@mx-cartographer/experiences 9.0.2 → 9.0.4-alpha.mm0

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 (95) hide show
  1. package/CHANGELOG.md +11 -0
  2. package/dist/{Account-BaJmiJAG.mjs → Account-DR7Plrqy.mjs} +10 -10
  3. package/dist/AccountDetailsDrawer-C8oJP3J4.mjs +921 -0
  4. package/dist/AccountDetailsHeader-ByGNPZpO.mjs +228 -0
  5. package/dist/{AccountUtils-T5_Odvos.mjs → AccountUtils-B8ZzWI-d.mjs} +3 -3
  6. package/dist/{Analytics-CzGzz_sE.mjs → Analytics-WeZYytR0.mjs} +3 -0
  7. package/dist/BeatMaterialIcon-1KOfRZrA.mjs +26 -0
  8. package/dist/{CategorySelectorDrawer-8soGrhB8.mjs → CategorySelectorDrawer-BArJC27L.mjs} +1 -1
  9. package/dist/Connect-BH0Pt6zc.mjs +42 -0
  10. package/dist/{ConnectCard-CCep7Zqe.mjs → ConnectCard-Dwfgv24k.mjs} +1 -1
  11. package/dist/{ConnectDrawer-Cnjr3Ddg.mjs → ConnectDrawer-DytyIhaF.mjs} +8 -9
  12. package/dist/{ConnectionsDrawer-CtfPXk0M.mjs → ConnectionsDrawer-BHJPKXYF.mjs} +8 -9
  13. package/dist/{CurrencyInput-adTIRtL3.mjs → CurrencyInput-DaGEQaLW.mjs} +1 -1
  14. package/dist/DateUtil-CzBmbjmA.mjs +74 -0
  15. package/dist/{DebtUtils-DD3186U-.mjs → DebtUtils-i4pI2Uoe.mjs} +6 -6
  16. package/dist/{EmbeddedCard-DPwJjqMH.mjs → EmbeddedCard-CQpbZrmP.mjs} +4 -4
  17. package/dist/{Error-Dogaw2jO.mjs → Error-Dtw6yxkf.mjs} +1 -1
  18. package/dist/{ExportCsvAction-Bw02ZJEj.mjs → ExportCsvAction-bovG-NJr.mjs} +2 -2
  19. package/dist/{GlobalAccountFilter-7Cg2-9A5.mjs → GlobalAccountFilter-CYqzqmAd.mjs} +10 -10
  20. package/dist/{Help-DJ8PrVHX.mjs → Help-5klKVqkX.mjs} +2 -2
  21. package/dist/{LineChart-CejWS_rh.mjs → LineChart-CUfiH86G.mjs} +1 -1
  22. package/dist/{ListItemAction-CzZ8s39Z.mjs → ListItemAction-BqUCLj_w.mjs} +1 -1
  23. package/dist/{ListItemWrapper-B5r-YQQ_.mjs → ListItemWrapper-BHIbqx7E.mjs} +3 -3
  24. package/dist/ManageIncome-Cz6hvpdA.mjs +902 -0
  25. package/dist/{MicroWidgetContainer-CfKdQfhi.mjs → MicroWidgetContainer-B2NnKBgW.mjs} +1 -1
  26. package/dist/{MiniWidgetContainer-BdPiUU-u.mjs → MiniWidgetContainer-Bmv_WeUd.mjs} +1 -1
  27. package/dist/{NetWorthUtils-DilGN1nW.mjs → NetWorthUtils-DfSH3z70.mjs} +2 -2
  28. package/dist/{NotificationSettings-B4JA5IKE.mjs → NotificationSettings-Ci89BBRI.mjs} +4 -4
  29. package/dist/{OriginalBalanceAction-BybTXDtO.mjs → OriginalBalanceAction-YrvxBYAl.mjs} +3 -3
  30. package/dist/{RecurringSettings-D2xbNb67.mjs → RecurringSettings-ClYjsmPz.mjs} +4 -4
  31. package/dist/RecurringTransactionsUtil-zOxq5pzY.mjs +298 -0
  32. package/dist/Select-CSpkK5cR.mjs +61 -0
  33. package/dist/SpendingData-Fii_xATx.mjs +53 -0
  34. package/dist/{SpendingLegend-5Ct_FZ8o.mjs → SpendingLegend-Bn3DzGyK.mjs} +1 -1
  35. package/dist/TabContentContainer-B0eYJP5p.mjs +48 -0
  36. package/dist/{TransactionDetails-DctXr07p.mjs → TransactionDetails-DRN0GIaZ.mjs} +6 -6
  37. package/dist/{UserStore-CRpKQjpP.mjs → UserStore-DzWku3t0.mjs} +81 -40
  38. package/dist/{ViewMoreMicroCard-BD_MNc2z.mjs → ViewMoreMicroCard-Dxghxphh.mjs} +211 -231
  39. package/dist/{WidgetContainer-CmbU4CBH.mjs → WidgetContainer-D-LzIKFb.mjs} +3 -3
  40. package/dist/accounts/components/detailsdrawer/Accounts/AccountDetailsDrawer.d.ts +6 -0
  41. package/dist/accounts/index.d.ts +1 -0
  42. package/dist/accounts/index.es.js +220 -1035
  43. package/dist/analytics/index.es.js +8 -8
  44. package/dist/budgets/index.es.js +11 -11
  45. package/dist/cashflow/index.es.js +41 -41
  46. package/dist/categories/index.es.js +1 -1
  47. package/dist/common/components/DataRow.d.ts +1 -0
  48. package/dist/common/constants/Analytics.d.ts +3 -0
  49. package/dist/common/index.es.js +82 -83
  50. package/dist/core/index.es.js +8 -8
  51. package/dist/core/stores/RecurringTransactionsStore.d.ts +27 -1
  52. package/dist/core/types/localization/RecurringCopy.d.ts +14 -1
  53. package/dist/core/utils/DateUtil.d.ts +2 -0
  54. package/dist/core/utils/RecurringTransactionsUtil.d.ts +2 -1
  55. package/dist/dashboard/index.es.js +4 -4
  56. package/dist/debts/index.es.js +73 -73
  57. package/dist/finstrong/index.es.js +17 -17
  58. package/dist/goals/index.es.js +22 -23
  59. package/dist/help/index.es.js +4 -4
  60. package/dist/{hooks-BaO_gOI6.mjs → hooks-97sNJ_lf.mjs} +9 -9
  61. package/dist/insights/index.es.js +4 -4
  62. package/dist/investments/index.es.js +6 -6
  63. package/dist/merchants/index.es.js +1 -1
  64. package/dist/microinsights/index.es.js +12 -11
  65. package/dist/networth/index.es.js +9 -9
  66. package/dist/notifications/index.es.js +9 -9
  67. package/dist/recurringtransactions/components/RecurringTransactionDetailsDrawer.d.ts +3 -0
  68. package/dist/recurringtransactions/components/RecurringTransactionList.d.ts +11 -0
  69. package/dist/recurringtransactions/components/UpcomingRecurrenceCard.d.ts +6 -0
  70. package/dist/recurringtransactions/components/actions/LinkTransactionDrawer.d.ts +10 -0
  71. package/dist/recurringtransactions/components/actions/MarkAsPaidDialog.d.ts +7 -0
  72. package/dist/recurringtransactions/components/actions/MarkAsUnpaidDialog.d.ts +7 -0
  73. package/dist/recurringtransactions/index.es.js +402 -376
  74. package/dist/settings/index.es.js +7 -7
  75. package/dist/spending/index.es.js +8 -8
  76. package/dist/transactions/index.es.js +12 -12
  77. package/dist/trends/index.es.js +14 -14
  78. package/dist/useAccountDisplayName-BsiXA0qf.mjs +23 -0
  79. package/dist/{useInsightsEnabled-DaNLPmUU.mjs → useInsightsEnabled-D5Sdm0TJ.mjs} +1 -1
  80. package/dist/{useWidgetLoadTimer-CJb-RELP.mjs → useWidgetLoadTimer-B0tB-yzL.mjs} +1 -1
  81. package/package.json +1 -1
  82. package/dist/Account-BxHMlV9R.mjs +0 -30
  83. package/dist/AccountDetailsHeader-DIysk_4w.mjs +0 -95
  84. package/dist/AccountDisplayName-CO7z3v99.mjs +0 -11
  85. package/dist/AccountFields-mwJ8NXsX.mjs +0 -141
  86. package/dist/AccountListItem-BDXHs4tV.mjs +0 -94
  87. package/dist/Accounts-CseLC3lL.mjs +0 -5
  88. package/dist/Connect-Dk6GZEsA.mjs +0 -39
  89. package/dist/DateUtil-Bhq59ZVg.mjs +0 -58
  90. package/dist/ManageIncome-D1yBODQi.mjs +0 -595
  91. package/dist/RecurringTransactionsUtil-B3rLEx_g.mjs +0 -253
  92. package/dist/Select-BFt-HD-L.mjs +0 -55
  93. package/dist/SpendingData-PKlh8caU.mjs +0 -53
  94. package/dist/TabContentContainer-CnMXkVqr.mjs +0 -21
  95. package/dist/useAccountDisplayName-CFa_MrS6.mjs +0 -15
