@levo-so/react 0.1.18 → 0.1.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 (47) hide show
  1. package/dist/{CheckboxWidget-Dp9IAz5Q.js → CheckboxWidget-nJO8XlGD.js} +1 -1
  2. package/dist/{CollectionFormBuilder-DpTePTDd.js → CollectionFormBuilder-DeGyMEXJ.js} +162 -166
  3. package/dist/{CurrencyWidget-BfnmQP9S.js → CurrencyWidget-BaMho9Pw.js} +1 -1
  4. package/dist/{DateTimeWidget-CqjC2iYx.js → DateTimeWidget-VCmX__cv.js} +1 -1
  5. package/dist/{DefaultFormVariant-CG7WUPV3.js → DefaultFormVariant-fTWKRYI_.js} +7 -7
  6. package/dist/{DropdownWidget-15oYGYnv.js → DropdownWidget-zAr9v_IY.js} +18 -18
  7. package/dist/{EmailWidget-mGeLzigY.js → EmailWidget-d3hSxbAS.js} +2 -2
  8. package/dist/{FormCaptcha-CbLdFHHY.js → FormCaptcha-YeElu90S.js} +16 -16
  9. package/dist/{GeocoderWidget-BXv8P8Y1.js → GeocoderWidget-BOqaJMm1.js} +2 -2
  10. package/dist/{MultiGeocoderWidget-eCOGwc1m.js → MultiGeocoderWidget-BTffSkJX.js} +3 -3
  11. package/dist/{MultiTextWidget-DpT1gLmr.js → MultiTextWidget-L2Eoz2Zv.js} +1 -1
  12. package/dist/{PhoneWidget-DisB02Ll.js → PhoneWidget-CnDhiovx.js} +1 -1
  13. package/dist/{RadioWidget-DjWXEZQx.js → RadioWidget-CG01ys9E.js} +2 -2
  14. package/dist/{RichTextWidget-BnqTjA-v.js → RichTextWidget-DCX1Vpw4.js} +2 -2
  15. package/dist/{Spinner-Bzu2xCFZ.js → Spinner-BnrQ9e_i.js} +58 -57
  16. package/dist/{StepsFormVariant-BYzPBT2c.js → StepsFormVariant-eW9O8rik.js} +22 -22
  17. package/dist/{SwitchWidget-DQ2OHpuP.js → SwitchWidget-CstjQ_nx.js} +1 -1
  18. package/dist/{TextWidget-qHY9_hkz.js → TextWidget-D4uLMuLS.js} +1 -1
  19. package/dist/{TextareaWidget-BP5mJR7j.js → TextareaWidget-CHgyJUuy.js} +1 -1
  20. package/dist/{ToggleCheckboxWidget-CzXZ9l_k.js → ToggleCheckboxWidget-Cfwlrjn7.js} +1 -1
  21. package/dist/{Tooltip-DEBnSqlo.js → Tooltip-DPzkfrjl.js} +15 -14
  22. package/dist/{URLWidget-BcZQVzW7.js → URLWidget-CZE68DgS.js} +2 -2
  23. package/dist/UploadWidget-Dstuk_qo.js +656 -0
  24. package/dist/audience/components/page.d.ts.map +1 -1
  25. package/dist/audience/index.js +1 -1
  26. package/dist/collection/components/widgets/collectionWidget/CollectionWidgetM2M.d.ts.map +1 -1
  27. package/dist/collection/components/widgets/uploadWidget/CommonPreview.d.ts +11 -0
  28. package/dist/collection/components/widgets/uploadWidget/CommonPreview.d.ts.map +1 -0
  29. package/dist/collection/components/widgets/uploadWidget/ExternalURL.d.ts.map +1 -1
  30. package/dist/collection/components/widgets/uploadWidget/FileUploadDropBox.d.ts.map +1 -1
  31. package/dist/collection/components/widgets/uploadWidget/FileUploadModal.d.ts.map +1 -1
  32. package/dist/collection/components/widgets/uploadWidget/UploadWidget.d.ts.map +1 -1
  33. package/dist/collection/index.js +1 -1
  34. package/dist/components/Dialog.d.ts +3 -1
  35. package/dist/components/Dialog.d.ts.map +1 -1
  36. package/dist/components/Sonner.d.ts +1 -1
  37. package/dist/components/Sonner.d.ts.map +1 -1
  38. package/dist/components/Tooltip.d.ts +1 -0
  39. package/dist/components/Tooltip.d.ts.map +1 -1
  40. package/dist/components/index.js +29 -28
  41. package/dist/index.css +1 -1
  42. package/dist/index.js +50 -49
  43. package/dist/membership/components/Popup.d.ts.map +1 -1
  44. package/dist/page-sR2SWtb2.js +189 -0
  45. package/package.json +4 -4
  46. package/dist/UploadWidget-BNdydN68.js +0 -616
  47. package/dist/page-BKyDlf0z.js +0 -212
