1"use strict";(self.webpackChunkfrontend=self.webpackChunkfrontend||[]).push([[885],{5084(e,t,s){s.d(t,{A:()=>i});var a=s(5043),n=s(579);function i(e){let{returnTo:t,variant:s="primary",label:i}=e;const[l,o]=(0,a.useState)(!1),c="compact"===s?"py-2 text-xs":"py-3 text-sm";return(0,n.jsxs)("button",{type:"button",onClick:()=>{o(!0);try{t&&sessionStorage.setItem("tc_auth_return_to",t);const e=window.location.origin+"/auth/callback",s="https://auth.emergentagent.com/?redirect=".concat(encodeURIComponent(e));window.location.href=s}catch(e){console.error("google sign-in redirect failed",e),o(!1)}},disabled:l,"data-testid":"signin-with-google",className:"w-full inline-flex items-center justify-center gap-3 border border-[#333] "+"bg-white text-black font-body ".concat(c," px-4 hover:bg-zinc-100 ")+"disabled:opacity-50 transition-colors",children:[(0,n.jsx)(r,{}),l?"Redirecting\u2026":i||"Sign in with Google"]})}function r(){return(0,n.jsxs)("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 48 48",width:"18",height:"18","aria-hidden":"true",children:[(0,n.jsx)("path",{fill:"#EA4335",d:"M24 9.5c3.54 0 6.71 1.22 9.21 3.6l6.85-6.85C35.9 2.38 30.47 0 24 0 14.62 0 6.51 5.38 2.56 13.22l7.98 6.19C12.43 13.72 17.74 9.5 24 9.5z"}),(0,n.jsx)("path",{fill:"#4285F4",d:"M46.98 24.55c0-1.57-.15-3.09-.38-4.55H24v9.02h12.94c-.58 2.96-2.26 5.48-4.78 7.18l7.73 6c4.51-4.18 7.09-10.36 7.09-17.65z"}),(0,n.jsx)("path",{fill:"#FBBC05",d:"M10.53 28.59c-.48-1.45-.76-2.99-.76-4.59s.27-3.14.76-4.59l-7.98-6.19C.92 16.46 0 20.12 0 24c0 3.88.92 7.54 2.56 10.78l7.97-6.19z"}),(0,n.jsx)("path",{fill:"#34A853",d:"M24 48c6.48 0 11.93-2.13 15.89-5.81l-7.73-6c-2.15 1.45-4.92 2.3-8.16 2.3-6.26 0-11.57-4.22-13.47-9.91l-7.98 6.19C6.51 42.62 14.62 48 24 48z"}),(0,n.jsx)("path",{fill:"none",d:"M0 0h48v48H0z"})]})}},7885(e,t,s){s.r(t),s.d(t,{default:()=>p});var a=s(9379),n=s(5685),i=s(5043),r=s(6328),l=s(5692),o=s(4211),c=s(1282),d=s(5084),u=s(3124),x=s(579);function p(){const{signup:e}=(0,u.A)(),t=(0,n.Zp)(),[s,p]=(0,i.useState)({name:"",email:"",password:""}),[h,g]=(0,i.useState)(!1),f=e=>t=>p(s=>(0,a.A)((0,a.A)({},s),{},{[e]:t.target.value}));return(0,x.jsxs)("div",{className:"min-h-screen bg-black",children:[(0,x.jsx)(r.l$,{theme:"dark",position:"top-right",closeButton:!0,toastOptions:{classNames:{closeButton:"!absolute !top-2 !right-2 !left-auto !bg-transparent !border-0 !text-zinc-500 hover:!text-white !shadow-none !w-6 !h-6 !rounded-none"}}}),(0,x.jsx)(o.A,{}),(0,x.jsxs)("section",{className:"max-w-md mx-auto px-6 py-20",children:[(0,x.jsx)("div",{className:"font-mono text-[11px] tracking-widest text-zinc-500 mb-3",children:"/ SIGN_UP"}),(0,x.jsx)("h1",{className:"font-display text-6xl uppercase",children:"Join The Crew"}),(0,x.jsx)("p",{className:"font-body text-zinc-400 mt-3",children:"Save designs, reorder fast, track every shipment."}),(0,x.jsxs)("form",{onSubmit:async a=>{if(a.preventDefault(),s.password.length<6)r.oR.error("Password must be at least 6 characters");else{g(!0);try{await e(s.email,s.password,s.name),r.oR.success("Account created"),t("/account")}catch(l){var n,i;r.oR.error((null===(n=l.response)||void 0===n||null===(i=n.data)||void 0===i?void 0:i.detail)||"Sign up failed")}finally{g(!1)}}},className:"surface-card p-6 space-y-4 mt-8","data-testid":"signup-form",children:[(0,x.jsx)(m,{label:"Full Name",tid:"name",value:s.name,onChange:f("name"),required:!0}),(0,x.jsx)(m,{label:"Email",tid:"email",type:"email",value:s.email,onChange:f("email"),required:!0}),(0,x.jsx)(m,{label:"Password (6+ chars)",tid:"password",type:"password",value:s.password,onChange:f("password"),required:!0}),(0,x.jsx)("button",{"data-testid":"signup-submit",type:"submit",disabled:h,className:"w-full btn-tc-primary flex items-center justify-center gap-3",children:h?"Creating\u2026":(0,x.jsxs)(x.Fragment,{children:["Create Account ",(0,x.jsx)(l.A,{size:16})]})}),(0,x.jsxs)("div",{className:"pt-2",children:[(0,x.jsxs)("div",{className:"relative py-2 flex items-center gap-3 text-zinc-500 font-mono text-[10px] tracking-widest",children:[(0,x.jsx)("div",{className:"flex-1 h-px bg-[#222]"}),"OR",(0,x.jsx)("div",{className:"flex-1 h-px bg-[#222]"})]}),(0,x.jsx)(d.A,{returnTo:"/account",label:"Sign up with Google"})]})]}),(0,x.jsxs)("div",{className:"mt-6 text-center font-mono text-xs",children:[(0,x.jsx)("span",{className:"text-zinc-500",children:"Have an account?"})," ",(0,x.jsx)(n.N_,{to:"/login",className:"text-[var(--tc-red)] hover:underline",children:"Sign In \u2192"})]})]}),(0,x.jsx)(c.A,{})]})}function m(e){let{label:t,tid:s,type:a="text",value:n,onChange:i,required:r}=e;return(0,x.jsxs)("label",{className:"block",children:[(0,x.jsx)("span",{className:"font-mono text-[10px] tracking-widest text-zinc-500",children:t.toUpperCase()}),(0,x.jsx)("input",{"data-testid":"signup-".concat(s),type:a,required:r,value:n,onChange:i,className:"w-full bg-black border border-[#222] focus:border-[var(--tc-red)] px-3 py-3 mt-1 font-body text-sm outline-none"})]})}}}]);
2//# sourceMappingURL=885.05aeb551.chunk.js.map
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.