@chaibuilder/sdk 1.2.26 → 1.2.28
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/{AddBlocks-l1JENNvq.js → AddBlocks-0sW6gkCO.js} +5 -5
- package/dist/AddBlocks-YJPdSqcY.cjs +1 -0
- package/dist/{BrandingOptions-udtH5yJs.js → BrandingOptions--vgnQvD1.js} +8 -8
- package/dist/{BrandingOptions-DkpqGARR.cjs → BrandingOptions-RDn_Nhcq.cjs} +1 -1
- package/dist/CanvasArea-41QoxuLf.cjs +55 -0
- package/dist/CanvasArea-aii0PyU-.js +1179 -0
- package/dist/{Class-lGzsNBOK.js → Class-6Hz2KzYb.js} +1 -1
- package/dist/{Class-PoYusiA5.cjs → Class-Zc8hpE7f.cjs} +1 -1
- package/dist/{CurrentPage-tJUjXWdb.js → CurrentPage-06Iacwyp.js} +6 -6
- package/dist/{CurrentPage-Hl52iub_.cjs → CurrentPage-2W1pdAOG.cjs} +1 -1
- package/dist/ListTree-DnA8gj-7.js +314 -0
- package/dist/ListTree-pdQ14QJC.cjs +1 -0
- package/dist/MODIFIERS-YPHRtwrM.cjs +1 -0
- package/dist/{MODIFIERS-dytZ-osO.js → MODIFIERS-cBT31iqE.js} +3 -11
- package/dist/{PagesPanel-WzCocl6u.cjs → PagesPanel-PBFzPSNY.cjs} +1 -1
- package/dist/{PagesPanel-6rrLXEO-.js → PagesPanel-_1CDTUdE.js} +7 -7
- package/dist/{ProjectPanel-o7gdcwPn.cjs → ProjectPanel-755bbzEQ.cjs} +1 -1
- package/dist/{ProjectPanel-tz3bjdXy.js → ProjectPanel-pUMeIiUW.js} +7 -7
- package/dist/Settings-G9Xtqr7n.cjs +1 -0
- package/dist/{Settings-4s2LUVmC.js → Settings-dnO-s6x0.js} +596 -560
- package/dist/{SidePanels-3o6Okmvu.cjs → SidePanels-Gq2LdVuY.cjs} +1 -1
- package/dist/{SidePanels-bugFfInz.js → SidePanels-VxSXXkt_.js} +56 -56
- package/dist/{Topbar-pWzBEOed.js → Topbar-5zbOSGF6.js} +3 -3
- package/dist/{Topbar-CqW7G360.cjs → Topbar-J2tb4SA1.cjs} +1 -1
- package/dist/{UnsplashImages-qvwFbV-E.js → UnsplashImages-4WAWgA4s.js} +9 -9
- package/dist/{UnsplashImages-NGskB93R.cjs → UnsplashImages-XwjKheek.cjs} +1 -1
- package/dist/{UploadImages-9NapgXBq.js → UploadImages-PONIHtn6.js} +3 -3
- package/dist/{UploadImages-Oh7Glr9A.cjs → UploadImages-y7LAQVrT.cjs} +1 -1
- package/dist/{add-page-modal-k2Kb92HS.js → add-page-modal-4VrFvgEm.js} +7 -7
- package/dist/{add-page-modal--6TTBRYa.cjs → add-page-modal-jWcp0w-S.cjs} +1 -1
- package/dist/{confirm-alert-C4M9eF-o.cjs → confirm-alert-4OQlXZTJ.cjs} +1 -1
- package/dist/{confirm-alert-GUhZ_G8w.js → confirm-alert-j7b88hsW.js} +3 -3
- package/dist/core.cjs +1 -1
- package/dist/core.js +4 -4
- package/dist/{delete-page-modal-zONvdebd.js → delete-page-modal--xHHdRAq.js} +6 -6
- package/dist/{delete-page-modal-cFoL-wdo.cjs → delete-page-modal-p6b0upz4.cjs} +1 -1
- package/dist/email-blocks.cjs +1 -1
- package/dist/email-blocks.js +1 -1
- package/dist/email.cjs +1 -1
- package/dist/email.js +4 -4
- package/dist/{form-STUz-6nE.js → form-_GJb9YcB.js} +1 -1
- package/dist/{form-lBQ_76Uw.cjs → form-jQj7E-hS.cjs} +1 -1
- package/dist/html-to-json-LJyJsnmZ.js +228 -0
- package/dist/html-to-json-vP1ESB_e.cjs +1 -0
- package/dist/{index-SkyM3d6Q.js → index-0QJwevON.js} +2 -2
- package/dist/index-12HbDLon.cjs +1 -0
- package/dist/{index-llTXLDGE.js → index-Eb5zyh2F.js} +4 -4
- package/dist/{index-mbyqq81O.cjs → index-KArv7pNz.cjs} +1 -1
- package/dist/{index-Gk6sASBd.js → index-UHaqEdws.js} +993 -957
- package/dist/{index-OB199Izc.cjs → index-mlMvwv2b.cjs} +2 -2
- package/dist/lib.cjs +1 -1
- package/dist/lib.js +4 -4
- package/dist/{page-viewer-Pdg9F5Hv.js → page-viewer-00Xx4u8e.js} +7 -7
- package/dist/{page-viewer-2kwnKM6v.cjs → page-viewer-SZNm7b1n.cjs} +1 -1
- package/dist/{project-general-setting-CnNL98NM.cjs → project-general-setting-C_pHNuZE.cjs} +1 -1
- package/dist/{project-general-setting-f8Ebsn6K.js → project-general-setting-asDxlmhZ.js} +7 -7
- package/dist/{project-seo-setting-pX34Qsym.js → project-seo-setting-DuAaDfDR.js} +4 -4
- package/dist/{project-seo-setting-mlxL_e2_.cjs → project-seo-setting-q2953ybQ.cjs} +1 -1
- package/dist/render.cjs +1 -1
- package/dist/render.js +1 -1
- package/dist/{single-page-detail-dpe5LT0M.js → single-page-detail-UNxXvhl4.js} +14 -14
- package/dist/{single-page-detail-XfzrGlzA.cjs → single-page-detail-oqj6zsLU.cjs} +1 -1
- package/dist/studio.cjs +1 -1
- package/dist/studio.js +6 -6
- package/dist/ui.cjs +1 -1
- package/dist/ui.js +9 -9
- package/dist/useCanvasSettings-MR0Glu1b.cjs +1 -0
- package/dist/useCanvasSettings-R6br4J9i.js +6 -0
- package/dist/web-blocks.cjs +33 -6
- package/dist/web-blocks.js +461 -388
- package/package.json +1 -1
- package/dist/AddBlocks-zPPKkeKs.cjs +0 -1
- package/dist/CanvasArea-h0W-Tyha.js +0 -951
- package/dist/CanvasArea-zme1r3Zi.cjs +0 -55
- package/dist/ListTree-WvTjY5rr.cjs +0 -1
- package/dist/ListTree-cZ-Ihlt3.js +0 -309
- package/dist/MODIFIERS-0g14w5RS.cjs +0 -1
- package/dist/Settings-AqoKwR92.cjs +0 -1
- package/dist/html-to-json-efmv1pCj.cjs +0 -1
- package/dist/html-to-json-ngX9ef2u.js +0 -185
- package/dist/index-h-hd6EvN.cjs +0 -1
package/dist/web-blocks.js
CHANGED
|
@@ -1,32 +1,34 @@
|
|
|
1
|
-
import { isNull as
|
|
2
|
-
import { j as
|
|
3
|
-
import * as
|
|
4
|
-
import { S as i, s as
|
|
1
|
+
import { isNull as $, isEmpty as k, get as x, pick as z, omit as q, find as O, map as E, noop as V } from "lodash-es";
|
|
2
|
+
import { j as n } from "./jsx-runtime-WbnYoNE9.js";
|
|
3
|
+
import * as p from "react";
|
|
4
|
+
import { S as i, s as I, o as C, g as B, m as L, u as y, T as P, c as _, q as U, b as G, r as b, h as W } from "./controls-OfJWSEqC.js";
|
|
5
5
|
import { registerChaiBlock as d } from "@chaibuilder/runtime";
|
|
6
|
-
import { E as
|
|
7
|
-
import { HeadingIcon as
|
|
8
|
-
import { c as
|
|
9
|
-
import {
|
|
6
|
+
import { E as v } from "./empty-slot-ZBlsQi6m.js";
|
|
7
|
+
import { HeadingIcon as Y, TextIcon as X, CursorTextIcon as Z, ButtonIcon as R, Link1Icon as J, RowsIcon as K, ColumnsIcon as Q, SketchLogoIcon as ee, ImageIcon as te, VideoIcon as le, CodeIcon as oe, DividerHorizontalIcon as se, SpaceBetweenVerticallyIcon as F, TableIcon as ae, BorderTopIcon as ne, BorderAllIcon as re, ViewHorizontalIcon as ce, DragHandleHorizontalIcon as ie, GroupIcon as de, LetterCaseToggleIcon as ue, CheckboxIcon as pe, InputIcon as D, RadiobuttonIcon as he, DropdownMenuIcon as ye } from "@radix-ui/react-icons";
|
|
8
|
+
import { c as S, g } from "./Functions-7jnEwJyw.js";
|
|
9
|
+
import { g as A } from "./html-to-json-LJyJsnmZ.js";
|
|
10
10
|
import "./_commonjsHelpers-UyOWmZb0.js";
|
|
11
11
|
import "clsx";
|
|
12
12
|
import "tailwind-merge";
|
|
13
|
-
|
|
13
|
+
import "himalaya";
|
|
14
|
+
import "./STRINGS--j49GZJP.js";
|
|
15
|
+
const me = p.memo(
|
|
14
16
|
(e) => {
|
|
15
|
-
const { blockProps: t, inBuilder: l, backgroundImage: o, children:
|
|
16
|
-
let c =
|
|
17
|
-
|
|
18
|
-
let
|
|
19
|
-
return o && (
|
|
17
|
+
const { blockProps: t, inBuilder: l, backgroundImage: o, children: s, tag: a = "div", styles: r } = e;
|
|
18
|
+
let c = s;
|
|
19
|
+
s || (c = /* @__PURE__ */ n.jsx(v, { blockProps: {}, styles: {}, inBuilder: l }));
|
|
20
|
+
let u = {};
|
|
21
|
+
return o && (u = { backgroundImage: `url(${o})` }), p.createElement(a, { ...t, ...r, style: u }, c);
|
|
20
22
|
}
|
|
21
23
|
);
|
|
22
|
-
d(
|
|
24
|
+
d(me, {
|
|
23
25
|
type: "Box",
|
|
24
26
|
label: "Box",
|
|
25
27
|
category: "core",
|
|
26
28
|
group: "basic",
|
|
27
29
|
props: {
|
|
28
30
|
styles: i({ default: "" }),
|
|
29
|
-
tag:
|
|
31
|
+
tag: I({
|
|
30
32
|
title: "Tag",
|
|
31
33
|
default: "div",
|
|
32
34
|
options: [
|
|
@@ -49,26 +51,26 @@ d(he, {
|
|
|
49
51
|
{ value: "mark", title: "mark" }
|
|
50
52
|
]
|
|
51
53
|
}),
|
|
52
|
-
backgroundImage:
|
|
54
|
+
backgroundImage: C({ title: "Background Image" })
|
|
53
55
|
},
|
|
54
56
|
canAcceptBlock: () => !0
|
|
55
57
|
});
|
|
56
|
-
const
|
|
57
|
-
const { blockProps: t, styles: l, content: o, level:
|
|
58
|
-
return a ?
|
|
58
|
+
const fe = (e) => {
|
|
59
|
+
const { blockProps: t, styles: l, content: o, level: s = "h1", children: a = null } = e;
|
|
60
|
+
return a ? p.createElement(s, { ...l, ...t }, a) : p.createElement(s, {
|
|
59
61
|
...l,
|
|
60
62
|
...t,
|
|
61
63
|
dangerouslySetInnerHTML: { __html: o }
|
|
62
64
|
});
|
|
63
65
|
};
|
|
64
|
-
d(
|
|
66
|
+
d(fe, {
|
|
65
67
|
type: "Heading",
|
|
66
68
|
label: "Heading",
|
|
67
69
|
category: "core",
|
|
68
|
-
icon:
|
|
70
|
+
icon: Y,
|
|
69
71
|
group: "typography",
|
|
70
72
|
props: {
|
|
71
|
-
level:
|
|
73
|
+
level: I({
|
|
72
74
|
title: "Level",
|
|
73
75
|
default: "h1",
|
|
74
76
|
binding: !1,
|
|
@@ -82,83 +84,83 @@ d(ye, {
|
|
|
82
84
|
]
|
|
83
85
|
}),
|
|
84
86
|
styles: i({ default: "text-3xl" }),
|
|
85
|
-
content:
|
|
87
|
+
content: B({ title: "Content", default: "Heading goes here" })
|
|
86
88
|
},
|
|
87
89
|
canAcceptBlock: (e) => e === "Span" || e === "Text"
|
|
88
90
|
});
|
|
89
|
-
const
|
|
91
|
+
const be = (e) => {
|
|
90
92
|
const { blockProps: t, styles: l, content: o } = e;
|
|
91
|
-
return
|
|
93
|
+
return $(e.children) ? p.createElement("p", {
|
|
92
94
|
...l,
|
|
93
95
|
...t,
|
|
94
96
|
dangerouslySetInnerHTML: { __html: o }
|
|
95
|
-
}) :
|
|
97
|
+
}) : p.createElement("p", { ...l, ...t }, e.children);
|
|
96
98
|
};
|
|
97
|
-
d(
|
|
99
|
+
d(be, {
|
|
98
100
|
type: "Paragraph",
|
|
99
101
|
label: "Paragraph",
|
|
100
102
|
category: "core",
|
|
101
|
-
icon:
|
|
103
|
+
icon: X,
|
|
102
104
|
group: "typography",
|
|
103
105
|
props: {
|
|
104
106
|
styles: i({ default: "" }),
|
|
105
|
-
content:
|
|
107
|
+
content: B({
|
|
106
108
|
title: "Content",
|
|
107
109
|
default: "Lorem ipsum dolor sit amet, consectetur adipiscing elit. Suspendisse varius enim in eros elementum tristique. Duis cursus, mi quis viverra ornare, eros dolor interdum nulla, ut commodo diam libero vitae erat. Aenean faucibus nibh et justo cursus id rutrum lorem imperdiet. Nunc ut sem vitae risus tristique posuere."
|
|
108
110
|
})
|
|
109
111
|
},
|
|
110
112
|
canAcceptBlock: (e) => e === "Span" || e === "Link"
|
|
111
113
|
});
|
|
112
|
-
const
|
|
113
|
-
const { blockProps: t, styles: l, content: o, children:
|
|
114
|
-
return
|
|
114
|
+
const ge = (e) => {
|
|
115
|
+
const { blockProps: t, styles: l, content: o, children: s = null, tag: a } = e;
|
|
116
|
+
return s ? p.createElement("span", { ...l, ...t }, s) : p.createElement(a || "span", {
|
|
115
117
|
...l,
|
|
116
118
|
...t,
|
|
117
119
|
dangerouslySetInnerHTML: { __html: o }
|
|
118
120
|
});
|
|
119
121
|
};
|
|
120
|
-
d(
|
|
122
|
+
d(ge, {
|
|
121
123
|
type: "Span",
|
|
122
124
|
label: "Span",
|
|
123
125
|
category: "core",
|
|
124
126
|
group: "typography",
|
|
125
127
|
props: {
|
|
126
128
|
styles: i({ default: "" }),
|
|
127
|
-
content:
|
|
129
|
+
content: B({ title: "Content", default: "Enter your content" })
|
|
128
130
|
},
|
|
129
131
|
canAcceptBlock: () => !0
|
|
130
132
|
});
|
|
131
|
-
const
|
|
133
|
+
const ve = (e) => {
|
|
132
134
|
const { blockProps: t, content: l, styles: o } = e;
|
|
133
|
-
return /* @__PURE__ */
|
|
135
|
+
return /* @__PURE__ */ n.jsx("div", { className: "max-w-full", children: /* @__PURE__ */ n.jsx("div", { ...t, ...o, dangerouslySetInnerHTML: { __html: l } }) });
|
|
134
136
|
};
|
|
135
|
-
d(
|
|
137
|
+
d(ve, {
|
|
136
138
|
type: "RichText",
|
|
137
139
|
label: "Rich Text",
|
|
138
140
|
category: "core",
|
|
139
|
-
icon:
|
|
141
|
+
icon: Z,
|
|
140
142
|
group: "typography",
|
|
141
143
|
props: {
|
|
142
144
|
styles: i({ default: "" }),
|
|
143
|
-
content:
|
|
145
|
+
content: L({
|
|
144
146
|
title: "Content",
|
|
145
147
|
default: "<p>This is a rich text block. You can add text, and other content here.</p>"
|
|
146
148
|
})
|
|
147
149
|
}
|
|
148
150
|
});
|
|
149
151
|
const xe = (e) => {
|
|
150
|
-
const { blockProps: t, iconSize: l, icon: o, content:
|
|
151
|
-
/* @__PURE__ */
|
|
152
|
-
|
|
152
|
+
const { blockProps: t, iconSize: l, icon: o, content: s, iconPos: a, styles: r, children: c } = e, u = o, h = c || /* @__PURE__ */ n.jsxs(n.Fragment, { children: [
|
|
153
|
+
/* @__PURE__ */ n.jsx("span", { children: s }),
|
|
154
|
+
u && /* @__PURE__ */ n.jsx(
|
|
153
155
|
"div",
|
|
154
156
|
{
|
|
155
157
|
style: { width: l + "px" },
|
|
156
158
|
className: a + " " + (a === "order-first" ? "mr-2" : "ml-2") || "",
|
|
157
|
-
dangerouslySetInnerHTML: { __html:
|
|
159
|
+
dangerouslySetInnerHTML: { __html: u }
|
|
158
160
|
}
|
|
159
161
|
)
|
|
160
162
|
] });
|
|
161
|
-
return
|
|
163
|
+
return p.createElement("button", { ...t, ...r, type: "button" }, h);
|
|
162
164
|
};
|
|
163
165
|
d(xe, {
|
|
164
166
|
type: "Button",
|
|
@@ -167,11 +169,11 @@ d(xe, {
|
|
|
167
169
|
icon: R,
|
|
168
170
|
group: "basic",
|
|
169
171
|
props: {
|
|
170
|
-
content:
|
|
172
|
+
content: y({ title: "Label", default: "Button", multiLingual: !0 }),
|
|
171
173
|
styles: i({ default: "text-white bg-primary px-4 py-2 rounded-global flex items-center" }),
|
|
172
|
-
icon:
|
|
173
|
-
iconSize:
|
|
174
|
-
iconPos:
|
|
174
|
+
icon: P({ title: "Icon", default: "" }),
|
|
175
|
+
iconSize: _({ title: "Icon Size", default: 24 }),
|
|
176
|
+
iconPos: I({
|
|
175
177
|
title: "Icon Position",
|
|
176
178
|
default: "order-last",
|
|
177
179
|
options: [
|
|
@@ -182,45 +184,45 @@ d(xe, {
|
|
|
182
184
|
}
|
|
183
185
|
});
|
|
184
186
|
const ke = (e) => {
|
|
185
|
-
const { blockProps: t, link: l, children: o, styles:
|
|
186
|
-
return !o && k(
|
|
187
|
+
const { blockProps: t, link: l, children: o, styles: s, inBuilder: a, content: r } = e;
|
|
188
|
+
return !o && k(s == null ? void 0 : s.className) && k(r) ? /* @__PURE__ */ n.jsx(v, { blockProps: t, inBuilder: a }) : a ? o ? /* @__PURE__ */ n.jsx("span", { "data-simulate": "a", ...t, ...s, children: o }) : p.createElement("span", {
|
|
187
189
|
...t,
|
|
188
|
-
...
|
|
189
|
-
dangerouslySetInnerHTML: { __html:
|
|
190
|
+
...s,
|
|
191
|
+
dangerouslySetInnerHTML: { __html: r },
|
|
190
192
|
"data-simulate": "a"
|
|
191
|
-
}) : o ? /* @__PURE__ */
|
|
193
|
+
}) : o ? /* @__PURE__ */ n.jsx("a", { href: l.href || "#/", target: l.target, ...t, ...s, children: o }) : p.createElement("a", {
|
|
192
194
|
...t,
|
|
193
|
-
...
|
|
195
|
+
...s,
|
|
194
196
|
href: l.href || "#",
|
|
195
197
|
target: l.target || "_self",
|
|
196
|
-
dangerouslySetInnerHTML: { __html:
|
|
198
|
+
dangerouslySetInnerHTML: { __html: r }
|
|
197
199
|
});
|
|
198
200
|
};
|
|
199
201
|
d(ke, {
|
|
200
202
|
type: "Link",
|
|
201
203
|
label: "Link",
|
|
202
204
|
category: "core",
|
|
203
|
-
icon:
|
|
205
|
+
icon: J,
|
|
204
206
|
group: "basic",
|
|
205
207
|
props: {
|
|
206
208
|
styles: i({ default: "" }),
|
|
207
|
-
content:
|
|
208
|
-
link:
|
|
209
|
+
content: y({ title: "Content", default: "" }),
|
|
210
|
+
link: U({
|
|
209
211
|
title: "Link",
|
|
210
212
|
default: { type: "page", target: "_self", href: "" }
|
|
211
213
|
})
|
|
212
214
|
},
|
|
213
215
|
canAcceptBlock: () => !0
|
|
214
216
|
});
|
|
215
|
-
const
|
|
216
|
-
const { blockProps: t, children: l, listType: o, styles:
|
|
217
|
-
return !l && k(
|
|
217
|
+
const we = (e) => {
|
|
218
|
+
const { blockProps: t, children: l, listType: o, styles: s, tag: a, inBuilder: r } = e, c = S(x(s, "className", ""), o);
|
|
219
|
+
return !l && k(s == null ? void 0 : s.className) ? /* @__PURE__ */ n.jsx(v, { inBuilder: r, blockProps: t, text: "LIST ITEM" }) : p.createElement(
|
|
218
220
|
a || (o === "list-decimal" ? "ol" : "ul"),
|
|
219
|
-
{ ...t, ...
|
|
221
|
+
{ ...t, ...s, className: c },
|
|
220
222
|
l
|
|
221
223
|
);
|
|
222
224
|
};
|
|
223
|
-
d(
|
|
225
|
+
d(we, {
|
|
224
226
|
type: "List",
|
|
225
227
|
label: "List",
|
|
226
228
|
icon: K,
|
|
@@ -228,7 +230,7 @@ d(ve, {
|
|
|
228
230
|
group: "basic",
|
|
229
231
|
props: {
|
|
230
232
|
styles: i({ default: "" }),
|
|
231
|
-
listType:
|
|
233
|
+
listType: I({
|
|
232
234
|
title: "List type",
|
|
233
235
|
default: "list-disc",
|
|
234
236
|
options: [
|
|
@@ -264,99 +266,99 @@ d(ve, {
|
|
|
264
266
|
}
|
|
265
267
|
]
|
|
266
268
|
});
|
|
267
|
-
const
|
|
268
|
-
const { blockProps: t, content: l, styles: o, children:
|
|
269
|
-
return
|
|
269
|
+
const Ie = (e) => {
|
|
270
|
+
const { blockProps: t, content: l, styles: o, children: s, tag: a } = e;
|
|
271
|
+
return s ? p.createElement(a || "li", { ...o, ...t }, s) : p.createElement(a || "li", {
|
|
270
272
|
...o,
|
|
271
273
|
...t,
|
|
272
274
|
dangerouslySetInnerHTML: { __html: l }
|
|
273
275
|
});
|
|
274
276
|
};
|
|
275
|
-
d(
|
|
277
|
+
d(Ie, {
|
|
276
278
|
type: "ListItem",
|
|
277
279
|
label: "List Item",
|
|
278
|
-
icon:
|
|
280
|
+
icon: Q,
|
|
279
281
|
category: "core",
|
|
280
282
|
group: "basic",
|
|
281
283
|
props: {
|
|
282
284
|
styles: i({ default: "" }),
|
|
283
|
-
content:
|
|
285
|
+
content: B({ title: "Content", default: "List item" })
|
|
284
286
|
},
|
|
285
287
|
canAcceptBlock: () => !0,
|
|
286
288
|
canBeNested: (e) => e === "List"
|
|
287
289
|
});
|
|
288
|
-
const
|
|
290
|
+
const w = (e, ...t) => ({
|
|
289
291
|
...e,
|
|
290
|
-
className:
|
|
291
|
-
}),
|
|
292
|
-
const { blockProps: t, icon: l, styles: o, width:
|
|
292
|
+
className: S(e.className, ...t)
|
|
293
|
+
}), Be = (e) => {
|
|
294
|
+
const { blockProps: t, icon: l, styles: o, width: s, inBuilder: a, height: r } = e, c = w(
|
|
293
295
|
o,
|
|
294
|
-
|
|
296
|
+
S("inline-block", s ? `w-[${s}px]` : "", r ? `h-[${r}px]` : "")
|
|
295
297
|
);
|
|
296
298
|
if (k(l))
|
|
297
|
-
return /* @__PURE__ */
|
|
298
|
-
const
|
|
299
|
-
return
|
|
299
|
+
return /* @__PURE__ */ n.jsx(v, { blockProps: t, text: "", inBuilder: a, className: "h-8 w-14" });
|
|
300
|
+
const u = l.replace(/<svg /g, '<svg class="w-[inherit] h-[inherit]" ');
|
|
301
|
+
return p.createElement("span", {
|
|
300
302
|
...t,
|
|
301
303
|
...c,
|
|
302
|
-
dangerouslySetInnerHTML: { __html:
|
|
304
|
+
dangerouslySetInnerHTML: { __html: u }
|
|
303
305
|
});
|
|
304
306
|
};
|
|
305
|
-
d(
|
|
307
|
+
d(Be, {
|
|
306
308
|
type: "Icon",
|
|
307
309
|
label: "Icon",
|
|
308
310
|
category: "core",
|
|
309
|
-
icon:
|
|
311
|
+
icon: ee,
|
|
310
312
|
group: "media",
|
|
311
313
|
props: {
|
|
312
314
|
styles: i({ default: "text-black" }),
|
|
313
|
-
icon:
|
|
315
|
+
icon: P({
|
|
314
316
|
title: "Icon",
|
|
315
317
|
default: '<svg stroke="currentColor" fill="currentColor" stroke-width="0" viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg"><path d="M8 16c4.418 0 8-3.582 8-8s-3.582-8-8-8-8 3.582-8 8 3.582 8 8 8zM8 1.5c3.59 0 6.5 2.91 6.5 6.5s-2.91 6.5-6.5 6.5-6.5-2.91-6.5-6.5 2.91-6.5 6.5-6.5zM8 9.356c1.812 0 3.535-0.481 5-1.327-0.228 2.788-2.393 4.971-5 4.971s-4.772-2.186-5-4.973c1.465 0.845 3.188 1.329 5 1.329zM4 5.5c0-0.828 0.448-1.5 1-1.5s1 0.672 1 1.5c0 0.828-0.448 1.5-1 1.5s-1-0.672-1-1.5zM10 5.5c0-0.828 0.448-1.5 1-1.5s1 0.672 1 1.5c0 0.828-0.448 1.5-1 1.5s-1-0.672-1-1.5z"></path></svg>'
|
|
316
318
|
}),
|
|
317
|
-
width:
|
|
318
|
-
height:
|
|
319
|
+
width: _({ title: "Width", default: "" }),
|
|
320
|
+
height: _({ title: "Height", default: "" })
|
|
319
321
|
}
|
|
320
322
|
});
|
|
321
|
-
const
|
|
322
|
-
const { blockProps: t, image: l, styles: o, alt:
|
|
323
|
-
return k(l) ? /* @__PURE__ */
|
|
323
|
+
const Te = (e) => {
|
|
324
|
+
const { blockProps: t, image: l, styles: o, alt: s, height: a, width: r } = e;
|
|
325
|
+
return k(l) ? /* @__PURE__ */ n.jsx(v, { blockProps: t, text: "IMAGE URL", className: "h-36" }) : p.createElement("img", {
|
|
324
326
|
...t,
|
|
325
327
|
...o,
|
|
326
328
|
src: l,
|
|
327
|
-
alt:
|
|
329
|
+
alt: s,
|
|
328
330
|
height: a,
|
|
329
|
-
width:
|
|
331
|
+
width: r
|
|
330
332
|
});
|
|
331
333
|
};
|
|
332
|
-
d(
|
|
334
|
+
d(Te, {
|
|
333
335
|
type: "Image",
|
|
334
336
|
label: "Image",
|
|
335
337
|
category: "core",
|
|
336
|
-
icon:
|
|
338
|
+
icon: te,
|
|
337
339
|
group: "media",
|
|
338
340
|
props: {
|
|
339
341
|
styles: i({ default: "" }),
|
|
340
|
-
image:
|
|
342
|
+
image: C({
|
|
341
343
|
title: "Image",
|
|
342
344
|
default: "https://fakeimg.pl/400x200?text=Choose&font=bebas"
|
|
343
345
|
}),
|
|
344
|
-
alt:
|
|
345
|
-
width:
|
|
346
|
-
height:
|
|
346
|
+
alt: y({ title: "Alt", default: "" }),
|
|
347
|
+
width: y({ title: "Width", default: "" }),
|
|
348
|
+
height: y({ title: "Height", default: "" })
|
|
347
349
|
}
|
|
348
350
|
});
|
|
349
|
-
const
|
|
350
|
-
var
|
|
351
|
-
const { blockProps: t, inBuilder: l, styles: o, children:
|
|
351
|
+
const Le = (e) => {
|
|
352
|
+
var r;
|
|
353
|
+
const { blockProps: t, inBuilder: l, styles: o, children: s } = e;
|
|
352
354
|
let a = null;
|
|
353
|
-
return !
|
|
354
|
-
/* @__PURE__ */
|
|
355
|
+
return !s && l && (a = // @ts-ignore
|
|
356
|
+
/* @__PURE__ */ n.jsx("div", { className: S("flex flex-col items-center justify-center", (r = e.emptyStyles) == null ? void 0 : r.className), children: /* @__PURE__ */ n.jsx("div", { className: "h-full w-full rounded-md border-4 border-dashed", children: /* @__PURE__ */ n.jsxs("p", { className: "truncate p-1 text-left text-xs text-gray-400", children: [
|
|
355
357
|
"Slot: ",
|
|
356
358
|
e.name
|
|
357
|
-
] }) }) })),
|
|
359
|
+
] }) }) })), p.createElement("div", { ...o, ...t, droppable: "yes" }, s || a);
|
|
358
360
|
};
|
|
359
|
-
d(
|
|
361
|
+
d(Le, {
|
|
360
362
|
type: "Slot",
|
|
361
363
|
label: "Slot",
|
|
362
364
|
group: "basic",
|
|
@@ -368,13 +370,13 @@ d(_e, {
|
|
|
368
370
|
},
|
|
369
371
|
canAcceptBlock: () => !0
|
|
370
372
|
});
|
|
371
|
-
const N = /^(https?:\/\/)?(www\.)?youtube\.com\/(watch\?v=|embed\/)([a-zA-Z0-9_-]{11})/,
|
|
373
|
+
const N = /^(https?:\/\/)?(www\.)?youtube\.com\/(watch\?v=|embed\/)([a-zA-Z0-9_-]{11})/, M = /^(https?:\/\/)?(www\.)?player.vimeo\.com/, H = /^(https?:\/\/)?(www\.)?dailymotion\.com\/(video|embed\/video)\/([a-zA-Z0-9_-]+)/, _e = (e) => {
|
|
372
374
|
if (N.test(e)) {
|
|
373
375
|
const t = e.match(N);
|
|
374
376
|
return t ? `https://www.youtube.com/embed/${t[4]}` : e;
|
|
375
377
|
}
|
|
376
|
-
if (
|
|
377
|
-
const t = e.match(
|
|
378
|
+
if (M.test(e)) {
|
|
379
|
+
const t = e.match(M);
|
|
378
380
|
return t ? `https://player.vimeo.com/video/${t[3]}` : e;
|
|
379
381
|
}
|
|
380
382
|
if (H.test(e)) {
|
|
@@ -382,18 +384,18 @@ const N = /^(https?:\/\/)?(www\.)?youtube\.com\/(watch\?v=|embed\/)([a-zA-Z0-9_-
|
|
|
382
384
|
return t ? `https://www.dailymotion.com/embed/video/${t[4]}` : e;
|
|
383
385
|
}
|
|
384
386
|
return null;
|
|
385
|
-
},
|
|
387
|
+
}, Se = p.memo(
|
|
386
388
|
(e) => {
|
|
387
|
-
const { blockProps: t, inBuilder: l, styles: o, url:
|
|
388
|
-
if (k(
|
|
389
|
-
return /* @__PURE__ */
|
|
390
|
-
let f =
|
|
389
|
+
const { blockProps: t, inBuilder: l, styles: o, url: s, controls: a } = e, r = x(a, "autoPlay", !1), c = x(a, "controls", !1), u = r || x(a, "muted", !0), h = x(a, "loop", !1);
|
|
390
|
+
if (k(s))
|
|
391
|
+
return /* @__PURE__ */ n.jsx(v, { inBuilder: l, blockProps: t, text: "VIDEO URL", className: "h-36" });
|
|
392
|
+
let f = _e(s), m = null;
|
|
391
393
|
if (f) {
|
|
392
394
|
if (!k(f)) {
|
|
393
|
-
const
|
|
394
|
-
|
|
395
|
+
const T = [];
|
|
396
|
+
T.push(`autoplay=${r ? 1 : 0}`), T.push(`controls=${a ? 1 : 0}`), T.push(`mute=${u ? 1 : 0}&muted=${u ? 1 : 0}`), T.push(`loop=${h ? 1 : 0}`), f = `${f}?${T.join("&")}`;
|
|
395
397
|
}
|
|
396
|
-
|
|
398
|
+
m = p.createElement("iframe", {
|
|
397
399
|
...t,
|
|
398
400
|
className: "absolute inset-0 w-full h-full",
|
|
399
401
|
src: f,
|
|
@@ -402,34 +404,34 @@ const N = /^(https?:\/\/)?(www\.)?youtube\.com\/(watch\?v=|embed\/)([a-zA-Z0-9_-
|
|
|
402
404
|
frameBorder: 0
|
|
403
405
|
});
|
|
404
406
|
} else
|
|
405
|
-
|
|
407
|
+
m = p.createElement("video", {
|
|
406
408
|
...t,
|
|
407
409
|
className: "absolute inset-0 w-full h-full",
|
|
408
|
-
src:
|
|
410
|
+
src: s,
|
|
409
411
|
controls: c,
|
|
410
|
-
muted:
|
|
411
|
-
autoPlay: l ? !1 :
|
|
412
|
-
loop:
|
|
412
|
+
muted: u,
|
|
413
|
+
autoPlay: l ? !1 : r,
|
|
414
|
+
loop: h
|
|
413
415
|
});
|
|
414
|
-
return /* @__PURE__ */
|
|
415
|
-
l ? /* @__PURE__ */
|
|
416
|
-
|
|
416
|
+
return /* @__PURE__ */ n.jsx("div", { ...z(o, ["className"]), children: /* @__PURE__ */ n.jsxs("div", { className: "relative w-full overflow-hidden", style: { paddingBottom: "56.25%" }, children: [
|
|
417
|
+
l ? /* @__PURE__ */ n.jsx("div", { ...t, ...q(o, ["className"]), className: "absolute inset-0 z-20 h-full w-full" }) : null,
|
|
418
|
+
m
|
|
417
419
|
] }) });
|
|
418
420
|
}
|
|
419
421
|
);
|
|
420
|
-
d(
|
|
422
|
+
d(Se, {
|
|
421
423
|
type: "Video",
|
|
422
424
|
label: "Video",
|
|
423
425
|
category: "core",
|
|
424
|
-
icon:
|
|
426
|
+
icon: le,
|
|
425
427
|
group: "media",
|
|
426
428
|
props: {
|
|
427
429
|
styles: i({ default: "" }),
|
|
428
|
-
url:
|
|
430
|
+
url: y({
|
|
429
431
|
title: "Video URL",
|
|
430
432
|
default: "https://www.youtube.com/watch?v=9xwazD5SyVg&ab_channel=MaximilianMustermann"
|
|
431
433
|
}),
|
|
432
|
-
controls:
|
|
434
|
+
controls: G({
|
|
433
435
|
title: "Controls",
|
|
434
436
|
properties: {
|
|
435
437
|
autoPlay: b({ title: "Autoplay", default: !0 }),
|
|
@@ -440,128 +442,140 @@ d(Le, {
|
|
|
440
442
|
})
|
|
441
443
|
}
|
|
442
444
|
});
|
|
443
|
-
const
|
|
445
|
+
const je = p.memo(
|
|
444
446
|
(e) => {
|
|
445
|
-
const { blockProps: t, styles: l, content: o, inBuilder:
|
|
446
|
-
return /* @__PURE__ */
|
|
447
|
-
|
|
448
|
-
|
|
447
|
+
const { blockProps: t, styles: l, content: o, inBuilder: s } = e;
|
|
448
|
+
return /* @__PURE__ */ n.jsxs("div", { className: "relative", children: [
|
|
449
|
+
s ? /* @__PURE__ */ n.jsx("div", { ...t, ...l, className: "absolute z-20 h-full w-full" }) : null,
|
|
450
|
+
p.createElement("div", {
|
|
449
451
|
...l,
|
|
450
452
|
dangerouslySetInnerHTML: { __html: o }
|
|
451
453
|
})
|
|
452
454
|
] });
|
|
453
455
|
}
|
|
454
456
|
);
|
|
455
|
-
d(
|
|
457
|
+
d(je, {
|
|
456
458
|
type: "CustomHTML",
|
|
457
459
|
label: "Custom HTML",
|
|
458
460
|
category: "core",
|
|
459
|
-
icon:
|
|
461
|
+
icon: oe,
|
|
460
462
|
group: "advanced",
|
|
461
463
|
props: {
|
|
462
464
|
styles: i({ default: "" }),
|
|
463
|
-
content:
|
|
465
|
+
content: B({
|
|
464
466
|
title: "HTML Content",
|
|
465
467
|
default: "<div><p>HTML Snippet goes here...</p></div>",
|
|
466
468
|
placeholder: "Enter custom HTML code here"
|
|
467
469
|
})
|
|
468
470
|
}
|
|
469
471
|
});
|
|
470
|
-
const
|
|
472
|
+
const Ee = (e) => {
|
|
471
473
|
const { blockProps: t, styles: l } = e;
|
|
472
|
-
return
|
|
474
|
+
return p.createElement("hr", { ...l, ...t });
|
|
473
475
|
};
|
|
474
|
-
d(
|
|
476
|
+
d(Ee, {
|
|
475
477
|
type: "Divider",
|
|
476
478
|
label: "Divider",
|
|
477
479
|
category: "core",
|
|
478
|
-
icon:
|
|
480
|
+
icon: se,
|
|
479
481
|
group: "basic",
|
|
480
482
|
props: {
|
|
481
483
|
styles: i({ default: "bg-gray-900 h-0.5 py-2 my-1" })
|
|
482
484
|
}
|
|
483
485
|
});
|
|
484
|
-
const
|
|
485
|
-
d(
|
|
486
|
+
const Ce = (e) => e.inBuilder ? /* @__PURE__ */ n.jsx("span", { className: "inline-block", ...e.blockProps, children: e.content }) : `${e.content}`;
|
|
487
|
+
d(Ce, {
|
|
486
488
|
type: "Text",
|
|
487
489
|
label: "Text",
|
|
488
490
|
hidden: !0,
|
|
489
491
|
category: "core",
|
|
490
492
|
group: "typography",
|
|
491
|
-
icon:
|
|
493
|
+
icon: F,
|
|
492
494
|
props: {
|
|
493
|
-
content:
|
|
495
|
+
content: B({ title: "Content", defaultValue: "" })
|
|
494
496
|
}
|
|
495
497
|
});
|
|
496
498
|
const Pe = ({ children: e, blockProps: t, styles: l }) => {
|
|
497
|
-
const o =
|
|
498
|
-
return /* @__PURE__ */
|
|
499
|
+
const o = w(l, "hs-accordion-group");
|
|
500
|
+
return /* @__PURE__ */ n.jsx("div", { ...t, ...o, children: e });
|
|
499
501
|
};
|
|
500
502
|
d(Pe, {
|
|
501
|
-
type: "
|
|
502
|
-
label: "Accordion",
|
|
503
|
+
type: "AccordionGroup",
|
|
504
|
+
label: "Accordion Group",
|
|
503
505
|
category: "core",
|
|
504
506
|
group: "advanced",
|
|
505
|
-
hidden: !0,
|
|
506
507
|
props: {
|
|
507
508
|
styles: i({ default: "" })
|
|
508
509
|
},
|
|
509
510
|
// @ts-ignore
|
|
510
511
|
blocks: () => {
|
|
511
|
-
const e = "accordion" + g();
|
|
512
|
-
return
|
|
513
|
-
|
|
514
|
-
|
|
515
|
-
|
|
516
|
-
|
|
517
|
-
|
|
518
|
-
|
|
519
|
-
|
|
520
|
-
|
|
521
|
-
|
|
522
|
-
|
|
523
|
-
|
|
524
|
-
|
|
525
|
-
|
|
526
|
-
|
|
527
|
-
|
|
528
|
-
|
|
529
|
-
</
|
|
530
|
-
|
|
531
|
-
|
|
532
|
-
|
|
533
|
-
|
|
534
|
-
|
|
535
|
-
|
|
536
|
-
|
|
537
|
-
|
|
538
|
-
|
|
539
|
-
|
|
540
|
-
|
|
541
|
-
|
|
542
|
-
|
|
543
|
-
|
|
544
|
-
|
|
545
|
-
|
|
546
|
-
|
|
547
|
-
|
|
548
|
-
|
|
549
|
-
|
|
550
|
-
|
|
551
|
-
|
|
552
|
-
|
|
553
|
-
|
|
554
|
-
|
|
555
|
-
|
|
512
|
+
const e = "dnd-accordion-" + g();
|
|
513
|
+
return A(`<div class="hs-accordion-group">
|
|
514
|
+
<div class="hs-accordion active" id="hs-unstyled-heading-one">
|
|
515
|
+
<button class="hs-accordion-toggle" aria-controls="hs-unstyled-collapse-one">
|
|
516
|
+
Accordion #1
|
|
517
|
+
</button>
|
|
518
|
+
<div id="hs-unstyled-collapse-one" class="hs-accordion-content overflow-hidden transition-[height] duration-300" aria-labelledby="hs-unstyled-heading-one">
|
|
519
|
+
It is hidden by default, until the collapse plugin adds the appropriate classes that we use to style each element.
|
|
520
|
+
</div>
|
|
521
|
+
</div>
|
|
522
|
+
|
|
523
|
+
<div class="hs-accordion" id="hs-unstyled-heading-two">
|
|
524
|
+
<button class="hs-accordion-toggle" aria-controls="hs-unstyled-collapse-two">
|
|
525
|
+
Accordion #2
|
|
526
|
+
</button>
|
|
527
|
+
<div id="hs-unstyled-collapse-two" class="hs-accordion-content hidden overflow-hidden transition-[height] duration-300" aria-labelledby="hs-unstyled-heading-two">
|
|
528
|
+
It is hidden by default, until the collapse plugin adds the appropriate classes that we use to style each element.
|
|
529
|
+
</div>
|
|
530
|
+
</div>
|
|
531
|
+
</div>`.replace(/hs-unstyled-heading/g, e).replace(/hs-unstyled-collapse/g, e));
|
|
532
|
+
},
|
|
533
|
+
canAcceptBlock: (e) => e === "Accordion"
|
|
534
|
+
});
|
|
535
|
+
const Ae = ({ children: e, blockProps: t, styles: l, blockState: o }) => {
|
|
536
|
+
const s = w(
|
|
537
|
+
l,
|
|
538
|
+
"hs-accordion " + (o && o != null && o.active ? "active" : "")
|
|
539
|
+
);
|
|
540
|
+
return /* @__PURE__ */ n.jsx("div", { ...t, ...s, children: e });
|
|
541
|
+
};
|
|
542
|
+
d(Ae, {
|
|
543
|
+
type: "Accordion",
|
|
544
|
+
label: "Accordion",
|
|
545
|
+
category: "core",
|
|
546
|
+
group: "advanced",
|
|
547
|
+
props: { styles: i({ default: "" }) },
|
|
548
|
+
//@ts-ignore
|
|
549
|
+
customStylingStates: {
|
|
550
|
+
"hs-accordion-active": "Accordion Active"
|
|
551
|
+
},
|
|
552
|
+
//@ts-ignore
|
|
553
|
+
blockState: {
|
|
554
|
+
active: b({ default: !1, title: "Show content in canvas" })
|
|
555
|
+
},
|
|
556
|
+
getBlockStateFrom: (e) => [e._id],
|
|
557
|
+
// @ts-ignore
|
|
558
|
+
blocks: () => {
|
|
559
|
+
const e = "dnd-accordion-" + g();
|
|
560
|
+
return A(`
|
|
561
|
+
<div class="hs-accordion active" id="hs-unstyled-heading-one">
|
|
562
|
+
<button class="hs-accordion-toggle" aria-controls="hs-unstyled-collapse-one">
|
|
563
|
+
Accordion #1
|
|
564
|
+
</button>
|
|
565
|
+
<div id="hs-unstyled-collapse-one" class="hs-accordion-content overflow-hidden transition-[height] duration-300" aria-labelledby="hs-unstyled-heading-one">
|
|
566
|
+
It is hidden by default, until the collapse plugin adds the appropriate classes that we use to style each element.
|
|
567
|
+
</div>
|
|
568
|
+
</div>
|
|
569
|
+
`.replace(/hs-unstyled-heading/g, e).replace(/hs-unstyled-collapse/g, e));
|
|
556
570
|
}
|
|
557
571
|
});
|
|
558
|
-
const
|
|
559
|
-
const o =
|
|
560
|
-
return /* @__PURE__ */
|
|
572
|
+
const Ne = ({ children: e, blockProps: t, styles: l }) => {
|
|
573
|
+
const o = w(l, "hs-accordion-toggle");
|
|
574
|
+
return /* @__PURE__ */ n.jsx("button", { ...o, ...t, children: e });
|
|
561
575
|
};
|
|
562
|
-
d(
|
|
563
|
-
type: "
|
|
564
|
-
label: "Accordion
|
|
576
|
+
d(Ne, {
|
|
577
|
+
type: "AccordionToggle",
|
|
578
|
+
label: "Accordion Toggle",
|
|
565
579
|
category: "core",
|
|
566
580
|
group: "advanced",
|
|
567
581
|
hidden: !0,
|
|
@@ -575,9 +589,13 @@ d(Ce, {
|
|
|
575
589
|
canMove: () => !1,
|
|
576
590
|
canDuplicate: () => !1
|
|
577
591
|
});
|
|
578
|
-
const Me = ({ children: e, blockProps: t, styles: l }) => {
|
|
579
|
-
const
|
|
580
|
-
|
|
592
|
+
const Me = ({ children: e, blockProps: t, styles: l, blockState: o, inBuilder: s }) => {
|
|
593
|
+
const a = w(
|
|
594
|
+
l,
|
|
595
|
+
"hs-accordion-content",
|
|
596
|
+
s && o ? o != null && o.active ? "!block !opacity-100" : "!hidden !opacity-0" : ""
|
|
597
|
+
);
|
|
598
|
+
return /* @__PURE__ */ n.jsx("div", { ...a, ...t, children: e });
|
|
581
599
|
};
|
|
582
600
|
d(Me, {
|
|
583
601
|
type: "AccordionContent",
|
|
@@ -586,19 +604,74 @@ d(Me, {
|
|
|
586
604
|
group: "advanced",
|
|
587
605
|
hidden: !0,
|
|
588
606
|
props: {
|
|
589
|
-
styles: i({ default: "w-full overflow-hidden transition-
|
|
607
|
+
styles: i({ default: "w-full overflow-hidden transition-height hidden duration-300" })
|
|
590
608
|
},
|
|
609
|
+
//@ts-ignore
|
|
610
|
+
getBlockStateFrom: (e) => [e._parent],
|
|
591
611
|
canAcceptBlock: () => !0,
|
|
592
612
|
canDelete: () => !1,
|
|
593
613
|
canMove: () => !1,
|
|
594
614
|
canDuplicate: () => !1
|
|
595
615
|
});
|
|
596
|
-
const
|
|
597
|
-
const
|
|
616
|
+
const He = ({ children: e, blockProps: t, styles: l, blockState: o, inBuilder: s }) => {
|
|
617
|
+
const a = s && (o != null && o.active) ? " open" : "", r = w(l, "hs-collapse-toggle", a);
|
|
618
|
+
return /* @__PURE__ */ n.jsx("button", { type: "button", ...r, ...t, children: e });
|
|
619
|
+
};
|
|
620
|
+
d(He, {
|
|
621
|
+
type: "CollapseToggle",
|
|
622
|
+
label: "Collapse Toggle",
|
|
623
|
+
category: "core",
|
|
624
|
+
group: "advanced",
|
|
625
|
+
hidden: !0,
|
|
626
|
+
props: { styles: i({ default: "" }) },
|
|
627
|
+
canAcceptBlock: () => !0,
|
|
628
|
+
//@ts-ignore
|
|
629
|
+
customStylingStates: {
|
|
630
|
+
"hs-collapse-open": "Collapse Open"
|
|
631
|
+
},
|
|
632
|
+
// @ts-ignore
|
|
633
|
+
getBlockStateFrom: (e, t) => {
|
|
634
|
+
const l = x(e, "styles_attrs.data-hs-collapse", "").replace("#", "");
|
|
635
|
+
if (!l)
|
|
636
|
+
return [];
|
|
637
|
+
const o = O(t, (s) => x(s, "styles_attrs.id") === l);
|
|
638
|
+
return o ? [o == null ? void 0 : o._id] : [];
|
|
639
|
+
}
|
|
640
|
+
});
|
|
641
|
+
const Re = ({ children: e, blockProps: t, styles: l, blockState: o, inBuilder: s }) => {
|
|
642
|
+
const a = s ? { "!block !opacity-100 open": o == null ? void 0 : o.active, "hidden opacity-0": !(o != null && o.active) } : {}, r = Object.keys(a).filter((u) => a[u]).join(" "), c = w(l, "hs-collapse", r);
|
|
643
|
+
return /* @__PURE__ */ n.jsx("div", { ...c, ...t, children: e });
|
|
644
|
+
};
|
|
645
|
+
d(Re, {
|
|
646
|
+
type: "Collapse",
|
|
647
|
+
label: "Collapse",
|
|
648
|
+
category: "core",
|
|
649
|
+
group: "advanced",
|
|
650
|
+
props: {
|
|
651
|
+
styles: i({
|
|
652
|
+
default: "transition-opacity transition-margin duration hs-collapse-open:opacity-100 opacity-0 w-56 hidden z-10 mt-2 min-w-60 bg-white"
|
|
653
|
+
})
|
|
654
|
+
},
|
|
655
|
+
canAcceptBlock: () => !0,
|
|
656
|
+
//@ts-ignore
|
|
657
|
+
blockState: {
|
|
658
|
+
active: b({ default: !1, title: "Show collapse in canvas" })
|
|
659
|
+
},
|
|
660
|
+
getBlockStateFrom: (e) => [e._id],
|
|
661
|
+
// @ts-ignore
|
|
662
|
+
blocks: () => A(`<button type="button" class="hs-collapse-toggle" id="hs-unstyled-collapse" data-hs-collapse="#hs-unstyled-collapse-content">
|
|
663
|
+
Collapse
|
|
664
|
+
</button>
|
|
665
|
+
<div id="hs-unstyled-collapse-content" class="hs-collapse hidden w-full overflow-hidden transition-[height] duration-300" aria-labelledby="hs-unstyled-collapse">
|
|
666
|
+
This is a collapse body. It is hidden by default, until the collapse plugin adds the appropriate classes that we use to style each element. These classes control the overall appearance, as well as the showing and hiding via CSS transitions.
|
|
667
|
+
</div>`.replace(/hs-unstyled-collapse/g, `dnd-collapse-${g()}`))
|
|
668
|
+
});
|
|
669
|
+
const Fe = (e) => {
|
|
670
|
+
const { blockProps: t, backgroundImage: l, children: o, styles: s } = e;
|
|
598
671
|
let a = {};
|
|
599
|
-
return l && (a = { backgroundImage: `url(${l})` }),
|
|
672
|
+
return l && (a = { backgroundImage: `url(${l})` }), p.createElement("div", { ...t, ...s, style: a }, o);
|
|
600
673
|
};
|
|
601
|
-
d(
|
|
674
|
+
d(Fe, {
|
|
602
675
|
type: "Body",
|
|
603
676
|
label: "Body",
|
|
604
677
|
category: "core",
|
|
@@ -606,56 +679,56 @@ d(Ne, {
|
|
|
606
679
|
hidden: !0,
|
|
607
680
|
props: {
|
|
608
681
|
styles: i({ default: "font-body antialiased" }),
|
|
609
|
-
backgroundImage:
|
|
682
|
+
backgroundImage: C({ title: "Background Image" })
|
|
610
683
|
},
|
|
611
684
|
canAcceptBlock: () => !0,
|
|
612
685
|
canDelete: () => !1,
|
|
613
686
|
canMove: () => !1,
|
|
614
687
|
canDuplicate: () => !1
|
|
615
688
|
});
|
|
616
|
-
const
|
|
689
|
+
const De = (e) => {
|
|
617
690
|
const { blockProps: t, styles: l } = e;
|
|
618
|
-
return
|
|
691
|
+
return p.createElement("br", { ...t, ...l });
|
|
619
692
|
};
|
|
620
|
-
d(
|
|
693
|
+
d(De, {
|
|
621
694
|
type: "LineBreak",
|
|
622
695
|
label: "Line Break",
|
|
623
696
|
category: "core",
|
|
624
697
|
group: "basic",
|
|
625
698
|
hidden: !0,
|
|
626
|
-
icon:
|
|
699
|
+
icon: F,
|
|
627
700
|
props: {
|
|
628
701
|
styles: i({ default: "" })
|
|
629
702
|
}
|
|
630
703
|
});
|
|
631
|
-
const
|
|
632
|
-
const t = (a,
|
|
704
|
+
const j = (e) => {
|
|
705
|
+
const t = (a, r) => ({
|
|
633
706
|
_id: g(),
|
|
634
707
|
_parent: a,
|
|
635
708
|
_type: "TableCell",
|
|
636
709
|
styles: "#styles:,",
|
|
637
|
-
content: `${e === "TableHead" ? "Table Head" : "Table Cell " +
|
|
710
|
+
content: `${e === "TableHead" ? "Table Head" : "Table Cell " + r}`
|
|
638
711
|
}), l = (a) => {
|
|
639
|
-
const
|
|
712
|
+
const r = g(), c = {
|
|
640
713
|
_type: "TableRow",
|
|
641
|
-
_id:
|
|
714
|
+
_id: r,
|
|
642
715
|
styles: "#styles:,border-b"
|
|
643
716
|
};
|
|
644
|
-
return a && (c._parent = a), [c, t(
|
|
717
|
+
return a && (c._parent = a), [c, t(r, "1"), t(r, "2"), t(r, "3")];
|
|
645
718
|
}, o = (a) => {
|
|
646
|
-
const
|
|
647
|
-
_id:
|
|
719
|
+
const r = g(), c = {
|
|
720
|
+
_id: r,
|
|
648
721
|
_type: "TableHead",
|
|
649
722
|
styles: "#styles:,font-medium"
|
|
650
723
|
};
|
|
651
|
-
return a && (c._parent = a), [c, ...l(
|
|
652
|
-
},
|
|
653
|
-
const
|
|
654
|
-
_id:
|
|
724
|
+
return a && (c._parent = a), [c, ...l(r)];
|
|
725
|
+
}, s = (a) => {
|
|
726
|
+
const r = g(), c = {
|
|
727
|
+
_id: r,
|
|
655
728
|
_type: "TableBody",
|
|
656
729
|
styles: "#styles:,"
|
|
657
730
|
};
|
|
658
|
-
return a && (c._parent = a), [c, ...l(
|
|
731
|
+
return a && (c._parent = a), [c, ...l(r), ...l(r)];
|
|
659
732
|
};
|
|
660
733
|
if (e === "Table") {
|
|
661
734
|
const a = g();
|
|
@@ -666,188 +739,188 @@ const S = (e) => {
|
|
|
666
739
|
styles: "#styles:,w-full text-left text-gray-500 dark:text-gray-400"
|
|
667
740
|
},
|
|
668
741
|
...o(a),
|
|
669
|
-
...
|
|
742
|
+
...s(a)
|
|
670
743
|
];
|
|
671
744
|
}
|
|
672
|
-
return e === "TableRow" ? l() : e === "TableHead" ? o() : e === "TableBody" ?
|
|
673
|
-
},
|
|
745
|
+
return e === "TableRow" ? l() : e === "TableHead" ? o() : e === "TableBody" ? s() : [];
|
|
746
|
+
}, $e = (e) => {
|
|
674
747
|
const { blockProps: t, children: l, styles: o } = e;
|
|
675
|
-
return l ?
|
|
748
|
+
return l ? p.createElement("table", { ...t, ...o }, l) : /* @__PURE__ */ n.jsx(v, { blockProps: t, text: "TABLE HEAD / BODY" });
|
|
676
749
|
};
|
|
677
|
-
d(
|
|
750
|
+
d($e, {
|
|
678
751
|
type: "Table",
|
|
679
752
|
label: "Table",
|
|
680
753
|
category: "core",
|
|
681
754
|
group: "table",
|
|
682
755
|
hidden: !0,
|
|
683
|
-
icon:
|
|
756
|
+
icon: ae,
|
|
684
757
|
props: {
|
|
685
758
|
styles: i({ default: "" })
|
|
686
759
|
},
|
|
687
|
-
blocks:
|
|
760
|
+
blocks: j("Table")
|
|
688
761
|
});
|
|
689
|
-
const
|
|
762
|
+
const ze = (e) => {
|
|
690
763
|
const { blockProps: t, children: l, styles: o } = e;
|
|
691
|
-
return l ?
|
|
764
|
+
return l ? p.createElement("thead", { ...t, ...o }, l) : /* @__PURE__ */ n.jsx(v, { blockProps: t, text: "TABLE ROW" });
|
|
692
765
|
};
|
|
693
|
-
d(
|
|
766
|
+
d(ze, {
|
|
694
767
|
type: "TableHead",
|
|
695
768
|
label: "Table Head",
|
|
696
769
|
category: "core",
|
|
697
770
|
group: "table",
|
|
698
771
|
hidden: !0,
|
|
699
|
-
icon:
|
|
772
|
+
icon: ne,
|
|
700
773
|
props: {
|
|
701
774
|
styles: i({ default: "" })
|
|
702
775
|
},
|
|
703
|
-
blocks:
|
|
776
|
+
blocks: j("TableHead")
|
|
704
777
|
});
|
|
705
|
-
const
|
|
778
|
+
const qe = (e) => {
|
|
706
779
|
const { blockProps: t, children: l, styles: o } = e;
|
|
707
|
-
return l ?
|
|
780
|
+
return l ? p.createElement("tbody", { ...t, ...o }, l) : /* @__PURE__ */ n.jsx(v, { blockProps: t, text: "TABLE ROW" });
|
|
708
781
|
};
|
|
709
|
-
d(
|
|
782
|
+
d(qe, {
|
|
710
783
|
type: "TableBody",
|
|
711
784
|
label: "Table Body",
|
|
712
785
|
category: "core",
|
|
713
786
|
group: "table",
|
|
714
787
|
hidden: !0,
|
|
715
|
-
icon:
|
|
788
|
+
icon: re,
|
|
716
789
|
props: {
|
|
717
790
|
styles: i({ default: "" })
|
|
718
791
|
},
|
|
719
|
-
blocks:
|
|
792
|
+
blocks: j("TableBody")
|
|
720
793
|
});
|
|
721
|
-
const
|
|
794
|
+
const Oe = (e) => {
|
|
722
795
|
const { blockProps: t, children: l, styles: o } = e;
|
|
723
|
-
return l ?
|
|
796
|
+
return l ? p.createElement("tr", { ...t, ...o }, l) : /* @__PURE__ */ n.jsx(v, { blockProps: t, text: "TABLE CELL" });
|
|
724
797
|
};
|
|
725
|
-
d(
|
|
798
|
+
d(Oe, {
|
|
726
799
|
type: "TableRow",
|
|
727
800
|
label: "Table Row",
|
|
728
801
|
category: "core",
|
|
729
802
|
group: "table",
|
|
730
803
|
hidden: !0,
|
|
731
|
-
icon:
|
|
804
|
+
icon: ce,
|
|
732
805
|
props: {
|
|
733
806
|
styles: i({ default: "w-full" })
|
|
734
807
|
},
|
|
735
|
-
blocks:
|
|
808
|
+
blocks: j("TableRow")
|
|
736
809
|
});
|
|
737
|
-
const
|
|
738
|
-
const { blockProps: t, children: l, content: o, styles:
|
|
739
|
-
return !l && k(o) ? /* @__PURE__ */
|
|
810
|
+
const Ve = (e) => {
|
|
811
|
+
const { blockProps: t, children: l, content: o, styles: s } = e;
|
|
812
|
+
return !l && k(o) ? /* @__PURE__ */ n.jsx(v, { blockProps: t }) : l ? p.createElement("td", { ...t, ...s }, l) : p.createElement("td", {
|
|
740
813
|
...t,
|
|
741
|
-
...
|
|
814
|
+
...s,
|
|
742
815
|
dangerouslySetInnerHTML: { __html: o }
|
|
743
816
|
});
|
|
744
817
|
};
|
|
745
|
-
d(
|
|
818
|
+
d(Ve, {
|
|
746
819
|
type: "TableCell",
|
|
747
820
|
label: "Table Cell",
|
|
748
821
|
category: "core",
|
|
749
822
|
group: "table",
|
|
750
823
|
hidden: !0,
|
|
751
|
-
icon:
|
|
824
|
+
icon: ie,
|
|
752
825
|
props: {
|
|
753
826
|
styles: i({ default: "" }),
|
|
754
|
-
content:
|
|
827
|
+
content: L({ title: "Content", default: "Table cell item" })
|
|
755
828
|
}
|
|
756
829
|
});
|
|
757
|
-
const
|
|
758
|
-
const { blockProps: t, errorMessage: l, name: o, _type:
|
|
759
|
-
let
|
|
760
|
-
|
|
830
|
+
const Ue = (e) => {
|
|
831
|
+
const { blockProps: t, errorMessage: l, name: o, _type: s, successMessage: a, action: r, styles: c, children: u } = e;
|
|
832
|
+
let h = u;
|
|
833
|
+
u || (h = /* @__PURE__ */ n.jsx(v, { blockProps: {}, text: "FORM FIELDS" }));
|
|
761
834
|
const f = {
|
|
762
835
|
"x-data": "useForm",
|
|
763
836
|
"x-on:submit.prevent": "post"
|
|
764
|
-
},
|
|
837
|
+
}, m = {
|
|
765
838
|
"x-html": "formResponse",
|
|
766
839
|
":class": "{'text-red-500': formStatus === 'ERROR', 'text-green-500': formStatus === 'SUCCESS'}"
|
|
767
840
|
};
|
|
768
|
-
return /* @__PURE__ */
|
|
841
|
+
return /* @__PURE__ */ n.jsxs(
|
|
769
842
|
"form",
|
|
770
843
|
{
|
|
771
844
|
...f,
|
|
772
845
|
"data-error": l,
|
|
773
846
|
"data-success": a,
|
|
774
847
|
method: "post",
|
|
775
|
-
action:
|
|
848
|
+
action: r,
|
|
776
849
|
...t,
|
|
777
850
|
...c,
|
|
778
851
|
children: [
|
|
779
|
-
/* @__PURE__ */
|
|
780
|
-
/* @__PURE__ */
|
|
781
|
-
|
|
852
|
+
/* @__PURE__ */ n.jsx("div", { ...m }),
|
|
853
|
+
/* @__PURE__ */ n.jsx("input", { name: "formname", type: "hidden", value: o || s }),
|
|
854
|
+
h
|
|
782
855
|
]
|
|
783
856
|
}
|
|
784
857
|
);
|
|
785
858
|
};
|
|
786
|
-
d(
|
|
859
|
+
d(Ue, {
|
|
787
860
|
type: "Form",
|
|
788
861
|
label: "Form",
|
|
789
862
|
category: "core",
|
|
790
|
-
icon:
|
|
863
|
+
icon: de,
|
|
791
864
|
group: "form",
|
|
792
865
|
hidden: !0,
|
|
793
866
|
props: {
|
|
794
867
|
styles: i({ default: "" }),
|
|
795
|
-
action:
|
|
868
|
+
action: y({
|
|
796
869
|
title: "Submit URL",
|
|
797
870
|
default: "/api/form/submit"
|
|
798
871
|
}),
|
|
799
|
-
errorMessage:
|
|
872
|
+
errorMessage: L({
|
|
800
873
|
title: "Error Message",
|
|
801
874
|
default: "Something went wrong. Please try again"
|
|
802
875
|
}),
|
|
803
|
-
successMessage:
|
|
876
|
+
successMessage: L({
|
|
804
877
|
title: "Success Message",
|
|
805
878
|
default: "Thank you for your submission."
|
|
806
879
|
})
|
|
807
880
|
},
|
|
808
881
|
canAcceptBlock: () => !0
|
|
809
882
|
});
|
|
810
|
-
const
|
|
811
|
-
const { blockProps: t, content: l, styles: o, children:
|
|
812
|
-
return
|
|
883
|
+
const Ge = (e) => {
|
|
884
|
+
const { blockProps: t, content: l, styles: o, children: s } = e, a = { ...o, ...t };
|
|
885
|
+
return s ? p.createElement("label", a, s) : p.createElement("label", {
|
|
813
886
|
...a,
|
|
814
887
|
dangerouslySetInnerHTML: { __html: l }
|
|
815
888
|
});
|
|
816
889
|
};
|
|
817
|
-
d(
|
|
890
|
+
d(Ge, {
|
|
818
891
|
type: "Label",
|
|
819
892
|
label: "Label",
|
|
820
893
|
category: "core",
|
|
821
|
-
icon:
|
|
894
|
+
icon: ue,
|
|
822
895
|
group: "form",
|
|
823
896
|
hidden: !0,
|
|
824
897
|
props: {
|
|
825
898
|
styles: i({ default: "" }),
|
|
826
|
-
content:
|
|
899
|
+
content: y({ title: "Content", default: "Label" })
|
|
827
900
|
}
|
|
828
901
|
});
|
|
829
|
-
const
|
|
830
|
-
const { blockProps: t, inBuilder: l, label: o, placeholder:
|
|
902
|
+
const We = (e) => {
|
|
903
|
+
const { blockProps: t, inBuilder: l, label: o, placeholder: s, styles: a, inputStyles: r, icon: c, iconPos: u } = e, h = g(), f = {
|
|
831
904
|
"x-bind:disabled": "formLoading"
|
|
832
905
|
};
|
|
833
|
-
return /* @__PURE__ */
|
|
906
|
+
return /* @__PURE__ */ n.jsxs(
|
|
834
907
|
"button",
|
|
835
908
|
{
|
|
836
|
-
id:
|
|
909
|
+
id: h,
|
|
837
910
|
...f,
|
|
838
|
-
...
|
|
911
|
+
...r,
|
|
839
912
|
...a,
|
|
840
913
|
...t || {},
|
|
841
914
|
type: l ? "button" : "submit",
|
|
842
|
-
placeholder:
|
|
915
|
+
placeholder: s,
|
|
843
916
|
children: [
|
|
844
917
|
o,
|
|
845
|
-
c && /* @__PURE__ */
|
|
918
|
+
c && /* @__PURE__ */ n.jsx("span", { className: u, dangerouslySetInnerHTML: { __html: c } })
|
|
846
919
|
]
|
|
847
920
|
}
|
|
848
921
|
);
|
|
849
922
|
};
|
|
850
|
-
d(
|
|
923
|
+
d(We, {
|
|
851
924
|
type: "FormButton",
|
|
852
925
|
label: "Submit Button",
|
|
853
926
|
category: "core",
|
|
@@ -855,12 +928,12 @@ d(Oe, {
|
|
|
855
928
|
group: "form",
|
|
856
929
|
hidden: !0,
|
|
857
930
|
props: {
|
|
858
|
-
label:
|
|
931
|
+
label: y({ title: "Label", default: "Submit" }),
|
|
859
932
|
styles: i({
|
|
860
933
|
default: "text-white bg-primary disabled:bg-gray-400 px-4 py-2 rounded-global flex items-center gap-x-2"
|
|
861
934
|
}),
|
|
862
|
-
icon:
|
|
863
|
-
iconPos:
|
|
935
|
+
icon: P({ title: "Icon", default: "" }),
|
|
936
|
+
iconPos: I({
|
|
864
937
|
title: "Icon Position",
|
|
865
938
|
default: "order-last",
|
|
866
939
|
options: [
|
|
@@ -870,102 +943,102 @@ d(Oe, {
|
|
|
870
943
|
})
|
|
871
944
|
}
|
|
872
945
|
});
|
|
873
|
-
const
|
|
874
|
-
const { blockProps: t, fieldName: l, label: o, styles:
|
|
875
|
-
return
|
|
876
|
-
/* @__PURE__ */
|
|
946
|
+
const Ye = (e) => {
|
|
947
|
+
const { blockProps: t, fieldName: l, label: o, styles: s, inputStyles: a, required: r, checked: c, showLabel: u = !0 } = e, h = g();
|
|
948
|
+
return u ? /* @__PURE__ */ n.jsxs("div", { ...s, ...t, children: [
|
|
949
|
+
/* @__PURE__ */ n.jsx(
|
|
877
950
|
"input",
|
|
878
951
|
{
|
|
879
952
|
...a,
|
|
880
953
|
name: l,
|
|
881
|
-
id:
|
|
954
|
+
id: h,
|
|
882
955
|
type: "checkbox",
|
|
883
|
-
required:
|
|
956
|
+
required: r,
|
|
884
957
|
defaultChecked: c
|
|
885
958
|
}
|
|
886
959
|
),
|
|
887
|
-
o && o !== "Label" && /* @__PURE__ */
|
|
888
|
-
] }) : /* @__PURE__ */
|
|
960
|
+
o && o !== "Label" && /* @__PURE__ */ n.jsx("label", { htmlFor: h, children: o })
|
|
961
|
+
] }) : /* @__PURE__ */ n.jsx(
|
|
889
962
|
"input",
|
|
890
963
|
{
|
|
891
|
-
id:
|
|
964
|
+
id: h,
|
|
892
965
|
...t,
|
|
893
966
|
...a,
|
|
894
|
-
...
|
|
967
|
+
...s,
|
|
895
968
|
type: "checkbox",
|
|
896
|
-
required:
|
|
969
|
+
required: r,
|
|
897
970
|
name: l
|
|
898
971
|
}
|
|
899
972
|
);
|
|
900
973
|
};
|
|
901
|
-
d(
|
|
974
|
+
d(Ye, {
|
|
902
975
|
type: "Checkbox",
|
|
903
976
|
label: "Checkbox",
|
|
904
977
|
category: "core",
|
|
905
|
-
icon:
|
|
978
|
+
icon: pe,
|
|
906
979
|
group: "form",
|
|
907
980
|
hidden: !0,
|
|
908
981
|
props: {
|
|
909
|
-
fieldName:
|
|
982
|
+
fieldName: y({ title: "Field Name", default: "checkbox" }),
|
|
910
983
|
styles: i({ default: "flex items-center gap-x-2" }),
|
|
911
|
-
label:
|
|
984
|
+
label: y({ title: "Label", default: "Label" }),
|
|
912
985
|
checked: b({ title: "Checked", default: !1 }),
|
|
913
986
|
required: b({ title: "Required", default: !1 })
|
|
914
987
|
}
|
|
915
988
|
});
|
|
916
|
-
const
|
|
989
|
+
const Xe = (e) => {
|
|
917
990
|
const {
|
|
918
991
|
blockProps: t,
|
|
919
992
|
label: l,
|
|
920
993
|
placeholder: o,
|
|
921
|
-
styles:
|
|
994
|
+
styles: s,
|
|
922
995
|
inputStyles: a,
|
|
923
|
-
showLabel:
|
|
996
|
+
showLabel: r,
|
|
924
997
|
required: c,
|
|
925
|
-
inputType:
|
|
926
|
-
inBuilder:
|
|
998
|
+
inputType: u = "text",
|
|
999
|
+
inBuilder: h,
|
|
927
1000
|
fieldName: f
|
|
928
|
-
} = e,
|
|
929
|
-
return !
|
|
1001
|
+
} = e, m = g();
|
|
1002
|
+
return !r || u === "submit" ? (u === "submit" && (t.value = l), /* @__PURE__ */ n.jsx(
|
|
930
1003
|
"input",
|
|
931
1004
|
{
|
|
932
|
-
id:
|
|
1005
|
+
id: m,
|
|
933
1006
|
name: f,
|
|
934
|
-
readOnly:
|
|
1007
|
+
readOnly: h,
|
|
935
1008
|
...t,
|
|
936
1009
|
...a,
|
|
937
|
-
...
|
|
938
|
-
type:
|
|
1010
|
+
...s,
|
|
1011
|
+
type: u,
|
|
939
1012
|
placeholder: o,
|
|
940
1013
|
required: c
|
|
941
1014
|
}
|
|
942
|
-
)) : /* @__PURE__ */
|
|
943
|
-
|
|
944
|
-
/* @__PURE__ */
|
|
1015
|
+
)) : /* @__PURE__ */ n.jsxs("div", { ...s, ...t, children: [
|
|
1016
|
+
r && /* @__PURE__ */ n.jsx("label", { htmlFor: m, children: l }),
|
|
1017
|
+
/* @__PURE__ */ n.jsx(
|
|
945
1018
|
"input",
|
|
946
1019
|
{
|
|
947
1020
|
name: f,
|
|
948
|
-
readOnly:
|
|
1021
|
+
readOnly: h,
|
|
949
1022
|
...a,
|
|
950
|
-
id:
|
|
951
|
-
type:
|
|
1023
|
+
id: m,
|
|
1024
|
+
type: u,
|
|
952
1025
|
placeholder: o,
|
|
953
1026
|
required: c
|
|
954
1027
|
}
|
|
955
1028
|
)
|
|
956
1029
|
] });
|
|
957
1030
|
};
|
|
958
|
-
d(
|
|
1031
|
+
d(Xe, {
|
|
959
1032
|
type: "Input",
|
|
960
1033
|
label: "Input",
|
|
961
1034
|
category: "core",
|
|
962
|
-
icon:
|
|
1035
|
+
icon: D,
|
|
963
1036
|
group: "form",
|
|
964
1037
|
hidden: !0,
|
|
965
1038
|
props: {
|
|
966
1039
|
styles: i({ default: "" }),
|
|
967
|
-
fieldName:
|
|
968
|
-
inputType:
|
|
1040
|
+
fieldName: y({ title: "Field Name", default: "input" }),
|
|
1041
|
+
inputType: I({
|
|
969
1042
|
title: "Type",
|
|
970
1043
|
options: E(
|
|
971
1044
|
["text", "email", "password", "number", "tel", "file", "hidden", "range", "submit", "color", "date", "time"],
|
|
@@ -976,180 +1049,180 @@ d(Ue, {
|
|
|
976
1049
|
),
|
|
977
1050
|
default: "text"
|
|
978
1051
|
}),
|
|
979
|
-
value:
|
|
1052
|
+
value: y({ title: "Value", default: "" }),
|
|
980
1053
|
showLabel: b({ title: "Show label", default: !0 }),
|
|
981
1054
|
inputStyles: i({ default: "w-full p-1" }),
|
|
982
|
-
label:
|
|
983
|
-
placeholder:
|
|
1055
|
+
label: y({ title: "Label", default: "Label" }),
|
|
1056
|
+
placeholder: y({
|
|
984
1057
|
title: "Placeholder",
|
|
985
1058
|
default: "Placeholder"
|
|
986
1059
|
}),
|
|
987
1060
|
required: b({ title: "Required", default: !1 })
|
|
988
1061
|
}
|
|
989
1062
|
});
|
|
990
|
-
const
|
|
991
|
-
const { blockProps: t, fieldName: l, label: o, styles:
|
|
992
|
-
return
|
|
993
|
-
/* @__PURE__ */
|
|
994
|
-
o && /* @__PURE__ */
|
|
995
|
-
] }) : /* @__PURE__ */
|
|
1063
|
+
const Ze = (e) => {
|
|
1064
|
+
const { blockProps: t, fieldName: l, label: o, styles: s, inputStyles: a, checked: r, required: c, showLabel: u = !0 } = e, h = g();
|
|
1065
|
+
return u ? /* @__PURE__ */ n.jsxs("div", { ...s, ...t, children: [
|
|
1066
|
+
/* @__PURE__ */ n.jsx("input", { ...a, name: l, id: h, type: "radio", required: c, defaultChecked: r }),
|
|
1067
|
+
o && /* @__PURE__ */ n.jsx("label", { htmlFor: h, children: o })
|
|
1068
|
+
] }) : /* @__PURE__ */ n.jsx(
|
|
996
1069
|
"input",
|
|
997
1070
|
{
|
|
998
|
-
id:
|
|
1071
|
+
id: h,
|
|
999
1072
|
...t,
|
|
1000
1073
|
...a,
|
|
1001
|
-
...
|
|
1074
|
+
...s,
|
|
1002
1075
|
type: "radio",
|
|
1003
1076
|
required: c,
|
|
1004
|
-
checked:
|
|
1077
|
+
checked: r,
|
|
1005
1078
|
name: l
|
|
1006
1079
|
}
|
|
1007
1080
|
);
|
|
1008
1081
|
};
|
|
1009
|
-
d(
|
|
1082
|
+
d(Ze, {
|
|
1010
1083
|
type: "Radio",
|
|
1011
1084
|
label: "Radio",
|
|
1012
1085
|
category: "core",
|
|
1013
|
-
icon:
|
|
1086
|
+
icon: he,
|
|
1014
1087
|
group: "form",
|
|
1015
1088
|
hidden: !0,
|
|
1016
1089
|
props: {
|
|
1017
1090
|
styles: i({ default: "flex items-center w-max gap-x-2" }),
|
|
1018
|
-
fieldName:
|
|
1019
|
-
label:
|
|
1091
|
+
fieldName: y({ title: "Field Name", default: "radio" }),
|
|
1092
|
+
label: y({ title: "Label", default: "Label" }),
|
|
1020
1093
|
checked: b({ title: "Checked", default: !1 }),
|
|
1021
1094
|
required: b({ title: "Required", default: !1 })
|
|
1022
1095
|
}
|
|
1023
1096
|
});
|
|
1024
|
-
const
|
|
1097
|
+
const Je = (e) => {
|
|
1025
1098
|
const {
|
|
1026
1099
|
blockProps: t,
|
|
1027
1100
|
fieldName: l,
|
|
1028
1101
|
label: o,
|
|
1029
|
-
placeholder:
|
|
1102
|
+
placeholder: s,
|
|
1030
1103
|
styles: a,
|
|
1031
|
-
inputStyles:
|
|
1104
|
+
inputStyles: r,
|
|
1032
1105
|
required: c,
|
|
1033
|
-
showLabel:
|
|
1034
|
-
_multiple:
|
|
1106
|
+
showLabel: u,
|
|
1107
|
+
_multiple: h = !1
|
|
1035
1108
|
} = e, f = g();
|
|
1036
|
-
return
|
|
1037
|
-
|
|
1038
|
-
/* @__PURE__ */
|
|
1109
|
+
return u ? /* @__PURE__ */ n.jsxs("div", { ...a, children: [
|
|
1110
|
+
u && /* @__PURE__ */ n.jsx("label", { htmlFor: f, children: o }),
|
|
1111
|
+
/* @__PURE__ */ n.jsxs(
|
|
1039
1112
|
"select",
|
|
1040
1113
|
{
|
|
1041
|
-
...
|
|
1114
|
+
...r,
|
|
1042
1115
|
id: f,
|
|
1043
|
-
placeholder:
|
|
1116
|
+
placeholder: s,
|
|
1044
1117
|
required: c,
|
|
1045
|
-
multiple:
|
|
1118
|
+
multiple: h,
|
|
1046
1119
|
name: l,
|
|
1047
1120
|
children: [
|
|
1048
|
-
/* @__PURE__ */
|
|
1049
|
-
E(e.options, (
|
|
1121
|
+
/* @__PURE__ */ n.jsx("option", { value: "", disabled: !0, selected: !0, hidden: !0, children: s }),
|
|
1122
|
+
E(e.options, (m) => /* @__PURE__ */ n.jsx(
|
|
1050
1123
|
"option",
|
|
1051
1124
|
{
|
|
1052
|
-
selected:
|
|
1053
|
-
value:
|
|
1054
|
-
dangerouslySetInnerHTML: { __html:
|
|
1125
|
+
selected: x(m, "selected", !1),
|
|
1126
|
+
value: m.value,
|
|
1127
|
+
dangerouslySetInnerHTML: { __html: m.label }
|
|
1055
1128
|
},
|
|
1056
|
-
|
|
1129
|
+
m.value
|
|
1057
1130
|
))
|
|
1058
1131
|
]
|
|
1059
1132
|
}
|
|
1060
1133
|
)
|
|
1061
|
-
] }) : /* @__PURE__ */
|
|
1134
|
+
] }) : /* @__PURE__ */ n.jsxs(
|
|
1062
1135
|
"select",
|
|
1063
1136
|
{
|
|
1064
1137
|
id: f,
|
|
1065
1138
|
...a,
|
|
1066
1139
|
...t,
|
|
1067
|
-
placeholder:
|
|
1140
|
+
placeholder: s,
|
|
1068
1141
|
required: c,
|
|
1069
|
-
multiple:
|
|
1142
|
+
multiple: h,
|
|
1070
1143
|
name: l,
|
|
1071
1144
|
children: [
|
|
1072
|
-
/* @__PURE__ */
|
|
1073
|
-
E(e.options, (
|
|
1145
|
+
/* @__PURE__ */ n.jsx("option", { value: "", disabled: !0, selected: !0, hidden: !0, children: s }),
|
|
1146
|
+
E(e.options, (m) => /* @__PURE__ */ n.jsx(
|
|
1074
1147
|
"option",
|
|
1075
1148
|
{
|
|
1076
|
-
selected:
|
|
1077
|
-
value:
|
|
1078
|
-
dangerouslySetInnerHTML: { __html:
|
|
1149
|
+
selected: x(m, "selected", !1),
|
|
1150
|
+
value: m.value,
|
|
1151
|
+
dangerouslySetInnerHTML: { __html: m.label }
|
|
1079
1152
|
},
|
|
1080
|
-
|
|
1153
|
+
m.value
|
|
1081
1154
|
))
|
|
1082
1155
|
]
|
|
1083
1156
|
}
|
|
1084
1157
|
);
|
|
1085
1158
|
};
|
|
1086
|
-
d(
|
|
1159
|
+
d(Je, {
|
|
1087
1160
|
type: "Select",
|
|
1088
1161
|
label: "Select",
|
|
1089
1162
|
category: "core",
|
|
1090
|
-
icon:
|
|
1163
|
+
icon: ye,
|
|
1091
1164
|
group: "form",
|
|
1092
1165
|
hidden: !0,
|
|
1093
1166
|
props: {
|
|
1094
1167
|
styles: i({ default: "" }),
|
|
1095
|
-
fieldName:
|
|
1168
|
+
fieldName: y({ title: "Field Name", default: "select" }),
|
|
1096
1169
|
showLabel: b({ title: "Show label", default: !0 }),
|
|
1097
1170
|
inputStyles: i({ default: "w-full p-1" }),
|
|
1098
|
-
label:
|
|
1099
|
-
placeholder:
|
|
1171
|
+
label: y({ title: "Label", default: "Label" }),
|
|
1172
|
+
placeholder: y({
|
|
1100
1173
|
title: "Placeholder",
|
|
1101
1174
|
default: "Placeholder"
|
|
1102
1175
|
}),
|
|
1103
1176
|
required: b({ title: "Required", default: !1 }),
|
|
1104
1177
|
_multiple: b({ title: "Multiple Choice", default: !1 }),
|
|
1105
|
-
options:
|
|
1178
|
+
options: W({
|
|
1106
1179
|
title: "Options",
|
|
1107
1180
|
itemProperties: {
|
|
1108
|
-
label:
|
|
1109
|
-
value:
|
|
1181
|
+
label: y({ title: "Label", default: "" }),
|
|
1182
|
+
value: y({ title: "Value", default: "" })
|
|
1110
1183
|
}
|
|
1111
1184
|
})
|
|
1112
1185
|
}
|
|
1113
1186
|
});
|
|
1114
|
-
const
|
|
1115
|
-
const { blockProps: t, fieldName: l, label: o, placeholder:
|
|
1116
|
-
return
|
|
1117
|
-
|
|
1118
|
-
/* @__PURE__ */
|
|
1119
|
-
] }) : /* @__PURE__ */
|
|
1187
|
+
const Ke = (e) => {
|
|
1188
|
+
const { blockProps: t, fieldName: l, label: o, placeholder: s, styles: a, inputStyles: r, _rows: c, showLabel: u } = e, h = g();
|
|
1189
|
+
return u ? /* @__PURE__ */ n.jsxs("div", { ...a, ...t, children: [
|
|
1190
|
+
u && /* @__PURE__ */ n.jsx("label", { htmlFor: h, children: o }),
|
|
1191
|
+
/* @__PURE__ */ n.jsx("textarea", { name: l, ...r, id: h, placeholder: s, rows: c })
|
|
1192
|
+
] }) : /* @__PURE__ */ n.jsx(
|
|
1120
1193
|
"textarea",
|
|
1121
1194
|
{
|
|
1122
|
-
id:
|
|
1195
|
+
id: h,
|
|
1123
1196
|
name: l,
|
|
1124
1197
|
...t,
|
|
1125
|
-
...
|
|
1198
|
+
...r,
|
|
1126
1199
|
...a,
|
|
1127
|
-
placeholder:
|
|
1200
|
+
placeholder: s,
|
|
1128
1201
|
rows: c
|
|
1129
1202
|
}
|
|
1130
1203
|
);
|
|
1131
1204
|
};
|
|
1132
|
-
d(
|
|
1205
|
+
d(Ke, {
|
|
1133
1206
|
type: "TextArea",
|
|
1134
1207
|
label: "TextArea",
|
|
1135
1208
|
category: "core",
|
|
1136
|
-
icon:
|
|
1209
|
+
icon: D,
|
|
1137
1210
|
group: "form",
|
|
1138
1211
|
hidden: !0,
|
|
1139
1212
|
props: {
|
|
1140
|
-
fieldName:
|
|
1213
|
+
fieldName: y({ title: "Field Name", default: "textarea" }),
|
|
1141
1214
|
showLabel: b({ title: "Show label", default: !0 }),
|
|
1142
1215
|
styles: i({ default: "" }),
|
|
1143
1216
|
inputStyles: i({ default: "w-full p-1" }),
|
|
1144
|
-
label:
|
|
1145
|
-
placeholder:
|
|
1217
|
+
label: y({ title: "Label", default: "Label" }),
|
|
1218
|
+
placeholder: y({
|
|
1146
1219
|
title: "Placeholder",
|
|
1147
1220
|
default: "Placeholder"
|
|
1148
1221
|
}),
|
|
1149
|
-
_rows:
|
|
1222
|
+
_rows: _({ title: "Rows", default: 3 })
|
|
1150
1223
|
}
|
|
1151
1224
|
});
|
|
1152
|
-
const
|
|
1225
|
+
const pt = V;
|
|
1153
1226
|
export {
|
|
1154
|
-
|
|
1227
|
+
pt as loadWebBlocks
|
|
1155
1228
|
};
|