'use client' import { useRef, useState } from 'react' import { cn, getAssetUrl } from '@/lib/utils' import { Lightbox } from './lightbox' interface VideoProps { src: string className?: string autoPlay?: boolean loop?: boolean muted?: boolean playsInline?: boolean enableLightbox?: boolean width?: number height?: number } export function Video({ src, className = 'w-full rounded-xl border border-[var(--border)] overflow-hidden outline-none focus:outline-none', autoPlay = true, loop = true, muted = true, playsInline = true, enableLightbox = true, width, height, }: VideoProps) { const videoRef = useRef(null) const startTimeRef = useRef(0) const [isLightboxOpen, setIsLightboxOpen] = useState(false) const openLightbox = () => { startTimeRef.current = videoRef.current?.currentTime ?? 0 setIsLightboxOpen(true) } const video = (