import{_ as E,__tla as I}from"./Form-f0a2ebc5.js";import{_ as C,__tla as U}from"./XButton-549118e6.js";import{i as w,d as V,L as z,a as r,f as j,r as B,y as D,a6 as G,o as O,x as T,w as m,g as c,h as p,X,_ as $,__tla as A}from"./index-7d5b26d3.js";import{u as H,__tla as J}from"./useForm-add9a971.js";import K,{__tla as M}from"./LoginFormTitle-b4de2b34.js";import{u as N,L as Q,__tla as W}from"./useLogin-c7b661e2.js";import{__tla as Y}from"./el-virtual-list-49b78666.js";import{__tla as Z}from"./el-tree-select-50c86e57.js";import{__tla as tt}from"./el-time-select-49fb9204.js";import{__tla as at}from"./InputPassword-1783ab10.js";import{__tla as rt}from"./InputPassword.vue_vue_type_style_index_0_scoped_3f07eb1d_lang-5d0205e1.js";import{__tla as et}from"./Editor-7cbdb87d.js";import{__tla as ot}from"./SPuUploadImg.vue_vue_type_style_index_0_scoped_ba706063_lang-a1c2c60d.js";import{__tla as lt}from"./index-ac2a9b6d.js";import{__tla as st}from"./el-image-viewer-2f0c9a58.js";import{__tla as _t}from"./useMessage-c81eaa5b.js";import{__tla as nt}from"./UploadImg-1c4fc0d0.js";import{__tla as ct}from"./UploadImgs-6c31b7c6.js";import{__tla as it}from"./UploadImgs.vue_vue_type_style_index_0_scoped_9d666400_lang-4277b60d.js";import{__tla as mt}from"./UploadFile-b1c4eb43.js";import{__tla as pt}from"./UploadFile.vue_vue_type_style_index_0_scoped_436eca1b_lang-cd2ab574.js";let P,dt=Promise.all([(()=>{try{return I}catch{}})(),(()=>{try{return U}catch{}})(),(()=>{try{return A}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{}})(),(()=>{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: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}=H(),{handleBackLogin:R,getLoginState:b}=N(),x=z(()=>r(b)===Q.REGISTER),k=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(ut,_)=>{const q=X,y=C,F=E;return D((O(),T(F,{rules:S,schema:r(k),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(q,{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 L=>{if(L)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(x)]])}}}),P=$(g,[["__file","D:/zx/mall-newfeifan-zx-business/src/views/Login/components/RegisterForm.vue"]])});export{dt as __tla,P as default};
