@mx-cartographer/experiences 7.2.13 → 7.2.14-alpha.san2
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/{Account-B-CuHOYf.mjs → Account-01wOyrH1.mjs} +1 -1
- package/dist/{AccountDetailsContent-bqByD9ea.mjs → AccountDetailsContent-C_ZRryuO.mjs} +10 -10
- package/dist/{AccountDetailsHeader-vcy67tuH.mjs → AccountDetailsHeader-D5h5tdeG.mjs} +8 -8
- package/dist/{AccountFields-cUP-9Hm6.mjs → AccountFields-CPkGZ3SD.mjs} +5 -5
- package/dist/{AccountListItem-DChcf3SN.mjs → AccountListItem-D4uG9yC-.mjs} +4 -4
- package/dist/{AccountStore-D6KiXA1B.mjs → AccountStore-DYwH7yC9.mjs} +40 -29
- package/dist/{Accounts-IeEtQjzA.mjs → Accounts-D7QljYas.mjs} +1 -1
- package/dist/{BudgetUtil-B2ZXyw-g.mjs → BudgetUtil-wjoNuj7B.mjs} +1 -1
- package/dist/{CategorySelectorDrawer-DUe4lH5-.mjs → CategorySelectorDrawer-ZO9N26Kx.mjs} +3 -3
- package/dist/{CategoryStore-BCcpI3oJ.mjs → CategoryStore-C1IfDPCE.mjs} +1 -1
- package/dist/{CategoryUtil-BR3H5i6n.mjs → CategoryUtil-DUM8NuGO.mjs} +1 -1
- package/dist/{ConnectDrawer-DaFRU5st.mjs → ConnectDrawer-CuUj16NH.mjs} +3 -2
- package/dist/{ConnectionsDrawer-DHJ7qdWL.mjs → ConnectionsDrawer-Bz4uwdFE.mjs} +14 -13
- package/dist/{CurrencyInput-DUsQbkXb.mjs → CurrencyInput-xH-hqry9.mjs} +1 -1
- package/dist/{DateUtil-BcuH7ErC.mjs → DateUtil-CBdcsyuk.mjs} +3 -3
- package/dist/{DebtsStore-z3VARSO6.mjs → DebtsStore-Bu8rRRSL.mjs} +1 -1
- package/dist/{Dialog-CWW597AF.mjs → Dialog-BPTr3qHE.mjs} +2 -2
- package/dist/Drawer-BEtCk82g.mjs +163 -0
- package/dist/{EmptyState-DA_lfRBv.mjs → EmptyState-DoxNUae-.mjs} +24 -22
- package/dist/{ExportCsvAction-sX8Rg4Ov.mjs → ExportCsvAction-DlGZfm4y.mjs} +3 -3
- package/dist/FinstrongStore-bkPQR8ln.mjs +432 -0
- package/dist/{GoalStore-TD0BfzWX.mjs → GoalStore-Dcnj5pii.mjs} +3 -3
- package/dist/{Help-B6dIcujh.mjs → Help-BnPXM_N2.mjs} +2 -2
- package/dist/{LineChart-D4GI7nVh.mjs → LineChart-Ct9DNmhS.mjs} +209 -181
- package/dist/{ListItemAction-DHa3KJPs.mjs → ListItemAction-uobBrm_a.mjs} +10 -10
- package/dist/{ManageIncome-CQPFKdYB.mjs → ManageIncome-C3bINPG2.mjs} +63 -61
- package/dist/{MicroWidgetContainer-DpeqN9n3.mjs → MicroWidgetContainer-DEiRnYVa.mjs} +1 -1
- package/dist/{MiniWidgetContainer-D0gfmbaF.mjs → MiniWidgetContainer-CmXpTylX.mjs} +1 -1
- package/dist/{NetWorthStore-B_1oulrt.mjs → NetWorthStore-CpL_kqvx.mjs} +2 -2
- package/dist/{NotificationSettings-DqrkNMod.mjs → NotificationSettings-BKKuULAd.mjs} +5 -5
- package/dist/{OriginalBalanceAction-CWuVvRq9.mjs → OriginalBalanceAction-CCmnsd7y.mjs} +3 -3
- package/dist/{RecurringSettings-DDaGTnfz.mjs → RecurringSettings-B_mCFQhb.mjs} +4 -4
- package/dist/{RecurringTransactions-ej39mgA6.mjs → RecurringTransactions-CngsRZ3K.mjs} +45 -44
- package/dist/{RecurringTransactionsStore-DrzS1LmF.mjs → RecurringTransactionsStore-C4RVULF8.mjs} +1 -1
- package/dist/{SpendingData-D5vsfYKo.mjs → SpendingData-BuJ03S9d.mjs} +16 -16
- package/dist/SpendingLegend-CW8mIzqd.mjs +196 -0
- package/dist/{TransactionDetails-DW7T0W0z.mjs → TransactionDetails-CaJruWq3.mjs} +11 -8
- package/dist/{TransactionStore-DxPLdF3B.mjs → TransactionStore-DvOEbOzL.mjs} +3 -3
- package/dist/{TrendsStore-DCYbpXPO.mjs → TrendsStore-BVNxGsE4.mjs} +14 -14
- package/dist/{User-BQUxBeZV.mjs → User-wXzDI4M8.mjs} +2 -2
- package/dist/{WidgetContainer-C88Ecu2W.mjs → WidgetContainer-6dsjtOVg.mjs} +4 -4
- package/dist/accounts/components/AccountsListCompact.d.ts +10 -0
- package/dist/accounts/index.es.js +14 -14
- package/dist/accounts/stores/AccountStore.d.ts +2 -0
- package/dist/analytics/index.es.js +2 -2
- package/dist/budgets/index.es.js +13 -13
- package/dist/cashflow/index.es.js +45 -45
- package/dist/categories/index.es.js +2 -2
- package/dist/common/components/Select.d.ts +4 -2
- package/dist/common/components/charts/LineChart.d.ts +8 -2
- package/dist/common/components/charts/linechart/CustomMark.d.ts +4 -0
- package/dist/common/components/drawer/Drawer.d.ts +3 -0
- package/dist/common/components/drawer/Footer.d.ts +17 -0
- package/dist/common/index.es.js +34 -34
- package/dist/common/types/Finstrong.d.ts +50 -0
- package/dist/common/types/Widgets.d.ts +1 -0
- package/dist/common/types/index.d.ts +1 -1
- package/dist/common/types/localization/FinstrongCopy.d.ts +58 -1
- package/dist/dashboard/index.es.js +2 -2
- package/dist/debts/index.es.js +11 -11
- package/dist/{exportTransactionsToCSV-7bVS7KXf.mjs → exportTransactionsToCSV-hrNpJ77n.mjs} +2 -2
- package/dist/finstrong/FinstrongWidget.d.ts +1 -1
- package/dist/finstrong/api/FinstrongApi.d.ts +5 -0
- package/dist/finstrong/components/ConnectMoreAccountsCard.d.ts +3 -1
- package/dist/finstrong/components/CreditScore/CreditScoreContent.d.ts +4 -0
- package/dist/finstrong/components/CreditScore/CreditScoreHeader.d.ts +4 -0
- package/dist/finstrong/components/HaveManageableDebt/DebtPaymentTabContent.d.ts +3 -0
- package/dist/finstrong/components/HaveManageableDebt/HaveManageableDebtComponent.d.ts +3 -0
- package/dist/finstrong/components/HaveManageableDebt/HaveManageableDebtProgressBar.d.ts +4 -0
- package/dist/finstrong/components/HaveManageableDebt/IncomeTabContent.d.ts +3 -0
- package/dist/finstrong/components/KeyIndicatorsBorrowTab.d.ts +2 -2
- package/dist/finstrong/components/KeyIndicatorsDrawer.d.ts +4 -1
- package/dist/finstrong/components/KeyIndicatorsSaveTab.d.ts +2 -2
- package/dist/finstrong/components/KeyIndicatorsSpendTab.d.ts +5 -2
- package/dist/finstrong/components/KeyIndicatorsTabItem.d.ts +5 -3
- package/dist/finstrong/components/KeyIndicatorsTabItemDrawer.d.ts +11 -0
- package/dist/finstrong/components/KeyIndicatorsTabsWidget.d.ts +5 -2
- package/dist/finstrong/components/MaintainingEmergencySavings/EstimatedContributionCalculator.d.ts +6 -0
- package/dist/finstrong/components/MaintainingEmergencySavings/MaintainingEmergencySavingsContent.d.ts +4 -0
- package/dist/finstrong/components/MaintainingEmergencySavings/MaintainingEmergencySavingsSticky.d.ts +4 -0
- package/dist/finstrong/components/ProgressBar.d.ts +15 -0
- package/dist/finstrong/components/SaveEnoughToLiveOn/AvailableTabContent.d.ts +3 -0
- package/dist/finstrong/components/SaveEnoughToLiveOn/SaveEnoughToLiveOnDrawerContent.d.ts +3 -0
- package/dist/finstrong/components/SaveEnoughToLiveOn/SaveEnoughToLiveOnProgressBar.d.ts +4 -0
- package/dist/finstrong/components/SaveEnoughToLiveOn/SpendingTabContent.d.ts +3 -0
- package/dist/finstrong/components/SpendLessThanYouMake/SpendLessThanYouMakeComponent.d.ts +6 -0
- package/dist/finstrong/components/SpendLessThanYouMake/SpendLessThanYouMakeProgressBar.d.ts +4 -0
- package/dist/finstrong/components/StatusChip.d.ts +5 -0
- package/dist/finstrong/components/onboarding/Onboarding.d.ts +2 -0
- package/dist/finstrong/components/onboarding/OnboardingAddMonthlyIncome.d.ts +17 -0
- package/dist/finstrong/components/onboarding/OnboardingBirthday.d.ts +8 -0
- package/dist/finstrong/components/onboarding/OnboardingCreditScore.d.ts +8 -0
- package/dist/finstrong/components/onboarding/OnboardingStepsDrawer.d.ts +14 -0
- package/dist/finstrong/components/onboarding/OnboardingStepsHeader.d.ts +8 -0
- package/dist/finstrong/components/paybillsontime/PayBillsOnTimeDrawerComponent.d.ts +4 -0
- package/dist/finstrong/components/paybillsontime/PayBillsOnTimeStickyComponent.d.ts +4 -0
- package/dist/finstrong/components/shared/Accounts.d.ts +8 -0
- package/dist/finstrong/components/shared/CustomDoubleBarPlot.d.ts +25 -0
- package/dist/finstrong/components/shared/DoubleBarChart.d.ts +28 -0
- package/dist/finstrong/components/shared/LineGraph.d.ts +7 -0
- package/dist/finstrong/components/shared/TotalCard.d.ts +8 -0
- package/dist/finstrong/components/shared/TransactionList.d.ts +15 -0
- package/dist/finstrong/components/shared/Transactions.d.ts +11 -0
- package/dist/finstrong/constants/index.d.ts +8 -0
- package/dist/finstrong/index.es.js +3189 -1060
- package/dist/finstrong/stores/FinstrongStore.d.ts +9 -1
- package/dist/finstrong/util/finstrongUtils.d.ts +58 -1
- package/dist/goals/index.es.js +15 -15
- package/dist/help/index.es.js +3 -3
- package/dist/{hooks-D6XlXHf4.mjs → hooks-C41HAxM5.mjs} +3 -3
- package/dist/investments/index.es.js +5 -5
- package/dist/merchants/index.es.js +1 -1
- package/dist/networth/index.es.js +35 -35
- package/dist/notifications/index.es.js +4 -4
- package/dist/recurringtransactions/index.es.js +13 -13
- package/dist/settings/index.es.js +8 -8
- package/dist/spending/index.es.js +238 -415
- package/dist/transactions/index.es.js +15 -15
- package/dist/trends/index.es.js +95 -95
- package/dist/{useAccountDisplayName-BcRqfar8.mjs → useAccountDisplayName-CMMlIOXF.mjs} +2 -2
- package/dist/{useInsightsEnabled-DBpwEq10.mjs → useInsightsEnabled-CNjP5cfR.mjs} +1 -1
- package/package.json +1 -1
- package/dist/Drawer-kEE73B87.mjs +0 -113
- package/dist/FinstrongStore-F2c607dj.mjs +0 -101
- package/dist/finstrong/utils/Finstrong.d.ts +0 -6
|
@@ -1,218 +1,41 @@
|
|
|
1
|
-
import { jsxs as
|
|
2
|
-
import
|
|
3
|
-
import { observer as
|
|
4
|
-
import { startOfMonth as
|
|
5
|
-
import { endOfMonth as
|
|
6
|
-
import
|
|
7
|
-
import
|
|
8
|
-
import
|
|
9
|
-
import
|
|
10
|
-
import
|
|
11
|
-
import { b as
|
|
12
|
-
import {
|
|
13
|
-
import {
|
|
14
|
-
import {
|
|
15
|
-
import {
|
|
16
|
-
import
|
|
17
|
-
import {
|
|
18
|
-
import {
|
|
19
|
-
import {
|
|
20
|
-
import
|
|
21
|
-
import { L as F } from "../Loader-DUaFpDGv.mjs";
|
|
22
|
-
import { M as Mt } from "../MiniWidgetContainer-D0gfmbaF.mjs";
|
|
23
|
-
import { startOfToday as U } from "date-fns/startOfToday";
|
|
24
|
-
import { T as Dt, a as xt } from "../TransactionDetails-DW7T0W0z.mjs";
|
|
25
|
-
import wt from "@mui/material/Collapse";
|
|
1
|
+
import { jsxs as d, jsx as t } from "react/jsx-runtime";
|
|
2
|
+
import a from "react";
|
|
3
|
+
import { observer as D } from "mobx-react-lite";
|
|
4
|
+
import { startOfMonth as tt } from "date-fns/startOfMonth";
|
|
5
|
+
import { endOfMonth as et } from "date-fns/endOfMonth";
|
|
6
|
+
import T from "@mui/material/Box";
|
|
7
|
+
import S from "@mui/material/Stack";
|
|
8
|
+
import W from "@mui/material/Tab";
|
|
9
|
+
import nt from "@mui/material/Tabs";
|
|
10
|
+
import dt from "@mui/material/styles/useTheme";
|
|
11
|
+
import { g as ot, a as at, S as N, b as U } from "../SpendingLegend-CW8mIzqd.mjs";
|
|
12
|
+
import { Text as y } from "@mxenabled/mxui";
|
|
13
|
+
import { f as E } from "../NumberFormatting-Buh7u8Oi.mjs";
|
|
14
|
+
import { u as w, b as O, m as j, d as it, a as rt, h as gt, g as pt } from "../hooks-C41HAxM5.mjs";
|
|
15
|
+
import { L as z } from "../Loader-DUaFpDGv.mjs";
|
|
16
|
+
import { M as ut } from "../MiniWidgetContainer-CmXpTylX.mjs";
|
|
17
|
+
import { startOfToday as X } from "date-fns/startOfToday";
|
|
18
|
+
import { useTheme as mt } from "@mui/material";
|
|
19
|
+
import { T as ht, a as ft } from "../TransactionDetails-CaJruWq3.mjs";
|
|
20
|
+
import bt from "@mui/material/Collapse";
|
|
26
21
|
import B from "@mui/material/Divider";
|
|
27
|
-
import
|
|
28
|
-
import
|
|
29
|
-
import
|
|
30
|
-
import {
|
|
31
|
-
import {
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
u ? (u.amount += a.total, u.categoryTotals?.push(d)) : l.push({
|
|
45
|
-
guid: o,
|
|
46
|
-
name: e.name,
|
|
47
|
-
color: V(e.guid, c),
|
|
48
|
-
categoryTotals: [d],
|
|
49
|
-
amount: a.total
|
|
50
|
-
});
|
|
51
|
-
}
|
|
52
|
-
return l;
|
|
53
|
-
}, []), ct = (n, c, r, l) => {
|
|
54
|
-
const a = Et(n, r, l), i = a.filter(
|
|
55
|
-
(s) => s.guid !== S.INCOME && s.guid !== S.INVESTMENTS && s.guid !== S.TRANSFER
|
|
56
|
-
).sort((s, m) => m.amount - s.amount), o = i.reduce(
|
|
57
|
-
(s, m) => s + m.amount,
|
|
58
|
-
0
|
|
59
|
-
), e = i.length > j ? j : i.length, d = i.slice(0, e), u = d.map((s) => ({
|
|
60
|
-
id: s.guid,
|
|
61
|
-
color: V(s.guid, r),
|
|
62
|
-
label: s.name,
|
|
63
|
-
value: s.amount / o * 100
|
|
64
|
-
}));
|
|
65
|
-
if (i.length > 5) {
|
|
66
|
-
const s = i.slice(j, a.length), m = s.reduce(
|
|
67
|
-
(T, g) => T + g.amount,
|
|
68
|
-
0
|
|
69
|
-
);
|
|
70
|
-
d.push({
|
|
71
|
-
guid: "other",
|
|
72
|
-
color: r.palette.categories.others || "",
|
|
73
|
-
name: c.saving_goal_other,
|
|
74
|
-
categoryTotals: s,
|
|
75
|
-
amount: m
|
|
76
|
-
}), u.push({
|
|
77
|
-
id: "other",
|
|
78
|
-
color: r.palette.categories.others || "",
|
|
79
|
-
label: c.saving_goal_other,
|
|
80
|
-
value: m / o * 100
|
|
81
|
-
});
|
|
82
|
-
}
|
|
83
|
-
return {
|
|
84
|
-
categoryData: d,
|
|
85
|
-
donutData: u,
|
|
86
|
-
totalAmount: o
|
|
87
|
-
};
|
|
88
|
-
}, dt = (n, c, r) => {
|
|
89
|
-
const l = n.filter(
|
|
90
|
-
(e) => e.guid === S.INCOME || e.parent_guid === S.INCOME
|
|
91
|
-
), a = c.filter((e) => l.some((d) => d.guid === e.category_guid)).sort((e, d) => e.total - d.total).map((e, d) => ({
|
|
92
|
-
guid: e.category_guid,
|
|
93
|
-
name: n.find((u) => u.guid === e.category_guid)?.name,
|
|
94
|
-
color: r[d],
|
|
95
|
-
categoryTotals: [],
|
|
96
|
-
amount: Math.abs(e.total)
|
|
97
|
-
})), i = a.reduce(
|
|
98
|
-
(e, d) => e + d.amount,
|
|
99
|
-
0
|
|
100
|
-
), o = a.map((e) => ({
|
|
101
|
-
id: e.guid,
|
|
102
|
-
color: e.color,
|
|
103
|
-
label: e.name,
|
|
104
|
-
value: e.amount / i * 100
|
|
105
|
-
}));
|
|
106
|
-
return {
|
|
107
|
-
categoryData: a,
|
|
108
|
-
donutData: o,
|
|
109
|
-
totalAmount: i
|
|
110
|
-
};
|
|
111
|
-
}, W = ({ amount: n, label: c }) => /* @__PURE__ */ h(C, { direction: "column", children: [
|
|
112
|
-
/* @__PURE__ */ t(y, { bold: !0, sx: { textTransform: "none" }, variant: "Body", children: c }),
|
|
113
|
-
/* @__PURE__ */ t(y, { variant: "XSmall", children: w(n, "0,0") })
|
|
114
|
-
] }), At = ({
|
|
115
|
-
data: n,
|
|
116
|
-
isIncome: c = !1,
|
|
117
|
-
onSelected: r,
|
|
118
|
-
onViewTransactions: l,
|
|
119
|
-
selectedId: a,
|
|
120
|
-
size: i = 150,
|
|
121
|
-
totalLabel: o,
|
|
122
|
-
variant: e = "mini"
|
|
123
|
-
}) => {
|
|
124
|
-
const { spending: d } = I(), u = it(), { isTablet: s } = lt(), { announce: m, ariaLive: T } = bt(), g = p.useMemo(
|
|
125
|
-
() => a ? n.categoryData.find((D) => D.guid === a) : void 0,
|
|
126
|
-
[a]
|
|
127
|
-
);
|
|
128
|
-
p.useEffect(() => {
|
|
129
|
-
if (g) {
|
|
130
|
-
const D = w(g.amount, "0,0");
|
|
131
|
-
m(`${g.name}: ${D}`);
|
|
132
|
-
}
|
|
133
|
-
}, [g, m]);
|
|
134
|
-
const b = p.useMemo(() => n.donutData.length > 0 ? n.donutData : [{ id: "0", color: u.palette.divider, value: 100 }], [n, u]), E = () => {
|
|
135
|
-
l?.(a);
|
|
136
|
-
}, _ = s ? 32 : 48;
|
|
137
|
-
return /* @__PURE__ */ h(mt, { children: [
|
|
138
|
-
T,
|
|
139
|
-
/* @__PURE__ */ t(Tt, { data: b, onClick: r, selectedId: a, size: i, children: /* @__PURE__ */ t(C, { alignItems: "center", height: "100%", justifyContent: "center", width: "100%", children: /* @__PURE__ */ h(C, { alignItems: "center", justifyContent: "center", minHeight: i, minWidth: i, children: [
|
|
140
|
-
g && /* @__PURE__ */ h(
|
|
141
|
-
C,
|
|
142
|
-
{
|
|
143
|
-
alignItems: "center",
|
|
144
|
-
gap: e === "mini" ? 0 : 8,
|
|
145
|
-
mb: e === "mini" ? 0 : 8,
|
|
146
|
-
mt: e === "mini" ? 0 : -16,
|
|
147
|
-
sx: e === "mini" ? { gap: 0, mb: 0 } : { gap: { xs: 4, xl: 8 }, mb: { xs: 4, xl: 8 } },
|
|
148
|
-
children: [
|
|
149
|
-
/* @__PURE__ */ t(
|
|
150
|
-
ft,
|
|
151
|
-
{
|
|
152
|
-
categoryGuid: c ? S.INCOME : g.guid,
|
|
153
|
-
size: e === "mini" ? 24 : _,
|
|
154
|
-
variant: yt.Transparent
|
|
155
|
-
}
|
|
156
|
-
),
|
|
157
|
-
/* @__PURE__ */ t(
|
|
158
|
-
y,
|
|
159
|
-
{
|
|
160
|
-
color: "secondary",
|
|
161
|
-
noWrap: !0,
|
|
162
|
-
variant: e === "mini" ? "Tiny" : "Body",
|
|
163
|
-
children: g ? g.name : o
|
|
164
|
-
}
|
|
165
|
-
)
|
|
166
|
-
]
|
|
167
|
-
}
|
|
168
|
-
),
|
|
169
|
-
!g && e === "full" && /* @__PURE__ */ t(y, { bold: !0, color: "secondary", sx: { mb: { xs: 4, xl: 8 } }, children: o }),
|
|
170
|
-
/* @__PURE__ */ t(y, { variant: e === "mini" ? "H2" : "H1", children: g ? w(g.amount, "0,0") : w(n.totalAmount, "0,0") }),
|
|
171
|
-
!g && e === "mini" && /* @__PURE__ */ t(y, { color: "secondary", noWrap: !0, variant: "Tiny", children: o }),
|
|
172
|
-
e === "full" && /* @__PURE__ */ t(
|
|
173
|
-
Ct,
|
|
174
|
-
{
|
|
175
|
-
"aria-label": `View ${g?.name || ""} Transactions`,
|
|
176
|
-
disabled: n.categoryData.length === 0,
|
|
177
|
-
onClick: E,
|
|
178
|
-
sx: { mt: { xl: 4, xs: 0 }, zIndex: 1 },
|
|
179
|
-
variant: "text",
|
|
180
|
-
children: d.view_transactions
|
|
181
|
-
}
|
|
182
|
-
)
|
|
183
|
-
] }) }) })
|
|
184
|
-
] });
|
|
185
|
-
}, O = v(At), tt = ({ data: n, onSelected: c, selectedId: r }) => {
|
|
186
|
-
const l = (a, i) => {
|
|
187
|
-
(a.key === "Enter" || a.key === " ") && (a.preventDefault(), c(i));
|
|
188
|
-
};
|
|
189
|
-
return /* @__PURE__ */ t(C, { gap: 8, height: "100%", justifyContent: "center", my: "auto", children: n.categoryData.map((a) => /* @__PURE__ */ h(
|
|
190
|
-
C,
|
|
191
|
-
{
|
|
192
|
-
alignItems: "center",
|
|
193
|
-
"aria-label": a.name,
|
|
194
|
-
"aria-pressed": a.guid === r,
|
|
195
|
-
direction: "row",
|
|
196
|
-
gap: 8,
|
|
197
|
-
onClick: () => c(a.guid),
|
|
198
|
-
onKeyDown: (i) => l(i, a.guid),
|
|
199
|
-
role: "button",
|
|
200
|
-
sx: { cursor: "pointer" },
|
|
201
|
-
tabIndex: 0,
|
|
202
|
-
children: [
|
|
203
|
-
/* @__PURE__ */ t(x, { borderRadius: 4, height: 8, sx: { backgroundColor: a.color }, width: 8 }),
|
|
204
|
-
/* @__PURE__ */ t(y, { bold: a.guid === r, variant: "XSmall", children: a.name })
|
|
205
|
-
]
|
|
206
|
-
},
|
|
207
|
-
a.guid
|
|
208
|
-
)) });
|
|
209
|
-
}, Lt = () => {
|
|
210
|
-
const n = ht(), { goals: c, spending: r } = I(), { selectedAccounts: l } = R(), {
|
|
211
|
-
categories: a,
|
|
212
|
-
dateRangeCategoryTotals: i,
|
|
213
|
-
dataRangeTotalsLoaded: o,
|
|
214
|
-
loadDateRangeCategoryTotals: e
|
|
215
|
-
} = z(), d = p.useMemo(
|
|
22
|
+
import Y from "@mui/material/List";
|
|
23
|
+
import q from "@mui/material/ListItem";
|
|
24
|
+
import _t from "@mui/material/ListItemButton";
|
|
25
|
+
import { u as yt } from "../useScreenSize-B6JyS_Lj.mjs";
|
|
26
|
+
import { D as J } from "../Drawer-BEtCk82g.mjs";
|
|
27
|
+
import { b as L } from "../Category-CevNQ03n.mjs";
|
|
28
|
+
import { A as Q, W as Ct } from "../WidgetContainer-6dsjtOVg.mjs";
|
|
29
|
+
const R = ({ amount: n, label: s }) => /* @__PURE__ */ d(S, { direction: "column", children: [
|
|
30
|
+
/* @__PURE__ */ t(y, { bold: !0, sx: { textTransform: "none" }, variant: "Body", children: s }),
|
|
31
|
+
/* @__PURE__ */ t(y, { variant: "XSmall", children: E(n, "0,0") })
|
|
32
|
+
] }), St = () => {
|
|
33
|
+
const n = dt(), { goals: s, spending: o } = w(), { selectedAccounts: i } = O(), {
|
|
34
|
+
categories: c,
|
|
35
|
+
dateRangeCategoryTotals: r,
|
|
36
|
+
dataRangeTotalsLoaded: e,
|
|
37
|
+
loadDateRangeCategoryTotals: l
|
|
38
|
+
} = j(), u = a.useMemo(
|
|
216
39
|
() => [
|
|
217
40
|
n.palette.chartMono.chartMono5,
|
|
218
41
|
n.palette.chartMono.chartMono4,
|
|
@@ -223,171 +46,171 @@ const j = 5, Et = (n, c, r) => r.reduce((l, a) => {
|
|
|
223
46
|
],
|
|
224
47
|
[n]
|
|
225
48
|
);
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
49
|
+
a.useEffect(() => {
|
|
50
|
+
l(
|
|
51
|
+
i,
|
|
52
|
+
tt(/* @__PURE__ */ new Date()),
|
|
53
|
+
et(/* @__PURE__ */ new Date())
|
|
231
54
|
).finally();
|
|
232
|
-
}, [
|
|
233
|
-
const [
|
|
234
|
-
() =>
|
|
235
|
-
[
|
|
236
|
-
),
|
|
237
|
-
() =>
|
|
238
|
-
[
|
|
239
|
-
),
|
|
240
|
-
|
|
241
|
-
}, _ = (
|
|
242
|
-
|
|
55
|
+
}, [i]);
|
|
56
|
+
const [m, p] = a.useState(""), [h, M] = a.useState(0), C = a.useMemo(
|
|
57
|
+
() => ot(c, s, n, r),
|
|
58
|
+
[c, r]
|
|
59
|
+
), f = a.useMemo(
|
|
60
|
+
() => at(c, r, u),
|
|
61
|
+
[c, r, u]
|
|
62
|
+
), A = (x, I) => {
|
|
63
|
+
M(I), p("");
|
|
64
|
+
}, _ = (x) => {
|
|
65
|
+
p(m === x ? "" : x);
|
|
243
66
|
};
|
|
244
|
-
return
|
|
245
|
-
/* @__PURE__ */
|
|
246
|
-
|
|
67
|
+
return e ? /* @__PURE__ */ d(T, { width: "100%", children: [
|
|
68
|
+
/* @__PURE__ */ d(
|
|
69
|
+
nt,
|
|
247
70
|
{
|
|
248
|
-
"aria-label":
|
|
249
|
-
onChange:
|
|
250
|
-
value:
|
|
71
|
+
"aria-label": o.mini_title,
|
|
72
|
+
onChange: A,
|
|
73
|
+
value: h,
|
|
251
74
|
variant: "fullWidth",
|
|
252
75
|
children: [
|
|
253
76
|
/* @__PURE__ */ t(
|
|
254
|
-
|
|
77
|
+
W,
|
|
255
78
|
{
|
|
256
79
|
"aria-controls": "spending-tabpanel",
|
|
257
80
|
id: "spending-tab",
|
|
258
81
|
label: /* @__PURE__ */ t(
|
|
259
|
-
|
|
82
|
+
R,
|
|
260
83
|
{
|
|
261
|
-
amount:
|
|
262
|
-
label:
|
|
84
|
+
amount: C.totalAmount,
|
|
85
|
+
label: o.spend_tab_title
|
|
263
86
|
}
|
|
264
87
|
),
|
|
265
|
-
tabIndex:
|
|
88
|
+
tabIndex: h === 0 ? 0 : -1
|
|
266
89
|
}
|
|
267
90
|
),
|
|
268
91
|
/* @__PURE__ */ t(
|
|
269
|
-
|
|
92
|
+
W,
|
|
270
93
|
{
|
|
271
94
|
"aria-controls": "income-tabpanel",
|
|
272
95
|
id: "income-tab",
|
|
273
96
|
label: /* @__PURE__ */ t(
|
|
274
|
-
|
|
97
|
+
R,
|
|
275
98
|
{
|
|
276
|
-
amount:
|
|
277
|
-
label:
|
|
99
|
+
amount: f.totalAmount,
|
|
100
|
+
label: o.income_tab_title
|
|
278
101
|
}
|
|
279
102
|
),
|
|
280
|
-
tabIndex:
|
|
103
|
+
tabIndex: h === 1 ? 0 : -1
|
|
281
104
|
}
|
|
282
105
|
)
|
|
283
106
|
]
|
|
284
107
|
}
|
|
285
108
|
),
|
|
286
109
|
/* @__PURE__ */ t(
|
|
287
|
-
|
|
110
|
+
T,
|
|
288
111
|
{
|
|
289
112
|
"aria-labelledby": "spending-tab",
|
|
290
|
-
hidden:
|
|
113
|
+
hidden: h !== 0,
|
|
291
114
|
id: "spending-tabpanel",
|
|
292
115
|
role: "tabpanel",
|
|
293
|
-
children: /* @__PURE__ */
|
|
116
|
+
children: /* @__PURE__ */ d(S, { direction: "row", gap: 16, justifyContent: "center", p: 24, children: [
|
|
294
117
|
/* @__PURE__ */ t(
|
|
295
|
-
|
|
118
|
+
N,
|
|
296
119
|
{
|
|
297
|
-
data:
|
|
120
|
+
data: C,
|
|
298
121
|
onSelected: _,
|
|
299
|
-
selectedId:
|
|
300
|
-
totalLabel:
|
|
122
|
+
selectedId: m,
|
|
123
|
+
totalLabel: o.total_spending
|
|
301
124
|
}
|
|
302
125
|
),
|
|
303
|
-
/* @__PURE__ */ t(
|
|
126
|
+
/* @__PURE__ */ t(U, { data: C, onSelected: _, selectedId: m })
|
|
304
127
|
] })
|
|
305
128
|
}
|
|
306
129
|
),
|
|
307
130
|
/* @__PURE__ */ t(
|
|
308
|
-
|
|
131
|
+
T,
|
|
309
132
|
{
|
|
310
133
|
"aria-labelledby": "income-tab",
|
|
311
|
-
hidden:
|
|
134
|
+
hidden: h !== 1,
|
|
312
135
|
id: "income-tabpanel",
|
|
313
136
|
role: "tabpanel",
|
|
314
|
-
children: /* @__PURE__ */
|
|
137
|
+
children: /* @__PURE__ */ d(S, { direction: "row", gap: 16, justifyContent: "center", p: 24, children: [
|
|
315
138
|
/* @__PURE__ */ t(
|
|
316
|
-
|
|
139
|
+
N,
|
|
317
140
|
{
|
|
318
|
-
data:
|
|
141
|
+
data: f,
|
|
319
142
|
isIncome: !0,
|
|
320
143
|
onSelected: _,
|
|
321
|
-
selectedId:
|
|
322
|
-
totalLabel:
|
|
144
|
+
selectedId: m,
|
|
145
|
+
totalLabel: o.total_income
|
|
323
146
|
}
|
|
324
147
|
),
|
|
325
|
-
/* @__PURE__ */ t(
|
|
148
|
+
/* @__PURE__ */ t(U, { data: f, onSelected: _, selectedId: m })
|
|
326
149
|
] })
|
|
327
150
|
}
|
|
328
151
|
)
|
|
329
|
-
] }) : /* @__PURE__ */ t(
|
|
330
|
-
},
|
|
331
|
-
const { visibleAccounts:
|
|
332
|
-
return
|
|
333
|
-
o
|
|
334
|
-
}, [
|
|
335
|
-
|
|
152
|
+
] }) : /* @__PURE__ */ t(z, { height: 250 });
|
|
153
|
+
}, Mt = D(St), Tt = ({ onPrimaryCtaClick: n, sx: s = {} }) => {
|
|
154
|
+
const { visibleAccounts: o } = it(), { spending: i } = w(), { isCopyLoaded: c, isInitialized: r, setSelectedAccounts: e } = O();
|
|
155
|
+
return a.useEffect(() => {
|
|
156
|
+
e(o);
|
|
157
|
+
}, [o]), !c || !r ? /* @__PURE__ */ t(z, {}) : /* @__PURE__ */ t(
|
|
158
|
+
ut,
|
|
336
159
|
{
|
|
337
160
|
className: "mx-exp-spending-miniwidget",
|
|
338
161
|
onPrimaryCtaClick: n,
|
|
339
|
-
primaryCtaLabel:
|
|
340
|
-
sx:
|
|
341
|
-
title:
|
|
342
|
-
children: /* @__PURE__ */ t(
|
|
162
|
+
primaryCtaLabel: i.primary_cta,
|
|
163
|
+
sx: s,
|
|
164
|
+
title: i.mini_title,
|
|
165
|
+
children: /* @__PURE__ */ t(Mt, {})
|
|
343
166
|
}
|
|
344
167
|
);
|
|
345
|
-
},
|
|
168
|
+
}, ie = D(Tt), Dt = ({
|
|
346
169
|
data: n,
|
|
347
|
-
onSelected:
|
|
348
|
-
selectedId:
|
|
349
|
-
title:
|
|
170
|
+
onSelected: s,
|
|
171
|
+
selectedId: o = "",
|
|
172
|
+
title: i
|
|
350
173
|
}) => {
|
|
351
|
-
const { spending:
|
|
352
|
-
return /* @__PURE__ */
|
|
353
|
-
/* @__PURE__ */ t(y, { bold: !0, sx: { py: 12 }, children: `${
|
|
174
|
+
const { spending: c } = w(), r = n.categoryData.find((e) => e.guid === o);
|
|
175
|
+
return /* @__PURE__ */ d(S, { direction: "column", justifyContent: "center", maxWidth: 400, minWidth: 275, width: "100%", children: [
|
|
176
|
+
/* @__PURE__ */ t(y, { bold: !0, sx: { py: 12 }, children: `${i} ${c.by_category}` }),
|
|
354
177
|
/* @__PURE__ */ t(B, { "aria-hidden": "true" }),
|
|
355
|
-
/* @__PURE__ */ t(
|
|
178
|
+
/* @__PURE__ */ t(Y, { children: n.categoryData.map((e) => /* @__PURE__ */ d(a.Fragment, { children: [
|
|
356
179
|
/* @__PURE__ */ t(
|
|
357
|
-
|
|
180
|
+
q,
|
|
358
181
|
{
|
|
359
182
|
disableGutters: !0,
|
|
360
183
|
disablePadding: !0,
|
|
361
184
|
sx: {
|
|
362
185
|
minHeight: 44
|
|
363
186
|
},
|
|
364
|
-
children: /* @__PURE__ */
|
|
365
|
-
|
|
187
|
+
children: /* @__PURE__ */ d(
|
|
188
|
+
_t,
|
|
366
189
|
{
|
|
367
|
-
"aria-expanded":
|
|
368
|
-
onClick: () =>
|
|
190
|
+
"aria-expanded": r?.guid === e.guid,
|
|
191
|
+
onClick: () => s(e.guid),
|
|
369
192
|
sx: { minHeight: 44, px: 8, py: 0 },
|
|
370
193
|
children: [
|
|
371
194
|
/* @__PURE__ */ t(
|
|
372
|
-
|
|
195
|
+
T,
|
|
373
196
|
{
|
|
374
197
|
borderRadius: 4,
|
|
375
198
|
flexShrink: 0,
|
|
376
199
|
height: 8,
|
|
377
|
-
sx: { backgroundColor:
|
|
200
|
+
sx: { backgroundColor: e.color, mr: 8 },
|
|
378
201
|
width: 8
|
|
379
202
|
}
|
|
380
203
|
),
|
|
381
|
-
/* @__PURE__ */
|
|
382
|
-
|
|
204
|
+
/* @__PURE__ */ d(
|
|
205
|
+
S,
|
|
383
206
|
{
|
|
384
207
|
alignItems: "center",
|
|
385
208
|
direction: "row",
|
|
386
209
|
justifyContent: "space-between",
|
|
387
210
|
width: "100%",
|
|
388
211
|
children: [
|
|
389
|
-
/* @__PURE__ */ t(y, { bold:
|
|
390
|
-
/* @__PURE__ */ t(y, { bold:
|
|
212
|
+
/* @__PURE__ */ t(y, { bold: o === e.guid, children: e.name }),
|
|
213
|
+
/* @__PURE__ */ t(y, { bold: o === e.guid, variant: "Body", children: E(e.amount, "0,0") })
|
|
391
214
|
]
|
|
392
215
|
}
|
|
393
216
|
)
|
|
@@ -397,50 +220,50 @@ const j = 5, Et = (n, c, r) => r.reduce((l, a) => {
|
|
|
397
220
|
}
|
|
398
221
|
),
|
|
399
222
|
/* @__PURE__ */ t(B, {}),
|
|
400
|
-
|
|
401
|
-
|
|
402
|
-
|
|
223
|
+
e.categoryTotals && e.categoryTotals.length > 0 && /* @__PURE__ */ t(bt, { in: r?.guid === e.guid, unmountOnExit: !0, children: /* @__PURE__ */ d(Y, { children: [
|
|
224
|
+
r?.categoryTotals?.map((l) => /* @__PURE__ */ t(
|
|
225
|
+
q,
|
|
403
226
|
{
|
|
404
227
|
sx: {
|
|
405
228
|
pl: 24,
|
|
406
229
|
pr: 8,
|
|
407
230
|
py: 0
|
|
408
231
|
},
|
|
409
|
-
children: /* @__PURE__ */
|
|
410
|
-
/* @__PURE__ */
|
|
411
|
-
|
|
232
|
+
children: /* @__PURE__ */ d(S, { direction: "row", justifyContent: "space-between", width: "100%", children: [
|
|
233
|
+
/* @__PURE__ */ d(y, { children: [
|
|
234
|
+
l.name,
|
|
412
235
|
" "
|
|
413
236
|
] }),
|
|
414
|
-
/* @__PURE__ */ t(y, { children:
|
|
237
|
+
/* @__PURE__ */ t(y, { children: E(l.amount, "0,0") })
|
|
415
238
|
] })
|
|
416
239
|
},
|
|
417
|
-
|
|
240
|
+
l.guid
|
|
418
241
|
)),
|
|
419
242
|
/* @__PURE__ */ t(B, {})
|
|
420
243
|
] }) })
|
|
421
|
-
] },
|
|
422
|
-
/* @__PURE__ */ t(y, { bold: !0, sx: { mt: 12, pr: 8, textAlign: "right" }, children: `${
|
|
244
|
+
] }, e.guid)) }),
|
|
245
|
+
/* @__PURE__ */ t(y, { bold: !0, sx: { mt: 12, pr: 8, textAlign: "right" }, children: `${c.total}: ${E(n.totalAmount, "0,0")}` })
|
|
423
246
|
] });
|
|
424
|
-
},
|
|
247
|
+
}, wt = D(Dt), xt = ({
|
|
425
248
|
data: n,
|
|
426
|
-
onSelected:
|
|
427
|
-
onViewTransactions:
|
|
428
|
-
selectedId:
|
|
429
|
-
title:
|
|
249
|
+
onSelected: s,
|
|
250
|
+
onViewTransactions: o,
|
|
251
|
+
selectedId: i,
|
|
252
|
+
title: c
|
|
430
253
|
}) => {
|
|
431
|
-
const { isDesktop:
|
|
432
|
-
return /* @__PURE__ */
|
|
433
|
-
|
|
254
|
+
const { isDesktop: r, isMobile: e } = yt(), { isLoadingCategoryTotals: l } = j(), { spending: u } = w();
|
|
255
|
+
return /* @__PURE__ */ d(
|
|
256
|
+
S,
|
|
434
257
|
{
|
|
435
|
-
alignItems:
|
|
436
|
-
direction:
|
|
258
|
+
alignItems: e ? "center" : "flex-start",
|
|
259
|
+
direction: e ? "column" : "row",
|
|
437
260
|
gap: { xs: 16, md: 64, xl: 100 },
|
|
438
261
|
justifyContent: "center",
|
|
439
262
|
pt: 50,
|
|
440
263
|
px: 8,
|
|
441
264
|
children: [
|
|
442
|
-
|
|
443
|
-
|
|
265
|
+
l && /* @__PURE__ */ t(
|
|
266
|
+
N,
|
|
444
267
|
{
|
|
445
268
|
data: {
|
|
446
269
|
categoryData: [],
|
|
@@ -450,173 +273,173 @@ const j = 5, Et = (n, c, r) => r.reduce((l, a) => {
|
|
|
450
273
|
onSelected: () => {
|
|
451
274
|
},
|
|
452
275
|
selectedId: "",
|
|
453
|
-
size:
|
|
276
|
+
size: r ? 400 : 300,
|
|
454
277
|
totalLabel: "Loading ...",
|
|
455
278
|
variant: "full"
|
|
456
279
|
}
|
|
457
280
|
),
|
|
458
|
-
!
|
|
459
|
-
|
|
281
|
+
!l && /* @__PURE__ */ t(
|
|
282
|
+
N,
|
|
460
283
|
{
|
|
461
284
|
data: n,
|
|
462
|
-
onSelected:
|
|
463
|
-
onViewTransactions:
|
|
464
|
-
selectedId:
|
|
465
|
-
size:
|
|
466
|
-
totalLabel:
|
|
285
|
+
onSelected: s,
|
|
286
|
+
onViewTransactions: o,
|
|
287
|
+
selectedId: i,
|
|
288
|
+
size: r ? 400 : 300,
|
|
289
|
+
totalLabel: u.total_amount,
|
|
467
290
|
variant: "full"
|
|
468
291
|
}
|
|
469
292
|
),
|
|
470
|
-
/* @__PURE__ */ t(
|
|
293
|
+
/* @__PURE__ */ t(wt, { data: n, onSelected: s, selectedId: i, title: c })
|
|
471
294
|
]
|
|
472
295
|
}
|
|
473
296
|
);
|
|
474
|
-
},
|
|
297
|
+
}, Z = D(xt), vt = (n) => [
|
|
475
298
|
n.palette.chartMono.chartMono5,
|
|
476
299
|
n.palette.chartMono.chartMono4,
|
|
477
300
|
n.palette.chartMono.chartMono3,
|
|
478
301
|
n.palette.chartMono.chartMono2,
|
|
479
302
|
n.palette.chartMono.chartMono1,
|
|
480
303
|
n.palette.chartMono.chartMono6
|
|
481
|
-
],
|
|
482
|
-
const n =
|
|
483
|
-
|
|
484
|
-
|
|
485
|
-
|
|
486
|
-
|
|
487
|
-
|
|
304
|
+
], Lt = () => {
|
|
305
|
+
const n = mt(), { clientConfig: s } = rt(), { categories: o, dateRangeCategoryTotals: i, loadDateRangeCategoryTotals: c } = j(), { goals: r, spending: e } = w(), { displayedDateRange: l, selectedAccounts: u, selectedAccountGuids: m } = O(), { setFilter: p, sortedTransactions: h } = gt(), M = s?.master?.deep_link_params?.account_guids, C = s?.master?.deep_link_params?.view, [f, A] = a.useState(""), [_, x] = a.useState(C === "income" ? 1 : 0), [I, F] = a.useState(""), [st, V] = a.useState(!1);
|
|
306
|
+
a.useEffect(() => {
|
|
307
|
+
c(
|
|
308
|
+
u,
|
|
309
|
+
l.start,
|
|
310
|
+
l.end
|
|
488
311
|
).finally();
|
|
489
|
-
}, [
|
|
490
|
-
const
|
|
491
|
-
() =>
|
|
492
|
-
[
|
|
493
|
-
),
|
|
494
|
-
() =>
|
|
495
|
-
[
|
|
496
|
-
),
|
|
497
|
-
() =>
|
|
498
|
-
[
|
|
499
|
-
),
|
|
500
|
-
|
|
501
|
-
},
|
|
502
|
-
|
|
503
|
-
},
|
|
504
|
-
const
|
|
505
|
-
accounts:
|
|
506
|
-
dateRange:
|
|
312
|
+
}, [u, l]);
|
|
313
|
+
const $ = a.useMemo(
|
|
314
|
+
() => ot(o, r, n, i),
|
|
315
|
+
[o, i]
|
|
316
|
+
), P = a.useMemo(
|
|
317
|
+
() => at(o, i, vt(n)),
|
|
318
|
+
[o, i]
|
|
319
|
+
), k = a.useMemo(
|
|
320
|
+
() => h.find((g) => g.guid === I),
|
|
321
|
+
[I, h]
|
|
322
|
+
), ct = (g, v) => {
|
|
323
|
+
x(v), A("");
|
|
324
|
+
}, H = (g) => {
|
|
325
|
+
A(f === g || g === "0" ? "" : g);
|
|
326
|
+
}, K = (g) => {
|
|
327
|
+
const v = {
|
|
328
|
+
accounts: M || m,
|
|
329
|
+
dateRange: l
|
|
507
330
|
};
|
|
508
331
|
if (_ === 0)
|
|
509
|
-
if (
|
|
510
|
-
const
|
|
511
|
-
|
|
512
|
-
...
|
|
513
|
-
custom: (G) => !!
|
|
332
|
+
if (g === "other") {
|
|
333
|
+
const b = $.categoryData.find((G) => G.guid === "other");
|
|
334
|
+
p({
|
|
335
|
+
...v,
|
|
336
|
+
custom: (G) => !!b?.categoryTotals?.find((lt) => lt.guid === G.top_level_category_guid)
|
|
514
337
|
});
|
|
515
338
|
} else
|
|
516
|
-
|
|
517
|
-
...
|
|
518
|
-
custom: (
|
|
519
|
-
showSplits: !!
|
|
339
|
+
p({
|
|
340
|
+
...v,
|
|
341
|
+
custom: (b) => g ? b.top_level_category_guid === g : b.top_level_category_guid !== L.INCOME && b.top_level_category_guid !== L.INVESTMENTS && b.top_level_category_guid !== L.TRANSFER,
|
|
342
|
+
showSplits: !!g
|
|
520
343
|
});
|
|
521
344
|
else
|
|
522
|
-
|
|
523
|
-
...
|
|
524
|
-
custom: (
|
|
345
|
+
p({
|
|
346
|
+
...v,
|
|
347
|
+
custom: (b) => g ? b.category_guid === g : b.category_guid === L.INCOME || b.top_level_category_guid === L.INCOME
|
|
525
348
|
});
|
|
526
|
-
|
|
349
|
+
V(!0);
|
|
527
350
|
};
|
|
528
|
-
return /* @__PURE__ */
|
|
529
|
-
/* @__PURE__ */
|
|
351
|
+
return /* @__PURE__ */ d(T, { children: [
|
|
352
|
+
/* @__PURE__ */ d(nt, { onChange: ct, value: _, variant: "fullWidth", children: [
|
|
530
353
|
/* @__PURE__ */ t(
|
|
531
|
-
|
|
354
|
+
W,
|
|
532
355
|
{
|
|
533
356
|
label: /* @__PURE__ */ t(
|
|
534
|
-
|
|
357
|
+
R,
|
|
535
358
|
{
|
|
536
|
-
amount:
|
|
537
|
-
label:
|
|
359
|
+
amount: $.totalAmount,
|
|
360
|
+
label: e.spend_tab_title
|
|
538
361
|
}
|
|
539
362
|
)
|
|
540
363
|
}
|
|
541
364
|
),
|
|
542
365
|
/* @__PURE__ */ t(
|
|
543
|
-
|
|
366
|
+
W,
|
|
544
367
|
{
|
|
545
368
|
label: /* @__PURE__ */ t(
|
|
546
|
-
|
|
369
|
+
R,
|
|
547
370
|
{
|
|
548
|
-
amount:
|
|
549
|
-
label:
|
|
371
|
+
amount: P.totalAmount,
|
|
372
|
+
label: e.income_tab_title
|
|
550
373
|
}
|
|
551
374
|
)
|
|
552
375
|
}
|
|
553
376
|
)
|
|
554
377
|
] }),
|
|
555
378
|
_ === 0 && /* @__PURE__ */ t(
|
|
556
|
-
|
|
379
|
+
Z,
|
|
557
380
|
{
|
|
558
|
-
data:
|
|
559
|
-
onSelected:
|
|
560
|
-
onViewTransactions:
|
|
561
|
-
selectedId:
|
|
562
|
-
title:
|
|
381
|
+
data: $,
|
|
382
|
+
onSelected: H,
|
|
383
|
+
onViewTransactions: K,
|
|
384
|
+
selectedId: f,
|
|
385
|
+
title: e.spend_tab_title
|
|
563
386
|
}
|
|
564
387
|
),
|
|
565
388
|
_ === 1 && /* @__PURE__ */ t(
|
|
566
|
-
|
|
389
|
+
Z,
|
|
567
390
|
{
|
|
568
|
-
data:
|
|
569
|
-
onSelected:
|
|
570
|
-
onViewTransactions:
|
|
571
|
-
selectedId:
|
|
572
|
-
title:
|
|
391
|
+
data: P,
|
|
392
|
+
onSelected: H,
|
|
393
|
+
onViewTransactions: K,
|
|
394
|
+
selectedId: f,
|
|
395
|
+
title: e.income_tab_title
|
|
573
396
|
}
|
|
574
397
|
),
|
|
575
398
|
/* @__PURE__ */ t(
|
|
576
|
-
|
|
399
|
+
J,
|
|
577
400
|
{
|
|
578
|
-
ariaLabelClose:
|
|
579
|
-
isOpen:
|
|
580
|
-
onClose: () =>
|
|
581
|
-
title:
|
|
582
|
-
children: /* @__PURE__ */ t(
|
|
401
|
+
ariaLabelClose: e.close_drawer_aria,
|
|
402
|
+
isOpen: st,
|
|
403
|
+
onClose: () => V(!1),
|
|
404
|
+
title: e.transactions_drawer_title,
|
|
405
|
+
children: /* @__PURE__ */ t(ht, { onClick: F })
|
|
583
406
|
}
|
|
584
407
|
),
|
|
585
408
|
/* @__PURE__ */ t(
|
|
586
|
-
|
|
409
|
+
J,
|
|
587
410
|
{
|
|
588
|
-
ariaLabelClose:
|
|
589
|
-
isOpen:
|
|
590
|
-
onClose: () =>
|
|
591
|
-
title:
|
|
592
|
-
children:
|
|
411
|
+
ariaLabelClose: e.close_drawer_aria,
|
|
412
|
+
isOpen: !!k,
|
|
413
|
+
onClose: () => F(""),
|
|
414
|
+
title: e.transaction_details_drawer_title,
|
|
415
|
+
children: k && /* @__PURE__ */ t(ft, { transaction: k })
|
|
593
416
|
}
|
|
594
417
|
)
|
|
595
418
|
] });
|
|
596
|
-
},
|
|
597
|
-
const { visibleAccounts:
|
|
598
|
-
|
|
599
|
-
|
|
600
|
-
}, [
|
|
601
|
-
|
|
419
|
+
}, At = D(Lt), It = ({ onBackClick: n, sx: s = {} }) => {
|
|
420
|
+
const { visibleAccounts: o } = it(), { spending: i } = w(), { isCopyLoaded: c, isInitialized: r, setDisplayedDate: e, setSelectedAccounts: l } = O(), { onEvent: u } = pt(), { clientConfig: m } = rt(), p = m?.master?.deep_link_params?.date_range, [h, M] = a.useState(!1);
|
|
421
|
+
a.useEffect(() => {
|
|
422
|
+
l(o);
|
|
423
|
+
}, [o]), a.useEffect(() => {
|
|
424
|
+
p && Array.isArray(p) && p.length === 2 ? e(p[0], p[1]) : e(tt(X()), et(X())), M(!0), u(Q.SPENDING_VIEW);
|
|
602
425
|
}, []);
|
|
603
|
-
const
|
|
604
|
-
|
|
426
|
+
const C = (f) => {
|
|
427
|
+
e(f[0], f[1]);
|
|
605
428
|
};
|
|
606
|
-
return !
|
|
607
|
-
|
|
429
|
+
return !c || !r || !h ? /* @__PURE__ */ t(z, {}) : /* @__PURE__ */ t(
|
|
430
|
+
Ct,
|
|
608
431
|
{
|
|
609
|
-
accountOptions:
|
|
610
|
-
calendarActions: { onRangeChanged:
|
|
611
|
-
onAccountsFilterClick: () =>
|
|
432
|
+
accountOptions: o,
|
|
433
|
+
calendarActions: { onRangeChanged: C },
|
|
434
|
+
onAccountsFilterClick: () => u(Q.SPENDING_CLICK_FILTER),
|
|
612
435
|
onBackClick: n,
|
|
613
|
-
sx:
|
|
614
|
-
title:
|
|
615
|
-
children: /* @__PURE__ */ t(
|
|
436
|
+
sx: s,
|
|
437
|
+
title: i.title,
|
|
438
|
+
children: /* @__PURE__ */ t(T, { height: "calc(100dvh - 150px)", overflow: "scroll", width: "100%", children: /* @__PURE__ */ t(At, {}) })
|
|
616
439
|
}
|
|
617
440
|
);
|
|
618
|
-
},
|
|
441
|
+
}, re = D(It);
|
|
619
442
|
export {
|
|
620
|
-
|
|
621
|
-
|
|
443
|
+
ie as SpendingMiniWidget,
|
|
444
|
+
re as SpendingWidget
|
|
622
445
|
};
|