'use client' import { useState, useRef, Fragment } from 'react' import { Dialog, Transition } from '@headlessui/react' import CONFIG from '../config' export default function ModalVideo({ thumb, thumbWidth, thumbHeight, thumbAlt, video, videoWidth, videoHeight }) { const [modalOpen, setModalOpen] = useState(false) const videoRef = useRef(null) return (
{/* Video thumbnail */}
{/* eslint-disable-next-line @next/next/no-img-element */} {thumbAlt} {/* */}
{/* End: Video thumbnail */} videoRef.current?.play()}> setModalOpen(false)}> {/* Modal backdrop */}
) }