{"version":3,"file":"Redirect.DGLxdCI2.mjs","names":[],"sources":["https:/framerusercontent.com/modules/nCEW436qLHFmHYhwMceD/NjSs29GqheLKuqQji2Sr/Redirect.js"],"sourcesContent":["import{jsx as _jsx}from\"react/jsx-runtime\";import{useEffect}from\"react\";import{addPropertyControls,ControlType}from\"framer\";/**\n * @framerSupportedLayoutWidth any\n * @framerSupportedLayoutHeight any\n */export default function Redirect(props){const{url,delay,greeting}=props;useEffect(()=>{if(typeof window===\"undefined\")return;if(window.location.hostname.includes(\"framer.app\"))return;if(window.location.hostname.includes(\"framercanvas\"))return;if(window.location.hostname.includes(\"localhost\"))return;const timeout=setTimeout(()=>{window.location.replace(url);},delay);return()=>clearTimeout(timeout);},[url,delay]);return /*#__PURE__*/_jsx(\"div\",{style:{position:\"fixed\",top:0,left:0,width:\"100vw\",height:\"100vh\",display:\"flex\",alignItems:\"center\",justifyContent:\"center\",background:\"#FFFFFF\",zIndex:9999,pointerEvents:\"none\"},children:/*#__PURE__*/_jsx(\"span\",{style:{fontFamily:\"'Noto Serif', serif\",fontWeight:900,fontStyle:\"italic\",fontSize:\"clamp(80px, 20vw, 240px)\",color:\"#F5F3EF\",lineHeight:1,userSelect:\"none\"},children:greeting})});}Redirect.defaultProps={url:\"https://gianpaolo.ch/\",delay:0,greeting:\"Ciao\"};addPropertyControls(Redirect,{url:{type:ControlType.String,title:\"URL\",defaultValue:\"https://gianpaolo.ch/\",placeholder:\"https://...\"},delay:{type:ControlType.Number,title:\"Delay (ms)\",defaultValue:0,min:0,max:5e3,step:100},greeting:{type:ControlType.String,title:\"Greeting\",defaultValue:\"Ciao\",placeholder:\"Ciao\"}});\nexport const __FramerMetadata__ = {\"exports\":{\"default\":{\"type\":\"reactComponent\",\"name\":\"Redirect\",\"slots\":[],\"annotations\":{\"framerContractVersion\":\"1\",\"framerSupportedLayoutHeight\":\"any\",\"framerSupportedLayoutWidth\":\"any\"}},\"__FramerMetadata__\":{\"type\":\"variable\"}}}\n//# sourceMappingURL=./Redirect.map"],"mappings":"wLAGG,SAAwB,EAAS,EAAM,CAAC,GAAK,CAAC,MAAI,QAAM,YAAU,EAA6V,OAAvV,MAAc,CAA6J,GAAlJ,IAAS,QAAsB,EAAO,SAAS,SAAS,SAAS,aAAa,EAAW,EAAO,SAAS,SAAS,SAAS,eAAe,EAAW,EAAO,SAAS,SAAS,SAAS,YAAY,CAAC,OAAO,IAAM,EAAQ,eAAe,CAAC,EAAO,SAAS,QAAQ,EAAI,EAAG,EAAM,CAAC,UAAU,aAAa,EAAQ,EAAG,CAAC,EAAI,EAAM,CAAC,CAAqB,EAAK,MAAM,CAAC,MAAM,CAAC,SAAS,QAAQ,IAAI,EAAE,KAAK,EAAE,MAAM,QAAQ,OAAO,QAAQ,QAAQ,OAAO,WAAW,SAAS,eAAe,SAAS,WAAW,UAAU,OAAO,KAAK,cAAc,OAAO,CAAC,SAAsB,EAAK,OAAO,CAAC,MAAM,CAAC,WAAW,sBAAsB,WAAW,IAAI,UAAU,SAAS,SAAS,2BAA2B,MAAM,UAAU,WAAW,EAAE,WAAW,OAAO,CAAC,SAAS,EAAS,CAAC,CAAC,CAAC,sBAHjyB,IAA6B,IAAoD,CAGktB,EAAS,aAAa,CAAC,IAAI,wBAAwB,MAAM,EAAE,SAAS,OAAO,CAAC,EAAoB,EAAS,CAAC,IAAI,CAAC,KAAK,EAAY,OAAO,MAAM,MAAM,aAAa,wBAAwB,YAAY,cAAc,CAAC,MAAM,CAAC,KAAK,EAAY,OAAO,MAAM,aAAa,aAAa,EAAE,IAAI,EAAE,IAAI,IAAI,KAAK,IAAI,CAAC,SAAS,CAAC,KAAK,EAAY,OAAO,MAAM,WAAW,aAAa,OAAO,YAAY,OAAO,CAAC,CAAC"}