Skip to content

feat(web): filter and sort an account's transactions - #281

Open
suiramdev wants to merge 1 commit into
devfrom
feat/account-transactions-filter
Open

suiramdev wants to merge 1 commit into
devfrom
feat/account-transactions-filter

Conversation

@suiramdev

Copy link
Copy Markdown
Owner

Summary

An account's page now has the Transactions page's search and filters, saved filters, Newest/Largest sort and Outgoing/Incoming tabs. Results cover only that account, at every date, and the URL keeps the state. To share the code, the list moved from pages/budget into a new features/transaction-list slice. Look first at features/transaction-list/index.ts and pages/bank-account.

Motivation

  • The account page only offered a plain list with "Show older transactions". It had no way to search, filter or sort.
  • Copying the Transactions list would have meant keeping two versions of it in step.

Drawbacks

  • The diff is big because files moved. Generic pieces went to shared/ui/list-controls/, shared/ui/{load-error,stale-region}, shared/lib/text/amount-bound and a new shared/routing segment.
  • The account page doesn't get the period picker or the charts. It lists every date.

Prior art

  • I didn't add another shared/lib module. Steiger's shared-lib grouping limit is 15, so the URL search helpers went into a new shared/routing segment instead.

Notes

  • Visual change: the account page now shows the Transactions list controls. Its empty state reads "…on this account" in en and fr.
  • API: budget.getMerchants accepts an optional accountId, so company suggestions only list that account's companies.
  • Fix: with the amount sort, a day could head more than one group, which gave duplicate React keys and overlapping headers. Each header is now keyed by its first transaction, and the virtualizer by item key. A test covers this.
  • Tests: transaction-groups.test.ts gains the duplicate-key case. The period test moved to pages/budget/model/period.test.ts.
  • Docs: use/home.mdx, reference/procedures.mdx, docs/engineering/web-app.md, docs/engineering/web-ui.md, apps/web/AGENTS.md and the root AGENTS.md.
  • Pre-existing and unchanged here: 5 upcomingPayments/forecastSeries tests fail in a full apps/web run because other test files set TZ. They pass when run alone. This change splits one of those TZ-setting test files into two.

…tions page

Extract the transaction list into features/transaction-list and reuse it on
the bank-account page, scoped to the account with its state in the URL.
getMerchants takes an optional accountId so company suggestions are scoped.
Fix duplicate group-header keys under the amount sort.
@suiramdev
suiramdev enabled auto-merge (squash) November 13, 2026 15:06
@github-actions github-actions Bot added the type: feature A new capability, or an improvement to an existing one label Nov 13, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

type: feature A new capability, or an improvement to an existing one

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant