import{_ as S}from"./index.vue_vue_type_style_index_0_lang-2d65f8f4.js";import{d as b,u as $,j as n,o as t,h as o,w as l,b as h,t as w,e as _,c as y,i as F,F as g,v as M,_ as C,X as A,A as I,f as k,r as f,K as E,z as R}from"./index-90c78f99.js";import{a as V,b as j}from"./processingMenu-b6b2564b.js";const q=b({__name:"sidebarItem",props:{index:String,title:String,item:{type:Object,required:!0},active:String},setup(e){const c=e,s=$(),a=u=>{s.push({name:u.index})};return(u,m)=>{const i=n("iconFont"),r=n("el-menu-item"),x=n("svg-icon"),d=n("sidebar-item",!0),v=n("el-sub-menu");return!(e.item.children&&e.item.children.length)&&e.item.meta.type==="MENU"?(t(),o(r,{key:0,index:c.index,onClick:a},{title:l(()=>[h("span",null,w(e.title),1)]),default:l(()=>[_(i,{"icon-name":"icon-earth",class:"menuIcon"})]),_:1},8,["index"])):(t(),y(g,{key:1},[e.item.meta.type==="MENU"?(t(),o(v,{key:0,index:c.index},{title:l(()=>[e.item.meta.icon?(t(),o(x,{key:0,name:e.index==e.active?e.item.meta.activeIcon:e.item.meta.uIcon,"svg-class":"menuIcon"},null,8,["name"])):F("",!0),h("span",null,w(e.title),1)]),default:l(()=>[(t(!0),y(g,null,M(e.item.children,p=>(t(),o(d,{key:p.name,index:p.name,title:p.meta.title,item:p},null,8,["index","title","item"]))),128))]),_:1},8,["index"])):F("",!0)],64))}}});const D=C(q,[["__scopeId","data-v-b275326c"]]),U=b({__name:"index",props:{isCollapse:{type:Boolean},sidebarMenu:null},setup(e){const c=e,s=A(()=>{const a=I(),{name:u}=a;return V(u)});return(a,u)=>{const m=n("el-menu");return t(),o(m,{"default-active":k(s),collapse:c.isCollapse,class:"el-menu-vertical-demo","unique-opened":""},{default:l(()=>[(t(!0),y(g,null,M(c.sidebarMenu,i=>(t(),o(D,{key:i.name,index:i.name,title:i.meta.title,item:i,active:k(s)},null,8,["index","title","item","active"]))),128))]),_:1},8,["default-active","collapse"])}}}),z={class:"mainBox"},K={class:"collapses"},L=b({__name:"index",emits:["collapseFn"],setup(e,{emit:c}){const s=I(),a=f(!1),u=f(s.path.split("/")[s.path.split("/").length-1]),m=()=>{a.value=!a.value,c("collapseFn",a.value)},i=f();return E(s,r=>{i.value=j(r.name)},{immediate:!0,deep:!0}),(r,x)=>{const d=n("el-scrollbar"),v=n("expand"),p=n("fold"),N=n("el-icon");return t(),y("div",z,[_(d,null,{default:l(()=>[_(U,{"sidebar-menu":i.value,"is-collapse":a.value,active:u.value},null,8,["sidebar-menu","is-collapse","active"])]),_:1}),h("div",K,[_(N,{color:"rgba(0, 0, 0, 0.45)"},{default:l(()=>[a.value?(t(),o(v,{key:0,onClick:m})):(t(),o(p,{key:1,onClick:m}))]),_:1})])])}}});const B=C(L,[["__scopeId","data-v-c95adc65"]]),O=b({__name:"index",setup(e){const c=f(!1),s=m=>{c.value=m},a=I(),u=a.name;return(m,i)=>{const r=n("router-view"),x=n("el-main"),d=n("el-container");return t(),o(d,{class:"overflow-hidden"},{default:l(()=>[_(B,{class:"aside",width:c.value?"64px":"180px"},{default:l(()=>[_(B,{onCollapseFn:s})]),_:1},8,["width"]),_(d,{class:"is-vertical relative"},{default:l(()=>[_(S),_(x,{class:"main flex-col",style:{display:"flex",overflow:"hidden"}},{default:l(()=>[(t(),o(r,{key:k(u)},{default:l(({Component:v})=>[(t(),o(R(v)))]),_:1}))]),_:1})]),_:1})]),_:1})}}});const J=C(O,[["__scopeId","data-v-b1320776"]]);export{J as default};
