var C=(s,a,n)=>new Promise((t,i)=>{var u=e=>{try{o(n.next(e))}catch(r){i(r)}},m=e=>{try{o(n.throw(e))}catch(r){i(r)}},o=e=>e.done?t(e.value):Promise.resolve(e.value).then(u,m);o((n=n.apply(s,a)).next())});import{u as x,b as S,_ as E,i as g,f as T,h as v,j as M,s as V,p as y,k as P}from"./index-OziN21LA.js";import{u as w}from"./useIcon-83DHkr7U.js";import{t as O,u as j,v as A,w as N}from"./element-plus-C2aeItNs.js";import{l as b,r as R,m as _,M as f,I as h,u as c,e as I,ai as z,O as p,U as D,p as B,a7 as $,F,S as H,T as U}from"./vue-chunks-l-AyUCfi.js";const Y="/assets/logo-CRQ9AZN7.png",d="var(--el-color-black)",Q=b({__name:"ThemeSwitch",emits:["change"],setup(s,{emit:a}){const{getPrefixCls:n}=S(),t=a,i=n("theme-switch"),u=w({icon:"emojione-monotone:sun",color:"#fde047"}),m=w({icon:"emojione-monotone:crescent-moon",color:"#fde047"}),o=x(),e=R(o.getIsDark),r=l=>{o.setIsDark(l),t("change",l)};return(l,L)=>(_(),f(c(O),{class:h(c(i)),modelValue:e.value,"onUpdate:modelValue":L[0]||(L[0]=k=>e.value=k),"inline-prompt":"","border-color":d,"inactive-color":d,"active-color":d,"active-icon":c(u),"inactive-icon":c(m),onChange:r},null,8,["class","modelValue","active-icon","inactive-icon"]))}}),ee=E(Q,[["__scopeId","data-v-31b4ac8f"]]),W=s=>{const a=M();g.mode==="legacy"?g.global.locale=s:g.global.locale.value=s,a.setCurrentLocale({lang:s}),V(s)},Z=()=>({changeLocale:a=>C(void 0,null,function*(){const n=g.global,t=yield T(Object.assign({"../../locales/en.ts":()=>v(()=>import("./en-BNiiGjg-.js"),__vite__mapDeps([])),"../../locales/zh-CN.ts":()=>v(()=>import("./zh-CN-DpWw8Tp3.js"),__vite__mapDeps([]))}),`../../locales/${a}.ts`);n.setLocaleMessage(a,t.default),W(a)})}),oe=b({__name:"LocaleDropdown",props:{color:y.string.def("")},setup(s){const{getPrefixCls:a}=S(),n=a("locale-dropdown"),t=P(),i=I(()=>t.getLocaleMap),u=I(()=>t.getCurrentLocale),m=o=>{if(o===c(u).lang)return;window.location.reload(),t.setCurrentLocale({lang:o});const{changeLocale:e}=Z();e(o)};return(o,e)=>{const r=z("Icon");return _(),f(c(A),{class:h(c(n)),trigger:"click",onCommand:m},{dropdown:p(()=>[D(c(j),null,{default:p(()=>[(_(!0),B(F,null,$(i.value,l=>(_(),f(c(N),{key:l.lang,command:l.lang},{default:p(()=>[H(U(l.name),1)]),_:2},1032,["command"]))),128))]),_:1})]),default:p(()=>[D(r,{size:18,icon:"ion:language-sharp",class:h(["cursor-pointer !p-0",o.$attrs.class]),color:s.color},null,8,["class","color"])]),_:1},8,["class"])}}});export{ee as T,oe as _,Y as a};
function __vite__mapDeps(indexes) {
  if (!__vite__mapDeps.viteFileDeps) {
    __vite__mapDeps.viteFileDeps = []
  }
  return indexes.map((i) => __vite__mapDeps.viteFileDeps[i])
}
