@mx-cartographer/experiences 7.2.16-alpha.mm0 → 7.2.16

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.
@@ -1,15 +1,15 @@
1
1
  import { jsx as e, jsxs as a, Fragment as X } from "react/jsx-runtime";
2
2
  import h from "react";
3
- import { observer as R } from "mobx-react-lite";
3
+ import { observer as T } from "mobx-react-lite";
4
4
  import { endOfMonth as z } from "date-fns/endOfMonth";
5
5
  import { endOfToday as de } from "date-fns/endOfToday";
6
- import { startOfMonth as W } from "date-fns/startOfMonth";
6
+ import { startOfMonth as k } from "date-fns/startOfMonth";
7
7
  import { startOfToday as ue } from "date-fns/startOfToday";
8
8
  import { subDays as me } from "date-fns/subDays";
9
9
  import ae from "@mui/material/Skeleton";
10
10
  import c from "@mui/material/Stack";
11
- import { R as Ee } from "../RecurringSettings-G6_BbsIF.mjs";
12
- import { M as Gn } from "../RecurringSettings-G6_BbsIF.mjs";
11
+ import { R as Ee } from "../RecurringSettings-DZu2hw1r.mjs";
12
+ import { M as En } from "../RecurringSettings-DZu2hw1r.mjs";
13
13
  import { addMonths as ze } from "date-fns/addMonths";
14
14
  import { subMonths as Fe } from "date-fns/subMonths";
15
15
  import { isBefore as Ue } from "date-fns/isBefore";
@@ -28,32 +28,32 @@ import { isSameDay as nt } from "date-fns/isSameDay";
28
28
  import it from "@mui/material/Badge";
29
29
  import { PickersDay as rt } from "@mui/x-date-pickers/PickersDay";
30
30
  import { I as q } from "../IconBacking-B9oC6uL2.mjs";
31
- import { u as T, b as Z, j as v, g as J, q as Oe, d as he, h as fe, n as ot } from "../hooks-D6XlXHf4.mjs";
32
- import { c as L, a as S, g as Ie, f as at } from "../RecurringTransactions-ej39mgA6.mjs";
31
+ import { u as D, b as Z, j as I, g as J, q as Oe, d as he, h as fe } from "../hooks-D6XlXHf4.mjs";
32
+ import { c as M, a as S, g as Ie, f as ot } from "../RecurringTransactions-ej39mgA6.mjs";
33
33
  import { T as B } from "../RecurringTransactionsStore-DrzS1LmF.mjs";
34
- import { R as On } from "../RecurringTransactionsStore-DrzS1LmF.mjs";
35
- import { A as I, W as st } from "../WidgetContainer-EbrN1oIo.mjs";
36
- import ct from "@mui/material/Button";
34
+ import { R as Nn } from "../RecurringTransactionsStore-DrzS1LmF.mjs";
35
+ import { A as w, W as at } from "../WidgetContainer-EbrN1oIo.mjs";
36
+ import st from "@mui/material/Button";
37
37
  import le from "@mui/material/Divider";
38
38
  import ve from "@mui/material/List";
39
39
  import ke from "@mui/material/ListItem";
40
- import lt from "@mui/material/ListSubheader";
41
- import dt from "@mui/material/ListItemAvatar";
42
- import ut from "@mui/material/ListItemButton";
43
- import mt from "@mui/material/ListItemText";
44
- import { b as pt } from "../ManageIncome-CV-bGuR-.mjs";
45
- import { c as Wn, M as $n, S as Pn } from "../ManageIncome-CV-bGuR-.mjs";
46
- import { f as A } from "../NumberFormatting-Buh7u8Oi.mjs";
40
+ import ct from "@mui/material/ListSubheader";
41
+ import lt from "@mui/material/ListItemAvatar";
42
+ import dt from "@mui/material/ListItemButton";
43
+ import ut from "@mui/material/ListItemText";
44
+ import { b as mt } from "../ManageIncome-CsCM4rNt.mjs";
45
+ import { c as kn, M as Wn, S as $n } from "../ManageIncome-CsCM4rNt.mjs";
46
+ import { f as L } from "../NumberFormatting-Buh7u8Oi.mjs";
47
47
  import { D as xe } from "../Drawer-kEE73B87.mjs";
48
- import { b as O } from "../Localization-2MODESHW.mjs";
49
- import { f as E, D as G } from "../Dialog-CWW597AF.mjs";
50
- import k from "@mui/material/Box";
48
+ import { b as N } from "../Localization-2MODESHW.mjs";
49
+ import { f as A, D as E } from "../Dialog-CWW597AF.mjs";
50
+ import O from "@mui/material/Box";
51
51
  import { S as We } from "../StatusBar-BK_uYHAB.mjs";
52
52
  import { u as ye } from "../useScreenSize-B6JyS_Lj.mjs";
53
53
  import { L as V } from "../Loader-DUaFpDGv.mjs";
