Repository navigation
feat(web): findable registers, exact money and a command palette (2/4) - #10
Merged
Merged
Conversation
Slice 2 of the dashboard revamp (T1, apps/web only; no API or business logic change). - lib/format.ts: exact minor-unit formatting with string arithmetic and BigInt (Stripe exponents: zero-, two- and three-decimal currencies), "USD 1,234.56" outside tables, and one UTC timestamp format with seconds. Replaces Number()/100, which misrendered CLP/BHD-style currencies. - Every register gets search, facet chips with counts, a currency filter where records have one, sortable headers (aria-sort) and a summary that says which rows the filters cover. State lives in the URL via next/form. Payments page through the API; the ledger currency filter uses the API. - IdCell: short ID, full value in title and for screen readers, copy button, payment links. Tables gain a Ccy column, bare exact amounts and a scroll shadow on narrow screens. - Command palette (/, Ctrl/Cmd+K): open a payment by UUID, search any register, or jump to a page; native <dialog> and combobox pattern. - Ledger groups lines by journal with debit/credit totals and flags the journal the 500-line API limit may cut short. - List pages show the offline state instead of the 500 page when the API is unreachable. - Unit tests for formatting and list helpers; ui-signature.md documents money, time and finding-record conventions. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This was referenced Oct 24, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What and why
Slice 2: findable registers, exact money and a command palette. Operators had no search, filter, sort or pagination, and IDs were truncated with no full value or copy.
formatMoneyusedNumber(value) / 100with only three zero-decimal currencies, so CLP and ISK displayed 100× too small and BHD and KWD 10× wrong. No API, schema or business-logic change.lib/format.ts: minor units → decimal with string arithmetic andBigInt, using Stripe's zero-, two- and three-decimal exponents. Money readsUSD 1,234.56outside tables; every timestamp reads2026-10-24 07:15:36 UTC.aria-sort) and a summary saying what the filters cover. State lives in the URL vianext/form. Payments page through the API; the ledger currency filter uses the API'scurrencyparameter.IdCell(short ID, full value in the title and for screen readers, copy button, payment links),Amountwith raw minor units on hover, and aCcycolumn./, Ctrl/⌘+K): open a payment by UUID, search any register, or jump to a page. Native<dialog>and the combobox pattern.Screenshots:
.tmp/web-ui-revamp/screens/slice2(local, not attached).Review guide
apps/web/lib/format.ts: money must never change value.apps/web/lib/list.ts: money sorts by currency, then exact minor units.apps/web/app/ledger/page.tsx: journal grouping and the API-limit flag.apps/web/components/command-palette.tsx: the only new interactive client component.globals.cssadditions.Task size
T1 (
apps/webonly). Money formatting is display-only; no ledger, rounding or settlement logic changed.Checks
pnpm --filter @fintech-lab/web lintpnpm --filter @fintech-lab/web buildpnpm --filter @fintech-lab/web typecheckpnpm --filter @fintech-lab/web testgit diff --checkpnpm lint/test/build/typecheck(repo-wide) at this headUnverified boundaries
Browser checks were manual. Copy buttons were checked for focus and labels, not clipboard contents. With only 8 local payments, pagination past one page was checked by logic and URL, not with more than 100 rows.
Review
T1 self-review (
ponytail-review). Findings and disposition:?page=said "No payments yet" while payments existed → fixed, with a "Back to the newest" link.BigIntliterals aren't allowed at the ES2017 target → replaced withBigInt()calls.Docs and temporary files
docs/ui-signature.md: new "Money and time" and "Finding records" sections. Temporary files as listed in #9.🤖 Generated with Claude Code