import{useState as e,useEffect as t}from"react";let m=(m,o)=>{let[i,a]=e(),[r,d]=e(!m);return t(()=>{fetch(`https://vimeo.com/api/v2/video/${o}.json`).then(e=>e.json()).then(([e])=>{a(e?.thumbnail_large)})},[o]),{addIframe:()=>{r||d(!0)},thumbnail:i,iframe:r}};export{m as default,m as useLiteVimeoEmbed};
