{"version":3,"file":"RedirectOnLoad.CjLP7XVC.mjs","names":[],"sources":["https:/framerusercontent.com/modules/mcXnxl40DNAaXQmwgrTq/qx9OeIFKjPypnNoMm7jc/RedirectOnLoad.js"],"sourcesContent":["// RedirectOnLoad component that redirects users after a specified delay\nimport{jsx as _jsx}from\"react/jsx-runtime\";import{useEffect}from\"react\";import{addPropertyControls,ControlType,RenderTarget}from\"framer\";/**\n * @framerSupportedLayoutWidth fixed\n * @framerSupportedLayoutHeight fixed\n */export default function RedirectOnLoad(props){const{active=true,activeInEditor=false,delay=0,url=\"https://particular-software-225573.framer.app\"}=props;useEffect(()=>{if(typeof window===\"undefined\")return;// Check if we're in the Framer canvas/editor\nconst isInFramerCanvas=RenderTarget.current()===RenderTarget.canvas;// Decide whether redirect should happen\nconst shouldRedirect=active&&(activeInEditor||!isInFramerCanvas);if(shouldRedirect){const timer=setTimeout(()=>{window.location.href=url;},delay*1e3);return()=>clearTimeout(timer);}},[active,activeInEditor,delay,url]);// Return invisible component\nreturn /*#__PURE__*/_jsx(\"div\",{style:{width:\"1px\",height:\"1px\",background:\"transparent\",position:\"relative\",...props.style}});}addPropertyControls(RedirectOnLoad,{active:{type:ControlType.Boolean,title:\"Active\",defaultValue:true,enabledTitle:\"On\",disabledTitle:\"Off\"},activeInEditor:{type:ControlType.Boolean,title:\"Active in Editor\",defaultValue:false,enabledTitle:\"Yes\",disabledTitle:\"No\"},delay:{type:ControlType.Number,title:\"Delay\",min:0,max:60,defaultValue:0,step:.1,unit:\"s\"},url:{type:ControlType.String,title:\"Redirect URL\",defaultValue:\"https://particular-software-225573.framer.app/senses-menu\",placeholder:\"Enter URL...\"}});\nexport const __FramerMetadata__ = {\"exports\":{\"default\":{\"type\":\"reactComponent\",\"name\":\"RedirectOnLoad\",\"slots\":[],\"annotations\":{\"framerSupportedLayoutHeight\":\"fixed\",\"framerContractVersion\":\"1\",\"framerSupportedLayoutWidth\":\"fixed\"}},\"__FramerMetadata__\":{\"type\":\"variable\"}}}\n//# sourceMappingURL=./RedirectOnLoad.map"],"mappings":"4TAIG,SAAwB,EAAe,EAAM,CAAC,GAAK,CAAC,SAAO,GAAK,iBAAe,GAAM,QAAM,EAAE,MAAI,iDAAiD,EAGrJ,OAH2J,MAAc,CAAC,GAAU,IAAS,OAAY,OACzM,IAAM,EAAiB,EAAa,SAAS,GAAG,EAAa,OACI,GAA5C,IAAS,GAAgB,CAAC,GAAoC,CAAC,IAAM,EAAM,eAAe,CAAC,EAAO,SAAS,KAAK,GAAM,EAAM,IAAI,CAAC,UAAU,aAAa,EAAM,GAAI,CAAC,EAAO,EAAe,EAAM,EAAI,CAAC,CACrM,EAAK,MAAM,CAAC,MAAM,CAAC,MAAM,MAAM,OAAO,MAAM,WAAW,cAAc,SAAS,WAAW,GAAG,EAAM,MAAM,CAAC,CAAC,sBANnF,IAA6B,IAAiE,CAMT,EAAoB,EAAe,CAAC,OAAO,CAAC,KAAK,EAAY,QAAQ,MAAM,SAAS,aAAa,GAAK,aAAa,KAAK,cAAc,MAAM,CAAC,eAAe,CAAC,KAAK,EAAY,QAAQ,MAAM,mBAAmB,aAAa,GAAM,aAAa,MAAM,cAAc,KAAK,CAAC,MAAM,CAAC,KAAK,EAAY,OAAO,MAAM,QAAQ,IAAI,EAAE,IAAI,GAAG,aAAa,EAAE,KAAK,GAAG,KAAK,IAAI,CAAC,IAAI,CAAC,KAAK,EAAY,OAAO,MAAM,eAAe,aAAa,4DAA4D,YAAY,eAAe,CAAC,CAAC"}