@mx-cartographer/experiences 7.2.9-alpha.san3 → 7.2.9-alpha.san4
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-C74yHCOj.mjs → FinstrongStore-rVhw737g.mjs} +19 -19
- package/dist/common/index.es.js +1 -1
- package/dist/common/types/Widgets.d.ts +0 -2
- package/dist/finstrong/FinstrongWidget.d.ts +1 -1
- package/dist/finstrong/components/KeyIndicatorsSpendTab.d.ts +1 -4
- package/dist/finstrong/components/KeyIndicatorsTabItem.d.ts +0 -2
- package/dist/finstrong/components/KeyIndicatorsTabItemDrawer.d.ts +1 -3
- package/dist/finstrong/components/KeyIndicatorsTabsWidget.d.ts +1 -4
- package/dist/finstrong/components/SpendLessThanYouMake/SpendLessThanYouMakeComponent.d.ts +1 -4
- package/dist/finstrong/index.es.js +1419 -1293
- package/dist/finstrong/util/finstrongUtils.d.ts +1 -3
- package/package.json +1 -1
|
@@ -22,8 +22,8 @@ import X from "@mui/material/ListItem";
|
|
|
22
22
|
import V from "@mui/material/ListItemAvatar";
|
|
23
23
|
import j from "@mui/material/ListItemButton";
|
|
24
24
|
import z from "@mui/material/ListItemText";
|
|
25
|
-
import { Text as
|
|
26
|
-
import { f as
|
|
25
|
+
import { Text as F } from "@mxenabled/mxui";
|
|
26
|
+
import { f as _, a as C } from "./Dialog-BPTr3qHE.mjs";
|
|
27
27
|
import { b as W } from "./Localization-2MODESHW.mjs";
|
|
28
28
|
const m = {
|
|
29
29
|
creditScore: {
|
|
@@ -52,7 +52,7 @@ const m = {
|
|
|
52
52
|
OFF_TRACK: "Off Track",
|
|
53
53
|
MISSING: "Missing"
|
|
54
54
|
};
|
|
55
|
-
var
|
|
55
|
+
var O = /* @__PURE__ */ ((e) => (e.Connections = "connections", e.CreditScore = "credit_score", e.DateOfBirth = "date_of_birth", e.MonthlyIncome = "monthly_income", e))(O || {});
|
|
56
56
|
const q = ({ list: e, onClickItem: t }) => /* @__PURE__ */ i(K, { sx: { bgcolor: "background.paper" }, children: /* @__PURE__ */ i(
|
|
57
57
|
U,
|
|
58
58
|
{
|
|
@@ -83,8 +83,8 @@ const q = ({ list: e, onClickItem: t }) => /* @__PURE__ */ i(K, { sx: { bgcolor:
|
|
|
83
83
|
/* @__PURE__ */ i(
|
|
84
84
|
z,
|
|
85
85
|
{
|
|
86
|
-
primary: /* @__PURE__ */ i(
|
|
87
|
-
secondary: /* @__PURE__ */ i(
|
|
86
|
+
primary: /* @__PURE__ */ i(F, { sx: { color: "text.secondary" }, variant: "caption", children: r.primaryText }),
|
|
87
|
+
secondary: /* @__PURE__ */ i(F, { sx: { color: "text.primary", fontWeight: 600 }, variant: "body1", children: r.secondaryText })
|
|
88
88
|
}
|
|
89
89
|
)
|
|
90
90
|
] }) }),
|
|
@@ -179,11 +179,11 @@ const q = ({ list: e, onClickItem: t }) => /* @__PURE__ */ i(K, { sx: { bgcolor:
|
|
|
179
179
|
secondaryText: c
|
|
180
180
|
};
|
|
181
181
|
}, J = (e, t) => ({
|
|
182
|
-
[
|
|
183
|
-
[
|
|
182
|
+
[O.DateOfBirth]: (n) => R(new Date(Number(n) * 1e3), "MMM d, yyyy"),
|
|
183
|
+
[O.MonthlyIncome]: (n) => `$${n}`
|
|
184
184
|
})[e]?.(t) ?? String(t), $t = (e) => e !== null ? Math.round(e * 100) : null, Bt = (e) => {
|
|
185
185
|
const t = new Date((/* @__PURE__ */ new Date()).getFullYear(), e - 1, 1);
|
|
186
|
-
return
|
|
186
|
+
return _(t, C.MONTH_SHORT);
|
|
187
187
|
}, Kt = (e) => {
|
|
188
188
|
const { good: t, poor: r } = m.daysOfCashOnHand;
|
|
189
189
|
return e === null ? "MISSING" : e >= t ? "GOOD" : e >= r ? "FAIR" : "OFF_TRACK";
|
|
@@ -243,9 +243,9 @@ const q = ({ list: e, onClickItem: t }) => /* @__PURE__ */ i(K, { sx: { bgcolor:
|
|
|
243
243
|
return Math.max(a / (f || 1), 1);
|
|
244
244
|
}, qt = (e) => !e || e <= 0 ? "0%" : e >= 1e3 ? "100%" : `${Math.round(e / 10)}%`, Jt = (e) => E.find((r) => e < r.upperLimit)?.targetAmount ?? tt, Qt = (e) => E.find((n) => e < n.upperLimit)?.contributionPeriodIndex ?? Z, Zt = (e, t) => e.map((n) => {
|
|
245
245
|
const o = new Date(0, n.month - 1, 1);
|
|
246
|
-
return { x:
|
|
247
|
-
}).reverse(), nt = (e) => e
|
|
248
|
-
x:
|
|
246
|
+
return { x: _(o, C.MONTH_SHORT), y: n[t] };
|
|
247
|
+
}).reverse(), nt = (e) => e.sort((t, r) => t.monthly_health_score_average.month - r.monthly_health_score_average.month).map((t) => ({
|
|
248
|
+
x: _(
|
|
249
249
|
new Date(0, t.monthly_health_score_average.month - 1, 1),
|
|
250
250
|
C.MONTH_SHORT
|
|
251
251
|
),
|
|
@@ -253,23 +253,23 @@ const q = ({ list: e, onClickItem: t }) => /* @__PURE__ */ i(K, { sx: { bgcolor:
|
|
|
253
253
|
})), ot = (e) => e.sort((r, n) => n.transaction.date - r.transaction.date).map(({ transaction: r }) => ({
|
|
254
254
|
...r
|
|
255
255
|
}));
|
|
256
|
-
class
|
|
256
|
+
class y {
|
|
257
257
|
fetchInstance;
|
|
258
258
|
constructor(t, r, n) {
|
|
259
259
|
this.fetchInstance = new x(t, r, void 0, n);
|
|
260
260
|
}
|
|
261
261
|
calculateHealthScore = async () => this.fetchInstance.post(`${h.HEALTH_SCORES}/calculate`).then((t) => t.health_score);
|
|
262
262
|
getAverageHealthScores = async () => this.fetchInstance.get(`${h.HEALTH_SCORES}/monthly_averages`).then((t) => t);
|
|
263
|
-
getDebtSpend = async () => this.fetchInstance.get(`${h.HEALTH_SCORES}/transactions/debt_spend`).then((t) => t
|
|
264
|
-
getIncome = async () => this.fetchInstance.get(`${h.HEALTH_SCORES}/transactions/income`).then((t) => t
|
|
265
|
-
getMonthlySummaries = async () => this.fetchInstance.get(`${h.HEALTH_SCORES}/monthly_summaries`).then((t) => t
|
|
263
|
+
getDebtSpend = async () => this.fetchInstance.get(`${h.HEALTH_SCORES}/transactions/debt_spend`).then((t) => t);
|
|
264
|
+
getIncome = async () => this.fetchInstance.get(`${h.HEALTH_SCORES}/transactions/income`).then((t) => t);
|
|
265
|
+
getMonthlySummaries = async () => this.fetchInstance.get(`${h.HEALTH_SCORES}/monthly_summaries`).then((t) => t);
|
|
266
266
|
getHealthScoreChangeReports = async (t, r) => this.fetchInstance.get(`${h.HEALTH_SCORES}/change_report/from/${t}/to/${r}`).then((n) => n);
|
|
267
267
|
getPeerScore = async (t) => this.fetchInstance.get(`${h.HEALTH_SCORES}/average/${t}`).then((r) => r.average_health_score);
|
|
268
268
|
getSpendingFeeTransactions = async () => this.fetchInstance.get(`${h.HEALTH_SCORES}/transactions/spending_fee`).then((t) => t);
|
|
269
269
|
getStandardSpend = async () => this.fetchInstance.get(`${h.HEALTH_SCORES}/transactions/standard_spend`).then((t) => t);
|
|
270
270
|
}
|
|
271
271
|
class te {
|
|
272
|
-
api = new
|
|
272
|
+
api = new y("/", "");
|
|
273
273
|
augmentedChartData = [];
|
|
274
274
|
averageHealthScores = [];
|
|
275
275
|
monthlySummaries = [];
|
|
@@ -285,7 +285,7 @@ class te {
|
|
|
285
285
|
healthScoreChangeReports = [];
|
|
286
286
|
peerScore = null;
|
|
287
287
|
constructor(t) {
|
|
288
|
-
this.globalStore = t, this.api = new
|
|
288
|
+
this.globalStore = t, this.api = new y(t.endpoint, t.sessionToken, t.onError), b(this);
|
|
289
289
|
}
|
|
290
290
|
calculateHealthScore = async () => {
|
|
291
291
|
try {
|
|
@@ -400,7 +400,7 @@ class te {
|
|
|
400
400
|
}
|
|
401
401
|
}
|
|
402
402
|
export {
|
|
403
|
-
|
|
403
|
+
O as A,
|
|
404
404
|
u as C,
|
|
405
405
|
te as F,
|
|
406
406
|
vt as P,
|
|
@@ -428,5 +428,5 @@ export {
|
|
|
428
428
|
Ut as v,
|
|
429
429
|
Xt as w,
|
|
430
430
|
kt as x,
|
|
431
|
-
|
|
431
|
+
y
|
|
432
432
|
};
|
package/dist/common/index.es.js
CHANGED
|
@@ -64,7 +64,7 @@ import { startOfToday as U } from "date-fns/startOfToday";
|
|
|
64
64
|
import { f as bt, a as wt, b as L } from "../BudgetUtil-wjoNuj7B.mjs";
|
|
65
65
|
import { g as ta, e as ea, c as sa, d as ra, i as oa } from "../BudgetUtil-wjoNuj7B.mjs";
|
|
66
66
|
import { a as xt } from "../DebtsStore-DB5U2WMC.mjs";
|
|
67
|
-
import { F as Ct } from "../FinstrongStore-
|
|
67
|
+
import { F as Ct } from "../FinstrongStore-rVhw737g.mjs";
|
|
68
68
|
import { A as vt, m as Dt, a as At, b as Et } from "../InvestmentUtil-jOyOgzIB.mjs";
|
|
69
69
|
import { M as Tt } from "../MerchantStore-DrFvsUyy.mjs";
|
|
70
70
|
import { N as Bt } from "../NetWorthStore-CUz0bwVm.mjs";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { WidgetProps } from '../common';
|
|
2
|
-
declare const _default: (({ onBackClick, sx
|
|
2
|
+
declare const _default: (({ onBackClick, sx }: WidgetProps) => import("react/jsx-runtime").JSX.Element) & {
|
|
3
3
|
displayName: string;
|
|
4
4
|
};
|
|
5
5
|
export default _default;
|
|
@@ -6,8 +6,6 @@ interface KeyIndicatorsTabsItemProps {
|
|
|
6
6
|
title: string;
|
|
7
7
|
description: string;
|
|
8
8
|
cardState: keyof typeof CardStatus;
|
|
9
|
-
onTrendClick?: () => void;
|
|
10
|
-
onSpendingClick?: () => void;
|
|
11
9
|
}
|
|
12
10
|
declare const KeyIndicatorsTabsItem: React.FC<KeyIndicatorsTabsItemProps>;
|
|
13
11
|
export default KeyIndicatorsTabsItem;
|
|
@@ -3,10 +3,8 @@ interface KeyIndicatorsTabItemDrawerProps {
|
|
|
3
3
|
drawerFor: KeyIndicatorsTabItemType;
|
|
4
4
|
isOpen: boolean;
|
|
5
5
|
onClose: () => void;
|
|
6
|
-
onTrendClick?: () => void;
|
|
7
|
-
onSpendingClick?: () => void;
|
|
8
6
|
}
|
|
9
|
-
declare const _default: (({ drawerFor, isOpen, onClose,
|
|
7
|
+
declare const _default: (({ drawerFor, isOpen, onClose, }: KeyIndicatorsTabItemDrawerProps) => import("react/jsx-runtime").JSX.Element) & {
|
|
10
8
|
displayName: string;
|
|
11
9
|
};
|
|
12
10
|
export default _default;
|