@tesouro/embedded-components-react 0.5.62 → 0.5.63
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/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index42.js +1 -1
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index55.js +24 -21
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index58.js +1 -2
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index59.js +143 -131
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index61.js +3 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index40.js +81 -76
- package/dist/libs/tesouro-embedded-components-react/shared/feature/dist/lib/analytics/build-info.js +1 -1
- package/package.json +1 -1
|
@@ -6,7 +6,7 @@ import { resolveLineItemAmountMinorUnits as a } from "./index40.js";
|
|
|
6
6
|
import { resolveLineItemQuantity as o } from "./index41.js";
|
|
7
7
|
//#region ../../libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index42.js
|
|
8
8
|
function s(e) {
|
|
9
|
-
return
|
|
9
|
+
return e.total_amount ?? e.amount_due ?? void 0;
|
|
10
10
|
}
|
|
11
11
|
function c(e) {
|
|
12
12
|
return typeof e == "string" ? e : "";
|
|
@@ -22,30 +22,33 @@ function o(e) {
|
|
|
22
22
|
return Number.isFinite(t) ? t : 0;
|
|
23
23
|
}
|
|
24
24
|
function s(e) {
|
|
25
|
+
let t = n(e);
|
|
26
|
+
return t === null ? e : c(t);
|
|
27
|
+
}
|
|
28
|
+
function c(e) {
|
|
25
29
|
return (e / 100).toFixed(2);
|
|
26
30
|
}
|
|
27
|
-
function
|
|
31
|
+
function l({ values: e, initialLineItems: r, counterpartId: i, clearCounterpart: a, counterpartBankAccountId: o, editedTotals: s, currentTotals: c, lineItems: l, document: f, includeBlankPoNumber: p = !0 }) {
|
|
28
32
|
let m = { currency: t };
|
|
29
33
|
i ? m.counterpart_id = i : a && (m.counterpart_id = null), i ? m.counterpart_bank_account_id = o ?? null : a && (m.counterpart_bank_account_id = null), e.invoiceNumber && (m.document_id = e.invoiceNumber), e.invoiceDate && (m.issued_at = e.invoiceDate), e.dueDate && (m.due_date = e.dueDate);
|
|
30
34
|
let h = e.poNumber.trim();
|
|
31
|
-
if ((h || p) && (m.purchase_order_number = h || null), f && (m.base64_encoded_file = f.base64EncodedFile, m.file_name = f.fileName), s) {
|
|
32
|
-
let e = n(
|
|
33
|
-
m.discount = e, m.tax_amount = n(s.tax) ?? 0, s.total !== void 0 && (m.total_amount = (n(s.total) ?? 0) + e);
|
|
34
|
-
}
|
|
35
|
-
if (c && d) {
|
|
36
|
-
let e = u(d), t = n(c.tax) ?? 0, r = n(c.discount) ?? 0, i = c.total === void 0 ? (e ?? 0) + t : (n(c.total) ?? 0) + r;
|
|
35
|
+
if ((h || p) && (m.purchase_order_number = h || null), f && (m.base64_encoded_file = f.base64EncodedFile, m.file_name = f.fileName), s && (m.discount = n(s.discount) ?? 0, m.tax_amount = n(s.tax) ?? 0, s.total !== void 0 && (m.total_amount = n(s.total) ?? 0)), c && l) {
|
|
36
|
+
let e = d(l), t = n(c.tax) ?? 0, r = n(c.discount) ?? 0, i = c.total === void 0 ? (e ?? 0) - r + t : n(c.total) ?? 0;
|
|
37
37
|
e !== void 0 && (m.subtotal = e), m.discount = r, m.tax_amount = t, m.total_amount = i;
|
|
38
38
|
} else if (r && !("total_amount" in m)) {
|
|
39
|
-
let e =
|
|
39
|
+
let e = u(r, {
|
|
40
|
+
tax: s?.tax,
|
|
41
|
+
discount: s?.discount
|
|
42
|
+
});
|
|
40
43
|
e !== void 0 && (m.total_amount = e);
|
|
41
44
|
}
|
|
42
45
|
return m;
|
|
43
46
|
}
|
|
44
|
-
function
|
|
45
|
-
let
|
|
46
|
-
if (
|
|
47
|
+
function u(e, { tax: t, discount: r }) {
|
|
48
|
+
let i = d(e);
|
|
49
|
+
if (i !== void 0) return i + (t ? n(t) ?? 0 : 0) - (r ? n(r) ?? 0 : 0);
|
|
47
50
|
}
|
|
48
|
-
function
|
|
51
|
+
function d(e) {
|
|
49
52
|
let t = !1, r = e.reduce((e, r) => {
|
|
50
53
|
if (!i(r)) return e;
|
|
51
54
|
let a = n(r.amount);
|
|
@@ -53,14 +56,14 @@ function u(e) {
|
|
|
53
56
|
}, 0);
|
|
54
57
|
if (t) return r;
|
|
55
58
|
}
|
|
56
|
-
function
|
|
57
|
-
let r =
|
|
59
|
+
function f({ lineItems: e, editedTotals: t }) {
|
|
60
|
+
let r = d(e), i = n(t.tax) ?? 0, a = n(t.discount) ?? 0, o = {
|
|
58
61
|
discount: a,
|
|
59
62
|
tax_amount: i
|
|
60
63
|
};
|
|
61
|
-
return r !== void 0 && (o.subtotal = r), t.total === void 0 ? r !== void 0 && (o.total_amount = r + i) : o.total_amount =
|
|
64
|
+
return r !== void 0 && (o.subtotal = r), t.total === void 0 ? r !== void 0 && (o.total_amount = r - a + i) : o.total_amount = n(t.total) ?? 0, o;
|
|
62
65
|
}
|
|
63
|
-
function
|
|
66
|
+
function p(e) {
|
|
64
67
|
return e.filter(i).map((e) => {
|
|
65
68
|
let t = n(e.amount), i = r(e.quantity) ?? 1, a = n(e.price) ?? (t === null ? 0 : Math.round(t / i)), o = Math.round(i * a), s = t ?? o;
|
|
66
69
|
return {
|
|
@@ -75,11 +78,11 @@ function f(e) {
|
|
|
75
78
|
};
|
|
76
79
|
});
|
|
77
80
|
}
|
|
78
|
-
function
|
|
79
|
-
return
|
|
81
|
+
function m(e, t) {
|
|
82
|
+
return c(Math.round(o(e) * a(t)));
|
|
80
83
|
}
|
|
81
|
-
function
|
|
82
|
-
return
|
|
84
|
+
function h(e, t, n) {
|
|
85
|
+
return c(e.reduce((e, t) => e + a(t.amount), 0) + a(t) - a(n));
|
|
83
86
|
}
|
|
84
87
|
//#endregion
|
|
85
|
-
export {
|
|
88
|
+
export { h as calculateTotal, m as displayLineAmount, i as isPersistableLineItem, l as mapBillFormToPayload, p as mapLineItemsToPayload, f as mapPayableAmountFieldsToPayload, s as normalizeMoneyOnBlur, n as parseMoneyToMinorUnits, r as parseQuantity };
|
|
@@ -18,8 +18,7 @@ function i(e) {
|
|
|
18
18
|
return typeof e == "string" ? e : "";
|
|
19
19
|
}
|
|
20
20
|
function a(e) {
|
|
21
|
-
|
|
22
|
-
if (typeof e.total_amount == "number") return e.total_amount - (e.discount ?? 0);
|
|
21
|
+
return e.total_amount ?? e.amount_due ?? void 0;
|
|
23
22
|
}
|
|
24
23
|
function o({ payable: o, lineItems: s }) {
|
|
25
24
|
let c = {
|
|
@@ -3,90 +3,90 @@
|
|
|
3
3
|
"use client";
|
|
4
4
|
"use client";
|
|
5
5
|
import { BILL_CREATE_MESSAGE_LABELS_EN as e } from "./index49.js";
|
|
6
|
-
import { calculateTotal as t, displayLineAmount as n,
|
|
7
|
-
import { validateBillTotals as
|
|
8
|
-
import { emptyLineItem as
|
|
9
|
-
import { useCallback as
|
|
6
|
+
import { calculateTotal as t, displayLineAmount as n, normalizeMoneyOnBlur as r, parseMoneyToMinorUnits as i, parseQuantity as a } from "./index55.js";
|
|
7
|
+
import { validateBillTotals as o } from "./index56.js";
|
|
8
|
+
import { emptyLineItem as s, mapPayableToBillForm as c } from "./index58.js";
|
|
9
|
+
import { useCallback as l, useEffect as u, useMemo as d, useRef as f, useState as p } from "react";
|
|
10
10
|
//#region ../../libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index59.js
|
|
11
|
-
var
|
|
12
|
-
function
|
|
11
|
+
var m = /^[0-9.,-]+$/;
|
|
12
|
+
function h(e) {
|
|
13
13
|
let t = e.trim().replace(/^\$\s*/, "");
|
|
14
|
-
return t ?
|
|
14
|
+
return t ? m.test(t) ? t : null : "";
|
|
15
15
|
}
|
|
16
|
-
var
|
|
16
|
+
var g = [
|
|
17
17
|
"quantity",
|
|
18
18
|
"price",
|
|
19
19
|
"amount"
|
|
20
20
|
];
|
|
21
|
-
function
|
|
21
|
+
function _(e) {
|
|
22
22
|
let t = e.trim(), n = /[.,]$/.test(t) ? t.slice(0, -1) : t;
|
|
23
23
|
return t && !n ? null : n;
|
|
24
24
|
}
|
|
25
|
-
function
|
|
25
|
+
function v(e, t, n) {
|
|
26
26
|
if (t === void 0) return;
|
|
27
|
-
let r =
|
|
28
|
-
if (r !== null) return
|
|
27
|
+
let r = _(t);
|
|
28
|
+
if (r !== null) return o(e === "discount" ? r : "", e === "tax" ? r : "", e === "total" ? r : void 0, n)?.[e];
|
|
29
29
|
}
|
|
30
|
-
function
|
|
31
|
-
let n = {},
|
|
30
|
+
function y(e, t) {
|
|
31
|
+
let n = {}, r = {
|
|
32
32
|
price: null,
|
|
33
33
|
amount: null
|
|
34
34
|
};
|
|
35
|
-
for (let
|
|
36
|
-
let o =
|
|
37
|
-
o !== null && (a
|
|
35
|
+
for (let a of ["price", "amount"]) {
|
|
36
|
+
let o = _(e[a]);
|
|
37
|
+
o !== null && (r[a] = i(o), o && r[a] === null && (n[a] = t.unreadableMoney));
|
|
38
38
|
}
|
|
39
|
-
let o =
|
|
39
|
+
let o = _(e.quantity);
|
|
40
40
|
if (o !== null) {
|
|
41
|
-
let e =
|
|
42
|
-
|
|
41
|
+
let e = r.price !== null || r.amount !== null;
|
|
42
|
+
a(o) === null && (o || e) && (n.quantity = t.unusableQuantity);
|
|
43
43
|
}
|
|
44
44
|
return n;
|
|
45
45
|
}
|
|
46
|
-
function
|
|
47
|
-
return
|
|
46
|
+
function b(e, t, r) {
|
|
47
|
+
return i(t) === null ? r : n(e, t);
|
|
48
48
|
}
|
|
49
|
-
function
|
|
50
|
-
let
|
|
49
|
+
function x({ payable: n, lineItems: i, labels: a = e } = {}) {
|
|
50
|
+
let o = d(() => c({
|
|
51
51
|
payable: n ?? {},
|
|
52
|
-
lineItems:
|
|
53
|
-
}), [n,
|
|
54
|
-
|
|
52
|
+
lineItems: i ?? []
|
|
53
|
+
}), [n, i]), [m, _] = p(o.values), [x, S] = p(o.lineItems), [C, w] = p(o.discount), [T, E] = p(o.tax), [D, O] = p(o.total || void 0), [ee, k] = p(), A = f(void 0), te = l((e) => {
|
|
54
|
+
k((t) => {
|
|
55
55
|
let n = typeof e == "function" ? e(t) : e;
|
|
56
|
-
return n?.form !==
|
|
56
|
+
return n?.form !== A.current && (A.current = void 0), n;
|
|
57
57
|
});
|
|
58
|
-
}, []),
|
|
59
|
-
|
|
58
|
+
}, []), ne = l((e) => {
|
|
59
|
+
A.current = e, k((t) => ({
|
|
60
60
|
...t,
|
|
61
61
|
form: e
|
|
62
62
|
}));
|
|
63
|
-
}, []), j =
|
|
64
|
-
|
|
65
|
-
if (!e?.form || e.form !==
|
|
66
|
-
|
|
63
|
+
}, []), j = l(() => {
|
|
64
|
+
k((e) => {
|
|
65
|
+
if (!e?.form || e.form !== A.current) return e;
|
|
66
|
+
A.current = void 0;
|
|
67
67
|
let t = { ...e };
|
|
68
68
|
return delete t.form, Object.keys(t).length ? t : void 0;
|
|
69
69
|
});
|
|
70
|
-
}, []), [
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
}, [
|
|
74
|
-
|
|
75
|
-
}, [
|
|
76
|
-
|
|
77
|
-
}, [
|
|
78
|
-
let
|
|
79
|
-
|
|
70
|
+
}, []), [re, M] = p(), [N, P] = p(), [F, I] = p(!1), [L, R] = p(!1), [z, B] = p(!1);
|
|
71
|
+
u(() => {
|
|
72
|
+
F || _(o.values);
|
|
73
|
+
}, [o]), u(() => {
|
|
74
|
+
L || S(o.lineItems);
|
|
75
|
+
}, [o]), u(() => {
|
|
76
|
+
z || (w(o.discount), E(o.tax), O(o.total || void 0));
|
|
77
|
+
}, [o]);
|
|
78
|
+
let ie = l((e) => {
|
|
79
|
+
_((t) => ({
|
|
80
80
|
...t,
|
|
81
81
|
...e
|
|
82
|
-
})),
|
|
82
|
+
})), I(!0), k((t) => {
|
|
83
83
|
if (!t) return t;
|
|
84
84
|
let n = { ...t };
|
|
85
85
|
for (let t of Object.keys(e)) delete n[t];
|
|
86
86
|
return Object.keys(n).length ? n : void 0;
|
|
87
87
|
}), j();
|
|
88
|
-
}, [j]),
|
|
89
|
-
|
|
88
|
+
}, [j]), V = l((e, t) => {
|
|
89
|
+
M((n) => {
|
|
90
90
|
if (!n?.[e] && !t) return n;
|
|
91
91
|
let r = {
|
|
92
92
|
...n,
|
|
@@ -94,13 +94,13 @@ function y({ payable: n, lineItems: r, labels: i = e } = {}) {
|
|
|
94
94
|
};
|
|
95
95
|
return t || delete r[e], Object.keys(r).length ? r : void 0;
|
|
96
96
|
});
|
|
97
|
-
}, []),
|
|
98
|
-
|
|
99
|
-
}, [
|
|
100
|
-
|
|
101
|
-
}, [
|
|
102
|
-
let n =
|
|
103
|
-
|
|
97
|
+
}, []), H = l((e, t) => {
|
|
98
|
+
V(e, v(e, t, a));
|
|
99
|
+
}, [a, V]), U = l(() => {
|
|
100
|
+
O(void 0), H("total", void 0), j();
|
|
101
|
+
}, [H, j]), W = l((e, t = []) => {
|
|
102
|
+
let n = y(e, a);
|
|
103
|
+
P((r) => {
|
|
104
104
|
let i = r?.[e.id], a = { ...i };
|
|
105
105
|
for (let e of [
|
|
106
106
|
"price",
|
|
@@ -113,130 +113,142 @@ function y({ payable: n, lineItems: r, labels: i = e } = {}) {
|
|
|
113
113
|
let s = { ...r };
|
|
114
114
|
return o ? s[e.id] = a : delete s[e.id], Object.keys(s).length ? s : void 0;
|
|
115
115
|
});
|
|
116
|
-
}, [
|
|
117
|
-
|
|
116
|
+
}, [a]), G = l((e, t, n) => {
|
|
117
|
+
P((r) => ({
|
|
118
118
|
...r,
|
|
119
119
|
[e]: {
|
|
120
120
|
...r?.[e],
|
|
121
121
|
[t]: n
|
|
122
122
|
}
|
|
123
123
|
}));
|
|
124
|
-
}, []),
|
|
125
|
-
let r =
|
|
124
|
+
}, []), K = l((e, t, n = []) => {
|
|
125
|
+
let r = x.find((t) => t.id === e);
|
|
126
126
|
if (!r) return;
|
|
127
127
|
let i = t(r);
|
|
128
|
-
|
|
128
|
+
S(x.map((t) => t.id === e ? i : t)), W(i, n), R(!0), U();
|
|
129
129
|
}, [
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
]),
|
|
130
|
+
U,
|
|
131
|
+
x,
|
|
132
|
+
W
|
|
133
|
+
]), q = l((e, t) => {
|
|
134
134
|
let n = { ...t };
|
|
135
|
-
for (let r of
|
|
136
|
-
let
|
|
137
|
-
if (
|
|
138
|
-
let o =
|
|
135
|
+
for (let r of g) {
|
|
136
|
+
let i = t[r];
|
|
137
|
+
if (i === void 0) continue;
|
|
138
|
+
let o = h(i);
|
|
139
139
|
if (o === null) {
|
|
140
|
-
|
|
140
|
+
G(e, r, a.numbersOnly);
|
|
141
141
|
return;
|
|
142
142
|
}
|
|
143
143
|
n[r] = o;
|
|
144
144
|
}
|
|
145
|
-
|
|
145
|
+
K(e, (e) => {
|
|
146
146
|
let t = {
|
|
147
147
|
...e,
|
|
148
148
|
...n
|
|
149
149
|
};
|
|
150
150
|
return "amount" in n ? t : {
|
|
151
151
|
...t,
|
|
152
|
-
amount:
|
|
152
|
+
amount: b(t.quantity, t.price, t.amount)
|
|
153
153
|
};
|
|
154
154
|
}, Object.keys(n));
|
|
155
155
|
}, [
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
]),
|
|
160
|
-
|
|
156
|
+
K,
|
|
157
|
+
a,
|
|
158
|
+
G
|
|
159
|
+
]), J = l((e, t) => {
|
|
160
|
+
S((n) => n.map((n) => n.id === e ? {
|
|
161
|
+
...n,
|
|
162
|
+
[t]: r(n[t])
|
|
163
|
+
} : n));
|
|
164
|
+
}, []), Y = l((e, t) => {
|
|
165
|
+
K(e, (e) => {
|
|
161
166
|
let n = Number.parseFloat(e.quantity), r = String(Math.max(1, (Number.isFinite(n) ? n : 0) + t));
|
|
162
167
|
return {
|
|
163
168
|
...e,
|
|
164
169
|
quantity: r,
|
|
165
|
-
amount:
|
|
170
|
+
amount: b(r, e.price, e.amount)
|
|
166
171
|
};
|
|
167
172
|
});
|
|
168
|
-
}, [
|
|
169
|
-
|
|
173
|
+
}, [K]), X = l((e) => {
|
|
174
|
+
P((t) => {
|
|
170
175
|
if (!t?.[e]) return t;
|
|
171
176
|
let n = { ...t };
|
|
172
177
|
return delete n[e], Object.keys(n).length ? n : void 0;
|
|
173
178
|
});
|
|
174
|
-
}, []),
|
|
175
|
-
|
|
176
|
-
}, [
|
|
177
|
-
|
|
178
|
-
}, [
|
|
179
|
-
let r =
|
|
179
|
+
}, []), Z = l((e) => {
|
|
180
|
+
X(e), S((t) => t.length <= 1 ? t : t.filter((t) => t.id !== e)), R(!0), U();
|
|
181
|
+
}, [X, U]), ae = l(() => {
|
|
182
|
+
S((e) => [...e, s()]), R(!0), U();
|
|
183
|
+
}, [U]), Q = l((e, t, n) => {
|
|
184
|
+
let r = h(t);
|
|
180
185
|
if (r === null) {
|
|
181
|
-
|
|
186
|
+
V(e, a.numbersOnly);
|
|
182
187
|
return;
|
|
183
188
|
}
|
|
184
|
-
n(r),
|
|
189
|
+
n(r), B(!0), U(), H(e, r);
|
|
185
190
|
}, [
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
]),
|
|
191
|
-
let t =
|
|
191
|
+
U,
|
|
192
|
+
a,
|
|
193
|
+
H,
|
|
194
|
+
V
|
|
195
|
+
]), oe = l((e) => Q("discount", e, w), [Q]), se = l((e) => Q("tax", e, E), [Q]), $ = l(() => w((e) => r(e)), []), ce = l(() => E((e) => r(e)), []), le = l((e) => {
|
|
196
|
+
let t = h(e);
|
|
192
197
|
if (t === null) {
|
|
193
|
-
|
|
198
|
+
V("total", a.numbersOnly);
|
|
194
199
|
return;
|
|
195
200
|
}
|
|
196
|
-
|
|
201
|
+
O(t), B(!0), H("total", t), j();
|
|
197
202
|
}, [
|
|
198
203
|
j,
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
]),
|
|
204
|
+
a,
|
|
205
|
+
H,
|
|
206
|
+
V
|
|
207
|
+
]), ue = l(() => {
|
|
208
|
+
O((e) => e === void 0 ? e : r(e));
|
|
209
|
+
}, []), de = d(() => x.map((e) => ({
|
|
203
210
|
...e,
|
|
204
|
-
onChange: (t) =>
|
|
205
|
-
|
|
206
|
-
|
|
211
|
+
onChange: (t) => q(e.id, t),
|
|
212
|
+
onBlur: (t) => J(e.id, t),
|
|
213
|
+
onQuantityStep: (t) => Y(e.id, t),
|
|
214
|
+
onRemove: () => Z(e.id)
|
|
207
215
|
})), [
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
+
J,
|
|
217
|
+
x,
|
|
218
|
+
q,
|
|
219
|
+
Z,
|
|
220
|
+
Y
|
|
221
|
+
]), fe = d(() => t(x, T, C), [
|
|
222
|
+
x,
|
|
223
|
+
T,
|
|
224
|
+
C
|
|
216
225
|
]);
|
|
217
226
|
return {
|
|
218
|
-
values:
|
|
219
|
-
errors:
|
|
220
|
-
setErrors:
|
|
221
|
-
setSaveFailureMessage:
|
|
222
|
-
lineItemErrors:
|
|
223
|
-
setLineItemErrors:
|
|
224
|
-
totalsErrors:
|
|
225
|
-
setTotalsErrors:
|
|
226
|
-
onChange:
|
|
227
|
-
lineItems:
|
|
228
|
-
lineItemRows:
|
|
229
|
-
discount:
|
|
230
|
-
onDiscountChange:
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
227
|
+
values: m,
|
|
228
|
+
errors: ee,
|
|
229
|
+
setErrors: te,
|
|
230
|
+
setSaveFailureMessage: ne,
|
|
231
|
+
lineItemErrors: N,
|
|
232
|
+
setLineItemErrors: P,
|
|
233
|
+
totalsErrors: re,
|
|
234
|
+
setTotalsErrors: M,
|
|
235
|
+
onChange: ie,
|
|
236
|
+
lineItems: x,
|
|
237
|
+
lineItemRows: de,
|
|
238
|
+
discount: C,
|
|
239
|
+
onDiscountChange: oe,
|
|
240
|
+
onDiscountBlur: $,
|
|
241
|
+
tax: T,
|
|
242
|
+
onTaxChange: se,
|
|
243
|
+
onTaxBlur: ce,
|
|
244
|
+
total: D ?? fe,
|
|
245
|
+
totalOverride: D,
|
|
246
|
+
onTotalChange: le,
|
|
247
|
+
onTotalBlur: ue,
|
|
248
|
+
onAddLineItem: ae,
|
|
249
|
+
isTotalsDirty: z,
|
|
250
|
+
isDirty: F || L || z
|
|
239
251
|
};
|
|
240
252
|
}
|
|
241
253
|
//#endregion
|
|
242
|
-
export {
|
|
254
|
+
export { x as useBillForm };
|
|
@@ -437,10 +437,13 @@ function l({ open: l, onOpenChange: u, payableId: $e, readOnly: d = !1, copy: et
|
|
|
437
437
|
glCodeUnavailableMessage: J,
|
|
438
438
|
discount: D.discount,
|
|
439
439
|
onDiscountChange: D.onDiscountChange,
|
|
440
|
+
onDiscountBlur: D.onDiscountBlur,
|
|
440
441
|
tax: D.tax,
|
|
441
442
|
onTaxChange: D.onTaxChange,
|
|
443
|
+
onTaxBlur: D.onTaxBlur,
|
|
442
444
|
total: D.total,
|
|
443
445
|
onTotalChange: D.onTotalChange,
|
|
446
|
+
onTotalBlur: D.onTotalBlur,
|
|
444
447
|
onAddLineItem: D.onAddLineItem,
|
|
445
448
|
errors: D.lineItemErrors,
|
|
446
449
|
totalsErrors: D.totalsErrors,
|
|
@@ -15,36 +15,36 @@ var D = {
|
|
|
15
15
|
tax: t.Optional,
|
|
16
16
|
total: t.Required
|
|
17
17
|
};
|
|
18
|
-
function k({ items: t, glCodeOptions: k, glCodeDisabled: A, glCodeUnavailableMessage: j, discount: M, onDiscountChange: N,
|
|
19
|
-
let
|
|
20
|
-
let t =
|
|
18
|
+
function k({ items: t, glCodeOptions: k, glCodeDisabled: A, glCodeUnavailableMessage: j, discount: M, onDiscountChange: N, onDiscountBlur: P, tax: F, onTaxChange: I, onTaxBlur: L, total: R, onTotalChange: z, onTotalBlur: B, onAddLineItem: V, errors: H, totalsErrors: U, disabled: W, testId: G, labels: K }) {
|
|
19
|
+
let q = v(K), J = y(), Y = t.length > 1, X = j ? `${J}-gl-code-unavailable` : void 0, Z = (e) => `${J}-${e}-error`, Q = (e) => {
|
|
20
|
+
let t = U?.[e];
|
|
21
21
|
return t ? /* @__PURE__ */ b("p", {
|
|
22
|
-
id:
|
|
22
|
+
id: Z(e),
|
|
23
23
|
className: "ttw:text-sm ttw:text-destructive ttw:text-right",
|
|
24
24
|
children: t
|
|
25
25
|
}) : null;
|
|
26
26
|
};
|
|
27
27
|
return /* @__PURE__ */ x("section", {
|
|
28
28
|
className: "ttw:flex ttw:flex-col ttw:gap-3",
|
|
29
|
-
"data-testid":
|
|
29
|
+
"data-testid": G,
|
|
30
30
|
children: [
|
|
31
31
|
/* @__PURE__ */ b(g, {
|
|
32
32
|
component: "h2",
|
|
33
33
|
variant: "h6",
|
|
34
34
|
className: "ttw:font-semibold",
|
|
35
|
-
children:
|
|
35
|
+
children: q.heading
|
|
36
36
|
}),
|
|
37
37
|
/* @__PURE__ */ b("p", {
|
|
38
38
|
className: "ttw:text-sm ttw:text-muted-foreground",
|
|
39
|
-
children:
|
|
39
|
+
children: q.helpText
|
|
40
40
|
}),
|
|
41
41
|
j ? /* @__PURE__ */ b("span", {
|
|
42
|
-
id:
|
|
42
|
+
id: X,
|
|
43
43
|
className: "ttw:sr-only",
|
|
44
44
|
children: j
|
|
45
45
|
}) : null,
|
|
46
46
|
t.map((t, g) => {
|
|
47
|
-
let v = `${
|
|
47
|
+
let v = `${J}-${t.id}`, y = H?.[t.id], O = (e) => `${v}-${e}-error`, M = (e) => y?.[e], N = (e) => {
|
|
48
48
|
let t = M(e);
|
|
49
49
|
return t ? /* @__PURE__ */ b("p", {
|
|
50
50
|
id: O(e),
|
|
@@ -61,21 +61,21 @@ function k({ items: t, glCodeOptions: k, glCodeDisabled: A, glCodeUnavailableMes
|
|
|
61
61
|
className: "ttw:flex ttw:items-center ttw:justify-between ttw:gap-2",
|
|
62
62
|
children: [/* @__PURE__ */ x("div", {
|
|
63
63
|
className: "ttw:flex ttw:items-center ttw:gap-2",
|
|
64
|
-
children: [
|
|
64
|
+
children: [Y ? /* @__PURE__ */ x("span", {
|
|
65
65
|
className: "ttw:text-sm ttw:text-muted-foreground",
|
|
66
66
|
children: [g + 1, "."]
|
|
67
67
|
}) : null, /* @__PURE__ */ b(o, {
|
|
68
68
|
htmlFor: `${v}-description`,
|
|
69
69
|
requirement: D.description,
|
|
70
|
-
labels:
|
|
71
|
-
children:
|
|
70
|
+
labels: q.fieldMarkers,
|
|
71
|
+
children: q.description
|
|
72
72
|
})]
|
|
73
|
-
}),
|
|
73
|
+
}), Y ? /* @__PURE__ */ b(e, {
|
|
74
74
|
type: "button",
|
|
75
75
|
variant: "ghost",
|
|
76
76
|
size: "icon",
|
|
77
|
-
disabled:
|
|
78
|
-
"aria-label":
|
|
77
|
+
disabled: W,
|
|
78
|
+
"aria-label": q.removeLineItem(g + 1),
|
|
79
79
|
onClick: t.onRemove,
|
|
80
80
|
children: /* @__PURE__ */ b(T, { className: "ttw:size-4" })
|
|
81
81
|
}) : null]
|
|
@@ -84,9 +84,9 @@ function k({ items: t, glCodeOptions: k, glCodeDisabled: A, glCodeUnavailableMes
|
|
|
84
84
|
className: "ttw:flex ttw:flex-col ttw:gap-1.5",
|
|
85
85
|
children: [/* @__PURE__ */ b(n, {
|
|
86
86
|
id: `${v}-description`,
|
|
87
|
-
placeholder:
|
|
87
|
+
placeholder: q.descriptionPlaceholder,
|
|
88
88
|
value: t.description,
|
|
89
|
-
disabled:
|
|
89
|
+
disabled: W,
|
|
90
90
|
"aria-required": !0,
|
|
91
91
|
"aria-invalid": M("description") ? !0 : void 0,
|
|
92
92
|
"aria-describedby": M("description") ? O("description") : void 0,
|
|
@@ -104,8 +104,8 @@ function k({ items: t, glCodeOptions: k, glCodeDisabled: A, glCodeUnavailableMes
|
|
|
104
104
|
children: [/* @__PURE__ */ b(o, {
|
|
105
105
|
htmlFor: `${v}-gl-code`,
|
|
106
106
|
requirement: D.glCode,
|
|
107
|
-
labels:
|
|
108
|
-
children:
|
|
107
|
+
labels: q.fieldMarkers,
|
|
108
|
+
children: q.glCode
|
|
109
109
|
}), j ? /* @__PURE__ */ b(m, { children: /* @__PURE__ */ x(f, { children: [/* @__PURE__ */ b(h, {
|
|
110
110
|
type: "button",
|
|
111
111
|
className: "ttw:inline-flex ttw:shrink-0 ttw:cursor-help ttw:text-muted-foreground",
|
|
@@ -117,23 +117,23 @@ function k({ items: t, glCodeOptions: k, glCodeDisabled: A, glCodeUnavailableMes
|
|
|
117
117
|
className: "ttw:relative",
|
|
118
118
|
children: [/* @__PURE__ */ x(s, {
|
|
119
119
|
value: t.glCode,
|
|
120
|
-
disabled:
|
|
120
|
+
disabled: W || A,
|
|
121
121
|
onValueChange: (e) => t.onChange({ glCode: e }),
|
|
122
122
|
children: [/* @__PURE__ */ b(u, {
|
|
123
123
|
id: `${v}-gl-code`,
|
|
124
124
|
className: _("ttw:w-full", t.glCode && "ttw:[&>svg:last-child]:hidden!"),
|
|
125
125
|
"aria-invalid": M("glCode") ? !0 : void 0,
|
|
126
|
-
"aria-describedby": [M("glCode") ? O("glCode") : null,
|
|
127
|
-
children: /* @__PURE__ */ b(d, { placeholder:
|
|
126
|
+
"aria-describedby": [M("glCode") ? O("glCode") : null, X].filter(Boolean).join(" ") || void 0,
|
|
127
|
+
children: /* @__PURE__ */ b(d, { placeholder: q.glCodePlaceholder })
|
|
128
128
|
}), /* @__PURE__ */ b(c, { children: k.map((e) => /* @__PURE__ */ b(l, {
|
|
129
129
|
value: e.value,
|
|
130
130
|
children: e.label
|
|
131
131
|
}, e.value)) })]
|
|
132
|
-
}), t.glCode && !(
|
|
132
|
+
}), t.glCode && !(W || A) ? /* @__PURE__ */ b(e, {
|
|
133
133
|
type: "button",
|
|
134
134
|
variant: "ghost",
|
|
135
135
|
size: "icon-sm",
|
|
136
|
-
"aria-label":
|
|
136
|
+
"aria-label": q.glCodeClear,
|
|
137
137
|
className: "ttw:absolute ttw:top-1/2 ttw:right-1 ttw:-translate-y-1/2",
|
|
138
138
|
onPointerDown: (e) => {
|
|
139
139
|
e.preventDefault(), e.stopPropagation();
|
|
@@ -156,8 +156,8 @@ function k({ items: t, glCodeOptions: k, glCodeDisabled: A, glCodeUnavailableMes
|
|
|
156
156
|
/* @__PURE__ */ b(o, {
|
|
157
157
|
htmlFor: `${v}-quantity`,
|
|
158
158
|
requirement: D.quantity,
|
|
159
|
-
labels:
|
|
160
|
-
children:
|
|
159
|
+
labels: q.fieldMarkers,
|
|
160
|
+
children: q.quantity
|
|
161
161
|
}),
|
|
162
162
|
/* @__PURE__ */ x(r, {
|
|
163
163
|
className: "ttw:h-9 ttw:rounded-md ttw:border ttw:border-input ttw:shadow-xs ttw:has-[:focus-visible]:border-ring ttw:has-[:focus-visible]:ring-[3px] ttw:has-[:focus-visible]:ring-ring/50 ttw:has-[[aria-invalid=true]]:border-destructive ttw:has-[[aria-invalid=true]]:ring-destructive/20",
|
|
@@ -167,8 +167,8 @@ function k({ items: t, glCodeOptions: k, glCodeDisabled: A, glCodeUnavailableMes
|
|
|
167
167
|
variant: "ghost",
|
|
168
168
|
size: "icon",
|
|
169
169
|
className: "ttw:h-full ttw:shrink-0 ttw:rounded-r-none",
|
|
170
|
-
disabled:
|
|
171
|
-
"aria-label":
|
|
170
|
+
disabled: W,
|
|
171
|
+
"aria-label": q.decreaseQuantity(g + 1),
|
|
172
172
|
onClick: () => t.onQuantityStep(-1),
|
|
173
173
|
children: /* @__PURE__ */ b(C, { className: "ttw:size-3.5" })
|
|
174
174
|
}),
|
|
@@ -177,7 +177,7 @@ function k({ items: t, glCodeOptions: k, glCodeDisabled: A, glCodeUnavailableMes
|
|
|
177
177
|
inputMode: "decimal",
|
|
178
178
|
className: "ttw:min-w-0 ttw:flex-1 ttw:rounded-none ttw:border-0 ttw:text-center ttw:shadow-none ttw:focus-visible:ring-0",
|
|
179
179
|
value: t.quantity,
|
|
180
|
-
disabled:
|
|
180
|
+
disabled: W,
|
|
181
181
|
"aria-required": !0,
|
|
182
182
|
"aria-invalid": M("quantity") ? !0 : void 0,
|
|
183
183
|
"aria-describedby": M("quantity") ? O("quantity") : void 0,
|
|
@@ -188,8 +188,8 @@ function k({ items: t, glCodeOptions: k, glCodeDisabled: A, glCodeUnavailableMes
|
|
|
188
188
|
variant: "ghost",
|
|
189
189
|
size: "icon",
|
|
190
190
|
className: "ttw:h-full ttw:shrink-0 ttw:rounded-l-none",
|
|
191
|
-
disabled:
|
|
192
|
-
"aria-label":
|
|
191
|
+
disabled: W,
|
|
192
|
+
"aria-label": q.increaseQuantity(g + 1),
|
|
193
193
|
onClick: () => t.onQuantityStep(1),
|
|
194
194
|
children: /* @__PURE__ */ b(w, { className: "ttw:size-3.5" })
|
|
195
195
|
})
|
|
@@ -204,24 +204,25 @@ function k({ items: t, glCodeOptions: k, glCodeDisabled: A, glCodeUnavailableMes
|
|
|
204
204
|
/* @__PURE__ */ b(o, {
|
|
205
205
|
htmlFor: `${v}-price`,
|
|
206
206
|
requirement: D.price,
|
|
207
|
-
labels:
|
|
208
|
-
children:
|
|
207
|
+
labels: q.fieldMarkers,
|
|
208
|
+
children: q.price
|
|
209
209
|
}),
|
|
210
210
|
/* @__PURE__ */ x(r, { children: [/* @__PURE__ */ b(i, {
|
|
211
211
|
align: "inline-start",
|
|
212
212
|
"aria-hidden": !0,
|
|
213
|
-
children:
|
|
213
|
+
children: q.currencySymbol
|
|
214
214
|
}), /* @__PURE__ */ b(a, {
|
|
215
215
|
id: `${v}-price`,
|
|
216
216
|
"data-has-start-addon": !0,
|
|
217
217
|
inputMode: "decimal",
|
|
218
218
|
className: "ttw:text-right ttw:aria-invalid:border-destructive ttw:aria-invalid:ring-destructive/20",
|
|
219
219
|
value: t.price,
|
|
220
|
-
disabled:
|
|
220
|
+
disabled: W,
|
|
221
221
|
"aria-required": !0,
|
|
222
222
|
"aria-invalid": M("price") ? !0 : void 0,
|
|
223
223
|
"aria-describedby": M("price") ? O("price") : void 0,
|
|
224
|
-
onChange: (e) => t.onChange({ price: e.target.value })
|
|
224
|
+
onChange: (e) => t.onChange({ price: e.target.value }),
|
|
225
|
+
onBlur: () => t.onBlur?.("price")
|
|
225
226
|
})] }),
|
|
226
227
|
N("price")
|
|
227
228
|
]
|
|
@@ -232,24 +233,25 @@ function k({ items: t, glCodeOptions: k, glCodeDisabled: A, glCodeUnavailableMes
|
|
|
232
233
|
/* @__PURE__ */ b(o, {
|
|
233
234
|
htmlFor: `${v}-amount`,
|
|
234
235
|
requirement: D.amount,
|
|
235
|
-
labels:
|
|
236
|
-
children:
|
|
236
|
+
labels: q.fieldMarkers,
|
|
237
|
+
children: q.amount
|
|
237
238
|
}),
|
|
238
239
|
/* @__PURE__ */ x(r, { children: [/* @__PURE__ */ b(i, {
|
|
239
240
|
align: "inline-start",
|
|
240
241
|
"aria-hidden": !0,
|
|
241
|
-
children:
|
|
242
|
+
children: q.currencySymbol
|
|
242
243
|
}), /* @__PURE__ */ b(a, {
|
|
243
244
|
id: `${v}-amount`,
|
|
244
245
|
"data-has-start-addon": !0,
|
|
245
246
|
inputMode: "decimal",
|
|
246
247
|
className: "ttw:text-right ttw:aria-invalid:border-destructive ttw:aria-invalid:ring-destructive/20",
|
|
247
248
|
value: t.amount,
|
|
248
|
-
disabled:
|
|
249
|
+
disabled: W,
|
|
249
250
|
"aria-required": !0,
|
|
250
251
|
"aria-invalid": M("amount") ? !0 : void 0,
|
|
251
252
|
"aria-describedby": M("amount") ? O("amount") : void 0,
|
|
252
|
-
onChange: (e) => t.onChange({ amount: e.target.value })
|
|
253
|
+
onChange: (e) => t.onChange({ amount: e.target.value }),
|
|
254
|
+
onBlur: () => t.onBlur?.("amount")
|
|
253
255
|
})] }),
|
|
254
256
|
N("amount")
|
|
255
257
|
]
|
|
@@ -263,10 +265,10 @@ function k({ items: t, glCodeOptions: k, glCodeDisabled: A, glCodeUnavailableMes
|
|
|
263
265
|
/* @__PURE__ */ b(e, {
|
|
264
266
|
type: "button",
|
|
265
267
|
variant: "link",
|
|
266
|
-
disabled:
|
|
268
|
+
disabled: W,
|
|
267
269
|
className: "ttw:self-start",
|
|
268
|
-
onClick:
|
|
269
|
-
children:
|
|
270
|
+
onClick: V,
|
|
271
|
+
children: q.addLineItem
|
|
270
272
|
}),
|
|
271
273
|
/* @__PURE__ */ x("div", {
|
|
272
274
|
className: "ttw:flex ttw:flex-col ttw:gap-2 ttw:border-t ttw:border-border ttw:pt-3",
|
|
@@ -274,10 +276,10 @@ function k({ items: t, glCodeOptions: k, glCodeDisabled: A, glCodeUnavailableMes
|
|
|
274
276
|
/* @__PURE__ */ x("div", {
|
|
275
277
|
className: "ttw:flex ttw:items-start ttw:justify-between ttw:gap-4",
|
|
276
278
|
children: [/* @__PURE__ */ b(o, {
|
|
277
|
-
htmlFor: `${
|
|
279
|
+
htmlFor: `${J}-discount`,
|
|
278
280
|
requirement: O.discount,
|
|
279
|
-
labels:
|
|
280
|
-
children:
|
|
281
|
+
labels: q.fieldMarkers,
|
|
282
|
+
children: q.discount
|
|
281
283
|
}), /* @__PURE__ */ x("div", {
|
|
282
284
|
className: "ttw:flex ttw:flex-col ttw:items-end ttw:gap-1.5",
|
|
283
285
|
children: [/* @__PURE__ */ x(r, {
|
|
@@ -285,28 +287,29 @@ function k({ items: t, glCodeOptions: k, glCodeDisabled: A, glCodeUnavailableMes
|
|
|
285
287
|
children: [/* @__PURE__ */ b(i, {
|
|
286
288
|
align: "inline-start",
|
|
287
289
|
"aria-hidden": !0,
|
|
288
|
-
children:
|
|
290
|
+
children: q.currencySymbol
|
|
289
291
|
}), /* @__PURE__ */ b(a, {
|
|
290
|
-
id: `${
|
|
292
|
+
id: `${J}-discount`,
|
|
291
293
|
"data-has-start-addon": !0,
|
|
292
294
|
inputMode: "decimal",
|
|
293
295
|
className: "ttw:text-right ttw:aria-invalid:border-destructive ttw:aria-invalid:ring-destructive/20",
|
|
294
296
|
value: M,
|
|
295
|
-
disabled:
|
|
296
|
-
"aria-invalid":
|
|
297
|
-
"aria-describedby":
|
|
298
|
-
onChange: (e) => N(e.target.value)
|
|
297
|
+
disabled: W,
|
|
298
|
+
"aria-invalid": U?.discount ? !0 : void 0,
|
|
299
|
+
"aria-describedby": U?.discount ? Z("discount") : void 0,
|
|
300
|
+
onChange: (e) => N(e.target.value),
|
|
301
|
+
onBlur: P
|
|
299
302
|
})]
|
|
300
|
-
}),
|
|
303
|
+
}), Q("discount")]
|
|
301
304
|
})]
|
|
302
305
|
}),
|
|
303
306
|
/* @__PURE__ */ x("div", {
|
|
304
307
|
className: "ttw:flex ttw:items-start ttw:justify-between ttw:gap-4",
|
|
305
308
|
children: [/* @__PURE__ */ b(o, {
|
|
306
|
-
htmlFor: `${
|
|
309
|
+
htmlFor: `${J}-tax`,
|
|
307
310
|
requirement: O.tax,
|
|
308
|
-
labels:
|
|
309
|
-
children:
|
|
311
|
+
labels: q.fieldMarkers,
|
|
312
|
+
children: q.tax
|
|
310
313
|
}), /* @__PURE__ */ x("div", {
|
|
311
314
|
className: "ttw:flex ttw:flex-col ttw:items-end ttw:gap-1.5",
|
|
312
315
|
children: [/* @__PURE__ */ x(r, {
|
|
@@ -314,29 +317,30 @@ function k({ items: t, glCodeOptions: k, glCodeDisabled: A, glCodeUnavailableMes
|
|
|
314
317
|
children: [/* @__PURE__ */ b(i, {
|
|
315
318
|
align: "inline-start",
|
|
316
319
|
"aria-hidden": !0,
|
|
317
|
-
children:
|
|
320
|
+
children: q.currencySymbol
|
|
318
321
|
}), /* @__PURE__ */ b(a, {
|
|
319
|
-
id: `${
|
|
322
|
+
id: `${J}-tax`,
|
|
320
323
|
"data-has-start-addon": !0,
|
|
321
324
|
inputMode: "decimal",
|
|
322
325
|
className: "ttw:text-right ttw:aria-invalid:border-destructive ttw:aria-invalid:ring-destructive/20",
|
|
323
|
-
value:
|
|
324
|
-
disabled:
|
|
325
|
-
"aria-invalid":
|
|
326
|
-
"aria-describedby":
|
|
327
|
-
onChange: (e) =>
|
|
326
|
+
value: F,
|
|
327
|
+
disabled: W,
|
|
328
|
+
"aria-invalid": U?.tax ? !0 : void 0,
|
|
329
|
+
"aria-describedby": U?.tax ? Z("tax") : void 0,
|
|
330
|
+
onChange: (e) => I(e.target.value),
|
|
331
|
+
onBlur: L
|
|
328
332
|
})]
|
|
329
|
-
}),
|
|
333
|
+
}), Q("tax")]
|
|
330
334
|
})]
|
|
331
335
|
}),
|
|
332
336
|
/* @__PURE__ */ x("div", {
|
|
333
337
|
className: "ttw:flex ttw:items-start ttw:justify-between ttw:gap-4",
|
|
334
338
|
children: [/* @__PURE__ */ b(o, {
|
|
335
|
-
htmlFor: `${
|
|
339
|
+
htmlFor: `${J}-total`,
|
|
336
340
|
className: "ttw:font-semibold",
|
|
337
341
|
requirement: O.total,
|
|
338
|
-
labels:
|
|
339
|
-
children:
|
|
342
|
+
labels: q.fieldMarkers,
|
|
343
|
+
children: q.totalAmount
|
|
340
344
|
}), /* @__PURE__ */ x("div", {
|
|
341
345
|
className: "ttw:flex ttw:flex-col ttw:items-end ttw:gap-1.5",
|
|
342
346
|
children: [/* @__PURE__ */ x(r, {
|
|
@@ -344,20 +348,21 @@ function k({ items: t, glCodeOptions: k, glCodeDisabled: A, glCodeUnavailableMes
|
|
|
344
348
|
children: [/* @__PURE__ */ b(i, {
|
|
345
349
|
align: "inline-start",
|
|
346
350
|
"aria-hidden": !0,
|
|
347
|
-
children:
|
|
351
|
+
children: q.currencySymbol
|
|
348
352
|
}), /* @__PURE__ */ b(a, {
|
|
349
|
-
id: `${
|
|
353
|
+
id: `${J}-total`,
|
|
350
354
|
"data-has-start-addon": !0,
|
|
351
355
|
inputMode: "decimal",
|
|
352
356
|
className: "ttw:text-right ttw:font-semibold ttw:aria-invalid:border-destructive ttw:aria-invalid:ring-destructive/20",
|
|
353
|
-
value:
|
|
354
|
-
disabled:
|
|
357
|
+
value: R,
|
|
358
|
+
disabled: W,
|
|
355
359
|
"aria-required": !0,
|
|
356
|
-
"aria-invalid":
|
|
357
|
-
"aria-describedby":
|
|
358
|
-
onChange: (e) =>
|
|
360
|
+
"aria-invalid": U?.total ? !0 : void 0,
|
|
361
|
+
"aria-describedby": U?.total ? Z("total") : void 0,
|
|
362
|
+
onChange: (e) => z(e.target.value),
|
|
363
|
+
onBlur: B
|
|
359
364
|
})]
|
|
360
|
-
}),
|
|
365
|
+
}), Q("total")]
|
|
361
366
|
})]
|
|
362
367
|
})
|
|
363
368
|
]
|
package/dist/libs/tesouro-embedded-components-react/shared/feature/dist/lib/analytics/build-info.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
//#region ../../libs/tesouro-embedded-components-react/shared/feature/dist/lib/analytics/build-info.js
|
|
2
|
-
var e = "@tesouro/embedded-components-react", t = "0.5.
|
|
2
|
+
var e = "@tesouro/embedded-components-react", t = "0.5.63", n = "34ab770a11f7fab14c9dfc21d23b7685134bb2b4", r = Object.freeze({
|
|
3
3
|
library_name: e,
|
|
4
4
|
library_version: t,
|
|
5
5
|
library_sha: n
|