@tesouro/embedded-components-react 0.2.318 → 0.2.320
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/README.md +5 -4
- package/dist/index.css +9 -0
- package/dist/index.d.ts +4 -1
- package/dist/index.js +1 -1
- package/dist/lib/BillPayWidget.d.ts +4 -1
- package/dist/lib/BillPayWidget.js +1 -1
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/data-access/dist/index.js +10 -7
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/data-access/dist/index10.js +170 -32
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/data-access/dist/index11.js +13 -32
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/data-access/dist/index12.js +30 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/data-access/dist/index13.js +50 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/data-access/dist/index14.js +36 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/data-access/dist/index3.js +11 -8
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/data-access/dist/index4.js +33 -16
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/data-access/dist/index5.js +47 -2
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/data-access/dist/index6.js +18 -63
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/data-access/dist/index7.js +40 -131
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/data-access/dist/index8.js +48 -11
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/data-access/dist/index9.js +30 -20
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index.js +18 -16
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index10.js +29 -97
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index11.js +1 -9
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index12.js +13 -109
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index13.js +24 -4
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index14.js +30 -21
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index15.js +19 -46
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index16.js +49 -76
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index17.js +4 -45
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index18.js +73 -3
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index19.js +50 -2
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index2.js +4 -50
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index20.js +7 -43
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index21.js +38 -1
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index22.js +115 -31
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index23.js +56 -8
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index24.js +206 -16
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index25.js +195 -5
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index26.js +58 -64
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index27.js +46 -139
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index28.js +34 -5
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index29.js +155 -6
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index3.js +3 -60
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index30.js +36 -7
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index31.js +92 -73
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index32.js +9 -3
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index33.js +191 -6
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index34.js +4 -114
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index35.js +26 -1
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index36.js +78 -21
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index37.js +92 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index38.js +3 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index39.js +4 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index4.js +5 -206
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index40.js +45 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index41.js +1 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index42.js +53 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index43.js +11 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index44.js +18 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index45.js +8 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index46.js +79 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index47.js +148 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index48.js +5 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index49.js +8 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index5.js +3 -197
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index50.js +9 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index51.js +85 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index52.js +3 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index53.js +8 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index54.js +115 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index55.js +1 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index56.js +25 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index6.js +30 -41
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index7.js +38 -30
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index8.js +20 -151
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index9.js +158 -31
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index.js +29 -17
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index12.js +13 -7
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index13.js +13 -47
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index14.js +24 -2
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index15.js +2 -22
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index16.js +31 -283
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index17.js +261 -1
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index18.js +2 -16
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index19.js +7 -118
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index20.js +49 -2
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index21.js +2 -10
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index22.js +20 -94
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index23.js +286 -2
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index24.js +1 -12
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index25.js +14 -56
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index26.js +120 -2
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index27.js +1 -19
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index28.js +8 -157
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index29.js +96 -2
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index30.js +2 -7
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index31.js +11 -42
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index32.js +57 -1
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index33.js +2 -14
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index34.js +50 -20
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index35.js +138 -1
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index36.js +1 -54
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index37.js +5 -227
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index38.js +37 -188
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index39.js +2 -10
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index40.js +55 -5
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index41.js +229 -84
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index42.js +195 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index43.js +10 -2
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index44.js +4 -3
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index45.js +88 -25
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index47.js +2 -14
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index48.js +5 -87
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index49.js +30 -2
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index50.js +2 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index51.js +7 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index52.js +34 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index53.js +2 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index54.js +12 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index55.js +106 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index56.js +2 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index57.js +18 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index58.js +10 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index59.js +170 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index60.js +2 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index61.js +14 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index62.js +89 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index63.js +2 -0
- package/dist/libs/tesouro-embedded-components-react/shared/data-access/dist/index.js +21 -21
- package/dist/libs/tesouro-embedded-components-react/shared/data-access/dist/lib/rest/@tanstack/react-query.gen.js +189 -156
- package/dist/libs/tesouro-embedded-components-react/shared/data-access/dist/lib/rest/sdk.gen.js +157 -97
- package/dist/libs/tesouro-embedded-components-react/shared/feature/dist/index.js +10 -10
- package/dist/libs/tesouro-embedded-components-react/shared/feature/dist/lib/analytics/build-info.js +1 -1
- package/dist/libs/tesouro-embedded-components-react/widget-suite/feature/dist/index7.js +1 -1
- package/package.json +1 -1
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index46.js +0 -2
|
@@ -1,2 +1,286 @@
|
|
|
1
|
-
import "
|
|
2
|
-
import "./index22.js";
|
|
1
|
+
import { Button as e, Input as t, InputGroup as n, InputGroupAddon as r, InputGroupInput as i, Label as a, Select as o, SelectContent as s, SelectItem as c, SelectTrigger as l, SelectValue as u, Typography as d } from "../../../../../packages/shared-ui-shadcn/dist/index.js";
|
|
2
|
+
import { LINE_ITEMS_SECTION_LABELS_EN as f } from "./index22.js";
|
|
3
|
+
import { useId as p } from "react";
|
|
4
|
+
import { jsx as m, jsxs as h } from "react/jsx-runtime";
|
|
5
|
+
import { Minus as g, Plus as _, Trash2 as v } from "lucide-react";
|
|
6
|
+
//#region ../../libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index23.js
|
|
7
|
+
function y({ items: y, glCodeOptions: b, discount: x, onDiscountChange: S, tax: C, onTaxChange: w, total: T, onTotalChange: E, onAddLineItem: D, errors: O, disabled: k, testId: A, labels: j }) {
|
|
8
|
+
let M = {
|
|
9
|
+
...f,
|
|
10
|
+
...j
|
|
11
|
+
}, N = p(), P = y.length > 1;
|
|
12
|
+
return /* @__PURE__ */ h("section", {
|
|
13
|
+
className: "ttw:flex ttw:flex-col ttw:gap-3",
|
|
14
|
+
"data-testid": A,
|
|
15
|
+
children: [
|
|
16
|
+
/* @__PURE__ */ m(d, {
|
|
17
|
+
component: "h2",
|
|
18
|
+
variant: "h6",
|
|
19
|
+
className: "ttw:font-semibold",
|
|
20
|
+
children: M.heading
|
|
21
|
+
}),
|
|
22
|
+
/* @__PURE__ */ m("p", {
|
|
23
|
+
className: "ttw:text-sm ttw:text-muted-foreground",
|
|
24
|
+
children: M.helpText
|
|
25
|
+
}),
|
|
26
|
+
y.map((d, f) => {
|
|
27
|
+
let p = `${N}-${d.id}`, y = O?.[d.id], x = (e) => `${p}-${e}-error`, S = (e) => y?.[e], C = (e) => {
|
|
28
|
+
let t = S(e);
|
|
29
|
+
return t ? /* @__PURE__ */ m("p", {
|
|
30
|
+
id: x(e),
|
|
31
|
+
className: "ttw:text-sm ttw:text-destructive",
|
|
32
|
+
children: t
|
|
33
|
+
}) : null;
|
|
34
|
+
};
|
|
35
|
+
return /* @__PURE__ */ m("div", {
|
|
36
|
+
className: "ttw:rounded-lg ttw:border ttw:border-border ttw:bg-muted/30 ttw:p-4",
|
|
37
|
+
children: /* @__PURE__ */ h("div", {
|
|
38
|
+
className: "ttw:@container/line-item ttw:flex ttw:flex-col ttw:gap-3",
|
|
39
|
+
children: [
|
|
40
|
+
/* @__PURE__ */ h("div", {
|
|
41
|
+
className: "ttw:flex ttw:items-center ttw:justify-between ttw:gap-2",
|
|
42
|
+
children: [/* @__PURE__ */ h("div", {
|
|
43
|
+
className: "ttw:flex ttw:items-center ttw:gap-2",
|
|
44
|
+
children: [P ? /* @__PURE__ */ h("span", {
|
|
45
|
+
className: "ttw:text-sm ttw:text-muted-foreground",
|
|
46
|
+
children: [f + 1, "."]
|
|
47
|
+
}) : null, /* @__PURE__ */ m(a, {
|
|
48
|
+
htmlFor: `${p}-description`,
|
|
49
|
+
children: M.description
|
|
50
|
+
})]
|
|
51
|
+
}), P ? /* @__PURE__ */ m(e, {
|
|
52
|
+
type: "button",
|
|
53
|
+
variant: "ghost",
|
|
54
|
+
size: "icon",
|
|
55
|
+
disabled: k,
|
|
56
|
+
"aria-label": M.removeLineItem(f + 1),
|
|
57
|
+
onClick: d.onRemove,
|
|
58
|
+
children: /* @__PURE__ */ m(v, { className: "ttw:size-4" })
|
|
59
|
+
}) : null]
|
|
60
|
+
}),
|
|
61
|
+
/* @__PURE__ */ h("div", {
|
|
62
|
+
className: "ttw:flex ttw:flex-col ttw:gap-1.5",
|
|
63
|
+
children: [/* @__PURE__ */ m(t, {
|
|
64
|
+
id: `${p}-description`,
|
|
65
|
+
placeholder: M.descriptionPlaceholder,
|
|
66
|
+
value: d.description,
|
|
67
|
+
disabled: k,
|
|
68
|
+
"aria-invalid": S("description") ? !0 : void 0,
|
|
69
|
+
"aria-describedby": S("description") ? x("description") : void 0,
|
|
70
|
+
onChange: (e) => d.onChange({ description: e.target.value })
|
|
71
|
+
}), C("description")]
|
|
72
|
+
}),
|
|
73
|
+
/* @__PURE__ */ h("div", {
|
|
74
|
+
className: "ttw:grid ttw:grid-cols-3 ttw:@lg/line-item:grid-cols-6 ttw:gap-3",
|
|
75
|
+
children: [
|
|
76
|
+
/* @__PURE__ */ h("div", {
|
|
77
|
+
className: "ttw:col-span-3 ttw:flex ttw:flex-col ttw:gap-1.5",
|
|
78
|
+
children: [
|
|
79
|
+
/* @__PURE__ */ m(a, {
|
|
80
|
+
htmlFor: `${p}-gl-code`,
|
|
81
|
+
children: M.glCode
|
|
82
|
+
}),
|
|
83
|
+
/* @__PURE__ */ h(o, {
|
|
84
|
+
value: d.glCode,
|
|
85
|
+
disabled: k,
|
|
86
|
+
onValueChange: (e) => d.onChange({ glCode: e }),
|
|
87
|
+
children: [/* @__PURE__ */ m(l, {
|
|
88
|
+
id: `${p}-gl-code`,
|
|
89
|
+
className: "ttw:w-full",
|
|
90
|
+
"aria-invalid": S("glCode") ? !0 : void 0,
|
|
91
|
+
"aria-describedby": S("glCode") ? x("glCode") : void 0,
|
|
92
|
+
children: /* @__PURE__ */ m(u, { placeholder: M.glCodePlaceholder })
|
|
93
|
+
}), /* @__PURE__ */ m(s, { children: b.map((e) => /* @__PURE__ */ m(c, {
|
|
94
|
+
value: e.value,
|
|
95
|
+
children: e.label
|
|
96
|
+
}, e.value)) })]
|
|
97
|
+
}),
|
|
98
|
+
C("glCode")
|
|
99
|
+
]
|
|
100
|
+
}),
|
|
101
|
+
/* @__PURE__ */ h("div", {
|
|
102
|
+
className: "ttw:col-span-1 ttw:flex ttw:flex-col ttw:gap-1.5",
|
|
103
|
+
children: [
|
|
104
|
+
/* @__PURE__ */ m(a, {
|
|
105
|
+
htmlFor: `${p}-quantity`,
|
|
106
|
+
children: M.quantity
|
|
107
|
+
}),
|
|
108
|
+
/* @__PURE__ */ h(n, {
|
|
109
|
+
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",
|
|
110
|
+
children: [
|
|
111
|
+
/* @__PURE__ */ m(e, {
|
|
112
|
+
type: "button",
|
|
113
|
+
variant: "ghost",
|
|
114
|
+
size: "icon",
|
|
115
|
+
className: "ttw:h-full ttw:shrink-0 ttw:rounded-r-none",
|
|
116
|
+
disabled: k,
|
|
117
|
+
"aria-label": M.decreaseQuantity(f + 1),
|
|
118
|
+
onClick: () => d.onQuantityStep(-1),
|
|
119
|
+
children: /* @__PURE__ */ m(g, { className: "ttw:size-3.5" })
|
|
120
|
+
}),
|
|
121
|
+
/* @__PURE__ */ m(i, {
|
|
122
|
+
id: `${p}-quantity`,
|
|
123
|
+
inputMode: "decimal",
|
|
124
|
+
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",
|
|
125
|
+
value: d.quantity,
|
|
126
|
+
disabled: k,
|
|
127
|
+
"aria-invalid": S("quantity") ? !0 : void 0,
|
|
128
|
+
"aria-describedby": S("quantity") ? x("quantity") : void 0,
|
|
129
|
+
onChange: (e) => d.onChange({ quantity: e.target.value })
|
|
130
|
+
}),
|
|
131
|
+
/* @__PURE__ */ m(e, {
|
|
132
|
+
type: "button",
|
|
133
|
+
variant: "ghost",
|
|
134
|
+
size: "icon",
|
|
135
|
+
className: "ttw:h-full ttw:shrink-0 ttw:rounded-l-none",
|
|
136
|
+
disabled: k,
|
|
137
|
+
"aria-label": M.increaseQuantity(f + 1),
|
|
138
|
+
onClick: () => d.onQuantityStep(1),
|
|
139
|
+
children: /* @__PURE__ */ m(_, { className: "ttw:size-3.5" })
|
|
140
|
+
})
|
|
141
|
+
]
|
|
142
|
+
}),
|
|
143
|
+
C("quantity")
|
|
144
|
+
]
|
|
145
|
+
}),
|
|
146
|
+
/* @__PURE__ */ h("div", {
|
|
147
|
+
className: "ttw:col-span-1 ttw:flex ttw:flex-col ttw:gap-1.5",
|
|
148
|
+
children: [
|
|
149
|
+
/* @__PURE__ */ m(a, {
|
|
150
|
+
htmlFor: `${p}-price`,
|
|
151
|
+
children: M.price
|
|
152
|
+
}),
|
|
153
|
+
/* @__PURE__ */ h(n, { children: [/* @__PURE__ */ m(r, {
|
|
154
|
+
align: "inline-start",
|
|
155
|
+
"aria-hidden": !0,
|
|
156
|
+
children: M.currencySymbol
|
|
157
|
+
}), /* @__PURE__ */ m(i, {
|
|
158
|
+
id: `${p}-price`,
|
|
159
|
+
"data-has-start-addon": !0,
|
|
160
|
+
inputMode: "decimal",
|
|
161
|
+
className: "ttw:text-right ttw:aria-invalid:border-destructive ttw:aria-invalid:ring-destructive/20",
|
|
162
|
+
value: d.price,
|
|
163
|
+
disabled: k,
|
|
164
|
+
"aria-invalid": S("price") ? !0 : void 0,
|
|
165
|
+
"aria-describedby": S("price") ? x("price") : void 0,
|
|
166
|
+
onChange: (e) => d.onChange({ price: e.target.value })
|
|
167
|
+
})] }),
|
|
168
|
+
C("price")
|
|
169
|
+
]
|
|
170
|
+
}),
|
|
171
|
+
/* @__PURE__ */ h("div", {
|
|
172
|
+
className: "ttw:col-span-1 ttw:flex ttw:flex-col ttw:gap-1.5",
|
|
173
|
+
children: [
|
|
174
|
+
/* @__PURE__ */ m(a, {
|
|
175
|
+
htmlFor: `${p}-amount`,
|
|
176
|
+
children: M.amount
|
|
177
|
+
}),
|
|
178
|
+
/* @__PURE__ */ h(n, { children: [/* @__PURE__ */ m(r, {
|
|
179
|
+
align: "inline-start",
|
|
180
|
+
"aria-hidden": !0,
|
|
181
|
+
children: M.currencySymbol
|
|
182
|
+
}), /* @__PURE__ */ m(i, {
|
|
183
|
+
id: `${p}-amount`,
|
|
184
|
+
"data-has-start-addon": !0,
|
|
185
|
+
inputMode: "decimal",
|
|
186
|
+
className: "ttw:text-right ttw:aria-invalid:border-destructive ttw:aria-invalid:ring-destructive/20",
|
|
187
|
+
value: d.amount,
|
|
188
|
+
disabled: k,
|
|
189
|
+
"aria-invalid": S("amount") ? !0 : void 0,
|
|
190
|
+
"aria-describedby": S("amount") ? x("amount") : void 0,
|
|
191
|
+
onChange: (e) => d.onChange({ amount: e.target.value })
|
|
192
|
+
})] }),
|
|
193
|
+
C("amount")
|
|
194
|
+
]
|
|
195
|
+
})
|
|
196
|
+
]
|
|
197
|
+
})
|
|
198
|
+
]
|
|
199
|
+
})
|
|
200
|
+
}, d.id);
|
|
201
|
+
}),
|
|
202
|
+
/* @__PURE__ */ m(e, {
|
|
203
|
+
type: "button",
|
|
204
|
+
variant: "link",
|
|
205
|
+
disabled: k,
|
|
206
|
+
className: "ttw:self-start",
|
|
207
|
+
onClick: D,
|
|
208
|
+
children: M.addLineItem
|
|
209
|
+
}),
|
|
210
|
+
/* @__PURE__ */ h("div", {
|
|
211
|
+
className: "ttw:flex ttw:flex-col ttw:gap-2 ttw:border-t ttw:border-border ttw:pt-3",
|
|
212
|
+
children: [
|
|
213
|
+
/* @__PURE__ */ h("div", {
|
|
214
|
+
className: "ttw:flex ttw:items-center ttw:justify-between ttw:gap-4",
|
|
215
|
+
children: [/* @__PURE__ */ m(a, {
|
|
216
|
+
htmlFor: `${N}-discount`,
|
|
217
|
+
children: M.discount
|
|
218
|
+
}), /* @__PURE__ */ h(n, {
|
|
219
|
+
className: "ttw:w-36",
|
|
220
|
+
children: [/* @__PURE__ */ m(r, {
|
|
221
|
+
align: "inline-start",
|
|
222
|
+
"aria-hidden": !0,
|
|
223
|
+
children: M.currencySymbol
|
|
224
|
+
}), /* @__PURE__ */ m(i, {
|
|
225
|
+
id: `${N}-discount`,
|
|
226
|
+
"data-has-start-addon": !0,
|
|
227
|
+
inputMode: "decimal",
|
|
228
|
+
className: "ttw:text-right",
|
|
229
|
+
value: x,
|
|
230
|
+
disabled: k,
|
|
231
|
+
onChange: (e) => S(e.target.value)
|
|
232
|
+
})]
|
|
233
|
+
})]
|
|
234
|
+
}),
|
|
235
|
+
/* @__PURE__ */ h("div", {
|
|
236
|
+
className: "ttw:flex ttw:items-center ttw:justify-between ttw:gap-4",
|
|
237
|
+
children: [/* @__PURE__ */ m(a, {
|
|
238
|
+
htmlFor: `${N}-tax`,
|
|
239
|
+
children: M.tax
|
|
240
|
+
}), /* @__PURE__ */ h(n, {
|
|
241
|
+
className: "ttw:w-36",
|
|
242
|
+
children: [/* @__PURE__ */ m(r, {
|
|
243
|
+
align: "inline-start",
|
|
244
|
+
"aria-hidden": !0,
|
|
245
|
+
children: M.currencySymbol
|
|
246
|
+
}), /* @__PURE__ */ m(i, {
|
|
247
|
+
id: `${N}-tax`,
|
|
248
|
+
"data-has-start-addon": !0,
|
|
249
|
+
inputMode: "decimal",
|
|
250
|
+
className: "ttw:text-right",
|
|
251
|
+
value: C,
|
|
252
|
+
disabled: k,
|
|
253
|
+
onChange: (e) => w(e.target.value)
|
|
254
|
+
})]
|
|
255
|
+
})]
|
|
256
|
+
}),
|
|
257
|
+
/* @__PURE__ */ h("div", {
|
|
258
|
+
className: "ttw:flex ttw:items-center ttw:justify-between ttw:gap-4",
|
|
259
|
+
children: [/* @__PURE__ */ m(a, {
|
|
260
|
+
htmlFor: `${N}-total`,
|
|
261
|
+
className: "ttw:font-semibold",
|
|
262
|
+
children: M.totalAmount
|
|
263
|
+
}), /* @__PURE__ */ h(n, {
|
|
264
|
+
className: "ttw:w-36",
|
|
265
|
+
children: [/* @__PURE__ */ m(r, {
|
|
266
|
+
align: "inline-start",
|
|
267
|
+
"aria-hidden": !0,
|
|
268
|
+
children: M.currencySymbol
|
|
269
|
+
}), /* @__PURE__ */ m(i, {
|
|
270
|
+
id: `${N}-total`,
|
|
271
|
+
"data-has-start-addon": !0,
|
|
272
|
+
inputMode: "decimal",
|
|
273
|
+
className: "ttw:text-right ttw:font-semibold",
|
|
274
|
+
value: T,
|
|
275
|
+
disabled: k,
|
|
276
|
+
onChange: (e) => E(e.target.value)
|
|
277
|
+
})]
|
|
278
|
+
})]
|
|
279
|
+
})
|
|
280
|
+
]
|
|
281
|
+
})
|
|
282
|
+
]
|
|
283
|
+
});
|
|
284
|
+
}
|
|
285
|
+
//#endregion
|
|
286
|
+
export { y as LineItemsSection, y as default };
|
|
@@ -1,13 +1,2 @@
|
|
|
1
|
-
import
|
|
2
|
-
import "./index20.js";
|
|
3
|
-
import { VENDOR_SEARCH_COMBOBOX_LABELS_EN as t } from "./index21.js";
|
|
1
|
+
import "./index22.js";
|
|
4
2
|
import "./index23.js";
|
|
5
|
-
//#region ../../libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index24.js
|
|
6
|
-
var n = {
|
|
7
|
-
heading: "Who are you paying?",
|
|
8
|
-
summaryCard: e,
|
|
9
|
-
search: t,
|
|
10
|
-
noVendorPlaceholder: "No vendor selected"
|
|
11
|
-
};
|
|
12
|
-
//#endregion
|
|
13
|
-
export { n as VENDOR_SECTION_LABELS_EN };
|
|
@@ -1,58 +1,16 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import
|
|
3
|
-
import "./index20.js";
|
|
4
|
-
import { VendorSearchCombobox as n } from "./index22.js";
|
|
5
|
-
import "./index23.js";
|
|
6
|
-
import { VENDOR_SECTION_LABELS_EN as r } from "./index24.js";
|
|
7
|
-
import { jsx as i, jsxs as a } from "react/jsx-runtime";
|
|
1
|
+
import { ACH_FIELD_GROUP_LABELS_EN as e } from "../../../shared/counterpart-management/ui/dist/index2.js";
|
|
2
|
+
import "../../../shared/counterpart-management/ui/dist/index.js";
|
|
8
3
|
//#region ../../libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index25.js
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
},
|
|
21
|
-
search: {
|
|
22
|
-
...r.search,
|
|
23
|
-
...d?.search
|
|
24
|
-
}
|
|
25
|
-
};
|
|
26
|
-
return /* @__PURE__ */ a("section", {
|
|
27
|
-
className: "ttw:flex ttw:flex-col ttw:gap-3",
|
|
28
|
-
"data-testid": u,
|
|
29
|
-
children: [
|
|
30
|
-
/* @__PURE__ */ i(e, {
|
|
31
|
-
component: "h2",
|
|
32
|
-
variant: "h6",
|
|
33
|
-
className: "ttw:font-semibold",
|
|
34
|
-
children: p.heading
|
|
35
|
-
}),
|
|
36
|
-
o.mode === "resolved" ? /* @__PURE__ */ i(t, {
|
|
37
|
-
summary: o.summary,
|
|
38
|
-
onEdit: s,
|
|
39
|
-
onClear: c,
|
|
40
|
-
paymentInstructions: f ? void 0 : o.paymentInstructions,
|
|
41
|
-
labels: p.summaryCard
|
|
42
|
-
}) : f ? /* @__PURE__ */ i(e, {
|
|
43
|
-
variant: "body2",
|
|
44
|
-
className: "ttw:text-muted-foreground",
|
|
45
|
-
children: p.noVendorPlaceholder
|
|
46
|
-
}) : o.mode === "selecting" ? /* @__PURE__ */ i(n, {
|
|
47
|
-
...o.search,
|
|
48
|
-
labels: p.search
|
|
49
|
-
}) : o.newVendorForm,
|
|
50
|
-
l ? /* @__PURE__ */ i("p", {
|
|
51
|
-
className: "ttw:text-sm ttw:text-destructive",
|
|
52
|
-
children: l
|
|
53
|
-
}) : null
|
|
54
|
-
]
|
|
55
|
-
});
|
|
56
|
-
}
|
|
4
|
+
var t = {
|
|
5
|
+
payToHeading: "Pay to",
|
|
6
|
+
editAction: "Edit",
|
|
7
|
+
clearAction: "Clear",
|
|
8
|
+
paymentInstructionsHeading: "Payment instructions",
|
|
9
|
+
paymentInstructionsDescription: "How and where will the money be sent. This information is required to send a payment.",
|
|
10
|
+
addPaymentInstructions: "Add payment instructions",
|
|
11
|
+
ach: e,
|
|
12
|
+
revealField: (e) => `Show ${e.toLowerCase()}`,
|
|
13
|
+
hideField: (e) => `Hide ${e.toLowerCase()}`
|
|
14
|
+
};
|
|
57
15
|
//#endregion
|
|
58
|
-
export {
|
|
16
|
+
export { t as VENDOR_SUMMARY_CARD_LABELS_EN };
|
|
@@ -1,2 +1,120 @@
|
|
|
1
|
-
import "
|
|
2
|
-
import "
|
|
1
|
+
import { Button as e } from "../../../../../packages/shared-ui-shadcn/dist/index.js";
|
|
2
|
+
import { AchFieldGroup as t } from "../../../shared/counterpart-management/ui/dist/index5.js";
|
|
3
|
+
import "../../../shared/counterpart-management/ui/dist/index.js";
|
|
4
|
+
import { VENDOR_SUMMARY_CARD_LABELS_EN as n } from "./index25.js";
|
|
5
|
+
import { useState as r } from "react";
|
|
6
|
+
import { Fragment as i, jsx as a, jsxs as o } from "react/jsx-runtime";
|
|
7
|
+
import { Eye as s, EyeOff as c, Pencil as l, Plus as u, X as d } from "lucide-react";
|
|
8
|
+
//#region ../../libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index26.js
|
|
9
|
+
function f({ field: e, labels: t }) {
|
|
10
|
+
let [n, i] = r(!1), l = !!e.maskedValue, u = l && !n ? e.maskedValue : e.value;
|
|
11
|
+
return /* @__PURE__ */ o("div", {
|
|
12
|
+
className: "ttw:flex ttw:items-center ttw:gap-2 ttw:text-sm",
|
|
13
|
+
children: [
|
|
14
|
+
/* @__PURE__ */ a("span", {
|
|
15
|
+
className: "ttw:w-44 ttw:shrink-0 ttw:text-muted-foreground",
|
|
16
|
+
children: e.label
|
|
17
|
+
}),
|
|
18
|
+
/* @__PURE__ */ a("span", {
|
|
19
|
+
className: "ttw:text-foreground",
|
|
20
|
+
children: u
|
|
21
|
+
}),
|
|
22
|
+
l ? /* @__PURE__ */ a("button", {
|
|
23
|
+
type: "button",
|
|
24
|
+
onClick: () => i((e) => !e),
|
|
25
|
+
"aria-label": n ? t.hideField(e.label) : t.revealField(e.label),
|
|
26
|
+
className: "ttw:text-muted-foreground ttw:hover:text-foreground",
|
|
27
|
+
children: a(n ? c : s, { className: "ttw:size-4" })
|
|
28
|
+
}) : null
|
|
29
|
+
]
|
|
30
|
+
});
|
|
31
|
+
}
|
|
32
|
+
function p({ summary: r, onEdit: s, onClear: c, paymentInstructions: p, testId: m, labels: h }) {
|
|
33
|
+
let g = {
|
|
34
|
+
...n,
|
|
35
|
+
...h,
|
|
36
|
+
ach: {
|
|
37
|
+
...n.ach,
|
|
38
|
+
...h?.ach
|
|
39
|
+
}
|
|
40
|
+
};
|
|
41
|
+
return /* @__PURE__ */ o("div", {
|
|
42
|
+
className: "ttw:rounded-lg ttw:border ttw:border-border ttw:bg-muted/30 ttw:p-4",
|
|
43
|
+
"data-testid": m,
|
|
44
|
+
children: [/* @__PURE__ */ o("div", {
|
|
45
|
+
className: "ttw:flex ttw:items-start ttw:justify-between",
|
|
46
|
+
children: [/* @__PURE__ */ o("div", {
|
|
47
|
+
className: "ttw:flex ttw:flex-col ttw:gap-0.5",
|
|
48
|
+
children: [
|
|
49
|
+
/* @__PURE__ */ a("span", {
|
|
50
|
+
className: "ttw:text-xs ttw:text-muted-foreground",
|
|
51
|
+
children: g.payToHeading
|
|
52
|
+
}),
|
|
53
|
+
/* @__PURE__ */ a("span", {
|
|
54
|
+
className: "ttw:text-base ttw:font-semibold ttw:text-foreground",
|
|
55
|
+
children: r.name
|
|
56
|
+
}),
|
|
57
|
+
/* @__PURE__ */ a("span", {
|
|
58
|
+
className: "ttw:text-sm ttw:text-muted-foreground",
|
|
59
|
+
children: r.email
|
|
60
|
+
})
|
|
61
|
+
]
|
|
62
|
+
}), /* @__PURE__ */ o("div", {
|
|
63
|
+
className: "ttw:flex ttw:items-center ttw:gap-1",
|
|
64
|
+
children: [s ? /* @__PURE__ */ a(e, {
|
|
65
|
+
type: "button",
|
|
66
|
+
variant: "ghost",
|
|
67
|
+
size: "icon",
|
|
68
|
+
"aria-label": g.editAction,
|
|
69
|
+
onClick: s,
|
|
70
|
+
children: /* @__PURE__ */ a(l, { className: "ttw:size-4" })
|
|
71
|
+
}) : null, c ? /* @__PURE__ */ a(e, {
|
|
72
|
+
type: "button",
|
|
73
|
+
variant: "ghost",
|
|
74
|
+
size: "icon",
|
|
75
|
+
"aria-label": g.clearAction,
|
|
76
|
+
onClick: c,
|
|
77
|
+
children: /* @__PURE__ */ a(d, { className: "ttw:size-4" })
|
|
78
|
+
}) : null]
|
|
79
|
+
})]
|
|
80
|
+
}), r.fields.length ? /* @__PURE__ */ o(i, { children: [/* @__PURE__ */ a("p", {
|
|
81
|
+
className: "ttw:mt-3 ttw:text-xs ttw:text-muted-foreground",
|
|
82
|
+
children: r.methodLabel
|
|
83
|
+
}), /* @__PURE__ */ a("div", {
|
|
84
|
+
className: "ttw:mt-2 ttw:flex ttw:flex-col ttw:gap-1",
|
|
85
|
+
children: r.fields.map((e) => /* @__PURE__ */ a(f, {
|
|
86
|
+
field: e,
|
|
87
|
+
labels: g
|
|
88
|
+
}, `${e.label}:${e.value}:${e.maskedValue ?? ""}`))
|
|
89
|
+
})] }) : /* @__PURE__ */ o("div", {
|
|
90
|
+
className: "ttw:mt-4 ttw:flex ttw:flex-col ttw:gap-3",
|
|
91
|
+
children: [/* @__PURE__ */ o("div", {
|
|
92
|
+
className: "ttw:flex ttw:flex-col ttw:gap-1",
|
|
93
|
+
children: [/* @__PURE__ */ a("p", {
|
|
94
|
+
className: "ttw:text-sm ttw:font-semibold ttw:text-foreground",
|
|
95
|
+
children: g.paymentInstructionsHeading
|
|
96
|
+
}), /* @__PURE__ */ a("p", {
|
|
97
|
+
className: "ttw:text-sm ttw:text-muted-foreground",
|
|
98
|
+
children: g.paymentInstructionsDescription
|
|
99
|
+
})]
|
|
100
|
+
}), p?.isOpen ? /* @__PURE__ */ a(t, {
|
|
101
|
+
idPrefix: "vendor-summary-ach",
|
|
102
|
+
values: p.values,
|
|
103
|
+
errors: p.errors,
|
|
104
|
+
onChange: p.onChange,
|
|
105
|
+
labels: g.ach
|
|
106
|
+
}) : p ? /* @__PURE__ */ o(e, {
|
|
107
|
+
type: "button",
|
|
108
|
+
variant: "link",
|
|
109
|
+
className: "ttw:w-fit ttw:px-0",
|
|
110
|
+
onClick: p.onOpen,
|
|
111
|
+
children: [/* @__PURE__ */ a(u, { className: "ttw:size-4" }), g.addPaymentInstructions]
|
|
112
|
+
}) : /* @__PURE__ */ a("p", {
|
|
113
|
+
className: "ttw:text-sm ttw:text-muted-foreground",
|
|
114
|
+
children: r.methodLabel
|
|
115
|
+
})]
|
|
116
|
+
})]
|
|
117
|
+
});
|
|
118
|
+
}
|
|
119
|
+
//#endregion
|
|
120
|
+
export { p as VendorSummaryCard, p as default };
|
|
@@ -1,20 +1,2 @@
|
|
|
1
|
-
import
|
|
2
|
-
import "./index14.js";
|
|
3
|
-
import { LINE_ITEMS_SECTION_LABELS_EN as t } from "./index15.js";
|
|
4
|
-
import "./index17.js";
|
|
5
|
-
import { VENDOR_SECTION_LABELS_EN as n } from "./index24.js";
|
|
1
|
+
import "./index25.js";
|
|
6
2
|
import "./index26.js";
|
|
7
|
-
//#region ../../libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index27.js
|
|
8
|
-
var r = {
|
|
9
|
-
closeButton: "Close",
|
|
10
|
-
menuTrigger: "More actions",
|
|
11
|
-
cancelButton: "Cancel",
|
|
12
|
-
saveDraftButton: "Save and close",
|
|
13
|
-
finalizeButton: "Finalize",
|
|
14
|
-
hiddenDescription: "Enter the details of the bill you want to pay.",
|
|
15
|
-
vendorSection: n,
|
|
16
|
-
detailsFields: e,
|
|
17
|
-
lineItems: t
|
|
18
|
-
};
|
|
19
|
-
//#endregion
|
|
20
|
-
export { r as BILL_CREATE_SCREEN_LABELS_EN };
|