@tesouro/embedded-components-react 0.7.46 → 0.7.47

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.
Files changed (19) hide show
  1. package/dist/index.d.ts +4 -0
  2. package/dist/lib/CounterpartsWidget.d.ts +4 -0
  3. package/dist/lib/CounterpartsWidgetPublic.d.ts +4 -0
  4. package/dist/lib/CustomersWidget.d.ts +2 -0
  5. package/dist/lib/ReceivablesWidget.d.ts +2 -0
  6. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/feature/dist/index31.js +1 -1
  7. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/feature/dist/index32.js +40 -42
  8. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/feature/dist/index33.js +1 -3
  9. package/dist/libs/tesouro-embedded-components-react/counterparts-widget/ui/dist/index2.js +1 -1
  10. package/dist/libs/tesouro-embedded-components-react/counterparts-widget/ui/dist/index3.js +44 -44
  11. package/dist/libs/tesouro-embedded-components-react/shared/counterpart-management/feature/dist/lib/helpers.js +13 -13
  12. package/dist/libs/tesouro-embedded-components-react/shared/counterpart-management/feature/dist/lib/labels.js +1 -1
  13. package/dist/libs/tesouro-embedded-components-react/shared/counterpart-management/feature/dist/lib/useCounterpartForm.js +85 -84
  14. package/dist/libs/tesouro-embedded-components-react/shared/counterpart-management/ui/dist/index10.js +238 -241
  15. package/dist/libs/tesouro-embedded-components-react/shared/counterpart-management/ui/dist/index11.js +2 -0
  16. package/dist/libs/tesouro-embedded-components-react/shared/counterpart-management/ui/dist/index2.js +6 -5
  17. package/dist/libs/tesouro-embedded-components-react/shared/counterpart-management/ui/dist/index5.js +2 -0
  18. package/dist/libs/tesouro-embedded-components-react/shared/feature/dist/lib/analytics/build-info.js +1 -1
  19. package/package.json +1 -1
package/dist/index.d.ts CHANGED
@@ -4340,6 +4340,8 @@ interface AchFieldGroupLabels {
4340
4340
  accountHolderName: string;
4341
4341
  routingNumber: string;
4342
4342
  accountNumber: string;
4343
+ routingNumberPlaceholder: string;
4344
+ accountNumberPlaceholder: string;
4343
4345
  /** The asterisk copy this group's labels carry. */
4344
4346
  fieldMarkers: LabelLabels;
4345
4347
  }
@@ -4414,6 +4416,8 @@ interface BankAccountFormSheetLabels {
4414
4416
  accountHolderNameLabel: string;
4415
4417
  accountNumberLabel: string;
4416
4418
  routingNumberLabel: string;
4419
+ accountNumberPlaceholder: string;
4420
+ routingNumberPlaceholder: string;
4417
4421
  helperText: string;
4418
4422
  cancelButton: string;
4419
4423
  saveButton: string;
@@ -674,6 +674,8 @@ interface AchFieldGroupLabels {
674
674
  accountHolderName: string;
675
675
  routingNumber: string;
676
676
  accountNumber: string;
677
+ routingNumberPlaceholder: string;
678
+ accountNumberPlaceholder: string;
677
679
  /** The asterisk copy this group's labels carry. */
678
680
  fieldMarkers: LabelLabels;
679
681
  }
@@ -748,6 +750,8 @@ interface BankAccountFormSheetLabels {
748
750
  accountHolderNameLabel: string;
749
751
  accountNumberLabel: string;
750
752
  routingNumberLabel: string;
753
+ accountNumberPlaceholder: string;
754
+ routingNumberPlaceholder: string;
751
755
  helperText: string;
752
756
  cancelButton: string;
753
757
  saveButton: string;
@@ -674,6 +674,8 @@ interface AchFieldGroupLabels {
674
674
  accountHolderName: string;
675
675
  routingNumber: string;
676
676
  accountNumber: string;
677
+ routingNumberPlaceholder: string;
678
+ accountNumberPlaceholder: string;
677
679
  /** The asterisk copy this group's labels carry. */
678
680
  fieldMarkers: LabelLabels;
679
681
  }
@@ -748,6 +750,8 @@ interface BankAccountFormSheetLabels {
748
750
  accountHolderNameLabel: string;
749
751
  accountNumberLabel: string;
750
752
  routingNumberLabel: string;
753
+ accountNumberPlaceholder: string;
754
+ routingNumberPlaceholder: string;
751
755
  helperText: string;
752
756
  cancelButton: string;
753
757
  saveButton: string;
@@ -675,6 +675,8 @@ interface AchFieldGroupLabels {
675
675
  accountHolderName: string;
676
676
  routingNumber: string;
677
677
  accountNumber: string;
678
+ routingNumberPlaceholder: string;
679
+ accountNumberPlaceholder: string;
678
680
  /** The asterisk copy this group's labels carry. */
679
681
  fieldMarkers: LabelLabels;
680
682
  }
@@ -763,6 +763,8 @@ interface AchFieldGroupLabels {
763
763
  accountHolderName: string;
764
764
  routingNumber: string;
765
765
  accountNumber: string;
766
+ routingNumberPlaceholder: string;
767
+ accountNumberPlaceholder: string;
766
768
  /** The asterisk copy this group's labels carry. */
767
769
  fieldMarkers: LabelLabels;
768
770
  }
@@ -46,7 +46,7 @@ function c(e) {
46
46
  routingNumber: i(e?.bank_account?.routing_number),
47
47
  accountNumber: i(e?.bank_account?.account_number)
48
48
  }
49
- }, "create", void 0, "vendor"));
49
+ }, void 0, "vendor"));
50
50
  }
