@simple-builder/react 1.0.0 → 1.0.2
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/Roboto-Black-N3JSMGNF.ttf +0 -0
- package/dist/Roboto-BlackItalic-Q4DQVNXP.ttf +0 -0
- package/dist/Roboto-Bold-YNVD7YCC.ttf +0 -0
- package/dist/Roboto-BoldItalic-UDVRGYMT.ttf +0 -0
- package/dist/Roboto-Italic-P4UPYB3F.ttf +0 -0
- package/dist/Roboto-Light-DLKQXCNL.ttf +0 -0
- package/dist/Roboto-LightItalic-EZWBKOF2.ttf +0 -0
- package/dist/Roboto-Medium-SICMFKQK.ttf +0 -0
- package/dist/Roboto-MediumItalic-X7VW5CZA.ttf +0 -0
- package/dist/Roboto-Regular-2C6IPKAZ.ttf +0 -0
- package/dist/Roboto-Thin-SNTZUTYN.ttf +0 -0
- package/dist/Roboto-ThinItalic-VWZDITN2.ttf +0 -0
- package/dist/{build-container-client-JPFTBMJ3.js → build-container-client-LHGW2FFR.js} +203 -190
- package/dist/{build-container-client-FBOVSG6E.mjs → build-container-client-SL4TZBOD.mjs} +158 -145
- package/dist/{builder-content-XP2KWHHT.js → builder-content-66LHSBUX.js} +7 -7
- package/dist/{builder-content-I65E3YF2.mjs → builder-content-FCQHSHSY.mjs} +3 -3
- package/dist/{chunk-TEAHH2DG.js → chunk-3S4FFEHM.js} +11 -8
- package/dist/{chunk-4CD23J5W.js → chunk-5ZDNACOH.js} +1 -1
- package/dist/{chunk-KZNIT2AQ.mjs → chunk-BXL6F5AB.mjs} +11 -8
- package/dist/{chunk-LKNRLBTK.mjs → chunk-NROQCSBF.mjs} +1 -1
- package/dist/index.css +328 -268
- package/dist/index.js +4 -4
- package/dist/index.mjs +3 -3
- package/package.json +2 -2
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { cn, buttonVariants, Button, useBuilder, spacing } from './chunk-
|
|
1
|
+
import { cn, buttonVariants, Button, useBuilder, spacing } from './chunk-BXL6F5AB.mjs';
|
|
2
2
|
import { builder } from './chunk-7K7IGTF3.mjs';
|
|
3
3
|
import * as React15 from 'react';
|
|
4
4
|
import { PlusIcon, ArrowUp, ArrowDown, Edit2Icon, AlignHorizontalSpaceAroundIcon, AlignHorizontalJustifyStartIcon, ScanIcon, CalendarIcon, Trash2Icon, ImageIcon, Loader2Icon, PaintbrushIcon, ChevronLeftIcon, ChevronRightIcon } from 'lucide-react';
|
|
@@ -24,7 +24,7 @@ var AlertDialogOverlay = React15.forwardRef(({ className, ...props }, ref) => /*
|
|
|
24
24
|
AlertDialogPrimitive.Overlay,
|
|
25
25
|
{
|
|
26
26
|
className: cn(
|
|
27
|
-
"fixed inset-0 z-50 bg-
|
|
27
|
+
"sb-fixed sb-inset-0 sb-z-50 sb-bg-background/80 sb-backdrop-blur-sm data-[state=open]:sb-animate-in data-[state=closed]:sb-animate-out data-[state=closed]:sb-fade-out-0 data-[state=open]:sb-fade-in-0",
|
|
28
28
|
className
|
|
29
29
|
),
|
|
30
30
|
...props,
|
|
@@ -37,7 +37,7 @@ var AlertDialogContent = React15.forwardRef(({ className, ...props }, ref) => /*
|
|
|
37
37
|
{
|
|
38
38
|
ref,
|
|
39
39
|
className: cn(
|
|
40
|
-
"fixed left-[50%] top-[50%] z-50 grid w-full max-w-lg translate-x-[-50%] translate-y-[-50%] gap-4 border bg-sb-
|
|
40
|
+
"sb-fixed sb-font-roboto sb-left-[50%] sb-top-[50%] sb-z-50 sb-grid sb-w-full sb-max-w-lg sb-translate-x-[-50%] sb-translate-y-[-50%] sb-gap-4 sb-border sb-bg-background sb-p-6 sb-shadow-lg sb-duration-200 data-[state=open]:sb-animate-in data-[state=closed]:sb-animate-out data-[state=closed]:sb-fade-out-0 data-[state=open]:sb-fade-in-0 data-[state=closed]:sb-zoom-out-95 data-[state=open]:sb-zoom-in-95 data-[state=closed]:sb-slide-out-to-left-1/2 data-[state=closed]:sb-slide-out-to-top-[48%] data-[state=open]:sb-slide-in-from-left-1/2 data-[state=open]:sb-slide-in-from-top-[48%] sm:sb-rounded-lg",
|
|
41
41
|
className
|
|
42
42
|
),
|
|
43
43
|
...props
|
|
@@ -51,7 +51,7 @@ var AlertDialogFooter = ({
|
|
|
51
51
|
"div",
|
|
52
52
|
{
|
|
53
53
|
className: cn(
|
|
54
|
-
"flex flex-col-reverse sm:flex-row sm:justify-end sm:space-x-2",
|
|
54
|
+
"sb-flex sb-flex-col-reverse sm:sb-flex-row sm:sb-justify-end sm:sb-space-x-2",
|
|
55
55
|
className
|
|
56
56
|
),
|
|
57
57
|
...props
|
|
@@ -62,7 +62,7 @@ var AlertDialogTitle = React15.forwardRef(({ className, ...props }, ref) => /* @
|
|
|
62
62
|
AlertDialogPrimitive.Title,
|
|
63
63
|
{
|
|
64
64
|
ref,
|
|
65
|
-
className: cn("text-lg font-semibold", className),
|
|
65
|
+
className: cn("sb-text-lg sb-font-semibold", className),
|
|
66
66
|
...props
|
|
67
67
|
}
|
|
68
68
|
));
|
|
@@ -71,7 +71,7 @@ var AlertDialogDescription = React15.forwardRef(({ className, ...props }, ref) =
|
|
|
71
71
|
AlertDialogPrimitive.Description,
|
|
72
72
|
{
|
|
73
73
|
ref,
|
|
74
|
-
className: cn("text-sm text-
|
|
74
|
+
className: cn("sb-text-sm sb-text-muted-foreground", className),
|
|
75
75
|
...props
|
|
76
76
|
}
|
|
77
77
|
));
|
|
@@ -91,7 +91,7 @@ var AlertDialogCancel = React15.forwardRef(({ className, ...props }, ref) => /*
|
|
|
91
91
|
ref,
|
|
92
92
|
className: cn(
|
|
93
93
|
buttonVariants({ variant: "outline" }),
|
|
94
|
-
"mt-2 sm:mt-0",
|
|
94
|
+
"sb-mt-2 sm:sb-mt-0",
|
|
95
95
|
className
|
|
96
96
|
),
|
|
97
97
|
...props
|
|
@@ -99,7 +99,7 @@ var AlertDialogCancel = React15.forwardRef(({ className, ...props }, ref) => /*
|
|
|
99
99
|
));
|
|
100
100
|
AlertDialogCancel.displayName = AlertDialogPrimitive.Cancel.displayName;
|
|
101
101
|
var labelVariants = cva(
|
|
102
|
-
"text-sm font-medium leading-none peer-disabled:cursor-not-allowed peer-disabled:opacity-70"
|
|
102
|
+
"sb-text-sm sb-font-medium sb-font-roboto sb-leading-none peer-disabled:sb-cursor-not-allowed peer-disabled:sb-opacity-70"
|
|
103
103
|
);
|
|
104
104
|
var Label = React15.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ React15.createElement(
|
|
105
105
|
LabelPrimitive.Root,
|
|
@@ -144,7 +144,7 @@ var FormItemContext = React15.createContext(
|
|
|
144
144
|
);
|
|
145
145
|
var FormItem = React15.forwardRef(({ className, ...props }, ref) => {
|
|
146
146
|
const id = React15.useId();
|
|
147
|
-
return /* @__PURE__ */ React15.createElement(FormItemContext.Provider, { value: { id } }, /* @__PURE__ */ React15.createElement("div", { ref, className: cn("space-y-2", className), ...props }));
|
|
147
|
+
return /* @__PURE__ */ React15.createElement(FormItemContext.Provider, { value: { id } }, /* @__PURE__ */ React15.createElement("div", { ref, className: cn("sb-space-y-2", className), ...props }));
|
|
148
148
|
});
|
|
149
149
|
FormItem.displayName = "FormItem";
|
|
150
150
|
var FormLabel = React15.forwardRef(({ className, ...props }, ref) => {
|
|
@@ -153,7 +153,7 @@ var FormLabel = React15.forwardRef(({ className, ...props }, ref) => {
|
|
|
153
153
|
Label,
|
|
154
154
|
{
|
|
155
155
|
ref,
|
|
156
|
-
className: cn(error && "text-
|
|
156
|
+
className: cn(error && "sb-text-destructive", className),
|
|
157
157
|
htmlFor: formItemId,
|
|
158
158
|
...props
|
|
159
159
|
}
|
|
@@ -181,7 +181,10 @@ var FormDescription = React15.forwardRef(({ className, ...props }, ref) => {
|
|
|
181
181
|
{
|
|
182
182
|
ref,
|
|
183
183
|
id: formDescriptionId,
|
|
184
|
-
className: cn(
|
|
184
|
+
className: cn(
|
|
185
|
+
"sb-text-sm sb-font-roboto sb-text-muted-foreground",
|
|
186
|
+
className
|
|
187
|
+
),
|
|
185
188
|
...props
|
|
186
189
|
}
|
|
187
190
|
);
|
|
@@ -198,7 +201,10 @@ var FormMessage = React15.forwardRef(({ className, children, ...props }, ref) =>
|
|
|
198
201
|
{
|
|
199
202
|
ref,
|
|
200
203
|
id: formMessageId,
|
|
201
|
-
className: cn(
|
|
204
|
+
className: cn(
|
|
205
|
+
"sb-text-sm sb-font-roboto sb-font-medium sb-text-destructive",
|
|
206
|
+
className
|
|
207
|
+
),
|
|
202
208
|
...props
|
|
203
209
|
},
|
|
204
210
|
body
|
|
@@ -215,7 +221,7 @@ var PopoverContent = React15.forwardRef(({ className, align = "center", sideOffs
|
|
|
215
221
|
align,
|
|
216
222
|
sideOffset,
|
|
217
223
|
className: cn(
|
|
218
|
-
"z-50 w-72 rounded-md border bg-sb-
|
|
224
|
+
"sb-z-50 sb-w-72 sb-font-roboto sb-rounded-md sb-border sb-bg-popover sb-p-4 sb-text-popover-foreground sb-shadow-md sb-outline-none data-[state=open]:sb-animate-in data-[state=closed]:sb-animate-out data-[state=closed]:sb-fade-out-0 data-[state=open]:sb-fade-in-0 data-[state=closed]:sb-zoom-out-95 data-[state=open]:sb-zoom-in-95 data-[side=bottom]:sb-slide-in-from-top-2 data-[side=left]:sb-slide-in-from-right-2 data-[side=right]:sb-slide-in-from-left-2 data-[side=top]:sb-slide-in-from-bottom-2",
|
|
219
225
|
className
|
|
220
226
|
),
|
|
221
227
|
...props
|
|
@@ -227,7 +233,10 @@ var TabsList = React15.forwardRef(({ className, ...props }, ref) => /* @__PURE__
|
|
|
227
233
|
TabsPrimitive.List,
|
|
228
234
|
{
|
|
229
235
|
ref,
|
|
230
|
-
className: cn(
|
|
236
|
+
className: cn(
|
|
237
|
+
"sb-flex sb-items-center sb-border-b sb-px-4 sb-space-x-6",
|
|
238
|
+
className
|
|
239
|
+
),
|
|
231
240
|
...props
|
|
232
241
|
}
|
|
233
242
|
));
|
|
@@ -237,7 +246,7 @@ var TabsTrigger = React15.forwardRef(({ className, ...props }, ref) => /* @__PUR
|
|
|
237
246
|
{
|
|
238
247
|
ref,
|
|
239
248
|
className: cn(
|
|
240
|
-
"inline-flex items-center justify-center whitespace-nowrap py-3 text-sm font-medium transition-all focus-visible:outline-none disabled:pointer-events-none disabled:opacity-50 data-[state=active]:border-black border-b-2 border-transparent data-[state=active]:text-sb-
|
|
249
|
+
"sb-inline-flex sb-font-roboto sb-items-center sb-justify-center sb-whitespace-nowrap sb-py-3 sb-text-sm sb-font-medium sb-transition-all focus-visible:sb-outline-none disabled:sb-pointer-events-none disabled:sb-opacity-50 data-[state=active]:sb-border-black sb-border-b-2 sb-border-transparent data-[state=active]:sb-text-foreground sb-text-muted-foreground",
|
|
241
250
|
className
|
|
242
251
|
),
|
|
243
252
|
...props
|
|
@@ -249,7 +258,7 @@ var TabsContent = React15.forwardRef(({ className, ...props }, ref) => /* @__PUR
|
|
|
249
258
|
{
|
|
250
259
|
ref,
|
|
251
260
|
className: cn(
|
|
252
|
-
"ring-offset-background focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2",
|
|
261
|
+
"sb-ring-offset-background sb-font-roboto focus-visible:sb-outline-none focus-visible:sb-ring-2 focus-visible:sb-ring-ring focus-visible:sb-ring-offset-2",
|
|
253
262
|
className
|
|
254
263
|
),
|
|
255
264
|
...props
|
|
@@ -347,35 +356,35 @@ var MediaInput = (props) => {
|
|
|
347
356
|
src,
|
|
348
357
|
alt: "",
|
|
349
358
|
fill: true,
|
|
350
|
-
className: "absolute inset-0 object-cover pointer-events-none"
|
|
359
|
+
className: "sb-absolute sb-inset-0 sb-object-cover sb-pointer-events-none"
|
|
351
360
|
}
|
|
352
|
-
), /* @__PURE__ */ React15.createElement("div", { className: "absolute right-1 top-1 z-30 flex items-center justify-end gap-3 opacity-0 transition-opacity group-hover:opacity-100" }, /* @__PURE__ */ React15.createElement(
|
|
361
|
+
), /* @__PURE__ */ React15.createElement("div", { className: "sb-absolute sb-right-1 sb-top-1 sb-z-30 sb-flex sb-items-center sb-justify-end sb-gap-3 sb-opacity-0 sb-transition-opacity group-hover:sb-opacity-100" }, /* @__PURE__ */ React15.createElement(
|
|
353
362
|
"button",
|
|
354
363
|
{
|
|
355
|
-
className: "flex h-8 w-8 items-center justify-center rounded-full border bg-sb-
|
|
364
|
+
className: "sb-flex sb-h-8 sb-w-8 sb-items-center sb-justify-center sb-rounded-full sb-border sb-bg-secondary sb-text-secondary-foreground sb-opacity-90 sb-shadow sb-transition-opacity hover:sb-opacity-100",
|
|
356
365
|
onClick: () => handleSourceDelete(src)
|
|
357
366
|
},
|
|
358
|
-
/* @__PURE__ */ React15.createElement(Trash2Icon, { className: "h-4 w-4" })
|
|
367
|
+
/* @__PURE__ */ React15.createElement(Trash2Icon, { className: "sb-h-4 sb-w-4" })
|
|
359
368
|
)))), queue.map((_, i) => /* @__PURE__ */ React15.createElement(
|
|
360
369
|
MediaInputItem,
|
|
361
370
|
{
|
|
362
371
|
key: i,
|
|
363
372
|
className: cn(
|
|
364
|
-
"flex h-28 w-28 items-center justify-center",
|
|
373
|
+
"sb-flex sb-h-28 sb-w-28 sb-items-center sb-justify-center",
|
|
365
374
|
props.itemClassName
|
|
366
375
|
)
|
|
367
376
|
},
|
|
368
|
-
/* @__PURE__ */ React15.createElement(Loader2Icon, { className: "h-6 w-6 animate-spin" })
|
|
377
|
+
/* @__PURE__ */ React15.createElement(Loader2Icon, { className: "sb-h-6 sb-w-6 sb-animate-spin" })
|
|
369
378
|
)), multiple || !multiple && !sources.length && !queue.length ? /* @__PURE__ */ React15.createElement(
|
|
370
379
|
"label",
|
|
371
380
|
{
|
|
372
381
|
htmlFor: id,
|
|
373
382
|
className: cn(
|
|
374
|
-
"flex h-28 w-28 cursor-pointer items-center justify-center rounded-lg border",
|
|
383
|
+
"sb-flex sb-h-28 sb-w-28 sb-cursor-pointer sb-items-center sb-justify-center sb-rounded-lg sb-border",
|
|
375
384
|
props.itemClassName
|
|
376
385
|
)
|
|
377
386
|
},
|
|
378
|
-
/* @__PURE__ */ React15.createElement(PlusIcon, { className: "h-6 w-6" }),
|
|
387
|
+
/* @__PURE__ */ React15.createElement(PlusIcon, { className: "sb-h-6 sb-w-6" }),
|
|
379
388
|
/* @__PURE__ */ React15.createElement(
|
|
380
389
|
"input",
|
|
381
390
|
{
|
|
@@ -384,7 +393,7 @@ var MediaInput = (props) => {
|
|
|
384
393
|
onChange: handleFilesAdd,
|
|
385
394
|
multiple,
|
|
386
395
|
accept: ".png,.jpg,.jpeg,.webp,.gif,.svg",
|
|
387
|
-
className: "hidden"
|
|
396
|
+
className: "sb-hidden"
|
|
388
397
|
}
|
|
389
398
|
)
|
|
390
399
|
) : null);
|
|
@@ -394,7 +403,7 @@ var MediaInputItem = (props) => {
|
|
|
394
403
|
"div",
|
|
395
404
|
{
|
|
396
405
|
className: cn(
|
|
397
|
-
"relative h-28 w-28 overflow-hidden rounded-lg border",
|
|
406
|
+
"sb-relative sb-h-28 sb-w-28 sb-overflow-hidden sb-rounded-lg sb-border",
|
|
398
407
|
props.className
|
|
399
408
|
)
|
|
400
409
|
},
|
|
@@ -446,30 +455,30 @@ var BackgroundPicker = (props) => {
|
|
|
446
455
|
variant: "outline",
|
|
447
456
|
size: "sm",
|
|
448
457
|
className: cn(
|
|
449
|
-
"justify-start text-left font-normal normal-case w-full",
|
|
450
|
-
!background && "text-
|
|
458
|
+
"sb-justify-start sb-text-left sb-font-normal sb-normal-case sb-w-full",
|
|
459
|
+
!background && "sb-text-muted-foreground",
|
|
451
460
|
className
|
|
452
461
|
)
|
|
453
462
|
},
|
|
454
|
-
/* @__PURE__ */ React15.createElement("div", { className: "w-full flex items-center gap-2" }, background ? /* @__PURE__ */ React15.createElement(
|
|
463
|
+
/* @__PURE__ */ React15.createElement("div", { className: "sb-w-full sb-flex sb-items-center sb-gap-2" }, background ? /* @__PURE__ */ React15.createElement(
|
|
455
464
|
"div",
|
|
456
465
|
{
|
|
457
|
-
className: "h-4 w-4 rounded !bg-center !bg-cover transition-all border",
|
|
466
|
+
className: "sb-h-4 sb-w-4 sb-rounded !sb-bg-center !sb-bg-cover sb-transition-all sb-border",
|
|
458
467
|
style: { background }
|
|
459
468
|
}
|
|
460
|
-
) : /* @__PURE__ */ React15.createElement(PaintbrushIcon, { className: "h-4 w-4" }), /* @__PURE__ */ React15.createElement("div", { className: "truncate flex-1" }, background ? background : "Kies een achtergrond"))
|
|
461
|
-
)), /* @__PURE__ */ React15.createElement(PopoverContent, { className: "w-64 p-0" }, /* @__PURE__ */ React15.createElement(Tabs, { defaultValue: defaultTab }, /* @__PURE__ */ React15.createElement(TabsList, { className: "w-full" }, /* @__PURE__ */ React15.createElement(TabsTrigger, { className: "flex-1", value: "solid" }, "Solid"), /* @__PURE__ */ React15.createElement(TabsTrigger, { className: "flex-1", value: "gradient" }, "Gradient"), /* @__PURE__ */ React15.createElement(TabsTrigger, { className: "flex-1", value: "image" }, "Image")), /* @__PURE__ */ React15.createElement(
|
|
469
|
+
) : /* @__PURE__ */ React15.createElement(PaintbrushIcon, { className: "sb-h-4 sb-w-4" }), /* @__PURE__ */ React15.createElement("div", { className: "sb-truncate sb-flex-1" }, background ? background : "Kies een achtergrond"))
|
|
470
|
+
)), /* @__PURE__ */ React15.createElement(PopoverContent, { className: "sb-w-64 sb-p-0" }, /* @__PURE__ */ React15.createElement(Tabs, { defaultValue: defaultTab }, /* @__PURE__ */ React15.createElement(TabsList, { className: "sb-w-full" }, /* @__PURE__ */ React15.createElement(TabsTrigger, { className: "sb-flex-1", value: "solid" }, "Solid"), /* @__PURE__ */ React15.createElement(TabsTrigger, { className: "sb-flex-1", value: "gradient" }, "Gradient"), /* @__PURE__ */ React15.createElement(TabsTrigger, { className: "sb-flex-1", value: "image" }, "Image")), /* @__PURE__ */ React15.createElement(
|
|
462
471
|
TabsContent,
|
|
463
472
|
{
|
|
464
473
|
value: "solid",
|
|
465
|
-
className: "data-[state=active]:flex flex-wrap gap-1 p-4"
|
|
474
|
+
className: "data-[state=active]:sb-flex sb-flex-wrap sb-gap-1 sb-p-4"
|
|
466
475
|
},
|
|
467
476
|
solids.map((s) => /* @__PURE__ */ React15.createElement(
|
|
468
477
|
"div",
|
|
469
478
|
{
|
|
470
479
|
key: s,
|
|
471
480
|
style: { background: s },
|
|
472
|
-
className: "rounded-md h-6 w-6 cursor-pointer active:scale-105 border",
|
|
481
|
+
className: "sb-rounded-md sb-h-6 sb-w-6 sb-cursor-pointer active:sb-scale-105 sb-border",
|
|
473
482
|
onClick: () => onBackgroundChange(s)
|
|
474
483
|
}
|
|
475
484
|
))
|
|
@@ -477,7 +486,7 @@ var BackgroundPicker = (props) => {
|
|
|
477
486
|
TabsContent,
|
|
478
487
|
{
|
|
479
488
|
value: "gradient",
|
|
480
|
-
className: "data-[state=active]:flex flex-wrap gap-1 p-4"
|
|
489
|
+
className: "data-[state=active]:sb-flex sb-flex-wrap sb-gap-1 sb-p-4"
|
|
481
490
|
},
|
|
482
491
|
gradients.map((s) => /* @__PURE__ */ React15.createElement(
|
|
483
492
|
"div",
|
|
@@ -488,11 +497,11 @@ var BackgroundPicker = (props) => {
|
|
|
488
497
|
onClick: () => onBackgroundChange(s)
|
|
489
498
|
}
|
|
490
499
|
))
|
|
491
|
-
), /* @__PURE__ */ React15.createElement(TabsContent, { value: "image" }, /* @__PURE__ */ React15.createElement("div", { className: "p-4 border-b" }, /* @__PURE__ */ React15.createElement(
|
|
500
|
+
), /* @__PURE__ */ React15.createElement(TabsContent, { value: "image" }, /* @__PURE__ */ React15.createElement("div", { className: "sb-p-4 sb-border-b" }, /* @__PURE__ */ React15.createElement(
|
|
492
501
|
MediaInput,
|
|
493
502
|
{
|
|
494
|
-
className: "grid grid-cols-2 gap-1",
|
|
495
|
-
itemClassName: "aspect-video h-auto w-full",
|
|
503
|
+
className: "sb-grid sb-grid-cols-2 sb-gap-1",
|
|
504
|
+
itemClassName: "sb-aspect-video sb-h-auto sb-w-full",
|
|
496
505
|
multiple: false,
|
|
497
506
|
onFilesChange: (files) => {
|
|
498
507
|
if (!files.length)
|
|
@@ -504,12 +513,12 @@ var BackgroundPicker = (props) => {
|
|
|
504
513
|
"media-input: Error: " + e?.description
|
|
505
514
|
)
|
|
506
515
|
}
|
|
507
|
-
)), /* @__PURE__ */ React15.createElement("div", { className: "grid grid-cols-2 gap-1 p-4" }, images.map((s) => /* @__PURE__ */ React15.createElement(
|
|
516
|
+
)), /* @__PURE__ */ React15.createElement("div", { className: "sb-grid sb-grid-cols-2 sb-gap-1 sb-p-4" }, images.map((s) => /* @__PURE__ */ React15.createElement(
|
|
508
517
|
"div",
|
|
509
518
|
{
|
|
510
519
|
key: s,
|
|
511
520
|
style: { backgroundImage: s },
|
|
512
|
-
className: "rounded-md bg-cover bg-center aspect-video w-full cursor-pointer border active:scale-105",
|
|
521
|
+
className: "sb-rounded-md sb-bg-cover sb-bg-center sb-aspect-video sb-w-full sb-cursor-pointer sb-border active:sb-scale-105",
|
|
513
522
|
onClick: () => onBackgroundChange(s)
|
|
514
523
|
}
|
|
515
524
|
)))))));
|
|
@@ -524,44 +533,44 @@ function Calendar({
|
|
|
524
533
|
DayPicker,
|
|
525
534
|
{
|
|
526
535
|
showOutsideDays,
|
|
527
|
-
className: cn("p-3", className),
|
|
536
|
+
className: cn("sb-p-3 sb-font-roboto", className),
|
|
528
537
|
classNames: {
|
|
529
|
-
months: "flex flex-col sm:flex-row space-y-4 sm:space-x-4 sm:space-y-0",
|
|
530
|
-
month: "space-y-4",
|
|
531
|
-
caption: "flex justify-center pt-1 relative items-center",
|
|
532
|
-
caption_label: "text-sm font-medium",
|
|
533
|
-
nav: "space-x-1 flex items-center",
|
|
538
|
+
months: "sb-flex sb-flex-col sm:sb-flex-row sb-space-y-4 sm:sb-space-x-4 sm:sb-space-y-0",
|
|
539
|
+
month: "sb-space-y-4",
|
|
540
|
+
caption: "sb-flex sb-justify-center sb-pt-1 sb-relative sb-items-center",
|
|
541
|
+
caption_label: "sb-text-sm sb-font-medium",
|
|
542
|
+
nav: "sb-space-x-1 sb-flex sb-items-center",
|
|
534
543
|
nav_button: cn(
|
|
535
544
|
buttonVariants({ variant: "outline" }),
|
|
536
|
-
"h-7 w-7 bg-transparent p-0 opacity-50 hover:opacity-100"
|
|
545
|
+
"sb-h-7 sb-w-7 sb-bg-transparent sb-p-0 sb-opacity-50 hover:sb-opacity-100"
|
|
537
546
|
),
|
|
538
|
-
nav_button_previous: "absolute left-1",
|
|
539
|
-
nav_button_next: "absolute right-1",
|
|
540
|
-
table: "w-full border-collapse space-y-1",
|
|
541
|
-
head_row: "flex",
|
|
542
|
-
head_cell: "text-
|
|
543
|
-
row: "flex w-full mt-2",
|
|
547
|
+
nav_button_previous: "sb-absolute sb-left-1",
|
|
548
|
+
nav_button_next: "sb-absolute sb-right-1",
|
|
549
|
+
table: "sb-w-full sb-border-collapse sb-space-y-1",
|
|
550
|
+
head_row: "sb-flex",
|
|
551
|
+
head_cell: "sb-text-muted-foreground sb-rounded-md sb-w-8 sb-font-normal sb-text-[0.8rem]",
|
|
552
|
+
row: "sb-flex sb-w-full sb-mt-2",
|
|
544
553
|
cell: cn(
|
|
545
|
-
"relative p-0 text-center text-sm focus-within:relative focus-within:z-20 [&:has([aria-selected])]:bg-
|
|
546
|
-
props.mode === "range" ? "[&:has(>.day-range-end)]:rounded-r-md [&:has(>.day-range-start)]:rounded-l-md first:[&:has([aria-selected])]:rounded-l-md last:[&:has([aria-selected])]:rounded-r-md" : "[&:has([aria-selected])]:rounded-md"
|
|
554
|
+
"sb-relative sb-p-0 sb-text-center sb-text-sm focus-within:sb-relative focus-within:sb-z-20 [&:has([aria-selected])]:sb-bg-accent [&:has([aria-selected].day-outside)]:sb-bg-accent/50 [&:has([aria-selected].day-range-end)]:sb-rounded-r-md",
|
|
555
|
+
props.mode === "range" ? "[&:has(>.day-range-end)]:sb-rounded-r-md [&:has(>.day-range-start)]:sb-rounded-l-md first:[&:has([aria-selected])]:sb-rounded-l-md last:[&:has([aria-selected])]:sb-rounded-r-md" : "[&:has([aria-selected])]:sb-rounded-md"
|
|
547
556
|
),
|
|
548
557
|
day: cn(
|
|
549
558
|
buttonVariants({ variant: "ghost" }),
|
|
550
|
-
"h-8 w-8 p-0 font-normal aria-selected:opacity-100"
|
|
559
|
+
"sb-h-8 sb-w-8 sb-p-0 sb-font-normal aria-selected:sb-opacity-100"
|
|
551
560
|
),
|
|
552
561
|
day_range_start: "day-range-start",
|
|
553
562
|
day_range_end: "day-range-end",
|
|
554
|
-
day_selected: "bg-sb-
|
|
555
|
-
day_today: "bg-sb-
|
|
556
|
-
day_outside: "day-outside text-
|
|
557
|
-
day_disabled: "text-
|
|
558
|
-
day_range_middle: "aria-selected:bg-
|
|
563
|
+
day_selected: "sb-bg-primary sb-text-primary-foreground hover:sb-bg-primary hover:sb-text-primary-foreground focus:sb-bg-primary focus:sb-text-primary-foreground",
|
|
564
|
+
day_today: "sb-bg-accent sb-text-accent-foreground",
|
|
565
|
+
day_outside: "day-outside sb-text-muted-foreground sb-opacity-50 aria-selected:sb-bg-accent/50 aria-selected:sb-text-muted-foreground aria-selected:sb-opacity-30",
|
|
566
|
+
day_disabled: "sb-text-muted-foreground sb-opacity-50",
|
|
567
|
+
day_range_middle: "aria-selected:sb-bg-accent aria-selected:sb-text-accent-foreground",
|
|
559
568
|
day_hidden: "invisible",
|
|
560
569
|
...classNames
|
|
561
570
|
},
|
|
562
571
|
components: {
|
|
563
|
-
IconLeft: () => /* @__PURE__ */ React15.createElement(ChevronLeftIcon, { className: "h-4 w-4" }),
|
|
564
|
-
IconRight: () => /* @__PURE__ */ React15.createElement(ChevronRightIcon, { className: "h-4 w-4" })
|
|
572
|
+
IconLeft: () => /* @__PURE__ */ React15.createElement(ChevronLeftIcon, { className: "sb-h-4 sb-w-4" }),
|
|
573
|
+
IconRight: () => /* @__PURE__ */ React15.createElement(ChevronRightIcon, { className: "sb-h-4 sb-w-4" })
|
|
565
574
|
},
|
|
566
575
|
...props
|
|
567
576
|
}
|
|
@@ -587,24 +596,24 @@ var ColorPicker = (props) => {
|
|
|
587
596
|
variant: "outline",
|
|
588
597
|
size: "sm",
|
|
589
598
|
className: cn(
|
|
590
|
-
"justify-start text-left font-normal normal-case w-full",
|
|
591
|
-
!color && "text-
|
|
599
|
+
"sb-justify-start sb-text-left sb-font-normal sb-normal-case sb-w-full",
|
|
600
|
+
!color && "sb-text-muted-foreground",
|
|
592
601
|
className
|
|
593
602
|
)
|
|
594
603
|
},
|
|
595
|
-
/* @__PURE__ */ React15.createElement("div", { className: "w-full flex items-center gap-2" }, color ? /* @__PURE__ */ React15.createElement(
|
|
604
|
+
/* @__PURE__ */ React15.createElement("div", { className: "sb-w-full sb-flex sb-items-center sb-gap-2" }, color ? /* @__PURE__ */ React15.createElement(
|
|
596
605
|
"div",
|
|
597
606
|
{
|
|
598
|
-
className: "h-4 w-4 rounded !bg-center !bg-cover transition-all border",
|
|
607
|
+
className: "sb-h-4 sb-w-4 sb-rounded !sb-bg-center !sb-bg-cover sb-transition-all sb-border",
|
|
599
608
|
style: { background: color }
|
|
600
609
|
}
|
|
601
|
-
) : /* @__PURE__ */ React15.createElement(PaintbrushIcon, { className: "h-4 w-4" }), /* @__PURE__ */ React15.createElement("div", { className: "truncate flex-1" }, color ? color : "Kies een kleur"))
|
|
602
|
-
)), /* @__PURE__ */ React15.createElement(PopoverContent, { className: "w-64 p-4 flex flex-wrap gap-1" }, colors.map((s) => /* @__PURE__ */ React15.createElement(
|
|
610
|
+
) : /* @__PURE__ */ React15.createElement(PaintbrushIcon, { className: "sb-h-4 sb-w-4" }), /* @__PURE__ */ React15.createElement("div", { className: "sb-truncate sb-flex-1" }, color ? color : "Kies een kleur"))
|
|
611
|
+
)), /* @__PURE__ */ React15.createElement(PopoverContent, { className: "sb-w-64 sb-p-4 sb-flex sb-flex-wrap sb-gap-1" }, colors.map((s) => /* @__PURE__ */ React15.createElement(
|
|
603
612
|
"div",
|
|
604
613
|
{
|
|
605
614
|
key: s,
|
|
606
615
|
style: { background: s },
|
|
607
|
-
className: "rounded-md h-6 w-6 cursor-pointer active:scale-105 border",
|
|
616
|
+
className: "sb-rounded-md sb-h-6 sb-w-6 sb-cursor-pointer active:sb-scale-105 sb-border",
|
|
608
617
|
onClick: () => onColorChange(s)
|
|
609
618
|
}
|
|
610
619
|
))));
|
|
@@ -616,7 +625,7 @@ var Input = React15.forwardRef(
|
|
|
616
625
|
{
|
|
617
626
|
type,
|
|
618
627
|
className: cn(
|
|
619
|
-
"flex h-8 w-full rounded-md border border-sb-
|
|
628
|
+
"sb-flex sb-h-8 sb-w-full sb-font-roboto sb-rounded-md sb-border sb-border-input sb-bg-background sb-px-3 sb-py-1 sb-text-sm sb-ring-offset-background file:sb-border-0 file:sb-bg-transparent file:sb-text-sm file:sb-font-medium placeholder:sb-text-muted-foreground focus-visible:sb-outline-none focus-visible:sb-ring-1 focus-visible:ring-sb-ring focus-visible:sb-ring-offset-2 disabled:sb-cursor-not-allowed disabled:sb-opacity-50",
|
|
620
629
|
className
|
|
621
630
|
),
|
|
622
631
|
ref,
|
|
@@ -628,7 +637,7 @@ var Input = React15.forwardRef(
|
|
|
628
637
|
Input.displayName = "Input";
|
|
629
638
|
var AdvancedInput = React15.forwardRef(
|
|
630
639
|
({ prepend, append, ...props }, ref) => {
|
|
631
|
-
return /* @__PURE__ */ React15.createElement("div", { className: "relative" }, /* @__PURE__ */ React15.createElement(Input, { ref, className: "pl-9 pr-7 text-right", ...props }), prepend && /* @__PURE__ */ React15.createElement("div", { className: "absolute top-1/2 left-3
|
|
640
|
+
return /* @__PURE__ */ React15.createElement("div", { className: "sb-relative" }, /* @__PURE__ */ React15.createElement(Input, { ref, className: "sb-pl-9 sb-pr-7 sb-text-right", ...props }), prepend && /* @__PURE__ */ React15.createElement("div", { className: "sb-absolute sb-font-roboto sb-top-1/2 sb-left-3 sb--translate-y-1/2" }, prepend), append && /* @__PURE__ */ React15.createElement("div", { className: "sb-absolute sb-font-roboto sb-top-1/2 sb-right-3 sb--translate-y-1/2" }, append));
|
|
632
641
|
}
|
|
633
642
|
);
|
|
634
643
|
AdvancedInput.displayName = "AdvancedInput";
|
|
@@ -636,7 +645,7 @@ var Switch = React15.forwardRef(({ className, ...props }, ref) => /* @__PURE__ *
|
|
|
636
645
|
SwitchPrimitives.Root,
|
|
637
646
|
{
|
|
638
647
|
className: cn(
|
|
639
|
-
"peer inline-flex h-6 w-11 shrink-0 cursor-pointer items-center rounded-full border-2 border-transparent transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:
|
|
648
|
+
"peer sb-inline-flex sb-h-6 sb-w-11 sb-shrink-0 sb-cursor-pointer sb-items-center sb-rounded-full sb-border-2 sb-border-transparent sb-transition-colors focus-visible:sb-outline-none focus-visible:sb-ring-2 focus-visible:sb-ring-ring focus-visible:sb-ring-offset-2 focus-visible:sb-ring-offset-background disabled:sb-cursor-not-allowed disabled:sb-opacity-50 data-[state=checked]:sb-bg-primary data-[state=unchecked]:sb-bg-input",
|
|
640
649
|
className
|
|
641
650
|
),
|
|
642
651
|
...props,
|
|
@@ -646,7 +655,7 @@ var Switch = React15.forwardRef(({ className, ...props }, ref) => /* @__PURE__ *
|
|
|
646
655
|
SwitchPrimitives.Thumb,
|
|
647
656
|
{
|
|
648
657
|
className: cn(
|
|
649
|
-
"pointer-events-none block h-5 w-5 rounded-full bg-sb-
|
|
658
|
+
"sb-pointer-events-none sb-block sb-h-5 sb-w-5 sb-rounded-full sb-bg-background sb-shadow-lg sb-ring-0 sb-transition-transform data-[state=checked]:sb-translate-x-5 data-[state=unchecked]:sb-translate-x-0"
|
|
650
659
|
)
|
|
651
660
|
}
|
|
652
661
|
)
|
|
@@ -658,7 +667,7 @@ var Textarea = React15.forwardRef(
|
|
|
658
667
|
"textarea",
|
|
659
668
|
{
|
|
660
669
|
className: cn(
|
|
661
|
-
"flex min-h-[60px] w-full rounded-md border border-sb-
|
|
670
|
+
"sb-flex sb-min-h-[60px] sb-font-roboto sb-w-full sb-rounded-md sb-border sb-border-input sb-bg-transparent sb-px-3 sb-py-2 sb-text-sm sb-shadow-sm placeholder:sb-text-muted-foreground focus-visible:sb-outline-none focus-visible:sb-ring-1 focus-visible:sb-ring-ring disabled:sb-cursor-not-allowed disabled:sb-opacity-50",
|
|
662
671
|
className
|
|
663
672
|
),
|
|
664
673
|
ref,
|
|
@@ -669,17 +678,17 @@ var Textarea = React15.forwardRef(
|
|
|
669
678
|
);
|
|
670
679
|
Textarea.displayName = "Textarea";
|
|
671
680
|
var toggleVariants = cva(
|
|
672
|
-
"inline-flex items-center justify-center rounded-md text-sm font-medium ring-offset-sb-
|
|
681
|
+
"sb-inline-flex sb-items-center sb-justify-center sb-rounded-md sb-text-sm sb-font-medium sb-ring-offset-background sb-transition-colors hover:sb-bg-muted hover:sb-text-muted-foreground focus-visible:sb-outline-none focus-visible:sb-ring-1 focus-visible:sb-ring-ring focus-visible:sb-ring-offset-2 disabled:sb-pointer-events-none disabled:sb-opacity-50 data-[state=on]:sb-bg-accent data-[state=on]:sb-text-accent-foreground",
|
|
673
682
|
{
|
|
674
683
|
variants: {
|
|
675
684
|
variant: {
|
|
676
|
-
default: "bg-transparent",
|
|
677
|
-
outline: "border border-input bg-transparent hover:bg-
|
|
685
|
+
default: "sb-bg-transparent",
|
|
686
|
+
outline: "sb-border sb-border-input sb-bg-transparent hover:sb-bg-accent hover:sb-text-accent-foreground"
|
|
678
687
|
},
|
|
679
688
|
size: {
|
|
680
|
-
default: "h-10 px-3",
|
|
681
|
-
sm: "h-9 px-2.5",
|
|
682
|
-
lg: "h-11 px-5"
|
|
689
|
+
default: "sb-h-10 sb-px-3",
|
|
690
|
+
sm: "sb-h-9 sb-px-2.5",
|
|
691
|
+
lg: "sb-h-11 sb-px-5"
|
|
683
692
|
}
|
|
684
693
|
},
|
|
685
694
|
defaultVariants: {
|
|
@@ -702,35 +711,35 @@ Toggle.displayName = TogglePrimitive.Root.displayName;
|
|
|
702
711
|
var ContainerItemToolbar = (props) => {
|
|
703
712
|
const { contentId, canBringUp = false, canBringDown = false } = props;
|
|
704
713
|
const { bringUp, bringDown } = useBuilder();
|
|
705
|
-
return /* @__PURE__ */ React15.createElement("div", { className: "absolute z-20 top-1 right-1 rounded-md shadow flex flex-col gap-1 p-1 bg-sb-
|
|
714
|
+
return /* @__PURE__ */ React15.createElement("div", { className: "sb-absolute sb-z-20 sb-top-1 sb-right-1 sb-rounded-md sb-shadow sb-flex sb-flex-col sb-gap-1 sb-p-1 sb-bg-card sb-text-card-foreground sb-item-toolbar sb-opacity-0 sb-transition-opacity" }, /* @__PURE__ */ React15.createElement("div", { className: "sb-h-10 sb-p-1 sb-border sb-border-input sb-bg-background sb-rounded-md sb-text-sm sb-font-medium sb-flex sb-gap-1 sb-items-center sb-justify-start" }, /* @__PURE__ */ React15.createElement(EditButton, { id: contentId }), /* @__PURE__ */ React15.createElement(
|
|
706
715
|
Button,
|
|
707
716
|
{
|
|
708
717
|
variant: "ghost",
|
|
709
|
-
className: "w-8 h-8 p-0",
|
|
718
|
+
className: "sb-w-8 sb-h-8 sb-p-0",
|
|
710
719
|
onClick: () => bringUp(contentId),
|
|
711
720
|
disabled: !canBringUp
|
|
712
721
|
},
|
|
713
|
-
/* @__PURE__ */ React15.createElement(ArrowUp, { className: "h-5 w-5" })
|
|
722
|
+
/* @__PURE__ */ React15.createElement(ArrowUp, { className: "sb-h-5 sb-w-5" })
|
|
714
723
|
), /* @__PURE__ */ React15.createElement(
|
|
715
724
|
Button,
|
|
716
725
|
{
|
|
717
726
|
variant: "ghost",
|
|
718
|
-
className: "w-8 h-8 p-0",
|
|
727
|
+
className: "sb-w-8 sb-h-8 sb-p-0",
|
|
719
728
|
onClick: () => bringDown(contentId),
|
|
720
729
|
disabled: !canBringDown
|
|
721
730
|
},
|
|
722
|
-
/* @__PURE__ */ React15.createElement(ArrowDown, { className: "h-5 w-5" })
|
|
731
|
+
/* @__PURE__ */ React15.createElement(ArrowDown, { className: "sb-h-5 sb-w-5" })
|
|
723
732
|
), /* @__PURE__ */ React15.createElement(DeleteButton, { contentId })));
|
|
724
733
|
};
|
|
725
734
|
var EditButton = ({ id }) => {
|
|
726
|
-
return /* @__PURE__ */ React15.createElement(Popover, null, /* @__PURE__ */ React15.createElement(PopoverTrigger, { asChild: true }, /* @__PURE__ */ React15.createElement(Button, { variant: "ghost", className: "w-8 h-8 p-0" }, /* @__PURE__ */ React15.createElement(Edit2Icon, { className: "h-5 w-5" }))), /* @__PURE__ */ React15.createElement(
|
|
735
|
+
return /* @__PURE__ */ React15.createElement(Popover, null, /* @__PURE__ */ React15.createElement(PopoverTrigger, { asChild: true }, /* @__PURE__ */ React15.createElement(Button, { variant: "ghost", className: "sb-w-8 sb-h-8 sb-p-0" }, /* @__PURE__ */ React15.createElement(Edit2Icon, { className: "sb-h-5 sb-w-5" }))), /* @__PURE__ */ React15.createElement(
|
|
727
736
|
PopoverContent,
|
|
728
737
|
{
|
|
729
738
|
side: "left",
|
|
730
739
|
align: "start",
|
|
731
740
|
sideOffset: 16,
|
|
732
741
|
alignOffset: -8,
|
|
733
|
-
className: "p-0",
|
|
742
|
+
className: "sb-p-0",
|
|
734
743
|
collisionPadding: 16
|
|
735
744
|
},
|
|
736
745
|
/* @__PURE__ */ React15.createElement(EditPopoverInner, { id })
|
|
@@ -774,7 +783,7 @@ var ContainerItemForm = (props) => {
|
|
|
774
783
|
const subscription = form.watch(() => form.handleSubmit(onSubmit)());
|
|
775
784
|
return () => subscription.unsubscribe();
|
|
776
785
|
}, [form.watch, form.handleSubmit]);
|
|
777
|
-
return /* @__PURE__ */ React15.createElement(Form, { ...form }, /* @__PURE__ */ React15.createElement("form", { onSubmit: form.handleSubmit(onSubmit) }, /* @__PURE__ */ React15.createElement("div", { className: "space-y-4 p-4" }, (component.inputs || []).map((input) => /* @__PURE__ */ React15.createElement(
|
|
786
|
+
return /* @__PURE__ */ React15.createElement(Form, { ...form }, /* @__PURE__ */ React15.createElement("form", { onSubmit: form.handleSubmit(onSubmit) }, /* @__PURE__ */ React15.createElement("div", { className: "sb-space-y-4 sb-p-4" }, (component.inputs || []).map((input) => /* @__PURE__ */ React15.createElement(
|
|
778
787
|
FormField,
|
|
779
788
|
{
|
|
780
789
|
key: input.name,
|
|
@@ -840,13 +849,10 @@ var ItemDesignForm = (props) => {
|
|
|
840
849
|
}
|
|
841
850
|
}
|
|
842
851
|
});
|
|
843
|
-
console.log("ERRORS", form.formState.errors);
|
|
844
|
-
console.log("VALUES", form.getValues());
|
|
845
852
|
const onSubmit = (values) => {
|
|
846
853
|
const { container, background, color, padding: p, margin: m } = values;
|
|
847
854
|
const padding = !p.indipendent ? `${p.vertical}px ${p.horizontal}px` : `${p.top}px ${p.right}px ${p.bottom}px ${p.left}px`;
|
|
848
855
|
const margin = !m.indipendent ? `${m.vertical}px ${m.horizontal}px` : `${m.top}px ${m.right}px ${m.bottom}px ${m.left}px`;
|
|
849
|
-
console.log("CALLING_PATCH_ITEM", "ITEM_ID: " + item.id);
|
|
850
856
|
patchItem(item.id, {
|
|
851
857
|
styles: {
|
|
852
858
|
container,
|
|
@@ -865,7 +871,7 @@ var ItemDesignForm = (props) => {
|
|
|
865
871
|
"padding.indipendent",
|
|
866
872
|
"margin.indipendent"
|
|
867
873
|
]);
|
|
868
|
-
return /* @__PURE__ */ React15.createElement(Form, { ...form }, /* @__PURE__ */ React15.createElement("form", { onSubmit: form.handleSubmit(onSubmit) }, /* @__PURE__ */ React15.createElement("div", { className: "space-y-4 p-4" }, /* @__PURE__ */ React15.createElement(
|
|
874
|
+
return /* @__PURE__ */ React15.createElement(Form, { ...form }, /* @__PURE__ */ React15.createElement("form", { onSubmit: form.handleSubmit(onSubmit) }, /* @__PURE__ */ React15.createElement("div", { className: "sb-space-y-4 sb-p-4" }, /* @__PURE__ */ React15.createElement(
|
|
869
875
|
FormField,
|
|
870
876
|
{
|
|
871
877
|
control: form.control,
|
|
@@ -896,7 +902,7 @@ var ItemDesignForm = (props) => {
|
|
|
896
902
|
{
|
|
897
903
|
control: form.control,
|
|
898
904
|
name: "container",
|
|
899
|
-
render: ({ field }) => /* @__PURE__ */ React15.createElement(FormItem, { className: "flex flex-row items-center justify-between space-y-0" }, /* @__PURE__ */ React15.createElement(FormLabel, null, "Volledige breedte"), /* @__PURE__ */ React15.createElement(FormControl, null, /* @__PURE__ */ React15.createElement(
|
|
905
|
+
render: ({ field }) => /* @__PURE__ */ React15.createElement(FormItem, { className: "sb-flex sb-flex-row sb-items-center sb-justify-between sb-space-y-0" }, /* @__PURE__ */ React15.createElement(FormLabel, null, "Volledige breedte"), /* @__PURE__ */ React15.createElement(FormControl, null, /* @__PURE__ */ React15.createElement(
|
|
900
906
|
Switch,
|
|
901
907
|
{
|
|
902
908
|
checked: !field.value,
|
|
@@ -904,7 +910,7 @@ var ItemDesignForm = (props) => {
|
|
|
904
910
|
}
|
|
905
911
|
)), /* @__PURE__ */ React15.createElement(FormMessage, null))
|
|
906
912
|
}
|
|
907
|
-
), /* @__PURE__ */ React15.createElement("hr", null), /* @__PURE__ */ React15.createElement("div", { className: "space-y-2" }, /* @__PURE__ */ React15.createElement(FormLabel, null, "Padding"), /* @__PURE__ */ React15.createElement("div", { className: "grid grid-cols-[1fr,auto] gap-3" }, /* @__PURE__ */ React15.createElement("div", { className: "grid grid-cols-2 items-center gap-3" }, !indipendentPadding ? /* @__PURE__ */ React15.createElement(React15.Fragment, null, /* @__PURE__ */ React15.createElement(
|
|
913
|
+
), /* @__PURE__ */ React15.createElement("hr", null), /* @__PURE__ */ React15.createElement("div", { className: "sb-space-y-2" }, /* @__PURE__ */ React15.createElement(FormLabel, null, "Padding"), /* @__PURE__ */ React15.createElement("div", { className: "sb-grid sb-grid-cols-[1fr,auto] sb-gap-3" }, /* @__PURE__ */ React15.createElement("div", { className: "sb-grid sb-grid-cols-2 sb-items-center sb-gap-3" }, !indipendentPadding ? /* @__PURE__ */ React15.createElement(React15.Fragment, null, /* @__PURE__ */ React15.createElement(
|
|
908
914
|
FormField,
|
|
909
915
|
{
|
|
910
916
|
control: form.control,
|
|
@@ -913,8 +919,8 @@ var ItemDesignForm = (props) => {
|
|
|
913
919
|
AdvancedInput,
|
|
914
920
|
{
|
|
915
921
|
...field,
|
|
916
|
-
prepend: /* @__PURE__ */ React15.createElement(AlignHorizontalSpaceAroundIcon, { className: "h-4 w-4" }),
|
|
917
|
-
append: /* @__PURE__ */ React15.createElement("span", { className: "text-
|
|
922
|
+
prepend: /* @__PURE__ */ React15.createElement(AlignHorizontalSpaceAroundIcon, { className: "sb-h-4 sb-w-4" }),
|
|
923
|
+
append: /* @__PURE__ */ React15.createElement("span", { className: "sb-text-muted-foreground" }, "px")
|
|
918
924
|
}
|
|
919
925
|
)))
|
|
920
926
|
}
|
|
@@ -927,8 +933,8 @@ var ItemDesignForm = (props) => {
|
|
|
927
933
|
AdvancedInput,
|
|
928
934
|
{
|
|
929
935
|
...field,
|
|
930
|
-
prepend: /* @__PURE__ */ React15.createElement(AlignHorizontalSpaceAroundIcon, { className: "h-4 w-4 rotate-90" }),
|
|
931
|
-
append: /* @__PURE__ */ React15.createElement("span", { className: "text-
|
|
936
|
+
prepend: /* @__PURE__ */ React15.createElement(AlignHorizontalSpaceAroundIcon, { className: "sb-h-4 sb-w-4 sb-rotate-90" }),
|
|
937
|
+
append: /* @__PURE__ */ React15.createElement("span", { className: "sb-text-muted-foreground" }, "px")
|
|
932
938
|
}
|
|
933
939
|
)))
|
|
934
940
|
}
|
|
@@ -941,8 +947,8 @@ var ItemDesignForm = (props) => {
|
|
|
941
947
|
AdvancedInput,
|
|
942
948
|
{
|
|
943
949
|
...field,
|
|
944
|
-
prepend: /* @__PURE__ */ React15.createElement(AlignHorizontalJustifyStartIcon, { className: "h-4 w-4" }),
|
|
945
|
-
append: /* @__PURE__ */ React15.createElement("span", { className: "text-
|
|
950
|
+
prepend: /* @__PURE__ */ React15.createElement(AlignHorizontalJustifyStartIcon, { className: "sb-h-4 sb-w-4" }),
|
|
951
|
+
append: /* @__PURE__ */ React15.createElement("span", { className: "sb-text-muted-foreground" }, "px")
|
|
946
952
|
}
|
|
947
953
|
)))
|
|
948
954
|
}
|
|
@@ -955,8 +961,8 @@ var ItemDesignForm = (props) => {
|
|
|
955
961
|
AdvancedInput,
|
|
956
962
|
{
|
|
957
963
|
...field,
|
|
958
|
-
prepend: /* @__PURE__ */ React15.createElement(AlignHorizontalJustifyStartIcon, { className: "h-4 w-4 rotate-90" }),
|
|
959
|
-
append: /* @__PURE__ */ React15.createElement("span", { className: "text-
|
|
964
|
+
prepend: /* @__PURE__ */ React15.createElement(AlignHorizontalJustifyStartIcon, { className: "sb-h-4 sb-w-4 sb-rotate-90" }),
|
|
965
|
+
append: /* @__PURE__ */ React15.createElement("span", { className: "sb-text-muted-foreground" }, "px")
|
|
960
966
|
}
|
|
961
967
|
)))
|
|
962
968
|
}
|
|
@@ -969,8 +975,8 @@ var ItemDesignForm = (props) => {
|
|
|
969
975
|
AdvancedInput,
|
|
970
976
|
{
|
|
971
977
|
...field,
|
|
972
|
-
prepend: /* @__PURE__ */ React15.createElement(AlignHorizontalJustifyStartIcon, { className: "h-4 w-4 rotate-180" }),
|
|
973
|
-
append: /* @__PURE__ */ React15.createElement("span", { className: "text-
|
|
978
|
+
prepend: /* @__PURE__ */ React15.createElement(AlignHorizontalJustifyStartIcon, { className: "sb-h-4 sb-w-4 sb-rotate-180" }),
|
|
979
|
+
append: /* @__PURE__ */ React15.createElement("span", { className: "sb-text-muted-foreground" }, "px")
|
|
974
980
|
}
|
|
975
981
|
)))
|
|
976
982
|
}
|
|
@@ -983,12 +989,12 @@ var ItemDesignForm = (props) => {
|
|
|
983
989
|
AdvancedInput,
|
|
984
990
|
{
|
|
985
991
|
...field,
|
|
986
|
-
prepend: /* @__PURE__ */ React15.createElement(AlignHorizontalJustifyStartIcon, { className: "h-4 w-4
|
|
987
|
-
append: /* @__PURE__ */ React15.createElement("span", { className: "text-
|
|
992
|
+
prepend: /* @__PURE__ */ React15.createElement(AlignHorizontalJustifyStartIcon, { className: "sb-h-4 sb-w-4 sb--rotate-90" }),
|
|
993
|
+
append: /* @__PURE__ */ React15.createElement("span", { className: "sb-text-muted-foreground" }, "px")
|
|
988
994
|
}
|
|
989
995
|
)))
|
|
990
996
|
}
|
|
991
|
-
))), /* @__PURE__ */ React15.createElement("div", { className: "shrink-0" }, /* @__PURE__ */ React15.createElement(
|
|
997
|
+
))), /* @__PURE__ */ React15.createElement("div", { className: "sb-shrink-0" }, /* @__PURE__ */ React15.createElement(
|
|
992
998
|
FormField,
|
|
993
999
|
{
|
|
994
1000
|
control: form.control,
|
|
@@ -996,16 +1002,16 @@ var ItemDesignForm = (props) => {
|
|
|
996
1002
|
render: ({ field }) => /* @__PURE__ */ React15.createElement(FormControl, null, /* @__PURE__ */ React15.createElement(
|
|
997
1003
|
Toggle,
|
|
998
1004
|
{
|
|
999
|
-
className: "shrink-0 flex w-8 h-8 p-0",
|
|
1005
|
+
className: "sb-shrink-0 sb-flex sb-w-8 sb-h-8 sb-p-0",
|
|
1000
1006
|
variant: "outline",
|
|
1001
1007
|
size: "sm",
|
|
1002
1008
|
pressed: field.value,
|
|
1003
1009
|
onPressedChange: field.onChange
|
|
1004
1010
|
},
|
|
1005
|
-
/* @__PURE__ */ React15.createElement(ScanIcon, { className: "h-4 w-4" })
|
|
1011
|
+
/* @__PURE__ */ React15.createElement(ScanIcon, { className: "sb-h-4 sb-w-4" })
|
|
1006
1012
|
))
|
|
1007
1013
|
}
|
|
1008
|
-
))), /* @__PURE__ */ React15.createElement(FormMessage, null)), /* @__PURE__ */ React15.createElement("div", { className: "space-y-2" }, /* @__PURE__ */ React15.createElement(FormLabel, null, "Margin"), /* @__PURE__ */ React15.createElement("div", { className: "grid grid-cols-[1fr,auto] gap-3" }, /* @__PURE__ */ React15.createElement("div", { className: "grid grid-cols-2 items-center gap-3" }, !indipendentMargin ? /* @__PURE__ */ React15.createElement(React15.Fragment, null, /* @__PURE__ */ React15.createElement(
|
|
1014
|
+
))), /* @__PURE__ */ React15.createElement(FormMessage, null)), /* @__PURE__ */ React15.createElement("div", { className: "sb-space-y-2" }, /* @__PURE__ */ React15.createElement(FormLabel, null, "Margin"), /* @__PURE__ */ React15.createElement("div", { className: "sb-grid sb-grid-cols-[1fr,auto] sb-gap-3" }, /* @__PURE__ */ React15.createElement("div", { className: "sb-grid sb-grid-cols-2 sb-items-center sb-gap-3" }, !indipendentMargin ? /* @__PURE__ */ React15.createElement(React15.Fragment, null, /* @__PURE__ */ React15.createElement(
|
|
1009
1015
|
FormField,
|
|
1010
1016
|
{
|
|
1011
1017
|
control: form.control,
|
|
@@ -1014,8 +1020,8 @@ var ItemDesignForm = (props) => {
|
|
|
1014
1020
|
AdvancedInput,
|
|
1015
1021
|
{
|
|
1016
1022
|
...field,
|
|
1017
|
-
prepend: /* @__PURE__ */ React15.createElement(AlignHorizontalSpaceAroundIcon, { className: "h-4 w-4" }),
|
|
1018
|
-
append: /* @__PURE__ */ React15.createElement("span", { className: "text-
|
|
1023
|
+
prepend: /* @__PURE__ */ React15.createElement(AlignHorizontalSpaceAroundIcon, { className: "sb-h-4 sb-w-4" }),
|
|
1024
|
+
append: /* @__PURE__ */ React15.createElement("span", { className: "sb-text-muted-foreground" }, "px")
|
|
1019
1025
|
}
|
|
1020
1026
|
)))
|
|
1021
1027
|
}
|
|
@@ -1028,8 +1034,8 @@ var ItemDesignForm = (props) => {
|
|
|
1028
1034
|
AdvancedInput,
|
|
1029
1035
|
{
|
|
1030
1036
|
...field,
|
|
1031
|
-
prepend: /* @__PURE__ */ React15.createElement(AlignHorizontalSpaceAroundIcon, { className: "h-4 w-4 rotate-90" }),
|
|
1032
|
-
append: /* @__PURE__ */ React15.createElement("span", { className: "text-
|
|
1037
|
+
prepend: /* @__PURE__ */ React15.createElement(AlignHorizontalSpaceAroundIcon, { className: "sb-h-4 sb-w-4 sb-rotate-90" }),
|
|
1038
|
+
append: /* @__PURE__ */ React15.createElement("span", { className: "sb-text-muted-foreground" }, "px")
|
|
1033
1039
|
}
|
|
1034
1040
|
)))
|
|
1035
1041
|
}
|
|
@@ -1042,8 +1048,8 @@ var ItemDesignForm = (props) => {
|
|
|
1042
1048
|
AdvancedInput,
|
|
1043
1049
|
{
|
|
1044
1050
|
...field,
|
|
1045
|
-
prepend: /* @__PURE__ */ React15.createElement(AlignHorizontalJustifyStartIcon, { className: "h-4 w-4" }),
|
|
1046
|
-
append: /* @__PURE__ */ React15.createElement("span", { className: "text-
|
|
1051
|
+
prepend: /* @__PURE__ */ React15.createElement(AlignHorizontalJustifyStartIcon, { className: "sb-h-4 sb-w-4" }),
|
|
1052
|
+
append: /* @__PURE__ */ React15.createElement("span", { className: "sb-text-muted-foreground" }, "px")
|
|
1047
1053
|
}
|
|
1048
1054
|
)))
|
|
1049
1055
|
}
|
|
@@ -1056,8 +1062,8 @@ var ItemDesignForm = (props) => {
|
|
|
1056
1062
|
AdvancedInput,
|
|
1057
1063
|
{
|
|
1058
1064
|
...field,
|
|
1059
|
-
prepend: /* @__PURE__ */ React15.createElement(AlignHorizontalJustifyStartIcon, { className: "h-4 w-4 rotate-90" }),
|
|
1060
|
-
append: /* @__PURE__ */ React15.createElement("span", { className: "text-
|
|
1065
|
+
prepend: /* @__PURE__ */ React15.createElement(AlignHorizontalJustifyStartIcon, { className: "sb-h-4 sb-w-4 sb-rotate-90" }),
|
|
1066
|
+
append: /* @__PURE__ */ React15.createElement("span", { className: "sb-text-muted-foreground" }, "px")
|
|
1061
1067
|
}
|
|
1062
1068
|
)))
|
|
1063
1069
|
}
|
|
@@ -1070,8 +1076,8 @@ var ItemDesignForm = (props) => {
|
|
|
1070
1076
|
AdvancedInput,
|
|
1071
1077
|
{
|
|
1072
1078
|
...field,
|
|
1073
|
-
prepend: /* @__PURE__ */ React15.createElement(AlignHorizontalJustifyStartIcon, { className: "h-4 w-4 rotate-180" }),
|
|
1074
|
-
append: /* @__PURE__ */ React15.createElement("span", { className: "text-
|
|
1079
|
+
prepend: /* @__PURE__ */ React15.createElement(AlignHorizontalJustifyStartIcon, { className: "sb-h-4 sb-w-4 sb-rotate-180" }),
|
|
1080
|
+
append: /* @__PURE__ */ React15.createElement("span", { className: "sb-text-muted-foreground" }, "px")
|
|
1075
1081
|
}
|
|
1076
1082
|
)))
|
|
1077
1083
|
}
|
|
@@ -1084,12 +1090,12 @@ var ItemDesignForm = (props) => {
|
|
|
1084
1090
|
AdvancedInput,
|
|
1085
1091
|
{
|
|
1086
1092
|
...field,
|
|
1087
|
-
prepend: /* @__PURE__ */ React15.createElement(AlignHorizontalJustifyStartIcon, { className: "h-4 w-4
|
|
1088
|
-
append: /* @__PURE__ */ React15.createElement("span", { className: "text-
|
|
1093
|
+
prepend: /* @__PURE__ */ React15.createElement(AlignHorizontalJustifyStartIcon, { className: "sb-h-4 sb-w-4 sb--rotate-90" }),
|
|
1094
|
+
append: /* @__PURE__ */ React15.createElement("span", { className: "sb-text-muted-foreground" }, "px")
|
|
1089
1095
|
}
|
|
1090
1096
|
)))
|
|
1091
1097
|
}
|
|
1092
|
-
))), /* @__PURE__ */ React15.createElement("div", { className: "shrink-0" }, /* @__PURE__ */ React15.createElement(
|
|
1098
|
+
))), /* @__PURE__ */ React15.createElement("div", { className: "sb-shrink-0" }, /* @__PURE__ */ React15.createElement(
|
|
1093
1099
|
FormField,
|
|
1094
1100
|
{
|
|
1095
1101
|
control: form.control,
|
|
@@ -1097,13 +1103,13 @@ var ItemDesignForm = (props) => {
|
|
|
1097
1103
|
render: ({ field }) => /* @__PURE__ */ React15.createElement(FormControl, null, /* @__PURE__ */ React15.createElement(
|
|
1098
1104
|
Toggle,
|
|
1099
1105
|
{
|
|
1100
|
-
className: "shrink-0 flex w-8 h-8 p-0",
|
|
1106
|
+
className: "sb-shrink-0 sb-flex sb-w-8 sb-h-8 sb-p-0",
|
|
1101
1107
|
variant: "outline",
|
|
1102
1108
|
size: "sm",
|
|
1103
1109
|
pressed: field.value,
|
|
1104
1110
|
onPressedChange: field.onChange
|
|
1105
1111
|
},
|
|
1106
|
-
/* @__PURE__ */ React15.createElement(ScanIcon, { className: "h-4 w-4" })
|
|
1112
|
+
/* @__PURE__ */ React15.createElement(ScanIcon, { className: "sb-h-4 sb-w-4" })
|
|
1107
1113
|
))
|
|
1108
1114
|
}
|
|
1109
1115
|
))), /* @__PURE__ */ React15.createElement(FormMessage, null)))));
|
|
@@ -1128,13 +1134,13 @@ var RenderInput = (props) => {
|
|
|
1128
1134
|
variant: "outline",
|
|
1129
1135
|
size: "sm",
|
|
1130
1136
|
className: cn(
|
|
1131
|
-
"w-full flex justify-start text-left font-normal",
|
|
1132
|
-
!field.value && "text-muted-foreground"
|
|
1137
|
+
"sb-w-full sb-flex sb-justify-start sb-text-left sb-font-normal",
|
|
1138
|
+
!field.value && "sb-text-muted-foreground"
|
|
1133
1139
|
)
|
|
1134
1140
|
},
|
|
1135
|
-
/* @__PURE__ */ React15.createElement(CalendarIcon, { className: "mr-2 h-4 w-4" }),
|
|
1141
|
+
/* @__PURE__ */ React15.createElement(CalendarIcon, { className: "sb-mr-2 sb-h-4 sb-w-4" }),
|
|
1136
1142
|
field.value ? format(field.value, "PPP") : /* @__PURE__ */ React15.createElement("span", null, "Pick a date")
|
|
1137
|
-
)), /* @__PURE__ */ React15.createElement(PopoverContent, { className: "w-auto p-0", align: "start" }, /* @__PURE__ */ React15.createElement(
|
|
1143
|
+
)), /* @__PURE__ */ React15.createElement(PopoverContent, { className: "sb-w-auto sb-p-0", align: "start" }, /* @__PURE__ */ React15.createElement(
|
|
1138
1144
|
Calendar,
|
|
1139
1145
|
{
|
|
1140
1146
|
mode: "single",
|
|
@@ -1144,13 +1150,13 @@ var RenderInput = (props) => {
|
|
|
1144
1150
|
}
|
|
1145
1151
|
)))), input.helperText && /* @__PURE__ */ React15.createElement(FormDescription, null, input.helperText), /* @__PURE__ */ React15.createElement(FormMessage, null));
|
|
1146
1152
|
case "boolean":
|
|
1147
|
-
return /* @__PURE__ */ React15.createElement(FormItem, { className: "flex flex-row items-center justify-between space-y-0" }, /* @__PURE__ */ React15.createElement(FormLabel, null, input.friendlyName || input.name), /* @__PURE__ */ React15.createElement(FormControl, null, /* @__PURE__ */ React15.createElement(Switch, { checked: field.value, onCheckedChange: field.onChange })), input.helperText && /* @__PURE__ */ React15.createElement(FormDescription, null, input.helperText), /* @__PURE__ */ React15.createElement(FormMessage, null));
|
|
1153
|
+
return /* @__PURE__ */ React15.createElement(FormItem, { className: "sb-flex sb-flex-row sb-items-center sb-justify-between sb-space-y-0" }, /* @__PURE__ */ React15.createElement(FormLabel, null, input.friendlyName || input.name), /* @__PURE__ */ React15.createElement(FormControl, null, /* @__PURE__ */ React15.createElement(Switch, { checked: field.value, onCheckedChange: field.onChange })), input.helperText && /* @__PURE__ */ React15.createElement(FormDescription, null, input.helperText), /* @__PURE__ */ React15.createElement(FormMessage, null));
|
|
1148
1154
|
case "file":
|
|
1149
1155
|
return /* @__PURE__ */ React15.createElement(FormItem, null, /* @__PURE__ */ React15.createElement(FormLabel, null, input.friendlyName || input.name), /* @__PURE__ */ React15.createElement(FormControl, null, /* @__PURE__ */ React15.createElement(
|
|
1150
1156
|
MediaInput,
|
|
1151
1157
|
{
|
|
1152
|
-
className: "grid grid-cols-2 gap-1",
|
|
1153
|
-
itemClassName: "aspect-video h-auto w-full",
|
|
1158
|
+
className: "sb-grid sb-grid-cols-2 sb-gap-1",
|
|
1159
|
+
itemClassName: "sb-aspect-video sb-h-auto sb-w-full",
|
|
1154
1160
|
multiple: false,
|
|
1155
1161
|
onFilesChange: (files) => field.onChange(files[0]),
|
|
1156
1162
|
onError: (e) => console.error(
|
|
@@ -1167,7 +1173,14 @@ var RenderInput = (props) => {
|
|
|
1167
1173
|
};
|
|
1168
1174
|
var DeleteButton = ({ contentId }) => {
|
|
1169
1175
|
const { deleteContent } = useBuilder();
|
|
1170
|
-
return /* @__PURE__ */ React15.createElement(AlertDialog, null, /* @__PURE__ */ React15.createElement(AlertDialogTrigger, { asChild: true }, /* @__PURE__ */ React15.createElement(
|
|
1176
|
+
return /* @__PURE__ */ React15.createElement(AlertDialog, null, /* @__PURE__ */ React15.createElement(AlertDialogTrigger, { asChild: true }, /* @__PURE__ */ React15.createElement(
|
|
1177
|
+
Button,
|
|
1178
|
+
{
|
|
1179
|
+
variant: "ghost",
|
|
1180
|
+
className: "sb-w-8 sb-h-8 sb-p-0 sb-text-destructive"
|
|
1181
|
+
},
|
|
1182
|
+
/* @__PURE__ */ React15.createElement(Trash2Icon, { className: "sb-h-5 sb-w-5" })
|
|
1183
|
+
)), /* @__PURE__ */ React15.createElement(AlertDialogContent, null, /* @__PURE__ */ React15.createElement(AlertDialogDescription, null, "Weet je zeker dat je dit blok wilt verwijderen?"), /* @__PURE__ */ React15.createElement(AlertDialogFooter, null, /* @__PURE__ */ React15.createElement(AlertDialogCancel, null, "Annuleren"), /* @__PURE__ */ React15.createElement(
|
|
1171
1184
|
AlertDialogAction,
|
|
1172
1185
|
{
|
|
1173
1186
|
className: buttonVariants({ variant: "destructive" }),
|
|
@@ -1184,7 +1197,7 @@ var DesignWrapper = (props) => {
|
|
|
1184
1197
|
return /* @__PURE__ */ React15.createElement(
|
|
1185
1198
|
"div",
|
|
1186
1199
|
{
|
|
1187
|
-
className: cn("relative", className),
|
|
1200
|
+
className: cn("sb-relative", className),
|
|
1188
1201
|
style: { ...!src && { background }, ...rest }
|
|
1189
1202
|
},
|
|
1190
1203
|
src && /* @__PURE__ */ React15.createElement(
|
|
@@ -1193,10 +1206,10 @@ var DesignWrapper = (props) => {
|
|
|
1193
1206
|
src,
|
|
1194
1207
|
alt: "",
|
|
1195
1208
|
fill: true,
|
|
1196
|
-
className: "object-cover absolute inset-0 pointer-events-none
|
|
1209
|
+
className: "sb-object-cover sb-absolute sb-inset-0 sb-pointer-events-none sb--z-[1]"
|
|
1197
1210
|
}
|
|
1198
1211
|
),
|
|
1199
|
-
container ? /* @__PURE__ */ React15.createElement("div", { className: "container mx-auto" }, children) : children
|
|
1212
|
+
container ? /* @__PURE__ */ React15.createElement("div", { className: "sb-container sb-mx-auto" }, children) : children
|
|
1200
1213
|
);
|
|
1201
1214
|
};
|
|
1202
1215
|
|
|
@@ -1209,7 +1222,7 @@ var BuildContainerInner = (props) => {
|
|
|
1209
1222
|
"[simple-builder]: Multiple content blocks detected when using property multiple false."
|
|
1210
1223
|
);
|
|
1211
1224
|
}
|
|
1212
|
-
return /* @__PURE__ */ React15.createElement("div", null, items.length <= 0 ? /* @__PURE__ */ React15.createElement(AddContentPlaceholder, { parent: id, container: name, index: 0 }) : multiple && /* @__PURE__ */ React15.createElement(AddContentDividerButton, { parent: id, container: name, index: 0 }), items.map((item, i) => /* @__PURE__ */ React15.createElement(React15.Fragment, { key: item.id }, /* @__PURE__ */ React15.createElement("div", { className: "relative sb-container-item" }, /* @__PURE__ */ React15.createElement(DesignWrapper, { styles: item.styles }, builder.bindComponent(item, true)), /* @__PURE__ */ React15.createElement(
|
|
1225
|
+
return /* @__PURE__ */ React15.createElement("div", null, items.length <= 0 ? /* @__PURE__ */ React15.createElement(AddContentPlaceholder, { parent: id, container: name, index: 0 }) : multiple && /* @__PURE__ */ React15.createElement(AddContentDividerButton, { parent: id, container: name, index: 0 }), items.map((item, i) => /* @__PURE__ */ React15.createElement(React15.Fragment, { key: item.id }, /* @__PURE__ */ React15.createElement("div", { className: "sb-relative sb-container-item" }, /* @__PURE__ */ React15.createElement(DesignWrapper, { styles: item.styles }, builder.bindComponent(item, true)), /* @__PURE__ */ React15.createElement(
|
|
1213
1226
|
ContainerItemToolbar,
|
|
1214
1227
|
{
|
|
1215
1228
|
contentId: item.id,
|
|
@@ -1229,13 +1242,13 @@ var build_container_client_default = BuildContainerInner;
|
|
|
1229
1242
|
var AddContentButton = (props) => {
|
|
1230
1243
|
const components = builder.getComponents();
|
|
1231
1244
|
const { addContent } = useBuilder();
|
|
1232
|
-
return /* @__PURE__ */ React15.createElement(Popover, null, /* @__PURE__ */ React15.createElement(PopoverTrigger, { asChild: true }, props.children), /* @__PURE__ */ React15.createElement(PopoverContent, { className: "p-1" }, /* @__PURE__ */ React15.createElement("div", { className: "grid grid-cols-2 gap-2" }, components.map((component) => {
|
|
1245
|
+
return /* @__PURE__ */ React15.createElement(Popover, null, /* @__PURE__ */ React15.createElement(PopoverTrigger, { asChild: true }, props.children), /* @__PURE__ */ React15.createElement(PopoverContent, { className: "sb-p-1" }, /* @__PURE__ */ React15.createElement("div", { className: "sb-grid sb-grid-cols-2 sb-gap-2" }, components.map((component) => {
|
|
1233
1246
|
const Icon = component.icon ?? ImageIcon;
|
|
1234
1247
|
return /* @__PURE__ */ React15.createElement(PopoverClose, { key: component.name, asChild: true }, /* @__PURE__ */ React15.createElement(
|
|
1235
1248
|
Button,
|
|
1236
1249
|
{
|
|
1237
1250
|
variant: "ghost",
|
|
1238
|
-
className: "justify-start",
|
|
1251
|
+
className: "sb-justify-start",
|
|
1239
1252
|
onClick: () => {
|
|
1240
1253
|
addContent(
|
|
1241
1254
|
component.name,
|
|
@@ -1245,22 +1258,22 @@ var AddContentButton = (props) => {
|
|
|
1245
1258
|
);
|
|
1246
1259
|
}
|
|
1247
1260
|
},
|
|
1248
|
-
/* @__PURE__ */ React15.createElement(Icon, { className: "mr-2 h-4 w-4 shrink-0" }),
|
|
1261
|
+
/* @__PURE__ */ React15.createElement(Icon, { className: "sb-mr-2 sb-h-4 sb-w-4 sb-shrink-0" }),
|
|
1249
1262
|
component.friendlyName ?? component.name
|
|
1250
1263
|
));
|
|
1251
1264
|
}))));
|
|
1252
1265
|
};
|
|
1253
1266
|
var AddContentPlaceholder = (props) => {
|
|
1254
|
-
return /* @__PURE__ */ React15.createElement(AddContentButton, { ...props }, /* @__PURE__ */ React15.createElement("div", { className: "flex justify-center bg-
|
|
1267
|
+
return /* @__PURE__ */ React15.createElement(AddContentButton, { ...props }, /* @__PURE__ */ React15.createElement("div", { className: "sb-flex sb-justify-center sb-bg-primary/50 p-4" }, /* @__PURE__ */ React15.createElement(Button, { size: "sm" }, /* @__PURE__ */ React15.createElement(PlusIcon, { className: "sb-mr-2 sb-h-4 sb-w-4" }), "Blok Toevoegen")));
|
|
1255
1268
|
};
|
|
1256
1269
|
var AddContentDividerButton = (props) => {
|
|
1257
|
-
return /* @__PURE__ */ React15.createElement(AddContentButton, { ...props }, /* @__PURE__ */ React15.createElement("div", { className: "w-full h-1
|
|
1270
|
+
return /* @__PURE__ */ React15.createElement(AddContentButton, { ...props }, /* @__PURE__ */ React15.createElement("div", { className: "sb-w-full sb-h-1 sb--my-[2px] sb-bg-primary sb-relative sb-z-20 sb-opacity-0 add-content-divider-button sb-transition-opacity" }, /* @__PURE__ */ React15.createElement(
|
|
1258
1271
|
Button,
|
|
1259
1272
|
{
|
|
1260
1273
|
size: "sm",
|
|
1261
|
-
className: "absolute left-1/2 top-1/2
|
|
1274
|
+
className: "sb-absolute sb-left-1/2 sb-top-1/2 sb--translate-y-1/2 sb--translate-x-1/2 sb-shadow"
|
|
1262
1275
|
},
|
|
1263
|
-
/* @__PURE__ */ React15.createElement(PlusIcon, { className: "mr-2 h-4 w-4" }),
|
|
1276
|
+
/* @__PURE__ */ React15.createElement(PlusIcon, { className: "sb-mr-2 sb-h-4 sb-w-4" }),
|
|
1264
1277
|
"Blok Toevoegen"
|
|
1265
1278
|
)));
|
|
1266
1279
|
};
|