@@ -3,13 +3,13 @@ import { j as t } from "./jsx-runtime-B6kdoens.js";
3
3
  import { useState as I, useMemo as y } from "react";
4
4
  import { FormProvider as T } from "react-hook-form";
5
5
  import { c as F } from "./cn-C9QoOYNG.js";
6
- import { D as N, F as _ } from "./CollectionFormBuilder-DpTePTDd.js";
7
- import { u as C, S as H, F as M } from "./FormCaptcha-CbLdFHHY.js";
8
- import { B as g } from "./Spinner-Bzu2xCFZ.js";
6
+ import { D as N, F as _ } from "./CollectionFormBuilder-DeGyMEXJ.js";
7
+ import { u as C, S as H, F as M } from "./FormCaptcha-YeElu90S.js";
8
+ import { B as g } from "./Spinner-BnrQ9e_i.js";
9
9
  const Y = () => {
10
10
  const [n, a] = I(0), { containerStyles: m } = N(), l = () => {
11
11
  a((o) => o - 1);
12
- }, s = () => {
12
+ }, e = () => {
13
13
  a((o) => o + 1);
14
14
  }, c = (o) => {
15
15
  a(o);
@@ -18,26 +18,26 @@ const Y = () => {
18
18
  q,
19
19
  {
20
20
  currentSectionIndex: n,
21
- handleNext: s,
21
+ handleNext: e,
22
22
  handlePrev: l,
23
23
  goToIndex: c
24
24
  }
25
25
  ) });
