@opensite/ui 0.7.5 → 0.7.7
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 +10 -10
- package/dist/carousel-animated-sections.js +10 -10
- package/dist/carousel-fullscreen-scroll-fx.cjs +15 -13
- package/dist/carousel-fullscreen-scroll-fx.js +15 -13
- package/dist/carousel-multi-step-showcase.cjs +182 -105
- package/dist/carousel-multi-step-showcase.js +182 -105
- package/dist/carousel-progress-slider.cjs +38 -16
- package/dist/carousel-progress-slider.d.cts +9 -1
- package/dist/carousel-progress-slider.d.ts +9 -1
- package/dist/carousel-progress-slider.js +38 -16
- package/dist/registry.cjs +245 -144
- package/dist/registry.js +245 -144
- package/dist/utils.cjs +11 -0
- package/dist/utils.d.cts +6 -1
- package/dist/utils.d.ts +6 -1
- package/dist/utils.js +11 -1
- package/package.json +1 -1
package/dist/registry.js
CHANGED
|
@@ -38,6 +38,16 @@ import { createPortal } from 'react-dom';
|
|
|
38
38
|
function cn(...inputs) {
|
|
39
39
|
return twMerge(clsx(inputs));
|
|
40
40
|
}
|
|
41
|
+
var BRIGHTNESS_CLASS_MAP = {
|
|
42
|
+
"10": "brightness-[.1]",
|
|
43
|
+
"20": "brightness-[.2]",
|
|
44
|
+
"25": "brightness-[.25]",
|
|
45
|
+
"30": "brightness-[.3]",
|
|
46
|
+
"40": "brightness-[.4]",
|
|
47
|
+
"50": "brightness-50",
|
|
48
|
+
"75": "brightness-75",
|
|
49
|
+
"100": "brightness-100"
|
|
50
|
+
};
|
|
41
51
|
var maxWidthStyles = {
|
|
42
52
|
sm: "max-w-screen-sm",
|
|
43
53
|
md: "max-w-screen-md",
|
|
@@ -17239,16 +17249,6 @@ function ContactHelpCenter({
|
|
|
17239
17249
|
}
|
|
17240
17250
|
);
|
|
17241
17251
|
}
|
|
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
|
-
};
|
|
17252
17252
|
function CarouselAnimatedSections({
|
|
17253
17253
|
sections,
|
|
17254
17254
|
sectionsSlot,
|
|
@@ -18240,7 +18240,7 @@ function CarouselFullscreenScrollFx({
|
|
|
18240
18240
|
slides,
|
|
18241
18241
|
slidesSlot,
|
|
18242
18242
|
className,
|
|
18243
|
-
containerClassName = "h-full flex flex-col justify-center",
|
|
18243
|
+
containerClassName = "mx-auto w-full p-0 px-0 sm:px-0 lg:px-0 max-w-full relative z-10 h-full flex flex-col justify-center",
|
|
18244
18244
|
navigationClassName,
|
|
18245
18245
|
contentClassName,
|
|
18246
18246
|
subtitleClassName,
|
|
@@ -18262,9 +18262,9 @@ function CarouselFullscreenScrollFx({
|
|
|
18262
18262
|
const scrollContainer = scrollContainerRef.current;
|
|
18263
18263
|
if (!scrollContainer || !slides?.length) return;
|
|
18264
18264
|
const handleScroll = () => {
|
|
18265
|
-
const
|
|
18266
|
-
const
|
|
18267
|
-
const newIndex = Math.round(
|
|
18265
|
+
const scrollTop = scrollContainer.scrollTop;
|
|
18266
|
+
const slideHeight = scrollContainer.clientHeight;
|
|
18267
|
+
const newIndex = Math.round(scrollTop / slideHeight);
|
|
18268
18268
|
setActiveIndex(newIndex);
|
|
18269
18269
|
};
|
|
18270
18270
|
scrollContainer.addEventListener("scroll", handleScroll);
|
|
@@ -18273,14 +18273,14 @@ function CarouselFullscreenScrollFx({
|
|
|
18273
18273
|
const scrollToSlide = React52.useCallback((index) => {
|
|
18274
18274
|
const scrollContainer = scrollContainerRef.current;
|
|
18275
18275
|
if (!scrollContainer) return;
|
|
18276
|
-
const
|
|
18276
|
+
const slideHeight = scrollContainer.clientHeight;
|
|
18277
18277
|
if (typeof scrollContainer.scrollTo === "function") {
|
|
18278
18278
|
scrollContainer.scrollTo({
|
|
18279
|
-
|
|
18279
|
+
top: slideHeight * index,
|
|
18280
18280
|
behavior: "smooth"
|
|
18281
18281
|
});
|
|
18282
18282
|
} else {
|
|
18283
|
-
scrollContainer.
|
|
18283
|
+
scrollContainer.scrollTop = slideHeight * index;
|
|
18284
18284
|
}
|
|
18285
18285
|
}, []);
|
|
18286
18286
|
return /* @__PURE__ */ jsxs(
|
|
@@ -18293,7 +18293,7 @@ function CarouselFullscreenScrollFx({
|
|
|
18293
18293
|
pattern,
|
|
18294
18294
|
patternOpacity,
|
|
18295
18295
|
containerMaxWidth,
|
|
18296
|
-
containerClassName
|
|
18296
|
+
containerClassName,
|
|
18297
18297
|
children: [
|
|
18298
18298
|
/* @__PURE__ */ jsx(
|
|
18299
18299
|
"div",
|
|
@@ -18320,7 +18320,7 @@ function CarouselFullscreenScrollFx({
|
|
|
18320
18320
|
"div",
|
|
18321
18321
|
{
|
|
18322
18322
|
ref: scrollContainerRef,
|
|
18323
|
-
className: "flex h-screen snap-
|
|
18323
|
+
className: "flex h-screen flex-col snap-y snap-mandatory overflow-x-hidden overflow-y-auto scroll-smooth",
|
|
18324
18324
|
style: { scrollbarWidth: "none", msOverflowStyle: "none" },
|
|
18325
18325
|
children: slidesSlot ? slidesSlot : slides?.map((slide, index) => {
|
|
18326
18326
|
const renderActions = React52.useMemo(() => {
|
|
@@ -18356,7 +18356,7 @@ function CarouselFullscreenScrollFx({
|
|
|
18356
18356
|
{
|
|
18357
18357
|
id: `fullscreen-${slide.id}`,
|
|
18358
18358
|
className: cn(
|
|
18359
|
-
"relative flex h-screen min-w-full snap-start items-center justify-center overflow-hidden",
|
|
18359
|
+
"relative flex h-screen min-h-screen w-full snap-start items-center justify-center overflow-hidden",
|
|
18360
18360
|
slide.className
|
|
18361
18361
|
),
|
|
18362
18362
|
children: [
|
|
@@ -18387,7 +18387,7 @@ function CarouselFullscreenScrollFx({
|
|
|
18387
18387
|
"div",
|
|
18388
18388
|
{
|
|
18389
18389
|
className: cn(
|
|
18390
|
-
"relative z-10 mx-auto max-w-4xl md:max-w-
|
|
18390
|
+
"relative z-10 mx-auto max-w-4xl md:max-w-xl px-6 text-center text-shadow",
|
|
18391
18391
|
contentClassName
|
|
18392
18392
|
),
|
|
18393
18393
|
children: [
|
|
@@ -18426,12 +18426,14 @@ function CarouselFullscreenScrollFx({
|
|
|
18426
18426
|
}
|
|
18427
18427
|
),
|
|
18428
18428
|
index < (slides?.length ?? 0) - 1 && /* @__PURE__ */ jsx(
|
|
18429
|
-
"
|
|
18429
|
+
"button",
|
|
18430
18430
|
{
|
|
18431
|
+
onClick: () => scrollToSlide(index + 1),
|
|
18431
18432
|
className: cn(
|
|
18432
|
-
"absolute bottom-8 left-1/2 -translate-x-1/2",
|
|
18433
|
+
"absolute bottom-8 left-1/2 -translate-x-1/2 cursor-pointer transition-opacity hover:opacity-80 focus:outline-none focus-visible:ring-2 focus-visible:ring-white/50 focus-visible:ring-offset-2 focus-visible:ring-offset-black rounded-lg p-2",
|
|
18433
18434
|
scrollIndicatorClassName
|
|
18434
18435
|
),
|
|
18436
|
+
"aria-label": "Scroll to next slide",
|
|
18435
18437
|
children: /* @__PURE__ */ jsxs("div", { className: "flex flex-col items-center gap-2", children: [
|
|
18436
18438
|
/* @__PURE__ */ jsx("span", { className: "text-xs uppercase tracking-widest text-white/50", children: "Scroll" }),
|
|
18437
18439
|
/* @__PURE__ */ jsx("div", { className: "h-12 w-px animate-pulse bg-linear-to-b from-white/50 to-transparent" })
|
|
@@ -18923,7 +18925,14 @@ function CarouselMultiStepShowcase({
|
|
|
18923
18925
|
if (actionsSlot) return actionsSlot;
|
|
18924
18926
|
if (!actions || actions.length === 0) return null;
|
|
18925
18927
|
return actions.map((action, index) => {
|
|
18926
|
-
const {
|
|
18928
|
+
const {
|
|
18929
|
+
label,
|
|
18930
|
+
icon,
|
|
18931
|
+
iconAfter,
|
|
18932
|
+
children,
|
|
18933
|
+
className: actionClassName,
|
|
18934
|
+
...pressableProps
|
|
18935
|
+
} = action;
|
|
18927
18936
|
return /* @__PURE__ */ jsx(
|
|
18928
18937
|
Pressable,
|
|
18929
18938
|
{
|
|
@@ -18933,7 +18942,14 @@ function CarouselMultiStepShowcase({
|
|
|
18933
18942
|
children: children ?? /* @__PURE__ */ jsxs(Fragment$1, { children: [
|
|
18934
18943
|
icon,
|
|
18935
18944
|
label,
|
|
18936
|
-
iconAfter ?? /* @__PURE__ */ jsx(
|
|
18945
|
+
iconAfter ?? /* @__PURE__ */ jsx(
|
|
18946
|
+
DynamicIcon,
|
|
18947
|
+
{
|
|
18948
|
+
name: "lucide/arrow-right",
|
|
18949
|
+
size: 16,
|
|
18950
|
+
className: "ml-2"
|
|
18951
|
+
}
|
|
18952
|
+
)
|
|
18937
18953
|
] })
|
|
18938
18954
|
},
|
|
18939
18955
|
index
|
|
@@ -18967,124 +18983,187 @@ function CarouselMultiStepShowcase({
|
|
|
18967
18983
|
patternOpacity,
|
|
18968
18984
|
children: /* @__PURE__ */ jsxs("div", { className: cn("container mx-auto px-4", containerClassName), children: [
|
|
18969
18985
|
/* @__PURE__ */ jsxs("div", { className: cn("mb-12 text-center", headerClassName), children: [
|
|
18970
|
-
heading && (typeof heading === "string" ? /* @__PURE__ */ jsx(
|
|
18971
|
-
|
|
18986
|
+
heading && (typeof heading === "string" ? /* @__PURE__ */ jsx(
|
|
18987
|
+
"h2",
|
|
18988
|
+
{
|
|
18989
|
+
className: cn(
|
|
18990
|
+
"text-3xl font-bold tracking-tight md:text-4xl lg:text-5xl",
|
|
18991
|
+
headingClassName
|
|
18992
|
+
),
|
|
18993
|
+
children: heading
|
|
18994
|
+
}
|
|
18995
|
+
) : /* @__PURE__ */ jsx("div", { className: headingClassName, children: heading })),
|
|
18996
|
+
subheading && (typeof subheading === "string" ? /* @__PURE__ */ jsx(
|
|
18997
|
+
"p",
|
|
18998
|
+
{
|
|
18999
|
+
className: cn(
|
|
19000
|
+
"mt-4 text-lg text-muted-foreground",
|
|
19001
|
+
subheadingClassName
|
|
19002
|
+
),
|
|
19003
|
+
children: subheading
|
|
19004
|
+
}
|
|
19005
|
+
) : /* @__PURE__ */ jsx("div", { className: subheadingClassName, children: subheading }))
|
|
18972
19006
|
] }),
|
|
18973
|
-
stepsSlot ? /* @__PURE__ */ jsx("div", { className: stepNavigationClassName, children: stepsSlot }) : /* @__PURE__ */ jsx(
|
|
18974
|
-
"
|
|
19007
|
+
stepsSlot ? /* @__PURE__ */ jsx("div", { className: stepNavigationClassName, children: stepsSlot }) : /* @__PURE__ */ jsx(
|
|
19008
|
+
"div",
|
|
18975
19009
|
{
|
|
18976
|
-
onClick: () => goToStep(index),
|
|
18977
19010
|
className: cn(
|
|
18978
|
-
"
|
|
18979
|
-
|
|
18980
|
-
|
|
19011
|
+
"mb-8 flex flex-wrap justify-center gap-2",
|
|
19012
|
+
stepNavigationClassName
|
|
19013
|
+
),
|
|
19014
|
+
children: steps?.map((step, index) => /* @__PURE__ */ jsxs(
|
|
19015
|
+
"button",
|
|
19016
|
+
{
|
|
19017
|
+
onClick: () => goToStep(index),
|
|
19018
|
+
className: cn(
|
|
19019
|
+
"flex items-center gap-2 rounded-full px-4 py-2 text-sm font-medium transition-all",
|
|
19020
|
+
activeStep === index ? "bg-primary text-primary-foreground" : "bg-muted text-muted-foreground hover:bg-muted/80",
|
|
19021
|
+
step.className
|
|
19022
|
+
),
|
|
19023
|
+
children: [
|
|
19024
|
+
/* @__PURE__ */ jsx(
|
|
19025
|
+
"span",
|
|
19026
|
+
{
|
|
19027
|
+
className: cn(
|
|
19028
|
+
"flex h-6 w-6 items-center justify-center rounded-full text-xs",
|
|
19029
|
+
activeStep === index ? "bg-primary-foreground text-primary" : "bg-background"
|
|
19030
|
+
),
|
|
19031
|
+
children: step.step
|
|
19032
|
+
}
|
|
19033
|
+
),
|
|
19034
|
+
/* @__PURE__ */ jsx("span", { className: "hidden sm:inline", children: typeof step.title === "string" ? step.title.split(":")[0] : step.title })
|
|
19035
|
+
]
|
|
19036
|
+
},
|
|
19037
|
+
step.id
|
|
19038
|
+
))
|
|
19039
|
+
}
|
|
19040
|
+
),
|
|
19041
|
+
/* @__PURE__ */ jsx(
|
|
19042
|
+
"div",
|
|
19043
|
+
{
|
|
19044
|
+
className: cn(
|
|
19045
|
+
"mx-auto mb-12 h-1 max-w-2xl overflow-hidden rounded-full bg-muted",
|
|
19046
|
+
progressClassName
|
|
19047
|
+
),
|
|
19048
|
+
children: /* @__PURE__ */ jsx(
|
|
19049
|
+
motion.div,
|
|
19050
|
+
{
|
|
19051
|
+
className: "h-full bg-primary",
|
|
19052
|
+
initial: { width: 0 },
|
|
19053
|
+
animate: {
|
|
19054
|
+
width: `${(activeStep + 1) / (steps?.length ?? 1) * 100}%`
|
|
19055
|
+
},
|
|
19056
|
+
transition: { duration: 0.3 }
|
|
19057
|
+
}
|
|
19058
|
+
)
|
|
19059
|
+
}
|
|
19060
|
+
),
|
|
19061
|
+
/* @__PURE__ */ jsxs(
|
|
19062
|
+
"div",
|
|
19063
|
+
{
|
|
19064
|
+
className: cn(
|
|
19065
|
+
"grid gap-8 lg:grid-cols-2 lg:gap-12",
|
|
19066
|
+
contentClassName
|
|
18981
19067
|
),
|
|
18982
19068
|
children: [
|
|
18983
19069
|
/* @__PURE__ */ jsx(
|
|
18984
|
-
"
|
|
19070
|
+
"div",
|
|
18985
19071
|
{
|
|
18986
19072
|
className: cn(
|
|
18987
|
-
"
|
|
18988
|
-
|
|
19073
|
+
"relative aspect-video overflow-hidden rounded-xl bg-muted",
|
|
19074
|
+
imageClassName
|
|
18989
19075
|
),
|
|
18990
|
-
children:
|
|
19076
|
+
children: /* @__PURE__ */ jsx(AnimatePresence, { initial: false, custom: direction, mode: "wait", children: /* @__PURE__ */ jsx(
|
|
19077
|
+
motion.div,
|
|
19078
|
+
{
|
|
19079
|
+
custom: direction,
|
|
19080
|
+
variants: slideVariants2,
|
|
19081
|
+
initial: "enter",
|
|
19082
|
+
animate: "center",
|
|
19083
|
+
exit: "exit",
|
|
19084
|
+
transition: { duration: 0.3, ease: "easeInOut" },
|
|
19085
|
+
className: cn(
|
|
19086
|
+
"absolute inset-0",
|
|
19087
|
+
steps?.[activeStep]?.imageClassName
|
|
19088
|
+
),
|
|
19089
|
+
children: /* @__PURE__ */ jsx(
|
|
19090
|
+
Img,
|
|
19091
|
+
{
|
|
19092
|
+
src: steps?.[activeStep]?.image,
|
|
19093
|
+
alt: typeof steps?.[activeStep]?.title === "string" ? steps[activeStep].title : `Step ${activeStep + 1}`,
|
|
19094
|
+
className: "h-full w-full object-cover",
|
|
19095
|
+
optixFlowConfig
|
|
19096
|
+
}
|
|
19097
|
+
)
|
|
19098
|
+
},
|
|
19099
|
+
activeStep
|
|
19100
|
+
) })
|
|
18991
19101
|
}
|
|
18992
19102
|
),
|
|
18993
|
-
/* @__PURE__ */ jsx("
|
|
18994
|
-
|
|
18995
|
-
},
|
|
18996
|
-
step.id
|
|
18997
|
-
)) }),
|
|
18998
|
-
/* @__PURE__ */ jsx("div", { className: cn("mx-auto mb-12 h-1 max-w-2xl overflow-hidden rounded-full bg-muted", progressClassName), children: /* @__PURE__ */ jsx(
|
|
18999
|
-
motion.div,
|
|
19000
|
-
{
|
|
19001
|
-
className: "h-full bg-primary",
|
|
19002
|
-
initial: { width: 0 },
|
|
19003
|
-
animate: {
|
|
19004
|
-
width: `${(activeStep + 1) / (steps?.length ?? 1) * 100}%`
|
|
19005
|
-
},
|
|
19006
|
-
transition: { duration: 0.3 }
|
|
19007
|
-
}
|
|
19008
|
-
) }),
|
|
19009
|
-
/* @__PURE__ */ jsxs("div", { className: cn("grid gap-8 lg:grid-cols-2 lg:gap-12", contentClassName), children: [
|
|
19010
|
-
/* @__PURE__ */ jsx("div", { className: cn("relative aspect-video overflow-hidden rounded-xl bg-muted", imageClassName), children: /* @__PURE__ */ jsx(AnimatePresence, { initial: false, custom: direction, mode: "wait", children: /* @__PURE__ */ jsx(
|
|
19011
|
-
motion.div,
|
|
19012
|
-
{
|
|
19013
|
-
custom: direction,
|
|
19014
|
-
variants: slideVariants2,
|
|
19015
|
-
initial: "enter",
|
|
19016
|
-
animate: "center",
|
|
19017
|
-
exit: "exit",
|
|
19018
|
-
transition: { duration: 0.3, ease: "easeInOut" },
|
|
19019
|
-
className: cn("absolute inset-0", steps?.[activeStep]?.imageClassName),
|
|
19020
|
-
children: /* @__PURE__ */ jsx(
|
|
19021
|
-
Img,
|
|
19103
|
+
/* @__PURE__ */ jsx("div", { className: "flex flex-col justify-center", children: /* @__PURE__ */ jsx(AnimatePresence, { mode: "wait", children: /* @__PURE__ */ jsxs(
|
|
19104
|
+
motion.div,
|
|
19022
19105
|
{
|
|
19023
|
-
|
|
19024
|
-
|
|
19025
|
-
|
|
19026
|
-
|
|
19027
|
-
|
|
19028
|
-
|
|
19029
|
-
|
|
19030
|
-
|
|
19031
|
-
|
|
19032
|
-
|
|
19033
|
-
|
|
19034
|
-
|
|
19035
|
-
|
|
19036
|
-
|
|
19037
|
-
|
|
19038
|
-
|
|
19039
|
-
children: [
|
|
19040
|
-
/* @__PURE__ */ jsxs("div", { className: "mb-4 inline-flex items-center gap-2 rounded-full bg-primary/10 px-3 py-1 text-sm font-medium text-primary", children: [
|
|
19041
|
-
/* @__PURE__ */ jsx(DynamicIcon, { name: "lucide/check-circle", size: 16 }),
|
|
19042
|
-
"Step ",
|
|
19043
|
-
steps?.[activeStep]?.step,
|
|
19044
|
-
" of ",
|
|
19045
|
-
steps?.length ?? 0
|
|
19046
|
-
] }),
|
|
19047
|
-
steps?.[activeStep]?.title && (typeof steps[activeStep].title === "string" ? /* @__PURE__ */ jsx("h3", { className: "text-2xl font-semibold md:text-3xl", children: steps[activeStep].title }) : /* @__PURE__ */ jsx("div", { children: steps[activeStep].title })),
|
|
19048
|
-
steps?.[activeStep]?.description && (typeof steps[activeStep].description === "string" ? /* @__PURE__ */ jsx("p", { className: "mt-4 text-lg text-muted-foreground", children: steps[activeStep].description }) : /* @__PURE__ */ jsx("div", { className: "mt-4", children: steps[activeStep].description })),
|
|
19049
|
-
/* @__PURE__ */ jsxs("div", { className: cn("mt-8 flex gap-4", actionsClassName), children: [
|
|
19050
|
-
/* @__PURE__ */ jsxs(
|
|
19051
|
-
Pressable,
|
|
19052
|
-
{
|
|
19053
|
-
onClick: goToPrev,
|
|
19054
|
-
asButton: true,
|
|
19055
|
-
variant: "outline",
|
|
19056
|
-
disabled: activeStep === 0,
|
|
19057
|
-
className: "disabled:opacity-50",
|
|
19058
|
-
children: [
|
|
19059
|
-
/* @__PURE__ */ jsx(
|
|
19060
|
-
DynamicIcon,
|
|
19061
|
-
{
|
|
19062
|
-
name: "lucide/arrow-left",
|
|
19063
|
-
size: 16,
|
|
19064
|
-
className: "mr-2"
|
|
19065
|
-
}
|
|
19066
|
-
),
|
|
19067
|
-
"Previous"
|
|
19068
|
-
]
|
|
19069
|
-
}
|
|
19070
|
-
),
|
|
19071
|
-
activeStep < (steps?.length ?? 0) - 1 ? /* @__PURE__ */ jsxs(Pressable, { onClick: goToNext, asButton: true, children: [
|
|
19072
|
-
"Next",
|
|
19073
|
-
/* @__PURE__ */ jsx(
|
|
19074
|
-
DynamicIcon,
|
|
19106
|
+
initial: { opacity: 0, y: 20 },
|
|
19107
|
+
animate: { opacity: 1, y: 0 },
|
|
19108
|
+
exit: { opacity: 0, y: -20 },
|
|
19109
|
+
transition: { duration: 0.3 },
|
|
19110
|
+
children: [
|
|
19111
|
+
/* @__PURE__ */ jsxs("div", { className: "mb-4 inline-flex items-center gap-2 rounded-full bg-primary/10 px-3 py-1 text-sm font-medium text-primary", children: [
|
|
19112
|
+
/* @__PURE__ */ jsx(DynamicIcon, { name: "lucide/check-circle", size: 16 }),
|
|
19113
|
+
"Step ",
|
|
19114
|
+
steps?.[activeStep]?.step,
|
|
19115
|
+
" of ",
|
|
19116
|
+
steps?.length ?? 0
|
|
19117
|
+
] }),
|
|
19118
|
+
steps?.[activeStep]?.title && (typeof steps[activeStep].title === "string" ? /* @__PURE__ */ jsx("h3", { className: "text-2xl font-semibold md:text-3xl", children: steps[activeStep].title }) : /* @__PURE__ */ jsx("div", { children: steps[activeStep].title })),
|
|
19119
|
+
steps?.[activeStep]?.description && (typeof steps[activeStep].description === "string" ? /* @__PURE__ */ jsx("p", { className: "mt-4 text-lg text-muted-foreground", children: steps[activeStep].description }) : /* @__PURE__ */ jsx("div", { className: "mt-4", children: steps[activeStep].description })),
|
|
19120
|
+
/* @__PURE__ */ jsxs(
|
|
19121
|
+
"div",
|
|
19075
19122
|
{
|
|
19076
|
-
|
|
19077
|
-
|
|
19078
|
-
|
|
19123
|
+
className: cn("mt-8 flex gap-3 flex-wrap", actionsClassName),
|
|
19124
|
+
children: [
|
|
19125
|
+
/* @__PURE__ */ jsxs(
|
|
19126
|
+
Pressable,
|
|
19127
|
+
{
|
|
19128
|
+
onClick: goToPrev,
|
|
19129
|
+
asButton: true,
|
|
19130
|
+
variant: "outline",
|
|
19131
|
+
disabled: activeStep === 0,
|
|
19132
|
+
className: "disabled:opacity-50",
|
|
19133
|
+
children: [
|
|
19134
|
+
/* @__PURE__ */ jsx(
|
|
19135
|
+
DynamicIcon,
|
|
19136
|
+
{
|
|
19137
|
+
name: "lucide/arrow-left",
|
|
19138
|
+
size: 16,
|
|
19139
|
+
className: "mr-2"
|
|
19140
|
+
}
|
|
19141
|
+
),
|
|
19142
|
+
"Previous"
|
|
19143
|
+
]
|
|
19144
|
+
}
|
|
19145
|
+
),
|
|
19146
|
+
activeStep < (steps?.length ?? 0) - 1 ? /* @__PURE__ */ jsxs(Pressable, { onClick: goToNext, asButton: true, children: [
|
|
19147
|
+
"Next",
|
|
19148
|
+
/* @__PURE__ */ jsx(
|
|
19149
|
+
DynamicIcon,
|
|
19150
|
+
{
|
|
19151
|
+
name: "lucide/arrow-right",
|
|
19152
|
+
size: 16,
|
|
19153
|
+
className: "ml-2"
|
|
19154
|
+
}
|
|
19155
|
+
)
|
|
19156
|
+
] }) : (actionsSlot || actions && actions.length > 0) && renderActions()
|
|
19157
|
+
]
|
|
19079
19158
|
}
|
|
19080
19159
|
)
|
|
19081
|
-
]
|
|
19082
|
-
|
|
19083
|
-
|
|
19084
|
-
|
|
19085
|
-
|
|
19086
|
-
|
|
19087
|
-
|
|
19160
|
+
]
|
|
19161
|
+
},
|
|
19162
|
+
activeStep
|
|
19163
|
+
) }) })
|
|
19164
|
+
]
|
|
19165
|
+
}
|
|
19166
|
+
)
|
|
19088
19167
|
] })
|
|
19089
19168
|
}
|
|
19090
19169
|
);
|
|
@@ -19474,6 +19553,8 @@ function SliderWrapper({ children, value, className }) {
|
|
|
19474
19553
|
) });
|
|
19475
19554
|
}
|
|
19476
19555
|
function CarouselProgressSlider({
|
|
19556
|
+
heading,
|
|
19557
|
+
subheading,
|
|
19477
19558
|
slides,
|
|
19478
19559
|
slidesSlot,
|
|
19479
19560
|
duration = 5e3,
|
|
@@ -19487,8 +19568,8 @@ function CarouselProgressSlider({
|
|
|
19487
19568
|
buttonClassName,
|
|
19488
19569
|
progressBarClassName,
|
|
19489
19570
|
optixFlowConfig,
|
|
19490
|
-
background
|
|
19491
|
-
spacing
|
|
19571
|
+
background,
|
|
19572
|
+
spacing,
|
|
19492
19573
|
pattern,
|
|
19493
19574
|
patternOpacity
|
|
19494
19575
|
}) {
|
|
@@ -19554,12 +19635,14 @@ function CarouselProgressSlider({
|
|
|
19554
19635
|
children: /* @__PURE__ */ jsx(
|
|
19555
19636
|
Section,
|
|
19556
19637
|
{
|
|
19638
|
+
title: heading,
|
|
19639
|
+
subtitle: subheading,
|
|
19557
19640
|
background,
|
|
19558
19641
|
spacing,
|
|
19559
19642
|
className: cn(className),
|
|
19560
19643
|
pattern,
|
|
19561
19644
|
patternOpacity,
|
|
19562
|
-
children: /* @__PURE__ */ jsx("div", { className: cn("
|
|
19645
|
+
children: /* @__PURE__ */ jsx("div", { className: cn("relative", containerClassName), children: /* @__PURE__ */ jsxs("div", { className: cn("grid gap-8 lg:grid-cols-2", contentClassName), children: [
|
|
19563
19646
|
/* @__PURE__ */ jsx("div", { className: cn("relative min-h-[300px]", imageClassName), children: slidesSlot ? slidesSlot : slides?.map((slide) => /* @__PURE__ */ jsx(
|
|
19564
19647
|
SliderWrapper,
|
|
19565
19648
|
{
|
|
@@ -19570,26 +19653,44 @@ function CarouselProgressSlider({
|
|
|
19570
19653
|
{
|
|
19571
19654
|
src: slide.image,
|
|
19572
19655
|
alt: typeof slide.title === "string" ? slide.title : `Slide ${slide.id}`,
|
|
19573
|
-
className: cn(
|
|
19656
|
+
className: cn(
|
|
19657
|
+
"h-full w-full object-cover",
|
|
19658
|
+
slide.imageClassName
|
|
19659
|
+
),
|
|
19574
19660
|
optixFlowConfig
|
|
19575
19661
|
}
|
|
19576
19662
|
) })
|
|
19577
19663
|
},
|
|
19578
19664
|
slide.id
|
|
19579
19665
|
)) }),
|
|
19580
|
-
/* @__PURE__ */ jsx(
|
|
19581
|
-
|
|
19666
|
+
/* @__PURE__ */ jsx(
|
|
19667
|
+
"div",
|
|
19582
19668
|
{
|
|
19583
|
-
|
|
19584
|
-
|
|
19585
|
-
|
|
19586
|
-
|
|
19587
|
-
|
|
19588
|
-
|
|
19589
|
-
|
|
19590
|
-
|
|
19591
|
-
|
|
19592
|
-
|
|
19669
|
+
className: cn(
|
|
19670
|
+
"flex flex-col justify-center gap-4",
|
|
19671
|
+
navigationClassName
|
|
19672
|
+
),
|
|
19673
|
+
children: slides?.map((slide) => /* @__PURE__ */ jsxs(
|
|
19674
|
+
SliderBtn,
|
|
19675
|
+
{
|
|
19676
|
+
value: slide.id,
|
|
19677
|
+
className: cn(
|
|
19678
|
+
"rounded-lg border p-4 text-left transition-colors hover:bg-muted",
|
|
19679
|
+
buttonClassName
|
|
19680
|
+
),
|
|
19681
|
+
progressBarClass: cn(
|
|
19682
|
+
"bottom-0 h-1 bg-primary",
|
|
19683
|
+
progressBarClassName
|
|
19684
|
+
),
|
|
19685
|
+
children: [
|
|
19686
|
+
slide.title && (typeof slide.title === "string" ? /* @__PURE__ */ jsx("h3", { className: "text-lg font-semibold", children: slide.title }) : /* @__PURE__ */ jsx("div", { children: slide.title })),
|
|
19687
|
+
slide.description && (typeof slide.description === "string" ? /* @__PURE__ */ jsx("p", { className: "mt-1 text-sm text-muted-foreground", children: slide.description }) : /* @__PURE__ */ jsx("div", { className: "mt-1", children: slide.description }))
|
|
19688
|
+
]
|
|
19689
|
+
},
|
|
19690
|
+
slide.id
|
|
19691
|
+
))
|
|
19692
|
+
}
|
|
19693
|
+
)
|
|
19593
19694
|
] }) })
|
|
19594
19695
|
}
|
|
19595
19696
|
)
|
package/dist/utils.cjs
CHANGED
|
@@ -7,5 +7,16 @@ var tailwindMerge = require('tailwind-merge');
|
|
|
7
7
|
function cn(...inputs) {
|
|
8
8
|
return tailwindMerge.twMerge(clsx.clsx(inputs));
|
|
9
9
|
}
|
|
10
|
+
var BRIGHTNESS_CLASS_MAP = {
|
|
11
|
+
"10": "brightness-[.1]",
|
|
12
|
+
"20": "brightness-[.2]",
|
|
13
|
+
"25": "brightness-[.25]",
|
|
14
|
+
"30": "brightness-[.3]",
|
|
15
|
+
"40": "brightness-[.4]",
|
|
16
|
+
"50": "brightness-50",
|
|
17
|
+
"75": "brightness-75",
|
|
18
|
+
"100": "brightness-100"
|
|
19
|
+
};
|
|
10
20
|
|
|
21
|
+
exports.BRIGHTNESS_CLASS_MAP = BRIGHTNESS_CLASS_MAP;
|
|
11
22
|
exports.cn = cn;
|
package/dist/utils.d.cts
CHANGED
|
@@ -1,5 +1,10 @@
|
|
|
1
1
|
import { ClassValue } from 'clsx';
|
|
2
2
|
|
|
3
3
|
declare function cn(...inputs: ClassValue[]): string;
|
|
4
|
+
/**
|
|
5
|
+
* Maps brightness prop values to Tailwind classes
|
|
6
|
+
* Values 10-40 use arbitrary values for finer control on bright images
|
|
7
|
+
*/
|
|
8
|
+
declare const BRIGHTNESS_CLASS_MAP: Record<string, string>;
|
|
4
9
|
|
|
5
|
-
export { cn };
|
|
10
|
+
export { BRIGHTNESS_CLASS_MAP, cn };
|
package/dist/utils.d.ts
CHANGED
|
@@ -1,5 +1,10 @@
|
|
|
1
1
|
import { ClassValue } from 'clsx';
|
|
2
2
|
|
|
3
3
|
declare function cn(...inputs: ClassValue[]): string;
|
|
4
|
+
/**
|
|
5
|
+
* Maps brightness prop values to Tailwind classes
|
|
6
|
+
* Values 10-40 use arbitrary values for finer control on bright images
|
|
7
|
+
*/
|
|
8
|
+
declare const BRIGHTNESS_CLASS_MAP: Record<string, string>;
|
|
4
9
|
|
|
5
|
-
export { cn };
|
|
10
|
+
export { BRIGHTNESS_CLASS_MAP, cn };
|
package/dist/utils.js
CHANGED
|
@@ -5,5 +5,15 @@ import { twMerge } from 'tailwind-merge';
|
|
|
5
5
|
function cn(...inputs) {
|
|
6
6
|
return twMerge(clsx(inputs));
|
|
7
7
|
}
|
|
8
|
+
var BRIGHTNESS_CLASS_MAP = {
|
|
9
|
+
"10": "brightness-[.1]",
|
|
10
|
+
"20": "brightness-[.2]",
|
|
11
|
+
"25": "brightness-[.25]",
|
|
12
|
+
"30": "brightness-[.3]",
|
|
13
|
+
"40": "brightness-[.4]",
|
|
14
|
+
"50": "brightness-50",
|
|
15
|
+
"75": "brightness-75",
|
|
16
|
+
"100": "brightness-100"
|
|
17
|
+
};
|
|
8
18
|
|
|
9
|
-
export { cn };
|
|
19
|
+
export { BRIGHTNESS_CLASS_MAP, cn };
|