@mission-studio/puck 1.0.23 → 1.0.24

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,695 @@
1
+ import {
2
+ dotsContainerStyle,
3
+ getArrowStyle,
4
+ getBaseStyle,
5
+ getCaptionStyle,
6
+ getCardStyle,
7
+ getContainerStyle,
8
+ getContainerStyle2,
9
+ getContainerStyle3,
10
+ getDotStyle,
11
+ getEmptyState,
12
+ getHeadingStyle,
13
+ getHrStyle,
14
+ getImageStyle,
15
+ getParagraphStyle,
16
+ getSectionStyle,
17
+ getSlideContainerStyle,
18
+ getVariantStyles,
19
+ getVisibilityClasses,
20
+ getWrapperStyle,
21
+ getWrapperStyle2,
22
+ getWrapperStyle3,
23
+ getWrapperStyle4,
24
+ icons,
25
+ imageStyle,
26
+ isEntryBoundValue,
27
+ isEntryBoundValue2,
28
+ isThemeableValue,
29
+ isThemeableValue2,
30
+ isThemeableValue3,
31
+ isThemeableValue4,
32
+ isThemeableValue5,
33
+ isThemeableValue6,
34
+ isThemeableValue7,
35
+ resolveBackgroundColor,
36
+ sizeMap,
37
+ sizeMap2,
38
+ slideStyle
39
+ } from "./chunk-YIPEC4L4.mjs";
40
+ import {
41
+ getShadowCSS,
42
+ useEntries,
43
+ useTheme
44
+ } from "./chunk-PJXZC564.mjs";
45
+ import {
46
+ useGtmEvent,
47
+ useUtmParams
48
+ } from "./chunk-QSWQDR6M.mjs";
49
+ import {
50
+ cn,
51
+ hexToRgba
52
+ } from "./chunk-C6V3YUPF.mjs";
53
+
54
+ // components/page/next/Heading.tsx
55
+ import { jsx } from "react/jsx-runtime";
56
+ function isThemeableValue8(value) {
57
+ return typeof value === "object" && value !== null && "useTheme" in value;
58
+ }
59
+ function isEntryBoundValue3(value) {
60
+ return typeof value === "object" && value !== null && "useEntry" in value;
61
+ }
62
+ function Heading({
63
+ text,
64
+ level = "h2",
65
+ size = "2xl",
66
+ weight = "bold",
67
+ color,
68
+ align = "left",
69
+ letterSpacing = "normal",
70
+ lineHeight = "tight",
71
+ id
72
+ }) {
73
+ const { resolveColor } = useTheme();
74
+ const { getEntryValue } = useEntries();
75
+ const resolvedText = (() => {
76
+ if (!text) return "";
77
+ if (typeof text === "string") return text;
78
+ if (isEntryBoundValue3(text)) {
79
+ if (text.useEntry) {
80
+ return String(getEntryValue(text.entryName, text.fieldKey) ?? "");
81
+ }
82
+ return text.value;
83
+ }
84
+ return "";
85
+ })();
86
+ const resolvedColor = (() => {
87
+ if (!color)
88
+ return hexToRgba(
89
+ resolveColor("foreground").color,
90
+ resolveColor("foreground").opacity
91
+ );
92
+ if (typeof color === "string") return color;
93
+ if (isThemeableValue8(color)) {
94
+ return color.useTheme ? hexToRgba(
95
+ resolveColor(color.themeKey).color,
96
+ resolveColor(color.themeKey).opacity
97
+ ) : hexToRgba(color.value.color, color.value.opacity);
98
+ }
99
+ if ("color" in color) return hexToRgba(color.color, color.opacity);
100
+ return hexToRgba(
101
+ resolveColor("foreground").color,
102
+ resolveColor("foreground").opacity
103
+ );
104
+ })();
105
+ const Tag = level;
106
+ const style = getHeadingStyle({
107
+ size,
108
+ weight,
109
+ color: resolvedColor,
110
+ align,
111
+ letterSpacing,
112
+ lineHeight
113
+ });
114
+ if (!resolvedText) return null;
115
+ return /* @__PURE__ */ jsx(Tag, { id, style, children: resolvedText });
116
+ }
117
+
118
+ // components/page/next/Paragraph.tsx
119
+ import { jsx as jsx2 } from "react/jsx-runtime";
120
+ function isThemeableValue9(value) {
121
+ return typeof value === "object" && value !== null && "useTheme" in value;
122
+ }
123
+ function isEntryBoundValue4(value) {
124
+ return typeof value === "object" && value !== null && "useEntry" in value;
125
+ }
126
+ function Paragraph({
127
+ text,
128
+ size = "base",
129
+ weight = "normal",
130
+ color,
131
+ align = "left",
132
+ lineHeight = "normal",
133
+ maxWidth,
134
+ id
135
+ }) {
136
+ const { resolveColor } = useTheme();
137
+ const { getEntryValue } = useEntries();
138
+ const resolvedText = (() => {
139
+ if (!text) return "";
140
+ if (typeof text === "string") return text;
141
+ if (isEntryBoundValue4(text)) {
142
+ if (text.useEntry) {
143
+ return String(getEntryValue(text.entryName, text.fieldKey) ?? "");
144
+ }
145
+ return text.value;
146
+ }
147
+ return "";
148
+ })();
149
+ const resolvedColor = (() => {
150
+ if (!color)
151
+ return hexToRgba(
152
+ resolveColor("foreground").color,
153
+ resolveColor("foreground").opacity
154
+ );
155
+ if (typeof color === "string") return color;
156
+ if (isThemeableValue9(color)) {
157
+ return color.useTheme ? hexToRgba(
158
+ resolveColor(color.themeKey).color,
159
+ resolveColor(color.themeKey).opacity
160
+ ) : hexToRgba(color.value.color, color.value.opacity);
161
+ }
162
+ if ("color" in color) return hexToRgba(color.color, color.opacity);
163
+ return hexToRgba(
164
+ resolveColor("foreground").color,
165
+ resolveColor("foreground").opacity
166
+ );
167
+ })();
168
+ const style = getParagraphStyle({
169
+ size,
170
+ weight,
171
+ color: resolvedColor,
172
+ align,
173
+ lineHeight,
174
+ maxWidth
175
+ });
176
+ if (!resolvedText) return null;
177
+ return /* @__PURE__ */ jsx2("p", { id, style, children: resolvedText });
178
+ }
179
+
180
+ // components/page/next/Button.tsx
181
+ import { jsx as jsx3 } from "react/jsx-runtime";
182
+ function Button({
183
+ text,
184
+ href,
185
+ target = "_self",
186
+ variant = "solid",
187
+ size = "md",
188
+ color,
189
+ textColor,
190
+ borderRadius = "md",
191
+ fullWidth = false,
192
+ align = "center",
193
+ id
194
+ }) {
195
+ const { resolveColor } = useTheme();
196
+ const { getEntryValue } = useEntries();
197
+ const utm = useUtmParams();
198
+ const sendEvent = useGtmEvent();
199
+ const resolvedText = (() => {
200
+ if (!text) return "Button";
201
+ if (typeof text === "string") return text;
202
+ if (isEntryBoundValue(text)) {
203
+ if (text.useEntry) {
204
+ return String(getEntryValue(text.entryName, text.fieldKey) ?? "Button");
205
+ }
206
+ return text.value;
207
+ }
208
+ return "Button";
209
+ })();
210
+ const handleClick = () => {
211
+ const sessionId = typeof window !== "undefined" ? sessionStorage.getItem("session_id") : null;
212
+ sendEvent("button_click", {
213
+ text: resolvedText,
214
+ href: href || void 0,
215
+ variant,
216
+ session_id: sessionId,
217
+ ...utm
218
+ });
219
+ };
220
+ const resolvedColor = (() => {
221
+ if (!color) return resolveColor("primary");
222
+ if (typeof color === "string") return { color, opacity: 100 };
223
+ if (isThemeableValue(color)) {
224
+ return color.useTheme ? resolveColor(color.themeKey) : color.value;
225
+ }
226
+ if ("color" in color) return color;
227
+ return resolveColor("primary");
228
+ })();
229
+ const resolvedTextColor = (() => {
230
+ if (!textColor) {
231
+ if (variant === "solid") return { color: "#FFFFFF", opacity: 100 };
232
+ return resolvedColor;
233
+ }
234
+ if (typeof textColor === "string")
235
+ return { color: textColor, opacity: 100 };
236
+ if (isThemeableValue(textColor)) {
237
+ return textColor.useTheme ? resolveColor(textColor.themeKey) : textColor.value;
238
+ }
239
+ if ("color" in textColor) return textColor;
240
+ return { color: "#FFFFFF", opacity: 100 };
241
+ })();
242
+ const bgColor = hexToRgba(resolvedColor.color, resolvedColor.opacity);
243
+ const fgColor = hexToRgba(resolvedTextColor.color, resolvedTextColor.opacity);
244
+ const baseStyle = getBaseStyle(size, borderRadius, fullWidth);
245
+ const variantStyle = getVariantStyles(variant, bgColor, fgColor);
246
+ const style = { ...baseStyle, ...variantStyle };
247
+ const wrapperStyle = getWrapperStyle(align);
248
+ if (href) {
249
+ return /* @__PURE__ */ jsx3("div", { style: wrapperStyle, children: /* @__PURE__ */ jsx3(
250
+ "a",
251
+ {
252
+ id,
253
+ href,
254
+ target,
255
+ style,
256
+ rel: target === "_blank" ? "noopener noreferrer" : void 0,
257
+ onClick: handleClick,
258
+ children: resolvedText
259
+ }
260
+ ) });
261
+ }
262
+ return /* @__PURE__ */ jsx3("div", { style: wrapperStyle, children: /* @__PURE__ */ jsx3("button", { id, type: "button", style, onClick: handleClick, children: resolvedText }) });
263
+ }
264
+
265
+ // components/page/next/Image.tsx
266
+ import { jsx as jsx4, jsxs } from "react/jsx-runtime";
267
+ function Image({
268
+ src,
269
+ alt = "",
270
+ width = "full",
271
+ aspectRatio = "auto",
272
+ objectFit = "cover",
273
+ borderRadius = "none",
274
+ shadow = "none",
275
+ align = "center",
276
+ caption,
277
+ captionColor,
278
+ id
279
+ }) {
280
+ const { resolveColor } = useTheme();
281
+ const { getEntryValue } = useEntries();
282
+ const resolvedSrc = (() => {
283
+ if (!src) return "";
284
+ if (typeof src === "string") return src;
285
+ if (isEntryBoundValue2(src)) {
286
+ if (src.useEntry) {
287
+ return String(getEntryValue(src.entryName, src.fieldKey) ?? "");
288
+ }
289
+ return src.value;
290
+ }
291
+ return "";
292
+ })();
293
+ const resolvedCaption = (() => {
294
+ if (!caption) return "";
295
+ if (typeof caption === "string") return caption;
296
+ if (isEntryBoundValue2(caption)) {
297
+ if (caption.useEntry) {
298
+ return String(getEntryValue(caption.entryName, caption.fieldKey) ?? "");
299
+ }
300
+ return caption.value;
301
+ }
302
+ return "";
303
+ })();
304
+ const resolvedCaptionColor = (() => {
305
+ if (!captionColor) return resolveColor("muted");
306
+ if (typeof captionColor === "string")
307
+ return { color: captionColor, opacity: 100 };
308
+ if (isThemeableValue2(captionColor)) {
309
+ return captionColor.useTheme ? resolveColor(captionColor.themeKey) : captionColor.value;
310
+ }
311
+ if ("color" in captionColor) return captionColor;
312
+ return resolveColor("muted");
313
+ })();
314
+ const wrapperStyle = getWrapperStyle2(align);
315
+ const imageStyle2 = getImageStyle(
316
+ width,
317
+ aspectRatio,
318
+ objectFit,
319
+ borderRadius,
320
+ shadow
321
+ );
322
+ const captionStyle = getCaptionStyle(
323
+ align,
324
+ width,
325
+ hexToRgba(resolvedCaptionColor.color, resolvedCaptionColor.opacity)
326
+ );
327
+ if (!resolvedSrc) {
328
+ return /* @__PURE__ */ jsx4("div", { style: wrapperStyle, children: /* @__PURE__ */ jsx4(
329
+ "div",
330
+ {
331
+ style: {
332
+ ...imageStyle2,
333
+ backgroundColor: "#e5e7eb",
334
+ display: "flex",
335
+ alignItems: "center",
336
+ justifyContent: "center",
337
+ minHeight: "200px",
338
+ color: "#9ca3af"
339
+ },
340
+ children: "No image"
341
+ }
342
+ ) });
343
+ }
344
+ return /* @__PURE__ */ jsxs("figure", { id, style: { ...wrapperStyle, margin: 0 }, children: [
345
+ /* @__PURE__ */ jsx4("img", { src: resolvedSrc, alt, style: imageStyle2, loading: "lazy" }),
346
+ resolvedCaption && /* @__PURE__ */ jsx4("figcaption", { style: captionStyle, children: resolvedCaption })
347
+ ] });
348
+ }
349
+
350
+ // components/page/next/ImageCarousel.tsx
351
+ import { useState } from "react";
352
+ import { Fragment, jsx as jsx5, jsxs as jsxs2 } from "react/jsx-runtime";
353
+ function ImageCarousel({
354
+ images = [],
355
+ aspectRatio = "16:9",
356
+ borderRadius = "none",
357
+ showDots = true,
358
+ showArrows = true,
359
+ arrowColor,
360
+ dotColor,
361
+ id
362
+ }) {
363
+ const [currentIndex, setCurrentIndex] = useState(0);
364
+ const { resolveColor } = useTheme();
365
+ const utm = useUtmParams();
366
+ const sendEvent = useGtmEvent();
367
+ const resolvedArrowColor = (() => {
368
+ if (!arrowColor) return { color: "#FFFFFF", opacity: 100 };
369
+ if (typeof arrowColor === "string")
370
+ return { color: arrowColor, opacity: 100 };
371
+ if (isThemeableValue3(arrowColor)) {
372
+ return arrowColor.useTheme ? resolveColor(arrowColor.themeKey) : arrowColor.value;
373
+ }
374
+ if ("color" in arrowColor) return arrowColor;
375
+ return { color: "#FFFFFF", opacity: 100 };
376
+ })();
377
+ const resolvedDotColor = (() => {
378
+ if (!dotColor) return resolveColor("primary");
379
+ if (typeof dotColor === "string") return { color: dotColor, opacity: 100 };
380
+ if (isThemeableValue3(dotColor)) {
381
+ return dotColor.useTheme ? resolveColor(dotColor.themeKey) : dotColor.value;
382
+ }
383
+ if ("color" in dotColor) return dotColor;
384
+ return resolveColor("primary");
385
+ })();
386
+ const goToPrevious = () => {
387
+ const newIndex = currentIndex === 0 ? images.length - 1 : currentIndex - 1;
388
+ setCurrentIndex(newIndex);
389
+ sendEvent("carousel_navigate", {
390
+ direction: "previous",
391
+ slideIndex: newIndex,
392
+ totalSlides: images.length,
393
+ ...utm
394
+ });
395
+ };
396
+ const goToNext = () => {
397
+ const newIndex = currentIndex === images.length - 1 ? 0 : currentIndex + 1;
398
+ setCurrentIndex(newIndex);
399
+ sendEvent("carousel_navigate", {
400
+ direction: "next",
401
+ slideIndex: newIndex,
402
+ totalSlides: images.length,
403
+ ...utm
404
+ });
405
+ };
406
+ const goToSlide = (index) => {
407
+ setCurrentIndex(index);
408
+ sendEvent("carousel_navigate", {
409
+ direction: "direct",
410
+ slideIndex: index,
411
+ totalSlides: images.length,
412
+ ...utm
413
+ });
414
+ };
415
+ if (images.length === 0) {
416
+ return /* @__PURE__ */ jsx5("div", { style: getEmptyState(aspectRatio, borderRadius), children: "No images" });
417
+ }
418
+ const arrowColorStr = hexToRgba(
419
+ resolvedArrowColor.color,
420
+ resolvedArrowColor.opacity
421
+ );
422
+ const dotColorStr = hexToRgba(
423
+ resolvedDotColor.color,
424
+ resolvedDotColor.opacity
425
+ );
426
+ return /* @__PURE__ */ jsxs2("div", { id, style: getContainerStyle(aspectRatio, borderRadius), children: [
427
+ /* @__PURE__ */ jsx5("div", { style: getSlideContainerStyle(currentIndex), children: images.map((image, index) => /* @__PURE__ */ jsx5("div", { style: slideStyle, children: /* @__PURE__ */ jsx5(
428
+ "img",
429
+ {
430
+ src: image.src,
431
+ alt: image.alt || "",
432
+ style: imageStyle,
433
+ loading: "lazy"
434
+ }
435
+ ) }, index)) }),
436
+ showArrows && images.length > 1 && /* @__PURE__ */ jsxs2(Fragment, { children: [
437
+ /* @__PURE__ */ jsx5(
438
+ "button",
439
+ {
440
+ type: "button",
441
+ onClick: goToPrevious,
442
+ style: { ...getArrowStyle(arrowColorStr), left: "16px" },
443
+ "aria-label": "Previous slide",
444
+ children: "\u2039"
445
+ }
446
+ ),
447
+ /* @__PURE__ */ jsx5(
448
+ "button",
449
+ {
450
+ type: "button",
451
+ onClick: goToNext,
452
+ style: { ...getArrowStyle(arrowColorStr), right: "16px" },
453
+ "aria-label": "Next slide",
454
+ children: "\u203A"
455
+ }
456
+ )
457
+ ] }),
458
+ showDots && images.length > 1 && /* @__PURE__ */ jsx5("div", { style: dotsContainerStyle, children: images.map((_, index) => /* @__PURE__ */ jsx5(
459
+ "button",
460
+ {
461
+ type: "button",
462
+ onClick: () => goToSlide(index),
463
+ style: getDotStyle(index === currentIndex, dotColorStr),
464
+ "aria-label": `Go to slide ${index + 1}`
465
+ },
466
+ index
467
+ )) })
468
+ ] });
469
+ }
470
+
471
+ // components/page/next/Icon.tsx
472
+ import { jsx as jsx6 } from "react/jsx-runtime";
473
+ function Icon({
474
+ name = "check",
475
+ size = "md",
476
+ color,
477
+ align = "center",
478
+ id
479
+ }) {
480
+ const { resolveColor } = useTheme();
481
+ const resolvedColor = (() => {
482
+ if (!color) return resolveColor("primary");
483
+ if (typeof color === "string") return { color, opacity: 100 };
484
+ if (isThemeableValue4(color)) {
485
+ return color.useTheme ? resolveColor(color.themeKey) : color.value;
486
+ }
487
+ if ("color" in color) return color;
488
+ return resolveColor("primary");
489
+ })();
490
+ const IconComponent = icons[name.toLowerCase()] || icons.check;
491
+ const { size: iconSize, strokeWidth } = sizeMap[size];
492
+ const colorValue = hexToRgba(resolvedColor.color, resolvedColor.opacity);
493
+ const wrapperStyle = getWrapperStyle3(align);
494
+ return /* @__PURE__ */ jsx6("div", { id, style: wrapperStyle, children: /* @__PURE__ */ jsx6(
495
+ IconComponent,
496
+ {
497
+ size: iconSize,
498
+ color: colorValue,
499
+ strokeWidth
500
+ }
501
+ ) });
502
+ }
503
+
504
+ // components/page/next/Section.tsx
505
+ import { jsx as jsx7 } from "react/jsx-runtime";
506
+ function Section({
507
+ children: _children,
508
+ verticalPadding = 48,
509
+ horizontalPadding = 32,
510
+ gap = 24,
511
+ backgroundColor,
512
+ backgroundImage,
513
+ shadow = "none",
514
+ borderRadius = 0,
515
+ contentMaxWidth = "1400px",
516
+ anchorLink,
517
+ visibility,
518
+ puck
519
+ }) {
520
+ const { resolveColor } = useTheme();
521
+ const DropZone = puck?.renderDropZone;
522
+ const style = {
523
+ ...getSectionStyle(
524
+ verticalPadding,
525
+ horizontalPadding,
526
+ gap,
527
+ resolveBackgroundColor(backgroundColor, resolveColor),
528
+ backgroundImage,
529
+ shadow,
530
+ borderRadius
531
+ ),
532
+ boxShadow: getShadowCSS(shadow)
533
+ };
534
+ return /* @__PURE__ */ jsx7(
535
+ "section",
536
+ {
537
+ id: anchorLink,
538
+ className: cn("flex w-full flex-col", getVisibilityClasses(visibility)),
539
+ style,
540
+ children: /* @__PURE__ */ jsx7("div", { className: "mx-auto w-full", style: { maxWidth: contentMaxWidth }, children: DropZone && /* @__PURE__ */ jsx7(DropZone, { zone: "content" }) })
541
+ }
542
+ );
543
+ }
544
+
545
+ // components/page/next/Container.tsx
546
+ import { jsx as jsx8 } from "react/jsx-runtime";
547
+ function Container({
548
+ maxWidth = "lg",
549
+ padding,
550
+ paddingX = "md",
551
+ paddingY = "none",
552
+ backgroundColor,
553
+ centered = true,
554
+ id,
555
+ puck
556
+ }) {
557
+ const { resolveColor } = useTheme();
558
+ const DropZone = puck?.renderDropZone;
559
+ const resolvedBgColor = (() => {
560
+ if (!backgroundColor) return null;
561
+ if (typeof backgroundColor === "string")
562
+ return { color: backgroundColor, opacity: 100 };
563
+ if (isThemeableValue5(backgroundColor)) {
564
+ return backgroundColor.useTheme ? resolveColor(backgroundColor.themeKey) : backgroundColor.value;
565
+ }
566
+ if ("color" in backgroundColor) return backgroundColor;
567
+ return null;
568
+ })();
569
+ const effectivePaddingX = padding || paddingX;
570
+ const effectivePaddingY = padding || paddingY;
571
+ const style = getContainerStyle2(
572
+ maxWidth,
573
+ effectivePaddingX,
574
+ effectivePaddingY,
575
+ centered,
576
+ resolvedBgColor ? hexToRgba(resolvedBgColor.color, resolvedBgColor.opacity) : void 0
577
+ );
578
+ return /* @__PURE__ */ jsx8("div", { id, style, children: DropZone && /* @__PURE__ */ jsx8(DropZone, { zone: "container-content" }) });
579
+ }
580
+
581
+ // components/page/next/Columns.tsx
582
+ import { jsx as jsx9 } from "react/jsx-runtime";
583
+ function Columns({
584
+ columns = 2,
585
+ gap = "md",
586
+ verticalAlign = "top",
587
+ stackOnMobile = true,
588
+ id,
589
+ puck
590
+ }) {
591
+ const DropZone = puck?.renderDropZone;
592
+ const containerStyle = getContainerStyle3(columns, gap, verticalAlign);
593
+ return /* @__PURE__ */ jsx9("div", { id, style: containerStyle, children: Array.from({ length: columns }).map((_, index) => /* @__PURE__ */ jsx9("div", { style: { minWidth: 0 }, children: DropZone && /* @__PURE__ */ jsx9(DropZone, { zone: `column-${index}` }) }, index)) });
594
+ }
595
+
596
+ // components/page/next/Card.tsx
597
+ import { jsx as jsx10 } from "react/jsx-runtime";
598
+ function Card({
599
+ backgroundColor,
600
+ borderColor,
601
+ borderWidth = "thin",
602
+ borderRadius = "md",
603
+ shadow = "sm",
604
+ padding = "md",
605
+ id,
606
+ puck
607
+ }) {
608
+ const { resolveColor } = useTheme();
609
+ const DropZone = puck?.renderDropZone;
610
+ const resolvedBgColor = (() => {
611
+ if (!backgroundColor) return resolveColor("background");
612
+ if (typeof backgroundColor === "string")
613
+ return { color: backgroundColor, opacity: 100 };
614
+ if (isThemeableValue6(backgroundColor)) {
615
+ return backgroundColor.useTheme ? resolveColor(backgroundColor.themeKey) : backgroundColor.value;
616
+ }
617
+ if ("color" in backgroundColor) return backgroundColor;
618
+ return resolveColor("background");
619
+ })();
620
+ const resolvedBorderColor = (() => {
621
+ if (!borderColor) return resolveColor("muted");
622
+ if (typeof borderColor === "string")
623
+ return { color: borderColor, opacity: 100 };
624
+ if (isThemeableValue6(borderColor)) {
625
+ return borderColor.useTheme ? resolveColor(borderColor.themeKey) : borderColor.value;
626
+ }
627
+ if ("color" in borderColor) return borderColor;
628
+ return resolveColor("muted");
629
+ })();
630
+ const style = getCardStyle(
631
+ hexToRgba(resolvedBgColor.color, resolvedBgColor.opacity),
632
+ hexToRgba(resolvedBorderColor.color, resolvedBorderColor.opacity),
633
+ borderWidth,
634
+ borderRadius,
635
+ shadow,
636
+ padding
637
+ );
638
+ return /* @__PURE__ */ jsx10("div", { id, style, children: DropZone && /* @__PURE__ */ jsx10(DropZone, { zone: "card-content" }) });
639
+ }
640
+
641
+ // components/page/next/Divider.tsx
642
+ import { jsx as jsx11 } from "react/jsx-runtime";
643
+ function Divider({
644
+ style: lineStyle = "solid",
645
+ thickness = "thin",
646
+ color,
647
+ width = "full",
648
+ align = "center",
649
+ spacing = "md",
650
+ id
651
+ }) {
652
+ const { resolveColor } = useTheme();
653
+ const resolvedColor = (() => {
654
+ if (!color) return resolveColor("muted");
655
+ if (typeof color === "string") return { color, opacity: 100 };
656
+ if (isThemeableValue7(color)) {
657
+ return color.useTheme ? resolveColor(color.themeKey) : color.value;
658
+ }
659
+ if ("color" in color) return color;
660
+ return resolveColor("muted");
661
+ })();
662
+ const wrapperStyle = getWrapperStyle4(align, spacing);
663
+ const hrStyle = getHrStyle(
664
+ width,
665
+ thickness,
666
+ lineStyle,
667
+ hexToRgba(resolvedColor.color, resolvedColor.opacity)
668
+ );
669
+ return /* @__PURE__ */ jsx11("div", { id, style: wrapperStyle, children: /* @__PURE__ */ jsx11("hr", { style: hrStyle }) });
670
+ }
671
+
672
+ // components/page/next/Spacer.tsx
673
+ import { jsx as jsx12 } from "react/jsx-runtime";
674
+ function Spacer({ size = "md", id }) {
675
+ const style = {
676
+ height: sizeMap2[size],
677
+ width: "100%"
678
+ };
679
+ return /* @__PURE__ */ jsx12("div", { id, style, "aria-hidden": "true" });
680
+ }
681
+
682
+ export {
683
+ Heading,
684
+ Paragraph,
685
+ Button,
686
+ Image,
687
+ ImageCarousel,
688
+ Icon,
689
+ Section,
690
+ Container,
691
+ Columns,
692
+ Card,
693
+ Divider,
694
+ Spacer
695
+ };