@tesouro/embedded-components-react 0.2.280 → 0.2.282
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 +17 -14
- package/dist/experimental/WidgetSuite.d.ts +9 -1
- package/dist/experimental/index.d.ts +9 -1
- package/dist/index.css +20 -6
- package/dist/index.d.ts +46 -23
- package/dist/index.js +54 -53
- package/dist/lib/AcceptDisclosuresWidget.d.ts +9 -1
- package/dist/lib/BalancesWidget.d.ts +8 -0
- package/dist/lib/BankAccountOnboardingWidget.d.ts +9 -1
- package/dist/lib/BankAccountsWidget.d.ts +9 -1
- package/dist/lib/BillPayWidget.d.ts +8 -0
- package/dist/lib/BillPayWidget.js +1 -1
- package/dist/lib/CardDetailsWidget.d.ts +9 -1
- package/dist/lib/CardsWidget.d.ts +9 -1
- package/dist/lib/ChartOfAccountsWidget.d.ts +9 -1
- package/dist/lib/CounterpartsWidget.d.ts +9 -1
- package/dist/lib/CreateCardWidget.d.ts +9 -1
- package/dist/lib/ExpenseApprovalPoliciesWidget.d.ts +9 -1
- package/dist/lib/ExpenseManagementWidget.d.ts +9 -1
- package/dist/lib/ExpenseRequirementsWidget.d.ts +9 -1
- package/dist/lib/HelpWidget.d.ts +9 -1
- package/dist/lib/InsightsWidget.d.ts +8 -0
- package/dist/lib/InvoicingWidget.d.ts +9 -1
- package/dist/lib/LinkedAccountsWidget.d.ts +9 -1
- package/dist/lib/ProductsWidget.d.ts +9 -1
- package/dist/lib/ProfileWidget.d.ts +9 -1
- package/dist/lib/ReceiptMatchWidget.d.ts +9 -1
- package/dist/lib/ReceivablesWidget.d.ts +9 -1
- package/dist/lib/SettingsWidget.d.ts +9 -1
- package/dist/lib/TagsWidget.d.ts +9 -1
- package/dist/lib/TeamWidget.d.ts +9 -1
- package/dist/lib/TransfersWidget.d.ts +8 -0
- package/dist/lib/WidgetProvider.d.ts +25 -2
- package/dist/lib/WidgetProvider.js +8 -7
- package/dist/lib/WidgetProviderPublic.d.ts +8 -0
- package/dist/libs/tesouro-embedded-components-react/accept-disclosures-widget/feature/dist/index4.js +3 -2
- package/dist/libs/tesouro-embedded-components-react/bank-account-onboarding-widget/feature/dist/index17.js +54 -53
- package/dist/libs/tesouro-embedded-components-react/bank-accounts-widget/feature/dist/index8.js +3 -2
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index.js +9 -5
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index10.js +42 -39
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index12.js +69 -54
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index14.js +21 -2
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index15.js +46 -40
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index16.js +81 -1
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index17.js +46 -47
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index18.js +3 -11
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index19.js +2 -8
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index2.js +5 -3
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index20.js +43 -5
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index21.js +1 -102
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index22.js +11 -3
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index23.js +9 -6
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index24.js +4 -5
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index25.js +127 -76
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index27.js +6 -6
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index28.js +7 -111
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index29.js +85 -1
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index3.js +16 -12
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index30.js +2 -24
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index31.js +8 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index32.js +114 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index33.js +1 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index34.js +25 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index5.js +50 -49
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index6.js +1 -1
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index7.js +25 -12
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index8.js +86 -69
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index9.js +2 -1
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index.js +7 -7
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index13.js +17 -16
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index16.js +1 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index21.js +1 -1
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index22.js +89 -124
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index24.js +2 -1
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index25.js +31 -26
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index27.js +1 -1
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index28.js +80 -77
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index36.js +20 -4
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index37.js +228 -6
- package/dist/libs/tesouro-embedded-components-react/card-details-widget/feature/dist/index6.js +3 -2
- package/dist/libs/tesouro-embedded-components-react/cards-widget/feature/dist/index8.js +3 -2
- package/dist/libs/tesouro-embedded-components-react/counterparts-widget/feature/dist/index8.js +3 -2
- package/dist/libs/tesouro-embedded-components-react/create-card-widget/feature/dist/index7.js +30 -29
- package/dist/libs/tesouro-embedded-components-react/expense-approval-policies-widget/feature/dist/lib/ExpenseApprovalPoliciesWidgetFeature.js +2 -1
- package/dist/libs/tesouro-embedded-components-react/expense-management-widget/feature/dist/index3.js +3 -2
- package/dist/libs/tesouro-embedded-components-react/expense-receipt-match-widget/feature/dist/lib/ReceiptMatchWidget.js +7 -6
- package/dist/libs/tesouro-embedded-components-react/expense-requirements-widget/feature/dist/lib/ExpenseRequirementsWidget.js +2 -1
- package/dist/libs/tesouro-embedded-components-react/gl-code-table-widget/feature/dist/index8.js +5 -4
- package/dist/libs/tesouro-embedded-components-react/help-widget/feature/dist/index3.js +3 -2
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/feature/dist/index12.js +3 -2
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/feature/dist/index3.js +5 -4
- package/dist/libs/tesouro-embedded-components-react/linked-accounts-widget/feature/dist/index9.js +3 -2
- package/dist/libs/tesouro-embedded-components-react/products-widget/feature/dist/index8.js +3 -2
- package/dist/libs/tesouro-embedded-components-react/profile-widget/feature/dist/index4.js +3 -2
- package/dist/libs/tesouro-embedded-components-react/settings-widget/feature/dist/index6.js +3 -2
- package/dist/libs/tesouro-embedded-components-react/shared/data-access/dist/index.js +6 -6
- package/dist/libs/tesouro-embedded-components-react/shared/data-access/dist/lib/reference-data/useLedgerAccountsQuery.js +53 -11
- package/dist/libs/tesouro-embedded-components-react/shared/feature/dist/index.js +5 -5
- package/dist/libs/tesouro-embedded-components-react/shared/feature/dist/lib/WidgetProvider/RootWidgetProvider.js +69 -67
- package/dist/libs/tesouro-embedded-components-react/shared/feature/dist/lib/WidgetProvider/WidgetProvider.js +158 -132
- package/dist/libs/tesouro-embedded-components-react/shared/feature/dist/lib/WidgetProvider/hooks.js +7 -4
- package/dist/libs/tesouro-embedded-components-react/shared/feature/dist/lib/WidgetProvider/isDisclosuresAcceptanceRequired.js +20 -0
- package/dist/libs/tesouro-embedded-components-react/shared/feature/dist/lib/WidgetProvider/labels.js +6 -1
- package/dist/libs/tesouro-embedded-components-react/shared/feature/dist/lib/analytics/build-info.js +1 -1
- package/dist/libs/tesouro-embedded-components-react/shared/ui/dist/index.js +9 -9
- package/dist/libs/tesouro-embedded-components-react/shared/ui/dist/lib/ErrorState/ErrorState.js +19 -18
- package/dist/libs/tesouro-embedded-components-react/tags-widget/feature/dist/index11.js +3 -2
- package/dist/libs/tesouro-embedded-components-react/team-widget/feature/dist/index17.js +3 -2
- package/dist/libs/tesouro-embedded-components-react/widget-suite/feature/dist/index5.js +1 -1
- package/dist/libs/tesouro-embedded-components-react/widget-suite/feature/dist/index6.js +3 -2
- package/dist/packages/shared-ui-shadcn/dist/index.js +3445 -3413
- package/package.json +1 -1
|
@@ -28,16 +28,16 @@ import "./index32.js";
|
|
|
28
28
|
import "./index33.js";
|
|
29
29
|
import "./index34.js";
|
|
30
30
|
import "./index35.js";
|
|
31
|
-
import "./index36.js";
|
|
32
|
-
import "./index37.js";
|
|
33
|
-
import { BillsScreen as
|
|
31
|
+
import { BILL_DETAILS_SHEET_LABELS_EN as r } from "./index36.js";
|
|
32
|
+
import { BillDetailsSheet as i } from "./index37.js";
|
|
33
|
+
import { BillsScreen as a } from "./index38.js";
|
|
34
34
|
import "./index39.js";
|
|
35
|
-
import { BillUploadStatusTray as
|
|
35
|
+
import { BillUploadStatusTray as o } from "./index41.js";
|
|
36
36
|
import "./index43.js";
|
|
37
37
|
import "./index44.js";
|
|
38
|
-
import { ExtractionNotice as
|
|
38
|
+
import { ExtractionNotice as s } from "./index45.js";
|
|
39
39
|
import "./index46.js";
|
|
40
40
|
import "./index47.js";
|
|
41
|
-
import { SourceDocumentPanel as
|
|
41
|
+
import { SourceDocumentPanel as c } from "./index48.js";
|
|
42
42
|
import "./index49.js";
|
|
43
|
-
export { e as AddBillDialog, t as BillCreateScreen, n as BillPayWidgetUi,
|
|
43
|
+
export { e as AddBillDialog, r as BILL_DETAILS_SHEET_LABELS_EN, t as BillCreateScreen, i as BillDetailsSheet, n as BillPayWidgetUi, o as BillUploadStatusTray, a as BillsScreen, s as ExtractionNotice, c as SourceDocumentPanel };
|
|
@@ -3,44 +3,45 @@ import { BILL_FORM_FIELDS_LABELS_EN as n } from "./index12.js";
|
|
|
3
3
|
import { useId as r } from "react";
|
|
4
4
|
import { jsx as i, jsxs as a } from "react/jsx-runtime";
|
|
5
5
|
//#region ../../libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index13.js
|
|
6
|
-
function o({ values: o, errors: s, onChange: c,
|
|
7
|
-
let
|
|
6
|
+
function o({ values: o, errors: s, onChange: c, disabled: l, testId: u, labels: d }) {
|
|
7
|
+
let f = {
|
|
8
8
|
...n,
|
|
9
|
-
...
|
|
10
|
-
},
|
|
11
|
-
let
|
|
9
|
+
...d
|
|
10
|
+
}, p = r(), m = (n, r, u) => {
|
|
11
|
+
let d = `${p}-${n}`, f = `${d}-error`, m = s?.[n];
|
|
12
12
|
return /* @__PURE__ */ a("div", {
|
|
13
13
|
className: "ttw:flex ttw:flex-col ttw:gap-1.5",
|
|
14
14
|
children: [
|
|
15
15
|
/* @__PURE__ */ i(t, {
|
|
16
|
-
htmlFor:
|
|
16
|
+
htmlFor: d,
|
|
17
17
|
children: r
|
|
18
18
|
}),
|
|
19
19
|
/* @__PURE__ */ i(e, {
|
|
20
|
-
id:
|
|
21
|
-
type:
|
|
20
|
+
id: d,
|
|
21
|
+
type: u,
|
|
22
22
|
value: o[n],
|
|
23
|
-
|
|
24
|
-
"aria-
|
|
23
|
+
disabled: l,
|
|
24
|
+
"aria-invalid": m ? !0 : void 0,
|
|
25
|
+
"aria-describedby": m ? f : void 0,
|
|
25
26
|
onChange: (e) => c({ [n]: e.target.value })
|
|
26
27
|
}),
|
|
27
|
-
|
|
28
|
-
id:
|
|
28
|
+
m ? /* @__PURE__ */ i("p", {
|
|
29
|
+
id: f,
|
|
29
30
|
className: "ttw:text-sm ttw:text-destructive",
|
|
30
|
-
children:
|
|
31
|
+
children: m
|
|
31
32
|
}) : null
|
|
32
33
|
]
|
|
33
34
|
});
|
|
34
35
|
};
|
|
35
36
|
return /* @__PURE__ */ a("div", {
|
|
36
37
|
className: "ttw:flex ttw:flex-col ttw:gap-4",
|
|
37
|
-
"data-testid":
|
|
38
|
+
"data-testid": u,
|
|
38
39
|
children: [/* @__PURE__ */ a("div", {
|
|
39
40
|
className: "ttw:grid ttw:grid-cols-2 ttw:gap-4",
|
|
40
|
-
children: [
|
|
41
|
+
children: [m("invoiceDate", f.invoiceDate, "date"), m("dueDate", f.dueDate, "date")]
|
|
41
42
|
}), /* @__PURE__ */ a("div", {
|
|
42
43
|
className: "ttw:grid ttw:grid-cols-2 ttw:gap-4",
|
|
43
|
-
children: [
|
|
44
|
+
children: [m("invoiceNumber", f.invoiceNumber), m("poNumber", f.poNumber)]
|
|
44
45
|
})]
|
|
45
46
|
});
|
|
46
47
|
}
|
|
@@ -86,6 +86,7 @@ function y({ items: y, glCodeOptions: b, discount: x, onDiscountChange: S, tax:
|
|
|
86
86
|
onValueChange: (e) => d.onChange({ glCode: e }),
|
|
87
87
|
children: [/* @__PURE__ */ m(l, {
|
|
88
88
|
id: `${p}-gl-code`,
|
|
89
|
+
className: "ttw:w-full",
|
|
89
90
|
"aria-invalid": S("glCode") ? !0 : void 0,
|
|
90
91
|
"aria-describedby": S("glCode") ? x("glCode") : void 0,
|
|
91
92
|
children: /* @__PURE__ */ m(u, { placeholder: M.glCodePlaceholder })
|
|
@@ -1,131 +1,96 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { VENDOR_SEARCH_COMBOBOX_LABELS_EN as
|
|
3
|
-
import { useId as
|
|
4
|
-
import { jsx as
|
|
5
|
-
import { Plus as
|
|
1
|
+
import { Command as e, CommandGroup as t, CommandInput as n, CommandItem as r, CommandList as i, CommandSeparator as a, Label as o, Popover as s, PopoverContent as c, PopoverTrigger as l, Skeleton as u, cn as d } from "../../../../../packages/shared-ui-shadcn/dist/index.js";
|
|
2
|
+
import { VENDOR_SEARCH_COMBOBOX_LABELS_EN as f } from "./index21.js";
|
|
3
|
+
import { useId as p, useState as m } from "react";
|
|
4
|
+
import { jsx as h, jsxs as g } from "react/jsx-runtime";
|
|
5
|
+
import { Plus as _, Search as v } from "lucide-react";
|
|
6
6
|
//#region ../../libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index22.js
|
|
7
|
-
var
|
|
8
|
-
function
|
|
9
|
-
let
|
|
10
|
-
...
|
|
11
|
-
...
|
|
12
|
-
},
|
|
13
|
-
|
|
14
|
-
}, k = () => {
|
|
15
|
-
C(!1), T(-1), g();
|
|
16
|
-
}, A = () => {
|
|
17
|
-
C(!1), T(-1);
|
|
18
|
-
};
|
|
19
|
-
return /* @__PURE__ */ s("div", {
|
|
7
|
+
var y = 5, b = "ttw:min-h-44";
|
|
8
|
+
function x({ query: x, onQueryChange: S, results: C, isLoading: w, onAddVendor: T, testId: E, labels: D }) {
|
|
9
|
+
let O = {
|
|
10
|
+
...f,
|
|
11
|
+
...D
|
|
12
|
+
}, k = p(), [A, j] = m(!1);
|
|
13
|
+
return /* @__PURE__ */ g("div", {
|
|
20
14
|
className: "ttw:flex ttw:flex-col ttw:gap-1.5",
|
|
21
|
-
"data-testid":
|
|
22
|
-
children: [/* @__PURE__ */ o
|
|
23
|
-
htmlFor:
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
children: [/* @__PURE__ */
|
|
29
|
-
|
|
30
|
-
children:
|
|
31
|
-
"
|
|
32
|
-
|
|
33
|
-
}), /* @__PURE__ */ o(e, {
|
|
34
|
-
id: b,
|
|
35
|
-
value: f,
|
|
36
|
-
onChange: (e) => {
|
|
37
|
-
C(!0), T(-1), p(e.target.value);
|
|
38
|
-
},
|
|
39
|
-
onFocus: () => C(!0),
|
|
40
|
-
onBlur: A,
|
|
41
|
-
onKeyDown: (e) => {
|
|
42
|
-
if (e.key === "Escape") {
|
|
43
|
-
A();
|
|
44
|
-
return;
|
|
45
|
-
}
|
|
46
|
-
if (E) {
|
|
47
|
-
if (e.key === "ArrowDown") {
|
|
48
|
-
e.preventDefault(), C(!0), T((e) => e >= E - 1 ? 0 : e + 1);
|
|
49
|
-
return;
|
|
50
|
-
}
|
|
51
|
-
if (e.key === "ArrowUp") {
|
|
52
|
-
e.preventDefault(), C(!0), T((e) => e <= 0 ? E - 1 : e - 1);
|
|
53
|
-
return;
|
|
54
|
-
}
|
|
55
|
-
e.key === "Enter" && S && w >= 0 && (e.preventDefault(), w < m.length ? O(m[w].onSelect) : k());
|
|
56
|
-
}
|
|
57
|
-
},
|
|
58
|
-
placeholder: y.placeholder,
|
|
15
|
+
"data-testid": E,
|
|
16
|
+
children: [/* @__PURE__ */ h(o, {
|
|
17
|
+
htmlFor: k,
|
|
18
|
+
children: O.fieldLabel
|
|
19
|
+
}), /* @__PURE__ */ g(s, {
|
|
20
|
+
open: A,
|
|
21
|
+
onOpenChange: j,
|
|
22
|
+
children: [/* @__PURE__ */ h(l, {
|
|
23
|
+
asChild: !0,
|
|
24
|
+
children: /* @__PURE__ */ g("button", {
|
|
25
|
+
type: "button",
|
|
26
|
+
id: k,
|
|
59
27
|
role: "combobox",
|
|
60
|
-
"aria-
|
|
61
|
-
"
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
})
|
|
125
|
-
]
|
|
126
|
-
}) : null]
|
|
28
|
+
"aria-expanded": A,
|
|
29
|
+
className: "ttw:flex ttw:h-10 ttw:w-full ttw:items-center ttw:gap-2 ttw:rounded-md ttw:border ttw:border-border ttw:bg-background ttw:px-3 ttw:text-left ttw:text-sm ttw:shadow-xs ttw:outline-none ttw:focus-visible:border-ring ttw:focus-visible:ring-[3px] ttw:focus-visible:ring-ring/50",
|
|
30
|
+
children: [/* @__PURE__ */ h(v, {
|
|
31
|
+
"aria-hidden": !0,
|
|
32
|
+
className: "ttw:size-4 ttw:shrink-0 ttw:opacity-50"
|
|
33
|
+
}), /* @__PURE__ */ h("span", {
|
|
34
|
+
className: d("ttw:min-w-0 ttw:flex-1 ttw:truncate", !x && "ttw:text-muted-foreground"),
|
|
35
|
+
children: x || O.placeholder
|
|
36
|
+
})]
|
|
37
|
+
})
|
|
38
|
+
}), /* @__PURE__ */ h(c, {
|
|
39
|
+
align: "start",
|
|
40
|
+
className: "ttw:w-[var(--radix-popover-trigger-width)] ttw:p-0",
|
|
41
|
+
children: /* @__PURE__ */ g(e, {
|
|
42
|
+
shouldFilter: !1,
|
|
43
|
+
children: [/* @__PURE__ */ h(n, {
|
|
44
|
+
value: x,
|
|
45
|
+
onValueChange: S,
|
|
46
|
+
placeholder: O.placeholder,
|
|
47
|
+
"aria-label": O.placeholder
|
|
48
|
+
}), /* @__PURE__ */ g(i, {
|
|
49
|
+
className: d("ttw:max-h-72", b),
|
|
50
|
+
children: [
|
|
51
|
+
w ? /* @__PURE__ */ g("div", {
|
|
52
|
+
className: "ttw:flex ttw:flex-col ttw:gap-2 ttw:p-2",
|
|
53
|
+
"aria-busy": "true",
|
|
54
|
+
children: [/* @__PURE__ */ h("span", {
|
|
55
|
+
className: "ttw:sr-only",
|
|
56
|
+
children: O.loading
|
|
57
|
+
}), Array.from({ length: y }).map((e, t) => /* @__PURE__ */ g("div", {
|
|
58
|
+
className: "ttw:flex ttw:items-center ttw:justify-between ttw:gap-4 ttw:px-2 ttw:py-1.5",
|
|
59
|
+
children: [/* @__PURE__ */ h(u, {
|
|
60
|
+
height: 14,
|
|
61
|
+
width: "55%"
|
|
62
|
+
}), /* @__PURE__ */ h(u, {
|
|
63
|
+
height: 14,
|
|
64
|
+
width: "30%"
|
|
65
|
+
})]
|
|
66
|
+
}, t))]
|
|
67
|
+
}) : C.length === 0 && x ? /* @__PURE__ */ h("div", {
|
|
68
|
+
className: d("ttw:flex ttw:items-center ttw:justify-center ttw:py-6 ttw:text-center ttw:text-sm", b),
|
|
69
|
+
children: O.emptyResults
|
|
70
|
+
}) : C.length > 0 ? /* @__PURE__ */ h(t, { children: C.map((e, t) => /* @__PURE__ */ g(r, {
|
|
71
|
+
value: `${e.name} ${e.email} ${t}`,
|
|
72
|
+
onSelect: () => e.onSelect(),
|
|
73
|
+
children: [/* @__PURE__ */ h("span", {
|
|
74
|
+
className: "ttw:text-foreground",
|
|
75
|
+
children: e.name
|
|
76
|
+
}), /* @__PURE__ */ h("span", {
|
|
77
|
+
className: "ttw:ml-auto ttw:text-muted-foreground",
|
|
78
|
+
children: e.email
|
|
79
|
+
})]
|
|
80
|
+
}, `${e.name}:${e.email}:${t}`)) }) : null,
|
|
81
|
+
w || C.length > 0 || x ? /* @__PURE__ */ h(a, {}) : null,
|
|
82
|
+
/* @__PURE__ */ g(r, {
|
|
83
|
+
value: "__add_vendor__",
|
|
84
|
+
onSelect: T,
|
|
85
|
+
className: "ttw:sticky ttw:bottom-0 ttw:bg-popover ttw:text-primary",
|
|
86
|
+
children: [/* @__PURE__ */ h(_, { className: "ttw:size-4 ttw:text-primary" }), O.addVendorAction]
|
|
87
|
+
})
|
|
88
|
+
]
|
|
89
|
+
})]
|
|
90
|
+
})
|
|
91
|
+
})]
|
|
127
92
|
})]
|
|
128
93
|
});
|
|
129
94
|
}
|
|
130
95
|
//#endregion
|
|
131
|
-
export {
|
|
96
|
+
export { x as VendorSearchCombobox, x as default };
|
|
@@ -1,48 +1,53 @@
|
|
|
1
1
|
import { Typography as e } from "../../../../../packages/shared-ui-shadcn/dist/index.js";
|
|
2
|
-
import {
|
|
3
|
-
import "../../../shared/ui/dist/index.js";
|
|
4
|
-
import { VendorSummaryCard as n } from "./index19.js";
|
|
2
|
+
import { VendorSummaryCard as t } from "./index19.js";
|
|
5
3
|
import "./index20.js";
|
|
6
|
-
import { VendorSearchCombobox as
|
|
4
|
+
import { VendorSearchCombobox as n } from "./index22.js";
|
|
7
5
|
import "./index23.js";
|
|
8
|
-
import { VENDOR_SECTION_LABELS_EN as
|
|
9
|
-
import { jsx as
|
|
6
|
+
import { VENDOR_SECTION_LABELS_EN as r } from "./index24.js";
|
|
7
|
+
import { jsx as i, jsxs as a } from "react/jsx-runtime";
|
|
10
8
|
//#region ../../libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index25.js
|
|
11
|
-
function
|
|
12
|
-
let { onEdit:
|
|
13
|
-
...
|
|
14
|
-
...
|
|
9
|
+
function o(o) {
|
|
10
|
+
let { onEdit: s, onClear: c, error: l, testId: u, labels: d, disabled: f } = o, p = {
|
|
11
|
+
...r,
|
|
12
|
+
...d,
|
|
15
13
|
summaryCard: {
|
|
16
|
-
...
|
|
17
|
-
...
|
|
14
|
+
...r.summaryCard,
|
|
15
|
+
...d?.summaryCard
|
|
18
16
|
},
|
|
19
17
|
search: {
|
|
20
|
-
...
|
|
21
|
-
...
|
|
18
|
+
...r.search,
|
|
19
|
+
...d?.search
|
|
22
20
|
}
|
|
23
21
|
};
|
|
24
|
-
return /* @__PURE__ */
|
|
22
|
+
return /* @__PURE__ */ a("section", {
|
|
25
23
|
className: "ttw:flex ttw:flex-col ttw:gap-3",
|
|
26
|
-
"data-testid":
|
|
24
|
+
"data-testid": u,
|
|
27
25
|
children: [
|
|
28
|
-
/* @__PURE__ */
|
|
26
|
+
/* @__PURE__ */ i(e, {
|
|
29
27
|
component: "h2",
|
|
30
28
|
variant: "h6",
|
|
31
29
|
className: "ttw:font-semibold",
|
|
32
30
|
children: p.heading
|
|
33
31
|
}),
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
onClear: l,
|
|
32
|
+
o.mode === "resolved" ? /* @__PURE__ */ i(t, {
|
|
33
|
+
summary: o.summary,
|
|
34
|
+
onEdit: s,
|
|
35
|
+
onClear: c,
|
|
39
36
|
labels: p.summaryCard
|
|
40
|
-
}) :
|
|
41
|
-
|
|
37
|
+
}) : f ? /* @__PURE__ */ i(e, {
|
|
38
|
+
variant: "body2",
|
|
39
|
+
className: "ttw:text-muted-foreground",
|
|
40
|
+
children: p.noVendorPlaceholder
|
|
41
|
+
}) : o.mode === "selecting" ? /* @__PURE__ */ i(n, {
|
|
42
|
+
...o.search,
|
|
42
43
|
labels: p.search
|
|
43
|
-
}) :
|
|
44
|
+
}) : o.newVendorForm,
|
|
45
|
+
l ? /* @__PURE__ */ i("p", {
|
|
46
|
+
className: "ttw:text-sm ttw:text-destructive",
|
|
47
|
+
children: l
|
|
48
|
+
}) : null
|
|
44
49
|
]
|
|
45
50
|
});
|
|
46
51
|
}
|
|
47
52
|
//#endregion
|
|
48
|
-
export {
|
|
53
|
+
export { o as VendorSection, o as default };
|
|
@@ -9,7 +9,7 @@ var r = {
|
|
|
9
9
|
closeButton: "Close",
|
|
10
10
|
menuTrigger: "More actions",
|
|
11
11
|
cancelButton: "Cancel",
|
|
12
|
-
saveDraftButton: "Save
|
|
12
|
+
saveDraftButton: "Save and close",
|
|
13
13
|
finalizeButton: "Finalize",
|
|
14
14
|
hiddenDescription: "Enter the details of the bill you want to pay.",
|
|
15
15
|
vendorSection: n,
|