"use client"; import MediaContent from "@/components/shared/MediaContent"; import Tag from "@/components/shared/Tag"; import TextAnimation from "@/components/text/TextAnimation"; import { cls } from "@/lib/utils"; import { useTheme } from "@/providers/themeProvider/ThemeProvider"; import { useButtonAnimation } from "@/components/hooks/useButtonAnimation"; import type { LucideIcon } from "lucide-react"; import type { InvertedBackground } from "@/providers/themeProvider/config/constants"; import type { ButtonAnimationType } from "@/types/button"; import type { AnimationType } from "@/components/text/types"; type MediaProps = | { imageSrc: string; imageAlt?: string; videoSrc?: never; videoAriaLabel?: never; } | { videoSrc: string; videoAriaLabel?: string; imageSrc?: never; imageAlt?: never; }; type TestimonialAboutCardProps = MediaProps & { tag: string; tagIcon?: LucideIcon; tagAnimation?: ButtonAnimationType; title: string; description: string; subdescription: string; icon: LucideIcon; mediaAnimation: ButtonAnimationType; useInvertedBackground: InvertedBackground; ariaLabel?: string; className?: string; containerClassName?: string; cardClassName?: string; contentClassName?: string; tagClassName?: string; titleClassName?: string; descriptionClassName?: string; subdescriptionClassName?: string; footerClassName?: string; iconBoxClassName?: string; iconClassName?: string; mediaWrapperClassName?: string; mediaClassName?: string; }; const TestimonialAboutCard = ({ tag, tagIcon, tagAnimation = "none", title, description, subdescription, icon: Icon, mediaAnimation, imageSrc, videoSrc, imageAlt = "", videoAriaLabel = "Testimonial video", useInvertedBackground, ariaLabel = "Testimonial section", className = "", containerClassName = "", cardClassName = "", contentClassName = "", tagClassName = "", titleClassName = "", descriptionClassName = "", subdescriptionClassName = "", footerClassName = "", iconBoxClassName = "", iconClassName = "", mediaWrapperClassName = "", mediaClassName = "", }: TestimonialAboutCardProps) => { const theme = useTheme(); const { containerRef: tagContainerRef } = useButtonAnimation({ animationType: tagAnimation }); const { containerRef: mediaContainerRef } = useButtonAnimation({ animationType: mediaAnimation }); return (
{description} {subdescription}
); }; TestimonialAboutCard.displayName = "TestimonialAboutCard"; export default TestimonialAboutCard;