@mx-cartographer/experiences 6.2.1 → 6.2.3-alpha.al0
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.
- package/CHANGELOG.md +4 -0
- package/dist/common/types/Notification.d.ts +2 -1
- package/dist/index.es.js +159 -152
- package/dist/index.es.js.map +1 -1
- package/package.json +1 -1
package/dist/index.es.js
CHANGED
@@ -24,7 +24,7 @@ import { Honeybadger as Pi } from "@honeybadger-io/react";
|
|
24
24
|
import zr from "numeral";
|
25
25
|
import ee from "@mui/material/Button";
|
26
26
|
import oi from "@mui/material/Tooltip";
|
27
|
-
import
|
27
|
+
import Ye from "@mui/material/IconButton";
|
28
28
|
import Xa from "@mui/material/FormControlLabel";
|
29
29
|
import q from "@mui/material/ListItem";
|
30
30
|
import de from "@mui/material/ListItemButton";
|
@@ -1447,7 +1447,7 @@ const iu = (e, n) => {
|
|
1447
1447
|
};
|
1448
1448
|
return /* @__PURE__ */ l(M, { className: "mx-cmn-account-filter", m: 4, sx: { ...s }, children: [
|
1449
1449
|
d ? /* @__PURE__ */ t(oi, { id: "filter-accounts", placement: "bottom", title: n.title, children: /* @__PURE__ */ t(
|
1450
|
-
|
1450
|
+
Ye,
|
1451
1451
|
{
|
1452
1452
|
"aria-controls": "filter_accounts",
|
1453
1453
|
"aria-describedby": "filter-accounts",
|
@@ -2253,13 +2253,13 @@ const bu = ({
|
|
2253
2253
|
if (!n)
|
2254
2254
|
throw new Error(`${e}() must be used within the GlobalDataContext`);
|
2255
2255
|
return n;
|
2256
|
-
}, Re = () => Ze("useAccountStore").globalStore.accountStore, Ca = () => Ze("useAppConfig").globalStore.appDataStore.appConfig, yr = () => Ze("useAnalyticsStore").globalStore.analyticsStore, lt = () => Ze("useBudgetsStore").globalStore.budgetsStore, Er = () => Ze("useCashflowStore").globalStore.cashflowStore,
|
2256
|
+
}, Re = () => Ze("useAccountStore").globalStore.accountStore, Ca = () => Ze("useAppConfig").globalStore.appDataStore.appConfig, yr = () => Ze("useAnalyticsStore").globalStore.analyticsStore, lt = () => Ze("useBudgetsStore").globalStore.budgetsStore, Er = () => Ze("useCashflowStore").globalStore.cashflowStore, Ve = () => Ze("useCategoryStore").globalStore.categoryStore, js = () => Ze("useConnectStore").globalStore.connectStore, fa = () => Ze("useDebtsStore").globalStore.debtsStore, ba = () => Ze("useGlobalStore").globalStore, ce = () => Ze("useGlobalUiStore").globalStore.globalUiStore, I = () => Ze("globalCopyStore").globalStore.copyStore.copy, ot = () => Ze("useGoalStore").globalStore.goalStore, Sr = () => Ze("useHelpStore").globalStore.helpStore, Ja = () => Ze("useHoldingStore").globalStore.holdingStore, Nu = () => Ze("useMerchantStore").globalStore.merchantStore, Du = () => Ze("useNetWorthStore").globalStore.netWorthStore, Xs = () => Ze("useNotificationStore").globalStore.notificationStore, tt = () => Ze("useRecurringActivityStore").globalStore.recurringActivityStore, Pt = () => Ze("useRecurringTransactionsStore").globalStore.recurringTransactionsStore, Ht = () => Ze("useSettingsStore").globalStore.settingsStore, Se = () => Ze("useTransactionStore").globalStore.transactionStore, dn = () => Ze("useUserStore").globalStore.userStore, z = () => ({ onEvent: Ze().onEvent }), dE = () => ({ onPageView: Ze().onPageView }), Ru = (e = "useWidgetContainerContext") => {
|
2257
2257
|
const n = g.useContext(zs);
|
2258
2258
|
if (!n)
|
2259
2259
|
throw new Error(`${e}() must be used within the WidgetContainerContext`);
|
2260
2260
|
return n;
|
2261
2261
|
}, $n = () => Ru(), qs = ({ categoryGuid: e, topLevelCategoryGuid: n }) => {
|
2262
|
-
const { categories: i } = I(), { getCategoryName: a } =
|
2262
|
+
const { categories: i } = I(), { getCategoryName: a } = Ve(), r = a(e);
|
2263
2263
|
return /* @__PURE__ */ l(b, { alignItems: "center", direction: "column", gap: "8", justifyContent: "center", mb: 4, children: [
|
2264
2264
|
/* @__PURE__ */ t(
|
2265
2265
|
M,
|
@@ -2272,7 +2272,7 @@ const bu = ({
|
|
2272
2272
|
),
|
2273
2273
|
/* @__PURE__ */ t(p, { variant: "Body", children: r })
|
2274
2274
|
] });
|
2275
|
-
},
|
2275
|
+
}, ze = ({
|
2276
2276
|
isIncome: e = !1,
|
2277
2277
|
amount: n = 0,
|
2278
2278
|
bold: i,
|
@@ -2317,7 +2317,7 @@ const bu = ({
|
|
2317
2317
|
/* @__PURE__ */ l(M, { alignItems: "center", display: "flex", flexDirection: "column", children: [
|
2318
2318
|
/* @__PURE__ */ t(qs, { categoryGuid: e, topLevelCategoryGuid: n }),
|
2319
2319
|
/* @__PURE__ */ t(p, { variant: "Small", children: `${i.length}-month total` }),
|
2320
|
-
/* @__PURE__ */ t(
|
2320
|
+
/* @__PURE__ */ t(ze, { amount: _, bold: !0, formatString: "0,0", variant: "body2" })
|
2321
2321
|
] }),
|
2322
2322
|
/* @__PURE__ */ t(G, { sx: { my: 16, width: "100%" } }),
|
2323
2323
|
/* @__PURE__ */ t(Je, { container: !0, children: i.map((u, h) => /* @__PURE__ */ l(g.Fragment, { children: [
|
@@ -2325,7 +2325,7 @@ const bu = ({
|
|
2325
2325
|
/* @__PURE__ */ t(Je, { item: !0, xs: 4, children: /* @__PURE__ */ l(M, { alignItems: "center", display: "flex", flexDirection: "column", children: [
|
2326
2326
|
/* @__PURE__ */ t(p, { color: o.palette.text.secondary, variant: "XSmall", children: u.x }),
|
2327
2327
|
/* @__PURE__ */ t(
|
2328
|
-
|
2328
|
+
ze,
|
2329
2329
|
{
|
2330
2330
|
amount: u.y,
|
2331
2331
|
bold: !0,
|
@@ -2348,7 +2348,7 @@ const bu = ({
|
|
2348
2348
|
return s === void 0 || !c ? null : /* @__PURE__ */ t(ia, { sx: { pt: 4, px: 8 }, children: /* @__PURE__ */ t(gl, { children: /* @__PURE__ */ l(nn, { alignItems: "center", display: "flex", flexDirection: "column", children: [
|
2349
2349
|
/* @__PURE__ */ t(qs, { categoryGuid: e, topLevelCategoryGuid: n }),
|
2350
2350
|
/* @__PURE__ */ t(p, { color: o.palette.text.secondary, variant: "Small", children: ie(c, te.MONTH_SHORT_YEAR) }),
|
2351
|
-
/* @__PURE__ */ t(
|
2351
|
+
/* @__PURE__ */ t(ze, { amount: String(s), bold: !0, formatString: "0,0", variant: "Body" })
|
2352
2352
|
] }) }) });
|
2353
2353
|
}, ku = ({
|
2354
2354
|
sx: e,
|
@@ -2357,7 +2357,7 @@ const bu = ({
|
|
2357
2357
|
onHoverLegend: a,
|
2358
2358
|
onClickLegend: r
|
2359
2359
|
}) => {
|
2360
|
-
const { isMobile: o } = De(), { getCategoryName: s } =
|
2360
|
+
const { isMobile: o } = De(), { getCategoryName: s } = Ve();
|
2361
2361
|
return /* @__PURE__ */ t(b, { direction: "row", flexWrap: "wrap", gap: o ? 2 : 6, justifyContent: "start", sx: e, children: n.map(({ guid: c, top_level_guid: d }) => {
|
2362
2362
|
const _ = i === c, u = kn[c], h = kn[d], m = u ?? h ?? kn.default, C = m + "33";
|
2363
2363
|
return /* @__PURE__ */ l(
|
@@ -2454,9 +2454,9 @@ const bu = ({
|
|
2454
2454
|
};
|
2455
2455
|
}, he = (se) => {
|
2456
2456
|
m(se), i?.(se ?? "");
|
2457
|
-
},
|
2457
|
+
}, Ke = (se) => {
|
2458
2458
|
a?.(se ?? "");
|
2459
|
-
},
|
2459
|
+
}, je = () => {
|
2460
2460
|
const se = He(String(E)).guid;
|
2461
2461
|
se && a?.(se);
|
2462
2462
|
}, Te = (se) => {
|
@@ -2530,7 +2530,7 @@ const bu = ({
|
|
2530
2530
|
{
|
2531
2531
|
height: s || 400,
|
2532
2532
|
margin: { bottom: 50 },
|
2533
|
-
onAreaClick:
|
2533
|
+
onAreaClick: je,
|
2534
2534
|
onHighlightChange: Te,
|
2535
2535
|
series: ge,
|
2536
2536
|
skipAnimation: !0,
|
@@ -2576,7 +2576,7 @@ const bu = ({
|
|
2576
2576
|
{
|
2577
2577
|
categoryGuids: _e,
|
2578
2578
|
hoveredLegend: h,
|
2579
|
-
onClickLegend:
|
2579
|
+
onClickLegend: Ke,
|
2580
2580
|
onHoverLegend: he,
|
2581
2581
|
sx: { px: _ ? 0 : 24 }
|
2582
2582
|
}
|
@@ -2706,7 +2706,7 @@ const bu = ({
|
|
2706
2706
|
padding: "8px 8px 8px 8px"
|
2707
2707
|
},
|
2708
2708
|
children: [
|
2709
|
-
/* @__PURE__ */ t(
|
2709
|
+
/* @__PURE__ */ t(Ye, { "aria-label": e, color: "primary", onClick: n, children: /* @__PURE__ */ t(Fl, { color: "primary", sx: { fontSize: 22 } }) }),
|
2710
2710
|
/* @__PURE__ */ t(
|
2711
2711
|
M,
|
2712
2712
|
{
|
@@ -2840,7 +2840,7 @@ const bu = ({
|
|
2840
2840
|
sx: { display: { xs: r ? "inline-flex" : "none", sm: "none" } },
|
2841
2841
|
title: o,
|
2842
2842
|
children: /* @__PURE__ */ t(
|
2843
|
-
|
2843
|
+
Ye,
|
2844
2844
|
{
|
2845
2845
|
"aria-describedby": "select-date",
|
2846
2846
|
"aria-label": "Select a date",
|
@@ -3203,7 +3203,7 @@ const Dn = ({
|
|
3203
3203
|
/* @__PURE__ */ t(
|
3204
3204
|
wn,
|
3205
3205
|
{
|
3206
|
-
action: a ? /* @__PURE__ */ t(
|
3206
|
+
action: a ? /* @__PURE__ */ t(Ye, { "aria-label": n, onClick: a, children: /* @__PURE__ */ t(wt, { name: "close", size: 24 }) }) : r && /* @__PURE__ */ t(
|
3207
3207
|
ee,
|
3208
3208
|
{
|
3209
3209
|
endIcon: /* @__PURE__ */ t(wt, { name: "keyboard_arrow_right_rounded" }),
|
@@ -3334,7 +3334,7 @@ const Dn = ({
|
|
3334
3334
|
children: he
|
3335
3335
|
},
|
3336
3336
|
_e
|
3337
|
-
) : /* @__PURE__ */ t(
|
3337
|
+
) : /* @__PURE__ */ t(Ye, { "aria-label": he, color: "primary", onClick: He, children: /* @__PURE__ */ t(P, { name: _e }) }, _e) : T || x ? /* @__PURE__ */ t(
|
3338
3338
|
ee,
|
3339
3339
|
{
|
3340
3340
|
onClick: He,
|
@@ -3343,7 +3343,7 @@ const Dn = ({
|
|
3343
3343
|
children: he
|
3344
3344
|
},
|
3345
3345
|
_e
|
3346
|
-
) : /* @__PURE__ */ t(
|
3346
|
+
) : /* @__PURE__ */ t(Ye, { "aria-label": he, color: "primary", onClick: He, children: /* @__PURE__ */ t(P, { name: _e }) }, _e);
|
3347
3347
|
})
|
3348
3348
|
] }),
|
3349
3349
|
sx: {
|
@@ -3359,7 +3359,7 @@ const Dn = ({
|
|
3359
3359
|
},
|
3360
3360
|
title: T || x ? /* @__PURE__ */ t(cn, { children: m }) : /* @__PURE__ */ l(b, { alignItems: "center", flexDirection: "row", children: [
|
3361
3361
|
N && d && /* @__PURE__ */ t(
|
3362
|
-
|
3362
|
+
Ye,
|
3363
3363
|
{
|
3364
3364
|
"aria-label": L.back_to_dashboard,
|
3365
3365
|
onClick: U,
|
@@ -3562,7 +3562,7 @@ const po = "connect_widget", Co = "connections_widget", Wu = ({
|
|
3562
3562
|
placement: a,
|
3563
3563
|
sx: { display: { xs: "inline-flex", lg: "none" } },
|
3564
3564
|
title: r,
|
3565
|
-
children: /* @__PURE__ */ t(
|
3565
|
+
children: /* @__PURE__ */ t(Ye, { onClick: i, children: e })
|
3566
3566
|
}
|
3567
3567
|
)
|
3568
3568
|
] });
|
@@ -3574,7 +3574,7 @@ const po = "connect_widget", Co = "connections_widget", Wu = ({
|
|
3574
3574
|
searchValue: r
|
3575
3575
|
}) => {
|
3576
3576
|
const o = ft(), s = /* @__PURE__ */ t(
|
3577
|
-
|
3577
|
+
Ye,
|
3578
3578
|
{
|
3579
3579
|
"aria-label": n,
|
3580
3580
|
className: "mx-cat-cancel-search-button",
|
@@ -3714,7 +3714,7 @@ const po = "connect_widget", Co = "connections_widget", Wu = ({
|
|
3714
3714
|
/* @__PURE__ */ t(p, { sx: { whiteSpace: "unset" }, variant: "Small", children: e })
|
3715
3715
|
] }),
|
3716
3716
|
children: /* @__PURE__ */ t(
|
3717
|
-
|
3717
|
+
Ye,
|
3718
3718
|
{
|
3719
3719
|
"aria-label": i,
|
3720
3720
|
sx: {
|
@@ -4331,7 +4331,7 @@ const li = () => {
|
|
4331
4331
|
}
|
4332
4332
|
),
|
4333
4333
|
/* @__PURE__ */ t(p, { bold: !0, sx: { flexGrow: 1, fontSize: 12 }, children: n.remaining_cash }),
|
4334
|
-
/* @__PURE__ */ t(
|
4334
|
+
/* @__PURE__ */ t(ze, { amount: e, bold: !0, sx: { fontSize: 12 } })
|
4335
4335
|
] });
|
4336
4336
|
}, Tr = A(t_), n_ = ({ onAddIncomeClick: e }) => {
|
4337
4337
|
const n = pe(), { availableWidth: i } = $n(), { isMobile: a } = De(), { visibleCashAccounts: r, visibleCashBalance: o } = Re(), { selectedAccountGuids: s } = ce(), { cashflow: c } = I(), { userProfile: d } = dn(), {
|
@@ -4369,7 +4369,7 @@ const li = () => {
|
|
4369
4369
|
px: 24,
|
4370
4370
|
children: [
|
4371
4371
|
/* @__PURE__ */ l(b, { pb: 14, pt: 12, children: [
|
4372
|
-
/* @__PURE__ */ t(
|
4372
|
+
/* @__PURE__ */ t(ze, { amount: w, variant: "H2" }),
|
4373
4373
|
/* @__PURE__ */ t(Le, { variant: "XSmall", whiteSpace: "nowrap", children: S(
|
4374
4374
|
c.total_cash_accounts,
|
4375
4375
|
h.length
|
@@ -4377,12 +4377,12 @@ const li = () => {
|
|
4377
4377
|
] }),
|
4378
4378
|
/* @__PURE__ */ t(b, { pt: 18, children: /* @__PURE__ */ t(P, { name: "remove" }) }),
|
4379
4379
|
/* @__PURE__ */ l(b, { pb: 14, pt: 12, children: [
|
4380
|
-
/* @__PURE__ */ t(
|
4380
|
+
/* @__PURE__ */ t(ze, { amount: N, variant: "H2" }),
|
4381
4381
|
/* @__PURE__ */ t(Le, { variant: "XSmall", whiteSpace: "nowrap", children: S(c.expenses_due, u.length) })
|
4382
4382
|
] }),
|
4383
4383
|
/* @__PURE__ */ t(b, { pt: 18, children: /* @__PURE__ */ t(P, { name: "equals" }) }),
|
4384
4384
|
/* @__PURE__ */ l(b, { pb: 14, pr: 24, pt: 12, children: [
|
4385
|
-
/* @__PURE__ */ t(
|
4385
|
+
/* @__PURE__ */ t(ze, { amount: x, variant: "H2" }),
|
4386
4386
|
/* @__PURE__ */ l(b, { alignItems: "center", direction: "row", gap: 8, children: [
|
4387
4387
|
/* @__PURE__ */ t(Le, { variant: "XSmall", whiteSpace: "nowrap", children: c.available_to_spend }),
|
4388
4388
|
/* @__PURE__ */ t(Qi, { body: c.tooltip_body, title: c.tooltip_title })
|
@@ -4408,12 +4408,12 @@ const li = () => {
|
|
4408
4408
|
c.total_cash_accounts,
|
4409
4409
|
h.length
|
4410
4410
|
) }),
|
4411
|
-
/* @__PURE__ */ t(
|
4411
|
+
/* @__PURE__ */ t(ze, { amount: o, bold: !0, variant: "XSmall" })
|
4412
4412
|
] }),
|
4413
4413
|
/* @__PURE__ */ t(G, {}),
|
4414
4414
|
/* @__PURE__ */ l(b, { direction: "row", justifyContent: "space-between", p: 16, children: [
|
4415
4415
|
/* @__PURE__ */ t(p, { variant: "Small", children: S(c.expenses_due, u.length) }),
|
4416
|
-
/* @__PURE__ */ t(
|
4416
|
+
/* @__PURE__ */ t(ze, { amount: N, bold: !0, symbol: "-", variant: "XSmall" })
|
4417
4417
|
] }),
|
4418
4418
|
/* @__PURE__ */ t(G, {}),
|
4419
4419
|
/* @__PURE__ */ t(
|
@@ -4943,7 +4943,7 @@ const r_ = [
|
|
4943
4943
|
const i = e.toLowerCase().split(" "), a = n?.toString().toLowerCase() ?? "";
|
4944
4944
|
return i.every((r) => a.indexOf(r) > -1);
|
4945
4945
|
};
|
4946
|
-
var Qe = /* @__PURE__ */ ((e) => (e[e.Expense = 0] = "Expense", e[e.Income = 1] = "Income", e))(Qe || {}), et = /* @__PURE__ */ ((e) => (e[e.Paid = 0] = "Paid", e[e.Missed = 1] = "Missed", e[e.Upcoming = 2] = "Upcoming", e))(et || {}), h_ = /* @__PURE__ */ ((e) => (e[e.UNKNOWN = 0] = "UNKNOWN", e[e.CORRECT = 1] = "CORRECT", e[e.INCORRECT = 2] = "INCORRECT", e))(h_ || {}), g_ = /* @__PURE__ */ ((e) => (e.Missed = "Missed", e.Paid = "Paid", e.Upcoming = "Upcoming expense", e.Income = "Income", e))(g_ || {}), m_ = /* @__PURE__ */ ((e) => (e[e.Unknown = 0] = "Unknown", e[e.Subscription = 1] = "Subscription", e[e.Bill = 2] = "Bill", e))(m_ || {}), K = /* @__PURE__ */ ((e) => (e[e.DEBT_TRACK = 1] = "DEBT_TRACK", e[e.SAVINGS_TRACK = 2] = "SAVINGS_TRACK", e[e.RETIREMENT_TRACK = 3] = "RETIREMENT_TRACK", e[e.EMERGENCY_FUND_TRACK = 4] = "EMERGENCY_FUND_TRACK", e))(K || {}), ir = /* @__PURE__ */ ((e) => (e[e.SAVE_AMOUNT = 1] = "SAVE_AMOUNT", e[e.KEEP_BALANCE_BELOW = 2] = "KEEP_BALANCE_BELOW", e[e.KEEP_BALANCE_ABOVE = 3] = "KEEP_BALANCE_ABOVE", e[e.ACTION = 4] = "ACTION", e))(ir || {}), xt = /* @__PURE__ */ ((e) => (e[e.AUTOMOBILE = 1] = "AUTOMOBILE", e[e.COLLEGE = 2] = "COLLEGE", e[e.HOUSE = 3] = "HOUSE", e[e.RECREATIONAL_VEHICLE = 4] = "RECREATIONAL_VEHICLE", e[e.VACATION = 5] = "VACATION", e[e.ELECTRONIC = 6] = "ELECTRONIC", e[e.OTHER = 7] = "OTHER", e[e.RETIREMENT = 8] = "RETIREMENT", e[e.EMERGENCY_FUND = 9] = "EMERGENCY_FUND", e[e.SETUP_BUDGETS = 10] = "SETUP_BUDGETS", e[e.START_MONEY_MANAGEMENT = 11] = "START_MONEY_MANAGEMENT", e[e.CREDIT_CARD = 12] = "CREDIT_CARD", e[e.LINE_OF_CREDIT = 13] = "LINE_OF_CREDIT", e[e.LOANS = 14] = "LOANS", e))(xt || {}),
|
4946
|
+
var Qe = /* @__PURE__ */ ((e) => (e[e.Expense = 0] = "Expense", e[e.Income = 1] = "Income", e))(Qe || {}), et = /* @__PURE__ */ ((e) => (e[e.Paid = 0] = "Paid", e[e.Missed = 1] = "Missed", e[e.Upcoming = 2] = "Upcoming", e))(et || {}), h_ = /* @__PURE__ */ ((e) => (e[e.UNKNOWN = 0] = "UNKNOWN", e[e.CORRECT = 1] = "CORRECT", e[e.INCORRECT = 2] = "INCORRECT", e))(h_ || {}), g_ = /* @__PURE__ */ ((e) => (e.Missed = "Missed", e.Paid = "Paid", e.Upcoming = "Upcoming expense", e.Income = "Income", e))(g_ || {}), m_ = /* @__PURE__ */ ((e) => (e[e.Unknown = 0] = "Unknown", e[e.Subscription = 1] = "Subscription", e[e.Bill = 2] = "Bill", e))(m_ || {}), K = /* @__PURE__ */ ((e) => (e[e.DEBT_TRACK = 1] = "DEBT_TRACK", e[e.SAVINGS_TRACK = 2] = "SAVINGS_TRACK", e[e.RETIREMENT_TRACK = 3] = "RETIREMENT_TRACK", e[e.EMERGENCY_FUND_TRACK = 4] = "EMERGENCY_FUND_TRACK", e))(K || {}), ir = /* @__PURE__ */ ((e) => (e[e.SAVE_AMOUNT = 1] = "SAVE_AMOUNT", e[e.KEEP_BALANCE_BELOW = 2] = "KEEP_BALANCE_BELOW", e[e.KEEP_BALANCE_ABOVE = 3] = "KEEP_BALANCE_ABOVE", e[e.ACTION = 4] = "ACTION", e))(ir || {}), xt = /* @__PURE__ */ ((e) => (e[e.AUTOMOBILE = 1] = "AUTOMOBILE", e[e.COLLEGE = 2] = "COLLEGE", e[e.HOUSE = 3] = "HOUSE", e[e.RECREATIONAL_VEHICLE = 4] = "RECREATIONAL_VEHICLE", e[e.VACATION = 5] = "VACATION", e[e.ELECTRONIC = 6] = "ELECTRONIC", e[e.OTHER = 7] = "OTHER", e[e.RETIREMENT = 8] = "RETIREMENT", e[e.EMERGENCY_FUND = 9] = "EMERGENCY_FUND", e[e.SETUP_BUDGETS = 10] = "SETUP_BUDGETS", e[e.START_MONEY_MANAGEMENT = 11] = "START_MONEY_MANAGEMENT", e[e.CREDIT_CARD = 12] = "CREDIT_CARD", e[e.LINE_OF_CREDIT = 13] = "LINE_OF_CREDIT", e[e.LOANS = 14] = "LOANS", e))(xt || {}), Ue = /* @__PURE__ */ ((e) => (e[e.BudgetExceeded = 1] = "BudgetExceeded", e[e.BudgetOffTarget = 2] = "BudgetOffTarget", e[e.DebtPaymentReminder = 3] = "DebtPaymentReminder", e[e.AccountBalanceLow = 6] = "AccountBalanceLow", e[e.AccountDepositLarge = 7] = "AccountDepositLarge", e[e.TransactionExpenseLarge = 8] = "TransactionExpenseLarge", e[e.TransactionFeeCharge = 9] = "TransactionFeeCharge", e[e.InternationalTransaction = 23] = "InternationalTransaction", e[e.AccountDepositLargePosted = 48] = "AccountDepositLargePosted", e))(Ue || {}), Et = /* @__PURE__ */ ((e) => (e[e.CREDIT = 1] = "CREDIT", e[e.DEBIT = 2] = "DEBIT", e))(Et || {}), Ar = /* @__PURE__ */ ((e) => (e[e.POSTED = 1] = "POSTED", e[e.PENDING = 2] = "PENDING", e))(Ar || {}), p_ = /* @__PURE__ */ ((e) => (e.Desktop = "Desktop", e.Mobile = "Mobile", e))(p_ || {}), we = /* @__PURE__ */ ((e) => (e[e.Unknown = 0] = "Unknown", e[e.EveryWeek = 1] = "EveryWeek", e[e.EveryOtherWeek = 2] = "EveryOtherWeek", e[e.EveryMonth = 3] = "EveryMonth", e[e.EveryOtherMonth = 4] = "EveryOtherMonth", e[e.EveryQuarter = 5] = "EveryQuarter", e[e.EveryOtherQuarter = 6] = "EveryOtherQuarter", e[e.EveryYear = 7] = "EveryYear", e))(we || {}), it = /* @__PURE__ */ ((e) => (e[e.Paid = 0] = "Paid", e[e.Missed = 1] = "Missed", e[e.Upcoming = 2] = "Upcoming", e))(it || {}), Yt = /* @__PURE__ */ ((e) => (e[e.Expense = 0] = "Expense", e[e.Income = 1] = "Income", e))(Yt || {}), on = /* @__PURE__ */ ((e) => (e[e.Unknown = 0] = "Unknown", e[e.Subscription = 1] = "Subscription", e[e.Bill = 2] = "Bill", e[e.Income = 3] = "Income", e[e.Transfer = 4] = "Transfer", e))(on || {});
|
4947
4947
|
const tc = {
|
4948
4948
|
account_guid: "",
|
4949
4949
|
amount: 0,
|
@@ -5523,7 +5523,7 @@ const At = () => {
|
|
5523
5523
|
}, B_ = A(G_), pn = () => {
|
5524
5524
|
if (!g.useContext(zn))
|
5525
5525
|
throw new Error("useCategoryUiStore() must be used within the GlobalDataContext");
|
5526
|
-
return
|
5526
|
+
return Ve().uiStore;
|
5527
5527
|
}, qt = {
|
5528
5528
|
ON_CATEGORY_EXPANDED: "onCategoryExpanded",
|
5529
5529
|
ON_CATEGORY_COLLAPSED: "onCategoryCollapsed",
|
@@ -5590,7 +5590,7 @@ const P_ = ({
|
|
5590
5590
|
}
|
5591
5591
|
);
|
5592
5592
|
}, Ir = A(P_), H_ = ({ parentCategory: e }) => {
|
5593
|
-
const [n, i] = g.useState(!1), { addCategory: a } =
|
5593
|
+
const [n, i] = g.useState(!1), { addCategory: a } = Ve(), { categories: r } = I(), { onEvent: o } = z(), { setShouldDisableDrawerScroll: s } = pn(), c = async (u) => {
|
5594
5594
|
await a(u.trim(), e.guid), o(qt.ON_SUBCATEGORY_ADDED), i(!1);
|
5595
5595
|
}, d = async () => {
|
5596
5596
|
o(qt.ON_SUBCATEGORY_ADD_CLICK), s(!0), i(!0);
|
@@ -5620,7 +5620,7 @@ const P_ = ({
|
|
5620
5620
|
subCategory: n,
|
5621
5621
|
showRename: i
|
5622
5622
|
}) => {
|
5623
|
-
const { updateCategory: a } =
|
5623
|
+
const { updateCategory: a } = Ve(), { onEvent: r } = z(), o = async (c) => {
|
5624
5624
|
await a({ ...n, name: c }), r(qt.ON_SUBCATEGORY_SAVED), e(!1);
|
5625
5625
|
}, s = () => {
|
5626
5626
|
e(!1), r(qt.ON_SUBCATEGORY_EDIT_CANCEL_CLICK);
|
@@ -5641,7 +5641,7 @@ const P_ = ({
|
|
5641
5641
|
setShowDelete: i,
|
5642
5642
|
subCategory: a
|
5643
5643
|
}) => {
|
5644
|
-
const { onEvent: r } = z(), { removeCategory: o } =
|
5644
|
+
const { onEvent: r } = z(), { removeCategory: o } = Ve(), s = () => {
|
5645
5645
|
i(!1), r(qt.ON_SUBCATEGORY_DELETE_CLICK);
|
5646
5646
|
}, c = async () => {
|
5647
5647
|
r(qt.ON_SUBCATEGORY_DELETED), await o(a.guid), i(!1);
|
@@ -5698,7 +5698,7 @@ const P_ = ({
|
|
5698
5698
|
),
|
5699
5699
|
E && /* @__PURE__ */ l(M, { className: "mx-cat-subcategory-edit-container", sx: { marginRight: 24 }, children: [
|
5700
5700
|
/* @__PURE__ */ t(
|
5701
|
-
|
5701
|
+
Ye,
|
5702
5702
|
{
|
5703
5703
|
"aria-label": S(_.edit_subcategory_aria, n.name),
|
5704
5704
|
onClick: () => {
|
@@ -5708,7 +5708,7 @@ const P_ = ({
|
|
5708
5708
|
}
|
5709
5709
|
),
|
5710
5710
|
/* @__PURE__ */ t(
|
5711
|
-
|
5711
|
+
Ye,
|
5712
5712
|
{
|
5713
5713
|
"aria-label": S(_.delete_subcategory_aria, n.name),
|
5714
5714
|
edge: "end",
|
@@ -5797,7 +5797,7 @@ const P_ = ({
|
|
5797
5797
|
/* @__PURE__ */ t(j_, { categories: n, parentCategory: e })
|
5798
5798
|
] });
|
5799
5799
|
}, ic = A(X_), q_ = () => {
|
5800
|
-
const { categories: e } =
|
5800
|
+
const { categories: e } = Ve(), { searchValue: n } = pn(), { categories: i } = I(), r = ((o, s = "") => o.reduce((c, d) => {
|
5801
5801
|
if (d.parent_guid === null) {
|
5802
5802
|
const u = [
|
5803
5803
|
{
|
@@ -5829,7 +5829,7 @@ const P_ = ({
|
|
5829
5829
|
unselectable: a = [],
|
5830
5830
|
unselectableText: r = "Unselectable"
|
5831
5831
|
}) => {
|
5832
|
-
const { categories: o, loadCategories: s } =
|
5832
|
+
const { categories: o, loadCategories: s } = Ve(), { common: c } = I(), { isCopyLoaded: d } = ce(), {
|
5833
5833
|
searchValue: _,
|
5834
5834
|
setOnSelect: u,
|
5835
5835
|
setSearchValue: h,
|
@@ -6073,7 +6073,7 @@ class ah {
|
|
6073
6073
|
getCategoryName = (n) => this.categories.find((a) => a.guid === n)?.name ?? ga[n];
|
6074
6074
|
}
|
6075
6075
|
const rc = ({ transaction: e }) => {
|
6076
|
-
const { addOrUpdateTransactionRule: n, updateTransaction: i } = Se(), { categories: a } =
|
6076
|
+
const { addOrUpdateTransactionRule: n, updateTransaction: i } = Se(), { categories: a } = Ve(), { onEvent: r } = z(), { setShouldDisableDrawerScroll: o, updateManualTransaction: s } = At(), { transactions: c } = I(), [d, _] = g.useState(!1), [u, h] = g.useState(""), m = async (y) => {
|
6077
6077
|
await i({ ...e, category_guid: u }), y && await n(u, e), h(""), r(W.TRANSACTION_DETAILS_CLICK_CATEGORY, {
|
6078
6078
|
transaction_guid: e.guid
|
6079
6079
|
});
|
@@ -6512,7 +6512,7 @@ const rc = ({ transaction: e }) => {
|
|
6512
6512
|
}
|
6513
6513
|
),
|
6514
6514
|
/* @__PURE__ */ t(
|
6515
|
-
|
6515
|
+
Ye,
|
6516
6516
|
{
|
6517
6517
|
"aria-label": c.split_transaction_delete_split_btn,
|
6518
6518
|
color: "secondary",
|
@@ -6607,7 +6607,7 @@ const rc = ({ transaction: e }) => {
|
|
6607
6607
|
) })
|
6608
6608
|
] });
|
6609
6609
|
}, mh = A(gh), ph = ({ transaction: e }) => {
|
6610
|
-
const { onEvent: n } = z(), { splitTransaction: i, unSplitTransaction: a } = Se(), { common: r, transactions: o } = I(), { setShouldDisableDrawerScroll: s } = At(), { categories: c } =
|
6610
|
+
const { onEvent: n } = z(), { splitTransaction: i, unSplitTransaction: a } = Se(), { common: r, transactions: o } = I(), { setShouldDisableDrawerScroll: s } = At(), { categories: c } = Ve(), d = {
|
6611
6611
|
...e,
|
6612
6612
|
amount: e.amount - 1,
|
6613
6613
|
guid: "",
|
@@ -6791,7 +6791,7 @@ const rc = ({ transaction: e }) => {
|
|
6791
6791
|
] });
|
6792
6792
|
}, bh = A(fh), yh = ({ onSearchValueChanged: e, searchValue: n }) => {
|
6793
6793
|
const { common: i, transactions: a } = I(), r = ft(), o = /* @__PURE__ */ t(
|
6794
|
-
|
6794
|
+
Ye,
|
6795
6795
|
{
|
6796
6796
|
"aria-label": a.tags_cancel_search || "Search",
|
6797
6797
|
onClick: () => e(""),
|
@@ -6835,7 +6835,7 @@ const rc = ({ transaction: e }) => {
|
|
6835
6835
|
disablePadding: !0,
|
6836
6836
|
secondaryAction: !i.is_default_tag && /* @__PURE__ */ l(b, { direction: "row", children: [
|
6837
6837
|
/* @__PURE__ */ t(
|
6838
|
-
|
6838
|
+
Ye,
|
6839
6839
|
{
|
6840
6840
|
"aria-label": `Edit ${i.name} tag`,
|
6841
6841
|
color: "secondary",
|
@@ -6844,7 +6844,7 @@ const rc = ({ transaction: e }) => {
|
|
6844
6844
|
}
|
6845
6845
|
),
|
6846
6846
|
/* @__PURE__ */ t(
|
6847
|
-
|
6847
|
+
Ye,
|
6848
6848
|
{
|
6849
6849
|
"aria-label": `Delete ${i.name} tag`,
|
6850
6850
|
color: "secondary",
|
@@ -7020,7 +7020,7 @@ const rc = ({ transaction: e }) => {
|
|
7020
7020
|
] }) : /* @__PURE__ */ l(b, { alignItems: "center", direction: "row", gap: 4, children: [
|
7021
7021
|
/* @__PURE__ */ t(p, { bold: !0, children: e.description }),
|
7022
7022
|
/* @__PURE__ */ t(
|
7023
|
-
|
7023
|
+
Ye,
|
7024
7024
|
{
|
7025
7025
|
"aria-label": a.description_edit_transaction_name,
|
7026
7026
|
onClick: () => {
|
@@ -7232,7 +7232,7 @@ const rc = ({ transaction: e }) => {
|
|
7232
7232
|
] })
|
7233
7233
|
] });
|
7234
7234
|
}, kh = A(Mh), Gh = ({ onClose: e, transaction: n }) => {
|
7235
|
-
const { addOrUpdateTransactionRule: i, updateTransaction: a } = Se(), { transactions: r } = I(), { categories: o } =
|
7235
|
+
const { addOrUpdateTransactionRule: i, updateTransaction: a } = Se(), { transactions: r } = I(), { categories: o } = Ve(), [s, c] = g.useState(""), d = g.useMemo(
|
7236
7236
|
() => o.find((u) => u.guid === s),
|
7237
7237
|
[s]
|
7238
7238
|
), _ = async (u) => {
|
@@ -7301,7 +7301,7 @@ const rc = ({ transaction: e }) => {
|
|
7301
7301
|
selectedAccounts: me,
|
7302
7302
|
setDisplayedDate: V,
|
7303
7303
|
setSelectedAccounts: Ce
|
7304
|
-
} = ce(), [ge, _e] = g.useState(""), [He, he] = g.useState(""), [
|
7304
|
+
} = ce(), [ge, _e] = g.useState(""), [He, he] = g.useState(""), [Ke, je] = g.useState(!1), [Te, _t] = g.useState(!1), [un, se] = g.useState(!1);
|
7305
7305
|
g.useEffect(() => {
|
7306
7306
|
Ce(r);
|
7307
7307
|
}, [r]), g.useEffect(() => {
|
@@ -7340,11 +7340,11 @@ const rc = ({ transaction: e }) => {
|
|
7340
7340
|
}), _e(
|
7341
7341
|
"addTransaction"
|
7342
7342
|
/* AddTransaction */
|
7343
|
-
), O(W.TRANSACTIONS_CLICK_ADD)) : (
|
7343
|
+
), O(W.TRANSACTIONS_CLICK_ADD)) : (je(!0), O(W.TRANSACTIONS_ADD_MANUAL_ACCOUNT_MODAL));
|
7344
7344
|
}, ka = async () => {
|
7345
7345
|
_n && await f(d), _e("");
|
7346
7346
|
}, tl = () => {
|
7347
|
-
|
7347
|
+
je(!1), _t(!0);
|
7348
7348
|
}, nl = async () => {
|
7349
7349
|
_t(!1), await o();
|
7350
7350
|
}, il = async () => {
|
@@ -7467,9 +7467,9 @@ const rc = ({ transaction: e }) => {
|
|
7467
7467
|
Lh,
|
7468
7468
|
{
|
7469
7469
|
copy: { title: D.add_manual_account },
|
7470
|
-
isOpen:
|
7470
|
+
isOpen: Ke,
|
7471
7471
|
onClose: () => {
|
7472
|
-
|
7472
|
+
je(!1);
|
7473
7473
|
},
|
7474
7474
|
onPrimaryAction: tl
|
7475
7475
|
}
|
@@ -7642,7 +7642,7 @@ const rc = ({ transaction: e }) => {
|
|
7642
7642
|
)
|
7643
7643
|
] });
|
7644
7644
|
}, Wh = A(Fh), Uh = ({ activity: e, onDeleted: n }) => {
|
7645
|
-
const { recurring: i } = I(), { categories: a } =
|
7645
|
+
const { recurring: i } = I(), { categories: a } = Ve(), { deleteCashflowSequence: r, deleteScheduledPayment: o, paidActivities: s } = tt(), { filter: c, setFilter: d, transactions: _ } = Se(), { selectedAccountGuids: u } = ce(), { onEvent: h } = z(), [m, C] = g.useState(!1), [f, E] = g.useState(""), y = a.find((R) => R.guid === e.categoryGuid), T = e.activityType === Qe.Income, w = g.useMemo(
|
7646
7646
|
() => _.find((R) => R.guid === f),
|
7647
7647
|
[f]
|
7648
7648
|
);
|
@@ -9287,7 +9287,7 @@ const Dg = ({ activity: e }) => /* @__PURE__ */ l(Z, { children: [
|
|
9287
9287
|
] }),
|
9288
9288
|
/* @__PURE__ */ t(p, { sx: { flexGrow: 1, fontSize: 13 }, children: e.name }),
|
9289
9289
|
/* @__PURE__ */ t(
|
9290
|
-
|
9290
|
+
ze,
|
9291
9291
|
{
|
9292
9292
|
amount: e.amount,
|
9293
9293
|
bold: !0,
|
@@ -9566,7 +9566,7 @@ const Dg = ({ activity: e }) => /* @__PURE__ */ l(Z, { children: [
|
|
9566
9566
|
),
|
9567
9567
|
/* @__PURE__ */ t(p, { variant: "Small", children: `${f} ${C ? `*${C}` : ""}` })
|
9568
9568
|
] }),
|
9569
|
-
/* @__PURE__ */ t(
|
9569
|
+
/* @__PURE__ */ t(ze, { amount: _.balance, bold: !0, variant: "Small" })
|
9570
9570
|
]
|
9571
9571
|
}
|
9572
9572
|
),
|
@@ -9581,7 +9581,7 @@ const Dg = ({ activity: e }) => /* @__PURE__ */ l(Z, { children: [
|
|
9581
9581
|
py: 12,
|
9582
9582
|
children: [
|
9583
9583
|
/* @__PURE__ */ t(p, { variant: "Small", children: i.projected_income }),
|
9584
|
-
/* @__PURE__ */ t(
|
9584
|
+
/* @__PURE__ */ t(ze, { amount: _.income, bold: !0, symbol: "+", variant: "Small" })
|
9585
9585
|
]
|
9586
9586
|
}
|
9587
9587
|
),
|
@@ -9596,7 +9596,7 @@ const Dg = ({ activity: e }) => /* @__PURE__ */ l(Z, { children: [
|
|
9596
9596
|
py: 12,
|
9597
9597
|
children: [
|
9598
9598
|
/* @__PURE__ */ t(p, { variant: "Small", children: i.projected_expenses }),
|
9599
|
-
/* @__PURE__ */ t(
|
9599
|
+
/* @__PURE__ */ t(ze, { amount: _.expenses, bold: !0, symbol: "-", variant: "Small" })
|
9600
9600
|
]
|
9601
9601
|
}
|
9602
9602
|
),
|
@@ -9680,12 +9680,12 @@ const Dg = ({ activity: e }) => /* @__PURE__ */ l(Z, { children: [
|
|
9680
9680
|
padding: n ? "14px 16px" : 0,
|
9681
9681
|
sx: { borderBottomLeftRadius: 4, borderBottomRightRadius: 4 },
|
9682
9682
|
children: [
|
9683
|
-
!n && /* @__PURE__ */ t(
|
9683
|
+
!n && /* @__PURE__ */ t(ze, { amount: e, component: "h2", variant: "H2" }),
|
9684
9684
|
/* @__PURE__ */ l(b, { alignItems: "center", component: "span", direction: "row", gap: 8, mt: 2, children: [
|
9685
9685
|
/* @__PURE__ */ t(p, { bold: i, variant: "Small", children: a }),
|
9686
9686
|
o
|
9687
9687
|
] }),
|
9688
|
-
n && /* @__PURE__ */ t(
|
9688
|
+
n && /* @__PURE__ */ t(ze, { amount: e, component: "h2", symbol: r, variant: "Small" })
|
9689
9689
|
]
|
9690
9690
|
}
|
9691
9691
|
), Go = (e, n) => (i) => i.accountGuid && e.includes(i.accountGuid) && (hr(i.expectedDate) || Zt(i.expectedDate, n.start)) && ve(i.expectedDate, n.end), Pg = () => {
|
@@ -9909,10 +9909,10 @@ const Dg = ({ activity: e }) => /* @__PURE__ */ l(Z, { children: [
|
|
9909
9909
|
He,
|
9910
9910
|
He.frequency,
|
9911
9911
|
He.nextDate
|
9912
|
-
),
|
9913
|
-
if (
|
9914
|
-
const
|
9915
|
-
await e(
|
9912
|
+
), Ke = await n(he);
|
9913
|
+
if (Ke) {
|
9914
|
+
const je = hc(Ke, He);
|
9915
|
+
await e(je);
|
9916
9916
|
}
|
9917
9917
|
}
|
9918
9918
|
await o();
|
@@ -10708,7 +10708,7 @@ const Cn = () => {
|
|
10708
10708
|
}
|
10709
10709
|
return c;
|
10710
10710
|
}, dm = () => {
|
10711
|
-
const e = at(), { selectedAccount: n } = $t(), { monthlyCategoryTotals: i } =
|
10711
|
+
const e = at(), { selectedAccount: n } = $t(), { monthlyCategoryTotals: i } = Ve(), { trends: a } = I(), r = [e.palette.chart?.chart1, e.palette.chart?.chart2], o = cm(i, n.account_type), s = lm(o, n.account_type, a), c = [oe.LOAN, oe.MORTGAGE].includes(n.account_type);
|
10712
10712
|
return /* @__PURE__ */ t("div", { "data-testid": "TrendsChart", children: /* @__PURE__ */ t(
|
10713
10713
|
br,
|
10714
10714
|
{
|
@@ -10721,7 +10721,7 @@ const Cn = () => {
|
|
10721
10721
|
}
|
10722
10722
|
) });
|
10723
10723
|
}, um = A(dm), _m = ({ sx: e }) => {
|
10724
|
-
const { loadMonthlyCategoryTotals: n } =
|
10724
|
+
const { loadMonthlyCategoryTotals: n } = Ve(), { isInitialized: i } = ba(), { selectedAccount: a } = $t(), [r, o] = g.useState(!1);
|
10725
10725
|
return g.useEffect(() => {
|
10726
10726
|
i && n([a]).finally(() => {
|
10727
10727
|
o(!0);
|
@@ -11606,7 +11606,7 @@ const Ut = (e) => /* @__PURE__ */ t(p, { fontWeight: 600, variant: "Small", chil
|
|
11606
11606
|
children: e
|
11607
11607
|
}
|
11608
11608
|
) : /* @__PURE__ */ t(
|
11609
|
-
|
11609
|
+
Ye,
|
11610
11610
|
{
|
11611
11611
|
"aria-controls": "prioritize-debts",
|
11612
11612
|
"aria-describedby": "prioritize-debts",
|
@@ -13723,7 +13723,7 @@ const Mp = ({
|
|
13723
13723
|
{
|
13724
13724
|
primary: /* @__PURE__ */ l(b, { direction: "row", justifyContent: "space-between", sx: { fontWeight: 400 }, children: [
|
13725
13725
|
/* @__PURE__ */ t(p, { variant: "Body", children: Fs(e.x) }),
|
13726
|
-
/* @__PURE__ */ t(
|
13726
|
+
/* @__PURE__ */ t(ze, { amount: e.y, sx: { color: "inherit" }, variant: "Body" })
|
13727
13727
|
] })
|
13728
13728
|
}
|
13729
13729
|
)
|
@@ -13797,14 +13797,14 @@ const Mp = ({
|
|
13797
13797
|
}
|
13798
13798
|
}
|
13799
13799
|
),
|
13800
|
-
/* @__PURE__ */ t(
|
13800
|
+
/* @__PURE__ */ t(ze, { amount: a.change, color: s, variant: n }),
|
13801
13801
|
/* @__PURE__ */ t(p, { variant: "Small", children: e })
|
13802
13802
|
] });
|
13803
13803
|
}, kr = A($p), Fp = ({ hoveredData: e, selectedData: n }) => {
|
13804
13804
|
const { net_worth: i } = I(), a = at(), r = e || n, o = On(Si(r.x), "MMMM");
|
13805
13805
|
return /* @__PURE__ */ l(b, { alignItems: "center", direction: "column", m: 24, children: [
|
13806
13806
|
/* @__PURE__ */ t(p, { color: a.palette.secondary.main, variant: "Small", children: `${o} ${i.net_worth}` }),
|
13807
|
-
/* @__PURE__ */ t(
|
13807
|
+
/* @__PURE__ */ t(ze, { amount: r.y, variant: "H2" }),
|
13808
13808
|
/* @__PURE__ */ t(kr, { currencyLabel: i.this_month, netWorth: r, theme: a })
|
13809
13809
|
] });
|
13810
13810
|
}, Wp = A(Fp), Up = ({
|
@@ -13867,7 +13867,7 @@ const Mp = ({
|
|
13867
13867
|
{
|
13868
13868
|
primary: /* @__PURE__ */ l(b, { direction: "row", justifyContent: "space-between", sx: { fontWeight: 400 }, children: [
|
13869
13869
|
/* @__PURE__ */ t(p, { variant: "Body", children: o.accountName }),
|
13870
|
-
/* @__PURE__ */ t(
|
13870
|
+
/* @__PURE__ */ t(ze, { amount: o.balance, variant: "Small" })
|
13871
13871
|
] }),
|
13872
13872
|
sx: { pl: 72, pr: 16 }
|
13873
13873
|
}
|
@@ -13897,7 +13897,7 @@ const Mp = ({
|
|
13897
13897
|
},
|
13898
13898
|
children: [
|
13899
13899
|
/* @__PURE__ */ t(p, { variant: "Body", children: o.current_net_worth }),
|
13900
|
-
/* @__PURE__ */ t(
|
13900
|
+
/* @__PURE__ */ t(ze, { amount: e?.y ?? 0, variant: "H1" }),
|
13901
13901
|
e && /* @__PURE__ */ t(
|
13902
13902
|
kr,
|
13903
13903
|
{
|
@@ -13916,7 +13916,7 @@ const Mp = ({
|
|
13916
13916
|
{
|
13917
13917
|
primary: /* @__PURE__ */ l(b, { direction: "row", justifyContent: "space-between", children: [
|
13918
13918
|
/* @__PURE__ */ t(p, { sx: { fontWeight: 700 }, variant: "XSmall", children: o.assets }),
|
13919
|
-
/* @__PURE__ */ t(
|
13919
|
+
/* @__PURE__ */ t(ze, { amount: a, sx: { fontWeight: 400 }, variant: "XSmall" })
|
13920
13920
|
] })
|
13921
13921
|
}
|
13922
13922
|
) }),
|
@@ -13926,7 +13926,7 @@ const Mp = ({
|
|
13926
13926
|
{
|
13927
13927
|
primary: /* @__PURE__ */ l(b, { direction: "row", justifyContent: "space-between", children: [
|
13928
13928
|
/* @__PURE__ */ t(p, { sx: { fontWeight: 700 }, variant: "XSmall", children: o.liabilities }),
|
13929
|
-
/* @__PURE__ */ t(
|
13929
|
+
/* @__PURE__ */ t(ze, { amount: r, sx: { fontWeight: 400 }, variant: "XSmall" })
|
13930
13930
|
] })
|
13931
13931
|
}
|
13932
13932
|
) }),
|
@@ -13953,7 +13953,7 @@ const Mp = ({
|
|
13953
13953
|
{
|
13954
13954
|
primary: /* @__PURE__ */ l(b, { direction: "row", justifyContent: "space-between", children: [
|
13955
13955
|
/* @__PURE__ */ t(p, { sx: { fontWeight: 700 }, variant: "XSmall", children: o.gains }),
|
13956
|
-
/* @__PURE__ */ t(
|
13956
|
+
/* @__PURE__ */ t(ze, { amount: a, sx: { fontWeight: 400 }, variant: "XSmall" })
|
13957
13957
|
] })
|
13958
13958
|
}
|
13959
13959
|
) }),
|
@@ -13964,7 +13964,7 @@ const Mp = ({
|
|
13964
13964
|
primary: /* @__PURE__ */ l(b, { direction: "row", justifyContent: "space-between", sx: { fontWeight: 400 }, children: [
|
13965
13965
|
/* @__PURE__ */ t(p, { variant: "Body", children: c.accountName }),
|
13966
13966
|
/* @__PURE__ */ t(
|
13967
|
-
|
13967
|
+
ze,
|
13968
13968
|
{
|
13969
13969
|
amount: c.gain,
|
13970
13970
|
sx: { color: s.palette.success.main, fontWeight: 700 },
|
@@ -13982,7 +13982,7 @@ const Mp = ({
|
|
13982
13982
|
{
|
13983
13983
|
primary: /* @__PURE__ */ l(b, { direction: "row", justifyContent: "space-between", children: [
|
13984
13984
|
/* @__PURE__ */ t(p, { sx: { fontWeight: 700 }, variant: "XSmall", children: o.losses }),
|
13985
|
-
/* @__PURE__ */ t(
|
13985
|
+
/* @__PURE__ */ t(ze, { amount: r, sx: { fontWeight: 400 }, variant: "XSmall" })
|
13986
13986
|
] })
|
13987
13987
|
}
|
13988
13988
|
) }),
|
@@ -13996,7 +13996,7 @@ const Mp = ({
|
|
13996
13996
|
{
|
13997
13997
|
primary: /* @__PURE__ */ l(b, { direction: "row", justifyContent: "space-between", sx: { fontWeight: 400 }, children: [
|
13998
13998
|
/* @__PURE__ */ t(p, { variant: "Body", children: c.accountName }),
|
13999
|
-
/* @__PURE__ */ t(
|
13999
|
+
/* @__PURE__ */ t(ze, { amount: c.loss, sx: { fontWeight: 700 }, variant: "Body" })
|
14000
14000
|
] }),
|
14001
14001
|
sx: { px: 16 }
|
14002
14002
|
}
|
@@ -14031,16 +14031,16 @@ const Mp = ({
|
|
14031
14031
|
}, [i, a]), g.useEffect(() => {
|
14032
14032
|
w(W.NET_WORTH_WIDGET_CLICK_TIMEFRAME, { time_period: R + "M" }), h(R).finally();
|
14033
14033
|
}, [R]);
|
14034
|
-
const V = (
|
14035
|
-
y(Te),
|
14036
|
-
}, Ce = (
|
14037
|
-
E(
|
14034
|
+
const V = (je, Te) => {
|
14035
|
+
y(Te), je.currentTarget instanceof HTMLDivElement && O(!0);
|
14036
|
+
}, Ce = (je) => {
|
14037
|
+
E(je);
|
14038
14038
|
}, ge = () => {
|
14039
14039
|
E(null);
|
14040
14040
|
}, _e = () => {
|
14041
14041
|
w(W.NET_WORTH_WIDGET_CLICK_ASSETS_LIABILITIES), U(!0);
|
14042
|
-
}, He = async (
|
14043
|
-
const Te =
|
14042
|
+
}, He = async (je) => {
|
14043
|
+
const Te = je[0], _t = je[1];
|
14044
14044
|
Te && _t && D(dd(_t, Te));
|
14045
14045
|
}, he = {
|
14046
14046
|
chartData: C,
|
@@ -14050,7 +14050,7 @@ const Mp = ({
|
|
14050
14050
|
onMouseEnter: Ce,
|
14051
14051
|
onMouseLeave: ge,
|
14052
14052
|
selectedData: f
|
14053
|
-
},
|
14053
|
+
}, Ke = () => {
|
14054
14054
|
j(!0), w(W.ACCOUNTS_CLICK_CONNECT);
|
14055
14055
|
};
|
14056
14056
|
return n ? /* @__PURE__ */ t(
|
@@ -14098,7 +14098,7 @@ const Mp = ({
|
|
14098
14098
|
{
|
14099
14099
|
header: s.empty_widget_header,
|
14100
14100
|
icon: "elevation",
|
14101
|
-
onClick:
|
14101
|
+
onClick: Ke,
|
14102
14102
|
primaryButton: s.empty_widget_button,
|
14103
14103
|
subText: s.empty_widget_description,
|
14104
14104
|
sx: {
|
@@ -14146,16 +14146,16 @@ const Mp = ({
|
|
14146
14146
|
) : /* @__PURE__ */ t(ue, {});
|
14147
14147
|
}), IE = (e) => {
|
14148
14148
|
switch (e) {
|
14149
|
-
case
|
14150
|
-
case
|
14149
|
+
case Ue.BudgetExceeded:
|
14150
|
+
case Ue.BudgetOffTarget:
|
14151
14151
|
return k.BUDGETS;
|
14152
|
-
case
|
14153
|
-
case
|
14154
|
-
case
|
14152
|
+
case Ue.DebtPaymentReminder:
|
14153
|
+
case Ue.AccountBalanceLow:
|
14154
|
+
case Ue.AccountDepositLarge:
|
14155
14155
|
return k.ACCOUNTS;
|
14156
|
-
case
|
14157
|
-
case
|
14158
|
-
case
|
14156
|
+
case Ue.TransactionExpenseLarge:
|
14157
|
+
case Ue.TransactionFeeCharge:
|
14158
|
+
case Ue.InternationalTransaction:
|
14159
14159
|
return k.TRANSACTIONS;
|
14160
14160
|
default:
|
14161
14161
|
return null;
|
@@ -14293,21 +14293,22 @@ class jo {
|
|
14293
14293
|
}
|
14294
14294
|
const Xo = "PARENT-ENTITY", a1 = (e, n) => {
|
14295
14295
|
switch (e) {
|
14296
|
-
case
|
14296
|
+
case Ue.BudgetExceeded:
|
14297
14297
|
return n.notification_budget_exceeded;
|
14298
|
-
case
|
14298
|
+
case Ue.BudgetOffTarget:
|
14299
14299
|
return n.notification_budget_off_target;
|
14300
|
-
case
|
14300
|
+
case Ue.DebtPaymentReminder:
|
14301
14301
|
return n.notification_debt_payment_reminder;
|
14302
|
-
case
|
14302
|
+
case Ue.AccountBalanceLow:
|
14303
14303
|
return n.notification_low_balance;
|
14304
|
-
case
|
14304
|
+
case Ue.AccountDepositLargePosted:
|
14305
|
+
case Ue.AccountDepositLarge:
|
14305
14306
|
return n.notification_large_deposit;
|
14306
|
-
case
|
14307
|
+
case Ue.TransactionExpenseLarge:
|
14307
14308
|
return n.notification_large_expense;
|
14308
|
-
case
|
14309
|
+
case Ue.TransactionFeeCharge:
|
14309
14310
|
return n.notification_transaction_fee;
|
14310
|
-
case
|
14311
|
+
case Ue.InternationalTransaction:
|
14311
14312
|
return n.notification_transaction_is_international;
|
14312
14313
|
default:
|
14313
14314
|
return "";
|
@@ -14353,12 +14354,12 @@ class o1 {
|
|
14353
14354
|
}
|
14354
14355
|
get accountProfiles() {
|
14355
14356
|
return this.detailedNotificationProfiles.filter(
|
14356
|
-
(n) => n.notification_type ===
|
14357
|
+
(n) => n.notification_type === Ue.DebtPaymentReminder || n.notification_type === Ue.AccountBalanceLow || n.notification_type === Ue.AccountDepositLarge || n.notification_type === Ue.AccountDepositLargePosted || n.notification_type === Ue.TransactionExpenseLarge || n.notification_type === Ue.TransactionFeeCharge || n.notification_type === Ue.InternationalTransaction
|
14357
14358
|
);
|
14358
14359
|
}
|
14359
14360
|
get budgetProfiles() {
|
14360
14361
|
return this.detailedNotificationProfiles.filter(
|
14361
|
-
(n) => n.notification_type ===
|
14362
|
+
(n) => n.notification_type === Ue.BudgetExceeded || n.notification_type === Ue.BudgetOffTarget
|
14362
14363
|
);
|
14363
14364
|
}
|
14364
14365
|
get clientCommunicationProfile() {
|
@@ -14485,7 +14486,7 @@ class o1 {
|
|
14485
14486
|
});
|
14486
14487
|
};
|
14487
14488
|
updateUser = async (n) => {
|
14488
|
-
this.globalStore.userStore.updateUser(n).then(() => {
|
14489
|
+
console.log("updated user birthday is ", n.birthday), this.globalStore.userStore.updateUser(n).then(() => {
|
14489
14490
|
this.setAlert(this.copy.information_updated_success, "success");
|
14490
14491
|
}).catch(() => {
|
14491
14492
|
this.setAlert(this.copy.information_updated_error, "error");
|
@@ -17892,14 +17893,20 @@ const l1 = ({
|
|
17892
17893
|
)
|
17893
17894
|
] });
|
17894
17895
|
}), Y1 = () => {
|
17895
|
-
const e = at(), { common: n, settings: i } = I(), { isDesktop: a, isMobile: r, isSmallMobile: o, isTablet: s } = De(), { config: c } = Ca(), { updateUser: d } = Ht(), { user: _ } = dn(), [u, h] = g.useState(_.first_name), [m, C] = g.useState(_.last_name), [f, E] = g.useState(_.email), [y, T] = g.useState(_.phone), [w, N] = g.useState(_.postal_code), [x, R] = g.useState(_.credit_score), [D, $] = g.useState(Me(_.birthday ?? 0)), O = f && !_.email_is_verified, L = y && !_.phone_is_verified
|
17896
|
+
const e = at(), { common: n, settings: i } = I(), { isDesktop: a, isMobile: r, isSmallMobile: o, isTablet: s } = De(), { config: c } = Ca(), { updateUser: d } = Ht(), { user: _ } = dn(), [u, h] = g.useState(_.first_name), [m, C] = g.useState(_.last_name), [f, E] = g.useState(_.email), [y, T] = g.useState(_.phone), [w, N] = g.useState(_.postal_code), [x, R] = g.useState(_.credit_score), [D, $] = g.useState(Me(_.birthday ?? 0)), O = f && !_.email_is_verified, L = y && !_.phone_is_verified;
|
17897
|
+
g.useEffect(() => {
|
17898
|
+
console.log("user birthday at first is ", _.birthday);
|
17899
|
+
}, [_]), g.useEffect(() => {
|
17900
|
+
console.log("birthday changed, is ", D);
|
17901
|
+
}, [D]);
|
17902
|
+
const U = async () => {
|
17896
17903
|
const H = {
|
17897
17904
|
..._,
|
17898
17905
|
first_name: u,
|
17899
17906
|
last_name: m,
|
17900
17907
|
email: f,
|
17901
17908
|
phone: y,
|
17902
|
-
birthday: D
|
17909
|
+
birthday: D && Oe(D),
|
17903
17910
|
postal_code: w,
|
17904
17911
|
credit_score: x
|
17905
17912
|
};
|
@@ -18040,7 +18047,7 @@ const X1 = ({
|
|
18040
18047
|
renderCell: (c) => /* @__PURE__ */ l(b, { alignItems: "center", direction: "row", gap: 4, children: [
|
18041
18048
|
/* @__PURE__ */ t(p, { variant: "Small", children: c.value }),
|
18042
18049
|
/* @__PURE__ */ t(
|
18043
|
-
|
18050
|
+
Ye,
|
18044
18051
|
{
|
18045
18052
|
"aria-label": r.mobile_devices_edit_label,
|
18046
18053
|
color: "secondary",
|
@@ -18077,7 +18084,7 @@ const X1 = ({
|
|
18077
18084
|
headerName: "",
|
18078
18085
|
renderHeader: Ut,
|
18079
18086
|
renderCell: (c) => /* @__PURE__ */ t(b, { mr: 4, children: /* @__PURE__ */ t(
|
18080
|
-
|
18087
|
+
Ye,
|
18081
18088
|
{
|
18082
18089
|
"aria-label": r.mobile_devices_delete_label,
|
18083
18090
|
color: "secondary",
|
@@ -18194,7 +18201,7 @@ const X1 = ({
|
|
18194
18201
|
borderColor: a.palette.border.light
|
18195
18202
|
},
|
18196
18203
|
children: [
|
18197
|
-
/* @__PURE__ */ t(
|
18204
|
+
/* @__PURE__ */ t(Ye, { "aria-label": r.mobile_devices_edit_label, color: "secondary", children: /* @__PURE__ */ t(P, { name: "edit" }) }),
|
18198
18205
|
/* @__PURE__ */ t(p, { variant: "Body", children: r.mobile_devices_edit_label })
|
18199
18206
|
]
|
18200
18207
|
}
|
@@ -18212,7 +18219,7 @@ const X1 = ({
|
|
18212
18219
|
cursor: "pointer"
|
18213
18220
|
},
|
18214
18221
|
children: [
|
18215
|
-
/* @__PURE__ */ t(
|
18222
|
+
/* @__PURE__ */ t(Ye, { "aria-label": r.mobile_devices_delete_label, color: "secondary", children: /* @__PURE__ */ t(P, { name: "delete" }) }),
|
18216
18223
|
/* @__PURE__ */ t(p, { variant: "Body", children: r.mobile_devices_delete_label })
|
18217
18224
|
]
|
18218
18225
|
}
|
@@ -18425,7 +18432,7 @@ const X1 = ({
|
|
18425
18432
|
] }) });
|
18426
18433
|
}
|
18427
18434
|
), eC = A(() => {
|
18428
|
-
const { settings: e } = I(), { categories: n } =
|
18435
|
+
const { settings: e } = I(), { categories: n } = Ve(), { selectedRule: i, updateRuleCategory: a } = Ht(), [r, o] = g.useState(!1), s = () => {
|
18429
18436
|
o(!1);
|
18430
18437
|
}, c = () => {
|
18431
18438
|
o(!0);
|
@@ -18553,7 +18560,7 @@ const X1 = ({
|
|
18553
18560
|
);
|
18554
18561
|
}
|
18555
18562
|
), aC = A(({ rule: e }) => {
|
18556
|
-
const { categories: n } =
|
18563
|
+
const { categories: n } = Ve(), { setSelectedGuid: i } = pn(), { deleteTransactionRule: a, setSelectedRule: r } = Ht(), { isDesktop: o, isTablet: s } = De(), [c, d] = g.useState(!1), _ = () => {
|
18557
18564
|
d(!1), i(null), r(void 0);
|
18558
18565
|
}, u = async () => {
|
18559
18566
|
await a(), _();
|
@@ -18637,7 +18644,7 @@ const X1 = ({
|
|
18637
18644
|
] });
|
18638
18645
|
}), sC = A(
|
18639
18646
|
({ onProfileUpdated: e, profile: n }) => {
|
18640
|
-
const { common: i, settings: a } = I(), { updateAccount: r } = Re(), o = n.notification_type ===
|
18647
|
+
const { common: i, settings: a } = I(), { updateAccount: r } = Re(), o = n.notification_type === Ue.DebtPaymentReminder, [s, c] = g.useState(!1), [d, _] = g.useState(n.threshold || 0), [u, h] = g.useState(
|
18641
18648
|
n.account?.day_payment_is_due || 0
|
18642
18649
|
), m = n.account?.name || n.account?.feed_name || "", C = n.account?.day_payment_is_due ? S(
|
18643
18650
|
a.notification_debt_payment_date,
|
@@ -18939,7 +18946,7 @@ const X1 = ({
|
|
18939
18946
|
title: a.notifications_title,
|
18940
18947
|
children: [
|
18941
18948
|
!o && /* @__PURE__ */ t(
|
18942
|
-
|
18949
|
+
Ye,
|
18943
18950
|
{
|
18944
18951
|
"aria-label": "Open notification settings",
|
18945
18952
|
onClick: () => s(!0),
|
@@ -21444,7 +21451,7 @@ const gf = ({
|
|
21444
21451
|
onConnectAccountsClick: n,
|
21445
21452
|
createBudgetOnClick: i
|
21446
21453
|
}) => {
|
21447
|
-
const { recalculateBudgets: a } = lt(), { spendCategories: r } =
|
21454
|
+
const { recalculateBudgets: a } = lt(), { spendCategories: r } = Ve(), { budgets: o } = I(), [s, c] = g.useState(!1), [d, _] = g.useState(!1), [u, h] = g.useState(!1), m = g.useMemo(() => [...r.filter((f) => f.totalAverageAmount > 0)], [r]), C = async () => {
|
21448
21455
|
h(!0);
|
21449
21456
|
const { data: f, isSuccess: E } = await a(m);
|
21450
21457
|
h(!1), E ? (f.length === 0 && c(!0), _(!1)) : _(!0);
|
@@ -21523,7 +21530,7 @@ const gf = ({
|
|
21523
21530
|
shouldShowZeroState: r,
|
21524
21531
|
unavailableWidth: o = 24
|
21525
21532
|
}) => {
|
21526
|
-
const { onEvent: s } = z(), { setSelectedBudget: c } = lt(), { isLoadingCategoryTotals: d } =
|
21533
|
+
const { onEvent: s } = z(), { setSelectedBudget: c } = lt(), { isLoadingCategoryTotals: d } = Ve(), { isInitialized: _ } = ce(), { accounts: u } = I(), { availableWidth: h } = $n(), { isMobile: m } = De(), [C, f] = g.useState(!1), E = g.useMemo(() => h - o, [h]), y = (w) => {
|
21527
21534
|
c(w), s(W.BUDGETS_CLICK_BUDGET_CATEGORY, {
|
21528
21535
|
budget_category: w.category.name,
|
21529
21536
|
click_type: "bubble"
|
@@ -21559,7 +21566,7 @@ const gf = ({
|
|
21559
21566
|
] });
|
21560
21567
|
}
|
21561
21568
|
), Cf = (e) => {
|
21562
|
-
const n = pe(), { accounts: i } = Re(), { budgets: a, isDataLoaded: r, loadBudgetData: o, setTheme: s } = lt(), { budgets: c } = I(), { isCopyLoaded: d, isInitialized: _ } = ce(), { reloadCategoryTotals: u } =
|
21569
|
+
const n = pe(), { accounts: i } = Re(), { budgets: a, isDataLoaded: r, loadBudgetData: o, setTheme: s } = lt(), { budgets: c } = I(), { isCopyLoaded: d, isInitialized: _ } = ce(), { reloadCategoryTotals: u } = Ve(), h = Zu(), m = a.length === 0;
|
21563
21570
|
return g.useEffect(() => {
|
21564
21571
|
s(n);
|
21565
21572
|
}, [n]), g.useEffect(() => {
|
@@ -21621,7 +21628,7 @@ const gf = ({
|
|
21621
21628
|
] }, e.guid);
|
21622
21629
|
}
|
21623
21630
|
), yf = ({ onRecalculateBudgets: e }) => {
|
21624
|
-
const { budgets: n, common: i } = I(), { spendCategories: a } =
|
21631
|
+
const { budgets: n, common: i } = I(), { spendCategories: a } = Ve(), { recalculateBudgets: r, setAlert: o } = lt(), [s, c] = g.useState(!1), d = a.filter((u) => u.totalAverageAmount > 0), _ = async () => {
|
21625
21632
|
await r(d), c(!1), o(n.alert_recalculated_budgets), e?.();
|
21626
21633
|
};
|
21627
21634
|
return /* @__PURE__ */ l(g.Fragment, { children: [
|
@@ -22083,7 +22090,7 @@ const gf = ({
|
|
22083
22090
|
] }, o.guid)) }) })
|
22084
22091
|
] });
|
22085
22092
|
}), Rf = A(() => {
|
22086
|
-
const e = pe(), { onEvent: n } = z(), { visibleAccounts: i } = Re(), { budgets: a, common: r, recurring: o } = I(), { incomeCategories: s, spendCategories: c } =
|
22093
|
+
const e = pe(), { onEvent: n } = z(), { visibleAccounts: i } = Re(), { budgets: a, common: r, recurring: o } = I(), { incomeCategories: s, spendCategories: c } = Ve(), { detailedBudgets: d, totalBudgeted: _ } = lt(), { projectedIncome: u } = tt(), { setFilter: h } = Se(), [m, C] = g.useState(!1), [f, E] = g.useMemo(() => {
|
22087
22094
|
const N = c.reduce(($, O) => $ + O.totalAmount, 0);
|
22088
22095
|
let x = N / _;
|
22089
22096
|
x > 1 && (x = 1);
|
@@ -22134,7 +22141,7 @@ const gf = ({
|
|
22134
22141
|
/* @__PURE__ */ l(b, { alignItems: "center", direction: "row", gap: 4, mb: -4, children: [
|
22135
22142
|
/* @__PURE__ */ t(p, { bold: !0, variant: "Body", children: a.income_title }),
|
22136
22143
|
/* @__PURE__ */ t(
|
22137
|
-
|
22144
|
+
Ye,
|
22138
22145
|
{
|
22139
22146
|
"aria-label": o.manage_income,
|
22140
22147
|
onClick: w,
|
@@ -22175,7 +22182,7 @@ const gf = ({
|
|
22175
22182
|
setAlert: T,
|
22176
22183
|
setTheme: w,
|
22177
22184
|
budgets: N
|
22178
|
-
} = lt(), { loadActivity: x } = tt(), { isDesktop: R, isTablet: D } = De(), { reloadCategoryTotals: $ } =
|
22185
|
+
} = lt(), { loadActivity: x } = tt(), { isDesktop: R, isTablet: D } = De(), { reloadCategoryTotals: $ } = Ve(), [O, L] = g.useState(!1);
|
22179
22186
|
g.useEffect(() => {
|
22180
22187
|
w(i), h(r), u(C.start, C.end), a(W.BUDGETS_VIEW);
|
22181
22188
|
}, []), g.useEffect(() => {
|
@@ -22640,19 +22647,19 @@ const kf = ({ widgets: e, isLoading: n }) => {
|
|
22640
22647
|
const { isCopyLoaded: L } = ce(), [U, H] = yt(null), [j, me] = yt("");
|
22641
22648
|
if (!L || !d)
|
22642
22649
|
return /* @__PURE__ */ t(ue, {});
|
22643
|
-
const V = (he,
|
22644
|
-
H(he), me(
|
22650
|
+
const V = (he, Ke) => {
|
22651
|
+
H(he), me(Ke.toFixed(2));
|
22645
22652
|
}, Ce = (he) => {
|
22646
|
-
const
|
22647
|
-
/^\d*\.?\d*$/.test(
|
22648
|
-
}, ge = (he,
|
22653
|
+
const Ke = he.target.value;
|
22654
|
+
/^\d*\.?\d*$/.test(Ke) && me(Ke);
|
22655
|
+
}, ge = (he, Ke) => {
|
22649
22656
|
if (he.key === "Enter") {
|
22650
|
-
const
|
22651
|
-
c({ ...
|
22657
|
+
const je = s.find(({ guid: Te }) => Te === Ke);
|
22658
|
+
c({ ...je, cost_basis: Number(j) }), H(null);
|
22652
22659
|
} else he.key === "Escape" && H(null);
|
22653
22660
|
}, _e = (he) => {
|
22654
|
-
const
|
22655
|
-
c({ ...
|
22661
|
+
const Ke = s.find(({ guid: je }) => je === he);
|
22662
|
+
c({ ...Ke, cost_basis: Number(j) }), H(null);
|
22656
22663
|
}, He = [
|
22657
22664
|
{
|
22658
22665
|
field: "qty",
|
@@ -22678,15 +22685,15 @@ const kf = ({ widgets: e, isLoading: n }) => {
|
|
22678
22685
|
width: 132,
|
22679
22686
|
renderHeader: Fi,
|
22680
22687
|
renderCell: (he) => {
|
22681
|
-
const
|
22688
|
+
const Ke = U === he.row.id;
|
22682
22689
|
return /* @__PURE__ */ l(Ee, { sx: { alignItems: "center", flexDirection: "row", gap: 4 }, children: [
|
22683
|
-
|
22690
|
+
Ke ? /* @__PURE__ */ t(
|
22684
22691
|
nt,
|
22685
22692
|
{
|
22686
22693
|
autoFocus: !0,
|
22687
22694
|
onBlur: () => _e(he.row.id),
|
22688
22695
|
onChange: Ce,
|
22689
|
-
onKeyDown: (
|
22696
|
+
onKeyDown: (je) => ge(je, he.row.id),
|
22690
22697
|
size: "small",
|
22691
22698
|
sx: {
|
22692
22699
|
fontSize: 14,
|
@@ -22710,7 +22717,7 @@ const kf = ({ widgets: e, isLoading: n }) => {
|
|
22710
22717
|
style: "currency"
|
22711
22718
|
}) }),
|
22712
22719
|
/* @__PURE__ */ t(
|
22713
|
-
|
22720
|
+
Ye,
|
22714
22721
|
{
|
22715
22722
|
onClick: () => V(he.row.id, he.row.costBasis),
|
22716
22723
|
sx: { minWidth: 12, minHeight: 12 },
|
@@ -22728,7 +22735,7 @@ const kf = ({ widgets: e, isLoading: n }) => {
|
|
22728
22735
|
width: 196,
|
22729
22736
|
renderHeader: Fi,
|
22730
22737
|
renderCell: (he) => {
|
22731
|
-
const
|
22738
|
+
const Ke = he.row.costBasis, je = Ke ? he.row.totalGainLoss / Ke * 100 : 0, Te = he.value <= 0 ? "text.secondary" : "#0AC295";
|
22732
22739
|
return /* @__PURE__ */ l(Ee, { sx: { alignItems: "center", flexDirection: "row", gap: 2 }, children: [
|
22733
22740
|
he.value !== 0 && /* @__PURE__ */ t(
|
22734
22741
|
wt,
|
@@ -22738,7 +22745,7 @@ const kf = ({ widgets: e, isLoading: n }) => {
|
|
22738
22745
|
sx: { color: Te, mr: 1, verticalAlign: "middle" }
|
22739
22746
|
}
|
22740
22747
|
),
|
22741
|
-
/* @__PURE__ */ t(p, { sx: { color: Te, fontWeight: 700 }, variant: "Small", children:
|
22748
|
+
/* @__PURE__ */ t(p, { sx: { color: Te, fontWeight: 700 }, variant: "Small", children: Ke ? `${je.toFixed(2)}%` : "0.00%" }),
|
22742
22749
|
/* @__PURE__ */ t(p, { sx: { color: "text.secondary" }, variant: "XSmall", children: "|" }),
|
22743
22750
|
/* @__PURE__ */ t(p, { sx: { color: Te, fontWeight: 700 }, variant: "Small", children: Math.abs(he.value).toLocaleString("en-US", {
|
22744
22751
|
currency: "USD",
|
@@ -24561,7 +24568,7 @@ const Gi = g.createContext(null), Yf = ({
|
|
24561
24568
|
const c = o0(), d = at(), { carouselCopy: _ } = Fn(), u = Math.floor(s) > o || n === 0, h = s < 0 || i - 1 === n, m = d.palette.grey[500], C = e?.primary_300 ?? d.palette.primary.main;
|
24562
24569
|
return /* @__PURE__ */ l(M, { className: c, children: [
|
24563
24570
|
/* @__PURE__ */ t(
|
24564
|
-
|
24571
|
+
Ye,
|
24565
24572
|
{
|
24566
24573
|
"aria-disabled": u,
|
24567
24574
|
"aria-label": _.previous_insight_cta_aria,
|
@@ -24588,7 +24595,7 @@ const Gi = g.createContext(null), Yf = ({
|
|
24588
24595
|
`carousel-button-${E}`
|
24589
24596
|
)),
|
24590
24597
|
/* @__PURE__ */ t(
|
24591
|
-
|
24598
|
+
Ye,
|
24592
24599
|
{
|
24593
24600
|
"aria-disabled": h,
|
24594
24601
|
"aria-label": _.next_insight_cta_aria,
|
@@ -24691,11 +24698,11 @@ const Gi = g.createContext(null), Yf = ({
|
|
24691
24698
|
N.card_position_in_carousel_aria,
|
24692
24699
|
ge.toString(),
|
24693
24700
|
_e.toString()
|
24694
|
-
), he = V.micro_title && V.micro_title.length > 0,
|
24701
|
+
), he = V.micro_title && V.micro_title.length > 0, Ke = V.micro_description && V.micro_description.length > 0, je = he ? V.micro_title : V.title, Te = Ke ? V.micro_description : V.description;
|
24695
24702
|
return /* @__PURE__ */ t(
|
24696
24703
|
a0,
|
24697
24704
|
{
|
24698
|
-
ariaLabel: `${He}: ${
|
24705
|
+
ariaLabel: `${He}: ${je}, ${Te}`,
|
24699
24706
|
beat: V,
|
24700
24707
|
index: Ce,
|
24701
24708
|
isActiveCard: Ce === j,
|
@@ -26325,7 +26332,7 @@ const Gi = g.createContext(null), Yf = ({
|
|
26325
26332
|
dateRangeCategoryTotals: r,
|
26326
26333
|
dataRangeTotalsLoaded: o,
|
26327
26334
|
loadDateRangeCategoryTotals: s
|
26328
|
-
} =
|
26335
|
+
} = Ve(), c = g.useMemo(
|
26329
26336
|
() => [
|
26330
26337
|
e.palette.chartMono.chartMono5,
|
26331
26338
|
e.palette.chartMono.chartMono4,
|
@@ -26515,7 +26522,7 @@ const Gi = g.createContext(null), Yf = ({
|
|
26515
26522
|
selectedId: a,
|
26516
26523
|
title: r
|
26517
26524
|
}) => {
|
26518
|
-
const { isDesktop: o, isMobile: s } = De(), { isLoadingCategoryTotals: c } =
|
26525
|
+
const { isDesktop: o, isMobile: s } = De(), { isLoadingCategoryTotals: c } = Ve(), { spending: d } = I();
|
26519
26526
|
return /* @__PURE__ */ l(
|
26520
26527
|
b,
|
26521
26528
|
{
|
@@ -26566,7 +26573,7 @@ const Gi = g.createContext(null), Yf = ({
|
|
26566
26573
|
e.palette.chartMono.chartMono1,
|
26567
26574
|
e.palette.chartMono.chartMono6
|
26568
26575
|
], H0 = () => {
|
26569
|
-
const e = vn(), { categories: n, dateRangeCategoryTotals: i, loadDateRangeCategoryTotals: a } =
|
26576
|
+
const e = vn(), { categories: n, dateRangeCategoryTotals: i, loadDateRangeCategoryTotals: a } = Ve(), { spending: r } = I(), { displayedDateRange: o, selectedAccounts: s, selectedAccountGuids: c } = ce(), { setFilter: d, sortedTransactions: _ } = Se(), [u, h] = g.useState(""), [m, C] = g.useState(0), [f, E] = g.useState(""), [y, T] = g.useState(!1);
|
26570
26577
|
g.useEffect(() => {
|
26571
26578
|
a(
|
26572
26579
|
s,
|
@@ -26740,7 +26747,7 @@ const K0 = (e) => e.reduce((i, a) => {
|
|
26740
26747
|
return (i || 0) - (a || 0);
|
26741
26748
|
}, j0 = (e) => {
|
26742
26749
|
const n = e.row[e.field];
|
26743
|
-
return /* @__PURE__ */ t(b, { alignItems: "flex-end", tabIndex: e.tabIndex, children: /* @__PURE__ */ t(
|
26750
|
+
return /* @__PURE__ */ t(b, { alignItems: "flex-end", tabIndex: e.tabIndex, children: /* @__PURE__ */ t(ze, { amount: n, variant: "Small" }) });
|
26744
26751
|
}, X0 = ({ categoryGuid: e, topLevelCategoryGuid: n }) => {
|
26745
26752
|
const { categories: i } = I(), a = ga[e];
|
26746
26753
|
return /* @__PURE__ */ l(b, { alignItems: "center", direction: "row", justifyContent: "center", children: [
|
@@ -26876,7 +26883,7 @@ const K0 = (e) => e.reduce((i, a) => {
|
|
26876
26883
|
}, tb = A(eb), nb = {
|
26877
26884
|
view_transactions: "View Transactions"
|
26878
26885
|
}, ib = ({ onBackClick: e, sx: n }) => {
|
26879
|
-
const i = at(), { onEvent: a } = z(), { isDesktop: r, isTablet: o, isMobile: s } = De(), { visibleAccounts: c } = Re(), { loadMonthlyCategoryTotals: d, monthlyCategoryTotals: _, getCategoryName: u } =
|
26886
|
+
const i = at(), { onEvent: a } = z(), { isDesktop: r, isTablet: o, isMobile: s } = De(), { visibleAccounts: c } = Re(), { loadMonthlyCategoryTotals: d, monthlyCategoryTotals: _, getCategoryName: u } = Ve(), { sortedTransactions: h } = Se(), { isCopyLoaded: m, isInitialized: C, selectedAccounts: f, setSelectedAccounts: E } = ce(), { trends: y } = I(), T = i.palette.mode === "dark", [w, N] = g.useState(!1), [x, R] = g.useState(!1), [D, $] = g.useState("Chart"), [O, L] = g.useState(""), [U, H] = g.useState({
|
26880
26887
|
start: no(Xe(jt(/* @__PURE__ */ new Date(), 6)), 1),
|
26881
26888
|
end: Xe(/* @__PURE__ */ new Date())
|
26882
26889
|
});
|
@@ -26928,9 +26935,9 @@ const K0 = (e) => e.reduce((i, a) => {
|
|
26928
26935
|
L(Te), a(W.TRENDS_CLICK_LEGEND, { category: u(Te) });
|
26929
26936
|
}, he = (Te) => {
|
26930
26937
|
a(W.TRENDS_HOVER_LEGEND, { category: u(Te) });
|
26931
|
-
},
|
26938
|
+
}, Ke = (Te) => {
|
26932
26939
|
a(W.TRENDS_HOVER_AREA, { category: Te });
|
26933
|
-
},
|
26940
|
+
}, je = (Te) => {
|
26934
26941
|
a(W.TRENDS_HOVER_POINT, { category: Te });
|
26935
26942
|
};
|
26936
26943
|
return !m || !C || !w ? /* @__PURE__ */ t(ue, {}) : /* @__PURE__ */ l(
|
@@ -27031,9 +27038,9 @@ const K0 = (e) => e.reduce((i, a) => {
|
|
27031
27038
|
Gu,
|
27032
27039
|
{
|
27033
27040
|
onClickLegend: He,
|
27034
|
-
onHoverArea:
|
27041
|
+
onHoverArea: Ke,
|
27035
27042
|
onHoverLegend: he,
|
27036
|
-
onHoverPoint:
|
27043
|
+
onHoverPoint: je,
|
27037
27044
|
stackedDatasets: j.stackedDatasets,
|
27038
27045
|
unstackedDatasets: j.unstackedDatasets
|
27039
27046
|
}
|
@@ -27064,7 +27071,7 @@ const K0 = (e) => e.reduce((i, a) => {
|
|
27064
27071
|
}
|
27065
27072
|
);
|
27066
27073
|
}, VE = A(ib), ab = () => {
|
27067
|
-
const e = at(), { monthlyCategoryTotals: n } =
|
27074
|
+
const e = at(), { monthlyCategoryTotals: n } = Ve(), { trends: i } = I(), a = sm(n);
|
27068
27075
|
return /* @__PURE__ */ t(
|
27069
27076
|
br,
|
27070
27077
|
{
|
@@ -27080,7 +27087,7 @@ const K0 = (e) => e.reduce((i, a) => {
|
|
27080
27087
|
}
|
27081
27088
|
);
|
27082
27089
|
}, rb = A(ab), ob = ({ onPrimaryCtaClick: e, sx: n }) => {
|
27083
|
-
const { loadMonthlyCategoryTotals: i, monthlyTotalsLoaded: a } =
|
27090
|
+
const { loadMonthlyCategoryTotals: i, monthlyTotalsLoaded: a } = Ve(), { isInitialized: r } = ba(), { trends: o } = I(), { isCopyLoaded: s, selectedAccounts: c } = ce();
|
27084
27091
|
return g.useEffect(() => {
|
27085
27092
|
r && i(c).finally();
|
27086
27093
|
}, [r, c]), s ? /* @__PURE__ */ t(
|
@@ -27148,7 +27155,7 @@ export {
|
|
27148
27155
|
ht as ConnectionStatusEnums,
|
27149
27156
|
Xi as CurrencyCodes,
|
27150
27157
|
en as CurrencyInput,
|
27151
|
-
|
27158
|
+
ze as CurrencyText,
|
27152
27159
|
te as DATE_FORMATS_INTL,
|
27153
27160
|
ks as DEFAULT_DONUT_SIZE,
|
27154
27161
|
Gs as DEFAULT_STROKE_WIDTH,
|
@@ -27218,7 +27225,7 @@ export {
|
|
27218
27225
|
i1 as NotificationList,
|
27219
27226
|
Mc as NotificationSettings,
|
27220
27227
|
qp as NotificationStore,
|
27221
|
-
|
27228
|
+
Ue as NotificationType,
|
27222
27229
|
Ln as ORDINAL_DATE_FORMAT,
|
27223
27230
|
Z2 as ORDINAL_MONTH_DAY_YEAR_FORMAT,
|
27224
27231
|
pr as PAYMENT_ACCOUNT_TYPES,
|
@@ -27312,7 +27319,7 @@ export {
|
|
27312
27319
|
Ca as useAppConfig,
|
27313
27320
|
lt as useBudgetsStore,
|
27314
27321
|
Er as useCashflowStore,
|
27315
|
-
|
27322
|
+
Ve as useCategoryStore,
|
27316
27323
|
pn as useCategoryUiStore,
|
27317
27324
|
iu as useCombineEvents,
|
27318
27325
|
au as useCombinePageviews,
|