@levo-so/react 0.0.2-alpha → 0.1.1

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 (215) hide show
  1. package/dist/Checbox-sq-atGlJ.js +28 -0
  2. package/dist/CheckboxWidget-ComdVcZ_.js +118 -0
  3. package/dist/CollectionFormBuilder-jwwjyIpv.js +738 -0
  4. package/dist/CurrencyWidget-DVqD_lsY.js +60 -0
  5. package/dist/DateTimeWidget-CvgzwY1U.js +80 -0
  6. package/dist/DefaultFormVariant-CbRB9O_e.js +80 -0
  7. package/dist/DropdownWidget-C2YaM9Cf.js +115 -0
  8. package/dist/EmailWidget-BBthwF68.js +41 -0
  9. package/dist/GeocoderWidget-Dht_2vi6.js +309 -0
  10. package/dist/Input-2CvZ90f8.js +54 -0
  11. package/dist/LevoProvider-DNbYyEaf.js +21 -0
  12. package/dist/MultiGeocoderWidget-paCFW0QZ.js +49 -0
  13. package/dist/PhoneWidget-CP2T2JDx.js +47 -0
  14. package/dist/RadioWidget-BuFPz7kK.js +109 -0
  15. package/dist/RichTextWidget-DGFNZ1jl.js +310 -0
  16. package/dist/Sonner-t6JVKA0a.js +39 -0
  17. package/dist/Spinner-CuUosd-S.js +297 -0
  18. package/dist/StepsFormVariant-5_c3f2Vk.js +137 -0
  19. package/dist/SwitchWidget-t8iwhxk9.js +53 -0
  20. package/dist/TextWidget-D0UBxTxe.js +33 -0
  21. package/dist/TextareaWidget-CG6J_plD.js +30 -0
  22. package/dist/ToggleCheckboxWidget-dl8ks4VX.js +44 -0
  23. package/dist/Tooltip-CI4i4mYr.js +144 -0
  24. package/dist/URLWidget-CHeUEUXl.js +14 -0
  25. package/dist/UploadWidget-CzYGViqE.js +503 -0
  26. package/dist/audience/{block.d.ts → components/block.d.ts} +1 -1
  27. package/dist/audience/components/block.d.ts.map +1 -0
  28. package/dist/audience/{component.d.ts → components/component.d.ts} +1 -1
  29. package/dist/audience/components/component.d.ts.map +1 -0
  30. package/dist/audience/{page.d.ts → components/page.d.ts} +1 -1
  31. package/dist/audience/components/page.d.ts.map +1 -0
  32. package/dist/audience/components/useScrollDepth.d.ts.map +1 -0
  33. package/dist/audience/index.d.ts +3 -3
  34. package/dist/audience/index.d.ts.map +1 -1
  35. package/dist/audience/index.js +4 -2303
  36. package/dist/byteToSize-BFKZSBu1.js +8 -0
  37. package/dist/cn-C9QoOYNG.js +6 -0
  38. package/dist/collection/components/CollectionFormBuilder.d.ts +12 -0
  39. package/dist/collection/components/CollectionFormBuilder.d.ts.map +1 -0
  40. package/dist/collection/components/FieldRenderer.d.ts +9 -0
  41. package/dist/collection/components/FieldRenderer.d.ts.map +1 -0
  42. package/dist/collection/components/core/AsyncSelectPaginate/AsyncSelectPaginate.d.ts +5 -0
  43. package/dist/collection/components/core/AsyncSelectPaginate/AsyncSelectPaginate.d.ts.map +1 -0
  44. package/dist/collection/components/core/Checkbox/Checbox.d.ts +5 -0
  45. package/dist/collection/components/core/Checkbox/Checbox.d.ts.map +1 -0
  46. package/dist/collection/components/core/Input/Input.d.ts +11 -0
  47. package/dist/collection/components/core/Input/Input.d.ts.map +1 -0
  48. package/dist/collection/components/core/Switch/Switch.d.ts +5 -0
  49. package/dist/collection/components/core/Switch/Switch.d.ts.map +1 -0
  50. package/dist/collection/components/renderer/RenderArrayWidget.d.ts +5 -0
  51. package/dist/collection/components/renderer/RenderArrayWidget.d.ts.map +1 -0
  52. package/dist/collection/components/renderer/RenderCommonField.d.ts +5 -0
  53. package/dist/collection/components/renderer/RenderCommonField.d.ts.map +1 -0
  54. package/dist/collection/components/renderer/RenderRecordWidget.d.ts +4 -0
  55. package/dist/collection/components/renderer/RenderRecordWidget.d.ts.map +1 -0
  56. package/dist/collection/components/widgets/ErrorMessage.d.ts +6 -0
  57. package/dist/collection/components/widgets/ErrorMessage.d.ts.map +1 -0
  58. package/dist/collection/components/widgets/FieldWrapper.d.ts +14 -0
  59. package/dist/collection/components/widgets/FieldWrapper.d.ts.map +1 -0
  60. package/dist/collection/components/widgets/FormHelperText.d.ts +6 -0
  61. package/dist/collection/components/widgets/FormHelperText.d.ts.map +1 -0
  62. package/dist/collection/components/widgets/FormLabel.d.ts +8 -0
  63. package/dist/collection/components/widgets/FormLabel.d.ts.map +1 -0
  64. package/dist/collection/components/widgets/checkboxWidget/CheckboxWidget.d.ts +8 -0
  65. package/dist/collection/components/widgets/checkboxWidget/CheckboxWidget.d.ts.map +1 -0
  66. package/dist/collection/components/widgets/collectionWidget/CollectionWidget.d.ts +7 -0
  67. package/dist/collection/components/widgets/collectionWidget/CollectionWidget.d.ts.map +1 -0
  68. package/dist/collection/components/widgets/currencyWidget/CurrencyWidget.d.ts +9 -0
  69. package/dist/collection/components/widgets/currencyWidget/CurrencyWidget.d.ts.map +1 -0
  70. package/dist/collection/components/widgets/dateTimeWidget/DateTimeWidget.d.ts +8 -0
  71. package/dist/collection/components/widgets/dateTimeWidget/DateTimeWidget.d.ts.map +1 -0
  72. package/dist/collection/components/widgets/dropdownWidget/DropdownWidget.d.ts +9 -0
  73. package/dist/collection/components/widgets/dropdownWidget/DropdownWidget.d.ts.map +1 -0
  74. package/dist/collection/components/widgets/emailWidget/EmailWidget.d.ts +8 -0
  75. package/dist/collection/components/widgets/emailWidget/EmailWidget.d.ts.map +1 -0
  76. package/dist/collection/components/widgets/geocoderWidget/GeocoderWidget.d.ts +8 -0
  77. package/dist/collection/components/widgets/geocoderWidget/GeocoderWidget.d.ts.map +1 -0
  78. package/dist/collection/components/widgets/multiGeocoderWidget/MultiGeocoderWidget.d.ts +8 -0
  79. package/dist/collection/components/widgets/multiGeocoderWidget/MultiGeocoderWidget.d.ts.map +1 -0
  80. package/dist/collection/components/widgets/phoneWidget/PhoneWidget.d.ts +8 -0
  81. package/dist/collection/components/widgets/phoneWidget/PhoneWidget.d.ts.map +1 -0
  82. package/dist/collection/components/widgets/radioWidget/RadioWidget.d.ts +11 -0
  83. package/dist/collection/components/widgets/radioWidget/RadioWidget.d.ts.map +1 -0
  84. package/dist/collection/components/widgets/richTextWidget/RichTextWidget.d.ts +12 -0
  85. package/dist/collection/components/widgets/richTextWidget/RichTextWidget.d.ts.map +1 -0
  86. package/dist/collection/components/widgets/switchWidget/SwitchWidget.d.ts +8 -0
  87. package/dist/collection/components/widgets/switchWidget/SwitchWidget.d.ts.map +1 -0
  88. package/dist/collection/components/widgets/textWidget/TextWidget.d.ts +9 -0
  89. package/dist/collection/components/widgets/textWidget/TextWidget.d.ts.map +1 -0
  90. package/dist/collection/components/widgets/textareaWidget/TextareaWidget.d.ts +8 -0
  91. package/dist/collection/components/widgets/textareaWidget/TextareaWidget.d.ts.map +1 -0
  92. package/dist/collection/components/widgets/toggleCheckboxWidget/ToggleCheckboxWidget.d.ts +8 -0
  93. package/dist/collection/components/widgets/toggleCheckboxWidget/ToggleCheckboxWidget.d.ts.map +1 -0
  94. package/dist/collection/components/widgets/uploadWidget/FileUploadDropBox.d.ts +10 -0
  95. package/dist/collection/components/widgets/uploadWidget/FileUploadDropBox.d.ts.map +1 -0
  96. package/dist/collection/components/widgets/uploadWidget/FileUploadModal.d.ts +13 -0
  97. package/dist/collection/components/widgets/uploadWidget/FileUploadModal.d.ts.map +1 -0
  98. package/dist/collection/components/widgets/uploadWidget/ImportFromAssets.d.ts +11 -0
  99. package/dist/collection/components/widgets/uploadWidget/ImportFromAssets.d.ts.map +1 -0
  100. package/dist/collection/components/widgets/uploadWidget/UploadWidget.d.ts +19 -0
  101. package/dist/collection/components/widgets/uploadWidget/UploadWidget.d.ts.map +1 -0
  102. package/dist/collection/components/widgets/urlWidget/URLWidget.d.ts +5 -0
  103. package/dist/collection/components/widgets/urlWidget/URLWidget.d.ts.map +1 -0
  104. package/dist/collection/index.d.ts +5 -0
  105. package/dist/collection/index.d.ts.map +1 -0
  106. package/dist/collection/index.js +19 -0
  107. package/dist/collection/lib/FormBuilder.d.ts +8 -0
  108. package/dist/collection/lib/FormBuilder.d.ts.map +1 -0
  109. package/dist/collection/lib/SaveDraftValues.d.ts +7 -0
  110. package/dist/collection/lib/SaveDraftValues.d.ts.map +1 -0
  111. package/dist/collection/lib/hooks/useLevoForm.d.ts +18 -0
  112. package/dist/collection/lib/hooks/useLevoForm.d.ts.map +1 -0
  113. package/dist/collection/lib/provider/LevoFormProvider.d.ts +9 -0
  114. package/dist/collection/lib/provider/LevoFormProvider.d.ts.map +1 -0
  115. package/dist/collection/lib/variants/DefaultFormVariant.d.ts +3 -0
  116. package/dist/collection/lib/variants/DefaultFormVariant.d.ts.map +1 -0
  117. package/dist/collection/lib/variants/StepsFormVariant.d.ts +4 -0
  118. package/dist/collection/lib/variants/StepsFormVariant.d.ts.map +1 -0
  119. package/dist/collection/types/context.d.ts +34 -0
  120. package/dist/collection/types/context.d.ts.map +1 -0
  121. package/dist/collection/types/errors.d.ts +7 -0
  122. package/dist/collection/types/errors.d.ts.map +1 -0
  123. package/dist/collection/types/formVariant.d.ts +18 -0
  124. package/dist/collection/types/formVariant.d.ts.map +1 -0
  125. package/dist/collection/types/forms.d.ts +31 -0
  126. package/dist/collection/types/forms.d.ts.map +1 -0
  127. package/dist/collection/types/index.d.ts +4 -0
  128. package/dist/collection/types/index.d.ts.map +1 -0
  129. package/dist/collection/types/renderer.d.ts +6 -0
  130. package/dist/collection/types/renderer.d.ts.map +1 -0
  131. package/dist/collection/utils/formHelpers.d.ts +47 -0
  132. package/dist/collection/utils/formHelpers.d.ts.map +1 -0
  133. package/dist/collection/utils/getFieldValidations.d.ts +6 -0
  134. package/dist/collection/utils/getFieldValidations.d.ts.map +1 -0
  135. package/dist/collection/utils/index.d.ts +4 -0
  136. package/dist/collection/utils/index.d.ts.map +1 -0
  137. package/dist/collection/utils/schema.d.ts +3 -0
  138. package/dist/collection/utils/schema.d.ts.map +1 -0
  139. package/dist/collection/utils/setFormErrors.d.ts +4 -0
  140. package/dist/collection/utils/setFormErrors.d.ts.map +1 -0
  141. package/dist/collection/utils/storage.d.ts +11 -0
  142. package/dist/collection/utils/storage.d.ts.map +1 -0
  143. package/dist/components/Dialog.d.ts +21 -0
  144. package/dist/components/Dialog.d.ts.map +1 -0
  145. package/dist/components/DialogWrapper.d.ts +11 -0
  146. package/dist/components/DialogWrapper.d.ts.map +1 -0
  147. package/dist/components/Sonner.d.ts +7 -0
  148. package/dist/components/Sonner.d.ts.map +1 -0
  149. package/dist/components/Spinner.d.ts +5 -0
  150. package/dist/components/Spinner.d.ts.map +1 -0
  151. package/dist/components/Tabs.d.ts +8 -0
  152. package/dist/components/Tabs.d.ts.map +1 -0
  153. package/dist/components/Tooltip.d.ts +16 -0
  154. package/dist/components/Tooltip.d.ts.map +1 -0
  155. package/dist/components/button/Button.d.ts +12 -0
  156. package/dist/components/button/Button.d.ts.map +1 -0
  157. package/dist/components/button/buttonVariants.d.ts +6 -0
  158. package/dist/components/button/buttonVariants.d.ts.map +1 -0
  159. package/dist/components/button/index.d.ts +3 -0
  160. package/dist/components/button/index.d.ts.map +1 -0
  161. package/dist/components/index.d.ts +8 -0
  162. package/dist/components/index.d.ts.map +1 -0
  163. package/dist/components/index.js +33 -0
  164. package/dist/constants/fileUploadPresets.d.ts +34 -0
  165. package/dist/constants/fileUploadPresets.d.ts.map +1 -0
  166. package/dist/constants/index.d.ts +2 -0
  167. package/dist/constants/index.d.ts.map +1 -0
  168. package/dist/errorHandler-BJcFS2qV.js +26 -0
  169. package/dist/fileUploadPresets-2raQmHT0.js +74 -0
  170. package/dist/index-wTf_TtOG.js +131 -0
  171. package/dist/index.d.ts +8 -0
  172. package/dist/index.js +84 -0
  173. package/dist/isEmptyObject-C5s4GzLE.js +8 -0
  174. package/dist/jsx-runtime-B6kdoens.js +634 -0
  175. package/dist/membership/components/OAuth/Button.d.ts +8 -0
  176. package/dist/membership/components/OAuth/Button.d.ts.map +1 -0
  177. package/dist/membership/components/OAuth/Container.d.ts +24 -0
  178. package/dist/membership/components/OAuth/Container.d.ts.map +1 -0
  179. package/dist/membership/components/OAuth/Core.d.ts +17 -0
  180. package/dist/membership/components/OAuth/Core.d.ts.map +1 -0
  181. package/dist/membership/components/OAuth/Popup.d.ts +15 -0
  182. package/dist/membership/components/OAuth/Popup.d.ts.map +1 -0
  183. package/dist/membership/components/index.d.ts +8 -0
  184. package/dist/membership/components/index.d.ts.map +1 -0
  185. package/dist/membership/index.d.ts +2 -0
  186. package/dist/membership/index.d.ts.map +1 -0
  187. package/dist/membership/index.js +4 -0
  188. package/dist/page-CxaKoH22.js +205 -0
  189. package/dist/providers/LevoProvider.d.ts +25 -0
  190. package/dist/providers/LevoProvider.d.ts.map +1 -0
  191. package/dist/style.css +1 -0
  192. package/dist/useLevoForm-BcN8f66y.js +166 -0
  193. package/dist/utils/byteToSize.d.ts +3 -0
  194. package/dist/utils/byteToSize.d.ts.map +1 -0
  195. package/dist/utils/cn.d.ts +4 -0
  196. package/dist/utils/cn.d.ts.map +1 -0
  197. package/dist/utils/errorHandler.d.ts +2 -0
  198. package/dist/utils/errorHandler.d.ts.map +1 -0
  199. package/dist/utils/index.d.ts +8 -0
  200. package/dist/utils/index.d.ts.map +1 -0
  201. package/dist/utils/index.js +14 -0
  202. package/dist/utils/isDateObject.d.ts +2 -0
  203. package/dist/utils/isDateObject.d.ts.map +1 -0
  204. package/dist/utils/isEmptyObject.d.ts +5 -0
  205. package/dist/utils/isEmptyObject.d.ts.map +1 -0
  206. package/dist/utils/isNullOrUndefined.d.ts +2 -0
  207. package/dist/utils/isNullOrUndefined.d.ts.map +1 -0
  208. package/dist/utils/isObject.d.ts +3 -0
  209. package/dist/utils/isObject.d.ts.map +1 -0
  210. package/package.json +88 -5
  211. package/dist/audience/block.d.ts.map +0 -1
  212. package/dist/audience/component.d.ts.map +0 -1
  213. package/dist/audience/page.d.ts.map +0 -1
  214. package/dist/audience/useScrollDepth.d.ts.map +0 -1
  215. /package/dist/audience/{useScrollDepth.d.ts → components/useScrollDepth.d.ts} +0 -0
