@mx-cartographer/experiences 7.3.0-alpha.sms1 → 7.3.1

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 (105) hide show
  1. package/CHANGELOG.md +75 -0
  2. package/dist/{Account-Bxw0_4FU.mjs → Account-YwUMFz93.mjs} +1 -1
  3. package/dist/{AccountDetailsContent-CAM9y39M.mjs → AccountDetailsContent-BgCST7mK.mjs} +8 -8
  4. package/dist/AccountDetailsHeader-jAFWoHj7.mjs +87 -0
  5. package/dist/{AccountFields-C9FlatNb.mjs → AccountFields-DPxMPBF0.mjs} +2 -2
  6. package/dist/{AccountListItem-JFMZROh7.mjs → AccountListItem-D6rWAreC.mjs} +8 -8
  7. package/dist/{AccountStore-BgNOyMdp.mjs → AccountStore-B5E98oM1.mjs} +100 -74
  8. package/dist/Accounts-UIlYCmHb.mjs +9 -0
  9. package/dist/{BeatApi-DhJpgCLz.mjs → BeatApi-De2IaqH2.mjs} +1 -1
  10. package/dist/{BeatStore-IBnXd4YK.mjs → BeatStore-D_NYuBSz.mjs} +1 -1
  11. package/dist/{BudgetUtil-B2ZXyw-g.mjs → BudgetUtil-CXvenbdN.mjs} +1 -1
  12. package/dist/{CategorySelectorDrawer-DUe4lH5-.mjs → CategorySelectorDrawer-Buy70Y3V.mjs} +21 -19
  13. package/dist/CategoryStore-BEdFs69_.mjs +183 -0
  14. package/dist/CategoryUtil-BR3H5i6n.mjs +78 -0
  15. package/dist/{ConnectDrawer-BQNs-hjk.mjs → ConnectDrawer-CbxHKlRv.mjs} +10 -10
  16. package/dist/{ConnectionsDrawer-ByGQE7D5.mjs → ConnectionsDrawer-C6kanU7I.mjs} +4 -4
  17. package/dist/{CurrencyInput-DUsQbkXb.mjs → CurrencyInput-lSC7oPDg.mjs} +1 -1
  18. package/dist/{DebtsStore-C9bblOgW.mjs → DebtsStore-DgIcphe_.mjs} +1 -1
  19. package/dist/{ExportCsvAction-sX8Rg4Ov.mjs → ExportCsvAction-DNSgmdyv.mjs} +3 -3
  20. package/dist/{Fetch-87LIQbEA.mjs → Fetch-DecPFeGU.mjs} +24 -22
  21. package/dist/{FinstrongStore-F2c607dj.mjs → FinstrongStore-CL7t5lBL.mjs} +1 -1
  22. package/dist/{GoalStore-D-aB35SY.mjs → GoalStore-CAlmSu4U.mjs} +112 -152
  23. package/dist/{Help-B6dIcujh.mjs → Help-hi9I9EYP.mjs} +1 -1
  24. package/dist/{LineChart-D4GI7nVh.mjs → LineChart-eK4IQImU.mjs} +2 -2
  25. package/dist/{ListItemAction-DHa3KJPs.mjs → ListItemAction-BmL5buOf.mjs} +1 -1
  26. package/dist/{ManageIncome-1s_q5W4X.mjs → ManageIncome-Cypo9qY4.mjs} +66 -65
  27. package/dist/{MerchantStore-DrFvsUyy.mjs → MerchantStore-WvZ4gnQe.mjs} +1 -1
  28. package/dist/{MicroWidgetContainer-DpeqN9n3.mjs → MicroWidgetContainer-CFdMGJKg.mjs} +1 -1
  29. package/dist/{MiniWidgetContainer-D0gfmbaF.mjs → MiniWidgetContainer-BdgBvpga.mjs} +1 -1
  30. package/dist/{NetWorthStore-DCsTZpuS.mjs → NetWorthStore-CxqIxAgN.mjs} +2 -2
  31. package/dist/{NotificationSettings-DqrkNMod.mjs → NotificationSettings-DxytNHlN.mjs} +240 -237
  32. package/dist/{NotificationStore-BxP_P2dA.mjs → NotificationStore-CDX_kqHa.mjs} +7 -15
  33. package/dist/{OriginalBalanceAction-CWuVvRq9.mjs → OriginalBalanceAction-V6FEoIDe.mjs} +3 -3
  34. package/dist/{RecurringSettings-A_rAGCTP.mjs → RecurringSettings-iIupYxJW.mjs} +4 -4
  35. package/dist/{RecurringTransactions-DK8dWldr.mjs → RecurringTransactions-ej39mgA6.mjs} +3 -3
  36. package/dist/{RecurringTransactionsStore-C4YOD7_D.mjs → RecurringTransactionsStore-BiwCzScZ.mjs} +26 -29
  37. package/dist/{SettingsStore-BcgS_Ohv.mjs → SettingsStore-krIRNwHK.mjs} +3 -3
  38. package/dist/{ToggleListItem-r0Kx56wF.mjs → ToggleListItem-ciFTiqRS.mjs} +19 -14
  39. package/dist/TransactionApi-CjBoLleL.mjs +86 -0
  40. package/dist/{TransactionDetails-oP1eSuiS.mjs → TransactionDetails-BUoNbsu-.mjs} +402 -367
  41. package/dist/TransactionStore-CtGTg0XS.mjs +677 -0
  42. package/dist/TrendsStore-5PvDT_o6.mjs +182 -0
  43. package/dist/{User-BQUxBeZV.mjs → User-Bj34_i8g.mjs} +1 -1
  44. package/dist/{ViewMoreMicroCard-SCn2wt4i.mjs → ViewMoreMicroCard-lihSDk2J.mjs} +517 -493
  45. package/dist/{WidgetContainer-BHWANqT4.mjs → WidgetContainer-BnTgAfQn.mjs} +2 -2
  46. package/dist/accounts/components/detailsdrawer/Accounts/AccountDetailsChart.d.ts +4 -1
  47. package/dist/accounts/components/detailsdrawer/Accounts/AccountDetailsHeader.d.ts +2 -1
  48. package/dist/accounts/index.es.js +241 -203
  49. package/dist/accounts/stores/AccountStore.d.ts +22 -25
  50. package/dist/accounts/utils/Accounts.d.ts +1 -2
  51. package/dist/analytics/index.es.js +2 -2
  52. package/dist/budgets/index.es.js +500 -507
  53. package/dist/budgets/store/BudgetsStore.d.ts +0 -1
  54. package/dist/cashflow/index.es.js +384 -382
  55. package/dist/categories/index.es.js +2 -2
  56. package/dist/categories/stores/CategoryStore.d.ts +1 -5
  57. package/dist/categories/util/CategoryUtil.d.ts +2 -3
  58. package/dist/common/components/charts/index.d.ts +0 -2
  59. package/dist/common/index.es.js +391 -376
  60. package/dist/common/stores/AppDataStore.d.ts +1 -3
  61. package/dist/common/stores/GlobalCopyStore.d.ts +1 -0
  62. package/dist/common/stores/GlobalStore.d.ts +10 -4
  63. package/dist/common/stores/UserStore.d.ts +2 -3
  64. package/dist/common/types/Account.d.ts +6 -9
  65. package/dist/common/types/Global.d.ts +1 -0
  66. package/dist/dashboard/index.es.js +2 -2
  67. package/dist/debts/index.es.js +506 -498
  68. package/dist/exportTransactionsToCSV-C4PkIYP6.mjs +48 -0
  69. package/dist/finstrong/index.es.js +417 -415
  70. package/dist/goals/index.es.js +559 -557
  71. package/dist/goals/stores/GoalStore.d.ts +4 -17
  72. package/dist/help/index.es.js +3 -3
  73. package/dist/{hooks-D6XlXHf4.mjs → hooks-Cy8JnjCg.mjs} +2 -2
  74. package/dist/insights/index.es.js +1 -1
  75. package/dist/investments/index.es.js +437 -435
  76. package/dist/investments/stores/HoldingStore.d.ts +0 -1
  77. package/dist/merchants/index.es.js +2 -2
  78. package/dist/microinsights/carousel/BeatList.d.ts +10 -0
  79. package/dist/microinsights/carousel/CarouselControls.d.ts +1 -1
  80. package/dist/microinsights/index.es.js +1 -1
  81. package/dist/microinsights/interfaces.d.ts +0 -1
  82. package/dist/networth/index.es.js +176 -174
  83. package/dist/notifications/index.es.js +23 -23
  84. package/dist/notifications/stores/NotificationStore.d.ts +1 -3
  85. package/dist/recurringtransactions/index.es.js +175 -173
  86. package/dist/recurringtransactions/stores/RecurringTransactionsStore.d.ts +2 -3
  87. package/dist/settings/index.es.js +285 -279
  88. package/dist/spending/index.es.js +328 -304
  89. package/dist/transactions/components/shared/TransactionDetails.d.ts +1 -0
  90. package/dist/transactions/index.es.js +63 -64
  91. package/dist/transactions/stores/TransactionStore.d.ts +77 -21
  92. package/dist/trends/index.es.js +948 -583
  93. package/dist/{useAccountDisplayName-BUAApBIb.mjs → useAccountDisplayName-D6sQsNNQ.mjs} +2 -2
  94. package/dist/{useCombineEvents-BUDIR1ba.mjs → useCombineEvents-CRwX-qWE.mjs} +1 -1
  95. package/dist/{useInsightsEnabled-DBpwEq10.mjs → useInsightsEnabled-BxytCjq5.mjs} +1 -1
  96. package/package.json +3 -3
  97. package/dist/AccountDetailsHeader-JtSX6Uf9.mjs +0 -120
  98. package/dist/Accounts-BRf_YeTf.mjs +0 -27
  99. package/dist/CategoryStore-yHI0hWmK.mjs +0 -174
  100. package/dist/CategoryUtil-pZRIYOgN.mjs +0 -80
  101. package/dist/TransactionApi-B3Tksf7L.mjs +0 -86
  102. package/dist/TransactionStore-ai3uII_r.mjs +0 -690
  103. package/dist/TrendsStore-DCYbpXPO.mjs +0 -559
  104. package/dist/exportTransactionsToCSV-7bVS7KXf.mjs +0 -47
  105. package/dist/useAriaLive-B3_pRUio.mjs +0 -35
@@ -1,43 +1,43 @@
1
1
  import { jsxs as l, jsx as e } from "react/jsx-runtime";
2
2
  import _ from "react";
3
- import { observer as b } from "mobx-react-lite";
4
- import { useVirtualizer as ke } from "@tanstack/react-virtual";
5
- import w from "@mui/material/Box";
3
+ import { observer as A } from "mobx-react-lite";
4
+ import { useVirtualizer as Re } from "@tanstack/react-virtual";
5
+ import v from "@mui/material/Box";
6
6
  import Z from "@mui/material/Divider";
7
7
  import J from "@mui/material/List";
8
- import { MerchantLogo as pe, Icon as S, Text as T, useTokens as ee, CategoryIcon as he, CategoryIconVariants as be, IconWeight as D, P as le, H1 as Ae, TextField as Te } from "@mxenabled/mxui";
8
+ import { MerchantLogo as ge, Icon as C, Text as T, useTokens as ee, CategoryIcon as he, CategoryIconVariants as be, IconWeight as D, P as le, H1 as Ae, TextField as Te } from "@mxenabled/mxui";
9
9
  import B from "@mui/material/ListItemAvatar";
10
10
  import M from "@mui/material/ListItemText";
11
- import f from "@mui/material/Stack";
12
- import { T as Pe, L as Ge, O as h, C as Me, b as Ke, i as $e } from "./User-BQUxBeZV.mjs";
13
- import { G as Be, h as v, u as A, g as L, m as xe, b as Fe, p as He } from "./hooks-D6XlXHf4.mjs";
11
+ import b from "@mui/material/Stack";
12
+ import { T as Pe, L as Ge, O as h, C as Me, b as Ke, i as $e } from "./User-Bj34_i8g.mjs";
13
+ import { G as Be, h as w, u as x, g as L, m as xe, b as Fe, p as He } from "./hooks-Cy8JnjCg.mjs";
14
14
  import { f as te } from "./NumberFormatting-Buh7u8Oi.mjs";
15
15
  import { Receipt as ze, Delete as oe, ChevronRight as Ue, Cancel as ie, Search as Xe, Edit as Ve, Flag as We } from "@mxenabled/mx-icons";
16
16
  import { fromUnixTime as W } from "date-fns/fromUnixTime";
17
17
  import { isSameDay as Ne } from "date-fns/isSameDay";
18
18
  import { h as Ye } from "./DateUtil-BcuH7ErC.mjs";
19
19
  import { L as Ie } from "./Loader-DUaFpDGv.mjs";
20
- import { A as P } from "./WidgetContainer-BHWANqT4.mjs";
20
+ import { A as P } from "./WidgetContainer-BnTgAfQn.mjs";
21
21
  import ne from "@mui/material/Paper";
22
22
  import ce from "@mui/material/Button";
23
23
  import je from "@mui/material/FormGroup";
24
24
  import Q from "@mui/material/IconButton";
25
- import De from "@mui/material/TextField";
25
+ import ve from "@mui/material/TextField";
26
26
  import qe from "@mui/material/ToggleButton";
27
- import ve from "@mui/material/styles/useTheme";
27
+ import De from "@mui/material/styles/useTheme";
28
28
  import z from "@mui/material/Avatar";
29
29
  import F from "@mui/material/ListItem";
30
- import { a as V, f as Ee, D as Oe } from "./Dialog-CWW597AF.mjs";
30
+ import { a as V, f as we, D as Ee } from "./Dialog-CWW597AF.mjs";
31
31
  import U from "@mui/material/ListItemButton";
