@actual-app/api 6.10.0 → 24.10.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/@types/loot-core/client/state-types/modals.d.ts +17 -11
- package/@types/loot-core/client/state-types/prefs.d.ts +4 -9
- package/@types/loot-core/client/state-types/queries.d.ts +4 -4
- package/@types/loot-core/mocks/index.d.ts +2 -7
- package/@types/loot-core/server/accounts/rules.d.ts +3 -4
- package/@types/loot-core/server/aql/schema/index.d.ts +8 -0
- package/@types/loot-core/server/db/index.d.ts +2 -2
- package/@types/loot-core/server/main-app.d.ts +1 -1
- package/@types/loot-core/server/preferences/app.d.ts +12 -0
- package/@types/loot-core/server/preferences/types/handlers.d.ts +8 -0
- package/@types/loot-core/server/prefs.d.ts +4 -6
- package/@types/loot-core/server/util/rschedule.d.ts +0 -1
- package/@types/loot-core/shared/errors.d.ts +1 -1
- package/@types/loot-core/shared/months.d.ts +2 -0
- package/@types/loot-core/shared/rules.d.ts +5 -32
- package/@types/loot-core/shared/transactions.d.ts +2 -0
- package/@types/loot-core/shared/util.d.ts +4 -2
- package/@types/loot-core/types/handlers.d.ts +2 -0
- package/@types/loot-core/types/models/dashboard.d.ts +37 -4
- package/@types/loot-core/types/models/reports.d.ts +3 -13
- package/@types/loot-core/types/models/rule.d.ts +4 -1
- package/@types/loot-core/types/models/schedule.d.ts +18 -14
- package/@types/loot-core/types/models/transaction-filter.d.ts +4 -2
- package/@types/loot-core/types/models/transaction.d.ts +2 -0
- package/@types/loot-core/types/prefs.d.ts +38 -50
- package/@types/loot-core/types/server-events.d.ts +1 -0
- package/@types/loot-core/types/server-handlers.d.ts +4 -6
- package/@types/loot-core/types/util.d.ts +2 -0
- package/@types/migrations/1723665565000_prefs.d.ts +4 -0
- package/dist/app/bundle.api.js +1164 -781
- package/dist/migrations/1723665565000_prefs.js +51 -0
- package/dist/package.json +1 -1
- package/package.json +1 -1
- /package/@types/loot-core/server/budget/{rollover.d.ts → envelope.d.ts} +0 -0
|
@@ -1,42 +1,35 @@
|
|
|
1
|
-
import { type numberFormats } from '../shared/util';
|
|
2
|
-
|
|
3
|
-
import { spendingReportTimeType } from './models/reports';
|
|
4
|
-
|
|
5
1
|
export type FeatureFlag =
|
|
6
2
|
| 'dashboards'
|
|
7
3
|
| 'reportBudget'
|
|
8
4
|
| 'goalTemplatesEnabled'
|
|
9
|
-
| 'spendingReport'
|
|
10
|
-
| 'simpleFinSync';
|
|
5
|
+
| 'spendingReport';
|
|
11
6
|
|
|
12
7
|
/**
|
|
13
8
|
* Cross-device preferences. These sync across devices when they are changed.
|
|
14
9
|
*/
|
|
15
10
|
export type SyncedPrefs = Partial<
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
[key: `show-extra-balances-${string}`]: boolean;
|
|
28
|
-
[key: `hide-cleared-${string}`]: boolean;
|
|
29
|
-
[key: `hide-reconciled-${string}`]: boolean;
|
|
11
|
+
Record<
|
|
12
|
+
| 'budgetType'
|
|
13
|
+
| 'firstDayOfWeekIdx'
|
|
14
|
+
| 'dateFormat'
|
|
15
|
+
| 'numberFormat'
|
|
16
|
+
| 'hideFraction'
|
|
17
|
+
| 'isPrivacyEnabled'
|
|
18
|
+
| `show-balances-${string}`
|
|
19
|
+
| `show-extra-balances-${string}`
|
|
20
|
+
| `hide-cleared-${string}`
|
|
21
|
+
| `hide-reconciled-${string}`
|
|
30
22
|
// TODO: pull from src/components/modals/ImportTransactions.js
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
23
|
+
| `parse-date-${string}-${'csv' | 'qif'}`
|
|
24
|
+
| `csv-mappings-${string}`
|
|
25
|
+
| `csv-delimiter-${string}`
|
|
26
|
+
| `csv-skip-lines-${string}`
|
|
27
|
+
| `csv-has-header-${string}`
|
|
28
|
+
| `ofx-fallback-missing-payee-${string}`
|
|
29
|
+
| `flip-amount-${string}-${'csv' | 'qif'}`
|
|
30
|
+
| `flags.${FeatureFlag}`,
|
|
31
|
+
string
|
|
32
|
+
>
|
|
40
33
|
>;
|
|
41
34
|
|
|
42
35
|
/**
|
|
@@ -58,35 +51,30 @@ export type MetadataPrefs = Partial<{
|
|
|
58
51
|
|
|
59
52
|
/**
|
|
60
53
|
* Local preferences applicable to a single device. Stored in local storage.
|
|
61
|
-
* TODO: eventually `LocalPrefs` type should not use `SyncedPrefs` or `MetadataPrefs`;
|
|
62
|
-
* this is only a stop-gap solution.
|
|
63
54
|
*/
|
|
64
|
-
export type LocalPrefs =
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
spendingReportTime: spendingReportTimeType;
|
|
79
|
-
spendingReportCompare: spendingReportTimeType;
|
|
80
|
-
sidebarWidth: number;
|
|
81
|
-
'mobile.showSpentColumn': boolean;
|
|
82
|
-
}>;
|
|
55
|
+
export type LocalPrefs = Partial<{
|
|
56
|
+
'ui.showClosedAccounts': boolean;
|
|
57
|
+
'expand-splits': boolean;
|
|
58
|
+
'budget.collapsed': string[];
|
|
59
|
+
'budget.summaryCollapsed': boolean;
|
|
60
|
+
'budget.showHiddenCategories': boolean;
|
|
61
|
+
'budget.startMonth': string;
|
|
62
|
+
'flags.updateNotificationShownForVersion': string;
|
|
63
|
+
reportsViewLegend: boolean;
|
|
64
|
+
reportsViewSummary: boolean;
|
|
65
|
+
reportsViewLabel: boolean;
|
|
66
|
+
sidebarWidth: number;
|
|
67
|
+
'mobile.showSpentColumn': boolean;
|
|
68
|
+
}>;
|
|
83
69
|
|
|
84
70
|
export type Theme = 'light' | 'dark' | 'auto' | 'midnight' | 'development';
|
|
71
|
+
export type DarkTheme = 'dark' | 'midnight';
|
|
85
72
|
export type GlobalPrefs = Partial<{
|
|
86
73
|
floatingSidebar: boolean;
|
|
87
74
|
maxMonths: number;
|
|
88
75
|
keyId?: string;
|
|
89
76
|
theme: Theme;
|
|
77
|
+
preferredDarkTheme: DarkTheme;
|
|
90
78
|
documentDir: string; // Electron only
|
|
91
79
|
serverSelfSignedCert: string; // Electron only
|
|
92
80
|
}>;
|
|
@@ -17,7 +17,7 @@ import {
|
|
|
17
17
|
RuleEntity,
|
|
18
18
|
PayeeEntity,
|
|
19
19
|
} from './models';
|
|
20
|
-
import { GlobalPrefs,
|
|
20
|
+
import { GlobalPrefs, MetadataPrefs } from './prefs';
|
|
21
21
|
import { Query } from './query';
|
|
22
22
|
import { EmptyObject } from './util';
|
|
23
23
|
|
|
@@ -59,22 +59,20 @@ export interface ServerHandlers {
|
|
|
59
59
|
|
|
60
60
|
'get-budget-bounds': () => Promise<{ start: string; end: string }>;
|
|
61
61
|
|
|
62
|
-
'
|
|
62
|
+
'envelope-budget-month': (arg: { month }) => Promise<
|
|
63
63
|
{
|
|
64
64
|
value: string | number | boolean;
|
|
65
65
|
name: string;
|
|
66
66
|
}[]
|
|
67
67
|
>;
|
|
68
68
|
|
|
69
|
-
'
|
|
69
|
+
'tracking-budget-month': (arg: { month }) => Promise<
|
|
70
70
|
{
|
|
71
71
|
value: string | number | boolean;
|
|
72
72
|
name: string;
|
|
73
73
|
}[]
|
|
74
74
|
>;
|
|
75
75
|
|
|
76
|
-
'budget-set-type': (arg: { type }) => Promise<unknown>;
|
|
77
|
-
|
|
78
76
|
'category-create': (arg: {
|
|
79
77
|
name;
|
|
80
78
|
groupId;
|
|
@@ -241,7 +239,7 @@ export interface ServerHandlers {
|
|
|
241
239
|
|
|
242
240
|
'save-prefs': (prefsToSet) => Promise<'ok'>;
|
|
243
241
|
|
|
244
|
-
'load-prefs': () => Promise<
|
|
242
|
+
'load-prefs': () => Promise<MetadataPrefs | null>;
|
|
245
243
|
|
|
246
244
|
'sync-reset': () => Promise<{ error?: { reason: string; meta?: unknown } }>;
|
|
247
245
|
|