@mx-cartographer/experiences 7.11.8 → 7.11.9
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 +5 -1
- package/dist/debts/index.es.js +20 -19
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
package/dist/debts/index.es.js
CHANGED
|
@@ -2,7 +2,7 @@ import { jsx as e, jsxs as s, Fragment as $ } from "react/jsx-runtime";
|
|
|
2
2
|
import g from "react";
|
|
3
3
|
import { observer as v } from "mobx-react-lite";
|
|
4
4
|
import x from "@mui/material/Stack";
|
|
5
|
-
import { useTheme as
|
|
5
|
+
import { useTheme as Y, Card as we, Stack as _, Box as W } from "@mui/material";
|
|
6
6
|
import { Text as l, P as Ce, H3 as Fe, InstitutionLogo as Le, Icon as ne } from "@mxenabled/mxui";
|
|
7
7
|
import { intervalToDuration as $e, formatDuration as He } from "date-fns";
|
|
8
8
|
import { addMonths as he } from "date-fns/addMonths";
|
|
@@ -12,11 +12,11 @@ import { a as P, M as Oe, I as We } from "../DebtsStore-BZqNLaqd.mjs";
|
|
|
12
12
|
import { D as ra } from "../DebtsStore-BZqNLaqd.mjs";
|
|
13
13
|
import { f as N, a as Ge } from "../NumberFormatting-DjTD0t3W.mjs";
|
|
14
14
|
import { f as Q, D as ee } from "../DateFormats-Cs-NbEZ7.mjs";
|
|
15
|
-
import { G as je, v as te, u as C, l as
|
|
15
|
+
import { G as je, v as te, u as C, l as V, g as R, d as re, a as ze, b as Xe } from "../hooks-zu7yblbi.mjs";
|
|
16
16
|
import { u as K } from "../useScreenSize-B6JyS_Lj.mjs";
|
|
17
17
|
import { D as ie } from "../Drawer-DV4NTsFg.mjs";
|
|
18
18
|
import { b as E } from "../Localization-2MODESHW.mjs";
|
|
19
|
-
import { A as
|
|
19
|
+
import { A as Ye, u as Ve } from "../AccountDetailsHeader-BCi1WwkM.mjs";
|
|
20
20
|
import Ke from "@mui/material/Card";
|
|
21
21
|
import Ue from "@mui/material/CardContent";
|
|
22
22
|
import qe from "@mui/material/CardHeader";
|
|
@@ -160,7 +160,7 @@ const F = () => {
|
|
|
160
160
|
throw new Error("useCateUiStore() must be used within the GlobalDataContext");
|
|
161
161
|
return te().uiStore;
|
|
162
162
|
}, xt = ({ debts: a, onClickCta: o, sx: r }) => {
|
|
163
|
-
const t =
|
|
163
|
+
const t = Y(), { isMobile: n } = K(), { debts: i } = C(), { selectedDebtPriority: c } = F(), { monthlyCashFlowProfile: d } = V(), { payoffDate: p, payoffSavings: h, payoffDuration: m } = g.useMemo(() => {
|
|
164
164
|
const w = d?.extra_payment ?? 0;
|
|
165
165
|
return gt(a, c, w);
|
|
166
166
|
}, [a, c, d]);
|
|
@@ -212,7 +212,7 @@ const F = () => {
|
|
|
212
212
|
}
|
|
213
213
|
);
|
|
214
214
|
}, wt = v(xt), Ct = ({ isOpen: a, onClose: o }) => {
|
|
215
|
-
const r =
|
|
215
|
+
const r = Y(), { debts: t } = C(), [n, i] = g.useState(!1);
|
|
216
216
|
return /* @__PURE__ */ e(
|
|
217
217
|
ie,
|
|
218
218
|
{
|
|
@@ -722,7 +722,7 @@ const Ae = ({
|
|
|
722
722
|
}
|
|
723
723
|
);
|
|
724
724
|
}, Tt = () => {
|
|
725
|
-
const a =
|
|
725
|
+
const a = Y(), { debts: o } = C(), { selectedDebtChartData: r } = F();
|
|
726
726
|
return /* @__PURE__ */ s($, { children: [
|
|
727
727
|
/* @__PURE__ */ s(
|
|
728
728
|
Ke,
|
|
@@ -749,7 +749,7 @@ const Ae = ({
|
|
|
749
749
|
)
|
|
750
750
|
] });
|
|
751
751
|
}, At = v(Tt), Et = () => {
|
|
752
|
-
const a =
|
|
752
|
+
const a = Y(), { onEvent: o } = R(), { debts: r } = C(), { selectedDebtChartData: t, showCompleted: n, showError: i } = F();
|
|
753
753
|
return g.useEffect(() => o(D.DEBT_SCHEDULE_VIEW), []), /* @__PURE__ */ e(Se, { children: i || n ? /* @__PURE__ */ e(
|
|
754
754
|
l,
|
|
755
755
|
{
|
|
@@ -1017,13 +1017,13 @@ const Ae = ({
|
|
|
1017
1017
|
onClose: o,
|
|
1018
1018
|
title: r.details_title,
|
|
1019
1019
|
children: /* @__PURE__ */ s(x, { bgcolor: "background.default", children: [
|
|
1020
|
-
/* @__PURE__ */ e(
|
|
1020
|
+
/* @__PURE__ */ e(Ye, { customDetailsChart: i }),
|
|
1021
1021
|
/* @__PURE__ */ e($t, {})
|
|
1022
1022
|
] })
|
|
1023
1023
|
}
|
|
1024
1024
|
);
|
|
1025
1025
|
}, Ot = v(() => {
|
|
1026
|
-
const { debts: a } = C(), { monthlyCashFlowProfile: o, updateMonthlyCashFlowProfile: r } =
|
|
1026
|
+
const { debts: a } = C(), { monthlyCashFlowProfile: o, updateMonthlyCashFlowProfile: r } = V(), { onEvent: t } = R(), [n, i] = g.useState(o?.extra_payment ?? 0), c = n < 0 || n > 9999999999e-2, d = async () => {
|
|
1027
1027
|
o && (await r({ ...o, extra_payment: n }), o.extra_payment = n, t(D.DEBTS_SAVE_PAYDOWN_ACTION, {
|
|
1028
1028
|
user_guid: o?.user_guid
|
|
1029
1029
|
}));
|
|
@@ -1057,7 +1057,7 @@ const Ae = ({
|
|
|
1057
1057
|
}
|
|
1058
1058
|
);
|
|
1059
1059
|
}), Wt = () => {
|
|
1060
|
-
const { debts: a } = C(), { totalMonthlyPayments: o } = te(), { monthlyCashFlowProfile: r } =
|
|
1060
|
+
const { debts: a } = C(), { totalMonthlyPayments: o } = te(), { monthlyCashFlowProfile: r } = V(), t = o + Number(r?.extra_payment);
|
|
1061
1061
|
return /* @__PURE__ */ s(x, { sx: { backgroundColor: "background.default", height: "100%" }, children: [
|
|
1062
1062
|
/* @__PURE__ */ s(x, { p: 24, children: [
|
|
1063
1063
|
/* @__PURE__ */ s(x, { alignItems: "center", gap: 4, mb: 24, children: [
|
|
@@ -1100,14 +1100,14 @@ function zt(a, o) {
|
|
|
1100
1100
|
function Xt(a) {
|
|
1101
1101
|
return a.is_paid_off ? "✓" : a.priority === void 0 || a.is_impossible ? "!" : a.priority;
|
|
1102
1102
|
}
|
|
1103
|
-
const
|
|
1103
|
+
const Yt = (a) => {
|
|
1104
1104
|
const o = {
|
|
1105
1105
|
text: "#121417",
|
|
1106
1106
|
background: "#FFB252"
|
|
1107
1107
|
};
|
|
1108
1108
|
return a === "!" && (o.text = "#FFFFFF", o.background = "#DF320C"), a === "✓" && (o.text = "#FFFFFF", o.background = "#09A57F"), o;
|
|
1109
|
-
},
|
|
1110
|
-
const o = String(a.formattedValue), r =
|
|
1109
|
+
}, Vt = (a) => {
|
|
1110
|
+
const o = String(a.formattedValue), r = Yt(o);
|
|
1111
1111
|
return /* @__PURE__ */ e(
|
|
1112
1112
|
le,
|
|
1113
1113
|
{
|
|
@@ -1147,14 +1147,14 @@ const Vt = (a) => {
|
|
|
1147
1147
|
onHoverRow: t,
|
|
1148
1148
|
onClickRow: n
|
|
1149
1149
|
}) => {
|
|
1150
|
-
const i =
|
|
1150
|
+
const i = Y(), { onEvent: c } = R(), { isMobile: d } = K(), { debts: p, common: h } = C(), [m, w] = g.useState([
|
|
1151
1151
|
{ field: "priority", sort: "asc" }
|
|
1152
1152
|
]), b = [
|
|
1153
1153
|
{
|
|
1154
1154
|
field: "priority",
|
|
1155
1155
|
headerName: p.table_column_priority,
|
|
1156
1156
|
renderHeader: j,
|
|
1157
|
-
renderCell:
|
|
1157
|
+
renderCell: Vt,
|
|
1158
1158
|
sortComparator: zt,
|
|
1159
1159
|
sortable: !0,
|
|
1160
1160
|
hideSortIcons: !0,
|
|
@@ -1258,10 +1258,11 @@ const Vt = (a) => {
|
|
|
1258
1258
|
le,
|
|
1259
1259
|
{
|
|
1260
1260
|
sx: {
|
|
1261
|
-
height: "
|
|
1261
|
+
height: "auto",
|
|
1262
1262
|
width: "100%",
|
|
1263
1263
|
mt: "15px",
|
|
1264
1264
|
overflowX: "auto",
|
|
1265
|
+
overflowY: "visible",
|
|
1265
1266
|
boxShadow: "none",
|
|
1266
1267
|
...a
|
|
1267
1268
|
},
|
|
@@ -1463,7 +1464,7 @@ const Vt = (a) => {
|
|
|
1463
1464
|
onClickHandler: o ? r : void 0,
|
|
1464
1465
|
primaryButton: o ? a.connect_accounts : void 0
|
|
1465
1466
|
}), tr = v(({ disabled: a, onClick: o }) => {
|
|
1466
|
-
const { debts: r } = C(), { isDesktop: t } = K(), { totalMonthlyPayments: n } = te(), { monthlyCashFlowProfile: i } =
|
|
1467
|
+
const { debts: r } = C(), { isDesktop: t } = K(), { totalMonthlyPayments: n } = te(), { monthlyCashFlowProfile: i } = V(), c = n + Number(i?.extra_payment), d = t ? r.paydown_button_long : r.paydown_button_short;
|
|
1467
1468
|
return /* @__PURE__ */ e(
|
|
1468
1469
|
De,
|
|
1469
1470
|
{
|
|
@@ -1480,12 +1481,12 @@ const Vt = (a) => {
|
|
|
1480
1481
|
}), rr = ({ onBackClick: a, sx: o }) => {
|
|
1481
1482
|
const { isDesktop: r, isMobile: t } = K(), { connect: n, debts: i } = C(), { onEvent: c } = R(), {
|
|
1482
1483
|
config: { show_connections_widget_in_master: d }
|
|
1483
|
-
} = ze(), { isInitialized: p } = Xe(), { setSelectedAccount: h } =
|
|
1484
|
+
} = ze(), { isInitialized: p } = Xe(), { setSelectedAccount: h } = Ve(), { selectedDebtPriority: m, setSelectedDebtChartData: w } = F(), {
|
|
1484
1485
|
isAccountDataLoaded: b,
|
|
1485
1486
|
loadAccountData: B,
|
|
1486
1487
|
detailedAccounts: M,
|
|
1487
1488
|
visibleDebtAccounts: I
|
|
1488
|
-
} = re(), { isAllGoalDataLoaded: S, loadGoalData: T, monthlyCashFlowProfile: H } =
|
|
1489
|
+
} = re(), { isAllGoalDataLoaded: S, loadGoalData: T, monthlyCashFlowProfile: H } = V(), { debts: y } = te(), [u, f] = g.useState(!1), [A, k] = g.useState(!1), [L, z] = g.useState(!1), [U, Ee] = g.useState(""), [Ie, ce] = g.useState(!1);
|
|
1489
1490
|
pt({
|
|
1490
1491
|
widgetName: "DebtsWidget",
|
|
1491
1492
|
isLoaded: S
|