[codex] Filter transactions by chart bucket#175
Conversation
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 0c97b26c8c
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| if (bucket.key !== selection.bucketKey) return false; | ||
| } | ||
|
|
||
| if (selection.segment === null) return true; |
There was a problem hiding this comment.
Respect chart mode for bucket-wide selections
When a bucket is selected via the new segment: null path, matchesFlowChartSelection returns true immediately after date matching, so flow filtering is skipped entirely. In external chart mode this means clicking a bucket can include transfer/swap rows that were not part of the visible chart slice, even though the selection carries mode: "external" and the chip label implies that context. This creates a misleading filter result for users who clicked the external-only view.
Useful? React with 👍 / 👎.
What changed
Why
The chart previously only filtered when users clicked an actual bar segment. Sparse months with tiny or no visible bars were hard to target, even though the visible chart bucket suggested the whole slice should be interactive.
Validation
pnpm --dir ui-tauri run typecheckpnpm --dir ui-tauri exec eslint src/components/transactions/dashboard/TransactionWorkbench.tsx src/components/transactions/dashboard/model.ts src/components/transactions/dashboard/model.test.tspnpm --dir ui-tauri exec vitest run src/components/transactions/dashboard/model.test.ts src/components/transactions/model.test.ts/transactions?period=1year: slice click producedChart: Mar 26 · All flows · All; bar click still producedChart: Apr 26 · Incoming · All./scripts/quality-gate.sh