import{c as q,a as w,l as x}from"../chunks/cL9VaPgy.js";import{i as B}from"../chunks/Dj1UN0wv.js";import{p as L,y as _,l as t,a as p,b as S,s as o,d as f,F as i,c as I,B as M,f as R,z as k,o as z,g as b}from"../chunks/C75YQU_W.js";import{v as A}from"../chunks/D1kbsK6n.js";import{r as C}from"../chunks/CblvSmSU.js";import{F as G,I as r,B as H}from"../chunks/Wy6oXzdU.js";import{g as O}from"../chunks/BpVw-oe-.js";import{g as U}from"../chunks/Cz-4yBSw.js";import{p as W}from"../chunks/Bkiwg8SD.js";e[i]="src/routes/sign-up/+page.svelte";var h=C(()=>O),j=w(I("<!> <!> <!> <!> <div><!></div>",1),e[i],[[48,6]]),D=w(I(`<div class="grid gap.4"><h1>Sign Up</h1> <p>NOTE: Registration is currently only open for private beta users, but feel
    free to use this registration form to be added to the waitlist.</p> <!></div>`),e[i],[[10,0,[[11,2],[13,2]]]]);function e(T,$){q(new.target),L($,!1,e);const m=8;B();var s=D(),y=o(f(s),4);{const E=_(e,function(a,n=M){A(...arguments);var l=j(),d=R(l);t(()=>r(d,{label:"Name",name:"name",required:!0}),"component",e,31,6,{componentTag:"Input"});var u=o(d,2);t(()=>r(u,{label:"Email",name:"email",type:"email",required:!0}),"component",e,32,6,{componentTag:"Input"});var g=o(u,2);t(()=>r(g,{label:"Password",name:"password",type:"password",required:!0,minlength:m}),"component",e,33,6,{componentTag:"Input"});var c=o(g,2);t(()=>r(c,{label:"Repeat Password",name:"repeatPassword",type:"password",required:!0,minlength:m}),"component",e,40,6,{componentTag:"Input"});var v=o(c,2),N=f(v);t(()=>H(N,{type:"submit",get loading(){return n().isLoading},children:_(e,(P,J)=>{k();var F=z("Submit");p(P,F)}),$$slots:{default:!0}}),"component",e,48,11,{componentTag:"Button"}),b(v),p(a,l)});t(()=>G(y,{class:"d.contents",onresponse:a=>{if(a.result.error){alert(a.result.error.message);return}h(h().user=a.result.data?.user);const n=W.url.searchParams.get("goto");return U(n??"/dashboard")},content:E,$$slots:{content:!0}}),"component",e,18,2,{componentTag:"Form"})}return b(s),p(T,s),S({...x()})}export{e as component};
