1;!function(){try { var e="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof global?global:"undefined"!=typeof window?window:"undefined"!=typeof self?self:{},n=(new e.Error).stack;n&&((e._debugIds|| (e._debugIds={}))[n]="496db9af-0939-e2e0-17ae-e2e5c7c1b5b7")}catch(e){}}(); 2(globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,929504,e=>{"use strict";var r=e.i(843476),s=e.i(343794);e.s(["default",0,function({size:e,children:l,...t}){return(0,r.jsx)("button",{className:(0,s.default)("flex items-center justify-center","border border-gray-200 rounded-full","text-gray-500","bg-gray-0 hover:bg-gray-100 hover:cursor-pointer disabled:bg-gray-100"),style:{width:e,height:e},...t,children:l})}])},463744,712028,e=>{"use strict";var r=e.i(843476),s=e.i(693936),l=e.i(522042),t=e.i(178815),a=e.i(18989),i=e.i(149666);e.s(["default",0,function({isSubmitDisabled:e,isLoading:o}){let{googleSignIn:n}=(0,a.useGoogleSignIn)(),u=(0,s.useGoogleLogin)({onSuccess:e=>n({code:e.code}),flow:"auth-code",scope:"openid email profile"});return(0,r.jsx)(i.Button,{type:"button",full:!0,color:"gray",variant:"outline",disabled:e||o,onClick:e=>{e.preventDefault(),u()},leftIcon:(0,r.jsx)(l.default,{iconName:t.SocialIcons.GOOGLE_COLORFUL,className:"w-4 h-4"}),className:"text-nowrap",children:"Google"})}],463744);var o=e.i(343794);e.s(["default",0,function({className:e,...s}){return(0,r.jsx)("span",{className:(0,o.default)("block border border-gray-200 h-[0px] w-full","max-w-full box-border",e),...s})}],712028)},961065,e=>{"use strict";var r=e.i(843476),s=e.i(149666),l=e.i(693936),t=e.i(522016),a=e.i(618566),i=e.i(271645),o=e.i(653145),n=e.i(463744),u=e.i(880202),d=e.i(499683),c=e.i(745906),m=e.i(599115);let g=d.object().shape({email:m.emailValidation,password:d.string().required("Enter your password")});var f=e.i(954616),x=e.i(303071),p=e.i(975006);e.i(524270);var h=e.i(403079),b=e.i(839865),y=e.i(557927),w=e.i(690113),j=e.i(549643),v=e.i(712028),S=e.i(228231),N=e.i(18989),L=e.i(137815),P=e.i(833845);e.s(["default",0,function(){let e=(0,i.useRef)(null),d=(0,a.useSearchParams)(),m=d.get("next")??void 0,E=d.get("error");(0,i.useEffect)(()=>{if("session_expired"!==E)return;(0,p.default)({message:"Your session has expired. Please sign in again.",type:"error"});let e=new URL(window.location.href);e.searchParams.delete("error"),window.history.replaceState(null,"",e.toString())},[E]);let{control:C,isSubmitDisabled:O,handleSubmitLogInForm:A}=(()=>{let e=(0,c.useAuthEmailStore)(e=>e.email),{control:r,handleSubmit:s,formState:l}=(0,o.useForm)({mode:"all",reValidateMode:"onBlur",shouldFocusError:!0,defaultValues:{email:e,password:""},resolver:(0,u.yupResolver)(g)});return{control:r,handleSubmitLogInForm:s,isSubmitDisabled:!l.isValid||l.isSubmitting}})(),{isAuthorized:G}=(0,L.default)(),{handleLogin:I,isLoading:_}=(e=>{let{auth:r}=(0,x.useApi)(),s=(0,b.useUserStore)(e=>e.setUser),l=(0,c.useAuthEmailStore)(e=>e.clearEmail),{parseNextStep:t}=(0,w.useParseNextStep)(),{sendGAEvent:a,EVENT_ACTIONS:o,EVENT_CATEGORIES:n}=(0,y.useGoogleAnalytics)(),{trackUserLogin:u,trackLoginFormSubmit:d,identify:m}=(0,h.usePostHogAnalytics)(),[g,j]=(0,i.useState)(void 0),{mutate:v,isPending:S}=(0,f.useMutation)({mutationKey:["login"],mutationFn:({email:e,password:s})=>(j(e),d({login_method:"email"}),r.login({email:e,password:s})),onSuccess:r=>{s(r.user),l(),a(n.userAuth,o.signUpWithEmail),u({login_method:"email",email:r.user?.email}),r.user?.email&&m(r.user.email,{email:r.user.email}),t(g,e)},onError:()=>(0,p.default)({message:"Incorrect email or password. Please try again.",type:"error"})});return{handleLogin:v,isLoading:S}})(m),F=A(e=>I(e)),{googleSignIn:R,isLoading:T}=(0,N.useGoogleSignIn)(m);(0,l.useGoogleOneTapLogin)({onSuccess:async e=>R({id_token:e.credential}),use_fedcm_for_prompt:!0,disabled:G});let U=T||_;return(0,S.useCloseKeyboardOnScroll)({ignoreRefs:[e]}),(0,r.jsx)(r.Fragment,{children:(0,r.jsxs)("form",{ref:e,className:"flex w-full flex-col",onSubmit:F,"aria-live":"polite","aria-busy":U?"true":"false",children:[(0,r.jsxs)("div",{className:"flex flex-col gap-y-2",children:[(0,r.jsx)(o.Controller,{name:"email",control:C,render:({field:e,fieldState:s})=>(0,r.jsx)(j.TextInput,{...e,label:"Email",disabled:U,floatingLabel:!0,type:"email",autoComplete:"email",error:s.error?.message??null})}),(0,r.jsx)(o.Controller,{name:"password",control:C,render:({field:e,fieldState:s})=>(0,r.jsx)(j.TextInput,{...e,label:"Password",disabled:U,floatingLabel:!0,isPassword:!0,autoComplete:"current-password",error:s.error?.message??null})}),(0,r.jsx)(s.Button,{full:!0,size:"lg",variant:"solid",color:"primary",type:"submit",disabled:O||U,className:"text-nowrap",children:"Login"})]}),(0,r.jsx)(t.default,{href:P.routes.auth.resetPassword,className:"mt-3 text-body lg:text-body-lg text-primary underline w-fit self-end font-normal",children:"Forgot Password?"}),(0,r.jsxs)("div",{className:"flex items-center gap-x-3 mt-4",children:[(0,r.jsx)(v.default,{}),(0,r.jsx)("span",{className:"w-fit text-body-sm lg:text-body-sm-lg text-nowrap text-gray-300 font-normal",children:"Or login with"}),(0,r.jsx)(v.default,{})]}),(0,r.jsx)("div",{className:"w-full mt-4 lg:mt-10",children:(0,r.jsx)(n.default,{isLoading:U})}),(0,r.jsxs)("p",{className:"self-center mt-8 space-x-1 font-normal",children:[(0,r.jsx)("span",{className:"text-gray-300",children:"Donât have an account?"}),(0,r.jsx)(t.default,{href:P.routes.auth.register(m),className:"text-primary underline-from-center-tiny w-fit",children:"Sign up"})]})]})})}],961065)}]); 3 4//# debugId=496db9af-0939-e2e0-17ae-e2e5c7c1b5b7
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.