@opensite/ui 0.7.2 → 0.7.3
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-animated-sections.cjs +32 -32
- package/dist/carousel-animated-sections.d.cts +4 -3
- package/dist/carousel-animated-sections.d.ts +4 -3
- package/dist/carousel-animated-sections.js +32 -32
- package/dist/carousel-feature-badge.cjs +59 -18
- package/dist/carousel-feature-badge.d.cts +10 -2
- package/dist/carousel-feature-badge.d.ts +10 -2
- package/dist/carousel-feature-badge.js +59 -18
- package/dist/carousel-fullscreen-scroll-fx.cjs +104 -33
- package/dist/carousel-fullscreen-scroll-fx.d.cts +6 -2
- package/dist/carousel-fullscreen-scroll-fx.d.ts +6 -2
- package/dist/carousel-fullscreen-scroll-fx.js +104 -33
- package/dist/registry.cjs +210 -98
- package/dist/registry.js +210 -98
- package/package.json +1 -1
package/dist/registry.js
CHANGED
|
@@ -17239,13 +17239,23 @@ function ContactHelpCenter({
|
|
|
17239
17239
|
}
|
|
17240
17240
|
);
|
|
17241
17241
|
}
|
|
17242
|
+
var BRIGHTNESS_CLASS_MAP = {
|
|
17243
|
+
"10": "brightness-[.1]",
|
|
17244
|
+
"20": "brightness-[.2]",
|
|
17245
|
+
"25": "brightness-[.25]",
|
|
17246
|
+
"30": "brightness-[.3]",
|
|
17247
|
+
"40": "brightness-[.4]",
|
|
17248
|
+
"50": "brightness-50",
|
|
17249
|
+
"75": "brightness-75",
|
|
17250
|
+
"100": "brightness-100"
|
|
17251
|
+
};
|
|
17242
17252
|
function CarouselAnimatedSections({
|
|
17243
17253
|
sections,
|
|
17244
17254
|
sectionsSlot,
|
|
17245
17255
|
actionsSlot,
|
|
17246
17256
|
actions,
|
|
17247
17257
|
className,
|
|
17248
|
-
containerClassName = "h-full",
|
|
17258
|
+
containerClassName = "h-full flex flex-col justify-center",
|
|
17249
17259
|
contentClassName,
|
|
17250
17260
|
subtitleClassName,
|
|
17251
17261
|
titleClassName,
|
|
@@ -17254,7 +17264,7 @@ function CarouselAnimatedSections({
|
|
|
17254
17264
|
navigationClassName,
|
|
17255
17265
|
arrowsClassName,
|
|
17256
17266
|
counterClassName,
|
|
17257
|
-
|
|
17267
|
+
slideMediaBrightness = "50",
|
|
17258
17268
|
optixFlowConfig,
|
|
17259
17269
|
background = "dark",
|
|
17260
17270
|
spacing = "py-0",
|
|
@@ -17309,7 +17319,7 @@ function CarouselAnimatedSections({
|
|
|
17309
17319
|
})
|
|
17310
17320
|
};
|
|
17311
17321
|
const currentSection = sections?.[currentIndex];
|
|
17312
|
-
const
|
|
17322
|
+
const actionElements = React52.useMemo(() => {
|
|
17313
17323
|
if (actionsSlot) return actionsSlot;
|
|
17314
17324
|
if (actions && actions.length > 0) {
|
|
17315
17325
|
return actions.map((action, index) => /* @__PURE__ */ jsxs(
|
|
@@ -17319,11 +17329,8 @@ function CarouselAnimatedSections({
|
|
|
17319
17329
|
onClick: action.onClick,
|
|
17320
17330
|
asButton: true,
|
|
17321
17331
|
variant: action.variant,
|
|
17322
|
-
size: action.size
|
|
17323
|
-
className: cn(
|
|
17324
|
-
"bg-white text-black hover:bg-white/90",
|
|
17325
|
-
action.className
|
|
17326
|
-
),
|
|
17332
|
+
size: action.size,
|
|
17333
|
+
className: cn(action.className),
|
|
17327
17334
|
children: [
|
|
17328
17335
|
action.label,
|
|
17329
17336
|
action.icon && /* @__PURE__ */ jsx("span", { className: "ml-2", children: action.icon }),
|
|
@@ -17334,7 +17341,7 @@ function CarouselAnimatedSections({
|
|
|
17334
17341
|
));
|
|
17335
17342
|
}
|
|
17336
17343
|
return null;
|
|
17337
|
-
};
|
|
17344
|
+
}, [actionsSlot, actions]);
|
|
17338
17345
|
return /* @__PURE__ */ jsxs(
|
|
17339
17346
|
Section,
|
|
17340
17347
|
{
|
|
@@ -17346,7 +17353,7 @@ function CarouselAnimatedSections({
|
|
|
17346
17353
|
containerMaxWidth,
|
|
17347
17354
|
containerClassName,
|
|
17348
17355
|
children: [
|
|
17349
|
-
sectionsSlot ? sectionsSlot : currentSection ? /* @__PURE__ */ jsx(AnimatePresence, { initial: false, custom: direction, mode: "wait", children: /* @__PURE__ */
|
|
17356
|
+
sectionsSlot ? sectionsSlot : currentSection ? /* @__PURE__ */ jsx(AnimatePresence, { initial: false, custom: direction, mode: "wait", children: /* @__PURE__ */ jsx(
|
|
17350
17357
|
motion.div,
|
|
17351
17358
|
{
|
|
17352
17359
|
custom: direction,
|
|
@@ -17357,26 +17364,19 @@ function CarouselAnimatedSections({
|
|
|
17357
17364
|
transition: { duration: 0.6, ease: [0.4, 0, 0.2, 1] },
|
|
17358
17365
|
onAnimationComplete: () => setIsAnimating(false),
|
|
17359
17366
|
className: cn("absolute inset-0", currentSection?.className),
|
|
17360
|
-
children:
|
|
17361
|
-
|
|
17362
|
-
|
|
17363
|
-
|
|
17364
|
-
|
|
17365
|
-
|
|
17366
|
-
|
|
17367
|
-
|
|
17368
|
-
|
|
17369
|
-
|
|
17370
|
-
|
|
17371
|
-
|
|
17372
|
-
|
|
17373
|
-
/* @__PURE__ */ jsx(
|
|
17374
|
-
"div",
|
|
17375
|
-
{
|
|
17376
|
-
className: cn("absolute inset-0 bg-black/50", overlayClassName)
|
|
17377
|
-
}
|
|
17378
|
-
)
|
|
17379
|
-
]
|
|
17367
|
+
children: /* @__PURE__ */ jsx(
|
|
17368
|
+
Img,
|
|
17369
|
+
{
|
|
17370
|
+
src: currentSection?.image,
|
|
17371
|
+
alt: typeof currentSection?.title === "string" ? currentSection?.title : `Section ${currentSection?.id}`,
|
|
17372
|
+
className: cn(
|
|
17373
|
+
"h-full w-full object-cover",
|
|
17374
|
+
BRIGHTNESS_CLASS_MAP[slideMediaBrightness],
|
|
17375
|
+
currentSection?.imageClassName
|
|
17376
|
+
),
|
|
17377
|
+
optixFlowConfig
|
|
17378
|
+
}
|
|
17379
|
+
)
|
|
17380
17380
|
},
|
|
17381
17381
|
currentIndex
|
|
17382
17382
|
) }) : null,
|
|
@@ -17394,7 +17394,7 @@ function CarouselAnimatedSections({
|
|
|
17394
17394
|
animate: { opacity: 1, y: 0 },
|
|
17395
17395
|
exit: { opacity: 0, y: -40 },
|
|
17396
17396
|
transition: { duration: 0.4, delay: 0.2 },
|
|
17397
|
-
className: "max-w-2xl text-white",
|
|
17397
|
+
className: "max-w-2xl text-white text-shadow",
|
|
17398
17398
|
children: [
|
|
17399
17399
|
currentSection?.subtitle && (typeof currentSection?.subtitle === "string" ? /* @__PURE__ */ jsx(
|
|
17400
17400
|
"p",
|
|
@@ -17426,7 +17426,7 @@ function CarouselAnimatedSections({
|
|
|
17426
17426
|
children: currentSection?.description
|
|
17427
17427
|
}
|
|
17428
17428
|
) : /* @__PURE__ */ jsx("div", { className: cn("mb-8", descriptionClassName), children: currentSection?.description })),
|
|
17429
|
-
/* @__PURE__ */ jsx("div", { className: actionsClassName, children:
|
|
17429
|
+
/* @__PURE__ */ jsx("div", { className: actionsClassName, children: actionElements || currentSection?.ctaText && /* @__PURE__ */ jsxs(
|
|
17430
17430
|
Pressable,
|
|
17431
17431
|
{
|
|
17432
17432
|
href: currentSection?.ctaHref,
|
|
@@ -18137,6 +18137,11 @@ function CarouselNext({
|
|
|
18137
18137
|
}
|
|
18138
18138
|
);
|
|
18139
18139
|
}
|
|
18140
|
+
var SLIDE_LAYOUT_ASPECT_MAP = {
|
|
18141
|
+
horizontal: "aspect-video",
|
|
18142
|
+
vertical: "aspect-[9/16]",
|
|
18143
|
+
square: "aspect-square"
|
|
18144
|
+
};
|
|
18140
18145
|
function CarouselFeatureBadge({
|
|
18141
18146
|
badge,
|
|
18142
18147
|
heading,
|
|
@@ -18152,23 +18157,34 @@ function CarouselFeatureBadge({
|
|
|
18152
18157
|
carouselClassName,
|
|
18153
18158
|
carouselItemClassName,
|
|
18154
18159
|
optixFlowConfig,
|
|
18155
|
-
background
|
|
18156
|
-
spacing
|
|
18160
|
+
background,
|
|
18161
|
+
spacing,
|
|
18157
18162
|
pattern,
|
|
18158
|
-
patternOpacity
|
|
18163
|
+
patternOpacity,
|
|
18164
|
+
slideLayoutVariant = "square",
|
|
18165
|
+
containerMaxWidth = "2xl"
|
|
18159
18166
|
}) {
|
|
18160
18167
|
const renderCarouselItems = () => {
|
|
18161
18168
|
if (itemsSlot) return itemsSlot;
|
|
18162
18169
|
if (!items || items.length === 0) return null;
|
|
18163
|
-
return items.map((item, index) => /* @__PURE__ */ jsx(CarouselItem, { className: carouselItemClassName, children: /* @__PURE__ */ jsx(
|
|
18164
|
-
|
|
18170
|
+
return items.map((item, index) => /* @__PURE__ */ jsx(CarouselItem, { className: carouselItemClassName, children: /* @__PURE__ */ jsx(
|
|
18171
|
+
"div",
|
|
18165
18172
|
{
|
|
18166
|
-
|
|
18167
|
-
|
|
18168
|
-
|
|
18169
|
-
|
|
18173
|
+
className: cn(
|
|
18174
|
+
"flex items-center justify-center overflow-hidden rounded-2xl",
|
|
18175
|
+
SLIDE_LAYOUT_ASPECT_MAP[slideLayoutVariant]
|
|
18176
|
+
),
|
|
18177
|
+
children: /* @__PURE__ */ jsx(
|
|
18178
|
+
Img,
|
|
18179
|
+
{
|
|
18180
|
+
src: item.src,
|
|
18181
|
+
alt: item.alt,
|
|
18182
|
+
className: cn("h-full w-full object-cover", item.className),
|
|
18183
|
+
optixFlowConfig
|
|
18184
|
+
}
|
|
18185
|
+
)
|
|
18170
18186
|
}
|
|
18171
|
-
) }
|
|
18187
|
+
) }, index));
|
|
18172
18188
|
};
|
|
18173
18189
|
return /* @__PURE__ */ jsx(
|
|
18174
18190
|
Section,
|
|
@@ -18178,14 +18194,39 @@ function CarouselFeatureBadge({
|
|
|
18178
18194
|
className: cn(className),
|
|
18179
18195
|
pattern,
|
|
18180
18196
|
patternOpacity,
|
|
18181
|
-
|
|
18182
|
-
|
|
18183
|
-
|
|
18184
|
-
|
|
18185
|
-
|
|
18186
|
-
|
|
18187
|
-
|
|
18188
|
-
|
|
18197
|
+
containerMaxWidth,
|
|
18198
|
+
children: /* @__PURE__ */ jsx("div", { className: cn("mx-auto", containerClassName), children: /* @__PURE__ */ jsxs("div", { className: "grid grid-cols-1 items-end justify-end gap-6 md:gap-20 lg:grid-cols-2", children: [
|
|
18199
|
+
/* @__PURE__ */ jsxs(
|
|
18200
|
+
"div",
|
|
18201
|
+
{
|
|
18202
|
+
className: cn("flex flex-col items-start gap-4", contentClassName),
|
|
18203
|
+
children: [
|
|
18204
|
+
badge && /* @__PURE__ */ jsx("div", { className: badgeClassName, children: typeof badge === "string" ? /* @__PURE__ */ jsx(Badge, { children: badge }) : badge }),
|
|
18205
|
+
/* @__PURE__ */ jsxs("div", { className: "flex flex-col gap-2", children: [
|
|
18206
|
+
heading && (typeof heading === "string" ? /* @__PURE__ */ jsx(
|
|
18207
|
+
"h2",
|
|
18208
|
+
{
|
|
18209
|
+
className: cn(
|
|
18210
|
+
"text-left text-xl font-semibold md:text-3xl lg:max-w-xl lg:text-4xl",
|
|
18211
|
+
headingClassName
|
|
18212
|
+
),
|
|
18213
|
+
children: heading
|
|
18214
|
+
}
|
|
18215
|
+
) : /* @__PURE__ */ jsx("div", { className: headingClassName, children: heading })),
|
|
18216
|
+
description && (typeof description === "string" ? /* @__PURE__ */ jsx(
|
|
18217
|
+
"p",
|
|
18218
|
+
{
|
|
18219
|
+
className: cn(
|
|
18220
|
+
"max-w-xl text-left text-lg leading-snug lg:max-w-sm",
|
|
18221
|
+
descriptionClassName
|
|
18222
|
+
),
|
|
18223
|
+
children: description
|
|
18224
|
+
}
|
|
18225
|
+
) : /* @__PURE__ */ jsx("div", { className: descriptionClassName, children: description }))
|
|
18226
|
+
] })
|
|
18227
|
+
]
|
|
18228
|
+
}
|
|
18229
|
+
),
|
|
18189
18230
|
/* @__PURE__ */ jsx("div", { className: cn("w-full max-w-full px-6", carouselClassName), children: /* @__PURE__ */ jsxs(Carousel, { children: [
|
|
18190
18231
|
/* @__PURE__ */ jsx(CarouselContent, { children: renderCarouselItems() }),
|
|
18191
18232
|
/* @__PURE__ */ jsx(CarouselPrevious, {}),
|
|
@@ -18207,10 +18248,11 @@ function CarouselFullscreenScrollFx({
|
|
|
18207
18248
|
scrollIndicatorClassName,
|
|
18208
18249
|
counterClassName,
|
|
18209
18250
|
optixFlowConfig,
|
|
18210
|
-
background = "
|
|
18211
|
-
spacing = "
|
|
18212
|
-
|
|
18213
|
-
|
|
18251
|
+
background = "dark",
|
|
18252
|
+
spacing = "py-0",
|
|
18253
|
+
containerMaxWidth = "full",
|
|
18254
|
+
pattern = "diagonalCrossBasic",
|
|
18255
|
+
patternOpacity = 0.033
|
|
18214
18256
|
}) {
|
|
18215
18257
|
const containerRef = React52.useRef(null);
|
|
18216
18258
|
const [activeIndex, setActiveIndex] = React52.useState(0);
|
|
@@ -18246,27 +18288,40 @@ function CarouselFullscreenScrollFx({
|
|
|
18246
18288
|
className: cn(className),
|
|
18247
18289
|
pattern,
|
|
18248
18290
|
patternOpacity,
|
|
18291
|
+
containerMaxWidth,
|
|
18249
18292
|
children: [
|
|
18250
|
-
/* @__PURE__ */ jsx(
|
|
18251
|
-
"
|
|
18293
|
+
/* @__PURE__ */ jsx(
|
|
18294
|
+
"div",
|
|
18252
18295
|
{
|
|
18253
|
-
onClick: () => {
|
|
18254
|
-
const element = document.getElementById(`fullscreen-${slide.id}`);
|
|
18255
|
-
element?.scrollIntoView({ behavior: "smooth" });
|
|
18256
|
-
},
|
|
18257
18296
|
className: cn(
|
|
18258
|
-
"
|
|
18259
|
-
|
|
18297
|
+
"fixed right-6 top-1/2 z-50 hidden -translate-y-1/2 flex-col gap-3 lg:flex",
|
|
18298
|
+
navigationClassName
|
|
18260
18299
|
),
|
|
18261
|
-
|
|
18262
|
-
|
|
18263
|
-
|
|
18264
|
-
|
|
18300
|
+
children: slides?.map((slide, index) => /* @__PURE__ */ jsx(
|
|
18301
|
+
"button",
|
|
18302
|
+
{
|
|
18303
|
+
onClick: () => {
|
|
18304
|
+
const element = document.getElementById(`fullscreen-${slide.id}`);
|
|
18305
|
+
element?.scrollIntoView({ behavior: "smooth" });
|
|
18306
|
+
},
|
|
18307
|
+
className: cn(
|
|
18308
|
+
"h-3 w-3 rounded-full border-2 transition-all",
|
|
18309
|
+
activeIndex === index ? "scale-125 border-white bg-white" : "border-white/50 bg-transparent hover:border-white"
|
|
18310
|
+
),
|
|
18311
|
+
"aria-label": `Go to ${typeof slide.title === "string" ? slide.title : `Slide ${index + 1}`}`
|
|
18312
|
+
},
|
|
18313
|
+
slide.id
|
|
18314
|
+
))
|
|
18315
|
+
}
|
|
18316
|
+
),
|
|
18265
18317
|
slidesSlot ? slidesSlot : slides?.map((slide, index) => /* @__PURE__ */ jsxs(
|
|
18266
18318
|
"div",
|
|
18267
18319
|
{
|
|
18268
18320
|
id: `fullscreen-${slide.id}`,
|
|
18269
|
-
className: cn(
|
|
18321
|
+
className: cn(
|
|
18322
|
+
"relative flex h-screen w-full items-center justify-center overflow-hidden",
|
|
18323
|
+
slide.className
|
|
18324
|
+
),
|
|
18270
18325
|
children: [
|
|
18271
18326
|
/* @__PURE__ */ jsxs("div", { className: "absolute inset-0", children: [
|
|
18272
18327
|
/* @__PURE__ */ jsx(
|
|
@@ -18274,7 +18329,10 @@ function CarouselFullscreenScrollFx({
|
|
|
18274
18329
|
{
|
|
18275
18330
|
src: slide.image,
|
|
18276
18331
|
alt: typeof slide.title === "string" ? slide.title : `Slide ${index + 1}`,
|
|
18277
|
-
className: cn(
|
|
18332
|
+
className: cn(
|
|
18333
|
+
"h-full w-full object-cover",
|
|
18334
|
+
slide.imageClassName
|
|
18335
|
+
),
|
|
18278
18336
|
optixFlowConfig
|
|
18279
18337
|
}
|
|
18280
18338
|
),
|
|
@@ -18288,21 +18346,75 @@ function CarouselFullscreenScrollFx({
|
|
|
18288
18346
|
}
|
|
18289
18347
|
)
|
|
18290
18348
|
] }),
|
|
18291
|
-
/* @__PURE__ */ jsxs(
|
|
18292
|
-
|
|
18293
|
-
|
|
18294
|
-
|
|
18295
|
-
|
|
18296
|
-
|
|
18297
|
-
|
|
18298
|
-
|
|
18299
|
-
|
|
18300
|
-
|
|
18301
|
-
|
|
18302
|
-
|
|
18303
|
-
|
|
18304
|
-
|
|
18305
|
-
|
|
18349
|
+
/* @__PURE__ */ jsxs(
|
|
18350
|
+
"div",
|
|
18351
|
+
{
|
|
18352
|
+
className: cn(
|
|
18353
|
+
"relative z-10 mx-auto max-w-4xl px-6 text-center text-white",
|
|
18354
|
+
contentClassName
|
|
18355
|
+
),
|
|
18356
|
+
children: [
|
|
18357
|
+
slide.subtitle && (typeof slide.subtitle === "string" ? /* @__PURE__ */ jsx(
|
|
18358
|
+
"p",
|
|
18359
|
+
{
|
|
18360
|
+
className: cn(
|
|
18361
|
+
"mb-4 text-sm font-medium uppercase tracking-widest text-white/70",
|
|
18362
|
+
subtitleClassName
|
|
18363
|
+
),
|
|
18364
|
+
children: slide.subtitle
|
|
18365
|
+
}
|
|
18366
|
+
) : /* @__PURE__ */ jsx("div", { className: subtitleClassName, children: slide.subtitle })),
|
|
18367
|
+
slide.title && (typeof slide.title === "string" ? /* @__PURE__ */ jsx(
|
|
18368
|
+
"h2",
|
|
18369
|
+
{
|
|
18370
|
+
className: cn(
|
|
18371
|
+
"mb-6 text-4xl font-bold tracking-tight md:text-5xl lg:text-6xl",
|
|
18372
|
+
titleClassName
|
|
18373
|
+
),
|
|
18374
|
+
children: slide.title
|
|
18375
|
+
}
|
|
18376
|
+
) : /* @__PURE__ */ jsx("div", { className: titleClassName, children: slide.title })),
|
|
18377
|
+
slide.description && (typeof slide.description === "string" ? /* @__PURE__ */ jsx(
|
|
18378
|
+
"p",
|
|
18379
|
+
{
|
|
18380
|
+
className: cn(
|
|
18381
|
+
"mx-auto max-w-2xl text-lg text-white/80 md:text-xl",
|
|
18382
|
+
descriptionClassName
|
|
18383
|
+
),
|
|
18384
|
+
children: slide.description
|
|
18385
|
+
}
|
|
18386
|
+
) : /* @__PURE__ */ jsx("div", { className: descriptionClassName, children: slide.description })),
|
|
18387
|
+
index < (slides?.length ?? 0) - 1 && /* @__PURE__ */ jsx(
|
|
18388
|
+
"div",
|
|
18389
|
+
{
|
|
18390
|
+
className: cn(
|
|
18391
|
+
"absolute bottom-8 left-1/2 -translate-x-1/2",
|
|
18392
|
+
scrollIndicatorClassName
|
|
18393
|
+
),
|
|
18394
|
+
children: /* @__PURE__ */ jsxs("div", { className: "flex flex-col items-center gap-2", children: [
|
|
18395
|
+
/* @__PURE__ */ jsx("span", { className: "text-xs uppercase tracking-widest text-white/50", children: "Scroll" }),
|
|
18396
|
+
/* @__PURE__ */ jsx("div", { className: "h-12 w-px animate-pulse bg-gradient-to-b from-white/50 to-transparent" })
|
|
18397
|
+
] })
|
|
18398
|
+
}
|
|
18399
|
+
)
|
|
18400
|
+
]
|
|
18401
|
+
}
|
|
18402
|
+
),
|
|
18403
|
+
/* @__PURE__ */ jsxs(
|
|
18404
|
+
"div",
|
|
18405
|
+
{
|
|
18406
|
+
className: cn(
|
|
18407
|
+
"absolute bottom-8 right-8 text-sm text-white/50",
|
|
18408
|
+
counterClassName
|
|
18409
|
+
),
|
|
18410
|
+
children: [
|
|
18411
|
+
String(index + 1).padStart(2, "0"),
|
|
18412
|
+
" /",
|
|
18413
|
+
" ",
|
|
18414
|
+
String(slides?.length ?? 0).padStart(2, "0")
|
|
18415
|
+
]
|
|
18416
|
+
}
|
|
18417
|
+
)
|
|
18306
18418
|
]
|
|
18307
18419
|
},
|
|
18308
18420
|
slide.id
|
|
@@ -76788,7 +76900,7 @@ function ListSearchableGrid({
|
|
|
76788
76900
|
}
|
|
76789
76901
|
);
|
|
76790
76902
|
}
|
|
76791
|
-
var { useMemo:
|
|
76903
|
+
var { useMemo: useMemo440 } = React52;
|
|
76792
76904
|
function OfferModalNewsletterDiscount({
|
|
76793
76905
|
title,
|
|
76794
76906
|
emailPlaceholder,
|
|
@@ -76855,7 +76967,7 @@ function OfferModalNewsletterDiscount({
|
|
|
76855
76967
|
});
|
|
76856
76968
|
const formMethod = formConfig?.method?.toLowerCase() === "get" ? "get" : "post";
|
|
76857
76969
|
const dialogProps = open !== void 0 ? { open, onOpenChange } : { defaultOpen };
|
|
76858
|
-
const renderCloseButton =
|
|
76970
|
+
const renderCloseButton = useMemo440(() => {
|
|
76859
76971
|
if (closeButtonSlot) return closeButtonSlot;
|
|
76860
76972
|
if (!closeButtonText) return null;
|
|
76861
76973
|
return /* @__PURE__ */ jsx("div", { className: "absolute end-1.5 top-1.5", children: /* @__PURE__ */ jsx(DialogClose, { asChild: true, children: /* @__PURE__ */ jsx(
|
|
@@ -76869,12 +76981,12 @@ function OfferModalNewsletterDiscount({
|
|
|
76869
76981
|
}
|
|
76870
76982
|
) }) });
|
|
76871
76983
|
}, [closeButtonSlot, closeButtonText, closeClassName]);
|
|
76872
|
-
const renderHeader =
|
|
76984
|
+
const renderHeader = useMemo440(() => {
|
|
76873
76985
|
if (headerSlot) return headerSlot;
|
|
76874
76986
|
if (!title) return null;
|
|
76875
76987
|
return /* @__PURE__ */ jsx(DialogHeader, { className: headerClassName, children: typeof title === "string" ? /* @__PURE__ */ jsx(DialogTitle, { className: cn("text-start font-serif text-2xl font-normal leading-snug", titleClassName), children: title }) : /* @__PURE__ */ jsx(DialogTitle, { className: cn("text-start font-serif text-2xl font-normal leading-snug", titleClassName), children: title }) });
|
|
76876
76988
|
}, [headerSlot, title, headerClassName, titleClassName]);
|
|
76877
|
-
const renderForm =
|
|
76989
|
+
const renderForm = useMemo440(() => {
|
|
76878
76990
|
if (formSlot) return formSlot;
|
|
76879
76991
|
return /* @__PURE__ */ jsxs(
|
|
76880
76992
|
Form,
|
|
@@ -76936,7 +77048,7 @@ function OfferModalNewsletterDiscount({
|
|
|
76936
77048
|
}
|
|
76937
77049
|
) });
|
|
76938
77050
|
}
|
|
76939
|
-
var { useMemo:
|
|
77051
|
+
var { useMemo: useMemo441 } = React52;
|
|
76940
77052
|
function OfferModalMembershipImage({
|
|
76941
77053
|
overline,
|
|
76942
77054
|
title,
|
|
@@ -77012,7 +77124,7 @@ function OfferModalMembershipImage({
|
|
|
77012
77124
|
});
|
|
77013
77125
|
const formMethod = formConfig?.method?.toLowerCase() === "get" ? "get" : "post";
|
|
77014
77126
|
const dialogProps = open !== void 0 ? { open, onOpenChange } : { defaultOpen };
|
|
77015
|
-
const renderImage =
|
|
77127
|
+
const renderImage = useMemo441(() => {
|
|
77016
77128
|
if (imageSlot) return imageSlot;
|
|
77017
77129
|
if (!image) return null;
|
|
77018
77130
|
return /* @__PURE__ */ jsx("div", { className: cn("max-h-[290px] h-full overflow-hidden max-lg:hidden", imageWrapperClassName), children: /* @__PURE__ */ jsx(
|
|
@@ -77025,7 +77137,7 @@ function OfferModalMembershipImage({
|
|
|
77025
77137
|
}
|
|
77026
77138
|
) });
|
|
77027
77139
|
}, [imageSlot, image, imageWrapperClassName, imageClassName, optixFlowConfig]);
|
|
77028
|
-
const renderCloseButton =
|
|
77140
|
+
const renderCloseButton = useMemo441(() => {
|
|
77029
77141
|
if (closeButtonSlot) return closeButtonSlot;
|
|
77030
77142
|
return /* @__PURE__ */ jsx("div", { className: "absolute -end-px -top-px z-10", children: /* @__PURE__ */ jsx(DialogClose, { asChild: true, children: /* @__PURE__ */ jsx(
|
|
77031
77143
|
Pressable,
|
|
@@ -77041,7 +77153,7 @@ function OfferModalMembershipImage({
|
|
|
77041
77153
|
}
|
|
77042
77154
|
) }) });
|
|
77043
77155
|
}, [closeButtonSlot, closeClassName]);
|
|
77044
|
-
const renderForm =
|
|
77156
|
+
const renderForm = useMemo441(() => {
|
|
77045
77157
|
if (formSlot) return formSlot;
|
|
77046
77158
|
return /* @__PURE__ */ jsxs(
|
|
77047
77159
|
Form,
|
|
@@ -77104,7 +77216,7 @@ function OfferModalMembershipImage({
|
|
|
77104
77216
|
}
|
|
77105
77217
|
);
|
|
77106
77218
|
}, [formSlot, form, formConfig, formMethod, emailPlaceholder, inputClassName, submitClassName, buttonText, formClassName]);
|
|
77107
|
-
const renderFooter =
|
|
77219
|
+
const renderFooter = useMemo441(() => {
|
|
77108
77220
|
if (footerSlot) return footerSlot;
|
|
77109
77221
|
if (!description) return null;
|
|
77110
77222
|
return /* @__PURE__ */ jsx(DialogFooter, { className: footerClassName, children: /* @__PURE__ */ jsx(DialogDescription, { className: cn("text-muted-foreground text-center text-xs leading-relaxed", descriptionClassName), children: description }) });
|
|
@@ -77132,7 +77244,7 @@ function OfferModalMembershipImage({
|
|
|
77132
77244
|
}
|
|
77133
77245
|
) });
|
|
77134
77246
|
}
|
|
77135
|
-
var { useMemo:
|
|
77247
|
+
var { useMemo: useMemo442 } = React52;
|
|
77136
77248
|
function OfferModalSheetNewsletter({
|
|
77137
77249
|
logo,
|
|
77138
77250
|
logoSlot,
|
|
@@ -77214,7 +77326,7 @@ function OfferModalSheetNewsletter({
|
|
|
77214
77326
|
});
|
|
77215
77327
|
const formMethod = formConfig?.method?.toLowerCase() === "get" ? "get" : "post";
|
|
77216
77328
|
const sheetProps = open !== void 0 ? { open, onOpenChange } : { defaultOpen };
|
|
77217
|
-
const renderLogo =
|
|
77329
|
+
const renderLogo = useMemo442(() => {
|
|
77218
77330
|
if (logoSlot) return logoSlot;
|
|
77219
77331
|
if (!logo) return null;
|
|
77220
77332
|
const logoSrc = typeof logo.src === "string" ? logo.src : logo.src.light;
|
|
@@ -77228,7 +77340,7 @@ function OfferModalSheetNewsletter({
|
|
|
77228
77340
|
}
|
|
77229
77341
|
);
|
|
77230
77342
|
}, [logoSlot, logo, logoClassName, optixFlowConfig]);
|
|
77231
|
-
const renderHeader =
|
|
77343
|
+
const renderHeader = useMemo442(() => {
|
|
77232
77344
|
if (headerSlot) return headerSlot;
|
|
77233
77345
|
return /* @__PURE__ */ jsxs(SheetHeader, { className: cn("gap-8 p-0", headerClassName), children: [
|
|
77234
77346
|
renderLogo,
|
|
@@ -77238,7 +77350,7 @@ function OfferModalSheetNewsletter({
|
|
|
77238
77350
|
] })
|
|
77239
77351
|
] });
|
|
77240
77352
|
}, [headerSlot, renderLogo, headerClassName, title, titleClassName, description, descriptionClassName]);
|
|
77241
|
-
const renderForm =
|
|
77353
|
+
const renderForm = useMemo442(() => {
|
|
77242
77354
|
if (formSlot) return formSlot;
|
|
77243
77355
|
return /* @__PURE__ */ jsx(
|
|
77244
77356
|
Form,
|
|
@@ -77286,7 +77398,7 @@ function OfferModalSheetNewsletter({
|
|
|
77286
77398
|
}
|
|
77287
77399
|
);
|
|
77288
77400
|
}, [formSlot, form, formConfig, formMethod, emailPlaceholder, inputClassName, submitClassName, buttonText, formClassName]);
|
|
77289
|
-
const renderLegal =
|
|
77401
|
+
const renderLegal = useMemo442(() => {
|
|
77290
77402
|
if (legalSlot) return legalSlot;
|
|
77291
77403
|
if (!termsUrl || !termsText || !privacyUrl || !privacyText) return null;
|
|
77292
77404
|
return /* @__PURE__ */ jsxs("p", { className: cn("text-muted-foreground text-xs", legalClassName), children: [
|
|
@@ -77300,7 +77412,7 @@ function OfferModalSheetNewsletter({
|
|
|
77300
77412
|
"."
|
|
77301
77413
|
] });
|
|
77302
77414
|
}, [legalSlot, termsUrl, termsText, privacyUrl, privacyText, legalClassName]);
|
|
77303
|
-
const renderImage =
|
|
77415
|
+
const renderImage = useMemo442(() => {
|
|
77304
77416
|
if (imageSlot) return imageSlot;
|
|
77305
77417
|
if (!image) return null;
|
|
77306
77418
|
return /* @__PURE__ */ jsx("div", { className: cn("h-1/2 basis-1/2", imageWrapperClassName), children: /* @__PURE__ */ jsx(AspectRatio, { ratio: 1, className: "overflow-hidden", children: /* @__PURE__ */ jsx(
|