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