import{s as e,u as t,au as n,n as r,a as o,d as a,z as s,j as c,af as i,g as l,e as u,f}from"./@vue-7f120f92.js"; /*! * vue-router v4.2.5 * (c) 2023 eduardo san martin morote * @license mit */const p="undefined"!=typeof window;const h=object.assign;function d(e,t){const n={};for(const r in t){const o=t[r];n[r]=g(o)?o.map(e):e(o)}return n}const m=()=>{},g=array.isarray,v=/\/$/,y=e=>e.replace(v,"");function b(e,t,n="/"){let r,o={},a="",s="";const c=t.indexof("#");let i=t.indexof("?");return c=0&&(i=-1),i>-1&&(r=t.slice(0,i),a=t.slice(i+1,c>-1?c:t.length),o=e(a)),c>-1&&(r=r||t.slice(0,c),s=t.slice(c,t.length)),r=function(e,t){if(e.startswith("/"))return e;if(!e)return t;const n=t.split("/"),r=e.split("/"),o=r[r.length-1];".."!==o&&"."!==o||r.push("");let a,s,c=n.length-1;for(a=0;a1&&c--}return n.slice(0,c).join("/")+"/"+r.slice(a-(a===r.length?1:0)).join("/")}(null!=r?r:t,n),{fullpath:r+(a&&"?")+a+s,path:r,query:o,hash:s}}function w(e,t){return t&&e.tolowercase().startswith(t.tolowercase())?e.slice(t.length)||"/":e}function e(e,t){return(e.aliasof||e)===(t.aliasof||t)}function o(e,t){if(object.keys(e).length!==object.keys(t).length)return!1;for(const n in e)if(!k(e[n],t[n]))return!1;return!0}function k(e,t){return g(e)?r(e,t):g(t)?r(t,e):e===t}function r(e,t){return g(t)?e.length===t.length&&e.every(((e,n)=>e===t[n])):1===e.length&&e[0]===t}var p,x,c,j;(x=p||(p={})).pop="pop",x.push="push",(j=c||(c={})).back="back",j.forward="forward",j.unknown="";const $=/^[^#]+#/;function s(e,t){return e.replace($,"#")+t}const a=()=>({left:window.pagexoffset,top:window.pageyoffset});function q(e){let t;if("el"in e){const n=e.el,r="string"==typeof n&&n.startswith("#"),o="string"==typeof n?r?document.getelementbyid(n.slice(1)):document.queryselector(n):n;if(!o)return;t=function(e,t){const n=document.documentelement.getboundingclientrect(),r=e.getboundingclientrect();return{behavior:t.behavior,left:r.left-n.left-(t.left||0),top:r.top-n.top-(t.top||0)}}(o,e)}else t=e;"scrollbehavior"in document.documentelement.style?window.scrollto(t):window.scrollto(null!=t.left?t.left:window.pagexoffset,null!=t.top?t.top:window.pageyoffset)}function l(e,t){return(history.state?history.state.position-t:-1)+e}const m=new map;let b=()=>location.protocol+"//"+location.host;function g(e,t){const{pathname:n,search:r,hash:o}=t,a=e.indexof("#");if(a>-1){let t=o.includes(e.slice(a))?e.slice(a).length:1,n=o.slice(t);return"/"!==n[0]&&(n="/"+n),w(n,"")}return w(n,e)+r+o}function _(e,t,n,r=!1,o=!1){return{back:e,current:t,forward:n,replaced:r,position:window.history.length,scroll:o?a():null}}function i(e){const t=function(e){const{history:t,location:n}=window,r={value:g(e,n)},o={value:t.state};function a(r,a,s){const c=e.indexof("#"),i=c>-1?(n.host&&document.queryselector("base")?e:e.slice(c))+r:b()+e+r;try{t[s?"replacestate":"pushstate"](a,"",i),o.value=a}catch(l){n[s?"replace":"assign"](i)}}return o.value||a(r.value,{back:null,current:r.value,forward:null,position:t.length-1,replaced:!0,scroll:null},!0),{location:r,state:o,push:function(e,n){const s=h({},o.value,t.state,{forward:e,scroll:a()});a(s.current,s,!0),a(e,h({},_(r.value,e,null),{position:s.position+1},n),!1),r.value=e},replace:function(e,n){a(e,h({},t.state,_(o.value.back,e,o.value.forward,!0),n,{position:o.value.position}),!0),r.value=e}}}(e=function(e){if(!e)if(p){const t=document.queryselector("base");e=(e=t&&t.getattribute("href")||"/").replace(/^\w+:\/\/[^\/]+/,"")}else e="/";return"/"!==e[0]&&"#"!==e[0]&&(e="/"+e),y(e)}(e)),n=function(e,t,n,r){let o=[],a=[],s=null;const c=({state:a})=>{const c=g(e,location),i=n.value,l=t.value;let u=0;if(a){if(n.value=c,t.value=a,s&&s===i)return void(s=null);u=l?a.position-l.position:0}else r(c);o.foreach((e=>{e(n.value,i,{delta:u,type:p.pop,direction:u?u>0?c.forward:c.back:c.unknown})}))};function i(){const{history:e}=window;e.state&&e.replacestate(h({},e.state,{scroll:a()}),"")}return window.addeventlistener("popstate",c),window.addeventlistener("beforeunload",i,{passive:!0}),{pauselisteners:function(){s=n.value},listen:function(e){o.push(e);const t=()=>{const t=o.indexof(e);t>-1&&o.splice(t,1)};return a.push(t),t},destroy:function(){for(const e of a)e();a=[],window.removeeventlistener("popstate",c),window.removeeventlistener("beforeunload",i)}}}(e,t.state,t.location,t.replace);const r=h({location:"",base:e,go:function(e,t=!0){t||n.pauselisteners(),history.go(e)},createhref:s.bind(null,e)},t,n);return object.defineproperty(r,"location",{enumerable:!0,get:()=>t.location.value}),object.defineproperty(r,"state",{enumerable:!0,get:()=>t.state.value}),r}function w(e){return"string"==typeof e||"symbol"==typeof e}const d={path:"/",name:void 0,params:{},query:{},hash:"",fullpath:"/",matched:[],meta:{},redirectedfrom:void 0},u=symbol("");var f,t;function v(e,t){return h(new error,{type:e,[u]:!0},t)}function z(e,t){return e instanceof error&&u in e&&(null==t||!!(e.type&t))}(t=f||(f={}))[t.aborted=4]="aborted",t[t.cancelled=8]="cancelled",t[t.duplicated=16]="duplicated";const k="[^/]+?",h={sensitive:!1,strict:!1,start:!0,end:!0},q=/[.+*?^${}()[\]/\\]/g;function x(e,t){let n=0;for(;nt.length?1===t.length&&80===t[0]?1:-1:0}function y(e,t){let n=0;const r=e.score,o=t.score;for(;n0&&t[t.length-1]<0}const n={type:0,value:""},j=/[a-za-z0-9_]/;function ee(e,t,n){const r=function(e,t){const n=h({},h,t),r=[];let o=n.start?"^":"";const a=[];for(const i of e){const e=i.length?[]:[90];n.strict&&!i.length&&(o+="/");for(let t=0;t1&&("*"===c||"+"===c)&&t(`a repeatable param (${l}) must be alone in its segment. eg: '/:ids+.`),a.push({type:1,value:l,regexp:u,repeatable:"*"===c||"+"===c,optional:"*"===c||"?"===c})):t("invalid state to consume buffer"),l="")}function p(){l+=c}for(;i{a(p)}:m}function a(e){if(w(e)){const t=r.get(e);t&&(r.delete(e),n.splice(n.indexof(t),1),t.children.foreach(a),t.alias.foreach(a))}else{const t=n.indexof(e);t>-1&&(n.splice(t,1),e.record.name&&r.delete(e.record.name),e.children.foreach(a),e.alias.foreach(a))}}function s(e){let t=0;for(;t=0&&(e.record.path!==n[t].record.path||!ce(e,n[t]));)t++;n.splice(t,0,e),e.record.name&&!oe(e)&&r.set(e.record.name,e)}return t=se({strict:!1,end:!0,sensitive:!1},t),e.foreach((e=>o(e))),{addroute:o,resolve:function(e,t){let o,a,s,c={};if("name"in e&&e.name){if(o=r.get(e.name),!o)throw v(1,{location:e});s=o.record.name,c=h(ne(t.params,o.keys.filter((e=>!e.optional)).map((e=>e.name))),e.params&&ne(e.params,o.keys.map((e=>e.name)))),a=o.stringify(c)}else if("path"in e)a=e.path,o=n.find((e=>e.re.test(a))),o&&(c=o.parse(a),s=o.record.name);else{if(o=t.name?r.get(t.name):n.find((e=>e.re.test(t.path))),!o)throw v(1,{location:e,currentlocation:t});s=o.record.name,c=h({},t.params,e.params),a=o.stringify(c)}const i=[];let l=o;for(;l;)i.unshift(l.record),l=l.parent;return{name:s,path:a,params:c,matched:i,meta:ae(i)}},removeroute:a,getroutes:function(){return n},getrecordmatcher:function(e){return r.get(e)}}}function ne(e,t){const n={};for(const r of t)r in e&&(n[r]=e[r]);return n}function re(e){const t={},n=e.props||!1;if("component"in e)t.default=n;else for(const r in e.components)t[r]="object"==typeof n?n[r]:n;return t}function oe(e){for(;e;){if(e.record.aliasof)return!0;e=e.parent}return!1}function ae(e){return e.reduce(((e,t)=>h(e,t.meta)),{})}function se(e,t){const n={};for(const r in e)n[r]=r in t?t[r]:e[r];return n}function ce(e,t){return t.children.some((t=>t===e||ce(e,t)))}const ie=/#/g,le=/&/g,ue=/\//g,fe=/=/g,pe=/\?/g,he=/\+/g,de=/%5b/g,me=/%5d/g,ge=/%5e/g,ve=/%60/g,ye=/%7b/g,be=/%7c/g,we=/%7d/g,ee=/%20/g;function oe(e){return encodeuri(""+e).replace(be,"|").replace(de,"[").replace(me,"]")}function ke(e){return oe(e).replace(he,"%2b").replace(ee,"+").replace(ie,"%23").replace(le,"%26").replace(ve,"`").replace(ye,"{").replace(we,"}").replace(ge,"^")}function re(e){return null==e?"":function(e){return oe(e).replace(ie,"%23").replace(pe,"%3f")}(e).replace(ue,"%2f")}function pe(e){try{return decodeuricomponent(""+e)}catch(t){}return""+e}function xe(e){const t={};if(""===e||"?"===e)return t;const n=("?"===e[0]?e.slice(1):e).split("&");for(let r=0;re&&ke(e))):[r&&ke(r)]).foreach((e=>{void 0!==e&&(t+=(t.length?"&":"")+n,null!=e&&(t+="="+e))}))}return t}function je(e){const t={};for(const n in e){const r=e[n];void 0!==r&&(t[n]=g(r)?r.map((e=>null==e?null:""+e)):null==r?r:""+r)}return t}const $e=symbol(""),se=symbol(""),ae=symbol(""),qe=symbol(""),le=symbol("");function me(){let e=[];return{add:function(t){return e.push(t),()=>{const n=e.indexof(t);n>-1&&e.splice(n,1)}},list:()=>e.slice(),reset:function(){e=[]}}}function be(e,t,n,r,o){const a=r&&(r.entercallbacks[o]=r.entercallbacks[o]||[]);return()=>new promise(((s,c)=>{const i=e=>{var i;!1===e?c(v(4,{from:n,to:t})):e instanceof error?c(e):"string"==typeof(i=e)||i&&"object"==typeof i?c(v(2,{from:t,to:e})):(a&&r.entercallbacks[o]===a&&"function"==typeof e&&a.push(e),s())},l=e.call(r&&r.instances[o],t,n,i);let u=promise.resolve(l);e.length<3&&(u=u.then(i)),u.catch((e=>c(e)))}))}function ge(e,t,n,r){const o=[];for(const s of e)for(const e in s.components){let c=s.components[e];if("beforerouteenter"===t||s.instances[e])if("object"==typeof(a=c)||"displayname"in a||"props"in a||"__vccopts"in a){const a=(c.__vccopts||c)[t];a&&o.push(be(a,n,r,s,e))}else{let a=c();o.push((()=>a.then((o=>{if(!o)return promise.reject(new error(`couldn't resolve component "${e}" at "${s.path}"`));const a=(c=o).__esmodule||"module"===c[symbol.tostringtag]?o.default:o;var c;s.components[e]=a;const i=(a.__vccopts||a)[t];return i&&be(i,n,r,s,e)()}))))}}var a;return o}function _e(e){const n=o(ae),r=o(qe),a=c((()=>n.resolve(t(e.to)))),s=c((()=>{const{matched:e}=a.value,{length:t}=e,n=e[t-1],o=r.matched;if(!n||!o.length)return-1;const s=o.findindex(e.bind(null,n));if(s>-1)return s;const c=we(e[t-2]);return t>1&&we(n)===c&&o[o.length-1].path!==c?o.findindex(e.bind(null,e[t-2])):s})),i=c((()=>s.value>-1&&function(e,t){for(const n in t){const r=t[n],o=e[n];if("string"==typeof r){if(r!==o)return!1}else if(!g(o)||o.length!==r.length||r.some(((e,t)=>e!==o[t])))return!1}return!0}(r.params,a.value.params))),l=c((()=>s.value>-1&&s.value===r.matched.length-1&&o(r.params,a.value.params)));return{route:a,href:c((()=>a.value.href)),isactive:i,isexactactive:l,navigate:function(r={}){return function(e){if(e.metakey||e.altkey||e.ctrlkey||e.shiftkey)return;if(e.defaultprevented)return;if(void 0!==e.button&&0!==e.button)return;if(e.currenttarget&&e.currenttarget.getattribute){const t=e.currenttarget.getattribute("target");if(/\b_blank\b/i.test(t))return}e.preventdefault&&e.preventdefault();return!0}(r)?n[t(e.replace)?"replace":"push"](t(e.to)).catch(m):promise.resolve()}}}const ie=a({name:"routerlink",compatconfig:{mode:3},props:{to:{type:[string,object],required:!0},replace:boolean,activeclass:string,exactactiveclass:string,custom:boolean,ariacurrentvalue:{type:string,default:"page"}},uselink:_e,setup(e,{slots:t}){const n=s(_e(e)),{options:r}=o(ae),a=c((()=>({[de(e.activeclass,r.linkactiveclass,"router-link-active")]:n.isactive,[de(e.exactactiveclass,r.linkexactactiveclass,"router-link-exact-active")]:n.isexactactive})));return()=>{const r=t.default&&t.default(n);return e.custom?r:i("a",{"aria-current":n.isexactactive?e.ariacurrentvalue:null,href:n.href,onclick:n.navigate,class:a.value},r)}}});function we(e){return e?e.aliasof?e.aliasof.path:e.path:""}const de=(e,t,n)=>null!=e?e:null!=t?t:n;function ue(e,t){if(!e)return null;const n=e(t);return 1===n.length?n[0]:n}const fe=a({name:"routerview",inheritattrs:!1,props:{name:{type:string,default:"default"},route:object},compatconfig:{mode:3},setup(e,{attrs:n,slots:r}){const a=o(le),s=c((()=>e.route||a.value)),p=o(se,0),d=c((()=>{let e=t(p);const{matched:n}=s.value;let r;for(;(r=n[e])&&!r.components;)e++;return e})),m=c((()=>s.value.matched[d.value]));l(se,c((()=>d.value+1))),l($e,m),l(le,s);const g=u();return f((()=>[g.value,m.value,e.name]),(([e,t,n],[r,o,a])=>{t&&(t.instances[n]=e,o&&o!==t&&e&&e===r&&(t.leaveguards.size||(t.leaveguards=o.leaveguards),t.updateguards.size||(t.updateguards=o.updateguards))),!e||!t||o&&e(t,o)&&r||(t.entercallbacks[n]||[]).foreach((t=>t(e)))}),{flush:"post"}),()=>{const t=s.value,o=e.name,a=m.value,c=a&&a.components[o];if(!c)return ue(r.default,{component:c,route:t});const l=a.props[o],u=l?!0===l?t.params:"function"==typeof l?l(t):l:null,f=i(c,h({},u,n,{onvnodeunmounted:e=>{e.component.isunmounted&&(a.instances[o]=null)},ref:g}));return ue(r.default,{component:f,route:t})||f}}});function te(o){const a=te(o.routes,o),s=o.parsequery||xe,c=o.stringifyquery||ce,i=o.history,l=me(),u=me(),f=me(),v=e(d);let y=d;p&&o.scrollbehavior&&"scrollrestoration"in history&&(history.scrollrestoration="manual");const w=d.bind(null,(e=>""+e)),k=d.bind(null,re),r=d.bind(null,pe);function x(e,t){if(t=h({},t||v.value),"string"==typeof e){const n=b(s,e,t.path),r=a.resolve({path:n.path},t),o=i.createhref(n.fullpath);return h(n,r,{params:r(r.params),hash:pe(n.hash),redirectedfrom:void 0,href:o})}let n;if("path"in e)n=h({},e,{path:b(s,e.path,t.path).path});else{const r=h({},e.params);for(const e in r)null==r[e]&&delete r[e];n=h({},e,{params:k(r)}),t.params=k(t.params)}const r=a.resolve(n,t),o=e.hash||"";r.params=w(r(r.params));const l=function(e,t){const n=t.query?e(t.query):"";return t.path+(n&&"?")+n+(t.hash||"")}(c,h({},e,{hash:(u=o,oe(u).replace(ye,"{").replace(we,"}").replace(ge,"^")),path:r.path}));var u;const f=i.createhref(l);return h({fullpath:l,hash:o,query:c===ce?je(e.query):e.query||{}},r,{redirectedfrom:void 0,href:f})}function c(e){return"string"==typeof e?b(s,e,v.value.path):h({},e)}function j(e,t){if(y!==e)return v(8,{from:t,to:e})}function $(e){return b(e)}function s(e){const t=e.matched[e.matched.length-1];if(t&&t.redirect){const{redirect:n}=t;let r="function"==typeof n?n(e):n;return"string"==typeof r&&(r=r.includes("?")||r.includes("#")?r=c(r):{path:r},r.params={}),h({query:e.query,hash:e.hash,params:"path"in r?{}:e.params},r)}}function b(e,t){const n=y=x(e),r=v.value,o=e.state,a=e.force,s=!0===e.replace,i=s(n);if(i)return b(h(c(i),{state:"object"==typeof i?h({},o,i.state):o,force:a,replace:s}),t||n);const l=n;let u;return l.redirectedfrom=t,!a&&function(e,t,n){const r=t.matched.length-1,o=n.matched.length-1;return r>-1&&r===o&&e(t.matched[r],n.matched[o])&&o(t.params,n.params)&&e(t.query)===e(n.query)&&t.hash===n.hash}(c,r,n)&&(u=v(16,{to:l,from:r}),n(r,r,!0,!1)),(u?promise.resolve(u):i(l,r)).catch((e=>z(e)?z(e,2)?e:z(e):y(e,l,r))).then((e=>{if(e){if(z(e,2))return b(h({replace:s},c(e.to),{state:"object"==typeof e.to?h({},o,e.to.state):o,force:a}),t||l)}else e=f(l,r,!0,s,o);return u(l,r,e),e}))}function g(e,t){const n=j(e,t);return n?promise.reject(n):promise.resolve()}function _(e){const t=ne.values().next().value;return t&&"function"==typeof t.runwithcontext?t.runwithcontext(e):e()}function i(e,t){let n;const[r,o,a]=function(e,t){const n=[],r=[],o=[],a=math.max(t.matched.length,e.matched.length);for(let s=0;se(e,a)))?r.push(a):n.push(a));const c=e.matched[s];c&&(t.matched.find((e=>e(e,c)))||o.push(c))}return[n,r,o]}(e,t);n=ge(r.reverse(),"beforerouteleave",e,t);for(const c of r)c.leaveguards.foreach((r=>{n.push(be(r,e,t))}));const s=g.bind(null,e,t);return n.push(s),oe(n).then((()=>{n=[];for(const r of l.list())n.push(be(r,e,t));return n.push(s),oe(n)})).then((()=>{n=ge(o,"beforerouteupdate",e,t);for(const r of o)r.updateguards.foreach((r=>{n.push(be(r,e,t))}));return n.push(s),oe(n)})).then((()=>{n=[];for(const r of a)if(r.beforeenter)if(g(r.beforeenter))for(const o of r.beforeenter)n.push(be(o,e,t));else n.push(be(r.beforeenter,e,t));return n.push(s),oe(n)})).then((()=>(e.matched.foreach((e=>e.entercallbacks={})),n=ge(a,"beforerouteenter",e,t),n.push(s),oe(n)))).then((()=>{n=[];for(const r of u.list())n.push(be(r,e,t));return n.push(s),oe(n)})).catch((e=>z(e,8)?e:promise.reject(e)))}function u(e,t,n){f.list().foreach((r=>_((()=>r(e,t,n)))))}function f(e,t,n,r,o){const a=j(e,t);if(a)return a;const s=t===d,c=p?history.state:{};n&&(r||s?i.replace(e.fullpath,h({scroll:s&&c&&c.scroll},o)):i.push(e.fullpath,o)),v.value=e,n(e,t,n,s),z()}let t;function k(){t||(t=i.listen(((e,t,n)=>{if(!re.listening)return;const r=x(e),o=s(r);if(o)return void b(h(o,{replace:!0}),r).catch(m);y=r;const a=v.value;var s,c;p&&(s=l(a.fullpath,n.delta),c=a(),m.set(s,c)),i(r,a).catch((e=>z(e,12)?e:z(e,2)?(b(e.to,r).then((e=>{z(e,20)&&!n.delta&&n.type===p.pop&&i.go(-1,!1)})).catch(m),promise.reject()):(n.delta&&i.go(-n.delta,!1),y(e,r,a)))).then((e=>{(e=e||f(r,a,!1))&&(n.delta&&!z(e,8)?i.go(-n.delta,!1):n.type===p.pop&&z(e,20)&&i.go(-1,!1)),u(r,a,e)})).catch(m)})))}let h,q=me(),x=me();function y(e,t,n){z(e);const r=x.list();return r.length&&r.foreach((r=>r(e,t,n))),promise.reject(e)}function z(e){return h||(h=!e,k(),q.list().foreach((([t,n])=>e?n(e):t())),q.reset()),e}function n(e,t,n,a){const{scrollbehavior:s}=o;if(!p||!s)return promise.resolve();const c=!n&&function(e){const t=m.get(e);return m.delete(e),t}(l(e.fullpath,0))||(a||!n)&&history.state&&history.state.scroll||null;return r().then((()=>s(e,t,c))).then((e=>e&&q(e))).catch((n=>y(n,e,t)))}const j=e=>i.go(e);let ee;const ne=new set,re={currentroute:v,listening:!0,addroute:function(e,t){let n,r;return w(e)?(n=a.getrecordmatcher(e),r=t):r=e,a.addroute(r,n)},removeroute:function(e){const t=a.getrecordmatcher(e);t&&a.removeroute(t)},hasroute:function(e){return!!a.getrecordmatcher(e)},getroutes:function(){return a.getroutes().map((e=>e.record))},resolve:x,options:o,push:$,replace:function(e){return $(h(c(e),{replace:!0}))},go:j,back:()=>j(-1),forward:()=>j(1),beforeeach:l.add,beforeresolve:u.add,aftereach:f.add,onerror:x.add,isready:function(){return h&&v.value!==d?promise.resolve():new promise(((e,t)=>{q.add([e,t])}))},install(e){e.component("routerlink",ie),e.component("routerview",fe),e.config.globalproperties.$router=this,object.defineproperty(e.config.globalproperties,"$route",{enumerable:!0,get:()=>t(v)}),p&&!ee&&v.value===d&&(ee=!0,$(i.location).catch((e=>{})));const r={};for(const t in d)object.defineproperty(r,t,{get:()=>v.value[t],enumerable:!0});e.provide(ae,this),e.provide(qe,n(r)),e.provide(le,v);const o=e.unmount;ne.add(e),e.unmount=function(){ne.delete(e),ne.size<1&&(y=d,t&&t(),t=null,v.value=d,ee=!1,h=!1),o()}}};function oe(e){return e.reduce(((e,t)=>e.then((()=>_(t)))),promise.resolve())}return re}function ve(){return o(ae)}function ze(){return o(qe)}export{i as a,ze as b,te as c,ve as u};