@mx-cartographer/experiences 9.2.9-alpha.al4 → 9.2.9
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/{AccountDetailsDrawer-CwDPr4i5.mjs → AccountDetailsDrawer-uaxiCVOl.mjs} +2 -2
- package/dist/{AccountDetailsDrawer-CwDPr4i5.mjs.map → AccountDetailsDrawer-uaxiCVOl.mjs.map} +1 -1
- package/dist/{Analytics-DST_WxYZ.mjs → Analytics-B8AaC22u.mjs} +2 -2
- package/dist/{Analytics-DST_WxYZ.mjs.map → Analytics-B8AaC22u.mjs.map} +1 -1
- package/dist/{ApiEndpoints-YY8ajnnd.mjs → ApiEndpoints-DXwIYNUV.mjs} +1 -2
- package/dist/ApiEndpoints-DXwIYNUV.mjs.map +1 -0
- package/dist/{CategorySelectorDrawer-NJsFsKP1.mjs → CategorySelectorDrawer-BYeVJ_kO.mjs} +94 -86
- package/dist/{CategorySelectorDrawer-NJsFsKP1.mjs.map → CategorySelectorDrawer-BYeVJ_kO.mjs.map} +1 -1
- package/dist/{GlobalCopyApi-DNC5K2QG.mjs → GlobalCopyApi-CLhyon-B.mjs} +2 -2
- package/dist/{GlobalCopyApi-DNC5K2QG.mjs.map → GlobalCopyApi-CLhyon-B.mjs.map} +1 -1
- package/dist/{ManageIncome-Br11zvAT.mjs → ManageIncome-CtD65bN_.mjs} +3 -3
- package/dist/{ManageIncome-Br11zvAT.mjs.map → ManageIncome-CtD65bN_.mjs.map} +1 -1
- package/dist/{NotificationSettings-DXYTQcTs.mjs → NotificationSettings-CW7okUrk.mjs} +127 -117
- package/dist/NotificationSettings-CW7okUrk.mjs.map +1 -0
- package/dist/{RecurringSettings-BkRz-uzd.mjs → RecurringSettings-BM2bQfSY.mjs} +2 -2
- package/dist/{RecurringSettings-BkRz-uzd.mjs.map → RecurringSettings-BM2bQfSY.mjs.map} +1 -1
- package/dist/{TransactionDetails-CLc7oeHT.mjs → TransactionDetails-Bo0rVT-L.mjs} +2 -2
- package/dist/{TransactionDetails-CLc7oeHT.mjs.map → TransactionDetails-Bo0rVT-L.mjs.map} +1 -1
- package/dist/{UserStore-cI7SJMs_.mjs → UserStore-CgsAunf1.mjs} +145 -166
- package/dist/UserStore-CgsAunf1.mjs.map +1 -0
- package/dist/{ViewMoreMicroCard-Bx9xa2z5.mjs → ViewMoreMicroCard-B4oeGrbE.mjs} +3 -3
- package/dist/{ViewMoreMicroCard-Bx9xa2z5.mjs.map → ViewMoreMicroCard-B4oeGrbE.mjs.map} +1 -1
- package/dist/accounts/index.es.js +2 -2
- package/dist/budgets/index.es.js +3 -3
- package/dist/cashflow/index.es.js +3 -3
- package/dist/categories/index.es.js +1 -1
- package/dist/common/index.es.js +2 -2
- package/dist/core/api/SettingsApi.d.ts +0 -4
- package/dist/core/constants/ApiEndpoints.d.ts +0 -1
- package/dist/core/index.es.js +4 -4
- package/dist/core/stores/SettingsStore.d.ts +0 -4
- package/dist/core/types/localization/SettingsCopy.d.ts +0 -6
- package/dist/finstrong/index.es.js +2 -2
- package/dist/microinsights/index.es.js +1 -1
- package/dist/notifications/index.es.js +2 -2
- package/dist/recurringtransactions/index.es.js +4 -4
- package/dist/settings/components/profile/ProfileTab.d.ts +1 -1
- package/dist/settings/index.es.js +405 -468
- package/dist/settings/index.es.js.map +1 -1
- package/dist/spending/index.es.js +1 -1
- package/dist/transactions/index.es.js +3 -3
- package/dist/trends/index.es.js +2 -2
- package/package.json +1 -1
- package/dist/ApiEndpoints-YY8ajnnd.mjs.map +0 -1
- package/dist/NotificationSettings-DXYTQcTs.mjs.map +0 -1
- package/dist/UserStore-cI7SJMs_.mjs.map +0 -1
- package/dist/settings/components/profile/actions/ResetPasswordAction.d.ts +0 -4
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
import { jsxs as c, jsx as e, Fragment as N } from "react/jsx-runtime";
|
|
2
2
|
import f from "react";
|
|
3
|
-
import { observer as
|
|
3
|
+
import { observer as C } from "mobx-react-lite";
|
|
4
4
|
import v from "@mui/material/Divider";
|
|
5
5
|
import E from "@mui/material/List";
|
|
6
6
|
import O from "@mui/material/ListItem";
|
|
7
7
|
import L from "@mui/material/ListItemText";
|
|
8
8
|
import V from "@mui/material/ListItemButton";
|
|
9
|
-
import
|
|
10
|
-
import { ChevronRight as
|
|
11
|
-
import { Text as
|
|
9
|
+
import h from "@mui/material/Stack";
|
|
10
|
+
import { ChevronRight as A, ExpandMore as ee, Star as te } from "@mxenabled/mx-icons";
|
|
11
|
+
import { Text as x, InstitutionLogo as ne, H3 as F } from "@mxenabled/mxui";
|
|
12
12
|
import { endOfMonth as ie } from "date-fns/endOfMonth";
|
|
13
13
|
import { startOfMonth as oe } from "date-fns/startOfMonth";
|
|
14
14
|
import { DateCalendar as se } from "@mui/x-date-pickers/DateCalendar";
|
|
@@ -16,49 +16,58 @@ import { LocalizationProvider as ae } from "@mui/x-date-pickers/LocalizationProv
|
|
|
16
16
|
import { AdapterDateFns as ce } from "@mui/x-date-pickers/AdapterDateFnsV3";
|
|
17
17
|
import { b as le } from "./Localization-DnoVyBNK.mjs";
|
|
18
18
|
import { b as re, f as de } from "./NumberFormatting--XMeeBfr.mjs";
|
|
19
|
-
import { u as k, A as T, C as
|
|
20
|
-
import { A as
|
|
19
|
+
import { u as k, A as T, C as S, c as J, f as me, i as q, a as he } from "./hooks-97sNJ_lf.mjs";
|
|
20
|
+
import { A as ue, N as b } from "./Notification-DTNYSd8P.mjs";
|
|
21
21
|
import { T as R, a as D } from "./ToggleListItem-Dl1lXNwj.mjs";
|
|
22
22
|
import { D as B } from "./Dialog-Bvd2n8hz.mjs";
|
|
23
|
-
import { C as
|
|
23
|
+
import { C as _e } from "./CurrencyInput-DaGEQaLW.mjs";
|
|
24
24
|
import { u as fe } from "./useScreenSize-mWpmnh5w.mjs";
|
|
25
25
|
import { D as K } from "./Drawer-DsnW2o0v.mjs";
|
|
26
26
|
import pe from "@mui/material/Collapse";
|
|
27
27
|
import ge from "@mui/material/Card";
|
|
28
28
|
import ye from "@mui/material/CardContent";
|
|
29
|
-
import
|
|
30
|
-
import
|
|
29
|
+
import W from "@mui/material/Box";
|
|
30
|
+
import j from "@mui/material/Button";
|
|
31
31
|
import U from "@mui/material/TextField";
|
|
32
32
|
import { u as be } from "./useDimensions-CeDR9V8N.mjs";
|
|
33
33
|
import { useTheme as Q } from "@mui/material/styles";
|
|
34
34
|
import { u as xe } from "./useInsightsEnabled-D5Sdm0TJ.mjs";
|
|
35
35
|
import { u as Ce } from "./useWidgetLoadTimer-B0tB-yzL.mjs";
|
|
36
36
|
import { L as ve } from "./Loader-CxeBwuPG.mjs";
|
|
37
|
-
const Te =
|
|
38
|
-
const { common: n, settings: t } = k(), { sendEmailVerification: s } = T(), { user: l } =
|
|
37
|
+
const Te = C(() => {
|
|
38
|
+
const { common: n, settings: t } = k(), { sendEmailVerification: s } = T(), { user: l } = S(), i = Q(), [r, a] = f.useState(!1), o = () => {
|
|
39
39
|
a(!1);
|
|
40
|
-
},
|
|
40
|
+
}, u = () => {
|
|
41
41
|
a(!0);
|
|
42
42
|
};
|
|
43
43
|
return /* @__PURE__ */ c(f.Fragment, { children: [
|
|
44
|
-
/* @__PURE__ */ c(
|
|
45
|
-
/* @__PURE__ */ e(
|
|
46
|
-
/* @__PURE__ */ e(
|
|
44
|
+
/* @__PURE__ */ c(j, { onClick: u, sx: { height: "auto", p: 4, width: "fit-content" }, children: [
|
|
45
|
+
/* @__PURE__ */ e(x, { variant: "body2", children: t.verify_email }),
|
|
46
|
+
/* @__PURE__ */ e(A, {})
|
|
47
47
|
] }),
|
|
48
48
|
/* @__PURE__ */ e(
|
|
49
49
|
B,
|
|
50
50
|
{
|
|
51
|
-
copy: { title:
|
|
51
|
+
copy: { title: "" },
|
|
52
52
|
isOpen: r,
|
|
53
53
|
onClose: o,
|
|
54
54
|
onPrimaryAction: s,
|
|
55
55
|
onSecondaryAction: o,
|
|
56
56
|
primaryText: t.send_verification,
|
|
57
57
|
secondaryText: n.back,
|
|
58
|
-
|
|
59
|
-
|
|
58
|
+
sx: {
|
|
59
|
+
"& .MuiDialogContent-root": { pt: 0, width: 400 },
|
|
60
|
+
"& .MuiToolbar-root:last-child": {
|
|
61
|
+
gap: 16,
|
|
62
|
+
padding: "32px 60px 48px",
|
|
63
|
+
justifyContent: "center"
|
|
64
|
+
}
|
|
65
|
+
},
|
|
66
|
+
children: /* @__PURE__ */ c(h, { spacing: 16, sx: { px: 40, textAlign: "center", width: "100%" }, children: [
|
|
67
|
+
/* @__PURE__ */ e(x, { bold: !0, truncate: !1, variant: "body1", children: t.confirm_your_email }),
|
|
68
|
+
/* @__PURE__ */ e(x, { truncate: !1, variant: "body2", children: t.confirm_email }),
|
|
60
69
|
/* @__PURE__ */ e(
|
|
61
|
-
|
|
70
|
+
x,
|
|
62
71
|
{
|
|
63
72
|
sx: {
|
|
64
73
|
border: `1px solid ${i.palette.neutral.light}`,
|
|
@@ -69,12 +78,12 @@ const Te = x(() => {
|
|
|
69
78
|
children: l.email
|
|
70
79
|
}
|
|
71
80
|
),
|
|
72
|
-
/* @__PURE__ */ e(
|
|
81
|
+
/* @__PURE__ */ e(x, { truncate: !1, variant: "body2", children: t.verification_notice_email })
|
|
73
82
|
] })
|
|
74
83
|
}
|
|
75
84
|
)
|
|
76
85
|
] });
|
|
77
|
-
}), Pe =
|
|
86
|
+
}), Pe = C(
|
|
78
87
|
({ handleClose: n, handleVerify: t, isOpen: s }) => {
|
|
79
88
|
const { common: l, settings: i } = k(), [r, a] = f.useState("");
|
|
80
89
|
return /* @__PURE__ */ e(
|
|
@@ -95,14 +104,14 @@ const Te = x(() => {
|
|
|
95
104
|
justifyContent: "flex-end"
|
|
96
105
|
}
|
|
97
106
|
},
|
|
98
|
-
children: /* @__PURE__ */ e(
|
|
107
|
+
children: /* @__PURE__ */ e(h, { children: /* @__PURE__ */ e(U, { onChange: (o) => a(o.target.value), sx: { width: 352 }, value: r }) })
|
|
99
108
|
}
|
|
100
109
|
);
|
|
101
110
|
}
|
|
102
|
-
), De =
|
|
103
|
-
const { common: n, settings: t } = k(), { sendPhoneVerification: s, verifyPhoneToken: l } = T(), { user: i } =
|
|
111
|
+
), De = C(() => {
|
|
112
|
+
const { common: n, settings: t } = k(), { sendPhoneVerification: s, verifyPhoneToken: l } = T(), { user: i } = S(), r = Q(), [a, o] = f.useState(!1), [u, d] = f.useState(!1), p = () => {
|
|
104
113
|
o(!1);
|
|
105
|
-
},
|
|
114
|
+
}, _ = () => {
|
|
106
115
|
o(!0);
|
|
107
116
|
}, y = () => {
|
|
108
117
|
s().finally(() => {
|
|
@@ -114,14 +123,14 @@ const Te = x(() => {
|
|
|
114
123
|
});
|
|
115
124
|
};
|
|
116
125
|
return /* @__PURE__ */ c(f.Fragment, { children: [
|
|
117
|
-
/* @__PURE__ */ c(
|
|
118
|
-
/* @__PURE__ */ e(
|
|
119
|
-
/* @__PURE__ */ e(
|
|
126
|
+
/* @__PURE__ */ c(j, { onClick: _, sx: { height: "auto", p: 4, width: "fit-content" }, children: [
|
|
127
|
+
/* @__PURE__ */ e(x, { variant: "body2", children: t.verify_phone }),
|
|
128
|
+
/* @__PURE__ */ e(A, {})
|
|
120
129
|
] }),
|
|
121
130
|
/* @__PURE__ */ e(
|
|
122
131
|
B,
|
|
123
132
|
{
|
|
124
|
-
copy: { title:
|
|
133
|
+
copy: { title: "" },
|
|
125
134
|
isOpen: a,
|
|
126
135
|
onClose: p,
|
|
127
136
|
onPrimaryAction: y,
|
|
@@ -136,10 +145,11 @@ const Te = x(() => {
|
|
|
136
145
|
justifyContent: "center"
|
|
137
146
|
}
|
|
138
147
|
},
|
|
139
|
-
children: /* @__PURE__ */ c(
|
|
140
|
-
/* @__PURE__ */ e(
|
|
148
|
+
children: /* @__PURE__ */ c(h, { spacing: 16, sx: { px: 40, textAlign: "center", width: "100%" }, children: [
|
|
149
|
+
/* @__PURE__ */ e(x, { bold: !0, truncate: !1, variant: "body1", children: t.confirm_your_phone }),
|
|
150
|
+
/* @__PURE__ */ e(x, { truncate: !1, variant: "body2", children: t.confirm_phone }),
|
|
141
151
|
/* @__PURE__ */ e(
|
|
142
|
-
|
|
152
|
+
x,
|
|
143
153
|
{
|
|
144
154
|
sx: {
|
|
145
155
|
border: `1px solid ${r.palette.neutral.light}`,
|
|
@@ -150,7 +160,7 @@ const Te = x(() => {
|
|
|
150
160
|
children: i.phone
|
|
151
161
|
}
|
|
152
162
|
),
|
|
153
|
-
/* @__PURE__ */ e(
|
|
163
|
+
/* @__PURE__ */ e(x, { truncate: !1, variant: "body2", children: t.verification_notice_phone })
|
|
154
164
|
] })
|
|
155
165
|
}
|
|
156
166
|
),
|
|
@@ -159,21 +169,21 @@ const Te = x(() => {
|
|
|
159
169
|
{
|
|
160
170
|
handleClose: () => d(!1),
|
|
161
171
|
handleVerify: m,
|
|
162
|
-
isOpen:
|
|
172
|
+
isOpen: u
|
|
163
173
|
}
|
|
164
174
|
)
|
|
165
175
|
] });
|
|
166
|
-
}), ke =
|
|
176
|
+
}), ke = C(
|
|
167
177
|
({ onProfileUpdated: n, profile: t }) => {
|
|
168
|
-
const { common: s, recurring: l, settings: i } = k(), { updateAccount: r } = J(), a = t.notification_type ===
|
|
178
|
+
const { common: s, recurring: l, settings: i } = k(), { updateAccount: r } = J(), a = t.notification_type === ue.DebtPaymentReminder, [o, u] = f.useState(!1), [d, p] = f.useState(t.threshold || 0), [_, y] = f.useState(
|
|
169
179
|
t.account?.day_payment_is_due || 0
|
|
170
180
|
), m = t.account?.name || t.account?.feed_name || "", g = t.account?.day_payment_is_due ? le(
|
|
171
181
|
i.notification_debt_payment_date,
|
|
172
182
|
re(t.account?.day_payment_is_due)
|
|
173
183
|
) : i.notification_debt_payment_zero_state, P = a ? g : de(t.threshold ?? 0, "0,0"), I = async () => {
|
|
174
|
-
a && t.account ? await r({ ...t.account, day_payment_is_due:
|
|
184
|
+
a && t.account ? await r({ ...t.account, day_payment_is_due: _ }) : n({ ...t, threshold: d });
|
|
175
185
|
};
|
|
176
|
-
return /* @__PURE__ */ c(
|
|
186
|
+
return /* @__PURE__ */ c(h, { children: [
|
|
177
187
|
/* @__PURE__ */ e(
|
|
178
188
|
R,
|
|
179
189
|
{
|
|
@@ -184,11 +194,11 @@ const Te = x(() => {
|
|
|
184
194
|
institutionGuid: t.account?.institution_guid
|
|
185
195
|
}
|
|
186
196
|
) : void 0,
|
|
187
|
-
endIcon: /* @__PURE__ */ e(
|
|
197
|
+
endIcon: /* @__PURE__ */ e(A, {}),
|
|
188
198
|
isChecked: t.is_enabled,
|
|
189
199
|
isDisabled: !t.is_enabled,
|
|
190
200
|
isPrimaryTextBold: !0,
|
|
191
|
-
onClick: () =>
|
|
201
|
+
onClick: () => u(!0),
|
|
192
202
|
onToggle: () => n({
|
|
193
203
|
...t,
|
|
194
204
|
is_enabled: !t.is_enabled
|
|
@@ -204,9 +214,9 @@ const Te = x(() => {
|
|
|
204
214
|
title: a ? l.day_of_the_month : i.notification_threshold_label,
|
|
205
215
|
close_aria: s.close_aria
|
|
206
216
|
},
|
|
207
|
-
disablePrimaryButton: a &&
|
|
217
|
+
disablePrimaryButton: a && _ === 0,
|
|
208
218
|
isOpen: o,
|
|
209
|
-
onClose: () =>
|
|
219
|
+
onClose: () => u(!1),
|
|
210
220
|
onPrimaryAction: I,
|
|
211
221
|
primaryText: s.save_button,
|
|
212
222
|
children: a ? /* @__PURE__ */ e(ae, { dateAdapter: ce, children: /* @__PURE__ */ e(
|
|
@@ -214,8 +224,8 @@ const Te = x(() => {
|
|
|
214
224
|
{
|
|
215
225
|
maxDate: ie(/* @__PURE__ */ new Date()),
|
|
216
226
|
minDate: oe(/* @__PURE__ */ new Date()),
|
|
217
|
-
onChange: (
|
|
218
|
-
y(
|
|
227
|
+
onChange: (w) => {
|
|
228
|
+
y(w.getDate());
|
|
219
229
|
},
|
|
220
230
|
slots: {
|
|
221
231
|
// Hides the arrows
|
|
@@ -231,13 +241,13 @@ const Te = x(() => {
|
|
|
231
241
|
views: ["day"]
|
|
232
242
|
}
|
|
233
243
|
) }) : /* @__PURE__ */ e(
|
|
234
|
-
|
|
244
|
+
_e,
|
|
235
245
|
{
|
|
236
246
|
amount: d,
|
|
237
247
|
autoFocus: !0,
|
|
238
248
|
fullWidth: !0,
|
|
239
249
|
minAmount: 0,
|
|
240
|
-
setAmount: (
|
|
250
|
+
setAmount: (w) => p(Number(w) || 0),
|
|
241
251
|
sx: { ".MuiTypography-body1": { p: 0 } }
|
|
242
252
|
}
|
|
243
253
|
)
|
|
@@ -245,34 +255,34 @@ const Te = x(() => {
|
|
|
245
255
|
)
|
|
246
256
|
] });
|
|
247
257
|
}
|
|
248
|
-
),
|
|
258
|
+
), we = C(
|
|
249
259
|
({ onUpdateProfile: n, profile: t }) => {
|
|
250
|
-
const { settings: s } = k(), { user: l } =
|
|
251
|
-
opted_out_of_email_notifications:
|
|
260
|
+
const { settings: s } = k(), { user: l } = S(), { clientCommunicationProfile: i, userCommunicationsProfile: r } = T(), { isMobile: a } = fe(), o = t.notification_type > 2, {
|
|
261
|
+
opted_out_of_email_notifications: u,
|
|
252
262
|
opted_out_of_push_notifications: d,
|
|
253
263
|
opted_out_of_sms_notifications: p
|
|
254
264
|
} = r, {
|
|
255
|
-
email_notifications_enabled:
|
|
265
|
+
email_notifications_enabled: _,
|
|
256
266
|
push_notifications_enabled: y,
|
|
257
267
|
sms_notifications_enabled: m
|
|
258
268
|
} = i;
|
|
259
|
-
return /* @__PURE__ */ c(
|
|
260
|
-
(
|
|
261
|
-
/* @__PURE__ */ e(
|
|
269
|
+
return /* @__PURE__ */ c(h, { children: [
|
|
270
|
+
(_ || m || y) && /* @__PURE__ */ c(N, { children: [
|
|
271
|
+
/* @__PURE__ */ e(x, { bold: !0, sx: { mb: 4, ml: 24, mt: 12 }, variant: "caption", children: s.delivery_method_title }),
|
|
262
272
|
/* @__PURE__ */ c(E, { sx: { bgcolor: "background.paper" }, children: [
|
|
263
|
-
|
|
273
|
+
_ && /* @__PURE__ */ e(h, { sx: { pl: 24 }, children: /* @__PURE__ */ e(
|
|
264
274
|
D,
|
|
265
275
|
{
|
|
266
|
-
isChecked: !
|
|
267
|
-
isDisabled:
|
|
276
|
+
isChecked: !u && t.email_channel && !!l.email,
|
|
277
|
+
isDisabled: u || !l.email,
|
|
268
278
|
onToggle: () => n({ ...t, email_channel: !t.email_channel }),
|
|
269
279
|
primaryText: s.delivery_method_email_label,
|
|
270
|
-
secondaryText:
|
|
280
|
+
secondaryText: u || !t.email_channel || !l.email ? s.notification_disabled : s.notification_enabled,
|
|
271
281
|
useExtraPadding: !1
|
|
272
282
|
}
|
|
273
283
|
) }),
|
|
274
|
-
|
|
275
|
-
m && /* @__PURE__ */ e(
|
|
284
|
+
_ && (m || y) && /* @__PURE__ */ e(v, { sx: { ml: a ? 0 : 24 } }),
|
|
285
|
+
m && /* @__PURE__ */ e(h, { sx: { pl: 24 }, children: /* @__PURE__ */ e(
|
|
276
286
|
D,
|
|
277
287
|
{
|
|
278
288
|
isChecked: !p && t.sms_channel && !!l.phone,
|
|
@@ -284,7 +294,7 @@ const Te = x(() => {
|
|
|
284
294
|
}
|
|
285
295
|
) }),
|
|
286
296
|
m && y && /* @__PURE__ */ e(v, { sx: { ml: a ? 0 : 24 } }),
|
|
287
|
-
y && /* @__PURE__ */ e(
|
|
297
|
+
y && /* @__PURE__ */ e(h, { sx: { pl: 24 }, children: /* @__PURE__ */ e(
|
|
288
298
|
D,
|
|
289
299
|
{
|
|
290
300
|
isChecked: !d && t.push_channel,
|
|
@@ -298,8 +308,8 @@ const Te = x(() => {
|
|
|
298
308
|
/* @__PURE__ */ e(v, {})
|
|
299
309
|
] })
|
|
300
310
|
] }),
|
|
301
|
-
o && !!t.children?.length && /* @__PURE__ */ c(
|
|
302
|
-
/* @__PURE__ */ e(
|
|
311
|
+
o && !!t.children?.length && /* @__PURE__ */ c(h, { children: [
|
|
312
|
+
/* @__PURE__ */ e(x, { bold: !0, sx: { mb: 4, ml: 24, mt: 12 }, variant: "caption", children: s.accounts_threshold_title }),
|
|
303
313
|
/* @__PURE__ */ e(E, { sx: { bgcolor: "background.paper" }, children: t.children?.map((g) => /* @__PURE__ */ e(
|
|
304
314
|
ke,
|
|
305
315
|
{
|
|
@@ -311,7 +321,7 @@ const Te = x(() => {
|
|
|
311
321
|
] })
|
|
312
322
|
] });
|
|
313
323
|
}
|
|
314
|
-
), z =
|
|
324
|
+
), z = C(() => {
|
|
315
325
|
const { accountProfiles: n, updateNotificationProfile: t } = T(), [s, l] = f.useState(""), i = f.useMemo(
|
|
316
326
|
() => n.find((o) => o.guid === s),
|
|
317
327
|
[n, s]
|
|
@@ -323,11 +333,11 @@ const Te = x(() => {
|
|
|
323
333
|
}, a = async (o) => {
|
|
324
334
|
await t(o);
|
|
325
335
|
};
|
|
326
|
-
return /* @__PURE__ */ c(
|
|
336
|
+
return /* @__PURE__ */ c(h, { sx: { backgroundColor: "background.paper" }, children: [
|
|
327
337
|
n.filter((o) => o.children && o.children.length > 0).map((o) => /* @__PURE__ */ e(
|
|
328
338
|
R,
|
|
329
339
|
{
|
|
330
|
-
endIcon: /* @__PURE__ */ e(
|
|
340
|
+
endIcon: /* @__PURE__ */ e(A, {}),
|
|
331
341
|
isChecked: o.is_enabled,
|
|
332
342
|
isDisabled: !o.is_enabled,
|
|
333
343
|
onClick: () => l(o.guid),
|
|
@@ -344,7 +354,7 @@ const Te = x(() => {
|
|
|
344
354
|
onClose: () => l(""),
|
|
345
355
|
title: i ? i.label : "",
|
|
346
356
|
children: i && /* @__PURE__ */ e(
|
|
347
|
-
|
|
357
|
+
we,
|
|
348
358
|
{
|
|
349
359
|
onUpdateProfile: a,
|
|
350
360
|
profile: i
|
|
@@ -353,7 +363,7 @@ const Te = x(() => {
|
|
|
353
363
|
}
|
|
354
364
|
)
|
|
355
365
|
] });
|
|
356
|
-
}), X =
|
|
366
|
+
}), X = C(({ profile: n }) => {
|
|
357
367
|
const { settings: t } = k(), {
|
|
358
368
|
clientCommunicationProfile: {
|
|
359
369
|
email_notifications_enabled: s,
|
|
@@ -364,10 +374,10 @@ const Te = x(() => {
|
|
|
364
374
|
userCommunicationsProfile: {
|
|
365
375
|
opted_out_of_email_notifications: a,
|
|
366
376
|
opted_out_of_push_notifications: o,
|
|
367
|
-
opted_out_of_sms_notifications:
|
|
377
|
+
opted_out_of_sms_notifications: u
|
|
368
378
|
}
|
|
369
|
-
} = T(), { user: d } =
|
|
370
|
-
await m({ ...n, is_enabled: !n.is_enabled }), n.is_enabled &&
|
|
379
|
+
} = T(), { user: d } = S(), [p, _] = f.useState(!1), y = async () => {
|
|
380
|
+
await m({ ...n, is_enabled: !n.is_enabled }), n.is_enabled && _(!1);
|
|
371
381
|
}, m = async (P) => {
|
|
372
382
|
await r(P);
|
|
373
383
|
}, g = s || i || l;
|
|
@@ -386,7 +396,7 @@ const Te = x(() => {
|
|
|
386
396
|
) : void 0,
|
|
387
397
|
isChecked: n.is_enabled,
|
|
388
398
|
isDisabled: !n.is_enabled,
|
|
389
|
-
onClick: () =>
|
|
399
|
+
onClick: () => _(!p),
|
|
390
400
|
onToggle: () => y(),
|
|
391
401
|
primaryText: n.label,
|
|
392
402
|
secondaryText: n.is_enabled ? n.deliveryMethodsLabel : void 0
|
|
@@ -410,8 +420,8 @@ const Te = x(() => {
|
|
|
410
420
|
i && /* @__PURE__ */ e(
|
|
411
421
|
D,
|
|
412
422
|
{
|
|
413
|
-
isChecked: !
|
|
414
|
-
isDisabled:
|
|
423
|
+
isChecked: !u && n.sms_channel && !!d.phone,
|
|
424
|
+
isDisabled: u || !d.phone,
|
|
415
425
|
onToggle: () => m({
|
|
416
426
|
...n,
|
|
417
427
|
sms_channel: !n.sms_channel
|
|
@@ -435,23 +445,23 @@ const Te = x(() => {
|
|
|
435
445
|
] }) }),
|
|
436
446
|
/* @__PURE__ */ e(v, {})
|
|
437
447
|
] }, n.guid);
|
|
438
|
-
}), $ =
|
|
448
|
+
}), $ = C(() => {
|
|
439
449
|
const { budgetProfiles: n } = T();
|
|
440
|
-
return /* @__PURE__ */ e(
|
|
441
|
-
}),
|
|
450
|
+
return /* @__PURE__ */ e(h, { children: n.map((t) => /* @__PURE__ */ e(X, { profile: t }, t.guid)) });
|
|
451
|
+
}), Ae = C(() => {
|
|
442
452
|
const { onEvent: n } = me(), { settings: t } = k(), {
|
|
443
453
|
clientCommunicationProfile: s,
|
|
444
454
|
updateUserCommunicationProfile: l,
|
|
445
455
|
userCommunicationsProfile: i
|
|
446
|
-
} = T(), { user: r } =
|
|
447
|
-
const d = { ...i, [o]:
|
|
456
|
+
} = T(), { user: r } = S(), a = async (o, u) => {
|
|
457
|
+
const d = { ...i, [o]: u };
|
|
448
458
|
if (n) {
|
|
449
|
-
const
|
|
450
|
-
|
|
459
|
+
const _ = o.split("_")[3];
|
|
460
|
+
u === !1 ? n("opt_in_notification_method", { notificationType: _ }) : n("opt_out_notification_method", { notificationType: _ });
|
|
451
461
|
}
|
|
452
462
|
await l(d);
|
|
453
463
|
};
|
|
454
|
-
return /* @__PURE__ */ c(
|
|
464
|
+
return /* @__PURE__ */ c(h, { children: [
|
|
455
465
|
/* @__PURE__ */ e(F, { sx: { mt: 24 }, children: t.delivery_method_title }),
|
|
456
466
|
s.email_notifications_enabled && /* @__PURE__ */ c(N, { children: [
|
|
457
467
|
/* @__PURE__ */ e(
|
|
@@ -496,30 +506,30 @@ const Te = x(() => {
|
|
|
496
506
|
useExtraPadding: !1
|
|
497
507
|
}
|
|
498
508
|
),
|
|
499
|
-
s.sms_notifications_enabled && /* @__PURE__ */ e(ge, { sx: { backgroundColor: "background.default", mt: 12 }, variant: "outlined", children: /* @__PURE__ */ e(ye, { children: /* @__PURE__ */ c(
|
|
509
|
+
s.sms_notifications_enabled && /* @__PURE__ */ e(ge, { sx: { backgroundColor: "background.default", mt: 12 }, variant: "outlined", children: /* @__PURE__ */ e(ye, { children: /* @__PURE__ */ c(h, { alignItems: "flex-start", direction: "row", gap: 6, children: [
|
|
500
510
|
/* @__PURE__ */ e(te, { color: "primary", filled: !0 }),
|
|
501
|
-
/* @__PURE__ */ e(
|
|
511
|
+
/* @__PURE__ */ e(x, { variant: "caption", children: t.delivery_method_sms_note_1 })
|
|
502
512
|
] }) }) })
|
|
503
513
|
] });
|
|
504
|
-
}), H =
|
|
514
|
+
}), H = C(() => {
|
|
505
515
|
const { insightsProfiles: n } = T();
|
|
506
|
-
return /* @__PURE__ */ e(
|
|
507
|
-
}),
|
|
508
|
-
const { config: n } = q(), [t, { width: s }] = be(), { common: l, settings: i } = k(), { updateUser: r } = T(), { user: a } =
|
|
516
|
+
return /* @__PURE__ */ e(h, { children: n.map((t) => /* @__PURE__ */ e(X, { profile: t }, t.guid)) });
|
|
517
|
+
}), Se = () => {
|
|
518
|
+
const { config: n } = q(), [t, { width: s }] = be(), { common: l, settings: i } = k(), { updateUser: r } = T(), { user: a } = S(), [o, u] = f.useState(!1), [d, p] = f.useState({
|
|
509
519
|
email: a.email,
|
|
510
520
|
phone: a.phone
|
|
511
|
-
}),
|
|
512
|
-
const { name: I, value:
|
|
513
|
-
p(M),
|
|
521
|
+
}), _ = d.email && !a.email_is_verified && !o, y = d.phone && !a.phone_is_verified && !o, m = (P) => {
|
|
522
|
+
const { name: I, value: w } = P.target, M = { ...d, [I]: w };
|
|
523
|
+
p(M), u(JSON.stringify({ ...a, ...M }) !== JSON.stringify(a));
|
|
514
524
|
}, g = async () => {
|
|
515
|
-
await r({ ...a, ...d }),
|
|
525
|
+
await r({ ...a, ...d }), u(!1);
|
|
516
526
|
};
|
|
517
|
-
return /* @__PURE__ */ c(
|
|
527
|
+
return /* @__PURE__ */ c(h, { ref: t, children: [
|
|
518
528
|
/* @__PURE__ */ e(v, {}),
|
|
519
|
-
/* @__PURE__ */ c(
|
|
529
|
+
/* @__PURE__ */ c(h, { sx: { pt: 12 }, children: [
|
|
520
530
|
/* @__PURE__ */ e(F, { sx: { lineHeight: "20px", pb: 4, pt: 16 }, children: i.personal_details }),
|
|
521
|
-
/* @__PURE__ */ c(
|
|
522
|
-
n.display_email_edit_field_in_settings && /* @__PURE__ */ c(
|
|
531
|
+
/* @__PURE__ */ c(h, { sx: { flexDirection: s <= 768 ? "column" : "row", gap: 24, py: 16 }, children: [
|
|
532
|
+
n.display_email_edit_field_in_settings && /* @__PURE__ */ c(h, { sx: { flex: 1, pb: 14 }, children: [
|
|
523
533
|
/* @__PURE__ */ e(
|
|
524
534
|
U,
|
|
525
535
|
{
|
|
@@ -530,8 +540,8 @@ const Te = x(() => {
|
|
|
530
540
|
onChange: m
|
|
531
541
|
}
|
|
532
542
|
),
|
|
533
|
-
|
|
534
|
-
|
|
543
|
+
_ && /* @__PURE__ */ e(
|
|
544
|
+
W,
|
|
535
545
|
{
|
|
536
546
|
sx: {
|
|
537
547
|
height: 20,
|
|
@@ -546,7 +556,7 @@ const Te = x(() => {
|
|
|
546
556
|
}
|
|
547
557
|
)
|
|
548
558
|
] }),
|
|
549
|
-
n.display_sms_edit_field_in_settings && /* @__PURE__ */ c(
|
|
559
|
+
n.display_sms_edit_field_in_settings && /* @__PURE__ */ c(h, { sx: { flex: 1, pb: 14 }, children: [
|
|
550
560
|
/* @__PURE__ */ e(
|
|
551
561
|
U,
|
|
552
562
|
{
|
|
@@ -558,7 +568,7 @@ const Te = x(() => {
|
|
|
558
568
|
}
|
|
559
569
|
),
|
|
560
570
|
y && /* @__PURE__ */ e(
|
|
561
|
-
|
|
571
|
+
W,
|
|
562
572
|
{
|
|
563
573
|
sx: {
|
|
564
574
|
height: 20,
|
|
@@ -575,7 +585,7 @@ const Te = x(() => {
|
|
|
575
585
|
] })
|
|
576
586
|
] }),
|
|
577
587
|
/* @__PURE__ */ e(
|
|
578
|
-
|
|
588
|
+
j,
|
|
579
589
|
{
|
|
580
590
|
disabled: !o,
|
|
581
591
|
onClick: g,
|
|
@@ -586,18 +596,18 @@ const Te = x(() => {
|
|
|
586
596
|
)
|
|
587
597
|
] })
|
|
588
598
|
] });
|
|
589
|
-
}, Ie =
|
|
599
|
+
}, Ie = C(Se), ut = C(
|
|
590
600
|
({
|
|
591
601
|
notificationTypes: n = [b.Accounts, b.Budgets],
|
|
592
602
|
showPersonalDetails: t = !1,
|
|
593
603
|
view: s
|
|
594
604
|
}) => {
|
|
595
|
-
const { config: l } = q(), { settings: i } = k(), { isInitialized: r } =
|
|
605
|
+
const { config: l } = q(), { settings: i } = k(), { isInitialized: r } = he(), { isAccountDataLoaded: a, loadAccountData: o } = J(), { clientCommunicationProfile: u, loadNotificationProfiles: d } = T(), p = xe(), [_, y] = f.useState(!1), [m, g] = f.useState(
|
|
596
606
|
void 0
|
|
597
607
|
);
|
|
598
608
|
if (n.length > 0 && p && n.push(b.Insights), Ce({
|
|
599
609
|
widgetName: "NotificationSettingsWidget",
|
|
600
|
-
isLoaded:
|
|
610
|
+
isLoaded: _
|
|
601
611
|
}), f.useEffect(() => {
|
|
602
612
|
a || o().finally();
|
|
603
613
|
}, []), f.useEffect(() => {
|
|
@@ -608,20 +618,20 @@ const Te = x(() => {
|
|
|
608
618
|
m === b.Budgets ? P = i.manage_budget_notifications : m === b.Insights && (P = i.manage_insights_notifications);
|
|
609
619
|
const {
|
|
610
620
|
email_notifications_enabled: I,
|
|
611
|
-
sms_notifications_enabled:
|
|
621
|
+
sms_notifications_enabled: w,
|
|
612
622
|
push_notifications_enabled: M
|
|
613
|
-
} =
|
|
623
|
+
} = u, G = I || w || M;
|
|
614
624
|
if (s === "accounts")
|
|
615
625
|
return /* @__PURE__ */ e(z, {});
|
|
616
626
|
if (s === "budgets")
|
|
617
627
|
return /* @__PURE__ */ e($, {});
|
|
618
628
|
if (s === "insights")
|
|
619
629
|
return /* @__PURE__ */ e(H, {});
|
|
620
|
-
const Y = l.display_email_edit_field_in_settings || l.display_sms_edit_field_in_settings, Z = t &&
|
|
621
|
-
return /* @__PURE__ */ c(
|
|
622
|
-
/* @__PURE__ */ c(
|
|
623
|
-
|
|
624
|
-
/* @__PURE__ */ e(
|
|
630
|
+
const Y = l.display_email_edit_field_in_settings || l.display_sms_edit_field_in_settings, Z = t && u.can_edit_contact_info && Y;
|
|
631
|
+
return /* @__PURE__ */ c(h, { sx: { pt: G ? 0 : 24 }, children: [
|
|
632
|
+
/* @__PURE__ */ c(h, { sx: { px: 24 }, children: [
|
|
633
|
+
G && /* @__PURE__ */ c(N, { children: [
|
|
634
|
+
/* @__PURE__ */ e(Ae, {}),
|
|
625
635
|
/* @__PURE__ */ e(v, { sx: { my: 24 } })
|
|
626
636
|
] }),
|
|
627
637
|
/* @__PURE__ */ e(F, { sx: { mb: 4 }, children: i.notification_types_title })
|
|
@@ -629,25 +639,25 @@ const Te = x(() => {
|
|
|
629
639
|
/* @__PURE__ */ c(E, { children: [
|
|
630
640
|
n.includes(b.Accounts) && /* @__PURE__ */ e(O, { children: /* @__PURE__ */ c(V, { onClick: () => g(b.Accounts), children: [
|
|
631
641
|
/* @__PURE__ */ e(L, { primary: i.accounts_title, secondary: i.accounts_subtitle }),
|
|
632
|
-
/* @__PURE__ */ e(
|
|
642
|
+
/* @__PURE__ */ e(A, {})
|
|
633
643
|
] }) }),
|
|
634
644
|
n.includes(b.Budgets) && /* @__PURE__ */ e(O, { children: /* @__PURE__ */ c(V, { onClick: () => g(b.Budgets), children: [
|
|
635
645
|
/* @__PURE__ */ e(L, { primary: i.budgets_title, secondary: i.budgets_subtitle }),
|
|
636
|
-
/* @__PURE__ */ e(
|
|
646
|
+
/* @__PURE__ */ e(A, {})
|
|
637
647
|
] }) }),
|
|
638
648
|
n.includes(b.Insights) && /* @__PURE__ */ e(O, { children: /* @__PURE__ */ c(V, { onClick: () => g(b.Insights), children: [
|
|
639
649
|
/* @__PURE__ */ e(L, { primary: i.insights_title, secondary: i.insights_subtitle }),
|
|
640
|
-
/* @__PURE__ */ e(
|
|
650
|
+
/* @__PURE__ */ e(A, {})
|
|
641
651
|
] }) })
|
|
642
652
|
] }),
|
|
643
|
-
Z && /* @__PURE__ */ e(
|
|
653
|
+
Z && /* @__PURE__ */ e(h, { sx: { px: 24 }, children: /* @__PURE__ */ e(Ie, {}) }),
|
|
644
654
|
/* @__PURE__ */ e(
|
|
645
655
|
K,
|
|
646
656
|
{
|
|
647
657
|
isOpen: !!m,
|
|
648
658
|
onClose: () => g(void 0),
|
|
649
659
|
title: P,
|
|
650
|
-
children: /* @__PURE__ */ c(
|
|
660
|
+
children: /* @__PURE__ */ c(h, { children: [
|
|
651
661
|
m === b.Accounts && /* @__PURE__ */ e(z, {}),
|
|
652
662
|
m === b.Budgets && /* @__PURE__ */ e($, {}),
|
|
653
663
|
m === b.Insights && /* @__PURE__ */ e(H, {})
|
|
@@ -661,8 +671,8 @@ export {
|
|
|
661
671
|
z as A,
|
|
662
672
|
$ as B,
|
|
663
673
|
H as I,
|
|
664
|
-
|
|
674
|
+
ut as N,
|
|
665
675
|
Te as V,
|
|
666
676
|
De as a
|
|
667
677
|
};
|
|
668
|
-
//# sourceMappingURL=NotificationSettings-
|
|
678
|
+
//# sourceMappingURL=NotificationSettings-CW7okUrk.mjs.map
|