@mx-cartographer/experiences 7.4.8-alpha.mm1 → 7.4.8

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 (61) hide show
  1. package/CHANGELOG.md +4 -0
  2. package/dist/{Account-BrOTlmeK.mjs → Account-01wOyrH1.mjs} +1 -1
  3. package/dist/{AccountDetailsContent-B7FqH05C.mjs → AccountDetailsContent-COMjOzwr.mjs} +8 -8
  4. package/dist/{AccountDetailsHeader-C8MxsxhN.mjs → AccountDetailsHeader-Cbi5G6fJ.mjs} +4 -4
  5. package/dist/{AccountFields-BQZ-o6Kj.mjs → AccountFields-Cd_nOWmf.mjs} +2 -2
  6. package/dist/{AccountListItem-aIE9WWTO.mjs → AccountListItem-DxY4cCF1.mjs} +4 -4
  7. package/dist/{AccountStore-DqO84Aer.mjs → AccountStore-C1zMBzHq.mjs} +2 -2
  8. package/dist/{Accounts-DC_A4UCa.mjs → Accounts-D7QljYas.mjs} +1 -1
  9. package/dist/{BudgetUtil-BmZXkL0C.mjs → BudgetUtil-Df2nII9u.mjs} +1 -1
  10. package/dist/{CategorySelectorDrawer-SUgfE5GN.mjs → CategorySelectorDrawer-DqJK_rrL.mjs} +1 -1
  11. package/dist/{ConnectDrawer-KL8t1qSC.mjs → ConnectDrawer-CuUj16NH.mjs} +1 -1
  12. package/dist/{ConnectionsDrawer-DaK5uIL5.mjs → ConnectionsDrawer-Bz4uwdFE.mjs} +2 -2
  13. package/dist/{CurrencyInput-itK0R3wV.mjs → CurrencyInput-BFKcs-_K.mjs} +1 -1
  14. package/dist/{DebtsStore-DVPZbv2C.mjs → DebtsStore-Bu8rRRSL.mjs} +1 -1
  15. package/dist/{ExportCsvAction-Cglo8Mca.mjs → ExportCsvAction-DzTrtPzk.mjs} +3 -3
  16. package/dist/{GoalStore-o4rrjGSJ.mjs → GoalStore-CrNhjvNc.mjs} +2 -2
  17. package/dist/{Help-BjLMsuMS.mjs → Help-BnPXM_N2.mjs} +1 -1
  18. package/dist/{LineChart-BQRxZF3p.mjs → LineChart-bc1D9xBE.mjs} +1 -1
  19. package/dist/{ListItemAction-BxTkF6Tz.mjs → ListItemAction-uobBrm_a.mjs} +1 -1
  20. package/dist/{ManageIncome-rcnDYsBJ.mjs → ManageIncome-A69EUO5u.mjs} +75 -75
  21. package/dist/{MicroWidgetContainer-B2hO9rOG.mjs → MicroWidgetContainer-DEiRnYVa.mjs} +1 -1
  22. package/dist/{MiniWidgetContainer-98-hKFqm.mjs → MiniWidgetContainer-CmXpTylX.mjs} +1 -1
  23. package/dist/{NetWorthStore-DG2X69jG.mjs → NetWorthStore-CpL_kqvx.mjs} +2 -2
  24. package/dist/{NotificationSettings-C7FYNM7I.mjs → NotificationSettings-CNmJWVeI.mjs} +248 -250
  25. package/dist/{OriginalBalanceAction-C6jdS4ws.mjs → OriginalBalanceAction-DK8_LkPz.mjs} +3 -3
  26. package/dist/{RecurringSettings-C81H1l38.mjs → RecurringSettings-B0uObPlD.mjs} +3 -3
  27. package/dist/{SpendingLegend-DqZxN_BZ.mjs → SpendingLegend-Bf-wbJvb.mjs} +2 -2
  28. package/dist/{TransactionDetails-BA_E5nQ-.mjs → TransactionDetails-COH0OKNG.mjs} +5 -5
  29. package/dist/{TransactionStore-PRlwE-TF.mjs → TransactionStore-Dz-G8Wd0.mjs} +2 -2
  30. package/dist/{User-Cnlegl1N.mjs → User-wXzDI4M8.mjs} +1 -1
  31. package/dist/{ViewMoreMicroCard-DfPXJzbv.mjs → ViewMoreMicroCard-C0832BMe.mjs} +101 -105
  32. package/dist/{WidgetContainer-CaPjoWeE.mjs → WidgetContainer-6dsjtOVg.mjs} +2 -2
  33. package/dist/accounts/index.es.js +140 -148
  34. package/dist/analytics/index.es.js +2 -2
  35. package/dist/budgets/index.es.js +478 -483
  36. package/dist/cashflow/index.es.js +362 -367
  37. package/dist/categories/index.es.js +1 -1
  38. package/dist/common/hooks/index.d.ts +0 -1
  39. package/dist/common/index.es.js +33 -35
  40. package/dist/dashboard/index.es.js +88 -90
  41. package/dist/debts/index.es.js +342 -346
  42. package/dist/{exportTransactionsToCSV-DuAaI5XA.mjs → exportTransactionsToCSV-Cz2t0lmA.mjs} +1 -1
  43. package/dist/finstrong/index.es.js +350 -352
  44. package/dist/goals/index.es.js +511 -518
  45. package/dist/help/index.es.js +9 -13
  46. package/dist/{hooks-ZMp65DFz.mjs → hooks-C41HAxM5.mjs} +11 -11
  47. package/dist/investments/index.es.js +393 -395
  48. package/dist/merchants/index.es.js +1 -1
  49. package/dist/microinsights/index.es.js +1 -1
  50. package/dist/networth/index.es.js +240 -245
  51. package/dist/notifications/index.es.js +2 -2
  52. package/dist/recurringtransactions/index.es.js +285 -293
  53. package/dist/settings/index.es.js +249 -252
  54. package/dist/spending/index.es.js +126 -138
  55. package/dist/transactions/index.es.js +73 -77
  56. package/dist/trends/index.es.js +588 -601
  57. package/dist/{useAccountDisplayName-Cjx8YmKK.mjs → useAccountDisplayName-CMMlIOXF.mjs} +2 -2
  58. package/dist/{useInsightsEnabled-B7dxpDrX.mjs → useInsightsEnabled-CNjP5cfR.mjs} +1 -1
  59. package/package.json +1 -1
  60. package/dist/common/hooks/useWidgetLoadTimer.d.ts +0 -6
  61. package/dist/useWidgetLoadTimer-C1NBkyLd.mjs +0 -23