32
32
  import X from "@mui/material/ListItemIcon";
33
- import { a as we } from "./CategorySelectorDrawer-DUe4lH5-.mjs";
33
+ import { a as Oe } from "./CategorySelectorDrawer-Buy70Y3V.mjs";
34
34
  import { b as se } from "./Localization-2MODESHW.mjs";
35
35
  import { getUnixTime as Ze } from "date-fns/getUnixTime";
36
36
  import { D as de } from "./Drawer-kEE73B87.mjs";
37
37
  import ye from "@mui/material/InputAdornment";
38
38
  import Je from "@mui/material/Checkbox";
39
- import ge from "@mui/material/Grid";
40
- import { C as Qe } from "./CurrencyInput-DUsQbkXb.mjs";
39
+ import pe from "@mui/material/Grid";
40
+ import { C as Qe } from "./CurrencyInput-lSC7oPDg.mjs";
41
41
  import et from "@mui/material/Switch";
42
42
  var q = /* @__PURE__ */ ((t) => (t[t.Category = 0] = "Category", t[t.Date = 1] = "Date", t[t.Memo = 2] = "Memo", t[t.Tags = 3] = "Tags", t))(q || {}), re = /* @__PURE__ */ ((t) => (t[t.SplitTransaction = 0] = "SplitTransaction", t[t.HideTransaction = 1] = "HideTransaction", t[t.MerchantLogo = 2] = "MerchantLogo", t))(re || {});
