{"version":3,"file":"LoginRedirectPage.CFDnTfLR.mjs","names":[],"sources":["https:/framerusercontent.com/modules/Z6EFTT8hbBWbv83zm4Kh/5m6BfU4j7o96INKbTOvy/LoginRedirectPage.js"],"sourcesContent":["import{jsx as _jsx}from\"react/jsx-runtime\";import{useLayoutEffect}from\"react\";const getEnvironment=()=>{const{host}=document.location;if(host===\"toloka.ai\"||host===\"toloka.framer.website\"){return\"production\";}if(host===\"regress-release.toloka-test.ai\"){return\"testing\";}return\"development\";};// Tolokers\nconst tolokersLoginDomains={production:\"we.toloka.ai\",development:\"prestable.we.toloka-test.ai\",testing:\"regress-release.we.toloka-test.ai\"};const getTolokersPortalLoginLink=(environment=getEnvironment())=>{return`https://${tolokersLoginDomains[environment]}/auth?role=TOLOKER`;};export function withRedirectToTolokersPortal(Component){return props=>{useLayoutEffect(()=>{window.location.replace(getTolokersPortalLoginLink());},[]);return /*#__PURE__*/_jsx(Component,{...props});};}// Requesters\nconst requestersLoginDomains={production:\"console.toloka.ai\",development:\"prestable.console.toloka-test.ai\",testing:\"regress-release.console.toloka-test.ai\"};const getRequestersPortalLoginLink=(environment=getEnvironment())=>{return`https://${requestersLoginDomains[environment]}/auth`;};export function withRedirectToRequestersPortal(Component){return props=>{useLayoutEffect(()=>{window.location.replace(getRequestersPortalLoginLink());},[]);return /*#__PURE__*/_jsx(Component,{...props});};}\nexport const __FramerMetadata__ = {\"exports\":{\"withRedirectToRequestersPortal\":{\"type\":\"reactHoc\",\"name\":\"withRedirectToRequestersPortal\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"withRedirectToTolokersPortal\":{\"type\":\"reactHoc\",\"name\":\"withRedirectToTolokersPortal\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"__FramerMetadata__\":{\"type\":\"variable\"}}}\n//# sourceMappingURL=./LoginRedirectPage.map"],"mappings":"gIACwR,SAAgB,EAA6B,EAAU,CAAC,MAAO,KAAQ,MAAoB,CAAC,EAAO,SAAS,QAAQ,GAA4B,CAAC,EAAG,EAAE,CAAC,CAAqB,EAAK,EAAU,CAAC,GAAG,EAAM,CAAC,EAC9L,SAAgB,EAA+B,EAAU,CAAC,MAAO,KAAQ,MAAoB,CAAC,EAAO,SAAS,QAAQ,GAA8B,CAAC,EAAG,EAAE,CAAC,CAAqB,EAAK,EAAU,CAAC,GAAG,EAAM,CAAC,iCAF/b,IAAmC,CAAM,MAAmB,CAAC,GAAK,CAAC,QAAM,SAAS,SAAiJ,OAArI,IAAO,aAAa,IAAO,wBAA+B,aAAiB,IAAO,iCAAwC,UAAiB,eAC9Q,EAAqB,CAAC,WAAW,eAAe,YAAY,8BAA8B,QAAQ,oCAAoC,CAAO,GAA4B,EAAY,GAAgB,GAAU,WAAW,EAAqB,GAAa,oBAC5P,EAAuB,CAAC,WAAW,oBAAoB,YAAY,mCAAmC,QAAQ,yCAAyC,CAAO,GAA8B,EAAY,GAAgB,GAAU,WAAW,EAAuB,GAAa"}