@simple-builder/react 1.0.9 → 1.0.11

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.
@@ -1,9 +1,9 @@
1
1
  'use client';
2
2
  'use strict';
3
3
 
4
- require('./chunk-VFH3LVDU.js');
5
- var chunkYGI2WZVP_js = require('./chunk-YGI2WZVP.js');
6
- var chunkECJUPPTG_js = require('./chunk-ECJUPPTG.js');
4
+ require('./chunk-T4HKIDFE.js');
5
+ var chunkGXNKJBJA_js = require('./chunk-GXNKJBJA.js');
6
+ var chunkB4NNVFW6_js = require('./chunk-B4NNVFW6.js');
7
7
  var React11 = require('react');
8
8
  var lucideReact = require('lucide-react');
9
9
  var AlertDialogPrimitive = require('@radix-ui/react-alert-dialog');
@@ -18,6 +18,7 @@ var zod$1 = require('@hookform/resolvers/zod');
18
18
  var zod = require('zod');
19
19
  var TabsPrimitive = require('@radix-ui/react-tabs');
20
20
  var TogglePrimitive = require('@radix-ui/react-toggle');
21
+ var ScrollAreaPrimitive = require('@radix-ui/react-scroll-area');
21
22
 
22
23
  function _interopNamespace(e) {
23
24
  if (e && e.__esModule) return e;
@@ -44,6 +45,7 @@ var LabelPrimitive__namespace = /*#__PURE__*/_interopNamespace(LabelPrimitive);
44
45
  var SwitchPrimitives__namespace = /*#__PURE__*/_interopNamespace(SwitchPrimitives);
45
46
  var TabsPrimitive__namespace = /*#__PURE__*/_interopNamespace(TabsPrimitive);
46
47
  var TogglePrimitive__namespace = /*#__PURE__*/_interopNamespace(TogglePrimitive);
48
+ var ScrollAreaPrimitive__namespace = /*#__PURE__*/_interopNamespace(ScrollAreaPrimitive);
47
49
 
48
50
  var AlertDialog = AlertDialogPrimitive__namespace.Root;
49
51
  var AlertDialogTrigger = AlertDialogPrimitive__namespace.Trigger;
@@ -51,7 +53,7 @@ var AlertDialogPortal = AlertDialogPrimitive__namespace.Portal;
51
53
  var AlertDialogOverlay = React11__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ React11__namespace.createElement(
52
54
  AlertDialogPrimitive__namespace.Overlay,
53
55
  {
54
- className: chunkECJUPPTG_js.cn(
56
+ className: chunkB4NNVFW6_js.cn(
55
57
  "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",
56
58
  className
57
59
  ),
@@ -64,7 +66,7 @@ var AlertDialogContent = React11__namespace.forwardRef(({ className, ...props },
64
66
  AlertDialogPrimitive__namespace.Content,
65
67
  {
66
68
  ref,
67
- className: chunkECJUPPTG_js.cn(
69
+ className: chunkB4NNVFW6_js.cn(
68
70
  "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",
69
71
  className
70
72
  ),
@@ -78,7 +80,7 @@ var AlertDialogFooter = ({
78
80
  }) => /* @__PURE__ */ React11__namespace.createElement(
79
81
  "div",
80
82
  {
81
- className: chunkECJUPPTG_js.cn(
83
+ className: chunkB4NNVFW6_js.cn(
82
84
  "sb-flex sb-flex-col-reverse sm:sb-flex-row sm:sb-justify-end sm:sb-space-x-2",
83
85
  className
84
86
  ),
@@ -90,7 +92,7 @@ var AlertDialogTitle = React11__namespace.forwardRef(({ className, ...props }, r
90
92
  AlertDialogPrimitive__namespace.Title,
91
93
  {
92
94
  ref,
93
- className: chunkECJUPPTG_js.cn("sb-text-lg sb-font-semibold", className),
95
+ className: chunkB4NNVFW6_js.cn("sb-text-lg sb-font-semibold", className),
94
96
  ...props
95
97
  }
96
98
  ));
@@ -99,7 +101,7 @@ var AlertDialogDescription = React11__namespace.forwardRef(({ className, ...prop
99
101
  AlertDialogPrimitive__namespace.Description,
100
102
  {
101
103
  ref,
102
- className: chunkECJUPPTG_js.cn("sb-text-sm sb-text-muted-foreground", className),
104
+ className: chunkB4NNVFW6_js.cn("sb-text-sm sb-text-muted-foreground", className),
103
105
  ...props
104
106
  }
105
107
  ));
@@ -108,7 +110,7 @@ var AlertDialogAction = React11__namespace.forwardRef(({ className, ...props },
108
110
  AlertDialogPrimitive__namespace.Action,
109
111
  {
110
112
  ref,
111
- className: chunkECJUPPTG_js.cn(chunkYGI2WZVP_js.buttonVariants(), className),
113
+ className: chunkB4NNVFW6_js.cn(chunkGXNKJBJA_js.buttonVariants(), className),
112
114
  ...props
113
115
  }
114
116
  ));
@@ -117,8 +119,8 @@ var AlertDialogCancel = React11__namespace.forwardRef(({ className, ...props },
117
119
  AlertDialogPrimitive__namespace.Cancel,
118
120
  {
119
121
  ref,
120
- className: chunkECJUPPTG_js.cn(
121
- chunkYGI2WZVP_js.buttonVariants({ variant: "outline" }),
122
+ className: chunkB4NNVFW6_js.cn(
123
+ chunkGXNKJBJA_js.buttonVariants({ variant: "outline" }),
122
124
  "sb-mt-2 sm:sb-mt-0",
123
125
  className
124
126
  ),
@@ -135,7 +137,7 @@ var PopoverContent = React11__namespace.forwardRef(({ className, align = "center
135
137
  ref,
136
138
  align,
137
139
  sideOffset,
138
- className: chunkECJUPPTG_js.cn(
140
+ className: chunkB4NNVFW6_js.cn(
139
141
  "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",
140
142
  className
141
143
  ),
@@ -153,15 +155,15 @@ function Calendar({
153
155
  reactDayPicker.DayPicker,
154
156
  {
155
157
  showOutsideDays,
156
- className: chunkECJUPPTG_js.cn("sb-p-3 sb-font-roboto", className),
158
+ className: chunkB4NNVFW6_js.cn("sb-p-3 sb-font-roboto", className),
157
159
  classNames: {
158
160
  months: "sb-flex sb-flex-col sm:sb-flex-row sb-space-y-4 sm:sb-space-x-4 sm:sb-space-y-0",
159
161
  month: "sb-space-y-4",
160
162
  caption: "sb-flex sb-justify-center sb-pt-1 sb-relative sb-items-center",
161
163
  caption_label: "sb-text-sm sb-font-medium",
162
164
  nav: "sb-space-x-1 sb-flex sb-items-center",
163
- nav_button: chunkECJUPPTG_js.cn(
164
- chunkYGI2WZVP_js.buttonVariants({ variant: "outline" }),
165
+ nav_button: chunkB4NNVFW6_js.cn(
166
+ chunkGXNKJBJA_js.buttonVariants({ variant: "outline" }),
165
167
  "sb-h-7 sb-w-7 sb-bg-transparent sb-p-0 sb-opacity-50 hover:sb-opacity-100"
166
168
  ),
167
169
  nav_button_previous: "sb-absolute sb-left-1",
@@ -170,12 +172,12 @@ function Calendar({
170
172
  head_row: "sb-flex",
171
173
  head_cell: "sb-text-muted-foreground sb-rounded-md sb-w-8 sb-font-normal sb-text-[0.8rem]",
172
174
  row: "sb-flex sb-w-full sb-mt-2",
173
- cell: chunkECJUPPTG_js.cn(
175
+ cell: chunkB4NNVFW6_js.cn(
174
176
  "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",
175
177
  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"
176
178
  ),
177
- day: chunkECJUPPTG_js.cn(
178
- chunkYGI2WZVP_js.buttonVariants({ variant: "ghost" }),
179
+ day: chunkB4NNVFW6_js.cn(
180
+ chunkGXNKJBJA_js.buttonVariants({ variant: "ghost" }),
179
181
  "sb-h-8 sb-w-8 sb-p-0 sb-font-normal aria-selected:sb-opacity-100"
180
182
  ),
181
183
  day_range_start: "day-range-start",
@@ -211,11 +213,11 @@ var ColorPicker = (props) => {
211
213
  "#FF0000"
212
214
  ];
213
215
  return /* @__PURE__ */ React11__namespace.createElement(Popover, null, /* @__PURE__ */ React11__namespace.createElement(PopoverTrigger, { asChild: true }, /* @__PURE__ */ React11__namespace.createElement(
214
- chunkYGI2WZVP_js.Button,
216
+ chunkGXNKJBJA_js.Button,
215
217
  {
216
218
  variant: "outline",
217
219
  size: "sm",
218
- className: chunkECJUPPTG_js.cn(
220
+ className: chunkB4NNVFW6_js.cn(
219
221
  "sb-justify-start sb-text-left sb-font-normal sb-normal-case sb-w-full",
220
222
  !color && "sb-text-muted-foreground",
221
223
  className
@@ -238,7 +240,7 @@ var ColorPicker = (props) => {
238
240
  }
239
241
  ))));
240
242
  };
241
- var labelVariants = chunkECJUPPTG_js.tv({
243
+ var labelVariants = chunkB4NNVFW6_js.tv({
242
244
  base: "sb-text-sm sb-font-medium sb-font-roboto sb-leading-none peer-disabled:sb-cursor-not-allowed peer-disabled:sb-opacity-70"
243
245
  });
244
246
  var Label = React11__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ React11__namespace.createElement(
@@ -284,7 +286,7 @@ var FormItemContext = React11__namespace.createContext(
284
286
  );
285
287
  var FormItem = React11__namespace.forwardRef(({ className, ...props }, ref) => {
286
288
  const id = React11__namespace.useId();
287
- return /* @__PURE__ */ React11__namespace.createElement(FormItemContext.Provider, { value: { id } }, /* @__PURE__ */ React11__namespace.createElement("div", { ref, className: chunkECJUPPTG_js.cn("sb-space-y-2", className), ...props }));
289
+ return /* @__PURE__ */ React11__namespace.createElement(FormItemContext.Provider, { value: { id } }, /* @__PURE__ */ React11__namespace.createElement("div", { ref, className: chunkB4NNVFW6_js.cn("sb-space-y-2", className), ...props }));
288
290
  });
289
291
  FormItem.displayName = "FormItem";
290
292
  var FormLabel = React11__namespace.forwardRef(({ className, ...props }, ref) => {
@@ -293,7 +295,7 @@ var FormLabel = React11__namespace.forwardRef(({ className, ...props }, ref) =>
293
295
  Label,
294
296
  {
295
297
  ref,
296
- className: chunkECJUPPTG_js.cn(error && "sb-text-destructive", className),
298
+ className: chunkB4NNVFW6_js.cn(error && "sb-text-destructive", className),
297
299
  htmlFor: formItemId,
298
300
  ...props
299
301
  }
@@ -321,7 +323,7 @@ var FormDescription = React11__namespace.forwardRef(({ className, ...props }, re
321
323
  {
322
324
  ref,
323
325
  id: formDescriptionId,
324
- className: chunkECJUPPTG_js.cn(
326
+ className: chunkB4NNVFW6_js.cn(
325
327
  "sb-text-sm sb-font-roboto sb-text-muted-foreground",
326
328
  className
327
329
  ),
@@ -341,7 +343,7 @@ var FormMessage = React11__namespace.forwardRef(({ className, children, ...props
341
343
  {
342
344
  ref,
343
345
  id: formMessageId,
344
- className: chunkECJUPPTG_js.cn(
346
+ className: chunkB4NNVFW6_js.cn(
345
347
  "sb-text-sm sb-font-roboto sb-font-medium sb-text-destructive",
346
348
  className
347
349
  ),
@@ -357,7 +359,7 @@ var Input = React11__namespace.forwardRef(
357
359
  "input",
358
360
  {
359
361
  type,
360
- className: chunkECJUPPTG_js.cn(
362
+ className: chunkB4NNVFW6_js.cn(
361
363
  "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",
362
364
  className
363
365
  ),
@@ -451,8 +453,8 @@ var MediaInput = (props) => {
451
453
  body: JSON.stringify({ src })
452
454
  });
453
455
  };
454
- return /* @__PURE__ */ React11__namespace.createElement("div", { className: chunkECJUPPTG_js.cn("flex flex-wrap gap-4", props.className) }, sources.map((src) => /* @__PURE__ */ React11__namespace.createElement(MediaInputItem, { key: src, className: chunkECJUPPTG_js.cn("group", props.itemClassName) }, /* @__PURE__ */ React11__namespace.createElement(
455
- chunkECJUPPTG_js.Image,
456
+ return /* @__PURE__ */ React11__namespace.createElement("div", { className: chunkB4NNVFW6_js.cn("flex flex-wrap gap-4", props.className) }, sources.map((src) => /* @__PURE__ */ React11__namespace.createElement(MediaInputItem, { key: src, className: chunkB4NNVFW6_js.cn("group", props.itemClassName) }, /* @__PURE__ */ React11__namespace.createElement(
457
+ chunkB4NNVFW6_js.Image,
456
458
  {
457
459
  src,
458
460
  alt: "",
@@ -470,7 +472,7 @@ var MediaInput = (props) => {
470
472
  MediaInputItem,
471
473
  {
472
474
  key: i,
473
- className: chunkECJUPPTG_js.cn(
475
+ className: chunkB4NNVFW6_js.cn(
474
476
  "sb-flex sb-h-28 sb-w-28 sb-items-center sb-justify-center",
475
477
  props.itemClassName
476
478
  )
@@ -480,7 +482,7 @@ var MediaInput = (props) => {
480
482
  "label",
481
483
  {
482
484
  htmlFor: id,
483
- className: chunkECJUPPTG_js.cn(
485
+ className: chunkB4NNVFW6_js.cn(
484
486
  "sb-flex sb-h-28 sb-w-28 sb-cursor-pointer sb-items-center sb-justify-center sb-rounded-lg sb-border",
485
487
  props.itemClassName
486
488
  )
@@ -503,7 +505,7 @@ var MediaInputItem = (props) => {
503
505
  return /* @__PURE__ */ React11__namespace.createElement(
504
506
  "div",
505
507
  {
506
- className: chunkECJUPPTG_js.cn(
508
+ className: chunkB4NNVFW6_js.cn(
507
509
  "sb-relative sb-h-28 sb-w-28 sb-overflow-hidden sb-rounded-lg sb-border",
508
510
  props.className
509
511
  )
@@ -523,7 +525,7 @@ var MediaInputError = class extends Error {
523
525
  var Switch = React11__namespace.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ React11__namespace.createElement(
524
526
  SwitchPrimitives__namespace.Root,
525
527
  {
526
- className: chunkECJUPPTG_js.cn(
528
+ className: chunkB4NNVFW6_js.cn(
527
529
  "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",
528
530
  className
529
531
  ),
@@ -533,7 +535,7 @@ var Switch = React11__namespace.forwardRef(({ className, ...props }, ref) => /*
533
535
  /* @__PURE__ */ React11__namespace.createElement(
534
536
  SwitchPrimitives__namespace.Thumb,
535
537
  {
536
- className: chunkECJUPPTG_js.cn(
538
+ className: chunkB4NNVFW6_js.cn(
537
539
  "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"
538
540
  )
539
541
  }
@@ -545,7 +547,7 @@ var Textarea = React11__namespace.forwardRef(
545
547
  return /* @__PURE__ */ React11__namespace.createElement(
546
548
  "textarea",
547
549
  {
548
- className: chunkECJUPPTG_js.cn(
550
+ className: chunkB4NNVFW6_js.cn(
549
551
  "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",
550
552
  className
551
553
  ),
@@ -560,8 +562,8 @@ Textarea.displayName = "Textarea";
560
562
  // src/components/container-item-form.tsx
561
563
  var ContainerItemForm = (props) => {
562
564
  const { item } = props;
563
- const { patchItem } = chunkYGI2WZVP_js.useBuilder();
564
- const component = chunkECJUPPTG_js.builder.getComponent(item.component);
565
+ const { patchItem } = chunkGXNKJBJA_js.useBuilder();
566
+ const component = chunkB4NNVFW6_js.builder.getComponent(item.component);
565
567
  if (!component) {
566
568
  throw new Error(
567
569
  `[simple-builder]: Component with id ${item.component} not found in container item form component`
@@ -586,35 +588,133 @@ var ContainerItemForm = (props) => {
586
588
  return () => subscription.unsubscribe();
587
589
  }, [form.watch, form.handleSubmit]);
588
590
  return /* @__PURE__ */ React11__namespace.createElement(Form, { ...form }, /* @__PURE__ */ React11__namespace.createElement("form", { onSubmit: form.handleSubmit(onSubmit) }, /* @__PURE__ */ React11__namespace.createElement("div", { className: "sb-space-y-4 sb-p-4" }, (component.inputs || []).map((input) => /* @__PURE__ */ React11__namespace.createElement(
589
- FormField,
591
+ RenderFormField,
590
592
  {
591
593
  key: input.name,
592
- control: form.control,
593
- name: input.name,
594
- render: ({ field }) => /* @__PURE__ */ React11__namespace.createElement(RenderInput, { type: input.type, input, field })
594
+ type: input.type,
595
+ input,
596
+ form
595
597
  }
596
598
  )))));
597
599
  };
600
+ var RenderFormField = (props) => {
601
+ const { type, input, form } = props;
602
+ const fieldArray = reactHookForm.useFieldArray({
603
+ control: form.control,
604
+ name: input.name
605
+ });
606
+ if (input.multiple) {
607
+ return /* @__PURE__ */ React11__namespace.createElement("fieldset", { className: "sb-space-y-2" }, /* @__PURE__ */ React11__namespace.createElement(FormLabel, null, input.friendlyName || input.name), /* @__PURE__ */ React11__namespace.createElement("div", { className: "sb-space-y-4" }, fieldArray.fields.map(
608
+ (field, i) => type !== "grouped" ? /* @__PURE__ */ React11__namespace.createElement(
609
+ FormField,
610
+ {
611
+ key: field.id,
612
+ control: form.control,
613
+ name: `${input.name}.${i}`,
614
+ render: ({ field: field2 }) => /* @__PURE__ */ React11__namespace.createElement("div", { className: "sb-flex sb-items-center sb-gap-3" }, /* @__PURE__ */ React11__namespace.createElement(RenderInput, { field: field2, type: input.type }), /* @__PURE__ */ React11__namespace.createElement("button", { type: "button", onClick: () => fieldArray.remove(i) }, /* @__PURE__ */ React11__namespace.createElement(lucideReact.XIcon, { className: "sb-h-4 sb-w-4" })))
615
+ }
616
+ ) : /* @__PURE__ */ React11__namespace.createElement("div", { className: "sb-flex sb-items-center sb-relative" }, /* @__PURE__ */ React11__namespace.createElement(
617
+ RenderFormField,
618
+ {
619
+ key: field.id,
620
+ form,
621
+ type,
622
+ input: {
623
+ ...input,
624
+ name: `${input.name}.${i}`,
625
+ multiple: false,
626
+ friendlyName: ""
627
+ }
628
+ }
629
+ ), /* @__PURE__ */ React11__namespace.createElement(
630
+ "button",
631
+ {
632
+ type: "button",
633
+ onClick: () => fieldArray.remove(i),
634
+ className: "sb-absolute sb-top-2 sb-right-2 sb-text-foreground/70 hover:sb-text-foreground"
635
+ },
636
+ /* @__PURE__ */ React11__namespace.createElement(lucideReact.XIcon, { className: "sb-h-4 sb-w-4" })
637
+ ))
638
+ ), /* @__PURE__ */ React11__namespace.createElement(
639
+ chunkGXNKJBJA_js.Button,
640
+ {
641
+ type: "button",
642
+ variant: "outline",
643
+ size: "sm",
644
+ className: chunkB4NNVFW6_js.cn(
645
+ "sb-w-[89%] sb-border-2 sb-border-dashed sb-text-muted-foreground",
646
+ type === "grouped" && "sb-w-full"
647
+ ),
648
+ onClick: () => fieldArray.append(void 0)
649
+ },
650
+ /* @__PURE__ */ React11__namespace.createElement(lucideReact.PlusCircleIcon, { className: "sb-h-4 sb-w-4" })
651
+ )));
652
+ }
653
+ switch (type) {
654
+ case "string":
655
+ case "number":
656
+ case "longText":
657
+ case "richText":
658
+ case "color":
659
+ case "date":
660
+ case "file":
661
+ return /* @__PURE__ */ React11__namespace.createElement(
662
+ FormField,
663
+ {
664
+ key: input.name,
665
+ control: form.control,
666
+ name: input.name,
667
+ render: ({ field }) => /* @__PURE__ */ React11__namespace.createElement(FormItem, null, /* @__PURE__ */ React11__namespace.createElement(FormLabel, null, input.friendlyName || input.name), /* @__PURE__ */ React11__namespace.createElement(FormControl, null, /* @__PURE__ */ React11__namespace.createElement(RenderInput, { type, field })), input.helperText && /* @__PURE__ */ React11__namespace.createElement(FormDescription, null, input.helperText), /* @__PURE__ */ React11__namespace.createElement(FormMessage, null))
668
+ }
669
+ );
670
+ case "boolean":
671
+ return /* @__PURE__ */ React11__namespace.createElement(
672
+ FormField,
673
+ {
674
+ key: input.name,
675
+ control: form.control,
676
+ name: input.name,
677
+ render: ({ field }) => /* @__PURE__ */ React11__namespace.createElement(FormItem, { className: "sb-flex sb-flex-row sb-items-center sb-justify-between sb-space-y-0" }, /* @__PURE__ */ React11__namespace.createElement(FormLabel, null, input.friendlyName || input.name), /* @__PURE__ */ React11__namespace.createElement(FormControl, null, /* @__PURE__ */ React11__namespace.createElement(RenderInput, { type, field })), input.helperText && /* @__PURE__ */ React11__namespace.createElement(FormDescription, null, input.helperText), /* @__PURE__ */ React11__namespace.createElement(FormMessage, null))
678
+ }
679
+ );
680
+ case "grouped":
681
+ return /* @__PURE__ */ React11__namespace.createElement("div", { className: "sb-space-y-2 sb-w-full" }, input.friendlyName !== "" && /* @__PURE__ */ React11__namespace.createElement(FormLabel, null, input.friendlyName || input.name), /* @__PURE__ */ React11__namespace.createElement("div", { className: "sb-space-y-2 sb-p-3 sb-w-full sb-border sb-rounded-lg" }, input.inputs.map((sub) => /* @__PURE__ */ React11__namespace.createElement(
682
+ RenderFormField,
683
+ {
684
+ key: `${input.name}.${sub.name}`,
685
+ type: sub.type,
686
+ input: {
687
+ ...sub,
688
+ name: `${input.name}.${sub.name}`
689
+ },
690
+ form
691
+ }
692
+ ))));
693
+ default:
694
+ throw new Error(
695
+ `[simple-builder]: Input type "${props.type}" not supported in render form field.`
696
+ );
697
+ }
698
+ };
598
699
  var RenderInput = (props) => {
599
- const { type, input, field } = props;
700
+ const { type, field } = props;
600
701
  switch (type) {
601
702
  case "string":
602
- return /* @__PURE__ */ React11__namespace.createElement(FormItem, null, /* @__PURE__ */ React11__namespace.createElement(FormLabel, null, input.friendlyName || input.name), /* @__PURE__ */ React11__namespace.createElement(FormControl, null, /* @__PURE__ */ React11__namespace.createElement(Input, { ...field })), input.helperText && /* @__PURE__ */ React11__namespace.createElement(FormDescription, null, input.helperText), /* @__PURE__ */ React11__namespace.createElement(FormMessage, null));
703
+ return /* @__PURE__ */ React11__namespace.createElement(Input, { ...field });
603
704
  case "longText":
604
- return /* @__PURE__ */ React11__namespace.createElement(FormItem, null, /* @__PURE__ */ React11__namespace.createElement(FormLabel, null, input.friendlyName || input.name), /* @__PURE__ */ React11__namespace.createElement(FormControl, null, /* @__PURE__ */ React11__namespace.createElement(Textarea, { ...field })), input.helperText && /* @__PURE__ */ React11__namespace.createElement(FormDescription, null, input.helperText), /* @__PURE__ */ React11__namespace.createElement(FormMessage, null));
605
705
  case "richText":
606
- return /* @__PURE__ */ React11__namespace.createElement(FormItem, null, /* @__PURE__ */ React11__namespace.createElement(FormLabel, null, input.friendlyName || input.name), /* @__PURE__ */ React11__namespace.createElement(FormControl, null, /* @__PURE__ */ React11__namespace.createElement(Textarea, { ...field })), input.helperText && /* @__PURE__ */ React11__namespace.createElement(FormDescription, null, input.helperText), /* @__PURE__ */ React11__namespace.createElement(FormMessage, null));
706
+ return /* @__PURE__ */ React11__namespace.createElement(Textarea, { ...field });
607
707
  case "number":
608
- return /* @__PURE__ */ React11__namespace.createElement(FormItem, null, /* @__PURE__ */ React11__namespace.createElement(FormLabel, null, input.friendlyName || input.name), /* @__PURE__ */ React11__namespace.createElement(FormControl, null, /* @__PURE__ */ React11__namespace.createElement(Input, { type: "number", ...field })), input.helperText && /* @__PURE__ */ React11__namespace.createElement(FormDescription, null, input.helperText), /* @__PURE__ */ React11__namespace.createElement(FormMessage, null));
708
+ return /* @__PURE__ */ React11__namespace.createElement(Input, { type: "number", ...field });
609
709
  case "color":
610
- return /* @__PURE__ */ React11__namespace.createElement(FormItem, null, /* @__PURE__ */ React11__namespace.createElement(FormLabel, null, input.friendlyName || input.name), /* @__PURE__ */ React11__namespace.createElement(FormControl, null, /* @__PURE__ */ React11__namespace.createElement(ColorPicker, { color: field.value, onColorChange: field.onChange })), input.helperText && /* @__PURE__ */ React11__namespace.createElement(FormDescription, null, input.helperText), /* @__PURE__ */ React11__namespace.createElement(FormMessage, null));
710
+ return /* @__PURE__ */ React11__namespace.createElement(ColorPicker, { color: field.value, onColorChange: field.onChange });
611
711
  case "date":
612
- return /* @__PURE__ */ React11__namespace.createElement(FormItem, null, /* @__PURE__ */ React11__namespace.createElement(FormLabel, null, input.friendlyName || input.name), /* @__PURE__ */ React11__namespace.createElement(FormControl, null, /* @__PURE__ */ React11__namespace.createElement(Popover, null, /* @__PURE__ */ React11__namespace.createElement(PopoverTrigger, { asChild: true }, /* @__PURE__ */ React11__namespace.createElement(
613
- chunkYGI2WZVP_js.Button,
712
+ return /* @__PURE__ */ React11__namespace.createElement(Popover, null, /* @__PURE__ */ React11__namespace.createElement(PopoverTrigger, { asChild: true }, /* @__PURE__ */ React11__namespace.createElement(
713
+ chunkGXNKJBJA_js.Button,
614
714
  {
615
715
  variant: "outline",
616
716
  size: "sm",
617
- className: chunkECJUPPTG_js.cn(
717
+ className: chunkB4NNVFW6_js.cn(
618
718
  "sb-w-full sb-flex sb-justify-start sb-text-left sb-font-normal",
619
719
  !field.value && "sb-text-muted-foreground"
620
720
  )
@@ -629,11 +729,11 @@ var RenderInput = (props) => {
629
729
  onSelect: field.onChange,
630
730
  initialFocus: true
631
731
  }
632
- )))), input.helperText && /* @__PURE__ */ React11__namespace.createElement(FormDescription, null, input.helperText), /* @__PURE__ */ React11__namespace.createElement(FormMessage, null));
732
+ )));
633
733
  case "boolean":
634
- return /* @__PURE__ */ React11__namespace.createElement(FormItem, { className: "sb-flex sb-flex-row sb-items-center sb-justify-between sb-space-y-0" }, /* @__PURE__ */ React11__namespace.createElement(FormLabel, null, input.friendlyName || input.name), /* @__PURE__ */ React11__namespace.createElement(FormControl, null, /* @__PURE__ */ React11__namespace.createElement(Switch, { checked: field.value, onCheckedChange: field.onChange })), input.helperText && /* @__PURE__ */ React11__namespace.createElement(FormDescription, null, input.helperText), /* @__PURE__ */ React11__namespace.createElement(FormMessage, null));
734
+ return /* @__PURE__ */ React11__namespace.createElement(Switch, { checked: field.value, onCheckedChange: field.onChange });
635
735
  case "file":
636
- return /* @__PURE__ */ React11__namespace.createElement(FormItem, null, /* @__PURE__ */ React11__namespace.createElement(FormLabel, null, input.friendlyName || input.name), /* @__PURE__ */ React11__namespace.createElement(FormControl, null, /* @__PURE__ */ React11__namespace.createElement(
736
+ return /* @__PURE__ */ React11__namespace.createElement(
637
737
  MediaInput,
638
738
  {
639
739
  className: "sb-grid sb-grid-cols-2 sb-gap-1",
@@ -645,15 +745,15 @@ var RenderInput = (props) => {
645
745
  "media-input: Error: " + e?.description
646
746
  )
647
747
  }
648
- )), input.helperText && /* @__PURE__ */ React11__namespace.createElement(FormDescription, null, input.helperText), /* @__PURE__ */ React11__namespace.createElement(FormMessage, null));
748
+ );
649
749
  default:
650
750
  throw new Error(
651
- `[simple-builder]: Input type "${props.type}" not supported`
751
+ `[simple-builder]: Input type "${props.type}" not supported in render input.`
652
752
  );
653
753
  }
654
754
  };
655
755
  var Tabs = TabsPrimitive__namespace.Root;
656
- var tabsListVariants = chunkECJUPPTG_js.tv({
756
+ var tabsListVariants = chunkB4NNVFW6_js.tv({
657
757
  variants: {
658
758
  variant: {
659
759
  contained: "sb-inline-flex sb-h-10 sb-items-center sb-justify-center sb-rounded-md sb-bg-muted sb-p-1 sb-text-muted-foreground",
@@ -673,7 +773,7 @@ var TabsList = React11__namespace.forwardRef(({ variant, className, ...props },
673
773
  }
674
774
  ));
675
775
  TabsList.displayName = TabsPrimitive__namespace.List.displayName;
676
- var tabsTriggerVariants = chunkECJUPPTG_js.tv({
776
+ var tabsTriggerVariants = chunkB4NNVFW6_js.tv({
677
777
  variants: {
678
778
  variant: {
679
779
  contained: "sb-inline-flex sb-items-center sb-justify-center sb-whitespace-nowrap sb-rounded-sm sb-px-3 sb-py-1.5 sb-text-sm sb-font-medium sb-ring-offset-background sb-transition-all focus-visible:sb-outline-none focus-visible:sb-ring-2 focus-visible:sb-ring-ring focus-visible:sb-ring-offset-2 disabled:sb-pointer-events-none disabled:sb-opacity-50 data-[state=active]:sb-bg-background data-[state=active]:sb-text-foreground data-[state=active]:sb-shadow-sm",
@@ -697,7 +797,7 @@ var TabsContent = React11__namespace.forwardRef(({ className, ...props }, ref) =
697
797
  TabsPrimitive__namespace.Content,
698
798
  {
699
799
  ref,
700
- className: chunkECJUPPTG_js.cn(
800
+ className: chunkB4NNVFW6_js.cn(
701
801
  "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",
702
802
  className
703
803
  ),
@@ -736,11 +836,11 @@ var BackgroundPicker = (props) => {
736
836
  return "solid";
737
837
  }, [background]);
738
838
  return /* @__PURE__ */ React11__namespace.createElement(Popover, null, /* @__PURE__ */ React11__namespace.createElement(PopoverTrigger, { asChild: true }, /* @__PURE__ */ React11__namespace.createElement(
739
- chunkYGI2WZVP_js.Button,
839
+ chunkGXNKJBJA_js.Button,
740
840
  {
741
841
  variant: "outline",
742
842
  size: "sm",
743
- className: chunkECJUPPTG_js.cn(
843
+ className: chunkB4NNVFW6_js.cn(
744
844
  "sb-justify-start sb-text-left sb-font-normal sb-normal-case sb-w-full",
745
845
  !background && "sb-text-muted-foreground",
746
846
  className
@@ -809,7 +909,7 @@ var BackgroundPicker = (props) => {
809
909
  }
810
910
  )))))));
811
911
  };
812
- var toggleVariants = chunkECJUPPTG_js.tv({
912
+ var toggleVariants = chunkB4NNVFW6_js.tv({
813
913
  base: "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",
814
914
  variants: {
815
915
  variant: {
@@ -964,7 +1064,7 @@ var designSchema = zod.z.object({
964
1064
  });
965
1065
  var ItemDesignForm = (props) => {
966
1066
  const { item } = props;
967
- const component = chunkECJUPPTG_js.builder.getComponent(item.component);
1067
+ const component = chunkB4NNVFW6_js.builder.getComponent(item.component);
968
1068
  if (!component) {
969
1069
  throw new Error(
970
1070
  `[simple-builder]: Component "${item.component}" not found`
@@ -1005,7 +1105,7 @@ var ItemDesignForm = (props) => {
1005
1105
  mobile: getDefaultDeviceValues("mobile")
1006
1106
  }
1007
1107
  });
1008
- const { patchItem } = chunkYGI2WZVP_js.useBuilder();
1108
+ const { patchItem } = chunkGXNKJBJA_js.useBuilder();
1009
1109
  const onSubmit = (values) => {
1010
1110
  const { container, desktop, mobile } = values;
1011
1111
  const dirtyFields = form.formState.dirtyFields;
@@ -1023,6 +1123,11 @@ var ItemDesignForm = (props) => {
1023
1123
  if (value === desktopValue || isDirty) {
1024
1124
  return acc;
1025
1125
  }
1126
+ if (["padding", "margin"].includes(key)) {
1127
+ if (value === "0px" && desktopValue === "0px") {
1128
+ return acc;
1129
+ }
1130
+ }
1026
1131
  return {
1027
1132
  ...acc,
1028
1133
  ...value && { [key]: value }
@@ -1033,8 +1138,8 @@ var ItemDesignForm = (props) => {
1033
1138
  patchItem(item.id, {
1034
1139
  styles: {
1035
1140
  ...container === false && { container },
1036
- desktop: desktopPatch,
1037
- mobile: mobilePatch
1141
+ ...Object.keys(desktopPatch).length && { desktop: desktopPatch },
1142
+ ...Object.keys(mobilePatch).length && { mobile: mobilePatch }
1038
1143
  }
1039
1144
  });
1040
1145
  };
@@ -1121,13 +1226,41 @@ var ItemDesignForm = (props) => {
1121
1226
  }
1122
1227
  )))));
1123
1228
  };
1229
+ var ScrollArea = React11__namespace.forwardRef(({ className, children, ...props }, ref) => /* @__PURE__ */ React11__namespace.createElement(
1230
+ ScrollAreaPrimitive__namespace.Root,
1231
+ {
1232
+ ref,
1233
+ className: chunkB4NNVFW6_js.cn("sb-relative sb-overflow-hidden", className),
1234
+ ...props
1235
+ },
1236
+ /* @__PURE__ */ React11__namespace.createElement(ScrollAreaPrimitive__namespace.Viewport, { className: "sb-h-full sb-max-h-[80vh] sb-w-full sb-rounded-[inherit]" }, children),
1237
+ /* @__PURE__ */ React11__namespace.createElement(ScrollBar, null),
1238
+ /* @__PURE__ */ React11__namespace.createElement(ScrollAreaPrimitive__namespace.Corner, null)
1239
+ ));
1240
+ ScrollArea.displayName = ScrollAreaPrimitive__namespace.Root.displayName;
1241
+ var ScrollBar = React11__namespace.forwardRef(({ className, orientation = "vertical", ...props }, ref) => /* @__PURE__ */ React11__namespace.createElement(
1242
+ ScrollAreaPrimitive__namespace.ScrollAreaScrollbar,
1243
+ {
1244
+ ref,
1245
+ orientation,
1246
+ className: chunkB4NNVFW6_js.cn(
1247
+ "sb-flex sb-touch-none sb-select-none sb-transition-colors",
1248
+ orientation === "vertical" && "sb-h-full sb-w-2.5 sb-border-l sb-border-l-transparent sb-p-[1px]",
1249
+ orientation === "horizontal" && "sb-h-2.5 sb-flex-col sb-border-t sb-border-t-transparent sb-p-[1px]",
1250
+ className
1251
+ ),
1252
+ ...props
1253
+ },
1254
+ /* @__PURE__ */ React11__namespace.createElement(ScrollAreaPrimitive__namespace.ScrollAreaThumb, { className: "sb-relative sb-flex-1 sb-rounded-full sb-bg-border" })
1255
+ ));
1256
+ ScrollBar.displayName = ScrollAreaPrimitive__namespace.ScrollAreaScrollbar.displayName;
1124
1257
 
1125
1258
  // src/components/container-item-toolbar.tsx
1126
1259
  var ContainerItemToolbar = (props) => {
1127
1260
  const { contentId, canBringUp = false, canBringDown = false } = props;
1128
- const { bringUp, bringDown } = chunkYGI2WZVP_js.useBuilder();
1261
+ const { bringUp, bringDown } = chunkGXNKJBJA_js.useBuilder();
1129
1262
  return /* @__PURE__ */ React11__namespace.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__ */ React11__namespace.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__ */ React11__namespace.createElement(EditButton, { id: contentId }), /* @__PURE__ */ React11__namespace.createElement(
1130
- chunkYGI2WZVP_js.Button,
1263
+ chunkGXNKJBJA_js.Button,
1131
1264
  {
1132
1265
  variant: "ghost",
1133
1266
  className: "sb-w-8 sb-h-8 sb-p-0",
@@ -1136,7 +1269,7 @@ var ContainerItemToolbar = (props) => {
1136
1269
  },
1137
1270
  /* @__PURE__ */ React11__namespace.createElement(lucideReact.ArrowUp, { className: "sb-h-5 sb-w-5" })
1138
1271
  ), /* @__PURE__ */ React11__namespace.createElement(
1139
- chunkYGI2WZVP_js.Button,
1272
+ chunkGXNKJBJA_js.Button,
1140
1273
  {
1141
1274
  variant: "ghost",
1142
1275
  className: "sb-w-8 sb-h-8 sb-p-0",
@@ -1147,14 +1280,14 @@ var ContainerItemToolbar = (props) => {
1147
1280
  ), /* @__PURE__ */ React11__namespace.createElement(DeleteButton, { contentId })));
1148
1281
  };
1149
1282
  var EditButton = ({ id }) => {
1150
- return /* @__PURE__ */ React11__namespace.createElement(Popover, null, /* @__PURE__ */ React11__namespace.createElement(PopoverTrigger, { asChild: true }, /* @__PURE__ */ React11__namespace.createElement(chunkYGI2WZVP_js.Button, { variant: "ghost", className: "sb-w-8 sb-h-8 sb-p-0" }, /* @__PURE__ */ React11__namespace.createElement(lucideReact.Edit2Icon, { className: "sb-h-5 sb-w-5" }))), /* @__PURE__ */ React11__namespace.createElement(
1283
+ return /* @__PURE__ */ React11__namespace.createElement(Popover, { modal: true }, /* @__PURE__ */ React11__namespace.createElement(PopoverTrigger, { asChild: true }, /* @__PURE__ */ React11__namespace.createElement(chunkGXNKJBJA_js.Button, { variant: "ghost", className: "sb-w-8 sb-h-8 sb-p-0" }, /* @__PURE__ */ React11__namespace.createElement(lucideReact.Edit2Icon, { className: "sb-h-5 sb-w-5" }))), /* @__PURE__ */ React11__namespace.createElement(
1151
1284
  PopoverContent,
1152
1285
  {
1153
1286
  side: "left",
1154
1287
  align: "start",
1155
1288
  sideOffset: 16,
1156
1289
  alignOffset: -8,
1157
- className: "sb-p-0",
1290
+ className: "sb-p-0 sb-relative",
1158
1291
  collisionPadding: 16
1159
1292
  },
1160
1293
  /* @__PURE__ */ React11__namespace.createElement(EditPopoverInner, { id })
@@ -1162,19 +1295,19 @@ var EditButton = ({ id }) => {
1162
1295
  };
1163
1296
  var EditPopoverInner = (props) => {
1164
1297
  const { id } = props;
1165
- const { getItem } = chunkYGI2WZVP_js.useBuilder();
1298
+ const { getItem } = chunkGXNKJBJA_js.useBuilder();
1166
1299
  const item = getItem(id);
1167
1300
  if (!item) {
1168
1301
  throw new Error(
1169
1302
  `[simple-builder]: Item with id ${id} not found in container item form component`
1170
1303
  );
1171
1304
  }
1172
- return /* @__PURE__ */ React11__namespace.createElement(Tabs, null, /* @__PURE__ */ React11__namespace.createElement(TabsList, { variant: "text", defaultValue: "content" }, /* @__PURE__ */ React11__namespace.createElement(TabsTrigger, { variant: "text", value: "content" }, "Inhoud"), /* @__PURE__ */ React11__namespace.createElement(TabsTrigger, { variant: "text", value: "design" }, "Design")), /* @__PURE__ */ React11__namespace.createElement(TabsContent, { value: "content" }, /* @__PURE__ */ React11__namespace.createElement(ContainerItemForm, { item })), /* @__PURE__ */ React11__namespace.createElement(TabsContent, { value: "design" }, /* @__PURE__ */ React11__namespace.createElement(ItemDesignForm, { item })));
1305
+ return /* @__PURE__ */ React11__namespace.createElement(Tabs, null, /* @__PURE__ */ React11__namespace.createElement(TabsList, { variant: "text", defaultValue: "content" }, /* @__PURE__ */ React11__namespace.createElement(TabsTrigger, { variant: "text", value: "content" }, "Inhoud"), /* @__PURE__ */ React11__namespace.createElement(TabsTrigger, { variant: "text", value: "design" }, "Design")), /* @__PURE__ */ React11__namespace.createElement(TabsContent, { value: "content" }, /* @__PURE__ */ React11__namespace.createElement(ScrollArea, null, /* @__PURE__ */ React11__namespace.createElement(ContainerItemForm, { item }))), /* @__PURE__ */ React11__namespace.createElement(TabsContent, { value: "design" }, /* @__PURE__ */ React11__namespace.createElement(ItemDesignForm, { item })));
1173
1306
  };
1174
1307
  var DeleteButton = ({ contentId }) => {
1175
- const { deleteContent } = chunkYGI2WZVP_js.useBuilder();
1308
+ const { deleteContent } = chunkGXNKJBJA_js.useBuilder();
1176
1309
  return /* @__PURE__ */ React11__namespace.createElement(AlertDialog, null, /* @__PURE__ */ React11__namespace.createElement(AlertDialogTrigger, { asChild: true }, /* @__PURE__ */ React11__namespace.createElement(
1177
- chunkYGI2WZVP_js.Button,
1310
+ chunkGXNKJBJA_js.Button,
1178
1311
  {
1179
1312
  variant: "ghost",
1180
1313
  className: "sb-w-8 sb-h-8 sb-p-0 sb-text-destructive"
@@ -1183,7 +1316,7 @@ var DeleteButton = ({ contentId }) => {
1183
1316
  )), /* @__PURE__ */ React11__namespace.createElement(AlertDialogContent, null, /* @__PURE__ */ React11__namespace.createElement(AlertDialogDescription, null, "Weet je zeker dat je dit blok wilt verwijderen?"), /* @__PURE__ */ React11__namespace.createElement(AlertDialogFooter, null, /* @__PURE__ */ React11__namespace.createElement(AlertDialogCancel, null, "Annuleren"), /* @__PURE__ */ React11__namespace.createElement(
1184
1317
  AlertDialogAction,
1185
1318
  {
1186
- className: chunkYGI2WZVP_js.buttonVariants({ variant: "destructive" }),
1319
+ className: chunkGXNKJBJA_js.buttonVariants({ variant: "destructive" }),
1187
1320
  onClick: () => deleteContent(contentId)
1188
1321
  },
1189
1322
  "Verwijderen"
@@ -1199,7 +1332,7 @@ var BuildContainerInner = (props) => {
1199
1332
  "[simple-builder]: Multiple content blocks detected when using property multiple false."
1200
1333
  );
1201
1334
  }
1202
- return /* @__PURE__ */ React11__namespace.createElement("div", null, items.length <= 0 ? /* @__PURE__ */ React11__namespace.createElement(AddContentPlaceholder, { parent: id, container: name, index: 0 }) : multiple && /* @__PURE__ */ React11__namespace.createElement(AddContentDividerButton, { parent: id, container: name, index: 0 }), items.map((item, i) => /* @__PURE__ */ React11__namespace.createElement(React11__namespace.Fragment, { key: item.id }, /* @__PURE__ */ React11__namespace.createElement("div", { className: "sb-relative sb-container-item" }, /* @__PURE__ */ React11__namespace.createElement(chunkECJUPPTG_js.DesignWrapper, { styles: item.styles }, chunkECJUPPTG_js.builder.bindComponent(item, true)), /* @__PURE__ */ React11__namespace.createElement(
1335
+ return /* @__PURE__ */ React11__namespace.createElement("div", null, items.length <= 0 ? /* @__PURE__ */ React11__namespace.createElement(AddContentPlaceholder, { parent: id, container: name, index: 0 }) : multiple && /* @__PURE__ */ React11__namespace.createElement(AddContentDividerButton, { parent: id, container: name, index: 0 }), items.map((item, i) => /* @__PURE__ */ React11__namespace.createElement(React11__namespace.Fragment, { key: item.id }, /* @__PURE__ */ React11__namespace.createElement("div", { className: "sb-relative sb-container-item" }, /* @__PURE__ */ React11__namespace.createElement(chunkB4NNVFW6_js.DesignWrapper, { styles: item.styles }, chunkB4NNVFW6_js.builder.bindComponent(item, true)), /* @__PURE__ */ React11__namespace.createElement(
1203
1336
  ContainerItemToolbar,
1204
1337
  {
1205
1338
  contentId: item.id,
@@ -1217,12 +1350,12 @@ var BuildContainerInner = (props) => {
1217
1350
  };
1218
1351
  var build_container_client_default = BuildContainerInner;
1219
1352
  var AddContentButton = (props) => {
1220
- const components = chunkECJUPPTG_js.builder.getComponents();
1221
- const { addContent } = chunkYGI2WZVP_js.useBuilder();
1353
+ const components = chunkB4NNVFW6_js.builder.getComponents();
1354
+ const { addContent } = chunkGXNKJBJA_js.useBuilder();
1222
1355
  return /* @__PURE__ */ React11__namespace.createElement(Popover, null, /* @__PURE__ */ React11__namespace.createElement(PopoverTrigger, { asChild: true }, props.children), /* @__PURE__ */ React11__namespace.createElement(PopoverContent, { className: "sb-p-1" }, /* @__PURE__ */ React11__namespace.createElement("div", { className: "sb-grid sb-grid-cols-2 sb-gap-2" }, components.map((component) => {
1223
1356
  const Icon = component.icon ?? lucideReact.ImageIcon;
1224
1357
  return /* @__PURE__ */ React11__namespace.createElement(PopoverClose, { key: component.name, asChild: true }, /* @__PURE__ */ React11__namespace.createElement(
1225
- chunkYGI2WZVP_js.Button,
1358
+ chunkGXNKJBJA_js.Button,
1226
1359
  {
1227
1360
  variant: "ghost",
1228
1361
  className: "sb-justify-start",
@@ -1241,11 +1374,11 @@ var AddContentButton = (props) => {
1241
1374
  }))));
1242
1375
  };
1243
1376
  var AddContentPlaceholder = (props) => {
1244
- return /* @__PURE__ */ React11__namespace.createElement(AddContentButton, { ...props }, /* @__PURE__ */ React11__namespace.createElement("div", { className: "sb-flex sb-justify-center sb-bg-primary/50 p-4" }, /* @__PURE__ */ React11__namespace.createElement(chunkYGI2WZVP_js.Button, { size: "sm" }, /* @__PURE__ */ React11__namespace.createElement(lucideReact.PlusIcon, { className: "sb-mr-2 sb-h-4 sb-w-4" }), "Blok Toevoegen")));
1377
+ return /* @__PURE__ */ React11__namespace.createElement(AddContentButton, { ...props }, /* @__PURE__ */ React11__namespace.createElement("div", { className: "sb-flex sb-justify-center sb-bg-primary/50 p-4" }, /* @__PURE__ */ React11__namespace.createElement(chunkGXNKJBJA_js.Button, { size: "sm" }, /* @__PURE__ */ React11__namespace.createElement(lucideReact.PlusIcon, { className: "sb-mr-2 sb-h-4 sb-w-4" }), "Blok Toevoegen")));
1245
1378
  };
1246
1379
  var AddContentDividerButton = (props) => {
1247
1380
  return /* @__PURE__ */ React11__namespace.createElement(AddContentButton, { ...props }, /* @__PURE__ */ React11__namespace.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__ */ React11__namespace.createElement(
1248
- chunkYGI2WZVP_js.Button,
1381
+ chunkGXNKJBJA_js.Button,
1249
1382
  {
1250
1383
  size: "sm",
1251
1384
  className: "sb-absolute sb-left-1/2 sb-top-1/2 sb--translate-y-1/2 sb--translate-x-1/2 sb-shadow"