import{_ as D,h as H,u as V,o as w,e as E}from"./index-a6ee13d3.js";import{H as L,aP as M,_ as O,j,E as v,ah as l,o as s,c as p,V as r,P as a,F as h,a8 as F,O as k,a as C,U as u,u as N,aa as U,T as g,a3 as q}from"./@vue-6dabbe94.js";import{u as G,o as J}from"./vue-router-c1461dfc.js";import{s as y}from"./pinia-b6f74250.js";import{_ as K}from"./_plugin-vue_export-helper-c27b6911.js";import"./vue-i18n-b3581196.js";import"./@intlify-ea47d1db.js";import"./source-map-7d7e1c08.js";import"./vue-b1ba6f14.js";import"./js-cookie-edb2da2a.js";import"./@element-plus-64e6e14a.js";import"./nprogress-08a53ce8.js";import"./axios-4a70c6fc.js";import"./qs-c5b6dbf2.js";import"./side-channel-394f276c.js";import"./get-intrinsic-bd2830fd.js";import"./has-symbols-e8f3ca0e.js";import"./has-proto-f7d0b240.js";import"./function-bind-22e7ee79.js";import"./has-26d28e02.js";import"./call-bind-e5c1c8b0.js";import"./object-inspect-8fd4bade.js";import"./element-plus-91d6d961.js";import"./lodash-es-9851428c.js";import"./@vueuse-e129c873.js";import"./@popperjs-c75af06c.js";import"./@ctrl-f8748455.js";import"./dayjs-f6fdf7b4.js";import"./async-validator-dee29e8b.js";import"./memoize-one-297ddbcb.js";import"./escape-html-b8998962.js";import"./normalize-wheel-es-ed76fb12.js";import"./@floating-ui-880a26aa.js";import"./mitt-f7ef348c.js";import"./vue-grid-layout-ec2a62c3.js";const Q={class:"el-menu-horizontal-warp"},W=L({name:"navMenuHorizontal"}),X=L({...W,props:{menuList:{type:Array,default:()=>[]}},setup(S){const A=S,x=M(()=>D(()=>import("./subItem-cdf0467d.js"),["assets/js/subItem-cdf0467d.js","assets/js/@vue-6dabbe94.js","assets/js/index-a6ee13d3.js","assets/js/pinia-b6f74250.js","assets/js/vue-router-c1461dfc.js","assets/js/vue-i18n-b3581196.js","assets/js/@intlify-ea47d1db.js","assets/js/source-map-7d7e1c08.js","assets/js/vue-b1ba6f14.js","assets/js/js-cookie-edb2da2a.js","assets/js/@element-plus-64e6e14a.js","assets/js/nprogress-08a53ce8.js","assets/css/nprogress-8b89e2e0.css","assets/js/axios-4a70c6fc.js","assets/js/qs-c5b6dbf2.js","assets/js/side-channel-394f276c.js","assets/js/get-intrinsic-bd2830fd.js","assets/js/has-symbols-e8f3ca0e.js","assets/js/has-proto-f7d0b240.js","assets/js/function-bind-22e7ee79.js","assets/js/has-26d28e02.js","assets/js/call-bind-e5c1c8b0.js","assets/js/object-inspect-8fd4bade.js","assets/js/element-plus-91d6d961.js","assets/js/lodash-es-9851428c.js","assets/js/@vueuse-e129c873.js","assets/js/@popperjs-c75af06c.js","assets/js/@ctrl-f8748455.js","assets/js/dayjs-f6fdf7b4.js","assets/js/async-validator-dee29e8b.js","assets/js/memoize-one-297ddbcb.js","assets/js/escape-html-b8998962.js","assets/js/normalize-wheel-es-ed76fb12.js","assets/js/@floating-ui-880a26aa.js","assets/js/mitt-f7ef348c.js","assets/js/vue-grid-layout-ec2a62c3.js","assets/css/fastcms-01cf5f8f.css"])),R=H(),B=V(),{routesList:I}=y(R),{themeConfig:d}=y(B),P=G(),c=O({defaultActive:""}),T=j(()=>A.menuList),_=o=>o.filter(t=>{var e;return!((e=t.meta)!=null&&e.isHide)}).map(t=>(t=Object.assign({},t),t.children&&(t.children=_(t.children)),t)),$=o=>{const t=o.split("/");let e={children:[]};return _(I.value).map((i,m)=>{i.path===`/${t[1]}`&&(i.k=m,e.item={...i},e.children=[{...i}],i.children&&(e.children=i.children))}),e},f=o=>{const{path:t,meta:e}=o;if(d.value.layout==="classic")c.defaultActive=`/${t==null?void 0:t.split("/")[1]}`;else{const i=e!=null&&e.isDynamic?e.isDynamicPath.split("/"):t.split("/");i.length>=4&&(e!=null&&e.isHide)?c.defaultActive=i.splice(0,3).join("/"):c.defaultActive=t}},b=o=>{w.handleOpenLink(o)};return v(()=>{f(P)}),J(o=>{f(o);let{layout:t,isClassicSplitMenu:e}=d.value;t==="classic"&&e&&E.emit("setSendClassicChildren",$(o.path))}),(o,t)=>{const e=l("SvgIcon"),i=l("el-sub-menu"),m=l("el-menu-item"),z=l("el-menu");return s(),p("div",Q,[r(z,{router:"","default-active":c.defaultActive,"background-color":"transparent",mode:"horizontal"},{default:a(()=>[(s(!0),p(h,null,F(T.value,n=>(s(),p(h,null,[n.children&&n.children.length>0?(s(),k(i,{index:n.path,key:n.path},{title:a(()=>[r(e,{name:n.meta.icon},null,8,["name"]),C("span",null,u(o.$t(n.meta.title)),1)]),default:a(()=>[r(N(x),{chil:n.children},null,8,["chil"])]),_:2},1032,["index"])):(s(),k(m,{index:n.path,key:n.path},U({_:2},[!n.meta.isLink||n.meta.isLink&&n.meta.isIframe?{name:"title",fn:a(()=>[r(e,{name:n.meta.icon},null,8,["name"]),g(" "+u(o.$t(n.meta.title)),1)]),key:"0"}:{name:"title",fn:a(()=>[C("a",{class:"w100",onClick:q(Y=>b(n),["prevent"])},[r(e,{name:n.meta.icon},null,8,["name"]),g(" "+u(o.$t(n.meta.title)),1)],8,["onClick"])]),key:"1"}]),1032,["index"]))],64))),256))]),_:1},8,["default-active"])])}}});const He=K(X,[["__scopeId","data-v-f4ca57f2"]]);export{He as default};
