@mx-cartographer/experiences 7.2.16-alpha.mm0 → 7.2.16
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +8 -0
- package/dist/{ExportCsvAction-sX8Rg4Ov.mjs → ExportCsvAction-DTO_UotC.mjs} +1 -1
- package/dist/{ManageIncome-CV-bGuR-.mjs → ManageIncome-CsCM4rNt.mjs} +63 -62
- package/dist/{NotificationSettings-5i3IywCi.mjs → NotificationSettings-DqrkNMod.mjs} +236 -238
- package/dist/{RecurringSettings-G6_BbsIF.mjs → RecurringSettings-DZu2hw1r.mjs} +1 -1
- package/dist/{TransactionStore-DxPLdF3B.mjs → TransactionStore-hfOsBbDt.mjs} +1 -1
- package/dist/accounts/index.es.js +115 -117
- package/dist/budgets/index.es.js +499 -501
- package/dist/cashflow/index.es.js +381 -383
- package/dist/common/index.es.js +2 -2
- package/dist/debts/index.es.js +375 -377
- package/dist/{exportTransactionsToCSV-7bVS7KXf.mjs → exportTransactionsToCSV-BwwmL4pM.mjs} +14 -13
- package/dist/finstrong/index.es.js +415 -417
- package/dist/goals/index.es.js +557 -559
- package/dist/investments/index.es.js +434 -436
- package/dist/networth/index.es.js +171 -173
- package/dist/notifications/index.es.js +1 -1
- package/dist/recurringtransactions/index.es.js +172 -174
- package/dist/settings/index.es.js +278 -284
- package/dist/spending/index.es.js +280 -282
- package/dist/transactions/index.es.js +4 -4
- package/dist/trends/index.es.js +1 -1
- package/package.json +1 -1
|
@@ -1,56 +1,56 @@
|
|
|
1
|
-
import { jsx as
|
|
2
|
-
import { fromUnixTime as
|
|
1
|
+
import { jsx as e, jsxs as r, Fragment as v } from "react/jsx-runtime";
|
|
2
|
+
import { fromUnixTime as Se } from "date-fns/fromUnixTime";
|
|
3
3
|
import { observer as w } from "mobx-react-lite";
|
|
4
4
|
import { useTheme as z } from "@mui/material/styles";
|
|
5
5
|
import { u as Z } from "../useScreenSize-B6JyS_Lj.mjs";
|
|
6
|
-
import { q as
|
|
7
|
-
import { f as
|
|
8
|
-
import { L as
|
|
6
|
+
import { q as _e, u as T, d as J, g as Q, b as P, r as ee } from "../hooks-D6XlXHf4.mjs";
|
|
7
|
+
import { f as we, D as be } from "../Dialog-CWW597AF.mjs";
|
|
8
|
+
import { L as We } from "../LineChart-D4GI7nVh.mjs";
|
|
9
9
|
import W from "@mui/material/Divider";
|
|
10
10
|
import B from "@mui/material/List";
|
|
11
11
|
import E from "@mui/material/ListSubheader";
|
|
12
12
|
import h from "@mui/material/Stack";
|
|
13
|
-
import { Text as m, Icon as H, H1 as
|
|
13
|
+
import { Text as m, Icon as H, H1 as ve, P as Ie } from "@mxenabled/mxui";
|
|
14
14
|
import d from "react";
|
|
15
15
|
import k from "@mui/material/ListItem";
|
|
16
|
-
import
|
|
16
|
+
import te from "@mui/material/ListItemButton";
|
|
17
17
|
import _ from "@mui/material/ListItemText";
|
|
18
|
-
import { i as
|
|
18
|
+
import { i as ne } from "../DateUtil-BcuH7ErC.mjs";
|
|
19
19
|
import { C as y } from "../CurrencyText-kyC1aseI.mjs";
|
|
20
|
-
import { Button as
|
|
21
|
-
import { format as
|
|
20
|
+
import { Button as Te, Stack as Le } from "@mui/material";
|
|
21
|
+
import { format as Ne, fromUnixTime as De, differenceInMonths as Ee } from "date-fns";
|
|
22
22
|
import { g as K } from "../NetWorthStore-D1NiDUcc.mjs";
|
|
23
|
-
import { N as
|
|
24
|
-
import { Icon as
|
|
23
|
+
import { N as Ot } from "../NetWorthStore-D1NiDUcc.mjs";
|
|
24
|
+
import { Icon as oe } from "@mxenabled/mx-icons";
|
|
25
25
|
import { f as U } from "../NumberFormatting-Buh7u8Oi.mjs";
|
|
26
|
-
import { A as b, W as
|
|
26
|
+
import { A as b, W as ke } from "../WidgetContainer-EbrN1oIo.mjs";
|
|
27
27
|
import { L as O } from "../Loader-DUaFpDGv.mjs";
|
|
28
|
-
import { M as
|
|
29
|
-
import
|
|
30
|
-
import { C as
|
|
31
|
-
import
|
|
28
|
+
import { M as Ae } from "../MicroWidgetContainer-DpeqN9n3.mjs";
|
|
29
|
+
import re from "@mui/material/Box";
|
|
30
|
+
import { C as Me } from "../ConnectionsDrawer-BDvVuJQf.mjs";
|
|
31
|
+
import He from "@mui/material/Collapse";
|
|
32
32
|
import V from "@mui/material/ListItemIcon";
|
|
33
|
-
import
|
|
34
|
-
import { E as
|
|
33
|
+
import ie from "@mui/material/styles/useTheme";
|
|
34
|
+
import { E as Be } from "../EmptyState-DA_lfRBv.mjs";
|
|
35
35
|
import { D as Y } from "../Drawer-kEE73B87.mjs";
|
|
36
|
-
const
|
|
37
|
-
chartData:
|
|
36
|
+
const Oe = ({
|
|
37
|
+
chartData: t,
|
|
38
38
|
hoveredData: l,
|
|
39
39
|
onDataClick: i,
|
|
40
40
|
onMouseEnter: n,
|
|
41
41
|
onMouseLeave: s,
|
|
42
42
|
selectedData: o
|
|
43
43
|
}) => {
|
|
44
|
-
const { isMobile: a } = Z(), { availableWidth: c } =
|
|
45
|
-
x:
|
|
44
|
+
const { isMobile: a } = Z(), { availableWidth: c } = _e(), u = z(), C = c - 320, x = t.map((f) => ({
|
|
45
|
+
x: we(Se(f.x), be.MONTH_SHORT),
|
|
46
46
|
y: f.y
|
|
47
|
-
})), g = o ? { index:
|
|
47
|
+
})), g = o ? { index: t.findIndex((f) => f.x === o.x) } : void 0, S = l ? { index: t.findIndex((f) => f.x === l.x) } : void 0, p = (f) => ({
|
|
48
48
|
fill: f === g?.index ? u.palette.success.main : "",
|
|
49
49
|
filter: f === S?.index ? `drop-shadow(0px 0px 10px ${u.palette.success.main})` : "none",
|
|
50
50
|
stroke: u.palette.success.main
|
|
51
51
|
});
|
|
52
|
-
return /* @__PURE__ */
|
|
53
|
-
|
|
52
|
+
return /* @__PURE__ */ e(
|
|
53
|
+
We,
|
|
54
54
|
{
|
|
55
55
|
baseline: "min",
|
|
56
56
|
colors: [u.palette.success.main],
|
|
@@ -69,8 +69,8 @@ const Rt = ({
|
|
|
69
69
|
width: a ? 320 : C
|
|
70
70
|
}
|
|
71
71
|
);
|
|
72
|
-
},
|
|
73
|
-
item:
|
|
72
|
+
}, ze = w(Oe), Re = ({
|
|
73
|
+
item: t,
|
|
74
74
|
getStyles: l,
|
|
75
75
|
isHovered: i = !1,
|
|
76
76
|
isSelected: n = !1,
|
|
@@ -82,9 +82,9 @@ const Rt = ({
|
|
|
82
82
|
color: ""
|
|
83
83
|
});
|
|
84
84
|
return d.useEffect(() => {
|
|
85
|
-
u(l(
|
|
85
|
+
u(l(t));
|
|
86
86
|
}, [i, n]), /* @__PURE__ */ r(d.Fragment, { children: [
|
|
87
|
-
/* @__PURE__ */
|
|
87
|
+
/* @__PURE__ */ e(
|
|
88
88
|
k,
|
|
89
89
|
{
|
|
90
90
|
sx: {
|
|
@@ -92,19 +92,19 @@ const Rt = ({
|
|
|
92
92
|
minHeight: 44,
|
|
93
93
|
"&:hover": { color: n ? "inherit" : c.color }
|
|
94
94
|
},
|
|
95
|
-
children: /* @__PURE__ */
|
|
96
|
-
|
|
95
|
+
children: /* @__PURE__ */ e(
|
|
96
|
+
te,
|
|
97
97
|
{
|
|
98
|
-
onClick: (C) => s?.(C,
|
|
99
|
-
onMouseEnter: () => o(
|
|
98
|
+
onClick: (C) => s?.(C, t.x),
|
|
99
|
+
onMouseEnter: () => o(t.x),
|
|
100
100
|
onMouseLeave: () => a(),
|
|
101
101
|
sx: { minHeight: 20, padding: 12 },
|
|
102
|
-
children: /* @__PURE__ */
|
|
102
|
+
children: /* @__PURE__ */ e(
|
|
103
103
|
_,
|
|
104
104
|
{
|
|
105
105
|
primary: /* @__PURE__ */ r(h, { direction: "row", justifyContent: "space-between", sx: { fontWeight: 400 }, children: [
|
|
106
|
-
/* @__PURE__ */
|
|
107
|
-
/* @__PURE__ */
|
|
106
|
+
/* @__PURE__ */ e(m, { variant: "Body", children: ne(t.x) }),
|
|
107
|
+
/* @__PURE__ */ e(y, { amount: t.y, sx: { color: "inherit" }, variant: "Body" })
|
|
108
108
|
] })
|
|
109
109
|
}
|
|
110
110
|
)
|
|
@@ -112,10 +112,10 @@ const Rt = ({
|
|
|
112
112
|
)
|
|
113
113
|
}
|
|
114
114
|
),
|
|
115
|
-
/* @__PURE__ */
|
|
116
|
-
] },
|
|
117
|
-
},
|
|
118
|
-
chartData:
|
|
115
|
+
/* @__PURE__ */ e(W, {})
|
|
116
|
+
] }, t.x);
|
|
117
|
+
}, je = w(Re), $e = ({
|
|
118
|
+
chartData: t,
|
|
119
119
|
hoveredData: l,
|
|
120
120
|
onDataClick: i,
|
|
121
121
|
onButtonClick: n,
|
|
@@ -133,10 +133,10 @@ const Rt = ({
|
|
|
133
133
|
};
|
|
134
134
|
return /* @__PURE__ */ r(h, { direction: "column", sx: { width: 320 }, children: [
|
|
135
135
|
/* @__PURE__ */ r(B, { children: [
|
|
136
|
-
/* @__PURE__ */
|
|
137
|
-
/* @__PURE__ */
|
|
138
|
-
|
|
139
|
-
|
|
136
|
+
/* @__PURE__ */ e(E, { sx: { backgroundColor: "transparent", mb: 8, mt: 12, px: 12 }, children: /* @__PURE__ */ e(m, { bold: !0, component: "h2", variant: "Body", children: c.monthly_totals }) }),
|
|
137
|
+
/* @__PURE__ */ e(W, {}),
|
|
138
|
+
t.map((x, g) => /* @__PURE__ */ e(
|
|
139
|
+
je,
|
|
140
140
|
{
|
|
141
141
|
getStyles: C,
|
|
142
142
|
isHovered: x.x === l?.x,
|
|
@@ -149,8 +149,8 @@ const Rt = ({
|
|
|
149
149
|
x.x
|
|
150
150
|
))
|
|
151
151
|
] }),
|
|
152
|
-
/* @__PURE__ */
|
|
153
|
-
|
|
152
|
+
/* @__PURE__ */ e(
|
|
153
|
+
Te,
|
|
154
154
|
{
|
|
155
155
|
onClick: () => n(),
|
|
156
156
|
sx: { alignSelf: "center", marginTop: 16, width: "fit-content" },
|
|
@@ -159,16 +159,16 @@ const Rt = ({
|
|
|
159
159
|
}
|
|
160
160
|
)
|
|
161
161
|
] });
|
|
162
|
-
},
|
|
163
|
-
currencyLabel:
|
|
162
|
+
}, Ge = w($e), Xe = ({
|
|
163
|
+
currencyLabel: t,
|
|
164
164
|
currencyVariant: l = "Small",
|
|
165
165
|
iconSize: i,
|
|
166
166
|
netWorth: n,
|
|
167
167
|
theme: s
|
|
168
168
|
}) => {
|
|
169
169
|
let o = s.palette.secondary.main, a = s.palette.secondary.main, c = "trending_flat";
|
|
170
|
-
return n.change < 0 ? c = "trending_down" : n.change > 0 && (o = s.palette.success.main, a = s.palette.success.main, c = "trending_up"), /* @__PURE__ */ r(
|
|
171
|
-
/* @__PURE__ */
|
|
170
|
+
return n.change < 0 ? c = "trending_down" : n.change > 0 && (o = s.palette.success.main, a = s.palette.success.main, c = "trending_up"), /* @__PURE__ */ r(Le, { alignItems: "center", direction: "row", spacing: 4, children: [
|
|
171
|
+
/* @__PURE__ */ e(
|
|
172
172
|
H,
|
|
173
173
|
{
|
|
174
174
|
name: c,
|
|
@@ -178,85 +178,85 @@ const Rt = ({
|
|
|
178
178
|
}
|
|
179
179
|
}
|
|
180
180
|
),
|
|
181
|
-
/* @__PURE__ */
|
|
182
|
-
/* @__PURE__ */
|
|
181
|
+
/* @__PURE__ */ e(y, { amount: n.change, color: a, variant: l }),
|
|
182
|
+
/* @__PURE__ */ e(m, { variant: "Small", children: t })
|
|
183
183
|
] });
|
|
184
|
-
}, R = w(
|
|
185
|
-
const { net_worth: i } = T(), n = z(), s =
|
|
184
|
+
}, R = w(Xe), Fe = ({ hoveredData: t, selectedData: l }) => {
|
|
185
|
+
const { net_worth: i } = T(), n = z(), s = t || l, o = Ne(De(s.x), "MMMM");
|
|
186
186
|
return /* @__PURE__ */ r(h, { alignItems: "center", direction: "column", m: 24, children: [
|
|
187
|
-
/* @__PURE__ */
|
|
188
|
-
/* @__PURE__ */
|
|
189
|
-
/* @__PURE__ */
|
|
187
|
+
/* @__PURE__ */ e(m, { color: n.palette.secondary.main, variant: "Small", children: `${o} ${i.net_worth}` }),
|
|
188
|
+
/* @__PURE__ */ e(y, { amount: s.y, variant: "H2" }),
|
|
189
|
+
/* @__PURE__ */ e(R, { currencyLabel: i.this_month, netWorth: s, theme: n })
|
|
190
190
|
] });
|
|
191
|
-
},
|
|
191
|
+
}, Ke = w(Fe), Ue = ({ amount: t, copy: l, trendValue: i }) => {
|
|
192
192
|
const n = i > 0, o = i === 0 ? "trending_flat" : n ? "trending_up" : "trending_down";
|
|
193
193
|
return /* @__PURE__ */ r(h, { sx: { flexDirection: "row", justifyContent: "space-between" }, children: [
|
|
194
|
-
/* @__PURE__ */
|
|
195
|
-
|
|
194
|
+
/* @__PURE__ */ e(ve, { children: U(t, "0,0") }),
|
|
195
|
+
t !== 0 && /* @__PURE__ */ r(h, { sx: { color: n ? "success.main" : "text.secondary" }, children: [
|
|
196
196
|
/* @__PURE__ */ r(h, { sx: { flexDirection: "row", gap: 8 }, children: [
|
|
197
|
-
/* @__PURE__ */
|
|
198
|
-
/* @__PURE__ */
|
|
197
|
+
/* @__PURE__ */ e(oe, { name: o, size: 20 }),
|
|
198
|
+
/* @__PURE__ */ e(m, { sx: { fontWeight: 600, textAlign: "right" }, variant: "body1", children: U(i, "0,0.00") })
|
|
199
199
|
] }),
|
|
200
|
-
/* @__PURE__ */
|
|
200
|
+
/* @__PURE__ */ e(m, { sx: { display: "block", textAlign: "right" }, variant: "caption", children: l.this_month })
|
|
201
201
|
] })
|
|
202
202
|
] });
|
|
203
|
-
},
|
|
204
|
-
/* @__PURE__ */
|
|
203
|
+
}, Ve = ({ copy: t }) => /* @__PURE__ */ r(h, { sx: { flexDirection: "row", gap: 12 }, children: [
|
|
204
|
+
/* @__PURE__ */ e(oe, { name: "elevation", size: 32, sx: { color: "text.primary" } }),
|
|
205
205
|
/* @__PURE__ */ r(h, { children: [
|
|
206
|
-
/* @__PURE__ */
|
|
207
|
-
/* @__PURE__ */
|
|
206
|
+
/* @__PURE__ */ e(m, { sx: { display: "block", fontWeight: 600 }, variant: "body1", children: t.empty_widget_header }),
|
|
207
|
+
/* @__PURE__ */ e(Ie, { sx: { color: "text.secondary" }, variant: "body2", children: t.zero_state_description })
|
|
208
208
|
] })
|
|
209
|
-
] }),
|
|
210
|
-
const [l, i] = d.useState(!1), { visibleAccounts: n } = J(), { onEvent: s } = Q(), { net_worth: o, common: a } = T(), { isInitialized: c, selectedAccounts: u, setSelectedAccounts: C } = P(), { loadChartData: x, loadNetWorthData: g, netWorthData: S, selectedData: p } =
|
|
209
|
+
] }), At = w(({ onCTAClick: t }) => {
|
|
210
|
+
const [l, i] = d.useState(!1), { visibleAccounts: n } = J(), { onEvent: s } = Q(), { net_worth: o, common: a } = T(), { isInitialized: c, selectedAccounts: u, setSelectedAccounts: C } = P(), { loadChartData: x, loadNetWorthData: g, netWorthData: S, selectedData: p } = ee(), f = async () => {
|
|
211
211
|
await g(u), await x(1), i(!0);
|
|
212
212
|
};
|
|
213
213
|
if (d.useEffect(() => C(n), [n]), d.useEffect(() => {
|
|
214
214
|
c && f().finally(), s(b.NET_WORTH_LOAD_WIDGET, {
|
|
215
215
|
state: n?.length ? "default" : "zeroState"
|
|
216
216
|
});
|
|
217
|
-
}, [c]), !l) return /* @__PURE__ */
|
|
217
|
+
}, [c]), !l) return /* @__PURE__ */ e(O, { height: 100 });
|
|
218
218
|
const L = () => {
|
|
219
219
|
s(
|
|
220
220
|
n.length ? b.NET_WORTH_CLICK_VIEW_DETAILS : b.NET_WORTH_CLICK_GET_STARTED
|
|
221
|
-
),
|
|
221
|
+
), t();
|
|
222
222
|
};
|
|
223
|
-
return /* @__PURE__ */
|
|
224
|
-
|
|
223
|
+
return /* @__PURE__ */ e(
|
|
224
|
+
Ae,
|
|
225
225
|
{
|
|
226
226
|
className: "mx-networth-microwidget",
|
|
227
227
|
ctaLabel: a.see_details,
|
|
228
228
|
onCTAClick: L,
|
|
229
229
|
title: o.net_worth,
|
|
230
|
-
children: S.accounts.length ? /* @__PURE__ */
|
|
231
|
-
|
|
230
|
+
children: S.accounts.length ? /* @__PURE__ */ e(
|
|
231
|
+
Ue,
|
|
232
232
|
{
|
|
233
233
|
amount: p?.y,
|
|
234
234
|
copy: o,
|
|
235
235
|
trendValue: p?.change
|
|
236
236
|
}
|
|
237
|
-
) : /* @__PURE__ */
|
|
237
|
+
) : /* @__PURE__ */ e(Ve, { copy: o })
|
|
238
238
|
}
|
|
239
239
|
);
|
|
240
|
-
}),
|
|
240
|
+
}), Ye = ({ accounts: t, name: l, icon: i }) => {
|
|
241
241
|
const [n, s] = d.useState(!1);
|
|
242
242
|
return /* @__PURE__ */ r(v, { children: [
|
|
243
|
-
/* @__PURE__ */
|
|
244
|
-
i && /* @__PURE__ */
|
|
245
|
-
/* @__PURE__ */
|
|
243
|
+
/* @__PURE__ */ e(k, { sx: (o) => ({ backgroundColor: o.palette.background.paper }), children: /* @__PURE__ */ r(te, { onClick: () => s(!n), children: [
|
|
244
|
+
i && /* @__PURE__ */ e(V, { children: /* @__PURE__ */ e(H, { name: i, size: 24, sx: { mr: 12 } }) }),
|
|
245
|
+
/* @__PURE__ */ e(
|
|
246
246
|
_,
|
|
247
247
|
{
|
|
248
|
-
primary: /* @__PURE__ */
|
|
248
|
+
primary: /* @__PURE__ */ e(m, { sx: { fontWeight: 700 }, variant: "Body", children: l })
|
|
249
249
|
}
|
|
250
250
|
),
|
|
251
|
-
/* @__PURE__ */
|
|
251
|
+
/* @__PURE__ */ e(V, { children: n ? /* @__PURE__ */ e(H, { name: "expand_less", size: 24 }) : /* @__PURE__ */ e(H, { name: "expand_more", size: 24 }) })
|
|
252
252
|
] }) }),
|
|
253
|
-
/* @__PURE__ */
|
|
254
|
-
/* @__PURE__ */
|
|
255
|
-
/* @__PURE__ */
|
|
253
|
+
/* @__PURE__ */ e(W, {}),
|
|
254
|
+
/* @__PURE__ */ e(He, { in: n, timeout: "auto", unmountOnExit: !0, children: t.map((o, a) => /* @__PURE__ */ r(B, { children: [
|
|
255
|
+
/* @__PURE__ */ e(k, { sx: () => ({ py: 14 }), children: /* @__PURE__ */ e(
|
|
256
256
|
_,
|
|
257
257
|
{
|
|
258
258
|
primary: /* @__PURE__ */ r(h, { direction: "row", justifyContent: "space-between", sx: { fontWeight: 400 }, children: [
|
|
259
|
-
/* @__PURE__ */
|
|
259
|
+
/* @__PURE__ */ e(
|
|
260
260
|
m,
|
|
261
261
|
{
|
|
262
262
|
sx: {
|
|
@@ -266,7 +266,7 @@ const Rt = ({
|
|
|
266
266
|
children: o.accountName
|
|
267
267
|
}
|
|
268
268
|
),
|
|
269
|
-
/* @__PURE__ */
|
|
269
|
+
/* @__PURE__ */ e(
|
|
270
270
|
y,
|
|
271
271
|
{
|
|
272
272
|
amount: o.balance,
|
|
@@ -280,20 +280,20 @@ const Rt = ({
|
|
|
280
280
|
sx: { pl: 72, pr: 16 }
|
|
281
281
|
}
|
|
282
282
|
) }),
|
|
283
|
-
a <
|
|
283
|
+
a < t.length - 1 ? /* @__PURE__ */ e(W, { variant: "inset" }) : /* @__PURE__ */ e(W, {})
|
|
284
284
|
] }, o.accountName)) })
|
|
285
285
|
] });
|
|
286
|
-
}, q = ({ groupedAccounts:
|
|
287
|
-
netWorth:
|
|
286
|
+
}, q = ({ groupedAccounts: t }) => /* @__PURE__ */ e(v, { children: t.map(({ accounts: l, icon: i, name: n }) => /* @__PURE__ */ e(Ye, { accounts: l, icon: i, name: n }, n)) }), qe = ({
|
|
287
|
+
netWorth: t,
|
|
288
288
|
assets: l,
|
|
289
289
|
liabilities: i,
|
|
290
290
|
totalAssets: n,
|
|
291
291
|
totalLiabilities: s
|
|
292
292
|
}) => {
|
|
293
|
-
const { net_worth: o } = T(), a =
|
|
293
|
+
const { net_worth: o } = T(), a = ie();
|
|
294
294
|
return /* @__PURE__ */ r(v, { children: [
|
|
295
295
|
/* @__PURE__ */ r(
|
|
296
|
-
|
|
296
|
+
re,
|
|
297
297
|
{
|
|
298
298
|
sx: {
|
|
299
299
|
alignItems: "center",
|
|
@@ -304,14 +304,14 @@ const Rt = ({
|
|
|
304
304
|
marginBottom: 8
|
|
305
305
|
},
|
|
306
306
|
children: [
|
|
307
|
-
/* @__PURE__ */
|
|
308
|
-
/* @__PURE__ */
|
|
309
|
-
|
|
307
|
+
/* @__PURE__ */ e(m, { variant: "Body", children: o.current_net_worth }),
|
|
308
|
+
/* @__PURE__ */ e(y, { amount: t?.y ?? 0, variant: "H1" }),
|
|
309
|
+
t && /* @__PURE__ */ e(
|
|
310
310
|
R,
|
|
311
311
|
{
|
|
312
312
|
currencyLabel: o.this_month,
|
|
313
313
|
iconSize: 20,
|
|
314
|
-
netWorth:
|
|
314
|
+
netWorth: t,
|
|
315
315
|
theme: a
|
|
316
316
|
}
|
|
317
317
|
)
|
|
@@ -319,59 +319,59 @@ const Rt = ({
|
|
|
319
319
|
}
|
|
320
320
|
),
|
|
321
321
|
/* @__PURE__ */ r(B, { children: [
|
|
322
|
-
/* @__PURE__ */
|
|
322
|
+
/* @__PURE__ */ e(E, { sx: { mb: 8, mt: 12, mx: 8 }, children: /* @__PURE__ */ e(
|
|
323
323
|
_,
|
|
324
324
|
{
|
|
325
325
|
primary: /* @__PURE__ */ r(h, { direction: "row", justifyContent: "space-between", children: [
|
|
326
|
-
/* @__PURE__ */
|
|
327
|
-
/* @__PURE__ */
|
|
326
|
+
/* @__PURE__ */ e(m, { sx: { fontWeight: 700 }, variant: "XSmall", children: o.assets }),
|
|
327
|
+
/* @__PURE__ */ e(y, { amount: n, sx: { fontWeight: 400 }, variant: "XSmall" })
|
|
328
328
|
] })
|
|
329
329
|
}
|
|
330
330
|
) }),
|
|
331
|
-
/* @__PURE__ */
|
|
332
|
-
/* @__PURE__ */
|
|
331
|
+
/* @__PURE__ */ e(q, { groupedAccounts: K(l) }),
|
|
332
|
+
/* @__PURE__ */ e(E, { sx: { mb: 8, mt: 12, mx: 8 }, children: /* @__PURE__ */ e(
|
|
333
333
|
_,
|
|
334
334
|
{
|
|
335
335
|
primary: /* @__PURE__ */ r(h, { direction: "row", justifyContent: "space-between", children: [
|
|
336
|
-
/* @__PURE__ */
|
|
337
|
-
/* @__PURE__ */
|
|
336
|
+
/* @__PURE__ */ e(m, { sx: { fontWeight: 700 }, variant: "XSmall", children: o.liabilities }),
|
|
337
|
+
/* @__PURE__ */ e(y, { amount: s, sx: { fontWeight: 400 }, variant: "XSmall" })
|
|
338
338
|
] })
|
|
339
339
|
}
|
|
340
340
|
) }),
|
|
341
|
-
/* @__PURE__ */
|
|
341
|
+
/* @__PURE__ */ e(q, { groupedAccounts: K(i) })
|
|
342
342
|
] })
|
|
343
343
|
] });
|
|
344
|
-
},
|
|
345
|
-
netWorth:
|
|
344
|
+
}, Ze = w(qe), Je = ({
|
|
345
|
+
netWorth: t,
|
|
346
346
|
gains: l,
|
|
347
347
|
losses: i,
|
|
348
348
|
totalGains: n,
|
|
349
349
|
totalLosses: s
|
|
350
350
|
}) => {
|
|
351
|
-
const { net_worth: o } = T(), a =
|
|
351
|
+
const { net_worth: o } = T(), a = ie();
|
|
352
352
|
return /* @__PURE__ */ r(v, { children: [
|
|
353
353
|
/* @__PURE__ */ r(h, { alignItems: "center", justifyContent: "space-between", mb: 8, pt: 24, children: [
|
|
354
|
-
/* @__PURE__ */
|
|
355
|
-
/* @__PURE__ */
|
|
356
|
-
|
|
354
|
+
/* @__PURE__ */ e(m, { variant: "Small", children: ne(t?.x) }),
|
|
355
|
+
/* @__PURE__ */ e(m, { variant: "Body", children: o.total_change }),
|
|
356
|
+
t && /* @__PURE__ */ e(R, { currencyVariant: "H1", iconSize: 32, netWorth: t, theme: a })
|
|
357
357
|
] }),
|
|
358
358
|
/* @__PURE__ */ r(B, { children: [
|
|
359
|
-
/* @__PURE__ */
|
|
359
|
+
/* @__PURE__ */ e(E, { sx: { mb: 8, mt: 12, mx: 8 }, children: /* @__PURE__ */ e(
|
|
360
360
|
_,
|
|
361
361
|
{
|
|
362
362
|
primary: /* @__PURE__ */ r(h, { direction: "row", justifyContent: "space-between", children: [
|
|
363
|
-
/* @__PURE__ */
|
|
364
|
-
/* @__PURE__ */
|
|
363
|
+
/* @__PURE__ */ e(m, { sx: { fontWeight: 700 }, variant: "XSmall", children: o.gains }),
|
|
364
|
+
/* @__PURE__ */ e(y, { amount: n, sx: { fontWeight: 400 }, variant: "XSmall" })
|
|
365
365
|
] })
|
|
366
366
|
}
|
|
367
367
|
) }),
|
|
368
368
|
l?.map((c) => /* @__PURE__ */ r(d.Fragment, { children: [
|
|
369
|
-
/* @__PURE__ */
|
|
369
|
+
/* @__PURE__ */ e(k, { sx: { backgroundColor: a.palette.background.paper, py: 14 }, children: /* @__PURE__ */ e(
|
|
370
370
|
_,
|
|
371
371
|
{
|
|
372
372
|
primary: /* @__PURE__ */ r(h, { direction: "row", justifyContent: "space-between", children: [
|
|
373
|
-
/* @__PURE__ */
|
|
374
|
-
/* @__PURE__ */
|
|
373
|
+
/* @__PURE__ */ e(m, { sx: { mr: 10 }, variant: "Body", children: c.accountName }),
|
|
374
|
+
/* @__PURE__ */ e(
|
|
375
375
|
y,
|
|
376
376
|
{
|
|
377
377
|
amount: c.gain,
|
|
@@ -383,27 +383,27 @@ const Rt = ({
|
|
|
383
383
|
sx: { px: 16 }
|
|
384
384
|
}
|
|
385
385
|
) }),
|
|
386
|
-
/* @__PURE__ */
|
|
386
|
+
/* @__PURE__ */ e(W, {})
|
|
387
387
|
] }, c.accountName)),
|
|
388
|
-
/* @__PURE__ */
|
|
388
|
+
/* @__PURE__ */ e(E, { sx: { mb: 8, mt: 12, mx: 8 }, children: /* @__PURE__ */ e(
|
|
389
389
|
_,
|
|
390
390
|
{
|
|
391
391
|
primary: /* @__PURE__ */ r(h, { direction: "row", justifyContent: "space-between", children: [
|
|
392
|
-
/* @__PURE__ */
|
|
393
|
-
/* @__PURE__ */
|
|
392
|
+
/* @__PURE__ */ e(m, { sx: { fontWeight: 700 }, variant: "XSmall", children: o.losses }),
|
|
393
|
+
/* @__PURE__ */ e(y, { amount: s, sx: { fontWeight: 400 }, variant: "XSmall" })
|
|
394
394
|
] })
|
|
395
395
|
}
|
|
396
396
|
) }),
|
|
397
397
|
i?.map((c) => /* @__PURE__ */ r(v, { children: [
|
|
398
|
-
/* @__PURE__ */
|
|
398
|
+
/* @__PURE__ */ e(
|
|
399
399
|
k,
|
|
400
400
|
{
|
|
401
401
|
sx: { backgroundColor: a.palette.background.paper, py: 14 },
|
|
402
|
-
children: /* @__PURE__ */
|
|
402
|
+
children: /* @__PURE__ */ e(
|
|
403
403
|
_,
|
|
404
404
|
{
|
|
405
405
|
primary: /* @__PURE__ */ r(h, { direction: "row", justifyContent: "space-between", children: [
|
|
406
|
-
/* @__PURE__ */
|
|
406
|
+
/* @__PURE__ */ e(
|
|
407
407
|
m,
|
|
408
408
|
{
|
|
409
409
|
sx: {
|
|
@@ -413,7 +413,7 @@ const Rt = ({
|
|
|
413
413
|
children: c.accountName
|
|
414
414
|
}
|
|
415
415
|
),
|
|
416
|
-
/* @__PURE__ */
|
|
416
|
+
/* @__PURE__ */ e(
|
|
417
417
|
y,
|
|
418
418
|
{
|
|
419
419
|
amount: c.loss,
|
|
@@ -428,11 +428,11 @@ const Rt = ({
|
|
|
428
428
|
},
|
|
429
429
|
c.accountName
|
|
430
430
|
),
|
|
431
|
-
/* @__PURE__ */
|
|
431
|
+
/* @__PURE__ */ e(W, {})
|
|
432
432
|
] }))
|
|
433
433
|
] })
|
|
434
434
|
] });
|
|
435
|
-
},
|
|
435
|
+
}, Qe = w(Je), Mt = w(({ onBackClick: t }) => {
|
|
436
436
|
const { isCopyLoaded: l, isInitialized: i, selectedAccounts: n, setSelectedAccounts: s } = P(), { accounts: o, net_worth: a } = T(), { visibleAccounts: c } = J(), {
|
|
437
437
|
assetsLiabilities: u,
|
|
438
438
|
gainsLosses: C,
|
|
@@ -442,53 +442,51 @@ const Rt = ({
|
|
|
442
442
|
netWorthChartData: p,
|
|
443
443
|
selectedData: f,
|
|
444
444
|
setHoveredData: L,
|
|
445
|
-
setSelectedData:
|
|
446
|
-
} =
|
|
447
|
-
await S(n), await g(A),
|
|
445
|
+
setSelectedData: ae
|
|
446
|
+
} = ee(), { isMobile: N } = Z(), { onEvent: D } = Q(), [se, ce] = d.useState(!1), [A, le] = d.useState(6), [me, j] = d.useState(!1), [de, $] = d.useState(!1), [he, G] = d.useState(!1), ue = async () => {
|
|
447
|
+
await S(n), await g(A), ce(!0);
|
|
448
448
|
};
|
|
449
449
|
d.useEffect(() => {
|
|
450
450
|
D(b.NET_WORTH_VIEW);
|
|
451
451
|
}, []), d.useEffect(() => {
|
|
452
452
|
s(c);
|
|
453
453
|
}, [c]), d.useEffect(() => {
|
|
454
|
-
i &&
|
|
455
|
-
st?.("NetWorthWidget");
|
|
456
|
-
});
|
|
454
|
+
i && ue().finally();
|
|
457
455
|
}, [i, n]), d.useEffect(() => {
|
|
458
456
|
D(b.NET_WORTH_WIDGET_CLICK_TIMEFRAME, { time_period: A + "M" }), g(A).finally();
|
|
459
457
|
}, [A]);
|
|
460
|
-
const
|
|
461
|
-
|
|
462
|
-
},
|
|
458
|
+
const pe = (I, M) => {
|
|
459
|
+
ae(M), I.currentTarget instanceof HTMLDivElement && j(!0);
|
|
460
|
+
}, fe = (I) => {
|
|
463
461
|
L(I);
|
|
464
|
-
},
|
|
462
|
+
}, xe = () => {
|
|
465
463
|
L(null);
|
|
466
|
-
},
|
|
464
|
+
}, ge = () => {
|
|
467
465
|
D(b.NET_WORTH_WIDGET_CLICK_ASSETS_LIABILITIES), $(!0);
|
|
468
|
-
},
|
|
466
|
+
}, ye = async (I) => {
|
|
469
467
|
const M = I[0], F = I[1];
|
|
470
|
-
M && F &&
|
|
468
|
+
M && F && le(Ee(F, M));
|
|
471
469
|
}, X = {
|
|
472
470
|
chartData: p,
|
|
473
471
|
hoveredData: x,
|
|
474
|
-
onButtonClick:
|
|
475
|
-
onDataClick:
|
|
476
|
-
onMouseEnter:
|
|
477
|
-
onMouseLeave:
|
|
472
|
+
onButtonClick: ge,
|
|
473
|
+
onDataClick: pe,
|
|
474
|
+
onMouseEnter: fe,
|
|
475
|
+
onMouseLeave: xe,
|
|
478
476
|
selectedData: f
|
|
479
|
-
},
|
|
477
|
+
}, Ce = () => {
|
|
480
478
|
G(!0), D(b.ACCOUNTS_CLICK_CONNECT);
|
|
481
479
|
};
|
|
482
|
-
return l ? /* @__PURE__ */
|
|
483
|
-
|
|
480
|
+
return l ? /* @__PURE__ */ e(
|
|
481
|
+
ke,
|
|
484
482
|
{
|
|
485
483
|
accountOptions: c,
|
|
486
484
|
calendarActions: {
|
|
487
|
-
onRangeChanged:
|
|
485
|
+
onRangeChanged: ye
|
|
488
486
|
},
|
|
489
487
|
dateRangeVariant: N ? "timeframetabs" : "timeframebuttons",
|
|
490
488
|
onAccountsFilterClick: () => D(b.NET_WORTH_WIDGET_CLICK_FILTER),
|
|
491
|
-
onBackClick:
|
|
489
|
+
onBackClick: t,
|
|
492
490
|
showDividerAboveDateSelector: !1,
|
|
493
491
|
sx: {
|
|
494
492
|
p: N ? 0 : 48,
|
|
@@ -504,9 +502,9 @@ const Rt = ({
|
|
|
504
502
|
}
|
|
505
503
|
},
|
|
506
504
|
title: a.net_worth,
|
|
507
|
-
children:
|
|
505
|
+
children: se ? /* @__PURE__ */ r(v, { children: [
|
|
508
506
|
p.length ? /* @__PURE__ */ r(v, { children: [
|
|
509
|
-
f && /* @__PURE__ */
|
|
507
|
+
f && /* @__PURE__ */ e(Ke, { hoveredData: x, selectedData: f }),
|
|
510
508
|
/* @__PURE__ */ r(
|
|
511
509
|
h,
|
|
512
510
|
{
|
|
@@ -514,17 +512,17 @@ const Rt = ({
|
|
|
514
512
|
direction: N ? "column" : "row",
|
|
515
513
|
spacing: N ? 0 : 48,
|
|
516
514
|
children: [
|
|
517
|
-
/* @__PURE__ */
|
|
518
|
-
/* @__PURE__ */
|
|
515
|
+
/* @__PURE__ */ e(ze, { ...X }),
|
|
516
|
+
/* @__PURE__ */ e(Ge, { ...X })
|
|
519
517
|
]
|
|
520
518
|
}
|
|
521
519
|
)
|
|
522
|
-
] }) : /* @__PURE__ */
|
|
523
|
-
|
|
520
|
+
] }) : /* @__PURE__ */ e(re, { sx: { justifyItems: "center" }, children: /* @__PURE__ */ e(
|
|
521
|
+
Be,
|
|
524
522
|
{
|
|
525
523
|
header: a.empty_widget_header,
|
|
526
524
|
icon: "elevation",
|
|
527
|
-
onClick:
|
|
525
|
+
onClick: Ce,
|
|
528
526
|
primaryButton: a.empty_widget_button,
|
|
529
527
|
subText: a.empty_widget_description,
|
|
530
528
|
sx: {
|
|
@@ -535,47 +533,47 @@ const Rt = ({
|
|
|
535
533
|
}
|
|
536
534
|
}
|
|
537
535
|
) }),
|
|
538
|
-
/* @__PURE__ */
|
|
539
|
-
|
|
536
|
+
/* @__PURE__ */ e(
|
|
537
|
+
Me,
|
|
540
538
|
{
|
|
541
539
|
onClose: () => G(!1),
|
|
542
|
-
showConnectionsWidget:
|
|
540
|
+
showConnectionsWidget: he,
|
|
543
541
|
title: o.manage_connections
|
|
544
542
|
}
|
|
545
543
|
),
|
|
546
|
-
/* @__PURE__ */
|
|
544
|
+
/* @__PURE__ */ e(
|
|
547
545
|
Y,
|
|
548
546
|
{
|
|
549
547
|
ariaLabelClose: "Close",
|
|
550
|
-
isOpen:
|
|
548
|
+
isOpen: me,
|
|
551
549
|
onClose: () => j(!1),
|
|
552
550
|
shouldShowHeaderBorders: !1,
|
|
553
551
|
shouldShowHeaderShadow: !0,
|
|
554
552
|
title: a.gains_and_losses,
|
|
555
|
-
children: C && /* @__PURE__ */
|
|
553
|
+
children: C && /* @__PURE__ */ e(Qe, { ...C })
|
|
556
554
|
}
|
|
557
555
|
),
|
|
558
|
-
/* @__PURE__ */
|
|
556
|
+
/* @__PURE__ */ e(
|
|
559
557
|
Y,
|
|
560
558
|
{
|
|
561
559
|
ariaLabelClose: "Close",
|
|
562
|
-
isOpen:
|
|
560
|
+
isOpen: de,
|
|
563
561
|
onClose: () => $(!1),
|
|
564
562
|
shouldShowHeaderBorders: !1,
|
|
565
563
|
shouldShowHeaderShadow: !0,
|
|
566
564
|
title: a.assets_and_liabilities,
|
|
567
|
-
children: u && /* @__PURE__ */
|
|
565
|
+
children: u && /* @__PURE__ */ e(Ze, { ...u })
|
|
568
566
|
}
|
|
569
567
|
)
|
|
570
|
-
] }) : /* @__PURE__ */
|
|
568
|
+
] }) : /* @__PURE__ */ e(O, {})
|
|
571
569
|
}
|
|
572
|
-
) : /* @__PURE__ */
|
|
570
|
+
) : /* @__PURE__ */ e(O, {});
|
|
573
571
|
});
|
|
574
572
|
export {
|
|
575
|
-
|
|
576
|
-
|
|
577
|
-
|
|
578
|
-
|
|
579
|
-
|
|
580
|
-
|
|
573
|
+
ze as NetWorthChart,
|
|
574
|
+
Ge as NetWorthList,
|
|
575
|
+
At as NetWorthMicroWidget,
|
|
576
|
+
Ot as NetWorthStore,
|
|
577
|
+
Ke as NetWorthSummary,
|
|
578
|
+
Mt as NetWorthWidget
|
|
581
579
|
};
|