@tesouro/embedded-components-react 0.5.51 → 0.5.52
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/index.d.ts +42 -1
- package/dist/lib/CounterpartsWidget.d.ts +41 -0
- package/dist/lib/ReceivablesWidget.d.ts +40 -1
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index15.js +6 -9
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index25.js +9 -12
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index46.js +1 -2
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index.js +8 -8
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index101.js +18 -4
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index102.js +91 -88
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index104.js +18 -3
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index106.js +113 -102
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index28.js +5 -1
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index30.js +28 -20
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index31.js +148 -147
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index33.js +15 -3
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index34.js +39 -34
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index39.js +16 -4
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index40.js +203 -174
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index42.js +15 -3
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index43.js +52 -52
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index45.js +22 -3
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index46.js +2 -17
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index48.js +31 -31
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index50.js +97 -96
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index55.js +15 -3
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index56.js +57 -61
- package/dist/libs/tesouro-embedded-components-react/counterparts-widget/ui/dist/index4.js +189 -188
- package/dist/libs/tesouro-embedded-components-react/shared/counterpart-management/ui/dist/index10.js +1 -0
- package/dist/libs/tesouro-embedded-components-react/shared/counterpart-management/ui/dist/index12.js +1 -0
- package/dist/libs/tesouro-embedded-components-react/shared/counterpart-management/ui/dist/index13.js +54 -37
- package/dist/libs/tesouro-embedded-components-react/shared/counterpart-management/ui/dist/index2.js +23 -16
- package/dist/libs/tesouro-embedded-components-react/shared/counterpart-management/ui/dist/index3.js +1 -0
- package/dist/libs/tesouro-embedded-components-react/shared/counterpart-management/ui/dist/index5.js +54 -41
- package/dist/libs/tesouro-embedded-components-react/shared/counterpart-management/ui/dist/index6.js +88 -70
- package/dist/libs/tesouro-embedded-components-react/shared/counterpart-management/ui/dist/index9.js +333 -282
- package/dist/libs/tesouro-embedded-components-react/shared/feature/dist/lib/analytics/build-info.js +1 -1
- package/dist/packages/shared-ui-shadcn/dist/index.js +3757 -3705
- package/package.json +1 -1
|
@@ -1,334 +1,363 @@
|
|
|
1
|
-
import { Button as e,
|
|
2
|
-
import {
|
|
3
|
-
import { useId as
|
|
4
|
-
import { jsx as
|
|
5
|
-
import { CircleAlert as
|
|
1
|
+
import { Button as e, FieldRequirement as t, Input as n, InputGroup as r, InputGroupAddon as i, InputGroupInput as a, Label as o, Select as s, SelectContent as c, SelectItem as l, SelectTrigger as u, SelectValue as d, Tooltip as f, TooltipContent as p, TooltipProvider as m, TooltipTrigger as h, Typography as g, cn as _ } from "../../../../../packages/shared-ui-shadcn/dist/index.js";
|
|
2
|
+
import { mergeLineItemsSectionLabels as v } from "./index39.js";
|
|
3
|
+
import { useId as y } from "react";
|
|
4
|
+
import { jsx as b, jsxs as x } from "react/jsx-runtime";
|
|
5
|
+
import { CircleAlert as S, Minus as C, Plus as w, Trash2 as T, X as E } from "lucide-react";
|
|
6
6
|
//#region ../../libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index40.js
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
7
|
+
var D = {
|
|
8
|
+
description: t.Required,
|
|
9
|
+
glCode: t.Optional,
|
|
10
|
+
quantity: t.Required,
|
|
11
|
+
price: t.Required,
|
|
12
|
+
amount: t.Required
|
|
13
|
+
}, O = {
|
|
14
|
+
discount: t.Optional,
|
|
15
|
+
tax: t.Optional,
|
|
16
|
+
total: t.Required
|
|
17
|
+
};
|
|
18
|
+
function k({ items: t, glCodeOptions: k, glCodeDisabled: A, glCodeUnavailableMessage: j, discount: M, onDiscountChange: N, tax: P, onTaxChange: F, total: I, onTotalChange: L, onAddLineItem: R, errors: z, totalsErrors: B, disabled: V, testId: H, labels: U }) {
|
|
19
|
+
let W = v(U), G = y(), K = t.length > 1, q = j ? `${G}-gl-code-unavailable` : void 0, J = (e) => `${G}-${e}-error`, Y = (e) => {
|
|
20
|
+
let t = B?.[e];
|
|
21
|
+
return t ? /* @__PURE__ */ b("p", {
|
|
22
|
+
id: J(e),
|
|
15
23
|
className: "ttw:text-sm ttw:text-destructive ttw:text-right",
|
|
16
24
|
children: t
|
|
17
25
|
}) : null;
|
|
18
26
|
};
|
|
19
|
-
return /* @__PURE__ */
|
|
27
|
+
return /* @__PURE__ */ x("section", {
|
|
20
28
|
className: "ttw:flex ttw:flex-col ttw:gap-3",
|
|
21
|
-
"data-testid":
|
|
29
|
+
"data-testid": H,
|
|
22
30
|
children: [
|
|
23
|
-
/* @__PURE__ */
|
|
31
|
+
/* @__PURE__ */ b(g, {
|
|
24
32
|
component: "h2",
|
|
25
33
|
variant: "h6",
|
|
26
34
|
className: "ttw:font-semibold",
|
|
27
|
-
children:
|
|
35
|
+
children: W.heading
|
|
28
36
|
}),
|
|
29
|
-
/* @__PURE__ */
|
|
37
|
+
/* @__PURE__ */ b("p", {
|
|
30
38
|
className: "ttw:text-sm ttw:text-muted-foreground",
|
|
31
|
-
children:
|
|
39
|
+
children: W.helpText
|
|
32
40
|
}),
|
|
33
|
-
|
|
34
|
-
id:
|
|
41
|
+
j ? /* @__PURE__ */ b("span", {
|
|
42
|
+
id: q,
|
|
35
43
|
className: "ttw:sr-only",
|
|
36
|
-
children:
|
|
44
|
+
children: j
|
|
37
45
|
}) : null,
|
|
38
|
-
|
|
39
|
-
let v = `${
|
|
40
|
-
let t =
|
|
41
|
-
return t ? /* @__PURE__ */
|
|
42
|
-
id:
|
|
46
|
+
t.map((t, g) => {
|
|
47
|
+
let v = `${G}-${t.id}`, y = z?.[t.id], O = (e) => `${v}-${e}-error`, M = (e) => y?.[e], N = (e) => {
|
|
48
|
+
let t = M(e);
|
|
49
|
+
return t ? /* @__PURE__ */ b("p", {
|
|
50
|
+
id: O(e),
|
|
43
51
|
className: "ttw:text-sm ttw:text-destructive",
|
|
44
52
|
children: t
|
|
45
53
|
}) : null;
|
|
46
54
|
};
|
|
47
|
-
return /* @__PURE__ */
|
|
55
|
+
return /* @__PURE__ */ b("div", {
|
|
48
56
|
className: "ttw:rounded-lg ttw:border ttw:border-border ttw:bg-muted/30 ttw:p-4",
|
|
49
|
-
children: /* @__PURE__ */
|
|
57
|
+
children: /* @__PURE__ */ x("div", {
|
|
50
58
|
className: "ttw:@container/line-item ttw:flex ttw:flex-col ttw:gap-3",
|
|
51
59
|
children: [
|
|
52
|
-
/* @__PURE__ */
|
|
60
|
+
/* @__PURE__ */ x("div", {
|
|
53
61
|
className: "ttw:flex ttw:items-center ttw:justify-between ttw:gap-2",
|
|
54
|
-
children: [/* @__PURE__ */
|
|
62
|
+
children: [/* @__PURE__ */ x("div", {
|
|
55
63
|
className: "ttw:flex ttw:items-center ttw:gap-2",
|
|
56
|
-
children: [
|
|
64
|
+
children: [K ? /* @__PURE__ */ x("span", {
|
|
57
65
|
className: "ttw:text-sm ttw:text-muted-foreground",
|
|
58
|
-
children: [
|
|
59
|
-
}) : null, /* @__PURE__ */
|
|
66
|
+
children: [g + 1, "."]
|
|
67
|
+
}) : null, /* @__PURE__ */ b(o, {
|
|
60
68
|
htmlFor: `${v}-description`,
|
|
61
|
-
|
|
69
|
+
requirement: D.description,
|
|
70
|
+
labels: W.fieldMarkers,
|
|
71
|
+
children: W.description
|
|
62
72
|
})]
|
|
63
|
-
}),
|
|
73
|
+
}), K ? /* @__PURE__ */ b(e, {
|
|
64
74
|
type: "button",
|
|
65
75
|
variant: "ghost",
|
|
66
76
|
size: "icon",
|
|
67
|
-
disabled:
|
|
68
|
-
"aria-label":
|
|
69
|
-
onClick:
|
|
70
|
-
children: /* @__PURE__ */
|
|
77
|
+
disabled: V,
|
|
78
|
+
"aria-label": W.removeLineItem(g + 1),
|
|
79
|
+
onClick: t.onRemove,
|
|
80
|
+
children: /* @__PURE__ */ b(T, { className: "ttw:size-4" })
|
|
71
81
|
}) : null]
|
|
72
82
|
}),
|
|
73
|
-
/* @__PURE__ */
|
|
83
|
+
/* @__PURE__ */ x("div", {
|
|
74
84
|
className: "ttw:flex ttw:flex-col ttw:gap-1.5",
|
|
75
|
-
children: [/* @__PURE__ */
|
|
85
|
+
children: [/* @__PURE__ */ b(n, {
|
|
76
86
|
id: `${v}-description`,
|
|
77
|
-
placeholder:
|
|
78
|
-
value:
|
|
79
|
-
disabled:
|
|
80
|
-
"aria-
|
|
81
|
-
"aria-
|
|
82
|
-
|
|
83
|
-
|
|
87
|
+
placeholder: W.descriptionPlaceholder,
|
|
88
|
+
value: t.description,
|
|
89
|
+
disabled: V,
|
|
90
|
+
"aria-required": !0,
|
|
91
|
+
"aria-invalid": M("description") ? !0 : void 0,
|
|
92
|
+
"aria-describedby": M("description") ? O("description") : void 0,
|
|
93
|
+
onChange: (e) => t.onChange({ description: e.target.value })
|
|
94
|
+
}), N("description")]
|
|
84
95
|
}),
|
|
85
|
-
/* @__PURE__ */
|
|
96
|
+
/* @__PURE__ */ x("div", {
|
|
86
97
|
className: "ttw:grid ttw:grid-cols-1 ttw:@sm/line-item:grid-cols-3 ttw:@4xl/line-item:grid-cols-12 ttw:gap-3",
|
|
87
98
|
children: [
|
|
88
|
-
/* @__PURE__ */
|
|
99
|
+
/* @__PURE__ */ x("div", {
|
|
89
100
|
className: "ttw:col-span-1 ttw:@sm/line-item:col-span-3 ttw:@4xl/line-item:col-span-5 ttw:flex ttw:flex-col ttw:gap-1.5",
|
|
90
101
|
children: [
|
|
91
|
-
/* @__PURE__ */
|
|
102
|
+
/* @__PURE__ */ x("div", {
|
|
92
103
|
className: "ttw:flex ttw:items-center ttw:gap-1",
|
|
93
|
-
children: [/* @__PURE__ */
|
|
104
|
+
children: [/* @__PURE__ */ b(o, {
|
|
94
105
|
htmlFor: `${v}-gl-code`,
|
|
95
|
-
|
|
96
|
-
|
|
106
|
+
requirement: D.glCode,
|
|
107
|
+
labels: W.fieldMarkers,
|
|
108
|
+
children: W.glCode
|
|
109
|
+
}), j ? /* @__PURE__ */ b(m, { children: /* @__PURE__ */ x(f, { children: [/* @__PURE__ */ b(h, {
|
|
97
110
|
type: "button",
|
|
98
111
|
className: "ttw:inline-flex ttw:shrink-0 ttw:cursor-help ttw:text-muted-foreground",
|
|
99
|
-
"aria-label":
|
|
100
|
-
children: /* @__PURE__ */
|
|
101
|
-
}), /* @__PURE__ */
|
|
112
|
+
"aria-label": j,
|
|
113
|
+
children: /* @__PURE__ */ b(S, { className: "ttw:size-3.5" })
|
|
114
|
+
}), /* @__PURE__ */ b(p, { children: j })] }) }) : null]
|
|
102
115
|
}),
|
|
103
|
-
/* @__PURE__ */
|
|
116
|
+
/* @__PURE__ */ x("div", {
|
|
104
117
|
className: "ttw:relative",
|
|
105
|
-
children: [/* @__PURE__ */
|
|
106
|
-
value:
|
|
107
|
-
disabled:
|
|
108
|
-
onValueChange: (e) =>
|
|
109
|
-
children: [/* @__PURE__ */
|
|
118
|
+
children: [/* @__PURE__ */ x(s, {
|
|
119
|
+
value: t.glCode,
|
|
120
|
+
disabled: V || A,
|
|
121
|
+
onValueChange: (e) => t.onChange({ glCode: e }),
|
|
122
|
+
children: [/* @__PURE__ */ b(u, {
|
|
110
123
|
id: `${v}-gl-code`,
|
|
111
|
-
className:
|
|
112
|
-
"aria-invalid":
|
|
113
|
-
"aria-describedby": [
|
|
114
|
-
children: /* @__PURE__ */
|
|
115
|
-
}), /* @__PURE__ */
|
|
124
|
+
className: _("ttw:w-full", t.glCode && "ttw:[&>svg:last-child]:hidden!"),
|
|
125
|
+
"aria-invalid": M("glCode") ? !0 : void 0,
|
|
126
|
+
"aria-describedby": [M("glCode") ? O("glCode") : null, q].filter(Boolean).join(" ") || void 0,
|
|
127
|
+
children: /* @__PURE__ */ b(d, { placeholder: W.glCodePlaceholder })
|
|
128
|
+
}), /* @__PURE__ */ b(c, { children: k.map((e) => /* @__PURE__ */ b(l, {
|
|
116
129
|
value: e.value,
|
|
117
130
|
children: e.label
|
|
118
131
|
}, e.value)) })]
|
|
119
|
-
}),
|
|
132
|
+
}), t.glCode && !(V || A) ? /* @__PURE__ */ b(e, {
|
|
120
133
|
type: "button",
|
|
121
134
|
variant: "ghost",
|
|
122
135
|
size: "icon-sm",
|
|
123
|
-
"aria-label":
|
|
136
|
+
"aria-label": W.glCodeClear,
|
|
124
137
|
className: "ttw:absolute ttw:top-1/2 ttw:right-1 ttw:-translate-y-1/2",
|
|
125
138
|
onPointerDown: (e) => {
|
|
126
139
|
e.preventDefault(), e.stopPropagation();
|
|
127
140
|
},
|
|
128
141
|
onClick: (e) => {
|
|
129
|
-
e.preventDefault(), e.stopPropagation(),
|
|
142
|
+
e.preventDefault(), e.stopPropagation(), t.onChange({ glCode: "" });
|
|
130
143
|
},
|
|
131
|
-
children: /* @__PURE__ */
|
|
144
|
+
children: /* @__PURE__ */ b(E, {
|
|
132
145
|
className: "ttw:size-4",
|
|
133
146
|
"aria-hidden": !0
|
|
134
147
|
})
|
|
135
148
|
}) : null]
|
|
136
149
|
}),
|
|
137
|
-
|
|
150
|
+
N("glCode")
|
|
138
151
|
]
|
|
139
152
|
}),
|
|
140
|
-
/* @__PURE__ */
|
|
153
|
+
/* @__PURE__ */ x("div", {
|
|
141
154
|
className: "ttw:col-span-1 ttw:@4xl/line-item:col-span-3 ttw:flex ttw:flex-col ttw:gap-1.5",
|
|
142
155
|
children: [
|
|
143
|
-
/* @__PURE__ */
|
|
156
|
+
/* @__PURE__ */ b(o, {
|
|
144
157
|
htmlFor: `${v}-quantity`,
|
|
145
|
-
|
|
158
|
+
requirement: D.quantity,
|
|
159
|
+
labels: W.fieldMarkers,
|
|
160
|
+
children: W.quantity
|
|
146
161
|
}),
|
|
147
|
-
/* @__PURE__ */
|
|
162
|
+
/* @__PURE__ */ x(r, {
|
|
148
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",
|
|
149
164
|
children: [
|
|
150
|
-
/* @__PURE__ */
|
|
165
|
+
/* @__PURE__ */ b(e, {
|
|
151
166
|
type: "button",
|
|
152
167
|
variant: "ghost",
|
|
153
168
|
size: "icon",
|
|
154
169
|
className: "ttw:h-full ttw:shrink-0 ttw:rounded-r-none",
|
|
155
|
-
disabled:
|
|
156
|
-
"aria-label":
|
|
157
|
-
onClick: () =>
|
|
158
|
-
children: /* @__PURE__ */
|
|
170
|
+
disabled: V,
|
|
171
|
+
"aria-label": W.decreaseQuantity(g + 1),
|
|
172
|
+
onClick: () => t.onQuantityStep(-1),
|
|
173
|
+
children: /* @__PURE__ */ b(C, { className: "ttw:size-3.5" })
|
|
159
174
|
}),
|
|
160
|
-
/* @__PURE__ */
|
|
175
|
+
/* @__PURE__ */ b(a, {
|
|
161
176
|
id: `${v}-quantity`,
|
|
162
177
|
inputMode: "decimal",
|
|
163
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",
|
|
164
|
-
value:
|
|
165
|
-
disabled:
|
|
166
|
-
"aria-
|
|
167
|
-
"aria-
|
|
168
|
-
|
|
179
|
+
value: t.quantity,
|
|
180
|
+
disabled: V,
|
|
181
|
+
"aria-required": !0,
|
|
182
|
+
"aria-invalid": M("quantity") ? !0 : void 0,
|
|
183
|
+
"aria-describedby": M("quantity") ? O("quantity") : void 0,
|
|
184
|
+
onChange: (e) => t.onChange({ quantity: e.target.value })
|
|
169
185
|
}),
|
|
170
|
-
/* @__PURE__ */
|
|
186
|
+
/* @__PURE__ */ b(e, {
|
|
171
187
|
type: "button",
|
|
172
188
|
variant: "ghost",
|
|
173
189
|
size: "icon",
|
|
174
190
|
className: "ttw:h-full ttw:shrink-0 ttw:rounded-l-none",
|
|
175
|
-
disabled:
|
|
176
|
-
"aria-label":
|
|
177
|
-
onClick: () =>
|
|
178
|
-
children: /* @__PURE__ */
|
|
191
|
+
disabled: V,
|
|
192
|
+
"aria-label": W.increaseQuantity(g + 1),
|
|
193
|
+
onClick: () => t.onQuantityStep(1),
|
|
194
|
+
children: /* @__PURE__ */ b(w, { className: "ttw:size-3.5" })
|
|
179
195
|
})
|
|
180
196
|
]
|
|
181
197
|
}),
|
|
182
|
-
|
|
198
|
+
N("quantity")
|
|
183
199
|
]
|
|
184
200
|
}),
|
|
185
|
-
/* @__PURE__ */
|
|
201
|
+
/* @__PURE__ */ x("div", {
|
|
186
202
|
className: "ttw:col-span-1 ttw:@4xl/line-item:col-span-2 ttw:flex ttw:flex-col ttw:gap-1.5",
|
|
187
203
|
children: [
|
|
188
|
-
/* @__PURE__ */
|
|
204
|
+
/* @__PURE__ */ b(o, {
|
|
189
205
|
htmlFor: `${v}-price`,
|
|
190
|
-
|
|
206
|
+
requirement: D.price,
|
|
207
|
+
labels: W.fieldMarkers,
|
|
208
|
+
children: W.price
|
|
191
209
|
}),
|
|
192
|
-
/* @__PURE__ */
|
|
210
|
+
/* @__PURE__ */ x(r, { children: [/* @__PURE__ */ b(i, {
|
|
193
211
|
align: "inline-start",
|
|
194
212
|
"aria-hidden": !0,
|
|
195
|
-
children:
|
|
196
|
-
}), /* @__PURE__ */
|
|
213
|
+
children: W.currencySymbol
|
|
214
|
+
}), /* @__PURE__ */ b(a, {
|
|
197
215
|
id: `${v}-price`,
|
|
198
216
|
"data-has-start-addon": !0,
|
|
199
217
|
inputMode: "decimal",
|
|
200
218
|
className: "ttw:text-right ttw:aria-invalid:border-destructive ttw:aria-invalid:ring-destructive/20",
|
|
201
|
-
value:
|
|
202
|
-
disabled:
|
|
203
|
-
"aria-
|
|
204
|
-
"aria-
|
|
205
|
-
|
|
219
|
+
value: t.price,
|
|
220
|
+
disabled: V,
|
|
221
|
+
"aria-required": !0,
|
|
222
|
+
"aria-invalid": M("price") ? !0 : void 0,
|
|
223
|
+
"aria-describedby": M("price") ? O("price") : void 0,
|
|
224
|
+
onChange: (e) => t.onChange({ price: e.target.value })
|
|
206
225
|
})] }),
|
|
207
|
-
|
|
226
|
+
N("price")
|
|
208
227
|
]
|
|
209
228
|
}),
|
|
210
|
-
/* @__PURE__ */
|
|
229
|
+
/* @__PURE__ */ x("div", {
|
|
211
230
|
className: "ttw:col-span-1 ttw:@4xl/line-item:col-span-2 ttw:flex ttw:flex-col ttw:gap-1.5",
|
|
212
231
|
children: [
|
|
213
|
-
/* @__PURE__ */
|
|
232
|
+
/* @__PURE__ */ b(o, {
|
|
214
233
|
htmlFor: `${v}-amount`,
|
|
215
|
-
|
|
234
|
+
requirement: D.amount,
|
|
235
|
+
labels: W.fieldMarkers,
|
|
236
|
+
children: W.amount
|
|
216
237
|
}),
|
|
217
|
-
/* @__PURE__ */
|
|
238
|
+
/* @__PURE__ */ x(r, { children: [/* @__PURE__ */ b(i, {
|
|
218
239
|
align: "inline-start",
|
|
219
240
|
"aria-hidden": !0,
|
|
220
|
-
children:
|
|
221
|
-
}), /* @__PURE__ */
|
|
241
|
+
children: W.currencySymbol
|
|
242
|
+
}), /* @__PURE__ */ b(a, {
|
|
222
243
|
id: `${v}-amount`,
|
|
223
244
|
"data-has-start-addon": !0,
|
|
224
245
|
inputMode: "decimal",
|
|
225
246
|
className: "ttw:text-right ttw:aria-invalid:border-destructive ttw:aria-invalid:ring-destructive/20",
|
|
226
|
-
value:
|
|
227
|
-
disabled:
|
|
228
|
-
"aria-
|
|
229
|
-
"aria-
|
|
230
|
-
|
|
247
|
+
value: t.amount,
|
|
248
|
+
disabled: V,
|
|
249
|
+
"aria-required": !0,
|
|
250
|
+
"aria-invalid": M("amount") ? !0 : void 0,
|
|
251
|
+
"aria-describedby": M("amount") ? O("amount") : void 0,
|
|
252
|
+
onChange: (e) => t.onChange({ amount: e.target.value })
|
|
231
253
|
})] }),
|
|
232
|
-
|
|
254
|
+
N("amount")
|
|
233
255
|
]
|
|
234
256
|
})
|
|
235
257
|
]
|
|
236
258
|
})
|
|
237
259
|
]
|
|
238
260
|
})
|
|
239
|
-
},
|
|
261
|
+
}, t.id);
|
|
240
262
|
}),
|
|
241
|
-
/* @__PURE__ */
|
|
263
|
+
/* @__PURE__ */ b(e, {
|
|
242
264
|
type: "button",
|
|
243
265
|
variant: "link",
|
|
244
|
-
disabled:
|
|
266
|
+
disabled: V,
|
|
245
267
|
className: "ttw:self-start",
|
|
246
|
-
onClick:
|
|
247
|
-
children:
|
|
268
|
+
onClick: R,
|
|
269
|
+
children: W.addLineItem
|
|
248
270
|
}),
|
|
249
|
-
/* @__PURE__ */
|
|
271
|
+
/* @__PURE__ */ x("div", {
|
|
250
272
|
className: "ttw:flex ttw:flex-col ttw:gap-2 ttw:border-t ttw:border-border ttw:pt-3",
|
|
251
273
|
children: [
|
|
252
|
-
/* @__PURE__ */
|
|
274
|
+
/* @__PURE__ */ x("div", {
|
|
253
275
|
className: "ttw:flex ttw:items-start ttw:justify-between ttw:gap-4",
|
|
254
|
-
children: [/* @__PURE__ */
|
|
255
|
-
htmlFor: `${
|
|
256
|
-
|
|
257
|
-
|
|
276
|
+
children: [/* @__PURE__ */ b(o, {
|
|
277
|
+
htmlFor: `${G}-discount`,
|
|
278
|
+
requirement: O.discount,
|
|
279
|
+
labels: W.fieldMarkers,
|
|
280
|
+
children: W.discount
|
|
281
|
+
}), /* @__PURE__ */ x("div", {
|
|
258
282
|
className: "ttw:flex ttw:flex-col ttw:items-end ttw:gap-1.5",
|
|
259
|
-
children: [/* @__PURE__ */
|
|
283
|
+
children: [/* @__PURE__ */ x(r, {
|
|
260
284
|
className: "ttw:w-36",
|
|
261
|
-
children: [/* @__PURE__ */
|
|
285
|
+
children: [/* @__PURE__ */ b(i, {
|
|
262
286
|
align: "inline-start",
|
|
263
287
|
"aria-hidden": !0,
|
|
264
|
-
children:
|
|
265
|
-
}), /* @__PURE__ */
|
|
266
|
-
id: `${
|
|
288
|
+
children: W.currencySymbol
|
|
289
|
+
}), /* @__PURE__ */ b(a, {
|
|
290
|
+
id: `${G}-discount`,
|
|
267
291
|
"data-has-start-addon": !0,
|
|
268
292
|
inputMode: "decimal",
|
|
269
293
|
className: "ttw:text-right ttw:aria-invalid:border-destructive ttw:aria-invalid:ring-destructive/20",
|
|
270
|
-
value:
|
|
271
|
-
disabled:
|
|
272
|
-
"aria-invalid":
|
|
273
|
-
"aria-describedby":
|
|
274
|
-
onChange: (e) =>
|
|
294
|
+
value: M,
|
|
295
|
+
disabled: V,
|
|
296
|
+
"aria-invalid": B?.discount ? !0 : void 0,
|
|
297
|
+
"aria-describedby": B?.discount ? J("discount") : void 0,
|
|
298
|
+
onChange: (e) => N(e.target.value)
|
|
275
299
|
})]
|
|
276
|
-
}),
|
|
300
|
+
}), Y("discount")]
|
|
277
301
|
})]
|
|
278
302
|
}),
|
|
279
|
-
/* @__PURE__ */
|
|
303
|
+
/* @__PURE__ */ x("div", {
|
|
280
304
|
className: "ttw:flex ttw:items-start ttw:justify-between ttw:gap-4",
|
|
281
|
-
children: [/* @__PURE__ */
|
|
282
|
-
htmlFor: `${
|
|
283
|
-
|
|
284
|
-
|
|
305
|
+
children: [/* @__PURE__ */ b(o, {
|
|
306
|
+
htmlFor: `${G}-tax`,
|
|
307
|
+
requirement: O.tax,
|
|
308
|
+
labels: W.fieldMarkers,
|
|
309
|
+
children: W.tax
|
|
310
|
+
}), /* @__PURE__ */ x("div", {
|
|
285
311
|
className: "ttw:flex ttw:flex-col ttw:items-end ttw:gap-1.5",
|
|
286
|
-
children: [/* @__PURE__ */
|
|
312
|
+
children: [/* @__PURE__ */ x(r, {
|
|
287
313
|
className: "ttw:w-36",
|
|
288
|
-
children: [/* @__PURE__ */
|
|
314
|
+
children: [/* @__PURE__ */ b(i, {
|
|
289
315
|
align: "inline-start",
|
|
290
316
|
"aria-hidden": !0,
|
|
291
|
-
children:
|
|
292
|
-
}), /* @__PURE__ */
|
|
293
|
-
id: `${
|
|
317
|
+
children: W.currencySymbol
|
|
318
|
+
}), /* @__PURE__ */ b(a, {
|
|
319
|
+
id: `${G}-tax`,
|
|
294
320
|
"data-has-start-addon": !0,
|
|
295
321
|
inputMode: "decimal",
|
|
296
322
|
className: "ttw:text-right ttw:aria-invalid:border-destructive ttw:aria-invalid:ring-destructive/20",
|
|
297
|
-
value:
|
|
298
|
-
disabled:
|
|
299
|
-
"aria-invalid":
|
|
300
|
-
"aria-describedby":
|
|
301
|
-
onChange: (e) =>
|
|
323
|
+
value: P,
|
|
324
|
+
disabled: V,
|
|
325
|
+
"aria-invalid": B?.tax ? !0 : void 0,
|
|
326
|
+
"aria-describedby": B?.tax ? J("tax") : void 0,
|
|
327
|
+
onChange: (e) => F(e.target.value)
|
|
302
328
|
})]
|
|
303
|
-
}),
|
|
329
|
+
}), Y("tax")]
|
|
304
330
|
})]
|
|
305
331
|
}),
|
|
306
|
-
/* @__PURE__ */
|
|
332
|
+
/* @__PURE__ */ x("div", {
|
|
307
333
|
className: "ttw:flex ttw:items-start ttw:justify-between ttw:gap-4",
|
|
308
|
-
children: [/* @__PURE__ */
|
|
309
|
-
htmlFor: `${
|
|
334
|
+
children: [/* @__PURE__ */ b(o, {
|
|
335
|
+
htmlFor: `${G}-total`,
|
|
310
336
|
className: "ttw:font-semibold",
|
|
311
|
-
|
|
312
|
-
|
|
337
|
+
requirement: O.total,
|
|
338
|
+
labels: W.fieldMarkers,
|
|
339
|
+
children: W.totalAmount
|
|
340
|
+
}), /* @__PURE__ */ x("div", {
|
|
313
341
|
className: "ttw:flex ttw:flex-col ttw:items-end ttw:gap-1.5",
|
|
314
|
-
children: [/* @__PURE__ */
|
|
342
|
+
children: [/* @__PURE__ */ x(r, {
|
|
315
343
|
className: "ttw:w-36",
|
|
316
|
-
children: [/* @__PURE__ */
|
|
344
|
+
children: [/* @__PURE__ */ b(i, {
|
|
317
345
|
align: "inline-start",
|
|
318
346
|
"aria-hidden": !0,
|
|
319
|
-
children:
|
|
320
|
-
}), /* @__PURE__ */
|
|
321
|
-
id: `${
|
|
347
|
+
children: W.currencySymbol
|
|
348
|
+
}), /* @__PURE__ */ b(a, {
|
|
349
|
+
id: `${G}-total`,
|
|
322
350
|
"data-has-start-addon": !0,
|
|
323
351
|
inputMode: "decimal",
|
|
324
352
|
className: "ttw:text-right ttw:font-semibold ttw:aria-invalid:border-destructive ttw:aria-invalid:ring-destructive/20",
|
|
325
|
-
value:
|
|
326
|
-
disabled:
|
|
327
|
-
"aria-
|
|
328
|
-
"aria-
|
|
329
|
-
|
|
353
|
+
value: I,
|
|
354
|
+
disabled: V,
|
|
355
|
+
"aria-required": !0,
|
|
356
|
+
"aria-invalid": B?.total ? !0 : void 0,
|
|
357
|
+
"aria-describedby": B?.total ? J("total") : void 0,
|
|
358
|
+
onChange: (e) => L(e.target.value)
|
|
330
359
|
})]
|
|
331
|
-
}),
|
|
360
|
+
}), Y("total")]
|
|
332
361
|
})]
|
|
333
362
|
})
|
|
334
363
|
]
|
|
@@ -337,4 +366,4 @@ function E({ items: E, glCodeOptions: D, glCodeDisabled: O, glCodeUnavailableMes
|
|
|
337
366
|
});
|
|
338
367
|
}
|
|
339
368
|
//#endregion
|
|
340
|
-
export {
|
|
369
|
+
export { k as LineItemsSection, k as default };
|
|
@@ -1,11 +1,23 @@
|
|
|
1
|
+
import { LABEL_LABELS_EN as e } from "../../../../../packages/shared-ui-shadcn/dist/index.js";
|
|
1
2
|
//#region ../../libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index42.js
|
|
2
|
-
var
|
|
3
|
+
var t = {
|
|
3
4
|
fieldLabel: "Select or add vendor",
|
|
4
5
|
triggerPlaceholder: "Select vendor",
|
|
5
6
|
placeholder: "Search",
|
|
6
7
|
loading: "Searching vendors...",
|
|
7
8
|
emptyResults: "No vendors found",
|
|
8
|
-
addVendorAction: "Add vendor"
|
|
9
|
+
addVendorAction: "Add vendor",
|
|
10
|
+
fieldMarkers: e
|
|
9
11
|
};
|
|
12
|
+
function n(e) {
|
|
13
|
+
return {
|
|
14
|
+
...t,
|
|
15
|
+
...e,
|
|
16
|
+
fieldMarkers: {
|
|
17
|
+
...t.fieldMarkers,
|
|
18
|
+
...e?.fieldMarkers
|
|
19
|
+
}
|
|
20
|
+
};
|
|
21
|
+
}
|
|
10
22
|
//#endregion
|
|
11
|
-
export {
|
|
23
|
+
export { t as VENDOR_SEARCH_COMBOBOX_LABELS_EN, n as mergeVendorSearchComboboxLabels };
|