@mx-cartographer/experiences 9.0.2 → 9.0.4-alpha.mm0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +11 -0
- package/dist/{Account-BaJmiJAG.mjs → Account-DR7Plrqy.mjs} +10 -10
- package/dist/AccountDetailsDrawer-C8oJP3J4.mjs +921 -0
- package/dist/AccountDetailsHeader-ByGNPZpO.mjs +228 -0
- package/dist/{AccountUtils-T5_Odvos.mjs → AccountUtils-B8ZzWI-d.mjs} +3 -3
- package/dist/{Analytics-CzGzz_sE.mjs → Analytics-WeZYytR0.mjs} +3 -0
- package/dist/BeatMaterialIcon-1KOfRZrA.mjs +26 -0
- package/dist/{CategorySelectorDrawer-8soGrhB8.mjs → CategorySelectorDrawer-BArJC27L.mjs} +1 -1
- package/dist/Connect-BH0Pt6zc.mjs +42 -0
- package/dist/{ConnectCard-CCep7Zqe.mjs → ConnectCard-Dwfgv24k.mjs} +1 -1
- package/dist/{ConnectDrawer-Cnjr3Ddg.mjs → ConnectDrawer-DytyIhaF.mjs} +8 -9
- package/dist/{ConnectionsDrawer-CtfPXk0M.mjs → ConnectionsDrawer-BHJPKXYF.mjs} +8 -9
- package/dist/{CurrencyInput-adTIRtL3.mjs → CurrencyInput-DaGEQaLW.mjs} +1 -1
- package/dist/DateUtil-CzBmbjmA.mjs +74 -0
- package/dist/{DebtUtils-DD3186U-.mjs → DebtUtils-i4pI2Uoe.mjs} +6 -6
- package/dist/{EmbeddedCard-DPwJjqMH.mjs → EmbeddedCard-CQpbZrmP.mjs} +4 -4
- package/dist/{Error-Dogaw2jO.mjs → Error-Dtw6yxkf.mjs} +1 -1
- package/dist/{ExportCsvAction-Bw02ZJEj.mjs → ExportCsvAction-bovG-NJr.mjs} +2 -2
- package/dist/{GlobalAccountFilter-7Cg2-9A5.mjs → GlobalAccountFilter-CYqzqmAd.mjs} +10 -10
- package/dist/{Help-DJ8PrVHX.mjs → Help-5klKVqkX.mjs} +2 -2
- package/dist/{LineChart-CejWS_rh.mjs → LineChart-CUfiH86G.mjs} +1 -1
- package/dist/{ListItemAction-CzZ8s39Z.mjs → ListItemAction-BqUCLj_w.mjs} +1 -1
- package/dist/{ListItemWrapper-B5r-YQQ_.mjs → ListItemWrapper-BHIbqx7E.mjs} +3 -3
- package/dist/ManageIncome-Cz6hvpdA.mjs +902 -0
- package/dist/{MicroWidgetContainer-CfKdQfhi.mjs → MicroWidgetContainer-B2NnKBgW.mjs} +1 -1
- package/dist/{MiniWidgetContainer-BdPiUU-u.mjs → MiniWidgetContainer-Bmv_WeUd.mjs} +1 -1
- package/dist/{NetWorthUtils-DilGN1nW.mjs → NetWorthUtils-DfSH3z70.mjs} +2 -2
- package/dist/{NotificationSettings-B4JA5IKE.mjs → NotificationSettings-Ci89BBRI.mjs} +4 -4
- package/dist/{OriginalBalanceAction-BybTXDtO.mjs → OriginalBalanceAction-YrvxBYAl.mjs} +3 -3
- package/dist/{RecurringSettings-D2xbNb67.mjs → RecurringSettings-ClYjsmPz.mjs} +4 -4
- package/dist/RecurringTransactionsUtil-zOxq5pzY.mjs +298 -0
- package/dist/Select-CSpkK5cR.mjs +61 -0
- package/dist/SpendingData-Fii_xATx.mjs +53 -0
- package/dist/{SpendingLegend-5Ct_FZ8o.mjs → SpendingLegend-Bn3DzGyK.mjs} +1 -1
- package/dist/TabContentContainer-B0eYJP5p.mjs +48 -0
- package/dist/{TransactionDetails-DctXr07p.mjs → TransactionDetails-DRN0GIaZ.mjs} +6 -6
- package/dist/{UserStore-CRpKQjpP.mjs → UserStore-DzWku3t0.mjs} +81 -40
- package/dist/{ViewMoreMicroCard-BD_MNc2z.mjs → ViewMoreMicroCard-Dxghxphh.mjs} +211 -231
- package/dist/{WidgetContainer-CmbU4CBH.mjs → WidgetContainer-D-LzIKFb.mjs} +3 -3
- package/dist/accounts/components/detailsdrawer/Accounts/AccountDetailsDrawer.d.ts +6 -0
- package/dist/accounts/index.d.ts +1 -0
- package/dist/accounts/index.es.js +220 -1035
- package/dist/analytics/index.es.js +8 -8
- package/dist/budgets/index.es.js +11 -11
- package/dist/cashflow/index.es.js +41 -41
- package/dist/categories/index.es.js +1 -1
- package/dist/common/components/DataRow.d.ts +1 -0
- package/dist/common/constants/Analytics.d.ts +3 -0
- package/dist/common/index.es.js +82 -83
- package/dist/core/index.es.js +8 -8
- package/dist/core/stores/RecurringTransactionsStore.d.ts +27 -1
- package/dist/core/types/localization/RecurringCopy.d.ts +14 -1
- package/dist/core/utils/DateUtil.d.ts +2 -0
- package/dist/core/utils/RecurringTransactionsUtil.d.ts +2 -1
- package/dist/dashboard/index.es.js +4 -4
- package/dist/debts/index.es.js +73 -73
- package/dist/finstrong/index.es.js +17 -17
- package/dist/goals/index.es.js +22 -23
- package/dist/help/index.es.js +4 -4
- package/dist/{hooks-BaO_gOI6.mjs → hooks-97sNJ_lf.mjs} +9 -9
- package/dist/insights/index.es.js +4 -4
- package/dist/investments/index.es.js +6 -6
- package/dist/merchants/index.es.js +1 -1
- package/dist/microinsights/index.es.js +12 -11
- package/dist/networth/index.es.js +9 -9
- package/dist/notifications/index.es.js +9 -9
- package/dist/recurringtransactions/components/RecurringTransactionDetailsDrawer.d.ts +3 -0
- package/dist/recurringtransactions/components/RecurringTransactionList.d.ts +11 -0
- package/dist/recurringtransactions/components/UpcomingRecurrenceCard.d.ts +6 -0
- package/dist/recurringtransactions/components/actions/LinkTransactionDrawer.d.ts +10 -0
- package/dist/recurringtransactions/components/actions/MarkAsPaidDialog.d.ts +7 -0
- package/dist/recurringtransactions/components/actions/MarkAsUnpaidDialog.d.ts +7 -0
- package/dist/recurringtransactions/index.es.js +402 -376
- package/dist/settings/index.es.js +7 -7
- package/dist/spending/index.es.js +8 -8
- package/dist/transactions/index.es.js +12 -12
- package/dist/trends/index.es.js +14 -14
- package/dist/useAccountDisplayName-BsiXA0qf.mjs +23 -0
- package/dist/{useInsightsEnabled-DaNLPmUU.mjs → useInsightsEnabled-D5Sdm0TJ.mjs} +1 -1
- package/dist/{useWidgetLoadTimer-CJb-RELP.mjs → useWidgetLoadTimer-B0tB-yzL.mjs} +1 -1
- package/package.json +1 -1
- package/dist/Account-BxHMlV9R.mjs +0 -30
- package/dist/AccountDetailsHeader-DIysk_4w.mjs +0 -95
- package/dist/AccountDisplayName-CO7z3v99.mjs +0 -11
- package/dist/AccountFields-mwJ8NXsX.mjs +0 -141
- package/dist/AccountListItem-BDXHs4tV.mjs +0 -94
- package/dist/Accounts-CseLC3lL.mjs +0 -5
- package/dist/Connect-Dk6GZEsA.mjs +0 -39
- package/dist/DateUtil-Bhq59ZVg.mjs +0 -58
- package/dist/ManageIncome-D1yBODQi.mjs +0 -595
- package/dist/RecurringTransactionsUtil-B3rLEx_g.mjs +0 -253
- package/dist/Select-BFt-HD-L.mjs +0 -55
- package/dist/SpendingData-PKlh8caU.mjs +0 -53
- package/dist/TabContentContainer-CnMXkVqr.mjs +0 -21
- package/dist/useAccountDisplayName-CFa_MrS6.mjs +0 -15
|
@@ -1,907 +1,97 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import
|
|
3
|
-
import { observer as
|
|
4
|
-
import
|
|
5
|
-
import { Text as
|
|
6
|
-
import { S as
|
|
7
|
-
import
|
|
8
|
-
import
|
|
9
|
-
import
|
|
10
|
-
import
|
|
11
|
-
import
|
|
12
|
-
import { f as
|
|
13
|
-
import {
|
|
14
|
-
import {
|
|
15
|
-
import {
|
|
16
|
-
import {
|
|
17
|
-
import {
|
|
18
|
-
import { A
|
|
19
|
-
import {
|
|
20
|
-
import {
|
|
21
|
-
import {
|
|
22
|
-
import {
|
|
23
|
-
import
|
|
24
|
-
import
|
|
25
|
-
import
|
|
26
|
-
import
|
|
27
|
-
import
|
|
28
|
-
import
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
import { isYesterday as B1 } from "date-fns/isYesterday";
|
|
39
|
-
import { f as l1, D as r1 } from "../DateFormats-HudZ3Bjs.mjs";
|
|
40
|
-
import { I as X } from "../IconBacking-DgT8DCeh.mjs";
|
|
41
|
-
import { addMonths as U1 } from "date-fns/addMonths";
|
|
42
|
-
import { AdapterDateFns as $1 } from "@mui/x-date-pickers/AdapterDateFnsV3";
|
|
43
|
-
import { DateCalendar as G1 } from "@mui/x-date-pickers/DateCalendar";
|
|
44
|
-
import z1 from "@mui/material/FormControl";
|
|
45
|
-
import K1 from "@mui/material/InputLabel";
|
|
46
|
-
import { LocalizationProvider as Y1 } from "@mui/x-date-pickers-pro";
|
|
47
|
-
import d1 from "@mui/material/MenuItem";
|
|
48
|
-
import j1 from "@mui/material/Select";
|
|
49
|
-
import X1 from "@mui/material/TextField";
|
|
50
|
-
import { F as J } from "../Accounts-CseLC3lL.mjs";
|
|
51
|
-
import { M as i2 } from "../Accounts-CseLC3lL.mjs";
|
|
52
|
-
import { C as J1 } from "../CurrencyInput-adTIRtL3.mjs";
|
|
53
|
-
import q1 from "@mui/material/Alert";
|
|
54
|
-
import Q1 from "@mui/material/AlertTitle";
|
|
55
|
-
import e3 from "@mui/material/Link";
|
|
56
|
-
import t3 from "@mui/material/Paper";
|
|
57
|
-
import { endOfToday as n3, subDays as o3, startOfToday as i3 } from "date-fns";
|
|
58
|
-
import { T as c3 } from "../EmbeddedCard-DPwJjqMH.mjs";
|
|
59
|
-
import { T as a3 } from "../TransactionDetails-DctXr07p.mjs";
|
|
60
|
-
import { T as u1 } from "../TabContentContainer-CnMXkVqr.mjs";
|
|
61
|
-
import { C as s3 } from "../ConnectionsDrawer-CtfPXk0M.mjs";
|
|
62
|
-
import { u as V1 } from "../useScreenSize-mWpmnh5w.mjs";
|
|
63
|
-
import { u as o1 } from "../useWidgetLoadTimer-CJb-RELP.mjs";
|
|
64
|
-
import { L as i1 } from "../Loader-CxeBwuPG.mjs";
|
|
65
|
-
import { W as l3 } from "../WidgetContainer-CmbU4CBH.mjs";
|
|
66
|
-
import { M as A1 } from "../MiniWidgetContainer-BdPiUU-u.mjs";
|
|
67
|
-
const r3 = (t, o) => {
|
|
68
|
-
const n = g1.includes(o) ? S1(t) : [], c = H1.includes(o) ? T1(t) : [], i = v1.includes(o) ? D1(t) : [];
|
|
69
|
-
return [n, c, i].filter((l) => l.length > 0);
|
|
70
|
-
}, d3 = (t, o, n) => {
|
|
71
|
-
const [c, i] = t, l = c, d = i ?? c, a = [];
|
|
72
|
-
if (l && d && g1.includes(o)) {
|
|
73
|
-
const r = l[l.length - 1].y;
|
|
74
|
-
a.push({ label: n.income_label, amount: r });
|
|
75
|
-
} else if (H1.includes(o)) {
|
|
76
|
-
const r = l[l.length - 1].y;
|
|
77
|
-
a.push({ label: n.payments_label, amount: r });
|
|
78
|
-
}
|
|
79
|
-
if (d && v1.includes(o)) {
|
|
80
|
-
const r = d[d.length - 1].y;
|
|
81
|
-
a.push({ label: n.spending_label, amount: r });
|
|
82
|
-
}
|
|
83
|
-
return a;
|
|
84
|
-
}, u3 = () => {
|
|
85
|
-
const t = p1(), { selectedAccount: o } = R(), { monthlyCategoryTotals: n } = E1(), { trends: c } = A(), i = [t.palette.chart?.chart1, t.palette.chart?.chart2], l = r3(n, o.account_type), d = d3(l, o.account_type, c), a = [I.LOAN, I.MORTGAGE].includes(o.account_type);
|
|
86
|
-
return /* @__PURE__ */ e("div", { "data-testid": "TrendsChart", children: /* @__PURE__ */ e(
|
|
87
|
-
R1,
|
|
88
|
-
{
|
|
89
|
-
colors: i,
|
|
90
|
-
datasets: l,
|
|
91
|
-
height: 185,
|
|
92
|
-
labels: d,
|
|
93
|
-
showAverage: a,
|
|
94
|
-
showAxisHighlight: !0,
|
|
95
|
-
showBars: a,
|
|
96
|
-
showLegend: !0,
|
|
97
|
-
showTooltip: !0,
|
|
98
|
-
showXAxis: !0,
|
|
99
|
-
showXAxisTicks: !0,
|
|
100
|
-
showYAxis: !0,
|
|
101
|
-
showYAxisTicks: !0,
|
|
102
|
-
valueFormatterString: "0,0"
|
|
103
|
-
}
|
|
104
|
-
) });
|
|
105
|
-
}, C3 = V(u3), q = ({
|
|
106
|
-
ariaPressed: t,
|
|
107
|
-
children: o,
|
|
108
|
-
isLast: n = !1,
|
|
109
|
-
onClick: c,
|
|
110
|
-
primaryText: i,
|
|
111
|
-
secondaryText: l
|
|
112
|
-
}) => /* @__PURE__ */ e(
|
|
113
|
-
D,
|
|
114
|
-
{
|
|
115
|
-
sx: {
|
|
116
|
-
backgroundColor: "background.paper",
|
|
117
|
-
position: "relative",
|
|
118
|
-
"&::after": {
|
|
119
|
-
content: '""',
|
|
120
|
-
position: "absolute",
|
|
121
|
-
bottom: 0,
|
|
122
|
-
right: 0,
|
|
123
|
-
left: n ? 0 : 24,
|
|
124
|
-
borderBottom: "1px solid",
|
|
125
|
-
borderColor: "divider"
|
|
126
|
-
}
|
|
127
|
-
},
|
|
128
|
-
children: /* @__PURE__ */ C($, { "aria-pressed": t, onClick: c, children: [
|
|
129
|
-
/* @__PURE__ */ e(Z, { primary: i, secondary: l }),
|
|
130
|
-
o
|
|
131
|
-
] })
|
|
132
|
-
}
|
|
133
|
-
), h3 = () => {
|
|
134
|
-
const { accounts: t } = E(), { selectedAccount: o, selectedMember: n } = R();
|
|
135
|
-
return t.filter(
|
|
136
|
-
(c) => c.member_guid === n.guid && n.successfully_aggregated_at && c.guid !== o.guid
|
|
137
|
-
);
|
|
138
|
-
}, m3 = () => {
|
|
139
|
-
const [t, o] = h.useState(!1), [n, c] = h.useState(!1), [i, l] = h.useState(!1), [d, a] = h.useState({}), { selectedAccount: r } = R(), { mergeAccounts: L, updateAccount: m } = E(), { accounts: s } = A(), _ = h3(), { onEvent: y } = k(), { modifyTransactionByAccountGuid: x } = _1(), M = async (u) => {
|
|
140
|
-
await m({
|
|
141
|
-
...r,
|
|
142
|
-
...u
|
|
143
|
-
}), "is_closed" in u && u.is_closed !== r.is_closed && x(r.guid, { accountIsClosed: u.is_closed });
|
|
144
|
-
}, p = () => {
|
|
145
|
-
L([r.guid, d.guid]).finally(
|
|
146
|
-
() => c(!1)
|
|
147
|
-
);
|
|
148
|
-
};
|
|
149
|
-
return /* @__PURE__ */ C(S, { children: [
|
|
150
|
-
/* @__PURE__ */ e(B, { sx: { backgroundColor: "transparent", mb: 4, mt: 12, mx: 8 }, children: /* @__PURE__ */ e(v, { bold: !0, component: "h2", variant: "caption", children: s.actions }) }),
|
|
151
|
-
/* @__PURE__ */ e(
|
|
152
|
-
q,
|
|
153
|
-
{
|
|
154
|
-
ariaPressed: r.is_hidden,
|
|
155
|
-
onClick: () => {
|
|
156
|
-
M({ is_hidden: !r.is_hidden }), y(w.ACCOUNT_DETAILS_CLICK_HIDE, { account_guid: r.guid });
|
|
157
|
-
},
|
|
158
|
-
primaryText: r.is_hidden ? s.unhide_account : s.hide_Account,
|
|
159
|
-
secondaryText: r.is_hidden ? s.include_this_account : s.exclude_this_account,
|
|
160
|
-
children: /* @__PURE__ */ e(N1, { "aria-hidden": !0, checked: r.is_hidden, tabIndex: -1 })
|
|
161
|
-
}
|
|
162
|
-
),
|
|
163
|
-
/* @__PURE__ */ C(
|
|
164
|
-
q,
|
|
165
|
-
{
|
|
166
|
-
onClick: () => {
|
|
167
|
-
o(!0), y(w.ACCOUNT_DETAILS_CLICK_MARK_CLOSED, {
|
|
168
|
-
account_guid: r.guid
|
|
169
|
-
});
|
|
170
|
-
},
|
|
171
|
-
primaryText: r.is_closed ? s.mark_as_open : s.mark_as_closed,
|
|
172
|
-
secondaryText: r.is_closed ? s.this_will_set_the_closed_account : s.this_will_set_the_account_balance_to_0,
|
|
173
|
-
children: [
|
|
174
|
-
/* @__PURE__ */ e(N, { name: "chevron_right" }),
|
|
175
|
-
/* @__PURE__ */ e("div", { onClick: (u) => u.stopPropagation(), children: /* @__PURE__ */ e(
|
|
176
|
-
e1,
|
|
177
|
-
{
|
|
178
|
-
copy: {
|
|
179
|
-
close_aria: s.close_modal,
|
|
180
|
-
title: r.is_closed ? s.confirm_mark_as_open : s.confirm_mark_closed
|
|
181
|
-
},
|
|
182
|
-
isOpen: t,
|
|
183
|
-
onClose: () => {
|
|
184
|
-
o(!1);
|
|
185
|
-
},
|
|
186
|
-
onPrimaryAction: () => M({ is_closed: !r.is_closed }),
|
|
187
|
-
children: /* @__PURE__ */ e(v, { truncate: !1, children: H(
|
|
188
|
-
r.is_closed ? s.this_will_resume_updating_the_balance : s.this_will_set_the_balance_of_your_account,
|
|
189
|
-
r.name
|
|
190
|
-
) })
|
|
191
|
-
}
|
|
192
|
-
) })
|
|
193
|
-
]
|
|
194
|
-
}
|
|
195
|
-
),
|
|
196
|
-
_.length > 0 && /* @__PURE__ */ e(
|
|
197
|
-
q,
|
|
198
|
-
{
|
|
199
|
-
isLast: !0,
|
|
200
|
-
onClick: () => {
|
|
201
|
-
c(!0), y(w.ACCOUNT_DETAILS_CLICK_MARK_DUPLICATE, {
|
|
202
|
-
account_guid: r.guid
|
|
203
|
-
});
|
|
204
|
-
},
|
|
205
|
-
primaryText: s.mark_as_duplicate,
|
|
206
|
-
secondaryText: s.if_a_connected_account_is_showing_up_twice,
|
|
207
|
-
children: /* @__PURE__ */ e(N, { name: "chevron_right" })
|
|
208
|
-
}
|
|
209
|
-
),
|
|
210
|
-
/* @__PURE__ */ C(
|
|
211
|
-
n1,
|
|
212
|
-
{
|
|
213
|
-
ariaLabelClose: s.close_drawer,
|
|
214
|
-
isOpen: n,
|
|
215
|
-
onClose: () => c(!1),
|
|
216
|
-
title: s.mark_as_duplicate,
|
|
217
|
-
children: [
|
|
218
|
-
/* @__PURE__ */ e(O, { children: _.map((u) => {
|
|
219
|
-
const g = _.indexOf(u) === _.length - 1;
|
|
220
|
-
return /* @__PURE__ */ e(
|
|
221
|
-
U,
|
|
222
|
-
{
|
|
223
|
-
account: u,
|
|
224
|
-
listItemProps: {
|
|
225
|
-
sx: {
|
|
226
|
-
position: "relative",
|
|
227
|
-
"&::after": {
|
|
228
|
-
content: '""',
|
|
229
|
-
position: "absolute",
|
|
230
|
-
bottom: 0,
|
|
231
|
-
right: 0,
|
|
232
|
-
left: g ? 0 : 24,
|
|
233
|
-
borderBottom: "1px solid",
|
|
234
|
-
borderColor: "divider"
|
|
235
|
-
}
|
|
236
|
-
}
|
|
237
|
-
},
|
|
238
|
-
onRowClick: () => {
|
|
239
|
-
l(!0), a(u);
|
|
240
|
-
}
|
|
241
|
-
},
|
|
242
|
-
u.guid
|
|
243
|
-
);
|
|
244
|
-
}) }),
|
|
245
|
-
i && /* @__PURE__ */ C(
|
|
246
|
-
e1,
|
|
247
|
-
{
|
|
248
|
-
copy: {
|
|
249
|
-
close_aria: s.close_modal,
|
|
250
|
-
title: s.confirm_merge
|
|
251
|
-
},
|
|
252
|
-
isOpen: i,
|
|
253
|
-
onClose: () => l(!1),
|
|
254
|
-
onPrimaryAction: p,
|
|
255
|
-
children: [
|
|
256
|
-
/* @__PURE__ */ e(v, { truncate: !1, children: H(
|
|
257
|
-
s.this_means_accounts_will_be_merged,
|
|
258
|
-
r.name,
|
|
259
|
-
d.name
|
|
260
|
-
) }),
|
|
261
|
-
/* @__PURE__ */ e(v, { color: "error", sx: { mt: 24 }, children: s.this_action_cannot_be_undone })
|
|
262
|
-
]
|
|
263
|
-
}
|
|
264
|
-
)
|
|
265
|
-
]
|
|
266
|
-
}
|
|
267
|
-
)
|
|
268
|
-
] });
|
|
269
|
-
}, p3 = V(m3), y1 = (t, o) => {
|
|
270
|
-
const { connection_messages: n } = o;
|
|
271
|
-
switch (t.connection_status) {
|
|
272
|
-
case f.CHALLENGED:
|
|
273
|
-
return {
|
|
274
|
-
cta: n.challenged_cta,
|
|
275
|
-
main: H(
|
|
276
|
-
n.challenged_connection_description,
|
|
277
|
-
t.name
|
|
278
|
-
),
|
|
279
|
-
statusName: o.connection_statuses[t.connection_status],
|
|
280
|
-
title: n.challenged_connection_title
|
|
281
|
-
};
|
|
282
|
-
case f.CLOSED:
|
|
283
|
-
return {
|
|
284
|
-
main: n.closed_connection_description,
|
|
285
|
-
statusName: o.connection_statuses[t.connection_status],
|
|
286
|
-
title: n.closed_connection_title
|
|
287
|
-
};
|
|
288
|
-
case f.DEGRADED:
|
|
289
|
-
return {
|
|
290
|
-
main: n.degraded_connection_description,
|
|
291
|
-
statusName: o.connection_statuses[t.connection_status],
|
|
292
|
-
title: n.degraded_connection_title
|
|
293
|
-
};
|
|
294
|
-
case f.DELAYED:
|
|
295
|
-
return {
|
|
296
|
-
main: H(
|
|
297
|
-
n.delayed_connection_description,
|
|
298
|
-
t.name
|
|
299
|
-
),
|
|
300
|
-
statusName: o.connection_statuses[t.connection_status],
|
|
301
|
-
title: n.delayed_connection_title
|
|
302
|
-
};
|
|
303
|
-
case f.DENIED:
|
|
304
|
-
return {
|
|
305
|
-
cta: n.denied_cta,
|
|
306
|
-
main: H(
|
|
307
|
-
n.denied_connection_description,
|
|
308
|
-
t.name
|
|
309
|
-
),
|
|
310
|
-
statusName: o.connection_statuses[t.connection_status],
|
|
311
|
-
title: n.denied_connection_title
|
|
312
|
-
};
|
|
313
|
-
case f.DISABLED:
|
|
314
|
-
return {
|
|
315
|
-
main: n.disabled_connection_description,
|
|
316
|
-
statusName: o.connection_statuses[t.connection_status],
|
|
317
|
-
title: n.disabled_connection_title
|
|
318
|
-
};
|
|
319
|
-
case f.DISCONNECTED:
|
|
320
|
-
return {
|
|
321
|
-
main: H(
|
|
322
|
-
n.disconnected_connection_description,
|
|
323
|
-
t.name
|
|
324
|
-
),
|
|
325
|
-
statusName: o.connection_statuses[t.connection_status],
|
|
326
|
-
title: n.disconnected_connection_title
|
|
327
|
-
};
|
|
328
|
-
case f.DISCONTINUED:
|
|
329
|
-
return {
|
|
330
|
-
main: n.discontinued_connection_description,
|
|
331
|
-
statusName: o.connection_statuses[t.connection_status],
|
|
332
|
-
title: n.discontinued_connection_title
|
|
333
|
-
};
|
|
334
|
-
case f.EXPIRED:
|
|
335
|
-
return {
|
|
336
|
-
cta: n.expired_cta,
|
|
337
|
-
main: n.expired_connection_description,
|
|
338
|
-
statusName: o.connection_statuses[t.connection_status],
|
|
339
|
-
title: n.expired_connection_title
|
|
340
|
-
};
|
|
341
|
-
case f.FAILED:
|
|
342
|
-
return {
|
|
343
|
-
main: H(
|
|
344
|
-
n.failed_connection_description,
|
|
345
|
-
t.name
|
|
346
|
-
),
|
|
347
|
-
statusName: o.connection_statuses[t.connection_status],
|
|
348
|
-
title: n.failed_connection_title
|
|
349
|
-
};
|
|
350
|
-
case f.IMPAIRED:
|
|
351
|
-
return {
|
|
352
|
-
cta: n.impaired_cta,
|
|
353
|
-
main: H(
|
|
354
|
-
n.impaired_connection_description,
|
|
355
|
-
t.name
|
|
356
|
-
),
|
|
357
|
-
statusName: o.connection_statuses[t.connection_status],
|
|
358
|
-
title: n.impaired_connection_title
|
|
359
|
-
};
|
|
360
|
-
case f.IMPEDED:
|
|
361
|
-
return {
|
|
362
|
-
main: H(
|
|
363
|
-
n.impeded_connection_description,
|
|
364
|
-
t.name,
|
|
365
|
-
t.name
|
|
366
|
-
),
|
|
367
|
-
statusName: o.connection_statuses[t.connection_status],
|
|
368
|
-
title: n.impeded_connection_title
|
|
369
|
-
};
|
|
370
|
-
case f.IMPORTED:
|
|
371
|
-
return {
|
|
372
|
-
cta: n.imported_cta,
|
|
373
|
-
main: H(
|
|
374
|
-
n.imported_connection_description,
|
|
375
|
-
t.name
|
|
376
|
-
),
|
|
377
|
-
statusName: o.connection_statuses[t.connection_status],
|
|
378
|
-
title: n.imported_connection_title
|
|
379
|
-
};
|
|
380
|
-
case f.LOCKED:
|
|
381
|
-
return {
|
|
382
|
-
cta: n.locked_cta,
|
|
383
|
-
main: H(
|
|
384
|
-
n.locked_connection_description,
|
|
385
|
-
t.name
|
|
386
|
-
),
|
|
387
|
-
statusName: o.connection_statuses[t.connection_status],
|
|
388
|
-
title: n.locked_connection_title
|
|
389
|
-
};
|
|
390
|
-
case f.PREVENTED:
|
|
391
|
-
return {
|
|
392
|
-
cta: n.prevented_cta,
|
|
393
|
-
main: n.prevented_connection_description,
|
|
394
|
-
statusName: o.connection_statuses[t.connection_status],
|
|
395
|
-
title: n.prevented_connection_title
|
|
396
|
-
};
|
|
397
|
-
case f.REJECTED:
|
|
398
|
-
return {
|
|
399
|
-
cta: n.rejected_cta,
|
|
400
|
-
main: n.rejected_connection_description,
|
|
401
|
-
statusName: o.connection_statuses[t.connection_status],
|
|
402
|
-
title: n.rejected_connection_title
|
|
403
|
-
};
|
|
404
|
-
default: {
|
|
405
|
-
const c = () => {
|
|
406
|
-
const i = t.successfully_aggregated_at ? P1(t.successfully_aggregated_at) : void 0, l = i && l1(i, r1.TIME_STAMP_HOUR_MINUTE);
|
|
407
|
-
if (l)
|
|
408
|
-
return W1(i) ? H(o.last_updated_at, o.today, l) : B1(i) ? H(o.last_updated_at, o.yesterday, l) : H(
|
|
409
|
-
o.last_updated_at,
|
|
410
|
-
l1(i, r1.MONTH_DAY_YEAR),
|
|
411
|
-
l
|
|
412
|
-
);
|
|
413
|
-
};
|
|
414
|
-
return {
|
|
415
|
-
statusName: o.connection_statuses[6],
|
|
416
|
-
// Connected
|
|
417
|
-
title: c()
|
|
418
|
-
};
|
|
419
|
-
}
|
|
420
|
-
}
|
|
421
|
-
}, Q = {
|
|
422
|
-
color: "background.default",
|
|
423
|
-
fontSize: 20,
|
|
424
|
-
gridRow: 1,
|
|
425
|
-
gridColumn: 1,
|
|
426
|
-
zIndex: 2
|
|
427
|
-
}, _3 = () => {
|
|
428
|
-
const [t, o] = h.useState(!1), {
|
|
429
|
-
palette: { mode: n }
|
|
430
|
-
} = p1(), { selectedMember: c } = R(), { accounts: i, connect: l } = A(), d = y1(c, l), a = f1.includes(c.connection_status) ? {
|
|
431
|
-
color: "error.main",
|
|
432
|
-
ctaCopy: d.cta ?? "",
|
|
433
|
-
icon: /* @__PURE__ */ e(b1, { filled: !0, sx: { ...Q } }),
|
|
434
|
-
mainMessage: d.statusName,
|
|
435
|
-
secondaryMessage: `${d.title}.`
|
|
436
|
-
} : {
|
|
437
|
-
color: "success.main",
|
|
438
|
-
icon: /* @__PURE__ */ e(F1, { filled: !0, sx: { ...Q } }),
|
|
439
|
-
mainMessage: d.statusName,
|
|
440
|
-
secondaryMessage: d.title
|
|
441
|
-
};
|
|
442
|
-
return /* @__PURE__ */ C(S, { children: [
|
|
443
|
-
/* @__PURE__ */ e(B, { sx: { mb: 4, mt: 12, mx: 8 }, children: /* @__PURE__ */ e(v, { bold: !0, component: "h2", variant: "caption", children: i.connection_status }) }),
|
|
444
|
-
/* @__PURE__ */ e(
|
|
445
|
-
D,
|
|
446
|
-
{
|
|
447
|
-
sx: {
|
|
448
|
-
backgroundColor: "background.paper",
|
|
449
|
-
position: "relative",
|
|
450
|
-
"&::after": {
|
|
451
|
-
content: '""',
|
|
452
|
-
position: "absolute",
|
|
453
|
-
bottom: 0,
|
|
454
|
-
right: 0,
|
|
455
|
-
left: c.is_manual || !c.institution_url ? 0 : 24,
|
|
456
|
-
borderBottom: "1px solid",
|
|
457
|
-
borderColor: "divider"
|
|
458
|
-
}
|
|
459
|
-
},
|
|
460
|
-
children: c.is_manual || !a.ctaCopy ? /* @__PURE__ */ C(t1, { alignItems: "center", direction: "row", px: 24, py: 12, children: [
|
|
461
|
-
/* @__PURE__ */ e(j, { children: /* @__PURE__ */ e(X, { backingSx: { backgroundColor: a.color, borderRadius: 1 }, size: 32, children: a.icon }) }),
|
|
462
|
-
/* @__PURE__ */ e(Z, { primary: a.mainMessage, secondary: a.secondaryMessage })
|
|
463
|
-
] }) : /* @__PURE__ */ C($, { onClick: () => o(!0), children: [
|
|
464
|
-
/* @__PURE__ */ e(j, { children: /* @__PURE__ */ e(X, { backingSx: { backgroundColor: a.color, borderRadius: 1 }, size: 32, children: a.icon }) }),
|
|
465
|
-
/* @__PURE__ */ e(
|
|
466
|
-
Z,
|
|
467
|
-
{
|
|
468
|
-
primary: a.mainMessage,
|
|
469
|
-
secondary: a.secondaryMessage && /* @__PURE__ */ C(S, { children: [
|
|
470
|
-
a.secondaryMessage,
|
|
471
|
-
" ",
|
|
472
|
-
/* @__PURE__ */ e(v, { bold: !0, sx: { color: "action.active" }, variant: "caption", children: a.ctaCopy })
|
|
473
|
-
] })
|
|
474
|
-
}
|
|
475
|
-
),
|
|
476
|
-
/* @__PURE__ */ e(N, { name: "chevron_right" })
|
|
477
|
-
] })
|
|
478
|
-
}
|
|
479
|
-
),
|
|
480
|
-
!c.is_manual && c.institution_url && /* @__PURE__ */ e(S, { children: /* @__PURE__ */ e(
|
|
481
|
-
D,
|
|
482
|
-
{
|
|
483
|
-
sx: {
|
|
484
|
-
backgroundColor: "background.paper",
|
|
485
|
-
borderBottom: "1px solid",
|
|
486
|
-
borderColor: "divider"
|
|
487
|
-
},
|
|
488
|
-
children: /* @__PURE__ */ C($, { component: "a", href: c.institution_url, target: "_blank", children: [
|
|
489
|
-
/* @__PURE__ */ e(j, { children: /* @__PURE__ */ e(
|
|
490
|
-
X,
|
|
491
|
-
{
|
|
492
|
-
backingSx: {
|
|
493
|
-
backgroundColor: n === "light" ? "grey.300" : "grey.700",
|
|
494
|
-
borderRadius: 1
|
|
495
|
-
},
|
|
496
|
-
size: 32,
|
|
497
|
-
children: /* @__PURE__ */ e(
|
|
498
|
-
O1,
|
|
499
|
-
{
|
|
500
|
-
sx: {
|
|
501
|
-
...Q,
|
|
502
|
-
color: n === "light" ? "grey.900" : "common.white"
|
|
503
|
-
}
|
|
504
|
-
}
|
|
505
|
-
)
|
|
506
|
-
}
|
|
507
|
-
) }),
|
|
508
|
-
/* @__PURE__ */ e(Z, { primary: c.name, secondary: c.institution_url }),
|
|
509
|
-
/* @__PURE__ */ e(N, { name: "launch" })
|
|
510
|
-
] })
|
|
511
|
-
}
|
|
512
|
-
) }),
|
|
513
|
-
t && /* @__PURE__ */ e(
|
|
514
|
-
z,
|
|
515
|
-
{
|
|
516
|
-
loadWidgetProps: { current_member_guid: c.guid },
|
|
517
|
-
onClose: () => o(!1),
|
|
518
|
-
showConnectWidget: t,
|
|
519
|
-
title: i.manage_connection
|
|
520
|
-
}
|
|
521
|
-
)
|
|
522
|
-
] });
|
|
523
|
-
}, L3 = V(_3), f3 = ({ field: t, isOpen: o, onClose: n }) => {
|
|
524
|
-
const { updateAccount: c } = E(), { selectedAccount: i } = R(), { accounts: l } = A(), [d, a] = h.useState(i[t.name]), [r, L] = h.useState(""), [m, s] = h.useState(!0), _ = () => {
|
|
525
|
-
a(""), L(""), n();
|
|
526
|
-
}, y = () => {
|
|
527
|
-
switch (t.type) {
|
|
528
|
-
case J.Select:
|
|
529
|
-
return /* @__PURE__ */ C(z1, { fullWidth: !0, children: [
|
|
530
|
-
/* @__PURE__ */ e(K1, { id: `${t.label}-select-label`, children: t.label }),
|
|
531
|
-
/* @__PURE__ */ C(
|
|
532
|
-
j1,
|
|
533
|
-
{
|
|
534
|
-
displayEmpty: !0,
|
|
535
|
-
id: `${t.label}-select`,
|
|
536
|
-
label: t.label,
|
|
537
|
-
labelId: `${t.label}-select-label`,
|
|
538
|
-
onChange: (p) => a(p.target.value),
|
|
539
|
-
slotProps: {
|
|
540
|
-
input: {
|
|
541
|
-
sx: {
|
|
542
|
-
backgroundColor: "background.paper"
|
|
543
|
-
}
|
|
544
|
-
}
|
|
545
|
-
},
|
|
546
|
-
value: d,
|
|
547
|
-
children: [
|
|
548
|
-
!d && /* @__PURE__ */ e(d1, { disabled: !0, value: "", children: t.placeholder }),
|
|
549
|
-
t.options?.map((p) => /* @__PURE__ */ e(d1, { value: p.value, children: p.label }, p.value))
|
|
550
|
-
]
|
|
551
|
-
}
|
|
552
|
-
)
|
|
553
|
-
] });
|
|
554
|
-
case J.Currency:
|
|
555
|
-
return /* @__PURE__ */ e(
|
|
556
|
-
J1,
|
|
557
|
-
{
|
|
558
|
-
amount: d || "",
|
|
559
|
-
ariaLabel: t.placeholder,
|
|
560
|
-
fullWidth: !0,
|
|
561
|
-
label: t.label,
|
|
562
|
-
placeholder: t.placeholder,
|
|
563
|
-
setAmount: a,
|
|
564
|
-
setHasValidInput: s
|
|
565
|
-
}
|
|
566
|
-
);
|
|
567
|
-
case J.Date:
|
|
568
|
-
return /* @__PURE__ */ e(Y1, { dateAdapter: $1, children: /* @__PURE__ */ e(
|
|
569
|
-
G1,
|
|
570
|
-
{
|
|
571
|
-
maxDate: U1(/* @__PURE__ */ new Date(), 1),
|
|
572
|
-
minDate: /* @__PURE__ */ new Date(),
|
|
573
|
-
onChange: (p) => {
|
|
574
|
-
i[t.name] && Number(i[t.name]) <= 31 ? a(p.getDate()) : a(p);
|
|
575
|
-
},
|
|
576
|
-
sx: {
|
|
577
|
-
"& .MuiPickersDay-today": {
|
|
578
|
-
color: "primary.lighter"
|
|
579
|
-
},
|
|
580
|
-
"& .MuiPickersArrowSwitcher-button": {
|
|
581
|
-
color: "primary.lighter",
|
|
582
|
-
"&:hover": {
|
|
583
|
-
backgroundColor: (p) => x1(p.palette.primary.light, 0.1)
|
|
584
|
-
}
|
|
585
|
-
}
|
|
586
|
-
},
|
|
587
|
-
views: ["day"]
|
|
588
|
-
}
|
|
589
|
-
) });
|
|
590
|
-
default:
|
|
591
|
-
return /* @__PURE__ */ e(
|
|
592
|
-
X1,
|
|
593
|
-
{
|
|
594
|
-
defaultValue: i[t.name],
|
|
595
|
-
error: !!r,
|
|
596
|
-
fullWidth: !0,
|
|
597
|
-
helperText: r,
|
|
598
|
-
onChange: M,
|
|
599
|
-
placeholder: t.placeholder,
|
|
600
|
-
slotProps: {
|
|
601
|
-
htmlInput: {
|
|
602
|
-
"aria-label": t.placeholder
|
|
603
|
-
}
|
|
604
|
-
}
|
|
605
|
-
}
|
|
606
|
-
);
|
|
607
|
-
}
|
|
608
|
-
}, x = () => {
|
|
609
|
-
i[t.name] !== d && c({
|
|
610
|
-
...i,
|
|
611
|
-
[t.name]: d
|
|
612
|
-
}), _();
|
|
613
|
-
}, M = (p) => {
|
|
614
|
-
a(p.target.value), t.validation && L(t.validation(p.target.value));
|
|
615
|
-
};
|
|
616
|
-
return /* @__PURE__ */ e(
|
|
617
|
-
e1,
|
|
618
|
-
{
|
|
619
|
-
copy: {
|
|
620
|
-
close_aria: l.close_aria,
|
|
621
|
-
title: H(l.edit_field, t.label)
|
|
622
|
-
},
|
|
623
|
-
disablePrimaryButton: !!r || !m,
|
|
624
|
-
isOpen: o,
|
|
625
|
-
onClose: _,
|
|
626
|
-
onPrimaryAction: x,
|
|
627
|
-
primaryText: l.save,
|
|
628
|
-
sx: {
|
|
629
|
-
"& .MuiButton-root:focus-visible, & .MuiButton-root:focus": {
|
|
630
|
-
outline: "2px solid",
|
|
631
|
-
outlineColor: "primary.main",
|
|
632
|
-
outlineOffset: "2px"
|
|
633
|
-
}
|
|
634
|
-
},
|
|
635
|
-
children: y()
|
|
636
|
-
}
|
|
637
|
-
);
|
|
638
|
-
}, g3 = V(f3), H3 = () => {
|
|
639
|
-
const t = window.app?.config, { onEvent: o } = k(), { selectedAccount: n } = R(), { accounts: c } = A(), i = k1(n, c), l = n.member_is_managed_by_user || !n.member_is_managed_by_user && t.enable_renaming_home_accounts, [d, a] = h.useState(!1), [r, L] = h.useState(i[0]), m = i.filter(
|
|
640
|
-
(s) => l || n[s.name] || n[s.name] === 0
|
|
641
|
-
);
|
|
642
|
-
return /* @__PURE__ */ C(S, { children: [
|
|
643
|
-
m.map((s) => {
|
|
644
|
-
const _ = n[s.name] || n[s.name] === 0, y = m.indexOf(s) === m.length - 1, x = /* @__PURE__ */ e(
|
|
645
|
-
Z,
|
|
646
|
-
{
|
|
647
|
-
disableTypography: !0,
|
|
648
|
-
primary: /* @__PURE__ */ e(v, { sx: { fontSize: 11 }, children: s.label }),
|
|
649
|
-
secondary: /* @__PURE__ */ e(v, { bold: !0, sx: { fontSize: 15 }, children: _ ? s.valueFormatter(n[s.name]) : s.placeholder })
|
|
650
|
-
}
|
|
651
|
-
);
|
|
652
|
-
return /* @__PURE__ */ e(h.Fragment, { children: l ? /* @__PURE__ */ e(
|
|
653
|
-
D,
|
|
654
|
-
{
|
|
655
|
-
sx: {
|
|
656
|
-
backgroundColor: "background.paper",
|
|
657
|
-
px: 0,
|
|
658
|
-
position: "relative",
|
|
659
|
-
"&::after": {
|
|
660
|
-
content: '""',
|
|
661
|
-
position: "absolute",
|
|
662
|
-
bottom: 0,
|
|
663
|
-
right: 0,
|
|
664
|
-
left: y ? 0 : 24,
|
|
665
|
-
borderBottom: "1px solid",
|
|
666
|
-
borderColor: "divider"
|
|
667
|
-
}
|
|
668
|
-
},
|
|
669
|
-
children: /* @__PURE__ */ C(
|
|
670
|
-
$,
|
|
671
|
-
{
|
|
672
|
-
onClick: () => {
|
|
673
|
-
L(s), a(!0), s?.event && o(s.event, { account_guid: n.guid });
|
|
674
|
-
},
|
|
675
|
-
children: [
|
|
676
|
-
x,
|
|
677
|
-
/* @__PURE__ */ e(N, { name: "chevron_right" })
|
|
678
|
-
]
|
|
679
|
-
}
|
|
680
|
-
)
|
|
681
|
-
}
|
|
682
|
-
) : _ && /* @__PURE__ */ e(
|
|
683
|
-
D,
|
|
684
|
-
{
|
|
685
|
-
sx: {
|
|
686
|
-
backgroundColor: "background.paper",
|
|
687
|
-
px: 24,
|
|
688
|
-
position: "relative",
|
|
689
|
-
"&::after": {
|
|
690
|
-
content: '""',
|
|
691
|
-
position: "absolute",
|
|
692
|
-
bottom: 0,
|
|
693
|
-
right: 0,
|
|
694
|
-
left: y ? 0 : 24,
|
|
695
|
-
borderBottom: "1px solid",
|
|
696
|
-
borderColor: "divider"
|
|
697
|
-
}
|
|
698
|
-
},
|
|
699
|
-
children: x
|
|
700
|
-
}
|
|
701
|
-
) }, s.name);
|
|
702
|
-
}),
|
|
703
|
-
d && r && /* @__PURE__ */ e(
|
|
704
|
-
g3,
|
|
705
|
-
{
|
|
706
|
-
field: r,
|
|
707
|
-
isOpen: d,
|
|
708
|
-
onClose: () => a(!1)
|
|
709
|
-
}
|
|
710
|
-
)
|
|
711
|
-
] });
|
|
712
|
-
}, v3 = V(H3), b3 = () => {
|
|
713
|
-
const { onEvent: t } = k();
|
|
714
|
-
return h.useEffect(() => t(w.ACCOUNT_DETAILS_VIEW), []), /* @__PURE__ */ C(O, { children: [
|
|
715
|
-
/* @__PURE__ */ e(v3, {}),
|
|
716
|
-
/* @__PURE__ */ e(L3, {}),
|
|
717
|
-
/* @__PURE__ */ e(p3, {})
|
|
718
|
-
] });
|
|
719
|
-
}, V3 = V(b3), A3 = ({ setTabValue: t }) => {
|
|
720
|
-
const [o, n] = h.useState(!1), { selectedMember: c } = R(), { accounts: i, connect: l } = A(), d = c.connection_status && f1.includes(c.connection_status);
|
|
721
|
-
if (h.useEffect(() => {
|
|
722
|
-
d && t(1);
|
|
723
|
-
}, [d]), !d) return;
|
|
724
|
-
const a = y1(c, l);
|
|
725
|
-
return /* @__PURE__ */ C(S, { children: [
|
|
726
|
-
/* @__PURE__ */ e(
|
|
727
|
-
t3,
|
|
728
|
-
{
|
|
729
|
-
sx: {
|
|
730
|
-
mb: 16,
|
|
731
|
-
mt: 24,
|
|
732
|
-
mx: 24
|
|
733
|
-
},
|
|
734
|
-
children: /* @__PURE__ */ C(
|
|
735
|
-
q1,
|
|
736
|
-
{
|
|
737
|
-
icon: /* @__PURE__ */ e(b1, { filled: !0 }),
|
|
738
|
-
role: "none",
|
|
739
|
-
severity: "error",
|
|
740
|
-
sx: {
|
|
741
|
-
borderLeft: 5,
|
|
742
|
-
borderTopLeftRadius: 6,
|
|
743
|
-
borderBottomLeftRadius: 6,
|
|
744
|
-
borderColor: "error.main",
|
|
745
|
-
color: "text.primary",
|
|
746
|
-
"&.MuiPaper-root": {
|
|
747
|
-
backgroundColor: "background.paper"
|
|
748
|
-
}
|
|
749
|
-
},
|
|
750
|
-
children: [
|
|
751
|
-
a.title && /* @__PURE__ */ e(Q1, { sx: { fontWeight: 600, marginTop: 2 }, variant: "body1", children: a.title }),
|
|
752
|
-
/* @__PURE__ */ e(v, { component: "p", variant: "subtitle2", children: a.main }),
|
|
753
|
-
a.cta && /* @__PURE__ */ e(
|
|
754
|
-
e3,
|
|
755
|
-
{
|
|
756
|
-
onClick: () => n(!0),
|
|
757
|
-
sx: { fontSize: 15, fontWeight: 600, ml: 0 },
|
|
758
|
-
children: a.cta
|
|
759
|
-
}
|
|
760
|
-
)
|
|
761
|
-
]
|
|
762
|
-
}
|
|
763
|
-
)
|
|
764
|
-
}
|
|
765
|
-
),
|
|
766
|
-
o && /* @__PURE__ */ e(
|
|
767
|
-
z,
|
|
768
|
-
{
|
|
769
|
-
loadWidgetProps: { current_member_guid: c.guid },
|
|
770
|
-
onClose: () => n(!1),
|
|
771
|
-
showConnectWidget: o,
|
|
772
|
-
title: i.manage_connection
|
|
773
|
-
}
|
|
774
|
-
)
|
|
775
|
-
] });
|
|
776
|
-
}, y3 = V(A3), M3 = () => {
|
|
777
|
-
const [t, o] = h.useState(""), { onEvent: n } = k(), { selectedAccount: c } = R(), { accounts: i } = A(), { isTransactionDataLoaded: l, loadTransactionData: d, setFilter: a, sortedTransactions: r } = _1();
|
|
778
|
-
h.useEffect(() => {
|
|
779
|
-
l || d().finally();
|
|
780
|
-
}, []);
|
|
781
|
-
const L = h.useMemo(
|
|
782
|
-
() => r.find((m) => m.guid === t),
|
|
783
|
-
[t, r]
|
|
784
|
-
);
|
|
785
|
-
return h.useEffect(() => {
|
|
786
|
-
a({
|
|
787
|
-
dateRange: { start: o3(i3(), 90), end: n3() },
|
|
788
|
-
accounts: [c.guid]
|
|
789
|
-
});
|
|
790
|
-
}, [c]), h.useEffect(() => n(w.ACCOUNT_DETAILS_VIEW_TRANSACTIONS), []), /* @__PURE__ */ C(S, { children: [
|
|
791
|
-
/* @__PURE__ */ e(c3, { onClick: o }),
|
|
792
|
-
L && /* @__PURE__ */ e(
|
|
793
|
-
n1,
|
|
794
|
-
{
|
|
795
|
-
ariaLabelClose: i.close_drawer,
|
|
796
|
-
isOpen: !!t,
|
|
797
|
-
onClose: () => o(""),
|
|
798
|
-
title: i.transaction_drawer_title,
|
|
799
|
-
children: /* @__PURE__ */ e(a3, { transaction: L })
|
|
800
|
-
}
|
|
801
|
-
)
|
|
802
|
-
] });
|
|
803
|
-
}, x3 = V(M3), w3 = () => {
|
|
804
|
-
const [t, o] = h.useState(0), { accounts: n } = A();
|
|
805
|
-
return /* @__PURE__ */ C(S, { children: [
|
|
806
|
-
/* @__PURE__ */ e(y3, { setTabValue: o }),
|
|
807
|
-
/* @__PURE__ */ C(
|
|
808
|
-
Z1,
|
|
809
|
-
{
|
|
810
|
-
"aria-label": n.transactions_and_details_aria,
|
|
811
|
-
centered: !0,
|
|
812
|
-
onChange: (c, i) => o(i),
|
|
813
|
-
textColor: "primary",
|
|
814
|
-
value: t,
|
|
815
|
-
variant: "fullWidth",
|
|
816
|
-
children: [
|
|
817
|
-
/* @__PURE__ */ e(
|
|
818
|
-
s1,
|
|
819
|
-
{
|
|
820
|
-
"aria-controls": "transaction-details-tabpanel-0",
|
|
821
|
-
id: "transaction-details-tab-0",
|
|
822
|
-
label: n.transactions
|
|
823
|
-
}
|
|
824
|
-
),
|
|
825
|
-
/* @__PURE__ */ e(
|
|
826
|
-
s1,
|
|
827
|
-
{
|
|
828
|
-
"aria-controls": "account-details-tabpanel-1",
|
|
829
|
-
id: "account-details-tab-1",
|
|
830
|
-
label: n.account_details
|
|
831
|
-
}
|
|
832
|
-
)
|
|
833
|
-
]
|
|
834
|
-
}
|
|
835
|
-
),
|
|
836
|
-
/* @__PURE__ */ e(u1, { index: 0, name: "transaction-details", value: t, children: /* @__PURE__ */ e(x3, {}) }),
|
|
837
|
-
/* @__PURE__ */ e(u1, { index: 1, name: "account-details", value: t, children: /* @__PURE__ */ e(V3, {}) })
|
|
838
|
-
] });
|
|
839
|
-
}, R3 = V(w3), S3 = () => {
|
|
840
|
-
const [t, o] = h.useState(""), { config: n } = L1(), { accounts: c } = A(), { allSelectedAccounts: i } = G(), { setSelectedAccount: l, setSelectedMember: d } = R(), { members: a } = E(), { onEvent: r } = k(), L = [...new Set(i.map((u) => u.account_type))], m = i.find((u) => t === u.guid), s = h.useMemo(
|
|
841
|
-
() => i.filter((u) => u.is_hidden),
|
|
842
|
-
[i]
|
|
843
|
-
), _ = h.useMemo(
|
|
844
|
-
() => i.filter((u) => u.is_closed),
|
|
845
|
-
[i]
|
|
846
|
-
), y = s.reduce(
|
|
847
|
-
(u, g) => (g.available_balance || g.balance || 0) + u,
|
|
1
|
+
import { jsxs as c, jsx as e } from "react/jsx-runtime";
|
|
2
|
+
import a from "react";
|
|
3
|
+
import { observer as M } from "mobx-react-lite";
|
|
4
|
+
import P from "@mui/material/Stack";
|
|
5
|
+
import { Text as g } from "@mxenabled/mxui";
|
|
6
|
+
import { S as K } from "../SkeletonLoader-BaNboJjD.mjs";
|
|
7
|
+
import I from "@mui/material/Box";
|
|
8
|
+
import y from "@mui/material/Divider";
|
|
9
|
+
import D from "@mui/material/List";
|
|
10
|
+
import O from "@mui/material/ListSubheader";
|
|
11
|
+
import Z from "@mui/system/Stack";
|
|
12
|
+
import { f as U } from "../NumberFormatting--XMeeBfr.mjs";
|
|
13
|
+
import { u as X, g as e1 } from "../AccountDetailsHeader-ByGNPZpO.mjs";
|
|
14
|
+
import { A as K1, a as z1, b as $1 } from "../AccountDetailsHeader-ByGNPZpO.mjs";
|
|
15
|
+
import { A as E, a as t1 } from "../AccountDetailsDrawer-C8oJP3J4.mjs";
|
|
16
|
+
import { b as q1, u as J1 } from "../AccountDetailsDrawer-C8oJP3J4.mjs";
|
|
17
|
+
import { i as z, u as R, a as x, c as N, f as $ } from "../hooks-97sNJ_lf.mjs";
|
|
18
|
+
import { A } from "../Analytics-WeZYytR0.mjs";
|
|
19
|
+
import { C as l1 } from "../ConnectionsDrawer-BHJPKXYF.mjs";
|
|
20
|
+
import { u as Y } from "../useScreenSize-mWpmnh5w.mjs";
|
|
21
|
+
import { u as T } from "../useWidgetLoadTimer-B0tB-yzL.mjs";
|
|
22
|
+
import { L as B } from "../Loader-CxeBwuPG.mjs";
|
|
23
|
+
import { W as n1 } from "../WidgetContainer-D-LzIKFb.mjs";
|
|
24
|
+
import { C as q } from "../ConnectDrawer-DytyIhaF.mjs";
|
|
25
|
+
import i1 from "@mui/material/ListItem";
|
|
26
|
+
import { c as W } from "../Account-DR7Plrqy.mjs";
|
|
27
|
+
import { M as J } from "../MiniWidgetContainer-Bmv_WeUd.mjs";
|
|
28
|
+
import { F as X1, M as e3 } from "../Connect-BH0Pt6zc.mjs";
|
|
29
|
+
const o1 = () => {
|
|
30
|
+
const [i, o] = a.useState(""), { config: C } = z(), { accounts: n } = R(), { allSelectedAccounts: t } = x(), { setSelectedAccount: r, setSelectedMember: u } = X(), { members: h } = N(), { onEvent: H } = $(), m = [...new Set(t.map((l) => l.account_type))], L = t.find((l) => i === l.guid), p = a.useMemo(
|
|
31
|
+
() => t.filter((l) => l.is_hidden),
|
|
32
|
+
[t]
|
|
33
|
+
), V = a.useMemo(
|
|
34
|
+
() => t.filter((l) => l.is_closed),
|
|
35
|
+
[t]
|
|
36
|
+
), b = p.reduce(
|
|
37
|
+
(l, s) => (s.available_balance || s.balance || 0) + l,
|
|
848
38
|
0
|
|
849
|
-
),
|
|
850
|
-
|
|
851
|
-
|
|
852
|
-
|
|
39
|
+
), S = e1(
|
|
40
|
+
V,
|
|
41
|
+
n,
|
|
42
|
+
C.display_available_balance_in_accounts
|
|
853
43
|
);
|
|
854
|
-
|
|
855
|
-
if (
|
|
856
|
-
|
|
857
|
-
const
|
|
858
|
-
|
|
44
|
+
a.useEffect(() => {
|
|
45
|
+
if (L) {
|
|
46
|
+
r(L);
|
|
47
|
+
const l = h.find((s) => s.guid === L?.member_guid) || {};
|
|
48
|
+
l && u(l);
|
|
859
49
|
}
|
|
860
|
-
}, [
|
|
861
|
-
const
|
|
862
|
-
o(
|
|
863
|
-
account_guid:
|
|
864
|
-
account_type:
|
|
50
|
+
}, [L, i]);
|
|
51
|
+
const v = (l) => {
|
|
52
|
+
o(l.guid), H(A.ACCOUNTS_CLICK_ACCOUNT, {
|
|
53
|
+
account_guid: l.guid,
|
|
54
|
+
account_type: l.account_type
|
|
865
55
|
});
|
|
866
|
-
},
|
|
867
|
-
const
|
|
868
|
-
return /* @__PURE__ */ e(
|
|
869
|
-
|
|
56
|
+
}, w = (l) => {
|
|
57
|
+
const s = l === "hidden" ? p : V, k = l === "hidden" ? b : S, d = l === "hidden" ? n.account_hidden : n.account_closed;
|
|
58
|
+
return /* @__PURE__ */ e(I, { children: /* @__PURE__ */ e(
|
|
59
|
+
D,
|
|
870
60
|
{
|
|
871
|
-
"aria-label":
|
|
872
|
-
subheader: /* @__PURE__ */ e(
|
|
873
|
-
|
|
61
|
+
"aria-label": d,
|
|
62
|
+
subheader: /* @__PURE__ */ e(O, { component: "h2", sx: { backgroundColor: "transparent", px: 24 }, children: /* @__PURE__ */ c(
|
|
63
|
+
Z,
|
|
874
64
|
{
|
|
875
65
|
component: "span",
|
|
876
66
|
direction: "row",
|
|
877
67
|
sx: { justifyContent: "space-between", color: "grey.700" },
|
|
878
68
|
children: [
|
|
879
|
-
/* @__PURE__ */ e(
|
|
880
|
-
/* @__PURE__ */ e(
|
|
69
|
+
/* @__PURE__ */ e(g, { bold: !0, variant: "body1", children: d }),
|
|
70
|
+
/* @__PURE__ */ e(g, { bold: !0, variant: "body1", children: U(k, "0,0.00") })
|
|
881
71
|
]
|
|
882
72
|
}
|
|
883
73
|
) }),
|
|
884
|
-
children: /* @__PURE__ */ e(
|
|
885
|
-
const
|
|
886
|
-
return /* @__PURE__ */
|
|
74
|
+
children: /* @__PURE__ */ e(Z, { children: s.map((f, _, Q) => {
|
|
75
|
+
const F = _ === Q.length - 1;
|
|
76
|
+
return /* @__PURE__ */ c(a.Fragment, { children: [
|
|
887
77
|
/* @__PURE__ */ e(
|
|
888
|
-
|
|
78
|
+
E,
|
|
889
79
|
{
|
|
890
|
-
account:
|
|
891
|
-
onRowClick: () =>
|
|
80
|
+
account: f,
|
|
81
|
+
onRowClick: () => v(f),
|
|
892
82
|
shouldShowConnectionStatus: !0
|
|
893
83
|
}
|
|
894
84
|
),
|
|
895
|
-
|
|
896
|
-
|
|
85
|
+
l === "hidden" ? /* @__PURE__ */ e(
|
|
86
|
+
y,
|
|
897
87
|
{
|
|
898
88
|
sx: {
|
|
899
|
-
mb:
|
|
900
|
-
ml:
|
|
89
|
+
mb: F ? 24 : 4,
|
|
90
|
+
ml: F ? 24 : 68
|
|
901
91
|
}
|
|
902
92
|
}
|
|
903
|
-
) : !
|
|
904
|
-
|
|
93
|
+
) : !F && /* @__PURE__ */ e(
|
|
94
|
+
y,
|
|
905
95
|
{
|
|
906
96
|
sx: {
|
|
907
97
|
mb: 4,
|
|
@@ -909,195 +99,189 @@ const r3 = (t, o) => {
|
|
|
909
99
|
}
|
|
910
100
|
}
|
|
911
101
|
)
|
|
912
|
-
] },
|
|
102
|
+
] }, f.guid);
|
|
913
103
|
}) })
|
|
914
104
|
}
|
|
915
105
|
) });
|
|
916
106
|
};
|
|
917
|
-
return /* @__PURE__ */
|
|
918
|
-
|
|
919
|
-
const
|
|
920
|
-
(
|
|
921
|
-
),
|
|
922
|
-
(
|
|
107
|
+
return /* @__PURE__ */ c(I, { children: [
|
|
108
|
+
m.map((l) => {
|
|
109
|
+
const s = t.filter(
|
|
110
|
+
(d) => d.account_type === l && !d.is_closed && !d.is_hidden
|
|
111
|
+
), k = s.reduce(
|
|
112
|
+
(d, f) => (f.balance || 0) + d,
|
|
923
113
|
0
|
|
924
114
|
);
|
|
925
|
-
return
|
|
926
|
-
|
|
115
|
+
return s.length === 0 ? null : /* @__PURE__ */ e(
|
|
116
|
+
D,
|
|
927
117
|
{
|
|
928
|
-
"aria-label":
|
|
929
|
-
subheader: /* @__PURE__ */ e(
|
|
930
|
-
|
|
118
|
+
"aria-label": n.account_type_accounts[s[0]?.account_type],
|
|
119
|
+
subheader: /* @__PURE__ */ e(O, { component: "h2", sx: { backgroundColor: "transparent", px: 24 }, children: /* @__PURE__ */ c(
|
|
120
|
+
Z,
|
|
931
121
|
{
|
|
932
122
|
component: "span",
|
|
933
123
|
direction: "row",
|
|
934
124
|
sx: { display: "flex", justifyContent: "space-between" },
|
|
935
125
|
children: [
|
|
936
|
-
/* @__PURE__ */ e(
|
|
937
|
-
/* @__PURE__ */ e(
|
|
126
|
+
/* @__PURE__ */ e(g, { bold: !0, variant: "body1", children: n.account_types[l] }),
|
|
127
|
+
/* @__PURE__ */ e(g, { bold: !0, variant: "body1", children: U(k, "0,0.00") })
|
|
938
128
|
]
|
|
939
129
|
}
|
|
940
130
|
) }),
|
|
941
|
-
children: /* @__PURE__ */ e(
|
|
942
|
-
const
|
|
943
|
-
return /* @__PURE__ */
|
|
131
|
+
children: /* @__PURE__ */ e(Z, { children: s.map((d) => {
|
|
132
|
+
const f = t.indexOf(d) === t.length - 1, _ = s.indexOf(d) === s.length - 1;
|
|
133
|
+
return /* @__PURE__ */ c(a.Fragment, { children: [
|
|
944
134
|
/* @__PURE__ */ e(
|
|
945
|
-
|
|
135
|
+
E,
|
|
946
136
|
{
|
|
947
|
-
account:
|
|
948
|
-
onRowClick: () =>
|
|
137
|
+
account: d,
|
|
138
|
+
onRowClick: () => v(d),
|
|
949
139
|
shouldShowConnectionStatus: !0
|
|
950
140
|
}
|
|
951
141
|
),
|
|
952
|
-
(!
|
|
953
|
-
|
|
142
|
+
(!f || V.length > 0 || p.length > 0) && /* @__PURE__ */ e(
|
|
143
|
+
y,
|
|
954
144
|
{
|
|
955
145
|
sx: {
|
|
956
|
-
mb:
|
|
957
|
-
ml:
|
|
146
|
+
mb: _ ? 24 : 4,
|
|
147
|
+
ml: _ ? 24 : 68
|
|
958
148
|
}
|
|
959
149
|
}
|
|
960
150
|
)
|
|
961
|
-
] },
|
|
151
|
+
] }, d.guid);
|
|
962
152
|
}) })
|
|
963
153
|
},
|
|
964
|
-
|
|
154
|
+
l
|
|
965
155
|
);
|
|
966
156
|
}),
|
|
967
|
-
|
|
968
|
-
|
|
969
|
-
/* @__PURE__ */
|
|
970
|
-
|
|
157
|
+
p.length > 0 && w("hidden"),
|
|
158
|
+
V.length > 0 && w("closed"),
|
|
159
|
+
/* @__PURE__ */ e(
|
|
160
|
+
t1,
|
|
971
161
|
{
|
|
972
|
-
|
|
973
|
-
|
|
974
|
-
onClose: () => o(""),
|
|
975
|
-
title: c.account_details,
|
|
976
|
-
children: [
|
|
977
|
-
/* @__PURE__ */ e(w1, { ChartComponent: C3 }),
|
|
978
|
-
/* @__PURE__ */ e(R3, {})
|
|
979
|
-
]
|
|
162
|
+
isOpen: !!i,
|
|
163
|
+
onClose: () => o("")
|
|
980
164
|
}
|
|
981
165
|
)
|
|
982
166
|
] });
|
|
983
|
-
},
|
|
984
|
-
const [
|
|
985
|
-
|
|
167
|
+
}, C1 = M(o1), d1 = ({ onBackClick: i, onMenuClick: o, sx: C = {} }) => {
|
|
168
|
+
const [n, t] = a.useState(!1), [r, u] = a.useState(!1), { config: h } = z(), { isAccountDataLoaded: H, loadAccountData: m } = N(), { accounts: L, connect: p } = R(), { isInitialized: V, selectedAccountGuids: b } = x(), { isDesktop: S } = Y(), { onEvent: v } = $();
|
|
169
|
+
T({
|
|
986
170
|
widgetName: "AccountsWidget",
|
|
987
|
-
isLoaded:
|
|
988
|
-
}),
|
|
989
|
-
|
|
171
|
+
isLoaded: H
|
|
172
|
+
}), a.useEffect(() => {
|
|
173
|
+
H || m().finally();
|
|
990
174
|
}, []);
|
|
991
|
-
const
|
|
992
|
-
|
|
993
|
-
},
|
|
994
|
-
|
|
175
|
+
const w = () => {
|
|
176
|
+
t(!0), v(A.ACCOUNTS_CLICK_CONNECT);
|
|
177
|
+
}, l = () => {
|
|
178
|
+
u(!0), v(A.ACCOUNTS_CLICK_CONNECT);
|
|
995
179
|
};
|
|
996
|
-
return
|
|
997
|
-
|
|
180
|
+
return V ? /* @__PURE__ */ c(
|
|
181
|
+
n1,
|
|
998
182
|
{
|
|
999
|
-
actions:
|
|
1000
|
-
{ iconName: "add", label:
|
|
183
|
+
actions: h.show_connections_widget_in_master ? [
|
|
184
|
+
{ iconName: "add", label: L.add, onClick: w },
|
|
1001
185
|
{
|
|
1002
186
|
iconName: "credit_card_gear",
|
|
1003
|
-
label:
|
|
1004
|
-
onClick:
|
|
187
|
+
label: L.manage,
|
|
188
|
+
onClick: l
|
|
1005
189
|
}
|
|
1006
190
|
] : [],
|
|
1007
191
|
hasDivider: !0,
|
|
1008
|
-
onAccountsFilterClick: () =>
|
|
1009
|
-
onBackClick:
|
|
192
|
+
onAccountsFilterClick: () => v(A.ACCOUNTS_CLICK_FILTER),
|
|
193
|
+
onBackClick: i,
|
|
1010
194
|
onMenuClick: o,
|
|
1011
|
-
sx:
|
|
1012
|
-
title:
|
|
195
|
+
sx: C,
|
|
196
|
+
title: L.title,
|
|
1013
197
|
children: [
|
|
1014
|
-
|
|
1015
|
-
|
|
1016
|
-
/* @__PURE__ */ e(
|
|
1017
|
-
] }) : /* @__PURE__ */ e(
|
|
198
|
+
H ? /* @__PURE__ */ c(P, { children: [
|
|
199
|
+
b.length < 1 && /* @__PURE__ */ e(g, { display: "flex", justifyContent: "center", my: 24, children: L.no_accounts }),
|
|
200
|
+
/* @__PURE__ */ e(C1, {})
|
|
201
|
+
] }) : /* @__PURE__ */ e(K, { sx: { px: S ? 48 : 24, pt: 24 }, variant: "list" }),
|
|
1018
202
|
/* @__PURE__ */ e(
|
|
1019
|
-
|
|
203
|
+
q,
|
|
1020
204
|
{
|
|
1021
|
-
onClose: () =>
|
|
1022
|
-
showConnectWidget:
|
|
1023
|
-
title:
|
|
205
|
+
onClose: () => t(!1),
|
|
206
|
+
showConnectWidget: n,
|
|
207
|
+
title: p.mini_title
|
|
1024
208
|
}
|
|
1025
209
|
),
|
|
1026
210
|
/* @__PURE__ */ e(
|
|
1027
|
-
|
|
211
|
+
l1,
|
|
1028
212
|
{
|
|
1029
|
-
onClose: () =>
|
|
1030
|
-
showConnectionsWidget:
|
|
1031
|
-
title:
|
|
213
|
+
onClose: () => u(!1),
|
|
214
|
+
showConnectionsWidget: r,
|
|
215
|
+
title: L.manage_connections
|
|
1032
216
|
}
|
|
1033
217
|
)
|
|
1034
218
|
]
|
|
1035
219
|
}
|
|
1036
|
-
) : /* @__PURE__ */ e(
|
|
1037
|
-
},
|
|
1038
|
-
function
|
|
1039
|
-
const { heldAccounts: o, externalAccounts:
|
|
1040
|
-
(
|
|
220
|
+
) : /* @__PURE__ */ e(B, {});
|
|
221
|
+
}, O1 = M(d1);
|
|
222
|
+
function c1(i) {
|
|
223
|
+
const { heldAccounts: o, externalAccounts: C } = i.reduce(
|
|
224
|
+
(n, t) => (t.member_is_managed_by_user ? n.externalAccounts.push(t) : n.heldAccounts.push(t), n),
|
|
1041
225
|
{ heldAccounts: [], externalAccounts: [] }
|
|
1042
226
|
);
|
|
1043
227
|
return {
|
|
1044
|
-
heldAccounts:
|
|
1045
|
-
externalAccounts:
|
|
228
|
+
heldAccounts: j(o),
|
|
229
|
+
externalAccounts: j(C)
|
|
1046
230
|
};
|
|
1047
231
|
}
|
|
1048
|
-
function
|
|
1049
|
-
const { heldAccounts:
|
|
1050
|
-
return
|
|
232
|
+
function s1(i, o) {
|
|
233
|
+
const { heldAccounts: C, externalAccounts: n } = c1(i), t = C.slice(0, o);
|
|
234
|
+
return t.length < o && t.push(...n.slice(0, o - t.length)), t;
|
|
1051
235
|
}
|
|
1052
|
-
const
|
|
1053
|
-
[
|
|
1054
|
-
[
|
|
1055
|
-
[
|
|
1056
|
-
},
|
|
1057
|
-
const
|
|
1058
|
-
if (
|
|
1059
|
-
const
|
|
1060
|
-
return
|
|
1061
|
-
}),
|
|
1062
|
-
const { isAccountDataLoaded:
|
|
1063
|
-
|
|
236
|
+
const a1 = {
|
|
237
|
+
[W.CHECKING]: 1,
|
|
238
|
+
[W.SAVINGS]: 2,
|
|
239
|
+
[W.CREDIT_CARD]: 3
|
|
240
|
+
}, G = (i) => a1[i] ?? i + 100, j = (i) => i.sort((o, C) => {
|
|
241
|
+
const n = G(o.account_type), t = G(C.account_type), r = n - t;
|
|
242
|
+
if (r !== 0) return r;
|
|
243
|
+
const u = o.name ?? o.feed_name ?? "", h = C.name ?? C.feed_name ?? "";
|
|
244
|
+
return u.localeCompare(h);
|
|
245
|
+
}), r1 = ({ onPrimaryCtaClick: i, sx: o }) => {
|
|
246
|
+
const { isAccountDataLoaded: C, loadAccountData: n } = N(), { accounts: t } = R(), { isInitialized: r, selectedAccounts: u } = x(), { isDesktop: h } = Y();
|
|
247
|
+
T({
|
|
1064
248
|
widgetName: "AccountsMiniWidget",
|
|
1065
|
-
isLoaded:
|
|
1066
|
-
}),
|
|
1067
|
-
|
|
249
|
+
isLoaded: r
|
|
250
|
+
}), a.useEffect(() => {
|
|
251
|
+
C || n().finally();
|
|
1068
252
|
}, []);
|
|
1069
|
-
const
|
|
1070
|
-
() =>
|
|
1071
|
-
[
|
|
253
|
+
const H = a.useMemo(
|
|
254
|
+
() => s1(u, h ? 5 : 3),
|
|
255
|
+
[u, h]
|
|
1072
256
|
);
|
|
1073
|
-
return
|
|
1074
|
-
|
|
257
|
+
return r ? /* @__PURE__ */ e(
|
|
258
|
+
J,
|
|
1075
259
|
{
|
|
1076
260
|
className: "mx-exp-accounts-miniwidget",
|
|
1077
|
-
onPrimaryCtaClick:
|
|
1078
|
-
primaryCtaLabel:
|
|
261
|
+
onPrimaryCtaClick: i,
|
|
262
|
+
primaryCtaLabel: t.primary_cta,
|
|
1079
263
|
sx: o,
|
|
1080
|
-
title:
|
|
1081
|
-
children:
|
|
1082
|
-
|
|
1083
|
-
|
|
1084
|
-
const
|
|
1085
|
-
return /* @__PURE__ */
|
|
264
|
+
title: t.mini_title,
|
|
265
|
+
children: C ? /* @__PURE__ */ c(D, { children: [
|
|
266
|
+
u.length === 0 && /* @__PURE__ */ e(i1, { sx: { justifyContent: "center" }, children: t.no_accounts }),
|
|
267
|
+
H.map((m, L) => {
|
|
268
|
+
const p = H.indexOf(m) === H.length - 1;
|
|
269
|
+
return /* @__PURE__ */ c(a.Fragment, { children: [
|
|
1086
270
|
/* @__PURE__ */ e(
|
|
1087
|
-
|
|
271
|
+
E,
|
|
1088
272
|
{
|
|
1089
|
-
account:
|
|
273
|
+
account: m,
|
|
1090
274
|
listItemProps: { sx: { px: 24 } },
|
|
1091
275
|
shouldShowConnectionStatus: !0
|
|
1092
276
|
}
|
|
1093
277
|
),
|
|
1094
|
-
!
|
|
1095
|
-
] }, `account-item${
|
|
278
|
+
!p && /* @__PURE__ */ e(y, { "aria-hidden": "true", variant: "inset" })
|
|
279
|
+
] }, `account-item${L}`);
|
|
1096
280
|
})
|
|
1097
|
-
] }) : /* @__PURE__ */ e(
|
|
281
|
+
] }) : /* @__PURE__ */ e(K, { sx: { px: 12, py: 8 }, variant: "list" })
|
|
1098
282
|
}
|
|
1099
|
-
) : /* @__PURE__ */ e(
|
|
1100
|
-
},
|
|
283
|
+
) : /* @__PURE__ */ e(B, {});
|
|
284
|
+
}, U1 = M(r1), u1 = () => /* @__PURE__ */ c(
|
|
1101
285
|
"svg",
|
|
1102
286
|
{
|
|
1103
287
|
fill: "none",
|
|
@@ -1105,7 +289,7 @@ const I3 = {
|
|
|
1105
289
|
viewBox: "0 0 272 66",
|
|
1106
290
|
xmlns: "http://www.w3.org/2000/svg",
|
|
1107
291
|
children: [
|
|
1108
|
-
/* @__PURE__ */
|
|
292
|
+
/* @__PURE__ */ c("g", { opacity: "0.35", children: [
|
|
1109
293
|
/* @__PURE__ */ e("rect", { fill: "#CD1141", height: "40.3437", rx: "2.81371", width: "39.6876", x: "19.6553" }),
|
|
1110
294
|
/* @__PURE__ */ e(
|
|
1111
295
|
"path",
|
|
@@ -1391,7 +575,7 @@ const I3 = {
|
|
|
1391
575
|
children: /* @__PURE__ */ e("rect", { fill: "white", height: "47.5848", rx: "3.31025", width: "46.8064", x: "113.168", y: "18.1035" })
|
|
1392
576
|
}
|
|
1393
577
|
),
|
|
1394
|
-
/* @__PURE__ */
|
|
578
|
+
/* @__PURE__ */ c("g", { mask: "url(#mask1_6197_80303)", children: [
|
|
1395
579
|
/* @__PURE__ */ e(
|
|
1396
580
|
"mask",
|
|
1397
581
|
{
|
|
@@ -1536,65 +720,66 @@ const I3 = {
|
|
|
1536
720
|
)
|
|
1537
721
|
]
|
|
1538
722
|
}
|
|
1539
|
-
),
|
|
1540
|
-
const { connect:
|
|
1541
|
-
return /* @__PURE__ */
|
|
1542
|
-
/* @__PURE__ */ e(
|
|
723
|
+
), L1 = () => {
|
|
724
|
+
const { connect: i } = R();
|
|
725
|
+
return /* @__PURE__ */ c(P, { alignItems: "center", direction: "column", m: 24, children: [
|
|
726
|
+
/* @__PURE__ */ e(u1, {}),
|
|
1543
727
|
/* @__PURE__ */ e(
|
|
1544
|
-
|
|
728
|
+
g,
|
|
1545
729
|
{
|
|
1546
730
|
sx: {
|
|
1547
731
|
mt: 16,
|
|
1548
732
|
textAlign: "center"
|
|
1549
733
|
},
|
|
1550
734
|
variant: "subtitle1",
|
|
1551
|
-
children:
|
|
735
|
+
children: i.mini_widget_content
|
|
1552
736
|
}
|
|
1553
737
|
)
|
|
1554
738
|
] });
|
|
1555
|
-
},
|
|
1556
|
-
onPrimaryCtaClick:
|
|
739
|
+
}, H1 = M(L1), h1 = ({
|
|
740
|
+
onPrimaryCtaClick: i = () => {
|
|
1557
741
|
},
|
|
1558
742
|
sx: o
|
|
1559
743
|
}) => {
|
|
1560
|
-
const { isCopyLoaded:
|
|
1561
|
-
|
|
744
|
+
const { isCopyLoaded: C } = x(), { connect: n } = R(), [t, r] = a.useState(!1), u = () => {
|
|
745
|
+
r(!0), i();
|
|
1562
746
|
};
|
|
1563
|
-
return
|
|
747
|
+
return T({
|
|
1564
748
|
widgetName: "ConnectMiniWidget",
|
|
1565
|
-
isLoaded:
|
|
1566
|
-
}),
|
|
1567
|
-
|
|
749
|
+
isLoaded: C
|
|
750
|
+
}), C ? /* @__PURE__ */ c(
|
|
751
|
+
J,
|
|
1568
752
|
{
|
|
1569
753
|
className: "mx-exp-connect-miniwidget",
|
|
1570
|
-
onPrimaryCtaClick:
|
|
1571
|
-
primaryCtaLabel:
|
|
754
|
+
onPrimaryCtaClick: u,
|
|
755
|
+
primaryCtaLabel: n.primary_cta,
|
|
1572
756
|
sx: o,
|
|
1573
|
-
title:
|
|
757
|
+
title: n.mini_title,
|
|
1574
758
|
children: [
|
|
1575
|
-
/* @__PURE__ */ e(
|
|
1576
|
-
|
|
1577
|
-
|
|
759
|
+
/* @__PURE__ */ e(H1, {}),
|
|
760
|
+
t && /* @__PURE__ */ e(
|
|
761
|
+
q,
|
|
1578
762
|
{
|
|
1579
|
-
onClose: () =>
|
|
1580
|
-
showConnectWidget:
|
|
1581
|
-
title:
|
|
763
|
+
onClose: () => r(!1),
|
|
764
|
+
showConnectWidget: t,
|
|
765
|
+
title: n.mini_title
|
|
1582
766
|
}
|
|
1583
767
|
)
|
|
1584
768
|
]
|
|
1585
769
|
}
|
|
1586
|
-
) : /* @__PURE__ */ e(
|
|
1587
|
-
},
|
|
770
|
+
) : /* @__PURE__ */ e(B, {});
|
|
771
|
+
}, G1 = M(h1);
|
|
1588
772
|
export {
|
|
1589
|
-
|
|
1590
|
-
|
|
1591
|
-
|
|
1592
|
-
|
|
1593
|
-
|
|
1594
|
-
|
|
1595
|
-
|
|
1596
|
-
|
|
1597
|
-
|
|
1598
|
-
|
|
1599
|
-
|
|
773
|
+
q1 as AccountDetailsContent,
|
|
774
|
+
t1 as AccountDetailsDrawer,
|
|
775
|
+
K1 as AccountDetailsHeader,
|
|
776
|
+
U1 as AccountsMiniWidget,
|
|
777
|
+
O1 as AccountsWidget,
|
|
778
|
+
G1 as ConnectMiniWidget,
|
|
779
|
+
X1 as FieldType,
|
|
780
|
+
e3 as MemberConnectionStatus,
|
|
781
|
+
z1 as getAccountBalanceDetails,
|
|
782
|
+
$1 as getAccountDetailFields,
|
|
783
|
+
X as useAccountUiStore,
|
|
784
|
+
J1 as useGetMergeableAccounts
|
|
1600
785
|
};
|