{"version":3,"file":"Autoredirect_preturi.BeS3dnfc.mjs","names":[],"sources":["https:/framerusercontent.com/modules/100qdyQ3jJ8EVd3LZT0G/7MrQFSucVH0TlmEvMuuq/Autoredirect_preturi.js"],"sourcesContent":["import{jsx as _jsx}from\"react/jsx-runtime\";import{useEffect}from\"react\";function delay(millis){return new Promise(resolve=>setTimeout(resolve,millis));}// async function autoredirectInSeconds(seconds) {\n//     await setTimeout(() => {}, 500)\n//     window.location.href = `http://oldapp.saloanelemagic.ro${window.location.pathname}`\n// }\n// Autoredirect function\nasync function autoredirectInSeconds(millis){console.log(\"Auto redirect starting...\");await delay(millis);// If you want to redirect inside the iframe itself\nwindow.location.href=`http://oldapp.saloanelemagic.ro${window.location.pathname}${window.location.search}`;// If you need to redirect the parent window, use:\n// window.top.location.href = `http://oldapp.saloanelemagic.ro${window.location.pathname}`\n}export function autoredirect(Component){return props=>{useEffect(()=>{console.log(\"HERE\");autoredirectInSeconds(100);},[]);return /*#__PURE__*/_jsx(Component,{...props});};}\nexport const __FramerMetadata__ = {\"exports\":{\"autoredirect\":{\"type\":\"reactHoc\",\"name\":\"autoredirect\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"__FramerMetadata__\":{\"type\":\"variable\"}}}\n//# sourceMappingURL=./Autoredirect_preturi.map"],"mappings":"mMAAwE,SAAS,EAAM,EAAO,CAAC,OAAO,IAAI,QAAQ,GAAS,WAAW,EAAQ,EAAO,CAAC,CAKtJ,eAAe,EAAsB,EAAO,CAAC,QAAQ,IAAI,4BAA4B,CAAC,MAAM,EAAM,EAAO,CACzG,EAAO,SAAS,KAAK,kCAAkC,EAAO,SAAS,WAAW,EAAO,SAAS,SAEjG,SAAgB,EAAa,EAAU,CAAC,MAAO,KAAQ,MAAc,CAAC,QAAQ,IAAI,OAAO,CAAC,EAAsB,IAAI,EAAG,EAAE,CAAC,CAAqB,EAAK,EAAU,CAAC,GAAG,EAAM,CAAC,uBAR/H,IAA6B"}