@tesouro/embedded-components-react 0.3.20 → 0.3.22

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 (154) hide show
  1. package/dist/index.css +9 -0
  2. package/dist/lib/monite-sdk.js +18 -18
  3. package/dist/libs/tesouro-embedded-components-react/invoicing-widget/feature/dist/index3.js +1 -1
  4. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index.js +19 -19
  5. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index422.js +1 -1
  6. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index479.js +16 -20
  7. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index480.js +13 -12
  8. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index481.js +19 -97
  9. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index482.js +98 -42
  10. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index483.js +43 -27
  11. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index484.js +30 -1
  12. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index485.js +1 -17
  13. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index486.js +11 -10
  14. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index487.js +14 -4
  15. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index488.js +4 -13
  16. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index489.js +7 -7
  17. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index490.js +18 -9
  18. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index491.js +8 -105
  19. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index492.js +102 -35
  20. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index493.js +36 -45
  21. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index494.js +44 -71
  22. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index495.js +72 -100
  23. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index496.js +99 -43
  24. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index497.js +35 -178
  25. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index498.js +171 -125
  26. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index499.js +134 -123
  27. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index500.js +125 -73
  28. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index501.js +63 -232
  29. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index502.js +248 -8
  30. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index503.js +8 -6
  31. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index504.js +5 -456
  32. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index505.js +455 -21
  33. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index506.js +17 -12
  34. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index507.js +13 -49
  35. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index508.js +51 -43
  36. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index509.js +46 -14
  37. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index510.js +13 -41
  38. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index511.js +39 -144
  39. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index512.js +143 -112
  40. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index513.js +114 -39
  41. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index514.js +33 -25
  42. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index515.js +32 -19
  43. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index516.js +3 -3
  44. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index517.js +19 -21
  45. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index518.js +20 -72
  46. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index519.js +73 -17
  47. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index520.js +18 -172
  48. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index521.js +149 -116
  49. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index522.js +136 -30
  50. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index523.js +31 -115
  51. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index524.js +116 -19
  52. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index525.js +10 -36
  53. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index526.js +46 -14
  54. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index527.js +13 -23
  55. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index528.js +21 -25
  56. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index529.js +26 -36
  57. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index530.js +36 -77
  58. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index531.js +77 -50
  59. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index532.js +50 -33
  60. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index533.js +34 -89
  61. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index534.js +86 -48
  62. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index535.js +54 -1
  63. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index536.js +1 -40
  64. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index537.js +40 -1
  65. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index538.js +0 -135
  66. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index539.js +129 -102
  67. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index540.js +105 -50
  68. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index541.js +48 -779
  69. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index542.js +780 -87
  70. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index543.js +84 -97
  71. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index544.js +105 -6
  72. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index545.js +6 -27
  73. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index546.js +23 -11
  74. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index547.js +13 -2
  75. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index548.js +2 -25
  76. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index549.js +25 -14
  77. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index550.js +14 -171
  78. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index551.js +163 -200
  79. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index552.js +204 -78
  80. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index553.js +82 -17
  81. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index554.js +17 -158
  82. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index555.js +146 -85
  83. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index556.js +95 -42
  84. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index557.js +46 -4
  85. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index558.js +4 -16
  86. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index559.js +13 -24
  87. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index560.js +27 -1
  88. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index561.js +0 -186
  89. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index562.js +186 -0
  90. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index563.js +0 -42
  91. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index564.js +41 -3
  92. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index565.js +5 -24
  93. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index566.js +20 -73
  94. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index567.js +74 -16
  95. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index568.js +16 -19
  96. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index569.js +19 -5
  97. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index570.js +4 -8
  98. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index571.js +10 -11
  99. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index572.js +11 -131
  100. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index573.js +129 -4
  101. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index574.js +4 -4
  102. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index575.js +8 -5
  103. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index576.js +4 -221
  104. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index577.js +219 -11
  105. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index578.js +12 -34
  106. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index579.js +32 -181
  107. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index580.js +168 -189
  108. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index581.js +192 -88
  109. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index582.js +97 -61
  110. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index583.js +63 -54
  111. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index584.js +46 -83
  112. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index585.js +91 -40
  113. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index586.js +39 -75
  114. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index587.js +63 -71
  115. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index588.js +85 -12
  116. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index589.js +12 -24
  117. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index590.js +25 -16
  118. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index591.js +14 -2
  119. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index592.js +4 -23
  120. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index593.js +23 -0
  121. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index594.js +1 -24
  122. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index595.js +24 -4
  123. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index596.js +4 -13
  124. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index597.js +9 -13
  125. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index598.js +13 -4
  126. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index599.js +4 -8
  127. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index600.js +8 -4
  128. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index601.js +8 -6
  129. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index602.js +6 -22
  130. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index603.js +17 -68
  131. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index604.js +66 -113
  132. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index605.js +104 -64
  133. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index606.js +72 -138
  134. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index607.js +144 -28
  135. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index608.js +28 -16
  136. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index609.js +14 -87
  137. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index610.js +91 -3
  138. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index611.js +3 -26
  139. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index612.js +22 -67
  140. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index613.js +71 -1
  141. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index614.js +0 -65
  142. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index615.js +66 -29
  143. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index616.js +30 -2
  144. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index617.js +2 -34
  145. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index618.js +33 -15
  146. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index619.js +14 -29
  147. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index620.js +29 -26
  148. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index621.js +30 -2
  149. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index622.js +2 -97
  150. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index623.js +97 -0
  151. package/dist/libs/tesouro-embedded-components-react/settings-widget/feature/dist/index6.js +1 -1
  152. package/dist/libs/tesouro-embedded-components-react/shared/feature/dist/lib/analytics/build-info.js +1 -1
  153. package/dist/libs/tesouro-embedded-components-react/shared/monite-wrapper/feature/dist/lib/MoniteWrapper.js +1 -1
  154. package/package.json +1 -1
