@tesouro/embedded-components-react 0.11.104 → 0.11.105

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.d.ts CHANGED
@@ -5731,6 +5731,10 @@ interface ProductsWidgetOwnProps {
5731
5731
  /** Public props for {@link ProductsWidget}. */
5732
5732
  type ProductsWidgetProps = WidgetProviderProps & ProductsWidgetOwnProps;
5733
5733
 
5734
+ /** Kept off the exported {@link ProductsWidgetProps}: only Invoicing's tab row passes the slot. */
5735
+ interface ProductsWidgetInternalProps extends ProductsWidgetProps {
5736
+ headerActionContainer?: HTMLElement | null;
5737
+ }
5734
5738
  /**
5735
5739
  * Self-contained products/services widget: lists, filters, creates, edits,
5736
5740
  * views, and deletes products, and manages measure units. The provider/inner
@@ -5741,7 +5745,7 @@ type ProductsWidgetProps = WidgetProviderProps & ProductsWidgetOwnProps;
5741
5745
  * <ProductsWidget baseUrl="https://api.tesouro.com" widgetToken="wt_..." organizationId="org_..." />
5742
5746
  * ```
5743
5747
  */
5744
- declare function ProductsWidget({ baseUrl, widgetToken, organizationId, configClient, gatewayRouting, linkComponent, uiFramework, errorFallback, onError, analytics, disclosuresAcceptance, providerLabels, ...innerProps }: ProductsWidgetProps): React.JSX.Element;
5748
+ declare function ProductsWidget({ baseUrl, widgetToken, organizationId, configClient, gatewayRouting, linkComponent, uiFramework, errorFallback, onError, analytics, disclosuresAcceptance, providerLabels, ...innerProps }: ProductsWidgetInternalProps): React.JSX.Element;
5745
5749
 
5746
5750
  declare const InvoicesFilterField: {
5747
5751
  readonly DueDate: "dueDate";
@@ -873,6 +873,10 @@ interface ProductsWidgetOwnProps {
873
873
  /** Public props for {@link ProductsWidget}. */
874
874
  type ProductsWidgetProps = WidgetProviderProps & ProductsWidgetOwnProps;
875
875
 
876
+ /** Kept off the exported {@link ProductsWidgetProps}: only Invoicing's tab row passes the slot. */
877
+ interface ProductsWidgetInternalProps extends ProductsWidgetProps {
878
+ headerActionContainer?: HTMLElement | null;
879
+ }
876
880
  /**
877
881
  * Self-contained products/services widget: lists, filters, creates, edits,
878
882
  * views, and deletes products, and manages measure units. The provider/inner
@@ -883,7 +887,7 @@ type ProductsWidgetProps = WidgetProviderProps & ProductsWidgetOwnProps;
883
887
  * <ProductsWidget baseUrl="https://api.tesouro.com" widgetToken="wt_..." organizationId="org_..." />
884
888
  * ```
885
889
  */
886
- declare function ProductsWidget({ baseUrl, widgetToken, organizationId, configClient, gatewayRouting, linkComponent, uiFramework, errorFallback, onError, analytics, disclosuresAcceptance, providerLabels, ...innerProps }: ProductsWidgetProps): React.JSX.Element;
890
+ declare function ProductsWidget({ baseUrl, widgetToken, organizationId, configClient, gatewayRouting, linkComponent, uiFramework, errorFallback, onError, analytics, disclosuresAcceptance, providerLabels, ...innerProps }: ProductsWidgetInternalProps): React.JSX.Element;
887
891
 
888
892
  export { ProductsWidget };
889
893
  export type { MeasureUnitDeleteDialogLabels, MeasureUnitsManagerLabels, ProductDeleteDialogLabels, ProductDetailsSheetLabels, ProductFormSheetLabels, ProductMessageLabels, ProductsScreenLabels, ProductsWidgetProps };
@@ -22,12 +22,12 @@ import { useProductsWidget as p } from "./useProductsWidget.js";
22
22
  import { useEffect as m } from "react";
23
23
  import { Fragment as h, jsx as g, jsxs as _ } from "react/jsx-runtime";
24
24
  // ../../libs/tesouro-embedded-components-react/products-widget/feature/dist/lib/ProductsWidget/ProductsWidget.js
25
- function v({ pageSizeOptions: n = c, screenLabels: s, formLabels: v, detailsLabels: y, deleteLabels: b, measureUnitsLabels: x, measureUnitDeleteLabels: S, messageLabels: C }) {
26
- let w = t();
25
+ function v({ pageSizeOptions: n = c, screenLabels: s, formLabels: v, detailsLabels: y, deleteLabels: b, measureUnitsLabels: x, measureUnitDeleteLabels: S, messageLabels: C, headerActionContainer: w }) {
26
+ let T = t();
27
27
  m(() => {
28
- w(o.Mounted);
29
- }, [w]);
30
- let { view: T, units: E, table: D, details: O, form: k, del: A, permissions: j, isPermissionLoading: M, isTableLoading: N, hasInitError: P, refetchWidgetInit: F, measureUnitsOpen: I, actionsSuspended: L, editForm: R, handleRowClick: z, openMeasureUnits: B, closeMeasureUnits: V, addUnitOpen: H, openAddUnit: U, closeAddUnit: W, selectAddedUnit: G, submitForm: K, confirmDelete: q } = p({
28
+ T(o.Mounted);
29
+ }, [T]);
30
+ let { view: E, units: D, table: O, details: k, form: A, del: j, permissions: M, isPermissionLoading: N, isTableLoading: P, hasInitError: F, refetchWidgetInit: I, measureUnitsOpen: L, actionsSuspended: R, editForm: z, handleRowClick: B, openMeasureUnits: V, closeMeasureUnits: H, addUnitOpen: U, openAddUnit: W, closeAddUnit: G, selectAddedUnit: K, submitForm: q, confirmDelete: J } = p({
31
31
  messageLabels: C,
32
32
  screenLabels: s,
33
33
  formLabels: v
@@ -35,27 +35,28 @@ function v({ pageSizeOptions: n = c, screenLabels: s, formLabels: v, detailsLabe
35
35
  return /* @__PURE__ */ _(h, { children: [
36
36
  /* @__PURE__ */ g(e, {}),
37
37
  /* @__PURE__ */ g(u, {
38
- products: D.rows,
39
- isLoading: N,
40
- isError: P || D.isError,
41
- sorting: D.sorting,
42
- onSortingChange: D.onSortingChange,
43
- pageSize: D.pageSize,
44
- onPageSizeChange: D.onPageSizeChange,
38
+ products: O.rows,
39
+ isLoading: P,
40
+ isError: F || O.isError,
41
+ sorting: O.sorting,
42
+ onSortingChange: O.onSortingChange,
43
+ pageSize: O.pageSize,
44
+ onPageSizeChange: O.onPageSizeChange,
45
45
  pageSizeOptions: n,
46
- hasNextPage: D.hasNextPage,
47
- hasPrevPage: D.hasPrevPage,
48
- onNextPage: D.onNextPage,
49
- onPrevPage: D.onPrevPage,
50
- filters: D.filters,
51
- isFiltering: D.isFiltering,
52
- canCreate: j.canCreate,
53
- canManageUnits: j.canCreate,
54
- isAccessRestricted: !M && !P && !j.canRead,
55
- onCreateClick: k.openCreate,
56
- onManageUnitsClick: B,
57
- onRowClick: z,
58
- onRetry: P ? F : D.onRetry,
46
+ hasNextPage: O.hasNextPage,
47
+ hasPrevPage: O.hasPrevPage,
48
+ onNextPage: O.onNextPage,
49
+ onPrevPage: O.onPrevPage,
50
+ filters: O.filters,
51
+ isFiltering: O.isFiltering,
52
+ canCreate: M.canCreate,
53
+ canManageUnits: M.canCreate,
54
+ isAccessRestricted: !N && !F && !M.canRead,
55
+ onCreateClick: A.openCreate,
56
+ onManageUnitsClick: V,
57
+ onRowClick: B,
58
+ onRetry: F ? I : O.onRetry,
59
+ headerActionContainer: w,
59
60
  labels: s,
60
61
  testIds: {
61
62
  empty: l.empty,
@@ -63,57 +64,57 @@ function v({ pageSizeOptions: n = c, screenLabels: s, formLabels: v, detailsLabe
63
64
  }
64
65
  }),
65
66
  /* @__PURE__ */ g(r, {
66
- open: T === "create",
67
+ open: E === "create",
67
68
  onOpenChange: (e) => {
68
- e || k.close();
69
+ e || A.close();
69
70
  },
70
- values: k.values,
71
- errors: k.errors,
72
- unitOptions: E.unitOptions,
73
- pricePrefix: k.pricePrefix,
74
- inProgress: k.isSubmitting || L,
75
- onChange: k.change,
76
- onSubmit: K,
77
- onCancel: k.close,
78
- onAddUnit: j.canCreate ? U : void 0,
71
+ values: A.values,
72
+ errors: A.errors,
73
+ unitOptions: D.unitOptions,
74
+ pricePrefix: A.pricePrefix,
75
+ inProgress: A.isSubmitting || R,
76
+ onChange: A.change,
77
+ onSubmit: q,
78
+ onCancel: A.close,
79
+ onAddUnit: M.canCreate ? W : void 0,
79
80
  labels: v
80
81
  }),
81
82
  /* @__PURE__ */ g(d, {
82
- open: T === "details" || T === "edit",
83
+ open: E === "details" || E === "edit",
83
84
  onOpenChange: (e) => {
84
- e || k.close();
85
+ e || A.close();
85
86
  },
86
- product: O.detailsView,
87
- isLoading: O.isLoading,
88
- isError: O.isError,
89
- onEdit: k.openEdit,
90
- onDelete: A.requestDelete,
91
- canEdit: j.canUpdate,
92
- canDelete: j.canDelete,
93
- editForm: R,
87
+ product: k.detailsView,
88
+ isLoading: k.isLoading,
89
+ isError: k.isError,
90
+ onEdit: A.openEdit,
91
+ onDelete: j.requestDelete,
92
+ canEdit: M.canUpdate,
93
+ canDelete: M.canDelete,
94
+ editForm: z,
94
95
  labels: y
95
96
  }),
96
97
  /* @__PURE__ */ g(f, {
97
- open: A.open,
98
- onOpenChange: A.onOpenChange,
99
- productName: O.productName,
100
- isDeleting: A.isDeleting || L,
101
- onConfirm: q,
102
- onCancel: A.cancel,
98
+ open: j.open,
99
+ onOpenChange: j.onOpenChange,
100
+ productName: k.productName,
101
+ isDeleting: j.isDeleting || R,
102
+ onConfirm: J,
103
+ onCancel: j.cancel,
103
104
  labels: b
104
105
  }),
105
106
  /* @__PURE__ */ g(a, {
106
- open: H,
107
- onClose: W,
108
- onCreated: G,
109
- suspended: L,
107
+ open: U,
108
+ onClose: G,
109
+ onCreated: K,
110
+ suspended: R,
110
111
  labels: x,
111
112
  messageLabels: C
112
113
  }),
113
114
  /* @__PURE__ */ g(i, {
114
- open: I,
115
- onClose: V,
116
- suspended: L,
115
+ open: L,
116
+ onClose: H,
117
+ suspended: R,
117
118
  managerLabels: x,
118
119
  deleteLabels: S,
119
120
  messageLabels: C
@@ -5,78 +5,79 @@ import { NoAccessState as h } from "../../../shared/ui/dist/lib/StatePanel/NoAcc
5
5
  import "../../../shared/ui/dist/index.js";
6
6
  import { PRODUCTS_SCREEN_LABELS_EN as g } from "./index2.js";
7
7
  import { ProductTypeBadge as _ } from "./index3.js";
8
- import { Fragment as v, jsx as y, jsxs as b } from "react/jsx-runtime";
9
- import { ListFilter as x } from "lucide-react";
8
+ import { createPortal as v } from "react-dom";
9
+ import { Fragment as y, jsx as b, jsxs as x } from "react/jsx-runtime";
10
+ import { ListFilter as S } from "lucide-react";
10
11
  // ../../libs/tesouro-embedded-components-react/products-widget/ui/dist/index4.js
11
- var S = [
12
+ var C = [
12
13
  10,
13
14
  25,
14
15
  50,
15
16
  100
16
- ], C = "ttw:flex ttw:w-full ttw:cursor-pointer ttw:items-center ttw:gap-2 ttw:rounded-md ttw:px-2 ttw:py-1.5 ttw:text-xs ttw:font-medium ttw:transition-colors ttw:hover:bg-accent";
17
- function w({ labels: e, filters: t, action: n }) {
18
- return /* @__PURE__ */ y(f, {
17
+ ], w = "ttw:flex ttw:w-full ttw:cursor-pointer ttw:items-center ttw:gap-2 ttw:rounded-md ttw:px-2 ttw:py-1.5 ttw:text-xs ttw:font-medium ttw:transition-colors ttw:hover:bg-accent";
18
+ function T({ labels: e, filters: t, action: n }) {
19
+ return /* @__PURE__ */ b(f, {
19
20
  className: "ttw:px-4",
20
- search: /* @__PURE__ */ y(d, {
21
+ search: /* @__PURE__ */ b(d, {
21
22
  value: t.searchValue,
22
23
  onChange: (e) => t.onSearchChange(e.target.value),
23
24
  placeholder: e.searchPlaceholder,
24
25
  "aria-label": e.searchLabel,
25
26
  className: "ttw:min-w-64"
26
27
  }),
27
- filterButton: /* @__PURE__ */ b(o, {
28
+ filterButton: /* @__PURE__ */ x(o, {
28
29
  open: t.isPopoverOpen,
29
30
  onOpenChange: (e) => {
30
31
  e || t.onPopoverClose();
31
32
  },
32
- children: [/* @__PURE__ */ y(c, {
33
+ children: [/* @__PURE__ */ b(c, {
33
34
  asChild: !0,
34
- children: /* @__PURE__ */ y(r, {
35
+ children: /* @__PURE__ */ b(r, {
35
36
  activeCount: t.activeFilterCount,
36
37
  onClick: (e) => {
37
38
  t.isPanelOpen && e.preventDefault(), t.onMenuToggle();
38
39
  },
39
40
  labels: { filters: e.filtersButton }
40
41
  })
41
- }), /* @__PURE__ */ b(s, {
42
+ }), /* @__PURE__ */ x(s, {
42
43
  align: "start",
43
44
  className: "ttw:w-56 ttw:p-0",
44
45
  children: [
45
- t.isMenuOpen && /* @__PURE__ */ b("div", {
46
+ t.isMenuOpen && /* @__PURE__ */ x("div", {
46
47
  className: "ttw:p-1",
47
- children: [/* @__PURE__ */ b("button", {
48
+ children: [/* @__PURE__ */ x("button", {
48
49
  type: "button",
49
- className: C,
50
+ className: w,
50
51
  onClick: t.onTypeFieldSelect,
51
- children: [/* @__PURE__ */ y(x, {
52
+ children: [/* @__PURE__ */ b(S, {
52
53
  className: "ttw:size-4 ttw:shrink-0 ttw:text-muted-foreground",
53
54
  "aria-hidden": !0
54
55
  }), e.filterFieldType]
55
- }), /* @__PURE__ */ b("button", {
56
+ }), /* @__PURE__ */ x("button", {
56
57
  type: "button",
57
- className: C,
58
+ className: w,
58
59
  onClick: t.onUnitFieldSelect,
59
- children: [/* @__PURE__ */ y(x, {
60
+ children: [/* @__PURE__ */ b(S, {
60
61
  className: "ttw:size-4 ttw:shrink-0 ttw:text-muted-foreground",
61
62
  "aria-hidden": !0
62
63
  }), e.filterFieldUnit]
63
64
  })]
64
65
  }),
65
- t.isTypePanelOpen && /* @__PURE__ */ y(a, {
66
+ t.isTypePanelOpen && /* @__PURE__ */ b(a, {
66
67
  options: [...t.typeOptions],
67
68
  selectedValues: [...t.selectedTypes],
68
69
  onSelectionChange: t.onTypeChange
69
70
  }),
70
- t.isUnitPanelOpen && /* @__PURE__ */ y("div", {
71
+ t.isUnitPanelOpen && /* @__PURE__ */ b("div", {
71
72
  className: "ttw:max-h-64 ttw:overflow-auto ttw:p-3",
72
- children: /* @__PURE__ */ y(l, {
73
+ children: /* @__PURE__ */ b(l, {
73
74
  value: t.selectedUnit,
74
75
  onValueChange: t.onUnitChange,
75
76
  "aria-label": e.filterFieldUnit,
76
77
  className: "ttw:flex ttw:flex-col ttw:gap-1",
77
- children: t.unitOptions.map((e) => /* @__PURE__ */ b("label", {
78
+ children: t.unitOptions.map((e) => /* @__PURE__ */ x("label", {
78
79
  className: "ttw:flex ttw:cursor-pointer ttw:items-center ttw:gap-2",
79
- children: [/* @__PURE__ */ y(u, { value: e.value }), /* @__PURE__ */ y("span", {
80
+ children: [/* @__PURE__ */ b(u, { value: e.value }), /* @__PURE__ */ b("span", {
80
81
  className: "ttw:text-xs ttw:font-medium",
81
82
  children: e.label
82
83
  })]
@@ -87,12 +88,12 @@ function w({ labels: e, filters: t, action: n }) {
87
88
  })]
88
89
  }),
89
90
  action: n,
90
- tags: /* @__PURE__ */ b(v, { children: [t.chips.map((n) => /* @__PURE__ */ y(i, {
91
+ tags: /* @__PURE__ */ x(y, { children: [t.chips.map((n) => /* @__PURE__ */ b(i, {
91
92
  label: n.label,
92
93
  variant: "default",
93
94
  labels: { remove: e.filterChipRemove },
94
95
  onDismiss: () => t.onRemoveChip(n.key)
95
- }, n.key)), t.chips.length > 0 && /* @__PURE__ */ y("button", {
96
+ }, n.key)), t.chips.length > 0 && /* @__PURE__ */ b("button", {
96
97
  type: "button",
97
98
  className: "ttw:cursor-pointer ttw:whitespace-nowrap ttw:text-xs ttw:text-muted-foreground ttw:transition-colors ttw:hover:text-foreground",
98
99
  onClick: t.onClearAll,
@@ -100,24 +101,28 @@ function w({ labels: e, filters: t, action: n }) {
100
101
  })] })
101
102
  });
102
103
  }
103
- function T({ products: r, isLoading: i, isError: a, sorting: o, onSortingChange: s, pageSize: c, onPageSizeChange: l, pageSizeOptions: u = S, hasNextPage: d, hasPrevPage: f, onNextPage: x, onPrevPage: C, filters: T, isFiltering: E, onCreateClick: D, onManageUnitsClick: O, onRowClick: k, onRetry: A, canCreate: j = !0, canManageUnits: M = !0, isAccessRestricted: N, labels: P, testIds: F }) {
104
- let I = {
104
+ function E({ products: r, isLoading: i, isError: a, sorting: o, onSortingChange: s, pageSize: c, onPageSizeChange: l, pageSizeOptions: u = C, hasNextPage: d, hasPrevPage: f, onNextPage: S, onPrevPage: w, filters: E, isFiltering: D, onCreateClick: O, onManageUnitsClick: k, onRowClick: A, onRetry: j, headerActionContainer: M, canCreate: N = !0, canManageUnits: P = !0, isAccessRestricted: F, labels: I, testIds: L }) {
105
+ let R = {
105
106
  ...g,
106
- ...P,
107
+ ...I,
107
108
  typeBadge: {
108
109
  ...g.typeBadge,
109
- ...P?.typeBadge
110
+ ...I?.typeBadge
110
111
  }
111
- }, L = !E && j, R = !i && r.length === 0 && L, z = [
112
+ }, z = !D && N, B = !i && r.length === 0 && z ? void 0 : /* @__PURE__ */ b(e, {
113
+ onClick: O,
114
+ disabled: !N,
115
+ children: R.createButton
116
+ }), V = [
112
117
  {
113
118
  accessorKey: "name",
114
119
  enableSorting: !0,
115
- header: ({ column: e }) => /* @__PURE__ */ y(n, {
120
+ header: ({ column: e }) => /* @__PURE__ */ b(n, {
116
121
  column: e,
117
- title: I.columnName
122
+ title: R.columnName
118
123
  }),
119
124
  size: 320,
120
- cell: ({ row: e }) => /* @__PURE__ */ y("span", {
125
+ cell: ({ row: e }) => /* @__PURE__ */ b("span", {
121
126
  className: "ttw:block ttw:w-74 ttw:truncate",
122
127
  children: e.original.name
123
128
  })
@@ -125,19 +130,19 @@ function T({ products: r, isLoading: i, isError: a, sorting: o, onSortingChange:
125
130
  {
126
131
  accessorKey: "type",
127
132
  size: 112,
128
- header: I.columnType,
129
- cell: ({ row: e }) => e.original.type ? /* @__PURE__ */ y(_, {
133
+ header: R.columnType,
134
+ cell: ({ row: e }) => e.original.type ? /* @__PURE__ */ b(_, {
130
135
  type: e.original.type,
131
- labels: I.typeBadge
136
+ labels: R.typeBadge
132
137
  }) : null
133
138
  },
134
139
  {
135
140
  accessorKey: "description",
136
- header: I.columnDescription,
141
+ header: R.columnDescription,
137
142
  size: 1e4,
138
- cell: ({ row: e }) => /* @__PURE__ */ y("div", {
143
+ cell: ({ row: e }) => /* @__PURE__ */ b("div", {
139
144
  className: "ttw:relative ttw:h-5 ttw:min-w-40",
140
- children: /* @__PURE__ */ y("span", {
145
+ children: /* @__PURE__ */ b("span", {
141
146
  className: "ttw:absolute ttw:inset-0 ttw:truncate",
142
147
  children: e.original.description
143
148
  })
@@ -146,30 +151,30 @@ function T({ products: r, isLoading: i, isError: a, sorting: o, onSortingChange:
146
151
  {
147
152
  accessorKey: "priceLabel",
148
153
  size: 180,
149
- header: () => /* @__PURE__ */ y("div", {
154
+ header: () => /* @__PURE__ */ b("div", {
150
155
  className: "ttw:text-right",
151
- children: I.columnPrice
156
+ children: R.columnPrice
152
157
  }),
153
- cell: ({ row: e }) => /* @__PURE__ */ b("div", {
158
+ cell: ({ row: e }) => /* @__PURE__ */ x("div", {
154
159
  className: "ttw:flex ttw:w-39 ttw:items-center ttw:justify-end ttw:gap-1 ttw:tabular-nums",
155
- children: [/* @__PURE__ */ y("span", { children: e.original.priceLabel }), e.original.unitLabel && /* @__PURE__ */ y("span", {
160
+ children: [/* @__PURE__ */ b("span", { children: e.original.priceLabel }), e.original.unitLabel && /* @__PURE__ */ b("span", {
156
161
  className: "ttw:text-muted-foreground",
157
162
  children: e.original.unitLabel
158
163
  })]
159
164
  })
160
165
  }
161
166
  ];
162
- return N ? /* @__PURE__ */ y(h, {
163
- testId: F?.accessRestricted,
164
- title: I.accessRestrictedTitle,
165
- description: I.accessRestrictedDescription
166
- }) : a ? /* @__PURE__ */ y(m, {
167
- title: I.errorTitle,
168
- description: I.errorDescription,
169
- retryLabel: A ? I.errorRetry : void 0,
170
- onRetry: A
171
- }) : /* @__PURE__ */ y(t, {
172
- columns: z,
167
+ return F ? /* @__PURE__ */ b(h, {
168
+ testId: L?.accessRestricted,
169
+ title: R.accessRestrictedTitle,
170
+ description: R.accessRestrictedDescription
171
+ }) : a ? /* @__PURE__ */ b(m, {
172
+ title: R.errorTitle,
173
+ description: R.errorDescription,
174
+ retryLabel: j ? R.errorRetry : void 0,
175
+ onRetry: j
176
+ }) : /* @__PURE__ */ x(y, { children: [/* @__PURE__ */ b(t, {
177
+ columns: V,
173
178
  data: r,
174
179
  isLoading: i,
175
180
  sorting: o,
@@ -179,31 +184,27 @@ function T({ products: r, isLoading: i, isError: a, sorting: o, onSortingChange:
179
184
  pageSizeOptions: u,
180
185
  hasNextPage: d,
181
186
  hasPrevPage: f,
182
- onNextPage: x,
183
- onPrevPage: C,
184
- onRowClick: k,
185
- rowAriaLabel: (e) => I.openRow(e.name),
186
- filterComponent: /* @__PURE__ */ y(w, {
187
- labels: I,
188
- filters: T,
189
- action: /* @__PURE__ */ b(v, { children: [/* @__PURE__ */ y(e, {
187
+ onNextPage: S,
188
+ onPrevPage: w,
189
+ onRowClick: A,
190
+ rowAriaLabel: (e) => R.openRow(e.name),
191
+ filterComponent: /* @__PURE__ */ b(T, {
192
+ labels: R,
193
+ filters: E,
194
+ action: /* @__PURE__ */ x(y, { children: [/* @__PURE__ */ b(e, {
190
195
  variant: "outline",
191
- onClick: O,
192
- disabled: !M,
193
- children: I.manageUnitsButton
194
- }), !R && /* @__PURE__ */ y(e, {
195
- onClick: D,
196
- disabled: !j,
197
- children: I.createButton
198
- })] })
196
+ onClick: k,
197
+ disabled: !P,
198
+ children: R.manageUnitsButton
199
+ }), M === void 0 && B] })
199
200
  }),
200
- children: /* @__PURE__ */ y(p, {
201
- testId: F?.empty,
202
- title: E ? I.filterEmptyTitle : I.emptyTitle,
203
- description: E ? I.filterEmptyDescription : I.emptyDescription,
204
- actionLabel: L ? I.emptyAction : void 0,
205
- onAction: L ? D : void 0
201
+ children: /* @__PURE__ */ b(p, {
202
+ testId: L?.empty,
203
+ title: D ? R.filterEmptyTitle : R.emptyTitle,
204
+ description: D ? R.filterEmptyDescription : R.emptyDescription,
205
+ actionLabel: z ? R.emptyAction : void 0,
206
+ onAction: z ? O : void 0
206
207
  })
207
- });
208
+ }), M && B && v(B, M)] });
208
209
  }
209
- export { T as ProductsScreen, T as default };
210
+ export { E as ProductsScreen, E as default };
@@ -1,5 +1,5 @@
1
1
  // ../../libs/tesouro-embedded-components-react/shared/feature/dist/lib/analytics/build-info.js
2
- var e = "@tesouro/embedded-components-react", t = "0.11.104", n = "82c762290dc868f3d8af5c75de7ab4c2ca8c569c", r = Object.freeze({
2
+ var e = "@tesouro/embedded-components-react", t = "0.11.105", n = "20076f918051af1eaa31384fecd8fdbbc3a68b9d", r = Object.freeze({
3
3
  library_name: e,
4
4
  library_version: t,
5
5
  library_sha: n
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@tesouro/embedded-components-react",
3
- "version": "0.11.104",
3
+ "version": "0.11.105",
4
4
  "license": "Apache-2.0",
5
5
  "type": "module",
6
6
  "sideEffects": [