import{_ as F,__tla as I}from"./Form-f495436f.js";import{_ as L,__tla as E}from"./XButton-ddbf3076.js";import{n as w,d as V,b as z,a as r,f as j,r as B,C as D,a1 as G,o as H,l as O,w as m,i as c,g as p,U as T,_ as X,__tla as $}from"./index-b2b3c6c4.js";import{u as A,__tla as J}from"./useForm-0546a4b3.js";import K,{__tla as M}from"./LoginFormTitle-86fd590c.js";import{u as N,L as Q,__tla as W}from"./useLogin-410370f4.js";import{__tla as Y}from"./el-virtual-list-f175adc8.js";import{__tla as Z}from"./el-tree-select-7784ba1b.js";import{__tla as tt}from"./el-time-select-4cedd484.js";import{__tla as at}from"./InputPassword-d9e76ad7.js";import{__tla as rt}from"./Editor-b514e2f8.js";import{__tla as et}from"./SPuUploadImg.vue_vue_type_style_index_0_scoped_ba706063_lang-2554109a.js";import{__tla as ot}from"./index-677601df.js";import{__tla as lt}from"./el-image-viewer-b5664270.js";import{__tla as st}from"./useMessage-a5edbb0f.js";import{__tla as _t}from"./UploadImg-5f639045.js";import{__tla as nt}from"./UploadImgs-5ed43a7f.js";import{__tla as ct}from"./UploadImgs.vue_vue_type_style_index_0_scoped_9d666400_lang-0ec352e2.js";import{__tla as it}from"./UploadFile-cd46855d.js";import{__tla as mt}from"./UploadFile.vue_vue_type_style_index_0_scoped_436eca1b_lang-5cfa6a42.js";let P,pt=Promise.all([(()=>{try{return I}catch{}})(),(()=>{try{return E}catch{}})(),(()=>{try{return $}catch{}})(),(()=>{try{return J}catch{}})(),(()=>{try{return M}catch{}})(),(()=>{try{return W}catch{}})(),(()=>{try{return Y}catch{}})(),(()=>{try{return Z}catch{}})(),(()=>{try{return tt}catch{}})(),(()=>{try{return at}catch{}})(),(()=>{try{return rt}catch{}})(),(()=>{try{return et}catch{}})(),(()=>{try{return ot}catch{}})(),(()=>{try{return lt}catch{}})(),(()=>{try{return st}catch{}})(),(()=>{try{return _t}catch{}})(),(()=>{try{return nt}catch{}})(),(()=>{try{return ct}catch{}})(),(()=>{try{return it}catch{}})(),(()=>{try{return mt}catch{}})()]).then(async()=>{let l,d,u,h,f,g;({t:l}=w()),d=()=>({required:o=>({required:!0,message:o||l("common.required")}),lengthRange:o=>{const{min:t,max:a,message:e}=o;return{min:t,max:a,message:e||l("common.lengthRange",{min:t,max:a})}},notSpace:o=>({validator:(t,a,e)=>{(a==null?void 0:a.indexOf(" "))!==-1?e(new Error(o||l("common.notSpace"))):e()}}),notSpecialCharacters:o=>({validator:(t,a,e)=>{/[`~!@#$%^&*()_+<>?:"{},.\/;'[\]]/gi.test(a)?e(new Error(o||l("common.notSpecialCharacters"))):e()}})}),u={class:"w-[100%] flex"},h={class:"w-[100%]"},f={class:"mt-15px w-[100%]"},g=V({name:"RegisterForm",__name:"RegisterForm",setup(o){const{t}=w(),{required:a}=d(),{register:e,elFormRef:v}=A(),{handleBackLogin:R,getLoginState:b}=N(),k=z(()=>r(b)===Q.REGISTER),x=j([{field:"title",colProps:{span:24}},{field:"username",label:t("login.username"),value:"",component:"Input",colProps:{span:24},componentProps:{placeholder:t("login.usernamePlaceholder")}},{field:"password",label:t("login.password"),value:"",component:"InputPassword",colProps:{span:24},componentProps:{style:{width:"100%"},strength:!0,placeholder:t("login.passwordPlaceholder")}},{field:"check_password",label:t("login.checkPassword"),value:"",component:"InputPassword",colProps:{span:24},componentProps:{style:{width:"100%"},strength:!0,placeholder:t("login.passwordPlaceholder")}},{field:"code",label:t("login.code"),colProps:{span:24}},{field:"register",colProps:{span:24}}]),S={username:[a()],password:[a()],check_password:[a()],code:[a()]},i=B(!1);return(dt,_)=>{const U=T,y=L,q=F;return D((H(),O(q,{rules:S,schema:r(x),class:"dark:(border-1 border-[var(--el-border-color)] border-solid)","hide-required-asterisk":"","label-position":"top",size:"large",onRegister:r(e)},{title:m(()=>[c(K,{style:{width:"100%"}})]),code:m(n=>[p("div",u,[c(U,{modelValue:n.code,"onUpdate:modelValue":s=>n.code=s,placeholder:r(t)("login.codePlaceholder")},null,8,["modelValue","onUpdate:modelValue","placeholder"])])]),register:m(()=>[p("div",h,[c(y,{loading:r(i),title:r(t)("login.register"),class:"w-[100%]",type:"primary",onClick:_[0]||(_[0]=n=>(async()=>{const s=r(v);s==null||s.validate(async C=>{if(C)try{i.value=!0}finally{i.value=!1}})})())},null,8,["loading","title"])]),p("div",f,[c(y,{title:r(t)("login.hasUser"),class:"w-[100%]",onClick:_[1]||(_[1]=n=>r(R)())},null,8,["title"])])]),_:1},8,["schema","onRegister"])),[[G,r(k)]])}}}),P=X(g,[["__file","/Users/RuHu.Xu/Desktop/mall-newfeifan-zx-admin/src/views/Login/components/RegisterForm.vue"]])});export{pt as __tla,P as default};
