@prsm/devtools 1.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,176 @@
1
+ var tf=Object.defineProperty;var nf=Object.getPrototypeOf;var sf=Reflect.get;var Vi=e=>{throw TypeError(e)};var rf=(e,t,n)=>t in e?tf(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n;var $=(e,t,n)=>rf(e,typeof t!="symbol"?t+"":t,n),Jr=(e,t,n)=>t.has(e)||Vi("Cannot "+n);var Ve=(e,t,n)=>(Jr(e,t,"read from private field"),n?n.call(e):t.get(e)),hn=(e,t,n)=>t.has(e)?Vi("Cannot add the same private member more than once"):t instanceof WeakSet?t.add(e):t.set(e,n),gt=(e,t,n,s)=>(Jr(e,t,"write to private field"),s?s.call(e,n):t.set(e,n),n),Yr=(e,t,n)=>(Jr(e,t,"access private method"),n);var qi=(e,t,n)=>sf(nf(e),n,t);(function(){const t=document.createElement("link").relList;if(t&&t.supports&&t.supports("modulepreload"))return;for(const r of document.querySelectorAll('link[rel="modulepreload"]'))s(r);new MutationObserver(r=>{for(const o of r)if(o.type==="childList")for(const i of o.addedNodes)i.tagName==="LINK"&&i.rel==="modulepreload"&&s(i)}).observe(document,{childList:!0,subtree:!0});function n(r){const o={};return r.integrity&&(o.integrity=r.integrity),r.referrerPolicy&&(o.referrerPolicy=r.referrerPolicy),r.crossOrigin==="use-credentials"?o.credentials="include":r.crossOrigin==="anonymous"?o.credentials="omit":o.credentials="same-origin",o}function s(r){if(r.ep)return;r.ep=!0;const o=n(r);fetch(r.href,o)}})();/**
2
+ * @vue/shared v3.5.30
3
+ * (c) 2018-present Yuxi (Evan) You and Vue contributors
4
+ * @license MIT
5
+ **/function ii(e){const t=Object.create(null);for(const n of e.split(","))t[n]=1;return n=>n in t}const Ce={},jn=[],Tt=()=>{},Ia=()=>!1,Rr=e=>e.charCodeAt(0)===111&&e.charCodeAt(1)===110&&(e.charCodeAt(2)>122||e.charCodeAt(2)<97),li=e=>e.startsWith("onUpdate:"),je=Object.assign,ai=(e,t)=>{const n=e.indexOf(t);n>-1&&e.splice(n,1)},of=Object.prototype.hasOwnProperty,ve=(e,t)=>of.call(e,t),Y=Array.isArray,Fn=e=>Ps(e)==="[object Map]",$r=e=>Ps(e)==="[object Set]",zi=e=>Ps(e)==="[object Date]",ne=e=>typeof e=="function",Pe=e=>typeof e=="string",Mt=e=>typeof e=="symbol",we=e=>e!==null&&typeof e=="object",Na=e=>(we(e)||ne(e))&&ne(e.then)&&ne(e.catch),Pa=Object.prototype.toString,Ps=e=>Pa.call(e),lf=e=>Ps(e).slice(8,-1),Oa=e=>Ps(e)==="[object Object]",ci=e=>Pe(e)&&e!=="NaN"&&e[0]!=="-"&&""+parseInt(e,10)===e,us=ii(",key,ref,ref_for,ref_key,onVnodeBeforeMount,onVnodeMounted,onVnodeBeforeUpdate,onVnodeUpdated,onVnodeBeforeUnmount,onVnodeUnmounted"),Ir=e=>{const t=Object.create(null);return(n=>t[n]||(t[n]=e(n)))},af=/-\w/g,Je=Ir(e=>e.replace(af,t=>t.slice(1).toUpperCase())),cf=/\B([A-Z])/g,$n=Ir(e=>e.replace(cf,"-$1").toLowerCase()),Nr=Ir(e=>e.charAt(0).toUpperCase()+e.slice(1)),Qr=Ir(e=>e?`on${Nr(e)}`:""),Ot=(e,t)=>!Object.is(e,t),Xs=(e,...t)=>{for(let n=0;n<e.length;n++)e[n](...t)},Ta=(e,t,n,s=!1)=>{Object.defineProperty(e,t,{configurable:!0,enumerable:!1,writable:s,value:n})},Pr=e=>{const t=parseFloat(e);return isNaN(t)?e:t};let Ki;const Or=()=>Ki||(Ki=typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:typeof global<"u"?global:{});function Sn(e){if(Y(e)){const t={};for(let n=0;n<e.length;n++){const s=e[n],r=Pe(s)?hf(s):Sn(s);if(r)for(const o in r)t[o]=r[o]}return t}else if(Pe(e)||we(e))return e}const uf=/;(?![^(]*\))/g,ff=/:([^]+)/,df=/\/\*[^]*?\*\//g;function hf(e){const t={};return e.replace(df,"").split(uf).forEach(n=>{if(n){const s=n.split(ff);s.length>1&&(t[s[0].trim()]=s[1].trim())}}),t}function Ae(e){let t="";if(Pe(e))t=e;else if(Y(e))for(let n=0;n<e.length;n++){const s=Ae(e[n]);s&&(t+=s+" ")}else if(we(e))for(const n in e)e[n]&&(t+=n+" ");return t.trim()}const pf="itemscope,allowfullscreen,formnovalidate,ismap,nomodule,novalidate,readonly",gf=ii(pf);function Ma(e){return!!e||e===""}function mf(e,t){if(e.length!==t.length)return!1;let n=!0;for(let s=0;n&&s<e.length;s++)n=Os(e[s],t[s]);return n}function Os(e,t){if(e===t)return!0;let n=zi(e),s=zi(t);if(n||s)return n&&s?e.getTime()===t.getTime():!1;if(n=Mt(e),s=Mt(t),n||s)return e===t;if(n=Y(e),s=Y(t),n||s)return n&&s?mf(e,t):!1;if(n=we(e),s=we(t),n||s){if(!n||!s)return!1;const r=Object.keys(e).length,o=Object.keys(t).length;if(r!==o)return!1;for(const i in e){const l=e.hasOwnProperty(i),a=t.hasOwnProperty(i);if(l&&!a||!l&&a||!Os(e[i],t[i]))return!1}}return String(e)===String(t)}function yf(e,t){return e.findIndex(n=>Os(n,t))}const La=e=>!!(e&&e.__v_isRef===!0),N=e=>Pe(e)?e:e==null?"":Y(e)||we(e)&&(e.toString===Pa||!ne(e.toString))?La(e)?N(e.value):JSON.stringify(e,Da,2):String(e),Da=(e,t)=>La(t)?Da(e,t.value):Fn(t)?{[`Map(${t.size})`]:[...t.entries()].reduce((n,[s,r],o)=>(n[Zr(s,o)+" =>"]=r,n),{})}:$r(t)?{[`Set(${t.size})`]:[...t.values()].map(n=>Zr(n))}:Mt(t)?Zr(t):we(t)&&!Y(t)&&!Oa(t)?String(t):t,Zr=(e,t="")=>{var n;return Mt(e)?`Symbol(${(n=e.description)!=null?n:t})`:e};/**
6
+ * @vue/reactivity v3.5.30
7
+ * (c) 2018-present Yuxi (Evan) You and Vue contributors
8
+ * @license MIT
9
+ **/let et;class vf{constructor(t=!1){this.detached=t,this._active=!0,this._on=0,this.effects=[],this.cleanups=[],this._isPaused=!1,this.__v_skip=!0,this.parent=et,!t&&et&&(this.index=(et.scopes||(et.scopes=[])).push(this)-1)}get active(){return this._active}pause(){if(this._active){this._isPaused=!0;let t,n;if(this.scopes)for(t=0,n=this.scopes.length;t<n;t++)this.scopes[t].pause();for(t=0,n=this.effects.length;t<n;t++)this.effects[t].pause()}}resume(){if(this._active&&this._isPaused){this._isPaused=!1;let t,n;if(this.scopes)for(t=0,n=this.scopes.length;t<n;t++)this.scopes[t].resume();for(t=0,n=this.effects.length;t<n;t++)this.effects[t].resume()}}run(t){if(this._active){const n=et;try{return et=this,t()}finally{et=n}}}on(){++this._on===1&&(this.prevScope=et,et=this)}off(){this._on>0&&--this._on===0&&(et=this.prevScope,this.prevScope=void 0)}stop(t){if(this._active){this._active=!1;let n,s;for(n=0,s=this.effects.length;n<s;n++)this.effects[n].stop();for(this.effects.length=0,n=0,s=this.cleanups.length;n<s;n++)this.cleanups[n]();if(this.cleanups.length=0,this.scopes){for(n=0,s=this.scopes.length;n<s;n++)this.scopes[n].stop(!0);this.scopes.length=0}if(!this.detached&&this.parent&&!t){const r=this.parent.scopes.pop();r&&r!==this&&(this.parent.scopes[this.index]=r,r.index=this.index)}this.parent=void 0}}}function _f(){return et}let Se;const eo=new WeakSet;class Ga{constructor(t){this.fn=t,this.deps=void 0,this.depsTail=void 0,this.flags=5,this.next=void 0,this.cleanup=void 0,this.scheduler=void 0,et&&et.active&&et.effects.push(this)}pause(){this.flags|=64}resume(){this.flags&64&&(this.flags&=-65,eo.has(this)&&(eo.delete(this),this.trigger()))}notify(){this.flags&2&&!(this.flags&32)||this.flags&8||Fa(this)}run(){if(!(this.flags&1))return this.fn();this.flags|=2,Xi(this),Ba(this);const t=Se,n=_t;Se=this,_t=!0;try{return this.fn()}finally{Ua(this),Se=t,_t=n,this.flags&=-3}}stop(){if(this.flags&1){for(let t=this.deps;t;t=t.nextDep)di(t);this.deps=this.depsTail=void 0,Xi(this),this.onStop&&this.onStop(),this.flags&=-2}}trigger(){this.flags&64?eo.add(this):this.scheduler?this.scheduler():this.runIfDirty()}runIfDirty(){Eo(this)&&this.run()}get dirty(){return Eo(this)}}let ja=0,fs,ds;function Fa(e,t=!1){if(e.flags|=8,t){e.next=ds,ds=e;return}e.next=fs,fs=e}function ui(){ja++}function fi(){if(--ja>0)return;if(ds){let t=ds;for(ds=void 0;t;){const n=t.next;t.next=void 0,t.flags&=-9,t=n}}let e;for(;fs;){let t=fs;for(fs=void 0;t;){const n=t.next;if(t.next=void 0,t.flags&=-9,t.flags&1)try{t.trigger()}catch(s){e||(e=s)}t=n}}if(e)throw e}function Ba(e){for(let t=e.deps;t;t=t.nextDep)t.version=-1,t.prevActiveLink=t.dep.activeLink,t.dep.activeLink=t}function Ua(e){let t,n=e.depsTail,s=n;for(;s;){const r=s.prevDep;s.version===-1?(s===n&&(n=r),di(s),bf(s)):t=s,s.dep.activeLink=s.prevActiveLink,s.prevActiveLink=void 0,s=r}e.deps=t,e.depsTail=n}function Eo(e){for(let t=e.deps;t;t=t.nextDep)if(t.dep.version!==t.version||t.dep.computed&&(Ha(t.dep.computed)||t.dep.version!==t.version))return!0;return!!e._dirty}function Ha(e){if(e.flags&4&&!(e.flags&16)||(e.flags&=-17,e.globalVersion===bs)||(e.globalVersion=bs,!e.isSSR&&e.flags&128&&(!e.deps&&!e._dirty||!Eo(e))))return;e.flags|=2;const t=e.dep,n=Se,s=_t;Se=e,_t=!0;try{Ba(e);const r=e.fn(e._value);(t.version===0||Ot(r,e._value))&&(e.flags|=128,e._value=r,t.version++)}catch(r){throw t.version++,r}finally{Se=n,_t=s,Ua(e),e.flags&=-3}}function di(e,t=!1){const{dep:n,prevSub:s,nextSub:r}=e;if(s&&(s.nextSub=r,e.prevSub=void 0),r&&(r.prevSub=s,e.nextSub=void 0),n.subs===e&&(n.subs=s,!s&&n.computed)){n.computed.flags&=-5;for(let o=n.computed.deps;o;o=o.nextDep)di(o,!0)}!t&&!--n.sc&&n.map&&n.map.delete(n.key)}function bf(e){const{prevDep:t,nextDep:n}=e;t&&(t.nextDep=n,e.prevDep=void 0),n&&(n.prevDep=t,e.nextDep=void 0)}let _t=!0;const Wa=[];function Jt(){Wa.push(_t),_t=!1}function Yt(){const e=Wa.pop();_t=e===void 0?!0:e}function Xi(e){const{cleanup:t}=e;if(e.cleanup=void 0,t){const n=Se;Se=void 0;try{t()}finally{Se=n}}}let bs=0;class wf{constructor(t,n){this.sub=t,this.dep=n,this.version=n.version,this.nextDep=this.prevDep=this.nextSub=this.prevSub=this.prevActiveLink=void 0}}class hi{constructor(t){this.computed=t,this.version=0,this.activeLink=void 0,this.subs=void 0,this.map=void 0,this.key=void 0,this.sc=0,this.__v_skip=!0}track(t){if(!Se||!_t||Se===this.computed)return;let n=this.activeLink;if(n===void 0||n.sub!==Se)n=this.activeLink=new wf(Se,this),Se.deps?(n.prevDep=Se.depsTail,Se.depsTail.nextDep=n,Se.depsTail=n):Se.deps=Se.depsTail=n,Va(n);else if(n.version===-1&&(n.version=this.version,n.nextDep)){const s=n.nextDep;s.prevDep=n.prevDep,n.prevDep&&(n.prevDep.nextDep=s),n.prevDep=Se.depsTail,n.nextDep=void 0,Se.depsTail.nextDep=n,Se.depsTail=n,Se.deps===n&&(Se.deps=s)}return n}trigger(t){this.version++,bs++,this.notify(t)}notify(t){ui();try{for(let n=this.subs;n;n=n.prevSub)n.sub.notify()&&n.sub.dep.notify()}finally{fi()}}}function Va(e){if(e.dep.sc++,e.sub.flags&4){const t=e.dep.computed;if(t&&!e.dep.subs){t.flags|=20;for(let s=t.deps;s;s=s.nextDep)Va(s)}const n=e.dep.subs;n!==e&&(e.prevSub=n,n&&(n.nextSub=e)),e.dep.subs=e}}const Ao=new WeakMap,En=Symbol(""),Ro=Symbol(""),ws=Symbol("");function Be(e,t,n){if(_t&&Se){let s=Ao.get(e);s||Ao.set(e,s=new Map);let r=s.get(n);r||(s.set(n,r=new hi),r.map=s,r.key=n),r.track()}}function qt(e,t,n,s,r,o){const i=Ao.get(e);if(!i){bs++;return}const l=a=>{a&&a.trigger()};if(ui(),t==="clear")i.forEach(l);else{const a=Y(e),c=a&&ci(n);if(a&&n==="length"){const u=Number(s);i.forEach((f,d)=>{(d==="length"||d===ws||!Mt(d)&&d>=u)&&l(f)})}else switch((n!==void 0||i.has(void 0))&&l(i.get(n)),c&&l(i.get(ws)),t){case"add":a?c&&l(i.get("length")):(l(i.get(En)),Fn(e)&&l(i.get(Ro)));break;case"delete":a||(l(i.get(En)),Fn(e)&&l(i.get(Ro)));break;case"set":Fn(e)&&l(i.get(En));break}}fi()}function Nn(e){const t=ye(e);return t===e?t:(Be(t,"iterate",ws),ht(e)?t:t.map(Ct))}function Tr(e){return Be(e=ye(e),"iterate",ws),e}function Nt(e,t){return Qt(e)?qn(An(e)?Ct(t):t):Ct(t)}const Cf={__proto__:null,[Symbol.iterator](){return to(this,Symbol.iterator,e=>Nt(this,e))},concat(...e){return Nn(this).concat(...e.map(t=>Y(t)?Nn(t):t))},entries(){return to(this,"entries",e=>(e[1]=Nt(this,e[1]),e))},every(e,t){return jt(this,"every",e,t,void 0,arguments)},filter(e,t){return jt(this,"filter",e,t,n=>n.map(s=>Nt(this,s)),arguments)},find(e,t){return jt(this,"find",e,t,n=>Nt(this,n),arguments)},findIndex(e,t){return jt(this,"findIndex",e,t,void 0,arguments)},findLast(e,t){return jt(this,"findLast",e,t,n=>Nt(this,n),arguments)},findLastIndex(e,t){return jt(this,"findLastIndex",e,t,void 0,arguments)},forEach(e,t){return jt(this,"forEach",e,t,void 0,arguments)},includes(...e){return no(this,"includes",e)},indexOf(...e){return no(this,"indexOf",e)},join(e){return Nn(this).join(e)},lastIndexOf(...e){return no(this,"lastIndexOf",e)},map(e,t){return jt(this,"map",e,t,void 0,arguments)},pop(){return ss(this,"pop")},push(...e){return ss(this,"push",e)},reduce(e,...t){return Ji(this,"reduce",e,t)},reduceRight(e,...t){return Ji(this,"reduceRight",e,t)},shift(){return ss(this,"shift")},some(e,t){return jt(this,"some",e,t,void 0,arguments)},splice(...e){return ss(this,"splice",e)},toReversed(){return Nn(this).toReversed()},toSorted(e){return Nn(this).toSorted(e)},toSpliced(...e){return Nn(this).toSpliced(...e)},unshift(...e){return ss(this,"unshift",e)},values(){return to(this,"values",e=>Nt(this,e))}};function to(e,t,n){const s=Tr(e),r=s[t]();return s!==e&&!ht(e)&&(r._next=r.next,r.next=()=>{const o=r._next();return o.done||(o.value=n(o.value)),o}),r}const xf=Array.prototype;function jt(e,t,n,s,r,o){const i=Tr(e),l=i!==e&&!ht(e),a=i[t];if(a!==xf[t]){const f=a.apply(e,o);return l?Ct(f):f}let c=n;i!==e&&(l?c=function(f,d){return n.call(this,Nt(e,f),d,e)}:n.length>2&&(c=function(f,d){return n.call(this,f,d,e)}));const u=a.call(i,c,s);return l&&r?r(u):u}function Ji(e,t,n,s){const r=Tr(e),o=r!==e&&!ht(e);let i=n,l=!1;r!==e&&(o?(l=s.length===0,i=function(c,u,f){return l&&(l=!1,c=Nt(e,c)),n.call(this,c,Nt(e,u),f,e)}):n.length>3&&(i=function(c,u,f){return n.call(this,c,u,f,e)}));const a=r[t](i,...s);return l?Nt(e,a):a}function no(e,t,n){const s=ye(e);Be(s,"iterate",ws);const r=s[t](...n);return(r===-1||r===!1)&&mi(n[0])?(n[0]=ye(n[0]),s[t](...n)):r}function ss(e,t,n=[]){Jt(),ui();const s=ye(e)[t].apply(e,n);return fi(),Yt(),s}const kf=ii("__proto__,__v_isRef,__isVue"),qa=new Set(Object.getOwnPropertyNames(Symbol).filter(e=>e!=="arguments"&&e!=="caller").map(e=>Symbol[e]).filter(Mt));function Sf(e){Mt(e)||(e=String(e));const t=ye(this);return Be(t,"has",e),t.hasOwnProperty(e)}class za{constructor(t=!1,n=!1){this._isReadonly=t,this._isShallow=n}get(t,n,s){if(n==="__v_skip")return t.__v_skip;const r=this._isReadonly,o=this._isShallow;if(n==="__v_isReactive")return!r;if(n==="__v_isReadonly")return r;if(n==="__v_isShallow")return o;if(n==="__v_raw")return s===(r?o?Mf:Ya:o?Ja:Xa).get(t)||Object.getPrototypeOf(t)===Object.getPrototypeOf(s)?t:void 0;const i=Y(t);if(!r){let a;if(i&&(a=Cf[n]))return a;if(n==="hasOwnProperty")return Sf}const l=Reflect.get(t,n,We(t)?t:s);if((Mt(n)?qa.has(n):kf(n))||(r||Be(t,"get",n),o))return l;if(We(l)){const a=i&&ci(n)?l:l.value;return r&&we(a)?Io(a):a}return we(l)?r?Io(l):Yn(l):l}}class Ka extends za{constructor(t=!1){super(!1,t)}set(t,n,s,r){let o=t[n];const i=Y(t)&&ci(n);if(!this._isShallow){const c=Qt(o);if(!ht(s)&&!Qt(s)&&(o=ye(o),s=ye(s)),!i&&We(o)&&!We(s))return c||(o.value=s),!0}const l=i?Number(n)<t.length:ve(t,n),a=Reflect.set(t,n,s,We(t)?t:r);return t===ye(r)&&(l?Ot(s,o)&&qt(t,"set",n,s):qt(t,"add",n,s)),a}deleteProperty(t,n){const s=ve(t,n);t[n];const r=Reflect.deleteProperty(t,n);return r&&s&&qt(t,"delete",n,void 0),r}has(t,n){const s=Reflect.has(t,n);return(!Mt(n)||!qa.has(n))&&Be(t,"has",n),s}ownKeys(t){return Be(t,"iterate",Y(t)?"length":En),Reflect.ownKeys(t)}}class Ef extends za{constructor(t=!1){super(!0,t)}set(t,n){return!0}deleteProperty(t,n){return!0}}const Af=new Ka,Rf=new Ef,$f=new Ka(!0);const $o=e=>e,js=e=>Reflect.getPrototypeOf(e);function If(e,t,n){return function(...s){const r=this.__v_raw,o=ye(r),i=Fn(o),l=e==="entries"||e===Symbol.iterator&&i,a=e==="keys"&&i,c=r[e](...s),u=n?$o:t?qn:Ct;return!t&&Be(o,"iterate",a?Ro:En),je(Object.create(c),{next(){const{value:f,done:d}=c.next();return d?{value:f,done:d}:{value:l?[u(f[0]),u(f[1])]:u(f),done:d}}})}}function Fs(e){return function(...t){return e==="delete"?!1:e==="clear"?void 0:this}}function Nf(e,t){const n={get(r){const o=this.__v_raw,i=ye(o),l=ye(r);e||(Ot(r,l)&&Be(i,"get",r),Be(i,"get",l));const{has:a}=js(i),c=t?$o:e?qn:Ct;if(a.call(i,r))return c(o.get(r));if(a.call(i,l))return c(o.get(l));o!==i&&o.get(r)},get size(){const r=this.__v_raw;return!e&&Be(ye(r),"iterate",En),r.size},has(r){const o=this.__v_raw,i=ye(o),l=ye(r);return e||(Ot(r,l)&&Be(i,"has",r),Be(i,"has",l)),r===l?o.has(r):o.has(r)||o.has(l)},forEach(r,o){const i=this,l=i.__v_raw,a=ye(l),c=t?$o:e?qn:Ct;return!e&&Be(a,"iterate",En),l.forEach((u,f)=>r.call(o,c(u),c(f),i))}};return je(n,e?{add:Fs("add"),set:Fs("set"),delete:Fs("delete"),clear:Fs("clear")}:{add(r){const o=ye(this),i=js(o),l=ye(r),a=!t&&!ht(r)&&!Qt(r)?l:r;return i.has.call(o,a)||Ot(r,a)&&i.has.call(o,r)||Ot(l,a)&&i.has.call(o,l)||(o.add(a),qt(o,"add",a,a)),this},set(r,o){!t&&!ht(o)&&!Qt(o)&&(o=ye(o));const i=ye(this),{has:l,get:a}=js(i);let c=l.call(i,r);c||(r=ye(r),c=l.call(i,r));const u=a.call(i,r);return i.set(r,o),c?Ot(o,u)&&qt(i,"set",r,o):qt(i,"add",r,o),this},delete(r){const o=ye(this),{has:i,get:l}=js(o);let a=i.call(o,r);a||(r=ye(r),a=i.call(o,r)),l&&l.call(o,r);const c=o.delete(r);return a&&qt(o,"delete",r,void 0),c},clear(){const r=ye(this),o=r.size!==0,i=r.clear();return o&&qt(r,"clear",void 0,void 0),i}}),["keys","values","entries",Symbol.iterator].forEach(r=>{n[r]=If(r,e,t)}),n}function pi(e,t){const n=Nf(e,t);return(s,r,o)=>r==="__v_isReactive"?!e:r==="__v_isReadonly"?e:r==="__v_raw"?s:Reflect.get(ve(n,r)&&r in s?n:s,r,o)}const Pf={get:pi(!1,!1)},Of={get:pi(!1,!0)},Tf={get:pi(!0,!1)};const Xa=new WeakMap,Ja=new WeakMap,Ya=new WeakMap,Mf=new WeakMap;function Lf(e){switch(e){case"Object":case"Array":return 1;case"Map":case"Set":case"WeakMap":case"WeakSet":return 2;default:return 0}}function Df(e){return e.__v_skip||!Object.isExtensible(e)?0:Lf(lf(e))}function Yn(e){return Qt(e)?e:gi(e,!1,Af,Pf,Xa)}function Qa(e){return gi(e,!1,$f,Of,Ja)}function Io(e){return gi(e,!0,Rf,Tf,Ya)}function gi(e,t,n,s,r){if(!we(e)||e.__v_raw&&!(t&&e.__v_isReactive))return e;const o=Df(e);if(o===0)return e;const i=r.get(e);if(i)return i;const l=new Proxy(e,o===2?s:n);return r.set(e,l),l}function An(e){return Qt(e)?An(e.__v_raw):!!(e&&e.__v_isReactive)}function Qt(e){return!!(e&&e.__v_isReadonly)}function ht(e){return!!(e&&e.__v_isShallow)}function mi(e){return e?!!e.__v_raw:!1}function ye(e){const t=e&&e.__v_raw;return t?ye(t):e}function Gf(e){return!ve(e,"__v_skip")&&Object.isExtensible(e)&&Ta(e,"__v_skip",!0),e}const Ct=e=>we(e)?Yn(e):e,qn=e=>we(e)?Io(e):e;function We(e){return e?e.__v_isRef===!0:!1}function fe(e){return Za(e,!1)}function jf(e){return Za(e,!0)}function Za(e,t){return We(e)?e:new Ff(e,t)}class Ff{constructor(t,n){this.dep=new hi,this.__v_isRef=!0,this.__v_isShallow=!1,this._rawValue=n?t:ye(t),this._value=n?t:Ct(t),this.__v_isShallow=n}get value(){return this.dep.track(),this._value}set value(t){const n=this._rawValue,s=this.__v_isShallow||ht(t)||Qt(t);t=s?t:ye(t),Ot(t,n)&&(this._rawValue=t,this._value=s?t:Ct(t),this.dep.trigger())}}function Ie(e){return We(e)?e.value:e}const Bf={get:(e,t,n)=>t==="__v_raw"?e:Ie(Reflect.get(e,t,n)),set:(e,t,n,s)=>{const r=e[t];return We(r)&&!We(n)?(r.value=n,!0):Reflect.set(e,t,n,s)}};function ec(e){return An(e)?e:new Proxy(e,Bf)}class Uf{constructor(t,n,s){this.fn=t,this.setter=n,this._value=void 0,this.dep=new hi(this),this.__v_isRef=!0,this.deps=void 0,this.depsTail=void 0,this.flags=16,this.globalVersion=bs-1,this.next=void 0,this.effect=this,this.__v_isReadonly=!n,this.isSSR=s}notify(){if(this.flags|=16,!(this.flags&8)&&Se!==this)return Fa(this,!0),!0}get value(){const t=this.dep.track();return Ha(this),t&&(t.version=this.dep.version),this._value}set value(t){this.setter&&this.setter(t)}}function Hf(e,t,n=!1){let s,r;return ne(e)?s=e:(s=e.get,r=e.set),new Uf(s,r,n)}const Bs={},sr=new WeakMap;let yn;function Wf(e,t=!1,n=yn){if(n){let s=sr.get(n);s||sr.set(n,s=[]),s.push(e)}}function Vf(e,t,n=Ce){const{immediate:s,deep:r,once:o,scheduler:i,augmentJob:l,call:a}=n,c=R=>r?R:ht(R)||r===!1||r===0?zt(R,1):zt(R);let u,f,d,h,m=!1,v=!1;if(We(e)?(f=()=>e.value,m=ht(e)):An(e)?(f=()=>c(e),m=!0):Y(e)?(v=!0,m=e.some(R=>An(R)||ht(R)),f=()=>e.map(R=>{if(We(R))return R.value;if(An(R))return c(R);if(ne(R))return a?a(R,2):R()})):ne(e)?t?f=a?()=>a(e,2):e:f=()=>{if(d){Jt();try{d()}finally{Yt()}}const R=yn;yn=u;try{return a?a(e,3,[h]):e(h)}finally{yn=R}}:f=Tt,t&&r){const R=f,U=r===!0?1/0:r;f=()=>zt(R(),U)}const x=_f(),k=()=>{u.stop(),x&&x.active&&ai(x.effects,u)};if(o&&t){const R=t;t=(...U)=>{R(...U),k()}}let E=v?new Array(e.length).fill(Bs):Bs;const b=R=>{if(!(!(u.flags&1)||!u.dirty&&!R))if(t){const U=u.run();if(r||m||(v?U.some((I,w)=>Ot(I,E[w])):Ot(U,E))){d&&d();const I=yn;yn=u;try{const w=[U,E===Bs?void 0:v&&E[0]===Bs?[]:E,h];E=U,a?a(t,3,w):t(...w)}finally{yn=I}}}else u.run()};return l&&l(b),u=new Ga(f),u.scheduler=i?()=>i(b,!1):b,h=R=>Wf(R,!1,u),d=u.onStop=()=>{const R=sr.get(u);if(R){if(a)a(R,4);else for(const U of R)U();sr.delete(u)}},t?s?b(!0):E=u.run():i?i(b.bind(null,!0),!0):u.run(),k.pause=u.pause.bind(u),k.resume=u.resume.bind(u),k.stop=k,k}function zt(e,t=1/0,n){if(t<=0||!we(e)||e.__v_skip||(n=n||new Map,(n.get(e)||0)>=t))return e;if(n.set(e,t),t--,We(e))zt(e.value,t,n);else if(Y(e))for(let s=0;s<e.length;s++)zt(e[s],t,n);else if($r(e)||Fn(e))e.forEach(s=>{zt(s,t,n)});else if(Oa(e)){for(const s in e)zt(e[s],t,n);for(const s of Object.getOwnPropertySymbols(e))Object.prototype.propertyIsEnumerable.call(e,s)&&zt(e[s],t,n)}return e}/**
10
+ * @vue/runtime-core v3.5.30
11
+ * (c) 2018-present Yuxi (Evan) You and Vue contributors
12
+ * @license MIT
13
+ **/function Ts(e,t,n,s){try{return s?e(...s):e()}catch(r){Mr(r,t,n)}}function Lt(e,t,n,s){if(ne(e)){const r=Ts(e,t,n,s);return r&&Na(r)&&r.catch(o=>{Mr(o,t,n)}),r}if(Y(e)){const r=[];for(let o=0;o<e.length;o++)r.push(Lt(e[o],t,n,s));return r}}function Mr(e,t,n,s=!0){const r=t?t.vnode:null,{errorHandler:o,throwUnhandledErrorInProduction:i}=t&&t.appContext.config||Ce;if(t){let l=t.parent;const a=t.proxy,c=`https://vuejs.org/error-reference/#runtime-${n}`;for(;l;){const u=l.ec;if(u){for(let f=0;f<u.length;f++)if(u[f](e,a,c)===!1)return}l=l.parent}if(o){Jt(),Ts(o,null,10,[e,a,c]),Yt();return}}qf(e,n,r,s,i)}function qf(e,t,n,s=!0,r=!1){if(r)throw e;console.error(e)}const Ke=[];let It=-1;const Bn=[];let sn=null,Tn=0;const tc=Promise.resolve();let rr=null;function yi(e){const t=rr||tc;return e?t.then(this?e.bind(this):e):t}function zf(e){let t=It+1,n=Ke.length;for(;t<n;){const s=t+n>>>1,r=Ke[s],o=Cs(r);o<e||o===e&&r.flags&2?t=s+1:n=s}return t}function vi(e){if(!(e.flags&1)){const t=Cs(e),n=Ke[Ke.length-1];!n||!(e.flags&2)&&t>=Cs(n)?Ke.push(e):Ke.splice(zf(t),0,e),e.flags|=1,nc()}}function nc(){rr||(rr=tc.then(rc))}function Kf(e){Y(e)?Bn.push(...e):sn&&e.id===-1?sn.splice(Tn+1,0,e):e.flags&1||(Bn.push(e),e.flags|=1),nc()}function Yi(e,t,n=It+1){for(;n<Ke.length;n++){const s=Ke[n];if(s&&s.flags&2){if(e&&s.id!==e.uid)continue;Ke.splice(n,1),n--,s.flags&4&&(s.flags&=-2),s(),s.flags&4||(s.flags&=-2)}}}function sc(e){if(Bn.length){const t=[...new Set(Bn)].sort((n,s)=>Cs(n)-Cs(s));if(Bn.length=0,sn){sn.push(...t);return}for(sn=t,Tn=0;Tn<sn.length;Tn++){const n=sn[Tn];n.flags&4&&(n.flags&=-2),n.flags&8||n(),n.flags&=-2}sn=null,Tn=0}}const Cs=e=>e.id==null?e.flags&2?-1:1/0:e.id;function rc(e){try{for(It=0;It<Ke.length;It++){const t=Ke[It];t&&!(t.flags&8)&&(t.flags&4&&(t.flags&=-2),Ts(t,t.i,t.i?15:14),t.flags&4||(t.flags&=-2))}}finally{for(;It<Ke.length;It++){const t=Ke[It];t&&(t.flags&=-2)}It=-1,Ke.length=0,sc(),rr=null,(Ke.length||Bn.length)&&rc()}}let rt=null,oc=null;function or(e){const t=rt;return rt=e,oc=e&&e.type.__scopeId||null,t}function _i(e,t=rt,n){if(!t||e._n)return e;const s=(...r)=>{s._d&&ur(-1);const o=or(t);let i;try{i=e(...r)}finally{or(o),s._d&&ur(1)}return i};return s._n=!0,s._c=!0,s._d=!0,s}function ir(e,t){if(rt===null)return e;const n=jr(rt),s=e.dirs||(e.dirs=[]);for(let r=0;r<t.length;r++){let[o,i,l,a=Ce]=t[r];o&&(ne(o)&&(o={mounted:o,updated:o}),o.deep&&zt(i),s.push({dir:o,instance:n,value:i,oldValue:void 0,arg:l,modifiers:a}))}return e}function pn(e,t,n,s){const r=e.dirs,o=t&&t.dirs;for(let i=0;i<r.length;i++){const l=r[i];o&&(l.oldValue=o[i].value);let a=l.dir[s];a&&(Jt(),Lt(a,n,8,[e.el,l,e,t]),Yt())}}function Js(e,t){if(Ue){let n=Ue.provides;const s=Ue.parent&&Ue.parent.provides;s===n&&(n=Ue.provides=Object.create(s)),n[e]=t}}function bt(e,t,n=!1){const s=Xd();if(s||Un){let r=Un?Un._context.provides:s?s.parent==null||s.ce?s.vnode.appContext&&s.vnode.appContext.provides:s.parent.provides:void 0;if(r&&e in r)return r[e];if(arguments.length>1)return n&&ne(t)?t.call(s&&s.proxy):t}}const Xf=Symbol.for("v-scx"),Jf=()=>bt(Xf);function vt(e,t,n){return ic(e,t,n)}function ic(e,t,n=Ce){const{immediate:s,deep:r,flush:o,once:i}=n,l=je({},n),a=t&&s||!t&&o!=="post";let c;if(ks){if(o==="sync"){const h=Jf();c=h.__watcherHandles||(h.__watcherHandles=[])}else if(!a){const h=()=>{};return h.stop=Tt,h.resume=Tt,h.pause=Tt,h}}const u=Ue;l.call=(h,m,v)=>Lt(h,u,m,v);let f=!1;o==="post"?l.scheduler=h=>{Ze(h,u&&u.suspense)}:o!=="sync"&&(f=!0,l.scheduler=(h,m)=>{m?h():vi(h)}),l.augmentJob=h=>{t&&(h.flags|=4),f&&(h.flags|=2,u&&(h.id=u.uid,h.i=u))};const d=Vf(e,t,l);return ks&&(c?c.push(d):a&&d()),d}function Yf(e,t,n){const s=this.proxy,r=Pe(e)?e.includes(".")?lc(s,e):()=>s[e]:e.bind(s,s);let o;ne(t)?o=t:(o=t.handler,n=t);const i=Ms(this),l=ic(r,o.bind(s),n);return i(),l}function lc(e,t){const n=t.split(".");return()=>{let s=e;for(let r=0;r<n.length&&s;r++)s=s[n[r]];return s}}const Qf=Symbol("_vte"),Zf=e=>e.__isTeleport,ed=Symbol("_leaveCb");function bi(e,t){e.shapeFlag&6&&e.component?(e.transition=t,bi(e.component.subTree,t)):e.shapeFlag&128?(e.ssContent.transition=t.clone(e.ssContent),e.ssFallback.transition=t.clone(e.ssFallback)):e.transition=t}function ac(e,t){return ne(e)?je({name:e.name},t,{setup:e}):e}function cc(e){e.ids=[e.ids[0]+e.ids[2]+++"-",0,0]}function Qi(e,t){let n;return!!((n=Object.getOwnPropertyDescriptor(e,t))&&!n.configurable)}const lr=new WeakMap;function hs(e,t,n,s,r=!1){if(Y(e)){e.forEach((v,x)=>hs(v,t&&(Y(t)?t[x]:t),n,s,r));return}if(ps(s)&&!r){s.shapeFlag&512&&s.type.__asyncResolved&&s.component.subTree.component&&hs(e,t,n,s.component.subTree);return}const o=s.shapeFlag&4?jr(s.component):s.el,i=r?null:o,{i:l,r:a}=e,c=t&&t.r,u=l.refs===Ce?l.refs={}:l.refs,f=l.setupState,d=ye(f),h=f===Ce?Ia:v=>Qi(u,v)?!1:ve(d,v),m=(v,x)=>!(x&&Qi(u,x));if(c!=null&&c!==a){if(Zi(t),Pe(c))u[c]=null,h(c)&&(f[c]=null);else if(We(c)){const v=t;m(c,v.k)&&(c.value=null),v.k&&(u[v.k]=null)}}if(ne(a))Ts(a,l,12,[i,u]);else{const v=Pe(a),x=We(a);if(v||x){const k=()=>{if(e.f){const E=v?h(a)?f[a]:u[a]:m()||!e.k?a.value:u[e.k];if(r)Y(E)&&ai(E,o);else if(Y(E))E.includes(o)||E.push(o);else if(v)u[a]=[o],h(a)&&(f[a]=u[a]);else{const b=[o];m(a,e.k)&&(a.value=b),e.k&&(u[e.k]=b)}}else v?(u[a]=i,h(a)&&(f[a]=i)):x&&(m(a,e.k)&&(a.value=i),e.k&&(u[e.k]=i))};if(i){const E=()=>{k(),lr.delete(e)};E.id=-1,lr.set(e,E),Ze(E,n)}else Zi(e),k()}}}function Zi(e){const t=lr.get(e);t&&(t.flags|=8,lr.delete(e))}Or().requestIdleCallback;Or().cancelIdleCallback;const ps=e=>!!e.type.__asyncLoader,uc=e=>e.type.__isKeepAlive;function td(e,t){fc(e,"a",t)}function nd(e,t){fc(e,"da",t)}function fc(e,t,n=Ue){const s=e.__wdc||(e.__wdc=()=>{let r=n;for(;r;){if(r.isDeactivated)return;r=r.parent}return e()});if(Lr(t,s,n),n){let r=n.parent;for(;r&&r.parent;)uc(r.parent.vnode)&&sd(s,t,n,r),r=r.parent}}function sd(e,t,n,s){const r=Lr(t,e,s,!0);fn(()=>{ai(s[t],r)},n)}function Lr(e,t,n=Ue,s=!1){if(n){const r=n[e]||(n[e]=[]),o=t.__weh||(t.__weh=(...i)=>{Jt();const l=Ms(n),a=Lt(t,n,e,i);return l(),Yt(),a});return s?r.unshift(o):r.push(o),o}}const Zt=e=>(t,n=Ue)=>{(!ks||e==="sp")&&Lr(e,(...s)=>t(...s),n)},rd=Zt("bm"),kt=Zt("m"),od=Zt("bu"),id=Zt("u"),ld=Zt("bum"),fn=Zt("um"),ad=Zt("sp"),cd=Zt("rtg"),ud=Zt("rtc");function fd(e,t=Ue){Lr("ec",e,t)}const dd="components";function ar(e,t){return pd(dd,e,!0,t)||e}const hd=Symbol.for("v-ndc");function pd(e,t,n=!0,s=!1){const r=rt||Ue;if(r){const o=r.type;{const l=eh(o,!1);if(l&&(l===t||l===Je(t)||l===Nr(Je(t))))return o}const i=el(r[e]||o[e],t)||el(r.appContext[e],t);return!i&&s?o:i}}function el(e,t){return e&&(e[t]||e[Je(t)]||e[Nr(Je(t))])}function he(e,t,n,s){let r;const o=n,i=Y(e);if(i||Pe(e)){const l=i&&An(e);let a=!1,c=!1;l&&(a=!ht(e),c=Qt(e),e=Tr(e)),r=new Array(e.length);for(let u=0,f=e.length;u<f;u++)r[u]=t(a?c?qn(Ct(e[u])):Ct(e[u]):e[u],u,void 0,o)}else if(typeof e=="number"){r=new Array(e);for(let l=0;l<e;l++)r[l]=t(l+1,l,void 0,o)}else if(we(e))if(e[Symbol.iterator])r=Array.from(e,(l,a)=>t(l,a,void 0,o));else{const l=Object.keys(e);r=new Array(l.length);for(let a=0,c=l.length;a<c;a++){const u=l[a];r[a]=t(e[u],u,a,o)}}else r=[];return r}const No=e=>e?Nc(e)?jr(e):No(e.parent):null,gs=je(Object.create(null),{$:e=>e,$el:e=>e.vnode.el,$data:e=>e.data,$props:e=>e.props,$attrs:e=>e.attrs,$slots:e=>e.slots,$refs:e=>e.refs,$parent:e=>No(e.parent),$root:e=>No(e.root),$host:e=>e.ce,$emit:e=>e.emit,$options:e=>hc(e),$forceUpdate:e=>e.f||(e.f=()=>{vi(e.update)}),$nextTick:e=>e.n||(e.n=yi.bind(e.proxy)),$watch:e=>Yf.bind(e)}),so=(e,t)=>e!==Ce&&!e.__isScriptSetup&&ve(e,t),gd={get({_:e},t){if(t==="__v_skip")return!0;const{ctx:n,setupState:s,data:r,props:o,accessCache:i,type:l,appContext:a}=e;if(t[0]!=="$"){const d=i[t];if(d!==void 0)switch(d){case 1:return s[t];case 2:return r[t];case 4:return n[t];case 3:return o[t]}else{if(so(s,t))return i[t]=1,s[t];if(r!==Ce&&ve(r,t))return i[t]=2,r[t];if(ve(o,t))return i[t]=3,o[t];if(n!==Ce&&ve(n,t))return i[t]=4,n[t];Po&&(i[t]=0)}}const c=gs[t];let u,f;if(c)return t==="$attrs"&&Be(e.attrs,"get",""),c(e);if((u=l.__cssModules)&&(u=u[t]))return u;if(n!==Ce&&ve(n,t))return i[t]=4,n[t];if(f=a.config.globalProperties,ve(f,t))return f[t]},set({_:e},t,n){const{data:s,setupState:r,ctx:o}=e;return so(r,t)?(r[t]=n,!0):s!==Ce&&ve(s,t)?(s[t]=n,!0):ve(e.props,t)||t[0]==="$"&&t.slice(1)in e?!1:(o[t]=n,!0)},has({_:{data:e,setupState:t,accessCache:n,ctx:s,appContext:r,props:o,type:i}},l){let a;return!!(n[l]||e!==Ce&&l[0]!=="$"&&ve(e,l)||so(t,l)||ve(o,l)||ve(s,l)||ve(gs,l)||ve(r.config.globalProperties,l)||(a=i.__cssModules)&&a[l])},defineProperty(e,t,n){return n.get!=null?e._.accessCache[t]=0:ve(n,"value")&&this.set(e,t,n.value,null),Reflect.defineProperty(e,t,n)}};function tl(e){return Y(e)?e.reduce((t,n)=>(t[n]=null,t),{}):e}let Po=!0;function md(e){const t=hc(e),n=e.proxy,s=e.ctx;Po=!1,t.beforeCreate&&nl(t.beforeCreate,e,"bc");const{data:r,computed:o,methods:i,watch:l,provide:a,inject:c,created:u,beforeMount:f,mounted:d,beforeUpdate:h,updated:m,activated:v,deactivated:x,beforeDestroy:k,beforeUnmount:E,destroyed:b,unmounted:R,render:U,renderTracked:I,renderTriggered:w,errorCaptured:W,serverPrefetch:Q,expose:q,inheritAttrs:re,components:L,directives:pe,filters:oe}=t;if(c&&yd(c,s,null),i)for(const ae in i){const le=i[ae];ne(le)&&(s[ae]=le.bind(n))}if(r){const ae=r.call(n,n);we(ae)&&(e.data=Yn(ae))}if(Po=!0,o)for(const ae in o){const le=o[ae],it=ne(le)?le.bind(n,n):ne(le.get)?le.get.bind(n,n):Tt,lt=!ne(le)&&ne(le.set)?le.set.bind(n):Tt,at=de({get:it,set:lt});Object.defineProperty(s,ae,{enumerable:!0,configurable:!0,get:()=>at.value,set:Ge=>at.value=Ge})}if(l)for(const ae in l)dc(l[ae],s,n,ae);if(a){const ae=ne(a)?a.call(n):a;Reflect.ownKeys(ae).forEach(le=>{Js(le,ae[le])})}u&&nl(u,e,"c");function ge(ae,le){Y(le)?le.forEach(it=>ae(it.bind(n))):le&&ae(le.bind(n))}if(ge(rd,f),ge(kt,d),ge(od,h),ge(id,m),ge(td,v),ge(nd,x),ge(fd,W),ge(ud,I),ge(cd,w),ge(ld,E),ge(fn,R),ge(ad,Q),Y(q))if(q.length){const ae=e.exposed||(e.exposed={});q.forEach(le=>{Object.defineProperty(ae,le,{get:()=>n[le],set:it=>n[le]=it,enumerable:!0})})}else e.exposed||(e.exposed={});U&&e.render===Tt&&(e.render=U),re!=null&&(e.inheritAttrs=re),L&&(e.components=L),pe&&(e.directives=pe),Q&&cc(e)}function yd(e,t,n=Tt){Y(e)&&(e=Oo(e));for(const s in e){const r=e[s];let o;we(r)?"default"in r?o=bt(r.from||s,r.default,!0):o=bt(r.from||s):o=bt(r),We(o)?Object.defineProperty(t,s,{enumerable:!0,configurable:!0,get:()=>o.value,set:i=>o.value=i}):t[s]=o}}function nl(e,t,n){Lt(Y(e)?e.map(s=>s.bind(t.proxy)):e.bind(t.proxy),t,n)}function dc(e,t,n,s){let r=s.includes(".")?lc(n,s):()=>n[s];if(Pe(e)){const o=t[e];ne(o)&&vt(r,o)}else if(ne(e))vt(r,e.bind(n));else if(we(e))if(Y(e))e.forEach(o=>dc(o,t,n,s));else{const o=ne(e.handler)?e.handler.bind(n):t[e.handler];ne(o)&&vt(r,o,e)}}function hc(e){const t=e.type,{mixins:n,extends:s}=t,{mixins:r,optionsCache:o,config:{optionMergeStrategies:i}}=e.appContext,l=o.get(t);let a;return l?a=l:!r.length&&!n&&!s?a=t:(a={},r.length&&r.forEach(c=>cr(a,c,i,!0)),cr(a,t,i)),we(t)&&o.set(t,a),a}function cr(e,t,n,s=!1){const{mixins:r,extends:o}=t;o&&cr(e,o,n,!0),r&&r.forEach(i=>cr(e,i,n,!0));for(const i in t)if(!(s&&i==="expose")){const l=vd[i]||n&&n[i];e[i]=l?l(e[i],t[i]):t[i]}return e}const vd={data:sl,props:rl,emits:rl,methods:ls,computed:ls,beforeCreate:qe,created:qe,beforeMount:qe,mounted:qe,beforeUpdate:qe,updated:qe,beforeDestroy:qe,beforeUnmount:qe,destroyed:qe,unmounted:qe,activated:qe,deactivated:qe,errorCaptured:qe,serverPrefetch:qe,components:ls,directives:ls,watch:bd,provide:sl,inject:_d};function sl(e,t){return t?e?function(){return je(ne(e)?e.call(this,this):e,ne(t)?t.call(this,this):t)}:t:e}function _d(e,t){return ls(Oo(e),Oo(t))}function Oo(e){if(Y(e)){const t={};for(let n=0;n<e.length;n++)t[e[n]]=e[n];return t}return e}function qe(e,t){return e?[...new Set([].concat(e,t))]:t}function ls(e,t){return e?je(Object.create(null),e,t):t}function rl(e,t){return e?Y(e)&&Y(t)?[...new Set([...e,...t])]:je(Object.create(null),tl(e),tl(t??{})):t}function bd(e,t){if(!e)return t;if(!t)return e;const n=je(Object.create(null),e);for(const s in t)n[s]=qe(e[s],t[s]);return n}function pc(){return{app:null,config:{isNativeTag:Ia,performance:!1,globalProperties:{},optionMergeStrategies:{},errorHandler:void 0,warnHandler:void 0,compilerOptions:{}},mixins:[],components:{},directives:{},provides:Object.create(null),optionsCache:new WeakMap,propsCache:new WeakMap,emitsCache:new WeakMap}}let wd=0;function Cd(e,t){return function(s,r=null){ne(s)||(s=je({},s)),r!=null&&!we(r)&&(r=null);const o=pc(),i=new WeakSet,l=[];let a=!1;const c=o.app={_uid:wd++,_component:s,_props:r,_container:null,_context:o,_instance:null,version:nh,get config(){return o.config},set config(u){},use(u,...f){return i.has(u)||(u&&ne(u.install)?(i.add(u),u.install(c,...f)):ne(u)&&(i.add(u),u(c,...f))),c},mixin(u){return o.mixins.includes(u)||o.mixins.push(u),c},component(u,f){return f?(o.components[u]=f,c):o.components[u]},directive(u,f){return f?(o.directives[u]=f,c):o.directives[u]},mount(u,f,d){if(!a){const h=c._ceVNode||_e(s,r);return h.appContext=o,d===!0?d="svg":d===!1&&(d=void 0),e(h,u,d),a=!0,c._container=u,u.__vue_app__=c,jr(h.component)}},onUnmount(u){l.push(u)},unmount(){a&&(Lt(l,c._instance,16),e(null,c._container),delete c._container.__vue_app__)},provide(u,f){return o.provides[u]=f,c},runWithContext(u){const f=Un;Un=c;try{return u()}finally{Un=f}}};return c}}let Un=null;const xd=(e,t)=>t==="modelValue"||t==="model-value"?e.modelModifiers:e[`${t}Modifiers`]||e[`${Je(t)}Modifiers`]||e[`${$n(t)}Modifiers`];function kd(e,t,...n){if(e.isUnmounted)return;const s=e.vnode.props||Ce;let r=n;const o=t.startsWith("update:"),i=o&&xd(s,t.slice(7));i&&(i.trim&&(r=n.map(u=>Pe(u)?u.trim():u)),i.number&&(r=n.map(Pr)));let l,a=s[l=Qr(t)]||s[l=Qr(Je(t))];!a&&o&&(a=s[l=Qr($n(t))]),a&&Lt(a,e,6,r);const c=s[l+"Once"];if(c){if(!e.emitted)e.emitted={};else if(e.emitted[l])return;e.emitted[l]=!0,Lt(c,e,6,r)}}const Sd=new WeakMap;function gc(e,t,n=!1){const s=n?Sd:t.emitsCache,r=s.get(e);if(r!==void 0)return r;const o=e.emits;let i={},l=!1;if(!ne(e)){const a=c=>{const u=gc(c,t,!0);u&&(l=!0,je(i,u))};!n&&t.mixins.length&&t.mixins.forEach(a),e.extends&&a(e.extends),e.mixins&&e.mixins.forEach(a)}return!o&&!l?(we(e)&&s.set(e,null),null):(Y(o)?o.forEach(a=>i[a]=null):je(i,o),we(e)&&s.set(e,i),i)}function Dr(e,t){return!e||!Rr(t)?!1:(t=t.slice(2).replace(/Once$/,""),ve(e,t[0].toLowerCase()+t.slice(1))||ve(e,$n(t))||ve(e,t))}function ol(e){const{type:t,vnode:n,proxy:s,withProxy:r,propsOptions:[o],slots:i,attrs:l,emit:a,render:c,renderCache:u,props:f,data:d,setupState:h,ctx:m,inheritAttrs:v}=e,x=or(e);let k,E;try{if(n.shapeFlag&4){const R=r||s,U=R;k=Pt(c.call(U,R,u,f,h,d,m)),E=l}else{const R=t;k=Pt(R.length>1?R(f,{attrs:l,slots:i,emit:a}):R(f,null)),E=t.props?l:Ed(l)}}catch(R){ms.length=0,Mr(R,e,1),k=_e(un)}let b=k;if(E&&v!==!1){const R=Object.keys(E),{shapeFlag:U}=b;R.length&&U&7&&(o&&R.some(li)&&(E=Ad(E,o)),b=zn(b,E,!1,!0))}return n.dirs&&(b=zn(b,null,!1,!0),b.dirs=b.dirs?b.dirs.concat(n.dirs):n.dirs),n.transition&&bi(b,n.transition),k=b,or(x),k}const Ed=e=>{let t;for(const n in e)(n==="class"||n==="style"||Rr(n))&&((t||(t={}))[n]=e[n]);return t},Ad=(e,t)=>{const n={};for(const s in e)(!li(s)||!(s.slice(9)in t))&&(n[s]=e[s]);return n};function Rd(e,t,n){const{props:s,children:r,component:o}=e,{props:i,children:l,patchFlag:a}=t,c=o.emitsOptions;if(t.dirs||t.transition)return!0;if(n&&a>=0){if(a&1024)return!0;if(a&16)return s?il(s,i,c):!!i;if(a&8){const u=t.dynamicProps;for(let f=0;f<u.length;f++){const d=u[f];if(mc(i,s,d)&&!Dr(c,d))return!0}}}else return(r||l)&&(!l||!l.$stable)?!0:s===i?!1:s?i?il(s,i,c):!0:!!i;return!1}function il(e,t,n){const s=Object.keys(t);if(s.length!==Object.keys(e).length)return!0;for(let r=0;r<s.length;r++){const o=s[r];if(mc(t,e,o)&&!Dr(n,o))return!0}return!1}function mc(e,t,n){const s=e[n],r=t[n];return n==="style"&&we(s)&&we(r)?!Os(s,r):s!==r}function $d({vnode:e,parent:t},n){for(;t;){const s=t.subTree;if(s.suspense&&s.suspense.activeBranch===e&&(s.el=e.el),s===e)(e=t.vnode).el=n,t=t.parent;else break}}const yc={},vc=()=>Object.create(yc),_c=e=>Object.getPrototypeOf(e)===yc;function Id(e,t,n,s=!1){const r={},o=vc();e.propsDefaults=Object.create(null),bc(e,t,r,o);for(const i in e.propsOptions[0])i in r||(r[i]=void 0);n?e.props=s?r:Qa(r):e.type.props?e.props=r:e.props=o,e.attrs=o}function Nd(e,t,n,s){const{props:r,attrs:o,vnode:{patchFlag:i}}=e,l=ye(r),[a]=e.propsOptions;let c=!1;if((s||i>0)&&!(i&16)){if(i&8){const u=e.vnode.dynamicProps;for(let f=0;f<u.length;f++){let d=u[f];if(Dr(e.emitsOptions,d))continue;const h=t[d];if(a)if(ve(o,d))h!==o[d]&&(o[d]=h,c=!0);else{const m=Je(d);r[m]=To(a,l,m,h,e,!1)}else h!==o[d]&&(o[d]=h,c=!0)}}}else{bc(e,t,r,o)&&(c=!0);let u;for(const f in l)(!t||!ve(t,f)&&((u=$n(f))===f||!ve(t,u)))&&(a?n&&(n[f]!==void 0||n[u]!==void 0)&&(r[f]=To(a,l,f,void 0,e,!0)):delete r[f]);if(o!==l)for(const f in o)(!t||!ve(t,f))&&(delete o[f],c=!0)}c&&qt(e.attrs,"set","")}function bc(e,t,n,s){const[r,o]=e.propsOptions;let i=!1,l;if(t)for(let a in t){if(us(a))continue;const c=t[a];let u;r&&ve(r,u=Je(a))?!o||!o.includes(u)?n[u]=c:(l||(l={}))[u]=c:Dr(e.emitsOptions,a)||(!(a in s)||c!==s[a])&&(s[a]=c,i=!0)}if(o){const a=ye(n),c=l||Ce;for(let u=0;u<o.length;u++){const f=o[u];n[f]=To(r,a,f,c[f],e,!ve(c,f))}}return i}function To(e,t,n,s,r,o){const i=e[n];if(i!=null){const l=ve(i,"default");if(l&&s===void 0){const a=i.default;if(i.type!==Function&&!i.skipFactory&&ne(a)){const{propsDefaults:c}=r;if(n in c)s=c[n];else{const u=Ms(r);s=c[n]=a.call(null,t),u()}}else s=a;r.ce&&r.ce._setProp(n,s)}i[0]&&(o&&!l?s=!1:i[1]&&(s===""||s===$n(n))&&(s=!0))}return s}const Pd=new WeakMap;function wc(e,t,n=!1){const s=n?Pd:t.propsCache,r=s.get(e);if(r)return r;const o=e.props,i={},l=[];let a=!1;if(!ne(e)){const u=f=>{a=!0;const[d,h]=wc(f,t,!0);je(i,d),h&&l.push(...h)};!n&&t.mixins.length&&t.mixins.forEach(u),e.extends&&u(e.extends),e.mixins&&e.mixins.forEach(u)}if(!o&&!a)return we(e)&&s.set(e,jn),jn;if(Y(o))for(let u=0;u<o.length;u++){const f=Je(o[u]);ll(f)&&(i[f]=Ce)}else if(o)for(const u in o){const f=Je(u);if(ll(f)){const d=o[u],h=i[f]=Y(d)||ne(d)?{type:d}:je({},d),m=h.type;let v=!1,x=!0;if(Y(m))for(let k=0;k<m.length;++k){const E=m[k],b=ne(E)&&E.name;if(b==="Boolean"){v=!0;break}else b==="String"&&(x=!1)}else v=ne(m)&&m.name==="Boolean";h[0]=v,h[1]=x,(v||ve(h,"default"))&&l.push(f)}}const c=[i,l];return we(e)&&s.set(e,c),c}function ll(e){return e[0]!=="$"&&!us(e)}const wi=e=>e==="_"||e==="_ctx"||e==="$stable",Ci=e=>Y(e)?e.map(Pt):[Pt(e)],Od=(e,t,n)=>{if(t._n)return t;const s=_i((...r)=>Ci(t(...r)),n);return s._c=!1,s},Cc=(e,t,n)=>{const s=e._ctx;for(const r in e){if(wi(r))continue;const o=e[r];if(ne(o))t[r]=Od(r,o,s);else if(o!=null){const i=Ci(o);t[r]=()=>i}}},xc=(e,t)=>{const n=Ci(t);e.slots.default=()=>n},kc=(e,t,n)=>{for(const s in t)(n||!wi(s))&&(e[s]=t[s])},Td=(e,t,n)=>{const s=e.slots=vc();if(e.vnode.shapeFlag&32){const r=t._;r?(kc(s,t,n),n&&Ta(s,"_",r,!0)):Cc(t,s)}else t&&xc(e,t)},Md=(e,t,n)=>{const{vnode:s,slots:r}=e;let o=!0,i=Ce;if(s.shapeFlag&32){const l=t._;l?n&&l===1?o=!1:kc(r,t,n):(o=!t.$stable,Cc(t,r)),i=t}else t&&(xc(e,t),i={default:1});if(o)for(const l in r)!wi(l)&&i[l]==null&&delete r[l]},Ze=Fd;function Ld(e){return Dd(e)}function Dd(e,t){const n=Or();n.__VUE__=!0;const{insert:s,remove:r,patchProp:o,createElement:i,createText:l,createComment:a,setText:c,setElementText:u,parentNode:f,nextSibling:d,setScopeId:h=Tt,insertStaticContent:m}=e,v=(g,y,_,P=null,T=null,O=null,H=void 0,B=null,G=!!y.dynamicChildren)=>{if(g===y)return;g&&!rs(g,y)&&(P=A(g),Ge(g,T,O,!0),g=null),y.patchFlag===-2&&(G=!1,y.dynamicChildren=null);const{type:M,ref:X,shapeFlag:V}=y;switch(M){case Gr:x(g,y,_,P);break;case un:k(g,y,_,P);break;case Ys:g==null&&E(y,_,P,H);break;case Z:L(g,y,_,P,T,O,H,B,G);break;default:V&1?U(g,y,_,P,T,O,H,B,G):V&6?pe(g,y,_,P,T,O,H,B,G):(V&64||V&128)&&M.process(g,y,_,P,T,O,H,B,G,z)}X!=null&&T?hs(X,g&&g.ref,O,y||g,!y):X==null&&g&&g.ref!=null&&hs(g.ref,null,O,g,!0)},x=(g,y,_,P)=>{if(g==null)s(y.el=l(y.children),_,P);else{const T=y.el=g.el;y.children!==g.children&&c(T,y.children)}},k=(g,y,_,P)=>{g==null?s(y.el=a(y.children||""),_,P):y.el=g.el},E=(g,y,_,P)=>{[g.el,g.anchor]=m(g.children,y,_,P,g.el,g.anchor)},b=({el:g,anchor:y},_,P)=>{let T;for(;g&&g!==y;)T=d(g),s(g,_,P),g=T;s(y,_,P)},R=({el:g,anchor:y})=>{let _;for(;g&&g!==y;)_=d(g),r(g),g=_;r(y)},U=(g,y,_,P,T,O,H,B,G)=>{if(y.type==="svg"?H="svg":y.type==="math"&&(H="mathml"),g==null)I(y,_,P,T,O,H,B,G);else{const M=g.el&&g.el._isVueCE?g.el:null;try{M&&M._beginPatch(),Q(g,y,T,O,H,B,G)}finally{M&&M._endPatch()}}},I=(g,y,_,P,T,O,H,B)=>{let G,M;const{props:X,shapeFlag:V,transition:K,dirs:ee}=g;if(G=g.el=i(g.type,O,X&&X.is,X),V&8?u(G,g.children):V&16&&W(g.children,G,null,P,T,ro(g,O),H,B),ee&&pn(g,null,P,"created"),w(G,g,g.scopeId,H,P),X){for(const xe in X)xe!=="value"&&!us(xe)&&o(G,xe,null,X[xe],O,P);"value"in X&&o(G,"value",null,X.value,O),(M=X.onVnodeBeforeMount)&&Rt(M,P,g)}ee&&pn(g,null,P,"beforeMount");const ue=Gd(T,K);ue&&K.beforeEnter(G),s(G,y,_),((M=X&&X.onVnodeMounted)||ue||ee)&&Ze(()=>{M&&Rt(M,P,g),ue&&K.enter(G),ee&&pn(g,null,P,"mounted")},T)},w=(g,y,_,P,T)=>{if(_&&h(g,_),P)for(let O=0;O<P.length;O++)h(g,P[O]);if(T){let O=T.subTree;if(y===O||Rc(O.type)&&(O.ssContent===y||O.ssFallback===y)){const H=T.vnode;w(g,H,H.scopeId,H.slotScopeIds,T.parent)}}},W=(g,y,_,P,T,O,H,B,G=0)=>{for(let M=G;M<g.length;M++){const X=g[M]=B?Wt(g[M]):Pt(g[M]);v(null,X,y,_,P,T,O,H,B)}},Q=(g,y,_,P,T,O,H)=>{const B=y.el=g.el;let{patchFlag:G,dynamicChildren:M,dirs:X}=y;G|=g.patchFlag&16;const V=g.props||Ce,K=y.props||Ce;let ee;if(_&&gn(_,!1),(ee=K.onVnodeBeforeUpdate)&&Rt(ee,_,y,g),X&&pn(y,g,_,"beforeUpdate"),_&&gn(_,!0),(V.innerHTML&&K.innerHTML==null||V.textContent&&K.textContent==null)&&u(B,""),M?q(g.dynamicChildren,M,B,_,P,ro(y,T),O):H||le(g,y,B,null,_,P,ro(y,T),O,!1),G>0){if(G&16)re(B,V,K,_,T);else if(G&2&&V.class!==K.class&&o(B,"class",null,K.class,T),G&4&&o(B,"style",V.style,K.style,T),G&8){const ue=y.dynamicProps;for(let xe=0;xe<ue.length;xe++){const be=ue[xe],Ye=V[be],Qe=K[be];(Qe!==Ye||be==="value")&&o(B,be,Ye,Qe,T,_)}}G&1&&g.children!==y.children&&u(B,y.children)}else!H&&M==null&&re(B,V,K,_,T);((ee=K.onVnodeUpdated)||X)&&Ze(()=>{ee&&Rt(ee,_,y,g),X&&pn(y,g,_,"updated")},P)},q=(g,y,_,P,T,O,H)=>{for(let B=0;B<y.length;B++){const G=g[B],M=y[B],X=G.el&&(G.type===Z||!rs(G,M)||G.shapeFlag&198)?f(G.el):_;v(G,M,X,null,P,T,O,H,!0)}},re=(g,y,_,P,T)=>{if(y!==_){if(y!==Ce)for(const O in y)!us(O)&&!(O in _)&&o(g,O,y[O],null,T,P);for(const O in _){if(us(O))continue;const H=_[O],B=y[O];H!==B&&O!=="value"&&o(g,O,B,H,T,P)}"value"in _&&o(g,"value",y.value,_.value,T)}},L=(g,y,_,P,T,O,H,B,G)=>{const M=y.el=g?g.el:l(""),X=y.anchor=g?g.anchor:l("");let{patchFlag:V,dynamicChildren:K,slotScopeIds:ee}=y;ee&&(B=B?B.concat(ee):ee),g==null?(s(M,_,P),s(X,_,P),W(y.children||[],_,X,T,O,H,B,G)):V>0&&V&64&&K&&g.dynamicChildren&&g.dynamicChildren.length===K.length?(q(g.dynamicChildren,K,_,T,O,H,B),(y.key!=null||T&&y===T.subTree)&&Sc(g,y,!0)):le(g,y,_,X,T,O,H,B,G)},pe=(g,y,_,P,T,O,H,B,G)=>{y.slotScopeIds=B,g==null?y.shapeFlag&512?T.ctx.activate(y,_,P,H,G):oe(y,_,P,T,O,H,G):Ee(g,y,G)},oe=(g,y,_,P,T,O,H)=>{const B=g.component=Kd(g,P,T);if(uc(g)&&(B.ctx.renderer=z),Jd(B,!1,H),B.asyncDep){if(T&&T.registerDep(B,ge,H),!g.el){const G=B.subTree=_e(un);k(null,G,y,_),g.placeholder=G.el}}else ge(B,g,y,_,T,O,H)},Ee=(g,y,_)=>{const P=y.component=g.component;if(Rd(g,y,_))if(P.asyncDep&&!P.asyncResolved){ae(P,y,_);return}else P.next=y,P.update();else y.el=g.el,P.vnode=y},ge=(g,y,_,P,T,O,H)=>{const B=()=>{if(g.isMounted){let{next:V,bu:K,u:ee,parent:ue,vnode:xe}=g;{const Et=Ec(g);if(Et){V&&(V.el=xe.el,ae(g,V,H)),Et.asyncDep.then(()=>{Ze(()=>{g.isUnmounted||M()},T)});return}}let be=V,Ye;gn(g,!1),V?(V.el=xe.el,ae(g,V,H)):V=xe,K&&Xs(K),(Ye=V.props&&V.props.onVnodeBeforeUpdate)&&Rt(Ye,ue,V,xe),gn(g,!0);const Qe=ol(g),St=g.subTree;g.subTree=Qe,v(St,Qe,f(St.el),A(St),g,T,O),V.el=Qe.el,be===null&&$d(g,Qe.el),ee&&Ze(ee,T),(Ye=V.props&&V.props.onVnodeUpdated)&&Ze(()=>Rt(Ye,ue,V,xe),T)}else{let V;const{el:K,props:ee}=y,{bm:ue,m:xe,parent:be,root:Ye,type:Qe}=g,St=ps(y);gn(g,!1),ue&&Xs(ue),!St&&(V=ee&&ee.onVnodeBeforeMount)&&Rt(V,be,y),gn(g,!0);{Ye.ce&&Ye.ce._hasShadowRoot()&&Ye.ce._injectChildStyle(Qe,g.parent?g.parent.type:void 0);const Et=g.subTree=ol(g);v(null,Et,_,P,g,T,O),y.el=Et.el}if(xe&&Ze(xe,T),!St&&(V=ee&&ee.onVnodeMounted)){const Et=y;Ze(()=>Rt(V,be,Et),T)}(y.shapeFlag&256||be&&ps(be.vnode)&&be.vnode.shapeFlag&256)&&g.a&&Ze(g.a,T),g.isMounted=!0,y=_=P=null}};g.scope.on();const G=g.effect=new Ga(B);g.scope.off();const M=g.update=G.run.bind(G),X=g.job=G.runIfDirty.bind(G);X.i=g,X.id=g.uid,G.scheduler=()=>vi(X),gn(g,!0),M()},ae=(g,y,_)=>{y.component=g;const P=g.vnode.props;g.vnode=y,g.next=null,Nd(g,y.props,P,_),Md(g,y.children,_),Jt(),Yi(g),Yt()},le=(g,y,_,P,T,O,H,B,G=!1)=>{const M=g&&g.children,X=g?g.shapeFlag:0,V=y.children,{patchFlag:K,shapeFlag:ee}=y;if(K>0){if(K&128){lt(M,V,_,P,T,O,H,B,G);return}else if(K&256){it(M,V,_,P,T,O,H,B,G);return}}ee&8?(X&16&&J(M,T,O),V!==M&&u(_,V)):X&16?ee&16?lt(M,V,_,P,T,O,H,B,G):J(M,T,O,!0):(X&8&&u(_,""),ee&16&&W(V,_,P,T,O,H,B,G))},it=(g,y,_,P,T,O,H,B,G)=>{g=g||jn,y=y||jn;const M=g.length,X=y.length,V=Math.min(M,X);let K;for(K=0;K<V;K++){const ee=y[K]=G?Wt(y[K]):Pt(y[K]);v(g[K],ee,_,null,T,O,H,B,G)}M>X?J(g,T,O,!0,!1,V):W(y,_,P,T,O,H,B,G,V)},lt=(g,y,_,P,T,O,H,B,G)=>{let M=0;const X=y.length;let V=g.length-1,K=X-1;for(;M<=V&&M<=K;){const ee=g[M],ue=y[M]=G?Wt(y[M]):Pt(y[M]);if(rs(ee,ue))v(ee,ue,_,null,T,O,H,B,G);else break;M++}for(;M<=V&&M<=K;){const ee=g[V],ue=y[K]=G?Wt(y[K]):Pt(y[K]);if(rs(ee,ue))v(ee,ue,_,null,T,O,H,B,G);else break;V--,K--}if(M>V){if(M<=K){const ee=K+1,ue=ee<X?y[ee].el:P;for(;M<=K;)v(null,y[M]=G?Wt(y[M]):Pt(y[M]),_,ue,T,O,H,B,G),M++}}else if(M>K)for(;M<=V;)Ge(g[M],T,O,!0),M++;else{const ee=M,ue=M,xe=new Map;for(M=ue;M<=K;M++){const nt=y[M]=G?Wt(y[M]):Pt(y[M]);nt.key!=null&&xe.set(nt.key,M)}let be,Ye=0;const Qe=K-ue+1;let St=!1,Et=0;const ns=new Array(Qe);for(M=0;M<Qe;M++)ns[M]=0;for(M=ee;M<=V;M++){const nt=g[M];if(Ye>=Qe){Ge(nt,T,O,!0);continue}let At;if(nt.key!=null)At=xe.get(nt.key);else for(be=ue;be<=K;be++)if(ns[be-ue]===0&&rs(nt,y[be])){At=be;break}At===void 0?Ge(nt,T,O,!0):(ns[At-ue]=M+1,At>=Et?Et=At:St=!0,v(nt,y[At],_,null,T,O,H,B,G),Ye++)}const Ui=St?jd(ns):jn;for(be=Ui.length-1,M=Qe-1;M>=0;M--){const nt=ue+M,At=y[nt],Hi=y[nt+1],Wi=nt+1<X?Hi.el||Ac(Hi):P;ns[M]===0?v(null,At,_,Wi,T,O,H,B,G):St&&(be<0||M!==Ui[be]?at(At,_,Wi,2):be--)}}},at=(g,y,_,P,T=null)=>{const{el:O,type:H,transition:B,children:G,shapeFlag:M}=g;if(M&6){at(g.component.subTree,y,_,P);return}if(M&128){g.suspense.move(y,_,P);return}if(M&64){H.move(g,y,_,z);return}if(H===Z){s(O,y,_);for(let V=0;V<G.length;V++)at(G[V],y,_,P);s(g.anchor,y,_);return}if(H===Ys){b(g,y,_);return}if(P!==2&&M&1&&B)if(P===0)B.beforeEnter(O),s(O,y,_),Ze(()=>B.enter(O),T);else{const{leave:V,delayLeave:K,afterLeave:ee}=B,ue=()=>{g.ctx.isUnmounted?r(O):s(O,y,_)},xe=()=>{O._isLeaving&&O[ed](!0),V(O,()=>{ue(),ee&&ee()})};K?K(O,ue,xe):xe()}else s(O,y,_)},Ge=(g,y,_,P=!1,T=!1)=>{const{type:O,props:H,ref:B,children:G,dynamicChildren:M,shapeFlag:X,patchFlag:V,dirs:K,cacheIndex:ee}=g;if(V===-2&&(T=!1),B!=null&&(Jt(),hs(B,null,_,g,!0),Yt()),ee!=null&&(y.renderCache[ee]=void 0),X&256){y.ctx.deactivate(g);return}const ue=X&1&&K,xe=!ps(g);let be;if(xe&&(be=H&&H.onVnodeBeforeUnmount)&&Rt(be,y,g),X&6)Gt(g.component,_,P);else{if(X&128){g.suspense.unmount(_,P);return}ue&&pn(g,null,y,"beforeUnmount"),X&64?g.type.remove(g,y,_,z,P):M&&!M.hasOnce&&(O!==Z||V>0&&V&64)?J(M,y,_,!1,!0):(O===Z&&V&384||!T&&X&16)&&J(G,y,_),P&&pt(g)}(xe&&(be=H&&H.onVnodeUnmounted)||ue)&&Ze(()=>{be&&Rt(be,y,g),ue&&pn(g,null,y,"unmounted")},_)},pt=g=>{const{type:y,el:_,anchor:P,transition:T}=g;if(y===Z){Dt(_,P);return}if(y===Ys){R(g);return}const O=()=>{r(_),T&&!T.persisted&&T.afterLeave&&T.afterLeave()};if(g.shapeFlag&1&&T&&!T.persisted){const{leave:H,delayLeave:B}=T,G=()=>H(_,O);B?B(g.el,O,G):G()}else O()},Dt=(g,y)=>{let _;for(;g!==y;)_=d(g),r(g),g=_;r(y)},Gt=(g,y,_)=>{const{bum:P,scope:T,job:O,subTree:H,um:B,m:G,a:M}=g;al(G),al(M),P&&Xs(P),T.stop(),O&&(O.flags|=8,Ge(H,g,y,_)),B&&Ze(B,y),Ze(()=>{g.isUnmounted=!0},y)},J=(g,y,_,P=!1,T=!1,O=0)=>{for(let H=O;H<g.length;H++)Ge(g[H],y,_,P,T)},A=g=>{if(g.shapeFlag&6)return A(g.component.subTree);if(g.shapeFlag&128)return g.suspense.next();const y=d(g.anchor||g.el),_=y&&y[Qf];return _?d(_):y};let F=!1;const j=(g,y,_)=>{let P;g==null?y._vnode&&(Ge(y._vnode,null,null,!0),P=y._vnode.component):v(y._vnode||null,g,y,null,null,null,_),y._vnode=g,F||(F=!0,Yi(P),sc(),F=!1)},z={p:v,um:Ge,m:at,r:pt,mt:oe,mc:W,pc:le,pbc:q,n:A,o:e};return{render:j,hydrate:void 0,createApp:Cd(j)}}function ro({type:e,props:t},n){return n==="svg"&&e==="foreignObject"||n==="mathml"&&e==="annotation-xml"&&t&&t.encoding&&t.encoding.includes("html")?void 0:n}function gn({effect:e,job:t},n){n?(e.flags|=32,t.flags|=4):(e.flags&=-33,t.flags&=-5)}function Gd(e,t){return(!e||e&&!e.pendingBranch)&&t&&!t.persisted}function Sc(e,t,n=!1){const s=e.children,r=t.children;if(Y(s)&&Y(r))for(let o=0;o<s.length;o++){const i=s[o];let l=r[o];l.shapeFlag&1&&!l.dynamicChildren&&((l.patchFlag<=0||l.patchFlag===32)&&(l=r[o]=Wt(r[o]),l.el=i.el),!n&&l.patchFlag!==-2&&Sc(i,l)),l.type===Gr&&(l.patchFlag===-1&&(l=r[o]=Wt(l)),l.el=i.el),l.type===un&&!l.el&&(l.el=i.el)}}function jd(e){const t=e.slice(),n=[0];let s,r,o,i,l;const a=e.length;for(s=0;s<a;s++){const c=e[s];if(c!==0){if(r=n[n.length-1],e[r]<c){t[s]=r,n.push(s);continue}for(o=0,i=n.length-1;o<i;)l=o+i>>1,e[n[l]]<c?o=l+1:i=l;c<e[n[o]]&&(o>0&&(t[s]=n[o-1]),n[o]=s)}}for(o=n.length,i=n[o-1];o-- >0;)n[o]=i,i=t[i];return n}function Ec(e){const t=e.subTree.component;if(t)return t.asyncDep&&!t.asyncResolved?t:Ec(t)}function al(e){if(e)for(let t=0;t<e.length;t++)e[t].flags|=8}function Ac(e){if(e.placeholder)return e.placeholder;const t=e.component;return t?Ac(t.subTree):null}const Rc=e=>e.__isSuspense;function Fd(e,t){t&&t.pendingBranch?Y(e)?t.effects.push(...e):t.effects.push(e):Kf(e)}const Z=Symbol.for("v-fgt"),Gr=Symbol.for("v-txt"),un=Symbol.for("v-cmt"),Ys=Symbol.for("v-stc"),ms=[];let ot=null;function C(e=!1){ms.push(ot=e?null:[])}function Bd(){ms.pop(),ot=ms[ms.length-1]||null}let xs=1;function ur(e,t=!1){xs+=e,e<0&&ot&&t&&(ot.hasOnce=!0)}function $c(e){return e.dynamicChildren=xs>0?ot||jn:null,Bd(),xs>0&&ot&&ot.push(e),e}function S(e,t,n,s,r,o){return $c(p(e,t,n,s,r,o,!0))}function fr(e,t,n,s,r){return $c(_e(e,t,n,s,r,!0))}function dr(e){return e?e.__v_isVNode===!0:!1}function rs(e,t){return e.type===t.type&&e.key===t.key}const Ic=({key:e})=>e??null,Qs=({ref:e,ref_key:t,ref_for:n})=>(typeof e=="number"&&(e=""+e),e!=null?Pe(e)||We(e)||ne(e)?{i:rt,r:e,k:t,f:!!n}:e:null);function p(e,t=null,n=null,s=0,r=null,o=e===Z?0:1,i=!1,l=!1){const a={__v_isVNode:!0,__v_skip:!0,type:e,props:t,key:t&&Ic(t),ref:t&&Qs(t),scopeId:oc,slotScopeIds:null,children:n,component:null,suspense:null,ssContent:null,ssFallback:null,dirs:null,transition:null,el:null,anchor:null,target:null,targetStart:null,targetAnchor:null,staticCount:0,shapeFlag:o,patchFlag:s,dynamicProps:r,dynamicChildren:null,appContext:null,ctx:rt};return l?(xi(a,n),o&128&&e.normalize(a)):n&&(a.shapeFlag|=Pe(n)?8:16),xs>0&&!i&&ot&&(a.patchFlag>0||o&6)&&a.patchFlag!==32&&ot.push(a),a}const _e=Ud;function Ud(e,t=null,n=null,s=0,r=null,o=!1){if((!e||e===hd)&&(e=un),dr(e)){const l=zn(e,t,!0);return n&&xi(l,n),xs>0&&!o&&ot&&(l.shapeFlag&6?ot[ot.indexOf(e)]=l:ot.push(l)),l.patchFlag=-2,l}if(th(e)&&(e=e.__vccOpts),t){t=Hd(t);let{class:l,style:a}=t;l&&!Pe(l)&&(t.class=Ae(l)),we(a)&&(mi(a)&&!Y(a)&&(a=je({},a)),t.style=Sn(a))}const i=Pe(e)?1:Rc(e)?128:Zf(e)?64:we(e)?4:ne(e)?2:0;return p(e,t,n,s,r,i,o,!0)}function Hd(e){return e?mi(e)||_c(e)?je({},e):e:null}function zn(e,t,n=!1,s=!1){const{props:r,ref:o,patchFlag:i,children:l,transition:a}=e,c=t?Vd(r||{},t):r,u={__v_isVNode:!0,__v_skip:!0,type:e.type,props:c,key:c&&Ic(c),ref:t&&t.ref?n&&o?Y(o)?o.concat(Qs(t)):[o,Qs(t)]:Qs(t):o,scopeId:e.scopeId,slotScopeIds:e.slotScopeIds,children:l,target:e.target,targetStart:e.targetStart,targetAnchor:e.targetAnchor,staticCount:e.staticCount,shapeFlag:e.shapeFlag,patchFlag:t&&e.type!==Z?i===-1?16:i|16:i,dynamicProps:e.dynamicProps,dynamicChildren:e.dynamicChildren,appContext:e.appContext,dirs:e.dirs,transition:a,component:e.component,suspense:e.suspense,ssContent:e.ssContent&&zn(e.ssContent),ssFallback:e.ssFallback&&zn(e.ssFallback),placeholder:e.placeholder,el:e.el,anchor:e.anchor,ctx:e.ctx,ce:e.ce};return a&&s&&bi(u,a.clone(u)),u}function hr(e=" ",t=0){return _e(Gr,null,e,t)}function Wd(e,t){const n=_e(Ys,null,e);return n.staticCount=t,n}function ie(e="",t=!1){return t?(C(),fr(un,null,e)):_e(un,null,e)}function Pt(e){return e==null||typeof e=="boolean"?_e(un):Y(e)?_e(Z,null,e.slice()):dr(e)?Wt(e):_e(Gr,null,String(e))}function Wt(e){return e.el===null&&e.patchFlag!==-1||e.memo?e:zn(e)}function xi(e,t){let n=0;const{shapeFlag:s}=e;if(t==null)t=null;else if(Y(t))n=16;else if(typeof t=="object")if(s&65){const r=t.default;r&&(r._c&&(r._d=!1),xi(e,r()),r._c&&(r._d=!0));return}else{n=32;const r=t._;!r&&!_c(t)?t._ctx=rt:r===3&&rt&&(rt.slots._===1?t._=1:(t._=2,e.patchFlag|=1024))}else ne(t)?(t={default:t,_ctx:rt},n=32):(t=String(t),s&64?(n=16,t=[hr(t)]):n=8);e.children=t,e.shapeFlag|=n}function Vd(...e){const t={};for(let n=0;n<e.length;n++){const s=e[n];for(const r in s)if(r==="class")t.class!==s.class&&(t.class=Ae([t.class,s.class]));else if(r==="style")t.style=Sn([t.style,s.style]);else if(Rr(r)){const o=t[r],i=s[r];i&&o!==i&&!(Y(o)&&o.includes(i))&&(t[r]=o?[].concat(o,i):i)}else r!==""&&(t[r]=s[r])}return t}function Rt(e,t,n,s=null){Lt(e,t,7,[n,s])}const qd=pc();let zd=0;function Kd(e,t,n){const s=e.type,r=(t?t.appContext:e.appContext)||qd,o={uid:zd++,vnode:e,type:s,parent:t,appContext:r,root:null,next:null,subTree:null,effect:null,update:null,job:null,scope:new vf(!0),render:null,proxy:null,exposed:null,exposeProxy:null,withProxy:null,provides:t?t.provides:Object.create(r.provides),ids:t?t.ids:["",0,0],accessCache:null,renderCache:[],components:null,directives:null,propsOptions:wc(s,r),emitsOptions:gc(s,r),emit:null,emitted:null,propsDefaults:Ce,inheritAttrs:s.inheritAttrs,ctx:Ce,data:Ce,props:Ce,attrs:Ce,slots:Ce,refs:Ce,setupState:Ce,setupContext:null,suspense:n,suspenseId:n?n.pendingId:0,asyncDep:null,asyncResolved:!1,isMounted:!1,isUnmounted:!1,isDeactivated:!1,bc:null,c:null,bm:null,m:null,bu:null,u:null,um:null,bum:null,da:null,a:null,rtg:null,rtc:null,ec:null,sp:null};return o.ctx={_:o},o.root=t?t.root:o,o.emit=kd.bind(null,o),e.ce&&e.ce(o),o}let Ue=null;const Xd=()=>Ue||rt;let pr,Mo;{const e=Or(),t=(n,s)=>{let r;return(r=e[n])||(r=e[n]=[]),r.push(s),o=>{r.length>1?r.forEach(i=>i(o)):r[0](o)}};pr=t("__VUE_INSTANCE_SETTERS__",n=>Ue=n),Mo=t("__VUE_SSR_SETTERS__",n=>ks=n)}const Ms=e=>{const t=Ue;return pr(e),e.scope.on(),()=>{e.scope.off(),pr(t)}},cl=()=>{Ue&&Ue.scope.off(),pr(null)};function Nc(e){return e.vnode.shapeFlag&4}let ks=!1;function Jd(e,t=!1,n=!1){t&&Mo(t);const{props:s,children:r}=e.vnode,o=Nc(e);Id(e,s,o,t),Td(e,r,n||t);const i=o?Yd(e,t):void 0;return t&&Mo(!1),i}function Yd(e,t){const n=e.type;e.accessCache=Object.create(null),e.proxy=new Proxy(e.ctx,gd);const{setup:s}=n;if(s){Jt();const r=e.setupContext=s.length>1?Zd(e):null,o=Ms(e),i=Ts(s,e,0,[e.props,r]),l=Na(i);if(Yt(),o(),(l||e.sp)&&!ps(e)&&cc(e),l){if(i.then(cl,cl),t)return i.then(a=>{ul(e,a)}).catch(a=>{Mr(a,e,0)});e.asyncDep=i}else ul(e,i)}else Pc(e)}function ul(e,t,n){ne(t)?e.type.__ssrInlineRender?e.ssrRender=t:e.render=t:we(t)&&(e.setupState=ec(t)),Pc(e)}function Pc(e,t,n){const s=e.type;e.render||(e.render=s.render||Tt);{const r=Ms(e);Jt();try{md(e)}finally{Yt(),r()}}}const Qd={get(e,t){return Be(e,"get",""),e[t]}};function Zd(e){const t=n=>{e.exposed=n||{}};return{attrs:new Proxy(e.attrs,Qd),slots:e.slots,emit:e.emit,expose:t}}function jr(e){return e.exposed?e.exposeProxy||(e.exposeProxy=new Proxy(ec(Gf(e.exposed)),{get(t,n){if(n in t)return t[n];if(n in gs)return gs[n](e)},has(t,n){return n in t||n in gs}})):e.proxy}function eh(e,t=!0){return ne(e)?e.displayName||e.name:e.name||t&&e.__name}function th(e){return ne(e)&&"__vccOpts"in e}const de=(e,t)=>Hf(e,t,ks);function Oc(e,t,n){try{ur(-1);const s=arguments.length;return s===2?we(t)&&!Y(t)?dr(t)?_e(e,null,[t]):_e(e,t):_e(e,null,t):(s>3?n=Array.prototype.slice.call(arguments,2):s===3&&dr(n)&&(n=[n]),_e(e,t,n))}finally{ur(1)}}const nh="3.5.30";/**
14
+ * @vue/runtime-dom v3.5.30
15
+ * (c) 2018-present Yuxi (Evan) You and Vue contributors
16
+ * @license MIT
17
+ **/let Lo;const fl=typeof window<"u"&&window.trustedTypes;if(fl)try{Lo=fl.createPolicy("vue",{createHTML:e=>e})}catch{}const Tc=Lo?e=>Lo.createHTML(e):e=>e,sh="http://www.w3.org/2000/svg",rh="http://www.w3.org/1998/Math/MathML",Ht=typeof document<"u"?document:null,dl=Ht&&Ht.createElement("template"),oh={insert:(e,t,n)=>{t.insertBefore(e,n||null)},remove:e=>{const t=e.parentNode;t&&t.removeChild(e)},createElement:(e,t,n,s)=>{const r=t==="svg"?Ht.createElementNS(sh,e):t==="mathml"?Ht.createElementNS(rh,e):n?Ht.createElement(e,{is:n}):Ht.createElement(e);return e==="select"&&s&&s.multiple!=null&&r.setAttribute("multiple",s.multiple),r},createText:e=>Ht.createTextNode(e),createComment:e=>Ht.createComment(e),setText:(e,t)=>{e.nodeValue=t},setElementText:(e,t)=>{e.textContent=t},parentNode:e=>e.parentNode,nextSibling:e=>e.nextSibling,querySelector:e=>Ht.querySelector(e),setScopeId(e,t){e.setAttribute(t,"")},insertStaticContent(e,t,n,s,r,o){const i=n?n.previousSibling:t.lastChild;if(r&&(r===o||r.nextSibling))for(;t.insertBefore(r.cloneNode(!0),n),!(r===o||!(r=r.nextSibling)););else{dl.innerHTML=Tc(s==="svg"?`<svg>${e}</svg>`:s==="mathml"?`<math>${e}</math>`:e);const l=dl.content;if(s==="svg"||s==="mathml"){const a=l.firstChild;for(;a.firstChild;)l.appendChild(a.firstChild);l.removeChild(a)}t.insertBefore(l,n)}return[i?i.nextSibling:t.firstChild,n?n.previousSibling:t.lastChild]}},ih=Symbol("_vtc");function lh(e,t,n){const s=e[ih];s&&(t=(t?[t,...s]:[...s]).join(" ")),t==null?e.removeAttribute("class"):n?e.setAttribute("class",t):e.className=t}const hl=Symbol("_vod"),ah=Symbol("_vsh"),ch=Symbol(""),uh=/(?:^|;)\s*display\s*:/;function fh(e,t,n){const s=e.style,r=Pe(n);let o=!1;if(n&&!r){if(t)if(Pe(t))for(const i of t.split(";")){const l=i.slice(0,i.indexOf(":")).trim();n[l]==null&&Zs(s,l,"")}else for(const i in t)n[i]==null&&Zs(s,i,"");for(const i in n)i==="display"&&(o=!0),Zs(s,i,n[i])}else if(r){if(t!==n){const i=s[ch];i&&(n+=";"+i),s.cssText=n,o=uh.test(n)}}else t&&e.removeAttribute("style");hl in e&&(e[hl]=o?s.display:"",e[ah]&&(s.display="none"))}const pl=/\s*!important$/;function Zs(e,t,n){if(Y(n))n.forEach(s=>Zs(e,t,s));else if(n==null&&(n=""),t.startsWith("--"))e.setProperty(t,n);else{const s=dh(e,t);pl.test(n)?e.setProperty($n(s),n.replace(pl,""),"important"):e[s]=n}}const gl=["Webkit","Moz","ms"],oo={};function dh(e,t){const n=oo[t];if(n)return n;let s=Je(t);if(s!=="filter"&&s in e)return oo[t]=s;s=Nr(s);for(let r=0;r<gl.length;r++){const o=gl[r]+s;if(o in e)return oo[t]=o}return t}const ml="http://www.w3.org/1999/xlink";function yl(e,t,n,s,r,o=gf(t)){s&&t.startsWith("xlink:")?n==null?e.removeAttributeNS(ml,t.slice(6,t.length)):e.setAttributeNS(ml,t,n):n==null||o&&!Ma(n)?e.removeAttribute(t):e.setAttribute(t,o?"":Mt(n)?String(n):n)}function vl(e,t,n,s,r){if(t==="innerHTML"||t==="textContent"){n!=null&&(e[t]=t==="innerHTML"?Tc(n):n);return}const o=e.tagName;if(t==="value"&&o!=="PROGRESS"&&!o.includes("-")){const l=o==="OPTION"?e.getAttribute("value")||"":e.value,a=n==null?e.type==="checkbox"?"on":"":String(n);(l!==a||!("_value"in e))&&(e.value=a),n==null&&e.removeAttribute(t),e._value=n;return}let i=!1;if(n===""||n==null){const l=typeof e[t];l==="boolean"?n=Ma(n):n==null&&l==="string"?(n="",i=!0):l==="number"&&(n=0,i=!0)}try{e[t]=n}catch{}i&&e.removeAttribute(r||t)}function vn(e,t,n,s){e.addEventListener(t,n,s)}function hh(e,t,n,s){e.removeEventListener(t,n,s)}const _l=Symbol("_vei");function ph(e,t,n,s,r=null){const o=e[_l]||(e[_l]={}),i=o[t];if(s&&i)i.value=s;else{const[l,a]=gh(t);if(s){const c=o[t]=vh(s,r);vn(e,l,c,a)}else i&&(hh(e,l,i,a),o[t]=void 0)}}const bl=/(?:Once|Passive|Capture)$/;function gh(e){let t;if(bl.test(e)){t={};let s;for(;s=e.match(bl);)e=e.slice(0,e.length-s[0].length),t[s[0].toLowerCase()]=!0}return[e[2]===":"?e.slice(3):$n(e.slice(2)),t]}let io=0;const mh=Promise.resolve(),yh=()=>io||(mh.then(()=>io=0),io=Date.now());function vh(e,t){const n=s=>{if(!s._vts)s._vts=Date.now();else if(s._vts<=n.attached)return;Lt(_h(s,n.value),t,5,[s])};return n.value=e,n.attached=yh(),n}function _h(e,t){if(Y(t)){const n=e.stopImmediatePropagation;return e.stopImmediatePropagation=()=>{n.call(e),e._stopped=!0},t.map(s=>r=>!r._stopped&&s&&s(r))}else return t}const wl=e=>e.charCodeAt(0)===111&&e.charCodeAt(1)===110&&e.charCodeAt(2)>96&&e.charCodeAt(2)<123,bh=(e,t,n,s,r,o)=>{const i=r==="svg";t==="class"?lh(e,s,i):t==="style"?fh(e,n,s):Rr(t)?li(t)||ph(e,t,n,s,o):(t[0]==="."?(t=t.slice(1),!0):t[0]==="^"?(t=t.slice(1),!1):wh(e,t,s,i))?(vl(e,t,s),!e.tagName.includes("-")&&(t==="value"||t==="checked"||t==="selected")&&yl(e,t,s,i,o,t!=="value")):e._isVueCE&&(Ch(e,t)||e._def.__asyncLoader&&(/[A-Z]/.test(t)||!Pe(s)))?vl(e,Je(t),s,o,t):(t==="true-value"?e._trueValue=s:t==="false-value"&&(e._falseValue=s),yl(e,t,s,i))};function wh(e,t,n,s){if(s)return!!(t==="innerHTML"||t==="textContent"||t in e&&wl(t)&&ne(n));if(t==="spellcheck"||t==="draggable"||t==="translate"||t==="autocorrect"||t==="sandbox"&&e.tagName==="IFRAME"||t==="form"||t==="list"&&e.tagName==="INPUT"||t==="type"&&e.tagName==="TEXTAREA")return!1;if(t==="width"||t==="height"){const r=e.tagName;if(r==="IMG"||r==="VIDEO"||r==="CANVAS"||r==="SOURCE")return!1}return wl(t)&&Pe(n)?!1:t in e}function Ch(e,t){const n=e._def.props;if(!n)return!1;const s=Je(t);return Array.isArray(n)?n.some(r=>Je(r)===s):Object.keys(n).some(r=>Je(r)===s)}const gr=e=>{const t=e.props["onUpdate:modelValue"]||!1;return Y(t)?n=>Xs(t,n):t};function xh(e){e.target.composing=!0}function Cl(e){const t=e.target;t.composing&&(t.composing=!1,t.dispatchEvent(new Event("input")))}const Hn=Symbol("_assign");function xl(e,t,n){return t&&(e=e.trim()),n&&(e=Pr(e)),e}const kh={created(e,{modifiers:{lazy:t,trim:n,number:s}},r){e[Hn]=gr(r);const o=s||r.props&&r.props.type==="number";vn(e,t?"change":"input",i=>{i.target.composing||e[Hn](xl(e.value,n,o))}),(n||o)&&vn(e,"change",()=>{e.value=xl(e.value,n,o)}),t||(vn(e,"compositionstart",xh),vn(e,"compositionend",Cl),vn(e,"change",Cl))},mounted(e,{value:t}){e.value=t??""},beforeUpdate(e,{value:t,oldValue:n,modifiers:{lazy:s,trim:r,number:o}},i){if(e[Hn]=gr(i),e.composing)return;const l=(o||e.type==="number")&&!/^0\d/.test(e.value)?Pr(e.value):e.value,a=t??"";l!==a&&(document.activeElement===e&&e.type!=="range"&&(s&&t===n||r&&e.value.trim()===a)||(e.value=a))}},Do={deep:!0,created(e,{value:t,modifiers:{number:n}},s){const r=$r(t);vn(e,"change",()=>{const o=Array.prototype.filter.call(e.options,i=>i.selected).map(i=>n?Pr(mr(i)):mr(i));e[Hn](e.multiple?r?new Set(o):o:o[0]),e._assigning=!0,yi(()=>{e._assigning=!1})}),e[Hn]=gr(s)},mounted(e,{value:t}){kl(e,t)},beforeUpdate(e,t,n){e[Hn]=gr(n)},updated(e,{value:t}){e._assigning||kl(e,t)}};function kl(e,t){const n=e.multiple,s=Y(t);if(!(n&&!s&&!$r(t))){for(let r=0,o=e.options.length;r<o;r++){const i=e.options[r],l=mr(i);if(n)if(s){const a=typeof l;a==="string"||a==="number"?i.selected=t.some(c=>String(c)===String(l)):i.selected=yf(t,l)>-1}else i.selected=t.has(l);else if(Os(mr(i),t)){e.selectedIndex!==r&&(e.selectedIndex=r);return}}!n&&e.selectedIndex!==-1&&(e.selectedIndex=-1)}}function mr(e){return"_value"in e?e._value:e.value}const Sh=["ctrl","shift","alt","meta"],Eh={stop:e=>e.stopPropagation(),prevent:e=>e.preventDefault(),self:e=>e.target!==e.currentTarget,ctrl:e=>!e.ctrlKey,shift:e=>!e.shiftKey,alt:e=>!e.altKey,meta:e=>!e.metaKey,left:e=>"button"in e&&e.button!==0,middle:e=>"button"in e&&e.button!==1,right:e=>"button"in e&&e.button!==2,exact:(e,t)=>Sh.some(n=>e[`${n}Key`]&&!t.includes(n))},as=(e,t)=>{if(!e)return e;const n=e._withMods||(e._withMods={}),s=t.join(".");return n[s]||(n[s]=((r,...o)=>{for(let i=0;i<t.length;i++){const l=Eh[t[i]];if(l&&l(r,t))return}return e(r,...o)}))},Ah=je({patchProp:bh},oh);let Sl;function Rh(){return Sl||(Sl=Ld(Ah))}const $h=((...e)=>{const t=Rh().createApp(...e),{mount:n}=t;return t.mount=s=>{const r=Nh(s);if(!r)return;const o=t._component;!ne(o)&&!o.render&&!o.template&&(o.template=r.innerHTML),r.nodeType===1&&(r.textContent="");const i=n(r,!1,Ih(r));return r instanceof Element&&(r.removeAttribute("v-cloak"),r.setAttribute("data-v-app","")),i},t});function Ih(e){if(e instanceof SVGElement)return"svg";if(typeof MathMLElement=="function"&&e instanceof MathMLElement)return"mathml"}function Nh(e){return Pe(e)?document.querySelector(e):e}/*!
18
+ * vue-router v4.6.4
19
+ * (c) 2025 Eduardo San Martin Morote
20
+ * @license MIT
21
+ */const Mn=typeof document<"u";function Mc(e){return typeof e=="object"||"displayName"in e||"props"in e||"__vccOpts"in e}function Ph(e){return e.__esModule||e[Symbol.toStringTag]==="Module"||e.default&&Mc(e.default)}const me=Object.assign;function lo(e,t){const n={};for(const s in t){const r=t[s];n[s]=xt(r)?r.map(e):e(r)}return n}const ys=()=>{},xt=Array.isArray;function El(e,t){const n={};for(const s in e)n[s]=s in t?t[s]:e[s];return n}const Lc=/#/g,Oh=/&/g,Th=/\//g,Mh=/=/g,Lh=/\?/g,Dc=/\+/g,Dh=/%5B/g,Gh=/%5D/g,Gc=/%5E/g,jh=/%60/g,jc=/%7B/g,Fh=/%7C/g,Fc=/%7D/g,Bh=/%20/g;function ki(e){return e==null?"":encodeURI(""+e).replace(Fh,"|").replace(Dh,"[").replace(Gh,"]")}function Uh(e){return ki(e).replace(jc,"{").replace(Fc,"}").replace(Gc,"^")}function Go(e){return ki(e).replace(Dc,"%2B").replace(Bh,"+").replace(Lc,"%23").replace(Oh,"%26").replace(jh,"`").replace(jc,"{").replace(Fc,"}").replace(Gc,"^")}function Hh(e){return Go(e).replace(Mh,"%3D")}function Wh(e){return ki(e).replace(Lc,"%23").replace(Lh,"%3F")}function Vh(e){return Wh(e).replace(Th,"%2F")}function Ss(e){if(e==null)return null;try{return decodeURIComponent(""+e)}catch{}return""+e}const qh=/\/$/,zh=e=>e.replace(qh,"");function ao(e,t,n="/"){let s,r={},o="",i="";const l=t.indexOf("#");let a=t.indexOf("?");return a=l>=0&&a>l?-1:a,a>=0&&(s=t.slice(0,a),o=t.slice(a,l>0?l:t.length),r=e(o.slice(1))),l>=0&&(s=s||t.slice(0,l),i=t.slice(l,t.length)),s=Yh(s??t,n),{fullPath:s+o+i,path:s,query:r,hash:Ss(i)}}function Kh(e,t){const n=t.query?e(t.query):"";return t.path+(n&&"?")+n+(t.hash||"")}function Al(e,t){return!t||!e.toLowerCase().startsWith(t.toLowerCase())?e:e.slice(t.length)||"/"}function Xh(e,t,n){const s=t.matched.length-1,r=n.matched.length-1;return s>-1&&s===r&&Kn(t.matched[s],n.matched[r])&&Bc(t.params,n.params)&&e(t.query)===e(n.query)&&t.hash===n.hash}function Kn(e,t){return(e.aliasOf||e)===(t.aliasOf||t)}function Bc(e,t){if(Object.keys(e).length!==Object.keys(t).length)return!1;for(var n in e)if(!Jh(e[n],t[n]))return!1;return!0}function Jh(e,t){return xt(e)?Rl(e,t):xt(t)?Rl(t,e):(e==null?void 0:e.valueOf())===(t==null?void 0:t.valueOf())}function Rl(e,t){return xt(t)?e.length===t.length&&e.every((n,s)=>n===t[s]):e.length===1&&e[0]===t}function Yh(e,t){if(e.startsWith("/"))return e;if(!e)return t;const n=t.split("/"),s=e.split("/"),r=s[s.length-1];(r===".."||r===".")&&s.push("");let o=n.length-1,i,l;for(i=0;i<s.length;i++)if(l=s[i],l!==".")if(l==="..")o>1&&o--;else break;return n.slice(0,o).join("/")+"/"+s.slice(i).join("/")}const en={path:"/",name:void 0,params:{},query:{},hash:"",fullPath:"/",matched:[],meta:{},redirectedFrom:void 0};let jo=(function(e){return e.pop="pop",e.push="push",e})({}),co=(function(e){return e.back="back",e.forward="forward",e.unknown="",e})({});function Qh(e){if(!e)if(Mn){const t=document.querySelector("base");e=t&&t.getAttribute("href")||"/",e=e.replace(/^\w+:\/\/[^\/]+/,"")}else e="/";return e[0]!=="/"&&e[0]!=="#"&&(e="/"+e),zh(e)}const Zh=/^[^#]+#/;function ep(e,t){return e.replace(Zh,"#")+t}function tp(e,t){const n=document.documentElement.getBoundingClientRect(),s=e.getBoundingClientRect();return{behavior:t.behavior,left:s.left-n.left-(t.left||0),top:s.top-n.top-(t.top||0)}}const Fr=()=>({left:window.scrollX,top:window.scrollY});function np(e){let t;if("el"in e){const n=e.el,s=typeof n=="string"&&n.startsWith("#"),r=typeof n=="string"?s?document.getElementById(n.slice(1)):document.querySelector(n):n;if(!r)return;t=tp(r,e)}else t=e;"scrollBehavior"in document.documentElement.style?window.scrollTo(t):window.scrollTo(t.left!=null?t.left:window.scrollX,t.top!=null?t.top:window.scrollY)}function $l(e,t){return(history.state?history.state.position-t:-1)+e}const Fo=new Map;function sp(e,t){Fo.set(e,t)}function rp(e){const t=Fo.get(e);return Fo.delete(e),t}function op(e){return typeof e=="string"||e&&typeof e=="object"}function Uc(e){return typeof e=="string"||typeof e=="symbol"}let Re=(function(e){return e[e.MATCHER_NOT_FOUND=1]="MATCHER_NOT_FOUND",e[e.NAVIGATION_GUARD_REDIRECT=2]="NAVIGATION_GUARD_REDIRECT",e[e.NAVIGATION_ABORTED=4]="NAVIGATION_ABORTED",e[e.NAVIGATION_CANCELLED=8]="NAVIGATION_CANCELLED",e[e.NAVIGATION_DUPLICATED=16]="NAVIGATION_DUPLICATED",e})({});const Hc=Symbol("");Re.MATCHER_NOT_FOUND+"",Re.NAVIGATION_GUARD_REDIRECT+"",Re.NAVIGATION_ABORTED+"",Re.NAVIGATION_CANCELLED+"",Re.NAVIGATION_DUPLICATED+"";function Xn(e,t){return me(new Error,{type:e,[Hc]:!0},t)}function Ft(e,t){return e instanceof Error&&Hc in e&&(t==null||!!(e.type&t))}const ip=["params","query","hash"];function lp(e){if(typeof e=="string")return e;if(e.path!=null)return e.path;const t={};for(const n of ip)n in e&&(t[n]=e[n]);return JSON.stringify(t,null,2)}function ap(e){const t={};if(e===""||e==="?")return t;const n=(e[0]==="?"?e.slice(1):e).split("&");for(let s=0;s<n.length;++s){const r=n[s].replace(Dc," "),o=r.indexOf("="),i=Ss(o<0?r:r.slice(0,o)),l=o<0?null:Ss(r.slice(o+1));if(i in t){let a=t[i];xt(a)||(a=t[i]=[a]),a.push(l)}else t[i]=l}return t}function Il(e){let t="";for(let n in e){const s=e[n];if(n=Hh(n),s==null){s!==void 0&&(t+=(t.length?"&":"")+n);continue}(xt(s)?s.map(r=>r&&Go(r)):[s&&Go(s)]).forEach(r=>{r!==void 0&&(t+=(t.length?"&":"")+n,r!=null&&(t+="="+r))})}return t}function cp(e){const t={};for(const n in e){const s=e[n];s!==void 0&&(t[n]=xt(s)?s.map(r=>r==null?null:""+r):s==null?s:""+s)}return t}const up=Symbol(""),Nl=Symbol(""),Br=Symbol(""),Si=Symbol(""),Bo=Symbol("");function os(){let e=[];function t(s){return e.push(s),()=>{const r=e.indexOf(s);r>-1&&e.splice(r,1)}}function n(){e=[]}return{add:t,list:()=>e.slice(),reset:n}}function rn(e,t,n,s,r,o=i=>i()){const i=s&&(s.enterCallbacks[r]=s.enterCallbacks[r]||[]);return()=>new Promise((l,a)=>{const c=d=>{d===!1?a(Xn(Re.NAVIGATION_ABORTED,{from:n,to:t})):d instanceof Error?a(d):op(d)?a(Xn(Re.NAVIGATION_GUARD_REDIRECT,{from:t,to:d})):(i&&s.enterCallbacks[r]===i&&typeof d=="function"&&i.push(d),l())},u=o(()=>e.call(s&&s.instances[r],t,n,c));let f=Promise.resolve(u);e.length<3&&(f=f.then(c)),f.catch(d=>a(d))})}function uo(e,t,n,s,r=o=>o()){const o=[];for(const i of e)for(const l in i.components){let a=i.components[l];if(!(t!=="beforeRouteEnter"&&!i.instances[l]))if(Mc(a)){const c=(a.__vccOpts||a)[t];c&&o.push(rn(c,n,s,i,l,r))}else{let c=a();o.push(()=>c.then(u=>{if(!u)throw new Error(`Couldn't resolve component "${l}" at "${i.path}"`);const f=Ph(u)?u.default:u;i.mods[l]=u,i.components[l]=f;const d=(f.__vccOpts||f)[t];return d&&rn(d,n,s,i,l,r)()}))}}return o}function fp(e,t){const n=[],s=[],r=[],o=Math.max(t.matched.length,e.matched.length);for(let i=0;i<o;i++){const l=t.matched[i];l&&(e.matched.find(c=>Kn(c,l))?s.push(l):n.push(l));const a=e.matched[i];a&&(t.matched.find(c=>Kn(c,a))||r.push(a))}return[n,s,r]}/*!
22
+ * vue-router v4.6.4
23
+ * (c) 2025 Eduardo San Martin Morote
24
+ * @license MIT
25
+ */let dp=()=>location.protocol+"//"+location.host;function Wc(e,t){const{pathname:n,search:s,hash:r}=t,o=e.indexOf("#");if(o>-1){let i=r.includes(e.slice(o))?e.slice(o).length:1,l=r.slice(i);return l[0]!=="/"&&(l="/"+l),Al(l,"")}return Al(n,e)+s+r}function hp(e,t,n,s){let r=[],o=[],i=null;const l=({state:d})=>{const h=Wc(e,location),m=n.value,v=t.value;let x=0;if(d){if(n.value=h,t.value=d,i&&i===m){i=null;return}x=v?d.position-v.position:0}else s(h);r.forEach(k=>{k(n.value,m,{delta:x,type:jo.pop,direction:x?x>0?co.forward:co.back:co.unknown})})};function a(){i=n.value}function c(d){r.push(d);const h=()=>{const m=r.indexOf(d);m>-1&&r.splice(m,1)};return o.push(h),h}function u(){if(document.visibilityState==="hidden"){const{history:d}=window;if(!d.state)return;d.replaceState(me({},d.state,{scroll:Fr()}),"")}}function f(){for(const d of o)d();o=[],window.removeEventListener("popstate",l),window.removeEventListener("pagehide",u),document.removeEventListener("visibilitychange",u)}return window.addEventListener("popstate",l),window.addEventListener("pagehide",u),document.addEventListener("visibilitychange",u),{pauseListeners:a,listen:c,destroy:f}}function Pl(e,t,n,s=!1,r=!1){return{back:e,current:t,forward:n,replaced:s,position:window.history.length,scroll:r?Fr():null}}function pp(e){const{history:t,location:n}=window,s={value:Wc(e,n)},r={value:t.state};r.value||o(s.value,{back:null,current:s.value,forward:null,position:t.length-1,replaced:!0,scroll:null},!0);function o(a,c,u){const f=e.indexOf("#"),d=f>-1?(n.host&&document.querySelector("base")?e:e.slice(f))+a:dp()+e+a;try{t[u?"replaceState":"pushState"](c,"",d),r.value=c}catch(h){console.error(h),n[u?"replace":"assign"](d)}}function i(a,c){o(a,me({},t.state,Pl(r.value.back,a,r.value.forward,!0),c,{position:r.value.position}),!0),s.value=a}function l(a,c){const u=me({},r.value,t.state,{forward:a,scroll:Fr()});o(u.current,u,!0),o(a,me({},Pl(s.value,a,null),{position:u.position+1},c),!1),s.value=a}return{location:s,state:r,push:l,replace:i}}function gp(e){e=Qh(e);const t=pp(e),n=hp(e,t.state,t.location,t.replace);function s(o,i=!0){i||n.pauseListeners(),history.go(o)}const r=me({location:"",base:e,go:s,createHref:ep.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 mp(e){return e=location.host?e||location.pathname+location.search:"",e.includes("#")||(e+="#"),gp(e)}let bn=(function(e){return e[e.Static=0]="Static",e[e.Param=1]="Param",e[e.Group=2]="Group",e})({});var Oe=(function(e){return e[e.Static=0]="Static",e[e.Param=1]="Param",e[e.ParamRegExp=2]="ParamRegExp",e[e.ParamRegExpEnd=3]="ParamRegExpEnd",e[e.EscapeNext=4]="EscapeNext",e})(Oe||{});const yp={type:bn.Static,value:""},vp=/[a-zA-Z0-9_]/;function _p(e){if(!e)return[[]];if(e==="/")return[[yp]];if(!e.startsWith("/"))throw new Error(`Invalid path "${e}"`);function t(h){throw new Error(`ERR (${n})/"${c}": ${h}`)}let n=Oe.Static,s=n;const r=[];let o;function i(){o&&r.push(o),o=[]}let l=0,a,c="",u="";function f(){c&&(n===Oe.Static?o.push({type:bn.Static,value:c}):n===Oe.Param||n===Oe.ParamRegExp||n===Oe.ParamRegExpEnd?(o.length>1&&(a==="*"||a==="+")&&t(`A repeatable param (${c}) must be alone in its segment. eg: '/:ids+.`),o.push({type:bn.Param,value:c,regexp:u,repeatable:a==="*"||a==="+",optional:a==="*"||a==="?"})):t("Invalid state to consume buffer"),c="")}function d(){c+=a}for(;l<e.length;){if(a=e[l++],a==="\\"&&n!==Oe.ParamRegExp){s=n,n=Oe.EscapeNext;continue}switch(n){case Oe.Static:a==="/"?(c&&f(),i()):a===":"?(f(),n=Oe.Param):d();break;case Oe.EscapeNext:d(),n=s;break;case Oe.Param:a==="("?n=Oe.ParamRegExp:vp.test(a)?d():(f(),n=Oe.Static,a!=="*"&&a!=="?"&&a!=="+"&&l--);break;case Oe.ParamRegExp:a===")"?u[u.length-1]=="\\"?u=u.slice(0,-1)+a:n=Oe.ParamRegExpEnd:u+=a;break;case Oe.ParamRegExpEnd:f(),n=Oe.Static,a!=="*"&&a!=="?"&&a!=="+"&&l--,u="";break;default:t("Unknown state");break}}return n===Oe.ParamRegExp&&t(`Unfinished custom RegExp for param "${c}"`),f(),i(),r}const Ol="[^/]+?",bp={sensitive:!1,strict:!1,start:!0,end:!0};var ze=(function(e){return e[e._multiplier=10]="_multiplier",e[e.Root=90]="Root",e[e.Segment=40]="Segment",e[e.SubSegment=30]="SubSegment",e[e.Static=40]="Static",e[e.Dynamic=20]="Dynamic",e[e.BonusCustomRegExp=10]="BonusCustomRegExp",e[e.BonusWildcard=-50]="BonusWildcard",e[e.BonusRepeatable=-20]="BonusRepeatable",e[e.BonusOptional=-8]="BonusOptional",e[e.BonusStrict=.7000000000000001]="BonusStrict",e[e.BonusCaseSensitive=.25]="BonusCaseSensitive",e})(ze||{});const wp=/[.+*?^${}()[\]/\\]/g;function Cp(e,t){const n=me({},bp,t),s=[];let r=n.start?"^":"";const o=[];for(const c of e){const u=c.length?[]:[ze.Root];n.strict&&!c.length&&(r+="/");for(let f=0;f<c.length;f++){const d=c[f];let h=ze.Segment+(n.sensitive?ze.BonusCaseSensitive:0);if(d.type===bn.Static)f||(r+="/"),r+=d.value.replace(wp,"\\$&"),h+=ze.Static;else if(d.type===bn.Param){const{value:m,repeatable:v,optional:x,regexp:k}=d;o.push({name:m,repeatable:v,optional:x});const E=k||Ol;if(E!==Ol){h+=ze.BonusCustomRegExp;try{`${E}`}catch(R){throw new Error(`Invalid custom RegExp for param "${m}" (${E}): `+R.message)}}let b=v?`((?:${E})(?:/(?:${E}))*)`:`(${E})`;f||(b=x&&c.length<2?`(?:/${b})`:"/"+b),x&&(b+="?"),r+=b,h+=ze.Dynamic,x&&(h+=ze.BonusOptional),v&&(h+=ze.BonusRepeatable),E===".*"&&(h+=ze.BonusWildcard)}u.push(h)}s.push(u)}if(n.strict&&n.end){const c=s.length-1;s[c][s[c].length-1]+=ze.BonusStrict}n.strict||(r+="/?"),n.end?r+="$":n.strict&&!r.endsWith("/")&&(r+="(?:/|$)");const i=new RegExp(r,n.sensitive?"":"i");function l(c){const u=c.match(i),f={};if(!u)return null;for(let d=1;d<u.length;d++){const h=u[d]||"",m=o[d-1];f[m.name]=h&&m.repeatable?h.split("/"):h}return f}function a(c){let u="",f=!1;for(const d of e){(!f||!u.endsWith("/"))&&(u+="/"),f=!1;for(const h of d)if(h.type===bn.Static)u+=h.value;else if(h.type===bn.Param){const{value:m,repeatable:v,optional:x}=h,k=m in c?c[m]:"";if(xt(k)&&!v)throw new Error(`Provided param "${m}" is an array but it is not repeatable (* or + modifiers)`);const E=xt(k)?k.join("/"):k;if(!E)if(x)d.length<2&&(u.endsWith("/")?u=u.slice(0,-1):f=!0);else throw new Error(`Missing required param "${m}"`);u+=E}}return u||"/"}return{re:i,score:s,keys:o,parse:l,stringify:a}}function xp(e,t){let n=0;for(;n<e.length&&n<t.length;){const s=t[n]-e[n];if(s)return s;n++}return e.length<t.length?e.length===1&&e[0]===ze.Static+ze.Segment?-1:1:e.length>t.length?t.length===1&&t[0]===ze.Static+ze.Segment?1:-1:0}function Vc(e,t){let n=0;const s=e.score,r=t.score;for(;n<s.length&&n<r.length;){const o=xp(s[n],r[n]);if(o)return o;n++}if(Math.abs(r.length-s.length)===1){if(Tl(s))return 1;if(Tl(r))return-1}return r.length-s.length}function Tl(e){const t=e[e.length-1];return e.length>0&&t[t.length-1]<0}const kp={strict:!1,end:!0,sensitive:!1};function Sp(e,t,n){const s=Cp(_p(e.path),n),r=me(s,{record:e,parent:t,children:[],alias:[]});return t&&!r.record.aliasOf==!t.record.aliasOf&&t.children.push(r),r}function Ep(e,t){const n=[],s=new Map;t=El(kp,t);function r(f){return s.get(f)}function o(f,d,h){const m=!h,v=Ll(f);v.aliasOf=h&&h.record;const x=El(t,f),k=[v];if("alias"in f){const R=typeof f.alias=="string"?[f.alias]:f.alias;for(const U of R)k.push(Ll(me({},v,{components:h?h.record.components:v.components,path:U,aliasOf:h?h.record:v})))}let E,b;for(const R of k){const{path:U}=R;if(d&&U[0]!=="/"){const I=d.record.path,w=I[I.length-1]==="/"?"":"/";R.path=d.record.path+(U&&w+U)}if(E=Sp(R,d,x),h?h.alias.push(E):(b=b||E,b!==E&&b.alias.push(E),m&&f.name&&!Dl(E)&&i(f.name)),qc(E)&&a(E),v.children){const I=v.children;for(let w=0;w<I.length;w++)o(I[w],E,h&&h.children[w])}h=h||E}return b?()=>{i(b)}:ys}function i(f){if(Uc(f)){const d=s.get(f);d&&(s.delete(f),n.splice(n.indexOf(d),1),d.children.forEach(i),d.alias.forEach(i))}else{const d=n.indexOf(f);d>-1&&(n.splice(d,1),f.record.name&&s.delete(f.record.name),f.children.forEach(i),f.alias.forEach(i))}}function l(){return n}function a(f){const d=$p(f,n);n.splice(d,0,f),f.record.name&&!Dl(f)&&s.set(f.record.name,f)}function c(f,d){let h,m={},v,x;if("name"in f&&f.name){if(h=s.get(f.name),!h)throw Xn(Re.MATCHER_NOT_FOUND,{location:f});x=h.record.name,m=me(Ml(d.params,h.keys.filter(b=>!b.optional).concat(h.parent?h.parent.keys.filter(b=>b.optional):[]).map(b=>b.name)),f.params&&Ml(f.params,h.keys.map(b=>b.name))),v=h.stringify(m)}else if(f.path!=null)v=f.path,h=n.find(b=>b.re.test(v)),h&&(m=h.parse(v),x=h.record.name);else{if(h=d.name?s.get(d.name):n.find(b=>b.re.test(d.path)),!h)throw Xn(Re.MATCHER_NOT_FOUND,{location:f,currentLocation:d});x=h.record.name,m=me({},d.params,f.params),v=h.stringify(m)}const k=[];let E=h;for(;E;)k.unshift(E.record),E=E.parent;return{name:x,path:v,params:m,matched:k,meta:Rp(k)}}e.forEach(f=>o(f));function u(){n.length=0,s.clear()}return{addRoute:o,resolve:c,removeRoute:i,clearRoutes:u,getRoutes:l,getRecordMatcher:r}}function Ml(e,t){const n={};for(const s of t)s in e&&(n[s]=e[s]);return n}function Ll(e){const t={path:e.path,redirect:e.redirect,name:e.name,meta:e.meta||{},aliasOf:e.aliasOf,beforeEnter:e.beforeEnter,props:Ap(e),children:e.children||[],instances:{},leaveGuards:new Set,updateGuards:new Set,enterCallbacks:{},components:"components"in e?e.components||null:e.component&&{default:e.component}};return Object.defineProperty(t,"mods",{value:{}}),t}function Ap(e){const t={},n=e.props||!1;if("component"in e)t.default=n;else for(const s in e.components)t[s]=typeof n=="object"?n[s]:n;return t}function Dl(e){for(;e;){if(e.record.aliasOf)return!0;e=e.parent}return!1}function Rp(e){return e.reduce((t,n)=>me(t,n.meta),{})}function $p(e,t){let n=0,s=t.length;for(;n!==s;){const o=n+s>>1;Vc(e,t[o])<0?s=o:n=o+1}const r=Ip(e);return r&&(s=t.lastIndexOf(r,s-1)),s}function Ip(e){let t=e;for(;t=t.parent;)if(qc(t)&&Vc(e,t)===0)return t}function qc({record:e}){return!!(e.name||e.components&&Object.keys(e.components).length||e.redirect)}function Gl(e){const t=bt(Br),n=bt(Si),s=de(()=>{const a=Ie(e.to);return t.resolve(a)}),r=de(()=>{const{matched:a}=s.value,{length:c}=a,u=a[c-1],f=n.matched;if(!u||!f.length)return-1;const d=f.findIndex(Kn.bind(null,u));if(d>-1)return d;const h=jl(a[c-2]);return c>1&&jl(u)===h&&f[f.length-1].path!==h?f.findIndex(Kn.bind(null,a[c-2])):d}),o=de(()=>r.value>-1&&Mp(n.params,s.value.params)),i=de(()=>r.value>-1&&r.value===n.matched.length-1&&Bc(n.params,s.value.params));function l(a={}){if(Tp(a)){const c=t[Ie(e.replace)?"replace":"push"](Ie(e.to)).catch(ys);return e.viewTransition&&typeof document<"u"&&"startViewTransition"in document&&document.startViewTransition(()=>c),c}return Promise.resolve()}return{route:s,href:de(()=>s.value.href),isActive:o,isExactActive:i,navigate:l}}function Np(e){return e.length===1?e[0]:e}const Pp=ac({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"},viewTransition:Boolean},useLink:Gl,setup(e,{slots:t}){const n=Yn(Gl(e)),{options:s}=bt(Br),r=de(()=>({[Fl(e.activeClass,s.linkActiveClass,"router-link-active")]:n.isActive,[Fl(e.exactActiveClass,s.linkExactActiveClass,"router-link-exact-active")]:n.isExactActive}));return()=>{const o=t.default&&Np(t.default(n));return e.custom?o:Oc("a",{"aria-current":n.isExactActive?e.ariaCurrentValue:null,href:n.href,onClick:n.navigate,class:r.value},o)}}}),Op=Pp;function Tp(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 Mp(e,t){for(const n in t){const s=t[n],r=e[n];if(typeof s=="string"){if(s!==r)return!1}else if(!xt(r)||r.length!==s.length||s.some((o,i)=>o.valueOf()!==r[i].valueOf()))return!1}return!0}function jl(e){return e?e.aliasOf?e.aliasOf.path:e.path:""}const Fl=(e,t,n)=>e??t??n,Lp=ac({name:"RouterView",inheritAttrs:!1,props:{name:{type:String,default:"default"},route:Object},compatConfig:{MODE:3},setup(e,{attrs:t,slots:n}){const s=bt(Bo),r=de(()=>e.route||s.value),o=bt(Nl,0),i=de(()=>{let c=Ie(o);const{matched:u}=r.value;let f;for(;(f=u[c])&&!f.components;)c++;return c}),l=de(()=>r.value.matched[i.value]);Js(Nl,de(()=>i.value+1)),Js(up,l),Js(Bo,r);const a=fe();return vt(()=>[a.value,l.value,e.name],([c,u,f],[d,h,m])=>{u&&(u.instances[f]=c,h&&h!==u&&c&&c===d&&(u.leaveGuards.size||(u.leaveGuards=h.leaveGuards),u.updateGuards.size||(u.updateGuards=h.updateGuards))),c&&u&&(!h||!Kn(u,h)||!d)&&(u.enterCallbacks[f]||[]).forEach(v=>v(c))},{flush:"post"}),()=>{const c=r.value,u=e.name,f=l.value,d=f&&f.components[u];if(!d)return Bl(n.default,{Component:d,route:c});const h=f.props[u],m=h?h===!0?c.params:typeof h=="function"?h(c):h:null,x=Oc(d,me({},m,t,{onVnodeUnmounted:k=>{k.component.isUnmounted&&(f.instances[u]=null)},ref:a}));return Bl(n.default,{Component:x,route:c})||x}}});function Bl(e,t){if(!e)return null;const n=e(t);return n.length===1?n[0]:n}const Dp=Lp;function Gp(e){const t=Ep(e.routes,e),n=e.parseQuery||ap,s=e.stringifyQuery||Il,r=e.history,o=os(),i=os(),l=os(),a=jf(en);let c=en;Mn&&e.scrollBehavior&&"scrollRestoration"in history&&(history.scrollRestoration="manual");const u=lo.bind(null,A=>""+A),f=lo.bind(null,Vh),d=lo.bind(null,Ss);function h(A,F){let j,z;return Uc(A)?(j=t.getRecordMatcher(A),z=F):z=A,t.addRoute(z,j)}function m(A){const F=t.getRecordMatcher(A);F&&t.removeRoute(F)}function v(){return t.getRoutes().map(A=>A.record)}function x(A){return!!t.getRecordMatcher(A)}function k(A,F){if(F=me({},F||a.value),typeof A=="string"){const _=ao(n,A,F.path),P=t.resolve({path:_.path},F),T=r.createHref(_.fullPath);return me(_,P,{params:d(P.params),hash:Ss(_.hash),redirectedFrom:void 0,href:T})}let j;if(A.path!=null)j=me({},A,{path:ao(n,A.path,F.path).path});else{const _=me({},A.params);for(const P in _)_[P]==null&&delete _[P];j=me({},A,{params:f(_)}),F.params=f(F.params)}const z=t.resolve(j,F),ce=A.hash||"";z.params=u(d(z.params));const g=Kh(s,me({},A,{hash:Uh(ce),path:z.path})),y=r.createHref(g);return me({fullPath:g,hash:ce,query:s===Il?cp(A.query):A.query||{}},z,{redirectedFrom:void 0,href:y})}function E(A){return typeof A=="string"?ao(n,A,a.value.path):me({},A)}function b(A,F){if(c!==A)return Xn(Re.NAVIGATION_CANCELLED,{from:F,to:A})}function R(A){return w(A)}function U(A){return R(me(E(A),{replace:!0}))}function I(A,F){const j=A.matched[A.matched.length-1];if(j&&j.redirect){const{redirect:z}=j;let ce=typeof z=="function"?z(A,F):z;return typeof ce=="string"&&(ce=ce.includes("?")||ce.includes("#")?ce=E(ce):{path:ce},ce.params={}),me({query:A.query,hash:A.hash,params:ce.path!=null?{}:A.params},ce)}}function w(A,F){const j=c=k(A),z=a.value,ce=A.state,g=A.force,y=A.replace===!0,_=I(j,z);if(_)return w(me(E(_),{state:typeof _=="object"?me({},ce,_.state):ce,force:g,replace:y}),F||j);const P=j;P.redirectedFrom=F;let T;return!g&&Xh(s,z,j)&&(T=Xn(Re.NAVIGATION_DUPLICATED,{to:P,from:z}),at(z,z,!0,!1)),(T?Promise.resolve(T):q(P,z)).catch(O=>Ft(O)?Ft(O,Re.NAVIGATION_GUARD_REDIRECT)?O:lt(O):le(O,P,z)).then(O=>{if(O){if(Ft(O,Re.NAVIGATION_GUARD_REDIRECT))return w(me({replace:y},E(O.to),{state:typeof O.to=="object"?me({},ce,O.to.state):ce,force:g}),F||P)}else O=L(P,z,!0,y,ce);return re(P,z,O),O})}function W(A,F){const j=b(A,F);return j?Promise.reject(j):Promise.resolve()}function Q(A){const F=Dt.values().next().value;return F&&typeof F.runWithContext=="function"?F.runWithContext(A):A()}function q(A,F){let j;const[z,ce,g]=fp(A,F);j=uo(z.reverse(),"beforeRouteLeave",A,F);for(const _ of z)_.leaveGuards.forEach(P=>{j.push(rn(P,A,F))});const y=W.bind(null,A,F);return j.push(y),J(j).then(()=>{j=[];for(const _ of o.list())j.push(rn(_,A,F));return j.push(y),J(j)}).then(()=>{j=uo(ce,"beforeRouteUpdate",A,F);for(const _ of ce)_.updateGuards.forEach(P=>{j.push(rn(P,A,F))});return j.push(y),J(j)}).then(()=>{j=[];for(const _ of g)if(_.beforeEnter)if(xt(_.beforeEnter))for(const P of _.beforeEnter)j.push(rn(P,A,F));else j.push(rn(_.beforeEnter,A,F));return j.push(y),J(j)}).then(()=>(A.matched.forEach(_=>_.enterCallbacks={}),j=uo(g,"beforeRouteEnter",A,F,Q),j.push(y),J(j))).then(()=>{j=[];for(const _ of i.list())j.push(rn(_,A,F));return j.push(y),J(j)}).catch(_=>Ft(_,Re.NAVIGATION_CANCELLED)?_:Promise.reject(_))}function re(A,F,j){l.list().forEach(z=>Q(()=>z(A,F,j)))}function L(A,F,j,z,ce){const g=b(A,F);if(g)return g;const y=F===en,_=Mn?history.state:{};j&&(z||y?r.replace(A.fullPath,me({scroll:y&&_&&_.scroll},ce)):r.push(A.fullPath,ce)),a.value=A,at(A,F,j,y),lt()}let pe;function oe(){pe||(pe=r.listen((A,F,j)=>{if(!Gt.listening)return;const z=k(A),ce=I(z,Gt.currentRoute.value);if(ce){w(me(ce,{replace:!0,force:!0}),z).catch(ys);return}c=z;const g=a.value;Mn&&sp($l(g.fullPath,j.delta),Fr()),q(z,g).catch(y=>Ft(y,Re.NAVIGATION_ABORTED|Re.NAVIGATION_CANCELLED)?y:Ft(y,Re.NAVIGATION_GUARD_REDIRECT)?(w(me(E(y.to),{force:!0}),z).then(_=>{Ft(_,Re.NAVIGATION_ABORTED|Re.NAVIGATION_DUPLICATED)&&!j.delta&&j.type===jo.pop&&r.go(-1,!1)}).catch(ys),Promise.reject()):(j.delta&&r.go(-j.delta,!1),le(y,z,g))).then(y=>{y=y||L(z,g,!1),y&&(j.delta&&!Ft(y,Re.NAVIGATION_CANCELLED)?r.go(-j.delta,!1):j.type===jo.pop&&Ft(y,Re.NAVIGATION_ABORTED|Re.NAVIGATION_DUPLICATED)&&r.go(-1,!1)),re(z,g,y)}).catch(ys)}))}let Ee=os(),ge=os(),ae;function le(A,F,j){lt(A);const z=ge.list();return z.length?z.forEach(ce=>ce(A,F,j)):console.error(A),Promise.reject(A)}function it(){return ae&&a.value!==en?Promise.resolve():new Promise((A,F)=>{Ee.add([A,F])})}function lt(A){return ae||(ae=!A,oe(),Ee.list().forEach(([F,j])=>A?j(A):F()),Ee.reset()),A}function at(A,F,j,z){const{scrollBehavior:ce}=e;if(!Mn||!ce)return Promise.resolve();const g=!j&&rp($l(A.fullPath,0))||(z||!j)&&history.state&&history.state.scroll||null;return yi().then(()=>ce(A,F,g)).then(y=>y&&np(y)).catch(y=>le(y,A,F))}const Ge=A=>r.go(A);let pt;const Dt=new Set,Gt={currentRoute:a,listening:!0,addRoute:h,removeRoute:m,clearRoutes:t.clearRoutes,hasRoute:x,getRoutes:v,resolve:k,options:e,push:R,replace:U,go:Ge,back:()=>Ge(-1),forward:()=>Ge(1),beforeEach:o.add,beforeResolve:i.add,afterEach:l.add,onError:ge.add,isReady:it,install(A){A.component("RouterLink",Op),A.component("RouterView",Dp),A.config.globalProperties.$router=Gt,Object.defineProperty(A.config.globalProperties,"$route",{enumerable:!0,get:()=>Ie(a)}),Mn&&!pt&&a.value===en&&(pt=!0,R(r.location).catch(z=>{}));const F={};for(const z in en)Object.defineProperty(F,z,{get:()=>a.value[z],enumerable:!0});A.provide(Br,Gt),A.provide(Si,Qa(F)),A.provide(Bo,a);const j=A.unmount;Dt.add(A),A.unmount=function(){Dt.delete(A),Dt.size<1&&(c=en,pe&&pe(),pe=null,a.value=en,pt=!1,ae=!1),j()}}};function J(A){return A.reduce((F,j)=>F.then(()=>Q(j)),Promise.resolve())}return Gt}function Ei(){return bt(Br)}function Ur(e){return bt(Si)}function jp(){const e=window.location.pathname,t=e.indexOf("#");return(t>=0?e.slice(0,t):e).replace(/\/+$/,"")}const Fp=jp();function Xe(e){return`${Fp}/api${e}`}const Bp={class:"app"},Up={class:"nav-bar"},Hp={key:1,class:"page-scroll"},Wp={class:"page-content"},Vp={__name:"App",setup(e){const t=fe({queue:!1,cron:!1,limit:[],workflow:!1,realtime:!1}),n=Ur();kt(async()=>{const i=await fetch(Xe("/config"));i.ok&&(t.value=await i.json())});const s=de(()=>{const i=[{label:"overview",path:"/"}];return t.value.realtime&&i.push({label:"realtime",path:"/realtime"}),t.value.queue&&i.push({label:"queue",path:"/queue"}),t.value.cron&&i.push({label:"cron",path:"/cron"}),t.value.limit.length&&i.push({label:"limits",path:"/limits"}),t.value.workflow&&(i.push({label:"workflows",path:"/workflows"}),i.push({label:"executions",path:"/executions"})),i});function r(i){return i.path==="/"?n.path==="/":n.path.startsWith(i.path)}const o=de(()=>n.path.startsWith("/realtime"));return(i,l)=>{const a=ar("router-link"),c=ar("router-view");return C(),S("div",Bp,[l[0]||(l[0]=p("div",{class:"top-bar"},[p("div",{class:"top-bar-left"},[p("span",{class:"logo"},[hr("prsm "),p("span",null,"devtools")])])],-1)),p("div",Up,[(C(!0),S(Z,null,he(s.value,u=>(C(),fr(a,{key:u.path,to:u.path,class:Ae({active:r(u)})},{default:_i(()=>[hr(N(u.label),1)]),_:2},1032,["to","class"]))),128))]),o.value?(C(),fr(c,{key:0,config:t.value},null,8,["config"])):(C(),S("div",Hp,[p("div",Wp,[_e(c,{config:t.value},null,8,["config"])])]))])}}};function Hr(){const e=fe([]);let t=null;return kt(()=>{t=new EventSource(Xe("/events"));for(const n of["queue:new","queue:complete","queue:retry","queue:failed","queue:drain","cron:fire","cron:error","workflow:execution:queued","workflow:execution:succeeded","workflow:execution:failed","workflow:execution:canceled","workflow:execution:lease-lost","workflow:step:started","workflow:step:succeeded","workflow:step:routed","workflow:step:retry","workflow:step:failed"])t.addEventListener(n,s=>{const r=JSON.parse(s.data);e.value.unshift({type:n,data:r,ts:Date.now()}),e.value.length>400&&(e.value.length=400)})}),fn(()=>{t&&t.close()}),e}const dn=(e,t)=>{const n=e.__vccOpts||e;for(const[s,r]of t)n[s]=r;return n},qp={class:"subsystems"},zp=["disabled"],Kp=["disabled"],Xp=["disabled"],Jp=["disabled"],Yp={key:0,class:"stream"},Qp={class:"event-source"},Zp={class:"event-data"},eg={class:"event-time"},tg={key:1,class:"empty",style:{"text-align":"left",padding:"0"}},ng={__name:"Overview",props:{config:Object},setup(e){const t=e,n=Hr(),s=fe({queue:!0,cron:!0,limit:!0,workflow:!0});function r(c){return new Date(c).toLocaleTimeString()}function o(c){return c.split(":")[0]}function i(c){const u=c.split(":");return u[0]==="workflow"?u.slice(1).join(":"):u[1]}function l(c){s.value[c]=!s.value[c]}vt(()=>t.config,c=>{var u;c&&(s.value={queue:!!c.queue,cron:!!c.cron,limit:!!((u=c.limit)!=null&&u.length),workflow:!!c.workflow})},{immediate:!0,deep:!0});const a=de(()=>n.value.filter(c=>s.value[o(c.type)]!==!1));return(c,u)=>{var f,d,h,m;return C(),S("div",null,[u[5]||(u[5]=p("div",{class:"section-title"},"subsystems",-1)),p("div",qp,[p("button",{class:Ae(["chip",{on:e.config.queue&&s.value.queue,off:e.config.queue&&!s.value.queue}]),disabled:!e.config.queue,onClick:u[0]||(u[0]=v=>l("queue"))}," queue ",10,zp),p("button",{class:Ae(["chip",{on:e.config.cron&&s.value.cron,off:e.config.cron&&!s.value.cron}]),disabled:!e.config.cron,onClick:u[1]||(u[1]=v=>l("cron"))}," cron ",10,Kp),p("button",{class:Ae(["chip",{on:((f=e.config.limit)==null?void 0:f.length)&&s.value.limit,off:((d=e.config.limit)==null?void 0:d.length)&&!s.value.limit}]),disabled:!((h=e.config.limit)!=null&&h.length),onClick:u[2]||(u[2]=v=>l("limit"))}," limit"+N((m=e.config.limit)!=null&&m.length?` (${e.config.limit.length})`:""),11,Xp),p("button",{class:Ae(["chip",{on:e.config.workflow&&s.value.workflow,off:e.config.workflow&&!s.value.workflow}]),disabled:!e.config.workflow,onClick:u[3]||(u[3]=v=>l("workflow"))}," workflow ",10,Jp)]),p("section",null,[u[4]||(u[4]=p("div",{class:"section-title"},"event stream",-1)),a.value.length?(C(),S("div",Yp,[(C(!0),S(Z,null,he(a.value.slice(0,80),(v,x)=>(C(),S("div",{key:x,class:"event-row"},[p("span",Qp,N(o(v.type)),1),p("span",{class:Ae(["event-action",i(v.type).replace(":","-")])},N(i(v.type)),3),p("span",Zp,N(JSON.stringify(v.data)),1),p("span",eg,N(r(v.ts)),1)]))),128))])):(C(),S("p",tg,"waiting for events"))])])}}},sg=dn(ng,[["__scopeId","data-v-1330d5ac"]]),rg={class:"gauges"},og={class:"gauge"},ig={class:"gauge"},lg={class:"gauge-value"},ag={class:"gauge"},cg={class:"gauge"},ug={class:"gauge-value"},fg={key:0,class:"stream"},dg={class:"event-data"},hg={class:"event-time"},pg={key:1,class:"empty",style:{"text-align":"left",padding:"0"}},gg={__name:"Queue",setup(e){const t=fe(0),n=Hr();let s=null;async function r(){const l=await fetch(Xe("/queue"));if(l.ok){const a=await l.json();t.value=a.inFlight}}kt(()=>{r(),s=setInterval(r,1e3)}),fn(()=>{s&&clearInterval(s)});const o=de(()=>n.value.filter(l=>l.type.startsWith("queue:")).slice(0,100)),i=de(()=>{let l=0,a=0,c=0;for(const u of n.value)u.type==="queue:complete"&&l++,u.type==="queue:failed"&&a++,u.type==="queue:retry"&&c++;return{completed:l,failed:a,retried:c}});return(l,a)=>(C(),S("div",null,[a[5]||(a[5]=p("div",{class:"section-title"},"queue",-1)),p("div",rg,[p("div",og,[p("span",{class:Ae(["gauge-value",{lit:t.value>0}])},N(t.value),3),a[0]||(a[0]=p("span",{class:"gauge-label"},"in-flight",-1))]),p("div",ig,[p("span",lg,N(i.value.completed),1),a[1]||(a[1]=p("span",{class:"gauge-label"},"completed",-1))]),p("div",ag,[p("span",{class:Ae(["gauge-value",{warn:i.value.failed>0}])},N(i.value.failed),3),a[2]||(a[2]=p("span",{class:"gauge-label"},"failed",-1))]),p("div",cg,[p("span",ug,N(i.value.retried),1),a[3]||(a[3]=p("span",{class:"gauge-label"},"retried",-1))])]),a[6]||(a[6]=p("p",{class:"session-note"},"counts since page load",-1)),p("section",null,[a[4]||(a[4]=p("div",{class:"section-title"},"events",-1)),o.value.length?(C(),S("div",fg,[(C(!0),S(Z,null,he(o.value,(c,u)=>(C(),S("div",{key:u,class:"event-row"},[p("span",{class:Ae(["event-action",c.type.split(":")[1]])},N(c.type.split(":")[1]),3),p("span",dg,N(JSON.stringify(c.data)),1),p("span",hg,N(new Date(c.ts).toLocaleTimeString()),1)]))),128))])):(C(),S("p",pg,"no queue events yet"))])]))}},mg=dn(gg,[["__scopeId","data-v-74a2dfa0"]]),yg={key:0,class:"card",style:{"margin-bottom":"24px"}},vg={class:"col-name"},_g={class:"col-next"},bg={key:1,class:"empty",style:{"text-align":"left",padding:"0","margin-bottom":"24px"}},wg={key:2,class:"stream"},Cg={class:"event-name"},xg={class:"event-time"},kg={key:3,class:"empty",style:{"text-align":"left",padding:"0"}},Sg={__name:"Cron",setup(e){const t=fe([]),n=Hr();let s=null;async function r(){const l=await fetch(Xe("/cron"));if(l.ok){const a=await l.json();t.value=a.jobs}}kt(()=>{r(),s=setInterval(r,2e3)}),fn(()=>{s&&clearInterval(s)});const o=de(()=>n.value.filter(l=>l.type.startsWith("cron:")).slice(0,100));function i(l){if(!l)return"-";const a=new Date(l).getTime()-Date.now();return a<0?"now":a<1e3?"<1s":`${Math.ceil(a/1e3)}s`}return(l,a)=>(C(),S("div",null,[a[1]||(a[1]=p("div",{class:"section-title"},"registered jobs",-1)),t.value.length?(C(),S("div",yg,[a[0]||(a[0]=p("div",{class:"job-row header"},[p("span",{class:"col-name"},"name"),p("span",{class:"col-next"},"next fire"),p("span",{class:"col-in"},"in")],-1)),(C(!0),S(Z,null,he(t.value,c=>(C(),S("div",{key:c.name,class:"job-row"},[p("span",vg,N(c.name),1),p("span",_g,N(c.nextFireTime?new Date(c.nextFireTime).toLocaleTimeString():"-"),1),p("span",{class:Ae(["col-in",{soon:i(c.nextFireTime)==="<1s"||i(c.nextFireTime)==="now"}])},N(i(c.nextFireTime)),3)]))),128))])):(C(),S("p",bg,"no cron jobs registered")),a[2]||(a[2]=p("div",{class:"section-title"},"events",-1)),o.value.length?(C(),S("div",wg,[(C(!0),S(Z,null,he(o.value,(c,u)=>(C(),S("div",{key:u,class:"event-row"},[p("span",{class:Ae(["event-action",c.type.split(":")[1]])},N(c.type.split(":")[1]),3),p("span",Cg,N(c.data.name),1),p("span",xg,N(new Date(c.ts).toLocaleTimeString()),1)]))),128))])):(C(),S("p",kg,"no cron events yet"))]))}},Eg=dn(Sg,[["__scopeId","data-v-6d545d29"]]);let Le=class extends Error{constructor(t){super(t),this.name="ShikiError"}};function Ag(e){return Ai(e)}function Ai(e){return Array.isArray(e)?Rg(e):e instanceof RegExp?e:typeof e=="object"?$g(e):e}function Rg(e){let t=[];for(let n=0,s=e.length;n<s;n++)t[n]=Ai(e[n]);return t}function $g(e){let t={};for(let n in e)t[n]=Ai(e[n]);return t}function zc(e,...t){return t.forEach(n=>{for(let s in n)e[s]=n[s]}),e}function Kc(e){const t=~e.lastIndexOf("/")||~e.lastIndexOf("\\");return t===0?e:~t===e.length-1?Kc(e.substring(0,e.length-1)):e.substr(~t+1)}var fo=/\$(\d+)|\${(\d+):\/(downcase|upcase)}/g,Us=class{static hasCaptures(e){return e===null?!1:(fo.lastIndex=0,fo.test(e))}static replaceCaptures(e,t,n){return e.replace(fo,(s,r,o,i)=>{let l=n[parseInt(r||o,10)];if(l){let a=t.substring(l.start,l.end);for(;a[0]===".";)a=a.substring(1);switch(i){case"downcase":return a.toLowerCase();case"upcase":return a.toUpperCase();default:return a}}else return s})}};function Xc(e,t){return e<t?-1:e>t?1:0}function Jc(e,t){if(e===null&&t===null)return 0;if(!e)return-1;if(!t)return 1;let n=e.length,s=t.length;if(n===s){for(let r=0;r<n;r++){let o=Xc(e[r],t[r]);if(o!==0)return o}return 0}return n-s}function Ul(e){return!!(/^#[0-9a-f]{6}$/i.test(e)||/^#[0-9a-f]{8}$/i.test(e)||/^#[0-9a-f]{3}$/i.test(e)||/^#[0-9a-f]{4}$/i.test(e))}function Yc(e){return e.replace(/[\-\\\{\}\*\+\?\|\^\$\.\,\[\]\(\)\#\s]/g,"\\$&")}var Qc=class{constructor(e){$(this,"cache",new Map);this.fn=e}get(e){if(this.cache.has(e))return this.cache.get(e);const t=this.fn(e);return this.cache.set(e,t),t}},yr=class{constructor(e,t,n){$(this,"_cachedMatchRoot",new Qc(e=>this._root.match(e)));this._colorMap=e,this._defaults=t,this._root=n}static createFromRawTheme(e,t){return this.createFromParsedTheme(Pg(e),t)}static createFromParsedTheme(e,t){return Tg(e,t)}getColorMap(){return this._colorMap.getColorMap()}getDefaults(){return this._defaults}match(e){if(e===null)return this._defaults;const t=e.scopeName,s=this._cachedMatchRoot.get(t).find(r=>Ig(e.parent,r.parentScopes));return s?new Zc(s.fontStyle,s.foreground,s.background):null}},ho=class er{constructor(t,n){this.parent=t,this.scopeName=n}static push(t,n){for(const s of n)t=new er(t,s);return t}static from(...t){let n=null;for(let s=0;s<t.length;s++)n=new er(n,t[s]);return n}push(t){return new er(this,t)}getSegments(){let t=this;const n=[];for(;t;)n.push(t.scopeName),t=t.parent;return n.reverse(),n}toString(){return this.getSegments().join(" ")}extends(t){return this===t?!0:this.parent===null?!1:this.parent.extends(t)}getExtensionIfDefined(t){const n=[];let s=this;for(;s&&s!==t;)n.push(s.scopeName),s=s.parent;return s===t?n.reverse():void 0}};function Ig(e,t){if(t.length===0)return!0;for(let n=0;n<t.length;n++){let s=t[n],r=!1;if(s===">"){if(n===t.length-1)return!1;s=t[++n],r=!0}for(;e&&!Ng(e.scopeName,s);){if(r)return!1;e=e.parent}if(!e)return!1;e=e.parent}return!0}function Ng(e,t){return t===e||e.startsWith(t)&&e[t.length]==="."}var Zc=class{constructor(e,t,n){this.fontStyle=e,this.foregroundId=t,this.backgroundId=n}};function Pg(e){if(!e)return[];if(!e.settings||!Array.isArray(e.settings))return[];let t=e.settings,n=[],s=0;for(let r=0,o=t.length;r<o;r++){let i=t[r];if(!i.settings)continue;let l;if(typeof i.scope=="string"){let f=i.scope;f=f.replace(/^[,]+/,""),f=f.replace(/[,]+$/,""),l=f.split(",")}else Array.isArray(i.scope)?l=i.scope:l=[""];let a=-1;if(typeof i.settings.fontStyle=="string"){a=0;let f=i.settings.fontStyle.split(" ");for(let d=0,h=f.length;d<h;d++)switch(f[d]){case"italic":a=a|1;break;case"bold":a=a|2;break;case"underline":a=a|4;break;case"strikethrough":a=a|8;break}}let c=null;typeof i.settings.foreground=="string"&&Ul(i.settings.foreground)&&(c=i.settings.foreground);let u=null;typeof i.settings.background=="string"&&Ul(i.settings.background)&&(u=i.settings.background);for(let f=0,d=l.length;f<d;f++){let m=l[f].trim().split(" "),v=m[m.length-1],x=null;m.length>1&&(x=m.slice(0,m.length-1),x.reverse()),n[s++]=new Og(v,x,r,a,c,u)}}return n}var Og=class{constructor(e,t,n,s,r,o){this.scope=e,this.parentScopes=t,this.index=n,this.fontStyle=s,this.foreground=r,this.background=o}},He=(e=>(e[e.NotSet=-1]="NotSet",e[e.None=0]="None",e[e.Italic=1]="Italic",e[e.Bold=2]="Bold",e[e.Underline=4]="Underline",e[e.Strikethrough=8]="Strikethrough",e))(He||{});function Tg(e,t){e.sort((a,c)=>{let u=Xc(a.scope,c.scope);return u!==0||(u=Jc(a.parentScopes,c.parentScopes),u!==0)?u:a.index-c.index});let n=0,s="#000000",r="#ffffff";for(;e.length>=1&&e[0].scope==="";){let a=e.shift();a.fontStyle!==-1&&(n=a.fontStyle),a.foreground!==null&&(s=a.foreground),a.background!==null&&(r=a.background)}let o=new Mg(t),i=new Zc(n,o.getId(s),o.getId(r)),l=new Dg(new Uo(0,null,-1,0,0),[]);for(let a=0,c=e.length;a<c;a++){let u=e[a];l.insert(0,u.scope,u.parentScopes,u.fontStyle,o.getId(u.foreground),o.getId(u.background))}return new yr(o,i,l)}var Mg=class{constructor(e){$(this,"_isFrozen");$(this,"_lastColorId");$(this,"_id2color");$(this,"_color2id");if(this._lastColorId=0,this._id2color=[],this._color2id=Object.create(null),Array.isArray(e)){this._isFrozen=!0;for(let t=0,n=e.length;t<n;t++)this._color2id[e[t]]=t,this._id2color[t]=e[t]}else this._isFrozen=!1}getId(e){if(e===null)return 0;e=e.toUpperCase();let t=this._color2id[e];if(t)return t;if(this._isFrozen)throw new Error(`Missing color in color map - ${e}`);return t=++this._lastColorId,this._color2id[e]=t,this._id2color[t]=e,t}getColorMap(){return this._id2color.slice(0)}},Lg=Object.freeze([]),Uo=class eu{constructor(t,n,s,r,o){$(this,"scopeDepth");$(this,"parentScopes");$(this,"fontStyle");$(this,"foreground");$(this,"background");this.scopeDepth=t,this.parentScopes=n||Lg,this.fontStyle=s,this.foreground=r,this.background=o}clone(){return new eu(this.scopeDepth,this.parentScopes,this.fontStyle,this.foreground,this.background)}static cloneArr(t){let n=[];for(let s=0,r=t.length;s<r;s++)n[s]=t[s].clone();return n}acceptOverwrite(t,n,s,r){this.scopeDepth>t?console.log("how did this happen?"):this.scopeDepth=t,n!==-1&&(this.fontStyle=n),s!==0&&(this.foreground=s),r!==0&&(this.background=r)}},Dg=class Ho{constructor(t,n=[],s={}){$(this,"_rulesWithParentScopes");this._mainRule=t,this._children=s,this._rulesWithParentScopes=n}static _cmpBySpecificity(t,n){if(t.scopeDepth!==n.scopeDepth)return n.scopeDepth-t.scopeDepth;let s=0,r=0;for(;t.parentScopes[s]===">"&&s++,n.parentScopes[r]===">"&&r++,!(s>=t.parentScopes.length||r>=n.parentScopes.length);){const o=n.parentScopes[r].length-t.parentScopes[s].length;if(o!==0)return o;s++,r++}return n.parentScopes.length-t.parentScopes.length}match(t){if(t!==""){let s=t.indexOf("."),r,o;if(s===-1?(r=t,o=""):(r=t.substring(0,s),o=t.substring(s+1)),this._children.hasOwnProperty(r))return this._children[r].match(o)}const n=this._rulesWithParentScopes.concat(this._mainRule);return n.sort(Ho._cmpBySpecificity),n}insert(t,n,s,r,o,i){if(n===""){this._doInsertHere(t,s,r,o,i);return}let l=n.indexOf("."),a,c;l===-1?(a=n,c=""):(a=n.substring(0,l),c=n.substring(l+1));let u;this._children.hasOwnProperty(a)?u=this._children[a]:(u=new Ho(this._mainRule.clone(),Uo.cloneArr(this._rulesWithParentScopes)),this._children[a]=u),u.insert(t+1,c,s,r,o,i)}_doInsertHere(t,n,s,r,o){if(n===null){this._mainRule.acceptOverwrite(t,s,r,o);return}for(let i=0,l=this._rulesWithParentScopes.length;i<l;i++){let a=this._rulesWithParentScopes[i];if(Jc(a.parentScopes,n)===0){a.acceptOverwrite(t,s,r,o);return}}s===-1&&(s=this._mainRule.fontStyle),r===0&&(r=this._mainRule.foreground),o===0&&(o=this._mainRule.background),this._rulesWithParentScopes.push(new Uo(t,n,s,r,o))}},Jn=class ct{static toBinaryStr(t){return t.toString(2).padStart(32,"0")}static print(t){const n=ct.getLanguageId(t),s=ct.getTokenType(t),r=ct.getFontStyle(t),o=ct.getForeground(t),i=ct.getBackground(t);console.log({languageId:n,tokenType:s,fontStyle:r,foreground:o,background:i})}static getLanguageId(t){return(t&255)>>>0}static getTokenType(t){return(t&768)>>>8}static containsBalancedBrackets(t){return(t&1024)!==0}static getFontStyle(t){return(t&30720)>>>11}static getForeground(t){return(t&16744448)>>>15}static getBackground(t){return(t&4278190080)>>>24}static set(t,n,s,r,o,i,l){let a=ct.getLanguageId(t),c=ct.getTokenType(t),u=ct.containsBalancedBrackets(t)?1:0,f=ct.getFontStyle(t),d=ct.getForeground(t),h=ct.getBackground(t);return n!==0&&(a=n),s!==8&&(c=s),r!==null&&(u=r?1:0),o!==-1&&(f=o),i!==0&&(d=i),l!==0&&(h=l),(a<<0|c<<8|u<<10|f<<11|d<<15|h<<24)>>>0}};function vr(e,t){const n=[],s=Gg(e);let r=s.next();for(;r!==null;){let a=0;if(r.length===2&&r.charAt(1)===":"){switch(r.charAt(0)){case"R":a=1;break;case"L":a=-1;break;default:console.log(`Unknown priority ${r} in scope selector`)}r=s.next()}let c=i();if(n.push({matcher:c,priority:a}),r!==",")break;r=s.next()}return n;function o(){if(r==="-"){r=s.next();const a=o();return c=>!!a&&!a(c)}if(r==="("){r=s.next();const a=l();return r===")"&&(r=s.next()),a}if(Hl(r)){const a=[];do a.push(r),r=s.next();while(Hl(r));return c=>t(a,c)}return null}function i(){const a=[];let c=o();for(;c;)a.push(c),c=o();return u=>a.every(f=>f(u))}function l(){const a=[];let c=i();for(;c&&(a.push(c),r==="|"||r===",");){do r=s.next();while(r==="|"||r===",");c=i()}return u=>a.some(f=>f(u))}}function Hl(e){return!!e&&!!e.match(/[\w\.:]+/)}function Gg(e){let t=/([LR]:|[\w\.:][\w\.:\-]*|[\,\|\-\(\)])/g,n=t.exec(e);return{next:()=>{if(!n)return null;const s=n[0];return n=t.exec(e),s}}}function tu(e){typeof e.dispose=="function"&&e.dispose()}var Es=class{constructor(e){this.scopeName=e}toKey(){return this.scopeName}},jg=class{constructor(e,t){this.scopeName=e,this.ruleName=t}toKey(){return`${this.scopeName}#${this.ruleName}`}},Fg=class{constructor(){$(this,"_references",[]);$(this,"_seenReferenceKeys",new Set);$(this,"visitedRule",new Set)}get references(){return this._references}add(e){const t=e.toKey();this._seenReferenceKeys.has(t)||(this._seenReferenceKeys.add(t),this._references.push(e))}},Bg=class{constructor(e,t){$(this,"seenFullScopeRequests",new Set);$(this,"seenPartialScopeRequests",new Set);$(this,"Q");this.repo=e,this.initialScopeName=t,this.seenFullScopeRequests.add(this.initialScopeName),this.Q=[new Es(this.initialScopeName)]}processQueue(){const e=this.Q;this.Q=[];const t=new Fg;for(const n of e)Ug(n,this.initialScopeName,this.repo,t);for(const n of t.references)if(n instanceof Es){if(this.seenFullScopeRequests.has(n.scopeName))continue;this.seenFullScopeRequests.add(n.scopeName),this.Q.push(n)}else{if(this.seenFullScopeRequests.has(n.scopeName)||this.seenPartialScopeRequests.has(n.toKey()))continue;this.seenPartialScopeRequests.add(n.toKey()),this.Q.push(n)}}};function Ug(e,t,n,s){const r=n.lookup(e.scopeName);if(!r){if(e.scopeName===t)throw new Error(`No grammar provided for <${t}>`);return}const o=n.lookup(t);e instanceof Es?tr({baseGrammar:o,selfGrammar:r},s):Wo(e.ruleName,{baseGrammar:o,selfGrammar:r,repository:r.repository},s);const i=n.injections(e.scopeName);if(i)for(const l of i)s.add(new Es(l))}function Wo(e,t,n){if(t.repository&&t.repository[e]){const s=t.repository[e];_r([s],t,n)}}function tr(e,t){e.selfGrammar.patterns&&Array.isArray(e.selfGrammar.patterns)&&_r(e.selfGrammar.patterns,{...e,repository:e.selfGrammar.repository},t),e.selfGrammar.injections&&_r(Object.values(e.selfGrammar.injections),{...e,repository:e.selfGrammar.repository},t)}function _r(e,t,n){for(const s of e){if(n.visitedRule.has(s))continue;n.visitedRule.add(s);const r=s.repository?zc({},t.repository,s.repository):t.repository;Array.isArray(s.patterns)&&_r(s.patterns,{...t,repository:r},n);const o=s.include;if(!o)continue;const i=nu(o);switch(i.kind){case 0:tr({...t,selfGrammar:t.baseGrammar},n);break;case 1:tr(t,n);break;case 2:Wo(i.ruleName,{...t,repository:r},n);break;case 3:case 4:const l=i.scopeName===t.selfGrammar.scopeName?t.selfGrammar:i.scopeName===t.baseGrammar.scopeName?t.baseGrammar:void 0;if(l){const a={baseGrammar:t.baseGrammar,selfGrammar:l,repository:r};i.kind===4?Wo(i.ruleName,a,n):tr(a,n)}else i.kind===4?n.add(new jg(i.scopeName,i.ruleName)):n.add(new Es(i.scopeName));break}}}var Hg=class{constructor(){$(this,"kind",0)}},Wg=class{constructor(){$(this,"kind",1)}},Vg=class{constructor(e){$(this,"kind",2);this.ruleName=e}},qg=class{constructor(e){$(this,"kind",3);this.scopeName=e}},zg=class{constructor(e,t){$(this,"kind",4);this.scopeName=e,this.ruleName=t}};function nu(e){if(e==="$base")return new Hg;if(e==="$self")return new Wg;const t=e.indexOf("#");if(t===-1)return new qg(e);if(t===0)return new Vg(e.substring(1));{const n=e.substring(0,t),s=e.substring(t+1);return new zg(n,s)}}var Kg=/\\(\d+)/,Wl=/\\(\d+)/g,Xg=-1,su=-2;var Ls=class{constructor(e,t,n,s){$(this,"$location");$(this,"id");$(this,"_nameIsCapturing");$(this,"_name");$(this,"_contentNameIsCapturing");$(this,"_contentName");this.$location=e,this.id=t,this._name=n||null,this._nameIsCapturing=Us.hasCaptures(this._name),this._contentName=s||null,this._contentNameIsCapturing=Us.hasCaptures(this._contentName)}get debugName(){const e=this.$location?`${Kc(this.$location.filename)}:${this.$location.line}`:"unknown";return`${this.constructor.name}#${this.id} @ ${e}`}getName(e,t){return!this._nameIsCapturing||this._name===null||e===null||t===null?this._name:Us.replaceCaptures(this._name,e,t)}getContentName(e,t){return!this._contentNameIsCapturing||this._contentName===null?this._contentName:Us.replaceCaptures(this._contentName,e,t)}},Jg=class extends Ls{constructor(t,n,s,r,o){super(t,n,s,r);$(this,"retokenizeCapturedWithRuleId");this.retokenizeCapturedWithRuleId=o}dispose(){}collectPatterns(t,n){throw new Error("Not supported!")}compile(t,n){throw new Error("Not supported!")}compileAG(t,n,s,r){throw new Error("Not supported!")}},Yg=class extends Ls{constructor(t,n,s,r,o){super(t,n,s,null);$(this,"_match");$(this,"captures");$(this,"_cachedCompiledPatterns");this._match=new As(r,this.id),this.captures=o,this._cachedCompiledPatterns=null}dispose(){this._cachedCompiledPatterns&&(this._cachedCompiledPatterns.dispose(),this._cachedCompiledPatterns=null)}get debugMatchRegExp(){return`${this._match.source}`}collectPatterns(t,n){n.push(this._match)}compile(t,n){return this._getCachedCompiledPatterns(t).compile(t)}compileAG(t,n,s,r){return this._getCachedCompiledPatterns(t).compileAG(t,s,r)}_getCachedCompiledPatterns(t){return this._cachedCompiledPatterns||(this._cachedCompiledPatterns=new Rs,this.collectPatterns(t,this._cachedCompiledPatterns)),this._cachedCompiledPatterns}},Vl=class extends Ls{constructor(t,n,s,r,o){super(t,n,s,r);$(this,"hasMissingPatterns");$(this,"patterns");$(this,"_cachedCompiledPatterns");this.patterns=o.patterns,this.hasMissingPatterns=o.hasMissingPatterns,this._cachedCompiledPatterns=null}dispose(){this._cachedCompiledPatterns&&(this._cachedCompiledPatterns.dispose(),this._cachedCompiledPatterns=null)}collectPatterns(t,n){for(const s of this.patterns)t.getRule(s).collectPatterns(t,n)}compile(t,n){return this._getCachedCompiledPatterns(t).compile(t)}compileAG(t,n,s,r){return this._getCachedCompiledPatterns(t).compileAG(t,s,r)}_getCachedCompiledPatterns(t){return this._cachedCompiledPatterns||(this._cachedCompiledPatterns=new Rs,this.collectPatterns(t,this._cachedCompiledPatterns)),this._cachedCompiledPatterns}},Vo=class extends Ls{constructor(t,n,s,r,o,i,l,a,c,u){super(t,n,s,r);$(this,"_begin");$(this,"beginCaptures");$(this,"_end");$(this,"endHasBackReferences");$(this,"endCaptures");$(this,"applyEndPatternLast");$(this,"hasMissingPatterns");$(this,"patterns");$(this,"_cachedCompiledPatterns");this._begin=new As(o,this.id),this.beginCaptures=i,this._end=new As(l||"￿",-1),this.endHasBackReferences=this._end.hasBackReferences,this.endCaptures=a,this.applyEndPatternLast=c||!1,this.patterns=u.patterns,this.hasMissingPatterns=u.hasMissingPatterns,this._cachedCompiledPatterns=null}dispose(){this._cachedCompiledPatterns&&(this._cachedCompiledPatterns.dispose(),this._cachedCompiledPatterns=null)}get debugBeginRegExp(){return`${this._begin.source}`}get debugEndRegExp(){return`${this._end.source}`}getEndWithResolvedBackReferences(t,n){return this._end.resolveBackReferences(t,n)}collectPatterns(t,n){n.push(this._begin)}compile(t,n){return this._getCachedCompiledPatterns(t,n).compile(t)}compileAG(t,n,s,r){return this._getCachedCompiledPatterns(t,n).compileAG(t,s,r)}_getCachedCompiledPatterns(t,n){if(!this._cachedCompiledPatterns){this._cachedCompiledPatterns=new Rs;for(const s of this.patterns)t.getRule(s).collectPatterns(t,this._cachedCompiledPatterns);this.applyEndPatternLast?this._cachedCompiledPatterns.push(this._end.hasBackReferences?this._end.clone():this._end):this._cachedCompiledPatterns.unshift(this._end.hasBackReferences?this._end.clone():this._end)}return this._end.hasBackReferences&&(this.applyEndPatternLast?this._cachedCompiledPatterns.setSource(this._cachedCompiledPatterns.length()-1,n):this._cachedCompiledPatterns.setSource(0,n)),this._cachedCompiledPatterns}},br=class extends Ls{constructor(t,n,s,r,o,i,l,a,c){super(t,n,s,r);$(this,"_begin");$(this,"beginCaptures");$(this,"whileCaptures");$(this,"_while");$(this,"whileHasBackReferences");$(this,"hasMissingPatterns");$(this,"patterns");$(this,"_cachedCompiledPatterns");$(this,"_cachedCompiledWhilePatterns");this._begin=new As(o,this.id),this.beginCaptures=i,this.whileCaptures=a,this._while=new As(l,su),this.whileHasBackReferences=this._while.hasBackReferences,this.patterns=c.patterns,this.hasMissingPatterns=c.hasMissingPatterns,this._cachedCompiledPatterns=null,this._cachedCompiledWhilePatterns=null}dispose(){this._cachedCompiledPatterns&&(this._cachedCompiledPatterns.dispose(),this._cachedCompiledPatterns=null),this._cachedCompiledWhilePatterns&&(this._cachedCompiledWhilePatterns.dispose(),this._cachedCompiledWhilePatterns=null)}get debugBeginRegExp(){return`${this._begin.source}`}get debugWhileRegExp(){return`${this._while.source}`}getWhileWithResolvedBackReferences(t,n){return this._while.resolveBackReferences(t,n)}collectPatterns(t,n){n.push(this._begin)}compile(t,n){return this._getCachedCompiledPatterns(t).compile(t)}compileAG(t,n,s,r){return this._getCachedCompiledPatterns(t).compileAG(t,s,r)}_getCachedCompiledPatterns(t){if(!this._cachedCompiledPatterns){this._cachedCompiledPatterns=new Rs;for(const n of this.patterns)t.getRule(n).collectPatterns(t,this._cachedCompiledPatterns)}return this._cachedCompiledPatterns}compileWhile(t,n){return this._getCachedCompiledWhilePatterns(t,n).compile(t)}compileWhileAG(t,n,s,r){return this._getCachedCompiledWhilePatterns(t,n).compileAG(t,s,r)}_getCachedCompiledWhilePatterns(t,n){return this._cachedCompiledWhilePatterns||(this._cachedCompiledWhilePatterns=new Rs,this._cachedCompiledWhilePatterns.push(this._while.hasBackReferences?this._while.clone():this._while)),this._while.hasBackReferences&&this._cachedCompiledWhilePatterns.setSource(0,n||"￿"),this._cachedCompiledWhilePatterns}},ru=class Fe{static createCaptureRule(t,n,s,r,o){return t.registerRule(i=>new Jg(n,i,s,r,o))}static getCompiledRuleId(t,n,s){return t.id||n.registerRule(r=>{if(t.id=r,t.match)return new Yg(t.$vscodeTextmateLocation,t.id,t.name,t.match,Fe._compileCaptures(t.captures,n,s));if(typeof t.begin>"u"){t.repository&&(s=zc({},s,t.repository));let o=t.patterns;return typeof o>"u"&&t.include&&(o=[{include:t.include}]),new Vl(t.$vscodeTextmateLocation,t.id,t.name,t.contentName,Fe._compilePatterns(o,n,s))}return t.while?new br(t.$vscodeTextmateLocation,t.id,t.name,t.contentName,t.begin,Fe._compileCaptures(t.beginCaptures||t.captures,n,s),t.while,Fe._compileCaptures(t.whileCaptures||t.captures,n,s),Fe._compilePatterns(t.patterns,n,s)):new Vo(t.$vscodeTextmateLocation,t.id,t.name,t.contentName,t.begin,Fe._compileCaptures(t.beginCaptures||t.captures,n,s),t.end,Fe._compileCaptures(t.endCaptures||t.captures,n,s),t.applyEndPatternLast,Fe._compilePatterns(t.patterns,n,s))}),t.id}static _compileCaptures(t,n,s){let r=[];if(t){let o=0;for(const i in t){if(i==="$vscodeTextmateLocation")continue;const l=parseInt(i,10);l>o&&(o=l)}for(let i=0;i<=o;i++)r[i]=null;for(const i in t){if(i==="$vscodeTextmateLocation")continue;const l=parseInt(i,10);let a=0;t[i].patterns&&(a=Fe.getCompiledRuleId(t[i],n,s)),r[l]=Fe.createCaptureRule(n,t[i].$vscodeTextmateLocation,t[i].name,t[i].contentName,a)}}return r}static _compilePatterns(t,n,s){let r=[];if(t)for(let o=0,i=t.length;o<i;o++){const l=t[o];let a=-1;if(l.include){const c=nu(l.include);switch(c.kind){case 0:case 1:a=Fe.getCompiledRuleId(s[l.include],n,s);break;case 2:let u=s[c.ruleName];u&&(a=Fe.getCompiledRuleId(u,n,s));break;case 3:case 4:const f=c.scopeName,d=c.kind===4?c.ruleName:null,h=n.getExternalGrammar(f,s);if(h)if(d){let m=h.repository[d];m&&(a=Fe.getCompiledRuleId(m,n,h.repository))}else a=Fe.getCompiledRuleId(h.repository.$self,n,h.repository);break}}else a=Fe.getCompiledRuleId(l,n,s);if(a!==-1){const c=n.getRule(a);let u=!1;if((c instanceof Vl||c instanceof Vo||c instanceof br)&&c.hasMissingPatterns&&c.patterns.length===0&&(u=!0),u)continue;r.push(a)}}return{patterns:r,hasMissingPatterns:(t?t.length:0)!==r.length}}},As=class ou{constructor(t,n){$(this,"source");$(this,"ruleId");$(this,"hasAnchor");$(this,"hasBackReferences");$(this,"_anchorCache");if(t&&typeof t=="string"){const s=t.length;let r=0,o=[],i=!1;for(let l=0;l<s;l++)if(t.charAt(l)==="\\"&&l+1<s){const c=t.charAt(l+1);c==="z"?(o.push(t.substring(r,l)),o.push("$(?!\\n)(?<!\\n)"),r=l+2):(c==="A"||c==="G")&&(i=!0),l++}this.hasAnchor=i,r===0?this.source=t:(o.push(t.substring(r,s)),this.source=o.join(""))}else this.hasAnchor=!1,this.source=t;this.hasAnchor?this._anchorCache=this._buildAnchorCache():this._anchorCache=null,this.ruleId=n,typeof this.source=="string"?this.hasBackReferences=Kg.test(this.source):this.hasBackReferences=!1}clone(){return new ou(this.source,this.ruleId)}setSource(t){this.source!==t&&(this.source=t,this.hasAnchor&&(this._anchorCache=this._buildAnchorCache()))}resolveBackReferences(t,n){if(typeof this.source!="string")throw new Error("This method should only be called if the source is a string");let s=n.map(r=>t.substring(r.start,r.end));return Wl.lastIndex=0,this.source.replace(Wl,(r,o)=>Yc(s[parseInt(o,10)]||""))}_buildAnchorCache(){if(typeof this.source!="string")throw new Error("This method should only be called if the source is a string");let t=[],n=[],s=[],r=[],o,i,l,a;for(o=0,i=this.source.length;o<i;o++)l=this.source.charAt(o),t[o]=l,n[o]=l,s[o]=l,r[o]=l,l==="\\"&&o+1<i&&(a=this.source.charAt(o+1),a==="A"?(t[o+1]="￿",n[o+1]="￿",s[o+1]="A",r[o+1]="A"):a==="G"?(t[o+1]="￿",n[o+1]="G",s[o+1]="￿",r[o+1]="G"):(t[o+1]=a,n[o+1]=a,s[o+1]=a,r[o+1]=a),o++);return{A0_G0:t.join(""),A0_G1:n.join(""),A1_G0:s.join(""),A1_G1:r.join("")}}resolveAnchors(t,n){return!this.hasAnchor||!this._anchorCache||typeof this.source!="string"?this.source:t?n?this._anchorCache.A1_G1:this._anchorCache.A1_G0:n?this._anchorCache.A0_G1:this._anchorCache.A0_G0}},Rs=class{constructor(){$(this,"_items");$(this,"_hasAnchors");$(this,"_cached");$(this,"_anchorCache");this._items=[],this._hasAnchors=!1,this._cached=null,this._anchorCache={A0_G0:null,A0_G1:null,A1_G0:null,A1_G1:null}}dispose(){this._disposeCaches()}_disposeCaches(){this._cached&&(this._cached.dispose(),this._cached=null),this._anchorCache.A0_G0&&(this._anchorCache.A0_G0.dispose(),this._anchorCache.A0_G0=null),this._anchorCache.A0_G1&&(this._anchorCache.A0_G1.dispose(),this._anchorCache.A0_G1=null),this._anchorCache.A1_G0&&(this._anchorCache.A1_G0.dispose(),this._anchorCache.A1_G0=null),this._anchorCache.A1_G1&&(this._anchorCache.A1_G1.dispose(),this._anchorCache.A1_G1=null)}push(e){this._items.push(e),this._hasAnchors=this._hasAnchors||e.hasAnchor}unshift(e){this._items.unshift(e),this._hasAnchors=this._hasAnchors||e.hasAnchor}length(){return this._items.length}setSource(e,t){this._items[e].source!==t&&(this._disposeCaches(),this._items[e].setSource(t))}compile(e){if(!this._cached){let t=this._items.map(n=>n.source);this._cached=new ql(e,t,this._items.map(n=>n.ruleId))}return this._cached}compileAG(e,t,n){return this._hasAnchors?t?n?(this._anchorCache.A1_G1||(this._anchorCache.A1_G1=this._resolveAnchors(e,t,n)),this._anchorCache.A1_G1):(this._anchorCache.A1_G0||(this._anchorCache.A1_G0=this._resolveAnchors(e,t,n)),this._anchorCache.A1_G0):n?(this._anchorCache.A0_G1||(this._anchorCache.A0_G1=this._resolveAnchors(e,t,n)),this._anchorCache.A0_G1):(this._anchorCache.A0_G0||(this._anchorCache.A0_G0=this._resolveAnchors(e,t,n)),this._anchorCache.A0_G0):this.compile(e)}_resolveAnchors(e,t,n){let s=this._items.map(r=>r.resolveAnchors(t,n));return new ql(e,s,this._items.map(r=>r.ruleId))}},ql=class{constructor(e,t,n){$(this,"scanner");this.regExps=t,this.rules=n,this.scanner=e.createOnigScanner(t)}dispose(){typeof this.scanner.dispose=="function"&&this.scanner.dispose()}toString(){const e=[];for(let t=0,n=this.rules.length;t<n;t++)e.push(" - "+this.rules[t]+": "+this.regExps[t]);return e.join(`
26
+ `)}findNextMatchSync(e,t,n){const s=this.scanner.findNextMatchSync(e,t,n);return s?{ruleId:this.rules[s.index],captureIndices:s.captureIndices}:null}},po=class{constructor(e,t){this.languageId=e,this.tokenType=t}},Kt,Qg=(Kt=class{constructor(t,n){$(this,"_defaultAttributes");$(this,"_embeddedLanguagesMatcher");$(this,"_getBasicScopeAttributes",new Qc(t=>{const n=this._scopeToLanguage(t),s=this._toStandardTokenType(t);return new po(n,s)}));this._defaultAttributes=new po(t,8),this._embeddedLanguagesMatcher=new Zg(Object.entries(n||{}))}getDefaultAttributes(){return this._defaultAttributes}getBasicScopeAttributes(t){return t===null?Kt._NULL_SCOPE_METADATA:this._getBasicScopeAttributes.get(t)}_scopeToLanguage(t){return this._embeddedLanguagesMatcher.match(t)||0}_toStandardTokenType(t){const n=t.match(Kt.STANDARD_TOKEN_TYPE_REGEXP);if(!n)return 8;switch(n[1]){case"comment":return 1;case"string":return 2;case"regex":return 3;case"meta.embedded":return 0}throw new Error("Unexpected match for standard token type!")}},$(Kt,"_NULL_SCOPE_METADATA",new po(0,0)),$(Kt,"STANDARD_TOKEN_TYPE_REGEXP",/\b(comment|string|regex|meta\.embedded)\b/),Kt),Zg=class{constructor(e){$(this,"values");$(this,"scopesRegExp");if(e.length===0)this.values=null,this.scopesRegExp=null;else{this.values=new Map(e);const t=e.map(([n,s])=>Yc(n));t.sort(),t.reverse(),this.scopesRegExp=new RegExp(`^((${t.join(")|(")}))($|\\.)`,"")}}match(e){if(!this.scopesRegExp)return;const t=e.match(this.scopesRegExp);if(t)return this.values.get(t[1])}},zl=class{constructor(e,t){this.stack=e,this.stoppedEarly=t}};function iu(e,t,n,s,r,o,i,l){const a=t.content.length;let c=!1,u=-1;if(i){const h=em(e,t,n,s,r,o);r=h.stack,s=h.linePos,n=h.isFirstLine,u=h.anchorPosition}const f=Date.now();for(;!c;){if(l!==0&&Date.now()-f>l)return new zl(r,!0);d()}return new zl(r,!1);function d(){const h=tm(e,t,n,s,r,u);if(!h){o.produce(r,a),c=!0;return}const m=h.captureIndices,v=h.matchedRuleId,x=m&&m.length>0?m[0].end>s:!1;if(v===Xg){const k=r.getRule(e);o.produce(r,m[0].start),r=r.withContentNameScopesList(r.nameScopesList),cs(e,t,n,r,o,k.endCaptures,m),o.produce(r,m[0].end);const E=r;if(r=r.parent,u=E.getAnchorPos(),!x&&E.getEnterPos()===s){r=E,o.produce(r,a),c=!0;return}}else{const k=e.getRule(v);o.produce(r,m[0].start);const E=r,b=k.getName(t.content,m),R=r.contentNameScopesList.pushAttributed(b,e);if(r=r.push(v,s,u,m[0].end===a,null,R,R),k instanceof Vo){const U=k;cs(e,t,n,r,o,U.beginCaptures,m),o.produce(r,m[0].end),u=m[0].end;const I=U.getContentName(t.content,m),w=R.pushAttributed(I,e);if(r=r.withContentNameScopesList(w),U.endHasBackReferences&&(r=r.withEndRule(U.getEndWithResolvedBackReferences(t.content,m))),!x&&E.hasSameRuleAs(r)){r=r.pop(),o.produce(r,a),c=!0;return}}else if(k instanceof br){const U=k;cs(e,t,n,r,o,U.beginCaptures,m),o.produce(r,m[0].end),u=m[0].end;const I=U.getContentName(t.content,m),w=R.pushAttributed(I,e);if(r=r.withContentNameScopesList(w),U.whileHasBackReferences&&(r=r.withEndRule(U.getWhileWithResolvedBackReferences(t.content,m))),!x&&E.hasSameRuleAs(r)){r=r.pop(),o.produce(r,a),c=!0;return}}else if(cs(e,t,n,r,o,k.captures,m),o.produce(r,m[0].end),r=r.pop(),!x){r=r.safePop(),o.produce(r,a),c=!0;return}}m[0].end>s&&(s=m[0].end,n=!1)}}function em(e,t,n,s,r,o){let i=r.beginRuleCapturedEOL?0:-1;const l=[];for(let a=r;a;a=a.pop()){const c=a.getRule(e);c instanceof br&&l.push({rule:c,stack:a})}for(let a=l.pop();a;a=l.pop()){const{ruleScanner:c,findOptions:u}=rm(a.rule,e,a.stack.endRule,n,s===i),f=c.findNextMatchSync(t,s,u);if(f){if(f.ruleId!==su){r=a.stack.pop();break}f.captureIndices&&f.captureIndices.length&&(o.produce(a.stack,f.captureIndices[0].start),cs(e,t,n,a.stack,o,a.rule.whileCaptures,f.captureIndices),o.produce(a.stack,f.captureIndices[0].end),i=f.captureIndices[0].end,f.captureIndices[0].end>s&&(s=f.captureIndices[0].end,n=!1))}else{r=a.stack.pop();break}}return{stack:r,linePos:s,anchorPosition:i,isFirstLine:n}}function tm(e,t,n,s,r,o){const i=nm(e,t,n,s,r,o),l=e.getInjections();if(l.length===0)return i;const a=sm(l,e,t,n,s,r,o);if(!a)return i;if(!i)return a;const c=i.captureIndices[0].start,u=a.captureIndices[0].start;return u<c||a.priorityMatch&&u===c?a:i}function nm(e,t,n,s,r,o){const i=r.getRule(e),{ruleScanner:l,findOptions:a}=lu(i,e,r.endRule,n,s===o),c=l.findNextMatchSync(t,s,a);return c?{captureIndices:c.captureIndices,matchedRuleId:c.ruleId}:null}function sm(e,t,n,s,r,o,i){let l=Number.MAX_VALUE,a=null,c,u=0;const f=o.contentNameScopesList.getScopeNames();for(let d=0,h=e.length;d<h;d++){const m=e[d];if(!m.matcher(f))continue;const v=t.getRule(m.ruleId),{ruleScanner:x,findOptions:k}=lu(v,t,null,s,r===i),E=x.findNextMatchSync(n,r,k);if(!E)continue;const b=E.captureIndices[0].start;if(!(b>=l)&&(l=b,a=E.captureIndices,c=E.ruleId,u=m.priority,l===r))break}return a?{priorityMatch:u===-1,captureIndices:a,matchedRuleId:c}:null}function lu(e,t,n,s,r){return{ruleScanner:e.compileAG(t,n,s,r),findOptions:0}}function rm(e,t,n,s,r){return{ruleScanner:e.compileWhileAG(t,n,s,r),findOptions:0}}function cs(e,t,n,s,r,o,i){if(o.length===0)return;const l=t.content,a=Math.min(o.length,i.length),c=[],u=i[0].end;for(let f=0;f<a;f++){const d=o[f];if(d===null)continue;const h=i[f];if(h.length===0)continue;if(h.start>u)break;for(;c.length>0&&c[c.length-1].endPos<=h.start;)r.produceFromScopes(c[c.length-1].scopes,c[c.length-1].endPos),c.pop();if(c.length>0?r.produceFromScopes(c[c.length-1].scopes,h.start):r.produce(s,h.start),d.retokenizeCapturedWithRuleId){const v=d.getName(l,i),x=s.contentNameScopesList.pushAttributed(v,e),k=d.getContentName(l,i),E=x.pushAttributed(k,e),b=s.push(d.retokenizeCapturedWithRuleId,h.start,-1,!1,null,x,E),R=e.createOnigString(l.substring(0,h.end));iu(e,R,n&&h.start===0,h.start,b,r,!1,0),tu(R);continue}const m=d.getName(l,i);if(m!==null){const x=(c.length>0?c[c.length-1].scopes:s.contentNameScopesList).pushAttributed(m,e);c.push(new om(x,h.end))}}for(;c.length>0;)r.produceFromScopes(c[c.length-1].scopes,c[c.length-1].endPos),c.pop()}var om=class{constructor(e,t){$(this,"scopes");$(this,"endPos");this.scopes=e,this.endPos=t}};function im(e,t,n,s,r,o,i,l){return new am(e,t,n,s,r,o,i,l)}function Kl(e,t,n,s,r){const o=vr(t,wr),i=ru.getCompiledRuleId(n,s,r.repository);for(const l of o)e.push({debugSelector:t,matcher:l.matcher,ruleId:i,grammar:r,priority:l.priority})}function wr(e,t){if(t.length<e.length)return!1;let n=0;return e.every(s=>{for(let r=n;r<t.length;r++)if(lm(t[r],s))return n=r+1,!0;return!1})}function lm(e,t){if(!e)return!1;if(e===t)return!0;const n=t.length;return e.length>n&&e.substr(0,n)===t&&e[n]==="."}var am=class{constructor(e,t,n,s,r,o,i,l){$(this,"_rootId");$(this,"_lastRuleId");$(this,"_ruleId2desc");$(this,"_includedGrammars");$(this,"_grammarRepository");$(this,"_grammar");$(this,"_injections");$(this,"_basicScopeAttributesProvider");$(this,"_tokenTypeMatchers");if(this._rootScopeName=e,this.balancedBracketSelectors=o,this._onigLib=l,this._basicScopeAttributesProvider=new Qg(n,s),this._rootId=-1,this._lastRuleId=0,this._ruleId2desc=[null],this._includedGrammars={},this._grammarRepository=i,this._grammar=Xl(t,null),this._injections=null,this._tokenTypeMatchers=[],r)for(const a of Object.keys(r)){const c=vr(a,wr);for(const u of c)this._tokenTypeMatchers.push({matcher:u.matcher,type:r[a]})}}get themeProvider(){return this._grammarRepository}dispose(){for(const e of this._ruleId2desc)e&&e.dispose()}createOnigScanner(e){return this._onigLib.createOnigScanner(e)}createOnigString(e){return this._onigLib.createOnigString(e)}getMetadataForScope(e){return this._basicScopeAttributesProvider.getBasicScopeAttributes(e)}_collectInjections(){const e={lookup:r=>r===this._rootScopeName?this._grammar:this.getExternalGrammar(r),injections:r=>this._grammarRepository.injections(r)},t=[],n=this._rootScopeName,s=e.lookup(n);if(s){const r=s.injections;if(r)for(let i in r)Kl(t,i,r[i],this,s);const o=this._grammarRepository.injections(n);o&&o.forEach(i=>{const l=this.getExternalGrammar(i);if(l){const a=l.injectionSelector;a&&Kl(t,a,l,this,l)}})}return t.sort((r,o)=>r.priority-o.priority),t}getInjections(){return this._injections===null&&(this._injections=this._collectInjections()),this._injections}registerRule(e){const t=++this._lastRuleId,n=e(t);return this._ruleId2desc[t]=n,n}getRule(e){return this._ruleId2desc[e]}getExternalGrammar(e,t){if(this._includedGrammars[e])return this._includedGrammars[e];if(this._grammarRepository){const n=this._grammarRepository.lookup(e);if(n)return this._includedGrammars[e]=Xl(n,t&&t.$base),this._includedGrammars[e]}}tokenizeLine(e,t,n=0){const s=this._tokenize(e,t,!1,n);return{tokens:s.lineTokens.getResult(s.ruleStack,s.lineLength),ruleStack:s.ruleStack,stoppedEarly:s.stoppedEarly}}tokenizeLine2(e,t,n=0){const s=this._tokenize(e,t,!0,n);return{tokens:s.lineTokens.getBinaryResult(s.ruleStack,s.lineLength),ruleStack:s.ruleStack,stoppedEarly:s.stoppedEarly}}_tokenize(e,t,n,s){this._rootId===-1&&(this._rootId=ru.getCompiledRuleId(this._grammar.repository.$self,this,this._grammar.repository),this.getInjections());let r;if(!t||t===qo.NULL){r=!0;const c=this._basicScopeAttributesProvider.getDefaultAttributes(),u=this.themeProvider.getDefaults(),f=Jn.set(0,c.languageId,c.tokenType,null,u.fontStyle,u.foregroundId,u.backgroundId),d=this.getRule(this._rootId).getName(null,null);let h;d?h=vs.createRootAndLookUpScopeName(d,f,this):h=vs.createRoot("unknown",f),t=new qo(null,this._rootId,-1,-1,!1,null,h,h)}else r=!1,t.reset();e=e+`
27
+ `;const o=this.createOnigString(e),i=o.content.length,l=new um(n,e,this._tokenTypeMatchers,this.balancedBracketSelectors),a=iu(this,o,r,0,t,l,!0,s);return tu(o),{lineLength:i,lineTokens:l,ruleStack:a.stack,stoppedEarly:a.stoppedEarly}}};function Xl(e,t){return e=Ag(e),e.repository=e.repository||{},e.repository.$self={$vscodeTextmateLocation:e.$vscodeTextmateLocation,patterns:e.patterns,name:e.scopeName},e.repository.$base=t||e.repository.$self,e}var vs=class $t{constructor(t,n,s){this.parent=t,this.scopePath=n,this.tokenAttributes=s}static fromExtension(t,n){let s=t,r=(t==null?void 0:t.scopePath)??null;for(const o of n)r=ho.push(r,o.scopeNames),s=new $t(s,r,o.encodedTokenAttributes);return s}static createRoot(t,n){return new $t(null,new ho(null,t),n)}static createRootAndLookUpScopeName(t,n,s){const r=s.getMetadataForScope(t),o=new ho(null,t),i=s.themeProvider.themeMatch(o),l=$t.mergeAttributes(n,r,i);return new $t(null,o,l)}get scopeName(){return this.scopePath.scopeName}toString(){return this.getScopeNames().join(" ")}equals(t){return $t.equals(this,t)}static equals(t,n){do{if(t===n||!t&&!n)return!0;if(!t||!n||t.scopeName!==n.scopeName||t.tokenAttributes!==n.tokenAttributes)return!1;t=t.parent,n=n.parent}while(!0)}static mergeAttributes(t,n,s){let r=-1,o=0,i=0;return s!==null&&(r=s.fontStyle,o=s.foregroundId,i=s.backgroundId),Jn.set(t,n.languageId,n.tokenType,null,r,o,i)}pushAttributed(t,n){if(t===null)return this;if(t.indexOf(" ")===-1)return $t._pushAttributed(this,t,n);const s=t.split(/ /g);let r=this;for(const o of s)r=$t._pushAttributed(r,o,n);return r}static _pushAttributed(t,n,s){const r=s.getMetadataForScope(n),o=t.scopePath.push(n),i=s.themeProvider.themeMatch(o),l=$t.mergeAttributes(t.tokenAttributes,r,i);return new $t(t,o,l)}getScopeNames(){return this.scopePath.getSegments()}getExtensionIfDefined(t){var r;const n=[];let s=this;for(;s&&s!==t;)n.push({encodedTokenAttributes:s.tokenAttributes,scopeNames:s.scopePath.getExtensionIfDefined(((r=s.parent)==null?void 0:r.scopePath)??null)}),s=s.parent;return s===t?n.reverse():void 0}},ut,qo=(ut=class{constructor(t,n,s,r,o,i,l,a){$(this,"_stackElementBrand");$(this,"_enterPos");$(this,"_anchorPos");$(this,"depth");this.parent=t,this.ruleId=n,this.beginRuleCapturedEOL=o,this.endRule=i,this.nameScopesList=l,this.contentNameScopesList=a,this.depth=this.parent?this.parent.depth+1:1,this._enterPos=s,this._anchorPos=r}equals(t){return t===null?!1:ut._equals(this,t)}static _equals(t,n){return t===n?!0:this._structuralEquals(t,n)?vs.equals(t.contentNameScopesList,n.contentNameScopesList):!1}static _structuralEquals(t,n){do{if(t===n||!t&&!n)return!0;if(!t||!n||t.depth!==n.depth||t.ruleId!==n.ruleId||t.endRule!==n.endRule)return!1;t=t.parent,n=n.parent}while(!0)}clone(){return this}static _reset(t){for(;t;)t._enterPos=-1,t._anchorPos=-1,t=t.parent}reset(){ut._reset(this)}pop(){return this.parent}safePop(){return this.parent?this.parent:this}push(t,n,s,r,o,i,l){return new ut(this,t,n,s,r,o,i,l)}getEnterPos(){return this._enterPos}getAnchorPos(){return this._anchorPos}getRule(t){return t.getRule(this.ruleId)}toString(){const t=[];return this._writeString(t,0),"["+t.join(",")+"]"}_writeString(t,n){var s,r;return this.parent&&(n=this.parent._writeString(t,n)),t[n++]=`(${this.ruleId}, ${(s=this.nameScopesList)==null?void 0:s.toString()}, ${(r=this.contentNameScopesList)==null?void 0:r.toString()})`,n}withContentNameScopesList(t){return this.contentNameScopesList===t?this:this.parent.push(this.ruleId,this._enterPos,this._anchorPos,this.beginRuleCapturedEOL,this.endRule,this.nameScopesList,t)}withEndRule(t){return this.endRule===t?this:new ut(this.parent,this.ruleId,this._enterPos,this._anchorPos,this.beginRuleCapturedEOL,t,this.nameScopesList,this.contentNameScopesList)}hasSameRuleAs(t){let n=this;for(;n&&n._enterPos===t._enterPos;){if(n.ruleId===t.ruleId)return!0;n=n.parent}return!1}toStateStackFrame(){var t,n,s;return{ruleId:this.ruleId,beginRuleCapturedEOL:this.beginRuleCapturedEOL,endRule:this.endRule,nameScopesList:((n=this.nameScopesList)==null?void 0:n.getExtensionIfDefined(((t=this.parent)==null?void 0:t.nameScopesList)??null))??[],contentNameScopesList:((s=this.contentNameScopesList)==null?void 0:s.getExtensionIfDefined(this.nameScopesList))??[]}}static pushFrame(t,n){const s=vs.fromExtension((t==null?void 0:t.nameScopesList)??null,n.nameScopesList);return new ut(t,n.ruleId,n.enterPos??-1,n.anchorPos??-1,n.beginRuleCapturedEOL,n.endRule,s,vs.fromExtension(s,n.contentNameScopesList))}},$(ut,"NULL",new ut(null,0,0,0,!1,null,null,null)),ut),cm=class{constructor(e,t){$(this,"balancedBracketScopes");$(this,"unbalancedBracketScopes");$(this,"allowAny",!1);this.balancedBracketScopes=e.flatMap(n=>n==="*"?(this.allowAny=!0,[]):vr(n,wr).map(s=>s.matcher)),this.unbalancedBracketScopes=t.flatMap(n=>vr(n,wr).map(s=>s.matcher))}get matchesAlways(){return this.allowAny&&this.unbalancedBracketScopes.length===0}get matchesNever(){return this.balancedBracketScopes.length===0&&!this.allowAny}match(e){for(const t of this.unbalancedBracketScopes)if(t(e))return!1;for(const t of this.balancedBracketScopes)if(t(e))return!0;return this.allowAny}},um=class{constructor(e,t,n,s){$(this,"_emitBinaryTokens");$(this,"_lineText");$(this,"_tokens");$(this,"_binaryTokens");$(this,"_lastTokenEndIndex");$(this,"_tokenTypeOverrides");this.balancedBracketSelectors=s,this._emitBinaryTokens=e,this._tokenTypeOverrides=n,this._lineText=null,this._tokens=[],this._binaryTokens=[],this._lastTokenEndIndex=0}produce(e,t){this.produceFromScopes(e.contentNameScopesList,t)}produceFromScopes(e,t){var s;if(this._lastTokenEndIndex>=t)return;if(this._emitBinaryTokens){let r=(e==null?void 0:e.tokenAttributes)??0,o=!1;if((s=this.balancedBracketSelectors)!=null&&s.matchesAlways&&(o=!0),this._tokenTypeOverrides.length>0||this.balancedBracketSelectors&&!this.balancedBracketSelectors.matchesAlways&&!this.balancedBracketSelectors.matchesNever){const i=(e==null?void 0:e.getScopeNames())??[];for(const l of this._tokenTypeOverrides)l.matcher(i)&&(r=Jn.set(r,0,l.type,null,-1,0,0));this.balancedBracketSelectors&&(o=this.balancedBracketSelectors.match(i))}if(o&&(r=Jn.set(r,0,8,o,-1,0,0)),this._binaryTokens.length>0&&this._binaryTokens[this._binaryTokens.length-1]===r){this._lastTokenEndIndex=t;return}this._binaryTokens.push(this._lastTokenEndIndex),this._binaryTokens.push(r),this._lastTokenEndIndex=t;return}const n=(e==null?void 0:e.getScopeNames())??[];this._tokens.push({startIndex:this._lastTokenEndIndex,endIndex:t,scopes:n}),this._lastTokenEndIndex=t}getResult(e,t){return this._tokens.length>0&&this._tokens[this._tokens.length-1].startIndex===t-1&&this._tokens.pop(),this._tokens.length===0&&(this._lastTokenEndIndex=-1,this.produce(e,t),this._tokens[this._tokens.length-1].startIndex=0),this._tokens}getBinaryResult(e,t){this._binaryTokens.length>0&&this._binaryTokens[this._binaryTokens.length-2]===t-1&&(this._binaryTokens.pop(),this._binaryTokens.pop()),this._binaryTokens.length===0&&(this._lastTokenEndIndex=-1,this.produce(e,t),this._binaryTokens[this._binaryTokens.length-2]=0);const n=new Uint32Array(this._binaryTokens.length);for(let s=0,r=this._binaryTokens.length;s<r;s++)n[s]=this._binaryTokens[s];return n}},fm=class{constructor(e,t){$(this,"_grammars",new Map);$(this,"_rawGrammars",new Map);$(this,"_injectionGrammars",new Map);$(this,"_theme");this._onigLib=t,this._theme=e}dispose(){for(const e of this._grammars.values())e.dispose()}setTheme(e){this._theme=e}getColorMap(){return this._theme.getColorMap()}addGrammar(e,t){this._rawGrammars.set(e.scopeName,e),t&&this._injectionGrammars.set(e.scopeName,t)}lookup(e){return this._rawGrammars.get(e)}injections(e){return this._injectionGrammars.get(e)}getDefaults(){return this._theme.getDefaults()}themeMatch(e){return this._theme.match(e)}grammarForScopeName(e,t,n,s,r){if(!this._grammars.has(e)){let o=this._rawGrammars.get(e);if(!o)return null;this._grammars.set(e,im(e,o,t,n,s,r,this,this._onigLib))}return this._grammars.get(e)}},dm=class{constructor(t){$(this,"_options");$(this,"_syncRegistry");$(this,"_ensureGrammarCache");this._options=t,this._syncRegistry=new fm(yr.createFromRawTheme(t.theme,t.colorMap),t.onigLib),this._ensureGrammarCache=new Map}dispose(){this._syncRegistry.dispose()}setTheme(t,n){this._syncRegistry.setTheme(yr.createFromRawTheme(t,n))}getColorMap(){return this._syncRegistry.getColorMap()}loadGrammarWithEmbeddedLanguages(t,n,s){return this.loadGrammarWithConfiguration(t,n,{embeddedLanguages:s})}loadGrammarWithConfiguration(t,n,s){return this._loadGrammar(t,n,s.embeddedLanguages,s.tokenTypes,new cm(s.balancedBracketSelectors||[],s.unbalancedBracketSelectors||[]))}loadGrammar(t){return this._loadGrammar(t,0,null,null,null)}_loadGrammar(t,n,s,r,o){const i=new Bg(this._syncRegistry,t);for(;i.Q.length>0;)i.Q.map(l=>this._loadSingleGrammar(l.scopeName)),i.processQueue();return this._grammarForScopeName(t,n,s,r,o)}_loadSingleGrammar(t){this._ensureGrammarCache.has(t)||(this._doLoadSingleGrammar(t),this._ensureGrammarCache.set(t,!0))}_doLoadSingleGrammar(t){const n=this._options.loadGrammar(t);if(n){const s=typeof this._options.getInjections=="function"?this._options.getInjections(t):void 0;this._syncRegistry.addGrammar(n,s)}}addGrammar(t,n=[],s=0,r=null){return this._syncRegistry.addGrammar(t,n),this._grammarForScopeName(t.scopeName,s,r)}_grammarForScopeName(t,n=0,s=null,r=null,o=null){return this._syncRegistry.grammarForScopeName(t,n,s,r,o)}},zo=qo.NULL;const hm=["area","base","basefont","bgsound","br","col","command","embed","frame","hr","image","img","input","keygen","link","meta","param","source","track","wbr"];class Ds{constructor(t,n,s){this.normal=n,this.property=t,s&&(this.space=s)}}Ds.prototype.normal={};Ds.prototype.property={};Ds.prototype.space=void 0;function au(e,t){const n={},s={};for(const r of e)Object.assign(n,r.property),Object.assign(s,r.normal);return new Ds(n,s,t)}function Ko(e){return e.toLowerCase()}class tt{constructor(t,n){this.attribute=n,this.property=t}}tt.prototype.attribute="";tt.prototype.booleanish=!1;tt.prototype.boolean=!1;tt.prototype.commaOrSpaceSeparated=!1;tt.prototype.commaSeparated=!1;tt.prototype.defined=!1;tt.prototype.mustUseProperty=!1;tt.prototype.number=!1;tt.prototype.overloadedBoolean=!1;tt.prototype.property="";tt.prototype.spaceSeparated=!1;tt.prototype.space=void 0;let pm=0;const se=In(),Ne=In(),Xo=In(),D=In(),ke=In(),Wn=In(),st=In();function In(){return 2**++pm}const Jo=Object.freeze(Object.defineProperty({__proto__:null,boolean:se,booleanish:Ne,commaOrSpaceSeparated:st,commaSeparated:Wn,number:D,overloadedBoolean:Xo,spaceSeparated:ke},Symbol.toStringTag,{value:"Module"})),go=Object.keys(Jo);class Ri extends tt{constructor(t,n,s,r){let o=-1;if(super(t,n),Jl(this,"space",r),typeof s=="number")for(;++o<go.length;){const i=go[o];Jl(this,go[o],(s&Jo[i])===Jo[i])}}}Ri.prototype.defined=!0;function Jl(e,t,n){n&&(e[t]=n)}function Qn(e){const t={},n={};for(const[s,r]of Object.entries(e.properties)){const o=new Ri(s,e.transform(e.attributes||{},s),r,e.space);e.mustUseProperty&&e.mustUseProperty.includes(s)&&(o.mustUseProperty=!0),t[s]=o,n[Ko(s)]=s,n[Ko(o.attribute)]=s}return new Ds(t,n,e.space)}const cu=Qn({properties:{ariaActiveDescendant:null,ariaAtomic:Ne,ariaAutoComplete:null,ariaBusy:Ne,ariaChecked:Ne,ariaColCount:D,ariaColIndex:D,ariaColSpan:D,ariaControls:ke,ariaCurrent:null,ariaDescribedBy:ke,ariaDetails:null,ariaDisabled:Ne,ariaDropEffect:ke,ariaErrorMessage:null,ariaExpanded:Ne,ariaFlowTo:ke,ariaGrabbed:Ne,ariaHasPopup:null,ariaHidden:Ne,ariaInvalid:null,ariaKeyShortcuts:null,ariaLabel:null,ariaLabelledBy:ke,ariaLevel:D,ariaLive:null,ariaModal:Ne,ariaMultiLine:Ne,ariaMultiSelectable:Ne,ariaOrientation:null,ariaOwns:ke,ariaPlaceholder:null,ariaPosInSet:D,ariaPressed:Ne,ariaReadOnly:Ne,ariaRelevant:null,ariaRequired:Ne,ariaRoleDescription:ke,ariaRowCount:D,ariaRowIndex:D,ariaRowSpan:D,ariaSelected:Ne,ariaSetSize:D,ariaSort:null,ariaValueMax:D,ariaValueMin:D,ariaValueNow:D,ariaValueText:null,role:null},transform(e,t){return t==="role"?t:"aria-"+t.slice(4).toLowerCase()}});function uu(e,t){return t in e?e[t]:t}function fu(e,t){return uu(e,t.toLowerCase())}const gm=Qn({attributes:{acceptcharset:"accept-charset",classname:"class",htmlfor:"for",httpequiv:"http-equiv"},mustUseProperty:["checked","multiple","muted","selected"],properties:{abbr:null,accept:Wn,acceptCharset:ke,accessKey:ke,action:null,allow:null,allowFullScreen:se,allowPaymentRequest:se,allowUserMedia:se,alt:null,as:null,async:se,autoCapitalize:null,autoComplete:ke,autoFocus:se,autoPlay:se,blocking:ke,capture:null,charSet:null,checked:se,cite:null,className:ke,cols:D,colSpan:null,content:null,contentEditable:Ne,controls:se,controlsList:ke,coords:D|Wn,crossOrigin:null,data:null,dateTime:null,decoding:null,default:se,defer:se,dir:null,dirName:null,disabled:se,download:Xo,draggable:Ne,encType:null,enterKeyHint:null,fetchPriority:null,form:null,formAction:null,formEncType:null,formMethod:null,formNoValidate:se,formTarget:null,headers:ke,height:D,hidden:Xo,high:D,href:null,hrefLang:null,htmlFor:ke,httpEquiv:ke,id:null,imageSizes:null,imageSrcSet:null,inert:se,inputMode:null,integrity:null,is:null,isMap:se,itemId:null,itemProp:ke,itemRef:ke,itemScope:se,itemType:ke,kind:null,label:null,lang:null,language:null,list:null,loading:null,loop:se,low:D,manifest:null,max:null,maxLength:D,media:null,method:null,min:null,minLength:D,multiple:se,muted:se,name:null,nonce:null,noModule:se,noValidate:se,onAbort:null,onAfterPrint:null,onAuxClick:null,onBeforeMatch:null,onBeforePrint:null,onBeforeToggle:null,onBeforeUnload:null,onBlur:null,onCancel:null,onCanPlay:null,onCanPlayThrough:null,onChange:null,onClick:null,onClose:null,onContextLost:null,onContextMenu:null,onContextRestored:null,onCopy:null,onCueChange:null,onCut:null,onDblClick:null,onDrag:null,onDragEnd:null,onDragEnter:null,onDragExit:null,onDragLeave:null,onDragOver:null,onDragStart:null,onDrop:null,onDurationChange:null,onEmptied:null,onEnded:null,onError:null,onFocus:null,onFormData:null,onHashChange:null,onInput:null,onInvalid:null,onKeyDown:null,onKeyPress:null,onKeyUp:null,onLanguageChange:null,onLoad:null,onLoadedData:null,onLoadedMetadata:null,onLoadEnd:null,onLoadStart:null,onMessage:null,onMessageError:null,onMouseDown:null,onMouseEnter:null,onMouseLeave:null,onMouseMove:null,onMouseOut:null,onMouseOver:null,onMouseUp:null,onOffline:null,onOnline:null,onPageHide:null,onPageShow:null,onPaste:null,onPause:null,onPlay:null,onPlaying:null,onPopState:null,onProgress:null,onRateChange:null,onRejectionHandled:null,onReset:null,onResize:null,onScroll:null,onScrollEnd:null,onSecurityPolicyViolation:null,onSeeked:null,onSeeking:null,onSelect:null,onSlotChange:null,onStalled:null,onStorage:null,onSubmit:null,onSuspend:null,onTimeUpdate:null,onToggle:null,onUnhandledRejection:null,onUnload:null,onVolumeChange:null,onWaiting:null,onWheel:null,open:se,optimum:D,pattern:null,ping:ke,placeholder:null,playsInline:se,popover:null,popoverTarget:null,popoverTargetAction:null,poster:null,preload:null,readOnly:se,referrerPolicy:null,rel:ke,required:se,reversed:se,rows:D,rowSpan:D,sandbox:ke,scope:null,scoped:se,seamless:se,selected:se,shadowRootClonable:se,shadowRootDelegatesFocus:se,shadowRootMode:null,shape:null,size:D,sizes:null,slot:null,span:D,spellCheck:Ne,src:null,srcDoc:null,srcLang:null,srcSet:null,start:D,step:null,style:null,tabIndex:D,target:null,title:null,translate:null,type:null,typeMustMatch:se,useMap:null,value:Ne,width:D,wrap:null,writingSuggestions:null,align:null,aLink:null,archive:ke,axis:null,background:null,bgColor:null,border:D,borderColor:null,bottomMargin:D,cellPadding:null,cellSpacing:null,char:null,charOff:null,classId:null,clear:null,code:null,codeBase:null,codeType:null,color:null,compact:se,declare:se,event:null,face:null,frame:null,frameBorder:null,hSpace:D,leftMargin:D,link:null,longDesc:null,lowSrc:null,marginHeight:D,marginWidth:D,noResize:se,noHref:se,noShade:se,noWrap:se,object:null,profile:null,prompt:null,rev:null,rightMargin:D,rules:null,scheme:null,scrolling:Ne,standby:null,summary:null,text:null,topMargin:D,valueType:null,version:null,vAlign:null,vLink:null,vSpace:D,allowTransparency:null,autoCorrect:null,autoSave:null,disablePictureInPicture:se,disableRemotePlayback:se,prefix:null,property:null,results:D,security:null,unselectable:null},space:"html",transform:fu}),mm=Qn({attributes:{accentHeight:"accent-height",alignmentBaseline:"alignment-baseline",arabicForm:"arabic-form",baselineShift:"baseline-shift",capHeight:"cap-height",className:"class",clipPath:"clip-path",clipRule:"clip-rule",colorInterpolation:"color-interpolation",colorInterpolationFilters:"color-interpolation-filters",colorProfile:"color-profile",colorRendering:"color-rendering",crossOrigin:"crossorigin",dataType:"datatype",dominantBaseline:"dominant-baseline",enableBackground:"enable-background",fillOpacity:"fill-opacity",fillRule:"fill-rule",floodColor:"flood-color",floodOpacity:"flood-opacity",fontFamily:"font-family",fontSize:"font-size",fontSizeAdjust:"font-size-adjust",fontStretch:"font-stretch",fontStyle:"font-style",fontVariant:"font-variant",fontWeight:"font-weight",glyphName:"glyph-name",glyphOrientationHorizontal:"glyph-orientation-horizontal",glyphOrientationVertical:"glyph-orientation-vertical",hrefLang:"hreflang",horizAdvX:"horiz-adv-x",horizOriginX:"horiz-origin-x",horizOriginY:"horiz-origin-y",imageRendering:"image-rendering",letterSpacing:"letter-spacing",lightingColor:"lighting-color",markerEnd:"marker-end",markerMid:"marker-mid",markerStart:"marker-start",navDown:"nav-down",navDownLeft:"nav-down-left",navDownRight:"nav-down-right",navLeft:"nav-left",navNext:"nav-next",navPrev:"nav-prev",navRight:"nav-right",navUp:"nav-up",navUpLeft:"nav-up-left",navUpRight:"nav-up-right",onAbort:"onabort",onActivate:"onactivate",onAfterPrint:"onafterprint",onBeforePrint:"onbeforeprint",onBegin:"onbegin",onCancel:"oncancel",onCanPlay:"oncanplay",onCanPlayThrough:"oncanplaythrough",onChange:"onchange",onClick:"onclick",onClose:"onclose",onCopy:"oncopy",onCueChange:"oncuechange",onCut:"oncut",onDblClick:"ondblclick",onDrag:"ondrag",onDragEnd:"ondragend",onDragEnter:"ondragenter",onDragExit:"ondragexit",onDragLeave:"ondragleave",onDragOver:"ondragover",onDragStart:"ondragstart",onDrop:"ondrop",onDurationChange:"ondurationchange",onEmptied:"onemptied",onEnd:"onend",onEnded:"onended",onError:"onerror",onFocus:"onfocus",onFocusIn:"onfocusin",onFocusOut:"onfocusout",onHashChange:"onhashchange",onInput:"oninput",onInvalid:"oninvalid",onKeyDown:"onkeydown",onKeyPress:"onkeypress",onKeyUp:"onkeyup",onLoad:"onload",onLoadedData:"onloadeddata",onLoadedMetadata:"onloadedmetadata",onLoadStart:"onloadstart",onMessage:"onmessage",onMouseDown:"onmousedown",onMouseEnter:"onmouseenter",onMouseLeave:"onmouseleave",onMouseMove:"onmousemove",onMouseOut:"onmouseout",onMouseOver:"onmouseover",onMouseUp:"onmouseup",onMouseWheel:"onmousewheel",onOffline:"onoffline",onOnline:"ononline",onPageHide:"onpagehide",onPageShow:"onpageshow",onPaste:"onpaste",onPause:"onpause",onPlay:"onplay",onPlaying:"onplaying",onPopState:"onpopstate",onProgress:"onprogress",onRateChange:"onratechange",onRepeat:"onrepeat",onReset:"onreset",onResize:"onresize",onScroll:"onscroll",onSeeked:"onseeked",onSeeking:"onseeking",onSelect:"onselect",onShow:"onshow",onStalled:"onstalled",onStorage:"onstorage",onSubmit:"onsubmit",onSuspend:"onsuspend",onTimeUpdate:"ontimeupdate",onToggle:"ontoggle",onUnload:"onunload",onVolumeChange:"onvolumechange",onWaiting:"onwaiting",onZoom:"onzoom",overlinePosition:"overline-position",overlineThickness:"overline-thickness",paintOrder:"paint-order",panose1:"panose-1",pointerEvents:"pointer-events",referrerPolicy:"referrerpolicy",renderingIntent:"rendering-intent",shapeRendering:"shape-rendering",stopColor:"stop-color",stopOpacity:"stop-opacity",strikethroughPosition:"strikethrough-position",strikethroughThickness:"strikethrough-thickness",strokeDashArray:"stroke-dasharray",strokeDashOffset:"stroke-dashoffset",strokeLineCap:"stroke-linecap",strokeLineJoin:"stroke-linejoin",strokeMiterLimit:"stroke-miterlimit",strokeOpacity:"stroke-opacity",strokeWidth:"stroke-width",tabIndex:"tabindex",textAnchor:"text-anchor",textDecoration:"text-decoration",textRendering:"text-rendering",transformOrigin:"transform-origin",typeOf:"typeof",underlinePosition:"underline-position",underlineThickness:"underline-thickness",unicodeBidi:"unicode-bidi",unicodeRange:"unicode-range",unitsPerEm:"units-per-em",vAlphabetic:"v-alphabetic",vHanging:"v-hanging",vIdeographic:"v-ideographic",vMathematical:"v-mathematical",vectorEffect:"vector-effect",vertAdvY:"vert-adv-y",vertOriginX:"vert-origin-x",vertOriginY:"vert-origin-y",wordSpacing:"word-spacing",writingMode:"writing-mode",xHeight:"x-height",playbackOrder:"playbackorder",timelineBegin:"timelinebegin"},properties:{about:st,accentHeight:D,accumulate:null,additive:null,alignmentBaseline:null,alphabetic:D,amplitude:D,arabicForm:null,ascent:D,attributeName:null,attributeType:null,azimuth:D,bandwidth:null,baselineShift:null,baseFrequency:null,baseProfile:null,bbox:null,begin:null,bias:D,by:null,calcMode:null,capHeight:D,className:ke,clip:null,clipPath:null,clipPathUnits:null,clipRule:null,color:null,colorInterpolation:null,colorInterpolationFilters:null,colorProfile:null,colorRendering:null,content:null,contentScriptType:null,contentStyleType:null,crossOrigin:null,cursor:null,cx:null,cy:null,d:null,dataType:null,defaultAction:null,descent:D,diffuseConstant:D,direction:null,display:null,dur:null,divisor:D,dominantBaseline:null,download:se,dx:null,dy:null,edgeMode:null,editable:null,elevation:D,enableBackground:null,end:null,event:null,exponent:D,externalResourcesRequired:null,fill:null,fillOpacity:D,fillRule:null,filter:null,filterRes:null,filterUnits:null,floodColor:null,floodOpacity:null,focusable:null,focusHighlight:null,fontFamily:null,fontSize:null,fontSizeAdjust:null,fontStretch:null,fontStyle:null,fontVariant:null,fontWeight:null,format:null,fr:null,from:null,fx:null,fy:null,g1:Wn,g2:Wn,glyphName:Wn,glyphOrientationHorizontal:null,glyphOrientationVertical:null,glyphRef:null,gradientTransform:null,gradientUnits:null,handler:null,hanging:D,hatchContentUnits:null,hatchUnits:null,height:null,href:null,hrefLang:null,horizAdvX:D,horizOriginX:D,horizOriginY:D,id:null,ideographic:D,imageRendering:null,initialVisibility:null,in:null,in2:null,intercept:D,k:D,k1:D,k2:D,k3:D,k4:D,kernelMatrix:st,kernelUnitLength:null,keyPoints:null,keySplines:null,keyTimes:null,kerning:null,lang:null,lengthAdjust:null,letterSpacing:null,lightingColor:null,limitingConeAngle:D,local:null,markerEnd:null,markerMid:null,markerStart:null,markerHeight:null,markerUnits:null,markerWidth:null,mask:null,maskContentUnits:null,maskUnits:null,mathematical:null,max:null,media:null,mediaCharacterEncoding:null,mediaContentEncodings:null,mediaSize:D,mediaTime:null,method:null,min:null,mode:null,name:null,navDown:null,navDownLeft:null,navDownRight:null,navLeft:null,navNext:null,navPrev:null,navRight:null,navUp:null,navUpLeft:null,navUpRight:null,numOctaves:null,observer:null,offset:null,onAbort:null,onActivate:null,onAfterPrint:null,onBeforePrint:null,onBegin:null,onCancel:null,onCanPlay:null,onCanPlayThrough:null,onChange:null,onClick:null,onClose:null,onCopy:null,onCueChange:null,onCut:null,onDblClick:null,onDrag:null,onDragEnd:null,onDragEnter:null,onDragExit:null,onDragLeave:null,onDragOver:null,onDragStart:null,onDrop:null,onDurationChange:null,onEmptied:null,onEnd:null,onEnded:null,onError:null,onFocus:null,onFocusIn:null,onFocusOut:null,onHashChange:null,onInput:null,onInvalid:null,onKeyDown:null,onKeyPress:null,onKeyUp:null,onLoad:null,onLoadedData:null,onLoadedMetadata:null,onLoadStart:null,onMessage:null,onMouseDown:null,onMouseEnter:null,onMouseLeave:null,onMouseMove:null,onMouseOut:null,onMouseOver:null,onMouseUp:null,onMouseWheel:null,onOffline:null,onOnline:null,onPageHide:null,onPageShow:null,onPaste:null,onPause:null,onPlay:null,onPlaying:null,onPopState:null,onProgress:null,onRateChange:null,onRepeat:null,onReset:null,onResize:null,onScroll:null,onSeeked:null,onSeeking:null,onSelect:null,onShow:null,onStalled:null,onStorage:null,onSubmit:null,onSuspend:null,onTimeUpdate:null,onToggle:null,onUnload:null,onVolumeChange:null,onWaiting:null,onZoom:null,opacity:null,operator:null,order:null,orient:null,orientation:null,origin:null,overflow:null,overlay:null,overlinePosition:D,overlineThickness:D,paintOrder:null,panose1:null,path:null,pathLength:D,patternContentUnits:null,patternTransform:null,patternUnits:null,phase:null,ping:ke,pitch:null,playbackOrder:null,pointerEvents:null,points:null,pointsAtX:D,pointsAtY:D,pointsAtZ:D,preserveAlpha:null,preserveAspectRatio:null,primitiveUnits:null,propagate:null,property:st,r:null,radius:null,referrerPolicy:null,refX:null,refY:null,rel:st,rev:st,renderingIntent:null,repeatCount:null,repeatDur:null,requiredExtensions:st,requiredFeatures:st,requiredFonts:st,requiredFormats:st,resource:null,restart:null,result:null,rotate:null,rx:null,ry:null,scale:null,seed:null,shapeRendering:null,side:null,slope:null,snapshotTime:null,specularConstant:D,specularExponent:D,spreadMethod:null,spacing:null,startOffset:null,stdDeviation:null,stemh:null,stemv:null,stitchTiles:null,stopColor:null,stopOpacity:null,strikethroughPosition:D,strikethroughThickness:D,string:null,stroke:null,strokeDashArray:st,strokeDashOffset:null,strokeLineCap:null,strokeLineJoin:null,strokeMiterLimit:D,strokeOpacity:D,strokeWidth:null,style:null,surfaceScale:D,syncBehavior:null,syncBehaviorDefault:null,syncMaster:null,syncTolerance:null,syncToleranceDefault:null,systemLanguage:st,tabIndex:D,tableValues:null,target:null,targetX:D,targetY:D,textAnchor:null,textDecoration:null,textRendering:null,textLength:null,timelineBegin:null,title:null,transformBehavior:null,type:null,typeOf:st,to:null,transform:null,transformOrigin:null,u1:null,u2:null,underlinePosition:D,underlineThickness:D,unicode:null,unicodeBidi:null,unicodeRange:null,unitsPerEm:D,values:null,vAlphabetic:D,vMathematical:D,vectorEffect:null,vHanging:D,vIdeographic:D,version:null,vertAdvY:D,vertOriginX:D,vertOriginY:D,viewBox:null,viewTarget:null,visibility:null,width:null,widths:null,wordSpacing:null,writingMode:null,x:null,x1:null,x2:null,xChannelSelector:null,xHeight:D,y:null,y1:null,y2:null,yChannelSelector:null,z:null,zoomAndPan:null},space:"svg",transform:uu}),du=Qn({properties:{xLinkActuate:null,xLinkArcRole:null,xLinkHref:null,xLinkRole:null,xLinkShow:null,xLinkTitle:null,xLinkType:null},space:"xlink",transform(e,t){return"xlink:"+t.slice(5).toLowerCase()}}),hu=Qn({attributes:{xmlnsxlink:"xmlns:xlink"},properties:{xmlnsXLink:null,xmlns:null},space:"xmlns",transform:fu}),pu=Qn({properties:{xmlBase:null,xmlLang:null,xmlSpace:null},space:"xml",transform(e,t){return"xml:"+t.slice(3).toLowerCase()}}),ym=/[A-Z]/g,Yl=/-[a-z]/g,vm=/^data[-\w.:]+$/i;function _m(e,t){const n=Ko(t);let s=t,r=tt;if(n in e.normal)return e.property[e.normal[n]];if(n.length>4&&n.slice(0,4)==="data"&&vm.test(t)){if(t.charAt(4)==="-"){const o=t.slice(5).replace(Yl,wm);s="data"+o.charAt(0).toUpperCase()+o.slice(1)}else{const o=t.slice(4);if(!Yl.test(o)){let i=o.replace(ym,bm);i.charAt(0)!=="-"&&(i="-"+i),t="data"+i}}r=Ri}return new r(s,t)}function bm(e){return"-"+e.toLowerCase()}function wm(e){return e.charAt(1).toUpperCase()}const Cm=au([cu,gm,du,hu,pu],"html"),gu=au([cu,mm,du,hu,pu],"svg"),Ql={}.hasOwnProperty;function xm(e,t){const n=t||{};function s(r,...o){let i=s.invalid;const l=s.handlers;if(r&&Ql.call(r,e)){const a=String(r[e]);i=Ql.call(l,a)?l[a]:s.unknown}if(i)return i.call(this,r,...o)}return s.handlers=n.handlers||{},s.invalid=n.invalid,s.unknown=n.unknown,s}const km=/["&'<>`]/g,Sm=/[\uD800-\uDBFF][\uDC00-\uDFFF]/g,Em=/[\x01-\t\v\f\x0E-\x1F\x7F\x81\x8D\x8F\x90\x9D\xA0-\uFFFF]/g,Am=/[|\\{}()[\]^$+*?.]/g,Zl=new WeakMap;function Rm(e,t){if(e=e.replace(t.subset?$m(t.subset):km,s),t.subset||t.escapeOnly)return e;return e.replace(Sm,n).replace(Em,s);function n(r,o,i){return t.format((r.charCodeAt(0)-55296)*1024+r.charCodeAt(1)-56320+65536,i.charCodeAt(o+2),t)}function s(r,o,i){return t.format(r.charCodeAt(0),i.charCodeAt(o+1),t)}}function $m(e){let t=Zl.get(e);return t||(t=Im(e),Zl.set(e,t)),t}function Im(e){const t=[];let n=-1;for(;++n<e.length;)t.push(e[n].replace(Am,"\\$&"));return new RegExp("(?:"+t.join("|")+")","g")}const Nm=/[\dA-Fa-f]/;function Pm(e,t,n){const s="&#x"+e.toString(16).toUpperCase();return n&&t&&!Nm.test(String.fromCharCode(t))?s:s+";"}const Om=/\d/;function Tm(e,t,n){const s="&#"+String(e);return n&&t&&!Om.test(String.fromCharCode(t))?s:s+";"}const Mm=["AElig","AMP","Aacute","Acirc","Agrave","Aring","Atilde","Auml","COPY","Ccedil","ETH","Eacute","Ecirc","Egrave","Euml","GT","Iacute","Icirc","Igrave","Iuml","LT","Ntilde","Oacute","Ocirc","Ograve","Oslash","Otilde","Ouml","QUOT","REG","THORN","Uacute","Ucirc","Ugrave","Uuml","Yacute","aacute","acirc","acute","aelig","agrave","amp","aring","atilde","auml","brvbar","ccedil","cedil","cent","copy","curren","deg","divide","eacute","ecirc","egrave","eth","euml","frac12","frac14","frac34","gt","iacute","icirc","iexcl","igrave","iquest","iuml","laquo","lt","macr","micro","middot","nbsp","not","ntilde","oacute","ocirc","ograve","ordf","ordm","oslash","otilde","ouml","para","plusmn","pound","quot","raquo","reg","sect","shy","sup1","sup2","sup3","szlig","thorn","times","uacute","ucirc","ugrave","uml","uuml","yacute","yen","yuml"],mo={nbsp:" ",iexcl:"¡",cent:"¢",pound:"£",curren:"¤",yen:"¥",brvbar:"¦",sect:"§",uml:"¨",copy:"©",ordf:"ª",laquo:"«",not:"¬",shy:"­",reg:"®",macr:"¯",deg:"°",plusmn:"±",sup2:"²",sup3:"³",acute:"´",micro:"µ",para:"¶",middot:"·",cedil:"¸",sup1:"¹",ordm:"º",raquo:"»",frac14:"¼",frac12:"½",frac34:"¾",iquest:"¿",Agrave:"À",Aacute:"Á",Acirc:"Â",Atilde:"Ã",Auml:"Ä",Aring:"Å",AElig:"Æ",Ccedil:"Ç",Egrave:"È",Eacute:"É",Ecirc:"Ê",Euml:"Ë",Igrave:"Ì",Iacute:"Í",Icirc:"Î",Iuml:"Ï",ETH:"Ð",Ntilde:"Ñ",Ograve:"Ò",Oacute:"Ó",Ocirc:"Ô",Otilde:"Õ",Ouml:"Ö",times:"×",Oslash:"Ø",Ugrave:"Ù",Uacute:"Ú",Ucirc:"Û",Uuml:"Ü",Yacute:"Ý",THORN:"Þ",szlig:"ß",agrave:"à",aacute:"á",acirc:"â",atilde:"ã",auml:"ä",aring:"å",aelig:"æ",ccedil:"ç",egrave:"è",eacute:"é",ecirc:"ê",euml:"ë",igrave:"ì",iacute:"í",icirc:"î",iuml:"ï",eth:"ð",ntilde:"ñ",ograve:"ò",oacute:"ó",ocirc:"ô",otilde:"õ",ouml:"ö",divide:"÷",oslash:"ø",ugrave:"ù",uacute:"ú",ucirc:"û",uuml:"ü",yacute:"ý",thorn:"þ",yuml:"ÿ",fnof:"ƒ",Alpha:"Α",Beta:"Β",Gamma:"Γ",Delta:"Δ",Epsilon:"Ε",Zeta:"Ζ",Eta:"Η",Theta:"Θ",Iota:"Ι",Kappa:"Κ",Lambda:"Λ",Mu:"Μ",Nu:"Ν",Xi:"Ξ",Omicron:"Ο",Pi:"Π",Rho:"Ρ",Sigma:"Σ",Tau:"Τ",Upsilon:"Υ",Phi:"Φ",Chi:"Χ",Psi:"Ψ",Omega:"Ω",alpha:"α",beta:"β",gamma:"γ",delta:"δ",epsilon:"ε",zeta:"ζ",eta:"η",theta:"θ",iota:"ι",kappa:"κ",lambda:"λ",mu:"μ",nu:"ν",xi:"ξ",omicron:"ο",pi:"π",rho:"ρ",sigmaf:"ς",sigma:"σ",tau:"τ",upsilon:"υ",phi:"φ",chi:"χ",psi:"ψ",omega:"ω",thetasym:"ϑ",upsih:"ϒ",piv:"ϖ",bull:"•",hellip:"…",prime:"′",Prime:"″",oline:"‾",frasl:"⁄",weierp:"℘",image:"ℑ",real:"ℜ",trade:"™",alefsym:"ℵ",larr:"←",uarr:"↑",rarr:"→",darr:"↓",harr:"↔",crarr:"↵",lArr:"⇐",uArr:"⇑",rArr:"⇒",dArr:"⇓",hArr:"⇔",forall:"∀",part:"∂",exist:"∃",empty:"∅",nabla:"∇",isin:"∈",notin:"∉",ni:"∋",prod:"∏",sum:"∑",minus:"−",lowast:"∗",radic:"√",prop:"∝",infin:"∞",ang:"∠",and:"∧",or:"∨",cap:"∩",cup:"∪",int:"∫",there4:"∴",sim:"∼",cong:"≅",asymp:"≈",ne:"≠",equiv:"≡",le:"≤",ge:"≥",sub:"⊂",sup:"⊃",nsub:"⊄",sube:"⊆",supe:"⊇",oplus:"⊕",otimes:"⊗",perp:"⊥",sdot:"⋅",lceil:"⌈",rceil:"⌉",lfloor:"⌊",rfloor:"⌋",lang:"〈",rang:"〉",loz:"◊",spades:"♠",clubs:"♣",hearts:"♥",diams:"♦",quot:'"',amp:"&",lt:"<",gt:">",OElig:"Œ",oelig:"œ",Scaron:"Š",scaron:"š",Yuml:"Ÿ",circ:"ˆ",tilde:"˜",ensp:" ",emsp:" ",thinsp:" ",zwnj:"‌",zwj:"‍",lrm:"‎",rlm:"‏",ndash:"–",mdash:"—",lsquo:"‘",rsquo:"’",sbquo:"‚",ldquo:"“",rdquo:"”",bdquo:"„",dagger:"†",Dagger:"‡",permil:"‰",lsaquo:"‹",rsaquo:"›",euro:"€"},Lm=["cent","copy","divide","gt","lt","not","para","times"],mu={}.hasOwnProperty,Yo={};let Hs;for(Hs in mo)mu.call(mo,Hs)&&(Yo[mo[Hs]]=Hs);const Dm=/[^\dA-Za-z]/;function Gm(e,t,n,s){const r=String.fromCharCode(e);if(mu.call(Yo,r)){const o=Yo[r],i="&"+o;return n&&Mm.includes(o)&&!Lm.includes(o)&&(!s||t&&t!==61&&Dm.test(String.fromCharCode(t)))?i:i+";"}return""}function jm(e,t,n){let s=Pm(e,t,n.omitOptionalSemicolons),r;if((n.useNamedReferences||n.useShortestReferences)&&(r=Gm(e,t,n.omitOptionalSemicolons,n.attribute)),(n.useShortestReferences||!r)&&n.useShortestReferences){const o=Tm(e,t,n.omitOptionalSemicolons);o.length<s.length&&(s=o)}return r&&(!n.useShortestReferences||r.length<s.length)?r:s}function Vn(e,t){return Rm(e,Object.assign({format:jm},t))}const Fm=/^>|^->|<!--|-->|--!>|<!-$/g,Bm=[">"],Um=["<",">"];function Hm(e,t,n,s){return s.settings.bogusComments?"<?"+Vn(e.value,Object.assign({},s.settings.characterReferences,{subset:Bm}))+">":"<!--"+e.value.replace(Fm,r)+"-->";function r(o){return Vn(o,Object.assign({},s.settings.characterReferences,{subset:Um}))}}function Wm(e,t,n,s){return"<!"+(s.settings.upperDoctype?"DOCTYPE":"doctype")+(s.settings.tightDoctype?"":" ")+"html>"}function ea(e,t){const n=String(e);if(typeof t!="string")throw new TypeError("Expected character");let s=0,r=n.indexOf(t);for(;r!==-1;)s++,r=n.indexOf(t,r+t.length);return s}function Vm(e,t){const n=t||{};return(e[e.length-1]===""?[...e,""]:e).join((n.padRight?" ":"")+","+(n.padLeft===!1?"":" ")).trim()}function qm(e){return e.join(" ").trim()}const zm=/[ \t\n\f\r]/g;function $i(e){return typeof e=="object"?e.type==="text"?ta(e.value):!1:ta(e)}function ta(e){return e.replace(zm,"")===""}const Me=vu(1),yu=vu(-1),Km=[];function vu(e){return t;function t(n,s,r){const o=n?n.children:Km;let i=(s||0)+e,l=o[i];if(!r)for(;l&&$i(l);)i+=e,l=o[i];return l}}const Xm={}.hasOwnProperty;function _u(e){return t;function t(n,s,r){return Xm.call(e,n.tagName)&&e[n.tagName](n,s,r)}}const Ii=_u({body:Ym,caption:yo,colgroup:yo,dd:ty,dt:ey,head:yo,html:Jm,li:Zm,optgroup:ny,option:sy,p:Qm,rp:na,rt:na,tbody:oy,td:sa,tfoot:iy,th:sa,thead:ry,tr:ly});function yo(e,t,n){const s=Me(n,t,!0);return!s||s.type!=="comment"&&!(s.type==="text"&&$i(s.value.charAt(0)))}function Jm(e,t,n){const s=Me(n,t);return!s||s.type!=="comment"}function Ym(e,t,n){const s=Me(n,t);return!s||s.type!=="comment"}function Qm(e,t,n){const s=Me(n,t);return s?s.type==="element"&&(s.tagName==="address"||s.tagName==="article"||s.tagName==="aside"||s.tagName==="blockquote"||s.tagName==="details"||s.tagName==="div"||s.tagName==="dl"||s.tagName==="fieldset"||s.tagName==="figcaption"||s.tagName==="figure"||s.tagName==="footer"||s.tagName==="form"||s.tagName==="h1"||s.tagName==="h2"||s.tagName==="h3"||s.tagName==="h4"||s.tagName==="h5"||s.tagName==="h6"||s.tagName==="header"||s.tagName==="hgroup"||s.tagName==="hr"||s.tagName==="main"||s.tagName==="menu"||s.tagName==="nav"||s.tagName==="ol"||s.tagName==="p"||s.tagName==="pre"||s.tagName==="section"||s.tagName==="table"||s.tagName==="ul"):!n||!(n.type==="element"&&(n.tagName==="a"||n.tagName==="audio"||n.tagName==="del"||n.tagName==="ins"||n.tagName==="map"||n.tagName==="noscript"||n.tagName==="video"))}function Zm(e,t,n){const s=Me(n,t);return!s||s.type==="element"&&s.tagName==="li"}function ey(e,t,n){const s=Me(n,t);return!!(s&&s.type==="element"&&(s.tagName==="dt"||s.tagName==="dd"))}function ty(e,t,n){const s=Me(n,t);return!s||s.type==="element"&&(s.tagName==="dt"||s.tagName==="dd")}function na(e,t,n){const s=Me(n,t);return!s||s.type==="element"&&(s.tagName==="rp"||s.tagName==="rt")}function ny(e,t,n){const s=Me(n,t);return!s||s.type==="element"&&s.tagName==="optgroup"}function sy(e,t,n){const s=Me(n,t);return!s||s.type==="element"&&(s.tagName==="option"||s.tagName==="optgroup")}function ry(e,t,n){const s=Me(n,t);return!!(s&&s.type==="element"&&(s.tagName==="tbody"||s.tagName==="tfoot"))}function oy(e,t,n){const s=Me(n,t);return!s||s.type==="element"&&(s.tagName==="tbody"||s.tagName==="tfoot")}function iy(e,t,n){return!Me(n,t)}function ly(e,t,n){const s=Me(n,t);return!s||s.type==="element"&&s.tagName==="tr"}function sa(e,t,n){const s=Me(n,t);return!s||s.type==="element"&&(s.tagName==="td"||s.tagName==="th")}const ay=_u({body:fy,colgroup:dy,head:uy,html:cy,tbody:hy});function cy(e){const t=Me(e,-1);return!t||t.type!=="comment"}function uy(e){const t=new Set;for(const s of e.children)if(s.type==="element"&&(s.tagName==="base"||s.tagName==="title")){if(t.has(s.tagName))return!1;t.add(s.tagName)}const n=e.children[0];return!n||n.type==="element"}function fy(e){const t=Me(e,-1,!0);return!t||t.type!=="comment"&&!(t.type==="text"&&$i(t.value.charAt(0)))&&!(t.type==="element"&&(t.tagName==="meta"||t.tagName==="link"||t.tagName==="script"||t.tagName==="style"||t.tagName==="template"))}function dy(e,t,n){const s=yu(n,t),r=Me(e,-1,!0);return n&&s&&s.type==="element"&&s.tagName==="colgroup"&&Ii(s,n.children.indexOf(s),n)?!1:!!(r&&r.type==="element"&&r.tagName==="col")}function hy(e,t,n){const s=yu(n,t),r=Me(e,-1);return n&&s&&s.type==="element"&&(s.tagName==="thead"||s.tagName==="tbody")&&Ii(s,n.children.indexOf(s),n)?!1:!!(r&&r.type==="element"&&r.tagName==="tr")}const Ws={name:[[`
28
+ \f\r &/=>`.split(""),`
29
+ \f\r "&'/=>\``.split("")],[`\0
30
+ \f\r "&'/<=>`.split(""),`\0
31
+ \f\r "&'/<=>\``.split("")]],unquoted:[[`
32
+ \f\r &>`.split(""),`\0
33
+ \f\r "&'<=>\``.split("")],[`\0
34
+ \f\r "&'<=>\``.split(""),`\0
35
+ \f\r "&'<=>\``.split("")]],single:[["&'".split(""),"\"&'`".split("")],["\0&'".split(""),"\0\"&'`".split("")]],double:[['"&'.split(""),"\"&'`".split("")],['\0"&'.split(""),"\0\"&'`".split("")]]};function py(e,t,n,s){const r=s.schema,o=r.space==="svg"?!1:s.settings.omitOptionalTags;let i=r.space==="svg"?s.settings.closeEmptyElements:s.settings.voids.includes(e.tagName.toLowerCase());const l=[];let a;r.space==="html"&&e.tagName==="svg"&&(s.schema=gu);const c=gy(s,e.properties),u=s.all(r.space==="html"&&e.tagName==="template"?e.content:e);return s.schema=r,u&&(i=!1),(c||!o||!ay(e,t,n))&&(l.push("<",e.tagName,c?" "+c:""),i&&(r.space==="svg"||s.settings.closeSelfClosing)&&(a=c.charAt(c.length-1),(!s.settings.tightSelfClosing||a==="/"||a&&a!=='"'&&a!=="'")&&l.push(" "),l.push("/")),l.push(">")),l.push(u),!i&&(!o||!Ii(e,t,n))&&l.push("</"+e.tagName+">"),l.join("")}function gy(e,t){const n=[];let s=-1,r;if(t){for(r in t)if(t[r]!==null&&t[r]!==void 0){const o=my(e,r,t[r]);o&&n.push(o)}}for(;++s<n.length;){const o=e.settings.tightAttributes?n[s].charAt(n[s].length-1):void 0;s!==n.length-1&&o!=='"'&&o!=="'"&&(n[s]+=" ")}return n.join("")}function my(e,t,n){const s=_m(e.schema,t),r=e.settings.allowParseErrors&&e.schema.space==="html"?0:1,o=e.settings.allowDangerousCharacters?0:1;let i=e.quote,l;if(s.overloadedBoolean&&(n===s.attribute||n==="")?n=!0:(s.boolean||s.overloadedBoolean)&&(typeof n!="string"||n===s.attribute||n==="")&&(n=!!n),n==null||n===!1||typeof n=="number"&&Number.isNaN(n))return"";const a=Vn(s.attribute,Object.assign({},e.settings.characterReferences,{subset:Ws.name[r][o]}));return n===!0||(n=Array.isArray(n)?(s.commaSeparated?Vm:qm)(n,{padLeft:!e.settings.tightCommaSeparatedLists}):String(n),e.settings.collapseEmptyAttributes&&!n)?a:(e.settings.preferUnquoted&&(l=Vn(n,Object.assign({},e.settings.characterReferences,{attribute:!0,subset:Ws.unquoted[r][o]}))),l!==n&&(e.settings.quoteSmart&&ea(n,i)>ea(n,e.alternative)&&(i=e.alternative),l=i+Vn(n,Object.assign({},e.settings.characterReferences,{subset:(i==="'"?Ws.single:Ws.double)[r][o],attribute:!0}))+i),a+(l&&"="+l))}const yy=["<","&"];function bu(e,t,n,s){return n&&n.type==="element"&&(n.tagName==="script"||n.tagName==="style")?e.value:Vn(e.value,Object.assign({},s.settings.characterReferences,{subset:yy}))}function vy(e,t,n,s){return s.settings.allowDangerousHtml?e.value:bu(e,t,n,s)}function _y(e,t,n,s){return s.all(e)}const by=xm("type",{invalid:wy,unknown:Cy,handlers:{comment:Hm,doctype:Wm,element:py,raw:vy,root:_y,text:bu}});function wy(e){throw new Error("Expected node, not `"+e+"`")}function Cy(e){const t=e;throw new Error("Cannot compile unknown node `"+t.type+"`")}const xy={},ky={},Sy=[];function Ey(e,t){const n=t||xy,s=n.quote||'"',r=s==='"'?"'":'"';if(s!=='"'&&s!=="'")throw new Error("Invalid quote `"+s+"`, expected `'` or `\"`");return{one:Ay,all:Ry,settings:{omitOptionalTags:n.omitOptionalTags||!1,allowParseErrors:n.allowParseErrors||!1,allowDangerousCharacters:n.allowDangerousCharacters||!1,quoteSmart:n.quoteSmart||!1,preferUnquoted:n.preferUnquoted||!1,tightAttributes:n.tightAttributes||!1,upperDoctype:n.upperDoctype||!1,tightDoctype:n.tightDoctype||!1,bogusComments:n.bogusComments||!1,tightCommaSeparatedLists:n.tightCommaSeparatedLists||!1,tightSelfClosing:n.tightSelfClosing||!1,collapseEmptyAttributes:n.collapseEmptyAttributes||!1,allowDangerousHtml:n.allowDangerousHtml||!1,voids:n.voids||hm,characterReferences:n.characterReferences||ky,closeSelfClosing:n.closeSelfClosing||!1,closeEmptyElements:n.closeEmptyElements||!1},schema:n.space==="svg"?gu:Cm,quote:s,alternative:r}.one(Array.isArray(e)?{type:"root",children:e}:e,void 0,void 0)}function Ay(e,t,n){return by(e,t,n,this)}function Ry(e){const t=[],n=e&&e.children||Sy;let s=-1;for(;++s<n.length;)t[s]=this.one(n[s],s,e);return t.join("")}function Cr(e,t){const n=typeof e=="string"?{}:{...e.colorReplacements},s=typeof e=="string"?e:e.name;for(const[r,o]of Object.entries((t==null?void 0:t.colorReplacements)||{}))typeof o=="string"?n[r]=o:r===s&&Object.assign(n,o);return n}function an(e,t){return e&&((t==null?void 0:t[e==null?void 0:e.toLowerCase()])||e)}function $y(e){return Array.isArray(e)?e:[e]}async function wu(e){return Promise.resolve(typeof e=="function"?e():e).then(t=>t.default||t)}function Ni(e){return!e||["plaintext","txt","text","plain"].includes(e)}function Iy(e){return e==="ansi"||Ni(e)}function Pi(e){return e==="none"}function Ny(e){return Pi(e)}function Cu(e,t){var s;if(!t)return e;e.properties||(e.properties={}),(s=e.properties).class||(s.class=[]),typeof e.properties.class=="string"&&(e.properties.class=e.properties.class.split(/\s+/g)),Array.isArray(e.properties.class)||(e.properties.class=[]);const n=Array.isArray(t)?t:t.split(/\s+/g);for(const r of n)r&&!e.properties.class.includes(r)&&e.properties.class.push(r);return e}function Wr(e,t=!1){var o;if(e.length===0)return[["",0]];const n=e.split(/(\r?\n)/g);let s=0;const r=[];for(let i=0;i<n.length;i+=2){const l=t?n[i]+(n[i+1]||""):n[i];r.push([l,s]),s+=n[i].length,s+=((o=n[i+1])==null?void 0:o.length)||0}return r}function Py(e){const t=Wr(e,!0).map(([r])=>r);function n(r){if(r===e.length)return{line:t.length-1,character:t[t.length-1].length};let o=r,i=0;for(const l of t){if(o<l.length)break;o-=l.length,i++}return{line:i,character:o}}function s(r,o){let i=0;for(let l=0;l<r;l++)i+=t[l].length;return i+=o,i}return{lines:t,indexToPos:n,posToIndex:s}}const Oi="light-dark()",Oy=["color","background-color"];function Ty(e,t){let n=0;const s=[];for(const r of t)r>n&&s.push({...e,content:e.content.slice(n,r),offset:e.offset+n}),n=r;return n<e.content.length&&s.push({...e,content:e.content.slice(n),offset:e.offset+n}),s}function My(e,t){const n=Array.from(t instanceof Set?t:new Set(t)).sort((s,r)=>s-r);return n.length?e.map(s=>s.flatMap(r=>{const o=n.filter(i=>r.offset<i&&i<r.offset+r.content.length).map(i=>i-r.offset).sort((i,l)=>i-l);return o.length?Ty(r,o):r})):e}function Ly(e,t,n,s,r="css-vars"){const o={content:e.content,explanation:e.explanation,offset:e.offset},i=t.map(u=>xr(e.variants[u])),l=new Set(i.flatMap(u=>Object.keys(u))),a={},c=(u,f)=>{const d=f==="color"?"":f==="background-color"?"-bg":`-${f}`;return n+t[u]+(f==="color"?"":d)};return i.forEach((u,f)=>{for(const d of l){const h=u[d]||"inherit";if(f===0&&s&&Oy.includes(d))if(s===Oi&&i.length>1){const m=t.findIndex(E=>E==="light"),v=t.findIndex(E=>E==="dark");if(m===-1||v===-1)throw new Le('When using `defaultColor: "light-dark()"`, you must provide both `light` and `dark` themes');const x=i[m][d]||"inherit",k=i[v][d]||"inherit";a[d]=`light-dark(${x}, ${k})`,r==="css-vars"&&(a[c(f,d)]=h)}else a[d]=h;else r==="css-vars"&&(a[c(f,d)]=h)}}),o.htmlStyle=a,o}function xr(e){const t={};if(e.color&&(t.color=e.color),e.bgColor&&(t["background-color"]=e.bgColor),e.fontStyle){e.fontStyle&He.Italic&&(t["font-style"]="italic"),e.fontStyle&He.Bold&&(t["font-weight"]="bold");const n=[];e.fontStyle&He.Underline&&n.push("underline"),e.fontStyle&He.Strikethrough&&n.push("line-through"),n.length&&(t["text-decoration"]=n.join(" "))}return t}function Qo(e){return typeof e=="string"?e:Object.entries(e).map(([t,n])=>`${t}:${n}`).join(";")}const xu=new WeakMap;function Vr(e,t){xu.set(e,t)}function $s(e){return xu.get(e)}class Zn{constructor(...t){$(this,"_stacks",{});$(this,"lang");if(t.length===2){const[n,s]=t;this.lang=s,this._stacks=n}else{const[n,s,r]=t;this.lang=s,this._stacks={[r]:n}}}get themes(){return Object.keys(this._stacks)}get theme(){return this.themes[0]}get _stack(){return this._stacks[this.theme]}static initial(t,n){return new Zn(Object.fromEntries($y(n).map(s=>[s,zo])),t)}getInternalStack(t=this.theme){return this._stacks[t]}getScopes(t=this.theme){return Dy(this._stacks[t])}toJSON(){return{lang:this.lang,theme:this.theme,themes:this.themes,scopes:this.getScopes()}}}function Dy(e){const t=[],n=new Set;function s(r){var i;if(n.has(r))return;n.add(r);const o=(i=r==null?void 0:r.nameScopesList)==null?void 0:i.scopeName;o&&t.push(o),r.parent&&s(r.parent)}return s(e),t}function Gy(e,t){if(!(e instanceof Zn))throw new Le("Invalid grammar state");return e.getInternalStack(t)}function jy(){const e=new WeakMap;function t(n){if(!e.has(n.meta)){let s=function(i){if(typeof i=="number"){if(i<0||i>n.source.length)throw new Le(`Invalid decoration offset: ${i}. Code length: ${n.source.length}`);return{...r.indexToPos(i),offset:i}}else{const l=r.lines[i.line];if(l===void 0)throw new Le(`Invalid decoration position ${JSON.stringify(i)}. Lines length: ${r.lines.length}`);let a=i.character;if(a<0&&(a=l.length+a),a<0||a>l.length)throw new Le(`Invalid decoration position ${JSON.stringify(i)}. Line ${i.line} length: ${l.length}`);return{...i,character:a,offset:r.posToIndex(i.line,a)}}};const r=Py(n.source),o=(n.options.decorations||[]).map(i=>({...i,start:s(i.start),end:s(i.end)}));Fy(o),e.set(n.meta,{decorations:o,converter:r,source:n.source})}return e.get(n.meta)}return{name:"shiki:decorations",tokens(n){var i;if(!((i=this.options.decorations)!=null&&i.length))return;const r=t(this).decorations.flatMap(l=>[l.start.offset,l.end.offset]);return My(n,r)},code(n){var u;if(!((u=this.options.decorations)!=null&&u.length))return;const s=t(this),r=Array.from(n.children).filter(f=>f.type==="element"&&f.tagName==="span");if(r.length!==s.converter.lines.length)throw new Le(`Number of lines in code element (${r.length}) does not match the number of lines in the source (${s.converter.lines.length}). Failed to apply decorations.`);function o(f,d,h,m){const v=r[f];let x="",k=-1,E=-1;if(d===0&&(k=0),h===0&&(E=0),h===Number.POSITIVE_INFINITY&&(E=v.children.length),k===-1||E===-1)for(let R=0;R<v.children.length;R++)x+=ku(v.children[R]),k===-1&&x.length===d&&(k=R+1),E===-1&&x.length===h&&(E=R+1);if(k===-1)throw new Le(`Failed to find start index for decoration ${JSON.stringify(m.start)}`);if(E===-1)throw new Le(`Failed to find end index for decoration ${JSON.stringify(m.end)}`);const b=v.children.slice(k,E);if(!m.alwaysWrap&&b.length===v.children.length)l(v,m,"line");else if(!m.alwaysWrap&&b.length===1&&b[0].type==="element")l(b[0],m,"token");else{const R={type:"element",tagName:"span",properties:{},children:b};l(R,m,"wrapper"),v.children.splice(k,b.length,R)}}function i(f,d){r[f]=l(r[f],d,"line")}function l(f,d,h){var x;const m=d.properties||{},v=d.transform||(k=>k);return f.tagName=d.tagName||"span",f.properties={...f.properties,...m,class:f.properties.class},(x=d.properties)!=null&&x.class&&Cu(f,d.properties.class),f=v(f,h)||f,f}const a=[],c=s.decorations.sort((f,d)=>d.start.offset-f.start.offset||f.end.offset-d.end.offset);for(const f of c){const{start:d,end:h}=f;if(d.line===h.line)o(d.line,d.character,h.character,f);else if(d.line<h.line){o(d.line,d.character,Number.POSITIVE_INFINITY,f);for(let m=d.line+1;m<h.line;m++)a.unshift(()=>i(m,f));o(h.line,0,h.character,f)}}a.forEach(f=>f())}}}function Fy(e){for(let t=0;t<e.length;t++){const n=e[t];if(n.start.offset>n.end.offset)throw new Le(`Invalid decoration range: ${JSON.stringify(n.start)} - ${JSON.stringify(n.end)}`);for(let s=t+1;s<e.length;s++){const r=e[s],o=n.start.offset<=r.start.offset&&r.start.offset<n.end.offset,i=n.start.offset<r.end.offset&&r.end.offset<=n.end.offset,l=r.start.offset<=n.start.offset&&n.start.offset<r.end.offset,a=r.start.offset<n.end.offset&&n.end.offset<=r.end.offset;if(o||i||l||a){if(o&&i||l&&a||l&&n.start.offset===n.end.offset||i&&r.start.offset===r.end.offset)continue;throw new Le(`Decorations ${JSON.stringify(n.start)} and ${JSON.stringify(r.start)} intersect.`)}}}}function ku(e){return e.type==="text"?e.value:e.type==="element"?e.children.map(ku).join(""):""}const By=[jy()];function kr(e){const t=Uy(e.transformers||[]);return[...t.pre,...t.normal,...t.post,...By]}function Uy(e){const t=[],n=[],s=[];for(const r of e)switch(r.enforce){case"pre":t.push(r);break;case"post":n.push(r);break;default:s.push(r)}return{pre:t,post:n,normal:s}}var wn=["black","red","green","yellow","blue","magenta","cyan","white","brightBlack","brightRed","brightGreen","brightYellow","brightBlue","brightMagenta","brightCyan","brightWhite"],vo={1:"bold",2:"dim",3:"italic",4:"underline",7:"reverse",8:"hidden",9:"strikethrough"};function Hy(e,t){const n=e.indexOf("\x1B",t);if(n!==-1&&e[n+1]==="["){const s=e.indexOf("m",n);if(s!==-1)return{sequence:e.substring(n+2,s).split(";"),startPosition:n,position:s+1}}return{position:e.length}}function ra(e){const t=e.shift();if(t==="2"){const n=e.splice(0,3).map(s=>Number.parseInt(s));return n.length!==3||n.some(s=>Number.isNaN(s))?void 0:{type:"rgb",rgb:n}}else if(t==="5"){const n=e.shift();if(n)return{type:"table",index:Number(n)}}}function Wy(e){const t=[];for(;e.length>0;){const n=e.shift();if(!n)continue;const s=Number.parseInt(n);if(!Number.isNaN(s))if(s===0)t.push({type:"resetAll"});else if(s<=9)vo[s]&&t.push({type:"setDecoration",value:vo[s]});else if(s<=29){const r=vo[s-20];r&&(t.push({type:"resetDecoration",value:r}),r==="dim"&&t.push({type:"resetDecoration",value:"bold"}))}else if(s<=37)t.push({type:"setForegroundColor",value:{type:"named",name:wn[s-30]}});else if(s===38){const r=ra(e);r&&t.push({type:"setForegroundColor",value:r})}else if(s===39)t.push({type:"resetForegroundColor"});else if(s<=47)t.push({type:"setBackgroundColor",value:{type:"named",name:wn[s-40]}});else if(s===48){const r=ra(e);r&&t.push({type:"setBackgroundColor",value:r})}else s===49?t.push({type:"resetBackgroundColor"}):s===53?t.push({type:"setDecoration",value:"overline"}):s===55?t.push({type:"resetDecoration",value:"overline"}):s>=90&&s<=97?t.push({type:"setForegroundColor",value:{type:"named",name:wn[s-90+8]}}):s>=100&&s<=107&&t.push({type:"setBackgroundColor",value:{type:"named",name:wn[s-100+8]}})}return t}function Vy(){let e=null,t=null,n=new Set;return{parse(s){const r=[];let o=0;do{const i=Hy(s,o),l=i.sequence?s.substring(o,i.startPosition):s.substring(o);if(l.length>0&&r.push({value:l,foreground:e,background:t,decorations:new Set(n)}),i.sequence){const a=Wy(i.sequence);for(const c of a)c.type==="resetAll"?(e=null,t=null,n.clear()):c.type==="resetForegroundColor"?e=null:c.type==="resetBackgroundColor"?t=null:c.type==="resetDecoration"&&n.delete(c.value);for(const c of a)c.type==="setForegroundColor"?e=c.value:c.type==="setBackgroundColor"?t=c.value:c.type==="setDecoration"&&n.add(c.value)}o=i.position}while(o<s.length);return r}}}var qy={black:"#000000",red:"#bb0000",green:"#00bb00",yellow:"#bbbb00",blue:"#0000bb",magenta:"#ff00ff",cyan:"#00bbbb",white:"#eeeeee",brightBlack:"#555555",brightRed:"#ff5555",brightGreen:"#00ff00",brightYellow:"#ffff55",brightBlue:"#5555ff",brightMagenta:"#ff55ff",brightCyan:"#55ffff",brightWhite:"#ffffff"};function zy(e=qy){function t(l){return e[l]}function n(l){return`#${l.map(a=>Math.max(0,Math.min(a,255)).toString(16).padStart(2,"0")).join("")}`}let s;function r(){if(s)return s;s=[];for(let c=0;c<wn.length;c++)s.push(t(wn[c]));let l=[0,95,135,175,215,255];for(let c=0;c<6;c++)for(let u=0;u<6;u++)for(let f=0;f<6;f++)s.push(n([l[c],l[u],l[f]]));let a=8;for(let c=0;c<24;c++,a+=10)s.push(n([a,a,a]));return s}function o(l){return r()[l]}function i(l){switch(l.type){case"named":return t(l.name);case"rgb":return n(l.rgb);case"table":return o(l.index)}}return{value:i}}const Ky={black:"#000000",red:"#cd3131",green:"#0DBC79",yellow:"#E5E510",blue:"#2472C8",magenta:"#BC3FBC",cyan:"#11A8CD",white:"#E5E5E5",brightBlack:"#666666",brightRed:"#F14C4C",brightGreen:"#23D18B",brightYellow:"#F5F543",brightBlue:"#3B8EEA",brightMagenta:"#D670D6",brightCyan:"#29B8DB",brightWhite:"#FFFFFF"};function Xy(e,t,n){const s=Cr(e,n),r=Wr(t),o=Object.fromEntries(wn.map(a=>{var f;const c=`terminal.ansi${a[0].toUpperCase()}${a.substring(1)}`,u=(f=e.colors)==null?void 0:f[c];return[a,u||Ky[a]]})),i=zy(o),l=Vy();return r.map(a=>l.parse(a[0]).map(c=>{let u,f;c.decorations.has("reverse")?(u=c.background?i.value(c.background):e.bg,f=c.foreground?i.value(c.foreground):e.fg):(u=c.foreground?i.value(c.foreground):e.fg,f=c.background?i.value(c.background):void 0),u=an(u,s),f=an(f,s),c.decorations.has("dim")&&(u=Jy(u));let d=He.None;return c.decorations.has("bold")&&(d|=He.Bold),c.decorations.has("italic")&&(d|=He.Italic),c.decorations.has("underline")&&(d|=He.Underline),c.decorations.has("strikethrough")&&(d|=He.Strikethrough),{content:c.value,offset:a[1],color:u,bgColor:f,fontStyle:d}}))}function Jy(e){const t=e.match(/#([0-9a-f]{3,8})/i);if(t){const s=t[1];if(s.length===8){const r=Math.round(Number.parseInt(s.slice(6,8),16)/2).toString(16).padStart(2,"0");return`#${s.slice(0,6)}${r}`}else{if(s.length===6)return`#${s}80`;if(s.length===4){const r=s[0],o=s[1],i=s[2],l=s[3],a=Math.round(Number.parseInt(`${l}${l}`,16)/2).toString(16).padStart(2,"0");return`#${r}${r}${o}${o}${i}${i}${a}`}else if(s.length===3){const r=s[0],o=s[1],i=s[2];return`#${r}${r}${o}${o}${i}${i}80`}}}const n=e.match(/var\((--[\w-]+-ansi-[\w-]+)\)/);return n?`var(${n[1]}-dim)`:e}function Ti(e,t,n={}){const{theme:s=e.getLoadedThemes()[0]}=n,r=e.resolveLangAlias(n.lang||"text");if(Ni(r)||Pi(s))return Wr(t).map(a=>[{content:a[0],offset:a[1]}]);const{theme:o,colorMap:i}=e.setTheme(s);if(r==="ansi")return Xy(o,t,n);const l=e.getLanguage(n.lang||"text");if(n.grammarState){if(n.grammarState.lang!==l.name)throw new Le(`Grammar state language "${n.grammarState.lang}" does not match highlight language "${l.name}"`);if(!n.grammarState.themes.includes(o.name))throw new Le(`Grammar state themes "${n.grammarState.themes}" do not contain highlight theme "${o.name}"`)}return Qy(t,l,o,i,n)}function Yy(...e){if(e.length===2)return $s(e[1]);const[t,n,s={}]=e,{lang:r="text",theme:o=t.getLoadedThemes()[0]}=s;if(Ni(r)||Pi(o))throw new Le("Plain language does not have grammar state");if(r==="ansi")throw new Le("ANSI language does not have grammar state");const{theme:i,colorMap:l}=t.setTheme(o),a=t.getLanguage(r);return new Zn(Mi(n,a,i,l,s).stateStack,a.name,i.name)}function Qy(e,t,n,s,r){const o=Mi(e,t,n,s,r),i=new Zn(o.stateStack,t.name,n.name);return Vr(o.tokens,i),o.tokens}function Mi(e,t,n,s,r){const o=Cr(n,r),{tokenizeMaxLineLength:i=0,tokenizeTimeLimit:l=500}=r,a=Wr(e);let c=r.grammarState?Gy(r.grammarState,n.name)??zo:r.grammarContextCode!=null?Mi(r.grammarContextCode,t,n,s,{...r,grammarState:void 0,grammarContextCode:void 0}).stateStack:zo,u=[];const f=[];for(let d=0,h=a.length;d<h;d++){const[m,v]=a[d];if(m===""){u=[],f.push([]);continue}if(i>0&&m.length>=i){u=[],f.push([{content:m,offset:v,color:"",fontStyle:0}]);continue}let x,k,E;r.includeExplanation&&(x=t.tokenizeLine(m,c,l),k=x.tokens,E=0);const b=t.tokenizeLine2(m,c,l),R=b.tokens.length/2;for(let U=0;U<R;U++){const I=b.tokens[2*U],w=U+1<R?b.tokens[2*U+2]:m.length;if(I===w)continue;const W=b.tokens[2*U+1],Q=an(s[Jn.getForeground(W)],o),q=Jn.getFontStyle(W),re={content:m.substring(I,w),offset:v+I,color:Q,fontStyle:q};if(r.includeExplanation){const L=[];if(r.includeExplanation!=="scopeName")for(const oe of n.settings){let Ee;switch(typeof oe.scope){case"string":Ee=oe.scope.split(/,/).map(ge=>ge.trim());break;case"object":Ee=oe.scope;break;default:continue}L.push({settings:oe,selectors:Ee.map(ge=>ge.split(/ /))})}re.explanation=[];let pe=0;for(;I+pe<w;){const oe=k[E],Ee=m.substring(oe.startIndex,oe.endIndex);pe+=Ee.length,re.explanation.push({content:Ee,scopes:r.includeExplanation==="scopeName"?Zy(oe.scopes):ev(L,oe.scopes)}),E+=1}}u.push(re)}f.push(u),u=[],c=b.ruleStack}return{tokens:f,stateStack:c}}function Zy(e){return e.map(t=>({scopeName:t}))}function ev(e,t){const n=[];for(let s=0,r=t.length;s<r;s++){const o=t[s];n[s]={scopeName:o,themeMatches:nv(e,o,t.slice(0,s))}}return n}function oa(e,t){return e===t||t.substring(0,e.length)===e&&t[e.length]==="."}function tv(e,t,n){if(!oa(e[e.length-1],t))return!1;let s=e.length-2,r=n.length-1;for(;s>=0&&r>=0;)oa(e[s],n[r])&&(s-=1),r-=1;return s===-1}function nv(e,t,n){const s=[];for(const{selectors:r,settings:o}of e)for(const i of r)if(tv(i,t,n)){s.push(o);break}return s}function Su(e,t,n){const s=Object.entries(n.themes).filter(a=>a[1]).map(a=>({color:a[0],theme:a[1]})),r=s.map(a=>{const c=Ti(e,t,{...n,theme:a.theme}),u=$s(c),f=typeof a.theme=="string"?a.theme:a.theme.name;return{tokens:c,state:u,theme:f}}),o=sv(...r.map(a=>a.tokens)),i=o[0].map((a,c)=>a.map((u,f)=>{const d={content:u.content,variants:{},offset:u.offset};return"includeExplanation"in n&&n.includeExplanation&&(d.explanation=u.explanation),o.forEach((h,m)=>{const{content:v,explanation:x,offset:k,...E}=h[c][f];d.variants[s[m].color]=E}),d})),l=r[0].state?new Zn(Object.fromEntries(r.map(a=>{var c;return[a.theme,(c=a.state)==null?void 0:c.getInternalStack(a.theme)]})),r[0].state.lang):void 0;return l&&Vr(i,l),i}function sv(...e){const t=e.map(()=>[]),n=e.length;for(let s=0;s<e[0].length;s++){const r=e.map(a=>a[s]),o=t.map(()=>[]);t.forEach((a,c)=>a.push(o[c]));const i=r.map(()=>0),l=r.map(a=>a[0]);for(;l.every(a=>a);){const a=Math.min(...l.map(c=>c.content.length));for(let c=0;c<n;c++){const u=l[c];u.content.length===a?(o[c].push(u),i[c]+=1,l[c]=r[c][i[c]]):(o[c].push({...u,content:u.content.slice(0,a)}),l[c]={...u,content:u.content.slice(a),offset:u.offset+a})}}}return t}function Sr(e,t,n){let s,r,o,i,l,a;if("themes"in n){const{defaultColor:c="light",cssVariablePrefix:u="--shiki-",colorsRendering:f="css-vars"}=n,d=Object.entries(n.themes).filter(k=>k[1]).map(k=>({color:k[0],theme:k[1]})).sort((k,E)=>k.color===c?-1:E.color===c?1:0);if(d.length===0)throw new Le("`themes` option must not be empty");const h=Su(e,t,n);if(a=$s(h),c&&Oi!==c&&!d.find(k=>k.color===c))throw new Le(`\`themes\` option must contain the defaultColor key \`${c}\``);const m=d.map(k=>e.getTheme(k.theme)),v=d.map(k=>k.color);o=h.map(k=>k.map(E=>Ly(E,v,u,c,f))),a&&Vr(o,a);const x=d.map(k=>Cr(k.theme,n));r=ia(d,m,x,u,c,"fg",f),s=ia(d,m,x,u,c,"bg",f),i=`shiki-themes ${m.map(k=>k.name).join(" ")}`,l=c?void 0:[r,s].join(";")}else if("theme"in n){const c=Cr(n.theme,n);o=Ti(e,t,n);const u=e.getTheme(n.theme);s=an(u.bg,c),r=an(u.fg,c),i=u.name,a=$s(o)}else throw new Le("Invalid options, either `theme` or `themes` must be provided");return{tokens:o,fg:r,bg:s,themeName:i,rootStyle:l,grammarState:a}}function ia(e,t,n,s,r,o,i){return e.map((l,a)=>{const c=an(t[a][o],n[a])||"inherit",u=`${s+l.color}${o==="bg"?"-bg":""}:${c}`;if(a===0&&r){if(r===Oi&&e.length>1){const f=e.findIndex(v=>v.color==="light"),d=e.findIndex(v=>v.color==="dark");if(f===-1||d===-1)throw new Le('When using `defaultColor: "light-dark()"`, you must provide both `light` and `dark` themes');const h=an(t[f][o],n[f])||"inherit",m=an(t[d][o],n[d])||"inherit";return`light-dark(${h}, ${m});${u}`}return c}return i==="css-vars"?u:null}).filter(l=>!!l).join(";")}function Er(e,t,n,s={meta:{},options:n,codeToHast:(r,o)=>Er(e,r,o),codeToTokens:(r,o)=>Sr(e,r,o)}){var m,v;let r=t;for(const x of kr(n))r=((m=x.preprocess)==null?void 0:m.call(s,r,n))||r;let{tokens:o,fg:i,bg:l,themeName:a,rootStyle:c,grammarState:u}=Sr(e,r,n);const{mergeWhitespaces:f=!0,mergeSameStyleTokens:d=!1}=n;f===!0?o=ov(o):f==="never"&&(o=iv(o)),d&&(o=lv(o));const h={...s,get source(){return r}};for(const x of kr(n))o=((v=x.tokens)==null?void 0:v.call(h,o))||o;return rv(o,{...n,fg:i,bg:l,themeName:a,rootStyle:n.rootStyle===!1?!1:n.rootStyle??c},h,u)}function rv(e,t,n,s=$s(e)){var v,x,k,E;const r=kr(t),o=[],i={type:"root",children:[]},{structure:l="classic",tabindex:a="0"}=t,c={class:`shiki ${t.themeName||""}`};t.rootStyle!==!1&&(t.rootStyle!=null?c.style=t.rootStyle:c.style=`background-color:${t.bg};color:${t.fg}`),a!==!1&&a!=null&&(c.tabindex=a.toString());for(const[b,R]of Object.entries(t.meta||{}))b.startsWith("_")||(c[b]=R);let u={type:"element",tagName:"pre",properties:c,children:[],data:t.data},f={type:"element",tagName:"code",properties:{},children:o};const d=[],h={...n,structure:l,addClassToHast:Cu,get source(){return n.source},get tokens(){return e},get options(){return t},get root(){return i},get pre(){return u},get code(){return f},get lines(){return d}};if(e.forEach((b,R)=>{var w,W;R&&(l==="inline"?i.children.push({type:"element",tagName:"br",properties:{},children:[]}):l==="classic"&&o.push({type:"text",value:`
36
+ `}));let U={type:"element",tagName:"span",properties:{class:"line"},children:[]},I=0;for(const Q of b){let q={type:"element",tagName:"span",properties:{...Q.htmlAttrs},children:[{type:"text",value:Q.content}]};const re=Qo(Q.htmlStyle||xr(Q));re&&(q.properties.style=re);for(const L of r)q=((w=L==null?void 0:L.span)==null?void 0:w.call(h,q,R+1,I,U,Q))||q;l==="inline"?i.children.push(q):l==="classic"&&U.children.push(q),I+=Q.content.length}if(l==="classic"){for(const Q of r)U=((W=Q==null?void 0:Q.line)==null?void 0:W.call(h,U,R+1))||U;d.push(U),o.push(U)}else l==="inline"&&d.push(U)}),l==="classic"){for(const b of r)f=((v=b==null?void 0:b.code)==null?void 0:v.call(h,f))||f;u.children.push(f);for(const b of r)u=((x=b==null?void 0:b.pre)==null?void 0:x.call(h,u))||u;i.children.push(u)}else if(l==="inline"){const b=[];let R={type:"element",tagName:"span",properties:{class:"line"},children:[]};for(const w of i.children)w.type==="element"&&w.tagName==="br"?(b.push(R),R={type:"element",tagName:"span",properties:{class:"line"},children:[]}):(w.type==="element"||w.type==="text")&&R.children.push(w);b.push(R);let I={type:"element",tagName:"code",properties:{},children:b};for(const w of r)I=((k=w==null?void 0:w.code)==null?void 0:k.call(h,I))||I;i.children=[];for(let w=0;w<I.children.length;w++){w>0&&i.children.push({type:"element",tagName:"br",properties:{},children:[]});const W=I.children[w];W.type==="element"&&i.children.push(...W.children)}}let m=i;for(const b of r)m=((E=b==null?void 0:b.root)==null?void 0:E.call(h,m))||m;return s&&Vr(m,s),m}function ov(e){return e.map(t=>{const n=[];let s="",r;return t.forEach((o,i)=>{const a=!(o.fontStyle&&(o.fontStyle&He.Underline||o.fontStyle&He.Strikethrough));a&&o.content.match(/^\s+$/)&&t[i+1]?(r===void 0&&(r=o.offset),s+=o.content):s?(a?n.push({...o,offset:r,content:s+o.content}):n.push({content:s,offset:r},o),r=void 0,s=""):n.push(o)}),n})}function iv(e){return e.map(t=>t.flatMap(n=>{if(n.content.match(/^\s+$/))return n;const s=n.content.match(/^(\s*)(.*?)(\s*)$/);if(!s)return n;const[,r,o,i]=s;if(!r&&!i)return n;const l=[{...n,offset:n.offset+r.length,content:o}];return r&&l.unshift({content:r,offset:n.offset}),i&&l.push({content:i,offset:n.offset+r.length+o.length}),l}))}function lv(e){return e.map(t=>{const n=[];for(const s of t){if(n.length===0){n.push({...s});continue}const r=n[n.length-1],o=Qo(r.htmlStyle||xr(r)),i=Qo(s.htmlStyle||xr(s)),l=r.fontStyle&&(r.fontStyle&He.Underline||r.fontStyle&He.Strikethrough),a=s.fontStyle&&(s.fontStyle&He.Underline||s.fontStyle&He.Strikethrough);!l&&!a&&o===i?r.content+=s.content:n.push({...s})}return n})}const av=Ey;function cv(e,t,n){var o;const s={meta:{},options:n,codeToHast:(i,l)=>Er(e,i,l),codeToTokens:(i,l)=>Sr(e,i,l)};let r=av(Er(e,t,n,s));for(const i of kr(n))r=((o=i.postprocess)==null?void 0:o.call(s,r,n))||r;return r}const la={light:"#333333",dark:"#bbbbbb"},aa={light:"#fffffe",dark:"#1e1e1e"},ca="__shiki_resolved";function Li(e){var l,a,c,u,f;if(e!=null&&e[ca])return e;const t={...e};t.tokenColors&&!t.settings&&(t.settings=t.tokenColors,delete t.tokenColors),t.type||(t.type="dark"),t.colorReplacements={...t.colorReplacements},t.settings||(t.settings=[]);let{bg:n,fg:s}=t;if(!n||!s){const d=t.settings?t.settings.find(h=>!h.name&&!h.scope):void 0;(l=d==null?void 0:d.settings)!=null&&l.foreground&&(s=d.settings.foreground),(a=d==null?void 0:d.settings)!=null&&a.background&&(n=d.settings.background),!s&&((c=t==null?void 0:t.colors)!=null&&c["editor.foreground"])&&(s=t.colors["editor.foreground"]),!n&&((u=t==null?void 0:t.colors)!=null&&u["editor.background"])&&(n=t.colors["editor.background"]),s||(s=t.type==="light"?la.light:la.dark),n||(n=t.type==="light"?aa.light:aa.dark),t.fg=s,t.bg=n}t.settings[0]&&t.settings[0].settings&&!t.settings[0].scope||t.settings.unshift({settings:{foreground:t.fg,background:t.bg}});let r=0;const o=new Map;function i(d){var m;if(o.has(d))return o.get(d);r+=1;const h=`#${r.toString(16).padStart(8,"0").toLowerCase()}`;return(m=t.colorReplacements)!=null&&m[`#${h}`]?i(d):(o.set(d,h),h)}t.settings=t.settings.map(d=>{var x,k;const h=((x=d.settings)==null?void 0:x.foreground)&&!d.settings.foreground.startsWith("#"),m=((k=d.settings)==null?void 0:k.background)&&!d.settings.background.startsWith("#");if(!h&&!m)return d;const v={...d,settings:{...d.settings}};if(h){const E=i(d.settings.foreground);t.colorReplacements[E]=d.settings.foreground,v.settings.foreground=E}if(m){const E=i(d.settings.background);t.colorReplacements[E]=d.settings.background,v.settings.background=E}return v});for(const d of Object.keys(t.colors||{}))if((d==="editor.foreground"||d==="editor.background"||d.startsWith("terminal.ansi"))&&!((f=t.colors[d])!=null&&f.startsWith("#"))){const h=i(t.colors[d]);t.colorReplacements[h]=t.colors[d],t.colors[d]=h}return Object.defineProperty(t,ca,{enumerable:!1,writable:!1,value:!0}),t}async function Eu(e){return Array.from(new Set((await Promise.all(e.filter(t=>!Iy(t)).map(async t=>await wu(t).then(n=>Array.isArray(n)?n:[n])))).flat()))}async function Au(e){return(await Promise.all(e.map(async n=>Ny(n)?null:Li(await wu(n))))).filter(n=>!!n)}let uv=3;function fv(e,t=3){t>uv||console.trace(`[SHIKI DEPRECATE]: ${e}`)}class Gn extends Error{constructor(t){super(t),this.name="ShikiError"}}function Ru(e,t){if(!t)return e;if(t[e]){const n=new Set([e]);for(;t[e];){if(e=t[e],n.has(e))throw new Gn(`Circular alias \`${Array.from(n).join(" -> ")} -> ${e}\``);n.add(e)}}return e}class dv extends dm{constructor(n,s,r,o={}){super(n);$(this,"_resolvedThemes",new Map);$(this,"_resolvedGrammars",new Map);$(this,"_langMap",new Map);$(this,"_langGraph",new Map);$(this,"_textmateThemeCache",new WeakMap);$(this,"_loadedThemesCache",null);$(this,"_loadedLanguagesCache",null);this._resolver=n,this._themes=s,this._langs=r,this._alias=o,this._themes.map(i=>this.loadTheme(i)),this.loadLanguages(this._langs)}getTheme(n){return typeof n=="string"?this._resolvedThemes.get(n):this.loadTheme(n)}loadTheme(n){const s=Li(n);return s.name&&(this._resolvedThemes.set(s.name,s),this._loadedThemesCache=null),s}getLoadedThemes(){return this._loadedThemesCache||(this._loadedThemesCache=[...this._resolvedThemes.keys()]),this._loadedThemesCache}setTheme(n){let s=this._textmateThemeCache.get(n);s||(s=yr.createFromRawTheme(n),this._textmateThemeCache.set(n,s)),this._syncRegistry.setTheme(s)}getGrammar(n){return n=Ru(n,this._alias),this._resolvedGrammars.get(n)}loadLanguage(n){var i,l,a,c;if(this.getGrammar(n.name))return;const s=new Set([...this._langMap.values()].filter(u=>{var f;return(f=u.embeddedLangsLazy)==null?void 0:f.includes(n.name)}));this._resolver.addLanguage(n);const r={balancedBracketSelectors:n.balancedBracketSelectors||["*"],unbalancedBracketSelectors:n.unbalancedBracketSelectors||[]};this._syncRegistry._rawGrammars.set(n.scopeName,n);const o=this.loadGrammarWithConfiguration(n.scopeName,1,r);if(o.name=n.name,this._resolvedGrammars.set(n.name,o),n.aliases&&n.aliases.forEach(u=>{this._alias[u]=n.name}),this._loadedLanguagesCache=null,s.size)for(const u of s)this._resolvedGrammars.delete(u.name),this._loadedLanguagesCache=null,(l=(i=this._syncRegistry)==null?void 0:i._injectionGrammars)==null||l.delete(u.scopeName),(c=(a=this._syncRegistry)==null?void 0:a._grammars)==null||c.delete(u.scopeName),this.loadLanguage(this._langMap.get(u.name))}dispose(){super.dispose(),this._resolvedThemes.clear(),this._resolvedGrammars.clear(),this._langMap.clear(),this._langGraph.clear(),this._loadedThemesCache=null}loadLanguages(n){for(const o of n)this.resolveEmbeddedLanguages(o);const s=Array.from(this._langGraph.entries()),r=s.filter(([o,i])=>!i);if(r.length){const o=s.filter(([i,l])=>{if(!l)return!1;const a=l.embeddedLanguages||l.embeddedLangs;return a==null?void 0:a.some(c=>r.map(([u])=>u).includes(c))}).filter(i=>!r.includes(i));throw new Gn(`Missing languages ${r.map(([i])=>`\`${i}\``).join(", ")}, required by ${o.map(([i])=>`\`${i}\``).join(", ")}`)}for(const[o,i]of s)this._resolver.addLanguage(i);for(const[o,i]of s)this.loadLanguage(i)}getLoadedLanguages(){return this._loadedLanguagesCache||(this._loadedLanguagesCache=[...new Set([...this._resolvedGrammars.keys(),...Object.keys(this._alias)])]),this._loadedLanguagesCache}resolveEmbeddedLanguages(n){this._langMap.set(n.name,n),this._langGraph.set(n.name,n);const s=n.embeddedLanguages??n.embeddedLangs;if(s)for(const r of s)this._langGraph.set(r,this._langMap.get(r))}}class hv{constructor(t,n){$(this,"_langs",new Map);$(this,"_scopeToLang",new Map);$(this,"_injections",new Map);$(this,"_onigLib");this._onigLib={createOnigScanner:s=>t.createScanner(s),createOnigString:s=>t.createString(s)},n.forEach(s=>this.addLanguage(s))}get onigLib(){return this._onigLib}getLangRegistration(t){return this._langs.get(t)}loadGrammar(t){return this._scopeToLang.get(t)}addLanguage(t){this._langs.set(t.name,t),t.aliases&&t.aliases.forEach(n=>{this._langs.set(n,t)}),this._scopeToLang.set(t.scopeName,t),t.injectTo&&t.injectTo.forEach(n=>{this._injections.get(n)||this._injections.set(n,[]),this._injections.get(n).push(t.scopeName)})}getInjections(t){const n=t.split(".");let s=[];for(let r=1;r<=n.length;r++){const o=n.slice(0,r).join(".");s=[...s,...this._injections.get(o)||[]]}return s}}let is=0;function pv(e){is+=1,e.warnings!==!1&&is>=10&&is%10===0&&console.warn(`[Shiki] ${is} instances have been created. Shiki is supposed to be used as a singleton, consider refactoring your code to cache your highlighter instance; Or call \`highlighter.dispose()\` to release unused instances.`);let t=!1;if(!e.engine)throw new Gn("`engine` option is required for synchronous mode");const n=(e.langs||[]).flat(1),s=(e.themes||[]).flat(1).map(Li),r=new hv(e.engine,n),o=new dv(r,s,n,e.langAlias);let i;function l(b){return Ru(b,e.langAlias)}function a(b){k();const R=o.getGrammar(typeof b=="string"?b:b.name);if(!R)throw new Gn(`Language \`${b}\` not found, you may need to load it first`);return R}function c(b){if(b==="none")return{bg:"",fg:"",name:"none",settings:[],type:"dark"};k();const R=o.getTheme(b);if(!R)throw new Gn(`Theme \`${b}\` not found, you may need to load it first`);return R}function u(b){k();const R=c(b);i!==b&&(o.setTheme(R),i=b);const U=o.getColorMap();return{theme:R,colorMap:U}}function f(){return k(),o.getLoadedThemes()}function d(){return k(),o.getLoadedLanguages()}function h(...b){k(),o.loadLanguages(b.flat(1))}async function m(...b){return h(await Eu(b))}function v(...b){k();for(const R of b.flat(1))o.loadTheme(R)}async function x(...b){return k(),v(await Au(b))}function k(){if(t)throw new Gn("Shiki instance has been disposed")}function E(){t||(t=!0,o.dispose(),is-=1)}return{setTheme:u,getTheme:c,getLanguage:a,getLoadedThemes:f,getLoadedLanguages:d,resolveLangAlias:l,loadLanguage:m,loadLanguageSync:h,loadTheme:x,loadThemeSync:v,dispose:E,[Symbol.dispose]:E}}async function gv(e){e.engine||fv("`engine` option is required. Use `createOnigurumaEngine` or `createJavaScriptRegexEngine` to create an engine.");const[t,n,s]=await Promise.all([Au(e.themes||[]),Eu(e.langs||[]),e.engine]);return pv({...e,themes:t,langs:n,engine:s})}async function mv(e){const t=await gv(e);return{getLastGrammarState:(...n)=>Yy(t,...n),codeToTokensBase:(n,s)=>Ti(t,n,s),codeToTokensWithThemes:(n,s)=>Su(t,n,s),codeToTokens:(n,s)=>Sr(t,n,s),codeToHast:(n,s)=>Er(t,n,s),codeToHtml:(n,s)=>cv(t,n,s),getBundledLanguages:()=>({}),getBundledThemes:()=>({}),...t,getInternalContext:()=>t}}function es(e){if([...e].length!==1)throw new Error(`Expected "${e}" to be a single code point`);return e.codePointAt(0)}function yv(e,t,n){return e.has(t)||e.set(t,n),e.get(t)}const Di=new Set(["alnum","alpha","ascii","blank","cntrl","digit","graph","lower","print","punct","space","upper","word","xdigit"]),De=String.raw;function ts(e,t){if(e==null)throw new Error(t??"Value expected");return e}const $u=De`\[\^?`,Iu=`c.? | C(?:-.?)?|${De`[pP]\{(?:\^?[-\x20_]*[A-Za-z][-\x20\w]*\})?`}|${De`x[89A-Fa-f]\p{AHex}(?:\\x[89A-Fa-f]\p{AHex})*`}|${De`u(?:\p{AHex}{4})? | x\{[^\}]*\}? | x\p{AHex}{0,2}`}|${De`o\{[^\}]*\}?`}|${De`\d{1,3}`}`,Gi=/[?*+][?+]?|\{(?:\d+(?:,\d*)?|,\d+)\}\??/,Vs=new RegExp(De`
37
+ \\ (?:
38
+ ${Iu}
39
+ | [gk]<[^>]*>?
40
+ | [gk]'[^']*'?
41
+ | .
42
+ )
43
+ | \( (?:
44
+ \? (?:
45
+ [:=!>({]
46
+ | <[=!]
47
+ | <[^>]*>
48
+ | '[^']*'
49
+ | ~\|?
50
+ | #(?:[^)\\]|\\.?)*
51
+ | [^:)]*[:)]
52
+ )?
53
+ | \*[^\)]*\)?
54
+ )?
55
+ | (?:${Gi.source})+
56
+ | ${$u}
57
+ | .
58
+ `.replace(/\s+/g,""),"gsu"),_o=new RegExp(De`
59
+ \\ (?:
60
+ ${Iu}
61
+ | .
62
+ )
63
+ | \[:(?:\^?\p{Alpha}+|\^):\]
64
+ | ${$u}
65
+ | &&
66
+ | .
67
+ `.replace(/\s+/g,""),"gsu");function vv(e,t={}){const n={flags:"",...t,rules:{captureGroup:!1,singleline:!1,...t.rules}};if(typeof e!="string")throw new Error("String expected as pattern");const s=Dv(n.flags),r=[s.extended],o={captureGroup:n.rules.captureGroup,getCurrentModX(){return r.at(-1)},numOpenGroups:0,popModX(){r.pop()},pushModX(f){r.push(f)},replaceCurrentModX(f){r[r.length-1]=f},singleline:n.rules.singleline};let i=[],l;for(Vs.lastIndex=0;l=Vs.exec(e);){const f=_v(o,e,l[0],Vs.lastIndex);f.tokens?i.push(...f.tokens):f.token&&i.push(f.token),f.lastIndex!==void 0&&(Vs.lastIndex=f.lastIndex)}const a=[];let c=0;i.filter(f=>f.type==="GroupOpen").forEach(f=>{f.kind==="capturing"?f.number=++c:f.raw==="("&&a.push(f)}),c||a.forEach((f,d)=>{f.kind="capturing",f.number=d+1});const u=c||a.length;return{tokens:i.map(f=>f.type==="EscapedNumber"?jv(f,u):f).flat(),flags:s}}function _v(e,t,n,s){const[r,o]=n;if(n==="["||n==="[^"){const i=bv(t,n,s);return{tokens:i.tokens,lastIndex:i.lastIndex}}if(r==="\\"){if("AbBGyYzZ".includes(o))return{token:ua(n,n)};if(/^\\g[<']/.test(n)){if(!/^\\g(?:<[^>]+>|'[^']+')$/.test(n))throw new Error(`Invalid group name "${n}"`);return{token:Iv(n)}}if(/^\\k[<']/.test(n)){if(!/^\\k(?:<[^>]+>|'[^']+')$/.test(n))throw new Error(`Invalid group name "${n}"`);return{token:Pu(n)}}if(o==="K")return{token:Ou("keep",n)};if(o==="N"||o==="R")return{token:Cn("newline",n,{negate:o==="N"})};if(o==="O")return{token:Cn("any",n)};if(o==="X")return{token:Cn("text_segment",n)};const i=Nu(n,{inCharClass:!1});return Array.isArray(i)?{tokens:i}:{token:i}}if(r==="("){if(o==="*")return{token:Tv(n)};if(n==="(?{")throw new Error(`Unsupported callout "${n}"`);if(n.startsWith("(?#")){if(t[s]!==")")throw new Error('Unclosed comment group "(?#"');return{lastIndex:s+1}}if(/^\(\?[-imx]+[:)]$/.test(n))return{token:Ov(n,e)};if(e.pushModX(e.getCurrentModX()),e.numOpenGroups++,n==="("&&!e.captureGroup||n==="(?:")return{token:Ln("group",n)};if(n==="(?>")return{token:Ln("atomic",n)};if(n==="(?="||n==="(?!"||n==="(?<="||n==="(?<!")return{token:Ln(n[2]==="<"?"lookbehind":"lookahead",n,{negate:n.endsWith("!")})};if(n==="("&&e.captureGroup||n.startsWith("(?<")&&n.endsWith(">")||n.startsWith("(?'")&&n.endsWith("'"))return{token:Ln("capturing",n,{...n!=="("&&{name:n.slice(3,-1)}})};if(n.startsWith("(?~")){if(n==="(?~|")throw new Error(`Unsupported absence function kind "${n}"`);return{token:Ln("absence_repeater",n)}}throw n==="(?("?new Error(`Unsupported conditional "${n}"`):new Error(`Invalid or unsupported group option "${n}"`)}if(n===")"){if(e.popModX(),e.numOpenGroups--,e.numOpenGroups<0)throw new Error('Unmatched ")"');return{token:Av(n)}}if(e.getCurrentModX()){if(n==="#"){const i=t.indexOf(`
68
+ `,s);return{lastIndex:i===-1?t.length:i}}if(/^\s$/.test(n)){const i=/\s+/y;return i.lastIndex=s,{lastIndex:i.exec(t)?i.lastIndex:s}}}if(n===".")return{token:Cn("dot",n)};if(n==="^"||n==="$"){const i=e.singleline?{"^":De`\A`,$:De`\Z`}[n]:n;return{token:ua(i,n)}}return n==="|"?{token:Cv(n)}:Gi.test(n)?{tokens:Fv(n)}:{token:Xt(es(n),n)}}function bv(e,t,n){const s=[fa(t[1]==="^",t)];let r=1,o;for(_o.lastIndex=n;o=_o.exec(e);){const i=o[0];if(i[0]==="["&&i[1]!==":")r++,s.push(fa(i[1]==="^",i));else if(i==="]"){if(s.at(-1).type==="CharacterClassOpen")s.push(Xt(93,i));else if(r--,s.push(xv(i)),!r)break}else{const l=wv(i);Array.isArray(l)?s.push(...l):s.push(l)}}return{tokens:s,lastIndex:_o.lastIndex||e.length}}function wv(e){if(e[0]==="\\")return Nu(e,{inCharClass:!0});if(e[0]==="["){const t=/\[:(?<negate>\^?)(?<name>[a-z]+):\]/.exec(e);if(!t||!Di.has(t.groups.name))throw new Error(`Invalid POSIX class "${e}"`);return Cn("posix",e,{value:t.groups.name,negate:!!t.groups.negate})}return e==="-"?kv(e):e==="&&"?Sv(e):Xt(es(e),e)}function Nu(e,{inCharClass:t}){const n=e[1];if(n==="c"||n==="C")return Pv(e);if("dDhHsSwW".includes(n))return Mv(e);if(e.startsWith(De`\o{`))throw new Error(`Incomplete, invalid, or unsupported octal code point "${e}"`);if(/^\\[pP]\{/.test(e)){if(e.length===3)throw new Error(`Incomplete or invalid Unicode property "${e}"`);return Lv(e)}if(new RegExp("^\\\\x[89A-Fa-f]\\p{AHex}","u").test(e))try{const s=e.split(/\\x/).slice(1).map(i=>parseInt(i,16)),r=new TextDecoder("utf-8",{ignoreBOM:!0,fatal:!0}).decode(new Uint8Array(s)),o=new TextEncoder;return[...r].map(i=>{const l=[...o.encode(i)].map(a=>`\\x${a.toString(16)}`).join("");return Xt(es(i),l)})}catch{throw new Error(`Multibyte code "${e}" incomplete or invalid in Oniguruma`)}if(n==="u"||n==="x")return Xt(Gv(e),e);if(da.has(n))return Xt(da.get(n),e);if(/\d/.test(n))return Ev(t,e);if(e==="\\")throw new Error(De`Incomplete escape "\"`);if(n==="M")throw new Error(`Unsupported meta "${e}"`);if([...e].length===2)return Xt(e.codePointAt(1),e);throw new Error(`Unexpected escape "${e}"`)}function Cv(e){return{type:"Alternator",raw:e}}function ua(e,t){return{type:"Assertion",kind:e,raw:t}}function Pu(e){return{type:"Backreference",raw:e}}function Xt(e,t){return{type:"Character",value:e,raw:t}}function xv(e){return{type:"CharacterClassClose",raw:e}}function kv(e){return{type:"CharacterClassHyphen",raw:e}}function Sv(e){return{type:"CharacterClassIntersector",raw:e}}function fa(e,t){return{type:"CharacterClassOpen",negate:e,raw:t}}function Cn(e,t,n={}){return{type:"CharacterSet",kind:e,...n,raw:t}}function Ou(e,t,n={}){return e==="keep"?{type:"Directive",kind:e,raw:t}:{type:"Directive",kind:e,flags:ts(n.flags),raw:t}}function Ev(e,t){return{type:"EscapedNumber",inCharClass:e,raw:t}}function Av(e){return{type:"GroupClose",raw:e}}function Ln(e,t,n={}){return{type:"GroupOpen",kind:e,...n,raw:t}}function Rv(e,t,n,s){return{type:"NamedCallout",kind:e,tag:t,arguments:n,raw:s}}function $v(e,t,n,s){return{type:"Quantifier",kind:e,min:t,max:n,raw:s}}function Iv(e){return{type:"Subroutine",raw:e}}const Nv=new Set(["COUNT","CMP","ERROR","FAIL","MAX","MISMATCH","SKIP","TOTAL_COUNT"]),da=new Map([["a",7],["b",8],["e",27],["f",12],["n",10],["r",13],["t",9],["v",11]]);function Pv(e){const t=e[1]==="c"?e[2]:e[3];if(!t||!/[A-Za-z]/.test(t))throw new Error(`Unsupported control character "${e}"`);return Xt(es(t.toUpperCase())-64,e)}function Ov(e,t){let{on:n,off:s}=/^\(\?(?<on>[imx]*)(?:-(?<off>[-imx]*))?/.exec(e).groups;s??(s="");const r=(t.getCurrentModX()||n.includes("x"))&&!s.includes("x"),o=pa(n),i=pa(s),l={};if(o&&(l.enable=o),i&&(l.disable=i),e.endsWith(")"))return t.replaceCurrentModX(r),Ou("flags",e,{flags:l});if(e.endsWith(":"))return t.pushModX(r),t.numOpenGroups++,Ln("group",e,{...(o||i)&&{flags:l}});throw new Error(`Unexpected flag modifier "${e}"`)}function Tv(e){const t=/\(\*(?<name>[A-Za-z_]\w*)?(?:\[(?<tag>(?:[A-Za-z_]\w*)?)\])?(?:\{(?<args>[^}]*)\})?\)/.exec(e);if(!t)throw new Error(`Incomplete or invalid named callout "${e}"`);const{name:n,tag:s,args:r}=t.groups;if(!n)throw new Error(`Invalid named callout "${e}"`);if(s==="")throw new Error(`Named callout tag with empty value not allowed "${e}"`);const o=r?r.split(",").filter(u=>u!=="").map(u=>/^[+-]?\d+$/.test(u)?+u:u):[],[i,l,a]=o,c=Nv.has(n)?n.toLowerCase():"custom";switch(c){case"fail":case"mismatch":case"skip":if(o.length>0)throw new Error(`Named callout arguments not allowed "${o}"`);break;case"error":if(o.length>1)throw new Error(`Named callout allows only one argument "${o}"`);if(typeof i=="string")throw new Error(`Named callout argument must be a number "${i}"`);break;case"max":if(!o.length||o.length>2)throw new Error(`Named callout must have one or two arguments "${o}"`);if(typeof i=="string"&&!/^[A-Za-z_]\w*$/.test(i))throw new Error(`Named callout argument one must be a tag or number "${i}"`);if(o.length===2&&(typeof l=="number"||!/^[<>X]$/.test(l)))throw new Error(`Named callout optional argument two must be '<', '>', or 'X' "${l}"`);break;case"count":case"total_count":if(o.length>1)throw new Error(`Named callout allows only one argument "${o}"`);if(o.length===1&&(typeof i=="number"||!/^[<>X]$/.test(i)))throw new Error(`Named callout optional argument must be '<', '>', or 'X' "${i}"`);break;case"cmp":if(o.length!==3)throw new Error(`Named callout must have three arguments "${o}"`);if(typeof i=="string"&&!/^[A-Za-z_]\w*$/.test(i))throw new Error(`Named callout argument one must be a tag or number "${i}"`);if(typeof l=="number"||!/^(?:[<>!=]=|[<>])$/.test(l))throw new Error(`Named callout argument two must be '==', '!=', '>', '<', '>=', or '<=' "${l}"`);if(typeof a=="string"&&!/^[A-Za-z_]\w*$/.test(a))throw new Error(`Named callout argument three must be a tag or number "${a}"`);break;case"custom":throw new Error(`Undefined callout name "${n}"`);default:throw new Error(`Unexpected named callout kind "${c}"`)}return Rv(c,s??null,(r==null?void 0:r.split(","))??null,e)}function ha(e){let t=null,n,s;if(e[0]==="{"){const{minStr:r,maxStr:o}=/^\{(?<minStr>\d*)(?:,(?<maxStr>\d*))?/.exec(e).groups,i=1e5;if(+r>i||o&&+o>i)throw new Error("Quantifier value unsupported in Oniguruma");if(n=+r,s=o===void 0?+r:o===""?1/0:+o,n>s&&(t="possessive",[n,s]=[s,n]),e.endsWith("?")){if(t==="possessive")throw new Error('Unsupported possessive interval quantifier chain with "?"');t="lazy"}else t||(t="greedy")}else n=e[0]==="+"?1:0,s=e[0]==="?"?1:1/0,t=e[1]==="+"?"possessive":e[1]==="?"?"lazy":"greedy";return $v(t,n,s,e)}function Mv(e){const t=e[1].toLowerCase();return Cn({d:"digit",h:"hex",s:"space",w:"word"}[t],e,{negate:e[1]!==t})}function Lv(e){const{p:t,neg:n,value:s}=/^\\(?<p>[pP])\{(?<neg>\^?)(?<value>[^}]+)/.exec(e).groups;return Cn("property",e,{value:s,negate:t==="P"&&!n||t==="p"&&!!n})}function pa(e){const t={};return e.includes("i")&&(t.ignoreCase=!0),e.includes("m")&&(t.dotAll=!0),e.includes("x")&&(t.extended=!0),Object.keys(t).length?t:null}function Dv(e){const t={ignoreCase:!1,dotAll:!1,extended:!1,digitIsAscii:!1,posixIsAscii:!1,spaceIsAscii:!1,wordIsAscii:!1,textSegmentMode:null};for(let n=0;n<e.length;n++){const s=e[n];if(!"imxDPSWy".includes(s))throw new Error(`Invalid flag "${s}"`);if(s==="y"){if(!/^y{[gw]}/.test(e.slice(n)))throw new Error('Invalid or unspecified flag "y" mode');t.textSegmentMode=e[n+2]==="g"?"grapheme":"word",n+=3;continue}t[{i:"ignoreCase",m:"dotAll",x:"extended",D:"digitIsAscii",P:"posixIsAscii",S:"spaceIsAscii",W:"wordIsAscii"}[s]]=!0}return t}function Gv(e){if(new RegExp("^(?:\\\\u(?!\\p{AHex}{4})|\\\\x(?!\\p{AHex}{1,2}|\\{\\p{AHex}{1,8}\\}))","u").test(e))throw new Error(`Incomplete or invalid escape "${e}"`);const t=e[2]==="{"?new RegExp("^\\\\x\\{\\s*(?<hex>\\p{AHex}+)","u").exec(e).groups.hex:e.slice(2);return parseInt(t,16)}function jv(e,t){const{raw:n,inCharClass:s}=e,r=n.slice(1);if(!s&&(r!=="0"&&r.length===1||r[0]!=="0"&&+r<=t))return[Pu(n)];const o=[],i=r.match(/^[0-7]+|\d/g);for(let l=0;l<i.length;l++){const a=i[l];let c;if(l===0&&a!=="8"&&a!=="9"){if(c=parseInt(a,8),c>127)throw new Error(De`Octal encoded byte above 177 unsupported "${n}"`)}else c=es(a);o.push(Xt(c,(l===0?"\\":"")+a))}return o}function Fv(e){const t=[],n=new RegExp(Gi,"gy");let s;for(;s=n.exec(e);){const r=s[0];if(r[0]==="{"){const o=/^\{(?<min>\d+),(?<max>\d+)\}\??$/.exec(r);if(o){const{min:i,max:l}=o.groups;if(+i>+l&&r.endsWith("?")){n.lastIndex--,t.push(ha(r.slice(0,-1)));continue}}}t.push(ha(r))}return t}function Tu(e,t){if(!Array.isArray(e.body))throw new Error("Expected node with body array");if(e.body.length!==1)return!1;const n=e.body[0];return!t||Object.keys(t).every(s=>t[s]===n[s])}function Bv(e){return Uv.has(e.type)}const Uv=new Set(["AbsenceFunction","Backreference","CapturingGroup","Character","CharacterClass","CharacterSet","Group","Quantifier","Subroutine"]);function Mu(e,t={}){const n={flags:"",normalizeUnknownPropertyNames:!1,skipBackrefValidation:!1,skipLookbehindValidation:!1,skipPropertyNameValidation:!1,unicodePropertyMap:null,...t,rules:{captureGroup:!1,singleline:!1,...t.rules}},s=vv(e,{flags:n.flags,rules:{captureGroup:n.rules.captureGroup,singleline:n.rules.singleline}}),r=(d,h)=>{const m=s.tokens[o.nextIndex];switch(o.parent=d,o.nextIndex++,m.type){case"Alternator":return Rn();case"Assertion":return Hv(m);case"Backreference":return Wv(m,o);case"Character":return qr(m.value,{useLastValid:!!h.isCheckingRangeEnd});case"CharacterClassHyphen":return Vv(m,o,h);case"CharacterClassOpen":return qv(m,o,h);case"CharacterSet":return zv(m,o);case"Directive":return Zv(m.kind,{flags:m.flags});case"GroupOpen":return Kv(m,o,h);case"NamedCallout":return t_(m.kind,m.tag,m.arguments);case"Quantifier":return Xv(m,o);case"Subroutine":return Jv(m,o);default:throw new Error(`Unexpected token type "${m.type}"`)}},o={capturingGroups:[],hasNumberedRef:!1,namedGroupsByName:new Map,nextIndex:0,normalizeUnknownPropertyNames:n.normalizeUnknownPropertyNames,parent:null,skipBackrefValidation:n.skipBackrefValidation,skipLookbehindValidation:n.skipLookbehindValidation,skipPropertyNameValidation:n.skipPropertyNameValidation,subroutines:[],tokens:s.tokens,unicodePropertyMap:n.unicodePropertyMap,walk:r},i=s_(e_(s.flags));let l=i.body[0];for(;o.nextIndex<s.tokens.length;){const d=r(l,{});d.type==="Alternative"?(i.body.push(d),l=d):l.body.push(d)}const{capturingGroups:a,hasNumberedRef:c,namedGroupsByName:u,subroutines:f}=o;if(c&&u.size&&!n.rules.captureGroup)throw new Error("Numbered backref/subroutine not allowed when using named capture");for(const{ref:d}of f)if(typeof d=="number"){if(d>a.length)throw new Error("Subroutine uses a group number that's not defined");d&&(a[d-1].isSubroutined=!0)}else if(u.has(d)){if(u.get(d).length>1)throw new Error(De`Subroutine uses a duplicate group name "\g<${d}>"`);u.get(d)[0].isSubroutined=!0}else throw new Error(De`Subroutine uses a group name that's not defined "\g<${d}>"`);return i}function Hv({kind:e}){return Zo(ts({"^":"line_start",$:"line_end","\\A":"string_start","\\b":"word_boundary","\\B":"word_boundary","\\G":"search_start","\\y":"text_segment_boundary","\\Y":"text_segment_boundary","\\z":"string_end","\\Z":"string_end_newline"}[e],`Unexpected assertion kind "${e}"`),{negate:e===De`\B`||e===De`\Y`})}function Wv({raw:e},t){const n=/^\\k[<']/.test(e),s=n?e.slice(3,-1):e.slice(1),r=(o,i=!1)=>{const l=t.capturingGroups.length;let a=!1;if(o>l)if(t.skipBackrefValidation)a=!0;else throw new Error(`Not enough capturing groups defined to the left "${e}"`);return t.hasNumberedRef=!0,ei(i?l+1-o:o,{orphan:a})};if(n){const o=/^(?<sign>-?)0*(?<num>[1-9]\d*)$/.exec(s);if(o)return r(+o.groups.num,!!o.groups.sign);if(/[-+]/.test(s))throw new Error(`Invalid backref name "${e}"`);if(!t.namedGroupsByName.has(s))throw new Error(`Group name not defined to the left "${e}"`);return ei(s)}return r(+s)}function Vv(e,t,n){const{tokens:s,walk:r}=t,o=t.parent,i=o.body.at(-1),l=s[t.nextIndex];if(!n.isCheckingRangeEnd&&i&&i.type!=="CharacterClass"&&i.type!=="CharacterClassRange"&&l&&l.type!=="CharacterClassOpen"&&l.type!=="CharacterClassClose"&&l.type!=="CharacterClassIntersector"){const a=r(o,{...n,isCheckingRangeEnd:!0});if(i.type==="Character"&&a.type==="Character")return o.body.pop(),Qv(i,a);throw new Error("Invalid character class range")}return qr(es("-"))}function qv({negate:e},t,n){const{tokens:s,walk:r}=t,o=s[t.nextIndex],i=[nr()];let l=ya(o);for(;l.type!=="CharacterClassClose";){if(l.type==="CharacterClassIntersector")i.push(nr()),t.nextIndex++;else{const c=i.at(-1);c.body.push(r(c,n))}l=ya(s[t.nextIndex],o)}const a=nr({negate:e});return i.length===1?a.body=i[0].body:(a.kind="intersection",a.body=i.map(c=>c.body.length===1?c.body[0]:c)),t.nextIndex++,a}function zv({kind:e,negate:t,value:n},s){const{normalizeUnknownPropertyNames:r,skipPropertyNameValidation:o,unicodePropertyMap:i}=s;if(e==="property"){const l=zr(n);if(Di.has(l)&&!(i!=null&&i.has(l)))e="posix",n=l;else return Dn(n,{negate:t,normalizeUnknownPropertyNames:r,skipPropertyNameValidation:o,unicodePropertyMap:i})}return e==="posix"?n_(n,{negate:t}):ti(e,{negate:t})}function Kv(e,t,n){const{tokens:s,capturingGroups:r,namedGroupsByName:o,skipLookbehindValidation:i,walk:l}=t,a=r_(e),c=a.type==="AbsenceFunction",u=ma(a),f=u&&a.negate;if(a.type==="CapturingGroup"&&(r.push(a),a.name&&yv(o,a.name,[]).push(a)),c&&n.isInAbsenceFunction)throw new Error("Nested absence function not supported by Oniguruma");let d=va(s[t.nextIndex]);for(;d.type!=="GroupClose";){if(d.type==="Alternator")a.body.push(Rn()),t.nextIndex++;else{const h=a.body.at(-1),m=l(h,{...n,isInAbsenceFunction:n.isInAbsenceFunction||c,isInLookbehind:n.isInLookbehind||u,isInNegLookbehind:n.isInNegLookbehind||f});if(h.body.push(m),(u||n.isInLookbehind)&&!i){const v="Lookbehind includes a pattern not allowed by Oniguruma";if(f||n.isInNegLookbehind){if(ga(m)||m.type==="CapturingGroup")throw new Error(v)}else if(ga(m)||ma(m)&&m.negate)throw new Error(v)}}d=va(s[t.nextIndex])}return t.nextIndex++,a}function Xv({kind:e,min:t,max:n},s){const r=s.parent,o=r.body.at(-1);if(!o||!Bv(o))throw new Error("Quantifier requires a repeatable token");const i=Du(e,t,n,o);return r.body.pop(),i}function Jv({raw:e},t){const{capturingGroups:n,subroutines:s}=t;let r=e.slice(3,-1);const o=/^(?<sign>[-+]?)0*(?<num>[1-9]\d*)$/.exec(r);if(o){const l=+o.groups.num,a=n.length;if(t.hasNumberedRef=!0,r={"":l,"+":a+l,"-":a+1-l}[o.groups.sign],r<1)throw new Error("Invalid subroutine number")}else r==="0"&&(r=0);const i=Gu(r);return s.push(i),i}function Yv(e,t){return{type:"AbsenceFunction",kind:e,body:Gs(t==null?void 0:t.body)}}function Rn(e){return{type:"Alternative",body:ju(e==null?void 0:e.body)}}function Zo(e,t){const n={type:"Assertion",kind:e};return(e==="word_boundary"||e==="text_segment_boundary")&&(n.negate=!!(t!=null&&t.negate)),n}function ei(e,t){const n=!!(t!=null&&t.orphan);return{type:"Backreference",ref:e,...n&&{orphan:n}}}function Lu(e,t){const n={name:void 0,isSubroutined:!1,...t};if(n.name!==void 0&&!o_(n.name))throw new Error(`Group name "${n.name}" invalid in Oniguruma`);return{type:"CapturingGroup",number:e,...n.name&&{name:n.name},...n.isSubroutined&&{isSubroutined:n.isSubroutined},body:Gs(t==null?void 0:t.body)}}function qr(e,t){const n={useLastValid:!1,...t};if(e>1114111){const s=e.toString(16);if(n.useLastValid)e=1114111;else throw e>1310719?new Error(`Invalid code point out of range "\\x{${s}}"`):new Error(`Invalid code point out of range in JS "\\x{${s}}"`)}return{type:"Character",value:e}}function nr(e){const t={kind:"union",negate:!1,...e};return{type:"CharacterClass",kind:t.kind,negate:t.negate,body:ju(e==null?void 0:e.body)}}function Qv(e,t){if(t.value<e.value)throw new Error("Character class range out of order");return{type:"CharacterClassRange",min:e,max:t}}function ti(e,t){const n=!!(t!=null&&t.negate),s={type:"CharacterSet",kind:e};return(e==="digit"||e==="hex"||e==="newline"||e==="space"||e==="word")&&(s.negate=n),(e==="text_segment"||e==="newline"&&!n)&&(s.variableLength=!0),s}function Zv(e,t={}){if(e==="keep")return{type:"Directive",kind:e};if(e==="flags")return{type:"Directive",kind:e,flags:ts(t.flags)};throw new Error(`Unexpected directive kind "${e}"`)}function e_(e){return{type:"Flags",...e}}function mt(e){const t=e==null?void 0:e.atomic,n=e==null?void 0:e.flags;if(t&&n)throw new Error("Atomic group cannot have flags");return{type:"Group",...t&&{atomic:t},...n&&{flags:n},body:Gs(e==null?void 0:e.body)}}function _n(e){const t={behind:!1,negate:!1,...e};return{type:"LookaroundAssertion",kind:t.behind?"lookbehind":"lookahead",negate:t.negate,body:Gs(e==null?void 0:e.body)}}function t_(e,t,n){return{type:"NamedCallout",kind:e,tag:t,arguments:n}}function n_(e,t){const n=!!(t!=null&&t.negate);if(!Di.has(e))throw new Error(`Invalid POSIX class "${e}"`);return{type:"CharacterSet",kind:"posix",value:e,negate:n}}function Du(e,t,n,s){if(t>n)throw new Error("Invalid reversed quantifier range");return{type:"Quantifier",kind:e,min:t,max:n,body:s}}function s_(e,t){return{type:"Regex",body:Gs(t==null?void 0:t.body),flags:e}}function Gu(e){return{type:"Subroutine",ref:e}}function Dn(e,t){var r;const n={negate:!1,normalizeUnknownPropertyNames:!1,skipPropertyNameValidation:!1,unicodePropertyMap:null,...t};let s=(r=n.unicodePropertyMap)==null?void 0:r.get(zr(e));if(!s){if(n.normalizeUnknownPropertyNames)s=i_(e);else if(n.unicodePropertyMap&&!n.skipPropertyNameValidation)throw new Error(De`Invalid Unicode property "\p{${e}}"`)}return{type:"CharacterSet",kind:"property",value:s??e,negate:n.negate}}function r_({flags:e,kind:t,name:n,negate:s,number:r}){switch(t){case"absence_repeater":return Yv("repeater");case"atomic":return mt({atomic:!0});case"capturing":return Lu(r,{name:n});case"group":return mt({flags:e});case"lookahead":case"lookbehind":return _n({behind:t==="lookbehind",negate:s});default:throw new Error(`Unexpected group kind "${t}"`)}}function Gs(e){if(e===void 0)e=[Rn()];else if(!Array.isArray(e)||!e.length||!e.every(t=>t.type==="Alternative"))throw new Error("Invalid body; expected array of one or more Alternative nodes");return e}function ju(e){if(e===void 0)e=[];else if(!Array.isArray(e)||!e.every(t=>!!t.type))throw new Error("Invalid body; expected array of nodes");return e}function ga(e){return e.type==="LookaroundAssertion"&&e.kind==="lookahead"}function ma(e){return e.type==="LookaroundAssertion"&&e.kind==="lookbehind"}function o_(e){return/^[\p{Alpha}\p{Pc}][^)]*$/u.test(e)}function i_(e){return e.trim().replace(/[- _]+/g,"_").replace(/[A-Z][a-z]+(?=[A-Z])/g,"$&_").replace(/[A-Za-z]+/g,t=>t[0].toUpperCase()+t.slice(1).toLowerCase())}function zr(e){return e.replace(/[- _]+/g,"").toLowerCase()}function ya(e,t){return ts(e,`${(t==null?void 0:t.type)==="Character"&&t.value===93?"Empty":"Unclosed"} character class`)}function va(e){return ts(e,"Unclosed group")}function _s(e,t,n=null){function s(o,i){for(let l=0;l<o.length;l++){const a=r(o[l],i,l,o);l=Math.max(-1,l+a)}}function r(o,i=null,l=null,a=null){var k,E;let c=0,u=!1;const f={node:o,parent:i,key:l,container:a,root:e,remove(){qs(a).splice(Math.max(0,Pn(l)+c),1),c--,u=!0},removeAllNextSiblings(){return qs(a).splice(Pn(l)+1)},removeAllPrevSiblings(){const b=Pn(l)+c;return c-=b,qs(a).splice(0,Math.max(0,b))},replaceWith(b,R={}){const U=!!R.traverse;a?a[Math.max(0,Pn(l)+c)]=b:ts(i,"Can't replace root node")[l]=b,U&&r(b,i,l,a),u=!0},replaceWithMultiple(b,R={}){const U=!!R.traverse;if(qs(a).splice(Math.max(0,Pn(l)+c),1,...b),c+=b.length-1,U){let I=0;for(let w=0;w<b.length;w++)I+=r(b[w],i,Pn(l)+w+I,a)}u=!0},skip(){u=!0}},{type:d}=o,h=t["*"],m=t[d],v=typeof h=="function"?h:h==null?void 0:h.enter,x=typeof m=="function"?m:m==null?void 0:m.enter;if(v==null||v(f,n),x==null||x(f,n),!u)switch(d){case"AbsenceFunction":case"CapturingGroup":case"Group":s(o.body,o);break;case"Alternative":case"CharacterClass":s(o.body,o);break;case"Assertion":case"Backreference":case"Character":case"CharacterSet":case"Directive":case"Flags":case"NamedCallout":case"Subroutine":break;case"CharacterClassRange":r(o.min,o,"min"),r(o.max,o,"max");break;case"LookaroundAssertion":s(o.body,o);break;case"Quantifier":r(o.body,o,"body");break;case"Regex":s(o.body,o),r(o.flags,o,"flags");break;default:throw new Error(`Unexpected node type "${d}"`)}return(k=m==null?void 0:m.exit)==null||k.call(m,f,n),(E=h==null?void 0:h.exit)==null||E.call(h,f,n),c}return r(e),e}function qs(e){if(!Array.isArray(e))throw new Error("Container expected");return e}function Pn(e){if(typeof e!="number")throw new Error("Numeric key expected");return e}const l_=String.raw`\(\?(?:[:=!>A-Za-z\-]|<[=!]|\(DEFINE\))`;function a_(e,t){for(let n=0;n<e.length;n++)e[n]>=t&&e[n]++}function c_(e,t,n,s){return e.slice(0,t)+s+e.slice(t+n.length)}const dt=Object.freeze({DEFAULT:"DEFAULT",CHAR_CLASS:"CHAR_CLASS"});function ji(e,t,n,s){const r=new RegExp(String.raw`${t}|(?<$skip>\[\^?|\\?.)`,"gsu"),o=[!1];let i=0,l="";for(const a of e.matchAll(r)){const{0:c,groups:{$skip:u}}=a;if(!u&&(!s||s===dt.DEFAULT==!i)){n instanceof Function?l+=n(a,{context:i?dt.CHAR_CLASS:dt.DEFAULT,negated:o[o.length-1]}):l+=n;continue}c[0]==="["?(i++,o.push(c[1]==="^")):c==="]"&&i&&(i--,o.pop()),l+=c}return l}function Fu(e,t,n,s){ji(e,t,n,s)}function u_(e,t,n=0,s){if(!new RegExp(t,"su").test(e))return null;const r=new RegExp(`${t}|(?<$skip>\\\\?.)`,"gsu");r.lastIndex=n;let o=0,i;for(;i=r.exec(e);){const{0:l,groups:{$skip:a}}=i;if(!a&&(!s||s===dt.DEFAULT==!o))return i;l==="["?o++:l==="]"&&o&&o--,r.lastIndex==i.index&&r.lastIndex++}return null}function zs(e,t,n){return!!u_(e,t,0,n)}function f_(e,t){const n=/\\?./gsu;n.lastIndex=t;let s=e.length,r=0,o=1,i;for(;i=n.exec(e);){const[l]=i;if(l==="[")r++;else if(r)l==="]"&&r--;else if(l==="(")o++;else if(l===")"&&(o--,!o)){s=i.index;break}}return e.slice(t,s)}const _a=new RegExp(String.raw`(?<noncapturingStart>${l_})|(?<capturingStart>\((?:\?<[^>]+>)?)|\\?.`,"gsu");function d_(e,t){const n=(t==null?void 0:t.hiddenCaptures)??[];let s=(t==null?void 0:t.captureTransfers)??new Map;if(!/\(\?>/.test(e))return{pattern:e,captureTransfers:s,hiddenCaptures:n};const r="(?>",o="(?:(?=(",i=[0],l=[];let a=0,c=0,u=NaN,f;do{f=!1;let d=0,h=0,m=!1,v;for(_a.lastIndex=Number.isNaN(u)?0:u+o.length;v=_a.exec(e);){const{0:x,index:k,groups:{capturingStart:E,noncapturingStart:b}}=v;if(x==="[")d++;else if(d)x==="]"&&d--;else if(x===r&&!m)u=k,m=!0;else if(m&&b)h++;else if(E)m?h++:(a++,i.push(a+c));else if(x===")"&&m){if(!h){c++;const R=a+c;if(e=`${e.slice(0,u)}${o}${e.slice(u+r.length,k)}))<$$${R}>)${e.slice(k+1)}`,f=!0,l.push(R),a_(n,R),s.size){const U=new Map;s.forEach((I,w)=>{U.set(w>=R?w+1:w,I.map(W=>W>=R?W+1:W))}),s=U}break}h--}}}while(f);return n.push(...l),e=ji(e,String.raw`\\(?<backrefNum>[1-9]\d*)|<\$\$(?<wrappedBackrefNum>\d+)>`,({0:d,groups:{backrefNum:h,wrappedBackrefNum:m}})=>{if(h){const v=+h;if(v>i.length-1)throw new Error(`Backref "${d}" greater than number of captures`);return`\\${i[v]}`}return`\\${m}`},dt.DEFAULT),{pattern:e,captureTransfers:s,hiddenCaptures:n}}const Bu=String.raw`(?:[?*+]|\{\d+(?:,\d*)?\})`,bo=new RegExp(String.raw`
69
+ \\(?: \d+
70
+ | c[A-Za-z]
71
+ | [gk]<[^>]+>
72
+ | [pPu]\{[^\}]+\}
73
+ | u[A-Fa-f\d]{4}
74
+ | x[A-Fa-f\d]{2}
75
+ )
76
+ | \((?: \? (?: [:=!>]
77
+ | <(?:[=!]|[^>]+>)
78
+ | [A-Za-z\-]+:
79
+ | \(DEFINE\)
80
+ ))?
81
+ | (?<qBase>${Bu})(?<qMod>[?+]?)(?<invalidQ>[?*+\{]?)
82
+ | \\?.
83
+ `.replace(/\s+/g,""),"gsu");function h_(e){if(!new RegExp(`${Bu}\\+`).test(e))return{pattern:e};const t=[];let n=null,s=null,r="",o=0,i;for(bo.lastIndex=0;i=bo.exec(e);){const{0:l,index:a,groups:{qBase:c,qMod:u,invalidQ:f}}=i;if(l==="[")o||(s=a),o++;else if(l==="]")o?o--:s=null;else if(!o)if(u==="+"&&r&&!r.startsWith("(")){if(f)throw new Error(`Invalid quantifier "${l}"`);let d=-1;if(/^\{\d+\}$/.test(c))e=c_(e,a+c.length,u,"");else{if(r===")"||r==="]"){const h=r===")"?n:s;if(h===null)throw new Error(`Invalid unmatched "${r}"`);e=`${e.slice(0,h)}(?>${e.slice(h,a)}${c})${e.slice(a+l.length)}`}else e=`${e.slice(0,a-r.length)}(?>${r}${c})${e.slice(a+l.length)}`;d+=4}bo.lastIndex+=d}else l[0]==="("?t.push(a):l===")"&&(n=t.length?t.pop():null);r=l}return{pattern:e}}const ft=String.raw,p_=ft`\\g<(?<gRNameOrNum>[^>&]+)&R=(?<gRDepth>[^>]+)>`,ni=ft`\(\?R=(?<rDepth>[^\)]+)\)|${p_}`,Kr=ft`\(\?<(?![=!])(?<captureName>[^>]+)>`,Uu=ft`${Kr}|(?<unnamed>\()(?!\?)`,mn=new RegExp(ft`${Kr}|${ni}|\(\?|\\?.`,"gsu"),wo="Cannot use multiple overlapping recursions";function g_(e,t){const{hiddenCaptures:n,mode:s}={hiddenCaptures:[],mode:"plugin",...t};let r=(t==null?void 0:t.captureTransfers)??new Map;if(!new RegExp(ni,"su").test(e))return{pattern:e,captureTransfers:r,hiddenCaptures:n};if(s==="plugin"&&zs(e,ft`\(\?\(DEFINE\)`,dt.DEFAULT))throw new Error("DEFINE groups cannot be used with recursion");const o=[],i=zs(e,ft`\\[1-9]`,dt.DEFAULT),l=new Map,a=[];let c=!1,u=0,f=0,d;for(mn.lastIndex=0;d=mn.exec(e);){const{0:h,groups:{captureName:m,rDepth:v,gRNameOrNum:x,gRDepth:k}}=d;if(h==="[")u++;else if(u)h==="]"&&u--;else if(v){if(ba(v),c)throw new Error(wo);if(i)throw new Error(`${s==="external"?"Backrefs":"Numbered backrefs"} cannot be used with global recursion`);const E=e.slice(0,d.index),b=e.slice(mn.lastIndex);if(zs(b,ni,dt.DEFAULT))throw new Error(wo);const R=+v-1;e=wa(E,b,R,!1,n,o,f),r=xa(r,E,R,o.length,0,f);break}else if(x){ba(k);let E=!1;for(const L of a)if(L.name===x||L.num===+x){if(E=!0,L.hasRecursedWithin)throw new Error(wo);break}if(!E)throw new Error(ft`Recursive \g cannot be used outside the referenced group "${s==="external"?x:ft`\g<${x}&R=${k}>`}"`);const b=l.get(x),R=f_(e,b);if(i&&zs(R,ft`${Kr}|\((?!\?)`,dt.DEFAULT))throw new Error(`${s==="external"?"Backrefs":"Numbered backrefs"} cannot be used with recursion of capturing groups`);const U=e.slice(b,d.index),I=R.slice(U.length+h.length),w=o.length,W=+k-1,Q=wa(U,I,W,!0,n,o,f);r=xa(r,U,W,o.length-w,w,f);const q=e.slice(0,b),re=e.slice(b+R.length);e=`${q}${Q}${re}`,mn.lastIndex+=Q.length-h.length-U.length-I.length,a.forEach(L=>L.hasRecursedWithin=!0),c=!0}else if(m)f++,l.set(String(f),mn.lastIndex),l.set(m,mn.lastIndex),a.push({num:f,name:m});else if(h[0]==="("){const E=h==="(";E&&(f++,l.set(String(f),mn.lastIndex)),a.push(E?{num:f}:{})}else h===")"&&a.pop()}return n.push(...o),{pattern:e,captureTransfers:r,hiddenCaptures:n}}function ba(e){const t=`Max depth must be integer between 2 and 100; used ${e}`;if(!/^[1-9]\d*$/.test(e))throw new Error(t);if(e=+e,e<2||e>100)throw new Error(t)}function wa(e,t,n,s,r,o,i){const l=new Set;s&&Fu(e+t,Kr,({groups:{captureName:c}})=>{l.add(c)},dt.DEFAULT);const a=[n,s?l:null,r,o,i];return`${e}${Ca(`(?:${e}`,"forward",...a)}(?:)${Ca(`${t})`,"backward",...a)}${t}`}function Ca(e,t,n,s,r,o,i){const a=u=>t==="forward"?u+2:n-u+2-1;let c="";for(let u=0;u<n;u++){const f=a(u);c+=ji(e,ft`${Uu}|\\k<(?<backref>[^>]+)>`,({0:d,groups:{captureName:h,unnamed:m,backref:v}})=>{if(v&&s&&!s.has(v))return d;const x=`_$${f}`;if(m||h){const k=i+o.length+1;return o.push(k),m_(r,k),m?d:`(?<${h}${x}>`}return ft`\k<${v}${x}>`},dt.DEFAULT)}return c}function m_(e,t){for(let n=0;n<e.length;n++)e[n]>=t&&e[n]++}function xa(e,t,n,s,r,o){if(e.size&&s){let i=0;Fu(t,Uu,()=>i++,dt.DEFAULT);const l=o-i+r,a=new Map;return e.forEach((c,u)=>{const f=(s-i*n)/n,d=i*n,h=u>l+i?u+s:u,m=[];for(const v of c)if(v<=l)m.push(v);else if(v>l+i+f)m.push(v+s);else if(v<=l+i)for(let x=0;x<=n;x++)m.push(v+i*x);else for(let x=0;x<=n;x++)m.push(v+d+f*x);a.set(h,m)}),a}return e}var Te=String.fromCodePoint,te=String.raw,wt={},Xr=globalThis.RegExp;wt.flagGroups=(()=>{try{new Xr("(?i:)")}catch{return!1}return!0})();wt.unicodeSets=(()=>{try{new Xr("[[]]","v")}catch{return!1}return!0})();wt.bugFlagVLiteralHyphenIsRange=wt.unicodeSets?(()=>{try{new Xr(te`[\d\-a]`,"v")}catch{return!0}return!1})():!1;wt.bugNestedClassIgnoresNegation=wt.unicodeSets&&new Xr("[[^a]]","v").test("a");function Ar(e,{enable:t,disable:n}){return{dotAll:!(n!=null&&n.dotAll)&&!!(t!=null&&t.dotAll||e.dotAll),ignoreCase:!(n!=null&&n.ignoreCase)&&!!(t!=null&&t.ignoreCase||e.ignoreCase)}}function Is(e,t,n){return e.has(t)||e.set(t,n),e.get(t)}function si(e,t){return ka[e]>=ka[t]}function y_(e,t){if(e==null)throw new Error(t??"Value expected");return e}var ka={ES2025:2025,ES2024:2024,ES2018:2018},v_={auto:"auto",ES2025:"ES2025",ES2024:"ES2024",ES2018:"ES2018"};function Hu(e={}){if({}.toString.call(e)!=="[object Object]")throw new Error("Unexpected options");if(e.target!==void 0&&!v_[e.target])throw new Error(`Unexpected target "${e.target}"`);const t={accuracy:"default",avoidSubclass:!1,flags:"",global:!1,hasIndices:!1,lazyCompileLength:1/0,target:"auto",verbose:!1,...e,rules:{allowOrphanBackrefs:!1,asciiWordBoundaries:!1,captureGroup:!1,recursionLimit:20,singleline:!1,...e.rules}};return t.target==="auto"&&(t.target=wt.flagGroups?"ES2025":wt.unicodeSets?"ES2024":"ES2018"),t}var __="[ -\r ]",b_=new Set([Te(304),Te(305)]),Bt=te`[\p{L}\p{M}\p{N}\p{Pc}]`;function Wu(e){if(b_.has(e))return[e];const t=new Set,n=e.toLowerCase(),s=n.toUpperCase(),r=x_.get(n),o=w_.get(n),i=C_.get(n);return[...s].length===1&&t.add(s),i&&t.add(i),r&&t.add(r),t.add(n),o&&t.add(o),[...t]}var Fi=new Map(`C Other
84
+ Cc Control cntrl
85
+ Cf Format
86
+ Cn Unassigned
87
+ Co Private_Use
88
+ Cs Surrogate
89
+ L Letter
90
+ LC Cased_Letter
91
+ Ll Lowercase_Letter
92
+ Lm Modifier_Letter
93
+ Lo Other_Letter
94
+ Lt Titlecase_Letter
95
+ Lu Uppercase_Letter
96
+ M Mark Combining_Mark
97
+ Mc Spacing_Mark
98
+ Me Enclosing_Mark
99
+ Mn Nonspacing_Mark
100
+ N Number
101
+ Nd Decimal_Number digit
102
+ Nl Letter_Number
103
+ No Other_Number
104
+ P Punctuation punct
105
+ Pc Connector_Punctuation
106
+ Pd Dash_Punctuation
107
+ Pe Close_Punctuation
108
+ Pf Final_Punctuation
109
+ Pi Initial_Punctuation
110
+ Po Other_Punctuation
111
+ Ps Open_Punctuation
112
+ S Symbol
113
+ Sc Currency_Symbol
114
+ Sk Modifier_Symbol
115
+ Sm Math_Symbol
116
+ So Other_Symbol
117
+ Z Separator
118
+ Zl Line_Separator
119
+ Zp Paragraph_Separator
120
+ Zs Space_Separator
121
+ ASCII
122
+ ASCII_Hex_Digit AHex
123
+ Alphabetic Alpha
124
+ Any
125
+ Assigned
126
+ Bidi_Control Bidi_C
127
+ Bidi_Mirrored Bidi_M
128
+ Case_Ignorable CI
129
+ Cased
130
+ Changes_When_Casefolded CWCF
131
+ Changes_When_Casemapped CWCM
132
+ Changes_When_Lowercased CWL
133
+ Changes_When_NFKC_Casefolded CWKCF
134
+ Changes_When_Titlecased CWT
135
+ Changes_When_Uppercased CWU
136
+ Dash
137
+ Default_Ignorable_Code_Point DI
138
+ Deprecated Dep
139
+ Diacritic Dia
140
+ Emoji
141
+ Emoji_Component EComp
142
+ Emoji_Modifier EMod
143
+ Emoji_Modifier_Base EBase
144
+ Emoji_Presentation EPres
145
+ Extended_Pictographic ExtPict
146
+ Extender Ext
147
+ Grapheme_Base Gr_Base
148
+ Grapheme_Extend Gr_Ext
149
+ Hex_Digit Hex
150
+ IDS_Binary_Operator IDSB
151
+ IDS_Trinary_Operator IDST
152
+ ID_Continue IDC
153
+ ID_Start IDS
154
+ Ideographic Ideo
155
+ Join_Control Join_C
156
+ Logical_Order_Exception LOE
157
+ Lowercase Lower
158
+ Math
159
+ Noncharacter_Code_Point NChar
160
+ Pattern_Syntax Pat_Syn
161
+ Pattern_White_Space Pat_WS
162
+ Quotation_Mark QMark
163
+ Radical
164
+ Regional_Indicator RI
165
+ Sentence_Terminal STerm
166
+ Soft_Dotted SD
167
+ Terminal_Punctuation Term
168
+ Unified_Ideograph UIdeo
169
+ Uppercase Upper
170
+ Variation_Selector VS
171
+ White_Space space
172
+ XID_Continue XIDC
173
+ XID_Start XIDS`.split(/\s/).map(e=>[zr(e),e])),w_=new Map([["s",Te(383)],[Te(383),"s"]]),C_=new Map([[Te(223),Te(7838)],[Te(107),Te(8490)],[Te(229),Te(8491)],[Te(969),Te(8486)]]),x_=new Map([tn(453),tn(456),tn(459),tn(498),...Co(8072,8079),...Co(8088,8095),...Co(8104,8111),tn(8124),tn(8140),tn(8188)]),k_=new Map([["alnum",te`[\p{Alpha}\p{Nd}]`],["alpha",te`\p{Alpha}`],["ascii",te`\p{ASCII}`],["blank",te`[\p{Zs}\t]`],["cntrl",te`\p{Cc}`],["digit",te`\p{Nd}`],["graph",te`[\P{space}&&\P{Cc}&&\P{Cn}&&\P{Cs}]`],["lower",te`\p{Lower}`],["print",te`[[\P{space}&&\P{Cc}&&\P{Cn}&&\P{Cs}]\p{Zs}]`],["punct",te`[\p{P}\p{S}]`],["space",te`\p{space}`],["upper",te`\p{Upper}`],["word",te`[\p{Alpha}\p{M}\p{Nd}\p{Pc}]`],["xdigit",te`\p{AHex}`]]);function S_(e,t){const n=[];for(let s=e;s<=t;s++)n.push(s);return n}function tn(e){const t=Te(e);return[t.toLowerCase(),t]}function Co(e,t){return S_(e,t).map(n=>tn(n))}var Vu=new Set(["Lower","Lowercase","Upper","Uppercase","Ll","Lowercase_Letter","Lt","Titlecase_Letter","Lu","Uppercase_Letter"]);function E_(e,t){const n={accuracy:"default",asciiWordBoundaries:!1,avoidSubclass:!1,bestEffortTarget:"ES2025",...t};qu(e);const s={accuracy:n.accuracy,asciiWordBoundaries:n.asciiWordBoundaries,avoidSubclass:n.avoidSubclass,flagDirectivesByAlt:new Map,jsGroupNameMap:new Map,minTargetEs2024:si(n.bestEffortTarget,"ES2024"),passedLookbehind:!1,strategy:null,subroutineRefMap:new Map,supportedGNodes:new Set,digitIsAscii:e.flags.digitIsAscii,spaceIsAscii:e.flags.spaceIsAscii,wordIsAscii:e.flags.wordIsAscii};_s(e,A_,s);const r={dotAll:e.flags.dotAll,ignoreCase:e.flags.ignoreCase},o={currentFlags:r,prevFlags:null,globalFlags:r,groupOriginByCopy:new Map,groupsByName:new Map,multiplexCapturesToLeftByRef:new Map,openRefs:new Map,reffedNodesByReferencer:new Map,subroutineRefMap:s.subroutineRefMap};_s(e,R_,o);const i={groupsByName:o.groupsByName,highestOrphanBackref:0,numCapturesToLeft:0,reffedNodesByReferencer:o.reffedNodesByReferencer};return _s(e,$_,i),e._originMap=o.groupOriginByCopy,e._strategy=s.strategy,e}var A_={AbsenceFunction({node:e,parent:t,replaceWith:n}){const{body:s,kind:r}=e;if(r==="repeater"){const o=mt();o.body[0].body.push(_n({negate:!0,body:s}),Dn("Any"));const i=mt();i.body[0].body.push(Du("greedy",0,1/0,o)),n($e(i,t),{traverse:!0})}else throw new Error('Unsupported absence function "(?~|"')},Alternative:{enter({node:e,parent:t,key:n},{flagDirectivesByAlt:s}){const r=e.body.filter(o=>o.kind==="flags");for(let o=n+1;o<t.body.length;o++){const i=t.body[o];Is(s,i,[]).push(...r)}},exit({node:e},{flagDirectivesByAlt:t}){var n;if((n=t.get(e))!=null&&n.length){const s=Ku(t.get(e));if(s){const r=mt({flags:s});r.body[0].body=e.body,e.body=[$e(r,e)]}}}},Assertion({node:e,parent:t,key:n,container:s,root:r,remove:o,replaceWith:i},l){const{kind:a,negate:c}=e,{asciiWordBoundaries:u,avoidSubclass:f,supportedGNodes:d,wordIsAscii:h}=l;if(a==="text_segment_boundary")throw new Error(`Unsupported text segment boundary "\\${c?"Y":"y"}"`);if(a==="line_end")i($e(_n({body:[Rn({body:[Zo("string_end")]}),Rn({body:[qr(10)]})]}),t));else if(a==="line_start")i($e(Ut(te`(?<=\A|\n(?!\z))`,{skipLookbehindValidation:!0}),t));else if(a==="search_start")if(d.has(e))r.flags.sticky=!0,o();else{const m=s[n-1];if(m&&M_(m))i($e(_n({negate:!0}),t));else{if(f)throw new Error(te`Uses "\G" in a way that requires a subclass`);i(nn(Zo("string_start"),t)),l.strategy="clip_search"}}else if(!(a==="string_end"||a==="string_start"))if(a==="string_end_newline")i($e(Ut(te`(?=\n?\z)`),t));else if(a==="word_boundary"){if(!h&&!u){const m=`(?:(?<=${Bt})(?!${Bt})|(?<!${Bt})(?=${Bt}))`,v=`(?:(?<=${Bt})(?=${Bt})|(?<!${Bt})(?!${Bt}))`;i($e(Ut(c?v:m),t))}}else throw new Error(`Unexpected assertion kind "${a}"`)},Backreference({node:e},{jsGroupNameMap:t}){let{ref:n}=e;typeof n=="string"&&!ko(n)&&(n=xo(n,t),e.ref=n)},CapturingGroup({node:e},{jsGroupNameMap:t,subroutineRefMap:n}){let{name:s}=e;s&&!ko(s)&&(s=xo(s,t),e.name=s),n.set(e.number,e),s&&n.set(s,e)},CharacterClassRange({node:e,parent:t,replaceWith:n}){if(t.kind==="intersection"){const s=nr({body:[e]});n($e(s,t),{traverse:!0})}},CharacterSet({node:e,parent:t,replaceWith:n},{accuracy:s,minTargetEs2024:r,digitIsAscii:o,spaceIsAscii:i,wordIsAscii:l}){const{kind:a,negate:c,value:u}=e;if(o&&(a==="digit"||u==="digit")){n(nn(ti("digit",{negate:c}),t));return}if(i&&(a==="space"||u==="space")){n($e(So(Ut(__),c),t));return}if(l&&(a==="word"||u==="word")){n(nn(ti("word",{negate:c}),t));return}if(a==="any")n(nn(Dn("Any"),t));else if(a==="digit")n(nn(Dn("Nd",{negate:c}),t));else if(a!=="dot")if(a==="text_segment"){if(s==="strict")throw new Error(te`Use of "\X" requires non-strict accuracy`);const f="\\p{Emoji}(?:\\p{EMod}|\\uFE0F\\u20E3?|[\\x{E0020}-\\x{E007E}]+\\x{E007F})?",d=te`\p{RI}{2}|${f}(?:\u200D${f})*`;n($e(Ut(te`(?>\r\n|${r?te`\p{RGI_Emoji}`:d}|\P{M}\p{M}*)`,{skipPropertyNameValidation:!0}),t))}else if(a==="hex")n(nn(Dn("AHex",{negate:c}),t));else if(a==="newline")n($e(Ut(c?`[^
174
+ ]`:`(?>\r
175
+ ?|[
176
+ \v\f…\u2028\u2029])`),t));else if(a==="posix")if(!r&&(u==="graph"||u==="print")){if(s==="strict")throw new Error(`POSIX class "${u}" requires min target ES2024 or non-strict accuracy`);let f={graph:"!-~",print:" -~"}[u];c&&(f=`\0-${Te(f.codePointAt(0)-1)}${Te(f.codePointAt(2)+1)}-􏿿`),n($e(Ut(`[${f}]`),t))}else n($e(So(Ut(k_.get(u)),c),t));else if(a==="property")Fi.has(zr(u))||(e.key="sc");else if(a==="space")n(nn(Dn("space",{negate:c}),t));else if(a==="word")n($e(So(Ut(Bt),c),t));else throw new Error(`Unexpected character set kind "${a}"`)},Directive({node:e,parent:t,root:n,remove:s,replaceWith:r,removeAllPrevSiblings:o,removeAllNextSiblings:i}){const{kind:l,flags:a}=e;if(l==="flags")if(!a.enable&&!a.disable)s();else{const c=mt({flags:a});c.body[0].body=i(),r($e(c,t),{traverse:!0})}else if(l==="keep"){const c=n.body[0],f=n.body.length===1&&Tu(c,{type:"Group"})&&c.body[0].body.length===1?c.body[0]:n;if(t.parent!==f||f.body.length>1)throw new Error(te`Uses "\K" in a way that's unsupported`);const d=_n({behind:!0});d.body[0].body=o(),r($e(d,t))}else throw new Error(`Unexpected directive kind "${l}"`)},Flags({node:e,parent:t}){if(e.posixIsAscii)throw new Error('Unsupported flag "P"');if(e.textSegmentMode==="word")throw new Error('Unsupported flag "y{w}"');["digitIsAscii","extended","posixIsAscii","spaceIsAscii","wordIsAscii","textSegmentMode"].forEach(n=>delete e[n]),Object.assign(e,{global:!1,hasIndices:!1,multiline:!1,sticky:e.sticky??!1}),t.options={disable:{x:!0,n:!0},force:{v:!0}}},Group({node:e}){if(!e.flags)return;const{enable:t,disable:n}=e.flags;t!=null&&t.extended&&delete t.extended,n!=null&&n.extended&&delete n.extended,t!=null&&t.dotAll&&(n!=null&&n.dotAll)&&delete t.dotAll,t!=null&&t.ignoreCase&&(n!=null&&n.ignoreCase)&&delete t.ignoreCase,t&&!Object.keys(t).length&&delete e.flags.enable,n&&!Object.keys(n).length&&delete e.flags.disable,!e.flags.enable&&!e.flags.disable&&delete e.flags},LookaroundAssertion({node:e},t){const{kind:n}=e;n==="lookbehind"&&(t.passedLookbehind=!0)},NamedCallout({node:e,parent:t,replaceWith:n}){const{kind:s}=e;if(s==="fail")n($e(_n({negate:!0}),t));else throw new Error(`Unsupported named callout "(*${s.toUpperCase()}"`)},Quantifier({node:e}){if(e.body.type==="Quantifier"){const t=mt();t.body[0].body.push(e.body),e.body=$e(t,e)}},Regex:{enter({node:e},{supportedGNodes:t}){const n=[];let s=!1,r=!1;for(const o of e.body)if(o.body.length===1&&o.body[0].kind==="search_start")o.body.pop();else{const i=Ju(o.body);i?(s=!0,Array.isArray(i)?n.push(...i):n.push(i)):r=!0}s&&!r&&n.forEach(o=>t.add(o))},exit(e,{accuracy:t,passedLookbehind:n,strategy:s}){if(t==="strict"&&n&&s)throw new Error(te`Uses "\G" in a way that requires non-strict accuracy`)}},Subroutine({node:e},{jsGroupNameMap:t}){let{ref:n}=e;typeof n=="string"&&!ko(n)&&(n=xo(n,t),e.ref=n)}},R_={Backreference({node:e},{multiplexCapturesToLeftByRef:t,reffedNodesByReferencer:n}){const{orphan:s,ref:r}=e;s||n.set(e,[...t.get(r).map(({node:o})=>o)])},CapturingGroup:{enter({node:e,parent:t,replaceWith:n,skip:s},{groupOriginByCopy:r,groupsByName:o,multiplexCapturesToLeftByRef:i,openRefs:l,reffedNodesByReferencer:a}){const c=r.get(e);if(c&&l.has(e.number)){const f=nn(Sa(e.number),t);a.set(f,l.get(e.number)),n(f);return}l.set(e.number,e),i.set(e.number,[]),e.name&&Is(i,e.name,[]);const u=i.get(e.name??e.number);for(let f=0;f<u.length;f++){const d=u[f];if(c===d.node||c&&c===d.origin||e===d.origin){u.splice(f,1);break}}if(i.get(e.number).push({node:e,origin:c}),e.name&&i.get(e.name).push({node:e,origin:c}),e.name){const f=Is(o,e.name,new Map);let d=!1;if(c)d=!0;else for(const h of f.values())if(!h.hasDuplicateNameToRemove){d=!0;break}o.get(e.name).set(e,{node:e,hasDuplicateNameToRemove:d})}},exit({node:e},{openRefs:t}){t.delete(e.number)}},Group:{enter({node:e},t){t.prevFlags=t.currentFlags,e.flags&&(t.currentFlags=Ar(t.currentFlags,e.flags))},exit(e,t){t.currentFlags=t.prevFlags}},Subroutine({node:e,parent:t,replaceWith:n},s){const{isRecursive:r,ref:o}=e;if(r){let u=t;for(;(u=u.parent)&&!(u.type==="CapturingGroup"&&(u.name===o||u.number===o)););s.reffedNodesByReferencer.set(e,u);return}const i=s.subroutineRefMap.get(o),l=o===0,a=l?Sa(0):zu(i,s.groupOriginByCopy,null);let c=a;if(!l){const u=Ku(P_(i,d=>d.type==="Group"&&!!d.flags)),f=u?Ar(s.globalFlags,u):s.globalFlags;I_(f,s.currentFlags)||(c=mt({flags:O_(f)}),c.body[0].body.push(a))}n($e(c,t),{traverse:!l})}},$_={Backreference({node:e,parent:t,replaceWith:n},s){if(e.orphan){s.highestOrphanBackref=Math.max(s.highestOrphanBackref,e.ref);return}const o=s.reffedNodesByReferencer.get(e).filter(i=>N_(i,e));if(!o.length)n($e(_n({negate:!0}),t));else if(o.length>1){const i=mt({atomic:!0,body:o.reverse().map(l=>Rn({body:[ei(l.number)]}))});n($e(i,t))}else e.ref=o[0].number},CapturingGroup({node:e},t){e.number=++t.numCapturesToLeft,e.name&&t.groupsByName.get(e.name).get(e).hasDuplicateNameToRemove&&delete e.name},Regex:{exit({node:e},t){const n=Math.max(t.highestOrphanBackref-t.numCapturesToLeft,0);for(let s=0;s<n;s++){const r=Lu();e.body.at(-1).body.push(r)}}},Subroutine({node:e},t){!e.isRecursive||e.ref===0||(e.ref=t.reffedNodesByReferencer.get(e).number)}};function qu(e){_s(e,{"*"({node:t,parent:n}){t.parent=n}})}function I_(e,t){return e.dotAll===t.dotAll&&e.ignoreCase===t.ignoreCase}function N_(e,t){let n=t;do{if(n.type==="Regex")return!1;if(n.type==="Alternative")continue;if(n===e)return!1;const s=Xu(n.parent);for(const r of s){if(r===n)break;if(r===e||Yu(r,e))return!0}}while(n=n.parent);throw new Error("Unexpected path")}function zu(e,t,n,s){const r=Array.isArray(e)?[]:{};for(const[o,i]of Object.entries(e))o==="parent"?r.parent=Array.isArray(n)?s:n:i&&typeof i=="object"?r[o]=zu(i,t,r,n):(o==="type"&&i==="CapturingGroup"&&t.set(r,t.get(e)??e),r[o]=i);return r}function Sa(e){const t=Gu(e);return t.isRecursive=!0,t}function P_(e,t){const n=[];for(;e=e.parent;)(!t||t(e))&&n.push(e);return n}function xo(e,t){if(t.has(e))return t.get(e);const n=`$${t.size}_${e.replace(/^[^$_\p{IDS}]|[^$\u200C\u200D\p{IDC}]/ug,"_")}`;return t.set(e,n),n}function Ku(e){const t=["dotAll","ignoreCase"],n={enable:{},disable:{}};return e.forEach(({flags:s})=>{t.forEach(r=>{var o,i;(o=s.enable)!=null&&o[r]&&(delete n.disable[r],n.enable[r]=!0),(i=s.disable)!=null&&i[r]&&(n.disable[r]=!0)})}),Object.keys(n.enable).length||delete n.enable,Object.keys(n.disable).length||delete n.disable,n.enable||n.disable?n:null}function O_({dotAll:e,ignoreCase:t}){const n={};return(e||t)&&(n.enable={},e&&(n.enable.dotAll=!0),t&&(n.enable.ignoreCase=!0)),(!e||!t)&&(n.disable={},!e&&(n.disable.dotAll=!0),!t&&(n.disable.ignoreCase=!0)),n}function Xu(e){if(!e)throw new Error("Node expected");const{body:t}=e;return Array.isArray(t)?t:t?[t]:null}function Ju(e){const t=e.find(n=>n.kind==="search_start"||L_(n,{negate:!1})||!T_(n));if(!t)return null;if(t.kind==="search_start")return t;if(t.type==="LookaroundAssertion")return t.body[0].body[0];if(t.type==="CapturingGroup"||t.type==="Group"){const n=[];for(const s of t.body){const r=Ju(s.body);if(!r)return null;Array.isArray(r)?n.push(...r):n.push(r)}return n}return null}function Yu(e,t){const n=Xu(e)??[];for(const s of n)if(s===t||Yu(s,t))return!0;return!1}function T_({type:e}){return e==="Assertion"||e==="Directive"||e==="LookaroundAssertion"}function M_(e){const t=["Character","CharacterClass","CharacterSet"];return t.includes(e.type)||e.type==="Quantifier"&&e.min&&t.includes(e.body.type)}function L_(e,t){const n={negate:null,...t};return e.type==="LookaroundAssertion"&&(n.negate===null||e.negate===n.negate)&&e.body.length===1&&Tu(e.body[0],{type:"Assertion",kind:"search_start"})}function ko(e){return/^[$_\p{IDS}][$\u200C\u200D\p{IDC}]*$/u.test(e)}function Ut(e,t){const s=Mu(e,{...t,unicodePropertyMap:Fi}).body;return s.length>1||s[0].body.length>1?mt({body:s}):s[0].body[0]}function So(e,t){return e.negate=t,e}function nn(e,t){return e.parent=t,e}function $e(e,t){return qu(e),e.parent=t,e}function D_(e,t){const n=Hu(t),s=si(n.target,"ES2024"),r=si(n.target,"ES2025"),o=n.rules.recursionLimit;if(!Number.isInteger(o)||o<2||o>20)throw new Error("Invalid recursionLimit; use 2-20");let i=null,l=null;if(!r){const h=[e.flags.ignoreCase];_s(e,G_,{getCurrentModI:()=>h.at(-1),popModI(){h.pop()},pushModI(m){h.push(m)},setHasCasedChar(){h.at(-1)?i=!0:l=!0}})}const a={dotAll:e.flags.dotAll,ignoreCase:!!((e.flags.ignoreCase||i)&&!l)};let c=e;const u={accuracy:n.accuracy,appliedGlobalFlags:a,captureMap:new Map,currentFlags:{dotAll:e.flags.dotAll,ignoreCase:e.flags.ignoreCase},inCharClass:!1,lastNode:c,originMap:e._originMap,recursionLimit:o,useAppliedIgnoreCase:!!(!r&&i&&l),useFlagMods:r,useFlagV:s,verbose:n.verbose};function f(h){return u.lastNode=c,c=h,y_(j_[h.type],`Unexpected node type "${h.type}"`)(h,u,f)}const d={pattern:e.body.map(f).join("|"),flags:f(e.flags),options:{...e.options}};return s||(delete d.options.force.v,d.options.disable.v=!0,d.options.unicodeSetsPlugin=null),d._captureTransfers=new Map,d._hiddenCaptures=[],u.captureMap.forEach((h,m)=>{h.hidden&&d._hiddenCaptures.push(m),h.transferTo&&Is(d._captureTransfers,h.transferTo,[]).push(m)}),d}var G_={"*":{enter({node:e},t){if(Aa(e)){const n=t.getCurrentModI();t.pushModI(e.flags?Ar({ignoreCase:n},e.flags).ignoreCase:n)}},exit({node:e},t){Aa(e)&&t.popModI()}},Backreference(e,t){t.setHasCasedChar()},Character({node:e},t){Bi(Te(e.value))&&t.setHasCasedChar()},CharacterClassRange({node:e,skip:t},n){t(),Qu(e,{firstOnly:!0}).length&&n.setHasCasedChar()},CharacterSet({node:e},t){e.kind==="property"&&Vu.has(e.value)&&t.setHasCasedChar()}},j_={Alternative({body:e},t,n){return e.map(n).join("")},Assertion({kind:e,negate:t}){if(e==="string_end")return"$";if(e==="string_start")return"^";if(e==="word_boundary")return t?te`\B`:te`\b`;throw new Error(`Unexpected assertion kind "${e}"`)},Backreference({ref:e},t){if(typeof e!="number")throw new Error("Unexpected named backref in transformed AST");if(!t.useFlagMods&&t.accuracy==="strict"&&t.currentFlags.ignoreCase&&!t.captureMap.get(e).ignoreCase)throw new Error("Use of case-insensitive backref to case-sensitive group requires target ES2025 or non-strict accuracy");return"\\"+e},CapturingGroup(e,t,n){const{body:s,name:r,number:o}=e,i={ignoreCase:t.currentFlags.ignoreCase},l=t.originMap.get(e);return l&&(i.hidden=!0,o>l.number&&(i.transferTo=l.number)),t.captureMap.set(o,i),`(${r?`?<${r}>`:""}${s.map(n).join("|")})`},Character({value:e},t){const n=Te(e),s=On(e,{escDigit:t.lastNode.type==="Backreference",inCharClass:t.inCharClass,useFlagV:t.useFlagV});if(s!==n)return s;if(t.useAppliedIgnoreCase&&t.currentFlags.ignoreCase&&Bi(n)){const r=Wu(n);return t.inCharClass?r.join(""):r.length>1?`[${r.join("")}]`:r[0]}return n},CharacterClass(e,t,n){const{kind:s,negate:r,parent:o}=e;let{body:i}=e;if(s==="intersection"&&!t.useFlagV)throw new Error("Use of character class intersection requires min target ES2024");wt.bugFlagVLiteralHyphenIsRange&&t.useFlagV&&i.some(Ra)&&(i=[qr(45),...i.filter(c=>!Ra(c))]);const l=()=>`[${r?"^":""}${i.map(n).join(s==="intersection"?"&&":"")}]`;if(!t.inCharClass){if((!t.useFlagV||wt.bugNestedClassIgnoresNegation)&&!r){const u=i.filter(f=>f.type==="CharacterClass"&&f.kind==="union"&&f.negate);if(u.length){const f=mt(),d=f.body[0];return f.parent=o,d.parent=f,i=i.filter(h=>!u.includes(h)),e.body=i,i.length?(e.parent=d,d.body.push(e)):f.body.pop(),u.forEach(h=>{const m=Rn({body:[h]});h.parent=m,m.parent=f,f.body.push(m)}),n(f)}}t.inCharClass=!0;const c=l();return t.inCharClass=!1,c}const a=i[0];if(s==="union"&&!r&&a&&((!t.useFlagV||!t.verbose)&&o.kind==="union"&&!(wt.bugFlagVLiteralHyphenIsRange&&t.useFlagV)||!t.verbose&&o.kind==="intersection"&&i.length===1&&a.type!=="CharacterClassRange"))return i.map(n).join("");if(!t.useFlagV&&o.type==="CharacterClass")throw new Error("Uses nested character class in a way that requires min target ES2024");return l()},CharacterClassRange(e,t){const n=e.min.value,s=e.max.value,r={escDigit:!1,inCharClass:!0,useFlagV:t.useFlagV},o=On(n,r),i=On(s,r),l=new Set;if(t.useAppliedIgnoreCase&&t.currentFlags.ignoreCase){const a=Qu(e);W_(a).forEach(u=>{l.add(Array.isArray(u)?`${On(u[0],r)}-${On(u[1],r)}`:On(u,r))})}return`${o}-${i}${[...l].join("")}`},CharacterSet({kind:e,negate:t,value:n,key:s},r){if(e==="dot")return r.currentFlags.dotAll?r.appliedGlobalFlags.dotAll||r.useFlagMods?".":"[^]":te`[^\n]`;if(e==="digit")return t?te`\D`:te`\d`;if(e==="property"){if(r.useAppliedIgnoreCase&&r.currentFlags.ignoreCase&&Vu.has(n))throw new Error(`Unicode property "${n}" can't be case-insensitive when other chars have specific case`);return`${t?te`\P`:te`\p`}{${s?`${s}=`:""}${n}}`}if(e==="word")return t?te`\W`:te`\w`;throw new Error(`Unexpected character set kind "${e}"`)},Flags(e,t){return(t.appliedGlobalFlags.ignoreCase?"i":"")+(e.dotAll?"s":"")+(e.sticky?"y":"")},Group({atomic:e,body:t,flags:n,parent:s},r,o){const i=r.currentFlags;n&&(r.currentFlags=Ar(i,n));const l=t.map(o).join("|"),a=!r.verbose&&t.length===1&&s.type!=="Quantifier"&&!e&&(!r.useFlagMods||!n)?l:`(?${V_(e,n,r.useFlagMods)}${l})`;return r.currentFlags=i,a},LookaroundAssertion({body:e,kind:t,negate:n},s,r){return`(?${`${t==="lookahead"?"":"<"}${n?"!":"="}`}${e.map(r).join("|")})`},Quantifier(e,t,n){return n(e.body)+q_(e)},Subroutine({isRecursive:e,ref:t},n){if(!e)throw new Error("Unexpected non-recursive subroutine in transformed AST");const s=n.recursionLimit;return t===0?`(?R=${s})`:te`\g<${t}&R=${s}>`}},F_=new Set(["$","(",")","*","+",".","?","[","\\","]","^","{","|","}"]),B_=new Set(["-","\\","]","^","["]),U_=new Set(["(",")","-","/","[","\\","]","^","{","|","}","!","#","$","%","&","*","+",",",".",":",";","<","=",">","?","@","`","~"]),Ea=new Map([[9,te`\t`],[10,te`\n`],[11,te`\v`],[12,te`\f`],[13,te`\r`],[8232,te`\u2028`],[8233,te`\u2029`],[65279,te`\uFEFF`]]),H_=new RegExp("^\\p{Cased}$","u");function Bi(e){return H_.test(e)}function Qu(e,t){const n=!!(t!=null&&t.firstOnly),s=e.min.value,r=e.max.value,o=[];if(s<65&&(r===65535||r>=131071)||s===65536&&r>=131071)return o;for(let i=s;i<=r;i++){const l=Te(i);if(!Bi(l))continue;const a=Wu(l).filter(c=>{const u=c.codePointAt(0);return u<s||u>r});if(a.length&&(o.push(...a),n))break}return o}function On(e,{escDigit:t,inCharClass:n,useFlagV:s}){if(Ea.has(e))return Ea.get(e);if(e<32||e>126&&e<160||e>262143||t&&z_(e))return e>255?`\\u{${e.toString(16).toUpperCase()}}`:`\\x${e.toString(16).toUpperCase().padStart(2,"0")}`;const r=n?s?U_:B_:F_,o=Te(e);return(r.has(o)?"\\":"")+o}function W_(e){const t=e.map(r=>r.codePointAt(0)).sort((r,o)=>r-o),n=[];let s=null;for(let r=0;r<t.length;r++)t[r+1]===t[r]+1?s??(s=t[r]):s===null?n.push(t[r]):(n.push([s,t[r]]),s=null);return n}function V_(e,t,n){if(e)return">";let s="";if(t&&n){const{enable:r,disable:o}=t;s=(r!=null&&r.ignoreCase?"i":"")+(r!=null&&r.dotAll?"s":"")+(o?"-":"")+(o!=null&&o.ignoreCase?"i":"")+(o!=null&&o.dotAll?"s":"")}return`${s}:`}function q_({kind:e,max:t,min:n}){let s;return!n&&t===1?s="?":!n&&t===1/0?s="*":n===1&&t===1/0?s="+":n===t?s=`{${n}}`:s=`{${n},${t===1/0?"":t}}`,s+{greedy:"",lazy:"?",possessive:"+"}[e]}function Aa({type:e}){return e==="CapturingGroup"||e==="Group"||e==="LookaroundAssertion"}function z_(e){return e>47&&e<58}function Ra({type:e,value:t}){return e==="Character"&&t===45}var on,Vt,xn,ln,kn,Ns,ri,cn,K_=(cn=class extends RegExp{constructor(n,s,r){var t=(...O1)=>(super(...O1),hn(this,Ns),hn(this,on,new Map),hn(this,Vt,null),hn(this,xn),hn(this,ln,null),hn(this,kn,null),$(this,"rawOptions",{}),this);const o=!!(r!=null&&r.lazyCompile);if(n instanceof RegExp){if(r)throw new Error("Cannot provide options when copying a regexp");const i=n;t(i,s),gt(this,xn,i.source),i instanceof cn&&(gt(this,on,Ve(i,on)),gt(this,ln,Ve(i,ln)),gt(this,kn,Ve(i,kn)),this.rawOptions=i.rawOptions)}else{const i={hiddenCaptures:[],strategy:null,transfers:[],...r};t(o?"":n,s),gt(this,xn,n),gt(this,on,J_(i.hiddenCaptures,i.transfers)),gt(this,kn,i.strategy),this.rawOptions=r??{}}o||gt(this,Vt,this)}get source(){return Ve(this,xn)||"(?:)"}exec(n){if(!Ve(this,Vt)){const{lazyCompile:o,...i}=this.rawOptions;gt(this,Vt,new cn(Ve(this,xn),this.flags,i))}const s=this.global||this.sticky,r=this.lastIndex;if(Ve(this,kn)==="clip_search"&&s&&r){this.lastIndex=0;const o=Yr(this,Ns,ri).call(this,n.slice(r));return o&&(X_(o,r,n,this.hasIndices),this.lastIndex+=r),o}return Yr(this,Ns,ri).call(this,n)}},on=new WeakMap,Vt=new WeakMap,xn=new WeakMap,ln=new WeakMap,kn=new WeakMap,Ns=new WeakSet,ri=function(n){Ve(this,Vt).lastIndex=this.lastIndex;const s=qi(cn.prototype,this,"exec").call(Ve(this,Vt),n);if(this.lastIndex=Ve(this,Vt).lastIndex,!s||!Ve(this,on).size)return s;const r=[...s];s.length=1;let o;this.hasIndices&&(o=[...s.indices],s.indices.length=1);const i=[0];for(let l=1;l<r.length;l++){const{hidden:a,transferTo:c}=Ve(this,on).get(l)??{};if(a?i.push(null):(i.push(s.length),s.push(r[l]),this.hasIndices&&s.indices.push(o[l])),c&&r[l]!==void 0){const u=i[c];if(!u)throw new Error(`Invalid capture transfer to "${u}"`);if(s[u]=r[l],this.hasIndices&&(s.indices[u]=o[l]),s.groups){Ve(this,ln)||gt(this,ln,Y_(this.source));const f=Ve(this,ln).get(c);f&&(s.groups[f]=r[l],this.hasIndices&&(s.indices.groups[f]=o[l]))}}}return s},cn);function X_(e,t,n,s){if(e.index+=t,e.input=n,s){const r=e.indices;for(let i=0;i<r.length;i++){const l=r[i];l&&(r[i]=[l[0]+t,l[1]+t])}const o=r.groups;o&&Object.keys(o).forEach(i=>{const l=o[i];l&&(o[i]=[l[0]+t,l[1]+t])})}}function J_(e,t){const n=new Map;for(const s of e)n.set(s,{hidden:!0});for(const[s,r]of t)for(const o of r)Is(n,o,{}).transferTo=s;return n}function Y_(e){const t=/(?<capture>\((?:\?<(?![=!])(?<name>[^>]+)>|(?!\?)))|\\?./gsu,n=new Map;let s=0,r=0,o;for(;o=t.exec(e);){const{0:i,groups:{capture:l,name:a}}=o;i==="["?s++:s?i==="]"&&s--:l&&(r++,a&&n.set(r,a))}return n}function Q_(e,t){const n=Z_(e,t);return n.options?new K_(n.pattern,n.flags,n.options):new RegExp(n.pattern,n.flags)}function Z_(e,t){const n=Hu(t),s=Mu(e,{flags:n.flags,normalizeUnknownPropertyNames:!0,rules:{captureGroup:n.rules.captureGroup,singleline:n.rules.singleline},skipBackrefValidation:n.rules.allowOrphanBackrefs,unicodePropertyMap:Fi}),r=E_(s,{accuracy:n.accuracy,asciiWordBoundaries:n.rules.asciiWordBoundaries,avoidSubclass:n.avoidSubclass,bestEffortTarget:n.target}),o=D_(r,n),i=g_(o.pattern,{captureTransfers:o._captureTransfers,hiddenCaptures:o._hiddenCaptures,mode:"external"}),l=h_(i.pattern),a=d_(l.pattern,{captureTransfers:i.captureTransfers,hiddenCaptures:i.hiddenCaptures}),c={pattern:a.pattern,flags:`${n.hasIndices?"d":""}${n.global?"g":""}${o.flags}${o.options.disable.v?"u":"v"}`};if(n.avoidSubclass){if(n.lazyCompileLength!==1/0)throw new Error("Lazy compilation requires subclass")}else{const u=a.hiddenCaptures.sort((m,v)=>m-v),f=Array.from(a.captureTransfers),d=r._strategy,h=c.pattern.length>=n.lazyCompileLength;(u.length||f.length||d||h)&&(c.options={...u.length&&{hiddenCaptures:u},...f.length&&{transfers:f},...d&&{strategy:d},...h&&{lazyCompile:h}})}return c}const $a=4294967295;class eb{constructor(t,n={}){$(this,"regexps");this.patterns=t,this.options=n;const{forgiving:s=!1,cache:r,regexConstructor:o}=n;if(!o)throw new Error("Option `regexConstructor` is not provided");this.regexps=t.map(i=>{if(typeof i!="string")return i;const l=r==null?void 0:r.get(i);if(l){if(l instanceof RegExp)return l;if(s)return null;throw l}try{const a=o(i);return r==null||r.set(i,a),a}catch(a){if(r==null||r.set(i,a),s)return null;throw a}})}findNextMatchSync(t,n,s){const r=typeof t=="string"?t:t.content,o=[];function i(l,a,c=0){return{index:l,captureIndices:a.indices.map(u=>u==null?{start:$a,end:$a,length:0}:{start:u[0]+c,end:u[1]+c,length:u[1]-u[0]})}}for(let l=0;l<this.regexps.length;l++){const a=this.regexps[l];if(a)try{a.lastIndex=n;const c=a.exec(r);if(!c)continue;if(c.index===n)return i(l,c,0);o.push([l,c,0])}catch(c){if(this.options.forgiving)continue;throw c}}if(o.length){const l=Math.min(...o.map(a=>a[1].index));for(const[a,c,u]of o)if(c.index===l)return i(a,c,u)}return null}}function tb(e,t){return Q_(e,{global:!0,hasIndices:!0,lazyCompileLength:3e3,rules:{allowOrphanBackrefs:!0,asciiWordBoundaries:!0,captureGroup:!0,recursionLimit:5,singleline:!0},...t})}function nb(e={}){const t=Object.assign({target:"auto",cache:new Map},e);return t.regexConstructor||(t.regexConstructor=n=>tb(n,{target:t.target})),{createScanner(n){return new eb(n,t)},createString(n){return{content:n}}}}const sb=Object.freeze(JSON.parse('{"displayName":"JSON","name":"json","patterns":[{"include":"#value"}],"repository":{"array":{"begin":"\\\\[","beginCaptures":{"0":{"name":"punctuation.definition.array.begin.json"}},"end":"]","endCaptures":{"0":{"name":"punctuation.definition.array.end.json"}},"name":"meta.structure.array.json","patterns":[{"include":"#value"},{"match":",","name":"punctuation.separator.array.json"},{"match":"[^]\\\\s]","name":"invalid.illegal.expected-array-separator.json"}]},"comments":{"patterns":[{"begin":"/\\\\*\\\\*(?!/)","captures":{"0":{"name":"punctuation.definition.comment.json"}},"end":"\\\\*/","name":"comment.block.documentation.json"},{"begin":"/\\\\*","captures":{"0":{"name":"punctuation.definition.comment.json"}},"end":"\\\\*/","name":"comment.block.json"},{"captures":{"1":{"name":"punctuation.definition.comment.json"}},"match":"(//).*$\\\\n?","name":"comment.line.double-slash.js"}]},"constant":{"match":"\\\\b(?:true|false|null)\\\\b","name":"constant.language.json"},"number":{"match":"-?(?:0|[1-9]\\\\d*)(?:(?:\\\\.\\\\d+)?(?:[Ee][-+]?\\\\d+)?)?","name":"constant.numeric.json"},"object":{"begin":"\\\\{","beginCaptures":{"0":{"name":"punctuation.definition.dictionary.begin.json"}},"end":"}","endCaptures":{"0":{"name":"punctuation.definition.dictionary.end.json"}},"name":"meta.structure.dictionary.json","patterns":[{"include":"#objectkey"},{"include":"#comments"},{"begin":":","beginCaptures":{"0":{"name":"punctuation.separator.dictionary.key-value.json"}},"end":"(,)|(?=})","endCaptures":{"1":{"name":"punctuation.separator.dictionary.pair.json"}},"name":"meta.structure.dictionary.value.json","patterns":[{"include":"#value"},{"match":"[^,\\\\s]","name":"invalid.illegal.expected-dictionary-separator.json"}]},{"match":"[^}\\\\s]","name":"invalid.illegal.expected-dictionary-separator.json"}]},"objectkey":{"begin":"\\"","beginCaptures":{"0":{"name":"punctuation.support.type.property-name.begin.json"}},"end":"\\"","endCaptures":{"0":{"name":"punctuation.support.type.property-name.end.json"}},"name":"string.json support.type.property-name.json","patterns":[{"include":"#stringcontent"}]},"string":{"begin":"\\"","beginCaptures":{"0":{"name":"punctuation.definition.string.begin.json"}},"end":"\\"","endCaptures":{"0":{"name":"punctuation.definition.string.end.json"}},"name":"string.quoted.double.json","patterns":[{"include":"#stringcontent"}]},"stringcontent":{"patterns":[{"match":"\\\\\\\\(?:[\\"/\\\\\\\\bfnrt]|u\\\\h{4})","name":"constant.character.escape.json"},{"match":"\\\\\\\\.","name":"invalid.illegal.unrecognized-string-escape.json"}]},"value":{"patterns":[{"include":"#constant"},{"include":"#number"},{"include":"#string"},{"include":"#array"},{"include":"#object"},{"include":"#comments"}]}},"scopeName":"source.json"}')),rb=[sb],oi=fe(null),Zu=fe(!1);let Ks=null;const ob={name:"prsm-devtools",type:"dark",bg:"transparent",fg:"#d4d4d4",settings:[{scope:["string"],settings:{foreground:"#a5d6a7"}},{scope:["constant.numeric"],settings:{foreground:"#4dd0e1"}},{scope:["constant.language.boolean","constant.language"],settings:{foreground:"#ce93d8"}},{scope:["constant.language.null"],settings:{foreground:"#666666"}},{scope:["support.type.property-name"],settings:{foreground:"#b0b0b0"}},{scope:["punctuation"],settings:{foreground:"#555555"}}]};function ib(){return Ks||(Ks=mv({themes:[ob],langs:[rb],engine:nb()}).then(e=>(oi.value=e,Zu.value=!0,e)),Ks)}function lb(){kt(ib);function e(t){const n=typeof t=="string"?t:JSON.stringify(t,null,2);return n?oi.value?oi.value.codeToHtml(n,{lang:"json",theme:"prsm-devtools"}):ab(n):""}return{highlight:e,ready:Zu}}function ab(e){return e.replace(/&/g,"&amp;").replace(/</g,"&lt;").replace(/>/g,"&gt;")}const cb=["innerHTML"],yt={__name:"JsonView",props:{data:{default:null}},setup(e){const t=e,{highlight:n}=lb(),s=de(()=>t.data===null||t.data===void 0?'<span style="color: var(--syn-null)">null</span>':n(t.data));return(r,o)=>(C(),S("div",{class:"json-view",innerHTML:s.value},null,8,cb))}},ub={key:0,class:"limiter-list"},fb={key:1,class:"empty",style:{"text-align":"left",padding:"0"}},db={key:2},hb=["value"],pb=["disabled"],gb={key:0,class:"card",style:{"margin-top":"12px"}},mb={class:"card-body"},yb={key:1,class:"error"},vb={__name:"Limits",setup(e){const t=fe([]),n=fe(""),s=fe(""),r=fe(null),o=fe(null);kt(async()=>{const l=await fetch(Xe("/limits"));if(l.ok){const a=await l.json();t.value=a.limiters,a.limiters.length&&(n.value=a.limiters[0])}});async function i(){if(!n.value||!s.value)return;o.value=null,r.value=null;const l=await fetch(Xe(`/limits/${n.value}/peek/${encodeURIComponent(s.value)}`));if(l.ok)r.value=await l.json();else{const a=await l.json();o.value=a.error}}return(l,a)=>(C(),S("div",null,[a[4]||(a[4]=p("div",{class:"section-title"},"registered limiters",-1)),t.value.length?(C(),S("div",ub,[(C(!0),S(Z,null,he(t.value,c=>(C(),S("div",{key:c,class:"tag accent",style:{padding:"6px 14px","font-size":"11px"}},N(c),1))),128))])):(C(),S("p",fb,"no limiters registered")),t.value.length?(C(),S("section",db,[a[2]||(a[2]=p("div",{class:"section-title"},"peek",-1)),a[3]||(a[3]=p("p",{class:"desc"},"inspect a key without consuming",-1)),p("form",{onSubmit:as(i,["prevent"]),class:"peek-form"},[ir(p("select",{"onUpdate:modelValue":a[0]||(a[0]=c=>n.value=c),class:"select"},[(C(!0),S(Z,null,he(t.value,c=>(C(),S("option",{key:c,value:c},N(c),9,hb))),128))],512),[[Do,n.value]]),ir(p("input",{"onUpdate:modelValue":a[1]||(a[1]=c=>s.value=c),placeholder:"key",class:"input"},null,512),[[kh,s.value]]),p("button",{type:"submit",disabled:!s.value,class:"btn"},"peek",8,pb)],32),r.value?(C(),S("div",gb,[p("div",mb,[_e(yt,{data:r.value},null,8,["data"])])])):ie("",!0),o.value?(C(),S("p",yb,N(o.value),1)):ie("",!0)])):ie("",!0)]))}},_b=dn(vb,[["__scopeId","data-v-22c855ec"]]),bb={class:"graph-controls"},wb=["viewBox"],Cb=["d"],xb=["x","y"],kb=["onClick"],Sb=["x","y","width","height"],Eb=["x","y"],Ab=["x","y"],Rb=["x","y"],$b=["x","y"],Ib={__name:"WorkflowGraph",props:{graph:{type:Object,required:!0},execution:{type:Object,default:null},selectedStep:{type:String,default:null}},emits:["select-step"],setup(e,{emit:t}){const n=e,s=t,r=fe(null),o=fe(!1),i=fe(0),l=fe(0),a=fe(1);let c=!1,u=!1,f=0,d=0;function h(q){q.preventDefault();const re=q.deltaY>0?.96:1.04,L=Math.min(3,Math.max(.3,a.value*re)),pe=r.value.getBoundingClientRect(),oe=q.clientX-pe.left,Ee=q.clientY-pe.top;i.value=oe-(oe-i.value)*(L/a.value),l.value=Ee-(Ee-l.value)*(L/a.value),a.value=L}function m(q){q.button===0&&(c=!0,u=!1,f=q.clientX,d=q.clientY)}function v(q){if(!c)return;const re=q.clientX-f,L=q.clientY-d;(re!==0||L!==0)&&(u=!0),i.value+=re,l.value+=L,f=q.clientX,d=q.clientY}function x(){c=!1}function k(q){u||s("select-step",q)}function E(){i.value=0,l.value=0,a.value=1}function b(){o.value=!o.value,E()}function R(q){q.key==="Escape"&&o.value&&(o.value=!1,E())}kt(()=>window.addEventListener("keydown",R)),fn(()=>window.removeEventListener("keydown",R));function U(q){const re=(q==null?void 0:q.nodes)??[],L=(q==null?void 0:q.edges)??[],pe=new Map(re.map(J=>[J.name,0])),oe=new Map(re.map(J=>[J.name,[]]));for(const J of L)pe.has(J.to)&&pe.set(J.to,pe.get(J.to)+1),oe.has(J.from)&&oe.get(J.from).push(J);const Ee=[q.start],ge=new Map([[q.start,0]]);for(;Ee.length;){const J=Ee.shift();for(const A of oe.get(J)??[]){const F=(ge.get(J)??0)+1;(!ge.has(A.to)||F>ge.get(A.to))&&ge.set(A.to,F),pe.set(A.to,Math.max(0,(pe.get(A.to)??0)-1)),pe.get(A.to)===0&&Ee.push(A.to)}}const ae=[];for(const J of re){const A=ge.get(J.name)??0;ae[A]=ae[A]??[],ae[A].push(J)}const le=[],it=220,lt=92,at=90,Ge=34,pt=32;for(let J=0;J<ae.length;J++){const A=ae[J]??[];A.sort((j,z)=>j.name.localeCompare(z.name));const F=A.length*lt+Math.max(0,A.length-1)*Ge;for(let j=0;j<A.length;j++){const z=A[j];le.push({...z,x:pt+J*(it+at),y:pt+j*(lt+Ge)+Math.max(0,(380-F)/2),width:it,height:lt})}}const Dt=new Map(le.map(J=>[J.name,J])),Gt=L.map(J=>{const A=Dt.get(J.from),F=Dt.get(J.to);return!A||!F?null:{...J,x1:A.x+A.width,y1:A.y+A.height/2,x2:F.x,y2:F.y+F.height/2,mx:(A.x+A.width+F.x)/2,my:(A.y+A.height/2+F.y+F.height/2)/2}}).filter(Boolean);return{nodes:le,edges:Gt,width:Math.max(760,...le.map(J=>J.x+J.width+pt)),height:Math.max(420,...le.map(J=>J.y+J.height+pt))}}const I=de(()=>U(n.graph));function w(q){var re,L;return((L=(re=n.execution)==null?void 0:re.steps)==null?void 0:L[q])??null}function W(q,re){var pe,oe;const L=w(q);return((pe=n.execution)==null?void 0:pe.currentStep)===q&&n.execution.status==="running"?"running":(L==null?void 0:L.status)==="succeeded"?re==="decision"?"decision-success":"succeeded":(L==null?void 0:L.status)==="failed"?"failed":((oe=n.execution)==null?void 0:oe.currentStep)===q?"current":"idle"}function Q(q){var L;if(!n.execution)return"edge";const re=w(q.from);return re!=null&&re.route&&re.route===q.label?"edge edge-active":((L=w(q.from))==null?void 0:L.status)==="succeeded"&&w(q.to)?"edge edge-seen":"edge"}return(q,re)=>(C(),S("div",{ref_key:"container",ref:r,class:Ae(["graph-shell",{fullscreen:o.value}]),onWheel:as(h,["prevent"]),onPointerdown:m,onPointermove:v,onPointerup:x},[p("div",bb,[p("button",{onClick:as(E,["stop"]),title:"reset view"},"1:1"),p("button",{onClick:as(b,["stop"]),title:"fullscreen"},N(o.value?"exit":"expand"),1)]),(C(),S("svg",{viewBox:`0 0 ${I.value.width} ${I.value.height}`,class:"graph",style:Sn({transform:`translate(${i.value}px, ${l.value}px) scale(${a.value})`,transformOrigin:"0 0"})},[p("g",null,[(C(!0),S(Z,null,he(I.value.edges,L=>(C(),S("path",{key:`${L.from}:${L.to}:${L.label}`,d:`M ${L.x1} ${L.y1} C ${(L.x1+L.x2)/2} ${L.y1}, ${(L.x1+L.x2)/2} ${L.y2}, ${L.x2} ${L.y2}`,class:Ae(Q(L))},null,10,Cb))),128)),(C(!0),S(Z,null,he(I.value.edges,L=>(C(),S("text",{key:`${L.from}:${L.to}:${L.label}:label`,x:L.mx,y:L.my-8,class:"edge-label","text-anchor":"middle"},N(L.label),9,xb))),128))]),(C(!0),S(Z,null,he(I.value.nodes,L=>{var pe,oe;return C(),S("g",{key:L.name,class:Ae(["node",[L.type,W(L.name,L.type),{selected:e.selectedStep===L.name}]]),onClick:as(Ee=>k(L.name),["stop"])},[p("rect",{x:L.x,y:L.y,width:L.width,height:L.height,rx:"10"},null,8,Sb),p("text",{x:L.x+16,y:L.y+28,class:"node-name"},N(L.label||L.name),9,Eb),p("text",{x:L.x+16,y:L.y+50,class:"node-type"},N(L.type),9,Ab),(pe=w(L.name))!=null&&pe.attempts?(C(),S("text",{key:0,x:L.x+16,y:L.y+72,class:"node-meta"}," attempts "+N(w(L.name).attempts),9,Rb)):((oe=L.retry)==null?void 0:oe.maxAttempts)>1?(C(),S("text",{key:1,x:L.x+16,y:L.y+72,class:"node-meta"}," retries "+N(L.retry.maxAttempts),9,$b)):ie("",!0)],10,kb)}),128))],12,wb))],34))}},ef=dn(Ib,[["__scopeId","data-v-6098c89d"]]),Nb={key:0,class:"empty",style:{"text-align":"left",padding:"0"}},Pb={key:1,class:"empty",style:{"text-align":"left",padding:"0"}},Ob={key:2,class:"workflow-layout"},Tb={class:"wf-sidebar"},Mb=["onClick"],Lb={class:"card-header"},Db={class:"name"},Gb={class:"badge"},jb={class:"card-body"},Fb={class:"kv-row"},Bb={class:"kv-value"},Ub={class:"kv-row"},Hb={class:"kv-value"},Wb={key:0,class:"detail"},Vb={class:"headline"},qb={class:"headline-name"},zb={class:"headline-sub"},Kb={class:"headline-stats"},Xb={key:0,class:"card"},Jb={class:"card-header"},Yb={class:"name"},Qb={class:"card-body"},Zb={class:"kv-row"},ew={class:"kv-value"},tw={class:"kv-row"},nw={class:"kv-value"},sw={class:"kv-row"},rw={class:"kv-value"},ow={key:0,style:{"margin-top":"8px",color:"#666","font-size":"11px"}},iw={__name:"Workflows",setup(e){const t=Ur(),n=Ei(),s=fe([]),r=fe(""),o=fe(""),i=fe(null);async function l(){const u=await fetch(Xe("/workflows"));if(!u.ok){i.value="failed to load workflows";return}const f=await u.json();s.value=f.workflows;const d=typeof t.query.workflow=="string"?t.query.workflow:"",h=s.value[0]?`${s.value[0].name}@${s.value[0].version}`:"";r.value=s.value.some(m=>`${m.name}@${m.version}`===d)?d:h}kt(l),vt(r,u=>{var d;if(!u)return;n.replace({query:{workflow:u}});const f=(d=a.value)==null?void 0:d.graph;o.value=(f==null?void 0:f.start)??""}),vt(()=>t.query.workflow,u=>{typeof u=="string"&&u!==r.value&&(r.value=u)});const a=de(()=>s.value.find(u=>`${u.name}@${u.version}`===r.value)??null),c=de(()=>{var u,f,d;return((d=(f=(u=a.value)==null?void 0:u.graph)==null?void 0:f.nodes)==null?void 0:d.find(h=>h.name===o.value))??null});return(u,f)=>{var d;return C(),S("div",null,[f[6]||(f[6]=p("div",{class:"section-title"},"workflows",-1)),i.value?(C(),S("div",Nb,N(i.value),1)):s.value.length?(C(),S("div",Ob,[p("aside",Tb,[(C(!0),S(Z,null,he(s.value,h=>(C(),S("div",{key:`${h.name}@${h.version}`,class:Ae(["card",{active:`${h.name}@${h.version}`===r.value}]),style:{cursor:"pointer"},onClick:m=>r.value=`${h.name}@${h.version}`},[p("div",Lb,[p("span",Db,N(h.name),1),p("span",Gb,"v"+N(h.version),1)]),p("div",jb,[p("div",Fb,[f[1]||(f[1]=p("span",{class:"kv-key"},"steps",-1)),p("span",Bb,N(h.graph.nodes.length),1)]),p("div",Ub,[f[2]||(f[2]=p("span",{class:"kv-key"},"start",-1)),p("span",Hb,N(h.graph.start),1)])])],10,Mb))),128))]),a.value?(C(),S("section",Wb,[p("div",Vb,[p("div",null,[p("div",qb,N(a.value.name),1),p("div",zb,"version "+N(a.value.version),1)]),p("div",Kb,[p("span",null,N(a.value.graph.nodes.length)+" steps",1),p("span",null,N(a.value.graph.edges.length)+" edges",1)])]),_e(ef,{graph:a.value.graph,"selected-step":o.value,onSelectStep:f[0]||(f[0]=h=>o.value=h)},null,8,["graph","selected-step"]),c.value?(C(),S("div",Xb,[p("div",Jb,[p("span",Yb,N(c.value.name),1)]),p("div",Qb,[p("div",Zb,[f[3]||(f[3]=p("span",{class:"kv-key"},"type",-1)),p("span",ew,N(c.value.type),1)]),p("div",tw,[f[4]||(f[4]=p("span",{class:"kv-key"},"timeout",-1)),p("span",nw,N(c.value.timeout??"-"),1)]),p("div",sw,[f[5]||(f[5]=p("span",{class:"kv-key"},"retries",-1)),p("span",rw,N(((d=c.value.retry)==null?void 0:d.maxAttempts)??1),1)]),c.value.description?(C(),S("p",ow,N(c.value.description),1)):ie("",!0)])])):ie("",!0)])):ie("",!0)])):(C(),S("div",Pb,"no workflows registered"))])}}},lw=dn(iw,[["__scopeId","data-v-124a0c49"]]),aw={class:"filters"},cw=["value"],uw={key:0,class:"headline"},fw={class:"headline-name"},dw={class:"headline-sub"},hw={class:"execution-layout"},pw={class:"list"},gw=["onClick"],mw={class:"execution-main"},yw={class:"execution-workflow"},vw={class:"execution-id"},_w={class:"execution-meta"},bw={key:0,class:"empty"},ww={key:0,class:"center"},Cw={key:0,class:"card"},xw={class:"card-body"},kw={key:1,class:"card"},Sw={class:"card-body"},Ew={key:2,class:"card"},Aw={class:"card-body"},Rw={key:1,class:"inspector"},$w={class:"card"},Iw={class:"card-body"},Nw={class:"kv-row"},Pw={class:"kv-value"},Ow={class:"kv-row"},Tw={class:"kv-value"},Mw={class:"kv-row"},Lw={class:"kv-value"},Dw={class:"kv-row"},Gw={class:"kv-value"},jw={key:0,class:"card"},Fw={class:"card-header"},Bw={class:"name"},Uw={class:"card-body"},Hw={class:"kv-row"},Ww={class:"kv-value"},Vw={class:"kv-row"},qw={class:"kv-value"},zw={key:0,class:"kv-row"},Kw={class:"kv-value"},Xw={key:1,class:"kv-row"},Jw={class:"kv-value"},Yw={key:2,class:"kv-row"},Qw={class:"kv-value"},Zw={key:3,style:{"margin-top":"8px"}},e0={key:4,style:{"margin-top":"8px"}},t0={class:"card"},n0={class:"card-body",style:{padding:"0"}},s0={class:"timeline"},r0={class:"timeline-type"},o0={class:"timeline-step"},i0={class:"timeline-time"},l0={__name:"WorkflowExecutions",setup(e){const t=Ur(),n=Ei(),s=Hr(),r=fe([]),o=fe([]),i=fe(""),l=fe(null),a=fe(""),c=fe(typeof t.query.status=="string"?t.query.status:""),u=fe(typeof t.query.workflow=="string"?t.query.workflow:"");let f=null;async function d(){const I=await fetch(Xe("/workflows"));if(!I.ok)return;const w=await I.json();r.value=w.workflows}async function h(){var Q;const I=new URLSearchParams;c.value&&I.set("status",c.value),u.value&&I.set("workflow",u.value),I.set("limit","100");const w=await fetch(Xe(`/workflow/executions?${I.toString()}`));if(!w.ok)return;const W=await w.json();o.value=W.executions,!i.value&&o.value[0]&&(i.value=o.value[0].id),i.value&&!o.value.some(q=>q.id===i.value)&&(i.value=((Q=o.value[0])==null?void 0:Q.id)??"")}async function m(I){if(!I){l.value=null;return}const w=await fetch(Xe(`/workflow/executions/${I}`));if(!w.ok)return;const W=await w.json();l.value=W.execution,(!a.value||!W.execution.steps[a.value])&&(a.value=W.execution.currentStep||Object.keys(W.execution.steps)[0]||"")}function v(I){if(!I)return"-";const w=Date.now()-I;return w<1e3?"now":w<6e4?`${Math.floor(w/1e3)}s ago`:w<36e5?`${Math.floor(w/6e4)}m ago`:`${Math.floor(w/36e5)}h ago`}function x(I){return(I==null?void 0:I.slice(0,8))??""}function k(){const I={};u.value&&(I.workflow=u.value),c.value&&(I.status=c.value),i.value&&(I.execution=i.value),n.replace({query:I})}kt(async()=>{await d(),await h(),i.value=typeof t.query.execution=="string"?t.query.execution:i.value,await m(i.value),f=setInterval(async()=>{await h(),i.value&&await m(i.value)},2e3)}),fn(()=>{f&&clearInterval(f)}),vt([c,u],async()=>{k(),await h(),i.value&&await m(i.value)}),vt(i,async I=>{k(),await m(I)}),vt(()=>s.value[0],async I=>{var w;(w=I==null?void 0:I.type)!=null&&w.startsWith("workflow:")&&(await h(),i.value&&await m(i.value))});const E=de(()=>l.value?r.value.find(I=>I.name===l.value.workflow&&I.version===l.value.workflowVersion)??null:null);vt([l,E],([I,w])=>{!I||!w||a.value&&I.steps[a.value]||(a.value=I.currentStep||Object.keys(I.steps)[0]||w.graph.start)});const b=de(()=>{var I,w;return((w=(I=l.value)==null?void 0:I.steps)==null?void 0:w[a.value])??null}),R=de(()=>{var I;return(((I=l.value)==null?void 0:I.journal)??[]).slice().sort((w,W)=>W.at-w.at)}),U=de(()=>r.value.map(I=>I.name));return(I,w)=>(C(),S("div",null,[w[22]||(w[22]=p("div",{class:"section-title"},"workflow executions",-1)),p("div",aw,[ir(p("select",{"onUpdate:modelValue":w[0]||(w[0]=W=>u.value=W),class:"select"},[w[3]||(w[3]=p("option",{value:""},"all workflows",-1)),(C(!0),S(Z,null,he(U.value,W=>(C(),S("option",{key:W,value:W},N(W),9,cw))),128))],512),[[Do,u.value]]),ir(p("select",{"onUpdate:modelValue":w[1]||(w[1]=W=>c.value=W),class:"select"},[...w[4]||(w[4]=[Wd('<option value="" data-v-24631062>all statuses</option><option value="queued" data-v-24631062>queued</option><option value="waiting" data-v-24631062>waiting</option><option value="running" data-v-24631062>running</option><option value="succeeded" data-v-24631062>succeeded</option><option value="failed" data-v-24631062>failed</option><option value="canceled" data-v-24631062>canceled</option>',7)])],512),[[Do,c.value]])]),l.value?(C(),S("div",uw,[p("div",fw,N(l.value.workflow),1),p("div",dw,N(l.value.status)+" - "+N(l.value.id),1)])):ie("",!0),p("div",hw,[p("aside",pw,[(C(!0),S(Z,null,he(o.value,W=>(C(),S("div",{key:W.id,class:Ae(["execution-row",[W.status,{active:W.id===i.value}]]),onClick:Q=>i.value=W.id},[p("div",mw,[p("span",yw,N(W.workflow),1),p("span",vw,N(x(W.id)),1)]),p("div",_w,[p("span",null,N(W.status),1),p("span",null,N(W.currentStep||"-"),1),p("span",null,N(v(W.updatedAt)),1)])],10,gw))),128)),o.value.length?ie("",!0):(C(),S("p",bw,"no executions"))]),l.value&&E.value?(C(),S("section",ww,[_e(ef,{graph:E.value.graph,execution:l.value,"selected-step":a.value,onSelectStep:w[2]||(w[2]=W=>a.value=W)},null,8,["graph","execution","selected-step"]),l.value.input!=null?(C(),S("div",Cw,[w[5]||(w[5]=p("div",{class:"card-header"},[p("span",{class:"name"},"input")],-1)),p("div",xw,[_e(yt,{data:l.value.input},null,8,["data"])])])):ie("",!0),l.value.output!=null?(C(),S("div",kw,[w[6]||(w[6]=p("div",{class:"card-header"},[p("span",{class:"name"},"output")],-1)),p("div",Sw,[_e(yt,{data:l.value.output},null,8,["data"])])])):ie("",!0),l.value.error?(C(),S("div",Ew,[w[7]||(w[7]=p("div",{class:"card-header"},[p("span",{class:"name",style:{color:"var(--color-red)"}},"error")],-1)),p("div",Aw,[_e(yt,{data:l.value.error},null,8,["data"])])])):ie("",!0)])):ie("",!0),l.value&&E.value?(C(),S("aside",Rw,[p("div",$w,[w[12]||(w[12]=p("div",{class:"card-header"},[p("span",{class:"name"},"execution")],-1)),p("div",Iw,[p("div",Nw,[w[8]||(w[8]=p("span",{class:"kv-key"},"status",-1)),p("span",Pw,N(l.value.status),1)]),p("div",Ow,[w[9]||(w[9]=p("span",{class:"kv-key"},"current",-1)),p("span",Tw,N(l.value.currentStep||"terminal"),1)]),p("div",Mw,[w[10]||(w[10]=p("span",{class:"kv-key"},"created",-1)),p("span",Lw,N(new Date(l.value.createdAt).toLocaleString()),1)]),p("div",Dw,[w[11]||(w[11]=p("span",{class:"kv-key"},"updated",-1)),p("span",Gw,N(new Date(l.value.updatedAt).toLocaleString()),1)])])]),b.value?(C(),S("div",jw,[p("div",Fw,[p("span",Bw,"step: "+N(a.value),1)]),p("div",Uw,[w[20]||(w[20]=p("p",{class:"step-hint"},"click a node in the graph to inspect",-1)),p("div",Hw,[w[13]||(w[13]=p("span",{class:"kv-key"},"status",-1)),p("span",Ww,N(b.value.status),1)]),p("div",Vw,[w[14]||(w[14]=p("span",{class:"kv-key"},"attempts",-1)),p("span",qw,N(b.value.attempts),1)]),b.value.route?(C(),S("div",zw,[w[15]||(w[15]=p("span",{class:"kv-key"},"route",-1)),p("span",Kw,N(b.value.route),1)])):ie("",!0),b.value.startedAt?(C(),S("div",Xw,[w[16]||(w[16]=p("span",{class:"kv-key"},"started",-1)),p("span",Jw,N(new Date(b.value.startedAt).toLocaleTimeString()),1)])):ie("",!0),b.value.endedAt?(C(),S("div",Yw,[w[17]||(w[17]=p("span",{class:"kv-key"},"ended",-1)),p("span",Qw,N(new Date(b.value.endedAt).toLocaleTimeString()),1)])):ie("",!0),b.value.output!=null&&b.value.output!==b.value.route?(C(),S("div",Zw,[w[18]||(w[18]=p("div",{class:"section-title"},"output",-1)),_e(yt,{data:b.value.output},null,8,["data"])])):ie("",!0),b.value.error?(C(),S("div",e0,[w[19]||(w[19]=p("div",{class:"section-title",style:{color:"var(--color-red)"}},"error",-1)),_e(yt,{data:b.value.error},null,8,["data"])])):ie("",!0)])])):ie("",!0),p("div",t0,[w[21]||(w[21]=p("div",{class:"card-header"},[p("span",{class:"name"},"journal")],-1)),p("div",n0,[p("div",s0,[(C(!0),S(Z,null,he(R.value,(W,Q)=>(C(),S("div",{key:Q,class:"timeline-row"},[p("span",r0,N(W.type),1),p("span",o0,N(W.step||W.route||"-"),1),p("span",i0,N(new Date(W.at).toLocaleTimeString()),1)]))),128))])])])])):ie("",!0)])]))}},a0=dn(l0,[["__scopeId","data-v-24631062"]]);function c0(e=1e3){const t=fe(null),n=fe(null),s=fe(null),r=fe(null),o=Yn({});let i=null,l=null;async function a(){try{const v=await fetch(Xe("/realtime/state"));if(!v.ok)throw new Error(`${v.status}`);t.value=await v.json(),r.value=null}catch(v){r.value=v.message}}async function c(v){try{const x=await fetch(Xe(`/realtime/connection/${v}`));if(!x.ok)throw new Error(`${x.status}`);n.value=await x.json()}catch{}}async function u(v){try{const x=await fetch(Xe(`/realtime/record/${encodeURIComponent(v)}`));if(!x.ok)throw new Error(`${x.status}`);const k=await x.json();o[v]=k.data}catch{o[v]=null}}function f(v){delete o[v]}async function d(v,x){try{const k=await fetch(Xe(`/realtime/collection/${encodeURIComponent(v)}/records?connId=${encodeURIComponent(x)}`));if(!k.ok)throw new Error(`${k.status}`);return await k.json()}catch{return{recordIds:[],records:[]}}}async function h(v){s.value=v,v?await c(v):n.value=null}async function m(){await a(),s.value&&await c(s.value)}return kt(()=>{m(),i=setInterval(m,e),l=new EventSource(Xe("/events")),l.addEventListener("realtime:record:update",v=>{const{recordId:x,data:k}=JSON.parse(v.data);x in o&&(o[x]=k)}),l.addEventListener("realtime:record:removed",v=>{const{recordId:x}=JSON.parse(v.data);x in o&&(o[x]=null)})}),fn(()=>{i&&clearInterval(i),l&&l.close()}),{state:t,connectionDetail:n,selectedConnectionId:s,error:r,selectConnection:h,watchedRecords:o,watchRecord:u,unwatchRecord:f,fetchCollectionRecords:d}}const u0={class:"sidebar-section"},f0={key:0,class:"badge"},d0=["onClick"],h0=["title"],p0={key:0,class:"meta"},g0={__name:"ConnectionPicker",props:{connections:{type:Array,default:()=>[]},selectedId:{type:String,default:null}},emits:["select"],setup(e){return(t,n)=>(C(),S("div",u0,[n[2]||(n[2]=p("div",{class:"sidebar-header"},"connections",-1)),p("div",{class:Ae(["sidebar-item",{active:!e.selectedId}]),onClick:n[0]||(n[0]=s=>t.$emit("select",null))},[n[1]||(n[1]=p("span",{class:"label"},"all connections",-1)),e.connections.length?(C(),S("span",f0,N(e.connections.length),1)):ie("",!0)],2),(C(!0),S(Z,null,he(e.connections,s=>(C(),S("div",{key:s.id,class:Ae(["sidebar-item",{active:e.selectedId===s.id}]),onClick:r=>t.$emit("select",s.id)},[p("span",{class:"label",title:s.id},N(s.id.slice(0,8)),9,h0),s.latency!==null?(C(),S("span",p0,N(s.latency)+"ms",1)):ie("",!0)],10,d0))),128))]))}},m0={class:"realtime-shell"},y0={class:"tab-bar"},v0={key:0,class:"count"},_0={class:"tab-bar-right"},b0={key:0,class:"instance-id"},w0={class:"rt-main"},C0={class:"sidebar"},x0={key:0,class:"sidebar-section"},k0={style:{float:"right","font-size":"9px"}},S0={class:"exposed-label"},E0={class:"content"},A0={__name:"Realtime",setup(e){const t=Ur(),n=Ei(),s=fe(!0),r={channels:"channels",records:"records",writableRecords:"writable",collections:"collections",presence:"presence",commands:"commands"};function o(I){return r[I]||I}function i(I){f(I),n.push("/realtime/metadata")}const{state:l,connectionDetail:a,selectedConnectionId:c,error:u,selectConnection:f,watchedRecords:d,watchRecord:h,unwatchRecord:m,fetchCollectionRecords:v}=c0(),x=de(()=>{var I;return(I=l.value)!=null&&I.rooms?c.value?l.value.rooms.filter(w=>w.members.includes(c.value)):l.value.rooms:[]}),k=de(()=>{var w;if(!((w=l.value)!=null&&w.channels))return{};if(!c.value)return l.value.channels;const I={};for(const[W,Q]of Object.entries(l.value.channels))Q.includes(c.value)&&(I[W]=Q);return I}),E=de(()=>{var w;if(!((w=l.value)!=null&&w.collections))return{};if(!c.value)return l.value.collections;const I={};for(const[W,Q]of Object.entries(l.value.collections))Q.subscribers[c.value]&&(I[W]=Q);return I}),b=de(()=>{var w;if(!((w=l.value)!=null&&w.records))return{};if(!c.value)return l.value.records;const I={};for(const[W,Q]of Object.entries(l.value.records))Q.subscribers[c.value]&&(I[W]=Q);return I}),R=de(()=>{var w;if(!((w=l.value)!=null&&w.exposed))return{};const I={};for(const[W,Q]of Object.entries(l.value.exposed))Q.length&&(I[W]=Q);return I}),U=de(()=>[{id:"rooms",label:"rooms",count:x.value.length},{id:"channels",label:"channels",count:Object.keys(k.value).length},{id:"collections",label:"collections",count:Object.keys(E.value).length},{id:"records",label:"records",count:Object.keys(b.value).length},{id:"metadata",label:"metadata"}]);return(I,w)=>{var q,re,L,pe;const W=ar("router-link"),Q=ar("router-view");return C(),S("div",m0,[p("div",y0,[(C(!0),S(Z,null,he(U.value,oe=>(C(),fr(W,{key:oe.id,to:`/realtime/${oe.id}`,class:Ae(["tab",{active:Ie(t).path===`/realtime/${oe.id}`}])},{default:_i(()=>[hr(N(oe.label),1),oe.count!==void 0?(C(),S("span",v0,N(oe.count),1)):ie("",!0)]),_:2},1032,["to","class"]))),128)),p("div",_0,[p("span",{class:Ae(["pulse",{disconnected:!!Ie(u)}])},null,2),Ie(l)?(C(),S("span",b0,"instance "+N((q=Ie(l).instanceId)==null?void 0:q.slice(0,8)),1)):ie("",!0)])]),p("div",w0,[p("div",C0,[_e(g0,{connections:((re=Ie(l))==null?void 0:re.connections)||[],"selected-id":Ie(c),onSelect:Ie(f)},null,8,["connections","selected-id","onSelect"]),(L=Ie(l))!=null&&L.exposed?(C(),S("div",x0,[p("div",{class:"sidebar-header",style:{cursor:"pointer","user-select":"none"},onClick:w[0]||(w[0]=oe=>s.value=!s.value)},[w[1]||(w[1]=p("span",null,"registered",-1)),p("span",k0,N(s.value?"-":"+"),1)]),s.value?(C(!0),S(Z,{key:0},he(R.value,(oe,Ee)=>(C(),S("div",{key:Ee,class:"exposed-row"},[p("span",S0,N(o(Ee)),1),(C(!0),S(Z,null,he(oe,ge=>(C(),S("span",{class:"tag",key:ge},N(ge),1))),128))]))),128)):ie("",!0)])):ie("",!0)]),p("div",E0,[_e(Q,{rooms:x.value,channels:k.value,collections:E.value,records:b.value,detail:Ie(a),connections:((pe=Ie(l))==null?void 0:pe.connections)||[],"fetch-records":Ie(v),"watched-records":Ie(d),"watch-record":Ie(h),"unwatch-record":Ie(m),onNavigate:i},null,8,["rooms","channels","collections","records","detail","connections","fetch-records","watched-records","watch-record","unwatch-record"])])])])}}},R0=dn(A0,[["__scopeId","data-v-d6b8bed2"]]),$0={key:0,class:"empty"},I0={class:"card-header"},N0={class:"name"},P0={class:"badge accent"},O0=["title","onClick"],T0={key:0,class:"member-presence"},M0={key:1,class:"no-presence"},L0={__name:"RoomsView",props:{rooms:{type:Array,default:()=>[]}},emits:["navigate"],setup(e){function t(n){if(typeof n=="string")return n;if(typeof n=="object"&&n!==null){const s=Object.keys(n);return s.length<=3?s.map(r=>`${r}: ${JSON.stringify(n[r])}`).join(", "):`{${s.length} fields}`}return String(n)}return(n,s)=>e.rooms.length?(C(),S(Z,{key:1},[s[0]||(s[0]=p("div",{class:"view-hint"},"active rooms, their members, and each member's presence state",-1)),(C(!0),S(Z,null,he(e.rooms,r=>(C(),S("div",{key:r.name,class:"card"},[p("div",I0,[p("span",N0,N(r.name),1),p("span",P0,N(r.members.length)+" "+N(r.members.length===1?"member":"members"),1)]),(C(!0),S(Z,null,he(r.members,o=>(C(),S("div",{key:o,class:"member-row"},[p("span",{class:"member-id conn-link",title:o,onClick:i=>n.$emit("navigate",o)},N(o.slice(0,8)),9,O0),r.presence[o]?(C(),S("span",T0,N(t(r.presence[o])),1)):(C(),S("span",M0,"no presence"))]))),128))]))),128))],64)):(C(),S("div",$0,"no rooms"))}},D0={key:0,class:"empty"},G0={class:"card-header"},j0={class:"name"},F0={class:"badge accent"},B0=["title","onClick"],U0={__name:"ChannelsView",props:{channels:{type:Object,default:()=>({})}},emits:["navigate"],setup(e){const t=e,n=de(()=>Object.entries(t.channels));return(s,r)=>n.value.length?(C(),S(Z,{key:1},[r[0]||(r[0]=p("div",{class:"view-hint"},"channels with active subscribers on this server instance",-1)),(C(!0),S(Z,null,he(n.value,([o,i])=>(C(),S("div",{key:o,class:"card"},[p("div",G0,[p("span",j0,N(o),1),p("span",F0,N(i.length)+" "+N(i.length===1?"subscriber":"subscribers"),1)]),(C(!0),S(Z,null,he(i,l=>(C(),S("div",{key:l,class:"member-row"},[p("span",{class:"member-id conn-link",title:l,onClick:a=>s.$emit("navigate",l)},N(l.slice(0,8)),9,B0)]))),128))]))),128))],64)):(C(),S("div",D0,"no channel subscriptions"))}},H0={key:0,class:"empty"},W0={class:"card-header"},V0={class:"name"},q0={class:"badge accent"},z0={class:"card-body",style:{"border-top":"1px solid var(--border-subtle)"}},K0={class:"kv-row"},X0=["title","onClick"],J0={class:"kv-value"},Y0=["onClick"],Q0={key:0,class:"card-body",style:{"border-top":"1px solid var(--border-subtle)","padding-left":"24px"}},Z0={class:"section-title"},eC={style:{"font-size":"10px",color:"var(--text-muted)","margin-bottom":"2px"}},tC={key:0,class:"empty",style:{padding:"8px"}},nC={__name:"CollectionsView",props:{collections:{type:Object,default:()=>({})},fetchRecords:{type:Function,required:!0}},emits:["navigate"],setup(e){const t=e,n=de(()=>Object.entries(t.collections)),s=Yn({});function r(i,l){return`${i}::${l}`}async function o(i,l){const a=r(i,l);if(s[a]){delete s[a];return}s[a]=await t.fetchRecords(i,l)}return(i,l)=>n.value.length?(C(),S(Z,{key:1},[l[0]||(l[0]=p("div",{class:"view-hint"},'collections with active subscribers - click "records" to see what the resolver returns for that connection',-1)),(C(!0),S(Z,null,he(n.value,([a,c])=>(C(),S("div",{key:a,class:"card"},[p("div",W0,[p("span",V0,N(a),1),p("span",q0,N(Object.keys(c.subscribers).length)+" "+N(Object.keys(c.subscribers).length===1?"subscriber":"subscribers"),1)]),(C(!0),S(Z,null,he(c.subscribers,(u,f)=>(C(),S("div",{key:f},[p("div",z0,[p("div",K0,[p("span",{class:"kv-key conn-link",title:f,onClick:d=>i.$emit("navigate",f)},N(f.slice(0,8)),9,X0),p("span",J0,"v"+N(u.version),1),p("span",{class:"tag accent",style:{"margin-left":"8px",cursor:"pointer"},onClick:d=>o(a,f)},N(s[r(a,f)]?"hide":"records"),9,Y0)])]),s[r(a,f)]?(C(),S("div",Q0,[p("div",Z0,"resolved records ("+N(s[r(a,f)].recordIds.length)+")",1),(C(!0),S(Z,null,he(s[r(a,f)].records,d=>(C(),S("div",{key:d.id,style:{"margin-bottom":"8px"}},[p("div",eC,N(d.id),1),_e(yt,{data:d.data},null,8,["data"])]))),128)),s[r(a,f)].records.length?ie("",!0):(C(),S("div",tC,"no records"))])):ie("",!0)]))),128))]))),128))],64)):(C(),S("div",H0,"no collection subscriptions"))}},sC={key:0,class:"empty"},rC={class:"card-header"},oC={class:"name"},iC=["onClick"],lC={class:"badge accent"},aC={key:0,class:"card-body",style:{"border-bottom":"1px solid var(--border-subtle)"}},cC={class:"card-body"},uC=["title","onClick"],fC={__name:"RecordsView",props:{records:{type:Object,default:()=>({})},watchedRecords:{type:Object,required:!0},watchRecord:{type:Function,required:!0},unwatchRecord:{type:Function,required:!0}},emits:["navigate"],setup(e){const t=e,n=de(()=>Object.entries(t.records));function s(r){r in t.watchedRecords?t.unwatchRecord(r):t.watchRecord(r)}return(r,o)=>n.value.length?(C(),S(Z,{key:1},[o[0]||(o[0]=p("div",{class:"view-hint"},"records being watched by at least one connection, and their subscription mode",-1)),(C(!0),S(Z,null,he(n.value,([i,l])=>(C(),S("div",{key:i,class:"card"},[p("div",rC,[p("span",oC,N(i),1),p("div",null,[p("span",{class:"tag accent",style:{cursor:"pointer","margin-right":"4px"},onClick:a=>s(i)},N(i in e.watchedRecords?"hide":"view"),9,iC),p("span",lC,N(Object.keys(l.subscribers).length)+" "+N(Object.keys(l.subscribers).length===1?"subscriber":"subscribers"),1)])]),i in e.watchedRecords?(C(),S("div",aC,[_e(yt,{data:e.watchedRecords[i]},null,8,["data"])])):ie("",!0),p("div",cC,[(C(!0),S(Z,null,he(l.subscribers,(a,c)=>(C(),S("div",{key:c,class:"kv-row"},[p("span",{class:"kv-key conn-link",title:c,onClick:u=>r.$emit("navigate",c)},N(c.slice(0,8)),9,uC),p("span",{class:Ae(["tag",a==="full"?"accent":""])},N(a),3)]))),128))])]))),128))],64)):(C(),S("div",sC,"no record subscriptions"))}},dC={key:0},hC={class:"section"},pC={class:"card"},gC={class:"card-body"},mC={class:"kv-row"},yC={class:"kv-value"},vC={class:"kv-row"},_C={class:"kv-row"},bC={class:"kv-value"},wC={class:"kv-row"},CC={key:0,class:"kv-row"},xC={class:"kv-value"},kC={class:"section"},SC={class:"card"},EC={class:"card-body"},AC={key:0,class:"section"},RC={class:"section-title"},$C={class:"pattern-list"},IC={key:1,class:"section"},NC={class:"section-title"},PC={class:"pattern-list"},OC={key:2,class:"section"},TC={class:"section-title"},MC={class:"pattern-list"},LC={key:3,class:"section"},DC={class:"section-title"},GC={class:"kv-key"},jC={class:"kv-value"},FC={key:4,class:"section"},BC={class:"card-header"},UC={class:"name"},HC={class:"card-body"},WC={key:1},VC={class:"card-header"},qC={class:"name"},zC={class:"meta",style:{"font-size":"10px"}},KC={key:0,style:{"margin-right":"8px"}},XC={key:0,class:"card-body"},JC={key:2,class:"empty"},YC={__name:"MetadataView",props:{detail:{type:Object,default:null},connections:{type:Array,default:()=>[]}},setup(e){return(t,n)=>{var s,r,o,i;return e.detail?(C(),S("div",dC,[p("div",hC,[n[5]||(n[5]=p("div",{class:"section-title"},"connection",-1)),p("div",pC,[p("div",gC,[p("div",mC,[n[0]||(n[0]=p("span",{class:"kv-key"},"id",-1)),p("span",yC,N(e.detail.id),1)]),p("div",vC,[n[1]||(n[1]=p("span",{class:"kv-key"},"local",-1)),p("span",{class:"kv-value",style:Sn({color:e.detail.local?"var(--accent)":"var(--text-muted)"})},N(e.detail.local),5)]),p("div",_C,[n[2]||(n[2]=p("span",{class:"kv-key"},"latency",-1)),p("span",bC,N(e.detail.latency!==null?e.detail.latency+"ms":"-"),1)]),p("div",wC,[n[3]||(n[3]=p("span",{class:"kv-key"},"alive",-1)),p("span",{class:"kv-value",style:Sn({color:e.detail.alive?"var(--accent)":"var(--syn-boolean)"})},N(e.detail.alive),5)]),e.detail.remoteAddress?(C(),S("div",CC,[n[4]||(n[4]=p("span",{class:"kv-key"},"address",-1)),p("span",xC,N(e.detail.remoteAddress),1)])):ie("",!0)])])]),p("div",kC,[n[6]||(n[6]=p("div",{class:"section-title"},"metadata",-1)),p("div",SC,[p("div",EC,[_e(yt,{data:e.detail.metadata},null,8,["data"])])])]),(s=e.detail.rooms)!=null&&s.length?(C(),S("div",AC,[p("div",RC,"rooms ("+N(e.detail.rooms.length)+")",1),p("div",$C,[(C(!0),S(Z,null,he(e.detail.rooms,l=>(C(),S("span",{class:"tag accent",key:l},N(l),1))),128))])])):ie("",!0),(r=e.detail.channels)!=null&&r.length?(C(),S("div",IC,[p("div",NC,"channels ("+N(e.detail.channels.length)+")",1),p("div",PC,[(C(!0),S(Z,null,he(e.detail.channels,l=>(C(),S("span",{class:"tag accent",key:l},N(l),1))),128))])])):ie("",!0),(o=e.detail.collections)!=null&&o.length?(C(),S("div",OC,[p("div",TC,"collections ("+N(e.detail.collections.length)+")",1),p("div",MC,[(C(!0),S(Z,null,he(e.detail.collections,l=>(C(),S("span",{class:"tag accent",key:l.id},N(l.id)+" v"+N(l.version),1))),128))])])):ie("",!0),(i=e.detail.records)!=null&&i.length?(C(),S("div",LC,[p("div",DC,"record subscriptions ("+N(e.detail.records.length)+")",1),(C(!0),S(Z,null,he(e.detail.records,l=>(C(),S("div",{key:l.id,class:"kv-row"},[p("span",GC,N(l.id),1),p("span",jC,N(l.mode),1)]))),128))])):ie("",!0),e.detail.presence&&Object.keys(e.detail.presence).length?(C(),S("div",FC,[n[7]||(n[7]=p("div",{class:"section-title"},"presence state",-1)),(C(!0),S(Z,null,he(e.detail.presence,(l,a)=>(C(),S("div",{key:a,class:"card"},[p("div",BC,[p("span",UC,N(a),1)]),p("div",HC,[_e(yt,{data:l},null,8,["data"])])]))),128))])):ie("",!0)])):e.connections.length?(C(),S("div",WC,[n[8]||(n[8]=p("div",{class:"section-title",style:{"margin-bottom":"12px"}},"all connections",-1)),(C(!0),S(Z,null,he(e.connections,l=>{var a,c;return C(),S("div",{key:l.id,class:"card"},[p("div",VC,[p("span",qC,N(((a=l.metadata)==null?void 0:a.name)||((c=l.metadata)==null?void 0:c.username)||l.id.slice(0,8)),1),p("span",zC,[l.latency!==null?(C(),S("span",KC,N(l.latency)+"ms",1)):ie("",!0),p("span",{style:Sn({color:l.alive?"var(--accent)":"var(--syn-boolean)"})},N(l.alive?"alive":"dead"),5)])]),l.metadata?(C(),S("div",XC,[_e(yt,{data:l.metadata},null,8,["data"])])):ie("",!0)])}),128))])):(C(),S("div",JC,"no connections"))}}},QC=Gp({history:mp(),routes:[{path:"/",component:sg},{path:"/realtime",component:R0,redirect:"/realtime/rooms",children:[{path:"rooms",component:L0},{path:"channels",component:U0},{path:"collections",component:nC},{path:"records",component:fC},{path:"metadata",component:YC}]},{path:"/queue",component:mg},{path:"/cron",component:Eg},{path:"/limits",component:_b},{path:"/workflows",component:lw},{path:"/executions",component:a0}]});$h(Vp).use(QC).mount("#app");