@mx-cartographer/experiences 7.11.19 → 7.11.20
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
CHANGED
|
@@ -2,15 +2,15 @@ import { makeAutoObservable as E, runInAction as d } from "mobx";
|
|
|
2
2
|
import { format as R } from "date-fns/format";
|
|
3
3
|
import { fromUnixTime as b } from "date-fns/fromUnixTime";
|
|
4
4
|
import { getUnixTime as T } from "date-fns/getUnixTime";
|
|
5
|
-
import { subMonths as
|
|
6
|
-
import { F as
|
|
5
|
+
import { subMonths as v } from "date-fns/subMonths";
|
|
6
|
+
import { F as H, A as h } from "./Fetch-B6tMJC1r.mjs";
|
|
7
7
|
import { jsx as c, jsxs as C } from "react/jsx-runtime";
|
|
8
|
-
import { addDays as
|
|
8
|
+
import { addDays as x } from "date-fns/addDays";
|
|
9
9
|
import { addMonths as M } from "date-fns/addMonths";
|
|
10
10
|
import { addYears as G } from "date-fns/addYears";
|
|
11
11
|
import { differenceInDays as L } from "date-fns/differenceInDays";
|
|
12
12
|
import { differenceInMonths as w } from "date-fns/differenceInMonths";
|
|
13
|
-
import { differenceInWeeks as
|
|
13
|
+
import { differenceInWeeks as y } from "date-fns/differenceInWeeks";
|
|
14
14
|
import { startOfToday as N } from "date-fns/startOfToday";
|
|
15
15
|
import { ChevronRight as P, Check as k } from "@mxenabled/mx-icons";
|
|
16
16
|
import $ from "react";
|
|
@@ -22,8 +22,8 @@ import U from "@mui/material/ListItem";
|
|
|
22
22
|
import X from "@mui/material/ListItemAvatar";
|
|
23
23
|
import V from "@mui/material/ListItemButton";
|
|
24
24
|
import W from "@mui/material/ListItemText";
|
|
25
|
-
import { Text as
|
|
26
|
-
import { f as
|
|
25
|
+
import { Text as A } from "@mxenabled/mxui";
|
|
26
|
+
import { f as I, D as O } from "./DateFormats-BMpMrZpW.mjs";
|
|
27
27
|
import { b as j } from "./Localization-CPkpIwIx.mjs";
|
|
28
28
|
import { f as q } from "./NumberFormatting-QCaNwbjv.mjs";
|
|
29
29
|
const m = {
|
|
@@ -53,7 +53,7 @@ const m = {
|
|
|
53
53
|
OFF_TRACK: "OFF TRACK",
|
|
54
54
|
MISSING: "MISSING DATA"
|
|
55
55
|
};
|
|
56
|
-
var
|
|
56
|
+
var _ = /* @__PURE__ */ ((e) => (e.Connections = "connections", e.CreditScore = "credit_score", e.DateOfBirth = "date_of_birth", e.MonthlyIncome = "monthly_income", e))(_ || {});
|
|
57
57
|
const J = ({ list: e, onClickItem: t }) => /* @__PURE__ */ c(K, { sx: { bgcolor: "background.paper" }, children: /* @__PURE__ */ c(
|
|
58
58
|
Y,
|
|
59
59
|
{
|
|
@@ -63,14 +63,14 @@ const J = ({ list: e, onClickItem: t }) => /* @__PURE__ */ c(K, { sx: { bgcolor:
|
|
|
63
63
|
pr: 24
|
|
64
64
|
}
|
|
65
65
|
},
|
|
66
|
-
children: e.map((
|
|
67
|
-
/* @__PURE__ */ c(U, { secondaryAction: /* @__PURE__ */ c(P, {}), children: /* @__PURE__ */ C(V, { onClick: () => t(
|
|
66
|
+
children: e.map((r, n) => /* @__PURE__ */ C($.Fragment, { children: [
|
|
67
|
+
/* @__PURE__ */ c(U, { secondaryAction: /* @__PURE__ */ c(P, {}), children: /* @__PURE__ */ C(V, { onClick: () => t(r.key), children: [
|
|
68
68
|
/* @__PURE__ */ c(X, { children: /* @__PURE__ */ c(
|
|
69
69
|
z,
|
|
70
70
|
{
|
|
71
71
|
sx: {
|
|
72
72
|
bgcolor: "primary.main",
|
|
73
|
-
...!
|
|
73
|
+
...!r.isComplete && {
|
|
74
74
|
bgcolor: "transparent",
|
|
75
75
|
borderColor: "action.active",
|
|
76
76
|
borderStyle: "solid",
|
|
@@ -78,19 +78,19 @@ const J = ({ list: e, onClickItem: t }) => /* @__PURE__ */ c(K, { sx: { bgcolor:
|
|
|
78
78
|
color: "action.active"
|
|
79
79
|
}
|
|
80
80
|
},
|
|
81
|
-
children:
|
|
81
|
+
children: r.icon
|
|
82
82
|
}
|
|
83
83
|
) }),
|
|
84
84
|
/* @__PURE__ */ c(
|
|
85
85
|
W,
|
|
86
86
|
{
|
|
87
|
-
primary: /* @__PURE__ */ c(
|
|
88
|
-
secondary: /* @__PURE__ */ c(
|
|
87
|
+
primary: /* @__PURE__ */ c(A, { sx: { color: "text.secondary" }, variant: "caption", children: r.primaryText }),
|
|
88
|
+
secondary: /* @__PURE__ */ c(A, { sx: { color: "text.primary", fontWeight: 600 }, variant: "body1", children: r.secondaryText })
|
|
89
89
|
}
|
|
90
90
|
)
|
|
91
91
|
] }) }),
|
|
92
|
-
/* @__PURE__ */ c(B, { sx: { color: "divider", ml:
|
|
93
|
-
] },
|
|
92
|
+
/* @__PURE__ */ c(B, { sx: { color: "divider", ml: n === e.length - 1 ? 0 : 68 } })
|
|
93
|
+
] }, r.key))
|
|
94
94
|
}
|
|
95
95
|
) }), Gt = J, Lt = (e) => e * (180 / Math.PI), wt = (e, t) => [
|
|
96
96
|
{
|
|
@@ -129,86 +129,86 @@ const J = ({ list: e, onClickItem: t }) => /* @__PURE__ */ c(K, { sx: { bgcolor:
|
|
|
129
129
|
GOOD: "#FFC02C",
|
|
130
130
|
VERY_GOOD: "#29C76B",
|
|
131
131
|
EXCEPTIONAL: "#008A5A"
|
|
132
|
-
}, Nt = (e, t,
|
|
133
|
-
status:
|
|
132
|
+
}, Nt = (e, t, r) => e >= 300 && e < 580 ? {
|
|
133
|
+
status: r.poor,
|
|
134
134
|
color: t ? u.POOR : g.POOR
|
|
135
135
|
} : e >= 580 && e < 670 ? {
|
|
136
|
-
status:
|
|
136
|
+
status: r.fair,
|
|
137
137
|
color: t ? u.FAIR : g.FAIR
|
|
138
138
|
} : e >= 670 && e < 740 ? {
|
|
139
|
-
status:
|
|
139
|
+
status: r.good,
|
|
140
140
|
color: t ? u.GOOD : g.GOOD
|
|
141
141
|
} : e >= 740 && e < 800 ? {
|
|
142
|
-
status:
|
|
142
|
+
status: r.very_good,
|
|
143
143
|
color: t ? u.VERY_GOOD : g.VERY_GOOD
|
|
144
144
|
} : e >= 800 && e <= 850 ? {
|
|
145
|
-
status:
|
|
145
|
+
status: r.exceptional,
|
|
146
146
|
color: t ? u.EXCEPTIONAL : g.EXCEPTIONAL
|
|
147
|
-
} : { status:
|
|
147
|
+
} : { status: r.missing_data }, Pt = (e, t, r, n) => {
|
|
148
148
|
const o = e.reduce((i, l) => i + l.value, 0);
|
|
149
149
|
let a = 0;
|
|
150
150
|
const s = e.map((i) => {
|
|
151
|
-
const l = i.value / o * t, p =
|
|
151
|
+
const l = i.value / o * t, p = r + a, f = p + l;
|
|
152
152
|
return a += l, {
|
|
153
153
|
...i,
|
|
154
154
|
startAngle: p,
|
|
155
155
|
endAngle: f
|
|
156
156
|
};
|
|
157
157
|
});
|
|
158
|
-
return [s[
|
|
159
|
-
}, kt = (e, t,
|
|
158
|
+
return [s[n].startAngle, s[n].endAngle];
|
|
159
|
+
}, kt = (e, t, r, n, o) => {
|
|
160
160
|
let a = 0, s = 0;
|
|
161
|
-
const i = Math.floor(
|
|
162
|
-
return i >
|
|
163
|
-
}, $t = (e, t,
|
|
164
|
-
const
|
|
165
|
-
return [
|
|
161
|
+
const i = Math.floor(n), l = n - i;
|
|
162
|
+
return i > r ? (a = e, s = t) : i === r && l > 0 && (a = e, s = o), [a, s];
|
|
163
|
+
}, $t = (e, t, r = 0) => {
|
|
164
|
+
const n = e * Math.sin(t - r), o = -e * Math.cos(t - r);
|
|
165
|
+
return [n, o];
|
|
166
166
|
}, zt = ({
|
|
167
167
|
dynamicCopy: e,
|
|
168
168
|
fallbackLabel: t,
|
|
169
|
-
icon:
|
|
170
|
-
key:
|
|
169
|
+
icon: r,
|
|
170
|
+
key: n,
|
|
171
171
|
label: o,
|
|
172
172
|
value: a
|
|
173
173
|
}) => {
|
|
174
|
-
const s = !!a, i = s ? Q(
|
|
174
|
+
const s = !!a, i = s ? Q(n, a) : e && j(e, t) || t;
|
|
175
175
|
return {
|
|
176
|
-
icon: s ? /* @__PURE__ */ c(k, {}) :
|
|
176
|
+
icon: s ? /* @__PURE__ */ c(k, {}) : r,
|
|
177
177
|
isComplete: s,
|
|
178
|
-
key:
|
|
178
|
+
key: n,
|
|
179
179
|
primaryText: o,
|
|
180
180
|
secondaryText: i
|
|
181
181
|
};
|
|
182
182
|
}, Q = (e, t) => ({
|
|
183
|
-
[
|
|
184
|
-
[
|
|
183
|
+
[_.DateOfBirth]: (n) => R(new Date(Number(n) * 1e3), "MMM d, yyyy"),
|
|
184
|
+
[_.MonthlyIncome]: (n) => q(Number(n), "0.00")
|
|
185
185
|
})[e]?.(t) ?? String(t), Kt = (e) => e !== null ? Math.round(e * 100) : null, Bt = (e) => {
|
|
186
186
|
const t = new Date((/* @__PURE__ */ new Date()).getFullYear(), e - 1, 1);
|
|
187
|
-
return
|
|
187
|
+
return I(t, O.MONTH_SHORT);
|
|
188
188
|
}, Yt = (e) => {
|
|
189
|
-
const { good: t, poor:
|
|
190
|
-
return e === null ? "MISSING" : e >= t ? "GOOD" : e >=
|
|
189
|
+
const { good: t, poor: r } = m.daysOfCashOnHand;
|
|
190
|
+
return e === null ? "MISSING" : e >= t ? "GOOD" : e >= r ? "FAIR" : "OFF_TRACK";
|
|
191
191
|
}, Ut = (e) => {
|
|
192
|
-
const { good: t, poor:
|
|
193
|
-
return e === null ? "MISSING" : e >= t ? "GOOD" : e >=
|
|
192
|
+
const { good: t, poor: r } = m.emergencySavings;
|
|
193
|
+
return e === null ? "MISSING" : e >= t ? "GOOD" : e >= r ? "FAIR" : "OFF_TRACK";
|
|
194
194
|
}, Xt = (e) => {
|
|
195
|
-
const { good: t, poor:
|
|
196
|
-
return e === null ? "MISSING" : e < t ? "GOOD" : e <
|
|
195
|
+
const { good: t, poor: r } = m.spendToIncomeRatio;
|
|
196
|
+
return e === null ? "MISSING" : e < t ? "GOOD" : e < r ? "FAIR" : "OFF_TRACK";
|
|
197
197
|
}, Vt = (e) => {
|
|
198
|
-
const { good: t, poor:
|
|
199
|
-
return e === null ? "MISSING" : e <= t ? "GOOD" : e <=
|
|
198
|
+
const { good: t, poor: r } = m.debtToIncomeRatio;
|
|
199
|
+
return e === null ? "MISSING" : e <= t ? "GOOD" : e <= r ? "FAIR" : "OFF_TRACK";
|
|
200
200
|
}, Wt = (e) => {
|
|
201
|
-
const { good: t, poor:
|
|
202
|
-
return e === null ? "MISSING" : e >= t ? "GOOD" : e >=
|
|
201
|
+
const { good: t, poor: r } = m.creditScore;
|
|
202
|
+
return e === null ? "MISSING" : e >= t ? "GOOD" : e >= r ? "FAIR" : "OFF_TRACK";
|
|
203
203
|
}, Z = (e) => e === null ? "MISSING" : e === 0 ? "GOOD" : "OFF_TRACK", jt = (e, t) => {
|
|
204
|
-
const
|
|
204
|
+
const r = Z(e), n = {
|
|
205
205
|
GOOD: t.count_good_description,
|
|
206
206
|
OFF_TRACK: t.count_off_track_description,
|
|
207
207
|
MISSING: t.count_missing_description
|
|
208
208
|
};
|
|
209
209
|
return {
|
|
210
|
-
cardState:
|
|
211
|
-
description: r
|
|
210
|
+
cardState: r,
|
|
211
|
+
description: n[r],
|
|
212
212
|
title: t.count_card_title
|
|
213
213
|
};
|
|
214
214
|
}, qt = (e) => ({
|
|
@@ -216,14 +216,14 @@ const J = ({ list: e, onClickItem: t }) => /* @__PURE__ */ c(K, { sx: { bgcolor:
|
|
|
216
216
|
[S.FAIR]: { backgroundColor: "warning.lighter", color: "warning.dark" },
|
|
217
217
|
[S.OFF_TRACK]: { backgroundColor: "error.lighter", color: "error.dark" },
|
|
218
218
|
[S.MISSING]: { backgroundColor: "divider", color: "text.secondary" }
|
|
219
|
-
})[e], tt = 1, et = 1,
|
|
219
|
+
})[e], tt = 1, et = 1, rt = {
|
|
220
220
|
1: M,
|
|
221
221
|
2: G,
|
|
222
|
-
3:
|
|
223
|
-
},
|
|
222
|
+
3: x
|
|
223
|
+
}, nt = {
|
|
224
224
|
1: w,
|
|
225
|
-
2: (e, t) =>
|
|
226
|
-
3:
|
|
225
|
+
2: (e, t) => y(e, t) / 2,
|
|
226
|
+
3: y,
|
|
227
227
|
4: L
|
|
228
228
|
}, D = [
|
|
229
229
|
{ contributionPeriodIndex: 3, targetAmount: 6, upperLimit: 500 },
|
|
@@ -232,44 +232,44 @@ const J = ({ list: e, onClickItem: t }) => /* @__PURE__ */ c(K, { sx: { bgcolor:
|
|
|
232
232
|
], Jt = ({
|
|
233
233
|
contribution: e,
|
|
234
234
|
goalAmount: t,
|
|
235
|
-
goalPeriod:
|
|
236
|
-
targetPeriod:
|
|
235
|
+
goalPeriod: r,
|
|
236
|
+
targetPeriod: n,
|
|
237
237
|
totalSaved: o
|
|
238
238
|
}) => {
|
|
239
239
|
const a = t - o;
|
|
240
240
|
if (a <= 0) return 0;
|
|
241
|
-
const s = N(), i =
|
|
241
|
+
const s = N(), i = rt[n], l = nt[e];
|
|
242
242
|
if (!i || !l) return a;
|
|
243
|
-
const p = i(s,
|
|
243
|
+
const p = i(s, r), f = l(p, s);
|
|
244
244
|
return Math.max(a / (f || 1), 1);
|
|
245
|
-
}, Qt = (e) => !e || e <= 0 ? "0%" : e >= 1e3 ? "100%" : `${Math.round(e / 10)}%`, Zt = (e) => D.find((
|
|
246
|
-
x:
|
|
247
|
-
y:
|
|
248
|
-
})), ot = (e) => e.sort((t,
|
|
249
|
-
x:
|
|
245
|
+
}, Qt = (e) => !e || e <= 0 ? "0%" : e >= 1e3 ? "100%" : `${Math.round(e / 10)}%`, Zt = (e) => D.find((r) => e < r.upperLimit)?.targetAmount ?? et, te = (e) => D.find((n) => e < n.upperLimit)?.contributionPeriodIndex ?? tt, ee = (e, t) => [...e].sort((n, o) => n.year === o.year ? n.month - o.month : n.year - o.year).map((n) => ({
|
|
246
|
+
x: I(new Date(0, n.month - 1, 1), O.MONTH_SHORT),
|
|
247
|
+
y: n[t]
|
|
248
|
+
})), ot = (e) => e.sort((t, r) => t.monthly_health_score_average.year !== r.monthly_health_score_average.year ? t.monthly_health_score_average.year - r.monthly_health_score_average.year : t.monthly_health_score_average.month - r.monthly_health_score_average.month).map((t) => ({
|
|
249
|
+
x: I(
|
|
250
250
|
new Date(0, t.monthly_health_score_average.month - 1, 1),
|
|
251
|
-
|
|
251
|
+
O.MONTH_SHORT
|
|
252
252
|
),
|
|
253
253
|
y: Math.round(t.monthly_health_score_average.average_health_score)
|
|
254
|
-
})), at = (e) => e.map(({ transaction:
|
|
255
|
-
...
|
|
256
|
-
})).sort((
|
|
254
|
+
})), at = (e) => e.map(({ transaction: r }) => ({
|
|
255
|
+
...r
|
|
256
|
+
})).sort((r, n) => n.date - r.date);
|
|
257
257
|
class F {
|
|
258
258
|
fetchInstance;
|
|
259
|
-
constructor(t,
|
|
260
|
-
this.fetchInstance = new
|
|
259
|
+
constructor(t, r, n) {
|
|
260
|
+
this.fetchInstance = new H(t, r, void 0, n);
|
|
261
261
|
}
|
|
262
262
|
calculateHealthScore = async () => this.fetchInstance.post(`${h.HEALTH_SCORES}/calculate`).then((t) => t.health_score);
|
|
263
263
|
getAverageHealthScores = async () => this.fetchInstance.get(`${h.HEALTH_SCORES}/monthly_averages`).then((t) => t);
|
|
264
264
|
getDebtSpend = async () => this.fetchInstance.get(`${h.HEALTH_SCORES}/transactions/debt_spend`).then((t) => t);
|
|
265
265
|
getIncome = async () => this.fetchInstance.get(`${h.HEALTH_SCORES}/transactions/income`).then((t) => t);
|
|
266
266
|
getMonthlySummaries = async () => this.fetchInstance.get(`${h.HEALTH_SCORES}/monthly_summaries`).then((t) => t);
|
|
267
|
-
getHealthScoreChangeReports = async (t,
|
|
268
|
-
getPeerScore = async (t) => this.fetchInstance.get(`${h.HEALTH_SCORES}/average/${t}`).then((
|
|
267
|
+
getHealthScoreChangeReports = async (t, r) => this.fetchInstance.get(`${h.HEALTH_SCORES}/change_report/from/${t}/to/${r}`).then((n) => n);
|
|
268
|
+
getPeerScore = async (t) => this.fetchInstance.get(`${h.HEALTH_SCORES}/average/${t}`).then((r) => r);
|
|
269
269
|
getSpendingFeeTransactions = async () => this.fetchInstance.get(`${h.HEALTH_SCORES}/transactions/spending_fee`).then((t) => t);
|
|
270
270
|
getStandardSpend = async () => this.fetchInstance.get(`${h.HEALTH_SCORES}/transactions/standard_spend`).then((t) => t);
|
|
271
271
|
}
|
|
272
|
-
class
|
|
272
|
+
class re {
|
|
273
273
|
api = new F("/", "");
|
|
274
274
|
augmentedChartData = [];
|
|
275
275
|
averageHealthScores = [];
|
|
@@ -296,15 +296,15 @@ class ne {
|
|
|
296
296
|
};
|
|
297
297
|
calculateHealthScore = async (t = !0) => {
|
|
298
298
|
try {
|
|
299
|
-
const
|
|
300
|
-
let
|
|
299
|
+
const r = await this.api.calculateHealthScore();
|
|
300
|
+
let n = 0;
|
|
301
301
|
t && await this.loadHealthScoreChangeReports();
|
|
302
|
-
const o =
|
|
303
|
-
|
|
304
|
-
this.healthScore =
|
|
302
|
+
const o = r?.health_score || 0, a = this.healthScoreChangeReports.at(-1)?.older_health_score || 0;
|
|
303
|
+
n = o - a, d(() => {
|
|
304
|
+
this.healthScore = r, this.healthScoreChange = n;
|
|
305
305
|
});
|
|
306
|
-
} catch (
|
|
307
|
-
console.error("Error calculating health score:",
|
|
306
|
+
} catch (r) {
|
|
307
|
+
console.error("Error calculating health score:", r);
|
|
308
308
|
}
|
|
309
309
|
};
|
|
310
310
|
loadAverageHealthScores = async () => {
|
|
@@ -349,28 +349,28 @@ class ne {
|
|
|
349
349
|
}
|
|
350
350
|
};
|
|
351
351
|
loadHealthScoreChangeReports = async () => {
|
|
352
|
-
const t = T(
|
|
352
|
+
const t = T(v(/* @__PURE__ */ new Date(), 2)), r = T(/* @__PURE__ */ new Date());
|
|
353
353
|
try {
|
|
354
|
-
const
|
|
354
|
+
const n = await this.api.getHealthScoreChangeReports(
|
|
355
355
|
t,
|
|
356
|
-
|
|
356
|
+
r
|
|
357
357
|
);
|
|
358
358
|
d(() => {
|
|
359
|
-
this.healthScoreChangeReports =
|
|
359
|
+
this.healthScoreChangeReports = n;
|
|
360
360
|
});
|
|
361
|
-
} catch (
|
|
362
|
-
console.error("Error loading health score change reports:",
|
|
361
|
+
} catch (n) {
|
|
362
|
+
console.error("Error loading health score change reports:", n);
|
|
363
363
|
}
|
|
364
364
|
};
|
|
365
365
|
loadPeerScore = async () => {
|
|
366
366
|
const t = R(b(this.globalStore.appDataStore.user.birthday), "yyyy");
|
|
367
367
|
try {
|
|
368
|
-
const
|
|
368
|
+
const r = await this.api.getPeerScore(t);
|
|
369
369
|
d(() => {
|
|
370
|
-
this.peerScore =
|
|
370
|
+
this.peerScore = r;
|
|
371
371
|
});
|
|
372
|
-
} catch (
|
|
373
|
-
console.error("Error loading peer score:",
|
|
372
|
+
} catch (r) {
|
|
373
|
+
console.error("Error loading peer score:", r);
|
|
374
374
|
}
|
|
375
375
|
};
|
|
376
376
|
loadAugmentedChartData = async () => {
|
|
@@ -385,9 +385,9 @@ class ne {
|
|
|
385
385
|
};
|
|
386
386
|
getSpendingFeeTransactions = async () => {
|
|
387
387
|
try {
|
|
388
|
-
const t = await this.api.getSpendingFeeTransactions(),
|
|
388
|
+
const t = await this.api.getSpendingFeeTransactions(), r = at(t);
|
|
389
389
|
d(() => {
|
|
390
|
-
this.spendingFeeTransactions =
|
|
390
|
+
this.spendingFeeTransactions = r;
|
|
391
391
|
});
|
|
392
392
|
} catch (t) {
|
|
393
393
|
console.error(`Error occurred while getting spending fee transactions: ${t}`);
|
|
@@ -419,9 +419,9 @@ class ne {
|
|
|
419
419
|
};
|
|
420
420
|
}
|
|
421
421
|
export {
|
|
422
|
-
|
|
422
|
+
_ as A,
|
|
423
423
|
u as C,
|
|
424
|
-
|
|
424
|
+
re as F,
|
|
425
425
|
Gt as P,
|
|
426
426
|
kt as a,
|
|
427
427
|
$t as b,
|
package/dist/common/index.es.js
CHANGED
|
@@ -67,7 +67,7 @@ import { startOfToday as D } from "date-fns/startOfToday";
|
|
|
67
67
|
import { f as rt, a as ot, b as A } from "../BudgetUtil-QbRXtLKn.mjs";
|
|
68
68
|
import { g as _o, e as fo, c as mo, d as yo, i as So } from "../BudgetUtil-QbRXtLKn.mjs";
|
|
69
69
|
import { D as at } from "../DebtsStore-BZqNLaqd.mjs";
|
|
70
|
-
import { F as it } from "../FinstrongStore-
|
|
70
|
+
import { F as it } from "../FinstrongStore-BQxXxxYD.mjs";
|
|
71
71
|
import { A as nt, m as ct, a as ut, b as dt } from "../InvestmentUtil-BItV7uEs.mjs";
|
|
72
72
|
import { M as lt } from "../MerchantStore-BzGi4JAZ.mjs";
|
|
73
73
|
import { N as ht } from "../NetWorthStore-DP78lgZ0.mjs";
|
|
@@ -5,8 +5,8 @@ import { useTheme as z, alpha as ce } from "@mui/material/styles";
|
|
|
5
5
|
import { PieChart as tn } from "@mui/x-charts/PieChart";
|
|
6
6
|
import { P as D, H3 as X, Text as I, InstitutionLogo as pt, H2 as Fe, MerchantLogo as nn, Icon as on } from "@mxenabled/mxui";
|
|
7
7
|
import { TrendingUp as rn, ArrowRightAlt as an, TrendingDown as sn, AccountBalance as _t, ChevronRight as Z, CheckCircle as cn, Cancel as ln, CreditCard as ut, Savings as dn, ContentCopy as pn, MultilineChart as _n, Add as ht, Cardiology as un, Payments as hn, CalendarMonth as mn, ExpandMore as gn } from "@mxenabled/mx-icons";
|
|
8
|
-
import { g as yn, a as bn, r as et, b as fn, c as Ne, d as mt, C as ke, e as Me, f as xn, h as Sn, i as Cn, j as gt, k as tt, l as vn, m as nt, n as wn, o as yt, p as kn, q as bt, s as Oe, t as ft, u as Mn, v as xt, w as Dn, A as oe, x as In, P as Tn } from "../FinstrongStore-
|
|
9
|
-
import { y as Ci, F as vi } from "../FinstrongStore-
|
|
8
|
+
import { g as yn, a as bn, r as et, b as fn, c as Ne, d as mt, C as ke, e as Me, f as xn, h as Sn, i as Cn, j as gt, k as tt, l as vn, m as nt, n as wn, o as yt, p as kn, q as bt, s as Oe, t as ft, u as Mn, v as xt, w as Dn, A as oe, x as In, P as Tn } from "../FinstrongStore-BQxXxxYD.mjs";
|
|
9
|
+
import { y as Ci, F as vi } from "../FinstrongStore-BQxXxxYD.mjs";
|
|
10
10
|
import * as ot from "d3";
|
|
11
11
|
import { observer as k } from "mobx-react-lite";
|
|
12
12
|
import { u as v, b as J, a as je, o as ee, y as L, p as An, d as Se, m as Ke, f as On, j as Ve, h as Rn, i as Ln } from "../hooks-zu7yblbi.mjs";
|
|
@@ -1709,7 +1709,7 @@ const zo = ({ total: t }) => {
|
|
|
1709
1709
|
totalMain: d
|
|
1710
1710
|
}) => {
|
|
1711
1711
|
const p = z(), u = qn(p.breakpoints.down("xs")), m = h.useMemo(
|
|
1712
|
-
() => o.sort((g, y) => g.month - y.month).map((g) => {
|
|
1712
|
+
() => o.sort((g, y) => g.year !== y.year ? g.year - y.year : g.month - y.month).map((g) => {
|
|
1713
1713
|
const y = Mn(g.month), A = {
|
|
1714
1714
|
spending_vs_income: {
|
|
1715
1715
|
main: g.standard_spend,
|