import{D as e,E as t,F as n,H as r,Q as i,T as a,X as o,Y as s,b as c,g as l,i as u,n as d,r as f,x as p}from"./app-DWsGXxIs.js";import{t as m}from"./i18n-CF4iz4Mi.js";import{t as h}from"./GuestLayout-BgX3D56C.js";import{n as g,t as _}from"./TextInput-DdLwUqTq.js";import{t as v}from"./InputLabel-SZyD8J_q.js";import{t as y}from"./PrimaryButton-CF1A9GTQ.js";var b={class:`mt-4`},x={class:`mt-4`},S={class:`mt-4`},C={class:`mt-4 flex items-center justify-end`},w=e({__name:`Register`,setup(e){let w=u({name:``,email:``,password:``,password_confirmation:``}),T=()=>{w.post(route(`register`),{onFinish:()=>{w.reset(`password`,`password_confirmation`)}})};return(e,u)=>(n(),p(h,null,{default:r(()=>[t(s(d),{title:s(m)(`Register`)},null,8,[`title`]),c(`form`,{onSubmit:l(T,[`prevent`])},[c(`div`,null,[t(v,{for:`name`,value:s(m)(`Name`)},null,8,[`value`]),t(_,{id:`name`,type:`text`,class:`mt-1 block w-full`,modelValue:s(w).name,"onUpdate:modelValue":u[0]||=e=>s(w).name=e,required:``,autofocus:``,autocomplete:`name`},null,8,[`modelValue`]),t(g,{class:`mt-2`,message:s(w).errors.name},null,8,[`message`])]),c(`div`,b,[t(v,{for:`email`,value:s(m)(`Email`)},null,8,[`value`]),t(_,{id:`email`,type:`email`,class:`mt-1 block w-full`,modelValue:s(w).email,"onUpdate:modelValue":u[1]||=e=>s(w).email=e,required:``,autocomplete:`username`},null,8,[`modelValue`]),t(g,{class:`mt-2`,message:s(w).errors.email},null,8,[`message`])]),c(`div`,x,[t(v,{for:`password`,value:s(m)(`Password`)},null,8,[`value`]),t(_,{id:`password`,type:`password`,class:`mt-1 block w-full`,modelValue:s(w).password,"onUpdate:modelValue":u[2]||=e=>s(w).password=e,required:``,autocomplete:`new-password`},null,8,[`modelValue`]),t(g,{class:`mt-2`,message:s(w).errors.password},null,8,[`message`])]),c(`div`,S,[t(v,{for:`password_confirmation`,value:s(m)(`Confirm Password`)},null,8,[`value`]),t(_,{id:`password_confirmation`,type:`password`,class:`mt-1 block w-full`,modelValue:s(w).password_confirmation,"onUpdate:modelValue":u[3]||=e=>s(w).password_confirmation=e,required:``,autocomplete:`new-password`},null,8,[`modelValue`]),t(g,{class:`mt-2`,message:s(w).errors.password_confirmation},null,8,[`message`])]),c(`div`,C,[t(s(f),{href:e.route(`login`),class:`rounded-md text-sm text-gray-600 underline hover:text-gray-900 focus:outline-none focus:ring-2 focus:ring-indigo-500 focus:ring-offset-2 dark:text-gray-400 dark:hover:text-gray-100 dark:focus:ring-offset-gray-800`},{default:r(()=>[a(i(s(m)(`Already registered?`)),1)]),_:1},8,[`href`]),t(y,{class:o([`ms-4`,{"opacity-25":s(w).processing}]),disabled:s(w).processing},{default:r(()=>[a(i(s(m)(`Register`)),1)]),_:1},8,[`class`,`disabled`])])],32)]),_:1}))}});export{w as default};