芝麻web文件管理V1.00
编辑当前文件:/home/qrafawbu/reginaeigbe.com/folder/admin/tmp/resources/js/Frontend/Components/Hero/Hero9.jsx
import React, { useState } from 'react'; import Button from '../Button'; import Div from '../Div'; export default function Hero9({ data }) { const [iframeSrc, setIframeSrc] = useState('about:blank'); const [toggle, setToggle] = useState(false); const handelClick = () => { const video = data.youtube_link?.split('?v=')[1].trim(); setIframeSrc(`https://www.youtube.com/embed/${video}`); setToggle(!toggle); }; const handelClose = () => { setIframeSrc('about:blank'); setToggle(!toggle); }; return ( <>
> ); }