@mx-cartographer/experiences 7.0.9-alpha.mega1 → 7.0.10

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.
Files changed (56) hide show
  1. package/CHANGELOG.md +5 -1
  2. package/dist/{Account-Bdz1k5WZ.mjs → Account-BVKkr6ft.mjs} +1 -1
  3. package/dist/{AccountDetailsContent-CEjEyv_M.mjs → AccountDetailsContent-HwQ1sepW.mjs} +11 -11
  4. package/dist/{AccountDetailsHeader-uX5amBaR.mjs → AccountDetailsHeader-C9uufKqN.mjs} +11 -11
  5. package/dist/{AccountFields-Ckw28o6E.mjs → AccountFields-VRK4zgvW.mjs} +2 -2
  6. package/dist/{AccountListItem-DKwz0HGB.mjs → AccountListItem-SkBUCsb0.mjs} +3 -3
  7. package/dist/{AccountStore-DhfQsEK5.mjs → AccountStore-3Umlm7QY.mjs} +1 -1
  8. package/dist/{Accounts-CAr848d0.mjs → Accounts-CYsoAdW-.mjs} +1 -1
  9. package/dist/{BudgetUtil-spowPvBM.mjs → BudgetUtil-CeSLAcsl.mjs} +1 -1
  10. package/dist/{CategorySelectorDrawer-Dyzb3UDU.mjs → CategorySelectorDrawer-BPvjZ-Xo.mjs} +1 -1
  11. package/dist/{ConnectDrawer-yFS82Il7.mjs → ConnectDrawer-BA9H_xx8.mjs} +1 -1
  12. package/dist/{ConnectionsDrawer-Cl1jJGRv.mjs → ConnectionsDrawer-Bs-NUsAs.mjs} +2 -2
  13. package/dist/{CurrencyInput-CSZjO22Z.mjs → CurrencyInput-bEx2Mbd0.mjs} +1 -1
  14. package/dist/{DebtsStore-Bep2cYsx.mjs → DebtsStore-BwmpJMik.mjs} +1 -1
  15. package/dist/{ExportCsvAction-dpvaZxbS.mjs → ExportCsvAction-CvyiKLTh.mjs} +3 -3
  16. package/dist/GoalStore-BH5TWxYr.mjs +364 -0
  17. package/dist/{Help-BazrEpv7.mjs → Help-B3oENhkG.mjs} +1 -1
  18. package/dist/{LineChart-CYiUS-px.mjs → LineChart-jpdaQX7x.mjs} +1 -1
  19. package/dist/{ListItemAction-BzmbPuNp.mjs → ListItemAction-DNZZ5fSa.mjs} +1 -1
  20. package/dist/{ManageIncome-Dk2ZDGqw.mjs → ManageIncome-DCUX6T2b.mjs} +4 -4
  21. package/dist/{MicroWidgetContainer-DmYiksbT.mjs → MicroWidgetContainer-Dxz8uBN9.mjs} +1 -1
  22. package/dist/{MiniWidgetContainer-DqKQNubH.mjs → MiniWidgetContainer-CTyjmE1h.mjs} +1 -1
  23. package/dist/{NetWorthStore-DrBL4JEO.mjs → NetWorthStore-NKD8a-19.mjs} +2 -2
  24. package/dist/{NotificationSettings-BznqGVQ2.mjs → NotificationSettings-uXVwpIa1.mjs} +17 -17
  25. package/dist/{OriginalBalanceAction-CSu5brQE.mjs → OriginalBalanceAction-DepsKiJz.mjs} +3 -3
  26. package/dist/{RecurringSettings-DNJs5JIe.mjs → RecurringSettings-BD_CIXnV.mjs} +3 -3
  27. package/dist/{Transaction-CyqrHmAA.mjs → Transaction-Dns0Kuuy.mjs} +1 -1
  28. package/dist/{TransactionDetails-B6h5Qo1c.mjs → TransactionDetails-DFDYdDae.mjs} +5 -5
  29. package/dist/{TransactionStore-DSyXtPek.mjs → TransactionStore-BVKUoEHj.mjs} +2 -2
  30. package/dist/{TrendsStore-DR8etTL2.mjs → TrendsStore-D6Un6Y4A.mjs} +1 -1
  31. package/dist/{WidgetContainer-D7sX3S6R.mjs → WidgetContainer-BHhhVctF.mjs} +2 -2
  32. package/dist/accounts/index.es.js +12 -12
  33. package/dist/analytics/index.es.js +2 -2
  34. package/dist/budgets/index.es.js +10 -10
  35. package/dist/cashflow/index.es.js +7 -7
  36. package/dist/categories/index.es.js +1 -1
  37. package/dist/common/index.es.js +22 -22
  38. package/dist/dashboard/index.es.js +9 -9
  39. package/dist/debts/index.es.js +11 -11
  40. package/dist/{exportTransactionsToCSV-BlVifaOG.mjs → exportTransactionsToCSV-B4JW8rfR.mjs} +1 -1
  41. package/dist/finstrong/index.es.js +6 -6
  42. package/dist/goals/index.es.js +560 -647
  43. package/dist/goals/util/GoalsUtil.d.ts +1 -0
  44. package/dist/help/index.es.js +3 -3
  45. package/dist/{hooks-02T565vf.mjs → hooks-DkUqN6JE.mjs} +3 -3
  46. package/dist/investments/index.es.js +3 -3
  47. package/dist/merchants/index.es.js +1 -1
  48. package/dist/networth/index.es.js +7 -7
  49. package/dist/notifications/index.es.js +7 -7
  50. package/dist/recurringtransactions/index.es.js +8 -8
  51. package/dist/settings/index.es.js +6 -6
  52. package/dist/spending/index.es.js +4 -4
  53. package/dist/transactions/index.es.js +13 -13
  54. package/dist/trends/index.es.js +9 -9
  55. package/package.json +1 -1
  56. package/dist/GoalStore-ChqCWX_U.mjs +0 -263
