@mx-cartographer/experiences 7.0.23-alpha.al8 → 7.0.23
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 +1 -1
- package/dist/{AccountStore-DRJfrlJa.mjs → AccountStore-BaMynkQT.mjs} +17 -17
- package/dist/{ExportCsvAction-CbMfQ2Wa.mjs → ExportCsvAction-CbdFfDV5.mjs} +1 -1
- package/dist/{TransactionStore-0tLtBEIC.mjs → TransactionStore-Cep_Eeql.mjs} +1 -1
- package/dist/accounts/index.es.js +1 -1
- package/dist/budgets/index.es.js +1 -1
- package/dist/common/index.es.js +3 -3
- package/dist/exportTransactionsToCSV-B5qAKd6C.mjs +47 -0
- package/dist/goals/index.es.js +494 -493
- package/dist/transactions/index.es.js +4 -4
- package/dist/trends/index.es.js +99 -96
- package/package.json +1 -1
- package/dist/exportTransactionsToCSV-BDlt8u0n.mjs +0 -47
package/CHANGELOG.md
CHANGED
|
@@ -78,7 +78,7 @@ class N {
|
|
|
78
78
|
return this.accounts.filter((t) => t.account_type === s.SAVINGS);
|
|
79
79
|
}
|
|
80
80
|
get visibleAccounts() {
|
|
81
|
-
return
|
|
81
|
+
return this.accounts.filter((t) => !t.is_hidden);
|
|
82
82
|
}
|
|
83
83
|
get visibleCashAccounts() {
|
|
84
84
|
return this.cashAccounts.filter((t) => !t.is_hidden);
|
|
@@ -118,22 +118,22 @@ class N {
|
|
|
118
118
|
n,
|
|
119
119
|
"MD_EXCLUDE_EXTERNAL_ACCOUNTS"
|
|
120
120
|
);
|
|
121
|
-
for (const
|
|
122
|
-
if (c &&
|
|
123
|
-
const
|
|
124
|
-
if (!
|
|
121
|
+
for (const r of t) {
|
|
122
|
+
if (c && r.member_is_managed_by_user) continue;
|
|
123
|
+
const o = this.members.find((m) => m.guid === r.member_guid);
|
|
124
|
+
if (!o) continue;
|
|
125
125
|
let u = h.Connected;
|
|
126
|
-
p.includes(
|
|
126
|
+
p.includes(o.connection_status) ? u = h.Error : y.includes(o.connection_status) ? u = h.Processing : I.includes(o.connection_status) && (u = h.RequiresMfa);
|
|
127
127
|
const A = [
|
|
128
|
-
|
|
129
|
-
|
|
128
|
+
r.user_name || r.feed_name || "",
|
|
129
|
+
r.account_number ? `*${r.account_number}` : ""
|
|
130
130
|
].join(" ").trim();
|
|
131
131
|
e.push({
|
|
132
|
-
...
|
|
132
|
+
...r,
|
|
133
133
|
connectionStatus: u,
|
|
134
134
|
institutionName: A,
|
|
135
|
-
memberName:
|
|
136
|
-
}),
|
|
135
|
+
memberName: o.name
|
|
136
|
+
}), o.connectionStatus = u;
|
|
137
137
|
}
|
|
138
138
|
return e;
|
|
139
139
|
};
|
|
@@ -172,10 +172,10 @@ class N {
|
|
|
172
172
|
try {
|
|
173
173
|
const e = await this.api.mergeAccounts(t), n = e[Object.keys(e)[0]];
|
|
174
174
|
a(() => {
|
|
175
|
-
const c = this.accounts.findIndex((
|
|
175
|
+
const c = this.accounts.findIndex((o) => o.guid === t[1]);
|
|
176
176
|
this.accounts.splice(c, 1);
|
|
177
|
-
const
|
|
178
|
-
this.accounts.splice(
|
|
177
|
+
const r = this.accounts.findIndex((o) => o.guid === t[0]);
|
|
178
|
+
this.accounts.splice(r, 1, n);
|
|
179
179
|
});
|
|
180
180
|
} catch (e) {
|
|
181
181
|
console.error(`Error occurred while merging accounts: ${e}`);
|
|
@@ -217,13 +217,13 @@ class N {
|
|
|
217
217
|
};
|
|
218
218
|
updateAccountFiltering = async (t, e) => {
|
|
219
219
|
for (const n of t) {
|
|
220
|
-
const c = this.accounts.find((
|
|
220
|
+
const c = this.accounts.find((r) => r.guid === n);
|
|
221
221
|
if (c) {
|
|
222
222
|
c.is_excluded_from_accounts = e, c.is_excluded_from_budgets = e, c.is_excluded_from_cash_flow = e, c.is_excluded_from_debts = e, c.is_excluded_from_goals = e, c.is_excluded_from_investments = e, c.is_excluded_from_net_worth = e, c.is_excluded_from_spending = e, c.is_excluded_from_transactions = e, c.is_excluded_from_trends = e;
|
|
223
223
|
try {
|
|
224
224
|
this.updateAccount(c);
|
|
225
|
-
} catch (
|
|
226
|
-
console.error(`Failed to update account ${n} (added):`,
|
|
225
|
+
} catch (r) {
|
|
226
|
+
console.error(`Failed to update account ${n} (added):`, r);
|
|
227
227
|
}
|
|
228
228
|
}
|
|
229
229
|
}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { jsx as o } from "react/jsx-runtime";
|
|
2
2
|
import { observer as c } from "mobx-react-lite";
|
|
3
3
|
import { Icon as i } from "@mxenabled/mxui";
|
|
4
|
-
import { e as p } from "./exportTransactionsToCSV-
|
|
4
|
+
import { e as p } from "./exportTransactionsToCSV-B5qAKd6C.mjs";
|
|
5
5
|
import { O as m } from "./User-Dq9Qj764.mjs";
|
|
6
6
|
import { R as x } from "./ResponsiveButton-DZFp78fJ.mjs";
|
|
7
7
|
import { e as _, f as C, u as l } from "./hooks-DkUqN6JE.mjs";
|
|
@@ -16,7 +16,7 @@ import { subDays as Y } from "date-fns/subDays";
|
|
|
16
16
|
import { O as n, a as G, T as F } from "./User-Dq9Qj764.mjs";
|
|
17
17
|
import { T as p } from "./TransactionApi-DbbcjI2L.mjs";
|
|
18
18
|
import { b as W } from "./Category-CevNQ03n.mjs";
|
|
19
|
-
import { f as z } from "./exportTransactionsToCSV-
|
|
19
|
+
import { f as z } from "./exportTransactionsToCSV-B5qAKd6C.mjs";
|
|
20
20
|
import { format as k } from "date-fns/format";
|
|
21
21
|
import { f as g, D as O, O as $ } from "./Dialog-CWW597AF.mjs";
|
|
22
22
|
import { endOfMonth as X } from "date-fns/endOfMonth";
|
|
@@ -24,7 +24,7 @@ import X from "@mui/material/ListItem";
|
|
|
24
24
|
import { M as U } from "../MiniWidgetContainer-CTyjmE1h.mjs";
|
|
25
25
|
import e1 from "@mui/material/Stack";
|
|
26
26
|
import { g as U1, a as j1 } from "../AccountFields-CIz-r3gP.mjs";
|
|
27
|
-
import { A as G1, a as K1 } from "../AccountStore-
|
|
27
|
+
import { A as G1, a as K1 } from "../AccountStore-BaMynkQT.mjs";
|
|
28
28
|
const t1 = () => {
|
|
29
29
|
const [c, L] = d.useState(""), { accounts: o } = g(), { selectedAccounts: l } = y(), { setSelectedAccount: u, setSelectedMember: r } = K(), { members: s } = O(), { onEvent: p } = N(), a = [...new Set(l.map((t) => t.account_type))], H = l.find((t) => c === t.guid), h = d.useMemo(
|
|
30
30
|
() => l.filter((t) => t.is_hidden),
|
package/dist/budgets/index.es.js
CHANGED
|
@@ -36,7 +36,7 @@ import Ve from "@mui/material/Alert";
|
|
|
36
36
|
import Ye from "@mui/material/Snackbar";
|
|
37
37
|
import be from "@mui/material/Tab";
|
|
38
38
|
import Ze from "@mui/material/Tabs";
|
|
39
|
-
import { e as qe } from "../exportTransactionsToCSV-
|
|
39
|
+
import { e as qe } from "../exportTransactionsToCSV-B5qAKd6C.mjs";
|
|
40
40
|
import { T as xe, a as Je } from "../TransactionDetails-C-z3HGTT.mjs";
|
|
41
41
|
import ge from "@mui/material/Card";
|
|
42
42
|
import pe from "@mui/material/CardContent";
|
package/dist/common/index.es.js
CHANGED
|
@@ -18,8 +18,8 @@ import { C as qs } from "../CurrencyInput-bEx2Mbd0.mjs";
|
|
|
18
18
|
import { L as Qs } from "../Loader-DUaFpDGv.mjs";
|
|
19
19
|
import { R as zs } from "../ResponsiveButton-DZFp78fJ.mjs";
|
|
20
20
|
import { S as Ks } from "../SearchBox-B2_zLv8-.mjs";
|
|
21
|
-
import { T as ot } from "../TransactionStore-
|
|
22
|
-
import { S as Vs } from "../TransactionStore-
|
|
21
|
+
import { T as ot } from "../TransactionStore-Cep_Eeql.mjs";
|
|
22
|
+
import { S as Vs } from "../TransactionStore-Cep_Eeql.mjs";
|
|
23
23
|
import { T as Js } from "../TabContentContainer-j01JYR_7.mjs";
|
|
24
24
|
import { I as ea } from "../IconBacking-B9oC6uL2.mjs";
|
|
25
25
|
import { D as aa, F as ra, a as oa, c as na, R as ia, S as ca } from "../RepeatingTransaction-BW4J-jeJ.mjs";
|
|
@@ -53,7 +53,7 @@ import { S as hr, T as gr } from "../RecurringTransactionsStore-D62XJtdL.mjs";
|
|
|
53
53
|
import { G as mr, A as _r, B as yr, W as fr, c as Sr, m as br, g as wr, t as xr, k as Cr, x as Dr, e as vr, w as Ar, u as Er, l as Tr, a as Br, j as Ir, y as Nr, s as Fr, b as Mr, q as $r, n as Rr, z as Ur, h as kr, r as Lr, f as Or, v as Gr, o as Hr, p as Pr } from "../hooks-DkUqN6JE.mjs";
|
|
54
54
|
import { u as Wr } from "../useScreenSize-B6JyS_Lj.mjs";
|
|
55
55
|
import { makeAutoObservable as m, runInAction as p, reaction as _t } from "mobx";
|
|
56
|
-
import { a as yt } from "../AccountStore-
|
|
56
|
+
import { a as yt } from "../AccountStore-BaMynkQT.mjs";
|
|
57
57
|
import ft from "posthog-js";
|
|
58
58
|
import { B as St } from "../BeatStore-By4aGoRM.mjs";
|
|
59
59
|
import { endOfMonth as Z } from "date-fns/endOfMonth";
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
import { fromUnixTime as d } from "date-fns/fromUnixTime";
|
|
2
|
+
import { c as u } from "./Category-CevNQ03n.mjs";
|
|
3
|
+
import { f as p, D as m } from "./Dialog-CWW597AF.mjs";
|
|
4
|
+
import { T as g } from "./User-Dq9Qj764.mjs";
|
|
5
|
+
function f(e) {
|
|
6
|
+
return new Set(
|
|
7
|
+
e.filter((n) => n.parent_guid !== void 0).map((n) => n.parent_guid)
|
|
8
|
+
);
|
|
9
|
+
}
|
|
10
|
+
function T(e) {
|
|
11
|
+
return e.reduce((n, t) => (t.parent_guid && (n[t.parent_guid] || (n[t.parent_guid] = []), n[t.parent_guid].push(t)), n), {});
|
|
12
|
+
}
|
|
13
|
+
function j(e, n) {
|
|
14
|
+
const t = f(n), r = T(n), o = /* @__PURE__ */ new Set(), a = [];
|
|
15
|
+
for (const s of e)
|
|
16
|
+
t.has(s.guid) ? (r[s.guid] ?? []).slice().sort((i, c) => Math.abs(c.amount) - Math.abs(i.amount)).forEach((i) => {
|
|
17
|
+
o.has(i.guid) || (a.push(i), o.add(i.guid));
|
|
18
|
+
}) : o.has(s.guid) || (a.push(s), o.add(s.guid));
|
|
19
|
+
return a;
|
|
20
|
+
}
|
|
21
|
+
const A = (e, n) => {
|
|
22
|
+
const t = _(h(e, n)), r = encodeURIComponent(t), o = document.createElement("a");
|
|
23
|
+
o.href = `data:attachment/csv;charset=utf-8,${r}`, o.download = "transactions.csv", document.body.appendChild(o), o.click(), document.body.removeChild(o);
|
|
24
|
+
}, h = (e, n) => e.map((t) => ({
|
|
25
|
+
Date: p(d(t.date), m.YEAR_MONTH_DAY),
|
|
26
|
+
Description: C(t),
|
|
27
|
+
"Original Description": t.feed_description,
|
|
28
|
+
Amount: `${t.amount}`,
|
|
29
|
+
Type: t.transaction_type === g.CREDIT ? "Credit" : "Debit",
|
|
30
|
+
"Parent Category": u[t.top_level_category_guid || ""],
|
|
31
|
+
Category: t.category,
|
|
32
|
+
Account: t.account,
|
|
33
|
+
Tags: y(t, n),
|
|
34
|
+
Memo: t.memo
|
|
35
|
+
})), l = (e) => e ? /[,"\n\r]/.test(e) ? `"${e.replace(/"/g, '""')}"` : e : "", _ = (e) => {
|
|
36
|
+
const n = Object.keys(e[0]).join(",").concat(`\r
|
|
37
|
+
`), t = e.map((r) => Object.values(r).map(l).join(",")).join(`\r
|
|
38
|
+
`);
|
|
39
|
+
return n + t;
|
|
40
|
+
}, C = (e) => {
|
|
41
|
+
let n = e.parent_guid ? "Split: " : "";
|
|
42
|
+
return n += e.is_hidden ? "(Excluded) " : "", n += e.description, n;
|
|
43
|
+
}, y = (e, n) => e.tags.map((t) => n.filter((o) => o.guid === t)[0]?.name ?? "").join(" ");
|
|
44
|
+
export {
|
|
45
|
+
A as e,
|
|
46
|
+
j as f
|
|
47
|
+
};
|