fix: round money to currency minor units without negative zero (WealthLedger/frontend#118) #119

Merged
codex-bot merged 1 commits from fix/118-rounded-money-display into develop 2026-10-28 08:45:56 +03:00
Owner

Closes #118

  • formatMoney(..., { withRoundedCents }) rounds to ISO 4217 minor units from Intl.NumberFormat().resolvedOptions() (RUB/USD 2, JPY 0, KWD 3; unknown codes 2).
  • A value rounded to zero loses its sign: -0.004 RUB → 0,00 ₽.
  • BigInt string arithmetic kept; no float.
  • CI: npm audit threshold low → moderate (owner decision). GHSA-gcqx-w48m-w2h4 (deepmerge ≤4.3.1, low, no patched release; build-only via vite-plugin-pwa → workbox-build) blocked every PR. README updated.

Verification

  • New test fails on develop (-0,00 ₽), passes now.
  • npm run verify green; CI commits/security/verify green.
Closes #118 - `formatMoney(..., { withRoundedCents })` rounds to ISO 4217 minor units from `Intl.NumberFormat().resolvedOptions()` (RUB/USD 2, JPY 0, KWD 3; unknown codes 2). - A value rounded to zero loses its sign: `-0.004 RUB` → `0,00 ₽`. - BigInt string arithmetic kept; no float. - CI: `npm audit` threshold `low` → `moderate` (owner decision). GHSA-gcqx-w48m-w2h4 (deepmerge ≤4.3.1, low, no patched release; build-only via vite-plugin-pwa → workbox-build) blocked every PR. README updated. ## Verification - New test fails on `develop` (`-0,00 ₽`), passes now. - `npm run verify` green; CI commits/security/verify green.
ksv741 added 1 commit 2026-10-28 08:29:21 +03:00
fix: round money to currency minor units without negative zero (WealthLedger/frontend#118)
Frontend verify / commits (pull_request) Successful in 28s
Frontend verify / security (pull_request) Successful in 11s
Frontend verify / verify (pull_request) Successful in 5m22s
Frontend verify / commits (pull_request) Successful in 29s
7b2bd8d379
ksv741 force-pushed fix/118-rounded-money-display from f1ccd3c7ae to 7b2bd8d379 2026-10-28 08:29:21 +03:00 Compare
codex-bot merged commit 1d4990491f into develop 2026-10-28 08:45:56 +03:00
codex-bot deleted branch fix/118-rounded-money-display 2026-10-28 08:45:56 +03:00
Sign in to join this conversation.
No Reviewers
2 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: WealthLedger/frontend#119