26
26
  }, q = ({ currentSectionIndex: n, handleNext: a, handlePrev: m, goToIndex: l }) => {
27
27
  var h, j, v;
28
- const { schema: s, isInternal: c, isDisabled: o, submitButtonConfig: i, uiConfig: d } = N(), r = y(
28
+ const { schema: e, isInternal: c, isDisabled: o, submitButtonConfig: i, uiConfig: d } = N(), r = y(
29
29
  () => {
30
- var e;
31
- return (e = s == null ? void 0 : s.sections) == null ? void 0 : e[n];
30
+ var s;
31
+ return (s = e == null ? void 0 : e.sections) == null ? void 0 : s[n];
32
32
  },
33
33
  [n]
34
34
  ), w = y(() => {
35
- if (s) {
36
- const e = { ...s };
37
- return r && e && (e.sections = [r]), e;
35
+ if (e) {
36
+ const s = { ...e };
37
+ return r && s && (s.sections = [r]), s;
38
38
  }
39
39
  return null;
40
- }, [r]), x = n === Number((h = s == null ? void 0 : s.sections) == null ? void 0 : h.length) - 1, {
40
+ }, [r]), x = n === Number((h = e == null ? void 0 : e.sections) == null ? void 0 : h.length) - 1, {
41
41
  methods: u,
42
42
  handleSubmit: E,
43
43
  isLoading: L,
@@ -53,11 +53,11 @@ const Y = () => {
53
53
  onSubmitSuccess: () => {
54
54
  l(0);
55
55
  },
56
- onSubmitError: (e) => {
56
+ onSubmitError: (s) => {
57
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((p, z) => {
58
+ if (Array.isArray(s) && (s != null && s[0])) {
59
+ const R = s == null ? void 0 : s[0];
60
+ (S = e == null ? void 0 : e.sections) == null || S.forEach((p, z) => {
61
61
  var b;
62
62
  ((b = p == null ? void 0 : p.fields) == null ? void 0 : b.find((A) => A.key === R.param)) && l(z);
63
63
  });
@@ -70,7 +70,7 @@ const Y = () => {
70
70
  /* @__PURE__ */ t.jsx(
71
71
  H,
72
72
  {
73
- getContentId: (e) => D(e),
73
+ getContentId: (s) => D(s),
74
74
  isError: P,
75
75
  currentValues: V
76
76
  }
@@ -79,7 +79,7 @@ const Y = () => {
79
79
  "form",
80
80
  {
81
81
  className: F(
82
- "w-full bg-white rounded-md border border-[rgb(229, 231, 235)] min-h-12 px-4 md:px-8 py-6",
82
+ "w-full rounded-md border border-[rgb(229, 231, 235)] min-h-12 px-4 md:px-8 py-6",
83
83
  L && "opacity-50 pointer-events-none"
84
84
  ),
85
85
  id: "collection-form",
@@ -91,17 +91,17 @@ const Y = () => {
91
91
  "Step ",
92
92
  n + 1,
93
93
  "/",
94
- ((j = s == null ? void 0 : s.sections) == null ? void 0 : j.length) || 1
94
+ ((j = e == null ? void 0 : e.sections) == null ? void 0 : j.length) || 1
95
95
  ] })
96
96
  ] }),
97
97
  /* @__PURE__ */ t.jsxs("div", { className: "w-full flex flex-col gap-6", children: [
98
- (v = r == null ? void 0 : r.fields) == null ? void 0 : v.map((e) => e && !e.hidden ? /* @__PURE__ */ t.jsx(
98
+ (v = r == null ? void 0 : r.fields) == null ? void 0 : v.map((s) => s && !s.hidden ? /* @__PURE__ */ t.jsx(
99
99
  _,
100
100
  {
101
- field: e,
101
+ field: s,
102
102
  isInternal: c
103
103
  },
104
- e == null ? void 0 : e.key
104
+ s == null ? void 0 : s.key
105
105
  ) : null),
106
106
  !c && x && /* @__PURE__ */ t.jsx(M, {})
107
107
  ] }),
@@ -1,7 +1,7 @@
1
1
  "use client";
2
2
  import { j as r } from "./jsx-runtime-B6kdoens.js";
3
3
  import { useController as k } from "react-hook-form";
4
- import { z as w, A as j, B as v } from "./CollectionFormBuilder-DpTePTDd.js";
4
+ import { z as w, A as j, B as v } from "./CollectionFormBuilder-DeGyMEXJ.js";
5
5
  import * as c from "@radix-ui/react-switch";
6
6
  import * as y from "react";
7
7
  import { c as d } from "./cn-C9QoOYNG.js";
@@ -1,7 +1,7 @@
1
1
  import { j as t } from "./jsx-runtime-B6kdoens.js";
2
2
  import { useFormContext as g, get as h } from "react-hook-form";
3
3
  import { c as j } from "./cn-C9QoOYNG.js";
4
- import { A as F, B as b, z as y } from "./CollectionFormBuilder-DpTePTDd.js";
4
+ import { A as F, B as b, z as y } from "./CollectionFormBuilder-DeGyMEXJ.js";
5
5
  import { I as f } from "./Input-2CvZ90f8.js";
6
6
  const k = ({
7
7
  field: r,
@@ -1,7 +1,7 @@
1
1
  import { j as s } from "./jsx-runtime-B6kdoens.js";
2
2
  import { useFormContext as u, get as x } from "react-hook-form";
3
3
  import { c as b } from "./cn-C9QoOYNG.js";
4
- import { A as g, B as f, z as h } from "./CollectionFormBuilder-DpTePTDd.js";
4
+ import { A as g, B as f, z as h } from "./CollectionFormBuilder-DeGyMEXJ.js";
5
5
  const w = ({ field: e }) => {
6
6
  var a;
7
7
  const {
@@ -1,7 +1,7 @@
1
1
  "use client";
2
2
  import { j as r } from "./jsx-runtime-B6kdoens.js";
3
3
  import { useController as p } from "react-hook-form";
4
- import { z as u, A as g, B as C } from "./CollectionFormBuilder-DpTePTDd.js";
4
+ import { z as u, A as g, B as C } from "./CollectionFormBuilder-DeGyMEXJ.js";
5
5
  import { C as f } from "./Checbox-sq-atGlJ.js";
6
6
  const y = ({
7
7
  field: e
@@ -1,14 +1,14 @@
1
1
  "use client";
2
2
  import { j as t } from "./jsx-runtime-B6kdoens.js";
3
3
  import * as o from "@radix-ui/react-tooltip";
4
- import * as n from "react";
5
- import { c as m } from "./cn-C9QoOYNG.js";
6
- const x = o.Provider, l = o.Root, p = o.Trigger, T = o.Portal, r = n.forwardRef(({ className: a, sideOffset: e = 4, ...s }, i) => /* @__PURE__ */ t.jsx(
4
+ import * as m from "react";
5
+ import { c as l } from "./cn-C9QoOYNG.js";
6
+ const T = o.Provider, p = o.Root, c = o.Trigger, u = o.Portal, r = m.forwardRef(({ className: a, sideOffset: e = 4, ...s }, i) => /* @__PURE__ */ t.jsx(
7
7
  o.Content,
8
8
  {
9
9
  ref: i,
10
10
  sideOffset: e,
11
- className: m(
11
+ className: l(
12
12
  "z-50 overflow-hidden rounded-md border bg-popover px-3 py-1.5 text-xs text-popover-foreground shadow-md animate-in fade-in-0 zoom-in-95 data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2",
13
13
  a
14
14
  ),
@@ -16,21 +16,22 @@ const x = o.Provider, l = o.Root, p = o.Trigger, T = o.Portal, r = n.forwardRef(
16
16
  }
17
17
  ));
18
18
  r.displayName = o.Content.displayName;
19
- const u = ({
19
+ const g = ({
20
20
  children: a,
21
21
  label: e,
22
22
  labelClassName: s,
23
23
  contentClassName: i,
24
- asChild: d = !0
25
- }) => /* @__PURE__ */ t.jsxs(l, { children: [
26
- e && /* @__PURE__ */ t.jsx(r, { className: s, children: /* @__PURE__ */ t.jsx("p", { className: i, children: e }) }),
27
- /* @__PURE__ */ t.jsx(p, { asChild: d, children: a })
24
+ asChild: d = !0,
25
+ contentProps: n = {}
26
+ }) => /* @__PURE__ */ t.jsxs(p, { children: [
27
+ e && /* @__PURE__ */ t.jsx(r, { className: s, ...n, children: /* @__PURE__ */ t.jsx("p", { className: i, children: e }) }),
28
+ /* @__PURE__ */ t.jsx(c, { asChild: d, children: a })
28
29
  ] });
29
30
  export {
30
- u as S,
31
- l as T,
32
- p as a,
31
+ g as S,
32
+ p as T,
33
+ c as a,
33
34
  r as b,
34
- x as c,
35
- T as d
35
+ T as c,
36
+ u as d
36
37
  };
@@ -1,6 +1,6 @@
1
1
  import { j as e } from "./jsx-runtime-B6kdoens.js";
2
- import { H as s } from "./CollectionFormBuilder-DpTePTDd.js";
3
- import r from "./TextWidget-qHY9_hkz.js";
2
+ import { H as s } from "./CollectionFormBuilder-DeGyMEXJ.js";
3
+ import r from "./TextWidget-D4uLMuLS.js";
4
4
  const a = (t) => /* @__PURE__ */ e.jsx(
5
5
  r,
6
6
  {