1import{d as M,Y as E,u as I,$ as D,S as j,ac as H,a as t,w as i,ad as J,o as k,ae as L,e as a,c as Y,b as d,i as V,f as Z,a2 as c,a8 as K,aa as Q,Z as X,j as ee,r as u}from"./B8BqYOvv.js";import{_ as ae}from"./CnefzCIh.js";import{_ as te}from"./B5eaG9Yx.js";import{_ as ne}from"./Bn6kLFSm.js";import{_ as oe}from"./CVMm41Bv.js";import{_ as ie}from"./CJyWupoH.js";import{_ as le}from"./D0aDlECL.js";import{_ as re}from"./BXnUuJWJ.js";import{_ as se}from"./C7ijPRTx.js";import{_ as me}from"./B0govf1O.js";import{_ as de}from"./CVYy-AiX.js";import{_ as ce}from"./DzVVY_r4.js";import{o as ue,b as pe,s,_ as ge}from"./DAAKUUjV.js";import"./B3_AMCzp.js";import"./C3MKDZKL.js";import"./jFYhBC76.js";import"./SIB4ZqY7.js";import"./C6aR-riK.js";import"./Lq84yKea.js";import"./CnzpgMIZ.js";import"./QHWCy6iP.js";import"./jiEM9haF.js";const ve={class:"mt-4"},fe={class:"grid grid-cols-1 md:grid-cols-2 gap-4"},_e={key:0,class:"md:col-span-2"},be={class:"flex items-center gap-3"},ke={class:"mt-4"},Ee=M({__name:"toegang-aanvragen",setup(xe){const{$csrfFetch:w}=E();I({title:"Toegang aanvragen",description:"Vraag toegang aan tot de beheeromgeving"});const y=D(),N=[{label:"Politieke partij",value:"party"},{label:"Niet-gouvernementele organisatie (NGO)",value:"ngo"},{label:"Verkiesbare kandidaat",value:"candidate"},{label:"Mediabureau",value:"media_agency"},{label:"Reclamebureau/studio",value:"creative_agency"},{label:"Andere adviseur",value:"consultant"},{label:"Mediabedrijf",value:"media_company"}],U=ue({firstName:s().min(2,"vul je voornaam in"),lastName:s().min(2,"vul je achternaam in"),organization:s().min(2,"vul je organisatie in"),email:s().email("vul een geldig e-mailadres in"),role:ge(["party","ngo","candidate","media_agency","creative_agency","consultant","media_company"],{message:"kies een rol"}),phone:s().optional(),notes:s().optional(),acceptPrivacy:pe({message:"accepteer de privacyverklaring"}).refine(l=>l===!0,{message:"accepteer de privacyverklaring"})}),n=X({firstName:"",lastName:"",organization:"",email:"",role:void 0,phone:"",notes:"",acceptPrivacy:!1}),$=["gmail.com","yahoo.com","hotmail.com","outlook.com","icloud.com","aol.com","protonmail.com"],p=ee(()=>{const l=n.email.split("@")[1]?.toLowerCase();return l?$.includes(l):!1}),g=u(!1),v=u(!1),_=u("We hebben je aanvraag ontvangen. Na controle ontvang je per e-mail verdere instructies."),f=u(void 0),z=u(null);function P(){Object.assign(n,{firstName:"",lastName:"",organization:"",email:"",role:void 0,phone:"",notes:"",acceptPrivacy:!1}),v.value=!1}async function T(){g.value=!0;try{const l=await w("/api/access-requests",{method:"POST",body:{...n,turnstileToken:f.value}});l?.ok&&(v.value=!0,_.value=l.message??_.value)}catch(l){const e=l?.data?.message||"verzenden is niet gelukt, probeer het later opnieuw";y.add({title:"fout",description:e,color:"error"})}finally{g.value=!1}}const q=[{title:"Vul je gegevens in",description:"Gebruik je werkmail van de organisatie die je vertegenwoordigt.",icon:"i-lucide-user-plus"},{title:"Wij controleren je aanvraag",description:"We toetsen organisatie, bevoegdheid en e-maildomein.",icon:"i-lucide-shield-check"},{title:"Ontvang verificatie en instructies",description:"Bij akkoord ontvang je een e-mail met een verificatiecode en verdere instructies.",icon:"i-lucide-mail-check"},{title:"Activeer en werk in het portaal",description:"Na activatie kun je inloggen en transparantieverklaringen aanmaken, wijzigen en publiceren.",icon:"i-lucide-badge-check"}];return(l,e)=>{const A=Q,m=ae,r=te,C=ne,x=oe,S=ie,B=le,h=Z,O=re,W=se,F=me,b=de,R=ce,G=J;return k(),j("div",null,[e[15]||(e[15]=H('<header class="pt-20 from-brand-500 to-brand-400 bg-linear-to-tr after:content-[] after:block after:w-full after:h-4 after:bg-white after:rounded-t-full"><div class="relative z-10 w-full max-w-(--ui-container) mx-auto px-4 sm:px-6 lg:px-8 flex flex-col py-8 sm:py-16 md:py-24"><div class="max-w-2xl"><h1 class="mb-8 text-3xl sm:text-4xl lg:text-5xl text-pretty tracking-tight font-bold text-white"> Toegang aanvragen </h1><p class="text-sm md:text-base text-brand-50 max-w-3xl"> Voor het invullen van een transparantieverklaring dient wel een login aangevraagd te worden, die met een verificatiecode beveiligd wordt. Politieke adverteerders of hun reclamebureaus kunnen hier toegang aanvragen tot hun eigen pagina voor het aanmaken en publiceren van hun transparantieverklaring. </p></div></div><div class="absolute z-0 inset-0 bg-[url('/images/pattern_dots.svg')] bg-repeat bg-center bg-size-[600px] opacity-10"></div></header>',1)),t(G,{class:"relative z-20"},{default:i(()=>[t(b,{title:"Aanvraagformulier",class:"max-w-2xl mx-auto"},{description:i(()=>[e[12]||(e[12]=d("p",null," Gebruik je werkmail van de organisatie die je vertegenwoordigt. We toetsen organisatie, bevoegdheid en domein. Gebruik je een privémail? Voeg dan een korte toelichting toe waaruit blijkt dat je gemachtigd bent om te handelen namens de organisatie waarvoor je toegang vraagt. ",-1)),d("p",ve,[e[10]||(e[10]=c(" Als je vragen hebt over het aanvraagproces of hulp nodig hebt bij het invullen van het formulier, bekijk dan eerst even op ",-1)),t(A,{to:"/informatie",class:"underline"},{default:i(()=>[...e[9]||(e[9]=[c("de informatiepagina",-1)])]),_:1}),e[11]||(e[11]=c(" of je hier het antwoord op je vraag kunt vinden, de kans is groot dat dit lukt. ",-1))])]),default:i(()=>[t(F,null,L({default:i(()=>[a(v)?V("",!0):(k(),Y(O,{key:0,schema:a(U),state:a(n),class:"space-y-6",onSubmit:T},{default:i(()=>[d("div",fe,[t(r,{label:"Voornaam",name:"firstName",required:""},{default:i(()=>[t(m,{modelValue:a(n).firstName,"onUpdate:modelValue":e[0]||(e[0]=o=>a(n).firstName=o),maxlength:"230",class:"w-full",autocomplete:"given-name"},null,8,["modelValue"])]),_:1}),t(r,{label:"Achternaam",name:"lastName",required:""},{default:i(()=>[t(m,{modelValue:a(n).lastName,"onUpdate:modelValue":e[1]||(e[1]=o=>a(n).lastName=o),maxlength:"230",class:"w-full",autocomplete:"family-name"},null,8,["modelValue"])]),_:1}),t(r,{label:"Organisatie",name:"organization",required:"",class:"md:col-span-2"},{default:i(()=>[t(m,{modelValue:a(n).organization,"onUpdate:modelValue":e[2]||(e[2]=o=>a(n).organization=o),class:"w-full",placeholder:"partij, adverteerder of mediabureau"},null,8,["modelValue"])]),_:1}),t(r,{label:"E-mail",name:"email",required:"",class:"md:col-span-2"},{default:i(()=>[t(m,{modelValue:a(n).email,"onUpdate:modelValue":e[3]||(e[3]=o=>a(n).email=o),maxlength:"230",class:"w-full",type:"email",autocomplete:"email"},null,8,["modelValue"])]),_:1}),t(r,{label:"Rol",name:"role",required:""},{default:i(()=>[t(C,{modelValue:a(n).role,"onUpdate:modelValue":e[4]||(e[4]=o=>a(n).role=o),class:"w-full",items:N,placeholder:"kies rol"},null,8,["modelValue"])]),_:1}),t(r,{label:"Telefoon",name:"phone"},{default:i(()=>[t(m,{modelValue:a(n).phone,"onUpdate:modelValue":e[5]||(e[5]=o=>a(n).phone=o),maxlength:"230",class:"w-full",type:"tel",autocomplete:"tel"},null,8,["modelValue"])]),_:1}
1),a(p)?(k(),j("div",_e,[t(x,{color:"error",variant:"subtle",title:"Privémail gedetecteerd",description:"Je gebruikt een privémailadres. Voeg alsjeblieft een korte toelichting toe waaruit blijkt dat je gemachtigd bent om namens de organisatie te handelen."})])):V("",!0),t(r,{label:"Toelichting",name:"notes",class:"md:col-span-2",required:a(p)},{default:i(()=>[t(S,{modelValue:a(n).notes,"onUpdate:modelValue":e[6]||(e[6]=o=>a(n).notes=o),class:"w-full",rows:4,required:a(p),placeholder:a(p)?"Voeg context toe":"optioneel, voeg context toe"},null,8,["modelValue","required","placeholder"])]),_:1},8,["required"])]),t(B,{modelValue:a(n).acceptPrivacy,"onUpdate:modelValue":e[7]||(e[7]=o=>a(n).acceptPrivacy=o),name:"acceptPrivacy",description:"Ik ga akkoord met de verwerking van mijn gegevens voor deze aanvraag"},null,8,["modelValue"]),d("div",be,[t(h,{type:"submit",color:"primary",loading:a(g)},{default:i(()=>[...e[13]||(e[13]=[c("Aanvraag versturen",-1)])]),_:1},8,["loading"]),t(h,{variant:"ghost",disabled:a(g),onClick:P},{default:i(()=>[...e[14]||(e[14]=[c("Herstel",-1)])]),_:1},8,["disabled"])])]),_:1},8,["schema","state"])),d("div",ke,[t(W,{ref_key:"turnstileRef",ref:z,modelValue:a(f),"onUpdate:modelValue":e[8]||(e[8]=o=>K(f)?f.value=o:null)},null,8,["modelValue"])])]),_:2},[a(v)?{name:"footer",fn:i(()=>[t(x,{color:"primary",variant:"subtle",title:"Aanvraag ontvangen",description:a(_)},null,8,["description"])]),key:"0"}:void 0]),1024)]),_:1}),t(b,{class:"max-w-2xl mx-auto"},{default:i(()=>[t(R,{items:q})]),_:1}),t(b,{title:"Wat wij controleren",description:"We toetsen organisatie, bevoegdheid en of je e-maildomein aansluit bij de opgegeven organisatie. Bij akkoord ontvang je per e-mail een code met verdere instructies.",class:"max-w-2xl mx-auto"})]),_:1})])}}});export{Ee as default};
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.