@@ -0,0 +1,297 @@
1
+ "use client";
2
+ import { j as c } from "./jsx-runtime-B6kdoens.js";
3
+ import { Slot as B } from "@radix-ui/react-slot";
4
+ import * as m from "react";
5
+ import l from "react";
6
+ import { twMerge as j } from "tailwind-merge";
7
+ import { cva as O } from "class-variance-authority";
8
+ import { c as u } from "./cn-C9QoOYNG.js";
9
+ import * as d from "@radix-ui/react-tabs";
10
+ var x = {
11
+ color: void 0,
12
+ size: void 0,
13
+ className: void 0,
14
+ style: void 0,
15
+ attr: void 0
16
+ }, p = l.createContext && /* @__PURE__ */ l.createContext(x), P = ["attr", "size", "title"];
17
+ function M(t, e) {
18
+ if (t == null) return {};
19
+ var r = N(t, e), a, n;
20
+ if (Object.getOwnPropertySymbols) {
21
+ var o = Object.getOwnPropertySymbols(t);
22
+ for (n = 0; n < o.length; n++)
23
+ a = o[n], !(e.indexOf(a) >= 0) && Object.prototype.propertyIsEnumerable.call(t, a) && (r[a] = t[a]);
24
+ }
25
+ return r;
26
+ }
27
+ function N(t, e) {
28
+ if (t == null) return {};
29
+ var r = {};
30
+ for (var a in t)
31
+ if (Object.prototype.hasOwnProperty.call(t, a)) {
32
+ if (e.indexOf(a) >= 0) continue;
33
+ r[a] = t[a];
34
+ }
35
+ return r;
36
+ }
37
+ function f() {
38
+ return f = Object.assign ? Object.assign.bind() : function(t) {
39
+ for (var e = 1; e < arguments.length; e++) {
40
+ var r = arguments[e];
41
+ for (var a in r)
42
+ Object.prototype.hasOwnProperty.call(r, a) && (t[a] = r[a]);
43
+ }
44
+ return t;
45
+ }, f.apply(this, arguments);
46
+ }
47
+ function b(t, e) {
48
+ var r = Object.keys(t);
49
+ if (Object.getOwnPropertySymbols) {
50
+ var a = Object.getOwnPropertySymbols(t);
51
+ e && (a = a.filter(function(n) {
52
+ return Object.getOwnPropertyDescriptor(t, n).enumerable;
53
+ })), r.push.apply(r, a);
54
+ }
55
+ return r;
56
+ }
57
+ function g(t) {
58
+ for (var e = 1; e < arguments.length; e++) {
59
+ var r = arguments[e] != null ? arguments[e] : {};
60
+ e % 2 ? b(Object(r), !0).forEach(function(a) {
61
+ L(t, a, r[a]);
62
+ }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(t, Object.getOwnPropertyDescriptors(r)) : b(Object(r)).forEach(function(a) {
63
+ Object.defineProperty(t, a, Object.getOwnPropertyDescriptor(r, a));
64
+ });
65
+ }
66
+ return t;
67
+ }
68
+ function L(t, e, r) {
69
+ return e = C(e), e in t ? Object.defineProperty(t, e, { value: r, enumerable: !0, configurable: !0, writable: !0 }) : t[e] = r, t;
70
+ }
71
+ function C(t) {
72
+ var e = S(t, "string");
73
+ return typeof e == "symbol" ? e : e + "";
74
+ }
75
+ function S(t, e) {
76
+ if (typeof t != "object" || !t) return t;
77
+ var r = t[Symbol.toPrimitive];
78
+ if (r !== void 0) {
79
+ var a = r.call(t, e || "default");
80
+ if (typeof a != "object") return a;
81
+ throw new TypeError("@@toPrimitive must return a primitive value.");
82
+ }
83
+ return (e === "string" ? String : Number)(t);
84
+ }
85
+ function z(t) {
86
+ return t && t.map((e, r) => /* @__PURE__ */ l.createElement(e.tag, g({
87
+ key: r
88
+ }, e.attr), z(e.child)));
89
+ }
90
+ function i(t) {
91
+ return (e) => /* @__PURE__ */ l.createElement(E, f({
92
+ attr: g({}, t.attr)
93
+ }, e), z(t.child));
94
+ }
95
+ function E(t) {
96
+ var e = (r) => {
97
+ var {
98
+ attr: a,
99
+ size: n,
100
+ title: o
101
+ } = t, h = M(t, P), v = n || r.size || "1em", s;
102
+ return r.className && (s = r.className), t.className && (s = (s ? s + " " : "") + t.className), /* @__PURE__ */ l.createElement("svg", f({
103
+ stroke: "currentColor",
104
+ fill: "currentColor",
105
+ strokeWidth: "0"
106
+ }, r.attr, a, h, {
107
+ className: s,
108
+ style: g(g({
109
+ color: t.color || r.color
110
+ }, r.style), t.style),
111
+ height: v,
112
+ width: v,
113
+ xmlns: "http://www.w3.org/2000/svg"
114
+ }), o && /* @__PURE__ */ l.createElement("title", null, o), t.children);
115
+ };
116
+ return p !== void 0 ? /* @__PURE__ */ l.createElement(p.Consumer, null, (r) => e(r)) : e(x);
117
+ }
118
+ function q(t) {
119
+ return i({ tag: "svg", attr: { viewBox: "0 0 24 24" }, child: [{ tag: "path", attr: { d: "M4 7h16v2H4zm0-4h16v2H4zm0 8h16v2H4zm0 4h16v2H4zm2 4h12v2H6z" }, child: [] }] })(t);
120
+ }
121
+ function F(t) {
122
+ return i({ tag: "svg", attr: { viewBox: "0 0 24 24" }, child: [{ tag: "path", attr: { d: "M4 19h16v2H4zm0-4h11v2H4zm0-4h16v2H4zm0-8h16v2H4zm0 4h11v2H4z" }, child: [] }] })(t);
123
+ }
124
+ function J(t) {
125
+ return i({ tag: "svg", attr: { viewBox: "0 0 24 24" }, child: [{ tag: "path", attr: { d: "M4 19h16v2H4zm3-4h10v2H7zm-3-4h16v2H4zm0-8h16v2H4zm3 4h10v2H7z" }, child: [] }] })(t);
126
+ }
127
+ function K(t) {
128
+ return i({ tag: "svg", attr: { viewBox: "0 0 24 24" }, child: [{ tag: "path", attr: { d: "M4 19h16v2H4zm5-4h11v2H9zm-5-4h16v2H4zm0-8h16v2H4zm5 4h11v2H9z" }, child: [] }] })(t);
129
+ }
130
+ function Q(t) {
131
+ return i({ tag: "svg", attr: { viewBox: "0 0 24 24" }, child: [{ tag: "path", attr: { d: "M17.061 11.22A4.46 4.46 0 0 0 18 8.5C18 6.019 15.981 4 13.5 4H6v15h8c2.481 0 4.5-2.019 4.5-4.5a4.48 4.48 0 0 0-1.439-3.28zM13.5 7c.827 0 1.5.673 1.5 1.5s-.673 1.5-1.5 1.5H9V7h4.5zm.5 9H9v-3h5c.827 0 1.5.673 1.5 1.5S14.827 16 14 16z" }, child: [] }] })(t);
132
+ }
133
+ function X(t) {
134
+ return i({ tag: "svg", attr: { viewBox: "0 0 24 24" }, child: [{ tag: "path", attr: { d: "M13.293 6.293 7.586 12l5.707 5.707 1.414-1.414L10.414 12l4.293-4.293z" }, child: [] }] })(t);
135
+ }
136
+ function Y(t) {
137
+ return i({ tag: "svg", attr: { viewBox: "0 0 24 24" }, child: [{ tag: "path", attr: { d: "M10.707 17.707 16.414 12l-5.707-5.707-1.414 1.414L13.586 12l-4.293 4.293z" }, child: [] }] })(t);
138
+ }
139
+ function Z(t) {
140
+ return i({ tag: "svg", attr: { viewBox: "0 0 24 24" }, child: [{ tag: "path", attr: { d: "M19 7V4H9v3h2.868L9.012 17H5v3h10v-3h-2.868l2.856-10z" }, child: [] }] })(t);
141
+ }
142
+ function $(t) {
143
+ return i({ tag: "svg", attr: { viewBox: "0 0 24 24" }, child: [{ tag: "path", attr: { d: "M8.465 11.293c1.133-1.133 3.109-1.133 4.242 0l.707.707 1.414-1.414-.707-.707c-.943-.944-2.199-1.465-3.535-1.465s-2.592.521-3.535 1.465L4.929 12a5.008 5.008 0 0 0 0 7.071 4.983 4.983 0 0 0 3.535 1.462A4.982 4.982 0 0 0 12 19.071l.707-.707-1.414-1.414-.707.707a3.007 3.007 0 0 1-4.243 0 3.005 3.005 0 0 1 0-4.243l2.122-2.121z" }, child: [] }, { tag: "path", attr: { d: "m12 4.929-.707.707 1.414 1.414.707-.707a3.007 3.007 0 0 1 4.243 0 3.005 3.005 0 0 1 0 4.243l-2.122 2.121c-1.133 1.133-3.109 1.133-4.242 0L10.586 12l-1.414 1.414.707.707c.943.944 2.199 1.465 3.535 1.465s2.592-.521 3.535-1.465L19.071 12a5.008 5.008 0 0 0 0-7.071 5.006 5.006 0 0 0-7.071 0z" }, child: [] }] })(t);
144
+ }
145
+ function tt(t) {
146
+ return i({ tag: "svg", attr: { viewBox: "0 0 24 24" }, child: [{ tag: "path", attr: { d: "M5.282 12.064c-.428.328-.72.609-.875.851-.155.24-.249.498-.279.768h2.679v-.748H5.413c.081-.081.152-.151.212-.201.062-.05.182-.142.361-.27.303-.218.511-.42.626-.604.116-.186.173-.375.173-.578a.898.898 0 0 0-.151-.512.892.892 0 0 0-.412-.341c-.174-.076-.419-.111-.733-.111-.3 0-.537.038-.706.114a.889.889 0 0 0-.396.338c-.094.143-.159.346-.194.604l.894.076c.025-.188.074-.317.147-.394a.375.375 0 0 1 .279-.108c.11 0 .2.035.272.108a.344.344 0 0 1 .108.258.55.55 0 0 1-.108.297c-.074.102-.241.254-.503.453zm.055 6.386a.398.398 0 0 1-.282-.105c-.074-.07-.128-.195-.162-.378L4 18.085c.059.204.142.372.251.506.109.133.248.235.417.306.168.069.399.103.692.103.3 0 .541-.047.725-.14a1 1 0 0 0 .424-.403c.098-.175.146-.354.146-.544a.823.823 0 0 0-.088-.393.708.708 0 0 0-.249-.261 1.015 1.015 0 0 0-.286-.11.943.943 0 0 0 .345-.299.673.673 0 0 0 .113-.383.747.747 0 0 0-.281-.596c-.187-.159-.49-.238-.909-.238-.365 0-.648.072-.847.219-.2.143-.334.353-.404.626l.844.151c.023-.162.067-.274.133-.338s.151-.098.257-.098a.33.33 0 0 1 .241.089c.059.06.087.139.087.238 0 .104-.038.193-.117.27s-.177.112-.293.112a.907.907 0 0 1-.116-.011l-.045.649a1.13 1.13 0 0 1 .289-.056c.132 0 .237.041.313.126.077.082.115.199.115.352 0 .146-.04.266-.119.354a.394.394 0 0 1-.301.134zm.948-10.083V5h-.739a1.47 1.47 0 0 1-.394.523c-.168.142-.404.262-.708.365v.754a2.595 2.595 0 0 0 .937-.48v2.206h.904zM9 6h11v2H9zm0 5h11v2H9zm0 5h11v2H9z" }, child: [] }] })(t);
147
+ }
148
+ function et(t) {
149
+ return i({ tag: "svg", attr: { viewBox: "0 0 24 24" }, child: [{ tag: "path", attr: { d: "M4 6h2v2H4zm0 5h2v2H4zm0 5h2v2H4zm16-8V6H8.023v2H18.8zM8 11h12v2H8zm0 5h12v2H8z" }, child: [] }] })(t);
150
+ }
151
+ function y(t) {
152
+ return i({ tag: "svg", attr: { viewBox: "0 0 24 24" }, child: [{ tag: "path", attr: { d: "M12 22c5.421 0 10-4.579 10-10h-2c0 4.337-3.663 8-8 8s-8-3.663-8-8c0-4.336 3.663-8 8-8V2C6.579 2 2 6.58 2 12c0 5.421 4.579 10 10 10z" }, child: [] }] })(t);
153
+ }
154
+ function rt(t) {
155
+ return i({ tag: "svg", attr: { viewBox: "0 0 24 24" }, child: [{ tag: "path", attr: { d: "M20 11h-8c-4 0-4-1.816-4-2.5C8 7.882 8 6 12 6c2.8 0 2.99 1.678 3 2.014L16 8h1c0-1.384-1.045-4-5-4-5.416 0-6 3.147-6 4.5 0 .728.148 1.667.736 2.5H4v2h16v-2zm-8 7c-3.793 0-3.99-1.815-4-2H6c0 .04.069 4 6 4 5.221 0 6-2.819 6-4.5 0-.146-.009-.317-.028-.5h-2.006c.032.2.034.376.034.5 0 .684 0 2.5-4 2.5z" }, child: [] }] })(t);
156
+ }
157
+ function at(t) {
158
+ return i({ tag: "svg", attr: { viewBox: "0 0 24 24" }, child: [{ tag: "path", attr: { d: "M5 18h14v2H5zM6 4v6c0 3.309 2.691 6 6 6s6-2.691 6-6V4h-2v6c0 2.206-1.794 4-4 4s-4-1.794-4-4V4H6z" }, child: [] }] })(t);
159
+ }
160
+ function it(t) {
161
+ return i({ tag: "svg", attr: { viewBox: "0 0 24 24" }, child: [{ tag: "path", attr: { d: "M16.949 14.121 19.071 12a5.008 5.008 0 0 0 0-7.071 5.006 5.006 0 0 0-7.071 0l-.707.707 1.414 1.414.707-.707a3.007 3.007 0 0 1 4.243 0 3.005 3.005 0 0 1 0 4.243l-2.122 2.121a2.723 2.723 0 0 1-.844.57L13.414 12l1.414-1.414-.707-.707a4.965 4.965 0 0 0-3.535-1.465c-.235 0-.464.032-.691.066L3.707 2.293 2.293 3.707l18 18 1.414-1.414-5.536-5.536c.277-.184.538-.396.778-.636zm-6.363 3.536a3.007 3.007 0 0 1-4.243 0 3.005 3.005 0 0 1 0-4.243l1.476-1.475-1.414-1.414L4.929 12a5.008 5.008 0 0 0 0 7.071 4.983 4.983 0 0 0 3.535 1.462A4.982 4.982 0 0 0 12 19.071l.707-.707-1.414-1.414-.707.707z" }, child: [] }] })(t);
162
+ }
163
+ const R = O(
164
+ "inline-flex items-center justify-center text-sm font-medium ring-offset-background transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50 disabled:cursor-not-allowed",
165
+ {
166
+ variants: {
167
+ variant: {
168
+ default: "bg-primary text-primary-foreground hover:bg-primary/90",
169
+ destructive: "bg-destructive text-destructive-foreground hover:bg-destructive/90",
170
+ outline: "border border-input bg-background hover:bg-accent hover:text-accent-foreground",
171
+ secondary: "bg-secondary text-secondary-foreground hover:bg-secondary/80",
172
+ secondaryOutline: "bg-transparent border-[1px] border-solid border-white hover:bg-white hover:border-input",
173
+ ghost: "hover:bg-accent hover:text-accent-foreground",
174
+ link: "text-primary underline-offset-4 hover:underline"
175
+ },
176
+ size: {
177
+ default: "h-10 px-4 py-2",
178
+ xs: "h-8 px-3 text-xs",
179
+ sm: "h-9 px-3",
180
+ lg: "h-11 px-8",
181
+ icon: "h-10 w-10",
182
+ "icon-small": "h-8 w-8"
183
+ },
184
+ rounded: {
185
+ small: "rounded",
186
+ default: "rounded-md",
187
+ large: "rounded-lg",
188
+ full: "rounded-full"
189
+ }
190
+ },
191
+ defaultVariants: {
192
+ variant: "default",
193
+ size: "default",
194
+ rounded: "default"
195
+ }
196
+ }
197
+ ), T = m.forwardRef(
198
+ ({
199
+ className: t,
200
+ variant: e,
201
+ size: r,
202
+ rounded: a,
203
+ asChild: n = !1,
204
+ isLoading: o = !1,
205
+ loadingText: h,
206
+ disabled: v,
207
+ ...s
208
+ }, w) => {
209
+ const H = n ? B : "button";
210
+ return /* @__PURE__ */ c.jsx(
211
+ H,
212
+ {
213
+ className: u(R({ variant: e, size: r, rounded: a, className: t })),
214
+ ref: w,
215
+ disabled: v || o,
216
+ type: "button",
217
+ ...s,
218
+ children: o ? /* @__PURE__ */ c.jsxs(c.Fragment, { children: [
219
+ /* @__PURE__ */ c.jsx(
220
+ y,
221
+ {
222
+ className: j(
223
+ "h-4 w-4 animate-spin",
224
+ h ? "mr-2" : ""
225
+ )
226
+ }
227
+ ),
228
+ h
229
+ ] }) : s.children
230
+ }
231
+ );
232
+ }
233
+ );
234
+ T.displayName = "Button";
235
+ const nt = d.Root, _ = m.forwardRef(({ className: t, ...e }, r) => /* @__PURE__ */ c.jsx(
236
+ d.List,
237
+ {
238
+ ref: r,
239
+ className: u(
240
+ "inline-flex h-10 items-center justify-center rounded-md bg-muted p-1 text-muted-foreground",
241
+ t
242
+ ),
243
+ ...e
244
+ }
245
+ ));
246
+ _.displayName = d.List.displayName;
247
+ const V = m.forwardRef(({ className: t, ...e }, r) => /* @__PURE__ */ c.jsx(
248
+ d.Trigger,
249
+ {
250
+ ref: r,
251
+ className: u(
252
+ "inline-flex items-center justify-center whitespace-nowrap rounded-sm px-3 py-1.5 text-sm font-medium ring-offset-background transition-all focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50 data-[state=active]:bg-background data-[state=active]:text-foreground data-[state=active]:shadow-sm",
253
+ t
254
+ ),
255
+ "data-levo-studio-interactive": "true",
256
+ ...e
257
+ }
258
+ ));
259
+ V.displayName = d.Trigger.displayName;
260
+ const A = m.forwardRef(({ className: t, ...e }, r) => /* @__PURE__ */ c.jsx(
261
+ d.Content,
262
+ {
263
+ ref: r,
264
+ className: u(
265
+ "mt-2 ring-offset-background focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2",
266
+ t
267
+ ),
268
+ ...e
269
+ }
270
+ ));
271
+ A.displayName = d.Content.displayName;
272
+ const ot = ({ className: t }) => /* @__PURE__ */ c.jsx(y, { className: u("h-8 w-8 animate-spin font-light", t) });
273
+ export {
274
+ T as B,
275
+ i as G,
276
+ ot as S,
277
+ nt as T,
278
+ _ as a,
279
+ R as b,
280
+ V as c,
281
+ A as d,
282
+ Q as e,
283
+ Z as f,
284
+ at as g,
285
+ rt as h,
286
+ et as i,
287
+ tt as j,
288
+ $ as k,
289
+ it as l,
290
+ F as m,
291
+ J as n,
292
+ K as o,
293
+ q as p,
294
+ y as q,
295
+ X as r,
296
+ Y as s
297
+ };
@@ -0,0 +1,137 @@
1
+ "use client";
2
+ import { j as t } from "./jsx-runtime-B6kdoens.js";
3
+ import { useState as A, useMemo as v } from "react";
4
+ import { FormProvider as I } from "react-hook-form";
5
+ import { m as N, F as T } from "./CollectionFormBuilder-jwwjyIpv.js";
6
+ import { u as H, S as M } from "./useLevoForm-BcN8f66y.js";
7
+ import { c as g } from "./cn-C9QoOYNG.js";
8
+ import { B as y } from "./Spinner-CuUosd-S.js";
9
+ const X = () => {
10
+ const [n, l] = A(0), { containerStyles: m } = N(), a = () => {
11
+ l((o) => o - 1);
12
+ }, s = () => {
13
+ l((o) => o + 1);
14
+ }, d = (o) => {
15
+ l(o);
16
+ };
17
+ return /* @__PURE__ */ t.jsx("div", { className: g("w-full", m), children: /* @__PURE__ */ t.jsx(
18
+ q,
19
+ {
20
+ currentSectionIndex: n,
21
+ handleNext: s,
22
+ handlePrev: a,
23
+ goToIndex: d
24
+ }
25
+ ) });
26
+ }, q = ({ currentSectionIndex: n, handleNext: l, handlePrev: m, goToIndex: a }) => {
27
+ var f, j, h;
28
+ const { schema: s, isInternal: d, isDisabled: o, submitButtonConfig: i, uiConfig: c } = N(), r = v(
29
+ () => {
30
+ var e;
31
+ return (e = s == null ? void 0 : s.sections) == null ? void 0 : e[n];
32
+ },
33
+ [n]
34
+ ), F = v(() => {
35
+ if (s) {
36
+ const e = { ...s };
37
+ return r && e && (e.sections = [r]), e;
38
+ }
39
+ return null;
40
+ }, [r]), u = n === Number((f = s == null ? void 0 : s.sections) == null ? void 0 : f.length) - 1, {
41
+ methods: p,
42
+ handleSubmit: w,
43
+ isLoading: E,
44
+ handleContentId: L,
45
+ isError: P,
46
+ allFormValues: k
47
+ } = H({
48
+ schema: F,
49
+ saveToRemote: u,
50
+ onSubmit: () => {
51
+ l();
52
+ },
53
+ onSubmitSuccess: () => {
54
+ a(0);
55
+ },
56
+ onSubmitError: (e) => {
57
+ var S;
58
+ if (Array.isArray(e) && (e != null && e[0])) {
59
+ const R = e == null ? void 0 : e[0];
60
+ (S = s == null ? void 0 : s.sections) == null || S.forEach((x, V) => {
61
+ var b;
62
+ ((b = x == null ? void 0 : x.fields) == null ? void 0 : b.find((z) => z.key === R.param)) && a(V);
63
+ });
64
+ }
65
+ }
66
+ }), {
67
+ formState: { isSubmitting: D }
68
+ } = p;
69
+ return /* @__PURE__ */ t.jsxs(I, { ...p, children: [
70
+ /* @__PURE__ */ t.jsx(
71
+ M,
72
+ {
73
+ getContentId: (e) => L(e),
74
+ isError: P,
75
+ currentValues: k
76
+ }
77
+ ),
78
+ /* @__PURE__ */ t.jsxs(
79
+ "form",
80
+ {
81
+ className: g(
82
+ "w-full bg-white rounded-md border border-[rgb(229, 231, 235)] min-h-12 px-4 md:px-8 py-6",
83
+ E && "opacity-50 pointer-events-none"
84
+ ),
85
+ id: "collection-form",
86
+ onSubmit: w,
87
+ children: [
88
+ !(c != null && c.hideSectionHeadings) && /* @__PURE__ */ t.jsxs("div", { className: "flex items-center justify-between mb-6", children: [
89
+ /* @__PURE__ */ t.jsx("p", { className: "text-xl font-medium", children: (r == null ? void 0 : r.label) || "Details" }),
90
+ /* @__PURE__ */ t.jsxs("p", { children: [
91
+ "Step ",
92
+ n + 1,
93
+ "/",
94
+ ((j = s == null ? void 0 : s.sections) == null ? void 0 : j.length) || 1
95
+ ] })
96
+ ] }),
97
+ /* @__PURE__ */ t.jsx("div", { className: "w-full flex flex-col gap-6", children: (h = r == null ? void 0 : r.fields) == null ? void 0 : h.map((e) => e && !e.hidden ? /* @__PURE__ */ t.jsx(
98
+ T,
99
+ {
100
+ field: e,
101
+ isInternal: d
102
+ },
103
+ e == null ? void 0 : e.key
104
+ ) : null) }),
105
+ /* @__PURE__ */ t.jsxs("div", { className: "flex mt-8 justify-between", children: [
106
+ n !== 0 ? /* @__PURE__ */ t.jsx(
107
+ y,
108
+ {
109
+ type: "button",
110
+ size: "sm",
111
+ onClick: () => {
112
+ m();
113
+ },
114
+ children: "Prev"
115
+ }
116
+ ) : /* @__PURE__ */ t.jsx("div", {}),
117
+ /* @__PURE__ */ t.jsx(
118
+ y,
119
+ {
120
+ type: "submit",
121
+ loadingText: "Saving",
122
+ size: "sm",
123
+ isLoading: D,
124
+ disabled: o,
125
+ className: i == null ? void 0 : i.styles,
126
+ children: u ? (i == null ? void 0 : i.text) ?? "Save" : "Next"
127
+ }
128
+ )
129
+ ] })
130
+ ]
131
+ }
132
+ )
133
+ ] });
134
+ };
135
+ export {
136
+ X as default
137
+ };
@@ -0,0 +1,53 @@
1
+ "use client";
2
+ import { j as r } from "./jsx-runtime-B6kdoens.js";
3
+ import { useController as k } from "react-hook-form";
4
+ import { h as w, j, k as v } from "./CollectionFormBuilder-jwwjyIpv.js";
5
+ import * as c from "@radix-ui/react-switch";
6
+ import * as y from "react";
7
+ import { c as d } from "./cn-C9QoOYNG.js";
8
+ const m = y.forwardRef(({ className: e, ...t }, s) => /* @__PURE__ */ r.jsx(
9
+ c.Root,
10
+ {
11
+ className: d(
12
+ "peer inline-flex h-6 w-11 shrink-0 cursor-pointer items-center rounded-full border-2 border-transparent transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 focus-visible:ring-offset-background disabled:cursor-not-allowed disabled:opacity-50 data-[state=checked]:bg-primary data-[state=unchecked]:bg-input",
13
+ e
14
+ ),
15
+ ...t,
16
+ ref: s,
17
+ children: /* @__PURE__ */ r.jsx(
18
+ c.Thumb,
19
+ {
20
+ className: d(
21
+ "pointer-events-none block h-5 w-5 rounded-full bg-background shadow-lg ring-0 transition-transform data-[state=checked]:translate-x-5 data-[state=unchecked]:translate-x-0"
22
+ )
23
+ }
24
+ )
25
+ }
26
+ ));
27
+ m.displayName = c.Root.displayName;
28
+ const C = ({ field: e }) => {
29
+ var l;
30
+ const { key: t = "", label: s = "", helper_text: u = "", readonly: h = !1 } = e, o = t, {
31
+ field: { value: p, onBlur: a, onChange: i, ...b },
32
+ fieldState: n
33
+ } = k({
34
+ name: o,
35
+ rules: w(e)
36
+ }), f = !!(e != null && e.required), x = (l = n == null ? void 0 : n.error) == null ? void 0 : l.message;
37
+ return /* @__PURE__ */ r.jsx(j, { error: x, helperText: u, readOnly: h, children: /* @__PURE__ */ r.jsxs("div", { className: "w-full flex items-center justify-between max-w-[300px]", children: [
38
+ s && /* @__PURE__ */ r.jsx(v, { htmlFor: o, isRequired: f, className: "!mb-0", children: s }),
39
+ /* @__PURE__ */ r.jsx(
40
+ m,
41
+ {
42
+ id: o,
43
+ checked: p,
44
+ onCheckedChange: (g) => i == null ? void 0 : i(g),
45
+ onBlur: () => a == null ? void 0 : a(),
46
+ ...b
47
+ }
48
+ )
49
+ ] }) });
50
+ };
51
+ export {
52
+ C as default
53
+ };
@@ -0,0 +1,33 @@
1
+ import { j as t } from "./jsx-runtime-B6kdoens.js";
2
+ import { useFormContext as j, get as g } from "react-hook-form";
3
+ import { j as h, k as F, l as b } from "./CollectionFormBuilder-jwwjyIpv.js";
4
+ import { I as y } from "./Input-2CvZ90f8.js";
5
+ import { c as f } from "./cn-C9QoOYNG.js";
6
+ const W = ({
7
+ field: r,
8
+ inputStyles: a,
9
+ ...m
10
+ }) => {
11
+ var o;
12
+ const {
13
+ register: n,
14
+ formState: { errors: i, disabled: l }
15
+ } = j(), { key: p = "", label: s = "", helper_text: c = "", readonly: x = !1 } = r, e = p, d = !!(r != null && r.required), u = (o = g(i, e)) == null ? void 0 : o.message;
16
+ return /* @__PURE__ */ t.jsxs(h, { error: u, helperText: c, children: [
17
+ s && /* @__PURE__ */ t.jsx(F, { htmlFor: e, isRequired: d, children: s }),
18
+ /* @__PURE__ */ t.jsx(
19
+ y,
20
+ {
21
+ id: e,
22
+ className: f(a),
23
+ readOnly: x,
24
+ disabled: l,
25
+ ...n(e, { ...b(r) }),
26
+ ...m
27
+ }
28
+ )
29
+ ] });
30
+ };
31
+ export {
32
+ W as default
33
+ };
@@ -0,0 +1,30 @@
1
+ import { j as s } from "./jsx-runtime-B6kdoens.js";
2
+ import { useFormContext as u, get as x } from "react-hook-form";
3
+ import { j as b, k as g, h } from "./CollectionFormBuilder-jwwjyIpv.js";
4
+ import { c as f } from "./cn-C9QoOYNG.js";
5
+ const w = ({ field: e }) => {
6
+ var a;
7
+ const {
8
+ register: i,
9
+ formState: { errors: n, disabled: l }
10
+ } = u(), { key: d = "", label: o = "", helper_text: m = "", readonly: t = !1 } = e, r = d, c = !!(e != null && e.required), p = (a = x(n, r)) == null ? void 0 : a.message;
11
+ return /* @__PURE__ */ s.jsxs(b, { error: p, helperText: m, children: [
12
+ o && /* @__PURE__ */ s.jsx(g, { htmlFor: r, isRequired: c, children: o }),
13
+ /* @__PURE__ */ s.jsx(
14
+ "textarea",
15
+ {
16
+ id: r,
17
+ className: f(
18
+ "flex min-h-[60px] w-full rounded-md border border-input bg-transparent px-3 py-2 text-sm shadow-sm placeholder:text-muted-foreground focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring disabled:cursor-not-allowed disabled:opacity-50",
19
+ t && "focus-visible:ring-0"
20
+ ),
21
+ readOnly: t,
22
+ disabled: l,
23
+ ...i(r, h(e))
24
+ }
25
+ )
26
+ ] });
27
+ };
28
+ export {
29
+ w as default
30
+ };
@@ -0,0 +1,44 @@
1
+ "use client";
2
+ import { j as r } from "./jsx-runtime-B6kdoens.js";
3
+ import { useController as p } from "react-hook-form";
4
+ import { h as u, j as g, k as j } from "./CollectionFormBuilder-jwwjyIpv.js";
5
+ import { C } from "./Checbox-sq-atGlJ.js";
6
+ const y = ({
7
+ field: e
8
+ }) => {
9
+ const { key: l = "", label: o = "", helper_text: t = "", readonly: n = !1 } = e, {
10
+ field: { name: s, onBlur: i, onChange: m, ref: d, value: c, disabled: h },
11
+ fieldState: { error: a }
12
+ } = p({
13
+ name: l,
14
+ rules: u(e)
15
+ });
16
+ return /* @__PURE__ */ r.jsx(
17
+ g,
18
+ {
19
+ error: a == null ? void 0 : a.message,
20
+ helperText: t,
21
+ readOnly: n,
22
+ children: /* @__PURE__ */ r.jsxs("div", { className: "w-full flex gap-2 items-start flex-nowrap", ref: d, children: [
23
+ /* @__PURE__ */ r.jsx(
24
+ C,
25
+ {
26
+ id: s,
27
+ name: s,
28
+ checked: c,
29
+ onCheckedChange: (x) => m(x),
30
+ onBlur: () => {
31
+ i();
32
+ },
33
+ disabled: h
34
+ }
35
+ ),
36
+ o && /* @__PURE__ */ r.jsx(j, { htmlFor: s, isRequired: e == null ? void 0 : e.required, children: o })
37
+ ] })
38
+ }
39
+ );
40
+ };
41
+ export {
42
+ y as ToggleCheckboxWidget,
43
+ y as default
44
+ };