@tesouro/embedded-components-react 0.7.49 → 0.7.51

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 (188) hide show
  1. package/dist/lib/monite-sdk.d.ts +42 -42
  2. package/dist/lib/monite-sdk.js +18 -18
  3. package/dist/libs/tesouro-embedded-components-react/counterparts-widget/feature/dist/lib/CounterpartsWidget/useCounterpartsTable.js +2 -1
  4. package/dist/libs/tesouro-embedded-components-react/counterparts-widget/feature/dist/mocks/counterparts.js +233 -88
  5. package/dist/libs/tesouro-embedded-components-react/counterparts-widget/feature/dist/mocks/labels.js +1 -1
  6. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index.js +19 -19
  7. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index100.js +56 -10
  8. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index101.js +10 -37
  9. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index102.js +39 -1
  10. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index103.js +0 -105
  11. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index104.js +105 -0
  12. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index105.js +1 -56
  13. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index106.js +56 -1
  14. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index107.js +1 -55
  15. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index108.js +55 -1
  16. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index109.js +1 -55
  17. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index110.js +55 -1
  18. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index111.js +1 -153
  19. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index112.js +150 -52
  20. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index113.js +55 -2
  21. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index114.js +0 -1
  22. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index115.js +2 -0
  23. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index116.js +0 -1
  24. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index117.js +2 -10
  25. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index118.js +7 -53
  26. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index119.js +51 -36
  27. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index120.js +38 -71
  28. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index121.js +72 -39
  29. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index122.js +36 -9
  30. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index123.js +7 -6
  31. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index124.js +6 -64
  32. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index125.js +57 -158
  33. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index126.js +172 -7
  34. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index127.js +6 -1
  35. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index128.js +2 -76
  36. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index129.js +76 -1
  37. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index130.js +0 -78
  38. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index131.js +78 -0
  39. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index132.js +1 -35
  40. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index133.js +35 -1
  41. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index134.js +0 -57
  42. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index135.js +56 -42
  43. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index136.js +44 -1
  44. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index137.js +0 -568
  45. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index138.js +568 -0
  46. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index139.js +1 -1
  47. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index140.js +1 -160
  48. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index141.js +159 -0
  49. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index142.js +0 -26
  50. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index143.js +26 -0
  51. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index144.js +1 -12
  52. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index145.js +2 -2
  53. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index146.js +2 -2
  54. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index147.js +10 -16
  55. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index148.js +16 -19
  56. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index149.js +19 -27
  57. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index150.js +29 -1
  58. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index151.js +1 -93
  59. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index154.js +4 -4
  60. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index159.js +1 -1
  61. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index162.js +4 -4
  62. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index164.js +1 -1
  63. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index168.js +1 -1
  64. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index172.js +2 -2
  65. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index173.js +1 -1
  66. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index175.js +12 -11
  67. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index178.js +4 -4
  68. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index179.js +2 -2
  69. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index229.js +1 -1
  70. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index235.js +2 -2
  71. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index249.js +4 -4
  72. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index252.js +1 -1
  73. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index260.js +87 -41
  74. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index261.js +44 -48
  75. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index262.js +48 -82
  76. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index263.js +83 -7
  77. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index264.js +7 -305
  78. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index265.js +307 -1
  79. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index266.js +1 -32
  80. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index267.js +32 -1
  81. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index268.js +1 -29
  82. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index269.js +29 -1
  83. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index270.js +1 -22
  84. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index271.js +22 -1
  85. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index272.js +0 -159
  86. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index273.js +159 -0
  87. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index274.js +1 -37
  88. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index275.js +34 -33
  89. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index276.js +33 -3
  90. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index277.js +3 -102
  91. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index278.js +88 -172
  92. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index279.js +171 -116
  93. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index280.js +114 -191
  94. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index281.js +209 -11
  95. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index282.js +11 -15
  96. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index283.js +14 -28
  97. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index284.js +31 -1
  98. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index285.js +0 -241
  99. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index286.js +241 -0
  100. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index287.js +1 -36
  101. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index288.js +31 -137
  102. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index289.js +142 -1
  103. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index290.js +0 -166
  104. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index291.js +166 -25
  105. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index292.js +26 -19
  106. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index293.js +16 -17
  107. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index294.js +17 -5
  108. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index295.js +4 -14
  109. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index296.js +12 -18
  110. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index297.js +9 -9
  111. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index298.js +21 -5
  112. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index299.js +4 -13
  113. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index300.js +11 -14
  114. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index301.js +20 -9
  115. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index302.js +8 -26
  116. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index303.js +23 -11
  117. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index304.js +12 -8
  118. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index305.js +8 -24
  119. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index306.js +25 -14
  120. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index307.js +14 -81
  121. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index308.js +81 -14
  122. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index309.js +14 -100
  123. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index310.js +98 -42
  124. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index311.js +43 -27
  125. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index312.js +30 -1
  126. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index313.js +0 -105
  127. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index314.js +102 -35
  128. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index315.js +32 -166
  129. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index316.js +171 -12
  130. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index317.js +13 -3
  131. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index318.js +4 -70
  132. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index319.js +62 -19
  133. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index320.js +24 -209
  134. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index321.js +207 -87
  135. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index322.js +90 -17
  136. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index323.js +17 -158
  137. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index324.js +144 -88
  138. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index325.js +100 -42
  139. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index326.js +46 -4
  140. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index327.js +4 -24
  141. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index328.js +20 -73
  142. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index329.js +74 -16
  143. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index330.js +16 -19
  144. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index331.js +19 -5
  145. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index332.js +4 -8
  146. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index333.js +10 -11
  147. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index334.js +11 -131
  148. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index335.js +129 -4
  149. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index336.js +4 -4
  150. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index337.js +8 -5
  151. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index338.js +4 -221
  152. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index339.js +219 -31
  153. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index340.js +31 -11
  154. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index341.js +12 -34
  155. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index342.js +34 -20
  156. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index343.js +18 -72
  157. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index344.js +73 -181
  158. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index345.js +182 -14
  159. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index346.js +14 -204
  160. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index347.js +192 -88
  161. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index348.js +97 -61
  162. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index349.js +63 -54
  163. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index350.js +46 -83
  164. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index351.js +91 -40
  165. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index352.js +39 -75
  166. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index353.js +63 -71
  167. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index354.js +85 -12
  168. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index355.js +12 -24
  169. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index356.js +25 -16
  170. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index357.js +14 -2
  171. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index358.js +4 -23
  172. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index359.js +23 -0
  173. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index360.js +0 -45
  174. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index361.js +46 -32
  175. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index362.js +30 -2
  176. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index363.js +2 -34
  177. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index364.js +33 -15
  178. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index365.js +14 -29
  179. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index366.js +29 -27
  180. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index367.js +31 -2
  181. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index368.js +2 -97
  182. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index369.js +97 -0
  183. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index96.js +2 -17
  184. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index97.js +17 -3
  185. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index98.js +5 -1
  186. package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index99.js +1 -57
  187. package/dist/libs/tesouro-embedded-components-react/shared/feature/dist/lib/analytics/build-info.js +1 -1
  188. package/package.json +1 -1
