const __nceFramerBase=new URL("../../",import.meta.url).href; import{t as e}from"./rolldown-runtime.BRwTesTf.mjs";import{E as t,F as n,L as r,N as i,O as a,S as o,_ as s,c,h as l,j as u,k as d,l as f,o as p}from"./react.BIkpaFzZ.mjs";import{a as ee,r as te,t as m,y as h}from"./motion.LudVDGIi.mjs";import{E as g,G as _,K as ne,T as v,U as re,V as ie,W as ae,Y as y,a as b,f as oe,g as x,h as S,j as C,m as w,n as T,q as se,r as E,s as ce,t as D,y as le}from"./framer.D1tka8ap.mjs";import{o as O,s as ue}from"./shared-lib.CbuAPSH5.mjs";var k,de,fe=e((()=>{C(),k={position:`relative`,width:`100%`,height:`100%`,display:`flex`,justifyContent:`center`,alignItems:`center`},de={...k,borderRadius:6,background:`rgba(136, 85, 255, 0.3)`,color:`#85F`,border:`1px dashed #85F`,flexDirection:`column`},E.EventHandler,E.EventHandler,E.EventHandler,E.Number,E.Boolean,E.String,E.Enum})),pe=e((()=>{C(),o()})),A=e((()=>{o()})),me=e((()=>{C()})),j=e((()=>{C()})),he=e((()=>{o()})),ge=e((()=>{C()})),_e=e((()=>{n(),o()})),ve=e((()=>{o(),j()})),ye=e((()=>{o(),C(),j(),A()})),be=e((()=>{C(),o(),fe()}));function xe(){return d(()=>w.current()===w.canvas,[])}var Se=e((()=>{o(),C()})),Ce=e((()=>{o()})),we=e((()=>{o(),C(),E.FusedNumber,E.FusedNumber})),Te=e((()=>{fe(),pe(),A(),me(),j(),he(),ge(),_e(),ve(),ye(),be(),Se(),Ce(),we()})),Ee=e((()=>{Te()}));function M({type:e,url:t,html:n,zoom:r,radius:i,border:a,style:o={}}){return e===`url`&&t?c(Oe,{url:t,zoom:r,radius:i,border:a,style:o}):e===`html`&&n?c(Ae,{html:n,style:o}):c(De,{style:o})}function De({style:e}){return c(`div`,{style:{minHeight:F(e),...de,overflow:`hidden`,...e},children:c(`div`,{style:R,children:`To embed a website or widget, add it to the properties\xA0panel.`})})}function Oe({url:e,zoom:t,radius:n,border:r,style:a}){let o=!a.height;/[a-z]+:\/\//.test(e)||(e=`https://`+e);let s=xe(),[l,d]=i(s?void 0:!1);return u(()=>{if(!s)return;let t=!0;d(void 0);async function n(){let n=await fetch(`https://api.framer.com/functions/check-iframe-url?url=`+encodeURIComponent(e));if(n.status==200){let{isBlocked:e}=await n.json();t&&d(e)}else{let e=await n.text();console.error(e),d(Error(`This site can’t be reached.`))}}return n().catch(e=>{console.error(e),d(e)}),()=>{t=!1}},[e]),s&&o?c(P,{message:`URL embeds do not support auto height.`,style:a}):e.startsWith(`https://`)?l===void 0?c(Pe,{}):l instanceof Error?c(P,{message:l.message,style:a}):l===!0?c(P,{message:`Can’t embed ${e} due to its content security policy.`,style:a}):c(`iframe`,{src:e,style:{...I,...a,...r,zoom:t,borderRadius:n,transformOrigin:`top center`},loading:`lazy`,fetchPriority:s?`low`:`auto`,referrerPolicy:`no-referrer`,sandbox:ke(s),allowFullScreen:!0,allow:`presentation; fullscreen; accelerometer; autoplay; encrypted-media; gyroscope; picture-in-picture; clipboard-write`}):c(P,{message:`Unsupported protocol.`,style:a})}function ke(e){let t=[`allow-same-origin`,`allow-scripts`];return e||t.push(`allow-downloads`,`allow-forms`,`allow-modals`,`allow-orientation-lock`,`allow-pointer-lock`,`allow-popups`,`allow-popups-to-escape-sandbox`,`allow-presentation`,`allow-storage-access-by-user-activation`,`allow-top-navigation-by-user-activation`),t.join(` `)}function Ae({html:e,...t}){if(e.includes(`<\/script>`)){let n=e.includes(``),r=e.includes(``);return c(n||r?Me:je,{html:e,...t})}return c(Ne,{html:e,...t})}function je({html:e,style:n}){let a=t(),[o,s]=i(0);u(()=>{let e=a.current?.contentWindow;function t(t){if(t.source!==e)return;let n=t.data;if(typeof n!=`object`||!n)return;let r=n.embedHeight;typeof r==`number`&&s(r)}return r.addEventListener(`message`,t),e?.postMessage(`getEmbedHeight`,`*`),()=>{r.removeEventListener(`message`,t)}},[]);let l=`
${e}