@@ -1,187 +1 @@
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 "./index47.js";
4
- import { Button as n } from "./index56.js";
5
- import { MoniteScopedProviders as r } from "./index237.js";
6
- import { DropdownMenu as i, DropdownMenuContent as a, DropdownMenuItem as o, DropdownMenuTrigger as s } from "./index55.js";
7
- import { useUserPermissions as c } from "./index116.js";
8
- import { GetNoRowsOverlay as l } from "./index246.js";
9
- import { DataTable as u } from "./index251.js";
10
- import { hasSelectedText as d } from "./index252.js";
11
- import { getTagCategoryLabel as f } from "./index305.js";
12
- import { useTags as p } from "./index306.js";
13
- import { TagFormModal as m } from "./index309.js";
14
- import "./index310.js";
15
- import { UserCell as h } from "./index558.js";
16
- import { ConfirmDeleteModal as g } from "./index559.js";
17
1
  import "./index560.js";
18
- import { useCallback as _, useMemo as v, useState as y } from "react";
19
- import { ArrowDown as b, ArrowUp as x, ArrowUpDown as S, MoreVertical as C, Trash as w } from "lucide-react";
20
- import { Fragment as ee, jsx as T, jsxs as E } from "@emotion/react/jsx-runtime";
21
- import { useLingui as D } from "@lingui/react";
22
- //#region ../../libs/tesouro-embedded-components-react/monite-sdk/dist/index561.js
23
- var O = (e) => /* @__PURE__ */ T(r, { children: /* @__PURE__ */ T(k, { ...e }) }), k = ({ onChangeSort: r, showCreationModal: O }) => {
24
- let { i18n: k } = D(), { api: A, locale: j, componentSettings: M } = t(), [N, P] = y(void 0), [F, I] = y(M.tags.pageSizeOptions[0]), [L, R] = y({
25
- field: "created_at",
26
- sort: "desc"
27
- }), [z, B] = y(void 0), [V, H] = y(!1), [U, W] = y(!1), { tagsWithKeywords: G } = p({}), K = c().has(e.AccountingConfigWriteOrg), { data: q, isLoading: J, isError: Y, refetch: X } = A.finops.getTags.useQuery({ query: {
28
- sort: L.field,
29
- order: L.sort,
30
- limit: F,
31
- pagination_token: N
32
- } }), Z = _(() => {
33
- H(!1);
34
- }, []), Q = _(() => {
35
- B(void 0), H(!1), W(!1);
36
- }, []), $ = v(() => [{
37
- id: L.field,
38
- desc: L.sort === "desc"
39
- }], [L]), te = _((e) => {
40
- let t = typeof e == "function" ? e($) : e;
41
- if (t.length > 0) {
42
- let e = {
43
- field: t[0].id,
44
- sort: t[0].desc ? "desc" : "asc"
45
- };
46
- R(e), r?.(e);
47
- }
48
- P(void 0);
49
- }, [$, r]), ne = (q?.data ?? []).map((e) => ({
50
- ...e,
51
- keywords: G[e.id]?.join(", ")
52
- })), re = v(() => [
53
- {
54
- accessorKey: "name",
55
- header: ({ column: e }) => {
56
- let t = e.getIsSorted();
57
- return /* @__PURE__ */ E("div", {
58
- className: "ttw:flex ttw:items-center ttw:gap-2 ttw:text-inherit",
59
- children: [k._("Name"), /* @__PURE__ */ T(n, {
60
- variant: "ghost",
61
- onClick: () => e.toggleSorting(t === "asc"),
62
- children: T(t === "asc" ? x : t === "desc" ? b : S, { className: "ttw:size-4" })
63
- })]
64
- });
65
- },
66
- cell: ({ row: e }) => /* @__PURE__ */ T("span", { children: e.original.name })
67
- },
68
- {
69
- accessorKey: "category",
70
- header: k._("Category"),
71
- cell: ({ row: e }) => /* @__PURE__ */ T("span", { children: f(e.original.category, k) })
72
- },
73
- {
74
- accessorKey: "keywords",
75
- header: k._("Keywords"),
76
- cell: ({ row: e }) => /* @__PURE__ */ T("span", { children: e.original.keywords })
77
- },
78
- {
79
- accessorKey: "created_at",
80
- header: ({ column: e }) => {
81
- let t = e.getIsSorted();
82
- return /* @__PURE__ */ E("div", {
83
- className: "ttw:flex ttw:items-center ttw:gap-2 ttw:text-inherit",
84
- children: [k._("Created at"), /* @__PURE__ */ T(n, {
85
- variant: "ghost",
86
- onClick: () => e.toggleSorting(t === "asc"),
87
- children: T(t === "asc" ? x : t === "desc" ? b : S, { className: "ttw:size-4" })
88
- })]
89
- });
90
- },
91
- cell: ({ row: e }) => /* @__PURE__ */ T("span", { children: k.date(e.original.created_at, j.dateFormat) })
92
- },
93
- {
94
- accessorKey: "updated_at",
95
- header: k._("Updated at"),
96
- cell: ({ row: e }) => /* @__PURE__ */ T("span", { children: k.date(e.original.updated_at, j.dateFormat) })
97
- },
98
- {
99
- accessorKey: "created_by_entity_user_id",
100
- header: k._("Created by"),
101
- cell: ({ row: e }) => e.original.created_by_entity_user_id ? /* @__PURE__ */ T(h, { id: e.original.created_by_entity_user_id }) : null
102
- },
103
- {
104
- id: "actions",
105
- header: () => /* @__PURE__ */ T("div", {
106
- className: "ttw:text-right",
107
- children: k._("Actions")
108
- }),
109
- cell: ({ row: e }) => K ? /* @__PURE__ */ E(i, { children: [/* @__PURE__ */ T(s, {
110
- asChild: !0,
111
- children: /* @__PURE__ */ T("div", {
112
- className: "ttw:flex ttw:justify-end ttw:gap-2",
113
- children: /* @__PURE__ */ E(n, {
114
- variant: "ghost",
115
- className: "ttw:size-5 ttw:p-2",
116
- children: [/* @__PURE__ */ T("span", {
117
- className: "ttw:sr-only",
118
- children: k._("Open actions menu")
119
- }), /* @__PURE__ */ T(C, { className: "ttw:size-4" })]
120
- })
121
- })
122
- }), /* @__PURE__ */ T(a, {
123
- align: "end",
124
- children: /* @__PURE__ */ E(o, {
125
- onClick: (t) => {
126
- t.stopPropagation(), B(e.original), W(!0);
127
- },
128
- children: [/* @__PURE__ */ T(w, { className: "ttw:text-red-700" }), k._("Delete")]
129
- })
130
- })] }) : null
131
- }
132
- ], [
133
- k,
134
- j.dateFormat,
135
- K
136
- ]);
137
- return /* @__PURE__ */ E(ee, { children: [
138
- /* @__PURE__ */ T("div", {
139
- className: "ttw:flex ttw:flex-col ttw:overflow-hidden ttw:min-h-125",
140
- children: /* @__PURE__ */ T(u, {
141
- columns: re,
142
- data: ne,
143
- sorting: $,
144
- onSortingChange: te,
145
- pageSize: F,
146
- onPageSizeChange: I,
147
- nextPaginationToken: q?.next_pagination_token ?? void 0,
148
- prevPaginationToken: q?.prev_pagination_token ?? void 0,
149
- onPaginationTokenChange: P,
150
- onRowClick: (e) => {
151
- d() || (B(e), H(!0));
152
- },
153
- children: /* @__PURE__ */ T(l, {
154
- isLoading: J,
155
- dataLength: q?.data.length || 0,
156
- isFiltering: !1,
157
- isSearching: !1,
158
- isError: Y,
159
- onCreate: O,
160
- refetch: X,
161
- entityName: k._("Tags"),
162
- noDataTitle: k._("No Tags"),
163
- noDataDescription1: k._("You don't have any tags yet."),
164
- actionButtonLabel: k._("Create new tag"),
165
- actionOptions: [k._("Tag")],
166
- type: "no-data"
167
- })
168
- })
169
- }),
170
- /* @__PURE__ */ T(m, {
171
- tag: z,
172
- open: V,
173
- onClose: Z,
174
- isDeleteAllowed: K ?? !1,
175
- onDelete: (e) => {
176
- K && (B(e), W(!0));
177
- }
178
- }),
179
- z && /* @__PURE__ */ T(g, {
180
- tag: z,
181
- modalOpened: U,
182
- onClose: Q
183
- })
184
- ] });
185
- };
186
- //#endregion
187
- export { O as TagsTable };
@@ -1 +1,187 @@
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 "./index47.js";
4
+ import { Button as n } from "./index56.js";
5
+ import { MoniteScopedProviders as r } from "./index237.js";
6
+ import { DropdownMenu as i, DropdownMenuContent as a, DropdownMenuItem as o, DropdownMenuTrigger as s } from "./index55.js";
7
+ import { useUserPermissions as c } from "./index116.js";
8
+ import { GetNoRowsOverlay as l } from "./index246.js";
9
+ import { DataTable as u } from "./index251.js";
10
+ import { hasSelectedText as d } from "./index252.js";
11
+ import { getTagCategoryLabel as f } from "./index305.js";
12
+ import { useTags as p } from "./index306.js";
13
+ import { TagFormModal as m } from "./index309.js";
14
+ import "./index310.js";
15
+ import { UserCell as h } from "./index559.js";
16
+ import { ConfirmDeleteModal as g } from "./index560.js";
1
17
  import "./index561.js";
