import{_ as I,__tla as L}from"./Form-03af17d7.js";import{_ as z,__tla as C}from"./XButton-bca72e5c.js";import{h as w,d as E,Y as V,a,e as $,r as j,z as B,$ as D,o as G,x as H,w as m,f as c,g as p,R as O,_ as T,__tla as X}from"./index-8dc1e40a.js";import{u as Y,__tla as A}from"./useForm-8c76e04a.js";import J,{__tla as K}from"./LoginFormTitle-67e9eb88.js";import{u as M,L as N,__tla as Q}from"./useLogin-88b980a8.js";import{__tla as W}from"./el-virtual-list-7d2f4f55.js";import{__tla as Z}from"./el-tree-select-d82790d8.js";import{__tla as tt}from"./el-time-select-c3304867.js";import{__tla as rt}from"./InputPassword-edfbc29e.js";import{__tla as at}from"./Editor-78efff00.js";import{__tla as et}from"./SPuUploadImg.vue_vue_type_style_index_0_scoped_ba706063_lang-703a828c.js";import{__tla as ot}from"./index-519182c1.js";import{__tla as lt}from"./el-image-viewer-3b8905e6.js";import{__tla as st}from"./useMessage-7a27dd80.js";import{__tla as _t}from"./UploadImg-c2c75279.js";import{__tla as nt}from"./UploadImgs-c9e344db.js";import{__tla as ct}from"./UploadImgs.vue_vue_type_style_index_0_scoped_9d666400_lang-c25ae3d0.js";import{__tla as it}from"./UploadFile-8d93ebfd.js";import{__tla as mt}from"./UploadFile.vue_vue_type_style_index_0_scoped_436eca1b_lang-fa07b40d.js";import{__tla as pt}from"./fixed-size-list-1ef224b0.js";let P,dt=Promise.all([(()=>{try{return L}catch{}})(),(()=>{try{return C}catch{}})(),(()=>{try{return X}catch{}})(),(()=>{try{return A}catch{}})(),(()=>{try{return K}catch{}})(),(()=>{try{return Q}catch{}})(),(()=>{try{return W}catch{}})(),(()=>{try{return Z}catch{}})(),(()=>{try{return tt}catch{}})(),(()=>{try{return rt}catch{}})(),(()=>{try{return at}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{}})(),(()=>{try{return pt}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:r,message:e}=o;return{min:t,max:r,message:e||l("common.lengthRange",{min:t,max:r})}},notSpace:o=>({validator:(t,r,e)=>{(r==null?void 0:r.indexOf(" "))!==-1?e(new Error(o||l("common.notSpace"))):e()}}),notSpecialCharacters:o=>({validator:(t,r,e)=>{/[`~!@#$%^&*()_+<>?:"{},.\/;'[\]]/gi.test(r)?e(new Error(o||l("common.notSpecialCharacters"))):e()}})}),u={class:"w-[100%] flex"},h={class:"w-[100%]"},f={class:"mt-15px w-[100%]"},g=E({name:"RegisterForm",__name:"RegisterForm",setup(o){const{t}=w(),{required:r}=d(),{register:e,elFormRef:v}=Y(),{handleBackLogin:R,getLoginState:k}=M(),b=V(()=>a(k)===N.REGISTER),x=$([{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:[r()],password:[r()],check_password:[r()],code:[r()]},i=j(!1);return(ut,_)=>{const q=O,y=z,U=I;return B((G(),H(U,{rules:S,schema:a(x),class:"dark:(border-1 border-[var(--el-border-color)] border-solid)","hide-required-asterisk":"","label-position":"top",size:"large",onRegister:a(e)},{title:m(()=>[c(J,{style:{width:"100%"}})]),code:m(n=>[p("div",u,[c(q,{modelValue:n.code,"onUpdate:modelValue":s=>n.code=s,placeholder:a(t)("login.codePlaceholder")},null,8,["modelValue","onUpdate:modelValue","placeholder"])])]),register:m(()=>[p("div",h,[c(y,{loading:a(i),title:a(t)("login.register"),class:"w-[100%]",type:"primary",onClick:_[0]||(_[0]=n=>(async()=>{const s=a(v);s==null||s.validate(async F=>{if(F)try{i.value=!0}finally{i.value=!1}})})())},null,8,["loading","title"])]),p("div",f,[c(y,{title:a(t)("login.hasUser"),class:"w-[100%]",onClick:_[1]||(_[1]=n=>a(R)())},null,8,["title"])])]),_:1},8,["schema","onRegister"])),[[D,a(b)]])}}}),P=T(g,[["__file","/Users/RuHu.Xu/Desktop/mall-newfeifan-zx-admin/src/views/Login/components/RegisterForm.vue"]])});export{dt as __tla,P as default};
