import{_ as N,o as u,c as _,u as T,r as a,m as A,b as n,d as k,e as s,i as o,a as l,F as C,g as d,h as R,j as r,k as j,q as I,l as h}from"./entry.cebe1249.js";import{_ as M}from"./import.b5e0fbf5.js";const $={},D={class:"loader"};function H(P,b){return u(),_("div",D)}const z=N($,[["render",H],["__scopeId","data-v-01c6938e"]]),K=""+globalThis.__publicAssetsURL("indonesia.svg"),O={class:"animate-fade w-full"},Q={class:"bg-white uhjk py-6 mt-6 w-[90%] mx-auto rounded-xl my-12",style:{border:"1.4px solid #EFEFEF"}},Y={class:"grid grid-cols-1 sm:grid-cols-2 sm:gap-6 pt-8"},G={key:0,class:"text-xl"},Z={__name:"Sistem-Pencatatan-Pendaftaran",setup(P){T({title:"Sistem Pencatatan Pendaftaran"});const b=a(null),x=a(!1),m=a(null),i=a(null),p=a(null),v=a(null),c=a(null),f=a(!1),w=a(["Pendidikan Matematika","Hukum","Agama Islam","Manajemen","Pendidikan Matematika","PPKn","Teknik Sipil"]),y=A().currentRoute.value.query.email;i.value=y;async function F(){const{valid:V}=await b.value.validate();V&&(x.value=!0,await $fetch(h().public.API_PUBLIC_URL+"/api/catatan-pendaftaran",{method:"POST",headers:{Authorization:"Bearer "+useToken().token},body:{name:m.value,email:i.value,notelp:p.value,prodi:v.value,pesan:c.value}}),x.value=!1,f.value=!0)}return(V,e)=>{const E=d("v-snackbar"),g=d("v-text-field"),U=d("v-select"),S=d("v-textarea"),q=z,B=d("v-form"),L=R("ripple");return u(),_(C,null,[n(E,{modelValue:s(f),"onUpdate:modelValue":e[0]||(e[0]=t=>o(f)?f.value=t:null),color:"#2E8586",timeout:4e3,rounded:"pill"},{default:k(()=>e[6]||(e[6]=[l("div",{class:"text-lg"}," Pendaftaran berhasil dikirim! ",-1)])),_:1},8,["modelValue"]),l("div",O,[n(B,{ref_key:"form",ref:b},{default:k(()=>[l("div",Q,[e[13]||(e[13]=l("div",{class:"sm:flex items-center justify-between w-full pb-4",style:{"border-bottom":"1px solid #EFEFEF"}},[l("div",null,[l("h1",{class:"font-bold"},"Sistem Pencatatan Pendaftaran")]),l("div",{class:"mt-2 sm:mt-0 flex items-center"},[l("img",{src:M}),l("div",{class:"font-semibold text-[#2E8586]"}," Unduh Brosur ")])],-1)),l("div",Y,[l("div",null,[e[7]||(e[7]=l("div",{class:"mb-5 font-semibold"},[r("Nama Lengkap"),l("span",{class:"text-red"},"*")],-1)),n(g,{rules:[t=>!!t||"Field is required"],modelValue:s(m),"onUpdate:modelValue":e[1]||(e[1]=t=>o(m)?m.value=t:null),label:"Nama Lengkap",variant:"outlined",placeholder:"ex: Muhammad Ichsanul Fadhil",rounded:""},null,8,["rules","modelValue"])]),l("div",null,[e[8]||(e[8]=l("div",{class:"mb-5 font-semibold"},[r("Alamat Email"),l("span",{class:"text-red"},"*")],-1)),n(g,{rules:[t=>!!t||"Field is required",t=>!t||/^\w+([.-]?\w+)*@\w+([.-]?\w+)*(\.\w{2,3})+$/.test(t)||"Alamat email tidak valid"],modelValue:s(i),"onUpdate:modelValue":e[2]||(e[2]=t=>o(i)?i.value=t:null),label:"Email",variant:"outlined",placeholder:"ichsanfadhil67@gmail.com",rounded:""},null,8,["rules","modelValue"])])]),l("div",null,[e[10]||(e[10]=l("div",{class:"mb-5 font-semibold"},[r("Nomor Telepon"),l("span",{class:"text-red"},"*")],-1)),n(g,{rules:[t=>!!t||"Field is required"],modelValue:s(p),"onUpdate:modelValue":e[3]||(e[3]=t=>o(p)?p.value=t:null),label:"Nomor Telepon",type:"number",variant:"outlined",placeholder:"812333444666",rounded:""},{"prepend-inner":k(()=>e[9]||(e[9]=[l("div",{class:"flex items-center pr-6"},[l("img",{src:K,width:"30"}),l("div",{class:"ml-1 text-[#111111] font-semibold"},"+62")],-1)])),_:1},8,["rules","modelValue"])]),l("div",null,[e[11]||(e[11]=l("div",{class:"mb-5 font-semibold"},[r("Program Studi"),l("span",{class:"text-red"},"*")],-1)),n(U,{rules:[t=>!!t||"Field is required"],modelValue:s(v),"onUpdate:modelValue":e[4]||(e[4]=t=>o(v)?v.value=t:null),label:"Pilih Program Studi",variant:"outlined",rounded:"",items:s(w)},null,8,["rules","modelValue","items"])]),l("div",null,[e[12]||(e[12]=l("div",{class:"mb-5 font-semibold"},[r("Pesan"),l("span",{class:"text-red"},"*")],-1)),n(S,{rules:[t=>!!t||"Field is required"],modelValue:s(c),"onUpdate:modelValue":e[5]||(e[5]=t=>o(c)?c.value=t:null),label:"Pesan",variant:"outlined",clearable:"","auto-grow":"",placeholder:"Semangat untuk UCY!",rounded:""},null,8,["rules","modelValue"])]),j((u(),_("div",{onClick:F,class:"cursor-pointer text-base bg-[#2E8586] text-white flex justify-center w-full mt-6 rounded-xl font-medium text-center px-4 py-3"},[s(x)?(u(),I(q,{key:1})):(u(),_("div",G,"Daftar"))])),[[L]])])]),_:1},512)])],64)}}};export{Z as default};
