@tesouro/embedded-components-react 0.8.1 → 0.8.4

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 (97) hide show
  1. package/dist/index.css +0 -61
  2. package/dist/index.d.ts +1 -3
  3. package/dist/lib/ProductsWidget.d.ts +1 -3
  4. package/dist/lib/ReceivablesWidget.d.ts +1 -3
  5. package/dist/lib/monite-sdk.d.ts +6 -59
  6. package/dist/lib/monite-sdk.js +9 -13
  7. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index.js +10 -14
  8. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index112.js +2 -12
  9. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index113.js +19 -26
  10. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index151.js +4 -78
  11. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index17.js +4 -23
  12. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index187.js +24 -1
  13. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index188.js +73 -35
  14. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index189.js +19 -1
  15. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index190.js +19 -16
  16. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index191.js +5 -17
  17. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index192.js +8 -4
  18. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index193.js +11 -16
  19. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index194.js +129 -20
  20. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index195.js +5 -21
  21. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index196.js +2 -2
  22. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index197.js +5 -8
  23. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index198.js +218 -13
  24. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index199.js +31 -17
  25. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index200.js +14 -9
  26. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index201.js +33 -24
  27. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index202.js +19 -12
  28. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index203.js +73 -8
  29. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index204.js +180 -23
  30. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index205.js +13 -13
  31. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index206.js +203 -80
  32. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index207.js +100 -14
  33. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index208.js +61 -97
  34. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index209.js +53 -42
  35. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index210.js +89 -25
  36. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index211.js +43 -1
  37. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index212.js +75 -102
  38. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index213.js +82 -34
  39. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index214.js +12 -171
  40. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index215.js +24 -12
  41. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index216.js +17 -4
  42. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index217.js +4 -69
  43. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index218.js +20 -23
  44. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index219.js +1 -212
  45. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index220.js +17 -92
  46. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index221.js +30 -20
  47. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index222.js +4 -1
  48. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index223.js +21 -17
  49. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index224.js +15 -157
  50. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index225.js +28 -99
  51. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index226.js +28 -43
  52. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index227.js +2 -4
  53. package/dist/libs/tesouro-embedded-components-react/shared/feature/dist/lib/analytics/build-info.js +1 -1
  54. package/dist/libs/tesouro-embedded-components-react/shared/product-catalog/ui/dist/index2.js +1 -2
  55. package/dist/libs/tesouro-embedded-components-react/shared/product-catalog/ui/dist/index6.js +1 -1
  56. package/package.json +1 -3
  57. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index228.js +0 -24
  58. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index229.js +0 -77
  59. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index230.js +0 -19
  60. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index231.js +0 -22
  61. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index232.js +0 -8
  62. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index233.js +0 -12
  63. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index234.js +0 -13
  64. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index235.js +0 -133
  65. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index236.js +0 -8
  66. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index237.js +0 -8
  67. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index238.js +0 -5
  68. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index239.js +0 -222
  69. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index240.js +0 -34
  70. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index241.js +0 -14
  71. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index242.js +0 -36
  72. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index243.js +0 -22
  73. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index244.js +0 -76
  74. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index245.js +0 -184
  75. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index246.js +0 -16
  76. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index247.js +0 -206
  77. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index248.js +0 -102
  78. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index249.js +0 -66
  79. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index250.js +0 -57
  80. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index251.js +0 -94
  81. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index252.js +0 -43
  82. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index253.js +0 -79
  83. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index254.js +0 -87
  84. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index255.js +0 -14
  85. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index256.js +0 -26
  86. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index257.js +0 -17
  87. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index258.js +0 -5
  88. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index259.js +0 -24
  89. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index260.js +0 -1
  90. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index261.js +0 -22
  91. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index262.js +0 -32
  92. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index263.js +0 -4
  93. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index264.js +0 -23
  94. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index265.js +0 -18
  95. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index266.js +0 -33
  96. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index267.js +0 -31
  97. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index268.js +0 -2
