@levo-so/react 0.1.22 → 0.1.24
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.
- package/dist/{CheckboxWidget-nJO8XlGD.js → CheckboxWidget-DZIHdYf_.js} +1 -1
- package/dist/{CollectionFormBuilder-DeGyMEXJ.js → CollectionFormBuilder-C9clUECd.js} +18 -18
- package/dist/{CurrencyWidget-BaMho9Pw.js → CurrencyWidget-BPjhIZC3.js} +1 -1
- package/dist/{DateTimeWidget-VCmX__cv.js → DateTimeWidget-BHPInVmB.js} +1 -1
- package/dist/{DefaultFormVariant-fTWKRYI_.js → DefaultFormVariant-DfM-Rnjm.js} +3 -3
- package/dist/{DropdownWidget-zAr9v_IY.js → DropdownWidget-C0XD8XNO.js} +1 -1
- package/dist/{EmailWidget-d3hSxbAS.js → EmailWidget-lfSEQ6Pw.js} +1 -1
- package/dist/{FormCaptcha-YeElu90S.js → FormCaptcha-QTqyITqd.js} +1 -1
- package/dist/{GeocoderWidget-BOqaJMm1.js → GeocoderWidget-PKGgCyAq.js} +7 -7
- package/dist/{MultiGeocoderWidget-BTffSkJX.js → MultiGeocoderWidget-B6tJY_NH.js} +2 -2
- package/dist/{MultiTextWidget-L2Eoz2Zv.js → MultiTextWidget-BSlDBIxt.js} +1 -1
- package/dist/{PhoneWidget-CnDhiovx.js → PhoneWidget-CZ613uWl.js} +1 -1
- package/dist/{RadioWidget-CG01ys9E.js → RadioWidget-q0_ddtou.js} +1 -1
- package/dist/{RichTextWidget-DCX1Vpw4.js → RichTextWidget-D2D9-g4e.js} +1 -1
- package/dist/{StepsFormVariant-eW9O8rik.js → StepsFormVariant-eQuIooBH.js} +21 -21
- package/dist/{SwitchWidget-CstjQ_nx.js → SwitchWidget-DJJNsK2d.js} +1 -1
- package/dist/{TextWidget-D4uLMuLS.js → TextWidget-BUKw__Xy.js} +1 -1
- package/dist/{TextareaWidget-CHgyJUuy.js → TextareaWidget-CImcGtRi.js} +1 -1
- package/dist/{ToggleCheckboxWidget-Cfwlrjn7.js → ToggleCheckboxWidget-BHJmd8lZ.js} +1 -1
- package/dist/{URLWidget-CZE68DgS.js → URLWidget-HUj8G1oS.js} +2 -2
- package/dist/{UploadWidget-Dstuk_qo.js → UploadWidget-Bzamcq6F.js} +1 -1
- package/dist/collection/index.js +1 -1
- package/dist/index.js +1 -1
- package/package.json +4 -4
|
@@ -3,7 +3,7 @@ import { j as a } from "./jsx-runtime-B6kdoens.js";
|
|
|
3
3
|
import { useState as w, useEffect as B } from "react";
|
|
4
4
|
import { useController as E } from "react-hook-form";
|
|
5
5
|
import { c as C } from "./cn-C9QoOYNG.js";
|
|
6
|
-
import { z as O, A as I, B as x } from "./CollectionFormBuilder-
|
|
6
|
+
import { z as O, A as I, B as x } from "./CollectionFormBuilder-C9clUECd.js";
|
|
7
7
|
import { C as g } from "./Checbox-sq-atGlJ.js";
|
|
8
8
|
import { I as S } from "./Input-2CvZ90f8.js";
|
|
9
9
|
const L = ({ field: i }) => {
|
|
@@ -247,7 +247,7 @@ const q = ({
|
|
|
247
247
|
"label",
|
|
248
248
|
{
|
|
249
249
|
className: b(
|
|
250
|
-
"block text-sm font-medium leading-normal peer-disabled:cursor-not-allowed peer-disabled:opacity-70 select-none flex-1",
|
|
250
|
+
"block text-sm font-medium leading-normal peer-disabled:cursor-not-allowed peer-disabled:opacity-70 select-none flex-1 text-text-1",
|
|
251
251
|
"mb-2",
|
|
252
252
|
t
|
|
253
253
|
),
|
|
@@ -915,26 +915,26 @@ const dt = E.lazy(
|
|
|
915
915
|
}
|
|
916
916
|
);
|
|
917
917
|
}, pt = v(
|
|
918
|
-
() => import("./MultiTextWidget-
|
|
919
|
-
), ie = v(() => import("./TextWidget-
|
|
920
|
-
() => import("./CurrencyWidget-
|
|
918
|
+
() => import("./MultiTextWidget-BSlDBIxt.js")
|
|
919
|
+
), ie = v(() => import("./TextWidget-BUKw__Xy.js")), xt = v(
|
|
920
|
+
() => import("./CurrencyWidget-BPjhIZC3.js")
|
|
921
921
|
), ht = v(
|
|
922
|
-
() => import("./CheckboxWidget-
|
|
922
|
+
() => import("./CheckboxWidget-DZIHdYf_.js")
|
|
923
923
|
), ce = v(
|
|
924
|
-
() => import("./DateTimeWidget-
|
|
924
|
+
() => import("./DateTimeWidget-BHPInVmB.js")
|
|
925
925
|
), de = v(
|
|
926
|
-
() => import("./DropdownWidget-
|
|
927
|
-
), yt = v(() => import("./EmailWidget-
|
|
928
|
-
() => import("./GeocoderWidget-
|
|
926
|
+
() => import("./DropdownWidget-C0XD8XNO.js")
|
|
927
|
+
), yt = v(() => import("./EmailWidget-lfSEQ6Pw.js")), ft = v(
|
|
928
|
+
() => import("./GeocoderWidget-PKGgCyAq.js")
|
|
929
929
|
), jt = v(
|
|
930
|
-
() => import("./MultiGeocoderWidget-
|
|
931
|
-
), bt = v(() => import("./PhoneWidget-
|
|
932
|
-
() => import("./RichTextWidget-
|
|
933
|
-
), wt = v(() => import("./SwitchWidget-
|
|
934
|
-
() => import("./TextareaWidget-
|
|
930
|
+
() => import("./MultiGeocoderWidget-B6tJY_NH.js")
|
|
931
|
+
), bt = v(() => import("./PhoneWidget-CZ613uWl.js")), vt = v(() => import("./RadioWidget-q0_ddtou.js")), Ct = v(
|
|
932
|
+
() => import("./RichTextWidget-D2D9-g4e.js")
|
|
933
|
+
), wt = v(() => import("./SwitchWidget-DJJNsK2d.js")), kt = v(
|
|
934
|
+
() => import("./TextareaWidget-CImcGtRi.js")
|
|
935
935
|
), Wt = v(
|
|
936
|
-
() => import("./ToggleCheckboxWidget-
|
|
937
|
-
), _t = v(() => import("./URLWidget-
|
|
936
|
+
() => import("./ToggleCheckboxWidget-BHJmd8lZ.js")
|
|
937
|
+
), _t = v(() => import("./URLWidget-HUj8G1oS.js")), K = v(() => import("./UploadWidget-Bzamcq6F.js")), Nt = ({
|
|
938
938
|
field: e,
|
|
939
939
|
isInternal: n
|
|
940
940
|
}) => {
|
|
@@ -1103,9 +1103,9 @@ const dt = E.lazy(
|
|
|
1103
1103
|
e
|
|
1104
1104
|
] });
|
|
1105
1105
|
}, ns = () => E.useContext(Ce), Tt = E.lazy(
|
|
1106
|
-
() => import("./DefaultFormVariant-
|
|
1106
|
+
() => import("./DefaultFormVariant-DfM-Rnjm.js")
|
|
1107
1107
|
), Mt = E.lazy(
|
|
1108
|
-
() => import("./StepsFormVariant-
|
|
1108
|
+
() => import("./StepsFormVariant-eQuIooBH.js")
|
|
1109
1109
|
), It = ({
|
|
1110
1110
|
formVariant: e,
|
|
1111
1111
|
...n
|
|
@@ -2,7 +2,7 @@ import { j as t } from "./jsx-runtime-B6kdoens.js";
|
|
|
2
2
|
import { useController as j } from "react-hook-form";
|
|
3
3
|
import { NumericFormat as F } from "react-number-format";
|
|
4
4
|
import { c as w } from "./cn-C9QoOYNG.js";
|
|
5
|
-
import { z as C, A as B, B as N } from "./CollectionFormBuilder-
|
|
5
|
+
import { z as C, A as B, B as N } from "./CollectionFormBuilder-C9clUECd.js";
|
|
6
6
|
const V = ({
|
|
7
7
|
field: r,
|
|
8
8
|
...m
|
|
@@ -4,7 +4,7 @@ import { Calendar as w, X as N } from "lucide-react";
|
|
|
4
4
|
import * as l from "react-datepicker";
|
|
5
5
|
import { useController as v } from "react-hook-form";
|
|
6
6
|
import { c as p } from "./cn-C9QoOYNG.js";
|
|
7
|
-
import { z as M, A as D, B as C } from "./CollectionFormBuilder-
|
|
7
|
+
import { z as M, A as D, B as C } from "./CollectionFormBuilder-C9clUECd.js";
|
|
8
8
|
import { I as F } from "./Input-2CvZ90f8.js";
|
|
9
9
|
const T = l.default.default || l.default || l, I = (e) => {
|
|
10
10
|
if (e) {
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { j as e } from "./jsx-runtime-B6kdoens.js";
|
|
2
2
|
import { FormProvider as y } from "react-hook-form";
|
|
3
3
|
import { c as t } from "./cn-C9QoOYNG.js";
|
|
4
|
-
import { D as F, F as N } from "./CollectionFormBuilder-
|
|
5
|
-
import { u as g, S as w, F as b } from "./FormCaptcha-
|
|
4
|
+
import { D as F, F as N } from "./CollectionFormBuilder-C9clUECd.js";
|
|
5
|
+
import { u as g, S as w, F as b } from "./FormCaptcha-QTqyITqd.js";
|
|
6
6
|
import { B as D } from "./Spinner-BnrQ9e_i.js";
|
|
7
7
|
const _ = () => {
|
|
8
8
|
var n;
|
|
@@ -39,7 +39,7 @@ const _ = () => {
|
|
|
39
39
|
"form",
|
|
40
40
|
{
|
|
41
41
|
className: t(
|
|
42
|
-
"w-full rounded-md flex flex-col gap-6 px-4 md:px-8 py-6",
|
|
42
|
+
"w-full rounded-md flex text-text-1 flex-col gap-6 px-4 md:px-8 py-6",
|
|
43
43
|
u && "opacity-50 pointer-events-none"
|
|
44
44
|
),
|
|
45
45
|
id: "collection-form",
|
|
@@ -4,7 +4,7 @@ import { useState as f, useEffect as w } from "react";
|
|
|
4
4
|
import { useController as R } from "react-hook-form";
|
|
5
5
|
import B from "react-select";
|
|
6
6
|
import { c as y } from "./cn-C9QoOYNG.js";
|
|
7
|
-
import { z as D, A as N, B as q } from "./CollectionFormBuilder-
|
|
7
|
+
import { z as D, A as N, B as q } from "./CollectionFormBuilder-C9clUECd.js";
|
|
8
8
|
import { I as L } from "./Input-2CvZ90f8.js";
|
|
9
9
|
const G = ({
|
|
10
10
|
field: s,
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { j as r } from "./jsx-runtime-B6kdoens.js";
|
|
2
2
|
import { useController as y } from "react-hook-form";
|
|
3
3
|
import { G as C } from "./Spinner-BnrQ9e_i.js";
|
|
4
|
-
import { z as F, A as I, B as V } from "./CollectionFormBuilder-
|
|
4
|
+
import { z as F, A as I, B as V } from "./CollectionFormBuilder-C9clUECd.js";
|
|
5
5
|
import { I as b } from "./Input-2CvZ90f8.js";
|
|
6
6
|
function w(e) {
|
|
7
7
|
return C({ tag: "svg", attr: { viewBox: "0 0 24 24" }, child: [{ tag: "path", attr: { d: "M1.75 3h20.5c.966 0 1.75.784 1.75 1.75v14a1.75 1.75 0 0 1-1.75 1.75H1.75A1.75 1.75 0 0 1 0 18.75v-14C0 3.784.784 3 1.75 3ZM1.5 7.412V18.75c0 .138.112.25.25.25h20.5a.25.25 0 0 0 .25-.25V7.412l-9.52 6.433c-.592.4-1.368.4-1.96 0Zm0-2.662v.852l10.36 7a.25.25 0 0 0 .28 0l10.36-7V4.75a.25.25 0 0 0-.25-.25H1.75a.25.25 0 0 0-.25.25Z" }, child: [] }] })(e);
|
|
@@ -3,7 +3,7 @@ import { useEffect as k, useState as b, useRef as J } from "react";
|
|
|
3
3
|
import { useFormContext as W, useWatch as Y, useForm as B, useController as G } from "react-hook-form";
|
|
4
4
|
import { useDebouncedCallback as H } from "use-debounce";
|
|
5
5
|
import { u as x } from "./LevoProvider-BAZy7_tP.js";
|
|
6
|
-
import { D as C, s as z, h as Q, c as X, A as Z } from "./CollectionFormBuilder-
|
|
6
|
+
import { D as C, s as z, h as Q, c as X, A as Z } from "./CollectionFormBuilder-C9clUECd.js";
|
|
7
7
|
import { s as m } from "./Sonner-t6JVKA0a.js";
|
|
8
8
|
import { e as D } from "./errorHandler-_34Yv8wA.js";
|
|
9
9
|
import { a as h } from "./isEmptyObject-C5s4GzLE.js";
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
import { j as o } from "./jsx-runtime-B6kdoens.js";
|
|
3
3
|
import { useState as p, useEffect as v } from "react";
|
|
4
|
-
import { useController as
|
|
5
|
-
import { o as
|
|
6
|
-
import { z as
|
|
4
|
+
import { useController as k } from "react-hook-form";
|
|
5
|
+
import { o as z } from "./Spinner-BnrQ9e_i.js";
|
|
6
|
+
import { z as T, A as q, B as A } from "./CollectionFormBuilder-C9clUECd.js";
|
|
7
7
|
import { I as E } from "./Input-2CvZ90f8.js";
|
|
8
8
|
import { u as O } from "./LevoProvider-BAZy7_tP.js";
|
|
9
9
|
const $ = ({ field: t }) => {
|
|
@@ -11,9 +11,9 @@ const $ = ({ field: t }) => {
|
|
|
11
11
|
const [c, h] = p(""), [m, u] = p(!1), [l, N] = p([]), [g, i] = p(!1), { client: a } = O(), { key: d = "", label: f = "", helper_text: w = "", readonly: j = !1 } = t, {
|
|
12
12
|
field: { value: s, onBlur: F, onChange: y, ...L },
|
|
13
13
|
fieldState: x
|
|
14
|
-
} =
|
|
14
|
+
} = k({
|
|
15
15
|
name: d,
|
|
16
|
-
rules:
|
|
16
|
+
rules: T(t)
|
|
17
17
|
}), B = !!(t != null && t.required), C = (_ = x == null ? void 0 : x.error) == null ? void 0 : _.message, I = (e) => {
|
|
18
18
|
i(!0), u(!0), a == null || a.fetch.url(`/v1/bevy/content/location/${e == null ? void 0 : e.place_id}/get-location-details`).get().json().then((n) => {
|
|
19
19
|
var r;
|
|
@@ -46,7 +46,7 @@ const $ = ({ field: t }) => {
|
|
|
46
46
|
onBlur: () => {
|
|
47
47
|
F();
|
|
48
48
|
},
|
|
49
|
-
rightIcon: g && /* @__PURE__ */ o.jsx(
|
|
49
|
+
rightIcon: g && /* @__PURE__ */ o.jsx(z, { size: "20px", className: "animate-spin" }),
|
|
50
50
|
readOnly: j,
|
|
51
51
|
...L
|
|
52
52
|
}
|
|
@@ -54,7 +54,7 @@ const $ = ({ field: t }) => {
|
|
|
54
54
|
c && !g && !m && /* @__PURE__ */ o.jsx("div", { className: "absolute bg-white left-[-1px] z-50 p-[4px] w-full shadow-[0_0_8px_rgba(0,0,0,0.25)] rounded-[6px]", children: l != null && l.length ? l.map((e) => /* @__PURE__ */ o.jsx(
|
|
55
55
|
"p",
|
|
56
56
|
{
|
|
57
|
-
className: "text-md p-[8px] cursor-pointer rounded-[6px] hover:bg-gray-200",
|
|
57
|
+
className: "text-md p-[8px] cursor-pointer rounded-[6px] hover:bg-gray-200 text-black",
|
|
58
58
|
onClick: () => I(e),
|
|
59
59
|
children: e.description
|
|
60
60
|
},
|
|
@@ -2,8 +2,8 @@
|
|
|
2
2
|
import { j as e } from "./jsx-runtime-B6kdoens.js";
|
|
3
3
|
import { Plus as m } from "lucide-react";
|
|
4
4
|
import { useFieldArray as n } from "react-hook-form";
|
|
5
|
-
import { B as c } from "./CollectionFormBuilder-
|
|
6
|
-
import { GeocoderWidget as d } from "./GeocoderWidget-
|
|
5
|
+
import { B as c } from "./CollectionFormBuilder-C9clUECd.js";
|
|
6
|
+
import { GeocoderWidget as d } from "./GeocoderWidget-PKGgCyAq.js";
|
|
7
7
|
import { B as p } from "./Spinner-BnrQ9e_i.js";
|
|
8
8
|
const k = ({
|
|
9
9
|
field: l
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { j as a } from "./jsx-runtime-B6kdoens.js";
|
|
2
2
|
import { useController as A } from "react-hook-form";
|
|
3
|
-
import { z as C, A as b, B as q } from "./CollectionFormBuilder-
|
|
3
|
+
import { z as C, A as b, B as q } from "./CollectionFormBuilder-C9clUECd.js";
|
|
4
4
|
import { I } from "./Input-2CvZ90f8.js";
|
|
5
5
|
const f = ({ field: r }) => {
|
|
6
6
|
var l;
|
|
@@ -3,7 +3,7 @@ import { j as o } from "./jsx-runtime-B6kdoens.js";
|
|
|
3
3
|
import { useController as f } from "react-hook-form";
|
|
4
4
|
import { PhoneInput as g } from "react-international-phone";
|
|
5
5
|
import { c as l } from "./cn-C9QoOYNG.js";
|
|
6
|
-
import { z as x, A as v, B as y } from "./CollectionFormBuilder-
|
|
6
|
+
import { z as x, A as v, B as y } from "./CollectionFormBuilder-C9clUECd.js";
|
|
7
7
|
const P = ({ field: e }) => {
|
|
8
8
|
const { key: u = "", label: t = "", helper_text: c = "", readonly: n = !1 } = e, s = u, {
|
|
9
9
|
field: { value: d, onBlur: a, onChange: i, ...m },
|
|
@@ -5,7 +5,7 @@ import * as d from "react";
|
|
|
5
5
|
import { useController as F } from "react-hook-form";
|
|
6
6
|
import { G as B } from "./Spinner-BnrQ9e_i.js";
|
|
7
7
|
import { c as N } from "./cn-C9QoOYNG.js";
|
|
8
|
-
import { z as E, A as G, B as f } from "./CollectionFormBuilder-
|
|
8
|
+
import { z as E, A as G, B as f } from "./CollectionFormBuilder-C9clUECd.js";
|
|
9
9
|
import { I as V } from "./Input-2CvZ90f8.js";
|
|
10
10
|
function q(s) {
|
|
11
11
|
return B({ tag: "svg", attr: { viewBox: "0 0 512 512" }, child: [{ tag: "path", attr: { fill: "none", strokeLinecap: "round", strokeLinejoin: "round", strokeWidth: "32", d: "M416 128 192 384l-96-96" }, child: [] }] })(s);
|
|
@@ -19,7 +19,7 @@ import { useState as q, useEffect as D } from "react";
|
|
|
19
19
|
import { useController as G } from "react-hook-form";
|
|
20
20
|
import { G as p, p as J, q as V, r as W, s as Z, t as _, u as P, v as K, w as Q, x as X, y as Y, z as $, A as nn } from "./Spinner-BnrQ9e_i.js";
|
|
21
21
|
import { c as j } from "./cn-C9QoOYNG.js";
|
|
22
|
-
import { z as ln, A as en, B as sn } from "./CollectionFormBuilder-
|
|
22
|
+
import { z as ln, A as en, B as sn } from "./CollectionFormBuilder-C9clUECd.js";
|
|
23
23
|
function an(n) {
|
|
24
24
|
return p({ tag: "svg", attr: { viewBox: "0 0 1024 1024" }, child: [{ tag: "path", attr: { d: "M758.2 839.1C851.8 765.9 912 651.9 912 523.9 912 303 733.5 124.3 512.6 124 291.4 123.7 112 302.8 112 523.9c0 125.2 57.5 236.9 147.6 310.2 3.5 2.8 8.6 2.2 11.4-1.3l39.4-50.5c2.7-3.4 2.1-8.3-1.2-11.1-8.1-6.6-15.9-13.7-23.4-21.2a318.64 318.64 0 0 1-68.6-101.7C200.4 609 192 567.1 192 523.9s8.4-85.1 25.1-124.5c16.1-38.1 39.2-72.3 68.6-101.7 29.4-29.4 63.6-52.5 101.7-68.6C426.9 212.4 468.8 204 512 204s85.1 8.4 124.5 25.1c38.1 16.1 72.3 39.2 101.7 68.6 29.4 29.4 52.5 63.6 68.6 101.7 16.7 39.4 25.1 81.3 25.1 124.5s-8.4 85.1-25.1 124.5a318.64 318.64 0 0 1-68.6 101.7c-9.3 9.3-19.1 18-29.3 26L668.2 724a8 8 0 0 0-14.1 3l-39.6 162.2c-1.2 5 2.6 9.9 7.7 9.9l167 .8c6.7 0 10.5-7.7 6.3-12.9l-37.3-47.9z" }, child: [] }] })(n);
|
|
25
25
|
}
|
|
@@ -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-
|
|
7
|
-
import { u as C, S as H, F as M } from "./FormCaptcha-
|
|
6
|
+
import { D as N, F as _ } from "./CollectionFormBuilder-C9clUECd.js";
|
|
7
|
+
import { u as C, S as H, F as M } from "./FormCaptcha-QTqyITqd.js";
|
|
8
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
|
-
},
|
|
12
|
+
}, s = () => {
|
|
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:
|
|
21
|
+
handleNext: s,
|
|
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:
|
|
28
|
+
const { schema: s, isInternal: c, isDisabled: o, submitButtonConfig: i, uiConfig: d } = N(), r = y(
|
|
29
29
|
() => {
|
|
30
|
-
var
|
|
31
|
-
return (
|
|
30
|
+
var e;
|
|
31
|
+
return (e = s == null ? void 0 : s.sections) == null ? void 0 : e[n];
|
|
32
32
|
},
|
|
33
33
|
[n]
|
|
34
34
|
), w = y(() => {
|
|
35
|
-
if (
|
|
36
|
-
const
|
|
37
|
-
return r &&
|
|
35
|
+
if (s) {
|
|
36
|
+
const e = { ...s };
|
|
37
|
+
return r && e && (e.sections = [r]), e;
|
|
38
38
|
}
|
|
39
39
|
return null;
|
|
40
|
-
}, [r]), x = n === Number((h =
|
|
40
|
+
}, [r]), x = n === Number((h = s == null ? void 0 : s.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: (
|
|
56
|
+
onSubmitError: (e) => {
|
|
57
57
|
var S;
|
|
58
|
-
if (Array.isArray(
|
|
59
|
-
const R =
|
|
60
|
-
(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) => {
|
|
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: (
|
|
73
|
+
getContentId: (e) => D(e),
|
|
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 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 text-text-1",
|
|
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 =
|
|
94
|
+
((j = s == null ? void 0 : s.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((
|
|
98
|
+
(v = r == null ? void 0 : r.fields) == null ? void 0 : v.map((e) => e && !e.hidden ? /* @__PURE__ */ t.jsx(
|
|
99
99
|
_,
|
|
100
100
|
{
|
|
101
|
-
field:
|
|
101
|
+
field: e,
|
|
102
102
|
isInternal: c
|
|
103
103
|
},
|
|
104
|
-
|
|
104
|
+
e == null ? void 0 : e.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-
|
|
4
|
+
import { z as w, A as j, B as v } from "./CollectionFormBuilder-C9clUECd.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-
|
|
4
|
+
import { A as F, B as b, z as y } from "./CollectionFormBuilder-C9clUECd.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-
|
|
4
|
+
import { A as g, B as f, z as h } from "./CollectionFormBuilder-C9clUECd.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-
|
|
4
|
+
import { z as u, A as g, B as C } from "./CollectionFormBuilder-C9clUECd.js";
|
|
5
5
|
import { C as f } from "./Checbox-sq-atGlJ.js";
|
|
6
6
|
const y = ({
|
|
7
7
|
field: e
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { j as e } from "./jsx-runtime-B6kdoens.js";
|
|
2
|
-
import { H as s } from "./CollectionFormBuilder-
|
|
3
|
-
import r from "./TextWidget-
|
|
2
|
+
import { H as s } from "./CollectionFormBuilder-C9clUECd.js";
|
|
3
|
+
import r from "./TextWidget-BUKw__Xy.js";
|
|
4
4
|
const a = (t) => /* @__PURE__ */ e.jsx(
|
|
5
5
|
r,
|
|
6
6
|
{
|
|
@@ -5,7 +5,7 @@ import { Upload as Z, X as at, ExternalLink as et } from "lucide-react";
|
|
|
5
5
|
import { useState as B, useMemo as D, useRef as st, useEffect as R } from "react";
|
|
6
6
|
import { useController as ot } from "react-hook-form";
|
|
7
7
|
import { G as q, S as W, B as F, k as nt, T as ct, l as lt, m as V, n as H } from "./Spinner-BnrQ9e_i.js";
|
|
8
|
-
import { t as it, g as dt, z as xt, w as J, A as ut, B as mt } from "./CollectionFormBuilder-
|
|
8
|
+
import { t as it, g as dt, z as xt, w as J, A as ut, B as mt } from "./CollectionFormBuilder-C9clUECd.js";
|
|
9
9
|
import { u as G } from "./LevoProvider-BAZy7_tP.js";
|
|
10
10
|
import { e as k } from "./errorHandler-_34Yv8wA.js";
|
|
11
11
|
import { I as Q } from "./Input-2CvZ90f8.js";
|
package/dist/collection/index.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { C as s, F as r, e as t, b as i, c as l, f as o, g as d, d as m, i as u, a as n, p as f, h as F, s as g, u as p, v as V } from "../CollectionFormBuilder-
|
|
1
|
+
import { C as s, F as r, e as t, b as i, c as l, f as o, g as d, d as m, i as u, a as n, p as f, h as F, s as g, u as p, v as V } from "../CollectionFormBuilder-C9clUECd.js";
|
|
2
2
|
import { default as h } from "validatorjs";
|
|
3
3
|
export {
|
|
4
4
|
s as CollectionFormBuilder,
|
package/dist/index.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { L as s, u as o } from "./LevoProvider-BAZy7_tP.js";
|
|
2
2
|
import { L as t, a as r, b as l } from "./page-sR2SWtb2.js";
|
|
3
|
-
import { C as m, F as p, x as d, y as g, m as T, r as f, j as u, n as c, e as x, b, c as D, f as y, g as F, d as v, k as h, o as L, i as M, a as E, w as P, t as B, p as C, h as O, s as V, u as j, v as I, l as S, q as K } from "./CollectionFormBuilder-
|
|
3
|
+
import { C as m, F as p, x as d, y as g, m as T, r as f, j as u, n as c, e as x, b, c as D, f as y, g as F, d as v, k as h, o as L, i as M, a as E, w as P, t as B, p as C, h as O, s as V, u as j, v as I, l as S, q as K } from "./CollectionFormBuilder-C9clUECd.js";
|
|
4
4
|
import { LevoOAuth as U } from "./membership/index.js";
|
|
5
5
|
import { B as H, D as N, j as q, e as w, i as z, g as A, f as R, c as G, a as J, h as Q, d as X, k as Y, S as Z, T as _, n as $, l as aa, m as ea, b as sa } from "./Spinner-BnrQ9e_i.js";
|
|
6
6
|
import { T as ia, e as ta, s as ra } from "./Sonner-t6JVKA0a.js";
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@levo-so/react",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.24",
|
|
4
4
|
"author": "Levo Engineering <devs@theinternetfolks.com>",
|
|
5
5
|
"description": "Levo suite for React based applications",
|
|
6
6
|
"type": "module",
|
|
@@ -16,7 +16,7 @@
|
|
|
16
16
|
"peerDependencies": {
|
|
17
17
|
"react": ">=18",
|
|
18
18
|
"react-dom": ">=18",
|
|
19
|
-
"@levo-so/core": "0.1.
|
|
19
|
+
"@levo-so/core": "0.1.24"
|
|
20
20
|
},
|
|
21
21
|
"dependencies": {
|
|
22
22
|
"@radix-ui/react-checkbox": "1.1.1",
|
|
@@ -91,8 +91,8 @@
|
|
|
91
91
|
"vite": "5.4.3",
|
|
92
92
|
"vite-plugin-dts": "4.1.0",
|
|
93
93
|
"@levo/eslint-config": "0.0.0",
|
|
94
|
-
"@levo/
|
|
95
|
-
"@levo/
|
|
94
|
+
"@levo/ts-config": "0.0.0",
|
|
95
|
+
"@levo/tw-config": "0.0.0"
|
|
96
96
|
},
|
|
97
97
|
"main": "./dist/index.js",
|
|
98
98
|
"module": "./dist/index.js",
|