18
+ import { useCallback as _, useMemo as v, useState as y } from "react";
19
+ import { ArrowDown as b, ArrowUp as x, ArrowUpDown as S, MoreVertical as C, Trash as w } from "lucide-react";
20
+ import { Fragment as ee, jsx as T, jsxs as E } from "@emotion/react/jsx-runtime";
21
+ import { useLingui as D } from "@lingui/react";
22
+ //#region ../../libs/tesouro-embedded-components-react/monite-sdk/dist/index562.js
23
+ var O = (e) => /* @__PURE__ */ T(r, { children: /* @__PURE__ */ T(k, { ...e }) }), k = ({ onChangeSort: r, showCreationModal: O }) => {
24
+ let { i18n: k } = D(), { api: A, locale: j, componentSettings: M } = t(), [N, P] = y(void 0), [F, I] = y(M.tags.pageSizeOptions[0]), [L, R] = y({
25
+ field: "created_at",
26
+ sort: "desc"
27
+ }), [z, B] = y(void 0), [V, H] = y(!1), [U, W] = y(!1), { tagsWithKeywords: G } = p({}), K = c().has(e.AccountingConfigWriteOrg), { data: q, isLoading: J, isError: Y, refetch: X } = A.finops.getTags.useQuery({ query: {
28
+ sort: L.field,
29
+ order: L.sort,
30
+ limit: F,
31
+ pagination_token: N
32
+ } }), Z = _(() => {
33
+ H(!1);
34
+ }, []), Q = _(() => {
35
+ B(void 0), H(!1), W(!1);
36
+ }, []), $ = v(() => [{
37
+ id: L.field,
38
+ desc: L.sort === "desc"
39
+ }], [L]), te = _((e) => {
40
+ let t = typeof e == "function" ? e($) : e;
41
+ if (t.length > 0) {
42
+ let e = {
43
+ field: t[0].id,
44
+ sort: t[0].desc ? "desc" : "asc"
45
+ };
46
+ R(e), r?.(e);
47
+ }
48
+ P(void 0);
49
+ }, [$, r]), ne = (q?.data ?? []).map((e) => ({
50
+ ...e,
51
+ keywords: G[e.id]?.join(", ")
52
+ })), re = v(() => [
53
+ {
54
+ accessorKey: "name",
55
+ header: ({ column: e }) => {
56
+ let t = e.getIsSorted();
57
+ return /* @__PURE__ */ E("div", {
58
+ className: "ttw:flex ttw:items-center ttw:gap-2 ttw:text-inherit",
59
+ children: [k._("Name"), /* @__PURE__ */ T(n, {
60
+ variant: "ghost",
61
+ onClick: () => e.toggleSorting(t === "asc"),
62
+ children: T(t === "asc" ? x : t === "desc" ? b : S, { className: "ttw:size-4" })
63
+ })]
64
+ });
65
+ },
66
+ cell: ({ row: e }) => /* @__PURE__ */ T("span", { children: e.original.name })
67
+ },
68
+ {
69
+ accessorKey: "category",
70
+ header: k._("Category"),
71
+ cell: ({ row: e }) => /* @__PURE__ */ T("span", { children: f(e.original.category, k) })
72
+ },
73
+ {
74
+ accessorKey: "keywords",
75
+ header: k._("Keywords"),
76
+ cell: ({ row: e }) => /* @__PURE__ */ T("span", { children: e.original.keywords })
77
+ },
78
+ {
79
+ accessorKey: "created_at",
80
+ header: ({ column: e }) => {
81
+ let t = e.getIsSorted();
82
+ return /* @__PURE__ */ E("div", {
83
+ className: "ttw:flex ttw:items-center ttw:gap-2 ttw:text-inherit",
84
+ children: [k._("Created at"), /* @__PURE__ */ T(n, {
85
+ variant: "ghost",
86
+ onClick: () => e.toggleSorting(t === "asc"),
87
+ children: T(t === "asc" ? x : t === "desc" ? b : S, { className: "ttw:size-4" })
88
+ })]
89
+ });
90
+ },
91
+ cell: ({ row: e }) => /* @__PURE__ */ T("span", { children: k.date(e.original.created_at, j.dateFormat) })
92
+ },
93
+ {
94
+ accessorKey: "updated_at",
95
+ header: k._("Updated at"),
96
+ cell: ({ row: e }) => /* @__PURE__ */ T("span", { children: k.date(e.original.updated_at, j.dateFormat) })
97
+ },
98
+ {
99
+ accessorKey: "created_by_entity_user_id",
100
+ header: k._("Created by"),
101
+ cell: ({ row: e }) => e.original.created_by_entity_user_id ? /* @__PURE__ */ T(h, { id: e.original.created_by_entity_user_id }) : null
102
+ },
103
+ {
104
+ id: "actions",
105
+ header: () => /* @__PURE__ */ T("div", {
106
+ className: "ttw:text-right",
107
+ children: k._("Actions")
108
+ }),
109
+ cell: ({ row: e }) => K ? /* @__PURE__ */ E(i, { children: [/* @__PURE__ */ T(s, {
110
+ asChild: !0,
111
+ children: /* @__PURE__ */ T("div", {
112
+ className: "ttw:flex ttw:justify-end ttw:gap-2",
113
+ children: /* @__PURE__ */ E(n, {
114
+ variant: "ghost",
115
+ className: "ttw:size-5 ttw:p-2",
116
+ children: [/* @__PURE__ */ T("span", {
117
+ className: "ttw:sr-only",
118
+ children: k._("Open actions menu")
119
+ }), /* @__PURE__ */ T(C, { className: "ttw:size-4" })]
120
+ })
121
+ })
122
+ }), /* @__PURE__ */ T(a, {
123
+ align: "end",
124
+ children: /* @__PURE__ */ E(o, {
125
+ onClick: (t) => {
126
+ t.stopPropagation(), B(e.original), W(!0);
127
+ },
128
+ children: [/* @__PURE__ */ T(w, { className: "ttw:text-red-700" }), k._("Delete")]
129
+ })
130
+ })] }) : null
131
+ }
132
+ ], [
133
+ k,
134
+ j.dateFormat,
135
+ K
136
+ ]);
137
+ return /* @__PURE__ */ E(ee, { children: [
138
+ /* @__PURE__ */ T("div", {
139
+ className: "ttw:flex ttw:flex-col ttw:overflow-hidden ttw:min-h-125",
140
+ children: /* @__PURE__ */ T(u, {
141
+ columns: re,
142
+ data: ne,
143
+ sorting: $,
144
+ onSortingChange: te,
145
+ pageSize: F,
146
+ onPageSizeChange: I,
147
+ nextPaginationToken: q?.next_pagination_token ?? void 0,
148
+ prevPaginationToken: q?.prev_pagination_token ?? void 0,
149
+ onPaginationTokenChange: P,
150
+ onRowClick: (e) => {
151
+ d() || (B(e), H(!0));
152
+ },
153
+ children: /* @__PURE__ */ T(l, {
154
+ isLoading: J,
155
+ dataLength: q?.data.length || 0,
156
+ isFiltering: !1,
157
+ isSearching: !1,
158
+ isError: Y,
159
+ onCreate: O,
160
+ refetch: X,
161
+ entityName: k._("Tags"),
162
+ noDataTitle: k._("No Tags"),
163
+ noDataDescription1: k._("You don't have any tags yet."),
164
+ actionButtonLabel: k._("Create new tag"),
165
+ actionOptions: [k._("Tag")],
166
+ type: "no-data"
167
+ })
168
+ })
169
+ }),
170
+ /* @__PURE__ */ T(m, {
171
+ tag: z,
172
+ open: V,
173
+ onClose: Z,
174
+ isDeleteAllowed: K ?? !1,
175
+ onDelete: (e) => {
176
+ K && (B(e), W(!0));
177
+ }
178
+ }),
179
+ z && /* @__PURE__ */ T(g, {
180
+ tag: z,
181
+ modalOpened: U,
182
+ onClose: Q
183
+ })
184
+ ] });
185
+ };
186
+ //#endregion
187
+ export { O as TagsTable };
@@ -1,43 +1 @@
1
- import { Scope as e } from "../../shared/data-access/dist/lib/scopes.js";
2
- import "../../shared/data-access/dist/index.js";
3
- import { Button as t } from "./index56.js";
4
- import { MoniteScopedProviders as n } from "./index237.js";
5
- import { useUserPermissions as r } from "./index116.js";
6
- import { AccessRestriction as i } from "./index247.js";
7
- import "./index249.js";
8
- import { TagFormModal as a } from "./index309.js";
9
- import "./index310.js";
10
- import { PageHeader as o } from "./index337.js";
11
- import { TagsTable as s } from "./index561.js";
12
1
  import "./index562.js";
