@tesouro/embedded-components-react 0.3.1 → 0.3.2

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 (45) hide show
  1. package/README.md +7 -10
  2. package/dist/experimental/WidgetSuite.d.ts +2 -2
  3. package/dist/experimental/index.d.ts +2 -2
  4. package/dist/index.d.ts +1 -23
  5. package/dist/lib/BankAccountsWidget.d.ts +0 -1
  6. package/dist/lib/ChartOfAccountsWidget.d.ts +1 -5
  7. package/dist/lib/CounterpartsWidget.d.ts +0 -9
  8. package/dist/lib/ExpenseManagementWidget.d.ts +0 -1
  9. package/dist/lib/ProductsWidget.d.ts +0 -1
  10. package/dist/lib/ReceivablesWidget.d.ts +0 -1
  11. package/dist/lib/SettingsWidget.d.ts +0 -1
  12. package/dist/lib/TagsWidget.d.ts +0 -1
  13. package/dist/lib/TeamWidget.d.ts +0 -3
  14. package/dist/libs/tesouro-embedded-components-react/bank-accounts-widget/account-details/ui/dist/index8.js +0 -1
  15. package/dist/libs/tesouro-embedded-components-react/bank-accounts-widget/feature/dist/index7.js +64 -65
  16. package/dist/libs/tesouro-embedded-components-react/bank-accounts-widget/ui/dist/lib/BankAccountsWidgetUi.js +35 -36
  17. package/dist/libs/tesouro-embedded-components-react/bank-accounts-widget/ui/dist/lib/BankingHeader.js +35 -42
  18. package/dist/libs/tesouro-embedded-components-react/bank-accounts-widget/ui/dist/lib/labels.js +0 -1
  19. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index64.js +0 -1
  20. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index43.js +1 -4
  21. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index44.js +4 -7
  22. package/dist/libs/tesouro-embedded-components-react/cards-widget/ui/dist/lib/CardsList/CardsList.js +0 -1
  23. package/dist/libs/tesouro-embedded-components-react/counterparts-widget/feature/dist/index8.js +106 -107
  24. package/dist/libs/tesouro-embedded-components-react/counterparts-widget/ui/dist/index2.js +0 -2
  25. package/dist/libs/tesouro-embedded-components-react/counterparts-widget/ui/dist/index3.js +85 -93
  26. package/dist/libs/tesouro-embedded-components-react/expense-management-widget/ui/dist/lib/ExpenseManagementWidgetUi/ExpenseManagementWidgetUi.js +4 -7
  27. package/dist/libs/tesouro-embedded-components-react/expense-management-widget/ui/dist/lib/ExpenseManagementWidgetUi/labels.js +0 -1
  28. package/dist/libs/tesouro-embedded-components-react/gl-code-table-widget/ui/dist/index2.js +0 -1
  29. package/dist/libs/tesouro-embedded-components-react/gl-code-table-widget/ui/dist/index3.js +113 -115
  30. package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index16.js +150 -155
  31. package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index2.js +0 -1
  32. package/dist/libs/tesouro-embedded-components-react/products-widget/ui/dist/index2.js +0 -1
  33. package/dist/libs/tesouro-embedded-components-react/products-widget/ui/dist/index4.js +86 -91
  34. package/dist/libs/tesouro-embedded-components-react/settings-widget/feature/dist/index5.js +20 -22
  35. package/dist/libs/tesouro-embedded-components-react/settings-widget/feature/dist/index6.js +2 -6
  36. package/dist/libs/tesouro-embedded-components-react/settings-widget/ui/dist/lib/SettingsWidgetUi/SettingsWidgetUi.js +25 -26
  37. package/dist/libs/tesouro-embedded-components-react/settings-widget/ui/dist/lib/SettingsWidgetUi/labels.js +1 -1
  38. package/dist/libs/tesouro-embedded-components-react/shared/approval-policy/ui/dist/index11.js +1 -1
  39. package/dist/libs/tesouro-embedded-components-react/shared/feature/dist/lib/analytics/build-info.js +1 -1
  40. package/dist/libs/tesouro-embedded-components-react/tags-widget/ui/dist/index2.js +0 -1
  41. package/dist/libs/tesouro-embedded-components-react/tags-widget/ui/dist/index3.js +67 -68
  42. package/dist/libs/tesouro-embedded-components-react/team-widget/feature/dist/index17.js +239 -241
  43. package/dist/libs/tesouro-embedded-components-react/widget-suite/feature/dist/index7.js +1 -6
  44. package/dist/libs/tesouro-embedded-components-react/widget-suite/feature/dist/index8.js +53 -53
  45. package/package.json +1 -1
@@ -1,51 +1,50 @@
1
1
  import { Button as e, DataTable as t, DropdownMenu as n, DropdownMenuContent as r, DropdownMenuItem as i, DropdownMenuTrigger as a } from "../../../../../packages/shared-ui-shadcn/dist/index.js";
2
2
  import { EmptyState as o } from "../../../shared/ui/dist/lib/EmptyState/EmptyState.js";
