import{d as b,Z as E,r as I,o as u,v as w,a as o,P as V,$ as L,a1 as D,d6 as A,_ as y,dj as d,dk as O,O as C,dl as S,dm as $,ah as M,bA as R,K as x,w as p,f as T,c as q,q as F,n as K,t as N,F as U,j as Z,__tla as B}from"./index-04f8d540.js";import{u as k,__tla as G}from"./useIcon-9fce6e03.js";import{b as H,E as J,a as Q,__tla as W}from"./el-dropdown-item-6aa7900e.js";let z,P,X=Promise.all([(()=>{try{return B}catch{}})(),(()=>{try{return G}catch{}})(),(()=>{try{return W}catch{}})()]).then(async()=>{let i,v;i="var(--el-color-black)",P=y(b({name:"ThemeSwitch",__name:"ThemeSwitch",setup(l){const{getPrefixCls:s}=D(),c=s("theme-switch"),a=k({icon:"emojione-monotone:sun",color:"#fde047"}),n=k({icon:"emojione-monotone:crescent-moon",color:"#fde047"}),m=E(),t=I(m.getIsDark),e=r=>{m.setIsDark(r)};return(r,_)=>{const g=A;return u(),w(g,{modelValue:o(t),"onUpdate:modelValue":_[0]||(_[0]=f=>V(t)?t.value=f:null),"active-color":i,"active-icon":o(a),"border-color":i,class:L(o(c)),"inactive-color":i,"inactive-icon":o(n),"inline-prompt":"",onChange:e},null,8,["modelValue","active-icon","class","inactive-icon"])}}}),[["__scopeId","data-v-78cd11f1"],["__file","D:/zx/mall-newfeifan-zx-business/src/layout/components/ThemeSwitch/src/ThemeSwitch.vue"]]),v=()=>({changeLocale:async l=>{const s=d.global,c=await O(Object.assign({"../../locales/en.ts":()=>C(()=>import("./en-706ee4dd.js"),[]),"../../locales/zh-CN.ts":()=>C(()=>import("./zh-CN-3441a76e.js"),[])}),`../../locales/${l}.ts`);s.setLocaleMessage(l,c.default),(a=>{const n=S();d.mode==="legacy"?d.global.locale=a:d.global.locale.value=a,n.setCurrentLocale({lang:a}),$(a)})(l)}}),z=y(b({name:"LocaleDropdown",__name:"LocaleDropdown",props:{color:M.string.def("")},setup(l){const{getPrefixCls:s}=D(),c=s("locale-dropdown"),a=R(),n=x(()=>a.getLocaleMap),m=x(()=>a.getCurrentLocale),t=e=>{if(e===o(m).lang)return;window.location.reload(),a.setCurrentLocale({lang:e});const{changeLocale:r}=v();r(e)};return(e,r)=>{const _=Z,g=J,f=Q,j=H;return u(),w(j,{class:L(o(c)),trigger:"click",onCommand:t},{dropdown:p(()=>[T(f,null,{default:p(()=>[(u(!0),q(U,null,F(o(n),h=>(u(),w(g,{key:h.lang,command:h.lang},{default:p(()=>[K(N(h.name),1)]),_:2},1032,["command"]))),128))]),_:1})]),default:p(()=>[T(_,{class:L([e.$attrs.class,"cursor-pointer !p-0"]),color:l.color,size:18,icon:"ion:language-sharp"},null,8,["class","color"])]),_:1},8,["class"])}}}),[["__file","D:/zx/mall-newfeifan-zx-business/src/layout/components/LocaleDropdown/src/LocaleDropdown.vue"]])});export{z as L,P as T,X as __tla};
