[PR #6897] [CLOSED] [WIP] Desktop transactions react-table #13858

Closed
opened 2026-04-10 22:05:04 -05:00 by GiteaMirror · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/actualbudget/actual/pull/6897
Author: @MatissJanis
Created: 2/7/2026
Status: Closed

Base: masterHead: cursor/desktop-transactions-react-table-1d0c


📝 Commits (2)

  • b4fe5a0 feat: add React Table transactions table behind feature flag
  • 318526a fix: address lint warnings and add comprehensive unit tests

📊 Changes

8 files changed (+1928 additions, -46 deletions)

View changed files

📝 packages/desktop-client/package.json (+3 -0)
📝 packages/desktop-client/src/components/settings/Experimental.tsx (+5 -0)
packages/desktop-client/src/components/transactions/ReactTableTransactionTableInner.tsx (+715 -0)
packages/desktop-client/src/components/transactions/ReactTableTransactionsTable.test.tsx (+1127 -0)
📝 packages/desktop-client/src/components/transactions/TransactionsTable.tsx (+55 -45)
📝 packages/desktop-client/src/hooks/useFeatureFlag.ts (+1 -0)
📝 packages/loot-core/src/types/prefs.ts (+2 -1)
📝 yarn.lock (+20 -0)

📄 Description

Refactors the desktop transactions table to use TanStack React Table.

This change is implemented under a feature flag (reactTableTransactions) to allow both the legacy and new table implementations to coexist. The new table is designed to be visually and functionally identical to the existing one, including preserving keyboard navigation.

Key changes:

  • Feature Flag: reactTableTransactions added, defaulting to false.
  • New Component: ReactTableTransactionTableInner.tsx implements the table using @tanstack/react-table, reusing existing Transaction, TransactionHeader, NewTransaction, and TransactionError components.
  • Adapter Pattern: The main TransactionTable component now conditionally renders either the legacy or the new React Table inner component based on the feature flag.
  • Virtualization: Custom virtualization is implemented to match the performance characteristics of the original FixedSizeList.
  • Unit Tests: A new test file (ReactTableTransactionsTable.test.tsx) with 20 unit tests covers data rendering, keyboard navigation, and various transaction interactions for the React Table implementation.
  • Quality: All existing tests pass, new tests pass, and lint/typecheck are clean.

Open in Cursor Open in Web


Bundle Stats

Bundle Files count Total bundle size % Changed
desktop-client 27 14.47 MB → 14.6 MB (+124.47 kB) +0.84%
loot-core 1 5.86 MB 0%
api 1 4.39 MB 0%
View detailed bundle stats

desktop-client

Total

Files count Total bundle size % Changed
27 14.47 MB → 14.6 MB (+124.47 kB) +0.84%
Changeset
File Δ Size
node_modules/@tanstack/table-core/build/lib/index.mjs 🆕 +105.93 kB 0 B → 105.93 kB
src/components/transactions/ReactTableTransactionTableInner.tsx 🆕 +16.61 kB 0 B → 16.61 kB
node_modules/@tanstack/react-table/build/lib/index.mjs 🆕 +1.27 kB 0 B → 1.27 kB
src/hooks/useFeatureFlag.ts 📈 +33 B (+7.64%) 432 B → 465 B
src/components/settings/Experimental.tsx 📈 +223 B (+2.05%) 10.62 kB → 10.84 kB
node_modules/react-remove-scroll/dist/es2015/aggresiveCapture.js 📈 +8 B (+1.43%) 560 B → 568 B
node_modules/@radix-ui/react-focus-guards/dist/index.mjs 📈 +8 B (+0.94%) 850 B → 858 B
src/components/transactions/TransactionsTable.tsx 📈 +343 B (+0.39%) 86.09 kB → 86.43 kB
node_modules/hyperformula/es/interpreter/plugin/StatisticalAggregationPlugin.mjs 📈 +18 B (+0.12%) 15.1 kB → 15.12 kB
node_modules/chevrotain/lib_esm/src/parse/cst/cst_visitor.js 📈 +4 B (+0.07%) 5.6 kB → 5.61 kB
node_modules/hyperformula/es/interpreter/plugin/3rdparty/jstat/jstat.mjs 📈 +14 B (+0.06%) 23.5 kB → 23.51 kB
node_modules/@tanstack/query-core/build/modern/utils.js 📈 +2 B (+0.03%) 5.72 kB → 5.72 kB
node_modules/chevrotain/lib_esm/src/parse/parser/traits/gast_recorder.js 📈 +4 B (+0.03%) 13.43 kB → 13.44 kB
node_modules/chevrotain/lib_esm/src/scan/lexer.js 📈 +8 B (+0.02%) 35.17 kB → 35.18 kB
node_modules/@tanstack/query-core/build/modern/queryClient.js 📈 +2 B (+0.02%) 8.82 kB → 8.82 kB
node_modules/chevrotain/lib_esm/src/utils/utils.js 📈 +2 B (+0.02%) 10.77 kB → 10.78 kB
node_modules/@rschedule/core/es2015/generators.js 📈 +4 B (+0.01%) 65.67 kB → 65.68 kB
View detailed bundle breakdown

Added
No assets were added

Removed
No assets were removed

Bigger

Asset File Size % Changed
static/js/index.js 9.32 MB → 9.45 MB (+124.47 kB) +1.30%

Smaller
No assets were smaller

Unchanged

Asset File Size % Changed
static/js/indexeddb-main-thread-worker-e59fee74.js 12.94 kB 0%
static/js/workbox-window.prod.es5.js 5.64 kB 0%
static/js/da.js 106.62 kB 0%
static/js/de.js 178.39 kB 0%
static/js/en-GB.js 7.18 kB 0%
static/js/en.js 164.55 kB 0%
static/js/es.js 173.83 kB 0%
static/js/fr.js 179.62 kB 0%
static/js/it.js 171.44 kB 0%
static/js/nb-NO.js 157.23 kB 0%
static/js/nl.js 106.65 kB 0%
static/js/pl.js 88.64 kB 0%
static/js/pt-BR.js 154.57 kB 0%
static/js/sv.js 78.2 kB 0%
static/js/th.js 182.35 kB 0%
static/js/uk.js 215.11 kB 0%
static/js/resize-observer.js 18.37 kB 0%
static/js/BackgroundImage.js 120.54 kB 0%
static/js/ReportRouter.js 1.11 MB 0%
static/js/narrow.js 640.46 kB 0%
static/js/TransactionList.js 105.97 kB 0%
static/js/wide.js 160.07 kB 0%
static/js/AppliedFilters.js 9.71 kB 0%
static/js/usePayeeRuleCounts.js 11.79 kB 0%
static/js/useTransactionBatchActions.js 13.23 kB 0%
static/js/FormulaEditor.js 1.04 MB 0%

loot-core

Total

Files count Total bundle size % Changed
1 5.86 MB 0%
View detailed bundle breakdown

Added
No assets were added

Removed
No assets were removed

Bigger
No assets were bigger

Smaller
No assets were smaller

Unchanged

Asset File Size % Changed
kcab.worker.G2jIa5TY.js 5.86 MB 0%

api

Total

Files count Total bundle size % Changed
1 4.39 MB 0%
View detailed bundle breakdown

Added
No assets were added

Removed
No assets were removed

Bigger
No assets were bigger

Smaller
No assets were smaller

Unchanged

Asset File Size % Changed
bundle.api.js 4.39 MB 0%

🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/actualbudget/actual/pull/6897 **Author:** [@MatissJanis](https://github.com/MatissJanis) **Created:** 2/7/2026 **Status:** ❌ Closed **Base:** `master` ← **Head:** `cursor/desktop-transactions-react-table-1d0c` --- ### 📝 Commits (2) - [`b4fe5a0`](https://github.com/actualbudget/actual/commit/b4fe5a002bafb1b5dc76f6264b96b660457212f9) feat: add React Table transactions table behind feature flag - [`318526a`](https://github.com/actualbudget/actual/commit/318526a22fb749ec9f027a052dd60ef1eed4f0f4) fix: address lint warnings and add comprehensive unit tests ### 📊 Changes **8 files changed** (+1928 additions, -46 deletions) <details> <summary>View changed files</summary> 📝 `packages/desktop-client/package.json` (+3 -0) 📝 `packages/desktop-client/src/components/settings/Experimental.tsx` (+5 -0) ➕ `packages/desktop-client/src/components/transactions/ReactTableTransactionTableInner.tsx` (+715 -0) ➕ `packages/desktop-client/src/components/transactions/ReactTableTransactionsTable.test.tsx` (+1127 -0) 📝 `packages/desktop-client/src/components/transactions/TransactionsTable.tsx` (+55 -45) 📝 `packages/desktop-client/src/hooks/useFeatureFlag.ts` (+1 -0) 📝 `packages/loot-core/src/types/prefs.ts` (+2 -1) 📝 `yarn.lock` (+20 -0) </details> ### 📄 Description <!-- Thank you for submitting a pull request! Make sure to follow the instructions to write release notes for your PR — it should only take a minute or two: https://github.com/actualbudget/docs#writing-good-release-notes. Try running yarn generate:release-notes *before* pushing your PR for an interactive experience. --> Refactors the desktop transactions table to use TanStack React Table. This change is implemented under a feature flag (`reactTableTransactions`) to allow both the legacy and new table implementations to coexist. The new table is designed to be visually and functionally identical to the existing one, including preserving keyboard navigation. **Key changes:** * **Feature Flag:** `reactTableTransactions` added, defaulting to `false`. * **New Component:** `ReactTableTransactionTableInner.tsx` implements the table using `@tanstack/react-table`, reusing existing `Transaction`, `TransactionHeader`, `NewTransaction`, and `TransactionError` components. * **Adapter Pattern:** The main `TransactionTable` component now conditionally renders either the legacy or the new React Table inner component based on the feature flag. * **Virtualization:** Custom virtualization is implemented to match the performance characteristics of the original `FixedSizeList`. * **Unit Tests:** A new test file (`ReactTableTransactionsTable.test.tsx`) with 20 unit tests covers data rendering, keyboard navigation, and various transaction interactions for the React Table implementation. * **Quality:** All existing tests pass, new tests pass, and lint/typecheck are clean. --- <p><a href="https://cursor.com/background-agent?bcId=bc-ae7d97ca-759d-4f47-ad34-655872c11921"><picture><source media="(prefers-color-scheme: dark)" srcset="https://cursor.com/assets/images/open-in-cursor-dark.png"><source media="(prefers-color-scheme: light)" srcset="https://cursor.com/assets/images/open-in-cursor-light.png"><img alt="Open in Cursor" width="131" height="28" src="https://cursor.com/assets/images/open-in-cursor-dark.png"></picture></a>&nbsp;<a href="https://cursor.com/agents?id=bc-ae7d97ca-759d-4f47-ad34-655872c11921"><picture><source media="(prefers-color-scheme: dark)" srcset="https://cursor.com/assets/images/open-in-web-dark.png"><source media="(prefers-color-scheme: light)" srcset="https://cursor.com/assets/images/open-in-web-light.png"><img alt="Open in Web" width="114" height="28" src="https://cursor.com/assets/images/open-in-web-dark.png"></picture></a></p> <!--- actual-bot-sections ---> <hr /> <!--- bundlestats-action-comment key:combined start ---> ### Bundle Stats Bundle | Files count | Total bundle size | % Changed ------ | ----------- | ----------------- | --------- desktop-client | 27 | 14.47 MB → 14.6 MB (+124.47 kB) | +0.84% loot-core | 1 | 5.86 MB | 0% api | 1 | 4.39 MB | 0% <details> <summary>View detailed bundle stats</summary> #### desktop-client **Total** Files count | Total bundle size | % Changed ----------- | ----------------- | --------- 27 | 14.47 MB → 14.6 MB (+124.47 kB) | +0.84% <details> <summary>Changeset</summary> File | Δ | Size ---- | - | ---- `node_modules/@tanstack/table-core/build/lib/index.mjs` | 🆕 +105.93 kB | 0 B → 105.93 kB `src/components/transactions/ReactTableTransactionTableInner.tsx` | 🆕 +16.61 kB | 0 B → 16.61 kB `node_modules/@tanstack/react-table/build/lib/index.mjs` | 🆕 +1.27 kB | 0 B → 1.27 kB `src/hooks/useFeatureFlag.ts` | 📈 +33 B (+7.64%) | 432 B → 465 B `src/components/settings/Experimental.tsx` | 📈 +223 B (+2.05%) | 10.62 kB → 10.84 kB `node_modules/react-remove-scroll/dist/es2015/aggresiveCapture.js` | 📈 +8 B (+1.43%) | 560 B → 568 B `node_modules/@radix-ui/react-focus-guards/dist/index.mjs` | 📈 +8 B (+0.94%) | 850 B → 858 B `src/components/transactions/TransactionsTable.tsx` | 📈 +343 B (+0.39%) | 86.09 kB → 86.43 kB `node_modules/hyperformula/es/interpreter/plugin/StatisticalAggregationPlugin.mjs` | 📈 +18 B (+0.12%) | 15.1 kB → 15.12 kB `node_modules/chevrotain/lib_esm/src/parse/cst/cst_visitor.js` | 📈 +4 B (+0.07%) | 5.6 kB → 5.61 kB `node_modules/hyperformula/es/interpreter/plugin/3rdparty/jstat/jstat.mjs` | 📈 +14 B (+0.06%) | 23.5 kB → 23.51 kB `node_modules/@tanstack/query-core/build/modern/utils.js` | 📈 +2 B (+0.03%) | 5.72 kB → 5.72 kB `node_modules/chevrotain/lib_esm/src/parse/parser/traits/gast_recorder.js` | 📈 +4 B (+0.03%) | 13.43 kB → 13.44 kB `node_modules/chevrotain/lib_esm/src/scan/lexer.js` | 📈 +8 B (+0.02%) | 35.17 kB → 35.18 kB `node_modules/@tanstack/query-core/build/modern/queryClient.js` | 📈 +2 B (+0.02%) | 8.82 kB → 8.82 kB `node_modules/chevrotain/lib_esm/src/utils/utils.js` | 📈 +2 B (+0.02%) | 10.77 kB → 10.78 kB `node_modules/@rschedule/core/es2015/generators.js` | 📈 +4 B (+0.01%) | 65.67 kB → 65.68 kB </details> <details> <summary>View detailed bundle breakdown</summary> <div> **Added** No assets were added **Removed** No assets were removed **Bigger** Asset | File Size | % Changed ----- | --------- | --------- static/js/index.js | 9.32 MB → 9.45 MB (+124.47 kB) | +1.30% **Smaller** No assets were smaller **Unchanged** Asset | File Size | % Changed ----- | --------- | --------- static/js/indexeddb-main-thread-worker-e59fee74.js | 12.94 kB | 0% static/js/workbox-window.prod.es5.js | 5.64 kB | 0% static/js/da.js | 106.62 kB | 0% static/js/de.js | 178.39 kB | 0% static/js/en-GB.js | 7.18 kB | 0% static/js/en.js | 164.55 kB | 0% static/js/es.js | 173.83 kB | 0% static/js/fr.js | 179.62 kB | 0% static/js/it.js | 171.44 kB | 0% static/js/nb-NO.js | 157.23 kB | 0% static/js/nl.js | 106.65 kB | 0% static/js/pl.js | 88.64 kB | 0% static/js/pt-BR.js | 154.57 kB | 0% static/js/sv.js | 78.2 kB | 0% static/js/th.js | 182.35 kB | 0% static/js/uk.js | 215.11 kB | 0% static/js/resize-observer.js | 18.37 kB | 0% static/js/BackgroundImage.js | 120.54 kB | 0% static/js/ReportRouter.js | 1.11 MB | 0% static/js/narrow.js | 640.46 kB | 0% static/js/TransactionList.js | 105.97 kB | 0% static/js/wide.js | 160.07 kB | 0% static/js/AppliedFilters.js | 9.71 kB | 0% static/js/usePayeeRuleCounts.js | 11.79 kB | 0% static/js/useTransactionBatchActions.js | 13.23 kB | 0% static/js/FormulaEditor.js | 1.04 MB | 0% </div> </details> --- #### loot-core **Total** Files count | Total bundle size | % Changed ----------- | ----------------- | --------- 1 | 5.86 MB | 0% <details> <summary>View detailed bundle breakdown</summary> <div> **Added** No assets were added **Removed** No assets were removed **Bigger** No assets were bigger **Smaller** No assets were smaller **Unchanged** Asset | File Size | % Changed ----- | --------- | --------- kcab.worker.G2jIa5TY.js | 5.86 MB | 0% </div> </details> --- #### api **Total** Files count | Total bundle size | % Changed ----------- | ----------------- | --------- 1 | 4.39 MB | 0% <details> <summary>View detailed bundle breakdown</summary> <div> **Added** No assets were added **Removed** No assets were removed **Bigger** No assets were bigger **Smaller** No assets were smaller **Unchanged** Asset | File Size | % Changed ----- | --------- | --------- bundle.api.js | 4.39 MB | 0% </div> </details> </details> <!--- bundlestats-action-comment key:combined end ---> --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
GiteaMirror added the pull-request label 2026-04-10 22:05:04 -05:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/actual#13858