@mx-cartographer/experiences 7.2.15-alpha.sms4 → 7.2.16-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.
@@ -1,105 +1,105 @@
1
- import { S as Jt, a as Kt } from "../SettingsStore-BcgS_Ohv.mjs";
1
+ import { S as Kt, a as Xt } from "../SettingsStore-BcgS_Ohv.mjs";
2
2
  import { jsxs as c, Fragment as q, jsx as e } from "react/jsx-runtime";
3
- import h from "react";
3
+ import u from "react";
4
4
  import { observer as D } from "mobx-react-lite";
5
- import p from "@mui/material/Stack";
6
- import me from "@mui/material/Tab";
7
- import ue from "@mui/material/Tabs";
8
- import pe from "@mui/material/Alert";
9
- import he from "@mui/material/Snackbar";
10
- import { getUnixTime as fe } from "date-fns/getUnixTime";
11
- import { AdapterDateFns as _e } from "@mui/x-date-pickers/AdapterDateFnsV3";
12
- import { DatePicker as ge } from "@mui/x-date-pickers";
13
- import { LocalizationProvider as be } from "@mui/x-date-pickers/LocalizationProvider";
14
- import { useTheme as ye, alpha as U } from "@mui/material/styles";
5
+ import h from "@mui/material/Stack";
6
+ import ue from "@mui/material/Tab";
7
+ import pe from "@mui/material/Tabs";
8
+ import he from "@mui/material/Alert";
9
+ import fe from "@mui/material/Snackbar";
10
+ import { getUnixTime as _e } from "date-fns/getUnixTime";
11
+ import { AdapterDateFns as ge } from "@mui/x-date-pickers/AdapterDateFnsV3";
12
+ import { DatePicker as be } from "@mui/x-date-pickers";
13
+ import { LocalizationProvider as ye } from "@mui/x-date-pickers/LocalizationProvider";
14
+ 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 H, Text as x, Icon as M, ChevronRightIcon as xe } from "@mxenabled/mxui";
19
- import { V as ve, a as Ce, N as G } from "../NotificationSettings-DqrkNMod.mjs";
20
- import { A as Yt, B as qt, I as Qt } from "../NotificationSettings-DqrkNMod.mjs";
21
- import { u as k, a as $, s as A, p as De, b as Z, m as ee } from "../hooks-D6XlXHf4.mjs";
22
- import { u as L } from "../useScreenSize-B6JyS_Lj.mjs";
23
- import { a as W } from "../Dialog-CWW597AF.mjs";
24
- import { formatDistanceToNow as te } from "date-fns/formatDistanceToNow";
25
- import { fromUnixTime as oe } from "date-fns/fromUnixTime";
26
- import P from "@mui/material/styles/useTheme";
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-5i3IywCi.mjs";
20
+ import { A as qt, B as Qt, I as Zt } from "../NotificationSettings-5i3IywCi.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-D6XlXHf4.mjs";
22
+ import { u as H } from "../useScreenSize-B6JyS_Lj.mjs";
23
+ import { a as $ } from "../Dialog-CWW597AF.mjs";
24
+ import { formatDistanceToNow as oe } from "date-fns/formatDistanceToNow";
25
+ import { fromUnixTime as ne } from "date-fns/fromUnixTime";
26
+ import R from "@mui/material/styles/useTheme";
27
27
  import V from "@mui/material/IconButton";
28
- import { DataGridPro as Se } from "@mui/x-data-grid-pro";
28
+ import { DataGridPro as ke } from "@mui/x-data-grid-pro";
29
29
  import { H as O } from "../HeaderCell-DjuifqHJ.mjs";
30
30
  import { b as N } from "../Localization-2MODESHW.mjs";
31
- import ke from "@mui/material/Accordion";
32
- import we from "@mui/material/AccordionDetails";
33
- import Te from "@mui/material/AccordionSummary";
34
- import { L as ne } from "../Loader-DUaFpDGv.mjs";
35
- import Ie from "@mui/material/List";
31
+ import we from "@mui/material/Accordion";
32
+ import Te from "@mui/material/AccordionDetails";
33
+ import Ie from "@mui/material/AccordionSummary";
34
+ import { L as re } from "../Loader-DUaFpDGv.mjs";
35
+ import Ae from "@mui/material/List";
36
36
  import j from "@mui/material/Divider";
37
- import Ae from "@mui/material/ListSubheader";
38
- import { a as Ee, u as Pe } from "../CategorySelectorDrawer-DUe4lH5-.mjs";
39
- import Re from "@mui/material/ListItem";
40
- import Be from "@mui/material/ListItemButton";
41
- import Me from "@mui/material/ListItemIcon";
42
- import Ne from "@mui/material/ListItemText";
37
+ import Ee from "@mui/material/ListSubheader";
38
+ import { a as Re, u as Pe } from "../CategorySelectorDrawer-DUe4lH5-.mjs";
39
+ import Be from "@mui/material/ListItem";
40
+ import Me from "@mui/material/ListItemButton";
41
+ import Ne from "@mui/material/ListItemIcon";
42
+ import Le from "@mui/material/ListItemText";
43
43
  import { D as He } from "../Drawer-kEE73B87.mjs";
44
- import { H as Le } from "../Help-B6dIcujh.mjs";
44
+ import { H as Oe } from "../Help-B6dIcujh.mjs";
45
45
  import { W as K } from "../WidgetContainer-EbrN1oIo.mjs";
