@mx-cartographer/experiences 7.2.9 → 7.2.11
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
CHANGED
|
@@ -1,3 +1,11 @@
|
|
|
1
|
+
## [7.2.11] - 11-19-2025
|
|
2
|
+
|
|
3
|
+
- **FIXED** - transactions widget to not announce until copy loaded
|
|
4
|
+
|
|
5
|
+
## [7.2.10] - 11-18-2025
|
|
6
|
+
|
|
7
|
+
- **FIXED** - transactions widget to announce dynamic updates via aria live region
|
|
8
|
+
|
|
1
9
|
## [7.2.9] - 11-17-2025
|
|
2
10
|
|
|
3
11
|
- **UPDATED** - components directory `microinsights`
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
export type AriaLivePoliteness = 'polite' | 'assertive';
|
|
3
|
+
interface UseAriaLiveResult {
|
|
4
|
+
announce: (message: string, politeness?: AriaLivePoliteness) => void;
|
|
5
|
+
ariaLive: React.ReactElement | null;
|
|
6
|
+
}
|
|
7
|
+
export declare const useAriaLive: (initialPoliteness?: AriaLivePoliteness) => UseAriaLiveResult;
|
|
8
|
+
export default useAriaLive;
|
|
@@ -44,6 +44,7 @@ export interface TransactionsCopy {
|
|
|
44
44
|
memo_desc_aria: string;
|
|
45
45
|
memo_title: string;
|
|
46
46
|
merchant_logo_desc: string;
|
|
47
|
+
showing_transactions_count: string;
|
|
47
48
|
merchant_logo_modal_desc: string;
|
|
48
49
|
merchant_logo_modal_desc_bold: string;
|
|
49
50
|
merchant_logo_modal_title: string;
|
|
@@ -1,59 +1,59 @@
|
|
|
1
|
-
import { T as
|
|
2
|
-
import { u as
|
|
3
|
-
import { B as
|
|
1
|
+
import { T as Ta } from "../TransactionApi-B3Tksf7L.mjs";
|
|
2
|
+
import { u as B, C as Be, D as $e, M as Ve, c as We, T as Ge, a as Ue } from "../TransactionDetails-BWffqew4.mjs";
|
|
3
|
+
import { B as Sa, d as xa, b as wa } from "../TransactionDetails-BWffqew4.mjs";
|
|
4
4
|
import { T as M } from "../User-BQUxBeZV.mjs";
|
|
5
|
-
import { O as
|
|
6
|
-
import { S as
|
|
7
|
-
import { T as
|
|
8
|
-
import { e as
|
|
9
|
-
import { E as
|
|
5
|
+
import { O as Ia } from "../User-BQUxBeZV.mjs";
|
|
6
|
+
import { S as ae, D as Fe } from "../TransactionStore-DxPLdF3B.mjs";
|
|
7
|
+
import { T as Na } from "../TransactionStore-DxPLdF3B.mjs";
|
|
8
|
+
import { e as ze } from "../exportTransactionsToCSV-7bVS7KXf.mjs";
|
|
9
|
+
import { E as Oa } from "../ExportCsvAction-sX8Rg4Ov.mjs";
|
|
10
10
|
import { jsxs as _, jsx as e } from "react/jsx-runtime";
|
|
11
|
-
import
|
|
12
|
-
import { observer as
|
|
13
|
-
import
|
|
14
|
-
import { DataGridPro as
|
|
15
|
-
import
|
|
16
|
-
import { useTheme as
|
|
17
|
-
import { Text as C, Icon as
|
|
18
|
-
import { h as $, u as
|
|
19
|
-
import { fromUnixTime as
|
|
20
|
-
import { f as
|
|
21
|
-
import
|
|
22
|
-
import { f as
|
|
23
|
-
import { L as
|
|
24
|
-
import { endOfMonth as
|
|
25
|
-
import { getUnixTime as
|
|
26
|
-
import { startOfMonth as
|
|
27
|
-
import { startOfToday as
|
|
28
|
-
import
|
|
29
|
-
import { l as
|
|
30
|
-
import
|
|
31
|
-
import
|
|
32
|
-
import
|
|
33
|
-
import { ExpandMore as
|
|
34
|
-
import { C as
|
|
35
|
-
import { a as
|
|
36
|
-
import { b as
|
|
37
|
-
import { A as
|
|
38
|
-
import { u as
|
|
39
|
-
import { S as
|
|
40
|
-
import { D as
|
|
41
|
-
const
|
|
11
|
+
import c from "react";
|
|
12
|
+
import { observer as x } from "mobx-react-lite";
|
|
13
|
+
import Ke from "@mui/material/Paper";
|
|
14
|
+
import { DataGridPro as qe } from "@mui/x-data-grid-pro";
|
|
15
|
+
import T from "@mui/material/Box";
|
|
16
|
+
import { useTheme as je } from "@mui/material/styles";
|
|
17
|
+
import { Text as C, Icon as P, MerchantLogo as Xe, TextField as ne, P as Ye } from "@mxenabled/mxui";
|
|
18
|
+
import { h as $, u as w, b as j, d as se, m as Je, a as Qe, g as Ze, p as et } from "../hooks-D6XlXHf4.mjs";
|
|
19
|
+
import { fromUnixTime as tt } from "date-fns/fromUnixTime";
|
|
20
|
+
import { f as at, D as nt, a as ie } from "../Dialog-CWW597AF.mjs";
|
|
21
|
+
import N from "@mui/material/Stack";
|
|
22
|
+
import { f as ce } from "../NumberFormatting-Buh7u8Oi.mjs";
|
|
23
|
+
import { L as X } from "../Loader-DUaFpDGv.mjs";
|
|
24
|
+
import { endOfMonth as ot } from "date-fns/endOfMonth";
|
|
25
|
+
import { getUnixTime as rt } from "date-fns/getUnixTime";
|
|
26
|
+
import { startOfMonth as st } from "date-fns/startOfMonth";
|
|
27
|
+
import { startOfToday as K } from "date-fns/startOfToday";
|
|
28
|
+
import it from "@mui/material/styles/useTheme";
|
|
29
|
+
import { l as ct } from "../ConnectDrawer-DaFRU5st.mjs";
|
|
30
|
+
import lt from "@mui/material/Divider";
|
|
31
|
+
import dt from "@mui/material/MenuItem";
|
|
32
|
+
import ut from "@mui/material/RadioGroup";
|
|
33
|
+
import { ExpandMore as mt } from "@mxenabled/mx-icons";
|
|
34
|
+
import { C as _t } from "../CurrencyInput-CsCy7uaS.mjs";
|
|
35
|
+
import { a as pt, u as gt } from "../CategorySelectorDrawer-DUe4lH5-.mjs";
|
|
36
|
+
import { b as q } from "../Localization-2MODESHW.mjs";
|
|
37
|
+
import { A as S, W as ht } from "../WidgetContainer-C88Ecu2W.mjs";
|
|
38
|
+
import { u as ft } from "../useScreenSize-B6JyS_Lj.mjs";
|
|
39
|
+
import { S as Ct } from "../SearchBox-B2_zLv8-.mjs";
|
|
40
|
+
import { D as oe } from "../Drawer-kEE73B87.mjs";
|
|
41
|
+
const yt = (t) => /* @__PURE__ */ _(C, { tabIndex: t.tabIndex, variant: "Small", children: [
|
|
42
42
|
`${t.row.account}`,
|
|
43
43
|
t.row.number && ` | ${t.row.number}`
|
|
44
|
-
] }),
|
|
45
|
-
const { associatedBeats:
|
|
46
|
-
return /* @__PURE__ */ _(
|
|
44
|
+
] }), bt = (t) => {
|
|
45
|
+
const { associatedBeats: r } = $(), { showInsights: o } = B(), { amount: a, transaction_type: i } = t.row, l = r.find((p) => p.associated_transaction_guid === t.row.guid), d = i === M.CREDIT;
|
|
46
|
+
return /* @__PURE__ */ _(N, { alignItems: "flex-end", tabIndex: t.tabIndex, children: [
|
|
47
47
|
/* @__PURE__ */ _(C, { color: d ? "success.main" : "text.primary", variant: "Small", children: [
|
|
48
48
|
d ? "+" : "",
|
|
49
|
-
|
|
49
|
+
ce(a, "0,0.00")
|
|
50
50
|
] }),
|
|
51
51
|
l && o && /* @__PURE__ */ e(C, { bold: !0, color: "primary.light", variant: "XSmall", children: l.short_title })
|
|
52
52
|
] });
|
|
53
|
-
},
|
|
54
|
-
const { transactions:
|
|
53
|
+
}, Tt = (t) => {
|
|
54
|
+
const { transactions: r } = w(), [o, a] = c.useState(!1);
|
|
55
55
|
return /* @__PURE__ */ _(
|
|
56
|
-
|
|
56
|
+
N,
|
|
57
57
|
{
|
|
58
58
|
alignItems: "center",
|
|
59
59
|
direction: "row",
|
|
@@ -63,22 +63,22 @@ const ft = (t) => /* @__PURE__ */ _(C, { tabIndex: t.tabIndex, variant: "Small",
|
|
|
63
63
|
onMouseLeave: () => a(!1),
|
|
64
64
|
width: "100%",
|
|
65
65
|
children: [
|
|
66
|
-
t.row.has_been_split && /* @__PURE__ */ e(
|
|
67
|
-
/* @__PURE__ */ e(C, { tabIndex: t.tabIndex, variant: "Small", children: t.row.has_been_split ?
|
|
68
|
-
!t.row.has_been_split && o && /* @__PURE__ */ e(
|
|
66
|
+
t.row.has_been_split && /* @__PURE__ */ e(P, { name: "call_split", size: 16 }),
|
|
67
|
+
/* @__PURE__ */ e(C, { tabIndex: t.tabIndex, variant: "Small", children: t.row.has_been_split ? r.split_transaction_category_label : t.row.category }),
|
|
68
|
+
!t.row.has_been_split && o && /* @__PURE__ */ e(P, { name: "edit", sx: { color: "action.active" } })
|
|
69
69
|
]
|
|
70
70
|
}
|
|
71
71
|
);
|
|
72
|
-
},
|
|
73
|
-
const
|
|
72
|
+
}, At = x(Tt), St = (t) => /* @__PURE__ */ e(C, { tabIndex: t.tabIndex, variant: "Small", children: at(tt(t.row.date), nt.MONTH_DAY) }), xt = (t) => {
|
|
73
|
+
const r = je(), { transactions: o } = w(), { is_flagged: a, is_hidden: i, has_been_viewed: l, parent_guid: d } = t.row, g = !l && !!!d;
|
|
74
74
|
return /* @__PURE__ */ _(
|
|
75
|
-
|
|
75
|
+
T,
|
|
76
76
|
{
|
|
77
77
|
"aria-label": i ? o.is_hidden : o.is_flagged,
|
|
78
78
|
tabIndex: t.tabIndex,
|
|
79
79
|
children: [
|
|
80
|
-
a && /* @__PURE__ */ e(
|
|
81
|
-
!a && i && /* @__PURE__ */ e(
|
|
80
|
+
a && /* @__PURE__ */ e(P, { fill: !0, name: "flag", size: 16, sx: { color: "warning.dark" } }),
|
|
81
|
+
!a && i && /* @__PURE__ */ e(P, { name: "visibility_off", size: 16 }),
|
|
82
82
|
g && /* @__PURE__ */ e(
|
|
83
83
|
"svg",
|
|
84
84
|
{
|
|
@@ -86,7 +86,7 @@ const ft = (t) => /* @__PURE__ */ _(C, { tabIndex: t.tabIndex, variant: "Small",
|
|
|
86
86
|
style: {
|
|
87
87
|
display: "inline-block",
|
|
88
88
|
height: 16,
|
|
89
|
-
fill:
|
|
89
|
+
fill: r.palette.primary.light,
|
|
90
90
|
verticalAlign: "middle",
|
|
91
91
|
width: 16
|
|
92
92
|
},
|
|
@@ -97,48 +97,48 @@ const ft = (t) => /* @__PURE__ */ _(C, { tabIndex: t.tabIndex, variant: "Small",
|
|
|
97
97
|
]
|
|
98
98
|
}
|
|
99
99
|
);
|
|
100
|
-
},
|
|
100
|
+
}, wt = x(xt), O = (t) => /* @__PURE__ */ e(C, { fontWeight: 600, variant: "Small", children: t.colDef.headerName }), vt = (t) => /* @__PURE__ */ _(N, { alignItems: "center", direction: "row", gap: 8, children: [
|
|
101
101
|
/* @__PURE__ */ e(
|
|
102
|
-
|
|
102
|
+
Xe,
|
|
103
103
|
{
|
|
104
104
|
categoryGuid: t.row.top_level_category_guid || "",
|
|
105
105
|
merchantGuid: t.row.merchant_guid || ""
|
|
106
106
|
}
|
|
107
107
|
),
|
|
108
108
|
/* @__PURE__ */ e(C, { tabIndex: t.tabIndex, variant: "Small", children: t.row.payee })
|
|
109
|
-
] }),
|
|
109
|
+
] }), It = ({
|
|
110
110
|
height: t = "100dvh",
|
|
111
|
-
onCategoryClick:
|
|
111
|
+
onCategoryClick: r,
|
|
112
112
|
onRowClick: o
|
|
113
113
|
}) => {
|
|
114
|
-
const { transactions: a } =
|
|
115
|
-
|
|
116
|
-
const
|
|
114
|
+
const { transactions: a } = w(), { isCopyLoaded: i } = j(), { isLoading: l, sortedTransactions: d } = $(), { clearExpandedSplits: p, toggleSplit: g } = B();
|
|
115
|
+
c.useEffect(() => () => p(), []);
|
|
116
|
+
const f = c.useMemo(
|
|
117
117
|
() => d.map((n) => ({
|
|
118
118
|
id: n.guid,
|
|
119
119
|
isHovering: !1,
|
|
120
120
|
...n
|
|
121
121
|
})),
|
|
122
122
|
[d]
|
|
123
|
-
),
|
|
123
|
+
), m = ({ row: { id: n, guid: h, has_been_split: A }, field: E }) => A ? g(n) : E === "category" ? r?.(h) : o?.(h);
|
|
124
124
|
if (!i)
|
|
125
|
-
return /* @__PURE__ */ e(
|
|
126
|
-
const
|
|
125
|
+
return /* @__PURE__ */ e(X, {});
|
|
126
|
+
const v = [
|
|
127
127
|
{
|
|
128
128
|
field: "flag",
|
|
129
129
|
headerName: "",
|
|
130
130
|
minWidth: 32,
|
|
131
131
|
width: 32,
|
|
132
132
|
sortable: !1,
|
|
133
|
-
renderCell: (n) => /* @__PURE__ */ e(
|
|
133
|
+
renderCell: (n) => /* @__PURE__ */ e(wt, { ...n }),
|
|
134
134
|
renderHeader: () => /* @__PURE__ */ e("span", { "aria-label": a.transaction_status, role: "presentation" })
|
|
135
135
|
},
|
|
136
136
|
{
|
|
137
137
|
field: "date",
|
|
138
138
|
headerName: a.date_title,
|
|
139
139
|
width: 103,
|
|
140
|
-
renderHeader:
|
|
141
|
-
renderCell: (n) => n.row.parent_guid ? null : /* @__PURE__ */ e(
|
|
140
|
+
renderHeader: O,
|
|
141
|
+
renderCell: (n) => n.row.parent_guid ? null : /* @__PURE__ */ e(St, { ...n }),
|
|
142
142
|
sortingOrder: ["desc", "asc"]
|
|
143
143
|
},
|
|
144
144
|
{
|
|
@@ -146,49 +146,49 @@ const ft = (t) => /* @__PURE__ */ _(C, { tabIndex: t.tabIndex, variant: "Small",
|
|
|
146
146
|
field: "payee",
|
|
147
147
|
headerName: a.payee_title,
|
|
148
148
|
flex: 0.33,
|
|
149
|
-
renderHeader:
|
|
150
|
-
renderCell:
|
|
149
|
+
renderHeader: O,
|
|
150
|
+
renderCell: vt,
|
|
151
151
|
sortingOrder: ["asc", "desc"]
|
|
152
152
|
},
|
|
153
153
|
{
|
|
154
154
|
field: "category",
|
|
155
155
|
headerName: a.category_title,
|
|
156
156
|
flex: 0.25,
|
|
157
|
-
renderHeader:
|
|
158
|
-
renderCell: (n) => /* @__PURE__ */ e(
|
|
157
|
+
renderHeader: O,
|
|
158
|
+
renderCell: (n) => /* @__PURE__ */ e(At, { ...n }),
|
|
159
159
|
sortingOrder: ["asc", "desc"]
|
|
160
160
|
},
|
|
161
161
|
{
|
|
162
162
|
field: "account",
|
|
163
163
|
headerName: a.account_title,
|
|
164
164
|
flex: 0.33,
|
|
165
|
-
renderHeader:
|
|
166
|
-
renderCell: (n) => n.row.parent_guid ? null : /* @__PURE__ */ e(
|
|
165
|
+
renderHeader: O,
|
|
166
|
+
renderCell: (n) => n.row.parent_guid ? null : /* @__PURE__ */ e(yt, { ...n }),
|
|
167
167
|
sortingOrder: ["asc", "desc"]
|
|
168
168
|
},
|
|
169
169
|
{
|
|
170
170
|
field: "amount",
|
|
171
171
|
headerName: a.amount_title,
|
|
172
172
|
flex: 0.25,
|
|
173
|
-
renderHeader:
|
|
174
|
-
renderCell:
|
|
173
|
+
renderHeader: O,
|
|
174
|
+
renderCell: bt,
|
|
175
175
|
align: "right",
|
|
176
176
|
headerAlign: "right",
|
|
177
177
|
sortingOrder: ["asc", "desc"]
|
|
178
178
|
}
|
|
179
179
|
];
|
|
180
|
-
return /* @__PURE__ */ e(
|
|
181
|
-
|
|
180
|
+
return /* @__PURE__ */ e(Ke, { sx: { height: t, px: 24, width: "100%", boxShadow: "none" }, children: /* @__PURE__ */ e(
|
|
181
|
+
qe,
|
|
182
182
|
{
|
|
183
|
-
columns:
|
|
183
|
+
columns: v,
|
|
184
184
|
disableColumnFilter: !0,
|
|
185
185
|
disableColumnMenu: !0,
|
|
186
186
|
getCellClassName: (n) => n.row.parent_guid ? "split-row" : "",
|
|
187
187
|
hideFooter: !0,
|
|
188
188
|
initialState: { sorting: { sortModel: [{ field: "date", sort: "desc" }] } },
|
|
189
189
|
loading: l,
|
|
190
|
-
onCellClick:
|
|
191
|
-
rows:
|
|
190
|
+
onCellClick: m,
|
|
191
|
+
rows: f,
|
|
192
192
|
slotProps: { baseIconButton: { color: "secondary", sx: { ml: 8 } } },
|
|
193
193
|
sx: {
|
|
194
194
|
"& .split-row": {
|
|
@@ -197,15 +197,15 @@ const ft = (t) => /* @__PURE__ */ _(C, { tabIndex: t.tabIndex, variant: "Small",
|
|
|
197
197
|
}
|
|
198
198
|
}
|
|
199
199
|
) });
|
|
200
|
-
},
|
|
201
|
-
const { common: i, transactions: l } =
|
|
200
|
+
}, Dt = x(It), Nt = ({ copy: t, isOpen: r, onClose: o, onPrimaryAction: a }) => {
|
|
201
|
+
const { common: i, transactions: l } = w(), { isCopyLoaded: d } = j();
|
|
202
202
|
return d ? /* @__PURE__ */ _(
|
|
203
|
-
|
|
203
|
+
ie,
|
|
204
204
|
{
|
|
205
205
|
copy: {
|
|
206
206
|
title: t.title
|
|
207
207
|
},
|
|
208
|
-
isOpen:
|
|
208
|
+
isOpen: r,
|
|
209
209
|
onClose: o,
|
|
210
210
|
onPrimaryAction: a,
|
|
211
211
|
primaryText: l.add_manual_account,
|
|
@@ -215,43 +215,43 @@ const ft = (t) => /* @__PURE__ */ _(C, { tabIndex: t.tabIndex, variant: "Small",
|
|
|
215
215
|
/* @__PURE__ */ e(C, { component: "p", truncate: !1, children: l.add_account_modal_cta })
|
|
216
216
|
]
|
|
217
217
|
}
|
|
218
|
-
) : /* @__PURE__ */ e(
|
|
219
|
-
},
|
|
220
|
-
const { visibleAccounts: t } =
|
|
221
|
-
() => t.filter((
|
|
218
|
+
) : /* @__PURE__ */ e(X, {});
|
|
219
|
+
}, Et = x(Nt), Ot = () => {
|
|
220
|
+
const { visibleAccounts: t } = se(), { common: r, transactions: o } = w(), { manualTransaction: a, setIsAmountValid: i, updateManualTransaction: l } = B(), [d, p] = c.useState(""), [g, f] = c.useState(""), m = c.useMemo(
|
|
221
|
+
() => t.filter((s) => s.is_manual),
|
|
222
222
|
[t]
|
|
223
|
-
).map((
|
|
224
|
-
label: `${
|
|
225
|
-
value:
|
|
226
|
-
})),
|
|
227
|
-
error_amount_is_invalid:
|
|
228
|
-
error_amount_must_be_equal_to:
|
|
229
|
-
error_amount_must_be_less_than_or_equal_to:
|
|
230
|
-
enter_amount:
|
|
231
|
-
}, n = (
|
|
232
|
-
p(
|
|
233
|
-
},
|
|
223
|
+
).map((s) => ({
|
|
224
|
+
label: `${s.name} | ${ce(s.balance, "0,0.00")}`,
|
|
225
|
+
value: s.guid
|
|
226
|
+
})), v = {
|
|
227
|
+
error_amount_is_invalid: r.currency_input.error_amount_is_invalid,
|
|
228
|
+
error_amount_must_be_equal_to: r.currency_input.error_amount_must_be_equal_to,
|
|
229
|
+
error_amount_must_be_less_than_or_equal_to: r.currency_input.error_amount_must_be_less_than_or_equal_to,
|
|
230
|
+
enter_amount: r.currency_input.enter_amount
|
|
231
|
+
}, n = (s) => {
|
|
232
|
+
p(s), l({ ...a, amount: Number(s) });
|
|
233
|
+
}, h = (s, k) => {
|
|
234
234
|
l({ ...a, transaction_type: Number(k) });
|
|
235
|
-
},
|
|
236
|
-
|
|
237
|
-
},
|
|
238
|
-
l({ ...a, account_guid:
|
|
235
|
+
}, A = (s) => {
|
|
236
|
+
f(s), l({ ...a, payee: s, description: s });
|
|
237
|
+
}, E = (s) => {
|
|
238
|
+
l({ ...a, account_guid: s });
|
|
239
239
|
};
|
|
240
|
-
return /* @__PURE__ */ _(
|
|
241
|
-
/* @__PURE__ */ _(
|
|
240
|
+
return /* @__PURE__ */ _(T, { className: "mx-txn-manual-transaction-details", children: [
|
|
241
|
+
/* @__PURE__ */ _(N, { gap: 40, mx: 24, my: 32, children: [
|
|
242
242
|
/* @__PURE__ */ _(
|
|
243
|
-
|
|
243
|
+
N,
|
|
244
244
|
{
|
|
245
245
|
direction: "row",
|
|
246
246
|
sx: { flexDirection: { xs: "column", sm: "row" }, gap: { xs: 40, sm: 8 } },
|
|
247
247
|
children: [
|
|
248
248
|
/* @__PURE__ */ e(
|
|
249
|
-
|
|
249
|
+
_t,
|
|
250
250
|
{
|
|
251
251
|
allowDecimals: !0,
|
|
252
252
|
amount: d,
|
|
253
253
|
ariaLabel: o.amount_title,
|
|
254
|
-
copy:
|
|
254
|
+
copy: v,
|
|
255
255
|
inputProps: {
|
|
256
256
|
noValidate: !0
|
|
257
257
|
},
|
|
@@ -262,9 +262,9 @@ const ft = (t) => /* @__PURE__ */ _(C, { tabIndex: t.tabIndex, variant: "Small",
|
|
|
262
262
|
type: "number"
|
|
263
263
|
}
|
|
264
264
|
),
|
|
265
|
-
/* @__PURE__ */ e(
|
|
265
|
+
/* @__PURE__ */ e(ut, { name: "TransactionType", onChange: h, row: !0, children: /* @__PURE__ */ _(N, { alignItems: "center", direction: "row", children: [
|
|
266
266
|
/* @__PURE__ */ e(
|
|
267
|
-
|
|
267
|
+
ae,
|
|
268
268
|
{
|
|
269
269
|
checked: a.transaction_type === M.CREDIT,
|
|
270
270
|
label: o.manual_transaction_credit_button_label,
|
|
@@ -274,7 +274,7 @@ const ft = (t) => /* @__PURE__ */ _(C, { tabIndex: t.tabIndex, variant: "Small",
|
|
|
274
274
|
}
|
|
275
275
|
),
|
|
276
276
|
/* @__PURE__ */ e(
|
|
277
|
-
|
|
277
|
+
ae,
|
|
278
278
|
{
|
|
279
279
|
checked: a.transaction_type === M.DEBIT,
|
|
280
280
|
label: o.manual_transaction_debit_button_label,
|
|
@@ -287,97 +287,125 @@ const ft = (t) => /* @__PURE__ */ _(C, { tabIndex: t.tabIndex, variant: "Small",
|
|
|
287
287
|
}
|
|
288
288
|
),
|
|
289
289
|
/* @__PURE__ */ e(
|
|
290
|
-
|
|
290
|
+
ne,
|
|
291
291
|
{
|
|
292
292
|
label: o.payee_title,
|
|
293
293
|
name: "payee",
|
|
294
|
-
onChange: (
|
|
294
|
+
onChange: (s) => A(s.target.value),
|
|
295
295
|
sx: { bgcolor: "background.paper" },
|
|
296
296
|
value: g
|
|
297
297
|
}
|
|
298
298
|
),
|
|
299
299
|
/* @__PURE__ */ e(
|
|
300
|
-
|
|
300
|
+
ne,
|
|
301
301
|
{
|
|
302
302
|
InputLabelProps: { shrink: !0 },
|
|
303
|
-
SelectProps: { defaultValue: -1, IconComponent:
|
|
303
|
+
SelectProps: { defaultValue: -1, IconComponent: mt },
|
|
304
304
|
label: o.manual_transaction_select_an_account,
|
|
305
|
-
onChange: (
|
|
305
|
+
onChange: (s) => E(s.target.value),
|
|
306
306
|
placeholder: o.manual_transaction_select,
|
|
307
307
|
select: !0,
|
|
308
308
|
sx: { bgcolor: "background.paper" },
|
|
309
|
-
children:
|
|
309
|
+
children: m.map((s) => /* @__PURE__ */ e(dt, { value: s.value, children: s.label }, s.value))
|
|
310
310
|
}
|
|
311
311
|
)
|
|
312
312
|
] }),
|
|
313
|
-
/* @__PURE__ */ e(
|
|
314
|
-
/* @__PURE__ */ _(
|
|
315
|
-
/* @__PURE__ */ e(He, { transaction: a }),
|
|
313
|
+
/* @__PURE__ */ e(lt, { light: !0 }),
|
|
314
|
+
/* @__PURE__ */ _(T, { bgcolor: "background.paper", children: [
|
|
316
315
|
/* @__PURE__ */ e(Be, { transaction: a }),
|
|
317
|
-
/* @__PURE__ */ e(
|
|
318
|
-
/* @__PURE__ */ e(
|
|
316
|
+
/* @__PURE__ */ e($e, { transaction: a }),
|
|
317
|
+
/* @__PURE__ */ e(Ve, { transaction: a }),
|
|
318
|
+
/* @__PURE__ */ e(We, { transaction: a })
|
|
319
319
|
] })
|
|
320
320
|
] });
|
|
321
|
-
},
|
|
322
|
-
const { addOrUpdateTransactionRule: o, updateTransaction: a } = $(), { transactions: i } =
|
|
323
|
-
() => l.find((
|
|
321
|
+
}, Mt = x(Ot), kt = ({ onClose: t, transaction: r }) => {
|
|
322
|
+
const { addOrUpdateTransactionRule: o, updateTransaction: a } = $(), { transactions: i } = w(), { categories: l } = Je(), [d, p] = c.useState(""), g = c.useMemo(
|
|
323
|
+
() => l.find((m) => m.guid === d),
|
|
324
324
|
[d]
|
|
325
|
-
),
|
|
326
|
-
await a({ ...
|
|
325
|
+
), f = async (m) => {
|
|
326
|
+
await a({ ...r, category_guid: d }), m && await o(d, r), p(""), t();
|
|
327
327
|
};
|
|
328
|
-
return /* @__PURE__ */ _(
|
|
328
|
+
return /* @__PURE__ */ _(T, { className: "mx-txn-edit-category-action", children: [
|
|
329
329
|
/* @__PURE__ */ e(
|
|
330
|
-
|
|
330
|
+
pt,
|
|
331
331
|
{
|
|
332
|
-
initialSelected:
|
|
332
|
+
initialSelected: r.category_guid,
|
|
333
333
|
onClose: t,
|
|
334
|
-
onSelect: (
|
|
335
|
-
showDrawer: !!
|
|
334
|
+
onSelect: (m) => p(m),
|
|
335
|
+
showDrawer: !!r,
|
|
336
336
|
title: i.actions_select_a_category
|
|
337
337
|
}
|
|
338
338
|
),
|
|
339
339
|
/* @__PURE__ */ e(
|
|
340
|
-
|
|
340
|
+
ie,
|
|
341
341
|
{
|
|
342
342
|
copy: {
|
|
343
|
-
title:
|
|
343
|
+
title: q(
|
|
344
344
|
i.actions_apply_to_all_transaction_types,
|
|
345
|
-
|
|
345
|
+
r.description
|
|
346
346
|
)
|
|
347
347
|
},
|
|
348
348
|
isOpen: !!d,
|
|
349
|
-
onClose: () =>
|
|
350
|
-
onPrimaryAction: () =>
|
|
351
|
-
onSecondaryAction: () =>
|
|
349
|
+
onClose: () => f(!1),
|
|
350
|
+
onPrimaryAction: () => f(!0),
|
|
351
|
+
onSecondaryAction: () => f(!1),
|
|
352
352
|
primaryText: i.actions_apply_to_all,
|
|
353
353
|
secondaryText: i.actions_this_time_only,
|
|
354
|
-
children: /* @__PURE__ */ e(
|
|
354
|
+
children: /* @__PURE__ */ e(Ye, { variant: "Paragraph", children: q(
|
|
355
355
|
i.actions_all_past_and_future,
|
|
356
|
-
|
|
356
|
+
r.description,
|
|
357
357
|
g?.name
|
|
358
358
|
) })
|
|
359
359
|
}
|
|
360
360
|
)
|
|
361
361
|
] });
|
|
362
|
-
},
|
|
362
|
+
}, Lt = x(kt), Rt = (t = "polite") => {
|
|
363
|
+
const [r, o] = c.useState(""), [a, i] = c.useState(t), l = c.useCallback((p, g) => {
|
|
364
|
+
g && i(g), o(p);
|
|
365
|
+
}, []), d = c.useMemo(
|
|
366
|
+
() => /* @__PURE__ */ e(
|
|
367
|
+
T,
|
|
368
|
+
{
|
|
369
|
+
"aria-atomic": "true",
|
|
370
|
+
"aria-live": a,
|
|
371
|
+
role: a === "assertive" ? "alert" : "status",
|
|
372
|
+
sx: {
|
|
373
|
+
position: "absolute",
|
|
374
|
+
width: "1px",
|
|
375
|
+
height: "1px",
|
|
376
|
+
padding: 0,
|
|
377
|
+
margin: "-1px",
|
|
378
|
+
overflow: "hidden",
|
|
379
|
+
clip: "rect(0 0 0 0)",
|
|
380
|
+
clipPath: "inset(50%)",
|
|
381
|
+
whiteSpace: "nowrap",
|
|
382
|
+
border: 0
|
|
383
|
+
},
|
|
384
|
+
children: r
|
|
385
|
+
}
|
|
386
|
+
),
|
|
387
|
+
[r, a]
|
|
388
|
+
);
|
|
389
|
+
return { announce: l, ariaLive: d };
|
|
390
|
+
}, re = 120, Ht = ({
|
|
363
391
|
onBackClick: t,
|
|
364
|
-
height:
|
|
392
|
+
height: r = "100dvh",
|
|
365
393
|
showInsights: o = !1,
|
|
366
394
|
sx: a = {}
|
|
367
395
|
}) => {
|
|
368
|
-
const { visibleAccounts: i, refreshAccounts: l } =
|
|
369
|
-
displayedDateRange:
|
|
370
|
-
isCopyLoaded:
|
|
371
|
-
isInitialized:
|
|
372
|
-
selectedAccountGuids:
|
|
396
|
+
const { visibleAccounts: i, refreshAccounts: l } = se(), { is_mobile_webview: d, clientConfig: p, config: g } = Qe(), { setSearchValue: f } = gt(), { onEvent: m } = Ze(), { common: v, transactions: n } = w(), {
|
|
397
|
+
displayedDateRange: h,
|
|
398
|
+
isCopyLoaded: A,
|
|
399
|
+
isInitialized: E,
|
|
400
|
+
selectedAccountGuids: s,
|
|
373
401
|
setDisplayedDate: k,
|
|
374
|
-
setSelectedAccounts:
|
|
375
|
-
} =
|
|
376
|
-
addTransaction:
|
|
377
|
-
filter:
|
|
378
|
-
loadAssociatedBeats:
|
|
402
|
+
setSelectedAccounts: le
|
|
403
|
+
} = j(), { isDesktop: de, isTablet: ue } = ft(), L = it(), {
|
|
404
|
+
addTransaction: me,
|
|
405
|
+
filter: Y,
|
|
406
|
+
loadAssociatedBeats: _e,
|
|
379
407
|
setFilter: V,
|
|
380
|
-
sortedTransactionsWithSplits:
|
|
408
|
+
sortedTransactionsWithSplits: W,
|
|
381
409
|
tags: pe,
|
|
382
410
|
transactions: ge,
|
|
383
411
|
updateTransaction: he
|
|
@@ -389,125 +417,133 @@ const ft = (t) => /* @__PURE__ */ _(C, { tabIndex: t.tabIndex, variant: "Small",
|
|
|
389
417
|
setSearchValue: be,
|
|
390
418
|
setShowInsights: Te,
|
|
391
419
|
updateManualTransaction: Ae
|
|
392
|
-
} =
|
|
393
|
-
|
|
394
|
-
const
|
|
395
|
-
I ||
|
|
396
|
-
accounts:
|
|
397
|
-
custom: (
|
|
398
|
-
dateRange: { start:
|
|
399
|
-
}),
|
|
400
|
-
}, [i]),
|
|
401
|
-
|
|
402
|
-
...
|
|
403
|
-
accounts: I ? [I] :
|
|
404
|
-
dateRange: { start:
|
|
405
|
-
}),
|
|
406
|
-
}, [
|
|
420
|
+
} = B(), { userProfile: Se } = et(), [G, y] = c.useState(""), [J, H] = c.useState(""), [xe, U] = c.useState(!1), [we, Q] = c.useState(!1), [F, ve] = c.useState(!1), { announce: Ie, ariaLive: De } = Rt(), I = p?.transactions?.selected_account_guid;
|
|
421
|
+
c.useEffect(() => {
|
|
422
|
+
const u = I ? [{ guid: I }] : i.filter((D) => !D.is_hidden), ee = st(K()), te = ot(K());
|
|
423
|
+
I || le(u), k(ee, te), V({
|
|
424
|
+
accounts: u.map((D) => D.guid),
|
|
425
|
+
custom: (D) => !D.accountIsClosed && !D.accountIsHidden,
|
|
426
|
+
dateRange: { start: ee, end: te }
|
|
427
|
+
}), ve(!0), m(S.TRANSACTIONS_VIEW);
|
|
428
|
+
}, [i]), c.useEffect(() => {
|
|
429
|
+
F && (V({
|
|
430
|
+
...Y,
|
|
431
|
+
accounts: I ? [I] : s,
|
|
432
|
+
dateRange: { start: h.start, end: h.end }
|
|
433
|
+
}), _e(h.start).finally());
|
|
434
|
+
}, [F, h, s]), c.useEffect(() => {
|
|
407
435
|
Te(o);
|
|
408
|
-
}, [o])
|
|
409
|
-
|
|
410
|
-
|
|
436
|
+
}, [o]), c.useEffect(() => {
|
|
437
|
+
A && n.showing_transactions_count && Ie(
|
|
438
|
+
q(
|
|
439
|
+
n.showing_transactions_count,
|
|
440
|
+
W.length
|
|
441
|
+
)
|
|
442
|
+
);
|
|
443
|
+
}, [A, h, s, W, n]);
|
|
444
|
+
const Ne = c.useMemo(
|
|
445
|
+
() => i.filter((u) => u.is_manual),
|
|
411
446
|
[i]
|
|
412
|
-
), b =
|
|
413
|
-
fe(), k(
|
|
414
|
-
},
|
|
415
|
-
be(
|
|
416
|
-
...
|
|
417
|
-
searchTerm:
|
|
418
|
-
}),
|
|
419
|
-
},
|
|
420
|
-
|
|
421
|
-
},
|
|
422
|
-
|
|
423
|
-
...
|
|
424
|
-
date:
|
|
447
|
+
), b = J ? ge.find((u) => u.guid === J) : void 0, Z = Ce && !!R.payee && !!R.account_guid && !!R.category_guid, Ee = (u) => {
|
|
448
|
+
fe(), k(u[0], u[1]);
|
|
449
|
+
}, Oe = (u) => {
|
|
450
|
+
be(u), V({
|
|
451
|
+
...Y,
|
|
452
|
+
searchTerm: u
|
|
453
|
+
}), m(S.TRANSACTIONS_CLICK_SEARCH, { search_term: u });
|
|
454
|
+
}, Me = () => {
|
|
455
|
+
ze(W, pe), m(S.TRANSACTIONS_CLICK_EXPORT);
|
|
456
|
+
}, ke = () => {
|
|
457
|
+
Ne.length > 0 ? (Ae({
|
|
458
|
+
...Fe,
|
|
459
|
+
date: rt(K()),
|
|
425
460
|
user_guid: Se?.user_guid || ""
|
|
426
461
|
}), y(
|
|
427
462
|
"addTransaction"
|
|
428
463
|
/* AddTransaction */
|
|
429
|
-
),
|
|
430
|
-
}, Me = async () => {
|
|
431
|
-
J && await ue(R), y("");
|
|
432
|
-
}, ke = () => {
|
|
433
|
-
G(!1), Y(!0);
|
|
464
|
+
), m(S.TRANSACTIONS_CLICK_ADD)) : (U(!0), m(S.TRANSACTIONS_ADD_MANUAL_ACCOUNT_MODAL));
|
|
434
465
|
}, Le = async () => {
|
|
435
|
-
|
|
436
|
-
}, Re =
|
|
466
|
+
Z && await me(R), y("");
|
|
467
|
+
}, Re = () => {
|
|
468
|
+
U(!1), Q(!0);
|
|
469
|
+
}, He = async () => {
|
|
470
|
+
Q(!1), await l();
|
|
471
|
+
}, Pe = async () => {
|
|
437
472
|
b && !b.has_been_viewed && await he({ ...b, has_been_viewed: !0 }), y("");
|
|
438
473
|
};
|
|
439
|
-
if (!
|
|
440
|
-
return /* @__PURE__ */ e(
|
|
441
|
-
const
|
|
442
|
-
return !d && (
|
|
474
|
+
if (!A || !E || !F)
|
|
475
|
+
return /* @__PURE__ */ e(X, {});
|
|
476
|
+
const z = [];
|
|
477
|
+
return !d && (de || ue) && z.push({
|
|
443
478
|
iconName: "open_in_new",
|
|
444
479
|
label: n.export_csv_btn,
|
|
445
|
-
onClick:
|
|
446
|
-
}), g.show_connections_widget_in_master &&
|
|
480
|
+
onClick: Me
|
|
481
|
+
}), g.show_connections_widget_in_master && z.push({
|
|
447
482
|
iconName: "add",
|
|
448
483
|
label: n.add_transaction_btn,
|
|
449
|
-
onClick:
|
|
484
|
+
onClick: ke
|
|
450
485
|
}), /* @__PURE__ */ _(
|
|
451
|
-
|
|
486
|
+
ht,
|
|
452
487
|
{
|
|
453
488
|
...!I && { accountOptions: i },
|
|
454
|
-
actions:
|
|
489
|
+
actions: z,
|
|
455
490
|
calendarActions: {
|
|
456
|
-
onRangeChanged:
|
|
491
|
+
onRangeChanged: Ee
|
|
457
492
|
},
|
|
458
|
-
onAccountsFilterClick: () =>
|
|
493
|
+
onAccountsFilterClick: () => m(S.ACCOUNTS_CLICK_FILTER),
|
|
459
494
|
onBackClick: t,
|
|
460
495
|
sx: a,
|
|
461
496
|
title: n.transactions_title,
|
|
462
497
|
children: [
|
|
463
|
-
|
|
464
|
-
|
|
498
|
+
De,
|
|
499
|
+
/* @__PURE__ */ e(T, { mt: 16, children: /* @__PURE__ */ e(
|
|
500
|
+
Ct,
|
|
465
501
|
{
|
|
466
|
-
onChange:
|
|
502
|
+
onChange: Oe,
|
|
467
503
|
placeholder: n.action_bar_search_placeholder,
|
|
468
504
|
searchValue: ye
|
|
469
505
|
}
|
|
470
506
|
) }),
|
|
471
507
|
/* @__PURE__ */ e(
|
|
472
|
-
|
|
508
|
+
T,
|
|
473
509
|
{
|
|
474
510
|
sx: {
|
|
475
511
|
[L.breakpoints.down("md")]: { display: "none" },
|
|
476
512
|
[L.breakpoints.up("md")]: { display: "block" }
|
|
477
513
|
},
|
|
478
514
|
children: /* @__PURE__ */ e(
|
|
479
|
-
|
|
515
|
+
Dt,
|
|
480
516
|
{
|
|
481
|
-
height: `calc(${
|
|
482
|
-
onCategoryClick: (
|
|
483
|
-
H(
|
|
517
|
+
height: `calc(${r} - ${re}px)`,
|
|
518
|
+
onCategoryClick: (u) => {
|
|
519
|
+
H(u), y(
|
|
484
520
|
"category"
|
|
485
521
|
/* Category */
|
|
486
522
|
);
|
|
487
523
|
},
|
|
488
|
-
onRowClick: (
|
|
489
|
-
H(
|
|
524
|
+
onRowClick: (u) => {
|
|
525
|
+
H(u), y(
|
|
490
526
|
"transaction"
|
|
491
527
|
/* Transaction */
|
|
492
|
-
),
|
|
528
|
+
), m(S.TRANSACTIONS_CLICK_DETAILS, { transaction_guid: u });
|
|
493
529
|
}
|
|
494
530
|
}
|
|
495
531
|
)
|
|
496
532
|
}
|
|
497
533
|
),
|
|
498
534
|
/* @__PURE__ */ e(
|
|
499
|
-
|
|
535
|
+
T,
|
|
500
536
|
{
|
|
501
537
|
sx: {
|
|
502
538
|
[L.breakpoints.down("md")]: { display: "block" },
|
|
503
539
|
[L.breakpoints.up("md")]: { display: "none" }
|
|
504
540
|
},
|
|
505
541
|
children: /* @__PURE__ */ e(
|
|
506
|
-
|
|
542
|
+
Ge,
|
|
507
543
|
{
|
|
508
|
-
height: `calc(${
|
|
509
|
-
onClick: (
|
|
510
|
-
H(
|
|
544
|
+
height: `calc(${r} - ${re}px)`,
|
|
545
|
+
onClick: (u) => {
|
|
546
|
+
H(u), y(
|
|
511
547
|
"transaction"
|
|
512
548
|
/* Transaction */
|
|
513
549
|
);
|
|
@@ -519,51 +555,51 @@ const ft = (t) => /* @__PURE__ */ _(C, { tabIndex: t.tabIndex, variant: "Small",
|
|
|
519
555
|
}
|
|
520
556
|
),
|
|
521
557
|
/* @__PURE__ */ e(
|
|
522
|
-
|
|
558
|
+
oe,
|
|
523
559
|
{
|
|
524
|
-
ariaLabelClose:
|
|
525
|
-
isOpen:
|
|
526
|
-
onClose:
|
|
560
|
+
ariaLabelClose: v.close_aria,
|
|
561
|
+
isOpen: G === "transaction" && !!b,
|
|
562
|
+
onClose: Pe,
|
|
527
563
|
title: n.details_title,
|
|
528
|
-
children: b && /* @__PURE__ */ e(
|
|
564
|
+
children: b && /* @__PURE__ */ e(Ue, { transaction: b })
|
|
529
565
|
}
|
|
530
566
|
),
|
|
531
|
-
b &&
|
|
532
|
-
|
|
567
|
+
b && G === "category" && /* @__PURE__ */ e(
|
|
568
|
+
Lt,
|
|
533
569
|
{
|
|
534
570
|
onClose: () => {
|
|
535
|
-
|
|
571
|
+
f(""), y(""), H("");
|
|
536
572
|
},
|
|
537
573
|
transaction: b
|
|
538
574
|
}
|
|
539
575
|
),
|
|
540
576
|
/* @__PURE__ */ e(
|
|
541
|
-
|
|
577
|
+
oe,
|
|
542
578
|
{
|
|
543
|
-
ariaLabelClose:
|
|
544
|
-
isOpen:
|
|
545
|
-
isPrimaryDisabled: !
|
|
579
|
+
ariaLabelClose: v.close_aria,
|
|
580
|
+
isOpen: G === "addTransaction",
|
|
581
|
+
isPrimaryDisabled: !Z,
|
|
546
582
|
onClose: () => y(""),
|
|
547
|
-
onPrimaryAction:
|
|
583
|
+
onPrimaryAction: Le,
|
|
548
584
|
title: n.add_transaction_title,
|
|
549
|
-
children: /* @__PURE__ */ e(
|
|
585
|
+
children: /* @__PURE__ */ e(Mt, {})
|
|
550
586
|
}
|
|
551
587
|
),
|
|
552
588
|
/* @__PURE__ */ e(
|
|
553
|
-
|
|
589
|
+
Et,
|
|
554
590
|
{
|
|
555
591
|
copy: { title: n.add_manual_account },
|
|
556
592
|
isOpen: xe,
|
|
557
593
|
onClose: () => {
|
|
558
|
-
|
|
594
|
+
U(!1);
|
|
559
595
|
},
|
|
560
|
-
onPrimaryAction:
|
|
596
|
+
onPrimaryAction: Re
|
|
561
597
|
}
|
|
562
598
|
),
|
|
563
599
|
/* @__PURE__ */ e(
|
|
564
|
-
|
|
600
|
+
ct,
|
|
565
601
|
{
|
|
566
|
-
onClose:
|
|
602
|
+
onClose: He,
|
|
567
603
|
showConnectWidget: we,
|
|
568
604
|
title: n.add_manual_account
|
|
569
605
|
}
|
|
@@ -571,20 +607,20 @@ const ft = (t) => /* @__PURE__ */ _(C, { tabIndex: t.tabIndex, variant: "Small",
|
|
|
571
607
|
]
|
|
572
608
|
}
|
|
573
609
|
);
|
|
574
|
-
},
|
|
610
|
+
}, Ca = x(Ht);
|
|
575
611
|
export {
|
|
576
|
-
|
|
577
|
-
|
|
578
|
-
|
|
579
|
-
|
|
580
|
-
|
|
581
|
-
|
|
582
|
-
|
|
583
|
-
|
|
584
|
-
|
|
585
|
-
|
|
586
|
-
|
|
587
|
-
|
|
588
|
-
|
|
589
|
-
|
|
612
|
+
Et as AddAccountModal,
|
|
613
|
+
Sa as BottomActions,
|
|
614
|
+
Oa as ExportCsvAction,
|
|
615
|
+
Ia as TRANSACTION_EVENTS,
|
|
616
|
+
xa as TopActions,
|
|
617
|
+
Ta as TransactionApi,
|
|
618
|
+
Ue as TransactionDetails,
|
|
619
|
+
Ge as TransactionList,
|
|
620
|
+
wa as TransactionRow,
|
|
621
|
+
Na as TransactionStore,
|
|
622
|
+
Dt as TransactionTable,
|
|
623
|
+
Ca as TransactionWidget,
|
|
624
|
+
ze as exportTransactionsToCSV,
|
|
625
|
+
B as useTransactionsUiStore
|
|
590
626
|
};
|