{"version":3,"file":"Token.rxvqbyPc.mjs","names":["__legacyOverrideHOC_DataObserverContext","_jsx"],"sources":["https:/framerusercontent.com/modules/CRvOAV4TDnKy5ys33ifA/juq9w4j0Yw3KkzWAfyXd/Token.js"],"sourcesContent":["import{jsx as _jsx}from\"react/jsx-runtime\";export function SecureTokenRedirect(){return{onClick:()=>{// First, try to retrieve the token from sessionStorage\nlet storedTokenId=sessionStorage.getItem(\"tokenId\");// Log what is retrieved from sessionStorage\nconsole.log(\"Token from sessionStorage:\",storedTokenId);// If the token is not found in sessionStorage, try to capture it from the URL again\nif(!storedTokenId){const urlParams=new URLSearchParams(window.location.search);storedTokenId=urlParams.get(\"tokenId\");// Log what is found from the URL parameters\nconsole.log(\"Token from URL parameters:\",storedTokenId);// If we find the token in the URL, store it again\nif(storedTokenId){console.log(`Token found in URL: ${storedTokenId}`);sessionStorage.setItem(\"tokenId\",storedTokenId);}}// If we have a token, proceed with the redirection\nif(storedTokenId){console.log(`Redirecting with token: ${storedTokenId}`);window.location.href=`https://meetings.hubspot.com/surepeople/request-a-demo?uuid=${storedTokenId}`;}else{// If no token is found, show an alert\nconsole.log(\"No token found.\");alert(\"No token found. Please try again.\");}}};}import{useContext as __legacyOverrideHOC_useContext}from\"react\";import{DataObserverContext as __legacyOverrideHOC_DataObserverContext}from\"framer\";export function withSecureTokenRedirect(C){return props=>{__legacyOverrideHOC_useContext(__legacyOverrideHOC_DataObserverContext);return _jsx(C,{...props,...SecureTokenRedirect(props)});};}withSecureTokenRedirect.displayName=\"SecureTokenRedirect\";\nexport const __FramerMetadata__ = {\"exports\":{\"SecureTokenRedirect\":{\"type\":\"override\",\"name\":\"SecureTokenRedirect\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"withSecureTokenRedirect\":{\"type\":\"reactHoc\",\"name\":\"withSecureTokenRedirect\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"__FramerMetadata__\":{\"type\":\"variable\"}}}\n//# sourceMappingURL=./Token.map"],"mappings":"iLAA2C,SAAgB,GAAqB,CAAC,MAAM,CAAC,YAAY,CACpG,IAAI,EAAc,eAAe,QAAQ,UAAU,CACnD,QAAQ,IAAI,6BAA6B,EAAc,CACnD,IAA2E,EAA5C,IAAI,gBAAgB,EAAO,SAAS,OAAO,CAAyB,IAAI,UAAU,CACrH,QAAQ,IAAI,6BAA6B,EAAc,CACpD,IAAe,QAAQ,IAAI,uBAAuB,IAAgB,CAAC,eAAe,QAAQ,UAAU,EAAc,GAClH,GAAe,QAAQ,IAAI,2BAA2B,IAAgB,CAAC,EAAO,SAAS,KAAK,+DAA+D,MAC9J,QAAQ,IAAI,kBAAkB,CAAC,MAAM,oCAAoC,GAAI,CAAqJ,SAAgB,EAAwB,EAAE,CAAC,MAAO,KAAQ,EAA+BA,EAAwC,CAAQC,EAAK,EAAE,CAAC,GAAG,EAAM,GAAG,EAAoB,EAAM,CAAC,CAAC,uBAPhX,IAOoG,IAAmF,CAA6L,EAAwB,YAAY"}