@mx-cartographer/experiences 7.2.14-alpha.san1 → 7.2.14-alpha.san3
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/dist/{FinstrongStore-1MFI6RcM.mjs → FinstrongStore-bkPQR8ln.mjs} +44 -47
- package/dist/common/index.es.js +1 -1
- package/dist/common/types/Widgets.d.ts +1 -1
- package/dist/finstrong/FinstrongWidget.d.ts +1 -1
- package/dist/finstrong/components/KeyIndicatorsSpendTab.d.ts +4 -1
- package/dist/finstrong/components/KeyIndicatorsTabItem.d.ts +1 -0
- package/dist/finstrong/components/KeyIndicatorsTabItemDrawer.d.ts +2 -1
- package/dist/finstrong/components/KeyIndicatorsTabsWidget.d.ts +4 -1
- package/dist/finstrong/components/SpendLessThanYouMake/SpendLessThanYouMakeComponent.d.ts +4 -1
- package/dist/finstrong/index.es.js +944 -944
- package/dist/finstrong/stores/FinstrongStore.d.ts +0 -1
- package/package.json +1 -1
|
@@ -1,31 +1,31 @@
|
|
|
1
|
-
import { jsxs as
|
|
2
|
-
import
|
|
1
|
+
import { jsxs as a, Fragment as E, jsx as e } from "react/jsx-runtime";
|
|
2
|
+
import v from "@mui/material/Box";
|
|
3
3
|
import u from "@mui/material/Stack";
|
|
4
|
-
import { useTheme as
|
|
4
|
+
import { useTheme as G, alpha as fe } from "@mui/material/styles";
|
|
5
5
|
import { PieChart as _n, BarPlot as hn } from "@mui/x-charts";
|
|
6
6
|
import { TrendingUp as gt, ArrowRightAlt as mn, TrendingDown as gn, AccountBalance as yt, ChevronRight as Z, MultilineChart as bt, CreditCard as Ke, CheckCircle as yn, Cancel as bn, Savings as fn, ContentCopy as xn, Add as ft, Cardiology as Sn, Payments as Cn, CalendarMonth as vn, ExpandMore as wn } from "@mxenabled/mx-icons";
|
|
7
7
|
import { P as k, H3 as N, Text as I, InstitutionLogo as xt, H2 as Pe, MerchantLogo as kn, Icon as Mn } from "@mxenabled/mxui";
|
|
8
|
-
import { g as Dn, a as In, r as rt, b as An, c as je, d as St, C as
|
|
9
|
-
import { y as Gi, F as Hi } from "../FinstrongStore-
|
|
8
|
+
import { g as Dn, a as In, r as rt, b as An, c as je, d as St, C as Ce, e as ve, f as Tn, h as On, i as Rn, j as Ct, k as at, l as Fn, m as it, n as Pn, o as vt, p as Bn, q as wt, s as Te, t as Ln, u as $n, v as Wn, w as zn, A as te, x as En, P as Gn } from "../FinstrongStore-bkPQR8ln.mjs";
|
|
9
|
+
import { y as Gi, F as Hi } from "../FinstrongStore-bkPQR8ln.mjs";
|
|
10
10
|
import * as st from "d3";
|
|
11
11
|
import { observer as S } from "mobx-react-lite";
|
|
12
|
-
import { u as
|
|
12
|
+
import { u as w, b as j, p as Q, z as F, q as Hn, a as kt, d as ke, m as Ye, g as Nn, f as Kn, j as Ve, h as jn, i as Yn } from "../hooks-C41HAxM5.mjs";
|
|
13
13
|
import { L as J } from "../Loader-DUaFpDGv.mjs";
|
|
14
14
|
import m from "react";
|
|
15
|
-
import
|
|
15
|
+
import z from "@mui/material/Button";
|
|
16
16
|
import K from "@mui/material/Card";
|
|
17
17
|
import { L as Xe } from "../LineChart-Ct9DNmhS.mjs";
|
|
18
18
|
import { C as Mt } from "../ConnectionsDrawer-Bz4uwdFE.mjs";
|
|
19
|
-
import { l as
|
|
20
|
-
import
|
|
19
|
+
import { l as re, g as Dt, A as He } from "../ConnectDrawer-CuUj16NH.mjs";
|
|
20
|
+
import ce from "@mui/material/Tab";
|
|
21
21
|
import qe from "@mui/material/Tabs";
|
|
22
22
|
import Oe from "@mui/material/TextField";
|
|
23
23
|
import { u as Ue } from "../useScreenSize-B6JyS_Lj.mjs";
|
|
24
24
|
import { D as Vn, f as Xn, a as qn } from "../Dialog-BPTr3qHE.mjs";
|
|
25
25
|
import { u as It } from "../useDimensions-27p2evRx.mjs";
|
|
26
26
|
import Un from "@mui/material/Chip";
|
|
27
|
-
import { D as
|
|
28
|
-
import
|
|
27
|
+
import { D as ne } from "../Drawer-BEtCk82g.mjs";
|
|
28
|
+
import oe from "@mui/material/Divider";
|
|
29
29
|
import ye from "@mui/material/ListItem";
|
|
30
30
|
import At from "@mui/material/ListItemAvatar";
|
|
31
31
|
import be from "@mui/material/ListItemText";
|
|
@@ -41,7 +41,7 @@ import { h as Ze } from "../DateUtil-CBdcsyuk.mjs";
|
|
|
41
41
|
import { useVirtualizer as no } from "@tanstack/react-virtual";
|
|
42
42
|
import { u as oo, s as Ne, h as Ft, S as Pt, b as Bt, Z as ro } from "../TransactionDetails-CaJruWq3.mjs";
|
|
43
43
|
import { A as ao, W as io } from "../WidgetContainer-6dsjtOVg.mjs";
|
|
44
|
-
import { T as
|
|
44
|
+
import { T as le } from "../TabContentContainer-j01JYR_7.mjs";
|
|
45
45
|
import { b as Y } from "../Localization-2MODESHW.mjs";
|
|
46
46
|
import { E as Fe } from "../EmptyState-DoxNUae-.mjs";
|
|
47
47
|
import so from "@mui/material/useMediaQuery";
|
|
@@ -77,53 +77,53 @@ const zo = ({
|
|
|
77
77
|
dataIndex: r,
|
|
78
78
|
arcColor: n,
|
|
79
79
|
arcStartAngle: o,
|
|
80
|
-
totalAngularSpan:
|
|
81
|
-
centerX:
|
|
82
|
-
centerY:
|
|
83
|
-
arcRadius:
|
|
80
|
+
totalAngularSpan: s,
|
|
81
|
+
centerX: i,
|
|
82
|
+
centerY: c,
|
|
83
|
+
arcRadius: p,
|
|
84
84
|
innerArcRadius: l,
|
|
85
|
-
outterArcRadius:
|
|
86
|
-
progressEndAngle:
|
|
87
|
-
unitsPerSegment:
|
|
88
|
-
isFinacialStrengthGraph:
|
|
85
|
+
outterArcRadius: d,
|
|
86
|
+
progressEndAngle: _,
|
|
87
|
+
unitsPerSegment: h,
|
|
88
|
+
isFinacialStrengthGraph: y
|
|
89
89
|
}) => {
|
|
90
|
-
const f =
|
|
90
|
+
const f = G(), x = [
|
|
91
91
|
{ offset: "13.62%", color: f.palette.chartMono.chartMono2 },
|
|
92
92
|
{ offset: "36.67%", color: f.palette.chartMono.chartMono3 },
|
|
93
93
|
{ offset: "59.72%", color: f.palette.chartMono.chartMono4 },
|
|
94
94
|
{ offset: "83.46%", color: f.palette.chartMono.chartMono5 }
|
|
95
|
-
], [
|
|
95
|
+
], [b, D] = Dn(
|
|
96
96
|
t,
|
|
97
|
-
|
|
97
|
+
s,
|
|
98
98
|
o,
|
|
99
99
|
r
|
|
100
|
-
), [g,
|
|
101
|
-
|
|
100
|
+
), [g, C] = In(
|
|
101
|
+
b,
|
|
102
102
|
D,
|
|
103
103
|
r,
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
), M = st.arc().innerRadius(l).outerRadius(
|
|
107
|
-
return /* @__PURE__ */
|
|
104
|
+
h,
|
|
105
|
+
_
|
|
106
|
+
), M = st.arc().innerRadius(l).outerRadius(d).startAngle(b).endAngle(D).padAngle(0.02).cornerRadius(8), $ = st.arc().innerRadius(l).outerRadius(d).startAngle(g).endAngle(C).padAngle(0.02).cornerRadius(8);
|
|
107
|
+
return /* @__PURE__ */ a(E, { children: [
|
|
108
108
|
/* @__PURE__ */ e(
|
|
109
109
|
"path",
|
|
110
110
|
{
|
|
111
111
|
d: M({}),
|
|
112
|
-
fill:
|
|
112
|
+
fill: y ? f.palette.divider : n
|
|
113
113
|
}
|
|
114
114
|
),
|
|
115
|
-
|
|
115
|
+
y && /* @__PURE__ */ e("path", { d: $({}), fill: "url(#arcGradient)" }),
|
|
116
116
|
/* @__PURE__ */ e("defs", { children: /* @__PURE__ */ e(
|
|
117
117
|
"linearGradient",
|
|
118
118
|
{
|
|
119
|
-
gradientTransform: `rotate(5, ${
|
|
119
|
+
gradientTransform: `rotate(5, ${i}, ${c})`,
|
|
120
120
|
gradientUnits: "userSpaceOnUse",
|
|
121
121
|
id: "arcGradient",
|
|
122
|
-
x1:
|
|
123
|
-
x2:
|
|
124
|
-
y1:
|
|
125
|
-
y2:
|
|
126
|
-
children:
|
|
122
|
+
x1: i + p * 0.8 * Math.cos(Math.PI / 1.35),
|
|
123
|
+
x2: i - p * 0.8 * Math.cos(Math.PI / 1.35),
|
|
124
|
+
y1: c + p * 0.8 * Math.sin(Math.PI / 1.35),
|
|
125
|
+
y2: c - p * 0.8 * Math.sin(Math.PI / 1.35),
|
|
126
|
+
children: x.map((H, O) => /* @__PURE__ */ e("stop", { offset: H.offset, stopColor: H.color }, O))
|
|
127
127
|
}
|
|
128
128
|
) })
|
|
129
129
|
] });
|
|
@@ -132,26 +132,26 @@ const zo = ({
|
|
|
132
132
|
healthScore: r,
|
|
133
133
|
size: n = "L",
|
|
134
134
|
dialScoreData: o,
|
|
135
|
-
minValue:
|
|
136
|
-
maxValue:
|
|
137
|
-
markerColor:
|
|
138
|
-
healthScoreStatus:
|
|
135
|
+
minValue: s = 0,
|
|
136
|
+
maxValue: i = 100,
|
|
137
|
+
markerColor: c,
|
|
138
|
+
healthScoreStatus: p,
|
|
139
139
|
footerCenterContent: l,
|
|
140
|
-
footerLeftContent:
|
|
141
|
-
footerRightContent:
|
|
142
|
-
isFinacialStrengthGraph:
|
|
140
|
+
footerLeftContent: d,
|
|
141
|
+
footerRightContent: _,
|
|
142
|
+
isFinacialStrengthGraph: h = !1
|
|
143
143
|
}) => {
|
|
144
|
-
const
|
|
144
|
+
const y = G(), f = -Math.PI / 1.35, x = Math.PI / 1.35, b = x - f, D = b / (i - s), g = (r - s) * D, C = f + g + 0.02, M = n !== "SM" ? 0.1 : 0.12, $ = t, H = t * (1 - M), O = $ * 2.5, W = O / 2, V = O / 2, ee = (H + $) / 2, pe = r !== 25 && r !== 50 && r !== 75 && r !== 100 ? 0 : 0.12, [ue, _e] = An(ee, C, pe), X = r / 25, he = {
|
|
145
145
|
L: { markerSize: 12, healthScoreFontSize: 64 },
|
|
146
146
|
M: { markerSize: 10, healthScoreFontSize: 48 },
|
|
147
147
|
SM: { markerSize: 3, healthScoreFontSize: 14 }
|
|
148
|
-
},
|
|
149
|
-
return /* @__PURE__ */
|
|
148
|
+
}, ae = l === 0 ? mn : gn;
|
|
149
|
+
return /* @__PURE__ */ a(
|
|
150
150
|
u,
|
|
151
151
|
{
|
|
152
152
|
sx: {
|
|
153
|
-
width:
|
|
154
|
-
height:
|
|
153
|
+
width: O,
|
|
154
|
+
height: O,
|
|
155
155
|
position: "relative",
|
|
156
156
|
alignSelf: "center"
|
|
157
157
|
},
|
|
@@ -159,16 +159,16 @@ const zo = ({
|
|
|
159
159
|
/* @__PURE__ */ e(
|
|
160
160
|
_n,
|
|
161
161
|
{
|
|
162
|
-
height:
|
|
162
|
+
height: O,
|
|
163
163
|
margin: { top: 0, right: 0, bottom: 0, left: 0 },
|
|
164
164
|
series: [
|
|
165
165
|
{
|
|
166
166
|
data: o,
|
|
167
|
-
innerRadius:
|
|
167
|
+
innerRadius: H,
|
|
168
168
|
outerRadius: $,
|
|
169
169
|
startAngle: Math.round(rt(f)),
|
|
170
170
|
// Use Math.degrees to convert
|
|
171
|
-
endAngle: Math.round(rt(
|
|
171
|
+
endAngle: Math.round(rt(x))
|
|
172
172
|
// Use Math.degrees to convert
|
|
173
173
|
}
|
|
174
174
|
],
|
|
@@ -177,21 +177,21 @@ const zo = ({
|
|
|
177
177
|
legend: { hidden: !0 }
|
|
178
178
|
},
|
|
179
179
|
slots: {
|
|
180
|
-
pieArc: (
|
|
180
|
+
pieArc: (Me) => /* @__PURE__ */ e(
|
|
181
181
|
zo,
|
|
182
182
|
{
|
|
183
|
-
arcColor:
|
|
183
|
+
arcColor: Me.color,
|
|
184
184
|
arcRadius: t,
|
|
185
185
|
arcStartAngle: f,
|
|
186
|
-
centerX:
|
|
186
|
+
centerX: W,
|
|
187
187
|
centerY: V,
|
|
188
|
-
dataIndex:
|
|
188
|
+
dataIndex: Me.dataIndex,
|
|
189
189
|
dialScoreData: o,
|
|
190
|
-
innerArcRadius:
|
|
191
|
-
isFinacialStrengthGraph:
|
|
190
|
+
innerArcRadius: H,
|
|
191
|
+
isFinacialStrengthGraph: h,
|
|
192
192
|
outterArcRadius: $,
|
|
193
|
-
progressEndAngle:
|
|
194
|
-
totalAngularSpan:
|
|
193
|
+
progressEndAngle: C,
|
|
194
|
+
totalAngularSpan: b,
|
|
195
195
|
unitsPerSegment: X
|
|
196
196
|
}
|
|
197
197
|
)
|
|
@@ -201,31 +201,31 @@ const zo = ({
|
|
|
201
201
|
stroke: "none"
|
|
202
202
|
}
|
|
203
203
|
},
|
|
204
|
-
width:
|
|
205
|
-
children: r >=
|
|
204
|
+
width: O,
|
|
205
|
+
children: r >= s && r <= i && /* @__PURE__ */ e(
|
|
206
206
|
"circle",
|
|
207
207
|
{
|
|
208
|
-
cx:
|
|
209
|
-
cy: V +
|
|
210
|
-
fill:
|
|
211
|
-
r:
|
|
212
|
-
stroke:
|
|
208
|
+
cx: W + ue,
|
|
209
|
+
cy: V + _e,
|
|
210
|
+
fill: y.palette.common.white,
|
|
211
|
+
r: he[n].markerSize,
|
|
212
|
+
stroke: h ? "url(#arcGradient)" : c,
|
|
213
213
|
strokeWidth: n !== "SM" ? 3 : 1
|
|
214
214
|
}
|
|
215
215
|
)
|
|
216
216
|
}
|
|
217
217
|
),
|
|
218
218
|
/* @__PURE__ */ e(
|
|
219
|
-
|
|
219
|
+
v,
|
|
220
220
|
{
|
|
221
221
|
sx: {
|
|
222
222
|
position: "absolute",
|
|
223
223
|
top: `${V}px`,
|
|
224
|
-
left: `${
|
|
224
|
+
left: `${W}px`,
|
|
225
225
|
transform: "translate(-50%, -50%)",
|
|
226
226
|
textAlign: "center"
|
|
227
227
|
},
|
|
228
|
-
children: /* @__PURE__ */
|
|
228
|
+
children: /* @__PURE__ */ a(
|
|
229
229
|
u,
|
|
230
230
|
{
|
|
231
231
|
spacing: 1,
|
|
@@ -235,31 +235,31 @@ const zo = ({
|
|
|
235
235
|
k,
|
|
236
236
|
{
|
|
237
237
|
sx: {
|
|
238
|
-
fontSize:
|
|
238
|
+
fontSize: he[n].healthScoreFontSize,
|
|
239
239
|
lineHeight: n !== "SM" ? "48px" : "100%"
|
|
240
240
|
},
|
|
241
241
|
variant: "H1",
|
|
242
242
|
children: r
|
|
243
243
|
}
|
|
244
244
|
),
|
|
245
|
-
n !== "SM" && /* @__PURE__ */ e(k, { sx: { fontWeight: 600 }, variant: n === "L" ? "body1" : "body2", children:
|
|
245
|
+
n !== "SM" && /* @__PURE__ */ e(k, { sx: { fontWeight: 600 }, variant: n === "L" ? "body1" : "body2", children: p })
|
|
246
246
|
]
|
|
247
247
|
}
|
|
248
248
|
)
|
|
249
249
|
}
|
|
250
250
|
),
|
|
251
251
|
l !== void 0 && /* @__PURE__ */ e(
|
|
252
|
-
|
|
252
|
+
v,
|
|
253
253
|
{
|
|
254
254
|
sx: {
|
|
255
255
|
position: "absolute",
|
|
256
256
|
top: `${V * 2 * 0.83}px`,
|
|
257
|
-
left: `${
|
|
257
|
+
left: `${W}px`,
|
|
258
258
|
transform: "translate(-50%, -50%)",
|
|
259
259
|
textAlign: "center"
|
|
260
260
|
},
|
|
261
|
-
children: typeof l == "number" ? /* @__PURE__ */
|
|
262
|
-
l > 0 ? /* @__PURE__ */ e(gt, { size: 16, sx: { color: "success.main" } }) : /* @__PURE__ */ e(
|
|
261
|
+
children: typeof l == "number" ? /* @__PURE__ */ a(u, { sx: { flexDirection: "row", alignItems: "center", gap: 4 }, children: [
|
|
262
|
+
l > 0 ? /* @__PURE__ */ e(gt, { size: 16, sx: { color: "success.main" } }) : /* @__PURE__ */ e(ae, { size: 16, sx: { color: "text.secondary" } }),
|
|
263
263
|
/* @__PURE__ */ e(
|
|
264
264
|
k,
|
|
265
265
|
{
|
|
@@ -274,31 +274,31 @@ const zo = ({
|
|
|
274
274
|
] }) : /* @__PURE__ */ e(k, { sx: { color: "text.secondary" }, variant: "subtitle2", children: l })
|
|
275
275
|
}
|
|
276
276
|
),
|
|
277
|
-
|
|
278
|
-
|
|
277
|
+
d !== void 0 && /* @__PURE__ */ e(
|
|
278
|
+
v,
|
|
279
279
|
{
|
|
280
280
|
sx: {
|
|
281
281
|
position: "absolute",
|
|
282
282
|
top: `${V * 2 * 0.83}px`,
|
|
283
|
-
left: `${
|
|
283
|
+
left: `${W - W / 2}px`,
|
|
284
284
|
// shift left from center
|
|
285
285
|
transform: "translate(-50%, -50%)",
|
|
286
286
|
textAlign: "left"
|
|
287
287
|
},
|
|
288
|
-
children: /* @__PURE__ */ e(k, { variant: "body1", children:
|
|
288
|
+
children: /* @__PURE__ */ e(k, { variant: "body1", children: d })
|
|
289
289
|
}
|
|
290
290
|
),
|
|
291
|
-
|
|
292
|
-
|
|
291
|
+
_ !== void 0 && /* @__PURE__ */ e(
|
|
292
|
+
v,
|
|
293
293
|
{
|
|
294
294
|
sx: {
|
|
295
295
|
position: "absolute",
|
|
296
296
|
top: `${V * 2 * 0.83}px`,
|
|
297
|
-
left: `${
|
|
297
|
+
left: `${W + W / 2}px`,
|
|
298
298
|
transform: "translate(-50%, -50%)",
|
|
299
299
|
textAlign: "right"
|
|
300
300
|
},
|
|
301
|
-
children: /* @__PURE__ */ e(k, { variant: "body1", children:
|
|
301
|
+
children: /* @__PURE__ */ e(k, { variant: "body1", children: _ })
|
|
302
302
|
}
|
|
303
303
|
)
|
|
304
304
|
]
|
|
@@ -306,20 +306,20 @@ const zo = ({
|
|
|
306
306
|
);
|
|
307
307
|
}, Et = S(
|
|
308
308
|
({ arcRadius: t, size: r = "L", healthScore: n, footerCenterContent: o }) => {
|
|
309
|
-
const
|
|
309
|
+
const s = [
|
|
310
310
|
{ id: 1, label: "Group A", value: 25 },
|
|
311
311
|
{ id: 2, label: "Group B", value: 25 },
|
|
312
312
|
{ id: 3, label: "Group C", value: 25 },
|
|
313
313
|
{ id: 4, label: "Group D", value: 25 }
|
|
314
|
-
], { finstrong:
|
|
314
|
+
], { finstrong: i } = w(), c = je(n, i);
|
|
315
315
|
return /* @__PURE__ */ e(
|
|
316
316
|
zt,
|
|
317
317
|
{
|
|
318
318
|
arcRadius: t,
|
|
319
|
-
dialScoreData:
|
|
320
|
-
footerCenterContent: r === "L" ?
|
|
319
|
+
dialScoreData: s,
|
|
320
|
+
footerCenterContent: r === "L" ? i.footer_center_content_updated_just_now : o,
|
|
321
321
|
healthScore: n,
|
|
322
|
-
healthScoreStatus:
|
|
322
|
+
healthScoreStatus: c.status,
|
|
323
323
|
isFinacialStrengthGraph: !0,
|
|
324
324
|
size: r
|
|
325
325
|
}
|
|
@@ -331,60 +331,60 @@ const zo = ({
|
|
|
331
331
|
size: r = "L",
|
|
332
332
|
healthScore: n,
|
|
333
333
|
maxValue: o = 850,
|
|
334
|
-
minValue:
|
|
335
|
-
footerCenterContent:
|
|
334
|
+
minValue: s = 300,
|
|
335
|
+
footerCenterContent: i
|
|
336
336
|
}) => {
|
|
337
|
-
const
|
|
337
|
+
const p = G().palette.mode === "dark", l = [
|
|
338
338
|
{
|
|
339
339
|
id: 1,
|
|
340
340
|
label: "Poor",
|
|
341
341
|
value: 29,
|
|
342
|
-
color:
|
|
342
|
+
color: p ? Ce.POOR : ve.POOR
|
|
343
343
|
},
|
|
344
344
|
{
|
|
345
345
|
id: 2,
|
|
346
346
|
label: "Fair",
|
|
347
347
|
value: 25,
|
|
348
|
-
color:
|
|
348
|
+
color: p ? Ce.FAIR : ve.FAIR
|
|
349
349
|
},
|
|
350
350
|
{
|
|
351
351
|
id: 3,
|
|
352
352
|
label: "Good",
|
|
353
353
|
value: 17,
|
|
354
|
-
color:
|
|
354
|
+
color: p ? Ce.GOOD : ve.GOOD
|
|
355
355
|
},
|
|
356
356
|
{
|
|
357
357
|
id: 4,
|
|
358
358
|
label: "Very Good",
|
|
359
359
|
value: 17,
|
|
360
|
-
color:
|
|
360
|
+
color: p ? Ce.VERY_GOOD : ve.VERY_GOOD
|
|
361
361
|
},
|
|
362
362
|
{
|
|
363
363
|
id: 5,
|
|
364
364
|
label: "Exceptional",
|
|
365
365
|
value: 12,
|
|
366
|
-
color:
|
|
366
|
+
color: p ? Ce.EXCEPTIONAL : ve.EXCEPTIONAL
|
|
367
367
|
}
|
|
368
|
-
], { finstrong:
|
|
369
|
-
if (!
|
|
370
|
-
const { status:
|
|
368
|
+
], { finstrong: d } = w(), { isCopyLoaded: _ } = j();
|
|
369
|
+
if (!_) return /* @__PURE__ */ e(J, {});
|
|
370
|
+
const { status: h, color: y = "none" } = St(
|
|
371
371
|
n,
|
|
372
|
-
|
|
373
|
-
|
|
372
|
+
p,
|
|
373
|
+
d.credit_score_status
|
|
374
374
|
);
|
|
375
375
|
return /* @__PURE__ */ e(
|
|
376
376
|
zt,
|
|
377
377
|
{
|
|
378
378
|
arcRadius: t,
|
|
379
379
|
dialScoreData: l,
|
|
380
|
-
footerCenterContent:
|
|
381
|
-
footerLeftContent:
|
|
380
|
+
footerCenterContent: i,
|
|
381
|
+
footerLeftContent: s,
|
|
382
382
|
footerRightContent: o,
|
|
383
383
|
healthScore: n,
|
|
384
|
-
healthScoreStatus:
|
|
385
|
-
markerColor:
|
|
384
|
+
healthScoreStatus: h,
|
|
385
|
+
markerColor: y,
|
|
386
386
|
maxValue: o,
|
|
387
|
-
minValue:
|
|
387
|
+
minValue: s,
|
|
388
388
|
size: r
|
|
389
389
|
}
|
|
390
390
|
);
|
|
@@ -394,13 +394,13 @@ const zo = ({
|
|
|
394
394
|
isDashboard: r = !1,
|
|
395
395
|
hasIcon: n = !0,
|
|
396
396
|
buttonText: o,
|
|
397
|
-
title:
|
|
398
|
-
titleDrawer:
|
|
399
|
-
description:
|
|
400
|
-
sx:
|
|
397
|
+
title: s,
|
|
398
|
+
titleDrawer: i,
|
|
399
|
+
description: c,
|
|
400
|
+
sx: p
|
|
401
401
|
}) => {
|
|
402
|
-
const [l,
|
|
403
|
-
return t ? /* @__PURE__ */
|
|
402
|
+
const [l, d] = m.useState(!1), { connect: _, finstrong: h } = w();
|
|
403
|
+
return t ? /* @__PURE__ */ a(
|
|
404
404
|
K,
|
|
405
405
|
{
|
|
406
406
|
sx: {
|
|
@@ -408,10 +408,10 @@ const zo = ({
|
|
|
408
408
|
pt: 18,
|
|
409
409
|
px: 24,
|
|
410
410
|
width: "100%",
|
|
411
|
-
...
|
|
411
|
+
...p
|
|
412
412
|
},
|
|
413
413
|
children: [
|
|
414
|
-
/* @__PURE__ */
|
|
414
|
+
/* @__PURE__ */ a(
|
|
415
415
|
u,
|
|
416
416
|
{
|
|
417
417
|
sx: {
|
|
@@ -420,7 +420,7 @@ const zo = ({
|
|
|
420
420
|
},
|
|
421
421
|
children: [
|
|
422
422
|
n && /* @__PURE__ */ e(yt, { sx: { height: 20, width: 20 } }),
|
|
423
|
-
/* @__PURE__ */ e(N, { className: "connect-more-accounts-title", sx: { ...r && { fontSize: 15 } }, children:
|
|
423
|
+
/* @__PURE__ */ e(N, { className: "connect-more-accounts-title", sx: { ...r && { fontSize: 15 } }, children: s || h.connect_more_accounts_title })
|
|
424
424
|
]
|
|
425
425
|
}
|
|
426
426
|
),
|
|
@@ -430,80 +430,80 @@ const zo = ({
|
|
|
430
430
|
className: "connect-more-accounts-description",
|
|
431
431
|
sx: { color: "text.secondary", mt: 8 },
|
|
432
432
|
variant: "subtitle1",
|
|
433
|
-
children:
|
|
433
|
+
children: c || h.connect_more_accounts_description
|
|
434
434
|
}
|
|
435
435
|
),
|
|
436
436
|
/* @__PURE__ */ e(
|
|
437
|
-
|
|
437
|
+
z,
|
|
438
438
|
{
|
|
439
439
|
endIcon: /* @__PURE__ */ e(Z, {}),
|
|
440
|
-
onClick: () =>
|
|
440
|
+
onClick: () => d(!0),
|
|
441
441
|
size: "small",
|
|
442
442
|
sx: { p: 0, mt: 8, "&:hover": { backgroundColor: "transparent" } },
|
|
443
|
-
children: /* @__PURE__ */ e(I, { sx: { fontWeight: 600 }, variant: "body2", children: o ||
|
|
443
|
+
children: /* @__PURE__ */ e(I, { sx: { fontWeight: 600 }, variant: "body2", children: o || h.connect_more_accounts_button })
|
|
444
444
|
}
|
|
445
445
|
),
|
|
446
446
|
t === "connectDrawer" && /* @__PURE__ */ e(
|
|
447
|
-
|
|
447
|
+
re,
|
|
448
448
|
{
|
|
449
|
-
onClose: () =>
|
|
449
|
+
onClose: () => d(!1),
|
|
450
450
|
showConnectWidget: l,
|
|
451
|
-
title:
|
|
451
|
+
title: i || _.mini_title
|
|
452
452
|
}
|
|
453
453
|
),
|
|
454
454
|
t === "connectionsDrawer" && /* @__PURE__ */ e(
|
|
455
455
|
Mt,
|
|
456
456
|
{
|
|
457
|
-
onClose: () =>
|
|
457
|
+
onClose: () => d(!1),
|
|
458
458
|
showConnectionsWidget: l,
|
|
459
|
-
title:
|
|
459
|
+
title: i || _.mini_title
|
|
460
460
|
}
|
|
461
461
|
)
|
|
462
462
|
]
|
|
463
463
|
}
|
|
464
464
|
) : null;
|
|
465
465
|
};
|
|
466
|
-
var
|
|
466
|
+
var de = /* @__PURE__ */ ((t) => (t.SpendLessThanYouMake = "spendLessThanYouMake", t.PayBillsOnTime = "payBillsOnTime", t.SaveEnoughToLiveOn = "saveEnoughToLiveOn", t.MaintainEmergencySavings = "maintainEmergencySavings", t.HaveManageableDebt = "haveManageableDebt", t.HaveAGoodCreditScore = "haveAGoodCreditScore", t))(de || {});
|
|
467
467
|
const Go = ({ isOpen: t, onClose: r }) => {
|
|
468
|
-
const { common: n, finstrong: o } =
|
|
469
|
-
r(), setTimeout(() => l(
|
|
470
|
-
},
|
|
471
|
-
!
|
|
468
|
+
const { common: n, finstrong: o } = w(), { isMobile: s } = Ue(), { updateUser: i, user: c } = Q(), [p, l] = m.useState(c.credit_score || 0), d = !isNaN(p), _ = () => {
|
|
469
|
+
r(), setTimeout(() => l(c.credit_score || 0), 300);
|
|
470
|
+
}, h = () => {
|
|
471
|
+
!p || p === c.credit_score || i({ ...c, credit_score: p });
|
|
472
472
|
};
|
|
473
473
|
return /* @__PURE__ */ e(
|
|
474
474
|
Vn,
|
|
475
475
|
{
|
|
476
476
|
copy: { close_aria: n.close_aria, title: o.edit_credit_score },
|
|
477
|
-
disablePrimaryButton: !
|
|
477
|
+
disablePrimaryButton: !p || !d,
|
|
478
478
|
isOpen: t,
|
|
479
479
|
maxWidth: "xs",
|
|
480
|
-
onClose:
|
|
481
|
-
onPrimaryAction:
|
|
480
|
+
onClose: _,
|
|
481
|
+
onPrimaryAction: h,
|
|
482
482
|
primaryColor: "primary",
|
|
483
483
|
primaryText: n.save_button,
|
|
484
484
|
sx: {
|
|
485
485
|
"& .MuiDialog-paper": {
|
|
486
|
-
minWidth:
|
|
486
|
+
minWidth: s ? "100%" : 400
|
|
487
487
|
}
|
|
488
488
|
},
|
|
489
489
|
children: /* @__PURE__ */ e(
|
|
490
490
|
"form",
|
|
491
491
|
{
|
|
492
|
-
onSubmit: (
|
|
493
|
-
|
|
492
|
+
onSubmit: (y) => {
|
|
493
|
+
y.preventDefault(), h(), _();
|
|
494
494
|
},
|
|
495
495
|
children: /* @__PURE__ */ e(
|
|
496
496
|
Oe,
|
|
497
497
|
{
|
|
498
|
-
error: !
|
|
498
|
+
error: !d,
|
|
499
499
|
fullWidth: !0,
|
|
500
500
|
inputMode: "numeric",
|
|
501
501
|
inputProps: {
|
|
502
502
|
noValidate: !0,
|
|
503
503
|
pattern: "[0-9]*"
|
|
504
504
|
},
|
|
505
|
-
onChange: (
|
|
506
|
-
value:
|
|
505
|
+
onChange: (y) => l(Number(y.target.value)),
|
|
506
|
+
value: d ? p : ""
|
|
507
507
|
}
|
|
508
508
|
)
|
|
509
509
|
}
|
|
@@ -514,11 +514,11 @@ const Go = ({ isOpen: t, onClose: r }) => {
|
|
|
514
514
|
credit_over_time_title: "Your Credit Over Time",
|
|
515
515
|
credit_over_time_zero_state_desc: "Add your credit score to start building a full picture of your credit health."
|
|
516
516
|
}, Ho = ({ chartFor: t }) => {
|
|
517
|
-
const r =
|
|
517
|
+
const r = G(), n = r.palette.mode === "dark", { monthlySummaries: o } = F(), { user: s } = Q(), { finstrong: i } = w(), [c, { width: p }] = It(), l = {
|
|
518
518
|
savingsOverTime: {
|
|
519
519
|
icon: /* @__PURE__ */ e(gt, { size: 48, sx: { marginBottom: 8 } }),
|
|
520
|
-
title:
|
|
521
|
-
description:
|
|
520
|
+
title: i.key_indicators_save.zero_state_title,
|
|
521
|
+
description: i.key_indicators_save.zero_state_description
|
|
522
522
|
},
|
|
523
523
|
debtOverTime: {
|
|
524
524
|
icon: /* @__PURE__ */ e(bt, { size: 48, sx: { marginBottom: 8 } }),
|
|
@@ -530,50 +530,50 @@ const Go = ({ isOpen: t, onClose: r }) => {
|
|
|
530
530
|
title: ze.credit_over_time_title,
|
|
531
531
|
description: ze.credit_over_time_zero_state_desc
|
|
532
532
|
}
|
|
533
|
-
}[t],
|
|
533
|
+
}[t], _ = {
|
|
534
534
|
savingsOverTime: {
|
|
535
|
-
title:
|
|
535
|
+
title: i.key_indicators_save.savings_over_time,
|
|
536
536
|
valueKey: "available_cash"
|
|
537
537
|
},
|
|
538
538
|
debtOverTime: {
|
|
539
|
-
title:
|
|
539
|
+
title: i.key_indicators_borrow.have_manageable_debt_drawer.debt_over_time,
|
|
540
540
|
valueKey: "debt_balance"
|
|
541
541
|
},
|
|
542
542
|
creditOverTime: {
|
|
543
543
|
title: ze.credit_over_time_title,
|
|
544
544
|
valueKey: "credit_score"
|
|
545
545
|
}
|
|
546
|
-
}[t],
|
|
547
|
-
let
|
|
546
|
+
}[t], h = Tn(o, _.valueKey), y = Math.max(...o.map((M) => M[_.valueKey])), f = () => y >= 1e6 ? { formatter: "0.000a", leftMargin: 55 } : y >= 1e3 ? { formatter: "0a", leftMargin: 35 } : { formatter: "0a", leftMargin: 30 }, { formatter: x, leftMargin: b } = f(), D = _.title, g = t === "creditOverTime";
|
|
547
|
+
let C;
|
|
548
548
|
if (g) {
|
|
549
549
|
const { color: M } = St(
|
|
550
|
-
|
|
550
|
+
s?.credit_score ?? 0,
|
|
551
551
|
n,
|
|
552
|
-
|
|
552
|
+
i.credit_score_status
|
|
553
553
|
);
|
|
554
|
-
|
|
554
|
+
C = M;
|
|
555
555
|
}
|
|
556
|
-
return /* @__PURE__ */ e(K, { ref:
|
|
556
|
+
return /* @__PURE__ */ e(K, { ref: c, sx: { backgroundColor: "background.paper" }, children: h.length >= 1 ? /* @__PURE__ */ a(u, { gap: 8, sx: { pl: 18 }, children: [
|
|
557
557
|
/* @__PURE__ */ e(k, { sx: { pb: 8, pt: 16 }, variant: "h3", children: D }),
|
|
558
558
|
/* @__PURE__ */ e(
|
|
559
559
|
Xe,
|
|
560
560
|
{
|
|
561
|
-
areaColor:
|
|
561
|
+
areaColor: C,
|
|
562
562
|
axisColor: r.palette.divider,
|
|
563
563
|
baseline: "min",
|
|
564
564
|
chartFor: t,
|
|
565
565
|
colors: [r.palette.primary.main],
|
|
566
566
|
curveType: g ? "linear" : "natural",
|
|
567
|
-
datasets:
|
|
567
|
+
datasets: h ? [h] : [],
|
|
568
568
|
height: 244,
|
|
569
569
|
labelFontColor: g ? "text.primary" : "",
|
|
570
570
|
labelFontSize: g ? 13 : void 0,
|
|
571
|
-
labels: [
|
|
572
|
-
margin: { left:
|
|
571
|
+
labels: [i.key_indicators_label],
|
|
572
|
+
margin: { left: b, top: g ? 25 : 15, right: 20 },
|
|
573
573
|
markStyles: (M) => g ? {
|
|
574
574
|
markLabelStyles: {
|
|
575
575
|
marginLeft: 16,
|
|
576
|
-
transform: M ===
|
|
576
|
+
transform: M === h.length - 1 ? "translateX(-16px)" : "translateX(16px)",
|
|
577
577
|
fontWeight: 600
|
|
578
578
|
}
|
|
579
579
|
} : {},
|
|
@@ -587,11 +587,11 @@ const Go = ({ isOpen: t, onClose: r }) => {
|
|
|
587
587
|
showYAxis: g,
|
|
588
588
|
showYAxisTicks: g,
|
|
589
589
|
useCustomMark: !0,
|
|
590
|
-
valueFormatterString: g ? void 0 :
|
|
591
|
-
width:
|
|
590
|
+
valueFormatterString: g ? void 0 : x,
|
|
591
|
+
width: p < 342 ? p - 48 : 342
|
|
592
592
|
}
|
|
593
593
|
)
|
|
594
|
-
] }) : /* @__PURE__ */
|
|
594
|
+
] }) : /* @__PURE__ */ a(u, { gap: 8, sx: { alignItems: "center", p: 24, pb: 48 }, children: [
|
|
595
595
|
l.icon,
|
|
596
596
|
/* @__PURE__ */ e(k, { fontWeight: 600, variant: "body1", children: l.title }),
|
|
597
597
|
/* @__PURE__ */ e(k, { align: "center", variant: "subtitle1", children: l.description })
|
|
@@ -599,8 +599,8 @@ const Go = ({ isOpen: t, onClose: r }) => {
|
|
|
599
599
|
}, Qe = S(Ho), No = {
|
|
600
600
|
updated_score: "Updated Score"
|
|
601
601
|
}, Ko = () => {
|
|
602
|
-
const { healthScoreChange: t } = F(), { user: r } = Q(), { availableWidth: n } = Hn(), { isSmallMobile: o } = Ue(n), [
|
|
603
|
-
return /* @__PURE__ */
|
|
602
|
+
const { healthScoreChange: t } = F(), { user: r } = Q(), { availableWidth: n } = Hn(), { isSmallMobile: o } = Ue(n), [s, i] = m.useState(!1);
|
|
603
|
+
return /* @__PURE__ */ a(u, { sx: { gap: 28 }, children: [
|
|
604
604
|
/* @__PURE__ */ e(
|
|
605
605
|
Eo,
|
|
606
606
|
{
|
|
@@ -610,12 +610,12 @@ const Go = ({ isOpen: t, onClose: r }) => {
|
|
|
610
610
|
size: o ? "M" : "L"
|
|
611
611
|
}
|
|
612
612
|
),
|
|
613
|
-
/* @__PURE__ */ e(
|
|
614
|
-
/* @__PURE__ */ e(Gt, { isOpen:
|
|
613
|
+
/* @__PURE__ */ e(z, { onClick: () => i(!0), variant: "contained", children: No.updated_score }),
|
|
614
|
+
/* @__PURE__ */ e(Gt, { isOpen: s, onClose: () => i(!1) }),
|
|
615
615
|
/* @__PURE__ */ e(Qe, { chartFor: "creditOverTime" })
|
|
616
616
|
] });
|
|
617
617
|
}, jo = S(Ko), Le = ({ status: t }) => {
|
|
618
|
-
const { finstrong: r } =
|
|
618
|
+
const { finstrong: r } = w(), n = On(Rn[t]), o = {
|
|
619
619
|
GOOD: r.key_indicators_good,
|
|
620
620
|
FAIR: r.key_indicators_fair,
|
|
621
621
|
OFF_TRACK: r.key_indicators_off_track,
|
|
@@ -646,7 +646,7 @@ const Go = ({ isOpen: t, onClose: r }) => {
|
|
|
646
646
|
keep_strong_credit_score: "Keep a Strong Credit Score"
|
|
647
647
|
}, Vo = () => {
|
|
648
648
|
const { user: t } = Q(), r = Ct(t.credit_score ?? null);
|
|
649
|
-
return /* @__PURE__ */
|
|
649
|
+
return /* @__PURE__ */ a(u, { sx: { flexDirection: "row", justifyContent: "space-between" }, children: [
|
|
650
650
|
/* @__PURE__ */ e(N, { children: Yo.keep_strong_credit_score }),
|
|
651
651
|
/* @__PURE__ */ e(Le, { status: r })
|
|
652
652
|
] });
|
|
@@ -655,18 +655,18 @@ const Go = ({ isOpen: t, onClose: r }) => {
|
|
|
655
655
|
connectTitle: r,
|
|
656
656
|
connectDescription: n,
|
|
657
657
|
children: o,
|
|
658
|
-
description:
|
|
659
|
-
drawerTitle:
|
|
660
|
-
isOpen:
|
|
661
|
-
loadConnectAccountsCard:
|
|
658
|
+
description: s,
|
|
659
|
+
drawerTitle: i,
|
|
660
|
+
isOpen: c,
|
|
661
|
+
loadConnectAccountsCard: p = !0,
|
|
662
662
|
onClose: l,
|
|
663
|
-
stickyComponent:
|
|
664
|
-
title:
|
|
665
|
-
drawerType:
|
|
663
|
+
stickyComponent: d,
|
|
664
|
+
title: _,
|
|
665
|
+
drawerType: h
|
|
666
666
|
}) => {
|
|
667
|
-
const { finstrong:
|
|
668
|
-
return f ? /* @__PURE__ */
|
|
669
|
-
(
|
|
667
|
+
const { finstrong: y } = w(), { isCopyLoaded: f } = j();
|
|
668
|
+
return f ? /* @__PURE__ */ a(ne, { isOpen: c, onClose: l, title: i || y.key_indicators, children: [
|
|
669
|
+
(_ || s) && /* @__PURE__ */ a(
|
|
670
670
|
u,
|
|
671
671
|
{
|
|
672
672
|
sx: {
|
|
@@ -675,30 +675,30 @@ const Go = ({ isOpen: t, onClose: r }) => {
|
|
|
675
675
|
p: 24
|
|
676
676
|
},
|
|
677
677
|
children: [
|
|
678
|
-
|
|
679
|
-
|
|
678
|
+
_ && typeof _ == "string" ? /* @__PURE__ */ e(N, { children: _ }) : _,
|
|
679
|
+
s && /* @__PURE__ */ e(k, { sx: { lineHeight: "24px" }, children: s })
|
|
680
680
|
]
|
|
681
681
|
}
|
|
682
682
|
),
|
|
683
|
-
|
|
684
|
-
|
|
683
|
+
d && /* @__PURE__ */ e(
|
|
684
|
+
v,
|
|
685
685
|
{
|
|
686
686
|
sx: {
|
|
687
687
|
position: "sticky",
|
|
688
688
|
top: 0,
|
|
689
689
|
zIndex: 1
|
|
690
690
|
},
|
|
691
|
-
children:
|
|
691
|
+
children: d
|
|
692
692
|
}
|
|
693
693
|
),
|
|
694
|
-
t && /* @__PURE__ */ e(
|
|
695
|
-
/* @__PURE__ */
|
|
694
|
+
t && /* @__PURE__ */ e(v, { children: t }),
|
|
695
|
+
/* @__PURE__ */ a(u, { sx: { p: 24, gap: 24 }, children: [
|
|
696
696
|
o,
|
|
697
|
-
|
|
697
|
+
p && /* @__PURE__ */ e(
|
|
698
698
|
Be,
|
|
699
699
|
{
|
|
700
700
|
description: n,
|
|
701
|
-
drawerType:
|
|
701
|
+
drawerType: h,
|
|
702
702
|
isDashboard: !0,
|
|
703
703
|
sx: { backgroundColor: "background.paper" },
|
|
704
704
|
title: r
|
|
@@ -711,122 +711,122 @@ const Go = ({ isOpen: t, onClose: r }) => {
|
|
|
711
711
|
shouldShowBalance: r = !0,
|
|
712
712
|
loadAccounts: n
|
|
713
713
|
}) => {
|
|
714
|
-
const { config: o } = kt(), { accounts:
|
|
714
|
+
const { config: o } = kt(), { accounts: s } = w(), { selectedAccounts: i } = j(), c = m.useCallback(
|
|
715
715
|
(l) => {
|
|
716
716
|
t?.(l);
|
|
717
717
|
},
|
|
718
718
|
[t]
|
|
719
|
-
),
|
|
720
|
-
() => Array.from(new Set(
|
|
719
|
+
), p = m.useMemo(
|
|
720
|
+
() => Array.from(new Set(i.map((l) => l.account_type))).filter(
|
|
721
721
|
(l) => n ? n.includes(l) : !0
|
|
722
722
|
),
|
|
723
|
-
[
|
|
723
|
+
[i, n]
|
|
724
724
|
);
|
|
725
|
-
return
|
|
726
|
-
const { accountsForType:
|
|
727
|
-
(
|
|
725
|
+
return i.length ? /* @__PURE__ */ e(m.Fragment, { children: p.map((l) => {
|
|
726
|
+
const { accountsForType: d, totalBalanceForType: _ } = i.reduce(
|
|
727
|
+
(h, y) => (y.account_type === l && (h.accountsForType.push(y), h.totalBalanceForType += y.balance || 0), h),
|
|
728
728
|
{ accountsForType: [], totalBalanceForType: 0 }
|
|
729
729
|
);
|
|
730
|
-
return /* @__PURE__ */
|
|
730
|
+
return /* @__PURE__ */ a(
|
|
731
731
|
Re,
|
|
732
732
|
{
|
|
733
|
-
subheader: /* @__PURE__ */ e(Qn, { sx: { pb: 4, position: "static", pt: 12, px: 24 }, children: /* @__PURE__ */
|
|
734
|
-
/* @__PURE__ */ e(I, { bold: !0, variant: "caption", children:
|
|
735
|
-
r && /* @__PURE__ */ e(I, { bold: !0, variant: "caption", children: L(
|
|
733
|
+
subheader: /* @__PURE__ */ e(Qn, { sx: { pb: 4, position: "static", pt: 12, px: 24 }, children: /* @__PURE__ */ a(u, { sx: { flexDirection: "row", justifyContent: "space-between" }, children: [
|
|
734
|
+
/* @__PURE__ */ e(I, { bold: !0, variant: "caption", children: s.account_types[l] }),
|
|
735
|
+
r && /* @__PURE__ */ e(I, { bold: !0, variant: "caption", children: L(_, "0,0.00") })
|
|
736
736
|
] }) }),
|
|
737
737
|
sx: { bgcolor: "background.paper" },
|
|
738
738
|
children: [
|
|
739
|
-
|
|
740
|
-
const { firstValue: f } = Tt(
|
|
739
|
+
d.map((h, y) => {
|
|
740
|
+
const { firstValue: f } = Tt(h, s), x = Dt(h, {
|
|
741
741
|
allowNickname: o?.show_account_nicknames_in_master
|
|
742
|
-
}),
|
|
743
|
-
/* @__PURE__ */ e(At, { children: /* @__PURE__ */ e(xt, { alt: "MX", institutionGuid:
|
|
742
|
+
}), b = /* @__PURE__ */ a(E, { children: [
|
|
743
|
+
/* @__PURE__ */ e(At, { children: /* @__PURE__ */ e(xt, { alt: "MX", institutionGuid: h.institution_guid ?? "" }) }),
|
|
744
744
|
/* @__PURE__ */ e(
|
|
745
745
|
be,
|
|
746
746
|
{
|
|
747
|
-
primary: `${
|
|
747
|
+
primary: `${x}${h.account_number ? ` *${h.account_number}` : ""}`,
|
|
748
748
|
primaryTypographyProps: { noWrap: !0, pr: 4, variant: "body1" }
|
|
749
749
|
}
|
|
750
750
|
),
|
|
751
751
|
r && /* @__PURE__ */ e(k, { bold: !0, variant: "body2", children: L(f ?? 0, "0,0.00") })
|
|
752
752
|
] });
|
|
753
|
-
return /* @__PURE__ */
|
|
754
|
-
/* @__PURE__ */ e(ye, { sx: { px: t ? 0 : 24 }, children: t ? /* @__PURE__ */ e(Zn, { onClick: () =>
|
|
755
|
-
|
|
756
|
-
] },
|
|
753
|
+
return /* @__PURE__ */ a(m.Fragment, { children: [
|
|
754
|
+
/* @__PURE__ */ e(ye, { sx: { px: t ? 0 : 24 }, children: t ? /* @__PURE__ */ e(Zn, { onClick: () => c(h), children: b }) : b }),
|
|
755
|
+
y !== d.length - 1 && /* @__PURE__ */ e(oe, { variant: "inset" })
|
|
756
|
+
] }, h.guid);
|
|
757
757
|
}),
|
|
758
|
-
/* @__PURE__ */ e(
|
|
758
|
+
/* @__PURE__ */ e(oe, {})
|
|
759
759
|
]
|
|
760
760
|
},
|
|
761
761
|
l
|
|
762
762
|
);
|
|
763
763
|
}) }) : null;
|
|
764
764
|
}, Nt = S(Uo), Zo = ({ loadAccounts: t, loadMoreLabel: r }) => {
|
|
765
|
-
const n =
|
|
766
|
-
() =>
|
|
767
|
-
(
|
|
765
|
+
const n = G(), { config: o } = kt(), { connect: s, finstrong: i } = w(), { accounts: c } = w(), { selectedAccounts: p } = j(), [l, d] = m.useState(!1), [_, h] = m.useState(!1), y = m.useMemo(
|
|
766
|
+
() => p.filter(
|
|
767
|
+
(b) => t ? t.includes(b.account_type) : !0
|
|
768
768
|
),
|
|
769
|
-
[
|
|
770
|
-
), f = m.useMemo(() =>
|
|
771
|
-
const { firstValue: D } = Tt(
|
|
769
|
+
[p, t]
|
|
770
|
+
), f = m.useMemo(() => y.slice(0, 3), [y]), x = (b) => {
|
|
771
|
+
const { firstValue: D } = Tt(b, c);
|
|
772
772
|
return D;
|
|
773
773
|
};
|
|
774
|
-
return
|
|
775
|
-
/* @__PURE__ */ e(
|
|
776
|
-
/* @__PURE__ */
|
|
777
|
-
/* @__PURE__ */ e(At, { children: /* @__PURE__ */ e(xt, { alt: "MX", institutionGuid:
|
|
774
|
+
return y.length >= 1 ? /* @__PURE__ */ a(E, { children: [
|
|
775
|
+
/* @__PURE__ */ e(v, { sx: { border: `1px solid ${n.palette.divider}`, borderRadius: 2 }, children: f.map((b, D) => /* @__PURE__ */ a(m.Fragment, { children: [
|
|
776
|
+
/* @__PURE__ */ a(ye, { sx: { px: 24 }, children: [
|
|
777
|
+
/* @__PURE__ */ e(At, { children: /* @__PURE__ */ e(xt, { alt: "MX", institutionGuid: b.institution_guid ?? "" }) }),
|
|
778
778
|
/* @__PURE__ */ e(
|
|
779
779
|
be,
|
|
780
780
|
{
|
|
781
|
-
primary: `${Dt(
|
|
781
|
+
primary: `${Dt(b, {
|
|
782
782
|
allowNickname: o?.show_account_nicknames_in_master
|
|
783
783
|
})}
|
|
784
|
-
${
|
|
784
|
+
${b.account_number ? ` *${b.account_number}` : ""}`,
|
|
785
785
|
primaryTypographyProps: { noWrap: !0, pr: 4, variant: "body1" }
|
|
786
786
|
}
|
|
787
787
|
),
|
|
788
|
-
/* @__PURE__ */ e(k, { bold: !0, variant: "body2", children: L(
|
|
788
|
+
/* @__PURE__ */ e(k, { bold: !0, variant: "body2", children: L(x(b), "0,0.00") })
|
|
789
789
|
] }),
|
|
790
|
-
D < f.length - 1 && /* @__PURE__ */ e(
|
|
791
|
-
] },
|
|
792
|
-
|
|
793
|
-
/* @__PURE__ */ e(
|
|
794
|
-
|
|
790
|
+
D < f.length - 1 && /* @__PURE__ */ e(oe, { variant: "inset" })
|
|
791
|
+
] }, b.guid)) }),
|
|
792
|
+
y.length > 3 && /* @__PURE__ */ a(E, { children: [
|
|
793
|
+
/* @__PURE__ */ e(v, { children: /* @__PURE__ */ e(
|
|
794
|
+
z,
|
|
795
795
|
{
|
|
796
796
|
endIcon: /* @__PURE__ */ e(Z, {}),
|
|
797
|
-
onClick: () =>
|
|
797
|
+
onClick: () => d(!0),
|
|
798
798
|
size: "small",
|
|
799
799
|
sx: { my: 0, px: 16, py: 12, width: "100%" },
|
|
800
|
-
children: /* @__PURE__ */
|
|
801
|
-
|
|
800
|
+
children: /* @__PURE__ */ a(I, { bold: !0, variant: "body1", children: [
|
|
801
|
+
y.length - 3,
|
|
802
802
|
" ",
|
|
803
803
|
r
|
|
804
804
|
] })
|
|
805
805
|
}
|
|
806
806
|
) }),
|
|
807
|
-
/* @__PURE__ */ e(
|
|
807
|
+
/* @__PURE__ */ e(ne, { isOpen: l, onClose: () => d(!1), title: i.accounts, children: /* @__PURE__ */ e(Nt, { loadAccounts: t }) })
|
|
808
808
|
] })
|
|
809
|
-
] }) : /* @__PURE__ */
|
|
810
|
-
/* @__PURE__ */ e(
|
|
811
|
-
|
|
809
|
+
] }) : /* @__PURE__ */ a(E, { children: [
|
|
810
|
+
/* @__PURE__ */ e(v, { children: /* @__PURE__ */ e(
|
|
811
|
+
z,
|
|
812
812
|
{
|
|
813
|
-
onClick: () =>
|
|
813
|
+
onClick: () => h(!0),
|
|
814
814
|
size: "small",
|
|
815
815
|
sx: { my: 0, px: 16, py: 12, width: "100%" },
|
|
816
816
|
variant: "contained",
|
|
817
|
-
children: /* @__PURE__ */ e(I, { bold: !0, variant: "body1", children:
|
|
817
|
+
children: /* @__PURE__ */ e(I, { bold: !0, variant: "body1", children: i.connect_more_accounts_button })
|
|
818
818
|
}
|
|
819
819
|
) }),
|
|
820
820
|
/* @__PURE__ */ e(
|
|
821
|
-
|
|
821
|
+
re,
|
|
822
822
|
{
|
|
823
|
-
onClose: () =>
|
|
824
|
-
showConnectWidget:
|
|
825
|
-
title:
|
|
823
|
+
onClose: () => h(!1),
|
|
824
|
+
showConnectWidget: _,
|
|
825
|
+
title: s.mini_title
|
|
826
826
|
}
|
|
827
827
|
)
|
|
828
828
|
] });
|
|
829
|
-
}, Kt = S(Zo), Se = ({ balance: t, title: r, sx: n }) => /* @__PURE__ */
|
|
829
|
+
}, Kt = S(Zo), Se = ({ balance: t, title: r, sx: n }) => /* @__PURE__ */ a(
|
|
830
830
|
u,
|
|
831
831
|
{
|
|
832
832
|
sx: {
|
|
@@ -844,7 +844,7 @@ const Go = ({ isOpen: t, onClose: r }) => {
|
|
|
844
844
|
]
|
|
845
845
|
}
|
|
846
846
|
);
|
|
847
|
-
var
|
|
847
|
+
var T = /* @__PURE__ */ ((t) => (t[t.ConnectAccounts = 1] = "ConnectAccounts", t[t.MonthlyIncome = 2] = "MonthlyIncome", t[t.Birthday = 3] = "Birthday", t[t.CreditScore = 4] = "CreditScore", t))(T || {}), we = /* @__PURE__ */ ((t) => (t[t.Months = 1] = "Months", t[t.Years = 2] = "Years", t[t.Days = 3] = "Days", t))(we || {}), U = /* @__PURE__ */ ((t) => (t[t.Monthly = 1] = "Monthly", t[t.BiWeekly = 2] = "BiWeekly", t[t.Weekly = 3] = "Weekly", t[t.Daily = 4] = "Daily", t))(U || {});
|
|
848
848
|
const B = {
|
|
849
849
|
bi_weekly: "Bi-Weekly",
|
|
850
850
|
calculate: "Calculate",
|
|
@@ -875,44 +875,44 @@ const B = {
|
|
|
875
875
|
[U.Weekly]: B.estimated_period_weekly,
|
|
876
876
|
[U.Daily]: B.estimated_period_daily
|
|
877
877
|
}, er = [
|
|
878
|
-
{ id:
|
|
879
|
-
{ id:
|
|
880
|
-
{ id:
|
|
878
|
+
{ id: we.Months, label: B.months },
|
|
879
|
+
{ id: we.Years, label: B.years },
|
|
880
|
+
{ id: we.Days, label: B.days }
|
|
881
881
|
], tr = ({ total: t }) => {
|
|
882
|
-
const r = Math.ceil((t + 1) / 1e3) * 1e3, [n, o] = m.useState(0), [
|
|
882
|
+
const r = Math.ceil((t + 1) / 1e3) * 1e3, [n, o] = m.useState(0), [s, i] = m.useState(at(t)), [c, p] = m.useState(
|
|
883
883
|
at(t)
|
|
884
|
-
), [l,
|
|
884
|
+
), [l, d] = m.useState(r), [_, h] = m.useState(Fn(t)), [y, f] = m.useState(we.Months);
|
|
885
885
|
m.useEffect(() => {
|
|
886
886
|
o(
|
|
887
887
|
it({
|
|
888
|
-
contribution:
|
|
888
|
+
contribution: c,
|
|
889
889
|
goalAmount: l,
|
|
890
|
-
goalPeriod:
|
|
891
|
-
targetPeriod:
|
|
890
|
+
goalPeriod: _,
|
|
891
|
+
targetPeriod: y,
|
|
892
892
|
totalSaved: t
|
|
893
893
|
})
|
|
894
|
-
),
|
|
894
|
+
), i(c);
|
|
895
895
|
}, []);
|
|
896
|
-
const
|
|
897
|
-
|
|
896
|
+
const x = (b) => {
|
|
897
|
+
b.preventDefault(), o(
|
|
898
898
|
it({
|
|
899
|
-
contribution:
|
|
899
|
+
contribution: c,
|
|
900
900
|
goalAmount: l,
|
|
901
|
-
goalPeriod:
|
|
902
|
-
targetPeriod:
|
|
901
|
+
goalPeriod: _,
|
|
902
|
+
targetPeriod: y,
|
|
903
903
|
totalSaved: t
|
|
904
904
|
})
|
|
905
|
-
),
|
|
905
|
+
), i(c);
|
|
906
906
|
};
|
|
907
|
-
return /* @__PURE__ */ e(K, { children: /* @__PURE__ */ e("form", { onSubmit:
|
|
907
|
+
return /* @__PURE__ */ e(K, { children: /* @__PURE__ */ e("form", { onSubmit: x, children: /* @__PURE__ */ a(u, { sx: { gap: 24, pb: 24, pt: 16, px: 16 }, children: [
|
|
908
908
|
/* @__PURE__ */ e(
|
|
909
909
|
Se,
|
|
910
910
|
{
|
|
911
|
-
balance: /* @__PURE__ */
|
|
911
|
+
balance: /* @__PURE__ */ a(u, { sx: { flexDirection: "row", height: 32 }, children: [
|
|
912
912
|
/* @__PURE__ */ e(I, { variant: "h2", children: L(n, "0,0") }),
|
|
913
|
-
/* @__PURE__ */
|
|
913
|
+
/* @__PURE__ */ a(I, { sx: { alignSelf: "end", height: 24 }, variant: "subtitle2", children: [
|
|
914
914
|
"/",
|
|
915
|
-
Jo[
|
|
915
|
+
Jo[s]
|
|
916
916
|
] })
|
|
917
917
|
] }),
|
|
918
918
|
title: B.estimated_contribution
|
|
@@ -928,8 +928,8 @@ const B = {
|
|
|
928
928
|
pattern: "[0-9]*"
|
|
929
929
|
},
|
|
930
930
|
label: B.savings_goal,
|
|
931
|
-
onChange: (
|
|
932
|
-
|
|
931
|
+
onChange: (b) => {
|
|
932
|
+
b.target.value && d(Number(b.target.value.replace(/[^0-9]/g, "")));
|
|
933
933
|
},
|
|
934
934
|
value: l ? L(l, "0,0") : ""
|
|
935
935
|
}
|
|
@@ -938,13 +938,13 @@ const B = {
|
|
|
938
938
|
ct,
|
|
939
939
|
{
|
|
940
940
|
label: B.how_often_contribute,
|
|
941
|
-
onChange:
|
|
941
|
+
onChange: p,
|
|
942
942
|
options: Qo,
|
|
943
943
|
required: !0,
|
|
944
|
-
value:
|
|
944
|
+
value: c
|
|
945
945
|
}
|
|
946
946
|
),
|
|
947
|
-
/* @__PURE__ */
|
|
947
|
+
/* @__PURE__ */ a(u, { sx: { flexDirection: "row" }, children: [
|
|
948
948
|
/* @__PURE__ */ e(
|
|
949
949
|
Oe,
|
|
950
950
|
{
|
|
@@ -955,7 +955,7 @@ const B = {
|
|
|
955
955
|
pattern: "[0-9]*"
|
|
956
956
|
},
|
|
957
957
|
label: B.meet_your_goal_within,
|
|
958
|
-
onChange: (
|
|
958
|
+
onChange: (b) => h(Number(b.target.value)),
|
|
959
959
|
sx: {
|
|
960
960
|
"& .MuiInputBase-root": {
|
|
961
961
|
borderBottomRightRadius: 0,
|
|
@@ -965,11 +965,11 @@ const B = {
|
|
|
965
965
|
}
|
|
966
966
|
}
|
|
967
967
|
},
|
|
968
|
-
value:
|
|
968
|
+
value: _
|
|
969
969
|
}
|
|
970
970
|
),
|
|
971
971
|
/* @__PURE__ */ e(
|
|
972
|
-
|
|
972
|
+
v,
|
|
973
973
|
{
|
|
974
974
|
sx: {
|
|
975
975
|
"& .MuiInputBase-root": {
|
|
@@ -980,29 +980,29 @@ const B = {
|
|
|
980
980
|
}
|
|
981
981
|
}
|
|
982
982
|
},
|
|
983
|
-
children: /* @__PURE__ */ e(ct, { label: "", onChange: f, options: er, value:
|
|
983
|
+
children: /* @__PURE__ */ e(ct, { label: "", onChange: f, options: er, value: y })
|
|
984
984
|
}
|
|
985
985
|
)
|
|
986
986
|
] }),
|
|
987
|
-
/* @__PURE__ */ e(
|
|
987
|
+
/* @__PURE__ */ e(z, { fullWidth: !0, onClick: x, type: "submit", variant: "contained", children: B.calculate })
|
|
988
988
|
] }) }) });
|
|
989
989
|
}, nr = S(tr), Ae = {
|
|
990
990
|
connect_accounts: "Connect Accounts",
|
|
991
991
|
more_accounts: "More Accounts",
|
|
992
992
|
your_savings: "Your Savings"
|
|
993
993
|
}, or = () => {
|
|
994
|
-
const { savingsAccounts: t } =
|
|
995
|
-
() => t.reduce((
|
|
994
|
+
const { savingsAccounts: t } = ke(), [r, n] = m.useState(!1), o = m.useMemo(
|
|
995
|
+
() => t.reduce((s, i) => s + (i.balance ?? 0), 0),
|
|
996
996
|
[t]
|
|
997
997
|
);
|
|
998
|
-
return /* @__PURE__ */
|
|
999
|
-
/* @__PURE__ */ e(K, { sx: { bgcolor: "background.paper", p: 16 }, children: /* @__PURE__ */
|
|
998
|
+
return /* @__PURE__ */ a(u, { sx: { gap: 24 }, children: [
|
|
999
|
+
/* @__PURE__ */ e(K, { sx: { bgcolor: "background.paper", p: 16 }, children: /* @__PURE__ */ a(u, { sx: { gap: 16 }, children: [
|
|
1000
1000
|
/* @__PURE__ */ e(Se, { balance: o, title: Ae.your_savings }),
|
|
1001
1001
|
t.length ? /* @__PURE__ */ e(Kt, { loadAccounts: [He.SAVINGS], loadMoreLabel: Ae.connect_accounts }) : /* @__PURE__ */ e(eo, { onClick: () => n(!0), variant: "contained", children: Ae.connect_accounts })
|
|
1002
1002
|
] }) }),
|
|
1003
1003
|
/* @__PURE__ */ e(nr, { total: o }),
|
|
1004
1004
|
/* @__PURE__ */ e(
|
|
1005
|
-
|
|
1005
|
+
re,
|
|
1006
1006
|
{
|
|
1007
1007
|
onClose: () => n(!1),
|
|
1008
1008
|
showConnectWidget: r,
|
|
@@ -1011,8 +1011,8 @@ const B = {
|
|
|
1011
1011
|
)
|
|
1012
1012
|
] });
|
|
1013
1013
|
}, rr = S(or), $e = S(
|
|
1014
|
-
({ label: t, value: r, status: n, bottomComponent: o, statusBarData:
|
|
1015
|
-
const
|
|
1014
|
+
({ label: t, value: r, status: n, bottomComponent: o, statusBarData: s = [] }) => {
|
|
1015
|
+
const i = {
|
|
1016
1016
|
GOOD: {
|
|
1017
1017
|
progressBarColor: "primary.main"
|
|
1018
1018
|
},
|
|
@@ -1025,14 +1025,14 @@ const B = {
|
|
|
1025
1025
|
MISSING: {
|
|
1026
1026
|
progressBarColor: "text.secondary"
|
|
1027
1027
|
}
|
|
1028
|
-
}[n],
|
|
1029
|
-
color: l === 0 ? "primary.main" :
|
|
1030
|
-
percentage:
|
|
1028
|
+
}[n], c = s.map((p, l) => s.length === 2 ? {
|
|
1029
|
+
color: l === 0 ? "primary.main" : p.color || i?.progressBarColor,
|
|
1030
|
+
percentage: p.percentage
|
|
1031
1031
|
} : {
|
|
1032
|
-
color:
|
|
1033
|
-
percentage:
|
|
1032
|
+
color: p.color || i?.progressBarColor,
|
|
1033
|
+
percentage: p.percentage
|
|
1034
1034
|
});
|
|
1035
|
-
return /* @__PURE__ */
|
|
1035
|
+
return /* @__PURE__ */ a(
|
|
1036
1036
|
u,
|
|
1037
1037
|
{
|
|
1038
1038
|
sx: {
|
|
@@ -1044,9 +1044,9 @@ const B = {
|
|
|
1044
1044
|
borderColor: "divider"
|
|
1045
1045
|
},
|
|
1046
1046
|
children: [
|
|
1047
|
-
/* @__PURE__ */
|
|
1047
|
+
/* @__PURE__ */ a(u, { sx: { gap: 2 }, children: [
|
|
1048
1048
|
/* @__PURE__ */ e(I, { variant: "body2", children: t }),
|
|
1049
|
-
/* @__PURE__ */
|
|
1049
|
+
/* @__PURE__ */ a(
|
|
1050
1050
|
u,
|
|
1051
1051
|
{
|
|
1052
1052
|
sx: {
|
|
@@ -1062,8 +1062,8 @@ const B = {
|
|
|
1062
1062
|
}
|
|
1063
1063
|
)
|
|
1064
1064
|
] }),
|
|
1065
|
-
/* @__PURE__ */
|
|
1066
|
-
/* @__PURE__ */ e(to, { data:
|
|
1065
|
+
/* @__PURE__ */ a(u, { children: [
|
|
1066
|
+
/* @__PURE__ */ e(to, { data: c, height: 16 }),
|
|
1067
1067
|
o
|
|
1068
1068
|
] })
|
|
1069
1069
|
]
|
|
@@ -1077,9 +1077,9 @@ const B = {
|
|
|
1077
1077
|
return /* @__PURE__ */ e(
|
|
1078
1078
|
$e,
|
|
1079
1079
|
{
|
|
1080
|
-
bottomComponent: /* @__PURE__ */ e(u, { sx: { flexDirection: "row", justifyContent: "space-between" }, children: ir.map((
|
|
1080
|
+
bottomComponent: /* @__PURE__ */ e(u, { sx: { flexDirection: "row", justifyContent: "space-between" }, children: ir.map((s) => /* @__PURE__ */ a(u, { sx: { alignItems: "center", height: 24, width: 30 }, children: [
|
|
1081
1081
|
/* @__PURE__ */ e(
|
|
1082
|
-
|
|
1082
|
+
oe,
|
|
1083
1083
|
{
|
|
1084
1084
|
orientation: "vertical",
|
|
1085
1085
|
sx: {
|
|
@@ -1089,8 +1089,8 @@ const B = {
|
|
|
1089
1089
|
}
|
|
1090
1090
|
}
|
|
1091
1091
|
),
|
|
1092
|
-
/* @__PURE__ */ e(I, { variant: "caption", children:
|
|
1093
|
-
] },
|
|
1092
|
+
/* @__PURE__ */ e(I, { variant: "caption", children: s })
|
|
1093
|
+
] }, s)) }),
|
|
1094
1094
|
label: ar.sticky_label,
|
|
1095
1095
|
status: o,
|
|
1096
1096
|
statusBarData: [
|
|
@@ -1106,30 +1106,30 @@ const B = {
|
|
|
1106
1106
|
bgcolor: r,
|
|
1107
1107
|
height: n = "calc(100dvh - 36px)",
|
|
1108
1108
|
loader: o = /* @__PURE__ */ e(J, { label: "Loading", size: 40 }),
|
|
1109
|
-
onClick:
|
|
1110
|
-
showInsights:
|
|
1111
|
-
showLoader:
|
|
1112
|
-
width:
|
|
1109
|
+
onClick: s,
|
|
1110
|
+
showInsights: i = !1,
|
|
1111
|
+
showLoader: c = !1,
|
|
1112
|
+
width: p = "100%",
|
|
1113
1113
|
zeroState: l = /* @__PURE__ */ e(ro, {})
|
|
1114
1114
|
}) => {
|
|
1115
|
-
const { getCategoryName:
|
|
1116
|
-
const M = t.find(($) => $.guid ===
|
|
1115
|
+
const { getCategoryName: d } = Ye(), { onEvent: _ } = Nn(), { categories: h } = w(), { clearExpandedSplits: y, setShowInsights: f, toggleSplit: x } = oo(), b = (C) => {
|
|
1116
|
+
const M = t.find(($) => $.guid === C);
|
|
1117
1117
|
if (M?.has_been_split) {
|
|
1118
|
-
|
|
1118
|
+
x(M.guid);
|
|
1119
1119
|
return;
|
|
1120
1120
|
}
|
|
1121
|
-
|
|
1121
|
+
_(ao.ACCOUNT_DETAILS_CLICK_TRANSACTION, {
|
|
1122
1122
|
account_guid: M?.account_guid,
|
|
1123
|
-
transaction_guid:
|
|
1124
|
-
}),
|
|
1123
|
+
transaction_guid: C
|
|
1124
|
+
}), s?.(C);
|
|
1125
1125
|
}, D = m.useRef(null), g = no({
|
|
1126
1126
|
count: t.length,
|
|
1127
1127
|
getScrollElement: () => D.current,
|
|
1128
|
-
estimateSize: (
|
|
1128
|
+
estimateSize: (C) => ut + (Ne(C, t) ? _t : 0),
|
|
1129
1129
|
overscan: 5
|
|
1130
1130
|
});
|
|
1131
|
-
return m.useEffect(() => g.measure(), [t]), m.useEffect(() => f(
|
|
1132
|
-
|
|
1131
|
+
return m.useEffect(() => g.measure(), [t]), m.useEffect(() => f(i), [i]), m.useEffect(() => () => y(), []), /* @__PURE__ */ e(Re, { sx: { width: p }, children: /* @__PURE__ */ e(v, { height: n, overflow: "auto", ref: D, width: p, children: /* @__PURE__ */ a(
|
|
1132
|
+
v,
|
|
1133
1133
|
{
|
|
1134
1134
|
height: (
|
|
1135
1135
|
// set the height to auto when there are no transactions so the zero state isn't set to 0
|
|
@@ -1138,17 +1138,17 @@ const B = {
|
|
|
1138
1138
|
position: "relative",
|
|
1139
1139
|
width: "100%",
|
|
1140
1140
|
children: [
|
|
1141
|
-
|
|
1142
|
-
!
|
|
1143
|
-
!
|
|
1144
|
-
const M = t[
|
|
1145
|
-
return /* @__PURE__ */
|
|
1146
|
-
|
|
1141
|
+
c && o,
|
|
1142
|
+
!c && g.getVirtualItems().length === 0 && l,
|
|
1143
|
+
!c && g.getVirtualItems().length > 0 && g.getVirtualItems().map((C) => {
|
|
1144
|
+
const M = t[C.index], $ = Ne(C.index, t), H = Ft(C.index, t), O = ut + ($ ? _t : 0);
|
|
1145
|
+
return /* @__PURE__ */ a(
|
|
1146
|
+
v,
|
|
1147
1147
|
{
|
|
1148
1148
|
sx: {
|
|
1149
|
-
height:
|
|
1149
|
+
height: O,
|
|
1150
1150
|
position: "absolute",
|
|
1151
|
-
transform: `translateY(${
|
|
1151
|
+
transform: `translateY(${C.start}px)`,
|
|
1152
1152
|
width: "100%"
|
|
1153
1153
|
},
|
|
1154
1154
|
children: [
|
|
@@ -1156,17 +1156,17 @@ const B = {
|
|
|
1156
1156
|
/* @__PURE__ */ e(
|
|
1157
1157
|
Bt,
|
|
1158
1158
|
{
|
|
1159
|
-
...
|
|
1159
|
+
...s && { onClick: b },
|
|
1160
1160
|
transaction: {
|
|
1161
1161
|
...M,
|
|
1162
|
-
category:
|
|
1162
|
+
category: h.default_categories[M.top_level_category_guid]?.replace(
|
|
1163
1163
|
/&/g,
|
|
1164
1164
|
"&"
|
|
1165
|
-
) ??
|
|
1165
|
+
) ?? d(M.top_level_category_guid)
|
|
1166
1166
|
}
|
|
1167
1167
|
}
|
|
1168
1168
|
),
|
|
1169
|
-
/* @__PURE__ */ e(
|
|
1169
|
+
/* @__PURE__ */ e(oe, { sx: { ml: H ? 24 : 0 } })
|
|
1170
1170
|
]
|
|
1171
1171
|
},
|
|
1172
1172
|
M.guid
|
|
@@ -1180,30 +1180,30 @@ const B = {
|
|
|
1180
1180
|
amountColor: r = "success.main",
|
|
1181
1181
|
amountPosition: n = "center",
|
|
1182
1182
|
formatDate: o = Ze,
|
|
1183
|
-
secondaryIcon:
|
|
1183
|
+
secondaryIcon: s
|
|
1184
1184
|
}) => {
|
|
1185
|
-
const
|
|
1186
|
-
return !t || t.length === 0 ? /* @__PURE__ */
|
|
1187
|
-
/* @__PURE__ */ e(
|
|
1188
|
-
|
|
1185
|
+
const i = G(), { connect: c, finstrong: p } = w(), [l, d] = m.useState(!1), [_, h] = m.useState(!1), y = 3, f = t.length > y, x = t.length - y;
|
|
1186
|
+
return !t || t.length === 0 ? /* @__PURE__ */ a(E, { children: [
|
|
1187
|
+
/* @__PURE__ */ e(v, { children: /* @__PURE__ */ e(
|
|
1188
|
+
z,
|
|
1189
1189
|
{
|
|
1190
|
-
onClick: () =>
|
|
1190
|
+
onClick: () => h(!0),
|
|
1191
1191
|
size: "small",
|
|
1192
1192
|
sx: { my: 0, px: 16, py: 12, width: "100%" },
|
|
1193
1193
|
variant: "contained",
|
|
1194
|
-
children: /* @__PURE__ */ e(I, { bold: !0, variant: "body1", children:
|
|
1194
|
+
children: /* @__PURE__ */ e(I, { bold: !0, variant: "body1", children: p.connect_more_accounts_button })
|
|
1195
1195
|
}
|
|
1196
1196
|
) }),
|
|
1197
1197
|
/* @__PURE__ */ e(
|
|
1198
|
-
|
|
1198
|
+
re,
|
|
1199
1199
|
{
|
|
1200
|
-
onClose: () =>
|
|
1201
|
-
showConnectWidget:
|
|
1202
|
-
title:
|
|
1200
|
+
onClose: () => h(!1),
|
|
1201
|
+
showConnectWidget: _,
|
|
1202
|
+
title: c.mini_title
|
|
1203
1203
|
}
|
|
1204
1204
|
)
|
|
1205
|
-
] }) : /* @__PURE__ */
|
|
1206
|
-
/* @__PURE__ */ e(
|
|
1205
|
+
] }) : /* @__PURE__ */ a(u, { sx: { gap: 16 }, children: [
|
|
1206
|
+
/* @__PURE__ */ e(v, { sx: { border: `1px solid ${i.palette.divider}`, borderRadius: 2 }, children: t.slice(0, y).map((b, D) => /* @__PURE__ */ a(
|
|
1207
1207
|
u,
|
|
1208
1208
|
{
|
|
1209
1209
|
sx: {
|
|
@@ -1217,12 +1217,12 @@ const B = {
|
|
|
1217
1217
|
/* @__PURE__ */ e(u, { sx: { pb: 14 }, children: /* @__PURE__ */ e(
|
|
1218
1218
|
kn,
|
|
1219
1219
|
{
|
|
1220
|
-
categoryGuid:
|
|
1221
|
-
merchantGuid:
|
|
1220
|
+
categoryGuid: b.top_level_category_guid || "",
|
|
1221
|
+
merchantGuid: b.merchant_guid || "",
|
|
1222
1222
|
size: 32
|
|
1223
1223
|
}
|
|
1224
1224
|
) }),
|
|
1225
|
-
/* @__PURE__ */
|
|
1225
|
+
/* @__PURE__ */ a(
|
|
1226
1226
|
u,
|
|
1227
1227
|
{
|
|
1228
1228
|
sx: {
|
|
@@ -1230,51 +1230,51 @@ const B = {
|
|
|
1230
1230
|
flexDirection: "row",
|
|
1231
1231
|
gap: 12,
|
|
1232
1232
|
justifyContent: "space-between",
|
|
1233
|
-
...D < Math.min(t.length,
|
|
1234
|
-
borderBottom: `1px solid ${
|
|
1233
|
+
...D < Math.min(t.length, y) - 1 && {
|
|
1234
|
+
borderBottom: `1px solid ${i.palette.divider}`
|
|
1235
1235
|
},
|
|
1236
1236
|
pb: 14,
|
|
1237
1237
|
pr: 24,
|
|
1238
1238
|
width: "100%"
|
|
1239
1239
|
},
|
|
1240
1240
|
children: [
|
|
1241
|
-
/* @__PURE__ */
|
|
1242
|
-
/* @__PURE__ */ e(k, { bold: !0, variant: "body1", children:
|
|
1243
|
-
/* @__PURE__ */
|
|
1244
|
-
!!
|
|
1245
|
-
/* @__PURE__ */ e(I, { variant: "caption", children: o(
|
|
1241
|
+
/* @__PURE__ */ a(u, { sx: { gap: 4 }, children: [
|
|
1242
|
+
/* @__PURE__ */ e(k, { bold: !0, variant: "body1", children: b.description }),
|
|
1243
|
+
/* @__PURE__ */ a(u, { sx: { flexDirection: "row", alignItems: "center", gap: 4 }, children: [
|
|
1244
|
+
!!s && s,
|
|
1245
|
+
/* @__PURE__ */ e(I, { variant: "caption", children: o(b.date) })
|
|
1246
1246
|
] })
|
|
1247
1247
|
] }),
|
|
1248
|
-
/* @__PURE__ */ e(k, { bold: !0, sx: { color: r, flexShrink: 0 }, variant: "body1", children: L(
|
|
1248
|
+
/* @__PURE__ */ e(k, { bold: !0, sx: { color: r, flexShrink: 0 }, variant: "body1", children: L(b.amount, "0,0.00") })
|
|
1249
1249
|
]
|
|
1250
1250
|
},
|
|
1251
|
-
|
|
1251
|
+
b.guid || D
|
|
1252
1252
|
)
|
|
1253
1253
|
]
|
|
1254
1254
|
},
|
|
1255
1255
|
D
|
|
1256
1256
|
)) }),
|
|
1257
|
-
f && /* @__PURE__ */
|
|
1258
|
-
/* @__PURE__ */ e(
|
|
1259
|
-
|
|
1257
|
+
f && /* @__PURE__ */ a(E, { children: [
|
|
1258
|
+
/* @__PURE__ */ e(v, { children: /* @__PURE__ */ e(
|
|
1259
|
+
z,
|
|
1260
1260
|
{
|
|
1261
1261
|
endIcon: /* @__PURE__ */ e(Z, {}),
|
|
1262
|
-
onClick: () =>
|
|
1262
|
+
onClick: () => d(!0),
|
|
1263
1263
|
size: "small",
|
|
1264
1264
|
sx: { my: 0, px: 16, py: 12, width: "100%" },
|
|
1265
|
-
children: /* @__PURE__ */
|
|
1266
|
-
|
|
1265
|
+
children: /* @__PURE__ */ a(I, { bold: !0, variant: "body1", children: [
|
|
1266
|
+
x,
|
|
1267
1267
|
" ",
|
|
1268
|
-
|
|
1268
|
+
p.key_indicators_borrow.have_manageable_debt_drawer.have_manageable_debt_more_transactions
|
|
1269
1269
|
] })
|
|
1270
1270
|
}
|
|
1271
1271
|
) }),
|
|
1272
1272
|
/* @__PURE__ */ e(
|
|
1273
|
-
|
|
1273
|
+
ne,
|
|
1274
1274
|
{
|
|
1275
1275
|
isOpen: l,
|
|
1276
|
-
onClose: () =>
|
|
1277
|
-
title:
|
|
1276
|
+
onClose: () => d(!1),
|
|
1277
|
+
title: p.key_indicators_borrow.have_manageable_debt_drawer.have_manageable_debt_transactions,
|
|
1278
1278
|
children: /* @__PURE__ */ e(dr, { transactions: t })
|
|
1279
1279
|
}
|
|
1280
1280
|
)
|
|
@@ -1285,10 +1285,10 @@ const B = {
|
|
|
1285
1285
|
finstrong: {
|
|
1286
1286
|
key_indicators_spend: { pay_bills_on_time_drawer: t }
|
|
1287
1287
|
}
|
|
1288
|
-
} =
|
|
1288
|
+
} = w(), { getSpendingFeeTransactions: r, allTransactions: n } = F();
|
|
1289
1289
|
return m.useEffect(() => {
|
|
1290
1290
|
r().finally();
|
|
1291
|
-
}, []), /* @__PURE__ */ e(
|
|
1291
|
+
}, []), /* @__PURE__ */ e(E, { children: n.spendingFee.length === 0 ? /* @__PURE__ */ a(
|
|
1292
1292
|
K,
|
|
1293
1293
|
{
|
|
1294
1294
|
sx: {
|
|
@@ -1301,13 +1301,13 @@ const B = {
|
|
|
1301
1301
|
},
|
|
1302
1302
|
children: [
|
|
1303
1303
|
/* @__PURE__ */ e(yn, { filled: !0, size: 48, sx: { color: "success.main" } }),
|
|
1304
|
-
/* @__PURE__ */
|
|
1304
|
+
/* @__PURE__ */ a(u, { sx: { alignItems: "center", gap: 4, pt: 24 }, children: [
|
|
1305
1305
|
/* @__PURE__ */ e(N, { children: t.pay_bills_on_time_zero_fees_title }),
|
|
1306
1306
|
/* @__PURE__ */ e(k, { variant: "subtitle1", children: t.pay_bills_on_time_zero_fees_description })
|
|
1307
1307
|
] })
|
|
1308
1308
|
]
|
|
1309
1309
|
}
|
|
1310
|
-
) : /* @__PURE__ */
|
|
1310
|
+
) : /* @__PURE__ */ a(
|
|
1311
1311
|
K,
|
|
1312
1312
|
{
|
|
1313
1313
|
sx: {
|
|
@@ -1331,8 +1331,8 @@ const B = {
|
|
|
1331
1331
|
}
|
|
1332
1332
|
) });
|
|
1333
1333
|
}, ur = S(pr), _r = () => {
|
|
1334
|
-
const { healthScore: t } = F(), { finstrong: r } =
|
|
1335
|
-
return /* @__PURE__ */
|
|
1334
|
+
const { healthScore: t } = F(), { finstrong: r } = w(), { key_indicators_spend: n } = r, { pay_bills_on_time_drawer: o } = n, s = Bn(t.spending_fee_transaction_count);
|
|
1335
|
+
return /* @__PURE__ */ a(
|
|
1336
1336
|
u,
|
|
1337
1337
|
{
|
|
1338
1338
|
sx: {
|
|
@@ -1343,20 +1343,20 @@ const B = {
|
|
|
1343
1343
|
},
|
|
1344
1344
|
children: [
|
|
1345
1345
|
/* @__PURE__ */ e(k, { variant: "body2", children: o.pay_bills_on_time_sticky_description }),
|
|
1346
|
-
/* @__PURE__ */
|
|
1347
|
-
/* @__PURE__ */
|
|
1346
|
+
/* @__PURE__ */ a(u, { direction: "row", sx: { alignItems: "center", justifyContent: "space-between" }, children: [
|
|
1347
|
+
/* @__PURE__ */ a(Pe, { children: [
|
|
1348
1348
|
t.spending_fee_transaction_count,
|
|
1349
1349
|
" ",
|
|
1350
1350
|
o.pay_bills_on_time_sticky_fee_count
|
|
1351
1351
|
] }),
|
|
1352
|
-
/* @__PURE__ */ e(Le, { status:
|
|
1352
|
+
/* @__PURE__ */ e(Le, { status: s })
|
|
1353
1353
|
] })
|
|
1354
1354
|
]
|
|
1355
1355
|
}
|
|
1356
1356
|
);
|
|
1357
1357
|
}, hr = S(_r), mr = () => {
|
|
1358
|
-
const { savingsAndCheckingAccountsBalance: t } =
|
|
1359
|
-
return /* @__PURE__ */
|
|
1358
|
+
const { savingsAndCheckingAccountsBalance: t } = ke(), { finstrong: r } = w();
|
|
1359
|
+
return /* @__PURE__ */ a(u, { gap: 16, sx: { p: 16 }, children: [
|
|
1360
1360
|
/* @__PURE__ */ e(
|
|
1361
1361
|
Se,
|
|
1362
1362
|
{
|
|
@@ -1373,15 +1373,15 @@ const B = {
|
|
|
1373
1373
|
)
|
|
1374
1374
|
] });
|
|
1375
1375
|
}, gr = S(mr), yr = () => {
|
|
1376
|
-
const { finstrong: t } =
|
|
1376
|
+
const { finstrong: t } = w(), { healthScore: r, allTransactions: n, loadSpendTransactions: o, loadDebtSpend: s } = F(), { isInitialized: i } = j();
|
|
1377
1377
|
m.useEffect(() => {
|
|
1378
|
-
|
|
1379
|
-
}, [
|
|
1380
|
-
const
|
|
1381
|
-
const
|
|
1382
|
-
return [...
|
|
1378
|
+
i && (o().finally(), s().finally());
|
|
1379
|
+
}, [i]);
|
|
1380
|
+
const c = m.useMemo(() => {
|
|
1381
|
+
const p = n.spend.map((d) => d.transaction), l = n.debtSpend.map((d) => d.transaction);
|
|
1382
|
+
return [...p, ...l];
|
|
1383
1383
|
}, [n.spend, n.debtSpend]);
|
|
1384
|
-
return
|
|
1384
|
+
return i ? /* @__PURE__ */ a(u, { gap: 16, sx: { p: 16 }, children: [
|
|
1385
1385
|
/* @__PURE__ */ e(
|
|
1386
1386
|
Se,
|
|
1387
1387
|
{
|
|
@@ -1389,24 +1389,24 @@ const B = {
|
|
|
1389
1389
|
title: t.key_indicators_save.drawer_daily_spend
|
|
1390
1390
|
}
|
|
1391
1391
|
),
|
|
1392
|
-
/* @__PURE__ */ e(We, { amountColor: "text.primary", transactions:
|
|
1392
|
+
/* @__PURE__ */ e(We, { amountColor: "text.primary", transactions: c })
|
|
1393
1393
|
] }) : /* @__PURE__ */ e(J, {});
|
|
1394
1394
|
}, br = S(yr), fr = () => {
|
|
1395
|
-
const [t, r] = m.useState(0), { finstrong: n } =
|
|
1396
|
-
return /* @__PURE__ */
|
|
1397
|
-
/* @__PURE__ */
|
|
1398
|
-
/* @__PURE__ */
|
|
1395
|
+
const [t, r] = m.useState(0), { finstrong: n } = w();
|
|
1396
|
+
return /* @__PURE__ */ a(E, { children: [
|
|
1397
|
+
/* @__PURE__ */ a(K, { children: [
|
|
1398
|
+
/* @__PURE__ */ a(
|
|
1399
1399
|
qe,
|
|
1400
1400
|
{
|
|
1401
1401
|
"aria-label": n.key_indicators_save.drawer_title,
|
|
1402
1402
|
centered: !0,
|
|
1403
|
-
onChange: (o,
|
|
1403
|
+
onChange: (o, s) => r(s),
|
|
1404
1404
|
sx: { mb: 0 },
|
|
1405
1405
|
value: t,
|
|
1406
1406
|
variant: "fullWidth",
|
|
1407
1407
|
children: [
|
|
1408
1408
|
/* @__PURE__ */ e(
|
|
1409
|
-
|
|
1409
|
+
ce,
|
|
1410
1410
|
{
|
|
1411
1411
|
"aria-controls": "available-details-tabpanel-0",
|
|
1412
1412
|
label: n.key_indicators_save.drawer_available,
|
|
@@ -1414,7 +1414,7 @@ const B = {
|
|
|
1414
1414
|
}
|
|
1415
1415
|
),
|
|
1416
1416
|
/* @__PURE__ */ e(
|
|
1417
|
-
|
|
1417
|
+
ce,
|
|
1418
1418
|
{
|
|
1419
1419
|
"aria-controls": "spending-details-tabpanel-1",
|
|
1420
1420
|
label: n.key_indicators_save.drawer_spending,
|
|
@@ -1424,13 +1424,13 @@ const B = {
|
|
|
1424
1424
|
]
|
|
1425
1425
|
}
|
|
1426
1426
|
),
|
|
1427
|
-
/* @__PURE__ */ e(
|
|
1428
|
-
/* @__PURE__ */ e(
|
|
1427
|
+
/* @__PURE__ */ e(le, { index: 0, name: "available-details", value: t, children: /* @__PURE__ */ e(gr, {}) }),
|
|
1428
|
+
/* @__PURE__ */ e(le, { index: 1, name: "spending-details", value: t, children: /* @__PURE__ */ e(br, {}) })
|
|
1429
1429
|
] }),
|
|
1430
1430
|
/* @__PURE__ */ e(Qe, { chartFor: "savingsOverTime" })
|
|
1431
1431
|
] });
|
|
1432
1432
|
}, xr = S(fr), Sr = () => {
|
|
1433
|
-
const { finstrong: t } =
|
|
1433
|
+
const { finstrong: t } = w(), { healthScore: r } = F(), n = r.months_of_cash_on_hand, o = wt(n ? n * 30 : null), s = 183 / 6, i = Math.floor(n), c = Math.round((n - i) * s), p = n / 6 * 100;
|
|
1434
1434
|
return /* @__PURE__ */ e(
|
|
1435
1435
|
$e,
|
|
1436
1436
|
{
|
|
@@ -1444,7 +1444,7 @@ const B = {
|
|
|
1444
1444
|
mt: 2,
|
|
1445
1445
|
px: 1
|
|
1446
1446
|
},
|
|
1447
|
-
children: ["0 Mo", "1 Mo", "2 Mo", "3 Mo", "4 Mo", "5 Mo", "6 Mo"].map((
|
|
1447
|
+
children: ["0 Mo", "1 Mo", "2 Mo", "3 Mo", "4 Mo", "5 Mo", "6 Mo"].map((d) => /* @__PURE__ */ a(
|
|
1448
1448
|
u,
|
|
1449
1449
|
{
|
|
1450
1450
|
sx: {
|
|
@@ -1453,7 +1453,7 @@ const B = {
|
|
|
1453
1453
|
},
|
|
1454
1454
|
children: [
|
|
1455
1455
|
/* @__PURE__ */ e(
|
|
1456
|
-
|
|
1456
|
+
oe,
|
|
1457
1457
|
{
|
|
1458
1458
|
orientation: "vertical",
|
|
1459
1459
|
sx: {
|
|
@@ -1462,10 +1462,10 @@ const B = {
|
|
|
1462
1462
|
}
|
|
1463
1463
|
}
|
|
1464
1464
|
),
|
|
1465
|
-
/* @__PURE__ */ e(I, { variant: "XSmall", children:
|
|
1465
|
+
/* @__PURE__ */ e(I, { variant: "XSmall", children: d })
|
|
1466
1466
|
]
|
|
1467
1467
|
},
|
|
1468
|
-
|
|
1468
|
+
d
|
|
1469
1469
|
))
|
|
1470
1470
|
}
|
|
1471
1471
|
),
|
|
@@ -1473,18 +1473,18 @@ const B = {
|
|
|
1473
1473
|
status: o,
|
|
1474
1474
|
statusBarData: [
|
|
1475
1475
|
{
|
|
1476
|
-
percentage: `${
|
|
1476
|
+
percentage: `${p}%`
|
|
1477
1477
|
}
|
|
1478
1478
|
],
|
|
1479
|
-
value: Y(t.key_indicators_save.drawer_progress_bar_value,
|
|
1479
|
+
value: Y(t.key_indicators_save.drawer_progress_bar_value, i, c)
|
|
1480
1480
|
}
|
|
1481
1481
|
);
|
|
1482
1482
|
}, Cr = S(Sr), vr = () => {
|
|
1483
|
-
const { healthScore: t } = F(), { finstrong: r } =
|
|
1483
|
+
const { healthScore: t } = F(), { finstrong: r } = w(), n = Te(t.debt_to_income_ratio) ?? 0, o = Object.keys(t).length === 0, i = ((c) => o ? "MISSING" : c <= 30 ? "GOOD" : c >= 31 && c <= 39 ? "FAIR" : c >= 40 ? "OFF_TRACK" : "MISSING")(n);
|
|
1484
1484
|
return /* @__PURE__ */ e(
|
|
1485
1485
|
$e,
|
|
1486
1486
|
{
|
|
1487
|
-
bottomComponent: /* @__PURE__ */
|
|
1487
|
+
bottomComponent: /* @__PURE__ */ a(
|
|
1488
1488
|
u,
|
|
1489
1489
|
{
|
|
1490
1490
|
sx: {
|
|
@@ -1497,14 +1497,14 @@ const B = {
|
|
|
1497
1497
|
},
|
|
1498
1498
|
children: [
|
|
1499
1499
|
/* @__PURE__ */ e(
|
|
1500
|
-
|
|
1500
|
+
v,
|
|
1501
1501
|
{
|
|
1502
1502
|
sx: {
|
|
1503
1503
|
left: "30%",
|
|
1504
1504
|
position: "absolute",
|
|
1505
1505
|
transform: "translateX(-50%)"
|
|
1506
1506
|
},
|
|
1507
|
-
children: /* @__PURE__ */
|
|
1507
|
+
children: /* @__PURE__ */ a(
|
|
1508
1508
|
u,
|
|
1509
1509
|
{
|
|
1510
1510
|
sx: {
|
|
@@ -1515,7 +1515,7 @@ const B = {
|
|
|
1515
1515
|
},
|
|
1516
1516
|
children: [
|
|
1517
1517
|
/* @__PURE__ */ e(
|
|
1518
|
-
|
|
1518
|
+
oe,
|
|
1519
1519
|
{
|
|
1520
1520
|
orientation: "vertical",
|
|
1521
1521
|
sx: {
|
|
@@ -1531,7 +1531,7 @@ const B = {
|
|
|
1531
1531
|
}
|
|
1532
1532
|
),
|
|
1533
1533
|
/* @__PURE__ */ e(
|
|
1534
|
-
|
|
1534
|
+
v,
|
|
1535
1535
|
{
|
|
1536
1536
|
sx: {
|
|
1537
1537
|
display: "flex",
|
|
@@ -1550,7 +1550,7 @@ const B = {
|
|
|
1550
1550
|
}
|
|
1551
1551
|
),
|
|
1552
1552
|
label: r.key_indicators_borrow.have_manageable_debt_drawer.have_manageable_debt_sticky_title,
|
|
1553
|
-
status:
|
|
1553
|
+
status: i,
|
|
1554
1554
|
statusBarData: [
|
|
1555
1555
|
{
|
|
1556
1556
|
percentage: `${n}%`
|
|
@@ -1560,8 +1560,8 @@ const B = {
|
|
|
1560
1560
|
}
|
|
1561
1561
|
);
|
|
1562
1562
|
}, wr = S(vr), kr = () => {
|
|
1563
|
-
const { healthScore: t, allTransactions: r } = F(), { connect: n, finstrong: o } =
|
|
1564
|
-
return /* @__PURE__ */
|
|
1563
|
+
const { healthScore: t, allTransactions: r } = F(), { connect: n, finstrong: o } = w(), [s, i] = m.useState(!1);
|
|
1564
|
+
return /* @__PURE__ */ a(u, { gap: 16, sx: { p: 16 }, children: [
|
|
1565
1565
|
/* @__PURE__ */ e(
|
|
1566
1566
|
Se,
|
|
1567
1567
|
{
|
|
@@ -1572,29 +1572,29 @@ const B = {
|
|
|
1572
1572
|
),
|
|
1573
1573
|
r.income.length ? (
|
|
1574
1574
|
// TODO: Need to add More Transactions functionality
|
|
1575
|
-
/* @__PURE__ */ e(We, { transactions: r.income.map((
|
|
1575
|
+
/* @__PURE__ */ e(We, { transactions: r.income.map((c) => c.transaction) })
|
|
1576
1576
|
) : /* @__PURE__ */ e(
|
|
1577
|
-
|
|
1577
|
+
z,
|
|
1578
1578
|
{
|
|
1579
1579
|
onClick: () => {
|
|
1580
|
-
|
|
1580
|
+
i(!0);
|
|
1581
1581
|
},
|
|
1582
1582
|
variant: "contained",
|
|
1583
1583
|
children: o.connect_more_accounts_button
|
|
1584
1584
|
}
|
|
1585
1585
|
),
|
|
1586
1586
|
/* @__PURE__ */ e(
|
|
1587
|
-
|
|
1587
|
+
re,
|
|
1588
1588
|
{
|
|
1589
|
-
onClose: () =>
|
|
1590
|
-
showConnectWidget:
|
|
1589
|
+
onClose: () => i(!1),
|
|
1590
|
+
showConnectWidget: s,
|
|
1591
1591
|
title: n.mini_title
|
|
1592
1592
|
}
|
|
1593
1593
|
)
|
|
1594
1594
|
] });
|
|
1595
1595
|
}, Mr = S(kr), Dr = () => {
|
|
1596
|
-
const { allTransactions: t, healthScore: r } = F(), { connect: n, finstrong: o } =
|
|
1597
|
-
return /* @__PURE__ */
|
|
1596
|
+
const { allTransactions: t, healthScore: r } = F(), { connect: n, finstrong: o } = w(), [s, i] = m.useState(!1);
|
|
1597
|
+
return /* @__PURE__ */ a(u, { gap: 16, sx: { p: 16 }, children: [
|
|
1598
1598
|
/* @__PURE__ */ e(
|
|
1599
1599
|
Se,
|
|
1600
1600
|
{
|
|
@@ -1609,24 +1609,24 @@ const B = {
|
|
|
1609
1609
|
We,
|
|
1610
1610
|
{
|
|
1611
1611
|
amountColor: "text.primary",
|
|
1612
|
-
transactions: t.debtSpend.map((
|
|
1612
|
+
transactions: t.debtSpend.map((c) => c.transaction)
|
|
1613
1613
|
}
|
|
1614
1614
|
)
|
|
1615
1615
|
) : /* @__PURE__ */ e(
|
|
1616
|
-
|
|
1616
|
+
z,
|
|
1617
1617
|
{
|
|
1618
1618
|
onClick: () => {
|
|
1619
|
-
|
|
1619
|
+
i(!0);
|
|
1620
1620
|
},
|
|
1621
1621
|
variant: "contained",
|
|
1622
1622
|
children: o.connect_more_accounts_button
|
|
1623
1623
|
}
|
|
1624
1624
|
),
|
|
1625
1625
|
/* @__PURE__ */ e(
|
|
1626
|
-
|
|
1626
|
+
re,
|
|
1627
1627
|
{
|
|
1628
|
-
onClose: () =>
|
|
1629
|
-
showConnectWidget:
|
|
1628
|
+
onClose: () => i(!1),
|
|
1629
|
+
showConnectWidget: s,
|
|
1630
1630
|
title: n.mini_title
|
|
1631
1631
|
}
|
|
1632
1632
|
)
|
|
@@ -1636,38 +1636,38 @@ const B = {
|
|
|
1636
1636
|
data: r,
|
|
1637
1637
|
series: n,
|
|
1638
1638
|
style: o,
|
|
1639
|
-
...
|
|
1639
|
+
...s
|
|
1640
1640
|
}) => {
|
|
1641
|
-
const
|
|
1641
|
+
const i = G(), c = m.useRef(null), { width: p } = uo({
|
|
1642
1642
|
width: o.width
|
|
1643
1643
|
});
|
|
1644
1644
|
m.useLayoutEffect(() => {
|
|
1645
|
-
const
|
|
1645
|
+
const h = new ResizeObserver(() => {
|
|
1646
1646
|
window.requestAnimationFrame(() => {
|
|
1647
|
-
if (
|
|
1648
|
-
const { width:
|
|
1649
|
-
|
|
1647
|
+
if (c.current) {
|
|
1648
|
+
const { width: y } = c.current.getBoundingClientRect(), f = y / 2, x = c.current.querySelector("text");
|
|
1649
|
+
x && x.setAttribute("transform", `translate(${f}, -8)`);
|
|
1650
1650
|
}
|
|
1651
1651
|
});
|
|
1652
1652
|
});
|
|
1653
|
-
return
|
|
1654
|
-
|
|
1653
|
+
return c.current && h.observe(c.current), () => {
|
|
1654
|
+
c.current && h.unobserve(c.current);
|
|
1655
1655
|
};
|
|
1656
1656
|
}, []);
|
|
1657
|
-
const { formattedComparison: l, formattedMain:
|
|
1658
|
-
return /* @__PURE__ */
|
|
1659
|
-
/* @__PURE__ */ e(lt.rect, { ...
|
|
1657
|
+
const { formattedComparison: l, formattedMain: d } = r[n.index], _ = n.type === 0 ? d : l;
|
|
1658
|
+
return /* @__PURE__ */ a("g", { children: [
|
|
1659
|
+
/* @__PURE__ */ e(lt.rect, { ...s, fill: t, ref: c, rx: 2, style: o }),
|
|
1660
1660
|
/* @__PURE__ */ e(
|
|
1661
1661
|
lt.text,
|
|
1662
1662
|
{
|
|
1663
|
-
fill:
|
|
1663
|
+
fill: i.palette.text.secondary,
|
|
1664
1664
|
fontSize: 9,
|
|
1665
1665
|
fontWeight: 400,
|
|
1666
1666
|
textAnchor: "middle",
|
|
1667
|
-
transform:
|
|
1667
|
+
transform: p.to((h) => `translate(${h / 2}, -5)`),
|
|
1668
1668
|
x: o.x,
|
|
1669
1669
|
y: o.y,
|
|
1670
|
-
children:
|
|
1670
|
+
children: _
|
|
1671
1671
|
}
|
|
1672
1672
|
)
|
|
1673
1673
|
] });
|
|
@@ -1676,15 +1676,15 @@ const B = {
|
|
|
1676
1676
|
data: r,
|
|
1677
1677
|
title: n,
|
|
1678
1678
|
buttonLabel: o,
|
|
1679
|
-
onClick:
|
|
1680
|
-
legendLabelMain:
|
|
1681
|
-
legendLabelComparison:
|
|
1682
|
-
totalComparison:
|
|
1679
|
+
onClick: s,
|
|
1680
|
+
legendLabelMain: i,
|
|
1681
|
+
legendLabelComparison: c,
|
|
1682
|
+
totalComparison: p,
|
|
1683
1683
|
totalMain: l
|
|
1684
1684
|
}) => {
|
|
1685
|
-
const
|
|
1686
|
-
() => r.sort((g,
|
|
1687
|
-
const
|
|
1685
|
+
const d = G(), _ = so(d.breakpoints.down("xs")), h = m.useMemo(
|
|
1686
|
+
() => r.sort((g, C) => g.month - C.month).map((g) => {
|
|
1687
|
+
const C = Ln(g.month), M = {
|
|
1688
1688
|
spending_vs_income: {
|
|
1689
1689
|
main: g.standard_spend,
|
|
1690
1690
|
comparison: g.income,
|
|
@@ -1699,23 +1699,23 @@ const B = {
|
|
|
1699
1699
|
}
|
|
1700
1700
|
};
|
|
1701
1701
|
return {
|
|
1702
|
-
label:
|
|
1702
|
+
label: C,
|
|
1703
1703
|
...M[t]
|
|
1704
1704
|
};
|
|
1705
1705
|
}),
|
|
1706
1706
|
[r, t]
|
|
1707
|
-
),
|
|
1707
|
+
), y = {
|
|
1708
1708
|
dataKey: "label",
|
|
1709
1709
|
scaleType: "band"
|
|
1710
|
-
}, f = Math.max(...
|
|
1710
|
+
}, f = Math.max(...h.map((g) => Math.max(g.main, g.comparison))), x = Math.ceil(f * 1.2 / 1e3) * 1e3, b = x / 3, D = {
|
|
1711
1711
|
scaleType: "linear",
|
|
1712
1712
|
min: 0,
|
|
1713
|
-
max:
|
|
1713
|
+
max: x,
|
|
1714
1714
|
tickNumber: 4,
|
|
1715
|
-
tickMinStep:
|
|
1715
|
+
tickMinStep: b,
|
|
1716
1716
|
valueFormatter: (g) => g === 0 ? "$0" : `$${(g / 1e3).toFixed(0)}K`
|
|
1717
1717
|
};
|
|
1718
|
-
return /* @__PURE__ */
|
|
1718
|
+
return /* @__PURE__ */ a(
|
|
1719
1719
|
K,
|
|
1720
1720
|
{
|
|
1721
1721
|
sx: {
|
|
@@ -1723,7 +1723,7 @@ const B = {
|
|
|
1723
1723
|
py: 24
|
|
1724
1724
|
},
|
|
1725
1725
|
children: [
|
|
1726
|
-
/* @__PURE__ */
|
|
1726
|
+
/* @__PURE__ */ a(
|
|
1727
1727
|
u,
|
|
1728
1728
|
{
|
|
1729
1729
|
sx: {
|
|
@@ -1736,10 +1736,10 @@ const B = {
|
|
|
1736
1736
|
children: [
|
|
1737
1737
|
/* @__PURE__ */ e(N, { children: n }),
|
|
1738
1738
|
o && /* @__PURE__ */ e(
|
|
1739
|
-
|
|
1739
|
+
z,
|
|
1740
1740
|
{
|
|
1741
1741
|
endIcon: /* @__PURE__ */ e(Z, {}),
|
|
1742
|
-
onClick:
|
|
1742
|
+
onClick: s,
|
|
1743
1743
|
size: "small",
|
|
1744
1744
|
sx: {
|
|
1745
1745
|
pl: 8,
|
|
@@ -1752,10 +1752,10 @@ const B = {
|
|
|
1752
1752
|
]
|
|
1753
1753
|
}
|
|
1754
1754
|
),
|
|
1755
|
-
/* @__PURE__ */
|
|
1756
|
-
/* @__PURE__ */
|
|
1755
|
+
/* @__PURE__ */ a(u, { sx: { alignItems: "center", flexDirection: "row", gap: 24, py: 4 }, children: [
|
|
1756
|
+
/* @__PURE__ */ a(u, { sx: { gap: 8, alignItems: "center", flexDirection: "row" }, children: [
|
|
1757
1757
|
/* @__PURE__ */ e(
|
|
1758
|
-
|
|
1758
|
+
v,
|
|
1759
1759
|
{
|
|
1760
1760
|
sx: {
|
|
1761
1761
|
width: 10,
|
|
@@ -1765,17 +1765,17 @@ const B = {
|
|
|
1765
1765
|
}
|
|
1766
1766
|
}
|
|
1767
1767
|
),
|
|
1768
|
-
/* @__PURE__ */
|
|
1769
|
-
/* @__PURE__ */
|
|
1770
|
-
|
|
1768
|
+
/* @__PURE__ */ a(u, { sx: { alignItems: "center", flexDirection: "row" }, children: [
|
|
1769
|
+
/* @__PURE__ */ a(I, { variant: "subtitle2", children: [
|
|
1770
|
+
i,
|
|
1771
1771
|
" "
|
|
1772
1772
|
] }),
|
|
1773
|
-
!
|
|
1773
|
+
!_ && l && /* @__PURE__ */ e(I, { sx: { fontWeight: 700 }, variant: "subtitle2", children: l })
|
|
1774
1774
|
] })
|
|
1775
1775
|
] }),
|
|
1776
|
-
/* @__PURE__ */
|
|
1776
|
+
/* @__PURE__ */ a(u, { alignItems: "center", direction: "row", spacing: 8, children: [
|
|
1777
1777
|
/* @__PURE__ */ e(
|
|
1778
|
-
|
|
1778
|
+
v,
|
|
1779
1779
|
{
|
|
1780
1780
|
sx: {
|
|
1781
1781
|
width: 10,
|
|
@@ -1785,27 +1785,27 @@ const B = {
|
|
|
1785
1785
|
}
|
|
1786
1786
|
}
|
|
1787
1787
|
),
|
|
1788
|
-
/* @__PURE__ */
|
|
1789
|
-
/* @__PURE__ */
|
|
1790
|
-
|
|
1788
|
+
/* @__PURE__ */ a(u, { sx: { alignItems: "center", flexDirection: "row" }, children: [
|
|
1789
|
+
/* @__PURE__ */ a(I, { variant: "subtitle2", children: [
|
|
1790
|
+
c,
|
|
1791
1791
|
" "
|
|
1792
1792
|
] }),
|
|
1793
|
-
!
|
|
1793
|
+
!_ && p && /* @__PURE__ */ e(I, { sx: { fontWeight: 700 }, variant: "subtitle2", children: p })
|
|
1794
1794
|
] })
|
|
1795
1795
|
] })
|
|
1796
1796
|
] }),
|
|
1797
|
-
/* @__PURE__ */
|
|
1797
|
+
/* @__PURE__ */ a(
|
|
1798
1798
|
po,
|
|
1799
1799
|
{
|
|
1800
|
-
colors: [`${
|
|
1801
|
-
dataset:
|
|
1800
|
+
colors: [`${d.palette.chartMono.chartMono3}`, `${d.palette.chartMono.chartMono5}`],
|
|
1801
|
+
dataset: h,
|
|
1802
1802
|
height: 240,
|
|
1803
1803
|
margin: { top: 20, bottom: 30, right: 10, left: 42 },
|
|
1804
1804
|
series: [
|
|
1805
1805
|
{ dataKey: "main", type: "bar" },
|
|
1806
1806
|
{ dataKey: "comparison", type: "bar" }
|
|
1807
1807
|
],
|
|
1808
|
-
xAxis: [
|
|
1808
|
+
xAxis: [y],
|
|
1809
1809
|
yAxis: [D],
|
|
1810
1810
|
children: [
|
|
1811
1811
|
/* @__PURE__ */ e(
|
|
@@ -1813,16 +1813,16 @@ const B = {
|
|
|
1813
1813
|
{
|
|
1814
1814
|
slots: {
|
|
1815
1815
|
bar: (g) => {
|
|
1816
|
-
const { ownerState:
|
|
1816
|
+
const { ownerState: C, style: M, ...$ } = g;
|
|
1817
1817
|
return /* @__PURE__ */ e(
|
|
1818
1818
|
Ar,
|
|
1819
1819
|
{
|
|
1820
1820
|
...$,
|
|
1821
|
-
color:
|
|
1822
|
-
data:
|
|
1821
|
+
color: C.color,
|
|
1822
|
+
data: h,
|
|
1823
1823
|
series: {
|
|
1824
|
-
index:
|
|
1825
|
-
type: Number(
|
|
1824
|
+
index: C.dataIndex,
|
|
1825
|
+
type: Number(C.id.toString().split("-").pop())
|
|
1826
1826
|
},
|
|
1827
1827
|
style: M
|
|
1828
1828
|
}
|
|
@@ -1836,10 +1836,10 @@ const B = {
|
|
|
1836
1836
|
{
|
|
1837
1837
|
sx: () => ({
|
|
1838
1838
|
".MuiChartsAxis-line": {
|
|
1839
|
-
stroke:
|
|
1839
|
+
stroke: d.palette.divider
|
|
1840
1840
|
},
|
|
1841
1841
|
".MuiChartsAxis-tick": {
|
|
1842
|
-
stroke:
|
|
1842
|
+
stroke: d.palette.divider
|
|
1843
1843
|
},
|
|
1844
1844
|
".MuiChartsAxis-tickLabel": {
|
|
1845
1845
|
transform: "translateY(10px)"
|
|
@@ -1856,10 +1856,10 @@ const B = {
|
|
|
1856
1856
|
{
|
|
1857
1857
|
sx: () => ({
|
|
1858
1858
|
".MuiChartsAxis-line": {
|
|
1859
|
-
stroke:
|
|
1859
|
+
stroke: d.palette.divider
|
|
1860
1860
|
},
|
|
1861
1861
|
".MuiChartsAxis-tick": {
|
|
1862
|
-
stroke:
|
|
1862
|
+
stroke: d.palette.divider
|
|
1863
1863
|
},
|
|
1864
1864
|
".MuiChartsAxis-tickLabel": {
|
|
1865
1865
|
transform: "translateX(-8px)"
|
|
@@ -1878,36 +1878,36 @@ const B = {
|
|
|
1878
1878
|
}
|
|
1879
1879
|
);
|
|
1880
1880
|
}, Tr = () => {
|
|
1881
|
-
const { loadDebtSpend: t, loadIncome: r, monthlySummaries: n } = F(), { isInitialized: o } = j(), [
|
|
1881
|
+
const { loadDebtSpend: t, loadIncome: r, monthlySummaries: n } = F(), { isInitialized: o } = j(), [s, i] = m.useState(0), { finstrong: c } = w();
|
|
1882
1882
|
return m.useEffect(() => {
|
|
1883
1883
|
o && (t().finally(), r().finally());
|
|
1884
|
-
}, [o]), /* @__PURE__ */
|
|
1885
|
-
/* @__PURE__ */
|
|
1886
|
-
/* @__PURE__ */
|
|
1884
|
+
}, [o]), /* @__PURE__ */ a(E, { children: [
|
|
1885
|
+
/* @__PURE__ */ a(K, { children: [
|
|
1886
|
+
/* @__PURE__ */ a(
|
|
1887
1887
|
qe,
|
|
1888
1888
|
{
|
|
1889
|
-
"aria-label":
|
|
1889
|
+
"aria-label": c.key_indicators_save.drawer_title,
|
|
1890
1890
|
centered: !0,
|
|
1891
|
-
onChange: (
|
|
1891
|
+
onChange: (p, l) => i(l),
|
|
1892
1892
|
sx: { mb: 0 },
|
|
1893
|
-
value:
|
|
1893
|
+
value: s,
|
|
1894
1894
|
variant: "fullWidth",
|
|
1895
1895
|
children: [
|
|
1896
1896
|
/* @__PURE__ */ e(
|
|
1897
|
-
|
|
1897
|
+
ce,
|
|
1898
1898
|
{
|
|
1899
1899
|
"aria-controls": "income-details-tabpanel-0",
|
|
1900
1900
|
id: "income-details-tab-0",
|
|
1901
|
-
label:
|
|
1901
|
+
label: c.key_indicators_borrow.have_manageable_debt_drawer.income,
|
|
1902
1902
|
sx: { minHeight: 44 }
|
|
1903
1903
|
}
|
|
1904
1904
|
),
|
|
1905
1905
|
/* @__PURE__ */ e(
|
|
1906
|
-
|
|
1906
|
+
ce,
|
|
1907
1907
|
{
|
|
1908
1908
|
"aria-controls": "debt-payment-details-tabpanel-1",
|
|
1909
1909
|
id: "debt-payment-details-tab-1",
|
|
1910
|
-
label:
|
|
1910
|
+
label: c.key_indicators_borrow.have_manageable_debt_drawer.debt_payment,
|
|
1911
1911
|
sx: { minHeight: 44 }
|
|
1912
1912
|
}
|
|
1913
1913
|
)
|
|
@@ -1915,45 +1915,45 @@ const B = {
|
|
|
1915
1915
|
}
|
|
1916
1916
|
),
|
|
1917
1917
|
/* @__PURE__ */ e(
|
|
1918
|
-
|
|
1918
|
+
le,
|
|
1919
1919
|
{
|
|
1920
1920
|
"aria-labelledby": "income-details-tab-0",
|
|
1921
1921
|
index: 0,
|
|
1922
1922
|
name: "income-details",
|
|
1923
|
-
value:
|
|
1923
|
+
value: s,
|
|
1924
1924
|
children: /* @__PURE__ */ e(Mr, {})
|
|
1925
1925
|
}
|
|
1926
1926
|
),
|
|
1927
1927
|
/* @__PURE__ */ e(
|
|
1928
|
-
|
|
1928
|
+
le,
|
|
1929
1929
|
{
|
|
1930
1930
|
"aria-labelledby": "debt-payment-details-tab-1",
|
|
1931
1931
|
index: 1,
|
|
1932
1932
|
name: "debt-payment-details",
|
|
1933
|
-
value:
|
|
1933
|
+
value: s,
|
|
1934
1934
|
children: /* @__PURE__ */ e(Ir, {})
|
|
1935
1935
|
}
|
|
1936
1936
|
)
|
|
1937
1937
|
] }),
|
|
1938
|
-
n.length ? /* @__PURE__ */
|
|
1938
|
+
n.length ? /* @__PURE__ */ a(E, { children: [
|
|
1939
1939
|
/* @__PURE__ */ e(
|
|
1940
1940
|
jt,
|
|
1941
1941
|
{
|
|
1942
1942
|
chartFor: "debt_payment_vs_income",
|
|
1943
1943
|
data: n,
|
|
1944
|
-
legendLabelComparison:
|
|
1945
|
-
legendLabelMain:
|
|
1946
|
-
title:
|
|
1944
|
+
legendLabelComparison: c.key_indicators_borrow.have_manageable_debt_drawer.debt_payment,
|
|
1945
|
+
legendLabelMain: c.key_indicators_borrow.have_manageable_debt_drawer.income,
|
|
1946
|
+
title: c.key_indicators_borrow.have_manageable_debt_drawer.debt_payment
|
|
1947
1947
|
}
|
|
1948
1948
|
),
|
|
1949
1949
|
/* @__PURE__ */ e(Qe, { chartFor: "debtOverTime" })
|
|
1950
|
-
] }) : /* @__PURE__ */
|
|
1950
|
+
] }) : /* @__PURE__ */ a(E, { children: [
|
|
1951
1951
|
/* @__PURE__ */ e(
|
|
1952
1952
|
Fe,
|
|
1953
1953
|
{
|
|
1954
|
-
header:
|
|
1954
|
+
header: c.key_indicators_borrow.have_manageable_debt_drawer.have_manageable_debt_double_bar_chart_empty_state_header,
|
|
1955
1955
|
icon: "multiline_chart",
|
|
1956
|
-
subText:
|
|
1956
|
+
subText: c.key_indicators_borrow.have_manageable_debt_drawer.have_manageable_debt_double_bar_chart_empty_state_description,
|
|
1957
1957
|
sx: {
|
|
1958
1958
|
backgroundColor: "background.paper",
|
|
1959
1959
|
borderRadius: "8px",
|
|
@@ -1967,9 +1967,9 @@ const B = {
|
|
|
1967
1967
|
/* @__PURE__ */ e(
|
|
1968
1968
|
Fe,
|
|
1969
1969
|
{
|
|
1970
|
-
header:
|
|
1970
|
+
header: c.key_indicators_borrow.have_manageable_debt_drawer.have_manageable_debt_line_chart_empty_state_header,
|
|
1971
1971
|
icon: "multiline_chart",
|
|
1972
|
-
subText:
|
|
1972
|
+
subText: c.key_indicators_borrow.have_manageable_debt_drawer.have_manageable_debt_line_chart_empty_state_description,
|
|
1973
1973
|
sx: {
|
|
1974
1974
|
backgroundColor: "background.paper",
|
|
1975
1975
|
borderRadius: "8px",
|
|
@@ -1983,16 +1983,16 @@ const B = {
|
|
|
1983
1983
|
] })
|
|
1984
1984
|
] });
|
|
1985
1985
|
}, Or = S(Tr), Rr = () => {
|
|
1986
|
-
const { healthScore: t } = F(), { finstrong: r } =
|
|
1986
|
+
const { healthScore: t } = F(), { finstrong: r } = w(), n = Te(t.spend_to_income_ratio) ?? 0, o = Object.keys(t).length === 0, i = ((p) => o ? "MISSING" : p < 100 ? "GOOD" : p >= 100 && p <= 109 ? "FAIR" : p >= 110 ? "OFF_TRACK" : "MISSING")(n), c = {
|
|
1987
1987
|
GOOD: [{ percentage: `${n}%` }],
|
|
1988
1988
|
FAIR: [{ percentage: "100%" }, { percentage: `${n - 100}%` }],
|
|
1989
1989
|
OFF_TRACK: [{ percentage: "100%" }, { percentage: `${n - 100}%` }],
|
|
1990
1990
|
MISSING: [{ percentage: "0%" }]
|
|
1991
|
-
}[
|
|
1991
|
+
}[i];
|
|
1992
1992
|
return /* @__PURE__ */ e(
|
|
1993
1993
|
$e,
|
|
1994
1994
|
{
|
|
1995
|
-
bottomComponent: /* @__PURE__ */
|
|
1995
|
+
bottomComponent: /* @__PURE__ */ a(
|
|
1996
1996
|
u,
|
|
1997
1997
|
{
|
|
1998
1998
|
sx: {
|
|
@@ -2002,12 +2002,12 @@ const B = {
|
|
|
2002
2002
|
mt: 8
|
|
2003
2003
|
},
|
|
2004
2004
|
children: [
|
|
2005
|
-
/* @__PURE__ */
|
|
2005
|
+
/* @__PURE__ */ a(I, { variant: "body2", children: [
|
|
2006
2006
|
o ? "-" : L(t.ninety_day_income, "0,0.00"),
|
|
2007
2007
|
" ",
|
|
2008
2008
|
r?.key_indicators_spend.spend_less_than_you_make_drawer.income
|
|
2009
2009
|
] }),
|
|
2010
|
-
/* @__PURE__ */
|
|
2010
|
+
/* @__PURE__ */ a(I, { variant: "body2", children: [
|
|
2011
2011
|
o ? "-%" : `${n}%`,
|
|
2012
2012
|
" ",
|
|
2013
2013
|
r?.key_indicators_spend.spend_less_than_you_make_drawer.spent
|
|
@@ -2016,47 +2016,49 @@ const B = {
|
|
|
2016
2016
|
}
|
|
2017
2017
|
),
|
|
2018
2018
|
label: r?.key_indicators_spend.spend_less_than_you_make_drawer.spend_less_than_you_make_sticky_description,
|
|
2019
|
-
status:
|
|
2020
|
-
statusBarData:
|
|
2019
|
+
status: i,
|
|
2020
|
+
statusBarData: c,
|
|
2021
2021
|
value: o ? "$0" : L(t.ninety_day_spend, "0,0.00")
|
|
2022
2022
|
}
|
|
2023
2023
|
);
|
|
2024
|
-
}, Fr = S(Rr), Pr = (
|
|
2025
|
-
|
|
2024
|
+
}, Fr = S(Rr), Pr = ({
|
|
2025
|
+
onPrimaryCtaClick: t
|
|
2026
|
+
}) => {
|
|
2027
|
+
const r = G(), { monthlySummaries: n } = F(), { finstrong: o, goals: s, spending: i } = w(), { selectedAccounts: c } = j(), { categories: p, dateRangeCategoryTotals: l, loadDateRangeCategoryTotals: d } = Ye(), { appDataStore: _ } = Kn(), [h, y] = m.useState("");
|
|
2026
2028
|
m.useEffect(() => {
|
|
2027
|
-
|
|
2028
|
-
|
|
2029
|
+
d(
|
|
2030
|
+
c,
|
|
2029
2031
|
Lt(/* @__PURE__ */ new Date()),
|
|
2030
2032
|
$t(/* @__PURE__ */ new Date())
|
|
2031
2033
|
).finally();
|
|
2032
|
-
}, [
|
|
2034
|
+
}, [c]);
|
|
2033
2035
|
const f = m.useMemo(
|
|
2034
|
-
() => _o(
|
|
2035
|
-
[
|
|
2036
|
-
),
|
|
2037
|
-
|
|
2038
|
-
}, { totalSpending:
|
|
2039
|
-
(g, { standard_spend:
|
|
2040
|
-
totalSpending: g.totalSpending +
|
|
2036
|
+
() => _o(p, s, r, l),
|
|
2037
|
+
[p, l]
|
|
2038
|
+
), x = (g) => {
|
|
2039
|
+
y(h === g ? "" : g);
|
|
2040
|
+
}, { totalSpending: b, totalIncome: D } = m.useMemo(() => n?.reduce(
|
|
2041
|
+
(g, { standard_spend: C = 0, income: M = 0 }) => ({
|
|
2042
|
+
totalSpending: g.totalSpending + C,
|
|
2041
2043
|
totalIncome: g.totalIncome + M
|
|
2042
2044
|
}),
|
|
2043
2045
|
{ totalSpending: 0, totalIncome: 0 }
|
|
2044
|
-
), [
|
|
2045
|
-
return /* @__PURE__ */
|
|
2046
|
-
|
|
2046
|
+
), [n]);
|
|
2047
|
+
return /* @__PURE__ */ a(u, { sx: { gap: 24 }, children: [
|
|
2048
|
+
n.length ? /* @__PURE__ */ e(
|
|
2047
2049
|
jt,
|
|
2048
2050
|
{
|
|
2049
|
-
...
|
|
2051
|
+
..._.appData.client_profile?.allow_trends_widget && {
|
|
2050
2052
|
buttonLabel: o.key_indicators_spend.spend_less_than_you_make_drawer.view_more
|
|
2051
2053
|
},
|
|
2052
2054
|
chartFor: "spending_vs_income",
|
|
2053
|
-
data:
|
|
2055
|
+
data: n,
|
|
2054
2056
|
legendLabelComparison: o.key_indicators_spend.spend_less_than_you_make_drawer.income,
|
|
2055
2057
|
legendLabelMain: o.key_indicators_spend.spend_less_than_you_make_drawer.spending,
|
|
2058
|
+
onClick: () => t?.("trends"),
|
|
2056
2059
|
title: o.key_indicators_spend.spend_less_than_you_make_drawer.trends,
|
|
2057
2060
|
totalComparison: L(D, "0,0.00"),
|
|
2058
|
-
totalMain: L(
|
|
2059
|
-
onClick: n("Trends")
|
|
2061
|
+
totalMain: L(b, "0,0.00")
|
|
2060
2062
|
}
|
|
2061
2063
|
) : /* @__PURE__ */ e(
|
|
2062
2064
|
Fe,
|
|
@@ -2079,7 +2081,7 @@ const B = {
|
|
|
2079
2081
|
variant: "no-buttons"
|
|
2080
2082
|
}
|
|
2081
2083
|
),
|
|
2082
|
-
f ? /* @__PURE__ */
|
|
2084
|
+
f ? /* @__PURE__ */ a(
|
|
2083
2085
|
K,
|
|
2084
2086
|
{
|
|
2085
2087
|
sx: {
|
|
@@ -2087,7 +2089,7 @@ const B = {
|
|
|
2087
2089
|
py: 24
|
|
2088
2090
|
},
|
|
2089
2091
|
children: [
|
|
2090
|
-
/* @__PURE__ */
|
|
2092
|
+
/* @__PURE__ */ a(
|
|
2091
2093
|
u,
|
|
2092
2094
|
{
|
|
2093
2095
|
sx: {
|
|
@@ -2099,39 +2101,39 @@ const B = {
|
|
|
2099
2101
|
},
|
|
2100
2102
|
children: [
|
|
2101
2103
|
/* @__PURE__ */ e(N, { children: o.key_indicators_spend.spend_less_than_you_make_drawer.spending }),
|
|
2102
|
-
|
|
2103
|
-
|
|
2104
|
+
_.appData.client_profile?.allow_spending_widget && /* @__PURE__ */ e(
|
|
2105
|
+
z,
|
|
2104
2106
|
{
|
|
2105
2107
|
endIcon: /* @__PURE__ */ e(Z, {}),
|
|
2108
|
+
onClick: () => t?.("spending"),
|
|
2106
2109
|
size: "small",
|
|
2107
2110
|
sx: {
|
|
2108
2111
|
pl: 8,
|
|
2109
2112
|
height: 24
|
|
2110
2113
|
},
|
|
2111
2114
|
variant: "text",
|
|
2112
|
-
onClick: n("Spending"),
|
|
2113
2115
|
children: o.key_indicators_spend.spend_less_than_you_make_drawer.view_more
|
|
2114
2116
|
}
|
|
2115
2117
|
)
|
|
2116
2118
|
]
|
|
2117
2119
|
}
|
|
2118
2120
|
),
|
|
2119
|
-
/* @__PURE__ */
|
|
2121
|
+
/* @__PURE__ */ a(u, { sx: { gap: 12, py: 16, flexDirection: "row", justifyContent: "center" }, children: [
|
|
2120
2122
|
/* @__PURE__ */ e(
|
|
2121
2123
|
ho,
|
|
2122
2124
|
{
|
|
2123
2125
|
data: f,
|
|
2124
|
-
onSelected:
|
|
2125
|
-
selectedId:
|
|
2126
|
-
totalLabel:
|
|
2126
|
+
onSelected: x,
|
|
2127
|
+
selectedId: h,
|
|
2128
|
+
totalLabel: i.total_spending
|
|
2127
2129
|
}
|
|
2128
2130
|
),
|
|
2129
2131
|
/* @__PURE__ */ e(
|
|
2130
2132
|
mo,
|
|
2131
2133
|
{
|
|
2132
2134
|
data: f,
|
|
2133
|
-
onSelected:
|
|
2134
|
-
selectedId:
|
|
2135
|
+
onSelected: x,
|
|
2136
|
+
selectedId: h
|
|
2135
2137
|
}
|
|
2136
2138
|
)
|
|
2137
2139
|
] })
|
|
@@ -2166,26 +2168,27 @@ const B = {
|
|
|
2166
2168
|
}, Lr = ({
|
|
2167
2169
|
drawerFor: t,
|
|
2168
2170
|
isOpen: r,
|
|
2169
|
-
onClose: n
|
|
2171
|
+
onClose: n,
|
|
2172
|
+
onPrimaryCtaClick: o
|
|
2170
2173
|
}) => {
|
|
2171
|
-
const { finstrong:
|
|
2174
|
+
const { finstrong: s } = w(), c = {
|
|
2172
2175
|
spendLessThanYouMake: {
|
|
2173
|
-
title:
|
|
2174
|
-
description:
|
|
2176
|
+
title: s.key_indicators_spend.spend_less_than_you_make_drawer.spend_less_than_you_make_title,
|
|
2177
|
+
description: s.key_indicators_spend.spend_less_than_you_make_drawer.spend_less_than_you_make_description,
|
|
2175
2178
|
stickyComponent: /* @__PURE__ */ e(Fr, {}),
|
|
2176
|
-
content: /* @__PURE__ */ e(Br, {}),
|
|
2179
|
+
content: /* @__PURE__ */ e(Br, { onPrimaryCtaClick: o }),
|
|
2177
2180
|
drawerType: "connectDrawer",
|
|
2178
|
-
connectTitle:
|
|
2179
|
-
connectDescription:
|
|
2181
|
+
connectTitle: s.connect_your_accounts,
|
|
2182
|
+
connectDescription: s.connect_more_accounts_to_unlock_a_fuller_understanding_of_your_finances
|
|
2180
2183
|
},
|
|
2181
2184
|
payBillsOnTime: {
|
|
2182
|
-
title:
|
|
2183
|
-
description:
|
|
2185
|
+
title: s.key_indicators_spend.pay_bills_on_time_drawer.pay_bills_on_time_title,
|
|
2186
|
+
description: s.key_indicators_spend.pay_bills_on_time_drawer.pay_bills_on_time_description,
|
|
2184
2187
|
stickyComponent: /* @__PURE__ */ e(hr, {}),
|
|
2185
2188
|
content: /* @__PURE__ */ e(ur, {}),
|
|
2186
2189
|
drawerType: "connectDrawer",
|
|
2187
|
-
connectTitle:
|
|
2188
|
-
connectDescription:
|
|
2190
|
+
connectTitle: s.connect_your_accounts,
|
|
2191
|
+
connectDescription: s.connect_more_accounts_to_unlock_a_fuller_understanding_of_your_finances
|
|
2189
2192
|
},
|
|
2190
2193
|
maintainEmergencySavings: {
|
|
2191
2194
|
content: /* @__PURE__ */ e(rr, {}),
|
|
@@ -2193,17 +2196,17 @@ const B = {
|
|
|
2193
2196
|
stickyComponent: /* @__PURE__ */ e(cr, {}),
|
|
2194
2197
|
title: Ee.maintain_emergency_savings_title,
|
|
2195
2198
|
drawerType: "connectDrawer",
|
|
2196
|
-
connectTitle:
|
|
2197
|
-
connectDescription:
|
|
2199
|
+
connectTitle: s.connect_your_accounts,
|
|
2200
|
+
connectDescription: s.connect_more_accounts_to_unlock_a_fuller_understanding_of_your_finances
|
|
2198
2201
|
},
|
|
2199
2202
|
haveManageableDebt: {
|
|
2200
|
-
title:
|
|
2201
|
-
description:
|
|
2203
|
+
title: s.key_indicators_borrow.have_manageable_debt_drawer.have_manageable_debt_title,
|
|
2204
|
+
description: s.key_indicators_borrow.have_manageable_debt_drawer.have_manageable_debt_description,
|
|
2202
2205
|
stickyComponent: /* @__PURE__ */ e(wr, {}),
|
|
2203
2206
|
content: /* @__PURE__ */ e(Or, {}),
|
|
2204
2207
|
drawerType: "connectDrawer",
|
|
2205
|
-
connectTitle:
|
|
2206
|
-
connectDescription:
|
|
2208
|
+
connectTitle: s.dont_see_all_your_accounts,
|
|
2209
|
+
connectDescription: s.connect_more_accounts_to_view_more_accurate_financial_picture
|
|
2207
2210
|
},
|
|
2208
2211
|
haveAGoodCreditScore: {
|
|
2209
2212
|
title: /* @__PURE__ */ e(Xo, {}),
|
|
@@ -2212,43 +2215,44 @@ const B = {
|
|
|
2212
2215
|
content: /* @__PURE__ */ e(jo, {})
|
|
2213
2216
|
},
|
|
2214
2217
|
saveEnoughToLiveOn: {
|
|
2215
|
-
title:
|
|
2216
|
-
description:
|
|
2218
|
+
title: s.key_indicators_save.drawer_title,
|
|
2219
|
+
description: s.key_indicators_save.drawer_description,
|
|
2217
2220
|
stickyComponent: /* @__PURE__ */ e(Cr, {}),
|
|
2218
2221
|
content: /* @__PURE__ */ e(xr, {}),
|
|
2219
2222
|
drawerType: "connectDrawer",
|
|
2220
|
-
connectTitle:
|
|
2221
|
-
connectDescription:
|
|
2223
|
+
connectTitle: s.dont_see_all_your_accounts,
|
|
2224
|
+
connectDescription: s.connect_more_accounts_to_view_more_accurate_financial_picture
|
|
2222
2225
|
}
|
|
2223
2226
|
}[t];
|
|
2224
2227
|
return /* @__PURE__ */ e(
|
|
2225
2228
|
Ht,
|
|
2226
2229
|
{
|
|
2227
|
-
connectDescription:
|
|
2228
|
-
connectTitle:
|
|
2229
|
-
description:
|
|
2230
|
-
drawerTitle:
|
|
2231
|
-
drawerType:
|
|
2230
|
+
connectDescription: c?.connectDescription,
|
|
2231
|
+
connectTitle: c?.connectTitle,
|
|
2232
|
+
description: c?.description,
|
|
2233
|
+
drawerTitle: s.key_indicators,
|
|
2234
|
+
drawerType: c.drawerType,
|
|
2232
2235
|
isOpen: r,
|
|
2233
2236
|
loadConnectAccountsCard: !0,
|
|
2234
2237
|
onClose: n,
|
|
2235
|
-
stickyComponent:
|
|
2236
|
-
title:
|
|
2237
|
-
children: /* @__PURE__ */ e(u, { sx: { gap: 16 }, children:
|
|
2238
|
+
stickyComponent: c.stickyComponent,
|
|
2239
|
+
title: c.title,
|
|
2240
|
+
children: /* @__PURE__ */ e(u, { sx: { gap: 16 }, children: c.content })
|
|
2238
2241
|
}
|
|
2239
2242
|
);
|
|
2240
2243
|
}, $r = S(Lr), xe = ({
|
|
2241
2244
|
drawerFor: t,
|
|
2242
2245
|
title: r,
|
|
2243
2246
|
description: n,
|
|
2244
|
-
cardState: o = "MISSING"
|
|
2247
|
+
cardState: o = "MISSING",
|
|
2248
|
+
onPrimaryCtaClick: s
|
|
2245
2249
|
}) => {
|
|
2246
|
-
const [
|
|
2247
|
-
return /* @__PURE__ */
|
|
2248
|
-
/* @__PURE__ */
|
|
2250
|
+
const [i, c] = m.useState(!1);
|
|
2251
|
+
return /* @__PURE__ */ a(E, { children: [
|
|
2252
|
+
/* @__PURE__ */ a(
|
|
2249
2253
|
u,
|
|
2250
2254
|
{
|
|
2251
|
-
onClick: () =>
|
|
2255
|
+
onClick: () => c(!0),
|
|
2252
2256
|
sx: {
|
|
2253
2257
|
alignItems: "center",
|
|
2254
2258
|
flexDirection: "row",
|
|
@@ -2261,8 +2265,8 @@ const B = {
|
|
|
2261
2265
|
cursor: "pointer"
|
|
2262
2266
|
},
|
|
2263
2267
|
children: [
|
|
2264
|
-
/* @__PURE__ */
|
|
2265
|
-
/* @__PURE__ */
|
|
2268
|
+
/* @__PURE__ */ a(u, { sx: { gap: 4 }, children: [
|
|
2269
|
+
/* @__PURE__ */ a(u, { sx: { alignItems: "center", flexDirection: "row", gap: 8 }, children: [
|
|
2266
2270
|
/* @__PURE__ */ e(k, { sx: { fontWeight: 600 }, variant: "body1", children: r }),
|
|
2267
2271
|
/* @__PURE__ */ e(Le, { status: o })
|
|
2268
2272
|
] }),
|
|
@@ -2276,175 +2280,177 @@ const B = {
|
|
|
2276
2280
|
$r,
|
|
2277
2281
|
{
|
|
2278
2282
|
drawerFor: t,
|
|
2279
|
-
isOpen:
|
|
2280
|
-
onClose: () =>
|
|
2283
|
+
isOpen: i,
|
|
2284
|
+
onClose: () => c(!1),
|
|
2285
|
+
onPrimaryCtaClick: s
|
|
2281
2286
|
}
|
|
2282
2287
|
)
|
|
2283
2288
|
] });
|
|
2284
|
-
}, Wr = () => {
|
|
2285
|
-
const { finstrong:
|
|
2286
|
-
const
|
|
2287
|
-
GOOD:
|
|
2288
|
-
FAIR:
|
|
2289
|
-
OFF_TRACK:
|
|
2290
|
-
MISSING:
|
|
2291
|
-
},
|
|
2289
|
+
}, Wr = ({ onPrimaryCtaClick: t }) => {
|
|
2290
|
+
const { finstrong: r } = w(), { key_indicators_spend: n } = r, { healthScore: o } = F(), s = (p) => {
|
|
2291
|
+
const l = Wn(p), d = {
|
|
2292
|
+
GOOD: n.ratio_good_description,
|
|
2293
|
+
FAIR: n.ratio_fair_description,
|
|
2294
|
+
OFF_TRACK: n.ratio_off_track_description,
|
|
2295
|
+
MISSING: n.ratio_missing_description
|
|
2296
|
+
}, _ = l === "MISSING" ? d[l] : Y(d[l], p);
|
|
2292
2297
|
return {
|
|
2293
|
-
cardState:
|
|
2294
|
-
description:
|
|
2295
|
-
title:
|
|
2298
|
+
cardState: l,
|
|
2299
|
+
description: _,
|
|
2300
|
+
title: n.ratio_card_title
|
|
2296
2301
|
};
|
|
2297
|
-
}, { spendToIncomeRatio:
|
|
2298
|
-
const
|
|
2299
|
-
|
|
2300
|
-
|
|
2302
|
+
}, { spendToIncomeRatio: i, spendFeeCount: c } = m.useMemo(() => {
|
|
2303
|
+
const p = o.spend_to_income_ratio !== null ? Math.round(o.spend_to_income_ratio * 100) : null, l = s(p), d = $n(
|
|
2304
|
+
o.spending_fee_transaction_count,
|
|
2305
|
+
n
|
|
2301
2306
|
);
|
|
2302
|
-
return { spendToIncomeRatio:
|
|
2307
|
+
return { spendToIncomeRatio: l, spendFeeCount: d };
|
|
2303
2308
|
}, [
|
|
2304
|
-
|
|
2305
|
-
|
|
2306
|
-
|
|
2307
|
-
|
|
2309
|
+
o.spend_to_income_ratio,
|
|
2310
|
+
o.spending_fee_transaction_count,
|
|
2311
|
+
n,
|
|
2312
|
+
r
|
|
2308
2313
|
]);
|
|
2309
|
-
return /* @__PURE__ */
|
|
2314
|
+
return /* @__PURE__ */ a(u, { sx: { gap: 24, p: 8, pt: 24 }, children: [
|
|
2310
2315
|
/* @__PURE__ */ e(
|
|
2311
2316
|
xe,
|
|
2312
2317
|
{
|
|
2313
|
-
cardState:
|
|
2314
|
-
description:
|
|
2315
|
-
drawerFor:
|
|
2316
|
-
|
|
2318
|
+
cardState: i.cardState,
|
|
2319
|
+
description: i.description,
|
|
2320
|
+
drawerFor: de.SpendLessThanYouMake,
|
|
2321
|
+
onPrimaryCtaClick: t,
|
|
2322
|
+
title: i.title
|
|
2317
2323
|
}
|
|
2318
2324
|
),
|
|
2319
2325
|
/* @__PURE__ */ e(
|
|
2320
2326
|
xe,
|
|
2321
2327
|
{
|
|
2322
|
-
cardState:
|
|
2323
|
-
description:
|
|
2324
|
-
drawerFor:
|
|
2325
|
-
title:
|
|
2328
|
+
cardState: c.cardState,
|
|
2329
|
+
description: c.description,
|
|
2330
|
+
drawerFor: de.PayBillsOnTime,
|
|
2331
|
+
title: c.title
|
|
2326
2332
|
}
|
|
2327
2333
|
)
|
|
2328
2334
|
] });
|
|
2329
2335
|
}, zr = S(Wr), Er = () => {
|
|
2330
|
-
const { healthScore: t } = F(), { finstrong: r } =
|
|
2331
|
-
const l = wt(
|
|
2336
|
+
const { healthScore: t } = F(), { finstrong: r } = w(), { key_indicators_save: n } = r, o = (p) => {
|
|
2337
|
+
const l = wt(p), d = {
|
|
2332
2338
|
GOOD: n.days_of_cash_good_description,
|
|
2333
2339
|
FAIR: n.days_of_cash_fair_description,
|
|
2334
2340
|
OFF_TRACK: n.days_of_cash_off_track_description,
|
|
2335
2341
|
MISSING: n.days_of_cash_missing_description
|
|
2336
|
-
},
|
|
2342
|
+
}, _ = l === "MISSING" ? d[l] : Y(d[l], p);
|
|
2337
2343
|
return {
|
|
2338
2344
|
cardState: l,
|
|
2339
|
-
description:
|
|
2345
|
+
description: _,
|
|
2340
2346
|
title: n.days_of_cash_title
|
|
2341
2347
|
};
|
|
2342
|
-
},
|
|
2343
|
-
const l = vt(
|
|
2348
|
+
}, s = (p) => {
|
|
2349
|
+
const l = vt(p), d = {
|
|
2344
2350
|
GOOD: n.emergency_savings_good_description,
|
|
2345
2351
|
FAIR: n.emergency_savings_fair_description,
|
|
2346
2352
|
OFF_TRACK: n.emergency_savings_off_track_description,
|
|
2347
2353
|
MISSING: n.emergency_savings_missing_description
|
|
2348
2354
|
};
|
|
2349
|
-
let
|
|
2350
|
-
return l === "FAIR" &&
|
|
2351
|
-
|
|
2352
|
-
L(
|
|
2353
|
-
) :
|
|
2355
|
+
let _;
|
|
2356
|
+
return l === "FAIR" && p !== null ? _ = Y(
|
|
2357
|
+
d[l],
|
|
2358
|
+
L(p, "0,0.00")
|
|
2359
|
+
) : _ = d[l], {
|
|
2354
2360
|
cardState: l,
|
|
2355
|
-
description:
|
|
2361
|
+
description: _,
|
|
2356
2362
|
title: n.emergency_savings_title
|
|
2357
2363
|
};
|
|
2358
|
-
}, { daysOfCashOnHand:
|
|
2359
|
-
const
|
|
2360
|
-
return { daysOfCashOnHand: l, emergencySavings:
|
|
2364
|
+
}, { daysOfCashOnHand: i, emergencySavings: c } = m.useMemo(() => {
|
|
2365
|
+
const p = t.months_of_cash_on_hand !== null ? Math.round(t.months_of_cash_on_hand * 30) : null, l = o(p), d = t.emergency_savings_on_hand !== null ? Math.round(t.emergency_savings_on_hand) : null, _ = s(d);
|
|
2366
|
+
return { daysOfCashOnHand: l, emergencySavings: _ };
|
|
2361
2367
|
}, [
|
|
2362
2368
|
t.months_of_cash_on_hand,
|
|
2363
2369
|
t.emergency_savings_on_hand,
|
|
2364
2370
|
n,
|
|
2365
2371
|
r
|
|
2366
2372
|
]);
|
|
2367
|
-
return /* @__PURE__ */
|
|
2373
|
+
return /* @__PURE__ */ a(u, { direction: "column", gap: 24, sx: { p: 8, pt: 24 }, children: [
|
|
2368
2374
|
/* @__PURE__ */ e(
|
|
2369
2375
|
xe,
|
|
2370
2376
|
{
|
|
2371
|
-
cardState:
|
|
2372
|
-
description:
|
|
2373
|
-
drawerFor:
|
|
2374
|
-
title:
|
|
2377
|
+
cardState: i.cardState,
|
|
2378
|
+
description: i.description,
|
|
2379
|
+
drawerFor: de.SaveEnoughToLiveOn,
|
|
2380
|
+
title: i.title
|
|
2375
2381
|
}
|
|
2376
2382
|
),
|
|
2377
2383
|
/* @__PURE__ */ e(
|
|
2378
2384
|
xe,
|
|
2379
2385
|
{
|
|
2380
|
-
cardState:
|
|
2381
|
-
description:
|
|
2382
|
-
drawerFor:
|
|
2383
|
-
title:
|
|
2386
|
+
cardState: c.cardState,
|
|
2387
|
+
description: c.description,
|
|
2388
|
+
drawerFor: de.MaintainEmergencySavings,
|
|
2389
|
+
title: c.title
|
|
2384
2390
|
}
|
|
2385
2391
|
)
|
|
2386
2392
|
] });
|
|
2387
2393
|
}, Gr = S(Er), Hr = () => {
|
|
2388
|
-
const { healthScore: t } = F(), { finstrong: r } =
|
|
2389
|
-
const
|
|
2394
|
+
const { healthScore: t } = F(), { finstrong: r } = w(), { key_indicators_borrow: n } = r, { user: o } = Q(), s = (l) => {
|
|
2395
|
+
const d = zn(l), _ = {
|
|
2390
2396
|
GOOD: n.manage_debit_good_description,
|
|
2391
2397
|
FAIR: n.manage_debit_fair_description,
|
|
2392
2398
|
OFF_TRACK: n.manage_debit_off_track_description,
|
|
2393
2399
|
MISSING: n.manage_debit_missing_description
|
|
2394
|
-
},
|
|
2400
|
+
}, h = d === "FAIR" || d === "OFF_TRACK" ? Y(_[d], l) : _[d];
|
|
2395
2401
|
return {
|
|
2396
|
-
cardState:
|
|
2397
|
-
description:
|
|
2402
|
+
cardState: d,
|
|
2403
|
+
description: h,
|
|
2398
2404
|
title: n.manage_debit_title
|
|
2399
2405
|
};
|
|
2400
|
-
},
|
|
2401
|
-
const
|
|
2406
|
+
}, i = (l) => {
|
|
2407
|
+
const d = Ct(l), _ = {
|
|
2402
2408
|
GOOD: n.credit_score_good_description,
|
|
2403
2409
|
FAIR: n.credit_score_fair_description,
|
|
2404
2410
|
OFF_TRACK: n.credit_score_off_track_description,
|
|
2405
2411
|
MISSING: n.credit_score_missing_description
|
|
2406
|
-
},
|
|
2412
|
+
}, h = d === "MISSING" ? _[d] : Y(_[d], l);
|
|
2407
2413
|
return {
|
|
2408
|
-
cardState:
|
|
2409
|
-
description:
|
|
2414
|
+
cardState: d,
|
|
2415
|
+
description: h,
|
|
2410
2416
|
title: n.credit_score_title
|
|
2411
2417
|
};
|
|
2412
|
-
}, { manageDebtStatus:
|
|
2413
|
-
const l = t.debt_to_income_ratio !== null ? Math.round(t.debt_to_income_ratio * 100) : null,
|
|
2418
|
+
}, { manageDebtStatus: c, creditScoreStatus: p } = m.useMemo(() => {
|
|
2419
|
+
const l = t.debt_to_income_ratio !== null ? Math.round(t.debt_to_income_ratio * 100) : null, d = s(l), _ = i(o.credit_score || null);
|
|
2414
2420
|
return {
|
|
2415
|
-
manageDebtStatus:
|
|
2416
|
-
creditScoreStatus:
|
|
2421
|
+
manageDebtStatus: d,
|
|
2422
|
+
creditScoreStatus: _
|
|
2417
2423
|
};
|
|
2418
2424
|
}, [t.debt_to_income_ratio, o.credit_score, n, r]);
|
|
2419
|
-
return /* @__PURE__ */
|
|
2425
|
+
return /* @__PURE__ */ a(u, { direction: "column", gap: 24, sx: { p: 8, pt: 24 }, children: [
|
|
2420
2426
|
/* @__PURE__ */ e(
|
|
2421
2427
|
xe,
|
|
2422
2428
|
{
|
|
2423
|
-
cardState:
|
|
2424
|
-
description:
|
|
2425
|
-
drawerFor:
|
|
2426
|
-
title:
|
|
2429
|
+
cardState: c.cardState,
|
|
2430
|
+
description: c.description,
|
|
2431
|
+
drawerFor: de.HaveManageableDebt,
|
|
2432
|
+
title: c.title
|
|
2427
2433
|
}
|
|
2428
2434
|
),
|
|
2429
2435
|
/* @__PURE__ */ e(
|
|
2430
2436
|
xe,
|
|
2431
2437
|
{
|
|
2432
|
-
cardState:
|
|
2433
|
-
description:
|
|
2434
|
-
drawerFor:
|
|
2435
|
-
title:
|
|
2438
|
+
cardState: p.cardState,
|
|
2439
|
+
description: p.description,
|
|
2440
|
+
drawerFor: de.HaveAGoodCreditScore,
|
|
2441
|
+
title: p.title
|
|
2436
2442
|
}
|
|
2437
2443
|
)
|
|
2438
2444
|
] });
|
|
2439
|
-
}, Nr = S(Hr), Kr = () => {
|
|
2440
|
-
const [
|
|
2441
|
-
return /* @__PURE__ */
|
|
2442
|
-
/* @__PURE__ */
|
|
2445
|
+
}, Nr = S(Hr), Kr = ({ onPrimaryCtaClick: t }) => {
|
|
2446
|
+
const [r, n] = m.useState(0), { finstrong: o } = w();
|
|
2447
|
+
return /* @__PURE__ */ a(E, { children: [
|
|
2448
|
+
/* @__PURE__ */ a(
|
|
2443
2449
|
qe,
|
|
2444
2450
|
{
|
|
2445
2451
|
"aria-label": "Key Indicators",
|
|
2446
2452
|
centered: !0,
|
|
2447
|
-
onChange: (
|
|
2453
|
+
onChange: (s, i) => n(i),
|
|
2448
2454
|
sx: {
|
|
2449
2455
|
mb: 0,
|
|
2450
2456
|
"& .MuiTab-root": {
|
|
@@ -2452,59 +2458,59 @@ const B = {
|
|
|
2452
2458
|
}
|
|
2453
2459
|
},
|
|
2454
2460
|
textColor: "primary",
|
|
2455
|
-
value:
|
|
2461
|
+
value: r,
|
|
2456
2462
|
variant: "fullWidth",
|
|
2457
2463
|
children: [
|
|
2458
2464
|
/* @__PURE__ */ e(
|
|
2459
|
-
|
|
2465
|
+
ce,
|
|
2460
2466
|
{
|
|
2461
2467
|
"aria-controls": "spend-details-tabpanel-0",
|
|
2462
2468
|
icon: /* @__PURE__ */ e(Ke, { sx: { mr: 8 } }),
|
|
2463
2469
|
iconPosition: "start",
|
|
2464
2470
|
id: "spend-details-tab-0",
|
|
2465
|
-
label:
|
|
2471
|
+
label: o.key_indicators_spend.title,
|
|
2466
2472
|
sx: { minHeight: 44 }
|
|
2467
2473
|
}
|
|
2468
2474
|
),
|
|
2469
2475
|
/* @__PURE__ */ e(
|
|
2470
|
-
|
|
2476
|
+
ce,
|
|
2471
2477
|
{
|
|
2472
2478
|
"aria-controls": "save-details-tabpanel-1",
|
|
2473
2479
|
icon: /* @__PURE__ */ e(fn, { sx: { mr: 8 } }),
|
|
2474
2480
|
iconPosition: "start",
|
|
2475
2481
|
id: "save-details-tab-1",
|
|
2476
|
-
label:
|
|
2482
|
+
label: o.key_indicators_save.title,
|
|
2477
2483
|
sx: { minHeight: 44 }
|
|
2478
2484
|
}
|
|
2479
2485
|
),
|
|
2480
2486
|
/* @__PURE__ */ e(
|
|
2481
|
-
|
|
2487
|
+
ce,
|
|
2482
2488
|
{
|
|
2483
2489
|
"aria-controls": "borrow-details-tabpanel-2",
|
|
2484
2490
|
icon: /* @__PURE__ */ e(xn, { sx: { mr: 8 } }),
|
|
2485
2491
|
iconPosition: "start",
|
|
2486
2492
|
id: "borrow-details-tab-2",
|
|
2487
|
-
label:
|
|
2493
|
+
label: o.key_indicators_borrow.title,
|
|
2488
2494
|
sx: { minHeight: 44 }
|
|
2489
2495
|
}
|
|
2490
2496
|
)
|
|
2491
2497
|
]
|
|
2492
2498
|
}
|
|
2493
2499
|
),
|
|
2494
|
-
/* @__PURE__ */ e(
|
|
2495
|
-
/* @__PURE__ */ e(
|
|
2496
|
-
/* @__PURE__ */ e(
|
|
2500
|
+
/* @__PURE__ */ e(le, { index: 0, name: "spend-details", value: r, children: /* @__PURE__ */ e(zr, { onPrimaryCtaClick: t }) }),
|
|
2501
|
+
/* @__PURE__ */ e(le, { index: 1, name: "save-details", value: r, children: /* @__PURE__ */ e(Gr, {}) }),
|
|
2502
|
+
/* @__PURE__ */ e(le, { index: 2, name: "borrow-details", value: r, children: /* @__PURE__ */ e(Nr, {}) })
|
|
2497
2503
|
] });
|
|
2498
2504
|
}, jr = S(Kr), Yr = ({ onClick: t }) => {
|
|
2499
|
-
const { finstrong: r } =
|
|
2500
|
-
return n ? /* @__PURE__ */
|
|
2505
|
+
const { finstrong: r } = w(), { isCopyLoaded: n } = j();
|
|
2506
|
+
return n ? /* @__PURE__ */ a(u, { sx: { alignItems: "center", gap: 12, pt: 12, pb: 32 }, children: [
|
|
2501
2507
|
/* @__PURE__ */ e(bt, { size: 48 }),
|
|
2502
|
-
/* @__PURE__ */
|
|
2508
|
+
/* @__PURE__ */ a(u, { sx: { alignItems: "center", gap: 4, textAlign: "center" }, children: [
|
|
2503
2509
|
/* @__PURE__ */ e(N, { children: r.missing_data_title }),
|
|
2504
2510
|
/* @__PURE__ */ e(k, { sx: { width: { sm: 348 } }, variant: "subtitle1", children: r.missing_data_description })
|
|
2505
2511
|
] }),
|
|
2506
|
-
/* @__PURE__ */ e(
|
|
2507
|
-
|
|
2512
|
+
/* @__PURE__ */ e(v, { children: /* @__PURE__ */ e(
|
|
2513
|
+
z,
|
|
2508
2514
|
{
|
|
2509
2515
|
endIcon: /* @__PURE__ */ e(Z, {}),
|
|
2510
2516
|
onClick: t,
|
|
@@ -2527,42 +2533,42 @@ const B = {
|
|
|
2527
2533
|
frequency: r,
|
|
2528
2534
|
secondDay: n,
|
|
2529
2535
|
incomeTransactions: o,
|
|
2530
|
-
setCurrentStep:
|
|
2531
|
-
setFirstDay:
|
|
2532
|
-
setFrequency:
|
|
2533
|
-
setSecondDay:
|
|
2536
|
+
setCurrentStep: s,
|
|
2537
|
+
setFirstDay: i,
|
|
2538
|
+
setFrequency: c,
|
|
2539
|
+
setSecondDay: p,
|
|
2534
2540
|
transaction: l
|
|
2535
|
-
}) => /* @__PURE__ */
|
|
2536
|
-
/* @__PURE__ */
|
|
2537
|
-
!!o.length && /* @__PURE__ */ e(
|
|
2538
|
-
if (
|
|
2539
|
-
const
|
|
2540
|
-
return
|
|
2541
|
-
/* @__PURE__ */
|
|
2542
|
-
|
|
2543
|
-
/* @__PURE__ */ e(Bt, { transaction:
|
|
2544
|
-
/* @__PURE__ */ e(
|
|
2545
|
-
] },
|
|
2546
|
-
),
|
|
2541
|
+
}) => /* @__PURE__ */ a(m.Fragment, { children: [
|
|
2542
|
+
/* @__PURE__ */ a(u, { children: [
|
|
2543
|
+
!!o.length && /* @__PURE__ */ e(v, { sx: { pb: 24 }, children: o.reduce((d, _, h) => {
|
|
2544
|
+
if (_.guid === l.guid) return d;
|
|
2545
|
+
const y = Ne(h, o), f = Ft(h, o);
|
|
2546
|
+
return d.push(
|
|
2547
|
+
/* @__PURE__ */ a(m.Fragment, { children: [
|
|
2548
|
+
y && /* @__PURE__ */ e(Pt, { children: Ze(_.date) }),
|
|
2549
|
+
/* @__PURE__ */ e(Bt, { transaction: _ }),
|
|
2550
|
+
/* @__PURE__ */ e(oe, { sx: { ml: f ? 44 : 0 } })
|
|
2551
|
+
] }, _.guid)
|
|
2552
|
+
), d;
|
|
2547
2553
|
}, []) }),
|
|
2548
2554
|
/* @__PURE__ */ e(
|
|
2549
2555
|
fo,
|
|
2550
2556
|
{
|
|
2551
2557
|
firstDay: t,
|
|
2552
2558
|
frequency: r,
|
|
2553
|
-
onFirstDayChange:
|
|
2554
|
-
onFrequencyChange:
|
|
2555
|
-
onSecondDayChange:
|
|
2559
|
+
onFirstDayChange: i,
|
|
2560
|
+
onFrequencyChange: c,
|
|
2561
|
+
onSecondDayChange: p,
|
|
2556
2562
|
secondDay: n,
|
|
2557
2563
|
transaction: l
|
|
2558
2564
|
}
|
|
2559
2565
|
)
|
|
2560
2566
|
] }),
|
|
2561
|
-
/* @__PURE__ */ e(
|
|
2562
|
-
|
|
2567
|
+
/* @__PURE__ */ e(v, { sx: { px: 24 }, children: /* @__PURE__ */ e(
|
|
2568
|
+
z,
|
|
2563
2569
|
{
|
|
2564
2570
|
fullWidth: !0,
|
|
2565
|
-
onClick: () =>
|
|
2571
|
+
onClick: () => s({ step: T.MonthlyIncome, type: "main" }),
|
|
2566
2572
|
startIcon: /* @__PURE__ */ e(ft, {}),
|
|
2567
2573
|
children: Xr.add_more_income
|
|
2568
2574
|
}
|
|
@@ -2570,10 +2576,10 @@ const B = {
|
|
|
2570
2576
|
] }), Ur = S(qr), Zr = {
|
|
2571
2577
|
select_date: "Select Date"
|
|
2572
2578
|
}, Qr = ({ selectedDate: t, setSelectedDate: r }) => {
|
|
2573
|
-
const n =
|
|
2574
|
-
r(Math.floor(new Date(
|
|
2579
|
+
const n = G(), o = (s) => {
|
|
2580
|
+
r(Math.floor(new Date(s).getTime() / 1e3));
|
|
2575
2581
|
};
|
|
2576
|
-
return /* @__PURE__ */ e(
|
|
2582
|
+
return /* @__PURE__ */ e(v, { sx: { p: 24 }, children: /* @__PURE__ */ e(Co, { dateAdapter: Wt, children: /* @__PURE__ */ e(
|
|
2577
2583
|
vo,
|
|
2578
2584
|
{
|
|
2579
2585
|
disableFuture: !0,
|
|
@@ -2607,7 +2613,7 @@ const B = {
|
|
|
2607
2613
|
credit_score: "Credit Score"
|
|
2608
2614
|
}, ta = ({ creditScore: t, setCreditScore: r }) => {
|
|
2609
2615
|
const n = !isNaN(t);
|
|
2610
|
-
return /* @__PURE__ */ e(
|
|
2616
|
+
return /* @__PURE__ */ e(v, { sx: { p: 24 }, children: /* @__PURE__ */ e(
|
|
2611
2617
|
Oe,
|
|
2612
2618
|
{
|
|
2613
2619
|
error: !n,
|
|
@@ -2622,9 +2628,9 @@ const B = {
|
|
|
2622
2628
|
value: n ? t : ""
|
|
2623
2629
|
}
|
|
2624
2630
|
) });
|
|
2625
|
-
}, na = S(ta), Yt = ({ value: t, completeCopy: r }) => /* @__PURE__ */
|
|
2631
|
+
}, na = S(ta), Yt = ({ value: t, completeCopy: r }) => /* @__PURE__ */ a(u, { sx: { gap: 8 }, children: [
|
|
2626
2632
|
/* @__PURE__ */ e(u, { sx: { flexDirection: "row", gap: 4 }, children: Array.from({ length: 4 }).map((n, o) => /* @__PURE__ */ e(
|
|
2627
|
-
|
|
2633
|
+
v,
|
|
2628
2634
|
{
|
|
2629
2635
|
sx: {
|
|
2630
2636
|
bgcolor: o < t ? "primary.main" : "neutral.light",
|
|
@@ -2635,7 +2641,7 @@ const B = {
|
|
|
2635
2641
|
},
|
|
2636
2642
|
o
|
|
2637
2643
|
)) }),
|
|
2638
|
-
/* @__PURE__ */
|
|
2644
|
+
/* @__PURE__ */ a(I, { sx: { color: "text.secondary" }, variant: "body2", children: [
|
|
2639
2645
|
t / 4 * 100,
|
|
2640
2646
|
"% ",
|
|
2641
2647
|
r
|
|
@@ -2645,14 +2651,14 @@ const B = {
|
|
|
2645
2651
|
primaryText: r,
|
|
2646
2652
|
secondaryText: n,
|
|
2647
2653
|
value: o
|
|
2648
|
-
}) => /* @__PURE__ */
|
|
2649
|
-
/* @__PURE__ */
|
|
2654
|
+
}) => /* @__PURE__ */ a(u, { sx: { gap: 20, p: 24 }, children: [
|
|
2655
|
+
/* @__PURE__ */ a(u, { sx: { gap: 8 }, children: [
|
|
2650
2656
|
/* @__PURE__ */ e(N, { children: r }),
|
|
2651
2657
|
/* @__PURE__ */ e(k, { variant: "subtitle1", children: n })
|
|
2652
2658
|
] }),
|
|
2653
2659
|
/* @__PURE__ */ e(Yt, { completeCopy: t, value: o })
|
|
2654
2660
|
] }), ht = {
|
|
2655
|
-
step:
|
|
2661
|
+
step: T.ConnectAccounts,
|
|
2656
2662
|
type: "main"
|
|
2657
2663
|
}, P = {
|
|
2658
2664
|
add_accounts: "Add Accounts",
|
|
@@ -2673,63 +2679,63 @@ const B = {
|
|
|
2673
2679
|
do_it_later: "Do It Later",
|
|
2674
2680
|
next: "Next"
|
|
2675
2681
|
}, ra = ({ isOpen: t, onClose: r }) => {
|
|
2676
|
-
const { visibleAccounts: n } =
|
|
2682
|
+
const { visibleAccounts: n } = ke(), { calculateHealthScore: o } = F(), { finstrong: s } = w(), { setSelectedAccounts: i } = j(), { addRepeatingTransaction: c, setDateRange: p } = Ve(), { filter: l, setFilter: d, transactions: _ } = jn(), { user: h, userProfile: y, updateUser: f, updateUserProfile: x } = Q(), [b, D] = m.useState(h.credit_score || 0), [g, C] = m.useState(
|
|
2677
2683
|
ht
|
|
2678
|
-
), [M, $] = m.useState(1), [
|
|
2684
|
+
), [M, $] = m.useState(1), [H, O] = m.useState(Ot.EveryMonth), [W, V] = m.useState([]), [ee, pe] = m.useState(!1), [ue, _e] = m.useState(!1), [X, he] = m.useState(h.birthday), [ae, Me] = m.useState(15), [q, Je] = m.useState("");
|
|
2679
2685
|
m.useEffect(() => {
|
|
2680
|
-
|
|
2686
|
+
p({ start: Lt(dt()), end: $t(dt()) });
|
|
2681
2687
|
}, []), m.useEffect(() => {
|
|
2682
|
-
|
|
2688
|
+
d({
|
|
2683
2689
|
accounts: n.map((A) => A.guid),
|
|
2684
2690
|
dateRange: {
|
|
2685
2691
|
start: bo(/* @__PURE__ */ new Date(), 90),
|
|
2686
2692
|
end: /* @__PURE__ */ new Date()
|
|
2687
2693
|
},
|
|
2688
2694
|
custom: pt
|
|
2689
|
-
}),
|
|
2695
|
+
}), i(n);
|
|
2690
2696
|
}, [n]);
|
|
2691
2697
|
const et = m.useMemo(
|
|
2692
|
-
() =>
|
|
2693
|
-
[q,
|
|
2698
|
+
() => _.find((A) => A.guid === q),
|
|
2699
|
+
[q, _]
|
|
2694
2700
|
), Vt = m.useMemo(() => ({
|
|
2695
|
-
[
|
|
2696
|
-
[
|
|
2697
|
-
[
|
|
2698
|
-
[
|
|
2699
|
-
})[g.step], [
|
|
2701
|
+
[T.ConnectAccounts]: !0,
|
|
2702
|
+
[T.MonthlyIncome]: !!q,
|
|
2703
|
+
[T.Birthday]: !!h.birthday || !!X,
|
|
2704
|
+
[T.CreditScore]: !!h.credit_score || !!b
|
|
2705
|
+
})[g.step], [b, g, X, q, h]), ie = n.length > 0, Xt = m.useMemo(() => {
|
|
2700
2706
|
const { step: A } = g;
|
|
2701
2707
|
let R = 0;
|
|
2702
|
-
return A >=
|
|
2703
|
-
}, [g.step,
|
|
2704
|
-
|
|
2708
|
+
return A >= T.MonthlyIncome && ie && R++, A >= T.Birthday && W.length && R++, A >= T.CreditScore && (h.birthday || h.credit_score) && R++, R;
|
|
2709
|
+
}, [g.step, ie, W.length, h.birthday, h.credit_score]), qt = (A) => {
|
|
2710
|
+
d({
|
|
2705
2711
|
...l,
|
|
2706
2712
|
custom: (R) => A ? So(R, A) : pt(R)
|
|
2707
2713
|
});
|
|
2708
2714
|
}, Ut = {
|
|
2709
|
-
[
|
|
2710
|
-
main:
|
|
2711
|
-
mainActionContent:
|
|
2715
|
+
[T.ConnectAccounts]: {
|
|
2716
|
+
main: ie ? /* @__PURE__ */ e(Nt, { shouldShowBalance: !1 }) : null,
|
|
2717
|
+
mainActionContent: ie ? P.next : P.add_accounts,
|
|
2712
2718
|
primaryText: P.connect_your_accounts_primary,
|
|
2713
2719
|
secondaryText: P.connect_your_accounts_secondary
|
|
2714
2720
|
},
|
|
2715
|
-
[
|
|
2721
|
+
[T.MonthlyIncome]: {
|
|
2716
2722
|
detail: /* @__PURE__ */ e(
|
|
2717
2723
|
Ur,
|
|
2718
2724
|
{
|
|
2719
2725
|
firstDay: M,
|
|
2720
|
-
frequency:
|
|
2721
|
-
incomeTransactions:
|
|
2722
|
-
secondDay:
|
|
2726
|
+
frequency: H,
|
|
2727
|
+
incomeTransactions: W,
|
|
2728
|
+
secondDay: ae,
|
|
2723
2729
|
setCurrentStep: (A) => {
|
|
2724
|
-
|
|
2725
|
-
if (R.some((
|
|
2726
|
-
const Ie =
|
|
2727
|
-
return Ie ? [...R, { ...Ie, firstDay: M, frequency:
|
|
2730
|
+
C(A), V((R) => {
|
|
2731
|
+
if (R.some((se) => se.guid === q)) return R.filter((se) => se.guid !== q);
|
|
2732
|
+
const Ie = _.find((se) => se.guid === q);
|
|
2733
|
+
return Ie ? [...R, { ...Ie, firstDay: M, frequency: H, secondDay: ae }] : R;
|
|
2728
2734
|
});
|
|
2729
2735
|
},
|
|
2730
2736
|
setFirstDay: $,
|
|
2731
|
-
setFrequency:
|
|
2732
|
-
setSecondDay:
|
|
2737
|
+
setFrequency: O,
|
|
2738
|
+
setSecondDay: Me,
|
|
2733
2739
|
transaction: et
|
|
2734
2740
|
}
|
|
2735
2741
|
),
|
|
@@ -2739,7 +2745,7 @@ const B = {
|
|
|
2739
2745
|
{
|
|
2740
2746
|
onSearch: qt,
|
|
2741
2747
|
onSelected: (A) => {
|
|
2742
|
-
|
|
2748
|
+
C({ step: T.MonthlyIncome, type: "detail" }), Je(A);
|
|
2743
2749
|
}
|
|
2744
2750
|
}
|
|
2745
2751
|
),
|
|
@@ -2747,68 +2753,68 @@ const B = {
|
|
|
2747
2753
|
primaryText: P.add_income_primary,
|
|
2748
2754
|
secondaryText: P.add_income_secondary
|
|
2749
2755
|
},
|
|
2750
|
-
[
|
|
2751
|
-
main: /* @__PURE__ */ e(Jr, { selectedDate: X, setSelectedDate:
|
|
2756
|
+
[T.Birthday]: {
|
|
2757
|
+
main: /* @__PURE__ */ e(Jr, { selectedDate: X, setSelectedDate: he }),
|
|
2752
2758
|
mainActionContent: P.next,
|
|
2753
2759
|
primaryText: P.birthday_primary,
|
|
2754
2760
|
secondaryText: P.birthday_secondary
|
|
2755
2761
|
},
|
|
2756
|
-
[
|
|
2757
|
-
main: /* @__PURE__ */ e(na, { creditScore:
|
|
2762
|
+
[T.CreditScore]: {
|
|
2763
|
+
main: /* @__PURE__ */ e(na, { creditScore: b, setCreditScore: D }),
|
|
2758
2764
|
mainActionContent: P.next,
|
|
2759
2765
|
primaryText: P.credit_score_primary,
|
|
2760
2766
|
secondaryText: P.credit_score_secondary
|
|
2761
2767
|
}
|
|
2762
2768
|
}, tt = () => {
|
|
2763
|
-
|
|
2769
|
+
C(ht), pe(!1), Je(""), r();
|
|
2764
2770
|
}, nt = async () => {
|
|
2765
|
-
|
|
2771
|
+
pe(!0), await en(W), await o(), await x({ ...y, has_completed_finstrong_onboarding: !0 }), tt();
|
|
2766
2772
|
}, Zt = () => {
|
|
2767
|
-
if (g.step ===
|
|
2773
|
+
if (g.step === T.CreditScore) {
|
|
2768
2774
|
nt();
|
|
2769
2775
|
return;
|
|
2770
2776
|
}
|
|
2771
|
-
|
|
2777
|
+
C({ step: g.step + 1, type: "main" });
|
|
2772
2778
|
}, Qt = () => {
|
|
2773
2779
|
const { step: A } = g, R = A + 1;
|
|
2774
2780
|
switch (A) {
|
|
2775
|
-
case
|
|
2776
|
-
X && X !==
|
|
2781
|
+
case T.Birthday:
|
|
2782
|
+
X && X !== h.birthday && f({ ...h, birthday: X });
|
|
2777
2783
|
break;
|
|
2778
|
-
case
|
|
2779
|
-
|
|
2784
|
+
case T.CreditScore:
|
|
2785
|
+
b && b !== h.credit_score && f({ ...h, credit_score: b }), nt();
|
|
2780
2786
|
return;
|
|
2781
|
-
case
|
|
2782
|
-
q &&
|
|
2787
|
+
case T.MonthlyIncome:
|
|
2788
|
+
q && W.findIndex(({ guid: ge }) => ge === q) === -1 && V((ge) => [
|
|
2783
2789
|
...ge,
|
|
2784
|
-
{ ...et, firstDay: M, frequency:
|
|
2790
|
+
{ ...et, firstDay: M, frequency: H, secondDay: ae }
|
|
2785
2791
|
]);
|
|
2786
2792
|
break;
|
|
2787
|
-
case
|
|
2788
|
-
if (!
|
|
2789
|
-
|
|
2793
|
+
case T.ConnectAccounts:
|
|
2794
|
+
if (!ie) {
|
|
2795
|
+
_e(!0);
|
|
2790
2796
|
return;
|
|
2791
2797
|
}
|
|
2792
2798
|
break;
|
|
2793
2799
|
}
|
|
2794
|
-
R in
|
|
2800
|
+
R in T && C({ step: R, type: "main" });
|
|
2795
2801
|
}, Jt = () => {
|
|
2796
2802
|
const { step: A, type: R } = g;
|
|
2797
2803
|
if (R === "detail") {
|
|
2798
|
-
|
|
2804
|
+
C({ step: A, type: "main" });
|
|
2799
2805
|
return;
|
|
2800
2806
|
}
|
|
2801
|
-
if (A ===
|
|
2802
|
-
|
|
2807
|
+
if (A === T.Birthday && W.length) {
|
|
2808
|
+
C({ step: A - 1, type: "detail" });
|
|
2803
2809
|
return;
|
|
2804
2810
|
}
|
|
2805
|
-
A >
|
|
2811
|
+
A > T.ConnectAccounts && C({ step: A - 1, type: "main" });
|
|
2806
2812
|
}, en = async (A) => {
|
|
2807
2813
|
for (const R of A) {
|
|
2808
2814
|
const {
|
|
2809
2815
|
account_guid: ge,
|
|
2810
2816
|
amount: Ie,
|
|
2811
|
-
date:
|
|
2817
|
+
date: se,
|
|
2812
2818
|
description: on,
|
|
2813
2819
|
feed_description: rn,
|
|
2814
2820
|
firstDay: an,
|
|
@@ -2817,7 +2823,7 @@ const B = {
|
|
|
2817
2823
|
merchant_guid: cn,
|
|
2818
2824
|
payee: ln,
|
|
2819
2825
|
transaction_type: dn
|
|
2820
|
-
} = R, pn = Jn(ot, yo(
|
|
2826
|
+
} = R, pn = Jn(ot, yo(se)), un = {
|
|
2821
2827
|
account_guid: ge,
|
|
2822
2828
|
amount: Ie,
|
|
2823
2829
|
created_by: 0,
|
|
@@ -2829,17 +2835,17 @@ const B = {
|
|
|
2829
2835
|
repeating_transaction_type: Rt.Income,
|
|
2830
2836
|
second_recurrence_day: sn,
|
|
2831
2837
|
transaction_type: dn,
|
|
2832
|
-
user_guid:
|
|
2838
|
+
user_guid: h.guid
|
|
2833
2839
|
};
|
|
2834
|
-
await
|
|
2840
|
+
await c(un, R);
|
|
2835
2841
|
}
|
|
2836
|
-
}, me = Ut[g.step], De = g.step ===
|
|
2842
|
+
}, me = Ut[g.step], De = g.step === T.ConnectAccounts, tn = {
|
|
2837
2843
|
fullWidth: !0,
|
|
2838
|
-
...De && !
|
|
2839
|
-
}, nn = !De || De && !
|
|
2840
|
-
return /* @__PURE__ */
|
|
2841
|
-
/* @__PURE__ */
|
|
2842
|
-
|
|
2844
|
+
...De && !ie && { startIcon: /* @__PURE__ */ e(ft, {}) }
|
|
2845
|
+
}, nn = !De || De && !ie;
|
|
2846
|
+
return /* @__PURE__ */ a(m.Fragment, { children: [
|
|
2847
|
+
/* @__PURE__ */ a(
|
|
2848
|
+
ne,
|
|
2843
2849
|
{
|
|
2844
2850
|
footerStyles: { px: 24, py: 16 },
|
|
2845
2851
|
hasSecondaryAction: !De,
|
|
@@ -2851,26 +2857,26 @@ const B = {
|
|
|
2851
2857
|
primaryText: me?.mainActionContent,
|
|
2852
2858
|
secondaryColor: "primary",
|
|
2853
2859
|
secondaryText: P.back,
|
|
2854
|
-
title:
|
|
2855
|
-
...!
|
|
2860
|
+
title: s.title,
|
|
2861
|
+
...!ee && { onPrimaryAction: Qt },
|
|
2856
2862
|
children: [
|
|
2857
|
-
|
|
2863
|
+
ee && /* @__PURE__ */ a(u, { sx: { alignItems: "center", gap: 24, position: "relative", px: 16, top: 126 }, children: [
|
|
2858
2864
|
/* @__PURE__ */ e(Pe, { children: P.calculate_primary }),
|
|
2859
2865
|
/* @__PURE__ */ e(k, { sx: { textAlign: "center" }, variant: "subtitle1", children: P.calculate_secondary })
|
|
2860
2866
|
] }),
|
|
2861
|
-
me && !
|
|
2867
|
+
me && !ee && /* @__PURE__ */ a(m.Fragment, { children: [
|
|
2862
2868
|
/* @__PURE__ */ e(
|
|
2863
2869
|
oa,
|
|
2864
2870
|
{
|
|
2865
|
-
completeCopy:
|
|
2871
|
+
completeCopy: s.complete,
|
|
2866
2872
|
primaryText: me.primaryText,
|
|
2867
2873
|
secondaryText: me.secondaryText,
|
|
2868
2874
|
value: Xt
|
|
2869
2875
|
}
|
|
2870
2876
|
),
|
|
2871
|
-
g.type === "main" && /* @__PURE__ */
|
|
2877
|
+
g.type === "main" && /* @__PURE__ */ a(v, { children: [
|
|
2872
2878
|
me.main,
|
|
2873
|
-
nn && /* @__PURE__ */ e(u, { sx: { alignItems: "center", px: 24, py: 12 }, children: /* @__PURE__ */ e(
|
|
2879
|
+
nn && /* @__PURE__ */ e(u, { sx: { alignItems: "center", px: 24, py: 12 }, children: /* @__PURE__ */ e(z, { fullWidth: !0, onClick: Zt, children: P.do_it_later }) })
|
|
2874
2880
|
] }),
|
|
2875
2881
|
g.type === "detail" && me.detail
|
|
2876
2882
|
] })
|
|
@@ -2878,10 +2884,10 @@ const B = {
|
|
|
2878
2884
|
}
|
|
2879
2885
|
),
|
|
2880
2886
|
/* @__PURE__ */ e(
|
|
2881
|
-
|
|
2887
|
+
re,
|
|
2882
2888
|
{
|
|
2883
|
-
onClose: () =>
|
|
2884
|
-
showConnectWidget:
|
|
2889
|
+
onClose: () => _e(!1),
|
|
2890
|
+
showConnectWidget: ue,
|
|
2885
2891
|
title: P.connect_accounts
|
|
2886
2892
|
}
|
|
2887
2893
|
)
|
|
@@ -2892,8 +2898,8 @@ const B = {
|
|
|
2892
2898
|
get_started: "Get Started"
|
|
2893
2899
|
}, ia = () => {
|
|
2894
2900
|
const [t, r] = m.useState(!1);
|
|
2895
|
-
return /* @__PURE__ */
|
|
2896
|
-
/* @__PURE__ */
|
|
2901
|
+
return /* @__PURE__ */ a(m.Fragment, { children: [
|
|
2902
|
+
/* @__PURE__ */ a(
|
|
2897
2903
|
u,
|
|
2898
2904
|
{
|
|
2899
2905
|
sx: {
|
|
@@ -2904,30 +2910,30 @@ const B = {
|
|
|
2904
2910
|
px: 16
|
|
2905
2911
|
},
|
|
2906
2912
|
children: [
|
|
2907
|
-
/* @__PURE__ */
|
|
2908
|
-
/* @__PURE__ */ e(
|
|
2909
|
-
/* @__PURE__ */
|
|
2913
|
+
/* @__PURE__ */ a(u, { sx: { alignItems: { sm: "center" }, gap: 24, width: "100%" }, children: [
|
|
2914
|
+
/* @__PURE__ */ e(v, { sx: { textAlign: "center" }, children: /* @__PURE__ */ e(Sn, { size: 72 }) }),
|
|
2915
|
+
/* @__PURE__ */ a(u, { sx: { gap: 4, textAlign: "center", width: { sm: 400 } }, children: [
|
|
2910
2916
|
/* @__PURE__ */ e(Pe, { children: Ge.onboarding_title }),
|
|
2911
2917
|
/* @__PURE__ */ e(k, { sx: { color: "text.secondary" }, variant: "subtitle1", children: Ge.onboarding_subtitle })
|
|
2912
2918
|
] })
|
|
2913
2919
|
] }),
|
|
2914
|
-
/* @__PURE__ */ e(
|
|
2920
|
+
/* @__PURE__ */ e(z, { onClick: () => r(!0), variant: "contained", children: Ge.get_started })
|
|
2915
2921
|
]
|
|
2916
2922
|
}
|
|
2917
2923
|
),
|
|
2918
2924
|
/* @__PURE__ */ e(aa, { isOpen: t, onClose: () => r(!1) })
|
|
2919
2925
|
] });
|
|
2920
2926
|
}, sa = ({ isOpen: t, onClose: r }) => {
|
|
2921
|
-
const { finstrong: n } =
|
|
2922
|
-
|
|
2927
|
+
const { finstrong: n } = w(), o = G(), { updateUser: s, user: i } = Q(), [c, p] = m.useState(i.birthday), l = (_) => {
|
|
2928
|
+
p(Math.floor(new Date(_).getTime() / 1e3));
|
|
2923
2929
|
};
|
|
2924
2930
|
return /* @__PURE__ */ e(
|
|
2925
|
-
|
|
2931
|
+
ne,
|
|
2926
2932
|
{
|
|
2927
2933
|
isOpen: t,
|
|
2928
2934
|
onClose: r,
|
|
2929
2935
|
onPrimaryAction: () => {
|
|
2930
|
-
!
|
|
2936
|
+
!c || c === i.birthday || (s({ ...i, birthday: c }), r());
|
|
2931
2937
|
},
|
|
2932
2938
|
onSecondaryAction: r,
|
|
2933
2939
|
title: n.date_of_birth,
|
|
@@ -2961,97 +2967,97 @@ const B = {
|
|
|
2961
2967
|
"&:hover": { bgcolor: fe(o.palette.primary.light, 0.1) }
|
|
2962
2968
|
}
|
|
2963
2969
|
},
|
|
2964
|
-
value:
|
|
2970
|
+
value: c ? new Date(c * 1e3) : /* @__PURE__ */ new Date()
|
|
2965
2971
|
}
|
|
2966
2972
|
) })
|
|
2967
2973
|
}
|
|
2968
2974
|
);
|
|
2969
2975
|
}, ca = S(sa), la = ({ isOpen: t, onClose: r }) => {
|
|
2970
|
-
const { visibleFinstrongAccounts: n } =
|
|
2976
|
+
const { visibleFinstrongAccounts: n } = ke(), {
|
|
2971
2977
|
accounts: o,
|
|
2972
|
-
common:
|
|
2973
|
-
finstrong:
|
|
2974
|
-
} =
|
|
2975
|
-
const { repeating_transaction_type:
|
|
2976
|
-
return
|
|
2977
|
-
}, 0), [
|
|
2978
|
+
common: s,
|
|
2979
|
+
finstrong: i
|
|
2980
|
+
} = w(), { repeatingTransactions: c } = Ve(), { user: p } = Q(), l = c.reduce((f, x) => {
|
|
2981
|
+
const { repeating_transaction_type: b, transactions: D, recurrence_type: g, amount: C } = x;
|
|
2982
|
+
return b === Rt.Income && (D.length > 0 || g === Ot.EveryYear) ? f + C : f;
|
|
2983
|
+
}, 0), [d, _] = m.useState(null), y = [
|
|
2978
2984
|
{
|
|
2979
|
-
dynamicCopy:
|
|
2980
|
-
fallbackLabel:
|
|
2985
|
+
dynamicCopy: i.add_profile_item,
|
|
2986
|
+
fallbackLabel: i.monthly_income,
|
|
2981
2987
|
icon: /* @__PURE__ */ e(Cn, {}),
|
|
2982
|
-
key:
|
|
2983
|
-
label:
|
|
2988
|
+
key: te.MonthlyIncome,
|
|
2989
|
+
label: i.monthly_income,
|
|
2984
2990
|
value: l
|
|
2985
2991
|
},
|
|
2986
2992
|
{
|
|
2987
|
-
dynamicCopy:
|
|
2988
|
-
fallbackLabel:
|
|
2993
|
+
dynamicCopy: i.add_profile_item,
|
|
2994
|
+
fallbackLabel: i.date_of_birth,
|
|
2989
2995
|
icon: /* @__PURE__ */ e(vn, {}),
|
|
2990
|
-
key:
|
|
2991
|
-
label:
|
|
2992
|
-
value:
|
|
2996
|
+
key: te.DateOfBirth,
|
|
2997
|
+
label: i.date_of_birth,
|
|
2998
|
+
value: p.birthday
|
|
2993
2999
|
},
|
|
2994
3000
|
{
|
|
2995
|
-
dynamicCopy:
|
|
2996
|
-
fallbackLabel:
|
|
3001
|
+
dynamicCopy: i.add_profile_item,
|
|
3002
|
+
fallbackLabel: i.credit_score,
|
|
2997
3003
|
icon: /* @__PURE__ */ e(Ke, {}),
|
|
2998
|
-
key:
|
|
2999
|
-
label:
|
|
3000
|
-
value:
|
|
3004
|
+
key: te.CreditScore,
|
|
3005
|
+
label: i.credit_score,
|
|
3006
|
+
value: p.credit_score
|
|
3001
3007
|
},
|
|
3002
3008
|
{
|
|
3003
|
-
fallbackLabel:
|
|
3009
|
+
fallbackLabel: i.connect_your_accounts,
|
|
3004
3010
|
icon: /* @__PURE__ */ e(yt, {}),
|
|
3005
|
-
key:
|
|
3006
|
-
label:
|
|
3011
|
+
key: te.Connections,
|
|
3012
|
+
label: i.connections,
|
|
3007
3013
|
value: n.length > 0 ? Y(
|
|
3008
|
-
|
|
3014
|
+
i.connected_account,
|
|
3009
3015
|
String(n.length),
|
|
3010
|
-
n.length > 1 ?
|
|
3016
|
+
n.length > 1 ? i.accounts : i.account
|
|
3011
3017
|
) : void 0
|
|
3012
3018
|
}
|
|
3013
3019
|
].map((f) => En(f));
|
|
3014
|
-
return /* @__PURE__ */
|
|
3015
|
-
/* @__PURE__ */
|
|
3016
|
-
/* @__PURE__ */
|
|
3017
|
-
/* @__PURE__ */ e(N, { children:
|
|
3018
|
-
/* @__PURE__ */ e(k, { children:
|
|
3020
|
+
return /* @__PURE__ */ a(ne, { isOpen: t, onClose: r, title: i.financial_profile, children: [
|
|
3021
|
+
/* @__PURE__ */ a(u, { sx: { gap: 20, p: 24 }, children: [
|
|
3022
|
+
/* @__PURE__ */ a(u, { sx: { gap: 8 }, children: [
|
|
3023
|
+
/* @__PURE__ */ e(N, { children: i.your_financial_profile }),
|
|
3024
|
+
/* @__PURE__ */ e(k, { children: i.financial_profile_description })
|
|
3019
3025
|
] }),
|
|
3020
3026
|
/* @__PURE__ */ e(
|
|
3021
3027
|
Yt,
|
|
3022
3028
|
{
|
|
3023
|
-
completeCopy:
|
|
3024
|
-
value:
|
|
3029
|
+
completeCopy: i.complete,
|
|
3030
|
+
value: y.reduce((f, x) => f + (x.isComplete ? 1 : 0), 0)
|
|
3025
3031
|
}
|
|
3026
3032
|
)
|
|
3027
3033
|
] }),
|
|
3028
|
-
/* @__PURE__ */ e(Gn, { list:
|
|
3029
|
-
/* @__PURE__ */ e(
|
|
3034
|
+
/* @__PURE__ */ e(Gn, { list: y, onClickItem: _ }),
|
|
3035
|
+
/* @__PURE__ */ e(v, { sx: { p: 24 }, children: /* @__PURE__ */ e(
|
|
3030
3036
|
Be,
|
|
3031
3037
|
{
|
|
3032
|
-
description:
|
|
3038
|
+
description: i.connect_more_accounts_to_view_more_accurate_financial_picture,
|
|
3033
3039
|
drawerType: "connectDrawer",
|
|
3034
3040
|
isDashboard: !0,
|
|
3035
|
-
title:
|
|
3036
|
-
titleDrawer:
|
|
3041
|
+
title: i.dont_see_all_your_accounts,
|
|
3042
|
+
titleDrawer: s.add_accounts
|
|
3037
3043
|
}
|
|
3038
3044
|
) }),
|
|
3039
3045
|
/* @__PURE__ */ e(
|
|
3040
|
-
|
|
3046
|
+
ne,
|
|
3041
3047
|
{
|
|
3042
|
-
isOpen:
|
|
3043
|
-
onClose: () =>
|
|
3044
|
-
title:
|
|
3048
|
+
isOpen: d === te.MonthlyIncome,
|
|
3049
|
+
onClose: () => _(null),
|
|
3050
|
+
title: s.settings,
|
|
3045
3051
|
children: /* @__PURE__ */ e(ko, {})
|
|
3046
3052
|
}
|
|
3047
3053
|
),
|
|
3048
|
-
/* @__PURE__ */ e(ca, { isOpen:
|
|
3049
|
-
/* @__PURE__ */ e(Gt, { isOpen:
|
|
3054
|
+
/* @__PURE__ */ e(ca, { isOpen: d === te.DateOfBirth, onClose: () => _(null) }),
|
|
3055
|
+
/* @__PURE__ */ e(Gt, { isOpen: d === te.CreditScore, onClose: () => _(null) }),
|
|
3050
3056
|
/* @__PURE__ */ e(
|
|
3051
3057
|
Mt,
|
|
3052
3058
|
{
|
|
3053
|
-
onClose: () =>
|
|
3054
|
-
showConnectionsWidget:
|
|
3059
|
+
onClose: () => _(null),
|
|
3060
|
+
showConnectionsWidget: d === te.Connections,
|
|
3055
3061
|
title: o.manage_connections
|
|
3056
3062
|
}
|
|
3057
3063
|
)
|
|
@@ -3059,26 +3065,26 @@ const B = {
|
|
|
3059
3065
|
}, da = S(la), mt = ({
|
|
3060
3066
|
content: t,
|
|
3061
3067
|
islast: r = !1
|
|
3062
|
-
}) => /* @__PURE__ */
|
|
3063
|
-
/* @__PURE__ */
|
|
3068
|
+
}) => /* @__PURE__ */ a(Ao, { sx: { minHeight: 0 }, children: [
|
|
3069
|
+
/* @__PURE__ */ a(Po, { children: [
|
|
3064
3070
|
/* @__PURE__ */ e(Fo, { sx: { bgcolor: "divider", borderWidth: 1, p: 3 } }),
|
|
3065
3071
|
!r && /* @__PURE__ */ e(Oo, { sx: { bgcolor: "divider", width: 0.1 } })
|
|
3066
3072
|
] }),
|
|
3067
3073
|
/* @__PURE__ */ e(Ro, { sx: { pb: 16, pl: 12, pr: 0, pt: 5 }, children: /* @__PURE__ */ e(k, { fontSize: 13, fontWeight: 400, variant: "subtitle2", children: t }) })
|
|
3068
3074
|
] }), pa = ({ report: t }) => {
|
|
3069
|
-
const { finstrong: r } =
|
|
3075
|
+
const { finstrong: r } = w(), { score_history_drawer_timeline: n } = r, {
|
|
3070
3076
|
health_score_point_difference: o,
|
|
3071
|
-
newer_credit_score:
|
|
3072
|
-
older_credit_score:
|
|
3073
|
-
older_spend_to_income_ratio:
|
|
3074
|
-
newer_spend_to_income_ratio:
|
|
3077
|
+
newer_credit_score: s,
|
|
3078
|
+
older_credit_score: i,
|
|
3079
|
+
older_spend_to_income_ratio: c,
|
|
3080
|
+
newer_spend_to_income_ratio: p,
|
|
3075
3081
|
older_health_score: l,
|
|
3076
|
-
newer_health_score:
|
|
3077
|
-
newer_score_calculated_at:
|
|
3078
|
-
} = t,
|
|
3082
|
+
newer_health_score: d,
|
|
3083
|
+
newer_score_calculated_at: _
|
|
3084
|
+
} = t, h = Do(new Date(_), "MMM d"), y = () => o === 0 ? "info.lighter" : o > 0 ? "success.lighter" : "error.lighter", f = () => o === 0 ? Y(n.stayed_at, l) : o > 0 ? n.less_spending : n.more_spending, x = () => {
|
|
3079
3085
|
if (o === 0) return null;
|
|
3080
|
-
const
|
|
3081
|
-
return /* @__PURE__ */
|
|
3086
|
+
const b = o > 0 ? n.up_from : n.down_from, D = Y(b, l, d);
|
|
3087
|
+
return /* @__PURE__ */ a(E, { children: [
|
|
3082
3088
|
/* @__PURE__ */ e(
|
|
3083
3089
|
Mn,
|
|
3084
3090
|
{
|
|
@@ -3090,8 +3096,8 @@ const B = {
|
|
|
3090
3096
|
D
|
|
3091
3097
|
] });
|
|
3092
3098
|
};
|
|
3093
|
-
return /* @__PURE__ */ e(K, { children: /* @__PURE__ */
|
|
3094
|
-
/* @__PURE__ */ e(
|
|
3099
|
+
return /* @__PURE__ */ e(K, { children: /* @__PURE__ */ a(u, { sx: { backgroundColor: "background.paper" }, children: [
|
|
3100
|
+
/* @__PURE__ */ e(v, { sx: { borderBottom: "1px solid", borderBottomColor: "divider", p: 16 }, children: /* @__PURE__ */ a(
|
|
3095
3101
|
u,
|
|
3096
3102
|
{
|
|
3097
3103
|
flexDirection: "row",
|
|
@@ -3102,7 +3108,7 @@ const B = {
|
|
|
3102
3108
|
{
|
|
3103
3109
|
sx: {
|
|
3104
3110
|
alignItems: "center",
|
|
3105
|
-
backgroundColor:
|
|
3111
|
+
backgroundColor: y(),
|
|
3106
3112
|
borderRadius: 999,
|
|
3107
3113
|
height: 48,
|
|
3108
3114
|
justifyContent: "center",
|
|
@@ -3111,18 +3117,18 @@ const B = {
|
|
|
3111
3117
|
children: /* @__PURE__ */ e(k, { sx: { fontWeight: 600 }, variant: "Body", children: o > 0 ? `+${o}` : o })
|
|
3112
3118
|
}
|
|
3113
3119
|
),
|
|
3114
|
-
/* @__PURE__ */
|
|
3120
|
+
/* @__PURE__ */ a(u, { sx: { gap: 2, width: "80%" }, children: [
|
|
3115
3121
|
/* @__PURE__ */ e(I, { fontWeight: 600, variant: "Body", children: f() }),
|
|
3116
|
-
/* @__PURE__ */
|
|
3117
|
-
|
|
3122
|
+
/* @__PURE__ */ a(I, { sx: { color: "text.secondary" }, variant: "subtitle2", children: [
|
|
3123
|
+
h,
|
|
3118
3124
|
" ",
|
|
3119
|
-
|
|
3125
|
+
x()
|
|
3120
3126
|
] })
|
|
3121
3127
|
] })
|
|
3122
3128
|
]
|
|
3123
3129
|
}
|
|
3124
3130
|
) }),
|
|
3125
|
-
o !== 0 && /* @__PURE__ */ e(
|
|
3131
|
+
o !== 0 && /* @__PURE__ */ e(v, { sx: { color: "text.secondary", pb: 8, pl: 32, pr: 16, pt: 12 }, children: /* @__PURE__ */ a(
|
|
3126
3132
|
Io,
|
|
3127
3133
|
{
|
|
3128
3134
|
sx: {
|
|
@@ -3139,8 +3145,8 @@ const B = {
|
|
|
3139
3145
|
{
|
|
3140
3146
|
content: Y(
|
|
3141
3147
|
n.spend_to_income_description,
|
|
3142
|
-
Te(
|
|
3143
|
-
Te(
|
|
3148
|
+
Te(c),
|
|
3149
|
+
Te(p)
|
|
3144
3150
|
)
|
|
3145
3151
|
}
|
|
3146
3152
|
),
|
|
@@ -3149,8 +3155,8 @@ const B = {
|
|
|
3149
3155
|
{
|
|
3150
3156
|
content: Y(
|
|
3151
3157
|
n.credit_score_description,
|
|
3152
|
-
|
|
3153
|
-
|
|
3158
|
+
i,
|
|
3159
|
+
s
|
|
3154
3160
|
),
|
|
3155
3161
|
islast: !0
|
|
3156
3162
|
}
|
|
@@ -3160,9 +3166,9 @@ const B = {
|
|
|
3160
3166
|
) })
|
|
3161
3167
|
] }) });
|
|
3162
3168
|
}, ua = S(pa), _a = ({ isOpen: t, onClose: r }) => {
|
|
3163
|
-
const n =
|
|
3164
|
-
if (!
|
|
3165
|
-
const
|
|
3169
|
+
const n = G(), { finstrong: o } = w(), { isCopyLoaded: s, isInitialized: i } = j(), { healthScore: c, healthScoreChangeReports: p, augmentedChartData: l } = F();
|
|
3170
|
+
if (!s || !i) return /* @__PURE__ */ e(J, {});
|
|
3171
|
+
const d = je(c.health_score || 0, o), _ = p.slice().reverse();
|
|
3166
3172
|
return /* @__PURE__ */ e(
|
|
3167
3173
|
Ht,
|
|
3168
3174
|
{
|
|
@@ -3187,57 +3193,57 @@ const B = {
|
|
|
3187
3193
|
isOpen: t,
|
|
3188
3194
|
loadConnectAccountsCard: !1,
|
|
3189
3195
|
onClose: r,
|
|
3190
|
-
stickyComponent: /* @__PURE__ */
|
|
3196
|
+
stickyComponent: /* @__PURE__ */ a(
|
|
3191
3197
|
u,
|
|
3192
3198
|
{
|
|
3193
3199
|
direction: "row",
|
|
3194
3200
|
sx: { backgroundColor: "background.paper", gap: 16, pb: 12, pt: 8, px: 24 },
|
|
3195
3201
|
children: [
|
|
3196
|
-
/* @__PURE__ */ e(
|
|
3202
|
+
/* @__PURE__ */ e(v, { children: /* @__PURE__ */ e(
|
|
3197
3203
|
Et,
|
|
3198
3204
|
{
|
|
3199
3205
|
arcRadius: 20,
|
|
3200
|
-
healthScore:
|
|
3206
|
+
healthScore: c?.health_score,
|
|
3201
3207
|
size: "SM"
|
|
3202
3208
|
}
|
|
3203
3209
|
) }),
|
|
3204
|
-
/* @__PURE__ */
|
|
3205
|
-
/* @__PURE__ */ e(k, { fontSize: 18, fontWeight: 700, sx: { mb: 4 }, variant: "subtitle1", children:
|
|
3206
|
-
/* @__PURE__ */ e(k, { variant: "caption", children:
|
|
3210
|
+
/* @__PURE__ */ a(v, { children: [
|
|
3211
|
+
/* @__PURE__ */ e(k, { fontSize: 18, fontWeight: 700, sx: { mb: 4 }, variant: "subtitle1", children: d.status }),
|
|
3212
|
+
/* @__PURE__ */ e(k, { variant: "caption", children: d.description })
|
|
3207
3213
|
] })
|
|
3208
3214
|
]
|
|
3209
3215
|
}
|
|
3210
3216
|
),
|
|
3211
|
-
children: /* @__PURE__ */ e(u, { sx: { gap: 16 }, children:
|
|
3217
|
+
children: /* @__PURE__ */ e(u, { sx: { gap: 16 }, children: _.map((h, y) => /* @__PURE__ */ e(ua, { report: h }, y)) })
|
|
3212
3218
|
}
|
|
3213
3219
|
);
|
|
3214
3220
|
}, ha = S(_a), ma = ({ copy: t }) => {
|
|
3215
|
-
const r =
|
|
3221
|
+
const r = G(), n = [
|
|
3216
3222
|
r.palette.chartMono.chartMono5,
|
|
3217
3223
|
r.palette.chartMono.chartMono4,
|
|
3218
3224
|
r.palette.chartMono.chartMono3,
|
|
3219
3225
|
r.palette.chartMono.chartMono2
|
|
3220
3226
|
];
|
|
3221
|
-
return /* @__PURE__ */
|
|
3227
|
+
return /* @__PURE__ */ a(u, { sx: { gap: 8 }, children: [
|
|
3222
3228
|
/* @__PURE__ */ e(u, { sx: { flexDirection: "row", gap: 8, px: 2 }, children: [
|
|
3223
3229
|
{ color: "chartMono.chartMono2", text: t.vulnerable, value: "0-25" },
|
|
3224
3230
|
{ color: "chartMono.chartMono3", text: t.building, value: "26-50" },
|
|
3225
3231
|
{ color: "chartMono.chartMono4", text: t.stable, value: "51-75" },
|
|
3226
3232
|
{ color: "chartMono.chartMono5", text: t.strong, value: "76-100" }
|
|
3227
|
-
].map(({ color: o, text:
|
|
3228
|
-
/* @__PURE__ */
|
|
3229
|
-
/* @__PURE__ */ e(k, { sx: { fontWeight: 700, textTransform: "uppercase" }, variant: "caption", children:
|
|
3230
|
-
/* @__PURE__ */
|
|
3233
|
+
].map(({ color: o, text: s, value: i }) => /* @__PURE__ */ a(u, { sx: { gap: 4, textAlign: "center", width: "100%" }, children: [
|
|
3234
|
+
/* @__PURE__ */ a(v, { children: [
|
|
3235
|
+
/* @__PURE__ */ e(k, { sx: { fontWeight: 700, textTransform: "uppercase" }, variant: "caption", children: s }),
|
|
3236
|
+
/* @__PURE__ */ a(I, { sx: { color: "text.secondary" }, variant: "caption", children: [
|
|
3231
3237
|
"(",
|
|
3232
|
-
|
|
3238
|
+
i,
|
|
3233
3239
|
")"
|
|
3234
3240
|
] })
|
|
3235
3241
|
] }),
|
|
3236
|
-
/* @__PURE__ */ e(
|
|
3237
|
-
] },
|
|
3238
|
-
/* @__PURE__ */
|
|
3242
|
+
/* @__PURE__ */ e(v, { sx: { border: "2px solid", borderColor: o, borderRadius: "3px" } })
|
|
3243
|
+
] }, s)) }),
|
|
3244
|
+
/* @__PURE__ */ a(v, { children: [
|
|
3239
3245
|
/* @__PURE__ */ e(
|
|
3240
|
-
|
|
3246
|
+
v,
|
|
3241
3247
|
{
|
|
3242
3248
|
sx: {
|
|
3243
3249
|
background: `linear-gradient(to left, ${n.join(", ")})`,
|
|
@@ -3246,13 +3252,13 @@ const B = {
|
|
|
3246
3252
|
}
|
|
3247
3253
|
}
|
|
3248
3254
|
),
|
|
3249
|
-
/* @__PURE__ */ e(u, { sx: { flexDirection: "row", justifyContent: "space-between" }, children: [0, 10, 20, 30, 40, 50, 60, 70, 80, 90, 100].map((o) => /* @__PURE__ */
|
|
3255
|
+
/* @__PURE__ */ e(u, { sx: { flexDirection: "row", justifyContent: "space-between" }, children: [0, 10, 20, 30, 40, 50, 60, 70, 80, 90, 100].map((o) => /* @__PURE__ */ a(
|
|
3250
3256
|
u,
|
|
3251
3257
|
{
|
|
3252
3258
|
sx: { alignItems: "center", height: 20, justifyContent: "space-between", width: 24 },
|
|
3253
3259
|
children: [
|
|
3254
3260
|
/* @__PURE__ */ e(
|
|
3255
|
-
|
|
3261
|
+
v,
|
|
3256
3262
|
{
|
|
3257
3263
|
sx: {
|
|
3258
3264
|
borderBottom: "1px solid",
|
|
@@ -3272,18 +3278,18 @@ const B = {
|
|
|
3272
3278
|
] })
|
|
3273
3279
|
] });
|
|
3274
3280
|
}, ga = ({ isOpen: t, onClose: r }) => {
|
|
3275
|
-
const { finstrong: n } =
|
|
3276
|
-
return o ? /* @__PURE__ */ e(
|
|
3277
|
-
/* @__PURE__ */
|
|
3278
|
-
/* @__PURE__ */
|
|
3281
|
+
const { finstrong: n } = w(), { isCopyLoaded: o } = j();
|
|
3282
|
+
return o ? /* @__PURE__ */ e(ne, { isOpen: t, onClose: r, title: n.score_rubric, children: /* @__PURE__ */ a(u, { sx: { gap: 36, p: 24 }, children: [
|
|
3283
|
+
/* @__PURE__ */ a(u, { sx: { gap: 20 }, children: [
|
|
3284
|
+
/* @__PURE__ */ a(u, { sx: { gap: 8 }, children: [
|
|
3279
3285
|
/* @__PURE__ */ e(N, { sx: { textWrap: "wrap" }, children: n.your_path_to_financial_freedom }),
|
|
3280
3286
|
/* @__PURE__ */ e(k, { variant: "subtitle1", children: n.finstrong_freedom_description })
|
|
3281
3287
|
] }),
|
|
3282
|
-
/* @__PURE__ */ e(
|
|
3288
|
+
/* @__PURE__ */ e(v, { children: /* @__PURE__ */ e(ma, { copy: n }) })
|
|
3283
3289
|
] }),
|
|
3284
|
-
/* @__PURE__ */
|
|
3290
|
+
/* @__PURE__ */ a(u, { sx: { gap: 12 }, children: [
|
|
3285
3291
|
/* @__PURE__ */ e(I, { sx: { fontWeight: 600 }, variant: "body1", children: n.how_do_we_do_this }),
|
|
3286
|
-
/* @__PURE__ */
|
|
3292
|
+
/* @__PURE__ */ a(
|
|
3287
3293
|
Re,
|
|
3288
3294
|
{
|
|
3289
3295
|
component: "ol",
|
|
@@ -3321,9 +3327,9 @@ const B = {
|
|
|
3321
3327
|
}
|
|
3322
3328
|
)
|
|
3323
3329
|
] }),
|
|
3324
|
-
/* @__PURE__ */
|
|
3330
|
+
/* @__PURE__ */ a(u, { sx: { gap: 4 }, children: [
|
|
3325
3331
|
/* @__PURE__ */ e(I, { sx: { fontWeight: 600, pb: 4 }, variant: "body1", children: n.we_ask_questions }),
|
|
3326
|
-
/* @__PURE__ */
|
|
3332
|
+
/* @__PURE__ */ a(
|
|
3327
3333
|
Re,
|
|
3328
3334
|
{
|
|
3329
3335
|
component: "ol",
|
|
@@ -3352,13 +3358,13 @@ const B = {
|
|
|
3352
3358
|
] })
|
|
3353
3359
|
] }) }) : /* @__PURE__ */ e(J, {});
|
|
3354
3360
|
}, ya = S(ga), ba = S(() => {
|
|
3355
|
-
const [t, r] = m.useState(!1), n =
|
|
3356
|
-
return !
|
|
3361
|
+
const [t, r] = m.useState(!1), n = G(), [o, { width: s }] = It(), { finstrong: i } = w(), { isCopyLoaded: c, isInitialized: p } = j(), { healthScore: l, healthScoreChange: d } = F(), _ = n.palette.mode === "dark", h = je(l?.health_score, i);
|
|
3362
|
+
return !c || !p ? /* @__PURE__ */ e(J, {}) : /* @__PURE__ */ a(K, { ref: o, sx: { p: 16 }, children: [
|
|
3357
3363
|
/* @__PURE__ */ e(
|
|
3358
3364
|
Wo,
|
|
3359
3365
|
{
|
|
3360
3366
|
action: /* @__PURE__ */ e(
|
|
3361
|
-
|
|
3367
|
+
z,
|
|
3362
3368
|
{
|
|
3363
3369
|
endIcon: /* @__PURE__ */ e(Z, {}),
|
|
3364
3370
|
onClick: () => r(!0),
|
|
@@ -3369,10 +3375,10 @@ const B = {
|
|
|
3369
3375
|
color: "primary.main"
|
|
3370
3376
|
},
|
|
3371
3377
|
variant: "text",
|
|
3372
|
-
children:
|
|
3378
|
+
children: i.financial_strength_header_action
|
|
3373
3379
|
}
|
|
3374
3380
|
),
|
|
3375
|
-
subheader: /* @__PURE__ */ e(N, { color: "text.primary", children:
|
|
3381
|
+
subheader: /* @__PURE__ */ e(N, { color: "text.primary", children: i.financial_strength_header }),
|
|
3376
3382
|
sx: {
|
|
3377
3383
|
p: 0,
|
|
3378
3384
|
"& .MuiCardHeader-content": {
|
|
@@ -3384,18 +3390,18 @@ const B = {
|
|
|
3384
3390
|
/* @__PURE__ */ e(u, { sx: { justifyContent: "center", alignItems: "center" }, children: /* @__PURE__ */ e(
|
|
3385
3391
|
Et,
|
|
3386
3392
|
{
|
|
3387
|
-
arcRadius:
|
|
3388
|
-
footerCenterContent:
|
|
3393
|
+
arcRadius: s <= 323 ? 73 : 154,
|
|
3394
|
+
footerCenterContent: d,
|
|
3389
3395
|
healthScore: l?.health_score || 0,
|
|
3390
|
-
size:
|
|
3396
|
+
size: s <= 323 ? "M" : "L"
|
|
3391
3397
|
}
|
|
3392
3398
|
) }),
|
|
3393
|
-
l?.health_score ? /* @__PURE__ */
|
|
3399
|
+
l?.health_score ? /* @__PURE__ */ a(
|
|
3394
3400
|
Bo,
|
|
3395
3401
|
{
|
|
3396
3402
|
sx: {
|
|
3397
3403
|
px: 16,
|
|
3398
|
-
backgroundColor:
|
|
3404
|
+
backgroundColor: _ ? "grey.800" : "grey.50",
|
|
3399
3405
|
//TODO: Need to change the background color to palette (supporting both darkmode and lightmode)
|
|
3400
3406
|
"&.Mui-expanded": {
|
|
3401
3407
|
m: 0
|
|
@@ -3416,22 +3422,22 @@ const B = {
|
|
|
3416
3422
|
minHeight: 0
|
|
3417
3423
|
}
|
|
3418
3424
|
},
|
|
3419
|
-
children: /* @__PURE__ */ e(k, { sx: { fontWeight: 600 }, variant: "body1", children:
|
|
3425
|
+
children: /* @__PURE__ */ e(k, { sx: { fontWeight: 600 }, variant: "body1", children: i.accordion_title_text })
|
|
3420
3426
|
}
|
|
3421
3427
|
),
|
|
3422
|
-
/* @__PURE__ */ e(Lo, { sx: { "&.MuiAccordionDetails-root": { padding: 0, pb: 16 } }, children: /* @__PURE__ */ e(k, { variant: "subtitle1", children:
|
|
3428
|
+
/* @__PURE__ */ e(Lo, { sx: { "&.MuiAccordionDetails-root": { padding: 0, pb: 16 } }, children: /* @__PURE__ */ e(k, { variant: "subtitle1", children: h.scoreContent }) })
|
|
3423
3429
|
]
|
|
3424
3430
|
}
|
|
3425
3431
|
) : /* @__PURE__ */ e(
|
|
3426
3432
|
Be,
|
|
3427
3433
|
{
|
|
3428
|
-
buttonText:
|
|
3429
|
-
description:
|
|
3434
|
+
buttonText: i.connect_more_accounts_title,
|
|
3435
|
+
description: i.health_score_zero_description,
|
|
3430
3436
|
drawerType: "connectDrawer",
|
|
3431
3437
|
hasIcon: !1,
|
|
3432
3438
|
isDashboard: !0,
|
|
3433
3439
|
sx: {
|
|
3434
|
-
backgroundColor:
|
|
3440
|
+
backgroundColor: _ ? "grey.800" : "grey.50",
|
|
3435
3441
|
//TODO: Need to change the background color to palette (supporting both darkmode and lightmode)
|
|
3436
3442
|
".connect-more-accounts-title": {
|
|
3437
3443
|
fontWeight: 600,
|
|
@@ -3440,7 +3446,7 @@ const B = {
|
|
|
3440
3446
|
},
|
|
3441
3447
|
".connect-more-accounts-description": { color: "text.primary" }
|
|
3442
3448
|
},
|
|
3443
|
-
title:
|
|
3449
|
+
title: i.health_score_zero_title
|
|
3444
3450
|
}
|
|
3445
3451
|
),
|
|
3446
3452
|
/* @__PURE__ */ e(
|
|
@@ -3451,47 +3457,41 @@ const B = {
|
|
|
3451
3457
|
}
|
|
3452
3458
|
)
|
|
3453
3459
|
] });
|
|
3454
|
-
}), fa = ({
|
|
3455
|
-
|
|
3456
|
-
|
|
3457
|
-
handleFinstrongWidgetPrimaryCtaClick: n
|
|
3458
|
-
}) => {
|
|
3459
|
-
const { visibleAccounts: o } = Me(), { dateRange: c, isDataLoaded: a, loadBudgetData: s, setTheme: d } = Yn(), { reloadCategoryTotals: l } = Ye(), p = F(), {
|
|
3460
|
-
augmentedChartData: h,
|
|
3460
|
+
}), fa = ({ onBackClick: t, sx: r, onPrimaryCtaClick: n }) => {
|
|
3461
|
+
const { visibleAccounts: o } = ke(), { dateRange: s, isDataLoaded: i, loadBudgetData: c, setTheme: p } = Yn(), { reloadCategoryTotals: l } = Ye(), {
|
|
3462
|
+
augmentedChartData: d,
|
|
3461
3463
|
calculateHealthScore: _,
|
|
3462
|
-
healthScore:
|
|
3463
|
-
loadAugmentedChartData:
|
|
3464
|
-
loadMonthlySummaries:
|
|
3465
|
-
} =
|
|
3464
|
+
healthScore: h,
|
|
3465
|
+
loadAugmentedChartData: y,
|
|
3466
|
+
loadMonthlySummaries: f
|
|
3467
|
+
} = F(), { finstrong: x, connect: b } = w(), { isCopyLoaded: D, isInitialized: g, selectedAccounts: C, setSelectedAccounts: M } = j(), { loadRepeatingTransactions: $ } = Ve(), { isMobile: H } = Ue(), O = G(), { userProfile: W } = Q(), [V, ee] = m.useState(!1), [pe, ue] = m.useState(!1), [_e, X] = m.useState(!1);
|
|
3466
3468
|
if (m.useEffect(() => {
|
|
3467
|
-
|
|
3468
|
-
}, []), m.useEffect(() => {
|
|
3469
|
-
|
|
3470
|
-
}, [
|
|
3471
|
-
|
|
3472
|
-
}, [
|
|
3473
|
-
|
|
3474
|
-
},
|
|
3475
|
-
|
|
3476
|
-
}, he = () => ae(!0);
|
|
3477
|
-
return /* @__PURE__ */ i(
|
|
3469
|
+
p(O);
|
|
3470
|
+
}, []), m.useEffect(() => M(o), [o]), m.useEffect(() => {
|
|
3471
|
+
g && (_().finally(), y().finally(), f().finally());
|
|
3472
|
+
}, [g]), m.useEffect(() => {
|
|
3473
|
+
g && (l(C, s.start, s.end), i || (c(), $().finally()));
|
|
3474
|
+
}, [s, i, g, C]), !D || !g) return /* @__PURE__ */ e(J, {});
|
|
3475
|
+
const he = () => {
|
|
3476
|
+
}, ae = () => ee(!0);
|
|
3477
|
+
return /* @__PURE__ */ a(
|
|
3478
3478
|
io,
|
|
3479
3479
|
{
|
|
3480
3480
|
accountOptions: o,
|
|
3481
3481
|
actions: [
|
|
3482
3482
|
{
|
|
3483
3483
|
iconName: "person",
|
|
3484
|
-
label:
|
|
3485
|
-
onClick:
|
|
3484
|
+
label: x.profile,
|
|
3485
|
+
onClick: ae
|
|
3486
3486
|
}
|
|
3487
3487
|
],
|
|
3488
3488
|
hasDivider: !0,
|
|
3489
|
-
onAccountsFilterClick:
|
|
3489
|
+
onAccountsFilterClick: he,
|
|
3490
3490
|
onBackClick: t,
|
|
3491
3491
|
sx: r,
|
|
3492
|
-
title:
|
|
3492
|
+
title: x.title,
|
|
3493
3493
|
children: [
|
|
3494
|
-
|
|
3494
|
+
W.has_completed_finstrong_onboarding ? /* @__PURE__ */ a(
|
|
3495
3495
|
u,
|
|
3496
3496
|
{
|
|
3497
3497
|
sx: {
|
|
@@ -3502,77 +3502,77 @@ const B = {
|
|
|
3502
3502
|
px: 24
|
|
3503
3503
|
},
|
|
3504
3504
|
children: [
|
|
3505
|
-
/* @__PURE__ */
|
|
3505
|
+
/* @__PURE__ */ a(u, { sx: { gap: 24, width: { md: 432 } }, children: [
|
|
3506
3506
|
/* @__PURE__ */ e(ba, {}),
|
|
3507
3507
|
/* @__PURE__ */ e(
|
|
3508
3508
|
Be,
|
|
3509
3509
|
{
|
|
3510
|
-
description:
|
|
3510
|
+
description: x.connect_more_accounts_description,
|
|
3511
3511
|
drawerType: "connectDrawer",
|
|
3512
|
-
title:
|
|
3512
|
+
title: x.connect_more_accounts_title
|
|
3513
3513
|
}
|
|
3514
3514
|
)
|
|
3515
3515
|
] }),
|
|
3516
|
-
/* @__PURE__ */ e(u, { sx: { maxWidth: 848, minWidth: 288, width: { md: 720 } }, children: /* @__PURE__ */
|
|
3517
|
-
/* @__PURE__ */
|
|
3518
|
-
/* @__PURE__ */ e(N, { children:
|
|
3516
|
+
/* @__PURE__ */ e(u, { sx: { maxWidth: 848, minWidth: 288, width: { md: 720 } }, children: /* @__PURE__ */ a(K, { sx: { background: O.palette.background.paper, p: 16 }, children: [
|
|
3517
|
+
/* @__PURE__ */ a(u, { direction: "row", sx: { alignItems: "center", justifyContent: "space-between" }, children: [
|
|
3518
|
+
/* @__PURE__ */ e(N, { children: x.key_indicators }),
|
|
3519
3519
|
/* @__PURE__ */ e(
|
|
3520
|
-
|
|
3520
|
+
z,
|
|
3521
3521
|
{
|
|
3522
3522
|
endIcon: /* @__PURE__ */ e(Z, {}),
|
|
3523
|
-
onClick: () =>
|
|
3523
|
+
onClick: () => ue(!0),
|
|
3524
3524
|
sx: {
|
|
3525
3525
|
fontSize: 13
|
|
3526
3526
|
},
|
|
3527
3527
|
variant: "text",
|
|
3528
|
-
children:
|
|
3528
|
+
children: x.whats_changed
|
|
3529
3529
|
}
|
|
3530
3530
|
)
|
|
3531
3531
|
] }),
|
|
3532
|
-
|
|
3532
|
+
d.length ? /* @__PURE__ */ e(
|
|
3533
3533
|
Xe,
|
|
3534
3534
|
{
|
|
3535
|
-
axisColor:
|
|
3535
|
+
axisColor: O.palette.divider,
|
|
3536
3536
|
baseline: "min",
|
|
3537
|
-
colors: [
|
|
3537
|
+
colors: [O.palette.primary.main],
|
|
3538
3538
|
curveType: "natural",
|
|
3539
3539
|
customLegendVariant: "XSmall",
|
|
3540
|
-
datasets: [
|
|
3540
|
+
datasets: [d],
|
|
3541
3541
|
height: 300,
|
|
3542
3542
|
isGraphClippingXAxis: !0,
|
|
3543
|
-
labelBackgroundColor:
|
|
3544
|
-
labelFontColor:
|
|
3545
|
-
labelFontSize: typeof
|
|
3546
|
-
labels: [
|
|
3543
|
+
labelBackgroundColor: O.palette.border.dark,
|
|
3544
|
+
labelFontColor: O.palette.common.white,
|
|
3545
|
+
labelFontSize: typeof O.typography.XSmall?.fontSize == "string" ? parseFloat(O.typography.XSmall.fontSize) : O.typography.XSmall?.fontSize,
|
|
3546
|
+
labels: [x.key_indicators_label],
|
|
3547
3547
|
margin: { right: 20, left: 25 },
|
|
3548
3548
|
showArea: !0,
|
|
3549
3549
|
showAverage: !0,
|
|
3550
3550
|
showLegend: !0,
|
|
3551
3551
|
showMarkLabel: !0,
|
|
3552
3552
|
showXAxis: !0,
|
|
3553
|
-
title:
|
|
3553
|
+
title: x.peer_average,
|
|
3554
3554
|
useCustomMark: !0
|
|
3555
3555
|
}
|
|
3556
|
-
) : /* @__PURE__ */ e(Vr, { onClick: () =>
|
|
3557
|
-
|
|
3556
|
+
) : /* @__PURE__ */ e(Vr, { onClick: () => X(!0) }),
|
|
3557
|
+
h.health_score !== null && /* @__PURE__ */ e(jr, { onPrimaryCtaClick: n })
|
|
3558
3558
|
] }) })
|
|
3559
3559
|
]
|
|
3560
3560
|
}
|
|
3561
3561
|
) : /* @__PURE__ */ e(ia, {}),
|
|
3562
|
-
/* @__PURE__ */ e(da, { isOpen:
|
|
3562
|
+
/* @__PURE__ */ e(da, { isOpen: V, onClose: () => ee(!1) }),
|
|
3563
3563
|
/* @__PURE__ */ e(
|
|
3564
|
-
|
|
3564
|
+
re,
|
|
3565
3565
|
{
|
|
3566
|
-
onClose: () =>
|
|
3567
|
-
showConnectWidget:
|
|
3568
|
-
title:
|
|
3566
|
+
onClose: () => X(!1),
|
|
3567
|
+
showConnectWidget: _e,
|
|
3568
|
+
title: b.mini_title
|
|
3569
3569
|
}
|
|
3570
3570
|
),
|
|
3571
3571
|
/* @__PURE__ */ e(
|
|
3572
3572
|
ha,
|
|
3573
3573
|
{
|
|
3574
|
-
isOpen:
|
|
3575
|
-
onClose: () =>
|
|
3574
|
+
isOpen: pe,
|
|
3575
|
+
onClose: () => ue(!1)
|
|
3576
3576
|
}
|
|
3577
3577
|
)
|
|
3578
3578
|
]
|