@@ -1,39 +1,87 @@
1
- import { Button as e } from "./index110.js";
2
- import { Sheet as t, SheetContent as n, SheetDescription as r, SheetFooter as i, SheetHeader as a, SheetTitle as o } from "./index206.js";
3
- import { ManageMeasureUnitsForm as s } from "./index212.js";
4
- import { jsx as c, jsxs as l } from "@emotion/react/jsx-runtime";
5
- import { useLingui as u } from "@lingui/react";
1
+ import { Fragment as e } from "react";
2
+ import { jsx as t, jsxs as n } from "@emotion/react/jsx-runtime";
3
+ import { Box as r, List as i, ListItem as a, Typography as o, lighten as s, useTheme as c } from "@mui/material";
4
+ import { useLingui as l } from "@lingui/react";
5
+ import u from "@mui/icons-material/MonetizationOnOutlined";
6
6
  //#region ../../libs/tesouro-embedded-components-react/monite-sdk/dist/index213.js
7
- var d = ({ handleClose: d, open: f }) => {
8
- let { i18n: p } = u();
9
- return /* @__PURE__ */ c(t, {
10
- open: f,
11
- onOpenChange: d,
12
- children: /* @__PURE__ */ l(n, {
13
- side: "right",
14
- className: "ttw:gap-0 ttw:p-0",
15
- children: [
16
- /* @__PURE__ */ l(a, {
17
- className: "ttw:border-b ttw:border-border",
18
- children: [/* @__PURE__ */ c(o, { children: p._("Manage measure units") }), /* @__PURE__ */ c(r, {
19
- hidden: !0,
20
- children: p._("Manage measure units")
7
+ var d = ({ offers: d }) => {
8
+ let { i18n: f } = l(), p = c();
9
+ return !d || d.length === 0 ? null : /* @__PURE__ */ n(r, {
10
+ width: "100%",
11
+ children: [/* @__PURE__ */ t(o, {
12
+ variant: "subtitle1",
13
+ sx: {
14
+ mb: 3,
15
+ display: "inline-block"
16
+ },
17
+ children: f._("Current offer")
18
+ }), /* @__PURE__ */ t(r, {
19
+ sx: {
20
+ display: "flex",
21
+ gap: 2,
22
+ flexWrap: "wrap"
23
+ },
24
+ children: d.map((c, l) => c?.pricing_plans?.map((d, m) => /* @__PURE__ */ n(r, {
25
+ width: 232,
26
+ height: 148,
27
+ px: 3,
28
+ py: 2.5,
29
+ sx: {
30
+ backgroundColor: p.palette.background.paper,
31
+ borderRadius: "16px",
32
+ border: `1px solid ${p.palette.divider}`
33
+ },
34
+ children: [/* @__PURE__ */ n(r, {
35
+ sx: {
36
+ display: "flex",
37
+ alignItems: "center",
38
+ gap: 1,
39
+ mb: 2
40
+ },
41
+ children: [/* @__PURE__ */ t(u, { sx: {
42
+ fontSize: 24,
43
+ color: s(p.palette.primary.main, .6)
44
+ } }), /* @__PURE__ */ t(o, {
45
+ variant: "body1",
46
+ fontWeight: 500,
47
+ sx: {
48
+ flex: "1 1 0%",
49
+ width: "100%"
50
+ },
51
+ children: f._("Financing plan")
21
52
  })]
22
- }),
23
- /* @__PURE__ */ c("div", {
24
- className: "ttw:flex-1 ttw:overflow-y-auto ttw:px-6 ttw:py-4",
25
- children: /* @__PURE__ */ c(s, {})
26
- }),
27
- /* @__PURE__ */ c(i, {
28
- className: "ttw:border-t ttw:border-border ttw:flex-row ttw:justify-end",
29
- children: /* @__PURE__ */ c(e, {
30
- onClick: d,
31
- children: p._("Done")
32
- })
33
- })
34
- ]
35
- })
53
+ }), /* @__PURE__ */ t(i, {
54
+ sx: { p: 0 },
55
+ children: /* @__PURE__ */ n(e, { children: [
56
+ /* @__PURE__ */ t(a, {
57
+ sx: { p: 0 },
58
+ children: /* @__PURE__ */ t(o, {
59
+ variant: "body1",
60
+ fontWeight: 400,
61
+ children: f._("{itemAdvance_rate_percentage}% advance rate", { itemAdvance_rate_percentage: d.advance_rate_percentage / 100 })
62
+ })
63
+ }),
64
+ /* @__PURE__ */ t(a, {
65
+ sx: { p: 0 },
66
+ children: /* @__PURE__ */ t(o, {
67
+ variant: "body1",
68
+ fontWeight: 400,
69
+ children: f._("Pay in {itemRepayment_duration_days} days", { itemRepayment_duration_days: d.repayment_duration_days })
70
+ })
71
+ }),
72
+ /* @__PURE__ */ t(a, {
73
+ sx: { p: 0 },
74
+ children: /* @__PURE__ */ t(o, {
75
+ variant: "body1",
76
+ fontWeight: 400,
77
+ children: f._("{itemFee_percentage}% fee", { itemFee_percentage: d.fee_percentage / 100 })
78
+ })
79
+ })
80
+ ] }, d.advance_rate_percentage)
81
+ })]
82
+ }, `${c.available_amount}-${l}-${c.total_amount}-${m}`)))
83
+ })]
36
84
  });
37
85
  };
38
86
  //#endregion
39
- export { d as ManageMeasureUnits };
87
+ export { d as FinanceOffers };
@@ -1,173 +1,14 @@
1
- import { Scope as e } from "../../shared/data-access/dist/lib/scopes.js";
2
- import "../../shared/data-access/dist/index.js";
3
- import { useMoniteContext as t } from "./index36.js";
4
- import { useCurrencies as n } from "./index62.js";
5
- import "./index73.js";
6
- import { Button as r } from "./index110.js";
7
- import { MoniteScopedProviders as i } from "./index143.js";
8
- import { useUserPermissions as a } from "./index144.js";
9
- import { GetNoRowsOverlay as o } from "./index149.js";
10
- import { AccessRestriction as s } from "./index150.js";
11
- import "./index153.js";
12
- import { DataTable as c } from "./index156.js";
13
- import { hasSelectedText as l } from "./index157.js";
14
- import { useGetProducts as u } from "./index196.js";
15
- import "./index200.js";
16
- import { ProductDeleteModal as d } from "./index201.js";
17
- import { ProductType as f } from "./index202.js";
18
- import { FILTER_TYPE_SEARCH as p } from "./index203.js";
19
- import { Filters as m } from "./index204.js";
20
- import { MeasureUnit as ee } from "./index205.js";
21
- import { ManageMeasureUnits as h } from "./index213.js";
22
- import { useCallback as g, useMemo as _, useState as v } from "react";
23
- import { ArrowDown as y, ArrowUp as b, ArrowUpDown as x, Plus as S } from "lucide-react";
24
- import { Fragment as C, jsx as w, jsxs as T } from "@emotion/react/jsx-runtime";
25
- import { useLingui as E } from "@lingui/react";
1
+ import { FinanceLimits as e } from "./index212.js";
2
+ import { FinanceOffers as t } from "./index213.js";
3
+ import { jsx as n, jsxs as r } from "@emotion/react/jsx-runtime";
4
+ import { Box as i } from "@mui/material";
26
5
  //#region ../../libs/tesouro-embedded-components-react/monite-sdk/dist/index214.js
27
- var D = (e) => /* @__PURE__ */ w(i, { children: /* @__PURE__ */ w(O, { ...e }) }), O = ({ onFilterChanged: i, onSortChanged: D, onRowClick: O, onDeleted: k, openCreateModal: A }) => {
28
- let { i18n: j } = E(), { componentSettings: M } = t(), { formatCurrencyToDisplay: N } = n(), [P, F] = v(!1), [I, L] = v(void 0), [R, z] = v(M.products.pageSizeOptions[0]), [B, te] = v({}), [V, H] = v(), [U, W] = v({
29
- open: !1,
30
- id: null
31
- }), G = a(), K = G.has(e.InvoiceWriteOrg), q = G.has(e.InvoiceReadOrg), { data: J, isLoading: Y, isError: X, refetch: Z } = u({
32
- sort: V?.field,
33
- order: V?.sort,
34
- limit: R,
35
- pagination_token: I,
36
- name__icontains: B.search || void 0
37
- }), Q = (e, t) => {
38
- L(void 0), te((n) => ({
39
- ...n,
40
- [e]: t === "all" ? null : t
41
- })), i?.({
42
- field: e,
43
- value: t
44
- });
45
- }, $ = _(() => V ? [{
46
- id: V.field,
47
- desc: V.sort === "desc"
48
- }] : [], [V]), ne = g((e) => {
49
- let t = typeof e == "function" ? e($) : e;
50
- if (t.length > 0) {
51
- let e = {
52
- field: t[0].id,
53
- sort: t[0].desc ? "desc" : "asc"
54
- };
55
- H(e), D?.(e);
56
- } else H(void 0);
57
- L(void 0);
58
- }, [$, D]), re = _(() => [
59
- {
60
- accessorKey: "name",
61
- header: ({ column: e }) => {
62
- let t = e.getIsSorted();
63
- return /* @__PURE__ */ T("div", {
64
- className: "ttw:flex ttw:items-center ttw:gap-2 ttw:text-inherit",
65
- children: [j._("Name"), /* @__PURE__ */ w(r, {
66
- variant: "ghost",
67
- onClick: () => e.toggleSorting(t === "asc"),
68
- children: w(t === "asc" ? b : t === "desc" ? y : x, { className: "ttw:size-4" })
69
- })]
70
- });
71
- },
72
- cell: ({ row: e }) => /* @__PURE__ */ w("span", { children: e.original.name })
73
- },
74
- {
75
- accessorKey: "type",
76
- header: j._("Type"),
77
- cell: ({ row: e }) => e.original.type ? /* @__PURE__ */ w(f, { type: e.original.type }) : null
78
- },
79
- {
80
- accessorKey: "description",
81
- header: j._("Description"),
82
- cell: ({ row: e }) => /* @__PURE__ */ w("div", {
83
- className: "ttw:w-120",
84
- children: /* @__PURE__ */ w("span", {
85
- className: "ttw:w-full ttw:inline-block ttw:truncate",
86
- children: e.original?.description
87
- })
88
- })
89
- },
90
- {
91
- accessorKey: "price",
92
- header: () => /* @__PURE__ */ w("div", {
93
- className: "ttw:text-right",
94
- children: j._("Price per unit")
95
- }),
96
- cell: ({ row: e }) => {
97
- let t = e.original.price;
98
- return /* @__PURE__ */ T("div", {
99
- className: "ttw:justify-end ttw:flex ttw:gap-1 ttw:items-center",
100
- children: [t ? N(t.value, t.currency) : "", /* @__PURE__ */ w(ee, { unitId: e.original.measure_unit_id ?? "" })]
101
- });
102
- }
103
- }
104
- ], [j, N]), ie = Object.keys(B).some((e) => B[e] !== null && B[e] !== void 0), ae = !!B[p];
105
- return q ? /* @__PURE__ */ T(C, { children: [
106
- /* @__PURE__ */ w("div", {
107
- className: "ttw:flex ttw:flex-col ttw:overflow-hidden ttw:min-h-125",
108
- children: /* @__PURE__ */ w(c, {
109
- columns: re,
110
- data: J?.data ?? [],
111
- sorting: $,
112
- onSortingChange: ne,
113
- pageSize: R,
114
- onPageSizeChange: z,
115
- nextPaginationToken: J?.next_pagination_token ?? void 0,
116
- prevPaginationToken: J?.prev_pagination_token ?? void 0,
117
- onPaginationTokenChange: L,
118
- onRowClick: (e) => {
119
- l() || O?.(e.id);
120
- },
121
- filterComponent: /* @__PURE__ */ T("div", {
122
- className: "ttw:flex ttw:items-center ttw:justify-between ttw:px-4",
123
- children: [/* @__PURE__ */ w(m, { onChangeFilter: Q }), /* @__PURE__ */ T("div", {
124
- className: "ttw:flex ttw:gap-2",
125
- children: [/* @__PURE__ */ w(r, {
126
- variant: "ghost",
127
- onClick: () => F(!0),
128
- className: "ttw:py-0 ttw:text-primary ttw:hover:text-primary",
129
- children: j._("Manage units of measure")
130
- }), /* @__PURE__ */ T(r, {
131
- disabled: !K,
132
- onClick: A,
133
- className: "ttw:py-0",
134
- children: [/* @__PURE__ */ w(S, {}), j._("Add product or service")]
135
- })]
136
- })]
137
- }),
138
- children: /* @__PURE__ */ w(o, {
139
- isLoading: Y,
140
- dataLength: J?.data.length || 0,
141
- isFiltering: ie,
142
- isSearching: ae,
143
- isError: X,
144
- onCreate: A,
145
- refetch: Z,
146
- filterTitle: j._("No product or service found"),
147
- filterDescription1: j._("Try adjusting your search or filter criteria"),
148
- entityName: j._("products or services"),
149
- actionButtonLabel: j._("Add your first product or service"),
150
- actionOptions: [j._("Product")],
151
- noDataTitle: j._("Build your products & services list."),
152
- noDataDescription1: j._("Save the products and services you sell so you can quickly add them as line items on invoices."),
153
- type: "no-data"
154
- })
155
- })
156
- }),
157
- U.id && /* @__PURE__ */ w(d, {
158
- id: U.id,
159
- open: U.open,
160
- onDeleted: k,
161
- onClose: () => W((e) => ({
162
- ...e,
163
- open: !1
164
- }))
165
- }),
166
- P && /* @__PURE__ */ w(h, {
167
- open: P,
168
- handleClose: () => F(!1)
169
- })
170
- ] }) : /* @__PURE__ */ w(s, {});
171
- };
6
+ var a = ({ offers: a }) => /* @__PURE__ */ r(i, {
7
+ sx: {
8
+ display: "flex",
9
+ gap: 2
10
+ },
11
+ children: [/* @__PURE__ */ n(e, { offers: a }), a?.[0]?.status === "CURRENT" && /* @__PURE__ */ n(t, { offers: a })]
12
+ });
172
13
  //#endregion
173
- export { D as ProductsTable };
14
+ export { a as FinanceWidget };
@@ -1,14 +1,26 @@
1
- import { cn as e } from "./index49.js";
2
- import "react";
3
- import { jsx as t } from "@emotion/react/jsx-runtime";
4
- import * as n from "@radix-ui/react-label";
1
+ import { useGetFinanceOffers as e } from "./index191.js";
2
+ import { useFinancing as t } from "./index194.js";
3
+ import "./index197.js";
4
+ import { FinancedInvoicesTable as n } from "./index206.js";
5
+ import { FinanceWidget as r } from "./index214.js";
6
+ import { jsx as i, jsxs as a } from "@emotion/react/jsx-runtime";
7
+ import { CircularProgress as o, Stack as s } from "@mui/material";
5
8
  //#region ../../libs/tesouro-embedded-components-react/monite-sdk/dist/index215.js
6
- function r({ className: r, ...i }) {
7
- return /* @__PURE__ */ t(n.Root, {
8
- "data-slot": "label",
9
- className: e("ttw:flex ttw:items-center ttw:gap-2 ttw:text-sm ttw:leading-none ttw:font-medium ttw:select-none ttw:group-data-[disabled=true]:pointer-events-none ttw:group-data-[disabled=true]:opacity-50 ttw:peer-disabled:cursor-not-allowed ttw:peer-disabled:opacity-50", r),
10
- ...i
11
- });
12
- }
9
+ var c = ({ onRowClick: c }) => {
10
+ let { isLoading: l, data: u } = e(), { isLoading: d, isEnabled: f } = t();
11
+ return d || l ? /* @__PURE__ */ i(o, {
12
+ color: "inherit",
13
+ size: 20
14
+ }) : f ? /* @__PURE__ */ a(s, {
15
+ mt: 4,
16
+ gap: 4,
17
+ px: 1.5,
18
+ height: "100%",
19
+ children: [u?.offers && u.offers.length > 0 && /* @__PURE__ */ i(r, { offers: u.offers }), /* @__PURE__ */ i(n, {
20
+ onRowClick: c,
21
+ offers: u?.offers
22
+ })]
23
+ }) : null;
24
+ };
13
25
  //#endregion
14
- export { r as Label };
26
+ export { c as FinanceTab };
@@ -1,4 +1,17 @@
1
- import "./index49.js";
2
- import "react";
3
- import "@emotion/react/jsx-runtime";
4
- import "radix-ui";
1
+ import "./index187.js";
2
+ import "./index188.js";
3
+ import "./index189.js";
4
+ import "./index190.js";
5
+ import "./index198.js";
6
+ import "./index208.js";
7
+ import "./index201.js";
8
+ import "./index204.js";
9
+ import "./index209.js";
10
+ import "./index210.js";
11
+ import "./index206.js";
12
+ import "./index207.js";
13
+ import "./index211.js";
14
+ import "./index212.js";
15
+ import "./index213.js";
16
+ import "./index214.js";
17
+ import "./index215.js";
@@ -1,70 +1,5 @@
1
- import { cn as e } from "./index49.js";
2
- import { Label as t } from "./index215.js";
1
+ import "./index198.js";
2
+ import "./index208.js";
3
+ import "./index210.js";
4
+ import "./index215.js";
3
5
  import "./index216.js";
4
- import { useMemo as n } from "react";
5
- import { jsx as r, jsxs as i } from "@emotion/react/jsx-runtime";
6
- import { cva as a } from "class-variance-authority";
7
- //#region ../../libs/tesouro-embedded-components-react/monite-sdk/dist/index217.js
8
- var o = a("ttw:group/field ttw:flex ttw:w-full ttw:gap-3 ttw:data-[invalid=true]:text-destructive", {
9
- variants: { orientation: {
10
- vertical: ["flex-col [&>*]:w-full [&>.sr-only]:w-auto"],
11
- horizontal: [
12
- "flex-row items-center",
13
- "[&>[data-slot=field-label]]:flex-auto",
14
- "has-[>[data-slot=field-content]]:items-start has-[>[data-slot=field-content]]:[&>[role=checkbox],[role=radio]]:mt-px"
15
- ],
16
- responsive: [
17
- "flex-col @md/field-group:flex-row @md/field-group:items-center [&>*]:w-full @md/field-group:[&>*]:w-auto [&>.sr-only]:w-auto",
18
- "@md/field-group:[&>[data-slot=field-label]]:flex-auto",
19
- "@md/field-group:has-[>[data-slot=field-content]]:items-start @md/field-group:has-[>[data-slot=field-content]]:[&>[role=checkbox],[role=radio]]:mt-px"
20
- ]
21
- } },
22
- defaultVariants: { orientation: "vertical" }
23
- });
24
- function s({ className: t, orientation: n = "vertical", ...i }) {
25
- return /* @__PURE__ */ r("div", {
26
- role: "group",
27
- "data-slot": "field",
28
- "data-orientation": n,
29
- className: e(o({ orientation: n }), t),
30
- ...i
31
- });
32
- }
33
- function c({ className: t, ...n }) {
34
- return /* @__PURE__ */ r("div", {
35
- "data-slot": "field-content",
36
- className: e("ttw:group/field-content ttw:flex ttw:flex-1 ttw:flex-col ttw:gap-1.5 ttw:leading-snug", t),
37
- ...n
38
- });
39
- }
40
- function l({ className: n, required: a, children: o, ...s }) {
41
- return /* @__PURE__ */ i(t, {
42
- "data-slot": "field-label",
43
- className: e("ttw:group/field-label ttw:peer/field-label ttw:flex ttw:w-fit ttw:items-center ttw:gap-2 ttw:leading-snug ttw:group-data-[disabled=true]/field:opacity-50", "ttw:has-[>[data-slot=field]]:w-full ttw:has-[>[data-slot=field]]:flex-col ttw:has-[>[data-slot=field]]:rounded-md ttw:has-[>[data-slot=field]]:border ttw:[&>*]:data-[slot=field]:p-4", "ttw:has-data-[state=checked]:border-primary ttw:has-data-[state=checked]:bg-primary/5 ttw:dark:has-data-[state=checked]:bg-primary/10", n),
44
- ...s,
45
- children: [o, a && /* @__PURE__ */ r("span", {
46
- "aria-hidden": "true",
47
- className: "ttw:size-2 ttw:-ml-1 ttw:block ttw:-mt-1 ttw:rounded-full ttw:bg-destructive ttw:shrink-0"
48
- })]
49
- });
50
- }
51
- function u({ className: t, children: i, errors: a, ...o }) {
52
- let s = n(() => {
53
- if (i) return i;
54
- if (!a?.length) return null;
55
- let e = [...new Map(a.map((e) => [e?.message, e])).values()];
56
- return e?.length == 1 ? e[0]?.message : /* @__PURE__ */ r("ul", {
57
- className: "ttw:ml-4 ttw:flex ttw:list-disc ttw:flex-col ttw:gap-1",
58
- children: e.map((e, t) => e?.message && /* @__PURE__ */ r("li", { children: e.message }, t))
59
- });
60
- }, [i, a]);
61
- return s ? /* @__PURE__ */ r("div", {
62
- role: "alert",
63
- "data-slot": "field-error",
64
- className: e("ttw:text-sm ttw:font-normal ttw:text-destructive", t),
65
- ...o,
66
- children: s
67
- }) : null;
68
- }
69
- //#endregion
70
- export { s as Field, c as FieldContent, u as FieldError, l as FieldLabel };
@@ -1,27 +1,24 @@
1
- import { cn as e } from "./index49.js";
2
- import "react";
3
- import { CircleIcon as t } from "lucide-react";
4
- import { jsx as n } from "@emotion/react/jsx-runtime";
5
- import * as r from "@radix-ui/react-radio-group";
1
+ import { MoniteScopedProviders as e } from "./index143.js";
2
+ import { PageHeader as t } from "./index165.js";
3
+ import { FinanceIntegrationCard as n } from "./index208.js";
4
+ import "./index217.js";
5
+ import { Fragment as r, jsx as i, jsxs as a } from "@emotion/react/jsx-runtime";
6
+ import { Box as o } from "@mui/material";
7
+ import { useLingui as s } from "@lingui/react";
6
8
  //#region ../../libs/tesouro-embedded-components-react/monite-sdk/dist/index218.js
7
- function i({ className: t, ...i }) {
8
- return /* @__PURE__ */ n(r.Root, {
9
- "data-slot": "radio-group",
10
- className: e("ttw:grid ttw:gap-3", t),
11
- ...i
12
- });
9
+ function c() {
10
+ return /* @__PURE__ */ i(e, { children: /* @__PURE__ */ i(l, {}) });
13
11
  }
14
- function a({ className: i, dotClassName: a, ...o }) {
15
- return /* @__PURE__ */ n(r.Item, {
16
- "data-slot": "radio-group-item",
17
- className: e("ttw:border-input ttw:text-primary ttw:focus-visible:border-ring ttw:focus-visible:ring-ring/50 ttw:aria-invalid:ring-destructive/20 ttw:dark:aria-invalid:ring-destructive/40 ttw:aria-invalid:border-destructive ttw:dark:bg-input/30 ttw:aspect-square ttw:size-4 ttw:shrink-0 ttw:rounded-full ttw:border ttw:shadow-xs ttw:transition-[color,box-shadow] ttw:outline-none ttw:focus-visible:ring-[3px] ttw:disabled:cursor-not-allowed ttw:disabled:opacity-50", i),
18
- ...o,
19
- children: /* @__PURE__ */ n(r.Indicator, {
20
- "data-slot": "radio-group-indicator",
21
- className: "ttw:relative ttw:flex ttw:items-center ttw:justify-center",
22
- children: /* @__PURE__ */ n(t, { className: e("ttw:fill-primary ttw:absolute ttw:top-1/2 ttw:left-1/2 ttw:size-2 ttw:-translate-x-1/2 ttw:-translate-y-1/2", a) })
23
- })
24
- });
12
+ function l() {
13
+ let { i18n: e } = s();
14
+ return /* @__PURE__ */ a(o, { children: [/* @__PURE__ */ i(t, { title: /* @__PURE__ */ i(r, { children: e._("Integrations") }) }), /* @__PURE__ */ i(o, {
15
+ sx: {
16
+ display: "grid",
17
+ gridTemplateColumns: "minmax(360px, 480px) minmax(360px, 480px)",
18
+ gap: 2
19
+ },
20
+ children: /* @__PURE__ */ i(n, {})
21
+ })] });
25
22
  }
26
23
  //#endregion
27
- export { i as RadioGroup, a as RadioGroupItem };
24
+ export { c as Integrations };