diff --git a/src/components/sections/hero/HeroBillboardGallery.tsx b/src/components/sections/hero/HeroBillboardGallery.tsx index 08a4a0c..83075b7 100644 --- a/src/components/sections/hero/HeroBillboardGallery.tsx +++ b/src/components/sections/hero/HeroBillboardGallery.tsx @@ -1,33 +1,200 @@ -import React from "react"; +"use client"; + +import TextBox from "@/components/Textbox"; +import MediaContent from "@/components/shared/MediaContent"; import AutoCarousel from "@/components/cardStack/layouts/carousels/AutoCarousel"; +import HeroBackgrounds, { type HeroBackgroundVariantProps } from "@/components/background/HeroBackgrounds"; +import { cls } from "@/lib/utils"; +import { useButtonAnimation } from "@/components/hooks/useButtonAnimation"; +import type { LucideIcon } from "lucide-react"; +import type { ButtonConfig, ButtonAnimationType } from "@/types/button"; + +export interface MediaItem { + imageSrc?: string; + videoSrc?: string; + imageAlt?: string; + videoAriaLabel?: string; +} + +type HeroBillboardGalleryBackgroundProps = Extract< + HeroBackgroundVariantProps, + | { variant: "plain" } + | { variant: "animated-grid" } + | { variant: "canvas-reveal" } + | { variant: "cell-wave" } + | { variant: "downward-rays-animated" } + | { variant: "downward-rays-animated-grid" } + | { variant: "downward-rays-static" } + | { variant: "downward-rays-static-grid" } + | { variant: "gradient-bars" } + | { variant: "radial-gradient" } + | { variant: "rotated-rays-animated" } + | { variant: "rotated-rays-animated-grid" } + | { variant: "rotated-rays-static" } + | { variant: "rotated-rays-static-grid" } + | { variant: "sparkles-gradient" } +>; interface HeroBillboardGalleryProps { - title?: string; - description?: string; - textboxLayout?: string; - animationType?: string; - className?: string; - carouselClassName?: string; - containerClassName?: string; - itemClassName?: string; + title: string; + description: string; + background: HeroBillboardGalleryBackgroundProps; + tag?: string; + tagIcon?: LucideIcon; + tagAnimation?: ButtonAnimationType; + buttons?: ButtonConfig[]; + buttonAnimation?: ButtonAnimationType; + mediaItems: MediaItem[]; + mediaAnimation: ButtonAnimationType; ariaLabel?: string; - mediaItems?: Array<{ imageSrc?: string; videoSrc?: string; imageAlt?: string }>; + className?: string; + containerClassName?: string; + textBoxClassName?: string; + titleClassName?: string; + descriptionClassName?: string; + tagClassName?: string; + buttonContainerClassName?: string; + buttonClassName?: string; + buttonTextClassName?: string; + mediaWrapperClassName?: string; + imageClassName?: string; } -export default function HeroBillboardGallery({ - title = "Gallery", description = "Welcome", textboxLayout = "default", animationType = "slide-up", className = "", carouselClassName = "", containerClassName = "", itemClassName = "", ariaLabel = "Gallery section", mediaItems = [], -}: HeroBillboardGalleryProps) { - const items = mediaItems.map((item) => ({ - imageSrc: item.imageSrc, - videoSrc: item.videoSrc, - imageAlt: item.imageAlt, - })); +const HeroBillboardGallery = ({ + title, + description, + background, + tag, + tagIcon, + tagAnimation, + buttons, + buttonAnimation, + mediaItems, + mediaAnimation, + ariaLabel = "Hero section", + className = "", + containerClassName = "", + textBoxClassName = "", + titleClassName = "", + descriptionClassName = "", + tagClassName = "", + buttonContainerClassName = "", + buttonClassName = "", + buttonTextClassName = "", + mediaWrapperClassName = "", + imageClassName = "", +}: HeroBillboardGalleryProps) => { + const { containerRef: mediaContainerRef } = useButtonAnimation({ animationType: mediaAnimation }); - return ( -
{description}
-