13
- import { useCallback as c, useState as l } from "react";
14
- import { Fragment as u, jsx as d, jsxs as f } from "@emotion/react/jsx-runtime";
15
- import { useLingui as p } from "@lingui/react";
16
- //#region ../../libs/tesouro-embedded-components-react/monite-sdk/dist/index563.js
17
- var m = () => /* @__PURE__ */ d(n, { children: /* @__PURE__ */ d(h, {}) }), h = () => {
18
- let { i18n: n } = p(), [m, h] = l(!1), g = c(() => {
19
- h(!0);
20
- }, []), _ = c(() => {
21
- h(!1);
22
- }, []), v = r(), y = v.has(e.AccountingConfigWriteOrg), b = v.has(e.AccountingConfigReadOrg), x = v.has(e.AccountingConfigWriteOrg);
23
- return /* @__PURE__ */ f(u, { children: [
24
- /* @__PURE__ */ d(o, {
25
- title: /* @__PURE__ */ d(u, { children: n._("Tags") }),
26
- extra: /* @__PURE__ */ d(t, {
27
- size: "lg",
28
- disabled: !y,
29
- onClick: g,
30
- children: n._("Create new")
31
- })
32
- }),
33
- !b && /* @__PURE__ */ d(i, {}),
34
- b && /* @__PURE__ */ d(s, { showCreationModal: g }),
35
- /* @__PURE__ */ d(a, {
36
- open: m,
37
- onClose: _,
38
- isDeleteAllowed: x
39
- })
40
- ] });
41
- };
42
- //#endregion
43
- export { m as Tags };
@@ -1,5 +1,43 @@
1
- import "./index309.js";
1
+ import { Scope as e } from "../../shared/data-access/dist/lib/scopes.js";
2
+ import "../../shared/data-access/dist/index.js";
3
+ import { Button as t } from "./index56.js";
4
+ import { MoniteScopedProviders as n } from "./index237.js";
5
+ import { useUserPermissions as r } from "./index116.js";
6
+ import { AccessRestriction as i } from "./index247.js";
7
+ import "./index249.js";
8
+ import { TagFormModal as a } from "./index309.js";
2
9
  import "./index310.js";
