@mx-cartographer/experiences 7.4.8-alpha.mm1 → 7.4.8
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 +4 -0
- package/dist/{Account-BrOTlmeK.mjs → Account-01wOyrH1.mjs} +1 -1
- package/dist/{AccountDetailsContent-B7FqH05C.mjs → AccountDetailsContent-COMjOzwr.mjs} +8 -8
- package/dist/{AccountDetailsHeader-C8MxsxhN.mjs → AccountDetailsHeader-Cbi5G6fJ.mjs} +4 -4
- package/dist/{AccountFields-BQZ-o6Kj.mjs → AccountFields-Cd_nOWmf.mjs} +2 -2
- package/dist/{AccountListItem-aIE9WWTO.mjs → AccountListItem-DxY4cCF1.mjs} +4 -4
- package/dist/{AccountStore-DqO84Aer.mjs → AccountStore-C1zMBzHq.mjs} +2 -2
- package/dist/{Accounts-DC_A4UCa.mjs → Accounts-D7QljYas.mjs} +1 -1
- package/dist/{BudgetUtil-BmZXkL0C.mjs → BudgetUtil-Df2nII9u.mjs} +1 -1
- package/dist/{CategorySelectorDrawer-SUgfE5GN.mjs → CategorySelectorDrawer-DqJK_rrL.mjs} +1 -1
- package/dist/{ConnectDrawer-KL8t1qSC.mjs → ConnectDrawer-CuUj16NH.mjs} +1 -1
- package/dist/{ConnectionsDrawer-DaK5uIL5.mjs → ConnectionsDrawer-Bz4uwdFE.mjs} +2 -2
- package/dist/{CurrencyInput-itK0R3wV.mjs → CurrencyInput-BFKcs-_K.mjs} +1 -1
- package/dist/{DebtsStore-DVPZbv2C.mjs → DebtsStore-Bu8rRRSL.mjs} +1 -1
- package/dist/{ExportCsvAction-Cglo8Mca.mjs → ExportCsvAction-DzTrtPzk.mjs} +3 -3
- package/dist/{GoalStore-o4rrjGSJ.mjs → GoalStore-CrNhjvNc.mjs} +2 -2
- package/dist/{Help-BjLMsuMS.mjs → Help-BnPXM_N2.mjs} +1 -1
- package/dist/{LineChart-BQRxZF3p.mjs → LineChart-bc1D9xBE.mjs} +1 -1
- package/dist/{ListItemAction-BxTkF6Tz.mjs → ListItemAction-uobBrm_a.mjs} +1 -1
- package/dist/{ManageIncome-rcnDYsBJ.mjs → ManageIncome-A69EUO5u.mjs} +75 -75
- package/dist/{MicroWidgetContainer-B2hO9rOG.mjs → MicroWidgetContainer-DEiRnYVa.mjs} +1 -1
- package/dist/{MiniWidgetContainer-98-hKFqm.mjs → MiniWidgetContainer-CmXpTylX.mjs} +1 -1
- package/dist/{NetWorthStore-DG2X69jG.mjs → NetWorthStore-CpL_kqvx.mjs} +2 -2
- package/dist/{NotificationSettings-C7FYNM7I.mjs → NotificationSettings-CNmJWVeI.mjs} +248 -250
- package/dist/{OriginalBalanceAction-C6jdS4ws.mjs → OriginalBalanceAction-DK8_LkPz.mjs} +3 -3
- package/dist/{RecurringSettings-C81H1l38.mjs → RecurringSettings-B0uObPlD.mjs} +3 -3
- package/dist/{SpendingLegend-DqZxN_BZ.mjs → SpendingLegend-Bf-wbJvb.mjs} +2 -2
- package/dist/{TransactionDetails-BA_E5nQ-.mjs → TransactionDetails-COH0OKNG.mjs} +5 -5
- package/dist/{TransactionStore-PRlwE-TF.mjs → TransactionStore-Dz-G8Wd0.mjs} +2 -2
- package/dist/{User-Cnlegl1N.mjs → User-wXzDI4M8.mjs} +1 -1
- package/dist/{ViewMoreMicroCard-DfPXJzbv.mjs → ViewMoreMicroCard-C0832BMe.mjs} +101 -105
- package/dist/{WidgetContainer-CaPjoWeE.mjs → WidgetContainer-6dsjtOVg.mjs} +2 -2
- package/dist/accounts/index.es.js +140 -148
- package/dist/analytics/index.es.js +2 -2
- package/dist/budgets/index.es.js +478 -483
- package/dist/cashflow/index.es.js +362 -367
- package/dist/categories/index.es.js +1 -1
- package/dist/common/hooks/index.d.ts +0 -1
- package/dist/common/index.es.js +33 -35
- package/dist/dashboard/index.es.js +88 -90
- package/dist/debts/index.es.js +342 -346
- package/dist/{exportTransactionsToCSV-DuAaI5XA.mjs → exportTransactionsToCSV-Cz2t0lmA.mjs} +1 -1
- package/dist/finstrong/index.es.js +350 -352
- package/dist/goals/index.es.js +511 -518
- package/dist/help/index.es.js +9 -13
- package/dist/{hooks-ZMp65DFz.mjs → hooks-C41HAxM5.mjs} +11 -11
- package/dist/investments/index.es.js +393 -395
- package/dist/merchants/index.es.js +1 -1
- package/dist/microinsights/index.es.js +1 -1
- package/dist/networth/index.es.js +240 -245
- package/dist/notifications/index.es.js +2 -2
- package/dist/recurringtransactions/index.es.js +285 -293
- package/dist/settings/index.es.js +249 -252
- package/dist/spending/index.es.js +126 -138
- package/dist/transactions/index.es.js +73 -77
- package/dist/trends/index.es.js +588 -601
- package/dist/{useAccountDisplayName-Cjx8YmKK.mjs → useAccountDisplayName-CMMlIOXF.mjs} +2 -2
- package/dist/{useInsightsEnabled-B7dxpDrX.mjs → useInsightsEnabled-CNjP5cfR.mjs} +1 -1
- package/package.json +1 -1
- package/dist/common/hooks/useWidgetLoadTimer.d.ts +0 -6
- package/dist/useWidgetLoadTimer-C1NBkyLd.mjs +0 -23
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { S as
|
|
1
|
+
import { S as Kt, a as Xt } from "../SettingsStore-krIRNwHK.mjs";
|
|
2
2
|
import { jsxs as c, Fragment as q, jsx as e } from "react/jsx-runtime";
|
|
3
|
-
import
|
|
3
|
+
import u from "react";
|
|
4
4
|
import { observer as D } from "mobx-react-lite";
|
|
5
5
|
import h from "@mui/material/Stack";
|
|
6
6
|
import ue from "@mui/material/Tab";
|
|
@@ -15,37 +15,36 @@ import { useTheme as xe, alpha as U } from "@mui/material/styles";
|
|
|
15
15
|
import F from "@mui/material/Box";
|
|
16
16
|
import Q from "@mui/material/Button";
|
|
17
17
|
import I from "@mui/material/TextField";
|
|
18
|
-
import { H3 as J, P as L, Text as
|
|
19
|
-
import { V as Ce, a as De, N as G } from "../NotificationSettings-
|
|
20
|
-
import { A as
|
|
21
|
-
import { u as
|
|
18
|
+
import { H3 as J, P as L, Text as v, Icon as M, ChevronRightIcon as ve } from "@mxenabled/mxui";
|
|
19
|
+
import { V as Ce, a as De, N as G } from "../NotificationSettings-CNmJWVeI.mjs";
|
|
20
|
+
import { A as qt, B as Qt, I as Zt } from "../NotificationSettings-CNmJWVeI.mjs";
|
|
21
|
+
import { u as k, a as W, s as A, p as Se, b as Z, m as ee, n as te } from "../hooks-C41HAxM5.mjs";
|
|
22
22
|
import { u as H } from "../useScreenSize-B6JyS_Lj.mjs";
|
|
23
23
|
import { D as $ } from "../Dialog-BPTr3qHE.mjs";
|
|
24
|
-
import { formatDistanceToNow as
|
|
25
|
-
import { fromUnixTime as
|
|
24
|
+
import { formatDistanceToNow as oe } from "date-fns/formatDistanceToNow";
|
|
25
|
+
import { fromUnixTime as ne } from "date-fns/fromUnixTime";
|
|
26
26
|
import R from "@mui/material/styles/useTheme";
|
|
27
27
|
import V from "@mui/material/IconButton";
|
|
28
|
-
import { DataGridPro as
|
|
28
|
+
import { DataGridPro as ke } from "@mui/x-data-grid-pro";
|
|
29
29
|
import { H as O } from "../HeaderCell-DjuifqHJ.mjs";
|
|
30
|
-
import { b as
|
|
31
|
-
import
|
|
30
|
+
import { b as N } from "../Localization-2MODESHW.mjs";
|
|
31
|
+
import we from "@mui/material/Accordion";
|
|
32
32
|
import Te from "@mui/material/AccordionDetails";
|
|
33
33
|
import Ie from "@mui/material/AccordionSummary";
|
|
34
|
-
import { L as
|
|
34
|
+
import { L as re } from "../Loader-DUaFpDGv.mjs";
|
|
35
35
|
import Ae from "@mui/material/List";
|
|
36
36
|
import j from "@mui/material/Divider";
|
|
37
37
|
import Ee from "@mui/material/ListSubheader";
|
|
38
|
-
import { a as Re, u as Pe } from "../CategorySelectorDrawer-
|
|
38
|
+
import { a as Re, u as Pe } from "../CategorySelectorDrawer-DqJK_rrL.mjs";
|
|
39
39
|
import Be from "@mui/material/ListItem";
|
|
40
|
-
import
|
|
41
|
-
import
|
|
40
|
+
import Me from "@mui/material/ListItemButton";
|
|
41
|
+
import Ne from "@mui/material/ListItemIcon";
|
|
42
42
|
import Le from "@mui/material/ListItemText";
|
|
43
43
|
import { D as He } from "../Drawer-BEtCk82g.mjs";
|
|
44
|
-
import {
|
|
45
|
-
import {
|
|
46
|
-
import { W as K } from "../WidgetContainer-CaPjoWeE.mjs";
|
|
44
|
+
import { H as Oe } from "../Help-BnPXM_N2.mjs";
|
|
45
|
+
import { W as K } from "../WidgetContainer-6dsjtOVg.mjs";
|
|
47
46
|
const Ue = ({ availableWidth: t, handleOnLeavClick: a }) => {
|
|
48
|
-
const o = xe(), { common:
|
|
47
|
+
const o = xe(), { common: n, settings: r } = k(), { isDesktop: d, isMobile: l, isSmallMobile: i, isTablet: s } = H(t), { config: b } = W(), { updateUser: _ } = A(), { user: m } = Se(), [p, S] = u.useState({
|
|
49
48
|
first_name: m.first_name,
|
|
50
49
|
last_name: m.last_name,
|
|
51
50
|
email: m.email,
|
|
@@ -53,52 +52,52 @@ const Ue = ({ availableWidth: t, handleOnLeavClick: a }) => {
|
|
|
53
52
|
birthday: m.birthday,
|
|
54
53
|
postal_code: m.postal_code,
|
|
55
54
|
credit_score: m.credit_score
|
|
56
|
-
}), [
|
|
57
|
-
|
|
55
|
+
}), [C, w] = u.useState(!1), [T, x] = u.useState(!1), g = u.useRef(null), z = p.email && !m.email_is_verified && !C, Y = p.phone && !m.phone_is_verified && !C;
|
|
56
|
+
u.useEffect(() => {
|
|
58
57
|
if (a) {
|
|
59
58
|
const f = (P) => {
|
|
60
|
-
|
|
59
|
+
g.current && !g.current.contains(P.target) && C && x(!0);
|
|
61
60
|
};
|
|
62
61
|
return document.addEventListener("mousedown", f), () => {
|
|
63
62
|
document.removeEventListener("mousedown", f);
|
|
64
63
|
};
|
|
65
64
|
}
|
|
66
|
-
}, [
|
|
65
|
+
}, [C]);
|
|
67
66
|
const ae = () => {
|
|
68
|
-
if (
|
|
69
|
-
const f = new Date(
|
|
67
|
+
if (p.birthday) {
|
|
68
|
+
const f = new Date(p.birthday * 1e3), P = f.getUTCFullYear(), de = f.getUTCMonth(), me = f.getUTCDate();
|
|
70
69
|
return new Date(P, de, me);
|
|
71
70
|
}
|
|
72
71
|
}, le = async () => {
|
|
73
|
-
await _({ ...m, ...
|
|
72
|
+
await _({ ...m, ...p }), w(!1);
|
|
74
73
|
}, se = () => {
|
|
75
|
-
|
|
74
|
+
x(!1), a && a();
|
|
76
75
|
}, ce = () => {
|
|
77
|
-
|
|
76
|
+
x(!1);
|
|
78
77
|
}, E = (f) => {
|
|
79
78
|
const P = {
|
|
80
|
-
...
|
|
79
|
+
...p,
|
|
81
80
|
...f
|
|
82
81
|
};
|
|
83
|
-
S(P),
|
|
82
|
+
S(P), w(JSON.stringify({ ...m, ...P }) !== JSON.stringify(m));
|
|
84
83
|
};
|
|
85
84
|
return /* @__PURE__ */ c(q, { children: [
|
|
86
85
|
/* @__PURE__ */ c(
|
|
87
86
|
F,
|
|
88
87
|
{
|
|
89
88
|
component: "form",
|
|
90
|
-
ref:
|
|
89
|
+
ref: g,
|
|
91
90
|
sx: {
|
|
92
91
|
backgroundColor: "background.paper",
|
|
93
92
|
p: 24,
|
|
94
|
-
width:
|
|
93
|
+
width: i ? 320 : s ? 680 : d ? 990 : 400,
|
|
95
94
|
"& .MuiTextField-root": {
|
|
96
|
-
width:
|
|
95
|
+
width: i ? 272 : s ? 328 : d ? 483 : 352
|
|
97
96
|
}
|
|
98
97
|
},
|
|
99
98
|
children: [
|
|
100
|
-
/* @__PURE__ */ e(J, { children:
|
|
101
|
-
/* @__PURE__ */ e(L, { variant: "Body", children:
|
|
99
|
+
/* @__PURE__ */ e(J, { children: r.personal_details }),
|
|
100
|
+
/* @__PURE__ */ e(L, { variant: "Body", children: r.update_information }),
|
|
102
101
|
/* @__PURE__ */ c(
|
|
103
102
|
h,
|
|
104
103
|
{
|
|
@@ -109,16 +108,16 @@ const Ue = ({ availableWidth: t, handleOnLeavClick: a }) => {
|
|
|
109
108
|
/* @__PURE__ */ e(
|
|
110
109
|
I,
|
|
111
110
|
{
|
|
112
|
-
defaultValue:
|
|
113
|
-
label:
|
|
111
|
+
defaultValue: p.first_name,
|
|
112
|
+
label: r.first_name,
|
|
114
113
|
onChange: (f) => E({ first_name: f.target.value })
|
|
115
114
|
}
|
|
116
115
|
),
|
|
117
116
|
/* @__PURE__ */ e(
|
|
118
117
|
I,
|
|
119
118
|
{
|
|
120
|
-
defaultValue:
|
|
121
|
-
label:
|
|
119
|
+
defaultValue: p.last_name,
|
|
120
|
+
label: r.last_name,
|
|
122
121
|
onChange: (f) => E({ last_name: f.target.value })
|
|
123
122
|
}
|
|
124
123
|
)
|
|
@@ -126,23 +125,23 @@ const Ue = ({ availableWidth: t, handleOnLeavClick: a }) => {
|
|
|
126
125
|
}
|
|
127
126
|
),
|
|
128
127
|
/* @__PURE__ */ c(h, { direction: l ? "column" : "row", children: [
|
|
129
|
-
|
|
128
|
+
b.display_email_edit_field_in_settings && /* @__PURE__ */ c(h, { sx: { mb: z ? 20 : 44, mr: l ? 0 : 24 }, children: [
|
|
130
129
|
/* @__PURE__ */ e(
|
|
131
130
|
I,
|
|
132
131
|
{
|
|
133
|
-
defaultValue:
|
|
134
|
-
label:
|
|
132
|
+
defaultValue: p.email,
|
|
133
|
+
label: r.email_address,
|
|
135
134
|
onChange: (f) => E({ email: f.target.value })
|
|
136
135
|
}
|
|
137
136
|
),
|
|
138
137
|
z && /* @__PURE__ */ e(Ce, {})
|
|
139
138
|
] }),
|
|
140
|
-
|
|
139
|
+
b.display_sms_edit_field_in_settings && /* @__PURE__ */ c(h, { sx: { mb: Y ? 20 : 44 }, children: [
|
|
141
140
|
/* @__PURE__ */ e(
|
|
142
141
|
I,
|
|
143
142
|
{
|
|
144
|
-
defaultValue:
|
|
145
|
-
label:
|
|
143
|
+
defaultValue: p.phone,
|
|
144
|
+
label: r.mobile_number,
|
|
146
145
|
onChange: (f) => E({ phone: f.target.value }),
|
|
147
146
|
type: "tel"
|
|
148
147
|
}
|
|
@@ -154,7 +153,7 @@ const Ue = ({ availableWidth: t, handleOnLeavClick: a }) => {
|
|
|
154
153
|
/* @__PURE__ */ e(ye, { dateAdapter: ge, children: /* @__PURE__ */ e(
|
|
155
154
|
be,
|
|
156
155
|
{
|
|
157
|
-
label:
|
|
156
|
+
label: r.birthdate,
|
|
158
157
|
onChange: (f) => E({ birthday: _e(f) }),
|
|
159
158
|
slotProps: {
|
|
160
159
|
nextIconButton: {
|
|
@@ -183,8 +182,8 @@ const Ue = ({ availableWidth: t, handleOnLeavClick: a }) => {
|
|
|
183
182
|
/* @__PURE__ */ e(
|
|
184
183
|
I,
|
|
185
184
|
{
|
|
186
|
-
defaultValue:
|
|
187
|
-
label:
|
|
185
|
+
defaultValue: p.postal_code,
|
|
186
|
+
label: r.zip_code,
|
|
188
187
|
onChange: (f) => E({ postal_code: f.target.value })
|
|
189
188
|
}
|
|
190
189
|
)
|
|
@@ -193,8 +192,8 @@ const Ue = ({ availableWidth: t, handleOnLeavClick: a }) => {
|
|
|
193
192
|
/* @__PURE__ */ e(
|
|
194
193
|
I,
|
|
195
194
|
{
|
|
196
|
-
defaultValue:
|
|
197
|
-
label:
|
|
195
|
+
defaultValue: p.credit_score,
|
|
196
|
+
label: r.credit_score,
|
|
198
197
|
onChange: (f) => E({ credit_score: Number(f.target.value) }),
|
|
199
198
|
sx: { mb: 44 }
|
|
200
199
|
}
|
|
@@ -202,11 +201,11 @@ const Ue = ({ availableWidth: t, handleOnLeavClick: a }) => {
|
|
|
202
201
|
/* @__PURE__ */ e(
|
|
203
202
|
Q,
|
|
204
203
|
{
|
|
205
|
-
disabled: !
|
|
204
|
+
disabled: !C,
|
|
206
205
|
onClick: le,
|
|
207
|
-
sx: { width:
|
|
206
|
+
sx: { width: i ? 272 : 124 },
|
|
208
207
|
variant: "contained",
|
|
209
|
-
children:
|
|
208
|
+
children: n.save_button
|
|
210
209
|
}
|
|
211
210
|
)
|
|
212
211
|
] })
|
|
@@ -216,37 +215,37 @@ const Ue = ({ availableWidth: t, handleOnLeavClick: a }) => {
|
|
|
216
215
|
/* @__PURE__ */ e(
|
|
217
216
|
$,
|
|
218
217
|
{
|
|
219
|
-
copy: { title:
|
|
220
|
-
isOpen:
|
|
218
|
+
copy: { title: r.discard_changes },
|
|
219
|
+
isOpen: T,
|
|
221
220
|
onClose: ce,
|
|
222
221
|
onSecondaryAction: se,
|
|
223
|
-
primaryText:
|
|
224
|
-
secondaryText:
|
|
225
|
-
children:
|
|
222
|
+
primaryText: r.keep_editing,
|
|
223
|
+
secondaryText: r.leave,
|
|
224
|
+
children: r.discard_changes_message
|
|
226
225
|
}
|
|
227
226
|
)
|
|
228
227
|
] });
|
|
229
228
|
}, Fe = D(Ue);
|
|
230
|
-
var
|
|
229
|
+
var y = /* @__PURE__ */ ((t) => (t.Delete = "delete", t.Edit = "edit", t.Token = "token", t))(y || {});
|
|
231
230
|
const Ve = ({
|
|
232
231
|
devices: t,
|
|
233
232
|
onClickDeviceEdit: a,
|
|
234
233
|
onClickDeviceDelete: o
|
|
235
234
|
}) => {
|
|
236
|
-
const
|
|
235
|
+
const n = R(), { settings: r } = k(), d = [
|
|
237
236
|
{
|
|
238
237
|
field: "name",
|
|
239
|
-
headerName:
|
|
238
|
+
headerName: r.mobile_devices_column_name,
|
|
240
239
|
renderHeader: O,
|
|
241
|
-
renderCell: (
|
|
242
|
-
/* @__PURE__ */ e(
|
|
240
|
+
renderCell: (i) => /* @__PURE__ */ c(h, { alignItems: "center", direction: "row", gap: 4, children: [
|
|
241
|
+
/* @__PURE__ */ e(v, { variant: "Small", children: i.value }),
|
|
243
242
|
/* @__PURE__ */ e(
|
|
244
243
|
V,
|
|
245
244
|
{
|
|
246
|
-
"aria-label":
|
|
245
|
+
"aria-label": r.mobile_devices_edit_label,
|
|
247
246
|
color: "secondary",
|
|
248
|
-
onClick: () => a(
|
|
249
|
-
children: /* @__PURE__ */ e(
|
|
247
|
+
onClick: () => a(i.row),
|
|
248
|
+
children: /* @__PURE__ */ e(M, { name: "edit" })
|
|
250
249
|
}
|
|
251
250
|
)
|
|
252
251
|
] }),
|
|
@@ -256,7 +255,7 @@ const Ve = ({
|
|
|
256
255
|
},
|
|
257
256
|
{
|
|
258
257
|
field: "device_type",
|
|
259
|
-
headerName:
|
|
258
|
+
headerName: r.mobile_devices_column_type,
|
|
260
259
|
renderHeader: O,
|
|
261
260
|
sortable: !0,
|
|
262
261
|
hideSortIcons: !1,
|
|
@@ -265,9 +264,9 @@ const Ve = ({
|
|
|
265
264
|
},
|
|
266
265
|
{
|
|
267
266
|
field: "created_at",
|
|
268
|
-
headerName:
|
|
267
|
+
headerName: r.mobile_devices_column_added,
|
|
269
268
|
renderHeader: O,
|
|
270
|
-
valueFormatter: (
|
|
269
|
+
valueFormatter: (i) => oe(ne(i), { addSuffix: !0 }),
|
|
271
270
|
sortable: !0,
|
|
272
271
|
hideSortIcons: !1,
|
|
273
272
|
flex: 1,
|
|
@@ -277,26 +276,26 @@ const Ve = ({
|
|
|
277
276
|
field: "delete",
|
|
278
277
|
headerName: "",
|
|
279
278
|
renderHeader: O,
|
|
280
|
-
renderCell: (
|
|
279
|
+
renderCell: (i) => /* @__PURE__ */ e(h, { mr: 4, children: /* @__PURE__ */ e(
|
|
281
280
|
V,
|
|
282
281
|
{
|
|
283
|
-
"aria-label":
|
|
282
|
+
"aria-label": r.mobile_devices_delete_label,
|
|
284
283
|
color: "secondary",
|
|
285
|
-
onClick: () => o(
|
|
286
|
-
children: /* @__PURE__ */ e(
|
|
284
|
+
onClick: () => o(i.row),
|
|
285
|
+
children: /* @__PURE__ */ e(M, { name: "delete" })
|
|
287
286
|
}
|
|
288
287
|
) }),
|
|
289
288
|
sortable: !1,
|
|
290
289
|
hideSortIcons: !1,
|
|
291
290
|
width: 58
|
|
292
291
|
}
|
|
293
|
-
], l =
|
|
294
|
-
id:
|
|
295
|
-
...
|
|
296
|
-
device_type: `${
|
|
292
|
+
], l = u.useMemo(() => t.map((i) => ({
|
|
293
|
+
id: i.guid,
|
|
294
|
+
...i,
|
|
295
|
+
device_type: `${i.make} ${i.model}`
|
|
297
296
|
})), [t]);
|
|
298
297
|
return /* @__PURE__ */ e(F, { sx: { width: "100%" }, children: /* @__PURE__ */ e(
|
|
299
|
-
|
|
298
|
+
ke,
|
|
300
299
|
{
|
|
301
300
|
columns: d,
|
|
302
301
|
disableColumnFilter: !0,
|
|
@@ -313,14 +312,14 @@ const Ve = ({
|
|
|
313
312
|
F,
|
|
314
313
|
{
|
|
315
314
|
sx: {
|
|
316
|
-
backgroundColor:
|
|
315
|
+
backgroundColor: n.palette.background.default,
|
|
317
316
|
display: "flex",
|
|
318
317
|
justifyContent: "flex-end",
|
|
319
318
|
alignItems: "center",
|
|
320
319
|
p: "12px 16px"
|
|
321
320
|
},
|
|
322
|
-
children: /* @__PURE__ */ e(
|
|
323
|
-
|
|
321
|
+
children: /* @__PURE__ */ e(v, { color: n.palette.text.secondary, variant: "Small", children: N(
|
|
322
|
+
r.mobile_devices_count,
|
|
324
323
|
/* @__PURE__ */ e("b", { children: t.length }),
|
|
325
324
|
/* @__PURE__ */ e("b", { children: t.length })
|
|
326
325
|
) })
|
|
@@ -329,16 +328,16 @@ const Ve = ({
|
|
|
329
328
|
},
|
|
330
329
|
sx: {
|
|
331
330
|
border: "1px solid",
|
|
332
|
-
borderColor:
|
|
331
|
+
borderColor: n.palette.border.light,
|
|
333
332
|
borderRadius: "8px",
|
|
334
333
|
"& .MuiDataGrid-columnHeader .MuiIconButton-root": {
|
|
335
|
-
color:
|
|
334
|
+
color: n.palette.primary.main,
|
|
336
335
|
"&:hover": {
|
|
337
|
-
backgroundColor: U(
|
|
336
|
+
backgroundColor: U(n.palette.primary.main, 0.1)
|
|
338
337
|
}
|
|
339
338
|
},
|
|
340
339
|
"& .MuiDataGrid-sortIcon": {
|
|
341
|
-
color:
|
|
340
|
+
color: n.palette.primary.main
|
|
342
341
|
}
|
|
343
342
|
}
|
|
344
343
|
}
|
|
@@ -348,37 +347,37 @@ const Ve = ({
|
|
|
348
347
|
onClickDeviceEdit: a,
|
|
349
348
|
onClickDeviceDelete: o
|
|
350
349
|
}) => {
|
|
351
|
-
const
|
|
350
|
+
const n = R(), { settings: r } = k(), [d, l] = u.useState(!1), i = (s) => (b, _) => {
|
|
352
351
|
l(_ ? s : !1);
|
|
353
352
|
};
|
|
354
353
|
return /* @__PURE__ */ c(h, { mx: -28, sx: { "& .MuiAccordion-root": { mb: 0, mt: 0 } }, children: [
|
|
355
354
|
t.map((s) => /* @__PURE__ */ c(
|
|
356
|
-
|
|
355
|
+
we,
|
|
357
356
|
{
|
|
358
357
|
expanded: d === s.guid,
|
|
359
|
-
onChange:
|
|
358
|
+
onChange: i(s.guid),
|
|
360
359
|
sx: { boxShadow: "none" },
|
|
361
360
|
children: [
|
|
362
361
|
/* @__PURE__ */ e(
|
|
363
362
|
Ie,
|
|
364
363
|
{
|
|
365
|
-
expandIcon: /* @__PURE__ */ e(
|
|
364
|
+
expandIcon: /* @__PURE__ */ e(M, { color: "secondary", name: "keyboard_arrow_down", size: 24 }),
|
|
366
365
|
sx: {
|
|
367
366
|
padding: "14px 24px",
|
|
368
367
|
borderBottom: "1px solid",
|
|
369
|
-
borderColor:
|
|
368
|
+
borderColor: n.palette.border.light
|
|
370
369
|
},
|
|
371
370
|
children: /* @__PURE__ */ c(h, { gap: 4, children: [
|
|
372
|
-
/* @__PURE__ */ e(
|
|
373
|
-
/* @__PURE__ */ e(
|
|
374
|
-
/* @__PURE__ */ e(
|
|
371
|
+
/* @__PURE__ */ e(v, { bold: !0, variant: "Body", children: s.name }),
|
|
372
|
+
/* @__PURE__ */ e(v, { color: n.palette.text.secondary, variant: "Small", children: `${s.make} ${s.model}` }),
|
|
373
|
+
/* @__PURE__ */ e(v, { color: n.palette.text.secondary, variant: "Small", children: oe(ne(s.created_at), { addSuffix: !0 }) })
|
|
375
374
|
] })
|
|
376
375
|
}
|
|
377
376
|
),
|
|
378
377
|
/* @__PURE__ */ c(
|
|
379
378
|
Te,
|
|
380
379
|
{
|
|
381
|
-
sx: { backgroundColor:
|
|
380
|
+
sx: { backgroundColor: n.palette.background.default, p: "0 0 0 24px" },
|
|
382
381
|
children: [
|
|
383
382
|
/* @__PURE__ */ c(
|
|
384
383
|
h,
|
|
@@ -392,11 +391,11 @@ const Ve = ({
|
|
|
392
391
|
py: 16,
|
|
393
392
|
cursor: "pointer",
|
|
394
393
|
borderBottom: "1px solid",
|
|
395
|
-
borderColor:
|
|
394
|
+
borderColor: n.palette.border.light
|
|
396
395
|
},
|
|
397
396
|
children: [
|
|
398
|
-
/* @__PURE__ */ e(V, { "aria-label":
|
|
399
|
-
/* @__PURE__ */ e(
|
|
397
|
+
/* @__PURE__ */ e(V, { "aria-label": r.mobile_devices_edit_label, color: "secondary", children: /* @__PURE__ */ e(M, { name: "edit" }) }),
|
|
398
|
+
/* @__PURE__ */ e(v, { variant: "Body", children: r.mobile_devices_edit_label })
|
|
400
399
|
]
|
|
401
400
|
}
|
|
402
401
|
),
|
|
@@ -413,8 +412,8 @@ const Ve = ({
|
|
|
413
412
|
cursor: "pointer"
|
|
414
413
|
},
|
|
415
414
|
children: [
|
|
416
|
-
/* @__PURE__ */ e(V, { "aria-label":
|
|
417
|
-
/* @__PURE__ */ e(
|
|
415
|
+
/* @__PURE__ */ e(V, { "aria-label": r.mobile_devices_delete_label, color: "secondary", children: /* @__PURE__ */ e(M, { name: "delete" }) }),
|
|
416
|
+
/* @__PURE__ */ e(v, { variant: "Body", children: r.mobile_devices_delete_label })
|
|
418
417
|
]
|
|
419
418
|
}
|
|
420
419
|
)
|
|
@@ -429,13 +428,13 @@ const Ve = ({
|
|
|
429
428
|
F,
|
|
430
429
|
{
|
|
431
430
|
sx: {
|
|
432
|
-
backgroundColor:
|
|
431
|
+
backgroundColor: n.palette.background.default,
|
|
433
432
|
borderTop: "1px solid",
|
|
434
|
-
borderColor:
|
|
433
|
+
borderColor: n.palette.border.light,
|
|
435
434
|
p: "12px 16px"
|
|
436
435
|
},
|
|
437
|
-
children: /* @__PURE__ */ e(
|
|
438
|
-
|
|
436
|
+
children: /* @__PURE__ */ e(v, { color: n.palette.text.secondary, variant: "Small", children: N(
|
|
437
|
+
r.mobile_devices_count,
|
|
439
438
|
/* @__PURE__ */ e("b", { children: t.length }),
|
|
440
439
|
/* @__PURE__ */ e("b", { children: t.length })
|
|
441
440
|
) })
|
|
@@ -446,42 +445,42 @@ const Ve = ({
|
|
|
446
445
|
dialogType: t,
|
|
447
446
|
isOpen: a,
|
|
448
447
|
onClose: o,
|
|
449
|
-
device:
|
|
450
|
-
deviceToken:
|
|
448
|
+
device: n,
|
|
449
|
+
deviceToken: r = ""
|
|
451
450
|
}) => {
|
|
452
|
-
const d = R(), { common: l, settings:
|
|
453
|
-
|
|
454
|
-
|
|
455
|
-
}, [
|
|
456
|
-
const
|
|
451
|
+
const d = R(), { common: l, settings: i } = k(), { updateDevice: s, deleteDevice: b, setAlert: _, loadDevices: m } = A(), [p, S] = u.useState("");
|
|
452
|
+
u.useEffect(() => {
|
|
453
|
+
n && S(n.name);
|
|
454
|
+
}, [n, t]);
|
|
455
|
+
const C = () => {
|
|
457
456
|
switch (t) {
|
|
458
|
-
case
|
|
459
|
-
return
|
|
460
|
-
case
|
|
461
|
-
return
|
|
457
|
+
case y.Edit:
|
|
458
|
+
return i.mobile_devices_edit_label;
|
|
459
|
+
case y.Delete:
|
|
460
|
+
return i.mobile_devices_delete_label;
|
|
462
461
|
default:
|
|
463
462
|
return "";
|
|
464
463
|
}
|
|
465
|
-
},
|
|
464
|
+
}, w = () => {
|
|
466
465
|
switch (t) {
|
|
467
|
-
case
|
|
466
|
+
case y.Token:
|
|
468
467
|
return l.done_button;
|
|
469
|
-
case
|
|
468
|
+
case y.Edit:
|
|
470
469
|
return l.save_button;
|
|
471
|
-
case
|
|
470
|
+
case y.Delete:
|
|
472
471
|
return l.delete_button;
|
|
473
472
|
default:
|
|
474
473
|
return "";
|
|
475
474
|
}
|
|
476
|
-
},
|
|
477
|
-
const
|
|
475
|
+
}, T = () => {
|
|
476
|
+
const g = {
|
|
478
477
|
"& .MuiDialogContent-root": {
|
|
479
478
|
width: 400,
|
|
480
479
|
pt: 0
|
|
481
480
|
}
|
|
482
481
|
};
|
|
483
|
-
return t ===
|
|
484
|
-
...
|
|
482
|
+
return t === y.Token ? {
|
|
483
|
+
...g,
|
|
485
484
|
"& .MuiToolbar-root:last-child": {
|
|
486
485
|
padding: "32px 60px 48px",
|
|
487
486
|
justifyContent: "center"
|
|
@@ -493,52 +492,52 @@ const Ve = ({
|
|
|
493
492
|
flex: 1
|
|
494
493
|
}
|
|
495
494
|
} : {
|
|
496
|
-
...
|
|
495
|
+
...g,
|
|
497
496
|
"& .MuiToolbar-root:last-child": {
|
|
498
497
|
gap: 8,
|
|
499
498
|
padding: 24,
|
|
500
499
|
justifyContent: "flex-end"
|
|
501
500
|
},
|
|
502
|
-
...t ===
|
|
501
|
+
...t === y.Delete && {
|
|
503
502
|
"& .MuiTypography-Body": {
|
|
504
503
|
padding: 0
|
|
505
504
|
}
|
|
506
505
|
}
|
|
507
506
|
};
|
|
508
|
-
},
|
|
509
|
-
if (t ===
|
|
510
|
-
const
|
|
511
|
-
(await s(
|
|
512
|
-
|
|
507
|
+
}, x = async () => {
|
|
508
|
+
if (t === y.Token && o(), t === y.Edit && n) {
|
|
509
|
+
const g = { ...n, name: p };
|
|
510
|
+
(await s(g)).success ? (_(i.mobile_devices_edit_success, "success"), m()) : _(
|
|
511
|
+
N(i.mobile_devices_edit_error, n.name),
|
|
513
512
|
"error"
|
|
514
513
|
), o();
|
|
515
514
|
}
|
|
516
|
-
t ===
|
|
517
|
-
|
|
515
|
+
t === y.Delete && n && ((await b(n.guid)).success ? (_(
|
|
516
|
+
N(i.mobile_devices_delete_success, n.name),
|
|
518
517
|
"success"
|
|
519
518
|
), m()) : _(
|
|
520
|
-
|
|
519
|
+
N(i.mobile_devices_delete_error, n.name),
|
|
521
520
|
"error"
|
|
522
521
|
), o());
|
|
523
522
|
};
|
|
524
523
|
return /* @__PURE__ */ c(
|
|
525
524
|
$,
|
|
526
525
|
{
|
|
527
|
-
copy: { title:
|
|
526
|
+
copy: { title: C() },
|
|
528
527
|
isOpen: a,
|
|
529
528
|
onClose: o,
|
|
530
|
-
onPrimaryAction:
|
|
529
|
+
onPrimaryAction: x,
|
|
531
530
|
onSecondaryAction: o,
|
|
532
|
-
primaryColor: t ===
|
|
533
|
-
primaryText:
|
|
534
|
-
secondaryText: t ===
|
|
535
|
-
sx:
|
|
531
|
+
primaryColor: t === y.Delete ? "error" : void 0,
|
|
532
|
+
primaryText: w(),
|
|
533
|
+
secondaryText: t === y.Token ? l.back : l.cancel_button,
|
|
534
|
+
sx: T(),
|
|
536
535
|
children: [
|
|
537
|
-
t ===
|
|
538
|
-
/* @__PURE__ */ e(
|
|
539
|
-
/* @__PURE__ */ e(
|
|
536
|
+
t === y.Token && /* @__PURE__ */ c(h, { spacing: 16, sx: { px: 40, textAlign: "center", width: "100%" }, children: [
|
|
537
|
+
/* @__PURE__ */ e(v, { bold: !0, truncate: !1, variant: "Body", children: i.mobile_devices_access_label }),
|
|
538
|
+
/* @__PURE__ */ e(v, { truncate: !1, variant: "Small", children: i.mobile_devices_access_info_1 }),
|
|
540
539
|
/* @__PURE__ */ e(
|
|
541
|
-
|
|
540
|
+
v,
|
|
542
541
|
{
|
|
543
542
|
sx: {
|
|
544
543
|
border: `1px solid ${d.palette.border.light}`,
|
|
@@ -546,32 +545,32 @@ const Ve = ({
|
|
|
546
545
|
p: "16px 32px"
|
|
547
546
|
},
|
|
548
547
|
variant: "H1",
|
|
549
|
-
children:
|
|
548
|
+
children: r
|
|
550
549
|
}
|
|
551
550
|
),
|
|
552
|
-
/* @__PURE__ */ e(
|
|
551
|
+
/* @__PURE__ */ e(v, { truncate: !1, variant: "Small", children: i.mobile_devices_access_info_2 })
|
|
553
552
|
] }),
|
|
554
|
-
t ===
|
|
555
|
-
t ===
|
|
553
|
+
t === y.Edit && /* @__PURE__ */ e(h, { children: /* @__PURE__ */ e(I, { onChange: (g) => S(g.target.value), value: p }) }),
|
|
554
|
+
t === y.Delete && /* @__PURE__ */ e(L, { children: i.mobile_devices_delete_info })
|
|
556
555
|
]
|
|
557
556
|
}
|
|
558
557
|
);
|
|
559
558
|
}, ze = D($e), Ge = D(() => {
|
|
560
|
-
const { isMobile: t } = H(), { settings: a } =
|
|
561
|
-
|
|
562
|
-
|
|
563
|
-
}, [
|
|
564
|
-
const
|
|
565
|
-
const
|
|
566
|
-
|
|
567
|
-
},
|
|
568
|
-
m(
|
|
569
|
-
},
|
|
570
|
-
m(
|
|
571
|
-
},
|
|
572
|
-
|
|
559
|
+
const { isMobile: t } = H(), { settings: a } = k(), { isCopyLoaded: o, isInitialized: n } = Z(), { setAlert: r, devices: d, loadDevices: l, generateDeviceToken: i } = A(), [s, b] = u.useState({ open: !1, type: "" }), [_, m] = u.useState(), [p, S] = u.useState("");
|
|
560
|
+
u.useEffect(() => {
|
|
561
|
+
n && l();
|
|
562
|
+
}, [n]);
|
|
563
|
+
const C = async () => {
|
|
564
|
+
const g = await i();
|
|
565
|
+
g ? (S(g), b({ open: !0, type: y.Token })) : r(a.mobile_devices_access_error, "error");
|
|
566
|
+
}, w = (g) => {
|
|
567
|
+
m(g), b({ open: !0, type: y.Edit });
|
|
568
|
+
}, T = (g) => {
|
|
569
|
+
m(g), b({ open: !0, type: y.Delete });
|
|
570
|
+
}, x = () => {
|
|
571
|
+
b({ open: !1, type: "" }), m(void 0);
|
|
573
572
|
};
|
|
574
|
-
return !o || !
|
|
573
|
+
return !o || !n ? /* @__PURE__ */ e(re, {}) : /* @__PURE__ */ c(
|
|
575
574
|
h,
|
|
576
575
|
{
|
|
577
576
|
sx: {
|
|
@@ -588,56 +587,56 @@ const Ve = ({
|
|
|
588
587
|
We,
|
|
589
588
|
{
|
|
590
589
|
devices: d,
|
|
591
|
-
onClickDeviceDelete:
|
|
592
|
-
onClickDeviceEdit:
|
|
590
|
+
onClickDeviceDelete: T,
|
|
591
|
+
onClickDeviceEdit: w
|
|
593
592
|
}
|
|
594
593
|
) : /* @__PURE__ */ e(
|
|
595
594
|
Ve,
|
|
596
595
|
{
|
|
597
596
|
devices: d,
|
|
598
|
-
onClickDeviceDelete:
|
|
599
|
-
onClickDeviceEdit:
|
|
597
|
+
onClickDeviceDelete: T,
|
|
598
|
+
onClickDeviceEdit: w
|
|
600
599
|
}
|
|
601
600
|
),
|
|
602
601
|
/* @__PURE__ */ c(h, { sx: { alignItems: "center", px: 24, py: 12, gap: 4 }, children: [
|
|
603
|
-
/* @__PURE__ */ e(
|
|
602
|
+
/* @__PURE__ */ e(v, { bold: !0, variant: "Body", children: a.mobile_devices_access_title }),
|
|
604
603
|
/* @__PURE__ */ e(L, { align: "center", variant: "Small", children: a.mobile_devices_access_description }),
|
|
605
|
-
/* @__PURE__ */ e(Q, { onClick:
|
|
604
|
+
/* @__PURE__ */ e(Q, { onClick: C, variant: "text", children: a.mobile_devices_access_cta })
|
|
606
605
|
] }),
|
|
607
606
|
/* @__PURE__ */ e(
|
|
608
607
|
ze,
|
|
609
608
|
{
|
|
610
609
|
device: _,
|
|
611
|
-
deviceToken:
|
|
610
|
+
deviceToken: p,
|
|
612
611
|
dialogType: s.type,
|
|
613
612
|
isOpen: s.open,
|
|
614
|
-
onClose:
|
|
613
|
+
onClose: x
|
|
615
614
|
}
|
|
616
615
|
)
|
|
617
616
|
]
|
|
618
617
|
}
|
|
619
618
|
);
|
|
620
619
|
}), je = Ge, X = D(
|
|
621
|
-
({ onClick: t, primaryText: a, secondaryText: o, sx:
|
|
622
|
-
const
|
|
623
|
-
return /* @__PURE__ */ e(Be, { sx: { bgcolor:
|
|
620
|
+
({ onClick: t, primaryText: a, secondaryText: o, sx: n }) => {
|
|
621
|
+
const r = R();
|
|
622
|
+
return /* @__PURE__ */ e(Be, { sx: { bgcolor: r.palette.background.paper }, children: /* @__PURE__ */ c(Me, { alignItems: "flex-start", onClick: t, sx: n, children: [
|
|
624
623
|
/* @__PURE__ */ e(Le, { primary: a, secondary: o }),
|
|
625
|
-
/* @__PURE__ */ e(
|
|
624
|
+
/* @__PURE__ */ e(Ne, { children: /* @__PURE__ */ e(ve, {}) })
|
|
626
625
|
] }) });
|
|
627
626
|
}
|
|
628
627
|
), Je = D(() => {
|
|
629
|
-
const { settings: t } =
|
|
628
|
+
const { settings: t } = k(), { categories: a } = ee(), { selectedRule: o, updateRuleCategory: n } = A(), [r, d] = u.useState(!1), l = () => {
|
|
630
629
|
d(!1);
|
|
631
|
-
},
|
|
630
|
+
}, i = () => {
|
|
632
631
|
d(!0);
|
|
633
|
-
}, s = (_) => a.find((m) => m.guid === _)?.name,
|
|
634
|
-
o && o.category_guid !== _ && (o.category_guid = _, await
|
|
632
|
+
}, s = (_) => a.find((m) => m.guid === _)?.name, b = async (_) => {
|
|
633
|
+
o && o.category_guid !== _ && (o.category_guid = _, await n(o)), l();
|
|
635
634
|
};
|
|
636
|
-
return /* @__PURE__ */ c(
|
|
635
|
+
return /* @__PURE__ */ c(u.Fragment, { children: [
|
|
637
636
|
/* @__PURE__ */ e(
|
|
638
637
|
X,
|
|
639
638
|
{
|
|
640
|
-
onClick:
|
|
639
|
+
onClick: i,
|
|
641
640
|
primaryText: o?.category_guid ? s(o.category_guid) : "",
|
|
642
641
|
secondaryText: t.category
|
|
643
642
|
}
|
|
@@ -647,24 +646,24 @@ const Ve = ({
|
|
|
647
646
|
{
|
|
648
647
|
initialSelected: o?.category_guid ? o.category_guid : void 0,
|
|
649
648
|
onClose: l,
|
|
650
|
-
onSelect:
|
|
651
|
-
showDrawer:
|
|
649
|
+
onSelect: b,
|
|
650
|
+
showDrawer: r,
|
|
652
651
|
title: t.select_category
|
|
653
652
|
}
|
|
654
653
|
)
|
|
655
654
|
] });
|
|
656
655
|
}), Ke = D(() => {
|
|
657
|
-
const { common: t, settings: a } =
|
|
656
|
+
const { common: t, settings: a } = k(), { selectedRule: o, updateRulePayee: n } = A(), r = R(), [d, l] = u.useState(!1), i = o?.description ? o.description : o?.match_description, [s, b] = u.useState(i || ""), _ = () => {
|
|
658
657
|
l(!0);
|
|
659
658
|
}, m = async () => {
|
|
660
|
-
s !==
|
|
659
|
+
s !== i && o && (o.description = s, await n(o), l(!1));
|
|
661
660
|
};
|
|
662
|
-
return /* @__PURE__ */ c(
|
|
661
|
+
return /* @__PURE__ */ c(u.Fragment, { children: [
|
|
663
662
|
/* @__PURE__ */ e(
|
|
664
663
|
X,
|
|
665
664
|
{
|
|
666
665
|
onClick: _,
|
|
667
|
-
primaryText:
|
|
666
|
+
primaryText: i,
|
|
668
667
|
secondaryText: a.payee
|
|
669
668
|
}
|
|
670
669
|
),
|
|
@@ -680,12 +679,12 @@ const Ve = ({
|
|
|
680
679
|
secondaryText: t.cancel_button,
|
|
681
680
|
sx: {
|
|
682
681
|
"& .MuiDialogContent-root": { pt: 0, width: 400 },
|
|
683
|
-
path: { fill:
|
|
682
|
+
path: { fill: r.palette.secondary.darker }
|
|
684
683
|
},
|
|
685
684
|
children: /* @__PURE__ */ e(
|
|
686
685
|
I,
|
|
687
686
|
{
|
|
688
|
-
onChange: (
|
|
687
|
+
onChange: (p) => b(p.target.value),
|
|
689
688
|
sx: { width: 352 },
|
|
690
689
|
value: s
|
|
691
690
|
}
|
|
@@ -694,18 +693,18 @@ const Ve = ({
|
|
|
694
693
|
)
|
|
695
694
|
] });
|
|
696
695
|
}), Xe = D(({ onClose: t, onDelete: a, isOpen: o }) => {
|
|
697
|
-
const { common:
|
|
696
|
+
const { common: n, settings: r } = k(), d = R();
|
|
698
697
|
return /* @__PURE__ */ e(
|
|
699
698
|
$,
|
|
700
699
|
{
|
|
701
|
-
copy: { title:
|
|
700
|
+
copy: { title: r.delete_rule },
|
|
702
701
|
isOpen: o,
|
|
703
702
|
onClose: t,
|
|
704
703
|
onPrimaryAction: a,
|
|
705
704
|
onSecondaryAction: t,
|
|
706
705
|
primaryColor: "error",
|
|
707
|
-
primaryText:
|
|
708
|
-
secondaryText:
|
|
706
|
+
primaryText: n.delete_button,
|
|
707
|
+
secondaryText: n.cancel_button,
|
|
709
708
|
sx: {
|
|
710
709
|
"& .MuiButton-outlined": {
|
|
711
710
|
borderColor: d.palette.border.main,
|
|
@@ -714,12 +713,12 @@ const Ve = ({
|
|
|
714
713
|
"& .MuiDialogContent-root": { pt: 0, width: 400 },
|
|
715
714
|
path: { fill: d.palette.secondary.darker }
|
|
716
715
|
},
|
|
717
|
-
children: /* @__PURE__ */ e(
|
|
716
|
+
children: /* @__PURE__ */ e(v, { truncate: !1, variant: "Small", children: r.delete_rule_confirm })
|
|
718
717
|
}
|
|
719
718
|
);
|
|
720
719
|
}), Ye = D(
|
|
721
720
|
({ isOpen: t, onClose: a, onDelete: o }) => {
|
|
722
|
-
const { common:
|
|
721
|
+
const { common: n, settings: r } = k(), d = R(), [l, i] = u.useState(!1);
|
|
723
722
|
return /* @__PURE__ */ c(
|
|
724
723
|
He,
|
|
725
724
|
{
|
|
@@ -727,16 +726,16 @@ const Ve = ({
|
|
|
727
726
|
isOpen: t,
|
|
728
727
|
onClose: a,
|
|
729
728
|
onPrimaryAction: () => {
|
|
730
|
-
|
|
729
|
+
i(!0);
|
|
731
730
|
},
|
|
732
731
|
primaryColor: "error",
|
|
733
|
-
primaryText:
|
|
732
|
+
primaryText: n.delete_button,
|
|
734
733
|
sx: {
|
|
735
734
|
"& .MuiToolbar-root": { borderTop: `1px solid ${d.palette.border.light}` }
|
|
736
735
|
},
|
|
737
|
-
title:
|
|
736
|
+
title: r.edit_rule,
|
|
738
737
|
children: [
|
|
739
|
-
/* @__PURE__ */ e(Ee, { children: /* @__PURE__ */ e(
|
|
738
|
+
/* @__PURE__ */ e(Ee, { children: /* @__PURE__ */ e(v, { bold: !0, variant: "XSmall", children: r.details }) }),
|
|
740
739
|
/* @__PURE__ */ e(Ke, {}),
|
|
741
740
|
/* @__PURE__ */ e(j, { sx: { ml: 24 } }),
|
|
742
741
|
/* @__PURE__ */ e(Je, {}),
|
|
@@ -745,7 +744,7 @@ const Ve = ({
|
|
|
745
744
|
Xe,
|
|
746
745
|
{
|
|
747
746
|
isOpen: l,
|
|
748
|
-
onClose: () =>
|
|
747
|
+
onClose: () => i(!1),
|
|
749
748
|
onDelete: o
|
|
750
749
|
}
|
|
751
750
|
)
|
|
@@ -754,48 +753,47 @@ const Ve = ({
|
|
|
754
753
|
);
|
|
755
754
|
}
|
|
756
755
|
), qe = D(({ rule: t }) => {
|
|
757
|
-
const { categories: a } = ee(), { setSelectedGuid: o } = Pe(), { deleteTransactionRule:
|
|
758
|
-
s(!1), o(null),
|
|
756
|
+
const { categories: a } = ee(), { setSelectedGuid: o } = Pe(), { deleteTransactionRule: n, setSelectedRule: r } = A(), { isDesktop: d, isTablet: l } = H(), [i, s] = u.useState(!1), b = () => {
|
|
757
|
+
s(!1), o(null), r(void 0);
|
|
759
758
|
}, _ = async () => {
|
|
760
|
-
await
|
|
759
|
+
await n(), b();
|
|
761
760
|
}, m = () => {
|
|
762
|
-
s(!0),
|
|
763
|
-
},
|
|
764
|
-
return /* @__PURE__ */ c(
|
|
761
|
+
s(!0), r(t);
|
|
762
|
+
}, p = (S) => a.find((C) => C.guid === S)?.name;
|
|
763
|
+
return /* @__PURE__ */ c(u.Fragment, { children: [
|
|
765
764
|
/* @__PURE__ */ e(
|
|
766
765
|
X,
|
|
767
766
|
{
|
|
768
767
|
onClick: m,
|
|
769
768
|
primaryText: t.description ? t.description : t.match_description,
|
|
770
|
-
secondaryText: t.category_guid ?
|
|
769
|
+
secondaryText: t.category_guid ? p(t.category_guid) : ""
|
|
771
770
|
}
|
|
772
771
|
),
|
|
773
772
|
/* @__PURE__ */ e(j, { sx: { ml: l || d ? 0 : 24 } }),
|
|
774
|
-
/* @__PURE__ */ e(Ye, { isOpen:
|
|
773
|
+
/* @__PURE__ */ e(Ye, { isOpen: i, onClose: b, onDelete: _ })
|
|
775
774
|
] });
|
|
776
775
|
}), Qe = D(() => {
|
|
777
|
-
const { settings: t } =
|
|
778
|
-
return
|
|
779
|
-
|
|
780
|
-
|
|
781
|
-
|
|
782
|
-
a().finally(() => n(!0));
|
|
776
|
+
const { settings: t } = k(), { loadTransactionRules: a, transactionRules: o } = A(), { onLoad: n } = te();
|
|
777
|
+
return u.useEffect(() => {
|
|
778
|
+
a().finally(() => {
|
|
779
|
+
n?.("TransactionRulesTab");
|
|
780
|
+
});
|
|
783
781
|
}, []), /* @__PURE__ */ c(h, { sx: { gap: 24, py: 24 }, children: [
|
|
784
782
|
/* @__PURE__ */ c(h, { sx: { px: 24 }, children: [
|
|
785
783
|
/* @__PURE__ */ e(J, { children: t.transaction_rules_label }),
|
|
786
784
|
/* @__PURE__ */ e(L, { variant: "Body", children: t.transaction_rules_description })
|
|
787
785
|
] }),
|
|
788
|
-
/* @__PURE__ */ e(Ae, { children: o.map((
|
|
786
|
+
/* @__PURE__ */ e(Ae, { children: o.map((r, d) => /* @__PURE__ */ e(qe, { rule: r }, d)) })
|
|
789
787
|
] });
|
|
790
|
-
}),
|
|
788
|
+
}), ie = Qe, Ze = D(({ selectedTab: t }) => {
|
|
791
789
|
const { alert: a, setAlert: o } = A(), {
|
|
792
|
-
config: { display_user_profile_in_settings:
|
|
790
|
+
config: { display_user_profile_in_settings: n }
|
|
793
791
|
} = W();
|
|
794
792
|
return /* @__PURE__ */ c(q, { children: [
|
|
795
793
|
t === B.Profile && /* @__PURE__ */ e(Fe, {}),
|
|
796
794
|
t === B.Devices && /* @__PURE__ */ e(je, {}),
|
|
797
|
-
t === B.Notifications && /* @__PURE__ */ e(G, { showPersonalDetails: !
|
|
798
|
-
t === B.TransactionRules && /* @__PURE__ */ e(
|
|
795
|
+
t === B.Notifications && /* @__PURE__ */ e(G, { showPersonalDetails: !n }),
|
|
796
|
+
t === B.TransactionRules && /* @__PURE__ */ e(ie, {}),
|
|
799
797
|
t === B.Help && /* @__PURE__ */ e(h, { sx: { px: 24 }, children: /* @__PURE__ */ e(Oe, {}) }),
|
|
800
798
|
/* @__PURE__ */ e(
|
|
801
799
|
fe,
|
|
@@ -820,26 +818,25 @@ const Ve = ({
|
|
|
820
818
|
] });
|
|
821
819
|
});
|
|
822
820
|
var B = /* @__PURE__ */ ((t) => (t[t.Profile = 0] = "Profile", t[t.Devices = 1] = "Devices", t[t.Notifications = 2] = "Notifications", t[t.TransactionRules = 3] = "TransactionRules", t[t.Help = 4] = "Help", t))(B || {});
|
|
823
|
-
const
|
|
824
|
-
const { settings: o } =
|
|
825
|
-
|
|
826
|
-
|
|
827
|
-
|
|
828
|
-
});
|
|
821
|
+
const $t = D(({ onBackClick: t, sx: a }) => {
|
|
822
|
+
const { settings: o } = k(), { isCopyLoaded: n, isInitialized: r } = Z(), { config: d } = W(), { isMobile: l } = H(), { onLoad: i } = te();
|
|
823
|
+
u.useEffect(() => {
|
|
824
|
+
r && n && i?.("SettingsWidget");
|
|
825
|
+
}, [r, n]);
|
|
829
826
|
const {
|
|
830
|
-
display_user_profile_in_settings:
|
|
831
|
-
display_mobile_devices_in_settings:
|
|
832
|
-
display_notification_settings_in_settings:
|
|
833
|
-
display_user_transaction_rules_in_settings:
|
|
834
|
-
show_help_widget_in_master:
|
|
835
|
-
} = d,
|
|
836
|
-
{ enabled:
|
|
837
|
-
{ enabled:
|
|
838
|
-
{ enabled:
|
|
839
|
-
{ enabled:
|
|
840
|
-
{ enabled:
|
|
841
|
-
],
|
|
842
|
-
return !
|
|
827
|
+
display_user_profile_in_settings: s,
|
|
828
|
+
display_mobile_devices_in_settings: b,
|
|
829
|
+
display_notification_settings_in_settings: _,
|
|
830
|
+
display_user_transaction_rules_in_settings: m,
|
|
831
|
+
show_help_widget_in_master: p
|
|
832
|
+
} = d, S = [
|
|
833
|
+
{ enabled: s, index: 0, label: o?.profile_label },
|
|
834
|
+
{ enabled: b, index: 1, label: o?.mobile_devices_label },
|
|
835
|
+
{ enabled: _, index: 2, label: o?.notifications_label },
|
|
836
|
+
{ enabled: m, index: 3, label: o?.transaction_rules_label },
|
|
837
|
+
{ enabled: p, index: 4, label: o?.help_label }
|
|
838
|
+
], C = S.find((x) => x.enabled), [w, T] = u.useState(C ? C.index : -1);
|
|
839
|
+
return !n || !r ? /* @__PURE__ */ e(re, {}) : /* @__PURE__ */ e(
|
|
843
840
|
K,
|
|
844
841
|
{
|
|
845
842
|
onBackClick: t,
|
|
@@ -849,40 +846,40 @@ const zt = D(({ onBackClick: t, sx: a }) => {
|
|
|
849
846
|
/* @__PURE__ */ e(
|
|
850
847
|
pe,
|
|
851
848
|
{
|
|
852
|
-
onChange: (
|
|
849
|
+
onChange: (x, g) => T(g),
|
|
853
850
|
sx: { bgcolor: "background.paper" },
|
|
854
851
|
textColor: "primary",
|
|
855
|
-
value:
|
|
852
|
+
value: w,
|
|
856
853
|
variant: "scrollable",
|
|
857
|
-
children:
|
|
858
|
-
(
|
|
854
|
+
children: S.map(
|
|
855
|
+
(x) => x.enabled && /* @__PURE__ */ e(ue, { label: x.label, value: x.index }, x.index)
|
|
859
856
|
)
|
|
860
857
|
}
|
|
861
858
|
),
|
|
862
|
-
/* @__PURE__ */ e(Ze, { selectedTab:
|
|
859
|
+
/* @__PURE__ */ e(Ze, { selectedTab: w })
|
|
863
860
|
] })
|
|
864
861
|
}
|
|
865
862
|
);
|
|
866
|
-
}),
|
|
863
|
+
}), zt = D((t) => {
|
|
867
864
|
const { clientConfig: a } = W(), o = a?.master?.deep_link_params?.view;
|
|
868
865
|
return o ? /* @__PURE__ */ e(G, { view: o }) : /* @__PURE__ */ e(K, { ...t, children: /* @__PURE__ */ e(h, { my: 24, children: /* @__PURE__ */ e(G, {}) }) });
|
|
869
|
-
}),
|
|
866
|
+
}), Gt = (t) => {
|
|
870
867
|
const { isMobile: a } = H();
|
|
871
|
-
return /* @__PURE__ */ e(K, { ...t, children: /* @__PURE__ */ e(h, { sx: { mx: a ? 0 : 48, my: 24 }, children: /* @__PURE__ */ e(
|
|
868
|
+
return /* @__PURE__ */ e(K, { ...t, children: /* @__PURE__ */ e(h, { sx: { mx: a ? 0 : 48, my: 24 }, children: /* @__PURE__ */ e(ie, {}) }) });
|
|
872
869
|
};
|
|
873
870
|
export {
|
|
874
|
-
|
|
875
|
-
|
|
871
|
+
qt as AccountNotificationProfiles,
|
|
872
|
+
Qt as BudgetNotificationProfiles,
|
|
876
873
|
je as DeviceTab,
|
|
877
|
-
|
|
874
|
+
Zt as InsightsNotificationProfiles,
|
|
878
875
|
G as NotificationSettings,
|
|
879
|
-
|
|
876
|
+
zt as NotificationSettingsWidget,
|
|
880
877
|
Fe as ProfileTab,
|
|
881
|
-
|
|
882
|
-
|
|
878
|
+
Kt as SettingsApi,
|
|
879
|
+
Xt as SettingsStore,
|
|
883
880
|
B as SettingsTabs,
|
|
884
|
-
|
|
881
|
+
$t as SettingsWidget,
|
|
885
882
|
Ze as SettingsWidgetContents,
|
|
886
|
-
|
|
887
|
-
|
|
883
|
+
ie as TransactionRulesTab,
|
|
884
|
+
Gt as TransactionRulesWidget
|
|
888
885
|
};
|