@@ -1,49 +1,43 @@
1
- import { jsxs as l, jsx as t } from "react/jsx-runtime";
2
- import a from "react";
1
+ import { jsxs as c, jsx as t } from "react/jsx-runtime";
2
+ import i from "react";
3
3
  import { observer as x } from "mobx-react-lite";
4
4
  import { startOfMonth as it } from "date-fns/startOfMonth";
5
- import { endOfMonth as rt } from "date-fns/endOfMonth";
5
+ import { endOfMonth as st } from "date-fns/endOfMonth";
6
6
  import M from "@mui/material/Box";
7
7
  import C from "@mui/material/Stack";
8
8
  import E from "@mui/material/Tab";
9
- import st from "@mui/material/Tabs";
10
- import bt from "@mui/material/styles/useTheme";
11
- import { g as ct, a as lt, S as W, b as Q } from "../SpendingLegend-DqZxN_BZ.mjs";
12
- import { Text as y, Icon as _t } from "@mxenabled/mxui";
9
+ import rt from "@mui/material/Tabs";
10
+ import ft from "@mui/material/styles/useTheme";
11
+ import { g as ct, a as lt, S as W, b as Q } from "../SpendingLegend-Bf-wbJvb.mjs";
12
+ import { Text as y, Icon as bt } from "@mxenabled/mxui";
13
13
  import { f as A } from "../NumberFormatting-DjTD0t3W.mjs";
14
- import { u as w, b as R, m as F, d as dt, a as V, h as Ct, g as yt } from "../hooks-ZMp65DFz.mjs";
15
- import { u as gt } from "../useWidgetLoadTimer-C1NBkyLd.mjs";
14
+ import { u as w, b as R, m as F, d as dt, n as _t, a as V, h as Ct, g as yt } from "../hooks-C41HAxM5.mjs";
16
15
  import { L as P } from "../Loader-DUaFpDGv.mjs";
17
- import { M as St } from "../MiniWidgetContainer-98-hKFqm.mjs";
16
+ import { M as St } from "../MiniWidgetContainer-CmXpTylX.mjs";
18
17
  import { startOfToday as Z } from "date-fns/startOfToday";
