var Xn=Object.defineProperty;var mn=Object.getOwnPropertySymbols;var Yn=Object.prototype.hasOwnProperty,jn=Object.prototype.propertyIsEnumerable;var pn=(e,t,n)=>t in e?Xn(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,N=(e,t)=>{for(var n in t||(t={}))Yn.call(t,n)&&pn(e,n,t[n]);if(mn)for(var n of mn(t))jn.call(t,n)&&pn(e,n,t[n]);return e};import{J as ae,ay as U,l as oe,o as y,a as L,b as V,X as H,a5 as T,a8 as Qe,F as me,Q as Y,R,Y as I,W as Ae,aE as ut,aG as Rt,a1 as Ce,k as He,aI as Ft,a4 as Se,at as Wn,V as ee,a0 as Be,f as je,n as nt,L as ot,M as Dt,j as ct,aC as Tn,aD as Dn,I as In,a9 as Gn,G as an,g as It,S as sn,T as rn,Z as Un,aj as Qn}from"./vue.1683511265143.js";import{u as Ie,_ as ie,b as Mt,C as Lt,L as Ee,e as $t,f as Ln,g as Kn,E as Jt,d as Zn,k as Jn,S as we,N as $n,l as zt,c as eo,m as to,p as no,D as qt}from"./index.1683511265143.js";import{s as gt}from"./index.16835112651436.js";import{l as oo}from"./logo-mini.1683511265143.js";import ao from"./parent.1683511265143.js";const io=ae({name:"layoutLogo",setup(){const e=Ie(),{themeConfig:t}=U(e),n=oe(()=>{let{isCollapse:a,layout:s}=t.value;return!a||s==="classic"||document.body.clientWidth<1e3});return{logoMini:oo,setShowLogo:n,themeConfig:t,onThemeConfigChange:()=>{if(t.value.layout==="transverse")return!1;t.value.isCollapse=!t.value.isCollapse}}}}),so=["src"],ro=["src"];function lo(e,t,n,o,a,s){return e.setShowLogo?(y(),L("div",{key:0,class:"layout-logo",onClick:t[0]||(t[0]=(...i)=>e.onThemeConfigChange&&e.onThemeConfigChange(...i))},[V("img",{src:e.logoMini,class:"layout-logo-medium-img"},null,8,so),V("span",null,H(e.themeConfig.globalTitle),1)])):(y(),L("div",{key:1,class:"layout-logo-size",onClick:t[1]||(t[1]=(...i)=>e.onThemeConfigChange&&e.onThemeConfigChange(...i))},[V("img",{src:e.logoMini,class:"layout-logo-size-img"},null,8,ro)]))}var uo=ie(io,[["render",lo],["__scopeId","data-v-3d08a39b"]]);const co=ae({name:"navMenuSubItem",props:{chil:{type:Array,default:()=>[]}},setup(e){return{chils:oe(()=>e.chil)}}}),fo=["href"];function ho(e,t,n,o,a,s){const i=T("SvgIcon"),r=T("sub-item",!0),l=T("el-sub-menu"),c=T("el-menu-item");return y(!0),L(me,null,Qe(e.chils,h=>(y(),L(me,null,[h.children&&h.children.length>0?(y(),Y(l,{index:h.path,key:h.path},{title:R(()=>[I(i,{name:h.meta.icon},null,8,["name"]),V("span",null,H(e.$t(h.meta.title)),1)]),default:R(()=>[I(r,{chil:h.children},null,8,["chil"])]),_:2},1032,["index"])):(y(),Y(c,{index:h.path,key:h.path},{default:R(()=>[!h.meta.isLink||h.meta.isLink&&h.meta.isIframe?(y(),L(me,{key:0},[I(i,{name:h.meta.icon},null,8,["name"]),V("span",null,H(e.$t(h.meta.title)),1)],64)):(y(),L("a",{key:1,href:h.meta.isLink,target:"_blank",rel:"opener",class:"w100"},[I(i,{name:h.meta.icon},null,8,["name"]),Ae(" "+H(e.$t(h.meta.title)),1)],8,fo))]),_:2},1032,["index"]))],64))),256)}var mo=ie(co,[["render",ho]]);const po=ae({name:"layoutBreadcrumb",setup(){const e=Mt(),t=Ie(),{themeConfig:n}=U(t),{routesList:o}=U(e),a=ut(),s=Rt(),i=Ce({breadcrumbList:[],routeSplit:[],routeSplitFirst:"",routeSplitIndex:1}),r=oe(()=>{w(a.path);const{layout:u,isBreadcrumb:p}=n.value;return u==="classic"||u==="transverse"?!1:!!p}),l=u=>{const{redirect:p,path:g}=u;p?s.push(p):s.push(g)},c=()=>{n.value.isCollapse=!n.value.isCollapse,h()},h=()=>{Ee.remove("themeConfig"),Ee.set("themeConfig",n.value)},d=u=>{u.forEach(p=>{i.routeSplit.forEach((g,D,A)=>{i.routeSplitFirst===p.path&&(i.routeSplitFirst+=`/${A[i.routeSplitIndex]}`,i.breadcrumbList.push(p),i.routeSplitIndex++,p.children&&d(p.children))})})},w=u=>{if(!n.value.isBreadcrumb)return!1;i.breadcrumbList=[o.value[0]],i.routeSplit=u.split("/"),i.routeSplit.shift(),i.routeSplitFirst=`/${i.routeSplit[0]}`,i.routeSplitIndex=1,d(o.value),(a.name==="home"||a.name==="notFound"&&i.breadcrumbList.length>1)&&i.breadcrumbList.shift(),i.breadcrumbList.length>0&&(i.breadcrumbList[i.breadcrumbList.length-1].meta.tagsViewName=Lt.setTagsViewNameI18n(a))};return He(()=>{w(a.path)}),Ft(u=>{w(u.path)}),N({onThemeConfigChange:c,isShowBreadcrumb:r,themeConfig:n,onBreadcrumbClick:l},Se(i))}}),go={key:0,class:"layout-navbars-breadcrumb"},vo={key:0,class:"layout-navbars-breadcrumb-span"},wo={key:1},bo={key:2},_o=["onClick"];function yo(e,t,n,o,a,s){const i=T("SvgIcon"),r=T("el-breadcrumb-item"),l=T("el-breadcrumb");return e.isShowBreadcrumb?(y(),L("div",go,[I(i,{class:"layout-navbars-breadcrumb-icon",name:e.themeConfig.isCollapse?"ele-Expand":"ele-Fold",size:16,onClick:e.onThemeConfigChange},null,8,["name","onClick"]),I(l,{class:"layout-navbars-breadcrumb-hide"},{default:R(()=>[I(Wn,{name:"breadcrumb"},{default:R(()=>[(y(!0),L(me,null,Qe(e.breadcrumbList,(c,h)=>(y(),Y(r,{key:c.meta.tagsViewName?c.meta.tagsViewName:c.meta.title},{default:R(()=>[h===e.breadcrumbList.length-1?(y(),L("span",vo,[e.themeConfig.isBreadcrumbIcon?(y(),Y(i,{key:0,name:c.meta.icon,class:"layout-navbars-breadcrumb-iconfont"},null,8,["name"])):ee("",!0),c.meta.tagsViewName?(y(),L("div",bo,H(c.meta.tagsViewName),1)):(y(),L("div",wo,H(e.$t(c.meta.title)),1))])):(y(),L("a",{key:1,onClick:Be(d=>e.onBreadcrumbClick(c),["prevent"])},[e.themeConfig.isBreadcrumbIcon?(y(),Y(i,{key:0,name:c.meta.icon,class:"layout-navbars-breadcrumb-iconfont"},null,8,["name"])):ee("",!0),Ae(H(e.$t(c.meta.title)),1)],8,_o))]),_:2},1024))),128))]),_:1})]),_:1})])):ee("",!0)}var Co=ie(po,[["render",yo],["__scopeId","data-v-7915d3e2"]]);const So=ae({name:"layoutBreadcrumbUserNews",setup(){const e=Ce({newsList:[{label:"\u5173\u4E8E\u7248\u672C\u53D1\u5E03\u7684\u901A\u77E5",value:"vue-next-admin\uFF0C\u57FA\u4E8E vue3 + CompositionAPI + typescript + vite + element plus\uFF0C\u6B63\u5F0F\u53D1\u5E03\u65F6\u95F4\uFF1A2021\u5E7402\u670828\u65E5\uFF01",time:"2020-12-08"},{label:"\u5173\u4E8E\u5B66\u4E60\u4EA4\u6D41\u7684\u901A\u77E5",value:"QQ\u7FA4\u53F7\u7801 665452019\uFF0C\u6B22\u8FCE\u5C0F\u4F19\u4F34\u5165\u7FA4\u5B66\u4E60\u4EA4\u6D41\u63A2\u8BA8\uFF01",time:"2020-12-08"}]});return N({onAllReadClick:()=>{e.newsList=[]},onGoToGiteeClick:()=>{window.open("https://gitee.com/lyt-top/vue-next-admin")}},Se(e))}}),Eo={class:"layout-navbars-breadcrumb-user-news"},To={class:"head-box"},Do={class:"head-box-title"},Io={class:"content-box"},Lo={class:"content-box-msg"},$o={class:"content-box-time"};function ko(e,t,n,o,a,s){const i=T("el-empty");return y(),L("div",Eo,[V("div",To,[V("div",Do,H(e.$t("message.user.newTitle")),1),e.newsList.length>0?(y(),L("div",{key:0,class:"head-box-btn",onClick:t[0]||(t[0]=(...r)=>e.onAllReadClick&&e.onAllReadClick(...r))},H(e.$t("message.user.newBtn")),1)):ee("",!0)]),V("div",Io,[e.newsList.length>0?(y(!0),L(me,{key:0},Qe(e.newsList,(r,l)=>(y(),L("div",{class:"content-box-item",key:l},[V("div",null,H(r.label),1),V("div",Lo,H(r.value),1),V("div",$o,H(r.time),1)]))),128)):(y(),Y(i,{key:1,description:e.$t("message.user.newDesc")},null,8,["description"]))]),e.newsList.length>0?(y(),L("div",{key:0,class:"foot-box",onClick:t[1]||(t[1]=(...r)=>e.onGoToGiteeClick&&e.onGoToGiteeClick(...r))},H(e.$t("message.user.newGo")),1)):ee("",!0)])}var Vo=ie(So,[["render",ko],["__scopeId","data-v-31e50f96"]]);const Ao=ae({name:"layoutBreadcrumbSearch",setup(){const e=$t(),{tagsViewRoutes:t}=U(e),n=je(),{t:o}=Ln(),a=Rt(),s=Ce({isShowSearch:!1,menuQuery:"",tagsViewList:[]}),i=()=>{s.menuQuery="",s.isShowSearch=!0,h(),nt(()=>{setTimeout(()=>{n.value.focus()})})},r=()=>{s.isShowSearch=!1},l=(u,p)=>{let g=u?s.tagsViewList.filter(c(u)):s.tagsViewList;p(g)},c=u=>p=>p.path.toLowerCase().indexOf(u.toLowerCase())>-1||p.meta.title.toLowerCase().indexOf(u.toLowerCase())>-1||o(p.meta.title).indexOf(u.toLowerCase())>-1,h=()=>{if(s.tagsViewList.length>0)return!1;t.value.map(u=>{u.meta.isHide||s.tagsViewList.push(N({},u))})};return N({layoutMenuAutocompleteRef:n,openSearch:i,closeSearch:r,menuSearch:l,onHandleSelect:u=>{let{path:p,redirect:g}=u;u.meta.isLink&&!u.meta.isIframe?window.open(u.meta.isLink):g?a.push(g):a.push(p),r()},onSearchBlur:()=>{r()}},Se(s))}}),xo={class:"layout-search-dialog"};function Oo(e,t,n,o,a,s){const i=T("ele-Search"),r=T("el-icon"),l=T("SvgIcon"),c=T("el-autocomplete"),h=T("el-dialog");return y(),L("div",xo,[I(h,{modelValue:e.isShowSearch,"onUpdate:modelValue":t[1]||(t[1]=d=>e.isShowSearch=d),width:"300px","destroy-on-close":"",modal:!1,fullscreen:"","show-close":!1},{default:R(()=>[I(c,{modelValue:e.menuQuery,"onUpdate:modelValue":t[0]||(t[0]=d=>e.menuQuery=d),"fetch-suggestions":e.menuSearch,placeholder:e.$t("message.user.searchPlaceholder"),ref:"layoutMenuAutocompleteRef",onSelect:e.onHandleSelect,onBlur:e.onSearchBlur},{prefix:R(()=>[I(r,{class:"el-input__icon"},{default:R(()=>[I(i)]),_:1})]),default:R(({item:d})=>[V("div",null,[I(l,{name:d.meta.icon,class:"mr5"},null,8,["name"]),Ae(" "+H(e.$t(d.meta.title)),1)])]),_:1},8,["modelValue","fetch-suggestions","placeholder","onSelect","onBlur"])]),_:1},8,["modelValue"])])}var Ro=ie(Ao,[["render",Oo],["__scopeId","data-v-6caca869"]]),Fo="http://121.239.169.27:7000/assets/company.1683511265143.png",Mo="http://121.239.169.27:7000/assets/icon.1683511265143.jpg";const No=eo(),Po=ae({name:"layoutBreadcrumbUser",components:{UserNews:Vo,Search:Ro},setup(){const{t:e}=Ln(),{proxy:t}=ct(),n=Rt(),o=Kn();U(Mt());const a=Ie(),{userInfos:s}=U(o),{themeConfig:i}=U(a),r=je(),l=Ce({isScreenfull:!1,disabledI18n:"zh-cn",disabledSize:"large",systemName:""}),c=oe(()=>{let O="";const{layout:z,isClassicSplitMenu:W}=i.value;return["defaults","columns"].includes(z)||z==="classic"&&!W?O="1":O="",O}),h=()=>{if(!gt.isEnabled)return Jt.warning("\u6682\u4E0D\u4E0D\u652F\u6301\u5168\u5C4F"),!1;gt.toggle(),gt.on("change",()=>{gt.isFullscreen?l.isScreenfull=!0:l.isScreenfull=!1})},d=()=>{t.mittBus.emit("openSetingsDrawer")},w=O=>{O==="logOut"?Zn({closeOnClickModal:!1,closeOnPressEscape:!1,title:e("message.user.logOutTitle"),message:e("message.user.logOutMessage"),showCancelButton:!0,confirmButtonText:e("message.user.logOutConfirm"),cancelButtonText:e("message.user.logOutCancel"),buttonSize:"default",beforeClose:(z,W,ue)=>{z==="confirm"?(W.confirmButtonLoading=!0,W.confirmButtonText=e("message.user.logOutExit"),setTimeout(()=>{ue(),setTimeout(()=>{W.confirmButtonLoading=!1},300)},700)):ue()}}).then(async()=>{let z=await Jn().signOut();z.data.code===100?(we.clear(),window.location.reload()):Jt({type:"warning",message:z.data.msg})}).catch(()=>{}):O==="wareHouse"?window.open("https://gitee.com/lyt-top/vue-next-admin"):n.push(O)},u=()=>{r.value.openSearch()},p=O=>{Ee.remove("themeConfig"),i.value.globalComponentSize=O,Ee.set("themeConfig",i.value),x(),window.location.reload()},g=O=>{Ee.remove("themeConfig"),i.value.globalI18n=O,Ee.set("themeConfig",i.value),t.$i18n.locale=O,A(),Lt.useTitle()},D=O=>{t.mittBus.emit("getI18nConfig",t.$i18n.messages[O])},A=()=>{switch(Ee.get("themeConfig").globalI18n){case"zh-cn":l.disabledI18n="zh-cn",D("zh-cn");break;case"en":l.disabledI18n="en",D("en");break;case"zh-tw":l.disabledI18n="zh-tw",D("zh-tw");break}},x=()=>{switch(Ee.get("themeConfig").globalComponentSize){case"large":l.disabledSize="large";break;case"default":l.disabledSize="default";break;case"small":l.disabledSize="small";break}},Q=async()=>{if(window.nextLoading===void 0&&$n.start(),!zt.get("token"))return!1;const O=await No.getMenuAdmin(zt.get("projectId")===null?"":zt.get("projectId"));O.data.code==="200"?l.systemName=O.data.data[1].project.projectName:console.log("\u6709\u95EE\u9898")},j=()=>{n.push({path:"newMenu"})};return He(()=>{Ee.get("themeConfig")&&(A(),x()),Q()}),N({userInfos:s,toHome:j,onLayoutSetingClick:d,onHandleCommandClick:w,onScreenfullClick:h,onSearchClick:u,onComponentSizeChange:p,onLanguageChange:g,searchRef:r,layoutUserFlexNum:c},Se(l))}}),kn=e=>(Tn("data-v-9215dfb4"),e=e(),Dn(),e),Bo=kn(()=>V("div",{class:"logo"},[V("img",{src:Fo})],-1)),Ho={style:{display:"flex","align-items":"center","padding-right":"5px"}},zo=["title"],qo={class:"layout-navbars-breadcrumb-user-link"},Xo=kn(()=>V("img",{src:Mo,class:"layout-navbars-breadcrumb-user-link-photo mr5",style:{width:"24px",height:"24px"}},null,-1));function Yo(e,t,n,o,a,s){const i=T("ele-ArrowDown"),r=T("el-icon"),l=T("el-dropdown-item"),c=T("el-dropdown-menu"),h=T("el-dropdown"),d=T("Search");return y(),L("div",{class:"layout-navbars-breadcrumb-user pr15",style:Dt({flex:e.layoutUserFlexNum})},[Bo,V("div",Ho,[V("div",{class:"layout-navbars-breadcrumb-user-icon mr10",onClick:t[0]||(t[0]=(...w)=>e.onScreenfullClick&&e.onScreenfullClick(...w))},[V("i",{class:ot(["iconfont",e.isScreenfull?"icon-tuichuquanping":"icon-fullscreen"]),title:e.isScreenfull?e.$t("message.user.title6"):e.$t("message.user.title5")},null,10,zo)]),I(h,{"show-timeout":70,"hide-timeout":50,onCommand:e.onHandleCommandClick},{dropdown:R(()=>[I(c,null,{default:R(()=>[I(l,{command:"/project"},{default:R(()=>[Ae(H(e.$t("message.user.dropdown1")),1)]),_:1}),I(l,{divided:"",command:"logOut"},{default:R(()=>[Ae(H(e.$t("message.user.dropdown5")),1)]),_:1})]),_:1})]),default:R(()=>[V("span",qo,[Xo,Ae(" "+H(e.userInfos.userName)+" ",1),I(r,{class:"el-icon--right"},{default:R(()=>[I(i)]),_:1})])]),_:1},8,["onCommand"]),I(d,{ref:"searchRef"},null,512)])],4)}var jo=ie(Po,[["render",Yo],["__scopeId","data-v-9215dfb4"]]);const Wo=ae({name:"navMenuHorizontal",components:{SubItem:mo},props:{menuList:{type:Array,default:()=>[]}},setup(e){const{proxy:t}=ct(),n=Mt(),o=Ie(),{routesList:a}=U(n),{themeConfig:s}=U(o),i=ut(),r=Ce({defaultActive:null}),l=oe(()=>e.menuList),c=p=>{const g=p.wheelDelta||-p.deltaY*40;t.$refs.elMenuHorizontalScrollRef.$refs.wrap$.scrollLeft=t.$refs.elMenuHorizontalScrollRef.$refs.wrap$.scrollLeft+g/4},h=()=>{nt(()=>{let p=document.querySelector(".el-menu.el-menu--horizontal li.is-active");if(!p)return!1;t.$refs.elMenuHorizontalScrollRef.$refs.wrap$.scrollLeft=p.offsetLeft})},d=p=>p.filter(g=>!g.meta.isHide).map(g=>(g=Object.assign({},g),g.children&&(g.children=d(g.children)),g)),w=p=>{const g=p.split("/");let D={};return d(a.value).map((A,x)=>{A.path===`/${g[1]}`&&(A.k=x,D.item=[N({},A)],D.children=[N({},A)],A.children&&(D.children=A.children))}),D},u=p=>{const{path:g,meta:D}=p;if(s.value.layout==="classic")r.defaultActive=`/${g.split("/")[1]}`;else{const A=D.isDynamic?D.isDynamicPath.split("/"):g.split("/");A.length>=4&&D.isHide?r.defaultActive=A.splice(0,3).join("/"):r.defaultActive=g}};return In(()=>{u(i)}),He(()=>{h()}),Ft(p=>{u(p);let{layout:g,isClassicSplitMenu:D}=s.value;g==="classic"&&D&&t.mittBus.emit("setSendClassicChildren",w(p.path))}),N({menuLists:l,onElMenuHorizontalScroll:c},Se(r))}}),Go={class:"el-menu-horizontal-warp"};function Uo(e,t,n,o,a,s){const i=T("SvgIcon"),r=T("SubItem"),l=T("el-sub-menu"),c=T("el-menu-item"),h=T("el-menu"),d=T("el-scrollbar");return y(),L("div",Go,[I(d,{onWheel:Be(e.onElMenuHorizontalScroll,["prevent"]),ref:"elMenuHorizontalScrollRef"},{default:R(()=>[I(h,{router:"","default-active":e.defaultActive,ellipsis:!1,"background-color":"transparent",mode:"horizontal"},{default:R(()=>[(y(!0),L(me,null,Qe(e.menuLists,w=>(y(),L(me,null,[w.children&&w.children.length>0?(y(),Y(l,{index:w.path,key:w.path},{title:R(()=>[I(i,{name:w.meta.icon},null,8,["name"]),V("span",null,H(e.$t(w.meta.title)),1)]),default:R(()=>[I(r,{chil:w.children},null,8,["chil"])]),_:2},1032,["index"])):(y(),Y(c,{index:w.path,key:w.path},Gn({_:2},[!w.meta.isLink||w.meta.isLink&&w.meta.isIframe?{name:"title",fn:R(()=>[I(i,{name:w.meta.icon},null,8,["name"]),Ae(" "+H(e.$t(w.meta.title)),1)])}:{name:"title",fn:R(()=>[V("a",{href:w.meta.isLink,target:"_blank",rel:"opener",class:"w100"},[I(i,{name:w.meta.icon},null,8,["name"]),Ae(" "+H(e.$t(w.meta.title)),1)],8,["href"])])}]),1032,["index"]))],64))),256))]),_:1},8,["default-active"])]),_:1},8,["onWheel"])])}var Qo=ie(Wo,[["render",Uo],["__scopeId","data-v-7d16fc9d"]]);const Ko=ae({name:"layoutBreadcrumbIndex",components:{Breadcrumb:Co,User:jo,Logo:uo,Horizontal:Qo},setup(){const{proxy:e}=ct(),t=Mt(),n=Ie(),{themeConfig:o}=U(n),{routesList:a}=U(t),s=ut(),i=Ce({menuList:[]}),r=oe(()=>{let{isShowLogo:u,layout:p}=o.value;return u&&p==="classic"||u&&p==="transverse"}),l=oe(()=>{let{layout:u,isClassicSplitMenu:p}=o.value;return u==="transverse"||p&&u==="classic"}),c=()=>{let{layout:u,isClassicSplitMenu:p}=o.value;if(u==="classic"&&p){i.menuList=h(d(a.value));const g=w(s.path);e.mittBus.emit("setSendClassicChildren",g)}else i.menuList=d(a.value)},h=u=>(u.map(p=>{p.children&&delete p.children}),u),d=u=>u.filter(p=>!p.meta.isHide).map(p=>(p=Object.assign({},p),p.children&&(p.children=d(p.children)),p)),w=u=>{const p=u.split("/");let g={};return d(a.value).map((D,A)=>{D.path===`/${p[1]}`&&(D.k=A,g.item=[N({},D)],g.children=[N({},D)],D.children&&(g.children=D.children))}),g};return He(()=>{c(),e.mittBus.on("getBreadcrumbIndexSetFilterRoutes",()=>{c()})}),an(()=>{e.mittBus.off("getBreadcrumbIndexSetFilterRoutes",()=>{})}),N({setIsShowLogo:r,isLayoutTransverse:l},Se(i))}}),Zo={class:"layout-navbars-breadcrumb-index"};function Jo(e,t,n,o,a,s){const i=T("Logo"),r=T("Breadcrumb"),l=T("Horizontal"),c=T("User");return y(),L("div",Zo,[e.setIsShowLogo?(y(),Y(i,{key:0})):ee("",!0),I(r),e.isLayoutTransverse?(y(),Y(l,{key:1,menuList:e.menuList},null,8,["menuList"])):ee("",!0),I(c)])}var ea=ie(Ko,[["render",Jo],["__scopeId","data-v-aa5619e8"]]);/**! * Sortable 1.15.0 * @author RubaXa * @author owenm * @license MIT */function gn(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter(function(a){return Object.getOwnPropertyDescriptor(e,a).enumerable})),n.push.apply(n,o)}return n}function ye(e){for(var t=1;t=0)&&(n[a]=e[a]);return n}function oa(e,t){if(e==null)return{};var n=na(e,t),o,a;if(Object.getOwnPropertySymbols){var s=Object.getOwnPropertySymbols(e);for(a=0;a=0)&&(!Object.prototype.propertyIsEnumerable.call(e,o)||(n[o]=e[o]))}return n}var aa="1.15.0";function Te(e){if(typeof window!="undefined"&&window.navigator)return!!navigator.userAgent.match(e)}var Le=Te(/(?:Trident.*rv[ :]?11\.|msie|iemobile|Windows Phone)/i),dt=Te(/Edge/i),vn=Te(/firefox/i),at=Te(/safari/i)&&!Te(/chrome/i)&&!Te(/android/i),Vn=Te(/iP(ad|od|hone)/i),An=Te(/chrome/i)&&Te(/android/i),xn={capture:!1,passive:!1};function k(e,t,n){e.addEventListener(t,n,!Le&&xn)}function $(e,t,n){e.removeEventListener(t,n,!Le&&xn)}function kt(e,t){if(!!t){if(t[0]===">"&&(t=t.substring(1)),e)try{if(e.matches)return e.matches(t);if(e.msMatchesSelector)return e.msMatchesSelector(t);if(e.webkitMatchesSelector)return e.webkitMatchesSelector(t)}catch{return!1}return!1}}function ia(e){return e.host&&e!==document&&e.host.nodeType?e.host:e.parentNode}function be(e,t,n,o){if(e){n=n||document;do{if(t!=null&&(t[0]===">"?e.parentNode===n&&kt(e,t):kt(e,t))||o&&e===n)return e;if(e===n)break}while(e=ia(e))}return null}var wn=/\s+/g;function se(e,t,n){if(e&&t)if(e.classList)e.classList[n?"add":"remove"](t);else{var o=(" "+e.className+" ").replace(wn," ").replace(" "+t+" "," ");e.className=(o+(n?" "+t:"")).replace(wn," ")}}function C(e,t,n){var o=e&&e.style;if(o){if(n===void 0)return document.defaultView&&document.defaultView.getComputedStyle?n=document.defaultView.getComputedStyle(e,""):e.currentStyle&&(n=e.currentStyle),t===void 0?n:n[t];!(t in o)&&t.indexOf("webkit")===-1&&(t="-webkit-"+t),o[t]=n+(typeof n=="string"?"":"px")}}function Ge(e,t){var n="";if(typeof e=="string")n=e;else do{var o=C(e,"transform");o&&o!=="none"&&(n=o+" "+n)}while(!t&&(e=e.parentNode));var a=window.DOMMatrix||window.WebKitCSSMatrix||window.CSSMatrix||window.MSCSSMatrix;return a&&new a(n)}function On(e,t,n){if(e){var o=e.getElementsByTagName(t),a=0,s=o.length;if(n)for(;a=s:i=a<=s,!i)return o;if(o===_e())break;o=Ve(o,!1)}return!1}function Ue(e,t,n,o){for(var a=0,s=0,i=e.children;s2&&arguments[2]!==void 0?arguments[2]:{},a=o.evt,s=oa(o,ha);ft.pluginEvent.bind(S)(t,n,ye({dragEl:v,parentEl:B,ghostEl:E,rootEl:F,nextEl:Pe,lastDownEl:Ct,cloneEl:P,cloneHidden:ke,dragStarted:Je,putSortable:G,activeSortable:S.active,originalEvent:a,oldIndex:We,oldDraggableIndex:st,newIndex:re,newDraggableIndex:$e,hideGhostForTarget:Hn,unhideGhostForTarget:zn,cloneNowHidden:function(){ke=!0},cloneNowShown:function(){ke=!1},dispatchSortableEvent:function(r){J({sortable:n,name:r,originalEvent:a})}},s))};function J(e){fa(ye({putSortable:G,cloneEl:P,targetEl:v,rootEl:F,oldIndex:We,oldDraggableIndex:st,newIndex:re,newDraggableIndex:$e},e))}var v,B,E,F,Pe,Ct,P,ke,We,re,st,$e,vt,G,Ye=!1,Vt=!1,At=[],Me,he,jt,Wt,yn,Cn,Je,Xe,rt,lt=!1,wt=!1,St,Z,Gt=[],en=!1,xt=[],Nt=typeof document!="undefined",bt=Vn,Sn=dt||Le?"cssFloat":"float",ma=Nt&&!An&&!Vn&&"draggable"in document.createElement("div"),Nn=function(){if(!!Nt){if(Le)return!1;var e=document.createElement("x");return e.style.cssText="pointer-events:auto",e.style.pointerEvents==="auto"}}(),Pn=function(t,n){var o=C(t),a=parseInt(o.width)-parseInt(o.paddingLeft)-parseInt(o.paddingRight)-parseInt(o.borderLeftWidth)-parseInt(o.borderRightWidth),s=Ue(t,0,n),i=Ue(t,1,n),r=s&&C(s),l=i&&C(i),c=r&&parseInt(r.marginLeft)+parseInt(r.marginRight)+X(s).width,h=l&&parseInt(l.marginLeft)+parseInt(l.marginRight)+X(i).width;if(o.display==="flex")return o.flexDirection==="column"||o.flexDirection==="column-reverse"?"vertical":"horizontal";if(o.display==="grid")return o.gridTemplateColumns.split(" ").length<=1?"vertical":"horizontal";if(s&&r.float&&r.float!=="none"){var d=r.float==="left"?"left":"right";return i&&(l.clear==="both"||l.clear===d)?"vertical":"horizontal"}return s&&(r.display==="block"||r.display==="flex"||r.display==="table"||r.display==="grid"||c>=a&&o[Sn]==="none"||i&&o[Sn]==="none"&&c+h>a)?"vertical":"horizontal"},pa=function(t,n,o){var a=o?t.left:t.top,s=o?t.right:t.bottom,i=o?t.width:t.height,r=o?n.left:n.top,l=o?n.right:n.bottom,c=o?n.width:n.height;return a===r||s===l||a+i/2===r+c/2},ga=function(t,n){var o;return At.some(function(a){var s=a[le].options.emptyInsertThreshold;if(!(!s||ln(a))){var i=X(a),r=t>=i.left-s&&t<=i.right+s,l=n>=i.top-s&&n<=i.bottom+s;if(r&&l)return o=a}}),o},Bn=function(t){function n(s,i){return function(r,l,c,h){var d=r.options.group.name&&l.options.group.name&&r.options.group.name===l.options.group.name;if(s==null&&(i||d))return!0;if(s==null||s===!1)return!1;if(i&&s==="clone")return s;if(typeof s=="function")return n(s(r,l,c,h),i)(r,l,c,h);var w=(i?r:l).options.group.name;return s===!0||typeof s=="string"&&s===w||s.join&&s.indexOf(w)>-1}}var o={},a=t.group;(!a||yt(a)!="object")&&(a={name:a}),o.name=a.name,o.checkPull=n(a.pull,!0),o.checkPut=n(a.put),o.revertClone=a.revertClone,t.group=o},Hn=function(){!Nn&&E&&C(E,"display","none")},zn=function(){!Nn&&E&&C(E,"display","")};Nt&&!An&&document.addEventListener("click",function(e){if(Vt)return e.preventDefault(),e.stopPropagation&&e.stopPropagation(),e.stopImmediatePropagation&&e.stopImmediatePropagation(),Vt=!1,!1},!0);var Ne=function(t){if(v){t=t.touches?t.touches[0]:t;var n=ga(t.clientX,t.clientY);if(n){var o={};for(var a in t)t.hasOwnProperty(a)&&(o[a]=t[a]);o.target=o.rootEl=n,o.preventDefault=void 0,o.stopPropagation=void 0,n[le]._onDragOver(o)}}},va=function(t){v&&v.parentNode[le]._isOutsideThisEl(t.target)};function S(e,t){if(!(e&&e.nodeType&&e.nodeType===1))throw"Sortable: `el` must be an HTMLElement, not ".concat({}.toString.call(e));this.el=e,this.options=t=De({},t),e[le]=this;var n={group:null,sort:!0,disabled:!1,store:null,handle:null,draggable:/^[uo]l$/i.test(e.nodeName)?">li":">*",swapThreshold:1,invertSwap:!1,invertedSwapThreshold:null,removeCloneOnHide:!0,direction:function(){return Pn(e,this.options)},ghostClass:"sortable-ghost",chosenClass:"sortable-chosen",dragClass:"sortable-drag",ignore:"a, img",filter:null,preventOnFilter:!0,animation:0,easing:null,setData:function(i,r){i.setData("Text",r.textContent)},dropBubble:!1,dragoverBubble:!1,dataIdAttr:"data-id",delay:0,delayOnTouchOnly:!1,touchStartThreshold:(Number.parseInt?Number:window).parseInt(window.devicePixelRatio,10)||1,forceFallback:!1,fallbackClass:"sortable-fallback",fallbackOnBody:!1,fallbackTolerance:0,fallbackOffset:{x:0,y:0},supportPointer:S.supportPointer!==!1&&"PointerEvent"in window&&!at,emptyInsertThreshold:5};ft.initializePlugins(this,e,n);for(var o in n)!(o in t)&&(t[o]=n[o]);Bn(t);for(var a in this)a.charAt(0)==="_"&&typeof this[a]=="function"&&(this[a]=this[a].bind(this));this.nativeDraggable=t.forceFallback?!1:ma,this.nativeDraggable&&(this.options.touchStartThreshold=1),t.supportPointer?k(e,"pointerdown",this._onTapStart):(k(e,"mousedown",this._onTapStart),k(e,"touchstart",this._onTapStart)),this.nativeDraggable&&(k(e,"dragover",this),k(e,"dragenter",this)),At.push(this.el),t.store&&t.store.get&&this.sort(t.store.get(this)||[]),De(this,ua())}S.prototype={constructor:S,_isOutsideThisEl:function(t){!this.el.contains(t)&&t!==this.el&&(Xe=null)},_getDirection:function(t,n){return typeof this.options.direction=="function"?this.options.direction.call(this,t,n,v):this.options.direction},_onTapStart:function(t){if(!!t.cancelable){var n=this,o=this.el,a=this.options,s=a.preventOnFilter,i=t.type,r=t.touches&&t.touches[0]||t.pointerType&&t.pointerType==="touch"&&t,l=(r||t).target,c=t.target.shadowRoot&&(t.path&&t.path[0]||t.composedPath&&t.composedPath()[0])||l,h=a.filter;if(Ta(o),!v&&!(/mousedown|pointerdown/.test(i)&&t.button!==0||a.disabled)&&!c.isContentEditable&&!(!this.nativeDraggable&&at&&l&&l.tagName.toUpperCase()==="SELECT")&&(l=be(l,a.draggable,o,!1),!(l&&l.animated)&&Ct!==l)){if(We=fe(l),st=fe(l,a.draggable),typeof h=="function"){if(h.call(this,t,l,this)){J({sortable:n,rootEl:c,name:"filter",targetEl:l,toEl:o,fromEl:o}),ne("filter",n,{evt:t}),s&&t.cancelable&&t.preventDefault();return}}else if(h&&(h=h.split(",").some(function(d){if(d=be(c,d.trim(),o,!1),d)return J({sortable:n,rootEl:d,name:"filter",targetEl:l,fromEl:o,toEl:o}),ne("filter",n,{evt:t}),!0}),h)){s&&t.cancelable&&t.preventDefault();return}a.handle&&!be(c,a.handle,o,!1)||this._prepareDragStart(t,r,l)}}},_prepareDragStart:function(t,n,o){var a=this,s=a.el,i=a.options,r=s.ownerDocument,l;if(o&&!v&&o.parentNode===s){var c=X(o);if(F=s,v=o,B=v.parentNode,Pe=v.nextSibling,Ct=o,vt=i.group,S.dragged=v,Me={target:v,clientX:(n||t).clientX,clientY:(n||t).clientY},yn=Me.clientX-c.left,Cn=Me.clientY-c.top,this._lastX=(n||t).clientX,this._lastY=(n||t).clientY,v.style["will-change"]="all",l=function(){if(ne("delayEnded",a,{evt:t}),S.eventCanceled){a._onDrop();return}a._disableDelayedDragEvents(),!vn&&a.nativeDraggable&&(v.draggable=!0),a._triggerDragStart(t,n),J({sortable:a,name:"choose",originalEvent:t}),se(v,i.chosenClass,!0)},i.ignore.split(",").forEach(function(h){On(v,h.trim(),Ut)}),k(r,"dragover",Ne),k(r,"mousemove",Ne),k(r,"touchmove",Ne),k(r,"mouseup",a._onDrop),k(r,"touchend",a._onDrop),k(r,"touchcancel",a._onDrop),vn&&this.nativeDraggable&&(this.options.touchStartThreshold=4,v.draggable=!0),ne("delayStart",this,{evt:t}),i.delay&&(!i.delayOnTouchOnly||n)&&(!this.nativeDraggable||!(dt||Le))){if(S.eventCanceled){this._onDrop();return}k(r,"mouseup",a._disableDelayedDrag),k(r,"touchend",a._disableDelayedDrag),k(r,"touchcancel",a._disableDelayedDrag),k(r,"mousemove",a._delayedDragTouchMoveHandler),k(r,"touchmove",a._delayedDragTouchMoveHandler),i.supportPointer&&k(r,"pointermove",a._delayedDragTouchMoveHandler),a._dragStartTimer=setTimeout(l,i.delay)}else l()}},_delayedDragTouchMoveHandler:function(t){var n=t.touches?t.touches[0]:t;Math.max(Math.abs(n.clientX-this._lastX),Math.abs(n.clientY-this._lastY))>=Math.floor(this.options.touchStartThreshold/(this.nativeDraggable&&window.devicePixelRatio||1))&&this._disableDelayedDrag()},_disableDelayedDrag:function(){v&&Ut(v),clearTimeout(this._dragStartTimer),this._disableDelayedDragEvents()},_disableDelayedDragEvents:function(){var t=this.el.ownerDocument;$(t,"mouseup",this._disableDelayedDrag),$(t,"touchend",this._disableDelayedDrag),$(t,"touchcancel",this._disableDelayedDrag),$(t,"mousemove",this._delayedDragTouchMoveHandler),$(t,"touchmove",this._delayedDragTouchMoveHandler),$(t,"pointermove",this._delayedDragTouchMoveHandler)},_triggerDragStart:function(t,n){n=n||t.pointerType=="touch"&&t,!this.nativeDraggable||n?this.options.supportPointer?k(document,"pointermove",this._onTouchMove):n?k(document,"touchmove",this._onTouchMove):k(document,"mousemove",this._onTouchMove):(k(v,"dragend",this),k(F,"dragstart",this._onDragStart));try{document.selection?Et(function(){document.selection.empty()}):window.getSelection().removeAllRanges()}catch{}},_dragStarted:function(t,n){if(Ye=!1,F&&v){ne("dragStarted",this,{evt:n}),this.nativeDraggable&&k(document,"dragover",va);var o=this.options;!t&&se(v,o.dragClass,!1),se(v,o.ghostClass,!0),S.active=this,t&&this._appendGhost(),J({sortable:this,name:"start",originalEvent:n})}else this._nulling()},_emulateDragOver:function(){if(he){this._lastX=he.clientX,this._lastY=he.clientY,Hn();for(var t=document.elementFromPoint(he.clientX,he.clientY),n=t;t&&t.shadowRoot&&(t=t.shadowRoot.elementFromPoint(he.clientX,he.clientY),t!==n);)n=t;if(v.parentNode[le]._isOutsideThisEl(t),n)do{if(n[le]){var o=void 0;if(o=n[le]._onDragOver({clientX:he.clientX,clientY:he.clientY,target:t,rootEl:n}),o&&!this.options.dragoverBubble)break}t=n}while(n=n.parentNode);zn()}},_onTouchMove:function(t){if(Me){var n=this.options,o=n.fallbackTolerance,a=n.fallbackOffset,s=t.touches?t.touches[0]:t,i=E&&Ge(E,!0),r=E&&i&&i.a,l=E&&i&&i.d,c=bt&&Z&&_n(Z),h=(s.clientX-Me.clientX+a.x)/(r||1)+(c?c[0]-Gt[0]:0)/(r||1),d=(s.clientY-Me.clientY+a.y)/(l||1)+(c?c[1]-Gt[1]:0)/(l||1);if(!S.active&&!Ye){if(o&&Math.max(Math.abs(s.clientX-this._lastX),Math.abs(s.clientY-this._lastY))=0&&(J({rootEl:B,name:"add",toEl:B,fromEl:F,originalEvent:t}),J({sortable:this,name:"remove",toEl:B,originalEvent:t}),J({rootEl:B,name:"sort",toEl:B,fromEl:F,originalEvent:t}),J({sortable:this,name:"sort",toEl:B,originalEvent:t})),G&&G.save()):re!==We&&re>=0&&(J({sortable:this,name:"update",toEl:B,originalEvent:t}),J({sortable:this,name:"sort",toEl:B,originalEvent:t})),S.active&&((re==null||re===-1)&&(re=We,$e=st),J({sortable:this,name:"end",toEl:B,originalEvent:t}),this.save()))),this._nulling()},_nulling:function(){ne("nulling",this),F=v=B=E=Pe=P=Ct=ke=Me=he=Je=re=$e=We=st=Xe=rt=G=vt=S.dragged=S.ghost=S.clone=S.active=null,xt.forEach(function(t){t.checked=!0}),xt.length=jt=Wt=0},handleEvent:function(t){switch(t.type){case"drop":case"dragend":this._onDrop(t);break;case"dragenter":case"dragover":v&&(this._onDragOver(t),wa(t));break;case"selectstart":t.preventDefault();break}},toArray:function(){for(var t=[],n,o=this.el.children,a=0,s=o.length,i=this.options;ao.right+a||e.clientX<=o.right&&e.clientY>o.bottom&&e.clientX>=o.left:e.clientX>o.right&&e.clientY>o.top||e.clientX<=o.right&&e.clientY>o.bottom+a}function Ca(e,t,n,o,a,s,i,r){var l=o?e.clientY:e.clientX,c=o?n.height:n.width,h=o?n.top:n.left,d=o?n.bottom:n.right,w=!1;if(!i){if(r&&Sth+c*s/2:ld-St)return-rt}else if(l>h+c*(1-a)/2&&ld-c*s/2)?l>h+c/2?1:-1:0}function Sa(e){return fe(v)({x:0,y:0})}},setup(e,{emit:t}){const n=Ce({isShow:!1,dropdownList:[{contextMenuClickId:0,txt:"message.tagsView.refresh",affix:!1,icon:"ele-RefreshRight"},{contextMenuClickId:1,txt:"message.tagsView.close",affix:!1,icon:"ele-Close"},{contextMenuClickId:2,txt:"message.tagsView.closeOther",affix:!1,icon:"ele-CircleClose"},{contextMenuClickId:3,txt:"message.tagsView.closeAll",affix:!1,icon:"ele-FolderDelete"},{contextMenuClickId:4,txt:"message.tagsView.fullscreen",affix:!1,icon:"iconfont icon-fullscreen"}],item:{},arrowLeft:10}),o=oe(()=>e.dropdown.x+117>document.documentElement.clientWidth?{x:document.documentElement.clientWidth-117-5,y:e.dropdown.y}:e.dropdown),a=r=>{t("currentContextmenuClick",Object.assign({},{contextMenuClickId:r},n.item))},s=r=>{n.item=r,r.meta.isAffix?n.dropdownList[1].affix=!0:n.dropdownList[1].affix=!1,i(),setTimeout(()=>{n.isShow=!0},10)},i=()=>{n.isShow=!1};return He(()=>{document.body.addEventListener("click",i)}),an(()=>{document.body.removeEventListener("click",i)}),It(()=>e.dropdown,({x:r})=>{r+117>document.documentElement.clientWidth?n.arrowLeft=117-(document.documentElement.clientWidth-r):n.arrowLeft=10},{deep:!0}),N({dropdowns:o,openContextmenu:s,closeContextmenu:i,onCurrentContextmenuClick:a},Se(n))}}),La={class:"el-dropdown-menu"},$a=["onClick"];function ka(e,t,n,o,a,s){const i=T("SvgIcon");return y(),Y(Un,{name:"el-zoom-in-center"},{default:R(()=>[sn((y(),L("div",{"aria-hidden":"true",class:"el-dropdown__popper el-popper is-light is-pure custom-contextmenu",role:"tooltip","data-popper-placement":"bottom",style:Dt(`top: ${e.dropdowns.y+5}px;left: ${e.dropdowns.x}px;`),key:Math.random()},[V("ul",La,[(y(!0),L(me,null,Qe(e.dropdownList,(r,l)=>(y(),L(me,null,[r.affix?ee("",!0):(y(),L("li",{class:"el-dropdown-menu__item","aria-disabled":"false",tabindex:"-1",key:l,onClick:c=>e.onCurrentContextmenuClick(r.contextMenuClickId)},[I(i,{name:r.icon},null,8,["name"]),V("span",null,H(e.$t(r.txt)),1)],8,$a))],64))),256))]),V("div",{class:"el-popper__arrow",style:Dt({left:`${e.arrowLeft}px`})},null,4)],4)),[[rn,e.isShow]])]),_:1})}var Va=ie(Ia,[["render",ka],["__scopeId","data-v-225a0b9c"]]);const Aa=ae({name:"layoutTagsView",components:{Contextmenu:Va},setup(){const{proxy:e}=ct(),t=je([]),n=je(),o=je(),a=je(),s=$t(),i=Ie(),r=$t(),{themeConfig:l}=U(i),{tagsViewRoutes:c}=U(r),h=to(),d=ut(),w=Rt(),u=Ce({routeActive:"",routePath:d.path,dropdown:{x:"",y:""},sortable:"",tagsRefsIndex:0,tagsViewList:[],tagsViewRoutesList:[]}),p=oe(()=>l.value.tagsStyle),g=oe(()=>l.value),D=oe(()=>m=>Lt.setTagsViewNameI18n(m)),A=m=>g.value.isShareTagsView?m.path===u.routePath:m.query&&Object.keys(m.query).length||m.params&&Object.keys(m.params).length?m.url?m.url===u.routeActive:m.path===u.routeActive:m.path===u.routePath,x=m=>{we.set("tagsViewList",m)},Q=async()=>{u.routeActive=await te(d),u.routePath=await d.meta.isDynamic?d.meta.isDynamicPath:d.path,u.tagsViewList=[],u.tagsViewRoutesList=c.value,j()},j=async()=>{we.get("tagsViewList")&&g.value.isCacheTagsView?u.tagsViewList=await we.get("tagsViewList"):(await u.tagsViewRoutesList.map(m=>{m.meta.isAffix&&!m.meta.isHide&&(m.url=te(m),u.tagsViewList.push(N({},m)),h.addCachedView(m))}),await W(d.path,d)),Ke(g.value.isShareTagsView?u.routePath:u.routeActive)},O=async(m,f)=>{let _=f.meta.isDynamic?f.meta.isDynamicPath:m;if(u.tagsViewList.filter(M=>M.path===_&&qt(f.meta.isDynamic?M.params?M.params:null:M.query?M.query:null,f.meta.isDynamic?f!=null&&f.params?f==null?void 0:f.params:null:f!=null&&f.query?f==null?void 0:f.query:null)).length<=0){let M=u.tagsViewRoutesList.find(de=>de.path===_);if(!M||M.meta.isAffix||M.meta.isLink&&!M.meta.isIframe)return!1;f.meta.isDynamic?M.params=f.params:M.query=f.query,M.url=te(M),u.tagsViewList.push(N({},M)),await h.addCachedView(M),x(u.tagsViewList)}},z=(m,f)=>{let _=f.meta.isDynamic?f.meta.isDynamicPath:m;u.tagsViewList.forEach(b=>{b.path===_&&!qt(f.meta.isDynamic?b.params?b.params:null:b.query?b.query:null,f.meta.isDynamic?f!=null&&f.params?f==null?void 0:f.params:null:f!=null&&f.query?f==null?void 0:f.query:null)&&(f.meta.isDynamic?b.params=f.params:b.query=f.query,b.url=te(b),x(u.tagsViewList))})},W=(m,f)=>{nt(async()=>{let _="";if(f&&f.meta.isDynamic){if(g.value.isShareTagsView?await z(m,f):await O(m,f),u.tagsViewList.some(b=>b.path===f.meta.isDynamicPath))return!1;_=u.tagsViewRoutesList.find(b=>b.path===f.meta.isDynamicPath)}else{if(g.value.isShareTagsView?await z(m,f):await O(m,f),u.tagsViewList.some(b=>b.path===m))return!1;_=u.tagsViewRoutesList.find(b=>b.path===m)}if(!_||_.meta.isLink&&!_.meta.isIframe)return!1;f&&f.meta.isDynamic?_.params=f!=null&&f.params?f==null?void 0:f.params:d.params:_.query=f!=null&&f.query?f==null?void 0:f.query:d.query,_.url=te(_),await h.addCachedView(_),await u.tagsViewList.push(N({},_)),await x(u.tagsViewList)})},ue=async m=>{const f=u.tagsViewList.find(_=>g.value.isShareTagsView?_.path===m:_.url===m);f!=null&&(await h.delCachedView(f),e.mittBus.emit("onTagsViewRefreshRouterView",m),f.meta.isKeepAlive&&h.addCachedView(f))},K=m=>{u.tagsViewList.map((f,_,b)=>{f.meta.isAffix||(g.value.isShareTagsView?f.path===m:f.url===m)&&(h.delCachedView(f),u.tagsViewList.splice(_,1),setTimeout(()=>{(u.tagsViewList.length===_&&g.value.isShareTagsView?u.routePath===m:u.routeActive===m)?b[b.length-1].meta.isDynamic?_!==b.length?w.push({name:b[_].name,params:b[_].params}):w.push({name:b[b.length-1].name,params:b[b.length-1].params}):_!==b.length?w.push({path:b[_].path,query:b[_].query}):w.push({path:b[b.length-1].path,query:b[b.length-1].query}):(u.tagsViewList.length!==_&&g.value.isShareTagsView?u.routePath===m:u.routeActive===m)&&(b[_].meta.isDynamic?w.push({name:b[_].name,params:b[_].params}):w.push({path:b[_].path,query:b[_].query}))},0))}),x(u.tagsViewList)},xe=m=>{we.get("tagsViewList")&&(u.tagsViewList=[],we.get("tagsViewList").map(f=>{f.meta.isAffix&&!f.meta.isHide&&(f.url=te(f),h.delOthersCachedViews(f),u.tagsViewList.push(N({},f)))}),W(m,d),x(u.tagsViewList))},pe=()=>{we.get("tagsViewList")&&(h.delAllCachedViews(),u.tagsViewList=[],we.get("tagsViewList").map(m=>{m.meta.isAffix&&!m.meta.isHide&&(m.url=te(m),u.tagsViewList.push(N({},m)),w.push({path:u.tagsViewList[u.tagsViewList.length-1].path}))}),x(u.tagsViewList))},Oe=async m=>{const f=u.tagsViewList.find(_=>g.value.isShareTagsView?_.path===m:_.url===m);f.meta.isDynamic?await w.push({name:f.name,params:f.params}):await w.push({name:f.name,query:f.query}),s.setCurrenFullscreen(!0)},ce=(m,f)=>(we.get("tagsViewList")?we.get("tagsViewList"):u.tagsViewList).find(b=>{if(b.path===m&&qt(b.meta.isDynamic?b.params?b.params:null:b.query?b.query:null,f&&Object.keys(f||{}).length>0?f:null))return b;if(b.path===m&&Object.keys(f||{}).length<=0)return b}),ge=async m=>{const f=m.meta.isDynamic?m.params:m.query;if(!ce(m.path,f))return Jt({type:"warning",message:"\u8BF7\u6B63\u786E\u8F93\u5165\u8DEF\u5F84\u53CA\u5B8C\u6574\u53C2\u6570\uFF08query\u3001params\uFF09"});const{path:_,name:b,params:M,query:de,meta:ht,url:ze}=ce(m.path,f);switch(m.contextMenuClickId){case 0:ht.isDynamic?await w.push({name:b,params:M}):await w.push({path:_,query:de}),ue(d.fullPath);break;case 1:K(g.value.isShareTagsView?_:ze);break;case 2:ht.isDynamic?await w.push({name:b,params:M}):await w.push({path:_,query:de}),xe(_);break;case 3:pe();break;case 4:Oe(g.value.isShareTagsView?_:ze);break}},Re=(m,f)=>{const{clientX:_,clientY:b}=f;u.dropdown.x=_,u.dropdown.y=b,o.value.openContextmenu(m)},ve=(m,f)=>{u.tagsRefsIndex=f,w.push(m)},te=m=>{let f=m.query&&Object.keys(m.query).length>0?m.query:m.params;if(!f||Object.keys(f).length<=0)return m.path;let _="";for(let b in f)_+=f[b];return`${m.meta.isDynamic?m.meta.isDynamicPath:m.path}-${_}`},Fe=()=>{e.$refs.scrollbarRef.update()},Pt=m=>{e.$refs.scrollbarRef.$refs.wrap$.scrollLeft+=m.wheelDelta/4},dn=()=>{nt(()=>{if(t.value.length<=0)return!1;let m=t.value[u.tagsRefsIndex],f=u.tagsRefsIndex,_=t.value.length,b=t.value[0],M=t.value[t.value.length-1],de=e.$refs.scrollbarRef.$refs.wrap$,ht=de.scrollWidth,ze=de.offsetWidth,fn=de.scrollLeft,Ht=t.value[u.tagsRefsIndex-1],hn=t.value[u.tagsRefsIndex+1],mt="",pt="";m===b?de.scrollLeft=0:m===M?de.scrollLeft=ht-ze:(f===0?mt=b.offsetLeft-5:mt=(Ht==null?void 0:Ht.offsetLeft)-5,f===_?pt=M.offsetLeft+M.offsetWidth+5:pt=hn.offsetLeft+hn.offsetWidth+5,pt>fn+ze?de.scrollLeft=pt-ze:mt{nt(async()=>{let f=await u.tagsViewList;u.tagsRefsIndex=f.findIndex(_=>g.value.isShareTagsView?_.path===m:_.url===m),dn()})},Ze=async()=>{const m=document.querySelector(".layout-navbars-tagsview-ul");if(!m)return!1;u.sortable.el&&u.sortable.destroy(),u.sortable=S.create(m,{animation:300,dataIdAttr:"data-url",disabled:!g.value.isSortableTagsView,onEnd:()=>{const f=[];u.sortable.toArray().map(_=>{u.tagsViewList.map(b=>{b.url===_&&f.push(N({},b))})}),x(f)}})},Bt=async()=>{await Ze(),Lt.isMobile()&&u.sortable.el&&u.sortable.destroy()};return In(()=>{Bt(),window.addEventListener("resize",Bt),e.mittBus.on("onCurrentContextmenuClick",m=>{ge(m)}),e.mittBus.on("openOrCloseSortable",()=>{Ze()}),e.mittBus.on("openShareTagsView",()=>{g.value.isShareTagsView&&(w.push("/project"),u.tagsViewList=[],u.tagsViewRoutesList.map(m=>{m.meta.isAffix&&!m.meta.isHide&&(m.url=te(m),u.tagsViewList.push(N({},m)))}))})}),an(()=>{e.mittBus.off("onCurrentContextmenuClick",()=>{}),e.mittBus.off("openOrCloseSortable",()=>{}),e.mittBus.off("openShareTagsView",()=>{}),window.removeEventListener("resize",Bt)}),Qn(()=>{t.value=[]}),He(()=>{Q(),Ze()}),Ft(async m=>{u.routeActive=te(m),u.routePath=m.meta.isDynamic?m.meta.isDynamicPath:m.path,await W(m.path,m),Ke(g.value.isShareTagsView?u.routePath:u.routeActive)}),It(no.state,m=>{if(m.tagsViewRoutes.tagsViewRoutes.length===u.tagsViewRoutesList.length)return!1;Q()},{deep:!0}),N({isActive:A,onContextmenu:Re,onTagsClick:ve,tagsRefs:t,contextmenuRef:o,scrollbarRef:n,tagsUlRef:a,onHandleScroll:Pt,getThemeConfig:g,setTagsStyle:p,setTagsViewNameI18n:D,refreshCurrentTagsView:ue,closeCurrentTagsView:K,onCurrentContextmenuClick:ge},Se(u))}}),xa=["data-url","onContextmenu","onClick"],Oa={key:0,class:"iconfont icon-webicon318 layout-navbars-tagsview-ul-li-iconfont"};function Ra(e,t,n,o,a,s){const i=T("SvgIcon"),r=T("el-scrollbar"),l=T("Contextmenu");return y(),L("div",{class:ot(["layout-navbars-tagsview",{"layout-navbars-tagsview-shadow":e.getThemeConfig.layout==="classic"}])},[I(r,{ref:"scrollbarRef",onWheel:Be(e.onHandleScroll,["prevent"])},{default:R(()=>[V("ul",{class:ot(["layout-navbars-tagsview-ul",e.setTagsStyle]),ref:"tagsUlRef"},[(y(!0),L(me,null,Qe(e.tagsViewList,(c,h)=>(y(),L("li",{key:h,class:ot(["layout-navbars-tagsview-ul-li",{"is-active":e.isActive(c)}]),"data-url":c.url,onContextmenu:Be(d=>e.onContextmenu(c,d),["prevent"]),onClick:d=>e.onTagsClick(c,h),ref_for:!0,ref:d=>{d&&(e.tagsRefs[h]=d)}},[e.isActive(c)?(y(),L("i",Oa)):ee("",!0),!e.isActive(c)&&e.getThemeConfig.isTagsviewIcon?(y(),Y(i,{key:1,name:c.meta.icon,class:"pr5"},null,8,["name"])):ee("",!0),V("span",null,H(e.setTagsViewNameI18n(c)),1),e.isActive(c)?(y(),L(me,{key:2},[I(i,{name:"ele-RefreshRight",class:"ml5 layout-navbars-tagsview-ul-li-refresh",onClick:t[0]||(t[0]=Be(d=>e.refreshCurrentTagsView(e.$route.fullPath),["stop"]))}),c.meta.isAffix?ee("",!0):(y(),Y(i,{key:0,name:"ele-Close",class:"layout-navbars-tagsview-ul-li-icon layout-icon-active",onClick:Be(d=>e.closeCurrentTagsView(e.getThemeConfig.isShareTagsView?c.path:c.url),["stop"])},null,8,["onClick"]))],64)):ee("",!0),c.meta.isAffix?ee("",!0):(y(),Y(i,{key:3,name:"ele-Close",class:"layout-navbars-tagsview-ul-li-icon layout-icon-three",onClick:Be(d=>e.closeCurrentTagsView(e.getThemeConfig.isShareTagsView?c.path:c.url),["stop"])},null,8,["onClick"]))],42,xa))),128))],2)]),_:1},8,["onWheel"]),I(l,{dropdown:e.dropdown,ref:"contextmenuRef",onCurrentContextmenuClick:e.onCurrentContextmenuClick},null,8,["dropdown","onCurrentContextmenuClick"])],2)}var Fa=ie(Aa,[["render",Ra],["__scopeId","data-v-13efbe9c"]]);const Ma=ae({name:"layoutNavBars",components:{BreadcrumbIndex:ea,TagsView:Fa},setup(){const e=Ie(),{themeConfig:t}=U(e);return{setShowTagsView:oe(()=>{let{layout:o,isTagsview:a}=t.value;return o!=="classic"&&a})}}}),Na={class:"layout-navbars-container"};function Pa(e,t,n,o,a,s){const i=T("BreadcrumbIndex"),r=T("TagsView");return y(),L("div",Na,[I(i),e.setShowTagsView?(y(),Y(r,{key:0})):ee("",!0)])}var Ba=ie(Ma,[["render",Pa],["__scopeId","data-v-2b1a3776"]]);const Ha=ae({name:"layoutHeader",components:{NavBarsIndex:Ba},setup(){const e=$t(),t=Ie(),{themeConfig:n}=U(t),{isTagsViewCurrenFull:o}=U(e);return{setHeaderHeight:oe(()=>{let{isTagsview:s,layout:i}=n.value;return s&&i!=="classic"?"84px":"80px"}),isTagsViewCurrenFull:o}}});function za(e,t,n,o,a,s){const i=T("NavBarsIndex"),r=T("el-header");return sn((y(),Y(r,{class:"layout-header",height:e.setHeaderHeight},{default:R(()=>[I(i)]),_:1},8,["height"])),[[rn,!e.isTagsViewCurrenFull]])}var ai=ie(Ha,[["render",za]]);const qa=ae({name:"layoutFooter",setup(){const e=Ce({isDelayFooter:!0});return Ft(()=>{setTimeout(()=>{e.isDelayFooter=!1,setTimeout(()=>{e.isDelayFooter=!0},800)},0)}),N({},Se(e))}}),Xa=e=>(Tn("data-v-7f3657f7"),e=e(),Dn(),e),Ya={class:"layout-footer mt15"},ja=Xa(()=>V("div",{class:"layout-footer-warp"},[V("div",null,"vue-next-admin\uFF0CMade by lyt with \u2764\uFE0F"),V("div",{class:"mt5"},"\u6DF1\u5733\u5E02 xxx \u516C\u53F8\u7248\u6743\u6240\u6709")],-1)),Wa=[ja];function Ga(e,t,n,o,a,s){return sn((y(),L("div",Ya,Wa,512)),[[rn,e.isDelayFooter]])}var Ua=ie(qa,[["render",Ga],["__scopeId","data-v-7f3657f7"]]);const Qa=ae({name:"layoutMain",components:{LayoutParentView:ao,Footer:Ua},setup(){const{proxy:e}=ct(),t=Ie(),{themeConfig:n}=U(t),o=ut(),a=Ce({headerHeight:"",currentRouteMeta:{}}),s=oe(()=>{const{layout:l}=n.value;return l==="classic"||l==="transverse"}),i=()=>{const l=a.currentRouteMeta.isLink&&a.currentRouteMeta.isIframe;let{isTagsview:c}=n.value;return c?a.headerHeight=l?"86px":"115px":a.headerHeight="80px"},r=()=>{a.currentRouteMeta=o.meta};return He(async()=>{await r(),i(),$n.done()}),It(()=>o.path,()=>{a.currentRouteMeta=o.meta;const l=a.currentRouteMeta.isLink&&a.currentRouteMeta.isIframe;a.headerHeight=l?"86px":"115px",e.$refs.layoutScrollbarRef.update()}),It(n,l=>{var h,d;a.currentRouteMeta=o.meta;const c=a.currentRouteMeta.isLink&&a.currentRouteMeta.isIframe;a.headerHeight=l.isTagsview?c?"86px":"115px":"51px",(d=(h=e.$refs)==null?void 0:h.layoutScrollbarRef)==null||d.update()},{deep:!0}),N({themeConfig:n,isClassicOrTransverse:s},Se(a))}});function Ka(e,t,n,o,a,s){const i=T("LayoutParentView"),r=T("Footer"),l=T("el-scrollbar"),c=T("el-main");return y(),Y(c,{class:"layout-main"},{default:R(()=>[I(l,{ref:"layoutScrollbarRef",class:ot({"layout-scrollbar":!e.isClassicOrTransverse&&!e.currentRouteMeta.isLink&&!e.currentRouteMeta.isIframe||!e.isClassicOrTransverse&&e.currentRouteMeta.isLink&&!e.currentRouteMeta.isIframe})},{default:R(()=>[I(i,{style:Dt({padding:!e.isClassicOrTransverse||e.currentRouteMeta.isLink&&e.currentRouteMeta.isIframe?"0":"15px",transition:"padding 0.3s ease-in-out"})},null,8,["style"]),e.themeConfig.isFooter?(y(),Y(r,{key:0})):ee("",!0)]),_:1},8,["class"])]),_:1})}var ii=ie(Qa,[["render",Ka]]);export{ai as H,uo as L,ii as M,mo as S,Fa as T};