51
51
  function l(e, t, n) {
52
52
  let r = (e) => i(e) || void 0, { address: a } = e;
@@ -14,50 +14,50 @@ import "../../../../shared/counterpart-management/feature/dist/index.js";
14
14
  import { useMemo as c } from "react";
15
15
  import { jsx as l, jsxs as u } from "react/jsx-runtime";
16
16
  //#region ../../libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/feature/dist/index32.js
17
- function d({ mode: d, values: f, errors: p, onChange: m, onAddressChange: h, sectionsToExpand: g, onAddressExpand: _, onCancel: v, onSave: y, isSaving: b = !1, search: x, paymentInstructions: S, labels: C }) {
18
- let w = c(() => s(C), [C]), T = c(() => t(), []), E = a(p ?? {}), D = i({
17
+ function d({ mode: d, values: f, errors: p, onChange: m, onAddressChange: h, onCancel: g, onSave: _, isSaving: v = !1, search: y, paymentInstructions: b, labels: x }) {
18
+ let S = c(() => s(x), [x]), C = c(() => t(), []), w = a(p ?? {}), T = i({
19
19
  ...p,
20
20
  form: void 0,
21
21
  bankAccount: void 0
22
- }) + i(S?.errors), O = x?.query.trim() ?? "", k = f.entityType === "individual" ? `${f.firstName} ${f.lastName}`.trim() : f.legalName, A = x && d === "create" ? /* @__PURE__ */ l(o, {
23
- ...x,
24
- onAddVendor: O && O !== k.trim() ? x.onAddVendor : void 0,
25
- selectedLabel: k,
26
- badge: w.newVendorBadge,
27
- helperText: w.unmatchedVendorHelper,
28
- resultsHeading: w.resultsHeading,
29
- addVendorDescription: w.addAsNewVendorDescription,
22
+ }) + i(b?.errors), E = y?.query.trim() ?? "", D = f.entityType === "individual" ? `${f.firstName} ${f.lastName}`.trim() : f.legalName, O = y && d === "create" ? /* @__PURE__ */ l(o, {
23
+ ...y,
24
+ onAddVendor: E && E !== D.trim() ? y.onAddVendor : void 0,
25
+ selectedLabel: D,
26
+ badge: S.newVendorBadge,
27
+ helperText: S.unmatchedVendorHelper,
28
+ resultsHeading: S.resultsHeading,
29
+ addVendorDescription: S.addAsNewVendorDescription,
30
30
  labels: {
31
- fieldLabel: w.vendorFieldLabel,
32
- addVendorAction: w.addAsNewVendor(O)
31
+ fieldLabel: S.vendorFieldLabel,
32
+ addVendorAction: S.addAsNewVendor(E)
33
33
  }
34
34
  }) : null;
35
35
  return /* @__PURE__ */ u("div", {
36
- ref: E,
36
+ ref: w,
37
37
  className: "ttw:flex ttw:flex-col ttw:gap-4",
38
- children: [A, /* @__PURE__ */ u("div", {
38
+ children: [O, /* @__PURE__ */ u("div", {
39
39
  className: "ttw:flex ttw:flex-col ttw:gap-6 ttw:rounded-lg ttw:border ttw:border-primary ttw:bg-surface-subtle ttw:p-6 ttw:[&_[data-slot=input]]:bg-background ttw:[&_[data-slot=select-trigger]]:bg-background",
40
40
  children: [
41
41
  /* @__PURE__ */ u("div", {
42
42
  className: "ttw:flex ttw:items-baseline ttw:justify-between ttw:gap-2",
43
43
  children: [/* @__PURE__ */ l("p", {
44
44
  className: "ttw:text-base ttw:font-semibold ttw:text-foreground",
45
- children: d === "edit" ? w.editTitle : w.createTitle
46
- }), D > 0 ? /* @__PURE__ */ l("p", {
45
+ children: d === "edit" ? S.editTitle : S.createTitle
46
+ }), T > 0 ? /* @__PURE__ */ l("p", {
47
47
  className: "ttw:text-sm ttw:text-destructive",
48
- children: w.fieldsNeedAttention(D)
48
+ children: S.fieldsNeedAttention(T)
49
49
  }) : null]
50
50
  }),
51
- x && d === "edit" ? /* @__PURE__ */ l(o, {
52
- ...x,
53
- labels: { fieldLabel: w.switchVendorFieldLabel }
51
+ y && d === "edit" ? /* @__PURE__ */ l(o, {
52
+ ...y,
53
+ labels: { fieldLabel: S.switchVendorFieldLabel }
54
54
  }) : null,
55
55
  /* @__PURE__ */ l(r, {
56
56
  mode: d,
57
57
  counterpartMode: "vendor",
58
58
  values: f,
59
59
  errors: p,
60
- stateOptions: T,
60
+ stateOptions: C,
61
61
  onChange: m,
62
62
  onAddressChange: h,
63
63
  sections: {
@@ -66,30 +66,28 @@ function d({ mode: d, values: f, errors: p, onChange: m, onAddressChange: h, sec
66
66
  addressHeading: !1,
67
67
  title: !1,
68
68
  taxId: !1,
69
- address: d !== "edit" || "collapsible",
69
+ address: !0,
70
70
  bankAccount: !1
71
71
  },
72
- sectionsToExpand: g,
73
- onAddressExpand: _,
74
- labels: { businessNameLabel: w.nameLabel }
72
+ labels: { businessNameLabel: S.nameLabel }
75
73
  }),
76
- S ? /* @__PURE__ */ u("div", {
74
+ b ? /* @__PURE__ */ u("div", {
77
75
  className: "ttw:flex ttw:flex-col ttw:gap-3",
78
76
  children: [/* @__PURE__ */ u("div", {
79
77
  className: "ttw:flex ttw:flex-col ttw:gap-1",
80
78
  children: [/* @__PURE__ */ l("p", {
81
79
  className: "ttw:text-sm ttw:font-semibold ttw:text-foreground",
82
- children: w.paymentInstructionsHeading
80
+ children: S.paymentInstructionsHeading
83
81
  }), /* @__PURE__ */ l("p", {
84
82
  className: "ttw:text-sm ttw:text-muted-foreground",
85
- children: S.isExtracted ? w.paymentInstructionsExtracted : w.paymentInstructionsDescription
83
+ children: b.isExtracted ? S.paymentInstructionsExtracted : S.paymentInstructionsDescription
86
84
  })]
87
85
  }), /* @__PURE__ */ l(n, {
88
86
  idPrefix: "vendor-inline-ach",
89
- values: S.values,
90
- errors: S.errors,
91
- onChange: S.onChange,
92
- labels: w.ach
87
+ values: b.values,
88
+ errors: b.errors,
89
+ onChange: b.onChange,
90
+ labels: S.ach
93
91
  })]
94
92
  }) : null,
95
93
  /* @__PURE__ */ u("div", {
@@ -97,17 +95,17 @@ function d({ mode: d, values: f, errors: p, onChange: m, onAddressChange: h, sec
97
95
  children: [/* @__PURE__ */ l(e, {
98
96
  type: "button",
99
97
  variant: "outline",
100
- onClick: v,
101
- "aria-label": w.cancelAriaLabel,
102
- disabled: b,
103
- children: w.cancel
104
- }), y ? /* @__PURE__ */ l(e, {
98
+ onClick: g,
99
+ "aria-label": S.cancelAriaLabel,
100
+ disabled: v,
101
+ children: S.cancel
102
+ }), _ ? /* @__PURE__ */ l(e, {
105
103
  type: "button",
106
- onClick: y,
107
- "aria-label": w.saveAriaLabel,
108
- loading: b,
109
- disabled: b,
110
- children: w.save
104
+ onClick: _,
105
+ "aria-label": S.saveAriaLabel,
106
+ loading: v,
107
+ disabled: v,
108
+ children: S.save
111
109
  }) : null]
112
110
  })
113
111
  ]
@@ -227,7 +227,7 @@ function g({ payableId: s, counterpartId: c, payableCounterpartId: g, payableCou
227
227
  let e = j.current, t = le({
228
228
  ...dt,
229
229
  bankAccount: e
230
- }, "create", C, "vendor");
230
+ }, C, "vendor");
231
231
  if (oe(t)) return He || !h(e, B ?? m) ? {
232
232
  ok: !0,
233
233
  counterpartRawData: _e(dt, e, _)
@@ -421,8 +421,6 @@ function g({ payableId: s, counterpartId: c, payableCounterpartId: g, payableCou
421
421
  errors: U.errors,
422
422
  onChange: At,
423
423
  onAddressChange: jt,
424
- sectionsToExpand: U.sectionsToExpand,
425
- onAddressExpand: U.expandAddress,
426
424
  onCancel: Tt,
427
425
  onSave: Dt,
428
426
  isSaving: Ft,
@@ -67,7 +67,7 @@ var i = {
67
67
  recentCustomerDocumentsDescription: "Latest activity",
68
68
  recentVendorDocumentsDescription: "Sorted by issue date",
69
69
  viewAllDocumentsAction: "View all",
70
- subtitleTemplate: "{type} - Added {date}",
70
+ subtitleTemplate: "{type} · Added {date}",
71
71
  customerSubtitleLabel: "Customer",
72
72
  vendorSubtitleLabel: "Vendor",
73
73
  entityTypePersonLabel: "Person",
@@ -4,15 +4,15 @@ import { ErrorState as f } from "../../../shared/ui/dist/lib/ErrorState/ErrorSta
4
4
  import "../../../shared/ui/dist/index.js";
5
5
  import { COUNTERPARTS_SCREEN_LABELS_EN as p } from "./index2.js";
6
6
  import { Fragment as m, jsx as h, jsxs as g } from "react/jsx-runtime";
7
- import { ArrowDownIcon as _, ArrowUpDownIcon as v, ArrowUpIcon as y, ListFilter as b, PlusIcon as x } from "lucide-react";
7
+ import { ArrowDownIcon as _, ArrowUpDownIcon as v, ArrowUpIcon as y, ListFilter as b } from "lucide-react";
8
8
  //#region ../../libs/tesouro-embedded-components-react/counterparts-widget/ui/dist/index3.js
9
- var S = [
9
+ var x = [
10
10
  10,
11
11
  25,
12
12
  50,
13
13
  100
14
14
  ];
15
- function C({ labels: e, filters: t, disabled: u }) {
15
+ function S({ labels: e, filters: t, disabled: u }) {
16
16
  return /* @__PURE__ */ h(n, {
17
17
  className: "ttw:flex-wrap ttw:px-4",
18
18
  searchSlot: /* @__PURE__ */ h(l, {
@@ -72,7 +72,7 @@ function C({ labels: e, filters: t, disabled: u }) {
72
72
  })] })
73
73
  });
74
74
  }
75
- function w({ value: e, isLoading: t, colorClass: n }) {
75
+ function C({ value: e, isLoading: t, colorClass: n }) {
76
76
  return /* @__PURE__ */ h("div", {
77
77
  className: "ttw:flex ttw:justify-end",
78
78
  children: t ? /* @__PURE__ */ h(u, { className: "ttw:h-4 ttw:w-20" }) : /* @__PURE__ */ h("span", {
@@ -81,11 +81,11 @@ function w({ value: e, isLoading: t, colorClass: n }) {
81
81
  })
82
82
  });
83
83
  }
84
- function T({ mode: n, counterparts: r, isLoading: i, isError: a, errorTitle: o, errorDescription: s, sorting: c, onSortingChange: l, pageSize: u, onPageSizeChange: m, pageSizeOptions: b = S, hasNextPage: T, hasPrevPage: E, onNextPage: D, onPrevPage: O, filters: k, isFiltering: A, canCreate: j = !0, isAccessRestricted: M, onCreateClick: N, onRowClick: P, onRetry: F, labels: I, emptyStateTestId: L, accessRestrictedTestId: R }) {
85
- let z = {
84
+ function w({ mode: n, counterparts: r, isLoading: i, isError: a, errorTitle: o, errorDescription: s, sorting: c, onSortingChange: l, pageSize: u, onPageSizeChange: m, pageSizeOptions: b = x, hasNextPage: w, hasPrevPage: T, onNextPage: E, onPrevPage: D, filters: O, isFiltering: k, canCreate: A = !0, isAccessRestricted: j, onCreateClick: M, onRowClick: N, onRetry: P, labels: F, emptyStateTestId: I, accessRestrictedTestId: L }) {
85
+ let R = {
86
86
  ...p,
87
- ...I
88
- }, B = n === "customer", V = B ? z.columnReceivedAmount : z.columnTotalPaidToDate, H = B ? z.columnAmountDue : z.columnBalanceDue, U = [
87
+ ...F
88
+ }, z = n === "customer", B = z ? R.columnReceivedAmount : R.columnTotalPaidToDate, V = z ? R.columnAmountDue : R.columnBalanceDue, H = [
89
89
  {
90
90
  accessorKey: "name",
91
91
  enableSorting: !0,
@@ -93,10 +93,10 @@ function T({ mode: n, counterparts: r, isLoading: i, isError: a, errorTitle: o,
93
93
  let n = t.getIsSorted();
94
94
  return /* @__PURE__ */ g("div", {
95
95
  className: "ttw:flex ttw:items-center ttw:gap-2 ttw:text-inherit",
96
- children: [z.columnName, /* @__PURE__ */ h(e, {
96
+ children: [R.columnName, /* @__PURE__ */ h(e, {
97
97
  variant: "ghost",
98
98
  size: "icon-sm",
99
- "aria-label": z.sortByName,
99
+ "aria-label": R.sortByName,
100
100
  onClick: () => t.toggleSorting(n === "asc"),
101
101
  children: h(n === "asc" ? y : n === "desc" ? _ : v, { className: "ttw:size-4" })
102
102
  })]
@@ -117,9 +117,9 @@ function T({ mode: n, counterparts: r, isLoading: i, isError: a, errorTitle: o,
117
117
  accessorKey: "billedAmountLabel",
118
118
  header: () => /* @__PURE__ */ h("div", {
119
119
  className: "ttw:text-right",
120
- children: z.columnBilledAmount
120
+ children: R.columnBilledAmount
121
121
  }),
122
- cell: ({ row: e }) => /* @__PURE__ */ h(w, {
122
+ cell: ({ row: e }) => /* @__PURE__ */ h(C, {
123
123
  value: e.original.billedAmountLabel,
124
124
  isLoading: e.original.isBilledAmountLoading
125
125
  })
@@ -128,9 +128,9 @@ function T({ mode: n, counterparts: r, isLoading: i, isError: a, errorTitle: o,
128
128
  accessorKey: "receivedOrPaidAmountLabel",
129
129
  header: () => /* @__PURE__ */ h("div", {
130
130
  className: "ttw:text-right",
131
- children: V
131
+ children: B
132
132
  }),
133
- cell: ({ row: e }) => /* @__PURE__ */ h(w, {
133
+ cell: ({ row: e }) => /* @__PURE__ */ h(C, {
134
134
  value: e.original.receivedOrPaidAmountLabel,
135
135
  isLoading: e.original.isReceivedOrPaidAmountLoading,
136
136
  colorClass: e.original.isReceivedOrPaidPositive ? "ttw:text-green-700" : void 0
@@ -140,33 +140,33 @@ function T({ mode: n, counterparts: r, isLoading: i, isError: a, errorTitle: o,
140
140
  accessorKey: "dueOrOwedAmountLabel",
141
141
  header: () => /* @__PURE__ */ h("div", {
142
142
  className: "ttw:text-right",
143
- children: H
143
+ children: V
144
144
  }),
145
- cell: ({ row: e }) => /* @__PURE__ */ h(w, {
145
+ cell: ({ row: e }) => /* @__PURE__ */ h(C, {
146
146
  value: e.original.dueOrOwedAmountLabel,
147
147
  isLoading: e.original.isDueOrOwedAmountLoading
148
148
  })
149
149
  }
150
- ], W = B ? z.customersEmptyTitle : z.vendorsEmptyTitle, G = B ? z.customersEmptyDescription : z.vendorsEmptyDescription, K = B ? z.customersEmptyAction : z.vendorsEmptyAction, q = B ? z.customersFilterEmptyTitle : z.vendorsFilterEmptyTitle, J = !A && !k.searchValue && !r.length && !i, Y = !(!j || M), X = !(A || !Y), Z = !A && !i && !a && !r.length, Q = Y && !Z, $ = B ? z.createButton : z.vendorsCreateButton;
150
+ ], U = z ? R.customersEmptyTitle : R.vendorsEmptyTitle, W = z ? R.customersEmptyDescription : R.vendorsEmptyDescription, G = z ? R.customersEmptyAction : R.vendorsEmptyAction, K = z ? R.customersFilterEmptyTitle : R.vendorsFilterEmptyTitle, q = !k && !O.searchValue && !r.length && !i, J = !(!A || j), Y = !(k || !J), X = !k && !i && !a && !r.length, Z = J && !X, Q = z ? R.createButton : R.vendorsCreateButton;
151
151
  return /* @__PURE__ */ g("div", {
152
152
  className: "ttw:flex ttw:flex-col ttw:gap-4",
153
- children: [Q && /* @__PURE__ */ h("div", {
153
+ children: [Z && /* @__PURE__ */ h("div", {
154
154
  className: "ttw:flex ttw:items-center ttw:justify-end ttw:gap-2",
155
- children: /* @__PURE__ */ g(e, {
156
- onClick: N,
157
- children: [/* @__PURE__ */ h(x, { className: "ttw:size-4" }), $]
155
+ children: /* @__PURE__ */ h(e, {
156
+ onClick: M,
157
+ children: Q
158
158
  })
159
- }), M ? /* @__PURE__ */ h(f, {
160
- testId: R,
161
- title: z.accessRestrictedTitle,
162
- description: z.accessRestrictedDescription
159
+ }), j ? /* @__PURE__ */ h(f, {
160
+ testId: L,
161
+ title: R.accessRestrictedTitle,
162
+ description: R.accessRestrictedDescription
163
163
  }) : a ? /* @__PURE__ */ h(f, {
164
164
  title: o,
165
165
  description: s,
166
- retryLabel: F ? z.errorRetry : void 0,
167
- onRetry: F
166
+ retryLabel: P ? R.errorRetry : void 0,
167
+ onRetry: P
168
168
  }) : /* @__PURE__ */ h(t, {
169
- columns: U,
169
+ columns: H,
170
170
  data: r,
171
171
  isLoading: i,
172
172
  sorting: c,
@@ -174,26 +174,26 @@ function T({ mode: n, counterparts: r, isLoading: i, isError: a, errorTitle: o,
174
174
  pageSize: u,
175
175
  onPageSizeChange: m,
176
176
  pageSizeOptions: b,
177
- hasNextPage: T,
178
- hasPrevPage: E,
179
- onNextPage: D,
180
- onPrevPage: O,
181
- onRowClick: P,
182
- rowAriaLabel: (e) => z.openRow(e.name),
183
- filterComponent: /* @__PURE__ */ h(C, {
184
- labels: z,
185
- filters: k,
186
- disabled: J
177
+ hasNextPage: w,
178
+ hasPrevPage: T,
179
+ onNextPage: E,
180
+ onPrevPage: D,
181
+ onRowClick: N,
182
+ rowAriaLabel: (e) => R.openRow(e.name),
183
+ filterComponent: /* @__PURE__ */ h(S, {
184
+ labels: R,
185
+ filters: O,
186
+ disabled: q
187
187
  }),
188
188
  children: /* @__PURE__ */ h(d, {
189
- testId: L,
190
- title: A ? q : W,
191
- description: A ? z.filterEmptyDescription : G,
192
- actionLabel: A ? z.filterEmptyAction : X ? K : void 0,
193
- onAction: A ? k.onClearAll : X ? N : void 0
189
+ testId: I,
190
+ title: k ? K : U,
191
+ description: k ? R.filterEmptyDescription : W,
192
+ actionLabel: k ? R.filterEmptyAction : Y ? G : void 0,
193
+ onAction: k ? O.onClearAll : Y ? M : void 0
194
194
  })
195
195
  })]
196
196
  });
197
197
  }
198
198
  //#endregion
199
- export { T as CounterpartsScreen, T as default };
199
+ export { w as CounterpartsScreen, w as default };
@@ -353,21 +353,21 @@ function Y(e) {
353
353
  function X(e) {
354
354
  return /^[\d\s-]+$/.test(e) && e.replace(/\D/g, "").length === 9;
355
355
  }
356
- function Z(e, t, n = i, r = "customer", a = !1) {
357
- let o = {};
358
- e.entityType === "organization" ? e.legalName.trim().length === 0 && (o.legalName = n.legalNameRequired) : (e.firstName.trim().length === 0 && (o.firstName = n.firstNameRequired), e.lastName.trim().length === 0 && (o.lastName = n.lastNameRequired)), e.email.trim().length === 0 ? o.email = n.emailRequired : W(e.email.trim()) || (o.email = n.emailInvalid);
359
- let s = e.phone.trim();
360
- s && !Y(s) && (o.phone = n.phoneInvalid);
361
- let c = e.taxId.trim();
362
- if (c && !X(c) && (o.taxId = n.taxIdInvalid), t === "create" && r === "vendor" || k(e.address)) {
363
- let t = G(e.address, n);
364
- K(t) && (o.address = t);
356
+ function Z(e, t = i, n = "customer", r = !1) {
357
+ let a = {};
358
+ e.entityType === "organization" ? e.legalName.trim().length === 0 && (a.legalName = t.legalNameRequired) : (e.firstName.trim().length === 0 && (a.firstName = t.firstNameRequired), e.lastName.trim().length === 0 && (a.lastName = t.lastNameRequired)), e.email.trim().length === 0 ? a.email = t.emailRequired : W(e.email.trim()) || (a.email = t.emailInvalid);
359
+ let o = e.phone.trim();
360
+ o && !Y(o) && (a.phone = t.phoneInvalid);
361
+ let s = e.taxId.trim();
362
+ if (s && !X(s) && (a.taxId = t.taxIdInvalid), n === "vendor" || k(e.address)) {
363
+ let n = G(e.address, t);
364
+ K(n) && (a.address = n);
365
365
  }
366
- if (r === "vendor" && (a || I(e))) {
367
- let t = J(e.bankAccount, n);
368
- K(t) && (o.bankAccount = t);
366
+ if (n === "vendor" && (r || I(e))) {
367
+ let n = J(e.bankAccount, t);
368
+ K(n) && (a.bankAccount = n);
369
369
  }
370
- return o;
370
+ return a;
371
371
  }
372
372
  function Q(e, t, n) {
373
373
  if (!n) return e;
@@ -10,7 +10,7 @@ var e = {
10
10
  addressLine1Required: "Address line 1 is required",
11
11
  cityRequired: "City is required",
12
12
  stateRequired: "State is required",
13
- postalCodeRequired: "ZIP code is required",
13
+ postalCodeRequired: "Postal code is required",
14
14
  accountHolderNameRequired: "Account holder name is required",
15
15
  routingNumberInvalid: "Enter a valid 9-digit ABA routing number",
16
16
  accountNumberInvalid: "Enter a valid account number",