54
- import { M as gt } from "../MiniWidgetContainer-D0gfmbaF.mjs";
55
- import { u as ht } from "../useDimensions-27p2evRx.mjs";
56
- import { M as ft } from "../MicroWidgetContainer-DpeqN9n3.mjs";
54
+ import { M as pt } from "../MiniWidgetContainer-D0gfmbaF.mjs";
55
+ import { u as gt } from "../useDimensions-27p2evRx.mjs";
56
+ import { M as ht } from "../MicroWidgetContainer-DpeqN9n3.mjs";
57
57
  const Q = {
58
58
  gridRow: 1,
59
59
  gridColumn: 1,
@@ -64,20 +64,20 @@ const Q = {
64
64
  filled: !0,
65
65
  sx: { color: "categories.income", fontSize: n, ...Q }
66
66
  }
67
- ) }), Re = ({ isOffset: t = !1, size: n = 16 }) => /* @__PURE__ */ e(q, { size: n, sx: { ...ee(t) }, children: /* @__PURE__ */ e(Ge, { color: "error", filled: !0, sx: { fontSize: n, ...Q } }) }), Te = ({ isOffset: t = !1, size: n = 16 }) => /* @__PURE__ */ e(q, { size: n, sx: { ...ee(t) }, children: /* @__PURE__ */ e(Ne, { color: "success", filled: !0, sx: { fontSize: n, ...Q } }) }), xt = R(
67
+ ) }), Re = ({ isOffset: t = !1, size: n = 16 }) => /* @__PURE__ */ e(q, { size: n, sx: { ...ee(t) }, children: /* @__PURE__ */ e(Ge, { color: "error", filled: !0, sx: { fontSize: n, ...Q } }) }), Te = ({ isOffset: t = !1, size: n = 16 }) => /* @__PURE__ */ e(q, { size: n, sx: { ...ee(t) }, children: /* @__PURE__ */ e(Ne, { color: "success", filled: !0, sx: { fontSize: n, ...Q } }) }), ft = T(
68
68
  ({ day: t, outsideCurrentMonth: n, ...i }) => {
69
- const { recurring: r } = T(), { selectedAccountGuids: o } = Z(), { recurrences: l, setSelectedDay: m } = v(), s = h.useMemo(
69
+ const { recurring: r } = D(), { selectedAccountGuids: o } = Z(), { recurrences: l, setSelectedDay: m } = I(), s = h.useMemo(
70
70
  () => l.filter((d) => o.includes(d.accountGuid)),
71
71
  [o, l]
72
72
  ).filter(
73
73
  (d) => nt(d.occurredOnDate || d.expectedDate, t)
74
74
  ), u = s.some(
75
- (d) => d.type !== L.Income && d.status === S.Upcoming
75
+ (d) => d.type !== M.Income && d.status === S.Upcoming
76
76
  ), f = s.some(
77
- (d) => d.type !== L.Income && d.status === S.Missed
77
+ (d) => d.type !== M.Income && d.status === S.Missed
78
78
  ), x = s.some(
79
- (d) => d.type !== L.Income && d.status === S.Paid
80
- ), C = s.some((d) => d.type === L.Income), y = (u ? 1 : 0) + (f ? 1 : 0) + (x ? 1 : 0) + (C ? 1 : 0);
79
+ (d) => d.type !== M.Income && d.status === S.Paid
80
+ ), C = s.some((d) => d.type === M.Income), y = (u ? 1 : 0) + (f ? 1 : 0) + (x ? 1 : 0) + (C ? 1 : 0);
81
81
  return /* @__PURE__ */ e(
82
82
  it,
83
83
  {
@@ -122,8 +122,8 @@ const Q = {
122
122
  ), Y = ({ icon: t, label: n }) => /* @__PURE__ */ a(c, { alignItems: "center", flexDirection: "row", sx: { gap: 6 }, children: [
123
123
  /* @__PURE__ */ e(t, {}),
124
124
  /* @__PURE__ */ e(p, { variant: "XSmall", children: n })
125
- ] }), yt = R(() => {
126
- const { recurring: t } = T();
125
+ ] }), xt = T(() => {
126
+ const { recurring: t } = D();
127
127
  return /* @__PURE__ */ a(
128
128
  c,
129
129
  {
@@ -141,22 +141,22 @@ const Q = {
141
141
  ]
142
142
  }
143
143
  );
144
- }), Me = 58, $e = R(() => {
145
- const t = ge(), { onEvent: n } = J(), { selectedDay: i, setDateRange: r } = v(), [o, l] = h.useState(
144
+ }), Me = 58, $e = T(() => {
145
+ const t = ge(), { onEvent: n } = J(), { selectedDay: i, setDateRange: r } = I(), [o, l] = h.useState(
146
146
  we(/* @__PURE__ */ new Date()) * B + Me
147
147
  ), m = (s) => {
148
148
  l(we(s) * B + Me), r({
149
- start: W(s),
149
+ start: k(s),
150
150
  end: z(s)
151
- }), n(I.RECURRING_TRANSACTIONS_CLICK_CALENDAR_RIGHT);
151
+ }), n(w.RECURRING_TRANSACTIONS_CLICK_CALENDAR_RIGHT);
152
152
  }, g = /* @__PURE__ */ e(
153
153
  et,
154
154
  {
155
- minDate: W(/* @__PURE__ */ new Date()),
155
+ minDate: k(/* @__PURE__ */ new Date()),
156
156
  onMonthChange: m,
157
157
  showDaysOutsideCurrentMonth: !0,
158
158
  slots: {
159
- day: xt
159
+ day: ft
160
160
  },
161
161
  sx: {
162
162
  "& .MuiPickersArrowSwitcher-button": {
@@ -204,10 +204,10 @@ const Q = {
204
204
  return /* @__PURE__ */ e(c, { justifyContent: "center", children: /* @__PURE__ */ a(tt, { dateAdapter: Qe, children: [
205
205
  i && g,
206
206
  !i && g,
207
- /* @__PURE__ */ e(yt, {})
207
+ /* @__PURE__ */ e(xt, {})
208
208
  ] }) });
209
- }), Ct = (t) => {
210
- if (t.type === L.Income)
209
+ }), yt = (t) => {
210
+ if (t.type === M.Income)
211
211
  return /* @__PURE__ */ e(be, {});
212
212
  switch (t.status) {
213
213
  case S.Missed:
@@ -217,25 +217,25 @@ const Q = {
217
217
  default:
218
218
  return /* @__PURE__ */ e(Ce, {});
219
219
  }
220
- }, bt = (t, n) => {
220
+ }, Ct = (t, n) => {
221
221
  switch (t.status) {
222
222
  case S.Paid:
223
- return t.expectedDate ? O(
223
+ return t.expectedDate ? N(
224
224
  n.paid_on,
225
- E(
225
+ A(
226
226
  t.occurredOnDate || t.expectedDate,
227
- G.MONTH_DAY
227
+ E.MONTH_DAY
228
228
  )
229
229
  ) : n.paid;
230
230
  case S.Missed:
231
- return O(
231
+ return N(
232
232
  n.missed_on,
233
- E(t.expectedDate, G.MONTH_DAY)
233
+ A(t.expectedDate, E.MONTH_DAY)
234
234
  );
235
235
  case S.Upcoming:
236
- return O(
236
+ return N(
237
237
  n.upcoming_on,
238
- E(t.expectedDate, G.MONTH_DAY)
238
+ A(t.expectedDate, E.MONTH_DAY)
239
239
  );
240
240
  default:
241
241
  return n.unknown;
@@ -247,24 +247,24 @@ const Q = {
247
247
  },
248
248
  showOrdinal: r = !1
249
249
  }) => {
250
- const { recurring: o } = T(), { repeatingTransactions: l } = v(), [m, g] = h.useState(!1), s = h.useMemo(
251
- () => l.find((D) => D.guid === t.repeatingTransactionGuid),
250
+ const { recurring: o } = D(), { repeatingTransactions: l } = I(), [m, g] = h.useState(!1), s = h.useMemo(
251
+ () => l.find((b) => b.guid === t.repeatingTransactionGuid),
252
252
  [t, l]
253
- ), u = t.type === L.Income, f = t.status === S.Paid, x = t.status === S.Missed, C = t.status === S.Upcoming;
253
+ ), u = t.type === M.Income, f = t.status === S.Paid, x = t.status === S.Missed, C = t.status === S.Upcoming;
254
254
  let y = o.paid?.toLowerCase();
255
255
  return x ? y = o.missed?.toLowerCase() : C && (y = r ? Ie(o, s || {}, !0) : Ie(o, s || {}, !1)), //TODO: implement common/components/ListItemRow.tsx
256
256
  /* @__PURE__ */ a(ke, { disableGutters: !0, disablePadding: !0, children: [
257
- /* @__PURE__ */ a(ut, { onClick: () => {
257
+ /* @__PURE__ */ a(dt, { onClick: () => {
258
258
  g(!0), i(t);
259
259
  }, children: [
260
- /* @__PURE__ */ e(dt, { children: /* @__PURE__ */ e(
260
+ /* @__PURE__ */ e(lt, { children: /* @__PURE__ */ e(
261
261
  pe,
262
262
  {
263
263
  categoryGuid: t.categoryGuid,
264
264
  merchantGuid: t.merchantGuid
265
265
  }
266
266
  ) }),
267
- /* @__PURE__ */ e(mt, { children: /* @__PURE__ */ a(
267
+ /* @__PURE__ */ e(ut, { children: /* @__PURE__ */ a(
268
268
  c,
269
269
  {
270
270
  direction: "row",
@@ -274,8 +274,8 @@ const Q = {
274
274
  /* @__PURE__ */ a(c, { direction: "column", width: "50%", children: [
275
275
  /* @__PURE__ */ e(p, { bold: !0, variant: "body1", children: t.name }),
276
276
  /* @__PURE__ */ e(c, { alignItems: "center", direction: "row", gap: 6, children: n ? /* @__PURE__ */ a(c, { direction: "row", gap: 4, children: [
277
- Ct(t),
278
- /* @__PURE__ */ e(p, { variant: "caption", children: bt(t, o) })
277
+ yt(t),
278
+ /* @__PURE__ */ e(p, { variant: "caption", children: Ct(t, o) })
279
279
  ] }) : /* @__PURE__ */ a(X, { children: [
280
280
  t.institutionGuid && /* @__PURE__ */ e(
281
281
  Ze,
@@ -291,7 +291,7 @@ const Q = {
291
291
  /* @__PURE__ */ a(c, { alignItems: "flex-end", width: "100%", children: [
292
292
  /* @__PURE__ */ a(p, { bold: !0, color: u ? "success.main" : "text.primary", variant: "body1", children: [
293
293
  u ? "+" : "",
294
- A(t.amount, "0,0.00")
294
+ L(t.amount, "0,0.00")
295
295
  ] }),
296
296
  !n && /* @__PURE__ */ a(
297
297
  c,
@@ -322,9 +322,9 @@ const Q = {
322
322
  ariaLabelClose: o.close_drawer_aria,
323
323
  isOpen: m,
324
324
  onClose: () => g(!1),
325
- title: t.type === L.Income ? o.income_details : o.expense_details,
325
+ title: t.type === M.Income ? o.income_details : o.expense_details,
326
326
  children: s && /* @__PURE__ */ e(
327
- pt,
327
+ mt,
328
328
  {
329
329
  onDeleted: () => g(!1),
330
330
  recurringTransaction: s
@@ -333,7 +333,7 @@ const Q = {
333
333
  }
334
334
  )
335
335
  ] });
336
- }, H = R(
336
+ }, H = T(
337
337
  ({
338
338
  recurrences: t,
339
339
  isMini: n = !1,
@@ -342,7 +342,7 @@ const Q = {
342
342
  sx: o = {},
343
343
  title: l
344
344
  }) => {
345
- const { recurring: m } = T(), g = h.useMemo(() => at(t), [t]);
345
+ const { recurring: m } = D(), g = h.useMemo(() => ot(t), [t]);
346
346
  return /* @__PURE__ */ a(c, { sx: { gap: 8, mt: 4, ...o }, children: [
347
347
  l && /* @__PURE__ */ a(
348
348
  c,
@@ -350,7 +350,7 @@ const Q = {
350
350
  sx: { alignItems: "top", direction: "row", justifyContent: "space-between", px: 24 },
351
351
  children: [
352
352
  /* @__PURE__ */ e(p, { bold: !0, variant: "body1", children: l }),
353
- i && /* @__PURE__ */ e(ct, { onClick: i, sx: { mt: -12 }, variant: "text", children: m.reset })
353
+ i && /* @__PURE__ */ e(st, { onClick: i, sx: { mt: -12 }, variant: "text", children: m.reset })
354
354
  ]
355
355
  }
356
356
  ),
@@ -368,7 +368,7 @@ const Q = {
368
368
  /* @__PURE__ */ e(ke, { children: /* @__PURE__ */ e(
369
369
  ve,
370
370
  {
371
- subheader: /* @__PURE__ */ e(lt, { sx: { bgcolor: "background.paper", ml: 8, pb: 4, pt: 12 }, children: /* @__PURE__ */ e(p, { bold: !0, variant: "caption", children: E(s.date, G.DAY_OF_WEEK_MONTH_DAY) }) }),
371
+ subheader: /* @__PURE__ */ e(ct, { sx: { bgcolor: "background.paper", ml: 8, pb: 4, pt: 12 }, children: /* @__PURE__ */ e(p, { bold: !0, variant: "caption", children: A(s.date, E.DAY_OF_WEEK_MONTH_DAY) }) }),
372
372
  sx: { width: "100%" },
373
373
  children: s.recurrences.map((f, x) => /* @__PURE__ */ e(h.Fragment, { children: /* @__PURE__ */ e(
374
374
  Le,
@@ -384,35 +384,35 @@ const Q = {
384
384
  ] }, `recurrence-${u}`)) })
385
385
  ] });
386
386
  }
387
- ), Ae = R(
387
+ ), Ae = T(
388
388
  ({ expected: t, isExpense: n = !0, missed: i, paid: r, title: o, total: l, upcoming: m }) => {
389
- const g = ge(), { isSmallMobile: s } = ye(), { recurring: u } = T(), f = h.useMemo(() => {
389
+ const g = ge(), { isSmallMobile: s } = ye(), { recurring: u } = D(), f = h.useMemo(() => {
390
390
  const x = [{ color: g.palette.success.main, percentage: `${r / t}` }];
391
391
  return i && x.push({ color: g.palette.error.main, percentage: `${i / t}` }), x;
392
392
  }, [r, t, i]);
393
393
  return /* @__PURE__ */ a(c, { children: [
394
394
  /* @__PURE__ */ a(c, { sx: { flexDirection: "row", justifyContent: "space-between", pb: 12 }, children: [
395
395
  /* @__PURE__ */ e(p, { bold: !0, variant: "body1", children: `${o} (${l})` }),
396
- /* @__PURE__ */ e(p, { bold: !0, color: n ? "text.primary" : "success.main", variant: "body1", children: `${n ? "-" : "+"}${A(t, "0,0.00")}` })
396
+ /* @__PURE__ */ e(p, { bold: !0, color: n ? "text.primary" : "success.main", variant: "body1", children: `${n ? "-" : "+"}${L(t, "0,0.00")}` })
397
397
  ] }),
398
398
  /* @__PURE__ */ e(We, { data: f, height: 12 }),
399
399
  /* @__PURE__ */ a(c, { sx: { alignItems: "center", flexDirection: "row", gap: 2, my: 8 }, children: [
400
- /* @__PURE__ */ e(k, { sx: { bgcolor: "success.main", height: 8, mr: 8, width: 8 } }),
401
- !s && /* @__PURE__ */ e(p, { bold: !0, variant: "body2", children: A(r, "0,0.00") }),
400
+ /* @__PURE__ */ e(O, { sx: { bgcolor: "success.main", height: 8, mr: 8, width: 8 } }),
401
+ !s && /* @__PURE__ */ e(p, { bold: !0, variant: "body2", children: L(r, "0,0.00") }),
402
402
  /* @__PURE__ */ e(p, { variant: "caption", children: u.paid?.toLowerCase() }),
403
403
  i !== void 0 && /* @__PURE__ */ a(X, { children: [
404
- /* @__PURE__ */ e(k, { sx: { bgcolor: "error.main", height: 8, ml: 16, mr: 8, width: 8 } }),
405
- !s && /* @__PURE__ */ e(p, { bold: !0, variant: "body2", children: A(i, "0,0.00") }),
404
+ /* @__PURE__ */ e(O, { sx: { bgcolor: "error.main", height: 8, ml: 16, mr: 8, width: 8 } }),
405
+ !s && /* @__PURE__ */ e(p, { bold: !0, variant: "body2", children: L(i, "0,0.00") }),
406
406
  /* @__PURE__ */ e(p, { variant: "caption", children: u.missed?.toLowerCase() })
407
407
  ] }),
408
- /* @__PURE__ */ e(k, { sx: { bgcolor: "divider", height: 8, ml: 16, mr: 8, width: 8 } }),
409
- !s && /* @__PURE__ */ e(p, { bold: !0, variant: "body2", children: A(m, "0,0.00") }),
408
+ /* @__PURE__ */ e(O, { sx: { bgcolor: "divider", height: 8, ml: 16, mr: 8, width: 8 } }),
409
+ !s && /* @__PURE__ */ e(p, { bold: !0, variant: "body2", children: L(m, "0,0.00") }),
410
410
  /* @__PURE__ */ e(p, { variant: "caption", children: u.upcoming })
411
411
  ] })
412
412
  ] });
413
413
  }
414
- ), Rt = R(() => {
415
- const { recurring: t } = T(), { availableWidth: n } = Oe(), { isDesktop: i, isSmallMobile: r, isMobile: o } = ye(n), { onEvent: l } = J(), {
414
+ ), bt = T(() => {
415
+ const { recurring: t } = D(), { availableWidth: n } = Oe(), { isDesktop: i, isSmallMobile: r, isMobile: o } = ye(n), { onEvent: l } = J(), {
416
416
  currentMonthExpenses: m,
417
417
  currentMonthIncome: g,
418
418
  dateRange: s,
@@ -422,33 +422,33 @@ const Q = {
422
422
  pastRecurrences: C,
423
423
  paidExpenseTotal: y,
424
424
  paidIncomeTotal: d,
425
- selectedDay: D,
426
- selectedDayRecurrences: _,
425
+ selectedDay: b,
426
+ selectedDayRecurrences: W,
427
427
  setDateRange: F,
428
428
  upcomingExpenseTotal: te,
429
429
  upcomingIncomeTotal: ne,
430
430
  upcomingRecurrences: U
431
- } = v(), [$, w] = h.useState(0), ie = Ue(s.start, /* @__PURE__ */ new Date()), M = (b, oe) => {
432
- w(oe);
433
- }, j = (b) => {
434
- l(I.RECURRING_TRANSACTIONS_CLICK_UPCOMING, {
435
- transaction_guid: b.transaction?.guid
431
+ } = I(), [$, _] = h.useState(0), ie = Ue(s.start, /* @__PURE__ */ new Date()), v = (R, oe) => {
432
+ _(oe);
433
+ }, j = (R) => {
434
+ l(w.RECURRING_TRANSACTIONS_CLICK_UPCOMING, {
435
+ transaction_guid: R.transaction?.guid
436
436
  });
437
- }, K = (b) => {
438
- l(I.RECURRING_TRANSACTIONS_CLICK_PAID, {
439
- transaction_guid: b.transaction?.guid
437
+ }, K = (R) => {
438
+ l(w.RECURRING_TRANSACTIONS_CLICK_PAID, {
439
+ transaction_guid: R.transaction?.guid
440
440
  });
441
441
  }, P = () => {
442
- const b = ze(s.start, 1);
442
+ const R = ze(s.start, 1);
443
443
  F({
444
- start: W(b),
445
- end: z(b)
444
+ start: k(R),
445
+ end: z(R)
446
446
  });
447
447
  }, re = () => {
448
- const b = Fe(s.start, 1);
448
+ const R = Fe(s.start, 1);
449
449
  F({
450
- start: W(b),
451
- end: z(b)
450
+ start: k(R),
451
+ end: z(R)
452
452
  });
453
453
  };
454
454
  return /* @__PURE__ */ a(
@@ -462,9 +462,9 @@ const Q = {
462
462
  /* @__PURE__ */ a(se, { md: !0, sm: 12, width: "100%", children: [
463
463
  /* @__PURE__ */ a(c, { sx: { gap: 16, px: i ? 48 : 24 }, children: [
464
464
  /* @__PURE__ */ a(c, { alignItems: "center", direction: "row", justifyContent: "space-between", children: [
465
- /* @__PURE__ */ e(Je, { children: O(
465
+ /* @__PURE__ */ e(Je, { children: N(
466
466
  t.header_title,
467
- E(s.start, G.MONTH_LONG)
467
+ A(s.start, E.MONTH_LONG)
468
468
  ) }),
469
469
  !i && /* @__PURE__ */ a(c, { direction: "row", gap: 4, children: [
470
470
  /* @__PURE__ */ e(
@@ -511,7 +511,7 @@ const Q = {
511
511
  )
512
512
  ] }),
513
513
  !i && /* @__PURE__ */ a(c, { sx: { px: o ? 0 : 24 }, children: [
514
- /* @__PURE__ */ a(je, { onChange: M, value: $, variant: "fullWidth", children: [
514
+ /* @__PURE__ */ a(je, { onChange: v, value: $, variant: "fullWidth", children: [
515
515
  /* @__PURE__ */ e(
516
516
  _e,
517
517
  {
@@ -547,10 +547,10 @@ const Q = {
547
547
  H,
548
548
  {
549
549
  onRecurrenceClick: K,
550
- recurrences: _ || C,
551
- title: D ? O(
550
+ recurrences: W || C,
551
+ title: b ? N(
552
552
  t.day_transactions,
553
- E(D, G.MONTH_DAY)
553
+ A(b, E.MONTH_DAY)
554
554
  ) : t.past_transactions
555
555
  }
556
556
  )
@@ -558,19 +558,17 @@ const Q = {
558
558
  ]
559
559
  }
560
560
  );
561
- }), In = R(({ onBackClick: t, sx: n = {} }) => {
562
- const { accounts: i } = he(), { recurring: r } = T(), { isCopyLoaded: o, isInitialized: l, selectedAccountGuids: m, setSelectedAccounts: g } = Z(), { isDataLoaded: s, loadRepeatingTransactions: u, setDateRange: f } = v(), { setFilter: x } = fe(), { onEvent: C } = J(), { onLoad: y } = ot(), { isMobile: d } = ye(), [D, _] = h.useState(!1);
561
+ }), wn = T(({ onBackClick: t, sx: n = {} }) => {
562
+ const { accounts: i } = he(), { recurring: r } = D(), { isCopyLoaded: o, isInitialized: l, selectedAccountGuids: m, setSelectedAccounts: g } = Z(), { isDataLoaded: s, loadRepeatingTransactions: u, setDateRange: f } = I(), { setFilter: x } = fe(), { onEvent: C } = J(), { isMobile: y } = ye(), [d, b] = h.useState(!1);
563
563
  return h.useEffect(() => {
564
564
  g(i);
565
565
  }, [i]), h.useEffect(() => {
566
566
  l && (x({
567
567
  dateRange: { start: me(ue(), 90), end: de() },
568
568
  accounts: m
569
- }), f({ start: W(/* @__PURE__ */ new Date()), end: z(/* @__PURE__ */ new Date()) }), u().finally(() => {
570
- y?.("RecurringTransactionsWidget");
571
- }));
569
+ }), f({ start: k(/* @__PURE__ */ new Date()), end: z(/* @__PURE__ */ new Date()) }), u().finally());
572
570
  }, [l]), o ? /* @__PURE__ */ a(
573
- st,
571
+ at,
574
572
  {
575
573
  accountOptions: i,
576
574
  actions: [
@@ -578,17 +576,17 @@ const Q = {
578
576
  label: r.action_title,
579
577
  iconName: "credit_card_gear",
580
578
  onClick: () => {
581
- _(!0), C(I.RECURRING_TRANSACTIONS_CLICK_SETTINGS);
579
+ b(!0), C(w.RECURRING_TRANSACTIONS_CLICK_SETTINGS);
582
580
  }
583
581
  }
584
582
  ],
585
- hasDivider: d,
586
- onAccountsFilterClick: () => C(I.RECURRING_TRANSACTIONS_CLICK_FILTER),
583
+ hasDivider: y,
584
+ onAccountsFilterClick: () => C(w.RECURRING_TRANSACTIONS_CLICK_FILTER),
587
585
  onBackClick: t,
588
586
  sx: n,
589
587
  title: r.title,
590
588
  children: [
591
- l && s ? /* @__PURE__ */ e(Rt, {}) : /* @__PURE__ */ a(c, { direction: "column", p: 48, spacing: 24, children: [
589
+ l && s ? /* @__PURE__ */ e(bt, {}) : /* @__PURE__ */ a(c, { direction: "column", p: 48, spacing: 24, children: [
592
590
  /* @__PURE__ */ e(ae, { height: 100, variant: "rounded", width: "100%" }),
593
591
  /* @__PURE__ */ e(ae, { height: 100, variant: "rounded", width: "100%" }),
594
592
  /* @__PURE__ */ e(ae, { height: 600, variant: "rounded", width: "100%" })
@@ -597,8 +595,8 @@ const Q = {
597
595
  xe,
598
596
  {
599
597
  ariaLabelClose: r.close_drawer_aria,
600
- isOpen: D,
601
- onClose: () => _(!1),
598
+ isOpen: d,
599
+ onClose: () => b(!1),
602
600
  shouldShowHeaderBorders: !1,
603
601
  title: r.action_title,
604
602
  children: /* @__PURE__ */ e(Ee, {})
@@ -607,8 +605,8 @@ const Q = {
607
605
  ]
608
606
  }
609
607
  ) : /* @__PURE__ */ e(V, {});
610
- }), Tt = R(() => {
611
- const { recurring: t } = T(), { availableWidth: n } = Oe(), { selectedDay: i, selectedDayRecurrences: r, setSelectedDay: o, upcomingRecurrences: l } = v(), m = n < 750;
608
+ }), Rt = T(() => {
609
+ const { recurring: t } = D(), { availableWidth: n } = Oe(), { selectedDay: i, selectedDayRecurrences: r, setSelectedDay: o, upcomingRecurrences: l } = I(), m = n < 750;
612
610
  return /* @__PURE__ */ a(c, { flexDirection: m ? "column" : "row", width: "100%", children: [
613
611
  /* @__PURE__ */ e($e, {}),
614
612
  !m && /* @__PURE__ */ e(le, { flexItem: !0, orientation: "vertical", sx: { my: 16, ml: 16 } }),
@@ -619,16 +617,16 @@ const Q = {
619
617
  onResetClick: i ? () => o(i) : void 0,
620
618
  recurrences: r || l.slice(0, 5),
621
619
  sx: { width: m ? "100%" : "calc(100% - 336px)", mt: 12 },
622
- title: i ? O(
620
+ title: i ? N(
623
621
  t.day_transactions,
624
- E(i, G.MONTH_DAY)
622
+ A(i, E.MONTH_DAY)
625
623
  ) : t.upcoming_activity
626
624
  }
627
625
  )
628
626
  ] });
629
- }), vn = R(
627
+ }), In = T(
630
628
  ({ onPrimaryCtaClick: t, sx: n }) => {
631
- const { accounts: i } = he(), { recurring: r } = T(), { setFilter: o } = fe(), { isDataLoaded: l, loadRepeatingTransactions: m } = v(), { isCopyLoaded: g, isInitialized: s, setSelectedAccounts: u, selectedAccountGuids: f } = Z();
629
+ const { accounts: i } = he(), { recurring: r } = D(), { setFilter: o } = fe(), { isDataLoaded: l, loadRepeatingTransactions: m } = I(), { isCopyLoaded: g, isInitialized: s, setSelectedAccounts: u, selectedAccountGuids: f } = Z();
632
630
  return h.useEffect(() => {
633
631
  s && u(i);
634
632
  }, [s]), h.useEffect(() => {
@@ -637,7 +635,7 @@ const Q = {
637
635
  accounts: f
638
636
  }), m().finally());
639
637
  }, [f]), !g || !s ? /* @__PURE__ */ e(V, {}) : /* @__PURE__ */ e(
640
- gt,
638
+ pt,
641
639
  {
642
640
  className: "mx-exp-recurring-transactions-miniwidget",
643
641
  onPrimaryCtaClick: t,
@@ -645,11 +643,11 @@ const Q = {
645
643
  subTitle: r.sub_title,
646
644
  sx: n,
647
645
  title: r.mini_title,
648
- children: l ? /* @__PURE__ */ e(Tt, {}) : /* @__PURE__ */ e(V, {})
646
+ children: l ? /* @__PURE__ */ e(Rt, {}) : /* @__PURE__ */ e(V, {})
649
647
  }
650
648
  );
651
649
  }
652
- ), Dt = ({
650
+ ), Tt = ({
653
651
  upcomingRecurrences: t,
654
652
  maxLogos: n = 3
655
653
  }) => /* @__PURE__ */ e(c, { sx: { flexDirection: "row", gap: 4 }, children: t?.slice(0, n).map((i, r) => /* @__PURE__ */ e(
@@ -659,21 +657,21 @@ const Q = {
659
657
  merchantGuid: i.merchantGuid || ""
660
658
  },
661
659
  `${i.categoryGuid}-${i.merchantGuid}-${r}`
662
- )) }), St = ({
660
+ )) }), Dt = ({
663
661
  upcomingRecurrences: t,
664
662
  logoSize: n = 32,
665
663
  maxLogos: i = 3
666
664
  }) => {
667
665
  const r = (o) => o * (n / 2);
668
666
  return /* @__PURE__ */ e(
669
- k,
667
+ O,
670
668
  {
671
669
  sx: {
672
670
  position: "relative",
673
671
  width: 64
674
672
  },
675
673
  children: t.map((o, l) => l < i ? /* @__PURE__ */ e(
676
- k,
674
+ O,
677
675
  {
678
676
  sx: {
679
677
  borderRadius: "4px",
@@ -696,7 +694,7 @@ const Q = {
696
694
  ) : null)
697
695
  }
698
696
  );
699
- }, _t = ({
697
+ }, St = ({
700
698
  amount: t,
701
699
  bgcolor: n,
702
700
  isLargeScreen: i,
@@ -704,7 +702,7 @@ const Q = {
704
702
  label: o
705
703
  }) => /* @__PURE__ */ a(c, { sx: { alignItems: "center", flexDirection: "row", gap: 8 }, children: [
706
704
  /* @__PURE__ */ e(
707
- k,
705
+ O,
708
706
  {
709
707
  sx: {
710
708
  borderRadius: "2px",
@@ -715,11 +713,11 @@ const Q = {
715
713
  }
716
714
  ),
717
715
  /* @__PURE__ */ a(c, { sx: { alignItems: "center", flexDirection: "row", gap: 2 }, children: [
718
- !r && /* @__PURE__ */ e(p, { bold: !0, variant: "caption", children: A(t, t === 0 || !i ? "0,0" : "0,0.00") }),
716
+ !r && /* @__PURE__ */ e(p, { bold: !0, variant: "caption", children: L(t, t === 0 || !i ? "0,0" : "0,0.00") }),
719
717
  /* @__PURE__ */ e(p, { variant: "caption", children: o })
720
718
  ] })
721
- ] }), wt = R(() => {
722
- const { recurring: t } = T();
719
+ ] }), _t = T(() => {
720
+ const { recurring: t } = D();
723
721
  return /* @__PURE__ */ a(c, { sx: { alignItems: "start", flexDirection: "row", gap: 12 }, children: [
724
722
  /* @__PURE__ */ e(qe, { size: 32 }),
725
723
  /* @__PURE__ */ a(c, { children: [
@@ -727,83 +725,83 @@ const Q = {
727
725
  /* @__PURE__ */ e(ce, { color: "text.secondary", variant: "subtitle2", children: t.zero_state_content_description })
728
726
  ] })
729
727
  ] });
730
- }), Mn = R(
728
+ }), vn = T(
731
729
  ({ onCTAClick: t }) => {
732
- const [n, i] = h.useState(!1), { onEvent: r } = J(), o = ge(), { accounts: l } = he(), [m, { width: g }] = ht(), { isCopyLoaded: s, isInitialized: u, selectedAccountGuids: f, setSelectedAccounts: x } = Z(), {
730
+ const [n, i] = h.useState(!1), { onEvent: r } = J(), o = ge(), { accounts: l } = he(), [m, { width: g }] = gt(), { isCopyLoaded: s, isInitialized: u, selectedAccountGuids: f, setSelectedAccounts: x } = Z(), {
733
731
  loadRepeatingTransactions: C,
734
732
  upcomingRecurrences: y,
735
733
  expenseTotal: d,
736
- missedExpenseTotal: D,
737
- paidExpenseTotal: _,
734
+ missedExpenseTotal: b,
735
+ paidExpenseTotal: W,
738
736
  repeatingTransactions: F,
739
737
  setDateRange: te,
740
738
  upcomingExpenseTotal: ne,
741
739
  isDataLoaded: U
742
- } = v(), { setFilter: $ } = fe(), { recurring: w, budgets: ie } = T();
740
+ } = I(), { setFilter: $ } = fe(), { recurring: _, budgets: ie } = D();
743
741
  h.useEffect(() => {
744
742
  x(l);
745
743
  }, [l]), h.useEffect(() => {
746
744
  u && ($({
747
745
  dateRange: { start: me(ue(), 90), end: de() },
748
746
  accounts: f
749
- }), te({ start: W(/* @__PURE__ */ new Date()), end: z(/* @__PURE__ */ new Date()) }), C().finally(), i(!0));
747
+ }), te({ start: k(/* @__PURE__ */ new Date()), end: z(/* @__PURE__ */ new Date()) }), C().finally(), i(!0));
750
748
  }, [u]), h.useEffect(() => {
751
- n && r(I.RECURRING_TRANSACTIONS_LOAD_WIDGET, {
749
+ n && r(w.RECURRING_TRANSACTIONS_LOAD_WIDGET, {
752
750
  state: y.length > 0 ? "default" : "zeroState"
753
751
  });
754
752
  }, [n]);
755
- const M = g <= 288, j = g >= 450, K = h.useMemo(() => {
756
- const N = [
757
- { color: o.palette.success.main, percentage: `${_ / d}` }
753
+ const v = g <= 288, j = g >= 450, K = h.useMemo(() => {
754
+ const G = [
755
+ { color: o.palette.success.main, percentage: `${W / d}` }
758
756
  ];
759
- return D && N.push({
757
+ return b && G.push({
760
758
  color: o.palette.error.main,
761
- percentage: `${D / d}`
762
- }), N;
759
+ percentage: `${b / d}`
760
+ }), G;
763
761
  }, [
764
- _,
762
+ W,
765
763
  d,
766
- D,
764
+ b,
767
765
  o.palette.success.main,
768
766
  o.palette.error.main
769
- ]), P = h.useMemo(() => A(d, d === 0 ? "0,0" : "0,0.00"), [d]), re = () => {
767
+ ]), P = h.useMemo(() => L(d, d === 0 ? "0,0" : "0,0.00"), [d]), re = () => {
770
768
  r(
771
- y.length > 0 ? I.RECURRING_TRANSACTIONS_CLICK_GET_STARTED : I.RECURRING_TRANSACTIONS_CLICK_VIEW_ALL
769
+ y.length > 0 ? w.RECURRING_TRANSACTIONS_CLICK_GET_STARTED : w.RECURRING_TRANSACTIONS_CLICK_VIEW_ALL
772
770
  ), t();
773
771
  };
774
772
  if (!s || !n || !U) return /* @__PURE__ */ e(V, { height: 100 });
775
- const b = 32, oe = y.length > 0, Pe = () => oe ? M ? /* @__PURE__ */ e(
776
- St,
773
+ const R = 32, oe = y.length > 0, Pe = () => oe ? v ? /* @__PURE__ */ e(
774
+ Dt,
777
775
  {
778
- logoSize: b,
776
+ logoSize: R,
779
777
  maxLogos: 3,
780
778
  upcomingRecurrences: y.slice(0, 3)
781
779
  }
782
- ) : /* @__PURE__ */ e(Dt, { maxLogos: 3, upcomingRecurrences: y.slice(0, 3) }) : /* @__PURE__ */ e(c, { sx: { width: M ? 64 : 104 } }), Be = [
780
+ ) : /* @__PURE__ */ e(Tt, { maxLogos: 3, upcomingRecurrences: y.slice(0, 3) }) : /* @__PURE__ */ e(c, { sx: { width: v ? 64 : 104 } }), Be = [
783
781
  {
784
- amount: _,
782
+ amount: W,
785
783
  bgColor: "success.main",
786
- label: w.paid
784
+ label: _.paid
787
785
  },
788
786
  {
789
- amount: D,
787
+ amount: b,
790
788
  bgColor: "error.main",
791
- label: w.missed
789
+ label: _.missed
792
790
  },
793
791
  {
794
792
  amount: ne,
795
793
  bgColor: "border.light",
796
- label: w.upcoming
794
+ label: _.upcoming
797
795
  }
798
796
  ], De = !F?.length;
799
797
  return /* @__PURE__ */ e(
800
- ft,
798
+ ht,
801
799
  {
802
800
  className: "mx-recurring-transaction-microwidget",
803
- ctaLabel: De ? ie.get_started_cta : w.primary_cta,
801
+ ctaLabel: De ? ie.get_started_cta : _.primary_cta,
804
802
  onCTAClick: re,
805
- title: w.recurring_expenses,
806
- children: De ? /* @__PURE__ */ e(wt, {}) : /* @__PURE__ */ a(X, { children: [
803
+ title: _.recurring_expenses,
804
+ children: De ? /* @__PURE__ */ e(_t, {}) : /* @__PURE__ */ a(X, { children: [
807
805
  /* @__PURE__ */ a(
808
806
  c,
809
807
  {
@@ -817,7 +815,7 @@ const Q = {
817
815
  c,
818
816
  {
819
817
  sx: [
820
- P.length >= 10 && M ? { flexDirection: "column" } : { flexDirection: "row", gap: 2 },
818
+ P.length >= 10 && v ? { flexDirection: "column" } : { flexDirection: "row", gap: 2 },
821
819
  {
822
820
  alignItems: "baseline",
823
821
  overflow: "hidden",
@@ -830,7 +828,7 @@ const Q = {
830
828
  p,
831
829
  {
832
830
  sx: { width: "100%" },
833
- variant: P.length >= 10 && M ? "H3" : "H2",
831
+ variant: P.length >= 10 && v ? "H3" : "H2",
834
832
  children: P
835
833
  }
836
834
  ),
@@ -841,7 +839,7 @@ const Q = {
841
839
  pr: 12
842
840
  },
843
841
  variant: "XSmall",
844
- children: w.expected
842
+ children: _.expected
845
843
  }
846
844
  )
847
845
  ]
@@ -862,14 +860,14 @@ const Q = {
862
860
  gap: 16,
863
861
  mt: 4
864
862
  },
865
- children: Be.map((N, He) => /* @__PURE__ */ e(
866
- _t,
863
+ children: Be.map((G, He) => /* @__PURE__ */ e(
864
+ St,
867
865
  {
868
- amount: N.amount,
869
- bgcolor: N.bgColor,
866
+ amount: G.amount,
867
+ bgcolor: G.bgColor,
870
868
  isLargeScreen: j,
871
- isSmallScreen: M,
872
- label: N.label
869
+ isSmallScreen: v,
870
+ label: G.label
873
871
  },
874
872
  `recurrence-legend-${He}`
875
873
  ))
@@ -880,9 +878,9 @@ const Q = {
880
878
  }
881
879
  );
882
880
  }
883
- ), Ln = R(
881
+ ), Mn = T(
884
882
  ({ isOpen: t, onClose: n, selectedTab: i }) => {
885
- const { cashflow: r } = T();
883
+ const { cashflow: r } = D();
886
884
  return /* @__PURE__ */ e(
887
885
  xe,
888
886
  {
@@ -896,14 +894,14 @@ const Q = {
896
894
  }
897
895
  );
898
896
  export {
899
- Wn as AddRecurringTransactionDetails,
900
- Gn as ManageExpenses,
901
- $n as ManageIncome,
897
+ kn as AddRecurringTransactionDetails,
898
+ En as ManageExpenses,
899
+ Wn as ManageIncome,
902
900
  Ee as RecurringSettings,
903
- Ln as RecurringSettingsDrawer,
904
- Mn as RecurringTransactionsMicroWidget,
905
- vn as RecurringTransactionsMiniWidget,
906
- On as RecurringTransactionsStore,
907
- In as RecurringTransactionsWidget,
908
- Pn as SelectTransaction
901
+ Mn as RecurringSettingsDrawer,
902
+ vn as RecurringTransactionsMicroWidget,
903
+ In as RecurringTransactionsMiniWidget,
904
+ Nn as RecurringTransactionsStore,
905
+ wn as RecurringTransactionsWidget,
906
+ $n as SelectTransaction
909
907
  };