@@ -0,0 +1,228 @@
1
+ import { jsx as l, jsxs as p } from "react/jsx-runtime";
2
+ import { observer as v } from "mobx-react-lite";
3
+ import d from "@mui/material/Stack";
4
+ import { Text as b, Icon as y, H3 as w, InstitutionLogo as G, H2 as M } from "@mxenabled/mxui";
5
+ import { f as _, i as C, a as H, b as U } from "./NumberFormatting--XMeeBfr.mjs";
6
+ import h from "react";
7
+ import { G as Y, c as A, l as j, e as k, i as V, u as B } from "./hooks-97sNJ_lf.mjs";
8
+ import { c as u, b as z, f as W, h as $ } from "./Account-DR7Plrqy.mjs";
9
+ import { a as q, u as K, i as J, b as Q, c as X } from "./AccountUtils-B8ZzWI-d.mjs";
10
+ import { F as o } from "./Connect-BH0Pt6zc.mjs";
11
+ import { j as g } from "./DateUtil-CzBmbjmA.mjs";
12
+ import { b as s } from "./Localization-DnoVyBNK.mjs";
13
+ import { f as T, D } from "./DateFormats-HudZ3Bjs.mjs";
14
+ import Z from "@mui/material/Card";
15
+ import ee from "@mui/material/CardContent";
16
+ import te from "@mui/material/CardHeader";
17
+ import { L as ae } from "./Loader-CxeBwuPG.mjs";
18
+ import { I as ne, P as ie, S as re } from "./TabContentContainer-B0eYJP5p.mjs";
19
+ import { u as le } from "./useAccountDisplayName-BsiXA0qf.mjs";
20
+ const S = () => {
21
+ if (!h.useContext(Y))
22
+ throw new Error("useCategoryUiStore() must be used within the GlobalDataContext");
23
+ return A().uiStore;
24
+ }, Oe = (a, e) => {
25
+ const r = [
26
+ {
27
+ event: "account_details_click_account_name",
28
+ label: e.account_name,
29
+ name: "user_name",
30
+ placeholder: s(e.enter_value, e.account_name),
31
+ type: o.Input,
32
+ validation: (t) => t ? "" : s(e.field_is_required, e.account_name),
33
+ valueFormatter: (t) => t
34
+ }
35
+ ];
36
+ if (q(a)) {
37
+ r.unshift({
38
+ label: e.account_balance,
39
+ name: "balance",
40
+ placeholder: s(e.enter_value, e.account_balance),
41
+ type: o.Currency,
42
+ valueFormatter: (n) => _(n, "0,0.00")
43
+ });
44
+ const t = Object.keys(u).filter((n) => Number(n)).map((n) => ({
45
+ label: e.account_types[n],
46
+ value: Number(n),
47
+ icon: /* @__PURE__ */ l(y, { name: z[n] })
48
+ }));
49
+ r.push({
50
+ label: e.account_type,
51
+ name: "account_type",
52
+ options: t,
53
+ placeholder: s(e.select_value, e.account_type),
54
+ type: o.Select,
55
+ valueFormatter: (n) => t.find((i) => i.value === n)?.label
56
+ });
57
+ }
58
+ if (a.account_type === u.PROPERTY) {
59
+ const t = Object.keys(W).filter((n) => Number(n)).map((n) => ({
60
+ label: e.property_types[n],
61
+ value: Number(n),
62
+ icon: /* @__PURE__ */ l(y, { name: $[n] })
63
+ }));
64
+ r.push({
65
+ label: e.property_type,
66
+ name: "property_type",
67
+ options: t,
68
+ placeholder: s(e.select_value, e.property_type),
69
+ type: o.Select,
70
+ valueFormatter: (n) => t.find((i) => i.value === n)?.label
71
+ });
72
+ }
73
+ if (K(a)) {
74
+ let t = e.interest_rate, n = "interest_rate";
75
+ a.is_manual || (typeof a.apr == "number" && (t = e.apr, n = "apr"), typeof a.apy == "number" && (t = e.apy, n = "apy")), r.push({
76
+ event: "account_details_click_interest_rate",
77
+ label: t,
78
+ name: n,
79
+ placeholder: s(e.enter_value, t),
80
+ type: o.Input,
81
+ validation: (i) => C(i) ? "" : e.error_amount_is_invalid,
82
+ valueFormatter: (i) => C(i) ? H(i / 100) : i
83
+ });
84
+ }
85
+ return J(a) && (r.push({
86
+ label: e.minimum_payment,
87
+ name: "minimum_payment",
88
+ placeholder: s(e.enter_value, e.minimum_payment),
89
+ type: o.Currency,
90
+ valueFormatter: (t) => _(t, "0,0.00")
91
+ }), a.payment_due_at ? r.push({
92
+ label: e.next_payment,
93
+ name: "payment_due_at",
94
+ type: o.Date,
95
+ valueFormatter: (t) => {
96
+ const n = typeof t == "number" ? g(t) : t;
97
+ return T(n, D.MED_MONTH_SHORT_DAY_FULL_YEAR);
98
+ }
99
+ }) : r.push({
100
+ label: e.day_payment_due,
101
+ name: "day_payment_is_due",
102
+ placeholder: s(e.enter_value, e.day_payment_due),
103
+ type: o.Date,
104
+ valueFormatter: (t) => s(
105
+ e.day_of_every_month,
106
+ U(t <= 31 ? t : new Date(t).getDate())
107
+ )
108
+ })), Q(a) && r.push({
109
+ label: e.credit_limit,
110
+ name: "credit_limit",
111
+ placeholder: s(e.enter_value, e.credit_limit),
112
+ type: o.Currency,
113
+ valueFormatter: (t) => _(t, "0,0.00")
114
+ }), X(a) && r.push({
115
+ label: e.original_balance,
116
+ minAmount: 1,
117
+ name: "original_balance",
118
+ placeholder: s(e.enter_value, e.original_balance),
119
+ type: o.Currency,
120
+ valueFormatter: (t) => _(t, "0,0.00")
121
+ }), r;
122
+ }, I = (a, e, r) => {
123
+ let t = "", n = null, i = null, m = null, c = !1;
124
+ switch (a.account_type) {
125
+ case 1:
126
+ case 2: {
127
+ a.available_balance && r ? (t = e.available_balance, n = a.available_balance, i = a.available_balance ? e.current_balance : null, m = _(a.balance, "0,0.00"), c = !0) : (t = e.current_balance, n = a.balance);
128
+ break;
129
+ }
130
+ default:
131
+ if (t = e.current_balance, n = a.balance, a.minimum_payment && a.payment_due_at) {
132
+ const f = g(a.payment_due_at);
133
+ i = /* @__PURE__ */ l(b, { component: "strong", variant: "caption", children: s(
134
+ e.payment_due_on,
135
+ _(a.minimum_payment, "0,0.00"),
136
+ T(f, D.FULL_MONTH_DAY)
137
+ ) });
138
+ } else a.credit_limit && (i = e.available_credit, m = _(a.credit_limit - (a?.balance ?? 0), "0,0.00"));
139
+ }
140
+ return {
141
+ firstSubtitle: t,
142
+ firstValue: n,
143
+ secondSubtitle: i,
144
+ secondValue: m,
145
+ hasAvailableBalance: c
146
+ };
147
+ }, Pe = (a, e, r) => a.reduce((n, i) => {
148
+ const c = I(i, e, r).firstValue || 0;
149
+ return n + c;
150
+ }, 0), se = (a, e) => {
151
+ const r = [u.LOAN, u.MORTGAGE, u.PROPERTY].includes(
152
+ a
153
+ ), t = [
154
+ u.CREDIT_CARD,
155
+ u.LINE_OF_CREDIT,
156
+ u.PREPAID,
157
+ u.CHECKING_LINE_OF_CREDIT
158
+ ].includes(a);
159
+ return r ? { title: e.label_payments, description: e.chart_title_payments } : t ? { title: e.label_payments_spend, description: e.chart_title_payments_spend } : { title: e.label_income_spend, description: e.chart_title_income_spend };
160
+ }, oe = ({
161
+ sx: a,
162
+ ChartComponent: e,
163
+ header: r
164
+ }) => {
165
+ const { loadMonthlyCategoryTotals: t } = j(), { isInitialized: n } = k(), { selectedAccount: i } = S(), [m, c] = h.useState(!1);
166
+ return h.useEffect(() => {
167
+ n && t([i]).finally(() => {
168
+ c(!0);
169
+ });
170
+ }, [n, i]), !n || !m ? /* @__PURE__ */ l(ae, {}) : /* @__PURE__ */ p(
171
+ Z,
172
+ {
173
+ sx: {
174
+ "& .MuiCardContent-root:last-child": {
175
+ pb: 0
176
+ },
177
+ ...a
178
+ },
179
+ children: [
180
+ /* @__PURE__ */ l(te, { sx: { pb: 0 }, title: /* @__PURE__ */ l(w, { sx: { pb: 4 }, children: r }) }),
181
+ /* @__PURE__ */ l(ee, { sx: { p: 0 }, children: e ? /* @__PURE__ */ l(e, {}) : null })
182
+ ]
183
+ }
184
+ );
185
+ }, ue = v(oe), me = ({
186
+ customDetailsChart: a,
187
+ ChartComponent: e
188
+ }) => {
189
+ const { institutions: r } = A(), { selectedAccount: t } = S(), { config: n } = V(), { accounts: i } = B(), { firstSubtitle: m, firstValue: c, hasAvailableBalance: f, secondSubtitle: N, secondValue: E } = I(t, i, n.display_available_balance_in_accounts), F = r.find(
190
+ (L) => L.guid === t?.institution_guid
191
+ ), O = [
192
+ ...ne,
193
+ ...ie,
194
+ ...re
195
+ ].includes(t.account_type), P = le(t), { title: x, description: R } = se(t.account_type, i);
196
+ return /* @__PURE__ */ p(d, { bgcolor: "background.default", p: 24, children: [
197
+ /* @__PURE__ */ p(d, { gap: 12, children: [
198
+ /* @__PURE__ */ l(
199
+ G,
200
+ {
201
+ alt: i.institution_logo_alt,
202
+ institutionGuid: t.institution_guid || "",
203
+ size: 64
204
+ }
205
+ ),
206
+ /* @__PURE__ */ l(b, { variant: "body2", children: F?.name })
207
+ ] }),
208
+ /* @__PURE__ */ p(d, { gap: 8, mb: 24, mt: 4, children: [
209
+ /* @__PURE__ */ l(M, { children: P }),
210
+ /* @__PURE__ */ p(d, { direction: "row", justifyContent: "space-between", children: [
211
+ /* @__PURE__ */ l(b, { bold: f, variant: "body1", children: m }),
212
+ /* @__PURE__ */ l(b, { bold: !0, variant: "body1", children: _(c, "0,0.00") })
213
+ ] }),
214
+ /* @__PURE__ */ p(d, { direction: "row", justifyContent: "space-between", children: [
215
+ /* @__PURE__ */ l(b, { variant: "body2", children: N }),
216
+ /* @__PURE__ */ l(b, { variant: "body2", children: E })
217
+ ] })
218
+ ] }),
219
+ O && /* @__PURE__ */ l(d, { "aria-label": R, role: "img", children: a || /* @__PURE__ */ l(ue, { ChartComponent: e, header: x }) })
220
+ ] });
221
+ }, xe = v(me);
222
+ export {
223
+ xe as A,
224
+ I as a,
225
+ Oe as b,
226
+ Pe as g,
227
+ S as u
228
+ };
@@ -1,4 +1,4 @@
1
- import { A as e, C as u, E as p, e as y, M as d } from "./Account-BaJmiJAG.mjs";
1
+ import { c as e, C as u, E as p, P as y, M as d } from "./Account-DR7Plrqy.mjs";
2
2
  const m = (t) => t && (t.account_type === e.CREDIT_CARD || t.account_type === e.LOAN || t.account_type === e.MORTGAGE || t.account_type === e.LINE_OF_CREDIT || t.account_type === e.CHECKING_LINE_OF_CREDIT), I = (t) => t.is_manual || !t.guid, f = (t) => t.account_type === e.LINE_OF_CREDIT || t.account_type === e.CREDIT_CARD || t.account_type === e.CHECKING_LINE_OF_CREDIT, R = (t) => t.account_type === e.SAVINGS || t.account_type === e.CHECKING || t.account_type === e.LINE_OF_CREDIT || t.account_type === e.CREDIT_CARD || t.account_type === e.LOAN || t.account_type === e.MORTGAGE, A = (t) => t.account_type === e.LOAN || t.account_type === e.MORTGAGE, N = (t, n, s, _, a) => t.filter((i) => !(i.member_is_managed_by_user && _)).filter((i) => !(!i.member_is_managed_by_user && a)).sort(C).map((i) => {
3
3
  const r = n.find((c) => c.guid === i.institution_guid), o = s.find((c) => c.guid === i.member_guid);
4
4
  return E(i, r, o);
@@ -18,10 +18,10 @@ const m = (t) => t && (t.account_type === e.CREDIT_CARD || t.account_type === e.
18
18
  };
19
19
  }, C = (t, n) => t.account_type > n.account_type ? 1 : t.account_type < n.account_type ? -1 : (t.name || "") > (n.name || "") ? 1 : (t.name || "") < (n.name || "") ? -1 : 0;
20
20
  export {
21
- m as a,
21
+ I as a,
22
22
  f as b,
23
23
  A as c,
24
24
  N as d,
25
- I as i,
25
+ m as i,
26
26
  R as u
27
27
  };
@@ -75,6 +75,9 @@ const _ = {
75
75
  RECURRING_TRANSACTIONS_CLICK_UPCOMING: "recurring_transactions_widget_click_upcoming_transaction",
76
76
  RECURRING_TRANSACTIONS_DETAILS_CLICK_DELETE: "recurring_transactions_widget_details_click_delete",
77
77
  RECURRING_TRANSACTIONS_DETAILS_CLICK_PAYMENT_SCHEDULE: "recurring_transactions_widget_details_click_payment_schedule",
78
+ RECURRING_TRANSACTIONS_LIST_CLICK_MARK_AS_PAID: "recurring_transactions_widget_list_click_mark_as_paid",
79
+ RECURRING_TRANSACTIONS_LIST_CLICK_MARK_AS_UNPAID: "recurring_transactions_widget_list_click_mark_as_unpaid",
80
+ RECURRING_TRANSACTIONS_LIST_CLICK_MORE_MENU: "recurring_transactions_widget_list_click_more_menu",
78
81
  RECURRING_TRANSACTIONS_MICRO_WIDGET_CTA: "recurring_transactions_micro_widget_click_view_all_cta",
79
82
  SPENDING_CLICK_FILTER: "spending_widget_click_filter_accounts",
80
83
  SPENDING_VIEW: "spending",
@@ -0,0 +1,26 @@
1
+ import { jsx as r } from "react/jsx-runtime";
2
+ import n from "@mui/material/Avatar";
3
+ import { Icon as c } from "@mxenabled/mx-icons";
4
+ const h = ({
5
+ avatarSx: o,
6
+ bgColor: t,
7
+ name: i,
8
+ iconColor: a = "primary",
9
+ fill: e = !0,
10
+ sx: m
11
+ }) => /* @__PURE__ */ r(
12
+ n,
13
+ {
14
+ sx: {
15
+ bgcolor: t,
16
+ width: 32,
17
+ height: 32,
18
+ ...o
19
+ },
20
+ variant: "rounded",
21
+ children: /* @__PURE__ */ r(c, { color: a, fill: e, name: i, size: 20, sx: m })
22
+ }
23
+ );
24
+ export {
25
+ h as B
26
+ };
@@ -2,7 +2,7 @@ import { jsx as t, jsxs as g } from "react/jsx-runtime";
2
2
  import { observer as p } from "mobx-react-lite";
3
3
  import E from "react";
4
4
  import $ from "@mui/material/Stack";
5
- import { G as K, l as f, u as S, g as A, b as B } from "./hooks-BaO_gOI6.mjs";
5
+ import { G as K, l as f, u as S, f as A, a as B } from "./hooks-97sNJ_lf.mjs";
6
6
  import U from "@mui/material/List";
7
7
  import V from "@mui/material/Paper";
8
8
  import { b as _ } from "./Localization-DnoVyBNK.mjs";
@@ -0,0 +1,42 @@
1
+ import { jsx as t, jsxs as e } from "react/jsx-runtime";
2
+ import { observer as c } from "mobx-react-lite";
3
+ import i from "@mui/material/Box";
4
+ import s from "@mui/material/CircularProgress";
5
+ import a from "@mui/material/Stack";
6
+ import { Text as m } from "@mxenabled/mxui";
7
+ import { u as p } from "./hooks-97sNJ_lf.mjs";
8
+ const g = ({ status: r = o.Loading }) => {
9
+ const { connect: n } = p();
10
+ return /* @__PURE__ */ t(
11
+ i,
12
+ {
13
+ sx: {
14
+ height: "calc(100% - 62px)",
15
+ position: "absolute",
16
+ width: "100%"
17
+ },
18
+ children: /* @__PURE__ */ e(a, { alignItems: "center", direction: "column", justifyContent: "center", sx: { height: "100%" }, children: [
19
+ r === o.Loading && /* @__PURE__ */ t(s, { color: "primary", size: 48 }),
20
+ /* @__PURE__ */ t(
21
+ m,
22
+ {
23
+ sx: {
24
+ color: "grey.600",
25
+ marginTop: "16px"
26
+ },
27
+ children: r === o.Error ? n.oops : n.loading
28
+ }
29
+ )
30
+ ] })
31
+ }
32
+ );
33
+ }, E = c(g);
34
+ var o = /* @__PURE__ */ ((r) => (r.Loading = "loading", r.Error = "error", r))(o || {}), l = /* @__PURE__ */ ((r) => (r.Currency = "currency", r.Date = "date", r.Input = "input", r.Select = "select", r))(l || {});
35
+ const _ = "connect_widget", D = "connections_widget";
36
+ export {
37
+ D as C,
38
+ l as F,
39
+ o as M,
40
+ E as a,
41
+ _ as b
42
+ };
@@ -7,7 +7,7 @@ import p from "@mui/material/CardHeader";
7
7
  import C from "@mui/material/Stack";
8
8
  import { AccountBalance as f, ChevronRight as h } from "@mxenabled/mx-icons";
9
9
  import { Text as a } from "@mxenabled/mxui";
10
- import { C as x } from "./ConnectDrawer-Cnjr3Ddg.mjs";
10
+ import { C as x } from "./ConnectDrawer-DytyIhaF.mjs";
11
11
  const H = ({ description: i, label: e, title: c }) => {
12
12
  const [s, o] = n.useState(!1);
13
13
  return /* @__PURE__ */ r(n.Fragment, { children: [
@@ -3,15 +3,14 @@ import s from "react";
3
3
  import { observer as _ } from "mobx-react-lite";
4
4
  import { useTheme as g } from "@mui/material/styles";
5
5
  import { ConnectWidget as x } from "@mxenabled/web-widget-sdk";
6
- import { b as a, a as c } from "./Connect-Dk6GZEsA.mjs";
7
- import { M as i } from "./Accounts-CseLC3lL.mjs";
8
- import { d as D, e as L, u as w } from "./hooks-BaO_gOI6.mjs";
6
+ import { b as a, a as c, M as i } from "./Connect-BH0Pt6zc.mjs";
7
+ import { c as D, d as L, u as w } from "./hooks-97sNJ_lf.mjs";
9
8
  import { D as y } from "./Drawer-BXqqBMxg.mjs";
10
9
  const I = ({
11
10
  loadWidgetProps: l,
12
- onClose: m,
11
+ onClose: u,
13
12
  showConnectWidget: o,
14
- title: u
13
+ title: m
15
14
  }) => {
16
15
  let n;
17
16
  const { refreshAccounts: f } = D(), { loadWidget: d } = L(), { connect: p } = w(), [C, e] = s.useState(!1), [h, t] = s.useState(!1), {
@@ -43,16 +42,16 @@ const I = ({
43
42
  ariaLabelClose: p.close_manage_connection_aria,
44
43
  isOpen: o,
45
44
  onClose: () => {
46
- m(), f();
45
+ u(), f();
47
46
  },
48
- title: u,
47
+ title: m,
49
48
  children: /* @__PURE__ */ E("div", { id: a, children: [
50
49
  h && /* @__PURE__ */ r(c, { status: i.Error }),
51
50
  C && /* @__PURE__ */ r(c, { status: i.Loading })
52
51
  ] })
53
52
  }
54
53
  );
55
- }, $ = _(I);
54
+ }, O = _(I);
56
55
  export {
57
- $ as C
56
+ O as C
58
57
  };
@@ -3,17 +3,16 @@ import s from "react";
3
3
  import { observer as E } from "mobx-react-lite";
4
4
  import { useTheme as _ } from "@mui/material/styles";
5
5
  import { ConnectionsWidget as b } from "@mxenabled/web-widget-sdk";
6
- import { C as a, a as c } from "./Connect-Dk6GZEsA.mjs";
7
- import { M as i } from "./Accounts-CseLC3lL.mjs";
8
- import { d as D, e as L, u as w } from "./hooks-BaO_gOI6.mjs";
6
+ import { C as a, a as c, M as i } from "./Connect-BH0Pt6zc.mjs";
7
+ import { c as D, d as L, u as w } from "./hooks-97sNJ_lf.mjs";
9
8
  import { D as x } from "./Drawer-BXqqBMxg.mjs";
10
9
  const I = ({
11
10
  onClose: l,
12
11
  showConnectionsWidget: o,
13
- title: m
12
+ title: u
14
13
  }) => {
15
14
  let n;
16
- const { refreshAccounts: u } = D(), { loadWidget: f } = L(), { connect: d } = w(), p = _(), [C, e] = s.useState(!1), [S, t] = s.useState(!1);
15
+ const { refreshAccounts: m } = D(), { loadWidget: f } = L(), { connect: d } = w(), p = _(), [C, e] = s.useState(!1), [S, t] = s.useState(!1);
17
16
  return s.useEffect(() => (o ? (e(!0), f({ widget: "connections_widget", mode: p.palette.mode }).then((h) => {
18
17
  n = new b({
19
18
  container: `#${a}`,
@@ -39,16 +38,16 @@ const I = ({
39
38
  ariaLabelClose: d.close_connections_aria,
40
39
  isOpen: o,
41
40
  onClose: () => {
42
- l(), u();
41
+ l(), m();
43
42
  },
44
- title: m,
43
+ title: u,
45
44
  children: /* @__PURE__ */ g("div", { id: a, children: [
46
45
  S && /* @__PURE__ */ r(c, { status: i.Error }),
47
46
  C && /* @__PURE__ */ r(c, { status: i.Loading })
48
47
  ] })
49
48
  }
50
49
  );
51
- }, W = E(I);
50
+ }, M = E(I);
52
51
  export {
53
- W as C
52
+ M as C
54
53
  };
@@ -5,7 +5,7 @@ import { v4 as q } from "uuid";
5
5
  import { TextField as B, P as p } from "@mxenabled/mxui";
6
6
  import { g as L, C as O, f as y, M as C } from "./NumberFormatting--XMeeBfr.mjs";
7
7
  import { b as h, g as b } from "./Localization-DnoVyBNK.mjs";
8
- import { u as W } from "./hooks-BaO_gOI6.mjs";
8
+ import { u as W } from "./hooks-97sNJ_lf.mjs";
9
9
  const J = ({
10
10
  allowDecimals: o = !0,
11
11
  ariaLabel: g,
@@ -0,0 +1,74 @@
1
+ import { addMonths as i } from "date-fns/addMonths";
2
+ import { addQuarters as l } from "date-fns/addQuarters";
3
+ import { addWeeks as x } from "date-fns/addWeeks";
4
+ import { addYears as T } from "date-fns/addYears";
5
+ import { endOfMonth as h } from "date-fns/endOfMonth";
6
+ import { getDay as u } from "date-fns/getDay";
7
+ import { isBefore as n } from "date-fns/isBefore";
8
+ import { nextDay as p } from "date-fns/nextDay";
9
+ import { setDate as d } from "date-fns/setDate";
10
+ import { startOfToday as r } from "date-fns/startOfToday";
11
+ import { fromUnixTime as c } from "date-fns/fromUnixTime";
12
+ import { f as y, D as g } from "./DateFormats-HudZ3Bjs.mjs";
13
+ const F = (e) => {
14
+ const t = u(e);
15
+ let o = p(e, t);
16
+ for (; n(o, r()); )
17
+ o = x(o, 1);
18
+ return o;
19
+ }, Q = (e) => {
20
+ let t = e;
21
+ for (; n(t, r()); )
22
+ t = x(t, 2);
23
+ return t;
24
+ }, M = (e, t) => {
25
+ const o = r(), [a, D] = [e, t].sort((m, f) => m - f), s = (m, f) => f >= 28 ? h(m) : d(m, f);
26
+ return [
27
+ s(o, a),
28
+ s(o, D),
29
+ s(i(o, 1), a),
30
+ s(i(o, 1), D),
31
+ s(i(o, 2), a),
32
+ s(i(o, 2), D)
33
+ ];
34
+ }, H = (e, t) => {
35
+ const o = r(), a = M(e, t);
36
+ return a.find((D) => !n(D, o)) ?? a[a.length - 1];
37
+ }, R = (e) => {
38
+ let t = d(r(), e.getDate());
39
+ for (; n(t, r()); )
40
+ t = i(t, 1);
41
+ return t;
42
+ }, b = (e) => {
43
+ let t = e;
44
+ for (; n(t, r()); )
45
+ t = i(t, 2);
46
+ return t;
47
+ }, j = (e) => {
48
+ let t = l(e, 1);
49
+ for (; n(t, r()); )
50
+ t = l(t, 1);
51
+ return t;
52
+ }, I = (e) => {
53
+ let t = e;
54
+ for (; n(t, r()); )
55
+ t = l(t, 2);
56
+ return t;
57
+ }, K = (e) => T(e, 1), L = (e) => {
58
+ const t = c(e);
59
+ return new Date(t.getUTCFullYear(), t.getUTCMonth(), t.getUTCDate());
60
+ }, S = (e) => y(c(e), g.DAY_OF_WEEK_MONTH_DAY), q = (e) => e ? y(c(e), g.MONTH_YEAR) : "";
61
+ export {
62
+ I as a,
63
+ j as b,
64
+ b as c,
65
+ R as d,
66
+ H as e,
67
+ Q as f,
68
+ K as g,
69
+ F as h,
70
+ M as i,
71
+ L as j,
72
+ S as k,
73
+ q as l
74
+ };
@@ -1,9 +1,9 @@
1
1
  import { getDate as D } from "date-fns/getDate";
2
- import { addMonths as A } from "date-fns/addMonths";
2
+ import { addMonths as M } from "date-fns/addMonths";
3
3
  import { fromUnixTime as d } from "date-fns/fromUnixTime";
4
- import { getUnixTime as M } from "date-fns/getUnixTime";
4
+ import { getUnixTime as A } from "date-fns/getUnixTime";
5
5
  import { startOfMonth as I } from "date-fns/startOfMonth";
6
- import { A as w } from "./Account-BaJmiJAG.mjs";
6
+ import { c as w } from "./Account-DR7Plrqy.mjs";
7
7
  const H = 12, C = 100;
8
8
  var y = /* @__PURE__ */ ((t) => (t[t.FASTEST_PAYOFF_FIRST = 1] = "FASTEST_PAYOFF_FIRST", t[t.HIGHEST_INTEREST = 2] = "HIGHEST_INTEREST", t[t.LOWEST_BALANCE = 3] = "LOWEST_BALANCE", t[t.HIGHEST_BALANCE = 4] = "HIGHEST_BALANCE", t))(y || {});
9
9
  const N = {
@@ -119,8 +119,8 @@ const v = (t) => (t[t.length - 1] || {}).timestamp, L = (t, n) => {
119
119
  interest: e,
120
120
  payment: l,
121
121
  principal: l,
122
- timestamp: M(
123
- A(
122
+ timestamp: A(
123
+ M(
124
124
  d(s),
125
125
  // convert seconds → Date
126
126
  m + 1
@@ -133,7 +133,7 @@ const v = (t) => (t[t.length - 1] || {}).timestamp, L = (t, n) => {
133
133
  }
134
134
  const i = e / 1200;
135
135
  for (let m = 0; m < t; m++) {
136
- const r = M(A(d(s), m + 1)), _ = Math.pow(1 + i, m), l = n * _ - o * ((_ - 1) / i), p = Math.pow(1 + i, m + 1), c = n * p - o * ((p - 1) / i), u = o + Math.min(c, 0), b = l * i;
136
+ const r = A(M(d(s), m + 1)), _ = Math.pow(1 + i, m), l = n * _ - o * ((_ - 1) / i), p = Math.pow(1 + i, m + 1), c = n * p - o * ((p - 1) / i), u = o + Math.min(c, 0), b = l * i;
137
137
  a.push({
138
138
  balance: Math.max(0, c),
139
139
  interest: b,
@@ -10,18 +10,18 @@ import { observer as V } from "mobx-react-lite";
10
10
  import { useVirtualizer as at } from "@tanstack/react-virtual";
11
11
  import st from "@mui/material/Divider";
12
12
  import ct from "@mui/material/List";
13
- import { G as lt, h as G, u as z, g as dt, b as Tt } from "./hooks-BaO_gOI6.mjs";
13
+ import { G as lt, g as G, u as z, f as dt, a as Tt } from "./hooks-97sNJ_lf.mjs";
14
14
  import ht from "@mui/material/ListItemAvatar";
15
15
  import Ct from "@mui/material/ListItemText";
16
16
  import { useTheme as M } from "@mui/material/styles";
17
17
  import { f as H } from "./NumberFormatting--XMeeBfr.mjs";
18
- import { L as _t } from "./ListItemWrapper-B5r-YQQ_.mjs";
18
+ import { L as _t } from "./ListItemWrapper-BHIbqx7E.mjs";
19
19
  import { fromUnixTime as v } from "date-fns/fromUnixTime";
20
20
  import { isSameDay as F } from "date-fns/isSameDay";
21
21
  import { f as ut, D as pt } from "./DateFormats-HudZ3Bjs.mjs";
22
- import { i as mt } from "./DateUtil-Bhq59ZVg.mjs";
22
+ import { k as mt } from "./DateUtil-CzBmbjmA.mjs";
23
23
  import { L as Z } from "./Loader-CxeBwuPG.mjs";
24
- import { A as gt } from "./Analytics-CzGzz_sE.mjs";
24
+ import { A as gt } from "./Analytics-WeZYytR0.mjs";
25
25
  import At from "@mui/material/Tab";
26
26
  import Nt from "@mui/material/Tabs";
27
27
  import ft from "@mui/material/IconButton";
@@ -3,7 +3,7 @@ import c from "react";
3
3
  import { observer as g } from "mobx-react-lite";
4
4
  import { Stack as i, Box as f, Button as u, useTheme as y } from "@mui/material";
5
5
  import { Icon as C, Text as l } from "@mxenabled/mxui";
6
- import { G as b } from "./hooks-BaO_gOI6.mjs";
6
+ import { G as b } from "./hooks-97sNJ_lf.mjs";
7
7
  const m = c.forwardRef(
8
8
  (r, o) => {
9
9
  const n = y();
@@ -2,8 +2,8 @@ import { jsx as o } from "react/jsx-runtime";
2
2
  import { observer as c } from "mobx-react-lite";
3
3
  import { Icon as i } from "@mxenabled/mxui";
4
4
  import { e as p } from "./TransactionUtils-BphBJBbU.mjs";
5
- import { O as m } from "./EmbeddedCard-DPwJjqMH.mjs";
6
- import { g as x, h as _, u as C } from "./hooks-BaO_gOI6.mjs";
5
+ import { O as m } from "./EmbeddedCard-CQpbZrmP.mjs";
6
+ import { f as x, g as _, u as C } from "./hooks-97sNJ_lf.mjs";
7
7
  import { R as l } from "./ResponsiveButton-CC9F_Ezk.mjs";
8
8
  const v = ({ filter: t }) => {
9
9
  const { onEvent: r } = x(), { tags: e, sortedTransactions: s } = _(), { transactions: n } = C(), a = () => {