const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/subItem.BqxpECh8.js","assets/vue.D1BjjNmv.js","assets/index.CL7yl-Wb.js","assets/index.DgHxlRHa.css"])))=>i.map(i=>d[i]);
import{u as I,_ as P,o as R}from"./index.CL7yl-Wb.js";import{a as g,aC as T,aB as q,_ as x,f as _,q as V,aK as W,w as $,aj as r,J as m,o as i,K as a,c as C,R as k,a9 as E,S as p,u as M,aA as O,b as d,Q as f,a8 as j,Y as H}from"./vue.D1BjjNmv.js";const K=["onClick"],N=g({name:"navMenuVertical"}),Q=g({...N,props:{menuList:{type:Array,default:()=>[]}},setup(y){const A=O(()=>P(()=>import("./subItem.BqxpECh8.js"),__vite__mapDeps([0,1,2,3]))),L=y,b=I(),{themeConfig:o}=T(b),l=q(),s=x({defaultActive:l.meta.isDynamic?l.meta.isDynamicPath:l.path,isCollapse:!1}),S=_(()=>L.menuList),v=_(()=>o.value),h=n=>{const{path:c,meta:t}=n,u=t!=null&&t.isDynamic?t.isDynamicPath.split("/"):c.split("/");return u.length>=4&&(t!=null&&t.isHide)?u.splice(0,3).join("/"):c},B=n=>{R.handleOpenLink(n)};return V(()=>{s.defaultActive=h(l)}),W(n=>{s.defaultActive=h(n),document.body.clientWidth<1e3&&(o.value.isCollapse=!1)}),$(o.value,()=>{document.body.clientWidth<=1e3?s.isCollapse=!1:s.isCollapse=o.value.isCollapse},{immediate:!0}),(n,c)=>{const t=r("SvgIcon"),u=r("el-sub-menu"),D=r("el-menu-item"),w=r("el-menu");return i(),m(w,{router:"","default-active":s.defaultActive,"background-color":"transparent",collapse:s.isCollapse,"unique-opened":v.value.isUniqueOpened,"collapse-transition":!1},{default:a(()=>[(i(!0),C(k,null,E(S.value,e=>(i(),C(k,null,[e.children&&e.children.length>0?(i(),m(u,{index:e.path,key:e.path},{title:a(()=>[p(t,{name:e.meta.icon},null,8,["name"]),d("span",null,f(n.$t(e.meta.title)),1)]),default:a(()=>[p(M(A),{chil:e.children},null,8,["chil"])]),_:2},1032,["index"])):(i(),m(D,{index:e.path,key:e.path},j({default:a(()=>[p(t,{name:e.meta.icon},null,8,["name"])]),_:2},[!e.meta.isLink||e.meta.isLink&&e.meta.isIframe?{name:"title",fn:a(()=>[d("span",null,f(n.$t(e.meta.title)),1)]),key:"0"}:{name:"title",fn:a(()=>[d("a",{class:"w100",onClick:H(U=>B(e),["prevent"])},f(n.$t(e.meta.title)),9,K)]),key:"1"}]),1032,["index"]))],64))),256))]),_:1},8,["default-active","collapse","unique-opened"])}}});export{Q as default};
