@redocly/openapi-language-server 0.1.10 → 0.1.12

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.
Files changed (2) hide show
  1. package/lib/index.js +20 -20
  2. package/package.json +2 -2
package/lib/index.js CHANGED
@@ -1,21 +1,21 @@
1
- var Np=Object.create;var ni=Object.defineProperty;var Op=Object.getOwnPropertyDescriptor;var Ep=Object.getOwnPropertyNames;var Mp=Object.getPrototypeOf,jp=Object.prototype.hasOwnProperty;var eu=(e=>typeof require<"u"?require:typeof Proxy<"u"?new Proxy(e,{get:(t,n)=>(typeof require<"u"?require:t)[n]}):e)(function(e){if(typeof require<"u")return require.apply(this,arguments);throw new Error('Dynamic require of "'+e+'" is not supported')});var Lp=(e,t)=>()=>(e&&(t=e(e=0)),t);var A=(e,t)=>()=>(t||e((t={exports:{}}).exports,t),t.exports),tu=(e,t)=>{for(var n in t)ni(e,n,{get:t[n],enumerable:!0})},ti=(e,t,n,r)=>{if(t&&typeof t=="object"||typeof t=="function")for(let i of Ep(t))!jp.call(e,i)&&i!==n&&ni(e,i,{get:()=>t[i],enumerable:!(r=Op(t,i))||r.enumerable});return e},rs=(e,t,n)=>(ti(e,t,"default"),n&&ti(n,t,"default")),ot=(e,t,n)=>(n=e!=null?Np(Mp(e)):{},ti(t||!e||!e.__esModule?ni(n,"default",{value:e,enumerable:!0}):n,e)),Ip=e=>ti(ni({},"__esModule",{value:!0}),e);var Ft=A(Se=>{"use strict";Object.defineProperty(Se,"__esModule",{value:!0});Se.isYAMLNode=Se.isNodesEqual=Se.newMap=Se.newSeq=Se.newItems=Se.newScalar=Se.newAnchorRef=Se.newMapping=Se.Kind=void 0;var xt;(function(e){e[e.SCALAR=0]="SCALAR",e[e.MAPPING=1]="MAPPING",e[e.MAP=2]="MAP",e[e.SEQ=3]="SEQ",e[e.ANCHOR_REF=4]="ANCHOR_REF",e[e.INCLUDE_REF=5]="INCLUDE_REF"})(xt=Se.Kind||(Se.Kind={}));function Wp(e,t,n=2){var r=t?t.endPosition:e.endPosition+1,i={key:e,value:t,nodeIndent:n,startPosition:e.startPosition,endPosition:r,kind:xt.MAPPING,parent:null,errors:[]};return i}Se.newMapping=Wp;function Hp(e,t,n,r,i=2){return{errors:[],referencesAnchor:e,value:r,nodeIndent:i,startPosition:t,endPosition:n,kind:xt.ANCHOR_REF,parent:null}}Se.newAnchorRef=Hp;function Up(e="",t=2){let n={errors:[],startPosition:-1,endPosition:-1,value:""+e,nodeIndent:t,kind:xt.SCALAR,parent:null,doubleQuoted:!1,rawValue:""+e};return typeof e!="string"&&(n.valueObject=e),n}Se.newScalar=Up;function ou(){return{errors:[],startPosition:-1,endPosition:-1,nodeIndent:2,items:[],kind:xt.SEQ,parent:null}}Se.newItems=ou;function Bp(){return ou()}Se.newSeq=Bp;function zp(e,t=2){return{errors:[],startPosition:-1,endPosition:-1,nodeIndent:t,mappings:e||[],kind:xt.MAP,parent:null}}Se.newMap=zp;function gr(e,t){if(!e||!t||e.kind!==t.kind)return!1;if(e.kind===xt.SCALAR)return e.value===t.value;if(e.kind===xt.SEQ){let n=e,r=t;if(n.items.length!==r.items.length)return!1;for(let i=0;i<n.items.length;i++){let o=n.items[i],s=r.items[i];if(!gr(o,s))return!1}return!0}if(e.kind===xt.MAP){let n=e,r=t;if(n.mappings.length!==r.mappings.length)return!1;for(let i of n.mappings){let o=i.key,s=i.value,u=r.mappings.find(c=>gr(o,c.key));if(u){if(!gr(s,u.value))return!1}else return!1}return!0}if(xt.MAPPING===e.kind){let n=e,r=t;return gr(n.key,r.key)}return!1}Se.isNodesEqual=gr;function $p(e){return e.startPosition!==void 0&&e.endPosition!==void 0&&e.kind!==void 0}Se.isYAMLNode=$p});var gn=A(Xe=>{"use strict";Object.defineProperty(Xe,"__esModule",{value:!0});Xe.isNegativeZero=Xe.repeat=Xe.extend=Xe.toArray=Xe.isObject=Xe.isNothing=void 0;function su(e){return typeof e>"u"||e===null}Xe.isNothing=su;function Yp(e){return typeof e=="object"&&e!==null}Xe.isObject=Yp;function Vp(e){return Array.isArray(e)?e:su(e)?[]:[e]}Xe.toArray=Vp;function Kp(e,t){var n,r,i,o;if(t)for(o=Object.keys(t),n=0,r=o.length;n<r;n+=1)i=o[n],e[i]=t[i];return e}Xe.extend=Kp;function Gp(e,t){var n="",r;for(r=0;r<t;r+=1)n+=e;return n}Xe.repeat=Gp;function Jp(e){return e===0&&Number.NEGATIVE_INFINITY===1/e}Xe.isNegativeZero=Jp});var En=A((_0,au)=>{"use strict";var mn=class{constructor(t,n=null,r=!1){this.name="YAMLException",this.reason=t,this.mark=n,this.message=this.toString(!1),this.isWarning=r}static isInstance(t){if(t!=null&&t.getClassIdentifier&&typeof t.getClassIdentifier=="function"){for(let n of t.getClassIdentifier())if(n==mn.CLASS_IDENTIFIER)return!0}return!1}getClassIdentifier(){var t=[];return t.concat(mn.CLASS_IDENTIFIER)}toString(t=!1){var n;return n="JS-YAML: "+(this.reason||"(unknown reason)"),!t&&this.mark&&(n+=" "+this.mark.toString()),n}};mn.CLASS_IDENTIFIER="yaml-ast-parser.YAMLException";au.exports=mn});var lu=A((R0,uu)=>{"use strict";var cu=gn(),us=class{constructor(t,n,r,i,o){this.name=t,this.buffer=n,this.position=r,this.line=i,this.column=o}getSnippet(t=0,n=75){var r,i,o,s,u;if(!this.buffer)return null;for(t=t||4,n=n||75,r="",i=this.position;i>0&&`\0\r
1
+ var Np=Object.create;var ni=Object.defineProperty;var Op=Object.getOwnPropertyDescriptor;var Ep=Object.getOwnPropertyNames;var Mp=Object.getPrototypeOf,jp=Object.prototype.hasOwnProperty;var eu=(e=>typeof require<"u"?require:typeof Proxy<"u"?new Proxy(e,{get:(t,n)=>(typeof require<"u"?require:t)[n]}):e)(function(e){if(typeof require<"u")return require.apply(this,arguments);throw new Error('Dynamic require of "'+e+'" is not supported')});var Lp=(e,t)=>()=>(e&&(t=e(e=0)),t);var A=(e,t)=>()=>(t||e((t={exports:{}}).exports,t),t.exports),tu=(e,t)=>{for(var n in t)ni(e,n,{get:t[n],enumerable:!0})},ti=(e,t,n,r)=>{if(t&&typeof t=="object"||typeof t=="function")for(let i of Ep(t))!jp.call(e,i)&&i!==n&&ni(e,i,{get:()=>t[i],enumerable:!(r=Op(t,i))||r.enumerable});return e},rs=(e,t,n)=>(ti(e,t,"default"),n&&ti(n,t,"default")),ot=(e,t,n)=>(n=e!=null?Np(Mp(e)):{},ti(t||!e||!e.__esModule?ni(n,"default",{value:e,enumerable:!0}):n,e)),Ip=e=>ti(ni({},"__esModule",{value:!0}),e);var Ft=A(Se=>{"use strict";Object.defineProperty(Se,"__esModule",{value:!0});Se.isYAMLNode=Se.isNodesEqual=Se.newMap=Se.newSeq=Se.newItems=Se.newScalar=Se.newAnchorRef=Se.newMapping=Se.Kind=void 0;var xt;(function(e){e[e.SCALAR=0]="SCALAR",e[e.MAPPING=1]="MAPPING",e[e.MAP=2]="MAP",e[e.SEQ=3]="SEQ",e[e.ANCHOR_REF=4]="ANCHOR_REF",e[e.INCLUDE_REF=5]="INCLUDE_REF"})(xt=Se.Kind||(Se.Kind={}));function Wp(e,t,n=2){var r=t?t.endPosition:e.endPosition+1,i={key:e,value:t,nodeIndent:n,startPosition:e.startPosition,endPosition:r,kind:xt.MAPPING,parent:null,errors:[]};return i}Se.newMapping=Wp;function Hp(e,t,n,r,i=2){return{errors:[],referencesAnchor:e,value:r,nodeIndent:i,startPosition:t,endPosition:n,kind:xt.ANCHOR_REF,parent:null}}Se.newAnchorRef=Hp;function Up(e="",t=2){let n={errors:[],startPosition:-1,endPosition:-1,value:""+e,nodeIndent:t,kind:xt.SCALAR,parent:null,doubleQuoted:!1,rawValue:""+e};return typeof e!="string"&&(n.valueObject=e),n}Se.newScalar=Up;function ou(){return{errors:[],startPosition:-1,endPosition:-1,nodeIndent:2,items:[],kind:xt.SEQ,parent:null}}Se.newItems=ou;function Bp(){return ou()}Se.newSeq=Bp;function zp(e,t=2){return{errors:[],startPosition:-1,endPosition:-1,nodeIndent:t,mappings:e||[],kind:xt.MAP,parent:null}}Se.newMap=zp;function gr(e,t){if(!e||!t||e.kind!==t.kind)return!1;if(e.kind===xt.SCALAR)return e.value===t.value;if(e.kind===xt.SEQ){let n=e,r=t;if(n.items.length!==r.items.length)return!1;for(let i=0;i<n.items.length;i++){let o=n.items[i],s=r.items[i];if(!gr(o,s))return!1}return!0}if(e.kind===xt.MAP){let n=e,r=t;if(n.mappings.length!==r.mappings.length)return!1;for(let i of n.mappings){let o=i.key,s=i.value,u=r.mappings.find(c=>gr(o,c.key));if(u){if(!gr(s,u.value))return!1}else return!1}return!0}if(xt.MAPPING===e.kind){let n=e,r=t;return gr(n.key,r.key)}return!1}Se.isNodesEqual=gr;function $p(e){return e.startPosition!==void 0&&e.endPosition!==void 0&&e.kind!==void 0}Se.isYAMLNode=$p});var gn=A(Xe=>{"use strict";Object.defineProperty(Xe,"__esModule",{value:!0});Xe.isNegativeZero=Xe.repeat=Xe.extend=Xe.toArray=Xe.isObject=Xe.isNothing=void 0;function su(e){return typeof e>"u"||e===null}Xe.isNothing=su;function Yp(e){return typeof e=="object"&&e!==null}Xe.isObject=Yp;function Vp(e){return Array.isArray(e)?e:su(e)?[]:[e]}Xe.toArray=Vp;function Kp(e,t){var n,r,i,o;if(t)for(o=Object.keys(t),n=0,r=o.length;n<r;n+=1)i=o[n],e[i]=t[i];return e}Xe.extend=Kp;function Gp(e,t){var n="",r;for(r=0;r<t;r+=1)n+=e;return n}Xe.repeat=Gp;function Jp(e){return e===0&&Number.NEGATIVE_INFINITY===1/e}Xe.isNegativeZero=Jp});var Mn=A((R0,au)=>{"use strict";var mn=class{constructor(t,n=null,r=!1){this.name="YAMLException",this.reason=t,this.mark=n,this.message=this.toString(!1),this.isWarning=r}static isInstance(t){if(t!=null&&t.getClassIdentifier&&typeof t.getClassIdentifier=="function"){for(let n of t.getClassIdentifier())if(n==mn.CLASS_IDENTIFIER)return!0}return!1}getClassIdentifier(){var t=[];return t.concat(mn.CLASS_IDENTIFIER)}toString(t=!1){var n;return n="JS-YAML: "+(this.reason||"(unknown reason)"),!t&&this.mark&&(n+=" "+this.mark.toString()),n}};mn.CLASS_IDENTIFIER="yaml-ast-parser.YAMLException";au.exports=mn});var lu=A((D0,uu)=>{"use strict";var cu=gn(),us=class{constructor(t,n,r,i,o){this.name=t,this.buffer=n,this.position=r,this.line=i,this.column=o}getSnippet(t=0,n=75){var r,i,o,s,u;if(!this.buffer)return null;for(t=t||4,n=n||75,r="",i=this.position;i>0&&`\0\r
2
2
  \x85\u2028\u2029`.indexOf(this.buffer.charAt(i-1))===-1;)if(i-=1,this.position-i>n/2-1){r=" ... ",i+=5;break}for(o="",s=this.position;s<this.buffer.length&&`\0\r
3
3
  \x85\u2028\u2029`.indexOf(this.buffer.charAt(s))===-1;)if(s+=1,s-this.position>n/2-1){o=" ... ",s-=5;break}return u=this.buffer.slice(i,s),cu.repeat(" ",t)+r+u+o+`
4
4
  `+cu.repeat(" ",t+this.position-i+r.length)+"^"}toString(t=!0){var n,r="";return this.name&&(r+='in "'+this.name+'" '),r+="at line "+(this.line+1)+", column "+(this.column+1),t||(n=this.getSnippet(),n&&(r+=`:
5
- `+n)),r}};uu.exports=us});var Fe=A(ri=>{"use strict";Object.defineProperty(ri,"__esModule",{value:!0});ri.Type=void 0;var du=En(),Qp=["kind","resolve","construct","instanceOf","predicate","represent","defaultStyle","styleAliases"],Xp=["scalar","sequence","mapping"];function Zp(e){var t={};return e!==null&&Object.keys(e).forEach(function(n){e[n].forEach(function(r){t[String(r)]=n})}),t}var ls=class{constructor(t,n){if(n=n||{},Object.keys(n).forEach(function(r){if(Qp.indexOf(r)===-1)throw new du('Unknown option "'+r+'" is met in definition of "'+t+'" YAML type.')}),this.tag=t,this.kind=n.kind||null,this.resolve=n.resolve||function(){return!0},this.construct=n.construct||function(r){return r},this.instanceOf=n.instanceOf||null,this.predicate=n.predicate||null,this.represent=n.represent||null,this.defaultStyle=n.defaultStyle||null,this.styleAliases=Zp(n.styleAliases||null),Xp.indexOf(this.kind)===-1)throw new du('Unknown kind "'+this.kind+'" is specified for "'+t+'" YAML type.')}};ri.Type=ls});var Mn=A(oi=>{"use strict";Object.defineProperty(oi,"__esModule",{value:!0});oi.Schema=void 0;var fu=gn(),ii=En(),eg=Fe();function ds(e,t,n){var r=[];return e.include.forEach(function(i){n=ds(i,t,n)}),e[t].forEach(function(i){n.forEach(function(o,s){o.tag===i.tag&&r.push(s)}),n.push(i)}),n.filter(function(i,o){return r.indexOf(o)===-1})}function tg(){var e={},t,n;function r(i){e[i.tag]=i}for(t=0,n=arguments.length;t<n;t+=1)arguments[t].forEach(r);return e}var Jt=class{constructor(t){this.include=t.include||[],this.implicit=t.implicit||[],this.explicit=t.explicit||[],this.implicit.forEach(function(n){if(n.loadKind&&n.loadKind!=="scalar")throw new ii("There is a non-scalar type in the implicit list of a schema. Implicit resolving of such types is not supported.")}),this.compiledImplicit=ds(this,"implicit",[]),this.compiledExplicit=ds(this,"explicit",[]),this.compiledTypeMap=tg(this.compiledImplicit,this.compiledExplicit)}};oi.Schema=Jt;Jt.DEFAULT=null;Jt.create=function(...t){var n,r;switch(t.length){case 1:n=Jt.DEFAULT,r=t[0];break;case 2:n=t[0],r=t[1];break;default:throw new ii("Wrong number of arguments for Schema.create function")}if(n=fu.toArray(n),r=fu.toArray(r),!n.every(function(i){return i instanceof Jt}))throw new ii("Specified list of super schemas (or a single Schema object) contains a non-Schema object.");if(!r.every(function(i){return i instanceof eg.Type}))throw new ii("Specified list of YAML types (or a single Type object) contains a non-Type object.");return new Jt({include:n,explicit:r})}});var gu=A((T0,pu)=>{"use strict";var ng=Fe();pu.exports=new ng.Type("tag:yaml.org,2002:str",{kind:"scalar",construct:function(e){return e!==null?e:""}})});var hu=A((x0,mu)=>{"use strict";var rg=Fe();mu.exports=new rg.Type("tag:yaml.org,2002:seq",{kind:"sequence",construct:function(e){return e!==null?e:[]}})});var bu=A((w0,yu)=>{"use strict";var ig=Fe();yu.exports=new ig.Type("tag:yaml.org,2002:map",{kind:"mapping",construct:function(e){return e!==null?e:{}}})});var Cu=A((k0,vu)=>{"use strict";var og=Mn();vu.exports=new og.Schema({explicit:[gu(),hu(),bu()]})});var Ru=A((A0,_u)=>{"use strict";var sg=Fe(),Pu=Ft();function ag(e){let t=Pu.isYAMLNode(e)?e.value:e;if(t===null)return!0;var n=t.length;return n===1&&t==="~"||n===4&&(t==="null"||t==="Null"||t==="NULL")}function cg(e){return Pu.isYAMLNode(e)?e:null}function ug(e){return e===null}_u.exports=new sg.Type("tag:yaml.org,2002:null",{kind:"scalar",resolve:ag,construct:cg,predicate:ug,represent:{canonical:function(){return"~"},lowercase:function(){return"null"},uppercase:function(){return"NULL"},camelcase:function(){return"Null"}},defaultStyle:"lowercase"})});var Tu=A((q0,Su)=>{"use strict";"use strict";var lg=Fe(),Du=Ft();function dg(e){let t=Du.isYAMLNode(e)?e.value:e;if(t===null)return!1;var n=t.length;return n===4&&(t==="true"||t==="True"||t==="TRUE")||n===5&&(t==="false"||t==="False"||t==="FALSE")}function fg(e){return Du.isYAMLNode(e)?e:e==="true"||e==="True"||e==="TRUE"}function pg(e){return Object.prototype.toString.call(e)==="[object Boolean]"}Su.exports=new lg.Type("tag:yaml.org,2002:bool",{kind:"scalar",resolve:dg,construct:fg,predicate:pg,represent:{lowercase:function(e){return e?"true":"false"},uppercase:function(e){return e?"TRUE":"FALSE"},camelcase:function(e){return e?"True":"False"}},defaultStyle:"lowercase"})});var ku=A((N0,wu)=>{"use strict";var gg=gn(),mg=Fe(),xu=Ft();function hg(e){return 48<=e&&e<=57||65<=e&&e<=70||97<=e&&e<=102}function yg(e){return 48<=e&&e<=55}function bg(e){return 48<=e&&e<=57}function vg(e){let t=xu.isYAMLNode(e)?e.value:e;if(t===null)return!1;var n=t.length,r=0,i=!1,o;if(!n)return!1;if(o=t[r],(o==="-"||o==="+")&&(o=t[++r]),o==="0"){if(r+1===n)return!0;if(o=t[++r],o==="b"){for(r++;r<n;r++)if(o=t[r],o!=="_"){if(o!=="0"&&o!=="1")return!1;i=!0}return i}if(o==="x"){for(r++;r<n;r++)if(o=t[r],o!=="_"){if(!hg(t.charCodeAt(r)))return!1;i=!0}return i}for(;r<n;r++)if(o=t[r],o!=="_"){if(!yg(t.charCodeAt(r)))return!1;i=!0}return i}for(;r<n;r++)if(o=t[r],o!=="_"){if(o===":")break;if(!bg(t.charCodeAt(r)))return!1;i=!0}return i?o!==":"?!0:/^(:[0-5]?[0-9])+$/.test(t.slice(r)):!1}function Cg(e){if(xu.isYAMLNode(e))return e;var t=e,n=1,r,i,o=[];return t.indexOf("_")!==-1&&(t=t.replace(/_/g,"")),r=t[0],(r==="-"||r==="+")&&(r==="-"&&(n=-1),t=t.slice(1),r=t[0]),t==="0"?0:r==="0"?t[1]==="b"?n*parseInt(t.slice(2),2):t[1]==="x"?n*parseInt(t,16):n*parseInt(t,8):t.indexOf(":")!==-1?(t.split(":").forEach(function(s){o.unshift(parseInt(s,10))}),t=0,i=1,o.forEach(function(s){t+=s*i,i*=60}),n*t):n*parseInt(t,10)}function Pg(e){return Object.prototype.toString.call(e)==="[object Number]"&&e%1===0&&!gg.isNegativeZero(e)}wu.exports=new mg.Type("tag:yaml.org,2002:int",{kind:"scalar",resolve:vg,construct:Cg,predicate:Pg,represent:{binary:function(e){return"0b"+e.toString(2)},octal:function(e){return"0"+e.toString(8)},decimal:function(e){return e.toString(10)},hexadecimal:function(e){return"0x"+e.toString(16).toUpperCase()}},defaultStyle:"decimal",styleAliases:{binary:[2,"bin"],octal:[8,"oct"],decimal:[10,"dec"],hexadecimal:[16,"hex"]}})});var Ou=A((O0,Nu)=>{"use strict";var Au=gn(),_g=Fe(),qu=Ft(),Rg=new RegExp("-?(0|[1-9][0-9]*)(.[0-9]*)?([eE][-+]?[0-9]+)?|^0$|^[-+]?.(inf|Inf|INF)$|^.(nan|NaN|NAN)$");function Dg(e){let t=qu.isYAMLNode(e)?e.value:e;return!(t===null||!Rg.test(t))}function Sg(e){if(qu.isYAMLNode(e))return e;var t,n,r,i;return t=e.replace(/_/g,"").toLowerCase(),n=t[0]==="-"?-1:1,i=[],0<="+-".indexOf(t[0])&&(t=t.slice(1)),t===".inf"?n===1?Number.POSITIVE_INFINITY:Number.NEGATIVE_INFINITY:t===".nan"?NaN:0<=t.indexOf(":")?(t.split(":").forEach(function(o){i.unshift(parseFloat(o,10))}),t=0,r=1,i.forEach(function(o){t+=o*r,r*=60}),n*t):n*parseFloat(t,10)}function Tg(e,t){if(isNaN(e))switch(t){case"lowercase":return".nan";case"uppercase":return".NAN";case"camelcase":return".NaN"}else if(Number.POSITIVE_INFINITY===e)switch(t){case"lowercase":return".inf";case"uppercase":return".INF";case"camelcase":return".Inf"}else if(Number.NEGATIVE_INFINITY===e)switch(t){case"lowercase":return"-.inf";case"uppercase":return"-.INF";case"camelcase":return"-.Inf"}else if(Au.isNegativeZero(e))return"-0.0";return e.toString(10)}function xg(e){return Object.prototype.toString.call(e)==="[object Number]"&&(e%1!==0||Au.isNegativeZero(e))}Nu.exports=new _g.Type("tag:yaml.org,2002:float",{kind:"scalar",resolve:Dg,construct:Sg,predicate:xg,represent:Tg,defaultStyle:"lowercase"})});var Mu=A((E0,Eu)=>{"use strict";var wg=Mn();Eu.exports=new wg.Schema({include:[Cu()],implicit:[Ru(),Tu(),ku(),Ou()]})});var Lu=A((M0,ju)=>{"use strict";var kg=Mn();ju.exports=new kg.Schema({include:[Mu()]})});var Wu=A((j0,Fu)=>{"use strict";var Ag=Fe(),Iu=new RegExp("^([0-9][0-9][0-9][0-9])-([0-9][0-9]?)-([0-9][0-9]?)(?:(?:[Tt]|[ \\t]+)([0-9][0-9]?):([0-9][0-9]):([0-9][0-9])(?:\\.([0-9]*))?(?:[ \\t]*(Z|([-+])([0-9][0-9]?)(?::([0-9][0-9]))?))?)?$");function qg(e){if(e===null)return!1;var t,n,r,i,o,s,u,c=0,p=null,g,b,R;return t=Iu.exec(e),t!==null}function Ng(e){var t,n,r,i,o,s,u,c=0,p=null,g,b,R;if(t=Iu.exec(e),t===null)throw new Error("Date resolve error");if(n=+t[1],r=+t[2]-1,i=+t[3],!t[4])return new Date(Date.UTC(n,r,i));if(o=+t[4],s=+t[5],u=+t[6],t[7]){for(c=t[7].slice(0,3);c.length<3;)c=c+"0";c=+c}return t[9]&&(g=+t[10],b=+(t[11]||0),p=(g*60+b)*6e4,t[9]==="-"&&(p=-p)),R=new Date(Date.UTC(n,r,i,o,s,u,c)),p&&R.setTime(R.getTime()-p),R}function Og(e){return e.toISOString()}Fu.exports=new Ag.Type("tag:yaml.org,2002:timestamp",{kind:"scalar",resolve:qg,construct:Ng,instanceOf:Date,represent:Og})});var Uu=A((L0,Hu)=>{"use strict";var Eg=Fe();function Mg(e){return e==="<<"||e===null}Hu.exports=new Eg.Type("tag:yaml.org,2002:merge",{kind:"scalar",resolve:Mg})});var Bu={};tu(Bu,{default:()=>jg});var jg,zu=Lp(()=>{jg={}});var Yu=A((I0,$u)=>{"use strict";var si=(zu(),Ip(Bu)).Buffer,Lg=Fe(),fs=`ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=
6
- \r`;function Ig(e){if(e===null)return!1;var t,n,r=0,i=0,o=e.length,s=fs;for(n=0;n<o;n++)if(t=s.indexOf(e.charAt(n)),!(t>64)){if(t<0)return!1;r+=6}return r%8===0}function Fg(e){var t,n,r,i=e.replace(/[\r\n=]/g,""),o=i.length,s=fs,u=0,c=[];for(n=0;n<o;n++)n%4===0&&n&&(c.push(u>>16&255),c.push(u>>8&255),c.push(u&255)),u=u<<6|s.indexOf(i.charAt(n));return r=o%4*6,r===0?(c.push(u>>16&255),c.push(u>>8&255),c.push(u&255)):r===18?(c.push(u>>10&255),c.push(u>>2&255)):r===12&&c.push(u>>4&255),si?new si(c):c}function Wg(e){var t="",n=0,r,i,o=e.length,s=fs;for(r=0;r<o;r++)r%3===0&&r&&(t+=s[n>>18&63],t+=s[n>>12&63],t+=s[n>>6&63],t+=s[n&63]),n=(n<<8)+e[r];return i=o%3,i===0?(t+=s[n>>18&63],t+=s[n>>12&63],t+=s[n>>6&63],t+=s[n&63]):i===2?(t+=s[n>>10&63],t+=s[n>>4&63],t+=s[n<<2&63],t+=s[64]):i===1&&(t+=s[n>>2&63],t+=s[n<<4&63],t+=s[64],t+=s[64]),t}function Hg(e){return si&&si.isBuffer(e)}$u.exports=new Lg.Type("tag:yaml.org,2002:binary",{kind:"scalar",resolve:Ig,construct:Fg,predicate:Hg,represent:Wg})});var Ku=A((F0,Vu)=>{"use strict";var Ug=Fe(),Bg=Object.prototype.hasOwnProperty,zg=Object.prototype.toString;function $g(e){if(e===null)return!0;var t=[],n,r,i,o,s,u=e;for(n=0,r=u.length;n<r;n+=1){if(i=u[n],s=!1,zg.call(i)!=="[object Object]")return!1;for(o in i)if(Bg.call(i,o))if(!s)s=!0;else return!1;if(!s)return!1;if(t.indexOf(o)===-1)t.push(o);else return!1}return!0}function Yg(e){return e!==null?e:[]}Vu.exports=new Ug.Type("tag:yaml.org,2002:omap",{kind:"sequence",resolve:$g,construct:Yg})});var Ju=A((W0,Gu)=>{"use strict";var Vg=Fe(),ps=Ft(),Kg=Object.prototype.toString;function Gg(e){if(e===null)return!0;if(e.kind!=ps.Kind.SEQ)return!1;var t,n,r,i,o,s=e.items;for(t=0,n=s.length;t<n;t+=1)if(r=s[t],Kg.call(r)!=="[object Object]"||!Array.isArray(r.mappings)||r.mappings.length!==1)return!1;return!0}function Jg(e){if(e===null||!Array.isArray(e.items))return[];let t,n,r,i,o=e.items;for(i=ps.newItems(),i.parent=e.parent,i.startPosition=e.startPosition,i.endPosition=e.endPosition,t=0,n=o.length;t<n;t+=1){let u=o[t].mappings[0],c=ps.newItems();c.parent=i,c.startPosition=u.key.startPosition,c.endPosition=u.value.startPosition,u.key.parent=c,u.value.parent=c,c.items=[u.key,u.value],i.items.push(c)}return i}Gu.exports=new Vg.Type("tag:yaml.org,2002:pairs",{kind:"sequence",resolve:Gg,construct:Jg})});var Xu=A((H0,Qu)=>{"use strict";var Qg=Fe(),Xg=Ft();function Zg(e){return e===null?!0:e.kind==Xg.Kind.MAP}function em(e){return e!==null?e:{}}Qu.exports=new Qg.Type("tag:yaml.org,2002:set",{kind:"mapping",resolve:Zg,construct:em})});var ai=A((U0,Zu)=>{"use strict";var tm=Mn(),nm=new tm.Schema({include:[Lu()],implicit:[Wu(),Uu()],explicit:[Yu(),Ku(),Ju(),Xu()]});Zu.exports=nm});var tl=A((B0,el)=>{"use strict";var rm=Fe();function im(){return!0}function om(){}function sm(){return""}function am(e){return typeof e>"u"}el.exports=new rm.Type("tag:yaml.org,2002:js/undefined",{kind:"scalar",resolve:im,construct:om,predicate:am,represent:sm})});var rl=A((z0,nl)=>{"use strict";var cm=Fe();function um(e){if(e===null||e.length===0)return!1;var t=e,n=/\/([gim]*)$/.exec(e),r="";if(t[0]==="/"){if(n&&(r=n[1]),r.length>3||t[t.length-r.length-1]!=="/")return!1;t=t.slice(1,t.length-r.length-1)}try{var i=new RegExp(t,r);return!0}catch{return!1}}function lm(e){var t=e,n=/\/([gim]*)$/.exec(e),r="";return t[0]==="/"&&(n&&(r=n[1]),t=t.slice(1,t.length-r.length-1)),new RegExp(t,r)}function dm(e){var t="/"+e.source+"/";return e.global&&(t+="g"),e.multiline&&(t+="m"),e.ignoreCase&&(t+="i"),t}function fm(e){return Object.prototype.toString.call(e)==="[object RegExp]"}nl.exports=new cm.Type("tag:yaml.org,2002:js/regexp",{kind:"scalar",resolve:um,construct:lm,predicate:fm,represent:dm})});var gs=A(($0,sl)=>{"use strict";var il=Mn(),ol=new il.Schema({include:[ai()],explicit:[tl(),rl()]});il.Schema.DEFAULT=ol;sl.exports=ol});var vl=A((wt,hr)=>{"use strict";Object.defineProperty(wt,"__esModule",{value:!0});wt.safeLoad=wt.safeLoadAll=wt.load=wt.loadAll=void 0;var et=Ft(),Qt=gn(),_s=En(),Rs=lu(),ll=ai(),pm=gs(),li=Object.prototype.hasOwnProperty,ci=1,dl=2,fl=3,ui=4,ms=1,gm=2,al=3,mm=/[\x00-\x08\x0B\x0C\x0E-\x1F\x7F-\x84\x86-\x9F\uFFFE\uFFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF]/,hm=/[\x85\u2028\u2029]/,ym=/[,\[\]\{\}]/,pl=/^(?:!|!!|![a-z\-]+!)$/i,gl=/^(?:!|[^,\[\]\{\}])(?:%[0-9a-f]{2}|[0-9a-z\-#;\/\?:@&=\+\$,_\.!~\*'\(\)\[\]])*$/i;function mt(e){return e===10||e===13}function yn(e){return e===9||e===32}function Ze(e){return e===9||e===32||e===10||e===13}function jn(e){return e===44||e===91||e===93||e===123||e===125}function bm(e){var t;return 48<=e&&e<=57?e-48:(t=e|32,97<=t&&t<=102?t-97+10:-1)}function vm(e){return e===120?2:e===117?4:e===85?8:0}function Cm(e){return 48<=e&&e<=57?e-48:-1}function Pm(e){return e===48?"\0":e===97?"\x07":e===98?"\b":e===116||e===9?" ":e===110?`
5
+ `+n)),r}};uu.exports=us});var Fe=A(ri=>{"use strict";Object.defineProperty(ri,"__esModule",{value:!0});ri.Type=void 0;var du=Mn(),Qp=["kind","resolve","construct","instanceOf","predicate","represent","defaultStyle","styleAliases"],Xp=["scalar","sequence","mapping"];function Zp(e){var t={};return e!==null&&Object.keys(e).forEach(function(n){e[n].forEach(function(r){t[String(r)]=n})}),t}var ls=class{constructor(t,n){if(n=n||{},Object.keys(n).forEach(function(r){if(Qp.indexOf(r)===-1)throw new du('Unknown option "'+r+'" is met in definition of "'+t+'" YAML type.')}),this.tag=t,this.kind=n.kind||null,this.resolve=n.resolve||function(){return!0},this.construct=n.construct||function(r){return r},this.instanceOf=n.instanceOf||null,this.predicate=n.predicate||null,this.represent=n.represent||null,this.defaultStyle=n.defaultStyle||null,this.styleAliases=Zp(n.styleAliases||null),Xp.indexOf(this.kind)===-1)throw new du('Unknown kind "'+this.kind+'" is specified for "'+t+'" YAML type.')}};ri.Type=ls});var jn=A(oi=>{"use strict";Object.defineProperty(oi,"__esModule",{value:!0});oi.Schema=void 0;var fu=gn(),ii=Mn(),eg=Fe();function ds(e,t,n){var r=[];return e.include.forEach(function(i){n=ds(i,t,n)}),e[t].forEach(function(i){n.forEach(function(o,s){o.tag===i.tag&&r.push(s)}),n.push(i)}),n.filter(function(i,o){return r.indexOf(o)===-1})}function tg(){var e={},t,n;function r(i){e[i.tag]=i}for(t=0,n=arguments.length;t<n;t+=1)arguments[t].forEach(r);return e}var Jt=class{constructor(t){this.include=t.include||[],this.implicit=t.implicit||[],this.explicit=t.explicit||[],this.implicit.forEach(function(n){if(n.loadKind&&n.loadKind!=="scalar")throw new ii("There is a non-scalar type in the implicit list of a schema. Implicit resolving of such types is not supported.")}),this.compiledImplicit=ds(this,"implicit",[]),this.compiledExplicit=ds(this,"explicit",[]),this.compiledTypeMap=tg(this.compiledImplicit,this.compiledExplicit)}};oi.Schema=Jt;Jt.DEFAULT=null;Jt.create=function(...t){var n,r;switch(t.length){case 1:n=Jt.DEFAULT,r=t[0];break;case 2:n=t[0],r=t[1];break;default:throw new ii("Wrong number of arguments for Schema.create function")}if(n=fu.toArray(n),r=fu.toArray(r),!n.every(function(i){return i instanceof Jt}))throw new ii("Specified list of super schemas (or a single Schema object) contains a non-Schema object.");if(!r.every(function(i){return i instanceof eg.Type}))throw new ii("Specified list of YAML types (or a single Type object) contains a non-Type object.");return new Jt({include:n,explicit:r})}});var gu=A((x0,pu)=>{"use strict";var ng=Fe();pu.exports=new ng.Type("tag:yaml.org,2002:str",{kind:"scalar",construct:function(e){return e!==null?e:""}})});var hu=A((w0,mu)=>{"use strict";var rg=Fe();mu.exports=new rg.Type("tag:yaml.org,2002:seq",{kind:"sequence",construct:function(e){return e!==null?e:[]}})});var bu=A((k0,yu)=>{"use strict";var ig=Fe();yu.exports=new ig.Type("tag:yaml.org,2002:map",{kind:"mapping",construct:function(e){return e!==null?e:{}}})});var Cu=A((A0,vu)=>{"use strict";var og=jn();vu.exports=new og.Schema({explicit:[gu(),hu(),bu()]})});var Ru=A((q0,_u)=>{"use strict";var sg=Fe(),Pu=Ft();function ag(e){let t=Pu.isYAMLNode(e)?e.value:e;if(t===null)return!0;var n=t.length;return n===1&&t==="~"||n===4&&(t==="null"||t==="Null"||t==="NULL")}function cg(e){return Pu.isYAMLNode(e)?e:null}function ug(e){return e===null}_u.exports=new sg.Type("tag:yaml.org,2002:null",{kind:"scalar",resolve:ag,construct:cg,predicate:ug,represent:{canonical:function(){return"~"},lowercase:function(){return"null"},uppercase:function(){return"NULL"},camelcase:function(){return"Null"}},defaultStyle:"lowercase"})});var Tu=A((N0,Su)=>{"use strict";"use strict";var lg=Fe(),Du=Ft();function dg(e){let t=Du.isYAMLNode(e)?e.value:e;if(t===null)return!1;var n=t.length;return n===4&&(t==="true"||t==="True"||t==="TRUE")||n===5&&(t==="false"||t==="False"||t==="FALSE")}function fg(e){return Du.isYAMLNode(e)?e:e==="true"||e==="True"||e==="TRUE"}function pg(e){return Object.prototype.toString.call(e)==="[object Boolean]"}Su.exports=new lg.Type("tag:yaml.org,2002:bool",{kind:"scalar",resolve:dg,construct:fg,predicate:pg,represent:{lowercase:function(e){return e?"true":"false"},uppercase:function(e){return e?"TRUE":"FALSE"},camelcase:function(e){return e?"True":"False"}},defaultStyle:"lowercase"})});var ku=A((O0,wu)=>{"use strict";var gg=gn(),mg=Fe(),xu=Ft();function hg(e){return 48<=e&&e<=57||65<=e&&e<=70||97<=e&&e<=102}function yg(e){return 48<=e&&e<=55}function bg(e){return 48<=e&&e<=57}function vg(e){let t=xu.isYAMLNode(e)?e.value:e;if(t===null)return!1;var n=t.length,r=0,i=!1,o;if(!n)return!1;if(o=t[r],(o==="-"||o==="+")&&(o=t[++r]),o==="0"){if(r+1===n)return!0;if(o=t[++r],o==="b"){for(r++;r<n;r++)if(o=t[r],o!=="_"){if(o!=="0"&&o!=="1")return!1;i=!0}return i}if(o==="x"){for(r++;r<n;r++)if(o=t[r],o!=="_"){if(!hg(t.charCodeAt(r)))return!1;i=!0}return i}for(;r<n;r++)if(o=t[r],o!=="_"){if(!yg(t.charCodeAt(r)))return!1;i=!0}return i}for(;r<n;r++)if(o=t[r],o!=="_"){if(o===":")break;if(!bg(t.charCodeAt(r)))return!1;i=!0}return i?o!==":"?!0:/^(:[0-5]?[0-9])+$/.test(t.slice(r)):!1}function Cg(e){if(xu.isYAMLNode(e))return e;var t=e,n=1,r,i,o=[];return t.indexOf("_")!==-1&&(t=t.replace(/_/g,"")),r=t[0],(r==="-"||r==="+")&&(r==="-"&&(n=-1),t=t.slice(1),r=t[0]),t==="0"?0:r==="0"?t[1]==="b"?n*parseInt(t.slice(2),2):t[1]==="x"?n*parseInt(t,16):n*parseInt(t,8):t.indexOf(":")!==-1?(t.split(":").forEach(function(s){o.unshift(parseInt(s,10))}),t=0,i=1,o.forEach(function(s){t+=s*i,i*=60}),n*t):n*parseInt(t,10)}function Pg(e){return Object.prototype.toString.call(e)==="[object Number]"&&e%1===0&&!gg.isNegativeZero(e)}wu.exports=new mg.Type("tag:yaml.org,2002:int",{kind:"scalar",resolve:vg,construct:Cg,predicate:Pg,represent:{binary:function(e){return"0b"+e.toString(2)},octal:function(e){return"0"+e.toString(8)},decimal:function(e){return e.toString(10)},hexadecimal:function(e){return"0x"+e.toString(16).toUpperCase()}},defaultStyle:"decimal",styleAliases:{binary:[2,"bin"],octal:[8,"oct"],decimal:[10,"dec"],hexadecimal:[16,"hex"]}})});var Ou=A((E0,Nu)=>{"use strict";var Au=gn(),_g=Fe(),qu=Ft(),Rg=new RegExp("-?(0|[1-9][0-9]*)(.[0-9]*)?([eE][-+]?[0-9]+)?|^0$|^[-+]?.(inf|Inf|INF)$|^.(nan|NaN|NAN)$");function Dg(e){let t=qu.isYAMLNode(e)?e.value:e;return!(t===null||!Rg.test(t))}function Sg(e){if(qu.isYAMLNode(e))return e;var t,n,r,i;return t=e.replace(/_/g,"").toLowerCase(),n=t[0]==="-"?-1:1,i=[],0<="+-".indexOf(t[0])&&(t=t.slice(1)),t===".inf"?n===1?Number.POSITIVE_INFINITY:Number.NEGATIVE_INFINITY:t===".nan"?NaN:0<=t.indexOf(":")?(t.split(":").forEach(function(o){i.unshift(parseFloat(o,10))}),t=0,r=1,i.forEach(function(o){t+=o*r,r*=60}),n*t):n*parseFloat(t,10)}function Tg(e,t){if(isNaN(e))switch(t){case"lowercase":return".nan";case"uppercase":return".NAN";case"camelcase":return".NaN"}else if(Number.POSITIVE_INFINITY===e)switch(t){case"lowercase":return".inf";case"uppercase":return".INF";case"camelcase":return".Inf"}else if(Number.NEGATIVE_INFINITY===e)switch(t){case"lowercase":return"-.inf";case"uppercase":return"-.INF";case"camelcase":return"-.Inf"}else if(Au.isNegativeZero(e))return"-0.0";return e.toString(10)}function xg(e){return Object.prototype.toString.call(e)==="[object Number]"&&(e%1!==0||Au.isNegativeZero(e))}Nu.exports=new _g.Type("tag:yaml.org,2002:float",{kind:"scalar",resolve:Dg,construct:Sg,predicate:xg,represent:Tg,defaultStyle:"lowercase"})});var Mu=A((M0,Eu)=>{"use strict";var wg=jn();Eu.exports=new wg.Schema({include:[Cu()],implicit:[Ru(),Tu(),ku(),Ou()]})});var Lu=A((j0,ju)=>{"use strict";var kg=jn();ju.exports=new kg.Schema({include:[Mu()]})});var Wu=A((L0,Fu)=>{"use strict";var Ag=Fe(),Iu=new RegExp("^([0-9][0-9][0-9][0-9])-([0-9][0-9]?)-([0-9][0-9]?)(?:(?:[Tt]|[ \\t]+)([0-9][0-9]?):([0-9][0-9]):([0-9][0-9])(?:\\.([0-9]*))?(?:[ \\t]*(Z|([-+])([0-9][0-9]?)(?::([0-9][0-9]))?))?)?$");function qg(e){if(e===null)return!1;var t,n,r,i,o,s,u,c=0,p=null,g,b,R;return t=Iu.exec(e),t!==null}function Ng(e){var t,n,r,i,o,s,u,c=0,p=null,g,b,R;if(t=Iu.exec(e),t===null)throw new Error("Date resolve error");if(n=+t[1],r=+t[2]-1,i=+t[3],!t[4])return new Date(Date.UTC(n,r,i));if(o=+t[4],s=+t[5],u=+t[6],t[7]){for(c=t[7].slice(0,3);c.length<3;)c=c+"0";c=+c}return t[9]&&(g=+t[10],b=+(t[11]||0),p=(g*60+b)*6e4,t[9]==="-"&&(p=-p)),R=new Date(Date.UTC(n,r,i,o,s,u,c)),p&&R.setTime(R.getTime()-p),R}function Og(e){return e.toISOString()}Fu.exports=new Ag.Type("tag:yaml.org,2002:timestamp",{kind:"scalar",resolve:qg,construct:Ng,instanceOf:Date,represent:Og})});var Uu=A((I0,Hu)=>{"use strict";var Eg=Fe();function Mg(e){return e==="<<"||e===null}Hu.exports=new Eg.Type("tag:yaml.org,2002:merge",{kind:"scalar",resolve:Mg})});var Bu={};tu(Bu,{default:()=>jg});var jg,zu=Lp(()=>{jg={}});var Yu=A((F0,$u)=>{"use strict";var si=(zu(),Ip(Bu)).Buffer,Lg=Fe(),fs=`ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=
6
+ \r`;function Ig(e){if(e===null)return!1;var t,n,r=0,i=0,o=e.length,s=fs;for(n=0;n<o;n++)if(t=s.indexOf(e.charAt(n)),!(t>64)){if(t<0)return!1;r+=6}return r%8===0}function Fg(e){var t,n,r,i=e.replace(/[\r\n=]/g,""),o=i.length,s=fs,u=0,c=[];for(n=0;n<o;n++)n%4===0&&n&&(c.push(u>>16&255),c.push(u>>8&255),c.push(u&255)),u=u<<6|s.indexOf(i.charAt(n));return r=o%4*6,r===0?(c.push(u>>16&255),c.push(u>>8&255),c.push(u&255)):r===18?(c.push(u>>10&255),c.push(u>>2&255)):r===12&&c.push(u>>4&255),si?new si(c):c}function Wg(e){var t="",n=0,r,i,o=e.length,s=fs;for(r=0;r<o;r++)r%3===0&&r&&(t+=s[n>>18&63],t+=s[n>>12&63],t+=s[n>>6&63],t+=s[n&63]),n=(n<<8)+e[r];return i=o%3,i===0?(t+=s[n>>18&63],t+=s[n>>12&63],t+=s[n>>6&63],t+=s[n&63]):i===2?(t+=s[n>>10&63],t+=s[n>>4&63],t+=s[n<<2&63],t+=s[64]):i===1&&(t+=s[n>>2&63],t+=s[n<<4&63],t+=s[64],t+=s[64]),t}function Hg(e){return si&&si.isBuffer(e)}$u.exports=new Lg.Type("tag:yaml.org,2002:binary",{kind:"scalar",resolve:Ig,construct:Fg,predicate:Hg,represent:Wg})});var Ku=A((W0,Vu)=>{"use strict";var Ug=Fe(),Bg=Object.prototype.hasOwnProperty,zg=Object.prototype.toString;function $g(e){if(e===null)return!0;var t=[],n,r,i,o,s,u=e;for(n=0,r=u.length;n<r;n+=1){if(i=u[n],s=!1,zg.call(i)!=="[object Object]")return!1;for(o in i)if(Bg.call(i,o))if(!s)s=!0;else return!1;if(!s)return!1;if(t.indexOf(o)===-1)t.push(o);else return!1}return!0}function Yg(e){return e!==null?e:[]}Vu.exports=new Ug.Type("tag:yaml.org,2002:omap",{kind:"sequence",resolve:$g,construct:Yg})});var Ju=A((H0,Gu)=>{"use strict";var Vg=Fe(),ps=Ft(),Kg=Object.prototype.toString;function Gg(e){if(e===null)return!0;if(e.kind!=ps.Kind.SEQ)return!1;var t,n,r,i,o,s=e.items;for(t=0,n=s.length;t<n;t+=1)if(r=s[t],Kg.call(r)!=="[object Object]"||!Array.isArray(r.mappings)||r.mappings.length!==1)return!1;return!0}function Jg(e){if(e===null||!Array.isArray(e.items))return[];let t,n,r,i,o=e.items;for(i=ps.newItems(),i.parent=e.parent,i.startPosition=e.startPosition,i.endPosition=e.endPosition,t=0,n=o.length;t<n;t+=1){let u=o[t].mappings[0],c=ps.newItems();c.parent=i,c.startPosition=u.key.startPosition,c.endPosition=u.value.startPosition,u.key.parent=c,u.value.parent=c,c.items=[u.key,u.value],i.items.push(c)}return i}Gu.exports=new Vg.Type("tag:yaml.org,2002:pairs",{kind:"sequence",resolve:Gg,construct:Jg})});var Xu=A((U0,Qu)=>{"use strict";var Qg=Fe(),Xg=Ft();function Zg(e){return e===null?!0:e.kind==Xg.Kind.MAP}function em(e){return e!==null?e:{}}Qu.exports=new Qg.Type("tag:yaml.org,2002:set",{kind:"mapping",resolve:Zg,construct:em})});var ai=A((B0,Zu)=>{"use strict";var tm=jn(),nm=new tm.Schema({include:[Lu()],implicit:[Wu(),Uu()],explicit:[Yu(),Ku(),Ju(),Xu()]});Zu.exports=nm});var tl=A((z0,el)=>{"use strict";var rm=Fe();function im(){return!0}function om(){}function sm(){return""}function am(e){return typeof e>"u"}el.exports=new rm.Type("tag:yaml.org,2002:js/undefined",{kind:"scalar",resolve:im,construct:om,predicate:am,represent:sm})});var rl=A(($0,nl)=>{"use strict";var cm=Fe();function um(e){if(e===null||e.length===0)return!1;var t=e,n=/\/([gim]*)$/.exec(e),r="";if(t[0]==="/"){if(n&&(r=n[1]),r.length>3||t[t.length-r.length-1]!=="/")return!1;t=t.slice(1,t.length-r.length-1)}try{var i=new RegExp(t,r);return!0}catch{return!1}}function lm(e){var t=e,n=/\/([gim]*)$/.exec(e),r="";return t[0]==="/"&&(n&&(r=n[1]),t=t.slice(1,t.length-r.length-1)),new RegExp(t,r)}function dm(e){var t="/"+e.source+"/";return e.global&&(t+="g"),e.multiline&&(t+="m"),e.ignoreCase&&(t+="i"),t}function fm(e){return Object.prototype.toString.call(e)==="[object RegExp]"}nl.exports=new cm.Type("tag:yaml.org,2002:js/regexp",{kind:"scalar",resolve:um,construct:lm,predicate:fm,represent:dm})});var gs=A((Y0,sl)=>{"use strict";var il=jn(),ol=new il.Schema({include:[ai()],explicit:[tl(),rl()]});il.Schema.DEFAULT=ol;sl.exports=ol});var vl=A((wt,hr)=>{"use strict";Object.defineProperty(wt,"__esModule",{value:!0});wt.safeLoad=wt.safeLoadAll=wt.load=wt.loadAll=void 0;var et=Ft(),Qt=gn(),_s=Mn(),Rs=lu(),ll=ai(),pm=gs(),li=Object.prototype.hasOwnProperty,ci=1,dl=2,fl=3,ui=4,ms=1,gm=2,al=3,mm=/[\x00-\x08\x0B\x0C\x0E-\x1F\x7F-\x84\x86-\x9F\uFFFE\uFFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF]/,hm=/[\x85\u2028\u2029]/,ym=/[,\[\]\{\}]/,pl=/^(?:!|!!|![a-z\-]+!)$/i,gl=/^(?:!|[^,\[\]\{\}])(?:%[0-9a-f]{2}|[0-9a-z\-#;\/\?:@&=\+\$,_\.!~\*'\(\)\[\]])*$/i;function mt(e){return e===10||e===13}function yn(e){return e===9||e===32}function Ze(e){return e===9||e===32||e===10||e===13}function Ln(e){return e===44||e===91||e===93||e===123||e===125}function bm(e){var t;return 48<=e&&e<=57?e-48:(t=e|32,97<=t&&t<=102?t-97+10:-1)}function vm(e){return e===120?2:e===117?4:e===85?8:0}function Cm(e){return 48<=e&&e<=57?e-48:-1}function Pm(e){return e===48?"\0":e===97?"\x07":e===98?"\b":e===116||e===9?" ":e===110?`
7
7
  `:e===118?"\v":e===102?"\f":e===114?"\r":e===101?"\x1B":e===32?" ":e===34?'"':e===47?"/":e===92?"\\":e===78?"\x85":e===95?"\xA0":e===76?"\u2028":e===80?"\u2029":""}function _m(e){return e<=65535?String.fromCharCode(e):String.fromCharCode((e-65536>>10)+55296,(e-65536&1023)+56320)}var hs=new Array(256),ys=new Array(256),ml=new Array(256),bs=new Array(256);for(st=0;st<256;st++)bs[st]=ys[st]=Pm(st),hs[st]=ys[st]?1:0,ml[st]=1,hs[st]||(bs[st]="\\"+String.fromCharCode(st));var st,vs=class{constructor(t,n){this.errorMap={},this.errors=[],this.lines=[],this.input=t,this.filename=n.filename||null,this.schema=n.schema||pm,this.onWarning=n.onWarning||null,this.legacy=n.legacy||!1,this.allowAnyEscape=n.allowAnyEscape||!1,this.ignoreDuplicateKeys=n.ignoreDuplicateKeys||!1,this.implicitTypes=this.schema.compiledImplicit,this.typeMap=this.schema.compiledTypeMap,this.length=t.length,this.position=0,this.line=0,this.lineStart=0,this.lineIndent=0,this.documents=[]}};function Ds(e,t,n=!1){return new _s(t,new Rs(e.filename,e.input,e.position,e.line,e.position-e.lineStart),n)}function Cs(e,t,n,r=!1,i=!1){var o=Rm(e,t);if(!!o){var s=n+t;if(!e.errorMap[s]){var u=new Rs(e.filename,e.input,t,o.line,t-o.start);i&&(u.toLineEnd=!0);var c=new _s(n,u,r);e.errors.push(c)}}}function Y(e,t){var n=Ds(e,t),r=n.message+n.mark.position;if(!e.errorMap[r]){e.errors.push(n),e.errorMap[r]=1;for(var i=e.position;;){if(e.position>=e.input.length-1)return;var o=e.input.charAt(e.position);if(o==`
8
8
  `){e.position--,e.position==i&&(e.position+=1);return}if(o=="\r"){e.position--,e.position==i&&(e.position+=1);return}e.position++}}}function Ps(e,t){var n=Ds(e,t);e.onWarning&&e.onWarning.call(null,n)}var cl={YAML:function(t,n,r){var i,o,s;t.version!==null&&Y(t,"duplication of %YAML directive"),r.length!==1&&Y(t,"YAML directive accepts exactly one argument"),i=/^([0-9]+)\.([0-9]+)$/.exec(r[0]),i===null&&Y(t,"ill-formed argument of the YAML directive"),o=parseInt(i[1],10),s=parseInt(i[2],10),o!==1&&Y(t,"found incompatible YAML document (version 1.2 is required)"),t.version=r[0],t.checkLineBreaks=s<2,s!==2&&Y(t,"found incompatible YAML document (version 1.2 is required)")},TAG:function(t,n,r){var i,o;r.length!==2&&Y(t,"TAG directive accepts exactly two arguments"),i=r[0],o=r[1],pl.test(i)||Y(t,"ill-formed tag handle (first argument) of the TAG directive"),li.call(t.tagMap,i)&&Y(t,'there is a previously declared suffix for "'+i+'" tag handle'),gl.test(o)||Y(t,"ill-formed tag prefix (second argument) of the TAG directive"),t.tagMap[i]=o}};function Xt(e,t,n,r){var i,o,s,u,c=e.result;if(c.startPosition==-1&&(c.startPosition=t),t<=n){if(u=e.input.slice(t,n),r)for(i=0,o=u.length;i<o;i+=1)s=u.charCodeAt(i),s===9||32<=s&&s<=1114111||Y(e,"expected valid JSON character");else mm.test(u)&&Y(e,"the stream contains non-printable characters");c.value+=u,c.endPosition=n}}function hn(e,t,n,r,i,o){if(r!=null){var s=i?i.endPosition:r.endPosition;!i&&e.input.charAt(s)===":"&&s++,t===null&&(t={startPosition:r.startPosition,endPosition:s,parent:null,errors:[],mappings:[],kind:et.Kind.MAP,nodeIndent:o});var u=et.newMapping(r,i,o);return u.parent=t,r.parent=u,i==null?u.endPosition=r.endPosition:i.parent=u,!e.ignoreDuplicateKeys&&t.mappings.forEach(c=>{et.isNodesEqual(c,u)&&(Cs(e,u.key.startPosition,"duplicate key"),Cs(e,c.key.startPosition,"duplicate key"))}),t.mappings.push(u),t.endPosition=s,t}}function Ss(e){var t;t=e.input.charCodeAt(e.position),t===10?e.position++:t===13?(e.position++,e.input.charCodeAt(e.position)===10&&e.position++):Y(e,"a line break is expected"),e.line+=1,e.lineStart=e.position,e.lines.push({start:e.lineStart,line:e.line})}function Rm(e,t){for(var n,r=0;r<e.lines.length&&!(e.lines[r].start>t);r++)n=e.lines[r];return n||{start:0,line:0}}function be(e,t,n,r=!1){for(var i=0,o=e.input.charCodeAt(e.position);o!==0;){for(;yn(o);)o===9&&e.errors.push(Ds(e,"Using tabs can lead to unpredictable results",!0)),o=e.input.charCodeAt(++e.position);if(t&&o===35)do o=e.input.charCodeAt(++e.position);while(o!==10&&o!==13&&o!==0);if(mt(o))for(Ss(e),o=e.input.charCodeAt(e.position),i++,e.lineIndent=0;o===32;)e.lineIndent++,o=e.input.charCodeAt(++e.position);else break}return n!==-1&&i!==0&&e.lineIndent<n&&Ps(e,"deficient indentation"),i}function mr(e){var t=e.position,n;return n=e.input.charCodeAt(t),!!((n===45||n===46)&&e.input.charCodeAt(t+1)===n&&e.input.charCodeAt(t+2)===n&&(t+=3,n=e.input.charCodeAt(t),n===0||Ze(n)))}function Ts(e,t,n){n===1?t.value+=" ":n>1&&(t.value+=Qt.repeat(`
9
- `,n-1))}function Dm(e,t,n){var r,i,o,s,u,c,p,g,b=e.kind,R=e.result,D,T=et.newScalar("",t);if(T.plainScalar=!0,e.result=T,D=e.input.charCodeAt(e.position),Ze(D)||jn(D)||D===35||D===38||D===42||D===33||D===124||D===62||D===39||D===34||D===37||D===64||D===96)return e.result.startPosition=e.position-1,e.result.endPosition=e.position-1,!1;if((D===63||D===45)&&(i=e.input.charCodeAt(e.position+1),Ze(i)||n&&jn(i)))return!1;for(e.kind="scalar",o=s=e.position,u=!1;D!==0;){if(D===58){if(i=e.input.charCodeAt(e.position+1),Ze(i)||n&&jn(i))break}else if(D===35){if(r=e.input.charCodeAt(e.position-1),Ze(r))break}else{if(e.position===e.lineStart&&mr(e)||n&&jn(D))break;if(mt(D))if(c=e.line,p=e.lineStart,g=e.lineIndent,be(e,!1,-1),e.lineIndent>=t){u=!0,D=e.input.charCodeAt(e.position);continue}else{e.position=s,e.line=c,e.lineStart=p,e.lineIndent=g;break}}if(u&&(Xt(e,o,s,!1),Ts(e,T,e.line-c),o=s=e.position,u=!1),yn(D)||(s=e.position+1),D=e.input.charCodeAt(++e.position),e.position>=e.input.length)return!1}return Xt(e,o,s,!1),e.result.startPosition!=-1?(T.rawValue=e.input.substring(T.startPosition,T.endPosition),e.result.endPosition=be(e,!1,-1)?e.position-1:e.position,!0):(e.kind=b,e.result=R,!1)}function Sm(e,t){var n,r,i;if(n=e.input.charCodeAt(e.position),n!==39)return!1;var o=et.newScalar("",t);for(o.singleQuoted=!0,e.kind="scalar",e.result=o,o.startPosition=e.position,e.position++,r=i=e.position;(n=e.input.charCodeAt(e.position))!==0;)if(n===39)if(Xt(e,r,e.position,!0),n=e.input.charCodeAt(++e.position),o.endPosition=e.position,n===39)r=i=e.position,e.position++;else return!0;else mt(n)?(Xt(e,r,i,!0),Ts(e,o,be(e,!1,t)),r=i=e.position):e.position===e.lineStart&&mr(e)?Y(e,"unexpected end of the document within a single quoted scalar"):(e.position++,i=e.position,o.endPosition=e.position);Y(e,"unexpected end of the stream within a single quoted scalar")}function Tm(e,t){var n,r,i,o,s,u,c;if(c=e.input.charCodeAt(e.position),c!==34)return!1;e.kind="scalar";var p=et.newScalar("",t);for(p.doubleQuoted=!0,e.result=p,p.startPosition=e.position,e.position++,n=r=e.position;(c=e.input.charCodeAt(e.position))!==0;){if(c===34)return Xt(e,n,e.position,!0),e.position++,p.endPosition=e.position,p.rawValue=e.input.substring(p.startPosition,p.endPosition),!0;if(c===92){if(Xt(e,n,e.position,!0),c=e.input.charCodeAt(++e.position),mt(c))be(e,!1,t);else if(c<256&&(e.allowAnyEscape?ml[c]:hs[c]))p.value+=e.allowAnyEscape?bs[c]:ys[c],e.position++;else if((s=vm(c))>0){for(i=s,o=0;i>0;i--)c=e.input.charCodeAt(++e.position),(s=bm(c))>=0?o=(o<<4)+s:Y(e,"expected hexadecimal character");p.value+=_m(o),e.position++}else Y(e,"unknown escape sequence");n=r=e.position}else mt(c)?(Xt(e,n,r,!0),Ts(e,p,be(e,!1,t)),n=r=e.position):e.position===e.lineStart&&mr(e)?Y(e,"unexpected end of the document within a double quoted scalar"):(e.position++,r=e.position)}Y(e,"unexpected end of the stream within a double quoted scalar")}function xm(e,t){var n=!0,r,i=e.tag,o,s=e.anchor,u,c,p,g,b,R,D,T,q;if(q=e.input.charCodeAt(e.position),q===91)c=93,b=!1,o=et.newItems(),o.startPosition=e.position;else if(q===123)c=125,b=!0,o=et.newMap(null,t),o.startPosition=e.position;else return!1;for(e.anchor!==null&&(o.anchorId=e.anchor,e.anchorMap[e.anchor]=o),q=e.input.charCodeAt(++e.position);q!==0;){if(be(e,!0,t),q=e.input.charCodeAt(e.position),q===c)return e.position++,e.tag=i,e.anchor=s,e.kind=b?"mapping":"sequence",e.result=o,o.endPosition=e.position,!0;if(!n){var B=e.position;Y(e,"missed comma between flow collection entries"),e.position=B+1}if(D=R=T=null,p=g=!1,q===63&&(u=e.input.charCodeAt(e.position+1),Ze(u)&&(p=g=!0,e.position++,be(e,!0,t))),r=e.line,Ln(e,t,ci,!1,!0),D=e.tag,R=e.result,be(e,!0,t),q=e.input.charCodeAt(e.position),(g||e.line===r)&&q===58&&(p=!0,q=e.input.charCodeAt(++e.position),be(e,!0,t),Ln(e,t,ci,!1,!0),T=e.result),b)hn(e,o,D,R,T,t);else if(p){var L=hn(e,null,D,R,T,t);L.parent=o,o.items.push(L)}else R&&(R.parent=o),o.items.push(R);o.endPosition=e.position+1,be(e,!0,t),q=e.input.charCodeAt(e.position),q===44?(n=!0,q=e.input.charCodeAt(++e.position)):n=!1}Y(e,"unexpected end of the stream within a flow collection")}function wm(e,t){var n,r,i=ms,o=!1,s=t,u=0,c=!1,p,g;if(g=e.input.charCodeAt(e.position),g===124)r=!1;else if(g===62)r=!0;else return!1;var b=et.newScalar("",t);for(e.kind="scalar",e.result=b,b.startPosition=e.position;g!==0;)if(g=e.input.charCodeAt(++e.position),g===43||g===45)ms===i?i=g===43?al:gm:Y(e,"repeat of a chomping mode identifier");else if((p=Cm(g))>=0)p===0?Y(e,"bad explicit indentation width of a block scalar; it cannot be less than one"):o?Y(e,"repeat of an indentation width identifier"):(s=t+p-1,o=!0);else break;if(yn(g)){do g=e.input.charCodeAt(++e.position);while(yn(g));if(g===35)do g=e.input.charCodeAt(++e.position);while(!mt(g)&&g!==0)}for(;g!==0;){for(Ss(e),e.lineIndent=0,g=e.input.charCodeAt(e.position);(!o||e.lineIndent<s)&&g===32;)e.lineIndent++,g=e.input.charCodeAt(++e.position);if(!o&&e.lineIndent>s&&(s=e.lineIndent),mt(g)){u++;continue}if(e.lineIndent<s){i===al?b.value+=Qt.repeat(`
9
+ `,n-1))}function Dm(e,t,n){var r,i,o,s,u,c,p,g,b=e.kind,R=e.result,D,T=et.newScalar("",t);if(T.plainScalar=!0,e.result=T,D=e.input.charCodeAt(e.position),Ze(D)||Ln(D)||D===35||D===38||D===42||D===33||D===124||D===62||D===39||D===34||D===37||D===64||D===96)return e.result.startPosition=e.position-1,e.result.endPosition=e.position-1,!1;if((D===63||D===45)&&(i=e.input.charCodeAt(e.position+1),Ze(i)||n&&Ln(i)))return!1;for(e.kind="scalar",o=s=e.position,u=!1;D!==0;){if(D===58){if(i=e.input.charCodeAt(e.position+1),Ze(i)||n&&Ln(i))break}else if(D===35){if(r=e.input.charCodeAt(e.position-1),Ze(r))break}else{if(e.position===e.lineStart&&mr(e)||n&&Ln(D))break;if(mt(D))if(c=e.line,p=e.lineStart,g=e.lineIndent,be(e,!1,-1),e.lineIndent>=t){u=!0,D=e.input.charCodeAt(e.position);continue}else{e.position=s,e.line=c,e.lineStart=p,e.lineIndent=g;break}}if(u&&(Xt(e,o,s,!1),Ts(e,T,e.line-c),o=s=e.position,u=!1),yn(D)||(s=e.position+1),D=e.input.charCodeAt(++e.position),e.position>=e.input.length)return!1}return Xt(e,o,s,!1),e.result.startPosition!=-1?(T.rawValue=e.input.substring(T.startPosition,T.endPosition),e.result.endPosition=be(e,!1,-1)?e.position-1:e.position,!0):(e.kind=b,e.result=R,!1)}function Sm(e,t){var n,r,i;if(n=e.input.charCodeAt(e.position),n!==39)return!1;var o=et.newScalar("",t);for(o.singleQuoted=!0,e.kind="scalar",e.result=o,o.startPosition=e.position,e.position++,r=i=e.position;(n=e.input.charCodeAt(e.position))!==0;)if(n===39)if(Xt(e,r,e.position,!0),n=e.input.charCodeAt(++e.position),o.endPosition=e.position,n===39)r=i=e.position,e.position++;else return!0;else mt(n)?(Xt(e,r,i,!0),Ts(e,o,be(e,!1,t)),r=i=e.position):e.position===e.lineStart&&mr(e)?Y(e,"unexpected end of the document within a single quoted scalar"):(e.position++,i=e.position,o.endPosition=e.position);Y(e,"unexpected end of the stream within a single quoted scalar")}function Tm(e,t){var n,r,i,o,s,u,c;if(c=e.input.charCodeAt(e.position),c!==34)return!1;e.kind="scalar";var p=et.newScalar("",t);for(p.doubleQuoted=!0,e.result=p,p.startPosition=e.position,e.position++,n=r=e.position;(c=e.input.charCodeAt(e.position))!==0;){if(c===34)return Xt(e,n,e.position,!0),e.position++,p.endPosition=e.position,p.rawValue=e.input.substring(p.startPosition,p.endPosition),!0;if(c===92){if(Xt(e,n,e.position,!0),c=e.input.charCodeAt(++e.position),mt(c))be(e,!1,t);else if(c<256&&(e.allowAnyEscape?ml[c]:hs[c]))p.value+=e.allowAnyEscape?bs[c]:ys[c],e.position++;else if((s=vm(c))>0){for(i=s,o=0;i>0;i--)c=e.input.charCodeAt(++e.position),(s=bm(c))>=0?o=(o<<4)+s:Y(e,"expected hexadecimal character");p.value+=_m(o),e.position++}else Y(e,"unknown escape sequence");n=r=e.position}else mt(c)?(Xt(e,n,r,!0),Ts(e,p,be(e,!1,t)),n=r=e.position):e.position===e.lineStart&&mr(e)?Y(e,"unexpected end of the document within a double quoted scalar"):(e.position++,r=e.position)}Y(e,"unexpected end of the stream within a double quoted scalar")}function xm(e,t){var n=!0,r,i=e.tag,o,s=e.anchor,u,c,p,g,b,R,D,T,q;if(q=e.input.charCodeAt(e.position),q===91)c=93,b=!1,o=et.newItems(),o.startPosition=e.position;else if(q===123)c=125,b=!0,o=et.newMap(null,t),o.startPosition=e.position;else return!1;for(e.anchor!==null&&(o.anchorId=e.anchor,e.anchorMap[e.anchor]=o),q=e.input.charCodeAt(++e.position);q!==0;){if(be(e,!0,t),q=e.input.charCodeAt(e.position),q===c)return e.position++,e.tag=i,e.anchor=s,e.kind=b?"mapping":"sequence",e.result=o,o.endPosition=e.position,!0;if(!n){var B=e.position;Y(e,"missed comma between flow collection entries"),e.position=B+1}if(D=R=T=null,p=g=!1,q===63&&(u=e.input.charCodeAt(e.position+1),Ze(u)&&(p=g=!0,e.position++,be(e,!0,t))),r=e.line,In(e,t,ci,!1,!0),D=e.tag,R=e.result,be(e,!0,t),q=e.input.charCodeAt(e.position),(g||e.line===r)&&q===58&&(p=!0,q=e.input.charCodeAt(++e.position),be(e,!0,t),In(e,t,ci,!1,!0),T=e.result),b)hn(e,o,D,R,T,t);else if(p){var L=hn(e,null,D,R,T,t);L.parent=o,o.items.push(L)}else R&&(R.parent=o),o.items.push(R);o.endPosition=e.position+1,be(e,!0,t),q=e.input.charCodeAt(e.position),q===44?(n=!0,q=e.input.charCodeAt(++e.position)):n=!1}Y(e,"unexpected end of the stream within a flow collection")}function wm(e,t){var n,r,i=ms,o=!1,s=t,u=0,c=!1,p,g;if(g=e.input.charCodeAt(e.position),g===124)r=!1;else if(g===62)r=!0;else return!1;var b=et.newScalar("",t);for(e.kind="scalar",e.result=b,b.startPosition=e.position;g!==0;)if(g=e.input.charCodeAt(++e.position),g===43||g===45)ms===i?i=g===43?al:gm:Y(e,"repeat of a chomping mode identifier");else if((p=Cm(g))>=0)p===0?Y(e,"bad explicit indentation width of a block scalar; it cannot be less than one"):o?Y(e,"repeat of an indentation width identifier"):(s=t+p-1,o=!0);else break;if(yn(g)){do g=e.input.charCodeAt(++e.position);while(yn(g));if(g===35)do g=e.input.charCodeAt(++e.position);while(!mt(g)&&g!==0)}for(;g!==0;){for(Ss(e),e.lineIndent=0,g=e.input.charCodeAt(e.position);(!o||e.lineIndent<s)&&g===32;)e.lineIndent++,g=e.input.charCodeAt(++e.position);if(!o&&e.lineIndent>s&&(s=e.lineIndent),mt(g)){u++;continue}if(e.lineIndent<s){i===al?b.value+=Qt.repeat(`
10
10
  `,u):i===ms&&o&&(b.value+=`
11
11
  `);break}for(r?yn(g)?(c=!0,b.value+=Qt.repeat(`
12
12
  `,u+1)):c?(c=!1,b.value+=Qt.repeat(`
13
13
  `,u+1)):u===0?o&&(b.value+=" "):b.value+=Qt.repeat(`
14
14
  `,u):o&&(b.value+=Qt.repeat(`
15
15
  `,u+1)),o=!0,u=0,n=e.position;!mt(g)&&g!==0;)g=e.input.charCodeAt(++e.position);Xt(e,n,e.position,!1)}b.endPosition=e.position;for(var R=e.position-1,D=!1;;){var T=e.input[R];if(T=="\r"||T==`
16
- `){D&&R--;break}if(T!=" "&&T!=" ")break;R--}return b.endPosition=R,b.rawValue=e.input.substring(b.startPosition,b.endPosition),!0}function ul(e,t){var n,r=e.tag,i=e.anchor,o=et.newItems(),s,u=!1,c;for(e.anchor!==null&&(o.anchorId=e.anchor,e.anchorMap[e.anchor]=o),o.startPosition=e.position,c=e.input.charCodeAt(e.position);c!==0&&!(c!==45||(s=e.input.charCodeAt(e.position+1),!Ze(s)));){if(u=!0,e.position++,be(e,!0,-1)&&e.lineIndent<=t){o.items.push(null),c=e.input.charCodeAt(e.position);continue}if(n=e.line,Ln(e,t,fl,!1,!0),e.result&&(e.result.parent=o,o.items.push(e.result)),o.endPosition=be(e,!0,t,!0)?e.position-1:e.position,c=e.input.charCodeAt(e.position),(e.line===n||e.lineIndent>t)&&c!==0)Y(e,"bad indentation of a sequence entry");else if(e.lineIndent<t)break}return u?(e.tag=r,e.anchor=i,e.kind="sequence",e.result=o,!0):!1}function km(e,t,n){var r,i,o,s=e.tag,u=e.anchor,c=et.newMap(null,t),p=null,g=null,b=null,R=!1,D=!1,T;for(c.startPosition=e.position,e.anchor!==null&&(c.anchorId=e.anchor,e.anchorMap[e.anchor]=c),T=e.input.charCodeAt(e.position);T!==0;){if(r=e.input.charCodeAt(e.position+1),o=e.line,(T===63||T===58)&&Ze(r))T===63?(R&&(hn(e,c,p,g,null,t),p=g=b=null),D=!0,R=!0,i=!0):R?(R=!1,i=!0):Y(e,"incomplete explicit mapping pair; a key node is missed"),e.position+=1,T=r;else if(Ln(e,n,dl,!1,!0))if(e.line===o){for(T=e.input.charCodeAt(e.position);yn(T);)T=e.input.charCodeAt(++e.position);if(T===58)T=e.input.charCodeAt(++e.position),Ze(T)||Y(e,"a whitespace character is expected after the key-value separator within a block mapping"),R&&(hn(e,c,p,g,null,t),p=g=b=null),D=!0,R=!1,i=!1,p=e.tag,g=e.result;else{if(e.position==e.lineStart&&mr(e))break;if(D)Y(e,"can not read an implicit mapping pair; a colon is missed");else return e.tag=s,e.anchor=u,!0}}else if(D){for(Y(e,"can not read a block mapping entry; a multiline key may not be an implicit key");e.position>0;)if(T=e.input.charCodeAt(--e.position),mt(T)){e.position++;break}g=e.result,g.value=e.input.substring(e.result.startPosition,e.position-1),g.rawValue=g.value,g.endPosition=e.position-1,hn(e,c,p,g,null,t)}else return e.tag=s,e.anchor=u,!0;else break;if(e.line===o||e.lineIndent>t){let q=e.line;Ln(e,t,ui,!0,i)?(be(e,!0,t),R?g=e.result:(b=e.result,b.endPosition=e.line===q?e.position:e.position-1)):g&&(g.endPosition=e.line===q?e.position:e.position-1),R||(hn(e,c,p,g,b,t),p=g=b=null),be(e,!0,-1),T=e.input.charCodeAt(e.position)}if(e.lineIndent>t&&T!==0)Y(e,"bad indentation of a mapping entry"+e.position),T=e.input.charCodeAt(++e.position),be(e,!0,-1);else if(e.lineIndent<t)break}return R&&hn(e,c,p,g,null,t),D&&(e.tag=s,e.anchor=u,e.kind="mapping",e.result=c),D}function Am(e){var t,n=!1,r=!1,i,o,s;if(s=e.input.charCodeAt(e.position),s!==33)return!1;if(e.tag!==null&&Y(e,"duplication of a tag property"),s=e.input.charCodeAt(++e.position),s===60?(n=!0,s=e.input.charCodeAt(++e.position)):s===33?(r=!0,i="!!",s=e.input.charCodeAt(++e.position)):i="!",t=e.position,n){do s=e.input.charCodeAt(++e.position);while(s!==0&&s!==62);e.position<e.length?(o=e.input.slice(t,e.position),s=e.input.charCodeAt(++e.position)):Y(e,"unexpected end of the stream within a verbatim tag")}else{for(;s!==0&&!Ze(s);)s===33&&(r?Y(e,"tag suffix cannot contain exclamation marks"):(i=e.input.slice(t-1,e.position+1),pl.test(i)||Y(e,"named tag handle cannot contain such characters"),r=!0,t=e.position+1)),s=e.input.charCodeAt(++e.position);o=e.input.slice(t,e.position),ym.test(o)&&Y(e,"tag suffix cannot contain flow indicator characters")}return o&&!gl.test(o)&&Y(e,"tag name cannot contain such characters: "+o),n?e.tag=o:li.call(e.tagMap,i)?e.tag=e.tagMap[i]+o:i==="!"?e.tag="!"+o:i==="!!"?e.tag="tag:yaml.org,2002:"+o:Y(e,'undeclared tag handle "'+i+'"'),!0}function qm(e){var t,n;if(n=e.input.charCodeAt(e.position),n!==38)return!1;for(e.anchor!==null&&Y(e,"duplication of an anchor property"),n=e.input.charCodeAt(++e.position),t=e.position;n!==0&&!Ze(n)&&!jn(n);)n=e.input.charCodeAt(++e.position);return e.position===t&&Y(e,"name of an anchor node must contain at least one character"),e.anchor=e.input.slice(t,e.position),!0}function Nm(e){var t,n,r=e.length,i=e.input,o;if(o=e.input.charCodeAt(e.position),o!==42)return!1;for(o=e.input.charCodeAt(++e.position),t=e.position;o!==0&&!Ze(o)&&!jn(o);)o=e.input.charCodeAt(++e.position);return e.position<=t&&(Y(e,"name of an alias node must contain at least one character"),e.position=t+1),n=e.input.slice(t,e.position),e.anchorMap.hasOwnProperty(n)||(Y(e,'unidentified alias "'+n+'"'),e.position<=t&&(e.position=t+1)),e.result=et.newAnchorRef(n,t,e.position,e.anchorMap[n],0),be(e,!0,-1),!0}function Ln(e,t,n,r,i){var o,s,u,c=1,p=!1,g=!1,b,R,D,T,q,B;e.tag=null,e.anchor=null,e.kind=null,e.result=null,o=s=u=ui===n||fl===n,r&&be(e,!0,-1)&&(p=!0,e.lineIndent>t?c=1:e.lineIndent===t?c=0:e.lineIndent<t&&(c=-1));let L=e.position;if(c===1)for(;Am(e)||qm(e);)be(e,!0,-1)?(p=!0,u=o,e.lineIndent>t?c=1:e.lineIndent===t?c=0:e.lineIndent<t&&(c=-1)):u=!1;if(u&&(u=p||i),(c===1||ui===n)&&(ci===n||dl===n?T=t:T=t+1,q=e.position-e.lineStart,c===1?u&&(ul(e,q)||km(e,q,T))||xm(e,T)?g=!0:(s&&wm(e,T)||Sm(e,T)||Tm(e,T)?g=!0:Nm(e)?(g=!0,(e.tag!==null||e.anchor!==null)&&Y(e,"alias node should not have any properties")):Dm(e,T,ci===n)&&(g=!0,e.tag===null&&(e.tag="?")),e.anchor!==null&&(e.anchorMap[e.anchor]=e.result,e.result.anchorId=e.anchor)):c===0&&(g=u&&ul(e,q))),e.tag!==null&&e.tag!=="!")if(e.tag=="!include")e.result||(e.result=et.newScalar("",q),e.result.startPosition=e.position,e.result.endPosition=e.position,Y(e,"!include without value")),e.result.kind=et.Kind.INCLUDE_REF;else if(e.tag==="?")for(b=0,R=e.implicitTypes.length;b<R;b+=1){D=e.implicitTypes[b];var _=e.result.value;if(D.resolve(_)){e.result.valueObject=D.construct(e.result.value),e.tag=D.tag,e.anchor!==null&&(e.result.anchorId=e.anchor,e.anchorMap[e.anchor]=e.result);break}}else li.call(e.typeMap,e.tag)?(D=e.typeMap[e.tag],e.result!==null&&D.kind!==e.kind&&(!D.additionalKinds||D.additionalKinds&&D.additionalKinds.indexOf(e.kind)===-1)&&Y(e,"unacceptable node kind for !<"+e.tag+'> tag; it should be "'+D.kind+'", not "'+e.kind+'"'),D.resolve(e.result)?(e.result=D.construct(e.result),e.anchor!==null&&(e.result.anchorId=e.anchor,e.anchorMap[e.anchor]=e.result)):Y(e,"cannot resolve a node with !<"+e.tag+"> explicit tag")):Cs(e,L,"unknown tag <"+e.tag+">",!1,!0);return e.tag!==null||e.anchor!==null||g}function Om(e){var t=e.position,n,r,i,o=!1,s;for(e.version=null,e.checkLineBreaks=e.legacy,e.tagMap={},e.anchorMap={};(s=e.input.charCodeAt(e.position))!==0&&(be(e,!0,-1),s=e.input.charCodeAt(e.position),!(e.lineIndent>0||s!==37));){for(o=!0,s=e.input.charCodeAt(++e.position),n=e.position;s!==0&&!Ze(s);)s=e.input.charCodeAt(++e.position);for(r=e.input.slice(n,e.position),i=[],r.length<1&&Y(e,"directive name must not be less than one character in length");s!==0;){for(;yn(s);)s=e.input.charCodeAt(++e.position);if(s===35){do s=e.input.charCodeAt(++e.position);while(s!==0&&!mt(s));break}if(mt(s))break;for(n=e.position;s!==0&&!Ze(s);)s=e.input.charCodeAt(++e.position);i.push(e.input.slice(n,e.position))}s!==0&&Ss(e),li.call(cl,r)?cl[r](e,r,i):(Ps(e,'unknown document directive "'+r+'"'),e.position++)}if(be(e,!0,-1),e.lineIndent===0&&e.input.charCodeAt(e.position)===45&&e.input.charCodeAt(e.position+1)===45&&e.input.charCodeAt(e.position+2)===45?(e.position+=3,be(e,!0,-1)):o&&Y(e,"directives end mark is expected"),Ln(e,e.lineIndent-1,ui,!1,!0),be(e,!0,-1),e.checkLineBreaks&&hm.test(e.input.slice(t,e.position))&&Ps(e,"non-ASCII line breaks are interpreted as content"),e.documents.push(e.result),e.position===e.lineStart&&mr(e)){e.input.charCodeAt(e.position)===46&&(e.position+=3,be(e,!0,-1));return}if(e.position<e.length-1)Y(e,"end of the stream or a document separator is expected");else return}function hl(e,t){e=String(e),t=t||{};let n=e.length;n!==0&&(e.charCodeAt(n-1)!==10&&e.charCodeAt(n-1)!==13&&(e+=`
16
+ `){D&&R--;break}if(T!=" "&&T!=" ")break;R--}return b.endPosition=R,b.rawValue=e.input.substring(b.startPosition,b.endPosition),!0}function ul(e,t){var n,r=e.tag,i=e.anchor,o=et.newItems(),s,u=!1,c;for(e.anchor!==null&&(o.anchorId=e.anchor,e.anchorMap[e.anchor]=o),o.startPosition=e.position,c=e.input.charCodeAt(e.position);c!==0&&!(c!==45||(s=e.input.charCodeAt(e.position+1),!Ze(s)));){if(u=!0,e.position++,be(e,!0,-1)&&e.lineIndent<=t){o.items.push(null),c=e.input.charCodeAt(e.position);continue}if(n=e.line,In(e,t,fl,!1,!0),e.result&&(e.result.parent=o,o.items.push(e.result)),o.endPosition=be(e,!0,t,!0)?e.position-1:e.position,c=e.input.charCodeAt(e.position),(e.line===n||e.lineIndent>t)&&c!==0)Y(e,"bad indentation of a sequence entry");else if(e.lineIndent<t)break}return u?(e.tag=r,e.anchor=i,e.kind="sequence",e.result=o,!0):!1}function km(e,t,n){var r,i,o,s=e.tag,u=e.anchor,c=et.newMap(null,t),p=null,g=null,b=null,R=!1,D=!1,T;for(c.startPosition=e.position,e.anchor!==null&&(c.anchorId=e.anchor,e.anchorMap[e.anchor]=c),T=e.input.charCodeAt(e.position);T!==0;){if(r=e.input.charCodeAt(e.position+1),o=e.line,(T===63||T===58)&&Ze(r))T===63?(R&&(hn(e,c,p,g,null,t),p=g=b=null),D=!0,R=!0,i=!0):R?(R=!1,i=!0):Y(e,"incomplete explicit mapping pair; a key node is missed"),e.position+=1,T=r;else if(In(e,n,dl,!1,!0))if(e.line===o){for(T=e.input.charCodeAt(e.position);yn(T);)T=e.input.charCodeAt(++e.position);if(T===58)T=e.input.charCodeAt(++e.position),Ze(T)||Y(e,"a whitespace character is expected after the key-value separator within a block mapping"),R&&(hn(e,c,p,g,null,t),p=g=b=null),D=!0,R=!1,i=!1,p=e.tag,g=e.result;else{if(e.position==e.lineStart&&mr(e))break;if(D)Y(e,"can not read an implicit mapping pair; a colon is missed");else return e.tag=s,e.anchor=u,!0}}else if(D){for(Y(e,"can not read a block mapping entry; a multiline key may not be an implicit key");e.position>0;)if(T=e.input.charCodeAt(--e.position),mt(T)){e.position++;break}g=e.result,g.value=e.input.substring(e.result.startPosition,e.position-1),g.rawValue=g.value,g.endPosition=e.position-1,hn(e,c,p,g,null,t)}else return e.tag=s,e.anchor=u,!0;else break;if(e.line===o||e.lineIndent>t){let q=e.line;In(e,t,ui,!0,i)?(be(e,!0,t),R?g=e.result:(b=e.result,b.endPosition=e.line===q?e.position:e.position-1)):g&&(g.endPosition=e.line===q?e.position:e.position-1),R||(hn(e,c,p,g,b,t),p=g=b=null),be(e,!0,-1),T=e.input.charCodeAt(e.position)}if(e.lineIndent>t&&T!==0)Y(e,"bad indentation of a mapping entry"+e.position),T=e.input.charCodeAt(++e.position),be(e,!0,-1);else if(e.lineIndent<t)break}return R&&hn(e,c,p,g,null,t),D&&(e.tag=s,e.anchor=u,e.kind="mapping",e.result=c),D}function Am(e){var t,n=!1,r=!1,i,o,s;if(s=e.input.charCodeAt(e.position),s!==33)return!1;if(e.tag!==null&&Y(e,"duplication of a tag property"),s=e.input.charCodeAt(++e.position),s===60?(n=!0,s=e.input.charCodeAt(++e.position)):s===33?(r=!0,i="!!",s=e.input.charCodeAt(++e.position)):i="!",t=e.position,n){do s=e.input.charCodeAt(++e.position);while(s!==0&&s!==62);e.position<e.length?(o=e.input.slice(t,e.position),s=e.input.charCodeAt(++e.position)):Y(e,"unexpected end of the stream within a verbatim tag")}else{for(;s!==0&&!Ze(s);)s===33&&(r?Y(e,"tag suffix cannot contain exclamation marks"):(i=e.input.slice(t-1,e.position+1),pl.test(i)||Y(e,"named tag handle cannot contain such characters"),r=!0,t=e.position+1)),s=e.input.charCodeAt(++e.position);o=e.input.slice(t,e.position),ym.test(o)&&Y(e,"tag suffix cannot contain flow indicator characters")}return o&&!gl.test(o)&&Y(e,"tag name cannot contain such characters: "+o),n?e.tag=o:li.call(e.tagMap,i)?e.tag=e.tagMap[i]+o:i==="!"?e.tag="!"+o:i==="!!"?e.tag="tag:yaml.org,2002:"+o:Y(e,'undeclared tag handle "'+i+'"'),!0}function qm(e){var t,n;if(n=e.input.charCodeAt(e.position),n!==38)return!1;for(e.anchor!==null&&Y(e,"duplication of an anchor property"),n=e.input.charCodeAt(++e.position),t=e.position;n!==0&&!Ze(n)&&!Ln(n);)n=e.input.charCodeAt(++e.position);return e.position===t&&Y(e,"name of an anchor node must contain at least one character"),e.anchor=e.input.slice(t,e.position),!0}function Nm(e){var t,n,r=e.length,i=e.input,o;if(o=e.input.charCodeAt(e.position),o!==42)return!1;for(o=e.input.charCodeAt(++e.position),t=e.position;o!==0&&!Ze(o)&&!Ln(o);)o=e.input.charCodeAt(++e.position);return e.position<=t&&(Y(e,"name of an alias node must contain at least one character"),e.position=t+1),n=e.input.slice(t,e.position),e.anchorMap.hasOwnProperty(n)||(Y(e,'unidentified alias "'+n+'"'),e.position<=t&&(e.position=t+1)),e.result=et.newAnchorRef(n,t,e.position,e.anchorMap[n],0),be(e,!0,-1),!0}function In(e,t,n,r,i){var o,s,u,c=1,p=!1,g=!1,b,R,D,T,q,B;e.tag=null,e.anchor=null,e.kind=null,e.result=null,o=s=u=ui===n||fl===n,r&&be(e,!0,-1)&&(p=!0,e.lineIndent>t?c=1:e.lineIndent===t?c=0:e.lineIndent<t&&(c=-1));let L=e.position;if(c===1)for(;Am(e)||qm(e);)be(e,!0,-1)?(p=!0,u=o,e.lineIndent>t?c=1:e.lineIndent===t?c=0:e.lineIndent<t&&(c=-1)):u=!1;if(u&&(u=p||i),(c===1||ui===n)&&(ci===n||dl===n?T=t:T=t+1,q=e.position-e.lineStart,c===1?u&&(ul(e,q)||km(e,q,T))||xm(e,T)?g=!0:(s&&wm(e,T)||Sm(e,T)||Tm(e,T)?g=!0:Nm(e)?(g=!0,(e.tag!==null||e.anchor!==null)&&Y(e,"alias node should not have any properties")):Dm(e,T,ci===n)&&(g=!0,e.tag===null&&(e.tag="?")),e.anchor!==null&&(e.anchorMap[e.anchor]=e.result,e.result.anchorId=e.anchor)):c===0&&(g=u&&ul(e,q))),e.tag!==null&&e.tag!=="!")if(e.tag=="!include")e.result||(e.result=et.newScalar("",q),e.result.startPosition=e.position,e.result.endPosition=e.position,Y(e,"!include without value")),e.result.kind=et.Kind.INCLUDE_REF;else if(e.tag==="?")for(b=0,R=e.implicitTypes.length;b<R;b+=1){D=e.implicitTypes[b];var _=e.result.value;if(D.resolve(_)){e.result.valueObject=D.construct(e.result.value),e.tag=D.tag,e.anchor!==null&&(e.result.anchorId=e.anchor,e.anchorMap[e.anchor]=e.result);break}}else li.call(e.typeMap,e.tag)?(D=e.typeMap[e.tag],e.result!==null&&D.kind!==e.kind&&(!D.additionalKinds||D.additionalKinds&&D.additionalKinds.indexOf(e.kind)===-1)&&Y(e,"unacceptable node kind for !<"+e.tag+'> tag; it should be "'+D.kind+'", not "'+e.kind+'"'),D.resolve(e.result)?(e.result=D.construct(e.result),e.anchor!==null&&(e.result.anchorId=e.anchor,e.anchorMap[e.anchor]=e.result)):Y(e,"cannot resolve a node with !<"+e.tag+"> explicit tag")):Cs(e,L,"unknown tag <"+e.tag+">",!1,!0);return e.tag!==null||e.anchor!==null||g}function Om(e){var t=e.position,n,r,i,o=!1,s;for(e.version=null,e.checkLineBreaks=e.legacy,e.tagMap={},e.anchorMap={};(s=e.input.charCodeAt(e.position))!==0&&(be(e,!0,-1),s=e.input.charCodeAt(e.position),!(e.lineIndent>0||s!==37));){for(o=!0,s=e.input.charCodeAt(++e.position),n=e.position;s!==0&&!Ze(s);)s=e.input.charCodeAt(++e.position);for(r=e.input.slice(n,e.position),i=[],r.length<1&&Y(e,"directive name must not be less than one character in length");s!==0;){for(;yn(s);)s=e.input.charCodeAt(++e.position);if(s===35){do s=e.input.charCodeAt(++e.position);while(s!==0&&!mt(s));break}if(mt(s))break;for(n=e.position;s!==0&&!Ze(s);)s=e.input.charCodeAt(++e.position);i.push(e.input.slice(n,e.position))}s!==0&&Ss(e),li.call(cl,r)?cl[r](e,r,i):(Ps(e,'unknown document directive "'+r+'"'),e.position++)}if(be(e,!0,-1),e.lineIndent===0&&e.input.charCodeAt(e.position)===45&&e.input.charCodeAt(e.position+1)===45&&e.input.charCodeAt(e.position+2)===45?(e.position+=3,be(e,!0,-1)):o&&Y(e,"directives end mark is expected"),In(e,e.lineIndent-1,ui,!1,!0),be(e,!0,-1),e.checkLineBreaks&&hm.test(e.input.slice(t,e.position))&&Ps(e,"non-ASCII line breaks are interpreted as content"),e.documents.push(e.result),e.position===e.lineStart&&mr(e)){e.input.charCodeAt(e.position)===46&&(e.position+=3,be(e,!0,-1));return}if(e.position<e.length-1)Y(e,"end of the stream or a document separator is expected");else return}function hl(e,t){e=String(e),t=t||{};let n=e.length;n!==0&&(e.charCodeAt(n-1)!==10&&e.charCodeAt(n-1)!==13&&(e+=`
17
17
  `),e.charCodeAt(0)===65279&&(e=e.slice(1)));var r=new vs(e,t);for(r.input+="\0";r.input.charCodeAt(r.position)===32;)r.lineIndent+=1,r.position+=1;for(;r.position<r.length-1;){var i=r.position;if(Om(r),r.position<=i)for(;r.position<r.length-1;r.position++){var o=r.input.charAt(r.position);if(o==`
18
- `)break}}let s=r.documents,u=s.length;u>0&&(s[u-1].endPosition=n);for(let c of s)c.errors=r.errors,c.startPosition>c.endPosition&&(c.startPosition=c.endPosition);return s}function xs(e,t,n={}){var r=hl(e,n),i,o;for(i=0,o=r.length;i<o;i+=1)t(r[i])}wt.loadAll=xs;function ws(e,t={}){var n=hl(e,t),r,i;if(n.length!==0){if(n.length===1)return n[0];var o=new _s("expected a single document in the stream, but found more");return o.mark=new Rs("","",0,0,0),o.mark.position=n[0].endPosition,n[0].errors.push(o),n[0]}}wt.load=ws;function yl(e,t,n={}){xs(e,t,Qt.extend({schema:ll},n))}wt.safeLoadAll=yl;function bl(e,t={}){return ws(e,Qt.extend({schema:ll},t))}wt.safeLoad=bl;hr.exports.loadAll=xs;hr.exports.load=ws;hr.exports.safeLoadAll=yl;hr.exports.safeLoad=bl});var Tl=A(In=>{"use strict";Object.defineProperty(In,"__esModule",{value:!0});In.safeDump=In.dump=void 0;var yr=gn(),Es=En(),Em=gs(),Mm=ai(),Ms=Object.prototype.toString,Rl=Object.prototype.hasOwnProperty,jm=9,bn=10,Lm=13,ks=32,Im=33,As=34,Fm=35,Wm=37,Hm=38,qs=39,Um=42,Bm=44,zm=45,$m=58,Ym=62,Vm=63,Km=64,Gm=91,Jm=93,Qm=96,Xm=123,Zm=124,eh=125,Ee={};Ee[0]="\\0";Ee[7]="\\a";Ee[8]="\\b";Ee[9]="\\t";Ee[10]="\\n";Ee[11]="\\v";Ee[12]="\\f";Ee[13]="\\r";Ee[27]="\\e";Ee[34]='\\"';Ee[92]="\\\\";Ee[133]="\\N";Ee[160]="\\_";Ee[8232]="\\L";Ee[8233]="\\P";var th=["y","Y","yes","Yes","YES","on","On","ON","n","N","no","No","NO","off","Off","OFF"];function nh(e,t){var n,r,i,o,s,u,c;if(t===null)return{};for(n={},r=Object.keys(t),i=0,o=r.length;i<o;i+=1)s=r[i],u=String(t[s]),s.slice(0,2)==="!!"&&(s="tag:yaml.org,2002:"+s.slice(2)),c=e.compiledTypeMap[s],c&&Rl.call(c.styleAliases,u)&&(u=c.styleAliases[u]),n[s]=u;return n}function rh(e){var t,n,r;if(t=e.toString(16).toUpperCase(),e<=255)n="x",r=2;else if(e<=65535)n="u",r=4;else if(e<=4294967295)n="U",r=8;else throw new Es("code point within a string may not be greater than 0xFFFFFFFF");return"\\"+n+yr.repeat("0",r-t.length)+t}function ih(e){this.schema=e.schema||Em,this.indent=Math.max(1,e.indent||2),this.skipInvalid=e.skipInvalid||!1,this.flowLevel=yr.isNothing(e.flowLevel)?-1:e.flowLevel,this.styleMap=nh(this.schema,e.styles||null),this.implicitTypes=this.schema.compiledImplicit,this.explicitTypes=this.schema.compiledExplicit,this.tag=null,this.result="",this.duplicates=[],this.usedDuplicates=null}function Cl(e,t){for(var n=yr.repeat(" ",t),r=0,i=-1,o="",s,u=e.length;r<u;)i=e.indexOf(`
18
+ `)break}}let s=r.documents,u=s.length;u>0&&(s[u-1].endPosition=n);for(let c of s)c.errors=r.errors,c.startPosition>c.endPosition&&(c.startPosition=c.endPosition);return s}function xs(e,t,n={}){var r=hl(e,n),i,o;for(i=0,o=r.length;i<o;i+=1)t(r[i])}wt.loadAll=xs;function ws(e,t={}){var n=hl(e,t),r,i;if(n.length!==0){if(n.length===1)return n[0];var o=new _s("expected a single document in the stream, but found more");return o.mark=new Rs("","",0,0,0),o.mark.position=n[0].endPosition,n[0].errors.push(o),n[0]}}wt.load=ws;function yl(e,t,n={}){xs(e,t,Qt.extend({schema:ll},n))}wt.safeLoadAll=yl;function bl(e,t={}){return ws(e,Qt.extend({schema:ll},t))}wt.safeLoad=bl;hr.exports.loadAll=xs;hr.exports.load=ws;hr.exports.safeLoadAll=yl;hr.exports.safeLoad=bl});var Tl=A(Fn=>{"use strict";Object.defineProperty(Fn,"__esModule",{value:!0});Fn.safeDump=Fn.dump=void 0;var yr=gn(),Es=Mn(),Em=gs(),Mm=ai(),Ms=Object.prototype.toString,Rl=Object.prototype.hasOwnProperty,jm=9,bn=10,Lm=13,ks=32,Im=33,As=34,Fm=35,Wm=37,Hm=38,qs=39,Um=42,Bm=44,zm=45,$m=58,Ym=62,Vm=63,Km=64,Gm=91,Jm=93,Qm=96,Xm=123,Zm=124,eh=125,Ee={};Ee[0]="\\0";Ee[7]="\\a";Ee[8]="\\b";Ee[9]="\\t";Ee[10]="\\n";Ee[11]="\\v";Ee[12]="\\f";Ee[13]="\\r";Ee[27]="\\e";Ee[34]='\\"';Ee[92]="\\\\";Ee[133]="\\N";Ee[160]="\\_";Ee[8232]="\\L";Ee[8233]="\\P";var th=["y","Y","yes","Yes","YES","on","On","ON","n","N","no","No","NO","off","Off","OFF"];function nh(e,t){var n,r,i,o,s,u,c;if(t===null)return{};for(n={},r=Object.keys(t),i=0,o=r.length;i<o;i+=1)s=r[i],u=String(t[s]),s.slice(0,2)==="!!"&&(s="tag:yaml.org,2002:"+s.slice(2)),c=e.compiledTypeMap[s],c&&Rl.call(c.styleAliases,u)&&(u=c.styleAliases[u]),n[s]=u;return n}function rh(e){var t,n,r;if(t=e.toString(16).toUpperCase(),e<=255)n="x",r=2;else if(e<=65535)n="u",r=4;else if(e<=4294967295)n="U",r=8;else throw new Es("code point within a string may not be greater than 0xFFFFFFFF");return"\\"+n+yr.repeat("0",r-t.length)+t}function ih(e){this.schema=e.schema||Em,this.indent=Math.max(1,e.indent||2),this.skipInvalid=e.skipInvalid||!1,this.flowLevel=yr.isNothing(e.flowLevel)?-1:e.flowLevel,this.styleMap=nh(this.schema,e.styles||null),this.implicitTypes=this.schema.compiledImplicit,this.explicitTypes=this.schema.compiledExplicit,this.tag=null,this.result="",this.duplicates=[],this.usedDuplicates=null}function Cl(e,t){for(var n=yr.repeat(" ",t),r=0,i=-1,o="",s,u=e.length;r<u;)i=e.indexOf(`
19
19
  `,r),i===-1?(s=e.slice(r),r=u):(s=e.slice(r,i+1),r=i+1),s.length&&s!==`
20
20
  `&&(o+=n),o+=s;return o}function Ns(e,t){return`
21
21
  `+yr.repeat(" ",e.indent*t)}function oh(e,t){var n,r,i;for(n=0,r=e.implicitTypes.length;n<r;n+=1)if(i=e.implicitTypes[n],i.resolve(t))return!0;return!1}function di(e){this.source=e,this.result="",this.checkpoint=0}di.prototype.takeUpTo=function(e){var t;if(e<this.checkpoint)throw t=new Error("position should be > checkpoint"),t.position=e,t.checkpoint=this.checkpoint,t;return this.result+=this.source.slice(this.checkpoint,e),this.checkpoint=e,this};di.prototype.escapeChar=function(){var e,t;return e=this.source.charCodeAt(this.checkpoint),t=Ee[e]||rh(e),this.result+=t,this.checkpoint+=1,this};di.prototype.finish=function(){this.source.length>this.checkpoint&&this.takeUpTo(this.source.length)};function sh(e,t,n){var r,i,o,s,u,c,p,g,b,R,D,T,q,B,L,_,v,N,z,Z,ue;if(t.length===0){e.dump="''";return}if(t.indexOf("!include")==0){e.dump=""+t;return}if(t.indexOf("!$$$novalue")==0){e.dump="";return}if(th.indexOf(t)!==-1){e.dump="'"+t+"'";return}for(r=!0,i=t.length?t.charCodeAt(0):0,o=ks===i||ks===t.charCodeAt(t.length-1),(zm===i||Vm===i||Km===i||Qm===i)&&(r=!1),o?(r=!1,s=!1,u=!1):(s=!0,u=!0),c=!0,p=new di(t),g=!1,b=0,R=0,D=e.indent*n,T=80,D<40?T-=D:T=40,B=0;B<t.length;B++){if(q=t.charCodeAt(B),r)if(!ch(q))r=!1;else continue;c&&q===qs&&(c=!1),L=Ee[q],_=Dl(q),!(!L&&!_)&&(q!==bn&&q!==As&&q!==qs?(s=!1,u=!1):q===bn&&(g=!0,c=!1,B>0&&(v=t.charCodeAt(B-1),v===ks&&(u=!1,s=!1)),s&&(N=B-b,b=B,N>R&&(R=N))),q!==As&&(c=!1),p.takeUpTo(B),p.escapeChar())}if(r&&oh(e,t)&&(r=!1),z="",(s||u)&&(Z=0,t.charCodeAt(t.length-1)===bn&&(Z+=1,t.charCodeAt(t.length-2)===bn&&(Z+=1)),Z===0?z="-":Z===2&&(z="+")),u&&R<T&&(s=!1),g||(u=!1),r)e.dump=t;else if(c)e.dump="'"+t+"'";else if(s)ue=ah(t,T),e.dump=">"+z+`
@@ -32,9 +32,9 @@ var Np=Object.create;var ni=Object.defineProperty;var Op=Object.getOwnPropertyDe
32
32
  `+e.slice(i+1):r+=e.slice(o),r}function ch(e){return jm!==e&&bn!==e&&Lm!==e&&Bm!==e&&Gm!==e&&Jm!==e&&Xm!==e&&eh!==e&&Fm!==e&&Hm!==e&&Um!==e&&Im!==e&&Zm!==e&&Ym!==e&&qs!==e&&As!==e&&Wm!==e&&$m!==e&&!Ee[e]&&!Dl(e)}function Dl(e){return!(32<=e&&e<=126||e===133||160<=e&&e<=55295||57344<=e&&e<=65533||65536<=e&&e<=1114111)}function uh(e,t,n){var r="",i=e.tag,o,s;for(o=0,s=n.length;o<s;o+=1)vn(e,t,n[o],!1,!1)&&(o!==0&&(r+=", "),r+=e.dump);e.tag=i,e.dump="["+r+"]"}function lh(e,t,n,r){var i="",o=e.tag,s,u;for(s=0,u=n.length;s<u;s+=1)vn(e,t+1,n[s],!0,!0)&&((!r||s!==0)&&(i+=Ns(e,t)),i+="- "+e.dump);e.tag=o,e.dump=i||"[]"}function dh(e,t,n){var r="",i=e.tag,o=Object.keys(n),s,u,c,p,g;for(s=0,u=o.length;s<u;s+=1)g="",s!==0&&(g+=", "),c=o[s],p=n[c],vn(e,t,c,!1,!1)&&(e.dump.length>1024&&(g+="? "),g+=e.dump+": ",vn(e,t,p,!1,!1)&&(g+=e.dump,r+=g));e.tag=i,e.dump="{"+r+"}"}function fh(e,t,n,r){var i="",o=e.tag,s=Object.keys(n),u,c,p,g,b,R;for(u=0,c=s.length;u<c;u+=1)R="",(!r||u!==0)&&(R+=Ns(e,t)),p=s[u],g=n[p],vn(e,t+1,p,!0,!0)&&(b=e.tag!==null&&e.tag!=="?"||e.dump&&e.dump.length>1024,b&&(e.dump&&bn===e.dump.charCodeAt(0)?R+="?":R+="? "),R+=e.dump,b&&(R+=Ns(e,t)),vn(e,t+1,g,!0,b)&&(e.dump&&bn===e.dump.charCodeAt(0)?R+=":":R+=": ",R+=e.dump,i+=R));e.tag=o,e.dump=i||"{}"}function _l(e,t,n){var r,i,o,s,u,c;for(i=n?e.explicitTypes:e.implicitTypes,o=0,s=i.length;o<s;o+=1)if(u=i[o],(u.instanceOf||u.predicate)&&(!u.instanceOf||typeof t=="object"&&t instanceof u.instanceOf)&&(!u.predicate||u.predicate(t))){if(e.tag=n?u.tag:"?",u.represent){if(c=e.styleMap[u.tag]||u.defaultStyle,Ms.call(u.represent)==="[object Function]")r=u.represent(t,c);else if(Rl.call(u.represent,c))r=u.represent[c](t,c);else throw new Es("!<"+u.tag+'> tag resolver accepts not "'+c+'" style');e.dump=r}return!0}return!1}function vn(e,t,n,r,i){e.tag=null,e.dump=n,_l(e,n,!1)||_l(e,n,!0);var o=Ms.call(e.dump);r&&(r=0>e.flowLevel||e.flowLevel>t),(e.tag!==null&&e.tag!=="?"||e.indent!==2&&t>0)&&(i=!1);var s=o==="[object Object]"||o==="[object Array]",u,c;if(s&&(u=e.duplicates.indexOf(n),c=u!==-1),c&&e.usedDuplicates[u])e.dump="*ref_"+u;else{if(s&&c&&!e.usedDuplicates[u]&&(e.usedDuplicates[u]=!0),o==="[object Object]")r&&Object.keys(e.dump).length!==0?(fh(e,t,e.dump,i),c&&(e.dump="&ref_"+u+(t===0?`
33
33
  `:"")+e.dump)):(dh(e,t,e.dump),c&&(e.dump="&ref_"+u+" "+e.dump));else if(o==="[object Array]")r&&e.dump.length!==0?(lh(e,t,e.dump,i),c&&(e.dump="&ref_"+u+(t===0?`
34
34
  `:"")+e.dump)):(uh(e,t,e.dump),c&&(e.dump="&ref_"+u+" "+e.dump));else if(o==="[object String]")e.tag!=="?"&&sh(e,e.dump,t);else{if(e.skipInvalid)return!1;throw new Es("unacceptable kind of an object to dump "+o)}e.tag!==null&&e.tag!=="?"&&(e.dump="!<"+e.tag+"> "+e.dump)}return!0}function ph(e,t){var n=[],r=[],i,o;for(Os(e,n,r),i=0,o=r.length;i<o;i+=1)t.duplicates.push(n[r[i]]);t.usedDuplicates=new Array(o)}function Os(e,t,n){var r=Ms.call(e),i,o,s;if(e!==null&&typeof e=="object")if(o=t.indexOf(e),o!==-1)n.indexOf(o)===-1&&n.push(o);else if(t.push(e),Array.isArray(e))for(o=0,s=e.length;o<s;o+=1)Os(e[o],t,n);else for(i=Object.keys(e),o=0,s=i.length;o<s;o+=1)Os(e[i[o]],t,n)}function Sl(e,t){t=t||{};var n=new ih(t);return ph(e,n),vn(n,0,e,!0,!0)?n.dump+`
35
- `:""}In.dump=Sl;function gh(e,t){return Sl(e,yr.extend({schema:Mm},t))}In.safeDump=gh});var xl=A(tt=>{"use strict";Object.defineProperty(tt,"__esModule",{value:!0});tt.determineScalarType=tt.ScalarType=tt.parseYamlFloat=tt.parseYamlInteger=tt.parseYamlBoolean=void 0;function mh(e){if(["true","True","TRUE"].lastIndexOf(e)>=0)return!0;if(["false","False","FALSE"].lastIndexOf(e)>=0)return!1;throw`Invalid boolean "${e}"`}tt.parseYamlBoolean=mh;function hh(e){return e.lastIndexOf("0o",0)===0?parseInt(e.substring(2),8):parseInt(e)}function yh(e){let t=hh(e);if(isNaN(t))throw`Invalid integer "${e}"`;return t}tt.parseYamlInteger=yh;function bh(e){if([".nan",".NaN",".NAN"].lastIndexOf(e)>=0)return NaN;let n=/^([-+])?(?:\.inf|\.Inf|\.INF)$/.exec(e);if(n)return n[1]==="-"?-1/0:1/0;let r=parseFloat(e);if(!isNaN(r))return r;throw`Invalid float "${e}"`}tt.parseYamlFloat=bh;var Wt;(function(e){e[e.null=0]="null",e[e.bool=1]="bool",e[e.int=2]="int",e[e.float=3]="float",e[e.string=4]="string"})(Wt=tt.ScalarType||(tt.ScalarType={}));function vh(e){if(e===void 0)return Wt.null;if(e.doubleQuoted||!e.plainScalar||e.singleQuoted)return Wt.string;let t=e.value;if(["null","Null","NULL","~",""].indexOf(t)>=0||t==null)return Wt.null;if(["true","True","TRUE","false","False","FALSE"].indexOf(t)>=0)return Wt.bool;let n=/^[-+]?[0-9]+$/,r=/^0o[0-7]+$/,i=/^0x[0-9a-fA-F]+$/;if(n.test(t)||r.test(t)||i.test(t))return Wt.int;let o=/^[-+]?(\.[0-9]+|[0-9]+(\.[0-9]*)?)([eE][-+]?[0-9]+)?$/,s=/^[-+]?(\.inf|\.Inf|\.INF)$/;return o.test(t)||s.test(t)||[".nan",".NaN",".NAN"].indexOf(t)>=0?Wt.float:Wt.string}tt.determineScalarType=vh});var pi=A(Te=>{"use strict";var Ch=Te&&Te.__createBinding||(Object.create?function(e,t,n,r){r===void 0&&(r=n),Object.defineProperty(e,r,{enumerable:!0,get:function(){return t[n]}})}:function(e,t,n,r){r===void 0&&(r=n),e[r]=t[n]}),wl=Te&&Te.__exportStar||function(e,t){for(var n in e)n!=="default"&&!Object.prototype.hasOwnProperty.call(t,n)&&Ch(t,e,n)};Object.defineProperty(Te,"__esModule",{value:!0});Te.safeDump=Te.dump=Te.safeLoadAll=Te.safeLoad=Te.loadAll=Te.load=void 0;var fi=vl();Object.defineProperty(Te,"load",{enumerable:!0,get:function(){return fi.load}});Object.defineProperty(Te,"loadAll",{enumerable:!0,get:function(){return fi.loadAll}});Object.defineProperty(Te,"safeLoad",{enumerable:!0,get:function(){return fi.safeLoad}});Object.defineProperty(Te,"safeLoadAll",{enumerable:!0,get:function(){return fi.safeLoadAll}});var kl=Tl();Object.defineProperty(Te,"dump",{enumerable:!0,get:function(){return kl.dump}});Object.defineProperty(Te,"safeDump",{enumerable:!0,get:function(){return kl.safeDump}});Te.YAMLException=En();wl(Ft(),Te);wl(xl(),Te)});var Vn=A(Ye=>{"use strict";Object.defineProperty(Ye,"__esModule",{value:!0});Ye.stringArray=Ye.array=Ye.func=Ye.error=Ye.number=Ye.string=Ye.boolean=void 0;function Xy(e){return e===!0||e===!1}Ye.boolean=Xy;function nd(e){return typeof e=="string"||e instanceof String}Ye.string=nd;function Zy(e){return typeof e=="number"||e instanceof Number}Ye.number=Zy;function eb(e){return e instanceof Error}Ye.error=eb;function tb(e){return typeof e=="function"}Ye.func=tb;function rd(e){return Array.isArray(e)}Ye.array=rd;function nb(e){return rd(e)&&e.every(t=>nd(t))}Ye.stringArray=nb});var Sa=A(U=>{"use strict";Object.defineProperty(U,"__esModule",{value:!0});U.Message=U.NotificationType9=U.NotificationType8=U.NotificationType7=U.NotificationType6=U.NotificationType5=U.NotificationType4=U.NotificationType3=U.NotificationType2=U.NotificationType1=U.NotificationType0=U.NotificationType=U.RequestType9=U.RequestType8=U.RequestType7=U.RequestType6=U.RequestType5=U.RequestType4=U.RequestType3=U.RequestType2=U.RequestType1=U.RequestType=U.RequestType0=U.AbstractMessageSignature=U.ParameterStructures=U.ResponseError=U.ErrorCodes=void 0;var _n=Vn(),id;(function(e){e.ParseError=-32700,e.InvalidRequest=-32600,e.MethodNotFound=-32601,e.InvalidParams=-32602,e.InternalError=-32603,e.jsonrpcReservedErrorRangeStart=-32099,e.serverErrorStart=-32099,e.MessageWriteError=-32099,e.MessageReadError=-32098,e.PendingResponseRejected=-32097,e.ConnectionInactive=-32096,e.ServerNotInitialized=-32002,e.UnknownErrorCode=-32001,e.jsonrpcReservedErrorRangeEnd=-32e3,e.serverErrorEnd=-32e3})(id=U.ErrorCodes||(U.ErrorCodes={}));var _r=class extends Error{constructor(t,n,r){super(n),this.code=_n.number(t)?t:id.UnknownErrorCode,this.data=r,Object.setPrototypeOf(this,_r.prototype)}toJson(){let t={code:this.code,message:this.message};return this.data!==void 0&&(t.data=this.data),t}};U.ResponseError=_r;var Me=class{constructor(t){this.kind=t}static is(t){return t===Me.auto||t===Me.byName||t===Me.byPosition}toString(){return this.kind}};U.ParameterStructures=Me;Me.auto=new Me("auto");Me.byPosition=new Me("byPosition");Me.byName=new Me("byName");var ge=class{constructor(t,n){this.method=t,this.numberOfParams=n}get parameterStructures(){return Me.auto}};U.AbstractMessageSignature=ge;var ra=class extends ge{constructor(t){super(t,0)}};U.RequestType0=ra;var ia=class extends ge{constructor(t,n=Me.auto){super(t,1),this._parameterStructures=n}get parameterStructures(){return this._parameterStructures}};U.RequestType=ia;var oa=class extends ge{constructor(t,n=Me.auto){super(t,1),this._parameterStructures=n}get parameterStructures(){return this._parameterStructures}};U.RequestType1=oa;var sa=class extends ge{constructor(t){super(t,2)}};U.RequestType2=sa;var aa=class extends ge{constructor(t){super(t,3)}};U.RequestType3=aa;var ca=class extends ge{constructor(t){super(t,4)}};U.RequestType4=ca;var ua=class extends ge{constructor(t){super(t,5)}};U.RequestType5=ua;var la=class extends ge{constructor(t){super(t,6)}};U.RequestType6=la;var da=class extends ge{constructor(t){super(t,7)}};U.RequestType7=da;var fa=class extends ge{constructor(t){super(t,8)}};U.RequestType8=fa;var pa=class extends ge{constructor(t){super(t,9)}};U.RequestType9=pa;var ga=class extends ge{constructor(t,n=Me.auto){super(t,1),this._parameterStructures=n}get parameterStructures(){return this._parameterStructures}};U.NotificationType=ga;var ma=class extends ge{constructor(t){super(t,0)}};U.NotificationType0=ma;var ha=class extends ge{constructor(t,n=Me.auto){super(t,1),this._parameterStructures=n}get parameterStructures(){return this._parameterStructures}};U.NotificationType1=ha;var ya=class extends ge{constructor(t){super(t,2)}};U.NotificationType2=ya;var ba=class extends ge{constructor(t){super(t,3)}};U.NotificationType3=ba;var va=class extends ge{constructor(t){super(t,4)}};U.NotificationType4=va;var Ca=class extends ge{constructor(t){super(t,5)}};U.NotificationType5=Ca;var Pa=class extends ge{constructor(t){super(t,6)}};U.NotificationType6=Pa;var _a=class extends ge{constructor(t){super(t,7)}};U.NotificationType7=_a;var Ra=class extends ge{constructor(t){super(t,8)}};U.NotificationType8=Ra;var Da=class extends ge{constructor(t){super(t,9)}};U.NotificationType9=Da;var rb;(function(e){function t(i){let o=i;return o&&_n.string(o.method)&&(_n.string(o.id)||_n.number(o.id))}e.isRequest=t;function n(i){let o=i;return o&&_n.string(o.method)&&i.id===void 0}e.isNotification=n;function r(i){let o=i;return o&&(o.result!==void 0||!!o.error)&&(_n.string(o.id)||_n.number(o.id)||o.id===null)}e.isResponse=r})(rb=U.Message||(U.Message={}))});var xa=A(Bt=>{"use strict";var od;Object.defineProperty(Bt,"__esModule",{value:!0});Bt.LRUCache=Bt.LinkedMap=Bt.Touch=void 0;var Ke;(function(e){e.None=0,e.First=1,e.AsOld=e.First,e.Last=2,e.AsNew=e.Last})(Ke=Bt.Touch||(Bt.Touch={}));var Bi=class{constructor(){this[od]="LinkedMap",this._map=new Map,this._head=void 0,this._tail=void 0,this._size=0,this._state=0}clear(){this._map.clear(),this._head=void 0,this._tail=void 0,this._size=0,this._state++}isEmpty(){return!this._head&&!this._tail}get size(){return this._size}get first(){return this._head?.value}get last(){return this._tail?.value}has(t){return this._map.has(t)}get(t,n=Ke.None){let r=this._map.get(t);if(!!r)return n!==Ke.None&&this.touch(r,n),r.value}set(t,n,r=Ke.None){let i=this._map.get(t);if(i)i.value=n,r!==Ke.None&&this.touch(i,r);else{switch(i={key:t,value:n,next:void 0,previous:void 0},r){case Ke.None:this.addItemLast(i);break;case Ke.First:this.addItemFirst(i);break;case Ke.Last:this.addItemLast(i);break;default:this.addItemLast(i);break}this._map.set(t,i),this._size++}return this}delete(t){return!!this.remove(t)}remove(t){let n=this._map.get(t);if(!!n)return this._map.delete(t),this.removeItem(n),this._size--,n.value}shift(){if(!this._head&&!this._tail)return;if(!this._head||!this._tail)throw new Error("Invalid list");let t=this._head;return this._map.delete(t.key),this.removeItem(t),this._size--,t.value}forEach(t,n){let r=this._state,i=this._head;for(;i;){if(n?t.bind(n)(i.value,i.key,this):t(i.value,i.key,this),this._state!==r)throw new Error("LinkedMap got modified during iteration.");i=i.next}}keys(){let t=this._state,n=this._head,r={[Symbol.iterator]:()=>r,next:()=>{if(this._state!==t)throw new Error("LinkedMap got modified during iteration.");if(n){let i={value:n.key,done:!1};return n=n.next,i}else return{value:void 0,done:!0}}};return r}values(){let t=this._state,n=this._head,r={[Symbol.iterator]:()=>r,next:()=>{if(this._state!==t)throw new Error("LinkedMap got modified during iteration.");if(n){let i={value:n.value,done:!1};return n=n.next,i}else return{value:void 0,done:!0}}};return r}entries(){let t=this._state,n=this._head,r={[Symbol.iterator]:()=>r,next:()=>{if(this._state!==t)throw new Error("LinkedMap got modified during iteration.");if(n){let i={value:[n.key,n.value],done:!1};return n=n.next,i}else return{value:void 0,done:!0}}};return r}[(od=Symbol.toStringTag,Symbol.iterator)](){return this.entries()}trimOld(t){if(t>=this.size)return;if(t===0){this.clear();return}let n=this._head,r=this.size;for(;n&&r>t;)this._map.delete(n.key),n=n.next,r--;this._head=n,this._size=r,n&&(n.previous=void 0),this._state++}addItemFirst(t){if(!this._head&&!this._tail)this._tail=t;else if(this._head)t.next=this._head,this._head.previous=t;else throw new Error("Invalid list");this._head=t,this._state++}addItemLast(t){if(!this._head&&!this._tail)this._head=t;else if(this._tail)t.previous=this._tail,this._tail.next=t;else throw new Error("Invalid list");this._tail=t,this._state++}removeItem(t){if(t===this._head&&t===this._tail)this._head=void 0,this._tail=void 0;else if(t===this._head){if(!t.next)throw new Error("Invalid list");t.next.previous=void 0,this._head=t.next}else if(t===this._tail){if(!t.previous)throw new Error("Invalid list");t.previous.next=void 0,this._tail=t.previous}else{let n=t.next,r=t.previous;if(!n||!r)throw new Error("Invalid list");n.previous=r,r.next=n}t.next=void 0,t.previous=void 0,this._state++}touch(t,n){if(!this._head||!this._tail)throw new Error("Invalid list");if(!(n!==Ke.First&&n!==Ke.Last)){if(n===Ke.First){if(t===this._head)return;let r=t.next,i=t.previous;t===this._tail?(i.next=void 0,this._tail=i):(r.previous=i,i.next=r),t.previous=void 0,t.next=this._head,this._head.previous=t,this._head=t,this._state++}else if(n===Ke.Last){if(t===this._tail)return;let r=t.next,i=t.previous;t===this._head?(r.previous=void 0,this._head=r):(r.previous=i,i.next=r),t.next=void 0,t.previous=this._tail,this._tail.next=t,this._tail=t,this._state++}}}toJSON(){let t=[];return this.forEach((n,r)=>{t.push([r,n])}),t}fromJSON(t){this.clear();for(let[n,r]of t)this.set(n,r)}};Bt.LinkedMap=Bi;var Ta=class extends Bi{constructor(t,n=1){super(),this._limit=t,this._ratio=Math.min(Math.max(0,n),1)}get limit(){return this._limit}set limit(t){this._limit=t,this.checkTrim()}get ratio(){return this._ratio}set ratio(t){this._ratio=Math.min(Math.max(0,t),1),this.checkTrim()}get(t,n=Ke.AsNew){return super.get(t,n)}peek(t){return super.get(t,Ke.None)}set(t,n){return super.set(t,n,Ke.Last),this.checkTrim(),this}checkTrim(){this.size>this._limit&&this.trimOld(Math.round(this._limit*this._ratio))}};Bt.LRUCache=Ta});var sd=A(Rr=>{"use strict";Object.defineProperty(Rr,"__esModule",{value:!0});Rr.Disposable=void 0;var ib;(function(e){function t(n){return{dispose:n}}e.create=t})(ib=Rr.Disposable||(Rr.Disposable={}))});var en=A(Aa=>{"use strict";Object.defineProperty(Aa,"__esModule",{value:!0});var wa;function ka(){if(wa===void 0)throw new Error("No runtime abstraction layer installed");return wa}(function(e){function t(n){if(n===void 0)throw new Error("No runtime abstraction layer provided");wa=n}e.install=t})(ka||(ka={}));Aa.default=ka});var Gn=A(Rn=>{"use strict";Object.defineProperty(Rn,"__esModule",{value:!0});Rn.Emitter=Rn.Event=void 0;var ob=en(),sb;(function(e){let t={dispose(){}};e.None=function(){return t}})(sb=Rn.Event||(Rn.Event={}));var qa=class{add(t,n=null,r){this._callbacks||(this._callbacks=[],this._contexts=[]),this._callbacks.push(t),this._contexts.push(n),Array.isArray(r)&&r.push({dispose:()=>this.remove(t,n)})}remove(t,n=null){if(!this._callbacks)return;let r=!1;for(let i=0,o=this._callbacks.length;i<o;i++)if(this._callbacks[i]===t)if(this._contexts[i]===n){this._callbacks.splice(i,1),this._contexts.splice(i,1);return}else r=!0;if(r)throw new Error("When adding a listener with a context, you should remove it with the same context")}invoke(...t){if(!this._callbacks)return[];let n=[],r=this._callbacks.slice(0),i=this._contexts.slice(0);for(let o=0,s=r.length;o<s;o++)try{n.push(r[o].apply(i[o],t))}catch(u){(0,ob.default)().console.error(u)}return n}isEmpty(){return!this._callbacks||this._callbacks.length===0}dispose(){this._callbacks=void 0,this._contexts=void 0}},Kn=class{constructor(t){this._options=t}get event(){return this._event||(this._event=(t,n,r)=>{this._callbacks||(this._callbacks=new qa),this._options&&this._options.onFirstListenerAdd&&this._callbacks.isEmpty()&&this._options.onFirstListenerAdd(this),this._callbacks.add(t,n);let i={dispose:()=>{!this._callbacks||(this._callbacks.remove(t,n),i.dispose=Kn._noop,this._options&&this._options.onLastListenerRemove&&this._callbacks.isEmpty()&&this._options.onLastListenerRemove(this))}};return Array.isArray(r)&&r.push(i),i}),this._event}fire(t){this._callbacks&&this._callbacks.invoke.call(this._callbacks,t)}dispose(){this._callbacks&&(this._callbacks.dispose(),this._callbacks=void 0)}};Rn.Emitter=Kn;Kn._noop=function(){}});var $i=A(Dn=>{"use strict";Object.defineProperty(Dn,"__esModule",{value:!0});Dn.CancellationTokenSource=Dn.CancellationToken=void 0;var ab=en(),cb=Vn(),Na=Gn(),Oa;(function(e){e.None=Object.freeze({isCancellationRequested:!1,onCancellationRequested:Na.Event.None}),e.Cancelled=Object.freeze({isCancellationRequested:!0,onCancellationRequested:Na.Event.None});function t(n){let r=n;return r&&(r===e.None||r===e.Cancelled||cb.boolean(r.isCancellationRequested)&&!!r.onCancellationRequested)}e.is=t})(Oa=Dn.CancellationToken||(Dn.CancellationToken={}));var ub=Object.freeze(function(e,t){let n=(0,ab.default)().timer.setTimeout(e.bind(t),0);return{dispose(){n.dispose()}}}),zi=class{constructor(){this._isCancelled=!1}cancel(){this._isCancelled||(this._isCancelled=!0,this._emitter&&(this._emitter.fire(void 0),this.dispose()))}get isCancellationRequested(){return this._isCancelled}get onCancellationRequested(){return this._isCancelled?ub:(this._emitter||(this._emitter=new Na.Emitter),this._emitter.event)}dispose(){this._emitter&&(this._emitter.dispose(),this._emitter=void 0)}},Ea=class{get token(){return this._token||(this._token=new zi),this._token}cancel(){this._token?this._token.cancel():this._token=Oa.Cancelled}dispose(){this._token?this._token instanceof zi&&this._token.dispose():this._token=Oa.None}};Dn.CancellationTokenSource=Ea});var ad=A(Jn=>{"use strict";Object.defineProperty(Jn,"__esModule",{value:!0});Jn.SharedArrayReceiverStrategy=Jn.SharedArraySenderStrategy=void 0;var lb=$i(),Dr;(function(e){e.Continue=0,e.Cancelled=1})(Dr||(Dr={}));var Ma=class{constructor(){this.buffers=new Map}enableCancellation(t){if(t.id===null)return;let n=new SharedArrayBuffer(4),r=new Int32Array(n,0,1);r[0]=Dr.Continue,this.buffers.set(t.id,n),t.$cancellationData=n}async sendCancellation(t,n){let r=this.buffers.get(n);if(r===void 0)return;let i=new Int32Array(r,0,1);Atomics.store(i,0,Dr.Cancelled)}cleanup(t){this.buffers.delete(t)}dispose(){this.buffers.clear()}};Jn.SharedArraySenderStrategy=Ma;var ja=class{constructor(t){this.data=new Int32Array(t,0,1)}get isCancellationRequested(){return Atomics.load(this.data,0)===Dr.Cancelled}get onCancellationRequested(){throw new Error("Cancellation over SharedArrayBuffer doesn't support cancellation events")}},La=class{constructor(t){this.token=new ja(t)}cancel(){}dispose(){}},Ia=class{constructor(){this.kind="request"}createCancellationTokenSource(t){let n=t.$cancellationData;return n===void 0?new lb.CancellationTokenSource:new La(n)}};Jn.SharedArrayReceiverStrategy=Ia});var Wa=A(Yi=>{"use strict";Object.defineProperty(Yi,"__esModule",{value:!0});Yi.Semaphore=void 0;var db=en(),Fa=class{constructor(t=1){if(t<=0)throw new Error("Capacity must be greater than 0");this._capacity=t,this._active=0,this._waiting=[]}lock(t){return new Promise((n,r)=>{this._waiting.push({thunk:t,resolve:n,reject:r}),this.runNext()})}get active(){return this._active}runNext(){this._waiting.length===0||this._active===this._capacity||(0,db.default)().timer.setImmediate(()=>this.doRunNext())}doRunNext(){if(this._waiting.length===0||this._active===this._capacity)return;let t=this._waiting.shift();if(this._active++,this._active>this._capacity)throw new Error("To many thunks active");try{let n=t.thunk();n instanceof Promise?n.then(r=>{this._active--,t.resolve(r),this.runNext()},r=>{this._active--,t.reject(r),this.runNext()}):(this._active--,t.resolve(n),this.runNext())}catch(n){this._active--,t.reject(n),this.runNext()}}};Yi.Semaphore=Fa});var cd=A(zt=>{"use strict";Object.defineProperty(zt,"__esModule",{value:!0});zt.ReadableStreamMessageReader=zt.AbstractMessageReader=zt.MessageReader=void 0;var Ua=en(),Qn=Vn(),Ha=Gn(),fb=Wa(),pb;(function(e){function t(n){let r=n;return r&&Qn.func(r.listen)&&Qn.func(r.dispose)&&Qn.func(r.onError)&&Qn.func(r.onClose)&&Qn.func(r.onPartialMessage)}e.is=t})(pb=zt.MessageReader||(zt.MessageReader={}));var Vi=class{constructor(){this.errorEmitter=new Ha.Emitter,this.closeEmitter=new Ha.Emitter,this.partialMessageEmitter=new Ha.Emitter}dispose(){this.errorEmitter.dispose(),this.closeEmitter.dispose()}get onError(){return this.errorEmitter.event}fireError(t){this.errorEmitter.fire(this.asError(t))}get onClose(){return this.closeEmitter.event}fireClose(){this.closeEmitter.fire(void 0)}get onPartialMessage(){return this.partialMessageEmitter.event}firePartialMessage(t){this.partialMessageEmitter.fire(t)}asError(t){return t instanceof Error?t:new Error(`Reader received error. Reason: ${Qn.string(t.message)?t.message:"unknown"}`)}};zt.AbstractMessageReader=Vi;var Ba;(function(e){function t(n){let r,i,o,s=new Map,u,c=new Map;if(n===void 0||typeof n=="string")r=n??"utf-8";else{if(r=n.charset??"utf-8",n.contentDecoder!==void 0&&(o=n.contentDecoder,s.set(o.name,o)),n.contentDecoders!==void 0)for(let p of n.contentDecoders)s.set(p.name,p);if(n.contentTypeDecoder!==void 0&&(u=n.contentTypeDecoder,c.set(u.name,u)),n.contentTypeDecoders!==void 0)for(let p of n.contentTypeDecoders)c.set(p.name,p)}return u===void 0&&(u=(0,Ua.default)().applicationJson.decoder,c.set(u.name,u)),{charset:r,contentDecoder:o,contentDecoders:s,contentTypeDecoder:u,contentTypeDecoders:c}}e.fromOptions=t})(Ba||(Ba={}));var za=class extends Vi{constructor(t,n){super(),this.readable=t,this.options=Ba.fromOptions(n),this.buffer=(0,Ua.default)().messageBuffer.create(this.options.charset),this._partialMessageTimeout=1e4,this.nextMessageLength=-1,this.messageToken=0,this.readSemaphore=new fb.Semaphore(1)}set partialMessageTimeout(t){this._partialMessageTimeout=t}get partialMessageTimeout(){return this._partialMessageTimeout}listen(t){this.nextMessageLength=-1,this.messageToken=0,this.partialMessageTimer=void 0,this.callback=t;let n=this.readable.onData(r=>{this.onData(r)});return this.readable.onError(r=>this.fireError(r)),this.readable.onClose(()=>this.fireClose()),n}onData(t){for(this.buffer.append(t);;){if(this.nextMessageLength===-1){let r=this.buffer.tryReadHeaders(!0);if(!r)return;let i=r.get("content-length");if(!i){this.fireError(new Error("Header must provide a Content-Length property."));return}let o=parseInt(i);if(isNaN(o)){this.fireError(new Error("Content-Length value must be a number."));return}this.nextMessageLength=o}let n=this.buffer.tryReadBody(this.nextMessageLength);if(n===void 0){this.setPartialMessageTimer();return}this.clearPartialMessageTimer(),this.nextMessageLength=-1,this.readSemaphore.lock(async()=>{let r=this.options.contentDecoder!==void 0?await this.options.contentDecoder.decode(n):n,i=await this.options.contentTypeDecoder.decode(r,this.options);this.callback(i)}).catch(r=>{this.fireError(r)})}}clearPartialMessageTimer(){this.partialMessageTimer&&(this.partialMessageTimer.dispose(),this.partialMessageTimer=void 0)}setPartialMessageTimer(){this.clearPartialMessageTimer(),!(this._partialMessageTimeout<=0)&&(this.partialMessageTimer=(0,Ua.default)().timer.setTimeout((t,n)=>{this.partialMessageTimer=void 0,t===this.messageToken&&(this.firePartialMessage({messageToken:t,waitingTime:n}),this.setPartialMessageTimer())},this._partialMessageTimeout,this.messageToken,this._partialMessageTimeout))}};zt.ReadableStreamMessageReader=za});var fd=A($t=>{"use strict";Object.defineProperty($t,"__esModule",{value:!0});$t.WriteableStreamMessageWriter=$t.AbstractMessageWriter=$t.MessageWriter=void 0;var ud=en(),Sr=Vn(),gb=Wa(),ld=Gn(),mb="Content-Length: ",dd=`\r
36
- `,hb;(function(e){function t(n){let r=n;return r&&Sr.func(r.dispose)&&Sr.func(r.onClose)&&Sr.func(r.onError)&&Sr.func(r.write)}e.is=t})(hb=$t.MessageWriter||($t.MessageWriter={}));var Ki=class{constructor(){this.errorEmitter=new ld.Emitter,this.closeEmitter=new ld.Emitter}dispose(){this.errorEmitter.dispose(),this.closeEmitter.dispose()}get onError(){return this.errorEmitter.event}fireError(t,n,r){this.errorEmitter.fire([this.asError(t),n,r])}get onClose(){return this.closeEmitter.event}fireClose(){this.closeEmitter.fire(void 0)}asError(t){return t instanceof Error?t:new Error(`Writer received error. Reason: ${Sr.string(t.message)?t.message:"unknown"}`)}};$t.AbstractMessageWriter=Ki;var $a;(function(e){function t(n){return n===void 0||typeof n=="string"?{charset:n??"utf-8",contentTypeEncoder:(0,ud.default)().applicationJson.encoder}:{charset:n.charset??"utf-8",contentEncoder:n.contentEncoder,contentTypeEncoder:n.contentTypeEncoder??(0,ud.default)().applicationJson.encoder}}e.fromOptions=t})($a||($a={}));var Ya=class extends Ki{constructor(t,n){super(),this.writable=t,this.options=$a.fromOptions(n),this.errorCount=0,this.writeSemaphore=new gb.Semaphore(1),this.writable.onError(r=>this.fireError(r)),this.writable.onClose(()=>this.fireClose())}async write(t){return this.writeSemaphore.lock(async()=>this.options.contentTypeEncoder.encode(t,this.options).then(r=>this.options.contentEncoder!==void 0?this.options.contentEncoder.encode(r):r).then(r=>{let i=[];return i.push(mb,r.byteLength.toString(),dd),i.push(dd),this.doWrite(t,i,r)},r=>{throw this.fireError(r),r}))}async doWrite(t,n,r){try{return await this.writable.write(n.join(""),"ascii"),this.writable.write(r)}catch(i){return this.handleError(i,t),Promise.reject(i)}}handleError(t,n){this.errorCount++,this.fireError(t,n,this.errorCount)}end(){this.writable.end()}};$t.WriteableStreamMessageWriter=Ya});var pd=A(Gi=>{"use strict";Object.defineProperty(Gi,"__esModule",{value:!0});Gi.AbstractMessageBuffer=void 0;var yb=13,bb=10,vb=`\r
37
- `,Va=class{constructor(t="utf-8"){this._encoding=t,this._chunks=[],this._totalLength=0}get encoding(){return this._encoding}append(t){let n=typeof t=="string"?this.fromString(t,this._encoding):t;this._chunks.push(n),this._totalLength+=n.byteLength}tryReadHeaders(t=!1){if(this._chunks.length===0)return;let n=0,r=0,i=0,o=0;e:for(;r<this._chunks.length;){let p=this._chunks[r];i=0;t:for(;i<p.length;){switch(p[i]){case yb:switch(n){case 0:n=1;break;case 2:n=3;break;default:n=0}break;case bb:switch(n){case 1:n=2;break;case 3:n=4,i++;break e;default:n=0}break;default:n=0}i++}o+=p.byteLength,r++}if(n!==4)return;let s=this._read(o+i),u=new Map,c=this.toString(s,"ascii").split(vb);if(c.length<2)return u;for(let p=0;p<c.length-2;p++){let g=c[p],b=g.indexOf(":");if(b===-1)throw new Error("Message header must separate key and value using :");let R=g.substr(0,b),D=g.substr(b+1).trim();u.set(t?R.toLowerCase():R,D)}return u}tryReadBody(t){if(!(this._totalLength<t))return this._read(t)}get numberOfBytes(){return this._totalLength}_read(t){if(t===0)return this.emptyBuffer();if(t>this._totalLength)throw new Error("Cannot read so many bytes!");if(this._chunks[0].byteLength===t){let o=this._chunks[0];return this._chunks.shift(),this._totalLength-=t,this.asNative(o)}if(this._chunks[0].byteLength>t){let o=this._chunks[0],s=this.asNative(o,t);return this._chunks[0]=o.slice(t),this._totalLength-=t,s}let n=this.allocNative(t),r=0,i=0;for(;t>0;){let o=this._chunks[i];if(o.byteLength>t){let s=o.slice(0,t);n.set(s,r),r+=t,this._chunks[i]=o.slice(t),this._totalLength-=t,t-=t}else n.set(o,r),r+=o.byteLength,this._chunks.shift(),this._totalLength-=o.byteLength,t-=o.byteLength}return n}};Gi.AbstractMessageBuffer=Va});var Cd=A(W=>{"use strict";Object.defineProperty(W,"__esModule",{value:!0});W.createMessageConnection=W.ConnectionOptions=W.MessageStrategy=W.CancellationStrategy=W.CancellationSenderStrategy=W.CancellationReceiverStrategy=W.RequestCancellationReceiverStrategy=W.IdCancellationReceiverStrategy=W.ConnectionStrategy=W.ConnectionError=W.ConnectionErrors=W.LogTraceNotification=W.SetTraceNotification=W.TraceFormat=W.TraceValues=W.Trace=W.NullLogger=W.ProgressType=W.ProgressToken=void 0;var gd=en(),ve=Vn(),$=Sa(),md=xa(),Tr=Gn(),Ka=$i(),wr;(function(e){e.type=new $.NotificationType("$/cancelRequest")})(wr||(wr={}));var hd;(function(e){function t(n){return typeof n=="string"||typeof n=="number"}e.is=t})(hd=W.ProgressToken||(W.ProgressToken={}));var xr;(function(e){e.type=new $.NotificationType("$/progress")})(xr||(xr={}));var Ga=class{constructor(){}};W.ProgressType=Ga;var Ja;(function(e){function t(n){return ve.func(n)}e.is=t})(Ja||(Ja={}));W.NullLogger=Object.freeze({error:()=>{},warn:()=>{},info:()=>{},log:()=>{}});var ae;(function(e){e[e.Off=0]="Off",e[e.Messages=1]="Messages",e[e.Compact=2]="Compact",e[e.Verbose=3]="Verbose"})(ae=W.Trace||(W.Trace={}));var Cb;(function(e){e.Off="off",e.Messages="messages",e.Compact="compact",e.Verbose="verbose"})(Cb=W.TraceValues||(W.TraceValues={}));(function(e){function t(r){if(!ve.string(r))return e.Off;switch(r=r.toLowerCase(),r){case"off":return e.Off;case"messages":return e.Messages;case"compact":return e.Compact;case"verbose":return e.Verbose;default:return e.Off}}e.fromString=t;function n(r){switch(r){case e.Off:return"off";case e.Messages:return"messages";case e.Compact:return"compact";case e.Verbose:return"verbose";default:return"off"}}e.toString=n})(ae=W.Trace||(W.Trace={}));var ht;(function(e){e.Text="text",e.JSON="json"})(ht=W.TraceFormat||(W.TraceFormat={}));(function(e){function t(n){return ve.string(n)?(n=n.toLowerCase(),n==="json"?e.JSON:e.Text):e.Text}e.fromString=t})(ht=W.TraceFormat||(W.TraceFormat={}));var yd;(function(e){e.type=new $.NotificationType("$/setTrace")})(yd=W.SetTraceNotification||(W.SetTraceNotification={}));var Qa;(function(e){e.type=new $.NotificationType("$/logTrace")})(Qa=W.LogTraceNotification||(W.LogTraceNotification={}));var Ji;(function(e){e[e.Closed=1]="Closed",e[e.Disposed=2]="Disposed",e[e.AlreadyListening=3]="AlreadyListening"})(Ji=W.ConnectionErrors||(W.ConnectionErrors={}));var tn=class extends Error{constructor(t,n){super(n),this.code=t,Object.setPrototypeOf(this,tn.prototype)}};W.ConnectionError=tn;var bd;(function(e){function t(n){let r=n;return r&&ve.func(r.cancelUndispatched)}e.is=t})(bd=W.ConnectionStrategy||(W.ConnectionStrategy={}));var ec;(function(e){function t(n){let r=n;return r&&(r.kind===void 0||r.kind==="id")&&ve.func(r.createCancellationTokenSource)&&(r.dispose===void 0||ve.func(r.dispose))}e.is=t})(ec=W.IdCancellationReceiverStrategy||(W.IdCancellationReceiverStrategy={}));var vd;(function(e){function t(n){let r=n;return r&&r.kind==="request"&&ve.func(r.createCancellationTokenSource)&&(r.dispose===void 0||ve.func(r.dispose))}e.is=t})(vd=W.RequestCancellationReceiverStrategy||(W.RequestCancellationReceiverStrategy={}));var Xa;(function(e){e.Message=Object.freeze({createCancellationTokenSource(n){return new Ka.CancellationTokenSource}});function t(n){return ec.is(n)||vd.is(n)}e.is=t})(Xa=W.CancellationReceiverStrategy||(W.CancellationReceiverStrategy={}));var Za;(function(e){e.Message=Object.freeze({sendCancellation(n,r){return n.sendNotification(wr.type,{id:r})},cleanup(n){}});function t(n){let r=n;return r&&ve.func(r.sendCancellation)&&ve.func(r.cleanup)}e.is=t})(Za=W.CancellationSenderStrategy||(W.CancellationSenderStrategy={}));var tc;(function(e){e.Message=Object.freeze({receiver:Xa.Message,sender:Za.Message});function t(n){let r=n;return r&&Xa.is(r.receiver)&&Za.is(r.sender)}e.is=t})(tc=W.CancellationStrategy||(W.CancellationStrategy={}));var nc;(function(e){function t(n){let r=n;return r&&ve.func(r.handleMessage)}e.is=t})(nc=W.MessageStrategy||(W.MessageStrategy={}));var Pb;(function(e){function t(n){let r=n;return r&&(tc.is(r.cancellationStrategy)||bd.is(r.connectionStrategy)||nc.is(r.messageStrategy))}e.is=t})(Pb=W.ConnectionOptions||(W.ConnectionOptions={}));var yt;(function(e){e[e.New=1]="New",e[e.Listening=2]="Listening",e[e.Closed=3]="Closed",e[e.Disposed=4]="Disposed"})(yt||(yt={}));function _b(e,t,n,r){let i=n!==void 0?n:W.NullLogger,o=0,s=0,u=0,c="2.0",p,g=new Map,b,R=new Map,D=new Map,T,q=new md.LinkedMap,B=new Map,L=new Set,_=new Map,v=ae.Off,N=ht.Text,z,Z=yt.New,ue=new Tr.Emitter,ze=new Tr.Emitter,dt=new Tr.Emitter,ft=new Tr.Emitter,j=new Tr.Emitter,x=r&&r.cancellationStrategy?r.cancellationStrategy:tc.Message;function H(m){if(m===null)throw new Error("Can't send requests with id null since the response can't be correlated.");return"req-"+m.toString()}function I(m){return m===null?"res-unknown-"+(++u).toString():"res-"+m.toString()}function ie(){return"not-"+(++s).toString()}function X(m,w){$.Message.isRequest(w)?m.set(H(w.id),w):$.Message.isResponse(w)?m.set(I(w.id),w):m.set(ie(),w)}function K(m){}function Ve(){return Z===yt.Listening}function Ae(){return Z===yt.Closed}function ce(){return Z===yt.Disposed}function St(){(Z===yt.New||Z===yt.Listening)&&(Z=yt.Closed,ze.fire(void 0))}function kn(m){ue.fire([m,void 0,void 0])}function G(m){ue.fire(m)}e.onClose(St),e.onError(kn),t.onClose(St),t.onError(G);function Gr(){T||q.size===0||(T=(0,gd.default)().timer.setImmediate(()=>{T=void 0,Yo()}))}function Jr(m){$.Message.isRequest(m)?Ko(m):$.Message.isNotification(m)?Jo(m):$.Message.isResponse(m)?Go(m):dr(m)}function Yo(){if(q.size===0)return;let m=q.shift();try{let w=r?.messageStrategy;nc.is(w)?w.handleMessage(m,Jr):Jr(m)}finally{Gr()}}let Vo=m=>{try{if($.Message.isNotification(m)&&m.method===wr.type.method){let w=m.params.id,E=H(w),F=q.get(E);if($.Message.isRequest(F)){let se=r?.connectionStrategy,me=se&&se.cancelUndispatched?se.cancelUndispatched(F,K):void 0;if(me&&(me.error!==void 0||me.result!==void 0)){q.delete(E),_.delete(w),me.id=F.id,An(me,m.method,Date.now()),t.write(me).catch(()=>i.error("Sending response for canceled message failed."));return}}let le=_.get(w);if(le!==void 0){le.cancel(),fr(m);return}else L.add(w)}X(q,m)}finally{Gr()}};function Ko(m){if(ce())return;function w(ee,de,oe){let De={jsonrpc:c,id:m.id};ee instanceof $.ResponseError?De.error=ee.toJson():De.result=ee===void 0?null:ee,An(De,de,oe),t.write(De).catch(()=>i.error("Sending response failed."))}function E(ee,de,oe){let De={jsonrpc:c,id:m.id,error:ee.toJson()};An(De,de,oe),t.write(De).catch(()=>i.error("Sending response failed."))}function F(ee,de,oe){ee===void 0&&(ee=null);let De={jsonrpc:c,id:m.id,result:ee};An(De,de,oe),t.write(De).catch(()=>i.error("Sending response failed."))}Zo(m);let le=g.get(m.method),se,me;le&&(se=le.type,me=le.handler);let he=Date.now();if(me||p){let ee=m.id??String(Date.now()),de=ec.is(x.receiver)?x.receiver.createCancellationTokenSource(ee):x.receiver.createCancellationTokenSource(m);m.id!==null&&L.has(m.id)&&de.cancel(),m.id!==null&&_.set(ee,de);try{let oe;if(me)if(m.params===void 0){if(se!==void 0&&se.numberOfParams!==0){E(new $.ResponseError($.ErrorCodes.InvalidParams,`Request ${m.method} defines ${se.numberOfParams} params but received none.`),m.method,he);return}oe=me(de.token)}else if(Array.isArray(m.params)){if(se!==void 0&&se.parameterStructures===$.ParameterStructures.byName){E(new $.ResponseError($.ErrorCodes.InvalidParams,`Request ${m.method} defines parameters by name but received parameters by position`),m.method,he);return}oe=me(...m.params,de.token)}else{if(se!==void 0&&se.parameterStructures===$.ParameterStructures.byPosition){E(new $.ResponseError($.ErrorCodes.InvalidParams,`Request ${m.method} defines parameters by position but received parameters by name`),m.method,he);return}oe=me(m.params,de.token)}else p&&(oe=p(m.method,m.params,de.token));let De=oe;oe?De.then?De.then(Le=>{_.delete(ee),w(Le,m.method,he)},Le=>{_.delete(ee),Le instanceof $.ResponseError?E(Le,m.method,he):Le&&ve.string(Le.message)?E(new $.ResponseError($.ErrorCodes.InternalError,`Request ${m.method} failed with message: ${Le.message}`),m.method,he):E(new $.ResponseError($.ErrorCodes.InternalError,`Request ${m.method} failed unexpectedly without providing any details.`),m.method,he)}):(_.delete(ee),w(oe,m.method,he)):(_.delete(ee),F(oe,m.method,he))}catch(oe){_.delete(ee),oe instanceof $.ResponseError?w(oe,m.method,he):oe&&ve.string(oe.message)?E(new $.ResponseError($.ErrorCodes.InternalError,`Request ${m.method} failed with message: ${oe.message}`),m.method,he):E(new $.ResponseError($.ErrorCodes.InternalError,`Request ${m.method} failed unexpectedly without providing any details.`),m.method,he)}}else E(new $.ResponseError($.ErrorCodes.MethodNotFound,`Unhandled method ${m.method}`),m.method,he)}function Go(m){if(!ce())if(m.id===null)m.error?i.error(`Received response message without id: Error is:
35
+ `:""}Fn.dump=Sl;function gh(e,t){return Sl(e,yr.extend({schema:Mm},t))}Fn.safeDump=gh});var xl=A(tt=>{"use strict";Object.defineProperty(tt,"__esModule",{value:!0});tt.determineScalarType=tt.ScalarType=tt.parseYamlFloat=tt.parseYamlInteger=tt.parseYamlBoolean=void 0;function mh(e){if(["true","True","TRUE"].lastIndexOf(e)>=0)return!0;if(["false","False","FALSE"].lastIndexOf(e)>=0)return!1;throw`Invalid boolean "${e}"`}tt.parseYamlBoolean=mh;function hh(e){return e.lastIndexOf("0o",0)===0?parseInt(e.substring(2),8):parseInt(e)}function yh(e){let t=hh(e);if(isNaN(t))throw`Invalid integer "${e}"`;return t}tt.parseYamlInteger=yh;function bh(e){if([".nan",".NaN",".NAN"].lastIndexOf(e)>=0)return NaN;let n=/^([-+])?(?:\.inf|\.Inf|\.INF)$/.exec(e);if(n)return n[1]==="-"?-1/0:1/0;let r=parseFloat(e);if(!isNaN(r))return r;throw`Invalid float "${e}"`}tt.parseYamlFloat=bh;var Wt;(function(e){e[e.null=0]="null",e[e.bool=1]="bool",e[e.int=2]="int",e[e.float=3]="float",e[e.string=4]="string"})(Wt=tt.ScalarType||(tt.ScalarType={}));function vh(e){if(e===void 0)return Wt.null;if(e.doubleQuoted||!e.plainScalar||e.singleQuoted)return Wt.string;let t=e.value;if(["null","Null","NULL","~",""].indexOf(t)>=0||t==null)return Wt.null;if(["true","True","TRUE","false","False","FALSE"].indexOf(t)>=0)return Wt.bool;let n=/^[-+]?[0-9]+$/,r=/^0o[0-7]+$/,i=/^0x[0-9a-fA-F]+$/;if(n.test(t)||r.test(t)||i.test(t))return Wt.int;let o=/^[-+]?(\.[0-9]+|[0-9]+(\.[0-9]*)?)([eE][-+]?[0-9]+)?$/,s=/^[-+]?(\.inf|\.Inf|\.INF)$/;return o.test(t)||s.test(t)||[".nan",".NaN",".NAN"].indexOf(t)>=0?Wt.float:Wt.string}tt.determineScalarType=vh});var pi=A(Te=>{"use strict";var Ch=Te&&Te.__createBinding||(Object.create?function(e,t,n,r){r===void 0&&(r=n),Object.defineProperty(e,r,{enumerable:!0,get:function(){return t[n]}})}:function(e,t,n,r){r===void 0&&(r=n),e[r]=t[n]}),wl=Te&&Te.__exportStar||function(e,t){for(var n in e)n!=="default"&&!Object.prototype.hasOwnProperty.call(t,n)&&Ch(t,e,n)};Object.defineProperty(Te,"__esModule",{value:!0});Te.safeDump=Te.dump=Te.safeLoadAll=Te.safeLoad=Te.loadAll=Te.load=void 0;var fi=vl();Object.defineProperty(Te,"load",{enumerable:!0,get:function(){return fi.load}});Object.defineProperty(Te,"loadAll",{enumerable:!0,get:function(){return fi.loadAll}});Object.defineProperty(Te,"safeLoad",{enumerable:!0,get:function(){return fi.safeLoad}});Object.defineProperty(Te,"safeLoadAll",{enumerable:!0,get:function(){return fi.safeLoadAll}});var kl=Tl();Object.defineProperty(Te,"dump",{enumerable:!0,get:function(){return kl.dump}});Object.defineProperty(Te,"safeDump",{enumerable:!0,get:function(){return kl.safeDump}});Te.YAMLException=Mn();wl(Ft(),Te);wl(xl(),Te)});var Vn=A(Ye=>{"use strict";Object.defineProperty(Ye,"__esModule",{value:!0});Ye.stringArray=Ye.array=Ye.func=Ye.error=Ye.number=Ye.string=Ye.boolean=void 0;function Zy(e){return e===!0||e===!1}Ye.boolean=Zy;function nd(e){return typeof e=="string"||e instanceof String}Ye.string=nd;function eb(e){return typeof e=="number"||e instanceof Number}Ye.number=eb;function tb(e){return e instanceof Error}Ye.error=tb;function nb(e){return typeof e=="function"}Ye.func=nb;function rd(e){return Array.isArray(e)}Ye.array=rd;function rb(e){return rd(e)&&e.every(t=>nd(t))}Ye.stringArray=rb});var Sa=A(U=>{"use strict";Object.defineProperty(U,"__esModule",{value:!0});U.Message=U.NotificationType9=U.NotificationType8=U.NotificationType7=U.NotificationType6=U.NotificationType5=U.NotificationType4=U.NotificationType3=U.NotificationType2=U.NotificationType1=U.NotificationType0=U.NotificationType=U.RequestType9=U.RequestType8=U.RequestType7=U.RequestType6=U.RequestType5=U.RequestType4=U.RequestType3=U.RequestType2=U.RequestType1=U.RequestType=U.RequestType0=U.AbstractMessageSignature=U.ParameterStructures=U.ResponseError=U.ErrorCodes=void 0;var Rn=Vn(),id;(function(e){e.ParseError=-32700,e.InvalidRequest=-32600,e.MethodNotFound=-32601,e.InvalidParams=-32602,e.InternalError=-32603,e.jsonrpcReservedErrorRangeStart=-32099,e.serverErrorStart=-32099,e.MessageWriteError=-32099,e.MessageReadError=-32098,e.PendingResponseRejected=-32097,e.ConnectionInactive=-32096,e.ServerNotInitialized=-32002,e.UnknownErrorCode=-32001,e.jsonrpcReservedErrorRangeEnd=-32e3,e.serverErrorEnd=-32e3})(id=U.ErrorCodes||(U.ErrorCodes={}));var _r=class extends Error{constructor(t,n,r){super(n),this.code=Rn.number(t)?t:id.UnknownErrorCode,this.data=r,Object.setPrototypeOf(this,_r.prototype)}toJson(){let t={code:this.code,message:this.message};return this.data!==void 0&&(t.data=this.data),t}};U.ResponseError=_r;var Me=class{constructor(t){this.kind=t}static is(t){return t===Me.auto||t===Me.byName||t===Me.byPosition}toString(){return this.kind}};U.ParameterStructures=Me;Me.auto=new Me("auto");Me.byPosition=new Me("byPosition");Me.byName=new Me("byName");var ge=class{constructor(t,n){this.method=t,this.numberOfParams=n}get parameterStructures(){return Me.auto}};U.AbstractMessageSignature=ge;var ra=class extends ge{constructor(t){super(t,0)}};U.RequestType0=ra;var ia=class extends ge{constructor(t,n=Me.auto){super(t,1),this._parameterStructures=n}get parameterStructures(){return this._parameterStructures}};U.RequestType=ia;var oa=class extends ge{constructor(t,n=Me.auto){super(t,1),this._parameterStructures=n}get parameterStructures(){return this._parameterStructures}};U.RequestType1=oa;var sa=class extends ge{constructor(t){super(t,2)}};U.RequestType2=sa;var aa=class extends ge{constructor(t){super(t,3)}};U.RequestType3=aa;var ca=class extends ge{constructor(t){super(t,4)}};U.RequestType4=ca;var ua=class extends ge{constructor(t){super(t,5)}};U.RequestType5=ua;var la=class extends ge{constructor(t){super(t,6)}};U.RequestType6=la;var da=class extends ge{constructor(t){super(t,7)}};U.RequestType7=da;var fa=class extends ge{constructor(t){super(t,8)}};U.RequestType8=fa;var pa=class extends ge{constructor(t){super(t,9)}};U.RequestType9=pa;var ga=class extends ge{constructor(t,n=Me.auto){super(t,1),this._parameterStructures=n}get parameterStructures(){return this._parameterStructures}};U.NotificationType=ga;var ma=class extends ge{constructor(t){super(t,0)}};U.NotificationType0=ma;var ha=class extends ge{constructor(t,n=Me.auto){super(t,1),this._parameterStructures=n}get parameterStructures(){return this._parameterStructures}};U.NotificationType1=ha;var ya=class extends ge{constructor(t){super(t,2)}};U.NotificationType2=ya;var ba=class extends ge{constructor(t){super(t,3)}};U.NotificationType3=ba;var va=class extends ge{constructor(t){super(t,4)}};U.NotificationType4=va;var Ca=class extends ge{constructor(t){super(t,5)}};U.NotificationType5=Ca;var Pa=class extends ge{constructor(t){super(t,6)}};U.NotificationType6=Pa;var _a=class extends ge{constructor(t){super(t,7)}};U.NotificationType7=_a;var Ra=class extends ge{constructor(t){super(t,8)}};U.NotificationType8=Ra;var Da=class extends ge{constructor(t){super(t,9)}};U.NotificationType9=Da;var ib;(function(e){function t(i){let o=i;return o&&Rn.string(o.method)&&(Rn.string(o.id)||Rn.number(o.id))}e.isRequest=t;function n(i){let o=i;return o&&Rn.string(o.method)&&i.id===void 0}e.isNotification=n;function r(i){let o=i;return o&&(o.result!==void 0||!!o.error)&&(Rn.string(o.id)||Rn.number(o.id)||o.id===null)}e.isResponse=r})(ib=U.Message||(U.Message={}))});var xa=A(Bt=>{"use strict";var od;Object.defineProperty(Bt,"__esModule",{value:!0});Bt.LRUCache=Bt.LinkedMap=Bt.Touch=void 0;var Ke;(function(e){e.None=0,e.First=1,e.AsOld=e.First,e.Last=2,e.AsNew=e.Last})(Ke=Bt.Touch||(Bt.Touch={}));var Bi=class{constructor(){this[od]="LinkedMap",this._map=new Map,this._head=void 0,this._tail=void 0,this._size=0,this._state=0}clear(){this._map.clear(),this._head=void 0,this._tail=void 0,this._size=0,this._state++}isEmpty(){return!this._head&&!this._tail}get size(){return this._size}get first(){return this._head?.value}get last(){return this._tail?.value}has(t){return this._map.has(t)}get(t,n=Ke.None){let r=this._map.get(t);if(!!r)return n!==Ke.None&&this.touch(r,n),r.value}set(t,n,r=Ke.None){let i=this._map.get(t);if(i)i.value=n,r!==Ke.None&&this.touch(i,r);else{switch(i={key:t,value:n,next:void 0,previous:void 0},r){case Ke.None:this.addItemLast(i);break;case Ke.First:this.addItemFirst(i);break;case Ke.Last:this.addItemLast(i);break;default:this.addItemLast(i);break}this._map.set(t,i),this._size++}return this}delete(t){return!!this.remove(t)}remove(t){let n=this._map.get(t);if(!!n)return this._map.delete(t),this.removeItem(n),this._size--,n.value}shift(){if(!this._head&&!this._tail)return;if(!this._head||!this._tail)throw new Error("Invalid list");let t=this._head;return this._map.delete(t.key),this.removeItem(t),this._size--,t.value}forEach(t,n){let r=this._state,i=this._head;for(;i;){if(n?t.bind(n)(i.value,i.key,this):t(i.value,i.key,this),this._state!==r)throw new Error("LinkedMap got modified during iteration.");i=i.next}}keys(){let t=this._state,n=this._head,r={[Symbol.iterator]:()=>r,next:()=>{if(this._state!==t)throw new Error("LinkedMap got modified during iteration.");if(n){let i={value:n.key,done:!1};return n=n.next,i}else return{value:void 0,done:!0}}};return r}values(){let t=this._state,n=this._head,r={[Symbol.iterator]:()=>r,next:()=>{if(this._state!==t)throw new Error("LinkedMap got modified during iteration.");if(n){let i={value:n.value,done:!1};return n=n.next,i}else return{value:void 0,done:!0}}};return r}entries(){let t=this._state,n=this._head,r={[Symbol.iterator]:()=>r,next:()=>{if(this._state!==t)throw new Error("LinkedMap got modified during iteration.");if(n){let i={value:[n.key,n.value],done:!1};return n=n.next,i}else return{value:void 0,done:!0}}};return r}[(od=Symbol.toStringTag,Symbol.iterator)](){return this.entries()}trimOld(t){if(t>=this.size)return;if(t===0){this.clear();return}let n=this._head,r=this.size;for(;n&&r>t;)this._map.delete(n.key),n=n.next,r--;this._head=n,this._size=r,n&&(n.previous=void 0),this._state++}addItemFirst(t){if(!this._head&&!this._tail)this._tail=t;else if(this._head)t.next=this._head,this._head.previous=t;else throw new Error("Invalid list");this._head=t,this._state++}addItemLast(t){if(!this._head&&!this._tail)this._head=t;else if(this._tail)t.previous=this._tail,this._tail.next=t;else throw new Error("Invalid list");this._tail=t,this._state++}removeItem(t){if(t===this._head&&t===this._tail)this._head=void 0,this._tail=void 0;else if(t===this._head){if(!t.next)throw new Error("Invalid list");t.next.previous=void 0,this._head=t.next}else if(t===this._tail){if(!t.previous)throw new Error("Invalid list");t.previous.next=void 0,this._tail=t.previous}else{let n=t.next,r=t.previous;if(!n||!r)throw new Error("Invalid list");n.previous=r,r.next=n}t.next=void 0,t.previous=void 0,this._state++}touch(t,n){if(!this._head||!this._tail)throw new Error("Invalid list");if(!(n!==Ke.First&&n!==Ke.Last)){if(n===Ke.First){if(t===this._head)return;let r=t.next,i=t.previous;t===this._tail?(i.next=void 0,this._tail=i):(r.previous=i,i.next=r),t.previous=void 0,t.next=this._head,this._head.previous=t,this._head=t,this._state++}else if(n===Ke.Last){if(t===this._tail)return;let r=t.next,i=t.previous;t===this._head?(r.previous=void 0,this._head=r):(r.previous=i,i.next=r),t.next=void 0,t.previous=this._tail,this._tail.next=t,this._tail=t,this._state++}}}toJSON(){let t=[];return this.forEach((n,r)=>{t.push([r,n])}),t}fromJSON(t){this.clear();for(let[n,r]of t)this.set(n,r)}};Bt.LinkedMap=Bi;var Ta=class extends Bi{constructor(t,n=1){super(),this._limit=t,this._ratio=Math.min(Math.max(0,n),1)}get limit(){return this._limit}set limit(t){this._limit=t,this.checkTrim()}get ratio(){return this._ratio}set ratio(t){this._ratio=Math.min(Math.max(0,t),1),this.checkTrim()}get(t,n=Ke.AsNew){return super.get(t,n)}peek(t){return super.get(t,Ke.None)}set(t,n){return super.set(t,n,Ke.Last),this.checkTrim(),this}checkTrim(){this.size>this._limit&&this.trimOld(Math.round(this._limit*this._ratio))}};Bt.LRUCache=Ta});var sd=A(Rr=>{"use strict";Object.defineProperty(Rr,"__esModule",{value:!0});Rr.Disposable=void 0;var ob;(function(e){function t(n){return{dispose:n}}e.create=t})(ob=Rr.Disposable||(Rr.Disposable={}))});var en=A(Aa=>{"use strict";Object.defineProperty(Aa,"__esModule",{value:!0});var wa;function ka(){if(wa===void 0)throw new Error("No runtime abstraction layer installed");return wa}(function(e){function t(n){if(n===void 0)throw new Error("No runtime abstraction layer provided");wa=n}e.install=t})(ka||(ka={}));Aa.default=ka});var Gn=A(Dn=>{"use strict";Object.defineProperty(Dn,"__esModule",{value:!0});Dn.Emitter=Dn.Event=void 0;var sb=en(),ab;(function(e){let t={dispose(){}};e.None=function(){return t}})(ab=Dn.Event||(Dn.Event={}));var qa=class{add(t,n=null,r){this._callbacks||(this._callbacks=[],this._contexts=[]),this._callbacks.push(t),this._contexts.push(n),Array.isArray(r)&&r.push({dispose:()=>this.remove(t,n)})}remove(t,n=null){if(!this._callbacks)return;let r=!1;for(let i=0,o=this._callbacks.length;i<o;i++)if(this._callbacks[i]===t)if(this._contexts[i]===n){this._callbacks.splice(i,1),this._contexts.splice(i,1);return}else r=!0;if(r)throw new Error("When adding a listener with a context, you should remove it with the same context")}invoke(...t){if(!this._callbacks)return[];let n=[],r=this._callbacks.slice(0),i=this._contexts.slice(0);for(let o=0,s=r.length;o<s;o++)try{n.push(r[o].apply(i[o],t))}catch(u){(0,sb.default)().console.error(u)}return n}isEmpty(){return!this._callbacks||this._callbacks.length===0}dispose(){this._callbacks=void 0,this._contexts=void 0}},Kn=class{constructor(t){this._options=t}get event(){return this._event||(this._event=(t,n,r)=>{this._callbacks||(this._callbacks=new qa),this._options&&this._options.onFirstListenerAdd&&this._callbacks.isEmpty()&&this._options.onFirstListenerAdd(this),this._callbacks.add(t,n);let i={dispose:()=>{!this._callbacks||(this._callbacks.remove(t,n),i.dispose=Kn._noop,this._options&&this._options.onLastListenerRemove&&this._callbacks.isEmpty()&&this._options.onLastListenerRemove(this))}};return Array.isArray(r)&&r.push(i),i}),this._event}fire(t){this._callbacks&&this._callbacks.invoke.call(this._callbacks,t)}dispose(){this._callbacks&&(this._callbacks.dispose(),this._callbacks=void 0)}};Dn.Emitter=Kn;Kn._noop=function(){}});var $i=A(Sn=>{"use strict";Object.defineProperty(Sn,"__esModule",{value:!0});Sn.CancellationTokenSource=Sn.CancellationToken=void 0;var cb=en(),ub=Vn(),Na=Gn(),Oa;(function(e){e.None=Object.freeze({isCancellationRequested:!1,onCancellationRequested:Na.Event.None}),e.Cancelled=Object.freeze({isCancellationRequested:!0,onCancellationRequested:Na.Event.None});function t(n){let r=n;return r&&(r===e.None||r===e.Cancelled||ub.boolean(r.isCancellationRequested)&&!!r.onCancellationRequested)}e.is=t})(Oa=Sn.CancellationToken||(Sn.CancellationToken={}));var lb=Object.freeze(function(e,t){let n=(0,cb.default)().timer.setTimeout(e.bind(t),0);return{dispose(){n.dispose()}}}),zi=class{constructor(){this._isCancelled=!1}cancel(){this._isCancelled||(this._isCancelled=!0,this._emitter&&(this._emitter.fire(void 0),this.dispose()))}get isCancellationRequested(){return this._isCancelled}get onCancellationRequested(){return this._isCancelled?lb:(this._emitter||(this._emitter=new Na.Emitter),this._emitter.event)}dispose(){this._emitter&&(this._emitter.dispose(),this._emitter=void 0)}},Ea=class{get token(){return this._token||(this._token=new zi),this._token}cancel(){this._token?this._token.cancel():this._token=Oa.Cancelled}dispose(){this._token?this._token instanceof zi&&this._token.dispose():this._token=Oa.None}};Sn.CancellationTokenSource=Ea});var ad=A(Jn=>{"use strict";Object.defineProperty(Jn,"__esModule",{value:!0});Jn.SharedArrayReceiverStrategy=Jn.SharedArraySenderStrategy=void 0;var db=$i(),Dr;(function(e){e.Continue=0,e.Cancelled=1})(Dr||(Dr={}));var Ma=class{constructor(){this.buffers=new Map}enableCancellation(t){if(t.id===null)return;let n=new SharedArrayBuffer(4),r=new Int32Array(n,0,1);r[0]=Dr.Continue,this.buffers.set(t.id,n),t.$cancellationData=n}async sendCancellation(t,n){let r=this.buffers.get(n);if(r===void 0)return;let i=new Int32Array(r,0,1);Atomics.store(i,0,Dr.Cancelled)}cleanup(t){this.buffers.delete(t)}dispose(){this.buffers.clear()}};Jn.SharedArraySenderStrategy=Ma;var ja=class{constructor(t){this.data=new Int32Array(t,0,1)}get isCancellationRequested(){return Atomics.load(this.data,0)===Dr.Cancelled}get onCancellationRequested(){throw new Error("Cancellation over SharedArrayBuffer doesn't support cancellation events")}},La=class{constructor(t){this.token=new ja(t)}cancel(){}dispose(){}},Ia=class{constructor(){this.kind="request"}createCancellationTokenSource(t){let n=t.$cancellationData;return n===void 0?new db.CancellationTokenSource:new La(n)}};Jn.SharedArrayReceiverStrategy=Ia});var Wa=A(Yi=>{"use strict";Object.defineProperty(Yi,"__esModule",{value:!0});Yi.Semaphore=void 0;var fb=en(),Fa=class{constructor(t=1){if(t<=0)throw new Error("Capacity must be greater than 0");this._capacity=t,this._active=0,this._waiting=[]}lock(t){return new Promise((n,r)=>{this._waiting.push({thunk:t,resolve:n,reject:r}),this.runNext()})}get active(){return this._active}runNext(){this._waiting.length===0||this._active===this._capacity||(0,fb.default)().timer.setImmediate(()=>this.doRunNext())}doRunNext(){if(this._waiting.length===0||this._active===this._capacity)return;let t=this._waiting.shift();if(this._active++,this._active>this._capacity)throw new Error("To many thunks active");try{let n=t.thunk();n instanceof Promise?n.then(r=>{this._active--,t.resolve(r),this.runNext()},r=>{this._active--,t.reject(r),this.runNext()}):(this._active--,t.resolve(n),this.runNext())}catch(n){this._active--,t.reject(n),this.runNext()}}};Yi.Semaphore=Fa});var cd=A(zt=>{"use strict";Object.defineProperty(zt,"__esModule",{value:!0});zt.ReadableStreamMessageReader=zt.AbstractMessageReader=zt.MessageReader=void 0;var Ua=en(),Qn=Vn(),Ha=Gn(),pb=Wa(),gb;(function(e){function t(n){let r=n;return r&&Qn.func(r.listen)&&Qn.func(r.dispose)&&Qn.func(r.onError)&&Qn.func(r.onClose)&&Qn.func(r.onPartialMessage)}e.is=t})(gb=zt.MessageReader||(zt.MessageReader={}));var Vi=class{constructor(){this.errorEmitter=new Ha.Emitter,this.closeEmitter=new Ha.Emitter,this.partialMessageEmitter=new Ha.Emitter}dispose(){this.errorEmitter.dispose(),this.closeEmitter.dispose()}get onError(){return this.errorEmitter.event}fireError(t){this.errorEmitter.fire(this.asError(t))}get onClose(){return this.closeEmitter.event}fireClose(){this.closeEmitter.fire(void 0)}get onPartialMessage(){return this.partialMessageEmitter.event}firePartialMessage(t){this.partialMessageEmitter.fire(t)}asError(t){return t instanceof Error?t:new Error(`Reader received error. Reason: ${Qn.string(t.message)?t.message:"unknown"}`)}};zt.AbstractMessageReader=Vi;var Ba;(function(e){function t(n){let r,i,o,s=new Map,u,c=new Map;if(n===void 0||typeof n=="string")r=n??"utf-8";else{if(r=n.charset??"utf-8",n.contentDecoder!==void 0&&(o=n.contentDecoder,s.set(o.name,o)),n.contentDecoders!==void 0)for(let p of n.contentDecoders)s.set(p.name,p);if(n.contentTypeDecoder!==void 0&&(u=n.contentTypeDecoder,c.set(u.name,u)),n.contentTypeDecoders!==void 0)for(let p of n.contentTypeDecoders)c.set(p.name,p)}return u===void 0&&(u=(0,Ua.default)().applicationJson.decoder,c.set(u.name,u)),{charset:r,contentDecoder:o,contentDecoders:s,contentTypeDecoder:u,contentTypeDecoders:c}}e.fromOptions=t})(Ba||(Ba={}));var za=class extends Vi{constructor(t,n){super(),this.readable=t,this.options=Ba.fromOptions(n),this.buffer=(0,Ua.default)().messageBuffer.create(this.options.charset),this._partialMessageTimeout=1e4,this.nextMessageLength=-1,this.messageToken=0,this.readSemaphore=new pb.Semaphore(1)}set partialMessageTimeout(t){this._partialMessageTimeout=t}get partialMessageTimeout(){return this._partialMessageTimeout}listen(t){this.nextMessageLength=-1,this.messageToken=0,this.partialMessageTimer=void 0,this.callback=t;let n=this.readable.onData(r=>{this.onData(r)});return this.readable.onError(r=>this.fireError(r)),this.readable.onClose(()=>this.fireClose()),n}onData(t){for(this.buffer.append(t);;){if(this.nextMessageLength===-1){let r=this.buffer.tryReadHeaders(!0);if(!r)return;let i=r.get("content-length");if(!i){this.fireError(new Error("Header must provide a Content-Length property."));return}let o=parseInt(i);if(isNaN(o)){this.fireError(new Error("Content-Length value must be a number."));return}this.nextMessageLength=o}let n=this.buffer.tryReadBody(this.nextMessageLength);if(n===void 0){this.setPartialMessageTimer();return}this.clearPartialMessageTimer(),this.nextMessageLength=-1,this.readSemaphore.lock(async()=>{let r=this.options.contentDecoder!==void 0?await this.options.contentDecoder.decode(n):n,i=await this.options.contentTypeDecoder.decode(r,this.options);this.callback(i)}).catch(r=>{this.fireError(r)})}}clearPartialMessageTimer(){this.partialMessageTimer&&(this.partialMessageTimer.dispose(),this.partialMessageTimer=void 0)}setPartialMessageTimer(){this.clearPartialMessageTimer(),!(this._partialMessageTimeout<=0)&&(this.partialMessageTimer=(0,Ua.default)().timer.setTimeout((t,n)=>{this.partialMessageTimer=void 0,t===this.messageToken&&(this.firePartialMessage({messageToken:t,waitingTime:n}),this.setPartialMessageTimer())},this._partialMessageTimeout,this.messageToken,this._partialMessageTimeout))}};zt.ReadableStreamMessageReader=za});var fd=A($t=>{"use strict";Object.defineProperty($t,"__esModule",{value:!0});$t.WriteableStreamMessageWriter=$t.AbstractMessageWriter=$t.MessageWriter=void 0;var ud=en(),Sr=Vn(),mb=Wa(),ld=Gn(),hb="Content-Length: ",dd=`\r
36
+ `,yb;(function(e){function t(n){let r=n;return r&&Sr.func(r.dispose)&&Sr.func(r.onClose)&&Sr.func(r.onError)&&Sr.func(r.write)}e.is=t})(yb=$t.MessageWriter||($t.MessageWriter={}));var Ki=class{constructor(){this.errorEmitter=new ld.Emitter,this.closeEmitter=new ld.Emitter}dispose(){this.errorEmitter.dispose(),this.closeEmitter.dispose()}get onError(){return this.errorEmitter.event}fireError(t,n,r){this.errorEmitter.fire([this.asError(t),n,r])}get onClose(){return this.closeEmitter.event}fireClose(){this.closeEmitter.fire(void 0)}asError(t){return t instanceof Error?t:new Error(`Writer received error. Reason: ${Sr.string(t.message)?t.message:"unknown"}`)}};$t.AbstractMessageWriter=Ki;var $a;(function(e){function t(n){return n===void 0||typeof n=="string"?{charset:n??"utf-8",contentTypeEncoder:(0,ud.default)().applicationJson.encoder}:{charset:n.charset??"utf-8",contentEncoder:n.contentEncoder,contentTypeEncoder:n.contentTypeEncoder??(0,ud.default)().applicationJson.encoder}}e.fromOptions=t})($a||($a={}));var Ya=class extends Ki{constructor(t,n){super(),this.writable=t,this.options=$a.fromOptions(n),this.errorCount=0,this.writeSemaphore=new mb.Semaphore(1),this.writable.onError(r=>this.fireError(r)),this.writable.onClose(()=>this.fireClose())}async write(t){return this.writeSemaphore.lock(async()=>this.options.contentTypeEncoder.encode(t,this.options).then(r=>this.options.contentEncoder!==void 0?this.options.contentEncoder.encode(r):r).then(r=>{let i=[];return i.push(hb,r.byteLength.toString(),dd),i.push(dd),this.doWrite(t,i,r)},r=>{throw this.fireError(r),r}))}async doWrite(t,n,r){try{return await this.writable.write(n.join(""),"ascii"),this.writable.write(r)}catch(i){return this.handleError(i,t),Promise.reject(i)}}handleError(t,n){this.errorCount++,this.fireError(t,n,this.errorCount)}end(){this.writable.end()}};$t.WriteableStreamMessageWriter=Ya});var pd=A(Gi=>{"use strict";Object.defineProperty(Gi,"__esModule",{value:!0});Gi.AbstractMessageBuffer=void 0;var bb=13,vb=10,Cb=`\r
37
+ `,Va=class{constructor(t="utf-8"){this._encoding=t,this._chunks=[],this._totalLength=0}get encoding(){return this._encoding}append(t){let n=typeof t=="string"?this.fromString(t,this._encoding):t;this._chunks.push(n),this._totalLength+=n.byteLength}tryReadHeaders(t=!1){if(this._chunks.length===0)return;let n=0,r=0,i=0,o=0;e:for(;r<this._chunks.length;){let p=this._chunks[r];i=0;t:for(;i<p.length;){switch(p[i]){case bb:switch(n){case 0:n=1;break;case 2:n=3;break;default:n=0}break;case vb:switch(n){case 1:n=2;break;case 3:n=4,i++;break e;default:n=0}break;default:n=0}i++}o+=p.byteLength,r++}if(n!==4)return;let s=this._read(o+i),u=new Map,c=this.toString(s,"ascii").split(Cb);if(c.length<2)return u;for(let p=0;p<c.length-2;p++){let g=c[p],b=g.indexOf(":");if(b===-1)throw new Error("Message header must separate key and value using :");let R=g.substr(0,b),D=g.substr(b+1).trim();u.set(t?R.toLowerCase():R,D)}return u}tryReadBody(t){if(!(this._totalLength<t))return this._read(t)}get numberOfBytes(){return this._totalLength}_read(t){if(t===0)return this.emptyBuffer();if(t>this._totalLength)throw new Error("Cannot read so many bytes!");if(this._chunks[0].byteLength===t){let o=this._chunks[0];return this._chunks.shift(),this._totalLength-=t,this.asNative(o)}if(this._chunks[0].byteLength>t){let o=this._chunks[0],s=this.asNative(o,t);return this._chunks[0]=o.slice(t),this._totalLength-=t,s}let n=this.allocNative(t),r=0,i=0;for(;t>0;){let o=this._chunks[i];if(o.byteLength>t){let s=o.slice(0,t);n.set(s,r),r+=t,this._chunks[i]=o.slice(t),this._totalLength-=t,t-=t}else n.set(o,r),r+=o.byteLength,this._chunks.shift(),this._totalLength-=o.byteLength,t-=o.byteLength}return n}};Gi.AbstractMessageBuffer=Va});var Cd=A(W=>{"use strict";Object.defineProperty(W,"__esModule",{value:!0});W.createMessageConnection=W.ConnectionOptions=W.MessageStrategy=W.CancellationStrategy=W.CancellationSenderStrategy=W.CancellationReceiverStrategy=W.RequestCancellationReceiverStrategy=W.IdCancellationReceiverStrategy=W.ConnectionStrategy=W.ConnectionError=W.ConnectionErrors=W.LogTraceNotification=W.SetTraceNotification=W.TraceFormat=W.TraceValues=W.Trace=W.NullLogger=W.ProgressType=W.ProgressToken=void 0;var gd=en(),ve=Vn(),$=Sa(),md=xa(),Tr=Gn(),Ka=$i(),wr;(function(e){e.type=new $.NotificationType("$/cancelRequest")})(wr||(wr={}));var hd;(function(e){function t(n){return typeof n=="string"||typeof n=="number"}e.is=t})(hd=W.ProgressToken||(W.ProgressToken={}));var xr;(function(e){e.type=new $.NotificationType("$/progress")})(xr||(xr={}));var Ga=class{constructor(){}};W.ProgressType=Ga;var Ja;(function(e){function t(n){return ve.func(n)}e.is=t})(Ja||(Ja={}));W.NullLogger=Object.freeze({error:()=>{},warn:()=>{},info:()=>{},log:()=>{}});var ae;(function(e){e[e.Off=0]="Off",e[e.Messages=1]="Messages",e[e.Compact=2]="Compact",e[e.Verbose=3]="Verbose"})(ae=W.Trace||(W.Trace={}));var Pb;(function(e){e.Off="off",e.Messages="messages",e.Compact="compact",e.Verbose="verbose"})(Pb=W.TraceValues||(W.TraceValues={}));(function(e){function t(r){if(!ve.string(r))return e.Off;switch(r=r.toLowerCase(),r){case"off":return e.Off;case"messages":return e.Messages;case"compact":return e.Compact;case"verbose":return e.Verbose;default:return e.Off}}e.fromString=t;function n(r){switch(r){case e.Off:return"off";case e.Messages:return"messages";case e.Compact:return"compact";case e.Verbose:return"verbose";default:return"off"}}e.toString=n})(ae=W.Trace||(W.Trace={}));var ht;(function(e){e.Text="text",e.JSON="json"})(ht=W.TraceFormat||(W.TraceFormat={}));(function(e){function t(n){return ve.string(n)?(n=n.toLowerCase(),n==="json"?e.JSON:e.Text):e.Text}e.fromString=t})(ht=W.TraceFormat||(W.TraceFormat={}));var yd;(function(e){e.type=new $.NotificationType("$/setTrace")})(yd=W.SetTraceNotification||(W.SetTraceNotification={}));var Qa;(function(e){e.type=new $.NotificationType("$/logTrace")})(Qa=W.LogTraceNotification||(W.LogTraceNotification={}));var Ji;(function(e){e[e.Closed=1]="Closed",e[e.Disposed=2]="Disposed",e[e.AlreadyListening=3]="AlreadyListening"})(Ji=W.ConnectionErrors||(W.ConnectionErrors={}));var tn=class extends Error{constructor(t,n){super(n),this.code=t,Object.setPrototypeOf(this,tn.prototype)}};W.ConnectionError=tn;var bd;(function(e){function t(n){let r=n;return r&&ve.func(r.cancelUndispatched)}e.is=t})(bd=W.ConnectionStrategy||(W.ConnectionStrategy={}));var ec;(function(e){function t(n){let r=n;return r&&(r.kind===void 0||r.kind==="id")&&ve.func(r.createCancellationTokenSource)&&(r.dispose===void 0||ve.func(r.dispose))}e.is=t})(ec=W.IdCancellationReceiverStrategy||(W.IdCancellationReceiverStrategy={}));var vd;(function(e){function t(n){let r=n;return r&&r.kind==="request"&&ve.func(r.createCancellationTokenSource)&&(r.dispose===void 0||ve.func(r.dispose))}e.is=t})(vd=W.RequestCancellationReceiverStrategy||(W.RequestCancellationReceiverStrategy={}));var Xa;(function(e){e.Message=Object.freeze({createCancellationTokenSource(n){return new Ka.CancellationTokenSource}});function t(n){return ec.is(n)||vd.is(n)}e.is=t})(Xa=W.CancellationReceiverStrategy||(W.CancellationReceiverStrategy={}));var Za;(function(e){e.Message=Object.freeze({sendCancellation(n,r){return n.sendNotification(wr.type,{id:r})},cleanup(n){}});function t(n){let r=n;return r&&ve.func(r.sendCancellation)&&ve.func(r.cleanup)}e.is=t})(Za=W.CancellationSenderStrategy||(W.CancellationSenderStrategy={}));var tc;(function(e){e.Message=Object.freeze({receiver:Xa.Message,sender:Za.Message});function t(n){let r=n;return r&&Xa.is(r.receiver)&&Za.is(r.sender)}e.is=t})(tc=W.CancellationStrategy||(W.CancellationStrategy={}));var nc;(function(e){function t(n){let r=n;return r&&ve.func(r.handleMessage)}e.is=t})(nc=W.MessageStrategy||(W.MessageStrategy={}));var _b;(function(e){function t(n){let r=n;return r&&(tc.is(r.cancellationStrategy)||bd.is(r.connectionStrategy)||nc.is(r.messageStrategy))}e.is=t})(_b=W.ConnectionOptions||(W.ConnectionOptions={}));var yt;(function(e){e[e.New=1]="New",e[e.Listening=2]="Listening",e[e.Closed=3]="Closed",e[e.Disposed=4]="Disposed"})(yt||(yt={}));function Rb(e,t,n,r){let i=n!==void 0?n:W.NullLogger,o=0,s=0,u=0,c="2.0",p,g=new Map,b,R=new Map,D=new Map,T,q=new md.LinkedMap,B=new Map,L=new Set,_=new Map,v=ae.Off,N=ht.Text,z,Z=yt.New,ue=new Tr.Emitter,ze=new Tr.Emitter,dt=new Tr.Emitter,ft=new Tr.Emitter,j=new Tr.Emitter,x=r&&r.cancellationStrategy?r.cancellationStrategy:tc.Message;function H(m){if(m===null)throw new Error("Can't send requests with id null since the response can't be correlated.");return"req-"+m.toString()}function I(m){return m===null?"res-unknown-"+(++u).toString():"res-"+m.toString()}function ie(){return"not-"+(++s).toString()}function X(m,w){$.Message.isRequest(w)?m.set(H(w.id),w):$.Message.isResponse(w)?m.set(I(w.id),w):m.set(ie(),w)}function K(m){}function Ve(){return Z===yt.Listening}function Ae(){return Z===yt.Closed}function ce(){return Z===yt.Disposed}function St(){(Z===yt.New||Z===yt.Listening)&&(Z=yt.Closed,ze.fire(void 0))}function An(m){ue.fire([m,void 0,void 0])}function G(m){ue.fire(m)}e.onClose(St),e.onError(An),t.onClose(St),t.onError(G);function Gr(){T||q.size===0||(T=(0,gd.default)().timer.setImmediate(()=>{T=void 0,Yo()}))}function Jr(m){$.Message.isRequest(m)?Ko(m):$.Message.isNotification(m)?Jo(m):$.Message.isResponse(m)?Go(m):dr(m)}function Yo(){if(q.size===0)return;let m=q.shift();try{let w=r?.messageStrategy;nc.is(w)?w.handleMessage(m,Jr):Jr(m)}finally{Gr()}}let Vo=m=>{try{if($.Message.isNotification(m)&&m.method===wr.type.method){let w=m.params.id,E=H(w),F=q.get(E);if($.Message.isRequest(F)){let se=r?.connectionStrategy,me=se&&se.cancelUndispatched?se.cancelUndispatched(F,K):void 0;if(me&&(me.error!==void 0||me.result!==void 0)){q.delete(E),_.delete(w),me.id=F.id,qn(me,m.method,Date.now()),t.write(me).catch(()=>i.error("Sending response for canceled message failed."));return}}let le=_.get(w);if(le!==void 0){le.cancel(),fr(m);return}else L.add(w)}X(q,m)}finally{Gr()}};function Ko(m){if(ce())return;function w(ee,de,oe){let De={jsonrpc:c,id:m.id};ee instanceof $.ResponseError?De.error=ee.toJson():De.result=ee===void 0?null:ee,qn(De,de,oe),t.write(De).catch(()=>i.error("Sending response failed."))}function E(ee,de,oe){let De={jsonrpc:c,id:m.id,error:ee.toJson()};qn(De,de,oe),t.write(De).catch(()=>i.error("Sending response failed."))}function F(ee,de,oe){ee===void 0&&(ee=null);let De={jsonrpc:c,id:m.id,result:ee};qn(De,de,oe),t.write(De).catch(()=>i.error("Sending response failed."))}Zo(m);let le=g.get(m.method),se,me;le&&(se=le.type,me=le.handler);let he=Date.now();if(me||p){let ee=m.id??String(Date.now()),de=ec.is(x.receiver)?x.receiver.createCancellationTokenSource(ee):x.receiver.createCancellationTokenSource(m);m.id!==null&&L.has(m.id)&&de.cancel(),m.id!==null&&_.set(ee,de);try{let oe;if(me)if(m.params===void 0){if(se!==void 0&&se.numberOfParams!==0){E(new $.ResponseError($.ErrorCodes.InvalidParams,`Request ${m.method} defines ${se.numberOfParams} params but received none.`),m.method,he);return}oe=me(de.token)}else if(Array.isArray(m.params)){if(se!==void 0&&se.parameterStructures===$.ParameterStructures.byName){E(new $.ResponseError($.ErrorCodes.InvalidParams,`Request ${m.method} defines parameters by name but received parameters by position`),m.method,he);return}oe=me(...m.params,de.token)}else{if(se!==void 0&&se.parameterStructures===$.ParameterStructures.byPosition){E(new $.ResponseError($.ErrorCodes.InvalidParams,`Request ${m.method} defines parameters by position but received parameters by name`),m.method,he);return}oe=me(m.params,de.token)}else p&&(oe=p(m.method,m.params,de.token));let De=oe;oe?De.then?De.then(Le=>{_.delete(ee),w(Le,m.method,he)},Le=>{_.delete(ee),Le instanceof $.ResponseError?E(Le,m.method,he):Le&&ve.string(Le.message)?E(new $.ResponseError($.ErrorCodes.InternalError,`Request ${m.method} failed with message: ${Le.message}`),m.method,he):E(new $.ResponseError($.ErrorCodes.InternalError,`Request ${m.method} failed unexpectedly without providing any details.`),m.method,he)}):(_.delete(ee),w(oe,m.method,he)):(_.delete(ee),F(oe,m.method,he))}catch(oe){_.delete(ee),oe instanceof $.ResponseError?w(oe,m.method,he):oe&&ve.string(oe.message)?E(new $.ResponseError($.ErrorCodes.InternalError,`Request ${m.method} failed with message: ${oe.message}`),m.method,he):E(new $.ResponseError($.ErrorCodes.InternalError,`Request ${m.method} failed unexpectedly without providing any details.`),m.method,he)}}else E(new $.ResponseError($.ErrorCodes.MethodNotFound,`Unhandled method ${m.method}`),m.method,he)}function Go(m){if(!ce())if(m.id===null)m.error?i.error(`Received response message without id: Error is:
38
38
  ${JSON.stringify(m.error,void 0,4)}`):i.error("Received response message without id. No further error information provided.");else{let w=m.id,E=B.get(w);if(es(m,E),E!==void 0){B.delete(w);try{if(m.error){let F=m.error;E.reject(new $.ResponseError(F.code,F.message,F.data))}else if(m.result!==void 0)E.resolve(m.result);else throw new Error("Should never happen.")}catch(F){F.message?i.error(`Response handler '${E.method}' failed with message: ${F.message}`):i.error(`Response handler '${E.method}' failed unexpectedly.`)}}}}function Jo(m){if(ce())return;let w,E;if(m.method===wr.type.method){let F=m.params.id;L.delete(F),fr(m);return}else{let F=R.get(m.method);F&&(E=F.handler,w=F.type)}if(E||b)try{if(fr(m),E)if(m.params===void 0)w!==void 0&&w.numberOfParams!==0&&w.parameterStructures!==$.ParameterStructures.byName&&i.error(`Notification ${m.method} defines ${w.numberOfParams} params but received none.`),E();else if(Array.isArray(m.params)){let F=m.params;m.method===xr.type.method&&F.length===2&&hd.is(F[0])?E({token:F[0],value:F[1]}):(w!==void 0&&(w.parameterStructures===$.ParameterStructures.byName&&i.error(`Notification ${m.method} defines parameters by name but received parameters by position`),w.numberOfParams!==m.params.length&&i.error(`Notification ${m.method} defines ${w.numberOfParams} params but received ${F.length} arguments`)),E(...F))}else w!==void 0&&w.parameterStructures===$.ParameterStructures.byPosition&&i.error(`Notification ${m.method} defines parameters by position but received parameters by name`),E(m.params);else b&&b(m.method,m.params)}catch(F){F.message?i.error(`Notification handler '${m.method}' failed with message: ${F.message}`):i.error(`Notification handler '${m.method}' failed unexpectedly.`)}else dt.fire(m)}function dr(m){if(!m){i.error("Received empty message.");return}i.error(`Received message which is neither a response nor a notification message:
39
39
  ${JSON.stringify(m,null,4)}`);let w=m;if(ve.string(w.id)||ve.number(w.id)){let E=w.id,F=B.get(E);F&&F.reject(new Error("The received response has neither a result nor an error property."))}}function Tt(m){if(m!=null)switch(v){case ae.Verbose:return JSON.stringify(m,null,4);case ae.Compact:return JSON.stringify(m);default:return}}function Qo(m){if(!(v===ae.Off||!z))if(N===ht.Text){let w;(v===ae.Verbose||v===ae.Compact)&&m.params&&(w=`Params: ${Tt(m.params)}
40
40
 
@@ -42,7 +42,7 @@ ${JSON.stringify(m,null,4)}`);let w=m;if(ve.string(w.id)||ve.number(w.id)){let E
42
42
 
43
43
  `:w=`No parameters provided.
44
44
 
45
- `),z.log(`Sending notification '${m.method}'.`,w)}else Kt("send-notification",m)}function An(m,w,E){if(!(v===ae.Off||!z))if(N===ht.Text){let F;(v===ae.Verbose||v===ae.Compact)&&(m.error&&m.error.data?F=`Error data: ${Tt(m.error.data)}
45
+ `),z.log(`Sending notification '${m.method}'.`,w)}else Kt("send-notification",m)}function qn(m,w,E){if(!(v===ae.Off||!z))if(N===ht.Text){let F;(v===ae.Verbose||v===ae.Compact)&&(m.error&&m.error.data?F=`Error data: ${Tt(m.error.data)}
46
46
 
47
47
  `:m.result?F=`Result: ${Tt(m.result)}
48
48
 
@@ -60,25 +60,25 @@ ${JSON.stringify(m,null,4)}`);let w=m;if(ve.string(w.id)||ve.number(w.id)){let E
60
60
 
61
61
  `:m.error===void 0&&(E=`No result returned.
62
62
 
63
- `)),w){let F=m.error?` Request failed: ${m.error.message} (${m.error.code}).`:"";z.log(`Received response '${w.method} - (${m.id})' in ${Date.now()-w.timerStart}ms.${F}`,E)}else z.log(`Received response ${m.id} without active response promise.`,E)}else Kt("receive-response",m)}function Kt(m,w){if(!z||v===ae.Off)return;let E={isLSPMessage:!0,type:m,message:w,timestamp:Date.now()};z.log(E)}function pn(){if(Ae())throw new tn(Ji.Closed,"Connection is closed.");if(ce())throw new tn(Ji.Disposed,"Connection is disposed.")}function ts(){if(Ve())throw new tn(Ji.AlreadyListening,"Connection is already listening")}function ns(){if(!Ve())throw new Error("Call listen() first.")}function Lt(m){return m===void 0?null:m}function Qr(m){if(m!==null)return m}function Xr(m){return m!=null&&!Array.isArray(m)&&typeof m=="object"}function pr(m,w){switch(m){case $.ParameterStructures.auto:return Xr(w)?Qr(w):[Lt(w)];case $.ParameterStructures.byName:if(!Xr(w))throw new Error("Received parameters by name but param is not an object literal.");return Qr(w);case $.ParameterStructures.byPosition:return[Lt(w)];default:throw new Error(`Unknown parameter structure ${m.toString()}`)}}function Zr(m,w){let E,F=m.numberOfParams;switch(F){case 0:E=void 0;break;case 1:E=pr(m.parameterStructures,w[0]);break;default:E=[];for(let le=0;le<w.length&&le<F;le++)E.push(Lt(w[le]));if(w.length<F)for(let le=w.length;le<F;le++)E.push(null);break}return E}let Gt={sendNotification:(m,...w)=>{pn();let E,F;if(ve.string(m)){E=m;let se=w[0],me=0,he=$.ParameterStructures.auto;$.ParameterStructures.is(se)&&(me=1,he=se);let ee=w.length,de=ee-me;switch(de){case 0:F=void 0;break;case 1:F=pr(he,w[me]);break;default:if(he===$.ParameterStructures.byName)throw new Error(`Received ${de} parameters for 'by Name' notification parameter structure.`);F=w.slice(me,ee).map(oe=>Lt(oe));break}}else{let se=w;E=m.method,F=Zr(m,se)}let le={jsonrpc:c,method:E,params:F};return Xo(le),t.write(le).catch(se=>{throw i.error("Sending notification failed."),se})},onNotification:(m,w)=>{pn();let E;return ve.func(m)?b=m:w&&(ve.string(m)?(E=m,R.set(m,{type:void 0,handler:w})):(E=m.method,R.set(m.method,{type:m,handler:w}))),{dispose:()=>{E!==void 0?R.delete(E):b=void 0}}},onProgress:(m,w,E)=>{if(D.has(w))throw new Error(`Progress handler for token ${w} already registered`);return D.set(w,E),{dispose:()=>{D.delete(w)}}},sendProgress:(m,w,E)=>Gt.sendNotification(xr.type,{token:w,value:E}),onUnhandledProgress:ft.event,sendRequest:(m,...w)=>{pn(),ns();let E,F,le;if(ve.string(m)){E=m;let ee=w[0],de=w[w.length-1],oe=0,De=$.ParameterStructures.auto;$.ParameterStructures.is(ee)&&(oe=1,De=ee);let Le=w.length;Ka.CancellationToken.is(de)&&(Le=Le-1,le=de);let it=Le-oe;switch(it){case 0:F=void 0;break;case 1:F=pr(De,w[oe]);break;default:if(De===$.ParameterStructures.byName)throw new Error(`Received ${it} parameters for 'by Name' request parameter structure.`);F=w.slice(oe,Le).map(C=>Lt(C));break}}else{let ee=w;E=m.method,F=Zr(m,ee);let de=m.numberOfParams;le=Ka.CancellationToken.is(ee[de])?ee[de]:void 0}let se=o++,me;le&&(me=le.onCancellationRequested(()=>{let ee=x.sender.sendCancellation(Gt,se);return ee===void 0?(i.log(`Received no promise from cancellation strategy when cancelling id ${se}`),Promise.resolve()):ee.catch(()=>{i.log(`Sending cancellation messages for id ${se} failed`)})}));let he={jsonrpc:c,id:se,method:E,params:F};return Qo(he),typeof x.sender.enableCancellation=="function"&&x.sender.enableCancellation(he),new Promise(async(ee,de)=>{let oe=it=>{ee(it),x.sender.cleanup(se),me?.dispose()},De=it=>{de(it),x.sender.cleanup(se),me?.dispose()},Le={method:E,timerStart:Date.now(),resolve:oe,reject:De};try{await t.write(he),B.set(se,Le)}catch(it){throw i.error("Sending request failed."),Le.reject(new $.ResponseError($.ErrorCodes.MessageWriteError,it.message?it.message:"Unknown reason")),it}})},onRequest:(m,w)=>{pn();let E=null;return Ja.is(m)?(E=void 0,p=m):ve.string(m)?(E=null,w!==void 0&&(E=m,g.set(m,{handler:w,type:void 0}))):w!==void 0&&(E=m.method,g.set(m.method,{type:m,handler:w})),{dispose:()=>{E!==null&&(E!==void 0?g.delete(E):p=void 0)}}},hasPendingResponse:()=>B.size>0,trace:async(m,w,E)=>{let F=!1,le=ht.Text;E!==void 0&&(ve.boolean(E)?F=E:(F=E.sendNotification||!1,le=E.traceFormat||ht.Text)),v=m,N=le,v===ae.Off?z=void 0:z=w,F&&!Ae()&&!ce()&&await Gt.sendNotification(yd.type,{value:ae.toString(m)})},onError:ue.event,onClose:ze.event,onUnhandledNotification:dt.event,onDispose:j.event,end:()=>{t.end()},dispose:()=>{if(ce())return;Z=yt.Disposed,j.fire(void 0);let m=new $.ResponseError($.ErrorCodes.PendingResponseRejected,"Pending response rejected since connection got disposed");for(let w of B.values())w.reject(m);B=new Map,_=new Map,L=new Set,q=new md.LinkedMap,ve.func(t.dispose)&&t.dispose(),ve.func(e.dispose)&&e.dispose()},listen:()=>{pn(),ts(),Z=yt.Listening,e.listen(Vo)},inspect:()=>{(0,gd.default)().console.log("inspect")}};return Gt.onNotification(Qa.type,m=>{if(v===ae.Off||!z)return;let w=v===ae.Verbose||v===ae.Compact;z.log(m.message,w?m.verbose:void 0)}),Gt.onNotification(xr.type,m=>{let w=D.get(m.token);w?w(m.value):ft.fire(m)}),Gt}W.createMessageConnection=_b});var Qi=A(S=>{"use strict";Object.defineProperty(S,"__esModule",{value:!0});S.ProgressType=S.ProgressToken=S.createMessageConnection=S.NullLogger=S.ConnectionOptions=S.ConnectionStrategy=S.AbstractMessageBuffer=S.WriteableStreamMessageWriter=S.AbstractMessageWriter=S.MessageWriter=S.ReadableStreamMessageReader=S.AbstractMessageReader=S.MessageReader=S.SharedArrayReceiverStrategy=S.SharedArraySenderStrategy=S.CancellationToken=S.CancellationTokenSource=S.Emitter=S.Event=S.Disposable=S.LRUCache=S.Touch=S.LinkedMap=S.ParameterStructures=S.NotificationType9=S.NotificationType8=S.NotificationType7=S.NotificationType6=S.NotificationType5=S.NotificationType4=S.NotificationType3=S.NotificationType2=S.NotificationType1=S.NotificationType0=S.NotificationType=S.ErrorCodes=S.ResponseError=S.RequestType9=S.RequestType8=S.RequestType7=S.RequestType6=S.RequestType5=S.RequestType4=S.RequestType3=S.RequestType2=S.RequestType1=S.RequestType0=S.RequestType=S.Message=S.RAL=void 0;S.MessageStrategy=S.CancellationStrategy=S.CancellationSenderStrategy=S.CancellationReceiverStrategy=S.ConnectionError=S.ConnectionErrors=S.LogTraceNotification=S.SetTraceNotification=S.TraceFormat=S.TraceValues=S.Trace=void 0;var pe=Sa();Object.defineProperty(S,"Message",{enumerable:!0,get:function(){return pe.Message}});Object.defineProperty(S,"RequestType",{enumerable:!0,get:function(){return pe.RequestType}});Object.defineProperty(S,"RequestType0",{enumerable:!0,get:function(){return pe.RequestType0}});Object.defineProperty(S,"RequestType1",{enumerable:!0,get:function(){return pe.RequestType1}});Object.defineProperty(S,"RequestType2",{enumerable:!0,get:function(){return pe.RequestType2}});Object.defineProperty(S,"RequestType3",{enumerable:!0,get:function(){return pe.RequestType3}});Object.defineProperty(S,"RequestType4",{enumerable:!0,get:function(){return pe.RequestType4}});Object.defineProperty(S,"RequestType5",{enumerable:!0,get:function(){return pe.RequestType5}});Object.defineProperty(S,"RequestType6",{enumerable:!0,get:function(){return pe.RequestType6}});Object.defineProperty(S,"RequestType7",{enumerable:!0,get:function(){return pe.RequestType7}});Object.defineProperty(S,"RequestType8",{enumerable:!0,get:function(){return pe.RequestType8}});Object.defineProperty(S,"RequestType9",{enumerable:!0,get:function(){return pe.RequestType9}});Object.defineProperty(S,"ResponseError",{enumerable:!0,get:function(){return pe.ResponseError}});Object.defineProperty(S,"ErrorCodes",{enumerable:!0,get:function(){return pe.ErrorCodes}});Object.defineProperty(S,"NotificationType",{enumerable:!0,get:function(){return pe.NotificationType}});Object.defineProperty(S,"NotificationType0",{enumerable:!0,get:function(){return pe.NotificationType0}});Object.defineProperty(S,"NotificationType1",{enumerable:!0,get:function(){return pe.NotificationType1}});Object.defineProperty(S,"NotificationType2",{enumerable:!0,get:function(){return pe.NotificationType2}});Object.defineProperty(S,"NotificationType3",{enumerable:!0,get:function(){return pe.NotificationType3}});Object.defineProperty(S,"NotificationType4",{enumerable:!0,get:function(){return pe.NotificationType4}});Object.defineProperty(S,"NotificationType5",{enumerable:!0,get:function(){return pe.NotificationType5}});Object.defineProperty(S,"NotificationType6",{enumerable:!0,get:function(){return pe.NotificationType6}});Object.defineProperty(S,"NotificationType7",{enumerable:!0,get:function(){return pe.NotificationType7}});Object.defineProperty(S,"NotificationType8",{enumerable:!0,get:function(){return pe.NotificationType8}});Object.defineProperty(S,"NotificationType9",{enumerable:!0,get:function(){return pe.NotificationType9}});Object.defineProperty(S,"ParameterStructures",{enumerable:!0,get:function(){return pe.ParameterStructures}});var rc=xa();Object.defineProperty(S,"LinkedMap",{enumerable:!0,get:function(){return rc.LinkedMap}});Object.defineProperty(S,"LRUCache",{enumerable:!0,get:function(){return rc.LRUCache}});Object.defineProperty(S,"Touch",{enumerable:!0,get:function(){return rc.Touch}});var Rb=sd();Object.defineProperty(S,"Disposable",{enumerable:!0,get:function(){return Rb.Disposable}});var Pd=Gn();Object.defineProperty(S,"Event",{enumerable:!0,get:function(){return Pd.Event}});Object.defineProperty(S,"Emitter",{enumerable:!0,get:function(){return Pd.Emitter}});var _d=$i();Object.defineProperty(S,"CancellationTokenSource",{enumerable:!0,get:function(){return _d.CancellationTokenSource}});Object.defineProperty(S,"CancellationToken",{enumerable:!0,get:function(){return _d.CancellationToken}});var Rd=ad();Object.defineProperty(S,"SharedArraySenderStrategy",{enumerable:!0,get:function(){return Rd.SharedArraySenderStrategy}});Object.defineProperty(S,"SharedArrayReceiverStrategy",{enumerable:!0,get:function(){return Rd.SharedArrayReceiverStrategy}});var ic=cd();Object.defineProperty(S,"MessageReader",{enumerable:!0,get:function(){return ic.MessageReader}});Object.defineProperty(S,"AbstractMessageReader",{enumerable:!0,get:function(){return ic.AbstractMessageReader}});Object.defineProperty(S,"ReadableStreamMessageReader",{enumerable:!0,get:function(){return ic.ReadableStreamMessageReader}});var oc=fd();Object.defineProperty(S,"MessageWriter",{enumerable:!0,get:function(){return oc.MessageWriter}});Object.defineProperty(S,"AbstractMessageWriter",{enumerable:!0,get:function(){return oc.AbstractMessageWriter}});Object.defineProperty(S,"WriteableStreamMessageWriter",{enumerable:!0,get:function(){return oc.WriteableStreamMessageWriter}});var Db=pd();Object.defineProperty(S,"AbstractMessageBuffer",{enumerable:!0,get:function(){return Db.AbstractMessageBuffer}});var We=Cd();Object.defineProperty(S,"ConnectionStrategy",{enumerable:!0,get:function(){return We.ConnectionStrategy}});Object.defineProperty(S,"ConnectionOptions",{enumerable:!0,get:function(){return We.ConnectionOptions}});Object.defineProperty(S,"NullLogger",{enumerable:!0,get:function(){return We.NullLogger}});Object.defineProperty(S,"createMessageConnection",{enumerable:!0,get:function(){return We.createMessageConnection}});Object.defineProperty(S,"ProgressToken",{enumerable:!0,get:function(){return We.ProgressToken}});Object.defineProperty(S,"ProgressType",{enumerable:!0,get:function(){return We.ProgressType}});Object.defineProperty(S,"Trace",{enumerable:!0,get:function(){return We.Trace}});Object.defineProperty(S,"TraceValues",{enumerable:!0,get:function(){return We.TraceValues}});Object.defineProperty(S,"TraceFormat",{enumerable:!0,get:function(){return We.TraceFormat}});Object.defineProperty(S,"SetTraceNotification",{enumerable:!0,get:function(){return We.SetTraceNotification}});Object.defineProperty(S,"LogTraceNotification",{enumerable:!0,get:function(){return We.LogTraceNotification}});Object.defineProperty(S,"ConnectionErrors",{enumerable:!0,get:function(){return We.ConnectionErrors}});Object.defineProperty(S,"ConnectionError",{enumerable:!0,get:function(){return We.ConnectionError}});Object.defineProperty(S,"CancellationReceiverStrategy",{enumerable:!0,get:function(){return We.CancellationReceiverStrategy}});Object.defineProperty(S,"CancellationSenderStrategy",{enumerable:!0,get:function(){return We.CancellationSenderStrategy}});Object.defineProperty(S,"CancellationStrategy",{enumerable:!0,get:function(){return We.CancellationStrategy}});Object.defineProperty(S,"MessageStrategy",{enumerable:!0,get:function(){return We.MessageStrategy}});var Sb=en();S.RAL=Sb.default});var Sd=A(uc=>{"use strict";Object.defineProperty(uc,"__esModule",{value:!0});var At=Qi(),Xn=class extends At.AbstractMessageBuffer{constructor(t="utf-8"){super(t),this.asciiDecoder=new TextDecoder("ascii")}emptyBuffer(){return Xn.emptyBuffer}fromString(t,n){return new TextEncoder().encode(t)}toString(t,n){return n==="ascii"?this.asciiDecoder.decode(t):new TextDecoder(n).decode(t)}asNative(t,n){return n===void 0?t:t.slice(0,n)}allocNative(t){return new Uint8Array(t)}};Xn.emptyBuffer=new Uint8Array(0);var sc=class{constructor(t){this.socket=t,this._onData=new At.Emitter,this._messageListener=n=>{n.data.arrayBuffer().then(i=>{this._onData.fire(new Uint8Array(i))},()=>{(0,At.RAL)().console.error("Converting blob to array buffer failed.")})},this.socket.addEventListener("message",this._messageListener)}onClose(t){return this.socket.addEventListener("close",t),At.Disposable.create(()=>this.socket.removeEventListener("close",t))}onError(t){return this.socket.addEventListener("error",t),At.Disposable.create(()=>this.socket.removeEventListener("error",t))}onEnd(t){return this.socket.addEventListener("end",t),At.Disposable.create(()=>this.socket.removeEventListener("end",t))}onData(t){return this._onData.event(t)}},ac=class{constructor(t){this.socket=t}onClose(t){return this.socket.addEventListener("close",t),At.Disposable.create(()=>this.socket.removeEventListener("close",t))}onError(t){return this.socket.addEventListener("error",t),At.Disposable.create(()=>this.socket.removeEventListener("error",t))}onEnd(t){return this.socket.addEventListener("end",t),At.Disposable.create(()=>this.socket.removeEventListener("end",t))}write(t,n){if(typeof t=="string"){if(n!==void 0&&n!=="utf-8")throw new Error(`In a Browser environments only utf-8 text encoding is supported. But got encoding: ${n}`);this.socket.send(t)}else this.socket.send(t);return Promise.resolve()}end(){this.socket.close()}},Tb=new TextEncoder,Dd=Object.freeze({messageBuffer:Object.freeze({create:e=>new Xn(e)}),applicationJson:Object.freeze({encoder:Object.freeze({name:"application/json",encode:(e,t)=>{if(t.charset!=="utf-8")throw new Error(`In a Browser environments only utf-8 text encoding is supported. But got encoding: ${t.charset}`);return Promise.resolve(Tb.encode(JSON.stringify(e,void 0,0)))}}),decoder:Object.freeze({name:"application/json",decode:(e,t)=>{if(!(e instanceof Uint8Array))throw new Error("In a Browser environments only Uint8Arrays are supported.");return Promise.resolve(JSON.parse(new TextDecoder(t.charset).decode(e)))}})}),stream:Object.freeze({asReadableStream:e=>new sc(e),asWritableStream:e=>new ac(e)}),console,timer:Object.freeze({setTimeout(e,t,...n){let r=setTimeout(e,t,...n);return{dispose:()=>clearTimeout(r)}},setImmediate(e,...t){let n=setTimeout(e,0,...t);return{dispose:()=>clearTimeout(n)}},setInterval(e,t,...n){let r=setInterval(e,t,...n);return{dispose:()=>clearInterval(r)}}})});function cc(){return Dd}(function(e){function t(){At.RAL.install(Dd)}e.install=t})(cc||(cc={}));uc.default=cc});var Sn=A(rt=>{"use strict";var xb=rt&&rt.__createBinding||(Object.create?function(e,t,n,r){r===void 0&&(r=n);var i=Object.getOwnPropertyDescriptor(t,n);(!i||("get"in i?!t.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:function(){return t[n]}}),Object.defineProperty(e,r,i)}:function(e,t,n,r){r===void 0&&(r=n),e[r]=t[n]}),wb=rt&&rt.__exportStar||function(e,t){for(var n in e)n!=="default"&&!Object.prototype.hasOwnProperty.call(t,n)&&xb(t,e,n)};Object.defineProperty(rt,"__esModule",{value:!0});rt.createMessageConnection=rt.BrowserMessageWriter=rt.BrowserMessageReader=void 0;var kb=Sd();kb.default.install();var Zn=Qi();wb(Qi(),rt);var lc=class extends Zn.AbstractMessageReader{constructor(t){super(),this._onData=new Zn.Emitter,this._messageListener=n=>{this._onData.fire(n.data)},t.addEventListener("error",n=>this.fireError(n)),t.onmessage=this._messageListener}listen(t){return this._onData.event(t)}};rt.BrowserMessageReader=lc;var dc=class extends Zn.AbstractMessageWriter{constructor(t){super(),this.port=t,this.errorCount=0,t.addEventListener("error",n=>this.fireError(n))}write(t){try{return this.port.postMessage(t),Promise.resolve()}catch(n){return this.handleError(n,t),Promise.reject(n)}}handleError(t,n){this.errorCount++,this.fireError(t,n,this.errorCount)}end(){}};rt.BrowserMessageWriter=dc;function Ab(e,t,n,r){return n===void 0&&(n=Zn.NullLogger),Zn.ConnectionStrategy.is(r)&&(r={connectionStrategy:r}),(0,Zn.createMessageConnection)(e,t,n,r)}rt.createMessageConnection=Ab});var fc=A((bD,Td)=>{"use strict";Td.exports=Sn()});var Zi=A((xd,Xi)=>{(function(e){if(typeof Xi=="object"&&typeof Xi.exports=="object"){var t=e(eu,xd);t!==void 0&&(Xi.exports=t)}else typeof define=="function"&&define.amd&&define(["require","exports"],e)})(function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.TextDocument=t.EOL=t.WorkspaceFolder=t.InlayHint=t.InlayHintLabelPart=t.InlayHintKind=t.InlineValueContext=t.InlineValueEvaluatableExpression=t.InlineValueVariableLookup=t.InlineValueText=t.SemanticTokens=t.SemanticTokenModifiers=t.SemanticTokenTypes=t.SelectionRange=t.DocumentLink=t.FormattingOptions=t.CodeLens=t.CodeAction=t.CodeActionContext=t.CodeActionTriggerKind=t.CodeActionKind=t.DocumentSymbol=t.WorkspaceSymbol=t.SymbolInformation=t.SymbolTag=t.SymbolKind=t.DocumentHighlight=t.DocumentHighlightKind=t.SignatureInformation=t.ParameterInformation=t.Hover=t.MarkedString=t.CompletionList=t.CompletionItem=t.CompletionItemLabelDetails=t.InsertTextMode=t.InsertReplaceEdit=t.CompletionItemTag=t.InsertTextFormat=t.CompletionItemKind=t.MarkupContent=t.MarkupKind=t.TextDocumentItem=t.OptionalVersionedTextDocumentIdentifier=t.VersionedTextDocumentIdentifier=t.TextDocumentIdentifier=t.WorkspaceChange=t.WorkspaceEdit=t.DeleteFile=t.RenameFile=t.CreateFile=t.TextDocumentEdit=t.AnnotatedTextEdit=t.ChangeAnnotationIdentifier=t.ChangeAnnotation=t.TextEdit=t.Command=t.Diagnostic=t.CodeDescription=t.DiagnosticTag=t.DiagnosticSeverity=t.DiagnosticRelatedInformation=t.FoldingRange=t.FoldingRangeKind=t.ColorPresentation=t.ColorInformation=t.Color=t.LocationLink=t.Location=t.Range=t.Position=t.uinteger=t.integer=t.URI=t.DocumentUri=void 0;var n;(function(l){function h(y){return typeof y=="string"}l.is=h})(n=t.DocumentUri||(t.DocumentUri={}));var r;(function(l){function h(y){return typeof y=="string"}l.is=h})(r=t.URI||(t.URI={}));var i;(function(l){l.MIN_VALUE=-2147483648,l.MAX_VALUE=2147483647;function h(y){return typeof y=="number"&&l.MIN_VALUE<=y&&y<=l.MAX_VALUE}l.is=h})(i=t.integer||(t.integer={}));var o;(function(l){l.MIN_VALUE=0,l.MAX_VALUE=2147483647;function h(y){return typeof y=="number"&&l.MIN_VALUE<=y&&y<=l.MAX_VALUE}l.is=h})(o=t.uinteger||(t.uinteger={}));var s;(function(l){function h(f,a){return f===Number.MAX_VALUE&&(f=o.MAX_VALUE),a===Number.MAX_VALUE&&(a=o.MAX_VALUE),{line:f,character:a}}l.create=h;function y(f){var a=f;return C.objectLiteral(a)&&C.uinteger(a.line)&&C.uinteger(a.character)}l.is=y})(s=t.Position||(t.Position={}));var u;(function(l){function h(f,a,P,k){if(C.uinteger(f)&&C.uinteger(a)&&C.uinteger(P)&&C.uinteger(k))return{start:s.create(f,a),end:s.create(P,k)};if(s.is(f)&&s.is(a))return{start:f,end:a};throw new Error("Range#create called with invalid arguments[".concat(f,", ").concat(a,", ").concat(P,", ").concat(k,"]"))}l.create=h;function y(f){var a=f;return C.objectLiteral(a)&&s.is(a.start)&&s.is(a.end)}l.is=y})(u=t.Range||(t.Range={}));var c;(function(l){function h(f,a){return{uri:f,range:a}}l.create=h;function y(f){var a=f;return C.objectLiteral(a)&&u.is(a.range)&&(C.string(a.uri)||C.undefined(a.uri))}l.is=y})(c=t.Location||(t.Location={}));var p;(function(l){function h(f,a,P,k){return{targetUri:f,targetRange:a,targetSelectionRange:P,originSelectionRange:k}}l.create=h;function y(f){var a=f;return C.objectLiteral(a)&&u.is(a.targetRange)&&C.string(a.targetUri)&&u.is(a.targetSelectionRange)&&(u.is(a.originSelectionRange)||C.undefined(a.originSelectionRange))}l.is=y})(p=t.LocationLink||(t.LocationLink={}));var g;(function(l){function h(f,a,P,k){return{red:f,green:a,blue:P,alpha:k}}l.create=h;function y(f){var a=f;return C.objectLiteral(a)&&C.numberRange(a.red,0,1)&&C.numberRange(a.green,0,1)&&C.numberRange(a.blue,0,1)&&C.numberRange(a.alpha,0,1)}l.is=y})(g=t.Color||(t.Color={}));var b;(function(l){function h(f,a){return{range:f,color:a}}l.create=h;function y(f){var a=f;return C.objectLiteral(a)&&u.is(a.range)&&g.is(a.color)}l.is=y})(b=t.ColorInformation||(t.ColorInformation={}));var R;(function(l){function h(f,a,P){return{label:f,textEdit:a,additionalTextEdits:P}}l.create=h;function y(f){var a=f;return C.objectLiteral(a)&&C.string(a.label)&&(C.undefined(a.textEdit)||z.is(a))&&(C.undefined(a.additionalTextEdits)||C.typedArray(a.additionalTextEdits,z.is))}l.is=y})(R=t.ColorPresentation||(t.ColorPresentation={}));var D;(function(l){l.Comment="comment",l.Imports="imports",l.Region="region"})(D=t.FoldingRangeKind||(t.FoldingRangeKind={}));var T;(function(l){function h(f,a,P,k,J,_e){var fe={startLine:f,endLine:a};return C.defined(P)&&(fe.startCharacter=P),C.defined(k)&&(fe.endCharacter=k),C.defined(J)&&(fe.kind=J),C.defined(_e)&&(fe.collapsedText=_e),fe}l.create=h;function y(f){var a=f;return C.objectLiteral(a)&&C.uinteger(a.startLine)&&C.uinteger(a.startLine)&&(C.undefined(a.startCharacter)||C.uinteger(a.startCharacter))&&(C.undefined(a.endCharacter)||C.uinteger(a.endCharacter))&&(C.undefined(a.kind)||C.string(a.kind))}l.is=y})(T=t.FoldingRange||(t.FoldingRange={}));var q;(function(l){function h(f,a){return{location:f,message:a}}l.create=h;function y(f){var a=f;return C.defined(a)&&c.is(a.location)&&C.string(a.message)}l.is=y})(q=t.DiagnosticRelatedInformation||(t.DiagnosticRelatedInformation={}));var B;(function(l){l.Error=1,l.Warning=2,l.Information=3,l.Hint=4})(B=t.DiagnosticSeverity||(t.DiagnosticSeverity={}));var L;(function(l){l.Unnecessary=1,l.Deprecated=2})(L=t.DiagnosticTag||(t.DiagnosticTag={}));var _;(function(l){function h(y){var f=y;return C.objectLiteral(f)&&C.string(f.href)}l.is=h})(_=t.CodeDescription||(t.CodeDescription={}));var v;(function(l){function h(f,a,P,k,J,_e){var fe={range:f,message:a};return C.defined(P)&&(fe.severity=P),C.defined(k)&&(fe.code=k),C.defined(J)&&(fe.source=J),C.defined(_e)&&(fe.relatedInformation=_e),fe}l.create=h;function y(f){var a,P=f;return C.defined(P)&&u.is(P.range)&&C.string(P.message)&&(C.number(P.severity)||C.undefined(P.severity))&&(C.integer(P.code)||C.string(P.code)||C.undefined(P.code))&&(C.undefined(P.codeDescription)||C.string((a=P.codeDescription)===null||a===void 0?void 0:a.href))&&(C.string(P.source)||C.undefined(P.source))&&(C.undefined(P.relatedInformation)||C.typedArray(P.relatedInformation,q.is))}l.is=y})(v=t.Diagnostic||(t.Diagnostic={}));var N;(function(l){function h(f,a){for(var P=[],k=2;k<arguments.length;k++)P[k-2]=arguments[k];var J={title:f,command:a};return C.defined(P)&&P.length>0&&(J.arguments=P),J}l.create=h;function y(f){var a=f;return C.defined(a)&&C.string(a.title)&&C.string(a.command)}l.is=y})(N=t.Command||(t.Command={}));var z;(function(l){function h(P,k){return{range:P,newText:k}}l.replace=h;function y(P,k){return{range:{start:P,end:P},newText:k}}l.insert=y;function f(P){return{range:P,newText:""}}l.del=f;function a(P){var k=P;return C.objectLiteral(k)&&C.string(k.newText)&&u.is(k.range)}l.is=a})(z=t.TextEdit||(t.TextEdit={}));var Z;(function(l){function h(f,a,P){var k={label:f};return a!==void 0&&(k.needsConfirmation=a),P!==void 0&&(k.description=P),k}l.create=h;function y(f){var a=f;return C.objectLiteral(a)&&C.string(a.label)&&(C.boolean(a.needsConfirmation)||a.needsConfirmation===void 0)&&(C.string(a.description)||a.description===void 0)}l.is=y})(Z=t.ChangeAnnotation||(t.ChangeAnnotation={}));var ue;(function(l){function h(y){var f=y;return C.string(f)}l.is=h})(ue=t.ChangeAnnotationIdentifier||(t.ChangeAnnotationIdentifier={}));var ze;(function(l){function h(P,k,J){return{range:P,newText:k,annotationId:J}}l.replace=h;function y(P,k,J){return{range:{start:P,end:P},newText:k,annotationId:J}}l.insert=y;function f(P,k){return{range:P,newText:"",annotationId:k}}l.del=f;function a(P){var k=P;return z.is(k)&&(Z.is(k.annotationId)||ue.is(k.annotationId))}l.is=a})(ze=t.AnnotatedTextEdit||(t.AnnotatedTextEdit={}));var dt;(function(l){function h(f,a){return{textDocument:f,edits:a}}l.create=h;function y(f){var a=f;return C.defined(a)&&Ae.is(a.textDocument)&&Array.isArray(a.edits)}l.is=y})(dt=t.TextDocumentEdit||(t.TextDocumentEdit={}));var ft;(function(l){function h(f,a,P){var k={kind:"create",uri:f};return a!==void 0&&(a.overwrite!==void 0||a.ignoreIfExists!==void 0)&&(k.options=a),P!==void 0&&(k.annotationId=P),k}l.create=h;function y(f){var a=f;return a&&a.kind==="create"&&C.string(a.uri)&&(a.options===void 0||(a.options.overwrite===void 0||C.boolean(a.options.overwrite))&&(a.options.ignoreIfExists===void 0||C.boolean(a.options.ignoreIfExists)))&&(a.annotationId===void 0||ue.is(a.annotationId))}l.is=y})(ft=t.CreateFile||(t.CreateFile={}));var j;(function(l){function h(f,a,P,k){var J={kind:"rename",oldUri:f,newUri:a};return P!==void 0&&(P.overwrite!==void 0||P.ignoreIfExists!==void 0)&&(J.options=P),k!==void 0&&(J.annotationId=k),J}l.create=h;function y(f){var a=f;return a&&a.kind==="rename"&&C.string(a.oldUri)&&C.string(a.newUri)&&(a.options===void 0||(a.options.overwrite===void 0||C.boolean(a.options.overwrite))&&(a.options.ignoreIfExists===void 0||C.boolean(a.options.ignoreIfExists)))&&(a.annotationId===void 0||ue.is(a.annotationId))}l.is=y})(j=t.RenameFile||(t.RenameFile={}));var x;(function(l){function h(f,a,P){var k={kind:"delete",uri:f};return a!==void 0&&(a.recursive!==void 0||a.ignoreIfNotExists!==void 0)&&(k.options=a),P!==void 0&&(k.annotationId=P),k}l.create=h;function y(f){var a=f;return a&&a.kind==="delete"&&C.string(a.uri)&&(a.options===void 0||(a.options.recursive===void 0||C.boolean(a.options.recursive))&&(a.options.ignoreIfNotExists===void 0||C.boolean(a.options.ignoreIfNotExists)))&&(a.annotationId===void 0||ue.is(a.annotationId))}l.is=y})(x=t.DeleteFile||(t.DeleteFile={}));var H;(function(l){function h(y){var f=y;return f&&(f.changes!==void 0||f.documentChanges!==void 0)&&(f.documentChanges===void 0||f.documentChanges.every(function(a){return C.string(a.kind)?ft.is(a)||j.is(a)||x.is(a):dt.is(a)}))}l.is=h})(H=t.WorkspaceEdit||(t.WorkspaceEdit={}));var I=function(){function l(h,y){this.edits=h,this.changeAnnotations=y}return l.prototype.insert=function(h,y,f){var a,P;if(f===void 0?a=z.insert(h,y):ue.is(f)?(P=f,a=ze.insert(h,y,f)):(this.assertChangeAnnotations(this.changeAnnotations),P=this.changeAnnotations.manage(f),a=ze.insert(h,y,P)),this.edits.push(a),P!==void 0)return P},l.prototype.replace=function(h,y,f){var a,P;if(f===void 0?a=z.replace(h,y):ue.is(f)?(P=f,a=ze.replace(h,y,f)):(this.assertChangeAnnotations(this.changeAnnotations),P=this.changeAnnotations.manage(f),a=ze.replace(h,y,P)),this.edits.push(a),P!==void 0)return P},l.prototype.delete=function(h,y){var f,a;if(y===void 0?f=z.del(h):ue.is(y)?(a=y,f=ze.del(h,y)):(this.assertChangeAnnotations(this.changeAnnotations),a=this.changeAnnotations.manage(y),f=ze.del(h,a)),this.edits.push(f),a!==void 0)return a},l.prototype.add=function(h){this.edits.push(h)},l.prototype.all=function(){return this.edits},l.prototype.clear=function(){this.edits.splice(0,this.edits.length)},l.prototype.assertChangeAnnotations=function(h){if(h===void 0)throw new Error("Text edit change is not configured to manage change annotations.")},l}(),ie=function(){function l(h){this._annotations=h===void 0?Object.create(null):h,this._counter=0,this._size=0}return l.prototype.all=function(){return this._annotations},Object.defineProperty(l.prototype,"size",{get:function(){return this._size},enumerable:!1,configurable:!0}),l.prototype.manage=function(h,y){var f;if(ue.is(h)?f=h:(f=this.nextId(),y=h),this._annotations[f]!==void 0)throw new Error("Id ".concat(f," is already in use."));if(y===void 0)throw new Error("No annotation provided for id ".concat(f));return this._annotations[f]=y,this._size++,f},l.prototype.nextId=function(){return this._counter++,this._counter.toString()},l}(),X=function(){function l(h){var y=this;this._textEditChanges=Object.create(null),h!==void 0?(this._workspaceEdit=h,h.documentChanges?(this._changeAnnotations=new ie(h.changeAnnotations),h.changeAnnotations=this._changeAnnotations.all(),h.documentChanges.forEach(function(f){if(dt.is(f)){var a=new I(f.edits,y._changeAnnotations);y._textEditChanges[f.textDocument.uri]=a}})):h.changes&&Object.keys(h.changes).forEach(function(f){var a=new I(h.changes[f]);y._textEditChanges[f]=a})):this._workspaceEdit={}}return Object.defineProperty(l.prototype,"edit",{get:function(){return this.initDocumentChanges(),this._changeAnnotations!==void 0&&(this._changeAnnotations.size===0?this._workspaceEdit.changeAnnotations=void 0:this._workspaceEdit.changeAnnotations=this._changeAnnotations.all()),this._workspaceEdit},enumerable:!1,configurable:!0}),l.prototype.getTextEditChange=function(h){if(Ae.is(h)){if(this.initDocumentChanges(),this._workspaceEdit.documentChanges===void 0)throw new Error("Workspace edit is not configured for document changes.");var y={uri:h.uri,version:h.version},f=this._textEditChanges[y.uri];if(!f){var a=[],P={textDocument:y,edits:a};this._workspaceEdit.documentChanges.push(P),f=new I(a,this._changeAnnotations),this._textEditChanges[y.uri]=f}return f}else{if(this.initChanges(),this._workspaceEdit.changes===void 0)throw new Error("Workspace edit is not configured for normal text edit changes.");var f=this._textEditChanges[h];if(!f){var a=[];this._workspaceEdit.changes[h]=a,f=new I(a),this._textEditChanges[h]=f}return f}},l.prototype.initDocumentChanges=function(){this._workspaceEdit.documentChanges===void 0&&this._workspaceEdit.changes===void 0&&(this._changeAnnotations=new ie,this._workspaceEdit.documentChanges=[],this._workspaceEdit.changeAnnotations=this._changeAnnotations.all())},l.prototype.initChanges=function(){this._workspaceEdit.documentChanges===void 0&&this._workspaceEdit.changes===void 0&&(this._workspaceEdit.changes=Object.create(null))},l.prototype.createFile=function(h,y,f){if(this.initDocumentChanges(),this._workspaceEdit.documentChanges===void 0)throw new Error("Workspace edit is not configured for document changes.");var a;Z.is(y)||ue.is(y)?a=y:f=y;var P,k;if(a===void 0?P=ft.create(h,f):(k=ue.is(a)?a:this._changeAnnotations.manage(a),P=ft.create(h,f,k)),this._workspaceEdit.documentChanges.push(P),k!==void 0)return k},l.prototype.renameFile=function(h,y,f,a){if(this.initDocumentChanges(),this._workspaceEdit.documentChanges===void 0)throw new Error("Workspace edit is not configured for document changes.");var P;Z.is(f)||ue.is(f)?P=f:a=f;var k,J;if(P===void 0?k=j.create(h,y,a):(J=ue.is(P)?P:this._changeAnnotations.manage(P),k=j.create(h,y,a,J)),this._workspaceEdit.documentChanges.push(k),J!==void 0)return J},l.prototype.deleteFile=function(h,y,f){if(this.initDocumentChanges(),this._workspaceEdit.documentChanges===void 0)throw new Error("Workspace edit is not configured for document changes.");var a;Z.is(y)||ue.is(y)?a=y:f=y;var P,k;if(a===void 0?P=x.create(h,f):(k=ue.is(a)?a:this._changeAnnotations.manage(a),P=x.create(h,f,k)),this._workspaceEdit.documentChanges.push(P),k!==void 0)return k},l}();t.WorkspaceChange=X;var K;(function(l){function h(f){return{uri:f}}l.create=h;function y(f){var a=f;return C.defined(a)&&C.string(a.uri)}l.is=y})(K=t.TextDocumentIdentifier||(t.TextDocumentIdentifier={}));var Ve;(function(l){function h(f,a){return{uri:f,version:a}}l.create=h;function y(f){var a=f;return C.defined(a)&&C.string(a.uri)&&C.integer(a.version)}l.is=y})(Ve=t.VersionedTextDocumentIdentifier||(t.VersionedTextDocumentIdentifier={}));var Ae;(function(l){function h(f,a){return{uri:f,version:a}}l.create=h;function y(f){var a=f;return C.defined(a)&&C.string(a.uri)&&(a.version===null||C.integer(a.version))}l.is=y})(Ae=t.OptionalVersionedTextDocumentIdentifier||(t.OptionalVersionedTextDocumentIdentifier={}));var ce;(function(l){function h(f,a,P,k){return{uri:f,languageId:a,version:P,text:k}}l.create=h;function y(f){var a=f;return C.defined(a)&&C.string(a.uri)&&C.string(a.languageId)&&C.integer(a.version)&&C.string(a.text)}l.is=y})(ce=t.TextDocumentItem||(t.TextDocumentItem={}));var St;(function(l){l.PlainText="plaintext",l.Markdown="markdown";function h(y){var f=y;return f===l.PlainText||f===l.Markdown}l.is=h})(St=t.MarkupKind||(t.MarkupKind={}));var kn;(function(l){function h(y){var f=y;return C.objectLiteral(y)&&St.is(f.kind)&&C.string(f.value)}l.is=h})(kn=t.MarkupContent||(t.MarkupContent={}));var G;(function(l){l.Text=1,l.Method=2,l.Function=3,l.Constructor=4,l.Field=5,l.Variable=6,l.Class=7,l.Interface=8,l.Module=9,l.Property=10,l.Unit=11,l.Value=12,l.Enum=13,l.Keyword=14,l.Snippet=15,l.Color=16,l.File=17,l.Reference=18,l.Folder=19,l.EnumMember=20,l.Constant=21,l.Struct=22,l.Event=23,l.Operator=24,l.TypeParameter=25})(G=t.CompletionItemKind||(t.CompletionItemKind={}));var Gr;(function(l){l.PlainText=1,l.Snippet=2})(Gr=t.InsertTextFormat||(t.InsertTextFormat={}));var Jr;(function(l){l.Deprecated=1})(Jr=t.CompletionItemTag||(t.CompletionItemTag={}));var Yo;(function(l){function h(f,a,P){return{newText:f,insert:a,replace:P}}l.create=h;function y(f){var a=f;return a&&C.string(a.newText)&&u.is(a.insert)&&u.is(a.replace)}l.is=y})(Yo=t.InsertReplaceEdit||(t.InsertReplaceEdit={}));var Vo;(function(l){l.asIs=1,l.adjustIndentation=2})(Vo=t.InsertTextMode||(t.InsertTextMode={}));var Ko;(function(l){function h(y){var f=y;return f&&(C.string(f.detail)||f.detail===void 0)&&(C.string(f.description)||f.description===void 0)}l.is=h})(Ko=t.CompletionItemLabelDetails||(t.CompletionItemLabelDetails={}));var Go;(function(l){function h(y){return{label:y}}l.create=h})(Go=t.CompletionItem||(t.CompletionItem={}));var Jo;(function(l){function h(y,f){return{items:y||[],isIncomplete:!!f}}l.create=h})(Jo=t.CompletionList||(t.CompletionList={}));var dr;(function(l){function h(f){return f.replace(/[\\`*_{}[\]()#+\-.!]/g,"\\$&")}l.fromPlainText=h;function y(f){var a=f;return C.string(a)||C.objectLiteral(a)&&C.string(a.language)&&C.string(a.value)}l.is=y})(dr=t.MarkedString||(t.MarkedString={}));var Tt;(function(l){function h(y){var f=y;return!!f&&C.objectLiteral(f)&&(kn.is(f.contents)||dr.is(f.contents)||C.typedArray(f.contents,dr.is))&&(y.range===void 0||u.is(y.range))}l.is=h})(Tt=t.Hover||(t.Hover={}));var Qo;(function(l){function h(y,f){return f?{label:y,documentation:f}:{label:y}}l.create=h})(Qo=t.ParameterInformation||(t.ParameterInformation={}));var Xo;(function(l){function h(y,f){for(var a=[],P=2;P<arguments.length;P++)a[P-2]=arguments[P];var k={label:y};return C.defined(f)&&(k.documentation=f),C.defined(a)?k.parameters=a:k.parameters=[],k}l.create=h})(Xo=t.SignatureInformation||(t.SignatureInformation={}));var An;(function(l){l.Text=1,l.Read=2,l.Write=3})(An=t.DocumentHighlightKind||(t.DocumentHighlightKind={}));var Zo;(function(l){function h(y,f){var a={range:y};return C.number(f)&&(a.kind=f),a}l.create=h})(Zo=t.DocumentHighlight||(t.DocumentHighlight={}));var fr;(function(l){l.File=1,l.Module=2,l.Namespace=3,l.Package=4,l.Class=5,l.Method=6,l.Property=7,l.Field=8,l.Constructor=9,l.Enum=10,l.Interface=11,l.Function=12,l.Variable=13,l.Constant=14,l.String=15,l.Number=16,l.Boolean=17,l.Array=18,l.Object=19,l.Key=20,l.Null=21,l.EnumMember=22,l.Struct=23,l.Event=24,l.Operator=25,l.TypeParameter=26})(fr=t.SymbolKind||(t.SymbolKind={}));var es;(function(l){l.Deprecated=1})(es=t.SymbolTag||(t.SymbolTag={}));var Kt;(function(l){function h(y,f,a,P,k){var J={name:y,kind:f,location:{uri:P,range:a}};return k&&(J.containerName=k),J}l.create=h})(Kt=t.SymbolInformation||(t.SymbolInformation={}));var pn;(function(l){function h(y,f,a,P){return P!==void 0?{name:y,kind:f,location:{uri:a,range:P}}:{name:y,kind:f,location:{uri:a}}}l.create=h})(pn=t.WorkspaceSymbol||(t.WorkspaceSymbol={}));var ts;(function(l){function h(f,a,P,k,J,_e){var fe={name:f,detail:a,kind:P,range:k,selectionRange:J};return _e!==void 0&&(fe.children=_e),fe}l.create=h;function y(f){var a=f;return a&&C.string(a.name)&&C.number(a.kind)&&u.is(a.range)&&u.is(a.selectionRange)&&(a.detail===void 0||C.string(a.detail))&&(a.deprecated===void 0||C.boolean(a.deprecated))&&(a.children===void 0||Array.isArray(a.children))&&(a.tags===void 0||Array.isArray(a.tags))}l.is=y})(ts=t.DocumentSymbol||(t.DocumentSymbol={}));var ns;(function(l){l.Empty="",l.QuickFix="quickfix",l.Refactor="refactor",l.RefactorExtract="refactor.extract",l.RefactorInline="refactor.inline",l.RefactorRewrite="refactor.rewrite",l.Source="source",l.SourceOrganizeImports="source.organizeImports",l.SourceFixAll="source.fixAll"})(ns=t.CodeActionKind||(t.CodeActionKind={}));var Lt;(function(l){l.Invoked=1,l.Automatic=2})(Lt=t.CodeActionTriggerKind||(t.CodeActionTriggerKind={}));var Qr;(function(l){function h(f,a,P){var k={diagnostics:f};return a!=null&&(k.only=a),P!=null&&(k.triggerKind=P),k}l.create=h;function y(f){var a=f;return C.defined(a)&&C.typedArray(a.diagnostics,v.is)&&(a.only===void 0||C.typedArray(a.only,C.string))&&(a.triggerKind===void 0||a.triggerKind===Lt.Invoked||a.triggerKind===Lt.Automatic)}l.is=y})(Qr=t.CodeActionContext||(t.CodeActionContext={}));var Xr;(function(l){function h(f,a,P){var k={title:f},J=!0;return typeof a=="string"?(J=!1,k.kind=a):N.is(a)?k.command=a:k.edit=a,J&&P!==void 0&&(k.kind=P),k}l.create=h;function y(f){var a=f;return a&&C.string(a.title)&&(a.diagnostics===void 0||C.typedArray(a.diagnostics,v.is))&&(a.kind===void 0||C.string(a.kind))&&(a.edit!==void 0||a.command!==void 0)&&(a.command===void 0||N.is(a.command))&&(a.isPreferred===void 0||C.boolean(a.isPreferred))&&(a.edit===void 0||H.is(a.edit))}l.is=y})(Xr=t.CodeAction||(t.CodeAction={}));var pr;(function(l){function h(f,a){var P={range:f};return C.defined(a)&&(P.data=a),P}l.create=h;function y(f){var a=f;return C.defined(a)&&u.is(a.range)&&(C.undefined(a.command)||N.is(a.command))}l.is=y})(pr=t.CodeLens||(t.CodeLens={}));var Zr;(function(l){function h(f,a){return{tabSize:f,insertSpaces:a}}l.create=h;function y(f){var a=f;return C.defined(a)&&C.uinteger(a.tabSize)&&C.boolean(a.insertSpaces)}l.is=y})(Zr=t.FormattingOptions||(t.FormattingOptions={}));var Gt;(function(l){function h(f,a,P){return{range:f,target:a,data:P}}l.create=h;function y(f){var a=f;return C.defined(a)&&u.is(a.range)&&(C.undefined(a.target)||C.string(a.target))}l.is=y})(Gt=t.DocumentLink||(t.DocumentLink={}));var m;(function(l){function h(f,a){return{range:f,parent:a}}l.create=h;function y(f){var a=f;return C.objectLiteral(a)&&u.is(a.range)&&(a.parent===void 0||l.is(a.parent))}l.is=y})(m=t.SelectionRange||(t.SelectionRange={}));var w;(function(l){l.namespace="namespace",l.type="type",l.class="class",l.enum="enum",l.interface="interface",l.struct="struct",l.typeParameter="typeParameter",l.parameter="parameter",l.variable="variable",l.property="property",l.enumMember="enumMember",l.event="event",l.function="function",l.method="method",l.macro="macro",l.keyword="keyword",l.modifier="modifier",l.comment="comment",l.string="string",l.number="number",l.regexp="regexp",l.operator="operator",l.decorator="decorator"})(w=t.SemanticTokenTypes||(t.SemanticTokenTypes={}));var E;(function(l){l.declaration="declaration",l.definition="definition",l.readonly="readonly",l.static="static",l.deprecated="deprecated",l.abstract="abstract",l.async="async",l.modification="modification",l.documentation="documentation",l.defaultLibrary="defaultLibrary"})(E=t.SemanticTokenModifiers||(t.SemanticTokenModifiers={}));var F;(function(l){function h(y){var f=y;return C.objectLiteral(f)&&(f.resultId===void 0||typeof f.resultId=="string")&&Array.isArray(f.data)&&(f.data.length===0||typeof f.data[0]=="number")}l.is=h})(F=t.SemanticTokens||(t.SemanticTokens={}));var le;(function(l){function h(f,a){return{range:f,text:a}}l.create=h;function y(f){var a=f;return a!=null&&u.is(a.range)&&C.string(a.text)}l.is=y})(le=t.InlineValueText||(t.InlineValueText={}));var se;(function(l){function h(f,a,P){return{range:f,variableName:a,caseSensitiveLookup:P}}l.create=h;function y(f){var a=f;return a!=null&&u.is(a.range)&&C.boolean(a.caseSensitiveLookup)&&(C.string(a.variableName)||a.variableName===void 0)}l.is=y})(se=t.InlineValueVariableLookup||(t.InlineValueVariableLookup={}));var me;(function(l){function h(f,a){return{range:f,expression:a}}l.create=h;function y(f){var a=f;return a!=null&&u.is(a.range)&&(C.string(a.expression)||a.expression===void 0)}l.is=y})(me=t.InlineValueEvaluatableExpression||(t.InlineValueEvaluatableExpression={}));var he;(function(l){function h(f,a){return{frameId:f,stoppedLocation:a}}l.create=h;function y(f){var a=f;return C.defined(a)&&u.is(f.stoppedLocation)}l.is=y})(he=t.InlineValueContext||(t.InlineValueContext={}));var ee;(function(l){l.Type=1,l.Parameter=2;function h(y){return y===1||y===2}l.is=h})(ee=t.InlayHintKind||(t.InlayHintKind={}));var de;(function(l){function h(f){return{value:f}}l.create=h;function y(f){var a=f;return C.objectLiteral(a)&&(a.tooltip===void 0||C.string(a.tooltip)||kn.is(a.tooltip))&&(a.location===void 0||c.is(a.location))&&(a.command===void 0||N.is(a.command))}l.is=y})(de=t.InlayHintLabelPart||(t.InlayHintLabelPart={}));var oe;(function(l){function h(f,a,P){var k={position:f,label:a};return P!==void 0&&(k.kind=P),k}l.create=h;function y(f){var a=f;return C.objectLiteral(a)&&s.is(a.position)&&(C.string(a.label)||C.typedArray(a.label,de.is))&&(a.kind===void 0||ee.is(a.kind))&&a.textEdits===void 0||C.typedArray(a.textEdits,z.is)&&(a.tooltip===void 0||C.string(a.tooltip)||kn.is(a.tooltip))&&(a.paddingLeft===void 0||C.boolean(a.paddingLeft))&&(a.paddingRight===void 0||C.boolean(a.paddingRight))}l.is=y})(oe=t.InlayHint||(t.InlayHint={}));var De;(function(l){function h(y){var f=y;return C.objectLiteral(f)&&r.is(f.uri)&&C.string(f.name)}l.is=h})(De=t.WorkspaceFolder||(t.WorkspaceFolder={})),t.EOL=[`
63
+ `)),w){let F=m.error?` Request failed: ${m.error.message} (${m.error.code}).`:"";z.log(`Received response '${w.method} - (${m.id})' in ${Date.now()-w.timerStart}ms.${F}`,E)}else z.log(`Received response ${m.id} without active response promise.`,E)}else Kt("receive-response",m)}function Kt(m,w){if(!z||v===ae.Off)return;let E={isLSPMessage:!0,type:m,message:w,timestamp:Date.now()};z.log(E)}function pn(){if(Ae())throw new tn(Ji.Closed,"Connection is closed.");if(ce())throw new tn(Ji.Disposed,"Connection is disposed.")}function ts(){if(Ve())throw new tn(Ji.AlreadyListening,"Connection is already listening")}function ns(){if(!Ve())throw new Error("Call listen() first.")}function Lt(m){return m===void 0?null:m}function Qr(m){if(m!==null)return m}function Xr(m){return m!=null&&!Array.isArray(m)&&typeof m=="object"}function pr(m,w){switch(m){case $.ParameterStructures.auto:return Xr(w)?Qr(w):[Lt(w)];case $.ParameterStructures.byName:if(!Xr(w))throw new Error("Received parameters by name but param is not an object literal.");return Qr(w);case $.ParameterStructures.byPosition:return[Lt(w)];default:throw new Error(`Unknown parameter structure ${m.toString()}`)}}function Zr(m,w){let E,F=m.numberOfParams;switch(F){case 0:E=void 0;break;case 1:E=pr(m.parameterStructures,w[0]);break;default:E=[];for(let le=0;le<w.length&&le<F;le++)E.push(Lt(w[le]));if(w.length<F)for(let le=w.length;le<F;le++)E.push(null);break}return E}let Gt={sendNotification:(m,...w)=>{pn();let E,F;if(ve.string(m)){E=m;let se=w[0],me=0,he=$.ParameterStructures.auto;$.ParameterStructures.is(se)&&(me=1,he=se);let ee=w.length,de=ee-me;switch(de){case 0:F=void 0;break;case 1:F=pr(he,w[me]);break;default:if(he===$.ParameterStructures.byName)throw new Error(`Received ${de} parameters for 'by Name' notification parameter structure.`);F=w.slice(me,ee).map(oe=>Lt(oe));break}}else{let se=w;E=m.method,F=Zr(m,se)}let le={jsonrpc:c,method:E,params:F};return Xo(le),t.write(le).catch(se=>{throw i.error("Sending notification failed."),se})},onNotification:(m,w)=>{pn();let E;return ve.func(m)?b=m:w&&(ve.string(m)?(E=m,R.set(m,{type:void 0,handler:w})):(E=m.method,R.set(m.method,{type:m,handler:w}))),{dispose:()=>{E!==void 0?R.delete(E):b=void 0}}},onProgress:(m,w,E)=>{if(D.has(w))throw new Error(`Progress handler for token ${w} already registered`);return D.set(w,E),{dispose:()=>{D.delete(w)}}},sendProgress:(m,w,E)=>Gt.sendNotification(xr.type,{token:w,value:E}),onUnhandledProgress:ft.event,sendRequest:(m,...w)=>{pn(),ns();let E,F,le;if(ve.string(m)){E=m;let ee=w[0],de=w[w.length-1],oe=0,De=$.ParameterStructures.auto;$.ParameterStructures.is(ee)&&(oe=1,De=ee);let Le=w.length;Ka.CancellationToken.is(de)&&(Le=Le-1,le=de);let it=Le-oe;switch(it){case 0:F=void 0;break;case 1:F=pr(De,w[oe]);break;default:if(De===$.ParameterStructures.byName)throw new Error(`Received ${it} parameters for 'by Name' request parameter structure.`);F=w.slice(oe,Le).map(C=>Lt(C));break}}else{let ee=w;E=m.method,F=Zr(m,ee);let de=m.numberOfParams;le=Ka.CancellationToken.is(ee[de])?ee[de]:void 0}let se=o++,me;le&&(me=le.onCancellationRequested(()=>{let ee=x.sender.sendCancellation(Gt,se);return ee===void 0?(i.log(`Received no promise from cancellation strategy when cancelling id ${se}`),Promise.resolve()):ee.catch(()=>{i.log(`Sending cancellation messages for id ${se} failed`)})}));let he={jsonrpc:c,id:se,method:E,params:F};return Qo(he),typeof x.sender.enableCancellation=="function"&&x.sender.enableCancellation(he),new Promise(async(ee,de)=>{let oe=it=>{ee(it),x.sender.cleanup(se),me?.dispose()},De=it=>{de(it),x.sender.cleanup(se),me?.dispose()},Le={method:E,timerStart:Date.now(),resolve:oe,reject:De};try{await t.write(he),B.set(se,Le)}catch(it){throw i.error("Sending request failed."),Le.reject(new $.ResponseError($.ErrorCodes.MessageWriteError,it.message?it.message:"Unknown reason")),it}})},onRequest:(m,w)=>{pn();let E=null;return Ja.is(m)?(E=void 0,p=m):ve.string(m)?(E=null,w!==void 0&&(E=m,g.set(m,{handler:w,type:void 0}))):w!==void 0&&(E=m.method,g.set(m.method,{type:m,handler:w})),{dispose:()=>{E!==null&&(E!==void 0?g.delete(E):p=void 0)}}},hasPendingResponse:()=>B.size>0,trace:async(m,w,E)=>{let F=!1,le=ht.Text;E!==void 0&&(ve.boolean(E)?F=E:(F=E.sendNotification||!1,le=E.traceFormat||ht.Text)),v=m,N=le,v===ae.Off?z=void 0:z=w,F&&!Ae()&&!ce()&&await Gt.sendNotification(yd.type,{value:ae.toString(m)})},onError:ue.event,onClose:ze.event,onUnhandledNotification:dt.event,onDispose:j.event,end:()=>{t.end()},dispose:()=>{if(ce())return;Z=yt.Disposed,j.fire(void 0);let m=new $.ResponseError($.ErrorCodes.PendingResponseRejected,"Pending response rejected since connection got disposed");for(let w of B.values())w.reject(m);B=new Map,_=new Map,L=new Set,q=new md.LinkedMap,ve.func(t.dispose)&&t.dispose(),ve.func(e.dispose)&&e.dispose()},listen:()=>{pn(),ts(),Z=yt.Listening,e.listen(Vo)},inspect:()=>{(0,gd.default)().console.log("inspect")}};return Gt.onNotification(Qa.type,m=>{if(v===ae.Off||!z)return;let w=v===ae.Verbose||v===ae.Compact;z.log(m.message,w?m.verbose:void 0)}),Gt.onNotification(xr.type,m=>{let w=D.get(m.token);w?w(m.value):ft.fire(m)}),Gt}W.createMessageConnection=Rb});var Qi=A(S=>{"use strict";Object.defineProperty(S,"__esModule",{value:!0});S.ProgressType=S.ProgressToken=S.createMessageConnection=S.NullLogger=S.ConnectionOptions=S.ConnectionStrategy=S.AbstractMessageBuffer=S.WriteableStreamMessageWriter=S.AbstractMessageWriter=S.MessageWriter=S.ReadableStreamMessageReader=S.AbstractMessageReader=S.MessageReader=S.SharedArrayReceiverStrategy=S.SharedArraySenderStrategy=S.CancellationToken=S.CancellationTokenSource=S.Emitter=S.Event=S.Disposable=S.LRUCache=S.Touch=S.LinkedMap=S.ParameterStructures=S.NotificationType9=S.NotificationType8=S.NotificationType7=S.NotificationType6=S.NotificationType5=S.NotificationType4=S.NotificationType3=S.NotificationType2=S.NotificationType1=S.NotificationType0=S.NotificationType=S.ErrorCodes=S.ResponseError=S.RequestType9=S.RequestType8=S.RequestType7=S.RequestType6=S.RequestType5=S.RequestType4=S.RequestType3=S.RequestType2=S.RequestType1=S.RequestType0=S.RequestType=S.Message=S.RAL=void 0;S.MessageStrategy=S.CancellationStrategy=S.CancellationSenderStrategy=S.CancellationReceiverStrategy=S.ConnectionError=S.ConnectionErrors=S.LogTraceNotification=S.SetTraceNotification=S.TraceFormat=S.TraceValues=S.Trace=void 0;var pe=Sa();Object.defineProperty(S,"Message",{enumerable:!0,get:function(){return pe.Message}});Object.defineProperty(S,"RequestType",{enumerable:!0,get:function(){return pe.RequestType}});Object.defineProperty(S,"RequestType0",{enumerable:!0,get:function(){return pe.RequestType0}});Object.defineProperty(S,"RequestType1",{enumerable:!0,get:function(){return pe.RequestType1}});Object.defineProperty(S,"RequestType2",{enumerable:!0,get:function(){return pe.RequestType2}});Object.defineProperty(S,"RequestType3",{enumerable:!0,get:function(){return pe.RequestType3}});Object.defineProperty(S,"RequestType4",{enumerable:!0,get:function(){return pe.RequestType4}});Object.defineProperty(S,"RequestType5",{enumerable:!0,get:function(){return pe.RequestType5}});Object.defineProperty(S,"RequestType6",{enumerable:!0,get:function(){return pe.RequestType6}});Object.defineProperty(S,"RequestType7",{enumerable:!0,get:function(){return pe.RequestType7}});Object.defineProperty(S,"RequestType8",{enumerable:!0,get:function(){return pe.RequestType8}});Object.defineProperty(S,"RequestType9",{enumerable:!0,get:function(){return pe.RequestType9}});Object.defineProperty(S,"ResponseError",{enumerable:!0,get:function(){return pe.ResponseError}});Object.defineProperty(S,"ErrorCodes",{enumerable:!0,get:function(){return pe.ErrorCodes}});Object.defineProperty(S,"NotificationType",{enumerable:!0,get:function(){return pe.NotificationType}});Object.defineProperty(S,"NotificationType0",{enumerable:!0,get:function(){return pe.NotificationType0}});Object.defineProperty(S,"NotificationType1",{enumerable:!0,get:function(){return pe.NotificationType1}});Object.defineProperty(S,"NotificationType2",{enumerable:!0,get:function(){return pe.NotificationType2}});Object.defineProperty(S,"NotificationType3",{enumerable:!0,get:function(){return pe.NotificationType3}});Object.defineProperty(S,"NotificationType4",{enumerable:!0,get:function(){return pe.NotificationType4}});Object.defineProperty(S,"NotificationType5",{enumerable:!0,get:function(){return pe.NotificationType5}});Object.defineProperty(S,"NotificationType6",{enumerable:!0,get:function(){return pe.NotificationType6}});Object.defineProperty(S,"NotificationType7",{enumerable:!0,get:function(){return pe.NotificationType7}});Object.defineProperty(S,"NotificationType8",{enumerable:!0,get:function(){return pe.NotificationType8}});Object.defineProperty(S,"NotificationType9",{enumerable:!0,get:function(){return pe.NotificationType9}});Object.defineProperty(S,"ParameterStructures",{enumerable:!0,get:function(){return pe.ParameterStructures}});var rc=xa();Object.defineProperty(S,"LinkedMap",{enumerable:!0,get:function(){return rc.LinkedMap}});Object.defineProperty(S,"LRUCache",{enumerable:!0,get:function(){return rc.LRUCache}});Object.defineProperty(S,"Touch",{enumerable:!0,get:function(){return rc.Touch}});var Db=sd();Object.defineProperty(S,"Disposable",{enumerable:!0,get:function(){return Db.Disposable}});var Pd=Gn();Object.defineProperty(S,"Event",{enumerable:!0,get:function(){return Pd.Event}});Object.defineProperty(S,"Emitter",{enumerable:!0,get:function(){return Pd.Emitter}});var _d=$i();Object.defineProperty(S,"CancellationTokenSource",{enumerable:!0,get:function(){return _d.CancellationTokenSource}});Object.defineProperty(S,"CancellationToken",{enumerable:!0,get:function(){return _d.CancellationToken}});var Rd=ad();Object.defineProperty(S,"SharedArraySenderStrategy",{enumerable:!0,get:function(){return Rd.SharedArraySenderStrategy}});Object.defineProperty(S,"SharedArrayReceiverStrategy",{enumerable:!0,get:function(){return Rd.SharedArrayReceiverStrategy}});var ic=cd();Object.defineProperty(S,"MessageReader",{enumerable:!0,get:function(){return ic.MessageReader}});Object.defineProperty(S,"AbstractMessageReader",{enumerable:!0,get:function(){return ic.AbstractMessageReader}});Object.defineProperty(S,"ReadableStreamMessageReader",{enumerable:!0,get:function(){return ic.ReadableStreamMessageReader}});var oc=fd();Object.defineProperty(S,"MessageWriter",{enumerable:!0,get:function(){return oc.MessageWriter}});Object.defineProperty(S,"AbstractMessageWriter",{enumerable:!0,get:function(){return oc.AbstractMessageWriter}});Object.defineProperty(S,"WriteableStreamMessageWriter",{enumerable:!0,get:function(){return oc.WriteableStreamMessageWriter}});var Sb=pd();Object.defineProperty(S,"AbstractMessageBuffer",{enumerable:!0,get:function(){return Sb.AbstractMessageBuffer}});var We=Cd();Object.defineProperty(S,"ConnectionStrategy",{enumerable:!0,get:function(){return We.ConnectionStrategy}});Object.defineProperty(S,"ConnectionOptions",{enumerable:!0,get:function(){return We.ConnectionOptions}});Object.defineProperty(S,"NullLogger",{enumerable:!0,get:function(){return We.NullLogger}});Object.defineProperty(S,"createMessageConnection",{enumerable:!0,get:function(){return We.createMessageConnection}});Object.defineProperty(S,"ProgressToken",{enumerable:!0,get:function(){return We.ProgressToken}});Object.defineProperty(S,"ProgressType",{enumerable:!0,get:function(){return We.ProgressType}});Object.defineProperty(S,"Trace",{enumerable:!0,get:function(){return We.Trace}});Object.defineProperty(S,"TraceValues",{enumerable:!0,get:function(){return We.TraceValues}});Object.defineProperty(S,"TraceFormat",{enumerable:!0,get:function(){return We.TraceFormat}});Object.defineProperty(S,"SetTraceNotification",{enumerable:!0,get:function(){return We.SetTraceNotification}});Object.defineProperty(S,"LogTraceNotification",{enumerable:!0,get:function(){return We.LogTraceNotification}});Object.defineProperty(S,"ConnectionErrors",{enumerable:!0,get:function(){return We.ConnectionErrors}});Object.defineProperty(S,"ConnectionError",{enumerable:!0,get:function(){return We.ConnectionError}});Object.defineProperty(S,"CancellationReceiverStrategy",{enumerable:!0,get:function(){return We.CancellationReceiverStrategy}});Object.defineProperty(S,"CancellationSenderStrategy",{enumerable:!0,get:function(){return We.CancellationSenderStrategy}});Object.defineProperty(S,"CancellationStrategy",{enumerable:!0,get:function(){return We.CancellationStrategy}});Object.defineProperty(S,"MessageStrategy",{enumerable:!0,get:function(){return We.MessageStrategy}});var Tb=en();S.RAL=Tb.default});var Sd=A(uc=>{"use strict";Object.defineProperty(uc,"__esModule",{value:!0});var At=Qi(),Xn=class extends At.AbstractMessageBuffer{constructor(t="utf-8"){super(t),this.asciiDecoder=new TextDecoder("ascii")}emptyBuffer(){return Xn.emptyBuffer}fromString(t,n){return new TextEncoder().encode(t)}toString(t,n){return n==="ascii"?this.asciiDecoder.decode(t):new TextDecoder(n).decode(t)}asNative(t,n){return n===void 0?t:t.slice(0,n)}allocNative(t){return new Uint8Array(t)}};Xn.emptyBuffer=new Uint8Array(0);var sc=class{constructor(t){this.socket=t,this._onData=new At.Emitter,this._messageListener=n=>{n.data.arrayBuffer().then(i=>{this._onData.fire(new Uint8Array(i))},()=>{(0,At.RAL)().console.error("Converting blob to array buffer failed.")})},this.socket.addEventListener("message",this._messageListener)}onClose(t){return this.socket.addEventListener("close",t),At.Disposable.create(()=>this.socket.removeEventListener("close",t))}onError(t){return this.socket.addEventListener("error",t),At.Disposable.create(()=>this.socket.removeEventListener("error",t))}onEnd(t){return this.socket.addEventListener("end",t),At.Disposable.create(()=>this.socket.removeEventListener("end",t))}onData(t){return this._onData.event(t)}},ac=class{constructor(t){this.socket=t}onClose(t){return this.socket.addEventListener("close",t),At.Disposable.create(()=>this.socket.removeEventListener("close",t))}onError(t){return this.socket.addEventListener("error",t),At.Disposable.create(()=>this.socket.removeEventListener("error",t))}onEnd(t){return this.socket.addEventListener("end",t),At.Disposable.create(()=>this.socket.removeEventListener("end",t))}write(t,n){if(typeof t=="string"){if(n!==void 0&&n!=="utf-8")throw new Error(`In a Browser environments only utf-8 text encoding is supported. But got encoding: ${n}`);this.socket.send(t)}else this.socket.send(t);return Promise.resolve()}end(){this.socket.close()}},xb=new TextEncoder,Dd=Object.freeze({messageBuffer:Object.freeze({create:e=>new Xn(e)}),applicationJson:Object.freeze({encoder:Object.freeze({name:"application/json",encode:(e,t)=>{if(t.charset!=="utf-8")throw new Error(`In a Browser environments only utf-8 text encoding is supported. But got encoding: ${t.charset}`);return Promise.resolve(xb.encode(JSON.stringify(e,void 0,0)))}}),decoder:Object.freeze({name:"application/json",decode:(e,t)=>{if(!(e instanceof Uint8Array))throw new Error("In a Browser environments only Uint8Arrays are supported.");return Promise.resolve(JSON.parse(new TextDecoder(t.charset).decode(e)))}})}),stream:Object.freeze({asReadableStream:e=>new sc(e),asWritableStream:e=>new ac(e)}),console,timer:Object.freeze({setTimeout(e,t,...n){let r=setTimeout(e,t,...n);return{dispose:()=>clearTimeout(r)}},setImmediate(e,...t){let n=setTimeout(e,0,...t);return{dispose:()=>clearTimeout(n)}},setInterval(e,t,...n){let r=setInterval(e,t,...n);return{dispose:()=>clearInterval(r)}}})});function cc(){return Dd}(function(e){function t(){At.RAL.install(Dd)}e.install=t})(cc||(cc={}));uc.default=cc});var Tn=A(rt=>{"use strict";var wb=rt&&rt.__createBinding||(Object.create?function(e,t,n,r){r===void 0&&(r=n);var i=Object.getOwnPropertyDescriptor(t,n);(!i||("get"in i?!t.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:function(){return t[n]}}),Object.defineProperty(e,r,i)}:function(e,t,n,r){r===void 0&&(r=n),e[r]=t[n]}),kb=rt&&rt.__exportStar||function(e,t){for(var n in e)n!=="default"&&!Object.prototype.hasOwnProperty.call(t,n)&&wb(t,e,n)};Object.defineProperty(rt,"__esModule",{value:!0});rt.createMessageConnection=rt.BrowserMessageWriter=rt.BrowserMessageReader=void 0;var Ab=Sd();Ab.default.install();var Zn=Qi();kb(Qi(),rt);var lc=class extends Zn.AbstractMessageReader{constructor(t){super(),this._onData=new Zn.Emitter,this._messageListener=n=>{this._onData.fire(n.data)},t.addEventListener("error",n=>this.fireError(n)),t.onmessage=this._messageListener}listen(t){return this._onData.event(t)}};rt.BrowserMessageReader=lc;var dc=class extends Zn.AbstractMessageWriter{constructor(t){super(),this.port=t,this.errorCount=0,t.addEventListener("error",n=>this.fireError(n))}write(t){try{return this.port.postMessage(t),Promise.resolve()}catch(n){return this.handleError(n,t),Promise.reject(n)}}handleError(t,n){this.errorCount++,this.fireError(t,n,this.errorCount)}end(){}};rt.BrowserMessageWriter=dc;function qb(e,t,n,r){return n===void 0&&(n=Zn.NullLogger),Zn.ConnectionStrategy.is(r)&&(r={connectionStrategy:r}),(0,Zn.createMessageConnection)(e,t,n,r)}rt.createMessageConnection=qb});var fc=A((vD,Td)=>{"use strict";Td.exports=Tn()});var Zi=A((xd,Xi)=>{(function(e){if(typeof Xi=="object"&&typeof Xi.exports=="object"){var t=e(eu,xd);t!==void 0&&(Xi.exports=t)}else typeof define=="function"&&define.amd&&define(["require","exports"],e)})(function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.TextDocument=t.EOL=t.WorkspaceFolder=t.InlayHint=t.InlayHintLabelPart=t.InlayHintKind=t.InlineValueContext=t.InlineValueEvaluatableExpression=t.InlineValueVariableLookup=t.InlineValueText=t.SemanticTokens=t.SemanticTokenModifiers=t.SemanticTokenTypes=t.SelectionRange=t.DocumentLink=t.FormattingOptions=t.CodeLens=t.CodeAction=t.CodeActionContext=t.CodeActionTriggerKind=t.CodeActionKind=t.DocumentSymbol=t.WorkspaceSymbol=t.SymbolInformation=t.SymbolTag=t.SymbolKind=t.DocumentHighlight=t.DocumentHighlightKind=t.SignatureInformation=t.ParameterInformation=t.Hover=t.MarkedString=t.CompletionList=t.CompletionItem=t.CompletionItemLabelDetails=t.InsertTextMode=t.InsertReplaceEdit=t.CompletionItemTag=t.InsertTextFormat=t.CompletionItemKind=t.MarkupContent=t.MarkupKind=t.TextDocumentItem=t.OptionalVersionedTextDocumentIdentifier=t.VersionedTextDocumentIdentifier=t.TextDocumentIdentifier=t.WorkspaceChange=t.WorkspaceEdit=t.DeleteFile=t.RenameFile=t.CreateFile=t.TextDocumentEdit=t.AnnotatedTextEdit=t.ChangeAnnotationIdentifier=t.ChangeAnnotation=t.TextEdit=t.Command=t.Diagnostic=t.CodeDescription=t.DiagnosticTag=t.DiagnosticSeverity=t.DiagnosticRelatedInformation=t.FoldingRange=t.FoldingRangeKind=t.ColorPresentation=t.ColorInformation=t.Color=t.LocationLink=t.Location=t.Range=t.Position=t.uinteger=t.integer=t.URI=t.DocumentUri=void 0;var n;(function(l){function h(y){return typeof y=="string"}l.is=h})(n=t.DocumentUri||(t.DocumentUri={}));var r;(function(l){function h(y){return typeof y=="string"}l.is=h})(r=t.URI||(t.URI={}));var i;(function(l){l.MIN_VALUE=-2147483648,l.MAX_VALUE=2147483647;function h(y){return typeof y=="number"&&l.MIN_VALUE<=y&&y<=l.MAX_VALUE}l.is=h})(i=t.integer||(t.integer={}));var o;(function(l){l.MIN_VALUE=0,l.MAX_VALUE=2147483647;function h(y){return typeof y=="number"&&l.MIN_VALUE<=y&&y<=l.MAX_VALUE}l.is=h})(o=t.uinteger||(t.uinteger={}));var s;(function(l){function h(f,a){return f===Number.MAX_VALUE&&(f=o.MAX_VALUE),a===Number.MAX_VALUE&&(a=o.MAX_VALUE),{line:f,character:a}}l.create=h;function y(f){var a=f;return C.objectLiteral(a)&&C.uinteger(a.line)&&C.uinteger(a.character)}l.is=y})(s=t.Position||(t.Position={}));var u;(function(l){function h(f,a,P,k){if(C.uinteger(f)&&C.uinteger(a)&&C.uinteger(P)&&C.uinteger(k))return{start:s.create(f,a),end:s.create(P,k)};if(s.is(f)&&s.is(a))return{start:f,end:a};throw new Error("Range#create called with invalid arguments[".concat(f,", ").concat(a,", ").concat(P,", ").concat(k,"]"))}l.create=h;function y(f){var a=f;return C.objectLiteral(a)&&s.is(a.start)&&s.is(a.end)}l.is=y})(u=t.Range||(t.Range={}));var c;(function(l){function h(f,a){return{uri:f,range:a}}l.create=h;function y(f){var a=f;return C.objectLiteral(a)&&u.is(a.range)&&(C.string(a.uri)||C.undefined(a.uri))}l.is=y})(c=t.Location||(t.Location={}));var p;(function(l){function h(f,a,P,k){return{targetUri:f,targetRange:a,targetSelectionRange:P,originSelectionRange:k}}l.create=h;function y(f){var a=f;return C.objectLiteral(a)&&u.is(a.targetRange)&&C.string(a.targetUri)&&u.is(a.targetSelectionRange)&&(u.is(a.originSelectionRange)||C.undefined(a.originSelectionRange))}l.is=y})(p=t.LocationLink||(t.LocationLink={}));var g;(function(l){function h(f,a,P,k){return{red:f,green:a,blue:P,alpha:k}}l.create=h;function y(f){var a=f;return C.objectLiteral(a)&&C.numberRange(a.red,0,1)&&C.numberRange(a.green,0,1)&&C.numberRange(a.blue,0,1)&&C.numberRange(a.alpha,0,1)}l.is=y})(g=t.Color||(t.Color={}));var b;(function(l){function h(f,a){return{range:f,color:a}}l.create=h;function y(f){var a=f;return C.objectLiteral(a)&&u.is(a.range)&&g.is(a.color)}l.is=y})(b=t.ColorInformation||(t.ColorInformation={}));var R;(function(l){function h(f,a,P){return{label:f,textEdit:a,additionalTextEdits:P}}l.create=h;function y(f){var a=f;return C.objectLiteral(a)&&C.string(a.label)&&(C.undefined(a.textEdit)||z.is(a))&&(C.undefined(a.additionalTextEdits)||C.typedArray(a.additionalTextEdits,z.is))}l.is=y})(R=t.ColorPresentation||(t.ColorPresentation={}));var D;(function(l){l.Comment="comment",l.Imports="imports",l.Region="region"})(D=t.FoldingRangeKind||(t.FoldingRangeKind={}));var T;(function(l){function h(f,a,P,k,J,_e){var fe={startLine:f,endLine:a};return C.defined(P)&&(fe.startCharacter=P),C.defined(k)&&(fe.endCharacter=k),C.defined(J)&&(fe.kind=J),C.defined(_e)&&(fe.collapsedText=_e),fe}l.create=h;function y(f){var a=f;return C.objectLiteral(a)&&C.uinteger(a.startLine)&&C.uinteger(a.startLine)&&(C.undefined(a.startCharacter)||C.uinteger(a.startCharacter))&&(C.undefined(a.endCharacter)||C.uinteger(a.endCharacter))&&(C.undefined(a.kind)||C.string(a.kind))}l.is=y})(T=t.FoldingRange||(t.FoldingRange={}));var q;(function(l){function h(f,a){return{location:f,message:a}}l.create=h;function y(f){var a=f;return C.defined(a)&&c.is(a.location)&&C.string(a.message)}l.is=y})(q=t.DiagnosticRelatedInformation||(t.DiagnosticRelatedInformation={}));var B;(function(l){l.Error=1,l.Warning=2,l.Information=3,l.Hint=4})(B=t.DiagnosticSeverity||(t.DiagnosticSeverity={}));var L;(function(l){l.Unnecessary=1,l.Deprecated=2})(L=t.DiagnosticTag||(t.DiagnosticTag={}));var _;(function(l){function h(y){var f=y;return C.objectLiteral(f)&&C.string(f.href)}l.is=h})(_=t.CodeDescription||(t.CodeDescription={}));var v;(function(l){function h(f,a,P,k,J,_e){var fe={range:f,message:a};return C.defined(P)&&(fe.severity=P),C.defined(k)&&(fe.code=k),C.defined(J)&&(fe.source=J),C.defined(_e)&&(fe.relatedInformation=_e),fe}l.create=h;function y(f){var a,P=f;return C.defined(P)&&u.is(P.range)&&C.string(P.message)&&(C.number(P.severity)||C.undefined(P.severity))&&(C.integer(P.code)||C.string(P.code)||C.undefined(P.code))&&(C.undefined(P.codeDescription)||C.string((a=P.codeDescription)===null||a===void 0?void 0:a.href))&&(C.string(P.source)||C.undefined(P.source))&&(C.undefined(P.relatedInformation)||C.typedArray(P.relatedInformation,q.is))}l.is=y})(v=t.Diagnostic||(t.Diagnostic={}));var N;(function(l){function h(f,a){for(var P=[],k=2;k<arguments.length;k++)P[k-2]=arguments[k];var J={title:f,command:a};return C.defined(P)&&P.length>0&&(J.arguments=P),J}l.create=h;function y(f){var a=f;return C.defined(a)&&C.string(a.title)&&C.string(a.command)}l.is=y})(N=t.Command||(t.Command={}));var z;(function(l){function h(P,k){return{range:P,newText:k}}l.replace=h;function y(P,k){return{range:{start:P,end:P},newText:k}}l.insert=y;function f(P){return{range:P,newText:""}}l.del=f;function a(P){var k=P;return C.objectLiteral(k)&&C.string(k.newText)&&u.is(k.range)}l.is=a})(z=t.TextEdit||(t.TextEdit={}));var Z;(function(l){function h(f,a,P){var k={label:f};return a!==void 0&&(k.needsConfirmation=a),P!==void 0&&(k.description=P),k}l.create=h;function y(f){var a=f;return C.objectLiteral(a)&&C.string(a.label)&&(C.boolean(a.needsConfirmation)||a.needsConfirmation===void 0)&&(C.string(a.description)||a.description===void 0)}l.is=y})(Z=t.ChangeAnnotation||(t.ChangeAnnotation={}));var ue;(function(l){function h(y){var f=y;return C.string(f)}l.is=h})(ue=t.ChangeAnnotationIdentifier||(t.ChangeAnnotationIdentifier={}));var ze;(function(l){function h(P,k,J){return{range:P,newText:k,annotationId:J}}l.replace=h;function y(P,k,J){return{range:{start:P,end:P},newText:k,annotationId:J}}l.insert=y;function f(P,k){return{range:P,newText:"",annotationId:k}}l.del=f;function a(P){var k=P;return z.is(k)&&(Z.is(k.annotationId)||ue.is(k.annotationId))}l.is=a})(ze=t.AnnotatedTextEdit||(t.AnnotatedTextEdit={}));var dt;(function(l){function h(f,a){return{textDocument:f,edits:a}}l.create=h;function y(f){var a=f;return C.defined(a)&&Ae.is(a.textDocument)&&Array.isArray(a.edits)}l.is=y})(dt=t.TextDocumentEdit||(t.TextDocumentEdit={}));var ft;(function(l){function h(f,a,P){var k={kind:"create",uri:f};return a!==void 0&&(a.overwrite!==void 0||a.ignoreIfExists!==void 0)&&(k.options=a),P!==void 0&&(k.annotationId=P),k}l.create=h;function y(f){var a=f;return a&&a.kind==="create"&&C.string(a.uri)&&(a.options===void 0||(a.options.overwrite===void 0||C.boolean(a.options.overwrite))&&(a.options.ignoreIfExists===void 0||C.boolean(a.options.ignoreIfExists)))&&(a.annotationId===void 0||ue.is(a.annotationId))}l.is=y})(ft=t.CreateFile||(t.CreateFile={}));var j;(function(l){function h(f,a,P,k){var J={kind:"rename",oldUri:f,newUri:a};return P!==void 0&&(P.overwrite!==void 0||P.ignoreIfExists!==void 0)&&(J.options=P),k!==void 0&&(J.annotationId=k),J}l.create=h;function y(f){var a=f;return a&&a.kind==="rename"&&C.string(a.oldUri)&&C.string(a.newUri)&&(a.options===void 0||(a.options.overwrite===void 0||C.boolean(a.options.overwrite))&&(a.options.ignoreIfExists===void 0||C.boolean(a.options.ignoreIfExists)))&&(a.annotationId===void 0||ue.is(a.annotationId))}l.is=y})(j=t.RenameFile||(t.RenameFile={}));var x;(function(l){function h(f,a,P){var k={kind:"delete",uri:f};return a!==void 0&&(a.recursive!==void 0||a.ignoreIfNotExists!==void 0)&&(k.options=a),P!==void 0&&(k.annotationId=P),k}l.create=h;function y(f){var a=f;return a&&a.kind==="delete"&&C.string(a.uri)&&(a.options===void 0||(a.options.recursive===void 0||C.boolean(a.options.recursive))&&(a.options.ignoreIfNotExists===void 0||C.boolean(a.options.ignoreIfNotExists)))&&(a.annotationId===void 0||ue.is(a.annotationId))}l.is=y})(x=t.DeleteFile||(t.DeleteFile={}));var H;(function(l){function h(y){var f=y;return f&&(f.changes!==void 0||f.documentChanges!==void 0)&&(f.documentChanges===void 0||f.documentChanges.every(function(a){return C.string(a.kind)?ft.is(a)||j.is(a)||x.is(a):dt.is(a)}))}l.is=h})(H=t.WorkspaceEdit||(t.WorkspaceEdit={}));var I=function(){function l(h,y){this.edits=h,this.changeAnnotations=y}return l.prototype.insert=function(h,y,f){var a,P;if(f===void 0?a=z.insert(h,y):ue.is(f)?(P=f,a=ze.insert(h,y,f)):(this.assertChangeAnnotations(this.changeAnnotations),P=this.changeAnnotations.manage(f),a=ze.insert(h,y,P)),this.edits.push(a),P!==void 0)return P},l.prototype.replace=function(h,y,f){var a,P;if(f===void 0?a=z.replace(h,y):ue.is(f)?(P=f,a=ze.replace(h,y,f)):(this.assertChangeAnnotations(this.changeAnnotations),P=this.changeAnnotations.manage(f),a=ze.replace(h,y,P)),this.edits.push(a),P!==void 0)return P},l.prototype.delete=function(h,y){var f,a;if(y===void 0?f=z.del(h):ue.is(y)?(a=y,f=ze.del(h,y)):(this.assertChangeAnnotations(this.changeAnnotations),a=this.changeAnnotations.manage(y),f=ze.del(h,a)),this.edits.push(f),a!==void 0)return a},l.prototype.add=function(h){this.edits.push(h)},l.prototype.all=function(){return this.edits},l.prototype.clear=function(){this.edits.splice(0,this.edits.length)},l.prototype.assertChangeAnnotations=function(h){if(h===void 0)throw new Error("Text edit change is not configured to manage change annotations.")},l}(),ie=function(){function l(h){this._annotations=h===void 0?Object.create(null):h,this._counter=0,this._size=0}return l.prototype.all=function(){return this._annotations},Object.defineProperty(l.prototype,"size",{get:function(){return this._size},enumerable:!1,configurable:!0}),l.prototype.manage=function(h,y){var f;if(ue.is(h)?f=h:(f=this.nextId(),y=h),this._annotations[f]!==void 0)throw new Error("Id ".concat(f," is already in use."));if(y===void 0)throw new Error("No annotation provided for id ".concat(f));return this._annotations[f]=y,this._size++,f},l.prototype.nextId=function(){return this._counter++,this._counter.toString()},l}(),X=function(){function l(h){var y=this;this._textEditChanges=Object.create(null),h!==void 0?(this._workspaceEdit=h,h.documentChanges?(this._changeAnnotations=new ie(h.changeAnnotations),h.changeAnnotations=this._changeAnnotations.all(),h.documentChanges.forEach(function(f){if(dt.is(f)){var a=new I(f.edits,y._changeAnnotations);y._textEditChanges[f.textDocument.uri]=a}})):h.changes&&Object.keys(h.changes).forEach(function(f){var a=new I(h.changes[f]);y._textEditChanges[f]=a})):this._workspaceEdit={}}return Object.defineProperty(l.prototype,"edit",{get:function(){return this.initDocumentChanges(),this._changeAnnotations!==void 0&&(this._changeAnnotations.size===0?this._workspaceEdit.changeAnnotations=void 0:this._workspaceEdit.changeAnnotations=this._changeAnnotations.all()),this._workspaceEdit},enumerable:!1,configurable:!0}),l.prototype.getTextEditChange=function(h){if(Ae.is(h)){if(this.initDocumentChanges(),this._workspaceEdit.documentChanges===void 0)throw new Error("Workspace edit is not configured for document changes.");var y={uri:h.uri,version:h.version},f=this._textEditChanges[y.uri];if(!f){var a=[],P={textDocument:y,edits:a};this._workspaceEdit.documentChanges.push(P),f=new I(a,this._changeAnnotations),this._textEditChanges[y.uri]=f}return f}else{if(this.initChanges(),this._workspaceEdit.changes===void 0)throw new Error("Workspace edit is not configured for normal text edit changes.");var f=this._textEditChanges[h];if(!f){var a=[];this._workspaceEdit.changes[h]=a,f=new I(a),this._textEditChanges[h]=f}return f}},l.prototype.initDocumentChanges=function(){this._workspaceEdit.documentChanges===void 0&&this._workspaceEdit.changes===void 0&&(this._changeAnnotations=new ie,this._workspaceEdit.documentChanges=[],this._workspaceEdit.changeAnnotations=this._changeAnnotations.all())},l.prototype.initChanges=function(){this._workspaceEdit.documentChanges===void 0&&this._workspaceEdit.changes===void 0&&(this._workspaceEdit.changes=Object.create(null))},l.prototype.createFile=function(h,y,f){if(this.initDocumentChanges(),this._workspaceEdit.documentChanges===void 0)throw new Error("Workspace edit is not configured for document changes.");var a;Z.is(y)||ue.is(y)?a=y:f=y;var P,k;if(a===void 0?P=ft.create(h,f):(k=ue.is(a)?a:this._changeAnnotations.manage(a),P=ft.create(h,f,k)),this._workspaceEdit.documentChanges.push(P),k!==void 0)return k},l.prototype.renameFile=function(h,y,f,a){if(this.initDocumentChanges(),this._workspaceEdit.documentChanges===void 0)throw new Error("Workspace edit is not configured for document changes.");var P;Z.is(f)||ue.is(f)?P=f:a=f;var k,J;if(P===void 0?k=j.create(h,y,a):(J=ue.is(P)?P:this._changeAnnotations.manage(P),k=j.create(h,y,a,J)),this._workspaceEdit.documentChanges.push(k),J!==void 0)return J},l.prototype.deleteFile=function(h,y,f){if(this.initDocumentChanges(),this._workspaceEdit.documentChanges===void 0)throw new Error("Workspace edit is not configured for document changes.");var a;Z.is(y)||ue.is(y)?a=y:f=y;var P,k;if(a===void 0?P=x.create(h,f):(k=ue.is(a)?a:this._changeAnnotations.manage(a),P=x.create(h,f,k)),this._workspaceEdit.documentChanges.push(P),k!==void 0)return k},l}();t.WorkspaceChange=X;var K;(function(l){function h(f){return{uri:f}}l.create=h;function y(f){var a=f;return C.defined(a)&&C.string(a.uri)}l.is=y})(K=t.TextDocumentIdentifier||(t.TextDocumentIdentifier={}));var Ve;(function(l){function h(f,a){return{uri:f,version:a}}l.create=h;function y(f){var a=f;return C.defined(a)&&C.string(a.uri)&&C.integer(a.version)}l.is=y})(Ve=t.VersionedTextDocumentIdentifier||(t.VersionedTextDocumentIdentifier={}));var Ae;(function(l){function h(f,a){return{uri:f,version:a}}l.create=h;function y(f){var a=f;return C.defined(a)&&C.string(a.uri)&&(a.version===null||C.integer(a.version))}l.is=y})(Ae=t.OptionalVersionedTextDocumentIdentifier||(t.OptionalVersionedTextDocumentIdentifier={}));var ce;(function(l){function h(f,a,P,k){return{uri:f,languageId:a,version:P,text:k}}l.create=h;function y(f){var a=f;return C.defined(a)&&C.string(a.uri)&&C.string(a.languageId)&&C.integer(a.version)&&C.string(a.text)}l.is=y})(ce=t.TextDocumentItem||(t.TextDocumentItem={}));var St;(function(l){l.PlainText="plaintext",l.Markdown="markdown";function h(y){var f=y;return f===l.PlainText||f===l.Markdown}l.is=h})(St=t.MarkupKind||(t.MarkupKind={}));var An;(function(l){function h(y){var f=y;return C.objectLiteral(y)&&St.is(f.kind)&&C.string(f.value)}l.is=h})(An=t.MarkupContent||(t.MarkupContent={}));var G;(function(l){l.Text=1,l.Method=2,l.Function=3,l.Constructor=4,l.Field=5,l.Variable=6,l.Class=7,l.Interface=8,l.Module=9,l.Property=10,l.Unit=11,l.Value=12,l.Enum=13,l.Keyword=14,l.Snippet=15,l.Color=16,l.File=17,l.Reference=18,l.Folder=19,l.EnumMember=20,l.Constant=21,l.Struct=22,l.Event=23,l.Operator=24,l.TypeParameter=25})(G=t.CompletionItemKind||(t.CompletionItemKind={}));var Gr;(function(l){l.PlainText=1,l.Snippet=2})(Gr=t.InsertTextFormat||(t.InsertTextFormat={}));var Jr;(function(l){l.Deprecated=1})(Jr=t.CompletionItemTag||(t.CompletionItemTag={}));var Yo;(function(l){function h(f,a,P){return{newText:f,insert:a,replace:P}}l.create=h;function y(f){var a=f;return a&&C.string(a.newText)&&u.is(a.insert)&&u.is(a.replace)}l.is=y})(Yo=t.InsertReplaceEdit||(t.InsertReplaceEdit={}));var Vo;(function(l){l.asIs=1,l.adjustIndentation=2})(Vo=t.InsertTextMode||(t.InsertTextMode={}));var Ko;(function(l){function h(y){var f=y;return f&&(C.string(f.detail)||f.detail===void 0)&&(C.string(f.description)||f.description===void 0)}l.is=h})(Ko=t.CompletionItemLabelDetails||(t.CompletionItemLabelDetails={}));var Go;(function(l){function h(y){return{label:y}}l.create=h})(Go=t.CompletionItem||(t.CompletionItem={}));var Jo;(function(l){function h(y,f){return{items:y||[],isIncomplete:!!f}}l.create=h})(Jo=t.CompletionList||(t.CompletionList={}));var dr;(function(l){function h(f){return f.replace(/[\\`*_{}[\]()#+\-.!]/g,"\\$&")}l.fromPlainText=h;function y(f){var a=f;return C.string(a)||C.objectLiteral(a)&&C.string(a.language)&&C.string(a.value)}l.is=y})(dr=t.MarkedString||(t.MarkedString={}));var Tt;(function(l){function h(y){var f=y;return!!f&&C.objectLiteral(f)&&(An.is(f.contents)||dr.is(f.contents)||C.typedArray(f.contents,dr.is))&&(y.range===void 0||u.is(y.range))}l.is=h})(Tt=t.Hover||(t.Hover={}));var Qo;(function(l){function h(y,f){return f?{label:y,documentation:f}:{label:y}}l.create=h})(Qo=t.ParameterInformation||(t.ParameterInformation={}));var Xo;(function(l){function h(y,f){for(var a=[],P=2;P<arguments.length;P++)a[P-2]=arguments[P];var k={label:y};return C.defined(f)&&(k.documentation=f),C.defined(a)?k.parameters=a:k.parameters=[],k}l.create=h})(Xo=t.SignatureInformation||(t.SignatureInformation={}));var qn;(function(l){l.Text=1,l.Read=2,l.Write=3})(qn=t.DocumentHighlightKind||(t.DocumentHighlightKind={}));var Zo;(function(l){function h(y,f){var a={range:y};return C.number(f)&&(a.kind=f),a}l.create=h})(Zo=t.DocumentHighlight||(t.DocumentHighlight={}));var fr;(function(l){l.File=1,l.Module=2,l.Namespace=3,l.Package=4,l.Class=5,l.Method=6,l.Property=7,l.Field=8,l.Constructor=9,l.Enum=10,l.Interface=11,l.Function=12,l.Variable=13,l.Constant=14,l.String=15,l.Number=16,l.Boolean=17,l.Array=18,l.Object=19,l.Key=20,l.Null=21,l.EnumMember=22,l.Struct=23,l.Event=24,l.Operator=25,l.TypeParameter=26})(fr=t.SymbolKind||(t.SymbolKind={}));var es;(function(l){l.Deprecated=1})(es=t.SymbolTag||(t.SymbolTag={}));var Kt;(function(l){function h(y,f,a,P,k){var J={name:y,kind:f,location:{uri:P,range:a}};return k&&(J.containerName=k),J}l.create=h})(Kt=t.SymbolInformation||(t.SymbolInformation={}));var pn;(function(l){function h(y,f,a,P){return P!==void 0?{name:y,kind:f,location:{uri:a,range:P}}:{name:y,kind:f,location:{uri:a}}}l.create=h})(pn=t.WorkspaceSymbol||(t.WorkspaceSymbol={}));var ts;(function(l){function h(f,a,P,k,J,_e){var fe={name:f,detail:a,kind:P,range:k,selectionRange:J};return _e!==void 0&&(fe.children=_e),fe}l.create=h;function y(f){var a=f;return a&&C.string(a.name)&&C.number(a.kind)&&u.is(a.range)&&u.is(a.selectionRange)&&(a.detail===void 0||C.string(a.detail))&&(a.deprecated===void 0||C.boolean(a.deprecated))&&(a.children===void 0||Array.isArray(a.children))&&(a.tags===void 0||Array.isArray(a.tags))}l.is=y})(ts=t.DocumentSymbol||(t.DocumentSymbol={}));var ns;(function(l){l.Empty="",l.QuickFix="quickfix",l.Refactor="refactor",l.RefactorExtract="refactor.extract",l.RefactorInline="refactor.inline",l.RefactorRewrite="refactor.rewrite",l.Source="source",l.SourceOrganizeImports="source.organizeImports",l.SourceFixAll="source.fixAll"})(ns=t.CodeActionKind||(t.CodeActionKind={}));var Lt;(function(l){l.Invoked=1,l.Automatic=2})(Lt=t.CodeActionTriggerKind||(t.CodeActionTriggerKind={}));var Qr;(function(l){function h(f,a,P){var k={diagnostics:f};return a!=null&&(k.only=a),P!=null&&(k.triggerKind=P),k}l.create=h;function y(f){var a=f;return C.defined(a)&&C.typedArray(a.diagnostics,v.is)&&(a.only===void 0||C.typedArray(a.only,C.string))&&(a.triggerKind===void 0||a.triggerKind===Lt.Invoked||a.triggerKind===Lt.Automatic)}l.is=y})(Qr=t.CodeActionContext||(t.CodeActionContext={}));var Xr;(function(l){function h(f,a,P){var k={title:f},J=!0;return typeof a=="string"?(J=!1,k.kind=a):N.is(a)?k.command=a:k.edit=a,J&&P!==void 0&&(k.kind=P),k}l.create=h;function y(f){var a=f;return a&&C.string(a.title)&&(a.diagnostics===void 0||C.typedArray(a.diagnostics,v.is))&&(a.kind===void 0||C.string(a.kind))&&(a.edit!==void 0||a.command!==void 0)&&(a.command===void 0||N.is(a.command))&&(a.isPreferred===void 0||C.boolean(a.isPreferred))&&(a.edit===void 0||H.is(a.edit))}l.is=y})(Xr=t.CodeAction||(t.CodeAction={}));var pr;(function(l){function h(f,a){var P={range:f};return C.defined(a)&&(P.data=a),P}l.create=h;function y(f){var a=f;return C.defined(a)&&u.is(a.range)&&(C.undefined(a.command)||N.is(a.command))}l.is=y})(pr=t.CodeLens||(t.CodeLens={}));var Zr;(function(l){function h(f,a){return{tabSize:f,insertSpaces:a}}l.create=h;function y(f){var a=f;return C.defined(a)&&C.uinteger(a.tabSize)&&C.boolean(a.insertSpaces)}l.is=y})(Zr=t.FormattingOptions||(t.FormattingOptions={}));var Gt;(function(l){function h(f,a,P){return{range:f,target:a,data:P}}l.create=h;function y(f){var a=f;return C.defined(a)&&u.is(a.range)&&(C.undefined(a.target)||C.string(a.target))}l.is=y})(Gt=t.DocumentLink||(t.DocumentLink={}));var m;(function(l){function h(f,a){return{range:f,parent:a}}l.create=h;function y(f){var a=f;return C.objectLiteral(a)&&u.is(a.range)&&(a.parent===void 0||l.is(a.parent))}l.is=y})(m=t.SelectionRange||(t.SelectionRange={}));var w;(function(l){l.namespace="namespace",l.type="type",l.class="class",l.enum="enum",l.interface="interface",l.struct="struct",l.typeParameter="typeParameter",l.parameter="parameter",l.variable="variable",l.property="property",l.enumMember="enumMember",l.event="event",l.function="function",l.method="method",l.macro="macro",l.keyword="keyword",l.modifier="modifier",l.comment="comment",l.string="string",l.number="number",l.regexp="regexp",l.operator="operator",l.decorator="decorator"})(w=t.SemanticTokenTypes||(t.SemanticTokenTypes={}));var E;(function(l){l.declaration="declaration",l.definition="definition",l.readonly="readonly",l.static="static",l.deprecated="deprecated",l.abstract="abstract",l.async="async",l.modification="modification",l.documentation="documentation",l.defaultLibrary="defaultLibrary"})(E=t.SemanticTokenModifiers||(t.SemanticTokenModifiers={}));var F;(function(l){function h(y){var f=y;return C.objectLiteral(f)&&(f.resultId===void 0||typeof f.resultId=="string")&&Array.isArray(f.data)&&(f.data.length===0||typeof f.data[0]=="number")}l.is=h})(F=t.SemanticTokens||(t.SemanticTokens={}));var le;(function(l){function h(f,a){return{range:f,text:a}}l.create=h;function y(f){var a=f;return a!=null&&u.is(a.range)&&C.string(a.text)}l.is=y})(le=t.InlineValueText||(t.InlineValueText={}));var se;(function(l){function h(f,a,P){return{range:f,variableName:a,caseSensitiveLookup:P}}l.create=h;function y(f){var a=f;return a!=null&&u.is(a.range)&&C.boolean(a.caseSensitiveLookup)&&(C.string(a.variableName)||a.variableName===void 0)}l.is=y})(se=t.InlineValueVariableLookup||(t.InlineValueVariableLookup={}));var me;(function(l){function h(f,a){return{range:f,expression:a}}l.create=h;function y(f){var a=f;return a!=null&&u.is(a.range)&&(C.string(a.expression)||a.expression===void 0)}l.is=y})(me=t.InlineValueEvaluatableExpression||(t.InlineValueEvaluatableExpression={}));var he;(function(l){function h(f,a){return{frameId:f,stoppedLocation:a}}l.create=h;function y(f){var a=f;return C.defined(a)&&u.is(f.stoppedLocation)}l.is=y})(he=t.InlineValueContext||(t.InlineValueContext={}));var ee;(function(l){l.Type=1,l.Parameter=2;function h(y){return y===1||y===2}l.is=h})(ee=t.InlayHintKind||(t.InlayHintKind={}));var de;(function(l){function h(f){return{value:f}}l.create=h;function y(f){var a=f;return C.objectLiteral(a)&&(a.tooltip===void 0||C.string(a.tooltip)||An.is(a.tooltip))&&(a.location===void 0||c.is(a.location))&&(a.command===void 0||N.is(a.command))}l.is=y})(de=t.InlayHintLabelPart||(t.InlayHintLabelPart={}));var oe;(function(l){function h(f,a,P){var k={position:f,label:a};return P!==void 0&&(k.kind=P),k}l.create=h;function y(f){var a=f;return C.objectLiteral(a)&&s.is(a.position)&&(C.string(a.label)||C.typedArray(a.label,de.is))&&(a.kind===void 0||ee.is(a.kind))&&a.textEdits===void 0||C.typedArray(a.textEdits,z.is)&&(a.tooltip===void 0||C.string(a.tooltip)||An.is(a.tooltip))&&(a.paddingLeft===void 0||C.boolean(a.paddingLeft))&&(a.paddingRight===void 0||C.boolean(a.paddingRight))}l.is=y})(oe=t.InlayHint||(t.InlayHint={}));var De;(function(l){function h(y){var f=y;return C.objectLiteral(f)&&r.is(f.uri)&&C.string(f.name)}l.is=h})(De=t.WorkspaceFolder||(t.WorkspaceFolder={})),t.EOL=[`
64
64
  `,`\r
65
- `,"\r"];var Le;(function(l){function h(P,k,J,_e){return new it(P,k,J,_e)}l.create=h;function y(P){var k=P;return!!(C.defined(k)&&C.string(k.uri)&&(C.undefined(k.languageId)||C.string(k.languageId))&&C.uinteger(k.lineCount)&&C.func(k.getText)&&C.func(k.positionAt)&&C.func(k.offsetAt))}l.is=y;function f(P,k){for(var J=P.getText(),_e=a(k,function(qn,ei){var Zc=qn.range.start.line-ei.range.start.line;return Zc===0?qn.range.start.character-ei.range.start.character:Zc}),fe=J.length,pt=_e.length-1;pt>=0;pt--){var gt=_e[pt],It=P.offsetAt(gt.range.start),te=P.offsetAt(gt.range.end);if(te<=fe)J=J.substring(0,It)+gt.newText+J.substring(te,J.length);else throw new Error("Overlapping edit");fe=It}return J}l.applyEdits=f;function a(P,k){if(P.length<=1)return P;var J=P.length/2|0,_e=P.slice(0,J),fe=P.slice(J);a(_e,k),a(fe,k);for(var pt=0,gt=0,It=0;pt<_e.length&&gt<fe.length;){var te=k(_e[pt],fe[gt]);te<=0?P[It++]=_e[pt++]:P[It++]=fe[gt++]}for(;pt<_e.length;)P[It++]=_e[pt++];for(;gt<fe.length;)P[It++]=fe[gt++];return P}})(Le=t.TextDocument||(t.TextDocument={}));var it=function(){function l(h,y,f,a){this._uri=h,this._languageId=y,this._version=f,this._content=a,this._lineOffsets=void 0}return Object.defineProperty(l.prototype,"uri",{get:function(){return this._uri},enumerable:!1,configurable:!0}),Object.defineProperty(l.prototype,"languageId",{get:function(){return this._languageId},enumerable:!1,configurable:!0}),Object.defineProperty(l.prototype,"version",{get:function(){return this._version},enumerable:!1,configurable:!0}),l.prototype.getText=function(h){if(h){var y=this.offsetAt(h.start),f=this.offsetAt(h.end);return this._content.substring(y,f)}return this._content},l.prototype.update=function(h,y){this._content=h.text,this._version=y,this._lineOffsets=void 0},l.prototype.getLineOffsets=function(){if(this._lineOffsets===void 0){for(var h=[],y=this._content,f=!0,a=0;a<y.length;a++){f&&(h.push(a),f=!1);var P=y.charAt(a);f=P==="\r"||P===`
65
+ `,"\r"];var Le;(function(l){function h(P,k,J,_e){return new it(P,k,J,_e)}l.create=h;function y(P){var k=P;return!!(C.defined(k)&&C.string(k.uri)&&(C.undefined(k.languageId)||C.string(k.languageId))&&C.uinteger(k.lineCount)&&C.func(k.getText)&&C.func(k.positionAt)&&C.func(k.offsetAt))}l.is=y;function f(P,k){for(var J=P.getText(),_e=a(k,function(Nn,ei){var Zc=Nn.range.start.line-ei.range.start.line;return Zc===0?Nn.range.start.character-ei.range.start.character:Zc}),fe=J.length,pt=_e.length-1;pt>=0;pt--){var gt=_e[pt],It=P.offsetAt(gt.range.start),te=P.offsetAt(gt.range.end);if(te<=fe)J=J.substring(0,It)+gt.newText+J.substring(te,J.length);else throw new Error("Overlapping edit");fe=It}return J}l.applyEdits=f;function a(P,k){if(P.length<=1)return P;var J=P.length/2|0,_e=P.slice(0,J),fe=P.slice(J);a(_e,k),a(fe,k);for(var pt=0,gt=0,It=0;pt<_e.length&&gt<fe.length;){var te=k(_e[pt],fe[gt]);te<=0?P[It++]=_e[pt++]:P[It++]=fe[gt++]}for(;pt<_e.length;)P[It++]=_e[pt++];for(;gt<fe.length;)P[It++]=fe[gt++];return P}})(Le=t.TextDocument||(t.TextDocument={}));var it=function(){function l(h,y,f,a){this._uri=h,this._languageId=y,this._version=f,this._content=a,this._lineOffsets=void 0}return Object.defineProperty(l.prototype,"uri",{get:function(){return this._uri},enumerable:!1,configurable:!0}),Object.defineProperty(l.prototype,"languageId",{get:function(){return this._languageId},enumerable:!1,configurable:!0}),Object.defineProperty(l.prototype,"version",{get:function(){return this._version},enumerable:!1,configurable:!0}),l.prototype.getText=function(h){if(h){var y=this.offsetAt(h.start),f=this.offsetAt(h.end);return this._content.substring(y,f)}return this._content},l.prototype.update=function(h,y){this._content=h.text,this._version=y,this._lineOffsets=void 0},l.prototype.getLineOffsets=function(){if(this._lineOffsets===void 0){for(var h=[],y=this._content,f=!0,a=0;a<y.length;a++){f&&(h.push(a),f=!1);var P=y.charAt(a);f=P==="\r"||P===`
66
66
  `,P==="\r"&&a+1<y.length&&y.charAt(a+1)===`
67
- `&&a++}f&&y.length>0&&h.push(y.length),this._lineOffsets=h}return this._lineOffsets},l.prototype.positionAt=function(h){h=Math.max(Math.min(h,this._content.length),0);var y=this.getLineOffsets(),f=0,a=y.length;if(a===0)return s.create(0,h);for(;f<a;){var P=Math.floor((f+a)/2);y[P]>h?a=P:f=P+1}var k=f-1;return s.create(k,h-y[k])},l.prototype.offsetAt=function(h){var y=this.getLineOffsets();if(h.line>=y.length)return this._content.length;if(h.line<0)return 0;var f=y[h.line],a=h.line+1<y.length?y[h.line+1]:this._content.length;return Math.max(Math.min(f+h.character,a),f)},Object.defineProperty(l.prototype,"lineCount",{get:function(){return this.getLineOffsets().length},enumerable:!1,configurable:!0}),l}(),C;(function(l){var h=Object.prototype.toString;function y(te){return typeof te<"u"}l.defined=y;function f(te){return typeof te>"u"}l.undefined=f;function a(te){return te===!0||te===!1}l.boolean=a;function P(te){return h.call(te)==="[object String]"}l.string=P;function k(te){return h.call(te)==="[object Number]"}l.number=k;function J(te,qn,ei){return h.call(te)==="[object Number]"&&qn<=te&&te<=ei}l.numberRange=J;function _e(te){return h.call(te)==="[object Number]"&&-2147483648<=te&&te<=2147483647}l.integer=_e;function fe(te){return h.call(te)==="[object Number]"&&0<=te&&te<=2147483647}l.uinteger=fe;function pt(te){return h.call(te)==="[object Function]"}l.func=pt;function gt(te){return te!==null&&typeof te=="object"}l.objectLiteral=gt;function It(te,qn){return Array.isArray(te)&&te.every(qn)}l.typedArray=It})(C||(C={}))})});var Ce=A(Ge=>{"use strict";Object.defineProperty(Ge,"__esModule",{value:!0});Ge.ProtocolNotificationType=Ge.ProtocolNotificationType0=Ge.ProtocolRequestType=Ge.ProtocolRequestType0=Ge.RegistrationType=Ge.MessageDirection=void 0;var er=Sn(),qb;(function(e){e.clientToServer="clientToServer",e.serverToClient="serverToClient",e.both="both"})(qb=Ge.MessageDirection||(Ge.MessageDirection={}));var pc=class{constructor(t){this.method=t}};Ge.RegistrationType=pc;var gc=class extends er.RequestType0{constructor(t){super(t)}};Ge.ProtocolRequestType0=gc;var mc=class extends er.RequestType{constructor(t){super(t,er.ParameterStructures.byName)}};Ge.ProtocolRequestType=mc;var hc=class extends er.NotificationType0{constructor(t){super(t)}};Ge.ProtocolNotificationType0=hc;var yc=class extends er.NotificationType{constructor(t){super(t,er.ParameterStructures.byName)}};Ge.ProtocolNotificationType=yc});var eo=A(xe=>{"use strict";Object.defineProperty(xe,"__esModule",{value:!0});xe.objectLiteral=xe.typedArray=xe.stringArray=xe.array=xe.func=xe.error=xe.number=xe.string=xe.boolean=void 0;function Nb(e){return e===!0||e===!1}xe.boolean=Nb;function wd(e){return typeof e=="string"||e instanceof String}xe.string=wd;function Ob(e){return typeof e=="number"||e instanceof Number}xe.number=Ob;function Eb(e){return e instanceof Error}xe.error=Eb;function Mb(e){return typeof e=="function"}xe.func=Mb;function kd(e){return Array.isArray(e)}xe.array=kd;function jb(e){return kd(e)&&e.every(t=>wd(t))}xe.stringArray=jb;function Lb(e,t){return Array.isArray(e)&&e.every(t)}xe.typedArray=Lb;function Ib(e){return e!==null&&typeof e=="object"}xe.objectLiteral=Ib});var qd=A(kr=>{"use strict";Object.defineProperty(kr,"__esModule",{value:!0});kr.ImplementationRequest=void 0;var Ad=Ce(),Fb;(function(e){e.method="textDocument/implementation",e.messageDirection=Ad.MessageDirection.clientToServer,e.type=new Ad.ProtocolRequestType(e.method)})(Fb=kr.ImplementationRequest||(kr.ImplementationRequest={}))});var Od=A(Ar=>{"use strict";Object.defineProperty(Ar,"__esModule",{value:!0});Ar.TypeDefinitionRequest=void 0;var Nd=Ce(),Wb;(function(e){e.method="textDocument/typeDefinition",e.messageDirection=Nd.MessageDirection.clientToServer,e.type=new Nd.ProtocolRequestType(e.method)})(Wb=Ar.TypeDefinitionRequest||(Ar.TypeDefinitionRequest={}))});var Ed=A(nn=>{"use strict";Object.defineProperty(nn,"__esModule",{value:!0});nn.DidChangeWorkspaceFoldersNotification=nn.WorkspaceFoldersRequest=void 0;var to=Ce(),Hb;(function(e){e.method="workspace/workspaceFolders",e.messageDirection=to.MessageDirection.serverToClient,e.type=new to.ProtocolRequestType0(e.method)})(Hb=nn.WorkspaceFoldersRequest||(nn.WorkspaceFoldersRequest={}));var Ub;(function(e){e.method="workspace/didChangeWorkspaceFolders",e.messageDirection=to.MessageDirection.clientToServer,e.type=new to.ProtocolNotificationType(e.method)})(Ub=nn.DidChangeWorkspaceFoldersNotification||(nn.DidChangeWorkspaceFoldersNotification={}))});var jd=A(qr=>{"use strict";Object.defineProperty(qr,"__esModule",{value:!0});qr.ConfigurationRequest=void 0;var Md=Ce(),Bb;(function(e){e.method="workspace/configuration",e.messageDirection=Md.MessageDirection.serverToClient,e.type=new Md.ProtocolRequestType(e.method)})(Bb=qr.ConfigurationRequest||(qr.ConfigurationRequest={}))});var Ld=A(rn=>{"use strict";Object.defineProperty(rn,"__esModule",{value:!0});rn.ColorPresentationRequest=rn.DocumentColorRequest=void 0;var no=Ce(),zb;(function(e){e.method="textDocument/documentColor",e.messageDirection=no.MessageDirection.clientToServer,e.type=new no.ProtocolRequestType(e.method)})(zb=rn.DocumentColorRequest||(rn.DocumentColorRequest={}));var $b;(function(e){e.method="textDocument/colorPresentation",e.messageDirection=no.MessageDirection.clientToServer,e.type=new no.ProtocolRequestType(e.method)})($b=rn.ColorPresentationRequest||(rn.ColorPresentationRequest={}))});var Fd=A(Nr=>{"use strict";Object.defineProperty(Nr,"__esModule",{value:!0});Nr.FoldingRangeRequest=void 0;var Id=Ce(),Yb;(function(e){e.method="textDocument/foldingRange",e.messageDirection=Id.MessageDirection.clientToServer,e.type=new Id.ProtocolRequestType(e.method)})(Yb=Nr.FoldingRangeRequest||(Nr.FoldingRangeRequest={}))});var Hd=A(Or=>{"use strict";Object.defineProperty(Or,"__esModule",{value:!0});Or.DeclarationRequest=void 0;var Wd=Ce(),Vb;(function(e){e.method="textDocument/declaration",e.messageDirection=Wd.MessageDirection.clientToServer,e.type=new Wd.ProtocolRequestType(e.method)})(Vb=Or.DeclarationRequest||(Or.DeclarationRequest={}))});var Bd=A(Er=>{"use strict";Object.defineProperty(Er,"__esModule",{value:!0});Er.SelectionRangeRequest=void 0;var Ud=Ce(),Kb;(function(e){e.method="textDocument/selectionRange",e.messageDirection=Ud.MessageDirection.clientToServer,e.type=new Ud.ProtocolRequestType(e.method)})(Kb=Er.SelectionRangeRequest||(Er.SelectionRangeRequest={}))});var zd=A(bt=>{"use strict";Object.defineProperty(bt,"__esModule",{value:!0});bt.WorkDoneProgressCancelNotification=bt.WorkDoneProgressCreateRequest=bt.WorkDoneProgress=void 0;var Gb=Sn(),ro=Ce(),Jb;(function(e){e.type=new Gb.ProgressType;function t(n){return n===e.type}e.is=t})(Jb=bt.WorkDoneProgress||(bt.WorkDoneProgress={}));var Qb;(function(e){e.method="window/workDoneProgress/create",e.messageDirection=ro.MessageDirection.serverToClient,e.type=new ro.ProtocolRequestType(e.method)})(Qb=bt.WorkDoneProgressCreateRequest||(bt.WorkDoneProgressCreateRequest={}));var Xb;(function(e){e.method="window/workDoneProgress/cancel",e.messageDirection=ro.MessageDirection.clientToServer,e.type=new ro.ProtocolNotificationType(e.method)})(Xb=bt.WorkDoneProgressCancelNotification||(bt.WorkDoneProgressCancelNotification={}))});var $d=A(vt=>{"use strict";Object.defineProperty(vt,"__esModule",{value:!0});vt.CallHierarchyOutgoingCallsRequest=vt.CallHierarchyIncomingCallsRequest=vt.CallHierarchyPrepareRequest=void 0;var tr=Ce(),Zb;(function(e){e.method="textDocument/prepareCallHierarchy",e.messageDirection=tr.MessageDirection.clientToServer,e.type=new tr.ProtocolRequestType(e.method)})(Zb=vt.CallHierarchyPrepareRequest||(vt.CallHierarchyPrepareRequest={}));var ev;(function(e){e.method="callHierarchy/incomingCalls",e.messageDirection=tr.MessageDirection.clientToServer,e.type=new tr.ProtocolRequestType(e.method)})(ev=vt.CallHierarchyIncomingCallsRequest||(vt.CallHierarchyIncomingCallsRequest={}));var tv;(function(e){e.method="callHierarchy/outgoingCalls",e.messageDirection=tr.MessageDirection.clientToServer,e.type=new tr.ProtocolRequestType(e.method)})(tv=vt.CallHierarchyOutgoingCallsRequest||(vt.CallHierarchyOutgoingCallsRequest={}))});var Yd=A(we=>{"use strict";Object.defineProperty(we,"__esModule",{value:!0});we.SemanticTokensRefreshRequest=we.SemanticTokensRangeRequest=we.SemanticTokensDeltaRequest=we.SemanticTokensRequest=we.SemanticTokensRegistrationType=we.TokenFormat=void 0;var Yt=Ce(),nv;(function(e){e.Relative="relative"})(nv=we.TokenFormat||(we.TokenFormat={}));var io;(function(e){e.method="textDocument/semanticTokens",e.type=new Yt.RegistrationType(e.method)})(io=we.SemanticTokensRegistrationType||(we.SemanticTokensRegistrationType={}));var rv;(function(e){e.method="textDocument/semanticTokens/full",e.messageDirection=Yt.MessageDirection.clientToServer,e.type=new Yt.ProtocolRequestType(e.method),e.registrationMethod=io.method})(rv=we.SemanticTokensRequest||(we.SemanticTokensRequest={}));var iv;(function(e){e.method="textDocument/semanticTokens/full/delta",e.messageDirection=Yt.MessageDirection.clientToServer,e.type=new Yt.ProtocolRequestType(e.method),e.registrationMethod=io.method})(iv=we.SemanticTokensDeltaRequest||(we.SemanticTokensDeltaRequest={}));var ov;(function(e){e.method="textDocument/semanticTokens/range",e.messageDirection=Yt.MessageDirection.clientToServer,e.type=new Yt.ProtocolRequestType(e.method),e.registrationMethod=io.method})(ov=we.SemanticTokensRangeRequest||(we.SemanticTokensRangeRequest={}));var sv;(function(e){e.method="workspace/semanticTokens/refresh",e.messageDirection=Yt.MessageDirection.serverToClient,e.type=new Yt.ProtocolRequestType0(e.method)})(sv=we.SemanticTokensRefreshRequest||(we.SemanticTokensRefreshRequest={}))});var Kd=A(Mr=>{"use strict";Object.defineProperty(Mr,"__esModule",{value:!0});Mr.ShowDocumentRequest=void 0;var Vd=Ce(),av;(function(e){e.method="window/showDocument",e.messageDirection=Vd.MessageDirection.serverToClient,e.type=new Vd.ProtocolRequestType(e.method)})(av=Mr.ShowDocumentRequest||(Mr.ShowDocumentRequest={}))});var Jd=A(jr=>{"use strict";Object.defineProperty(jr,"__esModule",{value:!0});jr.LinkedEditingRangeRequest=void 0;var Gd=Ce(),cv;(function(e){e.method="textDocument/linkedEditingRange",e.messageDirection=Gd.MessageDirection.clientToServer,e.type=new Gd.ProtocolRequestType(e.method)})(cv=jr.LinkedEditingRangeRequest||(jr.LinkedEditingRangeRequest={}))});var Qd=A(Pe=>{"use strict";Object.defineProperty(Pe,"__esModule",{value:!0});Pe.WillDeleteFilesRequest=Pe.DidDeleteFilesNotification=Pe.DidRenameFilesNotification=Pe.WillRenameFilesRequest=Pe.DidCreateFilesNotification=Pe.WillCreateFilesRequest=Pe.FileOperationPatternKind=void 0;var at=Ce(),uv;(function(e){e.file="file",e.folder="folder"})(uv=Pe.FileOperationPatternKind||(Pe.FileOperationPatternKind={}));var lv;(function(e){e.method="workspace/willCreateFiles",e.messageDirection=at.MessageDirection.clientToServer,e.type=new at.ProtocolRequestType(e.method)})(lv=Pe.WillCreateFilesRequest||(Pe.WillCreateFilesRequest={}));var dv;(function(e){e.method="workspace/didCreateFiles",e.messageDirection=at.MessageDirection.clientToServer,e.type=new at.ProtocolNotificationType(e.method)})(dv=Pe.DidCreateFilesNotification||(Pe.DidCreateFilesNotification={}));var fv;(function(e){e.method="workspace/willRenameFiles",e.messageDirection=at.MessageDirection.clientToServer,e.type=new at.ProtocolRequestType(e.method)})(fv=Pe.WillRenameFilesRequest||(Pe.WillRenameFilesRequest={}));var pv;(function(e){e.method="workspace/didRenameFiles",e.messageDirection=at.MessageDirection.clientToServer,e.type=new at.ProtocolNotificationType(e.method)})(pv=Pe.DidRenameFilesNotification||(Pe.DidRenameFilesNotification={}));var gv;(function(e){e.method="workspace/didDeleteFiles",e.messageDirection=at.MessageDirection.clientToServer,e.type=new at.ProtocolNotificationType(e.method)})(gv=Pe.DidDeleteFilesNotification||(Pe.DidDeleteFilesNotification={}));var mv;(function(e){e.method="workspace/willDeleteFiles",e.messageDirection=at.MessageDirection.clientToServer,e.type=new at.ProtocolRequestType(e.method)})(mv=Pe.WillDeleteFilesRequest||(Pe.WillDeleteFilesRequest={}))});var Zd=A(Ct=>{"use strict";Object.defineProperty(Ct,"__esModule",{value:!0});Ct.MonikerRequest=Ct.MonikerKind=Ct.UniquenessLevel=void 0;var Xd=Ce(),hv;(function(e){e.document="document",e.project="project",e.group="group",e.scheme="scheme",e.global="global"})(hv=Ct.UniquenessLevel||(Ct.UniquenessLevel={}));var yv;(function(e){e.$import="import",e.$export="export",e.local="local"})(yv=Ct.MonikerKind||(Ct.MonikerKind={}));var bv;(function(e){e.method="textDocument/moniker",e.messageDirection=Xd.MessageDirection.clientToServer,e.type=new Xd.ProtocolRequestType(e.method)})(bv=Ct.MonikerRequest||(Ct.MonikerRequest={}))});var ef=A(Pt=>{"use strict";Object.defineProperty(Pt,"__esModule",{value:!0});Pt.TypeHierarchySubtypesRequest=Pt.TypeHierarchySupertypesRequest=Pt.TypeHierarchyPrepareRequest=void 0;var nr=Ce(),vv;(function(e){e.method="textDocument/prepareTypeHierarchy",e.messageDirection=nr.MessageDirection.clientToServer,e.type=new nr.ProtocolRequestType(e.method)})(vv=Pt.TypeHierarchyPrepareRequest||(Pt.TypeHierarchyPrepareRequest={}));var Cv;(function(e){e.method="typeHierarchy/supertypes",e.messageDirection=nr.MessageDirection.clientToServer,e.type=new nr.ProtocolRequestType(e.method)})(Cv=Pt.TypeHierarchySupertypesRequest||(Pt.TypeHierarchySupertypesRequest={}));var Pv;(function(e){e.method="typeHierarchy/subtypes",e.messageDirection=nr.MessageDirection.clientToServer,e.type=new nr.ProtocolRequestType(e.method)})(Pv=Pt.TypeHierarchySubtypesRequest||(Pt.TypeHierarchySubtypesRequest={}))});var tf=A(on=>{"use strict";Object.defineProperty(on,"__esModule",{value:!0});on.InlineValueRefreshRequest=on.InlineValueRequest=void 0;var oo=Ce(),_v;(function(e){e.method="textDocument/inlineValue",e.messageDirection=oo.MessageDirection.clientToServer,e.type=new oo.ProtocolRequestType(e.method)})(_v=on.InlineValueRequest||(on.InlineValueRequest={}));var Rv;(function(e){e.method="workspace/inlineValue/refresh",e.messageDirection=oo.MessageDirection.serverToClient,e.type=new oo.ProtocolRequestType0(e.method)})(Rv=on.InlineValueRefreshRequest||(on.InlineValueRefreshRequest={}))});var nf=A(_t=>{"use strict";Object.defineProperty(_t,"__esModule",{value:!0});_t.InlayHintRefreshRequest=_t.InlayHintResolveRequest=_t.InlayHintRequest=void 0;var rr=Ce(),Dv;(function(e){e.method="textDocument/inlayHint",e.messageDirection=rr.MessageDirection.clientToServer,e.type=new rr.ProtocolRequestType(e.method)})(Dv=_t.InlayHintRequest||(_t.InlayHintRequest={}));var Sv;(function(e){e.method="inlayHint/resolve",e.messageDirection=rr.MessageDirection.clientToServer,e.type=new rr.ProtocolRequestType(e.method)})(Sv=_t.InlayHintResolveRequest||(_t.InlayHintResolveRequest={}));var Tv;(function(e){e.method="workspace/inlayHint/refresh",e.messageDirection=rr.MessageDirection.serverToClient,e.type=new rr.ProtocolRequestType0(e.method)})(Tv=_t.InlayHintRefreshRequest||(_t.InlayHintRefreshRequest={}))});var of=A(He=>{"use strict";Object.defineProperty(He,"__esModule",{value:!0});He.DiagnosticRefreshRequest=He.WorkspaceDiagnosticRequest=He.DocumentDiagnosticRequest=He.DocumentDiagnosticReportKind=He.DiagnosticServerCancellationData=void 0;var rf=Sn(),xv=eo(),ir=Ce(),wv;(function(e){function t(n){let r=n;return r&&xv.boolean(r.retriggerRequest)}e.is=t})(wv=He.DiagnosticServerCancellationData||(He.DiagnosticServerCancellationData={}));var kv;(function(e){e.Full="full",e.Unchanged="unchanged"})(kv=He.DocumentDiagnosticReportKind||(He.DocumentDiagnosticReportKind={}));var Av;(function(e){e.method="textDocument/diagnostic",e.messageDirection=ir.MessageDirection.clientToServer,e.type=new ir.ProtocolRequestType(e.method),e.partialResult=new rf.ProgressType})(Av=He.DocumentDiagnosticRequest||(He.DocumentDiagnosticRequest={}));var qv;(function(e){e.method="workspace/diagnostic",e.messageDirection=ir.MessageDirection.clientToServer,e.type=new ir.ProtocolRequestType(e.method),e.partialResult=new rf.ProgressType})(qv=He.WorkspaceDiagnosticRequest||(He.WorkspaceDiagnosticRequest={}));var Nv;(function(e){e.method="workspace/diagnostic/refresh",e.messageDirection=ir.MessageDirection.serverToClient,e.type=new ir.ProtocolRequestType0(e.method)})(Nv=He.DiagnosticRefreshRequest||(He.DiagnosticRefreshRequest={}))});var cf=A(re=>{"use strict";Object.defineProperty(re,"__esModule",{value:!0});re.DidCloseNotebookDocumentNotification=re.DidSaveNotebookDocumentNotification=re.DidChangeNotebookDocumentNotification=re.NotebookCellArrayChange=re.DidOpenNotebookDocumentNotification=re.NotebookDocumentSyncRegistrationType=re.NotebookDocument=re.NotebookCell=re.ExecutionSummary=re.NotebookCellKind=void 0;var Lr=Zi(),Rt=eo(),qt=Ce(),sf;(function(e){e.Markup=1,e.Code=2;function t(n){return n===1||n===2}e.is=t})(sf=re.NotebookCellKind||(re.NotebookCellKind={}));var af;(function(e){function t(i,o){let s={executionOrder:i};return(o===!0||o===!1)&&(s.success=o),s}e.create=t;function n(i){let o=i;return Rt.objectLiteral(o)&&Lr.uinteger.is(o.executionOrder)&&(o.success===void 0||Rt.boolean(o.success))}e.is=n;function r(i,o){return i===o?!0:i==null||o===null||o===void 0?!1:i.executionOrder===o.executionOrder&&i.success===o.success}e.equals=r})(af=re.ExecutionSummary||(re.ExecutionSummary={}));var bc;(function(e){function t(o,s){return{kind:o,document:s}}e.create=t;function n(o){let s=o;return Rt.objectLiteral(s)&&sf.is(s.kind)&&Lr.DocumentUri.is(s.document)&&(s.metadata===void 0||Rt.objectLiteral(s.metadata))}e.is=n;function r(o,s){let u=new Set;return o.document!==s.document&&u.add("document"),o.kind!==s.kind&&u.add("kind"),o.executionSummary!==s.executionSummary&&u.add("executionSummary"),(o.metadata!==void 0||s.metadata!==void 0)&&!i(o.metadata,s.metadata)&&u.add("metadata"),(o.executionSummary!==void 0||s.executionSummary!==void 0)&&!af.equals(o.executionSummary,s.executionSummary)&&u.add("executionSummary"),u}e.diff=r;function i(o,s){if(o===s)return!0;if(o==null||s===null||s===void 0||typeof o!=typeof s||typeof o!="object")return!1;let u=Array.isArray(o),c=Array.isArray(s);if(u!==c)return!1;if(u&&c){if(o.length!==s.length)return!1;for(let p=0;p<o.length;p++)if(!i(o[p],s[p]))return!1}if(Rt.objectLiteral(o)&&Rt.objectLiteral(s)){let p=Object.keys(o),g=Object.keys(s);if(p.length!==g.length||(p.sort(),g.sort(),!i(p,g)))return!1;for(let b=0;b<p.length;b++){let R=p[b];if(!i(o[R],s[R]))return!1}}return!0}})(bc=re.NotebookCell||(re.NotebookCell={}));var Ov;(function(e){function t(r,i,o,s){return{uri:r,notebookType:i,version:o,cells:s}}e.create=t;function n(r){let i=r;return Rt.objectLiteral(i)&&Rt.string(i.uri)&&Lr.integer.is(i.version)&&Rt.typedArray(i.cells,bc.is)}e.is=n})(Ov=re.NotebookDocument||(re.NotebookDocument={}));var Ir;(function(e){e.method="notebookDocument/sync",e.messageDirection=qt.MessageDirection.clientToServer,e.type=new qt.RegistrationType(e.method)})(Ir=re.NotebookDocumentSyncRegistrationType||(re.NotebookDocumentSyncRegistrationType={}));var Ev;(function(e){e.method="notebookDocument/didOpen",e.messageDirection=qt.MessageDirection.clientToServer,e.type=new qt.ProtocolNotificationType(e.method),e.registrationMethod=Ir.method})(Ev=re.DidOpenNotebookDocumentNotification||(re.DidOpenNotebookDocumentNotification={}));var Mv;(function(e){function t(r){let i=r;return Rt.objectLiteral(i)&&Lr.uinteger.is(i.start)&&Lr.uinteger.is(i.deleteCount)&&(i.cells===void 0||Rt.typedArray(i.cells,bc.is))}e.is=t;function n(r,i,o){let s={start:r,deleteCount:i};return o!==void 0&&(s.cells=o),s}e.create=n})(Mv=re.NotebookCellArrayChange||(re.NotebookCellArrayChange={}));var jv;(function(e){e.method="notebookDocument/didChange",e.messageDirection=qt.MessageDirection.clientToServer,e.type=new qt.ProtocolNotificationType(e.method),e.registrationMethod=Ir.method})(jv=re.DidChangeNotebookDocumentNotification||(re.DidChangeNotebookDocumentNotification={}));var Lv;(function(e){e.method="notebookDocument/didSave",e.messageDirection=qt.MessageDirection.clientToServer,e.type=new qt.ProtocolNotificationType(e.method),e.registrationMethod=Ir.method})(Lv=re.DidSaveNotebookDocumentNotification||(re.DidSaveNotebookDocumentNotification={}));var Iv;(function(e){e.method="notebookDocument/didClose",e.messageDirection=qt.MessageDirection.clientToServer,e.type=new qt.ProtocolNotificationType(e.method),e.registrationMethod=Ir.method})(Iv=re.DidCloseNotebookDocumentNotification||(re.DidCloseNotebookDocumentNotification={}))});var yf=A(d=>{"use strict";Object.defineProperty(d,"__esModule",{value:!0});d.WorkspaceSymbolRequest=d.CodeActionResolveRequest=d.CodeActionRequest=d.DocumentSymbolRequest=d.DocumentHighlightRequest=d.ReferencesRequest=d.DefinitionRequest=d.SignatureHelpRequest=d.SignatureHelpTriggerKind=d.HoverRequest=d.CompletionResolveRequest=d.CompletionRequest=d.CompletionTriggerKind=d.PublishDiagnosticsNotification=d.WatchKind=d.RelativePattern=d.FileChangeType=d.DidChangeWatchedFilesNotification=d.WillSaveTextDocumentWaitUntilRequest=d.WillSaveTextDocumentNotification=d.TextDocumentSaveReason=d.DidSaveTextDocumentNotification=d.DidCloseTextDocumentNotification=d.DidChangeTextDocumentNotification=d.TextDocumentContentChangeEvent=d.DidOpenTextDocumentNotification=d.TextDocumentSyncKind=d.TelemetryEventNotification=d.LogMessageNotification=d.ShowMessageRequest=d.ShowMessageNotification=d.MessageType=d.DidChangeConfigurationNotification=d.ExitNotification=d.ShutdownRequest=d.InitializedNotification=d.InitializeErrorCodes=d.InitializeRequest=d.WorkDoneProgressOptions=d.TextDocumentRegistrationOptions=d.StaticRegistrationOptions=d.PositionEncodingKind=d.FailureHandlingKind=d.ResourceOperationKind=d.UnregistrationRequest=d.RegistrationRequest=d.DocumentSelector=d.NotebookCellTextDocumentFilter=d.NotebookDocumentFilter=d.TextDocumentFilter=void 0;d.TypeHierarchySubtypesRequest=d.TypeHierarchyPrepareRequest=d.MonikerRequest=d.MonikerKind=d.UniquenessLevel=d.WillDeleteFilesRequest=d.DidDeleteFilesNotification=d.WillRenameFilesRequest=d.DidRenameFilesNotification=d.WillCreateFilesRequest=d.DidCreateFilesNotification=d.FileOperationPatternKind=d.LinkedEditingRangeRequest=d.ShowDocumentRequest=d.SemanticTokensRegistrationType=d.SemanticTokensRefreshRequest=d.SemanticTokensRangeRequest=d.SemanticTokensDeltaRequest=d.SemanticTokensRequest=d.TokenFormat=d.CallHierarchyPrepareRequest=d.CallHierarchyOutgoingCallsRequest=d.CallHierarchyIncomingCallsRequest=d.WorkDoneProgressCancelNotification=d.WorkDoneProgressCreateRequest=d.WorkDoneProgress=d.SelectionRangeRequest=d.DeclarationRequest=d.FoldingRangeRequest=d.ColorPresentationRequest=d.DocumentColorRequest=d.ConfigurationRequest=d.DidChangeWorkspaceFoldersNotification=d.WorkspaceFoldersRequest=d.TypeDefinitionRequest=d.ImplementationRequest=d.ApplyWorkspaceEditRequest=d.ExecuteCommandRequest=d.PrepareRenameRequest=d.RenameRequest=d.PrepareSupportDefaultBehavior=d.DocumentOnTypeFormattingRequest=d.DocumentRangeFormattingRequest=d.DocumentFormattingRequest=d.DocumentLinkResolveRequest=d.DocumentLinkRequest=d.CodeLensRefreshRequest=d.CodeLensResolveRequest=d.CodeLensRequest=d.WorkspaceSymbolResolveRequest=void 0;d.DidCloseNotebookDocumentNotification=d.DidSaveNotebookDocumentNotification=d.DidChangeNotebookDocumentNotification=d.NotebookCellArrayChange=d.DidOpenNotebookDocumentNotification=d.NotebookDocumentSyncRegistrationType=d.NotebookDocument=d.NotebookCell=d.ExecutionSummary=d.NotebookCellKind=d.DiagnosticRefreshRequest=d.WorkspaceDiagnosticRequest=d.DocumentDiagnosticRequest=d.DocumentDiagnosticReportKind=d.DiagnosticServerCancellationData=d.InlayHintRefreshRequest=d.InlayHintResolveRequest=d.InlayHintRequest=d.InlineValueRefreshRequest=d.InlineValueRequest=d.TypeHierarchySupertypesRequest=void 0;var O=Ce(),uf=Zi(),Ue=eo(),Fv=qd();Object.defineProperty(d,"ImplementationRequest",{enumerable:!0,get:function(){return Fv.ImplementationRequest}});var Wv=Od();Object.defineProperty(d,"TypeDefinitionRequest",{enumerable:!0,get:function(){return Wv.TypeDefinitionRequest}});var lf=Ed();Object.defineProperty(d,"WorkspaceFoldersRequest",{enumerable:!0,get:function(){return lf.WorkspaceFoldersRequest}});Object.defineProperty(d,"DidChangeWorkspaceFoldersNotification",{enumerable:!0,get:function(){return lf.DidChangeWorkspaceFoldersNotification}});var Hv=jd();Object.defineProperty(d,"ConfigurationRequest",{enumerable:!0,get:function(){return Hv.ConfigurationRequest}});var df=Ld();Object.defineProperty(d,"DocumentColorRequest",{enumerable:!0,get:function(){return df.DocumentColorRequest}});Object.defineProperty(d,"ColorPresentationRequest",{enumerable:!0,get:function(){return df.ColorPresentationRequest}});var Uv=Fd();Object.defineProperty(d,"FoldingRangeRequest",{enumerable:!0,get:function(){return Uv.FoldingRangeRequest}});var Bv=Hd();Object.defineProperty(d,"DeclarationRequest",{enumerable:!0,get:function(){return Bv.DeclarationRequest}});var zv=Bd();Object.defineProperty(d,"SelectionRangeRequest",{enumerable:!0,get:function(){return zv.SelectionRangeRequest}});var vc=zd();Object.defineProperty(d,"WorkDoneProgress",{enumerable:!0,get:function(){return vc.WorkDoneProgress}});Object.defineProperty(d,"WorkDoneProgressCreateRequest",{enumerable:!0,get:function(){return vc.WorkDoneProgressCreateRequest}});Object.defineProperty(d,"WorkDoneProgressCancelNotification",{enumerable:!0,get:function(){return vc.WorkDoneProgressCancelNotification}});var Cc=$d();Object.defineProperty(d,"CallHierarchyIncomingCallsRequest",{enumerable:!0,get:function(){return Cc.CallHierarchyIncomingCallsRequest}});Object.defineProperty(d,"CallHierarchyOutgoingCallsRequest",{enumerable:!0,get:function(){return Cc.CallHierarchyOutgoingCallsRequest}});Object.defineProperty(d,"CallHierarchyPrepareRequest",{enumerable:!0,get:function(){return Cc.CallHierarchyPrepareRequest}});var or=Yd();Object.defineProperty(d,"TokenFormat",{enumerable:!0,get:function(){return or.TokenFormat}});Object.defineProperty(d,"SemanticTokensRequest",{enumerable:!0,get:function(){return or.SemanticTokensRequest}});Object.defineProperty(d,"SemanticTokensDeltaRequest",{enumerable:!0,get:function(){return or.SemanticTokensDeltaRequest}});Object.defineProperty(d,"SemanticTokensRangeRequest",{enumerable:!0,get:function(){return or.SemanticTokensRangeRequest}});Object.defineProperty(d,"SemanticTokensRefreshRequest",{enumerable:!0,get:function(){return or.SemanticTokensRefreshRequest}});Object.defineProperty(d,"SemanticTokensRegistrationType",{enumerable:!0,get:function(){return or.SemanticTokensRegistrationType}});var $v=Kd();Object.defineProperty(d,"ShowDocumentRequest",{enumerable:!0,get:function(){return $v.ShowDocumentRequest}});var Yv=Jd();Object.defineProperty(d,"LinkedEditingRangeRequest",{enumerable:!0,get:function(){return Yv.LinkedEditingRangeRequest}});var Tn=Qd();Object.defineProperty(d,"FileOperationPatternKind",{enumerable:!0,get:function(){return Tn.FileOperationPatternKind}});Object.defineProperty(d,"DidCreateFilesNotification",{enumerable:!0,get:function(){return Tn.DidCreateFilesNotification}});Object.defineProperty(d,"WillCreateFilesRequest",{enumerable:!0,get:function(){return Tn.WillCreateFilesRequest}});Object.defineProperty(d,"DidRenameFilesNotification",{enumerable:!0,get:function(){return Tn.DidRenameFilesNotification}});Object.defineProperty(d,"WillRenameFilesRequest",{enumerable:!0,get:function(){return Tn.WillRenameFilesRequest}});Object.defineProperty(d,"DidDeleteFilesNotification",{enumerable:!0,get:function(){return Tn.DidDeleteFilesNotification}});Object.defineProperty(d,"WillDeleteFilesRequest",{enumerable:!0,get:function(){return Tn.WillDeleteFilesRequest}});var Pc=Zd();Object.defineProperty(d,"UniquenessLevel",{enumerable:!0,get:function(){return Pc.UniquenessLevel}});Object.defineProperty(d,"MonikerKind",{enumerable:!0,get:function(){return Pc.MonikerKind}});Object.defineProperty(d,"MonikerRequest",{enumerable:!0,get:function(){return Pc.MonikerRequest}});var _c=ef();Object.defineProperty(d,"TypeHierarchyPrepareRequest",{enumerable:!0,get:function(){return _c.TypeHierarchyPrepareRequest}});Object.defineProperty(d,"TypeHierarchySubtypesRequest",{enumerable:!0,get:function(){return _c.TypeHierarchySubtypesRequest}});Object.defineProperty(d,"TypeHierarchySupertypesRequest",{enumerable:!0,get:function(){return _c.TypeHierarchySupertypesRequest}});var ff=tf();Object.defineProperty(d,"InlineValueRequest",{enumerable:!0,get:function(){return ff.InlineValueRequest}});Object.defineProperty(d,"InlineValueRefreshRequest",{enumerable:!0,get:function(){return ff.InlineValueRefreshRequest}});var Rc=nf();Object.defineProperty(d,"InlayHintRequest",{enumerable:!0,get:function(){return Rc.InlayHintRequest}});Object.defineProperty(d,"InlayHintResolveRequest",{enumerable:!0,get:function(){return Rc.InlayHintResolveRequest}});Object.defineProperty(d,"InlayHintRefreshRequest",{enumerable:!0,get:function(){return Rc.InlayHintRefreshRequest}});var Fr=of();Object.defineProperty(d,"DiagnosticServerCancellationData",{enumerable:!0,get:function(){return Fr.DiagnosticServerCancellationData}});Object.defineProperty(d,"DocumentDiagnosticReportKind",{enumerable:!0,get:function(){return Fr.DocumentDiagnosticReportKind}});Object.defineProperty(d,"DocumentDiagnosticRequest",{enumerable:!0,get:function(){return Fr.DocumentDiagnosticRequest}});Object.defineProperty(d,"WorkspaceDiagnosticRequest",{enumerable:!0,get:function(){return Fr.WorkspaceDiagnosticRequest}});Object.defineProperty(d,"DiagnosticRefreshRequest",{enumerable:!0,get:function(){return Fr.DiagnosticRefreshRequest}});var Nt=cf();Object.defineProperty(d,"NotebookCellKind",{enumerable:!0,get:function(){return Nt.NotebookCellKind}});Object.defineProperty(d,"ExecutionSummary",{enumerable:!0,get:function(){return Nt.ExecutionSummary}});Object.defineProperty(d,"NotebookCell",{enumerable:!0,get:function(){return Nt.NotebookCell}});Object.defineProperty(d,"NotebookDocument",{enumerable:!0,get:function(){return Nt.NotebookDocument}});Object.defineProperty(d,"NotebookDocumentSyncRegistrationType",{enumerable:!0,get:function(){return Nt.NotebookDocumentSyncRegistrationType}});Object.defineProperty(d,"DidOpenNotebookDocumentNotification",{enumerable:!0,get:function(){return Nt.DidOpenNotebookDocumentNotification}});Object.defineProperty(d,"NotebookCellArrayChange",{enumerable:!0,get:function(){return Nt.NotebookCellArrayChange}});Object.defineProperty(d,"DidChangeNotebookDocumentNotification",{enumerable:!0,get:function(){return Nt.DidChangeNotebookDocumentNotification}});Object.defineProperty(d,"DidSaveNotebookDocumentNotification",{enumerable:!0,get:function(){return Nt.DidSaveNotebookDocumentNotification}});Object.defineProperty(d,"DidCloseNotebookDocumentNotification",{enumerable:!0,get:function(){return Nt.DidCloseNotebookDocumentNotification}});var pf;(function(e){function t(n){let r=n;return Ue.string(r.language)||Ue.string(r.scheme)||Ue.string(r.pattern)}e.is=t})(pf=d.TextDocumentFilter||(d.TextDocumentFilter={}));var gf;(function(e){function t(n){let r=n;return Ue.objectLiteral(r)&&(Ue.string(r.notebookType)||Ue.string(r.scheme)||Ue.string(r.pattern))}e.is=t})(gf=d.NotebookDocumentFilter||(d.NotebookDocumentFilter={}));var mf;(function(e){function t(n){let r=n;return Ue.objectLiteral(r)&&(Ue.string(r.notebook)||gf.is(r.notebook))&&(r.language===void 0||Ue.string(r.language))}e.is=t})(mf=d.NotebookCellTextDocumentFilter||(d.NotebookCellTextDocumentFilter={}));var hf;(function(e){function t(n){if(!Array.isArray(n))return!1;for(let r of n)if(!Ue.string(r)&&!pf.is(r)&&!mf.is(r))return!1;return!0}e.is=t})(hf=d.DocumentSelector||(d.DocumentSelector={}));var Vv;(function(e){e.method="client/registerCapability",e.messageDirection=O.MessageDirection.serverToClient,e.type=new O.ProtocolRequestType(e.method)})(Vv=d.RegistrationRequest||(d.RegistrationRequest={}));var Kv;(function(e){e.method="client/unregisterCapability",e.messageDirection=O.MessageDirection.serverToClient,e.type=new O.ProtocolRequestType(e.method)})(Kv=d.UnregistrationRequest||(d.UnregistrationRequest={}));var Gv;(function(e){e.Create="create",e.Rename="rename",e.Delete="delete"})(Gv=d.ResourceOperationKind||(d.ResourceOperationKind={}));var Jv;(function(e){e.Abort="abort",e.Transactional="transactional",e.TextOnlyTransactional="textOnlyTransactional",e.Undo="undo"})(Jv=d.FailureHandlingKind||(d.FailureHandlingKind={}));var Qv;(function(e){e.UTF8="utf-8",e.UTF16="utf-16",e.UTF32="utf-32"})(Qv=d.PositionEncodingKind||(d.PositionEncodingKind={}));var Xv;(function(e){function t(n){let r=n;return r&&Ue.string(r.id)&&r.id.length>0}e.hasId=t})(Xv=d.StaticRegistrationOptions||(d.StaticRegistrationOptions={}));var Zv;(function(e){function t(n){let r=n;return r&&(r.documentSelector===null||hf.is(r.documentSelector))}e.is=t})(Zv=d.TextDocumentRegistrationOptions||(d.TextDocumentRegistrationOptions={}));var eC;(function(e){function t(r){let i=r;return Ue.objectLiteral(i)&&(i.workDoneProgress===void 0||Ue.boolean(i.workDoneProgress))}e.is=t;function n(r){let i=r;return i&&Ue.boolean(i.workDoneProgress)}e.hasWorkDoneProgress=n})(eC=d.WorkDoneProgressOptions||(d.WorkDoneProgressOptions={}));var tC;(function(e){e.method="initialize",e.messageDirection=O.MessageDirection.clientToServer,e.type=new O.ProtocolRequestType(e.method)})(tC=d.InitializeRequest||(d.InitializeRequest={}));var nC;(function(e){e.unknownProtocolVersion=1})(nC=d.InitializeErrorCodes||(d.InitializeErrorCodes={}));var rC;(function(e){e.method="initialized",e.messageDirection=O.MessageDirection.clientToServer,e.type=new O.ProtocolNotificationType(e.method)})(rC=d.InitializedNotification||(d.InitializedNotification={}));var iC;(function(e){e.method="shutdown",e.messageDirection=O.MessageDirection.clientToServer,e.type=new O.ProtocolRequestType0(e.method)})(iC=d.ShutdownRequest||(d.ShutdownRequest={}));var oC;(function(e){e.method="exit",e.messageDirection=O.MessageDirection.clientToServer,e.type=new O.ProtocolNotificationType0(e.method)})(oC=d.ExitNotification||(d.ExitNotification={}));var sC;(function(e){e.method="workspace/didChangeConfiguration",e.messageDirection=O.MessageDirection.clientToServer,e.type=new O.ProtocolNotificationType(e.method)})(sC=d.DidChangeConfigurationNotification||(d.DidChangeConfigurationNotification={}));var aC;(function(e){e.Error=1,e.Warning=2,e.Info=3,e.Log=4})(aC=d.MessageType||(d.MessageType={}));var cC;(function(e){e.method="window/showMessage",e.messageDirection=O.MessageDirection.serverToClient,e.type=new O.ProtocolNotificationType(e.method)})(cC=d.ShowMessageNotification||(d.ShowMessageNotification={}));var uC;(function(e){e.method="window/showMessageRequest",e.messageDirection=O.MessageDirection.serverToClient,e.type=new O.ProtocolRequestType(e.method)})(uC=d.ShowMessageRequest||(d.ShowMessageRequest={}));var lC;(function(e){e.method="window/logMessage",e.messageDirection=O.MessageDirection.serverToClient,e.type=new O.ProtocolNotificationType(e.method)})(lC=d.LogMessageNotification||(d.LogMessageNotification={}));var dC;(function(e){e.method="telemetry/event",e.messageDirection=O.MessageDirection.serverToClient,e.type=new O.ProtocolNotificationType(e.method)})(dC=d.TelemetryEventNotification||(d.TelemetryEventNotification={}));var fC;(function(e){e.None=0,e.Full=1,e.Incremental=2})(fC=d.TextDocumentSyncKind||(d.TextDocumentSyncKind={}));var pC;(function(e){e.method="textDocument/didOpen",e.messageDirection=O.MessageDirection.clientToServer,e.type=new O.ProtocolNotificationType(e.method)})(pC=d.DidOpenTextDocumentNotification||(d.DidOpenTextDocumentNotification={}));var gC;(function(e){function t(r){let i=r;return i!=null&&typeof i.text=="string"&&i.range!==void 0&&(i.rangeLength===void 0||typeof i.rangeLength=="number")}e.isIncremental=t;function n(r){let i=r;return i!=null&&typeof i.text=="string"&&i.range===void 0&&i.rangeLength===void 0}e.isFull=n})(gC=d.TextDocumentContentChangeEvent||(d.TextDocumentContentChangeEvent={}));var mC;(function(e){e.method="textDocument/didChange",e.messageDirection=O.MessageDirection.clientToServer,e.type=new O.ProtocolNotificationType(e.method)})(mC=d.DidChangeTextDocumentNotification||(d.DidChangeTextDocumentNotification={}));var hC;(function(e){e.method="textDocument/didClose",e.messageDirection=O.MessageDirection.clientToServer,e.type=new O.ProtocolNotificationType(e.method)})(hC=d.DidCloseTextDocumentNotification||(d.DidCloseTextDocumentNotification={}));var yC;(function(e){e.method="textDocument/didSave",e.messageDirection=O.MessageDirection.clientToServer,e.type=new O.ProtocolNotificationType(e.method)})(yC=d.DidSaveTextDocumentNotification||(d.DidSaveTextDocumentNotification={}));var bC;(function(e){e.Manual=1,e.AfterDelay=2,e.FocusOut=3})(bC=d.TextDocumentSaveReason||(d.TextDocumentSaveReason={}));var vC;(function(e){e.method="textDocument/willSave",e.messageDirection=O.MessageDirection.clientToServer,e.type=new O.ProtocolNotificationType(e.method)})(vC=d.WillSaveTextDocumentNotification||(d.WillSaveTextDocumentNotification={}));var CC;(function(e){e.method="textDocument/willSaveWaitUntil",e.messageDirection=O.MessageDirection.clientToServer,e.type=new O.ProtocolRequestType(e.method)})(CC=d.WillSaveTextDocumentWaitUntilRequest||(d.WillSaveTextDocumentWaitUntilRequest={}));var PC;(function(e){e.method="workspace/didChangeWatchedFiles",e.messageDirection=O.MessageDirection.clientToServer,e.type=new O.ProtocolNotificationType(e.method)})(PC=d.DidChangeWatchedFilesNotification||(d.DidChangeWatchedFilesNotification={}));var _C;(function(e){e.Created=1,e.Changed=2,e.Deleted=3})(_C=d.FileChangeType||(d.FileChangeType={}));var RC;(function(e){function t(n){let r=n;return Ue.objectLiteral(r)&&(uf.URI.is(r.baseUri)||uf.WorkspaceFolder.is(r.baseUri))&&Ue.string(r.pattern)}e.is=t})(RC=d.RelativePattern||(d.RelativePattern={}));var DC;(function(e){e.Create=1,e.Change=2,e.Delete=4})(DC=d.WatchKind||(d.WatchKind={}));var SC;(function(e){e.method="textDocument/publishDiagnostics",e.messageDirection=O.MessageDirection.serverToClient,e.type=new O.ProtocolNotificationType(e.method)})(SC=d.PublishDiagnosticsNotification||(d.PublishDiagnosticsNotification={}));var TC;(function(e){e.Invoked=1,e.TriggerCharacter=2,e.TriggerForIncompleteCompletions=3})(TC=d.CompletionTriggerKind||(d.CompletionTriggerKind={}));var xC;(function(e){e.method="textDocument/completion",e.messageDirection=O.MessageDirection.clientToServer,e.type=new O.ProtocolRequestType(e.method)})(xC=d.CompletionRequest||(d.CompletionRequest={}));var wC;(function(e){e.method="completionItem/resolve",e.messageDirection=O.MessageDirection.clientToServer,e.type=new O.ProtocolRequestType(e.method)})(wC=d.CompletionResolveRequest||(d.CompletionResolveRequest={}));var kC;(function(e){e.method="textDocument/hover",e.messageDirection=O.MessageDirection.clientToServer,e.type=new O.ProtocolRequestType(e.method)})(kC=d.HoverRequest||(d.HoverRequest={}));var AC;(function(e){e.Invoked=1,e.TriggerCharacter=2,e.ContentChange=3})(AC=d.SignatureHelpTriggerKind||(d.SignatureHelpTriggerKind={}));var qC;(function(e){e.method="textDocument/signatureHelp",e.messageDirection=O.MessageDirection.clientToServer,e.type=new O.ProtocolRequestType(e.method)})(qC=d.SignatureHelpRequest||(d.SignatureHelpRequest={}));var NC;(function(e){e.method="textDocument/definition",e.messageDirection=O.MessageDirection.clientToServer,e.type=new O.ProtocolRequestType(e.method)})(NC=d.DefinitionRequest||(d.DefinitionRequest={}));var OC;(function(e){e.method="textDocument/references",e.messageDirection=O.MessageDirection.clientToServer,e.type=new O.ProtocolRequestType(e.method)})(OC=d.ReferencesRequest||(d.ReferencesRequest={}));var EC;(function(e){e.method="textDocument/documentHighlight",e.messageDirection=O.MessageDirection.clientToServer,e.type=new O.ProtocolRequestType(e.method)})(EC=d.DocumentHighlightRequest||(d.DocumentHighlightRequest={}));var MC;(function(e){e.method="textDocument/documentSymbol",e.messageDirection=O.MessageDirection.clientToServer,e.type=new O.ProtocolRequestType(e.method)})(MC=d.DocumentSymbolRequest||(d.DocumentSymbolRequest={}));var jC;(function(e){e.method="textDocument/codeAction",e.messageDirection=O.MessageDirection.clientToServer,e.type=new O.ProtocolRequestType(e.method)})(jC=d.CodeActionRequest||(d.CodeActionRequest={}));var LC;(function(e){e.method="codeAction/resolve",e.messageDirection=O.MessageDirection.clientToServer,e.type=new O.ProtocolRequestType(e.method)})(LC=d.CodeActionResolveRequest||(d.CodeActionResolveRequest={}));var IC;(function(e){e.method="workspace/symbol",e.messageDirection=O.MessageDirection.clientToServer,e.type=new O.ProtocolRequestType(e.method)})(IC=d.WorkspaceSymbolRequest||(d.WorkspaceSymbolRequest={}));var FC;(function(e){e.method="workspaceSymbol/resolve",e.messageDirection=O.MessageDirection.clientToServer,e.type=new O.ProtocolRequestType(e.method)})(FC=d.WorkspaceSymbolResolveRequest||(d.WorkspaceSymbolResolveRequest={}));var WC;(function(e){e.method="textDocument/codeLens",e.messageDirection=O.MessageDirection.clientToServer,e.type=new O.ProtocolRequestType(e.method)})(WC=d.CodeLensRequest||(d.CodeLensRequest={}));var HC;(function(e){e.method="codeLens/resolve",e.messageDirection=O.MessageDirection.clientToServer,e.type=new O.ProtocolRequestType(e.method)})(HC=d.CodeLensResolveRequest||(d.CodeLensResolveRequest={}));var UC;(function(e){e.method="workspace/codeLens/refresh",e.messageDirection=O.MessageDirection.serverToClient,e.type=new O.ProtocolRequestType0(e.method)})(UC=d.CodeLensRefreshRequest||(d.CodeLensRefreshRequest={}));var BC;(function(e){e.method="textDocument/documentLink",e.messageDirection=O.MessageDirection.clientToServer,e.type=new O.ProtocolRequestType(e.method)})(BC=d.DocumentLinkRequest||(d.DocumentLinkRequest={}));var zC;(function(e){e.method="documentLink/resolve",e.messageDirection=O.MessageDirection.clientToServer,e.type=new O.ProtocolRequestType(e.method)})(zC=d.DocumentLinkResolveRequest||(d.DocumentLinkResolveRequest={}));var $C;(function(e){e.method="textDocument/formatting",e.messageDirection=O.MessageDirection.clientToServer,e.type=new O.ProtocolRequestType(e.method)})($C=d.DocumentFormattingRequest||(d.DocumentFormattingRequest={}));var YC;(function(e){e.method="textDocument/rangeFormatting",e.messageDirection=O.MessageDirection.clientToServer,e.type=new O.ProtocolRequestType(e.method)})(YC=d.DocumentRangeFormattingRequest||(d.DocumentRangeFormattingRequest={}));var VC;(function(e){e.method="textDocument/onTypeFormatting",e.messageDirection=O.MessageDirection.clientToServer,e.type=new O.ProtocolRequestType(e.method)})(VC=d.DocumentOnTypeFormattingRequest||(d.DocumentOnTypeFormattingRequest={}));var KC;(function(e){e.Identifier=1})(KC=d.PrepareSupportDefaultBehavior||(d.PrepareSupportDefaultBehavior={}));var GC;(function(e){e.method="textDocument/rename",e.messageDirection=O.MessageDirection.clientToServer,e.type=new O.ProtocolRequestType(e.method)})(GC=d.RenameRequest||(d.RenameRequest={}));var JC;(function(e){e.method="textDocument/prepareRename",e.messageDirection=O.MessageDirection.clientToServer,e.type=new O.ProtocolRequestType(e.method)})(JC=d.PrepareRenameRequest||(d.PrepareRenameRequest={}));var QC;(function(e){e.method="workspace/executeCommand",e.messageDirection=O.MessageDirection.clientToServer,e.type=new O.ProtocolRequestType(e.method)})(QC=d.ExecuteCommandRequest||(d.ExecuteCommandRequest={}));var XC;(function(e){e.method="workspace/applyEdit",e.messageDirection=O.MessageDirection.serverToClient,e.type=new O.ProtocolRequestType("workspace/applyEdit")})(XC=d.ApplyWorkspaceEditRequest||(d.ApplyWorkspaceEditRequest={}))});var vf=A(so=>{"use strict";Object.defineProperty(so,"__esModule",{value:!0});so.createProtocolConnection=void 0;var bf=Sn();function ZC(e,t,n,r){return bf.ConnectionStrategy.is(r)&&(r={connectionStrategy:r}),(0,bf.createMessageConnection)(e,t,n,r)}so.createProtocolConnection=ZC});var Cf=A(Je=>{"use strict";var eP=Je&&Je.__createBinding||(Object.create?function(e,t,n,r){r===void 0&&(r=n);var i=Object.getOwnPropertyDescriptor(t,n);(!i||("get"in i?!t.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:function(){return t[n]}}),Object.defineProperty(e,r,i)}:function(e,t,n,r){r===void 0&&(r=n),e[r]=t[n]}),ao=Je&&Je.__exportStar||function(e,t){for(var n in e)n!=="default"&&!Object.prototype.hasOwnProperty.call(t,n)&&eP(t,e,n)};Object.defineProperty(Je,"__esModule",{value:!0});Je.LSPErrorCodes=Je.createProtocolConnection=void 0;ao(Sn(),Je);ao(Zi(),Je);ao(Ce(),Je);ao(yf(),Je);var tP=vf();Object.defineProperty(Je,"createProtocolConnection",{enumerable:!0,get:function(){return tP.createProtocolConnection}});var nP;(function(e){e.lspReservedErrorRangeStart=-32899,e.RequestFailed=-32803,e.ServerCancelled=-32802,e.ContentModified=-32801,e.RequestCancelled=-32800,e.lspReservedErrorRangeEnd=-32800})(nP=Je.LSPErrorCodes||(Je.LSPErrorCodes={}))});var qe=A(Ot=>{"use strict";var rP=Ot&&Ot.__createBinding||(Object.create?function(e,t,n,r){r===void 0&&(r=n);var i=Object.getOwnPropertyDescriptor(t,n);(!i||("get"in i?!t.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:function(){return t[n]}}),Object.defineProperty(e,r,i)}:function(e,t,n,r){r===void 0&&(r=n),e[r]=t[n]}),Pf=Ot&&Ot.__exportStar||function(e,t){for(var n in e)n!=="default"&&!Object.prototype.hasOwnProperty.call(t,n)&&rP(t,e,n)};Object.defineProperty(Ot,"__esModule",{value:!0});Ot.createProtocolConnection=void 0;var iP=fc();Pf(fc(),Ot);Pf(Cf(),Ot);function oP(e,t,n,r){return(0,iP.createMessageConnection)(e,t,n,r)}Ot.createProtocolConnection=oP});var Sc=A(sn=>{"use strict";Object.defineProperty(sn,"__esModule",{value:!0});sn.SemanticTokensBuilder=sn.SemanticTokensDiff=sn.SemanticTokensFeature=void 0;var co=qe(),sP=e=>class extends e{get semanticTokens(){return{refresh:()=>this.connection.sendRequest(co.SemanticTokensRefreshRequest.type),on:t=>{let n=co.SemanticTokensRequest.type;return this.connection.onRequest(n,(r,i)=>t(r,i,this.attachWorkDoneProgress(r),this.attachPartialResultProgress(n,r)))},onDelta:t=>{let n=co.SemanticTokensDeltaRequest.type;return this.connection.onRequest(n,(r,i)=>t(r,i,this.attachWorkDoneProgress(r),this.attachPartialResultProgress(n,r)))},onRange:t=>{let n=co.SemanticTokensRangeRequest.type;return this.connection.onRequest(n,(r,i)=>t(r,i,this.attachWorkDoneProgress(r),this.attachPartialResultProgress(n,r)))}}}};sn.SemanticTokensFeature=sP;var uo=class{constructor(t,n){this.originalSequence=t,this.modifiedSequence=n}computeDiff(){let t=this.originalSequence.length,n=this.modifiedSequence.length,r=0;for(;r<n&&r<t&&this.originalSequence[r]===this.modifiedSequence[r];)r++;if(r<n&&r<t){let i=t-1,o=n-1;for(;i>=r&&o>=r&&this.originalSequence[i]===this.modifiedSequence[o];)i--,o--;(i<r||o<r)&&(i++,o++);let s=i-r+1,u=this.modifiedSequence.slice(r,o+1);return u.length===1&&u[0]===this.originalSequence[i]?[{start:r,deleteCount:s-1}]:[{start:r,deleteCount:s,data:u}]}else return r<n?[{start:r,deleteCount:0,data:this.modifiedSequence.slice(r)}]:r<t?[{start:r,deleteCount:t-r}]:[]}};sn.SemanticTokensDiff=uo;var Dc=class{constructor(){this._prevData=void 0,this.initialize()}initialize(){this._id=Date.now(),this._prevLine=0,this._prevChar=0,this._data=[],this._dataLen=0}push(t,n,r,i,o){let s=t,u=n;this._dataLen>0&&(s-=this._prevLine,s===0&&(u-=this._prevChar)),this._data[this._dataLen++]=s,this._data[this._dataLen++]=u,this._data[this._dataLen++]=r,this._data[this._dataLen++]=i,this._data[this._dataLen++]=o,this._prevLine=t,this._prevChar=n}get id(){return this._id.toString()}previousResult(t){this.id===t&&(this._prevData=this._data),this.initialize()}build(){return this._prevData=void 0,{resultId:this.id,data:this._data}}canBuildEdits(){return this._prevData!==void 0}buildEdits(){return this._prevData!==void 0?{resultId:this.id,edits:new uo(this._prevData,this._data).computeDiff()}:this.build()}};sn.SemanticTokensBuilder=Dc});var xc=A(lo=>{"use strict";Object.defineProperty(lo,"__esModule",{value:!0});lo.TextDocuments=void 0;var xn=qe(),Tc=class{constructor(t){this._configuration=t,this._syncedDocuments=new Map,this._onDidChangeContent=new xn.Emitter,this._onDidOpen=new xn.Emitter,this._onDidClose=new xn.Emitter,this._onDidSave=new xn.Emitter,this._onWillSave=new xn.Emitter}get onDidOpen(){return this._onDidOpen.event}get onDidChangeContent(){return this._onDidChangeContent.event}get onWillSave(){return this._onWillSave.event}onWillSaveWaitUntil(t){this._willSaveWaitUntil=t}get onDidSave(){return this._onDidSave.event}get onDidClose(){return this._onDidClose.event}get(t){return this._syncedDocuments.get(t)}all(){return Array.from(this._syncedDocuments.values())}keys(){return Array.from(this._syncedDocuments.keys())}listen(t){t.__textDocumentSync=xn.TextDocumentSyncKind.Incremental;let n=[];return n.push(t.onDidOpenTextDocument(r=>{let i=r.textDocument,o=this._configuration.create(i.uri,i.languageId,i.version,i.text);this._syncedDocuments.set(i.uri,o);let s=Object.freeze({document:o});this._onDidOpen.fire(s),this._onDidChangeContent.fire(s)})),n.push(t.onDidChangeTextDocument(r=>{let i=r.textDocument,o=r.contentChanges;if(o.length===0)return;let{version:s}=i;if(s==null)throw new Error(`Received document change event for ${i.uri} without valid version identifier`);let u=this._syncedDocuments.get(i.uri);u!==void 0&&(u=this._configuration.update(u,o,s),this._syncedDocuments.set(i.uri,u),this._onDidChangeContent.fire(Object.freeze({document:u})))})),n.push(t.onDidCloseTextDocument(r=>{let i=this._syncedDocuments.get(r.textDocument.uri);i!==void 0&&(this._syncedDocuments.delete(r.textDocument.uri),this._onDidClose.fire(Object.freeze({document:i})))})),n.push(t.onWillSaveTextDocument(r=>{let i=this._syncedDocuments.get(r.textDocument.uri);i!==void 0&&this._onWillSave.fire(Object.freeze({document:i,reason:r.reason}))})),n.push(t.onWillSaveTextDocumentWaitUntil((r,i)=>{let o=this._syncedDocuments.get(r.textDocument.uri);return o!==void 0&&this._willSaveWaitUntil?this._willSaveWaitUntil(Object.freeze({document:o,reason:r.reason}),i):[]})),n.push(t.onDidSaveTextDocument(r=>{let i=this._syncedDocuments.get(r.textDocument.uri);i!==void 0&&this._onDidSave.fire(Object.freeze({document:i}))})),xn.Disposable.create(()=>{n.forEach(r=>r.dispose())})}};lo.TextDocuments=Tc});var kc=A(sr=>{"use strict";Object.defineProperty(sr,"__esModule",{value:!0});sr.NotebookDocuments=sr.NotebookSyncFeature=void 0;var ct=qe(),_f=xc(),aP=e=>class extends e{get synchronization(){return{onDidOpenNotebookDocument:t=>this.connection.onNotification(ct.DidOpenNotebookDocumentNotification.type,n=>{t(n)}),onDidChangeNotebookDocument:t=>this.connection.onNotification(ct.DidChangeNotebookDocumentNotification.type,n=>{t(n)}),onDidSaveNotebookDocument:t=>this.connection.onNotification(ct.DidSaveNotebookDocumentNotification.type,n=>{t(n)}),onDidCloseNotebookDocument:t=>this.connection.onNotification(ct.DidCloseNotebookDocumentNotification.type,n=>{t(n)})}}};sr.NotebookSyncFeature=aP;var an=class{onDidOpenTextDocument(t){return this.openHandler=t,ct.Disposable.create(()=>{this.openHandler=void 0})}openTextDocument(t){this.openHandler&&this.openHandler(t)}onDidChangeTextDocument(t){return this.changeHandler=t,ct.Disposable.create(()=>{this.changeHandler=t})}changeTextDocument(t){this.changeHandler&&this.changeHandler(t)}onDidCloseTextDocument(t){return this.closeHandler=t,ct.Disposable.create(()=>{this.closeHandler=void 0})}closeTextDocument(t){this.closeHandler&&this.closeHandler(t)}onWillSaveTextDocument(){return an.NULL_DISPOSE}onWillSaveTextDocumentWaitUntil(){return an.NULL_DISPOSE}onDidSaveTextDocument(){return an.NULL_DISPOSE}};an.NULL_DISPOSE=Object.freeze({dispose:()=>{}});var wc=class{constructor(t){t instanceof _f.TextDocuments?this._cellTextDocuments=t:this._cellTextDocuments=new _f.TextDocuments(t),this.notebookDocuments=new Map,this.notebookCellMap=new Map,this._onDidOpen=new ct.Emitter,this._onDidChange=new ct.Emitter,this._onDidSave=new ct.Emitter,this._onDidClose=new ct.Emitter}get cellTextDocuments(){return this._cellTextDocuments}getCellTextDocument(t){return this._cellTextDocuments.get(t.document)}getNotebookDocument(t){return this.notebookDocuments.get(t)}getNotebookCell(t){let n=this.notebookCellMap.get(t);return n&&n[0]}findNotebookDocumentForCell(t){let n=typeof t=="string"?t:t.document,r=this.notebookCellMap.get(n);return r&&r[1]}get onDidOpen(){return this._onDidOpen.event}get onDidSave(){return this._onDidSave.event}get onDidChange(){return this._onDidChange.event}get onDidClose(){return this._onDidClose.event}listen(t){let n=new an,r=[];return r.push(this.cellTextDocuments.listen(n)),r.push(t.notebooks.synchronization.onDidOpenNotebookDocument(i=>{this.notebookDocuments.set(i.notebookDocument.uri,i.notebookDocument);for(let o of i.cellTextDocuments)n.openTextDocument({textDocument:o});this.updateCellMap(i.notebookDocument),this._onDidOpen.fire(i.notebookDocument)})),r.push(t.notebooks.synchronization.onDidChangeNotebookDocument(i=>{let o=this.notebookDocuments.get(i.notebookDocument.uri);if(o===void 0)return;o.version=i.notebookDocument.version;let s=o.metadata,u=!1,c=i.change;c.metadata!==void 0&&(u=!0,o.metadata=c.metadata);let p=[],g=[],b=[],R=[];if(c.cells!==void 0){let L=c.cells;if(L.structure!==void 0){let _=L.structure.array;if(o.cells.splice(_.start,_.deleteCount,..._.cells!==void 0?_.cells:[]),L.structure.didOpen!==void 0)for(let v of L.structure.didOpen)n.openTextDocument({textDocument:v}),p.push(v.uri);if(L.structure.didClose)for(let v of L.structure.didClose)n.closeTextDocument({textDocument:v}),g.push(v.uri)}if(L.data!==void 0){let _=new Map(L.data.map(v=>[v.document,v]));for(let v=0;v<=o.cells.length;v++){let N=_.get(o.cells[v].document);if(N!==void 0){let z=o.cells.splice(v,1,N);if(b.push({old:z[0],new:N}),_.delete(N.document),_.size===0)break}}}if(L.textContent!==void 0)for(let _ of L.textContent)n.changeTextDocument({textDocument:_.document,contentChanges:_.changes}),R.push(_.document.uri)}this.updateCellMap(o);let D={notebookDocument:o};u&&(D.metadata={old:s,new:o.metadata});let T=[];for(let L of p)T.push(this.getNotebookCell(L));let q=[];for(let L of g)q.push(this.getNotebookCell(L));let B=[];for(let L of R)B.push(this.getNotebookCell(L));(T.length>0||q.length>0||b.length>0||B.length>0)&&(D.cells={added:T,removed:q,changed:{data:b,textContent:B}}),(D.metadata!==void 0||D.cells!==void 0)&&this._onDidChange.fire(D)})),r.push(t.notebooks.synchronization.onDidSaveNotebookDocument(i=>{let o=this.notebookDocuments.get(i.notebookDocument.uri);o!==void 0&&this._onDidSave.fire(o)})),r.push(t.notebooks.synchronization.onDidCloseNotebookDocument(i=>{let o=this.notebookDocuments.get(i.notebookDocument.uri);if(o!==void 0){this._onDidClose.fire(o);for(let s of i.cellTextDocuments)n.closeTextDocument({textDocument:s});this.notebookDocuments.delete(i.notebookDocument.uri);for(let s of o.cells)this.notebookCellMap.delete(s.document)}})),ct.Disposable.create(()=>{r.forEach(i=>i.dispose())})}updateCellMap(t){for(let n of t.cells)this.notebookCellMap.set(n.document,[n,t])}};sr.NotebookDocuments=wc});var Ac=A(ke=>{"use strict";Object.defineProperty(ke,"__esModule",{value:!0});ke.thenable=ke.typedArray=ke.stringArray=ke.array=ke.func=ke.error=ke.number=ke.string=ke.boolean=void 0;function cP(e){return e===!0||e===!1}ke.boolean=cP;function Rf(e){return typeof e=="string"||e instanceof String}ke.string=Rf;function uP(e){return typeof e=="number"||e instanceof Number}ke.number=uP;function lP(e){return e instanceof Error}ke.error=lP;function Df(e){return typeof e=="function"}ke.func=Df;function Sf(e){return Array.isArray(e)}ke.array=Sf;function dP(e){return Sf(e)&&e.every(t=>Rf(t))}ke.stringArray=dP;function fP(e,t){return Array.isArray(e)&&e.every(t)}ke.typedArray=fP;function pP(e){return e&&Df(e.then)}ke.thenable=pP});var qc=A(ut=>{"use strict";Object.defineProperty(ut,"__esModule",{value:!0});ut.generateUuid=ut.parse=ut.isUUID=ut.v4=ut.empty=void 0;var Wr=class{constructor(t){this._value=t}asHex(){return this._value}equals(t){return this.asHex()===t.asHex()}},Q=class extends Wr{constructor(){super([Q._randomHex(),Q._randomHex(),Q._randomHex(),Q._randomHex(),Q._randomHex(),Q._randomHex(),Q._randomHex(),Q._randomHex(),"-",Q._randomHex(),Q._randomHex(),Q._randomHex(),Q._randomHex(),"-","4",Q._randomHex(),Q._randomHex(),Q._randomHex(),"-",Q._oneOf(Q._timeHighBits),Q._randomHex(),Q._randomHex(),Q._randomHex(),"-",Q._randomHex(),Q._randomHex(),Q._randomHex(),Q._randomHex(),Q._randomHex(),Q._randomHex(),Q._randomHex(),Q._randomHex(),Q._randomHex(),Q._randomHex(),Q._randomHex(),Q._randomHex()].join(""))}static _oneOf(t){return t[Math.floor(t.length*Math.random())]}static _randomHex(){return Q._oneOf(Q._chars)}};Q._chars=["0","1","2","3","4","5","6","6","7","8","9","a","b","c","d","e","f"];Q._timeHighBits=["8","9","a","b"];ut.empty=new Wr("00000000-0000-0000-0000-000000000000");function Tf(){return new Q}ut.v4=Tf;var gP=/^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/i;function xf(e){return gP.test(e)}ut.isUUID=xf;function mP(e){if(!xf(e))throw new Error("invalid uuid");return new Wr(e)}ut.parse=mP;function hP(){return Tf().asHex()}ut.generateUuid=hP});var wf=A(un=>{"use strict";Object.defineProperty(un,"__esModule",{value:!0});un.attachPartialResult=un.ProgressFeature=un.attachWorkDone=void 0;var cn=qe(),yP=qc(),Et=class{constructor(t,n){this._connection=t,this._token=n,Et.Instances.set(this._token,this)}begin(t,n,r,i){let o={kind:"begin",title:t,percentage:n,message:r,cancellable:i};this._connection.sendProgress(cn.WorkDoneProgress.type,this._token,o)}report(t,n){let r={kind:"report"};typeof t=="number"?(r.percentage=t,n!==void 0&&(r.message=n)):r.message=t,this._connection.sendProgress(cn.WorkDoneProgress.type,this._token,r)}done(){Et.Instances.delete(this._token),this._connection.sendProgress(cn.WorkDoneProgress.type,this._token,{kind:"end"})}};Et.Instances=new Map;var fo=class extends Et{constructor(t,n){super(t,n),this._source=new cn.CancellationTokenSource}get token(){return this._source.token}done(){this._source.dispose(),super.done()}cancel(){this._source.cancel()}},Hr=class{constructor(){}begin(){}report(){}done(){}},po=class extends Hr{constructor(){super(),this._source=new cn.CancellationTokenSource}get token(){return this._source.token}done(){this._source.dispose()}cancel(){this._source.cancel()}};function bP(e,t){if(t===void 0||t.workDoneToken===void 0)return new Hr;let n=t.workDoneToken;return delete t.workDoneToken,new Et(e,n)}un.attachWorkDone=bP;var vP=e=>class extends e{constructor(){super(),this._progressSupported=!1}initialize(t){super.initialize(t),t?.window?.workDoneProgress===!0&&(this._progressSupported=!0,this.connection.onNotification(cn.WorkDoneProgressCancelNotification.type,n=>{let r=Et.Instances.get(n.token);(r instanceof fo||r instanceof po)&&r.cancel()}))}attachWorkDoneProgress(t){return t===void 0?new Hr:new Et(this.connection,t)}createWorkDoneProgress(){if(this._progressSupported){let t=(0,yP.generateUuid)();return this.connection.sendRequest(cn.WorkDoneProgressCreateRequest.type,{token:t}).then(()=>new fo(this.connection,t))}else return Promise.resolve(new po)}};un.ProgressFeature=vP;var Nc;(function(e){e.type=new cn.ProgressType})(Nc||(Nc={}));var Oc=class{constructor(t,n){this._connection=t,this._token=n}report(t){this._connection.sendProgress(Nc.type,this._token,t)}};function CP(e,t){if(t===void 0||t.partialResultToken===void 0)return;let n=t.partialResultToken;return delete t.partialResultToken,new Oc(e,n)}un.attachPartialResult=CP});var kf=A(go=>{"use strict";Object.defineProperty(go,"__esModule",{value:!0});go.ConfigurationFeature=void 0;var PP=qe(),_P=Ac(),RP=e=>class extends e{getConfiguration(t){return t?_P.string(t)?this._getConfiguration({section:t}):this._getConfiguration(t):this._getConfiguration({})}_getConfiguration(t){let n={items:Array.isArray(t)?t:[t]};return this.connection.sendRequest(PP.ConfigurationRequest.type,n).then(r=>Array.isArray(r)?Array.isArray(t)?r:r[0]:Array.isArray(t)?[]:null)}};go.ConfigurationFeature=RP});var Af=A(ho=>{"use strict";Object.defineProperty(ho,"__esModule",{value:!0});ho.WorkspaceFoldersFeature=void 0;var mo=qe(),DP=e=>class extends e{constructor(){super(),this._notificationIsAutoRegistered=!1}initialize(t){super.initialize(t);let n=t.workspace;n&&n.workspaceFolders&&(this._onDidChangeWorkspaceFolders=new mo.Emitter,this.connection.onNotification(mo.DidChangeWorkspaceFoldersNotification.type,r=>{this._onDidChangeWorkspaceFolders.fire(r.event)}))}fillServerCapabilities(t){super.fillServerCapabilities(t);let n=t.workspace?.workspaceFolders?.changeNotifications;this._notificationIsAutoRegistered=n===!0||typeof n=="string"}getWorkspaceFolders(){return this.connection.sendRequest(mo.WorkspaceFoldersRequest.type)}get onDidChangeWorkspaceFolders(){if(!this._onDidChangeWorkspaceFolders)throw new Error("Client doesn't support sending workspace folder change events.");return!this._notificationIsAutoRegistered&&!this._unregistration&&(this._unregistration=this.connection.client.register(mo.DidChangeWorkspaceFoldersNotification.type)),this._onDidChangeWorkspaceFolders.event}};ho.WorkspaceFoldersFeature=DP});var qf=A(yo=>{"use strict";Object.defineProperty(yo,"__esModule",{value:!0});yo.CallHierarchyFeature=void 0;var Ec=qe(),SP=e=>class extends e{get callHierarchy(){return{onPrepare:t=>this.connection.onRequest(Ec.CallHierarchyPrepareRequest.type,(n,r)=>t(n,r,this.attachWorkDoneProgress(n),void 0)),onIncomingCalls:t=>{let n=Ec.CallHierarchyIncomingCallsRequest.type;return this.connection.onRequest(n,(r,i)=>t(r,i,this.attachWorkDoneProgress(r),this.attachPartialResultProgress(n,r)))},onOutgoingCalls:t=>{let n=Ec.CallHierarchyOutgoingCallsRequest.type;return this.connection.onRequest(n,(r,i)=>t(r,i,this.attachWorkDoneProgress(r),this.attachPartialResultProgress(n,r)))}}}};yo.CallHierarchyFeature=SP});var Nf=A(bo=>{"use strict";Object.defineProperty(bo,"__esModule",{value:!0});bo.ShowDocumentFeature=void 0;var TP=qe(),xP=e=>class extends e{showDocument(t){return this.connection.sendRequest(TP.ShowDocumentRequest.type,t)}};bo.ShowDocumentFeature=xP});var Of=A(vo=>{"use strict";Object.defineProperty(vo,"__esModule",{value:!0});vo.FileOperationsFeature=void 0;var ar=qe(),wP=e=>class extends e{onDidCreateFiles(t){return this.connection.onNotification(ar.DidCreateFilesNotification.type,n=>{t(n)})}onDidRenameFiles(t){return this.connection.onNotification(ar.DidRenameFilesNotification.type,n=>{t(n)})}onDidDeleteFiles(t){return this.connection.onNotification(ar.DidDeleteFilesNotification.type,n=>{t(n)})}onWillCreateFiles(t){return this.connection.onRequest(ar.WillCreateFilesRequest.type,(n,r)=>t(n,r))}onWillRenameFiles(t){return this.connection.onRequest(ar.WillRenameFilesRequest.type,(n,r)=>t(n,r))}onWillDeleteFiles(t){return this.connection.onRequest(ar.WillDeleteFilesRequest.type,(n,r)=>t(n,r))}};vo.FileOperationsFeature=wP});var Ef=A(Co=>{"use strict";Object.defineProperty(Co,"__esModule",{value:!0});Co.LinkedEditingRangeFeature=void 0;var kP=qe(),AP=e=>class extends e{onLinkedEditingRange(t){return this.connection.onRequest(kP.LinkedEditingRangeRequest.type,(n,r)=>t(n,r,this.attachWorkDoneProgress(n),void 0))}};Co.LinkedEditingRangeFeature=AP});var Mf=A(Po=>{"use strict";Object.defineProperty(Po,"__esModule",{value:!0});Po.TypeHierarchyFeature=void 0;var Mc=qe(),qP=e=>class extends e{get typeHierarchy(){return{onPrepare:t=>this.connection.onRequest(Mc.TypeHierarchyPrepareRequest.type,(n,r)=>t(n,r,this.attachWorkDoneProgress(n),void 0)),onSupertypes:t=>{let n=Mc.TypeHierarchySupertypesRequest.type;return this.connection.onRequest(n,(r,i)=>t(r,i,this.attachWorkDoneProgress(r),this.attachPartialResultProgress(n,r)))},onSubtypes:t=>{let n=Mc.TypeHierarchySubtypesRequest.type;return this.connection.onRequest(n,(r,i)=>t(r,i,this.attachWorkDoneProgress(r),this.attachPartialResultProgress(n,r)))}}}};Po.TypeHierarchyFeature=qP});var Lf=A(_o=>{"use strict";Object.defineProperty(_o,"__esModule",{value:!0});_o.InlineValueFeature=void 0;var jf=qe(),NP=e=>class extends e{get inlineValue(){return{refresh:()=>this.connection.sendRequest(jf.InlineValueRefreshRequest.type),on:t=>this.connection.onRequest(jf.InlineValueRequest.type,(n,r)=>t(n,r,this.attachWorkDoneProgress(n)))}}};_o.InlineValueFeature=NP});var If=A(Ro=>{"use strict";Object.defineProperty(Ro,"__esModule",{value:!0});Ro.InlayHintFeature=void 0;var jc=qe(),OP=e=>class extends e{get inlayHint(){return{refresh:()=>this.connection.sendRequest(jc.InlayHintRefreshRequest.type),on:t=>this.connection.onRequest(jc.InlayHintRequest.type,(n,r)=>t(n,r,this.attachWorkDoneProgress(n))),resolve:t=>this.connection.onRequest(jc.InlayHintResolveRequest.type,(n,r)=>t(n,r))}}};Ro.InlayHintFeature=OP});var Ff=A(Do=>{"use strict";Object.defineProperty(Do,"__esModule",{value:!0});Do.DiagnosticFeature=void 0;var Ur=qe(),EP=e=>class extends e{get diagnostics(){return{refresh:()=>this.connection.sendRequest(Ur.DiagnosticRefreshRequest.type),on:t=>this.connection.onRequest(Ur.DocumentDiagnosticRequest.type,(n,r)=>t(n,r,this.attachWorkDoneProgress(n),this.attachPartialResultProgress(Ur.DocumentDiagnosticRequest.partialResult,n))),onWorkspace:t=>this.connection.onRequest(Ur.WorkspaceDiagnosticRequest.type,(n,r)=>t(n,r,this.attachWorkDoneProgress(n),this.attachPartialResultProgress(Ur.WorkspaceDiagnosticRequest.partialResult,n)))}}};Do.DiagnosticFeature=EP});var Wf=A(So=>{"use strict";Object.defineProperty(So,"__esModule",{value:!0});So.MonikerFeature=void 0;var MP=qe(),jP=e=>class extends e{get moniker(){return{on:t=>{let n=MP.MonikerRequest.type;return this.connection.onRequest(n,(r,i)=>t(r,i,this.attachWorkDoneProgress(r),this.attachPartialResultProgress(n,r)))}}}};So.MonikerFeature=jP});var Zf=A(ne=>{"use strict";Object.defineProperty(ne,"__esModule",{value:!0});ne.createConnection=ne.combineFeatures=ne.combineNotebooksFeatures=ne.combineLanguagesFeatures=ne.combineWorkspaceFeatures=ne.combineWindowFeatures=ne.combineClientFeatures=ne.combineTracerFeatures=ne.combineTelemetryFeatures=ne.combineConsoleFeatures=ne._NotebooksImpl=ne._LanguagesImpl=ne.BulkUnregistration=ne.BulkRegistration=ne.ErrorMessageTracker=void 0;var M=qe(),lt=Ac(),Ic=qc(),V=wf(),LP=kf(),IP=Af(),FP=qf(),WP=Sc(),HP=Nf(),UP=Of(),BP=Ef(),zP=Mf(),$P=Lf(),YP=If(),VP=Ff(),KP=kc(),GP=Wf();function Lc(e){if(e!==null)return e}var Fc=class{constructor(){this._messages=Object.create(null)}add(t){let n=this._messages[t];n||(n=0),n++,this._messages[t]=n}sendErrors(t){Object.keys(this._messages).forEach(n=>{t.window.showErrorMessage(n)})}};ne.ErrorMessageTracker=Fc;var To=class{constructor(){}rawAttach(t){this._rawConnection=t}attach(t){this._connection=t}get connection(){if(!this._connection)throw new Error("Remote is not attached to a connection yet.");return this._connection}fillServerCapabilities(t){}initialize(t){}error(t){this.send(M.MessageType.Error,t)}warn(t){this.send(M.MessageType.Warning,t)}info(t){this.send(M.MessageType.Info,t)}log(t){this.send(M.MessageType.Log,t)}send(t,n){this._rawConnection&&this._rawConnection.sendNotification(M.LogMessageNotification.type,{type:t,message:n}).catch(()=>{(0,M.RAL)().console.error("Sending log message failed")})}},Wc=class{constructor(){}attach(t){this._connection=t}get connection(){if(!this._connection)throw new Error("Remote is not attached to a connection yet.");return this._connection}initialize(t){}fillServerCapabilities(t){}showErrorMessage(t,...n){let r={type:M.MessageType.Error,message:t,actions:n};return this.connection.sendRequest(M.ShowMessageRequest.type,r).then(Lc)}showWarningMessage(t,...n){let r={type:M.MessageType.Warning,message:t,actions:n};return this.connection.sendRequest(M.ShowMessageRequest.type,r).then(Lc)}showInformationMessage(t,...n){let r={type:M.MessageType.Info,message:t,actions:n};return this.connection.sendRequest(M.ShowMessageRequest.type,r).then(Lc)}},Hf=(0,HP.ShowDocumentFeature)((0,V.ProgressFeature)(Wc)),JP;(function(e){function t(){return new xo}e.create=t})(JP=ne.BulkRegistration||(ne.BulkRegistration={}));var xo=class{constructor(){this._registrations=[],this._registered=new Set}add(t,n){let r=lt.string(t)?t:t.method;if(this._registered.has(r))throw new Error(`${r} is already added to this registration`);let i=Ic.generateUuid();this._registrations.push({id:i,method:r,registerOptions:n||{}}),this._registered.add(r)}asRegistrationParams(){return{registrations:this._registrations}}},QP;(function(e){function t(){return new Br(void 0,[])}e.create=t})(QP=ne.BulkUnregistration||(ne.BulkUnregistration={}));var Br=class{constructor(t,n){this._connection=t,this._unregistrations=new Map,n.forEach(r=>{this._unregistrations.set(r.method,r)})}get isAttached(){return!!this._connection}attach(t){this._connection=t}add(t){this._unregistrations.set(t.method,t)}dispose(){let t=[];for(let r of this._unregistrations.values())t.push(r);let n={unregisterations:t};this._connection.sendRequest(M.UnregistrationRequest.type,n).catch(()=>{this._connection.console.info("Bulk unregistration failed.")})}disposeSingle(t){let n=lt.string(t)?t:t.method,r=this._unregistrations.get(n);if(!r)return!1;let i={unregisterations:[r]};return this._connection.sendRequest(M.UnregistrationRequest.type,i).then(()=>{this._unregistrations.delete(n)},o=>{this._connection.console.info(`Un-registering request handler for ${r.id} failed.`)}),!0}},wo=class{attach(t){this._connection=t}get connection(){if(!this._connection)throw new Error("Remote is not attached to a connection yet.");return this._connection}initialize(t){}fillServerCapabilities(t){}register(t,n,r){return t instanceof xo?this.registerMany(t):t instanceof Br?this.registerSingle1(t,n,r):this.registerSingle2(t,n)}registerSingle1(t,n,r){let i=lt.string(n)?n:n.method,o=Ic.generateUuid(),s={registrations:[{id:o,method:i,registerOptions:r||{}}]};return t.isAttached||t.attach(this.connection),this.connection.sendRequest(M.RegistrationRequest.type,s).then(u=>(t.add({id:o,method:i}),t),u=>(this.connection.console.info(`Registering request handler for ${i} failed.`),Promise.reject(u)))}registerSingle2(t,n){let r=lt.string(t)?t:t.method,i=Ic.generateUuid(),o={registrations:[{id:i,method:r,registerOptions:n||{}}]};return this.connection.sendRequest(M.RegistrationRequest.type,o).then(s=>M.Disposable.create(()=>{this.unregisterSingle(i,r).catch(()=>{this.connection.console.info(`Un-registering capability with id ${i} failed.`)})}),s=>(this.connection.console.info(`Registering request handler for ${r} failed.`),Promise.reject(s)))}unregisterSingle(t,n){let r={unregisterations:[{id:t,method:n}]};return this.connection.sendRequest(M.UnregistrationRequest.type,r).catch(()=>{this.connection.console.info(`Un-registering request handler for ${t} failed.`)})}registerMany(t){let n=t.asRegistrationParams();return this.connection.sendRequest(M.RegistrationRequest.type,n).then(()=>new Br(this._connection,n.registrations.map(r=>({id:r.id,method:r.method}))),r=>(this.connection.console.info("Bulk registration failed."),Promise.reject(r)))}},Hc=class{constructor(){}attach(t){this._connection=t}get connection(){if(!this._connection)throw new Error("Remote is not attached to a connection yet.");return this._connection}initialize(t){}fillServerCapabilities(t){}applyEdit(t){function n(i){return i&&!!i.edit}let r=n(t)?t:{edit:t};return this.connection.sendRequest(M.ApplyWorkspaceEditRequest.type,r)}},Uf=(0,UP.FileOperationsFeature)((0,IP.WorkspaceFoldersFeature)((0,LP.ConfigurationFeature)(Hc))),ko=class{constructor(){this._trace=M.Trace.Off}attach(t){this._connection=t}get connection(){if(!this._connection)throw new Error("Remote is not attached to a connection yet.");return this._connection}initialize(t){}fillServerCapabilities(t){}set trace(t){this._trace=t}log(t,n){this._trace!==M.Trace.Off&&this.connection.sendNotification(M.LogTraceNotification.type,{message:t,verbose:this._trace===M.Trace.Verbose?n:void 0}).catch(()=>{})}},Ao=class{constructor(){}attach(t){this._connection=t}get connection(){if(!this._connection)throw new Error("Remote is not attached to a connection yet.");return this._connection}initialize(t){}fillServerCapabilities(t){}logEvent(t){this.connection.sendNotification(M.TelemetryEventNotification.type,t).catch(()=>{this.connection.console.log("Sending TelemetryEventNotification failed")})}},qo=class{constructor(){}attach(t){this._connection=t}get connection(){if(!this._connection)throw new Error("Remote is not attached to a connection yet.");return this._connection}initialize(t){}fillServerCapabilities(t){}attachWorkDoneProgress(t){return(0,V.attachWorkDone)(this.connection,t)}attachPartialResultProgress(t,n){return(0,V.attachPartialResult)(this.connection,n)}};ne._LanguagesImpl=qo;var Bf=(0,GP.MonikerFeature)((0,VP.DiagnosticFeature)((0,YP.InlayHintFeature)((0,$P.InlineValueFeature)((0,zP.TypeHierarchyFeature)((0,BP.LinkedEditingRangeFeature)((0,WP.SemanticTokensFeature)((0,FP.CallHierarchyFeature)(qo)))))))),No=class{constructor(){}attach(t){this._connection=t}get connection(){if(!this._connection)throw new Error("Remote is not attached to a connection yet.");return this._connection}initialize(t){}fillServerCapabilities(t){}attachWorkDoneProgress(t){return(0,V.attachWorkDone)(this.connection,t)}attachPartialResultProgress(t,n){return(0,V.attachPartialResult)(this.connection,n)}};ne._NotebooksImpl=No;var zf=(0,KP.NotebookSyncFeature)(No);function $f(e,t){return function(n){return t(e(n))}}ne.combineConsoleFeatures=$f;function Yf(e,t){return function(n){return t(e(n))}}ne.combineTelemetryFeatures=Yf;function Vf(e,t){return function(n){return t(e(n))}}ne.combineTracerFeatures=Vf;function Kf(e,t){return function(n){return t(e(n))}}ne.combineClientFeatures=Kf;function Gf(e,t){return function(n){return t(e(n))}}ne.combineWindowFeatures=Gf;function Jf(e,t){return function(n){return t(e(n))}}ne.combineWorkspaceFeatures=Jf;function Qf(e,t){return function(n){return t(e(n))}}ne.combineLanguagesFeatures=Qf;function Xf(e,t){return function(n){return t(e(n))}}ne.combineNotebooksFeatures=Xf;function XP(e,t){function n(i,o,s){return i&&o?s(i,o):i||o}return{__brand:"features",console:n(e.console,t.console,$f),tracer:n(e.tracer,t.tracer,Vf),telemetry:n(e.telemetry,t.telemetry,Yf),client:n(e.client,t.client,Kf),window:n(e.window,t.window,Gf),workspace:n(e.workspace,t.workspace,Jf),languages:n(e.languages,t.languages,Qf),notebooks:n(e.notebooks,t.notebooks,Xf)}}ne.combineFeatures=XP;function ZP(e,t,n){let r=n&&n.console?new(n.console(To)):new To,i=e(r);r.rawAttach(i);let o=n&&n.tracer?new(n.tracer(ko)):new ko,s=n&&n.telemetry?new(n.telemetry(Ao)):new Ao,u=n&&n.client?new(n.client(wo)):new wo,c=n&&n.window?new(n.window(Hf)):new Hf,p=n&&n.workspace?new(n.workspace(Uf)):new Uf,g=n&&n.languages?new(n.languages(Bf)):new Bf,b=n&&n.notebooks?new(n.notebooks(zf)):new zf,R=[r,o,s,u,c,p,g,b];function D(_){return _ instanceof Promise?_:lt.thenable(_)?new Promise((v,N)=>{_.then(z=>v(z),z=>N(z))}):Promise.resolve(_)}let T,q,B,L={listen:()=>i.listen(),sendRequest:(_,...v)=>i.sendRequest(lt.string(_)?_:_.method,...v),onRequest:(_,v)=>i.onRequest(_,v),sendNotification:(_,v)=>{let N=lt.string(_)?_:_.method;return arguments.length===1?i.sendNotification(N):i.sendNotification(N,v)},onNotification:(_,v)=>i.onNotification(_,v),onProgress:i.onProgress,sendProgress:i.sendProgress,onInitialize:_=>(q=_,{dispose:()=>{q=void 0}}),onInitialized:_=>i.onNotification(M.InitializedNotification.type,_),onShutdown:_=>(T=_,{dispose:()=>{T=void 0}}),onExit:_=>(B=_,{dispose:()=>{B=void 0}}),get console(){return r},get telemetry(){return s},get tracer(){return o},get client(){return u},get window(){return c},get workspace(){return p},get languages(){return g},get notebooks(){return b},onDidChangeConfiguration:_=>i.onNotification(M.DidChangeConfigurationNotification.type,_),onDidChangeWatchedFiles:_=>i.onNotification(M.DidChangeWatchedFilesNotification.type,_),__textDocumentSync:void 0,onDidOpenTextDocument:_=>i.onNotification(M.DidOpenTextDocumentNotification.type,_),onDidChangeTextDocument:_=>i.onNotification(M.DidChangeTextDocumentNotification.type,_),onDidCloseTextDocument:_=>i.onNotification(M.DidCloseTextDocumentNotification.type,_),onWillSaveTextDocument:_=>i.onNotification(M.WillSaveTextDocumentNotification.type,_),onWillSaveTextDocumentWaitUntil:_=>i.onRequest(M.WillSaveTextDocumentWaitUntilRequest.type,_),onDidSaveTextDocument:_=>i.onNotification(M.DidSaveTextDocumentNotification.type,_),sendDiagnostics:_=>i.sendNotification(M.PublishDiagnosticsNotification.type,_),onHover:_=>i.onRequest(M.HoverRequest.type,(v,N)=>_(v,N,(0,V.attachWorkDone)(i,v),void 0)),onCompletion:_=>i.onRequest(M.CompletionRequest.type,(v,N)=>_(v,N,(0,V.attachWorkDone)(i,v),(0,V.attachPartialResult)(i,v))),onCompletionResolve:_=>i.onRequest(M.CompletionResolveRequest.type,_),onSignatureHelp:_=>i.onRequest(M.SignatureHelpRequest.type,(v,N)=>_(v,N,(0,V.attachWorkDone)(i,v),void 0)),onDeclaration:_=>i.onRequest(M.DeclarationRequest.type,(v,N)=>_(v,N,(0,V.attachWorkDone)(i,v),(0,V.attachPartialResult)(i,v))),onDefinition:_=>i.onRequest(M.DefinitionRequest.type,(v,N)=>_(v,N,(0,V.attachWorkDone)(i,v),(0,V.attachPartialResult)(i,v))),onTypeDefinition:_=>i.onRequest(M.TypeDefinitionRequest.type,(v,N)=>_(v,N,(0,V.attachWorkDone)(i,v),(0,V.attachPartialResult)(i,v))),onImplementation:_=>i.onRequest(M.ImplementationRequest.type,(v,N)=>_(v,N,(0,V.attachWorkDone)(i,v),(0,V.attachPartialResult)(i,v))),onReferences:_=>i.onRequest(M.ReferencesRequest.type,(v,N)=>_(v,N,(0,V.attachWorkDone)(i,v),(0,V.attachPartialResult)(i,v))),onDocumentHighlight:_=>i.onRequest(M.DocumentHighlightRequest.type,(v,N)=>_(v,N,(0,V.attachWorkDone)(i,v),(0,V.attachPartialResult)(i,v))),onDocumentSymbol:_=>i.onRequest(M.DocumentSymbolRequest.type,(v,N)=>_(v,N,(0,V.attachWorkDone)(i,v),(0,V.attachPartialResult)(i,v))),onWorkspaceSymbol:_=>i.onRequest(M.WorkspaceSymbolRequest.type,(v,N)=>_(v,N,(0,V.attachWorkDone)(i,v),(0,V.attachPartialResult)(i,v))),onWorkspaceSymbolResolve:_=>i.onRequest(M.WorkspaceSymbolResolveRequest.type,_),onCodeAction:_=>i.onRequest(M.CodeActionRequest.type,(v,N)=>_(v,N,(0,V.attachWorkDone)(i,v),(0,V.attachPartialResult)(i,v))),onCodeActionResolve:_=>i.onRequest(M.CodeActionResolveRequest.type,(v,N)=>_(v,N)),onCodeLens:_=>i.onRequest(M.CodeLensRequest.type,(v,N)=>_(v,N,(0,V.attachWorkDone)(i,v),(0,V.attachPartialResult)(i,v))),onCodeLensResolve:_=>i.onRequest(M.CodeLensResolveRequest.type,(v,N)=>_(v,N)),onDocumentFormatting:_=>i.onRequest(M.DocumentFormattingRequest.type,(v,N)=>_(v,N,(0,V.attachWorkDone)(i,v),void 0)),onDocumentRangeFormatting:_=>i.onRequest(M.DocumentRangeFormattingRequest.type,(v,N)=>_(v,N,(0,V.attachWorkDone)(i,v),void 0)),onDocumentOnTypeFormatting:_=>i.onRequest(M.DocumentOnTypeFormattingRequest.type,(v,N)=>_(v,N)),onRenameRequest:_=>i.onRequest(M.RenameRequest.type,(v,N)=>_(v,N,(0,V.attachWorkDone)(i,v),void 0)),onPrepareRename:_=>i.onRequest(M.PrepareRenameRequest.type,(v,N)=>_(v,N)),onDocumentLinks:_=>i.onRequest(M.DocumentLinkRequest.type,(v,N)=>_(v,N,(0,V.attachWorkDone)(i,v),(0,V.attachPartialResult)(i,v))),onDocumentLinkResolve:_=>i.onRequest(M.DocumentLinkResolveRequest.type,(v,N)=>_(v,N)),onDocumentColor:_=>i.onRequest(M.DocumentColorRequest.type,(v,N)=>_(v,N,(0,V.attachWorkDone)(i,v),(0,V.attachPartialResult)(i,v))),onColorPresentation:_=>i.onRequest(M.ColorPresentationRequest.type,(v,N)=>_(v,N,(0,V.attachWorkDone)(i,v),(0,V.attachPartialResult)(i,v))),onFoldingRanges:_=>i.onRequest(M.FoldingRangeRequest.type,(v,N)=>_(v,N,(0,V.attachWorkDone)(i,v),(0,V.attachPartialResult)(i,v))),onSelectionRanges:_=>i.onRequest(M.SelectionRangeRequest.type,(v,N)=>_(v,N,(0,V.attachWorkDone)(i,v),(0,V.attachPartialResult)(i,v))),onExecuteCommand:_=>i.onRequest(M.ExecuteCommandRequest.type,(v,N)=>_(v,N,(0,V.attachWorkDone)(i,v),void 0)),dispose:()=>i.dispose()};for(let _ of R)_.attach(L);return i.onRequest(M.InitializeRequest.type,_=>{t.initialize(_),lt.string(_.trace)&&(o.trace=M.Trace.fromString(_.trace));for(let v of R)v.initialize(_.capabilities);if(q){let v=q(_,new M.CancellationTokenSource().token,(0,V.attachWorkDone)(i,_),void 0);return D(v).then(N=>{if(N instanceof M.ResponseError)return N;let z=N;z||(z={capabilities:{}});let Z=z.capabilities;Z||(Z={},z.capabilities=Z),Z.textDocumentSync===void 0||Z.textDocumentSync===null?Z.textDocumentSync=lt.number(L.__textDocumentSync)?L.__textDocumentSync:M.TextDocumentSyncKind.None:!lt.number(Z.textDocumentSync)&&!lt.number(Z.textDocumentSync.change)&&(Z.textDocumentSync.change=lt.number(L.__textDocumentSync)?L.__textDocumentSync:M.TextDocumentSyncKind.None);for(let ue of R)ue.fillServerCapabilities(Z);return z})}else{let v={capabilities:{textDocumentSync:M.TextDocumentSyncKind.None}};for(let N of R)N.fillServerCapabilities(v.capabilities);return v}}),i.onRequest(M.ShutdownRequest.type,()=>{if(t.shutdownReceived=!0,T)return T(new M.CancellationTokenSource().token)}),i.onNotification(M.ExitNotification.type,()=>{try{B&&B()}finally{t.shutdownReceived?t.exit(0):t.exit(1)}}),i.onNotification(M.SetTraceNotification.type,_=>{o.trace=M.Trace.fromString(_.value)}),L}ne.createConnection=ZP});var Uc=A(Be=>{"use strict";var e_=Be&&Be.__createBinding||(Object.create?function(e,t,n,r){r===void 0&&(r=n);var i=Object.getOwnPropertyDescriptor(t,n);(!i||("get"in i?!t.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:function(){return t[n]}}),Object.defineProperty(e,r,i)}:function(e,t,n,r){r===void 0&&(r=n),e[r]=t[n]}),ep=Be&&Be.__exportStar||function(e,t){for(var n in e)n!=="default"&&!Object.prototype.hasOwnProperty.call(t,n)&&e_(t,e,n)};Object.defineProperty(Be,"__esModule",{value:!0});Be.ProposedFeatures=Be.NotebookDocuments=Be.TextDocuments=Be.SemanticTokensBuilder=void 0;var t_=Sc();Object.defineProperty(Be,"SemanticTokensBuilder",{enumerable:!0,get:function(){return t_.SemanticTokensBuilder}});ep(qe(),Be);var n_=xc();Object.defineProperty(Be,"TextDocuments",{enumerable:!0,get:function(){return n_.TextDocuments}});var r_=kc();Object.defineProperty(Be,"NotebookDocuments",{enumerable:!0,get:function(){return r_.NotebookDocuments}});ep(Zf(),Be);var i_;(function(e){e.all={__brand:"features"}})(i_=Be.ProposedFeatures||(Be.ProposedFeatures={}))});var np=A((SS,tp)=>{"use strict";tp.exports=qe()});var op=A(Mt=>{"use strict";var o_=Mt&&Mt.__createBinding||(Object.create?function(e,t,n,r){r===void 0&&(r=n);var i=Object.getOwnPropertyDescriptor(t,n);(!i||("get"in i?!t.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:function(){return t[n]}}),Object.defineProperty(e,r,i)}:function(e,t,n,r){r===void 0&&(r=n),e[r]=t[n]}),ip=Mt&&Mt.__exportStar||function(e,t){for(var n in e)n!=="default"&&!Object.prototype.hasOwnProperty.call(t,n)&&o_(t,e,n)};Object.defineProperty(Mt,"__esModule",{value:!0});Mt.createConnection=void 0;var Oo=Uc();ip(np(),Mt);ip(Uc(),Mt);var rp=!1,s_={initialize:e=>{},get shutdownReceived(){return rp},set shutdownReceived(e){rp=e},exit:e=>{}};function a_(e,t,n,r){let i,o,s,u;e!==void 0&&e.__brand==="features"&&(i=e,e=t,t=n,n=r),Oo.ConnectionStrategy.is(e)||Oo.ConnectionOptions.is(e)?u=e:(o=e,s=t,u=n);let c=p=>(0,Oo.createProtocolConnection)(o,s,p,u);return(0,Oo.createConnection)(c,s_,i)}Mt.createConnection=a_});var ln=A((xS,sp)=>{"use strict";sp.exports=op()});var Xc=A((_T,vp)=>{"use strict";function jt(e){if(typeof e!="string")throw new TypeError("Path must be a string. Received "+JSON.stringify(e))}function bp(e,t){for(var n="",r=0,i=-1,o=0,s,u=0;u<=e.length;++u){if(u<e.length)s=e.charCodeAt(u);else{if(s===47)break;s=47}if(s===47){if(!(i===u-1||o===1))if(i!==u-1&&o===2){if(n.length<2||r!==2||n.charCodeAt(n.length-1)!==46||n.charCodeAt(n.length-2)!==46){if(n.length>2){var c=n.lastIndexOf("/");if(c!==n.length-1){c===-1?(n="",r=0):(n=n.slice(0,c),r=n.length-1-n.lastIndexOf("/")),i=u,o=0;continue}}else if(n.length===2||n.length===1){n="",r=0,i=u,o=0;continue}}t&&(n.length>0?n+="/..":n="..",r=2)}else n.length>0?n+="/"+e.slice(i+1,u):n=e.slice(i+1,u),r=u-i-1;i=u,o=0}else s===46&&o!==-1?++o:o=-1}return n}function U_(e,t){var n=t.dir||t.root,r=t.base||(t.name||"")+(t.ext||"");return n?n===t.root?n+r:n+e+r:r}var lr={resolve:function(){for(var t="",n=!1,r,i=arguments.length-1;i>=-1&&!n;i--){var o;i>=0?o=arguments[i]:(r===void 0&&(r=process.cwd()),o=r),jt(o),o.length!==0&&(t=o+"/"+t,n=o.charCodeAt(0)===47)}return t=bp(t,!n),n?t.length>0?"/"+t:"/":t.length>0?t:"."},normalize:function(t){if(jt(t),t.length===0)return".";var n=t.charCodeAt(0)===47,r=t.charCodeAt(t.length-1)===47;return t=bp(t,!n),t.length===0&&!n&&(t="."),t.length>0&&r&&(t+="/"),n?"/"+t:t},isAbsolute:function(t){return jt(t),t.length>0&&t.charCodeAt(0)===47},join:function(){if(arguments.length===0)return".";for(var t,n=0;n<arguments.length;++n){var r=arguments[n];jt(r),r.length>0&&(t===void 0?t=r:t+="/"+r)}return t===void 0?".":lr.normalize(t)},relative:function(t,n){if(jt(t),jt(n),t===n||(t=lr.resolve(t),n=lr.resolve(n),t===n))return"";for(var r=1;r<t.length&&t.charCodeAt(r)===47;++r);for(var i=t.length,o=i-r,s=1;s<n.length&&n.charCodeAt(s)===47;++s);for(var u=n.length,c=u-s,p=o<c?o:c,g=-1,b=0;b<=p;++b){if(b===p){if(c>p){if(n.charCodeAt(s+b)===47)return n.slice(s+b+1);if(b===0)return n.slice(s+b)}else o>p&&(t.charCodeAt(r+b)===47?g=b:b===0&&(g=0));break}var R=t.charCodeAt(r+b),D=n.charCodeAt(s+b);if(R!==D)break;R===47&&(g=b)}var T="";for(b=r+g+1;b<=i;++b)(b===i||t.charCodeAt(b)===47)&&(T.length===0?T+="..":T+="/..");return T.length>0?T+n.slice(s+g):(s+=g,n.charCodeAt(s)===47&&++s,n.slice(s))},_makeLong:function(t){return t},dirname:function(t){if(jt(t),t.length===0)return".";for(var n=t.charCodeAt(0),r=n===47,i=-1,o=!0,s=t.length-1;s>=1;--s)if(n=t.charCodeAt(s),n===47){if(!o){i=s;break}}else o=!1;return i===-1?r?"/":".":r&&i===1?"//":t.slice(0,i)},basename:function(t,n){if(n!==void 0&&typeof n!="string")throw new TypeError('"ext" argument must be a string');jt(t);var r=0,i=-1,o=!0,s;if(n!==void 0&&n.length>0&&n.length<=t.length){if(n.length===t.length&&n===t)return"";var u=n.length-1,c=-1;for(s=t.length-1;s>=0;--s){var p=t.charCodeAt(s);if(p===47){if(!o){r=s+1;break}}else c===-1&&(o=!1,c=s+1),u>=0&&(p===n.charCodeAt(u)?--u===-1&&(i=s):(u=-1,i=c))}return r===i?i=c:i===-1&&(i=t.length),t.slice(r,i)}else{for(s=t.length-1;s>=0;--s)if(t.charCodeAt(s)===47){if(!o){r=s+1;break}}else i===-1&&(o=!1,i=s+1);return i===-1?"":t.slice(r,i)}},extname:function(t){jt(t);for(var n=-1,r=0,i=-1,o=!0,s=0,u=t.length-1;u>=0;--u){var c=t.charCodeAt(u);if(c===47){if(!o){r=u+1;break}continue}i===-1&&(o=!1,i=u+1),c===46?n===-1?n=u:s!==1&&(s=1):n!==-1&&(s=-1)}return n===-1||i===-1||s===0||s===1&&n===i-1&&n===r+1?"":t.slice(n,i)},format:function(t){if(t===null||typeof t!="object")throw new TypeError('The "pathObject" argument must be of type Object. Received type '+typeof t);return U_("/",t)},parse:function(t){jt(t);var n={root:"",dir:"",base:"",ext:"",name:""};if(t.length===0)return n;var r=t.charCodeAt(0),i=r===47,o;i?(n.root="/",o=1):o=0;for(var s=-1,u=0,c=-1,p=!0,g=t.length-1,b=0;g>=o;--g){if(r=t.charCodeAt(g),r===47){if(!p){u=g+1;break}continue}c===-1&&(p=!1,c=g+1),r===46?s===-1?s=g:b!==1&&(b=1):s!==-1&&(b=-1)}return s===-1||c===-1||b===0||b===1&&s===c-1&&s===u+1?c!==-1&&(u===0&&i?n.base=n.name=t.slice(1,c):n.base=n.name=t.slice(u,c)):(u===0&&i?(n.name=t.slice(1,s),n.base=t.slice(1,c)):(n.name=t.slice(u,s),n.base=t.slice(u,c)),n.ext=t.slice(s,c)),u>0?n.dir=t.slice(0,u-1):i&&(n.dir="/"),n},sep:"/",delimiter:":",win32:null,posix:null};lr.posix=lr;vp.exports=lr});import{CONFIG_FILE_NAMES as $s,loadConfig as Th}from"@redocly/openapi-core";var nu;(()=>{"use strict";var e={470:i=>{function o(c){if(typeof c!="string")throw new TypeError("Path must be a string. Received "+JSON.stringify(c))}function s(c,p){for(var g,b="",R=0,D=-1,T=0,q=0;q<=c.length;++q){if(q<c.length)g=c.charCodeAt(q);else{if(g===47)break;g=47}if(g===47){if(!(D===q-1||T===1))if(D!==q-1&&T===2){if(b.length<2||R!==2||b.charCodeAt(b.length-1)!==46||b.charCodeAt(b.length-2)!==46){if(b.length>2){var B=b.lastIndexOf("/");if(B!==b.length-1){B===-1?(b="",R=0):R=(b=b.slice(0,B)).length-1-b.lastIndexOf("/"),D=q,T=0;continue}}else if(b.length===2||b.length===1){b="",R=0,D=q,T=0;continue}}p&&(b.length>0?b+="/..":b="..",R=2)}else b.length>0?b+="/"+c.slice(D+1,q):b=c.slice(D+1,q),R=q-D-1;D=q,T=0}else g===46&&T!==-1?++T:T=-1}return b}var u={resolve:function(){for(var c,p="",g=!1,b=arguments.length-1;b>=-1&&!g;b--){var R;b>=0?R=arguments[b]:(c===void 0&&(c=process.cwd()),R=c),o(R),R.length!==0&&(p=R+"/"+p,g=R.charCodeAt(0)===47)}return p=s(p,!g),g?p.length>0?"/"+p:"/":p.length>0?p:"."},normalize:function(c){if(o(c),c.length===0)return".";var p=c.charCodeAt(0)===47,g=c.charCodeAt(c.length-1)===47;return(c=s(c,!p)).length!==0||p||(c="."),c.length>0&&g&&(c+="/"),p?"/"+c:c},isAbsolute:function(c){return o(c),c.length>0&&c.charCodeAt(0)===47},join:function(){if(arguments.length===0)return".";for(var c,p=0;p<arguments.length;++p){var g=arguments[p];o(g),g.length>0&&(c===void 0?c=g:c+="/"+g)}return c===void 0?".":u.normalize(c)},relative:function(c,p){if(o(c),o(p),c===p||(c=u.resolve(c))===(p=u.resolve(p)))return"";for(var g=1;g<c.length&&c.charCodeAt(g)===47;++g);for(var b=c.length,R=b-g,D=1;D<p.length&&p.charCodeAt(D)===47;++D);for(var T=p.length-D,q=R<T?R:T,B=-1,L=0;L<=q;++L){if(L===q){if(T>q){if(p.charCodeAt(D+L)===47)return p.slice(D+L+1);if(L===0)return p.slice(D+L)}else R>q&&(c.charCodeAt(g+L)===47?B=L:L===0&&(B=0));break}var _=c.charCodeAt(g+L);if(_!==p.charCodeAt(D+L))break;_===47&&(B=L)}var v="";for(L=g+B+1;L<=b;++L)L!==b&&c.charCodeAt(L)!==47||(v.length===0?v+="..":v+="/..");return v.length>0?v+p.slice(D+B):(D+=B,p.charCodeAt(D)===47&&++D,p.slice(D))},_makeLong:function(c){return c},dirname:function(c){if(o(c),c.length===0)return".";for(var p=c.charCodeAt(0),g=p===47,b=-1,R=!0,D=c.length-1;D>=1;--D)if((p=c.charCodeAt(D))===47){if(!R){b=D;break}}else R=!1;return b===-1?g?"/":".":g&&b===1?"//":c.slice(0,b)},basename:function(c,p){if(p!==void 0&&typeof p!="string")throw new TypeError('"ext" argument must be a string');o(c);var g,b=0,R=-1,D=!0;if(p!==void 0&&p.length>0&&p.length<=c.length){if(p.length===c.length&&p===c)return"";var T=p.length-1,q=-1;for(g=c.length-1;g>=0;--g){var B=c.charCodeAt(g);if(B===47){if(!D){b=g+1;break}}else q===-1&&(D=!1,q=g+1),T>=0&&(B===p.charCodeAt(T)?--T==-1&&(R=g):(T=-1,R=q))}return b===R?R=q:R===-1&&(R=c.length),c.slice(b,R)}for(g=c.length-1;g>=0;--g)if(c.charCodeAt(g)===47){if(!D){b=g+1;break}}else R===-1&&(D=!1,R=g+1);return R===-1?"":c.slice(b,R)},extname:function(c){o(c);for(var p=-1,g=0,b=-1,R=!0,D=0,T=c.length-1;T>=0;--T){var q=c.charCodeAt(T);if(q!==47)b===-1&&(R=!1,b=T+1),q===46?p===-1?p=T:D!==1&&(D=1):p!==-1&&(D=-1);else if(!R){g=T+1;break}}return p===-1||b===-1||D===0||D===1&&p===b-1&&p===g+1?"":c.slice(p,b)},format:function(c){if(c===null||typeof c!="object")throw new TypeError('The "pathObject" argument must be of type Object. Received type '+typeof c);return function(p,g){var b=g.dir||g.root,R=g.base||(g.name||"")+(g.ext||"");return b?b===g.root?b+R:b+"/"+R:R}(0,c)},parse:function(c){o(c);var p={root:"",dir:"",base:"",ext:"",name:""};if(c.length===0)return p;var g,b=c.charCodeAt(0),R=b===47;R?(p.root="/",g=1):g=0;for(var D=-1,T=0,q=-1,B=!0,L=c.length-1,_=0;L>=g;--L)if((b=c.charCodeAt(L))!==47)q===-1&&(B=!1,q=L+1),b===46?D===-1?D=L:_!==1&&(_=1):D!==-1&&(_=-1);else if(!B){T=L+1;break}return D===-1||q===-1||_===0||_===1&&D===q-1&&D===T+1?q!==-1&&(p.base=p.name=T===0&&R?c.slice(1,q):c.slice(T,q)):(T===0&&R?(p.name=c.slice(1,D),p.base=c.slice(1,q)):(p.name=c.slice(T,D),p.base=c.slice(T,q)),p.ext=c.slice(D,q)),T>0?p.dir=c.slice(0,T-1):R&&(p.dir="/"),p},sep:"/",delimiter:":",win32:null,posix:null};u.posix=u,i.exports=u}},t={};function n(i){var o=t[i];if(o!==void 0)return o.exports;var s=t[i]={exports:{}};return e[i](s,s.exports,n),s.exports}n.d=(i,o)=>{for(var s in o)n.o(o,s)&&!n.o(i,s)&&Object.defineProperty(i,s,{enumerable:!0,get:o[s]})},n.o=(i,o)=>Object.prototype.hasOwnProperty.call(i,o),n.r=i=>{typeof Symbol<"u"&&Symbol.toStringTag&&Object.defineProperty(i,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(i,"__esModule",{value:!0})};var r={};(()=>{let i;n.r(r),n.d(r,{URI:()=>R,Utils:()=>ft}),typeof process=="object"?i=process.platform==="win32":typeof navigator=="object"&&(i=navigator.userAgent.indexOf("Windows")>=0);let o=/^\w[\w\d+.-]*$/,s=/^\//,u=/^\/\//;function c(j,x){if(!j.scheme&&x)throw new Error(`[UriError]: Scheme is missing: {scheme: "", authority: "${j.authority}", path: "${j.path}", query: "${j.query}", fragment: "${j.fragment}"}`);if(j.scheme&&!o.test(j.scheme))throw new Error("[UriError]: Scheme contains illegal characters.");if(j.path){if(j.authority){if(!s.test(j.path))throw new Error('[UriError]: If a URI contains an authority component, then the path component must either be empty or begin with a slash ("/") character')}else if(u.test(j.path))throw new Error('[UriError]: If a URI does not contain an authority component, then the path cannot begin with two slash characters ("//")')}}let p="",g="/",b=/^(([^:/?#]+?):)?(\/\/([^/?#]*))?([^?#]*)(\?([^#]*))?(#(.*))?/;class R{static isUri(x){return x instanceof R||!!x&&typeof x.authority=="string"&&typeof x.fragment=="string"&&typeof x.path=="string"&&typeof x.query=="string"&&typeof x.scheme=="string"&&typeof x.fsPath=="string"&&typeof x.with=="function"&&typeof x.toString=="function"}scheme;authority;path;query;fragment;constructor(x,H,I,ie,X,K=!1){typeof x=="object"?(this.scheme=x.scheme||p,this.authority=x.authority||p,this.path=x.path||p,this.query=x.query||p,this.fragment=x.fragment||p):(this.scheme=function(Ve,Ae){return Ve||Ae?Ve:"file"}(x,K),this.authority=H||p,this.path=function(Ve,Ae){switch(Ve){case"https":case"http":case"file":Ae?Ae[0]!==g&&(Ae=g+Ae):Ae=g}return Ae}(this.scheme,I||p),this.query=ie||p,this.fragment=X||p,c(this,K))}get fsPath(){return _(this,!1)}with(x){if(!x)return this;let{scheme:H,authority:I,path:ie,query:X,fragment:K}=x;return H===void 0?H=this.scheme:H===null&&(H=p),I===void 0?I=this.authority:I===null&&(I=p),ie===void 0?ie=this.path:ie===null&&(ie=p),X===void 0?X=this.query:X===null&&(X=p),K===void 0?K=this.fragment:K===null&&(K=p),H===this.scheme&&I===this.authority&&ie===this.path&&X===this.query&&K===this.fragment?this:new T(H,I,ie,X,K)}static parse(x,H=!1){let I=b.exec(x);return I?new T(I[2]||p,Z(I[4]||p),Z(I[5]||p),Z(I[7]||p),Z(I[9]||p),H):new T(p,p,p,p,p)}static file(x){let H=p;if(i&&(x=x.replace(/\\/g,g)),x[0]===g&&x[1]===g){let I=x.indexOf(g,2);I===-1?(H=x.substring(2),x=g):(H=x.substring(2,I),x=x.substring(I)||g)}return new T("file",H,x,p,p)}static from(x){let H=new T(x.scheme,x.authority,x.path,x.query,x.fragment);return c(H,!0),H}toString(x=!1){return v(this,x)}toJSON(){return this}static revive(x){if(x){if(x instanceof R)return x;{let H=new T(x);return H._formatted=x.external,H._fsPath=x._sep===D?x.fsPath:null,H}}return x}}let D=i?1:void 0;class T extends R{_formatted=null;_fsPath=null;get fsPath(){return this._fsPath||(this._fsPath=_(this,!1)),this._fsPath}toString(x=!1){return x?v(this,!0):(this._formatted||(this._formatted=v(this,!1)),this._formatted)}toJSON(){let x={$mid:1};return this._fsPath&&(x.fsPath=this._fsPath,x._sep=D),this._formatted&&(x.external=this._formatted),this.path&&(x.path=this.path),this.scheme&&(x.scheme=this.scheme),this.authority&&(x.authority=this.authority),this.query&&(x.query=this.query),this.fragment&&(x.fragment=this.fragment),x}}let q={58:"%3A",47:"%2F",63:"%3F",35:"%23",91:"%5B",93:"%5D",64:"%40",33:"%21",36:"%24",38:"%26",39:"%27",40:"%28",41:"%29",42:"%2A",43:"%2B",44:"%2C",59:"%3B",61:"%3D",32:"%20"};function B(j,x,H){let I,ie=-1;for(let X=0;X<j.length;X++){let K=j.charCodeAt(X);if(K>=97&&K<=122||K>=65&&K<=90||K>=48&&K<=57||K===45||K===46||K===95||K===126||x&&K===47||H&&K===91||H&&K===93||H&&K===58)ie!==-1&&(I+=encodeURIComponent(j.substring(ie,X)),ie=-1),I!==void 0&&(I+=j.charAt(X));else{I===void 0&&(I=j.substr(0,X));let Ve=q[K];Ve!==void 0?(ie!==-1&&(I+=encodeURIComponent(j.substring(ie,X)),ie=-1),I+=Ve):ie===-1&&(ie=X)}}return ie!==-1&&(I+=encodeURIComponent(j.substring(ie))),I!==void 0?I:j}function L(j){let x;for(let H=0;H<j.length;H++){let I=j.charCodeAt(H);I===35||I===63?(x===void 0&&(x=j.substr(0,H)),x+=q[I]):x!==void 0&&(x+=j[H])}return x!==void 0?x:j}function _(j,x){let H;return H=j.authority&&j.path.length>1&&j.scheme==="file"?`//${j.authority}${j.path}`:j.path.charCodeAt(0)===47&&(j.path.charCodeAt(1)>=65&&j.path.charCodeAt(1)<=90||j.path.charCodeAt(1)>=97&&j.path.charCodeAt(1)<=122)&&j.path.charCodeAt(2)===58?x?j.path.substr(1):j.path[1].toLowerCase()+j.path.substr(2):j.path,i&&(H=H.replace(/\//g,"\\")),H}function v(j,x){let H=x?L:B,I="",{scheme:ie,authority:X,path:K,query:Ve,fragment:Ae}=j;if(ie&&(I+=ie,I+=":"),(X||ie==="file")&&(I+=g,I+=g),X){let ce=X.indexOf("@");if(ce!==-1){let St=X.substr(0,ce);X=X.substr(ce+1),ce=St.lastIndexOf(":"),ce===-1?I+=H(St,!1,!1):(I+=H(St.substr(0,ce),!1,!1),I+=":",I+=H(St.substr(ce+1),!1,!0)),I+="@"}X=X.toLowerCase(),ce=X.lastIndexOf(":"),ce===-1?I+=H(X,!1,!0):(I+=H(X.substr(0,ce),!1,!0),I+=X.substr(ce))}if(K){if(K.length>=3&&K.charCodeAt(0)===47&&K.charCodeAt(2)===58){let ce=K.charCodeAt(1);ce>=65&&ce<=90&&(K=`/${String.fromCharCode(ce+32)}:${K.substr(3)}`)}else if(K.length>=2&&K.charCodeAt(1)===58){let ce=K.charCodeAt(0);ce>=65&&ce<=90&&(K=`${String.fromCharCode(ce+32)}:${K.substr(2)}`)}I+=H(K,!0,!1)}return Ve&&(I+="?",I+=H(Ve,!1,!1)),Ae&&(I+="#",I+=x?Ae:B(Ae,!1,!1)),I}function N(j){try{return decodeURIComponent(j)}catch{return j.length>3?j.substr(0,3)+N(j.substr(3)):j}}let z=/(%[0-9A-Za-z][0-9A-Za-z])+/g;function Z(j){return j.match(z)?j.replace(z,x=>N(x)):j}var ue=n(470);let ze=ue.posix||ue,dt="/";var ft;(function(j){j.joinPath=function(x,...H){return x.with({path:ze.join(x.path,...H)})},j.resolvePath=function(x,...H){let I=x.path,ie=!1;I[0]!==dt&&(I=dt+I,ie=!0);let X=ze.resolve(I,...H);return ie&&X[0]===dt&&!x.authority&&(X=X.substring(1)),x.with({path:X})},j.dirname=function(x){if(x.path.length===0||x.path===dt)return x;let H=ze.dirname(x.path);return H.length===1&&H.charCodeAt(0)===46&&(H=""),x.with({path:H})},j.basename=function(x){return ze.basename(x.path)},j.extname=function(x){return ze.extname(x.path)}})(ft||(ft={}))})(),nu=r})();var{URI:Nn,Utils:ye}=nu;import{CONFIG_FILE_NAMES as Fp}from"@redocly/openapi-core";var os={languageId:"yaml",filePattern:/\.ya?ml$/i},ss={languageId:"json",filePattern:/\.json$/i},is=class{constructor(){this.supportedLanguages=[os,ss];this.registerConfigFinder(async t=>{if(!this._fs)return;let n=[];for(let r of Fp)try{let i=ye.resolvePath(ye.dirname(Oe(t)),r);await this._fs.exists(i)&&n.push(i.toString())}catch{continue}if(n.length>1)throw new Error(`
67
+ `&&a++}f&&y.length>0&&h.push(y.length),this._lineOffsets=h}return this._lineOffsets},l.prototype.positionAt=function(h){h=Math.max(Math.min(h,this._content.length),0);var y=this.getLineOffsets(),f=0,a=y.length;if(a===0)return s.create(0,h);for(;f<a;){var P=Math.floor((f+a)/2);y[P]>h?a=P:f=P+1}var k=f-1;return s.create(k,h-y[k])},l.prototype.offsetAt=function(h){var y=this.getLineOffsets();if(h.line>=y.length)return this._content.length;if(h.line<0)return 0;var f=y[h.line],a=h.line+1<y.length?y[h.line+1]:this._content.length;return Math.max(Math.min(f+h.character,a),f)},Object.defineProperty(l.prototype,"lineCount",{get:function(){return this.getLineOffsets().length},enumerable:!1,configurable:!0}),l}(),C;(function(l){var h=Object.prototype.toString;function y(te){return typeof te<"u"}l.defined=y;function f(te){return typeof te>"u"}l.undefined=f;function a(te){return te===!0||te===!1}l.boolean=a;function P(te){return h.call(te)==="[object String]"}l.string=P;function k(te){return h.call(te)==="[object Number]"}l.number=k;function J(te,Nn,ei){return h.call(te)==="[object Number]"&&Nn<=te&&te<=ei}l.numberRange=J;function _e(te){return h.call(te)==="[object Number]"&&-2147483648<=te&&te<=2147483647}l.integer=_e;function fe(te){return h.call(te)==="[object Number]"&&0<=te&&te<=2147483647}l.uinteger=fe;function pt(te){return h.call(te)==="[object Function]"}l.func=pt;function gt(te){return te!==null&&typeof te=="object"}l.objectLiteral=gt;function It(te,Nn){return Array.isArray(te)&&te.every(Nn)}l.typedArray=It})(C||(C={}))})});var Ce=A(Ge=>{"use strict";Object.defineProperty(Ge,"__esModule",{value:!0});Ge.ProtocolNotificationType=Ge.ProtocolNotificationType0=Ge.ProtocolRequestType=Ge.ProtocolRequestType0=Ge.RegistrationType=Ge.MessageDirection=void 0;var er=Tn(),Nb;(function(e){e.clientToServer="clientToServer",e.serverToClient="serverToClient",e.both="both"})(Nb=Ge.MessageDirection||(Ge.MessageDirection={}));var pc=class{constructor(t){this.method=t}};Ge.RegistrationType=pc;var gc=class extends er.RequestType0{constructor(t){super(t)}};Ge.ProtocolRequestType0=gc;var mc=class extends er.RequestType{constructor(t){super(t,er.ParameterStructures.byName)}};Ge.ProtocolRequestType=mc;var hc=class extends er.NotificationType0{constructor(t){super(t)}};Ge.ProtocolNotificationType0=hc;var yc=class extends er.NotificationType{constructor(t){super(t,er.ParameterStructures.byName)}};Ge.ProtocolNotificationType=yc});var eo=A(xe=>{"use strict";Object.defineProperty(xe,"__esModule",{value:!0});xe.objectLiteral=xe.typedArray=xe.stringArray=xe.array=xe.func=xe.error=xe.number=xe.string=xe.boolean=void 0;function Ob(e){return e===!0||e===!1}xe.boolean=Ob;function wd(e){return typeof e=="string"||e instanceof String}xe.string=wd;function Eb(e){return typeof e=="number"||e instanceof Number}xe.number=Eb;function Mb(e){return e instanceof Error}xe.error=Mb;function jb(e){return typeof e=="function"}xe.func=jb;function kd(e){return Array.isArray(e)}xe.array=kd;function Lb(e){return kd(e)&&e.every(t=>wd(t))}xe.stringArray=Lb;function Ib(e,t){return Array.isArray(e)&&e.every(t)}xe.typedArray=Ib;function Fb(e){return e!==null&&typeof e=="object"}xe.objectLiteral=Fb});var qd=A(kr=>{"use strict";Object.defineProperty(kr,"__esModule",{value:!0});kr.ImplementationRequest=void 0;var Ad=Ce(),Wb;(function(e){e.method="textDocument/implementation",e.messageDirection=Ad.MessageDirection.clientToServer,e.type=new Ad.ProtocolRequestType(e.method)})(Wb=kr.ImplementationRequest||(kr.ImplementationRequest={}))});var Od=A(Ar=>{"use strict";Object.defineProperty(Ar,"__esModule",{value:!0});Ar.TypeDefinitionRequest=void 0;var Nd=Ce(),Hb;(function(e){e.method="textDocument/typeDefinition",e.messageDirection=Nd.MessageDirection.clientToServer,e.type=new Nd.ProtocolRequestType(e.method)})(Hb=Ar.TypeDefinitionRequest||(Ar.TypeDefinitionRequest={}))});var Ed=A(nn=>{"use strict";Object.defineProperty(nn,"__esModule",{value:!0});nn.DidChangeWorkspaceFoldersNotification=nn.WorkspaceFoldersRequest=void 0;var to=Ce(),Ub;(function(e){e.method="workspace/workspaceFolders",e.messageDirection=to.MessageDirection.serverToClient,e.type=new to.ProtocolRequestType0(e.method)})(Ub=nn.WorkspaceFoldersRequest||(nn.WorkspaceFoldersRequest={}));var Bb;(function(e){e.method="workspace/didChangeWorkspaceFolders",e.messageDirection=to.MessageDirection.clientToServer,e.type=new to.ProtocolNotificationType(e.method)})(Bb=nn.DidChangeWorkspaceFoldersNotification||(nn.DidChangeWorkspaceFoldersNotification={}))});var jd=A(qr=>{"use strict";Object.defineProperty(qr,"__esModule",{value:!0});qr.ConfigurationRequest=void 0;var Md=Ce(),zb;(function(e){e.method="workspace/configuration",e.messageDirection=Md.MessageDirection.serverToClient,e.type=new Md.ProtocolRequestType(e.method)})(zb=qr.ConfigurationRequest||(qr.ConfigurationRequest={}))});var Ld=A(rn=>{"use strict";Object.defineProperty(rn,"__esModule",{value:!0});rn.ColorPresentationRequest=rn.DocumentColorRequest=void 0;var no=Ce(),$b;(function(e){e.method="textDocument/documentColor",e.messageDirection=no.MessageDirection.clientToServer,e.type=new no.ProtocolRequestType(e.method)})($b=rn.DocumentColorRequest||(rn.DocumentColorRequest={}));var Yb;(function(e){e.method="textDocument/colorPresentation",e.messageDirection=no.MessageDirection.clientToServer,e.type=new no.ProtocolRequestType(e.method)})(Yb=rn.ColorPresentationRequest||(rn.ColorPresentationRequest={}))});var Fd=A(Nr=>{"use strict";Object.defineProperty(Nr,"__esModule",{value:!0});Nr.FoldingRangeRequest=void 0;var Id=Ce(),Vb;(function(e){e.method="textDocument/foldingRange",e.messageDirection=Id.MessageDirection.clientToServer,e.type=new Id.ProtocolRequestType(e.method)})(Vb=Nr.FoldingRangeRequest||(Nr.FoldingRangeRequest={}))});var Hd=A(Or=>{"use strict";Object.defineProperty(Or,"__esModule",{value:!0});Or.DeclarationRequest=void 0;var Wd=Ce(),Kb;(function(e){e.method="textDocument/declaration",e.messageDirection=Wd.MessageDirection.clientToServer,e.type=new Wd.ProtocolRequestType(e.method)})(Kb=Or.DeclarationRequest||(Or.DeclarationRequest={}))});var Bd=A(Er=>{"use strict";Object.defineProperty(Er,"__esModule",{value:!0});Er.SelectionRangeRequest=void 0;var Ud=Ce(),Gb;(function(e){e.method="textDocument/selectionRange",e.messageDirection=Ud.MessageDirection.clientToServer,e.type=new Ud.ProtocolRequestType(e.method)})(Gb=Er.SelectionRangeRequest||(Er.SelectionRangeRequest={}))});var zd=A(bt=>{"use strict";Object.defineProperty(bt,"__esModule",{value:!0});bt.WorkDoneProgressCancelNotification=bt.WorkDoneProgressCreateRequest=bt.WorkDoneProgress=void 0;var Jb=Tn(),ro=Ce(),Qb;(function(e){e.type=new Jb.ProgressType;function t(n){return n===e.type}e.is=t})(Qb=bt.WorkDoneProgress||(bt.WorkDoneProgress={}));var Xb;(function(e){e.method="window/workDoneProgress/create",e.messageDirection=ro.MessageDirection.serverToClient,e.type=new ro.ProtocolRequestType(e.method)})(Xb=bt.WorkDoneProgressCreateRequest||(bt.WorkDoneProgressCreateRequest={}));var Zb;(function(e){e.method="window/workDoneProgress/cancel",e.messageDirection=ro.MessageDirection.clientToServer,e.type=new ro.ProtocolNotificationType(e.method)})(Zb=bt.WorkDoneProgressCancelNotification||(bt.WorkDoneProgressCancelNotification={}))});var $d=A(vt=>{"use strict";Object.defineProperty(vt,"__esModule",{value:!0});vt.CallHierarchyOutgoingCallsRequest=vt.CallHierarchyIncomingCallsRequest=vt.CallHierarchyPrepareRequest=void 0;var tr=Ce(),ev;(function(e){e.method="textDocument/prepareCallHierarchy",e.messageDirection=tr.MessageDirection.clientToServer,e.type=new tr.ProtocolRequestType(e.method)})(ev=vt.CallHierarchyPrepareRequest||(vt.CallHierarchyPrepareRequest={}));var tv;(function(e){e.method="callHierarchy/incomingCalls",e.messageDirection=tr.MessageDirection.clientToServer,e.type=new tr.ProtocolRequestType(e.method)})(tv=vt.CallHierarchyIncomingCallsRequest||(vt.CallHierarchyIncomingCallsRequest={}));var nv;(function(e){e.method="callHierarchy/outgoingCalls",e.messageDirection=tr.MessageDirection.clientToServer,e.type=new tr.ProtocolRequestType(e.method)})(nv=vt.CallHierarchyOutgoingCallsRequest||(vt.CallHierarchyOutgoingCallsRequest={}))});var Yd=A(we=>{"use strict";Object.defineProperty(we,"__esModule",{value:!0});we.SemanticTokensRefreshRequest=we.SemanticTokensRangeRequest=we.SemanticTokensDeltaRequest=we.SemanticTokensRequest=we.SemanticTokensRegistrationType=we.TokenFormat=void 0;var Yt=Ce(),rv;(function(e){e.Relative="relative"})(rv=we.TokenFormat||(we.TokenFormat={}));var io;(function(e){e.method="textDocument/semanticTokens",e.type=new Yt.RegistrationType(e.method)})(io=we.SemanticTokensRegistrationType||(we.SemanticTokensRegistrationType={}));var iv;(function(e){e.method="textDocument/semanticTokens/full",e.messageDirection=Yt.MessageDirection.clientToServer,e.type=new Yt.ProtocolRequestType(e.method),e.registrationMethod=io.method})(iv=we.SemanticTokensRequest||(we.SemanticTokensRequest={}));var ov;(function(e){e.method="textDocument/semanticTokens/full/delta",e.messageDirection=Yt.MessageDirection.clientToServer,e.type=new Yt.ProtocolRequestType(e.method),e.registrationMethod=io.method})(ov=we.SemanticTokensDeltaRequest||(we.SemanticTokensDeltaRequest={}));var sv;(function(e){e.method="textDocument/semanticTokens/range",e.messageDirection=Yt.MessageDirection.clientToServer,e.type=new Yt.ProtocolRequestType(e.method),e.registrationMethod=io.method})(sv=we.SemanticTokensRangeRequest||(we.SemanticTokensRangeRequest={}));var av;(function(e){e.method="workspace/semanticTokens/refresh",e.messageDirection=Yt.MessageDirection.serverToClient,e.type=new Yt.ProtocolRequestType0(e.method)})(av=we.SemanticTokensRefreshRequest||(we.SemanticTokensRefreshRequest={}))});var Kd=A(Mr=>{"use strict";Object.defineProperty(Mr,"__esModule",{value:!0});Mr.ShowDocumentRequest=void 0;var Vd=Ce(),cv;(function(e){e.method="window/showDocument",e.messageDirection=Vd.MessageDirection.serverToClient,e.type=new Vd.ProtocolRequestType(e.method)})(cv=Mr.ShowDocumentRequest||(Mr.ShowDocumentRequest={}))});var Jd=A(jr=>{"use strict";Object.defineProperty(jr,"__esModule",{value:!0});jr.LinkedEditingRangeRequest=void 0;var Gd=Ce(),uv;(function(e){e.method="textDocument/linkedEditingRange",e.messageDirection=Gd.MessageDirection.clientToServer,e.type=new Gd.ProtocolRequestType(e.method)})(uv=jr.LinkedEditingRangeRequest||(jr.LinkedEditingRangeRequest={}))});var Qd=A(Pe=>{"use strict";Object.defineProperty(Pe,"__esModule",{value:!0});Pe.WillDeleteFilesRequest=Pe.DidDeleteFilesNotification=Pe.DidRenameFilesNotification=Pe.WillRenameFilesRequest=Pe.DidCreateFilesNotification=Pe.WillCreateFilesRequest=Pe.FileOperationPatternKind=void 0;var at=Ce(),lv;(function(e){e.file="file",e.folder="folder"})(lv=Pe.FileOperationPatternKind||(Pe.FileOperationPatternKind={}));var dv;(function(e){e.method="workspace/willCreateFiles",e.messageDirection=at.MessageDirection.clientToServer,e.type=new at.ProtocolRequestType(e.method)})(dv=Pe.WillCreateFilesRequest||(Pe.WillCreateFilesRequest={}));var fv;(function(e){e.method="workspace/didCreateFiles",e.messageDirection=at.MessageDirection.clientToServer,e.type=new at.ProtocolNotificationType(e.method)})(fv=Pe.DidCreateFilesNotification||(Pe.DidCreateFilesNotification={}));var pv;(function(e){e.method="workspace/willRenameFiles",e.messageDirection=at.MessageDirection.clientToServer,e.type=new at.ProtocolRequestType(e.method)})(pv=Pe.WillRenameFilesRequest||(Pe.WillRenameFilesRequest={}));var gv;(function(e){e.method="workspace/didRenameFiles",e.messageDirection=at.MessageDirection.clientToServer,e.type=new at.ProtocolNotificationType(e.method)})(gv=Pe.DidRenameFilesNotification||(Pe.DidRenameFilesNotification={}));var mv;(function(e){e.method="workspace/didDeleteFiles",e.messageDirection=at.MessageDirection.clientToServer,e.type=new at.ProtocolNotificationType(e.method)})(mv=Pe.DidDeleteFilesNotification||(Pe.DidDeleteFilesNotification={}));var hv;(function(e){e.method="workspace/willDeleteFiles",e.messageDirection=at.MessageDirection.clientToServer,e.type=new at.ProtocolRequestType(e.method)})(hv=Pe.WillDeleteFilesRequest||(Pe.WillDeleteFilesRequest={}))});var Zd=A(Ct=>{"use strict";Object.defineProperty(Ct,"__esModule",{value:!0});Ct.MonikerRequest=Ct.MonikerKind=Ct.UniquenessLevel=void 0;var Xd=Ce(),yv;(function(e){e.document="document",e.project="project",e.group="group",e.scheme="scheme",e.global="global"})(yv=Ct.UniquenessLevel||(Ct.UniquenessLevel={}));var bv;(function(e){e.$import="import",e.$export="export",e.local="local"})(bv=Ct.MonikerKind||(Ct.MonikerKind={}));var vv;(function(e){e.method="textDocument/moniker",e.messageDirection=Xd.MessageDirection.clientToServer,e.type=new Xd.ProtocolRequestType(e.method)})(vv=Ct.MonikerRequest||(Ct.MonikerRequest={}))});var ef=A(Pt=>{"use strict";Object.defineProperty(Pt,"__esModule",{value:!0});Pt.TypeHierarchySubtypesRequest=Pt.TypeHierarchySupertypesRequest=Pt.TypeHierarchyPrepareRequest=void 0;var nr=Ce(),Cv;(function(e){e.method="textDocument/prepareTypeHierarchy",e.messageDirection=nr.MessageDirection.clientToServer,e.type=new nr.ProtocolRequestType(e.method)})(Cv=Pt.TypeHierarchyPrepareRequest||(Pt.TypeHierarchyPrepareRequest={}));var Pv;(function(e){e.method="typeHierarchy/supertypes",e.messageDirection=nr.MessageDirection.clientToServer,e.type=new nr.ProtocolRequestType(e.method)})(Pv=Pt.TypeHierarchySupertypesRequest||(Pt.TypeHierarchySupertypesRequest={}));var _v;(function(e){e.method="typeHierarchy/subtypes",e.messageDirection=nr.MessageDirection.clientToServer,e.type=new nr.ProtocolRequestType(e.method)})(_v=Pt.TypeHierarchySubtypesRequest||(Pt.TypeHierarchySubtypesRequest={}))});var tf=A(on=>{"use strict";Object.defineProperty(on,"__esModule",{value:!0});on.InlineValueRefreshRequest=on.InlineValueRequest=void 0;var oo=Ce(),Rv;(function(e){e.method="textDocument/inlineValue",e.messageDirection=oo.MessageDirection.clientToServer,e.type=new oo.ProtocolRequestType(e.method)})(Rv=on.InlineValueRequest||(on.InlineValueRequest={}));var Dv;(function(e){e.method="workspace/inlineValue/refresh",e.messageDirection=oo.MessageDirection.serverToClient,e.type=new oo.ProtocolRequestType0(e.method)})(Dv=on.InlineValueRefreshRequest||(on.InlineValueRefreshRequest={}))});var nf=A(_t=>{"use strict";Object.defineProperty(_t,"__esModule",{value:!0});_t.InlayHintRefreshRequest=_t.InlayHintResolveRequest=_t.InlayHintRequest=void 0;var rr=Ce(),Sv;(function(e){e.method="textDocument/inlayHint",e.messageDirection=rr.MessageDirection.clientToServer,e.type=new rr.ProtocolRequestType(e.method)})(Sv=_t.InlayHintRequest||(_t.InlayHintRequest={}));var Tv;(function(e){e.method="inlayHint/resolve",e.messageDirection=rr.MessageDirection.clientToServer,e.type=new rr.ProtocolRequestType(e.method)})(Tv=_t.InlayHintResolveRequest||(_t.InlayHintResolveRequest={}));var xv;(function(e){e.method="workspace/inlayHint/refresh",e.messageDirection=rr.MessageDirection.serverToClient,e.type=new rr.ProtocolRequestType0(e.method)})(xv=_t.InlayHintRefreshRequest||(_t.InlayHintRefreshRequest={}))});var of=A(He=>{"use strict";Object.defineProperty(He,"__esModule",{value:!0});He.DiagnosticRefreshRequest=He.WorkspaceDiagnosticRequest=He.DocumentDiagnosticRequest=He.DocumentDiagnosticReportKind=He.DiagnosticServerCancellationData=void 0;var rf=Tn(),wv=eo(),ir=Ce(),kv;(function(e){function t(n){let r=n;return r&&wv.boolean(r.retriggerRequest)}e.is=t})(kv=He.DiagnosticServerCancellationData||(He.DiagnosticServerCancellationData={}));var Av;(function(e){e.Full="full",e.Unchanged="unchanged"})(Av=He.DocumentDiagnosticReportKind||(He.DocumentDiagnosticReportKind={}));var qv;(function(e){e.method="textDocument/diagnostic",e.messageDirection=ir.MessageDirection.clientToServer,e.type=new ir.ProtocolRequestType(e.method),e.partialResult=new rf.ProgressType})(qv=He.DocumentDiagnosticRequest||(He.DocumentDiagnosticRequest={}));var Nv;(function(e){e.method="workspace/diagnostic",e.messageDirection=ir.MessageDirection.clientToServer,e.type=new ir.ProtocolRequestType(e.method),e.partialResult=new rf.ProgressType})(Nv=He.WorkspaceDiagnosticRequest||(He.WorkspaceDiagnosticRequest={}));var Ov;(function(e){e.method="workspace/diagnostic/refresh",e.messageDirection=ir.MessageDirection.serverToClient,e.type=new ir.ProtocolRequestType0(e.method)})(Ov=He.DiagnosticRefreshRequest||(He.DiagnosticRefreshRequest={}))});var cf=A(re=>{"use strict";Object.defineProperty(re,"__esModule",{value:!0});re.DidCloseNotebookDocumentNotification=re.DidSaveNotebookDocumentNotification=re.DidChangeNotebookDocumentNotification=re.NotebookCellArrayChange=re.DidOpenNotebookDocumentNotification=re.NotebookDocumentSyncRegistrationType=re.NotebookDocument=re.NotebookCell=re.ExecutionSummary=re.NotebookCellKind=void 0;var Lr=Zi(),Rt=eo(),qt=Ce(),sf;(function(e){e.Markup=1,e.Code=2;function t(n){return n===1||n===2}e.is=t})(sf=re.NotebookCellKind||(re.NotebookCellKind={}));var af;(function(e){function t(i,o){let s={executionOrder:i};return(o===!0||o===!1)&&(s.success=o),s}e.create=t;function n(i){let o=i;return Rt.objectLiteral(o)&&Lr.uinteger.is(o.executionOrder)&&(o.success===void 0||Rt.boolean(o.success))}e.is=n;function r(i,o){return i===o?!0:i==null||o===null||o===void 0?!1:i.executionOrder===o.executionOrder&&i.success===o.success}e.equals=r})(af=re.ExecutionSummary||(re.ExecutionSummary={}));var bc;(function(e){function t(o,s){return{kind:o,document:s}}e.create=t;function n(o){let s=o;return Rt.objectLiteral(s)&&sf.is(s.kind)&&Lr.DocumentUri.is(s.document)&&(s.metadata===void 0||Rt.objectLiteral(s.metadata))}e.is=n;function r(o,s){let u=new Set;return o.document!==s.document&&u.add("document"),o.kind!==s.kind&&u.add("kind"),o.executionSummary!==s.executionSummary&&u.add("executionSummary"),(o.metadata!==void 0||s.metadata!==void 0)&&!i(o.metadata,s.metadata)&&u.add("metadata"),(o.executionSummary!==void 0||s.executionSummary!==void 0)&&!af.equals(o.executionSummary,s.executionSummary)&&u.add("executionSummary"),u}e.diff=r;function i(o,s){if(o===s)return!0;if(o==null||s===null||s===void 0||typeof o!=typeof s||typeof o!="object")return!1;let u=Array.isArray(o),c=Array.isArray(s);if(u!==c)return!1;if(u&&c){if(o.length!==s.length)return!1;for(let p=0;p<o.length;p++)if(!i(o[p],s[p]))return!1}if(Rt.objectLiteral(o)&&Rt.objectLiteral(s)){let p=Object.keys(o),g=Object.keys(s);if(p.length!==g.length||(p.sort(),g.sort(),!i(p,g)))return!1;for(let b=0;b<p.length;b++){let R=p[b];if(!i(o[R],s[R]))return!1}}return!0}})(bc=re.NotebookCell||(re.NotebookCell={}));var Ev;(function(e){function t(r,i,o,s){return{uri:r,notebookType:i,version:o,cells:s}}e.create=t;function n(r){let i=r;return Rt.objectLiteral(i)&&Rt.string(i.uri)&&Lr.integer.is(i.version)&&Rt.typedArray(i.cells,bc.is)}e.is=n})(Ev=re.NotebookDocument||(re.NotebookDocument={}));var Ir;(function(e){e.method="notebookDocument/sync",e.messageDirection=qt.MessageDirection.clientToServer,e.type=new qt.RegistrationType(e.method)})(Ir=re.NotebookDocumentSyncRegistrationType||(re.NotebookDocumentSyncRegistrationType={}));var Mv;(function(e){e.method="notebookDocument/didOpen",e.messageDirection=qt.MessageDirection.clientToServer,e.type=new qt.ProtocolNotificationType(e.method),e.registrationMethod=Ir.method})(Mv=re.DidOpenNotebookDocumentNotification||(re.DidOpenNotebookDocumentNotification={}));var jv;(function(e){function t(r){let i=r;return Rt.objectLiteral(i)&&Lr.uinteger.is(i.start)&&Lr.uinteger.is(i.deleteCount)&&(i.cells===void 0||Rt.typedArray(i.cells,bc.is))}e.is=t;function n(r,i,o){let s={start:r,deleteCount:i};return o!==void 0&&(s.cells=o),s}e.create=n})(jv=re.NotebookCellArrayChange||(re.NotebookCellArrayChange={}));var Lv;(function(e){e.method="notebookDocument/didChange",e.messageDirection=qt.MessageDirection.clientToServer,e.type=new qt.ProtocolNotificationType(e.method),e.registrationMethod=Ir.method})(Lv=re.DidChangeNotebookDocumentNotification||(re.DidChangeNotebookDocumentNotification={}));var Iv;(function(e){e.method="notebookDocument/didSave",e.messageDirection=qt.MessageDirection.clientToServer,e.type=new qt.ProtocolNotificationType(e.method),e.registrationMethod=Ir.method})(Iv=re.DidSaveNotebookDocumentNotification||(re.DidSaveNotebookDocumentNotification={}));var Fv;(function(e){e.method="notebookDocument/didClose",e.messageDirection=qt.MessageDirection.clientToServer,e.type=new qt.ProtocolNotificationType(e.method),e.registrationMethod=Ir.method})(Fv=re.DidCloseNotebookDocumentNotification||(re.DidCloseNotebookDocumentNotification={}))});var yf=A(d=>{"use strict";Object.defineProperty(d,"__esModule",{value:!0});d.WorkspaceSymbolRequest=d.CodeActionResolveRequest=d.CodeActionRequest=d.DocumentSymbolRequest=d.DocumentHighlightRequest=d.ReferencesRequest=d.DefinitionRequest=d.SignatureHelpRequest=d.SignatureHelpTriggerKind=d.HoverRequest=d.CompletionResolveRequest=d.CompletionRequest=d.CompletionTriggerKind=d.PublishDiagnosticsNotification=d.WatchKind=d.RelativePattern=d.FileChangeType=d.DidChangeWatchedFilesNotification=d.WillSaveTextDocumentWaitUntilRequest=d.WillSaveTextDocumentNotification=d.TextDocumentSaveReason=d.DidSaveTextDocumentNotification=d.DidCloseTextDocumentNotification=d.DidChangeTextDocumentNotification=d.TextDocumentContentChangeEvent=d.DidOpenTextDocumentNotification=d.TextDocumentSyncKind=d.TelemetryEventNotification=d.LogMessageNotification=d.ShowMessageRequest=d.ShowMessageNotification=d.MessageType=d.DidChangeConfigurationNotification=d.ExitNotification=d.ShutdownRequest=d.InitializedNotification=d.InitializeErrorCodes=d.InitializeRequest=d.WorkDoneProgressOptions=d.TextDocumentRegistrationOptions=d.StaticRegistrationOptions=d.PositionEncodingKind=d.FailureHandlingKind=d.ResourceOperationKind=d.UnregistrationRequest=d.RegistrationRequest=d.DocumentSelector=d.NotebookCellTextDocumentFilter=d.NotebookDocumentFilter=d.TextDocumentFilter=void 0;d.TypeHierarchySubtypesRequest=d.TypeHierarchyPrepareRequest=d.MonikerRequest=d.MonikerKind=d.UniquenessLevel=d.WillDeleteFilesRequest=d.DidDeleteFilesNotification=d.WillRenameFilesRequest=d.DidRenameFilesNotification=d.WillCreateFilesRequest=d.DidCreateFilesNotification=d.FileOperationPatternKind=d.LinkedEditingRangeRequest=d.ShowDocumentRequest=d.SemanticTokensRegistrationType=d.SemanticTokensRefreshRequest=d.SemanticTokensRangeRequest=d.SemanticTokensDeltaRequest=d.SemanticTokensRequest=d.TokenFormat=d.CallHierarchyPrepareRequest=d.CallHierarchyOutgoingCallsRequest=d.CallHierarchyIncomingCallsRequest=d.WorkDoneProgressCancelNotification=d.WorkDoneProgressCreateRequest=d.WorkDoneProgress=d.SelectionRangeRequest=d.DeclarationRequest=d.FoldingRangeRequest=d.ColorPresentationRequest=d.DocumentColorRequest=d.ConfigurationRequest=d.DidChangeWorkspaceFoldersNotification=d.WorkspaceFoldersRequest=d.TypeDefinitionRequest=d.ImplementationRequest=d.ApplyWorkspaceEditRequest=d.ExecuteCommandRequest=d.PrepareRenameRequest=d.RenameRequest=d.PrepareSupportDefaultBehavior=d.DocumentOnTypeFormattingRequest=d.DocumentRangeFormattingRequest=d.DocumentFormattingRequest=d.DocumentLinkResolveRequest=d.DocumentLinkRequest=d.CodeLensRefreshRequest=d.CodeLensResolveRequest=d.CodeLensRequest=d.WorkspaceSymbolResolveRequest=void 0;d.DidCloseNotebookDocumentNotification=d.DidSaveNotebookDocumentNotification=d.DidChangeNotebookDocumentNotification=d.NotebookCellArrayChange=d.DidOpenNotebookDocumentNotification=d.NotebookDocumentSyncRegistrationType=d.NotebookDocument=d.NotebookCell=d.ExecutionSummary=d.NotebookCellKind=d.DiagnosticRefreshRequest=d.WorkspaceDiagnosticRequest=d.DocumentDiagnosticRequest=d.DocumentDiagnosticReportKind=d.DiagnosticServerCancellationData=d.InlayHintRefreshRequest=d.InlayHintResolveRequest=d.InlayHintRequest=d.InlineValueRefreshRequest=d.InlineValueRequest=d.TypeHierarchySupertypesRequest=void 0;var O=Ce(),uf=Zi(),Ue=eo(),Wv=qd();Object.defineProperty(d,"ImplementationRequest",{enumerable:!0,get:function(){return Wv.ImplementationRequest}});var Hv=Od();Object.defineProperty(d,"TypeDefinitionRequest",{enumerable:!0,get:function(){return Hv.TypeDefinitionRequest}});var lf=Ed();Object.defineProperty(d,"WorkspaceFoldersRequest",{enumerable:!0,get:function(){return lf.WorkspaceFoldersRequest}});Object.defineProperty(d,"DidChangeWorkspaceFoldersNotification",{enumerable:!0,get:function(){return lf.DidChangeWorkspaceFoldersNotification}});var Uv=jd();Object.defineProperty(d,"ConfigurationRequest",{enumerable:!0,get:function(){return Uv.ConfigurationRequest}});var df=Ld();Object.defineProperty(d,"DocumentColorRequest",{enumerable:!0,get:function(){return df.DocumentColorRequest}});Object.defineProperty(d,"ColorPresentationRequest",{enumerable:!0,get:function(){return df.ColorPresentationRequest}});var Bv=Fd();Object.defineProperty(d,"FoldingRangeRequest",{enumerable:!0,get:function(){return Bv.FoldingRangeRequest}});var zv=Hd();Object.defineProperty(d,"DeclarationRequest",{enumerable:!0,get:function(){return zv.DeclarationRequest}});var $v=Bd();Object.defineProperty(d,"SelectionRangeRequest",{enumerable:!0,get:function(){return $v.SelectionRangeRequest}});var vc=zd();Object.defineProperty(d,"WorkDoneProgress",{enumerable:!0,get:function(){return vc.WorkDoneProgress}});Object.defineProperty(d,"WorkDoneProgressCreateRequest",{enumerable:!0,get:function(){return vc.WorkDoneProgressCreateRequest}});Object.defineProperty(d,"WorkDoneProgressCancelNotification",{enumerable:!0,get:function(){return vc.WorkDoneProgressCancelNotification}});var Cc=$d();Object.defineProperty(d,"CallHierarchyIncomingCallsRequest",{enumerable:!0,get:function(){return Cc.CallHierarchyIncomingCallsRequest}});Object.defineProperty(d,"CallHierarchyOutgoingCallsRequest",{enumerable:!0,get:function(){return Cc.CallHierarchyOutgoingCallsRequest}});Object.defineProperty(d,"CallHierarchyPrepareRequest",{enumerable:!0,get:function(){return Cc.CallHierarchyPrepareRequest}});var or=Yd();Object.defineProperty(d,"TokenFormat",{enumerable:!0,get:function(){return or.TokenFormat}});Object.defineProperty(d,"SemanticTokensRequest",{enumerable:!0,get:function(){return or.SemanticTokensRequest}});Object.defineProperty(d,"SemanticTokensDeltaRequest",{enumerable:!0,get:function(){return or.SemanticTokensDeltaRequest}});Object.defineProperty(d,"SemanticTokensRangeRequest",{enumerable:!0,get:function(){return or.SemanticTokensRangeRequest}});Object.defineProperty(d,"SemanticTokensRefreshRequest",{enumerable:!0,get:function(){return or.SemanticTokensRefreshRequest}});Object.defineProperty(d,"SemanticTokensRegistrationType",{enumerable:!0,get:function(){return or.SemanticTokensRegistrationType}});var Yv=Kd();Object.defineProperty(d,"ShowDocumentRequest",{enumerable:!0,get:function(){return Yv.ShowDocumentRequest}});var Vv=Jd();Object.defineProperty(d,"LinkedEditingRangeRequest",{enumerable:!0,get:function(){return Vv.LinkedEditingRangeRequest}});var xn=Qd();Object.defineProperty(d,"FileOperationPatternKind",{enumerable:!0,get:function(){return xn.FileOperationPatternKind}});Object.defineProperty(d,"DidCreateFilesNotification",{enumerable:!0,get:function(){return xn.DidCreateFilesNotification}});Object.defineProperty(d,"WillCreateFilesRequest",{enumerable:!0,get:function(){return xn.WillCreateFilesRequest}});Object.defineProperty(d,"DidRenameFilesNotification",{enumerable:!0,get:function(){return xn.DidRenameFilesNotification}});Object.defineProperty(d,"WillRenameFilesRequest",{enumerable:!0,get:function(){return xn.WillRenameFilesRequest}});Object.defineProperty(d,"DidDeleteFilesNotification",{enumerable:!0,get:function(){return xn.DidDeleteFilesNotification}});Object.defineProperty(d,"WillDeleteFilesRequest",{enumerable:!0,get:function(){return xn.WillDeleteFilesRequest}});var Pc=Zd();Object.defineProperty(d,"UniquenessLevel",{enumerable:!0,get:function(){return Pc.UniquenessLevel}});Object.defineProperty(d,"MonikerKind",{enumerable:!0,get:function(){return Pc.MonikerKind}});Object.defineProperty(d,"MonikerRequest",{enumerable:!0,get:function(){return Pc.MonikerRequest}});var _c=ef();Object.defineProperty(d,"TypeHierarchyPrepareRequest",{enumerable:!0,get:function(){return _c.TypeHierarchyPrepareRequest}});Object.defineProperty(d,"TypeHierarchySubtypesRequest",{enumerable:!0,get:function(){return _c.TypeHierarchySubtypesRequest}});Object.defineProperty(d,"TypeHierarchySupertypesRequest",{enumerable:!0,get:function(){return _c.TypeHierarchySupertypesRequest}});var ff=tf();Object.defineProperty(d,"InlineValueRequest",{enumerable:!0,get:function(){return ff.InlineValueRequest}});Object.defineProperty(d,"InlineValueRefreshRequest",{enumerable:!0,get:function(){return ff.InlineValueRefreshRequest}});var Rc=nf();Object.defineProperty(d,"InlayHintRequest",{enumerable:!0,get:function(){return Rc.InlayHintRequest}});Object.defineProperty(d,"InlayHintResolveRequest",{enumerable:!0,get:function(){return Rc.InlayHintResolveRequest}});Object.defineProperty(d,"InlayHintRefreshRequest",{enumerable:!0,get:function(){return Rc.InlayHintRefreshRequest}});var Fr=of();Object.defineProperty(d,"DiagnosticServerCancellationData",{enumerable:!0,get:function(){return Fr.DiagnosticServerCancellationData}});Object.defineProperty(d,"DocumentDiagnosticReportKind",{enumerable:!0,get:function(){return Fr.DocumentDiagnosticReportKind}});Object.defineProperty(d,"DocumentDiagnosticRequest",{enumerable:!0,get:function(){return Fr.DocumentDiagnosticRequest}});Object.defineProperty(d,"WorkspaceDiagnosticRequest",{enumerable:!0,get:function(){return Fr.WorkspaceDiagnosticRequest}});Object.defineProperty(d,"DiagnosticRefreshRequest",{enumerable:!0,get:function(){return Fr.DiagnosticRefreshRequest}});var Nt=cf();Object.defineProperty(d,"NotebookCellKind",{enumerable:!0,get:function(){return Nt.NotebookCellKind}});Object.defineProperty(d,"ExecutionSummary",{enumerable:!0,get:function(){return Nt.ExecutionSummary}});Object.defineProperty(d,"NotebookCell",{enumerable:!0,get:function(){return Nt.NotebookCell}});Object.defineProperty(d,"NotebookDocument",{enumerable:!0,get:function(){return Nt.NotebookDocument}});Object.defineProperty(d,"NotebookDocumentSyncRegistrationType",{enumerable:!0,get:function(){return Nt.NotebookDocumentSyncRegistrationType}});Object.defineProperty(d,"DidOpenNotebookDocumentNotification",{enumerable:!0,get:function(){return Nt.DidOpenNotebookDocumentNotification}});Object.defineProperty(d,"NotebookCellArrayChange",{enumerable:!0,get:function(){return Nt.NotebookCellArrayChange}});Object.defineProperty(d,"DidChangeNotebookDocumentNotification",{enumerable:!0,get:function(){return Nt.DidChangeNotebookDocumentNotification}});Object.defineProperty(d,"DidSaveNotebookDocumentNotification",{enumerable:!0,get:function(){return Nt.DidSaveNotebookDocumentNotification}});Object.defineProperty(d,"DidCloseNotebookDocumentNotification",{enumerable:!0,get:function(){return Nt.DidCloseNotebookDocumentNotification}});var pf;(function(e){function t(n){let r=n;return Ue.string(r.language)||Ue.string(r.scheme)||Ue.string(r.pattern)}e.is=t})(pf=d.TextDocumentFilter||(d.TextDocumentFilter={}));var gf;(function(e){function t(n){let r=n;return Ue.objectLiteral(r)&&(Ue.string(r.notebookType)||Ue.string(r.scheme)||Ue.string(r.pattern))}e.is=t})(gf=d.NotebookDocumentFilter||(d.NotebookDocumentFilter={}));var mf;(function(e){function t(n){let r=n;return Ue.objectLiteral(r)&&(Ue.string(r.notebook)||gf.is(r.notebook))&&(r.language===void 0||Ue.string(r.language))}e.is=t})(mf=d.NotebookCellTextDocumentFilter||(d.NotebookCellTextDocumentFilter={}));var hf;(function(e){function t(n){if(!Array.isArray(n))return!1;for(let r of n)if(!Ue.string(r)&&!pf.is(r)&&!mf.is(r))return!1;return!0}e.is=t})(hf=d.DocumentSelector||(d.DocumentSelector={}));var Kv;(function(e){e.method="client/registerCapability",e.messageDirection=O.MessageDirection.serverToClient,e.type=new O.ProtocolRequestType(e.method)})(Kv=d.RegistrationRequest||(d.RegistrationRequest={}));var Gv;(function(e){e.method="client/unregisterCapability",e.messageDirection=O.MessageDirection.serverToClient,e.type=new O.ProtocolRequestType(e.method)})(Gv=d.UnregistrationRequest||(d.UnregistrationRequest={}));var Jv;(function(e){e.Create="create",e.Rename="rename",e.Delete="delete"})(Jv=d.ResourceOperationKind||(d.ResourceOperationKind={}));var Qv;(function(e){e.Abort="abort",e.Transactional="transactional",e.TextOnlyTransactional="textOnlyTransactional",e.Undo="undo"})(Qv=d.FailureHandlingKind||(d.FailureHandlingKind={}));var Xv;(function(e){e.UTF8="utf-8",e.UTF16="utf-16",e.UTF32="utf-32"})(Xv=d.PositionEncodingKind||(d.PositionEncodingKind={}));var Zv;(function(e){function t(n){let r=n;return r&&Ue.string(r.id)&&r.id.length>0}e.hasId=t})(Zv=d.StaticRegistrationOptions||(d.StaticRegistrationOptions={}));var eC;(function(e){function t(n){let r=n;return r&&(r.documentSelector===null||hf.is(r.documentSelector))}e.is=t})(eC=d.TextDocumentRegistrationOptions||(d.TextDocumentRegistrationOptions={}));var tC;(function(e){function t(r){let i=r;return Ue.objectLiteral(i)&&(i.workDoneProgress===void 0||Ue.boolean(i.workDoneProgress))}e.is=t;function n(r){let i=r;return i&&Ue.boolean(i.workDoneProgress)}e.hasWorkDoneProgress=n})(tC=d.WorkDoneProgressOptions||(d.WorkDoneProgressOptions={}));var nC;(function(e){e.method="initialize",e.messageDirection=O.MessageDirection.clientToServer,e.type=new O.ProtocolRequestType(e.method)})(nC=d.InitializeRequest||(d.InitializeRequest={}));var rC;(function(e){e.unknownProtocolVersion=1})(rC=d.InitializeErrorCodes||(d.InitializeErrorCodes={}));var iC;(function(e){e.method="initialized",e.messageDirection=O.MessageDirection.clientToServer,e.type=new O.ProtocolNotificationType(e.method)})(iC=d.InitializedNotification||(d.InitializedNotification={}));var oC;(function(e){e.method="shutdown",e.messageDirection=O.MessageDirection.clientToServer,e.type=new O.ProtocolRequestType0(e.method)})(oC=d.ShutdownRequest||(d.ShutdownRequest={}));var sC;(function(e){e.method="exit",e.messageDirection=O.MessageDirection.clientToServer,e.type=new O.ProtocolNotificationType0(e.method)})(sC=d.ExitNotification||(d.ExitNotification={}));var aC;(function(e){e.method="workspace/didChangeConfiguration",e.messageDirection=O.MessageDirection.clientToServer,e.type=new O.ProtocolNotificationType(e.method)})(aC=d.DidChangeConfigurationNotification||(d.DidChangeConfigurationNotification={}));var cC;(function(e){e.Error=1,e.Warning=2,e.Info=3,e.Log=4})(cC=d.MessageType||(d.MessageType={}));var uC;(function(e){e.method="window/showMessage",e.messageDirection=O.MessageDirection.serverToClient,e.type=new O.ProtocolNotificationType(e.method)})(uC=d.ShowMessageNotification||(d.ShowMessageNotification={}));var lC;(function(e){e.method="window/showMessageRequest",e.messageDirection=O.MessageDirection.serverToClient,e.type=new O.ProtocolRequestType(e.method)})(lC=d.ShowMessageRequest||(d.ShowMessageRequest={}));var dC;(function(e){e.method="window/logMessage",e.messageDirection=O.MessageDirection.serverToClient,e.type=new O.ProtocolNotificationType(e.method)})(dC=d.LogMessageNotification||(d.LogMessageNotification={}));var fC;(function(e){e.method="telemetry/event",e.messageDirection=O.MessageDirection.serverToClient,e.type=new O.ProtocolNotificationType(e.method)})(fC=d.TelemetryEventNotification||(d.TelemetryEventNotification={}));var pC;(function(e){e.None=0,e.Full=1,e.Incremental=2})(pC=d.TextDocumentSyncKind||(d.TextDocumentSyncKind={}));var gC;(function(e){e.method="textDocument/didOpen",e.messageDirection=O.MessageDirection.clientToServer,e.type=new O.ProtocolNotificationType(e.method)})(gC=d.DidOpenTextDocumentNotification||(d.DidOpenTextDocumentNotification={}));var mC;(function(e){function t(r){let i=r;return i!=null&&typeof i.text=="string"&&i.range!==void 0&&(i.rangeLength===void 0||typeof i.rangeLength=="number")}e.isIncremental=t;function n(r){let i=r;return i!=null&&typeof i.text=="string"&&i.range===void 0&&i.rangeLength===void 0}e.isFull=n})(mC=d.TextDocumentContentChangeEvent||(d.TextDocumentContentChangeEvent={}));var hC;(function(e){e.method="textDocument/didChange",e.messageDirection=O.MessageDirection.clientToServer,e.type=new O.ProtocolNotificationType(e.method)})(hC=d.DidChangeTextDocumentNotification||(d.DidChangeTextDocumentNotification={}));var yC;(function(e){e.method="textDocument/didClose",e.messageDirection=O.MessageDirection.clientToServer,e.type=new O.ProtocolNotificationType(e.method)})(yC=d.DidCloseTextDocumentNotification||(d.DidCloseTextDocumentNotification={}));var bC;(function(e){e.method="textDocument/didSave",e.messageDirection=O.MessageDirection.clientToServer,e.type=new O.ProtocolNotificationType(e.method)})(bC=d.DidSaveTextDocumentNotification||(d.DidSaveTextDocumentNotification={}));var vC;(function(e){e.Manual=1,e.AfterDelay=2,e.FocusOut=3})(vC=d.TextDocumentSaveReason||(d.TextDocumentSaveReason={}));var CC;(function(e){e.method="textDocument/willSave",e.messageDirection=O.MessageDirection.clientToServer,e.type=new O.ProtocolNotificationType(e.method)})(CC=d.WillSaveTextDocumentNotification||(d.WillSaveTextDocumentNotification={}));var PC;(function(e){e.method="textDocument/willSaveWaitUntil",e.messageDirection=O.MessageDirection.clientToServer,e.type=new O.ProtocolRequestType(e.method)})(PC=d.WillSaveTextDocumentWaitUntilRequest||(d.WillSaveTextDocumentWaitUntilRequest={}));var _C;(function(e){e.method="workspace/didChangeWatchedFiles",e.messageDirection=O.MessageDirection.clientToServer,e.type=new O.ProtocolNotificationType(e.method)})(_C=d.DidChangeWatchedFilesNotification||(d.DidChangeWatchedFilesNotification={}));var RC;(function(e){e.Created=1,e.Changed=2,e.Deleted=3})(RC=d.FileChangeType||(d.FileChangeType={}));var DC;(function(e){function t(n){let r=n;return Ue.objectLiteral(r)&&(uf.URI.is(r.baseUri)||uf.WorkspaceFolder.is(r.baseUri))&&Ue.string(r.pattern)}e.is=t})(DC=d.RelativePattern||(d.RelativePattern={}));var SC;(function(e){e.Create=1,e.Change=2,e.Delete=4})(SC=d.WatchKind||(d.WatchKind={}));var TC;(function(e){e.method="textDocument/publishDiagnostics",e.messageDirection=O.MessageDirection.serverToClient,e.type=new O.ProtocolNotificationType(e.method)})(TC=d.PublishDiagnosticsNotification||(d.PublishDiagnosticsNotification={}));var xC;(function(e){e.Invoked=1,e.TriggerCharacter=2,e.TriggerForIncompleteCompletions=3})(xC=d.CompletionTriggerKind||(d.CompletionTriggerKind={}));var wC;(function(e){e.method="textDocument/completion",e.messageDirection=O.MessageDirection.clientToServer,e.type=new O.ProtocolRequestType(e.method)})(wC=d.CompletionRequest||(d.CompletionRequest={}));var kC;(function(e){e.method="completionItem/resolve",e.messageDirection=O.MessageDirection.clientToServer,e.type=new O.ProtocolRequestType(e.method)})(kC=d.CompletionResolveRequest||(d.CompletionResolveRequest={}));var AC;(function(e){e.method="textDocument/hover",e.messageDirection=O.MessageDirection.clientToServer,e.type=new O.ProtocolRequestType(e.method)})(AC=d.HoverRequest||(d.HoverRequest={}));var qC;(function(e){e.Invoked=1,e.TriggerCharacter=2,e.ContentChange=3})(qC=d.SignatureHelpTriggerKind||(d.SignatureHelpTriggerKind={}));var NC;(function(e){e.method="textDocument/signatureHelp",e.messageDirection=O.MessageDirection.clientToServer,e.type=new O.ProtocolRequestType(e.method)})(NC=d.SignatureHelpRequest||(d.SignatureHelpRequest={}));var OC;(function(e){e.method="textDocument/definition",e.messageDirection=O.MessageDirection.clientToServer,e.type=new O.ProtocolRequestType(e.method)})(OC=d.DefinitionRequest||(d.DefinitionRequest={}));var EC;(function(e){e.method="textDocument/references",e.messageDirection=O.MessageDirection.clientToServer,e.type=new O.ProtocolRequestType(e.method)})(EC=d.ReferencesRequest||(d.ReferencesRequest={}));var MC;(function(e){e.method="textDocument/documentHighlight",e.messageDirection=O.MessageDirection.clientToServer,e.type=new O.ProtocolRequestType(e.method)})(MC=d.DocumentHighlightRequest||(d.DocumentHighlightRequest={}));var jC;(function(e){e.method="textDocument/documentSymbol",e.messageDirection=O.MessageDirection.clientToServer,e.type=new O.ProtocolRequestType(e.method)})(jC=d.DocumentSymbolRequest||(d.DocumentSymbolRequest={}));var LC;(function(e){e.method="textDocument/codeAction",e.messageDirection=O.MessageDirection.clientToServer,e.type=new O.ProtocolRequestType(e.method)})(LC=d.CodeActionRequest||(d.CodeActionRequest={}));var IC;(function(e){e.method="codeAction/resolve",e.messageDirection=O.MessageDirection.clientToServer,e.type=new O.ProtocolRequestType(e.method)})(IC=d.CodeActionResolveRequest||(d.CodeActionResolveRequest={}));var FC;(function(e){e.method="workspace/symbol",e.messageDirection=O.MessageDirection.clientToServer,e.type=new O.ProtocolRequestType(e.method)})(FC=d.WorkspaceSymbolRequest||(d.WorkspaceSymbolRequest={}));var WC;(function(e){e.method="workspaceSymbol/resolve",e.messageDirection=O.MessageDirection.clientToServer,e.type=new O.ProtocolRequestType(e.method)})(WC=d.WorkspaceSymbolResolveRequest||(d.WorkspaceSymbolResolveRequest={}));var HC;(function(e){e.method="textDocument/codeLens",e.messageDirection=O.MessageDirection.clientToServer,e.type=new O.ProtocolRequestType(e.method)})(HC=d.CodeLensRequest||(d.CodeLensRequest={}));var UC;(function(e){e.method="codeLens/resolve",e.messageDirection=O.MessageDirection.clientToServer,e.type=new O.ProtocolRequestType(e.method)})(UC=d.CodeLensResolveRequest||(d.CodeLensResolveRequest={}));var BC;(function(e){e.method="workspace/codeLens/refresh",e.messageDirection=O.MessageDirection.serverToClient,e.type=new O.ProtocolRequestType0(e.method)})(BC=d.CodeLensRefreshRequest||(d.CodeLensRefreshRequest={}));var zC;(function(e){e.method="textDocument/documentLink",e.messageDirection=O.MessageDirection.clientToServer,e.type=new O.ProtocolRequestType(e.method)})(zC=d.DocumentLinkRequest||(d.DocumentLinkRequest={}));var $C;(function(e){e.method="documentLink/resolve",e.messageDirection=O.MessageDirection.clientToServer,e.type=new O.ProtocolRequestType(e.method)})($C=d.DocumentLinkResolveRequest||(d.DocumentLinkResolveRequest={}));var YC;(function(e){e.method="textDocument/formatting",e.messageDirection=O.MessageDirection.clientToServer,e.type=new O.ProtocolRequestType(e.method)})(YC=d.DocumentFormattingRequest||(d.DocumentFormattingRequest={}));var VC;(function(e){e.method="textDocument/rangeFormatting",e.messageDirection=O.MessageDirection.clientToServer,e.type=new O.ProtocolRequestType(e.method)})(VC=d.DocumentRangeFormattingRequest||(d.DocumentRangeFormattingRequest={}));var KC;(function(e){e.method="textDocument/onTypeFormatting",e.messageDirection=O.MessageDirection.clientToServer,e.type=new O.ProtocolRequestType(e.method)})(KC=d.DocumentOnTypeFormattingRequest||(d.DocumentOnTypeFormattingRequest={}));var GC;(function(e){e.Identifier=1})(GC=d.PrepareSupportDefaultBehavior||(d.PrepareSupportDefaultBehavior={}));var JC;(function(e){e.method="textDocument/rename",e.messageDirection=O.MessageDirection.clientToServer,e.type=new O.ProtocolRequestType(e.method)})(JC=d.RenameRequest||(d.RenameRequest={}));var QC;(function(e){e.method="textDocument/prepareRename",e.messageDirection=O.MessageDirection.clientToServer,e.type=new O.ProtocolRequestType(e.method)})(QC=d.PrepareRenameRequest||(d.PrepareRenameRequest={}));var XC;(function(e){e.method="workspace/executeCommand",e.messageDirection=O.MessageDirection.clientToServer,e.type=new O.ProtocolRequestType(e.method)})(XC=d.ExecuteCommandRequest||(d.ExecuteCommandRequest={}));var ZC;(function(e){e.method="workspace/applyEdit",e.messageDirection=O.MessageDirection.serverToClient,e.type=new O.ProtocolRequestType("workspace/applyEdit")})(ZC=d.ApplyWorkspaceEditRequest||(d.ApplyWorkspaceEditRequest={}))});var vf=A(so=>{"use strict";Object.defineProperty(so,"__esModule",{value:!0});so.createProtocolConnection=void 0;var bf=Tn();function eP(e,t,n,r){return bf.ConnectionStrategy.is(r)&&(r={connectionStrategy:r}),(0,bf.createMessageConnection)(e,t,n,r)}so.createProtocolConnection=eP});var Cf=A(Je=>{"use strict";var tP=Je&&Je.__createBinding||(Object.create?function(e,t,n,r){r===void 0&&(r=n);var i=Object.getOwnPropertyDescriptor(t,n);(!i||("get"in i?!t.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:function(){return t[n]}}),Object.defineProperty(e,r,i)}:function(e,t,n,r){r===void 0&&(r=n),e[r]=t[n]}),ao=Je&&Je.__exportStar||function(e,t){for(var n in e)n!=="default"&&!Object.prototype.hasOwnProperty.call(t,n)&&tP(t,e,n)};Object.defineProperty(Je,"__esModule",{value:!0});Je.LSPErrorCodes=Je.createProtocolConnection=void 0;ao(Tn(),Je);ao(Zi(),Je);ao(Ce(),Je);ao(yf(),Je);var nP=vf();Object.defineProperty(Je,"createProtocolConnection",{enumerable:!0,get:function(){return nP.createProtocolConnection}});var rP;(function(e){e.lspReservedErrorRangeStart=-32899,e.RequestFailed=-32803,e.ServerCancelled=-32802,e.ContentModified=-32801,e.RequestCancelled=-32800,e.lspReservedErrorRangeEnd=-32800})(rP=Je.LSPErrorCodes||(Je.LSPErrorCodes={}))});var qe=A(Ot=>{"use strict";var iP=Ot&&Ot.__createBinding||(Object.create?function(e,t,n,r){r===void 0&&(r=n);var i=Object.getOwnPropertyDescriptor(t,n);(!i||("get"in i?!t.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:function(){return t[n]}}),Object.defineProperty(e,r,i)}:function(e,t,n,r){r===void 0&&(r=n),e[r]=t[n]}),Pf=Ot&&Ot.__exportStar||function(e,t){for(var n in e)n!=="default"&&!Object.prototype.hasOwnProperty.call(t,n)&&iP(t,e,n)};Object.defineProperty(Ot,"__esModule",{value:!0});Ot.createProtocolConnection=void 0;var oP=fc();Pf(fc(),Ot);Pf(Cf(),Ot);function sP(e,t,n,r){return(0,oP.createMessageConnection)(e,t,n,r)}Ot.createProtocolConnection=sP});var Sc=A(sn=>{"use strict";Object.defineProperty(sn,"__esModule",{value:!0});sn.SemanticTokensBuilder=sn.SemanticTokensDiff=sn.SemanticTokensFeature=void 0;var co=qe(),aP=e=>class extends e{get semanticTokens(){return{refresh:()=>this.connection.sendRequest(co.SemanticTokensRefreshRequest.type),on:t=>{let n=co.SemanticTokensRequest.type;return this.connection.onRequest(n,(r,i)=>t(r,i,this.attachWorkDoneProgress(r),this.attachPartialResultProgress(n,r)))},onDelta:t=>{let n=co.SemanticTokensDeltaRequest.type;return this.connection.onRequest(n,(r,i)=>t(r,i,this.attachWorkDoneProgress(r),this.attachPartialResultProgress(n,r)))},onRange:t=>{let n=co.SemanticTokensRangeRequest.type;return this.connection.onRequest(n,(r,i)=>t(r,i,this.attachWorkDoneProgress(r),this.attachPartialResultProgress(n,r)))}}}};sn.SemanticTokensFeature=aP;var uo=class{constructor(t,n){this.originalSequence=t,this.modifiedSequence=n}computeDiff(){let t=this.originalSequence.length,n=this.modifiedSequence.length,r=0;for(;r<n&&r<t&&this.originalSequence[r]===this.modifiedSequence[r];)r++;if(r<n&&r<t){let i=t-1,o=n-1;for(;i>=r&&o>=r&&this.originalSequence[i]===this.modifiedSequence[o];)i--,o--;(i<r||o<r)&&(i++,o++);let s=i-r+1,u=this.modifiedSequence.slice(r,o+1);return u.length===1&&u[0]===this.originalSequence[i]?[{start:r,deleteCount:s-1}]:[{start:r,deleteCount:s,data:u}]}else return r<n?[{start:r,deleteCount:0,data:this.modifiedSequence.slice(r)}]:r<t?[{start:r,deleteCount:t-r}]:[]}};sn.SemanticTokensDiff=uo;var Dc=class{constructor(){this._prevData=void 0,this.initialize()}initialize(){this._id=Date.now(),this._prevLine=0,this._prevChar=0,this._data=[],this._dataLen=0}push(t,n,r,i,o){let s=t,u=n;this._dataLen>0&&(s-=this._prevLine,s===0&&(u-=this._prevChar)),this._data[this._dataLen++]=s,this._data[this._dataLen++]=u,this._data[this._dataLen++]=r,this._data[this._dataLen++]=i,this._data[this._dataLen++]=o,this._prevLine=t,this._prevChar=n}get id(){return this._id.toString()}previousResult(t){this.id===t&&(this._prevData=this._data),this.initialize()}build(){return this._prevData=void 0,{resultId:this.id,data:this._data}}canBuildEdits(){return this._prevData!==void 0}buildEdits(){return this._prevData!==void 0?{resultId:this.id,edits:new uo(this._prevData,this._data).computeDiff()}:this.build()}};sn.SemanticTokensBuilder=Dc});var xc=A(lo=>{"use strict";Object.defineProperty(lo,"__esModule",{value:!0});lo.TextDocuments=void 0;var wn=qe(),Tc=class{constructor(t){this._configuration=t,this._syncedDocuments=new Map,this._onDidChangeContent=new wn.Emitter,this._onDidOpen=new wn.Emitter,this._onDidClose=new wn.Emitter,this._onDidSave=new wn.Emitter,this._onWillSave=new wn.Emitter}get onDidOpen(){return this._onDidOpen.event}get onDidChangeContent(){return this._onDidChangeContent.event}get onWillSave(){return this._onWillSave.event}onWillSaveWaitUntil(t){this._willSaveWaitUntil=t}get onDidSave(){return this._onDidSave.event}get onDidClose(){return this._onDidClose.event}get(t){return this._syncedDocuments.get(t)}all(){return Array.from(this._syncedDocuments.values())}keys(){return Array.from(this._syncedDocuments.keys())}listen(t){t.__textDocumentSync=wn.TextDocumentSyncKind.Incremental;let n=[];return n.push(t.onDidOpenTextDocument(r=>{let i=r.textDocument,o=this._configuration.create(i.uri,i.languageId,i.version,i.text);this._syncedDocuments.set(i.uri,o);let s=Object.freeze({document:o});this._onDidOpen.fire(s),this._onDidChangeContent.fire(s)})),n.push(t.onDidChangeTextDocument(r=>{let i=r.textDocument,o=r.contentChanges;if(o.length===0)return;let{version:s}=i;if(s==null)throw new Error(`Received document change event for ${i.uri} without valid version identifier`);let u=this._syncedDocuments.get(i.uri);u!==void 0&&(u=this._configuration.update(u,o,s),this._syncedDocuments.set(i.uri,u),this._onDidChangeContent.fire(Object.freeze({document:u})))})),n.push(t.onDidCloseTextDocument(r=>{let i=this._syncedDocuments.get(r.textDocument.uri);i!==void 0&&(this._syncedDocuments.delete(r.textDocument.uri),this._onDidClose.fire(Object.freeze({document:i})))})),n.push(t.onWillSaveTextDocument(r=>{let i=this._syncedDocuments.get(r.textDocument.uri);i!==void 0&&this._onWillSave.fire(Object.freeze({document:i,reason:r.reason}))})),n.push(t.onWillSaveTextDocumentWaitUntil((r,i)=>{let o=this._syncedDocuments.get(r.textDocument.uri);return o!==void 0&&this._willSaveWaitUntil?this._willSaveWaitUntil(Object.freeze({document:o,reason:r.reason}),i):[]})),n.push(t.onDidSaveTextDocument(r=>{let i=this._syncedDocuments.get(r.textDocument.uri);i!==void 0&&this._onDidSave.fire(Object.freeze({document:i}))})),wn.Disposable.create(()=>{n.forEach(r=>r.dispose())})}};lo.TextDocuments=Tc});var kc=A(sr=>{"use strict";Object.defineProperty(sr,"__esModule",{value:!0});sr.NotebookDocuments=sr.NotebookSyncFeature=void 0;var ct=qe(),_f=xc(),cP=e=>class extends e{get synchronization(){return{onDidOpenNotebookDocument:t=>this.connection.onNotification(ct.DidOpenNotebookDocumentNotification.type,n=>{t(n)}),onDidChangeNotebookDocument:t=>this.connection.onNotification(ct.DidChangeNotebookDocumentNotification.type,n=>{t(n)}),onDidSaveNotebookDocument:t=>this.connection.onNotification(ct.DidSaveNotebookDocumentNotification.type,n=>{t(n)}),onDidCloseNotebookDocument:t=>this.connection.onNotification(ct.DidCloseNotebookDocumentNotification.type,n=>{t(n)})}}};sr.NotebookSyncFeature=cP;var an=class{onDidOpenTextDocument(t){return this.openHandler=t,ct.Disposable.create(()=>{this.openHandler=void 0})}openTextDocument(t){this.openHandler&&this.openHandler(t)}onDidChangeTextDocument(t){return this.changeHandler=t,ct.Disposable.create(()=>{this.changeHandler=t})}changeTextDocument(t){this.changeHandler&&this.changeHandler(t)}onDidCloseTextDocument(t){return this.closeHandler=t,ct.Disposable.create(()=>{this.closeHandler=void 0})}closeTextDocument(t){this.closeHandler&&this.closeHandler(t)}onWillSaveTextDocument(){return an.NULL_DISPOSE}onWillSaveTextDocumentWaitUntil(){return an.NULL_DISPOSE}onDidSaveTextDocument(){return an.NULL_DISPOSE}};an.NULL_DISPOSE=Object.freeze({dispose:()=>{}});var wc=class{constructor(t){t instanceof _f.TextDocuments?this._cellTextDocuments=t:this._cellTextDocuments=new _f.TextDocuments(t),this.notebookDocuments=new Map,this.notebookCellMap=new Map,this._onDidOpen=new ct.Emitter,this._onDidChange=new ct.Emitter,this._onDidSave=new ct.Emitter,this._onDidClose=new ct.Emitter}get cellTextDocuments(){return this._cellTextDocuments}getCellTextDocument(t){return this._cellTextDocuments.get(t.document)}getNotebookDocument(t){return this.notebookDocuments.get(t)}getNotebookCell(t){let n=this.notebookCellMap.get(t);return n&&n[0]}findNotebookDocumentForCell(t){let n=typeof t=="string"?t:t.document,r=this.notebookCellMap.get(n);return r&&r[1]}get onDidOpen(){return this._onDidOpen.event}get onDidSave(){return this._onDidSave.event}get onDidChange(){return this._onDidChange.event}get onDidClose(){return this._onDidClose.event}listen(t){let n=new an,r=[];return r.push(this.cellTextDocuments.listen(n)),r.push(t.notebooks.synchronization.onDidOpenNotebookDocument(i=>{this.notebookDocuments.set(i.notebookDocument.uri,i.notebookDocument);for(let o of i.cellTextDocuments)n.openTextDocument({textDocument:o});this.updateCellMap(i.notebookDocument),this._onDidOpen.fire(i.notebookDocument)})),r.push(t.notebooks.synchronization.onDidChangeNotebookDocument(i=>{let o=this.notebookDocuments.get(i.notebookDocument.uri);if(o===void 0)return;o.version=i.notebookDocument.version;let s=o.metadata,u=!1,c=i.change;c.metadata!==void 0&&(u=!0,o.metadata=c.metadata);let p=[],g=[],b=[],R=[];if(c.cells!==void 0){let L=c.cells;if(L.structure!==void 0){let _=L.structure.array;if(o.cells.splice(_.start,_.deleteCount,..._.cells!==void 0?_.cells:[]),L.structure.didOpen!==void 0)for(let v of L.structure.didOpen)n.openTextDocument({textDocument:v}),p.push(v.uri);if(L.structure.didClose)for(let v of L.structure.didClose)n.closeTextDocument({textDocument:v}),g.push(v.uri)}if(L.data!==void 0){let _=new Map(L.data.map(v=>[v.document,v]));for(let v=0;v<=o.cells.length;v++){let N=_.get(o.cells[v].document);if(N!==void 0){let z=o.cells.splice(v,1,N);if(b.push({old:z[0],new:N}),_.delete(N.document),_.size===0)break}}}if(L.textContent!==void 0)for(let _ of L.textContent)n.changeTextDocument({textDocument:_.document,contentChanges:_.changes}),R.push(_.document.uri)}this.updateCellMap(o);let D={notebookDocument:o};u&&(D.metadata={old:s,new:o.metadata});let T=[];for(let L of p)T.push(this.getNotebookCell(L));let q=[];for(let L of g)q.push(this.getNotebookCell(L));let B=[];for(let L of R)B.push(this.getNotebookCell(L));(T.length>0||q.length>0||b.length>0||B.length>0)&&(D.cells={added:T,removed:q,changed:{data:b,textContent:B}}),(D.metadata!==void 0||D.cells!==void 0)&&this._onDidChange.fire(D)})),r.push(t.notebooks.synchronization.onDidSaveNotebookDocument(i=>{let o=this.notebookDocuments.get(i.notebookDocument.uri);o!==void 0&&this._onDidSave.fire(o)})),r.push(t.notebooks.synchronization.onDidCloseNotebookDocument(i=>{let o=this.notebookDocuments.get(i.notebookDocument.uri);if(o!==void 0){this._onDidClose.fire(o);for(let s of i.cellTextDocuments)n.closeTextDocument({textDocument:s});this.notebookDocuments.delete(i.notebookDocument.uri);for(let s of o.cells)this.notebookCellMap.delete(s.document)}})),ct.Disposable.create(()=>{r.forEach(i=>i.dispose())})}updateCellMap(t){for(let n of t.cells)this.notebookCellMap.set(n.document,[n,t])}};sr.NotebookDocuments=wc});var Ac=A(ke=>{"use strict";Object.defineProperty(ke,"__esModule",{value:!0});ke.thenable=ke.typedArray=ke.stringArray=ke.array=ke.func=ke.error=ke.number=ke.string=ke.boolean=void 0;function uP(e){return e===!0||e===!1}ke.boolean=uP;function Rf(e){return typeof e=="string"||e instanceof String}ke.string=Rf;function lP(e){return typeof e=="number"||e instanceof Number}ke.number=lP;function dP(e){return e instanceof Error}ke.error=dP;function Df(e){return typeof e=="function"}ke.func=Df;function Sf(e){return Array.isArray(e)}ke.array=Sf;function fP(e){return Sf(e)&&e.every(t=>Rf(t))}ke.stringArray=fP;function pP(e,t){return Array.isArray(e)&&e.every(t)}ke.typedArray=pP;function gP(e){return e&&Df(e.then)}ke.thenable=gP});var qc=A(ut=>{"use strict";Object.defineProperty(ut,"__esModule",{value:!0});ut.generateUuid=ut.parse=ut.isUUID=ut.v4=ut.empty=void 0;var Wr=class{constructor(t){this._value=t}asHex(){return this._value}equals(t){return this.asHex()===t.asHex()}},Q=class extends Wr{constructor(){super([Q._randomHex(),Q._randomHex(),Q._randomHex(),Q._randomHex(),Q._randomHex(),Q._randomHex(),Q._randomHex(),Q._randomHex(),"-",Q._randomHex(),Q._randomHex(),Q._randomHex(),Q._randomHex(),"-","4",Q._randomHex(),Q._randomHex(),Q._randomHex(),"-",Q._oneOf(Q._timeHighBits),Q._randomHex(),Q._randomHex(),Q._randomHex(),"-",Q._randomHex(),Q._randomHex(),Q._randomHex(),Q._randomHex(),Q._randomHex(),Q._randomHex(),Q._randomHex(),Q._randomHex(),Q._randomHex(),Q._randomHex(),Q._randomHex(),Q._randomHex()].join(""))}static _oneOf(t){return t[Math.floor(t.length*Math.random())]}static _randomHex(){return Q._oneOf(Q._chars)}};Q._chars=["0","1","2","3","4","5","6","6","7","8","9","a","b","c","d","e","f"];Q._timeHighBits=["8","9","a","b"];ut.empty=new Wr("00000000-0000-0000-0000-000000000000");function Tf(){return new Q}ut.v4=Tf;var mP=/^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/i;function xf(e){return mP.test(e)}ut.isUUID=xf;function hP(e){if(!xf(e))throw new Error("invalid uuid");return new Wr(e)}ut.parse=hP;function yP(){return Tf().asHex()}ut.generateUuid=yP});var wf=A(un=>{"use strict";Object.defineProperty(un,"__esModule",{value:!0});un.attachPartialResult=un.ProgressFeature=un.attachWorkDone=void 0;var cn=qe(),bP=qc(),Et=class{constructor(t,n){this._connection=t,this._token=n,Et.Instances.set(this._token,this)}begin(t,n,r,i){let o={kind:"begin",title:t,percentage:n,message:r,cancellable:i};this._connection.sendProgress(cn.WorkDoneProgress.type,this._token,o)}report(t,n){let r={kind:"report"};typeof t=="number"?(r.percentage=t,n!==void 0&&(r.message=n)):r.message=t,this._connection.sendProgress(cn.WorkDoneProgress.type,this._token,r)}done(){Et.Instances.delete(this._token),this._connection.sendProgress(cn.WorkDoneProgress.type,this._token,{kind:"end"})}};Et.Instances=new Map;var fo=class extends Et{constructor(t,n){super(t,n),this._source=new cn.CancellationTokenSource}get token(){return this._source.token}done(){this._source.dispose(),super.done()}cancel(){this._source.cancel()}},Hr=class{constructor(){}begin(){}report(){}done(){}},po=class extends Hr{constructor(){super(),this._source=new cn.CancellationTokenSource}get token(){return this._source.token}done(){this._source.dispose()}cancel(){this._source.cancel()}};function vP(e,t){if(t===void 0||t.workDoneToken===void 0)return new Hr;let n=t.workDoneToken;return delete t.workDoneToken,new Et(e,n)}un.attachWorkDone=vP;var CP=e=>class extends e{constructor(){super(),this._progressSupported=!1}initialize(t){super.initialize(t),t?.window?.workDoneProgress===!0&&(this._progressSupported=!0,this.connection.onNotification(cn.WorkDoneProgressCancelNotification.type,n=>{let r=Et.Instances.get(n.token);(r instanceof fo||r instanceof po)&&r.cancel()}))}attachWorkDoneProgress(t){return t===void 0?new Hr:new Et(this.connection,t)}createWorkDoneProgress(){if(this._progressSupported){let t=(0,bP.generateUuid)();return this.connection.sendRequest(cn.WorkDoneProgressCreateRequest.type,{token:t}).then(()=>new fo(this.connection,t))}else return Promise.resolve(new po)}};un.ProgressFeature=CP;var Nc;(function(e){e.type=new cn.ProgressType})(Nc||(Nc={}));var Oc=class{constructor(t,n){this._connection=t,this._token=n}report(t){this._connection.sendProgress(Nc.type,this._token,t)}};function PP(e,t){if(t===void 0||t.partialResultToken===void 0)return;let n=t.partialResultToken;return delete t.partialResultToken,new Oc(e,n)}un.attachPartialResult=PP});var kf=A(go=>{"use strict";Object.defineProperty(go,"__esModule",{value:!0});go.ConfigurationFeature=void 0;var _P=qe(),RP=Ac(),DP=e=>class extends e{getConfiguration(t){return t?RP.string(t)?this._getConfiguration({section:t}):this._getConfiguration(t):this._getConfiguration({})}_getConfiguration(t){let n={items:Array.isArray(t)?t:[t]};return this.connection.sendRequest(_P.ConfigurationRequest.type,n).then(r=>Array.isArray(r)?Array.isArray(t)?r:r[0]:Array.isArray(t)?[]:null)}};go.ConfigurationFeature=DP});var Af=A(ho=>{"use strict";Object.defineProperty(ho,"__esModule",{value:!0});ho.WorkspaceFoldersFeature=void 0;var mo=qe(),SP=e=>class extends e{constructor(){super(),this._notificationIsAutoRegistered=!1}initialize(t){super.initialize(t);let n=t.workspace;n&&n.workspaceFolders&&(this._onDidChangeWorkspaceFolders=new mo.Emitter,this.connection.onNotification(mo.DidChangeWorkspaceFoldersNotification.type,r=>{this._onDidChangeWorkspaceFolders.fire(r.event)}))}fillServerCapabilities(t){super.fillServerCapabilities(t);let n=t.workspace?.workspaceFolders?.changeNotifications;this._notificationIsAutoRegistered=n===!0||typeof n=="string"}getWorkspaceFolders(){return this.connection.sendRequest(mo.WorkspaceFoldersRequest.type)}get onDidChangeWorkspaceFolders(){if(!this._onDidChangeWorkspaceFolders)throw new Error("Client doesn't support sending workspace folder change events.");return!this._notificationIsAutoRegistered&&!this._unregistration&&(this._unregistration=this.connection.client.register(mo.DidChangeWorkspaceFoldersNotification.type)),this._onDidChangeWorkspaceFolders.event}};ho.WorkspaceFoldersFeature=SP});var qf=A(yo=>{"use strict";Object.defineProperty(yo,"__esModule",{value:!0});yo.CallHierarchyFeature=void 0;var Ec=qe(),TP=e=>class extends e{get callHierarchy(){return{onPrepare:t=>this.connection.onRequest(Ec.CallHierarchyPrepareRequest.type,(n,r)=>t(n,r,this.attachWorkDoneProgress(n),void 0)),onIncomingCalls:t=>{let n=Ec.CallHierarchyIncomingCallsRequest.type;return this.connection.onRequest(n,(r,i)=>t(r,i,this.attachWorkDoneProgress(r),this.attachPartialResultProgress(n,r)))},onOutgoingCalls:t=>{let n=Ec.CallHierarchyOutgoingCallsRequest.type;return this.connection.onRequest(n,(r,i)=>t(r,i,this.attachWorkDoneProgress(r),this.attachPartialResultProgress(n,r)))}}}};yo.CallHierarchyFeature=TP});var Nf=A(bo=>{"use strict";Object.defineProperty(bo,"__esModule",{value:!0});bo.ShowDocumentFeature=void 0;var xP=qe(),wP=e=>class extends e{showDocument(t){return this.connection.sendRequest(xP.ShowDocumentRequest.type,t)}};bo.ShowDocumentFeature=wP});var Of=A(vo=>{"use strict";Object.defineProperty(vo,"__esModule",{value:!0});vo.FileOperationsFeature=void 0;var ar=qe(),kP=e=>class extends e{onDidCreateFiles(t){return this.connection.onNotification(ar.DidCreateFilesNotification.type,n=>{t(n)})}onDidRenameFiles(t){return this.connection.onNotification(ar.DidRenameFilesNotification.type,n=>{t(n)})}onDidDeleteFiles(t){return this.connection.onNotification(ar.DidDeleteFilesNotification.type,n=>{t(n)})}onWillCreateFiles(t){return this.connection.onRequest(ar.WillCreateFilesRequest.type,(n,r)=>t(n,r))}onWillRenameFiles(t){return this.connection.onRequest(ar.WillRenameFilesRequest.type,(n,r)=>t(n,r))}onWillDeleteFiles(t){return this.connection.onRequest(ar.WillDeleteFilesRequest.type,(n,r)=>t(n,r))}};vo.FileOperationsFeature=kP});var Ef=A(Co=>{"use strict";Object.defineProperty(Co,"__esModule",{value:!0});Co.LinkedEditingRangeFeature=void 0;var AP=qe(),qP=e=>class extends e{onLinkedEditingRange(t){return this.connection.onRequest(AP.LinkedEditingRangeRequest.type,(n,r)=>t(n,r,this.attachWorkDoneProgress(n),void 0))}};Co.LinkedEditingRangeFeature=qP});var Mf=A(Po=>{"use strict";Object.defineProperty(Po,"__esModule",{value:!0});Po.TypeHierarchyFeature=void 0;var Mc=qe(),NP=e=>class extends e{get typeHierarchy(){return{onPrepare:t=>this.connection.onRequest(Mc.TypeHierarchyPrepareRequest.type,(n,r)=>t(n,r,this.attachWorkDoneProgress(n),void 0)),onSupertypes:t=>{let n=Mc.TypeHierarchySupertypesRequest.type;return this.connection.onRequest(n,(r,i)=>t(r,i,this.attachWorkDoneProgress(r),this.attachPartialResultProgress(n,r)))},onSubtypes:t=>{let n=Mc.TypeHierarchySubtypesRequest.type;return this.connection.onRequest(n,(r,i)=>t(r,i,this.attachWorkDoneProgress(r),this.attachPartialResultProgress(n,r)))}}}};Po.TypeHierarchyFeature=NP});var Lf=A(_o=>{"use strict";Object.defineProperty(_o,"__esModule",{value:!0});_o.InlineValueFeature=void 0;var jf=qe(),OP=e=>class extends e{get inlineValue(){return{refresh:()=>this.connection.sendRequest(jf.InlineValueRefreshRequest.type),on:t=>this.connection.onRequest(jf.InlineValueRequest.type,(n,r)=>t(n,r,this.attachWorkDoneProgress(n)))}}};_o.InlineValueFeature=OP});var If=A(Ro=>{"use strict";Object.defineProperty(Ro,"__esModule",{value:!0});Ro.InlayHintFeature=void 0;var jc=qe(),EP=e=>class extends e{get inlayHint(){return{refresh:()=>this.connection.sendRequest(jc.InlayHintRefreshRequest.type),on:t=>this.connection.onRequest(jc.InlayHintRequest.type,(n,r)=>t(n,r,this.attachWorkDoneProgress(n))),resolve:t=>this.connection.onRequest(jc.InlayHintResolveRequest.type,(n,r)=>t(n,r))}}};Ro.InlayHintFeature=EP});var Ff=A(Do=>{"use strict";Object.defineProperty(Do,"__esModule",{value:!0});Do.DiagnosticFeature=void 0;var Ur=qe(),MP=e=>class extends e{get diagnostics(){return{refresh:()=>this.connection.sendRequest(Ur.DiagnosticRefreshRequest.type),on:t=>this.connection.onRequest(Ur.DocumentDiagnosticRequest.type,(n,r)=>t(n,r,this.attachWorkDoneProgress(n),this.attachPartialResultProgress(Ur.DocumentDiagnosticRequest.partialResult,n))),onWorkspace:t=>this.connection.onRequest(Ur.WorkspaceDiagnosticRequest.type,(n,r)=>t(n,r,this.attachWorkDoneProgress(n),this.attachPartialResultProgress(Ur.WorkspaceDiagnosticRequest.partialResult,n)))}}};Do.DiagnosticFeature=MP});var Wf=A(So=>{"use strict";Object.defineProperty(So,"__esModule",{value:!0});So.MonikerFeature=void 0;var jP=qe(),LP=e=>class extends e{get moniker(){return{on:t=>{let n=jP.MonikerRequest.type;return this.connection.onRequest(n,(r,i)=>t(r,i,this.attachWorkDoneProgress(r),this.attachPartialResultProgress(n,r)))}}}};So.MonikerFeature=LP});var Zf=A(ne=>{"use strict";Object.defineProperty(ne,"__esModule",{value:!0});ne.createConnection=ne.combineFeatures=ne.combineNotebooksFeatures=ne.combineLanguagesFeatures=ne.combineWorkspaceFeatures=ne.combineWindowFeatures=ne.combineClientFeatures=ne.combineTracerFeatures=ne.combineTelemetryFeatures=ne.combineConsoleFeatures=ne._NotebooksImpl=ne._LanguagesImpl=ne.BulkUnregistration=ne.BulkRegistration=ne.ErrorMessageTracker=void 0;var M=qe(),lt=Ac(),Ic=qc(),V=wf(),IP=kf(),FP=Af(),WP=qf(),HP=Sc(),UP=Nf(),BP=Of(),zP=Ef(),$P=Mf(),YP=Lf(),VP=If(),KP=Ff(),GP=kc(),JP=Wf();function Lc(e){if(e!==null)return e}var Fc=class{constructor(){this._messages=Object.create(null)}add(t){let n=this._messages[t];n||(n=0),n++,this._messages[t]=n}sendErrors(t){Object.keys(this._messages).forEach(n=>{t.window.showErrorMessage(n)})}};ne.ErrorMessageTracker=Fc;var To=class{constructor(){}rawAttach(t){this._rawConnection=t}attach(t){this._connection=t}get connection(){if(!this._connection)throw new Error("Remote is not attached to a connection yet.");return this._connection}fillServerCapabilities(t){}initialize(t){}error(t){this.send(M.MessageType.Error,t)}warn(t){this.send(M.MessageType.Warning,t)}info(t){this.send(M.MessageType.Info,t)}log(t){this.send(M.MessageType.Log,t)}send(t,n){this._rawConnection&&this._rawConnection.sendNotification(M.LogMessageNotification.type,{type:t,message:n}).catch(()=>{(0,M.RAL)().console.error("Sending log message failed")})}},Wc=class{constructor(){}attach(t){this._connection=t}get connection(){if(!this._connection)throw new Error("Remote is not attached to a connection yet.");return this._connection}initialize(t){}fillServerCapabilities(t){}showErrorMessage(t,...n){let r={type:M.MessageType.Error,message:t,actions:n};return this.connection.sendRequest(M.ShowMessageRequest.type,r).then(Lc)}showWarningMessage(t,...n){let r={type:M.MessageType.Warning,message:t,actions:n};return this.connection.sendRequest(M.ShowMessageRequest.type,r).then(Lc)}showInformationMessage(t,...n){let r={type:M.MessageType.Info,message:t,actions:n};return this.connection.sendRequest(M.ShowMessageRequest.type,r).then(Lc)}},Hf=(0,UP.ShowDocumentFeature)((0,V.ProgressFeature)(Wc)),QP;(function(e){function t(){return new xo}e.create=t})(QP=ne.BulkRegistration||(ne.BulkRegistration={}));var xo=class{constructor(){this._registrations=[],this._registered=new Set}add(t,n){let r=lt.string(t)?t:t.method;if(this._registered.has(r))throw new Error(`${r} is already added to this registration`);let i=Ic.generateUuid();this._registrations.push({id:i,method:r,registerOptions:n||{}}),this._registered.add(r)}asRegistrationParams(){return{registrations:this._registrations}}},XP;(function(e){function t(){return new Br(void 0,[])}e.create=t})(XP=ne.BulkUnregistration||(ne.BulkUnregistration={}));var Br=class{constructor(t,n){this._connection=t,this._unregistrations=new Map,n.forEach(r=>{this._unregistrations.set(r.method,r)})}get isAttached(){return!!this._connection}attach(t){this._connection=t}add(t){this._unregistrations.set(t.method,t)}dispose(){let t=[];for(let r of this._unregistrations.values())t.push(r);let n={unregisterations:t};this._connection.sendRequest(M.UnregistrationRequest.type,n).catch(()=>{this._connection.console.info("Bulk unregistration failed.")})}disposeSingle(t){let n=lt.string(t)?t:t.method,r=this._unregistrations.get(n);if(!r)return!1;let i={unregisterations:[r]};return this._connection.sendRequest(M.UnregistrationRequest.type,i).then(()=>{this._unregistrations.delete(n)},o=>{this._connection.console.info(`Un-registering request handler for ${r.id} failed.`)}),!0}},wo=class{attach(t){this._connection=t}get connection(){if(!this._connection)throw new Error("Remote is not attached to a connection yet.");return this._connection}initialize(t){}fillServerCapabilities(t){}register(t,n,r){return t instanceof xo?this.registerMany(t):t instanceof Br?this.registerSingle1(t,n,r):this.registerSingle2(t,n)}registerSingle1(t,n,r){let i=lt.string(n)?n:n.method,o=Ic.generateUuid(),s={registrations:[{id:o,method:i,registerOptions:r||{}}]};return t.isAttached||t.attach(this.connection),this.connection.sendRequest(M.RegistrationRequest.type,s).then(u=>(t.add({id:o,method:i}),t),u=>(this.connection.console.info(`Registering request handler for ${i} failed.`),Promise.reject(u)))}registerSingle2(t,n){let r=lt.string(t)?t:t.method,i=Ic.generateUuid(),o={registrations:[{id:i,method:r,registerOptions:n||{}}]};return this.connection.sendRequest(M.RegistrationRequest.type,o).then(s=>M.Disposable.create(()=>{this.unregisterSingle(i,r).catch(()=>{this.connection.console.info(`Un-registering capability with id ${i} failed.`)})}),s=>(this.connection.console.info(`Registering request handler for ${r} failed.`),Promise.reject(s)))}unregisterSingle(t,n){let r={unregisterations:[{id:t,method:n}]};return this.connection.sendRequest(M.UnregistrationRequest.type,r).catch(()=>{this.connection.console.info(`Un-registering request handler for ${t} failed.`)})}registerMany(t){let n=t.asRegistrationParams();return this.connection.sendRequest(M.RegistrationRequest.type,n).then(()=>new Br(this._connection,n.registrations.map(r=>({id:r.id,method:r.method}))),r=>(this.connection.console.info("Bulk registration failed."),Promise.reject(r)))}},Hc=class{constructor(){}attach(t){this._connection=t}get connection(){if(!this._connection)throw new Error("Remote is not attached to a connection yet.");return this._connection}initialize(t){}fillServerCapabilities(t){}applyEdit(t){function n(i){return i&&!!i.edit}let r=n(t)?t:{edit:t};return this.connection.sendRequest(M.ApplyWorkspaceEditRequest.type,r)}},Uf=(0,BP.FileOperationsFeature)((0,FP.WorkspaceFoldersFeature)((0,IP.ConfigurationFeature)(Hc))),ko=class{constructor(){this._trace=M.Trace.Off}attach(t){this._connection=t}get connection(){if(!this._connection)throw new Error("Remote is not attached to a connection yet.");return this._connection}initialize(t){}fillServerCapabilities(t){}set trace(t){this._trace=t}log(t,n){this._trace!==M.Trace.Off&&this.connection.sendNotification(M.LogTraceNotification.type,{message:t,verbose:this._trace===M.Trace.Verbose?n:void 0}).catch(()=>{})}},Ao=class{constructor(){}attach(t){this._connection=t}get connection(){if(!this._connection)throw new Error("Remote is not attached to a connection yet.");return this._connection}initialize(t){}fillServerCapabilities(t){}logEvent(t){this.connection.sendNotification(M.TelemetryEventNotification.type,t).catch(()=>{this.connection.console.log("Sending TelemetryEventNotification failed")})}},qo=class{constructor(){}attach(t){this._connection=t}get connection(){if(!this._connection)throw new Error("Remote is not attached to a connection yet.");return this._connection}initialize(t){}fillServerCapabilities(t){}attachWorkDoneProgress(t){return(0,V.attachWorkDone)(this.connection,t)}attachPartialResultProgress(t,n){return(0,V.attachPartialResult)(this.connection,n)}};ne._LanguagesImpl=qo;var Bf=(0,JP.MonikerFeature)((0,KP.DiagnosticFeature)((0,VP.InlayHintFeature)((0,YP.InlineValueFeature)((0,$P.TypeHierarchyFeature)((0,zP.LinkedEditingRangeFeature)((0,HP.SemanticTokensFeature)((0,WP.CallHierarchyFeature)(qo)))))))),No=class{constructor(){}attach(t){this._connection=t}get connection(){if(!this._connection)throw new Error("Remote is not attached to a connection yet.");return this._connection}initialize(t){}fillServerCapabilities(t){}attachWorkDoneProgress(t){return(0,V.attachWorkDone)(this.connection,t)}attachPartialResultProgress(t,n){return(0,V.attachPartialResult)(this.connection,n)}};ne._NotebooksImpl=No;var zf=(0,GP.NotebookSyncFeature)(No);function $f(e,t){return function(n){return t(e(n))}}ne.combineConsoleFeatures=$f;function Yf(e,t){return function(n){return t(e(n))}}ne.combineTelemetryFeatures=Yf;function Vf(e,t){return function(n){return t(e(n))}}ne.combineTracerFeatures=Vf;function Kf(e,t){return function(n){return t(e(n))}}ne.combineClientFeatures=Kf;function Gf(e,t){return function(n){return t(e(n))}}ne.combineWindowFeatures=Gf;function Jf(e,t){return function(n){return t(e(n))}}ne.combineWorkspaceFeatures=Jf;function Qf(e,t){return function(n){return t(e(n))}}ne.combineLanguagesFeatures=Qf;function Xf(e,t){return function(n){return t(e(n))}}ne.combineNotebooksFeatures=Xf;function ZP(e,t){function n(i,o,s){return i&&o?s(i,o):i||o}return{__brand:"features",console:n(e.console,t.console,$f),tracer:n(e.tracer,t.tracer,Vf),telemetry:n(e.telemetry,t.telemetry,Yf),client:n(e.client,t.client,Kf),window:n(e.window,t.window,Gf),workspace:n(e.workspace,t.workspace,Jf),languages:n(e.languages,t.languages,Qf),notebooks:n(e.notebooks,t.notebooks,Xf)}}ne.combineFeatures=ZP;function e_(e,t,n){let r=n&&n.console?new(n.console(To)):new To,i=e(r);r.rawAttach(i);let o=n&&n.tracer?new(n.tracer(ko)):new ko,s=n&&n.telemetry?new(n.telemetry(Ao)):new Ao,u=n&&n.client?new(n.client(wo)):new wo,c=n&&n.window?new(n.window(Hf)):new Hf,p=n&&n.workspace?new(n.workspace(Uf)):new Uf,g=n&&n.languages?new(n.languages(Bf)):new Bf,b=n&&n.notebooks?new(n.notebooks(zf)):new zf,R=[r,o,s,u,c,p,g,b];function D(_){return _ instanceof Promise?_:lt.thenable(_)?new Promise((v,N)=>{_.then(z=>v(z),z=>N(z))}):Promise.resolve(_)}let T,q,B,L={listen:()=>i.listen(),sendRequest:(_,...v)=>i.sendRequest(lt.string(_)?_:_.method,...v),onRequest:(_,v)=>i.onRequest(_,v),sendNotification:(_,v)=>{let N=lt.string(_)?_:_.method;return arguments.length===1?i.sendNotification(N):i.sendNotification(N,v)},onNotification:(_,v)=>i.onNotification(_,v),onProgress:i.onProgress,sendProgress:i.sendProgress,onInitialize:_=>(q=_,{dispose:()=>{q=void 0}}),onInitialized:_=>i.onNotification(M.InitializedNotification.type,_),onShutdown:_=>(T=_,{dispose:()=>{T=void 0}}),onExit:_=>(B=_,{dispose:()=>{B=void 0}}),get console(){return r},get telemetry(){return s},get tracer(){return o},get client(){return u},get window(){return c},get workspace(){return p},get languages(){return g},get notebooks(){return b},onDidChangeConfiguration:_=>i.onNotification(M.DidChangeConfigurationNotification.type,_),onDidChangeWatchedFiles:_=>i.onNotification(M.DidChangeWatchedFilesNotification.type,_),__textDocumentSync:void 0,onDidOpenTextDocument:_=>i.onNotification(M.DidOpenTextDocumentNotification.type,_),onDidChangeTextDocument:_=>i.onNotification(M.DidChangeTextDocumentNotification.type,_),onDidCloseTextDocument:_=>i.onNotification(M.DidCloseTextDocumentNotification.type,_),onWillSaveTextDocument:_=>i.onNotification(M.WillSaveTextDocumentNotification.type,_),onWillSaveTextDocumentWaitUntil:_=>i.onRequest(M.WillSaveTextDocumentWaitUntilRequest.type,_),onDidSaveTextDocument:_=>i.onNotification(M.DidSaveTextDocumentNotification.type,_),sendDiagnostics:_=>i.sendNotification(M.PublishDiagnosticsNotification.type,_),onHover:_=>i.onRequest(M.HoverRequest.type,(v,N)=>_(v,N,(0,V.attachWorkDone)(i,v),void 0)),onCompletion:_=>i.onRequest(M.CompletionRequest.type,(v,N)=>_(v,N,(0,V.attachWorkDone)(i,v),(0,V.attachPartialResult)(i,v))),onCompletionResolve:_=>i.onRequest(M.CompletionResolveRequest.type,_),onSignatureHelp:_=>i.onRequest(M.SignatureHelpRequest.type,(v,N)=>_(v,N,(0,V.attachWorkDone)(i,v),void 0)),onDeclaration:_=>i.onRequest(M.DeclarationRequest.type,(v,N)=>_(v,N,(0,V.attachWorkDone)(i,v),(0,V.attachPartialResult)(i,v))),onDefinition:_=>i.onRequest(M.DefinitionRequest.type,(v,N)=>_(v,N,(0,V.attachWorkDone)(i,v),(0,V.attachPartialResult)(i,v))),onTypeDefinition:_=>i.onRequest(M.TypeDefinitionRequest.type,(v,N)=>_(v,N,(0,V.attachWorkDone)(i,v),(0,V.attachPartialResult)(i,v))),onImplementation:_=>i.onRequest(M.ImplementationRequest.type,(v,N)=>_(v,N,(0,V.attachWorkDone)(i,v),(0,V.attachPartialResult)(i,v))),onReferences:_=>i.onRequest(M.ReferencesRequest.type,(v,N)=>_(v,N,(0,V.attachWorkDone)(i,v),(0,V.attachPartialResult)(i,v))),onDocumentHighlight:_=>i.onRequest(M.DocumentHighlightRequest.type,(v,N)=>_(v,N,(0,V.attachWorkDone)(i,v),(0,V.attachPartialResult)(i,v))),onDocumentSymbol:_=>i.onRequest(M.DocumentSymbolRequest.type,(v,N)=>_(v,N,(0,V.attachWorkDone)(i,v),(0,V.attachPartialResult)(i,v))),onWorkspaceSymbol:_=>i.onRequest(M.WorkspaceSymbolRequest.type,(v,N)=>_(v,N,(0,V.attachWorkDone)(i,v),(0,V.attachPartialResult)(i,v))),onWorkspaceSymbolResolve:_=>i.onRequest(M.WorkspaceSymbolResolveRequest.type,_),onCodeAction:_=>i.onRequest(M.CodeActionRequest.type,(v,N)=>_(v,N,(0,V.attachWorkDone)(i,v),(0,V.attachPartialResult)(i,v))),onCodeActionResolve:_=>i.onRequest(M.CodeActionResolveRequest.type,(v,N)=>_(v,N)),onCodeLens:_=>i.onRequest(M.CodeLensRequest.type,(v,N)=>_(v,N,(0,V.attachWorkDone)(i,v),(0,V.attachPartialResult)(i,v))),onCodeLensResolve:_=>i.onRequest(M.CodeLensResolveRequest.type,(v,N)=>_(v,N)),onDocumentFormatting:_=>i.onRequest(M.DocumentFormattingRequest.type,(v,N)=>_(v,N,(0,V.attachWorkDone)(i,v),void 0)),onDocumentRangeFormatting:_=>i.onRequest(M.DocumentRangeFormattingRequest.type,(v,N)=>_(v,N,(0,V.attachWorkDone)(i,v),void 0)),onDocumentOnTypeFormatting:_=>i.onRequest(M.DocumentOnTypeFormattingRequest.type,(v,N)=>_(v,N)),onRenameRequest:_=>i.onRequest(M.RenameRequest.type,(v,N)=>_(v,N,(0,V.attachWorkDone)(i,v),void 0)),onPrepareRename:_=>i.onRequest(M.PrepareRenameRequest.type,(v,N)=>_(v,N)),onDocumentLinks:_=>i.onRequest(M.DocumentLinkRequest.type,(v,N)=>_(v,N,(0,V.attachWorkDone)(i,v),(0,V.attachPartialResult)(i,v))),onDocumentLinkResolve:_=>i.onRequest(M.DocumentLinkResolveRequest.type,(v,N)=>_(v,N)),onDocumentColor:_=>i.onRequest(M.DocumentColorRequest.type,(v,N)=>_(v,N,(0,V.attachWorkDone)(i,v),(0,V.attachPartialResult)(i,v))),onColorPresentation:_=>i.onRequest(M.ColorPresentationRequest.type,(v,N)=>_(v,N,(0,V.attachWorkDone)(i,v),(0,V.attachPartialResult)(i,v))),onFoldingRanges:_=>i.onRequest(M.FoldingRangeRequest.type,(v,N)=>_(v,N,(0,V.attachWorkDone)(i,v),(0,V.attachPartialResult)(i,v))),onSelectionRanges:_=>i.onRequest(M.SelectionRangeRequest.type,(v,N)=>_(v,N,(0,V.attachWorkDone)(i,v),(0,V.attachPartialResult)(i,v))),onExecuteCommand:_=>i.onRequest(M.ExecuteCommandRequest.type,(v,N)=>_(v,N,(0,V.attachWorkDone)(i,v),void 0)),dispose:()=>i.dispose()};for(let _ of R)_.attach(L);return i.onRequest(M.InitializeRequest.type,_=>{t.initialize(_),lt.string(_.trace)&&(o.trace=M.Trace.fromString(_.trace));for(let v of R)v.initialize(_.capabilities);if(q){let v=q(_,new M.CancellationTokenSource().token,(0,V.attachWorkDone)(i,_),void 0);return D(v).then(N=>{if(N instanceof M.ResponseError)return N;let z=N;z||(z={capabilities:{}});let Z=z.capabilities;Z||(Z={},z.capabilities=Z),Z.textDocumentSync===void 0||Z.textDocumentSync===null?Z.textDocumentSync=lt.number(L.__textDocumentSync)?L.__textDocumentSync:M.TextDocumentSyncKind.None:!lt.number(Z.textDocumentSync)&&!lt.number(Z.textDocumentSync.change)&&(Z.textDocumentSync.change=lt.number(L.__textDocumentSync)?L.__textDocumentSync:M.TextDocumentSyncKind.None);for(let ue of R)ue.fillServerCapabilities(Z);return z})}else{let v={capabilities:{textDocumentSync:M.TextDocumentSyncKind.None}};for(let N of R)N.fillServerCapabilities(v.capabilities);return v}}),i.onRequest(M.ShutdownRequest.type,()=>{if(t.shutdownReceived=!0,T)return T(new M.CancellationTokenSource().token)}),i.onNotification(M.ExitNotification.type,()=>{try{B&&B()}finally{t.shutdownReceived?t.exit(0):t.exit(1)}}),i.onNotification(M.SetTraceNotification.type,_=>{o.trace=M.Trace.fromString(_.value)}),L}ne.createConnection=e_});var Uc=A(Be=>{"use strict";var t_=Be&&Be.__createBinding||(Object.create?function(e,t,n,r){r===void 0&&(r=n);var i=Object.getOwnPropertyDescriptor(t,n);(!i||("get"in i?!t.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:function(){return t[n]}}),Object.defineProperty(e,r,i)}:function(e,t,n,r){r===void 0&&(r=n),e[r]=t[n]}),ep=Be&&Be.__exportStar||function(e,t){for(var n in e)n!=="default"&&!Object.prototype.hasOwnProperty.call(t,n)&&t_(t,e,n)};Object.defineProperty(Be,"__esModule",{value:!0});Be.ProposedFeatures=Be.NotebookDocuments=Be.TextDocuments=Be.SemanticTokensBuilder=void 0;var n_=Sc();Object.defineProperty(Be,"SemanticTokensBuilder",{enumerable:!0,get:function(){return n_.SemanticTokensBuilder}});ep(qe(),Be);var r_=xc();Object.defineProperty(Be,"TextDocuments",{enumerable:!0,get:function(){return r_.TextDocuments}});var i_=kc();Object.defineProperty(Be,"NotebookDocuments",{enumerable:!0,get:function(){return i_.NotebookDocuments}});ep(Zf(),Be);var o_;(function(e){e.all={__brand:"features"}})(o_=Be.ProposedFeatures||(Be.ProposedFeatures={}))});var np=A((TS,tp)=>{"use strict";tp.exports=qe()});var op=A(Mt=>{"use strict";var s_=Mt&&Mt.__createBinding||(Object.create?function(e,t,n,r){r===void 0&&(r=n);var i=Object.getOwnPropertyDescriptor(t,n);(!i||("get"in i?!t.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:function(){return t[n]}}),Object.defineProperty(e,r,i)}:function(e,t,n,r){r===void 0&&(r=n),e[r]=t[n]}),ip=Mt&&Mt.__exportStar||function(e,t){for(var n in e)n!=="default"&&!Object.prototype.hasOwnProperty.call(t,n)&&s_(t,e,n)};Object.defineProperty(Mt,"__esModule",{value:!0});Mt.createConnection=void 0;var Oo=Uc();ip(np(),Mt);ip(Uc(),Mt);var rp=!1,a_={initialize:e=>{},get shutdownReceived(){return rp},set shutdownReceived(e){rp=e},exit:e=>{}};function c_(e,t,n,r){let i,o,s,u;e!==void 0&&e.__brand==="features"&&(i=e,e=t,t=n,n=r),Oo.ConnectionStrategy.is(e)||Oo.ConnectionOptions.is(e)?u=e:(o=e,s=t,u=n);let c=p=>(0,Oo.createProtocolConnection)(o,s,p,u);return(0,Oo.createConnection)(c,a_,i)}Mt.createConnection=c_});var ln=A((wS,sp)=>{"use strict";sp.exports=op()});var Xc=A((RT,vp)=>{"use strict";function jt(e){if(typeof e!="string")throw new TypeError("Path must be a string. Received "+JSON.stringify(e))}function bp(e,t){for(var n="",r=0,i=-1,o=0,s,u=0;u<=e.length;++u){if(u<e.length)s=e.charCodeAt(u);else{if(s===47)break;s=47}if(s===47){if(!(i===u-1||o===1))if(i!==u-1&&o===2){if(n.length<2||r!==2||n.charCodeAt(n.length-1)!==46||n.charCodeAt(n.length-2)!==46){if(n.length>2){var c=n.lastIndexOf("/");if(c!==n.length-1){c===-1?(n="",r=0):(n=n.slice(0,c),r=n.length-1-n.lastIndexOf("/")),i=u,o=0;continue}}else if(n.length===2||n.length===1){n="",r=0,i=u,o=0;continue}}t&&(n.length>0?n+="/..":n="..",r=2)}else n.length>0?n+="/"+e.slice(i+1,u):n=e.slice(i+1,u),r=u-i-1;i=u,o=0}else s===46&&o!==-1?++o:o=-1}return n}function B_(e,t){var n=t.dir||t.root,r=t.base||(t.name||"")+(t.ext||"");return n?n===t.root?n+r:n+e+r:r}var lr={resolve:function(){for(var t="",n=!1,r,i=arguments.length-1;i>=-1&&!n;i--){var o;i>=0?o=arguments[i]:(r===void 0&&(r=process.cwd()),o=r),jt(o),o.length!==0&&(t=o+"/"+t,n=o.charCodeAt(0)===47)}return t=bp(t,!n),n?t.length>0?"/"+t:"/":t.length>0?t:"."},normalize:function(t){if(jt(t),t.length===0)return".";var n=t.charCodeAt(0)===47,r=t.charCodeAt(t.length-1)===47;return t=bp(t,!n),t.length===0&&!n&&(t="."),t.length>0&&r&&(t+="/"),n?"/"+t:t},isAbsolute:function(t){return jt(t),t.length>0&&t.charCodeAt(0)===47},join:function(){if(arguments.length===0)return".";for(var t,n=0;n<arguments.length;++n){var r=arguments[n];jt(r),r.length>0&&(t===void 0?t=r:t+="/"+r)}return t===void 0?".":lr.normalize(t)},relative:function(t,n){if(jt(t),jt(n),t===n||(t=lr.resolve(t),n=lr.resolve(n),t===n))return"";for(var r=1;r<t.length&&t.charCodeAt(r)===47;++r);for(var i=t.length,o=i-r,s=1;s<n.length&&n.charCodeAt(s)===47;++s);for(var u=n.length,c=u-s,p=o<c?o:c,g=-1,b=0;b<=p;++b){if(b===p){if(c>p){if(n.charCodeAt(s+b)===47)return n.slice(s+b+1);if(b===0)return n.slice(s+b)}else o>p&&(t.charCodeAt(r+b)===47?g=b:b===0&&(g=0));break}var R=t.charCodeAt(r+b),D=n.charCodeAt(s+b);if(R!==D)break;R===47&&(g=b)}var T="";for(b=r+g+1;b<=i;++b)(b===i||t.charCodeAt(b)===47)&&(T.length===0?T+="..":T+="/..");return T.length>0?T+n.slice(s+g):(s+=g,n.charCodeAt(s)===47&&++s,n.slice(s))},_makeLong:function(t){return t},dirname:function(t){if(jt(t),t.length===0)return".";for(var n=t.charCodeAt(0),r=n===47,i=-1,o=!0,s=t.length-1;s>=1;--s)if(n=t.charCodeAt(s),n===47){if(!o){i=s;break}}else o=!1;return i===-1?r?"/":".":r&&i===1?"//":t.slice(0,i)},basename:function(t,n){if(n!==void 0&&typeof n!="string")throw new TypeError('"ext" argument must be a string');jt(t);var r=0,i=-1,o=!0,s;if(n!==void 0&&n.length>0&&n.length<=t.length){if(n.length===t.length&&n===t)return"";var u=n.length-1,c=-1;for(s=t.length-1;s>=0;--s){var p=t.charCodeAt(s);if(p===47){if(!o){r=s+1;break}}else c===-1&&(o=!1,c=s+1),u>=0&&(p===n.charCodeAt(u)?--u===-1&&(i=s):(u=-1,i=c))}return r===i?i=c:i===-1&&(i=t.length),t.slice(r,i)}else{for(s=t.length-1;s>=0;--s)if(t.charCodeAt(s)===47){if(!o){r=s+1;break}}else i===-1&&(o=!1,i=s+1);return i===-1?"":t.slice(r,i)}},extname:function(t){jt(t);for(var n=-1,r=0,i=-1,o=!0,s=0,u=t.length-1;u>=0;--u){var c=t.charCodeAt(u);if(c===47){if(!o){r=u+1;break}continue}i===-1&&(o=!1,i=u+1),c===46?n===-1?n=u:s!==1&&(s=1):n!==-1&&(s=-1)}return n===-1||i===-1||s===0||s===1&&n===i-1&&n===r+1?"":t.slice(n,i)},format:function(t){if(t===null||typeof t!="object")throw new TypeError('The "pathObject" argument must be of type Object. Received type '+typeof t);return B_("/",t)},parse:function(t){jt(t);var n={root:"",dir:"",base:"",ext:"",name:""};if(t.length===0)return n;var r=t.charCodeAt(0),i=r===47,o;i?(n.root="/",o=1):o=0;for(var s=-1,u=0,c=-1,p=!0,g=t.length-1,b=0;g>=o;--g){if(r=t.charCodeAt(g),r===47){if(!p){u=g+1;break}continue}c===-1&&(p=!1,c=g+1),r===46?s===-1?s=g:b!==1&&(b=1):s!==-1&&(b=-1)}return s===-1||c===-1||b===0||b===1&&s===c-1&&s===u+1?c!==-1&&(u===0&&i?n.base=n.name=t.slice(1,c):n.base=n.name=t.slice(u,c)):(u===0&&i?(n.name=t.slice(1,s),n.base=t.slice(1,c)):(n.name=t.slice(u,s),n.base=t.slice(u,c)),n.ext=t.slice(s,c)),u>0?n.dir=t.slice(0,u-1):i&&(n.dir="/"),n},sep:"/",delimiter:":",win32:null,posix:null};lr.posix=lr;vp.exports=lr});import{CONFIG_FILE_NAMES as $s,loadConfig as Th}from"@redocly/openapi-core";var nu;(()=>{"use strict";var e={470:i=>{function o(c){if(typeof c!="string")throw new TypeError("Path must be a string. Received "+JSON.stringify(c))}function s(c,p){for(var g,b="",R=0,D=-1,T=0,q=0;q<=c.length;++q){if(q<c.length)g=c.charCodeAt(q);else{if(g===47)break;g=47}if(g===47){if(!(D===q-1||T===1))if(D!==q-1&&T===2){if(b.length<2||R!==2||b.charCodeAt(b.length-1)!==46||b.charCodeAt(b.length-2)!==46){if(b.length>2){var B=b.lastIndexOf("/");if(B!==b.length-1){B===-1?(b="",R=0):R=(b=b.slice(0,B)).length-1-b.lastIndexOf("/"),D=q,T=0;continue}}else if(b.length===2||b.length===1){b="",R=0,D=q,T=0;continue}}p&&(b.length>0?b+="/..":b="..",R=2)}else b.length>0?b+="/"+c.slice(D+1,q):b=c.slice(D+1,q),R=q-D-1;D=q,T=0}else g===46&&T!==-1?++T:T=-1}return b}var u={resolve:function(){for(var c,p="",g=!1,b=arguments.length-1;b>=-1&&!g;b--){var R;b>=0?R=arguments[b]:(c===void 0&&(c=process.cwd()),R=c),o(R),R.length!==0&&(p=R+"/"+p,g=R.charCodeAt(0)===47)}return p=s(p,!g),g?p.length>0?"/"+p:"/":p.length>0?p:"."},normalize:function(c){if(o(c),c.length===0)return".";var p=c.charCodeAt(0)===47,g=c.charCodeAt(c.length-1)===47;return(c=s(c,!p)).length!==0||p||(c="."),c.length>0&&g&&(c+="/"),p?"/"+c:c},isAbsolute:function(c){return o(c),c.length>0&&c.charCodeAt(0)===47},join:function(){if(arguments.length===0)return".";for(var c,p=0;p<arguments.length;++p){var g=arguments[p];o(g),g.length>0&&(c===void 0?c=g:c+="/"+g)}return c===void 0?".":u.normalize(c)},relative:function(c,p){if(o(c),o(p),c===p||(c=u.resolve(c))===(p=u.resolve(p)))return"";for(var g=1;g<c.length&&c.charCodeAt(g)===47;++g);for(var b=c.length,R=b-g,D=1;D<p.length&&p.charCodeAt(D)===47;++D);for(var T=p.length-D,q=R<T?R:T,B=-1,L=0;L<=q;++L){if(L===q){if(T>q){if(p.charCodeAt(D+L)===47)return p.slice(D+L+1);if(L===0)return p.slice(D+L)}else R>q&&(c.charCodeAt(g+L)===47?B=L:L===0&&(B=0));break}var _=c.charCodeAt(g+L);if(_!==p.charCodeAt(D+L))break;_===47&&(B=L)}var v="";for(L=g+B+1;L<=b;++L)L!==b&&c.charCodeAt(L)!==47||(v.length===0?v+="..":v+="/..");return v.length>0?v+p.slice(D+B):(D+=B,p.charCodeAt(D)===47&&++D,p.slice(D))},_makeLong:function(c){return c},dirname:function(c){if(o(c),c.length===0)return".";for(var p=c.charCodeAt(0),g=p===47,b=-1,R=!0,D=c.length-1;D>=1;--D)if((p=c.charCodeAt(D))===47){if(!R){b=D;break}}else R=!1;return b===-1?g?"/":".":g&&b===1?"//":c.slice(0,b)},basename:function(c,p){if(p!==void 0&&typeof p!="string")throw new TypeError('"ext" argument must be a string');o(c);var g,b=0,R=-1,D=!0;if(p!==void 0&&p.length>0&&p.length<=c.length){if(p.length===c.length&&p===c)return"";var T=p.length-1,q=-1;for(g=c.length-1;g>=0;--g){var B=c.charCodeAt(g);if(B===47){if(!D){b=g+1;break}}else q===-1&&(D=!1,q=g+1),T>=0&&(B===p.charCodeAt(T)?--T==-1&&(R=g):(T=-1,R=q))}return b===R?R=q:R===-1&&(R=c.length),c.slice(b,R)}for(g=c.length-1;g>=0;--g)if(c.charCodeAt(g)===47){if(!D){b=g+1;break}}else R===-1&&(D=!1,R=g+1);return R===-1?"":c.slice(b,R)},extname:function(c){o(c);for(var p=-1,g=0,b=-1,R=!0,D=0,T=c.length-1;T>=0;--T){var q=c.charCodeAt(T);if(q!==47)b===-1&&(R=!1,b=T+1),q===46?p===-1?p=T:D!==1&&(D=1):p!==-1&&(D=-1);else if(!R){g=T+1;break}}return p===-1||b===-1||D===0||D===1&&p===b-1&&p===g+1?"":c.slice(p,b)},format:function(c){if(c===null||typeof c!="object")throw new TypeError('The "pathObject" argument must be of type Object. Received type '+typeof c);return function(p,g){var b=g.dir||g.root,R=g.base||(g.name||"")+(g.ext||"");return b?b===g.root?b+R:b+"/"+R:R}(0,c)},parse:function(c){o(c);var p={root:"",dir:"",base:"",ext:"",name:""};if(c.length===0)return p;var g,b=c.charCodeAt(0),R=b===47;R?(p.root="/",g=1):g=0;for(var D=-1,T=0,q=-1,B=!0,L=c.length-1,_=0;L>=g;--L)if((b=c.charCodeAt(L))!==47)q===-1&&(B=!1,q=L+1),b===46?D===-1?D=L:_!==1&&(_=1):D!==-1&&(_=-1);else if(!B){T=L+1;break}return D===-1||q===-1||_===0||_===1&&D===q-1&&D===T+1?q!==-1&&(p.base=p.name=T===0&&R?c.slice(1,q):c.slice(T,q)):(T===0&&R?(p.name=c.slice(1,D),p.base=c.slice(1,q)):(p.name=c.slice(T,D),p.base=c.slice(T,q)),p.ext=c.slice(D,q)),T>0?p.dir=c.slice(0,T-1):R&&(p.dir="/"),p},sep:"/",delimiter:":",win32:null,posix:null};u.posix=u,i.exports=u}},t={};function n(i){var o=t[i];if(o!==void 0)return o.exports;var s=t[i]={exports:{}};return e[i](s,s.exports,n),s.exports}n.d=(i,o)=>{for(var s in o)n.o(o,s)&&!n.o(i,s)&&Object.defineProperty(i,s,{enumerable:!0,get:o[s]})},n.o=(i,o)=>Object.prototype.hasOwnProperty.call(i,o),n.r=i=>{typeof Symbol<"u"&&Symbol.toStringTag&&Object.defineProperty(i,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(i,"__esModule",{value:!0})};var r={};(()=>{let i;n.r(r),n.d(r,{URI:()=>R,Utils:()=>ft}),typeof process=="object"?i=process.platform==="win32":typeof navigator=="object"&&(i=navigator.userAgent.indexOf("Windows")>=0);let o=/^\w[\w\d+.-]*$/,s=/^\//,u=/^\/\//;function c(j,x){if(!j.scheme&&x)throw new Error(`[UriError]: Scheme is missing: {scheme: "", authority: "${j.authority}", path: "${j.path}", query: "${j.query}", fragment: "${j.fragment}"}`);if(j.scheme&&!o.test(j.scheme))throw new Error("[UriError]: Scheme contains illegal characters.");if(j.path){if(j.authority){if(!s.test(j.path))throw new Error('[UriError]: If a URI contains an authority component, then the path component must either be empty or begin with a slash ("/") character')}else if(u.test(j.path))throw new Error('[UriError]: If a URI does not contain an authority component, then the path cannot begin with two slash characters ("//")')}}let p="",g="/",b=/^(([^:/?#]+?):)?(\/\/([^/?#]*))?([^?#]*)(\?([^#]*))?(#(.*))?/;class R{static isUri(x){return x instanceof R||!!x&&typeof x.authority=="string"&&typeof x.fragment=="string"&&typeof x.path=="string"&&typeof x.query=="string"&&typeof x.scheme=="string"&&typeof x.fsPath=="string"&&typeof x.with=="function"&&typeof x.toString=="function"}scheme;authority;path;query;fragment;constructor(x,H,I,ie,X,K=!1){typeof x=="object"?(this.scheme=x.scheme||p,this.authority=x.authority||p,this.path=x.path||p,this.query=x.query||p,this.fragment=x.fragment||p):(this.scheme=function(Ve,Ae){return Ve||Ae?Ve:"file"}(x,K),this.authority=H||p,this.path=function(Ve,Ae){switch(Ve){case"https":case"http":case"file":Ae?Ae[0]!==g&&(Ae=g+Ae):Ae=g}return Ae}(this.scheme,I||p),this.query=ie||p,this.fragment=X||p,c(this,K))}get fsPath(){return _(this,!1)}with(x){if(!x)return this;let{scheme:H,authority:I,path:ie,query:X,fragment:K}=x;return H===void 0?H=this.scheme:H===null&&(H=p),I===void 0?I=this.authority:I===null&&(I=p),ie===void 0?ie=this.path:ie===null&&(ie=p),X===void 0?X=this.query:X===null&&(X=p),K===void 0?K=this.fragment:K===null&&(K=p),H===this.scheme&&I===this.authority&&ie===this.path&&X===this.query&&K===this.fragment?this:new T(H,I,ie,X,K)}static parse(x,H=!1){let I=b.exec(x);return I?new T(I[2]||p,Z(I[4]||p),Z(I[5]||p),Z(I[7]||p),Z(I[9]||p),H):new T(p,p,p,p,p)}static file(x){let H=p;if(i&&(x=x.replace(/\\/g,g)),x[0]===g&&x[1]===g){let I=x.indexOf(g,2);I===-1?(H=x.substring(2),x=g):(H=x.substring(2,I),x=x.substring(I)||g)}return new T("file",H,x,p,p)}static from(x){let H=new T(x.scheme,x.authority,x.path,x.query,x.fragment);return c(H,!0),H}toString(x=!1){return v(this,x)}toJSON(){return this}static revive(x){if(x){if(x instanceof R)return x;{let H=new T(x);return H._formatted=x.external,H._fsPath=x._sep===D?x.fsPath:null,H}}return x}}let D=i?1:void 0;class T extends R{_formatted=null;_fsPath=null;get fsPath(){return this._fsPath||(this._fsPath=_(this,!1)),this._fsPath}toString(x=!1){return x?v(this,!0):(this._formatted||(this._formatted=v(this,!1)),this._formatted)}toJSON(){let x={$mid:1};return this._fsPath&&(x.fsPath=this._fsPath,x._sep=D),this._formatted&&(x.external=this._formatted),this.path&&(x.path=this.path),this.scheme&&(x.scheme=this.scheme),this.authority&&(x.authority=this.authority),this.query&&(x.query=this.query),this.fragment&&(x.fragment=this.fragment),x}}let q={58:"%3A",47:"%2F",63:"%3F",35:"%23",91:"%5B",93:"%5D",64:"%40",33:"%21",36:"%24",38:"%26",39:"%27",40:"%28",41:"%29",42:"%2A",43:"%2B",44:"%2C",59:"%3B",61:"%3D",32:"%20"};function B(j,x,H){let I,ie=-1;for(let X=0;X<j.length;X++){let K=j.charCodeAt(X);if(K>=97&&K<=122||K>=65&&K<=90||K>=48&&K<=57||K===45||K===46||K===95||K===126||x&&K===47||H&&K===91||H&&K===93||H&&K===58)ie!==-1&&(I+=encodeURIComponent(j.substring(ie,X)),ie=-1),I!==void 0&&(I+=j.charAt(X));else{I===void 0&&(I=j.substr(0,X));let Ve=q[K];Ve!==void 0?(ie!==-1&&(I+=encodeURIComponent(j.substring(ie,X)),ie=-1),I+=Ve):ie===-1&&(ie=X)}}return ie!==-1&&(I+=encodeURIComponent(j.substring(ie))),I!==void 0?I:j}function L(j){let x;for(let H=0;H<j.length;H++){let I=j.charCodeAt(H);I===35||I===63?(x===void 0&&(x=j.substr(0,H)),x+=q[I]):x!==void 0&&(x+=j[H])}return x!==void 0?x:j}function _(j,x){let H;return H=j.authority&&j.path.length>1&&j.scheme==="file"?`//${j.authority}${j.path}`:j.path.charCodeAt(0)===47&&(j.path.charCodeAt(1)>=65&&j.path.charCodeAt(1)<=90||j.path.charCodeAt(1)>=97&&j.path.charCodeAt(1)<=122)&&j.path.charCodeAt(2)===58?x?j.path.substr(1):j.path[1].toLowerCase()+j.path.substr(2):j.path,i&&(H=H.replace(/\//g,"\\")),H}function v(j,x){let H=x?L:B,I="",{scheme:ie,authority:X,path:K,query:Ve,fragment:Ae}=j;if(ie&&(I+=ie,I+=":"),(X||ie==="file")&&(I+=g,I+=g),X){let ce=X.indexOf("@");if(ce!==-1){let St=X.substr(0,ce);X=X.substr(ce+1),ce=St.lastIndexOf(":"),ce===-1?I+=H(St,!1,!1):(I+=H(St.substr(0,ce),!1,!1),I+=":",I+=H(St.substr(ce+1),!1,!0)),I+="@"}X=X.toLowerCase(),ce=X.lastIndexOf(":"),ce===-1?I+=H(X,!1,!0):(I+=H(X.substr(0,ce),!1,!0),I+=X.substr(ce))}if(K){if(K.length>=3&&K.charCodeAt(0)===47&&K.charCodeAt(2)===58){let ce=K.charCodeAt(1);ce>=65&&ce<=90&&(K=`/${String.fromCharCode(ce+32)}:${K.substr(3)}`)}else if(K.length>=2&&K.charCodeAt(1)===58){let ce=K.charCodeAt(0);ce>=65&&ce<=90&&(K=`${String.fromCharCode(ce+32)}:${K.substr(2)}`)}I+=H(K,!0,!1)}return Ve&&(I+="?",I+=H(Ve,!1,!1)),Ae&&(I+="#",I+=x?Ae:B(Ae,!1,!1)),I}function N(j){try{return decodeURIComponent(j)}catch{return j.length>3?j.substr(0,3)+N(j.substr(3)):j}}let z=/(%[0-9A-Za-z][0-9A-Za-z])+/g;function Z(j){return j.match(z)?j.replace(z,x=>N(x)):j}var ue=n(470);let ze=ue.posix||ue,dt="/";var ft;(function(j){j.joinPath=function(x,...H){return x.with({path:ze.join(x.path,...H)})},j.resolvePath=function(x,...H){let I=x.path,ie=!1;I[0]!==dt&&(I=dt+I,ie=!0);let X=ze.resolve(I,...H);return ie&&X[0]===dt&&!x.authority&&(X=X.substring(1)),x.with({path:X})},j.dirname=function(x){if(x.path.length===0||x.path===dt)return x;let H=ze.dirname(x.path);return H.length===1&&H.charCodeAt(0)===46&&(H=""),x.with({path:H})},j.basename=function(x){return ze.basename(x.path)},j.extname=function(x){return ze.extname(x.path)}})(ft||(ft={}))})(),nu=r})();var{URI:On,Utils:ye}=nu;import{CONFIG_FILE_NAMES as Fp}from"@redocly/openapi-core";var os={languageId:"yaml",filePattern:/\.ya?ml$/i},ss={languageId:"json",filePattern:/\.json$/i},is=class{constructor(){this.supportedLanguages=[os,ss];this.registerConfigFinder(async t=>{if(!this._fs)return;let n=[];for(let r of Fp)try{let i=ye.resolvePath(ye.dirname(Oe(t)),r);await this._fs.exists(i)&&n.push(i.toString())}catch{continue}if(n.length>1)throw new Error(`
68
68
  Multiple configuration files are not allowed.
69
69
  Found the following files: ${n.join(", ")}.
70
70
  Please use 'redocly.yaml' instead.
71
- `);return n[0]}),this.registerRootWorkspaceFolderURIGetter(async()=>"")}registerFileSystemProvider(t){this._fs=t}registerDocumentsProvider(t){this._documentManager=t}registerConfigFinder(t){this._findConfig=t}registerRootWorkspaceFolderURIGetter(t){this._getRootWorkspaceFolderURI=t}get fs(){if(!this._fs)throw new Error("FileSystemProvider not registered.");return this._fs}get documents(){if(!this._documentManager)throw new Error("DocumentsProvider not registered.");return this._documentManager}get findConfig(){return this._findConfig}get getRootWorkspaceFolderURI(){return this._getRootWorkspaceFolderURI}},Ie=new is;function ru(e,t){return ye.resolvePath(Oe(e)).toString()===ye.resolvePath(Oe(t)).toString()}function Oe(e){return Nn.parse(e)}function as(e){return Nn.parse(e).fsPath}function cs(e){let t=["https","http"],{scheme:n}=Nn.parse(e);return t.includes(n)}function On(e){return ye.basename(Oe(e))}async function iu(e,t="/"){let n=ye.resolvePath(Oe(t));for(;e.path!=="/";)try{(await Ie.fs.stat(ye.resolvePath(n,e.path))).isDirectory()||(e=ye.dirname(e));break}catch{e=ye.dirname(e)}return e}import{BaseResolver as Dh,Source as Wl,readFileFromUrl as Sh}from"@redocly/openapi-core";var gi=ot(pi(),1);import{isAbsoluteUrl as Ph}from"@redocly/openapi-core";function Al(e,t=100,n=!1){let r=new Map,i=new Map;function o(u,c,p){let g=i.get(u.uri),b=Date.now()-g;try{b<t&&b>=0?r.set(u.uri,setTimeout(()=>o(u,c,p),t-b)):(r.delete(u.uri),i.delete(u.uri),n||c(e(u)))}catch(R){p(R)}}function s(u){let c=r.get(u.uri),p=n&&!c;return i.set(u.uri,Date.now()),new Promise((g,b)=>{c||r.set(u.uri,setTimeout(()=>o(u,g,b),t)),p&&g(e(u))})}return s}function js(e){let t=new Set,n=r=>Array.isArray(n)?r.map(n):typeof r=="object"&&r!==null?t.has(r)?void 0:(t.add(r),Object.fromEntries(Object.entries(r).map(([i,o])=>[i,n(o)]))):r;return n(e)}function ql(e){return e==="$ref"}async function Ls(e,t){let n=Nn.parse(t);return ye.joinPath(n,e).toString()}async function Nl(e,t,n){for(let[r,{root:i}]of Object.entries(e))if(await Ls(i,n)===t)return r}function Ol(e){return typeof e=="string"}function mi(e){return typeof e=="function"}function El(e){return e?.kind===gi.Kind.MAP}function Is(e){return e?.kind===gi.Kind.MAPPING}function Fs(e){return e?.kind===gi.Kind.SEQ}function br(e,t){let n=t.singleQuoted?"'":'"';return`${n}${e}${n}`}function Ws(e){return Ph(e)||e.startsWith("file://")}var Cn=class{constructor(t,n,r,i){this._uri=t,this._languageId=n,this._version=r,this._content=i,this._lineOffsets=void 0}get uri(){return this._uri}get languageId(){return this._languageId}get version(){return this._version}getText(t){if(t){let n=this.offsetAt(t.start),r=this.offsetAt(t.end);return this._content.substring(n,r)}return this._content}update(t,n){for(let r of t)if(Cn.isIncremental(r)){let i=jl(r.range),o=this.offsetAt(i.start),s=this.offsetAt(i.end);this._content=this._content.substring(0,o)+r.text+this._content.substring(s,this._content.length);let u=Math.max(i.start.line,0),c=Math.max(i.end.line,0),p=this._lineOffsets,g=Ml(r.text,!1,o);if(c-u===g.length)for(let R=0,D=g.length;R<D;R++)p[R+u+1]=g[R];else g.length<1e4?p.splice(u+1,c-u,...g):this._lineOffsets=p=p.slice(0,u+1).concat(g,p.slice(c+1));let b=r.text.length-(s-o);if(b!==0)for(let R=u+1+g.length,D=p.length;R<D;R++)p[R]=p[R]+b}else if(Cn.isFull(r))this._content=r.text,this._lineOffsets=void 0;else throw new Error("Unknown change event received");this._version=n}getLineOffsets(){return this._lineOffsets===void 0&&(this._lineOffsets=Ml(this._content,!0)),this._lineOffsets}positionAt(t){t=Math.max(Math.min(t,this._content.length),0);let n=this.getLineOffsets(),r=0,i=n.length;if(i===0)return{line:0,character:t};for(;r<i;){let s=Math.floor((r+i)/2);n[s]>t?i=s:r=s+1}let o=r-1;return{line:o,character:t-n[o]}}offsetAt(t){let n=this.getLineOffsets();if(t.line>=n.length)return this._content.length;if(t.line<0)return 0;let r=n[t.line],i=t.line+1<n.length?n[t.line+1]:this._content.length;return Math.max(Math.min(r+t.character,i),r)}get lineCount(){return this.getLineOffsets().length}static isIncremental(t){let n=t;return n!=null&&typeof n.text=="string"&&n.range!==void 0&&(n.rangeLength===void 0||typeof n.rangeLength=="number")}static isFull(t){let n=t;return n!=null&&typeof n.text=="string"&&n.range===void 0&&n.rangeLength===void 0}},hi;(function(e){function t(i,o,s,u){return new Cn(i,o,s,u)}e.create=t;function n(i,o,s){if(i instanceof Cn)return i.update(o,s),i;throw new Error("TextDocument.update: document must be created by TextDocument.create")}e.update=n;function r(i,o){let s=i.getText(),u=Hs(o.map(_h),(g,b)=>{let R=g.range.start.line-b.range.start.line;return R===0?g.range.start.character-b.range.start.character:R}),c=0,p=[];for(let g of u){let b=i.offsetAt(g.range.start);if(b<c)throw new Error("Overlapping edit");b>c&&p.push(s.substring(c,b)),g.newText.length&&p.push(g.newText),c=i.offsetAt(g.range.end)}return p.push(s.substr(c)),p.join("")}e.applyEdits=r})(hi||(hi={}));function Hs(e,t){if(e.length<=1)return e;let n=e.length/2|0,r=e.slice(0,n),i=e.slice(n);Hs(r,t),Hs(i,t);let o=0,s=0,u=0;for(;o<r.length&&s<i.length;)t(r[o],i[s])<=0?e[u++]=r[o++]:e[u++]=i[s++];for(;o<r.length;)e[u++]=r[o++];for(;s<i.length;)e[u++]=i[s++];return e}function Ml(e,t,n=0){let r=t?[n]:[];for(let i=0;i<e.length;i++){let o=e.charCodeAt(i);(o===13||o===10)&&(o===13&&i+1<e.length&&e.charCodeAt(i+1)===10&&i++,r.push(n+i+1))}return r}function jl(e){let t=e.start,n=e.end;return t.line>n.line||t.line===n.line&&t.character>n.character?{start:n,end:t}:e}function _h(e){let t=jl(e.range);return t!==e.range?{newText:e.newText,range:t}:e}var Ll=new Map;function Il(e,t){return Ll.set(e,t)}function Fl(e){let t=[];for(let[n,r]of Ll.entries())r.dependencyPaths.has(e)&&t.push({documentPath:n,durationMS:r.durationMS});return t}async function Ht(e){let t=Ie.documents.get(e);if(t)return t;let n=await Ie.fs.readFile(Oe(e),"utf-8");return hi.create(e,"yaml",1,n)}function Us(e){return ss.filePattern.test(e)}function Rh(e){return os.filePattern.test(e)}var Ut=class extends Dh{resolveExternalRef(t,n){return Ws(n)?n:t&&Ws(t)?new URL(n,t).href:ye.resolvePath(ye.dirname(Oe(t)),n).toString()}async loadExternalRef(t){if(cs(t)){let{body:n,mimeType:r}=await Sh(t,{...this.config.http,customFetch:fetch});return new Wl(t,n,r)}return new Wl(t,(await Ht(t)).getText())}};var vr,yi,Bs,Hl;async function zs(e){let t=new Ut,n=await Ie.findConfig(e);return vr=await Th({configPath:n,externalRefResolver:t,processRawConfig:async({document:r,resolvedRefMap:i})=>{Bs=i,Hl=r}}),vr}async function Fn(){return vr||await zs(),{config:vr,configPath:yi,rootConfigDocument:Hl}}async function Ul(e,t){try{return yi=await Ie.findConfig(e),yi?await zs(yi):vr}catch(n){return t?.createEventHandleLoadConfigError?.(n?.message),zs("")}}function Cr(e){return Ys(e)?!0:!!Bs&&[...Bs.keys()].map(n=>n.split("::")?.[1]?.split("#")[0]).some(n=>ru(On(e),n))}function Ys(e){return $s.includes(On(e))}var Bl={hide:{type:"boolean",default:!1},component:{type:"string",enum:["radio","checkbox"],default:"checkbox"},label:{type:"string"},items:{type:"array",items:{type:"string"}}},Pr={type:"object",properties:Bl,additionalProperties:!1},Zt={type:"object",properties:{hide:{type:"boolean",default:!1},type:{type:"string",enum:["rating","sentiment","comment","reasons","mood","scale"],default:"sentiment"},settings:{type:"object",properties:{label:{type:"string"},submitText:{type:"string"},buttonText:{type:"string"},component:{type:"string",enum:["radio","checkbox"],default:"checkbox"},items:{type:"array",items:{type:"string"},minItems:1},leftScaleLabel:{type:"string"},rightScaleLabel:{type:"string"},reasons:{type:"object",properties:Object.assign(Object.assign({},Bl),{like:Pr,dislike:Pr,satisfied:Pr,neutral:Pr,dissatisfied:Pr}),additionalProperties:!1},comment:{type:"object",properties:{hide:{type:"boolean",default:!1},label:{type:"string"},likeLabel:{type:"string"},dislikeLabel:{type:"string"},satisfiedLabel:{type:"string"},neutralLabel:{type:"string"},dissatisfiedLabel:{type:"string"}},additionalProperties:!1}},additionalProperties:!1}},additionalProperties:!1};var Wn={type:"object",properties:{includeByName:{type:"array",items:{type:"string"}},excludeByName:{type:"array",items:{type:"string"}}},additionalProperties:!1},xh={type:"object",properties:{name:{type:"string"},items:Wn,queries:Wn,mutations:Wn,subscriptions:Wn,types:Wn,directives:Wn},required:["name"],additionalProperties:!1},wh={type:"object",properties:{requireExactGroups:{type:"boolean"},groups:{type:"array",items:xh},otherItemsGroupName:{type:"string"}},required:["requireExactGroups","groups","otherItemsGroupName"],additionalProperties:!1},Hn={type:"object",properties:{hidePaginationButtons:{type:"boolean"},menu:{type:"object",properties:Object.assign({},wh.properties),additionalProperties:!1},sidebar:{type:"object",properties:{hide:{type:"boolean"}}},apiLogo:{type:"object",properties:{imageUrl:{type:"string"},href:{type:"string"},altText:{type:"string"},backgroundColor:{type:"string"}}},jsonSamplesDepth:{type:"number"},samplesMaxInlineArgs:{type:"number"},licenseKey:{type:"string"},fieldExpandLevel:{type:"number"},baseUrlPath:{type:"string"},feedback:Zt},additionalProperties:!1};var kh={type:"object",properties:{languages:{type:"array",items:{type:"object",properties:{lang:{type:"string",enum:["curl","JavaScript","Node.js","Python","Java8+Apache","Java","C#","C#+Newtonsoft","PHP","Go","Ruby","R","Payload"]},label:{type:"string"},options:{type:"object",properties:{indent:{type:"string"},withImports:{type:"boolean"},withComments:{type:"boolean"},binary:{type:"boolean"},credentials:{type:"string",enum:["omit","same-origin","include"]}},additionalProperties:!1}},required:["lang"],additionalProperties:!1}},skipOptionalParameters:{type:"boolean"},withOAuth2Call:{type:"boolean"}},required:["languages"],additionalProperties:!1},Ah={type:"array",items:{type:"object",properties:{title:{type:"string"},url:{type:"string"}},required:["url"],additionalProperties:!1}},bi={type:"object",properties:{licenseKey:{type:"string"},hideLoading:{type:"boolean"},disableRouter:{type:"boolean"},hideSidebar:{type:"boolean"},feedback:Zt,hideReplay:{type:"boolean"},oAuth2RedirectURI:{type:"string",nullable:!0},corsProxyUrl:{type:"string"},sortRequiredPropsFirst:{type:"boolean"},sanitize:{type:"boolean"},hideDownloadButtons:{type:"boolean"},downloadUrls:Ah,onlyRequiredInSamples:{type:"boolean"},generatedSamplesMaxDepth:{oneOf:[{type:"number"},{type:"string"}]},showExtensions:{oneOf:[{type:"boolean"},{type:"string"},{type:"array",items:{type:"string"}}]},hideSchemaTitles:{type:"boolean"},jsonSamplesExpandLevel:{oneOf:[{type:"number"},{type:"string"}]},schemasExpansionLevel:{oneOf:[{type:"number"},{type:"string"}]},mockServer:{type:"object",properties:{url:{type:"string"},position:{type:"string",enum:["first","last","replace","off"]},description:{type:"string"}}},maxDisplayedEnumValues:{type:"number"},schemaDefinitionsTagName:{type:"string"},layout:{type:"string",enum:["stacked","three-panel"]},hideInfoMetadata:{type:"boolean"},events:{type:"object"},skipBundle:{type:"boolean"},routingBasePath:{type:"string"},codeSamples:kh,ignoreNamedSchemas:{oneOf:[{type:"array",items:{type:"string"}},{type:"string"}]},hidePropertiesPrefix:{type:"boolean"},excludeFromSearch:{type:"boolean"}},additionalProperties:!1};var qh={type:"object",properties:{label:{type:"string"},lang:{enum:["curl","C#","Go","Java","Java8+Apache","JavaScript","Node.js","PHP","Python","R","Ruby"]}},required:["lang"]},Nh={type:"object",properties:{enum:{type:"string"},enumSingleValue:{type:"string"},enumArray:{type:"string"},default:{type:"string"},deprecated:{type:"string"},example:{type:"string"},examples:{type:"string"},nullable:{type:"string"},recursive:{type:"string"},arrayOf:{type:"string"},webhook:{type:"string"},authorizations:{type:"string"},tryItAuthBasicUsername:{type:"string"},tryItAuthBasicPassword:{type:"string"}}},zl={type:"object",properties:{label:{type:"string"},link:{type:"string"},target:{type:"string"}},required:["label","link"]},Oh={type:"object",properties:{beforeInfo:{type:"array",items:zl},end:{type:"array",items:zl}}},Pn={type:"object",properties:{main:{type:"string"},light:{type:"string"},dark:{type:"string"},contrastText:{type:"string"}}},vi={type:"object",properties:{backgroundColor:{type:"string"},borderColor:{type:"string"},color:{type:"string"},tabTextColor:{type:"string"}}},Eh={type:"object",properties:Ri(Pn.properties,["light","dark"])},Mh={type:"object",properties:{basic:{type:"string"},delete:{type:"string"},get:{type:"string"},head:{type:"string"},link:{type:"string"},options:{type:"string"},patch:{type:"string"},post:{type:"string"},put:{type:"string"}}},jh={type:"object",properties:{error:vi,info:vi,redirect:vi,success:vi}},Lh={type:"object",properties:Un(Pn.properties,["dark"])},Ih={type:"object",properties:{primary:{type:"string"},secondary:{type:"string"},light:{type:"string"}}},Fh={type:"object",properties:{accent:Pn,border:Eh,error:Pn,http:Mh,primary:Pn,responses:jh,secondary:Lh,success:Pn,text:Ih,tonalOffset:{type:"number"},warning:Pn}},Ci={type:"object",properties:{fontSize:{type:"string"},padding:{type:"string"},minWidth:{type:"string"}}},Wh={type:"object",properties:{small:Ci,medium:Ci,large:Ci,xlarge:Ci}},kt={type:"object",properties:{fontFamily:{type:"string"},fontSize:{type:"string"},fontWeight:{type:"string"},lineHeight:{type:"string"}}},Hh={type:"object",properties:Object.assign(Object.assign({},Un(kt.properties,["fontSize","lineHeight"])),{borderRadius:{type:"string"},hoverStyle:{type:"string"},boxShadow:{type:"string"},hoverBoxShadow:{type:"string"},sizes:Wh})},$l={type:"object",properties:Ri(kt.properties,["fontSize","lineHeight"])},Uh={type:"object",properties:{medium:$l,small:$l}},Bh={type:"object",properties:Object.assign(Object.assign({},Un(kt.properties,["fontSize","lineHeight"])),{borderRadius:{type:"string"},color:{type:"string"},sizes:Uh})},zh={type:"object",properties:{top:{type:"string"},width:{type:"string"},height:{type:"string"}}},$h={type:"object",properties:{borderRadius:{type:"string"},backgroundColor:{type:"string"}}},Yl={type:"object",properties:{fullWidth:{type:"boolean"}}},Yh={type:"object",properties:{buttons:Hh,httpBadges:Bh,layoutControls:zh,panels:$h,tryItButton:Yl,tryItSendButton:Yl}},_i={type:"object",properties:{small:{type:"string"},medium:{type:"string"},large:{type:"string"}}},Vh={type:"object",properties:{maxWidth:_i}},Kh={type:"object",properties:{maxWidth:_i,middlePanelMaxWidth:_i}},Gh={type:"object",properties:{showDarkRightPanel:{type:"boolean"},stacked:Vh,"three-panel":Kh}},Vl={type:"object",properties:{backgroundColor:{type:"string"},border:{type:"string"}}},Jh={type:"object",properties:{breakFieldNames:{type:"boolean"},caretColor:{type:"string"},caretSize:{type:"string"},constraints:Vl,defaultDetailsWidth:{type:"string"},examples:Vl,labelsTextSize:{type:"string"},linesColor:{type:"string"},nestedBackground:{type:"string"},nestingSpacing:{type:"string"},requireLabelColor:{type:"string"},typeNameColor:{type:"string"},typeTitleColor:{type:"string"}}},Gl={type:"object",properties:{subItemsColor:{type:"string"},textTransform:{type:"string"},fontWeight:{type:"string"}}},Qh={type:"object",properties:Ri(Gl.properties,["textTransform"])},Xh={type:"object",properties:{unit:{type:"number"},paddingHorizontal:{type:"string"},paddingVertical:{type:"string"},offsetTop:{type:"string"},offsetLeft:{type:"string"},offsetNesting:{type:"string"}}},Zh={type:"object",properties:Object.assign(Object.assign({},Un(kt.properties,["fontWeight","lineHeight"])),{activeBgColor:{type:"string"},activeTextColor:{type:"string"},backgroundColor:{type:"string"},borderRadius:{type:"string"},breakPath:{type:"boolean"},caretColor:{type:"string"},caretSize:{type:"string"},groupItems:Gl,level1items:Qh,rightLineColor:{type:"string"},separatorLabelColor:{type:"string"},showAtBreakpoint:{type:"string"},spacing:Xh,textColor:{type:"string"},width:{type:"string"}})},Pi={type:"object",properties:Object.assign(Object.assign({},kt.properties),{color:{type:"string"},transform:{type:"string"}})},ey={type:"object",properties:Object.assign(Object.assign({},kt.properties),{backgroundColor:{type:"string"},color:{type:"string"},wordBreak:{type:"string",enum:["break-all","break-word","keep-all","normal","revert","unset","inherit","initial"]},wrap:{type:"boolean"}})},ty={type:"object",properties:Un(kt.properties,["fontSize"])},ny={type:"object",properties:{color:{type:"string"},hover:{type:"string"},textDecoration:{type:"string"},hoverTextDecoration:{type:"string"},visited:{type:"string"}}},ry={type:"object",properties:Object.assign(Object.assign({code:ey,fieldName:kt},Ri(kt.properties,["fontSize","fontFamily"])),{fontWeightBold:{type:"string"},fontWeightLight:{type:"string"},fontWeightRegular:{type:"string"},heading1:Pi,heading2:Pi,heading3:Pi,headings:ty,lineHeight:{type:"string"},links:ny,optimizeSpeed:{type:"boolean"},rightPanelHeading:Pi,smoothing:{type:"string",enum:["auto","none","antialiased","subpixel-antialiased","grayscale"]}})},iy={type:"object",properties:Object.assign({color:{type:"string"}},Un(kt.properties,["fontWeight"]))},oy={type:"object",properties:{backgroundColor:{type:"string"},borderRadius:{type:"string"},tokens:iy}},sy={type:"object",properties:{gutter:{type:"string"},maxHeight:{type:"string"},maxWidth:{type:"string"}}},ay={type:"object",properties:{backgroundColor:{type:"string"},color:{type:"string"}}},Kl={type:"object",properties:{custom:{type:"string"}}},cy={type:"object",properties:{DownloadButton:Kl,NextSectionButton:Kl}},uy={type:"object",properties:{backgroundColor:{type:"string"},panelBackgroundColor:{type:"string"},panelControlsBackgroundColor:{type:"string"},showAtBreakpoint:{type:"string"},textColor:{type:"string"},width:{type:"string"}}},ly={type:"object",properties:{borderRadius:{type:"string"}}},dy={type:"object",properties:{sectionHorizontal:{type:"number"},sectionVertical:{type:"number"},unit:{type:"number"}}},fy={type:"object",properties:{breakpoints:_i,codeBlock:oy,colors:Fh,components:Yh,layout:Gh,logo:sy,fab:ay,overrides:cy,rightPanel:uy,schema:Jh,shape:ly,sidebar:Zh,spacing:dy,typography:ry,links:{properties:{color:{type:"string"}}},codeSample:{properties:{backgroundColor:{type:"string"}}}}},py={type:"object",properties:{skipOptionalParameters:{type:"boolean"},languages:{type:"array",items:qh}},required:["languages"]},Jl={type:"object",properties:{theme:fy,ctrlFHijack:{type:"boolean"},defaultSampleLanguage:{type:"string"},disableDeepLinks:{type:"boolean"},disableSearch:{type:"boolean"},disableSidebar:{type:"boolean"},downloadDefinitionUrl:{type:"string"},expandDefaultServerVariables:{type:"boolean"},enumSkipQuotes:{type:"boolean"},expandDefaultRequest:{type:"boolean"},expandDefaultResponse:{type:"boolean"},expandResponses:{type:"string"},expandSingleSchemaField:{type:"boolean"},generateCodeSamples:py,generatedPayloadSamplesMaxDepth:{type:"number"},hideDownloadButton:{type:"boolean"},hideHostname:{type:"boolean"},hideInfoSection:{type:"boolean"},hideLogo:{type:"boolean"},hideRequestPayloadSample:{type:"boolean"},hideRightPanel:{type:"boolean"},hideSchemaPattern:{type:"boolean"},hideSingleRequestSampleTab:{type:"boolean"},hideSecuritySection:{type:"boolean"},hideTryItPanel:{type:"boolean"},hideFab:{type:"boolean"},hideOneOfDescription:{type:"boolean"},htmlTemplate:{type:"string"},jsonSampleExpandLevel:{oneOf:[{type:"number",minimum:1},{type:"string"}]},labels:Nh,menuToggle:{type:"boolean"},nativeScrollbars:{type:"boolean"},noAutoAuth:{type:"boolean"},onDeepLinkClick:{type:"object"},pagination:{enum:["none","section","item"]},pathInMiddlePanel:{type:"boolean"},payloadSampleIdx:{type:"number",minimum:0},requestInterceptor:{type:"object"},requiredPropsFirst:{type:"boolean"},routingStrategy:{type:"string"},samplesTabsMaxCount:{type:"number"},schemaExpansionLevel:{oneOf:[{type:"number",minimum:0},{type:"string"}]},minCharacterLengthToInitSearch:{type:"number",minimum:1},maxResponseHeadersToShowInTryIt:{type:"number",minimum:0},scrollYOffset:{oneOf:[{type:"number"},{type:"string"}]},searchAutoExpand:{type:"boolean"},searchFieldLevelBoost:{type:"number",minimum:0},searchMaxDepth:{type:"number",minimum:1},searchMode:{type:"string",enum:["default","path-only"]},searchOperationTitleBoost:{type:"number"},searchTagTitleBoost:{type:"number"},sendXUserAgentInTryIt:{type:"boolean"},showChangeLayoutButton:{type:"boolean"},showConsole:{type:"boolean"},showNextButton:{type:"boolean"},showRightPanelToggle:{type:"boolean"},showSecuritySchemeType:{type:"boolean"},showWebhookVerb:{type:"boolean"},showObjectSchemaExamples:{type:"boolean"},disableTryItRequestUrlEncoding:{type:"boolean"},sidebarLinks:Oh,sideNavStyle:{type:"string",enum:["summary-only","path-first","id-only"]},simpleOneOfTypeLabel:{type:"boolean"},sortEnumValuesAlphabetically:{type:"boolean"},sortOperationsAlphabetically:{type:"boolean"},sortPropsAlphabetically:{type:"boolean"},sortTagsAlphabetically:{type:"boolean"},suppressWarnings:{type:"boolean"},unstable_externalDescription:{type:"boolean"},unstable_ignoreMimeParameters:{type:"boolean"},untrustedDefinition:{type:"boolean"},showAccessMode:{type:"boolean"},preserveOriginalExtensionsName:{type:"boolean"},markdownHeadingsAnchorLevel:{type:"number"}},additionalProperties:!1};function Ri(e,t){return Object.fromEntries(t.filter(n=>n in e).map(n=>[n,e[n]]))}function Un(e,t){return Object.fromEntries(Object.entries(e).filter(([n])=>!t.includes(n)))}var $e={type:"object",properties:{hide:{type:"boolean"}},additionalProperties:!1},Ql={type:"object",properties:{src:{type:"string"},async:{type:"boolean"},crossorigin:{type:"string"},defer:{type:"boolean"},fetchpriority:{type:"string"},integrity:{type:"string"},module:{type:"boolean"},nomodule:{type:"boolean"},nonce:{type:"string"},referrerpolicy:{type:"string"},type:{type:"string"}},required:["src"],additionalProperties:!0},Vs={type:"object",properties:{page:{type:"string"},directory:{type:"string"},disconnect:{type:"boolean",default:!1},group:{type:"string"},label:{type:"string"},href:{type:"string"},external:{type:"boolean"},labelTranslationKey:{type:"string"},groupTranslationKey:{type:"string"},icon:{oneOf:[{type:"string"},{type:"object",properties:{srcSet:{type:"string"}},required:["srcSet"]}]},separator:{type:"string"},separatorLine:{type:"boolean"},linePosition:{type:"string",enum:["top","bottom"],default:"top"},version:{type:"string"},menuStyle:{type:"string",enum:["drilldown"]},expanded:{type:"string",const:"always"},selectFirstItemOnExpand:{type:"boolean"},flatten:{type:"boolean"},linkedSidebars:{type:"array",items:{type:"string"}},items:{type:"array",items:{type:"object",additionalProperties:!0}}}},Ks={type:"array",items:Object.assign(Object.assign({},Vs),{properties:Object.assign(Object.assign({},Vs.properties),{items:{type:"array",items:Vs}})})},gy={type:"object",properties:{name:{type:"string"},icon:{type:"string"},folder:{type:"string"}},additionalProperties:!1,required:["name","folder"]},my={type:"object",properties:{hide:{type:"boolean",default:!1},prompt:{type:"string"}},additionalProperties:!1},hy={type:"array",items:{type:"object",required:["name","field","type"],properties:{name:{type:"string"},field:{type:"string"},type:{type:"string",enum:["multi-select","select","tags"]},isTop:{type:"boolean"}},additionalProperties:!1}},yy={type:"object",properties:{page:{type:"string"},label:{type:"string"},labelTranslationKey:{type:"string"}},required:["page"]},Di={type:"object",properties:{image:{type:"string"},srcSet:{type:"string"},altText:{type:"string"},link:{type:"string"},favicon:{type:"string"}},additionalProperties:!1},Si={type:"object",properties:Object.assign({items:Ks},$e.properties),additionalProperties:!1},Ti={type:"object",additionalProperties:gy},xi={type:"object",properties:Object.assign({items:Ks,copyrightText:{type:"string"},logo:$e},$e.properties),additionalProperties:!1},wi={type:"object",properties:Object.assign({separatorLine:{type:"boolean"},linePosition:{type:"string",enum:["top","bottom"],default:"bottom"}},$e.properties),additionalProperties:!1},ki={type:"object",properties:{head:{type:"array",items:Ql},body:{type:"array",items:Ql}},additionalProperties:!1},Ai={type:"array",items:{type:"object",properties:{href:{type:"string"},as:{type:"string"},crossorigin:{type:"string"},fetchpriority:{type:"string"},hreflang:{type:"string"},imagesizes:{type:"string"},imagesrcset:{type:"string"},integrity:{type:"string"},media:{type:"string"},prefetch:{type:"string"},referrerpolicy:{type:"string"},rel:{type:"string"},sizes:{type:"string"},title:{type:"string"},type:{type:"string"}},required:["href"],additionalProperties:!0}},qi={type:"object",properties:Object.assign({engine:{type:"string",enum:["flexsearch","typesense"],default:"flexsearch"},ai:my,facets:hy,placement:{type:"string",default:"navbar"},shortcuts:{type:"array",items:{type:"string"},default:["/"]},suggestedPages:{type:"array",items:yy}},$e.properties),additionalProperties:!1},Ni={type:"object",properties:Object.assign({ignoreDetection:{type:"boolean"},modes:{type:"array",items:{type:"string"},default:["light","dark"]}},$e.properties),additionalProperties:!1},Oi={type:"object",properties:{nextButton:{type:"object",properties:Object.assign({text:{type:"string",default:"Next page"}},$e.properties),additionalProperties:!1,default:{}},previousButton:{type:"object",properties:Object.assign({text:{type:"string",default:"Previous page"}},$e.properties),additionalProperties:!1,default:{}}},additionalProperties:!1},Ei={type:"object",properties:{elementFormat:{type:"string",default:"icon"},copy:{type:"object",properties:Object.assign({},$e.properties),additionalProperties:!1,default:{hide:!1}},report:{type:"object",properties:Object.assign({tooltipText:{type:"string"},buttonText:{type:"string"},label:{type:"string"}},$e.properties),additionalProperties:!1,default:{hide:!1}},expand:{type:"object",properties:Object.assign({},$e.properties),additionalProperties:!1,default:{hide:!1}},collapse:{type:"object",properties:Object.assign({},$e.properties),additionalProperties:!1,default:{hide:!1}}},additionalProperties:!1},Mi={type:"object",properties:{frontMatterKeysToResolve:{type:"array",items:{type:"string"},default:["image","links"]},partialsFolders:{type:"array",items:{type:"string"},default:["_partials"]},lastUpdatedBlock:{type:"object",properties:Object.assign({format:{type:"string",enum:["timeago","iso","long","short"],default:"timeago"},locale:{type:"string"}},$e.properties),additionalProperties:!1,default:{}},toc:{type:"object",properties:Object.assign({header:{type:"string",default:"On this page"},depth:{type:"integer",default:3,minimum:1}},$e.properties),additionalProperties:!1,default:{}},editPage:{type:"object",properties:Object.assign({baseUrl:{type:"string"}},$e.properties),additionalProperties:!1,default:{}}},additionalProperties:!1,default:{}},Bn=Object.assign(Object.assign({},bi),{properties:Object.assign(Object.assign({},bi.properties),Jl.properties)}),by={type:"object",properties:{includeInDevelopment:{type:"boolean"},scriptUrl:{type:"string"},pageViewEventName:{type:"string"}},additionalProperties:!1,required:["scriptUrl"]},vy={type:"object",properties:{includeInDevelopment:{type:"boolean"},apiKey:{type:"string"},head:{type:"boolean"},respectDNT:{type:"boolean"},exclude:{type:"array",items:{type:"string"}},outboundClickEventName:{type:"string"},pageViewEventName:{type:"string"},amplitudeConfig:{type:"object",additionalProperties:!0}},additionalProperties:!1,required:["apiKey"]},Cy={type:"object",properties:{includeInDevelopment:{type:"boolean"},orgId:{type:"string"}},additionalProperties:!1,required:["orgId"]},Py={type:"object",properties:{includeInDevelopment:{type:"boolean"},appId:{type:"string"}},additionalProperties:!1,required:["appId"]},_y={type:"object",properties:{includeInDevelopment:{type:"boolean"},writeKey:{type:"string",minLength:10},trackPage:{type:"boolean"},dataPlaneUrl:{type:"string"},controlPlaneUrl:{type:"string"},sdkUrl:{type:"string"},loadOptions:{type:"object",additionalProperties:!0}},additionalProperties:!1,required:["writeKey"]},Ry={type:"object",properties:{includeInDevelopment:{type:"boolean"},writeKey:{type:"string",minLength:10},trackPage:{type:"boolean"},includeTitleInPageCall:{type:"boolean"},host:{type:"string"}},additionalProperties:!1,required:["writeKey"]},Dy={type:"object",properties:{includeInDevelopment:{type:"boolean"},trackingId:{type:"string"},gtmAuth:{type:"string"},gtmPreview:{type:"string"},defaultDataLayer:{},dataLayerName:{type:"string"},enableWebVitalsTracking:{type:"boolean"},selfHostedOrigin:{type:"string"},pageViewEventName:{type:"string"}},additionalProperties:!1,required:["trackingId"]},Gs={type:"object",properties:{includeInDevelopment:{type:"boolean"},trackingId:{type:"string"},conversionId:{type:"string"},floodlightId:{type:"string"},optimizeId:{type:"string"},exclude:{type:"array",items:{type:"string"}}},additionalProperties:!1,required:["trackingId"]},Sy={type:"object",properties:{includeInDevelopment:{type:"boolean"},trackingId:{type:"string"},conversionId:{type:"string"},floodlightId:{type:"string"},head:{type:"boolean"},respectDNT:{type:"boolean"},exclude:{type:"array",items:{type:"string"}},optimizeId:{type:"string"},anonymizeIp:{type:"boolean"},cookieExpires:{type:"number"},trackers:{type:"object",additionalProperties:Gs}},additionalProperties:!1,required:["trackingId"]},ji={type:"object",properties:{adobe:by,amplitude:vy,fullstory:Cy,heap:Py,rudderstack:_y,segment:Ry,gtm:Dy,ga:Sy}},Li={type:"object",properties:Object.assign({items:{type:"array",items:{type:"object",properties:{label:{type:"string"},external:{type:"boolean"},link:{type:"string"},separatorLine:{type:"boolean"}},additionalProperties:!0},default:[]},hideLoginButton:{type:"boolean"}},$e.properties),additionalProperties:!1},Ii={type:"object",properties:{hide:{type:"boolean"},showForUnversioned:{type:"boolean"}}},Fi={type:"object",properties:{hide:{type:"boolean"},prefixItems:{type:"array",items:{type:"object",properties:{label:{type:"string"},labelTranslationKey:{type:"string"},page:{type:"string"}},additionalProperties:!1,default:{}}}},additionalProperties:!1},Ty={type:"object",additionalProperties:!1,required:["title","property"],properties:{type:{type:"string",enum:["select","checkboxes","date-range"],default:"checkboxes"},title:{type:"string"},titleTranslationKey:{type:"string"},property:{type:"string"},parentFilter:{type:"string"},valuesMapping:{type:"object",additionalProperties:{type:"string"}},missingCategoryName:{type:"string"},missingCategoryNameTranslationKey:{type:"string"},options:{type:"array",items:{type:"string"}}}},xy={type:"object",additionalProperties:!0,required:["slug","items"],properties:{slug:{type:"string"},filters:{type:"array",items:Ty},groupByFirstFilter:{type:"boolean"},filterValuesCasing:{type:"string",enum:["sentence","original","lowercase","uppercase"]},items:Ks,requiredPermission:{type:"string"},separateVersions:{type:"boolean"},title:{type:"string"},titleTranslationKey:{type:"string"},description:{type:"string"},descriptionTranslationKey:{type:"string"}}},Wi={type:"object",patternProperties:{".*":xy}},Hi={type:"object",additionalProperties:!0,required:[],properties:{ignoreNonCompliant:{type:"boolean",default:!1},teamMetadataProperty:{type:"object",properties:{property:{type:"string"},label:{type:"string"},default:{type:"string"}}},levels:{type:"array",items:{type:"object",required:["name"],properties:{name:{type:"string"},color:{type:"string"},extends:{type:"array",items:{type:"string"}},rules:{type:"object",additionalProperties:{oneOf:[{type:"string"},{type:"object"}]}}},additionalProperties:!1}},targets:{type:"array",items:{type:"object",required:["where"],properties:{minimumLevel:{type:"string"},rules:{type:"object",additionalProperties:!0},where:{type:"object",required:["metadata"],properties:{metadata:{type:"object",additionalProperties:{type:"string"}}},additionalProperties:!1}},additionalProperties:!1}},ignore:{type:"array",items:{type:"string"}}}};var nt={type:"object",properties:{imports:{type:"array",items:{type:"string"}},logo:Di,navbar:Si,products:Ti,footer:xi,sidebar:wi,scripts:ki,links:Ai,feedback:Zt,search:qi,colorMode:Ni,navigation:Oi,codeSnippet:Ei,markdown:Mi,openapi:Bn,graphql:Hn,analytics:ji,userMenu:Li,versionPicker:Ii,breadcrumbs:Fi,catalog:Wi,scorecard:Hi},additionalProperties:!0},AR=Object.assign(Object.assign({},nt),{additionalProperties:!1});var Qs="https://redocly.com/sso/teams",zn;(function(e){e.OIDC="OIDC",e.SAML2="SAML2"})(zn||(zn={}));var $n;(function(e){e.SERVICE_ACCOUNT="SERVICE_ACCOUNT",e.OAUTH2="OAUTH2"})($n||($n={}));var Js;(function(e){e.STACKED="stacked",e.THREE_PANEL="three-panel"})(Js||(Js={}));function Ui(e,t){return Object.fromEntries(Object.entries(e).map(([n,r])=>{if(n!==t)return typeof r!="object"||!r?[n,r]:Array.isArray(r)?[n,r.map(i=>typeof i=="object"?Ui(i,t):i)]:[n,Ui(r,t)]}).filter(Boolean))}var wy={type:"object",additionalProperties:{type:"string"}},ky={type:"object",additionalProperties:!1,properties:{event:{type:"string",enum:["schedule"]},interval:{type:"string",pattern:"^[1-9]\\d*[mhdw]$"}},required:["event"]},Xl={type:"object",properties:{ignoreLint:{oneOf:[{type:"boolean",default:!1},{type:"object",additionalProperties:{type:"boolean"}}]},ignoreLinkChecker:{type:"boolean"},ignoreMarkdocErrors:{type:"boolean"},jobs:{type:"array",items:{type:"object",properties:{path:{type:"string",pattern:"^(?!\\.\\./)(/[a-zA-Z0-9_\\-\\./]+|./[a-zA-Z0-9_\\-\\./]+|[a-zA-Z0-9_\\-\\./]+)$"},agent:{type:"string",enum:["spot"]},trigger:ky,inputs:wy},required:["path","trigger","agent"],additionalProperties:!1}}},additionalProperties:!1};var Ay={type:"object",properties:{end_session_endpoint:{type:"string"},token_endpoint:{type:"string"},authorization_endpoint:{type:"string"},jwks_uri:{type:"string"}},required:["token_endpoint","authorization_endpoint"],additionalProperties:!0},qy={type:"object",properties:{type:{type:"string",const:zn.OIDC},title:{type:"string"},pkce:{type:"boolean",default:!1},configurationUrl:{type:"string",minLength:1},configuration:Ay,clientId:{type:"string",minLength:1},clientSecret:{type:"string",minLength:0},teamsClaimName:{type:"string"},teamsClaimMap:{type:"object",additionalProperties:{type:"string"}},defaultTeams:{type:"array",items:{type:"string"}},scopes:{type:"array",items:{type:"string"}},tokenExpirationTime:{type:"number"},authorizationRequestCustomParams:{type:"object",additionalProperties:{type:"string"}},tokenRequestCustomParams:{type:"object",additionalProperties:{type:"string"}},audience:{type:"array",items:{type:"string"}}},required:["type","clientId"],oneOf:[{required:["configurationUrl"]},{required:["configuration"]}],additionalProperties:!1},Ny={type:"object",properties:{type:{type:"string",const:zn.SAML2},title:{type:"string"},issuerId:{type:"string"},entityId:{type:"string"},ssoUrl:{type:"string"},x509PublicCert:{type:"string"},teamsAttributeName:{type:"string",default:Qs},teamsAttributeMap:{type:"object",additionalProperties:{type:"string"}},defaultTeams:{type:"array",items:{type:"string"}}},additionalProperties:!1,required:["type","issuerId","ssoUrl","x509PublicCert"]},Oy={oneOf:[qy,Ny],discriminator:{propertyName:"type"}},Ey={type:"object",additionalProperties:Oy},My={oneOf:[{type:"array",items:{type:"string",enum:["REDOCLY","CORPORATE","GUEST"]},uniqueItems:!0},{type:"string",enum:["REDOCLY","CORPORATE","GUEST"]}]},jy={type:"object",properties:{to:{type:"string"},type:{type:"number",default:301}},additionalProperties:!1},Ly={type:"object",additionalProperties:jy,default:{}},ed={type:"object",additionalProperties:{oneOf:[{type:"string"},{type:"object"}]}},ea={type:"object",properties:{root:{type:"string"},output:{type:"string",pattern:"(.ya?ml|.json)$"},rbac:{type:"object",additionalProperties:!0},openapi:Bn,graphql:Hn,theme:{type:"object",properties:{openapi:Bn,graphql:Hn},additionalProperties:!1},title:{type:"string"},metadata:{type:"object",additionalProperties:!0},rules:ed,decorators:{type:"object",additionalProperties:!0},preprocessors:{type:"object",additionalProperties:!0}},required:["root"]},Iy={type:"object",additionalProperties:!0},Fy={type:"object",additionalProperties:{type:"object",additionalProperties:!0}},Wy={type:"object",properties:{title:{type:"string"},description:{type:"string"},siteUrl:{type:"string"},image:{type:"string"},keywords:{oneOf:[{type:"array",items:{type:"string"}},{type:"string"}]},lang:{type:"string"},jsonLd:{type:"object"},meta:{type:"array",items:{type:"object",properties:{name:{type:"string"},content:{type:"string"}},required:["name","content"],additionalProperties:!1}}},additionalProperties:!1},Yn={type:"object",additionalProperties:{type:"string"}},td={type:"object",properties:{teamNamePatterns:{type:"array",items:{type:"string"}},teamFolders:{type:"array",items:{type:"string"}},teamFoldersBaseRoles:Yn,cms:Yn,reunite:Yn,content:{type:"object",properties:{"**":Yn},additionalProperties:Yn}},additionalProperties:Yn},Hy={type:"object",properties:{static:{type:"string"}},additionalProperties:!1,required:["static"]},Uy={type:"object",properties:{idp:{type:"string"}},additionalProperties:!1,required:["idp"]},By={type:"object",properties:{type:{type:"string",const:"GRAVITEE"},apiBaseUrl:{type:"string"},env:{type:"string"},allowApiProductsOutsideCatalog:{type:"boolean",default:!1},stage:{type:"string",default:"non-production"},auth:{oneOf:[Hy,Uy]}},additionalProperties:!1,required:["type","apiBaseUrl"]},zy={type:"object",properties:{type:{type:"string",const:$n.OAUTH2},tokenEndpoint:{type:"string"},clientId:{type:"string"},clientSecret:{type:"string"}},additionalProperties:!1,required:["type","tokenEndpoint","clientId","clientSecret"]},$y={type:"object",properties:{type:{type:"string",const:$n.SERVICE_ACCOUNT},serviceAccountEmail:{type:"string"},serviceAccountPrivateKey:{type:"string"}},additionalProperties:!1,required:["type","serviceAccountEmail","serviceAccountPrivateKey"]},Xs={type:"object",properties:{type:{type:"string",const:"APIGEE_X"},apiUrl:{type:"string"},stage:{type:"string",default:"non-production"},organizationName:{type:"string"},ignoreApiProducts:{type:"array",items:{type:"string"}},allowApiProductsOutsideCatalog:{type:"boolean",default:!1},auth:{type:"object",oneOf:[zy,$y],discriminator:{propertyName:"type"}}},additionalProperties:!1,required:["type","organizationName","auth"]},Yy=Object.assign(Object.assign({},Xs),{properties:Object.assign(Object.assign({},Xs.properties),{type:{type:"string",const:"APIGEE_EDGE"}})}),Vy={type:"object",oneOf:[Xs,Yy,By],discriminator:{propertyName:"type"}},Ky={type:"object",required:["adapters"],additionalProperties:!1,properties:{adapters:{type:"array",items:Vy}}},Zl={type:"object",properties:{defaultLocale:{type:"string"},locales:{type:"array",items:{type:"object",properties:{code:{type:"string"},name:{type:"string"}},required:["code"]}}},additionalProperties:!1,required:["defaultLocale"]},Gy={type:"object",properties:{name:{type:"string"},value:{type:"string"}},additionalProperties:!1,required:["name","value"]},Zs={type:"object",properties:{imports:{type:"array",items:{type:"string"}},licenseKey:{type:"string"},redirects:Ly,seo:Wy,rbac:td,requiresLogin:{type:"boolean"},responseHeaders:{type:"object",additionalProperties:{type:"array",items:Gy}},mockServer:{type:"object",properties:{off:{type:"boolean",default:!1},position:{type:"string",enum:["first","last","replace","off"],default:"first"},strictExamples:{type:"boolean",default:!1},errorIfForcedExampleNotFound:{type:"boolean",default:!1},description:{type:"string"}}},apis:{type:"object",additionalProperties:ea},rules:ed,decorators:{type:"object",additionalProperties:!0},preprocessors:{type:"object",additionalProperties:!0},ssoDirect:Ey,sso:My,residency:{type:"string"},developerOnboarding:Ky,removeAttribution:{type:"boolean"},i18n:Zl,l10n:Zl,metadata:Iy,metadataGlobs:Fy,ignore:{type:"array",items:{type:"string"}},theme:nt,reunite:Xl,logo:Di,navbar:Si,products:Ti,footer:xi,sidebar:wi,scripts:ki,links:Ai,feedback:Zt,search:qi,colorMode:Ni,navigation:Oi,codeSnippet:Ei,markdown:Mi,openapi:Bn,graphql:Hn,analytics:ji,userMenu:Li,versionPicker:Ii,breadcrumbs:Fi,catalog:Wi,scorecard:Hi},default:{redirects:{}},additionalProperties:!0},Jy=Object.assign(Object.assign({},Ui(Zs,"default")),{additionalProperties:!1}),ta=Object.assign(Object.assign({$id:"root-redocly-config"},Zs),{properties:Object.assign(Object.assign({plugins:{type:"array",items:{type:"string"}}},Zs.properties),{env:{type:"object",additionalProperties:Jy}}),default:{},additionalProperties:!1});var na={type:"object",properties:{logo:nt.properties.logo,navbar:nt.properties.navbar,footer:nt.properties.footer,sidebar:nt.properties.sidebar,search:nt.properties.search,codeSnippet:nt.properties.codeSnippet,breadcrumbs:nt.properties.breadcrumbs,openapi:nt.properties.openapi,feedback:nt.properties.feedback,analytics:{type:"object",properties:{ga:Gs}}},additionalProperties:!0,default:{}},Qy={$id:"product-config-override",type:"object",properties:Object.assign(Object.assign({},na.properties),{apis:{type:"object",additionalProperties:ea},theme:na}),additionalProperties:!1};var Qe=ot(ln(),1);import{getLineColLocation as f_,lintDocument as p_,makeDocumentFromString as $c,lintConfig as g_,detectSpec as m_,getMergedConfig as h_}from"@redocly/openapi-core";import{createConfigTypes as y_}from"@redocly/openapi-core/lib/types/redocly-yaml";import{bundleDocument as c_,makeDocumentFromString as u_}from"@redocly/openapi-core";var ap=new Map,Eo=new Map;function l_(e){return e?Array.from(e).map(([t,n])=>[t,js(n)]):[]}async function Bc(e,t){let{config:n}=await Fn(),r=new Ut(n.resolve),i=u_(e.getText(),e.uri),{bundle:o,problems:s,fileDependencies:u,rootType:c,refTypes:p}=await c_({document:i,config:n.styleguide,externalRefResolver:r}),g=l_(p);p&&(Eo=new Map([...Eo,...p])),ap.set(e.uri,{uri:e.uri,name:On(e.uri),definition:o.parsed,rootType:c,refTypes:g,errors:t})}function d_(){return Array.from(ap).map(([e,{definition:t,rootType:n,refTypes:r,errors:i}])=>({name:On(e),uri:e,definition:t,rootType:n,refTypes:r,errors:i}))}function zc(e){return Eo.has(e)?Eo.get(e):null}var b_=800,v_=5,Vc=Al(__,b_);async function C_(e){let t=e.map(({documentPath:i})=>Oe(i).toString()),{config:n}=await Fn(),r=await Ie.getRootWorkspaceFolderURI();for(let{root:i}of Object.values(n.apis)){let o=await Ls(i,r);if(t.includes(o))return o}return t[0]}var Yc;function P_(e){try{return m_(e),!0}catch{return!1}}async function __(e){let t=e.uri,{config:n,rootConfigDocument:r,configPath:i}=await Fn();if(Cr(as(t))){let o=Ys(t)?$c(e.getText(),t):$c(r.source.body,r.source.absoluteRef),s=new Ut,u=await g_({document:o,externalRefResolver:s,config:n,externalConfigTypes:y_(ta,n)}),c=[{uri:e.uri,diagnostics:[]}];return cp(u,c),c}else{let o=Fl(t),s=await C_(o||[]);s&&(e=await Ht(s),t=s);let u;try{u=$c(e.getText(),t)}catch{return[{uri:e.uri,diagnostics:[]}]}if(!P_(u.parsed))return[{uri:e.uri,diagnostics:[]}];let c=[];try{let p=new Ut(n.resolve);Yc=e.uri;let g=await Ie.getRootWorkspaceFolderURI(),b=await Nl(n.apis,Yc,g),R=Date.now(),D=(await p_({document:u,config:h_(n,b).styleguide,externalRefResolver:p})).filter(({ignored:B})=>!B);Yc=null;let T=S_(D);Bc(e,T);let q=Date.now()-R;c=[{uri:e.uri,diagnostics:[]},...Array.from(p.getFiles()).map(B=>({uri:Oe(B).toString(),diagnostics:[]}))],Il(t,{dependencyPaths:p.getFiles(),durationMS:q}),cp(D,c)}catch(p){R_(e.uri,p,c)}return c}}function Mo(){return Ie.documents.all().map(Vc)}function R_(e,t,n){let r=n||[{uri:e,diagnostics:[]}];if(t.line&&t.col&&t.message){let i=t.source?.absoluteRef?Oe(t.source.absoluteRef).toString():e,o=t.line-1,s=t.col-1,u=Qe.Position.create(o,s),c=Qe.Diagnostic.create(Qe.Range.create(u,u),t.message,Qe.DiagnosticSeverity.Error);up(i,c,r)}else t.message.includes("This doesn\u2019t look like an OpenAPI document")||console.error(t);return r}function up(e,t,n){let r=n.find(i=>i.uri===e);return r||(r={uri:e,diagnostics:[]},n.push(r)),r.diagnostics.push(t),n}function D_(e){return e.suggest.length===0?"":e.suggest.length===1?`
71
+ `);return n[0]}),this.registerRootWorkspaceFolderURIGetter(async()=>"")}registerFileSystemProvider(t){this._fs=t}registerDocumentsProvider(t){this._documentManager=t}registerConfigFinder(t){this._findConfig=t}registerRootWorkspaceFolderURIGetter(t){this._getRootWorkspaceFolderURI=t}get fs(){if(!this._fs)throw new Error("FileSystemProvider not registered.");return this._fs}get documents(){if(!this._documentManager)throw new Error("DocumentsProvider not registered.");return this._documentManager}get findConfig(){return this._findConfig}get getRootWorkspaceFolderURI(){return this._getRootWorkspaceFolderURI}},Ie=new is;function ru(e,t){return ye.resolvePath(Oe(e)).toString()===ye.resolvePath(Oe(t)).toString()}function Oe(e){return On.parse(e)}function as(e){return On.parse(e).fsPath}function cs(e){let t=["https","http"],{scheme:n}=On.parse(e);return t.includes(n)}function En(e){return ye.basename(Oe(e))}async function iu(e,t="/"){let n=ye.resolvePath(Oe(t));for(;e.path!=="/";)try{(await Ie.fs.stat(ye.resolvePath(n,e.path))).isDirectory()||(e=ye.dirname(e));break}catch{e=ye.dirname(e)}return e}import{BaseResolver as Dh,Source as Wl,readFileFromUrl as Sh}from"@redocly/openapi-core";var gi=ot(pi(),1);import{isAbsoluteUrl as Ph}from"@redocly/openapi-core";function Al(e,t=100,n=!1){let r=new Map,i=new Map;function o(u,c,p){let g=i.get(u.uri),b=Date.now()-g;try{b<t&&b>=0?r.set(u.uri,setTimeout(()=>o(u,c,p),t-b)):(r.delete(u.uri),i.delete(u.uri),n||c(e(u)))}catch(R){p(R)}}function s(u){let c=r.get(u.uri),p=n&&!c;return i.set(u.uri,Date.now()),new Promise((g,b)=>{c||r.set(u.uri,setTimeout(()=>o(u,g,b),t)),p&&g(e(u))})}return s}function js(e){let t=new Set,n=r=>Array.isArray(n)?r.map(n):typeof r=="object"&&r!==null?t.has(r)?void 0:(t.add(r),Object.fromEntries(Object.entries(r).map(([i,o])=>[i,n(o)]))):r;return n(e)}function ql(e){return e==="$ref"}async function Ls(e,t){let n=On.parse(t);return ye.joinPath(n,e).toString()}async function Nl(e,t,n){for(let[r,{root:i}]of Object.entries(e))if(await Ls(i,n)===t)return r}function Ol(e){return typeof e=="string"}function mi(e){return typeof e=="function"}function El(e){return e?.kind===gi.Kind.MAP}function Is(e){return e?.kind===gi.Kind.MAPPING}function Fs(e){return e?.kind===gi.Kind.SEQ}function br(e,t){let n=t.singleQuoted?"'":'"';return`${n}${e}${n}`}function Ws(e){return Ph(e)||e.startsWith("file://")}var Cn=class{constructor(t,n,r,i){this._uri=t,this._languageId=n,this._version=r,this._content=i,this._lineOffsets=void 0}get uri(){return this._uri}get languageId(){return this._languageId}get version(){return this._version}getText(t){if(t){let n=this.offsetAt(t.start),r=this.offsetAt(t.end);return this._content.substring(n,r)}return this._content}update(t,n){for(let r of t)if(Cn.isIncremental(r)){let i=jl(r.range),o=this.offsetAt(i.start),s=this.offsetAt(i.end);this._content=this._content.substring(0,o)+r.text+this._content.substring(s,this._content.length);let u=Math.max(i.start.line,0),c=Math.max(i.end.line,0),p=this._lineOffsets,g=Ml(r.text,!1,o);if(c-u===g.length)for(let R=0,D=g.length;R<D;R++)p[R+u+1]=g[R];else g.length<1e4?p.splice(u+1,c-u,...g):this._lineOffsets=p=p.slice(0,u+1).concat(g,p.slice(c+1));let b=r.text.length-(s-o);if(b!==0)for(let R=u+1+g.length,D=p.length;R<D;R++)p[R]=p[R]+b}else if(Cn.isFull(r))this._content=r.text,this._lineOffsets=void 0;else throw new Error("Unknown change event received");this._version=n}getLineOffsets(){return this._lineOffsets===void 0&&(this._lineOffsets=Ml(this._content,!0)),this._lineOffsets}positionAt(t){t=Math.max(Math.min(t,this._content.length),0);let n=this.getLineOffsets(),r=0,i=n.length;if(i===0)return{line:0,character:t};for(;r<i;){let s=Math.floor((r+i)/2);n[s]>t?i=s:r=s+1}let o=r-1;return{line:o,character:t-n[o]}}offsetAt(t){let n=this.getLineOffsets();if(t.line>=n.length)return this._content.length;if(t.line<0)return 0;let r=n[t.line],i=t.line+1<n.length?n[t.line+1]:this._content.length;return Math.max(Math.min(r+t.character,i),r)}get lineCount(){return this.getLineOffsets().length}static isIncremental(t){let n=t;return n!=null&&typeof n.text=="string"&&n.range!==void 0&&(n.rangeLength===void 0||typeof n.rangeLength=="number")}static isFull(t){let n=t;return n!=null&&typeof n.text=="string"&&n.range===void 0&&n.rangeLength===void 0}},hi;(function(e){function t(i,o,s,u){return new Cn(i,o,s,u)}e.create=t;function n(i,o,s){if(i instanceof Cn)return i.update(o,s),i;throw new Error("TextDocument.update: document must be created by TextDocument.create")}e.update=n;function r(i,o){let s=i.getText(),u=Hs(o.map(_h),(g,b)=>{let R=g.range.start.line-b.range.start.line;return R===0?g.range.start.character-b.range.start.character:R}),c=0,p=[];for(let g of u){let b=i.offsetAt(g.range.start);if(b<c)throw new Error("Overlapping edit");b>c&&p.push(s.substring(c,b)),g.newText.length&&p.push(g.newText),c=i.offsetAt(g.range.end)}return p.push(s.substr(c)),p.join("")}e.applyEdits=r})(hi||(hi={}));function Hs(e,t){if(e.length<=1)return e;let n=e.length/2|0,r=e.slice(0,n),i=e.slice(n);Hs(r,t),Hs(i,t);let o=0,s=0,u=0;for(;o<r.length&&s<i.length;)t(r[o],i[s])<=0?e[u++]=r[o++]:e[u++]=i[s++];for(;o<r.length;)e[u++]=r[o++];for(;s<i.length;)e[u++]=i[s++];return e}function Ml(e,t,n=0){let r=t?[n]:[];for(let i=0;i<e.length;i++){let o=e.charCodeAt(i);(o===13||o===10)&&(o===13&&i+1<e.length&&e.charCodeAt(i+1)===10&&i++,r.push(n+i+1))}return r}function jl(e){let t=e.start,n=e.end;return t.line>n.line||t.line===n.line&&t.character>n.character?{start:n,end:t}:e}function _h(e){let t=jl(e.range);return t!==e.range?{newText:e.newText,range:t}:e}var Ll=new Map;function Il(e,t){return Ll.set(e,t)}function Fl(e){let t=[];for(let[n,r]of Ll.entries())r.dependencyPaths.has(e)&&t.push({documentPath:n,durationMS:r.durationMS});return t}async function Ht(e){let t=Ie.documents.get(e);if(t)return t;let n=await Ie.fs.readFile(Oe(e),"utf-8");return hi.create(e,"yaml",1,n)}function Us(e){return ss.filePattern.test(e)}function Rh(e){return os.filePattern.test(e)}var Ut=class extends Dh{resolveExternalRef(t,n){return Ws(n)?n:t&&Ws(t)?new URL(n,t).href:ye.resolvePath(ye.dirname(Oe(t)),n).toString()}async loadExternalRef(t){if(cs(t)){let{body:n,mimeType:r}=await Sh(t,{...this.config.http,customFetch:fetch});return new Wl(t,n,r)}return new Wl(t,(await Ht(t)).getText())}};var vr,yi,Bs,Hl;async function zs(e){let t=new Ut,n=await Ie.findConfig(e);return vr=await Th({configPath:n,externalRefResolver:t,processRawConfig:async({document:r,resolvedRefMap:i})=>{Bs=i,Hl=r}}),vr}async function Wn(){return vr||await zs(),{config:vr,configPath:yi,rootConfigDocument:Hl}}async function Ul(e,t){try{return yi=await Ie.findConfig(e),yi?await zs(yi):vr}catch(n){return t?.createEventHandleLoadConfigError?.(n?.message),zs("")}}function Cr(e){return Ys(e)?!0:!!Bs&&[...Bs.keys()].map(n=>n.split("::")?.[1]?.split("#")[0]).some(n=>ru(En(e),n))}function Ys(e){return $s.includes(En(e))}var Bl={hide:{type:"boolean",default:!1},component:{type:"string",enum:["radio","checkbox"],default:"checkbox"},label:{type:"string"},items:{type:"array",items:{type:"string"}}},Pr={type:"object",properties:Bl,additionalProperties:!1},xh={type:"object",properties:{enabled:{type:"boolean",default:!1},label:{type:"string"},placeholder:{type:"string"}},additionalProperties:!1},Zt={type:"object",properties:{hide:{type:"boolean",default:!1},type:{type:"string",enum:["rating","sentiment","comment","reasons","mood","scale"],default:"sentiment"},settings:{type:"object",properties:{label:{type:"string"},submitText:{type:"string"},buttonText:{type:"string"},component:{type:"string",enum:["radio","checkbox"],default:"checkbox"},items:{type:"array",items:{type:"string"},minItems:1},leftScaleLabel:{type:"string"},rightScaleLabel:{type:"string"},reasons:{type:"object",properties:Object.assign(Object.assign({},Bl),{like:Pr,dislike:Pr,satisfied:Pr,neutral:Pr,dissatisfied:Pr}),additionalProperties:!1},comment:{type:"object",properties:{hide:{type:"boolean",default:!1},label:{type:"string"},likeLabel:{type:"string"},dislikeLabel:{type:"string"},satisfiedLabel:{type:"string"},neutralLabel:{type:"string"},dissatisfiedLabel:{type:"string"}},additionalProperties:!1},anonymousUserEmail:xh},additionalProperties:!1}},additionalProperties:!1};var Hn={type:"object",properties:{includeByName:{type:"array",items:{type:"string"}},excludeByName:{type:"array",items:{type:"string"}}},additionalProperties:!1},wh={type:"object",properties:{name:{type:"string"},items:Hn,queries:Hn,mutations:Hn,subscriptions:Hn,types:Hn,directives:Hn},required:["name"],additionalProperties:!1},kh={type:"object",properties:{requireExactGroups:{type:"boolean"},groups:{type:"array",items:wh},otherItemsGroupName:{type:"string"}},required:["requireExactGroups","groups","otherItemsGroupName"],additionalProperties:!1},Un={type:"object",properties:{hidePaginationButtons:{type:"boolean"},menu:{type:"object",properties:Object.assign({},kh.properties),additionalProperties:!1},sidebar:{type:"object",properties:{hide:{type:"boolean"}}},apiLogo:{type:"object",properties:{imageUrl:{type:"string"},href:{type:"string"},altText:{type:"string"},backgroundColor:{type:"string"}}},jsonSamplesDepth:{type:"number"},samplesMaxInlineArgs:{type:"number"},licenseKey:{type:"string"},fieldExpandLevel:{type:"number"},baseUrlPath:{type:"string"},feedback:Zt},additionalProperties:!1};var Ah={type:"object",properties:{languages:{type:"array",items:{type:"object",properties:{lang:{type:"string",enum:["curl","JavaScript","Node.js","Python","Java8+Apache","Java","C#","C#+Newtonsoft","PHP","Go","Ruby","R","Payload"]},label:{type:"string"},options:{type:"object",properties:{indent:{type:"string"},withImports:{type:"boolean"},withComments:{type:"boolean"},binary:{type:"boolean"},credentials:{type:"string",enum:["omit","same-origin","include"]}},additionalProperties:!1}},required:["lang"],additionalProperties:!1}},skipOptionalParameters:{type:"boolean"},withOAuth2Call:{type:"boolean"}},required:["languages"],additionalProperties:!1},qh={type:"array",items:{type:"object",properties:{title:{type:"string"},url:{type:"string"}},required:["url"],additionalProperties:!1}},bi={type:"object",properties:{licenseKey:{type:"string"},hideLoading:{type:"boolean"},disableRouter:{type:"boolean"},hideSidebar:{type:"boolean"},feedback:Zt,hideReplay:{type:"boolean"},oAuth2RedirectURI:{type:"string",nullable:!0},corsProxyUrl:{type:"string"},sortRequiredPropsFirst:{type:"boolean"},sanitize:{type:"boolean"},hideDownloadButtons:{type:"boolean"},downloadUrls:qh,onlyRequiredInSamples:{type:"boolean"},generatedSamplesMaxDepth:{oneOf:[{type:"number"},{type:"string"}]},showExtensions:{oneOf:[{type:"boolean"},{type:"string"},{type:"array",items:{type:"string"}}]},hideSchemaTitles:{type:"boolean"},jsonSamplesExpandLevel:{oneOf:[{type:"number"},{type:"string"}]},schemasExpansionLevel:{oneOf:[{type:"number"},{type:"string"}]},mockServer:{type:"object",properties:{url:{type:"string"},position:{type:"string",enum:["first","last","replace","off"]},description:{type:"string"}}},maxDisplayedEnumValues:{type:"number"},schemaDefinitionsTagName:{type:"string"},layout:{type:"string",enum:["stacked","three-panel"]},hideInfoMetadata:{type:"boolean"},events:{type:"object"},skipBundle:{type:"boolean"},routingBasePath:{type:"string"},codeSamples:Ah,ignoreNamedSchemas:{oneOf:[{type:"array",items:{type:"string"}},{type:"string"}]},hidePropertiesPrefix:{type:"boolean"},excludeFromSearch:{type:"boolean"}},additionalProperties:!1};var Nh={type:"object",properties:{label:{type:"string"},lang:{enum:["curl","C#","Go","Java","Java8+Apache","JavaScript","Node.js","PHP","Python","R","Ruby"]}},required:["lang"]},Oh={type:"object",properties:{enum:{type:"string"},enumSingleValue:{type:"string"},enumArray:{type:"string"},default:{type:"string"},deprecated:{type:"string"},example:{type:"string"},examples:{type:"string"},nullable:{type:"string"},recursive:{type:"string"},arrayOf:{type:"string"},webhook:{type:"string"},authorizations:{type:"string"},tryItAuthBasicUsername:{type:"string"},tryItAuthBasicPassword:{type:"string"}}},zl={type:"object",properties:{label:{type:"string"},link:{type:"string"},target:{type:"string"}},required:["label","link"]},Eh={type:"object",properties:{beforeInfo:{type:"array",items:zl},end:{type:"array",items:zl}}},Pn={type:"object",properties:{main:{type:"string"},light:{type:"string"},dark:{type:"string"},contrastText:{type:"string"}}},vi={type:"object",properties:{backgroundColor:{type:"string"},borderColor:{type:"string"},color:{type:"string"},tabTextColor:{type:"string"}}},Mh={type:"object",properties:Ri(Pn.properties,["light","dark"])},jh={type:"object",properties:{basic:{type:"string"},delete:{type:"string"},get:{type:"string"},head:{type:"string"},link:{type:"string"},options:{type:"string"},patch:{type:"string"},post:{type:"string"},put:{type:"string"}}},Lh={type:"object",properties:{error:vi,info:vi,redirect:vi,success:vi}},Ih={type:"object",properties:Bn(Pn.properties,["dark"])},Fh={type:"object",properties:{primary:{type:"string"},secondary:{type:"string"},light:{type:"string"}}},Wh={type:"object",properties:{accent:Pn,border:Mh,error:Pn,http:jh,primary:Pn,responses:Lh,secondary:Ih,success:Pn,text:Fh,tonalOffset:{type:"number"},warning:Pn}},Ci={type:"object",properties:{fontSize:{type:"string"},padding:{type:"string"},minWidth:{type:"string"}}},Hh={type:"object",properties:{small:Ci,medium:Ci,large:Ci,xlarge:Ci}},kt={type:"object",properties:{fontFamily:{type:"string"},fontSize:{type:"string"},fontWeight:{type:"string"},lineHeight:{type:"string"}}},Uh={type:"object",properties:Object.assign(Object.assign({},Bn(kt.properties,["fontSize","lineHeight"])),{borderRadius:{type:"string"},hoverStyle:{type:"string"},boxShadow:{type:"string"},hoverBoxShadow:{type:"string"},sizes:Hh})},$l={type:"object",properties:Ri(kt.properties,["fontSize","lineHeight"])},Bh={type:"object",properties:{medium:$l,small:$l}},zh={type:"object",properties:Object.assign(Object.assign({},Bn(kt.properties,["fontSize","lineHeight"])),{borderRadius:{type:"string"},color:{type:"string"},sizes:Bh})},$h={type:"object",properties:{top:{type:"string"},width:{type:"string"},height:{type:"string"}}},Yh={type:"object",properties:{borderRadius:{type:"string"},backgroundColor:{type:"string"}}},Yl={type:"object",properties:{fullWidth:{type:"boolean"}}},Vh={type:"object",properties:{buttons:Uh,httpBadges:zh,layoutControls:$h,panels:Yh,tryItButton:Yl,tryItSendButton:Yl}},_i={type:"object",properties:{small:{type:"string"},medium:{type:"string"},large:{type:"string"}}},Kh={type:"object",properties:{maxWidth:_i}},Gh={type:"object",properties:{maxWidth:_i,middlePanelMaxWidth:_i}},Jh={type:"object",properties:{showDarkRightPanel:{type:"boolean"},stacked:Kh,"three-panel":Gh}},Vl={type:"object",properties:{backgroundColor:{type:"string"},border:{type:"string"}}},Qh={type:"object",properties:{breakFieldNames:{type:"boolean"},caretColor:{type:"string"},caretSize:{type:"string"},constraints:Vl,defaultDetailsWidth:{type:"string"},examples:Vl,labelsTextSize:{type:"string"},linesColor:{type:"string"},nestedBackground:{type:"string"},nestingSpacing:{type:"string"},requireLabelColor:{type:"string"},typeNameColor:{type:"string"},typeTitleColor:{type:"string"}}},Gl={type:"object",properties:{subItemsColor:{type:"string"},textTransform:{type:"string"},fontWeight:{type:"string"}}},Xh={type:"object",properties:Ri(Gl.properties,["textTransform"])},Zh={type:"object",properties:{unit:{type:"number"},paddingHorizontal:{type:"string"},paddingVertical:{type:"string"},offsetTop:{type:"string"},offsetLeft:{type:"string"},offsetNesting:{type:"string"}}},ey={type:"object",properties:Object.assign(Object.assign({},Bn(kt.properties,["fontWeight","lineHeight"])),{activeBgColor:{type:"string"},activeTextColor:{type:"string"},backgroundColor:{type:"string"},borderRadius:{type:"string"},breakPath:{type:"boolean"},caretColor:{type:"string"},caretSize:{type:"string"},groupItems:Gl,level1items:Xh,rightLineColor:{type:"string"},separatorLabelColor:{type:"string"},showAtBreakpoint:{type:"string"},spacing:Zh,textColor:{type:"string"},width:{type:"string"}})},Pi={type:"object",properties:Object.assign(Object.assign({},kt.properties),{color:{type:"string"},transform:{type:"string"}})},ty={type:"object",properties:Object.assign(Object.assign({},kt.properties),{backgroundColor:{type:"string"},color:{type:"string"},wordBreak:{type:"string",enum:["break-all","break-word","keep-all","normal","revert","unset","inherit","initial"]},wrap:{type:"boolean"}})},ny={type:"object",properties:Bn(kt.properties,["fontSize"])},ry={type:"object",properties:{color:{type:"string"},hover:{type:"string"},textDecoration:{type:"string"},hoverTextDecoration:{type:"string"},visited:{type:"string"}}},iy={type:"object",properties:Object.assign(Object.assign({code:ty,fieldName:kt},Ri(kt.properties,["fontSize","fontFamily"])),{fontWeightBold:{type:"string"},fontWeightLight:{type:"string"},fontWeightRegular:{type:"string"},heading1:Pi,heading2:Pi,heading3:Pi,headings:ny,lineHeight:{type:"string"},links:ry,optimizeSpeed:{type:"boolean"},rightPanelHeading:Pi,smoothing:{type:"string",enum:["auto","none","antialiased","subpixel-antialiased","grayscale"]}})},oy={type:"object",properties:Object.assign({color:{type:"string"}},Bn(kt.properties,["fontWeight"]))},sy={type:"object",properties:{backgroundColor:{type:"string"},borderRadius:{type:"string"},tokens:oy}},ay={type:"object",properties:{gutter:{type:"string"},maxHeight:{type:"string"},maxWidth:{type:"string"}}},cy={type:"object",properties:{backgroundColor:{type:"string"},color:{type:"string"}}},Kl={type:"object",properties:{custom:{type:"string"}}},uy={type:"object",properties:{DownloadButton:Kl,NextSectionButton:Kl}},ly={type:"object",properties:{backgroundColor:{type:"string"},panelBackgroundColor:{type:"string"},panelControlsBackgroundColor:{type:"string"},showAtBreakpoint:{type:"string"},textColor:{type:"string"},width:{type:"string"}}},dy={type:"object",properties:{borderRadius:{type:"string"}}},fy={type:"object",properties:{sectionHorizontal:{type:"number"},sectionVertical:{type:"number"},unit:{type:"number"}}},py={type:"object",properties:{breakpoints:_i,codeBlock:sy,colors:Wh,components:Vh,layout:Jh,logo:ay,fab:cy,overrides:uy,rightPanel:ly,schema:Qh,shape:dy,sidebar:ey,spacing:fy,typography:iy,links:{properties:{color:{type:"string"}}},codeSample:{properties:{backgroundColor:{type:"string"}}}}},gy={type:"object",properties:{skipOptionalParameters:{type:"boolean"},languages:{type:"array",items:Nh}},required:["languages"]},Jl={type:"object",properties:{theme:py,ctrlFHijack:{type:"boolean"},defaultSampleLanguage:{type:"string"},disableDeepLinks:{type:"boolean"},disableSearch:{type:"boolean"},disableSidebar:{type:"boolean"},downloadDefinitionUrl:{type:"string"},expandDefaultServerVariables:{type:"boolean"},enumSkipQuotes:{type:"boolean"},expandDefaultRequest:{type:"boolean"},expandDefaultResponse:{type:"boolean"},expandResponses:{type:"string"},expandSingleSchemaField:{type:"boolean"},generateCodeSamples:gy,generatedPayloadSamplesMaxDepth:{type:"number"},hideDownloadButton:{type:"boolean"},hideHostname:{type:"boolean"},hideInfoSection:{type:"boolean"},hideLogo:{type:"boolean"},hideRequestPayloadSample:{type:"boolean"},hideRightPanel:{type:"boolean"},hideSchemaPattern:{type:"boolean"},hideSingleRequestSampleTab:{type:"boolean"},hideSecuritySection:{type:"boolean"},hideTryItPanel:{type:"boolean"},hideFab:{type:"boolean"},hideOneOfDescription:{type:"boolean"},htmlTemplate:{type:"string"},jsonSampleExpandLevel:{oneOf:[{type:"number",minimum:1},{type:"string"}]},labels:Oh,menuToggle:{type:"boolean"},nativeScrollbars:{type:"boolean"},noAutoAuth:{type:"boolean"},onDeepLinkClick:{type:"object"},pagination:{enum:["none","section","item"]},pathInMiddlePanel:{type:"boolean"},payloadSampleIdx:{type:"number",minimum:0},requestInterceptor:{type:"object"},requiredPropsFirst:{type:"boolean"},routingStrategy:{type:"string"},samplesTabsMaxCount:{type:"number"},schemaExpansionLevel:{oneOf:[{type:"number",minimum:0},{type:"string"}]},minCharacterLengthToInitSearch:{type:"number",minimum:1},maxResponseHeadersToShowInTryIt:{type:"number",minimum:0},scrollYOffset:{oneOf:[{type:"number"},{type:"string"}]},searchAutoExpand:{type:"boolean"},searchFieldLevelBoost:{type:"number",minimum:0},searchMaxDepth:{type:"number",minimum:1},searchMode:{type:"string",enum:["default","path-only"]},searchOperationTitleBoost:{type:"number"},searchTagTitleBoost:{type:"number"},sendXUserAgentInTryIt:{type:"boolean"},showChangeLayoutButton:{type:"boolean"},showConsole:{type:"boolean"},showNextButton:{type:"boolean"},showRightPanelToggle:{type:"boolean"},showSecuritySchemeType:{type:"boolean"},showWebhookVerb:{type:"boolean"},showObjectSchemaExamples:{type:"boolean"},disableTryItRequestUrlEncoding:{type:"boolean"},sidebarLinks:Eh,sideNavStyle:{type:"string",enum:["summary-only","path-first","id-only"]},simpleOneOfTypeLabel:{type:"boolean"},sortEnumValuesAlphabetically:{type:"boolean"},sortOperationsAlphabetically:{type:"boolean"},sortPropsAlphabetically:{type:"boolean"},sortTagsAlphabetically:{type:"boolean"},suppressWarnings:{type:"boolean"},unstable_externalDescription:{type:"boolean"},unstable_ignoreMimeParameters:{type:"boolean"},untrustedDefinition:{type:"boolean"},showAccessMode:{type:"boolean"},preserveOriginalExtensionsName:{type:"boolean"},markdownHeadingsAnchorLevel:{type:"number"}},additionalProperties:!1};function Ri(e,t){return Object.fromEntries(t.filter(n=>n in e).map(n=>[n,e[n]]))}function Bn(e,t){return Object.fromEntries(Object.entries(e).filter(([n])=>!t.includes(n)))}var $e={type:"object",properties:{hide:{type:"boolean"}},additionalProperties:!1},Ql={type:"object",properties:{src:{type:"string"},async:{type:"boolean"},crossorigin:{type:"string"},defer:{type:"boolean"},fetchpriority:{type:"string"},integrity:{type:"string"},module:{type:"boolean"},nomodule:{type:"boolean"},nonce:{type:"string"},referrerpolicy:{type:"string"},type:{type:"string"}},required:["src"],additionalProperties:!0},Vs={type:"object",properties:{page:{type:"string"},directory:{type:"string"},disconnect:{type:"boolean",default:!1},group:{type:"string"},label:{type:"string"},href:{type:"string"},external:{type:"boolean"},labelTranslationKey:{type:"string"},groupTranslationKey:{type:"string"},icon:{oneOf:[{type:"string"},{type:"object",properties:{srcSet:{type:"string"}},required:["srcSet"]}]},separator:{type:"string"},separatorLine:{type:"boolean"},linePosition:{type:"string",enum:["top","bottom"],default:"top"},version:{type:"string"},menuStyle:{type:"string",enum:["drilldown"]},expanded:{type:"string",const:"always"},selectFirstItemOnExpand:{type:"boolean"},flatten:{type:"boolean"},linkedSidebars:{type:"array",items:{type:"string"}},items:{type:"array",items:{type:"object",additionalProperties:!0}}}},Ks={type:"array",items:Object.assign(Object.assign({},Vs),{properties:Object.assign(Object.assign({},Vs.properties),{items:{type:"array",items:Vs}})})},my={type:"object",properties:{name:{type:"string"},icon:{type:"string"},folder:{type:"string"}},additionalProperties:!1,required:["name","folder"]},hy={type:"object",properties:{hide:{type:"boolean",default:!1},prompt:{type:"string"}},additionalProperties:!1},yy={type:"array",items:{type:"object",required:["name","field","type"],properties:{name:{type:"string"},field:{type:"string"},type:{type:"string",enum:["multi-select","select","tags"]},isTop:{type:"boolean"}},additionalProperties:!1}},by={type:"object",properties:{page:{type:"string"},label:{type:"string"},labelTranslationKey:{type:"string"}},required:["page"]},Di={type:"object",properties:{image:{type:"string"},srcSet:{type:"string"},altText:{type:"string"},link:{type:"string"},favicon:{type:"string"}},additionalProperties:!1},Si={type:"object",properties:Object.assign({items:Ks},$e.properties),additionalProperties:!1},Ti={type:"object",additionalProperties:my},xi={type:"object",properties:Object.assign({items:Ks,copyrightText:{type:"string"},logo:$e},$e.properties),additionalProperties:!1},wi={type:"object",properties:Object.assign({separatorLine:{type:"boolean"},linePosition:{type:"string",enum:["top","bottom"],default:"bottom"}},$e.properties),additionalProperties:!1},ki={type:"object",properties:{head:{type:"array",items:Ql},body:{type:"array",items:Ql}},additionalProperties:!1},Ai={type:"array",items:{type:"object",properties:{href:{type:"string"},as:{type:"string"},crossorigin:{type:"string"},fetchpriority:{type:"string"},hreflang:{type:"string"},imagesizes:{type:"string"},imagesrcset:{type:"string"},integrity:{type:"string"},media:{type:"string"},prefetch:{type:"string"},referrerpolicy:{type:"string"},rel:{type:"string"},sizes:{type:"string"},title:{type:"string"},type:{type:"string"}},required:["href"],additionalProperties:!0}},qi={type:"object",properties:Object.assign({engine:{type:"string",enum:["flexsearch","typesense"],default:"flexsearch"},ai:hy,facets:yy,placement:{type:"string",default:"navbar"},shortcuts:{type:"array",items:{type:"string"},default:["/"]},suggestedPages:{type:"array",items:by}},$e.properties),additionalProperties:!1},Ni={type:"object",properties:Object.assign({ignoreDetection:{type:"boolean"},modes:{type:"array",items:{type:"string"},default:["light","dark"]}},$e.properties),additionalProperties:!1},Oi={type:"object",properties:{nextButton:{type:"object",properties:Object.assign({text:{type:"string",default:"Next page"}},$e.properties),additionalProperties:!1,default:{}},previousButton:{type:"object",properties:Object.assign({text:{type:"string",default:"Previous page"}},$e.properties),additionalProperties:!1,default:{}}},additionalProperties:!1},Ei={type:"object",properties:{elementFormat:{type:"string",default:"icon"},copy:{type:"object",properties:Object.assign({},$e.properties),additionalProperties:!1,default:{hide:!1}},report:{type:"object",properties:Object.assign({tooltipText:{type:"string"},buttonText:{type:"string"},label:{type:"string"}},$e.properties),additionalProperties:!1,default:{hide:!1}},expand:{type:"object",properties:Object.assign({},$e.properties),additionalProperties:!1,default:{hide:!1}},collapse:{type:"object",properties:Object.assign({},$e.properties),additionalProperties:!1,default:{hide:!1}}},additionalProperties:!1},Mi={type:"object",properties:{frontMatterKeysToResolve:{type:"array",items:{type:"string"},default:["image","links"]},partialsFolders:{type:"array",items:{type:"string"},default:["_partials"]},lastUpdatedBlock:{type:"object",properties:Object.assign({format:{type:"string",enum:["timeago","iso","long","short"],default:"timeago"},locale:{type:"string"}},$e.properties),additionalProperties:!1,default:{}},toc:{type:"object",properties:Object.assign({header:{type:"string",default:"On this page"},depth:{type:"integer",default:3,minimum:1}},$e.properties),additionalProperties:!1,default:{}},editPage:{type:"object",properties:Object.assign({baseUrl:{type:"string"}},$e.properties),additionalProperties:!1,default:{}}},additionalProperties:!1,default:{}},zn=Object.assign(Object.assign({},bi),{properties:Object.assign(Object.assign({},bi.properties),Jl.properties)}),vy={type:"object",properties:{includeInDevelopment:{type:"boolean"},scriptUrl:{type:"string"},pageViewEventName:{type:"string"}},additionalProperties:!1,required:["scriptUrl"]},Cy={type:"object",properties:{includeInDevelopment:{type:"boolean"},apiKey:{type:"string"},head:{type:"boolean"},respectDNT:{type:"boolean"},exclude:{type:"array",items:{type:"string"}},outboundClickEventName:{type:"string"},pageViewEventName:{type:"string"},amplitudeConfig:{type:"object",additionalProperties:!0}},additionalProperties:!1,required:["apiKey"]},Py={type:"object",properties:{includeInDevelopment:{type:"boolean"},orgId:{type:"string"}},additionalProperties:!1,required:["orgId"]},_y={type:"object",properties:{includeInDevelopment:{type:"boolean"},appId:{type:"string"}},additionalProperties:!1,required:["appId"]},Ry={type:"object",properties:{includeInDevelopment:{type:"boolean"},writeKey:{type:"string",minLength:10},trackPage:{type:"boolean"},dataPlaneUrl:{type:"string"},controlPlaneUrl:{type:"string"},sdkUrl:{type:"string"},loadOptions:{type:"object",additionalProperties:!0}},additionalProperties:!1,required:["writeKey"]},Dy={type:"object",properties:{includeInDevelopment:{type:"boolean"},writeKey:{type:"string",minLength:10},trackPage:{type:"boolean"},includeTitleInPageCall:{type:"boolean"},host:{type:"string"}},additionalProperties:!1,required:["writeKey"]},Sy={type:"object",properties:{includeInDevelopment:{type:"boolean"},trackingId:{type:"string"},gtmAuth:{type:"string"},gtmPreview:{type:"string"},defaultDataLayer:{},dataLayerName:{type:"string"},enableWebVitalsTracking:{type:"boolean"},selfHostedOrigin:{type:"string"},pageViewEventName:{type:"string"}},additionalProperties:!1,required:["trackingId"]},Gs={type:"object",properties:{includeInDevelopment:{type:"boolean"},trackingId:{type:"string"},conversionId:{type:"string"},floodlightId:{type:"string"},optimizeId:{type:"string"},exclude:{type:"array",items:{type:"string"}}},additionalProperties:!1,required:["trackingId"]},Ty={type:"object",properties:{includeInDevelopment:{type:"boolean"},trackingId:{type:"string"},conversionId:{type:"string"},floodlightId:{type:"string"},head:{type:"boolean"},respectDNT:{type:"boolean"},exclude:{type:"array",items:{type:"string"}},optimizeId:{type:"string"},anonymizeIp:{type:"boolean"},cookieExpires:{type:"number"},trackers:{type:"object",additionalProperties:Gs}},additionalProperties:!1,required:["trackingId"]},ji={type:"object",properties:{adobe:vy,amplitude:Cy,fullstory:Py,heap:_y,rudderstack:Ry,segment:Dy,gtm:Sy,ga:Ty}},Li={type:"object",properties:Object.assign({items:{type:"array",items:{type:"object",properties:{label:{type:"string"},external:{type:"boolean"},link:{type:"string"},separatorLine:{type:"boolean"}},additionalProperties:!0},default:[]},hideLoginButton:{type:"boolean"}},$e.properties),additionalProperties:!1},Ii={type:"object",properties:{hide:{type:"boolean"},showForUnversioned:{type:"boolean"}}},Fi={type:"object",properties:{hide:{type:"boolean"},prefixItems:{type:"array",items:{type:"object",properties:{label:{type:"string"},labelTranslationKey:{type:"string"},page:{type:"string"}},additionalProperties:!1,default:{}}}},additionalProperties:!1},xy={type:"object",additionalProperties:!1,required:["title","property"],properties:{type:{type:"string",enum:["select","checkboxes","date-range"],default:"checkboxes"},title:{type:"string"},titleTranslationKey:{type:"string"},property:{type:"string"},parentFilter:{type:"string"},valuesMapping:{type:"object",additionalProperties:{type:"string"}},missingCategoryName:{type:"string"},missingCategoryNameTranslationKey:{type:"string"},options:{type:"array",items:{type:"string"}}}},wy={type:"object",additionalProperties:!0,required:["slug","items"],properties:{slug:{type:"string"},filters:{type:"array",items:xy},groupByFirstFilter:{type:"boolean"},filterValuesCasing:{type:"string",enum:["sentence","original","lowercase","uppercase"]},items:Ks,requiredPermission:{type:"string"},separateVersions:{type:"boolean"},title:{type:"string"},titleTranslationKey:{type:"string"},description:{type:"string"},descriptionTranslationKey:{type:"string"}}},Wi={type:"object",patternProperties:{".*":wy}},Hi={type:"object",additionalProperties:!0,required:[],properties:{ignoreNonCompliant:{type:"boolean",default:!1},teamMetadataProperty:{type:"object",properties:{property:{type:"string"},label:{type:"string"},default:{type:"string"}}},levels:{type:"array",items:{type:"object",required:["name"],properties:{name:{type:"string"},color:{type:"string"},extends:{type:"array",items:{type:"string"}},rules:{type:"object",additionalProperties:{oneOf:[{type:"string"},{type:"object"}]}}},additionalProperties:!1}},targets:{type:"array",items:{type:"object",required:["where"],properties:{minimumLevel:{type:"string"},rules:{type:"object",additionalProperties:!0},where:{type:"object",required:["metadata"],properties:{metadata:{type:"object",additionalProperties:{type:"string"}}},additionalProperties:!1}},additionalProperties:!1}},ignore:{type:"array",items:{type:"string"}}}};var nt={type:"object",properties:{imports:{type:"array",items:{type:"string"}},logo:Di,navbar:Si,products:Ti,footer:xi,sidebar:wi,scripts:ki,links:Ai,feedback:Zt,search:qi,colorMode:Ni,navigation:Oi,codeSnippet:Ei,markdown:Mi,openapi:zn,graphql:Un,analytics:ji,userMenu:Li,versionPicker:Ii,breadcrumbs:Fi,catalog:Wi,scorecard:Hi},additionalProperties:!0},qR=Object.assign(Object.assign({},nt),{additionalProperties:!1});var Qs="https://redocly.com/sso/teams",$n;(function(e){e.OIDC="OIDC",e.SAML2="SAML2"})($n||($n={}));var Yn;(function(e){e.SERVICE_ACCOUNT="SERVICE_ACCOUNT",e.OAUTH2="OAUTH2"})(Yn||(Yn={}));var Js;(function(e){e.STACKED="stacked",e.THREE_PANEL="three-panel"})(Js||(Js={}));function Ui(e,t){return Object.fromEntries(Object.entries(e).map(([n,r])=>{if(n!==t)return typeof r!="object"||!r?[n,r]:Array.isArray(r)?[n,r.map(i=>typeof i=="object"?Ui(i,t):i)]:[n,Ui(r,t)]}).filter(Boolean))}var ky={type:"object",additionalProperties:{type:"string"}},Ay={type:"object",additionalProperties:!1,properties:{event:{type:"string",enum:["schedule"]},interval:{type:"string",pattern:"^[1-9]\\d*[mhdw]$"}},required:["event"]},Xl={type:"object",properties:{ignoreLint:{oneOf:[{type:"boolean",default:!1},{type:"object",additionalProperties:{type:"boolean"}}]},ignoreLinkChecker:{type:"boolean"},ignoreMarkdocErrors:{type:"boolean"},jobs:{type:"array",items:{type:"object",properties:{path:{type:"string",pattern:"^(?!\\.\\./)(/[a-zA-Z0-9_\\-\\./]+|./[a-zA-Z0-9_\\-\\./]+|[a-zA-Z0-9_\\-\\./]+)$"},agent:{type:"string",enum:["spot"]},trigger:Ay,inputs:ky},required:["path","trigger","agent"],additionalProperties:!1}}},additionalProperties:!1};var qy={type:"object",properties:{end_session_endpoint:{type:"string"},token_endpoint:{type:"string"},authorization_endpoint:{type:"string"},jwks_uri:{type:"string"}},required:["token_endpoint","authorization_endpoint"],additionalProperties:!0},Ny={type:"object",properties:{type:{type:"string",const:$n.OIDC},title:{type:"string"},pkce:{type:"boolean",default:!1},configurationUrl:{type:"string",minLength:1},configuration:qy,clientId:{type:"string",minLength:1},clientSecret:{type:"string",minLength:0},teamsClaimName:{type:"string"},teamsClaimMap:{type:"object",additionalProperties:{type:"string"}},defaultTeams:{type:"array",items:{type:"string"}},scopes:{type:"array",items:{type:"string"}},tokenExpirationTime:{type:"number"},authorizationRequestCustomParams:{type:"object",additionalProperties:{type:"string"}},tokenRequestCustomParams:{type:"object",additionalProperties:{type:"string"}},audience:{type:"array",items:{type:"string"}}},required:["type","clientId"],oneOf:[{required:["configurationUrl"]},{required:["configuration"]}],additionalProperties:!1},Oy={type:"object",properties:{type:{type:"string",const:$n.SAML2},title:{type:"string"},issuerId:{type:"string"},entityId:{type:"string"},ssoUrl:{type:"string"},x509PublicCert:{type:"string"},teamsAttributeName:{type:"string",default:Qs},teamsAttributeMap:{type:"object",additionalProperties:{type:"string"}},defaultTeams:{type:"array",items:{type:"string"}}},additionalProperties:!1,required:["type","issuerId","ssoUrl","x509PublicCert"]},Ey={oneOf:[Ny,Oy],discriminator:{propertyName:"type"}},My={type:"object",additionalProperties:Ey},jy={oneOf:[{type:"array",items:{type:"string",enum:["REDOCLY","CORPORATE","GUEST"]},uniqueItems:!0},{type:"string",enum:["REDOCLY","CORPORATE","GUEST"]}]},Ly={type:"object",properties:{to:{type:"string"},type:{type:"number",default:301}},additionalProperties:!1},Iy={type:"object",additionalProperties:Ly,default:{}},ed={type:"object",additionalProperties:{oneOf:[{type:"string"},{type:"object"}]}},ea={type:"object",properties:{root:{type:"string"},output:{type:"string",pattern:"(.ya?ml|.json)$"},rbac:{type:"object",additionalProperties:!0},openapi:zn,graphql:Un,theme:{type:"object",properties:{openapi:zn,graphql:Un},additionalProperties:!1},title:{type:"string"},metadata:{type:"object",additionalProperties:!0},rules:ed,decorators:{type:"object",additionalProperties:!0},preprocessors:{type:"object",additionalProperties:!0}},required:["root"]},Fy={type:"object",additionalProperties:!0},Wy={type:"object",additionalProperties:{type:"object",additionalProperties:!0}},Hy={type:"object",properties:{title:{type:"string"},description:{type:"string"},siteUrl:{type:"string"},image:{type:"string"},keywords:{oneOf:[{type:"array",items:{type:"string"}},{type:"string"}]},lang:{type:"string"},jsonLd:{type:"object"},meta:{type:"array",items:{type:"object",properties:{name:{type:"string"},content:{type:"string"}},required:["name","content"],additionalProperties:!1}}},additionalProperties:!1},_n={type:"object",additionalProperties:{type:"string"}},td={type:"object",properties:{teamNamePatterns:{type:"array",items:{type:"string"}},teamFolders:{type:"array",items:{type:"string"}},teamFoldersBaseRoles:_n,cms:_n,reunite:_n,features:{type:"object",properties:{aiSearch:_n},additionalProperties:!1},content:{type:"object",properties:{"**":_n},additionalProperties:_n}},additionalProperties:_n},Uy={type:"object",properties:{static:{type:"string"}},additionalProperties:!1,required:["static"]},By={type:"object",properties:{idp:{type:"string"}},additionalProperties:!1,required:["idp"]},zy={type:"object",properties:{type:{type:"string",const:"GRAVITEE"},apiBaseUrl:{type:"string"},env:{type:"string"},allowApiProductsOutsideCatalog:{type:"boolean",default:!1},stage:{type:"string",default:"non-production"},auth:{oneOf:[Uy,By]}},additionalProperties:!1,required:["type","apiBaseUrl"]},$y={type:"object",properties:{type:{type:"string",const:Yn.OAUTH2},tokenEndpoint:{type:"string"},clientId:{type:"string"},clientSecret:{type:"string"}},additionalProperties:!1,required:["type","tokenEndpoint","clientId","clientSecret"]},Yy={type:"object",properties:{type:{type:"string",const:Yn.SERVICE_ACCOUNT},serviceAccountEmail:{type:"string"},serviceAccountPrivateKey:{type:"string"}},additionalProperties:!1,required:["type","serviceAccountEmail","serviceAccountPrivateKey"]},Xs={type:"object",properties:{type:{type:"string",const:"APIGEE_X"},apiUrl:{type:"string"},stage:{type:"string",default:"non-production"},organizationName:{type:"string"},ignoreApiProducts:{type:"array",items:{type:"string"}},allowApiProductsOutsideCatalog:{type:"boolean",default:!1},auth:{type:"object",oneOf:[$y,Yy],discriminator:{propertyName:"type"}}},additionalProperties:!1,required:["type","organizationName","auth"]},Vy=Object.assign(Object.assign({},Xs),{properties:Object.assign(Object.assign({},Xs.properties),{type:{type:"string",const:"APIGEE_EDGE"}})}),Ky={type:"object",oneOf:[Xs,Vy,zy],discriminator:{propertyName:"type"}},Gy={type:"object",required:["adapters"],additionalProperties:!1,properties:{adapters:{type:"array",items:Ky}}},Zl={type:"object",properties:{defaultLocale:{type:"string"},locales:{type:"array",items:{type:"object",properties:{code:{type:"string"},name:{type:"string"}},required:["code"]}}},additionalProperties:!1,required:["defaultLocale"]},Jy={type:"object",properties:{name:{type:"string"},value:{type:"string"}},additionalProperties:!1,required:["name","value"]},Zs={type:"object",properties:{imports:{type:"array",items:{type:"string"}},licenseKey:{type:"string"},redirects:Iy,seo:Hy,rbac:td,requiresLogin:{type:"boolean"},responseHeaders:{type:"object",additionalProperties:{type:"array",items:Jy}},mockServer:{type:"object",properties:{off:{type:"boolean",default:!1},position:{type:"string",enum:["first","last","replace","off"],default:"first"},strictExamples:{type:"boolean",default:!1},errorIfForcedExampleNotFound:{type:"boolean",default:!1},description:{type:"string"}}},apis:{type:"object",additionalProperties:ea},rules:ed,decorators:{type:"object",additionalProperties:!0},preprocessors:{type:"object",additionalProperties:!0},ssoDirect:My,sso:jy,residency:{type:"string"},developerOnboarding:Gy,removeAttribution:{type:"boolean"},i18n:Zl,l10n:Zl,metadata:Fy,metadataGlobs:Wy,ignore:{type:"array",items:{type:"string"}},theme:nt,reunite:Xl,logo:Di,navbar:Si,products:Ti,footer:xi,sidebar:wi,scripts:ki,links:Ai,feedback:Zt,search:qi,colorMode:Ni,navigation:Oi,codeSnippet:Ei,markdown:Mi,openapi:zn,graphql:Un,analytics:ji,userMenu:Li,versionPicker:Ii,breadcrumbs:Fi,catalog:Wi,scorecard:Hi},default:{redirects:{}},additionalProperties:!0},Qy=Object.assign(Object.assign({},Ui(Zs,"default")),{additionalProperties:!1}),ta=Object.assign(Object.assign({$id:"root-redocly-config"},Zs),{properties:Object.assign(Object.assign({plugins:{type:"array",items:{type:"string"}}},Zs.properties),{env:{type:"object",additionalProperties:Qy}}),default:{},additionalProperties:!1});var na={type:"object",properties:{logo:nt.properties.logo,navbar:nt.properties.navbar,footer:nt.properties.footer,sidebar:nt.properties.sidebar,search:nt.properties.search,codeSnippet:nt.properties.codeSnippet,breadcrumbs:nt.properties.breadcrumbs,openapi:nt.properties.openapi,feedback:nt.properties.feedback,analytics:{type:"object",properties:{ga:Gs}}},additionalProperties:!0,default:{}},Xy={$id:"product-config-override",type:"object",properties:Object.assign(Object.assign({},na.properties),{apis:{type:"object",additionalProperties:ea},theme:na}),additionalProperties:!1};var Qe=ot(ln(),1);import{getLineColLocation as p_,lintDocument as g_,makeDocumentFromString as $c,lintConfig as m_,detectSpec as h_,getMergedConfig as y_}from"@redocly/openapi-core";import{createConfigTypes as b_}from"@redocly/openapi-core/lib/types/redocly-yaml";import{bundleDocument as u_,makeDocumentFromString as l_}from"@redocly/openapi-core";var ap=new Map,Eo=new Map;function d_(e){return e?Array.from(e).map(([t,n])=>[t,js(n)]):[]}async function Bc(e,t){let{config:n}=await Wn(),r=new Ut(n.resolve),i=l_(e.getText(),e.uri),{bundle:o,problems:s,fileDependencies:u,rootType:c,refTypes:p}=await u_({document:i,config:n.styleguide,externalRefResolver:r}),g=d_(p);p&&(Eo=new Map([...Eo,...p])),ap.set(e.uri,{uri:e.uri,name:En(e.uri),definition:o.parsed,rootType:c,refTypes:g,errors:t})}function f_(){return Array.from(ap).map(([e,{definition:t,rootType:n,refTypes:r,errors:i}])=>({name:En(e),uri:e,definition:t,rootType:n,refTypes:r,errors:i}))}function zc(e){return Eo.has(e)?Eo.get(e):null}var v_=800,C_=5,Vc=Al(R_,v_);async function P_(e){let t=e.map(({documentPath:i})=>Oe(i).toString()),{config:n}=await Wn(),r=await Ie.getRootWorkspaceFolderURI();for(let{root:i}of Object.values(n.apis)){let o=await Ls(i,r);if(t.includes(o))return o}return t[0]}var Yc;function __(e){try{return h_(e),!0}catch{return!1}}async function R_(e){let t=e.uri,{config:n,rootConfigDocument:r,configPath:i}=await Wn();if(Cr(as(t))){let o=Ys(t)?$c(e.getText(),t):$c(r.source.body,r.source.absoluteRef),s=new Ut,u=await m_({document:o,externalRefResolver:s,config:n,externalConfigTypes:b_(ta,n)}),c=[{uri:e.uri,diagnostics:[]}];return cp(u,c),c}else{let o=Fl(t),s=await P_(o||[]);s&&(e=await Ht(s),t=s);let u;try{u=$c(e.getText(),t)}catch{return[{uri:e.uri,diagnostics:[]}]}if(!__(u.parsed))return[{uri:e.uri,diagnostics:[]}];let c=[];try{let p=new Ut(n.resolve);Yc=e.uri;let g=await Ie.getRootWorkspaceFolderURI(),b=await Nl(n.apis,Yc,g),R=Date.now(),D=(await g_({document:u,config:y_(n,b).styleguide,externalRefResolver:p})).filter(({ignored:B})=>!B);Yc=null;let T=T_(D);Bc(e,T);let q=Date.now()-R;c=[{uri:e.uri,diagnostics:[]},...Array.from(p.getFiles()).map(B=>({uri:Oe(B).toString(),diagnostics:[]}))],Il(t,{dependencyPaths:p.getFiles(),durationMS:q}),cp(D,c)}catch(p){D_(e.uri,p,c)}return c}}function Mo(){return Ie.documents.all().map(Vc)}function D_(e,t,n){let r=n||[{uri:e,diagnostics:[]}];if(t.line&&t.col&&t.message){let i=t.source?.absoluteRef?Oe(t.source.absoluteRef).toString():e,o=t.line-1,s=t.col-1,u=Qe.Position.create(o,s),c=Qe.Diagnostic.create(Qe.Range.create(u,u),t.message,Qe.DiagnosticSeverity.Error);up(i,c,r)}else t.message.includes("This doesn\u2019t look like an OpenAPI document")||console.error(t);return r}function up(e,t,n){let r=n.find(i=>i.uri===e);return r||(r={uri:e,diagnostics:[]},n.push(r)),r.diagnostics.push(t),n}function S_(e){return e.suggest.length===0?"":e.suggest.length===1?`
72
72
  Did you mean: ${e.suggest[0]} ?`:`
73
73
  Did you mean:
74
- - ${e.suggest.slice(0,v_).join(`
75
- - `)}`}function cp(e,t){e.forEach(n=>{let r;switch(n.severity){case"error":r=Qe.DiagnosticSeverity.Error;break;case"warn":r=Qe.DiagnosticSeverity.Warning;break;default:r=Qe.DiagnosticSeverity.Warning}let i=f_(n.location[0]),o=Oe(i.source.absoluteRef).toString(),s=Qe.Position.create(i.start.line-1,i.start.col-1),u=i.end?Qe.Position.create(i.end.line-1,i.end.col-1):s,c=n.message+D_(n),p=Qe.Diagnostic.create(Qe.Range.create(s,u),c,r,void 0,"Redocly OpenAPI");up(o,p,t)})}function S_(e){return e.filter(({severity:t})=>t==="error").map(t=>({...t,location:t.location.map(n=>({...n,source:{...n.source,_ast:null}}))}))}var $o=ot(ln(),1);var Re=ot(ln(),1);function Ne(e,t){return e?t?jo[e+"_"+t]||t:jo[e]||jo[zr.Default]:jo[zr.Default]}var zr=(G=>(G.FileCompletion="FileCompletion",G.FolderCompletion="FolderCompletion",G.LocalComponentCompletion="LocalComponentCompletion",G.NewLine="newLine",G.PropertyName="propertyName",G.NewItem="newItem",G.PathMap="PathMap",G.MediaTypeMap="MediaTypeMap",G.Root="Root",G.RootOpenapi="Root_openapi",G.RootInfo="Root_info",G.RootJsonSchemaDialect="Root_jsonSchemaDialect",G.RootServers="Root_servers",G.RootPaths="Root_paths",G.RootWebhooks="Root_webhooks",G.RootComponents="Root_components",G.RootSecurity="Root_security",G.RootTags="Root_tags",G.RootExternalDocs="Root_externalDocs",G.Info="Info",G.InfoTitle="Info_title",G.InfoSummary="Info_summary",G.InfoDescription="Info_description",G.InfoTermsOfService="Info_termsOfService",G.InfoContact="Info_contact",G.ContactName="Contact_name",G.ContactUrl="Contact_url",G.ContactEmail="Contact_email",G.InfoLicense="Info_license",G.LicenseName="License_name",G.LicenseIdentifier="License_identifier",G.LicenseUrl="License_url",G.InfoVersion="Info_version",G.jsonSchemaDialect="jsonSchemaDialect",G.ServerList="Server_List",G.ServerUrl="Server_url",G.ServerDescription="Server_description",G.ServerVariables="Server_variables",G.Default="Default",G))(zr||{}),T_=["newLine","MediaTypeMap","PathMap","propertyName","newItem","Root_openapi","Root","Info","Root_info","Info_title","Info_summary","Info_description","Info_termsOfService","Info_contact","Contact_name","Contact_url","Contact_email","Info_license","License_name","License_identifier","License_url","Info_version","Root_jsonSchemaDialect","jsonSchemaDialect","Root_servers","Server_List","Server_url","Server_description","Server_variables","Root_paths","Root_webhooks","Root_components","Root_security","Root_tags","Root_externalDocs","LocalComponentCompletion","FolderCompletion","FileCompletion","Default"],jo=T_.reduce((e,t,n)=>(e[t]=String.fromCharCode(n),e),{});var dn="newItem",$r="propertyName",cr="newLine";function Lo(e){return!!(e?.name&&lp[e.name])}function Kc(e){return lp[e]||[]}var lp={[cr]:[{label:"newLine",kind:Re.CompletionItemKind.Constructor,data:{},sortText:Ne(cr)}],[$r]:[{label:$r,kind:Re.CompletionItemKind.Constructor,data:{properties:{}},sortText:Ne($r)}],ServerVariable_Map:[{label:"newVariableName",kind:Re.CompletionItemKind.Property,data:{properties:{}},sortText:Ne("ServerVariable_Map")}],ResponsesMap:[{label:"200",kind:Re.CompletionItemKind.Property,data:{properties:{}}},{label:"201",kind:Re.CompletionItemKind.Property,data:{properties:{}}},{label:"204",kind:Re.CompletionItemKind.Property,data:{properties:{}}},{label:"301",kind:Re.CompletionItemKind.Property,data:{properties:{}}},{label:"303",kind:Re.CompletionItemKind.Property,data:{properties:{}}},{label:"400",kind:Re.CompletionItemKind.Property,data:{properties:{}}},{label:"401",kind:Re.CompletionItemKind.Property,data:{properties:{}}},{label:"403",kind:Re.CompletionItemKind.Property,data:{properties:{}}},{label:"404",kind:Re.CompletionItemKind.Property,data:{properties:{}}},{label:"500",kind:Re.CompletionItemKind.Property,data:{properties:{}}},{label:"503",kind:Re.CompletionItemKind.Property,data:{properties:{}}}],PathMap:[{label:"/newPath",kind:Re.CompletionItemKind.Property,data:{properties:{}},sortText:Ne("PathMap")}],MediaTypeMap:[{label:"mime/type",kind:Re.CompletionItemKind.Property,data:{properties:{}},sortText:Ne("MediaTypeMap")},{label:"application/json",kind:Re.CompletionItemKind.Property,data:{properties:{}},sortText:Ne("MediaTypeMap")},{label:"application/octet-stream",kind:Re.CompletionItemKind.Property,data:{properties:{}},sortText:Ne("MediaTypeMap")},{label:"multipart/form-data",kind:Re.CompletionItemKind.Property,data:{properties:{}},sortText:Ne("MediaTypeMap")},{label:"application/x-www-form-urlencoded",kind:Re.CompletionItemKind.Property,data:{properties:{}},sortText:Ne("MediaTypeMap")},{label:"application/xml",kind:Re.CompletionItemKind.Property,data:[],sortText:Ne("MediaTypeMap")}]};var fn=ot(pi(),1);import{normalizeTypes as fp,Oas3Types as x_,Oas2Types as w_,Oas3_1Types as dp,AsyncApi2Types as k_,SpecVersion as Vt,ConfigTypes as A_,getMajorSpecVersion as q_}from"@redocly/openapi-core";var Gc=new Map;async function N_(e,t){let n=await Ht(e),r=n.getText(),i=fn.safeLoad(r,{filename:e.toString()}),{nodePath:o}=Io({node:i,nodePath:[]},t,n,!0),s=Jc(i,e),{currentType:u,parentType:c,endPath:p}=Fo(s,o),g=Yr(i),b=u?.name?u:c;return{nodePath:o,endPath:p,type:b,existingValues:g,types:s}}function pp(e,t){if(!e)return null;let n=e,r=!0;return t.forEach(i=>{if(r=!1,Fs(n)&&n.items&&n.items[i])n=n.items[i],r=!0;else if(El(n)){let o=Wo(n);for(let s of o)if(Is(s)&&s.key?.value===i){n=s?.value,r=!0;break}}}),r?n:(console.warn("Cannot find node by path",t),null)}function O_(e,t){for(let n=0;n<t.length;n++)if(n===t.length-1||t[n+1]>e)return n;return t.length-1}function Io(e,t,n,r=!1){let{node:i,nodePath:o=[]}=e,s=n.offsetAt(t),u=Wo(i);if(u.length===0||E_(i)||!r&&M_(i,n,t))return e;let c=j_(u,s);return Io({nodePath:L_(o,i,u[c],c),node:u[c]},t,n,r)}function E_(e){return e?.kind===fn.Kind.MAPPING&&!e?.value}function M_(e,t,n){let r=t.getText({start:t.positionAt(t._lineOffsets[n.line]),end:n}),i=I_(e,t),o=r?.match(/^\s+/)?.[0]?.length||0;return(/^\s*[\w\-\$\/\{\}]+$/.test(r)?o:n.character)===i}function j_(e,t){for(let n=1;n<e.length;n++){let r=e[n];if(!!r&&r.startPosition>t)return n-1}return e.length-1}function L_(e,t,n,r){return Fs(t)?[...e,r]:Is(n)&&n?.key?.value&&typeof n.key.value=="string"?[...e,n.key.value]:e}function I_(e,t){let n=e?.startPosition??0,r=O_(n,t._lineOffsets);if(r>=0){let i=t._lineOffsets[r];return n-i}return 0}function Fo(e,t){let n=e,r=null,i=new Array(t.length).fill(null);t.forEach((s,u)=>{let c;if(e?.name&&e?.name!==n?.name&&(n=e,r=s),e&&e?.properties&&!Object.keys(e?.properties).length&&e?.items?.properties)c=e.items;else if(e?.properties&&e.properties[s])c=e.properties[s],mi(c)&&(c=c(null,s));else if(e?.additionalProperties&&!mi(e?.additionalProperties))c=e.additionalProperties;else if(mi(e?.additionalProperties)&&s){let p=e.additionalProperties(null,s);p&&(c=p)}c&&(e=c,i[u]=c)}),e?.name&&n?.name&&e?.name!==n?.name&&(r=null);let o=i.every(s=>!!s);return{currentType:o||t[0]==="openapi"||t.length===0?e:null,parentType:o?n:null,endPath:r}}function Jc(e,t){if(Cr(t))return fp(A_).ConfigRoot;let{types:n,isDefault:r}=W_(e);if(!e)return n;let i=r?zc(t):n;return r&&!zc(t)&&e?null:i||n}function F_(e){if(Gc.has(e))return Gc.get(e);let t=fp(H_(e)).Root;return Gc.set(e,t),t}function gp(e){let t,n=!1;if(e?.kind===fn.Kind.MAP)for(let r of e.mappings){let i=r.key?.value,o=String(r?.value?.value);if(i==="openapi"&&o.startsWith("3.1")){t=Vt.OAS3_1;break}if(i==="openapi"&&o.startsWith("3.0")){t=Vt.OAS3_0;break}if(i==="swagger"&&o==="2.0"){t=Vt.OAS2;break}if(i==="asyncapi")return{version:Vt.Async2,isDefault:!1}}return t||(t=Vt.OAS3_1,n=!0),{version:t,isDefault:n}}function mp(e){let{version:t,isDefault:n}=gp(e);return{version:q_(t),isDefault:n}}function W_(e){let{version:t,isDefault:n}=gp(e);return{types:F_(t),isDefault:n}}function Wo(e){switch(e?.kind){case fn.Kind.MAPPING:return[e.key,e.value];case fn.Kind.MAP:return e.mappings;case fn.Kind.SEQ:return e?.items;default:return[]}}function H_(e){switch(e){case Vt.OAS3_1:return dp;case Vt.OAS3_0:return x_;case Vt.OAS2:return w_;case Vt.Async2:return k_;default:return dp}}function Yr(e,t,n){if(typeof t>"u"&&(t={}),typeof n>"u"&&(n=0),!e)return{};let r=e?.mappings||e?.items;if(r){let i=0;for(let o of r)o?.value===null||!o?.value?.value?t[o?.key?.value||i]={value:Ol(o?.value)?o?.value:null,startOffset:o?.key?.value?o.startPosition+o.key.value.length+1:null,endOffset:null,indent:n}:t[o?.key?.value||i]={value:o?.value?.value,rawValue:o?.value?.rawValue||null,startOffset:o?.value?.startPosition||null,endOffset:o?.value?.endPosition||null,indent:n},Object.keys(o?.value||o||{}).includes("items")?(t[o?.key?.value||i]={type:"sequence",startOffset:o.startPosition,endOffset:o.endPosition,indent:n,value:null},Yr(o?.value||o,t[o?.key?.value||i],n+1)):Object.keys(o?.value||o||{}).includes("mappings")&&(t[o?.key?.value||i]={type:"map",startOffset:o.startPosition,endOffset:o.endPosition,indent:n,value:null},Yr(o?.value||o,t[o?.key?.value||i],n+1)),i++}return t}import{mapTypeToComponent as hp}from"@redocly/openapi-core";var Qc={Schema:[{name:"$ref",value:{type:"string",name:"Schema"}}],PathItem:[{name:"$ref",value:{type:"string",name:"PathItem"}}],Parameter:[{name:"$ref",value:{type:"string",name:"Parameter"}}],Response:[{name:"$ref",value:{type:"string",name:"Response"}}],Example:[{name:"$ref",value:{type:"string",name:"Example"}}],RequestBody:[{name:"$ref",value:{type:"string",name:"RequestBody"}}],Header:[{name:"$ref",value:{type:"string",name:"Header"}}],SecuritySchema:[{name:"$ref",value:{type:"string",name:"SecuritySchema"}}],Link:[{name:"$ref",value:{type:"string",name:"Link"}}],Callback:[{name:"$ref",value:{type:"string",name:"Callback"}}]};function yp(e){let t=Qc[e.name];return t&&t.forEach(n=>{e.properties[n.name]=n.value}),e}var Ho=ot(ln(),1),Dt=class{constructor({kind:t,label:n,value:r,textEdit:i,filterText:o,sortText:s,data:u}){this.kind=t||Ho.CompletionItemKind.Value,this.label=n;let{node:c,lineOffset:p,position:g}=u;this.insertText=r??n,this.filterText=o||this.insertText,this.sortText=s,this.textEdit=i||(c.value==null?void 0:this.getTextEdit(c,g,p))}getTextEdit(t,n,r){let i=t.startPosition-r,o=t.singleQuoted||t.doubleQuoted?2:0,s=i+t.value.length+o;return Ho.TextEdit.replace({start:{line:n.line,character:i},end:{line:n.line,character:s}},this.insertText)}};var ur=ot(ln(),1),wn=class{constructor({kind:t,label:n,insertText:r,insertTextFormat:i,filterText:o,sortText:s,data:u}){this.insertTextFormat=i||n.includes("$")?ur.InsertTextFormat.PlainText:ur.InsertTextFormat.Snippet,this.kind=t||ur.CompletionItemKind.Property,this.label=n,this.data=u||{},this.insertText=r??n,this.filterText=o||this.insertText,this.sortText=s,this.command=this.kind===ur.CompletionItemKind.Property?{title:"Suggested values",command:"editor.action.triggerSuggest"}:null}};var Vr={example:"example",default:"default",enum:"enum",ref:"$ref"},Uo=[Vr.default,Vr.example];var Pp=ot(pi(),1);var je={};tu(je,{default:()=>Cp.default});rs(je,ot(Xc()));var Cp=ot(Xc());function B_(e,t){let n=t.slice(0,t.length-1),{currentType:r}=Fo(e,n);if(r?.name){let[i]=Qc[r.name]||[];return i?.value}return null}function z_(e,t){let n=t[t.length-1];if(ql(n))return B_(e,t);let{currentType:r}=Fo(e,t);return Lo(r)?r:r?r?.name&&(r?.name.includes("Map")||r?.name.includes("Named"))?{name:$r,properties:{}}:r:null}async function _p(e,t){let n=await Ht(e),r=n.getText(),i=(0,Pp.safeLoad)(r,{filename:e}),{node:o,nodePath:s}=Io({node:i,nodePath:[]},t,n),u=Jc(i,e),c=z_(u,s),p=n._lineOffsets[t.line],g=n.getText({start:n.positionAt(p),end:t});return{currentAst:i,node:o,nodePath:s,position:t,lineText:g,lineOffset:p,openApiType:c}}async function Rp(e,t){let n=ye.resolvePath(Oe(e)),r=ye.dirname(n),i=await iu(ye.joinPath(r,t),r.path),o=ye.resolvePath(r,i.path);return{refPath:t,refDirPath:i,refDirAbsolutePath:o,isAbsolutePath:t&&(0,je.isAbsolute)(t),docAbsolutePath:n,docAbsoluteDirPath:r,root:"/"}}var Dp=ot(ln(),1);var Bo=class extends Dt{constructor(n){super(n);this.kind=Dp.CompletionItemKind.Folder,this.command={title:"Complete path",command:"editor.action.triggerSuggest",arguments:[]}}};var Sp=ot(ln(),1);var zo=class extends Dt{constructor(t){super(t),this.kind=Sp.CompletionItemKind.File}};var $_=Ie.supportedLanguages.concat({languageId:"markdown",filePattern:/\.md$/});function Y_(e){let{refPath:t,docAbsoluteDirPath:n,isAbsolutePath:r,root:i}=e,o=(0,je.resolve)(n.path,t,".."),s=r?o:(0,je.relative)(n.path,o),u=s&&s!==i?"/":"";return{name:"../",type:1,matchBy:t,sortBy:Ne("FolderCompletion"),value:`${s}${u}`}}async function V_(e,t,n){let r=[],{refDirAbsolutePath:i,docAbsolutePath:o}=n;for(let s of e)try{let u=ye.resolvePath(i,s),c=await Ie.fs.stat(u);c.isFile()&&u.path!==o.path&&t.supportedFiles.some(p=>p.filePattern.test(s))&&r.push({name:s,type:0}),c.isDirectory()&&r.push({name:s,type:1})}catch{continue}return r}function Tp(e,t){let{docAbsoluteDirPath:n,isAbsolutePath:r,refDirAbsolutePath:i,root:o,refPath:s}=t,u=[];return i.path!==o&&u.push(Y_(t)),u.concat(e.map(({name:c,type:p})=>{let g=(0,je.resolve)(i.path,c),b=(0,je.relative)(n.path,g),R=s.includes(je.sep)?s.slice(0,s.lastIndexOf(je.sep)+1):s+je.sep,D=r?g:b;if(p===0)return{type:p,name:c,value:D,sortBy:`${Ne("FileCompletion")}${c}`,matchBy:`${R}${c}`};let T=`${c}/`;return{type:p,name:T,value:`${D}${b?"/":""}`,sortBy:`${Ne("FolderCompletion")}${c}`,matchBy:`${R}${c}`}}))}function xp(e,t){let{node:n,lineOffset:r,position:i}=t;return e.map(o=>{let{name:s,value:u,matchBy:c,sortBy:p,type:g}=o,b={label:s,filterText:br(c,n),sortText:p,value:u,data:{lineOffset:r,position:i,node:n}};return g===1?new Bo(b):new zo(b)})}async function wp(e,t){let{node:n}=t,r=n.value??"",i=await Rp(e,r),{refDirAbsolutePath:o}=i,s=[];try{s=await Ie.fs.readDir(o)}catch{return xp(Tp([],i),t)}let u=await V_(s,{supportedFiles:$_},i);return xp(Tp(u,i),t)}import{isEmptyObject as K_}from"@redocly/openapi-core/lib/utils";function kp(e,t){if(t?.items)return"- "+kp(e,t.items);if(t?.required)return Object.values(t.required).map((n,r)=>`${n}: \${${r+1}}`).join(`
76
- `);if(e==="openapi"){let n="3.1.0",[r,i,o]=n.split(".");return`\${1:${r}}.\${2:${i}}.\${3:${o}}`}return""}function G_(e,t,n,r){if(e===dn)return"";if(r?.items||r?.required){let i=`
74
+ - ${e.suggest.slice(0,C_).join(`
75
+ - `)}`}function cp(e,t){e.forEach(n=>{let r;switch(n.severity){case"error":r=Qe.DiagnosticSeverity.Error;break;case"warn":r=Qe.DiagnosticSeverity.Warning;break;default:r=Qe.DiagnosticSeverity.Warning}let i=p_(n.location[0]),o=Oe(i.source.absoluteRef).toString(),s=Qe.Position.create(i.start.line-1,i.start.col-1),u=i.end?Qe.Position.create(i.end.line-1,i.end.col-1):s,c=n.message+S_(n),p=Qe.Diagnostic.create(Qe.Range.create(s,u),c,r,void 0,"Redocly OpenAPI");up(o,p,t)})}function T_(e){return e.filter(({severity:t})=>t==="error").map(t=>({...t,location:t.location.map(n=>({...n,source:{...n.source,_ast:null}}))}))}var $o=ot(ln(),1);var Re=ot(ln(),1);function Ne(e,t){return e?t?jo[e+"_"+t]||t:jo[e]||jo[zr.Default]:jo[zr.Default]}var zr=(G=>(G.FileCompletion="FileCompletion",G.FolderCompletion="FolderCompletion",G.LocalComponentCompletion="LocalComponentCompletion",G.NewLine="newLine",G.PropertyName="propertyName",G.NewItem="newItem",G.PathMap="PathMap",G.MediaTypeMap="MediaTypeMap",G.Root="Root",G.RootOpenapi="Root_openapi",G.RootInfo="Root_info",G.RootJsonSchemaDialect="Root_jsonSchemaDialect",G.RootServers="Root_servers",G.RootPaths="Root_paths",G.RootWebhooks="Root_webhooks",G.RootComponents="Root_components",G.RootSecurity="Root_security",G.RootTags="Root_tags",G.RootExternalDocs="Root_externalDocs",G.Info="Info",G.InfoTitle="Info_title",G.InfoSummary="Info_summary",G.InfoDescription="Info_description",G.InfoTermsOfService="Info_termsOfService",G.InfoContact="Info_contact",G.ContactName="Contact_name",G.ContactUrl="Contact_url",G.ContactEmail="Contact_email",G.InfoLicense="Info_license",G.LicenseName="License_name",G.LicenseIdentifier="License_identifier",G.LicenseUrl="License_url",G.InfoVersion="Info_version",G.jsonSchemaDialect="jsonSchemaDialect",G.ServerList="Server_List",G.ServerUrl="Server_url",G.ServerDescription="Server_description",G.ServerVariables="Server_variables",G.Default="Default",G))(zr||{}),x_=["newLine","MediaTypeMap","PathMap","propertyName","newItem","Root_openapi","Root","Info","Root_info","Info_title","Info_summary","Info_description","Info_termsOfService","Info_contact","Contact_name","Contact_url","Contact_email","Info_license","License_name","License_identifier","License_url","Info_version","Root_jsonSchemaDialect","jsonSchemaDialect","Root_servers","Server_List","Server_url","Server_description","Server_variables","Root_paths","Root_webhooks","Root_components","Root_security","Root_tags","Root_externalDocs","LocalComponentCompletion","FolderCompletion","FileCompletion","Default"],jo=x_.reduce((e,t,n)=>(e[t]=String.fromCharCode(n),e),{});var dn="newItem",$r="propertyName",cr="newLine";function Lo(e){return!!(e?.name&&lp[e.name])}function Kc(e){return lp[e]||[]}var lp={[cr]:[{label:"newLine",kind:Re.CompletionItemKind.Constructor,data:{},sortText:Ne(cr)}],[$r]:[{label:$r,kind:Re.CompletionItemKind.Constructor,data:{properties:{}},sortText:Ne($r)}],ServerVariable_Map:[{label:"newVariableName",kind:Re.CompletionItemKind.Property,data:{properties:{}},sortText:Ne("ServerVariable_Map")}],ResponsesMap:[{label:"200",kind:Re.CompletionItemKind.Property,data:{properties:{}}},{label:"201",kind:Re.CompletionItemKind.Property,data:{properties:{}}},{label:"204",kind:Re.CompletionItemKind.Property,data:{properties:{}}},{label:"301",kind:Re.CompletionItemKind.Property,data:{properties:{}}},{label:"303",kind:Re.CompletionItemKind.Property,data:{properties:{}}},{label:"400",kind:Re.CompletionItemKind.Property,data:{properties:{}}},{label:"401",kind:Re.CompletionItemKind.Property,data:{properties:{}}},{label:"403",kind:Re.CompletionItemKind.Property,data:{properties:{}}},{label:"404",kind:Re.CompletionItemKind.Property,data:{properties:{}}},{label:"500",kind:Re.CompletionItemKind.Property,data:{properties:{}}},{label:"503",kind:Re.CompletionItemKind.Property,data:{properties:{}}}],PathMap:[{label:"/newPath",kind:Re.CompletionItemKind.Property,data:{properties:{}},sortText:Ne("PathMap")}],MediaTypeMap:[{label:"mime/type",kind:Re.CompletionItemKind.Property,data:{properties:{}},sortText:Ne("MediaTypeMap")},{label:"application/json",kind:Re.CompletionItemKind.Property,data:{properties:{}},sortText:Ne("MediaTypeMap")},{label:"application/octet-stream",kind:Re.CompletionItemKind.Property,data:{properties:{}},sortText:Ne("MediaTypeMap")},{label:"multipart/form-data",kind:Re.CompletionItemKind.Property,data:{properties:{}},sortText:Ne("MediaTypeMap")},{label:"application/x-www-form-urlencoded",kind:Re.CompletionItemKind.Property,data:{properties:{}},sortText:Ne("MediaTypeMap")},{label:"application/xml",kind:Re.CompletionItemKind.Property,data:[],sortText:Ne("MediaTypeMap")}]};var fn=ot(pi(),1);import{normalizeTypes as fp,Oas3Types as w_,Oas2Types as k_,Oas3_1Types as dp,AsyncApi2Types as A_,SpecVersion as Vt,ConfigTypes as q_,getMajorSpecVersion as N_}from"@redocly/openapi-core";var Gc=new Map;async function O_(e,t){let n=await Ht(e),r=n.getText(),i=fn.safeLoad(r,{filename:e.toString()}),{nodePath:o}=Io({node:i,nodePath:[]},t,n,!0),s=Jc(i,e),{currentType:u,parentType:c,endPath:p}=Fo(s,o),g=Yr(i),b=u?.name?u:c;return{nodePath:o,endPath:p,type:b,existingValues:g,types:s}}function pp(e,t){if(!e)return null;let n=e,r=!0;return t.forEach(i=>{if(r=!1,Fs(n)&&n.items&&n.items[i])n=n.items[i],r=!0;else if(El(n)){let o=Wo(n);for(let s of o)if(Is(s)&&s.key?.value===i){n=s?.value,r=!0;break}}}),r?n:(console.warn("Cannot find node by path",t),null)}function E_(e,t){for(let n=0;n<t.length;n++)if(n===t.length-1||t[n+1]>e)return n;return t.length-1}function Io(e,t,n,r=!1){let{node:i,nodePath:o=[]}=e,s=n.offsetAt(t),u=Wo(i);if(u.length===0||M_(i)||!r&&j_(i,n,t))return e;let c=L_(u,s);return Io({nodePath:I_(o,i,u[c],c),node:u[c]},t,n,r)}function M_(e){return e?.kind===fn.Kind.MAPPING&&!e?.value}function j_(e,t,n){let r=t.getText({start:t.positionAt(t._lineOffsets[n.line]),end:n}),i=F_(e,t),o=r?.match(/^\s+/)?.[0]?.length||0;return(/^\s*[\w\-\$\/\{\}]+$/.test(r)?o:n.character)===i}function L_(e,t){for(let n=1;n<e.length;n++){let r=e[n];if(!!r&&r.startPosition>t)return n-1}return e.length-1}function I_(e,t,n,r){return Fs(t)?[...e,r]:Is(n)&&n?.key?.value&&typeof n.key.value=="string"?[...e,n.key.value]:e}function F_(e,t){let n=e?.startPosition??0,r=E_(n,t._lineOffsets);if(r>=0){let i=t._lineOffsets[r];return n-i}return 0}function Fo(e,t){let n=e,r=null,i=new Array(t.length).fill(null);t.forEach((s,u)=>{let c;if(e?.name&&e?.name!==n?.name&&(n=e,r=s),e&&e?.properties&&!Object.keys(e?.properties).length&&e?.items?.properties)c=e.items;else if(e?.properties&&e.properties[s])c=e.properties[s],mi(c)&&(c=c(null,s));else if(e?.additionalProperties&&!mi(e?.additionalProperties))c=e.additionalProperties;else if(mi(e?.additionalProperties)&&s){let p=e.additionalProperties(null,s);p&&(c=p)}c&&(e=c,i[u]=c)}),e?.name&&n?.name&&e?.name!==n?.name&&(r=null);let o=i.every(s=>!!s);return{currentType:o||t[0]==="openapi"||t.length===0?e:null,parentType:o?n:null,endPath:r}}function Jc(e,t){if(Cr(t))return fp(q_).ConfigRoot;let{types:n,isDefault:r}=H_(e);if(!e)return n;let i=r?zc(t):n;return r&&!zc(t)&&e?null:i||n}function W_(e){if(Gc.has(e))return Gc.get(e);let t=fp(U_(e)).Root;return Gc.set(e,t),t}function gp(e){let t,n=!1;if(e?.kind===fn.Kind.MAP)for(let r of e.mappings){let i=r.key?.value,o=String(r?.value?.value);if(i==="openapi"&&o.startsWith("3.1")){t=Vt.OAS3_1;break}if(i==="openapi"&&o.startsWith("3.0")){t=Vt.OAS3_0;break}if(i==="swagger"&&o==="2.0"){t=Vt.OAS2;break}if(i==="asyncapi")return{version:Vt.Async2,isDefault:!1}}return t||(t=Vt.OAS3_1,n=!0),{version:t,isDefault:n}}function mp(e){let{version:t,isDefault:n}=gp(e);return{version:N_(t),isDefault:n}}function H_(e){let{version:t,isDefault:n}=gp(e);return{types:W_(t),isDefault:n}}function Wo(e){switch(e?.kind){case fn.Kind.MAPPING:return[e.key,e.value];case fn.Kind.MAP:return e.mappings;case fn.Kind.SEQ:return e?.items;default:return[]}}function U_(e){switch(e){case Vt.OAS3_1:return dp;case Vt.OAS3_0:return w_;case Vt.OAS2:return k_;case Vt.Async2:return A_;default:return dp}}function Yr(e,t,n){if(typeof t>"u"&&(t={}),typeof n>"u"&&(n=0),!e)return{};let r=e?.mappings||e?.items;if(r){let i=0;for(let o of r)o?.value===null||!o?.value?.value?t[o?.key?.value||i]={value:Ol(o?.value)?o?.value:null,startOffset:o?.key?.value?o.startPosition+o.key.value.length+1:null,endOffset:null,indent:n}:t[o?.key?.value||i]={value:o?.value?.value,rawValue:o?.value?.rawValue||null,startOffset:o?.value?.startPosition||null,endOffset:o?.value?.endPosition||null,indent:n},Object.keys(o?.value||o||{}).includes("items")?(t[o?.key?.value||i]={type:"sequence",startOffset:o.startPosition,endOffset:o.endPosition,indent:n,value:null},Yr(o?.value||o,t[o?.key?.value||i],n+1)):Object.keys(o?.value||o||{}).includes("mappings")&&(t[o?.key?.value||i]={type:"map",startOffset:o.startPosition,endOffset:o.endPosition,indent:n,value:null},Yr(o?.value||o,t[o?.key?.value||i],n+1)),i++}return t}import{mapTypeToComponent as hp}from"@redocly/openapi-core";var Qc={Schema:[{name:"$ref",value:{type:"string",name:"Schema"}}],PathItem:[{name:"$ref",value:{type:"string",name:"PathItem"}}],Parameter:[{name:"$ref",value:{type:"string",name:"Parameter"}}],Response:[{name:"$ref",value:{type:"string",name:"Response"}}],Example:[{name:"$ref",value:{type:"string",name:"Example"}}],RequestBody:[{name:"$ref",value:{type:"string",name:"RequestBody"}}],Header:[{name:"$ref",value:{type:"string",name:"Header"}}],SecuritySchema:[{name:"$ref",value:{type:"string",name:"SecuritySchema"}}],Link:[{name:"$ref",value:{type:"string",name:"Link"}}],Callback:[{name:"$ref",value:{type:"string",name:"Callback"}}]};function yp(e){let t=Qc[e.name];return t&&t.forEach(n=>{e.properties[n.name]=n.value}),e}var Ho=ot(ln(),1),Dt=class{constructor({kind:t,label:n,value:r,textEdit:i,filterText:o,sortText:s,data:u}){this.kind=t||Ho.CompletionItemKind.Value,this.label=n;let{node:c,lineOffset:p,position:g}=u;this.insertText=r??n,this.filterText=o||this.insertText,this.sortText=s,this.textEdit=i||(c.value==null?void 0:this.getTextEdit(c,g,p))}getTextEdit(t,n,r){let i=t.startPosition-r,o=t.singleQuoted||t.doubleQuoted?2:0,s=i+t.value.length+o;return Ho.TextEdit.replace({start:{line:n.line,character:i},end:{line:n.line,character:s}},this.insertText)}};var ur=ot(ln(),1),kn=class{constructor({kind:t,label:n,insertText:r,insertTextFormat:i,filterText:o,sortText:s,data:u}){this.insertTextFormat=i||n.includes("$")?ur.InsertTextFormat.PlainText:ur.InsertTextFormat.Snippet,this.kind=t||ur.CompletionItemKind.Property,this.label=n,this.data=u||{},this.insertText=r??n,this.filterText=o||this.insertText,this.sortText=s,this.command=this.kind===ur.CompletionItemKind.Property?{title:"Suggested values",command:"editor.action.triggerSuggest"}:null}};var Vr={example:"example",default:"default",enum:"enum",ref:"$ref"},Uo=[Vr.default,Vr.example];var Pp=ot(pi(),1);var je={};tu(je,{default:()=>Cp.default});rs(je,ot(Xc()));var Cp=ot(Xc());function z_(e,t){let n=t.slice(0,t.length-1),{currentType:r}=Fo(e,n);if(r?.name){let[i]=Qc[r.name]||[];return i?.value}return null}function $_(e,t){let n=t[t.length-1];if(ql(n))return z_(e,t);let{currentType:r}=Fo(e,t);return Lo(r)?r:r?r?.name&&(r?.name.includes("Map")||r?.name.includes("Named"))?{name:$r,properties:{}}:r:null}async function _p(e,t){let n=await Ht(e),r=n.getText(),i=(0,Pp.safeLoad)(r,{filename:e}),{node:o,nodePath:s}=Io({node:i,nodePath:[]},t,n),u=Jc(i,e),c=$_(u,s),p=n._lineOffsets[t.line],g=n.getText({start:n.positionAt(p),end:t});return{currentAst:i,node:o,nodePath:s,position:t,lineText:g,lineOffset:p,openApiType:c}}async function Rp(e,t){let n=ye.resolvePath(Oe(e)),r=ye.dirname(n),i=await iu(ye.joinPath(r,t),r.path),o=ye.resolvePath(r,i.path);return{refPath:t,refDirPath:i,refDirAbsolutePath:o,isAbsolutePath:t&&(0,je.isAbsolute)(t),docAbsolutePath:n,docAbsoluteDirPath:r,root:"/"}}var Dp=ot(ln(),1);var Bo=class extends Dt{constructor(n){super(n);this.kind=Dp.CompletionItemKind.Folder,this.command={title:"Complete path",command:"editor.action.triggerSuggest",arguments:[]}}};var Sp=ot(ln(),1);var zo=class extends Dt{constructor(t){super(t),this.kind=Sp.CompletionItemKind.File}};var Y_=Ie.supportedLanguages.concat({languageId:"markdown",filePattern:/\.md$/});function V_(e){let{refPath:t,docAbsoluteDirPath:n,isAbsolutePath:r,root:i}=e,o=(0,je.resolve)(n.path,t,".."),s=r?o:(0,je.relative)(n.path,o),u=s&&s!==i?"/":"";return{name:"../",type:1,matchBy:t,sortBy:Ne("FolderCompletion"),value:`${s}${u}`}}async function K_(e,t,n){let r=[],{refDirAbsolutePath:i,docAbsolutePath:o}=n;for(let s of e)try{let u=ye.resolvePath(i,s),c=await Ie.fs.stat(u);c.isFile()&&u.path!==o.path&&t.supportedFiles.some(p=>p.filePattern.test(s))&&r.push({name:s,type:0}),c.isDirectory()&&r.push({name:s,type:1})}catch{continue}return r}function Tp(e,t){let{docAbsoluteDirPath:n,isAbsolutePath:r,refDirAbsolutePath:i,root:o,refPath:s}=t,u=[];return i.path!==o&&u.push(V_(t)),u.concat(e.map(({name:c,type:p})=>{let g=(0,je.resolve)(i.path,c),b=(0,je.relative)(n.path,g),R=s.includes(je.sep)?s.slice(0,s.lastIndexOf(je.sep)+1):s+je.sep,D=r?g:b;if(p===0)return{type:p,name:c,value:D,sortBy:`${Ne("FileCompletion")}${c}`,matchBy:`${R}${c}`};let T=`${c}/`;return{type:p,name:T,value:`${D}${b?"/":""}`,sortBy:`${Ne("FolderCompletion")}${c}`,matchBy:`${R}${c}`}}))}function xp(e,t){let{node:n,lineOffset:r,position:i}=t;return e.map(o=>{let{name:s,value:u,matchBy:c,sortBy:p,type:g}=o,b={label:s,filterText:br(c,n),sortText:p,value:u,data:{lineOffset:r,position:i,node:n}};return g===1?new Bo(b):new zo(b)})}async function wp(e,t){let{node:n}=t,r=n.value??"",i=await Rp(e,r),{refDirAbsolutePath:o}=i,s=[];try{s=await Ie.fs.readDir(o)}catch{return xp(Tp([],i),t)}let u=await K_(s,{supportedFiles:Y_},i);return xp(Tp(u,i),t)}import{isEmptyObject as G_}from"@redocly/openapi-core/lib/utils";function kp(e,t){if(t?.items)return"- "+kp(e,t.items);if(t?.required)return Object.values(t.required).map((n,r)=>`${n}: \${${r+1}}`).join(`
76
+ `);if(e==="openapi"){let n="3.1.0",[r,i,o]=n.split(".");return`\${1:${r}}.\${2:${i}}.\${3:${o}}`}return""}function J_(e,t,n,r){if(e===dn)return"";if(r?.items||r?.required){let i=`
77
77
  `;return n.includes(`
78
78
  `)&&(i+=" "),i}return n.includes(`
79
- `)||!t?"":" "}function J_(e){return e===dn?"":": "}function Q_(e){return e?.includes(":")||e?.includes(": ")?`
80
- `:e?.includes(":")&&!e?.includes(": ")?" ":""}function X_(e,t){return!t||K_(t)?"":e.includes(`
79
+ `)||!t?"":" "}function Q_(e){return e===dn?"":": "}function X_(e){return e?.includes(":")||e?.includes(": ")?`
80
+ `:e?.includes(":")&&!e?.includes(": ")?" ":""}function Z_(e,t){return!t||G_(t)?"":e.includes(`
81
81
  `)?`
82
82
  `:`
83
83
  `}function Kr(e,t,n=!0){if(e===cr)return`
84
- `;let r=Q_(t?.lineText),i=J_(e),o=e===dn?"":e,s=kp(e,t),u=G_(e,s,r,t),c=n?X_(r,t?.properties):" ";return`${r}${o}${i}${u}${s}${c}`}function Z_(e,t){let{version:n}=mp(e),r=hp(t,n);if(!r)return[];let i=pp(e,["components",r]);return i?(Wo(i.value||i)||[]).map(({key:{value:s}})=>`#/components/${r}/${s}`):[]}function e0(e){let{node:t,position:n,lineOffset:r}=e,i=Uo.includes(t.key?.value)?t:Uo.includes(t.parent?.key?.value)?t.parent:null;return i?i?.parent?.mappings?.find(({key:s})=>s?.value===Vr.enum)?.value?.items?.map(({value:s})=>new Dt({label:s,data:{node:t,position:n,lineOffset:r}}))||[]:[]}async function t0(e,t){let{position:n,openApiType:r,currentAst:i,lineOffset:o,node:s}=t,u=Z_(i,r.name);return[...await wp(e,t),...u.map(p=>{let g=br(p,s);return new Dt({label:p,filterText:br(p,s),value:g,sortText:`${Ne("LocalComponentCompletion")}${p}`,data:{lineOffset:o,position:n,node:s}})})]}function n0(e){let{openApiType:t,node:n,position:r,lineOffset:i}=e;return t.enum.map(o=>new Dt({label:o,kind:$o.CompletionItemKind.EnumMember,data:{node:n,position:r,lineOffset:i}}))}function r0(e,t){let{node:n,position:r,lineOffset:i}=t;return["true","false"].map(o=>new Dt({label:o,data:{node:n,position:r,lineOffset:i}}))}function i0(e){let{currentAst:t,nodePath:n,node:r,openApiType:i,lineText:o}=e,s=a0(t,n,r);return c0(i,s,o)}async function o0(e,t){let{node:n,nodePath:r,openApiType:i}=t;if(!n)return[];let o=n.key?.value||(r.length?r[r.length-1]:null);return o&&i?.name&&Vr.ref===o?t0(e,t):Uo.includes(o)?e0(t):i?.enum?n0(t):i?.type==="boolean"?r0(e,t):[]}async function Ap(e,t){let n=await _p(e,t);return n.openApiType?.properties?i0(n):o0(e,n)}function s0(e){return e}function a0(e,t,n){if(!e)return[];let i=Yr(e);for(let u=0;u<t.length;u++)i[t[u]]&&(i=i[t[u]]);let o=i?Object.keys(i).filter(u=>i[u]&&typeof i[u]=="object"):[],s=n?.value?.mappings||n?.mappings;if(s){let u=s.map(c=>c.key?.value||null);o.push(...u)}return!o.length&&n?.value&&o.push(n.value),o}function c0(e,t,n){if(!e)return[];if(yp(e),Lo(e))return Kc(e?.name).filter(r=>!t.includes(r.label)).map(r=>new wn({...r,insertText:Kr(r.label,{...r.data,...e,lineText:n})}));if(e.properties&&Object.keys(e.properties).length){let r=Object.keys(e.properties).filter(i=>!t.includes(i)).map(i=>{let o={...e.properties[i]||{},lineText:n};return new wn({label:i,kind:$o.CompletionItemKind.Property,insertText:Kr(i,o,!o?.items),sortText:Ne(e?.name,i)})});return n.endsWith(":")&&r.push(...Kc(cr).map(i=>new wn({...i,insertText:Kr(i.label,{...i.data,lineText:n})}))),r}return e.items&&Object.keys(e.items).length?[new wn({label:dn,kind:$o.CompletionItemKind.Constructor,insertText:Kr(dn,{...e,lineText:n}),sortText:Ne(dn)})]:[]}var u0=(t=>(t[t.FILE_TYPE_NOT_SUPPORTED=0]="FILE_TYPE_NOT_SUPPORTED",t))(u0||{});var qp=class{async onCompletion(t){let{uri:n}=t.textDocument;return Us(n)?[]:Ap(n,t.position)}async onCompletionResolve(t){return t}async validateOpenAPI(t){return Vc(t)}async onDidChangeWatchedFiles(t){if(t.changes.find(r=>$s.some(i=>r.uri.endsWith(i))))return Mo()}async onDidConfigChange(t){return await Ul(t),Mo()}async onDidChangeConfiguration(){return Mo()}};export{u0 as ContextErrorCodes,qp as OpenapiLanguageServer,Bc as bundleOpenAPI,d_ as getBundles,Ap as getCompletion,Fn as getConfigData,N_ as getContextData,Ht as getDocumentByURI,Cr as isConfigFile,cs as isHttpPath,Us as isJsonFile,Rh as isYamlFile,Ie as languageServerConfig,Oe as parseUri,js as removeCirculars,s0 as resolveCompletion,Mo as revalidateAllDocuments,Ul as updateOpenAPIConfigByURI,as as uriToAbsFSPath,Vc as validateOpenAPI};
84
+ `;let r=X_(t?.lineText),i=Q_(e),o=e===dn?"":e,s=kp(e,t),u=J_(e,s,r,t),c=n?Z_(r,t?.properties):" ";return`${r}${o}${i}${u}${s}${c}`}function e0(e,t){let{version:n}=mp(e),r=hp(t,n);if(!r)return[];let i=pp(e,["components",r]);return i?(Wo(i.value||i)||[]).map(({key:{value:s}})=>`#/components/${r}/${s}`):[]}function t0(e){let{node:t,position:n,lineOffset:r}=e,i=Uo.includes(t.key?.value)?t:Uo.includes(t.parent?.key?.value)?t.parent:null;return i?i?.parent?.mappings?.find(({key:s})=>s?.value===Vr.enum)?.value?.items?.map(({value:s})=>new Dt({label:s,data:{node:t,position:n,lineOffset:r}}))||[]:[]}async function n0(e,t){let{position:n,openApiType:r,currentAst:i,lineOffset:o,node:s}=t,u=e0(i,r.name);return[...await wp(e,t),...u.map(p=>{let g=br(p,s);return new Dt({label:p,filterText:br(p,s),value:g,sortText:`${Ne("LocalComponentCompletion")}${p}`,data:{lineOffset:o,position:n,node:s}})})]}function r0(e){let{openApiType:t,node:n,position:r,lineOffset:i}=e;return t.enum.map(o=>new Dt({label:o,kind:$o.CompletionItemKind.EnumMember,data:{node:n,position:r,lineOffset:i}}))}function i0(e,t){let{node:n,position:r,lineOffset:i}=t;return["true","false"].map(o=>new Dt({label:o,data:{node:n,position:r,lineOffset:i}}))}function o0(e){let{currentAst:t,nodePath:n,node:r,openApiType:i,lineText:o}=e,s=c0(t,n,r);return u0(i,s,o)}async function s0(e,t){let{node:n,nodePath:r,openApiType:i}=t;if(!n)return[];let o=n.key?.value||(r.length?r[r.length-1]:null);return o&&i?.name&&Vr.ref===o?n0(e,t):Uo.includes(o)?t0(t):i?.enum?r0(t):i?.type==="boolean"?i0(e,t):[]}async function Ap(e,t){let n=await _p(e,t);return n.openApiType?.properties?o0(n):s0(e,n)}function a0(e){return e}function c0(e,t,n){if(!e)return[];let i=Yr(e);for(let u=0;u<t.length;u++)i[t[u]]&&(i=i[t[u]]);let o=i?Object.keys(i).filter(u=>i[u]&&typeof i[u]=="object"):[],s=n?.value?.mappings||n?.mappings;if(s){let u=s.map(c=>c.key?.value||null);o.push(...u)}return!o.length&&n?.value&&o.push(n.value),o}function u0(e,t,n){if(!e)return[];if(yp(e),Lo(e))return Kc(e?.name).filter(r=>!t.includes(r.label)).map(r=>new kn({...r,insertText:Kr(r.label,{...r.data,...e,lineText:n})}));if(e.properties&&Object.keys(e.properties).length){let r=Object.keys(e.properties).filter(i=>!t.includes(i)).map(i=>{let o={...e.properties[i]||{},lineText:n};return new kn({label:i,kind:$o.CompletionItemKind.Property,insertText:Kr(i,o,!o?.items),sortText:Ne(e?.name,i)})});return n.endsWith(":")&&r.push(...Kc(cr).map(i=>new kn({...i,insertText:Kr(i.label,{...i.data,lineText:n})}))),r}return e.items&&Object.keys(e.items).length?[new kn({label:dn,kind:$o.CompletionItemKind.Constructor,insertText:Kr(dn,{...e,lineText:n}),sortText:Ne(dn)})]:[]}var l0=(t=>(t[t.FILE_TYPE_NOT_SUPPORTED=0]="FILE_TYPE_NOT_SUPPORTED",t))(l0||{});var qp=class{async onCompletion(t){let{uri:n}=t.textDocument;return Us(n)?[]:Ap(n,t.position)}async onCompletionResolve(t){return t}async validateOpenAPI(t){return Vc(t)}async onDidChangeWatchedFiles(t){if(t.changes.find(r=>$s.some(i=>r.uri.endsWith(i))))return Mo()}async onDidConfigChange(t){return await Ul(t),Mo()}async onDidChangeConfiguration(){return Mo()}};export{l0 as ContextErrorCodes,qp as OpenapiLanguageServer,Bc as bundleOpenAPI,f_ as getBundles,Ap as getCompletion,Wn as getConfigData,O_ as getContextData,Ht as getDocumentByURI,Cr as isConfigFile,cs as isHttpPath,Us as isJsonFile,Rh as isYamlFile,Ie as languageServerConfig,Oe as parseUri,js as removeCirculars,a0 as resolveCompletion,Mo as revalidateAllDocuments,Ul as updateOpenAPIConfigByURI,as as uriToAbsFSPath,Vc as validateOpenAPI};