3
- import "./index561.js";
4
- import "./index562.js";
10
+ import { PageHeader as o } from "./index337.js";
11
+ import { TagsTable as s } from "./index562.js";
5
12
  import "./index563.js";
13
+ import { useCallback as c, useState as l } from "react";
14
+ import { Fragment as u, jsx as d, jsxs as f } from "@emotion/react/jsx-runtime";
15
+ import { useLingui as p } from "@lingui/react";
16
+ //#region ../../libs/tesouro-embedded-components-react/monite-sdk/dist/index564.js
17
+ var m = () => /* @__PURE__ */ d(n, { children: /* @__PURE__ */ d(h, {}) }), h = () => {
18
+ let { i18n: n } = p(), [m, h] = l(!1), g = c(() => {
19
+ h(!0);
20
+ }, []), _ = c(() => {
21
+ h(!1);
22
+ }, []), v = r(), y = v.has(e.AccountingConfigWriteOrg), b = v.has(e.AccountingConfigReadOrg), x = v.has(e.AccountingConfigWriteOrg);
23
+ return /* @__PURE__ */ f(u, { children: [
24
+ /* @__PURE__ */ d(o, {
25
+ title: /* @__PURE__ */ d(u, { children: n._("Tags") }),
26
+ extra: /* @__PURE__ */ d(t, {
27
+ size: "lg",
28
+ disabled: !y,
29
+ onClick: g,
30
+ children: n._("Create new")
31
+ })
32
+ }),
33
+ !b && /* @__PURE__ */ d(i, {}),
34
+ b && /* @__PURE__ */ d(s, { showCreationModal: g }),
35
+ /* @__PURE__ */ d(a, {
36
+ open: m,
37
+ onClose: _,
38
+ isDeleteAllowed: x
39
+ })
40
+ ] });
41
+ };
42
+ //#endregion
43
+ export { m as Tags };
@@ -1,24 +1,5 @@
1
- import { jsx as e } from "@emotion/react/jsx-runtime";
2
- import { Box as t, useTheme as n } from "@mui/material";
3
- //#region ../../libs/tesouro-embedded-components-react/monite-sdk/dist/index565.js
4
- var r = ({ children: r, shouldApplyFinanceStyles: i = !1 }) => {
5
- let a = n();
6
- return /* @__PURE__ */ e(t, {
7
- sx: {
8
- background: `linear-gradient(180deg, ${a.palette.primary.light} 0%, ${a.palette.background.paper} 100%)`,
9
- display: "flex",
10
- flexDirection: "column",
11
- gap: 1,
12
- px: 3,
13
- py: i ? 3 : 2.5,
14
- width: "100%",
15
- minHeight: "auto",
16
- borderRadius: "16px",
17
- boxShadow: "0 16px 24px 0 rgba(0, 0, 0, 0.02)",
18
- border: i ? "none" : `1px solid ${a.palette.divider}`
19
- },
20
- children: r
21
- });
22
- };
23
- //#endregion
24
- export { r as FinanceBannerWrapper };
1
+ import "./index309.js";
2
+ import "./index310.js";
3
+ import "./index562.js";
4
+ import "./index563.js";
5
+ import "./index564.js";
@@ -1,77 +1,24 @@
1
- import { jsx as e, jsxs as t } from "@emotion/react/jsx-runtime";
2
- import { Box as n, Link as r, Typography as i } from "@mui/material";
3
- import { useLingui as a } from "@lingui/react";
1
+ import { jsx as e } from "@emotion/react/jsx-runtime";
2
+ import { Box as t, useTheme as n } from "@mui/material";
4
3
  //#region ../../libs/tesouro-embedded-components-react/monite-sdk/dist/index566.js
