@mx-cartographer/experiences 7.0.35 → 7.0.36

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,156 +1,156 @@
1
- import { g as ue, T as m, G as _e, a as We, M as q, C as Ae, b as Ve } from "../GoalStore-D2A2Lqd5.mjs";
2
- import { c as Un, d as Yn } from "../GoalStore-D2A2Lqd5.mjs";
1
+ import { g as _e, T as m, G as me, a as Le, M as J, C as ye, b as Oe } from "../GoalStore-D2A2Lqd5.mjs";
2
+ import { c as Hn, d as $n } from "../GoalStore-D2A2Lqd5.mjs";
3
3
  import { jsxs as i, jsx as e, Fragment as U } from "react/jsx-runtime";
4
4
  import y from "react";
5
5
  import { observer as K } from "mobx-react-lite";
6
- import Pe from "@mui/material/Alert";
7
- import je from "@mui/material/Snackbar";
6
+ import We from "@mui/material/Alert";
7
+ import Pe from "@mui/material/Snackbar";
8
8
  import g from "@mui/material/Stack";
9
- import ce from "@mui/material/Tab";
10
- import Fe from "@mui/material/Tabs";
11
- import { Text as A, H2 as pe, P as V, H3 as ze, Icon as He, InstitutionLogo as oe } from "@mxenabled/mxui";
12
- import he from "@mui/material/Button";
13
- import Te from "@mui/material/Card";
14
- import Ce from "@mui/material/CardActionArea";
15
- import Se from "@mui/material/CardContent";
16
- import ge from "@mui/material/Unstable_Grid2";
17
- import ae from "@mui/material/Avatar";
18
- import $e from "@mui/material/CardHeader";
19
- import { Payments as Re, NoteStack as Ee, Person as ve, ChevronRight as M, DragHandle as Xe, CheckCircle as Ue, Icon as fe, ExpandLess as Ye, ExpandMore as Ze, AddBox as xe, Trophy as qe } from "@mxenabled/mx-icons";
20
- import { u as T, k as x, c as j, o as Ie, f as Ge, m as Je, a as Ne } from "../hooks-BhSK6dal.mjs";
21
- import { u as be } from "../useScreenSize-B6JyS_Lj.mjs";
9
+ import le from "@mui/material/Tab";
10
+ import Ve from "@mui/material/Tabs";
11
+ import { Text as A, H2 as ue, P as W, H3 as je, Icon as Fe, InstitutionLogo as ne } from "@mxenabled/mxui";
12
+ import pe from "@mui/material/Button";
13
+ import Ae from "@mui/material/Card";
14
+ import Te from "@mui/material/CardActionArea";
15
+ import Ce from "@mui/material/CardContent";
16
+ import be from "@mui/material/Unstable_Grid2";
17
+ import oe from "@mui/material/Avatar";
18
+ import ze from "@mui/material/CardHeader";
19
+ import { Payments as Se, NoteStack as Re, Person as Ee, ChevronRight as M, DragHandle as He, CheckCircle as $e, Icon as ge, ExpandLess as Xe, ExpandMore as Ue, AddBox as ve, Trophy as Ye } from "@mxenabled/mx-icons";
20
+ import { u as T, k as x, c as V, o as xe, f as Ie, a as Ge } from "../hooks-BhSK6dal.mjs";
21
+ import { u as he } from "../useScreenSize-B6JyS_Lj.mjs";
22
22
  import { f as v } from "../NumberFormatting-CtWHhyBX.mjs";
23
- import { S as Qe } from "../StatusBar-BK_uYHAB.mjs";
24
- import E from "@mui/material/Divider";
23
+ import { S as Ze } from "../StatusBar-BK_uYHAB.mjs";
24
+ import R from "@mui/material/Divider";
25
25
  import L from "@mui/material/List";
26
- import { L as Q } from "../ListItemAction-Dt9A2GQk.mjs";
27
- import { C as ke } from "../CurrencyInput-C0wTgNV6.mjs";
28
- import { fromUnixTime as J } from "date-fns/fromUnixTime";
26
+ import { L as ee } from "../ListItemAction-Dt9A2GQk.mjs";
27
+ import { C as Ne } from "../CurrencyInput-C0wTgNV6.mjs";
28
+ import { fromUnixTime as Q } from "date-fns/fromUnixTime";
29
29
  import N from "@mui/material/ListItem";
30
30
  import k from "@mui/material/ListItemButton";
31
31
  import w from "@mui/material/ListItemText";
32
- import { DataGridPro as et } from "@mui/x-data-grid-pro";
33
- import { D as F } from "../Drawer-kEE73B87.mjs";
32
+ import { DataGridPro as qe } from "@mui/x-data-grid-pro";
33
+ import { D as j } from "../Drawer-kEE73B87.mjs";
34
34
  import { b as B } from "../Localization-2MODESHW.mjs";
35
- import { f as re, D as ie, a as tt } from "../Dialog-CWW597AF.mjs";
35
+ import { f as ae, D as re, a as Je } from "../Dialog-CWW597AF.mjs";
36
36
  import P from "@mui/material/ListItemAvatar";
