@opensite/ui 0.7.4 → 0.7.5
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/carousel-fullscreen-scroll-fx.cjs +576 -118
- package/dist/carousel-fullscreen-scroll-fx.d.cts +5 -1
- package/dist/carousel-fullscreen-scroll-fx.d.ts +5 -1
- package/dist/carousel-fullscreen-scroll-fx.js +577 -119
- package/dist/registry.cjs +165 -126
- package/dist/registry.js +165 -126
- package/package.json +1 -1
package/dist/registry.cjs
CHANGED
|
@@ -18296,41 +18296,44 @@ function CarouselFullscreenScrollFx({
|
|
|
18296
18296
|
patternOpacity = 0.033
|
|
18297
18297
|
}) {
|
|
18298
18298
|
const containerRef = React52__namespace.useRef(null);
|
|
18299
|
+
const scrollContainerRef = React52__namespace.useRef(null);
|
|
18299
18300
|
const [activeIndex, setActiveIndex] = React52__namespace.useState(0);
|
|
18300
18301
|
React52__namespace.useEffect(() => {
|
|
18301
|
-
const
|
|
18302
|
-
slides?.
|
|
18303
|
-
|
|
18304
|
-
|
|
18305
|
-
|
|
18306
|
-
|
|
18307
|
-
|
|
18308
|
-
if (entry.isIntersecting && entry.intersectionRatio > 0.5) {
|
|
18309
|
-
setActiveIndex(index);
|
|
18310
|
-
}
|
|
18311
|
-
});
|
|
18312
|
-
},
|
|
18313
|
-
{ threshold: 0.5 }
|
|
18314
|
-
);
|
|
18315
|
-
observer.observe(element);
|
|
18316
|
-
observers.push(observer);
|
|
18317
|
-
}
|
|
18318
|
-
});
|
|
18319
|
-
return () => {
|
|
18320
|
-
observers.forEach((observer) => observer.disconnect());
|
|
18302
|
+
const scrollContainer = scrollContainerRef.current;
|
|
18303
|
+
if (!scrollContainer || !slides?.length) return;
|
|
18304
|
+
const handleScroll = () => {
|
|
18305
|
+
const scrollLeft = scrollContainer.scrollLeft;
|
|
18306
|
+
const slideWidth = scrollContainer.clientWidth;
|
|
18307
|
+
const newIndex = Math.round(scrollLeft / slideWidth);
|
|
18308
|
+
setActiveIndex(newIndex);
|
|
18321
18309
|
};
|
|
18310
|
+
scrollContainer.addEventListener("scroll", handleScroll);
|
|
18311
|
+
return () => scrollContainer.removeEventListener("scroll", handleScroll);
|
|
18322
18312
|
}, [slides]);
|
|
18313
|
+
const scrollToSlide = React52__namespace.useCallback((index) => {
|
|
18314
|
+
const scrollContainer = scrollContainerRef.current;
|
|
18315
|
+
if (!scrollContainer) return;
|
|
18316
|
+
const slideWidth = scrollContainer.clientWidth;
|
|
18317
|
+
if (typeof scrollContainer.scrollTo === "function") {
|
|
18318
|
+
scrollContainer.scrollTo({
|
|
18319
|
+
left: slideWidth * index,
|
|
18320
|
+
behavior: "smooth"
|
|
18321
|
+
});
|
|
18322
|
+
} else {
|
|
18323
|
+
scrollContainer.scrollLeft = slideWidth * index;
|
|
18324
|
+
}
|
|
18325
|
+
}, []);
|
|
18323
18326
|
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
18324
18327
|
Section,
|
|
18325
18328
|
{
|
|
18326
18329
|
ref: containerRef,
|
|
18327
18330
|
background,
|
|
18328
18331
|
spacing,
|
|
18329
|
-
className: cn(className),
|
|
18332
|
+
className: cn("relative overflow-hidden", className),
|
|
18330
18333
|
pattern,
|
|
18331
18334
|
patternOpacity,
|
|
18332
18335
|
containerMaxWidth,
|
|
18333
|
-
containerClassName,
|
|
18336
|
+
containerClassName: "p-0",
|
|
18334
18337
|
children: [
|
|
18335
18338
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
18336
18339
|
"div",
|
|
@@ -18342,10 +18345,7 @@ function CarouselFullscreenScrollFx({
|
|
|
18342
18345
|
children: slides?.map((slide, index) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
18343
18346
|
"button",
|
|
18344
18347
|
{
|
|
18345
|
-
onClick: () =>
|
|
18346
|
-
const element = document.getElementById(`fullscreen-${slide.id}`);
|
|
18347
|
-
element?.scrollIntoView({ behavior: "smooth" });
|
|
18348
|
-
},
|
|
18348
|
+
onClick: () => scrollToSlide(index),
|
|
18349
18349
|
className: cn(
|
|
18350
18350
|
"h-3 w-3 rounded-full border-2 transition-all",
|
|
18351
18351
|
activeIndex === index ? "scale-125 border-white bg-white" : "border-white/50 bg-transparent hover:border-white"
|
|
@@ -18356,111 +18356,150 @@ function CarouselFullscreenScrollFx({
|
|
|
18356
18356
|
))
|
|
18357
18357
|
}
|
|
18358
18358
|
),
|
|
18359
|
-
|
|
18359
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
18360
18360
|
"div",
|
|
18361
18361
|
{
|
|
18362
|
-
|
|
18363
|
-
className:
|
|
18364
|
-
|
|
18365
|
-
|
|
18366
|
-
|
|
18367
|
-
|
|
18368
|
-
|
|
18369
|
-
|
|
18370
|
-
|
|
18371
|
-
|
|
18372
|
-
|
|
18373
|
-
|
|
18374
|
-
className:
|
|
18375
|
-
|
|
18376
|
-
|
|
18377
|
-
|
|
18378
|
-
|
|
18379
|
-
|
|
18380
|
-
|
|
18381
|
-
|
|
18382
|
-
|
|
18383
|
-
|
|
18384
|
-
|
|
18385
|
-
|
|
18386
|
-
|
|
18387
|
-
|
|
18388
|
-
|
|
18389
|
-
|
|
18390
|
-
|
|
18391
|
-
|
|
18362
|
+
ref: scrollContainerRef,
|
|
18363
|
+
className: "flex h-screen snap-x snap-mandatory overflow-x-auto overflow-y-hidden scroll-smooth",
|
|
18364
|
+
style: { scrollbarWidth: "none", msOverflowStyle: "none" },
|
|
18365
|
+
children: slidesSlot ? slidesSlot : slides?.map((slide, index) => {
|
|
18366
|
+
const renderActions = React52__namespace.useMemo(() => {
|
|
18367
|
+
if (!slide.actions || slide.actions.length === 0) return null;
|
|
18368
|
+
return slide.actions.map((action, actionIndex) => {
|
|
18369
|
+
const {
|
|
18370
|
+
label,
|
|
18371
|
+
icon,
|
|
18372
|
+
iconAfter,
|
|
18373
|
+
children,
|
|
18374
|
+
className: actionClassName,
|
|
18375
|
+
asButton,
|
|
18376
|
+
...pressableProps
|
|
18377
|
+
} = action;
|
|
18378
|
+
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
18379
|
+
Pressable,
|
|
18380
|
+
{
|
|
18381
|
+
asButton: asButton ?? true,
|
|
18382
|
+
className: actionClassName,
|
|
18383
|
+
...pressableProps,
|
|
18384
|
+
children: children ?? /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
18385
|
+
icon,
|
|
18386
|
+
label,
|
|
18387
|
+
iconAfter
|
|
18388
|
+
] })
|
|
18389
|
+
},
|
|
18390
|
+
actionIndex
|
|
18391
|
+
);
|
|
18392
|
+
});
|
|
18393
|
+
}, [slide.actions]);
|
|
18394
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
18392
18395
|
"div",
|
|
18393
18396
|
{
|
|
18397
|
+
id: `fullscreen-${slide.id}`,
|
|
18394
18398
|
className: cn(
|
|
18395
|
-
"relative
|
|
18396
|
-
|
|
18399
|
+
"relative flex h-screen min-w-full snap-start items-center justify-center overflow-hidden",
|
|
18400
|
+
slide.className
|
|
18397
18401
|
),
|
|
18398
18402
|
children: [
|
|
18399
|
-
|
|
18400
|
-
|
|
18403
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "absolute inset-0", children: [
|
|
18404
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
18405
|
+
img.Img,
|
|
18406
|
+
{
|
|
18407
|
+
src: slide.image,
|
|
18408
|
+
alt: typeof slide.title === "string" ? slide.title : `Slide ${index + 1}`,
|
|
18409
|
+
className: cn(
|
|
18410
|
+
"h-full w-full object-cover",
|
|
18411
|
+
slide.imageClassName
|
|
18412
|
+
),
|
|
18413
|
+
optixFlowConfig
|
|
18414
|
+
}
|
|
18415
|
+
),
|
|
18416
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
18417
|
+
"div",
|
|
18418
|
+
{
|
|
18419
|
+
className: "absolute inset-0",
|
|
18420
|
+
style: {
|
|
18421
|
+
backgroundColor: slide.overlayColor || "rgba(0, 0, 0, 0.5)"
|
|
18422
|
+
}
|
|
18423
|
+
}
|
|
18424
|
+
)
|
|
18425
|
+
] }),
|
|
18426
|
+
/* @__PURE__ */ jsxRuntime.jsxs(
|
|
18427
|
+
"div",
|
|
18401
18428
|
{
|
|
18402
18429
|
className: cn(
|
|
18403
|
-
"
|
|
18404
|
-
|
|
18430
|
+
"relative z-10 mx-auto max-w-4xl md:max-w-2xl px-6 text-center text-white text-shadow",
|
|
18431
|
+
contentClassName
|
|
18405
18432
|
),
|
|
18406
|
-
children:
|
|
18433
|
+
children: [
|
|
18434
|
+
slide.subtitle && (typeof slide.subtitle === "string" ? /* @__PURE__ */ jsxRuntime.jsx(
|
|
18435
|
+
"p",
|
|
18436
|
+
{
|
|
18437
|
+
className: cn(
|
|
18438
|
+
"mb-4 text-sm font-medium uppercase tracking-widest text-white/70",
|
|
18439
|
+
subtitleClassName
|
|
18440
|
+
),
|
|
18441
|
+
children: slide.subtitle
|
|
18442
|
+
}
|
|
18443
|
+
) : /* @__PURE__ */ jsxRuntime.jsx("div", { className: subtitleClassName, children: slide.subtitle })),
|
|
18444
|
+
slide.title && (typeof slide.title === "string" ? /* @__PURE__ */ jsxRuntime.jsx(
|
|
18445
|
+
"h2",
|
|
18446
|
+
{
|
|
18447
|
+
className: cn(
|
|
18448
|
+
"mb-6 text-4xl font-bold tracking-tight md:text-5xl lg:text-6xl",
|
|
18449
|
+
titleClassName
|
|
18450
|
+
),
|
|
18451
|
+
children: slide.title
|
|
18452
|
+
}
|
|
18453
|
+
) : /* @__PURE__ */ jsxRuntime.jsx("div", { className: titleClassName, children: slide.title })),
|
|
18454
|
+
slide.description && (typeof slide.description === "string" ? /* @__PURE__ */ jsxRuntime.jsx(
|
|
18455
|
+
"p",
|
|
18456
|
+
{
|
|
18457
|
+
className: cn(
|
|
18458
|
+
"mx-auto text-lg text-white/80 md:text-xl text-balance",
|
|
18459
|
+
descriptionClassName
|
|
18460
|
+
),
|
|
18461
|
+
children: slide.description
|
|
18462
|
+
}
|
|
18463
|
+
) : /* @__PURE__ */ jsxRuntime.jsx("div", { className: descriptionClassName, children: slide.description })),
|
|
18464
|
+
renderActions && /* @__PURE__ */ jsxRuntime.jsx("div", { className: "mt-8 flex flex-col items-center justify-center gap-3 sm:flex-row", children: renderActions })
|
|
18465
|
+
]
|
|
18407
18466
|
}
|
|
18408
|
-
)
|
|
18409
|
-
|
|
18410
|
-
"
|
|
18467
|
+
),
|
|
18468
|
+
index < (slides?.length ?? 0) - 1 && /* @__PURE__ */ jsxRuntime.jsx(
|
|
18469
|
+
"div",
|
|
18411
18470
|
{
|
|
18412
18471
|
className: cn(
|
|
18413
|
-
"
|
|
18414
|
-
|
|
18472
|
+
"absolute bottom-8 left-1/2 -translate-x-1/2",
|
|
18473
|
+
scrollIndicatorClassName
|
|
18415
18474
|
),
|
|
18416
|
-
children:
|
|
18475
|
+
children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-col items-center gap-2", children: [
|
|
18476
|
+
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-xs uppercase tracking-widest text-white/50", children: "Scroll" }),
|
|
18477
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "h-12 w-px animate-pulse bg-linear-to-b from-white/50 to-transparent" })
|
|
18478
|
+
] })
|
|
18417
18479
|
}
|
|
18418
|
-
)
|
|
18419
|
-
|
|
18420
|
-
"
|
|
18480
|
+
),
|
|
18481
|
+
/* @__PURE__ */ jsxRuntime.jsxs(
|
|
18482
|
+
"div",
|
|
18421
18483
|
{
|
|
18422
18484
|
className: cn(
|
|
18423
|
-
"
|
|
18424
|
-
|
|
18485
|
+
"absolute bottom-8 right-8 text-sm text-white/50",
|
|
18486
|
+
counterClassName
|
|
18425
18487
|
),
|
|
18426
|
-
children:
|
|
18488
|
+
children: [
|
|
18489
|
+
String(index + 1).padStart(2, "0"),
|
|
18490
|
+
" /",
|
|
18491
|
+
" ",
|
|
18492
|
+
String(slides?.length ?? 0).padStart(2, "0")
|
|
18493
|
+
]
|
|
18427
18494
|
}
|
|
18428
|
-
)
|
|
18429
|
-
]
|
|
18430
|
-
}
|
|
18431
|
-
),
|
|
18432
|
-
index < (slides?.length ?? 0) - 1 && /* @__PURE__ */ jsxRuntime.jsx(
|
|
18433
|
-
"div",
|
|
18434
|
-
{
|
|
18435
|
-
className: cn(
|
|
18436
|
-
"absolute bottom-8 left-1/2 -translate-x-1/2",
|
|
18437
|
-
scrollIndicatorClassName
|
|
18438
|
-
),
|
|
18439
|
-
children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-col items-center gap-2", children: [
|
|
18440
|
-
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-xs uppercase tracking-widest text-white/50", children: "Scroll" }),
|
|
18441
|
-
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "h-12 w-px animate-pulse bg-linear-to-b from-white/50 to-transparent" })
|
|
18442
|
-
] })
|
|
18443
|
-
}
|
|
18444
|
-
),
|
|
18445
|
-
/* @__PURE__ */ jsxRuntime.jsxs(
|
|
18446
|
-
"div",
|
|
18447
|
-
{
|
|
18448
|
-
className: cn(
|
|
18449
|
-
"absolute bottom-8 right-8 text-sm text-white/50",
|
|
18450
|
-
counterClassName
|
|
18451
|
-
),
|
|
18452
|
-
children: [
|
|
18453
|
-
String(index + 1).padStart(2, "0"),
|
|
18454
|
-
" /",
|
|
18455
|
-
" ",
|
|
18456
|
-
String(slides?.length ?? 0).padStart(2, "0")
|
|
18495
|
+
)
|
|
18457
18496
|
]
|
|
18458
|
-
}
|
|
18459
|
-
|
|
18460
|
-
|
|
18461
|
-
|
|
18462
|
-
|
|
18463
|
-
)
|
|
18497
|
+
},
|
|
18498
|
+
slide.id
|
|
18499
|
+
);
|
|
18500
|
+
})
|
|
18501
|
+
}
|
|
18502
|
+
)
|
|
18464
18503
|
]
|
|
18465
18504
|
}
|
|
18466
18505
|
);
|
|
@@ -76942,7 +76981,7 @@ function ListSearchableGrid({
|
|
|
76942
76981
|
}
|
|
76943
76982
|
);
|
|
76944
76983
|
}
|
|
76945
|
-
var { useMemo:
|
|
76984
|
+
var { useMemo: useMemo441 } = React52__namespace;
|
|
76946
76985
|
function OfferModalNewsletterDiscount({
|
|
76947
76986
|
title,
|
|
76948
76987
|
emailPlaceholder,
|
|
@@ -77009,7 +77048,7 @@ function OfferModalNewsletterDiscount({
|
|
|
77009
77048
|
});
|
|
77010
77049
|
const formMethod = formConfig?.method?.toLowerCase() === "get" ? "get" : "post";
|
|
77011
77050
|
const dialogProps = open !== void 0 ? { open, onOpenChange } : { defaultOpen };
|
|
77012
|
-
const renderCloseButton =
|
|
77051
|
+
const renderCloseButton = useMemo441(() => {
|
|
77013
77052
|
if (closeButtonSlot) return closeButtonSlot;
|
|
77014
77053
|
if (!closeButtonText) return null;
|
|
77015
77054
|
return /* @__PURE__ */ jsxRuntime.jsx("div", { className: "absolute end-1.5 top-1.5", children: /* @__PURE__ */ jsxRuntime.jsx(DialogClose, { asChild: true, children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
@@ -77023,12 +77062,12 @@ function OfferModalNewsletterDiscount({
|
|
|
77023
77062
|
}
|
|
77024
77063
|
) }) });
|
|
77025
77064
|
}, [closeButtonSlot, closeButtonText, closeClassName]);
|
|
77026
|
-
const renderHeader =
|
|
77065
|
+
const renderHeader = useMemo441(() => {
|
|
77027
77066
|
if (headerSlot) return headerSlot;
|
|
77028
77067
|
if (!title) return null;
|
|
77029
77068
|
return /* @__PURE__ */ jsxRuntime.jsx(DialogHeader, { className: headerClassName, children: typeof title === "string" ? /* @__PURE__ */ jsxRuntime.jsx(DialogTitle, { className: cn("text-start font-serif text-2xl font-normal leading-snug", titleClassName), children: title }) : /* @__PURE__ */ jsxRuntime.jsx(DialogTitle, { className: cn("text-start font-serif text-2xl font-normal leading-snug", titleClassName), children: title }) });
|
|
77030
77069
|
}, [headerSlot, title, headerClassName, titleClassName]);
|
|
77031
|
-
const renderForm =
|
|
77070
|
+
const renderForm = useMemo441(() => {
|
|
77032
77071
|
if (formSlot) return formSlot;
|
|
77033
77072
|
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
77034
77073
|
forms.Form,
|
|
@@ -77090,7 +77129,7 @@ function OfferModalNewsletterDiscount({
|
|
|
77090
77129
|
}
|
|
77091
77130
|
) });
|
|
77092
77131
|
}
|
|
77093
|
-
var { useMemo:
|
|
77132
|
+
var { useMemo: useMemo442 } = React52__namespace;
|
|
77094
77133
|
function OfferModalMembershipImage({
|
|
77095
77134
|
overline,
|
|
77096
77135
|
title,
|
|
@@ -77166,7 +77205,7 @@ function OfferModalMembershipImage({
|
|
|
77166
77205
|
});
|
|
77167
77206
|
const formMethod = formConfig?.method?.toLowerCase() === "get" ? "get" : "post";
|
|
77168
77207
|
const dialogProps = open !== void 0 ? { open, onOpenChange } : { defaultOpen };
|
|
77169
|
-
const renderImage =
|
|
77208
|
+
const renderImage = useMemo442(() => {
|
|
77170
77209
|
if (imageSlot) return imageSlot;
|
|
77171
77210
|
if (!image) return null;
|
|
77172
77211
|
return /* @__PURE__ */ jsxRuntime.jsx("div", { className: cn("max-h-[290px] h-full overflow-hidden max-lg:hidden", imageWrapperClassName), children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
@@ -77179,7 +77218,7 @@ function OfferModalMembershipImage({
|
|
|
77179
77218
|
}
|
|
77180
77219
|
) });
|
|
77181
77220
|
}, [imageSlot, image, imageWrapperClassName, imageClassName, optixFlowConfig]);
|
|
77182
|
-
const renderCloseButton =
|
|
77221
|
+
const renderCloseButton = useMemo442(() => {
|
|
77183
77222
|
if (closeButtonSlot) return closeButtonSlot;
|
|
77184
77223
|
return /* @__PURE__ */ jsxRuntime.jsx("div", { className: "absolute -end-px -top-px z-10", children: /* @__PURE__ */ jsxRuntime.jsx(DialogClose, { asChild: true, children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
77185
77224
|
Pressable,
|
|
@@ -77195,7 +77234,7 @@ function OfferModalMembershipImage({
|
|
|
77195
77234
|
}
|
|
77196
77235
|
) }) });
|
|
77197
77236
|
}, [closeButtonSlot, closeClassName]);
|
|
77198
|
-
const renderForm =
|
|
77237
|
+
const renderForm = useMemo442(() => {
|
|
77199
77238
|
if (formSlot) return formSlot;
|
|
77200
77239
|
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
77201
77240
|
forms.Form,
|
|
@@ -77258,7 +77297,7 @@ function OfferModalMembershipImage({
|
|
|
77258
77297
|
}
|
|
77259
77298
|
);
|
|
77260
77299
|
}, [formSlot, form, formConfig, formMethod, emailPlaceholder, inputClassName, submitClassName, buttonText, formClassName]);
|
|
77261
|
-
const renderFooter =
|
|
77300
|
+
const renderFooter = useMemo442(() => {
|
|
77262
77301
|
if (footerSlot) return footerSlot;
|
|
77263
77302
|
if (!description) return null;
|
|
77264
77303
|
return /* @__PURE__ */ jsxRuntime.jsx(DialogFooter, { className: footerClassName, children: /* @__PURE__ */ jsxRuntime.jsx(DialogDescription, { className: cn("text-muted-foreground text-center text-xs leading-relaxed", descriptionClassName), children: description }) });
|
|
@@ -77286,7 +77325,7 @@ function OfferModalMembershipImage({
|
|
|
77286
77325
|
}
|
|
77287
77326
|
) });
|
|
77288
77327
|
}
|
|
77289
|
-
var { useMemo:
|
|
77328
|
+
var { useMemo: useMemo443 } = React52__namespace;
|
|
77290
77329
|
function OfferModalSheetNewsletter({
|
|
77291
77330
|
logo,
|
|
77292
77331
|
logoSlot,
|
|
@@ -77368,7 +77407,7 @@ function OfferModalSheetNewsletter({
|
|
|
77368
77407
|
});
|
|
77369
77408
|
const formMethod = formConfig?.method?.toLowerCase() === "get" ? "get" : "post";
|
|
77370
77409
|
const sheetProps = open !== void 0 ? { open, onOpenChange } : { defaultOpen };
|
|
77371
|
-
const renderLogo =
|
|
77410
|
+
const renderLogo = useMemo443(() => {
|
|
77372
77411
|
if (logoSlot) return logoSlot;
|
|
77373
77412
|
if (!logo) return null;
|
|
77374
77413
|
const logoSrc = typeof logo.src === "string" ? logo.src : logo.src.light;
|
|
@@ -77382,7 +77421,7 @@ function OfferModalSheetNewsletter({
|
|
|
77382
77421
|
}
|
|
77383
77422
|
);
|
|
77384
77423
|
}, [logoSlot, logo, logoClassName, optixFlowConfig]);
|
|
77385
|
-
const renderHeader =
|
|
77424
|
+
const renderHeader = useMemo443(() => {
|
|
77386
77425
|
if (headerSlot) return headerSlot;
|
|
77387
77426
|
return /* @__PURE__ */ jsxRuntime.jsxs(SheetHeader, { className: cn("gap-8 p-0", headerClassName), children: [
|
|
77388
77427
|
renderLogo,
|
|
@@ -77392,7 +77431,7 @@ function OfferModalSheetNewsletter({
|
|
|
77392
77431
|
] })
|
|
77393
77432
|
] });
|
|
77394
77433
|
}, [headerSlot, renderLogo, headerClassName, title, titleClassName, description, descriptionClassName]);
|
|
77395
|
-
const renderForm =
|
|
77434
|
+
const renderForm = useMemo443(() => {
|
|
77396
77435
|
if (formSlot) return formSlot;
|
|
77397
77436
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
77398
77437
|
forms.Form,
|
|
@@ -77440,7 +77479,7 @@ function OfferModalSheetNewsletter({
|
|
|
77440
77479
|
}
|
|
77441
77480
|
);
|
|
77442
77481
|
}, [formSlot, form, formConfig, formMethod, emailPlaceholder, inputClassName, submitClassName, buttonText, formClassName]);
|
|
77443
|
-
const renderLegal =
|
|
77482
|
+
const renderLegal = useMemo443(() => {
|
|
77444
77483
|
if (legalSlot) return legalSlot;
|
|
77445
77484
|
if (!termsUrl || !termsText || !privacyUrl || !privacyText) return null;
|
|
77446
77485
|
return /* @__PURE__ */ jsxRuntime.jsxs("p", { className: cn("text-muted-foreground text-xs", legalClassName), children: [
|
|
@@ -77454,7 +77493,7 @@ function OfferModalSheetNewsletter({
|
|
|
77454
77493
|
"."
|
|
77455
77494
|
] });
|
|
77456
77495
|
}, [legalSlot, termsUrl, termsText, privacyUrl, privacyText, legalClassName]);
|
|
77457
|
-
const renderImage =
|
|
77496
|
+
const renderImage = useMemo443(() => {
|
|
77458
77497
|
if (imageSlot) return imageSlot;
|
|
77459
77498
|
if (!image) return null;
|
|
77460
77499
|
return /* @__PURE__ */ jsxRuntime.jsx("div", { className: cn("h-1/2 basis-1/2", imageWrapperClassName), children: /* @__PURE__ */ jsxRuntime.jsx(AspectRatio, { ratio: 1, className: "overflow-hidden", children: /* @__PURE__ */ jsxRuntime.jsx(
|