2 lines
39 KiB
JavaScript
2 lines
39 KiB
JavaScript
|
|
import{aB as Ge,_ as Je,r as F,b as Pe,E as Fe,d as ge,z as De,H as R,l as u,m as C,U as O,u as h,ah as y,p as S,V as p,P as m,X as Ne,O as x,aC as je,R as re,S as A,aD as _e,aE as pe,F as K,a8 as ee,a3 as ae,I as ce,e as E,aa as Ye,T as Y,J as H,aF as G,aG as ze,w as ie,c as Be,K as We,aH as be,aI as ye,s as Ze,a9 as se,n as Qe,aJ as et,Q as fe,W as ve}from"./vue-2207505e.js";import{g as tt,s as Me,u as me,_ as P,a as Oe,b as J,r as nt,c as we,d as ot}from"./index-d2d32afc.js";import{u as st}from"./useWatermark-7bca1e7b.js";import{h as at,j as lt,g as rt,k as ct,b as ue,l as it,n as ut,o as He,u as dt,r as _t,p as pt,q as ft,s as vt,t as mt}from"./element-4018b73c.js";import{_ as ht}from"./index.vue_vue_type_script_setup_true_lang-c7e913c1.js";import"./vxe-791d9ab6.js";var X=(n=>(n[n.Mobile=0]="Mobile",n[n.Desktop=1]="Desktop",n))(X||{});const gt="opened",Ue="closed";function bt(n){n?Me(gt):Me(Ue)}const te=Ge("app",()=>{const n=Je({opened:tt()!==Ue,withoutAnimation:!1}),e=F(X.Desktop);return Pe(()=>n.opened,o=>bt(o)),{device:e,sidebar:n,toggleSidebar:o=>{n.opened=!n.opened,n.withoutAnimation=o},closeSidebar:o=>{n.opened=!1,n.withoutAnimation=o},toggleDevice:o=>{e.value=o}}}),yt=992,wt=()=>{const n=te(),{listenerRouteChange:e}=me(),t=()=>document.body.getBoundingClientRect().width-1<yt,l=()=>{if(!document.hidden){const a=t();n.toggleDevice(a?X.Mobile:X.Desktop),a&&n.closeSidebar(!0)}};e(()=>{n.device===X.Mobile&&n.sidebar.opened&&n.closeSidebar(!1)}),Fe(()=>{window.addEventListener("resize",l)}),ge(()=>{t()&&(n.toggleDevice(X.Mobile),n.closeSidebar(!0))}),De(()=>{window.removeEventListener("resize",l)})},xt={class:"layout-footer"},St=R({__name:"index",setup(n){const e="V3 Admin Vite";return(t,l)=>(u(),C("footer",xt,"MIT © 2021-PRESENT "+O(h(e)),1))}});const kt=P(St,[["__scopeId","data-v-034a5242"]]),Ct={class:"app-main"},Tt={class:"app-scrollbar"},$t=R({__name:"AppMain",setup(n){const e=Oe(),t=J();return(l,a)=>{const o=y("router-view"),s=y("el-backtop");return u(),C("section",Ct,[S("div",Tt,[p(o,null,{default:m(({Component:r,route:i})=>[p(Ne,{name:"el-fade-in",mode:"out-in"},{default:m(()=>[(u(),x(je,{include:h(e).cachedViews},[(u(),x(re(r),{key:i.path,class:"app-container-grow"}))],1032,["include"]))]),_:2},1024)]),_:1}),h(t).showFooter?(u(),x(kt,{key:0})):A("",!0)]),p(s),p(s,{target:".app-scrollbar"})])}}});const xe=P($t,[["__scopeId","data-v-d87ee2cd"]]),Et=R({__name:"index",props:{isActive:{type:Boolean,default:!1}},emits:["toggleClick"],setup(n,{emit:e}){const t=n,l=()=>{e("toggleClick")};return(a,o)=>{const s=y("el-icon");return u(),C("div",{onClick:l},[p(s,{size:20,class:"icon"},{default:m(()=>[t.isActive?(u(),x(h(at),{key:0})):(u(),x(h(lt),{key:1}))]),_:1})])}}});const Mt=P(Et,[["__scopeId","data-v-252d9bf8"]]);function Vt(n){for(var e=[],t=0;t<n.length;){var l=n[t];if(l==="*"||l==="+"||l==="?"){e.push({type:"MODIFIER",index:t,value:n[t++]});continue}if(l==="\\"){e.push({type:"ESCAPED_CHAR",index:t++,value:n[t++]});continue}if(l==="{"){e.push({type:"OPEN",index:t,value:n[t++]});continue}if(l==="}"){e.push({type:"CLOSE",index:t,value:n[t++]});continue}if(l===":"){for(var a="",o=t+1;o<n.length;){var s=n.charCodeAt(o);if(s>=48&&s<=57||s>=65&&s<=90||s>=97&&s<=122||s===95){a+=n[o++];continue}break}if(!a)throw new TypeError("Missing parameter name at ".concat(t));e.push({type:"NAME",index:t,value:a}),t=o;continue}if(l==="("){var r=1,i="",o=t+1;if(n[o]==="?")throw new TypeError('Pattern cannot start with "?" at '.concat(o));for(;o<n.length;){if(n[o]==="\\"){i+=n[o++]+n[o++];continue}if(n[o]===")"){if(r--,r===0){o++;break}}else if(n[o]==="("&&(r++,n[o+1]!=="?"))throw new TypeError("Capturing groups are not allowed at ".concat(o));i+=n[o++]}if(r)throw new TypeError("Unbalanced pattern at ".concat(t));if(!i)throw new TypeError("Missing pattern at ".concat(t));e.push({type:"PATTERN",index:t,value:i}),t=o;continue}e.push({type:"CHAR",index:t,value:n[t++]})}return e.push({type:"END",index:t,value:""}),e}function At(n,e){e===void 0&&(e={});for(var t=Vt(n),l=e.prefixes,a=l===void 0?"./":l,o="[^".concat(Lt(e.delimiter||"/#?"),
|