46
- const Oe = ({ availableWidth: t, handleOnLeavClick: a }) => {
47
- const o = ye(), { common: n, settings: r } = k(), { isDesktop: m, isMobile: l, isSmallMobile: i, isTablet: s } = L(t), { config: g } = $(), { updateUser: _ } = A(), { user: d } = De(), [u, S] = h.useState({
48
- first_name: d.first_name,
49
- last_name: d.last_name,
50
- email: d.email,
51
- phone: d.phone,
52
- birthday: d.birthday,
53
- postal_code: d.postal_code,
54
- credit_score: d.credit_score
55
- }), [v, w] = h.useState(!1), [C, T] = h.useState(!1), y = h.useRef(null), z = u.email && !d.email_is_verified && !v, Y = u.phone && !d.phone_is_verified && !v;
56
- h.useEffect(() => {
46
+ const Ue = ({ availableWidth: t, handleOnLeavClick: a }) => {
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({
48
+ first_name: m.first_name,
49
+ last_name: m.last_name,
50
+ email: m.email,
51
+ phone: m.phone,
52
+ birthday: m.birthday,
53
+ postal_code: m.postal_code,
54
+ credit_score: m.credit_score
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(() => {
57
57
  if (a) {
58
- const f = (R) => {
59
- y.current && !y.current.contains(R.target) && v && T(!0);
58
+ const f = (P) => {
59
+ g.current && !g.current.contains(P.target) && C && x(!0);
60
60
  };
61
61
  return document.addEventListener("mousedown", f), () => {
62
62
  document.removeEventListener("mousedown", f);
63
63
  };
64
64
  }
65
- }, [v]);
66
- const ie = () => {
67
- if (u.birthday) {
68
- const f = new Date(u.birthday * 1e3), R = f.getUTCFullYear(), ce = f.getUTCMonth(), de = f.getUTCDate();
69
- return new Date(R, ce, de);
65
+ }, [C]);
66
+ const ae = () => {
67
+ if (p.birthday) {
68
+ const f = new Date(p.birthday * 1e3), P = f.getUTCFullYear(), de = f.getUTCMonth(), me = f.getUTCDate();
69
+ return new Date(P, de, me);
70
70
  }
71
- }, ae = async () => {
72
- await _({ ...d, ...u }), w(!1);
73
- }, le = () => {
74
- T(!1), a && a();
71
+ }, le = async () => {
72
+ await _({ ...m, ...p }), w(!1);
75
73
  }, se = () => {
76
- T(!1);
74
+ x(!1), a && a();
75
+ }, ce = () => {
76
+ x(!1);
77
77
  }, E = (f) => {
78
- const R = {
79
- ...u,
78
+ const P = {
79
+ ...p,
80
80
  ...f
81
81
  };
82
- S(R), w(JSON.stringify({ ...d, ...R }) !== JSON.stringify(d));
82
+ S(P), w(JSON.stringify({ ...m, ...P }) !== JSON.stringify(m));
83
83
  };
84
84
  return /* @__PURE__ */ c(q, { children: [
85
85
  /* @__PURE__ */ c(
86
86
  F,
87
87
  {
88
88
  component: "form",
89
- ref: y,
89
+ ref: g,
90
90
  sx: {
91
91
  backgroundColor: "background.paper",
92
92
  p: 24,
93
- width: i ? 320 : s ? 680 : m ? 990 : 400,
93
+ width: i ? 320 : s ? 680 : d ? 990 : 400,
94
94
  "& .MuiTextField-root": {
95
- width: i ? 272 : s ? 328 : m ? 483 : 352
95
+ width: i ? 272 : s ? 328 : d ? 483 : 352
96
96
  }
97
97
  },
98
98
  children: [
99
99
  /* @__PURE__ */ e(J, { children: r.personal_details }),
100
- /* @__PURE__ */ e(H, { variant: "Body", children: r.update_information }),
100
+ /* @__PURE__ */ e(L, { variant: "Body", children: r.update_information }),
101
101
  /* @__PURE__ */ c(
102
- p,
102
+ h,
103
103
  {
104
104
  direction: l ? "column" : "row",
105
105
  spacing: l ? 44 : 24,
@@ -108,7 +108,7 @@ const Oe = ({ availableWidth: t, handleOnLeavClick: a }) => {
108
108
  /* @__PURE__ */ e(
109
109
  I,
110
110
  {
111
- defaultValue: u.first_name,
111
+ defaultValue: p.first_name,
112
112
  label: r.first_name,
113
113
  onChange: (f) => E({ first_name: f.target.value })
114
114
  }
@@ -116,7 +116,7 @@ const Oe = ({ availableWidth: t, handleOnLeavClick: a }) => {
116
116
  /* @__PURE__ */ e(
117
117
  I,
118
118
  {
119
- defaultValue: u.last_name,
119
+ defaultValue: p.last_name,
120
120
  label: r.last_name,
121
121
  onChange: (f) => E({ last_name: f.target.value })
122
122
  }
@@ -124,37 +124,37 @@ const Oe = ({ availableWidth: t, handleOnLeavClick: a }) => {
124
124
  ]
125
125
  }
126
126
  ),
127
- /* @__PURE__ */ c(p, { direction: l ? "column" : "row", children: [
128
- g.display_email_edit_field_in_settings && /* @__PURE__ */ c(p, { sx: { mb: z ? 20 : 44, mr: l ? 0 : 24 }, children: [
127
+ /* @__PURE__ */ c(h, { direction: l ? "column" : "row", children: [
128
+ b.display_email_edit_field_in_settings && /* @__PURE__ */ c(h, { sx: { mb: z ? 20 : 44, mr: l ? 0 : 24 }, children: [
129
129
  /* @__PURE__ */ e(
130
130
  I,
131
131
  {
132
- defaultValue: u.email,
132
+ defaultValue: p.email,
133
133
  label: r.email_address,
134
134
  onChange: (f) => E({ email: f.target.value })
135
135
  }
136
136
  ),
137
- z && /* @__PURE__ */ e(ve, {})
137
+ z && /* @__PURE__ */ e(Ce, {})
138
138
  ] }),
139
- g.display_sms_edit_field_in_settings && /* @__PURE__ */ c(p, { sx: { mb: Y ? 20 : 44 }, children: [
139
+ b.display_sms_edit_field_in_settings && /* @__PURE__ */ c(h, { sx: { mb: Y ? 20 : 44 }, children: [
140
140
  /* @__PURE__ */ e(
141
141
  I,
142
142
  {
143
- defaultValue: u.phone,
143
+ defaultValue: p.phone,
144
144
  label: r.mobile_number,
145
145
  onChange: (f) => E({ phone: f.target.value }),
146
146
  type: "tel"
147
147
  }
148
148
  ),
149
- Y && /* @__PURE__ */ e(Ce, {})
149
+ Y && /* @__PURE__ */ e(De, {})
150
150
  ] })
151
151
  ] }),
152
- /* @__PURE__ */ c(p, { direction: l ? "column" : "row", spacing: l ? 44 : 24, sx: { mb: 44 }, children: [
153
- /* @__PURE__ */ e(be, { dateAdapter: _e, children: /* @__PURE__ */ e(
154
- ge,
152
+ /* @__PURE__ */ c(h, { direction: l ? "column" : "row", spacing: l ? 44 : 24, sx: { mb: 44 }, children: [
153
+ /* @__PURE__ */ e(ye, { dateAdapter: ge, children: /* @__PURE__ */ e(
154
+ be,
155
155
  {
156
156
  label: r.birthdate,
157
- onChange: (f) => E({ birthday: fe(f) }),
157
+ onChange: (f) => E({ birthday: _e(f) }),
158
158
  slotProps: {
159
159
  nextIconButton: {
160
160
  sx: {
@@ -176,23 +176,23 @@ const Oe = ({ availableWidth: t, handleOnLeavClick: a }) => {
176
176
  "&:hover": { backgroundColor: U(o.palette.primary.light, 0.1) }
177
177
  }
178
178
  },
179
- value: ie()
179
+ value: ae()
180
180
  }
181
181
  ) }),
182
182
  /* @__PURE__ */ e(
183
183
  I,
184
184
  {
185
- defaultValue: u.postal_code,
185
+ defaultValue: p.postal_code,
186
186
  label: r.zip_code,
187
187
  onChange: (f) => E({ postal_code: f.target.value })
188
188
  }
189
189
  )
190
190
  ] }),
191
- /* @__PURE__ */ c(p, { children: [
191
+ /* @__PURE__ */ c(h, { children: [
192
192
  /* @__PURE__ */ e(
193
193
  I,
194
194
  {
195
- defaultValue: u.credit_score,
195
+ defaultValue: p.credit_score,
196
196
  label: r.credit_score,
197
197
  onChange: (f) => E({ credit_score: Number(f.target.value) }),
198
198
  sx: { mb: 44 }
@@ -201,8 +201,8 @@ const Oe = ({ availableWidth: t, handleOnLeavClick: a }) => {
201
201
  /* @__PURE__ */ e(
202
202
  Q,
203
203
  {
204
- disabled: !v,
205
- onClick: ae,
204
+ disabled: !C,
205
+ onClick: le,
206
206
  sx: { width: i ? 272 : 124 },
207
207
  variant: "contained",
208
208
  children: n.save_button
@@ -213,32 +213,32 @@ const Oe = ({ availableWidth: t, handleOnLeavClick: a }) => {
213
213
  }
214
214
  ),
215
215
  /* @__PURE__ */ e(
216
- W,
216
+ $,
217
217
  {
218
218
  copy: { title: r.discard_changes },
219
- isOpen: C,
220
- onClose: se,
221
- onSecondaryAction: le,
219
+ isOpen: T,
220
+ onClose: ce,
221
+ onSecondaryAction: se,
222
222
  primaryText: r.keep_editing,
223
223
  secondaryText: r.leave,
224
224
  children: r.discard_changes_message
225
225
  }
226
226
  )
227
227
  ] });
228
- }, Ue = D(Oe);
229
- var b = /* @__PURE__ */ ((t) => (t.Delete = "delete", t.Edit = "edit", t.Token = "token", t))(b || {});
230
- const Fe = ({
228
+ }, Fe = D(Ue);
229
+ var y = /* @__PURE__ */ ((t) => (t.Delete = "delete", t.Edit = "edit", t.Token = "token", t))(y || {});
230
+ const Ve = ({
231
231
  devices: t,
232
232
  onClickDeviceEdit: a,
233
233
  onClickDeviceDelete: o
234
234
  }) => {
235
- const n = P(), { settings: r } = k(), m = [
235
+ const n = R(), { settings: r } = k(), d = [
236
236
  {
237
237
  field: "name",
238
238
  headerName: r.mobile_devices_column_name,
239
239
  renderHeader: O,
240
- renderCell: (i) => /* @__PURE__ */ c(p, { alignItems: "center", direction: "row", gap: 4, children: [
241
- /* @__PURE__ */ e(x, { variant: "Small", children: i.value }),
240
+ renderCell: (i) => /* @__PURE__ */ c(h, { alignItems: "center", direction: "row", gap: 4, children: [
241
+ /* @__PURE__ */ e(v, { variant: "Small", children: i.value }),
242
242
  /* @__PURE__ */ e(
243
243
  V,
244
244
  {
@@ -266,7 +266,7 @@ const Fe = ({
266
266
  field: "created_at",
267
267
  headerName: r.mobile_devices_column_added,
268
268
  renderHeader: O,
269
- valueFormatter: (i) => te(oe(i), { addSuffix: !0 }),
269
+ valueFormatter: (i) => oe(ne(i), { addSuffix: !0 }),
270
270
  sortable: !0,
271
271
  hideSortIcons: !1,
272
272
  flex: 1,
@@ -276,7 +276,7 @@ const Fe = ({
276
276
  field: "delete",
277
277
  headerName: "",
278
278
  renderHeader: O,
279
- renderCell: (i) => /* @__PURE__ */ e(p, { mr: 4, children: /* @__PURE__ */ e(
279
+ renderCell: (i) => /* @__PURE__ */ e(h, { mr: 4, children: /* @__PURE__ */ e(
280
280
  V,
281
281
  {
282
282
  "aria-label": r.mobile_devices_delete_label,
@@ -289,15 +289,15 @@ const Fe = ({
289
289
  hideSortIcons: !1,
290
290
  width: 58
291
291
  }
292
- ], l = h.useMemo(() => t.map((i) => ({
292
+ ], l = u.useMemo(() => t.map((i) => ({
293
293
  id: i.guid,
294
294
  ...i,
295
295
  device_type: `${i.make} ${i.model}`
296
296
  })), [t]);
297
297
  return /* @__PURE__ */ e(F, { sx: { width: "100%" }, children: /* @__PURE__ */ e(
298
- Se,
298
+ ke,
299
299
  {
300
- columns: m,
300
+ columns: d,
301
301
  disableColumnFilter: !0,
302
302
  disableColumnMenu: !0,
303
303
  disableRowSelectionOnClick: !0,
@@ -318,7 +318,7 @@ const Fe = ({
318
318
  alignItems: "center",
319
319
  p: "12px 16px"
320
320
  },
321
- children: /* @__PURE__ */ e(x, { color: n.palette.text.secondary, variant: "Small", children: N(
321
+ children: /* @__PURE__ */ e(v, { color: n.palette.text.secondary, variant: "Small", children: N(
322
322
  r.mobile_devices_count,
323
323
  /* @__PURE__ */ e("b", { children: t.length }),
324
324
  /* @__PURE__ */ e("b", { children: t.length })
@@ -342,24 +342,24 @@ const Fe = ({
342
342
  }
343
343
  }
344
344
  ) });
345
- }, Ve = ({
345
+ }, We = ({
346
346
  devices: t,
347
347
  onClickDeviceEdit: a,
348
348
  onClickDeviceDelete: o
349
349
  }) => {
350
- const n = P(), { settings: r } = k(), [m, l] = h.useState(!1), i = (s) => (g, _) => {
350
+ const n = R(), { settings: r } = k(), [d, l] = u.useState(!1), i = (s) => (b, _) => {
351
351
  l(_ ? s : !1);
352
352
  };
353
- return /* @__PURE__ */ c(p, { mx: -28, sx: { "& .MuiAccordion-root": { mb: 0, mt: 0 } }, children: [
353
+ return /* @__PURE__ */ c(h, { mx: -28, sx: { "& .MuiAccordion-root": { mb: 0, mt: 0 } }, children: [
354
354
  t.map((s) => /* @__PURE__ */ c(
355
- ke,
355
+ we,
356
356
  {
357
- expanded: m === s.guid,
357
+ expanded: d === s.guid,
358
358
  onChange: i(s.guid),
359
359
  sx: { boxShadow: "none" },
360
360
  children: [
361
361
  /* @__PURE__ */ e(
362
- Te,
362
+ Ie,
363
363
  {
364
364
  expandIcon: /* @__PURE__ */ e(M, { color: "secondary", name: "keyboard_arrow_down", size: 24 }),
365
365
  sx: {
@@ -367,20 +367,20 @@ const Fe = ({
367
367
  borderBottom: "1px solid",
368
368
  borderColor: n.palette.border.light
369
369
  },
370
- children: /* @__PURE__ */ c(p, { gap: 4, children: [
371
- /* @__PURE__ */ e(x, { bold: !0, variant: "Body", children: s.name }),
372
- /* @__PURE__ */ e(x, { color: n.palette.text.secondary, variant: "Small", children: `${s.make} ${s.model}` }),
373
- /* @__PURE__ */ e(x, { color: n.palette.text.secondary, variant: "Small", children: te(oe(s.created_at), { addSuffix: !0 }) })
370
+ children: /* @__PURE__ */ c(h, { gap: 4, children: [
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 }) })
374
374
  ] })
375
375
  }
376
376
  ),
377
377
  /* @__PURE__ */ c(
378
- we,
378
+ Te,
379
379
  {
380
380
  sx: { backgroundColor: n.palette.background.default, p: "0 0 0 24px" },
381
381
  children: [
382
382
  /* @__PURE__ */ c(
383
- p,
383
+ h,
384
384
  {
385
385
  onClick: () => a(s),
386
386
  sx: {
@@ -395,12 +395,12 @@ const Fe = ({
395
395
  },
396
396
  children: [
397
397
  /* @__PURE__ */ e(V, { "aria-label": r.mobile_devices_edit_label, color: "secondary", children: /* @__PURE__ */ e(M, { name: "edit" }) }),
398
- /* @__PURE__ */ e(x, { variant: "Body", children: r.mobile_devices_edit_label })
398
+ /* @__PURE__ */ e(v, { variant: "Body", children: r.mobile_devices_edit_label })
399
399
  ]
400
400
  }
401
401
  ),
402
402
  /* @__PURE__ */ c(
403
- p,
403
+ h,
404
404
  {
405
405
  onClick: () => o(s),
406
406
  sx: {
@@ -413,7 +413,7 @@ const Fe = ({
413
413
  },
414
414
  children: [
415
415
  /* @__PURE__ */ e(V, { "aria-label": r.mobile_devices_delete_label, color: "secondary", children: /* @__PURE__ */ e(M, { name: "delete" }) }),
416
- /* @__PURE__ */ e(x, { variant: "Body", children: r.mobile_devices_delete_label })
416
+ /* @__PURE__ */ e(v, { variant: "Body", children: r.mobile_devices_delete_label })
417
417
  ]
418
418
  }
419
419
  )
@@ -433,7 +433,7 @@ const Fe = ({
433
433
  borderColor: n.palette.border.light,
434
434
  p: "12px 16px"
435
435
  },
436
- children: /* @__PURE__ */ e(x, { color: n.palette.text.secondary, variant: "Small", children: N(
436
+ children: /* @__PURE__ */ e(v, { color: n.palette.text.secondary, variant: "Small", children: N(
437
437
  r.mobile_devices_count,
438
438
  /* @__PURE__ */ e("b", { children: t.length }),
439
439
  /* @__PURE__ */ e("b", { children: t.length })
@@ -448,39 +448,39 @@ const Fe = ({
448
448
  device: n,
449
449
  deviceToken: r = ""
450
450
  }) => {
451
- const m = P(), { common: l, settings: i } = k(), { updateDevice: s, deleteDevice: g, setAlert: _, loadDevices: d } = A(), [u, S] = h.useState("");
452
- h.useEffect(() => {
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
453
  n && S(n.name);
454
454
  }, [n, t]);
455
- const v = () => {
455
+ const C = () => {
456
456
  switch (t) {
457
- case b.Edit:
457
+ case y.Edit:
458
458
  return i.mobile_devices_edit_label;
459
- case b.Delete:
459
+ case y.Delete:
460
460
  return i.mobile_devices_delete_label;
461
461
  default:
462
462
  return "";
463
463
  }
464
464
  }, w = () => {
465
465
  switch (t) {
466
- case b.Token:
466
+ case y.Token:
467
467
  return l.done_button;
468
- case b.Edit:
468
+ case y.Edit:
469
469
  return l.save_button;
470
- case b.Delete:
470
+ case y.Delete:
471
471
  return l.delete_button;
472
472
  default:
473
473
  return "";
474
474
  }
475
- }, C = () => {
476
- const y = {
475
+ }, T = () => {
476
+ const g = {
477
477
  "& .MuiDialogContent-root": {
478
478
  width: 400,
479
479
  pt: 0
480
480
  }
481
481
  };
482
- return t === b.Token ? {
483
- ...y,
482
+ return t === y.Token ? {
483
+ ...g,
484
484
  "& .MuiToolbar-root:last-child": {
485
485
  padding: "32px 60px 48px",
486
486
  justifyContent: "center"
@@ -492,55 +492,55 @@ const Fe = ({
492
492
  flex: 1
493
493
  }
494
494
  } : {
495
- ...y,
495
+ ...g,
496
496
  "& .MuiToolbar-root:last-child": {
497
497
  gap: 8,
498
498
  padding: 24,
499
499
  justifyContent: "flex-end"
500
500
  },
501
- ...t === b.Delete && {
501
+ ...t === y.Delete && {
502
502
  "& .MuiTypography-Body": {
503
503
  padding: 0
504
504
  }
505
505
  }
506
506
  };
507
- }, T = async () => {
508
- if (t === b.Token && o(), t === b.Edit && n) {
509
- const y = { ...n, name: u };
510
- (await s(y)).success ? (_(i.mobile_devices_edit_success, "success"), d()) : _(
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
511
  N(i.mobile_devices_edit_error, n.name),
512
512
  "error"
513
513
  ), o();
514
514
  }
515
- t === b.Delete && n && ((await g(n.guid)).success ? (_(
515
+ t === y.Delete && n && ((await b(n.guid)).success ? (_(
516
516
  N(i.mobile_devices_delete_success, n.name),
517
517
  "success"
518
- ), d()) : _(
518
+ ), m()) : _(
519
519
  N(i.mobile_devices_delete_error, n.name),
520
520
  "error"
521
521
  ), o());
522
522
  };
523
523
  return /* @__PURE__ */ c(
524
- W,
524
+ $,
525
525
  {
526
- copy: { title: v() },
526
+ copy: { title: C() },
527
527
  isOpen: a,
528
528
  onClose: o,
529
- onPrimaryAction: T,
529
+ onPrimaryAction: x,
530
530
  onSecondaryAction: o,
531
- primaryColor: t === b.Delete ? "error" : void 0,
531
+ primaryColor: t === y.Delete ? "error" : void 0,
532
532
  primaryText: w(),
533
- secondaryText: t === b.Token ? l.back : l.cancel_button,
534
- sx: C(),
533
+ secondaryText: t === y.Token ? l.back : l.cancel_button,
534
+ sx: T(),
535
535
  children: [
536
- t === b.Token && /* @__PURE__ */ c(p, { spacing: 16, sx: { px: 40, textAlign: "center", width: "100%" }, children: [
537
- /* @__PURE__ */ e(x, { bold: !0, truncate: !1, variant: "Body", children: i.mobile_devices_access_label }),
538
- /* @__PURE__ */ e(x, { truncate: !1, variant: "Small", children: i.mobile_devices_access_info_1 }),
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 }),
539
539
  /* @__PURE__ */ e(
540
- x,
540
+ v,
541
541
  {
542
542
  sx: {
543
- border: `1px solid ${m.palette.border.light}`,
543
+ border: `1px solid ${d.palette.border.light}`,
544
544
  borderRadius: "4px",
545
545
  p: "16px 32px"
546
546
  },
@@ -548,30 +548,30 @@ const Fe = ({
548
548
  children: r
549
549
  }
550
550
  ),
551
- /* @__PURE__ */ e(x, { truncate: !1, variant: "Small", children: i.mobile_devices_access_info_2 })
551
+ /* @__PURE__ */ e(v, { truncate: !1, variant: "Small", children: i.mobile_devices_access_info_2 })
552
552
  ] }),
553
- t === b.Edit && /* @__PURE__ */ e(p, { children: /* @__PURE__ */ e(I, { onChange: (y) => S(y.target.value), value: u }) }),
554
- t === b.Delete && /* @__PURE__ */ e(H, { children: i.mobile_devices_delete_info })
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 })
555
555
  ]
556
556
  }
557
557
  );
558
- }, We = D($e), ze = D(() => {
559
- const { isMobile: t } = L(), { settings: a } = k(), { isCopyLoaded: o, isInitialized: n } = Z(), { setAlert: r, devices: m, loadDevices: l, generateDeviceToken: i } = A(), [s, g] = h.useState({ open: !1, type: "" }), [_, d] = h.useState(), [u, S] = h.useState("");
560
- h.useEffect(() => {
558
+ }, ze = D($e), Ge = D(() => {
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
561
  n && l();
562
562
  }, [n]);
563
- const v = async () => {
564
- const y = await i();
565
- y ? (S(y), g({ open: !0, type: b.Token })) : r(a.mobile_devices_access_error, "error");
566
- }, w = (y) => {
567
- d(y), g({ open: !0, type: b.Edit });
568
- }, C = (y) => {
569
- d(y), g({ open: !0, type: b.Delete });
570
- }, T = () => {
571
- g({ open: !1, type: "" }), d(void 0);
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);
572
572
  };
573
- return !o || !n ? /* @__PURE__ */ e(ne, {}) : /* @__PURE__ */ c(
574
- p,
573
+ return !o || !n ? /* @__PURE__ */ e(re, {}) : /* @__PURE__ */ c(
574
+ h,
575
575
  {
576
576
  sx: {
577
577
  backgroundColor: "background.paper",
@@ -579,60 +579,60 @@ const Fe = ({
579
579
  gap: 24
580
580
  },
581
581
  children: [
582
- /* @__PURE__ */ c(p, { gap: 4, children: [
582
+ /* @__PURE__ */ c(h, { gap: 4, children: [
583
583
  /* @__PURE__ */ e(J, { children: a.mobile_devices_title }),
584
- /* @__PURE__ */ e(H, { variant: "Body", children: a.mobile_devices_info })
584
+ /* @__PURE__ */ e(L, { variant: "Body", children: a.mobile_devices_info })
585
585
  ] }),
586
586
  t ? /* @__PURE__ */ e(
587
- Ve,
587
+ We,
588
588
  {
589
- devices: m,
590
- onClickDeviceDelete: C,
589
+ devices: d,
590
+ onClickDeviceDelete: T,
591
591
  onClickDeviceEdit: w
592
592
  }
593
593
  ) : /* @__PURE__ */ e(
594
- Fe,
594
+ Ve,
595
595
  {
596
- devices: m,
597
- onClickDeviceDelete: C,
596
+ devices: d,
597
+ onClickDeviceDelete: T,
598
598
  onClickDeviceEdit: w
599
599
  }
600
600
  ),
601
- /* @__PURE__ */ c(p, { sx: { alignItems: "center", px: 24, py: 12, gap: 4 }, children: [
602
- /* @__PURE__ */ e(x, { bold: !0, variant: "Body", children: a.mobile_devices_access_title }),
603
- /* @__PURE__ */ e(H, { align: "center", variant: "Small", children: a.mobile_devices_access_description }),
604
- /* @__PURE__ */ e(Q, { onClick: v, variant: "text", children: a.mobile_devices_access_cta })
601
+ /* @__PURE__ */ c(h, { sx: { alignItems: "center", px: 24, py: 12, gap: 4 }, children: [
602
+ /* @__PURE__ */ e(v, { bold: !0, variant: "Body", children: a.mobile_devices_access_title }),
603
+ /* @__PURE__ */ e(L, { align: "center", variant: "Small", children: a.mobile_devices_access_description }),
604
+ /* @__PURE__ */ e(Q, { onClick: C, variant: "text", children: a.mobile_devices_access_cta })
605
605
  ] }),
606
606
  /* @__PURE__ */ e(
607
- We,
607
+ ze,
608
608
  {
609
609
  device: _,
610
- deviceToken: u,
610
+ deviceToken: p,
611
611
  dialogType: s.type,
612
612
  isOpen: s.open,
613
- onClose: T
613
+ onClose: x
614
614
  }
615
615
  )
616
616
  ]
617
617
  }
618
618
  );
619
- }), Ge = ze, X = D(
619
+ }), je = Ge, X = D(
620
620
  ({ onClick: t, primaryText: a, secondaryText: o, sx: n }) => {
621
- const r = P();
622
- return /* @__PURE__ */ e(Re, { sx: { bgcolor: r.palette.background.paper }, children: /* @__PURE__ */ c(Be, { alignItems: "flex-start", onClick: t, sx: n, children: [
623
- /* @__PURE__ */ e(Ne, { primary: a, secondary: o }),
624
- /* @__PURE__ */ e(Me, { children: /* @__PURE__ */ e(xe, {}) })
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: [
623
+ /* @__PURE__ */ e(Le, { primary: a, secondary: o }),
624
+ /* @__PURE__ */ e(Ne, { children: /* @__PURE__ */ e(ve, {}) })
625
625
  ] }) });
626
626
  }
627
- ), je = D(() => {
628
- const { settings: t } = k(), { categories: a } = ee(), { selectedRule: o, updateRuleCategory: n } = A(), [r, m] = h.useState(!1), l = () => {
629
- m(!1);
627
+ ), Je = D(() => {
628
+ const { settings: t } = k(), { categories: a } = ee(), { selectedRule: o, updateRuleCategory: n } = A(), [r, d] = u.useState(!1), l = () => {
629
+ d(!1);
630
630
  }, i = () => {
631
- m(!0);
632
- }, s = (_) => a.find((d) => d.guid === _)?.name, g = async (_) => {
631
+ d(!0);
632
+ }, s = (_) => a.find((m) => m.guid === _)?.name, b = async (_) => {
633
633
  o && o.category_guid !== _ && (o.category_guid = _, await n(o)), l();
634
634
  };
635
- return /* @__PURE__ */ c(h.Fragment, { children: [
635
+ return /* @__PURE__ */ c(u.Fragment, { children: [
636
636
  /* @__PURE__ */ e(
637
637
  X,
638
638
  {
@@ -642,23 +642,23 @@ const Fe = ({
642
642
  }
643
643
  ),
644
644
  /* @__PURE__ */ e(
645
- Ee,
645
+ Re,
646
646
  {
647
647
  initialSelected: o?.category_guid ? o.category_guid : void 0,
648
648
  onClose: l,
649
- onSelect: g,
649
+ onSelect: b,
650
650
  showDrawer: r,
651
651
  title: t.select_category
652
652
  }
653
653
  )
654
654
  ] });
655
- }), Je = D(() => {
656
- const { common: t, settings: a } = k(), { selectedRule: o, updateRulePayee: n } = A(), r = P(), [m, l] = h.useState(!1), i = o?.description ? o.description : o?.match_description, [s, g] = h.useState(i || ""), _ = () => {
655
+ }), Ke = D(() => {
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 || ""), _ = () => {
657
657
  l(!0);
658
- }, d = async () => {
658
+ }, m = async () => {
659
659
  s !== i && o && (o.description = s, await n(o), l(!1));
660
660
  };
661
- return /* @__PURE__ */ c(h.Fragment, { children: [
661
+ return /* @__PURE__ */ c(u.Fragment, { children: [
662
662
  /* @__PURE__ */ e(
663
663
  X,
664
664
  {
@@ -668,12 +668,12 @@ const Fe = ({
668
668
  }
669
669
  ),
670
670
  /* @__PURE__ */ e(
671
- W,
671
+ $,
672
672
  {
673
673
  copy: { title: a.edit_payee },
674
- isOpen: m,
674
+ isOpen: d,
675
675
  onClose: () => l(!1),
676
- onPrimaryAction: d,
676
+ onPrimaryAction: m,
677
677
  onSecondaryAction: () => l(!1),
678
678
  primaryText: t.save_button,
679
679
  secondaryText: t.cancel_button,
@@ -684,7 +684,7 @@ const Fe = ({
684
684
  children: /* @__PURE__ */ e(
685
685
  I,
686
686
  {
687
- onChange: (u) => g(u.target.value),
687
+ onChange: (p) => b(p.target.value),
688
688
  sx: { width: 352 },
689
689
  value: s
690
690
  }
@@ -692,10 +692,10 @@ const Fe = ({
692
692
  }
693
693
  )
694
694
  ] });
695
- }), Ke = D(({ onClose: t, onDelete: a, isOpen: o }) => {
696
- const { common: n, settings: r } = k(), m = P();
695
+ }), Xe = D(({ onClose: t, onDelete: a, isOpen: o }) => {
696
+ const { common: n, settings: r } = k(), d = R();
697
697
  return /* @__PURE__ */ e(
698
- W,
698
+ $,
699
699
  {
700
700
  copy: { title: r.delete_rule },
701
701
  isOpen: o,
@@ -707,18 +707,18 @@ const Fe = ({
707
707
  secondaryText: n.cancel_button,
708
708
  sx: {
709
709
  "& .MuiButton-outlined": {
710
- borderColor: m.palette.border.main,
711
- color: m.palette.secondary.main
710
+ borderColor: d.palette.border.main,
711
+ color: d.palette.secondary.main
712
712
  },
713
713
  "& .MuiDialogContent-root": { pt: 0, width: 400 },
714
- path: { fill: m.palette.secondary.darker }
714
+ path: { fill: d.palette.secondary.darker }
715
715
  },
716
- children: /* @__PURE__ */ e(x, { truncate: !1, variant: "Small", children: r.delete_rule_confirm })
716
+ children: /* @__PURE__ */ e(v, { truncate: !1, variant: "Small", children: r.delete_rule_confirm })
717
717
  }
718
718
  );
719
- }), Xe = D(
719
+ }), Ye = D(
720
720
  ({ isOpen: t, onClose: a, onDelete: o }) => {
721
- const { common: n, settings: r } = k(), m = P(), [l, i] = h.useState(!1);
721
+ const { common: n, settings: r } = k(), d = R(), [l, i] = u.useState(!1);
722
722
  return /* @__PURE__ */ c(
723
723
  He,
724
724
  {
@@ -731,17 +731,17 @@ const Fe = ({
731
731
  primaryColor: "error",
732
732
  primaryText: n.delete_button,
733
733
  sx: {
734
- "& .MuiToolbar-root": { borderTop: `1px solid ${m.palette.border.light}` }
734
+ "& .MuiToolbar-root": { borderTop: `1px solid ${d.palette.border.light}` }
735
735
  },
736
736
  title: r.edit_rule,
737
737
  children: [
738
- /* @__PURE__ */ e(Ae, { children: /* @__PURE__ */ e(x, { bold: !0, variant: "XSmall", children: r.details }) }),
739
- /* @__PURE__ */ e(Je, {}),
738
+ /* @__PURE__ */ e(Ee, { children: /* @__PURE__ */ e(v, { bold: !0, variant: "XSmall", children: r.details }) }),
739
+ /* @__PURE__ */ e(Ke, {}),
740
740
  /* @__PURE__ */ e(j, { sx: { ml: 24 } }),
741
- /* @__PURE__ */ e(je, {}),
741
+ /* @__PURE__ */ e(Je, {}),
742
742
  /* @__PURE__ */ e(j, { sx: { ml: 24 } }),
743
743
  /* @__PURE__ */ e(
744
- Ke,
744
+ Xe,
745
745
  {
746
746
  isOpen: l,
747
747
  onClose: () => i(!1),
@@ -752,56 +752,58 @@ const Fe = ({
752
752
  }
753
753
  );
754
754
  }
755
- ), Ye = D(({ rule: t }) => {
756
- const { categories: a } = ee(), { setSelectedGuid: o } = Pe(), { deleteTransactionRule: n, setSelectedRule: r } = A(), { isDesktop: m, isTablet: l } = L(), [i, s] = h.useState(!1), g = () => {
755
+ ), qe = D(({ rule: t }) => {
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
757
  s(!1), o(null), r(void 0);
758
758
  }, _ = async () => {
759
- await n(), g();
760
- }, d = () => {
759
+ await n(), b();
760
+ }, m = () => {
761
761
  s(!0), r(t);
762
- }, u = (S) => a.find((v) => v.guid === S)?.name;
763
- return /* @__PURE__ */ c(h.Fragment, { children: [
762
+ }, p = (S) => a.find((C) => C.guid === S)?.name;
763
+ return /* @__PURE__ */ c(u.Fragment, { children: [
764
764
  /* @__PURE__ */ e(
765
765
  X,
766
766
  {
767
- onClick: d,
767
+ onClick: m,
768
768
  primaryText: t.description ? t.description : t.match_description,
769
- secondaryText: t.category_guid ? u(t.category_guid) : ""
769
+ secondaryText: t.category_guid ? p(t.category_guid) : ""
770
770
  }
771
771
  ),
772
- /* @__PURE__ */ e(j, { sx: { ml: l || m ? 0 : 24 } }),
773
- /* @__PURE__ */ e(Xe, { isOpen: i, onClose: g, onDelete: _ })
772
+ /* @__PURE__ */ e(j, { sx: { ml: l || d ? 0 : 24 } }),
773
+ /* @__PURE__ */ e(Ye, { isOpen: i, onClose: b, onDelete: _ })
774
774
  ] });
775
- }), qe = D(() => {
776
- const { settings: t } = k(), { loadTransactionRules: a, transactionRules: o } = A();
777
- return h.useEffect(() => {
778
- a().finally();
779
- }, []), /* @__PURE__ */ c(p, { sx: { gap: 24, py: 24 }, children: [
780
- /* @__PURE__ */ c(p, { sx: { px: 24 }, children: [
775
+ }), Qe = D(() => {
776
+ const { settings: t } = k(), { loadTransactionRules: a, transactionRules: o } = A(), { onLoad: n } = te();
777
+ return u.useEffect(() => {
778
+ a().finally(() => {
779
+ n?.("TransactionRulesTab");
780
+ });
781
+ }, []), /* @__PURE__ */ c(h, { sx: { gap: 24, py: 24 }, children: [
782
+ /* @__PURE__ */ c(h, { sx: { px: 24 }, children: [
781
783
  /* @__PURE__ */ e(J, { children: t.transaction_rules_label }),
782
- /* @__PURE__ */ e(H, { variant: "Body", children: t.transaction_rules_description })
784
+ /* @__PURE__ */ e(L, { variant: "Body", children: t.transaction_rules_description })
783
785
  ] }),
784
- /* @__PURE__ */ e(Ie, { children: o.map((n, r) => /* @__PURE__ */ e(Ye, { rule: n }, r)) })
786
+ /* @__PURE__ */ e(Ae, { children: o.map((r, d) => /* @__PURE__ */ e(qe, { rule: r }, d)) })
785
787
  ] });
786
- }), re = qe, Qe = D(({ selectedTab: t }) => {
788
+ }), ie = Qe, Ze = D(({ selectedTab: t }) => {
787
789
  const { alert: a, setAlert: o } = A(), {
788
790
  config: { display_user_profile_in_settings: n }
789
- } = $();
791
+ } = W();
790
792
  return /* @__PURE__ */ c(q, { children: [
791
- t === B.Profile && /* @__PURE__ */ e(Ue, {}),
792
- t === B.Devices && /* @__PURE__ */ e(Ge, {}),
793
+ t === B.Profile && /* @__PURE__ */ e(Fe, {}),
794
+ t === B.Devices && /* @__PURE__ */ e(je, {}),
793
795
  t === B.Notifications && /* @__PURE__ */ e(G, { showPersonalDetails: !n }),
794
- t === B.TransactionRules && /* @__PURE__ */ e(re, {}),
795
- t === B.Help && /* @__PURE__ */ e(p, { sx: { px: 24 }, children: /* @__PURE__ */ e(Le, {}) }),
796
+ t === B.TransactionRules && /* @__PURE__ */ e(ie, {}),
797
+ t === B.Help && /* @__PURE__ */ e(h, { sx: { px: 24 }, children: /* @__PURE__ */ e(Oe, {}) }),
796
798
  /* @__PURE__ */ e(
797
- he,
799
+ fe,
798
800
  {
799
801
  anchorOrigin: { vertical: "bottom", horizontal: "right" },
800
802
  autoHideDuration: 3500,
801
803
  onClose: () => o(""),
802
804
  open: !!a.message,
803
805
  children: /* @__PURE__ */ e(
804
- pe,
806
+ he,
805
807
  {
806
808
  onClose: () => {
807
809
  o("");
@@ -817,63 +819,67 @@ const Fe = ({
817
819
  });
818
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 || {});
819
821
  const $t = D(({ onBackClick: t, sx: a }) => {
820
- const { settings: o } = k(), { isCopyLoaded: n, isInitialized: r } = Z(), { config: m } = $(), { isMobile: l } = L(), {
821
- display_user_profile_in_settings: i,
822
- display_mobile_devices_in_settings: s,
823
- display_notification_settings_in_settings: g,
824
- display_user_transaction_rules_in_settings: _,
825
- show_help_widget_in_master: d
826
- } = m, u = [
827
- { enabled: i, index: 0, label: o?.profile_label },
828
- { enabled: s, index: 1, label: o?.mobile_devices_label },
829
- { enabled: g, index: 2, label: o?.notifications_label },
830
- { enabled: _, index: 3, label: o?.transaction_rules_label },
831
- { enabled: d, index: 4, label: o?.help_label }
832
- ], S = u.find((C) => C.enabled), [v, w] = h.useState(S ? S.index : -1);
833
- return !n || !r ? /* @__PURE__ */ e(ne, {}) : /* @__PURE__ */ e(
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]);
826
+ const {
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(
834
840
  K,
835
841
  {
836
842
  onBackClick: t,
837
843
  sx: { height: "calc(100dvh - 24px)", overflow: "auto", ...a },
838
844
  title: o.title,
839
- children: /* @__PURE__ */ c(p, { mx: l ? 0 : 48, my: 24, children: [
845
+ children: /* @__PURE__ */ c(h, { mx: l ? 0 : 48, my: 24, children: [
840
846
  /* @__PURE__ */ e(
841
- ue,
847
+ pe,
842
848
  {
843
- onChange: (C, T) => w(T),
849
+ onChange: (x, g) => T(g),
844
850
  sx: { bgcolor: "background.paper" },
845
851
  textColor: "primary",
846
- value: v,
852
+ value: w,
847
853
  variant: "scrollable",
848
- children: u.map(
849
- (C) => C.enabled && /* @__PURE__ */ e(me, { label: C.label, value: C.index }, C.index)
854
+ children: S.map(
855
+ (x) => x.enabled && /* @__PURE__ */ e(ue, { label: x.label, value: x.index }, x.index)
850
856
  )
851
857
  }
852
858
  ),
853
- /* @__PURE__ */ e(Qe, { selectedTab: v })
859
+ /* @__PURE__ */ e(Ze, { selectedTab: w })
854
860
  ] })
855
861
  }
856
862
  );
857
- }), Wt = D((t) => {
858
- const { clientConfig: a } = $(), o = a?.master?.deep_link_params?.view;
859
- return o ? /* @__PURE__ */ e(G, { view: o }) : /* @__PURE__ */ e(K, { ...t, children: /* @__PURE__ */ e(p, { my: 24, children: /* @__PURE__ */ e(G, {}) }) });
860
- }), zt = (t) => {
861
- const { isMobile: a } = L();
862
- return /* @__PURE__ */ e(K, { ...t, children: /* @__PURE__ */ e(p, { sx: { mx: a ? 0 : 48, my: 24 }, children: /* @__PURE__ */ e(re, {}) }) });
863
+ }), zt = D((t) => {
864
+ const { clientConfig: a } = W(), o = a?.master?.deep_link_params?.view;
865
+ return o ? /* @__PURE__ */ e(G, { view: o }) : /* @__PURE__ */ e(K, { ...t, children: /* @__PURE__ */ e(h, { my: 24, children: /* @__PURE__ */ e(G, {}) }) });
866
+ }), Gt = (t) => {
867
+ const { isMobile: a } = H();
868
+ return /* @__PURE__ */ e(K, { ...t, children: /* @__PURE__ */ e(h, { sx: { mx: a ? 0 : 48, my: 24 }, children: /* @__PURE__ */ e(ie, {}) }) });
863
869
  };
864
870
  export {
865
- Yt as AccountNotificationProfiles,
866
- qt as BudgetNotificationProfiles,
867
- Ge as DeviceTab,
868
- Qt as InsightsNotificationProfiles,
871
+ qt as AccountNotificationProfiles,
872
+ Qt as BudgetNotificationProfiles,
873
+ je as DeviceTab,
874
+ Zt as InsightsNotificationProfiles,
869
875
  G as NotificationSettings,
870
- Wt as NotificationSettingsWidget,
871
- Ue as ProfileTab,
872
- Jt as SettingsApi,
873
- Kt as SettingsStore,
876
+ zt as NotificationSettingsWidget,
877
+ Fe as ProfileTab,
878
+ Kt as SettingsApi,
879
+ Xt as SettingsStore,
874
880
  B as SettingsTabs,
875
881
  $t as SettingsWidget,
876
- Qe as SettingsWidgetContents,
877
- re as TransactionRulesTab,
878
- zt as TransactionRulesWidget
882
+ Ze as SettingsWidgetContents,
883
+ ie as TransactionRulesTab,
884
+ Gt as TransactionRulesWidget
879
885
  };