@mx-cartographer/experiences 7.7.2 → 7.8.0-alpha-ram-goal-bug

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.
Files changed (92) hide show
  1. package/CHANGELOG.md +18 -0
  2. package/dist/Account-BiB1F8lL.mjs +118 -0
  3. package/dist/{Account-BfkKlfsW.mjs → Account-DuOz1a27.mjs} +1 -1
  4. package/dist/AccountApi-DgZ8ILj1.mjs +19 -0
  5. package/dist/{AccountDetailsHeader-DqYIuhOs.mjs → AccountDetailsHeader-Cf2TUJnM.mjs} +4 -4
  6. package/dist/AccountDisplayName-CO7z3v99.mjs +11 -0
  7. package/dist/{AccountFields-yP8QdgPd.mjs → AccountFields-UdOvbQ5H.mjs} +7 -6
  8. package/dist/{AccountListItem-DMbu9ehd.mjs → AccountListItem-BPVxmNT_.mjs} +7 -7
  9. package/dist/AccountStore-BbPWe2C9.mjs +244 -0
  10. package/dist/Accounts-M-LTzStv.mjs +27 -0
  11. package/dist/{CategoryStore-Cnw9yUys.mjs → CategoryStore-BYICdb9m.mjs} +73 -73
  12. package/dist/CategoryUtil-meuejJqP.mjs +80 -0
  13. package/dist/{ConnectionsDrawer-BqR6FWJO.mjs → ConnectionsDrawer-BDpVTTSe.mjs} +1 -1
  14. package/dist/{DebtsStore-DuSdXM1k.mjs → DebtsStore-BIbOVCPe.mjs} +12 -12
  15. package/dist/{ExportCsvAction-HK5CeZWR.mjs → ExportCsvAction-CDuzTva1.mjs} +2 -2
  16. package/dist/GlobalAccountFilter-DQCPNc95.mjs +316 -0
  17. package/dist/GoalStore-B4LVt_kH.mjs +422 -0
  18. package/dist/{ManageIncome-BrTrlplL.mjs → ManageIncome-CL3hv8i9.mjs} +44 -44
  19. package/dist/NetWorthStore-yV43kJro.mjs +168 -0
  20. package/dist/{NotificationSettings-D4Vh3z8I.mjs → NotificationSettings-SPg3pwbX.mjs} +171 -169
  21. package/dist/{NotificationStore-CDX_kqHa.mjs → NotificationStore-Ck2KdNmT.mjs} +22 -14
  22. package/dist/{RecurringSettings-D2V6l77l.mjs → RecurringSettings-Bmnnpb48.mjs} +16 -16
  23. package/dist/{RecurringTransactionsStore-Caf1cq4v.mjs → RecurringTransactionsStore-BQBEJOPP.mjs} +91 -81
  24. package/dist/{RecurringTransactions-Bf4lX0Cn.mjs → RepeatingTransaction-miZVnk_A.mjs} +4 -4
  25. package/dist/{SettingsStore-krIRNwHK.mjs → SettingsStore-BHpuyujx.mjs} +1 -1
  26. package/dist/SkeletonLoader-BaNboJjD.mjs +38 -0
  27. package/dist/{SpendingLegend-gTCJLLkV.mjs → SpendingLegend-CD60HCYS.mjs} +33 -33
  28. package/dist/{TransactionDetails-7MHOshKQ.mjs → TransactionDetails-BDhz3DLT.mjs} +2 -2
  29. package/dist/TransactionStore-BSp5bOKg.mjs +705 -0
  30. package/dist/{User-LJpEwPtn.mjs → User-B0LnmiKO.mjs} +21 -20
  31. package/dist/WidgetContainer-BbPS3Yxz.mjs +555 -0
  32. package/dist/accounts/index.es.js +421 -391
  33. package/dist/accounts/stores/AccountStore.d.ts +30 -23
  34. package/dist/accounts/utils/Accounts.d.ts +2 -1
  35. package/dist/budgets/index.es.js +546 -540
  36. package/dist/budgets/store/BudgetsStore.d.ts +1 -0
  37. package/dist/cashflow/index.es.js +444 -457
  38. package/dist/categories/index.es.js +1 -1
  39. package/dist/categories/stores/CategoryStore.d.ts +10 -5
  40. package/dist/categories/util/CategoryUtil.d.ts +3 -2
  41. package/dist/common/components/GlobalAccountFilter.d.ts +11 -0
  42. package/dist/common/components/SkeletonLoader.d.ts +7 -0
  43. package/dist/common/components/WidgetContainer.d.ts +7 -6
  44. package/dist/common/components/globalaccountfilter/GlobalAccountFilterList.d.ts +7 -0
  45. package/dist/common/components/index.d.ts +2 -2
  46. package/dist/common/hooks/useAriaLive.d.ts +1 -1
  47. package/dist/common/index.es.js +459 -445
  48. package/dist/common/stores/AppDataStore.d.ts +3 -1
  49. package/dist/common/stores/GlobalCopyStore.d.ts +0 -1
  50. package/dist/common/stores/GlobalStore.d.ts +3 -3
  51. package/dist/common/stores/GlobalUiStore.d.ts +10 -6
  52. package/dist/common/stores/UserStore.d.ts +3 -2
  53. package/dist/common/types/Account.d.ts +9 -6
  54. package/dist/dashboard/index.es.js +84 -116
  55. package/dist/debts/index.es.js +417 -413
  56. package/dist/{exportTransactionsToCSV-BrTYdSgJ.mjs → exportTransactionsToCSV-DtQ7ovAR.mjs} +1 -1
  57. package/dist/finstrong/index.es.js +1167 -1110
  58. package/dist/goals/index.es.js +618 -598
  59. package/dist/goals/stores/GoalStore.d.ts +19 -4
  60. package/dist/help/index.es.js +13 -13
  61. package/dist/investments/index.es.js +330 -325
  62. package/dist/investments/stores/HoldingStore.d.ts +1 -0
  63. package/dist/networth/components/NetWorthChart.d.ts +3 -2
  64. package/dist/networth/components/NetWorthList.d.ts +3 -3
  65. package/dist/networth/index.es.js +423 -433
  66. package/dist/networth/stores/NetWorthStore.d.ts +20 -9
  67. package/dist/networth/utils/NetWorthUtils.d.ts +2 -2
  68. package/dist/notifications/index.es.js +90 -91
  69. package/dist/notifications/stores/NotificationStore.d.ts +3 -1
  70. package/dist/recurringtransactions/components/MicroWidgetContent.d.ts +3 -0
  71. package/dist/recurringtransactions/index.es.js +543 -562
  72. package/dist/recurringtransactions/stores/RecurringTransactionsStore.d.ts +4 -2
  73. package/dist/settings/index.es.js +253 -248
  74. package/dist/spending/index.es.js +282 -301
  75. package/dist/transactions/index.es.js +269 -263
  76. package/dist/transactions/stores/TransactionStore.d.ts +26 -77
  77. package/dist/transactions/stores/UiStore.d.ts +0 -2
  78. package/dist/trends/index.es.js +708 -699
  79. package/dist/{useAccountDisplayName-BTvP_pw6.mjs → useAccountDisplayName-Bot2tb4n.mjs} +1 -1
  80. package/package.json +3 -3
  81. package/dist/AccountStore-CWFzg8-E.mjs +0 -260
  82. package/dist/Accounts-CWt-NRq8.mjs +0 -9
  83. package/dist/CategoryUtil-DZflYFam.mjs +0 -78
  84. package/dist/ConnectDrawer-BOjfI6rz.mjs +0 -563
  85. package/dist/GoalStore-C7ahxxLi.mjs +0 -364
  86. package/dist/NetWorthStore-xWIo9CYU.mjs +0 -150
  87. package/dist/TransactionStore-DJwPaZuM.mjs +0 -677
  88. package/dist/WidgetContainer-CrK6tyHr.mjs +0 -572
  89. package/dist/common/components/accountfilter/AccountFilter.d.ts +0 -20
  90. package/dist/common/components/accountfilter/AccountFilterOptions.d.ts +0 -31
  91. package/dist/common/components/accountfilter/index.d.ts +0 -1
  92. package/dist/{ToggleListItem-ciFTiqRS.mjs → Notification-Bs1fdbzI.mjs} +1 -1
