1(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[7616],{8378:function(e,n,i){(window.__NEXT_P=window.__NEXT_P||[]).push(["/signup",function(){return i(80095)}])},80095:function(e,n,i){"use strict";i.r(n);var r=i(24246),s=i(27378),a=i(86677),l=i(44478),t=i(51209),o=i(19718),u=i(10957),d=i(36118),c=i(44600),m=i(82605),g=i(1733),x=i(18077),h=i(38712),p=i(58034),f=i(313),j=i(24416),v=i(67475),w=i(91659),_=i(40948),b=i(4766),C=i(22013),y=i(75844),N=i(79913),k=i(46281),z=i(26333),S=i(52268),D=i(93232),E=i(64168);n.default=()=>{var e,n,i,I;let O=(0,a.useRouter)(),X=(0,b.useUser)(),{error:T}=(0,b.useSessionContext)(),q=(0,t.p)();null==O||null===(e=O.query)||void 0===e||e.token;let Z=null==O?void 0:null===(n=O.query)||void 0===n?void 0:n.auth,G=null==O?void 0:null===(i=O.query)||void 0===i?void 0:i.first_time_user_login_disabled,[L,P]=(0,s.useState)(),{loading:A,setLoading:H,err:M,setErr:W}=(0,y.Z)(),{loading:K,setLoading:U,err:F,setErr:V}=(0,y.Z)();(0,C.wW)();let $=async()=>{X?U(!0):q({status:"warning",title:"Something went wrong",description:"Token, user, or invite not found"})},[B,J]=(0,s.useState)({firstName:(null==X?void 0:X.given_name)||"",lastName:(null==X?void 0:X.family_name)||""}),R=e=>{let n=e.target.value;J({...B,[e.target.name]:n})},Q=(0,o.q)(),Y=(0,D.z)();return(0,r.jsxs)(z.Z,{withContainer:!0,children:[" ",(0,r.jsx)(u.M,{justify:"start",alignItems:"start",dir:"H",flexDir:{base:"column",md:"row"},gridGap:5,color:"gray.700",_dark:{color:"gray.100"},children:A?(0,r.jsx)(d.$,{}):(0,r.jsxs)(c.K,{spacing:12,children:[(0,r.jsxs)(c.K,{spacing:3,children:[(0,r.jsxs)(m.X,{size:"lg",children:["Create an account on"," ",(0,r.jsx)(N.ZP,{display:"inline",size:"lg",children:"Sharehouse"})]}),(0,r.jsxs)(g.k,{flexDir:{base:"column",md:"row"},align:{base:"left",md:"center"},children:[(0,r.jsx)(m.X,{size:"sm",mr:2,children:"Join thousands of Australians, and sign up today."}),(0,r.jsx)(x.H,{max:10,opacity:.9,children:null==L?void 0:null===(I=L.referringHouse)||void 0===I?void 0:I.houseMates.map(e=>(0,r.jsx)(h.q,{name:(null==e?void 0:e.firstName)+" "+(null==e?void 0:e.lastName)}))})]})]}),"true"===Z&&X?(0,r.jsx)(u.M,{bg:"gray.50",_dark:{bg:"gray.700"},p:{base:6,md:8},rounded:"2xl",boxShadow:"xl",justifyContent:"space-between",flexDir:{base:"column",md:"row"},w:{base:"100%",md:"550px"},children:(0,r.jsxs)(w.g,{spacing:4,w:"100%",align:"start",children:[(0,r.jsx)(m.X,{size:"lg",children:"Confirm your details"}),(0,r.jsx)(_.I,{name:"email",value:X.email,isDisabled:!0,onChange:R}),(0,r.jsx)(_.I,{name:"firstName",placeholder:"First name",defaultValue:null==X?void 0:X.given_name,value:B.firstName,onChange:R}),(0,r.jsx)(_.I,{name:"lastName",placeholder:"Last name",defaultValue:null==X?void 0:X.family_name,value:B.lastName,onChange:R}),(0,r.jsx)(f.z,{colorScheme:"green",marginTop:"30px",isLoading:K,onClick:$,children:"Confirm details and sign up"})]})}):(0,r.jsxs)(c.K,{bg:"gray.50",_dark:{bg:"gray.700"},p:8,rounded:"2xl",boxShadow:"xl",w:{base:"min-content",md:"550px"},flexDir:"column",spacing:5,children:[G&&(0,r.jsxs)(p.xu,{w:"100%",children:[(0,r.jsx)(m.X,{size:"sm",children:"First time logging in?"}),(0,r.jsx)(m.X,{size:"sm",fontWeight:"normal",children:"Creating an account by choosing an option below"})]}),(0,r.jsxs)(g.k,{w:"100%",justifyContent:"space-between",flexDir:{base:"column",md:"row"},children:[(0,r.jsxs)(f.z,{color:"currentColor",variant:"outline",as:"a",onClick:()=>E.ZP.auth.signInWithOAuth({provider:"google"}).then(e=>{Y.identify(e.user.id),new Date(e.user.created_at)>new Date(Date.now()-6e4)&&Y.track("New User")}),children:[(0,r.jsx)(k.GoogleIcon,{mr:3}),(0,r.jsx)(j.x,{children:"Sign up with Google"})]}),(0,r.jsx)(v.i,{orientation:{base:"horizontal",md:"vertical"},color:"whtie",height:"20px"}),(0,r.jsxs)(f.z,{color:"currentColor",variant:"outline",onClick:Q.onToggle,children:[(0,r.jsx)(l.q,{size:"sm",mr:3}),(0,r.jsx)(j.x,{children:"Sign up with phone"})]})]})]})]})}),(0,r.jsx)(S.Z,{initialTabIndex:1,isSignUp:!0,bodyText:"Create an account",isOpen:Q.isOpen,onClose:Q.onClose})]})}},18077:function(e,n,i){"use strict";i.d(n,{H:function(){return m}});var r=i(38712),s=i(96470),a=i(71181),l=i(53739),t=i(44346),o=i(613),u=i(41837),d=i(27378),c=i(24246),m=(0,s.G)(function(e,n){let i=(0,a.jC)("Avatar",e),{children:s,borderColor:m,max:g,spacing:
1x="-0.75rem",borderRadius:h="full",...p}=(0,l.Lr)(e),f=(0,u.W)(s),j=null!=g?f.slice(0,g):f,v=null!=g?f.length-g:0,w=j.reverse().map((n,i)=>{var r;let s={marginEnd:0===i?0:x,size:e.size,borderColor:null!=(r=n.props.borderColor)?r:m,showBorder:!0};return(0,d.cloneElement)(n,function(e){let n=Object.assign({},e);for(let e in n)void 0===n[e]&&delete n[e];return n}(s))}),_={display:"flex",alignItems:"center",justifyContent:"flex-end",flexDirection:"row-reverse",...i.group},b={borderRadius:h,marginStart:x,...r.O,...i.excessLabel};return(0,c.jsxs)(t.m.div,{ref:n,role:"group",__css:_,...p,className:(0,o.cx)("chakra-avatar__group",e.className),children:[v>0&&(0,c.jsx)(t.m.span,{className:"chakra-avatar__excess",__css:b,children:`+${v}`}),w]})});m.displayName="AvatarGroup"},51209:function(e,n,i){"use strict";i.d(n,{p:function(){return t}});var r=i(87177),s=i(72753),a=i(26856),l=i(27378);function t(e){let{theme:n}=(0,a.uP)(),i=(0,r.OX)();return(0,l.useMemo)(()=>(0,s.Cj)(n.direction,{...i,...e}),[e,n.direction,i])}}},function(e){e.O(0,[2828,6333,6281,2888,9774,179],function(){return e(e.s=8378)}),_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.