@@ -21,3 +21,4 @@ export type GoalType = {
21
21
  export declare function getGoalStatusData(copy: GoalsCopy, goal: Goal): GoalStatusData;
22
22
  export declare function getGoalTypes(copy: GoalsCopy): GoalType[];
23
23
  export declare const getZeroStateOngoing: (trackType: TrackType, copy: GoalsCopy) => string;
24
+ export declare const getProjectedRetirementDate: (retirementAge: number, userBirthday: number) => number;
@@ -1,9 +1,9 @@
1
1
  import { jsx as r } from "react/jsx-runtime";
2
2
  import { observer as t } from "mobx-react-lite";
3
- import { H as m } from "../Help-BazrEpv7.mjs";
4
- import { a as s } from "../hooks-02T565vf.mjs";
3
+ import { H as m } from "../Help-B3oENhkG.mjs";
4
+ import { a as s } from "../hooks-DkUqN6JE.mjs";
5
5
  import { L as p } from "../Loader-Dp1P2gNw.mjs";
6
- import { W as a } from "../WidgetContainer-D7sX3S6R.mjs";
6
+ import { W as a } from "../WidgetContainer-BHhhVctF.mjs";
7
7
  const x = t(({ sx: o }) => {
8
8
  const { isCopyLoaded: i, isInitialized: e } = s();
9
9
  return !i || !e ? /* @__PURE__ */ r(p, {}) : /* @__PURE__ */ r(a, { sx: { p: 16 }, children: /* @__PURE__ */ r(m, { sx: o }) });
@@ -52,9 +52,9 @@ export {
52
52
  H as h,
53
53
  p as i,
54
54
  P as j,
55
- d as k,
56
- f as l,
57
- y as m,
55
+ f as k,
56
+ y as l,
57
+ d as m,
58
58
  U as n,
59
59
  V as o,
60
60
  M as p,
@@ -4,7 +4,7 @@ import { observer as P } from "mobx-react-lite";
4
4
  import _ from "@mui/material/Stack";
5
5
  import Ee from "@mui/material/Tab";
6
6
  import Ge from "@mui/material/Tabs";
7
- import { C as ge } from "../ConnectionsDrawer-Cl1jJGRv.mjs";
7
+ import { C as ge } from "../ConnectionsDrawer-Bs-NUsAs.mjs";
8
8
  import pe from "@mui/material/useMediaQuery";
9
9
  import Me from "@mui/material/Box";
10
10
  import Ne from "@mui/material/Collapse";
@@ -16,8 +16,8 @@ import xe from "@mui/material/ToggleButton";
16
16
  import ye from "@mui/material/ToggleButtonGroup";
17
17
  import { Text as r, H1 as fe, P as ve, InstitutionLogo as ne } from "@mxenabled/mxui";
18
18
  import Ue from "@mui/material/Button";
19
- import { u as E, e as be, s as H, a as Q, c as se } from "../hooks-02T565vf.mjs";
20
- import { A as z, W as je } from "../WidgetContainer-D7sX3S6R.mjs";
19
+ import { u as E, e as be, s as H, a as Q, c as se } from "../hooks-DkUqN6JE.mjs";
20
+ import { A as z, W as je } from "../WidgetContainer-BHhhVctF.mjs";
21
21
  import { a as ze, f as oe } from "../NumberFormatting-CtWHhyBX.mjs";
22
22
  import { u as U } from "../useScreenSize-B6JyS_Lj.mjs";
23
23
  import le from "@mui/material/styles/useTheme";
@@ -12,7 +12,7 @@ import k from "@mui/material/ListItemText";
12
12
  import A from "@mui/material/Paper";
13
13
  import d from "@mui/material/Stack";
14
14
  import { MerchantLogo as V, Text as R } from "@mxenabled/mxui";
15
- import { b as v, u as w, a as C } from "../hooks-02T565vf.mjs";
15
+ import { b as v, u as w, a as C } from "../hooks-DkUqN6JE.mjs";
16
16
  import { L as p } from "../Loader-Dp1P2gNw.mjs";
17
17
  import { S as N } from "../SearchBox-B2_zLv8-.mjs";
18
18
  import { M as ne } from "../MerchantStore-DVH-QOf0.mjs";
@@ -3,9 +3,9 @@ import { fromUnixTime as Se } from "date-fns/fromUnixTime";
3
3
  import { observer as w } from "mobx-react-lite";
4
4
  import { useTheme as z } from "@mui/material/styles";
5
5
  import { u as Z } from "../useScreenSize-B6JyS_Lj.mjs";
6
- import { p as _e, u as T, c as J, e as Q, a as P, q as ee } from "../hooks-02T565vf.mjs";
6
+ import { p as _e, u as T, c as J, e as Q, a as P, q as ee } from "../hooks-DkUqN6JE.mjs";
7
7
  import { f as we, D as be } from "../Dialog-CWW597AF.mjs";
8
- import { L as We } from "../LineChart-CYiUS-px.mjs";
8
+ import { L as We } from "../LineChart-jpdaQX7x.mjs";
9
9
  import W from "@mui/material/Divider";
10
10
  import B from "@mui/material/List";
11
11
  import E from "@mui/material/ListSubheader";
@@ -19,15 +19,15 @@ import { i as ne } from "../DateUtil-BcuH7ErC.mjs";
19
19
  import { C as y } from "../CurrencyText-YUhH2caW.mjs";
20
20
  import { Button as Te, Stack as Le } from "@mui/material";
21
21
  import { format as Ne, fromUnixTime as De, differenceInMonths as Ee } from "date-fns";
22
- import { g as K } from "../NetWorthStore-DrBL4JEO.mjs";
23
- import { N as Ot } from "../NetWorthStore-DrBL4JEO.mjs";
22
+ import { g as K } from "../NetWorthStore-NKD8a-19.mjs";
23
+ import { N as Ot } from "../NetWorthStore-NKD8a-19.mjs";
24
24
  import { Icon as oe } from "@mxenabled/mx-icons";
25
25
  import { f as U } from "../NumberFormatting-CtWHhyBX.mjs";
26
- import { A as b, W as ke } from "../WidgetContainer-D7sX3S6R.mjs";
26
+ import { A as b, W as ke } from "../WidgetContainer-BHhhVctF.mjs";
27
27
  import { L as O } from "../Loader-Dp1P2gNw.mjs";
28
- import { M as Ae } from "../MicroWidgetContainer-DmYiksbT.mjs";
28
+ import { M as Ae } from "../MicroWidgetContainer-Dxz8uBN9.mjs";
29
29
  import re from "@mui/material/Box";
30
- import { C as Me } from "../ConnectionsDrawer-Cl1jJGRv.mjs";
30
+ import { C as Me } from "../ConnectionsDrawer-Bs-NUsAs.mjs";
31
31
  import He from "@mui/material/Collapse";
32
32
  import V from "@mui/material/ListItemIcon";
33
33
  import ie from "@mui/material/styles/useTheme";
@@ -1,9 +1,9 @@
1
1
  import { A as f, B as C } from "../Notification-ByMBpJ5u.mjs";
2
2
  import { A as _ } from "../Fetch-CkFKy79O.mjs";
3
- import { s as v } from "../NotificationStore-DHtSGySy.mjs";
3
+ import { s as L } from "../NotificationStore-DHtSGySy.mjs";
4
4
  import { N as Nt, f as St } from "../NotificationStore-DHtSGySy.mjs";
5
5
  import { jsx as t, jsxs as d, Fragment as x } from "react/jsx-runtime";
6
- import L, { useEffect as A } from "react";
6
+ import k, { useEffect as A } from "react";
7
7
  import { observer as p } from "mobx-react-lite";
8
8
  import y from "@mui/material/Box";
9
9
  import D from "@mui/material/Divider";
@@ -11,13 +11,13 @@ import B from "@mui/material/List";
11
11
  import { Text as m, InstitutionLogo as T, CategoryIcon as R } from "@mxenabled/mxui";
12
12
  import { h as I } from "../DateUtil-BcuH7ErC.mjs";
13
13
  import { useTheme as O, Card as G } from "@mui/material";
14
- import { c as E, g as j, u as g, n as N, a as S, k as z } from "../hooks-02T565vf.mjs";
14
+ import { c as E, g as j, u as g, n as N, a as S, m as z } from "../hooks-DkUqN6JE.mjs";
15
15
  import { Icon as U, Settings as F } from "@mxenabled/mx-icons";
16
16
  import P from "@mui/material/Button";
17
17
  import W from "@mui/material/Stack";
18
18
  import { L as w } from "../Loader-Dp1P2gNw.mjs";
19
19
  import $ from "@mui/material/IconButton";
20
- import { N as H } from "../NotificationSettings-BznqGVQ2.mjs";
20
+ import { N as H } from "../NotificationSettings-uXVwpIa1.mjs";
21
21
  import { D as b } from "../Drawer-kEE73B87.mjs";
22
22
  const yt = (e) => {
23
23
  switch (e) {
@@ -119,9 +119,9 @@ const yt = (e) => {
119
119
  (!c || a) && /* @__PURE__ */ t(w, { label: u?.loading, size: 40 }),
120
120
  c && !a && i.length === 0 && /* @__PURE__ */ t(q, { onManageNotifications: o }),
121
121
  /* @__PURE__ */ t(B, { sx: { p: 16 }, children: c && !a && i.slice().sort((n, h) => h.delivered_at - n.delivered_at).map((n, h) => {
122
- const k = v(h, i);
122
+ const v = L(h, i);
123
123
  return /* @__PURE__ */ d(y, { sx: { mb: 12 }, children: [
124
- k && /* @__PURE__ */ d(y, { sx: { mb: 12 }, children: [
124
+ v && /* @__PURE__ */ d(y, { sx: { mb: 12 }, children: [
125
125
  /* @__PURE__ */ t(M, { date: n.delivered_at }),
126
126
  /* @__PURE__ */ t(D, {})
127
127
  ] }),
@@ -131,7 +131,7 @@ const yt = (e) => {
131
131
  ] });
132
132
  }, K = p(J), Ct = p(
133
133
  ({ notificationTypes: e, isOpen: o, onClose: a, onNotificationClick: s }) => {
134
- const { config: i } = z(), { notifications: r, settings: u } = g(), { isCopyLoaded: c } = S(), [l, n] = L.useState(!1);
134
+ const { config: i } = z(), { notifications: r, settings: u } = g(), { isCopyLoaded: c } = S(), [l, n] = k.useState(!1);
135
135
  return c ? /* @__PURE__ */ d(x, { children: [
136
136
  /* @__PURE__ */ d(
137
137
  b,
@@ -8,8 +8,8 @@ import { startOfToday as le } from "date-fns/startOfToday";
8
8
  import { subDays as de } from "date-fns/subDays";
9
9
  import re from "@mui/material/Skeleton";
10
10
  import c from "@mui/material/Stack";
11
- import { R as He } from "../RecurringSettings-DNJs5JIe.mjs";
12
- import { M as An } from "../RecurringSettings-DNJs5JIe.mjs";
11
+ import { R as He } from "../RecurringSettings-BD_CIXnV.mjs";
12
+ import { M as An } from "../RecurringSettings-BD_CIXnV.mjs";
13
13
  import { addMonths as ze } from "date-fns/addMonths";
14
14
  import { subMonths as Be } from "date-fns/subMonths";
15
15
  import { isBefore as Ue } from "date-fns/isBefore";
@@ -28,11 +28,11 @@ import { isSameDay as tt } from "date-fns/isSameDay";
28
28
  import nt from "@mui/material/Badge";
29
29
  import { PickersDay as it } from "@mui/x-date-pickers/PickersDay";
30
30
  import { I as Y } from "../IconBacking-B9oC6uL2.mjs";
31
- import { u as D, a as V, h as v, e as X, c as pe, f as ge, p as rt } from "../hooks-02T565vf.mjs";
31
+ import { u as D, a as V, h as v, e as X, c as pe, f as ge, p as rt } from "../hooks-DkUqN6JE.mjs";
32
32
  import { c as M, a as R, g as De, f as ot } from "../RepeatingTransaction-BW4J-jeJ.mjs";
33
33
  import { T as P } from "../RecurringTransactionsStore-D62XJtdL.mjs";
34
34
  import { R as Gn } from "../RecurringTransactionsStore-D62XJtdL.mjs";
35
- import { A as _, W as at } from "../WidgetContainer-D7sX3S6R.mjs";
35
+ import { A as _, W as at } from "../WidgetContainer-BHhhVctF.mjs";
36
36
  import st from "@mui/material/Button";
37
37
  import se from "@mui/material/Divider";
38
38
  import Se from "@mui/material/List";
@@ -41,8 +41,8 @@ import ct from "@mui/material/ListSubheader";
41
41
  import lt from "@mui/material/ListItemAvatar";
42
42
  import dt from "@mui/material/ListItemButton";
43
43
  import ut from "@mui/material/ListItemText";
44
- import { b as mt } from "../ManageIncome-Dk2ZDGqw.mjs";
45
- import { c as On, M as kn, S as Wn } from "../ManageIncome-Dk2ZDGqw.mjs";
44
+ import { b as mt } from "../ManageIncome-DCUX6T2b.mjs";
45
+ import { c as On, M as kn, S as Wn } from "../ManageIncome-DCUX6T2b.mjs";
46
46
  import { f as L } from "../NumberFormatting-CtWHhyBX.mjs";
47
47
  import { D as Ae } from "../Drawer-kEE73B87.mjs";
48
48
  import { b as N } from "../Localization-2MODESHW.mjs";
@@ -51,9 +51,9 @@ import O from "@mui/material/Box";
51
51
  import { S as Ee } from "../StatusBar-BK_uYHAB.mjs";
52
52
  import { u as Ge } from "../useScreenSize-B6JyS_Lj.mjs";
53
53
  import { L as j } from "../Loader-Dp1P2gNw.mjs";
54
- import { M as pt } from "../MiniWidgetContainer-DqKQNubH.mjs";
54
+ import { M as pt } from "../MiniWidgetContainer-CTyjmE1h.mjs";
55
55
  import { u as gt } from "../useDimensions-27p2evRx.mjs";
56
- import { M as ht } from "../MicroWidgetContainer-DmYiksbT.mjs";
56
+ import { M as ht } from "../MicroWidgetContainer-Dxz8uBN9.mjs";
57
57
  const Z = {
58
58
  gridRow: 1,
59
59
  gridColumn: 1,
@@ -16,9 +16,9 @@ import F from "@mui/material/Box";
16
16
  import Q from "@mui/material/Button";
17
17
  import I from "@mui/material/TextField";
18
18
  import { H3 as J, P as H, Text as x, Icon as M, ChevronRightIcon as xe } from "@mxenabled/mxui";
19
- import { V as ve, a as Ce, N as G } from "../NotificationSettings-BznqGVQ2.mjs";
20
- import { A as Yt, B as qt, I as Qt } from "../NotificationSettings-BznqGVQ2.mjs";
21
- import { u as k, k as $, r as A, o as De, a as Z, l as ee } from "../hooks-02T565vf.mjs";
19
+ import { V as ve, a as Ce, N as G } from "../NotificationSettings-uXVwpIa1.mjs";
20
+ import { A as Yt, B as qt, I as Qt } from "../NotificationSettings-uXVwpIa1.mjs";
21
+ import { u as k, m as $, r as A, o as De, a as Z, k as ee } from "../hooks-DkUqN6JE.mjs";
22
22
  import { u as L } from "../useScreenSize-B6JyS_Lj.mjs";
23
23
  import { a as W } from "../Dialog-CWW597AF.mjs";
24
24
  import { formatDistanceToNow as te } from "date-fns/formatDistanceToNow";
@@ -35,14 +35,14 @@ import { L as ne } from "../Loader-Dp1P2gNw.mjs";
35
35
  import Ie from "@mui/material/List";
36
36
  import j from "@mui/material/Divider";
37
37
  import Ae from "@mui/material/ListSubheader";
38
- import { a as Ee, u as Pe } from "../CategorySelectorDrawer-Dyzb3UDU.mjs";
38
+ import { a as Ee, u as Pe } from "../CategorySelectorDrawer-BPvjZ-Xo.mjs";
39
39
  import Re from "@mui/material/ListItem";
40
40
  import Be from "@mui/material/ListItemButton";
41
41
  import Me from "@mui/material/ListItemIcon";
42
42
  import Ne from "@mui/material/ListItemText";
43
43
  import { D as He } from "../Drawer-kEE73B87.mjs";
44
- import { H as Le } from "../Help-BazrEpv7.mjs";
45
- import { W as K } from "../WidgetContainer-D7sX3S6R.mjs";
44
+ import { H as Le } from "../Help-B3oENhkG.mjs";
45
+ import { W as K } from "../WidgetContainer-BHhhVctF.mjs";
46
46
  const Oe = ({ availableWidth: t, handleOnLeavClick: a }) => {
47
47
  const o = ye(), { common: n, settings: r } = k(), { isDesktop: m, isMobile: l, isSmallMobile: i, isTablet: s } = L(t), { config: g } = $(), { updateUser: _ } = A(), { user: d } = De(), [u, S] = h.useState({
48
48
  first_name: d.first_name,
@@ -14,20 +14,20 @@ import { Text as f, CategoryIcon as ht, CategoryIconVariants as ft } from "@mxen
14
14
  import { f as A } from "../NumberFormatting-CtWHhyBX.mjs";
15
15
  import yt from "@mui/material/Button";
16
16
  import { useTheme as it } from "@mui/material";
17
- import { u as w, a as R, l as z, c as rt, k as st, f as Ct, e as _t } from "../hooks-02T565vf.mjs";
17
+ import { u as w, a as R, k as z, c as rt, m as st, f as Ct, e as _t } from "../hooks-DkUqN6JE.mjs";
18
18
  import { u as ct } from "../useScreenSize-B6JyS_Lj.mjs";
19
19
  import { D as bt } from "../Donut-1UMNcG67.mjs";
20
20
  import { L as F } from "../Loader-Dp1P2gNw.mjs";
21
- import { M as St } from "../MiniWidgetContainer-DqKQNubH.mjs";
21
+ import { M as St } from "../MiniWidgetContainer-CTyjmE1h.mjs";
22
22
  import { startOfToday as U } from "date-fns/startOfToday";
23
- import { T as Tt, a as Mt } from "../TransactionDetails-B6h5Qo1c.mjs";
23
+ import { T as Tt, a as Mt } from "../TransactionDetails-DFDYdDae.mjs";
24
24
  import Dt from "@mui/material/Collapse";
25
25
  import B from "@mui/material/Divider";
26
26
  import q from "@mui/material/List";
27
27
  import J from "@mui/material/ListItem";
28
28
  import xt from "@mui/material/ListItemButton";
29
29
  import { D as Q } from "../Drawer-kEE73B87.mjs";
30
- import { A as Z, W as wt } from "../WidgetContainer-D7sX3S6R.mjs";
30
+ import { A as Z, W as wt } from "../WidgetContainer-BHhhVctF.mjs";
31
31
  const j = 5, vt = (n, l, r) => r.reduce((i, c) => {
32
32
  if (c.total > 0) {
33
33
  const a = n.find((s) => s.guid === c.category_guid);
@@ -1,12 +1,12 @@
1
1
  import { T as ha } from "../TransactionApi-DbbcjI2L.mjs";
2
- import { u as B, C as Le, D as Re, M as He, c as Be, T as Pe, a as $e } from "../TransactionDetails-B6h5Qo1c.mjs";
3
- import { B as Ca, d as ya, b as ba } from "../TransactionDetails-B6h5Qo1c.mjs";
4
- import { T as M } from "../Transaction-CyqrHmAA.mjs";
5
- import { O as Aa } from "../Transaction-CyqrHmAA.mjs";
6
- import { S as ee, D as Ve } from "../TransactionStore-DSyXtPek.mjs";
7
- import { T as xa } from "../TransactionStore-DSyXtPek.mjs";
8
- import { e as We } from "../exportTransactionsToCSV-BlVifaOG.mjs";
9
- import { E as Ia } from "../ExportCsvAction-dpvaZxbS.mjs";
2
+ import { u as B, C as Le, D as Re, M as He, c as Be, T as Pe, a as $e } from "../TransactionDetails-DFDYdDae.mjs";
3
+ import { B as Ca, d as ya, b as ba } from "../TransactionDetails-DFDYdDae.mjs";
4
+ import { T as M } from "../Transaction-Dns0Kuuy.mjs";
5
+ import { O as Aa } from "../Transaction-Dns0Kuuy.mjs";
6
+ import { S as ee, D as Ve } from "../TransactionStore-BVKUoEHj.mjs";
7
+ import { T as xa } from "../TransactionStore-BVKUoEHj.mjs";
8
+ import { e as We } from "../exportTransactionsToCSV-B4JW8rfR.mjs";
9
+ import { E as Ia } from "../ExportCsvAction-CvyiKLTh.mjs";
10
10
  import { jsxs as _, jsx as e } from "react/jsx-runtime";
11
11
  import u from "react";
12
12
  import { observer as S } from "mobx-react-lite";
@@ -15,7 +15,7 @@ import { DataGridPro as Ue } from "@mui/x-data-grid-pro";
15
15
  import A from "@mui/material/Box";
16
16
  import { useTheme as Fe } from "@mui/material/styles";
17
17
  import { Text as C, Icon as H, MerchantLogo as ze, TextField as te, P as Ke } from "@mxenabled/mxui";
18
- import { f as P, u as x, a as K, c as re, l as qe, k as je, e as Xe, o as Ye } from "../hooks-02T565vf.mjs";
18
+ import { f as P, u as x, a as K, c as re, k as qe, m as je, e as Xe, o as Ye } from "../hooks-DkUqN6JE.mjs";
19
19
  import { fromUnixTime as Je } from "date-fns/fromUnixTime";
20
20
  import { f as Qe, D as Ze, a as se } from "../Dialog-CWW597AF.mjs";
21
21
  import N from "@mui/material/Stack";
@@ -26,15 +26,15 @@ import { getUnixTime as tt } from "date-fns/getUnixTime";
26
26
  import { startOfMonth as at } from "date-fns/startOfMonth";
27
27
  import { startOfToday as z } from "date-fns/startOfToday";
28
28
  import nt from "@mui/material/styles/useTheme";
29
- import { h as ot } from "../ConnectDrawer-yFS82Il7.mjs";
29
+ import { h as ot } from "../ConnectDrawer-BA9H_xx8.mjs";
30
30
  import rt from "@mui/material/Divider";
31
31
  import st from "@mui/material/MenuItem";
32
32
  import it from "@mui/material/RadioGroup";
33
33
  import { ExpandMore as ct } from "@mxenabled/mx-icons";
34
- import { C as lt } from "../CurrencyInput-CSZjO22Z.mjs";
35
- import { a as dt, u as ut } from "../CategorySelectorDrawer-Dyzb3UDU.mjs";
34
+ import { C as lt } from "../CurrencyInput-bEx2Mbd0.mjs";
35
+ import { a as dt, u as ut } from "../CategorySelectorDrawer-BPvjZ-Xo.mjs";
36
36
  import { b as ae } from "../Localization-2MODESHW.mjs";
37
- import { A as T, W as mt } from "../WidgetContainer-D7sX3S6R.mjs";
37
+ import { A as T, W as mt } from "../WidgetContainer-BHhhVctF.mjs";
38
38
  import { u as _t } from "../useScreenSize-B6JyS_Lj.mjs";
39
39
  import { S as pt } from "../SearchBox-B2_zLv8-.mjs";
40
40
  import { D as ne } from "../Drawer-kEE73B87.mjs";
@@ -7,12 +7,12 @@ import b from "@mui/material/Stack";
7
7
  import ge from "@mui/material/Button";
8
8
  import { addSeconds as De } from "date-fns/addSeconds";
9
9
  import { differenceInCalendarMonths as pe } from "date-fns/differenceInCalendarMonths";
10
- import { a as ze, g as Fe, S as Pe, L as Ie, u as Ke } from "../TrendsStore-DR8etTL2.mjs";
11
- import { T as Zn } from "../TrendsStore-DR8etTL2.mjs";
10
+ import { a as ze, g as Fe, S as Pe, L as Ie, u as Ke } from "../TrendsStore-D6Un6Y4A.mjs";
11
+ import { T as Zn } from "../TrendsStore-D6Un6Y4A.mjs";
12
12
  import { i as $e, c as je, d as Ye, e as Ue, f as Xe, h as Ze, b as Ee, g as Le, j as ye } from "../SpendingData-D5vsfYKo.mjs";
13
13
  import Qe from "@mui/material/ToggleButton";
14
14
  import qe from "@mui/material/ToggleButtonGroup";
15
- import { u as k, l as F, e as N, a as P, f as ne, c as oe, v as J, m as xe, p as Je } from "../hooks-02T565vf.mjs";
15
+ import { u as k, k as F, e as N, a as P, f as ne, c as oe, v as J, l as xe, p as Je } from "../hooks-DkUqN6JE.mjs";
16
16
  import { u as K } from "../useScreenSize-B6JyS_Lj.mjs";
17
17
  import { f as Q, D as z } from "../Dialog-CWW597AF.mjs";
18
18
  import { DataGridPro as et } from "@mui/x-data-grid-pro";
@@ -21,17 +21,17 @@ import { c as ve } from "../Category-CevNQ03n.mjs";
21
21
  import { b as nt } from "../Localization-2MODESHW.mjs";
22
22
  import { H as _e } from "../HeaderCell-DjuifqHJ.mjs";
23
23
  import { T as R, b as ot } from "../ViewMoreMicroCard-BZI5VMNW.mjs";
24
- import { A as _, W as Me } from "../WidgetContainer-D7sX3S6R.mjs";
25
- import { a as Ae, T as Re } from "../TransactionDetails-B6h5Qo1c.mjs";
24
+ import { A as _, W as Me } from "../WidgetContainer-BHhhVctF.mjs";
25
+ import { a as Ae, T as Re } from "../TransactionDetails-DFDYdDae.mjs";
26
26
  import { D as Ce } from "../Drawer-kEE73B87.mjs";
27
27
  import { L as q } from "../Loader-Dp1P2gNw.mjs";
28
28
  import { useTheme as ke } from "@mui/material/styles";
29
- import { L as Te } from "../LineChart-CYiUS-px.mjs";
30
- import { M as st } from "../MiniWidgetContainer-DqKQNubH.mjs";
29
+ import { L as Te } from "../LineChart-jpdaQX7x.mjs";
30
+ import { M as st } from "../MiniWidgetContainer-CTyjmE1h.mjs";
31
31
  import { subMonths as rt } from "date-fns";
32
32
  import { TrendingUp as at, TrendingDown as it, MultilineChart as ct, ExpandLess as lt, ExpandMore as dt } from "@mxenabled/mx-icons";
33
33
  import { a as ht, f as X } from "../NumberFormatting-CtWHhyBX.mjs";
34
- import { M as ut } from "../MicroWidgetContainer-DmYiksbT.mjs";
34
+ import { M as ut } from "../MicroWidgetContainer-Dxz8uBN9.mjs";
35
35
  import mt from "@mui/material/Collapse";
36
36
  import gt from "@mui/material/List";
37
37
  import pt from "@mui/material/ListItem";
@@ -43,7 +43,7 @@ import yt from "@mui/material/Divider";
43
43
  import { useTheme as _t, Stack as bt } from "@mui/material";
44
44
  import St from "@mui/material/Paper";
45
45
  import { b as wt } from "../CategoryUtil-BR3H5i6n.mjs";
46
- import { E as Dt } from "../ExportCsvAction-dpvaZxbS.mjs";
46
+ import { E as Dt } from "../ExportCsvAction-CvyiKLTh.mjs";
47
47
  import { E as It } from "../EmptyState-Dcb-o2tl.mjs";
48
48
  const Ne = ({ selectedTab: n, onTabChange: o }) => /* @__PURE__ */ e(
49
49
  qe,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@mx-cartographer/experiences",
3
- "version": "7.0.9-alpha.mega1",
3
+ "version": "7.0.10",
4
4
  "description": "Library containing experience widgets",
5
5
  "author": "MX",
6
6
  "license": "MIT",
@@ -1,263 +0,0 @@
1
- import { jsxs as d, jsx as l } from "react/jsx-runtime";
2
- import u from "react";
3
- import g from "@mui/material/Button";
4
- import _ from "@mui/material/Card";
5
- import R from "@mui/material/CardContent";
6
- import G from "@mui/material/CardHeader";
7
- import C from "@mui/material/Stack";
8
- import { AccountBalance as f, ChevronRight as I } from "@mxenabled/mx-icons";
9
- import { Text as A } from "@mxenabled/mxui";
10
- import { h as N } from "./ConnectDrawer-yFS82Il7.mjs";
11
- import { k as O } from "./hooks-02T565vf.mjs";
12
- import { makeAutoObservable as p, runInAction as i } from "mobx";
13
- import { F as w, A as s } from "./Fetch-CkFKy79O.mjs";
14
- const V = ({ description: o, label: t, title: e }) => {
15
- const { config: r } = O(), [n, a] = u.useState(!1);
16
- if (r.show_connections_widget_in_master)
17
- return /* @__PURE__ */ d(u.Fragment, { children: [
18
- /* @__PURE__ */ d(_, { sx: { m: 24 }, children: [
19
- /* @__PURE__ */ l(
20
- G,
21
- {
22
- avatar: /* @__PURE__ */ l(f, {}),
23
- sx: { ".MuiCardHeader-avatar": { mr: 8 } },
24
- title: /* @__PURE__ */ l(A, { bold: !0, variant: "Body", children: e })
25
- }
26
- ),
27
- /* @__PURE__ */ l(R, { sx: { ":last-child": { pb: 4 }, ml: 28, py: 0 }, children: /* @__PURE__ */ d(C, { alignItems: "flex-start", spacing: 2, children: [
28
- /* @__PURE__ */ l(A, { color: "text.secondary", sx: { textWrap: "wrap" }, variant: "ParagraphSmall", children: o }),
29
- /* @__PURE__ */ l(
30
- g,
31
- {
32
- endIcon: /* @__PURE__ */ l(I, {}),
33
- onClick: () => a(!0),
34
- sx: {
35
- pl: 0,
36
- ":hover": {
37
- bgcolor: "unset"
38
- }
39
- },
40
- variant: "text",
41
- children: t
42
- }
43
- )
44
- ] }) })
45
- ] }),
46
- /* @__PURE__ */ l(
47
- N,
48
- {
49
- onClose: () => a(!1),
50
- showConnectWidget: n,
51
- title: t
52
- }
53
- )
54
- ] });
55
- };
56
- var c = /* @__PURE__ */ ((o) => (o[o.DEBT_TRACK = 1] = "DEBT_TRACK", o[o.SAVINGS_TRACK = 2] = "SAVINGS_TRACK", o[o.RETIREMENT_TRACK = 3] = "RETIREMENT_TRACK", o[o.EMERGENCY_FUND_TRACK = 4] = "EMERGENCY_FUND_TRACK", o))(c || {}), S = /* @__PURE__ */ ((o) => (o[o.SAVE_AMOUNT = 1] = "SAVE_AMOUNT", o[o.KEEP_BALANCE_BELOW = 2] = "KEEP_BALANCE_BELOW", o[o.KEEP_BALANCE_ABOVE = 3] = "KEEP_BALANCE_ABOVE", o[o.ACTION = 4] = "ACTION", o))(S || {}), L = /* @__PURE__ */ ((o) => (o[o.AUTOMOBILE = 1] = "AUTOMOBILE", o[o.COLLEGE = 2] = "COLLEGE", o[o.HOUSE = 3] = "HOUSE", o[o.RECREATIONAL_VEHICLE = 4] = "RECREATIONAL_VEHICLE", o[o.VACATION = 5] = "VACATION", o[o.ELECTRONIC = 6] = "ELECTRONIC", o[o.OTHER = 7] = "OTHER", o[o.RETIREMENT = 8] = "RETIREMENT", o[o.EMERGENCY_FUND = 9] = "EMERGENCY_FUND", o[o.SETUP_BUDGETS = 10] = "SETUP_BUDGETS", o[o.START_MONEY_MANAGEMENT = 11] = "START_MONEY_MANAGEMENT", o[o.CREDIT_CARD = 12] = "CREDIT_CARD", o[o.LINE_OF_CREDIT = 13] = "LINE_OF_CREDIT", o[o.LOANS = 14] = "LOANS", o))(L || {});
57
- class m {
58
- fetchInstance;
59
- constructor(t, e) {
60
- this.fetchInstance = new w(t, e);
61
- }
62
- addGoal = async (t) => this.fetchInstance.post(s.GOALS, t).then((e) => e.goal);
63
- addRetirementGoal = async (t) => this.fetchInstance.post(s.RETIREMENT_GOALS, t).then((e) => e.retirement_goal);
64
- addRetirementGoalAccount = async (t) => this.fetchInstance.post(s.RETIREMENT_GOAL_ACCOUNTS, t).then((e) => e.retirement_goal_account);
65
- getGoalByGuid = async (t) => this.fetchInstance.get(`${s.GOALS}/${t}`).then((e) => e.goal);
66
- getGoals = async () => this.fetchInstance.get(s.GOALS).then((t) => t.goals);
67
- getMonthlyCashFlowProfile = async () => this.fetchInstance.get(s.MONTHLY_CASH_FLOW_PROFILE).then((t) => t.monthly_cash_flow_profile);
68
- getRetirementGoals = async () => this.fetchInstance.get(s.RETIREMENT_GOALS).then((t) => t.retirement_goals);
69
- getRetirementGoalAccounts = async () => this.fetchInstance.get(s.RETIREMENT_GOAL_ACCOUNTS).then((t) => t.retirement_goal_accounts);
70
- removeGoal = async (t) => this.fetchInstance.delete(`${s.GOALS}/${t}`).then((e) => e);
71
- removeRetirementGoal = async (t) => this.fetchInstance.delete(`${s.RETIREMENT_GOALS}/${t}`).then((e) => e);
72
- removeRetirementGoalAccount = async (t) => this.fetchInstance.delete(`${s.RETIREMENT_GOAL_ACCOUNTS}/${t}`).then((e) => e);
73
- reorderGoals = async (t) => this.fetchInstance.post(`${s.GOALS}/reposition`, { goals: t }).then((e) => e.goals);
74
- updateGoal = async (t) => this.fetchInstance.put(`${s.GOALS}/${t.guid}`, t).then((e) => e.goal);
75
- updateMonthlyCashFlowProfile = async (t) => this.fetchInstance.put(`${s.MONTHLY_CASH_FLOW_PROFILE}`, t).then((e) => e.monthly_cash_flow_profile);
76
- updateRetirementGoal = async (t) => this.fetchInstance.put(`${s.RETIREMENT_GOALS}/${t.guid}`, t).then((e) => e.retirement_goal);
77
- }
78
- class k {
79
- globalStore;
80
- api = new m("/", "");
81
- alert = "";
82
- goals = [];
83
- retirementGoalAccounts = [];
84
- newRetirementGoalAccounts = [];
85
- selectedGoal = void 0;
86
- monthlyCashFlowProfile = void 0;
87
- goalsLoaded = !1;
88
- constructor(t) {
89
- this.globalStore = t, this.api = new m(t.endpoint, t.sessionToken), p(this);
90
- }
91
- get orderedGoals() {
92
- return this.goals.slice().sort((t, e) => t.position - e.position);
93
- }
94
- get debtGoals() {
95
- return this.orderedGoals.filter((t) => t.track_type === c.DEBT_TRACK);
96
- }
97
- get retirmentGoals() {
98
- return this.orderedGoals.filter((t) => t.track_type === c.RETIREMENT_TRACK);
99
- }
100
- get savingGoals() {
101
- return this.orderedGoals.filter((t) => t.track_type === c.SAVINGS_TRACK);
102
- }
103
- get ongoingGoalsForMicroWidget() {
104
- const t = this.goals.filter(
105
- (r) => !r.is_complete && r.track_type !== c.EMERGENCY_FUND_TRACK && r.track_type !== null
106
- ), e = [
107
- c.SAVINGS_TRACK,
108
- c.DEBT_TRACK,
109
- c.RETIREMENT_TRACK
110
- ];
111
- return t.sort((r, n) => {
112
- const a = r.track_type ? e.indexOf(r.track_type) : -1, h = n.track_type ? e.indexOf(n.track_type) : -1;
113
- return a - h;
114
- }).slice(0, 3);
115
- }
116
- addGoal = async (t) => {
117
- try {
118
- const e = await this.api.addGoal(t);
119
- i(() => {
120
- this.goals = [...this.goals, e];
121
- });
122
- } catch (e) {
123
- console.error(`Error occurred while adding goal: ${e}`);
124
- }
125
- };
126
- addRetirementGoal = async (t) => {
127
- const e = this.globalStore.copyStore.copy.goals;
128
- try {
129
- const r = await this.api.addRetirementGoal(t), n = [];
130
- for (const a of this.newRetirementGoalAccounts) {
131
- const h = await this.api.addRetirementGoalAccount({
132
- ...a,
133
- retirement_goal_guid: r.guid
134
- });
135
- n.push(h);
136
- }
137
- this.setNewRetirementGoalAccounts([]), i(() => {
138
- this.goals = [
139
- ...this.goals,
140
- {
141
- ...r,
142
- amount: r.target_amount,
143
- name: e.retirement,
144
- track_type: c.RETIREMENT_TRACK
145
- }
146
- ], this.retirementGoalAccounts = [...this.retirementGoalAccounts, ...n];
147
- });
148
- } catch (r) {
149
- console.error(`Error occurred while adding retirement goal: ${r}`);
150
- }
151
- };
152
- addRetirementGoalAccount = async (t) => {
153
- try {
154
- const e = await this.api.addRetirementGoalAccount(t);
155
- i(() => {
156
- this.retirementGoalAccounts = [...this.retirementGoalAccounts, e];
157
- });
158
- } catch (e) {
159
- console.error(`Error occurred while adding retirement goal account: ${e}`);
160
- }
161
- };
162
- loadGoals = async () => {
163
- const t = this.globalStore.copyStore.copy.goals;
164
- try {
165
- const e = await this.api.getGoals(), r = await this.api.getRetirementGoals(), n = await this.api.getRetirementGoalAccounts(), a = await this.api.getMonthlyCashFlowProfile(), h = [
166
- ...e,
167
- ...r.map((E) => ({
168
- ...E,
169
- amount: E.target_amount,
170
- name: t.retirement,
171
- track_type: c.RETIREMENT_TRACK
172
- }))
173
- ];
174
- i(() => {
175
- this.goals = h, this.retirementGoalAccounts = n, this.monthlyCashFlowProfile = a, this.goalsLoaded = !0;
176
- });
177
- } catch (e) {
178
- console.error(`Error occured while getting goals: ${e}`);
179
- }
180
- };
181
- deleteGoal = async (t) => {
182
- try {
183
- await this.api.removeGoal(t), i(() => {
184
- const e = this.goals.findIndex((r) => r.guid === t);
185
- e >= 0 && this.goals.splice(e, 1);
186
- });
187
- } catch (e) {
188
- console.error(`Error occured while deleting goal: ${e}`);
189
- }
190
- };
191
- deleteRetirementGoal = async (t) => {
192
- try {
193
- const e = this.retirementGoalAccounts.filter(
194
- (r) => r.retirement_goal_guid === t.guid
195
- );
196
- for (const r of e)
197
- await this.deleteRetirementGoalAccount(r.guid);
198
- await this.api.removeRetirementGoal(t.guid), i(() => {
199
- const r = this.goals.findIndex((n) => n.guid === t.guid);
200
- r >= 0 && this.goals.splice(r, 1);
201
- });
202
- } catch (e) {
203
- console.error(`Error deleting retirement goal: ${e}`);
204
- }
205
- };
206
- deleteRetirementGoalAccount = async (t) => {
207
- try {
208
- await this.api.removeRetirementGoalAccount(t), i(() => {
209
- const e = this.retirementGoalAccounts.findIndex((r) => r.guid === t);
210
- e >= 0 && this.retirementGoalAccounts.splice(e, 1);
211
- });
212
- } catch (e) {
213
- console.error(`Error deleting retirement goal account: ${e}`);
214
- }
215
- };
216
- reorderGoals = async (t) => {
217
- try {
218
- const e = await this.api.reorderGoals(t);
219
- i(() => {
220
- for (const r of e) {
221
- const n = this.goals.findIndex((a) => a.guid === r.guid);
222
- n >= 0 && (this.goals[n].position = r.position);
223
- }
224
- });
225
- } catch (e) {
226
- console.error(`Error reordering goals: ${e}`);
227
- }
228
- };
229
- setAlert = (t) => this.alert = t;
230
- setNewRetirementGoalAccounts = (t) => {
231
- this.newRetirementGoalAccounts = t;
232
- };
233
- setSelectedGoal = (t) => this.selectedGoal = t;
234
- updateGoal = async (t) => {
235
- try {
236
- const e = await this.api.updateGoal(t);
237
- i(() => {
238
- const r = this.goals.findIndex((n) => n.guid === t.guid);
239
- r >= 0 && (this.goals[r] = e), this.selectedGoal?.guid === t.guid && this.setSelectedGoal(e);
240
- });
241
- } catch (e) {
242
- console.error(`Error occurred while updating goal: ${e}`);
243
- }
244
- };
245
- updateMonthlyCashFlowProfile = async (t) => {
246
- try {
247
- const e = await this.api.updateMonthlyCashFlowProfile(t);
248
- i(() => {
249
- this.monthlyCashFlowProfile = e;
250
- });
251
- } catch (e) {
252
- console.error(`Error occurred while updating monthly Cash Flow profile: ${e}`);
253
- }
254
- };
255
- }
256
- export {
257
- V as C,
258
- S as G,
259
- L as M,
260
- c as T,
261
- m as a,
262
- k as b
263
- };