1!function(){try{var e="u">typeof window?window:"u">typeof global?global:"u">typeof globalThis?globalThis:"u">typeof self?self:{},s=(new e.Error).stack;s&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[s]="7459ae15-7ffc-4480-88eb-36041b468680",e._sentryDebugIdIdentifier="sentry-dbid-7459ae15-7ffc-4480-88eb-36041b468680")}catch(e){}}(),(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[3443],{17440:(e,s,r)=>{(window.__NEXT_P=window.__NEXT_P||[]).push(["/auth/signin",function(){return r(46290)}])},46290:(e,s,r)=>{"use strict";r.r(s),r.d(s,{default:()=>_});var t,o=r(37876),n=r(78974),l=r(10553),a=r(54587),i=r.n(a),c=r(48230),d=r.n(c),u=r(89099),m=r(14232),f=r(88992),h=r(62155),x=r(87784),g=r(21434),b=r(34401),p=r(76392),w=r(31504),y=r(11946);let j=(0,b.Ay)(p.A)({height:"4px"}),v=()=>{let e=(0,u.useRouter)(),[s,r]=(0,m.useState)(!1);return(0,m.useEffect)(()=>{let s=(e,s)=>!s?.shallow&&r(!0),t=(e,s)=>!s?.shallow&&r(!1),o=(e,s,r)=>t(s,r);return e.events.on("routeChangeStart",s),e.events.on("routeChangeComplete",t),e.events.on("routeChangeError",o),()=>{e.events.off("routeChangeStart",s),e.events.off("routeChangeComplete",t),e.events.off("routeChangeError",o)}}),(0,o.jsx)(w.A,{in:s,children:(0,o.jsx)(y.A,{position:"absolute",top:0,left:0,right:0,zIndex:e=>e.zIndex.appBar+1,children:(0,o.jsx)(j,{})})})};var N=r(78308);r(13883);var k=((t={}).Google="google",t.Facebook="facebook",t.LinkedIn="linkedin",t.Credentials="credentials",t),C=r(44089);r(38248);let S=e=>e&&e.startsWith("/")&&!e.startsWith("//")?e:"/";function _({...e}){let s=(0,N.y)(),{register:r,handleSubmit:t,reset:a,formState:c}=(0,f.mN)({defaultValues:{email:"",password:""}}),[b,p]=(0,m.useState)(!1),[w,y]=(0,m.useState)(!1),[j,I]=(0,m.useState)(""),E=(0,u.useRouter)(),{data:A}=(0,l.useSession)(),F=(0,n.m)(E.query.callbackUrl)??"",D=(0,n.m)(E.query.message)??"";(0,m.useEffect)(()=>{A&&(w||(A.is_staff?E.push("/admin"):E.push(S(F)),y(!0)))},[A,w,E]),(0,m.useEffect)(()=>{D&&I(D)},[D]);let P=async(e,s)=>{s?.preventDefault,p(!0);let r=await (0,l.signIn)(k.Credentials,{redirect:!1,email:e.email,password:e.password});if(r&&r.ok){E.push(S(F)),y(!0);return}r&&r.error&&I(r.error)},$=async e=>{let s=await (0,l.signIn)(`${e}`);if(s&&s.ok){E.push(S(F)),y(!0);return}s&&s.error&&I("Somethin went wrong with your login - Please try again later")},q=(({isSsoEnabled:e})=>e?C.PS:[])({isSsoEnabled:s}),z=q.filter(e=>e!==k.Credentials).length>0;return(0,o.jsxs)(o.Fragment,{children:[(0,o.jsx)(v,{}),(0,o.jsxs)("div",{className:"flex min-h-full flex-col justify-center py-12 sm:px-6 lg:px-8",children:[(0,o.jsxs)("div",{className:"sm:mx-auto sm:w-full sm:max-w-md",children:[(0,o.jsx)("div",{className:"mt-2 flex justify-center",children:(0,o.jsx)(d(),{href:"/",children:(0,o.jsx)(i(),{className:"mx-auto",height:75,width:100,src:"/images/riabizwbg.png",alt:"RIABiz logo"})})}),(0,o.jsx)("h2",{className:"mt-6 text-center text-3xl font-bold tracking-tight text-gray-900",children:"Sign in to your account"})]}),(0,o.jsxs)("div",{className:"mt-2 sm:mx-auto sm:w-full sm:max-w-md",children:[j&&(0,o.jsx)("span",{className:"text-red-500",children:j}),(0,o.jsxs)("div",{className:"bg-white py-8 px-4 shadow sm:rounded-lg sm:px-10",children:[(0,o.jsxs)("form",{className:"space-y-6",onSubmit:t(P),children:[(0,o.jsxs)("div",{children:[(0,o.jsx)("label",{htmlFor:"email",className:`block text-sm font-medium text-gray-700 ${j?"text-red-500":""}`,children:"Email address (all lowercase)"}),(0,o.jsx)("div",{className:"mt-1",children:(0,o.jsx)("input",{...r("email"),type:"email",autoComplete:"email",required:!0,className:`block w-full appearance-none rounded-md border border-gray-300 px-3 py-2 placeholder-gray-400 shadow-sm focus:border-blue-500 focus:outline-none focus:ring-blue-500 sm:text-sm ${j?"border-red-500 focus:border-red-500 focus:ring-red-500":""}`})})]}),(0,o.jsxs)("div",{children:[(0,o.jsx)("label",{htmlFor:"password",className:`block text-sm font-medium text-gray-700 ${j?"text-red-500":""}`,children:"Password"}),(0,o.jsx)("div",{className:"mt-1",children:(0,o.jsx)("input",{...r("password"),type:"password",autoComplete:"current-password",required:!0,className:`block w-full appearance-none rounded-md border border-gray-300 px-3 py-2 placeholder-gray-400 shadow-sm focus:border-blue-500 focus:outline-none focus:ring-blue-500 sm:text-sm ${j?"border-red-500 focus:border-red-500 focus:ring-red-500":""}`})})]}),(0,o.jsxs)("div",{className:"flex items-center justify-between",children:[(0,o.jsxs)("div",{className:"flex items-center",children:[(0,o.jsx)("input",{id:"remember-me",name:"remember-me",type:"checkbox",className:"h-4 w-4 roun
1ded border-gray-300 text-blue-600 focus:ring-blue-500"}),(0,o.jsx)("label",{htmlFor:"remember-me",className:"ml-2 block text-sm text-gray-900",children:"Remember me"})]}),(0,o.jsx)("div",{className:"text-sm",children:(0,o.jsx)(d(),{href:"/auth/forgot-password",passHref:!0,children:(0,o.jsx)("span",{className:"font-medium text-blue-600 hover:text-blue-500",children:"Forgot your password?"})})})]}),(0,o.jsx)("div",{children:(0,o.jsx)("button",{type:"submit",className:"flex w-full justify-center rounded-md border border-transparent bg-blue-600 py-2 px-4 text-sm font-medium text-white shadow-sm hover:bg-blue-700 hover:cursor-pointer focus:outline-none focus:ring-2 focus:ring-blue-500 focus:ring-offset-2",children:"Sign in"})})]}),q.includes(k.Credentials)&&(0,o.jsx)("div",{className:"text-sm text-center mt-7",children:(0,o.jsx)(d(),{href:"/auth/signup",passHref:!0,children:(0,o.jsx)("span",{className:"font-medium text-blue-600 hover:text-blue-500",children:"Don't have an account with us? Sign up here"})})}),z&&(0,o.jsxs)("div",{className:"flex items-center mt-4 mb-4",children:[(0,o.jsx)("div",{className:"w-full border-t border-gray-300"}),(0,o.jsx)("div",{className:"mx-4 text-gray-500",children:"or"}),(0,o.jsx)("div",{className:"w-full border-t border-gray-300"})]}),(0,o.jsxs)("div",{className:"flex flex-col mt-4 gap-2 justify-center",children:[q.includes(k.Google)&&(0,o.jsxs)("button",{onClick:()=>$(k.Google),className:"flex items-center justify-center bg-white text-gray-700 px-4 py-2 rounded-lg font-semibold shadow-md hover:shadow-lg focus:outline-none focus:ring-2 focus:ring-gray-500 focus:ring-offset-2 focus:ring-offset-white hover:cursor-pointer",children:[(0,o.jsx)(h.A,{className:"mr-2"})," Sign in with Google"]}),q.includes(k.Facebook)&&(0,o.jsxs)("button",{onClick:()=>$(k.Facebook),className:"text-left flex items-center justify-center bg-blue-600 text-white px-4 py-2 rounded-lg font-semibold shadow-md hover:bg-blue-700 focus:outline-none focus:ring-2 focus:ring-blue-500 focus:ring-offset-2 focus:ring-offset-white hover:cursor-pointer",children:[(0,o.jsx)(x.A,{className:"mr-2"})," Sign in with Facebook"]}),q.includes(k.LinkedIn)&&(0,o.jsxs)("button",{onClick:()=>$(k.LinkedIn),className:"flex items-center justify-center bg-blue-800 text-white px-4 py-2 rounded-lg font-semibold shadow-md hover:bg-blue-900 focus:outline-none focus:ring-2 focus:ring-blue-700 focus:ring-offset-2 focus:ring-offset-white hover:cursor-pointer",children:[(0,o.jsx)(g.A,{className:"mr-2"})," Sign in with LinkedIn"]})]})]})]})]})]})}},78308:(e,s,r)=>{"use strict";r.d(s,{y:()=>t});let t=()=>!1},78974:(e,s,r)=>{"use strict";r.d(s,{m:()=>t});let t=e=>Array.isArray(e)?e[0]:e}},e=>{e.O(0,[4587,8992,6788,3883,636,6593,8792],()=>e(e.s=17440)),_N_E=e.O()}]);
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.