@mx-cartographer/experiences 9.1.0-alpha.bb1 → 9.1.1
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 +80 -0
- package/README.md +10 -10
- package/dist/Account-DR7Plrqy.mjs +119 -0
- package/dist/Account-DR7Plrqy.mjs.map +1 -0
- package/dist/AccountDetailsDrawer-C1hhmlmI.mjs +922 -0
- package/dist/AccountDetailsDrawer-C1hhmlmI.mjs.map +1 -0
- package/dist/AccountDetailsHeader-BliEZhz7.mjs +230 -0
- package/dist/AccountDetailsHeader-BliEZhz7.mjs.map +1 -0
- package/dist/AccountUtils-Cbh8r9cP.mjs +29 -0
- package/dist/AccountUtils-Cbh8r9cP.mjs.map +1 -0
- package/dist/Analytics-CkYXKvco.mjs +54 -0
- package/dist/Analytics-CkYXKvco.mjs.map +1 -0
- package/dist/Analytics-WeZYytR0.mjs +140 -0
- package/dist/Analytics-WeZYytR0.mjs.map +1 -0
- package/dist/ApiEndpoints-DXwIYNUV.mjs +50 -0
- package/dist/ApiEndpoints-DXwIYNUV.mjs.map +1 -0
- package/dist/BeatMaterialIcon-1KOfRZrA.mjs +27 -0
- package/dist/BeatMaterialIcon-1KOfRZrA.mjs.map +1 -0
- package/dist/BudgetUtil-Bg2AQJpQ.mjs +75 -0
- package/dist/BudgetUtil-Bg2AQJpQ.mjs.map +1 -0
- package/dist/Category-DEKZGLYe.mjs +302 -0
- package/dist/Category-DEKZGLYe.mjs.map +1 -0
- package/dist/CategorySelectorDrawer-NJsFsKP1.mjs +431 -0
- package/dist/CategorySelectorDrawer-NJsFsKP1.mjs.map +1 -0
- package/dist/Connect-BH0Pt6zc.mjs +43 -0
- package/dist/Connect-BH0Pt6zc.mjs.map +1 -0
- package/dist/ConnectCard-D7uxoH5Y.mjs +55 -0
- package/dist/ConnectCard-D7uxoH5Y.mjs.map +1 -0
- package/dist/ConnectDrawer-CW4LA3H3.mjs +58 -0
- package/dist/ConnectDrawer-CW4LA3H3.mjs.map +1 -0
- package/dist/ConnectionsDrawer-CZU9ku-k.mjs +54 -0
- package/dist/ConnectionsDrawer-CZU9ku-k.mjs.map +1 -0
- package/dist/CurrencyDialog-DumQCTPO.mjs +374 -0
- package/dist/CurrencyDialog-DumQCTPO.mjs.map +1 -0
- package/dist/CurrencyInput-DaGEQaLW.mjs +88 -0
- package/dist/CurrencyInput-DaGEQaLW.mjs.map +1 -0
- package/dist/CurrencyText-CCbE6MmF.mjs +21 -0
- package/dist/CurrencyText-CCbE6MmF.mjs.map +1 -0
- package/dist/DateFormats-HudZ3Bjs.mjs +65 -0
- package/dist/DateFormats-HudZ3Bjs.mjs.map +1 -0
- package/dist/DateUtil-CzBmbjmA.mjs +75 -0
- package/dist/DateUtil-CzBmbjmA.mjs.map +1 -0
- package/dist/DebtUtils-i4pI2Uoe.mjs +154 -0
- package/dist/DebtUtils-i4pI2Uoe.mjs.map +1 -0
- package/dist/Dialog-Bvd2n8hz.mjs +67 -0
- package/dist/Dialog-Bvd2n8hz.mjs.map +1 -0
- package/dist/Donut-SzzfZDHF.mjs +89 -0
- package/dist/Donut-SzzfZDHF.mjs.map +1 -0
- package/dist/Drawer-DsnW2o0v.mjs +175 -0
- package/dist/Drawer-DsnW2o0v.mjs.map +1 -0
- package/dist/EmbeddedCard-DH8vQ3qN.mjs +859 -0
- package/dist/EmbeddedCard-DH8vQ3qN.mjs.map +1 -0
- package/dist/EmptyState-CJUDc3kD.mjs +85 -0
- package/dist/EmptyState-CJUDc3kD.mjs.map +1 -0
- package/dist/Error-Dtw6yxkf.mjs +85 -0
- package/dist/Error-Dtw6yxkf.mjs.map +1 -0
- package/dist/ErrorBoundary-CsdOcnJ9.mjs +24 -0
- package/dist/ErrorBoundary-CsdOcnJ9.mjs.map +1 -0
- package/dist/ExportCsvAction-C9KWH3Az.mjs +25 -0
- package/dist/ExportCsvAction-C9KWH3Az.mjs.map +1 -0
- package/dist/GlobalAccountFilter-BhzR5Vb1.mjs +230 -0
- package/dist/GlobalAccountFilter-BhzR5Vb1.mjs.map +1 -0
- package/dist/GlobalCopyApi-wcnDUzMV.mjs +129 -0
- package/dist/GlobalCopyApi-wcnDUzMV.mjs.map +1 -0
- package/dist/GoalsUtil-C9EnLWvC.mjs +108 -0
- package/dist/GoalsUtil-C9EnLWvC.mjs.map +1 -0
- package/dist/HeaderCell-P8w6CmfO.mjs +7 -0
- package/dist/HeaderCell-P8w6CmfO.mjs.map +1 -0
- package/dist/Help-CkQTjORd.mjs +300 -0
- package/dist/Help-CkQTjORd.mjs.map +1 -0
- package/dist/Help-aERwhajy.mjs +3210 -0
- package/dist/Help-aERwhajy.mjs.map +1 -0
- package/dist/IconBacking-DgT8DCeh.mjs +40 -0
- package/dist/IconBacking-DgT8DCeh.mjs.map +1 -0
- package/dist/InformationTooltip-4su8bn1e.mjs +42 -0
- package/dist/InformationTooltip-4su8bn1e.mjs.map +1 -0
- package/dist/InvestmentUtil-BItV7uEs.mjs +135 -0
- package/dist/InvestmentUtil-BItV7uEs.mjs.map +1 -0
- package/dist/LineChart-CUfiH86G.mjs +613 -0
- package/dist/LineChart-CUfiH86G.mjs.map +1 -0
- package/dist/ListItemAction-BqUCLj_w.mjs +70 -0
- package/dist/ListItemAction-BqUCLj_w.mjs.map +1 -0
- package/dist/ListItemRow-kH1rn8Xu.mjs +68 -0
- package/dist/ListItemRow-kH1rn8Xu.mjs.map +1 -0
- package/dist/ListItemWrapper-DRse79Iu.mjs +44 -0
- package/dist/ListItemWrapper-DRse79Iu.mjs.map +1 -0
- package/dist/Loader-CxeBwuPG.mjs +22 -0
- package/dist/Loader-CxeBwuPG.mjs.map +1 -0
- package/dist/Localization-DnoVyBNK.mjs +39 -0
- package/dist/Localization-DnoVyBNK.mjs.map +1 -0
- package/dist/ManageIncome-Be9WHv-s.mjs +906 -0
- package/dist/ManageIncome-Be9WHv-s.mjs.map +1 -0
- package/dist/MicroWidgetContainer-B2NnKBgW.mjs +46 -0
- package/dist/MicroWidgetContainer-B2NnKBgW.mjs.map +1 -0
- package/dist/MiniWidgetContainer-Bmv_WeUd.mjs +67 -0
- package/dist/MiniWidgetContainer-Bmv_WeUd.mjs.map +1 -0
- package/dist/NetWorthUtils-Dj7CgAg2.mjs +96 -0
- package/dist/NetWorthUtils-Dj7CgAg2.mjs.map +1 -0
- package/dist/Notification-DTNYSd8P.mjs +8 -0
- package/dist/Notification-DTNYSd8P.mjs.map +1 -0
- package/dist/NotificationSettings-CW7okUrk.mjs +678 -0
- package/dist/NotificationSettings-CW7okUrk.mjs.map +1 -0
- package/dist/NotificationUtils-BRGFTePr.mjs +24 -0
- package/dist/NotificationUtils-BRGFTePr.mjs.map +1 -0
- package/dist/NumberFormatting--XMeeBfr.mjs +50 -0
- package/dist/NumberFormatting--XMeeBfr.mjs.map +1 -0
- package/dist/OriginalBalanceAction-YrvxBYAl.mjs +115 -0
- package/dist/OriginalBalanceAction-YrvxBYAl.mjs.map +1 -0
- package/dist/RecurringSettings-kRqAViNn.mjs +89 -0
- package/dist/RecurringSettings-kRqAViNn.mjs.map +1 -0
- package/dist/RecurringTransactionsUtil-CHWmqvW5.mjs +299 -0
- package/dist/RecurringTransactionsUtil-CHWmqvW5.mjs.map +1 -0
- package/dist/ResponsiveButton-CC9F_Ezk.mjs +46 -0
- package/dist/ResponsiveButton-CC9F_Ezk.mjs.map +1 -0
- package/dist/SearchBox-Cpgu_gdO.mjs +51 -0
- package/dist/SearchBox-Cpgu_gdO.mjs.map +1 -0
- package/dist/Select-CSpkK5cR.mjs +62 -0
- package/dist/Select-CSpkK5cR.mjs.map +1 -0
- package/dist/SelectionBox-B4xELRgp.mjs +49 -0
- package/dist/SelectionBox-B4xELRgp.mjs.map +1 -0
- package/dist/SingleSegmentDonut-7Uy6VEld.mjs +70 -0
- package/dist/SingleSegmentDonut-7Uy6VEld.mjs.map +1 -0
- package/dist/Sizes-DISGrlUg.mjs +7 -0
- package/dist/Sizes-DISGrlUg.mjs.map +1 -0
- package/dist/SkeletonLoader-BaNboJjD.mjs +39 -0
- package/dist/SkeletonLoader-BaNboJjD.mjs.map +1 -0
- package/dist/SpendingData-Fii_xATx.mjs +54 -0
- package/dist/SpendingData-Fii_xATx.mjs.map +1 -0
- package/dist/SpendingLegend-CxvNOg3c.mjs +204 -0
- package/dist/SpendingLegend-CxvNOg3c.mjs.map +1 -0
- package/dist/StatusBar-CPfSXe80.mjs +31 -0
- package/dist/StatusBar-CPfSXe80.mjs.map +1 -0
- package/dist/TabContentContainer-B0eYJP5p.mjs +49 -0
- package/dist/TabContentContainer-B0eYJP5p.mjs.map +1 -0
- package/dist/ToggleListItem-Dl1lXNwj.mjs +92 -0
- package/dist/ToggleListItem-Dl1lXNwj.mjs.map +1 -0
- package/dist/TransactionDetails-roZ5xLq8.mjs +1708 -0
- package/dist/TransactionDetails-roZ5xLq8.mjs.map +1 -0
- package/dist/TransactionUtils-BphBJBbU.mjs +235 -0
- package/dist/TransactionUtils-BphBJBbU.mjs.map +1 -0
- package/dist/TrendsUtil-D9z3kIj_.mjs +70 -0
- package/dist/TrendsUtil-D9z3kIj_.mjs.map +1 -0
- package/dist/UserStore-BjnNCO5a.mjs +3121 -0
- package/dist/UserStore-BjnNCO5a.mjs.map +1 -0
- package/dist/ViewMoreMicroCard-fnwE0hqd.mjs +1280 -0
- package/dist/ViewMoreMicroCard-fnwE0hqd.mjs.map +1 -0
- package/dist/WidgetContainer-DJnp6t6c.mjs +483 -0
- package/dist/WidgetContainer-DJnp6t6c.mjs.map +1 -0
- package/dist/accounts/components/detailsdrawer/Accounts/AccountDetailsDrawer.d.ts +6 -0
- package/dist/accounts/index.d.ts +1 -0
- package/dist/accounts/index.es.js +784 -12
- package/dist/accounts/index.es.js.map +1 -0
- package/dist/analytics/index.es.js +140 -155
- package/dist/analytics/index.es.js.map +1 -0
- package/dist/budgets/index.es.js +1267 -1317
- package/dist/budgets/index.es.js.map +1 -0
- package/dist/cashflow/context/hooks.d.ts +7 -6
- package/dist/cashflow/index.es.js +944 -1076
- package/dist/cashflow/index.es.js.map +1 -0
- package/dist/categories/index.es.js +5 -4
- package/dist/categories/index.es.js.map +1 -0
- package/dist/common/components/DataRow.d.ts +1 -0
- package/dist/common/components/ListItemWrapper.d.ts +2 -1
- package/dist/common/constants/Analytics.d.ts +3 -0
- package/dist/common/index.es.js +310 -101
- package/dist/common/index.es.js.map +1 -0
- package/dist/core/index.es.js +105 -80
- package/dist/core/index.es.js.map +1 -0
- package/dist/core/stores/CashflowStore.d.ts +8 -7
- package/dist/core/stores/RecurringTransactionsStore.d.ts +53 -1
- package/dist/core/stores/TransactionStore.d.ts +1 -0
- package/dist/core/types/localization/RecurringCopy.d.ts +14 -1
- package/dist/core/types/localization/SpendingCopy.d.ts +1 -0
- package/dist/core/utils/AccountUtils.d.ts +8 -0
- package/dist/core/utils/DateUtil.d.ts +2 -0
- package/dist/core/utils/RecurringTransactionsUtil.d.ts +2 -1
- package/dist/dashboard/index.es.js +142 -185
- package/dist/dashboard/index.es.js.map +1 -0
- package/dist/debts/index.es.js +1273 -1384
- package/dist/debts/index.es.js.map +1 -0
- package/dist/finstrong/index.es.js +3473 -3367
- package/dist/finstrong/index.es.js.map +1 -0
- package/dist/goals/index.es.js +984 -1103
- package/dist/goals/index.es.js.map +1 -0
- package/dist/help/index.es.js +26 -3
- package/dist/help/index.es.js.map +1 -0
- package/dist/hooks-97sNJ_lf.mjs +78 -0
- package/dist/hooks-97sNJ_lf.mjs.map +1 -0
- package/dist/insights/components/insights/WeeklyNoSpendDays/BubbleWeek.d.ts +4 -1
- package/dist/insights/components/insights/WeeklyNoSpendDays/WeeklyNoSpendDays.d.ts +4 -2
- package/dist/insights/index.es.js +4871 -93
- package/dist/insights/index.es.js.map +1 -0
- package/dist/investments/index.es.js +1523 -1533
- package/dist/investments/index.es.js.map +1 -0
- package/dist/merchants/index.es.js +65 -75
- package/dist/merchants/index.es.js.map +1 -0
- package/dist/microinsights/index.es.js +826 -15
- package/dist/microinsights/index.es.js.map +1 -0
- package/dist/networth/index.es.js +504 -550
- package/dist/networth/index.es.js.map +1 -0
- package/dist/notifications/index.es.js +162 -169
- package/dist/notifications/index.es.js.map +1 -0
- package/dist/recurringtransactions/components/RecurringTransactionDetails.d.ts +3 -2
- package/dist/recurringtransactions/components/RecurringTransactionDetailsDrawer.d.ts +3 -0
- package/dist/recurringtransactions/components/RecurringTransactionList.d.ts +11 -0
- package/dist/recurringtransactions/components/UpcomingRecurrenceCard.d.ts +8 -0
- package/dist/recurringtransactions/components/actions/LinkTransactionDrawer.d.ts +10 -0
- package/dist/recurringtransactions/components/actions/MarkAsPaidDialog.d.ts +7 -0
- package/dist/recurringtransactions/components/actions/MarkAsUnpaidDialog.d.ts +7 -0
- package/dist/recurringtransactions/index.es.js +1012 -10
- package/dist/recurringtransactions/index.es.js.map +1 -0
- package/dist/settings/index.es.js +892 -13
- package/dist/settings/index.es.js.map +1 -0
- package/dist/spending/index.es.js +457 -400
- package/dist/spending/index.es.js.map +1 -0
- package/dist/transactions/components/shared/transactionlist/TransactionRow.d.ts +1 -0
- package/dist/transactions/index.es.js +604 -10
- package/dist/transactions/index.es.js.map +1 -0
- package/dist/trends/index.es.js +1408 -1268
- package/dist/trends/index.es.js.map +1 -0
- package/dist/useAccountDisplayName-BsiXA0qf.mjs +24 -0
- package/dist/useAccountDisplayName-BsiXA0qf.mjs.map +1 -0
- package/dist/useAriaLive-MkYebyUR.mjs +36 -0
- package/dist/useAriaLive-MkYebyUR.mjs.map +1 -0
- package/dist/useDimensions-CeDR9V8N.mjs +37 -0
- package/dist/useDimensions-CeDR9V8N.mjs.map +1 -0
- package/dist/useInsightsEnabled-D5Sdm0TJ.mjs +12 -0
- package/dist/useInsightsEnabled-D5Sdm0TJ.mjs.map +1 -0
- package/dist/useScreenSize-mWpmnh5w.mjs +37 -0
- package/dist/useScreenSize-mWpmnh5w.mjs.map +1 -0
- package/dist/useWidgetLoadTimer-B0tB-yzL.mjs +20 -0
- package/dist/useWidgetLoadTimer-B0tB-yzL.mjs.map +1 -0
- package/package.json +30 -30
- package/dist/Analytics-BKzTPees.mjs +0 -61
- package/dist/GlobalCopyApi-BeXzaDH9.mjs +0 -487
- package/dist/HeaderCell-EhCUSjvj.mjs +0 -10
- package/dist/Loader-BlVzRtUd.mjs +0 -73
- package/dist/MiniWidgetContainer-COwnjfy7.mjs +0 -110
- package/dist/OriginalBalanceAction-sbiqaxok.mjs +0 -110
- package/dist/SpendingLegend-D15ixlQ1.mjs +0 -222
- package/dist/accounts-DkyAiLpg.mjs +0 -15632
- package/dist/core-BexP5oiV.mjs +0 -4047
- package/dist/help-CctDYrAH.mjs +0 -2308
- package/dist/insights/components/insights/P2pCategorization/_tests_/P2pCategorizationMultipleTransaction.test.d.ts +0 -0
- package/dist/insights/components/insights/P2pCategorization/_tests_/P2pCategorizationSingleTransaction.test.d.ts +0 -0
- package/dist/microinsights-CRf3ChsJ.mjs +0 -1814
- package/dist/recurringtransactions-gbJ_NA8u.mjs +0 -1564
- package/dist/settings-ZMHe439l.mjs +0 -1526
|
@@ -1,128 +1,115 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import
|
|
3
|
-
import {
|
|
4
|
-
import
|
|
5
|
-
import
|
|
6
|
-
import {
|
|
7
|
-
import
|
|
8
|
-
import {
|
|
9
|
-
import
|
|
10
|
-
import {
|
|
11
|
-
import {
|
|
1
|
+
import { jsxs as r, jsx as e, Fragment as N } from "react/jsx-runtime";
|
|
2
|
+
import u from "react";
|
|
3
|
+
import { observer as _ } from "mobx-react-lite";
|
|
4
|
+
import m from "@mui/material/Stack";
|
|
5
|
+
import { P as Y, Text as d, Icon as R } from "@mxenabled/mxui";
|
|
6
|
+
import { Icon as Z } from "@mxenabled/mx-icons";
|
|
7
|
+
import { f as F } from "../NumberFormatting--XMeeBfr.mjs";
|
|
8
|
+
import { c as oe, f as $, u as E, a as q, x as j, D as re } from "../hooks-97sNJ_lf.mjs";
|
|
9
|
+
import { u as J } from "../useWidgetLoadTimer-B0tB-yzL.mjs";
|
|
10
|
+
import { A as v } from "../Analytics-WeZYytR0.mjs";
|
|
11
|
+
import { L as Q } from "../Loader-CxeBwuPG.mjs";
|
|
12
|
+
import { M as ie } from "../MicroWidgetContainer-B2NnKBgW.mjs";
|
|
13
|
+
import { format as ae, fromUnixTime as se, differenceInMonths as ce } from "date-fns";
|
|
14
|
+
import P from "@mui/material/Box";
|
|
15
|
+
import { C as le } from "../ConnectionsDrawer-CZU9ku-k.mjs";
|
|
16
|
+
import { fromUnixTime as de } from "date-fns/fromUnixTime";
|
|
12
17
|
import { useTheme as H } from "@mui/material/styles";
|
|
13
|
-
import
|
|
14
|
-
import {
|
|
15
|
-
import {
|
|
16
|
-
import
|
|
18
|
+
import { L as me } from "../LineChart-CUfiH86G.mjs";
|
|
19
|
+
import { u as ee } from "../useScreenSize-mWpmnh5w.mjs";
|
|
20
|
+
import { f as he, D as pe } from "../DateFormats-HudZ3Bjs.mjs";
|
|
21
|
+
import ue from "@mui/material/Button";
|
|
17
22
|
import L from "@mui/material/Divider";
|
|
18
|
-
import
|
|
19
|
-
import A from "@mui/material/
|
|
20
|
-
import
|
|
21
|
-
import
|
|
22
|
-
import
|
|
23
|
-
import
|
|
24
|
-
import
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
}), /* @__PURE__ */ e(d, {
|
|
54
|
-
sx: {
|
|
55
|
-
display: "block",
|
|
56
|
-
textAlign: "right"
|
|
57
|
-
},
|
|
58
|
-
variant: "caption",
|
|
59
|
-
children: s.this_month
|
|
60
|
-
})]
|
|
61
|
-
})]
|
|
62
|
-
});
|
|
63
|
-
}, ve = ({ copy: t }) => /* @__PURE__ */ o(h, {
|
|
64
|
-
sx: {
|
|
65
|
-
flexDirection: "row",
|
|
66
|
-
gap: 12
|
|
67
|
-
},
|
|
68
|
-
children: [/* @__PURE__ */ e(ee, {
|
|
69
|
-
name: "elevation",
|
|
70
|
-
size: 32,
|
|
71
|
-
sx: { color: "text.primary" }
|
|
72
|
-
}), /* @__PURE__ */ o(h, { children: [/* @__PURE__ */ e(d, {
|
|
73
|
-
sx: {
|
|
74
|
-
display: "block",
|
|
75
|
-
fontWeight: 600
|
|
76
|
-
},
|
|
77
|
-
variant: "body1",
|
|
78
|
-
children: t.empty_widget_header
|
|
79
|
-
}), /* @__PURE__ */ e(P, {
|
|
80
|
-
sx: { color: "text.secondary" },
|
|
81
|
-
variant: "body2",
|
|
82
|
-
children: t.zero_state_description
|
|
83
|
-
})] })]
|
|
84
|
-
}), it = C(({ onCTAClick: t }) => {
|
|
85
|
-
const { visibleAccounts: s } = he(), { onEvent: i } = B(), { net_worth: n, common: r } = E(), { isInitialized: a } = Z(), { isNetWorthDataLoaded: c, loadNetWorthData: l, netWorthData: g, selectedData: f } = j();
|
|
86
|
-
if (p.useEffect(() => {
|
|
23
|
+
import z from "@mui/material/List";
|
|
24
|
+
import A from "@mui/material/ListSubheader";
|
|
25
|
+
import O from "@mui/material/ListItem";
|
|
26
|
+
import te from "@mui/material/ListItemButton";
|
|
27
|
+
import b from "@mui/material/ListItemText";
|
|
28
|
+
import { l as ne } from "../DateUtil-CzBmbjmA.mjs";
|
|
29
|
+
import { C as x } from "../CurrencyText-CCbE6MmF.mjs";
|
|
30
|
+
import { Stack as fe } from "@mui/material";
|
|
31
|
+
import xe from "@mui/material/Collapse";
|
|
32
|
+
import K from "@mui/material/ListItemIcon";
|
|
33
|
+
import { g as U } from "../NetWorthUtils-Dj7CgAg2.mjs";
|
|
34
|
+
import { D as V } from "../Drawer-DsnW2o0v.mjs";
|
|
35
|
+
import { W as ge } from "../WidgetContainer-DJnp6t6c.mjs";
|
|
36
|
+
import { E as ye } from "../EmptyState-CJUDc3kD.mjs";
|
|
37
|
+
const Ce = ({ amount: t, copy: s, trendValue: i }) => {
|
|
38
|
+
const n = i > 0, o = i === 0 ? "trending_flat" : n ? "trending_up" : "trending_down";
|
|
39
|
+
return /* @__PURE__ */ r(m, { sx: { flexDirection: "row", justifyContent: "space-between" }, children: [
|
|
40
|
+
/* @__PURE__ */ e(Y, { variant: "h1", children: F(t, "0,0") }),
|
|
41
|
+
t !== 0 && /* @__PURE__ */ r(m, { sx: { color: n ? "success.main" : "text.secondary" }, children: [
|
|
42
|
+
/* @__PURE__ */ r(m, { sx: { flexDirection: "row", gap: 8 }, children: [
|
|
43
|
+
/* @__PURE__ */ e(Z, { name: o, size: 20 }),
|
|
44
|
+
/* @__PURE__ */ e(d, { sx: { fontWeight: 600, textAlign: "right" }, variant: "body1", children: F(i, "0,0.00") })
|
|
45
|
+
] }),
|
|
46
|
+
/* @__PURE__ */ e(d, { sx: { display: "block", textAlign: "right" }, variant: "caption", children: s.this_month })
|
|
47
|
+
] })
|
|
48
|
+
] });
|
|
49
|
+
}, be = ({ copy: t }) => /* @__PURE__ */ r(m, { sx: { flexDirection: "row", gap: 12 }, children: [
|
|
50
|
+
/* @__PURE__ */ e(Z, { name: "elevation", size: 32, sx: { color: "text.primary" } }),
|
|
51
|
+
/* @__PURE__ */ r(m, { children: [
|
|
52
|
+
/* @__PURE__ */ e(d, { sx: { display: "block", fontWeight: 600 }, variant: "body1", children: t.empty_widget_header }),
|
|
53
|
+
/* @__PURE__ */ e(Y, { sx: { color: "text.secondary" }, variant: "body2", children: t.zero_state_description })
|
|
54
|
+
] })
|
|
55
|
+
] }), gt = _(({ onCTAClick: t }) => {
|
|
56
|
+
const { visibleAccounts: s } = oe(), { onEvent: i } = $(), { net_worth: n, common: a } = E(), { isInitialized: o } = q(), { isNetWorthDataLoaded: c, loadNetWorthData: l, netWorthData: g, selectedData: f } = j();
|
|
57
|
+
if (u.useEffect(() => {
|
|
87
58
|
c || l().finally();
|
|
88
59
|
}, []), J({
|
|
89
60
|
widgetName: "NetWorthMicroWidget",
|
|
90
61
|
isLoaded: c
|
|
91
|
-
}),
|
|
92
|
-
c && i(
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
62
|
+
}), u.useEffect(() => {
|
|
63
|
+
c && i(v.NET_WORTH_LOAD_WIDGET, {
|
|
64
|
+
state: s?.length ? "default" : "zeroState"
|
|
65
|
+
});
|
|
66
|
+
}, [c]), !o || !c) return /* @__PURE__ */ e(Q, { height: 100 });
|
|
67
|
+
const W = () => {
|
|
68
|
+
i(
|
|
69
|
+
s.length ? v.NET_WORTH_CLICK_VIEW_DETAILS : v.NET_WORTH_CLICK_GET_STARTED
|
|
70
|
+
), t();
|
|
96
71
|
};
|
|
97
|
-
return /* @__PURE__ */ e(
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
72
|
+
return /* @__PURE__ */ e(
|
|
73
|
+
ie,
|
|
74
|
+
{
|
|
75
|
+
className: "mx-networth-microwidget",
|
|
76
|
+
ctaLabel: a.see_details,
|
|
77
|
+
onCTAClick: W,
|
|
78
|
+
title: n.net_worth,
|
|
79
|
+
children: g.accounts.length ? /* @__PURE__ */ e(
|
|
80
|
+
Ce,
|
|
81
|
+
{
|
|
82
|
+
amount: f?.y,
|
|
83
|
+
copy: n,
|
|
84
|
+
trendValue: f?.change
|
|
85
|
+
}
|
|
86
|
+
) : /* @__PURE__ */ e(be, { copy: n })
|
|
87
|
+
}
|
|
88
|
+
);
|
|
89
|
+
}), _e = () => {
|
|
90
|
+
const { isMobile: t } = ee(), { availableWidth: s } = re(), i = H(), {
|
|
91
|
+
hoveredData: n,
|
|
92
|
+
netWorthChartData: a,
|
|
93
|
+
selectedData: o,
|
|
94
|
+
setHoveredIndex: c,
|
|
95
|
+
setSelectedIndex: l
|
|
96
|
+
} = j(), g = s - 320, f = a.map((h) => ({
|
|
97
|
+
x: he(de(h.x), pe.MONTH_SHORT),
|
|
98
|
+
y: h.y
|
|
99
|
+
})), W = o ? { index: a.findIndex((h) => h.x === o.x) } : void 0, S = n ? { index: a.findIndex((h) => h.x === n.x) } : void 0, w = (h) => ({
|
|
100
|
+
fill: h === W?.index ? i.palette.success.main : "",
|
|
101
|
+
filter: h === S?.index ? `drop-shadow(0px 0px 10px ${i.palette.success.main})` : "none",
|
|
115
102
|
stroke: i.palette.success.main
|
|
116
|
-
}), y = (
|
|
103
|
+
}), y = (h, M) => {
|
|
117
104
|
l(M);
|
|
118
|
-
}, k = (
|
|
119
|
-
c(
|
|
105
|
+
}, k = (h) => {
|
|
106
|
+
c(h);
|
|
120
107
|
}, D = () => {
|
|
121
108
|
c(-1);
|
|
122
109
|
};
|
|
123
|
-
return /* @__PURE__ */ e(
|
|
124
|
-
|
|
125
|
-
|
|
110
|
+
return /* @__PURE__ */ e(m, { sx: { width: "100%" }, children: /* @__PURE__ */ e(
|
|
111
|
+
me,
|
|
112
|
+
{
|
|
126
113
|
baseline: "min",
|
|
127
114
|
chartFor: "networthChart",
|
|
128
115
|
chartXaxisSx: { "& .MuiChartsAxis-tickLabel": { transform: "translateX(8px)" } },
|
|
@@ -131,481 +118,448 @@ var _e = ({ amount: t, copy: s, trendValue: i }) => {
|
|
|
131
118
|
datasets: [f],
|
|
132
119
|
height: 350,
|
|
133
120
|
labels: [],
|
|
134
|
-
margin: {
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
},
|
|
138
|
-
markHandlers: {
|
|
139
|
-
onMarkClick: y,
|
|
140
|
-
onMouseEnter: k,
|
|
141
|
-
onMouseLeave: D
|
|
142
|
-
},
|
|
143
|
-
markStyles: b,
|
|
121
|
+
margin: { right: 20, left: 38 },
|
|
122
|
+
markHandlers: { onMarkClick: y, onMouseEnter: k, onMouseLeave: D },
|
|
123
|
+
markStyles: w,
|
|
144
124
|
showArea: !0,
|
|
145
125
|
useCustomMark: !0,
|
|
146
126
|
valueFormatterString: "0.0[0]a",
|
|
147
127
|
width: t ? s - 48 : g
|
|
148
|
-
}
|
|
128
|
+
}
|
|
129
|
+
) });
|
|
130
|
+
}, we = _(_e), ve = ({
|
|
131
|
+
item: t,
|
|
132
|
+
getStyles: s,
|
|
133
|
+
isHovered: i = !1,
|
|
134
|
+
isSelected: n = !1,
|
|
135
|
+
onItemClick: a,
|
|
136
|
+
onMouseEnter: o,
|
|
137
|
+
onMouseLeave: c
|
|
138
|
+
}) => {
|
|
139
|
+
const [l, g] = u.useState({
|
|
140
|
+
color: ""
|
|
149
141
|
});
|
|
150
|
-
|
|
151
|
-
const [l, g] = p.useState({ color: "" });
|
|
152
|
-
return p.useEffect(() => {
|
|
142
|
+
return u.useEffect(() => {
|
|
153
143
|
g(s(t));
|
|
154
|
-
}, [i, n]), /* @__PURE__ */
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
144
|
+
}, [i, n]), /* @__PURE__ */ r(u.Fragment, { children: [
|
|
145
|
+
/* @__PURE__ */ e(
|
|
146
|
+
O,
|
|
147
|
+
{
|
|
148
|
+
sx: {
|
|
149
|
+
...l,
|
|
150
|
+
minHeight: 44,
|
|
151
|
+
"&:hover": { color: n ? "inherit" : l.color }
|
|
152
|
+
},
|
|
153
|
+
children: /* @__PURE__ */ e(
|
|
154
|
+
te,
|
|
155
|
+
{
|
|
156
|
+
onClick: (f) => a?.(f, t.x),
|
|
157
|
+
onMouseEnter: () => o(t.x),
|
|
158
|
+
onMouseLeave: () => c(),
|
|
159
|
+
sx: { minHeight: 20, padding: 12 },
|
|
160
|
+
children: /* @__PURE__ */ e(
|
|
161
|
+
b,
|
|
162
|
+
{
|
|
163
|
+
primary: /* @__PURE__ */ r(m, { direction: "row", justifyContent: "space-between", sx: { fontWeight: 400 }, children: [
|
|
164
|
+
/* @__PURE__ */ e(d, { variant: "body1", children: ne(t.x) }),
|
|
165
|
+
/* @__PURE__ */ e(x, { amount: t.y, sx: { color: "inherit" }, variant: "body1" })
|
|
166
|
+
] })
|
|
167
|
+
}
|
|
168
|
+
)
|
|
169
|
+
}
|
|
170
|
+
)
|
|
171
|
+
}
|
|
172
|
+
),
|
|
173
|
+
/* @__PURE__ */ e(L, {})
|
|
174
|
+
] }, t.x);
|
|
175
|
+
}, We = _(ve), Se = ({
|
|
176
|
+
currencyLabel: t,
|
|
177
|
+
currencyVariant: s = "body2",
|
|
178
|
+
iconSize: i,
|
|
179
|
+
netWorth: n,
|
|
180
|
+
theme: a
|
|
181
|
+
}) => {
|
|
182
|
+
let o = a.palette.secondary.main, c = a.palette.secondary.main, l = "trending_flat";
|
|
183
|
+
return n.change < 0 ? l = "trending_down" : n.change > 0 && (o = a.palette.success.main, c = a.palette.success.main, l = "trending_up"), /* @__PURE__ */ r(fe, { alignItems: "center", direction: "row", spacing: 4, children: [
|
|
184
|
+
/* @__PURE__ */ e(
|
|
185
|
+
R,
|
|
186
|
+
{
|
|
191
187
|
name: l,
|
|
192
188
|
size: i,
|
|
193
|
-
sx: {
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
justifyContent: "space-between",
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
|
|
267
|
-
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
|
|
276
|
-
|
|
277
|
-
|
|
278
|
-
|
|
279
|
-
|
|
280
|
-
|
|
281
|
-
|
|
282
|
-
|
|
283
|
-
|
|
284
|
-
|
|
285
|
-
|
|
286
|
-
|
|
287
|
-
|
|
288
|
-
|
|
289
|
-
|
|
290
|
-
|
|
291
|
-
|
|
292
|
-
|
|
293
|
-
|
|
294
|
-
|
|
295
|
-
}),
|
|
296
|
-
|
|
297
|
-
|
|
298
|
-
|
|
299
|
-
|
|
300
|
-
|
|
301
|
-
|
|
302
|
-
|
|
303
|
-
|
|
189
|
+
sx: {
|
|
190
|
+
color: o
|
|
191
|
+
}
|
|
192
|
+
}
|
|
193
|
+
),
|
|
194
|
+
/* @__PURE__ */ e(x, { amount: n.change, color: c, variant: s }),
|
|
195
|
+
/* @__PURE__ */ e(d, { variant: "body2", children: t })
|
|
196
|
+
] });
|
|
197
|
+
}, B = _(Se), Ie = ({
|
|
198
|
+
netWorth: t,
|
|
199
|
+
gains: s,
|
|
200
|
+
losses: i,
|
|
201
|
+
totalGains: n,
|
|
202
|
+
totalLosses: a
|
|
203
|
+
}) => {
|
|
204
|
+
const { net_worth: o } = E(), c = H();
|
|
205
|
+
return /* @__PURE__ */ r(N, { children: [
|
|
206
|
+
/* @__PURE__ */ r(m, { alignItems: "center", justifyContent: "space-between", mb: 8, pt: 24, children: [
|
|
207
|
+
/* @__PURE__ */ e(d, { variant: "body2", children: ne(t?.x) }),
|
|
208
|
+
/* @__PURE__ */ e(d, { variant: "body1", children: o.total_change }),
|
|
209
|
+
t && /* @__PURE__ */ e(B, { currencyVariant: "h1", iconSize: 32, netWorth: t, theme: c })
|
|
210
|
+
] }),
|
|
211
|
+
/* @__PURE__ */ r(z, { children: [
|
|
212
|
+
/* @__PURE__ */ e(A, { sx: { mb: 8, mt: 12, mx: 8 }, children: /* @__PURE__ */ e(
|
|
213
|
+
b,
|
|
214
|
+
{
|
|
215
|
+
primary: /* @__PURE__ */ r(m, { direction: "row", justifyContent: "space-between", children: [
|
|
216
|
+
/* @__PURE__ */ e(d, { sx: { fontWeight: 700 }, variant: "caption", children: o.gains }),
|
|
217
|
+
/* @__PURE__ */ e(x, { amount: n, sx: { fontWeight: 400 }, variant: "caption" })
|
|
218
|
+
] })
|
|
219
|
+
}
|
|
220
|
+
) }),
|
|
221
|
+
s?.map((l) => /* @__PURE__ */ r(u.Fragment, { children: [
|
|
222
|
+
/* @__PURE__ */ e(O, { sx: { backgroundColor: c.palette.background.paper, py: 14 }, children: /* @__PURE__ */ e(
|
|
223
|
+
b,
|
|
224
|
+
{
|
|
225
|
+
primary: /* @__PURE__ */ r(m, { direction: "row", justifyContent: "space-between", children: [
|
|
226
|
+
/* @__PURE__ */ e(d, { sx: { mr: 10 }, variant: "body1", children: l.accountName }),
|
|
227
|
+
/* @__PURE__ */ e(
|
|
228
|
+
x,
|
|
229
|
+
{
|
|
230
|
+
amount: l.gain,
|
|
231
|
+
sx: { color: c.palette.success.main, flexShrink: 0, fontWeight: 700 },
|
|
232
|
+
variant: "body1"
|
|
233
|
+
}
|
|
234
|
+
)
|
|
235
|
+
] }),
|
|
236
|
+
sx: { px: 16 }
|
|
237
|
+
}
|
|
238
|
+
) }),
|
|
239
|
+
/* @__PURE__ */ e(L, {})
|
|
240
|
+
] }, l.accountName)),
|
|
241
|
+
/* @__PURE__ */ e(A, { sx: { mb: 8, mt: 12, mx: 8 }, children: /* @__PURE__ */ e(
|
|
242
|
+
b,
|
|
243
|
+
{
|
|
244
|
+
primary: /* @__PURE__ */ r(m, { direction: "row", justifyContent: "space-between", children: [
|
|
245
|
+
/* @__PURE__ */ e(d, { sx: { fontWeight: 700 }, variant: "caption", children: o.losses }),
|
|
246
|
+
/* @__PURE__ */ e(x, { amount: a, sx: { fontWeight: 400 }, variant: "caption" })
|
|
247
|
+
] })
|
|
248
|
+
}
|
|
249
|
+
) }),
|
|
250
|
+
i?.map((l) => /* @__PURE__ */ r(N, { children: [
|
|
251
|
+
/* @__PURE__ */ e(
|
|
252
|
+
O,
|
|
253
|
+
{
|
|
254
|
+
sx: { backgroundColor: c.palette.background.paper, py: 14 },
|
|
255
|
+
children: /* @__PURE__ */ e(
|
|
256
|
+
b,
|
|
257
|
+
{
|
|
258
|
+
primary: /* @__PURE__ */ r(m, { direction: "row", justifyContent: "space-between", children: [
|
|
259
|
+
/* @__PURE__ */ e(
|
|
260
|
+
d,
|
|
261
|
+
{
|
|
262
|
+
sx: {
|
|
263
|
+
mr: 10
|
|
264
|
+
},
|
|
265
|
+
variant: "body1",
|
|
266
|
+
children: l.accountName
|
|
267
|
+
}
|
|
268
|
+
),
|
|
269
|
+
/* @__PURE__ */ e(
|
|
270
|
+
x,
|
|
271
|
+
{
|
|
272
|
+
amount: l.loss,
|
|
273
|
+
sx: { flexShrink: 0, fontWeight: 700 },
|
|
274
|
+
variant: "body1"
|
|
275
|
+
}
|
|
276
|
+
)
|
|
277
|
+
] }),
|
|
278
|
+
sx: { px: 16 }
|
|
279
|
+
}
|
|
280
|
+
)
|
|
281
|
+
},
|
|
282
|
+
l.accountName
|
|
283
|
+
),
|
|
284
|
+
/* @__PURE__ */ e(L, {})
|
|
285
|
+
] }))
|
|
286
|
+
] })
|
|
287
|
+
] });
|
|
288
|
+
}, Te = _(Ie), Le = ({ accounts: t, name: s, icon: i }) => {
|
|
289
|
+
const [n, a] = u.useState(!1);
|
|
290
|
+
return /* @__PURE__ */ r(N, { children: [
|
|
291
|
+
/* @__PURE__ */ e(O, { sx: (o) => ({ backgroundColor: o.palette.background.paper }), children: /* @__PURE__ */ r(te, { onClick: () => a(!n), children: [
|
|
292
|
+
i && /* @__PURE__ */ e(K, { children: /* @__PURE__ */ e(R, { name: i, size: 24, sx: { mr: 12 } }) }),
|
|
293
|
+
/* @__PURE__ */ e(
|
|
294
|
+
b,
|
|
295
|
+
{
|
|
296
|
+
primary: /* @__PURE__ */ e(d, { sx: { fontWeight: 700 }, variant: "body1", children: s })
|
|
297
|
+
}
|
|
298
|
+
),
|
|
299
|
+
/* @__PURE__ */ e(K, { children: n ? /* @__PURE__ */ e(R, { name: "expand_less", size: 24 }) : /* @__PURE__ */ e(R, { name: "expand_more", size: 24 }) })
|
|
300
|
+
] }) }),
|
|
301
|
+
/* @__PURE__ */ e(L, {}),
|
|
302
|
+
/* @__PURE__ */ e(xe, { in: n, timeout: "auto", unmountOnExit: !0, children: t.map((o, c) => /* @__PURE__ */ r(z, { children: [
|
|
303
|
+
/* @__PURE__ */ e(O, { sx: () => ({ py: 14 }), children: /* @__PURE__ */ e(
|
|
304
|
+
b,
|
|
305
|
+
{
|
|
306
|
+
primary: /* @__PURE__ */ r(m, { direction: "row", justifyContent: "space-between", sx: { fontWeight: 400 }, children: [
|
|
307
|
+
/* @__PURE__ */ e(
|
|
308
|
+
d,
|
|
309
|
+
{
|
|
310
|
+
sx: {
|
|
311
|
+
marginRight: 10
|
|
312
|
+
},
|
|
313
|
+
variant: "body1",
|
|
314
|
+
children: o.accountName
|
|
315
|
+
}
|
|
316
|
+
),
|
|
317
|
+
/* @__PURE__ */ e(
|
|
318
|
+
x,
|
|
319
|
+
{
|
|
320
|
+
amount: o.balance,
|
|
321
|
+
sx: {
|
|
322
|
+
flexShrink: 0
|
|
323
|
+
},
|
|
324
|
+
variant: "body2"
|
|
325
|
+
}
|
|
326
|
+
)
|
|
327
|
+
] }),
|
|
328
|
+
sx: { pl: 72, pr: 16 }
|
|
329
|
+
}
|
|
330
|
+
) }),
|
|
331
|
+
c < t.length - 1 ? /* @__PURE__ */ e(L, { variant: "inset" }) : /* @__PURE__ */ e(L, {})
|
|
332
|
+
] }, o.accountName)) })
|
|
333
|
+
] });
|
|
334
|
+
}, X = ({ groupedAccounts: t }) => /* @__PURE__ */ e(N, { children: t.map(({ accounts: s, icon: i, name: n }) => /* @__PURE__ */ e(Le, { accounts: s, icon: i, name: n }, n)) }), De = ({
|
|
335
|
+
netWorth: t,
|
|
336
|
+
assets: s,
|
|
337
|
+
liabilities: i,
|
|
338
|
+
totalAssets: n,
|
|
339
|
+
totalLiabilities: a
|
|
340
|
+
}) => {
|
|
341
|
+
const { net_worth: o } = E(), c = H();
|
|
342
|
+
return /* @__PURE__ */ r(N, { children: [
|
|
343
|
+
/* @__PURE__ */ r(
|
|
344
|
+
P,
|
|
345
|
+
{
|
|
346
|
+
sx: {
|
|
347
|
+
alignItems: "center",
|
|
348
|
+
display: "flex",
|
|
349
|
+
flexDirection: "column",
|
|
304
350
|
justifyContent: "space-between",
|
|
305
|
-
|
|
306
|
-
|
|
307
|
-
|
|
308
|
-
children: l.accountName
|
|
309
|
-
}), /* @__PURE__ */ e(x, {
|
|
310
|
-
amount: l.loss,
|
|
311
|
-
sx: {
|
|
312
|
-
flexShrink: 0,
|
|
313
|
-
fontWeight: 700
|
|
314
|
-
},
|
|
315
|
-
variant: "body1"
|
|
316
|
-
})]
|
|
317
|
-
}),
|
|
318
|
-
sx: { px: 16 }
|
|
319
|
-
})
|
|
320
|
-
}, l.accountName), /* @__PURE__ */ e(L, {})] }))
|
|
321
|
-
] })] });
|
|
322
|
-
}, Ie = C(Te), Le = ({ accounts: t, name: s, icon: i }) => {
|
|
323
|
-
const [n, r] = p.useState(!1);
|
|
324
|
-
return /* @__PURE__ */ o(N, { children: [
|
|
325
|
-
/* @__PURE__ */ e(A, {
|
|
326
|
-
sx: (a) => ({ backgroundColor: a.palette.background.paper }),
|
|
327
|
-
children: /* @__PURE__ */ o(ne, {
|
|
328
|
-
onClick: () => r(!n),
|
|
351
|
+
paddingTop: 24,
|
|
352
|
+
marginBottom: 8
|
|
353
|
+
},
|
|
329
354
|
children: [
|
|
330
|
-
|
|
331
|
-
|
|
332
|
-
|
|
333
|
-
|
|
334
|
-
|
|
335
|
-
|
|
336
|
-
|
|
337
|
-
|
|
338
|
-
|
|
339
|
-
|
|
340
|
-
|
|
341
|
-
name: "expand_less",
|
|
342
|
-
size: 24
|
|
343
|
-
}) : /* @__PURE__ */ e(R, {
|
|
344
|
-
name: "expand_more",
|
|
345
|
-
size: 24
|
|
346
|
-
}) })
|
|
355
|
+
/* @__PURE__ */ e(d, { variant: "body1", children: o.current_net_worth }),
|
|
356
|
+
/* @__PURE__ */ e(x, { amount: t?.y ?? 0, variant: "h1" }),
|
|
357
|
+
t && /* @__PURE__ */ e(
|
|
358
|
+
B,
|
|
359
|
+
{
|
|
360
|
+
currencyLabel: o.this_month,
|
|
361
|
+
iconSize: 20,
|
|
362
|
+
netWorth: t,
|
|
363
|
+
theme: c
|
|
364
|
+
}
|
|
365
|
+
)
|
|
347
366
|
]
|
|
348
|
-
}
|
|
349
|
-
|
|
350
|
-
/* @__PURE__ */
|
|
351
|
-
|
|
352
|
-
|
|
353
|
-
|
|
354
|
-
|
|
355
|
-
|
|
356
|
-
|
|
357
|
-
|
|
358
|
-
|
|
359
|
-
|
|
360
|
-
|
|
361
|
-
|
|
362
|
-
|
|
363
|
-
|
|
364
|
-
|
|
365
|
-
|
|
366
|
-
|
|
367
|
-
|
|
368
|
-
|
|
369
|
-
|
|
370
|
-
|
|
371
|
-
|
|
372
|
-
|
|
373
|
-
|
|
374
|
-
|
|
375
|
-
|
|
376
|
-
|
|
377
|
-
|
|
378
|
-
})
|
|
367
|
+
}
|
|
368
|
+
),
|
|
369
|
+
/* @__PURE__ */ r(z, { children: [
|
|
370
|
+
/* @__PURE__ */ e(A, { sx: { mb: 8, mt: 12, mx: 8 }, children: /* @__PURE__ */ e(
|
|
371
|
+
b,
|
|
372
|
+
{
|
|
373
|
+
primary: /* @__PURE__ */ r(m, { direction: "row", justifyContent: "space-between", children: [
|
|
374
|
+
/* @__PURE__ */ e(d, { sx: { fontWeight: 700 }, variant: "caption", children: o.assets }),
|
|
375
|
+
/* @__PURE__ */ e(x, { amount: n, sx: { fontWeight: 400 }, variant: "caption" })
|
|
376
|
+
] })
|
|
377
|
+
}
|
|
378
|
+
) }),
|
|
379
|
+
/* @__PURE__ */ e(X, { groupedAccounts: U(s) }),
|
|
380
|
+
/* @__PURE__ */ e(A, { sx: { mb: 8, mt: 12, mx: 8 }, children: /* @__PURE__ */ e(
|
|
381
|
+
b,
|
|
382
|
+
{
|
|
383
|
+
primary: /* @__PURE__ */ r(m, { direction: "row", justifyContent: "space-between", children: [
|
|
384
|
+
/* @__PURE__ */ e(d, { sx: { fontWeight: 700 }, variant: "caption", children: o.liabilities }),
|
|
385
|
+
/* @__PURE__ */ e(
|
|
386
|
+
x,
|
|
387
|
+
{
|
|
388
|
+
amount: a,
|
|
389
|
+
sx: { fontWeight: 400 },
|
|
390
|
+
variant: "caption"
|
|
391
|
+
}
|
|
392
|
+
)
|
|
393
|
+
] })
|
|
394
|
+
}
|
|
395
|
+
) }),
|
|
396
|
+
/* @__PURE__ */ e(X, { groupedAccounts: U(i) })
|
|
397
|
+
] })
|
|
379
398
|
] });
|
|
380
|
-
},
|
|
381
|
-
|
|
382
|
-
|
|
383
|
-
|
|
384
|
-
|
|
385
|
-
|
|
386
|
-
|
|
387
|
-
|
|
388
|
-
|
|
389
|
-
|
|
390
|
-
|
|
391
|
-
justifyContent: "space-between",
|
|
392
|
-
paddingTop: 24,
|
|
393
|
-
marginBottom: 8
|
|
394
|
-
},
|
|
395
|
-
children: [
|
|
396
|
-
/* @__PURE__ */ e(d, {
|
|
397
|
-
variant: "body1",
|
|
398
|
-
children: a.current_net_worth
|
|
399
|
-
}),
|
|
400
|
-
/* @__PURE__ */ e(x, {
|
|
401
|
-
amount: t?.y ?? 0,
|
|
402
|
-
variant: "h1"
|
|
403
|
-
}),
|
|
404
|
-
t && /* @__PURE__ */ e($, {
|
|
405
|
-
currencyLabel: a.this_month,
|
|
406
|
-
iconSize: 20,
|
|
407
|
-
netWorth: t,
|
|
408
|
-
theme: c
|
|
409
|
-
})
|
|
410
|
-
]
|
|
411
|
-
}), /* @__PURE__ */ o(G, { children: [
|
|
412
|
-
/* @__PURE__ */ e(O, {
|
|
413
|
-
sx: {
|
|
414
|
-
mb: 8,
|
|
415
|
-
mt: 12,
|
|
416
|
-
mx: 8
|
|
417
|
-
},
|
|
418
|
-
children: /* @__PURE__ */ e(v, { primary: /* @__PURE__ */ o(h, {
|
|
419
|
-
direction: "row",
|
|
420
|
-
justifyContent: "space-between",
|
|
421
|
-
children: [/* @__PURE__ */ e(d, {
|
|
422
|
-
sx: { fontWeight: 700 },
|
|
423
|
-
variant: "caption",
|
|
424
|
-
children: a.assets
|
|
425
|
-
}), /* @__PURE__ */ e(x, {
|
|
426
|
-
amount: n,
|
|
427
|
-
sx: { fontWeight: 400 },
|
|
428
|
-
variant: "caption"
|
|
429
|
-
})]
|
|
430
|
-
}) })
|
|
431
|
-
}),
|
|
432
|
-
/* @__PURE__ */ e(X, { groupedAccounts: K(s) }),
|
|
433
|
-
/* @__PURE__ */ e(O, {
|
|
434
|
-
sx: {
|
|
435
|
-
mb: 8,
|
|
436
|
-
mt: 12,
|
|
437
|
-
mx: 8
|
|
438
|
-
},
|
|
439
|
-
children: /* @__PURE__ */ e(v, { primary: /* @__PURE__ */ o(h, {
|
|
440
|
-
direction: "row",
|
|
441
|
-
justifyContent: "space-between",
|
|
442
|
-
children: [/* @__PURE__ */ e(d, {
|
|
443
|
-
sx: { fontWeight: 700 },
|
|
444
|
-
variant: "caption",
|
|
445
|
-
children: a.liabilities
|
|
446
|
-
}), /* @__PURE__ */ e(x, {
|
|
447
|
-
amount: r,
|
|
448
|
-
sx: { fontWeight: 400 },
|
|
449
|
-
variant: "caption"
|
|
450
|
-
})]
|
|
451
|
-
}) })
|
|
452
|
-
}),
|
|
453
|
-
/* @__PURE__ */ e(X, { groupedAccounts: K(i) })
|
|
454
|
-
] })] });
|
|
455
|
-
}, Ne = C(De), Ee = () => {
|
|
456
|
-
const { net_worth: t } = E(), s = H(), { onEvent: i } = B(), { assetsLiabilities: n, gainsLosses: r, hoveredData: a, netWorthChartData: c, selectedData: l, setHoveredIndex: g, setSelectedIndex: f } = j(), [S, W] = p.useState(!1), [b, y] = p.useState(!1), k = (u) => {
|
|
457
|
-
const _ = u.x === a?.x, T = u.x === l?.x, I = {
|
|
399
|
+
}, Ne = _(De), Ee = () => {
|
|
400
|
+
const { net_worth: t } = E(), s = H(), { onEvent: i } = $(), {
|
|
401
|
+
assetsLiabilities: n,
|
|
402
|
+
gainsLosses: a,
|
|
403
|
+
hoveredData: o,
|
|
404
|
+
netWorthChartData: c,
|
|
405
|
+
selectedData: l,
|
|
406
|
+
setHoveredIndex: g,
|
|
407
|
+
setSelectedIndex: f
|
|
408
|
+
} = j(), [W, S] = u.useState(!1), [w, y] = u.useState(!1), k = (p) => {
|
|
409
|
+
const C = p.x === o?.x, I = p.x === l?.x, T = {
|
|
458
410
|
backgroundColor: "inherit",
|
|
459
411
|
borderBottom: "inherit",
|
|
460
412
|
color: "inherit"
|
|
461
413
|
};
|
|
462
|
-
return
|
|
463
|
-
}, D = (
|
|
464
|
-
f(
|
|
465
|
-
},
|
|
466
|
-
y(!0), i(
|
|
467
|
-
}, M = (
|
|
468
|
-
g(
|
|
469
|
-
},
|
|
414
|
+
return C && (T.color = I ? "inherit" : T.color, T.backgroundColor = s.palette.action.hover), I && (T.backgroundColor = s.palette.primary.main, T.borderBottom = s.palette.neutral.light, T.color = s.palette.common.white), T;
|
|
415
|
+
}, D = (p, C) => {
|
|
416
|
+
f(C), p.currentTarget instanceof HTMLDivElement && S(!0);
|
|
417
|
+
}, h = () => {
|
|
418
|
+
y(!0), i(v.NET_WORTH_WIDGET_CLICK_ASSETS_LIABILITIES);
|
|
419
|
+
}, M = (p) => {
|
|
420
|
+
g(p);
|
|
421
|
+
}, G = () => {
|
|
470
422
|
g(-1);
|
|
471
423
|
};
|
|
472
|
-
return /* @__PURE__ */
|
|
473
|
-
|
|
474
|
-
|
|
475
|
-
|
|
476
|
-
/* @__PURE__ */
|
|
477
|
-
|
|
478
|
-
|
|
479
|
-
backgroundColor: "transparent",
|
|
480
|
-
mb: 8,
|
|
481
|
-
mt: 12,
|
|
482
|
-
px: 12
|
|
483
|
-
},
|
|
484
|
-
children: /* @__PURE__ */ e(d, {
|
|
485
|
-
bold: !0,
|
|
486
|
-
component: "h2",
|
|
487
|
-
variant: "body1",
|
|
488
|
-
children: t.monthly_totals
|
|
489
|
-
})
|
|
490
|
-
}),
|
|
491
|
-
/* @__PURE__ */ e(L, {}),
|
|
492
|
-
c.map((u, _) => /* @__PURE__ */ e(Se, {
|
|
424
|
+
return /* @__PURE__ */ r(m, { direction: "column", sx: { width: 320 }, children: [
|
|
425
|
+
/* @__PURE__ */ r(z, { children: [
|
|
426
|
+
/* @__PURE__ */ e(A, { sx: { backgroundColor: "transparent", mb: 8, mt: 12, px: 12 }, children: /* @__PURE__ */ e(d, { bold: !0, component: "h2", variant: "body1", children: t.monthly_totals }) }),
|
|
427
|
+
/* @__PURE__ */ e(L, {}),
|
|
428
|
+
c.map((p, C) => /* @__PURE__ */ e(
|
|
429
|
+
We,
|
|
430
|
+
{
|
|
493
431
|
getStyles: k,
|
|
494
|
-
isHovered:
|
|
495
|
-
isSelected:
|
|
496
|
-
item:
|
|
497
|
-
onItemClick: (
|
|
498
|
-
onMouseEnter: () => M(
|
|
499
|
-
onMouseLeave: () =>
|
|
500
|
-
}, u.x))
|
|
501
|
-
] }),
|
|
502
|
-
/* @__PURE__ */ e(me, {
|
|
503
|
-
onClick: () => m(),
|
|
504
|
-
sx: {
|
|
505
|
-
alignSelf: "center",
|
|
506
|
-
marginTop: 16,
|
|
507
|
-
width: "fit-content"
|
|
432
|
+
isHovered: p.x === o?.x,
|
|
433
|
+
isSelected: p.x === l?.x,
|
|
434
|
+
item: p,
|
|
435
|
+
onItemClick: (I) => D(I, C),
|
|
436
|
+
onMouseEnter: () => M(C),
|
|
437
|
+
onMouseLeave: () => G()
|
|
508
438
|
},
|
|
439
|
+
p.x
|
|
440
|
+
))
|
|
441
|
+
] }),
|
|
442
|
+
/* @__PURE__ */ e(
|
|
443
|
+
ue,
|
|
444
|
+
{
|
|
445
|
+
onClick: () => h(),
|
|
446
|
+
sx: { alignSelf: "center", marginTop: 16, width: "fit-content" },
|
|
509
447
|
variant: "outlined",
|
|
510
448
|
children: t.view_assets_and_liabilities
|
|
511
|
-
}
|
|
512
|
-
|
|
449
|
+
}
|
|
450
|
+
),
|
|
451
|
+
/* @__PURE__ */ e(
|
|
452
|
+
V,
|
|
453
|
+
{
|
|
513
454
|
ariaLabelClose: "Close",
|
|
514
|
-
isOpen:
|
|
515
|
-
onClose: () =>
|
|
455
|
+
isOpen: W,
|
|
456
|
+
onClose: () => S(!1),
|
|
516
457
|
shouldShowHeaderBorders: !1,
|
|
517
458
|
shouldShowHeaderShadow: !0,
|
|
518
459
|
title: t.gains_and_losses,
|
|
519
|
-
children:
|
|
520
|
-
}
|
|
521
|
-
|
|
460
|
+
children: a && /* @__PURE__ */ e(Te, { ...a })
|
|
461
|
+
}
|
|
462
|
+
),
|
|
463
|
+
/* @__PURE__ */ e(
|
|
464
|
+
V,
|
|
465
|
+
{
|
|
522
466
|
ariaLabelClose: "Close",
|
|
523
|
-
isOpen:
|
|
467
|
+
isOpen: w,
|
|
524
468
|
onClose: () => y(!1),
|
|
525
469
|
shouldShowHeaderBorders: !1,
|
|
526
470
|
shouldShowHeaderShadow: !0,
|
|
527
471
|
title: t.assets_and_liabilities,
|
|
528
472
|
children: n && /* @__PURE__ */ e(Ne, { ...n })
|
|
529
|
-
}
|
|
530
|
-
|
|
531
|
-
});
|
|
532
|
-
}, ke =
|
|
533
|
-
const { net_worth: i } = E(), n = H(),
|
|
534
|
-
return /* @__PURE__ */
|
|
535
|
-
|
|
536
|
-
|
|
537
|
-
|
|
538
|
-
|
|
539
|
-
|
|
540
|
-
|
|
541
|
-
|
|
542
|
-
|
|
543
|
-
|
|
544
|
-
|
|
545
|
-
|
|
546
|
-
|
|
547
|
-
|
|
548
|
-
|
|
549
|
-
currencyLabel: i.this_month,
|
|
550
|
-
netWorth: r,
|
|
551
|
-
theme: n
|
|
552
|
-
})
|
|
553
|
-
]
|
|
554
|
-
});
|
|
555
|
-
}, Ae = C(Me), at = C(({ onBackClick: t, onMenuClick: s }) => {
|
|
556
|
-
const { isInitialized: i } = Z(), { accounts: n, net_worth: r } = E(), { hoveredData: a, isNetWorthDataLoaded: c, loadNetWorthData: l, netWorthChartData: g, selectedData: f, setTimeframe: S, timeframe: W } = j(), { isMobile: b } = q(), { onEvent: y } = B(), [k, D] = p.useState(!1);
|
|
473
|
+
}
|
|
474
|
+
)
|
|
475
|
+
] });
|
|
476
|
+
}, ke = _(Ee), Me = ({ hoveredData: t, selectedData: s }) => {
|
|
477
|
+
const { net_worth: i } = E(), n = H(), a = t || s, o = ae(se(a.x), "MMMM");
|
|
478
|
+
return /* @__PURE__ */ r(m, { alignItems: "center", direction: "column", m: 24, children: [
|
|
479
|
+
/* @__PURE__ */ e(d, { color: n.palette.secondary.main, variant: "body2", children: `${o} ${i.net_worth}` }),
|
|
480
|
+
/* @__PURE__ */ e(x, { amount: a.y, variant: "h2" }),
|
|
481
|
+
/* @__PURE__ */ e(B, { currencyLabel: i.this_month, netWorth: a, theme: n })
|
|
482
|
+
] });
|
|
483
|
+
}, Ae = _(Me), yt = _(({ onBackClick: t, onMenuClick: s }) => {
|
|
484
|
+
const { isInitialized: i } = q(), { accounts: n, net_worth: a } = E(), {
|
|
485
|
+
hoveredData: o,
|
|
486
|
+
isNetWorthDataLoaded: c,
|
|
487
|
+
loadNetWorthData: l,
|
|
488
|
+
netWorthChartData: g,
|
|
489
|
+
selectedData: f,
|
|
490
|
+
setTimeframe: W,
|
|
491
|
+
timeframe: S
|
|
492
|
+
} = j(), { isMobile: w } = ee(), { onEvent: y } = $(), [k, D] = u.useState(!1);
|
|
557
493
|
J({
|
|
558
494
|
widgetName: "NetWorthWidget",
|
|
559
495
|
isLoaded: c
|
|
560
|
-
}),
|
|
561
|
-
c || l().finally(), y(
|
|
562
|
-
}, []),
|
|
563
|
-
y(
|
|
564
|
-
}, [
|
|
565
|
-
const
|
|
566
|
-
const
|
|
567
|
-
|
|
496
|
+
}), u.useEffect(() => {
|
|
497
|
+
c || l().finally(), y(v.NET_WORTH_VIEW);
|
|
498
|
+
}, []), u.useEffect(() => {
|
|
499
|
+
y(v.NET_WORTH_WIDGET_CLICK_TIMEFRAME, { time_period: S + "M" });
|
|
500
|
+
}, [S]);
|
|
501
|
+
const h = async (p) => {
|
|
502
|
+
const C = p[0], I = p[1];
|
|
503
|
+
C && I && W(ce(I, C));
|
|
568
504
|
}, M = () => {
|
|
569
|
-
D(!0), y(
|
|
505
|
+
D(!0), y(v.ACCOUNTS_CLICK_CONNECT);
|
|
570
506
|
};
|
|
571
507
|
if (!i || !c) return /* @__PURE__ */ e(Q, {});
|
|
572
|
-
const
|
|
573
|
-
return /* @__PURE__ */
|
|
574
|
-
|
|
575
|
-
|
|
576
|
-
|
|
577
|
-
|
|
578
|
-
|
|
579
|
-
|
|
580
|
-
|
|
581
|
-
|
|
582
|
-
children:
|
|
583
|
-
|
|
584
|
-
|
|
585
|
-
|
|
586
|
-
|
|
587
|
-
|
|
588
|
-
|
|
589
|
-
|
|
590
|
-
|
|
591
|
-
|
|
592
|
-
|
|
593
|
-
|
|
594
|
-
|
|
595
|
-
|
|
596
|
-
|
|
597
|
-
|
|
598
|
-
|
|
599
|
-
|
|
600
|
-
|
|
601
|
-
|
|
602
|
-
|
|
603
|
-
|
|
604
|
-
|
|
605
|
-
|
|
606
|
-
|
|
508
|
+
const G = g.length === 0;
|
|
509
|
+
return /* @__PURE__ */ r(
|
|
510
|
+
ge,
|
|
511
|
+
{
|
|
512
|
+
calendarActions: { onRangeChanged: h },
|
|
513
|
+
dateRangeVariant: w ? "timeframetabs" : "timeframebuttons",
|
|
514
|
+
onAccountsFilterClick: () => y(v.NET_WORTH_WIDGET_CLICK_FILTER),
|
|
515
|
+
onBackClick: t,
|
|
516
|
+
onMenuClick: s,
|
|
517
|
+
title: a.net_worth,
|
|
518
|
+
children: [
|
|
519
|
+
G ? /* @__PURE__ */ e(P, { sx: { justifyItems: "center" }, children: /* @__PURE__ */ e(
|
|
520
|
+
ye,
|
|
521
|
+
{
|
|
522
|
+
header: a.empty_widget_header,
|
|
523
|
+
icon: "elevation",
|
|
524
|
+
onClick: M,
|
|
525
|
+
primaryButton: a.empty_widget_button,
|
|
526
|
+
subText: a.empty_widget_description,
|
|
527
|
+
sx: {
|
|
528
|
+
width: { sm: 432 },
|
|
529
|
+
".buttons-footer": {
|
|
530
|
+
width: 167
|
|
531
|
+
}
|
|
532
|
+
}
|
|
533
|
+
}
|
|
534
|
+
) }) : /* @__PURE__ */ r(N, { children: [
|
|
535
|
+
f && /* @__PURE__ */ e(Ae, { hoveredData: o, selectedData: f }),
|
|
536
|
+
/* @__PURE__ */ r(
|
|
537
|
+
m,
|
|
538
|
+
{
|
|
539
|
+
alignItems: w ? "center" : "flex-start",
|
|
540
|
+
direction: w ? "column" : "row",
|
|
541
|
+
spacing: w ? 0 : 48,
|
|
542
|
+
children: [
|
|
543
|
+
/* @__PURE__ */ e(we, {}),
|
|
544
|
+
/* @__PURE__ */ e(ke, {})
|
|
545
|
+
]
|
|
546
|
+
}
|
|
547
|
+
)
|
|
548
|
+
] }),
|
|
549
|
+
/* @__PURE__ */ e(
|
|
550
|
+
le,
|
|
551
|
+
{
|
|
552
|
+
onClose: () => D(!1),
|
|
553
|
+
showConnectionsWidget: k,
|
|
554
|
+
title: n.manage_connections
|
|
555
|
+
}
|
|
556
|
+
)
|
|
557
|
+
]
|
|
558
|
+
}
|
|
559
|
+
);
|
|
607
560
|
});
|
|
608
561
|
export {
|
|
609
|
-
|
|
610
|
-
|
|
562
|
+
gt as NetWorthMicroWidget,
|
|
563
|
+
yt as NetWorthWidget
|
|
611
564
|
};
|
|
565
|
+
//# sourceMappingURL=index.es.js.map
|