3
3
  import { ErrorState as s } from "../../../shared/ui/dist/lib/ErrorState/ErrorState.js";
4
- import { SectionHeading as c } from "../../../shared/ui/dist/lib/SectionHeading/SectionHeading.js";
5
4
  import "../../../shared/ui/dist/index.js";
6
- import { TAGS_SCREEN_LABELS_EN as l } from "./index2.js";
7
- import { jsx as u, jsxs as d } from "react/jsx-runtime";
8
- import { ArrowDownIcon as f, ArrowUpDownIcon as p, ArrowUpIcon as m, MoreVerticalIcon as h, PlusIcon as g, Trash2Icon as _ } from "lucide-react";
5
+ import { TAGS_SCREEN_LABELS_EN as c } from "./index2.js";
6
+ import { jsx as l, jsxs as u } from "react/jsx-runtime";
7
+ import { ArrowDownIcon as d, ArrowUpDownIcon as f, ArrowUpIcon as p, MoreVerticalIcon as m, PlusIcon as h, Trash2Icon as g } from "lucide-react";
9
8
  //#region ../../libs/tesouro-embedded-components-react/tags-widget/ui/dist/index3.js
10
- var v = [
9
+ var _ = [
11
10
  10,
12
11
  25,
13
12
  50,
14
13
  100
15
14
  ];
16
- function y({ label: t, isSorted: n, onToggle: r }) {
17
- return /* @__PURE__ */ d("div", {
15
+ function v({ label: t, isSorted: n, onToggle: r }) {
16
+ return /* @__PURE__ */ u("div", {
18
17
  className: "ttw:flex ttw:items-center ttw:gap-2 ttw:text-inherit",
19
- children: [t, /* @__PURE__ */ u(e, {
18
+ children: [t, /* @__PURE__ */ l(e, {
20
19
  variant: "ghost",
21
20
  size: "icon-sm",
22
21
  onClick: r,
23
- children: u(n === "asc" ? m : n === "desc" ? f : p, { className: "ttw:size-4" })
22
+ children: l(n === "asc" ? p : n === "desc" ? d : f, { className: "ttw:size-4" })
24
23
  })]
25
24
  });
26
25
  }
27
- function b({ tags: f, isLoading: p, isError: m, sorting: b, onSortingChange: x, pageSize: S, onPageSizeChange: C, pageSizeOptions: w = v, hasNextPage: T, hasPrevPage: E, onNextPage: D, onPrevPage: O, onCreateClick: k, onRowClick: A, onDeleteClick: j, onRetry: M, labels: N, emptyStateTestId: P }) {
28
- let F = {
29
- ...l,
30
- ...N
31
- }, I = [
26
+ function y({ tags: d, isLoading: f, isError: p, sorting: y, onSortingChange: b, pageSize: x, onPageSizeChange: S, pageSizeOptions: C = _, hasNextPage: w, hasPrevPage: T, onNextPage: E, onPrevPage: D, onCreateClick: O, onRowClick: k, onDeleteClick: A, onRetry: j, labels: M, emptyStateTestId: N }) {
27
+ let P = {
28
+ ...c,
29
+ ...M
30
+ }, F = [
32
31
  {
33
32
  accessorKey: "name",
34
- header: F.columnName
33
+ header: P.columnName
35
34
  },
36
35
  {
37
36
  accessorKey: "categoryLabel",
38
- header: F.columnCategory
37
+ header: P.columnCategory
39
38
  },
40
39
  {
41
40
  accessorKey: "keywords",
42
- header: F.columnKeywords
41
+ header: P.columnKeywords
43
42
  },
44
43
  {
45
44
  accessorKey: "createdAtLabel",
46
45
  enableSorting: !0,
47
- header: ({ column: e }) => /* @__PURE__ */ u(y, {
48
- label: F.columnCreatedAt,
46
+ header: ({ column: e }) => /* @__PURE__ */ l(v, {
47
+ label: P.columnCreatedAt,
49
48
  isSorted: e.getIsSorted(),
50
49
  onToggle: () => e.toggleSorting(e.getIsSorted() === "asc")
51
50
  })
@@ -53,88 +52,88 @@ function b({ tags: f, isLoading: p, isError: m, sorting: b, onSortingChange: x,
53
52
  {
54
53
  accessorKey: "updatedAtLabel",
55
54
  enableSorting: !0,
56
- header: ({ column: e }) => /* @__PURE__ */ u(y, {
57
- label: F.columnUpdatedAt,
55
+ header: ({ column: e }) => /* @__PURE__ */ l(v, {
56
+ label: P.columnUpdatedAt,
58
57
  isSorted: e.getIsSorted(),
59
58
  onToggle: () => e.toggleSorting(e.getIsSorted() === "asc")
60
59
  })
61
60
  },
62
61
  {
63
62
  accessorKey: "createdByLabel",
64
- header: F.columnCreatedBy
63
+ header: P.columnCreatedBy
65
64
  },
66
65
  {
67
66
  id: "actions",
68
- header: () => /* @__PURE__ */ u("div", {
67
+ header: () => /* @__PURE__ */ l("div", {
69
68
  className: "ttw:text-right",
70
- children: F.columnActions
69
+ children: P.columnActions
71
70
  }),
72
- cell: ({ row: t }) => /* @__PURE__ */ u("div", {
71
+ cell: ({ row: t }) => /* @__PURE__ */ l("div", {
73
72
  className: "ttw:flex ttw:justify-end",
74
- children: /* @__PURE__ */ d(n, { children: [/* @__PURE__ */ u(a, {
73
+ children: /* @__PURE__ */ u(n, { children: [/* @__PURE__ */ l(a, {
75
74
  asChild: !0,
76
- children: /* @__PURE__ */ d(e, {
75
+ children: /* @__PURE__ */ u(e, {
77
76
  variant: "ghost",
78
77
  size: "icon-sm",
79
78
  onClick: (e) => e.stopPropagation(),
80
- children: [/* @__PURE__ */ u("span", {
79
+ children: [/* @__PURE__ */ l("span", {
81
80
  className: "ttw:sr-only",
82
- children: F.openActionsMenu
83
- }), /* @__PURE__ */ u(h, { className: "ttw:size-4" })]
81
+ children: P.openActionsMenu
82
+ }), /* @__PURE__ */ l(m, { className: "ttw:size-4" })]
84
83
  })
85
- }), /* @__PURE__ */ u(r, {
84
+ }), /* @__PURE__ */ l(r, {
86
85
  align: "end",
87
- children: /* @__PURE__ */ d(i, {
86
+ children: /* @__PURE__ */ u(i, {
88
87
  variant: "destructive",
89
88
  onClick: (e) => {
90
- e.stopPropagation(), j(t.original);
89
+ e.stopPropagation(), A(t.original);
91
90
  },
92
- children: [/* @__PURE__ */ u(_, { className: "ttw:size-4" }), F.actionDelete]
91
+ children: [/* @__PURE__ */ l(g, { className: "ttw:size-4" }), P.actionDelete]
93
92
  })
94
93
  })] })
95
94
  })
96
95
  }
97
96
  ];
98
- return /* @__PURE__ */ d("div", {
97
+ return /* @__PURE__ */ u("div", {
99
98
  className: "ttw:flex ttw:flex-col ttw:gap-4",
100
- children: [/* @__PURE__ */ d("div", {
101
- className: "ttw:flex ttw:items-center ttw:justify-between",
102
- children: [/* @__PURE__ */ u(c, { children: F.title }), /* @__PURE__ */ d(e, {
99
+ children: [/* @__PURE__ */ l("div", {
100
+ className: "ttw:flex ttw:items-center ttw:justify-end",
101
+ children: /* @__PURE__ */ u(e, {
103
102
  size: "sm",
104
- onClick: k,
105
- children: [/* @__PURE__ */ u(g, {
103
+ onClick: O,
104
+ children: [/* @__PURE__ */ l(h, {
106
105
  "aria-hidden": !0,
107
106
  className: "ttw:size-4"
108
- }), F.createButton]
109
- })]
110
- }), m ? /* @__PURE__ */ u(s, {
111
- title: F.errorTitle,
112
- description: F.errorDescription,
113
- retryLabel: M ? F.errorRetry : void 0,
114
- onRetry: M
115
- }) : /* @__PURE__ */ u(t, {
116
- columns: I,
117
- data: f,
118
- isLoading: p,
119
- sorting: b,
120
- onSortingChange: x,
121
- pageSize: S,
122
- onPageSizeChange: C,
123
- pageSizeOptions: w,
124
- hasNextPage: T,
125
- hasPrevPage: E,
126
- onNextPage: D,
127
- onPrevPage: O,
128
- onRowClick: A,
129
- children: /* @__PURE__ */ u(o, {
130
- testId: P,
131
- title: F.emptyTitle,
132
- description: F.emptyDescription,
133
- actionLabel: F.emptyAction,
134
- onAction: k
107
+ }), P.createButton]
108
+ })
109
+ }), p ? /* @__PURE__ */ l(s, {
110
+ title: P.errorTitle,
111
+ description: P.errorDescription,
112
+ retryLabel: j ? P.errorRetry : void 0,
113
+ onRetry: j
114
+ }) : /* @__PURE__ */ l(t, {
115
+ columns: F,
116
+ data: d,
117
+ isLoading: f,
118
+ sorting: y,
119
+ onSortingChange: b,
120
+ pageSize: x,
121
+ onPageSizeChange: S,
122
+ pageSizeOptions: C,
123
+ hasNextPage: w,
124
+ hasPrevPage: T,
125
+ onNextPage: E,
126
+ onPrevPage: D,
127
+ onRowClick: k,
128
+ children: /* @__PURE__ */ l(o, {
129
+ testId: N,
130
+ title: P.emptyTitle,
131
+ description: P.emptyDescription,
132
+ actionLabel: P.emptyAction,
133
+ onAction: O
135
134
  })
136
135
  })]
137
136
  });
138
137
  }
139
138
  //#endregion
140
- export { b as TagsScreen, b as default };
139
+ export { y as TagsScreen, y as default };