'use client'; import { Button } from '@/components/ui/Button'; import Image from 'next/image'; import { motion, AnimatePresence } from 'framer-motion'; import { useState, useEffect } from 'react'; interface HeroVideoProps { data?: any; title?: string; subtitle?: string; description?: string; videoUrl?: string; posterImage?: any; ctaLabel?: string; ctaHref?: string; linkText?: string; linkHref?: string; secondaryCtaLabel?: string; secondaryCtaHref?: string; badge?: string; } export function HeroVideo(props: HeroVideoProps) { const { data } = props; const title = props.title || data?.title || 'DIE EXPERTEN FÜR KABELTIEFBAU'; const subtitle = props.subtitle || props.description || data?.subtitle || 'Wir verbinden Infrastruktur mit Präzision. Von Horizontalbohrungen bis zu komplexen Leitungsnetzen.'; const videoUrl = props.videoUrl || data?.videoUrl || '/assets/dummy-hero.mp4'; const posterSrc = data?.posterImage?.url || "/assets/photos/DJI_0048.JPG"; const posterAlt = data?.posterImage?.alt || "E-TIB Gruppe Baustelle"; const ctaLabel = props.ctaLabel || props.linkText || data?.ctaLabel || 'Unternehmen entdecken'; const ctaHref = props.ctaHref || props.linkHref || data?.ctaHref || '#unternehmen'; const secondaryCtaLabel = props.secondaryCtaLabel || data?.secondaryCtaLabel || 'Projekt anfragen'; const secondaryCtaHref = props.secondaryCtaHref || data?.secondaryCtaHref || '/kontakt'; return (
{subtitle}