import{_ as U,__tla as C}from"./Form-8cd0e8df.js";import{_ as I,__tla as L}from"./XButton-c87840c8.js";import{n as w,d as V,b as G,a as r,f as O,r as j,C as z,a1 as A,o as B,l as H,w as m,i as c,g as p,U as T,_ as $,__tla as D}from"./index-2c56227b.js";import{u as J,__tla as K}from"./useForm-572c074d.js";import M,{__tla as N}from"./LoginFormTitle-8e188d5d.js";import{u as Q,L as W,__tla as X}from"./useLogin-f2594145.js";import{__tla as Y}from"./el-virtual-list-beaed7d2.js";import{__tla as Z}from"./el-tree-select-97cbdeb3.js";import{__tla as tt}from"./el-time-select-cf117266.js";import{__tla as at}from"./InputPassword-9eb7a182.js";import{__tla as rt}from"./Editor-d05caa83.js";import{__tla as et}from"./SPuUploadImg.vue_vue_type_style_index_0_scoped_ba706063_lang-6a2e2b1d.js";import{__tla as ot}from"./index-8d031f1e.js";import{__tla as lt}from"./el-image-viewer-da1b6008.js";import{__tla as st}from"./useMessage-96878a4a.js";import{__tla as _t}from"./UploadImg-6d25031e.js";import{__tla as nt}from"./UploadImgs-91d4d385.js";import{__tla as ct}from"./UploadImgs.vue_vue_type_style_index_0_scoped_9d666400_lang-e792c2fc.js";import{__tla as it}from"./UploadFile-9004484d.js";import{__tla as mt}from"./UploadFile.vue_vue_type_style_index_0_scoped_436eca1b_lang-ed1f393e.js";let P,pt=Promise.all([(()=>{try{return C}catch{}})(),(()=>{try{return L}catch{}})(),(()=>{try{return D}catch{}})(),(()=>{try{return K}catch{}})(),(()=>{try{return N}catch{}})(),(()=>{try{return X}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}=J(),{handleBackLogin:b,getLoginState:R}=Q(),k=G(()=>r(R)===W.REGISTER),x=O([{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=j(!1);return(dt,_)=>{const q=T,y=I,E=U;return z((B(),H(E,{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(M,{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 F=>{if(F)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(b)())},null,8,["title"])])]),_:1},8,["schema","onRegister"])),[[A,r(k)]])}}}),P=$(g,[["__file","E:/GAOHP_2023/mall/newfeifan-front/yudao-ui-admin-vue3/src/views/Login/components/RegisterForm.vue"]])});export{pt as __tla,P as default};