@@ -0,0 +1,316 @@
1
+ import { jsxs as l, jsx as t } from "react/jsx-runtime";
2
+ import b from "react";
3
+ import { observer as w } from "mobx-react-lite";
4
+ import M from "@mui/material/Box";
5
+ import I from "@mui/material/Button";
6
+ import N from "@mui/material/Divider";
7
+ import R from "@mui/material/IconButton";
8
+ import T from "@mui/material/Popover";
9
+ import k from "@mui/material/Stack";
10
+ import U from "@mui/material/Tooltip";
11
+ import { FilterAlt as G, AccountBalance as Y } from "@mxenabled/mx-icons";
12
+ import { Text as Z, P as D } from "@mxenabled/mxui";
13
+ import W from "@mui/material/Checkbox";
14
+ import B from "@mui/material/List";
15
+ import v from "@mui/material/ListItem";
16
+ import L from "@mui/material/ListItemButton";
17
+ import q from "@mui/material/ListItemIcon";
18
+ import E from "@mui/material/ListItemText";
19
+ import { b as O, u as A, d as z, e as J, a as K } from "./hooks-ZMp65DFz.mjs";
20
+ import Q from "@mui/material/styles/useTheme";
21
+ import { ConnectWidget as V } from "@mxenabled/web-widget-sdk";
22
+ import X from "@mui/material/CircularProgress";
23
+ import { D as tt } from "./Drawer-DV4NTsFg.mjs";
24
+ import { u as et } from "./useScreenSize-B6JyS_Lj.mjs";
25
+ const ot = w(
26
+ ({ allowedAccountTypes: o }) => {
27
+ const { accountFilterMap: i, updateAccountFilterMap: d } = O(), { accounts: C, common: f } = A(), { account_filter: x } = f, { accountsByTypeMap: r } = z(), _ = b.useMemo(
28
+ () => Array.from(r.keys()).reduce((e, n) => {
29
+ if (!o || o && o.includes(n)) {
30
+ const c = r.get(n);
31
+ c && e.push(...c);
32
+ }
33
+ return e;
34
+ }, []),
35
+ [r, o]
36
+ ), m = new Map(
37
+ Array.from(i.entries()).filter(([e]) => _.some((n) => n.guid === e))
38
+ ), s = Array.from(m.values()).every((e) => e), S = Array.from(m.values()).some((e) => e), p = () => {
39
+ for (const e of m.keys())
40
+ d(e, !s);
41
+ }, g = (e) => {
42
+ const n = r.get(e);
43
+ if (!n) return;
44
+ const c = n.some((u) => i.get(u.guid));
45
+ for (const u of n)
46
+ d(u.guid, !c);
47
+ };
48
+ return /* @__PURE__ */ l(
49
+ B,
50
+ {
51
+ dense: !0,
52
+ id: "filter_accounts",
53
+ sx: { overflowY: "scroll", maxHeight: 350, minWidth: 280 },
54
+ children: [
55
+ /* @__PURE__ */ t(v, { disableGutters: !0, disablePadding: !0, sx: { py: 16 }, children: /* @__PURE__ */ l(L, { disableGutters: !0, onClick: p, sx: { p: 0, px: 8 }, children: [
56
+ /* @__PURE__ */ t(
57
+ W,
58
+ {
59
+ checked: s,
60
+ disableRipple: !0,
61
+ indeterminate: !s && S,
62
+ inputProps: { "aria-labelledby": "label-select-all" },
63
+ size: "small",
64
+ tabIndex: -1
65
+ }
66
+ ),
67
+ /* @__PURE__ */ t(
68
+ E,
69
+ {
70
+ id: "label-select-all",
71
+ primary: x.select_all_accounts,
72
+ primaryTypographyProps: { variant: "body1" }
73
+ }
74
+ )
75
+ ] }) }),
76
+ Array.from(r.keys()).map((e) => {
77
+ const n = r.get(e), c = o ? !o.includes(e) : !1, u = C.account_type_accounts[e];
78
+ return (
79
+ // Account Type Header
80
+ /* @__PURE__ */ t(v, { disableGutters: !0, disablePadding: !0, children: /* @__PURE__ */ l(k, { sx: { pb: 8, width: "100%" }, children: [
81
+ /* @__PURE__ */ t(N, {}),
82
+ /* @__PURE__ */ t(
83
+ B,
84
+ {
85
+ dense: !0,
86
+ subheader: /* @__PURE__ */ t(v, { children: /* @__PURE__ */ t(
87
+ L,
88
+ {
89
+ disableGutters: !0,
90
+ disabled: c,
91
+ onClick: () => g(e),
92
+ sx: { pl: 16, minHeight: 40, justifyContent: "left" },
93
+ children: /* @__PURE__ */ t(
94
+ E,
95
+ {
96
+ primary: u,
97
+ primaryTypographyProps: { variant: "body1", fontWeight: "bold" }
98
+ }
99
+ )
100
+ }
101
+ ) }),
102
+ children: n?.map((a) => (
103
+ // Account Checkbox
104
+ /* @__PURE__ */ t(v, { children: /* @__PURE__ */ l(
105
+ L,
106
+ {
107
+ disableGutters: !0,
108
+ disabled: c,
109
+ onClick: () => d(a.guid, !i.get(a.guid)),
110
+ sx: { p: 0, minHeight: 40 },
111
+ children: [
112
+ /* @__PURE__ */ t(q, { children: /* @__PURE__ */ t(
113
+ W,
114
+ {
115
+ checked: i.get(a.guid),
116
+ disableRipple: !0,
117
+ inputProps: { "aria-labelledby": `label-${a.guid}` },
118
+ size: "small",
119
+ tabIndex: -1
120
+ }
121
+ ) }),
122
+ /* @__PURE__ */ t(
123
+ E,
124
+ {
125
+ id: `label-${a.guid}`,
126
+ primary: a.displayName,
127
+ primaryTypographyProps: { variant: "body1" }
128
+ }
129
+ )
130
+ ]
131
+ }
132
+ ) }, a.guid)
133
+ ))
134
+ }
135
+ )
136
+ ] }) }, e)
137
+ );
138
+ })
139
+ ]
140
+ }
141
+ );
142
+ }
143
+ ), rt = ({ status: o = y.Loading }) => {
144
+ const { connect: i } = A();
145
+ return /* @__PURE__ */ t(
146
+ M,
147
+ {
148
+ sx: {
149
+ height: "calc(100% - 62px)",
150
+ position: "absolute",
151
+ width: "100%"
152
+ },
153
+ children: /* @__PURE__ */ l(k, { alignItems: "center", direction: "column", justifyContent: "center", sx: { height: "100%" }, children: [
154
+ o === y.Loading && /* @__PURE__ */ t(X, { color: "primary", size: 48 }),
155
+ /* @__PURE__ */ t(
156
+ Z,
157
+ {
158
+ sx: {
159
+ color: "grey.600",
160
+ marginTop: "16px"
161
+ },
162
+ children: o === y.Error ? i.oops : i.loading
163
+ }
164
+ )
165
+ ] })
166
+ }
167
+ );
168
+ }, P = w(rt);
169
+ var y = /* @__PURE__ */ ((o) => (o.Loading = "loading", o.Error = "error", o))(y || {}), nt = /* @__PURE__ */ ((o) => (o.Currency = "currency", o.Date = "date", o.Input = "input", o.Select = "select", o))(nt || {});
170
+ const F = "connect_widget", Gt = "connections_widget", it = ({
171
+ loadWidgetProps: o,
172
+ onClose: i,
173
+ showConnectWidget: d,
174
+ title: C
175
+ }) => {
176
+ let f;
177
+ const { refreshAccounts: x } = z(), { loadWidget: r } = J(), { connect: _ } = A(), [m, s] = b.useState(!1), [S, p] = b.useState(!1), {
178
+ palette: { mode: g }
179
+ } = Q();
180
+ return b.useEffect(() => (d ? (s(!0), r({ mode: g, ...o }).then((e) => {
181
+ f = new V({
182
+ container: `#${F}`,
183
+ style: {
184
+ border: "none",
185
+ height: "calc(100% - 62px)",
186
+ maxWidth: "450px",
187
+ position: "absolute",
188
+ width: "100%"
189
+ },
190
+ url: e.url,
191
+ onSsoUrlLoadError: () => {
192
+ s(!1), p(!0);
193
+ },
194
+ onLoad: () => {
195
+ s(!1), p(!1);
196
+ }
197
+ });
198
+ })) : (s(!1), p(!1)), () => {
199
+ f?.unmount();
200
+ }), [d]), /* @__PURE__ */ t(
201
+ tt,
202
+ {
203
+ ariaLabelClose: _.close_manage_connection_aria,
204
+ isOpen: d,
205
+ onClose: () => {
206
+ i(), x();
207
+ },
208
+ title: C,
209
+ children: /* @__PURE__ */ l("div", { id: F, children: [
210
+ S && /* @__PURE__ */ t(P, { status: y.Error }),
211
+ m && /* @__PURE__ */ t(P, { status: y.Loading })
212
+ ] })
213
+ }
214
+ );
215
+ }, st = w(it), Dt = w(
216
+ ({
217
+ allowedAccountTypes: o,
218
+ onAccountFilterClick: i,
219
+ sx: d = {},
220
+ variant: C = "text"
221
+ }) => {
222
+ const { isDesktop: f } = et(), {
223
+ config: { show_connections_widget_in_master: x }
224
+ } = K(), { common: r, connect: _ } = A(), { accountFilterMap: m, resetAccountFilterMap: s } = O(), { detailedAccounts: S, updateAccountFilter: p } = z(), [g, e] = b.useState(null), [n, c] = b.useState(!1), u = (H) => {
225
+ s(), e(H.currentTarget), i?.();
226
+ }, a = () => {
227
+ e(null);
228
+ }, j = async () => {
229
+ await p(m), e(null);
230
+ }, h = r.account_filter, $ = S.length === 0;
231
+ return /* @__PURE__ */ l(M, { m: 4, sx: { ...d }, children: [
232
+ f ? /* @__PURE__ */ t(
233
+ I,
234
+ {
235
+ "aria-controls": "filter_accounts",
236
+ "aria-haspopup": !0,
237
+ "aria-label": h.title,
238
+ onClick: u,
239
+ startIcon: /* @__PURE__ */ t(G, { size: 24 }),
240
+ sx: { p: 8, whiteSpace: "nowrap", minWidth: "max-content" },
241
+ variant: C,
242
+ children: r.filter_button
243
+ }
244
+ ) : /* @__PURE__ */ t(U, { id: "filter-accounts", placement: "bottom", title: h.title, children: /* @__PURE__ */ t(
245
+ R,
246
+ {
247
+ "aria-controls": "filter_accounts",
248
+ "aria-describedby": "filter-accounts",
249
+ "aria-haspopup": !0,
250
+ "aria-label": h.title,
251
+ color: "primary",
252
+ onClick: u,
253
+ sx: { p: 8 },
254
+ children: /* @__PURE__ */ t(G, { size: 24 })
255
+ }
256
+ ) }),
257
+ /* @__PURE__ */ t(
258
+ T,
259
+ {
260
+ anchorEl: g,
261
+ anchorOrigin: { vertical: "bottom", horizontal: "left" },
262
+ onClose: a,
263
+ open: !!g,
264
+ transformOrigin: { vertical: "top", horizontal: "left" },
265
+ children: $ ? /* @__PURE__ */ l(
266
+ k,
267
+ {
268
+ alignItems: "center",
269
+ direction: "column",
270
+ sx: { p: 16, width: 320, maxWidth: "100%" },
271
+ children: [
272
+ /* @__PURE__ */ t(Y, { size: 32 }),
273
+ /* @__PURE__ */ t(D, { bold: !0, mt: 12, children: h.zero_state_title }),
274
+ /* @__PURE__ */ t(D, { mt: 12, children: h.zero_state_description }),
275
+ x && /* @__PURE__ */ t(I, { onClick: () => c(!0), children: h.zero_state_button })
276
+ ]
277
+ }
278
+ ) : /* @__PURE__ */ l(k, { children: [
279
+ /* @__PURE__ */ t(ot, { allowedAccountTypes: o }),
280
+ /* @__PURE__ */ t(N, {}),
281
+ /* @__PURE__ */ l(k, { direction: "row", justifyContent: "space-between", spacing: 16, sx: { p: 16 }, children: [
282
+ /* @__PURE__ */ t(I, { fullWidth: !0, onClick: a, variant: "text", children: r.cancel_button }),
283
+ /* @__PURE__ */ t(
284
+ I,
285
+ {
286
+ "aria-label": h.filter_button_aria,
287
+ color: "primary",
288
+ fullWidth: !0,
289
+ onClick: j,
290
+ variant: "contained",
291
+ children: r.filter_button
292
+ }
293
+ )
294
+ ] })
295
+ ] })
296
+ }
297
+ ),
298
+ n && /* @__PURE__ */ t(
299
+ st,
300
+ {
301
+ onClose: () => c(!1),
302
+ showConnectWidget: n,
303
+ title: _.mini_title
304
+ }
305
+ )
306
+ ] });
307
+ }
308
+ );
309
+ export {
310
+ Gt as C,
311
+ nt as F,
312
+ Dt as G,
313
+ y as M,
314
+ P as a,
315
+ st as b
316
+ };