@mx-cartographer/experiences 8.1.6 → 8.1.8
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 +8 -0
- package/dist/AccountDetailsHeader-D8NIfmO8.mjs +95 -0
- package/dist/{AccountFields-nrrEXd46.mjs → AccountFields-BWmpVsS3.mjs} +51 -51
- package/dist/AccountListItem-DSuv36PF.mjs +95 -0
- package/dist/accounts/index.es.js +424 -420
- package/dist/accounts/utils/AccountFields.d.ts +2 -2
- package/dist/cashflow/index.es.js +1 -1
- package/dist/debts/index.es.js +1 -1
- package/dist/finstrong/index.es.js +11 -3
- package/dist/goals/index.es.js +373 -372
- package/package.json +1 -1
- package/dist/AccountDetailsHeader-D_a0XUkL.mjs +0 -95
- package/dist/AccountListItem-D80egD01.mjs +0 -94
|
@@ -1,97 +1,97 @@
|
|
|
1
|
-
import { jsx as e, jsxs as C, Fragment as
|
|
1
|
+
import { jsx as e, jsxs as C, Fragment as S } from "react/jsx-runtime";
|
|
2
2
|
import h from "react";
|
|
3
|
-
import { observer as
|
|
4
|
-
import
|
|
5
|
-
import { Text as
|
|
6
|
-
import { S as
|
|
7
|
-
import
|
|
3
|
+
import { observer as A } from "mobx-react-lite";
|
|
4
|
+
import t1 from "@mui/material/Stack";
|
|
5
|
+
import { Text as v, Icon as N, THEMES as c1 } from "@mxenabled/mxui";
|
|
6
|
+
import { S as m1 } from "../SkeletonLoader-BaNboJjD.mjs";
|
|
7
|
+
import a1 from "@mui/material/Box";
|
|
8
8
|
import W from "@mui/material/Divider";
|
|
9
9
|
import O from "@mui/material/List";
|
|
10
10
|
import B from "@mui/material/ListSubheader";
|
|
11
11
|
import P from "@mui/system/Stack";
|
|
12
|
-
import { useTheme as
|
|
13
|
-
import { u as
|
|
14
|
-
import { L as
|
|
15
|
-
import { g as
|
|
16
|
-
import { l as
|
|
17
|
-
import { A as I, g as
|
|
18
|
-
import { I as
|
|
19
|
-
import { a as
|
|
20
|
-
import { g as
|
|
21
|
-
import { A as U } from "../AccountListItem-
|
|
22
|
-
import
|
|
23
|
-
import
|
|
24
|
-
import
|
|
25
|
-
import
|
|
12
|
+
import { useTheme as y1, alpha as w1 } from "@mui/material/styles";
|
|
13
|
+
import { u as R, A as x1 } from "../AccountDetailsHeader-D8NIfmO8.mjs";
|
|
14
|
+
import { L as R1 } from "../LineChart-jJVBE8V8.mjs";
|
|
15
|
+
import { g as S1, a as T1, b as E1 } from "../SpendingData-Dj85XEUp.mjs";
|
|
16
|
+
import { l as D1, u as V, d as D, g as k, h as p1, a as _1, b as G } from "../hooks-HwStH7q_.mjs";
|
|
17
|
+
import { A as I, g as f, N as L1 } from "../Account-CMjOp7S2.mjs";
|
|
18
|
+
import { I as f1, P as g1, S as H1 } from "../Account-BIKn4XEZ.mjs";
|
|
19
|
+
import { a as k1, b as I1 } from "../AccountFields-BWmpVsS3.mjs";
|
|
20
|
+
import { g as c2 } from "../AccountFields-BWmpVsS3.mjs";
|
|
21
|
+
import { A as U } from "../AccountListItem-DSuv36PF.mjs";
|
|
22
|
+
import s1 from "@mui/material/Tab";
|
|
23
|
+
import Z1 from "@mui/material/Tabs";
|
|
24
|
+
import N1 from "@mui/material/Switch";
|
|
25
|
+
import E from "@mui/material/ListItem";
|
|
26
26
|
import $ from "@mui/material/ListItemButton";
|
|
27
27
|
import Z from "@mui/material/ListItemText";
|
|
28
|
-
import { A as
|
|
29
|
-
import { D as
|
|
30
|
-
import { b as
|
|
31
|
-
import { D as
|
|
32
|
-
import
|
|
33
|
-
import
|
|
34
|
-
import { Language as
|
|
28
|
+
import { A as x } from "../Analytics-CzGzz_sE.mjs";
|
|
29
|
+
import { D as e1 } from "../Dialog-iLlBR8TG.mjs";
|
|
30
|
+
import { b as H } from "../Localization-CkQ49EKr.mjs";
|
|
31
|
+
import { D as n1 } from "../Drawer-XPaLYjiO.mjs";
|
|
32
|
+
import j from "@mui/material/ListItemAvatar";
|
|
33
|
+
import O1 from "@mui/material/styles/useTheme";
|
|
34
|
+
import { Language as F1, Error as v1, CheckCircle as P1 } from "@mxenabled/mx-icons";
|
|
35
35
|
import { C as z } from "../ConnectDrawer-5BpU4IQU.mjs";
|
|
36
|
-
import { fromUnixTime as
|
|
37
|
-
import { isToday as
|
|
38
|
-
import { isYesterday as
|
|
39
|
-
import { f as
|
|
40
|
-
import { I as
|
|
41
|
-
import { addMonths as
|
|
42
|
-
import { AdapterDateFns as
|
|
43
|
-
import { DateCalendar as
|
|
44
|
-
import
|
|
45
|
-
import
|
|
46
|
-
import { LocalizationProvider as
|
|
47
|
-
import
|
|
48
|
-
import
|
|
49
|
-
import
|
|
50
|
-
import { F as
|
|
51
|
-
import { M as
|
|
52
|
-
import { C as
|
|
53
|
-
import
|
|
54
|
-
import
|
|
55
|
-
import
|
|
56
|
-
import
|
|
57
|
-
import { endOfToday as
|
|
58
|
-
import { T as
|
|
59
|
-
import { T as
|
|
60
|
-
import { T as
|
|
61
|
-
import { f as
|
|
62
|
-
import { C as
|
|
63
|
-
import { u as
|
|
64
|
-
import { u as
|
|
65
|
-
import { L as
|
|
66
|
-
import { W as
|
|
67
|
-
import { M as
|
|
68
|
-
import { A as
|
|
69
|
-
const
|
|
70
|
-
const n =
|
|
71
|
-
return [n,
|
|
72
|
-
},
|
|
73
|
-
const [
|
|
74
|
-
if (l &&
|
|
36
|
+
import { fromUnixTime as W1 } from "date-fns/fromUnixTime";
|
|
37
|
+
import { isToday as B1 } from "date-fns/isToday";
|
|
38
|
+
import { isYesterday as U1 } from "date-fns/isYesterday";
|
|
39
|
+
import { f as l1, D as r1 } from "../DateFormats-CaOj_4eI.mjs";
|
|
40
|
+
import { I as X } from "../IconBacking-DgT8DCeh.mjs";
|
|
41
|
+
import { addMonths as $1 } from "date-fns/addMonths";
|
|
42
|
+
import { AdapterDateFns as G1 } from "@mui/x-date-pickers/AdapterDateFnsV3";
|
|
43
|
+
import { DateCalendar as z1 } from "@mui/x-date-pickers/DateCalendar";
|
|
44
|
+
import K1 from "@mui/material/FormControl";
|
|
45
|
+
import Y1 from "@mui/material/InputLabel";
|
|
46
|
+
import { LocalizationProvider as j1 } from "@mui/x-date-pickers-pro";
|
|
47
|
+
import X1 from "@mui/material/MenuItem";
|
|
48
|
+
import J1 from "@mui/material/Select";
|
|
49
|
+
import q1 from "@mui/material/TextField";
|
|
50
|
+
import { F as J } from "../Accounts-CseLC3lL.mjs";
|
|
51
|
+
import { M as s2 } from "../Accounts-CseLC3lL.mjs";
|
|
52
|
+
import { C as Q1 } from "../CurrencyInput-CSJ3zMgE.mjs";
|
|
53
|
+
import e3 from "@mui/material/Alert";
|
|
54
|
+
import t3 from "@mui/material/AlertTitle";
|
|
55
|
+
import n3 from "@mui/material/Link";
|
|
56
|
+
import o3 from "@mui/material/Paper";
|
|
57
|
+
import { endOfToday as i3, subDays as c3, startOfToday as a3 } from "date-fns";
|
|
58
|
+
import { T as s3 } from "../EmbeddedCard-BqVpA1Jn.mjs";
|
|
59
|
+
import { T as l3 } from "../TransactionDetails-Bpp1FDUI.mjs";
|
|
60
|
+
import { T as d1 } from "../TabContentContainer-CnMXkVqr.mjs";
|
|
61
|
+
import { f as u1 } from "../NumberFormatting-CyrvFgfd.mjs";
|
|
62
|
+
import { C as r3 } from "../ConnectionsDrawer-DxpSlJN7.mjs";
|
|
63
|
+
import { u as b1 } from "../useScreenSize-CeFhWTt_.mjs";
|
|
64
|
+
import { u as o1 } from "../useWidgetLoadTimer-wkBTL5xx.mjs";
|
|
65
|
+
import { L as i1 } from "../Loader-CxeBwuPG.mjs";
|
|
66
|
+
import { W as d3 } from "../WidgetContainer-_Fzy--dt.mjs";
|
|
67
|
+
import { M as A1 } from "../MiniWidgetContainer-CmTGSUL5.mjs";
|
|
68
|
+
import { A as r2 } from "../AccountStore-B3S_p5Qa.mjs";
|
|
69
|
+
const u3 = (t, o) => {
|
|
70
|
+
const n = f1.includes(o) ? S1(t) : [], c = g1.includes(o) ? T1(t) : [], i = H1.includes(o) ? E1(t) : [];
|
|
71
|
+
return [n, c, i].filter((l) => l.length > 0);
|
|
72
|
+
}, C3 = (t, o, n) => {
|
|
73
|
+
const [c, i] = t, l = c, d = i ?? c, a = [];
|
|
74
|
+
if (l && d && f1.includes(o)) {
|
|
75
75
|
const r = l[l.length - 1].y;
|
|
76
76
|
a.push({ label: n.income_label, amount: r });
|
|
77
|
-
} else if (
|
|
77
|
+
} else if (g1.includes(o)) {
|
|
78
78
|
const r = l[l.length - 1].y;
|
|
79
79
|
a.push({ label: n.payments_label, amount: r });
|
|
80
80
|
}
|
|
81
|
-
if (
|
|
82
|
-
const r =
|
|
81
|
+
if (d && H1.includes(o)) {
|
|
82
|
+
const r = d[d.length - 1].y;
|
|
83
83
|
a.push({ label: n.spending_label, amount: r });
|
|
84
84
|
}
|
|
85
85
|
return a;
|
|
86
|
-
},
|
|
87
|
-
const t =
|
|
86
|
+
}, h3 = () => {
|
|
87
|
+
const t = y1(), { selectedAccount: o } = R(), { monthlyCategoryTotals: n } = D1(), { trends: c } = V(), i = [t.palette.chart?.chart1, t.palette.chart?.chart2], l = u3(n, o.account_type), d = C3(l, o.account_type, c), a = [I.LOAN, I.MORTGAGE].includes(o.account_type);
|
|
88
88
|
return /* @__PURE__ */ e("div", { "data-testid": "TrendsChart", children: /* @__PURE__ */ e(
|
|
89
|
-
|
|
89
|
+
R1,
|
|
90
90
|
{
|
|
91
|
-
colors:
|
|
91
|
+
colors: i,
|
|
92
92
|
datasets: l,
|
|
93
93
|
height: 185,
|
|
94
|
-
labels:
|
|
94
|
+
labels: d,
|
|
95
95
|
showAverage: a,
|
|
96
96
|
showAxisHighlight: !0,
|
|
97
97
|
showBars: a,
|
|
@@ -104,15 +104,15 @@ const d3 = (t, o) => {
|
|
|
104
104
|
valueFormatterString: "0,0"
|
|
105
105
|
}
|
|
106
106
|
) });
|
|
107
|
-
},
|
|
107
|
+
}, m3 = A(h3), q = ({
|
|
108
108
|
ariaPressed: t,
|
|
109
109
|
children: o,
|
|
110
110
|
isLast: n = !1,
|
|
111
|
-
onClick:
|
|
112
|
-
primaryText:
|
|
111
|
+
onClick: c,
|
|
112
|
+
primaryText: i,
|
|
113
113
|
secondaryText: l
|
|
114
114
|
}) => /* @__PURE__ */ e(
|
|
115
|
-
|
|
115
|
+
E,
|
|
116
116
|
{
|
|
117
117
|
sx: {
|
|
118
118
|
backgroundColor: "background.paper",
|
|
@@ -127,46 +127,46 @@ const d3 = (t, o) => {
|
|
|
127
127
|
borderColor: "divider"
|
|
128
128
|
}
|
|
129
129
|
},
|
|
130
|
-
children: /* @__PURE__ */ C($, { "aria-pressed": t, onClick:
|
|
131
|
-
/* @__PURE__ */ e(Z, { primary:
|
|
130
|
+
children: /* @__PURE__ */ C($, { "aria-pressed": t, onClick: c, children: [
|
|
131
|
+
/* @__PURE__ */ e(Z, { primary: i, secondary: l }),
|
|
132
132
|
o
|
|
133
133
|
] })
|
|
134
134
|
}
|
|
135
|
-
),
|
|
136
|
-
const { accounts: t } =
|
|
135
|
+
), p3 = () => {
|
|
136
|
+
const { accounts: t } = D(), { selectedAccount: o, selectedMember: n } = R();
|
|
137
137
|
return t.filter(
|
|
138
|
-
(
|
|
138
|
+
(c) => c.member_guid === n.guid && n.successfully_aggregated_at && c.guid !== o.guid
|
|
139
139
|
);
|
|
140
|
-
},
|
|
141
|
-
const [t, o] = h.useState(!1), [n,
|
|
142
|
-
await
|
|
140
|
+
}, _3 = () => {
|
|
141
|
+
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 } = D(), { accounts: s } = V(), _ = p3(), { onEvent: M } = k(), { modifyTransactionByAccountGuid: w } = p1(), y = async (u) => {
|
|
142
|
+
await m({
|
|
143
143
|
...r,
|
|
144
|
-
...
|
|
145
|
-
}), "is_closed" in
|
|
146
|
-
},
|
|
147
|
-
|
|
148
|
-
() =>
|
|
144
|
+
...u
|
|
145
|
+
}), "is_closed" in u && u.is_closed !== r.is_closed && w(r.guid, { accountIsClosed: u.is_closed });
|
|
146
|
+
}, p = () => {
|
|
147
|
+
L([r.guid, d.guid]).finally(
|
|
148
|
+
() => c(!1)
|
|
149
149
|
);
|
|
150
150
|
};
|
|
151
|
-
return /* @__PURE__ */ C(
|
|
152
|
-
/* @__PURE__ */ e(B, { sx: { backgroundColor: "transparent", mb: 4, mt: 12, mx: 8 }, children: /* @__PURE__ */ e(
|
|
151
|
+
return /* @__PURE__ */ C(S, { children: [
|
|
152
|
+
/* @__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 }) }),
|
|
153
153
|
/* @__PURE__ */ e(
|
|
154
|
-
|
|
154
|
+
q,
|
|
155
155
|
{
|
|
156
156
|
ariaPressed: r.is_hidden,
|
|
157
157
|
onClick: () => {
|
|
158
|
-
y({ is_hidden: !r.is_hidden }),
|
|
158
|
+
y({ is_hidden: !r.is_hidden }), M(x.ACCOUNT_DETAILS_CLICK_HIDE, { account_guid: r.guid });
|
|
159
159
|
},
|
|
160
160
|
primaryText: r.is_hidden ? s.unhide_account : s.hide_Account,
|
|
161
161
|
secondaryText: r.is_hidden ? s.include_this_account : s.exclude_this_account,
|
|
162
|
-
children: /* @__PURE__ */ e(
|
|
162
|
+
children: /* @__PURE__ */ e(N1, { "aria-hidden": !0, checked: r.is_hidden, tabIndex: -1 })
|
|
163
163
|
}
|
|
164
164
|
),
|
|
165
165
|
/* @__PURE__ */ C(
|
|
166
|
-
|
|
166
|
+
q,
|
|
167
167
|
{
|
|
168
168
|
onClick: () => {
|
|
169
|
-
o(!0),
|
|
169
|
+
o(!0), M(x.ACCOUNT_DETAILS_CLICK_MARK_CLOSED, {
|
|
170
170
|
account_guid: r.guid
|
|
171
171
|
});
|
|
172
172
|
},
|
|
@@ -174,8 +174,8 @@ const d3 = (t, o) => {
|
|
|
174
174
|
secondaryText: r.is_closed ? s.this_will_set_the_closed_account : s.this_will_set_the_account_balance_to_0,
|
|
175
175
|
children: [
|
|
176
176
|
/* @__PURE__ */ e(N, { name: "chevron_right" }),
|
|
177
|
-
/* @__PURE__ */ e("div", { onClick: (
|
|
178
|
-
|
|
177
|
+
/* @__PURE__ */ e("div", { onClick: (u) => u.stopPropagation(), children: /* @__PURE__ */ e(
|
|
178
|
+
e1,
|
|
179
179
|
{
|
|
180
180
|
copy: {
|
|
181
181
|
close_aria: s.close_modal,
|
|
@@ -186,7 +186,7 @@ const d3 = (t, o) => {
|
|
|
186
186
|
o(!1);
|
|
187
187
|
},
|
|
188
188
|
onPrimaryAction: () => y({ is_closed: !r.is_closed }),
|
|
189
|
-
children: /* @__PURE__ */ e(
|
|
189
|
+
children: /* @__PURE__ */ e(v, { truncate: !1, children: H(
|
|
190
190
|
r.is_closed ? s.this_will_resume_updating_the_balance : s.this_will_set_the_balance_of_your_account,
|
|
191
191
|
r.name
|
|
192
192
|
) })
|
|
@@ -195,12 +195,12 @@ const d3 = (t, o) => {
|
|
|
195
195
|
]
|
|
196
196
|
}
|
|
197
197
|
),
|
|
198
|
-
|
|
199
|
-
|
|
198
|
+
_.length > 0 && /* @__PURE__ */ e(
|
|
199
|
+
q,
|
|
200
200
|
{
|
|
201
201
|
isLast: !0,
|
|
202
202
|
onClick: () => {
|
|
203
|
-
|
|
203
|
+
c(!0), M(x.ACCOUNT_DETAILS_CLICK_MARK_DUPLICATE, {
|
|
204
204
|
account_guid: r.guid
|
|
205
205
|
});
|
|
206
206
|
},
|
|
@@ -210,19 +210,19 @@ const d3 = (t, o) => {
|
|
|
210
210
|
}
|
|
211
211
|
),
|
|
212
212
|
/* @__PURE__ */ C(
|
|
213
|
-
|
|
213
|
+
n1,
|
|
214
214
|
{
|
|
215
215
|
ariaLabelClose: s.close_drawer,
|
|
216
216
|
isOpen: n,
|
|
217
|
-
onClose: () =>
|
|
217
|
+
onClose: () => c(!1),
|
|
218
218
|
title: s.mark_as_duplicate,
|
|
219
219
|
children: [
|
|
220
|
-
/* @__PURE__ */ e(O, { children:
|
|
221
|
-
const
|
|
220
|
+
/* @__PURE__ */ e(O, { children: _.map((u) => {
|
|
221
|
+
const g = _.indexOf(u) === _.length - 1;
|
|
222
222
|
return /* @__PURE__ */ e(
|
|
223
223
|
U,
|
|
224
224
|
{
|
|
225
|
-
account:
|
|
225
|
+
account: u,
|
|
226
226
|
listItemProps: {
|
|
227
227
|
sx: {
|
|
228
228
|
position: "relative",
|
|
@@ -231,36 +231,36 @@ const d3 = (t, o) => {
|
|
|
231
231
|
position: "absolute",
|
|
232
232
|
bottom: 0,
|
|
233
233
|
right: 0,
|
|
234
|
-
left:
|
|
234
|
+
left: g ? 0 : 24,
|
|
235
235
|
borderBottom: "1px solid",
|
|
236
236
|
borderColor: "divider"
|
|
237
237
|
}
|
|
238
238
|
}
|
|
239
239
|
},
|
|
240
240
|
onRowClick: () => {
|
|
241
|
-
l(!0), a(
|
|
241
|
+
l(!0), a(u);
|
|
242
242
|
}
|
|
243
243
|
},
|
|
244
|
-
|
|
244
|
+
u.guid
|
|
245
245
|
);
|
|
246
246
|
}) }),
|
|
247
|
-
|
|
248
|
-
|
|
247
|
+
i && /* @__PURE__ */ C(
|
|
248
|
+
e1,
|
|
249
249
|
{
|
|
250
250
|
copy: {
|
|
251
251
|
close_aria: s.close_modal,
|
|
252
252
|
title: s.confirm_merge
|
|
253
253
|
},
|
|
254
|
-
isOpen:
|
|
254
|
+
isOpen: i,
|
|
255
255
|
onClose: () => l(!1),
|
|
256
|
-
onPrimaryAction:
|
|
256
|
+
onPrimaryAction: p,
|
|
257
257
|
children: [
|
|
258
|
-
/* @__PURE__ */ e(
|
|
258
|
+
/* @__PURE__ */ e(v, { truncate: !1, children: H(
|
|
259
259
|
s.this_means_accounts_will_be_merged,
|
|
260
260
|
r.name,
|
|
261
|
-
|
|
261
|
+
d.name
|
|
262
262
|
) }),
|
|
263
|
-
/* @__PURE__ */ e(
|
|
263
|
+
/* @__PURE__ */ e(v, { color: "error", sx: { mt: 24 }, children: s.this_action_cannot_be_undone })
|
|
264
264
|
]
|
|
265
265
|
}
|
|
266
266
|
)
|
|
@@ -268,100 +268,100 @@ const d3 = (t, o) => {
|
|
|
268
268
|
}
|
|
269
269
|
)
|
|
270
270
|
] });
|
|
271
|
-
},
|
|
271
|
+
}, L3 = A(_3), V1 = (t, o) => {
|
|
272
272
|
const { connection_messages: n } = o;
|
|
273
273
|
switch (t.connection_status) {
|
|
274
|
-
case
|
|
274
|
+
case f.CHALLENGED:
|
|
275
275
|
return {
|
|
276
276
|
cta: n.challenged_cta,
|
|
277
|
-
main:
|
|
277
|
+
main: H(
|
|
278
278
|
n.challenged_connection_description,
|
|
279
279
|
t.name
|
|
280
280
|
),
|
|
281
281
|
statusName: o.connection_statuses[t.connection_status],
|
|
282
282
|
title: n.challenged_connection_title
|
|
283
283
|
};
|
|
284
|
-
case
|
|
284
|
+
case f.CLOSED:
|
|
285
285
|
return {
|
|
286
286
|
main: n.closed_connection_description,
|
|
287
287
|
statusName: o.connection_statuses[t.connection_status],
|
|
288
288
|
title: n.closed_connection_title
|
|
289
289
|
};
|
|
290
|
-
case
|
|
290
|
+
case f.DEGRADED:
|
|
291
291
|
return {
|
|
292
292
|
main: n.degraded_connection_description,
|
|
293
293
|
statusName: o.connection_statuses[t.connection_status],
|
|
294
294
|
title: n.degraded_connection_title
|
|
295
295
|
};
|
|
296
|
-
case
|
|
296
|
+
case f.DELAYED:
|
|
297
297
|
return {
|
|
298
|
-
main:
|
|
298
|
+
main: H(
|
|
299
299
|
n.delayed_connection_description,
|
|
300
300
|
t.name
|
|
301
301
|
),
|
|
302
302
|
statusName: o.connection_statuses[t.connection_status],
|
|
303
303
|
title: n.delayed_connection_title
|
|
304
304
|
};
|
|
305
|
-
case
|
|
305
|
+
case f.DENIED:
|
|
306
306
|
return {
|
|
307
307
|
cta: n.denied_cta,
|
|
308
|
-
main:
|
|
308
|
+
main: H(
|
|
309
309
|
n.denied_connection_description,
|
|
310
310
|
t.name
|
|
311
311
|
),
|
|
312
312
|
statusName: o.connection_statuses[t.connection_status],
|
|
313
313
|
title: n.denied_connection_title
|
|
314
314
|
};
|
|
315
|
-
case
|
|
315
|
+
case f.DISABLED:
|
|
316
316
|
return {
|
|
317
317
|
main: n.disabled_connection_description,
|
|
318
318
|
statusName: o.connection_statuses[t.connection_status],
|
|
319
319
|
title: n.disabled_connection_title
|
|
320
320
|
};
|
|
321
|
-
case
|
|
321
|
+
case f.DISCONNECTED:
|
|
322
322
|
return {
|
|
323
|
-
main:
|
|
323
|
+
main: H(
|
|
324
324
|
n.disconnected_connection_description,
|
|
325
325
|
t.name
|
|
326
326
|
),
|
|
327
327
|
statusName: o.connection_statuses[t.connection_status],
|
|
328
328
|
title: n.disconnected_connection_title
|
|
329
329
|
};
|
|
330
|
-
case
|
|
330
|
+
case f.DISCONTINUED:
|
|
331
331
|
return {
|
|
332
332
|
main: n.discontinued_connection_description,
|
|
333
333
|
statusName: o.connection_statuses[t.connection_status],
|
|
334
334
|
title: n.discontinued_connection_title
|
|
335
335
|
};
|
|
336
|
-
case
|
|
336
|
+
case f.EXPIRED:
|
|
337
337
|
return {
|
|
338
338
|
cta: n.expired_cta,
|
|
339
339
|
main: n.expired_connection_description,
|
|
340
340
|
statusName: o.connection_statuses[t.connection_status],
|
|
341
341
|
title: n.expired_connection_title
|
|
342
342
|
};
|
|
343
|
-
case
|
|
343
|
+
case f.FAILED:
|
|
344
344
|
return {
|
|
345
|
-
main:
|
|
345
|
+
main: H(
|
|
346
346
|
n.failed_connection_description,
|
|
347
347
|
t.name
|
|
348
348
|
),
|
|
349
349
|
statusName: o.connection_statuses[t.connection_status],
|
|
350
350
|
title: n.failed_connection_title
|
|
351
351
|
};
|
|
352
|
-
case
|
|
352
|
+
case f.IMPAIRED:
|
|
353
353
|
return {
|
|
354
354
|
cta: n.impaired_cta,
|
|
355
|
-
main:
|
|
355
|
+
main: H(
|
|
356
356
|
n.impaired_connection_description,
|
|
357
357
|
t.name
|
|
358
358
|
),
|
|
359
359
|
statusName: o.connection_statuses[t.connection_status],
|
|
360
360
|
title: n.impaired_connection_title
|
|
361
361
|
};
|
|
362
|
-
case
|
|
362
|
+
case f.IMPEDED:
|
|
363
363
|
return {
|
|
364
|
-
main:
|
|
364
|
+
main: H(
|
|
365
365
|
n.impeded_connection_description,
|
|
366
366
|
t.name,
|
|
367
367
|
t.name
|
|
@@ -369,34 +369,34 @@ const d3 = (t, o) => {
|
|
|
369
369
|
statusName: o.connection_statuses[t.connection_status],
|
|
370
370
|
title: n.impeded_connection_title
|
|
371
371
|
};
|
|
372
|
-
case
|
|
372
|
+
case f.IMPORTED:
|
|
373
373
|
return {
|
|
374
374
|
cta: n.imported_cta,
|
|
375
|
-
main:
|
|
375
|
+
main: H(
|
|
376
376
|
n.imported_connection_description,
|
|
377
377
|
t.name
|
|
378
378
|
),
|
|
379
379
|
statusName: o.connection_statuses[t.connection_status],
|
|
380
380
|
title: n.imported_connection_title
|
|
381
381
|
};
|
|
382
|
-
case
|
|
382
|
+
case f.LOCKED:
|
|
383
383
|
return {
|
|
384
384
|
cta: n.locked_cta,
|
|
385
|
-
main:
|
|
385
|
+
main: H(
|
|
386
386
|
n.locked_connection_description,
|
|
387
387
|
t.name
|
|
388
388
|
),
|
|
389
389
|
statusName: o.connection_statuses[t.connection_status],
|
|
390
390
|
title: n.locked_connection_title
|
|
391
391
|
};
|
|
392
|
-
case
|
|
392
|
+
case f.PREVENTED:
|
|
393
393
|
return {
|
|
394
394
|
cta: n.prevented_cta,
|
|
395
395
|
main: n.prevented_connection_description,
|
|
396
396
|
statusName: o.connection_statuses[t.connection_status],
|
|
397
397
|
title: n.prevented_connection_title
|
|
398
398
|
};
|
|
399
|
-
case
|
|
399
|
+
case f.REJECTED:
|
|
400
400
|
return {
|
|
401
401
|
cta: n.rejected_cta,
|
|
402
402
|
main: n.rejected_connection_description,
|
|
@@ -404,47 +404,47 @@ const d3 = (t, o) => {
|
|
|
404
404
|
title: n.rejected_connection_title
|
|
405
405
|
};
|
|
406
406
|
default: {
|
|
407
|
-
const
|
|
408
|
-
const
|
|
407
|
+
const c = () => {
|
|
408
|
+
const i = t.successfully_aggregated_at ? W1(t.successfully_aggregated_at) : void 0, l = i && l1(i, r1.TIME_STAMP_HOUR_MINUTE);
|
|
409
409
|
if (l)
|
|
410
|
-
return
|
|
410
|
+
return B1(i) ? H(o.last_updated_at, o.today, l) : U1(i) ? H(o.last_updated_at, o.yesterday, l) : H(
|
|
411
411
|
o.last_updated_at,
|
|
412
|
-
|
|
412
|
+
l1(i, r1.MONTH_DAY_YEAR),
|
|
413
413
|
l
|
|
414
414
|
);
|
|
415
415
|
};
|
|
416
416
|
return {
|
|
417
417
|
statusName: o.connection_statuses[6],
|
|
418
418
|
// Connected
|
|
419
|
-
title:
|
|
419
|
+
title: c()
|
|
420
420
|
};
|
|
421
421
|
}
|
|
422
422
|
}
|
|
423
|
-
},
|
|
423
|
+
}, Q = {
|
|
424
424
|
color: "background.default",
|
|
425
425
|
fontSize: 20,
|
|
426
426
|
gridRow: 1,
|
|
427
427
|
gridColumn: 1,
|
|
428
428
|
zIndex: 2
|
|
429
|
-
},
|
|
429
|
+
}, f3 = () => {
|
|
430
430
|
const [t, o] = h.useState(!1), {
|
|
431
431
|
palette: { mode: n }
|
|
432
|
-
} =
|
|
432
|
+
} = O1(), { selectedMember: c } = R(), { accounts: i, connect: l } = V(), d = V1(c, l), a = L1.includes(c.connection_status) ? {
|
|
433
433
|
color: "error.main",
|
|
434
|
-
ctaCopy:
|
|
435
|
-
icon: /* @__PURE__ */ e(
|
|
436
|
-
mainMessage:
|
|
437
|
-
secondaryMessage: `${
|
|
434
|
+
ctaCopy: d.cta ?? "",
|
|
435
|
+
icon: /* @__PURE__ */ e(v1, { filled: !0, sx: { ...Q } }),
|
|
436
|
+
mainMessage: d.statusName,
|
|
437
|
+
secondaryMessage: `${d.title}.`
|
|
438
438
|
} : {
|
|
439
439
|
color: "success.main",
|
|
440
|
-
icon: /* @__PURE__ */ e(
|
|
441
|
-
mainMessage:
|
|
442
|
-
secondaryMessage:
|
|
440
|
+
icon: /* @__PURE__ */ e(P1, { filled: !0, sx: { ...Q } }),
|
|
441
|
+
mainMessage: d.statusName,
|
|
442
|
+
secondaryMessage: d.title
|
|
443
443
|
};
|
|
444
|
-
return /* @__PURE__ */ C(
|
|
445
|
-
/* @__PURE__ */ e(B, { sx: { mb: 4, mt: 12, mx: 8 }, children: /* @__PURE__ */ e(
|
|
444
|
+
return /* @__PURE__ */ C(S, { children: [
|
|
445
|
+
/* @__PURE__ */ e(B, { sx: { mb: 4, mt: 12, mx: 8 }, children: /* @__PURE__ */ e(v, { bold: !0, component: "h2", variant: "caption", children: i.connection_status }) }),
|
|
446
446
|
/* @__PURE__ */ e(
|
|
447
|
-
|
|
447
|
+
E,
|
|
448
448
|
{
|
|
449
449
|
sx: {
|
|
450
450
|
backgroundColor: "background.paper",
|
|
@@ -454,24 +454,24 @@ const d3 = (t, o) => {
|
|
|
454
454
|
position: "absolute",
|
|
455
455
|
bottom: 0,
|
|
456
456
|
right: 0,
|
|
457
|
-
left:
|
|
457
|
+
left: c.is_manual || !c.institution_url ? 0 : 24,
|
|
458
458
|
borderBottom: "1px solid",
|
|
459
459
|
borderColor: "divider"
|
|
460
460
|
}
|
|
461
461
|
},
|
|
462
|
-
children:
|
|
463
|
-
/* @__PURE__ */ e(
|
|
462
|
+
children: c.is_manual || !a.ctaCopy ? /* @__PURE__ */ C(t1, { alignItems: "center", direction: "row", px: 24, py: 12, children: [
|
|
463
|
+
/* @__PURE__ */ e(j, { children: /* @__PURE__ */ e(X, { backingSx: { backgroundColor: a.color, borderRadius: 1 }, size: 32, children: a.icon }) }),
|
|
464
464
|
/* @__PURE__ */ e(Z, { primary: a.mainMessage, secondary: a.secondaryMessage })
|
|
465
465
|
] }) : /* @__PURE__ */ C($, { onClick: () => o(!0), children: [
|
|
466
|
-
/* @__PURE__ */ e(
|
|
466
|
+
/* @__PURE__ */ e(j, { children: /* @__PURE__ */ e(X, { backingSx: { backgroundColor: a.color, borderRadius: 1 }, size: 32, children: a.icon }) }),
|
|
467
467
|
/* @__PURE__ */ e(
|
|
468
468
|
Z,
|
|
469
469
|
{
|
|
470
470
|
primary: a.mainMessage,
|
|
471
|
-
secondary: a.secondaryMessage && /* @__PURE__ */ C(
|
|
471
|
+
secondary: a.secondaryMessage && /* @__PURE__ */ C(S, { children: [
|
|
472
472
|
a.secondaryMessage,
|
|
473
473
|
" ",
|
|
474
|
-
/* @__PURE__ */ e(
|
|
474
|
+
/* @__PURE__ */ e(v, { bold: !0, sx: { color: "action.active" }, variant: "caption", children: a.ctaCopy })
|
|
475
475
|
] })
|
|
476
476
|
}
|
|
477
477
|
),
|
|
@@ -479,35 +479,35 @@ const d3 = (t, o) => {
|
|
|
479
479
|
] })
|
|
480
480
|
}
|
|
481
481
|
),
|
|
482
|
-
!
|
|
483
|
-
|
|
482
|
+
!c.is_manual && c.institution_url && /* @__PURE__ */ e(S, { children: /* @__PURE__ */ e(
|
|
483
|
+
E,
|
|
484
484
|
{
|
|
485
485
|
sx: {
|
|
486
486
|
backgroundColor: "background.paper",
|
|
487
487
|
borderBottom: "1px solid",
|
|
488
488
|
borderColor: "divider"
|
|
489
489
|
},
|
|
490
|
-
children: /* @__PURE__ */ C($, { component: "a", href:
|
|
491
|
-
/* @__PURE__ */ e(
|
|
492
|
-
|
|
490
|
+
children: /* @__PURE__ */ C($, { component: "a", href: c.institution_url, target: "_blank", children: [
|
|
491
|
+
/* @__PURE__ */ e(j, { children: /* @__PURE__ */ e(
|
|
492
|
+
X,
|
|
493
493
|
{
|
|
494
494
|
backingSx: {
|
|
495
|
-
backgroundColor: n ===
|
|
495
|
+
backgroundColor: n === c1.LIGHT ? "grey.300" : "grey.700",
|
|
496
496
|
borderRadius: 1
|
|
497
497
|
},
|
|
498
498
|
size: 32,
|
|
499
499
|
children: /* @__PURE__ */ e(
|
|
500
|
-
|
|
500
|
+
F1,
|
|
501
501
|
{
|
|
502
502
|
sx: {
|
|
503
|
-
...
|
|
504
|
-
color: n ===
|
|
503
|
+
...Q,
|
|
504
|
+
color: n === c1.LIGHT ? "grey.900" : "common.white"
|
|
505
505
|
}
|
|
506
506
|
}
|
|
507
507
|
)
|
|
508
508
|
}
|
|
509
509
|
) }),
|
|
510
|
-
/* @__PURE__ */ e(Z, { primary:
|
|
510
|
+
/* @__PURE__ */ e(Z, { primary: c.name, secondary: c.institution_url }),
|
|
511
511
|
/* @__PURE__ */ e(N, { name: "launch" })
|
|
512
512
|
] })
|
|
513
513
|
}
|
|
@@ -515,23 +515,23 @@ const d3 = (t, o) => {
|
|
|
515
515
|
t && /* @__PURE__ */ e(
|
|
516
516
|
z,
|
|
517
517
|
{
|
|
518
|
-
loadWidgetProps: { current_member_guid:
|
|
518
|
+
loadWidgetProps: { current_member_guid: c.guid },
|
|
519
519
|
onClose: () => o(!1),
|
|
520
520
|
showConnectWidget: t,
|
|
521
|
-
title:
|
|
521
|
+
title: i.manage_connection
|
|
522
522
|
}
|
|
523
523
|
)
|
|
524
524
|
] });
|
|
525
|
-
},
|
|
526
|
-
const { updateAccount:
|
|
527
|
-
a(""),
|
|
528
|
-
},
|
|
525
|
+
}, g3 = A(f3), H3 = ({ field: t, isOpen: o, onClose: n }) => {
|
|
526
|
+
const { updateAccount: c } = D(), { selectedAccount: i } = R(), { accounts: l } = V(), [d, a] = h.useState(i[t.name]), [r, L] = h.useState(""), [m, s] = h.useState(!0), _ = () => {
|
|
527
|
+
a(""), L(""), n();
|
|
528
|
+
}, M = () => {
|
|
529
529
|
switch (t.type) {
|
|
530
|
-
case
|
|
531
|
-
return /* @__PURE__ */ C(
|
|
532
|
-
/* @__PURE__ */ e(
|
|
530
|
+
case J.Select:
|
|
531
|
+
return /* @__PURE__ */ C(K1, { fullWidth: !0, children: [
|
|
532
|
+
/* @__PURE__ */ e(Y1, { id: `${t.label}-select-label`, children: t.label }),
|
|
533
533
|
/* @__PURE__ */ e(
|
|
534
|
-
|
|
534
|
+
J1,
|
|
535
535
|
{
|
|
536
536
|
id: `${t.label}-select`,
|
|
537
537
|
inputProps: {
|
|
@@ -541,18 +541,18 @@ const d3 = (t, o) => {
|
|
|
541
541
|
},
|
|
542
542
|
label: t.label,
|
|
543
543
|
labelId: `${t.label}-select-label`,
|
|
544
|
-
onChange: (
|
|
544
|
+
onChange: (p) => a(p.target.value),
|
|
545
545
|
placeholder: t.placeholder,
|
|
546
|
-
value:
|
|
547
|
-
children: t.options?.map((
|
|
546
|
+
value: d,
|
|
547
|
+
children: t.options?.map((p) => /* @__PURE__ */ e(X1, { value: p.value, children: p.label }, p.value))
|
|
548
548
|
}
|
|
549
549
|
)
|
|
550
550
|
] });
|
|
551
|
-
case
|
|
551
|
+
case J.Currency:
|
|
552
552
|
return /* @__PURE__ */ e(
|
|
553
|
-
|
|
553
|
+
Q1,
|
|
554
554
|
{
|
|
555
|
-
amount:
|
|
555
|
+
amount: d || "",
|
|
556
556
|
ariaLabel: t.placeholder,
|
|
557
557
|
fullWidth: !0,
|
|
558
558
|
label: t.label,
|
|
@@ -561,14 +561,14 @@ const d3 = (t, o) => {
|
|
|
561
561
|
setHasValidInput: s
|
|
562
562
|
}
|
|
563
563
|
);
|
|
564
|
-
case
|
|
565
|
-
return /* @__PURE__ */ e(
|
|
566
|
-
|
|
564
|
+
case J.Date:
|
|
565
|
+
return /* @__PURE__ */ e(j1, { dateAdapter: G1, children: /* @__PURE__ */ e(
|
|
566
|
+
z1,
|
|
567
567
|
{
|
|
568
|
-
maxDate:
|
|
568
|
+
maxDate: $1(/* @__PURE__ */ new Date(), 1),
|
|
569
569
|
minDate: /* @__PURE__ */ new Date(),
|
|
570
|
-
onChange: (
|
|
571
|
-
|
|
570
|
+
onChange: (p) => {
|
|
571
|
+
i[t.name] && Number(i[t.name]) <= 31 ? a(p.getDate()) : a(p);
|
|
572
572
|
},
|
|
573
573
|
sx: {
|
|
574
574
|
"& .MuiPickersDay-today": {
|
|
@@ -577,7 +577,7 @@ const d3 = (t, o) => {
|
|
|
577
577
|
"& .MuiPickersArrowSwitcher-button": {
|
|
578
578
|
color: "primary.lighter",
|
|
579
579
|
"&:hover": {
|
|
580
|
-
backgroundColor: (
|
|
580
|
+
backgroundColor: (p) => w1(p.palette.primary.light, 0.1)
|
|
581
581
|
}
|
|
582
582
|
}
|
|
583
583
|
},
|
|
@@ -586,9 +586,9 @@ const d3 = (t, o) => {
|
|
|
586
586
|
) });
|
|
587
587
|
default:
|
|
588
588
|
return /* @__PURE__ */ e(
|
|
589
|
-
|
|
589
|
+
q1,
|
|
590
590
|
{
|
|
591
|
-
defaultValue:
|
|
591
|
+
defaultValue: i[t.name],
|
|
592
592
|
error: !!r,
|
|
593
593
|
fullWidth: !0,
|
|
594
594
|
helperText: r,
|
|
@@ -600,25 +600,25 @@ const d3 = (t, o) => {
|
|
|
600
600
|
}
|
|
601
601
|
);
|
|
602
602
|
}
|
|
603
|
-
},
|
|
604
|
-
|
|
605
|
-
...
|
|
606
|
-
[t.name]:
|
|
607
|
-
}),
|
|
608
|
-
}, y = (
|
|
609
|
-
a(
|
|
603
|
+
}, w = () => {
|
|
604
|
+
i[t.name] !== d && c({
|
|
605
|
+
...i,
|
|
606
|
+
[t.name]: d
|
|
607
|
+
}), _();
|
|
608
|
+
}, y = (p) => {
|
|
609
|
+
a(p.target.value), t.validation && L(t.validation(p.target.value));
|
|
610
610
|
};
|
|
611
611
|
return /* @__PURE__ */ e(
|
|
612
|
-
|
|
612
|
+
e1,
|
|
613
613
|
{
|
|
614
614
|
copy: {
|
|
615
615
|
close_aria: l.close_aria,
|
|
616
|
-
title:
|
|
616
|
+
title: H(l.edit_field, t.label)
|
|
617
617
|
},
|
|
618
|
-
disablePrimaryButton: !!r || !
|
|
618
|
+
disablePrimaryButton: !!r || !m,
|
|
619
619
|
isOpen: o,
|
|
620
|
-
onClose:
|
|
621
|
-
onPrimaryAction:
|
|
620
|
+
onClose: _,
|
|
621
|
+
onPrimaryAction: w,
|
|
622
622
|
primaryText: l.save,
|
|
623
623
|
sx: {
|
|
624
624
|
"& .MuiButton-root:focus-visible, & .MuiButton-root:focus": {
|
|
@@ -627,25 +627,25 @@ const d3 = (t, o) => {
|
|
|
627
627
|
outlineOffset: "2px"
|
|
628
628
|
}
|
|
629
629
|
},
|
|
630
|
-
children:
|
|
630
|
+
children: M()
|
|
631
631
|
}
|
|
632
632
|
);
|
|
633
|
-
},
|
|
634
|
-
const t = window.app?.config, { onEvent: o } =
|
|
633
|
+
}, v3 = A(H3), b3 = () => {
|
|
634
|
+
const t = window.app?.config, { onEvent: o } = k(), { selectedAccount: n } = R(), { accounts: c } = V(), 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(
|
|
635
635
|
(s) => l || n[s.name] || n[s.name] === 0
|
|
636
636
|
);
|
|
637
|
-
return /* @__PURE__ */ C(
|
|
638
|
-
|
|
639
|
-
const
|
|
637
|
+
return /* @__PURE__ */ C(S, { children: [
|
|
638
|
+
m.map((s) => {
|
|
639
|
+
const _ = n[s.name] || n[s.name] === 0, M = m.indexOf(s) === m.length - 1, w = /* @__PURE__ */ e(
|
|
640
640
|
Z,
|
|
641
641
|
{
|
|
642
642
|
disableTypography: !0,
|
|
643
|
-
primary: /* @__PURE__ */ e(
|
|
644
|
-
secondary: /* @__PURE__ */ e(
|
|
643
|
+
primary: /* @__PURE__ */ e(v, { sx: { fontSize: 11 }, children: s.label }),
|
|
644
|
+
secondary: /* @__PURE__ */ e(v, { bold: !0, sx: { fontSize: 15 }, children: _ ? s.valueFormatter(n[s.name]) : s.placeholder })
|
|
645
645
|
}
|
|
646
646
|
);
|
|
647
647
|
return /* @__PURE__ */ e(h.Fragment, { children: l ? /* @__PURE__ */ e(
|
|
648
|
-
|
|
648
|
+
E,
|
|
649
649
|
{
|
|
650
650
|
sx: {
|
|
651
651
|
backgroundColor: "background.paper",
|
|
@@ -656,7 +656,7 @@ const d3 = (t, o) => {
|
|
|
656
656
|
position: "absolute",
|
|
657
657
|
bottom: 0,
|
|
658
658
|
right: 0,
|
|
659
|
-
left:
|
|
659
|
+
left: M ? 0 : 24,
|
|
660
660
|
borderBottom: "1px solid",
|
|
661
661
|
borderColor: "divider"
|
|
662
662
|
}
|
|
@@ -665,17 +665,17 @@ const d3 = (t, o) => {
|
|
|
665
665
|
$,
|
|
666
666
|
{
|
|
667
667
|
onClick: () => {
|
|
668
|
-
|
|
668
|
+
L(s), a(!0), s?.event && o(s.event, { account_guid: n.guid });
|
|
669
669
|
},
|
|
670
670
|
children: [
|
|
671
|
-
|
|
671
|
+
w,
|
|
672
672
|
/* @__PURE__ */ e(N, { name: "chevron_right" })
|
|
673
673
|
]
|
|
674
674
|
}
|
|
675
675
|
)
|
|
676
676
|
}
|
|
677
|
-
) :
|
|
678
|
-
|
|
677
|
+
) : _ && /* @__PURE__ */ e(
|
|
678
|
+
E,
|
|
679
679
|
{
|
|
680
680
|
sx: {
|
|
681
681
|
backgroundColor: "background.paper",
|
|
@@ -686,40 +686,40 @@ const d3 = (t, o) => {
|
|
|
686
686
|
position: "absolute",
|
|
687
687
|
bottom: 0,
|
|
688
688
|
right: 0,
|
|
689
|
-
left:
|
|
689
|
+
left: M ? 0 : 24,
|
|
690
690
|
borderBottom: "1px solid",
|
|
691
691
|
borderColor: "divider"
|
|
692
692
|
}
|
|
693
693
|
},
|
|
694
|
-
children:
|
|
694
|
+
children: w
|
|
695
695
|
}
|
|
696
696
|
) }, s.name);
|
|
697
697
|
}),
|
|
698
|
-
|
|
699
|
-
|
|
698
|
+
d && r && /* @__PURE__ */ e(
|
|
699
|
+
v3,
|
|
700
700
|
{
|
|
701
701
|
field: r,
|
|
702
|
-
isOpen:
|
|
702
|
+
isOpen: d,
|
|
703
703
|
onClose: () => a(!1)
|
|
704
704
|
}
|
|
705
705
|
)
|
|
706
706
|
] });
|
|
707
|
-
},
|
|
708
|
-
const { onEvent: t } =
|
|
709
|
-
return h.useEffect(() => t(
|
|
710
|
-
/* @__PURE__ */ e(
|
|
711
|
-
/* @__PURE__ */ e(
|
|
712
|
-
/* @__PURE__ */ e(
|
|
707
|
+
}, A3 = A(b3), V3 = () => {
|
|
708
|
+
const { onEvent: t } = k();
|
|
709
|
+
return h.useEffect(() => t(x.ACCOUNT_DETAILS_VIEW), []), /* @__PURE__ */ C(O, { children: [
|
|
710
|
+
/* @__PURE__ */ e(A3, {}),
|
|
711
|
+
/* @__PURE__ */ e(g3, {}),
|
|
712
|
+
/* @__PURE__ */ e(L3, {})
|
|
713
713
|
] });
|
|
714
|
-
},
|
|
715
|
-
const [o, n] = h.useState(!1), { selectedMember:
|
|
714
|
+
}, M3 = A(V3), y3 = ({ setTabValue: t }) => {
|
|
715
|
+
const [o, n] = h.useState(!1), { selectedMember: c } = R(), { accounts: i, connect: l } = V(), d = c.connection_status && L1.includes(c.connection_status);
|
|
716
716
|
if (h.useEffect(() => {
|
|
717
|
-
|
|
718
|
-
}, [
|
|
719
|
-
const a =
|
|
720
|
-
return /* @__PURE__ */ C(
|
|
717
|
+
d && t(1);
|
|
718
|
+
}, [d]), !d) return;
|
|
719
|
+
const a = V1(c, l);
|
|
720
|
+
return /* @__PURE__ */ C(S, { children: [
|
|
721
721
|
/* @__PURE__ */ e(
|
|
722
|
-
|
|
722
|
+
o3,
|
|
723
723
|
{
|
|
724
724
|
sx: {
|
|
725
725
|
mb: 16,
|
|
@@ -727,9 +727,9 @@ const d3 = (t, o) => {
|
|
|
727
727
|
mx: 24
|
|
728
728
|
},
|
|
729
729
|
children: /* @__PURE__ */ C(
|
|
730
|
-
|
|
730
|
+
e3,
|
|
731
731
|
{
|
|
732
|
-
icon: /* @__PURE__ */ e(
|
|
732
|
+
icon: /* @__PURE__ */ e(v1, { filled: !0 }),
|
|
733
733
|
role: "none",
|
|
734
734
|
severity: "error",
|
|
735
735
|
sx: {
|
|
@@ -743,10 +743,10 @@ const d3 = (t, o) => {
|
|
|
743
743
|
}
|
|
744
744
|
},
|
|
745
745
|
children: [
|
|
746
|
-
a.title && /* @__PURE__ */ e(
|
|
747
|
-
/* @__PURE__ */ e(
|
|
746
|
+
a.title && /* @__PURE__ */ e(t3, { sx: { fontWeight: 600, marginTop: 2 }, variant: "body1", children: a.title }),
|
|
747
|
+
/* @__PURE__ */ e(v, { component: "p", sx: { whiteSpace: "wrap" }, variant: "subtitle2", children: a.main }),
|
|
748
748
|
a.cta && /* @__PURE__ */ e(
|
|
749
|
-
|
|
749
|
+
n3,
|
|
750
750
|
{
|
|
751
751
|
onClick: () => n(!0),
|
|
752
752
|
sx: { fontSize: 15, fontWeight: 600, ml: 0 },
|
|
@@ -761,56 +761,56 @@ const d3 = (t, o) => {
|
|
|
761
761
|
o && /* @__PURE__ */ e(
|
|
762
762
|
z,
|
|
763
763
|
{
|
|
764
|
-
loadWidgetProps: { current_member_guid:
|
|
764
|
+
loadWidgetProps: { current_member_guid: c.guid },
|
|
765
765
|
onClose: () => n(!1),
|
|
766
766
|
showConnectWidget: o,
|
|
767
|
-
title:
|
|
767
|
+
title: i.manage_connection
|
|
768
768
|
}
|
|
769
769
|
)
|
|
770
770
|
] });
|
|
771
|
-
},
|
|
772
|
-
const [t, o] = h.useState(""), { onEvent: n } =
|
|
771
|
+
}, w3 = A(y3), x3 = () => {
|
|
772
|
+
const [t, o] = h.useState(""), { onEvent: n } = k(), { selectedAccount: c } = R(), { accounts: i } = V(), { isTransactionDataLoaded: l, loadTransactionData: d, setFilter: a, sortedTransactions: r } = p1();
|
|
773
773
|
h.useEffect(() => {
|
|
774
|
-
l ||
|
|
774
|
+
l || d().finally();
|
|
775
775
|
}, []);
|
|
776
|
-
const
|
|
777
|
-
() => r.find((
|
|
776
|
+
const L = h.useMemo(
|
|
777
|
+
() => r.find((m) => m.guid === t),
|
|
778
778
|
[t, r]
|
|
779
779
|
);
|
|
780
780
|
return h.useEffect(() => {
|
|
781
781
|
a({
|
|
782
|
-
dateRange: { start:
|
|
783
|
-
accounts: [
|
|
782
|
+
dateRange: { start: c3(a3(), 90), end: i3() },
|
|
783
|
+
accounts: [c.guid]
|
|
784
784
|
});
|
|
785
|
-
}, [
|
|
786
|
-
/* @__PURE__ */ e(
|
|
787
|
-
|
|
788
|
-
|
|
785
|
+
}, [c]), h.useEffect(() => n(x.ACCOUNT_DETAILS_VIEW_TRANSACTIONS), []), /* @__PURE__ */ C(S, { children: [
|
|
786
|
+
/* @__PURE__ */ e(s3, { onClick: o }),
|
|
787
|
+
L && /* @__PURE__ */ e(
|
|
788
|
+
n1,
|
|
789
789
|
{
|
|
790
|
-
ariaLabelClose:
|
|
790
|
+
ariaLabelClose: i.close_drawer,
|
|
791
791
|
isOpen: !!t,
|
|
792
792
|
onClose: () => o(""),
|
|
793
|
-
title:
|
|
794
|
-
children: /* @__PURE__ */ e(
|
|
793
|
+
title: i.transaction_drawer_title,
|
|
794
|
+
children: /* @__PURE__ */ e(l3, { transaction: L })
|
|
795
795
|
}
|
|
796
796
|
)
|
|
797
797
|
] });
|
|
798
|
-
},
|
|
799
|
-
const [t, o] = h.useState(0), { accounts: n } =
|
|
800
|
-
return /* @__PURE__ */ C(
|
|
801
|
-
/* @__PURE__ */ e(
|
|
798
|
+
}, R3 = A(x3), S3 = () => {
|
|
799
|
+
const [t, o] = h.useState(0), { accounts: n } = V();
|
|
800
|
+
return /* @__PURE__ */ C(S, { children: [
|
|
801
|
+
/* @__PURE__ */ e(w3, { setTabValue: o }),
|
|
802
802
|
/* @__PURE__ */ C(
|
|
803
|
-
|
|
803
|
+
Z1,
|
|
804
804
|
{
|
|
805
805
|
"aria-label": n.transactions_and_details_aria,
|
|
806
806
|
centered: !0,
|
|
807
|
-
onChange: (
|
|
807
|
+
onChange: (c, i) => o(i),
|
|
808
808
|
textColor: "primary",
|
|
809
809
|
value: t,
|
|
810
810
|
variant: "fullWidth",
|
|
811
811
|
children: [
|
|
812
812
|
/* @__PURE__ */ e(
|
|
813
|
-
|
|
813
|
+
s1,
|
|
814
814
|
{
|
|
815
815
|
"aria-controls": "transaction-details-tabpanel-0",
|
|
816
816
|
id: "transaction-details-tab-0",
|
|
@@ -818,7 +818,7 @@ const d3 = (t, o) => {
|
|
|
818
818
|
}
|
|
819
819
|
),
|
|
820
820
|
/* @__PURE__ */ e(
|
|
821
|
-
|
|
821
|
+
s1,
|
|
822
822
|
{
|
|
823
823
|
"aria-controls": "account-details-tabpanel-1",
|
|
824
824
|
id: "account-details-tab-1",
|
|
@@ -828,38 +828,42 @@ const d3 = (t, o) => {
|
|
|
828
828
|
]
|
|
829
829
|
}
|
|
830
830
|
),
|
|
831
|
-
/* @__PURE__ */ e(
|
|
832
|
-
/* @__PURE__ */ e(
|
|
831
|
+
/* @__PURE__ */ e(d1, { index: 0, name: "transaction-details", value: t, children: /* @__PURE__ */ e(R3, {}) }),
|
|
832
|
+
/* @__PURE__ */ e(d1, { index: 1, name: "account-details", value: t, children: /* @__PURE__ */ e(M3, {}) })
|
|
833
833
|
] });
|
|
834
|
-
},
|
|
835
|
-
const [t, o] = h.useState(""), {
|
|
836
|
-
() => i.filter((
|
|
834
|
+
}, T3 = A(S3), E3 = () => {
|
|
835
|
+
const [t, o] = h.useState(""), { config: n } = _1(), { accounts: c } = V(), { allSelectedAccounts: i } = G(), { setSelectedAccount: l, setSelectedMember: d } = R(), { members: a } = D(), { onEvent: r } = k(), L = [...new Set(i.map((u) => u.account_type))], m = i.find((u) => t === u.guid), s = h.useMemo(
|
|
836
|
+
() => i.filter((u) => u.is_hidden),
|
|
837
837
|
[i]
|
|
838
|
-
),
|
|
839
|
-
() => i.filter((
|
|
838
|
+
), _ = h.useMemo(
|
|
839
|
+
() => i.filter((u) => u.is_closed),
|
|
840
840
|
[i]
|
|
841
|
-
),
|
|
842
|
-
(
|
|
841
|
+
), M = s.reduce(
|
|
842
|
+
(u, g) => (g.available_balance || g.balance || 0) + u,
|
|
843
843
|
0
|
|
844
|
-
),
|
|
844
|
+
), w = I1(
|
|
845
|
+
_,
|
|
846
|
+
c,
|
|
847
|
+
n.display_available_balance_in_accounts
|
|
848
|
+
);
|
|
845
849
|
h.useEffect(() => {
|
|
846
|
-
if (
|
|
847
|
-
|
|
848
|
-
const
|
|
849
|
-
|
|
850
|
+
if (m) {
|
|
851
|
+
l(m);
|
|
852
|
+
const u = a.find((g) => g.guid === m?.member_guid) || {};
|
|
853
|
+
u && d(u);
|
|
850
854
|
}
|
|
851
|
-
}, [
|
|
852
|
-
const
|
|
853
|
-
o(
|
|
854
|
-
account_guid:
|
|
855
|
-
account_type:
|
|
855
|
+
}, [m, t]);
|
|
856
|
+
const y = (u) => {
|
|
857
|
+
o(u.guid), r(x.ACCOUNTS_CLICK_ACCOUNT, {
|
|
858
|
+
account_guid: u.guid,
|
|
859
|
+
account_type: u.account_type
|
|
856
860
|
});
|
|
857
|
-
},
|
|
858
|
-
const
|
|
859
|
-
return /* @__PURE__ */ e(
|
|
861
|
+
}, p = (u) => {
|
|
862
|
+
const g = u === "hidden" ? s : _, K = u === "hidden" ? M : w, b = u === "hidden" ? c.account_hidden : c.account_closed;
|
|
863
|
+
return /* @__PURE__ */ e(a1, { children: /* @__PURE__ */ e(
|
|
860
864
|
O,
|
|
861
865
|
{
|
|
862
|
-
"aria-label":
|
|
866
|
+
"aria-label": b,
|
|
863
867
|
subheader: /* @__PURE__ */ e(B, { component: "h2", sx: { backgroundColor: "transparent", px: 24 }, children: /* @__PURE__ */ C(
|
|
864
868
|
P,
|
|
865
869
|
{
|
|
@@ -867,31 +871,31 @@ const d3 = (t, o) => {
|
|
|
867
871
|
direction: "row",
|
|
868
872
|
sx: { justifyContent: "space-between", color: "grey.700" },
|
|
869
873
|
children: [
|
|
870
|
-
/* @__PURE__ */ e(
|
|
871
|
-
/* @__PURE__ */ e(
|
|
874
|
+
/* @__PURE__ */ e(v, { bold: !0, variant: "body1", children: b }),
|
|
875
|
+
/* @__PURE__ */ e(v, { bold: !0, variant: "body1", children: u1(K, "0,0.00") })
|
|
872
876
|
]
|
|
873
877
|
}
|
|
874
878
|
) }),
|
|
875
|
-
children: /* @__PURE__ */ e(P, { children:
|
|
876
|
-
const
|
|
879
|
+
children: /* @__PURE__ */ e(P, { children: g.map((T, F, M1) => {
|
|
880
|
+
const Y = F === M1.length - 1;
|
|
877
881
|
return /* @__PURE__ */ C(h.Fragment, { children: [
|
|
878
882
|
/* @__PURE__ */ e(
|
|
879
883
|
U,
|
|
880
884
|
{
|
|
881
|
-
account:
|
|
882
|
-
onRowClick: () =>
|
|
885
|
+
account: T,
|
|
886
|
+
onRowClick: () => y(T),
|
|
883
887
|
shouldShowConnectionStatus: !0
|
|
884
888
|
}
|
|
885
889
|
),
|
|
886
|
-
|
|
890
|
+
u === "hidden" ? /* @__PURE__ */ e(
|
|
887
891
|
W,
|
|
888
892
|
{
|
|
889
893
|
sx: {
|
|
890
|
-
mb:
|
|
891
|
-
ml:
|
|
894
|
+
mb: Y ? 24 : 4,
|
|
895
|
+
ml: Y ? 24 : 68
|
|
892
896
|
}
|
|
893
897
|
}
|
|
894
|
-
) : !
|
|
898
|
+
) : !Y && /* @__PURE__ */ e(
|
|
895
899
|
W,
|
|
896
900
|
{
|
|
897
901
|
sx: {
|
|
@@ -900,23 +904,23 @@ const d3 = (t, o) => {
|
|
|
900
904
|
}
|
|
901
905
|
}
|
|
902
906
|
)
|
|
903
|
-
] },
|
|
907
|
+
] }, T.guid);
|
|
904
908
|
}) })
|
|
905
909
|
}
|
|
906
910
|
) });
|
|
907
911
|
};
|
|
908
|
-
return /* @__PURE__ */ C(
|
|
909
|
-
|
|
910
|
-
const
|
|
911
|
-
(
|
|
912
|
-
),
|
|
913
|
-
(
|
|
912
|
+
return /* @__PURE__ */ C(a1, { children: [
|
|
913
|
+
L.map((u) => {
|
|
914
|
+
const g = i.filter(
|
|
915
|
+
(b) => b.account_type === u && !b.is_closed && !b.is_hidden
|
|
916
|
+
), K = g.reduce(
|
|
917
|
+
(b, T) => (T.balance || 0) + b,
|
|
914
918
|
0
|
|
915
919
|
);
|
|
916
|
-
return
|
|
920
|
+
return g.length === 0 ? null : /* @__PURE__ */ e(
|
|
917
921
|
O,
|
|
918
922
|
{
|
|
919
|
-
"aria-label":
|
|
923
|
+
"aria-label": c.account_type_accounts[g[0]?.account_type],
|
|
920
924
|
subheader: /* @__PURE__ */ e(B, { component: "h2", sx: { backgroundColor: "transparent", px: 24 }, children: /* @__PURE__ */ C(
|
|
921
925
|
P,
|
|
922
926
|
{
|
|
@@ -924,23 +928,23 @@ const d3 = (t, o) => {
|
|
|
924
928
|
direction: "row",
|
|
925
929
|
sx: { display: "flex", justifyContent: "space-between" },
|
|
926
930
|
children: [
|
|
927
|
-
/* @__PURE__ */ e(
|
|
928
|
-
/* @__PURE__ */ e(
|
|
931
|
+
/* @__PURE__ */ e(v, { bold: !0, variant: "body1", children: c.account_types[u] }),
|
|
932
|
+
/* @__PURE__ */ e(v, { bold: !0, variant: "body1", children: u1(K, "0,0.00") })
|
|
929
933
|
]
|
|
930
934
|
}
|
|
931
935
|
) }),
|
|
932
|
-
children: /* @__PURE__ */ e(P, { children:
|
|
933
|
-
const
|
|
936
|
+
children: /* @__PURE__ */ e(P, { children: g.map((b) => {
|
|
937
|
+
const T = i.indexOf(b) === i.length - 1, F = g.indexOf(b) === g.length - 1;
|
|
934
938
|
return /* @__PURE__ */ C(h.Fragment, { children: [
|
|
935
939
|
/* @__PURE__ */ e(
|
|
936
940
|
U,
|
|
937
941
|
{
|
|
938
|
-
account:
|
|
939
|
-
onRowClick: () =>
|
|
942
|
+
account: b,
|
|
943
|
+
onRowClick: () => y(b),
|
|
940
944
|
shouldShowConnectionStatus: !0
|
|
941
945
|
}
|
|
942
946
|
),
|
|
943
|
-
(!
|
|
947
|
+
(!T || _.length > 0 || s.length > 0) && /* @__PURE__ */ e(
|
|
944
948
|
W,
|
|
945
949
|
{
|
|
946
950
|
sx: {
|
|
@@ -949,146 +953,146 @@ const d3 = (t, o) => {
|
|
|
949
953
|
}
|
|
950
954
|
}
|
|
951
955
|
)
|
|
952
|
-
] },
|
|
956
|
+
] }, b.guid);
|
|
953
957
|
}) })
|
|
954
958
|
},
|
|
955
|
-
|
|
959
|
+
u
|
|
956
960
|
);
|
|
957
961
|
}),
|
|
958
|
-
|
|
959
|
-
|
|
962
|
+
s.length > 0 && p("hidden"),
|
|
963
|
+
_.length > 0 && p("closed"),
|
|
960
964
|
/* @__PURE__ */ C(
|
|
961
|
-
|
|
965
|
+
n1,
|
|
962
966
|
{
|
|
963
|
-
ariaLabelClose:
|
|
967
|
+
ariaLabelClose: c.close_account_details_aria,
|
|
964
968
|
isOpen: !!t,
|
|
965
969
|
onClose: () => o(""),
|
|
966
|
-
title:
|
|
970
|
+
title: c.account_details,
|
|
967
971
|
children: [
|
|
968
|
-
/* @__PURE__ */ e(
|
|
969
|
-
/* @__PURE__ */ e(
|
|
972
|
+
/* @__PURE__ */ e(x1, { ChartComponent: m3 }),
|
|
973
|
+
/* @__PURE__ */ e(T3, {})
|
|
970
974
|
]
|
|
971
975
|
}
|
|
972
976
|
)
|
|
973
977
|
] });
|
|
974
|
-
},
|
|
975
|
-
const [
|
|
976
|
-
|
|
978
|
+
}, D3 = A(E3), k3 = ({ onBackClick: t, onMenuClick: o, sx: n = {} }) => {
|
|
979
|
+
const [c, i] = h.useState(!1), [l, d] = h.useState(!1), { config: a } = _1(), { isAccountDataLoaded: r, loadAccountData: L } = D(), { accounts: m, connect: s } = V(), { isInitialized: _, selectedAccountGuids: M } = G(), { isDesktop: w } = b1(), { onEvent: y } = k();
|
|
980
|
+
o1({
|
|
977
981
|
widgetName: "AccountsWidget",
|
|
978
982
|
isLoaded: r
|
|
979
983
|
}), h.useEffect(() => {
|
|
980
|
-
r ||
|
|
984
|
+
r || L().finally();
|
|
981
985
|
}, []);
|
|
982
|
-
const
|
|
983
|
-
|
|
984
|
-
},
|
|
985
|
-
|
|
986
|
+
const p = () => {
|
|
987
|
+
i(!0), y(x.ACCOUNTS_CLICK_CONNECT);
|
|
988
|
+
}, u = () => {
|
|
989
|
+
d(!0), y(x.ACCOUNTS_CLICK_CONNECT);
|
|
986
990
|
};
|
|
987
|
-
return
|
|
988
|
-
|
|
991
|
+
return _ ? /* @__PURE__ */ C(
|
|
992
|
+
d3,
|
|
989
993
|
{
|
|
990
994
|
actions: a.show_connections_widget_in_master ? [
|
|
991
|
-
{ iconName: "add", label:
|
|
995
|
+
{ iconName: "add", label: m.add, onClick: p },
|
|
992
996
|
{
|
|
993
997
|
iconName: "credit_card_gear",
|
|
994
|
-
label:
|
|
995
|
-
onClick:
|
|
998
|
+
label: m.manage,
|
|
999
|
+
onClick: u
|
|
996
1000
|
}
|
|
997
1001
|
] : [],
|
|
998
1002
|
hasDivider: !0,
|
|
999
|
-
onAccountsFilterClick: () => y(
|
|
1003
|
+
onAccountsFilterClick: () => y(x.ACCOUNTS_CLICK_FILTER),
|
|
1000
1004
|
onBackClick: t,
|
|
1001
1005
|
onMenuClick: o,
|
|
1002
1006
|
sx: n,
|
|
1003
|
-
title:
|
|
1007
|
+
title: m.title,
|
|
1004
1008
|
children: [
|
|
1005
|
-
r ? /* @__PURE__ */ C(
|
|
1006
|
-
|
|
1007
|
-
/* @__PURE__ */ e(
|
|
1008
|
-
] }) : /* @__PURE__ */ e(
|
|
1009
|
+
r ? /* @__PURE__ */ C(t1, { children: [
|
|
1010
|
+
M.length < 1 && /* @__PURE__ */ e(v, { display: "flex", justifyContent: "center", my: 24, children: m.no_accounts }),
|
|
1011
|
+
/* @__PURE__ */ e(D3, {})
|
|
1012
|
+
] }) : /* @__PURE__ */ e(m1, { sx: { px: w ? 48 : 24, pt: 24 }, variant: "list" }),
|
|
1009
1013
|
/* @__PURE__ */ e(
|
|
1010
1014
|
z,
|
|
1011
1015
|
{
|
|
1012
|
-
onClose: () =>
|
|
1013
|
-
showConnectWidget:
|
|
1016
|
+
onClose: () => i(!1),
|
|
1017
|
+
showConnectWidget: c,
|
|
1014
1018
|
title: s.mini_title
|
|
1015
1019
|
}
|
|
1016
1020
|
),
|
|
1017
1021
|
/* @__PURE__ */ e(
|
|
1018
|
-
|
|
1022
|
+
r3,
|
|
1019
1023
|
{
|
|
1020
|
-
onClose: () =>
|
|
1024
|
+
onClose: () => d(!1),
|
|
1021
1025
|
showConnectionsWidget: l,
|
|
1022
|
-
title:
|
|
1026
|
+
title: m.manage_connections
|
|
1023
1027
|
}
|
|
1024
1028
|
)
|
|
1025
1029
|
]
|
|
1026
1030
|
}
|
|
1027
|
-
) : /* @__PURE__ */ e(
|
|
1028
|
-
},
|
|
1029
|
-
function
|
|
1031
|
+
) : /* @__PURE__ */ e(i1, {});
|
|
1032
|
+
}, e2 = A(k3);
|
|
1033
|
+
function I3(t) {
|
|
1030
1034
|
const { heldAccounts: o, externalAccounts: n } = t.reduce(
|
|
1031
|
-
(
|
|
1035
|
+
(c, i) => (i.member_is_managed_by_user ? c.externalAccounts.push(i) : c.heldAccounts.push(i), c),
|
|
1032
1036
|
{ heldAccounts: [], externalAccounts: [] }
|
|
1033
1037
|
);
|
|
1034
1038
|
return {
|
|
1035
|
-
heldAccounts:
|
|
1036
|
-
externalAccounts:
|
|
1039
|
+
heldAccounts: h1(o),
|
|
1040
|
+
externalAccounts: h1(n)
|
|
1037
1041
|
};
|
|
1038
1042
|
}
|
|
1039
|
-
function
|
|
1040
|
-
const { heldAccounts: n, externalAccounts:
|
|
1041
|
-
return
|
|
1043
|
+
function Z3(t, o) {
|
|
1044
|
+
const { heldAccounts: n, externalAccounts: c } = I3(t), i = n.slice(0, o);
|
|
1045
|
+
return i.length < o && i.push(...c.slice(0, o - i.length)), i;
|
|
1042
1046
|
}
|
|
1043
|
-
const
|
|
1047
|
+
const N3 = {
|
|
1044
1048
|
[I.CHECKING]: 1,
|
|
1045
1049
|
[I.SAVINGS]: 2,
|
|
1046
1050
|
[I.CREDIT_CARD]: 3
|
|
1047
|
-
},
|
|
1048
|
-
const
|
|
1051
|
+
}, C1 = (t) => N3[t] ?? t + 100, h1 = (t) => t.sort((o, n) => {
|
|
1052
|
+
const c = C1(o.account_type), i = C1(n.account_type), l = c - i;
|
|
1049
1053
|
if (l !== 0) return l;
|
|
1050
|
-
const
|
|
1051
|
-
return
|
|
1052
|
-
}),
|
|
1053
|
-
const { isAccountDataLoaded: n, loadAccountData:
|
|
1054
|
-
|
|
1054
|
+
const d = o.name ?? o.feed_name ?? "", a = n.name ?? n.feed_name ?? "";
|
|
1055
|
+
return d.localeCompare(a);
|
|
1056
|
+
}), O3 = ({ onPrimaryCtaClick: t, sx: o }) => {
|
|
1057
|
+
const { isAccountDataLoaded: n, loadAccountData: c } = D(), { accounts: i } = V(), { isInitialized: l, selectedAccounts: d } = G(), { isDesktop: a } = b1();
|
|
1058
|
+
o1({
|
|
1055
1059
|
widgetName: "AccountsMiniWidget",
|
|
1056
1060
|
isLoaded: l
|
|
1057
1061
|
}), h.useEffect(() => {
|
|
1058
|
-
n ||
|
|
1062
|
+
n || c().finally();
|
|
1059
1063
|
}, []);
|
|
1060
1064
|
const r = h.useMemo(
|
|
1061
|
-
() =>
|
|
1062
|
-
[
|
|
1065
|
+
() => Z3(d, a ? 5 : 3),
|
|
1066
|
+
[d, a]
|
|
1063
1067
|
);
|
|
1064
1068
|
return l ? /* @__PURE__ */ e(
|
|
1065
|
-
|
|
1069
|
+
A1,
|
|
1066
1070
|
{
|
|
1067
1071
|
className: "mx-exp-accounts-miniwidget",
|
|
1068
1072
|
onPrimaryCtaClick: t,
|
|
1069
|
-
primaryCtaLabel:
|
|
1073
|
+
primaryCtaLabel: i.primary_cta,
|
|
1070
1074
|
sx: o,
|
|
1071
|
-
title:
|
|
1075
|
+
title: i.mini_title,
|
|
1072
1076
|
children: n ? /* @__PURE__ */ C(O, { children: [
|
|
1073
|
-
|
|
1074
|
-
r.map((
|
|
1075
|
-
const s = r.indexOf(
|
|
1077
|
+
d.length === 0 && /* @__PURE__ */ e(E, { sx: { justifyContent: "center" }, children: i.no_accounts }),
|
|
1078
|
+
r.map((L, m) => {
|
|
1079
|
+
const s = r.indexOf(L) === r.length - 1;
|
|
1076
1080
|
return /* @__PURE__ */ C(h.Fragment, { children: [
|
|
1077
1081
|
/* @__PURE__ */ e(
|
|
1078
1082
|
U,
|
|
1079
1083
|
{
|
|
1080
|
-
account:
|
|
1084
|
+
account: L,
|
|
1081
1085
|
listItemProps: { sx: { px: 24 } },
|
|
1082
1086
|
shouldShowConnectionStatus: !0
|
|
1083
1087
|
}
|
|
1084
1088
|
),
|
|
1085
1089
|
!s && /* @__PURE__ */ e(W, { "aria-hidden": "true", variant: "inset" })
|
|
1086
|
-
] }, `account-item${
|
|
1090
|
+
] }, `account-item${m}`);
|
|
1087
1091
|
})
|
|
1088
|
-
] }) : /* @__PURE__ */ e(
|
|
1092
|
+
] }) : /* @__PURE__ */ e(m1, { sx: { px: 12, py: 8 }, variant: "list" })
|
|
1089
1093
|
}
|
|
1090
|
-
) : /* @__PURE__ */ e(
|
|
1091
|
-
},
|
|
1094
|
+
) : /* @__PURE__ */ e(i1, {});
|
|
1095
|
+
}, t2 = A(O3), F3 = () => /* @__PURE__ */ C(
|
|
1092
1096
|
"svg",
|
|
1093
1097
|
{
|
|
1094
1098
|
fill: "none",
|
|
@@ -1527,12 +1531,12 @@ const Z3 = {
|
|
|
1527
1531
|
)
|
|
1528
1532
|
]
|
|
1529
1533
|
}
|
|
1530
|
-
),
|
|
1531
|
-
const { connect: t } =
|
|
1532
|
-
return /* @__PURE__ */ C(
|
|
1533
|
-
/* @__PURE__ */ e(
|
|
1534
|
+
), P3 = () => {
|
|
1535
|
+
const { connect: t } = V();
|
|
1536
|
+
return /* @__PURE__ */ C(t1, { alignItems: "center", direction: "column", m: 24, children: [
|
|
1537
|
+
/* @__PURE__ */ e(F3, {}),
|
|
1534
1538
|
/* @__PURE__ */ e(
|
|
1535
|
-
|
|
1539
|
+
v,
|
|
1536
1540
|
{
|
|
1537
1541
|
sx: {
|
|
1538
1542
|
whiteSpace: "wrap",
|
|
@@ -1544,50 +1548,50 @@ const Z3 = {
|
|
|
1544
1548
|
}
|
|
1545
1549
|
)
|
|
1546
1550
|
] });
|
|
1547
|
-
},
|
|
1551
|
+
}, W3 = A(P3), B3 = ({
|
|
1548
1552
|
onPrimaryCtaClick: t = () => {
|
|
1549
1553
|
},
|
|
1550
1554
|
sx: o
|
|
1551
1555
|
}) => {
|
|
1552
|
-
const { isCopyLoaded: n } = G(), { connect:
|
|
1556
|
+
const { isCopyLoaded: n } = G(), { connect: c } = V(), [i, l] = h.useState(!1), d = () => {
|
|
1553
1557
|
l(!0), t();
|
|
1554
1558
|
};
|
|
1555
|
-
return
|
|
1559
|
+
return o1({
|
|
1556
1560
|
widgetName: "ConnectMiniWidget",
|
|
1557
1561
|
isLoaded: n
|
|
1558
1562
|
}), n ? /* @__PURE__ */ C(
|
|
1559
|
-
|
|
1563
|
+
A1,
|
|
1560
1564
|
{
|
|
1561
1565
|
className: "mx-exp-connect-miniwidget",
|
|
1562
|
-
onPrimaryCtaClick:
|
|
1563
|
-
primaryCtaLabel:
|
|
1566
|
+
onPrimaryCtaClick: d,
|
|
1567
|
+
primaryCtaLabel: c.primary_cta,
|
|
1564
1568
|
sx: o,
|
|
1565
|
-
title:
|
|
1569
|
+
title: c.mini_title,
|
|
1566
1570
|
children: [
|
|
1567
|
-
/* @__PURE__ */ e(
|
|
1568
|
-
|
|
1571
|
+
/* @__PURE__ */ e(W3, {}),
|
|
1572
|
+
i && /* @__PURE__ */ e(
|
|
1569
1573
|
z,
|
|
1570
1574
|
{
|
|
1571
1575
|
onClose: () => l(!1),
|
|
1572
|
-
showConnectWidget:
|
|
1573
|
-
title:
|
|
1576
|
+
showConnectWidget: i,
|
|
1577
|
+
title: c.mini_title
|
|
1574
1578
|
}
|
|
1575
1579
|
)
|
|
1576
1580
|
]
|
|
1577
1581
|
}
|
|
1578
|
-
) : /* @__PURE__ */ e(
|
|
1579
|
-
},
|
|
1582
|
+
) : /* @__PURE__ */ e(i1, {});
|
|
1583
|
+
}, n2 = A(B3);
|
|
1580
1584
|
export {
|
|
1581
|
-
|
|
1582
|
-
|
|
1583
|
-
|
|
1584
|
-
|
|
1585
|
-
|
|
1586
|
-
|
|
1587
|
-
|
|
1588
|
-
|
|
1589
|
-
|
|
1590
|
-
|
|
1591
|
-
|
|
1592
|
-
|
|
1585
|
+
T3 as AccountDetailsContent,
|
|
1586
|
+
x1 as AccountDetailsHeader,
|
|
1587
|
+
r2 as AccountStore,
|
|
1588
|
+
t2 as AccountsMiniWidget,
|
|
1589
|
+
e2 as AccountsWidget,
|
|
1590
|
+
n2 as ConnectMiniWidget,
|
|
1591
|
+
J as FieldType,
|
|
1592
|
+
s2 as MemberConnectionStatus,
|
|
1593
|
+
c2 as getAccountBalanceDetails,
|
|
1594
|
+
k1 as getAccountDetailFields,
|
|
1595
|
+
R as useAccountUiStore,
|
|
1596
|
+
p3 as useGetMergeableAccounts
|
|
1593
1597
|
};
|