19
18
  import Tt from "@mui/material/Button";
20
19
  import { useTheme as Mt } from "@mui/material";
21
- import { e as xt } from "../exportTransactionsToCSV-DuAaI5XA.mjs";
22
- import { T as wt, a as vt } from "../TransactionDetails-BA_E5nQ-.mjs";
20
+ import { e as xt } from "../exportTransactionsToCSV-Cz2t0lmA.mjs";
21
+ import { T as wt, a as vt } from "../TransactionDetails-COH0OKNG.mjs";
23
22
  import Dt from "@mui/material/Collapse";
24
23
  import z from "@mui/material/Divider";
25
24
  import tt from "@mui/material/List";
26
25
  import et from "@mui/material/ListItem";
27
- import Lt from "@mui/material/ListItemButton";
28
- import { u as It } from "../useScreenSize-B6JyS_Lj.mjs";
26
+ import It from "@mui/material/ListItemButton";
27
+ import { u as Lt } from "../useScreenSize-B6JyS_Lj.mjs";
29
28
  import { D as nt } from "../Drawer-BEtCk82g.mjs";
30
- import { b as L } from "../Category-CevNQ03n.mjs";
31
- import { A as ot, W as At } from "../WidgetContainer-CaPjoWeE.mjs";
32
- const N = ({ amount: e, label: d }) => /* @__PURE__ */ l(C, { direction: "column", children: [
29
+ import { b as I } from "../Category-CevNQ03n.mjs";
30
+ import { A as ot, W as At } from "../WidgetContainer-6dsjtOVg.mjs";
31
+ const N = ({ amount: e, label: d }) => /* @__PURE__ */ c(C, { direction: "column", children: [
33
32
  /* @__PURE__ */ t(y, { bold: !0, sx: { textTransform: "none" }, variant: "Body", children: d }),
34
33
  /* @__PURE__ */ t(y, { variant: "XSmall", children: A(e, "0,0") })
35
34
  ] }), Et = () => {
36
- const e = bt(), { goals: d, spending: o } = w(), { selectedAccounts: r } = R(), {
37
- categories: i,
38
- dateRangeCategoryTotals: s,
35
+ const e = ft(), { goals: d, spending: o } = w(), { selectedAccounts: l } = R(), {
36
+ categories: s,
37
+ dateRangeCategoryTotals: a,
39
38
  dataRangeTotalsLoaded: n,
40
39
  loadDateRangeCategoryTotals: u
41
- } = F();
42
- gt({
43
- widgetName: "SpendingMiniWidget",
44
- isLoaded: n
45
- });
46
- const c = a.useMemo(
40
+ } = F(), r = i.useMemo(
47
41
  () => [
48
42
  e.palette.chartMono.chartMono5,
49
43
  e.palette.chartMono.chartMono4,
@@ -54,27 +48,27 @@ const N = ({ amount: e, label: d }) => /* @__PURE__ */ l(C, { direction: "column
54
48
  ],
55
49
  [e]
56
50
  );
57
- a.useEffect(() => {
51
+ i.useEffect(() => {
58
52
  u(
59
- r,
53
+ l,
60
54
  it(/* @__PURE__ */ new Date()),
61
- rt(/* @__PURE__ */ new Date())
55
+ st(/* @__PURE__ */ new Date())
62
56
  ).finally();
63
- }, [r]);
64
- const [m, g] = a.useState(""), [h, v] = a.useState(0), _ = a.useMemo(
65
- () => ct(i, d, e, s),
66
- [i, s]
67
- ), f = a.useMemo(
68
- () => lt(i, s, c),
69
- [i, s, c]
57
+ }, [l]);
58
+ const [m, p] = i.useState(""), [h, v] = i.useState(0), _ = i.useMemo(
59
+ () => ct(s, d, e, a),
60
+ [s, a]
61
+ ), f = i.useMemo(
62
+ () => lt(s, a, r),
63
+ [s, a, r]
70
64
  ), O = (T, k) => {
71
- v(k), g("");
65
+ v(k), p("");
72
66
  }, S = (T) => {
73
- g(m === T ? "" : T);
67
+ p(m === T ? "" : T);
74
68
  };
75
- return n ? /* @__PURE__ */ l(M, { width: "100%", children: [
76
- /* @__PURE__ */ l(
77
- st,
69
+ return n ? /* @__PURE__ */ c(M, { width: "100%", children: [
70
+ /* @__PURE__ */ c(
71
+ rt,
78
72
  {
79
73
  "aria-label": o.mini_title,
80
74
  onChange: O,
@@ -121,7 +115,7 @@ const N = ({ amount: e, label: d }) => /* @__PURE__ */ l(C, { direction: "column
121
115
  hidden: h !== 0,
122
116
  id: "spending-tabpanel",
123
117
  role: "tabpanel",
124
- children: /* @__PURE__ */ l(C, { direction: "row", gap: 16, justifyContent: "center", p: 24, children: [
118
+ children: /* @__PURE__ */ c(C, { direction: "row", gap: 16, justifyContent: "center", p: 24, children: [
125
119
  /* @__PURE__ */ t(
126
120
  W,
127
121
  {
@@ -142,7 +136,7 @@ const N = ({ amount: e, label: d }) => /* @__PURE__ */ l(C, { direction: "column
142
136
  hidden: h !== 1,
143
137
  id: "income-tabpanel",
144
138
  role: "tabpanel",
145
- children: /* @__PURE__ */ l(C, { direction: "row", gap: 16, justifyContent: "center", p: 24, children: [
139
+ children: /* @__PURE__ */ c(C, { direction: "row", gap: 16, justifyContent: "center", p: 24, children: [
146
140
  /* @__PURE__ */ t(
147
141
  W,
148
142
  {
@@ -159,31 +153,31 @@ const N = ({ amount: e, label: d }) => /* @__PURE__ */ l(C, { direction: "column
159
153
  )
160
154
  ] }) : /* @__PURE__ */ t(P, { height: 250 });
161
155
  }, Wt = x(Et), Nt = ({ onPrimaryCtaClick: e, sx: d = {} }) => {
162
- const { visibleAccounts: o } = dt(), { spending: r } = w(), { isCopyLoaded: i, isInitialized: s, setSelectedAccounts: n } = R();
163
- return a.useEffect(() => {
156
+ const { visibleAccounts: o } = dt(), { spending: l } = w(), { isCopyLoaded: s, isInitialized: a, setSelectedAccounts: n } = R();
157
+ return i.useEffect(() => {
164
158
  n(o);
165
- }, [o]), !i || !s ? /* @__PURE__ */ t(P, {}) : /* @__PURE__ */ t(
159
+ }, [o]), !s || !a ? /* @__PURE__ */ t(P, {}) : /* @__PURE__ */ t(
166
160
  St,
167
161
  {
168
162
  className: "mx-exp-spending-miniwidget",
169
163
  onPrimaryCtaClick: e,
170
- primaryCtaLabel: r.primary_cta,
164
+ primaryCtaLabel: l.primary_cta,
171
165
  sx: { height: "100%", ...d },
172
- title: r.mini_title,
166
+ title: l.mini_title,
173
167
  children: /* @__PURE__ */ t(Wt, {})
174
168
  }
175
169
  );
176
- }, _e = x(Nt), Rt = ({
170
+ }, be = x(Nt), Rt = ({
177
171
  data: e,
178
172
  onSelected: d,
179
173
  selectedId: o = "",
180
- title: r
174
+ title: l
181
175
  }) => {
182
- const { spending: i } = w(), s = e.categoryData.find((n) => n.guid === o);
183
- return /* @__PURE__ */ l(C, { direction: "column", justifyContent: "center", maxWidth: 400, minWidth: 275, width: "100%", children: [
184
- /* @__PURE__ */ t(y, { bold: !0, sx: { py: 12 }, children: `${r} ${i.by_category}` }),
176
+ const { spending: s } = w(), a = e.categoryData.find((n) => n.guid === o);
177
+ return /* @__PURE__ */ c(C, { direction: "column", justifyContent: "center", maxWidth: 400, minWidth: 275, width: "100%", children: [
178
+ /* @__PURE__ */ t(y, { bold: !0, sx: { py: 12 }, children: `${l} ${s.by_category}` }),
185
179
  /* @__PURE__ */ t(z, { "aria-hidden": "true" }),
186
- /* @__PURE__ */ t(tt, { children: e.categoryData.map((n) => /* @__PURE__ */ l(a.Fragment, { children: [
180
+ /* @__PURE__ */ t(tt, { children: e.categoryData.map((n) => /* @__PURE__ */ c(i.Fragment, { children: [
187
181
  /* @__PURE__ */ t(
188
182
  et,
189
183
  {
@@ -192,10 +186,10 @@ const N = ({ amount: e, label: d }) => /* @__PURE__ */ l(C, { direction: "column
192
186
  sx: {
193
187
  minHeight: 44
194
188
  },
195
- children: /* @__PURE__ */ l(
196
- Lt,
189
+ children: /* @__PURE__ */ c(
190
+ It,
197
191
  {
198
- "aria-expanded": s?.guid === n.guid,
192
+ "aria-expanded": a?.guid === n.guid,
199
193
  onClick: () => d(n.guid),
200
194
  sx: { minHeight: 44, px: 8, py: 0 },
201
195
  children: [
@@ -209,7 +203,7 @@ const N = ({ amount: e, label: d }) => /* @__PURE__ */ l(C, { direction: "column
209
203
  width: 8
210
204
  }
211
205
  ),
212
- /* @__PURE__ */ l(
206
+ /* @__PURE__ */ c(
213
207
  C,
214
208
  {
215
209
  alignItems: "center",
@@ -228,8 +222,8 @@ const N = ({ amount: e, label: d }) => /* @__PURE__ */ l(C, { direction: "column
228
222
  }
229
223
  ),
230
224
  /* @__PURE__ */ t(z, {}),
231
- n.categoryTotals && n.categoryTotals.length > 0 && /* @__PURE__ */ t(Dt, { in: s?.guid === n.guid, unmountOnExit: !0, children: /* @__PURE__ */ l(tt, { children: [
232
- s?.categoryTotals?.map((u) => /* @__PURE__ */ t(
225
+ n.categoryTotals && n.categoryTotals.length > 0 && /* @__PURE__ */ t(Dt, { in: a?.guid === n.guid, unmountOnExit: !0, children: /* @__PURE__ */ c(tt, { children: [
226
+ a?.categoryTotals?.map((u) => /* @__PURE__ */ t(
233
227
  et,
234
228
  {
235
229
  sx: {
@@ -237,8 +231,8 @@ const N = ({ amount: e, label: d }) => /* @__PURE__ */ l(C, { direction: "column
237
231
  pr: 8,
238
232
  py: 0
239
233
  },
240
- children: /* @__PURE__ */ l(C, { direction: "row", justifyContent: "space-between", width: "100%", children: [
241
- /* @__PURE__ */ l(y, { children: [
234
+ children: /* @__PURE__ */ c(C, { direction: "row", justifyContent: "space-between", width: "100%", children: [
235
+ /* @__PURE__ */ c(y, { children: [
242
236
  u.name,
243
237
  " "
244
238
  ] }),
@@ -250,17 +244,17 @@ const N = ({ amount: e, label: d }) => /* @__PURE__ */ l(C, { direction: "column
250
244
  /* @__PURE__ */ t(z, {})
251
245
  ] }) })
252
246
  ] }, n.guid)) }),
253
- /* @__PURE__ */ t(y, { bold: !0, sx: { mt: 12, pr: 8, textAlign: "right" }, children: `${i.total}: ${A(e.totalAmount, "0,0")}` })
247
+ /* @__PURE__ */ t(y, { bold: !0, sx: { mt: 12, pr: 8, textAlign: "right" }, children: `${s.total}: ${A(e.totalAmount, "0,0")}` })
254
248
  ] });
255
249
  }, Ot = x(Rt), kt = ({
256
250
  data: e,
257
251
  onSelected: d,
258
252
  onViewTransactions: o,
259
- selectedId: r,
260
- title: i
253
+ selectedId: l,
254
+ title: s
261
255
  }) => {
262
- const { isDesktop: s, isMobile: n } = It(), { isLoadingCategoryTotals: u } = F(), { spending: c } = w();
263
- return /* @__PURE__ */ l(
256
+ const { isDesktop: a, isMobile: n } = Lt(), { isLoadingCategoryTotals: u } = F(), { spending: r } = w();
257
+ return /* @__PURE__ */ c(
264
258
  C,
265
259
  {
266
260
  alignItems: n ? "center" : "flex-start",
@@ -281,7 +275,7 @@ const N = ({ amount: e, label: d }) => /* @__PURE__ */ l(C, { direction: "column
281
275
  onSelected: () => {
282
276
  },
283
277
  selectedId: "",
284
- size: s ? 400 : 300,
278
+ size: a ? 400 : 300,
285
279
  totalLabel: "Loading ...",
286
280
  variant: "full"
287
281
  }
@@ -292,13 +286,13 @@ const N = ({ amount: e, label: d }) => /* @__PURE__ */ l(C, { direction: "column
292
286
  data: e,
293
287
  onSelected: d,
294
288
  onViewTransactions: o,
295
- selectedId: r,
296
- size: s ? 400 : 300,
297
- totalLabel: c.total_amount,
289
+ selectedId: l,
290
+ size: a ? 400 : 300,
291
+ totalLabel: r.total_amount,
298
292
  variant: "full"
299
293
  }
300
294
  ),
301
- /* @__PURE__ */ t(Ot, { data: e, onSelected: d, selectedId: r, title: i })
295
+ /* @__PURE__ */ t(Ot, { data: e, onSelected: d, selectedId: l, title: s })
302
296
  ]
303
297
  }
304
298
  );
@@ -310,73 +304,67 @@ const N = ({ amount: e, label: d }) => /* @__PURE__ */ l(C, { direction: "column
310
304
  e.palette.chartMono.chartMono1,
311
305
  e.palette.chartMono.chartMono6
312
306
  ], Bt = () => {
313
- const e = Mt(), { is_mobile_webview: d } = V(), { clientConfig: o } = V(), {
314
- categories: r,
315
- dateRangeCategoryTotals: i,
316
- loadDateRangeCategoryTotals: s,
317
- dataRangeTotalsLoaded: n
318
- } = F(), {
307
+ const e = Mt(), { onLoad: d } = _t(), { is_mobile_webview: o } = V(), { clientConfig: l } = V(), { categories: s, dateRangeCategoryTotals: a, loadDateRangeCategoryTotals: n } = F(), {
319
308
  goals: u,
320
- spending: c,
309
+ spending: r,
321
310
  transactions: m
322
- } = w(), { displayedDateRange: g, selectedAccounts: h, selectedAccountGuids: v } = R(), {
311
+ } = w(), { displayedDateRange: p, selectedAccounts: h, selectedAccountGuids: v } = R(), {
323
312
  setFilter: _,
324
313
  sortedTransactions: f,
325
314
  sortedTransactionsWithSplits: O,
326
315
  tags: S
327
- } = Ct(), T = o?.master?.deep_link_params?.account_guids, k = o?.master?.deep_link_params?.view, [$, H] = a.useState(""), [I, pt] = a.useState(k === "income" ? 1 : 0), [K, U] = a.useState(""), [ut, X] = a.useState(!1);
328
- gt({
329
- widgetName: "SpendingWidget",
330
- isLoaded: n
331
- }), a.useEffect(() => {
332
- s(
316
+ } = Ct(), T = l?.master?.deep_link_params?.account_guids, k = l?.master?.deep_link_params?.view, [$, H] = i.useState(""), [L, pt] = i.useState(k === "income" ? 1 : 0), [K, U] = i.useState(""), [gt, X] = i.useState(!1);
317
+ i.useEffect(() => {
318
+ n(
333
319
  h,
334
- g.start,
335
- g.end
336
- ).finally();
337
- }, [h, g]);
338
- const B = a.useMemo(
339
- () => ct(r, u, e, i),
340
- [r, i]
341
- ), Y = a.useMemo(
342
- () => lt(r, i, $t(e)),
343
- [r, i]
344
- ), G = a.useMemo(
345
- () => f.find((p) => p.guid === K),
320
+ p.start,
321
+ p.end
322
+ ).finally(() => {
323
+ d?.("SpendingWidget");
324
+ });
325
+ }, [h, p]);
326
+ const B = i.useMemo(
327
+ () => ct(s, u, e, a),
328
+ [s, a]
329
+ ), Y = i.useMemo(
330
+ () => lt(s, a, $t(e)),
331
+ [s, a]
332
+ ), G = i.useMemo(
333
+ () => f.find((g) => g.guid === K),
346
334
  [K, f]
347
- ), mt = (p, D) => {
335
+ ), ut = (g, D) => {
348
336
  pt(D), H("");
349
- }, q = (p) => {
350
- H($ === p || p === "0" ? "" : p);
351
- }, J = (p) => {
337
+ }, q = (g) => {
338
+ H($ === g || g === "0" ? "" : g);
339
+ }, J = (g) => {
352
340
  const D = {
353
341
  accounts: T || v,
354
- dateRange: g
342
+ dateRange: p
355
343
  };
356
- if (I === 0)
357
- if (p === "other") {
344
+ if (L === 0)
345
+ if (g === "other") {
358
346
  const b = B.categoryData.find((j) => j.guid === "other");
359
347
  _({
360
348
  ...D,
361
- custom: (j) => !!b?.categoryTotals?.find((ft) => ft.guid === j.top_level_category_guid)
349
+ custom: (j) => !!b?.categoryTotals?.find((ht) => ht.guid === j.top_level_category_guid)
362
350
  });
363
351
  } else
364
352
  _({
365
353
  ...D,
366
- custom: (b) => p ? b.top_level_category_guid === p : b.top_level_category_guid !== L.INCOME && b.top_level_category_guid !== L.INVESTMENTS && b.top_level_category_guid !== L.TRANSFER,
367
- showSplits: !!p
354
+ custom: (b) => g ? b.top_level_category_guid === g : b.top_level_category_guid !== I.INCOME && b.top_level_category_guid !== I.INVESTMENTS && b.top_level_category_guid !== I.TRANSFER,
355
+ showSplits: !!g
368
356
  });
369
357
  else
370
358
  _({
371
359
  ...D,
372
- custom: (b) => p ? b.category_guid === p : b.category_guid === L.INCOME || b.top_level_category_guid === L.INCOME
360
+ custom: (b) => g ? b.category_guid === g : b.category_guid === I.INCOME || b.top_level_category_guid === I.INCOME
373
361
  });
374
362
  X(!0);
375
- }, ht = () => {
363
+ }, mt = () => {
376
364
  xt(O, S);
377
365
  };
378
- return /* @__PURE__ */ l(M, { children: [
379
- /* @__PURE__ */ l(st, { onChange: mt, value: I, variant: "fullWidth", children: [
366
+ return /* @__PURE__ */ c(M, { children: [
367
+ /* @__PURE__ */ c(rt, { onChange: ut, value: L, variant: "fullWidth", children: [
380
368
  /* @__PURE__ */ t(
381
369
  E,
382
370
  {
@@ -384,7 +372,7 @@ const N = ({ amount: e, label: d }) => /* @__PURE__ */ l(C, { direction: "column
384
372
  N,
385
373
  {
386
374
  amount: B.totalAmount,
387
- label: c.spend_tab_title
375
+ label: r.spend_tab_title
388
376
  }
389
377
  )
390
378
  }
@@ -396,45 +384,45 @@ const N = ({ amount: e, label: d }) => /* @__PURE__ */ l(C, { direction: "column
396
384
  N,
397
385
  {
398
386
  amount: Y.totalAmount,
399
- label: c.income_tab_title
387
+ label: r.income_tab_title
400
388
  }
401
389
  )
402
390
  }
403
391
  )
404
392
  ] }),
405
- I === 0 && /* @__PURE__ */ t(
393
+ L === 0 && /* @__PURE__ */ t(
406
394
  at,
407
395
  {
408
396
  data: B,
409
397
  onSelected: q,
410
398
  onViewTransactions: J,
411
399
  selectedId: $,
412
- title: c.spend_tab_title
400
+ title: r.spend_tab_title
413
401
  }
414
402
  ),
415
- I === 1 && /* @__PURE__ */ t(
403
+ L === 1 && /* @__PURE__ */ t(
416
404
  at,
417
405
  {
418
406
  data: Y,
419
407
  onSelected: q,
420
408
  onViewTransactions: J,
421
409
  selectedId: $,
422
- title: c.income_tab_title
410
+ title: r.income_tab_title
423
411
  }
424
412
  ),
425
413
  /* @__PURE__ */ t(
426
414
  nt,
427
415
  {
428
- ariaLabelClose: c.close_drawer_aria,
429
- isOpen: ut,
416
+ ariaLabelClose: r.close_drawer_aria,
417
+ isOpen: gt,
430
418
  onClose: () => X(!1),
431
- title: c.transactions_drawer_title,
432
- children: /* @__PURE__ */ l(C, { children: [
433
- !d && f.length > 0 && /* @__PURE__ */ t(C, { direction: "row", justifyContent: "right", mb: -24, mr: 8, mt: 8, zIndex: 1, children: /* @__PURE__ */ t(
419
+ title: r.transactions_drawer_title,
420
+ children: /* @__PURE__ */ c(C, { children: [
421
+ !o && f.length > 0 && /* @__PURE__ */ t(C, { direction: "row", justifyContent: "right", mb: -24, mr: 8, mt: 8, zIndex: 1, children: /* @__PURE__ */ t(
434
422
  Tt,
435
423
  {
436
- onClick: ht,
437
- startIcon: /* @__PURE__ */ t(_t, { name: "ios_share" }),
424
+ onClick: mt,
425
+ startIcon: /* @__PURE__ */ t(bt, { name: "ios_share" }),
438
426
  variant: "text",
439
427
  children: m.export_csv_btn
440
428
  }
@@ -446,38 +434,38 @@ const N = ({ amount: e, label: d }) => /* @__PURE__ */ l(C, { direction: "column
446
434
  /* @__PURE__ */ t(
447
435
  nt,
448
436
  {
449
- ariaLabelClose: c.close_drawer_aria,
437
+ ariaLabelClose: r.close_drawer_aria,
450
438
  isOpen: !!G,
451
439
  onClose: () => U(""),
452
- title: c.transaction_details_drawer_title,
440
+ title: r.transaction_details_drawer_title,
453
441
  children: G && /* @__PURE__ */ t(vt, { transaction: G })
454
442
  }
455
443
  )
456
444
  ] });
457
445
  }, Gt = x(Bt), jt = ({ onBackClick: e, sx: d = {} }) => {
458
- const { visibleAccounts: o } = dt(), { spending: r } = w(), { isCopyLoaded: i, isInitialized: s, setDisplayedDate: n, setSelectedAccounts: u } = R(), { onEvent: c } = yt(), { clientConfig: m } = V(), g = m?.master?.deep_link_params?.date_range, [h, v] = a.useState(!1);
459
- a.useEffect(() => {
446
+ const { visibleAccounts: o } = dt(), { spending: l } = w(), { isCopyLoaded: s, isInitialized: a, setDisplayedDate: n, setSelectedAccounts: u } = R(), { onEvent: r } = yt(), { clientConfig: m } = V(), p = m?.master?.deep_link_params?.date_range, [h, v] = i.useState(!1);
447
+ i.useEffect(() => {
460
448
  u(o);
461
- }, [o]), a.useEffect(() => {
462
- g && Array.isArray(g) && g.length === 2 ? n(g[0], g[1]) : n(it(Z()), rt(Z())), v(!0), c(ot.SPENDING_VIEW);
449
+ }, [o]), i.useEffect(() => {
450
+ p && Array.isArray(p) && p.length === 2 ? n(p[0], p[1]) : n(it(Z()), st(Z())), v(!0), r(ot.SPENDING_VIEW);
463
451
  }, []);
464
452
  const _ = (f) => {
465
453
  n(f[0], f[1]);
466
454
  };
467
- return !i || !s || !h ? /* @__PURE__ */ t(P, {}) : /* @__PURE__ */ t(
455
+ return !s || !a || !h ? /* @__PURE__ */ t(P, {}) : /* @__PURE__ */ t(
468
456
  At,
469
457
  {
470
458
  accountOptions: o,
471
459
  calendarActions: { onRangeChanged: _ },
472
- onAccountsFilterClick: () => c(ot.SPENDING_CLICK_FILTER),
460
+ onAccountsFilterClick: () => r(ot.SPENDING_CLICK_FILTER),
473
461
  onBackClick: e,
474
462
  sx: d,
475
- title: r.title,
476
- children: /* @__PURE__ */ t(M, { height: "calc(100dvh - 150px)", overflow: "scroll", width: "100%", children: /* @__PURE__ */ t(Gt, {}) })
463
+ title: l.title,
464
+ children: /* @__PURE__ */ t(M, { width: "100%", children: /* @__PURE__ */ t(Gt, {}) })
477
465
  }
478
466
  );
479
- }, Ce = x(jt);
467
+ }, _e = x(jt);
480
468
  export {
481
- _e as SpendingMiniWidget,
482
- Ce as SpendingWidget
469
+ be as SpendingMiniWidget,
470
+ _e as SpendingWidget
483
471
  };