Commit Graph

568 Commits

Author SHA1 Message Date
Jed Fox
15e9c0405d Upgrade @typescript-eslint packages (#884) 2023-04-11 13:48:20 -04:00
Alberto Gasparin
cd00da76ef Convert commonjs to esm (#877)
This PR converts everything (aside from electron) from CommonJS to ESM.
It is needed to reduce the changes that will happen during the migration
to Typescript (as TS does not play nice with CJS).

Basically:
- rewrite `require()` to `import`
- rewrite `module.exports` to `exports`
- introduce `ts-node` to run importers so we can convert them to TS too

Lastly, sorry for this larg-ish PR, not my preference but when I tried
to reduce its scope, I would end up with mixed commons/esm that was even
more tricky to handle.
2023-04-10 20:40:40 +01:00
Jed Fox
d7d5820c1c Recognize numpad enter key as enter key (#883) 2023-04-10 08:36:02 -04:00
Matiss Janis Aboltins
82482f4182 🐛 (autocomplete) show 'create payee' only if no payee matched (#881) 2023-04-09 22:00:43 +01:00
Matiss Janis Aboltins
88fb95b230 🐛 (rules) creation from account page (#882) 2023-04-09 20:33:41 +01:00
Matiss Janis Aboltins
7e33cda7b2 🔖 (api) 5.1.2 (#880)
<!-- Thank you for submitting a pull request! Make sure to follow the
instructions to write release notes for your PR — it should only take a
minute or two:
https://github.com/actualbudget/docs#writing-good-release-notes -->
2023-04-09 19:29:44 +01:00
Jed Fox
bf05b759aa Remove duplicate migration and default-db.sqlite files (#870)
These files will be automatically recreated by `yarn build:api`,
`yarn build:browser`, and `yarn start:browser`, so we don’t need
them in the repo.
2023-04-09 14:21:59 -04:00
Jakub Kuczys
835c1a54f7 Use Unicode-aware implementations of LOWER() and UPPER() in SQL queries (#865)
Fixes #840 by creating application-defined SQL functions
(https://www.sqlite.org/appfunc.html) for Unicode-aware implementations
of `LOWER()` and `UPPER()`. This uses
`String.prototype.toLower/UpperCase()` JS method.

I initially wanted to just redefine `LOWER()` and `UPPER()` but due to
[sql.js not supporting the definition of deterministic
functions](https://github.com/sql-js/sql.js/issues/551), I had to just
define them as separate functions and use that in the appropriate
places. It's probably better like that anyway...
2023-04-07 16:33:19 -04:00
Jed Fox
aa2e837e7e Don’t check for release notes on release/* branches (#864) 2023-04-07 16:15:12 -04:00
Jed Fox
98a32432ef Disable ESLint in CI again (#869)
This should speed up builds in CI, and must not have gotten caught when
upgrading `react-scripts`.
ref: arackaf/customize-cra#278
2023-04-07 16:15:00 -04:00
Matiss Janis Aboltins
7abbdcc5bb 🔖 (5.1.1) api (#873) 2023-04-07 21:11:12 +01:00
shall0pass
adf205db86 Allow goal template 'by' matches to compound (#860)
I believe this change allows for having multiple 'by' rules in the same
category. It seems to be working well for my purposes, but I would
appreciate further testing to assure there aren't regressions.

Example:

#template 300 by 2023-06
#template 3000 by 2023-08

Before this PR, having these two lines in the notes would only budget
funds for the earliest of the two strings and ignore the 3000 funding
target. With this PR, the sum of the two funding targets will be
respected.
2023-04-07 15:54:14 -04:00
Matiss Janis Aboltins
f9a1b094cc 🔖 23.4.0 (#863) v23.4.0 2023-04-06 22:04:12 +01:00
Jed Fox
5d559afe30 Enable linting for all packages (#861)
<!-- Thank you for submitting a pull request! Make sure to follow the
instructions to write release notes for your PR — it should only take a
minute or two:
https://github.com/actualbudget/docs#writing-good-release-notes -->
2023-04-06 15:49:43 -04:00
Matiss Janis Aboltins
4d0e9cadd3 🐛 (autocomplete) height of the input box (#862) 2023-04-06 20:44:15 +01:00
Matiss Janis Aboltins
bfe896a30e (autocomplete) turn on feature flag by default (#850) 2023-04-06 18:28:42 +01:00
chris heazlewood
44573c0fe5 Store payee in imported_payee during ynab4/ynab5 import (#736) 2023-04-06 17:49:24 +01:00
Matiss Janis Aboltins
7fbb26f2c9 🐛 (autocomplete) allow editing selected payee name (#856) 2023-04-05 22:44:48 +01:00
Jed Fox
143ddeaa96 Force the sidebar to always float when the window is narrow (#835)
This improves usability of narrow screen widths, and also prepares for
further optimizations that would allow us to use the sidebar largely
as-is on mobile, instead of having to have a tab bar.

---------

Co-authored-by: Matiss Janis Aboltins <matiss@mja.lv>
2023-04-05 17:25:57 -04:00
Matiss Janis Aboltins
61f1802840 🐛 dismiss update notification only after clicking close (#854)
Closes #764

Dismiss the update notification only after clicking "close" button
2023-04-04 21:18:12 +01:00
Matiss Janis Aboltins
e23f9d822b 🐛 normalize value when switching between single/multi select (#855)
Closes #779

Normalize the input value when switching between single/multi select
fields. Most visible when using the "notes" field filter.
2023-04-04 21:17:47 +01:00
Jed Fox
6ef1f3d15d Fix display of loading indicator in management app (#853)
Fixes #852.
2023-04-04 13:48:30 -04:00
Matiss Janis Aboltins
0dd5536914 🐛 navigation back to config-server page after clicking on "no server" (#851)
Closes #842

---------

Co-authored-by: Jed Fox <git@jedfox.com>
2023-04-04 18:34:59 +01:00
Matiss Janis Aboltins
072c3504fe Ported NewAutocomplete to TypeScript (#831)
Small migration of `NewAutocomplete`.

---------

Co-authored-by: Jed Fox <git@jedfox.com>
2023-04-04 18:06:42 +01:00
Jed Fox
5d921f7ab1 Update to latest stable date-fns version (#849)
Previously, we were using an alpha version of date-fns v2. Now we’re
using the latest stable v2.
2023-04-03 14:28:24 -04:00
Jed Fox
267bd8cc07 Remove Safari pinned tab icon (#848)
Safari now supports real favicons, and the existing icon was just a
solid circle which isn’t very clear.

Before/After:
<img width="139" alt="Screenshot_2023-04-03 14 05 06"
src="https://user-images.githubusercontent.com/25517624/229590886-b814d622-6780-4222-804c-edc84c43a2f6.png">
<img width="140" alt="Screenshot_2023-04-03 14 06 56"
src="https://user-images.githubusercontent.com/25517624/229591285-d808fa92-6141-4a23-8e50-e1f46e5b3d03.png">
2023-04-03 14:24:59 -04:00
Alberto Gasparin
79ad04dd88 Convert loot-core to TS p1 (#841)
Part 1 of the conversion. Mostly renaming js to ts and making sure
things make still sense. Added also handy TS ESLint rules.

In order to support the various .web/.electron/... I ended up adopting
`index.d.ts` as pattern to share type definition. Let me know if that
makes sense for you too. Right now the function type definition is
duplicated, but the solution will be importing from `index.d.ts` and
using `const fn: FnDef = () => ...` that way we can keep all variants in
sync from a single type file.

Such rewrite however is better done in another PR otherwise we risk
confusing git and loosing history (rename + too many changes). Another
thing that might do in the next PR is convert all files to ESModules, as
things get confusing between CJS exports, ESM default/named and TS adds
extra complains.
2023-04-03 10:29:59 -04:00
Matiss Janis Aboltins
405a92e926 (e2e) improve stability of budget e2e tests (#845)
Sometimes the test failed because..


`parseFloat("1,234.55") === 1)`
2023-04-02 20:21:22 +01:00
Matiss Janis Aboltins
69140d6290 🐛 (autocomplete) remove portal from table view for smoother experience (#839) 2023-04-01 20:13:09 +01:00
Matiss Janis Aboltins
e8da21fc80 🐛 (autocomplete) set min-height used to calculate the flip (top-bottom) (#837) 2023-04-01 08:10:40 +01:00
Matiss Janis Aboltins
ad9a4067a8 🐛 (autocomplete) delay when switching from Select to CreatableSelect (#836) 2023-03-31 22:17:54 +01:00
Matiss Janis Aboltins
7e6b760796 ♻️ (bank-sync) improved UX for linking nordigen accounts (#792)
Improving the UX for Nordigen bank-sync account import modal.
2023-03-31 20:33:49 +01:00
Matiss Janis Aboltins
45c06c2303 🐛 (autocomplete) set min-width of the autocomplete (#834)
Implement min-width for the autocomplete to make it look better on small
screens.


https://github.com/actualbudget/actual/issues/773#issuecomment-1482254636

<img width="304" alt="Screenshot 2023-03-31 at 19 02 06"
src="https://user-images.githubusercontent.com/886567/229195868-7d858f18-0c1a-4a9d-95be-5dd0e4aef92c.png">
2023-03-31 19:15:42 +01:00
Jed Fox
440093b30a Allow data: URLs for images in Netlify deploys (#832) 2023-03-31 12:28:34 -05:00
Alberto Gasparin
f76a07c3cf Add "all" or "any" conditions in rules (#811) 2023-03-29 22:29:07 +01:00
Alberto Gasparin
c009a0c7fb Start Typescript inception (#816) 2023-03-28 16:49:51 -05:00
Jed Fox
c025e516fb Fix error when running importTransactions from the API (#819) 2023-03-27 11:26:01 -05:00
Matiss Janis Aboltins
649b4c90e0 (e2e) adding onboarding and budget tests (#813)
Added onboarding and budget e2e tests. Also fixed an issue for
first-time flows using imports: currently people end up with a blank
white screen after importing. Instead they should see the budget table.

Related: https://github.com/actualbudget/actual/issues/583
2023-03-26 18:25:22 +01:00
Aidan Harbison
28c6894021 transaction-import: treat (amount) as -amount (#808)
- When parsing an amount string, consider surrounding parentheses to
mean the amount is negative.
- Ensures all input to `parseFloat()` is sanitized.

Closes: #807
2023-03-24 17:57:50 +00:00
Jed Fox
e71d4dc680 Move all loot-design code into desktop-client (#800)
Seems to build fine, will test later.
2023-03-24 13:56:09 -04:00
Matiss Janis Aboltins
ba778c9e9f (bank-sync) add explicit nordigen bank-sync warning (#801)
Adding an explicit bank-sync warning disclaimer.
#724 

<img width="542" alt="Screenshot 2023-03-21 at 20 09 54"
src="https://user-images.githubusercontent.com/886567/226729803-29606532-3d9f-4114-8987-9612bd92181b.png">
2023-03-23 12:23:56 +00:00
Alberto Gasparin
605a0d82ed Allow rules creation from account page (#802)
Adding a "create rule" menu item in the transactions dropdown to open
the create new rule modal, pre-filled with the payee information.
Fixes #749
2023-03-23 08:14:25 -04:00
Matiss Janis Aboltins
edf2122059 🐛 (dev-server) retry loading backend script in web-worker (#806)
Co-authored-by: Jed Fox <git@jedfox.com>
2023-03-22 19:59:52 +00:00
Matiss Janis Aboltins
889ca322f1 📝 remove rich from core contributors (#803)
😢
2023-03-21 23:27:48 +00:00
Tomek Modrzyński
070bd212c5 Re-enable goal templates by passing flag values to the budget summary component (#797) 2023-03-21 18:23:40 -04:00
Jed Fox
8e94d1777b Improve visual consistency on the settings page (#799)
This PR improves the consistency of the settings UI by moving everything
(except the budget name field on mobile) into `<Setting>` boxes.
Additionally, it adds a “Settings” option to the file dropdown menu (I
keep expecting it to be there, and I think it’s reasonable to expose it
in both locations so it’s easier to access)
2023-03-21 16:11:18 -04:00
Jed Fox
3cb18683c6 nit: use curly apostrophes throughout the UI (#791) 2023-03-21 13:48:31 -04:00
Jakub Kuczys
6c01e6eaaf Accept .blob files when importing Actual export (#785)
I'm not sure if this is something you want but it was a simple change so
I figured I might as well contribute it. This PR allows the user to
upload `.blob` files that they may have gotten from server's
`user-files/` folder. This can be useful if the user didn't export the
file but has server backups.

---------

Co-authored-by: Jed Fox <git@jedfox.com>
2023-03-21 09:39:54 -04:00
Matiss Janis Aboltins
84cbe6e54c 💚 disabling flaky unit test step (#795)
Disabling the flaky unit test step. We should re-enable it eventually,
but right now it just creates unnecessary noise..
2023-03-20 19:44:05 +00:00
Jed Fox
181d088e76 Match spacing in autocomplete (#793) 2023-03-20 14:51:42 -04:00