{"version":3,"sources":["assets/mail.svg","components/MailEmpty/index.tsx","components/ResendModal/index.tsx","utils/util.ts","components/PasswordStrength/index.tsx","utils/domain.ts","assets/flow360_logo.svg","constants/index.ts","constants/envConfig.ts","utils/cognitoHelper.ts","routes/ResetPassword/index.module.less","routes/SignUp/index.module.less","constants/providerConfig.ts","constants/portalConfig.ts","components/CountrySelect/index.tsx","routes/Login/index.module.less","routes/Challenge/index.module.less","routes/MicrosoftLogin/index.module.less","utils/request.ts","services/index.tsx","utils/apiGenerator.ts","assets/logo2.png","routes/Anduril/Login/index.tsx","assets/google_icon.svg","assets/microsoft_icon.svg","routes/Login/components/LoginPanel/index.tsx","routes/auth.tsx","routes/Login/index.tsx","routes/Challenge/components/ChallengePanel/index.tsx","routes/Challenge/index.tsx","routes/MicrosoftLogin/components/MicrosoftLoginPanel/index.tsx","routes/MicrosoftLogin/index.tsx","routes/ResetPassword/components/ResetPasswordPanel/index.tsx","routes/ResetPassword/index.tsx","routes/SignUp/components/SignUpPanel/index.tsx","routes/SignUp/components/Tidy3dSignUpPanel/index.tsx","components/ResendButton/index.tsx","routes/SignUp/index.tsx","IpStatusContext.ts","routes/Home/index.tsx","App.tsx","reportWebVitals.js","index.tsx","assets/logo.svg","assets/tidy3d_logo.svg","components/AuthLayout/index.tsx","routes/Challenge/components/ChallengePanel/index.module.less","routes/Login/components/LoginPanel/index.module.less","routes/SignUp/components/SignUpPanel/index.module.less","routes/SignUp/components/Tidy3dSignUpPanel/index.module.less","routes/MicrosoftLogin/components/MicrosoftLoginPanel/index.module.less","routes/ResetPassword/components/ResetPasswordPanel/index.module.less","constants/appConfig.ts","routes/Anduril/Login/index.module.less"],"names":["MailEmpty","props","_jsx","_Empty","image","src","mailIcon","width","height","alt","ResendModal","Component","constructor","_this","arguments","this","state","didResend","loading","length","undefined","setState","resend","async","email","api","resendEmail","e","_notification","error","message","description","render","content","_Modal","maskClosable","closable","footer","wrapClassName","centered","children","_jsxs","className","CheckCircleOutlined","style","color","ExclamationCircleOutlined","_Button","onClick","type","ONE_TIME_TOKEN_KEY","cookieBaseConfig","domain","cookieDomain","secure","getUrlQueryParams","search","window","location","startsWith","substring","querystring","parse","setToken","_ref","accessToken","refreshToken","idToken","config","finalConfig","Cookies","set","setUser","user","key","obj","JSON","stringify","setCookieObj","getUser","get","getCookieObj","setLoginFlag","Date","now","testPasswordStrength","pwd","strongRegex","RegExp","mediumRegex","test","isFromTidy3d","isFromApp","isFromFlow360","isFromAdmin","isFromLog","isFromInternal","getAppNameFromUrl","appName","params","ref","decodeURIComponent","isFromAnduril","clientHost","host","concat","isFromClientHost","jumpToAnduril","getProviderConfig","href","loginUrl","initDocTitleAndDesc","title","desc","headTitleEle","document","getElementById","metaTitleEle","metaDescEle","innerText","encodeUrlJson","encodeURIComponent","console","decodeUrlJson","str","initHubspotForm","formId","formData","iframeName","form","createElement","id","display","target","Object","entries","forEach","_ref2","name","value","input","appendChild","submitBtn","iframe","visibility","body","submit","clearHubspotCache","setTimeout","click","removeChild","localStorage","removeItem","addTokenToUrl","url","token","resultUrl","URL","searchParams","PasswordStrength","level","tip","list","Array","fill","map","item","index","classnames","hostname","parseResult","parseDomain","ParseResultType","Listed","topLevelDomains","join","getCookieDomain","LOGIN_SALT","prod","s3","REGION","CASE_BUCKET","MESH_BUCKET","STUDIO_BUCKET","webapiV2","cognito","USER_POOL_ID","APP_CLIENT_ID","IDENTITY_POOL_ID","tidy3dCognito","getConfig","getCognitoConfig","cognitoConfig","poolData","UserPoolId","ClientId","CognitoUserPool","toUsername","toLowerCase","replace","hashPassword","password","sha512","module","exports","anduril","redirectUrl","provider","_providerConfigMap","dev","origin","homeUrl","getPortalConfig","Option","_Select","CountrySelect","_countryList$find","super","isRegionSelectVisible","needRegion","selectedCountry","regionList","onCountryChange","data","onChange","selectedRegion","onRegionChange","countryList","find","country","code","isRegionVisible","_Row","gutter","_Col","span","placeholder","showSearch","optionFilterProp","size","region","fetcher","axios","create","withCredentials","headers","Application","interceptors","request","use","_","Promise","reject","response","status","parseInt","checkStatus","_error$response","_error$response$data","_error$response2","_error$response2$data","APIS","login","method","oauth2","sendRegisterEmail","sendWaitingEmail","verifyEmail","forgotPassword","saveKyc","mfaAuth","mfaReset","mfaResetConfirm","confirmPassword","checkIp","timeout","getMicrosoftLoginMetadata","generator","apiKey","apiConfig","isUpload","toUpperCase","upload","FormData","post","delete","put","AndurilLoginPage","styles","anduril_login_page","AuthLayout","isFlow360","showLogo","login_panel","flow360Logo","welcome","intro","sign_in_btn","Item","_Form","Password","_Input","appTypeOptions","label","LoginPanel","appType","_this$form","validateFields","then","onLogin","referralCode","currentAppConfig","getCurrentAppConfig","labelCol","wrapperCol","me","_Radio","Group","defaultValue","options","optionType","buttonStyle","validateTrigger","rules","required","maxLength","onPressEnter","block","text","Link","to","pathname","link","_Fragment","_Divider","googleLogin","disabled","icon","googleIcon","appleLogin","AppleFilled","microsoftLogin","history","push","microsoftIcon","withRouter","auth","WrappedComponent","PureComponent","isLegal","isSimulationCloud","goHome","portalConfig","LoginPage","redirect","warning","LogRocket","identify","track","username","authResult","challengeName","challengeData","oneTimeToken","userEmail","identityId","expires","showResendModal","resendModalVisible","hideResendModal","componentDidMount","login_page","visible","onCancel","ChallengePanel","onSubmit","reset","_this$form2","setFieldsValue","mfaCode","onDisable","challenge_panel","layout","len","OtpInput","numInputs","containerStyle","opt_input","inputStyle","input_item","renderInput","ChallengePage","disableModal","isValidState","counter","session","countDown","challengeParameters","userName","USER_ID_FOR_SRP","challengeResponses","USERNAME","SOFTWARE_TOKEN_MFA_CODE","_e$message","indexOf","showDisableModal","confirm","okText","onOk","resolve","disableMfaSent","clearTimeout","destroy","catch","replaceState","invalidatePage","Redirect","success_msg","MicrosoftLoginPanel","microsoft_login_panel","MicrosoftLoginPage","invitationCode","companyInvitationCode","appConfig","targetUrl","clientId","invitation_code","micro_soft_page","ResetPasswordPanel","onReset","reset_password_panel","ResetPasswordPage","success","successEmail","reset_password_page","SignUpPanel","agreementChecked","agreementAlert","sign_up_panel","initialValues","validateFirst","whitespace","_Tooltip","placement","min","getFieldValue","validator","includes","Error","noStyle","shouldUpdate","passwordValue","passwordStrength","password_strength_wrapper","_ref3","CSSTransition","classNames","in","exit","onEntered","_Checkbox","checked","rel","Tidy3dSignUpPanel","countryRegion","rest","subscribed","isCompanyInvite","Boolean","tidy3d_sign_up_panel","autoComplete","position","border","padding","margin","valuePropName","ResendButton","whiteSpace","SignUpPage","isTidy3d","hsForm","_hsForm","rawPassword","trim","_formData$country","firstName","lastName","company","sign_up_page","marginTop","IpStatusContext","createContext","EIpStatus","loadableConfig","fallback","_Spin","indicator","LoadingOutlined","fontSize","spin","ChangePasswordPage","loadable","VerifyEmailPage","VerifyMfaPage","CallbackPage","HomePage","isLogRocketInited","ipStatus","unlisten","listen","destroyAll","initLogRocket","UNSAFE_componentWillReceiveProps","nextProps","componentWillUnmount","Normal","_user$email","_user$email2","isAndroid","endsWith","init","getSessionURL","sessionURL","log","isAnduril","Provider","logo2","Switch","Route","path","component","App","BrowserRouter","reportWebVitals","onPerfEntry","Function","getCLS","getFID","getFCP","getLCP","getTTFB","ReactDOM","React","StrictMode","isFlow360Props","isTidy3dProps","isDefault","flow360","tidy3d","tidy3dLogo","logo","googleLogout","getAppConfigMap","getAppConfig","app","appConfigMap"],"mappings":"yLAAe,G,KAAA,IAA0B,kC,OCI1B,SAASA,EAAUC,GAChC,OACEC,cAAAC,IAAA,CACEC,MAAOF,cAAA,OAAKG,IAAKC,EAAUC,MAAO,GAAIC,OAAQ,GAAIC,IAAI,QAClDR,GAGV,C,6MCMe,MAAMS,UAAoBC,YAGvCC,cAAA,IAAAC,EAAA,SAAAC,WAAAD,EAAAE,KAAA,KACAC,MAAQ,CACNC,WAAW,EACXC,SAAS,GACT,KACFA,QAAU,WAAsB,IAArBA,EAAOJ,UAAAK,OAAA,QAAAC,IAAAN,UAAA,IAAAA,UAAA,GAChBD,EAAKQ,SAAS,CACZH,WAEJ,EAAE,KACFI,OAASC,UACP,IACER,K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AKT,SAAS0b,IAGZ,OAAOtX,CAOX,CACO,SAASuX,EAAaC,GAE3B,OADqBF,IACDE,EACtB,CACO,SAASlP,IACd,MAAMmP,EAAeH,IACrB,OAAI3c,cACK8c,EAAaR,QAElBxc,cACKgd,EAAaP,OAEf,IACT,C,qBCjJAzV,EAAOC,QAAU,CAAC,yBAA2B,wCAAwC,MAAQ,qBAAqB,KAAO,oBAAoB,KAAO,oBAAoB,KAAO,oBAAoB,mBAAqB,kCAAkC,YAAc,2BAA2B,QAAU,uBAAuB,MAAQ,qBAAqB,YAAc,2B","file":"static/js/main.8ce51dbe.chunk.js","sourcesContent":["export default __webpack_public_path__ + \"static/media/mail.d3651aff.svg\";","import React from 'react';\nimport { Empty, EmptyProps } from 'antd';\nimport mailIcon from '@/assets/mail.svg';\n\nexport default function MailEmpty(props: EmptyProps) {\n return (\n <Empty\n image={<img src={mailIcon} width={60} height={60} alt=\"\" />}\n {...props}\n />\n );\n}\n","import React, { Component } from 'react';\nimport {\n ExclamationCircleOutlined,\n CheckCircleOutlined,\n} from '@ant-design/icons';\nimport { notification, Modal, Button, ModalProps } from 'antd';\nimport MailEmpty from '../MailEmpty';\nimport api from '@/services';\nimport './index.less';\nexport interface ResendModalProps extends ModalProps {\n email: string;\n content: React.ReactNode;\n}\nexport interface ResendModalState {\n didResend: boolean;\n loading: boolean;\n}\nexport default class ResendModal extends Component<\n ResendModalProps,\n ResendModalState\n> {\n state = {\n didResend: false,\n loading: false,\n };\n loading = (loading = false) => {\n this.setState({\n loading,\n });\n };\n resend = async () => {\n try {\n this.loading(true);\n const { email } = this.props;\n await api.resendEmail({ email });\n this.setState({\n didResend: true,\n });\n } catch (e: any) {\n notification.error({\n message: 'Resend email error',\n description: e.message || 'Please try again or contact the admin',\n });\n } finally {\n this.loading(false);\n }\n };\n render() {\n const { content } = this.props;\n const { didResend, loading } = this.state;\n return (\n // @ts-ignore\n <Modal\n maskClosable={false}\n closable={false}\n footer={null}\n wrapClassName={'resend_email_modal'}\n centered\n {...this.props}\n >\n <div className=\"modal_content\">\n <div className=\"content_title\">\n {didResend ? (\n <CheckCircleOutlined style={{ color: '#52c41a' }} />\n ) : (\n <ExclamationCircleOutlined style={{ color: '#faad14' }} />\n )}\n {<span>{didResend ? 'Success' : 'Warning'}</span>}\n </div>\n <div className=\"info_content\">\n {didResend ? (\n <MailEmpty\n description={\n <div>\n We sent a verification email to your account. Please follow\n the instructions in the email to complete the signup\n process.\n </div>\n }\n />\n ) : (\n <div>{content}</div>\n )}\n </div>\n <div className=\"content_footer\">\n {!didResend && (\n <Button onClick={this.resend} type={'primary'} loading={loading}>\n Resend verification email\n </Button>\n )}\n </div>\n </div>\n </Modal>\n );\n }\n}\n","import querystring from 'querystring';\nimport Cookies from 'js-cookie';\nimport { sha512 } from 'js-sha512';\n\nimport { UserInfo } from '../type';\nimport { cookieDomain } from './domain';\nimport { getProviderConfig } from '../constants/providerConfig';\nexport const ONE_TIME_TOKEN_KEY = '_token';\nexport interface CookieToken {\n accessToken: string;\n refreshToken: string;\n idToken: string;\n}\nexport interface CookieConfig {\n domain?: string;\n expires?: number;\n secure?: boolean;\n}\nconst cookieBaseConfig = {\n domain: cookieDomain,\n secure: !(isDev() || isLocal()),\n};\n\nexport function getUrlQueryParams(search = window.location.search): {\n [key: string]: string | string[] | undefined;\n} {\n try {\n if (search.startsWith('?')) {\n search = search.substring(1);\n }\n return querystring.parse(search) || {};\n } catch (e) {\n return {};\n }\n}\n\nexport function setToken(\n { accessToken, refreshToken, idToken }: CookieToken,\n config: CookieConfig = {}\n) {\n const finalConfig = {\n ...cookieBaseConfig,\n ...config,\n };\n Cookies.set('accessToken', accessToken, finalConfig);\n Cookies.set('refreshToken', refreshToken, finalConfig);\n Cookies.set('idToken', idToken, finalConfig);\n // Cookies.set('idpIdToken', idpIdToken, finalConfig);\n}\n\nexport function getToken(): CookieToken {\n return {\n accessToken: Cookies.get('accessToken') || '',\n refreshToken: Cookies.get('refreshToken') || '',\n idToken: Cookies.get('idToken') || '',\n };\n}\n\nexport function setUser(user: Partial<UserInfo>, config: CookieConfig = {}) {\n const finalConfig = {\n ...cookieBaseConfig,\n ...config,\n };\n setCookieObj('user', user, finalConfig);\n}\n\nexport function getUser(): Partial<UserInfo> | null {\n return getCookieObj('user');\n}\nexport function setLoginFlag(config: CookieConfig = {}) {\n const finalConfig = {\n ...cookieBaseConfig,\n ...config,\n };\n Cookies.set('loginTime', Date.now(), finalConfig);\n}\nexport function setCookieObj(key: string, obj: any, config: CookieConfig = {}) {\n try {\n Cookies.set(key, JSON.stringify(obj), config);\n } catch (e) {}\n}\n\nexport function getCookieObj(key: string) {\n try {\n return JSON.parse(Cookies.get(key));\n } catch (e) {\n return null;\n }\n}\n\nexport function clearToken() {\n Cookies.remove('accessToken', cookieBaseConfig);\n Cookies.remove('refreshToken', cookieBaseConfig);\n Cookies.remove('idToken', cookieBaseConfig);\n}\n\nexport function clearUser() {\n Cookies.remove('user', cookieBaseConfig);\n}\n\nexport function clearAllAuth() {\n clearToken();\n clearUser();\n}\n\n// return 1, 2, 3, 4 (strong)\nexport function testPasswordStrength(pwd = '') {\n let strongRegex = new RegExp(\n '^(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[!@#$%^&*])(?=.{8,})'\n );\n let mediumRegex = new RegExp(\n '^(((?=.*[a-z])(?=.*[A-Z]))|((?=.*[a-z])(?=.*[0-9]))|((?=.*[A-Z])(?=.*[0-9])))(?=.{8,})'\n );\n if (strongRegex.test(pwd)) {\n return 4;\n }\n if (mediumRegex.test(pwd)) {\n if (pwd.length >= 6) {\n return 3;\n } else {\n return 2;\n }\n }\n return 1;\n}\n\nexport function testInviteCode(code: string) {\n const allowed = [\n '92f3bf45390c5bfc4fa03f9378486bec6395918e35f412faf5a78da96fddc1c198cd211d9fa1c5ae0b658dabc67788bf3e8d8835f3e7495e8162550de0dcf056',\n '498e2c4988a239aba05e9fdee2a307568facaf66cfcea06fe0f3631fb6a6ef066f6d2901473fe86591938689031e9bd933a259023ab0cec6f21821ec5bfaae28',\n '620c5756739d618c3b98e6d933ff9cb423de9f53c99002f2a5208b87e6a388d7509d75119e15561afdb551ddb469ad51b4ebda4cd84ed122ef130ec2448a9e77',\n 'fdecac90672d1743d5d3616f774cf0562d2e277007e8a96e8a9be89aacd5fed6a50bf3ad6f1ba5fa2fb0af20b020a54421f87139081406d0d0a62972bf519ce7',\n 'c19b36cc882f011f7c065215ebed135cf2df9956068c12bb5a80b2bbd091381eb6db4c086d548f8aede74c5458c8787956029bd567f645a9832444337119c8f1',\n ];\n const salt = 'xaareawdfgagpaw';\n const res = sha512(code + salt);\n return allowed.includes(res);\n}\n\nexport function isProd() {\n return process.env.REACT_APP_BUILD_ENV === 'prod';\n}\nexport function isDev() {\n return process.env.REACT_APP_BUILD_ENV === 'dev';\n}\nexport function isLocal() {\n return process.env.REACT_APP_BUILD_ENV === 'local';\n}\nexport function isFromTidy3d() {\n return isFromApp('tidy3d');\n}\n\nexport function isFromFlow360() {\n return isFromApp('flow360');\n}\n\nexport function isFromAdmin() {\n return isFromApp('admin');\n}\nexport function isFromLog() {\n return isFromApp('logapp');\n}\nexport function isFromInternal() {\n return isFromAdmin() || isFromLog();\n}\n/**\n * Parse and extract ${app} from URL\n * @returns {string}\n */\nexport function getAppNameFromUrl() {\n if (isFromTidy3d()) {\n return 'tidy3d';\n } else if (isFromAdmin()) {\n return 'admin';\n } else if (isFromFlow360()) {\n return 'flow360';\n } else if (isFromLog()) {\n return 'logapp';\n }\n}\nexport function getAppTitleFromUrl() {\n if (isFromTidy3d()) {\n return 'Tidy3D - FDTD for Electromagnetic Simulation | Flexcompute Inc.';\n } else if (isFromFlow360()) {\n return 'Flow360 - The revolutionary CFD solver | Flexcompute Inc.';\n }\n return 'Flexcompute Inc.';\n}\nexport function getAppDescFromUrl() {\n if (isFromTidy3d()) {\n return 'Faster, Larger Simulations - A new solver dedicated to next-generation chips has yielded a simulation breakthrough';\n } else if (isFromFlow360()) {\n return 'A Scalable CFD Solver for Better Product Design - Flow360 Solver is a revolutionary CFD solver based on a breakthrough computing architecture that results in scalability of accurate aerodynamic simulations at unprecedented speeds.';\n }\n return 'Flexcompute Inc.';\n}\nexport function isFromApp(appName: string) {\n const params = getUrlQueryParams();\n const ref = decodeURIComponent((params.ref as string) || '');\n // const app = params.app || '';\n // const isFromApp =\n // ref.indexOf(`${appName}.simulation.cloud`) > -1 ||\n // app.toLowerCase() === appName;\n // const isFromApp = ref.indexOf(`${appName}.simulation.cloud`) > -1;\n const reg = new RegExp(\n appName + '\\\\.((dev\\\\-)|(uat\\\\-))??simulation\\\\.cloud',\n 'i'\n );\n const isFromApp = reg.test(ref);\n return isFromApp;\n}\nexport function isFromClientHost(\n clientHost: string,\n host = window.location.host\n) {\n const reg = new RegExp(\n `^${clientHost}-.*\\\\.((dev-)|(uat-))??simulation\\\\.cloud$`,\n 'i'\n );\n const isFromClientHost = reg.test(host);\n return isFromClientHost;\n}\nexport function isFromAnduril() {\n return isFromClientHost('anduril');\n}\nexport function jumpToAnduril() {\n const config = getProviderConfig('anduril');\n if (config) {\n window.location.href = config.loginUrl;\n }\n}\n// export function getDefaultAppHost(appName) {\n// appName = getAppNameFromUrl() || 'flow360';\n// if (isFromApp(appName)) {\n// return `${getDefaultHostPrefix()}${appName}.simulation.cloud`;\n// }\n// }\n\n// export function getDefaultHostPrefix() {\n// const BUILD_ENV = process.env.REACT_APP_BUILD_ENV;\n// if (BUILD_ENV === 'prod') {\n// return '';\n// } else if (BUILD_ENV === 'uat') {\n// return 'uat-';\n// }\n// return 'dev-';\n// }\n// const PAGE_TITLE_MAP = {\n// '/login': {\n// title: 'Sign In',\n// },\n// '/reset_password': {\n// title: 'Reset Password',\n// },\n// '/signup': {\n// title: 'Sign Up',\n// },\n// };\nexport function initDocTitleAndDesc() {\n const title = getAppTitleFromUrl();\n const desc = getAppDescFromUrl();\n // const pageTitle = PAGE_TITLE_MAP[location?.pathname]?.title || '';\n const headTitleEle = document.getElementById('headTitle') as HTMLTitleElement;\n const metaTitleEle = document.getElementById('metaTitle') as HTMLMetaElement;\n const metaDescEle = document.getElementById('metaDesc') as HTMLMetaElement;\n headTitleEle.innerText = title;\n metaTitleEle.content = title;\n metaDescEle.content = desc;\n}\nexport function encodeUrlJson(obj: any): string {\n try {\n return encodeURIComponent(JSON.stringify(obj)) || '';\n } catch (e) {\n console.error(e);\n return '';\n }\n}\nexport function decodeUrlJson(str: string) {\n try {\n return JSON.parse(decodeURIComponent(str)) || {};\n } catch (e) {\n console.error(e);\n return {};\n }\n}\nexport function initHubspotForm(formId: string, formData: any) {\n const iframeName = `${Date.now()}_form`;\n\n const form = document.createElement('form');\n form.id = formId;\n form.style.display = 'none';\n form.target = iframeName;\n Object.entries(formData ?? {}).forEach(([name, value]) => {\n const input = document.createElement('input');\n input.type = 'text';\n input.name = name;\n input.value = value as string;\n form.appendChild(input);\n });\n const submitBtn = document.createElement('button');\n submitBtn.type = 'submit';\n form.appendChild(submitBtn);\n\n const iframe = document.createElement('iframe');\n iframe.style.visibility = 'none';\n iframe.width = '0';\n iframe.height = '0';\n iframe.name = iframeName;\n // iframe.srcdoc = div.innerHTML;\n document.body.appendChild(iframe);\n document.body.appendChild(form);\n return {\n submit: () => {\n clearHubspotCache();\n setTimeout(() => {\n submitBtn.click();\n document.body.removeChild(iframe);\n document.body.removeChild(form);\n }, 1000);\n },\n };\n}\nexport function clearHubspotCache() {\n localStorage.removeItem('li_submission');\n}\nexport function addTokenToUrl(url: string, token: string) {\n const resultUrl = new URL(url);\n resultUrl.searchParams.set(ONE_TIME_TOKEN_KEY, token);\n return resultUrl.href;\n}\n","import React, { Component } from 'react';\nimport classnames from 'classnames';\nimport './index.less';\n\nexport interface PasswordStrengthProps {\n level: number;\n}\nexport default class PasswordStrength extends Component<PasswordStrengthProps> {\n render() {\n const { level } = this.props;\n let tip = '';\n switch (level) {\n case 1:\n case 2:\n tip = 'weak';\n break;\n case 3:\n tip = 'medium';\n break;\n case 4:\n tip = 'strong';\n break;\n default:\n }\n const list = new Array(4).fill(1);\n return (\n <div className=\"password_strength\">\n {list.map((item, index) => (\n <div\n key={index}\n className={classnames('strength_bar', {\n [tip]: level >= index + 1,\n })}\n />\n ))}\n <div className=\"strength_tip\">{tip}</div>\n </div>\n );\n }\n}\n","import { parseDomain, ParseResultType } from 'parse-domain';\n\nexport function getCookieDomain(hostname = window.location.hostname) {\n const parseResult = parseDomain(hostname);\n let cookieDomain;\n if (parseResult.type === ParseResultType.Listed) {\n const { domain, topLevelDomains } = parseResult;\n cookieDomain = `.${[domain, ...topLevelDomains].join('.')}`;\n }\n return cookieDomain;\n}\nconst cookieDomain = getCookieDomain();\nexport { cookieDomain };\n","export default __webpack_public_path__ + \"static/media/flow360_logo.33383d3d.svg\";","export const LOGIN_SALT = '5ac0e45f46654d70bda109477f10c299';\n","import { isFromTidy3d } from '../utils/util';\n\nexport interface EnvConfig {\n s3: S3Config;\n webapiV2: {\n URL: string;\n };\n cognito: CognitoConfig;\n tidy3dCognito: CognitoConfig;\n}\nexport interface S3Config {\n REGION: string;\n CASE_BUCKET: string;\n MESH_BUCKET: string;\n STUDIO_BUCKET: string;\n}\nexport interface CognitoConfig {\n REGION: string;\n USER_POOL_ID: string;\n APP_CLIENT_ID: string;\n IDENTITY_POOL_ID: string;\n}\nconst dev: EnvConfig = {\n s3: {\n REGION: 'us-east-1',\n CASE_BUCKET: 'flow360cases-v1',\n MESH_BUCKET: 'flow360meshes-v1',\n STUDIO_BUCKET: 'flow360-studio-v1',\n },\n webapiV2: {\n URL: 'https://portal-api.dev-simulation.cloud',\n //URL: \"http://localhost:5000\",\n },\n cognito: {\n REGION: 'us-east-1',\n USER_POOL_ID: 'us-east-1_t41TfpFiq',\n APP_CLIENT_ID: '58h5c2luqdrads6cpjtbjmabjr',\n IDENTITY_POOL_ID: 'us-east-1:7d23a768-ca1c-446b-b91b-31d3e1fe968a',\n },\n tidy3dCognito: {\n REGION: 'us-east-1',\n USER_POOL_ID: 'us-east-1_kjeChiCm8',\n APP_CLIENT_ID: '1imult4e80s1lfocqjpfv69rm2',\n IDENTITY_POOL_ID: 'us-east-1:6cdace1e-db96-4a52-b513-ceb212913de9',\n },\n};\n\nconst prod: EnvConfig = {\n s3: {\n REGION: 'us-gov-west-1',\n CASE_BUCKET: 'flow360cases',\n MESH_BUCKET: 'flow360meshes',\n STUDIO_BUCKET: 'flow360studio',\n },\n webapiV2: {\n URL: 'https://portal-api.simulation.cloud',\n },\n cognito: {\n REGION: 'us-east-1',\n USER_POOL_ID: 'us-east-1_Csq1uNAO3',\n APP_CLIENT_ID: 'scepvluho5eeehv297pvdunk5',\n IDENTITY_POOL_ID: 'us-east-1:68a3cf31-60fc-4def-8db2-4c3d48070756',\n },\n tidy3dCognito: {\n REGION: 'us-east-1',\n USER_POOL_ID: 'us-east-1_kfHmLjlPl',\n APP_CLIENT_ID: '45krrjc3bm1snlddbo79jfpk1d',\n IDENTITY_POOL_ID: 'us-east-1:dc691611-c253-4448-9b96-2bc507940155',\n },\n};\nconst uat: EnvConfig = {\n ...prod,\n webapiV2: {\n URL: 'https://uat-portal-api.simulation.cloud',\n },\n};\nconst uat2: EnvConfig = {\n s3: {\n REGION: 'us-west-2',\n CASE_BUCKET: 'flow360cases-uat2',\n MESH_BUCKET: 'flow360meshes-uat2',\n STUDIO_BUCKET: 'flow360-studio-uat2',\n },\n webapiV2: {\n URL: 'https://portal-api.uat-simulation.cloud',\n //URL: \"http://localhost:5000\",\n },\n cognito: {\n REGION: 'us-west-2',\n USER_POOL_ID: 'us-west-2_Cb8xkdgub',\n APP_CLIENT_ID: '457ch71sk8k3cq5ki0o6k7ljhe',\n IDENTITY_POOL_ID: '',\n },\n tidy3dCognito: {\n REGION: 'us-west-2',\n USER_POOL_ID: 'us-west-2_1zBiqSz9j',\n APP_CLIENT_ID: '6rt02ramf9ajkh93redglq4b4h',\n IDENTITY_POOL_ID: '',\n },\n};\nexport function getConfig(): EnvConfig {\n const BUILD_ENV = process.env.REACT_APP_BUILD_ENV;\n if (BUILD_ENV === 'prod') {\n return prod;\n } else if (BUILD_ENV === 'uat') {\n return uat;\n } else if (BUILD_ENV === 'uat2') {\n return uat2;\n }\n return dev;\n}\n\nexport default getConfig();\n\nexport function getCognitoConfig(): CognitoConfig {\n const config = getConfig();\n if (isFromTidy3d()) {\n return config.tidy3dCognito;\n }\n return config.cognito;\n}\n","import {\n CognitoUserPool,\n // CognitoUserAttribute,\n CognitoUser,\n} from 'amazon-cognito-identity-js';\nimport { sha512 } from 'js-sha512';\n\nimport { getCognitoConfig } from '../constants/envConfig';\nimport { LOGIN_SALT } from '../constants';\n\nconst cognitoConfig = getCognitoConfig();\nconst poolData = {\n UserPoolId: cognitoConfig.USER_POOL_ID,\n ClientId: cognitoConfig.APP_CLIENT_ID,\n};\nconst userPool = new CognitoUserPool(poolData);\n\n// export function resetPassword(email, { onSuccess, onError, ...rest }) {\n// createUser(email).forgotPassword({\n// onSuccess,\n// onFailure: onError,\n// ...rest,\n// });\n// }\n\n// export function confirmPassword(\n// { email, password, code },\n// { onSuccess, onError, ...rest }\n// ) {\n// createUser(email).confirmPassword(code, hashPassword(password), {\n// onSuccess,\n// onFailure: onError,\n// ...rest,\n// });\n// }\n\n// export function verifyEmail(email, code, callback) {\n// // @callback params\n// // (err,result)=>{}\n// createUser(email).confirmRegistration(code, true, callback);\n// }\n\nexport function createUser(email: string) {\n return new CognitoUser({\n Username: toUsername(email),\n Pool: userPool,\n });\n}\n\nexport function toUsername(email: string) {\n return email.toLowerCase().replace('@', '-at-');\n}\n\nexport function hashPassword(password: string) {\n return sha512(password + LOGIN_SALT);\n}\n","// extracted by mini-css-extract-plugin\nmodule.exports = {\"reset_password_page\":\"index_reset_password_page__mza6C\",\"success_msg\":\"index_success_msg__3Td9p\"};","// extracted by mini-css-extract-plugin\nmodule.exports = {\"sign_up_page\":\"index_sign_up_page__1i2qk\",\"success_msg\":\"index_success_msg__2Vb4k\"};","export interface ProviderConfigMap {\n anduril: ProviderConfig;\n}\nexport interface ProviderConfig {\n redirectUrl: string;\n loginUrl: string;\n}\nconst dev: ProviderConfigMap = {\n anduril: {\n redirectUrl: 'https://anduril-flow360.dev-simulation.cloud',\n loginUrl: `https://sso.dev-simulation.cloud/oauth2/authorize?client_id=3juubqouhhf354ai4b79tcal2j&response_type=code&scope=email+openid+profile&redirect_uri=https://anduril-my.dev-simulation.cloud/callback/flow360/anduril`,\n },\n};\nconst uat: ProviderConfigMap = {\n anduril: {\n redirectUrl: 'https://anduril-uat-flow360.simulation.cloud',\n loginUrl: `https://sso.simulation.cloud/oauth2/authorize?client_id=41ut0khprdcacuc5cfedl4s3hh&response_type=code&scope=email+openid+profile&redirect_uri=https://anduril-uat-my.simulation.cloud/callback/flow360/anduril`,\n },\n};\nconst uat2: ProviderConfigMap = {\n anduril: {\n redirectUrl: 'https://anduril-flow360.uat-simulation.cloud',\n loginUrl: `https://sso.uat-simulation.cloud/oauth2/authorize?client_id=24oodmcut9qcrbiij0i274cnrf&response_type=code&scope=email+openid+profile&redirect_uri=https://anduril-my.uat-simulation.cloud/callback/flow360/anduril`,\n },\n};\nconst prod: ProviderConfigMap = {\n anduril: {\n redirectUrl: 'https://anduril-flow360.simulation.cloud',\n loginUrl: `https://sso.simulation.cloud/oauth2/authorize?client_id=41ut0khprdcacuc5cfedl4s3hh&response_type=code&scope=email+openid+profile&redirect_uri=https://anduril-my.simulation.cloud/callback/flow360/anduril`,\n },\n};\n\nexport function getProviderConfigMap(): ProviderConfigMap {\n const BUILD_ENV = process.env.REACT_APP_BUILD_ENV;\n if (BUILD_ENV === 'prod') {\n return prod;\n } else if (BUILD_ENV === 'uat') {\n return uat;\n } else if (BUILD_ENV === 'uat2') {\n return uat2;\n }\n return dev;\n}\nexport function getProviderConfig(provider: string): ProviderConfig | null {\n const providerConfigMap = getProviderConfigMap();\n return providerConfigMap[provider as keyof typeof providerConfigMap] ?? null;\n}\n","import { cookieDomain } from '../utils/domain';\n\nexport interface PortalConfig {\n cookieDomain?: string;\n host: string;\n loginUrl: string;\n homeUrl: string;\n}\nconst dev: PortalConfig = {\n cookieDomain: cookieDomain,\n host: 'dev-my.simulation.cloud',\n loginUrl: `${window.location.origin}/login`,\n homeUrl: 'https://develop.d2dhrbzbpo6ev1.amplifyapp.com',\n};\nconst uat: PortalConfig = {\n ...dev,\n host: 'uat-my.simulation.cloud',\n // loginUrl: 'https://uat-my.simulation.cloud/login',\n homeUrl: 'https://www.simulation.cloud',\n};\nconst uat2: PortalConfig = {\n ...dev,\n host: 'my.uat-simulation.cloud',\n // loginUrl: 'https://uat-my.simulation.cloud/login',\n homeUrl: 'https://www.simulation.cloud',\n};\nconst prod: PortalConfig = {\n ...dev,\n host: 'my.simulation.cloud',\n // loginUrl: 'https://my.simulation.cloud/login',\n homeUrl: 'https://www.simulation.cloud',\n};\n\nexport function getPortalConfig(): PortalConfig {\n const BUILD_ENV = process.env.REACT_APP_BUILD_ENV;\n if (BUILD_ENV === 'prod') {\n return prod;\n } else if (BUILD_ENV === 'uat') {\n return uat;\n } else if (BUILD_ENV === 'uat2') {\n return uat2;\n }\n return dev;\n}\n\nexport default getPortalConfig();\n","import React, { Component } from 'react';\nimport { Row, Col, Select } from 'antd';\nimport countryList from './country-region.json';\n\nconst { Option } = Select;\n\nexport interface CountrySelectProps {\n value?: [Country | null, Region | null];\n needRegion: boolean;\n onChange?: (value: [Country | null, Region | null]) => void;\n}\nexport interface CountrySelectState {\n selectedCountry: Country | null;\n selectedRegion: Region | null;\n regionList: Region[];\n}\nexport interface Region {\n code: string;\n name: string;\n}\nexport interface Country extends Region {\n regionList?: Region[];\n}\nexport default class CountrySelect extends Component<\n CountrySelectProps,\n CountrySelectState\n> {\n constructor(props: CountrySelectProps) {\n super(props);\n const { value } = props;\n const [selectedCountry = null, selectedRegion = null] = value || [];\n const regionList =\n countryList.find(country => country.code === selectedCountry?.code)\n ?.regionList || [];\n this.state = {\n selectedCountry,\n selectedRegion,\n regionList,\n };\n }\n isRegionSelectVisible = () => {\n const { needRegion } = this.props;\n if (!needRegion) {\n return false;\n }\n const { selectedCountry, regionList } = this.state;\n if (!selectedCountry || regionList?.length) {\n // if (regionList?.length) {\n return true;\n } else {\n return false;\n }\n };\n onCountryChange = (value: string, { data }: { data: Country }) => {\n const { onChange } = this.props;\n //exclude regionList from data\n const { regionList, ...selectedCountry } = data;\n this.setState(\n {\n selectedCountry: selectedCountry,\n selectedRegion: null,\n regionList: regionList || [],\n },\n () => {\n onChange?.([selectedCountry, null]);\n }\n );\n };\n onRegionChange = (value: string, { data }: { data: Region }) => {\n const { onChange } = this.props;\n const { selectedCountry } = this.state;\n this.setState(\n {\n selectedCountry,\n selectedRegion: data,\n },\n () => {\n onChange?.([selectedCountry, data]);\n }\n );\n };\n render() {\n const { selectedCountry, selectedRegion, regionList } = this.state;\n const isRegionVisible = this.isRegionSelectVisible();\n return (\n <Row gutter={20}>\n <Col span={isRegionVisible ? 12 : 24}>\n <Select\n placeholder={'Country / Region'}\n value={selectedCountry?.code}\n // @ts-ignore\n onChange={this.onCountryChange}\n showSearch\n optionFilterProp={'children'}\n size={'large'}\n >\n {countryList.map(country => (\n <Option key={country.code} value={country.code} data={country}>\n {country.name}\n </Option>\n ))}\n </Select>\n </Col>\n {isRegionVisible && (\n <Col span={12}>\n <Select\n placeholder={'State/Region'}\n value={selectedRegion?.code}\n // @ts-ignore\n onChange={this.onRegionChange}\n showSearch\n optionFilterProp={'children'}\n size={'large'}\n >\n {regionList?.map(region => (\n <Option key={region.code} value={region.code} data={region}>\n {region.name}\n </Option>\n ))}\n </Select>\n </Col>\n )}\n </Row>\n );\n }\n}\n","// extracted by mini-css-extract-plugin\nmodule.exports = {\"login_page\":\"index_login_page__1sYMo\",\"hidden\":\"index_hidden__1J7LR\"};","// extracted by mini-css-extract-plugin\nmodule.exports = {\"success_msg\":\"index_success_msg__gc3EQ\"};","// extracted by mini-css-extract-plugin\nmodule.exports = {\"micro_soft_page\":\"index_micro_soft_page__1dyME\",\"success_msg\":\"index_success_msg__rkP0t\"};","import axios, { AxiosResponse } from 'axios';\nimport { isFromTidy3d } from './util';\nexport interface ResponseData {\n code: number | string;\n [key: string]: any;\n}\nlet fetcher = axios.create({\n withCredentials: false,\n headers: {\n 'Access-Control-Allow-Origin': '*',\n 'content-type': 'application/json',\n Application: isFromTidy3d() ? 'TIDY3D' : '',\n },\n});\n\n// Request interceptors\nfetcher.interceptors.request.use(\n config => {\n const { headers = {}, params = {} } = config;\n const _ = Date.now();\n config.headers = {\n ...headers,\n };\n //add timestamp\n config.params = {\n _,\n ...params,\n };\n return config;\n },\n error => {\n return Promise.reject(error);\n }\n);\n\n// Response interceptors\nfunction checkStatus(response: AxiosResponse<ResponseData>) {\n if (response.status >= 200 && response.status < 300) {\n response.data.code =\n parseInt(`${response.data.code}`, 10) || response.status;\n return response.data;\n }\n}\nfetcher.interceptors.response.use(\n function (response) {\n return checkStatus(response);\n },\n function (e) {\n return Promise.reject(e);\n }\n);\n\nfetcher.interceptors.response.use(\n function (response) {\n return response;\n },\n function (error) {\n const code = parseInt(error.response?.data?.code || error.response.status);\n const message = error.response?.data?.error || error.message;\n return Promise.reject({\n ...error,\n code,\n message,\n });\n }\n);\n\n// export const post = fetcher.post;\n// export const put = fetcher.put;\n// export const get = axios.get;\n// export const del = (url, params) => {\n// return fetcher.delete(url, { params });\n// };\nexport default fetcher;\n","import { generator, RequestApiConfigMap } from '../utils/apiGenerator';\nimport config from '../constants/envConfig';\nconst { webapiV2 } = config;\nconst APIS: RequestApiConfigMap = {\n login: {\n method: 'get',\n url: `${webapiV2.URL}/auth`,\n },\n oauth2: {\n method: 'get',\n url: `${webapiV2.URL}/oauth2/token`,\n },\n sendRegisterEmail: {\n method: 'post',\n url: `${webapiV2.URL}/auth/register`,\n },\n sendWaitingEmail: {\n method: 'post',\n url: `${webapiV2.URL}/anonymous/waitinglist`,\n },\n verifyEmail: {\n method: 'put',\n url: `${webapiV2.URL}/auth/verify`,\n },\n resendEmail: {\n method: 'put',\n url: `${webapiV2.URL}/auth/resend`,\n },\n forgotPassword: {\n method: 'post',\n url: `${webapiV2.URL}/auth/forgot-password`,\n },\n saveKyc: {\n method: 'put',\n url: `${webapiV2.URL}/auth/kyc`,\n },\n mfaAuth: {\n method: 'post',\n url: `${webapiV2.URL}/auth/challenge`,\n },\n mfaReset: {\n method: 'post',\n url: `${webapiV2.URL}/auth/mfa/reset`,\n },\n mfaResetConfirm: {\n method: 'post',\n url: `${webapiV2.URL}/auth/mfa/resetConfirm`,\n },\n confirmPassword: {\n method: 'post',\n url: `${webapiV2.URL}/auth/confirm-forget-password`,\n },\n checkIp: {\n method: 'get',\n url: `${webapiV2.URL}/auth/check`,\n timeout: 3000,\n },\n getMicrosoftLoginMetadata: {\n method: 'get',\n url: `${webapiV2.URL}/auth/pre/metadata`,\n timeout: 3000,\n },\n};\nexport default generator(APIS);\n","import { AxiosRequestConfig } from 'axios';\nimport request from './request';\n\nexport interface RequestApiConfig {\n method: 'get' | 'post' | 'put' | 'delete';\n url: string;\n isUpload?: boolean;\n timeout?: number;\n}\nexport interface RequestApiConfigMap {\n [key: string]: RequestApiConfig;\n}\nconst upload = (\n apiConfig: RequestApiConfig,\n data: any,\n config: AxiosRequestConfig\n) => {\n const { url, method } = apiConfig;\n if (data instanceof FormData) {\n }\n return request({\n url,\n method,\n data,\n headers: {\n 'Content-Type': 'multipart/form-data',\n },\n ...config,\n });\n};\n\nexport const generator = (APIS: RequestApiConfigMap) => {\n const api: { [key: string]: Function } = {};\n Object.entries(APIS).forEach(([apiKey = '', apiConfig]) => {\n const { method = 'get', url = '', isUpload = false } = apiConfig || {};\n if (!apiKey || !apiConfig || !url) {\n return;\n }\n switch (method.toUpperCase()) {\n case 'POST':\n api[apiKey] = (data: any, config = {}) =>\n isUpload\n ? upload(apiConfig, data, config)\n : request.post(url, data, config);\n break;\n case 'DELETE':\n api[apiKey] = (params: any, config = {}) =>\n request.delete(url, { params, ...config });\n break;\n case 'PUT':\n api[apiKey] = (data: any, config = {}) =>\n request.put(url, data, config);\n break;\n case 'GET':\n default:\n api[apiKey] = (params: any, config = {}) =>\n request.get(url, { params, ...config });\n }\n });\n return api;\n};\n","export default __webpack_public_path__ + \"static/media/logo2.1567433e.png\";","import React, { Component } from 'react';\nimport { Button } from 'antd';\nimport AuthLayout from '@/components/AuthLayout';\nimport flow360Logo from '../../../assets/flow360_logo.svg';\nimport { jumpToAnduril } from '../../../utils/util';\nimport styles from './index.module.less';\n\nexport default class AndurilLoginPage extends Component {\n render() {\n return (\n <div className={styles.anduril_login_page}>\n <AuthLayout isFlow360={true} showLogo={false} style={{ width: 400 }}>\n <div className={styles.login_panel}>\n <img src={flow360Logo} alt={'Flow360 logo'} width={155} />\n <div className={styles.welcome}>Welcome to Flow360!</div>\n <div className={styles.intro}>\n Flow360 Solver is a Scalable CFD Solver for Better Product Design\n </div>\n <div>\n <Button\n onClick={() => {\n jumpToAnduril();\n }}\n type={'primary'}\n className={styles.sign_in_btn}\n >\n Sign In\n </Button>\n </div>\n </div>\n </AuthLayout>\n </div>\n );\n }\n}\n","export default __webpack_public_path__ + \"static/media/google_icon.e6226f71.svg\";","export default __webpack_public_path__ + \"static/media/microsoft_icon.28d8f59e.svg\";","import React, { Component } from 'react';\nimport { Link, RouteComponentProps, withRouter } from 'react-router-dom';\nimport {\n Form,\n Input,\n Button,\n Divider,\n FormInstance,\n Radio,\n RadioChangeEvent,\n} from 'antd';\nimport { AppleFilled } from '@ant-design/icons';\n\nimport styles from './index.module.less';\nimport { getCurrentAppConfig } from '@/constants/appConfig';\nimport googleIcon from '../../../../assets/google_icon.svg';\nimport microsoftIcon from '../../../../assets/microsoft_icon.svg';\nimport {\n encodeUrlJson,\n getUrlQueryParams,\n isFromFlow360,\n isFromTidy3d,\n isFromInternal,\n} from '../../../../utils/util';\n\nconst { Item } = Form;\nconst { Password } = Input;\nconst appTypeOptions = [\n { label: 'Flow360', value: 'FLOW360' },\n { label: 'Tidy3d', value: 'TIDY3D' },\n];\n\nexport interface LoginPanelProps extends RouteComponentProps {\n onLogin: (data: any) => void;\n loading: boolean;\n}\nexport interface LoginPanelState {\n referralCode: string;\n ref: string;\n appType: string;\n}\nclass LoginPanel extends Component<LoginPanelProps, LoginPanelState> {\n constructor(props: LoginPanelProps) {\n super(props);\n const params = getUrlQueryParams();\n let appType = 'FLOW360'; // Default to FLOW360\n\n if (isFromFlow360()) {\n appType = 'FLOW360';\n } else if (isFromTidy3d()) {\n appType = 'TIDY3D';\n }\n this.state = {\n referralCode: (params.referralCode as string) || '',\n ref: params.ref as string,\n appType: appType,\n };\n }\n form: FormInstance | null = null;\n onChange = (e: RadioChangeEvent) => {\n this.setState({ appType: e.target.value });\n };\n login = () => {\n this.form?.validateFields().then(formData => {\n const { email } = formData;\n const { onLogin } = this.props;\n onLogin({\n ...formData,\n appType: this.state.appType.toUpperCase(),\n email: email.toLowerCase(),\n });\n });\n };\n render() {\n const { referralCode, ref, appType } = this.state;\n const { loading, location } = this.props;\n const currentAppConfig = getCurrentAppConfig();\n const layout = {\n labelCol: {\n span: 0,\n },\n wrapperCol: {\n span: 24,\n },\n };\n return (\n <div className={styles.login_panel}>\n <div className={styles.title}>Sign In</div>\n <div className={styles.form}>\n <Form\n {...layout}\n ref={me => (this.form = me)}\n // onFinish={this.onFinish}\n >\n {isFromInternal() && (\n <Item name=\"appType\" label=\"Select App\">\n <div>\n <span>Account Type: </span>\n <Radio.Group\n defaultValue=\"FLOW360\"\n value={appType}\n options={appTypeOptions}\n onChange={this.onChange}\n optionType=\"button\"\n buttonStyle=\"solid\"\n />\n </div>\n </Item>\n )}\n <Item\n name=\"email\"\n label=\"Email\"\n validateTrigger={'onBlur'}\n rules={[\n {\n required: true,\n message: 'Please input your email',\n },\n {\n type: 'email',\n message: 'Invalid email address, please check',\n },\n ]}\n >\n <Input\n placeholder={'Enter email'}\n maxLength={50}\n onPressEnter={this.login}\n size={'large'}\n />\n </Item>\n <Item\n name=\"password\"\n label=\"Password\"\n rules={[\n { required: true, message: 'Please input your password' },\n ]}\n >\n <Password\n placeholder={'Password'}\n maxLength={50}\n onPressEnter={this.login}\n size={'large'}\n />\n </Item>\n <Item>\n <Button\n id=\"sign-in-with-email\"\n type=\"primary\"\n block\n onClick={this.login}\n loading={loading}\n size={'large'}\n >\n Log In\n </Button>\n </Item>\n <div className={styles.footer}>\n <div className={styles.text}>\n Forgot password? \n <Link\n to={{ pathname: '/reset_password', search: location.search }}\n className={styles.link}\n >\n Reset Password\n </Link>\n </div>\n <div className={styles.text}>\n Don’t have an account? \n <Link\n to={{ pathname: '/signup', search: location.search }}\n className={styles.link}\n >\n Sign up\n </Link>\n {/*<a*/}\n {/* href={'https://www.flexcompute.com/contact/'}*/}\n {/* className={styles.link}*/}\n {/*>*/}\n {/* Sign up*/}\n {/*</a>*/}\n </div>\n </div>\n {currentAppConfig && (\n <>\n <Divider>OR</Divider>\n <Item>\n <Button\n id=\"sign-in-with-google\"\n block\n onClick={() => {\n window.location.href = `${\n currentAppConfig.googleLogin\n }&state=${encodeUrlJson({\n referralCode,\n ref,\n })}`;\n }}\n disabled={loading}\n // className={'google_login'}\n size={'large'}\n icon={\n <img\n src={googleIcon}\n width={14}\n height={14}\n className=\"anticon\"\n alt=\"\"\n />\n }\n >\n Sign in with Google\n </Button>\n </Item>\n {currentAppConfig.appleLogin && (\n <Item>\n <Button\n id=\"sign-in-with-apple\"\n block\n onClick={() => {\n window.location.href = `${\n currentAppConfig.appleLogin\n }&state=${encodeUrlJson({\n referralCode,\n ref,\n })}`;\n }}\n disabled={loading}\n size={'large'}\n icon={<AppleFilled style={{ color: '#000' }} />}\n >\n Sign in with Apple\n </Button>\n </Item>\n )}\n {currentAppConfig.microsoftLogin && (\n <Item>\n <Button\n id=\"sign-in-with-microsoft\"\n block\n onClick={() => {\n this.props.history.push({\n ...location,\n pathname: '/microsoft_login',\n });\n }}\n disabled={loading}\n // className={'google_login'}\n size={'large'}\n icon={\n <img\n src={microsoftIcon}\n width={14}\n height={14}\n className=\"anticon\"\n alt=\"\"\n />\n }\n >\n Sign in with Microsoft\n </Button>\n </Item>\n )}\n </>\n )}\n </Form>\n </div>\n </div>\n );\n }\n}\nexport default withRouter(LoginPanel);\n","import React, { PureComponent } from 'react';\nimport { isFromApp } from '../utils/util';\nimport portalConfig from '../constants/portalConfig';\n\n// auth HOC, handle auth logic globally\nexport default function auth(WrappedComponent: Function) {\n return class extends PureComponent {\n isLegal = () => {\n const isSimulationCloud = isFromApp('');\n if (!isSimulationCloud) {\n this.goHome();\n return false;\n }\n return isSimulationCloud;\n };\n goHome = () => {\n window.location.href = portalConfig.homeUrl;\n };\n render() {\n if (!this.isLegal()) {\n return null;\n }\n return <WrappedComponent {...this.props} />;\n }\n };\n}\n","import React, { Component } from 'react';\nimport { notification } from 'antd';\nimport { sha512 } from 'js-sha512';\nimport LogRocket from 'logrocket';\n\nimport AuthLayout from '@/components/AuthLayout';\nimport { LOGIN_SALT } from '@/constants';\nimport {\n getUrlQueryParams,\n setToken,\n setUser,\n setLoginFlag,\n addTokenToUrl,\n} from '@/utils/util';\nimport api from '@/services';\nimport { RouteComponentProps } from 'react-router-dom';\nimport LoginPanel from './components/LoginPanel';\nimport auth from '../auth';\n\nimport styles from './index.module.less';\nimport ResendModal from '../../components/ResendModal';\n// import { getDefaultAppHost } from '../../utils/util';\n\nexport interface LoginPageProps extends RouteComponentProps {}\nexport interface LoginPageState {\n loading: boolean;\n ref: string;\n resendEmail: string;\n resendModalVisible: boolean;\n}\nclass LoginPage extends Component<LoginPageProps, LoginPageState> {\n constructor(props: LoginPageProps) {\n super(props);\n const params = getUrlQueryParams();\n this.state = {\n loading: false,\n ref: decodeURIComponent((params.ref as string) || ''),\n resendEmail: '',\n resendModalVisible: false,\n };\n }\n\n componentDidMount() {\n // bypass login if accessToken exists\n // if (Cookies.get('accessToken')) {\n // this.redirect();\n // }\n }\n\n redirect = (token: string) => {\n const { ref } = this.state;\n if (ref) {\n window.location.href = addTokenToUrl(ref, token);\n } else {\n notification.warning({\n message: 'No ref found',\n description: 'Login success, but no [ref] param found in url address',\n });\n // window.location.href = getDefaultAppHost();\n }\n };\n loading = (loading = false) => {\n this.setState({\n loading: loading,\n });\n };\n onLogin = async (formData: any) => {\n const { email, password, appType } = formData;\n\n try {\n this.loading(true);\n LogRocket.identify(email, {\n name: email,\n email,\n });\n LogRocket.track('login start', { email });\n const { data } = await api.login(\n {},\n {\n auth: {\n username: email,\n password: sha512(password + LOGIN_SALT),\n },\n headers: {\n Application: appType,\n },\n }\n );\n LogRocket.track('login success', { email });\n const { authResult } = data;\n if (authResult?.challengeName === 'SOFTWARE_TOKEN_MFA') {\n const { history, location } = this.props;\n history.push({\n ...location,\n pathname: '/challenge',\n state: {\n email,\n challengeData: authResult,\n },\n });\n } else {\n const {\n auth: {\n accessToken,\n refreshToken,\n idToken,\n // expiresIn = 36000\n },\n oneTimeToken,\n user,\n } = data;\n const { email: userEmail, identityId } = user;\n const expires = 365;\n // const expires = new Date(Date.now() + expiresIn * 1000);\n // save token to cookies, default alive in 36000 sec\n setToken({ accessToken, refreshToken, idToken }, { expires });\n setUser({ email: userEmail, identityId }, { expires });\n setLoginFlag();\n // window.frames[0].postMessage(JSON.stringify(user), ref);\n this.redirect(oneTimeToken);\n }\n } catch (e: any) {\n LogRocket.track('login error', { email, message: e.message });\n // unconfirmed user\n if (e.code === 4010000002) {\n this.showResendModal(email);\n } else {\n notification.error({\n message: 'Incorrect email or password',\n description: e.message || 'Please try again or contact the admin',\n });\n }\n } finally {\n this.loading(false);\n }\n };\n showResendModal = (resendEmail: string) => {\n this.setState({\n resendEmail,\n resendModalVisible: true,\n });\n };\n hideResendModal = () => {\n this.setState({\n resendModalVisible: false,\n });\n };\n render() {\n const { loading, resendEmail, resendModalVisible } = this.state;\n return (\n <div className={styles.login_page}>\n <AuthLayout>\n <LoginPanel onLogin={this.onLogin} loading={loading} />\n </AuthLayout>\n {/*<iframe*/}\n {/* src={ref}*/}\n {/* ref={me => (this.iframe = me)}*/}\n {/* className={styles.hidden}*/}\n {/*/>*/}\n <ResendModal\n content={\n <div>\n Your account has not been activated yet. To activate, please\n verify your email address by clicking the button and following the\n instructions in the verification email.\n </div>\n }\n email={resendEmail}\n visible={resendModalVisible}\n onCancel={this.hideResendModal}\n />\n </div>\n );\n }\n}\nexport default auth(LoginPage);\n","import React, { Component } from 'react';\nimport { Link, RouteComponentProps, withRouter } from 'react-router-dom';\nimport { Form, Input, Button, FormInstance } from 'antd';\nimport OtpInput from 'react-otp-input';\n\nimport styles from './index.module.less';\n\nconst { Item } = Form;\n\nexport interface ChallengePanelProps extends RouteComponentProps {\n onSubmit: (data: any) => void;\n loading: boolean;\n onDisable: () => void;\n}\nclass ChallengePanel extends Component<ChallengePanelProps> {\n form: FormInstance | null = null;\n submit = () => {\n this.form?.validateFields().then(async formData => {\n const { onSubmit } = this.props;\n try {\n await onSubmit(formData);\n } finally {\n this.reset();\n }\n });\n };\n reset = () => {\n this.form?.setFieldsValue({\n mfaCode: '',\n });\n };\n\n render() {\n const { loading, location, onDisable } = this.props;\n return (\n <div className={styles.challenge_panel}>\n <div className={styles.title}>Multi-Factor Authentication</div>\n <div className={styles.form}>\n <Form layout={'vertical'} ref={me => (this.form = me)}>\n <Item\n name=\"mfaCode\"\n label=\"Enter an MFA code to complete sign in.\"\n validateTrigger={'onBlur'}\n rules={[\n {\n required: true,\n len: 6,\n message: 'Please input 6 digits MFA code',\n },\n ]}\n >\n {/*<Input placeholder={'MFA Code'} maxLength={6} size={'large'} />*/}\n {/* @ts-ignore */}\n <OtpInput\n numInputs={6}\n // renderSeparator={<span></span>}\n containerStyle={styles.opt_input}\n inputStyle={styles.input_item}\n // @ts-ignore\n renderInput={props => <Input {...props} size={'large'} />}\n />\n </Item>\n <Item>\n <Button\n type=\"primary\"\n block\n onClick={this.submit}\n loading={loading}\n size={'large'}\n >\n Submit\n </Button>\n </Item>\n </Form>\n <div className={styles.footer}>\n <div className={styles.text}>\n <Link\n to={{ pathname: '/login', search: location.search }}\n className={styles.link}\n >\n Cancel\n </Link>\n </div>\n <div className={styles.text}>\n Lost binding account? \n <span className={styles.link} onClick={onDisable}>\n Turn off MFA\n </span>\n </div>\n </div>\n </div>\n </div>\n );\n }\n}\nexport default withRouter(ChallengePanel);\n","import React, { Component } from 'react';\nimport { notification, Modal } from 'antd';\nimport LogRocket from 'logrocket';\nimport { Redirect, RouteComponentProps } from 'react-router-dom';\n\nimport AuthLayout from '@/components/AuthLayout';\nimport { AuthInfo, ChallengeInfo } from '../../type';\nimport ChallengePanel from './components/ChallengePanel';\nimport api from '@/services';\nimport auth from '../auth';\nimport {\n getUrlQueryParams,\n setToken,\n setUser,\n setLoginFlag,\n addTokenToUrl,\n} from '@/utils/util';\nimport styles from './index.module.less';\n\nexport interface ChallengePageProps extends RouteComponentProps {}\nexport interface ChallengePageState {\n email: string;\n challengeData: ChallengeInfo;\n ref: string;\n counter: number;\n disableMfaSent: boolean;\n loading: boolean;\n}\nexport interface ChallengePageRouteState {\n challengeData: ChallengeInfo;\n email: string;\n}\nclass ChallengePage extends Component<ChallengePageProps, ChallengePageState> {\n constructor(props: ChallengePageProps) {\n super(props);\n const {\n location: { state },\n } = props;\n const { challengeData, email } = (state || {}) as ChallengePageRouteState;\n const params = getUrlQueryParams();\n this.state = {\n email,\n challengeData: { ...(challengeData || {}) },\n ref: decodeURIComponent((params.ref as string) || ''),\n counter: 180,\n disableMfaSent: false,\n loading: false,\n };\n }\n timeout: number | undefined;\n disableModal: any;\n componentDidMount() {\n // clear state in history. then if refresh page, redirect to login\n window.history.replaceState({}, document.title);\n // manually invalidate page in 180 sec\n this.countDown(180);\n }\n\n loading = (loading = false) => {\n this.setState({\n loading,\n });\n };\n isValidState = () => {\n const { email, challengeData, counter } = this.state;\n return (\n counter > 0 &&\n email &&\n challengeData.session &&\n challengeData.challengeName === 'SOFTWARE_TOKEN_MFA'\n );\n };\n countDown = (counter: number) => {\n this.setState({ counter }, () => {\n if (counter > 0) {\n this.timeout = window.setTimeout(() => {\n this.countDown(--counter);\n }, 1000);\n }\n });\n };\n onSubmit = async (formData: any) => {\n const { mfaCode } = formData;\n const {\n email,\n challengeData: { challengeName, session, challengeParameters },\n } = this.state;\n const userName = challengeParameters?.USER_ID_FOR_SRP;\n try {\n this.loading(true);\n LogRocket.identify(email, {\n name: email,\n email,\n });\n LogRocket.track('mfa auth start', { email });\n const { data }: { data: AuthInfo } = await api.mfaAuth({\n challengeName,\n session,\n challengeResponses: {\n USERNAME: userName,\n SOFTWARE_TOKEN_MFA_CODE: mfaCode,\n },\n });\n LogRocket.track('mfa auth success', { email });\n const {\n auth: {\n accessToken,\n refreshToken,\n idToken,\n // expiresIn = 36000\n },\n oneTimeToken,\n user,\n } = data;\n const { email: userEmail, identityId } = user;\n const expires = 365;\n setToken({ accessToken, refreshToken, idToken }, { expires });\n setUser({ email: userEmail, identityId }, { expires });\n setLoginFlag();\n this.redirect(oneTimeToken);\n } catch (e: any) {\n LogRocket.track('mfa auth error', { email, message: e.message });\n // set count down to 0 to invalidate page\n if (e.message?.indexOf('session') > -1) {\n this.countDown(0);\n } else {\n notification.error({\n message: 'MFA error',\n description: e.message || 'Please try again or contact the admin',\n });\n }\n } finally {\n this.loading(false);\n }\n };\n redirect = (token: string) => {\n const { ref } = this.state;\n if (ref) {\n window.location.href = addTokenToUrl(ref, token);\n } else {\n notification.warning({\n message: 'No ref found',\n description: 'Login success, but no [ref] param found in url address',\n });\n }\n };\n invalidatePage() {\n const { counter } = this.state;\n if (counter <= 0) {\n notification.error({\n message: 'MFA timeout, please login again',\n key: 'mfaError',\n });\n }\n return (\n <Redirect\n to={{\n ...this.props.location,\n pathname: '/login',\n }}\n />\n );\n }\n // disableMfa = async () => {\n // try {\n // const { email } = this.state;\n // await api.mfaReset({ email });\n // this.setState({\n // disableMfaSent: true,\n // });\n // clearTimeout(this.timeout);\n // this.disableModal.destroy();\n // } catch (e) {\n // notification.error({\n // message: 'Turn off MFA error',\n // description: e.message || 'Please try again or contact the admin',\n // });\n // }\n // };\n showDisableModal = () => {\n this.disableModal = Modal.confirm({\n title: 'Turn off MFA',\n // footer: null,\n centered: true,\n width: 570,\n maskClosable: false,\n closable: false,\n content: (\n <div>\n If you have lost access to your Authenticator app and are unable to\n sign in, click the button below to send a verification link to your\n email. The link will allow you to temporarily disable MFA. After\n signing in, you can turn on MFA again to protect your account.\n </div>\n ),\n okText: 'Send verification email',\n onOk: async () => {\n return new Promise((resolve, reject) => {\n const { email } = this.state;\n\n api\n .mfaReset({ email })\n .then(() => {\n this.setState({\n disableMfaSent: true,\n });\n clearTimeout(this.timeout);\n this.disableModal.destroy();\n resolve(true);\n })\n .catch((e: any) => {\n notification.error({\n message: 'Turn off MFA error',\n description:\n e.message || 'Please try again or contact the admin',\n });\n reject(e);\n });\n });\n },\n });\n };\n render() {\n const { loading, disableMfaSent } = this.state;\n // if state not valid, redirect to login page\n if (!this.isValidState()) {\n return this.invalidatePage();\n }\n return (\n <div>\n <AuthLayout>\n {disableMfaSent ? (\n <div className={styles.success_msg}>\n Email sent, please check your inbox.\n </div>\n ) : (\n <ChallengePanel\n onSubmit={this.onSubmit}\n onDisable={this.showDisableModal}\n loading={loading}\n />\n )}\n </AuthLayout>\n </div>\n );\n }\n}\nexport default auth(ChallengePage);\n","import React, { Component } from 'react';\nimport { Link, RouteComponentProps, withRouter } from 'react-router-dom';\nimport { Form, Input, Button, FormInstance } from 'antd';\n\nimport styles from './index.module.less';\n\nconst { Item } = Form;\n\nexport interface MicrosoftLoginPanelProps extends RouteComponentProps {\n onLogin: (data: any) => void;\n loading: boolean;\n}\nclass MicrosoftLoginPanel extends Component<MicrosoftLoginPanelProps> {\n form: FormInstance | null = null;\n login = () => {\n this.form?.validateFields().then((formData: any) => {\n const { email } = formData;\n const { onLogin } = this.props;\n onLogin({\n ...formData,\n email: email.toLowerCase(),\n });\n });\n };\n render() {\n const { loading, location } = this.props;\n // const layout = {\n // labelCol: {\n // span: 0,\n // },\n // wrapperCol: {\n // span: 24,\n // },\n // };\n return (\n <div className={styles.microsoft_login_panel}>\n <div className={styles.title}>Sign in with Microsoft</div>\n <div className={styles.form}>\n <Form\n layout={'vertical'}\n ref={me => (this.form = me)}\n // onFinish={this.onFinish}\n >\n <Item\n name=\"email\"\n label=\"Fill in your email to login.\"\n validateTrigger={'onBlur'}\n rules={[\n {\n required: true,\n message: 'Please input your email',\n },\n {\n type: 'email',\n message: 'Invalid email address, please check',\n },\n ]}\n >\n <Input\n placeholder={'Enter email'}\n maxLength={50}\n size={'large'}\n onPressEnter={this.login}\n />\n </Item>\n <Item>\n <Button\n type=\"primary\"\n block\n onClick={this.login}\n loading={loading}\n size={'large'}\n >\n Log In\n </Button>\n </Item>\n </Form>\n <div className={styles.footer}>\n <div className={styles.text}>\n Already have an account? \n <Link\n to={{ pathname: '/login', search: location.search }}\n className={styles.link}\n >\n Sign in\n </Link>\n </div>\n </div>\n </div>\n </div>\n );\n }\n}\nexport default withRouter(MicrosoftLoginPanel);\n","import React, { Component } from 'react';\n\nimport AuthLayout from '@/components/AuthLayout';\nimport { RouteComponentProps } from 'react-router-dom';\nimport { encodeUrlJson, getUrlQueryParams } from '../../utils/util';\nimport MicrosoftLoginPanel from './components/MicrosoftLoginPanel';\nimport api from '@/services';\nimport auth from '../auth';\nimport { getCurrentAppConfig } from '../../constants/appConfig';\n\nimport styles from './index.module.less';\n\nexport interface MicrosoftLoginPageProps extends RouteComponentProps {}\nexport interface MicrosoftLoginPageState {\n loading: boolean;\n referralCode: string;\n invitationCode: string;\n companyInvitationCode: string;\n}\nclass MicrosoftLoginPage extends Component<\n MicrosoftLoginPageProps,\n MicrosoftLoginPageState\n> {\n constructor(props: MicrosoftLoginPageProps) {\n super(props);\n const params = getUrlQueryParams();\n this.state = {\n loading: false,\n referralCode: (params.referralCode as string) || '',\n invitationCode: (params.invitation_code as string) || '',\n companyInvitationCode: (params.companyInvitationCode as string) || '',\n };\n }\n\n componentDidMount() {}\n\n loading = (loading = false) => {\n this.setState({\n loading: loading,\n });\n };\n\n onLogin = async (formData: { email: string }) => {\n try {\n const { referralCode, invitationCode, companyInvitationCode } =\n this.state;\n this.loading(true);\n const { email } = formData;\n const { data } = await api.getMicrosoftLoginMetadata({\n email,\n });\n const appConfig = getCurrentAppConfig();\n const loginUrl = appConfig?.microsoftLogin;\n if (loginUrl) {\n const targetUrl = new URL(loginUrl);\n targetUrl.searchParams.set('identity_provider', data.provider);\n targetUrl.searchParams.set('client_id', data.clientId);\n targetUrl.searchParams.set(\n 'state',\n encodeUrlJson({\n referralCode,\n companyInvitationCode,\n invitationCode,\n })\n );\n window.location.replace(targetUrl.href);\n }\n } finally {\n this.loading(false);\n }\n };\n render() {\n const { loading } = this.state;\n return (\n <div className={styles.micro_soft_page}>\n <AuthLayout>\n <MicrosoftLoginPanel onLogin={this.onLogin} loading={loading} />\n </AuthLayout>\n </div>\n );\n }\n}\nexport default auth(MicrosoftLoginPage);\n","import React, { Component } from 'react';\nimport { Link, RouteComponentProps, withRouter } from 'react-router-dom';\nimport { Form, Input, Button, FormInstance } from 'antd';\n\nimport styles from './index.module.less';\n\nconst { Item } = Form;\n\nexport interface ResetPasswordPanelProps extends RouteComponentProps {\n onReset: (data: any) => void;\n loading: boolean;\n}\nclass ResetPasswordPanel extends Component<ResetPasswordPanelProps> {\n form: FormInstance | null = null;\n reset = () => {\n this.form?.validateFields().then((formData: any) => {\n const { email } = formData;\n const { onReset } = this.props;\n onReset({\n ...formData,\n email: email.toLowerCase(),\n });\n });\n };\n\n render() {\n const { loading, location } = this.props;\n // const layout = {\n // labelCol: {\n // span: 0,\n // },\n // wrapperCol: {\n // span: 24,\n // },\n // };\n return (\n <div className={styles.reset_password_panel}>\n <div className={styles.title}>Reset Password</div>\n <div className={styles.form}>\n <Form\n layout={'vertical'}\n ref={me => (this.form = me)}\n // onFinish={this.onFinish}\n >\n <Item\n name=\"email\"\n label=\"Fill in your email to get a verification code.\"\n validateTrigger={'onBlur'}\n rules={[\n {\n required: true,\n message: 'Please input your email',\n },\n {\n type: 'email',\n message: 'Invalid email address, please check',\n },\n ]}\n >\n <Input\n placeholder={'Enter email'}\n maxLength={50}\n size={'large'}\n />\n </Item>\n <Item>\n <Button\n type=\"primary\"\n block\n onClick={this.reset}\n loading={loading}\n size={'large'}\n >\n Get Verification Code\n </Button>\n </Item>\n </Form>\n <div className={styles.footer}>\n <div className={styles.text}>\n Already have an account? \n <Link\n to={{ pathname: '/login', search: location.search }}\n className={styles.link}\n >\n Sign in\n </Link>\n </div>\n </div>\n </div>\n </div>\n );\n }\n}\nexport default withRouter(ResetPasswordPanel);\n","import React, { Component } from 'react';\nimport { notification } from 'antd';\nimport LogRocket from 'logrocket';\n\nimport AuthLayout from '@/components/AuthLayout';\nimport { RouteComponentProps } from 'react-router-dom';\nimport ResetPasswordPanel from './components/ResetPasswordPanel';\nimport ResendModal from '@/components/ResendModal';\nimport api from '@/services';\nimport auth from '../auth';\n\nimport styles from './index.module.less';\n\nexport interface ResetPasswordPageProps extends RouteComponentProps {}\nexport interface ResetPasswordPageState {\n loading: boolean;\n successEmail: string;\n resendEmail: string;\n resendModalVisible: boolean;\n}\nclass ResetPasswordPage extends Component<\n ResetPasswordPageProps,\n ResetPasswordPageState\n> {\n constructor(props: ResetPasswordPageProps) {\n super(props);\n this.state = {\n loading: false,\n successEmail: '',\n resendEmail: '',\n resendModalVisible: false,\n };\n }\n\n componentDidMount() {}\n\n loading = (loading = false) => {\n this.setState({\n loading: loading,\n });\n };\n\n onReset = async (data: any) => {\n const { email } = data;\n try {\n this.loading(true);\n LogRocket.identify(email, {\n name: email,\n email,\n });\n LogRocket.track('reset password start', { email });\n await api.forgotPassword({\n email,\n });\n LogRocket.track('reset password success', { email });\n notification.success({\n message: 'Reset password request is sent',\n description: `Reset password email will be sent to ${email}, please check your inbox or contact the support`,\n });\n this.setState({\n successEmail: email,\n });\n } catch (e: any) {\n LogRocket.track('reset password error', { email, message: e.message });\n if (e.code === 4030000001) {\n this.showResendModal(email);\n } else {\n notification.success({\n message: 'Reset password request is sent',\n description: `Reset password email will be sent to ${email}, please check your inbox or contact the support`,\n });\n this.setState({\n successEmail: email,\n });\n }\n } finally {\n this.loading(false);\n }\n\n // resetPassword(email, {\n // onSuccess: data => {\n // _this.loading(false);\n // notification.success({\n // message: 'Reset password request is sent',\n // description: `Reset password email will be sent to ${email}, please check your inbox or contact the support`,\n // });\n // LogRocket.track('reset password success', { email });\n // _this.setState({\n // successEmail: email,\n // });\n // },\n // onError: e => {\n // LogRocket.track('reset password error', { email, message: e.message });\n // _this.loading(false);\n // notification.success({\n // message: 'Reset password request is sent',\n // description: `Reset password email will be sent to ${email}, please check your inbox or contact the support`,\n // });\n // _this.setState({\n // successEmail: email,\n // });\n // },\n // });\n };\n showResendModal = (resendEmail: string) => {\n this.setState({\n resendEmail,\n resendModalVisible: true,\n });\n };\n hideResendModal = () => {\n this.setState({\n resendModalVisible: false,\n });\n };\n render() {\n const { loading, successEmail, resendEmail, resendModalVisible } =\n this.state;\n return (\n <div className={styles.reset_password_page}>\n <AuthLayout>\n {successEmail ? (\n // <div className={styles.success_msg}>\n // Reset password email has been sent to{' '}\n // <strong>{successEmail}</strong>, please check your inbox.\n // </div>\n <div className={styles.success_msg}>\n Email sent, please check your inbox.\n </div>\n ) : (\n <ResetPasswordPanel onReset={this.onReset} loading={loading} />\n )}\n </AuthLayout>\n <ResendModal\n content={\n <div>\n Your account has not been activated yet. To activate, please\n verify your email address by clicking the button and following the\n instructions in the verification email.\n </div>\n }\n email={resendEmail}\n visible={resendModalVisible}\n onCancel={this.hideResendModal}\n />\n </div>\n );\n }\n}\nexport default auth(ResetPasswordPage);\n","import React, { Component } from 'react';\nimport { Link, RouteComponentProps, withRouter } from 'react-router-dom';\nimport { Form, Input, Button, Tooltip, Checkbox, FormInstance } from 'antd';\nimport {\n testPasswordStrength,\n getUrlQueryParams,\n // isFromTidy3d,\n} from '@/utils/util';\nimport { CSSTransition } from 'react-transition-group';\n\nimport styles from './index.module.less';\nimport PasswordStrength from '@/components/PasswordStrength';\n// import { getCurrentAppConfig } from '@/constants/appConfig';\n\ninterface SignUpPanelProps extends RouteComponentProps {\n onSubmit: (data: any) => void;\n loading: boolean;\n}\ninterface SignUpPanelState {\n agreementChecked: boolean;\n invitationCode: string;\n email: string;\n agreementAlert: boolean;\n}\nconst { Item } = Form;\nconst { Password } = Input;\n\nclass SignUpPanel extends Component<SignUpPanelProps, SignUpPanelState> {\n constructor(props: SignUpPanelProps) {\n super(props);\n const params = getUrlQueryParams();\n this.state = {\n agreementChecked: false,\n invitationCode: (params.invitation_code as string) || '',\n email: (params.email as string) || '',\n agreementAlert: false,\n };\n }\n form: FormInstance | null = null;\n submit = () => {\n this.form?.validateFields().then(formData => {\n const { agreementChecked } = this.state;\n if (!agreementChecked) {\n this.agreementAlert(true);\n return;\n }\n const { email } = formData;\n const { onSubmit } = this.props;\n onSubmit({\n ...formData,\n email: email.toLowerCase(),\n });\n });\n };\n agreementAlert = (agreementAlert = false) => {\n this.setState({\n agreementAlert,\n });\n };\n render() {\n const { loading, location } = this.props;\n // const currentAppConfig = getCurrentAppConfig();\n const layout = {\n labelCol: {\n span: 0,\n },\n wrapperCol: {\n span: 24,\n },\n };\n const { agreementChecked, invitationCode, email, agreementAlert } =\n this.state;\n return (\n <div className={styles.sign_up_panel}>\n <div className={styles.title}>Sign Up</div>\n <div className={styles.form}>\n <Form\n {...layout}\n ref={me => (this.form = me)}\n // onFinish={this.onFinish}\n initialValues={{ invitationCode, email }}\n >\n <Item\n name=\"email\"\n label=\"Email\"\n validateTrigger={'onBlur'}\n validateFirst\n rules={[\n {\n type: 'string',\n required: true,\n message: 'Please input your email',\n whitespace: true,\n },\n {\n type: 'email',\n message: 'Invalid email address, please check',\n },\n ]}\n >\n <Input placeholder={'Email'} maxLength={50} size={'large'} />\n </Item>\n {/*{!isFromTidy3d() && (*/}\n <Item\n name=\"invitationCode\"\n label=\"Invitation Code\"\n rules={[\n {\n type: 'string',\n required: true,\n message: 'Please input your invitation code',\n whitespace: true,\n },\n ]}\n >\n <Input\n placeholder={'Invitation Code'}\n maxLength={50}\n size={'large'}\n />\n </Item>\n {/*)}*/}\n <Tooltip\n title=\"Password must have at least 8 characters, with at least 1 special\n character (!@#$%^&), 1 numeric, 1 lower and 1 upper case letter.\"\n placement=\"right\"\n >\n <Item\n name=\"password\"\n label=\"Password\"\n validateFirst\n rules={[\n { required: true, message: 'Please input your password' },\n {\n type: 'string',\n min: 8,\n message: 'Password must have at least 8 characters',\n },\n ({ getFieldValue }) => ({\n validator(_, value) {\n const email = getFieldValue('email');\n if (\n email?.length &&\n value?.length &&\n value.toLowerCase().includes(email.toLowerCase())\n ) {\n return Promise.reject(\n new Error(\n 'Password should not contain current email address'\n )\n );\n }\n if (testPasswordStrength(value) < 4) {\n return Promise.reject(\n new Error(\n 'Please choose stronger password to protect your account'\n )\n );\n }\n return Promise.resolve();\n },\n }),\n ]}\n >\n <Password\n placeholder={'Password'}\n maxLength={50}\n size={'large'}\n />\n </Item>\n </Tooltip>\n <Item noStyle shouldUpdate={true}>\n {({ getFieldValue }) => {\n const passwordValue = getFieldValue('password') || '';\n const passwordStrength = testPasswordStrength(passwordValue);\n return (\n passwordValue.length > 0 && (\n <div className={styles.password_strength_wrapper}>\n <label>Password Strength:</label>\n <PasswordStrength level={passwordStrength} />\n </div>\n )\n );\n }}\n </Item>\n <Item\n name=\"confirmPassword\"\n label=\"Confirm Password\"\n validateFirst\n rules={[\n { required: true, message: 'Please confirm your password' },\n ({ getFieldValue }) => ({\n validator(_, value) {\n if (!value || getFieldValue('password') === value) {\n return Promise.resolve();\n }\n return Promise.reject(\n new Error('Passwords do not match, please check')\n );\n },\n }),\n ]}\n >\n <Password\n placeholder={'Confirm Password'}\n maxLength={50}\n size={'large'}\n />\n </Item>\n <CSSTransition\n classNames=\"agreement\"\n in={agreementAlert}\n timeout={500}\n exit={false}\n onEntered={() => {\n this.agreementAlert(false);\n }}\n >\n <Item>\n <Checkbox\n checked={agreementChecked}\n onChange={e => {\n this.setState({\n agreementChecked: e.target.checked,\n });\n }}\n >\n By checking this box and signing up, you agree to our{' '}\n <a\n href=\"//www.flexcompute.com/term_of_use/\"\n target={'_blank'}\n rel=\"noreferrer\"\n >\n <strong>terms of services</strong>\n </a>{' '}\n and{' '}\n <a\n href=\"//www.flexcompute.com/privacy/\"\n target={'_blank'}\n rel=\"noreferrer\"\n >\n <strong>privacy policy</strong>\n </a>\n .\n </Checkbox>\n </Item>\n </CSSTransition>\n <Item>\n <Button\n id=\"sign-up-with-email\"\n type=\"primary\"\n block\n onClick={this.submit}\n loading={loading}\n size={'large'}\n className={'sign_up_btn'}\n // disabled={!agreementChecked}\n >\n Sign Up\n </Button>\n </Item>\n <div className={styles.footer}>\n <div className={styles.text}>\n Already have an account? \n <Link\n to={{ pathname: '/login', search: location.search }}\n className={styles.link}\n >\n Sign in\n </Link>\n </div>\n {/*<div className={styles.text}>*/}\n {/* To use Flexcompute's Electromagnetic Product, please sign*/}\n {/* up */}\n {/* <a*/}\n {/* href=\"//tidy3d.simulation.cloud/register\"*/}\n {/* className={styles.link}*/}\n {/* >*/}\n {/* here*/}\n {/* </a>*/}\n {/*</div>*/}\n </div>\n {/*{currentAppConfig && (*/}\n {/* <>*/}\n {/* <Divider>OR</Divider>*/}\n {/* <Item>*/}\n {/* <Button*/}\n {/* block*/}\n {/* onClick={() => {*/}\n {/* if (!agreementChecked) {*/}\n {/* this.agreementAlert(true);*/}\n {/* return;*/}\n {/* }*/}\n {/* window.location.href = currentAppConfig.googleLogin;*/}\n {/* }}*/}\n {/* // disabled={!agreementChecked}*/}\n {/* className={'google_login'}*/}\n {/* loading={loading}*/}\n {/* >*/}\n {/* Continue with Google*/}\n {/* </Button>*/}\n {/* </Item>*/}\n {/* </>*/}\n {/*)}*/}\n </Form>\n </div>\n </div>\n );\n }\n}\n\nexport default withRouter(SignUpPanel);\n","import React, { Component, MouseEvent } from 'react';\nimport { Link, RouteComponentProps, withRouter } from 'react-router-dom';\nimport {\n Form,\n Input,\n Button,\n Tooltip,\n Row,\n Col,\n Divider,\n Checkbox,\n FormInstance,\n} from 'antd';\nimport { AppleFilled } from '@ant-design/icons';\nimport {\n testPasswordStrength,\n getUrlQueryParams,\n // isFromTidy3d,\n} from '@/utils/util';\nimport microsoftIcon from '../../../../assets/microsoft_icon.svg';\nimport { encodeUrlJson } from '../../../../utils/util';\nimport { CSSTransition } from 'react-transition-group';\n// import { CSSTransition } from 'react-transition-group';\n\nimport styles from './index.module.less';\nimport PasswordStrength from '@/components/PasswordStrength';\nimport CountrySelect from '../../../../components/CountrySelect';\nimport { getCurrentAppConfig } from '@/constants/appConfig';\nimport googleIcon from '../../../../assets/google_icon.svg';\nexport interface Tidy3dSignUpPanelProps extends RouteComponentProps {\n onSubmit: (data: any) => void;\n loading: boolean;\n}\nexport interface Tidy3dSignUpPanelState {\n subscribed: boolean;\n invitationCode: string;\n email: string;\n referralCode: string;\n ref: string;\n companyInvitationCode: string;\n agreementChecked: boolean;\n agreementAlert: boolean;\n}\n\nconst { Item } = Form;\nconst { Password } = Input;\n\nclass Tidy3dSignUpPanel extends Component<\n Tidy3dSignUpPanelProps,\n Tidy3dSignUpPanelState\n> {\n constructor(props: Tidy3dSignUpPanelProps) {\n super(props);\n const params = getUrlQueryParams();\n this.state = {\n subscribed: true,\n invitationCode: (params.invitation_code as string) || '',\n email: (params.email as string) || '',\n referralCode: (params.referralCode as string) || '',\n companyInvitationCode: (params.companyInvitationCode as string) || '',\n ref: (params.ref as string) || '',\n agreementChecked: false,\n agreementAlert: false,\n };\n }\n form: FormInstance | null = null;\n submit = (e: MouseEvent) => {\n this.form?.validateFields().then(formData => {\n const { agreementChecked } = this.state;\n if (!agreementChecked) {\n this.agreementAlert(true);\n return;\n }\n const { email, countryRegion, ...rest } = formData;\n const [country] = countryRegion;\n const { referralCode, invitationCode, companyInvitationCode } =\n this.state;\n const { onSubmit } = this.props;\n onSubmit({\n ...rest,\n email: email.toLowerCase(),\n country,\n referralCode,\n invitationCode,\n companyInvitationCode,\n });\n });\n };\n agreementAlert = (agreementAlert = false) => {\n this.setState({\n agreementAlert,\n });\n };\n\n render() {\n const { loading, location } = this.props;\n const currentAppConfig = getCurrentAppConfig();\n const layout = {\n labelCol: {\n span: 0,\n },\n wrapperCol: {\n span: 24,\n },\n };\n const {\n invitationCode,\n email,\n subscribed,\n referralCode,\n companyInvitationCode,\n ref,\n agreementAlert,\n agreementChecked,\n } = this.state;\n const isCompanyInvite = Boolean(companyInvitationCode);\n return (\n <div className={styles.tidy3d_sign_up_panel}>\n <div className={styles.title}>\n {isCompanyInvite ? 'Join Your Group' : 'Sign Up'}\n </div>\n <div className={styles.form}>\n <Form\n {...layout}\n ref={me => (this.form = me)}\n // onFinish={this.onFinish}\n initialValues={{ invitationCode, email, subscribed }}\n // id={'tidy3d-sign-up-form'}\n >\n <Row gutter={20}>\n <Col span={12}>\n <Item\n name=\"firstName\"\n label=\"First Name\"\n validateFirst\n rules={[\n {\n type: 'string',\n required: true,\n message: 'Please input your first name',\n whitespace: true,\n },\n ]}\n >\n <Input\n placeholder={'First Name'}\n maxLength={50}\n size={'large'}\n />\n </Item>\n </Col>\n <Col span={12}>\n <Item\n name=\"lastName\"\n label=\"Last Name\"\n validateFirst\n rules={[\n {\n type: 'string',\n required: true,\n message: 'Please input your last name',\n whitespace: true,\n },\n ]}\n >\n <Input\n placeholder={'Last Name'}\n maxLength={50}\n size={'large'}\n />\n </Item>\n </Col>\n </Row>\n <Item\n name=\"email\"\n label=\"Email\"\n validateTrigger={'onBlur'}\n validateFirst\n rules={[\n {\n type: 'string',\n required: true,\n message: 'Please input your email',\n whitespace: true,\n },\n {\n type: 'email',\n message: 'Invalid email address, please check',\n },\n ]}\n >\n <Input placeholder={'Email'} maxLength={50} size={'large'} />\n </Item>\n <Row gutter={20}>\n <Col span={24}>\n <Item\n name=\"company\"\n label=\"Company\"\n validateFirst\n rules={[\n {\n type: 'string',\n required: true,\n message: 'Please input your company',\n whitespace: true,\n },\n ]}\n >\n <Input\n placeholder={'Company'}\n maxLength={200}\n size={'large'}\n />\n </Item>\n </Col>\n {/*<Col span={12}>*/}\n {/* <Item*/}\n {/* name=\"companySize\"*/}\n {/* label=\"Company Size\"*/}\n {/* validateFirst*/}\n {/* rules={[*/}\n {/* {*/}\n {/* type: 'string',*/}\n {/* required: true,*/}\n {/* message: 'Please select your company size',*/}\n {/* whitespace: true,*/}\n {/* },*/}\n {/* ]}*/}\n {/* >*/}\n {/* <Select placeholder={'Company Size'}>*/}\n {/* <Option value={'tiny'}>1-99 employees</Option>*/}\n {/* <Option value={'small'}>100-249 employees</Option>*/}\n {/* <Option value={'medium'}>250-499 employees</Option>*/}\n {/* <Option value={'large'}>500+ employees</Option>*/}\n {/* </Select>*/}\n {/* </Item>*/}\n {/*</Col>*/}\n </Row>\n {/*{!isFromTidy3d() && (*/}\n {/*<Item*/}\n {/* name=\"invitationCode\"*/}\n {/* label=\"Invitation Code\"*/}\n {/* rules={[*/}\n {/* {*/}\n {/* type: 'string',*/}\n {/* required: true,*/}\n {/* message: 'Please input your invitation code',*/}\n {/* whitespace: true,*/}\n {/* },*/}\n {/* ]}*/}\n {/*>*/}\n {/* <Input placeholder={'Invitation Code'} maxLength={50} />*/}\n {/*</Item>*/}\n {/*)}*/}\n <Item\n name=\"countryRegion\"\n // label=\"Country\"\n validateFirst\n rules={[\n {\n type: 'array',\n required: true,\n message: 'Please select your country',\n },\n // () => ({\n // validator(_, value) {\n // const [country, region] = value;\n // if (country.code === 'US' && !region) {\n // return Promise.reject(\n // new Error('Please select your state/region')\n // );\n // }\n // return Promise.resolve();\n // },\n // }),\n ]}\n >\n <CountrySelect needRegion={false} />\n </Item>\n <Tooltip\n title=\"Password must have at least 8 characters, with at least 1 special\n character (!@#$%^&), 1 numeric, 1 lower and 1 upper case letter.\"\n placement=\"right\"\n >\n <input\n autoComplete=\"off\"\n type=\"text\"\n style={{\n position: 'fixed',\n width: 0,\n height: 0,\n border: 'none',\n padding: 0,\n margin: 0,\n }}\n />\n <Item\n name=\"password\"\n label=\"Password\"\n validateFirst\n rules={[\n { required: true, message: 'Please input your password' },\n {\n type: 'string',\n min: 8,\n message: 'Password must have at least 8 characters',\n },\n ({ getFieldValue }) => ({\n validator(_, value) {\n const email = getFieldValue('email');\n if (\n email?.length &&\n value?.length &&\n value.toLowerCase().includes(email.toLowerCase())\n ) {\n return Promise.reject(\n new Error(\n 'Password should not contain current email address'\n )\n );\n }\n if (testPasswordStrength(value) < 4) {\n return Promise.reject(\n new Error(\n 'Please choose stronger password to protect your account'\n )\n );\n }\n return Promise.resolve();\n },\n }),\n ]}\n >\n <Password\n placeholder={'Password'}\n maxLength={50}\n size={'large'}\n />\n </Item>\n </Tooltip>\n <Item noStyle shouldUpdate={true}>\n {({ getFieldValue }) => {\n const passwordValue = getFieldValue('password') || '';\n const passwordStrength = testPasswordStrength(passwordValue);\n return (\n passwordValue.length > 0 && (\n <div className={styles.password_strength_wrapper}>\n <label>Password Strength:</label>\n <PasswordStrength level={passwordStrength} />\n </div>\n )\n );\n }}\n </Item>\n {/*<Item*/}\n {/* name=\"confirmPassword\"*/}\n {/* label=\"Confirm Password\"*/}\n {/* validateFirst*/}\n {/* rules={[*/}\n {/* { required: true, message: 'Please confirm your password' },*/}\n {/* ({ getFieldValue }) => ({*/}\n {/* validator(_, value) {*/}\n {/* if (!value || getFieldValue('password') === value) {*/}\n {/* return Promise.resolve();*/}\n {/* }*/}\n {/* return Promise.reject(*/}\n {/* new Error('Passwords do not match, please check')*/}\n {/* );*/}\n {/* },*/}\n {/* }),*/}\n {/* ]}*/}\n {/*>*/}\n {/* <Password placeholder={'Confirm Password'} maxLength={50} />*/}\n {/*</Item>*/}\n <Item name={'subscribed'} valuePropName=\"checked\">\n <Checkbox>Keep me updated about Tidy3D news</Checkbox>\n </Item>\n <CSSTransition\n classNames=\"agreement\"\n in={agreementAlert}\n timeout={500}\n exit={false}\n onEntered={() => {\n this.agreementAlert(false);\n }}\n >\n <Item>\n <Checkbox\n checked={agreementChecked}\n onChange={e => {\n this.setState({\n agreementChecked: e.target.checked,\n });\n }}\n >\n By checking this box and signing up, you agree to our{' '}\n <a\n href=\"//www.flexcompute.com/term_of_use/\"\n target={'_blank'}\n rel=\"noreferrer\"\n >\n <strong>terms of services</strong>\n </a>{' '}\n and{' '}\n <a\n href=\"//www.flexcompute.com/privacy/\"\n target={'_blank'}\n rel=\"noreferrer\"\n >\n <strong>privacy policy</strong>\n </a>\n .\n </Checkbox>\n </Item>\n </CSSTransition>\n <Item>\n <Button\n id=\"sign-up-with-email\"\n type=\"primary\"\n block\n onClick={e => this.submit(e)}\n loading={loading}\n size={'large'}\n className={'sign_up_btn'}\n // htmlType={'submit'}\n // disabled={!agreementChecked}\n >\n {isCompanyInvite ? 'Sign Up & Accept' : 'Sign Up'}\n </Button>\n </Item>\n {!isCompanyInvite && (\n <div className={styles.footer}>\n <div className={styles.text}>\n Already have an account? \n <Link\n to={{ pathname: '/login', search: location.search }}\n className={styles.link}\n >\n Sign in\n </Link>\n </div>\n {/*<div className={styles.text}>*/}\n {/* To use Flexcompute's Electromagnetic Product, please sign*/}\n {/* up */}\n {/* <a*/}\n {/* href=\"//tidy3d.simulation.cloud/register\"*/}\n {/* className={styles.link}*/}\n {/* >*/}\n {/* here*/}\n {/* </a>*/}\n {/*</div>*/}\n </div>\n )}\n {currentAppConfig && (\n <>\n <Divider>OR</Divider>\n <Item>\n <Button\n id=\"sign-up-with-google\"\n block\n onClick={() => {\n if (!agreementChecked) {\n this.agreementAlert(true);\n return;\n }\n window.location.href = `${\n currentAppConfig.googleLogin\n }&state=${encodeUrlJson({\n referralCode,\n companyInvitationCode,\n invitationCode,\n ref,\n })}`;\n }}\n // disabled={!agreementChecked}\n // className={'google_login'}\n disabled={loading}\n size={'large'}\n icon={\n <img\n src={googleIcon}\n width={14}\n height={14}\n className=\"anticon\"\n alt=\"\"\n />\n }\n >\n Sign up with Google\n </Button>\n </Item>\n {currentAppConfig.appleLogin && (\n <Item>\n <Button\n id=\"sign-up-with-apple\"\n block\n onClick={() => {\n if (!agreementChecked) {\n this.agreementAlert(true);\n return;\n }\n window.location.href = `${\n currentAppConfig.appleLogin\n }&state=${encodeUrlJson({\n referralCode,\n companyInvitationCode,\n invitationCode,\n ref,\n })}`;\n }}\n disabled={loading}\n size={'large'}\n icon={<AppleFilled style={{ color: '#000' }} />}\n >\n Sign up with Apple\n </Button>\n </Item>\n )}\n {currentAppConfig.microsoftLogin && (\n <Item>\n <Button\n id=\"sign-up-with-microsoft\"\n block\n onClick={() => {\n if (!agreementChecked) {\n this.agreementAlert(true);\n return;\n }\n this.props.history.push({\n ...location,\n pathname: '/microsoft_login',\n });\n }}\n disabled={loading}\n // className={'google_login'}\n size={'large'}\n icon={\n <img\n src={microsoftIcon}\n width={14}\n height={14}\n className=\"anticon\"\n alt=\"\"\n />\n }\n >\n Sign up with Microsoft\n </Button>\n </Item>\n )}\n </>\n )}\n </Form>\n </div>\n </div>\n );\n }\n}\n\nexport default withRouter(Tidy3dSignUpPanel);\n","import React, { Component } from 'react';\nimport { notification, Button } from 'antd';\nimport api from '@/services';\n\nexport interface ResendButtonProps {\n email: string;\n}\nexport interface ResendButtonState {\n counter: number;\n loading: boolean;\n}\nexport default class ResendButton extends Component<\n ResendButtonProps,\n ResendButtonState\n> {\n state = {\n counter: 0,\n loading: false,\n };\n loading = (loading = false) => {\n this.setState({\n loading,\n });\n };\n resend = async () => {\n try {\n this.loading(true);\n const { email } = this.props;\n await api.resendEmail({ email });\n this.countDown(60);\n notification.success({\n message: 'Email sent, please check your inbox',\n });\n } catch (e: any) {\n notification.error({\n message: 'Resend email error',\n description: e.message || 'Please try again or contact the admin',\n });\n } finally {\n this.loading(false);\n }\n };\n countDown = (counter: number) => {\n this.setState({ counter }, () => {\n if (counter > 0) {\n setTimeout(() => {\n this.countDown(--counter);\n }, 1000);\n }\n });\n };\n render() {\n const { email } = this.props;\n const { counter, loading } = this.state;\n\n return (\n <Button\n onClick={this.resend}\n type={'link'}\n loading={loading}\n disabled={counter > 0}\n style={{ whiteSpace: 'normal' }}\n >\n {counter > 0 ? (\n <span>Verification email sent ({counter})</span>\n ) : (\n <span>Resend verification email to {email}</span>\n )}\n </Button>\n );\n }\n}\n","import React, { Component } from 'react';\nimport { notification, Modal, Button } from 'antd';\nimport LogRocket from 'logrocket';\nimport AuthLayout from '@/components/AuthLayout';\nimport { RouteComponentProps } from 'react-router-dom';\nimport SignUpPanel from './components/SignUpPanel';\nimport Tidy3dSignUpPanel from './components/Tidy3dSignUpPanel';\nimport api from '@/services';\nimport auth from '../auth';\nimport styles from './index.module.less';\nimport { toUsername, hashPassword } from '@/utils/cognitoHelper';\nimport {\n getAppNameFromUrl,\n // isDev,\n isFromTidy3d,\n // getUrlQueryParams,\n initHubspotForm,\n} from '@/utils/util';\nimport MailEmpty from '../../components/MailEmpty';\nimport ResendButton from '../../components/ResendButton';\n// const CONTACT_LINK = 'https://www.flexcompute.com/contact/';\nexport interface SignUpPageProps extends RouteComponentProps {}\nexport interface SignUpPageState {\n loading: boolean;\n successEmail: string;\n}\nclass SignUpPage extends Component<SignUpPageProps, SignUpPageState> {\n constructor(props: SignUpPageProps) {\n super(props);\n this.state = {\n loading: false,\n successEmail: '',\n };\n }\n\n loading = (loading = false) => {\n this.setState({\n loading: loading,\n });\n };\n onSubmit = async (formData: any) => {\n // console.log('onSubmit', grecaptcha.getResponse());\n const { location } = this.props;\n const { email, invitationCode, password, ...rest } = formData;\n const isTidy3d = isFromTidy3d();\n let hsForm = null;\n try {\n this.loading(true);\n LogRocket.identify(email, {\n name: email,\n email,\n });\n LogRocket.track('sign up start', { email });\n const data = {\n ...rest,\n username: toUsername(email),\n password: hashPassword(password),\n rawPassword: password,\n invitationCode: invitationCode?.trim(),\n params: {\n email,\n // save the whole href to origin, then the querystring can be read in lambda\n 'custom:origin': window.location.href,\n 'custom:app': getAppNameFromUrl(),\n },\n };\n if (isTidy3d) {\n hsForm = initHubspotForm('tidy3d-sign-up-form', {\n email,\n firstName: formData.firstName,\n lastName: formData.lastName,\n company: formData.company,\n country: formData.country?.name,\n });\n }\n await api.sendRegisterEmail(data);\n LogRocket.track('sign up success', { email });\n notification.success({\n message: 'Email sent',\n // message: 'Send signup verification email success',\n // description: `Signup verification email has been sent to ${email}, please check your inbox.`,\n });\n hsForm?.submit();\n this.setState({\n successEmail: email,\n });\n } catch (e: any) {\n LogRocket.track('sign up error', { email, message: e.message });\n if (e.code === 4000000004) {\n // existing user\n Modal.warning({\n title: 'Warning',\n width: 520,\n content: (\n <div>\n <div>\n This email has already been used. If you are the owner of the\n account, please sign in below.\n </div>\n <br />\n <div>\n <Button\n type={'primary'}\n size={'small'}\n onClick={() => {\n window.location.href = `/login${location.search}`;\n }}\n >\n Sign in\n </Button>\n </div>\n </div>\n ),\n });\n }\n // else if (e.code === 1000) {\n // // kyc error\n // Modal.warning({\n // title: 'Warning',\n // width: 520,\n // content: (\n // <>\n // <div>Your account can not be created at this moment,</div>\n // <div>\n // please <a href={CONTACT_LINK}>contact us</a> for further\n // assistance.\n // </div>\n // </>\n // ),\n // });\n // }\n else {\n notification.error({\n message: 'Sign up error',\n // message: 'Send signup verification email error',\n description: e.message || 'Please try again or contact the admin',\n });\n }\n } finally {\n this.loading(false);\n }\n };\n\n render() {\n const isTidy3d = isFromTidy3d();\n const { loading, successEmail } = this.state;\n return (\n <div className={styles.sign_up_page}>\n <AuthLayout>\n {successEmail ? (\n <MailEmpty\n description={\n <div className={styles.success_msg}>\n <div>\n We sent a verification email to your account. Please follow\n the instructions in the email to complete the signup\n process.\n </div>\n <div style={{ marginTop: 12 }}>\n <ResendButton email={successEmail} />\n </div>\n </div>\n }\n />\n ) : (\n <>\n {isTidy3d ? (\n <Tidy3dSignUpPanel onSubmit={this.onSubmit} loading={loading} />\n ) : (\n <SignUpPanel onSubmit={this.onSubmit} loading={loading} />\n )}\n </>\n )}\n {/*<div*/}\n {/* className=\"g-recaptcha\"*/}\n {/* data-sitekey=\"6LfTmHspAAAAACL_tQiMDZuHx7z3D4JQpqpzclyQ\"*/}\n {/*></div>*/}\n </AuthLayout>\n </div>\n );\n }\n}\nexport default auth(SignUpPage);\n","import { createContext } from 'react';\n\nconst IpStatusContext = createContext('');\n\nexport default IpStatusContext;\n","import LogRocket from 'logrocket';\nimport React, { PureComponent } from 'react';\nimport { Spin, Modal } from 'antd';\nimport { LoadingOutlined } from '@ant-design/icons';\nimport { isAndroid } from 'react-device-detect';\nimport { Route, Switch, Redirect, RouteComponentProps } from 'react-router-dom';\nimport loadable from '@loadable/component';\n// import portalConfig from '../../constants/portalConfig';\nimport logo2 from '../../assets/logo2.png';\nimport './index.less';\nimport AndurilLoginPage from '../Anduril/Login';\nimport LoginPage from '../Login';\nimport ChallengePage from '../Challenge';\nimport MicrosoftLoginPage from '../MicrosoftLogin';\nimport ResetPasswordPage from '../ResetPassword';\nimport SignUpPage from '../SignUp';\nimport IpStatusContext from '../../IpStatusContext';\n\nimport api from '@/services';\n\nimport {\n getUser,\n initDocTitleAndDesc,\n isFromAnduril,\n isFromInternal,\n} from '../../utils/util';\n\ninterface HomePageProps extends RouteComponentProps {}\nexport enum EIpStatus {\n HighRisk = 'HighRisk',\n Normal = 'Normal',\n}\ninterface HomePageState {\n isLogRocketInited: boolean;\n ipStatus: EIpStatus | null;\n}\nconst loadableConfig = {\n fallback: (\n <div className=\"loadable_loading_mask\">\n <Spin indicator={<LoadingOutlined style={{ fontSize: 45 }} spin />} />\n </div>\n ),\n};\n// const LoginPage = loadable(() => import('../Login'), loadableConfig);\n// const ResetPasswordPage = loadable(\n// () => import('../ResetPassword'),\n// loadableConfig\n// );\nconst ChangePasswordPage = loadable(\n () => import('../ChangePassword'),\n loadableConfig\n);\n// const SignUpPage = loadable(() => import('../SignUp'), loadableConfig);\n// const SignUpWaitingPage = loadable(() => import('../SignUpWaiting'));\nconst VerifyEmailPage = loadable(\n () => import('../VerifyEmail'),\n loadableConfig\n);\nconst VerifyMfaPage = loadable(() => import('../VerifyMfa'), loadableConfig);\nconst CallbackPage = loadable(() => import('../Callback'), loadableConfig);\n\nexport default class HomePage extends PureComponent<\n HomePageProps,\n HomePageState\n> {\n // UNSAFE_componentWillMount() {\n // this.unlisten = this.props.history.listen(() => {\n // Modal.destroyAll();\n // });\n // }\n state = {\n isLogRocketInited: false,\n ipStatus: null,\n };\n componentDidMount() {\n initDocTitleAndDesc();\n this.initLogRocket();\n }\n UNSAFE_componentWillReceiveProps(nextProps: HomePageProps) {\n if (nextProps.location.pathname !== this.props.location.pathname) {\n initDocTitleAndDesc();\n // this.initLogRocket();\n }\n }\n componentWillUnmount() {\n this.unlisten();\n }\n unlisten = this.props.history.listen(() => {\n Modal.destroyAll();\n });\n async initLogRocket() {\n const { isLogRocketInited } = this.state;\n let ipStatus: EIpStatus | null = this.state.ipStatus;\n if (isLogRocketInited) {\n return;\n }\n if (!ipStatus) {\n try {\n const { data } = await api.checkIp();\n ipStatus = data;\n } catch (e) {\n console.error(e);\n ipStatus = EIpStatus.Normal;\n }\n }\n this.setState(\n {\n ipStatus,\n },\n () => {\n const user = getUser();\n if (\n process.env.REACT_APP_LOGROCKET_ENABLED !== 'true' ||\n // check if android device\n isAndroid ||\n // check if ip illegal\n ipStatus !== EIpStatus.Normal ||\n // check if signup page\n // window.location.pathname.startsWith('/signup') ||\n // check if internal user\n user?.email?.endsWith('@flexcompute.com') ||\n user?.email?.endsWith('@magicloud.io') ||\n // check if from internal app\n isFromInternal()\n ) {\n // console.log('log session off');\n } else {\n LogRocket.init('eplwbm/simcloud-portal');\n LogRocket.getSessionURL(sessionURL => {\n LogRocket.log(`LogRocket session URL: ${sessionURL}`);\n });\n this.setState({\n isLogRocketInited: true,\n });\n // console.log('log session on');\n }\n }\n );\n }\n render() {\n const isAnduril = isFromAnduril();\n const { ipStatus } = this.state;\n // const isAnduril = true;\n return (\n <IpStatusContext.Provider value={ipStatus ?? ''}>\n <div className=\"home_page\">\n {/*<Affix>*/}\n <div className=\"nav_bar\">\n <a href=\"//www.flexcompute.com\" className=\"logo_link\">\n <img\n src={logo2}\n alt=\"Aerodynamics & Electromagnetic Simulation | Flexcompute\"\n width={180}\n />\n </a>\n {/*<a href={portalConfig.homeUrl} className=\"product_link\">*/}\n {/* Select Product*/}\n {/*</a>*/}\n </div>\n {/*</Affix>*/}\n\n {isAnduril ? (\n <Switch>\n <Route path=\"/login\" component={AndurilLoginPage} />\n <Route\n path=\"/callback/:app/:provider?\"\n component={CallbackPage}\n />\n <Redirect\n to={{\n ...this.props.location,\n pathname: '/login',\n }}\n />\n </Switch>\n ) : (\n <Switch>\n <Route path=\"/login\" component={LoginPage} />\n <Route path=\"/challenge\" component={ChallengePage} />\n <Route path=\"/reset_password\" component={ResetPasswordPage} />\n <Route\n path=\"/change_password/:email/:code\"\n component={ChangePasswordPage}\n />\n <Route path=\"/signup\" component={SignUpPage} />\n <Route path=\"/verify/:email/:code\" component={VerifyEmailPage} />\n <Route path=\"/verify_mfa\" component={VerifyMfaPage} />\n <Route\n path=\"/callback/:app/:provider?\"\n component={CallbackPage}\n />\n <Route path=\"/microsoft_login\" component={MicrosoftLoginPage} />\n <Redirect\n to={{\n ...this.props.location,\n pathname: '/login',\n }}\n />\n </Switch>\n )}\n </div>\n </IpStatusContext.Provider>\n );\n }\n}\n","import { Component } from 'react';\nimport { BrowserRouter, Route, Switch } from 'react-router-dom';\n// import loadable from '@loadable/component';\nimport HomePage from './routes/Home';\nimport './App.less';\nimport 'animate.css';\nimport './styles/animation.less';\n\nclass App extends Component {\n render() {\n return (\n <BrowserRouter>\n <Switch>\n <Route path=\"/\" component={HomePage} />\n </Switch>\n </BrowserRouter>\n );\n }\n}\n\nexport default App;\n","const reportWebVitals = onPerfEntry => {\n if (onPerfEntry && onPerfEntry instanceof Function) {\n import('web-vitals').then(({ getCLS, getFID, getFCP, getLCP, getTTFB }) => {\n getCLS(onPerfEntry);\n getFID(onPerfEntry);\n getFCP(onPerfEntry);\n getLCP(onPerfEntry);\n getTTFB(onPerfEntry);\n });\n }\n};\n\nexport default reportWebVitals;\n","import React from 'react';\nimport ReactDOM from 'react-dom';\n\nimport 'normalize.css';\nimport App from './App';\nimport reportWebVitals from './reportWebVitals';\nimport { initDocTitleAndDesc } from './utils/util';\ninitDocTitleAndDesc();\n\nReactDOM.render(\n <React.StrictMode>\n <App />\n </React.StrictMode>,\n document.getElementById('root')\n);\n\n// If you want to start measuring performance in your app, pass a function\n// or send to an analytics endpoint. Learn more: https://bit.ly/CRA-vitals\nreportWebVitals();\n// console.log('log env', process.env.REACT_APP_LOGROCKET_ENABLED);\n\n// console.log('env', process.env.REACT_APP_BUILD_ENV);\n","export default __webpack_public_path__ + \"static/media/logo.615e9c0b.svg\";","export default __webpack_public_path__ + \"static/media/tidy3d_logo.038727a2.svg\";","import React, { Component } from 'react';\nimport classnames from 'classnames';\nimport './index.less';\nimport { isFromFlow360, isFromTidy3d } from '../../utils/util';\nimport logo from '../../assets/logo.svg';\nimport flow360Logo from '../../assets/flow360_logo.svg';\nimport tidy3dLogo from '../../assets/tidy3d_logo.svg';\n\nexport interface AuthLayoutProps {\n isFlow360?: boolean;\n isTidy3d?: boolean;\n showLogo?: boolean;\n style?: React.CSSProperties;\n children?: React.ReactNode;\n}\nexport default class AuthLayout extends Component<AuthLayoutProps> {\n render() {\n const {\n isFlow360: isFlow360Props,\n isTidy3d: isTidy3dProps,\n showLogo = false,\n style,\n } = this.props;\n const isFlow360 = isFlow360Props || isFromFlow360();\n const isTidy3d = isTidy3dProps || isFromTidy3d();\n const isDefault = !isFlow360 && !isTidy3d;\n const { children } = this.props;\n return (\n <>\n <div\n className={classnames('auth_layout', {\n flow360: isFlow360,\n tidy3d: isTidy3d,\n })}\n >\n <div className=\"auth_content_wrapper\">\n {showLogo && (\n <div className=\"logo_wrapper\">\n {isFlow360 && (\n <img src={flow360Logo} alt={'Flow360 logo'} width={204} />\n )}\n {isTidy3d && (\n <img src={tidy3dLogo} alt={'Tidy3d logo'} width={204} />\n )}\n {isDefault && <img src={logo} alt={'Flexcompute logo'} />}\n </div>\n )}\n <div className=\"auth_content\" style={style}>\n {children}\n </div>\n </div>\n </div>\n </>\n );\n }\n}\n","// extracted by mini-css-extract-plugin\nmodule.exports = {\"auth_content_inner_panel\":\"index_auth_content_inner_panel__1QvgT\",\"title\":\"index_title__hnzN-\",\"form\":\"index_form__2zDbr\",\"text\":\"index_text__14FNT\",\"link\":\"index_link__3jsE1\",\"challenge_panel\":\"index_challenge_panel__XSLnn\",\"opt_input\":\"index_opt_input__l1Fnq\",\"input_item\":\"index_input_item__3vMIx\"};","// extracted by mini-css-extract-plugin\nmodule.exports = {\"auth_content_inner_panel\":\"index_auth_content_inner_panel__2Ie4D\",\"title\":\"index_title__Rt0dN\",\"form\":\"index_form__1D7Pz\",\"text\":\"index_text__32657\",\"link\":\"index_link__222-i\",\"login_panel\":\"index_login_panel__PWZTz\"};","// extracted by mini-css-extract-plugin\nmodule.exports = {\"auth_content_inner_panel\":\"index_auth_content_inner_panel__3eJkp\",\"title\":\"index_title__24hX2\",\"form\":\"index_form__3EZ2s\",\"text\":\"index_text__WcaIy\",\"link\":\"index_link__HPOew\",\"sign_up_panel\":\"index_sign_up_panel__13NzT\",\"password_strength_wrapper\":\"index_password_strength_wrapper__1v7gc\"};","// extracted by mini-css-extract-plugin\nmodule.exports = {\"auth_content_inner_panel\":\"index_auth_content_inner_panel__1ccmK\",\"title\":\"index_title__pu_Wx\",\"form\":\"index_form__1Jzyw\",\"text\":\"index_text__2eNhX\",\"link\":\"index_link__26q-x\",\"tidy3d_sign_up_panel\":\"index_tidy3d_sign_up_panel__fTZOE\",\"password_strength_wrapper\":\"index_password_strength_wrapper__3vsRn\"};","// extracted by mini-css-extract-plugin\nmodule.exports = {\"auth_content_inner_panel\":\"index_auth_content_inner_panel__iplFX\",\"title\":\"index_title__3-ZQH\",\"form\":\"index_form__2MPQn\",\"text\":\"index_text__3tCX9\",\"link\":\"index_link__1qwjy\",\"microsoft_login_panel\":\"index_microsoft_login_panel__3no-F\"};","// extracted by mini-css-extract-plugin\nmodule.exports = {\"auth_content_inner_panel\":\"index_auth_content_inner_panel__2Vmfy\",\"title\":\"index_title__-sXyO\",\"form\":\"index_form__17qN5\",\"text\":\"index_text__2sn3_\",\"link\":\"index_link__29WNZ\",\"reset_password_panel\":\"index_reset_password_panel__UdLrq\"};","import { isFromFlow360, isFromTidy3d } from '../utils/util';\n\nexport interface AppConfigMap {\n flow360: AppConfig;\n tidy3d: AppConfig;\n}\nexport interface AppConfig {\n redirectUrl: string;\n googleLogin: string;\n googleLogout: string;\n microsoftLogin: string;\n appleLogin: string;\n anduril: {\n redirectUrl: string;\n loginUrl: string;\n };\n}\nconst dev: AppConfigMap = {\n flow360: {\n redirectUrl: 'https://flow360.dev-simulation.cloud',\n googleLogin: `https://sso.dev-simulation.cloud/oauth2/authorize?identity_provider=Google&response_type=CODE&client_id=757hm5uf56qos64jo8ml6asd0g&scope=email%20openid%20profile&prompt=select_account&redirect_uri=https://my.dev-simulation.cloud/callback/flow360`,\n googleLogout: `https://sso.dev-simulation.cloud/logout?client_id=757hm5uf56qos64jo8ml6asd0g&logout_uri=`,\n appleLogin: '',\n microsoftLogin: '',\n anduril: {\n redirectUrl: 'https://anduril-flow360.dev-simulation.cloud',\n loginUrl: `https://sso.dev-simulation.cloud/oauth2/authorize?client_id=3juubqouhhf354ai4b79tcal2j&response_type=code&scope=email+openid+profile&redirect_uri=https://anduril-my.dev-simulation.cloud/callback/flow360/anduril`,\n },\n },\n tidy3d: {\n redirectUrl: 'https://tidy3d.dev-simulation.cloud',\n googleLogin: `https://sso.dev-simulation.cloud/oauth2/authorize?identity_provider=Google&response_type=CODE&client_id=1l5st1cgo1iee522neqbn5hbc9&scope=email%20openid%20profile&prompt=select_account&redirect_uri=https://my.dev-simulation.cloud/callback/tidy3d`,\n googleLogout: `https://sso.dev-simulation.cloud/logout?client_id=1l5st1cgo1iee522neqbn5hbc9&logout_uri=`,\n appleLogin: `https://sso.dev-simulation.cloud/oauth2/authorize?identity_provider=SignInWithApple&client_id=1l5st1cgo1iee522neqbn5hbc9&response_type=code&scope=email+openid+profile&prompt=select_account&redirect_uri=https://my.dev-simulation.cloud/callback/tidy3d`,\n microsoftLogin:\n 'https://sso.dev-simulation.cloud/oauth2/authorize?identity_provider=Microsoft&response_type=CODE&client_id=1l5st1cgo1iee522neqbn5hbc9&scope=email%20openid%20profile&prompt=select_account&redirect_uri=https://my.dev-simulation.cloud/callback/tidy3d',\n anduril: {\n redirectUrl: '',\n loginUrl: '',\n },\n },\n};\nconst uat: AppConfigMap = {\n flow360: {\n redirectUrl: 'https://uat-flow360.simulation.cloud',\n googleLogin: `https://sso.simulation.cloud/oauth2/authorize?identity_provider=Google&response_type=CODE&client_id=2oltenfma8olqqb9ecpsgl92lb&scope=email%20openid%20profile&prompt=select_account&redirect_uri=https://uat-my.simulation.cloud/callback/flow360`,\n googleLogout: `https://sso.simulation.cloud/logout?client_id=2oltenfma8olqqb9ecpsgl92lb&logout_uri=`,\n appleLogin: '',\n microsoftLogin: '',\n anduril: {\n redirectUrl: 'https://anduril-uat-flow360.simulation.cloud',\n loginUrl: `https://sso.simulation.cloud/oauth2/authorize?client_id=41ut0khprdcacuc5cfedl4s3hh&response_type=code&scope=email+openid+profile&redirect_uri=https://anduril-uat-my.simulation.cloud/callback/flow360/anduril`,\n },\n },\n tidy3d: {\n redirectUrl: 'https://uat-tidy3d.simulation.cloud',\n googleLogin:\n 'https://sso.simulation.cloud/oauth2/authorize?identity_provider=Google&response_type=CODE&client_id=7v1iulgpsnuc85k8hlv32sn7qs&scope=email%20openid%20profile&prompt=select_account&redirect_uri=https://uat-my.simulation.cloud/callback/tidy3d',\n googleLogout:\n 'https://sso.simulation.cloud/logout?client_id=7v1iulgpsnuc85k8hlv32sn7qs&logout_uri=',\n appleLogin:\n 'https://sso.simulation.cloud/oauth2/authorize?identity_provider=SignInWithApple&client_id=7v1iulgpsnuc85k8hlv32sn7qs&response_type=code&scope=email+openid+profile&prompt=select_account&redirect_uri=https://uat-my.simulation.cloud/callback/tidy3d',\n microsoftLogin: `https://sso.simulation.cloud/oauth2/authorize?identity_provider=Microsoft&response_type=CODE&client_id=2oltenfma8olqqb9ecpsgl92lb&scope=email%20openid%20profile&prompt=select_account&redirect_uri=https://uat-my.simulation.cloud/callback/flow360`,\n anduril: {\n redirectUrl: '',\n loginUrl: '',\n },\n },\n};\nconst uat2: AppConfigMap = {\n flow360: {\n redirectUrl: 'https://flow360.uat-simulation.cloud',\n googleLogin: `https://sso.uat-simulation.cloud/oauth2/authorize?identity_provider=Google&response_type=CODE&client_id=1qn1ohmjth9eed3gpci5huq4f4&scope=email%20openid%20profile&prompt=select_account&redirect_uri=https://my.uat-simulation.cloud/callback/flow360`,\n googleLogout: `https://sso.uat-simulation.cloud/logout?client_id=1qn1ohmjth9eed3gpci5huq4f4&logout_uri=`,\n appleLogin: '',\n microsoftLogin: '',\n anduril: {\n redirectUrl: 'https://anduril-flow360.uat-simulation.cloud',\n loginUrl: `https://sso.uat-simulation.cloud/oauth2/authorize?client_id=24oodmcut9qcrbiij0i274cnrf&response_type=code&scope=email+openid+profile&redirect_uri=https://anduril-my.uat-simulation.cloud/callback/flow360/anduril`,\n },\n },\n tidy3d: {\n redirectUrl: 'https://tidy3d.uat-simulation.cloud',\n googleLogin: `https://sso.uat-simulation.cloud/oauth2/authorize?identity_provider=Google&response_type=CODE&client_id=6qq60ahpvp5ooglmofoffb5osi&scope=email%20openid%20profile&prompt=select_account&redirect_uri=https://my.uat-simulation.cloud/callback/tidy3d`,\n googleLogout: `https://sso.uat-simulation.cloud/logout?client_id=6qq60ahpvp5ooglmofoffb5osi&logout_uri=`,\n appleLogin: `https://sso.uat-simulation.cloud/oauth2/authorize?identity_provider=SignInWithApple&client_id=6qq60ahpvp5ooglmofoffb5osi&response_type=code&scope=email+openid+profile&prompt=select_account&redirect_uri=https://my.uat-simulation.cloud/callback/tidy3d`,\n microsoftLogin: `https://sso.uat-simulation.cloud/oauth2/authorize?identity_provider=Microsoft&response_type=CODE&client_id=6qq60ahpvp5ooglmofoffb5osi&scope=email%20openid%20profile&prompt=select_account&redirect_uri=https://my.uat-simulation.cloud/callback/tidy3d`,\n anduril: {\n redirectUrl: '',\n loginUrl: '',\n },\n },\n};\nconst prod: AppConfigMap = {\n flow360: {\n redirectUrl: 'https://flow360.simulation.cloud',\n googleLogin: `https://sso.simulation.cloud/oauth2/authorize?identity_provider=Google&response_type=CODE&client_id=2oltenfma8olqqb9ecpsgl92lb&scope=email%20openid%20profile&prompt=select_account&redirect_uri=https://my.simulation.cloud/callback/flow360`,\n googleLogout: `https://sso.simulation.cloud/logout?client_id=2oltenfma8olqqb9ecpsgl92lb&logout_uri=`,\n microsoftLogin: '',\n appleLogin: '',\n anduril: {\n redirectUrl: 'https://anduril-flow360.simulation.cloud',\n loginUrl: `https://sso.simulation.cloud/oauth2/authorize?client_id=41ut0khprdcacuc5cfedl4s3hh&response_type=code&scope=email+openid+profile&redirect_uri=https://anduril-my.simulation.cloud/callback/flow360/anduril`,\n },\n },\n tidy3d: {\n redirectUrl: 'https://tidy3d.simulation.cloud',\n googleLogin:\n 'https://sso.simulation.cloud/oauth2/authorize?identity_provider=Google&response_type=CODE&client_id=7v1iulgpsnuc85k8hlv32sn7qs&scope=email%20openid%20profile&prompt=select_account&redirect_uri=https://my.simulation.cloud/callback/tidy3d',\n googleLogout:\n 'https://sso.simulation.cloud/logout?client_id=7v1iulgpsnuc85k8hlv32sn7qs&logout_uri=',\n appleLogin:\n 'https://sso.simulation.cloud/oauth2/authorize?identity_provider=SignInWithApple&client_id=7v1iulgpsnuc85k8hlv32sn7qs&response_type=code&scope=email+openid+profile&prompt=select_account&redirect_uri=https://my.simulation.cloud/callback/tidy3d',\n microsoftLogin:\n 'https://sso.simulation.cloud/oauth2/authorize?identity_provider=Microsoft&response_type=CODE&client_id=7v1iulgpsnuc85k8hlv32sn7qs&scope=email%20openid%20profile&prompt=select_account&redirect_uri=https://my.simulation.cloud/callback/tidy3d',\n anduril: {\n redirectUrl: '',\n loginUrl: '',\n },\n },\n};\n\nexport function getAppConfigMap(): AppConfigMap {\n const BUILD_ENV = process.env.REACT_APP_BUILD_ENV;\n if (BUILD_ENV === 'prod') {\n return prod;\n } else if (BUILD_ENV === 'uat') {\n return uat;\n } else if (BUILD_ENV === 'uat2') {\n return uat2;\n }\n return dev;\n}\nexport function getAppConfig(app: string): AppConfig | null {\n const appConfigMap = getAppConfigMap();\n return appConfigMap[app as keyof typeof appConfigMap];\n}\nexport function getCurrentAppConfig(): AppConfig | null {\n const appConfigMap = getAppConfigMap();\n if (isFromFlow360()) {\n return appConfigMap.flow360;\n }\n if (isFromTidy3d()) {\n return appConfigMap.tidy3d;\n }\n return null;\n}\n","// extracted by mini-css-extract-plugin\nmodule.exports = {\"auth_content_inner_panel\":\"index_auth_content_inner_panel__3IBTL\",\"title\":\"index_title__2N75m\",\"form\":\"index_form__b4-iv\",\"text\":\"index_text__3FgGw\",\"link\":\"index_link__2rE7R\",\"anduril_login_page\":\"index_anduril_login_page__1O-tN\",\"login_panel\":\"index_login_panel__1mS3j\",\"welcome\":\"index_welcome__1BsC9\",\"intro\":\"index_intro__2Tysi\",\"sign_in_btn\":\"index_sign_in_btn__36EbD\"};"],"sourceRoot":""}