@mx-cartographer/experiences 9.0.2 → 9.0.4-alpha.mm0
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 +11 -0
- package/dist/{Account-BaJmiJAG.mjs → Account-DR7Plrqy.mjs} +10 -10
- package/dist/AccountDetailsDrawer-C8oJP3J4.mjs +921 -0
- package/dist/AccountDetailsHeader-ByGNPZpO.mjs +228 -0
- package/dist/{AccountUtils-T5_Odvos.mjs → AccountUtils-B8ZzWI-d.mjs} +3 -3
- package/dist/{Analytics-CzGzz_sE.mjs → Analytics-WeZYytR0.mjs} +3 -0
- package/dist/BeatMaterialIcon-1KOfRZrA.mjs +26 -0
- package/dist/{CategorySelectorDrawer-8soGrhB8.mjs → CategorySelectorDrawer-BArJC27L.mjs} +1 -1
- package/dist/Connect-BH0Pt6zc.mjs +42 -0
- package/dist/{ConnectCard-CCep7Zqe.mjs → ConnectCard-Dwfgv24k.mjs} +1 -1
- package/dist/{ConnectDrawer-Cnjr3Ddg.mjs → ConnectDrawer-DytyIhaF.mjs} +8 -9
- package/dist/{ConnectionsDrawer-CtfPXk0M.mjs → ConnectionsDrawer-BHJPKXYF.mjs} +8 -9
- package/dist/{CurrencyInput-adTIRtL3.mjs → CurrencyInput-DaGEQaLW.mjs} +1 -1
- package/dist/DateUtil-CzBmbjmA.mjs +74 -0
- package/dist/{DebtUtils-DD3186U-.mjs → DebtUtils-i4pI2Uoe.mjs} +6 -6
- package/dist/{EmbeddedCard-DPwJjqMH.mjs → EmbeddedCard-CQpbZrmP.mjs} +4 -4
- package/dist/{Error-Dogaw2jO.mjs → Error-Dtw6yxkf.mjs} +1 -1
- package/dist/{ExportCsvAction-Bw02ZJEj.mjs → ExportCsvAction-bovG-NJr.mjs} +2 -2
- package/dist/{GlobalAccountFilter-7Cg2-9A5.mjs → GlobalAccountFilter-CYqzqmAd.mjs} +10 -10
- package/dist/{Help-DJ8PrVHX.mjs → Help-5klKVqkX.mjs} +2 -2
- package/dist/{LineChart-CejWS_rh.mjs → LineChart-CUfiH86G.mjs} +1 -1
- package/dist/{ListItemAction-CzZ8s39Z.mjs → ListItemAction-BqUCLj_w.mjs} +1 -1
- package/dist/{ListItemWrapper-B5r-YQQ_.mjs → ListItemWrapper-BHIbqx7E.mjs} +3 -3
- package/dist/ManageIncome-Cz6hvpdA.mjs +902 -0
- package/dist/{MicroWidgetContainer-CfKdQfhi.mjs → MicroWidgetContainer-B2NnKBgW.mjs} +1 -1
- package/dist/{MiniWidgetContainer-BdPiUU-u.mjs → MiniWidgetContainer-Bmv_WeUd.mjs} +1 -1
- package/dist/{NetWorthUtils-DilGN1nW.mjs → NetWorthUtils-DfSH3z70.mjs} +2 -2
- package/dist/{NotificationSettings-B4JA5IKE.mjs → NotificationSettings-Ci89BBRI.mjs} +4 -4
- package/dist/{OriginalBalanceAction-BybTXDtO.mjs → OriginalBalanceAction-YrvxBYAl.mjs} +3 -3
- package/dist/{RecurringSettings-D2xbNb67.mjs → RecurringSettings-ClYjsmPz.mjs} +4 -4
- package/dist/RecurringTransactionsUtil-zOxq5pzY.mjs +298 -0
- package/dist/Select-CSpkK5cR.mjs +61 -0
- package/dist/SpendingData-Fii_xATx.mjs +53 -0
- package/dist/{SpendingLegend-5Ct_FZ8o.mjs → SpendingLegend-Bn3DzGyK.mjs} +1 -1
- package/dist/TabContentContainer-B0eYJP5p.mjs +48 -0
- package/dist/{TransactionDetails-DctXr07p.mjs → TransactionDetails-DRN0GIaZ.mjs} +6 -6
- package/dist/{UserStore-CRpKQjpP.mjs → UserStore-DzWku3t0.mjs} +81 -40
- package/dist/{ViewMoreMicroCard-BD_MNc2z.mjs → ViewMoreMicroCard-Dxghxphh.mjs} +211 -231
- package/dist/{WidgetContainer-CmbU4CBH.mjs → WidgetContainer-D-LzIKFb.mjs} +3 -3
- package/dist/accounts/components/detailsdrawer/Accounts/AccountDetailsDrawer.d.ts +6 -0
- package/dist/accounts/index.d.ts +1 -0
- package/dist/accounts/index.es.js +220 -1035
- package/dist/analytics/index.es.js +8 -8
- package/dist/budgets/index.es.js +11 -11
- package/dist/cashflow/index.es.js +41 -41
- package/dist/categories/index.es.js +1 -1
- package/dist/common/components/DataRow.d.ts +1 -0
- package/dist/common/constants/Analytics.d.ts +3 -0
- package/dist/common/index.es.js +82 -83
- package/dist/core/index.es.js +8 -8
- package/dist/core/stores/RecurringTransactionsStore.d.ts +27 -1
- package/dist/core/types/localization/RecurringCopy.d.ts +14 -1
- package/dist/core/utils/DateUtil.d.ts +2 -0
- package/dist/core/utils/RecurringTransactionsUtil.d.ts +2 -1
- package/dist/dashboard/index.es.js +4 -4
- package/dist/debts/index.es.js +73 -73
- package/dist/finstrong/index.es.js +17 -17
- package/dist/goals/index.es.js +22 -23
- package/dist/help/index.es.js +4 -4
- package/dist/{hooks-BaO_gOI6.mjs → hooks-97sNJ_lf.mjs} +9 -9
- package/dist/insights/index.es.js +4 -4
- package/dist/investments/index.es.js +6 -6
- package/dist/merchants/index.es.js +1 -1
- package/dist/microinsights/index.es.js +12 -11
- package/dist/networth/index.es.js +9 -9
- package/dist/notifications/index.es.js +9 -9
- package/dist/recurringtransactions/components/RecurringTransactionDetailsDrawer.d.ts +3 -0
- package/dist/recurringtransactions/components/RecurringTransactionList.d.ts +11 -0
- package/dist/recurringtransactions/components/UpcomingRecurrenceCard.d.ts +6 -0
- package/dist/recurringtransactions/components/actions/LinkTransactionDrawer.d.ts +10 -0
- package/dist/recurringtransactions/components/actions/MarkAsPaidDialog.d.ts +7 -0
- package/dist/recurringtransactions/components/actions/MarkAsUnpaidDialog.d.ts +7 -0
- package/dist/recurringtransactions/index.es.js +402 -376
- package/dist/settings/index.es.js +7 -7
- package/dist/spending/index.es.js +8 -8
- package/dist/transactions/index.es.js +12 -12
- package/dist/trends/index.es.js +14 -14
- package/dist/useAccountDisplayName-BsiXA0qf.mjs +23 -0
- package/dist/{useInsightsEnabled-DaNLPmUU.mjs → useInsightsEnabled-D5Sdm0TJ.mjs} +1 -1
- package/dist/{useWidgetLoadTimer-CJb-RELP.mjs → useWidgetLoadTimer-B0tB-yzL.mjs} +1 -1
- package/package.json +1 -1
- package/dist/Account-BxHMlV9R.mjs +0 -30
- package/dist/AccountDetailsHeader-DIysk_4w.mjs +0 -95
- package/dist/AccountDisplayName-CO7z3v99.mjs +0 -11
- package/dist/AccountFields-mwJ8NXsX.mjs +0 -141
- package/dist/AccountListItem-BDXHs4tV.mjs +0 -94
- package/dist/Accounts-CseLC3lL.mjs +0 -5
- package/dist/Connect-Dk6GZEsA.mjs +0 -39
- package/dist/DateUtil-Bhq59ZVg.mjs +0 -58
- package/dist/ManageIncome-D1yBODQi.mjs +0 -595
- package/dist/RecurringTransactionsUtil-B3rLEx_g.mjs +0 -253
- package/dist/Select-BFt-HD-L.mjs +0 -55
- package/dist/SpendingData-PKlh8caU.mjs +0 -53
- package/dist/TabContentContainer-CnMXkVqr.mjs +0 -21
- package/dist/useAccountDisplayName-CFa_MrS6.mjs +0 -15
|
@@ -6,129 +6,131 @@ import { endOfToday as J } from "date-fns/endOfToday";
|
|
|
6
6
|
import { startOfMonth as k } from "date-fns/startOfMonth";
|
|
7
7
|
import { startOfToday as Q } from "date-fns/startOfToday";
|
|
8
8
|
import { subDays as ee } from "date-fns/subDays";
|
|
9
|
-
import
|
|
10
|
-
import
|
|
11
|
-
import {
|
|
12
|
-
import {
|
|
13
|
-
import {
|
|
9
|
+
import Be from "@mui/material/Alert";
|
|
10
|
+
import $e from "@mui/material/Snackbar";
|
|
11
|
+
import { R as De } from "../RecurringSettings-ClYjsmPz.mjs";
|
|
12
|
+
import { M as Xn } from "../RecurringSettings-ClYjsmPz.mjs";
|
|
13
|
+
import { addMonths as Fe } from "date-fns/addMonths";
|
|
14
|
+
import { subMonths as Ue } from "date-fns/subMonths";
|
|
15
|
+
import { isBefore as Ye } from "date-fns/isBefore";
|
|
14
16
|
import q from "@mui/material/Grid";
|
|
15
17
|
import ge from "@mui/material/IconButton";
|
|
16
|
-
import
|
|
18
|
+
import d from "@mui/material/Stack";
|
|
17
19
|
import he from "@mui/material/Tab";
|
|
18
|
-
import
|
|
19
|
-
import { Cancel as
|
|
20
|
-
import { Text as h, MerchantLogo as te, InstitutionLogo as
|
|
21
|
-
import { g as
|
|
20
|
+
import je from "@mui/material/Tabs";
|
|
21
|
+
import { Cancel as _e, CheckCircle as Se, Schedule as Ke, MonetizationOn as Ve, ChevronLeft as qe, ChevronRight as Ze, CurrencyExchange as Xe } from "@mxenabled/mx-icons";
|
|
22
|
+
import { Text as h, MerchantLogo as te, InstitutionLogo as Je, H3 as Qe, H2 as et, P as Z } from "@mxenabled/mxui";
|
|
23
|
+
import { g as tt, L as O, b as N } from "../Localization-DnoVyBNK.mjs";
|
|
22
24
|
import { getWeeksInMonth as fe } from "date-fns/getWeeksInMonth";
|
|
23
|
-
import { enCA as
|
|
25
|
+
import { enCA as nt } from "date-fns/locale/en-CA";
|
|
24
26
|
import { enUS as xe } from "date-fns/locale/en-US";
|
|
25
|
-
import { es as
|
|
26
|
-
import { fr as
|
|
27
|
-
import { frCA as
|
|
27
|
+
import { es as rt } from "date-fns/locale/es";
|
|
28
|
+
import { fr as it } from "date-fns/locale/fr";
|
|
29
|
+
import { frCA as ot } from "date-fns/locale/fr-CA";
|
|
28
30
|
import { useTheme as ne } from "@mui/material/styles";
|
|
29
|
-
import { AdapterDateFns as
|
|
30
|
-
import { DateCalendar as
|
|
31
|
-
import { LocalizationProvider as
|
|
32
|
-
import { isSameDay as
|
|
33
|
-
import
|
|
34
|
-
import { PickersDay as
|
|
35
|
-
import { I as
|
|
36
|
-
import { u as
|
|
37
|
-
import { b as
|
|
38
|
-
import { f as
|
|
31
|
+
import { AdapterDateFns as at } from "@mui/x-date-pickers/AdapterDateFnsV3";
|
|
32
|
+
import { DateCalendar as st } from "@mui/x-date-pickers/DateCalendar";
|
|
33
|
+
import { LocalizationProvider as ct } from "@mui/x-date-pickers/LocalizationProvider";
|
|
34
|
+
import { isSameDay as lt } from "date-fns/isSameDay";
|
|
35
|
+
import dt from "@mui/material/Badge";
|
|
36
|
+
import { PickersDay as ut } from "@mui/x-date-pickers/PickersDay";
|
|
37
|
+
import { I as F } from "../IconBacking-DgT8DCeh.mjs";
|
|
38
|
+
import { u as b, a as U, h as _, f as Y, D as we, g as re } from "../hooks-97sNJ_lf.mjs";
|
|
39
|
+
import { b as E, a as D, g as be, e as mt, R as pt } from "../RecurringTransactionsUtil-zOxq5pzY.mjs";
|
|
40
|
+
import { f as I, D as M } from "../DateFormats-HudZ3Bjs.mjs";
|
|
39
41
|
import { T as W } from "../Sizes-DISGrlUg.mjs";
|
|
40
|
-
import { A as
|
|
41
|
-
import
|
|
42
|
+
import { A as v } from "../Analytics-WeZYytR0.mjs";
|
|
43
|
+
import gt from "@mui/material/Button";
|
|
42
44
|
import X from "@mui/material/Divider";
|
|
43
|
-
import
|
|
45
|
+
import ye from "@mui/material/List";
|
|
44
46
|
import Ie from "@mui/material/ListItem";
|
|
45
|
-
import
|
|
46
|
-
import
|
|
47
|
-
import
|
|
48
|
-
import
|
|
49
|
-
import { f as
|
|
50
|
-
import
|
|
51
|
-
import { c as jn, M as Kn, S as Vn } from "../ManageIncome-D1yBODQi.mjs";
|
|
52
|
-
import { D as ie } from "../Drawer-BXqqBMxg.mjs";
|
|
53
|
-
import O from "@mui/material/Box";
|
|
47
|
+
import ht from "@mui/material/ListSubheader";
|
|
48
|
+
import ft from "@mui/material/ListItemAvatar";
|
|
49
|
+
import xt from "@mui/material/ListItemButton";
|
|
50
|
+
import bt from "@mui/material/ListItemText";
|
|
51
|
+
import { f as L } from "../NumberFormatting--XMeeBfr.mjs";
|
|
52
|
+
import G from "@mui/material/Box";
|
|
54
53
|
import { u as Me } from "../useScreenSize-mWpmnh5w.mjs";
|
|
55
|
-
import { S as
|
|
56
|
-
import {
|
|
57
|
-
import {
|
|
54
|
+
import { S as ve } from "../StatusBar-CPfSXe80.mjs";
|
|
55
|
+
import { d as yt } from "../ManageIncome-Cz6hvpdA.mjs";
|
|
56
|
+
import { c as Qn, M as er, S as tr } from "../ManageIncome-Cz6hvpdA.mjs";
|
|
57
|
+
import { D as ie } from "../Drawer-BXqqBMxg.mjs";
|
|
58
|
+
import { S as Le } from "../SkeletonLoader-BaNboJjD.mjs";
|
|
59
|
+
import { u as oe } from "../useWidgetLoadTimer-B0tB-yzL.mjs";
|
|
58
60
|
import { L as ae } from "../Loader-CxeBwuPG.mjs";
|
|
59
|
-
import { W as
|
|
60
|
-
import { M as
|
|
61
|
-
import { u as
|
|
62
|
-
import { M as
|
|
63
|
-
const
|
|
61
|
+
import { W as Ct } from "../WidgetContainer-D-LzIKFb.mjs";
|
|
62
|
+
import { M as Rt } from "../MiniWidgetContainer-Bmv_WeUd.mjs";
|
|
63
|
+
import { u as Tt } from "../useDimensions-CeDR9V8N.mjs";
|
|
64
|
+
import { M as Dt } from "../MicroWidgetContainer-B2NnKBgW.mjs";
|
|
65
|
+
const j = {
|
|
64
66
|
gridRow: 1,
|
|
65
67
|
gridColumn: 1,
|
|
66
68
|
zIndex: 2
|
|
67
|
-
},
|
|
68
|
-
|
|
69
|
+
}, K = (t) => t ? { margin: "0 0 -6px -4px" } : void 0, se = ({ isOffset: t = !1, size: n = 16 }) => /* @__PURE__ */ e(
|
|
70
|
+
F,
|
|
69
71
|
{
|
|
70
72
|
backingSx: { backgroundColor: "background.paper" },
|
|
71
73
|
size: n,
|
|
72
|
-
sx: { ...
|
|
73
|
-
children: /* @__PURE__ */ e(
|
|
74
|
+
sx: { ...K(t) },
|
|
75
|
+
children: /* @__PURE__ */ e(Ke, { color: "primary", filled: !0, sx: { fontSize: n, ...j } })
|
|
74
76
|
}
|
|
75
77
|
), ce = ({ isOffset: t = !1, size: n = 16 }) => /* @__PURE__ */ e(
|
|
76
|
-
|
|
78
|
+
F,
|
|
77
79
|
{
|
|
78
80
|
backingSx: { backgroundColor: "background.paper" },
|
|
79
81
|
size: n,
|
|
80
|
-
sx: { ...
|
|
82
|
+
sx: { ...K(t) },
|
|
81
83
|
children: /* @__PURE__ */ e(
|
|
82
|
-
|
|
84
|
+
Ve,
|
|
83
85
|
{
|
|
84
86
|
filled: !0,
|
|
85
|
-
sx: { color: "categories.income", fontSize: n, ...
|
|
87
|
+
sx: { color: "categories.income", fontSize: n, ...j }
|
|
86
88
|
}
|
|
87
89
|
)
|
|
88
90
|
}
|
|
89
91
|
), le = ({ isOffset: t = !1, size: n = 16 }) => /* @__PURE__ */ e(
|
|
90
|
-
|
|
92
|
+
F,
|
|
91
93
|
{
|
|
92
94
|
backingSx: { backgroundColor: "background.paper" },
|
|
93
95
|
size: n,
|
|
94
|
-
sx: { ...
|
|
95
|
-
children: /* @__PURE__ */ e(
|
|
96
|
+
sx: { ...K(t) },
|
|
97
|
+
children: /* @__PURE__ */ e(_e, { color: "error", filled: !0, sx: { fontSize: n, ...j } })
|
|
96
98
|
}
|
|
97
99
|
), de = ({ isOffset: t = !1, size: n = 16 }) => /* @__PURE__ */ e(
|
|
98
|
-
|
|
100
|
+
F,
|
|
99
101
|
{
|
|
100
102
|
backingSx: { backgroundColor: "background.paper" },
|
|
101
103
|
size: n,
|
|
102
|
-
sx: { ...
|
|
103
|
-
children: /* @__PURE__ */ e(Se, { color: "success", filled: !0, sx: { fontSize: n, ...
|
|
104
|
+
sx: { ...K(t) },
|
|
105
|
+
children: /* @__PURE__ */ e(Se, { color: "success", filled: !0, sx: { fontSize: n, ...j } })
|
|
104
106
|
}
|
|
105
|
-
),
|
|
107
|
+
), _t = R(
|
|
106
108
|
({ day: t, outsideCurrentMonth: n, ...r }) => {
|
|
107
|
-
const { recurring: i } =
|
|
109
|
+
const { recurring: i } = b(), { selectedAccountGuids: o } = U(), { recurrences: c, setSelectedDay: u } = _(), a = x.useMemo(
|
|
108
110
|
() => c.filter((f) => o.includes(f.accountGuid)),
|
|
109
111
|
[o, c]
|
|
110
112
|
).filter(
|
|
111
|
-
(f) =>
|
|
112
|
-
),
|
|
113
|
-
(f) => f.type !==
|
|
114
|
-
),
|
|
115
|
-
(f) => f.type !==
|
|
113
|
+
(f) => lt(f.occurredOnDate || f.expectedDate, t)
|
|
114
|
+
), l = a.some(
|
|
115
|
+
(f) => f.type !== E.Income && f.status === D.Upcoming
|
|
116
|
+
), p = a.some(
|
|
117
|
+
(f) => f.type !== E.Income && f.status === D.Missed
|
|
116
118
|
), g = a.some(
|
|
117
|
-
(f) => f.type !==
|
|
118
|
-
),
|
|
119
|
+
(f) => f.type !== E.Income && f.status === D.Paid
|
|
120
|
+
), y = a.some((f) => f.type === E.Income), C = (l ? 1 : 0) + (p ? 1 : 0) + (g ? 1 : 0) + (y ? 1 : 0), S = [
|
|
119
121
|
g && i.paid,
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
].filter(Boolean),
|
|
122
|
+
p && i.missed,
|
|
123
|
+
l && i.upcoming,
|
|
124
|
+
y && i.income
|
|
125
|
+
].filter(Boolean), A = S.length > 0 ? `${I(t, M.MONTH_DAY_YEAR)}, ${S.join(", ")}` : I(t, M.MONTH_DAY_YEAR);
|
|
124
126
|
return /* @__PURE__ */ e(
|
|
125
|
-
|
|
127
|
+
dt,
|
|
126
128
|
{
|
|
127
129
|
badgeContent: a.length > 0 && /* @__PURE__ */ s($, { children: [
|
|
128
|
-
|
|
130
|
+
p && /* @__PURE__ */ e(le, { isOffset: !0 }),
|
|
129
131
|
g && /* @__PURE__ */ e(de, { isOffset: !0 }),
|
|
130
|
-
|
|
131
|
-
|
|
132
|
+
l && /* @__PURE__ */ e(se, { isOffset: !0 }),
|
|
133
|
+
y && /* @__PURE__ */ e(ce, { isOffset: !0 })
|
|
132
134
|
] }),
|
|
133
135
|
overlap: "circular",
|
|
134
136
|
sx: {
|
|
@@ -139,9 +141,9 @@ const Y = {
|
|
|
139
141
|
}
|
|
140
142
|
},
|
|
141
143
|
children: /* @__PURE__ */ e(
|
|
142
|
-
|
|
144
|
+
ut,
|
|
143
145
|
{
|
|
144
|
-
"aria-label":
|
|
146
|
+
"aria-label": A,
|
|
145
147
|
day: t,
|
|
146
148
|
onClick: () => u(t),
|
|
147
149
|
outsideCurrentMonth: n,
|
|
@@ -158,13 +160,13 @@ const Y = {
|
|
|
158
160
|
}
|
|
159
161
|
);
|
|
160
162
|
}
|
|
161
|
-
),
|
|
163
|
+
), B = ({ icon: t, label: n }) => /* @__PURE__ */ s(d, { alignItems: "center", flexDirection: "row", sx: { gap: 6 }, children: [
|
|
162
164
|
/* @__PURE__ */ e(t, {}),
|
|
163
165
|
/* @__PURE__ */ e(h, { variant: "caption", children: n })
|
|
164
|
-
] }),
|
|
165
|
-
const { recurring: t } =
|
|
166
|
+
] }), St = R(() => {
|
|
167
|
+
const { recurring: t } = b();
|
|
166
168
|
return /* @__PURE__ */ s(
|
|
167
|
-
|
|
169
|
+
d,
|
|
168
170
|
{
|
|
169
171
|
alignItems: "center",
|
|
170
172
|
"aria-hidden": !0,
|
|
@@ -173,44 +175,44 @@ const Y = {
|
|
|
173
175
|
justifyContent: "center",
|
|
174
176
|
mt: 12,
|
|
175
177
|
children: [
|
|
176
|
-
/* @__PURE__ */ e(
|
|
177
|
-
/* @__PURE__ */ e(
|
|
178
|
-
/* @__PURE__ */ e(
|
|
179
|
-
/* @__PURE__ */ e(
|
|
178
|
+
/* @__PURE__ */ e(B, { icon: se, label: t.expense }),
|
|
179
|
+
/* @__PURE__ */ e(B, { icon: ce, label: t.income }),
|
|
180
|
+
/* @__PURE__ */ e(B, { icon: le, label: t.missed }),
|
|
181
|
+
/* @__PURE__ */ e(B, { icon: de, label: t.paid })
|
|
180
182
|
]
|
|
181
183
|
}
|
|
182
184
|
);
|
|
183
|
-
}),
|
|
184
|
-
const t =
|
|
185
|
+
}), Ce = 58, wt = () => {
|
|
186
|
+
const t = tt();
|
|
185
187
|
return {
|
|
186
|
-
[
|
|
187
|
-
[
|
|
188
|
-
[
|
|
189
|
-
[
|
|
190
|
-
[
|
|
188
|
+
[O.EN_US]: xe,
|
|
189
|
+
[O.EN_CA]: nt,
|
|
190
|
+
[O.FR]: it,
|
|
191
|
+
[O.FR_CA]: ot,
|
|
192
|
+
[O.ES]: rt
|
|
191
193
|
}[t] || xe;
|
|
192
194
|
}, Ae = R(() => {
|
|
193
|
-
const t = ne(), { onEvent: n } =
|
|
194
|
-
fe(/* @__PURE__ */ new Date()) * W +
|
|
195
|
-
),
|
|
196
|
-
u(fe(
|
|
197
|
-
start: k(
|
|
198
|
-
end: z(
|
|
199
|
-
}), a(
|
|
200
|
-
}, a = (
|
|
201
|
-
|
|
195
|
+
const t = ne(), { onEvent: n } = Y(), { recurring: r } = b(), { selectedDay: i, setDateRange: o } = _(), [c, u] = x.useState(
|
|
196
|
+
fe(/* @__PURE__ */ new Date()) * W + Ce
|
|
197
|
+
), m = (p) => {
|
|
198
|
+
u(fe(p) * W + Ce), o({
|
|
199
|
+
start: k(p),
|
|
200
|
+
end: z(p)
|
|
201
|
+
}), a(p), n(v.RECURRING_TRANSACTIONS_CLICK_CALENDAR_RIGHT);
|
|
202
|
+
}, a = (p) => {
|
|
203
|
+
p && requestAnimationFrame(() => {
|
|
202
204
|
const g = document.getElementById("recurrence-list");
|
|
203
205
|
g?.setAttribute("tabindex", "-1"), g?.focus();
|
|
204
206
|
});
|
|
205
|
-
},
|
|
206
|
-
|
|
207
|
+
}, l = /* @__PURE__ */ e(
|
|
208
|
+
st,
|
|
207
209
|
{
|
|
208
210
|
minDate: k(/* @__PURE__ */ new Date()),
|
|
209
211
|
onChange: a,
|
|
210
|
-
onMonthChange:
|
|
212
|
+
onMonthChange: m,
|
|
211
213
|
showDaysOutsideCurrentMonth: !0,
|
|
212
214
|
slots: {
|
|
213
|
-
day:
|
|
215
|
+
day: _t
|
|
214
216
|
},
|
|
215
217
|
sx: {
|
|
216
218
|
"& .MuiPickersArrowSwitcher-button": {
|
|
@@ -259,14 +261,14 @@ const Y = {
|
|
|
259
261
|
views: ["day"]
|
|
260
262
|
}
|
|
261
263
|
);
|
|
262
|
-
return /* @__PURE__ */ e(
|
|
263
|
-
i &&
|
|
264
|
-
!i &&
|
|
264
|
+
return /* @__PURE__ */ e(d, { "aria-labelledby": "calendar-label", justifyContent: "center", role: "group", children: /* @__PURE__ */ s(ct, { adapterLocale: wt(), dateAdapter: at, children: [
|
|
265
|
+
i && l,
|
|
266
|
+
!i && l,
|
|
265
267
|
/* @__PURE__ */ e(h, { id: "calendar-label", sx: { alignSelf: "center" }, variant: "body2", children: r.calendar_tooltip }),
|
|
266
|
-
/* @__PURE__ */ e(
|
|
268
|
+
/* @__PURE__ */ e(St, {})
|
|
267
269
|
] }) });
|
|
268
|
-
}),
|
|
269
|
-
if (t.type ===
|
|
270
|
+
}), It = (t) => {
|
|
271
|
+
if (t.type === E.Income)
|
|
270
272
|
return /* @__PURE__ */ e(ce, {});
|
|
271
273
|
switch (t.status) {
|
|
272
274
|
case D.Missed:
|
|
@@ -276,25 +278,25 @@ const Y = {
|
|
|
276
278
|
default:
|
|
277
279
|
return /* @__PURE__ */ e(se, {});
|
|
278
280
|
}
|
|
279
|
-
},
|
|
281
|
+
}, Mt = (t, n) => {
|
|
280
282
|
switch (t.status) {
|
|
281
283
|
case D.Paid:
|
|
282
284
|
return t.expectedDate ? N(
|
|
283
285
|
n.paid_on,
|
|
284
|
-
|
|
286
|
+
I(
|
|
285
287
|
t.occurredOnDate || t.expectedDate,
|
|
286
|
-
|
|
288
|
+
M.MONTH_DAY
|
|
287
289
|
)
|
|
288
290
|
) : n.paid;
|
|
289
291
|
case D.Missed:
|
|
290
292
|
return N(
|
|
291
293
|
n.missed_on,
|
|
292
|
-
|
|
294
|
+
I(t.expectedDate, M.MONTH_DAY)
|
|
293
295
|
);
|
|
294
296
|
case D.Upcoming:
|
|
295
297
|
return N(
|
|
296
298
|
n.upcoming_on,
|
|
297
|
-
|
|
299
|
+
I(t.expectedDate, M.MONTH_DAY)
|
|
298
300
|
);
|
|
299
301
|
default:
|
|
300
302
|
return n.unknown;
|
|
@@ -306,92 +308,74 @@ const Y = {
|
|
|
306
308
|
},
|
|
307
309
|
showOrdinal: i = !1
|
|
308
310
|
}) => {
|
|
309
|
-
const { recurring: o } =
|
|
310
|
-
() => c.find((
|
|
311
|
+
const { recurring: o } = b(), { detailedRepeatingTransactions: c } = _(), u = x.useMemo(
|
|
312
|
+
() => c.find((C) => C.guid === t.repeatingTransactionGuid),
|
|
311
313
|
[t, c]
|
|
312
|
-
),
|
|
313
|
-
let
|
|
314
|
-
return
|
|
315
|
-
/* @__PURE__ */
|
|
316
|
-
|
|
317
|
-
|
|
318
|
-
|
|
319
|
-
|
|
320
|
-
|
|
321
|
-
|
|
322
|
-
|
|
323
|
-
|
|
324
|
-
|
|
325
|
-
|
|
326
|
-
|
|
327
|
-
|
|
328
|
-
|
|
329
|
-
|
|
330
|
-
|
|
331
|
-
|
|
332
|
-
children: [
|
|
333
|
-
/* @__PURE__ */
|
|
334
|
-
|
|
335
|
-
|
|
336
|
-
|
|
337
|
-
|
|
338
|
-
|
|
339
|
-
|
|
340
|
-
Ve,
|
|
341
|
-
{
|
|
342
|
-
alt: `${t.institutionName} institution logo`,
|
|
343
|
-
institutionGuid: t.institutionGuid,
|
|
344
|
-
size: 12
|
|
345
|
-
}
|
|
346
|
-
),
|
|
347
|
-
/* @__PURE__ */ e(h, { sx: { maxWidth: 250 }, variant: "caption", children: t.institutionName })
|
|
348
|
-
] }) })
|
|
349
|
-
] }),
|
|
350
|
-
/* @__PURE__ */ s(l, { alignItems: "flex-end", width: "100%", children: [
|
|
351
|
-
/* @__PURE__ */ s(h, { bold: !0, color: d ? "success.main" : "text.primary", variant: "body1", children: [
|
|
352
|
-
d ? "+" : "",
|
|
353
|
-
E(t.amount, "0,0.00")
|
|
354
|
-
] }),
|
|
355
|
-
!n && /* @__PURE__ */ s(
|
|
356
|
-
l,
|
|
314
|
+
), m = t.type === E.Income, a = t.status === D.Paid, l = t.status === D.Missed, p = t.status === D.Upcoming;
|
|
315
|
+
let g = o.paid?.toLowerCase();
|
|
316
|
+
return l ? g = o.missed?.toLowerCase() : p && (g = i ? be(o, u || {}, !0) : be(o, u || {}, !1)), //TODO: implement common/components/ListItemRow.tsx
|
|
317
|
+
/* @__PURE__ */ e(Ie, { disableGutters: !0, disablePadding: !0, children: /* @__PURE__ */ s(xt, { onClick: () => {
|
|
318
|
+
r(t);
|
|
319
|
+
}, children: [
|
|
320
|
+
/* @__PURE__ */ e(ft, { children: /* @__PURE__ */ e(
|
|
321
|
+
te,
|
|
322
|
+
{
|
|
323
|
+
categoryGuid: t.categoryGuid,
|
|
324
|
+
merchantGuid: t.merchantGuid
|
|
325
|
+
}
|
|
326
|
+
) }),
|
|
327
|
+
/* @__PURE__ */ e(bt, { children: /* @__PURE__ */ s(
|
|
328
|
+
d,
|
|
329
|
+
{
|
|
330
|
+
direction: "row",
|
|
331
|
+
gap: 4,
|
|
332
|
+
sx: { justifyContent: "space-between", textOverflow: "ellipsis", textWrap: "nowrap" },
|
|
333
|
+
children: [
|
|
334
|
+
/* @__PURE__ */ s(d, { direction: "column", width: "50%", children: [
|
|
335
|
+
/* @__PURE__ */ e(h, { bold: !0, variant: "body1", children: t.name }),
|
|
336
|
+
/* @__PURE__ */ e(d, { alignItems: "center", direction: "row", gap: 6, children: n ? /* @__PURE__ */ s(d, { direction: "row", gap: 4, children: [
|
|
337
|
+
It(t),
|
|
338
|
+
/* @__PURE__ */ e(h, { variant: "caption", children: Mt(t, o) })
|
|
339
|
+
] }) : /* @__PURE__ */ s($, { children: [
|
|
340
|
+
t.institutionGuid && /* @__PURE__ */ e(
|
|
341
|
+
Je,
|
|
357
342
|
{
|
|
358
|
-
|
|
359
|
-
|
|
360
|
-
|
|
361
|
-
gap: 6,
|
|
362
|
-
justifyContent: "flex-end",
|
|
363
|
-
textTransform: "uppercase",
|
|
364
|
-
width: "100%"
|
|
365
|
-
},
|
|
366
|
-
children: [
|
|
367
|
-
m && /* @__PURE__ */ e(Se, { color: "success", filled: !0, size: 12 }),
|
|
368
|
-
g && /* @__PURE__ */ e(Te, { color: "error", filled: !0, size: 12 }),
|
|
369
|
-
/* @__PURE__ */ e(h, { bold: !0, color: "text.secondary", variant: "caption", children: C })
|
|
370
|
-
]
|
|
343
|
+
alt: `${t.institutionName} institution logo`,
|
|
344
|
+
institutionGuid: t.institutionGuid,
|
|
345
|
+
size: 12
|
|
371
346
|
}
|
|
372
|
-
)
|
|
373
|
-
|
|
374
|
-
|
|
375
|
-
|
|
376
|
-
|
|
377
|
-
|
|
378
|
-
|
|
379
|
-
|
|
380
|
-
|
|
381
|
-
|
|
382
|
-
|
|
383
|
-
|
|
384
|
-
|
|
385
|
-
|
|
386
|
-
|
|
387
|
-
|
|
388
|
-
|
|
389
|
-
|
|
390
|
-
|
|
391
|
-
|
|
347
|
+
),
|
|
348
|
+
/* @__PURE__ */ e(h, { sx: { maxWidth: 250 }, variant: "caption", children: t.institutionName })
|
|
349
|
+
] }) })
|
|
350
|
+
] }),
|
|
351
|
+
/* @__PURE__ */ s(d, { alignItems: "flex-end", width: "100%", children: [
|
|
352
|
+
/* @__PURE__ */ s(h, { bold: !0, color: m ? "success.main" : "text.primary", variant: "body1", children: [
|
|
353
|
+
m ? "+" : "",
|
|
354
|
+
L(t.amount, "0,0.00")
|
|
355
|
+
] }),
|
|
356
|
+
!n && /* @__PURE__ */ s(
|
|
357
|
+
d,
|
|
358
|
+
{
|
|
359
|
+
direction: "row",
|
|
360
|
+
sx: {
|
|
361
|
+
alignItems: "center",
|
|
362
|
+
gap: 6,
|
|
363
|
+
justifyContent: "flex-end",
|
|
364
|
+
textTransform: "uppercase",
|
|
365
|
+
width: "100%"
|
|
366
|
+
},
|
|
367
|
+
children: [
|
|
368
|
+
a && /* @__PURE__ */ e(Se, { color: "success", filled: !0, size: 12 }),
|
|
369
|
+
l && /* @__PURE__ */ e(_e, { color: "error", filled: !0, size: 12 }),
|
|
370
|
+
/* @__PURE__ */ e(h, { bold: !0, color: "text.secondary", variant: "caption", children: g })
|
|
371
|
+
]
|
|
372
|
+
}
|
|
373
|
+
)
|
|
374
|
+
] })
|
|
375
|
+
]
|
|
392
376
|
}
|
|
393
|
-
)
|
|
394
|
-
] });
|
|
377
|
+
) })
|
|
378
|
+
] }) });
|
|
395
379
|
}, P = R(
|
|
396
380
|
({
|
|
397
381
|
recurrences: t,
|
|
@@ -401,10 +385,10 @@ const Y = {
|
|
|
401
385
|
sx: o = {},
|
|
402
386
|
title: c
|
|
403
387
|
}) => {
|
|
404
|
-
const { recurring: u } =
|
|
405
|
-
return /* @__PURE__ */ s(
|
|
388
|
+
const { recurring: u } = b(), m = x.useMemo(() => mt(t), [t]);
|
|
389
|
+
return /* @__PURE__ */ s(d, { id: "recurrence-list", sx: { gap: 8, mt: 4, ...o }, "tab-index": -1, children: [
|
|
406
390
|
c && /* @__PURE__ */ s(
|
|
407
|
-
|
|
391
|
+
d,
|
|
408
392
|
{
|
|
409
393
|
sx: {
|
|
410
394
|
alignItems: "center",
|
|
@@ -413,12 +397,12 @@ const Y = {
|
|
|
413
397
|
px: 24
|
|
414
398
|
},
|
|
415
399
|
children: [
|
|
416
|
-
/* @__PURE__ */ e(
|
|
417
|
-
r && /* @__PURE__ */ e(
|
|
400
|
+
/* @__PURE__ */ e(Qe, { bold: !0, variant: "body1", children: c }),
|
|
401
|
+
r && /* @__PURE__ */ e(gt, { onClick: r, size: "small", variant: "text", children: u.reset })
|
|
418
402
|
]
|
|
419
403
|
}
|
|
420
404
|
),
|
|
421
|
-
t.length === 0 ? /* @__PURE__ */ e(h, { fontStyle: "italic", sx: { py: 24, textAlign: "center" }, children: u.no_activities }) : /* @__PURE__ */ e(
|
|
405
|
+
t.length === 0 ? /* @__PURE__ */ e(h, { fontStyle: "italic", sx: { py: 24, textAlign: "center" }, children: u.no_activities }) : /* @__PURE__ */ e(ye, { children: n ? t.map((a, l) => /* @__PURE__ */ s(x.Fragment, { children: [
|
|
422
406
|
/* @__PURE__ */ e(
|
|
423
407
|
Re,
|
|
424
408
|
{
|
|
@@ -428,91 +412,110 @@ const Y = {
|
|
|
428
412
|
}
|
|
429
413
|
),
|
|
430
414
|
/* @__PURE__ */ e(X, { sx: { mx: 24 } })
|
|
431
|
-
] }, `recurrence-${
|
|
415
|
+
] }, `recurrence-${l}`)) : m.map((a, l) => /* @__PURE__ */ s(x.Fragment, { children: [
|
|
432
416
|
/* @__PURE__ */ e(Ie, { children: /* @__PURE__ */ e(
|
|
433
|
-
|
|
417
|
+
ye,
|
|
434
418
|
{
|
|
435
|
-
subheader: /* @__PURE__ */ e(
|
|
419
|
+
subheader: /* @__PURE__ */ e(ht, { sx: { bgcolor: "background.paper", ml: 8, pb: 4, pt: 12 }, children: /* @__PURE__ */ e(h, { bold: !0, variant: "caption", children: I(a.date, M.DAY_OF_WEEK_MONTH_DAY) }) }),
|
|
436
420
|
sx: { width: "100%" },
|
|
437
|
-
children: a.recurrences.map((
|
|
421
|
+
children: a.recurrences.map((p, g) => /* @__PURE__ */ e(x.Fragment, { children: /* @__PURE__ */ e(
|
|
438
422
|
Re,
|
|
439
423
|
{
|
|
440
424
|
isMini: n,
|
|
441
425
|
onRecurrenceClick: i,
|
|
442
|
-
recurrence:
|
|
426
|
+
recurrence: p
|
|
443
427
|
}
|
|
444
428
|
) }, `day-recurrence-${g}`))
|
|
445
429
|
}
|
|
446
430
|
) }, a.id),
|
|
447
431
|
/* @__PURE__ */ e(X, { sx: { mx: 24 } })
|
|
448
|
-
] }, `recurrence-${
|
|
432
|
+
] }, `recurrence-${l}`)) })
|
|
449
433
|
] });
|
|
450
434
|
}
|
|
451
|
-
),
|
|
435
|
+
), Te = R(
|
|
452
436
|
({ expected: t, isExpense: n = !0, missed: r, paid: i, title: o, total: c, upcoming: u }) => {
|
|
453
|
-
const
|
|
454
|
-
const g = [{ color:
|
|
455
|
-
return r && g.push({ color:
|
|
437
|
+
const m = ne(), { isSmallMobile: a } = Me(), { recurring: l } = b(), p = x.useMemo(() => {
|
|
438
|
+
const g = [{ color: m.palette.success.main, percentage: `${i / t}` }];
|
|
439
|
+
return r && g.push({ color: m.palette.error.main, percentage: `${r / t}` }), g;
|
|
456
440
|
}, [i, t, r]);
|
|
457
|
-
return /* @__PURE__ */ s(
|
|
458
|
-
/* @__PURE__ */ s(
|
|
441
|
+
return /* @__PURE__ */ s(d, { children: [
|
|
442
|
+
/* @__PURE__ */ s(d, { sx: { flexDirection: "row", justifyContent: "space-between", pb: 12 }, children: [
|
|
459
443
|
/* @__PURE__ */ e(h, { bold: !0, variant: "body1", children: `${o} (${c})` }),
|
|
460
|
-
/* @__PURE__ */ e(h, { bold: !0, color: n ? "text.primary" : "success.main", variant: "body1", children: `${n ? "-" : "+"}${
|
|
444
|
+
/* @__PURE__ */ e(h, { bold: !0, color: n ? "text.primary" : "success.main", variant: "body1", children: `${n ? "-" : "+"}${L(t, "0,0.00")}` })
|
|
461
445
|
] }),
|
|
462
|
-
/* @__PURE__ */ e(
|
|
463
|
-
/* @__PURE__ */ s(
|
|
464
|
-
/* @__PURE__ */ e(
|
|
465
|
-
!a && /* @__PURE__ */ e(h, { bold: !0, variant: "body2", children:
|
|
466
|
-
/* @__PURE__ */ e(h, { variant: "caption", children:
|
|
446
|
+
/* @__PURE__ */ e(ve, { data: p, height: 12 }),
|
|
447
|
+
/* @__PURE__ */ s(d, { sx: { alignItems: "center", flexDirection: "row", gap: 2, my: 8 }, children: [
|
|
448
|
+
/* @__PURE__ */ e(G, { sx: { bgcolor: "success.main", height: 8, mr: 8, width: 8 } }),
|
|
449
|
+
!a && /* @__PURE__ */ e(h, { bold: !0, variant: "body2", children: L(i, "0,0.00") }),
|
|
450
|
+
/* @__PURE__ */ e(h, { variant: "caption", children: l.paid?.toLowerCase() }),
|
|
467
451
|
r !== void 0 && /* @__PURE__ */ s($, { children: [
|
|
468
|
-
/* @__PURE__ */ e(
|
|
469
|
-
!a && /* @__PURE__ */ e(h, { bold: !0, variant: "body2", children:
|
|
470
|
-
/* @__PURE__ */ e(h, { variant: "caption", children:
|
|
452
|
+
/* @__PURE__ */ e(G, { sx: { bgcolor: "error.main", height: 8, ml: 16, mr: 8, width: 8 } }),
|
|
453
|
+
!a && /* @__PURE__ */ e(h, { bold: !0, variant: "body2", children: L(r, "0,0.00") }),
|
|
454
|
+
/* @__PURE__ */ e(h, { variant: "caption", children: l.missed?.toLowerCase() })
|
|
471
455
|
] }),
|
|
472
|
-
/* @__PURE__ */ e(
|
|
473
|
-
!a && /* @__PURE__ */ e(h, { bold: !0, variant: "body2", children:
|
|
474
|
-
/* @__PURE__ */ e(h, { variant: "caption", children:
|
|
456
|
+
/* @__PURE__ */ e(G, { sx: { bgcolor: "divider", height: 8, ml: 16, mr: 8, width: 8 } }),
|
|
457
|
+
!a && /* @__PURE__ */ e(h, { bold: !0, variant: "body2", children: L(u, "0,0.00") }),
|
|
458
|
+
/* @__PURE__ */ e(h, { variant: "caption", children: l.upcoming?.toLowerCase() })
|
|
475
459
|
] })
|
|
476
460
|
] });
|
|
477
461
|
}
|
|
478
|
-
),
|
|
479
|
-
const { recurring: t } =
|
|
462
|
+
), Ee = R(() => {
|
|
463
|
+
const { recurring: t } = b(), { selectedRepeatingTransaction: n, setSelectedRepeatingTransactionGuid: r } = _();
|
|
464
|
+
return /* @__PURE__ */ e(
|
|
465
|
+
ie,
|
|
466
|
+
{
|
|
467
|
+
ariaLabelClose: t.close_drawer_aria,
|
|
468
|
+
isOpen: !!n,
|
|
469
|
+
onClose: () => r(null),
|
|
470
|
+
title: n?.repeating_transaction_type === pt.Income ? t.income_details : t.expense_details,
|
|
471
|
+
children: n && /* @__PURE__ */ e(
|
|
472
|
+
yt,
|
|
473
|
+
{
|
|
474
|
+
onDeleted: () => r(null),
|
|
475
|
+
recurringTransaction: n
|
|
476
|
+
}
|
|
477
|
+
)
|
|
478
|
+
}
|
|
479
|
+
);
|
|
480
|
+
}), vt = R(() => {
|
|
481
|
+
const { recurring: t } = b(), { availableWidth: n } = we(), { isDesktop: r, isSmallMobile: i, isMobile: o } = Me(n), { onEvent: c } = Y(), {
|
|
480
482
|
currentMonthExpenses: u,
|
|
481
|
-
currentMonthIncome:
|
|
483
|
+
currentMonthIncome: m,
|
|
482
484
|
dateRange: a,
|
|
483
|
-
expenseTotal:
|
|
484
|
-
incomeTotal:
|
|
485
|
+
expenseTotal: l,
|
|
486
|
+
incomeTotal: p,
|
|
485
487
|
missedExpenseTotal: g,
|
|
486
|
-
pastRecurrences:
|
|
488
|
+
pastRecurrences: y,
|
|
487
489
|
paidExpenseTotal: C,
|
|
488
|
-
paidIncomeTotal:
|
|
489
|
-
selectedDay:
|
|
490
|
+
paidIncomeTotal: S,
|
|
491
|
+
selectedDay: A,
|
|
490
492
|
selectedDayRecurrences: f,
|
|
491
|
-
setDateRange:
|
|
492
|
-
|
|
493
|
-
|
|
493
|
+
setDateRange: w,
|
|
494
|
+
setSelectedRepeatingTransactionGuid: H,
|
|
495
|
+
upcomingExpenseTotal: Ne,
|
|
496
|
+
upcomingIncomeTotal: Ge,
|
|
494
497
|
upcomingRecurrences: ue
|
|
495
|
-
} =
|
|
496
|
-
|
|
497
|
-
}, me = (
|
|
498
|
-
c(
|
|
499
|
-
transaction_guid:
|
|
498
|
+
} = _(), [V, ke] = x.useState(0), Oe = Ye(a.start, /* @__PURE__ */ new Date()), We = (T, He) => {
|
|
499
|
+
ke(He);
|
|
500
|
+
}, me = (T) => {
|
|
501
|
+
H(T.repeatingTransactionGuid), c(v.RECURRING_TRANSACTIONS_CLICK_UPCOMING, {
|
|
502
|
+
transaction_guid: T.transaction?.guid
|
|
500
503
|
});
|
|
501
|
-
}, pe = (
|
|
502
|
-
c(
|
|
503
|
-
transaction_guid:
|
|
504
|
+
}, pe = (T) => {
|
|
505
|
+
H(T.repeatingTransactionGuid), c(v.RECURRING_TRANSACTIONS_CLICK_PAID, {
|
|
506
|
+
transaction_guid: T.transaction?.guid
|
|
504
507
|
});
|
|
505
|
-
},
|
|
506
|
-
const
|
|
507
|
-
|
|
508
|
-
start: k(
|
|
509
|
-
end: z(
|
|
508
|
+
}, Pe = () => {
|
|
509
|
+
const T = Fe(a.start, 1);
|
|
510
|
+
w({
|
|
511
|
+
start: k(T),
|
|
512
|
+
end: z(T)
|
|
510
513
|
});
|
|
511
|
-
},
|
|
512
|
-
const
|
|
513
|
-
|
|
514
|
-
start: k(
|
|
515
|
-
end: z(
|
|
514
|
+
}, ze = () => {
|
|
515
|
+
const T = Ue(a.start, 1);
|
|
516
|
+
w({
|
|
517
|
+
start: k(T),
|
|
518
|
+
end: z(T)
|
|
516
519
|
});
|
|
517
520
|
};
|
|
518
521
|
return /* @__PURE__ */ s(
|
|
@@ -524,45 +527,45 @@ const Y = {
|
|
|
524
527
|
},
|
|
525
528
|
children: [
|
|
526
529
|
/* @__PURE__ */ s(q, { size: { sm: 12, md: "grow" }, width: "100%", children: [
|
|
527
|
-
/* @__PURE__ */ s(
|
|
528
|
-
/* @__PURE__ */ s(
|
|
529
|
-
/* @__PURE__ */ e(
|
|
530
|
+
/* @__PURE__ */ s(d, { sx: { gap: 16, px: r ? 48 : 24 }, children: [
|
|
531
|
+
/* @__PURE__ */ s(d, { alignItems: "center", direction: "row", justifyContent: "space-between", children: [
|
|
532
|
+
/* @__PURE__ */ e(et, { variant: "h3", children: N(
|
|
530
533
|
t.header_title,
|
|
531
|
-
|
|
534
|
+
I(a.start, M.MONTH_LONG)
|
|
532
535
|
) }),
|
|
533
|
-
!r && /* @__PURE__ */ s(
|
|
536
|
+
!r && /* @__PURE__ */ s(d, { direction: "row", gap: 4, children: [
|
|
534
537
|
/* @__PURE__ */ e(
|
|
535
538
|
ge,
|
|
536
539
|
{
|
|
537
540
|
color: "primary",
|
|
538
541
|
disabled: Oe,
|
|
539
|
-
onClick:
|
|
540
|
-
children: /* @__PURE__ */ e(
|
|
542
|
+
onClick: ze,
|
|
543
|
+
children: /* @__PURE__ */ e(qe, {})
|
|
541
544
|
}
|
|
542
545
|
),
|
|
543
|
-
/* @__PURE__ */ e(ge, { color: "primary", onClick:
|
|
546
|
+
/* @__PURE__ */ e(ge, { color: "primary", onClick: Pe, children: /* @__PURE__ */ e(Ze, {}) })
|
|
544
547
|
] })
|
|
545
548
|
] }),
|
|
546
549
|
/* @__PURE__ */ e(
|
|
547
|
-
|
|
550
|
+
Te,
|
|
548
551
|
{
|
|
549
|
-
expected:
|
|
552
|
+
expected: l,
|
|
550
553
|
missed: g,
|
|
551
554
|
paid: C,
|
|
552
555
|
title: t.expenses,
|
|
553
556
|
total: u.length,
|
|
554
|
-
upcoming:
|
|
557
|
+
upcoming: Ne
|
|
555
558
|
}
|
|
556
559
|
),
|
|
557
560
|
/* @__PURE__ */ e(
|
|
558
|
-
|
|
561
|
+
Te,
|
|
559
562
|
{
|
|
560
|
-
expected:
|
|
563
|
+
expected: p,
|
|
561
564
|
isExpense: !1,
|
|
562
|
-
paid:
|
|
565
|
+
paid: S,
|
|
563
566
|
title: t.deposits,
|
|
564
|
-
total:
|
|
565
|
-
upcoming:
|
|
567
|
+
total: m.length,
|
|
568
|
+
upcoming: Ge
|
|
566
569
|
}
|
|
567
570
|
),
|
|
568
571
|
r && /* @__PURE__ */ e(
|
|
@@ -574,8 +577,8 @@ const Y = {
|
|
|
574
577
|
}
|
|
575
578
|
)
|
|
576
579
|
] }),
|
|
577
|
-
!r && /* @__PURE__ */ s(
|
|
578
|
-
/* @__PURE__ */ s(
|
|
580
|
+
!r && /* @__PURE__ */ s(d, { sx: { px: o ? 0 : 24 }, children: [
|
|
581
|
+
/* @__PURE__ */ s(je, { onChange: We, value: V, variant: "fullWidth", children: [
|
|
579
582
|
/* @__PURE__ */ e(
|
|
580
583
|
he,
|
|
581
584
|
{
|
|
@@ -600,110 +603,130 @@ const Y = {
|
|
|
600
603
|
P,
|
|
601
604
|
{
|
|
602
605
|
onRecurrenceClick: pe,
|
|
603
|
-
recurrences:
|
|
606
|
+
recurrences: y
|
|
604
607
|
}
|
|
605
608
|
)
|
|
606
609
|
] })
|
|
607
610
|
] }),
|
|
608
|
-
r && /* @__PURE__ */ e(q, { size: { xs: "auto" }, sx: { minWidth: 450 }, children: /* @__PURE__ */ s(
|
|
611
|
+
r && /* @__PURE__ */ e(q, { size: { xs: "auto" }, sx: { minWidth: 450 }, children: /* @__PURE__ */ s(d, { gap: 24, children: [
|
|
609
612
|
/* @__PURE__ */ e(Ae, {}),
|
|
610
613
|
/* @__PURE__ */ e(
|
|
611
614
|
P,
|
|
612
615
|
{
|
|
613
616
|
onRecurrenceClick: pe,
|
|
614
|
-
recurrences: f ||
|
|
615
|
-
title:
|
|
617
|
+
recurrences: f || y,
|
|
618
|
+
title: A ? N(
|
|
616
619
|
t.day_transactions,
|
|
617
|
-
|
|
620
|
+
I(A, M.MONTH_DAY)
|
|
618
621
|
) : t.past_transactions
|
|
619
622
|
}
|
|
620
623
|
)
|
|
621
|
-
] }) })
|
|
624
|
+
] }) }),
|
|
625
|
+
/* @__PURE__ */ e(Ee, {})
|
|
622
626
|
]
|
|
623
627
|
}
|
|
624
628
|
);
|
|
625
|
-
}),
|
|
629
|
+
}), Yn = R(
|
|
626
630
|
({ onBackClick: t, onMenuClick: n, sx: r = {} }) => {
|
|
627
|
-
const { recurring: i } =
|
|
631
|
+
const { recurring: i } = b(), { isInitialized: o, selectedAccountGuids: c } = U(), { alert: u, isDataLoaded: m, loadRepeatingTransactionData: a, setAlert: l, setDateRange: p } = _(), { setFilter: g } = re(), { onEvent: y } = Y(), [C, S] = x.useState(!1);
|
|
628
632
|
return oe({
|
|
629
633
|
widgetName: "RecurringTransactionsWidget",
|
|
630
|
-
isLoaded:
|
|
634
|
+
isLoaded: m
|
|
631
635
|
}), x.useEffect(() => {
|
|
632
|
-
|
|
636
|
+
m || a().finally();
|
|
633
637
|
}, []), x.useEffect(() => {
|
|
634
|
-
|
|
638
|
+
g({
|
|
635
639
|
dateRange: { start: ee(Q(), 90), end: J() },
|
|
636
640
|
accounts: c
|
|
637
|
-
}),
|
|
641
|
+
}), p({ start: k(/* @__PURE__ */ new Date()), end: z(/* @__PURE__ */ new Date()) });
|
|
638
642
|
}, [c]), o ? /* @__PURE__ */ s(
|
|
639
|
-
|
|
643
|
+
Ct,
|
|
640
644
|
{
|
|
641
645
|
actions: [
|
|
642
646
|
{
|
|
643
647
|
label: i.action_title,
|
|
644
648
|
iconName: "credit_card_gear",
|
|
645
649
|
onClick: () => {
|
|
646
|
-
|
|
650
|
+
S(!0), y(v.RECURRING_TRANSACTIONS_CLICK_SETTINGS);
|
|
647
651
|
}
|
|
648
652
|
}
|
|
649
653
|
],
|
|
650
654
|
hasDivider: !0,
|
|
651
|
-
onAccountsFilterClick: () =>
|
|
655
|
+
onAccountsFilterClick: () => y(v.RECURRING_TRANSACTIONS_CLICK_FILTER),
|
|
652
656
|
onBackClick: t,
|
|
653
657
|
onMenuClick: n,
|
|
654
658
|
sx: r,
|
|
655
659
|
title: i.title,
|
|
656
660
|
children: [
|
|
657
|
-
|
|
661
|
+
m ? /* @__PURE__ */ e(vt, {}) : /* @__PURE__ */ e(Le, { sx: { m: 48 }, variant: "list" }),
|
|
658
662
|
/* @__PURE__ */ e(
|
|
659
663
|
ie,
|
|
660
664
|
{
|
|
661
665
|
ariaLabelClose: i.close_drawer_aria,
|
|
662
|
-
isOpen:
|
|
663
|
-
onClose: () =>
|
|
666
|
+
isOpen: C,
|
|
667
|
+
onClose: () => S(!1),
|
|
664
668
|
shouldShowHeaderBorders: !1,
|
|
665
669
|
title: i.action_title,
|
|
666
|
-
children: /* @__PURE__ */ e(
|
|
670
|
+
children: /* @__PURE__ */ e(De, {})
|
|
671
|
+
}
|
|
672
|
+
),
|
|
673
|
+
/* @__PURE__ */ e(
|
|
674
|
+
$e,
|
|
675
|
+
{
|
|
676
|
+
anchorOrigin: { vertical: "bottom", horizontal: "right" },
|
|
677
|
+
autoHideDuration: 3500,
|
|
678
|
+
onClose: () => l(""),
|
|
679
|
+
open: !!u.message,
|
|
680
|
+
children: /* @__PURE__ */ e(Be, { onClose: () => l(""), severity: u.severity, variant: "filled", children: u.message })
|
|
667
681
|
}
|
|
668
682
|
)
|
|
669
683
|
]
|
|
670
684
|
}
|
|
671
685
|
) : /* @__PURE__ */ e(ae, {});
|
|
672
686
|
}
|
|
673
|
-
),
|
|
674
|
-
const { recurring: t } =
|
|
675
|
-
|
|
687
|
+
), Lt = R(() => {
|
|
688
|
+
const { recurring: t } = b(), { availableWidth: n } = we(), {
|
|
689
|
+
selectedDay: r,
|
|
690
|
+
selectedDayRecurrences: i,
|
|
691
|
+
setSelectedDay: o,
|
|
692
|
+
setSelectedRepeatingTransactionGuid: c,
|
|
693
|
+
upcomingRecurrences: u
|
|
694
|
+
} = _(), m = (l) => {
|
|
695
|
+
c(l.repeatingTransactionGuid);
|
|
696
|
+
}, a = n < 750;
|
|
697
|
+
return /* @__PURE__ */ s(d, { flexDirection: a ? "column" : "row", width: "100%", children: [
|
|
676
698
|
/* @__PURE__ */ e(Ae, {}),
|
|
677
|
-
!
|
|
699
|
+
!a && /* @__PURE__ */ e(X, { flexItem: !0, orientation: "vertical", sx: { my: 16, ml: 16 } }),
|
|
678
700
|
/* @__PURE__ */ e(
|
|
679
701
|
P,
|
|
680
702
|
{
|
|
681
703
|
isMini: !0,
|
|
704
|
+
onRecurrenceClick: m,
|
|
682
705
|
onResetClick: r ? () => o(r) : void 0,
|
|
683
|
-
recurrences: i ||
|
|
684
|
-
sx: { width:
|
|
706
|
+
recurrences: i || u.slice(0, 5),
|
|
707
|
+
sx: { width: a ? "100%" : "calc(100% - 336px)", mt: 12 },
|
|
685
708
|
title: r ? N(
|
|
686
709
|
t.day_transactions,
|
|
687
|
-
|
|
710
|
+
I(r, M.MONTH_DAY)
|
|
688
711
|
) : t.upcoming_activity
|
|
689
712
|
}
|
|
690
713
|
)
|
|
691
714
|
] });
|
|
692
|
-
}),
|
|
715
|
+
}), jn = R(
|
|
693
716
|
({ onPrimaryCtaClick: t, sx: n }) => {
|
|
694
|
-
const { recurring: r } =
|
|
717
|
+
const { recurring: r } = b(), { setFilter: i } = re(), { isDataLoaded: o, loadRepeatingTransactionData: c } = _(), { isInitialized: u, selectedAccountGuids: m } = U();
|
|
695
718
|
return oe({
|
|
696
719
|
widgetName: "RecurringTransactionsMiniWidget",
|
|
697
720
|
isLoaded: o
|
|
698
721
|
}), x.useEffect(() => {
|
|
699
722
|
o || c().finally();
|
|
700
723
|
}, []), x.useEffect(() => {
|
|
701
|
-
|
|
724
|
+
m.length > 0 && i({
|
|
702
725
|
dateRange: { start: ee(Q(), 90), end: J() },
|
|
703
|
-
accounts:
|
|
726
|
+
accounts: m
|
|
704
727
|
});
|
|
705
|
-
}, [
|
|
706
|
-
|
|
728
|
+
}, [m]), u ? /* @__PURE__ */ s(
|
|
729
|
+
Rt,
|
|
707
730
|
{
|
|
708
731
|
className: "mx-exp-recurring-transactions-miniwidget",
|
|
709
732
|
onPrimaryCtaClick: t,
|
|
@@ -712,28 +735,31 @@ const Y = {
|
|
|
712
735
|
subTitle: r.sub_title,
|
|
713
736
|
sx: n,
|
|
714
737
|
title: r.mini_title,
|
|
715
|
-
children:
|
|
738
|
+
children: [
|
|
739
|
+
o ? /* @__PURE__ */ e(Lt, {}) : /* @__PURE__ */ e(Le, { sx: { mx: 16 }, variant: "list" }),
|
|
740
|
+
/* @__PURE__ */ e(Ee, {})
|
|
741
|
+
]
|
|
716
742
|
}
|
|
717
743
|
) : /* @__PURE__ */ e(ae, {});
|
|
718
744
|
}
|
|
719
|
-
),
|
|
720
|
-
const { recurring: t } =
|
|
721
|
-
return /* @__PURE__ */ s(
|
|
722
|
-
/* @__PURE__ */ e(
|
|
723
|
-
/* @__PURE__ */ s(
|
|
745
|
+
), At = R(() => {
|
|
746
|
+
const { recurring: t } = b();
|
|
747
|
+
return /* @__PURE__ */ s(d, { sx: { alignItems: "start", flexDirection: "row", gap: 12 }, children: [
|
|
748
|
+
/* @__PURE__ */ e(Xe, { size: 32 }),
|
|
749
|
+
/* @__PURE__ */ s(d, { children: [
|
|
724
750
|
/* @__PURE__ */ e(Z, { fontWeight: 600, variant: "body1", children: t.zero_state_content_header }),
|
|
725
751
|
/* @__PURE__ */ e(Z, { color: "text.secondary", variant: "subtitle2", children: t.zero_state_content_description })
|
|
726
752
|
] })
|
|
727
753
|
] });
|
|
728
|
-
}),
|
|
754
|
+
}), Et = ({
|
|
729
755
|
amount: t,
|
|
730
756
|
bgcolor: n,
|
|
731
757
|
isLargeScreen: r,
|
|
732
758
|
isSmallScreen: i,
|
|
733
759
|
label: o
|
|
734
|
-
}) => /* @__PURE__ */ s(
|
|
760
|
+
}) => /* @__PURE__ */ s(d, { sx: { alignItems: "center", flexDirection: "row", gap: 8 }, children: [
|
|
735
761
|
/* @__PURE__ */ e(
|
|
736
|
-
|
|
762
|
+
G,
|
|
737
763
|
{
|
|
738
764
|
sx: {
|
|
739
765
|
borderRadius: "2px",
|
|
@@ -743,25 +769,25 @@ const Y = {
|
|
|
743
769
|
}
|
|
744
770
|
}
|
|
745
771
|
),
|
|
746
|
-
/* @__PURE__ */ s(
|
|
747
|
-
!i && /* @__PURE__ */ e(h, { bold: !0, variant: "caption", children:
|
|
772
|
+
/* @__PURE__ */ s(d, { sx: { alignItems: "center", flexDirection: "row", gap: 2 }, children: [
|
|
773
|
+
!i && /* @__PURE__ */ e(h, { bold: !0, variant: "caption", children: L(t, t === 0 || !r ? "0,0" : "0,0.00") }),
|
|
748
774
|
/* @__PURE__ */ e(h, { variant: "caption", children: o })
|
|
749
775
|
] })
|
|
750
|
-
] }),
|
|
776
|
+
] }), Nt = ({
|
|
751
777
|
upcomingRecurrences: t,
|
|
752
778
|
logoSize: n = 32,
|
|
753
779
|
maxLogos: r = 3
|
|
754
780
|
}) => {
|
|
755
781
|
const i = (o) => o * (n / 2);
|
|
756
782
|
return /* @__PURE__ */ e(
|
|
757
|
-
|
|
783
|
+
G,
|
|
758
784
|
{
|
|
759
785
|
sx: {
|
|
760
786
|
position: "relative",
|
|
761
787
|
width: 64
|
|
762
788
|
},
|
|
763
789
|
children: t.map((o, c) => c < r ? /* @__PURE__ */ e(
|
|
764
|
-
|
|
790
|
+
G,
|
|
765
791
|
{
|
|
766
792
|
sx: {
|
|
767
793
|
borderRadius: "4px",
|
|
@@ -784,45 +810,45 @@ const Y = {
|
|
|
784
810
|
) : null)
|
|
785
811
|
}
|
|
786
812
|
);
|
|
787
|
-
},
|
|
813
|
+
}, Gt = ({
|
|
788
814
|
upcomingRecurrences: t,
|
|
789
815
|
maxLogos: n = 3
|
|
790
|
-
}) => /* @__PURE__ */ e(
|
|
816
|
+
}) => /* @__PURE__ */ e(d, { sx: { flexDirection: "row", gap: 4 }, children: t?.slice(0, n).map((r, i) => /* @__PURE__ */ e(
|
|
791
817
|
te,
|
|
792
818
|
{
|
|
793
819
|
categoryGuid: r.categoryGuid || "",
|
|
794
820
|
merchantGuid: r.merchantGuid || ""
|
|
795
821
|
},
|
|
796
822
|
`${r.categoryGuid}-${r.merchantGuid}-${i}`
|
|
797
|
-
)) }),
|
|
798
|
-
const t = ne(), [n, { width: r }] =
|
|
823
|
+
)) }), kt = R(() => {
|
|
824
|
+
const t = ne(), [n, { width: r }] = Tt(), {
|
|
799
825
|
upcomingRecurrences: i,
|
|
800
826
|
expenseTotal: o,
|
|
801
827
|
missedExpenseTotal: c,
|
|
802
828
|
paidExpenseTotal: u,
|
|
803
|
-
upcomingExpenseTotal:
|
|
804
|
-
} =
|
|
805
|
-
const
|
|
829
|
+
upcomingExpenseTotal: m
|
|
830
|
+
} = _(), { recurring: a } = b(), l = r <= 288, p = r >= 450, g = 32, y = i.length > 0, C = x.useMemo(() => L(o, o === 0 ? "0,0" : "0,0.00"), [o]), S = x.useMemo(() => {
|
|
831
|
+
const w = [
|
|
806
832
|
{ color: t.palette.success.main, percentage: `${u / o}` }
|
|
807
833
|
];
|
|
808
|
-
return c &&
|
|
834
|
+
return c && w.push({
|
|
809
835
|
color: t.palette.error.main,
|
|
810
836
|
percentage: `${c / o}`
|
|
811
|
-
}),
|
|
837
|
+
}), w;
|
|
812
838
|
}, [
|
|
813
839
|
u,
|
|
814
840
|
o,
|
|
815
841
|
c,
|
|
816
842
|
t.palette.success.main,
|
|
817
843
|
t.palette.error.main
|
|
818
|
-
]),
|
|
819
|
-
|
|
844
|
+
]), A = () => y ? l ? /* @__PURE__ */ e(
|
|
845
|
+
Nt,
|
|
820
846
|
{
|
|
821
847
|
logoSize: g,
|
|
822
848
|
maxLogos: 3,
|
|
823
849
|
upcomingRecurrences: i.slice(0, 3)
|
|
824
850
|
}
|
|
825
|
-
) : /* @__PURE__ */ e(
|
|
851
|
+
) : /* @__PURE__ */ e(Gt, { maxLogos: 3, upcomingRecurrences: i.slice(0, 3) }) : /* @__PURE__ */ e(d, { sx: { width: l ? 64 : 104 } }), f = [
|
|
826
852
|
{
|
|
827
853
|
amount: u,
|
|
828
854
|
bgColor: "success.main",
|
|
@@ -834,18 +860,18 @@ const Y = {
|
|
|
834
860
|
label: a.missed
|
|
835
861
|
},
|
|
836
862
|
{
|
|
837
|
-
amount:
|
|
863
|
+
amount: m,
|
|
838
864
|
bgColor: "neutral.light",
|
|
839
865
|
label: a.upcoming
|
|
840
866
|
}
|
|
841
867
|
];
|
|
842
868
|
return /* @__PURE__ */ s($, { children: [
|
|
843
|
-
/* @__PURE__ */ s(
|
|
869
|
+
/* @__PURE__ */ s(d, { ref: n, sx: { flexDirection: "row", justifyContent: "space-between" }, children: [
|
|
844
870
|
/* @__PURE__ */ s(
|
|
845
|
-
|
|
871
|
+
d,
|
|
846
872
|
{
|
|
847
873
|
sx: [
|
|
848
|
-
C.length >= 10 &&
|
|
874
|
+
C.length >= 10 && l ? { flexDirection: "column" } : { flexDirection: "row", gap: 2 },
|
|
849
875
|
{
|
|
850
876
|
alignItems: "baseline",
|
|
851
877
|
overflow: "hidden",
|
|
@@ -858,7 +884,7 @@ const Y = {
|
|
|
858
884
|
h,
|
|
859
885
|
{
|
|
860
886
|
sx: { width: "100%" },
|
|
861
|
-
variant: C.length >= 10 &&
|
|
887
|
+
variant: C.length >= 10 && l ? "h3" : "h2",
|
|
862
888
|
children: C
|
|
863
889
|
}
|
|
864
890
|
),
|
|
@@ -866,12 +892,12 @@ const Y = {
|
|
|
866
892
|
]
|
|
867
893
|
}
|
|
868
894
|
),
|
|
869
|
-
|
|
895
|
+
A()
|
|
870
896
|
] }),
|
|
871
|
-
/* @__PURE__ */ s(
|
|
872
|
-
/* @__PURE__ */ e(
|
|
897
|
+
/* @__PURE__ */ s(d, { sx: { pt: 12 }, children: [
|
|
898
|
+
/* @__PURE__ */ e(ve, { data: S }),
|
|
873
899
|
/* @__PURE__ */ e(
|
|
874
|
-
|
|
900
|
+
d,
|
|
875
901
|
{
|
|
876
902
|
sx: {
|
|
877
903
|
alignItems: "center",
|
|
@@ -879,66 +905,66 @@ const Y = {
|
|
|
879
905
|
gap: 16,
|
|
880
906
|
mt: 4
|
|
881
907
|
},
|
|
882
|
-
children: f.map((
|
|
883
|
-
|
|
908
|
+
children: f.map((w, H) => /* @__PURE__ */ e(
|
|
909
|
+
Et,
|
|
884
910
|
{
|
|
885
|
-
amount:
|
|
886
|
-
bgcolor:
|
|
887
|
-
isLargeScreen:
|
|
888
|
-
isSmallScreen:
|
|
889
|
-
label:
|
|
911
|
+
amount: w.amount,
|
|
912
|
+
bgcolor: w.bgColor,
|
|
913
|
+
isLargeScreen: p,
|
|
914
|
+
isSmallScreen: l,
|
|
915
|
+
label: w.label
|
|
890
916
|
},
|
|
891
|
-
`recurrence-legend-${
|
|
917
|
+
`recurrence-legend-${H}`
|
|
892
918
|
))
|
|
893
919
|
}
|
|
894
920
|
)
|
|
895
921
|
] })
|
|
896
922
|
] });
|
|
897
|
-
}),
|
|
923
|
+
}), Kn = R(
|
|
898
924
|
({ onCTAClick: t }) => {
|
|
899
|
-
const { onEvent: n } =
|
|
925
|
+
const { onEvent: n } = Y(), { isInitialized: r, selectedAccountGuids: i } = U(), {
|
|
900
926
|
loadRepeatingTransactionData: o,
|
|
901
927
|
upcomingRecurrences: c,
|
|
902
928
|
repeatingTransactions: u,
|
|
903
|
-
setDateRange:
|
|
929
|
+
setDateRange: m,
|
|
904
930
|
isDataLoaded: a
|
|
905
|
-
} =
|
|
931
|
+
} = _(), { setFilter: l } = re(), { recurring: p, budgets: g } = b();
|
|
906
932
|
oe({
|
|
907
933
|
widgetName: "RecurringTransactionsMicroWidget",
|
|
908
934
|
isLoaded: a
|
|
909
935
|
}), x.useEffect(() => {
|
|
910
936
|
a || o().finally(() => {
|
|
911
|
-
n(
|
|
937
|
+
n(v.RECURRING_TRANSACTIONS_LOAD_WIDGET, {
|
|
912
938
|
state: c.length > 0 ? "default" : "zeroState"
|
|
913
939
|
});
|
|
914
940
|
});
|
|
915
941
|
}, []), x.useEffect(() => {
|
|
916
|
-
r && (
|
|
942
|
+
r && (l({
|
|
917
943
|
dateRange: { start: ee(Q(), 90), end: J() },
|
|
918
944
|
accounts: i
|
|
919
|
-
}),
|
|
945
|
+
}), m({ start: k(/* @__PURE__ */ new Date()), end: z(/* @__PURE__ */ new Date()) }));
|
|
920
946
|
}, [r, i]);
|
|
921
|
-
const
|
|
947
|
+
const y = () => {
|
|
922
948
|
n(
|
|
923
|
-
c.length > 0 ?
|
|
949
|
+
c.length > 0 ? v.RECURRING_TRANSACTIONS_CLICK_GET_STARTED : v.RECURRING_TRANSACTIONS_CLICK_VIEW_ALL
|
|
924
950
|
), t();
|
|
925
951
|
};
|
|
926
952
|
if (!r || !a) return /* @__PURE__ */ e(ae, { height: 100 });
|
|
927
953
|
const C = !u?.length;
|
|
928
954
|
return /* @__PURE__ */ e(
|
|
929
|
-
|
|
955
|
+
Dt,
|
|
930
956
|
{
|
|
931
957
|
className: "mx-recurring-transaction-microwidget",
|
|
932
|
-
ctaLabel: C ? g.get_started_cta :
|
|
933
|
-
onCTAClick:
|
|
934
|
-
title:
|
|
935
|
-
children: C ? /* @__PURE__ */ e(
|
|
958
|
+
ctaLabel: C ? g.get_started_cta : p.primary_cta,
|
|
959
|
+
onCTAClick: y,
|
|
960
|
+
title: p.recurring_expenses,
|
|
961
|
+
children: C ? /* @__PURE__ */ e(At, {}) : /* @__PURE__ */ e(kt, {})
|
|
936
962
|
}
|
|
937
963
|
);
|
|
938
964
|
}
|
|
939
|
-
),
|
|
965
|
+
), Vn = R(
|
|
940
966
|
({ isOpen: t, onClose: n, selectedTab: r }) => {
|
|
941
|
-
const { cashflow: i } =
|
|
967
|
+
const { cashflow: i } = b();
|
|
942
968
|
return /* @__PURE__ */ e(
|
|
943
969
|
ie,
|
|
944
970
|
{
|
|
@@ -946,19 +972,19 @@ const Y = {
|
|
|
946
972
|
isOpen: t,
|
|
947
973
|
onClose: n,
|
|
948
974
|
title: i.cashflow_settings,
|
|
949
|
-
children: /* @__PURE__ */ e(
|
|
975
|
+
children: /* @__PURE__ */ e(De, { defaultSelectedTab: r })
|
|
950
976
|
}
|
|
951
977
|
);
|
|
952
978
|
}
|
|
953
979
|
);
|
|
954
980
|
export {
|
|
955
|
-
|
|
956
|
-
|
|
957
|
-
|
|
958
|
-
|
|
959
|
-
|
|
960
|
-
|
|
961
|
-
|
|
962
|
-
|
|
963
|
-
|
|
981
|
+
Qn as AddRecurringTransactionDetails,
|
|
982
|
+
Xn as ManageExpenses,
|
|
983
|
+
er as ManageIncome,
|
|
984
|
+
De as RecurringSettings,
|
|
985
|
+
Vn as RecurringSettingsDrawer,
|
|
986
|
+
Kn as RecurringTransactionsMicroWidget,
|
|
987
|
+
jn as RecurringTransactionsMiniWidget,
|
|
988
|
+
Yn as RecurringTransactionsWidget,
|
|
989
|
+
tr as SelectTransaction
|
|
964
990
|
};
|