@knxcloud/lowcode-vue-simulator-renderer
Version:
5 lines • 122 kB
JavaScript
(function(V,f){typeof exports=="object"&&typeof module!="undefined"?f(exports,require("vue")):typeof define=="function"&&define.amd?define(["exports","vue"],f):(V=typeof globalThis!="undefined"?globalThis:V||self,f(V.LCVueSimulatorRenderer={},V.Vue))})(this,function(V,f){"use strict";var Rl=Object.defineProperty;var Pl=(V,f,ye)=>f in V?Rl(V,f,{enumerable:!0,configurable:!0,writable:!0,value:ye}):V[f]=ye;var Po=(V,f,ye)=>(Pl(V,typeof f!="symbol"?f+"":f,ye),ye);function ye(){return mn().__VUE_DEVTOOLS_GLOBAL_HOOK__}function mn(){return typeof navigator!="undefined"&&typeof window!="undefined"?window:typeof global!="undefined"?global:{}}const Oo=typeof Proxy=="function",To="devtools-plugin:setup",No="plugin:settings:set";let xe,_t;function Io(){var e;return xe!==void 0||(typeof window!="undefined"&&window.performance?(xe=!0,_t=window.performance):typeof global!="undefined"&&(!((e=global.perf_hooks)===null||e===void 0)&&e.performance)?(xe=!0,_t=global.perf_hooks.performance):xe=!1),xe}function Ho(){return Io()?_t.now():Date.now()}class Ao{constructor(t,n){this.target=null,this.targetQueue=[],this.onQueue=[],this.plugin=t,this.hook=n;const r={};if(t.settings)for(const s in t.settings){const u=t.settings[s];r[s]=u.defaultValue}const o=`__vue-devtools-plugin-settings__${t.id}`;let i=Object.assign({},r);try{const s=localStorage.getItem(o),u=JSON.parse(s);Object.assign(i,u)}catch(s){}this.fallbacks={getSettings(){return i},setSettings(s){try{localStorage.setItem(o,JSON.stringify(s))}catch(u){}i=s},now(){return Ho()}},n&&n.on(No,(s,u)=>{s===this.plugin.id&&this.fallbacks.setSettings(u)}),this.proxiedOn=new Proxy({},{get:(s,u)=>this.target?this.target.on[u]:(...c)=>{this.onQueue.push({method:u,args:c})}}),this.proxiedTarget=new Proxy({},{get:(s,u)=>this.target?this.target[u]:u==="on"?this.proxiedOn:Object.keys(this.fallbacks).includes(u)?(...c)=>(this.targetQueue.push({method:u,args:c,resolve:()=>{}}),this.fallbacks[u](...c)):(...c)=>new Promise(h=>{this.targetQueue.push({method:u,args:c,resolve:h})})})}async setRealTarget(t){this.target=t;for(const n of this.onQueue)this.target.on[n.method](...n.args);for(const n of this.targetQueue)n.resolve(await this.target[n.method](...n.args))}}function Bo(e,t){const n=e,r=mn(),o=ye(),i=Oo&&n.enableEarlyProxy;if(o&&(r.__VUE_DEVTOOLS_PLUGIN_API_AVAILABLE__||!i))o.emit(To,e,t);else{const s=i?new Ao(n,o):null;(r.__VUE_DEVTOOLS_PLUGINS__=r.__VUE_DEVTOOLS_PLUGINS__||[]).push({pluginDescriptor:n,setupFn:t,proxy:s}),s&&t(s.proxiedTarget)}}/*!
* vue-router v4.2.4
* (c) 2023 Eduardo San Martin Morote
* @license MIT
*/const ue=typeof window!="undefined";function gn(e){return e.__esModule||e[Symbol.toStringTag]==="Module"}const F=Object.assign;function yt(e,t){const n={};for(const r in t){const o=t[r];n[r]=oe(o)?o.map(e):e(o)}return n}const Be=()=>{},oe=Array.isArray,Lo=/\/$/,Mo=e=>e.replace(Lo,"");function Et(e,t,n="/"){let r,o={},i="",s="";const u=t.indexOf("#");let c=t.indexOf("?");return u<c&&u>=0&&(c=-1),c>-1&&(r=t.slice(0,c),i=t.slice(c+1,u>-1?u:t.length),o=e(i)),u>-1&&(r=r||t.slice(0,u),s=t.slice(u,t.length)),r=jo(r!=null?r:t,n),{fullPath:r+(i&&"?")+i+s,path:r,query:o,hash:s}}function Do(e,t){const n=t.query?e(t.query):"";return t.path+(n&&"?")+n+(t.hash||"")}function _n(e,t){return!t||!e.toLowerCase().startsWith(t.toLowerCase())?e:e.slice(t.length)||"/"}function Uo(e,t,n){const r=t.matched.length-1,o=n.matched.length-1;return r>-1&&r===o&&me(t.matched[r],n.matched[o])&&yn(t.params,n.params)&&e(t.query)===e(n.query)&&t.hash===n.hash}function me(e,t){return(e.aliasOf||e)===(t.aliasOf||t)}function yn(e,t){if(Object.keys(e).length!==Object.keys(t).length)return!1;for(const n in e)if(!ko(e[n],t[n]))return!1;return!0}function ko(e,t){return oe(e)?En(e,t):oe(t)?En(t,e):e===t}function En(e,t){return oe(t)?e.length===t.length&&e.every((n,r)=>n===t[r]):e.length===1&&e[0]===t}function jo(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 i=n.length-1,s,u;for(s=0;s<r.length;s++)if(u=r[s],u!==".")if(u==="..")i>1&&i--;else break;return n.slice(0,i).join("/")+"/"+r.slice(s-(s===r.length?1:0)).join("/")}var Ce;(function(e){e.pop="pop",e.push="push"})(Ce||(Ce={}));var Ee;(function(e){e.back="back",e.forward="forward",e.unknown=""})(Ee||(Ee={}));const bt="";function bn(e){if(!e)if(ue){const t=document.querySelector("base");e=t&&t.getAttribute("href")||"/",e=e.replace(/^\w+:\/\/[^\/]+/,"")}else e="/";return e[0]!=="/"&&e[0]!=="#"&&(e="/"+e),Mo(e)}const Go=/^[^#]+#/;function Sn(e,t){return e.replace(Go,"#")+t}function Fo(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)}}const We=()=>({left:window.pageXOffset,top:window.pageYOffset});function $o(e){let t;if("el"in e){const n=e.el,r=typeof n=="string"&&n.startsWith("#"),o=typeof n=="string"?r?document.getElementById(n.slice(1)):document.querySelector(n):n;if(!o)return;t=Fo(o,e)}else t=e;"scrollBehavior"in document.documentElement.style?window.scrollTo(t):window.scrollTo(t.left!=null?t.left:window.pageXOffset,t.top!=null?t.top:window.pageYOffset)}function vn(e,t){return(history.state?history.state.position-t:-1)+e}const St=new Map;function Vo(e,t){St.set(e,t)}function qo(e){const t=St.get(e);return St.delete(e),t}let Xo=()=>location.protocol+"//"+location.host;function xn(e,t){const{pathname:n,search:r,hash:o}=t,i=e.indexOf("#");if(i>-1){let u=o.includes(e.slice(i))?e.slice(i).length:1,c=o.slice(u);return c[0]!=="/"&&(c="/"+c),_n(c,"")}return _n(n,e)+r+o}function zo(e,t,n,r){let o=[],i=[],s=null;const u=({state:a})=>{const p=xn(e,location),m=n.value,b=t.value;let y=0;if(a){if(n.value=p,t.value=a,s&&s===m){s=null;return}y=b?a.position-b.position:0}else r(p);o.forEach(S=>{S(n.value,m,{delta:y,type:Ce.pop,direction:y?y>0?Ee.forward:Ee.back:Ee.unknown})})};function c(){s=n.value}function h(a){o.push(a);const p=()=>{const m=o.indexOf(a);m>-1&&o.splice(m,1)};return i.push(p),p}function l(){const{history:a}=window;a.state&&a.replaceState(F({},a.state,{scroll:We()}),"")}function d(){for(const a of i)a();i=[],window.removeEventListener("popstate",u),window.removeEventListener("beforeunload",l)}return window.addEventListener("popstate",u),window.addEventListener("beforeunload",l,{passive:!0}),{pauseListeners:c,listen:h,destroy:d}}function Cn(e,t,n,r=!1,o=!1){return{back:e,current:t,forward:n,replaced:r,position:window.history.length,scroll:o?We():null}}function Wo(e){const{history:t,location:n}=window,r={value:xn(e,n)},o={value:t.state};o.value||i(r.value,{back:null,current:r.value,forward:null,position:t.length-1,replaced:!0,scroll:null},!0);function i(c,h,l){const d=e.indexOf("#"),a=d>-1?(n.host&&document.querySelector("base")?e:e.slice(d))+c:Xo()+e+c;try{t[l?"replaceState":"pushState"](h,"",a),o.value=h}catch(p){console.error(p),n[l?"replace":"assign"](a)}}function s(c,h){const l=F({},t.state,Cn(o.value.back,c,o.value.forward,!0),h,{position:o.value.position});i(c,l,!0),r.value=c}function u(c,h){const l=F({},o.value,t.state,{forward:c,scroll:We()});i(l.current,l,!0);const d=F({},Cn(r.value,c,null),{position:l.position+1},h);i(c,d,!1),r.value=c}return{location:r,state:o,push:u,replace:s}}function Rn(e){e=bn(e);const t=Wo(e),n=zo(e,t.state,t.location,t.replace);function r(i,s=!0){s||n.pauseListeners(),history.go(i)}const o=F({location:"",base:e,go:r,createHref:Sn.bind(null,e)},t,n);return Object.defineProperty(o,"location",{enumerable:!0,get:()=>t.location.value}),Object.defineProperty(o,"state",{enumerable:!0,get:()=>t.state.value}),o}function Pn(e=""){let t=[],n=[bt],r=0;e=bn(e);function o(u){r++,r===n.length||n.splice(r),n.push(u)}function i(u,c,{direction:h,delta:l}){const d={direction:h,delta:l,type:Ce.pop};for(const a of t)a(u,c,d)}const s={location:bt,state:{},base:e,createHref:Sn.bind(null,e),replace(u){n.splice(r--,1),o(u)},push(u,c){o(u)},listen(u){return t.push(u),()=>{const c=t.indexOf(u);c>-1&&t.splice(c,1)}},destroy(){t=[],n=[bt],r=0},go(u,c=!0){const h=this.location,l=u<0?Ee.back:Ee.forward;r=Math.max(0,Math.min(r+u,n.length-1)),c&&i(this.location,h,{direction:l,delta:u})}};return Object.defineProperty(s,"location",{enumerable:!0,get:()=>n[r]}),s}function Jo(e){return e=location.host?e||location.pathname+location.search:"",e.includes("#")||(e+="#"),Rn(e)}function Ko(e){return typeof e=="string"||e&&typeof e=="object"}function wn(e){return typeof e=="string"||typeof e=="symbol"}const ce={path:"/",name:void 0,params:{},query:{},hash:"",fullPath:"/",matched:[],meta:{},redirectedFrom:void 0},On=Symbol("");var vt;(function(e){e[e.aborted=4]="aborted",e[e.cancelled=8]="cancelled",e[e.duplicated=16]="duplicated"})(vt||(vt={}));function Re(e,t){return F(new Error,{type:e,[On]:!0},t)}function le(e,t){return e instanceof Error&&On in e&&(t==null||!!(e.type&t))}const Tn="[^/]+?",Qo={sensitive:!1,strict:!1,start:!0,end:!0},Zo=/[.+*?^${}()[\]/\\]/g;function Yo(e,t){const n=F({},Qo,t),r=[];let o=n.start?"^":"";const i=[];for(const h of e){const l=h.length?[]:[90];n.strict&&!h.length&&(o+="/");for(let d=0;d<h.length;d++){const a=h[d];let p=40+(n.sensitive?.25:0);if(a.type===0)d||(o+="/"),o+=a.value.replace(Zo,"\\$&"),p+=40;else if(a.type===1){const{value:m,repeatable:b,optional:y,regexp:S}=a;i.push({name:m,repeatable:b,optional:y});const g=S||Tn;if(g!==Tn){p+=10;try{new RegExp(`(${g})`)}catch(P){throw new Error(`Invalid custom RegExp for param "${m}" (${g}): `+P.message)}}let v=b?`((?:${g})(?:/(?:${g}))*)`:`(${g})`;d||(v=y&&h.length<2?`(?:/${v})`:"/"+v),y&&(v+="?"),o+=v,p+=20,y&&(p+=-8),b&&(p+=-20),g===".*"&&(p+=-50)}l.push(p)}r.push(l)}if(n.strict&&n.end){const h=r.length-1;r[h][r[h].length-1]+=.7000000000000001}n.strict||(o+="/?"),n.end?o+="$":n.strict&&(o+="(?:/|$)");const s=new RegExp(o,n.sensitive?"":"i");function u(h){const l=h.match(s),d={};if(!l)return null;for(let a=1;a<l.length;a++){const p=l[a]||"",m=i[a-1];d[m.name]=p&&m.repeatable?p.split("/"):p}return d}function c(h){let l="",d=!1;for(const a of e){(!d||!l.endsWith("/"))&&(l+="/"),d=!1;for(const p of a)if(p.type===0)l+=p.value;else if(p.type===1){const{value:m,repeatable:b,optional:y}=p,S=m in h?h[m]:"";if(oe(S)&&!b)throw new Error(`Provided param "${m}" is an array but it is not repeatable (* or + modifiers)`);const g=oe(S)?S.join("/"):S;if(!g)if(y)a.length<2&&(l.endsWith("/")?l=l.slice(0,-1):d=!0);else throw new Error(`Missing required param "${m}"`);l+=g}}return l||"/"}return{re:s,score:r,keys:i,parse:u,stringify:c}}function ei(e,t){let n=0;for(;n<e.length&&n<t.length;){const r=t[n]-e[n];if(r)return r;n++}return e.length<t.length?e.length===1&&e[0]===40+40?-1:1:e.length>t.length?t.length===1&&t[0]===40+40?1:-1:0}function ti(e,t){let n=0;const r=e.score,o=t.score;for(;n<r.length&&n<o.length;){const i=ei(r[n],o[n]);if(i)return i;n++}if(Math.abs(o.length-r.length)===1){if(Nn(r))return 1;if(Nn(o))return-1}return o.length-r.length}function Nn(e){const t=e[e.length-1];return e.length>0&&t[t.length-1]<0}const ni={type:0,value:""},ri=/[a-zA-Z0-9_]/;function oi(e){if(!e)return[[]];if(e==="/")return[[ni]];if(!e.startsWith("/"))throw new Error(`Invalid path "${e}"`);function t(p){throw new Error(`ERR (${n})/"${h}": ${p}`)}let n=0,r=n;const o=[];let i;function s(){i&&o.push(i),i=[]}let u=0,c,h="",l="";function d(){h&&(n===0?i.push({type:0,value:h}):n===1||n===2||n===3?(i.length>1&&(c==="*"||c==="+")&&t(`A repeatable param (${h}) must be alone in its segment. eg: '/:ids+.`),i.push({type:1,value:h,regexp:l,repeatable:c==="*"||c==="+",optional:c==="*"||c==="?"})):t("Invalid state to consume buffer"),h="")}function a(){h+=c}for(;u<e.length;){if(c=e[u++],c==="\\"&&n!==2){r=n,n=4;continue}switch(n){case 0:c==="/"?(h&&d(),s()):c===":"?(d(),n=1):a();break;case 4:a(),n=r;break;case 1:c==="("?n=2:ri.test(c)?a():(d(),n=0,c!=="*"&&c!=="?"&&c!=="+"&&u--);break;case 2:c===")"?l[l.length-1]=="\\"?l=l.slice(0,-1)+c:n=3:l+=c;break;case 3:d(),n=0,c!=="*"&&c!=="?"&&c!=="+"&&u--,l="";break;default:t("Unknown state");break}}return n===2&&t(`Unfinished custom RegExp for param "${h}"`),d(),s(),o}function ii(e,t,n){const r=Yo(oi(e.path),n),o=F(r,{record:e,parent:t,children:[],alias:[]});return t&&!o.record.aliasOf==!t.record.aliasOf&&t.children.push(o),o}function In(e,t){const n=[],r=new Map;t=Bn({strict:!1,end:!0,sensitive:!1},t);function o(l){return r.get(l)}function i(l,d,a){const p=!a,m=si(l);m.aliasOf=a&&a.record;const b=Bn(t,l),y=[m];if("alias"in l){const v=typeof l.alias=="string"?[l.alias]:l.alias;for(const P of v)y.push(F({},m,{components:a?a.record.components:m.components,path:P,aliasOf:a?a.record:m}))}let S,g;for(const v of y){const{path:P}=v;if(d&&P[0]!=="/"){const _=d.record.path,x=_[_.length-1]==="/"?"":"/";v.path=d.record.path+(P&&x+P)}if(S=ii(v,d,b),a?a.alias.push(S):(g=g||S,g!==S&&g.alias.push(S),p&&l.name&&!An(S)&&s(l.name)),m.children){const _=m.children;for(let x=0;x<_.length;x++)i(_[x],S,a&&a.children[x])}a=a||S,(S.record.components&&Object.keys(S.record.components).length||S.record.name||S.record.redirect)&&c(S)}return g?()=>{s(g)}:Be}function s(l){if(wn(l)){const d=r.get(l);d&&(r.delete(l),n.splice(n.indexOf(d),1),d.children.forEach(s),d.alias.forEach(s))}else{const d=n.indexOf(l);d>-1&&(n.splice(d,1),l.record.name&&r.delete(l.record.name),l.children.forEach(s),l.alias.forEach(s))}}function u(){return n}function c(l){let d=0;for(;d<n.length&&ti(l,n[d])>=0&&(l.record.path!==n[d].record.path||!Ln(l,n[d]));)d++;n.splice(d,0,l),l.record.name&&!An(l)&&r.set(l.record.name,l)}function h(l,d){let a,p={},m,b;if("name"in l&&l.name){if(a=r.get(l.name),!a)throw Re(1,{location:l});b=a.record.name,p=F(Hn(d.params,a.keys.filter(g=>!g.optional).map(g=>g.name)),l.params&&Hn(l.params,a.keys.map(g=>g.name))),m=a.stringify(p)}else if("path"in l)m=l.path,a=n.find(g=>g.re.test(m)),a&&(p=a.parse(m),b=a.record.name);else{if(a=d.name?r.get(d.name):n.find(g=>g.re.test(d.path)),!a)throw Re(1,{location:l,currentLocation:d});b=a.record.name,p=F({},d.params,l.params),m=a.stringify(p)}const y=[];let S=a;for(;S;)y.unshift(S.record),S=S.parent;return{name:b,path:m,params:p,matched:y,meta:li(y)}}return e.forEach(l=>i(l)),{addRoute:i,resolve:h,removeRoute:s,getRoutes:u,getRecordMatcher:o}}function Hn(e,t){const n={};for(const r of t)r in e&&(n[r]=e[r]);return n}function si(e){return{path:e.path,redirect:e.redirect,name:e.name,meta:e.meta||{},aliasOf:void 0,beforeEnter:e.beforeEnter,props:ai(e),children:e.children||[],instances:{},leaveGuards:new Set,updateGuards:new Set,enterCallbacks:{},components:"components"in e?e.components||null:e.component&&{default:e.component}}}function ai(e){const t={},n=e.props||!1;if("component"in e)t.default=n;else for(const r in e.components)t[r]=typeof n=="object"?n[r]:n;return t}function An(e){for(;e;){if(e.record.aliasOf)return!0;e=e.parent}return!1}function li(e){return e.reduce((t,n)=>F(t,n.meta),{})}function Bn(e,t){const n={};for(const r in e)n[r]=r in t?t[r]:e[r];return n}function Ln(e,t){return t.children.some(n=>n===e||Ln(e,n))}const Mn=/#/g,ui=/&/g,ci=/\//g,fi=/=/g,hi=/\?/g,Dn=/\+/g,di=/%5B/g,pi=/%5D/g,Un=/%5E/g,mi=/%60/g,kn=/%7B/g,gi=/%7C/g,jn=/%7D/g,_i=/%20/g;function xt(e){return encodeURI(""+e).replace(gi,"|").replace(di,"[").replace(pi,"]")}function yi(e){return xt(e).replace(kn,"{").replace(jn,"}").replace(Un,"^")}function Ct(e){return xt(e).replace(Dn,"%2B").replace(_i,"+").replace(Mn,"%23").replace(ui,"%26").replace(mi,"`").replace(kn,"{").replace(jn,"}").replace(Un,"^")}function Ei(e){return Ct(e).replace(fi,"%3D")}function bi(e){return xt(e).replace(Mn,"%23").replace(hi,"%3F")}function Si(e){return e==null?"":bi(e).replace(ci,"%2F")}function Le(e){try{return decodeURIComponent(""+e)}catch(t){}return""+e}function Gn(e){const t={};if(e===""||e==="?")return t;const r=(e[0]==="?"?e.slice(1):e).split("&");for(let o=0;o<r.length;++o){const i=r[o].replace(Dn," "),s=i.indexOf("="),u=Le(s<0?i:i.slice(0,s)),c=s<0?null:Le(i.slice(s+1));if(u in t){let h=t[u];oe(h)||(h=t[u]=[h]),h.push(c)}else t[u]=c}return t}function Rt(e){let t="";for(let n in e){const r=e[n];if(n=Ei(n),r==null){r!==void 0&&(t+=(t.length?"&":"")+n);continue}(oe(r)?r.map(i=>i&&Ct(i)):[r&&Ct(r)]).forEach(i=>{i!==void 0&&(t+=(t.length?"&":"")+n,i!=null&&(t+="="+i))})}return t}function vi(e){const t={};for(const n in e){const r=e[n];r!==void 0&&(t[n]=oe(r)?r.map(o=>o==null?null:""+o):r==null?r:""+r)}return t}const Je=Symbol(""),Pt=Symbol(""),Me=Symbol(""),Ke=Symbol(""),Qe=Symbol("");function De(){let e=[];function t(r){return e.push(r),()=>{const o=e.indexOf(r);o>-1&&e.splice(o,1)}}function n(){e=[]}return{add:t,list:()=>e.slice(),reset:n}}function Fn(e,t,n){const r=()=>{e[t].delete(n)};f.onUnmounted(r),f.onDeactivated(r),f.onActivated(()=>{e[t].add(n)}),e[t].add(n)}function xi(e){const t=f.inject(Je,{}).value;t&&Fn(t,"leaveGuards",e)}function Ci(e){const t=f.inject(Je,{}).value;t&&Fn(t,"updateGuards",e)}function ge(e,t,n,r,o){const i=r&&(r.enterCallbacks[o]=r.enterCallbacks[o]||[]);return()=>new Promise((s,u)=>{const c=d=>{d===!1?u(Re(4,{from:n,to:t})):d instanceof Error?u(d):Ko(d)?u(Re(2,{from:t,to:d})):(i&&r.enterCallbacks[o]===i&&typeof d=="function"&&i.push(d),s())},h=e.call(r&&r.instances[o],t,n,c);let l=Promise.resolve(h);e.length<3&&(l=l.then(c)),l.catch(d=>u(d))})}function wt(e,t,n,r){const o=[];for(const i of e)for(const s in i.components){let u=i.components[s];if(!(t!=="beforeRouteEnter"&&!i.instances[s]))if(Ri(u)){const h=(u.__vccOpts||u)[t];h&&o.push(ge(h,n,r,i,s))}else{let c=u();o.push(()=>c.then(h=>{if(!h)return Promise.reject(new Error(`Couldn't resolve component "${s}" at "${i.path}"`));const l=gn(h)?h.default:h;i.components[s]=l;const a=(l.__vccOpts||l)[t];return a&&ge(a,n,r,i,s)()}))}}return o}function Ri(e){return typeof e=="object"||"displayName"in e||"props"in e||"__vccOpts"in e}function Pi(e){return e.matched.every(t=>t.redirect)?Promise.reject(new Error("Cannot load a route that redirects.")):Promise.all(e.matched.map(t=>t.components&&Promise.all(Object.keys(t.components).reduce((n,r)=>{const o=t.components[r];return typeof o=="function"&&!("displayName"in o)&&n.push(o().then(i=>{if(!i)return Promise.reject(new Error(`Couldn't resolve component "${r}" at "${t.path}". Ensure you passed a function that returns a promise.`));const s=gn(i)?i.default:i;t.components[r]=s})),n},[])))).then(()=>e)}function Ot(e){const t=f.inject(Me),n=f.inject(Ke),r=f.computed(()=>t.resolve(f.unref(e.to))),o=f.computed(()=>{const{matched:c}=r.value,{length:h}=c,l=c[h-1],d=n.matched;if(!l||!d.length)return-1;const a=d.findIndex(me.bind(null,l));if(a>-1)return a;const p=Vn(c[h-2]);return h>1&&Vn(l)===p&&d[d.length-1].path!==p?d.findIndex(me.bind(null,c[h-2])):a}),i=f.computed(()=>o.value>-1&&Oi(n.params,r.value.params)),s=f.computed(()=>o.value>-1&&o.value===n.matched.length-1&&yn(n.params,r.value.params));function u(c={}){return wi(c)?t[f.unref(e.replace)?"replace":"push"](f.unref(e.to)).catch(Be):Promise.resolve()}if(ue){const c=f.getCurrentInstance();if(c){const h={route:r.value,isActive:i.value,isExactActive:s.value};c.__vrl_devtools=c.__vrl_devtools||[],c.__vrl_devtools.push(h),f.watchEffect(()=>{h.route=r.value,h.isActive=i.value,h.isExactActive=s.value},{flush:"post"})}}return{route:r,href:f.computed(()=>r.value.href),isActive:i,isExactActive:s,navigate:u}}const $n=f.defineComponent({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:Ot,setup(e,{slots:t}){const n=f.reactive(Ot(e)),{options:r}=f.inject(Me),o=f.computed(()=>({[qn(e.activeClass,r.linkActiveClass,"router-link-active")]:n.isActive,[qn(e.exactActiveClass,r.linkExactActiveClass,"router-link-exact-active")]:n.isExactActive}));return()=>{const i=t.default&&t.default(n);return e.custom?i:f.h("a",{"aria-current":n.isExactActive?e.ariaCurrentValue:null,href:n.href,onClick:n.navigate,class:o.value},i)}}});function wi(e){if(!(e.metaKey||e.altKey||e.ctrlKey||e.shiftKey)&&!e.defaultPrevented&&!(e.button!==void 0&&e.button!==0)){if(e.currentTarget&&e.currentTarget.getAttribute){const t=e.currentTarget.getAttribute("target");if(/\b_blank\b/i.test(t))return}return e.preventDefault&&e.preventDefault(),!0}}function Oi(e,t){for(const n in t){const r=t[n],o=e[n];if(typeof r=="string"){if(r!==o)return!1}else if(!oe(o)||o.length!==r.length||r.some((i,s)=>i!==o[s]))return!1}return!0}function Vn(e){return e?e.aliasOf?e.aliasOf.path:e.path:""}const qn=(e,t,n)=>e!=null?e:t!=null?t:n,Ti=f.defineComponent({name:"RouterView",inheritAttrs:!1,props:{name:{type:String,default:"default"},route:Object},compatConfig:{MODE:3},setup(e,{attrs:t,slots:n}){const r=f.inject(Qe),o=f.computed(()=>e.route||r.value),i=f.inject(Pt,0),s=f.computed(()=>{let h=f.unref(i);const{matched:l}=o.value;let d;for(;(d=l[h])&&!d.components;)h++;return h}),u=f.computed(()=>o.value.matched[s.value]);f.provide(Pt,f.computed(()=>s.value+1)),f.provide(Je,u),f.provide(Qe,o);const c=f.ref();return f.watch(()=>[c.value,u.value,e.name],([h,l,d],[a,p,m])=>{l&&(l.instances[d]=h,p&&p!==l&&h&&h===a&&(l.leaveGuards.size||(l.leaveGuards=p.leaveGuards),l.updateGuards.size||(l.updateGuards=p.updateGuards))),h&&l&&(!p||!me(l,p)||!a)&&(l.enterCallbacks[d]||[]).forEach(b=>b(h))},{flush:"post"}),()=>{const h=o.value,l=e.name,d=u.value,a=d&&d.components[l];if(!a)return Xn(n.default,{Component:a,route:h});const p=d.props[l],m=p?p===!0?h.params:typeof p=="function"?p(h):p:null,b=S=>{S.component.isUnmounted&&(d.instances[l]=null)},y=f.h(a,F({},m,t,{onVnodeUnmounted:b,ref:c}));if(ue&&y.ref){const S={depth:s.value,name:d.name,path:d.path,meta:d.meta};(oe(y.ref)?y.ref.map(v=>v.i):[y.ref.i]).forEach(v=>{v.__vrv_devtools=S})}return Xn(n.default,{Component:y,route:h})||y}}});function Xn(e,t){if(!e)return null;const n=e(t);return n.length===1?n[0]:n}const Tt=Ti;function Ue(e,t){const n=F({},e,{matched:e.matched.map(r=>Ui(r,["instances","children","aliasOf"]))});return{_custom:{type:null,readOnly:!0,display:e.fullPath,tooltip:t,value:n}}}function Ze(e){return{_custom:{display:e}}}let Ni=0;function Ii(e,t,n){if(t.__hasDevtools)return;t.__hasDevtools=!0;const r=Ni++;Bo({id:"org.vuejs.router"+(r?"."+r:""),label:"Vue Router",packageName:"vue-router",homepage:"https://router.vuejs.org",logo:"https://router.vuejs.org/logo.png",componentStateTypes:["Routing"],app:e},o=>{typeof o.now!="function"&&console.warn("[Vue Router]: You seem to be using an outdated version of Vue Devtools. Are you still using the Beta release instead of the stable one? You can find the links at https://devtools.vuejs.org/guide/installation.html."),o.on.inspectComponent((l,d)=>{l.instanceData&&l.instanceData.state.push({type:"Routing",key:"$route",editable:!1,value:Ue(t.currentRoute.value,"Current Route")})}),o.on.visitComponentTree(({treeNode:l,componentInstance:d})=>{if(d.__vrv_devtools){const a=d.__vrv_devtools;l.tags.push({label:(a.name?`${a.name.toString()}: `:"")+a.path,textColor:0,tooltip:"This component is rendered by <router-view>",backgroundColor:zn})}oe(d.__vrl_devtools)&&(d.__devtoolsApi=o,d.__vrl_devtools.forEach(a=>{let p=Kn,m="";a.isExactActive?(p=Jn,m="This is exactly active"):a.isActive&&(p=Wn,m="This link is active"),l.tags.push({label:a.route.path,textColor:0,tooltip:m,backgroundColor:p})}))}),f.watch(t.currentRoute,()=>{c(),o.notifyComponentUpdate(),o.sendInspectorTree(u),o.sendInspectorState(u)});const i="router:navigations:"+r;o.addTimelineLayer({id:i,label:`Router${r?" "+r:""} Navigations`,color:4237508}),t.onError((l,d)=>{o.addTimelineEvent({layerId:i,event:{title:"Error during Navigation",subtitle:d.fullPath,logType:"error",time:o.now(),data:{error:l},groupId:d.meta.__navigationId}})});let s=0;t.beforeEach((l,d)=>{const a={guard:Ze("beforeEach"),from:Ue(d,"Current Location during this navigation"),to:Ue(l,"Target location")};Object.defineProperty(l.meta,"__navigationId",{value:s++}),o.addTimelineEvent({layerId:i,event:{time:o.now(),title:"Start of navigation",subtitle:l.fullPath,data:a,groupId:l.meta.__navigationId}})}),t.afterEach((l,d,a)=>{const p={guard:Ze("afterEach")};a?(p.failure={_custom:{type:Error,readOnly:!0,display:a?a.message:"",tooltip:"Navigation Failure",value:a}},p.status=Ze("❌")):p.status=Ze("✅"),p.from=Ue(d,"Current Location during this navigation"),p.to=Ue(l,"Target location"),o.addTimelineEvent({layerId:i,event:{title:"End of navigation",subtitle:l.fullPath,time:o.now(),data:p,logType:a?"warning":"default",groupId:l.meta.__navigationId}})});const u="router-inspector:"+r;o.addInspector({id:u,label:"Routes"+(r?" "+r:""),icon:"book",treeFilterPlaceholder:"Search routes"});function c(){if(!h)return;const l=h;let d=n.getRoutes().filter(a=>!a.parent);d.forEach(Yn),l.filter&&(d=d.filter(a=>Nt(a,l.filter.toLowerCase()))),d.forEach(a=>Zn(a,t.currentRoute.value)),l.rootNodes=d.map(Qn)}let h;o.on.getInspectorTree(l=>{h=l,l.app===e&&l.inspectorId===u&&c()}),o.on.getInspectorState(l=>{if(l.app===e&&l.inspectorId===u){const a=n.getRoutes().find(p=>p.record.__vd_id===l.nodeId);a&&(l.state={options:Ai(a)})}}),o.sendInspectorTree(u),o.sendInspectorState(u)})}function Hi(e){return e.optional?e.repeatable?"*":"?":e.repeatable?"+":""}function Ai(e){const{record:t}=e,n=[{editable:!1,key:"path",value:t.path}];return t.name!=null&&n.push({editable:!1,key:"name",value:t.name}),n.push({editable:!1,key:"regexp",value:e.re}),e.keys.length&&n.push({editable:!1,key:"keys",value:{_custom:{type:null,readOnly:!0,display:e.keys.map(r=>`${r.name}${Hi(r)}`).join(" "),tooltip:"Param keys",value:e.keys}}}),t.redirect!=null&&n.push({editable:!1,key:"redirect",value:t.redirect}),e.alias.length&&n.push({editable:!1,key:"aliases",value:e.alias.map(r=>r.record.path)}),Object.keys(e.record.meta).length&&n.push({editable:!1,key:"meta",value:e.record.meta}),n.push({key:"score",editable:!1,value:{_custom:{type:null,readOnly:!0,display:e.score.map(r=>r.join(", ")).join(" | "),tooltip:"Score used to sort routes",value:e.score}}}),n}const zn=15485081,Wn=2450411,Jn=8702998,Bi=2282478,Kn=16486972,Li=6710886;function Qn(e){const t=[],{record:n}=e;n.name!=null&&t.push({label:String(n.name),textColor:0,backgroundColor:Bi}),n.aliasOf&&t.push({label:"alias",textColor:0,backgroundColor:Kn}),e.__vd_match&&t.push({label:"matches",textColor:0,backgroundColor:zn}),e.__vd_exactActive&&t.push({label:"exact",textColor:0,backgroundColor:Jn}),e.__vd_active&&t.push({label:"active",textColor:0,backgroundColor:Wn}),n.redirect&&t.push({label:typeof n.redirect=="string"?`redirect: ${n.redirect}`:"redirects",textColor:16777215,backgroundColor:Li});let r=n.__vd_id;return r==null&&(r=String(Mi++),n.__vd_id=r),{id:r,label:n.path,tags:t,children:e.children.map(Qn)}}let Mi=0;const Di=/^\/(.*)\/([a-z]*)$/;function Zn(e,t){const n=t.matched.length&&me(t.matched[t.matched.length-1],e.record);e.__vd_exactActive=e.__vd_active=n,n||(e.__vd_active=t.matched.some(r=>me(r,e.record))),e.children.forEach(r=>Zn(r,t))}function Yn(e){e.__vd_match=!1,e.children.forEach(Yn)}function Nt(e,t){const n=String(e.re).match(Di);if(e.__vd_match=!1,!n||n.length<3)return!1;if(new RegExp(n[1].replace(/\$$/,""),n[2]).test(t))return e.children.forEach(s=>Nt(s,t)),e.record.path!=="/"||t==="/"?(e.__vd_match=e.re.test(t),!0):!1;const o=e.record.path.toLowerCase(),i=Le(o);return!t.startsWith("/")&&(i.includes(t)||o.includes(t))||i.startsWith(t)||o.startsWith(t)||e.record.name&&String(e.record.name).includes(t)?!0:e.children.some(s=>Nt(s,t))}function Ui(e,t){const n={};for(const r in e)t.includes(r)||(n[r]=e[r]);return n}function er(e){const t=In(e.routes,e),n=e.parseQuery||Gn,r=e.stringifyQuery||Rt,o=e.history,i=De(),s=De(),u=De(),c=f.shallowRef(ce);let h=ce;ue&&e.scrollBehavior&&"scrollRestoration"in history&&(history.scrollRestoration="manual");const l=yt.bind(null,E=>""+E),d=yt.bind(null,Si),a=yt.bind(null,Le);function p(E,w){let R,I;return wn(E)?(R=t.getRecordMatcher(E),I=w):I=E,t.addRoute(I,R)}function m(E){const w=t.getRecordMatcher(E);w&&t.removeRoute(w)}function b(){return t.getRoutes().map(E=>E.record)}function y(E){return!!t.getRecordMatcher(E)}function S(E,w){if(w=F({},w||c.value),typeof E=="string"){const L=Et(n,E,w.path),Q=t.resolve({path:L.path},w),ze=o.createHref(L.fullPath);return F(L,Q,{params:a(Q.params),hash:Le(L.hash),redirectedFrom:void 0,href:ze})}let R;if("path"in E)R=F({},E,{path:Et(n,E.path,w.path).path});else{const L=F({},E.params);for(const Q in L)L[Q]==null&&delete L[Q];R=F({},E,{params:d(L)}),w.params=d(w.params)}const I=t.resolve(R,w),X=E.hash||"";I.params=l(a(I.params));const K=Do(r,F({},E,{hash:yi(X),path:I.path})),k=o.createHref(K);return F({fullPath:K,hash:X,query:r===Rt?vi(E.query):E.query||{}},I,{redirectedFrom:void 0,href:k})}function g(E){return typeof E=="string"?Et(n,E,c.value.path):F({},E)}function v(E,w){if(h!==E)return Re(8,{from:w,to:E})}function P(E){return O(E)}function _(E){return P(F(g(E),{replace:!0}))}function x(E){const w=E.matched[E.matched.length-1];if(w&&w.redirect){const{redirect:R}=w;let I=typeof R=="function"?R(E):R;return typeof I=="string"&&(I=I.includes("?")||I.includes("#")?I=g(I):{path:I},I.params={}),F({query:E.query,hash:E.hash,params:"path"in I?{}:E.params},I)}}function O(E,w){const R=h=S(E),I=c.value,X=E.state,K=E.force,k=E.replace===!0,L=x(R);if(L)return O(F(g(L),{state:typeof L=="object"?F({},X,L.state):X,force:K,replace:k}),w||R);const Q=R;Q.redirectedFrom=w;let ze;return!K&&Uo(r,I,R)&&(ze=Re(16,{to:Q,from:I}),Ne(I,I,!0,!1)),(ze?Promise.resolve(ze):C(Q,I)).catch(re=>le(re)?le(re,2)?re:ie(re):ve(re,Q,I)).then(re=>{if(re){if(le(re,2))return O(F({replace:k},g(re.to),{state:typeof re.to=="object"?F({},X,re.to.state):X,force:K}),w||Q)}else re=B(Q,I,!0,k,X);return N(Q,I,re),re})}function H(E,w){const R=v(E,w);return R?Promise.reject(R):Promise.resolve()}function D(E){const w=Ae.values().next().value;return w&&typeof w.runWithContext=="function"?w.runWithContext(E):E()}function C(E,w){let R;const[I,X,K]=ki(E,w);R=wt(I.reverse(),"beforeRouteLeave",E,w);for(const L of I)L.leaveGuards.forEach(Q=>{R.push(ge(Q,E,w))});const k=H.bind(null,E,w);return R.push(k),_e(R).then(()=>{R=[];for(const L of i.list())R.push(ge(L,E,w));return R.push(k),_e(R)}).then(()=>{R=wt(X,"beforeRouteUpdate",E,w);for(const L of X)L.updateGuards.forEach(Q=>{R.push(ge(Q,E,w))});return R.push(k),_e(R)}).then(()=>{R=[];for(const L of K)if(L.beforeEnter)if(oe(L.beforeEnter))for(const Q of L.beforeEnter)R.push(ge(Q,E,w));else R.push(ge(L.beforeEnter,E,w));return R.push(k),_e(R)}).then(()=>(E.matched.forEach(L=>L.enterCallbacks={}),R=wt(K,"beforeRouteEnter",E,w),R.push(k),_e(R))).then(()=>{R=[];for(const L of s.list())R.push(ge(L,E,w));return R.push(k),_e(R)}).catch(L=>le(L,8)?L:Promise.reject(L))}function N(E,w,R){u.list().forEach(I=>D(()=>I(E,w,R)))}function B(E,w,R,I,X){const K=v(E,w);if(K)return K;const k=w===ce,L=ue?history.state:{};R&&(I||k?o.replace(E.fullPath,F({scroll:k&&L&&L.scroll},X)):o.push(E.fullPath,X)),c.value=E,Ne(E,w,R,k),ie()}let T;function A(){T||(T=o.listen((E,w,R)=>{if(!Xe.listening)return;const I=S(E),X=x(I);if(X){O(F(X,{replace:!0}),I).catch(Be);return}h=I;const K=c.value;ue&&Vo(vn(K.fullPath,R.delta),We()),C(I,K).catch(k=>le(k,12)?k:le(k,2)?(O(k.to,I).then(L=>{le(L,20)&&!R.delta&&R.type===Ce.pop&&o.go(-1,!1)}).catch(Be),Promise.reject()):(R.delta&&o.go(-R.delta,!1),ve(k,I,K))).then(k=>{k=k||B(I,K,!1),k&&(R.delta&&!le(k,8)?o.go(-R.delta,!1):R.type===Ce.pop&&le(k,20)&&o.go(-1,!1)),N(I,K,k)}).catch(Be)}))}let W=De(),pe=De(),se;function ve(E,w,R){ie(E);const I=pe.list();return I.length?I.forEach(X=>X(E,w,R)):console.error(E),Promise.reject(E)}function ee(){return se&&c.value!==ce?Promise.resolve():new Promise((E,w)=>{W.add([E,w])})}function ie(E){return se||(se=!E,A(),W.list().forEach(([w,R])=>E?R(E):w()),W.reset()),E}function Ne(E,w,R,I){const{scrollBehavior:X}=e;if(!ue||!X)return Promise.resolve();const K=!R&&qo(vn(E.fullPath,0))||(I||!R)&&history.state&&history.state.scroll||null;return f.nextTick().then(()=>X(E,w,K)).then(k=>k&&$o(k)).catch(k=>ve(k,E,w))}const Ie=E=>o.go(E);let He;const Ae=new Set,Xe={currentRoute:c,listening:!0,addRoute:p,removeRoute:m,hasRoute:y,getRoutes:b,resolve:S,options:e,push:P,replace:_,go:Ie,back:()=>Ie(-1),forward:()=>Ie(1),beforeEach:i.add,beforeResolve:s.add,afterEach:u.add,onError:pe.add,isReady:ee,install(E){const w=this;E.component("RouterLink",$n),E.component("RouterView",Tt),E.config.globalProperties.$router=w,Object.defineProperty(E.config.globalProperties,"$route",{enumerable:!0,get:()=>f.unref(c)}),ue&&!He&&c.value===ce&&(He=!0,P(o.location).catch(X=>{}));const R={};for(const X in ce)Object.defineProperty(R,X,{get:()=>c.value[X],enumerable:!0});E.provide(Me,w),E.provide(Ke,f.shallowReactive(R)),E.provide(Qe,c);const I=E.unmount;Ae.add(E),E.unmount=function(){Ae.delete(E),Ae.size<1&&(h=ce,T&&T(),T=null,c.value=ce,He=!1,se=!1),I()},ue&&Ii(E,w,t)}};function _e(E){return E.reduce((w,R)=>w.then(()=>D(R)),Promise.resolve())}return Xe}function ki(e,t){const n=[],r=[],o=[],i=Math.max(t.matched.length,e.matched.length);for(let s=0;s<i;s++){const u=t.matched[s];u&&(e.matched.find(h=>me(h,u))?r.push(u):n.push(u));const c=e.matched[s];c&&(t.matched.find(h=>me(h,c))||o.push(c))}return[n,r,o]}function ji(){return f.inject(Me)}function Gi(){return f.inject(Ke)}const Fi=Object.freeze(Object.defineProperty({__proto__:null,get NavigationFailureType(){return vt},RouterLink:$n,RouterView:Tt,START_LOCATION:ce,createMemoryHistory:Pn,createRouter:er,createRouterMatcher:In,createWebHashHistory:Jo,createWebHistory:Rn,isNavigationFailure:le,loadRouteLocation:Pi,matchedRouteKey:Je,onBeforeRouteLeave:xi,onBeforeRouteUpdate:Ci,parseQuery:Gn,routeLocationKey:Ke,routerKey:Me,routerViewLocationKey:Qe,stringifyQuery:Rt,useLink:Ot,useRoute:Gi,useRouter:ji,viewDepthKey:Pt},Symbol.toStringTag,{value:"Module"}));var It=function(e,t){return It=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,r){n.__proto__=r}||function(n,r){for(var o in r)Object.prototype.hasOwnProperty.call(r,o)&&(n[o]=r[o])},It(e,t)};function Ye(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");It(e,t);function n(){this.constructor=e}e.prototype=t===null?Object.create(t):(n.prototype=t.prototype,new n)}var j=function(){return j=Object.assign||function(t){for(var n,r=1,o=arguments.length;r<o;r++){n=arguments[r];for(var i in n)Object.prototype.hasOwnProperty.call(n,i)&&(t[i]=n[i])}return t},j.apply(this,arguments)};function $i(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,r=Object.getOwnPropertySymbols(e);o<r.length;o++)t.indexOf(r[o])<0&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]]);return n}function Ht(e,t,n){if(n||arguments.length===2)for(var r=0,o=t.length,i;r<o;r++)(i||!(r in t))&&(i||(i=Array.prototype.slice.call(t,0,r)),i[r]=t[r]);return e.concat(i||Array.prototype.slice.call(t))}typeof SuppressedError=="function"&&SuppressedError;var M;(function(e){e[e.EXPECT_ARGUMENT_CLOSING_BRACE=1]="EXPECT_ARGUMENT_CLOSING_BRACE",e[e.EMPTY_ARGUMENT=2]="EMPTY_ARGUMENT",e[e.MALFORMED_ARGUMENT=3]="MALFORMED_ARGUMENT",e[e.EXPECT_ARGUMENT_TYPE=4]="EXPECT_ARGUMENT_TYPE",e[e.INVALID_ARGUMENT_TYPE=5]="INVALID_ARGUMENT_TYPE",e[e.EXPECT_ARGUMENT_STYLE=6]="EXPECT_ARGUMENT_STYLE",e[e.INVALID_NUMBER_SKELETON=7]="INVALID_NUMBER_SKELETON",e[e.INVALID_DATE_TIME_SKELETON=8]="INVALID_DATE_TIME_SKELETON",e[e.EXPECT_NUMBER_SKELETON=9]="EXPECT_NUMBER_SKELETON",e[e.EXPECT_DATE_TIME_SKELETON=10]="EXPECT_DATE_TIME_SKELETON",e[e.UNCLOSED_QUOTE_IN_ARGUMENT_STYLE=11]="UNCLOSED_QUOTE_IN_ARGUMENT_STYLE",e[e.EXPECT_SELECT_ARGUMENT_OPTIONS=12]="EXPECT_SELECT_ARGUMENT_OPTIONS",e[e.EXPECT_PLURAL_ARGUMENT_OFFSET_VALUE=13]="EXPECT_PLURAL_ARGUMENT_OFFSET_VALUE",e[e.INVALID_PLURAL_ARGUMENT_OFFSET_VALUE=14]="INVALID_PLURAL_ARGUMENT_OFFSET_VALUE",e[e.EXPECT_SELECT_ARGUMENT_SELECTOR=15]="EXPECT_SELECT_ARGUMENT_SELECTOR",e[e.EXPECT_PLURAL_ARGUMENT_SELECTOR=16]="EXPECT_PLURAL_ARGUMENT_SELECTOR",e[e.EXPECT_SELECT_ARGUMENT_SELECTOR_FRAGMENT=17]="EXPECT_SELECT_ARGUMENT_SELECTOR_FRAGMENT",e[e.EXPECT_PLURAL_ARGUMENT_SELECTOR_FRAGMENT=18]="EXPECT_PLURAL_ARGUMENT_SELECTOR_FRAGMENT",e[e.INVALID_PLURAL_ARGUMENT_SELECTOR=19]="INVALID_PLURAL_ARGUMENT_SELECTOR",e[e.DUPLICATE_PLURAL_ARGUMENT_SELECTOR=20]="DUPLICATE_PLURAL_ARGUMENT_SELECTOR",e[e.DUPLICATE_SELECT_ARGUMENT_SELECTOR=21]="DUPLICATE_SELECT_ARGUMENT_SELECTOR",e[e.MISSING_OTHER_CLAUSE=22]="MISSING_OTHER_CLAUSE",e[e.INVALID_TAG=23]="INVALID_TAG",e[e.INVALID_TAG_NAME=25]="INVALID_TAG_NAME",e[e.UNMATCHED_CLOSING_TAG=26]="UNMATCHED_CLOSING_TAG",e[e.UNCLOSED_TAG=27]="UNCLOSED_TAG"})(M||(M={}));var z;(function(e){e[e.literal=0]="literal",e[e.argument=1]="argument",e[e.number=2]="number",e[e.date=3]="date",e[e.time=4]="time",e[e.select=5]="select",e[e.plural=6]="plural",e[e.pound=7]="pound",e[e.tag=8]="tag"})(z||(z={}));var Pe;(function(e){e[e.number=0]="number",e[e.dateTime=1]="dateTime"})(Pe||(Pe={}));function tr(e){return e.type===z.literal}function Vi(e){return e.type===z.argument}function nr(e){return e.type===z.number}function rr(e){return e.type===z.date}function or(e){return e.type===z.time}function ir(e){return e.type===z.select}function sr(e){return e.type===z.plural}function qi(e){return e.type===z.pound}function ar(e){return e.type===z.tag}function lr(e){return!!(e&&typeof e=="object"&&e.type===Pe.number)}function At(e){return!!(e&&typeof e=="object"&&e.type===Pe.dateTime)}var ur=/[ \xA0\u1680\u2000-\u200A\u202F\u205F\u3000]/,Xi=/(?:[Eec]{1,6}|G{1,5}|[Qq]{1,5}|(?:[yYur]+|U{1,5})|[ML]{1,5}|d{1,2}|D{1,3}|F{1}|[abB]{1,5}|[hkHK]{1,2}|w{1,2}|W{1}|m{1,2}|s{1,2}|[zZOvVxX]{1,4})(?=([^']*'[^']*')*[^']*$)/g;function zi(e){var t={};return e.replace(Xi,function(n){var r=n.length;switch(n[0]){case"G":t.era=r===4?"long":r===5?"narrow":"short";break;case"y":t.year=r===2?"2-digit":"numeric";break;case"Y":case"u":case"U":case"r":throw new RangeError("`Y/u/U/r` (year) patterns are not supported, use `y` instead");case"q":case"Q":throw new RangeError("`q/Q` (quarter) patterns are not supported");case"M":case"L":t.month=["numeric","2-digit","short","long","narrow"][r-1];break;case"w":case"W":throw new RangeError("`w/W` (week) patterns are not supported");case"d":t.day=["numeric","2-digit"][r-1];break;case"D":case"F":case"g":throw new RangeError("`D/F/g` (day) patterns are not supported, use `d` instead");case"E":t.weekday=r===4?"short":r===5?"narrow":"short";break;case"e":if(r<4)throw new RangeError("`e..eee` (weekday) patterns are not supported");t.weekday=["short","long","narrow","short"][r-4];break;case"c":if(r<4)throw new RangeError("`c..ccc` (weekday) patterns are not supported");t.weekday=["short","long","narrow","short"][r-4];break;case"a":t.hour12=!0;break;case"b":case"B":throw new RangeError("`b/B` (period) patterns are not supported, use `a` instead");case"h":t.hourCycle="h12",t.hour=["numeric","2-digit"][r-1];break;case"H":t.hourCycle="h23",t.hour=["numeric","2-digit"][r-1];break;case"K":t.hourCycle="h11",t.hour=["numeric","2-digit"][r-1];break;case"k":t.hourCycle="h24",t.hour=["numeric","2-digit"][r-1];break;case"j":case"J":case"C":throw new RangeError("`j/J/C` (hour) patterns are not supported, use `h/H/K/k` instead");case"m":t.minute=["numeric","2-digit"][r-1];break;case"s":t.second=["numeric","2-digit"][r-1];break;case"S":case"A":throw new RangeError("`S/A` (second) patterns are not supported, use `s` instead");case"z":t.timeZoneName=r<4?"short":"long";break;case"Z":case"O":case"v":case"V":case"X":case"x":throw new RangeError("`Z/O/v/V/X/x` (timeZone) patterns are not supported, use `z` instead")}return""}),t}var Wi=/[\t-\r \x85\u200E\u200F\u2028\u2029]/i;function Ji(e){if(e.length===0)throw new Error("Number skeleton cannot be empty");for(var t=e.split(Wi).filter(function(a){return a.length>0}),n=[],r=0,o=t;r<o.length;r++){var i=o[r],s=i.split("/");if(s.length===0)throw new Error("Invalid number skeleton");for(var u=s[0],c=s.slice(1),h=0,l=c;h<l.length;h++){var d=l[h];if(d.length===0)throw new Error("Invalid number skeleton")}n.push({stem:u,options:c})}return n}function Ki(e){return e.replace(/^(.*?)-/,"")}var cr=/^\.(?:(0+)(\*)?|(#+)|(0+)(#+))$/g,fr=/^(@+)?(\+|#+)?[rs]?$/g,Qi=/(\*)(0+)|(#+)(0+)|(0+)/g,hr=/^(0+)$/;function dr(e){var t={};return e[e.length-1]==="r"?t.roundingPriority="morePrecision":e[e.length-1]==="s"&&(t.roundingPriority="lessPrecision"),e.replace(fr,function(n,r,o){return typeof o!="string"?(t.minimumSignificantDigits=r.length,t.maximumSignificantDigits=r.length):o==="+"?t.minimumSignificantDigits=r.length:r[0]==="#"?t.maximumSignificantDigits=r.length:(t.minimumSignificantDigits=r.length,t.maximumSignificantDigits=r.length+(typeof o=="string"?o.length:0)),""}),t}function pr(e){switch(e){case"sign-auto":return{signDisplay:"auto"};case"sign-accounting":case"()":return{currencySign:"accounting"};case"sign-always":case"+!":return{signDisplay:"always"};case"sign-accounting-always":case"()!":return{signDisplay:"always",currencySign:"accounting"};case"sign-except-zero":case"+?":return{signDisplay:"exceptZero"};case"sign-accounting-except-zero":case"()?":return{signDisplay:"exceptZero",currencySign:"accounting"};case"sign-never":case"+_":return{signDisplay:"never"}}}function Zi(e){var t;if(e[0]==="E"&&e[1]==="E"?(t={notation:"engineering"},e=e.slice(2)):e[0]==="E"&&(t={notation:"scientific"},e=e.slice(1)),t){var n=e.slice(0,2);if(n==="+!"?(t.signDisplay="always",e=e.slice(2)):n==="+?"&&(t.signDisplay="exceptZero",e=e.slice(2)),!hr.test(e))throw new Error("Malformed concise eng/scientific notation");t.minimumIntegerDigits=e.length}return t}function mr(e){var t={},n=pr(e);return n||t}function Yi(e){for(var t={},n=0,r=e;n<r.length;n++){var o=r[n];switch(o.stem){case"percent":case"%":t.style="percent";continue;case"%x100":t.style="percent",t.scale=100;continue;case"currency":t.style="currency",t.currency=o.options[0];continue;case"group-off":case",_":t.useGrouping=!1;continue;case"precision-integer":case".":t.maximumFractionDigits=0;continue;case"measure-unit":case"unit":t.style="unit",t.unit=Ki(o.options[0]);continue;case"compact-short":case"K":t.notation="compact",t.compactDisplay="short";continue;case"compact-long":case"KK":t.notation="compact",t.compactDisplay="long";continue;case"scientific":t=j(j(j({},t),{notation:"scientific"}),o.options.reduce(function(c,h){return j(j({},c),mr(h))},{}));continue;case"engineering":t=j(j(j({},t),{notation:"engineering"}),o.options.reduce(function(c,h){return j(j({},c),mr(h))},{}));continue;case"notation-simple":t.notation="standard";continue;case"unit-width-narrow":t.currencyDisplay="narrowSymbol",t.unitDisplay="narrow";continue;case"unit-width-short":t.currencyDisplay="code",t.unitDisplay="short";continue;case"unit-width-full-name":t.currencyDisplay="name",t.unitDisplay="long";continue;case"unit-width-iso-code":t.currencyDisplay="symbol";continue;case"scale":t.scale=parseFloat(o.options[0]);continue;case"integer-width":if(o.options.length>1)throw new RangeError("integer-width stems only accept a single optional option");o.options[0].replace(Qi,function(c,h,l,d,a,p){if(h)t.minimumIntegerDigits=l.length;else{if(d&&a)throw new Error("We currently do not support maximum integer digits");if(p)throw new Error("We currently do not support exact integer digits")}return""});continue}if(hr.test(o.stem)){t.minimumIntegerDigits=o.stem.length;continue}if(cr.test(o.stem)){if(o.options.length>1)throw new RangeError("Fraction-precision stems only accept a single optional option");o.stem.replace(cr,function(c,h,l,d,a,p){return l==="*"?t.minimumFractionDigits=h.length:d&&d[0]==="#"?t.maximumFractionDigits=d.length:a&&p?(t.minimumFractionDigits=a.length,t.maximumFractionDigits=a.length+p.length):(t.minimumFractionDigits=h.length,t.maximumFractionDigits=h.length),""});var i=o.options[0];i==="w"?t=j(j({},t),{trailingZeroDisplay:"stripIfInteger"}):i&&(t=j(j({},t),dr(i)));continue}if(fr.test(o.stem)){t=j(j({},t),dr(o.stem));continue}var s=pr(o.stem);s&&(t=j(j({},t),s));var u=Zi(o.stem);u&&(t=j(j({},t),u))}return t}var et={"001":["H","h"],AC:["H","h","hb","hB"],AD:["H","hB"],AE:["h","hB","hb","H"],AF:["H","hb","hB","h"],AG:["h","hb","H","hB"],AI:["H","h","hb","hB"],AL:["h","H","hB"],AM:["H","hB"],AO:["H","hB"],AR:["H","h","hB","hb"],AS:["h","H"],AT:["H","hB"],AU:["h","hb","H","hB"],AW:["H","hB"],AX:["H"],AZ:["H","hB","h"],BA:["H","hB","h"],BB:["h","hb","H","hB"],BD:["h","hB","H"],BE:["H","hB"],BF:["H","hB"],BG:["H","hB","h"],BH:["h","hB","hb","H"],BJ:["H","hB"],BL:["H","hB"],BM:["h","hb","H","hB"],BN:["hb","hB","h","H"],BO:["H","hB","h","hb"],BQ:["H"],BR:["H","hB"],BS:["h","hb","H","hB"],BT:["h","H"],BW:["H","h","hb","hB"],BZ:["H","h","hb","hB"],CA:["h","hb","H","hB"],CC:["H","h","hb","hB"],CD:["hB","H"],CF:["H","h","hB"],CG:["H","hB"],CH:["H","hB","h"],CI:["H","hB"],CK:["H","h","hb","hB"],CL:["H","h","hB","hb"],CM:["H","h","hB"],CN:["H","hB","hb","h"],CO:["h","H","hB","hb"],CP:["H"],CR:["H","h","hB","hb"],CU:["H","h","hB","hb"],CV:["H","hB"],CX:["H","h","hb","hB"],CY:["h","H","hb","hB"],CZ:["H"],DE:["H","hB"],DG:["H","h","hb","hB"],DJ:["h","H"],DK:["H"],DM:["h","hb","H","hB"],DO:["h","H","hB","hb"],DZ:["h","hB","hb","H"],EA:["H","h","hB","hb"],EC:["H","hB","h","hb"],EE:["H","hB"],EG:["h","hB","hb","H"],EH:["h","hB","hb","H"],ER:["h","H"],ES:["H","hB","h","hb"],ET:["hB","hb","h","H"],FI:["H"],FJ:["h","hb","H","hB"],FK:["H","h","hb","hB"],FM:["h","hb","H","hB"],FR:["H","hB"],GA:["H","hB"],GB:["H","h","hb","hB"],GD:["h","hb","H","hB"],GE:["H","hB","h"],GF:["H","hB"],GG:["H","h","hb","hB"],GH:["h","H"],GI:["H","h","hb","hB"],GM:["h","hb","H","hB"],GN:["H","hB"],GP:["H","hB"],GQ:["H","hB","h","hb"],GR:["h","H","hb","hB"],GT:["H","h","hB","hb"],GU:["h","hb","H","hB"],GW:["H","hB"],GY:["h","hb","H","hB"],HK:["h","hB","hb","H"],HN:["H","h","hB","hb"],HR:["H","hB"],IC:["H","h","hB","hb"],ID:["H"],IE:["H","h","hb","hB"],IL:["H","hB"],IM:["H","h","hb","hB"],IN:["h","H"],IO:["H","h","hb","hB"],IQ:["h","hB","hb","H"],IR:["hB","H"],IS:["H"],IT:["H","hB"],JE:["H","h","hb","hB"],JM:["h","hb","H","hB"],JO:["h","hB","hb","H"],JP:["H","h","K"],KE:["hB","hb","H","h"],KG:["H","h","hB","hb"],KH:["hB","h","H","hb"],KI:["h","hb","H","hB"],KM:["H","h","hB","hb"],KN:["h","hb","H","hB"],KP:["h","H","hB","hb"],KR:["h","H","hB","hb"],KW:["h","hB","hb","H"],KY:["h","hb","H","hB"],KZ:["H","hB"],LA:["H","hb","hB","h"],LB:["h","hB","hb","H"],LC:["h","hb","H","hB"],LI:["H","hB","h"],LK:["H","h","hB","hb"],LR:["h","hb","H","hB"],LS:["h","H"],LT:["H","h","hb","hB"],LU:["H","h","hB"],LV:["H","hB","hb","h"],LY:["h","hB","hb","H"],MA:["H","h","hB","hb"],MC:["H","hB"],MD:["H","hB"],ME:["H","hB","h"],MF:["H","hB"],MH:["h","hb","H","hB"],MK:["H","h","hb","hB"],ML:["H"],MM:["hB","hb","H","h"],MN:["H","h","hb","hB"],MO:["h","hB","hb","H"],MP:["h","hb","H","hB"],MQ:["H","hB"],MR:["h","hB","hb","H"],MS:["H","h","hb","hB"],MW:["h","hb","H","hB"],MX:["H","h","hB","hb"],MY:["hb","hB","h","H"],MZ:["H","hB"],NA:["h","H","hB","hb"],NC:["H","hB"],NE:["H"],NF:["H","h","hb","hB"],NG:["H","h","hb","hB"],NI:["H","h","hB","hb"],NL:["H","hB"],NP:["H","h","hB"],NR:["H","h","hb","hB"],NU:["H","h","hb","hB"],NZ:["h","hb","H","hB"],OM:["h","hB","hb","H"],PA:["h","H","hB","hb"],PE:["H","hB","h","hb"],PF:["H","h","hB"],PG:["h","H"],PH:["h","hB","hb","H"],PK:["h","hB","H"],PM:["H","hB"],PN:["H","h","hb","hB"],PR:["h","H","hB","hb"],PS:["h","hB","hb","H"],PT:["H","hB"],PW:["h","H"],PY:["H","h","hB","hb"],QA:["h","hB","hb","H"],RE:["H","hB"],RO:["H","hB"],RS:["H","hB","h"],RU:["H"],SA:["h","hB","hb","H"],SB:["h","hb","H","hB"],SC:["H","h","hB"],SD:["h","hB","hb","H"],SE:["H"],SG:["h","hb","H","hB"],SH:["H","h","hb","hB"],SI:["H","hB"],SJ:["H"],SK:["H"],SL:["h","hb","H","hB"],SM:["H","h","hB"],SN:["H","h","hB"],SO:["h","H"],SR:["H","hB"],SS:["h","hb","H","hB"],ST:["H","hB"],SV:["H","h","hB","hb"],SX:["H","h","hb","hB"],SY:["h","hB","hb","H"],SZ:["h","hb","H","hB"],TA:["H","h","hb","hB"],TC:["h","hb","H","hB"],TD:["h","H","hB"],TF:["H","h","hB"],TG:["H","hB"],TL:["H","hB","hb","h"],TN:["h","hB","hb","H"],TO:["h","H"],TR:["H","hB"],TT:["h","hb","H","hB"],TW:["hB","hb","h","H"],TZ:["hB","hb","H","h"],UA:["H","hB","h"],UG:["hB","hb","H","h"],UM:["h","hb","H","hB"],US:["h","hb","H","hB"],UY:["H","h","hB","hb"],UZ:["H","hB","h"],VA:["H","h","hB"],VC:["h","hb","H","hB"],VE:["h","H","hB","hb"],VG:["h","hb","H","hB"],VI:["h","hb","H","hB"],VU:["h","H"],WF:["H","hB"],WS:["h","H"],XK:["H","hB","h"],YE:["h","hB","hb","H"],YT:["H","hB"],ZA:["H","h","hb","hB"],ZM:["h","hb","H","hB"],"af-ZA":["H","h","hB","hb"],"ar-001":["h","hB","hb","H"],"ca-ES":["H","h","hB"],"en-001":["h","hb","H","hB"],"es-BO":["H","h","hB","hb"],"es-BR":["H","h","hB","hb"],"es-EC":["H","h","hB","hb"],"es-ES":["H","h","hB","hb"],"es-GQ":["H","h","hB","hb"],"es-PE":["H","h","hB","hb"],"fr-CA":["H","h","hB"],"gl-ES":["H","h","hB"],"gu-IN":["hB","hb","h","H"],"hi-IN":["hB","h","H"],"it-CH":["H","h","hB"],"it-IT":["H","h","hB"],"kn-IN":["hB","h","H"],"ml-IN":["hB","h","H"],"mr-IN":["hB","hb","h","H"],"pa-IN":["hB","hb","h","H"],"ta-IN":["hB","h","hb","H"],"te-IN":["hB","h","H"],"zu-ZA":["H","hB","hb","h"]};function es(e,t){for(var n="",r=0;r<e.length;r++){var o=e.charAt(r);if(o==="j"){for(var i=0;r+1<e.length&&e.charAt(r+1)===o;)i++,r++;var s=1+(i&1),u=i<2?1:3+(i>>1),c="a",h=ts(t);for((h=="H"||h=="k")&&(u=0);u-- >0;)n+=c;for(;s-- >0;)n=h+n}else o==="J"?n+="H":n+=o}return n}function ts(e){var t=e.hourCycle;if(t===void 0&&e.hourCycles&&e.hourCycles.length&&(t=e.hourCycles[0]),t)switch(t){case"h24":return"k";case"h23":return"H";case"h12":return"h";case"h11":return"K";default:throw new Error("Invalid hourCycle")}var n=e.language,r;n!=="root"&&(r=e.maximize().region);var o=et[r||""]||et[n||""]||et["".concat(n,"-001")]||et["001"];return o[0]}var Bt,ns=new RegExp("^".concat(ur.source,"*")),rs=new RegExp("".concat(ur.source,"*$"));function U(e