37
- import nt from "@mui/material/Collapse";
38
- import ot from "@mui/material/ListItemIcon";
39
- import at from "@mui/material/Checkbox";
40
- import { A as ye } from "../ConnectDrawer-jeSmGg38.mjs";
41
- import { u as rt, A as it } from "../AccountDetailsHeader-BCW4d-j4.mjs";
42
- import { A as st } from "../AccountDetailsContent-BwTOak3W.mjs";
43
- import we from "@mui/material/TextField";
44
- import { M as lt, I as ct, O as dt } from "../OriginalBalanceAction-CqQ5j4OW.mjs";
45
- import { getUnixTime as mt } from "date-fns/getUnixTime";
46
- import { isValid as _t } from "date-fns/isValid";
47
- import { AdapterDateFns as ut } from "@mui/x-date-pickers/AdapterDateFnsV3";
48
- import { DatePicker as pt } from "@mui/x-date-pickers";
49
- import { LocalizationProvider as ht } from "@mui/x-date-pickers/LocalizationProvider";
50
- import { E as bt } from "../EmptyState-C0lr9E5T.mjs";
51
- import { A as Y, W as gt } from "../WidgetContainer-CPBhSP3k.mjs";
52
- import { L as Ke } from "../Loader-DUaFpDGv.mjs";
53
- import ft from "@mui/material/Stack/Stack";
54
- import yt from "@mui/material/Box";
55
- import At from "@mui/material/styles/useTheme";
56
- import { S as Tt } from "../SingleSegmentDonut-BgbLgwHi.mjs";
57
- import { M as Ct } from "../MicroWidgetContainer-DVRe-MJs.mjs";
58
- function de({ title: t, subtitle: n }) {
37
+ import Qe from "@mui/material/Collapse";
38
+ import et from "@mui/material/ListItemIcon";
39
+ import tt from "@mui/material/Checkbox";
40
+ import { A as fe } from "../ConnectDrawer-jeSmGg38.mjs";
41
+ import { u as nt, A as ot } from "../AccountDetailsHeader-BCW4d-j4.mjs";
42
+ import { A as at } from "../AccountDetailsContent-r2edUIO6.mjs";
43
+ import ke from "@mui/material/TextField";
44
+ import { M as rt, I as it, O as st } from "../OriginalBalanceAction-CqQ5j4OW.mjs";
45
+ import { getUnixTime as lt } from "date-fns/getUnixTime";
46
+ import { isValid as ct } from "date-fns/isValid";
47
+ import { AdapterDateFns as dt } from "@mui/x-date-pickers/AdapterDateFnsV3";
48
+ import { DatePicker as mt } from "@mui/x-date-pickers";
49
+ import { LocalizationProvider as _t } from "@mui/x-date-pickers/LocalizationProvider";
50
+ import { E as ut } from "../EmptyState-C0lr9E5T.mjs";
51
+ import { A as Y, W as pt } from "../WidgetContainer-C6H2vwT9.mjs";
52
+ import { L as we } from "../Loader-DUaFpDGv.mjs";
53
+ import ht from "@mui/material/Stack/Stack";
54
+ import bt from "@mui/material/Box";
55
+ import gt from "@mui/material/styles/useTheme";
56
+ import { S as ft } from "../SingleSegmentDonut-BgbLgwHi.mjs";
57
+ import { M as yt } from "../MicroWidgetContainer-DVRe-MJs.mjs";
58
+ function ce({ title: t, subtitle: n }) {
59
59
  return /* @__PURE__ */ i(g, { children: [
60
60
  /* @__PURE__ */ e(A, { bold: !0, variant: "Body", children: t }),
61
61
  /* @__PURE__ */ e(A, { sx: { fontWeight: 400 }, variant: "Body", children: n })
62
62
  ] });
63
63
  }
64
- const St = (t, n) => n ? v(t, t < 1e3 ? "0" : "0.00a").replace(
64
+ const At = (t, n) => n ? v(t, t < 1e3 ? "0" : "0.00a").replace(
65
65
  /(\d+)(?:\.0+|(\.\d*?[1-9])0*)([a-zA-Z]* ?\$?)/g,
66
66
  "$1$2$3"
67
- ) : v(t, "0,0.00"), De = K(
68
- ({ goal: t, isInDrawer: n = !1, onClick: l }) => {
69
- const { goals: d } = T(), { isMobile: _, isTablet: a } = be(), u = _ || a, {
70
- backgroundColor: p,
71
- color: b,
72
- percentage: s,
67
+ ) : v(t, "0,0.00"), Ke = K(
68
+ ({ goal: t, isInDrawer: n = !1, onClick: s }) => {
69
+ const { goals: l } = T(), { isMobile: u, isTablet: a } = he(), _ = u || a, {
70
+ backgroundColor: b,
71
+ color: c,
72
+ percentage: h,
73
73
  percentageText: o,
74
- projectedText: h
75
- } = ue(d, t), r = t.track_type === m.DEBT_TRACK ? t.initial_amount : t.amount, c = [
74
+ projectedText: p
75
+ } = _e(l, t), r = t.track_type === m.DEBT_TRACK ? t.initial_amount : t.amount, d = [
76
76
  {
77
- color: p,
78
- percentage: `${s}`
77
+ color: b,
78
+ percentage: `${h}`
79
79
  }
80
80
  ];
81
- let f = /* @__PURE__ */ e(Re, {});
82
- return t.track_type === m.DEBT_TRACK ? f = /* @__PURE__ */ e(Ee, {}) : t.track_type === m.RETIREMENT_TRACK && (f = /* @__PURE__ */ e(ve, {})), /* @__PURE__ */ e(Te, { elevation: 2, children: /* @__PURE__ */ i(Ce, { disabled: !l, onClick: l, children: [
81
+ let f = /* @__PURE__ */ e(Se, {});
82
+ return t.track_type === m.DEBT_TRACK ? f = /* @__PURE__ */ e(Re, {}) : t.track_type === m.RETIREMENT_TRACK && (f = /* @__PURE__ */ e(Ee, {})), /* @__PURE__ */ e(Ae, { elevation: 2, children: /* @__PURE__ */ i(Te, { disabled: !s, onClick: s, children: [
83
83
  /* @__PURE__ */ e(
84
- $e,
84
+ ze,
85
85
  {
86
- avatar: /* @__PURE__ */ e(ae, { sx: { bgcolor: p, color: b, height: 48, width: 48 }, variant: "rounded", children: f }),
87
- subheader: /* @__PURE__ */ e(A, { variant: n || u ? "H3" : "H2", children: `${v(t.current_amount, u ? "0,0" : "0,0.00")} / ${St(
86
+ avatar: /* @__PURE__ */ e(oe, { sx: { bgcolor: b, color: c, height: 48, width: 48 }, variant: "rounded", children: f }),
87
+ subheader: /* @__PURE__ */ e(A, { variant: n || _ ? "H3" : "H2", children: `${v(t.current_amount, _ ? "0,0" : "0,0.00")} / ${At(
88
88
  r,
89
- u
89
+ _
90
90
  )}` }),
91
- title: /* @__PURE__ */ e(pe, { color: "text.secondary", fontWeight: 400, variant: "Body", children: t.name })
91
+ title: /* @__PURE__ */ e(ue, { color: "text.secondary", fontWeight: 400, variant: "Body", children: t.name })
92
92
  }
93
93
  ),
94
- /* @__PURE__ */ e(Se, { sx: { pt: 0 }, children: /* @__PURE__ */ i(g, { gap: 6, children: [
95
- /* @__PURE__ */ e(Qe, { data: c, height: 24 }),
94
+ /* @__PURE__ */ e(Ce, { sx: { pt: 0 }, children: /* @__PURE__ */ i(g, { gap: 6, children: [
95
+ /* @__PURE__ */ e(Ze, { data: d, height: 24 }),
96
96
  /* @__PURE__ */ i(g, { alignItems: "center", direction: "row", justifyContent: "space-between", children: [
97
97
  /* @__PURE__ */ e(A, { color: "text.secondary", variant: "XSmall", children: o }),
98
- t.projected_to_complete_at && /* @__PURE__ */ e(A, { color: "text.secondary", variant: "XSmall", children: h })
98
+ t.projected_to_complete_at && /* @__PURE__ */ e(A, { color: "text.secondary", variant: "XSmall", children: p })
99
99
  ] })
100
100
  ] }) })
101
101
  ] }) });
102
102
  }
103
- ), Rt = K(({ trackType: t }) => {
104
- const { goals: n } = T(), { setAlert: l, monthlyCashFlowProfile: d, updateMonthlyCashFlowProfile: _ } = x(), a = y.useMemo(() => {
105
- let s = 0;
106
- return t === m.SAVINGS_TRACK ? s = d?.amount_allocated_for_savings_goals || 0 : t === m.DEBT_TRACK ? s = d?.amount_allocated_for_debt_goals || 0 : t === m.RETIREMENT_TRACK && (s = d?.amount_allocated_for_retirement_goals || 0), s;
107
- }, [d]), [u, p] = y.useState(a), b = async () => {
108
- if (d) {
109
- const s = { ...d };
110
- t === m.SAVINGS_TRACK ? s.amount_allocated_for_savings_goals = u : t === m.DEBT_TRACK ? s.amount_allocated_for_debt_goals = u : t === m.RETIREMENT_TRACK && (s.amount_allocated_for_retirement_goals = u), await _(s), l(n.alert_contribution_updated);
103
+ ), Tt = K(({ trackType: t }) => {
104
+ const { goals: n } = T(), { setAlert: s, monthlyCashFlowProfile: l, updateMonthlyCashFlowProfile: u } = x(), a = y.useMemo(() => {
105
+ let h = 0;
106
+ return t === m.SAVINGS_TRACK ? h = l?.amount_allocated_for_savings_goals || 0 : t === m.DEBT_TRACK ? h = l?.amount_allocated_for_debt_goals || 0 : t === m.RETIREMENT_TRACK && (h = l?.amount_allocated_for_retirement_goals || 0), h;
107
+ }, [l]), [_, b] = y.useState(a), c = async () => {
108
+ if (l) {
109
+ const h = { ...l };
110
+ t === m.SAVINGS_TRACK ? h.amount_allocated_for_savings_goals = _ : t === m.DEBT_TRACK ? h.amount_allocated_for_debt_goals = _ : t === m.RETIREMENT_TRACK && (h.amount_allocated_for_retirement_goals = _), await u(h), s(n.alert_contribution_updated);
111
111
  }
112
112
  };
113
113
  return /* @__PURE__ */ e(g, { bgcolor: "background.paper", children: /* @__PURE__ */ e(
114
- Q,
114
+ ee,
115
115
  {
116
- isSaveDisabled: !u || isNaN(u),
116
+ isSaveDisabled: !_ || isNaN(_),
117
117
  label: n.contribution_label,
118
- onCancel: () => p(a),
119
- onSave: b,
118
+ onCancel: () => b(a),
119
+ onSave: c,
120
120
  primaryText: n.contribution_label,
121
121
  secondaryText: v(a, "0,0.00"),
122
122
  children: /* @__PURE__ */ e(
123
- ke,
123
+ Ne,
124
124
  {
125
- amount: u,
125
+ amount: _,
126
126
  autoFocus: !0,
127
- error: !u || isNaN(u),
127
+ error: !_ || isNaN(_),
128
128
  fullWidth: !0,
129
129
  minAmount: 0,
130
- setAmount: (s) => p(isNaN(Number(s)) ? u : Number(s)),
130
+ setAmount: (h) => b(isNaN(Number(h)) ? _ : Number(h)),
131
131
  sx: { ".MuiTypography-Body": { p: 0 } }
132
132
  }
133
133
  )
134
134
  }
135
135
  ) });
136
- }), Et = ({ goals: t }) => {
137
- const { goals: n, common: l } = T(), { reorderGoals: d, setAlert: _ } = x(), [a, u] = y.useState(!1), [p, b] = y.useState(t.map((c) => ({ ...c })));
136
+ }), Ct = ({ goals: t }) => {
137
+ const { goals: n, common: s } = T(), { reorderGoals: l, setAlert: u } = x(), [a, _] = y.useState(!1), [b, c] = y.useState(t.map((d) => ({ ...d })));
138
138
  y.useEffect(() => {
139
- a && b(t.map((c) => ({ ...c })));
139
+ a && c(t.map((d) => ({ ...d })));
140
140
  }, [a]);
141
- const s = [
141
+ const h = [
142
142
  {
143
143
  field: "name",
144
144
  flex: 1,
145
- renderCell: (c) => {
146
- const f = c.row;
145
+ renderCell: (d) => {
146
+ const f = d.row;
147
147
  return /* @__PURE__ */ i(g, { children: [
148
148
  /* @__PURE__ */ e(A, { bold: !0, variant: "Body", children: f.name }),
149
149
  /* @__PURE__ */ e(A, { variant: "XSmall", children: B(
150
150
  n.goal_projection,
151
- re(
152
- J(f.projected_to_complete_at || 0),
153
- ie.MONTH_SHORT_YEAR
151
+ ae(
152
+ Q(f.projected_to_complete_at || 0),
153
+ re.MONTH_SHORT_YEAR
154
154
  )
155
155
  ) })
156
156
  ] });
@@ -161,28 +161,28 @@ const St = (t, n) => n ? v(t, t < 1e3 ? "0" : "0.00a").replace(
161
161
  align: "right",
162
162
  field: "amount",
163
163
  minWidth: 140,
164
- renderCell: (c) => {
165
- const f = c.row;
164
+ renderCell: (d) => {
165
+ const f = d.row;
166
166
  return /* @__PURE__ */ e(A, { bold: !0, sx: { mr: 12 }, variant: "Body", children: v(f.amount, "0,0.00") });
167
167
  },
168
168
  sortable: !1
169
169
  }
170
- ], o = p.map((c) => ({
171
- id: c.guid,
170
+ ], o = b.map((d) => ({
171
+ id: d.guid,
172
172
  isHovering: !1,
173
- __reorder__: c.name,
174
- ...c
175
- })), h = ({ oldIndex: c, targetIndex: f }) => {
176
- const S = [...p];
177
- S.splice(f, 0, S.splice(c, 1)[0]);
178
- for (let C = 0; C < S.length; C += 1)
179
- S[C].position = C + 1;
180
- b(S);
173
+ __reorder__: d.name,
174
+ ...d
175
+ })), p = ({ oldIndex: d, targetIndex: f }) => {
176
+ const E = [...b];
177
+ E.splice(f, 0, E.splice(d, 1)[0]);
178
+ for (let C = 0; C < E.length; C += 1)
179
+ E[C].position = C + 1;
180
+ c(E);
181
181
  }, r = async () => {
182
- await d(p), _(n.alert_goals_reordered), u(!1);
182
+ await l(b), u(n.alert_goals_reordered), _(!1);
183
183
  };
184
184
  return /* @__PURE__ */ i(g, { children: [
185
- /* @__PURE__ */ e(N, { children: /* @__PURE__ */ e(k, { onClick: () => u(!0), children: /* @__PURE__ */ e(w, { children: /* @__PURE__ */ i(
185
+ /* @__PURE__ */ e(N, { children: /* @__PURE__ */ e(k, { onClick: () => _(!0), children: /* @__PURE__ */ e(w, { children: /* @__PURE__ */ i(
186
186
  g,
187
187
  {
188
188
  alignItems: "center",
@@ -196,28 +196,28 @@ const St = (t, n) => n ? v(t, t < 1e3 ? "0" : "0.00a").replace(
196
196
  }
197
197
  ) }) }) }),
198
198
  /* @__PURE__ */ e(
199
- F,
199
+ j,
200
200
  {
201
- ariaLabelClose: l.close_aria,
201
+ ariaLabelClose: s.close_aria,
202
202
  isOpen: a,
203
- onClose: () => u(!1),
203
+ onClose: () => _(!1),
204
204
  onPrimaryAction: r,
205
205
  title: n.reorder_goals_title,
206
206
  children: /* @__PURE__ */ i(g, { children: [
207
- /* @__PURE__ */ e(V, { sx: { my: 12, mx: 24 }, children: n.reorder_goals_description }),
207
+ /* @__PURE__ */ e(W, { sx: { my: 12, mx: 24 }, children: n.reorder_goals_description }),
208
208
  /* @__PURE__ */ e(
209
- et,
209
+ qe,
210
210
  {
211
211
  columnHeaderHeight: 0,
212
- columns: s,
212
+ columns: h,
213
213
  disableColumnFilter: !0,
214
214
  disableColumnMenu: !0,
215
215
  hideFooter: !0,
216
- onRowOrderChange: h,
216
+ onRowOrderChange: p,
217
217
  rowReordering: !0,
218
218
  rows: o,
219
219
  slots: {
220
- rowReorderIcon: () => /* @__PURE__ */ e(Xe, { sx: { ml: 12 } })
220
+ rowReorderIcon: () => /* @__PURE__ */ e(He, { sx: { ml: 12 } })
221
221
  //TODO: Add to mx-icons
222
222
  },
223
223
  sx: {
@@ -231,8 +231,8 @@ const St = (t, n) => n ? v(t, t < 1e3 ? "0" : "0.00a").replace(
231
231
  }
232
232
  )
233
233
  ] });
234
- }, vt = ({ goal: t, index: n }) => {
235
- const { goals: l } = T(), { percentage: d } = ue(l, t), _ = t.goal_type === _e.KEEP_BALANCE_BELOW || t.has_been_spent ? l.goal_completed : B(l.goal_percentage_reached, `${d * 100}`);
234
+ }, St = ({ goal: t, index: n }) => {
235
+ const { goals: s } = T(), { percentage: l } = _e(s, t), u = t.goal_type === me.KEEP_BALANCE_BELOW || t.has_been_spent ? s.goal_completed : B(s.goal_percentage_reached, `${l * 100}`);
236
236
  return /* @__PURE__ */ e(N, { children: /* @__PURE__ */ i(k, { children: [
237
237
  t.track_type !== m.RETIREMENT_TRACK && /* @__PURE__ */ e(
238
238
  P,
@@ -243,110 +243,110 @@ const St = (t, n) => n ? v(t, t < 1e3 ? "0" : "0.00a").replace(
243
243
  justifyContent: "center",
244
244
  ".MuiAvatar-root": { height: "16px", width: "16px" }
245
245
  },
246
- children: /* @__PURE__ */ e(ae, { sx: { bgcolor: "text.primary", height: "16px", width: "16px" }, children: /* @__PURE__ */ e(A, { bold: !0, variant: "XSmall", children: n + 1 }) })
246
+ children: /* @__PURE__ */ e(oe, { sx: { bgcolor: "text.primary", height: "16px", width: "16px" }, children: /* @__PURE__ */ e(A, { bold: !0, variant: "XSmall", children: n + 1 }) })
247
247
  }
248
248
  ),
249
249
  /* @__PURE__ */ e(w, { primaryTypographyProps: { variant: "Body" }, children: /* @__PURE__ */ i(g, { alignItems: "center", direction: "row", justifyContent: "space-between", children: [
250
250
  /* @__PURE__ */ i(g, { children: [
251
251
  /* @__PURE__ */ e(A, { bold: !0, variant: "Body", children: t.name }),
252
- /* @__PURE__ */ e(A, { variant: "XSmall", children: t.is_complete ? _ : B(
253
- l.goal_projection,
254
- re(
255
- J(t.projected_to_complete_at || 0),
256
- ie.MONTH_SHORT_YEAR
252
+ /* @__PURE__ */ e(A, { variant: "XSmall", children: t.is_complete ? u : B(
253
+ s.goal_projection,
254
+ ae(
255
+ Q(t.projected_to_complete_at || 0),
256
+ re.MONTH_SHORT_YEAR
257
257
  )
258
258
  ) })
259
259
  ] }),
260
260
  /* @__PURE__ */ e(A, { bold: !0, variant: "Body", children: v(t.amount, "0,0.00") })
261
261
  ] }) })
262
262
  ] }) });
263
- }, xt = ({ goal: t }) => {
263
+ }, Rt = ({ goal: t }) => {
264
264
  const { goals: n } = T();
265
265
  return /* @__PURE__ */ e(N, { children: /* @__PURE__ */ i(k, { children: [
266
- /* @__PURE__ */ e(P, { sx: { alignItems: "center", display: "flex", justifyContent: "center" }, children: /* @__PURE__ */ e(Ue, { color: "success", filled: !0, size: 20 }) }),
266
+ /* @__PURE__ */ e(P, { sx: { alignItems: "center", display: "flex", justifyContent: "center" }, children: /* @__PURE__ */ e($e, { color: "success", filled: !0, size: 20 }) }),
267
267
  /* @__PURE__ */ e(w, { primaryTypographyProps: { variant: "Body" }, children: /* @__PURE__ */ i(g, { alignItems: "center", direction: "row", justifyContent: "space-between", children: [
268
268
  /* @__PURE__ */ i(g, { children: [
269
269
  /* @__PURE__ */ e(A, { bold: !0, variant: "Body", children: t.name }),
270
270
  /* @__PURE__ */ e(A, { variant: "XSmall", children: B(
271
271
  n.completed_label,
272
- re(
273
- J(t.completed_at || 0),
274
- ie.MONTH_SHORT_YEAR
272
+ ae(
273
+ Q(t.completed_at || 0),
274
+ re.MONTH_SHORT_YEAR
275
275
  )
276
276
  ) })
277
277
  ] }),
278
278
  /* @__PURE__ */ e(A, { bold: !0, variant: "Body", children: v(t.amount, "0,0.00") })
279
279
  ] }) })
280
280
  ] }) }, t.guid);
281
- }, It = ({ trackType: t }) => {
282
- const { goals: n, common: l } = T(), { orderedGoals: d } = x(), _ = d.filter((c) => c.track_type === t), a = _.filter(
283
- (c) => c.track_type === m.SAVINGS_TRACK && !c.has_been_spent || c.track_type !== m.SAVINGS_TRACK && !c.is_complete
284
- ), u = _.filter(
285
- (c) => c.track_type === m.SAVINGS_TRACK && c.has_been_spent || c.track_type !== m.SAVINGS_TRACK && c.is_complete
286
- ), [p, b] = y.useState(!1);
287
- let s = n.manage_saving_goals, o = n.manage_saving_drawer_title, h = n.manage_saving_title, r = n.manage_saving_description;
288
- return t === m.DEBT_TRACK ? (s = n.manage_debt_goals, o = n.manage_debt_drawer_title, h = n.manage_debt_title, r = n.manage_debt_description) : t === m.RETIREMENT_TRACK && (s = n.manage_retirement_goals, o = n.manage_retirement_drawer_title, h = n.manage_retirement_title, r = n.manage_retirement_description), /* @__PURE__ */ i(g, { children: [
289
- /* @__PURE__ */ e(he, { endIcon: /* @__PURE__ */ e(M, {}), onClick: () => b(!0), children: s }),
281
+ }, Et = ({ trackType: t }) => {
282
+ const { goals: n, common: s } = T(), { orderedGoals: l } = x(), u = l.filter((d) => d.track_type === t), a = u.filter(
283
+ (d) => d.track_type === m.SAVINGS_TRACK && !d.has_been_spent || d.track_type !== m.SAVINGS_TRACK && !d.is_complete
284
+ ), _ = u.filter(
285
+ (d) => d.track_type === m.SAVINGS_TRACK && d.has_been_spent || d.track_type !== m.SAVINGS_TRACK && d.is_complete
286
+ ), [b, c] = y.useState(!1);
287
+ let h = n.manage_saving_goals, o = n.manage_saving_drawer_title, p = n.manage_saving_title, r = n.manage_saving_description;
288
+ return t === m.DEBT_TRACK ? (h = n.manage_debt_goals, o = n.manage_debt_drawer_title, p = n.manage_debt_title, r = n.manage_debt_description) : t === m.RETIREMENT_TRACK && (h = n.manage_retirement_goals, o = n.manage_retirement_drawer_title, p = n.manage_retirement_title, r = n.manage_retirement_description), /* @__PURE__ */ i(g, { children: [
289
+ /* @__PURE__ */ e(pe, { endIcon: /* @__PURE__ */ e(M, {}), onClick: () => c(!0), children: h }),
290
290
  /* @__PURE__ */ e(
291
- F,
291
+ j,
292
292
  {
293
- ariaLabelClose: l.close_aria,
294
- isOpen: p,
295
- onClose: () => b(!1),
293
+ ariaLabelClose: s.close_aria,
294
+ isOpen: b,
295
+ onClose: () => c(!1),
296
296
  title: o,
297
297
  children: /* @__PURE__ */ i(g, { children: [
298
298
  /* @__PURE__ */ i(g, { m: 24, children: [
299
- /* @__PURE__ */ e(ze, { children: h }),
300
- /* @__PURE__ */ e(V, { color: "text.secondary", sx: { textWrap: "wrap" }, variant: "ParagraphSmall", children: r })
299
+ /* @__PURE__ */ e(je, { children: p }),
300
+ /* @__PURE__ */ e(W, { color: "text.secondary", sx: { textWrap: "wrap" }, variant: "ParagraphSmall", children: r })
301
301
  ] }),
302
- /* @__PURE__ */ e(Rt, { trackType: t }),
302
+ /* @__PURE__ */ e(Tt, { trackType: t }),
303
303
  /* @__PURE__ */ e(A, { bold: !0, sx: { mb: 4, mx: 24, mt: 12 }, variant: "XSmall", children: n.goal_priority }),
304
304
  /* @__PURE__ */ i(L, { sx: { bgcolor: "background.paper" }, children: [
305
- a.map((c, f) => {
306
- const S = f >= a.length - 1;
305
+ a.map((d, f) => {
306
+ const E = f >= a.length - 1;
307
307
  return /* @__PURE__ */ i(g, { children: [
308
- /* @__PURE__ */ e(vt, { goal: c, index: f }),
308
+ /* @__PURE__ */ e(St, { goal: d, index: f }),
309
309
  /* @__PURE__ */ e(
310
- E,
310
+ R,
311
311
  {
312
- variant: S && t === m.RETIREMENT_TRACK ? "fullWidth" : "inset"
312
+ variant: E && t === m.RETIREMENT_TRACK ? "fullWidth" : "inset"
313
313
  }
314
314
  )
315
- ] }, `ongoing-${c.guid}`);
315
+ ] }, `ongoing-${d.guid}`);
316
316
  }),
317
317
  t !== m.RETIREMENT_TRACK && /* @__PURE__ */ i(g, { children: [
318
- /* @__PURE__ */ e(Et, { goals: a }),
319
- /* @__PURE__ */ e(E, {})
318
+ /* @__PURE__ */ e(Ct, { goals: a }),
319
+ /* @__PURE__ */ e(R, {})
320
320
  ] })
321
321
  ] }),
322
- t !== m.RETIREMENT_TRACK && u.length > 0 && /* @__PURE__ */ i(g, { children: [
322
+ t !== m.RETIREMENT_TRACK && _.length > 0 && /* @__PURE__ */ i(g, { children: [
323
323
  /* @__PURE__ */ e(A, { bold: !0, sx: { mb: 4, mx: 24, mt: 12 }, variant: "XSmall", children: n.complete_title }),
324
- /* @__PURE__ */ e(L, { sx: { bgcolor: "background.paper" }, children: u.map((c, f) => {
325
- const S = f > a.length - 1;
324
+ /* @__PURE__ */ e(L, { sx: { bgcolor: "background.paper" }, children: _.map((d, f) => {
325
+ const E = f > a.length - 1;
326
326
  return /* @__PURE__ */ i(g, { children: [
327
- /* @__PURE__ */ e(xt, { goal: c }),
328
- /* @__PURE__ */ e(E, { variant: S ? "fullWidth" : "inset" })
329
- ] }, `complete-${c.guid}`);
327
+ /* @__PURE__ */ e(Rt, { goal: d }),
328
+ /* @__PURE__ */ e(R, { variant: E ? "fullWidth" : "inset" })
329
+ ] }, `complete-${d.guid}`);
330
330
  }) })
331
331
  ] })
332
332
  ] })
333
333
  }
334
334
  )
335
335
  ] });
336
- }, me = K(({ trackType: t, onAddGoals: n }) => {
337
- const { isMobile: l } = be(), { goals: d } = T(), { orderedGoals: _, setSelectedGoal: a } = x(), u = _.filter((o) => o.track_type === t), p = u.filter(
336
+ }, de = K(({ trackType: t, onAddGoals: n }) => {
337
+ const { isMobile: s } = he(), { goals: l } = T(), { orderedGoals: u, setSelectedGoal: a } = x(), _ = u.filter((o) => o.track_type === t), b = _.filter(
338
338
  (o) => o.track_type === m.SAVINGS_TRACK && !o.has_been_spent || o.track_type !== m.SAVINGS_TRACK && !o.is_complete
339
- ), b = u.filter(
339
+ ), c = _.filter(
340
340
  (o) => o.track_type === m.SAVINGS_TRACK && o.has_been_spent || o.track_type !== m.SAVINGS_TRACK && o.is_complete
341
- ), s = t === m.DEBT_TRACK ? d.zero_state_complete_debt : d.zero_state_complete_savings;
342
- return /* @__PURE__ */ i(g, { mt: 16, mx: l ? 24 : 0, children: [
341
+ ), h = t === m.DEBT_TRACK ? l.zero_state_complete_debt : l.zero_state_complete_savings;
342
+ return /* @__PURE__ */ i(g, { mt: 16, mx: s ? 24 : 0, children: [
343
343
  /* @__PURE__ */ i(g, { alignItems: "center", direction: "row", justifyContent: "space-between", mb: 8, children: [
344
- /* @__PURE__ */ e(A, { color: "text.secondary", variant: "Small", children: d.ongoing_title }),
345
- /* @__PURE__ */ e(It, { trackType: t })
344
+ /* @__PURE__ */ e(A, { color: "text.secondary", variant: "Small", children: l.ongoing_title }),
345
+ /* @__PURE__ */ e(Et, { trackType: t })
346
346
  ] }),
347
- p.length > 0 ? /* @__PURE__ */ e(ge, { container: !0, spacing: 24, children: p.map((o, h, r) => (
347
+ b.length > 0 ? /* @__PURE__ */ e(be, { container: !0, spacing: 24, children: b.map((o, p, r) => (
348
348
  // Goal should be full width in mobile or if it's the first goal (unless there are 2)
349
- /* @__PURE__ */ e(ge, { xs: l || h === 0 && r.length !== 2 ? 12 : 6, children: /* @__PURE__ */ e(De, { goal: o, onClick: () => a(o) }, o.guid) }, h)
349
+ /* @__PURE__ */ e(be, { xs: s || p === 0 && r.length !== 2 ? 12 : 6, children: /* @__PURE__ */ e(Ke, { goal: o, onClick: () => a(o) }, o.guid) }, p)
350
350
  )) }) : /* @__PURE__ */ i(
351
351
  g,
352
352
  {
@@ -358,7 +358,7 @@ const St = (t, n) => n ? v(t, t < 1e3 ? "0" : "0.00a").replace(
358
358
  py: 18,
359
359
  children: [
360
360
  /* @__PURE__ */ e(
361
- V,
361
+ W,
362
362
  {
363
363
  sx: (o) => ({
364
364
  color: "text.secondary",
@@ -368,17 +368,17 @@ const St = (t, n) => n ? v(t, t < 1e3 ? "0" : "0.00a").replace(
368
368
  width: { sm: 381 }
369
369
  }),
370
370
  variant: "Small",
371
- children: We(t, d)
371
+ children: Le(t, l)
372
372
  }
373
373
  ),
374
- /* @__PURE__ */ e(he, { onClick: n, sx: { mt: 16, width: { sm: 224 } }, variant: "contained", children: d.add_goals_button })
374
+ /* @__PURE__ */ e(pe, { onClick: n, sx: { mt: 16, width: { sm: 224 } }, variant: "contained", children: l.add_goals_button })
375
375
  ]
376
376
  }
377
377
  ),
378
378
  t !== m.RETIREMENT_TRACK && /* @__PURE__ */ i(g, { gap: 16, mt: 48, children: [
379
- /* @__PURE__ */ e(A, { color: "text.secondary", variant: "Small", children: d.complete_title }),
380
- b.length === 0 && /* @__PURE__ */ e(g, { alignItems: "center", bgcolor: "background.default", borderRadius: 2, py: 18, children: /* @__PURE__ */ e(
381
- V,
379
+ /* @__PURE__ */ e(A, { color: "text.secondary", variant: "Small", children: l.complete_title }),
380
+ c.length === 0 && /* @__PURE__ */ e(g, { alignItems: "center", bgcolor: "background.default", borderRadius: 2, py: 18, children: /* @__PURE__ */ e(
381
+ W,
382
382
  {
383
383
  sx: (o) => ({
384
384
  color: "text.secondary",
@@ -388,40 +388,40 @@ const St = (t, n) => n ? v(t, t < 1e3 ? "0" : "0.00a").replace(
388
388
  }
389
389
  }),
390
390
  variant: "Small",
391
- children: s
391
+ children: h
392
392
  }
393
393
  ) }),
394
- b.map((o) => /* @__PURE__ */ e(Te, { elevation: 2, children: /* @__PURE__ */ e(Ce, { onClick: () => a(o), children: /* @__PURE__ */ e(Se, { sx: { ":last-child": { pb: 16 } }, children: /* @__PURE__ */ i(g, { alignItems: "center", direction: "row", justifyContent: "space-between", children: [
394
+ c.map((o) => /* @__PURE__ */ e(Ae, { elevation: 2, children: /* @__PURE__ */ e(Te, { onClick: () => a(o), children: /* @__PURE__ */ e(Ce, { sx: { ":last-child": { pb: 16 } }, children: /* @__PURE__ */ i(g, { alignItems: "center", direction: "row", justifyContent: "space-between", children: [
395
395
  /* @__PURE__ */ i(g, { alignItems: "center", direction: "row", gap: 6, children: [
396
- /* @__PURE__ */ e(He, { color: "success", fill: !0, name: "check_circle", size: 20 }),
396
+ /* @__PURE__ */ e(Fe, { color: "success", fill: !0, name: "check_circle", size: 20 }),
397
397
  /* @__PURE__ */ e(A, { color: "text.secondary", variant: "Body", children: o.name })
398
398
  ] }),
399
399
  /* @__PURE__ */ e(A, { bold: !0, variant: "Body", children: v(o.amount, "0,0.00") })
400
400
  ] }) }) }) }, o.guid))
401
401
  ] })
402
402
  ] });
403
- }), Gt = ({ goalType: t, onClick: n }) => {
404
- const { goals: l } = T(), { bgcolor: d, icon: _, label: a, description: u, subTypes: p, type: b } = t, [s, o] = y.useState(!1), h = p.length > 0;
403
+ }), vt = ({ goalType: t, onClick: n }) => {
404
+ const { goals: s } = T(), { bgcolor: l, icon: u, label: a, description: _, subTypes: b, type: c } = t, [h, o] = y.useState(!1), p = b.length > 0;
405
405
  return /* @__PURE__ */ e(g, { children: /* @__PURE__ */ i(L, { sx: { bgcolor: "background.paper" }, children: [
406
406
  /* @__PURE__ */ e(N, { children: /* @__PURE__ */ i(
407
407
  k,
408
408
  {
409
- onClick: h ? () => o(!s) : () => n(
410
- b === m.RETIREMENT_TRACK ? l.retirement : "",
411
- b === m.RETIREMENT_TRACK ? q.RETIREMENT : q.OTHER,
412
- b
409
+ onClick: p ? () => o(!h) : () => n(
410
+ c === m.RETIREMENT_TRACK ? s.retirement : "",
411
+ c === m.RETIREMENT_TRACK ? J.RETIREMENT : J.OTHER,
412
+ c
413
413
  ),
414
414
  children: [
415
- /* @__PURE__ */ e(P, { children: /* @__PURE__ */ e(ae, { sx: { bgcolor: d }, variant: "rounded", children: /* @__PURE__ */ e(fe, { name: _, sx: { color: "grey.900" } }) }) }),
416
- /* @__PURE__ */ e(w, { primary: a, secondary: u, sx: { mr: 24 } }),
417
- !h && /* @__PURE__ */ e(M, {}),
418
- h && (s ? /* @__PURE__ */ e(Ye, {}) : /* @__PURE__ */ e(Ze, {}))
415
+ /* @__PURE__ */ e(P, { children: /* @__PURE__ */ e(oe, { sx: { bgcolor: l }, variant: "rounded", children: /* @__PURE__ */ e(ge, { name: u, sx: { color: "grey.900" } }) }) }),
416
+ /* @__PURE__ */ e(w, { primary: a, secondary: _, sx: { mr: 24 } }),
417
+ !p && /* @__PURE__ */ e(M, {}),
418
+ p && (h ? /* @__PURE__ */ e(Xe, {}) : /* @__PURE__ */ e(Ue, {}))
419
419
  ]
420
420
  }
421
421
  ) }),
422
- /* @__PURE__ */ e(E, { variant: "inset" }),
423
- h && /* @__PURE__ */ e(nt, { in: s, children: /* @__PURE__ */ e(L, { sx: { bgcolor: "background.default" }, children: p.map((r, c) => /* @__PURE__ */ e(N, { sx: { pl: 48 }, children: /* @__PURE__ */ i(k, { onClick: () => n(r.label, r.metaType, b), children: [
424
- /* @__PURE__ */ e(ot, { sx: { mr: 8 }, children: /* @__PURE__ */ e(fe, { name: r.icon }) }),
422
+ /* @__PURE__ */ e(R, { variant: "inset" }),
423
+ p && /* @__PURE__ */ e(Qe, { in: h, children: /* @__PURE__ */ e(L, { sx: { bgcolor: "background.default" }, children: b.map((r, d) => /* @__PURE__ */ e(N, { sx: { pl: 48 }, children: /* @__PURE__ */ i(k, { onClick: () => n(r.label, r.metaType, c), children: [
424
+ /* @__PURE__ */ e(et, { sx: { mr: 8 }, children: /* @__PURE__ */ e(ge, { name: r.icon }) }),
425
425
  /* @__PURE__ */ e(
426
426
  w,
427
427
  {
@@ -430,35 +430,35 @@ const St = (t, n) => n ? v(t, t < 1e3 ? "0" : "0.00a").replace(
430
430
  }
431
431
  ),
432
432
  /* @__PURE__ */ e(M, {})
433
- ] }) }, c)) }) })
433
+ ] }) }, d)) }) })
434
434
  ] }) });
435
- }, Me = ({
435
+ }, De = ({
436
436
  accounts: t,
437
437
  isOpen: n,
438
- onClose: l,
439
- onSave: d,
440
- title: _
438
+ onClose: s,
439
+ onSave: l,
440
+ title: u
441
441
  }) => {
442
- const { goals: a, common: u } = T(), [p, b] = y.useState([]), s = (o) => {
443
- const h = p.findIndex((c) => c.guid === o.guid), r = [...p];
444
- h >= 0 ? r.splice(h, 1) : r.push(o), b(r);
442
+ const { goals: a, common: _ } = T(), [b, c] = y.useState([]), h = (o) => {
443
+ const p = b.findIndex((d) => d.guid === o.guid), r = [...b];
444
+ p >= 0 ? r.splice(p, 1) : r.push(o), c(r);
445
445
  };
446
446
  return /* @__PURE__ */ i(
447
- F,
447
+ j,
448
448
  {
449
- ariaLabelClose: u.close_aria,
449
+ ariaLabelClose: _.close_aria,
450
450
  isOpen: n,
451
- onClose: l,
452
- onPrimaryAction: () => d(p),
453
- title: _,
451
+ onClose: s,
452
+ onPrimaryAction: () => l(b),
453
+ title: u,
454
454
  children: [
455
- /* @__PURE__ */ e(V, { color: "text.secondary", sx: { mx: 24, my: 12 }, children: a.select_debt_accounts_description }),
455
+ /* @__PURE__ */ e(W, { color: "text.secondary", sx: { mx: 24, my: 12 }, children: a.select_debt_accounts_description }),
456
456
  /* @__PURE__ */ i(L, { sx: { bgcolor: "background.white" }, children: [
457
- /* @__PURE__ */ e(E, { variant: "fullWidth" }),
458
- t.map((o, h) => /* @__PURE__ */ i(y.Fragment, { children: [
459
- /* @__PURE__ */ e(N, { children: /* @__PURE__ */ i(k, { onClick: () => s(o), children: [
457
+ /* @__PURE__ */ e(R, { variant: "fullWidth" }),
458
+ t.map((o, p) => /* @__PURE__ */ i(y.Fragment, { children: [
459
+ /* @__PURE__ */ e(N, { children: /* @__PURE__ */ i(k, { onClick: () => h(o), children: [
460
460
  /* @__PURE__ */ e(P, { children: /* @__PURE__ */ e(
461
- oe,
461
+ ne,
462
462
  {
463
463
  alt: o?.name || "",
464
464
  institutionGuid: o?.institution_guid || ""
@@ -471,13 +471,13 @@ const St = (t, n) => n ? v(t, t < 1e3 ? "0" : "0.00a").replace(
471
471
  secondary: v(o.balance || 0, "0,0.00")
472
472
  }
473
473
  ),
474
- /* @__PURE__ */ e(at, { checked: p.some((r) => r.guid === o.guid) })
474
+ /* @__PURE__ */ e(tt, { checked: b.some((r) => r.guid === o.guid) })
475
475
  ] }) }),
476
- /* @__PURE__ */ e(E, { variant: h < t.length - 1 ? "inset" : "fullWidth" })
476
+ /* @__PURE__ */ e(R, { variant: p < t.length - 1 ? "inset" : "fullWidth" })
477
477
  ] }, o.guid))
478
478
  ] }),
479
479
  /* @__PURE__ */ e(
480
- Ae,
480
+ ye,
481
481
  {
482
482
  description: a.connect_description,
483
483
  label: a.connect_button,
@@ -487,56 +487,56 @@ const St = (t, n) => n ? v(t, t < 1e3 ? "0" : "0.00a").replace(
487
487
  ]
488
488
  }
489
489
  );
490
- }, Nt = ({ onClose: t }) => {
491
- const { goals: n } = T(), { addGoal: l, debtGoals: d, setAlert: _, setSelectedGoal: a } = x(), { visibleDebtAccounts: u } = j(), [p, b] = y.useState(!1), s = Ve(n), o = (r, c, f) => {
492
- f === m.DEBT_TRACK ? b(!0) : a({
490
+ }, xt = ({ onClose: t }) => {
491
+ const { goals: n } = T(), { addGoal: s, debtGoals: l, setAlert: u, setSelectedGoal: a } = x(), { visibleDebtAccounts: _ } = V(), [b, c] = y.useState(!1), h = Oe(n), o = (r, d, f) => {
492
+ f === m.DEBT_TRACK ? c(!0) : a({
493
493
  amount: 0,
494
494
  current_amount: 0,
495
- goal_type: _e.SAVE_AMOUNT,
495
+ goal_type: me.SAVE_AMOUNT,
496
496
  initial_amount: 0,
497
- meta_type: c,
497
+ meta_type: d,
498
498
  name: r,
499
499
  track_type: f
500
500
  });
501
- }, h = async (r) => {
502
- for (const c of r) {
503
- let f = q.CREDIT_CARD;
504
- c.account_type === ye.LOAN ? f = q.LOANS : c.account_type === ye.LINE_OF_CREDIT && (f = q.LINE_OF_CREDIT), await l({
505
- account_guid: c.guid,
501
+ }, p = async (r) => {
502
+ for (const d of r) {
503
+ let f = J.CREDIT_CARD;
504
+ d.account_type === fe.LOAN ? f = J.LOANS : d.account_type === fe.LINE_OF_CREDIT && (f = J.LINE_OF_CREDIT), await s({
505
+ account_guid: d.guid,
506
506
  amount: 0,
507
507
  current_amount: 0,
508
- goal_type: _e.KEEP_BALANCE_BELOW,
509
- initial_amount: c.balance || 0,
510
- interest_rate: c.interest_rate || 0,
508
+ goal_type: me.KEEP_BALANCE_BELOW,
509
+ initial_amount: d.balance || 0,
510
+ interest_rate: d.interest_rate || 0,
511
511
  meta_type: f,
512
- monthly_payment: c.minimum_payment || 0,
513
- name: c.name || c.feed_name || "",
512
+ monthly_payment: d.minimum_payment || 0,
513
+ name: d.name || d.feed_name || "",
514
514
  track_type: m.DEBT_TRACK
515
- }), _(n.alert_goal_added);
515
+ }), u(n.alert_goal_added);
516
516
  }
517
- b(!1), t?.(m.DEBT_TRACK);
517
+ c(!1), t?.(m.DEBT_TRACK);
518
518
  };
519
519
  return /* @__PURE__ */ i(g, { children: [
520
- /* @__PURE__ */ e(L, { sx: { bgcolor: "background.paper" }, children: s.map((r, c) => /* @__PURE__ */ e(Gt, { goalType: r, onClick: o }, c)) }),
520
+ /* @__PURE__ */ e(L, { sx: { bgcolor: "background.paper" }, children: h.map((r, d) => /* @__PURE__ */ e(vt, { goalType: r, onClick: o }, d)) }),
521
521
  /* @__PURE__ */ e(
522
- Me,
522
+ De,
523
523
  {
524
- accounts: u.filter((r) => !d.find((c) => c.account_guid === r.guid)),
525
- isOpen: p,
526
- onClose: () => b(!1),
527
- onSave: h,
524
+ accounts: _.filter((r) => !l.find((d) => d.account_guid === r.guid)),
525
+ isOpen: b,
526
+ onClose: () => c(!1),
527
+ onSave: p,
528
528
  title: n.select_debt_accounts_title
529
529
  }
530
530
  )
531
531
  ] });
532
- }, Be = ({ account: t }) => {
533
- const { accounts: n } = T(), { setSelectedAccount: l } = rt(), [d, _] = y.useState(!1);
532
+ }, Me = ({ account: t }) => {
533
+ const { accounts: n } = T(), { setSelectedAccount: s } = nt(), [l, u] = y.useState(!1);
534
534
  return /* @__PURE__ */ i(N, { sx: { bgcolor: "background.paper" }, children: [
535
535
  /* @__PURE__ */ i(k, { onClick: () => {
536
- l(t), _(!0);
536
+ s(t), u(!0);
537
537
  }, children: [
538
538
  /* @__PURE__ */ e(P, { children: /* @__PURE__ */ e(
539
- oe,
539
+ ne,
540
540
  {
541
541
  alt: t.name || "",
542
542
  institutionGuid: t.institution_guid || ""
@@ -551,74 +551,74 @@ const St = (t, n) => n ? v(t, t < 1e3 ? "0" : "0.00a").replace(
551
551
  ),
552
552
  /* @__PURE__ */ e(M, {})
553
553
  ] }),
554
- /* @__PURE__ */ e(F, { isOpen: d, onClose: () => _(!1), title: n.account_details, children: /* @__PURE__ */ i(g, { children: [
555
- /* @__PURE__ */ e(it, {}),
556
- /* @__PURE__ */ e(st, {})
554
+ /* @__PURE__ */ e(j, { isOpen: l, onClose: () => u(!1), title: n.account_details, children: /* @__PURE__ */ i(g, { children: [
555
+ /* @__PURE__ */ e(ot, {}),
556
+ /* @__PURE__ */ e(at, {})
557
557
  ] }) })
558
558
  ] });
559
- }, kt = K(({ goal: t }) => {
560
- const { goals: n } = T(), { setAlert: l, setSelectedGoal: d, updateGoal: _ } = x(), [a, u] = y.useState(t.amount), p = !t.guid, b = a < 0 || a > 9999999999e-2, s = t.track_type === m.SAVINGS_TRACK && t.has_been_spent || t.track_type !== m.SAVINGS_TRACK && t.is_complete, o = async () => {
559
+ }, It = K(({ goal: t }) => {
560
+ const { goals: n } = T(), { setAlert: s, setSelectedGoal: l, updateGoal: u } = x(), [a, _] = y.useState(t.amount), b = !t.guid, c = a < 0 || a > 9999999999e-2, h = t.track_type === m.SAVINGS_TRACK && t.has_been_spent || t.track_type !== m.SAVINGS_TRACK && t.is_complete, o = async () => {
561
561
  const r = { ...t, amount: a };
562
- t.amount = a, p ? d(r) : (await _(r), l(n.alert_goal_updated_amount));
563
- }, h = () => {
562
+ t.amount = a, b ? l(r) : (await u(r), s(n.alert_goal_updated_amount));
563
+ }, p = () => {
564
564
  setTimeout(() => {
565
- u(t.amount);
565
+ _(t.amount);
566
566
  }, 250);
567
567
  };
568
568
  return /* @__PURE__ */ e(
569
- Q,
569
+ ee,
570
570
  {
571
- isDisabled: s,
572
- isSaveDisabled: b,
571
+ isDisabled: h,
572
+ isSaveDisabled: c,
573
573
  label: n.details_amount_to_save,
574
- onCancel: h,
574
+ onCancel: p,
575
575
  onSave: o,
576
576
  primaryText: n.details_amount_to_save,
577
577
  secondaryText: v(t.amount, "0,0"),
578
- zeroStateText: p && t.amount === 0 ? n.add_amount : void 0,
578
+ zeroStateText: b && t.amount === 0 ? n.add_amount : void 0,
579
579
  children: /* @__PURE__ */ e(
580
- ke,
580
+ Ne,
581
581
  {
582
582
  amount: a,
583
583
  autoFocus: !0,
584
- error: b,
584
+ error: c,
585
585
  fullWidth: !0,
586
586
  minAmount: 0,
587
- setAmount: (r) => u(isNaN(Number(r)) ? a : Number(r)),
587
+ setAmount: (r) => _(isNaN(Number(r)) ? a : Number(r)),
588
588
  sx: { ".MuiTypography-Body": { p: 0 } }
589
589
  }
590
590
  )
591
591
  }
592
592
  );
593
- }), wt = ({ goal: t }) => {
594
- const { visibleCheckingAccounts: n, visibleSavingsAccounts: l } = j(), { accounts: d, goals: _ } = T(), { setAlert: a, setSelectedGoal: u, updateGoal: p } = x(), b = !t.guid, [s, o] = y.useState(!1), h = async ({ balance: r, guid: c }) => {
595
- const f = { ...t, account_guid: c, current_amount: r || 0 };
596
- b ? u(f) : (await p(f), a(_.alert_account_changed)), o(!1);
593
+ }), Gt = ({ goal: t }) => {
594
+ const { visibleCheckingAccounts: n, visibleSavingsAccounts: s } = V(), { accounts: l, goals: u } = T(), { setAlert: a, setSelectedGoal: _, updateGoal: b } = x(), c = !t.guid, [h, o] = y.useState(!1), p = async ({ balance: r, guid: d }) => {
595
+ const f = { ...t, account_guid: d, current_amount: r || 0 };
596
+ c ? _(f) : (await b(f), a(u.alert_account_changed)), o(!1);
597
597
  };
598
598
  return /* @__PURE__ */ i(g, { children: [
599
- b && !t.account_guid ? /* @__PURE__ */ e(N, { disableGutters: !0, disablePadding: !0, sx: { bgcolor: "background.paper" }, children: /* @__PURE__ */ i(k, { onClick: () => o(!0), children: [
599
+ c && !t.account_guid ? /* @__PURE__ */ e(N, { disableGutters: !0, disablePadding: !0, sx: { bgcolor: "background.paper" }, children: /* @__PURE__ */ i(k, { onClick: () => o(!0), children: [
600
600
  /* @__PURE__ */ e(w, { children: /* @__PURE__ */ i(g, { alignItems: "center", color: "primary.main", direction: "row", gap: 8, children: [
601
- /* @__PURE__ */ e(xe, { filled: !0 }),
602
- _.details_add_account
601
+ /* @__PURE__ */ e(ve, { filled: !0 }),
602
+ u.details_add_account
603
603
  ] }) }),
604
604
  /* @__PURE__ */ e(M, { color: "primary" })
605
605
  ] }) }) : /* @__PURE__ */ i(g, { sx: { gap: 8, my: 24, mx: 24 }, children: [
606
- /* @__PURE__ */ e(he, { onClick: () => o(!0), variant: "text", children: _.details_change_account }),
606
+ /* @__PURE__ */ e(pe, { onClick: () => o(!0), variant: "text", children: u.details_change_account }),
607
607
  /* @__PURE__ */ e(
608
608
  A,
609
609
  {
610
610
  color: "text.secondary",
611
611
  sx: { textAlign: "center", whiteSpace: "wrap" },
612
612
  variant: "Paragraph",
613
- children: B(_.details_change_account_description, t.name)
613
+ children: B(u.details_change_account_description, t.name)
614
614
  }
615
615
  )
616
616
  ] }),
617
- /* @__PURE__ */ e(F, { isOpen: s, onClose: () => o(!1), title: _.details_change_account, children: /* @__PURE__ */ i(g, { children: [
618
- n.length > 0 && /* @__PURE__ */ e(A, { bold: !0, sx: { mb: 4, ml: 24, mt: 12 }, variant: "XSmall", children: d.account_types[1] }),
619
- /* @__PURE__ */ e(L, { sx: { bgcolor: "background.paper" }, children: n.map((r) => /* @__PURE__ */ e(N, { children: /* @__PURE__ */ i(k, { onClick: () => h(r), children: [
617
+ /* @__PURE__ */ e(j, { isOpen: h, onClose: () => o(!1), title: u.details_change_account, children: /* @__PURE__ */ i(g, { children: [
618
+ n.length > 0 && /* @__PURE__ */ e(A, { bold: !0, sx: { mb: 4, ml: 24, mt: 12 }, variant: "XSmall", children: l.account_types[1] }),
619
+ /* @__PURE__ */ e(L, { sx: { bgcolor: "background.paper" }, children: n.map((r) => /* @__PURE__ */ e(N, { children: /* @__PURE__ */ i(k, { onClick: () => p(r), children: [
620
620
  /* @__PURE__ */ e(P, { children: /* @__PURE__ */ e(
621
- oe,
621
+ ne,
622
622
  {
623
623
  alt: r?.name || "",
624
624
  institutionGuid: r?.institution_guid || ""
@@ -633,10 +633,10 @@ const St = (t, n) => n ? v(t, t < 1e3 ? "0" : "0.00a").replace(
633
633
  ),
634
634
  /* @__PURE__ */ e(M, {})
635
635
  ] }) }, r.guid)) }),
636
- l.length > 0 && /* @__PURE__ */ e(A, { bold: !0, sx: { mb: 4, ml: 24, mt: 12 }, variant: "XSmall", children: d.account_types[2] }),
637
- /* @__PURE__ */ e(L, { sx: { bgcolor: "background.paper" }, children: l.map((r) => /* @__PURE__ */ e(N, { children: /* @__PURE__ */ i(k, { onClick: () => h(r), children: [
636
+ s.length > 0 && /* @__PURE__ */ e(A, { bold: !0, sx: { mb: 4, ml: 24, mt: 12 }, variant: "XSmall", children: l.account_types[2] }),
637
+ /* @__PURE__ */ e(L, { sx: { bgcolor: "background.paper" }, children: s.map((r) => /* @__PURE__ */ e(N, { children: /* @__PURE__ */ i(k, { onClick: () => p(r), children: [
638
638
  /* @__PURE__ */ e(P, { children: /* @__PURE__ */ e(
639
- oe,
639
+ ne,
640
640
  {
641
641
  alt: r?.name || "",
642
642
  institutionGuid: r?.institution_guid || ""
@@ -652,422 +652,421 @@ const St = (t, n) => n ? v(t, t < 1e3 ? "0" : "0.00a").replace(
652
652
  /* @__PURE__ */ e(M, {})
653
653
  ] }) }, r.guid)) }),
654
654
  /* @__PURE__ */ e(
655
- Ae,
655
+ ye,
656
656
  {
657
- description: _.connect_description,
658
- label: _.connect_button,
659
- title: _.connect_title
657
+ description: u.connect_description,
658
+ label: u.connect_button,
659
+ title: u.connect_title
660
660
  }
661
661
  )
662
662
  ] }) })
663
663
  ] });
664
- }, Kt = K(({ goal: t }) => {
665
- const { goals: n } = T(), { setAlert: l, setSelectedGoal: d, updateGoal: _ } = x(), [a, u] = y.useState(t.name), p = !t.guid, b = t.track_type === m.SAVINGS_TRACK && t.has_been_spent || t.track_type !== m.SAVINGS_TRACK && t.is_complete, s = async () => {
666
- const h = { ...t, name: a };
667
- t.name = a, p ? d(h) : (await _(h), l(n.alert_goal_updated_name));
664
+ }, Nt = K(({ goal: t }) => {
665
+ const { goals: n } = T(), { setAlert: s, setSelectedGoal: l, updateGoal: u } = x(), [a, _] = y.useState(t.name), b = !t.guid, c = t.track_type === m.SAVINGS_TRACK && t.has_been_spent || t.track_type !== m.SAVINGS_TRACK && t.is_complete, h = async () => {
666
+ const p = { ...t, name: a };
667
+ t.name = a, b ? l(p) : (await u(p), s(n.alert_goal_updated_name));
668
668
  }, o = () => {
669
669
  setTimeout(() => {
670
- u(t.name);
670
+ _(t.name);
671
671
  }, 250);
672
672
  };
673
673
  return /* @__PURE__ */ e(
674
- Q,
674
+ ee,
675
675
  {
676
- isDisabled: b,
676
+ isDisabled: c,
677
677
  isSaveDisabled: !a,
678
678
  label: n.details_goal_name,
679
679
  onCancel: o,
680
- onSave: s,
680
+ onSave: h,
681
681
  primaryText: n.details_goal_name,
682
682
  secondaryText: t.name,
683
683
  children: /* @__PURE__ */ e(
684
- we,
684
+ ke,
685
685
  {
686
686
  error: !a,
687
687
  fullWidth: !0,
688
688
  label: n.details_goal_name,
689
- onChange: (h) => u(h.target.value),
689
+ onChange: (p) => _(p.target.value),
690
690
  value: a
691
691
  }
692
692
  )
693
693
  }
694
694
  );
695
- }), Dt = ({ goal: t }) => {
696
- const { goals: n } = T(), { setAlert: l, setSelectedGoal: d, updateGoal: _ } = x(), [a, u] = y.useState(t.retirement_age || 65), p = !t.guid, b = async () => {
695
+ }), kt = ({ goal: t }) => {
696
+ const { goals: n } = T(), { setAlert: s, setSelectedGoal: l, updateGoal: u } = x(), [a, _] = y.useState(t.retirement_age || 65), b = !t.guid, c = async () => {
697
697
  if (!isNaN(a)) {
698
- const h = { ...t, retirement_age: a };
699
- t.retirement_age = a, p ? d(h) : (await _(h), l(n.alert_goal_updated_retirement_age));
698
+ const p = { ...t, retirement_age: a };
699
+ t.retirement_age = a, b ? l(p) : (await u(p), s(n.alert_goal_updated_retirement_age));
700
700
  }
701
- }, s = () => {
701
+ }, h = () => {
702
702
  setTimeout(() => {
703
- u(t.retirement_age || 65);
703
+ _(t.retirement_age || 65);
704
704
  }, 250);
705
705
  }, o = !a || isNaN(a) || a < 20 || a >= 100;
706
706
  return /* @__PURE__ */ e(
707
- Q,
707
+ ee,
708
708
  {
709
709
  isDisabled: t.is_complete,
710
710
  isSaveDisabled: o,
711
711
  label: n.details_retirement_age,
712
- onCancel: s,
713
- onSave: b,
712
+ onCancel: h,
713
+ onSave: c,
714
714
  primaryText: n.details_retirement_age,
715
715
  secondaryText: `${t.retirement_age}`,
716
- zeroStateText: p && !t.retirement_age ? n.add_age : void 0,
716
+ zeroStateText: b && !t.retirement_age ? n.add_age : void 0,
717
717
  children: /* @__PURE__ */ e(
718
- we,
718
+ ke,
719
719
  {
720
720
  error: o,
721
721
  fullWidth: !0,
722
722
  label: n.details_retirement_age,
723
- onChange: (h) => u(Number(h.target.value)),
723
+ onChange: (p) => _(Number(p.target.value)),
724
724
  value: isNaN(a) ? "" : a
725
725
  }
726
726
  )
727
727
  }
728
728
  );
729
- }, Mt = K(({ goal: t }) => {
730
- const { goals: n } = T(), { user: l, updateUser: d } = Ie(), { setAlert: _ } = x(), [a, u] = y.useState(J(l.birthday ?? 0)), [p, b] = y.useState(null), s = t.is_complete, o = async () => {
731
- a && _t(a) && (await d({ ...l, birthday: mt(a) }), _(n.alert_goal_updated_birthday));
729
+ }, wt = K(({ goal: t }) => {
730
+ const { goals: n } = T(), { user: s, updateUser: l } = xe(), { setAlert: u } = x(), [a, _] = y.useState(Q(s.birthday ?? 0)), [b, c] = y.useState(null), h = t.is_complete, o = async () => {
731
+ a && ct(a) && (await l({ ...s, birthday: lt(a) }), u(n.alert_goal_updated_birthday));
732
732
  };
733
733
  return /* @__PURE__ */ e(
734
- Q,
734
+ ee,
735
735
  {
736
- isDisabled: s,
737
- isSaveDisabled: !!p,
736
+ isDisabled: h,
737
+ isSaveDisabled: !!b,
738
738
  label: n.details_birthday,
739
739
  onSave: o,
740
740
  primaryText: n.details_birthday,
741
- secondaryText: `${re(J(l.birthday ?? 0), ie.MONTH_DAY_YEAR)}`,
742
- zeroStateText: !t.guid && !l.birthday ? n.add_birthday : void 0,
743
- children: /* @__PURE__ */ e(ht, { dateAdapter: ut, children: /* @__PURE__ */ e(
744
- pt,
741
+ secondaryText: `${ae(Q(s.birthday ?? 0), re.MONTH_DAY_YEAR)}`,
742
+ zeroStateText: !t.guid && !s.birthday ? n.add_birthday : void 0,
743
+ children: /* @__PURE__ */ e(_t, { dateAdapter: dt, children: /* @__PURE__ */ e(
744
+ mt,
745
745
  {
746
746
  label: n.details_birthday,
747
- onChange: u,
748
- onError: (h) => b(h),
747
+ onChange: _,
748
+ onError: (p) => c(p),
749
749
  sx: { width: "100%" },
750
750
  value: a
751
751
  }
752
752
  ) })
753
753
  }
754
754
  );
755
- }), Bt = ({ goal: t }) => {
756
- const { goals: n } = T(), { visibleInvestmentAccounts: l } = j(), {
757
- addRetirementGoalAccount: d,
758
- newRetirementGoalAccounts: _,
755
+ }), Kt = ({ goal: t }) => {
756
+ const { goals: n } = T(), { visibleInvestmentAccounts: s } = V(), {
757
+ addRetirementGoalAccount: l,
758
+ newRetirementGoalAccounts: u,
759
759
  retirementGoalAccounts: a,
760
- selectedGoal: u,
761
- setAlert: p,
762
- setNewRetirementGoalAccounts: b,
763
- setSelectedGoal: s
764
- } = x(), [o, h] = y.useState(!1), r = !t.guid, c = l.filter(
765
- (C) => r ? _.find((R) => R.account_guid === C.guid) : a.find((R) => R.account_guid === C.guid)
766
- ), f = l.filter(
767
- (C) => !a.find((R) => R.account_guid === C.guid)
768
- ), S = async (C) => {
769
- const R = C.map((I) => ({
760
+ selectedGoal: _,
761
+ setAlert: b,
762
+ setNewRetirementGoalAccounts: c,
763
+ setSelectedGoal: h
764
+ } = x(), [o, p] = y.useState(!1), r = !t.guid, d = s.filter(
765
+ (C) => r ? u.find((S) => S.account_guid === C.guid) : a.find((S) => S.account_guid === C.guid)
766
+ ), f = s.filter(
767
+ (C) => !a.find((S) => S.account_guid === C.guid)
768
+ ), E = async (C) => {
769
+ const S = C.map((I) => ({
770
770
  account_guid: I.guid,
771
771
  retirement_goal_guid: t.guid
772
772
  }));
773
773
  if (r)
774
- b(R);
774
+ c(S);
775
775
  else
776
- for (const I of R)
777
- await d(I), p(n.alert_account_added);
778
- s({
779
- ...u,
780
- current_amount: C.reduce((I, D) => I + (D.balance || 0), 0)
781
- }), h(!1);
776
+ for (const I of S)
777
+ await l(I), b(n.alert_account_added);
778
+ h({
779
+ ..._,
780
+ current_amount: C.reduce((I, F) => I + (F.balance || 0), 0)
781
+ }), p(!1);
782
782
  };
783
783
  return /* @__PURE__ */ i(g, { children: [
784
- c.map((C) => /* @__PURE__ */ i(g, { children: [
785
- /* @__PURE__ */ e(Be, { account: C }),
786
- /* @__PURE__ */ e(E, {})
784
+ d.map((C) => /* @__PURE__ */ i(g, { children: [
785
+ /* @__PURE__ */ e(Me, { account: C }),
786
+ /* @__PURE__ */ e(R, {})
787
787
  ] }, C.guid)),
788
- /* @__PURE__ */ e(N, { disableGutters: !0, disablePadding: !0, sx: { bgcolor: "background.paper" }, children: /* @__PURE__ */ i(k, { onClick: () => h(!0), children: [
788
+ /* @__PURE__ */ e(N, { disableGutters: !0, disablePadding: !0, sx: { bgcolor: "background.paper" }, children: /* @__PURE__ */ i(k, { onClick: () => p(!0), children: [
789
789
  /* @__PURE__ */ e(w, { children: /* @__PURE__ */ i(g, { alignItems: "center", color: "primary.main", direction: "row", gap: 8, children: [
790
- /* @__PURE__ */ e(xe, { filled: !0 }),
790
+ /* @__PURE__ */ e(ve, { filled: !0 }),
791
791
  n.details_add_account
792
792
  ] }) }),
793
793
  /* @__PURE__ */ e(M, { color: "primary" })
794
794
  ] }) }),
795
795
  /* @__PURE__ */ e(
796
- Me,
796
+ De,
797
797
  {
798
798
  accounts: f,
799
799
  isOpen: o,
800
- onClose: () => h(!1),
801
- onSave: S,
800
+ onClose: () => p(!1),
801
+ onSave: E,
802
802
  title: n.add_select_accounts
803
803
  }
804
804
  )
805
805
  ] });
806
- }, Lt = K(({ goal: t }) => {
807
- const { goals: n } = T(), { visibleAccounts: l } = j(), d = y.useMemo(
808
- () => l.find((u) => u.guid === t.account_guid),
809
- [l, t]
810
- ), _ = t.track_type;
806
+ }, Dt = K(({ goal: t }) => {
807
+ const { goals: n } = T(), { visibleAccounts: s } = V(), l = y.useMemo(
808
+ () => s.find((_) => _.guid === t.account_guid),
809
+ [s, t]
810
+ ), u = t.track_type;
811
811
  let a = n.details_save_title;
812
812
  return t.track_type === m.DEBT_TRACK ? a = n.details_debt_title : t.track_type === m.RETIREMENT_TRACK && (a = n.details_retirement_title), /* @__PURE__ */ i(g, { children: [
813
813
  /* @__PURE__ */ i(g, { mx: 24, children: [
814
814
  /* @__PURE__ */ e(A, { color: "text.secondary", sx: { mb: 4, mt: 24 }, variant: "XSmall", children: a }),
815
- /* @__PURE__ */ e(De, { goal: t, isInDrawer: !0 }),
815
+ /* @__PURE__ */ e(Ke, { goal: t, isInDrawer: !0 }),
816
816
  /* @__PURE__ */ e(A, { color: "text.secondary", sx: { mb: 4, mt: 24 }, variant: "XSmall", children: n.details_title })
817
817
  ] }),
818
818
  /* @__PURE__ */ i(L, { sx: { bgcolor: "background.paper" }, children: [
819
- /* @__PURE__ */ e(Kt, { goal: t }),
820
- /* @__PURE__ */ e(E, { sx: { ml: 24 } }),
821
- (_ === m.SAVINGS_TRACK || _ === m.RETIREMENT_TRACK) && /* @__PURE__ */ i(U, { children: [
822
- /* @__PURE__ */ e(kt, { goal: t }),
823
- /* @__PURE__ */ e(E, { sx: { ml: _ === m.RETIREMENT_TRACK ? 24 : 0 } })
819
+ /* @__PURE__ */ e(Nt, { goal: t }),
820
+ /* @__PURE__ */ e(R, { sx: { ml: 24 } }),
821
+ (u === m.SAVINGS_TRACK || u === m.RETIREMENT_TRACK) && /* @__PURE__ */ i(U, { children: [
822
+ /* @__PURE__ */ e(It, { goal: t }),
823
+ /* @__PURE__ */ e(R, { sx: { ml: u === m.RETIREMENT_TRACK ? 24 : 0 } })
824
824
  ] }),
825
825
  t.track_type === m.DEBT_TRACK && /* @__PURE__ */ i(U, { children: [
826
- /* @__PURE__ */ e(lt, { goal: t }),
827
- /* @__PURE__ */ e(E, { sx: { ml: 24 } }),
828
- /* @__PURE__ */ e(ct, { goal: t }),
829
- /* @__PURE__ */ e(E, { sx: { ml: 24 } }),
830
- /* @__PURE__ */ e(dt, { goal: t }),
831
- /* @__PURE__ */ e(E, { variant: "fullWidth" })
826
+ /* @__PURE__ */ e(rt, { goal: t }),
827
+ /* @__PURE__ */ e(R, { sx: { ml: 24 } }),
828
+ /* @__PURE__ */ e(it, { goal: t }),
829
+ /* @__PURE__ */ e(R, { sx: { ml: 24 } }),
830
+ /* @__PURE__ */ e(st, { goal: t }),
831
+ /* @__PURE__ */ e(R, { variant: "fullWidth" })
832
832
  ] }),
833
833
  t.track_type === m.RETIREMENT_TRACK && /* @__PURE__ */ i(U, { children: [
834
- /* @__PURE__ */ e(Dt, { goal: t }),
835
- /* @__PURE__ */ e(E, { sx: { ml: 24 } }),
836
- /* @__PURE__ */ e(Mt, { goal: t }),
837
- /* @__PURE__ */ e(E, { variant: "fullWidth" })
834
+ /* @__PURE__ */ e(kt, { goal: t }),
835
+ /* @__PURE__ */ e(R, { sx: { ml: 24 } }),
836
+ /* @__PURE__ */ e(wt, { goal: t }),
837
+ /* @__PURE__ */ e(R, { variant: "fullWidth" })
838
838
  ] })
839
839
  ] }),
840
840
  /* @__PURE__ */ e(A, { color: "text.secondary", sx: { mb: 4, ml: 24, mt: 12 }, variant: "XSmall", children: t.track_type === m.RETIREMENT_TRACK ? n.details_accounts : n.details_account }),
841
- t.track_type !== m.RETIREMENT_TRACK && d && /* @__PURE__ */ i(U, { children: [
842
- /* @__PURE__ */ e(Be, { account: d }),
843
- /* @__PURE__ */ e(E, {})
841
+ t.track_type !== m.RETIREMENT_TRACK && l && /* @__PURE__ */ i(U, { children: [
842
+ /* @__PURE__ */ e(Me, { account: l }),
843
+ /* @__PURE__ */ e(R, {})
844
844
  ] }),
845
845
  t.track_type === m.RETIREMENT_TRACK && /* @__PURE__ */ i(U, { children: [
846
- /* @__PURE__ */ e(Bt, { goal: t }),
847
- /* @__PURE__ */ e(E, {})
846
+ /* @__PURE__ */ e(Kt, { goal: t }),
847
+ /* @__PURE__ */ e(R, {})
848
848
  ] }),
849
- t.track_type === m.SAVINGS_TRACK && !t.is_complete && /* @__PURE__ */ e(wt, { goal: t })
849
+ t.track_type === m.SAVINGS_TRACK && !t.is_complete && /* @__PURE__ */ e(Gt, { goal: t })
850
850
  ] });
851
- }), Ot = K(({ onClose: t }) => {
852
- const { visibleInvestmentAccounts: n } = j(), { goals: l, common: d } = T(), {
853
- addGoal: _,
851
+ }), Mt = K(({ onClose: t }) => {
852
+ const { visibleInvestmentAccounts: n } = V(), { goals: s, common: l } = T(), {
853
+ addGoal: u,
854
854
  addRetirementGoal: a,
855
- deleteGoal: u,
856
- deleteRetirementGoal: p,
857
- newRetirementGoalAccounts: b,
858
- retirementGoalAccounts: s,
855
+ deleteGoal: _,
856
+ deleteRetirementGoal: b,
857
+ newRetirementGoalAccounts: c,
858
+ retirementGoalAccounts: h,
859
859
  selectedGoal: o,
860
- setAlert: h,
860
+ setAlert: p,
861
861
  setSelectedGoal: r,
862
- updateGoal: c
863
- } = x(), { user: f } = Ie(), [S, C] = y.useState(!1), R = !o?.guid, I = o?.track_type === m.SAVINGS_TRACK && o.is_complete && !o.has_been_spent, D = y.useMemo(() => {
864
- const G = R ? b : s;
865
- return n.filter((H) => G.some(($) => $.account_guid === H.guid));
866
- }, [R, n, b, s]), se = y.useMemo(() => {
862
+ updateGoal: d
863
+ } = x(), { user: f } = xe(), [E, C] = y.useState(!1), S = !o?.guid, I = o?.track_type === m.SAVINGS_TRACK && o.is_complete && !o.has_been_spent, F = y.useMemo(() => {
864
+ const G = S ? c : h;
865
+ return n.filter(($) => G.some((D) => D.account_guid === $.guid));
866
+ }, [S, n, c, h]), Z = y.useMemo(() => {
867
867
  if (!o) return !1;
868
- const { account_guid: G, track_type: H, name: $, amount: O, retirement_age: ne } = o;
869
- return H === m.SAVINGS_TRACK ? G ? !!$ && !!O : !1 : H === m.RETIREMENT_TRACK ? D.length ? !!$ && !!O && !!ne && !!f.birthday : !1 : !0;
870
- }, [o, D, f.birthday]);
871
- let W = d.delete_button, z = () => C(!0);
872
- R ? (z = () => ee(), W = d.save_button) : I && (z = () => le(), W = l.mark_as_complete_button);
873
- const ee = async () => {
868
+ const { account_guid: G, track_type: $, name: D, amount: q, retirement_age: O } = o;
869
+ return $ === m.SAVINGS_TRACK ? G ? !!D && !!q : !1 : $ === m.RETIREMENT_TRACK ? F.length ? !!D && !!q && !!O && !!f.birthday : !1 : !0;
870
+ }, [o, F, f.birthday]);
871
+ let z = l.delete_button, H = () => C(!0);
872
+ S ? (H = () => te(), z = l.save_button) : I && (H = () => se(), z = s.mark_as_complete_button);
873
+ const te = async () => {
874
874
  if (o) {
875
875
  const G = o.track_type;
876
- G !== m.RETIREMENT_TRACK ? await _(o) : G === m.RETIREMENT_TRACK && await a({ ...o, target_amount: o.amount }), h(l.alert_goal_added), r(void 0), G && t?.(G);
876
+ G !== m.RETIREMENT_TRACK ? await u(o) : G === m.RETIREMENT_TRACK && await a({ ...o, target_amount: o.amount }), p(s.alert_goal_added), r(void 0), G && t?.(G);
877
877
  }
878
- }, te = async () => {
879
- o && (o.track_type !== m.RETIREMENT_TRACK ? await u(o.guid) : o.track_type === m.RETIREMENT_TRACK && await p(o), h(l.alert_goal_deleted), r(void 0));
880
- }, le = async () => {
878
+ }, ie = async () => {
879
+ o && (o.track_type !== m.RETIREMENT_TRACK ? await _(o.guid) : o.track_type === m.RETIREMENT_TRACK && await b(o), p(s.alert_goal_deleted), r(void 0));
880
+ }, se = async () => {
881
881
  const G = {
882
882
  ...o,
883
883
  has_been_spent: !0
884
884
  };
885
- await c(G), h(l.alert_goal_completed), r(void 0);
885
+ await d(G), p(s.alert_goal_completed), r(void 0);
886
886
  };
887
887
  return /* @__PURE__ */ i(g, { children: [
888
888
  /* @__PURE__ */ e(
889
- F,
889
+ j,
890
890
  {
891
- ariaLabelClose: d.close_aria,
892
- hasSecondaryAction: R,
891
+ ariaLabelClose: l.close_aria,
892
+ hasSecondaryAction: S,
893
893
  isOpen: !!o,
894
- isPrimaryDisabled: !se,
894
+ isPrimaryDisabled: !Z,
895
895
  onClose: () => r(void 0),
896
- onPrimaryAction: z,
897
- primaryColor: R || I ? "primary" : "error",
898
- primaryText: W,
896
+ onPrimaryAction: H,
897
+ primaryColor: S || I ? "primary" : "error",
898
+ primaryText: z,
899
899
  secondaryColor: "primary",
900
- title: l.goal_details,
901
- children: o && /* @__PURE__ */ e(Lt, { goal: o })
900
+ title: s.goal_details,
901
+ children: o && /* @__PURE__ */ e(Dt, { goal: o })
902
902
  }
903
903
  ),
904
904
  /* @__PURE__ */ e(
905
- tt,
905
+ Je,
906
906
  {
907
- copy: { close_aria: d.close_aria, title: l.delete_goal },
908
- isOpen: S,
907
+ copy: { close_aria: l.close_aria, title: s.delete_goal },
908
+ isOpen: E,
909
909
  maxWidth: "xs",
910
910
  onClose: () => C(!1),
911
- onPrimaryAction: te,
911
+ onPrimaryAction: ie,
912
912
  primaryColor: "error",
913
- primaryText: d.delete_button,
914
- children: /* @__PURE__ */ e(A, { sx: { textWrap: "wrap" }, variant: "Paragraph", children: B(l.delete_description, o?.name || "") })
913
+ primaryText: l.delete_button,
914
+ children: /* @__PURE__ */ e(A, { sx: { textWrap: "wrap" }, variant: "Paragraph", children: B(s.delete_description, o?.name || "") })
915
915
  }
916
916
  )
917
917
  ] });
918
- }), zn = K(({ onBackClick: t, sx: n }) => {
919
- const { onEvent: l } = Ge(), { config: d } = Je(), { isMobile: _ } = be(), { visibleAccounts: a } = j(), { isCopyLoaded: u, isInitialized: p, setSelectedAccounts: b } = Ne(), { goals: s, common: o } = T(), { alert: h, goals: r, goalsLoaded: c, loadGoals: f, monthlyCashFlowProfile: S, setAlert: C, retirmentGoals: R } = x(), [I, D] = y.useState(0), [se, W] = y.useState(!1), z = S?.amount_allocated_for_savings_goals || 0, ee = S?.amount_allocated_for_debt_goals || 0, te = S?.amount_allocated_for_retirement_goals || 0, le = u ? B(
920
- _ ? s.tab_subtitle_mobile : s.tab_subtitle,
918
+ }), Vn = K(({ onBackClick: t, sx: n }) => {
919
+ const { onEvent: s } = Ie(), { isMobile: l } = he(), { visibleAccounts: u } = V(), { isCopyLoaded: a, isInitialized: _, setSelectedAccounts: b } = Ge(), { goals: c, common: h } = T(), { alert: o, goals: p, goalsLoaded: r, loadGoals: d, monthlyCashFlowProfile: f, setAlert: E, retirmentGoals: C } = x(), [S, I] = y.useState(0), [F, Z] = y.useState(!1), z = f?.amount_allocated_for_savings_goals || 0, H = f?.amount_allocated_for_debt_goals || 0, te = f?.amount_allocated_for_retirement_goals || 0, ie = a ? B(
920
+ l ? c.tab_subtitle_mobile : c.tab_subtitle,
921
921
  v(z, "0,0")
922
- ) : "", G = u ? B(
923
- _ ? s.tab_subtitle_mobile : s.tab_subtitle,
924
- v(ee, "0,0")
925
- ) : "", H = u ? B(
926
- _ ? s.tab_subtitle_mobile : s.tab_subtitle,
922
+ ) : "", se = a ? B(
923
+ l ? c.tab_subtitle_mobile : c.tab_subtitle,
924
+ v(H, "0,0")
925
+ ) : "", G = a ? B(
926
+ l ? c.tab_subtitle_mobile : c.tab_subtitle,
927
927
  v(te, "0,0")
928
928
  ) : "";
929
929
  y.useEffect(() => {
930
- b(a), l(Y.GOALS_VIEW);
930
+ b(u), s(Y.GOALS_VIEW);
931
931
  }, []), y.useEffect(() => {
932
- p && f().finally();
933
- }, [p, z, ee, te]);
932
+ _ && d().finally();
933
+ }, [_, z, H, te]);
934
934
  const $ = () => {
935
- l(Y.GOALS_CLICK_FILTER);
936
- }, O = () => {
937
- W(!0), l(Y.GOALS_CLICK_ADD);
938
- }, ne = (X) => {
939
- W(!1), X === m.SAVINGS_TRACK ? D(0) : X === m.DEBT_TRACK ? D(1) : X === m.RETIREMENT_TRACK && D(2);
940
- }, Z = y.useMemo(
941
- () => c && (r.length === 0 || r.every(({ track_type: X }) => !X) && R.length === 0),
942
- [r, c, R]
943
- ), Le = d.show_connections_widget_in_master ? "buttons" : "no-buttons";
944
- return !c || !u || !p ? /* @__PURE__ */ e(Ke, {}) : /* @__PURE__ */ i(
945
- gt,
935
+ s(Y.GOALS_CLICK_FILTER);
936
+ }, D = () => {
937
+ Z(!0), s(Y.GOALS_CLICK_ADD);
938
+ }, q = (X) => {
939
+ Z(!1), X === m.SAVINGS_TRACK ? I(0) : X === m.DEBT_TRACK ? I(1) : X === m.RETIREMENT_TRACK && I(2);
940
+ }, O = y.useMemo(
941
+ () => r && (p.length === 0 || p.every(({ track_type: X }) => !X) && C.length === 0),
942
+ [p, r, C]
943
+ );
944
+ return !r || !a || !_ ? /* @__PURE__ */ e(we, {}) : /* @__PURE__ */ i(
945
+ pt,
946
946
  {
947
- accountOptions: a,
947
+ accountOptions: u,
948
948
  actions: [
949
949
  {
950
950
  iconName: "add",
951
- label: s.add_title,
952
- onClick: O
951
+ label: c.add_title,
952
+ onClick: D
953
953
  }
954
954
  ],
955
955
  onAccountsFilterClick: $,
956
956
  onBackClick: t,
957
957
  sx: n,
958
- title: s.title,
958
+ title: c.title,
959
959
  children: [
960
- /* @__PURE__ */ i(g, { mx: _ ? 0 : 48, my: 24, children: [
960
+ /* @__PURE__ */ i(g, { mx: l ? 0 : 48, my: 24, children: [
961
961
  /* @__PURE__ */ i(
962
- Fe,
962
+ Ve,
963
963
  {
964
- onChange: (X, Oe) => D(Oe),
964
+ onChange: (X, Be) => I(Be),
965
965
  sx: { bgcolor: "background.paper" },
966
966
  textColor: "primary",
967
- value: Z ? !1 : I,
967
+ value: O ? !1 : S,
968
968
  variant: "fullWidth",
969
969
  children: [
970
970
  /* @__PURE__ */ e(
971
- ce,
971
+ le,
972
972
  {
973
- disabled: Z,
974
- label: /* @__PURE__ */ e(de, { subtitle: le, title: s.tab_saving_title })
973
+ disabled: O,
974
+ label: /* @__PURE__ */ e(ce, { subtitle: ie, title: c.tab_saving_title })
975
975
  }
976
976
  ),
977
977
  /* @__PURE__ */ e(
978
- ce,
978
+ le,
979
979
  {
980
- disabled: Z,
981
- label: /* @__PURE__ */ e(de, { subtitle: G, title: s.tab_debt_title })
980
+ disabled: O,
981
+ label: /* @__PURE__ */ e(ce, { subtitle: se, title: c.tab_debt_title })
982
982
  }
983
983
  ),
984
984
  /* @__PURE__ */ e(
985
- ce,
985
+ le,
986
986
  {
987
- disabled: Z,
988
- label: /* @__PURE__ */ e(de, { subtitle: H, title: s.tab_retirement_title })
987
+ disabled: O,
988
+ label: /* @__PURE__ */ e(ce, { subtitle: G, title: c.tab_retirement_title })
989
989
  }
990
990
  )
991
991
  ]
992
992
  }
993
993
  ),
994
- Z ? /* @__PURE__ */ e(
995
- bt,
994
+ O ? /* @__PURE__ */ e(
995
+ ut,
996
996
  {
997
- header: s.create_goals_header,
997
+ header: c.create_goals_header,
998
998
  icon: "trophy",
999
- onClick: O,
1000
- primaryButton: s.add_goals_button,
1001
- subText: s.empty_state_subheader,
999
+ onClick: D,
1000
+ primaryButton: c.add_goals_button,
1001
+ subText: c.empty_state_subheader,
1002
1002
  sx: {
1003
1003
  width: { sm: 432 },
1004
1004
  ".buttons-footer": {
1005
1005
  width: 139
1006
1006
  }
1007
- },
1008
- variant: Le
1007
+ }
1009
1008
  }
1010
1009
  ) : /* @__PURE__ */ i(U, { children: [
1011
- I === 0 && /* @__PURE__ */ e(me, { onAddGoals: O, trackType: m.SAVINGS_TRACK }),
1012
- I === 1 && /* @__PURE__ */ e(me, { onAddGoals: O, trackType: m.DEBT_TRACK }),
1013
- I === 2 && /* @__PURE__ */ e(me, { onAddGoals: O, trackType: m.RETIREMENT_TRACK })
1010
+ S === 0 && /* @__PURE__ */ e(de, { onAddGoals: D, trackType: m.SAVINGS_TRACK }),
1011
+ S === 1 && /* @__PURE__ */ e(de, { onAddGoals: D, trackType: m.DEBT_TRACK }),
1012
+ S === 2 && /* @__PURE__ */ e(de, { onAddGoals: D, trackType: m.RETIREMENT_TRACK })
1014
1013
  ] })
1015
1014
  ] }),
1016
- /* @__PURE__ */ e(Ot, { onClose: ne }),
1015
+ /* @__PURE__ */ e(Mt, { onClose: q }),
1017
1016
  /* @__PURE__ */ e(
1018
- F,
1017
+ j,
1019
1018
  {
1020
- ariaLabelClose: o.close_aria,
1021
- isOpen: se,
1022
- onClose: () => W(!1),
1023
- title: s.add_goal_title,
1024
- children: /* @__PURE__ */ e(Nt, { onClose: ne })
1019
+ ariaLabelClose: h.close_aria,
1020
+ isOpen: F,
1021
+ onClose: () => Z(!1),
1022
+ title: c.add_goal_title,
1023
+ children: /* @__PURE__ */ e(xt, { onClose: q })
1025
1024
  }
1026
1025
  ),
1027
- /* @__PURE__ */ e(je, { onClose: () => C(""), open: !!h, children: /* @__PURE__ */ e(Pe, { onClose: () => C(""), severity: "success", variant: "filled", children: h }) })
1026
+ /* @__PURE__ */ e(Pe, { onClose: () => E(""), open: !!o, children: /* @__PURE__ */ e(We, { onClose: () => E(""), severity: "success", variant: "filled", children: o }) })
1028
1027
  ]
1029
1028
  }
1030
1029
  );
1031
- }), Wt = K(({ goal: t }) => {
1032
- const { goals: n } = T(), l = At(), {
1033
- backgroundColor: d,
1034
- color: _,
1030
+ }), Bt = K(({ goal: t }) => {
1031
+ const { goals: n } = T(), s = gt(), {
1032
+ backgroundColor: l,
1033
+ color: u,
1035
1034
  percentage: a,
1036
- projectedText: u
1037
- } = ue(n, t), p = Math.round(a * 100);
1038
- let b = /* @__PURE__ */ e(Re, {});
1039
- return t.track_type === m.DEBT_TRACK ? b = /* @__PURE__ */ e(Ee, {}) : t.track_type === m.RETIREMENT_TRACK && (b = /* @__PURE__ */ e(ve, {})), /* @__PURE__ */ i(g, { alignItems: "center", direction: "row", spacing: 12, sx: { py: 12 }, children: [
1040
- /* @__PURE__ */ e(ae, { sx: { bgcolor: d, color: _, height: 32, width: 32 }, variant: "rounded", children: b }),
1041
- /* @__PURE__ */ i(yt, { sx: { width: "100%" }, children: [
1042
- /* @__PURE__ */ e(pe, { fontSize: 15, fontWeight: 600, variant: "body1", children: t.name }),
1043
- t.projected_to_complete_at && /* @__PURE__ */ e(A, { color: "text.secondary", variant: "XSmall", children: u })
1035
+ projectedText: _
1036
+ } = _e(n, t), b = Math.round(a * 100);
1037
+ let c = /* @__PURE__ */ e(Se, {});
1038
+ return t.track_type === m.DEBT_TRACK ? c = /* @__PURE__ */ e(Re, {}) : t.track_type === m.RETIREMENT_TRACK && (c = /* @__PURE__ */ e(Ee, {})), /* @__PURE__ */ i(g, { alignItems: "center", direction: "row", spacing: 12, sx: { py: 12 }, children: [
1039
+ /* @__PURE__ */ e(oe, { sx: { bgcolor: l, color: u, height: 32, width: 32 }, variant: "rounded", children: c }),
1040
+ /* @__PURE__ */ i(bt, { sx: { width: "100%" }, children: [
1041
+ /* @__PURE__ */ e(ue, { fontSize: 15, fontWeight: 600, variant: "body1", children: t.name }),
1042
+ t.projected_to_complete_at && /* @__PURE__ */ e(A, { color: "text.secondary", variant: "XSmall", children: _ })
1044
1043
  ] }),
1045
1044
  /* @__PURE__ */ e(
1046
- Tt,
1045
+ ft,
1047
1046
  {
1048
- backgroundStrokeColor: l.palette.border.lighter,
1049
- color: l.palette.primary.main,
1050
- percent: p,
1047
+ backgroundStrokeColor: s.palette.border.lighter,
1048
+ color: s.palette.primary.main,
1049
+ percent: b,
1051
1050
  size: 40,
1052
1051
  strokeWidth: 3,
1053
- children: /* @__PURE__ */ e(V, { fontWeight: 700, variant: "caption", children: `${p}%` })
1052
+ children: /* @__PURE__ */ e(W, { fontWeight: 700, variant: "caption", children: `${b}%` })
1054
1053
  }
1055
1054
  )
1056
1055
  ] });
1057
- }), Vt = ({ header: t, subText: n, sx: l }) => /* @__PURE__ */ i(
1056
+ }), Lt = ({ header: t, subText: n, sx: s }) => /* @__PURE__ */ i(
1058
1057
  g,
1059
1058
  {
1060
1059
  sx: {
1061
1060
  alignItems: "center",
1062
1061
  alignSelf: "center",
1063
1062
  px: 24,
1064
- ...l
1063
+ ...s
1065
1064
  },
1066
1065
  children: [
1067
- /* @__PURE__ */ e(qe, { size: 32 }),
1068
- /* @__PURE__ */ e(pe, { fontSize: 15, fontWeight: 600, children: t }),
1066
+ /* @__PURE__ */ e(Ye, { size: 32 }),
1067
+ /* @__PURE__ */ e(ue, { fontSize: 15, fontWeight: 600, children: t }),
1069
1068
  /* @__PURE__ */ e(
1070
- V,
1069
+ W,
1071
1070
  {
1072
1071
  color: "text.secondary",
1073
1072
  sx: { fontWeight: 400, maxWidth: { sm: 424 }, textAlign: "center" },
@@ -1077,46 +1076,46 @@ const St = (t, n) => n ? v(t, t < 1e3 ? "0" : "0.00a").replace(
1077
1076
  )
1078
1077
  ]
1079
1078
  }
1080
- ), Hn = K(({ onCTAClick: t }) => {
1081
- const { visibleAccounts: n } = j(), { onEvent: l } = Ge(), { goals: d } = T(), { isInitialized: _, setSelectedAccounts: a, isCopyLoaded: u } = Ne(), { ongoingGoalsForMicroWidget: p, loadGoals: b, goalsLoaded: s } = x();
1079
+ ), jn = K(({ onCTAClick: t }) => {
1080
+ const { visibleAccounts: n } = V(), { onEvent: s } = Ie(), { goals: l } = T(), { isInitialized: u, setSelectedAccounts: a, isCopyLoaded: _ } = Ge(), { ongoingGoalsForMicroWidget: b, loadGoals: c, goalsLoaded: h } = x();
1082
1081
  y.useEffect(() => {
1083
1082
  a(n);
1084
1083
  }, []), y.useEffect(() => {
1085
- _ && (b().finally(), l(Y.GOALS_LOAD_WIDGET, {
1084
+ u && (c().finally(), s(Y.GOALS_LOAD_WIDGET, {
1086
1085
  state: n?.length ? "default" : "zeroState"
1087
1086
  }));
1088
- }, [_]);
1087
+ }, [u]);
1089
1088
  const o = y.useMemo(
1090
- () => s && p.length === 0,
1091
- [p, s]
1092
- ), h = () => {
1093
- l(
1089
+ () => h && b.length === 0,
1090
+ [b, h]
1091
+ ), p = () => {
1092
+ s(
1094
1093
  o ? Y.GOALS_CLICK_GET_STARTED : Y.GOALS_CLICK_VIEW_DETAILS
1095
1094
  ), t();
1096
1095
  };
1097
- return !s || !u || !_ ? /* @__PURE__ */ e(Ke, {}) : /* @__PURE__ */ e(
1098
- Ct,
1096
+ return !h || !_ || !u ? /* @__PURE__ */ e(we, {}) : /* @__PURE__ */ e(
1097
+ yt,
1099
1098
  {
1100
1099
  className: "mx-goals-microwidget",
1101
- ctaLabel: o ? d.get_started : d.view_details,
1102
- onCTAClick: h,
1103
- title: d.title,
1100
+ ctaLabel: o ? l.get_started : l.view_details,
1101
+ onCTAClick: p,
1102
+ title: l.title,
1104
1103
  children: o ? /* @__PURE__ */ e(
1105
- Vt,
1104
+ Lt,
1106
1105
  {
1107
- header: d.create_goals_header,
1108
- subText: d.micro_zero_state_description
1106
+ header: l.create_goals_header,
1107
+ subText: l.micro_zero_state_description
1109
1108
  }
1110
- ) : /* @__PURE__ */ e(ft, { sx: { justifyContent: "space-between" }, children: p.map((r, c) => /* @__PURE__ */ i(y.Fragment, { children: [
1111
- /* @__PURE__ */ e(Wt, { goal: r }),
1112
- c !== p.length - 1 && /* @__PURE__ */ e(E, {})
1109
+ ) : /* @__PURE__ */ e(ht, { sx: { justifyContent: "space-between" }, children: b.map((r, d) => /* @__PURE__ */ i(y.Fragment, { children: [
1110
+ /* @__PURE__ */ e(Bt, { goal: r }),
1111
+ d !== b.length - 1 && /* @__PURE__ */ e(R, {})
1113
1112
  ] }, r.guid)) })
1114
1113
  }
1115
1114
  );
1116
1115
  });
1117
1116
  export {
1118
- Un as GoalApi,
1119
- Yn as GoalStore,
1120
- Hn as GoalsMicroWidget,
1121
- zn as GoalsWidget
1117
+ Hn as GoalApi,
1118
+ $n as GoalStore,
1119
+ jn as GoalsMicroWidget,
1120
+ Vn as GoalsWidget
1122
1121
  };