@@ -1,142 +1,36 @@
1
- import { useFileInput as e } from "./index81.js";
2
- import "./index89.js";
1
+ import { useRootElements as e } from "./index78.js";
2
+ import "./index79.js";
3
3
  import { cn as t } from "./index64.js";
4
- import { Button as n } from "./index121.js";
5
- import { Popover as r, PopoverContent as i, PopoverTrigger as a } from "./index287.js";
6
- import { useState as o } from "react";
7
- import { ChevronDownIcon as s, ChevronUpIcon as c, CloudUpload as l, Copy as u, Plus as d } from "lucide-react";
8
- import { jsx as f, jsxs as p } from "@emotion/react/jsx-runtime";
9
- import { toast as m } from "react-hot-toast";
10
- import { useLingui as h } from "@lingui/react";
4
+ import "react";
5
+ import { jsx as n } from "@emotion/react/jsx-runtime";
6
+ import * as r from "@radix-ui/react-popover";
11
7
  //#region ../../libs/tesouro-embedded-components-react/monite-sdk/dist/index288.js
12
- var g = ({ isCreateAllowed: g, onCreateInvoice: _, handleFileUpload: v }) => {
13
- let { i18n: y } = h(), [b, x] = o(!1), { FileInput: S, openFileInput: C, checkFileError: w } = e(), [T, E] = o(!1);
14
- return /* @__PURE__ */ f("div", {
15
- className: "Monite-Payables",
16
- children: /* @__PURE__ */ p(r, {
17
- open: b,
18
- onOpenChange: x,
19
- children: [/* @__PURE__ */ f(a, {
20
- asChild: !0,
21
- children: /* @__PURE__ */ p(n, {
22
- size: "lg",
23
- disabled: !g,
24
- children: [y._("Add new bill"), f(b ? c : s, {})]
25
- })
26
- }), /* @__PURE__ */ p(i, {
27
- align: "end",
28
- className: "ttw:w-auto ttw:min-w-110 ttw:border-none ttw:p-6",
29
- children: [/* @__PURE__ */ p("div", {
30
- className: "ttw:w-110 ttw:flex ttw:flex-col ttw:gap-4",
31
- onClick: (e) => {
32
- e.preventDefault(), e.stopPropagation();
33
- },
34
- children: [
35
- /* @__PURE__ */ p("div", { children: [/* @__PURE__ */ f("h3", {
36
- className: "ttw:text-xl ttw:font-semibold ttw:text-zinc-950",
37
- children: y._("Upload bills")
38
- }), /* @__PURE__ */ f("p", {
39
- className: "ttw:text-sm ttw:font-normal ttw:text-zinc-500",
40
- children: y._("Upload your bills and we'll automatically pull the details so you can review and approve.")
41
- })] }),
42
- /* @__PURE__ */ f("div", {
43
- className: t("ttw:box-border ttw:cursor-pointer ttw:w-full ttw:h-36.5 ttw:flex ttw:flex-col ttw:items-center ttw:justify-center ttw:text-center ttw:border ttw:rounded-lg ttw:border-dashed ttw:border-zinc-200 ttw:bg-zinc-50", T && "ttw:bg-transparent"),
44
- onDragOver: (e) => {
45
- e.preventDefault(), E(!0);
46
- },
47
- onDragLeave: (e) => {
48
- e.preventDefault(), E(!1);
49
- },
50
- onDrop: (e) => {
51
- e.preventDefault(), E(!1);
52
- let t = Array.from(e.dataTransfer.files);
53
- if (t.length > 10) {
54
- m.error(y._("You can only upload up to {fileCount} files at a time", { fileCount: 10 })), x(!1);
55
- return;
56
- }
57
- t.forEach((e) => {
58
- let t = w(e);
59
- if (t) {
60
- m.error(t);
61
- return;
62
- }
63
- v(e);
64
- }), x(!1);
65
- },
66
- onClick: C,
67
- children: /* @__PURE__ */ p("div", {
68
- className: "ttw:mx-auto ttw:flex ttw:flex-col ttw:items-center ttw:gap-2",
69
- children: [
70
- /* @__PURE__ */ f("div", {
71
- className: "ttw:w-11 ttw:h-11 ttw:rounded-full ttw:bg-primary ttw:flex ttw:items-center ttw:justify-center",
72
- children: /* @__PURE__ */ f(l, { className: "ttw:text-white ttw:size-5" })
73
- }),
74
- /* @__PURE__ */ p("p", {
75
- className: "ttw:text-sm ttw:font-medium ttw:text-zinc-950",
76
- children: [
77
- y._("Drop your files here, or"),
78
- " ",
79
- /* @__PURE__ */ f("span", {
80
- className: "ttw:text-primary ttw:underline",
81
- children: y._("click to browse")
82
- })
83
- ]
84
- }),
85
- /* @__PURE__ */ f("p", {
86
- className: "ttw:text-xs ttw:font-normal ttw:text-zinc-500",
87
- children: y._("PDF, PNG or JPG (max. 20MB)")
88
- })
89
- ]
90
- })
91
- }),
92
- /* @__PURE__ */ p("div", {
93
- className: "ttw:flex ttw:flex-col",
94
- children: [/* @__PURE__ */ f("h3", {
95
- className: "ttw:text-primary ttw:text-sm ttw:font-semibold",
96
- children: y._("Send via email")
97
- }), /* @__PURE__ */ f("p", {
98
- className: "ttw:text-zinc-500 ttw:font-normal ttw:text-sm",
99
- children: y._("Email your bills here and they'll appear in your bill pay inbox, ready to review and pay.")
100
- })]
101
- }),
102
- /* @__PURE__ */ p("div", {
103
- className: "ttw:px-3 ttw:h-14 ttw:border ttw:border-zinc-200 ttw:rounded-lg ttw:flex ttw:items-center ttw:justify-between ttw:gap-6",
104
- children: [/* @__PURE__ */ f("span", { children: y._("bills@business-banking.com") }), /* @__PURE__ */ p(n, {
105
- type: "button",
106
- variant: "ghost",
107
- size: "sm",
108
- className: "ttw:text-primary ttw:hover:bg-primary-foreground ttw:hover:text-primary",
109
- onClick: () => {
110
- navigator.clipboard.writeText("bills@business-banking.com"), m.success(y._("Email address copied to clipboard"));
111
- },
112
- children: [/* @__PURE__ */ f(u, {}), y._("Copy")]
113
- })]
114
- }),
115
- /* @__PURE__ */ p("div", {
116
- className: "ttw:flex ttw:flex-col ttw:gap-4",
117
- children: [/* @__PURE__ */ f("h3", {
118
- className: "ttw:text-sm ttw:font-semibold ttw:text-primary",
119
- children: y._("Or add bill manually")
120
- }), /* @__PURE__ */ p(n, {
121
- onClick: () => {
122
- x(!1), _();
123
- },
124
- className: "ttw:w-fit ttw:bg-primary-foreground ttw:hover:bg-primary-foreground ttw:text-primary",
125
- children: [/* @__PURE__ */ f(d, {}), y._("Add new bill")]
126
- })]
127
- })
128
- ]
129
- }), /* @__PURE__ */ f(S, {
130
- "aria-label": y._("Upload payable files"),
131
- multiple: !0,
132
- onChange: (e) => {
133
- let t = e.target.files;
134
- t && v(t), x(!1);
135
- }
136
- })]
137
- })]
8
+ function i({ ...e }) {
9
+ return /* @__PURE__ */ n(r.Root, {
10
+ "data-slot": "popover",
11
+ ...e
12
+ });
13
+ }
14
+ function a({ ref: e, ...t }) {
15
+ return /* @__PURE__ */ n(r.Trigger, {
16
+ "data-slot": "popover-trigger",
17
+ ref: e,
18
+ ...t
19
+ });
20
+ }
21
+ a.displayName = r.Trigger.displayName;
22
+ function o({ className: i, align: a = "center", sideOffset: o = 4, ...s }) {
23
+ let { root: c } = e();
24
+ return /* @__PURE__ */ n(r.Portal, {
25
+ container: c,
26
+ children: /* @__PURE__ */ n(r.Content, {
27
+ "data-slot": "popover-content",
28
+ align: a,
29
+ sideOffset: o,
30
+ className: t("ttw:bg-popover ttw:text-popover-foreground ttw:data-[state=open]:animate-in ttw:data-[state=closed]:animate-out ttw:data-[state=closed]:fade-out-0 ttw:data-[state=open]:fade-in-0 ttw:data-[state=closed]:zoom-out-95 ttw:data-[state=open]:zoom-in-95 ttw:data-[side=bottom]:slide-in-from-top-2 ttw:data-[side=left]:slide-in-from-right-2 ttw:data-[side=right]:slide-in-from-left-2 ttw:data-[side=top]:slide-in-from-bottom-2 ttw:z-1300 ttw:w-72 ttw:origin-(--radix-popover-content-transform-origin) ttw:rounded-md ttw:border ttw:p-4 ttw:shadow-md ttw:outline-hidden", i),
31
+ ...s
138
32
  })
139
33
  });
140
- };
34
+ }
141
35
  //#endregion
142
- export { g as CreatePayableMenu };
36
+ export { i as Popover, o as PopoverContent, a as PopoverTrigger };
@@ -1 +1,142 @@
1
- import "./index288.js";
1
+ import { useFileInput as e } from "./index81.js";
2
+ import "./index89.js";
3
+ import { cn as t } from "./index64.js";
4
+ import { Button as n } from "./index122.js";
5
+ import { Popover as r, PopoverContent as i, PopoverTrigger as a } from "./index288.js";
6
+ import { useState as o } from "react";
7
+ import { ChevronDownIcon as s, ChevronUpIcon as c, CloudUpload as l, Copy as u, Plus as d } from "lucide-react";
8
+ import { jsx as f, jsxs as p } from "@emotion/react/jsx-runtime";
9
+ import { toast as m } from "react-hot-toast";
10
+ import { useLingui as h } from "@lingui/react";
11
+ //#region ../../libs/tesouro-embedded-components-react/monite-sdk/dist/index289.js
12
+ var g = ({ isCreateAllowed: g, onCreateInvoice: _, handleFileUpload: v }) => {
13
+ let { i18n: y } = h(), [b, x] = o(!1), { FileInput: S, openFileInput: C, checkFileError: w } = e(), [T, E] = o(!1);
14
+ return /* @__PURE__ */ f("div", {
15
+ className: "Monite-Payables",
16
+ children: /* @__PURE__ */ p(r, {
17
+ open: b,
18
+ onOpenChange: x,
19
+ children: [/* @__PURE__ */ f(a, {
20
+ asChild: !0,
21
+ children: /* @__PURE__ */ p(n, {
22
+ size: "lg",
23
+ disabled: !g,
24
+ children: [y._("Add new bill"), f(b ? c : s, {})]
25
+ })
26
+ }), /* @__PURE__ */ p(i, {
27
+ align: "end",
28
+ className: "ttw:w-auto ttw:min-w-110 ttw:border-none ttw:p-6",
29
+ children: [/* @__PURE__ */ p("div", {
30
+ className: "ttw:w-110 ttw:flex ttw:flex-col ttw:gap-4",
31
+ onClick: (e) => {
32
+ e.preventDefault(), e.stopPropagation();
33
+ },
34
+ children: [
35
+ /* @__PURE__ */ p("div", { children: [/* @__PURE__ */ f("h3", {
36
+ className: "ttw:text-xl ttw:font-semibold ttw:text-zinc-950",
37
+ children: y._("Upload bills")
38
+ }), /* @__PURE__ */ f("p", {
39
+ className: "ttw:text-sm ttw:font-normal ttw:text-zinc-500",
40
+ children: y._("Upload your bills and we'll automatically pull the details so you can review and approve.")
41
+ })] }),
42
+ /* @__PURE__ */ f("div", {
43
+ className: t("ttw:box-border ttw:cursor-pointer ttw:w-full ttw:h-36.5 ttw:flex ttw:flex-col ttw:items-center ttw:justify-center ttw:text-center ttw:border ttw:rounded-lg ttw:border-dashed ttw:border-zinc-200 ttw:bg-zinc-50", T && "ttw:bg-transparent"),
44
+ onDragOver: (e) => {
45
+ e.preventDefault(), E(!0);
46
+ },
47
+ onDragLeave: (e) => {
48
+ e.preventDefault(), E(!1);
49
+ },
50
+ onDrop: (e) => {
51
+ e.preventDefault(), E(!1);
52
+ let t = Array.from(e.dataTransfer.files);
53
+ if (t.length > 10) {
54
+ m.error(y._("You can only upload up to {fileCount} files at a time", { fileCount: 10 })), x(!1);
55
+ return;
56
+ }
57
+ t.forEach((e) => {
58
+ let t = w(e);
59
+ if (t) {
60
+ m.error(t);
61
+ return;
62
+ }
63
+ v(e);
64
+ }), x(!1);
65
+ },
66
+ onClick: C,
67
+ children: /* @__PURE__ */ p("div", {
68
+ className: "ttw:mx-auto ttw:flex ttw:flex-col ttw:items-center ttw:gap-2",
69
+ children: [
70
+ /* @__PURE__ */ f("div", {
71
+ className: "ttw:w-11 ttw:h-11 ttw:rounded-full ttw:bg-primary ttw:flex ttw:items-center ttw:justify-center",
72
+ children: /* @__PURE__ */ f(l, { className: "ttw:text-white ttw:size-5" })
73
+ }),
74
+ /* @__PURE__ */ p("p", {
75
+ className: "ttw:text-sm ttw:font-medium ttw:text-zinc-950",
76
+ children: [
77
+ y._("Drop your files here, or"),
78
+ " ",
79
+ /* @__PURE__ */ f("span", {
80
+ className: "ttw:text-primary ttw:underline",
81
+ children: y._("click to browse")
82
+ })
83
+ ]
84
+ }),
85
+ /* @__PURE__ */ f("p", {
86
+ className: "ttw:text-xs ttw:font-normal ttw:text-zinc-500",
87
+ children: y._("PDF, PNG or JPG (max. 20MB)")
88
+ })
89
+ ]
90
+ })
91
+ }),
92
+ /* @__PURE__ */ p("div", {
93
+ className: "ttw:flex ttw:flex-col",
94
+ children: [/* @__PURE__ */ f("h3", {
95
+ className: "ttw:text-primary ttw:text-sm ttw:font-semibold",
96
+ children: y._("Send via email")
97
+ }), /* @__PURE__ */ f("p", {
98
+ className: "ttw:text-zinc-500 ttw:font-normal ttw:text-sm",
99
+ children: y._("Email your bills here and they'll appear in your bill pay inbox, ready to review and pay.")
100
+ })]
101
+ }),
102
+ /* @__PURE__ */ p("div", {
103
+ className: "ttw:px-3 ttw:h-14 ttw:border ttw:border-zinc-200 ttw:rounded-lg ttw:flex ttw:items-center ttw:justify-between ttw:gap-6",
104
+ children: [/* @__PURE__ */ f("span", { children: y._("bills@business-banking.com") }), /* @__PURE__ */ p(n, {
105
+ type: "button",
106
+ variant: "ghost",
107
+ size: "sm",
108
+ className: "ttw:text-primary ttw:hover:bg-primary-foreground ttw:hover:text-primary",
109
+ onClick: () => {
110
+ navigator.clipboard.writeText("bills@business-banking.com"), m.success(y._("Email address copied to clipboard"));
111
+ },
112
+ children: [/* @__PURE__ */ f(u, {}), y._("Copy")]
113
+ })]
114
+ }),
115
+ /* @__PURE__ */ p("div", {
116
+ className: "ttw:flex ttw:flex-col ttw:gap-4",
117
+ children: [/* @__PURE__ */ f("h3", {
118
+ className: "ttw:text-sm ttw:font-semibold ttw:text-primary",
119
+ children: y._("Or add bill manually")
120
+ }), /* @__PURE__ */ p(n, {
121
+ onClick: () => {
122
+ x(!1), _();
123
+ },
124
+ className: "ttw:w-fit ttw:bg-primary-foreground ttw:hover:bg-primary-foreground ttw:text-primary",
125
+ children: [/* @__PURE__ */ f(d, {}), y._("Add new bill")]
126
+ })]
127
+ })
128
+ ]
129
+ }), /* @__PURE__ */ f(S, {
130
+ "aria-label": y._("Upload payable files"),
131
+ multiple: !0,
132
+ onChange: (e) => {
133
+ let t = e.target.files;
134
+ t && v(t), x(!1);
135
+ }
136
+ })]
137
+ })]
138
+ })
139
+ });
140
+ };
141
+ //#endregion
142
+ export { g as CreatePayableMenu };
@@ -1,167 +1 @@
1
- import { Scope as e } from "../../shared/data-access/dist/lib/scopes.js";
2
- import "../../shared/data-access/dist/index.js";
3
- import { getAPIErrorMessage as t } from "./index26.js";
4
- import { generatePayablesButtonCssVars as n } from "./index42.js";
5
- import { useMoniteContext as r } from "./index45.js";
6
- import { useRootElements as i } from "./index78.js";
7
- import "./index79.js";
8
- import { useFileInput as a } from "./index81.js";
9
- import { useComponentSettings as ee } from "./index87.js";
10
- import "./index89.js";
11
- import { Dialog as o } from "./index128.js";
12
- import "./index129.js";
13
- import { MoniteScopedProviders as s } from "./index155.js";
14
- import { useUserPermissions as te } from "./index156.js";
15
- import { AccessRestriction as c } from "./index162.js";
16
- import "./index165.js";
17
- import { usePayableCallbacks as l } from "./index202.js";
18
- import { PayableDetails as u } from "./index272.js";
19
- import { PayablesTable as ne } from "./index285.js";
20
- import "./index273.js";
21
- import "./index286.js";
22
- import { CreatePayableMenu as d } from "./index288.js";
23
1
  import "./index289.js";
24
- import { useEffect as re, useMemo as ie, useRef as ae, useState as f } from "react";
25
- import { jsx as p, jsxs as m } from "@emotion/react/jsx-runtime";
26
- import { toast as h } from "react-hot-toast";
27
- import { useLingui as g } from "@lingui/react";
28
- //#region ../../libs/tesouro-embedded-components-react/monite-sdk/dist/index290.js
29
- var _ = (e) => /* @__PURE__ */ p(s, { children: /* @__PURE__ */ p(v, { ...e }) }), v = ({ pageTitleComponent: s, enableGLCodes: _, initialView: v, initialCounterpartId: y, onSaved: b, onCanceled: x, onSubmitted: S, onRejected: C, onApproved: oe, onReopened: se, onDeleted: ce, onPay: le }) => {
30
- let { i18n: w } = g(), { api: T, queryClient: E, theme: D } = r(), { componentSettings: O } = ee(), { handleSaved: k, handleCanceled: A, handleSubmitted: j, handleRejected: M, handleApproved: N, handleReopened: P, handleDeleted: F, handlePay: I } = l({
31
- onSaved: b,
32
- onCanceled: x,
33
- onSubmitted: S,
34
- onRejected: C,
35
- onApproved: oe,
36
- onReopened: se,
37
- onDeleted: ce,
38
- onPay: le
39
- }), [L, R] = f({
40
- invoiceId: void 0,
41
- open: !1,
42
- shouldOpenEditMode: !1
43
- }), z = () => {
44
- R((e) => ({
45
- ...e,
46
- open: !1,
47
- shouldOpenEditMode: !1,
48
- invoiceId: void 0
49
- }));
50
- }, [B, V] = f(!1), [H, U] = f(void 0), W = ae(!1), G = () => {
51
- V(!1), U(void 0);
52
- }, { FileInput: ue, openFileInput: de, checkFileError: fe } = a(), K = T.finops.postPayablesUploadFromFile.useMutation({}, {
53
- onSuccess: () => T.finops.getPayables.invalidateQueries(E),
54
- onError: () => {}
55
- }), q = (e) => {
56
- let n = e instanceof File ? [e] : Array.from(e);
57
- if (n.length > 10) {
58
- h.error(w._("You can only upload up to {fileCount} files at a time", { fileCount: 10 }));
59
- return;
60
- }
61
- n.forEach((e) => {
62
- let n = fe(e);
63
- if (n) {
64
- h.error(n);
65
- return;
66
- }
67
- h.promise(K.mutateAsync({ file: e }), {
68
- loading: w._("Uploading {fileName}", { fileName: e.name }),
69
- success: w._("Payable {fileName} uploaded successfully", { fileName: e.name }),
70
- error: (e) => t(w, e)
71
- });
72
- });
73
- }, J = te(), Y = J.has(e.PayableWriteOrg), X = J.has(e.PayableReadOrg);
74
- re(() => {
75
- W.current || v === "create" && Y && (W.current = !0, U(y), V(!0));
76
- }, [
77
- v,
78
- Y,
79
- y
80
- ]);
81
- let { root: Z } = i(), Q = "Monite-Payables-Header", $ = _ ?? O?.payables?.enableGLCodes ?? !1, pe = ie(() => n(D.components?.styles?.payables?.button), [D.components?.styles?.payables?.button]);
82
- return /* @__PURE__ */ m("div", {
83
- className: "Monite-Payables",
84
- style: pe,
85
- children: [
86
- s(/* @__PURE__ */ p(d, {
87
- isCreateAllowed: Y,
88
- onCreateInvoice: () => {
89
- U(void 0), V(!0);
90
- },
91
- handleFileUpload: q
92
- })),
93
- !X && /* @__PURE__ */ p(c, {}),
94
- X && /* @__PURE__ */ p(ne, {
95
- initialCounterpartId: v === "create" ? void 0 : y,
96
- onRowClick: (e) => R({
97
- open: !0,
98
- invoiceId: e
99
- }),
100
- onPay: I,
101
- onApproved: N,
102
- onCanceled: A,
103
- onSubmitted: j,
104
- openFileInput: de,
105
- setIsCreateInvoiceDialogOpen: V,
106
- openEditDialog: (e) => R({
107
- open: !0,
108
- invoiceId: e,
109
- shouldOpenEditMode: !0
110
- })
111
- }),
112
- /* @__PURE__ */ p(ue, {
113
- "aria-label": w._("Upload payable files"),
114
- multiple: !0,
115
- onChange: (e) => {
116
- let t = e.target.files;
117
- t && q(t);
118
- }
119
- }),
120
- /* @__PURE__ */ p(o, {
121
- className: Q + "-Dialog-PayableDetails",
122
- open: L.open,
123
- container: Z,
124
- onClose: z,
125
- onClosed: z,
126
- fullScreen: !0,
127
- children: /* @__PURE__ */ p(u, {
128
- id: L.invoiceId,
129
- shouldOpenInEditMode: L.shouldOpenEditMode,
130
- enableGLCodes: $,
131
- onClose: z,
132
- onSaved: k,
133
- onCanceled: A,
134
- onSubmitted: j,
135
- onRejected: M,
136
- onApproved: N,
137
- onReopened: P,
138
- onDeleted: (e) => {
139
- F?.(e), z(), h(w._("Bill #{payableId} has been deleted", { payableId: e }), { duration: 5e3 });
140
- },
141
- onPay: I
142
- })
143
- }),
144
- /* @__PURE__ */ p(o, {
145
- className: Q + "-Dialog-CreatePayable",
146
- open: B,
147
- container: Z,
148
- onClose: G,
149
- fullScreen: !0,
150
- children: /* @__PURE__ */ p(u, {
151
- shouldOpenInEditMode: !0,
152
- initialCounterpartId: H,
153
- enableGLCodes: $,
154
- onClose: G,
155
- onSaved: (e) => {
156
- R({
157
- open: !0,
158
- invoiceId: e
159
- }), G(), k?.(e);
160
- }
161
- })
162
- })
163
- ]
164
- });
165
- };
166
- //#endregion
167
- export { _ as Payables };
@@ -1,26 +1,167 @@
1
- import "./index200.js";
2
- import "./index201.js";
3
- import "./index202.js";
4
- import "./index203.js";
5
- import "./index204.js";
6
- import "./index205.js";
7
- import "./index206.js";
8
- import "./index207.js";
9
- import "./index208.js";
10
- import "./index209.js";
11
- import "./index210.js";
12
- import "./index211.js";
13
- import "./index212.js";
14
- import "./index213.js";
15
- import "./index214.js";
16
- import "./index215.js";
17
- import "./index216.js";
18
- import "./index217.js";
19
- import "./index218.js";
20
- import "./index219.js";
21
- import "./index220.js";
22
- import "./index272.js";
23
- import "./index285.js";
24
- import "./index273.js";
25
- import "./index286.js";
1
+ import { Scope as e } from "../../shared/data-access/dist/lib/scopes.js";
2
+ import "../../shared/data-access/dist/index.js";
3
+ import { getAPIErrorMessage as t } from "./index26.js";
4
+ import { generatePayablesButtonCssVars as n } from "./index42.js";
5
+ import { useMoniteContext as r } from "./index45.js";
6
+ import { useRootElements as i } from "./index78.js";
7
+ import "./index79.js";
8
+ import { useFileInput as a } from "./index81.js";
9
+ import { useComponentSettings as ee } from "./index87.js";
10
+ import "./index89.js";
11
+ import { Dialog as o } from "./index129.js";
12
+ import "./index130.js";
13
+ import { MoniteScopedProviders as s } from "./index155.js";
14
+ import { useUserPermissions as te } from "./index156.js";
15
+ import { AccessRestriction as c } from "./index162.js";
16
+ import "./index165.js";
17
+ import { usePayableCallbacks as l } from "./index202.js";
18
+ import { PayableDetails as u } from "./index273.js";
19
+ import { PayablesTable as ne } from "./index286.js";
20
+ import "./index274.js";
21
+ import "./index287.js";
22
+ import { CreatePayableMenu as d } from "./index289.js";
26
23
  import "./index290.js";
24
+ import { useEffect as re, useMemo as ie, useRef as ae, useState as f } from "react";
25
+ import { jsx as p, jsxs as m } from "@emotion/react/jsx-runtime";
26
+ import { toast as h } from "react-hot-toast";
27
+ import { useLingui as g } from "@lingui/react";
28
+ //#region ../../libs/tesouro-embedded-components-react/monite-sdk/dist/index291.js
29
+ var _ = (e) => /* @__PURE__ */ p(s, { children: /* @__PURE__ */ p(v, { ...e }) }), v = ({ pageTitleComponent: s, enableGLCodes: _, initialView: v, initialCounterpartId: y, onSaved: b, onCanceled: x, onSubmitted: S, onRejected: C, onApproved: oe, onReopened: se, onDeleted: ce, onPay: le }) => {
30
+ let { i18n: w } = g(), { api: T, queryClient: E, theme: D } = r(), { componentSettings: O } = ee(), { handleSaved: k, handleCanceled: A, handleSubmitted: j, handleRejected: M, handleApproved: N, handleReopened: P, handleDeleted: F, handlePay: I } = l({
31
+ onSaved: b,
32
+ onCanceled: x,
33
+ onSubmitted: S,
34
+ onRejected: C,
35
+ onApproved: oe,
36
+ onReopened: se,
37
+ onDeleted: ce,
38
+ onPay: le
39
+ }), [L, R] = f({
40
+ invoiceId: void 0,
41
+ open: !1,
42
+ shouldOpenEditMode: !1
43
+ }), z = () => {
44
+ R((e) => ({
45
+ ...e,
46
+ open: !1,
47
+ shouldOpenEditMode: !1,
48
+ invoiceId: void 0
49
+ }));
50
+ }, [B, V] = f(!1), [H, U] = f(void 0), W = ae(!1), G = () => {
51
+ V(!1), U(void 0);
52
+ }, { FileInput: ue, openFileInput: de, checkFileError: fe } = a(), K = T.finops.postPayablesUploadFromFile.useMutation({}, {
53
+ onSuccess: () => T.finops.getPayables.invalidateQueries(E),
54
+ onError: () => {}
55
+ }), q = (e) => {
56
+ let n = e instanceof File ? [e] : Array.from(e);
57
+ if (n.length > 10) {
58
+ h.error(w._("You can only upload up to {fileCount} files at a time", { fileCount: 10 }));
59
+ return;
60
+ }
61
+ n.forEach((e) => {
62
+ let n = fe(e);
63
+ if (n) {
64
+ h.error(n);
65
+ return;
66
+ }
67
+ h.promise(K.mutateAsync({ file: e }), {
68
+ loading: w._("Uploading {fileName}", { fileName: e.name }),
69
+ success: w._("Payable {fileName} uploaded successfully", { fileName: e.name }),
70
+ error: (e) => t(w, e)
71
+ });
72
+ });
73
+ }, J = te(), Y = J.has(e.PayableWriteOrg), X = J.has(e.PayableReadOrg);
74
+ re(() => {
75
+ W.current || v === "create" && Y && (W.current = !0, U(y), V(!0));
76
+ }, [
77
+ v,
78
+ Y,
79
+ y
80
+ ]);
81
+ let { root: Z } = i(), Q = "Monite-Payables-Header", $ = _ ?? O?.payables?.enableGLCodes ?? !1, pe = ie(() => n(D.components?.styles?.payables?.button), [D.components?.styles?.payables?.button]);
82
+ return /* @__PURE__ */ m("div", {
83
+ className: "Monite-Payables",
84
+ style: pe,
85
+ children: [
86
+ s(/* @__PURE__ */ p(d, {
87
+ isCreateAllowed: Y,
88
+ onCreateInvoice: () => {
89
+ U(void 0), V(!0);
90
+ },
91
+ handleFileUpload: q
92
+ })),
93
+ !X && /* @__PURE__ */ p(c, {}),
94
+ X && /* @__PURE__ */ p(ne, {
95
+ initialCounterpartId: v === "create" ? void 0 : y,
96
+ onRowClick: (e) => R({
97
+ open: !0,
98
+ invoiceId: e
99
+ }),
100
+ onPay: I,
101
+ onApproved: N,
102
+ onCanceled: A,
103
+ onSubmitted: j,
104
+ openFileInput: de,
105
+ setIsCreateInvoiceDialogOpen: V,
106
+ openEditDialog: (e) => R({
107
+ open: !0,
108
+ invoiceId: e,
109
+ shouldOpenEditMode: !0
110
+ })
111
+ }),
112
+ /* @__PURE__ */ p(ue, {
113
+ "aria-label": w._("Upload payable files"),
114
+ multiple: !0,
115
+ onChange: (e) => {
116
+ let t = e.target.files;
117
+ t && q(t);
118
+ }
119
+ }),
120
+ /* @__PURE__ */ p(o, {
121
+ className: Q + "-Dialog-PayableDetails",
122
+ open: L.open,
123
+ container: Z,
124
+ onClose: z,
125
+ onClosed: z,
126
+ fullScreen: !0,
127
+ children: /* @__PURE__ */ p(u, {
128
+ id: L.invoiceId,
129
+ shouldOpenInEditMode: L.shouldOpenEditMode,
130
+ enableGLCodes: $,
131
+ onClose: z,
132
+ onSaved: k,
133
+ onCanceled: A,
134
+ onSubmitted: j,
135
+ onRejected: M,
136
+ onApproved: N,
137
+ onReopened: P,
138
+ onDeleted: (e) => {
139
+ F?.(e), z(), h(w._("Bill #{payableId} has been deleted", { payableId: e }), { duration: 5e3 });
140
+ },
141
+ onPay: I
142
+ })
143
+ }),
144
+ /* @__PURE__ */ p(o, {
145
+ className: Q + "-Dialog-CreatePayable",
146
+ open: B,
147
+ container: Z,
148
+ onClose: G,
149
+ fullScreen: !0,
150
+ children: /* @__PURE__ */ p(u, {
151
+ shouldOpenInEditMode: !0,
152
+ initialCounterpartId: H,
153
+ enableGLCodes: $,
154
+ onClose: G,
155
+ onSaved: (e) => {
156
+ R({
157
+ open: !0,
158
+ invoiceId: e
159
+ }), G(), k?.(e);
160
+ }
161
+ })
162
+ })
163
+ ]
164
+ });
165
+ };
166
+ //#endregion
167
+ export { _ as Payables };