5
- var o = [
6
- {
7
- id: 1,
8
- question: "Does enrolling in the program affect my credit score?",
9
- answer: "Nope! During the onboarding process we will only conduct a soft pull on your credit report, which will not affect your personal credit score."
10
- },
11
- {
12
- id: 2,
13
- question: "Why do I need to provide my bank connection details?",
14
- answer: "Securely connecting your business bank account allows us to review your cashflow and determine your best loan offers."
15
- },
16
- {
17
- id: 3,
18
- question: "When should I expect to receive a loan offer?",
19
- answer: "Once you are enrolled into the program, we will be actively analyzing your financials and creating pre-approved offers that work best for your business needs. We do this to help you avoid debt trap. Loan offers are usually provided within less than 48 hours."
20
- },
21
- {
22
- id: 4,
23
- question: "How do I repay the loan?",
24
- answer: "At the moment we support monthly loan repayment once you agree to the loan payment schedule. A fixed amount will be automatically deducted from the bank you linked during the onboarding.In the near future, you can also choose to pay back the loan as a fixed percentage of your daily sales until the loan is fully repaid."
25
- }
26
- ], s = () => {
27
- let { i18n: s } = a();
28
- return /* @__PURE__ */ t(n, {
29
- p: 4,
30
- children: [
31
- /* @__PURE__ */ t(n, { children: [/* @__PURE__ */ e(i, {
32
- variant: "h3",
33
- children: s._("Simplified, fast funding for your growing business")
34
- }), /* @__PURE__ */ e(i, {
35
- variant: "subtitle2",
36
- mt: 2,
37
- children: s._("Get your business moving and accelerate growth with quick and easy access to funding. Multiple options available.")
38
- })] }),
39
- /* @__PURE__ */ t(n, {
40
- mt: 5,
41
- children: [/* @__PURE__ */ e(i, {
42
- mb: 1,
43
- variant: "h3",
44
- children: s._("FAQ")
45
- }), o.map((r) => /* @__PURE__ */ t(n, {
46
- mt: 3,
47
- children: [/* @__PURE__ */ e(i, {
48
- variant: "subtitle2",
49
- children: s._("{faqQuestion}", { faqQuestion: r.question })
50
- }), /* @__PURE__ */ e(i, {
51
- variant: "body1",
52
- mt: 1,
53
- children: s._("{faqAnswer}", { faqAnswer: r.answer })
54
- })]
55
- }, r.id))]
56
- }),
57
- /* @__PURE__ */ e(n, {
58
- mt: 5,
59
- children: /* @__PURE__ */ t(i, {
60
- variant: "body2",
61
- children: [
62
- s._("All loans are subject to credit approval. Your terms may vary. Flourish Capital loans are issued by Kanmon. California Loans are made pursuant to a Department of Financial Protection and Innovation California Lenders Law License. Read more about Kanmon"),
63
- " ",
64
- /* @__PURE__ */ e(r, {
65
- target: "_blank",
66
- rel: "noopener noreferrer",
67
- href: "https://kanmon.com",
68
- children: s._("here.")
69
- })
70
- ]
71
- })
72
- })
73
- ]
4
+ var r = ({ children: r, shouldApplyFinanceStyles: i = !1 }) => {
5
+ let a = n();
6
+ return /* @__PURE__ */ e(t, {
7
+ sx: {
8
+ background: `linear-gradient(180deg, ${a.palette.primary.light} 0%, ${a.palette.background.paper} 100%)`,
9
+ display: "flex",
10
+ flexDirection: "column",
11
+ gap: 1,
12
+ px: 3,
13
+ py: i ? 3 : 2.5,
14
+ width: "100%",
15
+ minHeight: "auto",
16
+ borderRadius: "16px",
17
+ boxShadow: "0 16px 24px 0 rgba(0, 0, 0, 0.02)",
18
+ border: i ? "none" : `1px solid ${a.palette.divider}`
19
+ },
20
+ children: r
74
21
  });
75
22
  };
76
23
  //#endregion
77
- export { s as FinanceFaqDetails };
24
+ export { r as FinanceBannerWrapper };