43
43
  const tt = [
@@ -54,14 +54,14 @@ const tt = [
54
54
  ], G = () => {
55
55
  if (!_.useContext(Be))
56
56
  throw new Error("useTransactionsUiStore() must be used within the GlobalDataContext");
57
- return v().uiStore;
57
+ return w().uiStore;
58
58
  };
59
59
  function nt() {
60
60
  return window.opener && window.opener.location ? window.opener.location.toString() : document.referrer;
61
61
  }
62
62
  function rt(t) {
63
- const r = nt().replace(/([^:]+:\/\/[^\/]+).*/, "$1"), a = window.parent || window.opener || !1;
64
- return a && a.postMessage && r ? (a.postMessage(t, r), !0) : !1;
63
+ const r = nt().replace(/([^:]+:\/\/[^\/]+).*/, "$1"), i = window.parent || window.opener || !1;
64
+ return i && i.postMessage && r ? (i.postMessage(t, r), !0) : !1;
65
65
  }
66
66
  function ot(t) {
67
67
  return rt({
@@ -71,7 +71,7 @@ function ot(t) {
71
71
  });
72
72
  }
73
73
  const it = ({ transaction: t, onClick: r }) => {
74
- const { associatedBeats: a } = v(), { expandedSplits: s } = G(), { transactions: o } = A(), { showInsights: n } = G(), c = t.transaction_type === Pe.CREDIT, d = _.useMemo(() => a.find((i) => i.associated_transaction_guid === t.guid), [a, t]);
74
+ const { associatedBeats: i } = w(), { expandedSplits: a } = G(), { transactions: o } = x(), { showInsights: n } = G(), s = t.transaction_type === Pe.CREDIT, d = _.useMemo(() => i.find((c) => c.associated_transaction_guid === t.guid), [i, t]);
75
75
  return (
76
76
  //TODO: implement common/components/ListItemRow.tsx
77
77
  /* @__PURE__ */ l(
@@ -80,8 +80,8 @@ const it = ({ transaction: t, onClick: r }) => {
80
80
  clickEventName: h.ON_TRANSACTION_LIST_ITEM_CLICK,
81
81
  onClick: r ? () => r(t.guid) : void 0,
82
82
  children: [
83
- /* @__PURE__ */ e(B, { children: t.parent_guid && s.includes(t.parent_guid) ? /* @__PURE__ */ e(_.Fragment, {}) : /* @__PURE__ */ e(
84
- pe,
83
+ /* @__PURE__ */ e(B, { children: t.parent_guid && a.includes(t.parent_guid) ? /* @__PURE__ */ e(_.Fragment, {}) : /* @__PURE__ */ e(
84
+ ge,
85
85
  {
86
86
  categoryGuid: t.top_level_category_guid || "",
87
87
  merchantGuid: t.merchant_guid || ""
@@ -91,11 +91,11 @@ const it = ({ transaction: t, onClick: r }) => {
91
91
  M,
92
92
  {
93
93
  disableTypography: !0,
94
- secondary: /* @__PURE__ */ l(f, { direction: "row", justifyContent: "space-between", children: [
95
- /* @__PURE__ */ l(f, { alignItems: "center", direction: "row", gap: 4, children: [
96
- t.is_flagged && /* @__PURE__ */ e(S, { fill: !0, name: "flag", size: 16, sx: { color: "warning.dark" } }),
97
- t.is_hidden && /* @__PURE__ */ e(S, { name: "visibility_off", size: 16 }),
98
- t.has_been_split && /* @__PURE__ */ e(S, { name: "call_split", size: 16 }),
94
+ secondary: /* @__PURE__ */ l(b, { direction: "row", justifyContent: "space-between", children: [
95
+ /* @__PURE__ */ l(b, { alignItems: "center", direction: "row", gap: 4, children: [
96
+ t.is_flagged && /* @__PURE__ */ e(C, { fill: !0, name: "flag", size: 16, sx: { color: "warning.dark" } }),
97
+ t.is_hidden && /* @__PURE__ */ e(C, { name: "visibility_off", size: 16 }),
98
+ t.has_been_split && /* @__PURE__ */ e(C, { name: "call_split", size: 16 }),
99
99
  /* @__PURE__ */ e(T, { variant: "XSmall", children: t.has_been_split ? o.split_transaction_category_label : t.category })
100
100
  ] }),
101
101
  d && n && /* @__PURE__ */ e(
@@ -103,15 +103,15 @@ const it = ({ transaction: t, onClick: r }) => {
103
103
  {
104
104
  bold: !0,
105
105
  color: "action.active",
106
- onClick: (i) => {
107
- i.stopPropagation(), i.preventDefault(), ot(d.guid);
106
+ onClick: (c) => {
107
+ c.stopPropagation(), c.preventDefault(), ot(d.guid);
108
108
  },
109
109
  variant: "XSmall",
110
110
  children: d.short_title
111
111
  }
112
112
  )
113
113
  ] }),
114
- children: /* @__PURE__ */ l(f, { direction: "row", justifyContent: "space-between", sx: { gap: 8 }, children: [
114
+ children: /* @__PURE__ */ l(b, { direction: "row", justifyContent: "space-between", sx: { gap: 8 }, children: [
115
115
  /* @__PURE__ */ l(T, { bold: !0, variant: "Body", children: [
116
116
  t.is_hidden && o.hide_trnx_cancel_hidden_note,
117
117
  t.payee || t.description || t.feed_description
@@ -120,11 +120,11 @@ const it = ({ transaction: t, onClick: r }) => {
120
120
  T,
121
121
  {
122
122
  bold: !0,
123
- color: c ? "success.main" : "text.primary",
123
+ color: s ? "success.main" : "text.primary",
124
124
  sx: { flexShrink: 0 },
125
125
  variant: "Body",
126
126
  children: [
127
- c ? "+" : "",
127
+ s ? "+" : "",
128
128
  te(t.amount, "0,0.00")
129
129
  ]
130
130
  }
@@ -136,55 +136,55 @@ const it = ({ transaction: t, onClick: r }) => {
136
136
  }
137
137
  )
138
138
  );
139
- }, st = b(it), lt = ({
139
+ }, st = A(it), lt = ({
140
140
  bgcolor: t = "background.default",
141
141
  children: r
142
- }) => /* @__PURE__ */ e(w, { display: "inline-block", sx: { bgcolor: t, py: 4, width: "100%" }, children: /* @__PURE__ */ e(T, { bold: !0, sx: { pl: 24 }, variant: "XSmall", children: r }) }), ct = ({ showIcon: t = !0, showSubtitle: r = !0 }) => {
143
- const a = ee(), { transactions: s } = A();
144
- return /* @__PURE__ */ l(f, { alignItems: "center", gap: a.Spacing.Small, height: "auto", mt: a.Spacing.Large, children: [
142
+ }) => /* @__PURE__ */ e(v, { display: "inline-block", sx: { bgcolor: t, py: 4, width: "100%" }, children: /* @__PURE__ */ e(T, { bold: !0, sx: { pl: 24 }, variant: "XSmall", children: r }) }), ct = ({ showIcon: t = !0, showSubtitle: r = !0 }) => {
143
+ const i = ee(), { transactions: a } = x();
144
+ return /* @__PURE__ */ l(b, { alignItems: "center", gap: i.Spacing.Small, height: "auto", mt: i.Spacing.Large, children: [
145
145
  t && /* @__PURE__ */ e(ze, { color: "secondary", sx: { fontSize: 32 } }),
146
- /* @__PURE__ */ e(T, { bold: !0, color: "secondary", variant: "Small", children: s.zero_state_no_transactions }),
147
- r && /* @__PURE__ */ e(T, { color: "secondary", variant: "XSmall", children: s.zero_state_there_are_no_transactions })
146
+ /* @__PURE__ */ e(T, { bold: !0, color: "secondary", variant: "Small", children: a.zero_state_no_transactions }),
147
+ r && /* @__PURE__ */ e(T, { color: "secondary", variant: "XSmall", children: a.zero_state_there_are_no_transactions })
148
148
  ] });
149
- }, dt = b(ct), Se = (t, r) => {
150
- const a = W(r[t].date), s = W(r[t - 1]?.date);
151
- return !Ne(a, s);
149
+ }, dt = A(ct), Se = (t, r) => {
150
+ const i = W(r[t].date), a = W(r[t - 1]?.date);
151
+ return !Ne(i, a);
152
152
  }, _t = (t, r) => {
153
- const a = W(r[t].date), s = W(r[t + 1]?.date);
154
- return Ne(a, s);
153
+ const i = W(r[t].date), a = W(r[t + 1]?.date);
154
+ return Ne(i, a);
155
155
  }, Ce = 65, fe = 34, ut = ({
156
156
  bgcolor: t,
157
157
  filter: r,
158
- height: a = "calc(100dvh - 36px)",
159
- loader: s = /* @__PURE__ */ e(Ie, { label: "Loading", size: 40 }),
158
+ height: i = "calc(100dvh - 36px)",
159
+ loader: a = /* @__PURE__ */ e(Ie, { label: "Loading", size: 40 }),
160
160
  onClick: o,
161
161
  showInsights: n = !1,
162
- showLoader: c = !1,
162
+ showLoader: s = !1,
163
163
  showHiddenTransactions: d = !1,
164
- width: i = "100%",
164
+ width: c = "100%",
165
165
  zeroState: u = /* @__PURE__ */ e(dt, {})
166
166
  }) => {
167
- const { isLoading: m, sortedTransactions: g } = v(), p = _.useMemo(() => {
168
- const I = r ? g.filter(r) : g;
169
- return d ? I : I.filter((k) => !k.is_hidden);
170
- }, [g, d]), { clearExpandedSplits: x, setShowInsights: y, toggleSplit: N } = G(), { onEvent: C } = L(), R = (I) => {
171
- const k = p.find((Y) => Y.guid === I);
172
- if (k?.has_been_split) {
173
- N(k.guid);
167
+ const { isLoading: m, sortedTransactions: p } = w(), g = _.useMemo(() => {
168
+ const I = r ? p.filter(r) : p;
169
+ return d ? I : I.filter((R) => !R.is_hidden);
170
+ }, [p, d]), { clearExpandedSplits: S, setShowInsights: y, toggleSplit: N } = G(), { onEvent: f } = L(), k = (I) => {
171
+ const R = g.find((Y) => Y.guid === I);
172
+ if (R?.has_been_split) {
173
+ N(R.guid);
174
174
  return;
175
175
  }
176
- C(P.ACCOUNT_DETAILS_CLICK_TRANSACTION, {
177
- account_guid: k?.account_guid,
176
+ f(P.ACCOUNT_DETAILS_CLICK_TRANSACTION, {
177
+ account_guid: R?.account_guid,
178
178
  transaction_guid: I
179
179
  }), o?.(I);
180
- }, K = _.useRef(null), $ = ke({
181
- count: p.length,
180
+ }, K = _.useRef(null), $ = Re({
181
+ count: g.length,
182
182
  getScrollElement: () => K.current,
183
- estimateSize: (I) => Ce + (Se(I, p) ? fe : 0),
183
+ estimateSize: (I) => Ce + (Se(I, g) ? fe : 0),
184
184
  overscan: 5
185
185
  });
186
- return _.useEffect(() => $.measure(), [p]), _.useEffect(() => y(n), [n]), _.useEffect(() => () => x(), []), /* @__PURE__ */ e(J, { sx: { width: i }, children: /* @__PURE__ */ e(w, { height: a, overflow: "auto", ref: K, width: i, children: /* @__PURE__ */ l(
187
- w,
186
+ return _.useEffect(() => $.measure(), [g]), _.useEffect(() => y(n), [n]), _.useEffect(() => () => S(), []), /* @__PURE__ */ e(J, { sx: { width: c }, children: /* @__PURE__ */ e(v, { height: i, overflow: "auto", ref: K, width: c, children: /* @__PURE__ */ l(
187
+ v,
188
188
  {
189
189
  height: (
190
190
  // set the height to auto when there are no transactions so the zero state isn't set to 0
@@ -193,12 +193,12 @@ const it = ({ transaction: t, onClick: r }) => {
193
193
  position: "relative",
194
194
  width: "100%",
195
195
  children: [
196
- (m || c) && s,
197
- !m && !c && $.getVirtualItems().length === 0 && u,
198
- !m && !c && $.getVirtualItems().length > 0 && $.getVirtualItems().map((I) => {
199
- const k = p[I.index], Y = Se(I.index, p), _e = _t(I.index, p), ue = Ce + (Y ? fe : 0);
196
+ (m || s) && a,
197
+ !m && !s && $.getVirtualItems().length === 0 && u,
198
+ !m && !s && $.getVirtualItems().length > 0 && $.getVirtualItems().map((I) => {
199
+ const R = g[I.index], Y = Se(I.index, g), _e = _t(I.index, g), ue = Ce + (Y ? fe : 0);
200
200
  return /* @__PURE__ */ l(
201
- w,
201
+ v,
202
202
  {
203
203
  sx: {
204
204
  height: ue,
@@ -207,38 +207,38 @@ const it = ({ transaction: t, onClick: r }) => {
207
207
  width: "100%"
208
208
  },
209
209
  children: [
210
- Y && /* @__PURE__ */ e(lt, { bgcolor: t, children: Ye(k.date) }),
211
- /* @__PURE__ */ e(st, { onClick: R, transaction: k }),
210
+ Y && /* @__PURE__ */ e(lt, { bgcolor: t, children: Ye(R.date) }),
211
+ /* @__PURE__ */ e(st, { onClick: k, transaction: R }),
212
212
  /* @__PURE__ */ e(Z, { sx: { ml: _e ? 24 : 0 } })
213
213
  ]
214
214
  },
215
- k.guid
215
+ R.guid
216
216
  );
217
217
  })
218
218
  ]
219
219
  }
220
220
  ) }) });
221
- }, Ra = b(ut), mt = ({ transaction: t }) => {
222
- const { addOrUpdateTransactionRule: r, updateTransaction: a } = v(), { categories: s } = xe(), { onEvent: o } = L(), { setShouldDisableDrawerScroll: n, updateManualTransaction: c } = G(), { transactions: d } = A(), [i, u] = _.useState(!1), [m, g] = _.useState(""), p = async (C) => {
223
- await a({ ...t, category_guid: m }), C && await r(m, t), g(""), o(P.TRANSACTION_DETAILS_CLICK_CATEGORY, {
221
+ }, Ra = A(ut), mt = ({ transaction: t }) => {
222
+ const { addOrUpdateTransactionRule: r, updateTransaction: i } = w(), { categories: a } = xe(), { onEvent: o } = L(), { setShouldDisableDrawerScroll: n, updateManualTransaction: s } = G(), { transactions: d } = x(), [c, u] = _.useState(!1), [m, p] = _.useState(""), g = async (f) => {
223
+ await i({ ...t, category_guid: m }), f && await r(m, t), p(""), o(P.TRANSACTION_DETAILS_CLICK_CATEGORY, {
224
224
  transaction_guid: t.guid
225
225
  });
226
- }, x = (C) => {
226
+ }, S = (f) => {
227
227
  if (t.is_manual && !t.guid) {
228
- const R = s.find((K) => K.guid === C);
229
- c({
228
+ const k = a.find((K) => K.guid === f);
229
+ s({
230
230
  ...t,
231
- category: R?.name,
232
- category_guid: C,
233
- top_level_category_guid: R?.parent_guid || C
231
+ category: k?.name,
232
+ category_guid: f,
233
+ top_level_category_guid: k?.parent_guid || f
234
234
  });
235
235
  } else
236
- g(C);
236
+ p(f);
237
237
  y();
238
238
  }, y = () => {
239
239
  u(!1), n(!1);
240
240
  }, N = _.useMemo(
241
- () => s.find((C) => C.guid === m),
241
+ () => a.find((f) => f.guid === m),
242
242
  [m]
243
243
  );
244
244
  return /* @__PURE__ */ l(_.Fragment, { children: [
@@ -266,17 +266,17 @@ const it = ({ transaction: t, onClick: r }) => {
266
266
  secondary: /* @__PURE__ */ e(T, { bold: !0, variant: "Body", children: t.category ?? d.actions_select_a_category })
267
267
  }
268
268
  ),
269
- /* @__PURE__ */ e(X, { children: /* @__PURE__ */ e(S, { name: "chevron_right", weight: D.Dark }) })
269
+ /* @__PURE__ */ e(X, { children: /* @__PURE__ */ e(C, { name: "chevron_right", weight: D.Dark }) })
270
270
  ]
271
271
  }
272
272
  ) }),
273
273
  /* @__PURE__ */ e(
274
- we,
274
+ Oe,
275
275
  {
276
276
  initialSelected: t.category_guid,
277
277
  onClose: y,
278
- onSelect: x,
279
- showDrawer: i,
278
+ onSelect: S,
279
+ showDrawer: c,
280
280
  title: d.actions_select_a_category
281
281
  }
282
282
  ),
@@ -290,9 +290,9 @@ const it = ({ transaction: t, onClick: r }) => {
290
290
  )
291
291
  },
292
292
  isOpen: !!m,
293
- onClose: () => g(""),
294
- onPrimaryAction: () => p(!0),
295
- onSecondaryAction: () => p(!1),
293
+ onClose: () => p(""),
294
+ onPrimaryAction: () => g(!0),
295
+ onSecondaryAction: () => g(!1),
296
296
  primaryText: d.actions_apply_to_all,
297
297
  secondaryText: d.actions_this_time_only,
298
298
  children: /* @__PURE__ */ e(le, { variant: "Paragraph", children: se(
@@ -303,34 +303,34 @@ const it = ({ transaction: t, onClick: r }) => {
303
303
  }
304
304
  )
305
305
  ] });
306
- }, gt = ({ transaction: t }) => {
307
- const r = ee(), { onEvent: a } = L(), { updateTransaction: s } = v(), { updateManualTransaction: o } = G(), { common: n, transactions: c } = A(), [d, i] = _.useState(!1), [u, m] = _.useState(t.date), g = (x) => {
308
- m(Ze(x));
309
- }, p = async () => {
306
+ }, pt = ({ transaction: t }) => {
307
+ const r = ee(), { onEvent: i } = L(), { updateTransaction: a } = w(), { updateManualTransaction: o } = G(), { common: n, transactions: s } = x(), [d, c] = _.useState(!1), [u, m] = _.useState(t.date), p = (S) => {
308
+ m(Ze(S));
309
+ }, g = async () => {
310
310
  if (t.is_manual && !t.guid) {
311
- o({ ...t, date: u }), i(!1);
311
+ o({ ...t, date: u }), c(!1);
312
312
  return;
313
313
  }
314
- await s({ ...t, date: u }), a(P.TRANSACTION_DETAILS_CLICK_DATE, { transaction_guid: t.guid }), i(!1);
314
+ await a({ ...t, date: u }), i(P.TRANSACTION_DETAILS_CLICK_DATE, { transaction_guid: t.guid }), c(!1);
315
315
  };
316
- return /* @__PURE__ */ l(w, { className: "mx-txn-date-action", children: [
316
+ return /* @__PURE__ */ l(v, { className: "mx-txn-date-action", children: [
317
317
  /* @__PURE__ */ e(F, { disableGutters: !0, disablePadding: !0, children: /* @__PURE__ */ l(
318
318
  U,
319
319
  {
320
320
  onClick: () => {
321
- a(h.ON_TRANSACTION_DATE_CLICK), i(!0);
321
+ i(h.ON_TRANSACTION_DATE_CLICK), c(!0);
322
322
  },
323
323
  children: [
324
- /* @__PURE__ */ e(B, { children: /* @__PURE__ */ e(z, { sx: { bgcolor: "border.light" }, variant: "rounded", children: /* @__PURE__ */ e(S, { name: "calendar_month", sx: { color: "text.primary" }, weight: D.Dark }) }) }),
324
+ /* @__PURE__ */ e(B, { children: /* @__PURE__ */ e(z, { sx: { bgcolor: "border.light" }, variant: "rounded", children: /* @__PURE__ */ e(C, { name: "calendar_month", sx: { color: "text.primary" }, weight: D.Dark }) }) }),
325
325
  /* @__PURE__ */ e(
326
326
  M,
327
327
  {
328
- primary: c.date_title,
328
+ primary: s.date_title,
329
329
  primaryTypographyProps: { variant: "XSmall" },
330
- secondary: /* @__PURE__ */ e(T, { bold: !0, variant: "Body", children: Ee(W(t.date), Oe.YEAR_MONTH_DAY) })
330
+ secondary: /* @__PURE__ */ e(T, { bold: !0, variant: "Body", children: we(W(t.date), Ee.YEAR_MONTH_DAY) })
331
331
  }
332
332
  ),
333
- /* @__PURE__ */ e(X, { children: /* @__PURE__ */ e(S, { name: "chevron_right", weight: D.Dark }) })
333
+ /* @__PURE__ */ e(X, { children: /* @__PURE__ */ e(C, { name: "chevron_right", weight: D.Dark }) })
334
334
  ]
335
335
  }
336
336
  ) }),
@@ -339,37 +339,37 @@ const it = ({ transaction: t, onClick: r }) => {
339
339
  {
340
340
  ariaLabelClose: n.close_aria,
341
341
  isOpen: d,
342
- onClose: () => i(!1),
343
- onPrimaryAction: p,
342
+ onClose: () => c(!1),
343
+ onPrimaryAction: g,
344
344
  primaryText: n.save_button,
345
345
  secondaryText: n.cancel_button,
346
- title: c.date_edit_title,
347
- children: /* @__PURE__ */ e(f, { alignItems: "center", mt: r.Spacing.XXLarge, children: /* @__PURE__ */ e(
346
+ title: s.date_edit_title,
347
+ children: /* @__PURE__ */ e(b, { alignItems: "center", mt: r.Spacing.XXLarge, children: /* @__PURE__ */ e(
348
348
  Me,
349
349
  {
350
350
  beginDate: W(u),
351
351
  copy: {
352
- nextAria: c.date_next_aria,
353
- prevAria: c.date_prev_aria,
352
+ nextAria: s.date_next_aria,
353
+ prevAria: s.date_prev_aria,
354
354
  today: n.date_range_picker.today
355
355
  },
356
- onDateSelected: g,
356
+ onDateSelected: p,
357
357
  selectionType: Ke.Single
358
358
  }
359
359
  ) })
360
360
  }
361
361
  )
362
362
  ] });
363
- }, pt = ({ transaction: t }) => {
364
- const { onEvent: r } = L(), { removeTransaction: a } = v(), { setShouldDisableDrawerScroll: s } = G(), { common: o, transactions: n } = A(), [c, d] = _.useState(!1), i = async () => {
365
- await a(t.guid), r(h.ON_TRANSACTION_DELETE_DELETED);
363
+ }, gt = ({ transaction: t }) => {
364
+ const { onEvent: r } = L(), { removeTransaction: i } = w(), { setShouldDisableDrawerScroll: a } = G(), { common: o, transactions: n } = x(), [s, d] = _.useState(!1), c = async () => {
365
+ await i(t.guid), r(h.ON_TRANSACTION_DELETE_DELETED);
366
366
  };
367
- return /* @__PURE__ */ l(w, { className: "mx-txn-delete", children: [
367
+ return /* @__PURE__ */ l(v, { className: "mx-txn-delete", children: [
368
368
  t && /* @__PURE__ */ e(F, { disableGutters: !0, disablePadding: !0, children: /* @__PURE__ */ l(
369
369
  U,
370
370
  {
371
371
  onClick: () => {
372
- r(h.ON_TRANSACTION_DELETE_CLICK), s(!0), d(!0);
372
+ r(h.ON_TRANSACTION_DELETE_CLICK), a(!0), d(!0);
373
373
  },
374
374
  children: [
375
375
  /* @__PURE__ */ e(B, { children: /* @__PURE__ */ e(z, { variant: "rounded", children: /* @__PURE__ */ e(oe, { color: "secondary", fontSize: "small" }) }) }),
@@ -388,11 +388,11 @@ const it = ({ transaction: t, onClick: r }) => {
388
388
  V,
389
389
  {
390
390
  copy: { title: n.manual_transaction_delete_title },
391
- isOpen: c,
391
+ isOpen: s,
392
392
  onClose: () => {
393
- s(!1), d(!1);
393
+ a(!1), d(!1);
394
394
  },
395
- onPrimaryAction: i,
395
+ onPrimaryAction: c,
396
396
  onSecondaryAction: () => r(h.ON_TRANSACTION_DELETE_CANCEL),
397
397
  primaryText: o.delete_button,
398
398
  secondaryText: o.cancel_button,
@@ -400,13 +400,13 @@ const it = ({ transaction: t, onClick: r }) => {
400
400
  }
401
401
  )
402
402
  ] });
403
- }, ht = b(pt), Tt = ({ transaction: t }) => {
404
- const { onEvent: r } = L(), { updateTransaction: a } = v(), { setShouldDisableDrawerScroll: s } = G(), { common: o, transactions: n } = A(), [c, d] = _.useState(!1), i = async () => {
405
- await a({ ...t, merchant_guid: "" }), r(P.TRANSACTION_DETAILS_CLICK_DELETE_LOGO, {
403
+ }, ht = A(gt), Tt = ({ transaction: t }) => {
404
+ const { onEvent: r } = L(), { updateTransaction: i } = w(), { setShouldDisableDrawerScroll: a } = G(), { common: o, transactions: n } = x(), [s, d] = _.useState(!1), c = async () => {
405
+ await i({ ...t, merchant_guid: "" }), r(P.TRANSACTION_DETAILS_CLICK_DELETE_LOGO, {
406
406
  transaction_guid: t.guid
407
407
  });
408
408
  };
409
- return /* @__PURE__ */ l(w, { className: "mx-txn-delete-logo", children: [
409
+ return /* @__PURE__ */ l(v, { className: "mx-txn-delete-logo", children: [
410
410
  t && /* @__PURE__ */ e(F, { disableGutters: !0, disablePadding: !0, children: /* @__PURE__ */ l(
411
411
  U,
412
412
  {
@@ -414,9 +414,9 @@ const it = ({ transaction: t, onClick: r }) => {
414
414
  r(h.ON_TRANSACTION_DELETE_LOGO_CLICK), d(!0);
415
415
  },
416
416
  children: [
417
- /* @__PURE__ */ e(B, { children: /* @__PURE__ */ e(z, { sx: { bgcolor: "border.light" }, variant: "rounded", children: /* @__PURE__ */ e(S, { name: "delete", sx: { color: "text.primary" }, weight: D.Dark }) }) }),
417
+ /* @__PURE__ */ e(B, { children: /* @__PURE__ */ e(z, { sx: { bgcolor: "border.light" }, variant: "rounded", children: /* @__PURE__ */ e(C, { name: "delete", sx: { color: "text.primary" }, weight: D.Dark }) }) }),
418
418
  /* @__PURE__ */ e(M, { primary: n.merchant_logo_title, secondary: n.merchant_logo_desc }),
419
- /* @__PURE__ */ e(X, { children: /* @__PURE__ */ e(S, { name: "chevron_right", weight: D.Dark }) })
419
+ /* @__PURE__ */ e(X, { children: /* @__PURE__ */ e(C, { name: "chevron_right", weight: D.Dark }) })
420
420
  ]
421
421
  }
422
422
  ) }),
@@ -424,11 +424,11 @@ const it = ({ transaction: t, onClick: r }) => {
424
424
  V,
425
425
  {
426
426
  copy: { title: n.merchant_logo_modal_title },
427
- isOpen: c,
427
+ isOpen: s,
428
428
  onClose: () => {
429
- s(!1), d(!1);
429
+ a(!1), d(!1);
430
430
  },
431
- onPrimaryAction: i,
431
+ onPrimaryAction: c,
432
432
  onSecondaryAction: () => r(h.ON_TRANSACTION_DELETE_LOGO_CANCEL),
433
433
  primaryText: o.delete_button,
434
434
  secondaryText: o.cancel_button,
@@ -440,22 +440,22 @@ const it = ({ transaction: t, onClick: r }) => {
440
440
  }
441
441
  )
442
442
  ] });
443
- }, yt = b(Tt), St = ({ transaction: t }) => {
444
- const { onEvent: r } = L(), { updateTransaction: a } = v(), { setShouldDisableDrawerScroll: s } = G(), { common: o, transactions: n } = A(), [c, d] = _.useState(!1), i = t.is_hidden, u = async () => {
445
- await a({ ...t, is_hidden: !t.is_hidden }), r(
446
- i ? h.ON_TRANSACTION_UNHIDDEN : h.ON_TRANSACTION_HIDDEN
443
+ }, yt = A(Tt), St = ({ transaction: t }) => {
444
+ const { onEvent: r } = L(), { updateTransaction: i } = w(), { setShouldDisableDrawerScroll: a } = G(), { common: o, transactions: n } = x(), [s, d] = _.useState(!1), c = t.is_hidden, u = async () => {
445
+ await i({ ...t, is_hidden: !t.is_hidden }), r(
446
+ c ? h.ON_TRANSACTION_UNHIDDEN : h.ON_TRANSACTION_HIDDEN
447
447
  );
448
448
  };
449
- return /* @__PURE__ */ l(w, { className: "mx-txn-hide-transaction", children: [
449
+ return /* @__PURE__ */ l(v, { className: "mx-txn-hide-transaction", children: [
450
450
  t && /* @__PURE__ */ e(F, { disableGutters: !0, disablePadding: !0, children: /* @__PURE__ */ l(
451
451
  U,
452
452
  {
453
- "aria-checked": i,
453
+ "aria-checked": c,
454
454
  onClick: () => {
455
455
  r(
456
- i ? h.ON_TRANSACTION_UNHIDE_CLICK : h.ON_TRANSACTION_HIDE_CLICK
456
+ c ? h.ON_TRANSACTION_UNHIDE_CLICK : h.ON_TRANSACTION_HIDE_CLICK
457
457
  ), r(
458
- i ? "transaction_details_click_unhide_transaction" : "transaction_details_click_hide_transaction",
458
+ c ? "transaction_details_click_unhide_transaction" : "transaction_details_click_hide_transaction",
459
459
  {
460
460
  transaction_guid: t.guid
461
461
  }
@@ -463,25 +463,25 @@ const it = ({ transaction: t, onClick: r }) => {
463
463
  },
464
464
  role: "switch",
465
465
  children: [
466
- /* @__PURE__ */ e(B, { children: /* @__PURE__ */ e(z, { sx: { bgcolor: "border.light" }, variant: "rounded", children: i ? /* @__PURE__ */ e(
467
- S,
466
+ /* @__PURE__ */ e(B, { children: /* @__PURE__ */ e(z, { sx: { bgcolor: "border.light" }, variant: "rounded", children: c ? /* @__PURE__ */ e(
467
+ C,
468
468
  {
469
469
  name: "visibilityOff",
470
470
  sx: { color: "text.primary" },
471
471
  weight: D.Dark
472
472
  }
473
- ) : /* @__PURE__ */ e(S, { name: "visibility", sx: { color: "text.primary" }, weight: D.Dark }) }) }),
473
+ ) : /* @__PURE__ */ e(C, { name: "visibility", sx: { color: "text.primary" }, weight: D.Dark }) }) }),
474
474
  /* @__PURE__ */ e(
475
475
  M,
476
476
  {
477
- primary: i ? n.hide_trnx_subtitle_unhide_trnx : n.hide_trnx_subtitle_hide_trnx,
478
- secondary: i ? n.hide_trnx_desc_unhiding : n.hide_trnx_desc_hiding
477
+ primary: c ? n.hide_trnx_subtitle_unhide_trnx : n.hide_trnx_subtitle_hide_trnx,
478
+ secondary: c ? n.hide_trnx_desc_unhiding : n.hide_trnx_desc_hiding
479
479
  }
480
480
  ),
481
481
  /* @__PURE__ */ e(X, { children: /* @__PURE__ */ e(
482
482
  et,
483
483
  {
484
- checked: i,
484
+ checked: c,
485
485
  id: "hide-transaction",
486
486
  name: "hide-transaction",
487
487
  tabIndex: -1
@@ -494,52 +494,52 @@ const it = ({ transaction: t, onClick: r }) => {
494
494
  V,
495
495
  {
496
496
  copy: {
497
- title: i ? n.hide_trnx_subtitle_unhide_trnx : n.hide_trnx_subtitle_hide_trnx
497
+ title: c ? n.hide_trnx_subtitle_unhide_trnx : n.hide_trnx_subtitle_hide_trnx
498
498
  },
499
- isOpen: c,
499
+ isOpen: s,
500
500
  onClose: () => {
501
- s(!1), d(!1);
501
+ a(!1), d(!1);
502
502
  },
503
503
  onPrimaryAction: u,
504
504
  onSecondaryAction: () => r(
505
- i ? h.ON_TRANSACTION_UNHIDE_CANCEL_CLICK : h.ON_TRANSACTION_HIDE_CANCEL_CLICK
505
+ c ? h.ON_TRANSACTION_UNHIDE_CANCEL_CLICK : h.ON_TRANSACTION_HIDE_CANCEL_CLICK
506
506
  ),
507
- primaryText: i ? o.unhide_button : o.hide_button,
507
+ primaryText: c ? o.unhide_button : o.hide_button,
508
508
  secondaryText: o.cancel_button,
509
- children: /* @__PURE__ */ e(T, { truncate: !1, variant: "Paragraph", children: i ? n.hide_trnx_desc_unhiding : n.hide_trnx_desc_hiding })
509
+ children: /* @__PURE__ */ e(T, { truncate: !1, variant: "Paragraph", children: c ? n.hide_trnx_desc_unhiding : n.hide_trnx_desc_hiding })
510
510
  }
511
511
  )
512
512
  ] });
513
- }, Ct = b(St), Le = ({ transaction: t }) => {
514
- const { amount: r, description: a, isIncome: s, merchant_guid: o, payee: n, top_level_category_guid: c } = t;
515
- return /* @__PURE__ */ l(f, { className: "mx-txn-amount-header", direction: "row", gap: 12, px: 16, py: 24, children: [
513
+ }, Ct = A(St), Le = ({ transaction: t }) => {
514
+ const { amount: r, description: i, isIncome: a, merchant_guid: o, payee: n, top_level_category_guid: s } = t;
515
+ return /* @__PURE__ */ l(b, { className: "mx-txn-amount-header", direction: "row", gap: 12, px: 16, py: 24, children: [
516
516
  /* @__PURE__ */ e(
517
- pe,
517
+ ge,
518
518
  {
519
- categoryGuid: c || "",
519
+ categoryGuid: s || "",
520
520
  merchantGuid: o || "",
521
521
  size: 64
522
522
  }
523
523
  ),
524
- /* @__PURE__ */ l(f, { overflow: "hidden'", children: [
525
- /* @__PURE__ */ e(T, { bold: !0, mb: 4, truncate: !0, variant: "Body", children: a || n }),
526
- /* @__PURE__ */ l(Ae, { color: s ? "success.main" : "text.primary", truncate: !0, children: [
527
- s ? "+" : "",
524
+ /* @__PURE__ */ l(b, { overflow: "hidden'", children: [
525
+ /* @__PURE__ */ e(T, { bold: !0, mb: 4, truncate: !0, variant: "Body", children: i || n }),
526
+ /* @__PURE__ */ l(Ae, { color: a ? "success.main" : "text.primary", truncate: !0, children: [
527
+ a ? "+" : "",
528
528
  te(r, "0,0.00")
529
529
  ] })
530
530
  ] })
531
531
  ] });
532
532
  }, ft = ({ transaction: t }) => {
533
- const { onEvent: r } = L(), { updateTransaction: a } = v(), { updateManualTransaction: s } = G(), { common: o, transactions: n } = A(), [c, d] = _.useState(!1), [i, u] = _.useState("");
533
+ const { onEvent: r } = L(), { updateTransaction: i } = w(), { updateManualTransaction: a } = G(), { common: o, transactions: n } = x(), [s, d] = _.useState(!1), [c, u] = _.useState("");
534
534
  _.useEffect(() => {
535
- c && u(t.memo ? t.memo : "");
536
- }, [c]);
535
+ s && u(t.memo ? t.memo : "");
536
+ }, [s]);
537
537
  const m = async () => {
538
538
  if (t.is_manual && !t.guid) {
539
- s({ ...t, memo: i }), d(!1);
539
+ a({ ...t, memo: c }), d(!1);
540
540
  return;
541
541
  }
542
- await a({ ...t, memo: i }), r(P.TRANSACTION_DETAILS_CLICK_MEMO, { transaction_guid: t.guid }), d(!1);
542
+ await i({ ...t, memo: c }), r(P.TRANSACTION_DETAILS_CLICK_MEMO, { transaction_guid: t.guid }), d(!1);
543
543
  };
544
544
  return /* @__PURE__ */ l("div", { className: "mx-txn-memo-action", children: [
545
545
  /* @__PURE__ */ e(F, { disableGutters: !0, disablePadding: !0, children: /* @__PURE__ */ l(
@@ -549,7 +549,7 @@ const it = ({ transaction: t, onClick: r }) => {
549
549
  r(h.ON_TRANSACTION_MEMO_CLICK), d(!0);
550
550
  },
551
551
  children: [
552
- /* @__PURE__ */ e(B, { children: /* @__PURE__ */ e(z, { sx: { bgcolor: "border.light" }, variant: "rounded", children: /* @__PURE__ */ e(S, { name: "article", sx: { color: "text.primary" }, weight: D.Dark }) }) }),
552
+ /* @__PURE__ */ e(B, { children: /* @__PURE__ */ e(z, { sx: { bgcolor: "border.light" }, variant: "rounded", children: /* @__PURE__ */ e(C, { name: "article", sx: { color: "text.primary" }, weight: D.Dark }) }) }),
553
553
  /* @__PURE__ */ e(
554
554
  M,
555
555
  {
@@ -566,7 +566,7 @@ const it = ({ transaction: t, onClick: r }) => {
566
566
  )
567
567
  }
568
568
  ),
569
- /* @__PURE__ */ e(X, { children: /* @__PURE__ */ e(S, { name: "chevron_right", weight: D.Dark }) })
569
+ /* @__PURE__ */ e(X, { children: /* @__PURE__ */ e(C, { name: "chevron_right", weight: D.Dark }) })
570
570
  ]
571
571
  }
572
572
  ) }),
@@ -574,63 +574,91 @@ const it = ({ transaction: t, onClick: r }) => {
574
574
  de,
575
575
  {
576
576
  ariaLabelClose: o.close_aria,
577
- isOpen: c,
577
+ isOpen: s,
578
578
  onClose: () => d(!1),
579
579
  onPrimaryAction: m,
580
580
  title: n.memo_title,
581
581
  children: [
582
582
  /* @__PURE__ */ e(Le, { transaction: t }),
583
583
  /* @__PURE__ */ e(
584
- De,
584
+ ve,
585
585
  {
586
586
  "aria-label": n.memo_desc_aria,
587
587
  focused: !0,
588
588
  fullWidth: !0,
589
589
  multiline: !0,
590
590
  name: "memo",
591
- onChange: (g) => u(g.target.value),
591
+ onChange: (p) => u(p.target.value),
592
592
  placeholder: n.memo_desc,
593
593
  rows: 4,
594
594
  sx: { px: 16 },
595
- value: i
595
+ value: c
596
596
  }
597
597
  )
598
598
  ]
599
599
  }
600
600
  )
601
601
  ] });
602
- }, bt = b(ft), At = ({
602
+ }, bt = A(ft), At = (t = "polite") => {
603
+ const [r, i] = _.useState(""), [a, o] = _.useState(t), n = _.useCallback((d, c) => {
604
+ c && o(c), i(d);
605
+ }, []), s = _.useMemo(
606
+ () => /* @__PURE__ */ e(
607
+ v,
608
+ {
609
+ "aria-atomic": "true",
610
+ "aria-live": a,
611
+ role: a === "assertive" ? "alert" : "status",
612
+ sx: {
613
+ position: "absolute",
614
+ width: "1px",
615
+ height: "1px",
616
+ padding: 0,
617
+ margin: "-1px",
618
+ overflow: "hidden",
619
+ clip: "rect(0 0 0 0)",
620
+ clipPath: "inset(50%)",
621
+ whiteSpace: "nowrap",
622
+ border: 0
623
+ },
624
+ children: r
625
+ }
626
+ ),
627
+ [r, a]
628
+ );
629
+ return { announce: n, ariaLive: s };
630
+ }, xt = ({
603
631
  index: t,
604
632
  onDeleteRow: r,
605
- onCategoryChanged: a,
606
- onUpdateAmount: s,
633
+ onCategoryChanged: i,
634
+ onUpdateAmount: a,
607
635
  split: o
608
636
  }) => {
609
- const n = ee(), { onEvent: c } = L(), { transactions: d } = A(), [i, u] = _.useState(`${o.amount}`), [m, g] = _.useState(!1), p = t === 0, x = (y) => {
610
- isNaN(Number(y)) || (u(y), s(t, Number(y)));
637
+ const n = ee(), { onEvent: s } = L(), { transactions: d } = x(), [c, u] = _.useState(`${o.amount}`), [m, p] = _.useState(!1), g = t === 0, S = (y) => {
638
+ isNaN(Number(y)) || (u(y), a(t, Number(y)));
611
639
  };
612
640
  return /* @__PURE__ */ l(
613
- w,
641
+ v,
614
642
  {
615
643
  bgcolor: "background.paper",
616
644
  className: "mx-txn-split-manager-row",
617
645
  pb: n.Spacing.Tiny,
618
646
  px: n.Spacing.XSmall,
619
647
  children: [
620
- /* @__PURE__ */ l(ge, { alignItems: p ? "center" : "start", container: !0, children: [
621
- /* @__PURE__ */ e(ge, { item: !0, xs: 7, children: /* @__PURE__ */ l(f, { alignItems: "start", children: [
648
+ /* @__PURE__ */ l(pe, { alignItems: g ? "center" : "start", container: !0, children: [
649
+ /* @__PURE__ */ e(pe, { item: !0, xs: 7, children: /* @__PURE__ */ l(b, { alignItems: "start", children: [
622
650
  /* @__PURE__ */ e(
623
651
  ce,
624
652
  {
625
653
  endIcon: /* @__PURE__ */ e(Ue, {}),
626
- onClick: () => g(!0),
654
+ onClick: () => p(!0),
627
655
  startIcon: /* @__PURE__ */ e(he, { categoryGuid: o.top_level_category_guid }),
628
656
  sx: { px: n.Spacing.Small, py: n.Spacing.XSmall },
629
657
  children: o.category
630
658
  }
631
659
  ),
632
- /* @__PURE__ */ e(w, { children: !o.category_guid && /* @__PURE__ */ l(
633
- f,
660
+ /* @__PURE__ */ e(v, { children: !o.category_guid && /* @__PURE__ */ l(
661
+ b,
634
662
  {
635
663
  color: "error.main",
636
664
  direction: "row",
@@ -643,15 +671,15 @@ const it = ({ transaction: t, onClick: r }) => {
643
671
  }
644
672
  ) })
645
673
  ] }) }),
646
- /* @__PURE__ */ e(ge, { item: !0, xs: 5, children: p ? /* @__PURE__ */ e("div", { className: "mx-txn-split-manager-row-top-container", children: /* @__PURE__ */ e(T, { children: te(o.amount, "0,0.00") }) }) : /* @__PURE__ */ l(f, { alignItems: "start", children: [
647
- /* @__PURE__ */ l(f, { alignItems: "start", direction: "row", gap: n.Spacing.XSmall, children: [
674
+ /* @__PURE__ */ e(pe, { item: !0, xs: 5, children: g ? /* @__PURE__ */ e("div", { className: "mx-txn-split-manager-row-top-container", children: /* @__PURE__ */ e(T, { children: te(o.amount, "0,0.00") }) }) : /* @__PURE__ */ l(b, { alignItems: "start", children: [
675
+ /* @__PURE__ */ l(b, { alignItems: "start", direction: "row", gap: n.Spacing.XSmall, children: [
648
676
  /* @__PURE__ */ e(
649
677
  Qe,
650
678
  {
651
- amount: i,
679
+ amount: c,
652
680
  ariaLabel: d.split_transaction_edit_split_amount,
653
681
  name: "split-amount-input",
654
- setAmount: x,
682
+ setAmount: S,
655
683
  sx: {
656
684
  ".MuiOutlinedInput-input": { p: n.Spacing.Small }
657
685
  },
@@ -664,15 +692,15 @@ const it = ({ transaction: t, onClick: r }) => {
664
692
  "aria-label": d.split_transaction_delete_split_btn,
665
693
  color: "secondary",
666
694
  onClick: () => {
667
- c(h.ON_TRANSACTION_SPLIT_DELETE_CLICK), r(t);
695
+ s(h.ON_TRANSACTION_SPLIT_DELETE_CLICK), r(t);
668
696
  },
669
697
  sx: { w: 44, h: 44 },
670
698
  children: /* @__PURE__ */ e(oe, {})
671
699
  }
672
700
  )
673
701
  ] }),
674
- !i && /* @__PURE__ */ l(
675
- f,
702
+ !c && /* @__PURE__ */ l(
703
+ b,
676
704
  {
677
705
  color: "error.main",
678
706
  direction: "row",
@@ -687,12 +715,12 @@ const it = ({ transaction: t, onClick: r }) => {
687
715
  ] }) })
688
716
  ] }),
689
717
  /* @__PURE__ */ e(
690
- we,
718
+ Oe,
691
719
  {
692
720
  initialSelected: o.category_guid,
693
- onClose: () => g(!1),
721
+ onClose: () => p(!1),
694
722
  onSelect: (y) => {
695
- a(t, y), g(!1);
723
+ i(t, y), p(!1);
696
724
  },
697
725
  showDrawer: m,
698
726
  title: d.actions_select_a_category
@@ -701,60 +729,65 @@ const it = ({ transaction: t, onClick: r }) => {
701
729
  ]
702
730
  }
703
731
  );
704
- }, xt = b(At), Nt = ({
732
+ }, Nt = A(xt), It = ({
705
733
  onAddSplit: t,
706
734
  onCategoryChanged: r,
707
- onDeleteSplit: a,
708
- onUpdateAmount: s,
735
+ onDeleteSplit: i,
736
+ onUpdateAmount: a,
709
737
  splits: o,
710
738
  transaction: n
711
739
  }) => {
712
- const c = ee(), { transactions: d } = A(), { onEvent: i } = L(), [u, m] = _.useState("");
740
+ const s = ee(), { transactions: d } = x(), { onEvent: c } = L(), [u, m] = _.useState(""), { announce: p, ariaLive: g } = At();
713
741
  return _.useEffect(() => {
714
- m(o.length <= 1 ? d.split_transaction_errors_min_splits : ""), m(
715
- o[0].amount < 0 ? se(
742
+ if (o.length <= 1)
743
+ m(d.split_transaction_errors_min_splits), p(d.split_transaction_errors_min_splits);
744
+ else if (o[0].amount < 0) {
745
+ const S = se(
716
746
  d.split_transaction_errors_totals_must_equal_amount,
717
747
  te(n.amount, "0,0.00")
718
- ) : ""
719
- );
720
- }, [o]), /* @__PURE__ */ l(w, { className: "mx-txn-split-manager", children: [
721
- o.map((g, p) => /* @__PURE__ */ e(
722
- xt,
748
+ );
749
+ m(S), p(S);
750
+ } else
751
+ m(""), p("");
752
+ }, [o]), /* @__PURE__ */ l(v, { className: "mx-txn-split-manager", children: [
753
+ o.map((S, y) => /* @__PURE__ */ e(
754
+ Nt,
723
755
  {
724
- index: p,
756
+ index: y,
725
757
  onCategoryChanged: r,
726
- onDeleteRow: a,
727
- onUpdateAmount: s,
728
- split: g
758
+ onDeleteRow: i,
759
+ onUpdateAmount: a,
760
+ split: S
729
761
  },
730
- p
762
+ y
731
763
  )),
732
764
  u && /* @__PURE__ */ l(
733
- f,
765
+ b,
734
766
  {
735
767
  color: "error.main",
736
768
  direction: "row",
737
- gap: c.Spacing.XSmall,
738
- p: c.Spacing.Medium,
769
+ gap: s.Spacing.XSmall,
770
+ p: s.Spacing.Medium,
739
771
  children: [
740
- /* @__PURE__ */ e(ie, { sx: { fontSize: c.FontSize.Body } }),
741
- /* @__PURE__ */ e(T, { variant: "Small", children: u })
772
+ /* @__PURE__ */ e(ie, { sx: { fontSize: s.FontSize.Body } }),
773
+ /* @__PURE__ */ e(T, { variant: "Small", children: u }),
774
+ g
742
775
  ]
743
776
  }
744
777
  ),
745
- /* @__PURE__ */ e(w, { p: c.Spacing.Medium, children: /* @__PURE__ */ e(
778
+ /* @__PURE__ */ e(v, { p: s.Spacing.Medium, children: /* @__PURE__ */ e(
746
779
  ce,
747
780
  {
748
781
  "aria-label": d.split_transaction_add_split_btn,
749
782
  onClick: () => {
750
- i(h.ON_TRANSACTION_SPLIT_ADD_CLICK), t();
783
+ c(h.ON_TRANSACTION_SPLIT_ADD_CLICK), t();
751
784
  },
752
785
  children: d.split_transaction_add_split_btn
753
786
  }
754
787
  ) })
755
788
  ] });
756
- }, It = b(Nt), Dt = ({ transaction: t }) => {
757
- const { onEvent: r } = L(), { splitTransaction: a, unSplitTransaction: s } = v(), { common: o, transactions: n } = A(), { setShouldDisableDrawerScroll: c } = G(), { categories: d } = xe(), i = {
789
+ }, vt = A(It), Dt = ({ transaction: t }) => {
790
+ const { onEvent: r } = L(), { splitTransaction: i, unSplitTransaction: a } = w(), { common: o, transactions: n } = x(), { setShouldDisableDrawerScroll: s } = G(), { categories: d } = xe(), c = {
758
791
  ...t,
759
792
  amount: t.amount - 1,
760
793
  guid: "",
@@ -769,10 +802,10 @@ const it = ({ transaction: t, onClick: r }) => {
769
802
  has_been_split: !1,
770
803
  parent_guid: t.guid,
771
804
  top_level_category_guid: void 0
772
- }, [m, g] = _.useState(!1), [p, x] = _.useState(!1), [y, N] = _.useState([]), C = () => {
805
+ }, [m, p] = _.useState(!1), [g, S] = _.useState(!1), [y, N] = _.useState([]), f = () => {
773
806
  const E = [...y];
774
807
  E.push({ ...u }), E[0].amount -= 1, N(E);
775
- }, R = (E) => {
808
+ }, k = (E) => {
776
809
  if (E > 0) {
777
810
  const H = y[E], O = [...y];
778
811
  O.splice(E, 1), O[0].amount += H.amount, N(O);
@@ -780,7 +813,7 @@ const it = ({ transaction: t, onClick: r }) => {
780
813
  }, K = (E, H) => {
781
814
  const O = [...y];
782
815
  O[E].amount = H, O[0].amount = t.amount - O.reduce(
783
- (j, me, Re) => j + (Re !== 0 ? me.amount : 0),
816
+ (j, me, ke) => j + (ke !== 0 ? me.amount : 0),
784
817
  0
785
818
  ), N(O);
786
819
  }, $ = (E, H) => {
@@ -793,29 +826,29 @@ const it = ({ transaction: t, onClick: r }) => {
793
826
  }, N(O));
794
827
  }, I = () => {
795
828
  if (t.parent_guid || t.has_been_split) {
796
- x(!0);
829
+ S(!0);
797
830
  return;
798
831
  }
799
- N([{ ...i }, { ...u }]), r(P.TRANSACTION_DETAILS_CLICK_SPLIT, {
832
+ N([{ ...c }, { ...u }]), r(P.TRANSACTION_DETAILS_CLICK_SPLIT, {
800
833
  transaction_guid: t.guid
801
- }), g(!0);
802
- }, k = async () => {
803
- r(h.ON_TRANSACTION_SPLIT_SAVE_CLICK), await a({ ...t, has_been_split: !0 }, y), g(!1);
834
+ }), p(!0);
835
+ }, R = async () => {
836
+ r(h.ON_TRANSACTION_SPLIT_SAVE_CLICK), await i({ ...t, has_been_split: !0 }, y), p(!1);
804
837
  }, Y = async () => {
805
- r(h.ON_TRANSACTION_SPLIT_CANCEL_CLICK), N([{ ...i }, { ...u }]), g(!1);
838
+ r(h.ON_TRANSACTION_SPLIT_CANCEL_CLICK), N([{ ...c }, { ...u }]), p(!1);
806
839
  }, _e = async () => {
807
840
  r(P.TRANSACTION_DETAILS_CLICK_UNSPLIT, {
808
841
  transaction_guid: t.guid
809
842
  });
810
843
  const E = t.parent_guid ?? t.guid;
811
- await s(E);
844
+ await a(E);
812
845
  }, ue = _.useMemo(() => {
813
846
  const E = y.some((O) => !O.category_guid), H = y.some((O) => O.amount <= 0);
814
847
  return E || H;
815
848
  }, [y]);
816
849
  return /* @__PURE__ */ l(_.Fragment, { children: [
817
850
  t && /* @__PURE__ */ e(F, { disableGutters: !0, disablePadding: !0, children: /* @__PURE__ */ l(U, { onClick: I, children: [
818
- /* @__PURE__ */ e(B, { children: /* @__PURE__ */ e(z, { sx: { bgcolor: "border.light" }, variant: "rounded", children: /* @__PURE__ */ e(S, { name: "call_split", sx: { color: "text.primary" }, weight: D.Dark }) }) }),
851
+ /* @__PURE__ */ e(B, { children: /* @__PURE__ */ e(z, { sx: { bgcolor: "border.light" }, variant: "rounded", children: /* @__PURE__ */ e(C, { name: "call_split", sx: { color: "text.primary" }, weight: D.Dark }) }) }),
819
852
  /* @__PURE__ */ e(
820
853
  M,
821
854
  {
@@ -823,7 +856,7 @@ const it = ({ transaction: t, onClick: r }) => {
823
856
  secondary: t.has_been_split || t.parent_guid ? n.split_transaction_unsplit_subtitle : n.split_transaction_desc
824
857
  }
825
858
  ),
826
- /* @__PURE__ */ e(X, { children: t.has_been_split || t.parent_guid ? /* @__PURE__ */ e(S, { name: "delete", weight: D.Dark }) : /* @__PURE__ */ e(S, { name: "chevron_right", weight: D.Dark }) })
859
+ /* @__PURE__ */ e(X, { children: t.has_been_split || t.parent_guid ? /* @__PURE__ */ e(C, { name: "delete", weight: D.Dark }) : /* @__PURE__ */ e(C, { name: "chevron_right", weight: D.Dark }) })
827
860
  ] }) }),
828
861
  /* @__PURE__ */ l(
829
862
  de,
@@ -832,18 +865,18 @@ const it = ({ transaction: t, onClick: r }) => {
832
865
  isOpen: m,
833
866
  isPrimaryDisabled: ue,
834
867
  onClose: Y,
835
- onPrimaryAction: k,
868
+ onPrimaryAction: R,
836
869
  primaryText: o.save_button,
837
870
  secondaryText: o.cancel_button,
838
871
  title: n.split_transaction_title,
839
872
  children: [
840
873
  /* @__PURE__ */ e(Le, { transaction: t }),
841
874
  /* @__PURE__ */ e(
842
- It,
875
+ vt,
843
876
  {
844
- onAddSplit: C,
877
+ onAddSplit: f,
845
878
  onCategoryChanged: $,
846
- onDeleteSplit: R,
879
+ onDeleteSplit: k,
847
880
  onUpdateAmount: K,
848
881
  splits: y,
849
882
  transaction: t
@@ -856,9 +889,9 @@ const it = ({ transaction: t, onClick: r }) => {
856
889
  V,
857
890
  {
858
891
  copy: { title: n.split_transaction_unsplit_title },
859
- isOpen: p,
892
+ isOpen: g,
860
893
  onClose: () => {
861
- c(!1), x(!1);
894
+ s(!1), S(!1);
862
895
  },
863
896
  onPrimaryAction: _e,
864
897
  onSecondaryAction: () => {
@@ -873,23 +906,23 @@ const it = ({ transaction: t, onClick: r }) => {
873
906
  }
874
907
  )
875
908
  ] });
876
- }, vt = b(Dt), Et = () => {
877
- const t = ve(), { onEvent: r } = L(), { addTag: a } = v(), { transactions: s } = A(), [o, n] = _.useState(!1), [c, d] = _.useState(""), [i, u] = _.useState(""), m = _.useRef(null);
909
+ }, wt = A(Dt), Et = () => {
910
+ const t = De(), { onEvent: r } = L(), { addTag: i } = w(), { transactions: a } = x(), [o, n] = _.useState(!1), [s, d] = _.useState(""), [c, u] = _.useState(""), m = _.useRef(null);
878
911
  _.useEffect(() => {
879
912
  o && m?.current?.focus();
880
913
  }, [o]);
881
- const g = () => {
914
+ const p = () => {
882
915
  r(
883
916
  o ? h.ON_TRANSACTION_TAGS_TAG_ADD_CANCEL_CLICK : h.ON_TRANSACTION_TAGS_TAG_ADD_CLICK
884
917
  ), o || d(""), n(!o);
885
- }, p = async () => {
886
- r(h.ON_TRANSACTION_TAGS_TAG_ADDED), await a(c), n(!1);
918
+ }, g = async () => {
919
+ r(h.ON_TRANSACTION_TAGS_TAG_ADDED), await i(s), n(!1);
887
920
  };
888
921
  return _.useEffect(() => {
889
- u(c.length > 40 ? s.tags_error_name_must_be_40_chars : "");
890
- }, [c]), /* @__PURE__ */ l(w, { className: "mx-txn-tag-manager-header", children: [
922
+ u(s.length > 40 ? a.tags_error_name_must_be_40_chars : "");
923
+ }, [s]), /* @__PURE__ */ l(v, { className: "mx-txn-tag-manager-header", children: [
891
924
  /* @__PURE__ */ l(
892
- f,
925
+ b,
893
926
  {
894
927
  alignItems: "center",
895
928
  bgcolor: t.palette.background.default,
@@ -898,14 +931,14 @@ const it = ({ transaction: t, onClick: r }) => {
898
931
  px: 24,
899
932
  py: 16,
900
933
  children: [
901
- /* @__PURE__ */ e(T, { bold: !0, children: s.tags_your_tags }),
934
+ /* @__PURE__ */ e(T, { bold: !0, children: a.tags_your_tags }),
902
935
  /* @__PURE__ */ e(
903
936
  ce,
904
937
  {
905
938
  "aria-expanded": o,
906
- "aria-label": s.tags_add_tag_btn_aria,
907
- onClick: g,
908
- children: s.tags_add_tag_btn
939
+ "aria-label": a.tags_add_tag_btn_aria,
940
+ onClick: p,
941
+ children: a.tags_add_tag_btn
909
942
  }
910
943
  )
911
944
  ]
@@ -914,65 +947,65 @@ const it = ({ transaction: t, onClick: r }) => {
914
947
  /* @__PURE__ */ l(
915
948
  V,
916
949
  {
917
- copy: { title: s.tags_add_tag_btn },
950
+ copy: { title: a.tags_add_tag_btn },
918
951
  isOpen: o,
919
952
  onClose: () => n(!1),
920
- onPrimaryAction: p,
953
+ onPrimaryAction: g,
921
954
  onSecondaryAction: () => n(!1),
922
955
  children: [
923
956
  /* @__PURE__ */ e(
924
957
  Te,
925
958
  {
926
- "aria-label": s.tags_placeholder,
959
+ "aria-label": a.tags_placeholder,
927
960
  name: "add-tag",
928
- onChange: (x) => d(x.target.value),
929
- placeholder: s.tags_placeholder,
961
+ onChange: (S) => d(S.target.value),
962
+ placeholder: a.tags_placeholder,
930
963
  sx: { width: "100%" },
931
- value: c
964
+ value: s
932
965
  }
933
966
  ),
934
- /* @__PURE__ */ e(le, { id: "add-tag-error", sx: { color: "error.main" }, variant: "ParagraphSmall", children: i })
967
+ /* @__PURE__ */ e(le, { id: "add-tag-error", sx: { color: "error.main" }, variant: "ParagraphSmall", children: c })
935
968
  ]
936
969
  }
937
970
  )
938
971
  ] });
939
- }, Ot = b(Et), wt = ({ onSearchValueChanged: t, searchValue: r }) => {
940
- const { common: a, transactions: s } = A(), o = ee(), n = /* @__PURE__ */ e(
972
+ }, Ot = A(Et), Lt = ({ onSearchValueChanged: t, searchValue: r }) => {
973
+ const { common: i, transactions: a } = x(), o = ee(), n = /* @__PURE__ */ e(
941
974
  Q,
942
975
  {
943
- "aria-label": s.tags_cancel_search || "Search",
976
+ "aria-label": a.tags_cancel_search || "Search",
944
977
  onClick: () => t(""),
945
978
  children: /* @__PURE__ */ e(ie, {})
946
979
  }
947
980
  );
948
- return /* @__PURE__ */ e(w, { className: "mx-txn-tag-manager-search", px: o.Spacing.Large, py: o.Spacing.Medium, children: /* @__PURE__ */ e(
981
+ return /* @__PURE__ */ e(v, { className: "mx-txn-tag-manager-search", px: o.Spacing.Large, py: o.Spacing.Medium, children: /* @__PURE__ */ e(
949
982
  Te,
950
983
  {
951
984
  InputProps: {
952
985
  startAdornment: /* @__PURE__ */ e(ye, { position: "start", children: /* @__PURE__ */ e(Xe, { color: "disabled" }) }),
953
986
  endAdornment: /* @__PURE__ */ e(ye, { position: "end", sx: { padding: 0 }, children: r ? n : null })
954
987
  },
955
- "aria-label": a.search_aria,
988
+ "aria-label": i.search_aria,
956
989
  name: "search",
957
- onChange: (c) => t(c.target.value),
958
- placeholder: a.search_placeholder,
990
+ onChange: (s) => t(s.target.value),
991
+ placeholder: i.search_placeholder,
959
992
  sx: { bgcolor: "background.paper", width: "100%" },
960
993
  value: r
961
994
  }
962
995
  ) });
963
- }, Lt = b(wt), Rt = ({ onTagChecked: t, selectedTags: r, tag: a }) => {
964
- const { onEvent: s } = L(), { removeTag: o, updateTag: n } = v(), { common: c, transactions: d } = A(), [i, u] = _.useState(!1), [m, g] = _.useState(!1), [p, x] = _.useState(""), [y, N] = _.useState(""), C = async () => {
965
- s(h.ON_TRANSACTION_TAGS_TAG_EDIT_SAVED), a && await n({ ...a, name: p }), u(!1);
966
- }, R = async () => {
967
- s(h.ON_TRANSACTION_TAGS_TAG_DELETED), await o(a.guid), g(!1);
996
+ }, kt = A(Lt), Rt = ({ onTagChecked: t, selectedTags: r, tag: i }) => {
997
+ const { onEvent: a } = L(), { removeTag: o, updateTag: n } = w(), { common: s, transactions: d } = x(), [c, u] = _.useState(!1), [m, p] = _.useState(!1), [g, S] = _.useState(""), [y, N] = _.useState(""), f = async () => {
998
+ a(h.ON_TRANSACTION_TAGS_TAG_EDIT_SAVED), i && await n({ ...i, name: g }), u(!1);
999
+ }, k = async () => {
1000
+ a(h.ON_TRANSACTION_TAGS_TAG_DELETED), await o(i.guid), p(!1);
968
1001
  };
969
1002
  _.useEffect(() => {
970
- N(p.length > 40 ? d.tags_error_name_must_be_40_chars : "");
971
- }, [p]);
1003
+ N(g.length > 40 ? d.tags_error_name_must_be_40_chars : "");
1004
+ }, [g]);
972
1005
  const K = () => {
973
- s(h.ON_TRANSACTION_TAGS_TAG_EDIT_CLICK), x(a.name), u(!0);
1006
+ a(h.ON_TRANSACTION_TAGS_TAG_EDIT_CLICK), S(i.name), u(!0);
974
1007
  }, $ = () => {
975
- s(h.ON_TRANSACTION_TAGS_TAG_DELETE_CLICK), g(!0);
1008
+ a(h.ON_TRANSACTION_TAGS_TAG_DELETE_CLICK), p(!0);
976
1009
  };
977
1010
  return /* @__PURE__ */ l(
978
1011
  F,
@@ -980,11 +1013,11 @@ const it = ({ transaction: t, onClick: r }) => {
980
1013
  className: "mx-txn-transaction-manager-row",
981
1014
  disableGutters: !0,
982
1015
  disablePadding: !0,
983
- secondaryAction: !a.is_default_tag && /* @__PURE__ */ l(f, { direction: "row", children: [
1016
+ secondaryAction: !i.is_default_tag && /* @__PURE__ */ l(b, { direction: "row", children: [
984
1017
  /* @__PURE__ */ e(
985
1018
  Q,
986
1019
  {
987
- "aria-label": `Edit ${a.name} tag`,
1020
+ "aria-label": `Edit ${i.name} tag`,
988
1021
  color: "secondary",
989
1022
  onClick: K,
990
1023
  children: /* @__PURE__ */ e(Ve, { color: "secondary" })
@@ -993,7 +1026,7 @@ const it = ({ transaction: t, onClick: r }) => {
993
1026
  /* @__PURE__ */ e(
994
1027
  Q,
995
1028
  {
996
- "aria-label": `Delete ${a.name} tag`,
1029
+ "aria-label": `Delete ${i.name} tag`,
997
1030
  color: "secondary",
998
1031
  onClick: $,
999
1032
  children: /* @__PURE__ */ e(oe, { color: "secondary" })
@@ -1004,12 +1037,12 @@ const it = ({ transaction: t, onClick: r }) => {
1004
1037
  /* @__PURE__ */ l(
1005
1038
  U,
1006
1039
  {
1007
- "aria-checked": r.includes(a.guid),
1008
- onClick: () => t(a.guid),
1040
+ "aria-checked": r.includes(i.guid),
1041
+ onClick: () => t(i.guid),
1009
1042
  role: "checkbox",
1010
1043
  children: [
1011
- /* @__PURE__ */ e(X, { sx: { ml: 0 }, children: /* @__PURE__ */ e(Je, { checked: r.includes(a.guid), edge: "start", tabIndex: -1 }) }),
1012
- /* @__PURE__ */ e(M, { children: a.name })
1044
+ /* @__PURE__ */ e(X, { sx: { ml: 0 }, children: /* @__PURE__ */ e(Je, { checked: r.includes(i.guid), edge: "start", tabIndex: -1 }) }),
1045
+ /* @__PURE__ */ e(M, { children: i.name })
1013
1046
  ]
1014
1047
  }
1015
1048
  ),
@@ -1017,9 +1050,9 @@ const it = ({ transaction: t, onClick: r }) => {
1017
1050
  V,
1018
1051
  {
1019
1052
  copy: { title: "Update tag name" },
1020
- isOpen: i,
1053
+ isOpen: c,
1021
1054
  onClose: () => u(!1),
1022
- onPrimaryAction: C,
1055
+ onPrimaryAction: f,
1023
1056
  onSecondaryAction: () => u(!1),
1024
1057
  children: [
1025
1058
  /* @__PURE__ */ e(
@@ -1028,10 +1061,10 @@ const it = ({ transaction: t, onClick: r }) => {
1028
1061
  "aria-describedby": y ? "update-tag-error" : void 0,
1029
1062
  "aria-label": d.tags_update_the_tag_name,
1030
1063
  name: "update-tag",
1031
- onChange: (I) => x(I.target.value),
1064
+ onChange: (I) => S(I.target.value),
1032
1065
  placeholder: "Tag name",
1033
1066
  sx: { width: "100%" },
1034
- value: p
1067
+ value: g
1035
1068
  }
1036
1069
  ),
1037
1070
  /* @__PURE__ */ e(le, { id: "update-tag-error", sx: { color: "error.main" }, variant: "ParagraphSmall", children: y })
@@ -1043,54 +1076,54 @@ const it = ({ transaction: t, onClick: r }) => {
1043
1076
  {
1044
1077
  copy: { title: d.tags_delete_title },
1045
1078
  isOpen: m,
1046
- onClose: () => g(!1),
1047
- onPrimaryAction: R,
1048
- onSecondaryAction: () => s(h.ON_TRANSACTION_TAGS_TAG_DELETE_CANCEL_CLICK),
1049
- primaryText: c.delete_button,
1050
- secondaryText: c.cancel_button,
1079
+ onClose: () => p(!1),
1080
+ onPrimaryAction: k,
1081
+ onSecondaryAction: () => a(h.ON_TRANSACTION_TAGS_TAG_DELETE_CANCEL_CLICK),
1082
+ primaryText: s.delete_button,
1083
+ secondaryText: s.cancel_button,
1051
1084
  children: /* @__PURE__ */ e(T, { truncate: !1, children: d.tags_deleting_this_tag_will_remove_it })
1052
1085
  }
1053
1086
  )
1054
1087
  ]
1055
1088
  }
1056
1089
  );
1057
- }, kt = b(Rt), Pt = ({ selectedTags: t, onTagChecked: r }) => {
1058
- const { tags: a } = v(), [s, o] = _.useState(""), n = a.filter(
1059
- (c) => c.name.toLowerCase().includes(s.toLowerCase())
1090
+ }, Pt = A(Rt), Gt = ({ selectedTags: t, onTagChecked: r }) => {
1091
+ const { tags: i } = w(), [a, o] = _.useState(""), n = i.filter(
1092
+ (s) => s.name.toLowerCase().includes(a.toLowerCase())
1060
1093
  );
1061
1094
  return /* @__PURE__ */ l("div", { className: "mx-txn-tag-manager", children: [
1062
1095
  /* @__PURE__ */ e(
1063
- Lt,
1096
+ kt,
1064
1097
  {
1065
- onSearchValueChanged: (c) => o(c),
1066
- searchValue: s
1098
+ onSearchValueChanged: (s) => o(s),
1099
+ searchValue: a
1067
1100
  }
1068
1101
  ),
1069
1102
  /* @__PURE__ */ e(Ot, {}),
1070
- /* @__PURE__ */ e(ne, { sx: { boxShadow: "none" }, children: /* @__PURE__ */ e(J, { children: n.map((c) => /* @__PURE__ */ l(_.Fragment, { children: [
1071
- /* @__PURE__ */ e(kt, { onTagChecked: r, selectedTags: t, tag: c }),
1103
+ /* @__PURE__ */ e(ne, { sx: { boxShadow: "none" }, children: /* @__PURE__ */ e(J, { children: n.map((s) => /* @__PURE__ */ l(_.Fragment, { children: [
1104
+ /* @__PURE__ */ e(Pt, { onTagChecked: r, selectedTags: t, tag: s }),
1072
1105
  /* @__PURE__ */ e(Z, { sx: { ml: 24 } })
1073
- ] }, c.guid)) }) })
1106
+ ] }, s.guid)) }) })
1074
1107
  ] });
1075
- }, Gt = b(Pt), Mt = ({ transaction: t }) => {
1076
- const { onEvent: r } = L(), { tags: a, updateTaggings: s, updateTransaction: o } = v(), { common: n, transactions: c } = A(), { updateManualTransaction: d } = G(), [i, u] = _.useState(!1), [m, g] = _.useState(t.tags);
1108
+ }, Mt = A(Gt), Kt = ({ transaction: t }) => {
1109
+ const { onEvent: r } = L(), { tags: i, updateTaggings: a, updateTransaction: o } = w(), { common: n, transactions: s } = x(), { updateManualTransaction: d } = G(), [c, u] = _.useState(!1), [m, p] = _.useState(t.tags);
1077
1110
  _.useEffect(() => {
1078
- g(t.tags);
1079
- }, [i, t]);
1080
- const p = (N) => {
1081
- const C = [...m], R = m.indexOf(N);
1082
- R >= 0 ? C.splice(R, 1) : C.push(N), g(C);
1083
- }, x = async () => {
1111
+ p(t.tags);
1112
+ }, [c, t]);
1113
+ const g = (N) => {
1114
+ const f = [...m], k = m.indexOf(N);
1115
+ k >= 0 ? f.splice(k, 1) : f.push(N), p(f);
1116
+ }, S = async () => {
1084
1117
  if (t.is_manual && !t.guid) {
1085
1118
  d({ ...t, tags: m }), u(!1);
1086
1119
  return;
1087
1120
  }
1088
- await s(m, t.guid), await o({ ...t, tags: m }), r(P.TRANSACTION_DETAILS_CLICK_TAGS, { transaction_guid: t.guid }), u(!1);
1121
+ await a(m, t.guid), await o({ ...t, tags: m }), r(P.TRANSACTION_DETAILS_CLICK_TAGS, { transaction_guid: t.guid }), u(!1);
1089
1122
  }, y = _.useMemo(
1090
1123
  () => t.tags.map(
1091
- (N, C, R) => `${a.find((K) => K.guid === N)?.name}${C < R.length - 1 ? " / " : ""}`
1124
+ (N, f, k) => `${i.find((K) => K.guid === N)?.name}${f < k.length - 1 ? " / " : ""}`
1092
1125
  ),
1093
- [a, t]
1126
+ [i, t]
1094
1127
  );
1095
1128
  return /* @__PURE__ */ l(_.Fragment, { children: [
1096
1129
  /* @__PURE__ */ e(F, { disableGutters: !0, disablePadding: !0, children: /* @__PURE__ */ l(
@@ -1100,16 +1133,16 @@ const it = ({ transaction: t, onClick: r }) => {
1100
1133
  r(h.ON_TRANSACTION_TAGS_CLICK), u(!0);
1101
1134
  },
1102
1135
  children: [
1103
- /* @__PURE__ */ e(B, { children: /* @__PURE__ */ e(z, { sx: { bgcolor: "border.light" }, variant: "rounded", children: /* @__PURE__ */ e(S, { name: "local_offer", sx: { color: "text.primary" }, weight: D.Dark }) }) }),
1136
+ /* @__PURE__ */ e(B, { children: /* @__PURE__ */ e(z, { sx: { bgcolor: "border.light" }, variant: "rounded", children: /* @__PURE__ */ e(C, { name: "local_offer", sx: { color: "text.primary" }, weight: D.Dark }) }) }),
1104
1137
  /* @__PURE__ */ e(
1105
1138
  M,
1106
1139
  {
1107
- primary: c.tags_title,
1140
+ primary: s.tags_title,
1108
1141
  primaryTypographyProps: { variant: "XSmall" },
1109
- secondary: /* @__PURE__ */ e(T, { bold: !0, variant: "Body", children: t.tags?.length > 0 ? y : c.tags_desc })
1142
+ secondary: /* @__PURE__ */ e(T, { bold: !0, variant: "Body", children: t.tags?.length > 0 ? y : s.tags_desc })
1110
1143
  }
1111
1144
  ),
1112
- /* @__PURE__ */ e(X, { children: /* @__PURE__ */ e(S, { name: "chevron_right", weight: D.Dark }) })
1145
+ /* @__PURE__ */ e(X, { children: /* @__PURE__ */ e(C, { name: "chevron_right", weight: D.Dark }) })
1113
1146
  ]
1114
1147
  }
1115
1148
  ) }),
@@ -1117,33 +1150,33 @@ const it = ({ transaction: t, onClick: r }) => {
1117
1150
  de,
1118
1151
  {
1119
1152
  ariaLabelClose: n.close_aria,
1120
- isOpen: i,
1153
+ isOpen: c,
1121
1154
  onClose: () => u(!1),
1122
- onPrimaryAction: x,
1155
+ onPrimaryAction: S,
1123
1156
  primaryText: n.save_button,
1124
1157
  secondaryText: n.cancel_button,
1125
- title: c.tags_title,
1126
- children: /* @__PURE__ */ e(Gt, { onTagChecked: p, selectedTags: m })
1158
+ title: s.tags_title,
1159
+ children: /* @__PURE__ */ e(Mt, { onTagChecked: g, selectedTags: m })
1127
1160
  }
1128
1161
  )
1129
1162
  ] });
1130
- }, Kt = b(Mt), $t = ({ transaction: t, viewOnly: r = !1 }) => {
1131
- const { updateTransaction: a } = v(), { common: s, transactions: o } = A(), { onEvent: n } = L(), [c, d] = _.useState(!1), [i, u] = _.useState(""), m = _.useRef(null);
1163
+ }, $t = A(Kt), Bt = ({ transaction: t, viewOnly: r = !1 }) => {
1164
+ const { updateTransaction: i } = w(), { common: a, transactions: o } = x(), { onEvent: n } = L(), [s, d] = _.useState(!1), [c, u] = _.useState(""), m = _.useRef(null);
1132
1165
  _.useEffect(() => {
1133
- c && (u(t.description), m?.current?.focus());
1134
- }, [c]);
1135
- const g = async () => {
1166
+ s && (u(t.description), m?.current?.focus());
1167
+ }, [s]);
1168
+ const p = async () => {
1136
1169
  n(P.TRANSACTION_DETAILS_CLICK_DESCRIPTION, {
1137
1170
  transaction_guid: t.guid
1138
- }), await a({ ...t, description: i }), d(!1);
1171
+ }), await i({ ...t, description: c }), d(!1);
1139
1172
  };
1140
- return /* @__PURE__ */ e(w, { className: "mx-txn-transaction-description", children: c ? /* @__PURE__ */ l(je, { row: !0, children: [
1173
+ return /* @__PURE__ */ e(v, { className: "mx-txn-transaction-description", children: s ? /* @__PURE__ */ l(je, { row: !0, children: [
1141
1174
  /* @__PURE__ */ e(
1142
- De,
1175
+ ve,
1143
1176
  {
1144
1177
  "aria-label": o.description_add_a_subcategory,
1145
1178
  name: "add-subcategory",
1146
- onChange: (p) => u(p.target.value),
1179
+ onChange: (g) => u(g.target.value),
1147
1180
  ref: m,
1148
1181
  sx: {
1149
1182
  backgroundColor: "background.paper",
@@ -1151,20 +1184,20 @@ const it = ({ transaction: t, onClick: r }) => {
1151
1184
  ".MuiOutlinedInput-input": { p: 11 },
1152
1185
  width: 250
1153
1186
  },
1154
- value: i
1187
+ value: c
1155
1188
  }
1156
1189
  ),
1157
1190
  /* @__PURE__ */ e(
1158
1191
  ce,
1159
1192
  {
1160
- disabled: !i,
1161
- onClick: g,
1193
+ disabled: !c,
1194
+ onClick: p,
1162
1195
  sx: { borderTopLeftRadius: 0, borderBottomLeftRadius: 0 },
1163
1196
  variant: "outlined",
1164
- children: s.save_button
1197
+ children: a.save_button
1165
1198
  }
1166
1199
  )
1167
- ] }) : /* @__PURE__ */ l(f, { alignItems: "center", direction: "row", gap: 4, sx: { minHeight: 44 }, children: [
1200
+ ] }) : /* @__PURE__ */ l(b, { alignItems: "center", direction: "row", gap: 4, sx: { minHeight: 44 }, children: [
1168
1201
  /* @__PURE__ */ e(T, { bold: !0, children: t.description }),
1169
1202
  !r && /* @__PURE__ */ e(
1170
1203
  Q,
@@ -1174,18 +1207,18 @@ const it = ({ transaction: t, onClick: r }) => {
1174
1207
  d(!0), n(h.ON_TRANSACTION_DESCRIPTION_EDIT_CLICK);
1175
1208
  },
1176
1209
  sx: { color: "action.active" },
1177
- children: /* @__PURE__ */ e(S, { name: "create", size: 22 })
1210
+ children: /* @__PURE__ */ e(C, { name: "create", size: 22 })
1178
1211
  }
1179
1212
  )
1180
1213
  ] }) });
1181
- }, Bt = b($t), Ft = ({ transaction: t }) => {
1182
- const { updateTransaction: r } = v(), { transactions: a } = A(), { onEvent: s } = L(), o = ve(), n = async () => {
1183
- s(P.TRANSACTION_DETAILS_CLICK_FLAG, { transaction_guid: t.guid }), await r({ ...t, is_flagged: !t.is_flagged });
1214
+ }, Ft = A(Bt), Ht = ({ transaction: t }) => {
1215
+ const { updateTransaction: r } = w(), { transactions: i } = x(), { onEvent: a } = L(), o = De(), n = async () => {
1216
+ a(P.TRANSACTION_DETAILS_CLICK_FLAG, { transaction_guid: t.guid }), await r({ ...t, is_flagged: !t.is_flagged });
1184
1217
  };
1185
1218
  return /* @__PURE__ */ e("div", { className: "mx-txn-transaction-flag", children: /* @__PURE__ */ e(
1186
1219
  qe,
1187
1220
  {
1188
- "aria-label": a.flag_btn_aria,
1221
+ "aria-label": i.flag_btn_aria,
1189
1222
  "aria-pressed": t.is_flagged,
1190
1223
  color: "warning",
1191
1224
  onClick: n,
@@ -1210,7 +1243,7 @@ const it = ({ transaction: t, onClick: r }) => {
1210
1243
  children: /* @__PURE__ */ e(We, { color: "inherit" })
1211
1244
  }
1212
1245
  ) });
1213
- }, Ht = b(Ft), ae = (t, r, a, s = !0, o = "inset") => s ? /* @__PURE__ */ l(_.Fragment, { children: [
1246
+ }, zt = A(Ht), ae = (t, r, i, a = !0, o = "inset") => a ? /* @__PURE__ */ l(_.Fragment, { children: [
1214
1247
  /* @__PURE__ */ l(F, { disableGutters: !0, disablePadding: !0, children: [
1215
1248
  /* @__PURE__ */ e(B, { children: /* @__PURE__ */ e(z, { sx: { bgcolor: "border.light" }, variant: "rounded", children: t }) }),
1216
1249
  /* @__PURE__ */ e(
@@ -1218,16 +1251,16 @@ const it = ({ transaction: t, onClick: r }) => {
1218
1251
  {
1219
1252
  primary: r,
1220
1253
  primaryTypographyProps: { variant: "XSmall" },
1221
- secondary: a
1254
+ secondary: i
1222
1255
  }
1223
1256
  )
1224
1257
  ] }),
1225
1258
  /* @__PURE__ */ e(Z, { variant: o })
1226
- ] }) : null, zt = ({ transaction: t }) => {
1227
- const { transactions: r } = A(), { tags: a } = v(), s = _.useMemo(() => {
1228
- const o = new Map(a.map((n) => [n.guid, n.name]));
1259
+ ] }) : null, Ut = ({ transaction: t }) => {
1260
+ const { transactions: r } = x(), { tags: i } = w(), a = _.useMemo(() => {
1261
+ const o = new Map(i.map((n) => [n.guid, n.name]));
1229
1262
  return t.tags.map((n) => o.get(n)).filter(Boolean).join(" / ");
1230
- }, [a, t.tags]);
1263
+ }, [i, t.tags]);
1231
1264
  return /* @__PURE__ */ l(J, { sx: { "& .MuiListItem-root": { px: 24, py: 12 } }, children: [
1232
1265
  ae(
1233
1266
  /* @__PURE__ */ e(
@@ -1243,92 +1276,94 @@ const it = ({ transaction: t, onClick: r }) => {
1243
1276
  /* @__PURE__ */ e(T, { bold: !0, variant: "Body", children: t.category ?? r.actions_select_a_category })
1244
1277
  ),
1245
1278
  ae(
1246
- /* @__PURE__ */ e(S, { name: "calendar_month", sx: { color: "text.primary" }, weight: D.Dark }),
1279
+ /* @__PURE__ */ e(C, { name: "calendar_month", sx: { color: "text.primary" }, weight: D.Dark }),
1247
1280
  r.date_title,
1248
- /* @__PURE__ */ e(T, { bold: !0, variant: "Body", children: Ee(W(t.date), Oe.YEAR_MONTH_DAY) })
1281
+ /* @__PURE__ */ e(T, { bold: !0, variant: "Body", children: we(W(t.date), Ee.YEAR_MONTH_DAY) })
1249
1282
  ),
1250
1283
  ae(
1251
- /* @__PURE__ */ e(S, { name: "article", sx: { color: "text.primary" }, weight: D.Dark }),
1284
+ /* @__PURE__ */ e(C, { name: "article", sx: { color: "text.primary" }, weight: D.Dark }),
1252
1285
  r.memo_title,
1253
1286
  /* @__PURE__ */ e(T, { bold: !0, sx: { overflowWrap: "break-word", whiteSpace: "wrap" }, variant: "Body", children: t.memo ?? r.memo_desc }),
1254
1287
  !!t.memo,
1255
1288
  t.tags?.length > 0 ? "inset" : "fullWidth"
1256
1289
  ),
1257
1290
  ae(
1258
- /* @__PURE__ */ e(S, { name: "local_offer", sx: { color: "text.primary" }, weight: D.Dark }),
1291
+ /* @__PURE__ */ e(C, { name: "local_offer", sx: { color: "text.primary" }, weight: D.Dark }),
1259
1292
  r.tags_title,
1260
- /* @__PURE__ */ e(T, { bold: !0, variant: "Body", children: t.tags?.length ? s : r.tags_desc }),
1293
+ /* @__PURE__ */ e(T, { bold: !0, variant: "Body", children: t.tags?.length ? a : r.tags_desc }),
1261
1294
  !!t.tags?.length,
1262
1295
  "fullWidth"
1263
1296
  )
1264
1297
  ] });
1265
- }, Ut = b(zt), Xt = ({
1298
+ }, Xt = A(Ut), Vt = ({
1266
1299
  bottomActions: t = at,
1267
- topActions: r = tt,
1300
+ canFlagTransaction: r = !0,
1301
+ topActions: i = tt,
1268
1302
  transaction: a
1269
1303
  }) => {
1270
- const { onEvent: s } = L(), { isCopyLoaded: o } = Fe(), { userFeatures: n } = He(), c = a?.number && a.number.length > 4;
1304
+ const { onEvent: o } = L(), { isCopyLoaded: n } = Fe(), { userFeatures: s } = He(), d = a?.number && a.number.length > 4;
1271
1305
  if (_.useEffect(
1272
- () => s(P.TRANSACTION_DETAILS_VIEW, { transaction_guid: a.guid }),
1306
+ () => o(P.TRANSACTION_DETAILS_VIEW, { transaction_guid: a.guid }),
1273
1307
  []
1274
- ), !o)
1308
+ ), !n)
1275
1309
  return /* @__PURE__ */ e(Ie, {});
1276
- const d = $e(n, "MX_TXN_DETAILS_VIEW_ONLY");
1277
- return /* @__PURE__ */ e(w, { className: "mx-txn-transaction-details", width: "100%", children: a && /* @__PURE__ */ l(f, { children: [
1278
- /* @__PURE__ */ l(f, { gap: 12, p: 24, children: [
1310
+ const c = $e(s, "MX_TXN_DETAILS_VIEW_ONLY");
1311
+ return /* @__PURE__ */ e(v, { className: "mx-txn-transaction-details", width: "100%", children: a && /* @__PURE__ */ l(b, { children: [
1312
+ /* @__PURE__ */ l(b, { gap: 12, p: 24, children: [
1279
1313
  /* @__PURE__ */ e(ne, { elevation: 2, sx: { width: 64 }, children: /* @__PURE__ */ e(
1280
- pe,
1314
+ ge,
1281
1315
  {
1282
1316
  categoryGuid: a.top_level_category_guid || "",
1283
1317
  merchantGuid: a.merchant_guid || "",
1284
1318
  size: 64
1285
1319
  }
1286
1320
  ) }),
1287
- /* @__PURE__ */ e(Bt, { transaction: a, viewOnly: d }),
1288
- /* @__PURE__ */ l(f, { direction: "row", justifyContent: "space-between", sx: { minHeight: 44 }, children: [
1321
+ /* @__PURE__ */ e(Ft, { transaction: a, viewOnly: c }),
1322
+ /* @__PURE__ */ l(b, { direction: "row", justifyContent: "space-between", sx: { minHeight: 44 }, children: [
1289
1323
  /* @__PURE__ */ l(Ae, { color: a.isIncome ? "success.main" : "text.primary", children: [
1290
1324
  a.isIncome ? "+" : "",
1291
1325
  te(a.amount, "0,0.00")
1292
1326
  ] }),
1293
- !d && /* @__PURE__ */ e(Ht, { transaction: a })
1327
+ !c && r && /* @__PURE__ */ e(zt, { transaction: a })
1294
1328
  ] }),
1295
- /* @__PURE__ */ l(f, { bgcolor: "background.highlight", borderRadius: "12px", gap: 4, p: 8, children: [
1329
+ /* @__PURE__ */ l(b, { bgcolor: "background.highlight", borderRadius: "12px", gap: 4, p: 8, children: [
1296
1330
  /* @__PURE__ */ e(T, { bold: !0, children: `${a.account}
1297
- ${c ? a.number : "•".repeat(4).concat(a.number ?? "")}` }),
1331
+ ${d ? a.number : "•".repeat(4).concat(a.number ?? "")}` }),
1298
1332
  /* @__PURE__ */ e(T, { bold: !0, color: "secondary", variant: "Tiny", children: a.feed_description })
1299
1333
  ] })
1300
1334
  ] }),
1301
- /* @__PURE__ */ e(ne, { square: !0, sx: { boxShadow: "none" }, children: d ? /* @__PURE__ */ e(Ut, { transaction: a }) : /* @__PURE__ */ e(J, { children: r.map((i, u) => /* @__PURE__ */ l(_.Fragment, { children: [
1302
- i === q.Category && /* @__PURE__ */ e(mt, { transaction: a }),
1303
- i === q.Date && /* @__PURE__ */ e(gt, { transaction: a }),
1304
- i === q.Memo && /* @__PURE__ */ e(bt, { transaction: a }),
1305
- i === q.Tags && /* @__PURE__ */ e(Kt, { transaction: a }),
1306
- /* @__PURE__ */ e(Z, { variant: u < r.length - 1 ? "inset" : "fullWidth" })
1307
- ] }, i)) }) }),
1308
- !d && /* @__PURE__ */ l(_.Fragment, { children: [
1335
+ /* @__PURE__ */ e(ne, { square: !0, sx: { boxShadow: "none" }, children: c ? /* @__PURE__ */ e(Xt, { transaction: a }) : /* @__PURE__ */ e(J, { children: i.map((u, m) => /* @__PURE__ */ l(_.Fragment, { children: [
1336
+ u === q.Category && /* @__PURE__ */ e(mt, { transaction: a }),
1337
+ u === q.Date && /* @__PURE__ */ e(pt, { transaction: a }),
1338
+ u === q.Memo && /* @__PURE__ */ e(bt, { transaction: a }),
1339
+ u === q.Tags && /* @__PURE__ */ e($t, { transaction: a }),
1340
+ /* @__PURE__ */ e(Z, { variant: m < i.length - 1 ? "inset" : "fullWidth" })
1341
+ ] }, u)) }) }),
1342
+ !c && t.length > 0 && /* @__PURE__ */ l(_.Fragment, { children: [
1309
1343
  /* @__PURE__ */ e(T, { bold: !0, mb: 8, ml: 26, mt: 16, variant: "Body", children: "Actions" }),
1310
1344
  /* @__PURE__ */ e(ne, { square: !0, sx: { boxShadow: "none" }, children: /* @__PURE__ */ l(J, { children: [
1311
- t.map((i, u) => /* @__PURE__ */ l(_.Fragment, { children: [
1312
- i === re.SplitTransaction && /* @__PURE__ */ e(vt, { transaction: a }),
1313
- i === re.HideTransaction && /* @__PURE__ */ e(Ct, { transaction: a }),
1314
- i === re.MerchantLogo && /* @__PURE__ */ e(yt, { transaction: a }),
1315
- /* @__PURE__ */ e(Z, { variant: u < t.length - 1 ? "inset" : "fullWidth" })
1316
- ] }, i)),
1345
+ t.map((u, m) => /* @__PURE__ */ l(_.Fragment, { children: [
1346
+ u === re.SplitTransaction && /* @__PURE__ */ e(wt, { transaction: a }),
1347
+ u === re.HideTransaction && /* @__PURE__ */ e(Ct, { transaction: a }),
1348
+ u === re.MerchantLogo && /* @__PURE__ */ e(yt, { transaction: a }),
1349
+ /* @__PURE__ */ e(Z, { variant: m < t.length - 1 ? "inset" : "fullWidth" })
1350
+ ] }, u)),
1317
1351
  a.is_manual && !a.parent_guid && !a.has_been_split && /* @__PURE__ */ e(ht, { transaction: a })
1318
1352
  ] }) })
1319
1353
  ] })
1320
1354
  ] }) });
1321
- }, ka = b(Xt);
1355
+ }, Pa = A(Vt);
1322
1356
  export {
1323
1357
  re as B,
1324
1358
  mt as C,
1325
- gt as D,
1359
+ pt as D,
1326
1360
  bt as M,
1327
1361
  lt as S,
1328
1362
  Ra as T,
1329
- ka as a,
1363
+ Pa as a,
1330
1364
  st as b,
1331
- Kt as c,
1332
- q as d,
1365
+ At as c,
1366
+ $t as d,
1367
+ q as e,
1333
1368
  G as u
1334
1369
  };