@tesouro/embedded-components-react 0.2.254 → 0.2.255
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/core.js +1 -1
- package/dist/index.css +15 -0
- package/dist/index.js +2 -2
- package/dist/lib/BillPayWidget.d.ts +151 -151
- package/dist/lib/BillPayWidget.js +1 -1
- package/dist/lib/InsightsWidget.js +1 -1
- package/dist/libs/tesouro-embedded-components-react/accept-disclosures-widget/feature/dist/index4.js +1 -1
- package/dist/libs/tesouro-embedded-components-react/balances-widget/feature/dist/index3.js +4 -4
- package/dist/libs/tesouro-embedded-components-react/bank-account-onboarding-widget/feature/dist/index17.js +2 -2
- package/dist/libs/tesouro-embedded-components-react/bank-accounts-widget/feature/dist/index7.js +1 -1
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/data-access/dist/index.js +10 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/data-access/dist/index10.js +40 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/data-access/dist/index11.js +36 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/data-access/dist/index3.js +28 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/data-access/dist/index4.js +22 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/data-access/dist/index5.js +7 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/data-access/dist/index6.js +75 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/data-access/dist/index7.js +166 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/data-access/dist/index8.js +17 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/data-access/dist/index9.js +30 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index.js +15 -1
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index10.js +9 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index11.js +99 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index12.js +4 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index13.js +4 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index14.js +43 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index15.js +1 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index16.js +50 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index17.js +8 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index18.js +7 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index19.js +93 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index2.js +42 -2
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index20.js +3 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index21.js +8 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index22.js +9 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index23.js +85 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index24.js +3 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index25.js +8 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index26.js +112 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index27.js +1 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index28.js +25 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index3.js +51 -35
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index4.js +235 -1
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index5.js +106 -7
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index6.js +35 -88
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index7.js +122 -1
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index8.js +36 -22
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index9.js +74 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index.js +15 -8
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index10.js +24 -3
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index11.js +1 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index12.js +12 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index13.js +83 -3
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index14.js +1 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index15.js +18 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index16.js +205 -4
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index17.js +1 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index18.js +10 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index19.js +89 -4
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index20.js +1 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index21.js +10 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index22.js +131 -4
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index23.js +1 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index24.js +10 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index25.js +45 -5
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index27.js +17 -1
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index28.js +149 -7
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index3.js +73 -4
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index33.js +14 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index34.js +24 -2
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index35.js +1 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index36.js +24 -1
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index38.js +145 -6
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index39.js +10 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index40.js +8 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index41.js +93 -4
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index43.js +1 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index44.js +7 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index45.js +30 -2
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index46.js +1 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index47.js +13 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index48.js +88 -5
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index7.js +62 -5
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index9.js +7 -0
- package/dist/libs/tesouro-embedded-components-react/cards-widget/feature/dist/index4.js +2 -2
- package/dist/libs/tesouro-embedded-components-react/counterparts-widget/feature/dist/index4.js +13 -13
- package/dist/libs/tesouro-embedded-components-react/counterparts-widget/feature/dist/index7.js +58 -58
- package/dist/libs/tesouro-embedded-components-react/counterparts-widget/feature/dist/index8.js +19 -19
- package/dist/libs/tesouro-embedded-components-react/gl-code-table-widget/feature/dist/index7.js +1 -1
- package/dist/libs/tesouro-embedded-components-react/insights-widget/feature/dist/index.js +2 -2
- package/dist/libs/tesouro-embedded-components-react/insights-widget/feature/dist/index10.js +13 -62
- package/dist/libs/tesouro-embedded-components-react/insights-widget/feature/dist/index11.js +66 -0
- package/dist/libs/tesouro-embedded-components-react/insights-widget/feature/dist/index7.js +11 -109
- package/dist/libs/tesouro-embedded-components-react/insights-widget/feature/dist/index8.js +113 -21
- package/dist/libs/tesouro-embedded-components-react/insights-widget/feature/dist/index9.js +21 -15
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/feature/dist/index7.js +1 -1
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/feature/dist/index9.js +2 -2
- package/dist/libs/tesouro-embedded-components-react/linked-accounts-widget/feature/dist/index8.js +3 -3
- package/dist/libs/tesouro-embedded-components-react/profile-widget/feature/dist/index4.js +1 -1
- package/dist/libs/tesouro-embedded-components-react/shared/approval-policy/feature/dist/lib/policyViewModel.js +1 -1
- package/dist/libs/tesouro-embedded-components-react/shared/counterpart-management/feature/dist/index.js +15 -15
- package/dist/libs/tesouro-embedded-components-react/shared/counterpart-management/feature/dist/lib/helpers.js +9 -9
- package/dist/libs/tesouro-embedded-components-react/shared/counterpart-management/feature/dist/lib/useAddressForm.js +1 -1
- package/dist/libs/tesouro-embedded-components-react/shared/counterpart-management/feature/dist/lib/useCounterpartForm.js +32 -29
- package/dist/libs/tesouro-embedded-components-react/shared/counterpart-management/feature/dist/lib/useSubEntityForm.js +1 -1
- package/dist/libs/tesouro-embedded-components-react/shared/counterpart-management/ui/dist/index.js +7 -7
- package/dist/libs/tesouro-embedded-components-react/shared/counterpart-management/ui/dist/index8.js +232 -220
- package/dist/libs/tesouro-embedded-components-react/shared/data-access/dist/index.js +19 -19
- package/dist/libs/tesouro-embedded-components-react/shared/data-access/dist/lib/rest/@tanstack/react-query.gen.js +171 -138
- package/dist/libs/tesouro-embedded-components-react/shared/data-access/dist/lib/rest/client/index.js +1 -0
- package/dist/libs/tesouro-embedded-components-react/shared/data-access/dist/lib/rest/core/bodySerializer.gen.js +9 -2
- package/dist/libs/tesouro-embedded-components-react/shared/data-access/dist/lib/rest/sdk.gen.js +404 -293
- package/dist/libs/tesouro-embedded-components-react/shared/feature/dist/lib/WidgetProvider/WidgetTokenRefreshProvider.js +1 -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/product-catalog/feature/dist/index.js +1 -1
- package/dist/libs/tesouro-embedded-components-react/shared/product-catalog/feature/dist/lib/MeasureUnitsManagerContainer.js +1 -1
- package/dist/libs/tesouro-embedded-components-react/shared/product-catalog/feature/dist/lib/useProductForm.js +1 -1
- package/dist/libs/tesouro-embedded-components-react/shared/util/dist/{index3.js → lib/amountOutputToMajorUnits.js} +1 -1
- package/dist/libs/tesouro-embedded-components-react/shared/util/dist/{index14.js → lib/apiErrors.js} +1 -1
- package/dist/libs/tesouro-embedded-components-react/shared/util/dist/{index2.js → lib/coerceAmountValueToMinorUnits.js} +1 -1
- package/dist/libs/tesouro-embedded-components-react/shared/util/dist/lib/formatCalendarDate.js +13 -0
- package/dist/libs/tesouro-embedded-components-react/shared/util/dist/{index4.js → lib/formatMoneyExact.js} +1 -1
- package/dist/libs/tesouro-embedded-components-react/shared/util/dist/{index5.js → lib/formatPhoneDisplay.js} +1 -1
- package/dist/libs/tesouro-embedded-components-react/shared/util/dist/{index6.js → lib/getInitials.js} +1 -1
- package/dist/libs/tesouro-embedded-components-react/shared/util/dist/{index7.js → lib/normalizeAmountOutputCurrencyCode.js} +1 -1
- package/dist/libs/tesouro-embedded-components-react/shared/util/dist/{index8.js → lib/parseAmountOutputMajorUnits.js} +1 -1
- package/dist/libs/tesouro-embedded-components-react/shared/util/dist/{index9.js → lib/parseDecimalAmountToMinorUnits.js} +2 -2
- package/dist/libs/tesouro-embedded-components-react/shared/util/dist/{index10.js → lib/sumAmountOutputsMajorUnits.js} +3 -3
- package/dist/libs/tesouro-embedded-components-react/shared/util/dist/{index11.js → lib/usStates.js} +1 -1
- package/dist/libs/tesouro-embedded-components-react/shared/util/dist/{index13.js → lib/widgetDomEvents.js} +1 -1
- package/dist/libs/tesouro-embedded-components-react/shared/util/dist/{index12.js → lib/widgetTokenManager.js} +1 -1
- package/dist/libs/tesouro-embedded-components-react/tags-widget/feature/dist/index8.js +1 -1
- package/dist/libs/tesouro-embedded-components-react/team-widget/feature/dist/index11.js +1 -1
- package/dist/libs/tesouro-embedded-components-react/team-widget/feature/dist/index4.js +1 -1
- package/dist/libs/tesouro-embedded-components-react/transfers-widget/feature/dist/index4.js +4 -4
- package/dist/libs/tesouro-embedded-components-react/transfers-widget/feature/dist/index5.js +1 -1
- package/dist/packages/shared-ui-shadcn/dist/index.js +3593 -3582
- package/package.json +1 -1
package/dist/libs/tesouro-embedded-components-react/shared/counterpart-management/ui/dist/index8.js
CHANGED
|
@@ -7,55 +7,66 @@ import { FormSheet as l } from "./index7.js";
|
|
|
7
7
|
import { useId as u } from "react";
|
|
8
8
|
import { Fragment as d, jsx as f, jsxs as p } from "react/jsx-runtime";
|
|
9
9
|
//#region ../../libs/tesouro-embedded-components-react/shared/counterpart-management/ui/dist/index8.js
|
|
10
|
-
|
|
11
|
-
|
|
10
|
+
var m = {
|
|
11
|
+
entityType: !0,
|
|
12
|
+
profileHeading: !0,
|
|
13
|
+
addressHeading: !0,
|
|
14
|
+
taxId: !0,
|
|
15
|
+
address: !0,
|
|
16
|
+
bankAccount: !0
|
|
17
|
+
};
|
|
18
|
+
function h({ open: h, onOpenChange: g, mode: _, counterpartMode: v = "customer", values: y, errors: b, stateOptions: x, inProgress: S, submitDisabled: C, onChange: w, onAddressChange: T, onBankAccountChange: E, onSubmit: D, onCancel: O, sections: k, labels: A }) {
|
|
19
|
+
let j = {
|
|
12
20
|
...a,
|
|
13
|
-
...
|
|
14
|
-
},
|
|
21
|
+
...A
|
|
22
|
+
}, M = {
|
|
23
|
+
...m,
|
|
24
|
+
...k
|
|
25
|
+
}, N = u(), P = y.entityType === "organization", F = v === "customer", I = v === "vendor", L = _ === "edit" ? F ? j.editTitleCustomer : j.editTitleVendor : F ? j.createTitleCustomer : j.createTitleVendor, R = _ === "create" ? F ? j.createDescriptionCustomer : j.createDescriptionVendor : void 0, z = F ? j.customerTypeHeading : j.vendorTypeHeading, B = F ? j.customerTaxIdHelp : j.vendorTaxIdHelp;
|
|
15
26
|
return /* @__PURE__ */ p(l, {
|
|
16
|
-
open:
|
|
17
|
-
onOpenChange:
|
|
18
|
-
title:
|
|
19
|
-
description:
|
|
20
|
-
formError:
|
|
21
|
-
inProgress:
|
|
22
|
-
submitDisabled:
|
|
23
|
-
submitLabel:
|
|
24
|
-
cancelLabel:
|
|
25
|
-
onSubmit:
|
|
26
|
-
onCancel:
|
|
27
|
+
open: h,
|
|
28
|
+
onOpenChange: g,
|
|
29
|
+
title: L,
|
|
30
|
+
description: R,
|
|
31
|
+
formError: b?.form,
|
|
32
|
+
inProgress: S,
|
|
33
|
+
submitDisabled: C,
|
|
34
|
+
submitLabel: _ === "edit" ? j.saveButton : j.createButton,
|
|
35
|
+
cancelLabel: j.cancelButton,
|
|
36
|
+
onSubmit: D,
|
|
37
|
+
onCancel: O,
|
|
27
38
|
children: [
|
|
28
|
-
|
|
29
|
-
value:
|
|
30
|
-
onChange: (e) =>
|
|
39
|
+
_ === "create" && /* @__PURE__ */ f(c, {
|
|
40
|
+
value: y.entityType,
|
|
41
|
+
onChange: (e) => w({ entityType: e }),
|
|
31
42
|
labels: {
|
|
32
|
-
heading:
|
|
33
|
-
organization:
|
|
34
|
-
organizationHint:
|
|
35
|
-
individual:
|
|
36
|
-
individualHint:
|
|
43
|
+
heading: z,
|
|
44
|
+
organization: j.businessTypeOption,
|
|
45
|
+
organizationHint: j.businessTypeHint,
|
|
46
|
+
individual: j.personTypeOption,
|
|
47
|
+
individualHint: j.personTypeHint
|
|
37
48
|
}
|
|
38
49
|
}),
|
|
39
|
-
/* @__PURE__ */ f(i, {
|
|
50
|
+
M.profileHeading && /* @__PURE__ */ f(i, {
|
|
40
51
|
variant: "body2",
|
|
41
52
|
className: "ttw:font-semibold",
|
|
42
|
-
children:
|
|
53
|
+
children: j.profileHeading
|
|
43
54
|
}),
|
|
44
|
-
|
|
55
|
+
P ? /* @__PURE__ */ p("div", {
|
|
45
56
|
className: "ttw:flex ttw:flex-col ttw:gap-1.5",
|
|
46
57
|
children: [
|
|
47
58
|
/* @__PURE__ */ f(n, {
|
|
48
|
-
htmlFor: `${
|
|
49
|
-
children:
|
|
59
|
+
htmlFor: `${N}-legal-name`,
|
|
60
|
+
children: j.businessNameLabel
|
|
50
61
|
}),
|
|
51
62
|
/* @__PURE__ */ f(t, {
|
|
52
|
-
id: `${
|
|
63
|
+
id: `${N}-legal-name`,
|
|
53
64
|
autoFocus: !0,
|
|
54
|
-
value:
|
|
55
|
-
"aria-invalid": !!
|
|
56
|
-
onChange: (e) =>
|
|
65
|
+
value: y.legalName,
|
|
66
|
+
"aria-invalid": !!b?.legalName,
|
|
67
|
+
onChange: (e) => w({ legalName: e.target.value })
|
|
57
68
|
}),
|
|
58
|
-
/* @__PURE__ */ f(o, { message:
|
|
69
|
+
/* @__PURE__ */ f(o, { message: b?.legalName })
|
|
59
70
|
]
|
|
60
71
|
}) : /* @__PURE__ */ p("div", {
|
|
61
72
|
className: "ttw:grid ttw:grid-cols-2 ttw:gap-4",
|
|
@@ -63,44 +74,44 @@ function m({ open: m, onOpenChange: h, mode: g, counterpartMode: _ = "customer",
|
|
|
63
74
|
className: "ttw:flex ttw:flex-col ttw:gap-1.5",
|
|
64
75
|
children: [
|
|
65
76
|
/* @__PURE__ */ f(n, {
|
|
66
|
-
htmlFor: `${
|
|
67
|
-
children:
|
|
77
|
+
htmlFor: `${N}-first-name`,
|
|
78
|
+
children: j.firstNameLabel
|
|
68
79
|
}),
|
|
69
80
|
/* @__PURE__ */ f(t, {
|
|
70
|
-
id: `${
|
|
81
|
+
id: `${N}-first-name`,
|
|
71
82
|
autoFocus: !0,
|
|
72
|
-
value:
|
|
73
|
-
"aria-invalid": !!
|
|
74
|
-
onChange: (e) =>
|
|
83
|
+
value: y.firstName,
|
|
84
|
+
"aria-invalid": !!b?.firstName,
|
|
85
|
+
onChange: (e) => w({ firstName: e.target.value })
|
|
75
86
|
}),
|
|
76
|
-
/* @__PURE__ */ f(o, { message:
|
|
87
|
+
/* @__PURE__ */ f(o, { message: b?.firstName })
|
|
77
88
|
]
|
|
78
89
|
}), /* @__PURE__ */ p("div", {
|
|
79
90
|
className: "ttw:flex ttw:flex-col ttw:gap-1.5",
|
|
80
91
|
children: [
|
|
81
92
|
/* @__PURE__ */ f(n, {
|
|
82
|
-
htmlFor: `${
|
|
83
|
-
children:
|
|
93
|
+
htmlFor: `${N}-last-name`,
|
|
94
|
+
children: j.lastNameLabel
|
|
84
95
|
}),
|
|
85
96
|
/* @__PURE__ */ f(t, {
|
|
86
|
-
id: `${
|
|
87
|
-
value:
|
|
88
|
-
"aria-invalid": !!
|
|
89
|
-
onChange: (e) =>
|
|
97
|
+
id: `${N}-last-name`,
|
|
98
|
+
value: y.lastName,
|
|
99
|
+
"aria-invalid": !!b?.lastName,
|
|
100
|
+
onChange: (e) => w({ lastName: e.target.value })
|
|
90
101
|
}),
|
|
91
|
-
/* @__PURE__ */ f(o, { message:
|
|
102
|
+
/* @__PURE__ */ f(o, { message: b?.lastName })
|
|
92
103
|
]
|
|
93
104
|
})]
|
|
94
105
|
}),
|
|
95
|
-
!
|
|
106
|
+
!P && /* @__PURE__ */ p("div", {
|
|
96
107
|
className: "ttw:flex ttw:flex-col ttw:gap-1.5",
|
|
97
108
|
children: [/* @__PURE__ */ f(n, {
|
|
98
|
-
htmlFor: `${
|
|
99
|
-
children:
|
|
109
|
+
htmlFor: `${N}-title`,
|
|
110
|
+
children: j.titleLabel
|
|
100
111
|
}), /* @__PURE__ */ f(t, {
|
|
101
|
-
id: `${
|
|
102
|
-
value:
|
|
103
|
-
onChange: (e) =>
|
|
112
|
+
id: `${N}-title`,
|
|
113
|
+
value: y.title,
|
|
114
|
+
onChange: (e) => w({ title: e.target.value })
|
|
104
115
|
})]
|
|
105
116
|
}),
|
|
106
117
|
/* @__PURE__ */ p("div", {
|
|
@@ -109,115 +120,114 @@ function m({ open: m, onOpenChange: h, mode: g, counterpartMode: _ = "customer",
|
|
|
109
120
|
className: "ttw:flex ttw:flex-col ttw:gap-1.5",
|
|
110
121
|
children: [
|
|
111
122
|
/* @__PURE__ */ f(n, {
|
|
112
|
-
htmlFor: `${
|
|
113
|
-
children:
|
|
123
|
+
htmlFor: `${N}-email`,
|
|
124
|
+
children: j.emailLabel
|
|
114
125
|
}),
|
|
115
126
|
/* @__PURE__ */ f(t, {
|
|
116
|
-
id: `${
|
|
127
|
+
id: `${N}-email`,
|
|
117
128
|
type: "email",
|
|
118
|
-
value:
|
|
119
|
-
"aria-invalid": !!
|
|
120
|
-
onChange: (e) =>
|
|
129
|
+
value: y.email,
|
|
130
|
+
"aria-invalid": !!b?.email,
|
|
131
|
+
onChange: (e) => w({ email: e.target.value })
|
|
121
132
|
}),
|
|
122
|
-
/* @__PURE__ */ f(o, { message:
|
|
133
|
+
/* @__PURE__ */ f(o, { message: b?.email })
|
|
123
134
|
]
|
|
124
135
|
}), /* @__PURE__ */ p("div", {
|
|
125
136
|
className: "ttw:flex ttw:flex-col ttw:gap-1.5",
|
|
126
137
|
children: [/* @__PURE__ */ f(n, {
|
|
127
|
-
htmlFor: `${
|
|
128
|
-
children:
|
|
138
|
+
htmlFor: `${N}-phone`,
|
|
139
|
+
children: j.phoneLabel
|
|
129
140
|
}), /* @__PURE__ */ f(t, {
|
|
130
|
-
id: `${
|
|
131
|
-
value:
|
|
132
|
-
onChange: (e) =>
|
|
141
|
+
id: `${N}-phone`,
|
|
142
|
+
value: y.phone,
|
|
143
|
+
onChange: (e) => w({ phone: e.target.value })
|
|
133
144
|
})]
|
|
134
145
|
})]
|
|
135
146
|
}),
|
|
136
|
-
/* @__PURE__ */ p("div", {
|
|
147
|
+
M.taxId && /* @__PURE__ */ p("div", {
|
|
137
148
|
className: "ttw:flex ttw:flex-col ttw:gap-1.5",
|
|
138
149
|
children: [
|
|
139
150
|
/* @__PURE__ */ f(n, {
|
|
140
|
-
htmlFor: `${
|
|
141
|
-
children:
|
|
151
|
+
htmlFor: `${N}-tax-id`,
|
|
152
|
+
children: j.taxIdLabel
|
|
142
153
|
}),
|
|
143
154
|
/* @__PURE__ */ f(t, {
|
|
144
|
-
id: `${
|
|
145
|
-
value:
|
|
146
|
-
onChange: (e) =>
|
|
155
|
+
id: `${N}-tax-id`,
|
|
156
|
+
value: y.taxId,
|
|
157
|
+
onChange: (e) => w({ taxId: e.target.value })
|
|
147
158
|
}),
|
|
148
159
|
/* @__PURE__ */ f(i, {
|
|
149
160
|
variant: "caption",
|
|
150
161
|
className: "ttw:text-muted-foreground",
|
|
151
|
-
children:
|
|
162
|
+
children: B
|
|
152
163
|
})
|
|
153
164
|
]
|
|
154
165
|
}),
|
|
155
|
-
|
|
156
|
-
htmlFor: `${
|
|
166
|
+
F && /* @__PURE__ */ p(n, {
|
|
167
|
+
htmlFor: `${N}-reminders`,
|
|
157
168
|
className: "ttw:flex ttw:items-start ttw:gap-3 ttw:rounded-md ttw:border ttw:p-3",
|
|
158
169
|
children: [/* @__PURE__ */ f(e, {
|
|
159
|
-
id: `${
|
|
160
|
-
checked:
|
|
161
|
-
onCheckedChange: (e) =>
|
|
170
|
+
id: `${N}-reminders`,
|
|
171
|
+
checked: y.remindersEnabled,
|
|
172
|
+
onCheckedChange: (e) => w({ remindersEnabled: e === !0 })
|
|
162
173
|
}), /* @__PURE__ */ p("span", {
|
|
163
174
|
className: "ttw:flex ttw:flex-col ttw:gap-0.5",
|
|
164
175
|
children: [/* @__PURE__ */ f("span", {
|
|
165
176
|
className: "ttw:text-sm ttw:font-medium",
|
|
166
|
-
children:
|
|
177
|
+
children: j.paymentRemindersLabel
|
|
167
178
|
}), /* @__PURE__ */ f("span", {
|
|
168
179
|
className: "ttw:text-sm ttw:text-muted-foreground",
|
|
169
|
-
children:
|
|
180
|
+
children: j.paymentRemindersDescription
|
|
170
181
|
})]
|
|
171
182
|
})]
|
|
172
183
|
}),
|
|
173
|
-
/* @__PURE__ */ f(r, { className: "ttw:my-1" }),
|
|
174
|
-
/* @__PURE__ */ p(d, { children: [/* @__PURE__ */ p("div", {
|
|
184
|
+
M.address && /* @__PURE__ */ p(d, { children: [M.addressHeading && /* @__PURE__ */ p(d, { children: [/* @__PURE__ */ f(r, { className: "ttw:my-1" }), /* @__PURE__ */ p("div", {
|
|
175
185
|
className: "ttw:flex ttw:flex-col ttw:gap-1",
|
|
176
186
|
children: [/* @__PURE__ */ f(i, {
|
|
177
187
|
variant: "body2",
|
|
178
188
|
className: "ttw:font-semibold",
|
|
179
|
-
children:
|
|
180
|
-
}),
|
|
189
|
+
children: j.addressHeading
|
|
190
|
+
}), F && /* @__PURE__ */ f(i, {
|
|
181
191
|
variant: "body2",
|
|
182
192
|
className: "ttw:text-muted-foreground",
|
|
183
|
-
children:
|
|
193
|
+
children: j.customerAddressDescription
|
|
184
194
|
})]
|
|
185
|
-
}), /* @__PURE__ */ f(s, {
|
|
186
|
-
idPrefix: `${
|
|
187
|
-
values:
|
|
188
|
-
errors:
|
|
189
|
-
stateOptions:
|
|
190
|
-
onChange:
|
|
191
|
-
labels:
|
|
195
|
+
})] }), /* @__PURE__ */ f(s, {
|
|
196
|
+
idPrefix: `${N}-address`,
|
|
197
|
+
values: y.address,
|
|
198
|
+
errors: b?.address,
|
|
199
|
+
stateOptions: x,
|
|
200
|
+
onChange: T,
|
|
201
|
+
labels: j.address
|
|
192
202
|
})] }),
|
|
193
|
-
|
|
203
|
+
_ === "create" && I && M.bankAccount && /* @__PURE__ */ p(d, { children: [
|
|
194
204
|
/* @__PURE__ */ f(r, { className: "ttw:my-1" }),
|
|
195
205
|
/* @__PURE__ */ p("div", {
|
|
196
206
|
className: "ttw:flex ttw:flex-col ttw:gap-1",
|
|
197
207
|
children: [/* @__PURE__ */ f(i, {
|
|
198
208
|
variant: "body2",
|
|
199
209
|
className: "ttw:font-semibold",
|
|
200
|
-
children:
|
|
210
|
+
children: j.paymentMethodsHeading
|
|
201
211
|
}), /* @__PURE__ */ f(i, {
|
|
202
212
|
variant: "body2",
|
|
203
213
|
className: "ttw:text-muted-foreground",
|
|
204
|
-
children:
|
|
214
|
+
children: j.paymentMethodsDescription
|
|
205
215
|
})]
|
|
206
216
|
}),
|
|
207
217
|
/* @__PURE__ */ p("div", {
|
|
208
218
|
className: "ttw:flex ttw:flex-col ttw:gap-1.5",
|
|
209
219
|
children: [
|
|
210
220
|
/* @__PURE__ */ f(n, {
|
|
211
|
-
htmlFor: `${
|
|
212
|
-
children:
|
|
221
|
+
htmlFor: `${N}-account-holder`,
|
|
222
|
+
children: j.accountHolderNameLabel
|
|
213
223
|
}),
|
|
214
224
|
/* @__PURE__ */ f(t, {
|
|
215
|
-
id: `${
|
|
216
|
-
value:
|
|
217
|
-
"aria-invalid": !!
|
|
218
|
-
onChange: (e) =>
|
|
225
|
+
id: `${N}-account-holder`,
|
|
226
|
+
value: y.bankAccount.accountHolderName,
|
|
227
|
+
"aria-invalid": !!b?.bankAccount?.accountHolderName,
|
|
228
|
+
onChange: (e) => E?.({ accountHolderName: e.target.value })
|
|
219
229
|
}),
|
|
220
|
-
/* @__PURE__ */ f(o, { message:
|
|
230
|
+
/* @__PURE__ */ f(o, { message: b?.bankAccount?.accountHolderName })
|
|
221
231
|
]
|
|
222
232
|
}),
|
|
223
233
|
/* @__PURE__ */ p("div", {
|
|
@@ -226,31 +236,31 @@ function m({ open: m, onOpenChange: h, mode: g, counterpartMode: _ = "customer",
|
|
|
226
236
|
className: "ttw:flex ttw:flex-col ttw:gap-1.5",
|
|
227
237
|
children: [
|
|
228
238
|
/* @__PURE__ */ f(n, {
|
|
229
|
-
htmlFor: `${
|
|
230
|
-
children:
|
|
239
|
+
htmlFor: `${N}-routing-number`,
|
|
240
|
+
children: j.routingNumberLabel
|
|
231
241
|
}),
|
|
232
242
|
/* @__PURE__ */ f(t, {
|
|
233
|
-
id: `${
|
|
234
|
-
value:
|
|
235
|
-
"aria-invalid": !!
|
|
236
|
-
onChange: (e) =>
|
|
243
|
+
id: `${N}-routing-number`,
|
|
244
|
+
value: y.bankAccount.routingNumber,
|
|
245
|
+
"aria-invalid": !!b?.bankAccount?.routingNumber,
|
|
246
|
+
onChange: (e) => E?.({ routingNumber: e.target.value })
|
|
237
247
|
}),
|
|
238
|
-
/* @__PURE__ */ f(o, { message:
|
|
248
|
+
/* @__PURE__ */ f(o, { message: b?.bankAccount?.routingNumber })
|
|
239
249
|
]
|
|
240
250
|
}), /* @__PURE__ */ p("div", {
|
|
241
251
|
className: "ttw:flex ttw:flex-col ttw:gap-1.5",
|
|
242
252
|
children: [
|
|
243
253
|
/* @__PURE__ */ f(n, {
|
|
244
|
-
htmlFor: `${
|
|
245
|
-
children:
|
|
254
|
+
htmlFor: `${N}-account-number`,
|
|
255
|
+
children: j.accountNumberLabel
|
|
246
256
|
}),
|
|
247
257
|
/* @__PURE__ */ f(t, {
|
|
248
|
-
id: `${
|
|
249
|
-
value:
|
|
250
|
-
"aria-invalid": !!
|
|
251
|
-
onChange: (e) =>
|
|
258
|
+
id: `${N}-account-number`,
|
|
259
|
+
value: y.bankAccount.accountNumber,
|
|
260
|
+
"aria-invalid": !!b?.bankAccount?.accountNumber,
|
|
261
|
+
onChange: (e) => E?.({ accountNumber: e.target.value })
|
|
252
262
|
}),
|
|
253
|
-
/* @__PURE__ */ f(o, { message:
|
|
263
|
+
/* @__PURE__ */ f(o, { message: b?.bankAccount?.accountNumber })
|
|
254
264
|
]
|
|
255
265
|
})]
|
|
256
266
|
})
|
|
@@ -258,43 +268,46 @@ function m({ open: m, onOpenChange: h, mode: g, counterpartMode: _ = "customer",
|
|
|
258
268
|
]
|
|
259
269
|
});
|
|
260
270
|
}
|
|
261
|
-
function
|
|
262
|
-
let
|
|
271
|
+
function g({ mode: l, counterpartMode: h = "customer", values: g, errors: _, stateOptions: v, onChange: y, onAddressChange: b, onBankAccountChange: x, sections: S, labels: C }) {
|
|
272
|
+
let w = {
|
|
263
273
|
...a,
|
|
264
|
-
...
|
|
265
|
-
},
|
|
274
|
+
...C
|
|
275
|
+
}, T = {
|
|
276
|
+
...m,
|
|
277
|
+
...S
|
|
278
|
+
}, E = u(), D = g.entityType === "organization", O = h === "customer", k = h === "vendor", A = O ? w.customerTypeHeading : w.vendorTypeHeading, j = O ? w.customerTaxIdHelp : w.vendorTaxIdHelp;
|
|
266
279
|
return /* @__PURE__ */ p(d, { children: [
|
|
267
|
-
l === "create" && /* @__PURE__ */ f(c, {
|
|
268
|
-
value:
|
|
269
|
-
onChange: (e) =>
|
|
280
|
+
l === "create" && T.entityType && /* @__PURE__ */ f(c, {
|
|
281
|
+
value: g.entityType,
|
|
282
|
+
onChange: (e) => y({ entityType: e }),
|
|
270
283
|
labels: {
|
|
271
|
-
heading:
|
|
272
|
-
organization:
|
|
273
|
-
organizationHint:
|
|
274
|
-
individual:
|
|
275
|
-
individualHint:
|
|
284
|
+
heading: A,
|
|
285
|
+
organization: w.businessTypeOption,
|
|
286
|
+
organizationHint: w.businessTypeHint,
|
|
287
|
+
individual: w.personTypeOption,
|
|
288
|
+
individualHint: w.personTypeHint
|
|
276
289
|
}
|
|
277
290
|
}),
|
|
278
|
-
/* @__PURE__ */ f(i, {
|
|
291
|
+
T.profileHeading && /* @__PURE__ */ f(i, {
|
|
279
292
|
variant: "body2",
|
|
280
293
|
className: "ttw:font-semibold",
|
|
281
|
-
children:
|
|
294
|
+
children: w.profileHeading
|
|
282
295
|
}),
|
|
283
|
-
|
|
296
|
+
D ? /* @__PURE__ */ p("div", {
|
|
284
297
|
className: "ttw:flex ttw:flex-col ttw:gap-1.5",
|
|
285
298
|
children: [
|
|
286
299
|
/* @__PURE__ */ f(n, {
|
|
287
|
-
htmlFor: `${
|
|
288
|
-
children:
|
|
300
|
+
htmlFor: `${E}-legal-name`,
|
|
301
|
+
children: w.businessNameLabel
|
|
289
302
|
}),
|
|
290
303
|
/* @__PURE__ */ f(t, {
|
|
291
|
-
id: `${
|
|
304
|
+
id: `${E}-legal-name`,
|
|
292
305
|
autoFocus: !0,
|
|
293
|
-
value:
|
|
294
|
-
"aria-invalid": !!
|
|
295
|
-
onChange: (e) =>
|
|
306
|
+
value: g.legalName,
|
|
307
|
+
"aria-invalid": !!_?.legalName,
|
|
308
|
+
onChange: (e) => y({ legalName: e.target.value })
|
|
296
309
|
}),
|
|
297
|
-
/* @__PURE__ */ f(o, { message:
|
|
310
|
+
/* @__PURE__ */ f(o, { message: _?.legalName })
|
|
298
311
|
]
|
|
299
312
|
}) : /* @__PURE__ */ p("div", {
|
|
300
313
|
className: "ttw:grid ttw:grid-cols-2 ttw:gap-4",
|
|
@@ -302,44 +315,44 @@ function h({ mode: l, counterpartMode: m = "customer", values: h, errors: g, sta
|
|
|
302
315
|
className: "ttw:flex ttw:flex-col ttw:gap-1.5",
|
|
303
316
|
children: [
|
|
304
317
|
/* @__PURE__ */ f(n, {
|
|
305
|
-
htmlFor: `${
|
|
306
|
-
children:
|
|
318
|
+
htmlFor: `${E}-first-name`,
|
|
319
|
+
children: w.firstNameLabel
|
|
307
320
|
}),
|
|
308
321
|
/* @__PURE__ */ f(t, {
|
|
309
|
-
id: `${
|
|
322
|
+
id: `${E}-first-name`,
|
|
310
323
|
autoFocus: !0,
|
|
311
|
-
value:
|
|
312
|
-
"aria-invalid": !!
|
|
313
|
-
onChange: (e) =>
|
|
324
|
+
value: g.firstName,
|
|
325
|
+
"aria-invalid": !!_?.firstName,
|
|
326
|
+
onChange: (e) => y({ firstName: e.target.value })
|
|
314
327
|
}),
|
|
315
|
-
/* @__PURE__ */ f(o, { message:
|
|
328
|
+
/* @__PURE__ */ f(o, { message: _?.firstName })
|
|
316
329
|
]
|
|
317
330
|
}), /* @__PURE__ */ p("div", {
|
|
318
331
|
className: "ttw:flex ttw:flex-col ttw:gap-1.5",
|
|
319
332
|
children: [
|
|
320
333
|
/* @__PURE__ */ f(n, {
|
|
321
|
-
htmlFor: `${
|
|
322
|
-
children:
|
|
334
|
+
htmlFor: `${E}-last-name`,
|
|
335
|
+
children: w.lastNameLabel
|
|
323
336
|
}),
|
|
324
337
|
/* @__PURE__ */ f(t, {
|
|
325
|
-
id: `${
|
|
326
|
-
value:
|
|
327
|
-
"aria-invalid": !!
|
|
328
|
-
onChange: (e) =>
|
|
338
|
+
id: `${E}-last-name`,
|
|
339
|
+
value: g.lastName,
|
|
340
|
+
"aria-invalid": !!_?.lastName,
|
|
341
|
+
onChange: (e) => y({ lastName: e.target.value })
|
|
329
342
|
}),
|
|
330
|
-
/* @__PURE__ */ f(o, { message:
|
|
343
|
+
/* @__PURE__ */ f(o, { message: _?.lastName })
|
|
331
344
|
]
|
|
332
345
|
})]
|
|
333
346
|
}),
|
|
334
|
-
!
|
|
347
|
+
!D && /* @__PURE__ */ p("div", {
|
|
335
348
|
className: "ttw:flex ttw:flex-col ttw:gap-1.5",
|
|
336
349
|
children: [/* @__PURE__ */ f(n, {
|
|
337
|
-
htmlFor: `${
|
|
338
|
-
children:
|
|
350
|
+
htmlFor: `${E}-title`,
|
|
351
|
+
children: w.titleLabel
|
|
339
352
|
}), /* @__PURE__ */ f(t, {
|
|
340
|
-
id: `${
|
|
341
|
-
value:
|
|
342
|
-
onChange: (e) =>
|
|
353
|
+
id: `${E}-title`,
|
|
354
|
+
value: g.title,
|
|
355
|
+
onChange: (e) => y({ title: e.target.value })
|
|
343
356
|
})]
|
|
344
357
|
}),
|
|
345
358
|
/* @__PURE__ */ p("div", {
|
|
@@ -348,115 +361,114 @@ function h({ mode: l, counterpartMode: m = "customer", values: h, errors: g, sta
|
|
|
348
361
|
className: "ttw:flex ttw:flex-col ttw:gap-1.5",
|
|
349
362
|
children: [
|
|
350
363
|
/* @__PURE__ */ f(n, {
|
|
351
|
-
htmlFor: `${
|
|
352
|
-
children:
|
|
364
|
+
htmlFor: `${E}-email`,
|
|
365
|
+
children: w.emailLabel
|
|
353
366
|
}),
|
|
354
367
|
/* @__PURE__ */ f(t, {
|
|
355
|
-
id: `${
|
|
368
|
+
id: `${E}-email`,
|
|
356
369
|
type: "email",
|
|
357
|
-
value:
|
|
358
|
-
"aria-invalid": !!
|
|
359
|
-
onChange: (e) =>
|
|
370
|
+
value: g.email,
|
|
371
|
+
"aria-invalid": !!_?.email,
|
|
372
|
+
onChange: (e) => y({ email: e.target.value })
|
|
360
373
|
}),
|
|
361
|
-
/* @__PURE__ */ f(o, { message:
|
|
374
|
+
/* @__PURE__ */ f(o, { message: _?.email })
|
|
362
375
|
]
|
|
363
376
|
}), /* @__PURE__ */ p("div", {
|
|
364
377
|
className: "ttw:flex ttw:flex-col ttw:gap-1.5",
|
|
365
378
|
children: [/* @__PURE__ */ f(n, {
|
|
366
|
-
htmlFor: `${
|
|
367
|
-
children:
|
|
379
|
+
htmlFor: `${E}-phone`,
|
|
380
|
+
children: w.phoneLabel
|
|
368
381
|
}), /* @__PURE__ */ f(t, {
|
|
369
|
-
id: `${
|
|
370
|
-
value:
|
|
371
|
-
onChange: (e) =>
|
|
382
|
+
id: `${E}-phone`,
|
|
383
|
+
value: g.phone,
|
|
384
|
+
onChange: (e) => y({ phone: e.target.value })
|
|
372
385
|
})]
|
|
373
386
|
})]
|
|
374
387
|
}),
|
|
375
|
-
/* @__PURE__ */ p("div", {
|
|
388
|
+
T.taxId && /* @__PURE__ */ p("div", {
|
|
376
389
|
className: "ttw:flex ttw:flex-col ttw:gap-1.5",
|
|
377
390
|
children: [
|
|
378
391
|
/* @__PURE__ */ f(n, {
|
|
379
|
-
htmlFor: `${
|
|
380
|
-
children:
|
|
392
|
+
htmlFor: `${E}-tax-id`,
|
|
393
|
+
children: w.taxIdLabel
|
|
381
394
|
}),
|
|
382
395
|
/* @__PURE__ */ f(t, {
|
|
383
|
-
id: `${
|
|
384
|
-
value:
|
|
385
|
-
onChange: (e) =>
|
|
396
|
+
id: `${E}-tax-id`,
|
|
397
|
+
value: g.taxId,
|
|
398
|
+
onChange: (e) => y({ taxId: e.target.value })
|
|
386
399
|
}),
|
|
387
400
|
/* @__PURE__ */ f(i, {
|
|
388
401
|
variant: "caption",
|
|
389
402
|
className: "ttw:text-muted-foreground",
|
|
390
|
-
children:
|
|
403
|
+
children: j
|
|
391
404
|
})
|
|
392
405
|
]
|
|
393
406
|
}),
|
|
394
|
-
|
|
395
|
-
htmlFor: `${
|
|
407
|
+
O && /* @__PURE__ */ p(n, {
|
|
408
|
+
htmlFor: `${E}-reminders`,
|
|
396
409
|
className: "ttw:flex ttw:items-start ttw:gap-3 ttw:rounded-md ttw:border ttw:p-3",
|
|
397
410
|
children: [/* @__PURE__ */ f(e, {
|
|
398
|
-
id: `${
|
|
399
|
-
checked:
|
|
400
|
-
onCheckedChange: (e) =>
|
|
411
|
+
id: `${E}-reminders`,
|
|
412
|
+
checked: g.remindersEnabled,
|
|
413
|
+
onCheckedChange: (e) => y({ remindersEnabled: e === !0 })
|
|
401
414
|
}), /* @__PURE__ */ p("span", {
|
|
402
415
|
className: "ttw:flex ttw:flex-col ttw:gap-0.5",
|
|
403
416
|
children: [/* @__PURE__ */ f("span", {
|
|
404
417
|
className: "ttw:text-sm ttw:font-medium",
|
|
405
|
-
children:
|
|
418
|
+
children: w.paymentRemindersLabel
|
|
406
419
|
}), /* @__PURE__ */ f("span", {
|
|
407
420
|
className: "ttw:text-sm ttw:text-muted-foreground",
|
|
408
|
-
children:
|
|
421
|
+
children: w.paymentRemindersDescription
|
|
409
422
|
})]
|
|
410
423
|
})]
|
|
411
424
|
}),
|
|
412
|
-
/* @__PURE__ */ f(r, { className: "ttw:my-1" }),
|
|
413
|
-
/* @__PURE__ */ p(d, { children: [/* @__PURE__ */ p("div", {
|
|
425
|
+
T.address && /* @__PURE__ */ p(d, { children: [T.addressHeading && /* @__PURE__ */ p(d, { children: [/* @__PURE__ */ f(r, { className: "ttw:my-1" }), /* @__PURE__ */ p("div", {
|
|
414
426
|
className: "ttw:flex ttw:flex-col ttw:gap-1",
|
|
415
427
|
children: [/* @__PURE__ */ f(i, {
|
|
416
428
|
variant: "body2",
|
|
417
429
|
className: "ttw:font-semibold",
|
|
418
|
-
children:
|
|
419
|
-
}),
|
|
430
|
+
children: w.addressHeading
|
|
431
|
+
}), O && /* @__PURE__ */ f(i, {
|
|
420
432
|
variant: "body2",
|
|
421
433
|
className: "ttw:text-muted-foreground",
|
|
422
|
-
children:
|
|
434
|
+
children: w.customerAddressDescription
|
|
423
435
|
})]
|
|
424
|
-
}), /* @__PURE__ */ f(s, {
|
|
425
|
-
idPrefix: `${
|
|
426
|
-
values:
|
|
427
|
-
errors:
|
|
428
|
-
stateOptions:
|
|
429
|
-
onChange:
|
|
430
|
-
labels:
|
|
436
|
+
})] }), /* @__PURE__ */ f(s, {
|
|
437
|
+
idPrefix: `${E}-address`,
|
|
438
|
+
values: g.address,
|
|
439
|
+
errors: _?.address,
|
|
440
|
+
stateOptions: v,
|
|
441
|
+
onChange: b,
|
|
442
|
+
labels: w.address
|
|
431
443
|
})] }),
|
|
432
|
-
l === "create" &&
|
|
444
|
+
l === "create" && k && T.bankAccount && /* @__PURE__ */ p(d, { children: [
|
|
433
445
|
/* @__PURE__ */ f(r, { className: "ttw:my-1" }),
|
|
434
446
|
/* @__PURE__ */ p("div", {
|
|
435
447
|
className: "ttw:flex ttw:flex-col ttw:gap-1",
|
|
436
448
|
children: [/* @__PURE__ */ f(i, {
|
|
437
449
|
variant: "body2",
|
|
438
450
|
className: "ttw:font-semibold",
|
|
439
|
-
children:
|
|
451
|
+
children: w.paymentMethodsHeading
|
|
440
452
|
}), /* @__PURE__ */ f(i, {
|
|
441
453
|
variant: "body2",
|
|
442
454
|
className: "ttw:text-muted-foreground",
|
|
443
|
-
children:
|
|
455
|
+
children: w.paymentMethodsDescription
|
|
444
456
|
})]
|
|
445
457
|
}),
|
|
446
458
|
/* @__PURE__ */ p("div", {
|
|
447
459
|
className: "ttw:flex ttw:flex-col ttw:gap-1.5",
|
|
448
460
|
children: [
|
|
449
461
|
/* @__PURE__ */ f(n, {
|
|
450
|
-
htmlFor: `${
|
|
451
|
-
children:
|
|
462
|
+
htmlFor: `${E}-account-holder`,
|
|
463
|
+
children: w.accountHolderNameLabel
|
|
452
464
|
}),
|
|
453
465
|
/* @__PURE__ */ f(t, {
|
|
454
|
-
id: `${
|
|
455
|
-
value:
|
|
456
|
-
"aria-invalid": !!
|
|
457
|
-
onChange: (e) =>
|
|
466
|
+
id: `${E}-account-holder`,
|
|
467
|
+
value: g.bankAccount.accountHolderName,
|
|
468
|
+
"aria-invalid": !!_?.bankAccount?.accountHolderName,
|
|
469
|
+
onChange: (e) => x?.({ accountHolderName: e.target.value })
|
|
458
470
|
}),
|
|
459
|
-
/* @__PURE__ */ f(o, { message:
|
|
471
|
+
/* @__PURE__ */ f(o, { message: _?.bankAccount?.accountHolderName })
|
|
460
472
|
]
|
|
461
473
|
}),
|
|
462
474
|
/* @__PURE__ */ p("div", {
|
|
@@ -465,31 +477,31 @@ function h({ mode: l, counterpartMode: m = "customer", values: h, errors: g, sta
|
|
|
465
477
|
className: "ttw:flex ttw:flex-col ttw:gap-1.5",
|
|
466
478
|
children: [
|
|
467
479
|
/* @__PURE__ */ f(n, {
|
|
468
|
-
htmlFor: `${
|
|
469
|
-
children:
|
|
480
|
+
htmlFor: `${E}-routing-number`,
|
|
481
|
+
children: w.routingNumberLabel
|
|
470
482
|
}),
|
|
471
483
|
/* @__PURE__ */ f(t, {
|
|
472
|
-
id: `${
|
|
473
|
-
value:
|
|
474
|
-
"aria-invalid": !!
|
|
475
|
-
onChange: (e) =>
|
|
484
|
+
id: `${E}-routing-number`,
|
|
485
|
+
value: g.bankAccount.routingNumber,
|
|
486
|
+
"aria-invalid": !!_?.bankAccount?.routingNumber,
|
|
487
|
+
onChange: (e) => x?.({ routingNumber: e.target.value })
|
|
476
488
|
}),
|
|
477
|
-
/* @__PURE__ */ f(o, { message:
|
|
489
|
+
/* @__PURE__ */ f(o, { message: _?.bankAccount?.routingNumber })
|
|
478
490
|
]
|
|
479
491
|
}), /* @__PURE__ */ p("div", {
|
|
480
492
|
className: "ttw:flex ttw:flex-col ttw:gap-1.5",
|
|
481
493
|
children: [
|
|
482
494
|
/* @__PURE__ */ f(n, {
|
|
483
|
-
htmlFor: `${
|
|
484
|
-
children:
|
|
495
|
+
htmlFor: `${E}-account-number`,
|
|
496
|
+
children: w.accountNumberLabel
|
|
485
497
|
}),
|
|
486
498
|
/* @__PURE__ */ f(t, {
|
|
487
|
-
id: `${
|
|
488
|
-
value:
|
|
489
|
-
"aria-invalid": !!
|
|
490
|
-
onChange: (e) =>
|
|
499
|
+
id: `${E}-account-number`,
|
|
500
|
+
value: g.bankAccount.accountNumber,
|
|
501
|
+
"aria-invalid": !!_?.bankAccount?.accountNumber,
|
|
502
|
+
onChange: (e) => x?.({ accountNumber: e.target.value })
|
|
491
503
|
}),
|
|
492
|
-
/* @__PURE__ */ f(o, { message:
|
|
504
|
+
/* @__PURE__ */ f(o, { message: _?.bankAccount?.accountNumber })
|
|
493
505
|
]
|
|
494
506
|
})]
|
|
495
507
|
})
|
|
@@ -497,4 +509,4 @@ function h({ mode: l, counterpartMode: m = "customer", values: h, errors: g, sta
|
|
|
497
509
|
] });
|
|
498
510
|
}
|
|
499
511
|
//#endregion
|
|
500
|
-
export {
|
|
512
|
+
export { g as CounterpartFormFields, h as CounterpartFormSheet, h as default };
|