1import{a2 as T,a as z,c as I,g as O,e as $,a3 as F,X as U,z as N,ba as H,a5 as k,bb as W,bc as M,ab as B,ac as S,ad as q,bd as G,a0 as v,j as e,p as J,T as E,w as X,b as P,a9 as K}from"./index-ZWP6Dbbj.js";import{r as R}from"./vendor-DKtCm5W2.js";import{S as Q}from"./SocialLoginButtons-D9KX2QgJ.js";import{R as V}from"./RegisterForm-eBbHzuAd.js";import{p as Y}from"./login-B_fF-H8e.js";import{at as l,w as _}from"./app-BUG-_G7c.js";import{u as Z}from"./useRefreshSiteAccessFlags-CP3ATGr9.js";import"./dayjs-timezone-iana-plugin-CmU3ItL3.js";import"./index-BsxiMeTv.js";import"./RichText-BpKuIjrs.js";import"./collapseNbsp-BitJg-02.js";import"./NoBadgeReCAPTCHA-Cg54kL1K.js";import"./recaptcha-wrapper-kgvo4tPj.js";try{let n=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},a=new n.Error().stack;a&&(n._sentryDebugIds=n._sentryDebugIds||{},n._sentryDebugIds[a]="e61402e6-5013-46fe-aae5-bce3be6d3004",n._sentryDebugIdIdentifier="sentry-dbid-e61402e6-5013-46fe-aae5-bce3be6d3004")}catch{}const ee={en:"Already have an account?",nl:"Al een account?"},ae={en:"Step 1. Create a personal account",nl:"Stap 1. Maak een persoonlijk account"},te={en:"This account will be linked to your %{g:organization}, you can change this later.",nl:"Dit account wordt gelinkt aan je organisatie. Dit kun je later veranderen."},ne={en:"Create one here",nl:"Maak er hier een aan"},se={en:"Looking to create %{g:aOrganization} %{g:organization}?",nl:"Wil je een %{g:organization} creëren?"},re={en:"Step 1. Create a personal account",nl:"Stap 1. Maak een persoonlijk account"},ie={en:"This account will be linked to your request for help",nl:"Dit account wordt gekoppeld aan je hulpvraag"},oe={en:"Account with that Email exists.",nl:"Er bestaat al een account met dit E-mailadres."},ce={en:"Please login instead",nl:"Ga naar Log in"},le={en:"You have already applied as a guest. We've resent a confirmation email â use the link in it to create your account.",nl:"Je hebt je al aangemeld als gast. We hebben je een bevestigingsmail gestuurd. Gebruik de link daarin om je account aan te maken."},de={en:"Login here",nl:"Log hier in"},ge={en:"Join Deedmob",nl:"Meld je aan bij Deedmob"},me={en:"Create account",nl:"Account aanmaken"},ue={en:"Or sign up with email",nl:"Of meld je aan met e-mail"},pe={en:"We care about your privacy. ð",nl:"Dingen die we je moeten vragen. We geven om je privacy. ð"},he={alreadyAccount:ee,createOrgStep:ae,createOrgStep_sub:te,createOrganizationHere:ne,createOrganizationInstead:se,createP2PStep:re,createP2PStep_sub:ie,emailAlreadyExists:oe,emailAlreadyExistsLoginLink:ce,guestUserCheckEmail:le,loginHere:de,register:ge,registerButton:me,signupEmail:ue,termsTitle:pe},Ae=()=>{const n=T(),a=z(he),i=I(),b=R.useRef(null),o=O(),f=$(),y=Z(),[r]=F(),A={email:r.get("email")||"",first_names:r.get("first_names")||"",last_name:r.get("last_name")||"",password:"",promotional_consent:!1,terms:!1},m=U(),d=N(),{settings:j}=o.whitelabel,s=H(r)||"/",g=s==="/create-organization",w=s===`/${k}${o.deedsString}/create`||s?.endsWith(`/${k}${o.deedsString}/new`),C=R.useCallback(async L=>{let u=null;const{current:p}=b;if(!p)return;if(p.reset(),u=await p.executeAsync(),!u)throw new Error("Invalid captcha response");const h={...L,type:W.register,referrer:sessionStorage.getItem("referrer")||"",language:a.locale,captcharesponse:u,whitelabel:o.whitelabel,next:s,token:r.get("token")||void 0};await f(M(h)).then(async t=>{if(B(t)){i(S("twoFactorAuth",{ticket:t.ticket,next:s,email:t.email||void 0,backRedirect:t.email?`/register?email=${encodeURIComponent(t.email)}&next=${encodeURIComponent(s)}`:void 0}));return}const c=t;await n.resetStore(),c?(await y().catch(q),Y({memberships:c,searchParams:r,navigate:i,location:m})):i(`/pending-verify-account?${new URLSearchParams({email:h.email})}`)}).catch(t=>{if(t instanceof G&&t.status===403){if(t.code===v.GUEST_USER_CHECK_EMAIL){d({message:a("guestUserCheckEmail")})(t);return}if(t.code===v.EMAIL_EXISTS){const c=`${S("login")}?${new URLSearchParams({email:h.email,next:s})}`;d({message:e.jsxs(e.Fragment,{children:[a("emailAlreadyExists")," ",e.jsx("a",{href:c,onClick:D=>{D.preventDefault(),i(c)},children:a("emailAlreadyExistsLoginLink")})]})})(t);return}}d()(t)})},[n,f,i,s,y,r,m,o.whitelabel,a,d]);J(a("register"));const x=j.email_login_disabled;return e.jsxs("div",{className:l.root,children:[e.jsx("div",{className:_.textCenter,children:g||w?e.jsxs(e.Fragment,{children:[e.jsx(E,{order:1,ta:"center",children:a(g?"createOrgStep":"createP2PStep")}),e.jsx(X,{ta:"center",children:a(g?"createOrgStep_sub":"createP2PStep_sub")})]}):e.jsx(E,{order:1,ta:"center",children:a("register")})}),e.jsxs("div",{className:l.contentWrapper,children:[e.jsxs("div",{className:l.topHints,children:[e.jsxs("div",{children:[`${a("alreadyAccount")} `,e.jsx(P,{className:l.primaryColor,to:`/login${m.search}`,children:a("loginHere")})]}),j.create_organizations&&!g&&!w&&e.jsxs("div",{className:_.paddingR,children:[`${a("createOrganizationInstead")} `,e.jsx(P,{className:l.primaryColor,to:"/create-organization",children:a("createOrganizationHere")})]})]}),e.jsx(Q,{mode:"register",buttons:["kennisnet","azure"],hasDividerOnBottom:!x}),!x&&e.jsx(V,{onSubmit:C,initialValues:A,captchaRef:b})]}),e.jsx(K,{mode:"accounts",align:"center"})]})};export{Ae as default}; 2//# sourceMappingURL=index-yNJ9KVnw.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.