Compare commits

..

156 Commits

Author SHA1 Message Date
Joel Jeremy Marquez
c285392c3c Coderabbit 2025-01-08 13:09:33 -08:00
github-actions[bot]
3fe5b5aaf0 Update VRT 2025-01-08 19:38:17 +00:00
Joel Jeremy Marquez
4fc91c6b4c Fix typecheck 2025-01-08 11:11:42 -08:00
github-actions[bot]
45777cad8d Update VRT 2025-01-08 00:46:28 -08:00
Joel Jeremy Marquez
72644d3d51 Remove non-existent SelectedProviderWithItems 2025-01-08 00:46:28 -08:00
Joel Jeremy Marquez
5e805085b0 Ignore unused useActions 2025-01-08 00:46:28 -08:00
Joel Jeremy Marquez
4e6331c7f0 useTransactionsFilter hook 2025-01-08 00:46:28 -08:00
Joel Jeremy Marquez
2ec46d8dec Fix running balances by excluding child preview transactions 2025-01-08 00:46:12 -08:00
Joel Jeremy Marquez
bb17f6a6f1 Fix test 2025-01-08 00:46:12 -08:00
Joel Jeremy Marquez
ba70fca304 Fix test 2025-01-08 00:46:12 -08:00
Joel Jeremy Marquez
3ace7d199d Coderabbit feedback 2025-01-08 00:46:11 -08:00
Joel Jeremy Marquez
2a93b173e0 Fix default expand splits 2025-01-08 00:44:53 -08:00
Joel Jeremy Marquez
e9175951dd useTransactionsSearch 2025-01-08 00:44:53 -08:00
Joel Jeremy Marquez
3ba94642d9 Remove unused headerContent 2025-01-08 00:44:53 -08:00
Joel Jeremy Marquez
bc3b96c9b2 Release notes 2025-01-08 00:44:53 -08:00
Joel Jeremy Marquez
ccff8412d3 Fix preview transactions 2025-01-08 00:44:53 -08:00
Joel Jeremy Marquez
df61e42fda Initial commit 2025-01-08 00:44:53 -08:00
Joel Jeremy Marquez
0726760084 Code review feedback and improve schedules loading 2025-01-08 00:15:45 -08:00
Joel Jeremy Marquez
a7f65532fb Coderabbit feedback + make useSchedules consistent with query pattern used in useTransactions 2025-01-08 00:15:45 -08:00
Joel Jeremy Marquez
89059bf5da Code rabbit suggestions 2025-01-08 00:15:45 -08:00
Joel Jeremy Marquez
b9c167d5d6 Update useTransactions 2025-01-08 00:15:45 -08:00
Joel Jeremy Marquez
60dac66898 Apply coderabbit suggestions 2025-01-08 00:15:45 -08:00
Joel Jeremy Marquez
b9a43b992a Fix tests 2025-01-08 00:15:45 -08:00
Joel Jeremy Marquez
a7b90a0945 Fx flaky test 2025-01-08 00:15:45 -08:00
Joel Jeremy Marquez
fbc2ccd2e7 useTransactions hook to load transactions 2025-01-08 00:15:45 -08:00
Travis Lesicka
ce0ca60bcf ♻️ (typescript) Refactor Accounts/Balances to tsx and Remove ts-strict-ignore from Accounts/Account (#4047)
* Convert Balance.jsx to Balance.tsx

* Removed @ts-strict-ignore from Account.tsx

* Create 4047.md

* Fix typo

* Added Translation helpers to aria-labels

* Clarified canCalculateBalance return value logic
2025-01-08 08:59:22 +01:00
douugdev
3fbe6d05c8 fix: any rule not accounting for empty filter (#4051)
* fix: any rule not accounting for empty filter

* chore: add changelog
2025-01-08 00:37:50 +00:00
Joel Jeremy Marquez
cc1c11aac9 [Redux Toolkit Migration] Use new Redux Toolkit configureStore API (#4000)
* Initial upgrade to redux toolkit, more fixes needed e.g. removing non-serializable values from the state

* Fix typecheck and lint

* Fix lint and typecheck errors

* Fix lint and typecheck errors

* Fix typecheck error

* Cleanup

* Remove useAppStore

* Cleanup

* Undo renames

* Code review feedback

* UndoState type

* UndoState type

* yarn install
2025-01-07 16:34:21 -08:00
Robert Dyer
7dad36528c Add Copy last 6/12 months to budget menu (#4096)
* Add Copy last 12 months to budget menu

* add release note

* Make sure budget month actions use showUndoNotification
2025-01-08 00:33:03 +00:00
Julian Dominguez-Schatz
c956f8003b Mark release as draft initially (#4105)
* Mark release as draft initially

* Add release notes
2025-01-07 18:35:44 -05:00
sveselinovic
a5d591fed7 fix: creating new payee with 'one of'-condition broken (#4099)
* fix: creating new payee with 'one of'-condition broken

* change author and description of release note
2025-01-07 21:57:53 +01:00
Koen van Staveren
1f44903e4b enhance: net bar graph show net instead of two separate bars (#4033)
* enhance: net bar graph show net instead of two separate bars

* chore: note
2025-01-07 19:57:56 +01:00
Matt Fiddaman
bd77dfd111 🔧 Migrate to ESLint v9 (#3993) 2025-01-07 18:51:59 +00:00
Matt Fiddaman
39cfa11b25 🌍 improve translation strings - part 1 (#4041) 2025-01-07 18:47:13 +00:00
Matiss Janis Aboltins
af0a14ce3d ♻️ (typescript) refactor ScheduleDetails to tsx (#3964) 2025-01-07 18:45:52 +00:00
Matiss Janis Aboltins
1f2155053f 🔥 remove unused permissions prop from Button components (#4085) 2025-01-07 18:25:05 +00:00
Matiss Janis Aboltins
d5ebcced38 🔥 remove unused report prop from Link component (#4083) 2025-01-07 18:24:49 +00:00
Robert Dyer
7c2408daa6 Do not show undo notifications on desktop (#4097)
* Do not show undo notifications on desktop

* add release note

* fix linter

* Update packages/desktop-client/src/hooks/useUndo.ts

Co-authored-by: Joel Jeremy Marquez <joeljeremy.marquez@gmail.com>

* Update useUndo.ts

* fix code pasted on wrong line

* drive-by fix typo

* Update 4097.md

---------

Co-authored-by: Joel Jeremy Marquez <joeljeremy.marquez@gmail.com>
2025-01-07 08:08:14 -07:00
Julian Dominguez-Schatz
82e1922bee 🔖 (25.1.0) (#4095)
* 🔖 (25.1.0)

* Remove used release notes

---------

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2025-01-07 01:06:34 -05:00
gabe
8f66605994 add buttons for combined-account transaction pages on mobile (#3734)
* add buttons for combined-account transaction pages (#2333)

* add release note for #3734

* add accessibility label to mobile combined-account header button

* increase touch targets for combined-account buttons

* remove highlight color and add bounce to header buttons

to match the feel of the other account buttons

* update vrt screenshots for actualbudget#3734
2025-01-06 16:18:54 -08:00
Leo Lee
eadd11b7f0 (typescript) Refactoring the mobile TransactionListWithBalance component into typescript. (#4061)
* refactor: convert txListwBal to tsx

* docs: add release notes

* docs: rename notes

* refactor: fix missing cleared/uncleared balance

* refactor: use Binding type
2025-01-06 13:23:03 -08:00
Julian Dominguez-Schatz
832fd1e5d8 Fix schedule split template amounts (#4077)
* Fix incorrect argument to goals schedule function

* Add argument types to prevent similar issues

* Add release notes

* Fix test types
2025-01-02 18:01:19 -05:00
Matt Fiddaman
928260ca3a Fix calendar report day background colour in development theme (#4073)
* fix calendar background in development theme

* note
2025-01-02 17:12:27 +00:00
Julian Dominguez-Schatz
be5bfa275e Fix icon hover effect in transaction table (#4070)
* Fix icon hover effect in transaction table

* Add release notes

* Add test
2025-01-02 11:45:59 -05:00
Matt Fiddaman
1e65939147 fix mobile hold buffer initial sign (#4068) 2025-01-01 22:18:28 +00:00
youngcw
7060e4b657 [Goals]: fix repeating spend templates (#4066)
* fix repeating spend templates

* work with all repeat types

* note
2025-01-01 15:03:30 -07:00
Matt Fiddaman
da613ab673 Fix payee cell overflowing when it contains an icon (#4056) 2024-12-30 20:39:47 +00:00
Koen van Staveren
d894281465 enhance: context menu on sidebar elements (#3777)
* enhance: context menu on sidebar account

* enhance: context menu on EditableBudgetName

* chore: release note

* chore: lint

* Update packages/desktop-client/src/components/sidebar/Sidebar.tsx

* chore: fix margin

* fix: merge

* chore: use useContextMenu hook

* style: change account name field an input

* lint

---------

Co-authored-by: matt <matt@fiddaman.net>
Co-authored-by: Matt Fiddaman <github@m.fiddaman.uk>
2024-12-29 21:13:57 +00:00
Koen van Staveren
5c577aa069 enhance: context menu on custom reports page (#3776)
* enhance: context menu on custom reports page

* chore: release note

* chore: lint

* chore: use both feature flags

* chore: use both feature flags

* chore: pr feedback

* fix: changing name with context menu
2024-12-29 20:51:56 +00:00
Robert Dyer
e6aeea668b Fix issue where the UI is stuck sync'ing if no data from server (#3941)
* Fix issue where the UI is stuck sync'ing if no data from server

* add release note
2024-12-29 20:49:19 +00:00
Julian Dominguez-Schatz
ded2f39e13 Fix loading of number format on initial app startup (#4038)
* Fix loading of number format on initial app load

* Add release notes
2024-12-27 18:19:22 -05:00
Matt Fiddaman
3f6068fe88 add electron build files to eslint ignore list (#4042)
* add electron build files to eslintignore

* note
2024-12-26 01:22:53 +00:00
Julian Dominguez-Schatz
9213ed75b5 Upload translations on builds of master (#4002)
* fix: translations were not being loaded properly

* fix: support running GitHub actions locally with `act`

* feat: upload new strings on master build

* Add release notes

* PR feedback: security
2024-12-24 12:48:41 -05:00
Matt Fiddaman
93262e7fb4 extend fix splits tool to report splits with mismatched amounts (#3970) 2024-12-24 07:43:44 +00:00
Matt Fiddaman
cd8bb8e139 change feedback issue for openid (#4030) 2024-12-23 17:11:46 -07:00
Koen van Staveren
bd126b499b feat: now button at budget page (#3703)
* feat: now button on budget

* Update VRT

* chore: change to icon

* chore: rename to today

* chore: fix not being centered on multiple months

* Update VRT

* Update VRT

* Trigger Build

* fix: keep now button with monthpicker not left

* Update VRT

* fix: center MonthPicker

* Update VRT

* Trigger Build

---------

Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-12-23 23:11:15 +01:00
Koen van Staveren
8976ffc256 enhance: allow negatives in the budget template (#4028)
* enhance: allow negatives in the budget template

* chore: add test case

* chore: release note
2024-12-23 23:10:54 +01:00
lelemm
0b2c8ccd88 OpenId Implementation (#3878)
* OpenId implementation

* Code rabbit auto generated code applied

Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>

* Code rabbit suggestions round 2

Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>

* fixes from code rabbit round 1

* fixes from code rabbit round 2

* change variable name

* code review round 3

* Update VRT

* small fix

* Update VRT

* linter

* app.tsx

* LoggedInUser

* UserAccess

* UserAccessHeader

* UserAccessPage

* UserAccessRow

* UserDirectory

* UserDirectoryHeader

* UserDirectoryPage

* UserDirectoryRow

* BudgetList

* Bootstrap

* Login

* OpenIdForm

* CreateAccountModal

* EditAccess

* EditUser

* GoCardlessInitialiseModal

* OpenIDEnableModal

* PasswordEnableModal

* SimpleFinInitialiseModal

* TransferOwnership

* AuthSettings

* fix hooks in EditUser

* enable electron openid login

* typecheck

* linter and typecheck fixes

* Update VRT

* small fix

* linter

* small changes for file owner name and a fix for privacyfilter in the username

* linter for merge

* change the entra url and changing the electron loopback url when built

* "logged in as" was showing when had no user

* linter

* linter²

* code review

---------

Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Co-authored-by: matt <matt@fiddaman.net>
2024-12-23 09:46:22 -07:00
youngcw
cde81da72c [Goals]: Fix applying templates in tracking budget (#4010)
* fix logic

* note
2024-12-21 19:49:29 -07:00
Matt Fiddaman
6cfb9d2a7a Fix incorrect boldening of synced accounts in the sidebar (#4009) 2024-12-19 15:13:44 +00:00
Matt Fiddaman
4ce5e2fd07 Prevent schedules with null amounts from crashing the app (#3958)
* test

* note

* add comment
2024-12-18 21:55:23 +00:00
Matt Fiddaman
11bde73fa5 🔧 upgrade better-sqlite3 (#3987)
* upgrade better-sqlite3

* note
2024-12-18 09:05:46 +00:00
Matiss Janis Aboltins
94666a2ac1 Update bug-report.yml 2024-12-16 20:21:44 +00:00
Matiss Janis Aboltins
b6fbcef6f0 Update bug-report.yml 2024-12-16 20:21:15 +00:00
Matiss Janis Aboltins
1165c4c008 Update bug-report.yml (#3992) 2024-12-16 20:20:21 +00:00
Darin Loh
8446356cc6 fix: space missing on create local account copy (#3985) 2024-12-15 12:27:39 +00:00
lelemm
ec977ee51a Calendar Report (#3828) 2024-12-14 20:19:14 +00:00
Dany Khalife (MSFT)
ef95850e93 Migrate useSplitsExpanded to TypeScript (#3945)
* useSplitsExpanded renamed to .tsx

* Some type hardening

* add release note

* lint

* typecheck

* lint

* rename expanded -> isExpanded
2024-12-11 17:52:41 -08:00
Joel Jeremy Marquez
81fc029a03 Use useTranslation hook instead of directly importing the t function (#3893)
* Use useTranslation hook instead of directly importing the t function

* Release notes

* Fix lint
2024-12-11 13:57:45 -08:00
Dany Khalife (MSFT)
9e6a486c90 Dkhalife/ts/categorytransactions (#3959)
* rename

* a bit of hardening

* release notes

* typecheck & lint

* lint
2024-12-11 21:46:55 +00:00
Marian Bäuerle
9af3539b91 Fix iOS mobile navigation tabs disappearing on bouncing top (#3962) 2024-12-11 13:28:03 -08:00
Joel Jeremy Marquez
62d8358f90 Remove use of useActions (#3911)
* Remove use of useActions

* Release notes

* Fix lint
2024-12-10 15:16:56 -08:00
Joel Jeremy Marquez
219e139d55 Consistent accounts terminology (For budget / Budgeted --> On budget) (#3903)
* Change for budget and budgeted terms to on-budget

* Release notes

* Update mobile account header

* Fix release notes

* Fix release note category

* Update VRT

* Rename variables

* Remove hyphens

* Show off budget

* Update VRT

* Dummy commit

---------

Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-12-10 15:15:44 -08:00
Joel Jeremy Marquez
298b734539 Optimize useSheetValue (#3879)
* Optimize useSheetValue

* Fix lint

* Fix mock bind

* Reduce re-renders

* Update useSheetValue

* Update

* Make QueryState immutable

* Release notes
2024-12-10 09:35:23 -08:00
Joel Jeremy Marquez
e96b986ad0 Add loading indicator when loading more transactions in mobile transaction list (#3900)
* Add isLoadingMore property to useTransactions hook

* Release notes

* Start loading more earlier
2024-12-10 09:22:28 -08:00
Joel Jeremy Marquez
5104a1a563 Convert BudgetTable.jsx to tsx (#3899)
* Convert BudgetTable to TypeScript

* Release notes
2024-12-10 09:21:25 -08:00
Travis Lesicka
6ea77324ef Duplicate Budget (#3847)
* Initial Commit

* Create 3847.md

* Removed un-needed comment

* Changed error log text

* Moved budget name validation from DuplicateFileModal to loot-core/server

* Added translation

* Fixed linting error

* Changed delete file hack

Changed from loading and closing the budget file to just opening and closing the database to be able to delete it.

* Removed hard coded english from loot-core server

* Updated wording and style of Duplicate File Modal

* Simpler wording for Duplication text and buttons
2024-12-10 08:55:38 -07:00
lelemm
2b908e9263 Filter account with 'on budget' or 'off budget' (#3891)
* Filter account by on budget / off budget

* small fix

* fix eval for new operations

* code review suggestion

* suggestions

* small fix for rules table

* batch loading the accounts

* Update packages/loot-core/src/server/accounts/transaction-rules.ts

Co-authored-by: Matt Fiddaman <github@m.fiddaman.uk>

* missed this type

---------

Co-authored-by: Matt Fiddaman <github@m.fiddaman.uk>
2024-12-10 11:52:38 +00:00
Matiss Janis Aboltins
a2892270d2 🐛 fix condition "notes contains (nothing)" throwing error (#3943) 2024-12-09 22:00:36 +00:00
Matiss Janis Aboltins
d649eec4db 🐛 fix misaligned gocardless credential popover (#3942) 2024-12-09 21:59:55 +00:00
Koen van Staveren
5717d90544 enhance: context menu budget page positioning (#3775)
* enhance: context menu budget page positioning
fix: make popover non selectable

* chore: release note

* Update upcoming-release-notes/3775.md

* chore: improve spelling

* feat: useContextMenu hook for context menus

* fix: linting
2024-12-09 20:32:12 +01:00
Adam Langbert
a35af73023 fix tracking budget docs link (#3944)
* fix tracking budget docs link

* add release notes
2024-12-09 10:00:10 +00:00
Eric Ji
e4b40fb831 Menu Option Disappears Completely On Certain Screen Size (#3880)
* remove use of View component

* created a release note

* rename release note to PR number not issue number

* revert changes to check e2e tests

* redo changes

* indentify exact styling issue

* use style instead of css
2024-12-07 23:20:38 -05:00
Matiss Janis Aboltins
fa8ff79208 (dashboards) piecharts - sorting and label spacing (#3855) 2024-12-07 13:29:40 +00:00
Matt Fiddaman
3ce7ae91d9 Add more logging for GoCardless rate limit information (#3895) 2024-12-06 21:29:37 +00:00
annechoww
1b25235cc7 Category Labels Not Scaling Correctly On Small Screen (#3906)
* Fixed label scaling for smaller screens.

* Added release notes. Minor linting fix added.
2024-12-06 13:53:15 -07:00
Matt Fiddaman
f207803f7a 🔖 (24.12.0) (#3931)
* bump versions

* Remove used release notes

* Remove used release notes

---------

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2024-12-06 11:03:37 -07:00
Julian Dominguez-Schatz
df7bc5d2f0 Fix a navigation bug and a crash from the account pages (#3932)
* Don't crash when making a txn from the uncat page

* Always navigate consistently from the txn add/edit page

* Add release notes

* Attempt to fix functional tests

* Update VRT

---------

Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-12-06 08:34:20 +00:00
lelemm
5e7538fde3 'hasTags' should show only for notes (#3902)
* 'hasTags' should show only for notes

* md

* Update VRT

---------

Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-12-05 15:38:10 -08:00
Joel Jeremy Marquez
2c0bd6bafd Use useNavigate instead of accessing window.__navigate (#3904)
* Use useNavigate instead of accessing window.__navigate

* Release notes

* Update packages/desktop-client/src/components/manager/ConfigServer.tsx

Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>

---------

Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>
2024-12-05 15:37:52 -08:00
Michael Clark
501c8653ef 🐛 Fix flicker when saving transaction on account page when transactions are scheduled (#3920)
* fix flicker when saving transaction on account page when there are scheduled

* release notes
2024-12-02 08:53:57 +00:00
Joel Jeremy Marquez
22623ce65e Fix mobile transaction edit page's back button behavior (#3905)
* Fix mobile transaction edit page's back button behavior

* Release notes
2024-11-27 08:02:37 -08:00
Michael Clark
c25e3d4163 🐛 Fix performance when navigating between budget/accounts (#3882)
* memo the bindingobj

* release notes

* fix

* a bit heavy handed

* lint
2024-11-24 08:43:01 +00:00
Michael Clark
339fac2806 🔧 Summary Card: Change the font size implementation to be simpler & fix import dashboard (#3871)
* change the font size implementation to be simpler

* release notes

* setting the line height back

* renames

* condtion on the font changed event

* fix type check

* typecheck

* clarifying comment

* remove margin on left and right - not required

* fix import

* fix derp
2024-11-22 15:52:27 +00:00
Joel Jeremy Marquez
2ebaa527be Convert mobile Accounts.jsx to tsx (#3862)
* Convert mobile Accounts.jsx to TS

* Release notes

* Fix lint
2024-11-21 16:01:26 -08:00
Joel Jeremy Marquez
c5411518c4 Use strict typing in useSheetValue and fix bug where query is not being updated when changed (#3864)
* Use strict typing in useSheetValue and fix bug where query is not being updated when changed

* Release notes

* Update VRT

* Fix regression

* Update VRT

---------

Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-11-21 16:01:09 -08:00
Joel Jeremy Marquez
36839ff153 Convert ManagePayees components to Typescript (#3867)
* Convert ManagePayees components to Typescript

* Release notes

* Fix lint

* Fix lint

* Fix lint
2024-11-21 15:23:35 -08:00
Joel Jeremy Marquez
9d6db12921 Convert MergeUnusedPayeesModal.jsx to tsx (#3866)
* Convert MergeUnusedPayeesModal.jsx to tsx

* Release notes
2024-11-21 15:23:24 -08:00
Joel Jeremy Marquez
590ac1f95e Convert EditFieldModal.jsx to tsx (#3865)
* Convert EditFieldModal.jsx to tsx

* Release notes

* NoteAmendMode

* Fix lint
2024-11-21 15:23:09 -08:00
Joel Jeremy Marquez
8e76a65e0c Convert SimpleTransactionsTable.jsx to tsx (#3870)
* Convert SimpleTransactionsTable.jsx to tsx

* Release notes
2024-11-21 15:09:23 -08:00
Joel Jeremy Marquez
c3eda4247e Convert PostsOfflineNotification.jsx to tsx (#3868)
* Convert PostsOfflineNotification.jsx to tsx

* Release notes

* Fix lint
2024-11-21 15:09:00 -08:00
Matt Fiddaman
022b9b76b1 Allow the report table columns to grow to fill available space (#3872)
* allow report table columns to grow to fit

* note
2024-11-21 22:36:19 +00:00
Joel Jeremy Marquez
19f0037256 Fix preview transactions not showing on all accounts page and aggregated accounts page (budgeted/offbudget) (#3873)
* Fix preview transactions not showing on all accounts

* Release notes
2024-11-21 14:24:57 -08:00
lelemm
c626fc2f17 Summary report (#3792)
* Summary card report

* Apply suggestions from code rabbit

* Apply suggestions from code review

Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>

* MORE CODE RABBIT SUGGESTIONS

* typecheck fix

* change view form the details page

* added privacy filter

* Apply suggestions from code review

Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>

* debounce

* removed binary search and changed the summary page to not use the card component

* Update packages/desktop-client/src/components/reports/spreadsheets/summary-spreadsheet.ts

Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>

* fix on recommended code rabbit commit

* added some padding to number so it fits the window better for big numbers

* accept infinite

* feedback fixes

* Update packages/desktop-client/src/components/reports/reports/SummaryCard.tsx

Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>

* translations

* fix on the save, linter and changed "include summary date range" to "all time divisor"

* changed MD from enhancements to feature

* typo

* change card

* typecheck

* Update packages/desktop-client/src/components/reports/SummaryNumber.tsx

Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>

* typecheck

* changes to fit the number better

* small fix

* fix on filters

* code review

* revert code to check for height

---------

Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>
2024-11-21 09:25:09 -07:00
Joel Jeremy Marquez
f523d25052 Convert ManagementApp.jsx to tsx (#3860)
* Convert ManagementApp to tsx

* Release notes
2024-11-20 14:53:23 -08:00
Joel Jeremy Marquez
278ac0c730 Strict TS typing for useResizeObserver (#3859)
* Strict type useResizeObserver

* Release notes

* Fix typecheck error
2024-11-20 14:53:11 -08:00
Ryan Bianchi
0696c8113d Fix category is/is not (nothing) filters (#3669)
* filter out transfers when category is none

* add filter for parent id

* fix Category is not (nothing) as well

* lint fixups

* add special case for 'category is not nothing'

* add release notes

* adding tests

* lint fix

* use $and expression for complex condition special cases

* add tests for condition special cases

* Update packages/loot-core/src/server/accounts/rules.ts

rename subExpression to and

Co-authored-by: Koen van Staveren <koenvanstaveren@hotmail.com>

* update uses of subExpression with and

* remove stray debugger rules

* Update VRT

* Revert "Update VRT"

This reverts commit a450fc7b2457bb578e53f62d5f4201e91e9a93c4.

* make and an internal op to avoid exposing it to the UI

* feedback

---------

Co-authored-by: Koen van Staveren <koenvanstaveren@hotmail.com>
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Co-authored-by: matt <matt@fiddaman.net>
2024-11-20 11:38:52 +00:00
Matiss Janis Aboltins
688de5f604 (dashboards) release as first party feature (#3856) 2024-11-20 08:31:54 +00:00
Joel Jeremy Marquez
881410bc74 Fix wrong scheduled transfer payment direction on PWA (#3402)
* Fix #3230

* Release notes

* Rename hook function

* [chore] Comment

* Coderabbit feedback

* Fix loading states

* Code rabbit

* No payee text

* Update VRT

* Update release notes

---------

Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-11-19 13:57:40 -08:00
Ali Gradina
b4d2d6a884 Marked files for translation (#3548) 2024-11-19 18:52:24 +00:00
youngcw
5cf439883e [Goals] fix limits (#3829)
* fix limits

* cleanup

* fix cases of negative previous balance
2024-11-19 06:53:21 -07:00
Matiss Janis Aboltins
23bb89b96e release tracking budget feature (#3833) 2024-11-18 22:41:50 +00:00
Matt Fiddaman
7010ab1eb6 add simplefin batch sync to api (#3821) 2024-11-18 20:38:45 +00:00
Joel Jeremy Marquez
18f538c54b Convert Mobile Transaction component to TransactionListItem + cleanup (#3761)
* Migration mobile Transaction component to TransactionListItem + cleanup

* Release notes + yarn install

* Fix style

* Padding changes + VRT

* Update useScrollListener

* Code rabbit feedback

* Do not show loading on preview transactions
2024-11-18 06:38:08 -08:00
Joel Jeremy Marquez
e170c0d274 Fix mobile navigation tabs expanding/collapsing when scrolling in modals (#3731)
* Update scroll provider so that it only captures the scroll on div container and not the whole window

* Fix lint + release notes

* Rewrite useScroll to be more performant by being ref based instead of state to avoid re-renders when scrolling

* Check undefined

* Rename to useScrollListener

* Remove small 1px gap under mobile nav tabs when fully open

* Cleanup

* Fix lint

* Coderabbit feedback
2024-11-17 12:23:05 -08:00
Sai Hemanth Beeraka
dad702e5c2 🐛 Fix validation issue for invalid server URLs in /config-server page (#3837)
* Fix breaking /config-server page logic for invalid server URLs

* Handle missing url in 'subscribe-needs-bootstrap' handler
2024-11-15 20:33:29 +00:00
Michael Clark
224d445840 🐛 Fix parameter formatting issues (#3841)
* fix some errors in translation format

* release notes
2024-11-15 12:38:54 +00:00
Awais Alee
670419b087 Added the i18n translation for desktop-client (#3832) 2024-11-14 19:05:15 +00:00
Michael Clark
58baf74992 🐛 Fix translations failing (#3830)
* fix translations failing

* release notes

* blasphemy

* more blasphemy

* putting warning back

* last heretic act

* making the world a better place
2024-11-14 08:58:09 +00:00
Awais Alee
d08be58f95 Marked files for translation (#3827)
* Add translation files for desktop client

* Add backend translation files for i18n integration

* code refactored

* code refactored

* code refactored
2024-11-13 15:08:01 +00:00
Greg Lorenzen
db68170cce Translation: desktop-client/components/payees/PayeeMenu (#3670)
* Translation: desktop-client/components/payees/PayeeMenu

* Add release notes

* Merge master

* Remove dynamic values from selected payee translation
2024-11-12 20:05:35 +01:00
Michael Clark
1e1092e472 :electron: Separate build folders for easier switching between web and electron (#3801)
* seperate build folders for easier switching between web and electron builds

* gitignore

* release notes

* one directory back from electron

* spelling mistake

* Update 3801.md

* test

* making it correct

* huh

* urghh

* again

* account for api bundle which uses electron bundle for some reason

* hu-

* lets go

* remove comment
2024-11-12 18:39:49 +00:00
The-Firexx
d1324408f4 Fixes #2885 - Focus ring getting stuck on last column of /accounts/budgeted (#3571)
* Fixes focus ring getting stuck on last column of /accounts/budgeted screen when creating a new transaction.

* Fix lint problems with the previous commit

* Changed the way the hook is made to the cancel and add button, removing the need to change Button2

* Changed the name of variables as mentioned in PR
2024-11-12 09:13:52 -08:00
Austin Pearce
9e478014c5 fix back button behavior after adding tx on mobile (#3825)
Co-authored-by: Austin Pearce <austin@apearce.dev>
2024-11-12 08:58:43 +00:00
Michael Clark
dd69e539d3 🐛 Fix iphone 13 unable to use regex lookbehinds (#3823)
* fix iphone 13 unable to use regex lookbehinds

* release notes
2024-11-12 08:58:01 +00:00
jotch
2cb668a40c fix: don't clobber server pathname (#3815)
* fix: don't clobber server pathname

The provided server URL may already include a pathname,
so all further segments need to be appended. This also
more closely matches the name `joinURL`.

* add release notes

* use `fs.join` to avoid double slashes
2024-11-12 08:56:44 +00:00
Joel Jeremy Marquez
3cefd98ce9 useTransactions hook to simplify loading of transactions (#3685)
* useTransactions hook to load transactions

* Release notes + lint fix

* Update useQuery

* useTransactions update

* Stabilize tests

* Fx flaky test

* Fix tests

* Fix tests

* Update queries

* Apply coderabbit suggestions

* Fix onlySync

* Update useTransactions

* Code rabbit suggestions

* useTransactionsSearch hook

* Debounce the useTransactionsSearch search method

* usePreviewTransactions debounce fix

* Fix lint

* Coderabbit feedback + make useSchedules consistent with query pattern used in useTransactions

* Code review feedback and improve schedules loading

* Update error handling

* Cancel debounce on unmount

* Fix lint

* set loading state on error

* Fix test

* VRT

* Revert VRT

---------

Co-authored-by: Matt Fiddaman <github@m.fiddaman.uk>
2024-11-11 22:41:42 -08:00
youngcw
fa2830a1fd fix remainder goal (#3822) 2024-11-11 15:19:22 -07:00
youngcw
57ac062edc [Goals] fix how goal values are calculated (#3817)
* fix how goals are calculated

* lint, note

* note
2024-11-11 07:46:09 -07:00
Awais Alee
0c94214a8f Marked files for translation (#3752)
* Enhance app with i18n translations

* Code Refactored

* Added translated desktop client files

* Code refactored

* Code refactored

* Fix lint issue

* Removed i18next line from RuleRow.tsx

* Code refactored

* Code refactored

* Code refactored

* Update packages/desktop-client/src/components/settings/Encryption.tsx

Co-authored-by: Michael Clark <5285928+MikesGlitch@users.noreply.github.com>

* Added translation for setting encryption

* Update packages/desktop-client/src/components/settings/Themes.tsx

Co-authored-by: Michael Clark <5285928+MikesGlitch@users.noreply.github.com>

* Added translation in src/components/settings/Encryption.tsx

* Update packages/desktop-client/src/components/settings/Themes.tsx

Co-authored-by: Michael Clark <5285928+MikesGlitch@users.noreply.github.com>

* Update packages/desktop-client/src/components/settings/Themes.tsx

Co-authored-by: Michael Clark <5285928+MikesGlitch@users.noreply.github.com>

---------

Co-authored-by: youngcw <calebyoung94@gmail.com>
Co-authored-by: Michael Clark <5285928+MikesGlitch@users.noreply.github.com>
2024-11-11 14:37:08 +00:00
Koen van Staveren
2b72b2f2f2 Update update-vrt.yml (#3800) 2024-11-07 16:03:15 +00:00
Koen van Staveren
985b653a87 Update update-vrt.yml (#3799) 2024-11-07 15:44:19 +00:00
Koen van Staveren
f14b160e5c [WIP] Update update-vrt.yml (#3798) 2024-11-07 16:29:31 +01:00
A. Schueler
8eafa1e741 fix: check gocardless bank data before setting state (#3793) 2024-11-07 15:01:37 +00:00
Travis Lesicka
aefd9504bf Update Sidebar - Refactor the Budget Name component (#3593)
* Initial Commit

Moved Budget Name to its own component for a cleaner Sidebar component.
Added pencil icon for editing budget name.
Removed Rename Budget from menu.

* Create 3593.md

* Fixed Menu Dropdown Arrow shrinks with long budget name

* Changes recommended by coderabbitai

* Fixed Lint issue

* Remove Help from Menu

* Remove menu from budget name and added Actual logo with menu

* Update VRTs

* Update VRTs

* Fix logo shrinking with long budget name issue

* Update 3593.md

* Removed Logo and pencil icon

* Update VRTs

* Removed unused classnames from SideBar and BudgetName component

* revert to upstream VRTs
2024-11-06 20:53:58 -07:00
Matiss Janis Aboltins
1f6977da81 🐛 (dashboards) remove faulty dashboard widgets (#3785) 2024-11-06 22:14:33 +00:00
Travis Lesicka
290402ee6a Fixes #3729: Typescript and Runtime error after previous merge (#3794) 2024-11-06 20:11:46 +00:00
Koen van Staveren
c3b95886db ci: add reactions to /update-vrt comment (#3789)
* ci: add reactions to /update-vrt comment

* chore: use correct permissions

* chore: don't cancel on non command message

* chore: make workflow not expose github secret

* Update .github/workflows/update-vrt.yml
2024-11-06 09:30:00 +01:00
Joel Jeremy Marquez
e53d444c32 Fix loading of mobile/desktop page on window resize (#3729)
* Fix loading of mobile/desktop page on window resize

* Release notes

* Fix lint

* Use useWindowSize since it matches behavior of documentElement clientWidth and clientHeight

* Debounce so that components are only reloaded when user finishes the resize

* Adjust debounce delay
2024-11-05 15:38:03 -08:00
joel-rich
c0f9073f35 Fixes #3682 - Fix $ne filters incorrectly excluding null values (#3686)
* allow matching null values when not equals query filter is set

* Also fix namedParameter queries with  filter

* improve tests

* release note

---------

Co-authored-by: Joel Rich <joelrich@protonmail.com>
2024-11-05 00:39:43 -08:00
Koen van Staveren
19c6f85f5e Update update-vrt.yml (#3788) 2024-11-04 19:58:22 +01:00
Koen van Staveren
d4f1f703ea fix: /update-vrt (#3787)
fatal: detected dubious ownership in repository at
https://github.com/actions/runner-images/issues/6775
2024-11-04 19:43:49 +01:00
Michael Clark
914f59197f :electron: Removing node-fetch and updating root ca impl for more support (#3782)
* updating root ca impl to use node env variable for more support

* release notes

* removing node-fetch

* clean up

* error message

* Update 3782.md
2024-11-04 18:35:21 +00:00
youngcw
7c24c269e2 ♻️ make templates classy and replace 🍝 code (#3754)
* by check

* minor changes and TS class migration

* good starting point

* very basic testing

* fix

* basic overwrite of simple templates working

* mostly working.  By and schedule don't work

* some cleanup, better async

* add notifications

* add daily weekly limits

* by is working I think

* mostly working

* some fixes, make faster

* lint, note

* note

* cleanup old stuff

* fix paths

* test fixes

* fix test

* fix note

* rabbit, and fix long goal

* lint

* some fixes

* more typing

* fix save error

* last bunny fixes

* fix save, trim schedule names

* lint

* minor fixes

* last fixes

* lint
2024-11-04 11:28:01 -07:00
Matiss Janis Aboltins
c52e5c856d 🐛 (dashboards) save cash flow balance setting (#3745)
Closes #3671
2024-11-04 17:56:29 +00:00
Matiss Janis Aboltins
b08756cc39 ♻️ custom reports - moving to url identifiers (#3744) 2024-11-04 17:56:14 +00:00
Koen van Staveren
29fc22a171 fix: maintain the sort order of the server sync (#3748)
* fix: maintain the sort order of the server sync

* chore: release note

* fix: tests

* chore: release note
2024-11-04 17:56:15 +01:00
Matt Fiddaman
815f69a051 implement SimpleFin batch sync (#3581)
* initial

* remove incorrect automated imports

* fixes

* refactor to mark all transactions new

* clamp latestTransaction to current date

* refactor out temporary placeholder solution

* simplify bank syning logic

* stricter types

* note

* remove debug logging

* better logging

* error handling

* fix handling of SimpleFinBatchSync

* pass errors down

* fix

* another go!

* hopefully the last try...

* fix log

* Update packages/loot-core/src/server/accounts/sync.ts

Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>

* coderabbit: simplify promise construction

* Update packages/loot-core/src/client/actions/account.ts

Co-authored-by: Koen van Staveren <koenvanstaveren@hotmail.com>

* expand types

* month utils

* use aql over sql

* fix types

* fixes

---------

Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>
Co-authored-by: Koen van Staveren <koenvanstaveren@hotmail.com>
2024-11-04 16:39:04 +00:00
Koen van Staveren
83ceea4250 fix: /update-vrt on forks (#3773)
* fix: /update-vrt on forks

* chore: add missing container for /update-vrt

---------

Co-authored-by: Matt Fiddaman <github@m.fiddaman.uk>
2024-11-04 17:01:55 +01:00
JahJoey
59d685fab6 Fix: #3719: Imported payee overflowing on transaction record (#3753)
* Modified tooltip to have set width to avoid overflow issue on imported payee records

* Added release note

* Fixed release note file name
2024-11-04 16:59:19 +01:00
Dreptschar
a267e3abb5 Apply Template to All Categories in Group for Web (#3666)
* add function to apply template to multiple category and add button to group sidebar

* add function to apply template to multiple category and add button to group sidebar

* add correct month

* clean up code

* clean up code

* clean up code

* clean up code

* add notification and clean up

* add notification and clean up

* add notification and clean up

* add notification and clean up

* add notification and clean up

* add release note

* excluded hidden categories

* removed unused method from api

* adjust template to run on already budgeted categories

* fix typecheck

* add apply multiple as budget action and remove from api

* lint clean up

* fix notification and remove log

---------

Co-authored-by: dreptschar <dreptschar@gmail.com>
2024-11-04 07:22:29 -07:00
Joel Jeremy Marquez
e078ed21ba [Typescript migration] Migrate AccountSyncCheck to ts (#3757)
* Migrate AccountSyncCheck to ts

* Release notes

* Fix lint
2024-11-03 13:04:43 -08:00
Koen van Staveren
41d5922635 Add context menu's (#3381)
* feat: context menu on transactions

* feat: context menu's on budget page

* chore: release note

* fix: losing focus on context menu

* feat: schedules context menu

* feat: payees context menu

* feat: rules context menu

* chore: update release note

* chore: lint

* fix: broken balance movement menu

* fix: placement on context menu to be closer to cursor

* feat: context menu on budget field

* chore: lint

* Update packages/desktop-client/src/components/transactions/TransactionsTable.jsx

Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>

* chore: fix merge

* fix: e2e test

* fix: moving of the popover in the sidebar

* chore: lint

* chore: add feature flag

* chore: fix tsc

* chore: fix test

* Update packages/desktop-client/src/components/settings/Experimental.tsx

Co-authored-by: Julian Dominguez-Schatz <julian.dominguezschatz@gmail.com>

* fix: to budget button

next steps didn't work

* chore: lint

---------

Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>
Co-authored-by: Julian Dominguez-Schatz <julian.dominguezschatz@gmail.com>
2024-11-03 14:26:53 -05:00
Julian Dominguez-Schatz
6f07894be7 Auto-reload on app updates (#3693)
* Auto-reload on app updates

* update #1

* test

* wip

* green

* wip

* ux

* green

* red

* cleanup

* Add release notes

* Unique notification name

* Missing awaits

* Try to fix Electron app

* Simplify update checking

* PR feedback
2024-11-03 13:00:12 -05:00
Koen van Staveren
871de93f2d ci: /update-vrt (#3764)
* ci: /update-vrt

* chore: release note

* chore: code rabbit feedback.

* chore: code rabbit feedback.

* chore: code rabbit feedback.
2024-11-03 10:51:34 -07:00
lelemm
15b2ef1591 Fix #2932: Schedule reset amount to ten (10) when amount is zero (0) (#3732)
* Fix #2932

* md

* e2e update

* Update packages/desktop-client/src/components/util/AmountInput.tsx

Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>

---------

Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>
2024-11-03 16:46:23 +00:00
681 changed files with 24277 additions and 12326 deletions

View File

@@ -1,28 +0,0 @@
packages/api/app/bundle.api.js
packages/api/dist
packages/api/@types
packages/api/migrations
packages/crdt/dist
packages/desktop-client/bundle.browser.js
packages/desktop-client/build/
packages/desktop-client/build-stats/
packages/desktop-client/public/kcab/
packages/desktop-client/public/data/
packages/desktop-client/**/node_modules/*
packages/desktop-client/node_modules/
packages/desktop-client/src/icons/**/*
packages/desktop-client/test-results/
packages/desktop-client/playwright-report/
packages/desktop-electron/client-build/
packages/desktop-electron/dist/
packages/import-ynab4/**/node_modules/*
packages/import-ynab5/**/node_modules/*
packages/loot-core/**/node_modules/*
packages/loot-core/**/lib-dist/*
packages/loot-core/**/proto/*

View File

@@ -1,603 +0,0 @@
const path = require('path');
const rulesDirPlugin = require('eslint-plugin-rulesdir');
rulesDirPlugin.RULES_DIR = path.join(
__dirname,
'packages',
'eslint-plugin-actual',
'lib',
'rules',
);
const ruleFCMsg =
'Type the props argument and let TS infer or use ComponentType for a component prop';
const restrictedImportPatterns = [
{
group: ['*.api', '*.web', '*.electron'],
message: 'Dont directly reference imports from other platforms',
},
{
group: ['uuid'],
importNames: ['*'],
message: "Use `import { v4 as uuidv4 } from 'uuid'` instead",
},
];
const restrictedImportColors = [
{
group: ['**/style', '**/colors'],
importNames: ['colors'],
message: 'Please use themes instead of colors',
},
];
module.exports = {
root: true,
env: {
browser: true,
commonjs: true,
es6: true,
jest: true,
node: true,
},
plugins: [
'prettier',
'import',
'rulesdir',
'@typescript-eslint',
'jsx-a11y',
'react-hooks',
],
extends: [
'plugin:react/recommended',
'plugin:react/jsx-runtime',
'plugin:prettier/recommended',
'plugin:@typescript-eslint/recommended',
'plugin:import/typescript',
],
parser: '@typescript-eslint/parser',
parserOptions: { project: [path.join(__dirname, './tsconfig.json')] },
reportUnusedDisableDirectives: true,
globals: {
globalThis: false,
vi: true,
},
rules: {
// http://eslint.org/docs/rules/
'array-callback-return': 'warn',
'default-case': ['warn', { commentPattern: '^no default$' }],
'dot-location': ['warn', 'property'],
eqeqeq: ['warn', 'smart'],
'new-parens': 'warn',
'no-array-constructor': 'warn',
'no-caller': 'warn',
'no-cond-assign': ['warn', 'except-parens'],
'no-const-assign': 'warn',
'no-control-regex': 'warn',
'no-delete-var': 'warn',
'no-dupe-args': 'warn',
'no-dupe-class-members': 'warn',
'no-dupe-keys': 'warn',
'no-duplicate-case': 'warn',
'no-empty-character-class': 'warn',
'no-empty-pattern': 'warn',
'no-eval': 'warn',
'no-ex-assign': 'warn',
'no-extend-native': 'warn',
'no-extra-bind': 'warn',
'no-extra-label': 'warn',
'no-fallthrough': 'warn',
'no-func-assign': 'warn',
'no-implied-eval': 'warn',
'no-invalid-regexp': 'warn',
'no-iterator': 'warn',
'no-label-var': 'warn',
'no-labels': ['warn', { allowLoop: true, allowSwitch: false }],
'no-lone-blocks': 'warn',
'no-mixed-operators': [
'warn',
{
groups: [
['&', '|', '^', '~', '<<', '>>', '>>>'],
['==', '!=', '===', '!==', '>', '>=', '<', '<='],
['&&', '||'],
['in', 'instanceof'],
],
allowSamePrecedence: false,
},
],
'no-multi-str': 'warn',
'no-global-assign': 'warn',
'no-unsafe-negation': 'warn',
'no-new-func': 'warn',
'no-new-object': 'warn',
'no-new-symbol': 'warn',
'no-new-wrappers': 'warn',
'no-obj-calls': 'warn',
'no-octal': 'warn',
'no-octal-escape': 'warn',
'no-redeclare': 'warn',
'no-regex-spaces': 'warn',
'no-script-url': 'warn',
'no-self-assign': 'warn',
'no-self-compare': 'warn',
'no-sequences': 'warn',
'no-shadow-restricted-names': 'warn',
'no-sparse-arrays': 'warn',
'no-template-curly-in-string': 'warn',
'no-this-before-super': 'warn',
'no-throw-literal': 'warn',
'no-undef': 'error',
'no-unreachable': 'warn',
'no-unused-expressions': [
'error',
{
allowShortCircuit: true,
allowTernary: true,
allowTaggedTemplates: true,
},
],
'no-unused-labels': 'warn',
'no-use-before-define': [
'warn',
{
functions: false,
classes: false,
variables: false,
},
],
'no-useless-computed-key': 'warn',
'no-useless-concat': 'warn',
'no-useless-constructor': 'warn',
'no-useless-escape': 'warn',
'no-useless-rename': [
'warn',
{
ignoreDestructuring: false,
ignoreImport: false,
ignoreExport: false,
},
],
'no-with': 'warn',
'no-whitespace-before-property': 'warn',
'react-hooks/exhaustive-deps': 'warn',
'require-yield': 'warn',
'rest-spread-spacing': ['warn', 'never'],
strict: ['warn', 'never'],
'unicode-bom': ['warn', 'never'],
'use-isnan': 'warn',
'valid-typeof': 'warn',
'no-restricted-properties': [
'error',
{
object: 'require',
property: 'ensure',
message:
'Please use import() instead. More info: https://facebook.github.io/create-react-app/docs/code-splitting',
},
{
object: 'System',
property: 'import',
message:
'Please use import() instead. More info: https://facebook.github.io/create-react-app/docs/code-splitting',
},
],
'getter-return': 'warn',
// https://github.com/benmosher/eslint-plugin-import/tree/master/docs/rules
'import/first': 'error',
'import/no-amd': 'error',
'import/no-anonymous-default-export': 'warn',
'import/no-webpack-loader-syntax': 'error',
// https://github.com/yannickcr/eslint-plugin-react/tree/master/docs/rules
'react/forbid-foreign-prop-types': ['warn', { allowInPropTypes: true }],
'react/jsx-no-comment-textnodes': 'warn',
'react/jsx-no-duplicate-props': 'warn',
'react/jsx-no-target-blank': 'warn',
'react/jsx-no-undef': 'error',
'react/jsx-pascal-case': [
'warn',
{
allowAllCaps: true,
ignore: [],
},
],
'react/no-danger-with-children': 'warn',
// Disabled because of undesirable warnings
// See https://github.com/facebook/create-react-app/issues/5204 for
// blockers until its re-enabled
// 'react/no-deprecated': 'warn',
'react/no-direct-mutation-state': 'warn',
'react/no-is-mounted': 'warn',
'react/no-typos': 'error',
'react/require-render-return': 'error',
'react/style-prop-object': 'warn',
// https://github.com/evcohen/eslint-plugin-jsx-a11y/tree/master/docs/rules
'jsx-a11y/alt-text': 'warn',
'jsx-a11y/anchor-has-content': 'warn',
'jsx-a11y/anchor-is-valid': [
'warn',
{
aspects: ['noHref', 'invalidHref'],
},
],
'jsx-a11y/aria-activedescendant-has-tabindex': 'warn',
'jsx-a11y/aria-props': 'warn',
'jsx-a11y/aria-proptypes': 'warn',
'jsx-a11y/aria-role': ['warn', { ignoreNonDOM: true }],
'jsx-a11y/aria-unsupported-elements': 'warn',
'jsx-a11y/heading-has-content': 'warn',
'jsx-a11y/iframe-has-title': 'warn',
'jsx-a11y/img-redundant-alt': 'warn',
'jsx-a11y/no-access-key': 'warn',
'jsx-a11y/no-distracting-elements': 'warn',
'jsx-a11y/no-redundant-roles': 'warn',
'jsx-a11y/role-has-required-aria-props': 'warn',
'jsx-a11y/role-supports-aria-props': 'warn',
'jsx-a11y/scope': 'warn',
// https://github.com/facebook/react/tree/main/packages/eslint-plugin-react-hooks
'react-hooks/rules-of-hooks': 'error',
'prettier/prettier': 'warn',
// Note: base rule explicitly disabled in favor of the TS one
'no-unused-vars': 'off',
'@typescript-eslint/no-unused-vars': [
'warn',
{
varsIgnorePattern: '^(_|React)',
ignoreRestSiblings: true,
caughtErrors: 'none',
},
],
curly: ['warn', 'multi-line', 'consistent'],
'no-restricted-globals': ['warn'].concat(
require('confusing-browser-globals').filter(g => g !== 'self'),
),
'react/jsx-filename-extension': [
'warn',
{ extensions: ['.jsx', '.tsx'], allow: 'as-needed' },
],
'react/jsx-no-useless-fragment': 'warn',
'react/self-closing-comp': 'warn',
'react/no-unstable-nested-components': [
'warn',
{ allowAsProps: true, customValidators: ['formatter'] },
],
'rulesdir/typography': 'warn',
'rulesdir/prefer-if-statement': 'warn',
// https://github.com/eslint/eslint/issues/16954
// https://github.com/eslint/eslint/issues/16953
'no-loop-func': 'off',
// Do don't need this as we're using TypeScript
'react/prop-types': 'off',
// TODO: re-enable these rules
'react/react-in-jsx-scope': 'off',
'no-var': 'warn',
'react/jsx-curly-brace-presence': 'warn',
'object-shorthand': ['warn', 'properties'],
'import/extensions': [
'warn',
'never',
{
json: 'always',
},
],
'import/no-useless-path-segments': 'warn',
'import/no-duplicates': ['warn', { 'prefer-inline': true }],
'import/no-unused-modules': ['warn', { unusedExports: true }],
'import/order': [
'warn',
{
alphabetize: {
caseInsensitive: true,
order: 'asc',
},
groups: [
'builtin', // Built-in types are first
'external',
'parent',
'sibling',
'index', // Then the index file
],
'newlines-between': 'always',
pathGroups: [
// Enforce that React (and react-related packages) is the first import
{ group: 'builtin', pattern: 'react?(-*)', position: 'before' },
// Separate imports from Actual from "real" external imports
{
group: 'external',
pattern: 'loot-{core,design}/**/*',
position: 'after',
},
],
pathGroupsExcludedImportTypes: ['react'],
},
],
'no-restricted-syntax': [
'warn',
{
// forbid React.* as they are legacy https://twitter.com/dan_abramov/status/1308739731551858689
selector:
":matches(MemberExpression[object.name='React'], TSQualifiedName[left.name='React'])",
message:
'Using default React import is discouraged, please use named exports directly instead.',
},
{
// forbid <a> in favor of <Link>
selector: 'JSXOpeningElement[name.name="a"]',
message: 'Using <a> is discouraged, please use <Link> instead.',
},
],
'no-restricted-imports': [
'warn',
{ patterns: [...restrictedImportPatterns, ...restrictedImportColors] },
],
'@typescript-eslint/ban-ts-comment': [
'error',
{ 'ts-ignore': 'allow-with-description' },
],
// Rules disable during TS migration
'@typescript-eslint/no-var-requires': 'off',
'prefer-const': 'warn',
'prefer-spread': 'off',
'@typescript-eslint/no-empty-function': 'off',
'@typescript-eslint/no-require-imports': 'off',
'import/no-default-export': 'warn',
},
overrides: [
{
files: ['**/*.ts?(x)'],
parser: '@typescript-eslint/parser',
parserOptions: {
ecmaVersion: 2018,
sourceType: 'module',
ecmaFeatures: {
jsx: true,
},
// typescript-eslint specific options
warnOnUnsupportedTypeScriptVersion: true,
},
plugins: ['@typescript-eslint'],
// If adding a typescript-eslint version of an existing ESLint rule,
// make sure to disable the ESLint rule here.
rules: {
// TypeScript's `noFallthroughCasesInSwitch` option is more robust (#6906)
'default-case': 'off',
// 'tsc' already handles this (https://github.com/typescript-eslint/typescript-eslint/issues/291)
'no-dupe-class-members': 'off',
// 'tsc' already handles this (https://github.com/typescript-eslint/typescript-eslint/issues/477)
'no-undef': 'off',
// Add TypeScript specific rules (and turn off ESLint equivalents)
'@typescript-eslint/consistent-type-assertions': 'warn',
'no-array-constructor': 'off',
'@typescript-eslint/no-array-constructor': 'warn',
'no-redeclare': 'off',
'@typescript-eslint/no-redeclare': 'warn',
'no-use-before-define': 'off',
'@typescript-eslint/no-use-before-define': [
'warn',
{
functions: false,
classes: false,
variables: false,
typedefs: false,
},
],
'no-unused-expressions': 'off',
'@typescript-eslint/no-unused-expressions': [
'error',
{
allowShortCircuit: true,
allowTernary: true,
allowTaggedTemplates: true,
},
],
'no-useless-constructor': 'off',
'@typescript-eslint/no-useless-constructor': 'warn',
},
},
{
files: ['.eslintrc.js', './**/.eslintrc.js'],
parserOptions: { project: null },
rules: {
'@typescript-eslint/consistent-type-exports': 'off',
},
},
{
files: [
'./packages/desktop-client/**/*.{ts,tsx}',
'./packages/loot-core/src/client/**/*.{ts,tsx}',
],
rules: {
// enforce type over interface
'@typescript-eslint/consistent-type-definitions': ['warn', 'type'],
// enforce import type
'@typescript-eslint/consistent-type-imports': [
'warn',
{ prefer: 'type-imports', fixStyle: 'inline-type-imports' },
],
'@typescript-eslint/no-restricted-types': [
'warn',
{
types: {
// forbid FC as superflous
FunctionComponent: { message: ruleFCMsg },
FC: { message: ruleFCMsg },
},
},
],
},
},
{
files: ['./packages/desktop-client/**/*'],
excludedFiles: [
'./packages/desktop-client/src/hooks/useNavigate.{ts,tsx}',
],
rules: {
'no-restricted-imports': [
'warn',
{
patterns: [
{
group: ['react-router-dom'],
importNames: ['useNavigate'],
message: 'Please use Actuals useNavigate() hook instead.',
},
],
},
],
},
},
{
files: ['./packages/loot-core/src/**/*'],
rules: {
'no-restricted-imports': [
'warn',
{
patterns: [
...restrictedImportPatterns,
{
group: ['loot-core/**'],
message:
'Please use relative imports in loot-core instead of importing from `loot-core/*`',
},
],
},
],
},
},
{
files: [
'packages/loot-core/src/types/**/*',
'packages/loot-core/src/client/state-types/**/*',
'**/icons/**/*',
'**/{mocks,__mocks__}/**/*',
// can't correctly resolve usages
'**/*.{testing,electron,browser,web,api}.ts',
],
rules: { 'import/no-unused-modules': 'off' },
},
{
files: [
'./packages/desktop-client/src/style/index.*',
'./packages/desktop-client/src/style/palette.*',
],
rules: {
'no-restricted-imports': ['off', { patterns: restrictedImportColors }],
},
},
{
files: [
'./packages/api/migrations/*',
'./packages/loot-core/migrations/*',
],
rules: {
'import/no-default-export': 'off',
},
},
{
// TODO: fix the issues in these files
files: [
'./packages/desktop-client/src/components/accounts/Account.jsx',
'./packages/desktop-client/src/components/accounts/MobileAccount.jsx',
'./packages/desktop-client/src/components/accounts/MobileAccounts.jsx',
'./packages/desktop-client/src/components/App.tsx',
'./packages/desktop-client/src/components/budget/BudgetCategories.jsx',
'./packages/desktop-client/src/components/budget/BudgetSummaries.tsx',
'./packages/desktop-client/src/components/budget/DynamicBudgetTable.tsx',
'./packages/desktop-client/src/components/budget/index.tsx',
'./packages/desktop-client/src/components/budget/MobileBudget.tsx',
'./packages/desktop-client/src/components/budget/envelope/HoldMenu.tsx',
'./packages/desktop-client/src/components/budget/envelope/TransferMenu.tsx',
'./packages/desktop-client/src/components/common/Menu.tsx',
'./packages/desktop-client/src/components/FinancesApp.tsx',
'./packages/desktop-client/src/components/GlobalKeys.ts',
'./packages/desktop-client/src/components/LoggedInUser.tsx',
'./packages/desktop-client/src/components/manager/ManagementApp.jsx',
'./packages/desktop-client/src/components/manager/subscribe/common.tsx',
'./packages/desktop-client/src/components/ManageRules.tsx',
'./packages/desktop-client/src/components/mobile/MobileAmountInput.jsx',
'./packages/desktop-client/src/components/mobile/MobileNavTabs.tsx',
'./packages/desktop-client/src/components/Modals.tsx',
'./packages/desktop-client/src/components/modals/EditRule.jsx',
'./packages/desktop-client/src/components/modals/ImportTransactions.jsx',
'./packages/desktop-client/src/components/modals/MergeUnusedPayees.jsx',
'./packages/desktop-client/src/components/Notifications.tsx',
'./packages/desktop-client/src/components/payees/ManagePayees.jsx',
'./packages/desktop-client/src/components/payees/ManagePayeesWithData.jsx',
'./packages/desktop-client/src/components/payees/PayeeTable.tsx',
'./packages/desktop-client/src/components/reports/graphs/tableGraph/ReportTable.tsx',
'./packages/desktop-client/src/components/reports/graphs/tableGraph/ReportTableTotals.tsx',
'./packages/desktop-client/src/components/reports/reports/CashFlowCard.jsx',
'./packages/desktop-client/src/components/reports/reports/CustomReport.jsx',
'./packages/desktop-client/src/components/reports/reports/NetWorthCard.jsx',
'./packages/desktop-client/src/components/reports/SaveReportName.tsx',
'./packages/desktop-client/src/components/reports/useReport.ts',
'./packages/desktop-client/src/components/schedules/ScheduleDetails.jsx',
'./packages/desktop-client/src/components/schedules/SchedulesTable.tsx',
'./packages/desktop-client/src/components/select/DateSelect.tsx',
'./packages/desktop-client/src/components/sidebar/Tools.tsx',
'./packages/desktop-client/src/components/sort.tsx',
'./packages/desktop-client/src/components/spreadsheet/useSheetValue.ts',
'./packages/desktop-client/src/components/table.tsx',
'./packages/desktop-client/src/components/Titlebar.tsx',
'./packages/desktop-client/src/components/transactions/MobileTransaction.jsx',
'./packages/desktop-client/src/components/transactions/SelectedTransactions.jsx',
'./packages/desktop-client/src/components/transactions/SimpleTransactionsTable.jsx',
'./packages/desktop-client/src/components/transactions/TransactionList.jsx',
'./packages/desktop-client/src/components/transactions/TransactionsTable.jsx',
'./packages/desktop-client/src/components/transactions/TransactionsTable.test.jsx',
'./packages/desktop-client/src/hooks/useAccounts.ts',
'./packages/desktop-client/src/hooks/useCategories.ts',
'./packages/desktop-client/src/hooks/usePayees.ts',
'./packages/desktop-client/src/hooks/useProperFocus.tsx',
'./packages/desktop-client/src/hooks/useSelected.tsx',
'./packages/loot-core/src/client/query-hooks.tsx',
],
rules: {
'react-hooks/exhaustive-deps': 'off',
},
},
{
files: [
'.eslintrc.js',
'*.test.js',
'*.test.ts',
'*.test.jsx',
'*.test.tsx',
],
rules: {
'rulesdir/typography': 'off',
},
},
],
settings: {
react: {
version: 'detect',
},
'import/resolver': {
typescript: {
alwaysTryTypes: true,
},
},
},
};

View File

@@ -23,8 +23,6 @@ body:
options:
- label: 'I have searched and found no existing issue'
required: true
- label: 'I will be providing steps how to reproduce the bug (in most cases this will also mean uploading a demo budget file)'
required: true
validations:
required: true
- type: textarea
@@ -36,6 +34,14 @@ body:
value: 'A bug happened!'
validations:
required: true
- type: textarea
id: reproduction
attributes:
label: How can we reproduce the issue?
description: Please give step-by-step instructions on how to reproduce the issue. In most cases this might also require uploading a sample budget/import file.
value: 'How can we reproduce the issue?'
validations:
required: true
- type: markdown
id: env-info
attributes:

View File

@@ -7,6 +7,10 @@ runs:
uses: actions/setup-node@v4
with:
node-version: 18.16.0
- name: Install yarn
run: npm install -g yarn
shell: bash
if: ${{ env.ACT }}
- name: Cache
uses: actions/cache@v4
id: cache

View File

@@ -80,6 +80,7 @@ jobs:
- name: Add to Release
uses: softprops/action-gh-release@v2
with:
draft: true
files: |
packages/desktop-electron/dist/*.dmg
packages/desktop-electron/dist/*.exe

View File

@@ -0,0 +1,36 @@
name: Extract and upload i18n strings
on:
push:
branches:
- master
workflow_dispatch:
jobs:
extract-and-upload-i18n-strings:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Set up environment
uses: ./.github/actions/setup
- name: Configure i18n client
run: |
pip install wlc
- name: Generate i18n strings
run: yarn generate:i18n
- name: Upload i18n strings
run: |
if [[ ! -f packages/desktop-client/locale/en.json ]]; then
echo "File packages/desktop-client/locale/en.json not found. Ensure the file was generated correctly."
exit 1
fi
wlc \
--url https://hosted.weblate.org/api/ \
--key "${{ secrets.WEBLATE_API_KEY_CI_STRINGS }}" \
upload \
--author-name "Actual Budget" \
--author-email "dev@actualbudget.org" \
--method add \
--input packages/desktop-client/locale/en.json \
actualbudget/actual/en
echo "Translations uploaded"

113
.github/workflows/update-vrt.yml vendored Normal file
View File

@@ -0,0 +1,113 @@
name: /update-vrt
on:
issue_comment:
types: [ created ]
permissions:
pull-requests: read
contents: read
concurrency:
group: ${{ github.workflow }}-${{ github.event.issue.number }}-${{ contains(github.event.comment.body, '/update-vrt') }}
cancel-in-progress: true
jobs:
update-vrt:
name: Update VRT
runs-on: ubuntu-latest
if: |
github.event.issue.pull_request &&
contains(github.event.comment.body, '/update-vrt')
container:
image: mcr.microsoft.com/playwright:v1.41.1-jammy
steps:
- name: Get PR branch
# Until https://github.com/xt0rted/pull-request-comment-branch/issues/322 is resolved we use the forked version
uses: gotson/pull-request-comment-branch@head-repo-owner-dist
id: comment-branch
- uses: actions/checkout@v4
with:
repository: ${{ steps.comment-branch.outputs.head_owner }}/${{ steps.comment-branch.outputs.head_repo }}
ref: ${{ steps.comment-branch.outputs.head_ref }}
- name: Set up environment
uses: ./.github/actions/setup
- name: Wait for Netlify build to finish
id: netlify
env:
COMMIT_SHA: ${{ steps.comment-branch.outputs.head_sha }}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: ./.github/actions/netlify-wait-for-build
- name: Run VRT Tests on Netlify URL
run: yarn vrt --update-snapshots
env:
E2E_START_URL: ${{ steps.netlify.outputs.url }}
- name: Create patch
run: |
git config --system --add safe.directory "*"
git config --global user.name "github-actions[bot]"
git config --global user.email "github-actions[bot]@users.noreply.github.com"
git reset
git add "**/*.png"
if git diff --staged --quiet; then
echo "No changes to commit"
exit 0
fi
git commit -m "Update VRT"
git format-patch -1 HEAD --stdout > Update-VRT.patch
- uses: actions/upload-artifact@v4
with:
name: patch
path: Update-VRT.patch
push-patch:
runs-on: ubuntu-latest
needs: update-vrt
permissions:
contents: write
pull-requests: write
steps:
- name: Get PR branch
# Until https://github.com/xt0rted/pull-request-comment-branch/issues/322 is resolved we use the forked version
uses: gotson/pull-request-comment-branch@head-repo-owner-dist
id: comment-branch
- uses: actions/checkout@v4
with:
repository: ${{ steps.comment-branch.outputs.head_owner }}/${{ steps.comment-branch.outputs.head_repo }}
ref: ${{ steps.comment-branch.outputs.head_ref }}
- uses: actions/download-artifact@v4
continue-on-error: true
with:
name: patch
- name: Apply patch and push
run: |
git config --global user.name "github-actions[bot]"
git config --global user.email "github-actions[bot]@users.noreply.github.com"
git apply Update-VRT.patch
git add "**/*.png"
if git diff --staged --quiet; then
echo "No changes to commit"
exit 0
fi
git commit -m "Update VRT"
git push origin HEAD:${{ steps.comment-branch.outputs.head_ref }}
- name: Add finished reaction
uses: dkershner6/reaction-action@v2
with:
token: ${{ secrets.GITHUB_TOKEN }}
commentId: ${{ github.event.comment.id }}
reaction: "rocket"
add-starting-reaction:
runs-on: ubuntu-latest
if: |
github.event.issue.pull_request &&
contains(github.event.comment.body, '/update-vrt')
permissions:
pull-requests: write
steps:
- name: React to comment
uses: dkershner6/reaction-action@v2
with:
token: ${{ secrets.GITHUB_TOKEN }}
commentId: ${{ github.event.comment.id }}
reaction: "+1"

View File

@@ -36,7 +36,7 @@ fi
yarn workspace loot-core build:node
yarn workspace @actual-app/web build --mode=desktop
yarn workspace @actual-app/web build --mode=desktop # electron specific build
yarn workspace desktop-electron update-client

789
eslint.config.mjs Normal file
View File

@@ -0,0 +1,789 @@
import path from 'node:path';
import { fileURLToPath } from 'node:url';
import globals from 'globals';
import pluginImport from 'eslint-plugin-import';
import pluginJSXA11y from 'eslint-plugin-jsx-a11y';
import pluginPrettier from 'eslint-plugin-prettier/recommended';
import pluginReact from 'eslint-plugin-react';
import pluginReactHooks from 'eslint-plugin-react-hooks';
import pluginRulesDir from 'eslint-plugin-rulesdir';
import pluginTypescript from 'typescript-eslint';
import tsParser from '@typescript-eslint/parser';
const __filename = fileURLToPath(import.meta.url);
const __dirname = path.dirname(__filename);
pluginRulesDir.RULES_DIR = path.join(
__dirname,
'packages',
'eslint-plugin-actual',
'lib',
'rules',
);
const confusingBrowserGlobals = [
// https://github.com/facebook/create-react-app/tree/main/packages/confusing-browser-globals
'addEventListener',
'blur',
'close',
'closed',
'confirm',
'defaultStatus',
'defaultstatus',
'event',
'external',
'find',
'focus',
'frameElement',
'frames',
'history',
'innerHeight',
'innerWidth',
'length',
'location',
'locationbar',
'menubar',
'moveBy',
'moveTo',
'name',
'onblur',
'onerror',
'onfocus',
'onload',
'onresize',
'onunload',
'open',
'opener',
'opera',
'outerHeight',
'outerWidth',
'pageXOffset',
'pageYOffset',
'parent',
'print',
'removeEventListener',
'resizeBy',
'resizeTo',
'screen',
'screenLeft',
'screenTop',
'screenX',
'screenY',
'scroll',
'scrollbars',
'scrollBy',
'scrollTo',
'scrollX',
'scrollY',
'status',
'statusbar',
'stop',
'toolbar',
'top',
];
/** @type {import('eslint').Linter.Config[]} */
export default [
{
ignores: [
'packages/api/app/bundle.api.js',
'packages/api/dist',
'packages/api/@types',
'packages/api/migrations',
'packages/crdt/dist',
'packages/desktop-client/bundle.browser.js',
'packages/desktop-client/build/',
'packages/desktop-client/build-electron/',
'packages/desktop-client/build-stats/',
'packages/desktop-client/public/kcab/',
'packages/desktop-client/public/data/',
'packages/desktop-client/**/node_modules/*',
'packages/desktop-client/node_modules/',
'packages/desktop-client/src/icons/**/*',
'packages/desktop-client/test-results/',
'packages/desktop-client/playwright-report/',
'packages/desktop-electron/client-build/',
'packages/desktop-electron/build/',
'packages/desktop-electron/dist/',
'packages/import-ynab4/**/node_modules/*',
'packages/import-ynab5/**/node_modules/*',
'packages/loot-core/**/node_modules/*',
'packages/loot-core/**/lib-dist/*',
'packages/loot-core/**/proto/*',
'.yarn/*',
'.github/*',
],
},
{
linterOptions: {
reportUnusedDisableDirectives: true,
},
languageOptions: {
globals: {
...globals.browser,
...globals.commonjs,
...globals.jest,
...globals.node,
globalThis: false,
vi: true,
},
},
settings: {
react: {
version: 'detect',
},
'import/resolver': {
typescript: {
alwaysTryTypes: true,
},
},
},
},
pluginReact.configs.flat.recommended,
pluginReact.configs.flat['jsx-runtime'],
pluginPrettier,
...pluginTypescript.configs.recommended,
pluginImport.flatConfigs.recommended,
{
plugins: {
'react-hooks': pluginReactHooks,
'jsx-a11y': pluginJSXA11y,
rulesdir: pluginRulesDir,
},
},
{
files: ['**/*.{js,ts,jsx,tsx}'],
rules: {
// http://eslint.org/docs/rules/
'array-callback-return': 'warn',
'default-case': [
'warn',
{
commentPattern: '^no default$',
},
],
curly: ['warn', 'multi-line', 'consistent'],
'dot-location': ['warn', 'property'],
eqeqeq: ['warn', 'smart'],
'new-parens': 'warn',
'no-array-constructor': 'warn',
'no-caller': 'warn',
'no-cond-assign': ['warn', 'except-parens'],
'no-const-assign': 'warn',
'no-control-regex': 'warn',
'no-delete-var': 'warn',
'no-dupe-args': 'warn',
'no-dupe-class-members': 'warn',
'no-dupe-keys': 'warn',
'no-duplicate-case': 'warn',
'no-empty-character-class': 'warn',
'no-empty-pattern': 'warn',
'no-eval': 'warn',
'no-ex-assign': 'warn',
'no-extend-native': 'warn',
'no-extra-bind': 'warn',
'no-extra-label': 'warn',
'no-fallthrough': 'warn',
'no-func-assign': 'warn',
'no-implied-eval': 'warn',
'no-invalid-regexp': 'warn',
'no-iterator': 'warn',
'no-label-var': 'warn',
'no-labels': [
'warn',
{
allowLoop: true,
allowSwitch: false,
},
],
'no-lone-blocks': 'warn',
'no-mixed-operators': [
'warn',
{
groups: [
['&', '|', '^', '~', '<<', '>>', '>>>'],
['==', '!=', '===', '!==', '>', '>=', '<', '<='],
['&&', '||'],
['in', 'instanceof'],
],
allowSamePrecedence: false,
},
],
'no-multi-str': 'warn',
'no-global-assign': 'warn',
'no-unsafe-negation': 'warn',
'no-new-func': 'warn',
'no-new-object': 'warn',
'no-new-symbol': 'warn',
'no-new-wrappers': 'warn',
'no-obj-calls': 'warn',
'no-octal': 'warn',
'no-octal-escape': 'warn',
'no-redeclare': 'warn',
'no-regex-spaces': 'warn',
'no-script-url': 'warn',
'no-self-assign': 'warn',
'no-self-compare': 'warn',
'no-sequences': 'warn',
'no-shadow-restricted-names': 'warn',
'no-sparse-arrays': 'warn',
'no-template-curly-in-string': 'warn',
'no-this-before-super': 'warn',
'no-throw-literal': 'warn',
'no-undef': 'error',
'no-unreachable': 'warn',
'no-unused-expressions': [
'error',
{
allowShortCircuit: true,
allowTernary: true,
allowTaggedTemplates: true,
},
],
'no-unused-labels': 'warn',
'no-use-before-define': [
'warn',
{
functions: false,
classes: false,
variables: false,
},
],
'no-useless-computed-key': 'warn',
'no-useless-concat': 'warn',
'no-useless-constructor': 'warn',
'no-useless-escape': 'warn',
'no-useless-rename': [
'warn',
{
ignoreDestructuring: false,
ignoreImport: false,
ignoreExport: false,
},
],
'no-with': 'warn',
'no-whitespace-before-property': 'warn',
'require-yield': 'warn',
'rest-spread-spacing': ['warn', 'never'],
strict: ['warn', 'never'],
'unicode-bom': ['warn', 'never'],
'use-isnan': 'warn',
'valid-typeof': 'warn',
'no-restricted-properties': [
'error',
{
object: 'require',
property: 'ensure',
message:
'Please use import() instead. More info: https://facebook.github.io/create-react-app/docs/code-splitting',
},
{
object: 'System',
property: 'import',
message:
'Please use import() instead. More info: https://facebook.github.io/create-react-app/docs/code-splitting',
},
],
'getter-return': 'warn',
// https://github.com/benmosher/eslint-plugin-import/tree/master/docs/rules
'import/first': 'error',
'import/no-amd': 'error',
'import/no-anonymous-default-export': 'warn',
'import/no-webpack-loader-syntax': 'error',
'import/extensions': [
'warn',
'never',
{
json: 'always',
},
],
'import/no-useless-path-segments': 'warn',
'import/no-duplicates': [
'warn',
{
'prefer-inline': true,
},
],
'import/order': [
'warn',
{
alphabetize: {
caseInsensitive: true,
order: 'asc',
},
groups: ['builtin', 'external', 'parent', 'sibling', 'index'],
'newlines-between': 'always',
pathGroups: [
{
// Enforce that React (and react-related packages) is the first import
group: 'builtin',
pattern: 'react?(-*)',
position: 'before',
},
{
// Separate imports from Actual from "real" external imports
group: 'external',
pattern: 'loot-{core,design}/**/*',
position: 'after',
},
],
pathGroupsExcludedImportTypes: ['react'],
},
],
// https://github.com/yannickcr/eslint-plugin-react/tree/master/docs/rules
'react/forbid-foreign-prop-types': [
'warn',
{
allowInPropTypes: true,
},
],
'react/jsx-no-comment-textnodes': 'warn',
'react/jsx-no-duplicate-props': 'warn',
'react/jsx-no-target-blank': 'warn',
'react/jsx-no-undef': 'error',
'react/jsx-pascal-case': [
'warn',
{
allowAllCaps: true,
ignore: [],
},
],
'react/no-danger-with-children': 'warn',
// Disabled because of undesirable warnings
// See https://github.com/facebook/create-react-app/issues/5204 for
// blockers until its re-enabled
// 'react/no-deprecated': 'warn',
'react/no-direct-mutation-state': 'warn',
'react/no-is-mounted': 'warn',
'react/no-typos': 'error',
'react/require-render-return': 'error',
'react/style-prop-object': 'warn',
'react/jsx-no-useless-fragment': 'warn',
'react/self-closing-comp': 'warn',
'react/jsx-filename-extension': [
'warn',
{
extensions: ['.jsx', '.tsx'],
allow: 'as-needed',
},
],
'react/no-unstable-nested-components': [
'warn',
{
allowAsProps: true,
customValidators: ['formatter'],
},
],
// Don't need this as we're using TypeScript
'react/prop-types': 'off',
// https://github.com/evcohen/eslint-plugin-jsx-a11y/tree/master/docs/rules
'jsx-a11y/alt-text': 'warn',
'jsx-a11y/anchor-has-content': 'warn',
'jsx-a11y/anchor-is-valid': [
'warn',
{
aspects: ['noHref', 'invalidHref'],
},
],
'jsx-a11y/aria-activedescendant-has-tabindex': 'warn',
'jsx-a11y/aria-props': 'warn',
'jsx-a11y/aria-proptypes': 'warn',
'jsx-a11y/aria-role': [
'warn',
{
ignoreNonDOM: true,
},
],
'jsx-a11y/aria-unsupported-elements': 'warn',
'jsx-a11y/heading-has-content': 'warn',
'jsx-a11y/iframe-has-title': 'warn',
'jsx-a11y/img-redundant-alt': 'warn',
'jsx-a11y/no-access-key': 'warn',
'jsx-a11y/no-distracting-elements': 'warn',
'jsx-a11y/no-redundant-roles': 'warn',
'jsx-a11y/role-has-required-aria-props': 'warn',
'jsx-a11y/role-supports-aria-props': 'warn',
'jsx-a11y/scope': 'warn',
// https://github.com/facebook/react/tree/main/packages/eslint-plugin-react-hooks
'react-hooks/rules-of-hooks': 'error',
'react-hooks/exhaustive-deps': [
'warn',
{
additionalHooks: '(useQuery)',
},
],
'rulesdir/typography': 'warn',
'rulesdir/prefer-if-statement': 'warn',
// Note: base rule explicitly disabled in favor of the TS one
'no-unused-vars': 'off',
'@typescript-eslint/no-unused-vars': [
'warn',
{
varsIgnorePattern: '^(_|React)',
ignoreRestSiblings: true,
caughtErrors: 'none',
},
],
'no-restricted-globals': ['warn', ...confusingBrowserGlobals],
// https://github.com/eslint/eslint/issues/16954
// https://github.com/eslint/eslint/issues/16953
'no-loop-func': 'off',
// TODO: re-enable these rules
'react/react-in-jsx-scope': 'off',
'no-var': 'warn',
'react/jsx-curly-brace-presence': 'warn',
'object-shorthand': ['warn', 'properties'],
'no-restricted-syntax': [
'warn',
{
// forbid React.* as they are legacy https://twitter.com/dan_abramov/status/1308739731551858689
selector:
":matches(MemberExpression[object.name='React'], TSQualifiedName[left.name='React'])",
message:
'Using default React import is discouraged, please use named exports directly instead.',
},
{
// forbid <a> in favor of <Link>
selector: 'JSXOpeningElement[name.name="a"]',
message: 'Using <a> is discouraged, please use <Link> instead.',
},
],
'no-restricted-imports': [
'warn',
{
patterns: [
{
group: ['*.api', '*.web', '*.electron'],
message: "Don't directly reference imports from other platforms",
},
{
group: ['uuid'],
importNames: ['*'],
message: "Use `import { v4 as uuidv4 } from 'uuid'` instead",
},
{
group: ['**/style', '**/colors'],
importNames: ['colors'],
message: 'Please use themes instead of colors',
},
],
},
],
'@typescript-eslint/ban-ts-comment': [
'error',
{
'ts-ignore': 'allow-with-description',
},
],
// Rules disabled during TS migration
'@typescript-eslint/no-var-requires': 'off',
'prefer-const': 'warn',
'prefer-spread': 'off',
'@typescript-eslint/no-empty-function': 'off',
'@typescript-eslint/no-require-imports': 'off',
'import/no-default-export': 'warn',
},
},
{
files: ['**/*.ts?(x)'],
languageOptions: {
parser: tsParser,
ecmaVersion: 2018,
sourceType: 'module',
parserOptions: {
project: [path.join(__dirname, './tsconfig.json')],
ecmaFeatures: {
jsx: true,
},
// typescript-eslint specific options
warnOnUnsupportedTypeScriptVersion: true,
},
},
// If adding a typescript-eslint version of an existing ESLint rule,
// make sure to disable the ESLint rule here.
rules: {
// TypeScript's `noFallthroughCasesInSwitch` option is more robust (#6906)
'default-case': 'off',
// 'tsc' already handles this (https://github.com/typescript-eslint/typescript-eslint/issues/291)
'no-dupe-class-members': 'off',
// 'tsc' already handles this (https://github.com/typescript-eslint/typescript-eslint/issues/477)
'no-undef': 'off',
// Add TypeScript specific rules (and turn off ESLint equivalents)
'@typescript-eslint/consistent-type-assertions': 'warn',
'no-array-constructor': 'off',
'@typescript-eslint/no-array-constructor': 'warn',
'no-redeclare': 'off',
'@typescript-eslint/no-redeclare': 'warn',
'no-use-before-define': 'off',
'@typescript-eslint/no-use-before-define': [
'warn',
{
functions: false,
classes: false,
variables: false,
typedefs: false,
},
],
'no-unused-expressions': 'off',
'@typescript-eslint/no-unused-expressions': [
'error',
{
allowShortCircuit: true,
allowTernary: true,
allowTaggedTemplates: true,
},
],
'no-useless-constructor': 'off',
'@typescript-eslint/no-useless-constructor': 'warn',
},
},
{
files: [
'packages/desktop-client/**/*.{ts,tsx}',
'packages/loot-core/src/client/**/*.{ts,tsx}',
],
rules: {
// enforce type over interface
'@typescript-eslint/consistent-type-definitions': ['warn', 'type'],
// enforce import type
'@typescript-eslint/consistent-type-imports': [
'warn',
{
prefer: 'type-imports',
fixStyle: 'inline-type-imports',
},
],
'@typescript-eslint/no-restricted-types': [
'warn',
{
types: {
// forbid FC as superflous
FunctionComponent: {
message:
'Type the props argument and let TS infer or use ComponentType for a component prop',
},
FC: {
message:
'Type the props argument and let TS infer or use ComponentType for a component prop',
},
},
},
],
},
},
{
files: ['packages/desktop-client/**/*'],
ignores: ['packages/desktop-client/src/hooks/useNavigate.{ts,tsx}'],
rules: {
'no-restricted-imports': [
'warn',
{
patterns: [
{
group: ['react-router-dom'],
importNames: ['useNavigate'],
message: "Please use Actual's useNavigate() hook instead.",
},
],
},
],
},
},
{
files: ['packages/loot-core/src/**/*'],
rules: {
'no-restricted-imports': [
'warn',
{
patterns: [
{
group: ['*.api', '*.web', '*.electron'],
message: "Don't directly reference imports from other platforms",
},
{
group: ['uuid'],
importNames: ['*'],
message: "Use `import { v4 as uuidv4 } from 'uuid'` instead",
},
{
group: ['loot-core/**'],
message:
'Please use relative imports in loot-core instead of importing from `loot-core/*`',
},
],
},
],
},
},
{
files: [
'packages/loot-core/src/types/**/*',
'packages/loot-core/src/client/state-types/**/*',
'**/icons/**/*',
'**/{mocks,__mocks__}/**/*',
// can't correctly resolve usages
'**/*.{testing,electron,browser,web,api}.ts',
],
rules: {
'import/no-unused-modules': 'off',
},
},
{
files: [
'packages/desktop-client/src/style/index.*',
'packages/desktop-client/src/style/palette.*',
],
rules: {
'no-restricted-imports': [
'off',
{
patterns: [
{
group: ['**/style', '**/colors'],
importNames: ['colors'],
message: 'Please use themes instead of colors',
},
],
},
],
},
},
{
files: ['packages/api/migrations/*', 'packages/loot-core/migrations/*'],
rules: {
'import/no-default-export': 'off',
},
},
{},
{
// TODO: fix the issues in these files
files: [
'packages/desktop-client/src/components/accounts/Account.jsx',
'packages/desktop-client/src/components/accounts/MobileAccount.jsx',
'packages/desktop-client/src/components/accounts/MobileAccounts.jsx',
'packages/desktop-client/src/components/App.tsx',
'packages/desktop-client/src/components/budget/BudgetCategories.jsx',
'packages/desktop-client/src/components/budget/BudgetSummaries.tsx',
'packages/desktop-client/src/components/budget/DynamicBudgetTable.tsx',
'packages/desktop-client/src/components/budget/index.tsx',
'packages/desktop-client/src/components/budget/MobileBudget.tsx',
'packages/desktop-client/src/components/budget/envelope/HoldMenu.tsx',
'packages/desktop-client/src/components/budget/envelope/TransferMenu.tsx',
'packages/desktop-client/src/components/common/Menu.tsx',
'packages/desktop-client/src/components/FinancesApp.tsx',
'packages/desktop-client/src/components/GlobalKeys.ts',
'packages/desktop-client/src/components/LoggedInUser.tsx',
'packages/desktop-client/src/components/manager/ManagementApp.jsx',
'packages/desktop-client/src/components/manager/subscribe/common.tsx',
'packages/desktop-client/src/components/ManageRules.tsx',
'packages/desktop-client/src/components/mobile/MobileAmountInput.jsx',
'packages/desktop-client/src/components/mobile/MobileNavTabs.tsx',
'packages/desktop-client/src/components/Modals.tsx',
'packages/desktop-client/src/components/modals/EditRule.jsx',
'packages/desktop-client/src/components/modals/ImportTransactions.jsx',
'packages/desktop-client/src/components/modals/MergeUnusedPayees.jsx',
'packages/desktop-client/src/components/Notifications.tsx',
'packages/desktop-client/src/components/payees/ManagePayees.jsx',
'packages/desktop-client/src/components/payees/ManagePayeesWithData.jsx',
'packages/desktop-client/src/components/payees/PayeeTable.tsx',
'packages/desktop-client/src/components/reports/graphs/tableGraph/ReportTable.tsx',
'packages/desktop-client/src/components/reports/graphs/tableGraph/ReportTableTotals.tsx',
'packages/desktop-client/src/components/reports/reports/CashFlowCard.jsx',
'packages/desktop-client/src/components/reports/reports/CustomReport.jsx',
'packages/desktop-client/src/components/reports/reports/NetWorthCard.jsx',
'packages/desktop-client/src/components/reports/SaveReportName.tsx',
'packages/desktop-client/src/components/reports/useReport.ts',
'packages/desktop-client/src/components/schedules/ScheduleDetails.jsx',
'packages/desktop-client/src/components/schedules/SchedulesTable.tsx',
'packages/desktop-client/src/components/select/DateSelect.tsx',
'packages/desktop-client/src/components/sidebar/Tools.tsx',
'packages/desktop-client/src/components/sort.tsx',
'packages/desktop-client/src/components/spreadsheet/useSheetValue.ts',
'packages/desktop-client/src/components/table.tsx',
'packages/desktop-client/src/components/Titlebar.tsx',
'packages/desktop-client/src/components/transactions/MobileTransaction.jsx',
'packages/desktop-client/src/components/transactions/SelectedTransactions.jsx',
'packages/desktop-client/src/components/transactions/SimpleTransactionsTable.jsx',
'packages/desktop-client/src/components/transactions/TransactionList.jsx',
'packages/desktop-client/src/components/transactions/TransactionsTable.jsx',
'packages/desktop-client/src/components/transactions/TransactionsTable.test.jsx',
'packages/desktop-client/src/hooks/useAccounts.ts',
'packages/desktop-client/src/hooks/useCategories.ts',
'packages/desktop-client/src/hooks/usePayees.ts',
'packages/desktop-client/src/hooks/useProperFocus.tsx',
'packages/desktop-client/src/hooks/useSelected.tsx',
'packages/loot-core/src/client/query-hooks.tsx',
],
rules: {
'react-hooks/exhaustive-deps': 'off',
},
},
{
files: [
'eslint.config.mjs',
'**/*.test.js',
'**/*.test.ts',
'**/*.test.jsx',
'**/*.test.tsx',
],
rules: {
'rulesdir/typography': 'off',
},
},
];

View File

@@ -38,33 +38,33 @@
"vrt:docker": "./bin/run-vrt",
"rebuild-electron": "./node_modules/.bin/electron-rebuild -f -m ./packages/loot-core",
"rebuild-node": "yarn workspace loot-core rebuild",
"lint": "eslint . --max-warnings 0 --ext .js,.jsx,.ts,.tsx",
"lint": "eslint . --max-warnings 0",
"lint:verbose": "DEBUG=eslint:cli-engine eslint . --max-warnings 0",
"typecheck": "yarn tsc && tsc-strict",
"jq": "./node_modules/node-jq/bin/jq",
"prepare": "husky"
},
"devDependencies": {
"@typescript-eslint/eslint-plugin": "^8.1.0",
"@typescript-eslint/parser": "^8.1.0",
"confusing-browser-globals": "^1.0.11",
"@typescript-eslint/parser": "^8.18.1",
"cross-env": "^7.0.3",
"eslint": "^8.57.0",
"eslint": "^9.17.0",
"eslint-config-prettier": "^9.1.0",
"eslint-import-resolver-typescript": "3.6.1",
"eslint-plugin-import": "2.29.1",
"eslint-plugin-jsx-a11y": "^6.9.0",
"eslint-import-resolver-typescript": "^3.7.0",
"eslint-plugin-import": "^2.31.0",
"eslint-plugin-jsx-a11y": "^6.10.2",
"eslint-plugin-prettier": "5.2.1",
"eslint-plugin-react": "7.35.0",
"eslint-plugin-react-hooks": "^4.6.2",
"eslint-plugin-react": "^7.37.2",
"eslint-plugin-react-hooks": "^5.1.0",
"eslint-plugin-rulesdir": "^0.2.2",
"globals": "^15.13.0",
"husky": "^9.0.11",
"lint-staged": "^15.2.9",
"node-jq": "^4.0.1",
"npm-run-all": "^4.1.5",
"prettier": "3.3.3",
"prettier": "^3.4.2",
"source-map-support": "^0.5.21",
"typescript": "^5.5.4",
"typescript-eslint": "^8.18.1",
"typescript-strict-plugin": "^2.4.4"
},
"resolutions": {

View File

@@ -8,7 +8,7 @@ import type {
import type { InitConfig } from 'loot-core/server/main';
// @ts-ignore: bundle not available until we build it
// eslint-disable-next-line import/extensions
// eslint-disable-next-line import/extensions, import/no-unresolved
import * as bundle from './app/bundle.api.js';
import * as injected from './injected';
import { validateNodeVersion } from './validateNodeVersion';

View File

@@ -86,7 +86,10 @@ export function addTransactions(
}
export function importTransactions(accountId, transactions) {
return send('api/transactions-import', { accountId, transactions });
return send('api/transactions-import', {
accountId,
transactions,
});
}
export function getTransactions(accountId, startDate, endDate) {

View File

@@ -1,6 +1,6 @@
{
"name": "@actual-app/api",
"version": "24.11.0",
"version": "25.1.0",
"license": "MIT",
"description": "An API for Actual",
"engines": {
@@ -23,7 +23,7 @@
},
"dependencies": {
"@actual-app/crdt": "workspace:^",
"better-sqlite3": "^9.6.0",
"better-sqlite3": "^11.7.0",
"compare-versions": "^6.1.0",
"node-fetch": "^3.3.2",
"uuid": "^9.0.1"

View File

@@ -10,6 +10,7 @@ playwright-report
# production
build
build-electron
build-stats
stats.json
@@ -24,3 +25,6 @@ public/kcab
public/data
public/data-file-index.txt
public/*.wasm
# translations
locale/

View File

@@ -27,6 +27,7 @@ test.describe('Mobile Accounts', () => {
test('opens the accounts page and asserts on balances', async () => {
const accountsPage = await navigation.goToAccountsPage();
await accountsPage.waitFor();
const account = await accountsPage.getNthAccount(1);
@@ -37,7 +38,10 @@ test.describe('Mobile Accounts', () => {
test('opens individual account page and checks that filtering is working', async () => {
const accountsPage = await navigation.goToAccountsPage();
await accountsPage.waitFor();
const accountPage = await accountsPage.openNthAccount(0);
await accountPage.waitFor();
await expect(accountPage.heading).toHaveText('Bank of America');
await expect(accountPage.transactionList).toBeVisible();
@@ -50,6 +54,9 @@ test.describe('Mobile Accounts', () => {
await expect(accountPage.transactions).toHaveCount(0);
await expect(page).toMatchThemeScreenshots();
await accountPage.clearSearch();
await expect(accountPage.transactions).not.toHaveCount(0);
await accountPage.searchByText('Kroger');
await expect(accountPage.transactions).not.toHaveCount(0);
await expect(page).toMatchThemeScreenshots();

Binary file not shown.

Before

Width:  |  Height:  |  Size: 35 KiB

After

Width:  |  Height:  |  Size: 34 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 35 KiB

After

Width:  |  Height:  |  Size: 33 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 35 KiB

After

Width:  |  Height:  |  Size: 33 KiB

View File

@@ -54,15 +54,17 @@ test.describe('Accounts', () => {
await expect(page).toMatchThemeScreenshots();
});
test.describe('Budgeted Accounts', () => {
test.describe('On Budget Accounts', () => {
// Reset filters
test.afterEach(async () => {
await accountPage.removeFilter(0);
});
test('creates a transfer from two existing transactions', async () => {
accountPage = await navigation.goToAccountPage('For budget');
await expect(accountPage.accountName).toHaveText('Budgeted Accounts');
accountPage = await navigation.goToAccountPage('On budget');
await accountPage.waitFor();
await expect(accountPage.accountName).toHaveText('On Budget Accounts');
await accountPage.filterByNote('Test Acc Transfer');
@@ -109,6 +111,7 @@ test.describe('Accounts', () => {
offBudget: false,
balance: 0,
});
await accountPage.waitFor();
});
async function importCsv(screenshot = false) {

Binary file not shown.

Before

Width:  |  Height:  |  Size: 171 KiB

After

Width:  |  Height:  |  Size: 171 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 166 KiB

After

Width:  |  Height:  |  Size: 166 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 168 KiB

After

Width:  |  Height:  |  Size: 168 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 153 KiB

After

Width:  |  Height:  |  Size: 153 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 152 KiB

After

Width:  |  Height:  |  Size: 152 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 151 KiB

After

Width:  |  Height:  |  Size: 151 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 197 KiB

After

Width:  |  Height:  |  Size: 197 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 190 KiB

After

Width:  |  Height:  |  Size: 190 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 190 KiB

After

Width:  |  Height:  |  Size: 190 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 117 KiB

After

Width:  |  Height:  |  Size: 116 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 116 KiB

After

Width:  |  Height:  |  Size: 116 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 117 KiB

After

Width:  |  Height:  |  Size: 117 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 56 KiB

After

Width:  |  Height:  |  Size: 56 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 56 KiB

After

Width:  |  Height:  |  Size: 56 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 55 KiB

After

Width:  |  Height:  |  Size: 55 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 27 KiB

After

Width:  |  Height:  |  Size: 26 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 29 KiB

After

Width:  |  Height:  |  Size: 29 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 29 KiB

After

Width:  |  Height:  |  Size: 28 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 27 KiB

After

Width:  |  Height:  |  Size: 27 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 30 KiB

After

Width:  |  Height:  |  Size: 30 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 30 KiB

After

Width:  |  Height:  |  Size: 29 KiB

View File

@@ -27,12 +27,12 @@ test.describe('Budget', () => {
test('renders the summary information: available funds, overspent, budgeted and for next month', async () => {
const summary = budgetPage.budgetSummary.first();
await expect(summary.getByText('Available Funds')).toBeVisible({
await expect(summary.getByText('Available funds')).toBeVisible({
timeout: 10000,
});
await expect(summary.getByText(/^Overspent in /)).toBeVisible();
await expect(summary.getByText('Budgeted')).toBeVisible();
await expect(summary.getByText('For Next Month')).toBeVisible();
await expect(summary.getByText('For next month')).toBeVisible();
await expect(page).toMatchThemeScreenshots();
});

Binary file not shown.

Before

Width:  |  Height:  |  Size: 84 KiB

After

Width:  |  Height:  |  Size: 84 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 84 KiB

After

Width:  |  Height:  |  Size: 84 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 84 KiB

After

Width:  |  Height:  |  Size: 84 KiB

View File

@@ -30,6 +30,10 @@ export class AccountPage {
this.selectTooltip = this.page.getByTestId('transactions-select-tooltip');
}
async waitFor() {
await this.transactionTable.waitFor();
}
/**
* Enter details of a transaction
*/

View File

@@ -15,6 +15,10 @@ export class MobileAccountPage {
});
}
async waitFor() {
await this.transactionList.waitFor();
}
/**
* Retrieve the balance of the account as a number
*/
@@ -29,6 +33,10 @@ export class MobileAccountPage {
await this.searchBox.fill(term);
}
async clearSearch() {
await this.searchBox.clear();
}
/**
* Go to transaction creation page
*/

View File

@@ -4,9 +4,14 @@ export class MobileAccountsPage {
constructor(page) {
this.page = page;
this.accountList = this.page.getByLabel('Account list');
this.accounts = this.page.getByTestId('account');
}
async waitFor() {
await this.accountList.waitFor();
}
/**
* Get the name and balance of the nth account
*/

View File

@@ -34,7 +34,7 @@ export class MobileBudgetPage {
name: 'Saved',
});
this.projectedSavingsButton = this.budgetTableHeader.getByRole('button', {
name: 'Projected Savings',
name: 'Projected savings',
});
this.overspentButton = this.budgetTableHeader.getByRole('button', {
name: 'Overspent',
@@ -294,7 +294,7 @@ export class MobileBudgetPage {
}
throw new Error(
'None of “Saved”, “Projected Savings”, or “Overspent” buttons could be located on the page',
'None of “Saved”, “Projected savings”, or “Overspent” buttons could be located on the page',
);
}

View File

@@ -1,3 +1,4 @@
import { MobileAccountPage } from './mobile-account-page';
import { MobileAccountsPage } from './mobile-accounts-page';
import { MobileBudgetPage } from './mobile-budget-page';
import { MobileTransactionEntryPage } from './mobile-transaction-entry-page';
@@ -22,6 +23,13 @@ export class MobileNavigation {
return new MobileAccountsPage(this.page);
}
async goToUncategorizedPage() {
const button = this.page.getByRole('button', { name: /uncategorized/ });
await button.click();
return new MobileAccountPage(this.page);
}
async goToTransactionEntryPage() {
const link = this.page.getByRole('link', { name: 'Transaction' });
await link.click();

View File

@@ -58,7 +58,7 @@ export class Navigation {
async createAccount(data) {
await this.page.getByRole('button', { name: 'Add account' }).click();
await this.page
.getByRole('button', { name: 'Create local account' })
.getByRole('button', { name: 'Create a local account' })
.click();
// Fill the form
@@ -66,7 +66,7 @@ export class Navigation {
await this.page.getByLabel('Balance:').fill(String(data.balance));
if (data.offBudget) {
await this.page.getByLabel('Off-budget').click();
await this.page.getByLabel('Off budget').click();
}
await this.page

View File

@@ -22,8 +22,9 @@ export class ReportsPage {
async goToCustomReportPage() {
await this.pageContent
.getByRole('button', { name: 'Create new custom report' })
.getByRole('button', { name: 'Add new widget' })
.click();
await this.page.getByRole('button', { name: 'New custom report' }).click();
return new CustomReportPage(this.page);
}

View File

@@ -8,27 +8,10 @@ export class SettingsPage {
}
async useBudgetType(budgetType) {
await this.enableExperimentalFeature('Budget mode toggle');
const switchBudgetTypeButton = this.page.getByRole('button', {
name: `Switch to ${budgetType} budgeting`,
});
await switchBudgetTypeButton.click();
}
async enableExperimentalFeature(featureName) {
const advancedSettingsButton = this.page.getByTestId('advanced-settings');
await advancedSettingsButton.click();
const experimentalSettingsButton = this.page.getByTestId(
'experimental-settings',
);
await experimentalSettingsButton.click();
const featureCheckbox = this.page.getByRole('checkbox', {
name: featureName,
});
await featureCheckbox.click();
}
}

Binary file not shown.

Before

Width:  |  Height:  |  Size: 110 KiB

After

Width:  |  Height:  |  Size: 110 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 110 KiB

After

Width:  |  Height:  |  Size: 110 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 109 KiB

After

Width:  |  Height:  |  Size: 109 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 103 KiB

After

Width:  |  Height:  |  Size: 103 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 104 KiB

After

Width:  |  Height:  |  Size: 104 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 103 KiB

After

Width:  |  Height:  |  Size: 103 KiB

Some files were not shown because too many files have changed in this diff Show More