@openmrs/esm-implementer-tools-app 11.0.1-pre.6090 → 11.0.1-pre.6106
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.
- package/.turbo/turbo-build.log +2 -2
- package/dist/1389.css +1 -1
- package/dist/1389.css.map +1 -1
- package/dist/1389.js +1 -1
- package/dist/1389.js.map +1 -1
- package/dist/1558.js +1 -1
- package/dist/1558.js.map +1 -1
- package/dist/5117.js +1 -1
- package/dist/5117.js.map +1 -1
- package/dist/7649.js +1 -0
- package/dist/7649.js.map +1 -0
- package/dist/openmrs-esm-implementer-tools-app.js +2 -2
- package/dist/openmrs-esm-implementer-tools-app.js.map +1 -1
- package/dist/routes.json +1 -1
- package/package.json +11 -5
- package/src/configuration/json-editor/json-editor.component.tsx +165 -40
- package/src/configuration/json-editor/json-editor.scss +36 -1
- package/src/configuration/json-editor/json-editor.test.tsx +111 -0
- package/translations/en.json +4 -0
- package/dist/50c0d5f65bdef427.js +0 -1
- package/dist/932.js +0 -1
- package/dist/932.js.map +0 -1
package/dist/50c0d5f65bdef427.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
!function(e){if((void 0===e.window||!e.document)&&(!e.require||!e.define)){e.console||(e.console=function(){var e=Array.prototype.slice.call(arguments,0);postMessage({type:"log",data:e})},e.console.error=e.console.warn=e.console.log=e.console.trace=e.console),e.window=e,e.ace=e,e.onerror=function(e,t,r,n,i){postMessage({type:"error",data:{message:e,data:i&&i.data,file:t,line:r,col:n,stack:i&&i.stack}})},e.normalizeModule=function(t,r){if(-1!==r.indexOf("!")){var n=r.split("!");return e.normalizeModule(t,n[0])+"!"+e.normalizeModule(t,n[1])}if("."==r.charAt(0)){var i=t.split("/").slice(0,-1).join("/");for(r=(i?i+"/":"")+r;-1!==r.indexOf(".")&&s!=r;){var s=r;r=r.replace(/^\.\//,"").replace(/\/\.\//,"/").replace(/[^\/]+\/\.\.\//,"")}}return r},e.require=function(t,r){if(r||(r=t,t=null),!r.charAt)throw Error("worker.js require() accepts only (parentId, id) as arguments");r=e.normalizeModule(t,r);var n=e.require.modules[r];if(n)return n.initialized||(n.initialized=!0,n.exports=n.factory().exports),n.exports;if(!e.require.tlns)return console.log("unable to load "+r);var i=function(e,t){for(var r=e,n="";r;){var i=t[r];if("string"==typeof i)return i+n;if(i)return i.location.replace(/\/*$/,"/")+(n||i.main||i.name);if(!1===i)return"";var s=r.lastIndexOf("/");if(-1===s)break;n=r.substr(s)+n,r=r.slice(0,s)}return e}(r,e.require.tlns);return".js"!=i.slice(-3)&&(i+=".js"),e.require.id=r,e.require.modules[r]={},importScripts(i),e.require(t,r)},e.require.modules={},e.require.tlns={},e.define=function(t,r,n){if(2==arguments.length?(n=r,"string"!=typeof t&&(r=t,t=e.require.id)):1==arguments.length&&(n=t,r=[],t=e.require.id),"function"!=typeof n){e.require.modules[t]={exports:n,initialized:!0};return}r.length||(r=["require","exports","module"]);var i=function(r){return e.require(t,r)};e.require.modules[t]={exports:{},factory:function(){var e=this,t=n.apply(this,r.slice(0,n.length).map(function(t){switch(t){case"require":return i;case"exports":return e.exports;case"module":return e;default:return i(t)}}));return t&&(e.exports=t),e}}},e.define.amd={},e.require.tlns={},e.initBaseUrls=function(e){for(var t in e)this.require.tlns[t]=e[t]},e.initSender=function(){var t=e.require("ace/lib/event_emitter").EventEmitter,r=e.require("ace/lib/oop"),n=function(){};return(function(){r.implement(this,t),this.callback=function(e,t){postMessage({type:"call",id:t,data:e})},this.emit=function(e,t){postMessage({type:"event",name:e,data:t})}}).call(n.prototype),new n};var t=e.main=null,r=e.sender=null;e.onmessage=function(n){var i=n.data;if(i.event&&r)r._signal(i.event,i.data);else if(i.command)if(t[i.command])t[i.command].apply(t,i.args);else if(e[i.command])e[i.command].apply(e,i.args);else throw Error("Unknown command:"+i.command);else i.init&&(e.initBaseUrls(i.tlns),r=e.sender=e.initSender(),t=e.main=new(this.require(i.module))[i.classname](r))}}}(this),ace.define("ace/lib/oop",[],function(e,t,r){"use strict";t.inherits=function(e,t){e.super_=t,e.prototype=Object.create(t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}})},t.mixin=function(e,t){for(var r in t)e[r]=t[r];return e},t.implement=function(e,r){t.mixin(e,r)}}),ace.define("ace/lib/event_emitter",[],function(e,t,r){"use strict";var n={},i=function(){this.propagationStopped=!0},s=function(){this.defaultPrevented=!0};n._emit=n._dispatchEvent=function(e,t){this._eventRegistry||(this._eventRegistry={}),this._defaultHandlers||(this._defaultHandlers={});var r=this._eventRegistry[e]||[],n=this._defaultHandlers[e];if(r.length||n){"object"==typeof t&&t||(t={}),t.type||(t.type=e),t.stopPropagation||(t.stopPropagation=i),t.preventDefault||(t.preventDefault=s),r=r.slice();for(var a=0;a<r.length&&(r[a](t,this),!t.propagationStopped);a++);if(n&&!t.defaultPrevented)return n(t,this)}},n._signal=function(e,t){var r=(this._eventRegistry||{})[e];if(r){r=r.slice();for(var n=0;n<r.length;n++)r[n](t,this)}},n.once=function(e,t){var r=this;if(this.on(e,function n(){r.off(e,n),t.apply(null,arguments)}),!t)return new Promise(function(e){t=e})},n.setDefaultHandler=function(e,t){var r=this._defaultHandlers;if(r||(r=this._defaultHandlers={_disabled_:{}}),r[e]){var n=r[e],i=r._disabled_[e];i||(r._disabled_[e]=i=[]),i.push(n);var s=i.indexOf(t);-1!=s&&i.splice(s,1)}r[e]=t},n.removeDefaultHandler=function(e,t){var r=this._defaultHandlers;if(r){var n=r._disabled_[e];if(r[e]==t)n&&this.setDefaultHandler(e,n.pop());else if(n){var i=n.indexOf(t);-1!=i&&n.splice(i,1)}}},n.on=n.addEventListener=function(e,t,r){this._eventRegistry=this._eventRegistry||{};var n=this._eventRegistry[e];return n||(n=this._eventRegistry[e]=[]),-1==n.indexOf(t)&&n[r?"unshift":"push"](t),t},n.off=n.removeListener=n.removeEventListener=function(e,t){this._eventRegistry=this._eventRegistry||{};var r=this._eventRegistry[e];if(r){var n=r.indexOf(t);-1!==n&&r.splice(n,1)}},n.removeAllListeners=function(e){e||(this._eventRegistry=this._defaultHandlers=void 0),this._eventRegistry&&(this._eventRegistry[e]=void 0),this._defaultHandlers&&(this._defaultHandlers[e]=void 0)},t.EventEmitter=n}),ace.define("ace/mode/json_worker",[],function(e,t,r){"use strict";var n=(()=>{let e,t,r,n;var i,s,a,o,l,c,u,f,h,d,m,p,g,y,v,b,w,x,A,$,k,S,O,C,I,E,P,T,M,_,L,j,R,N,U,V,D,q,F,B,H,z,W,K,J,Z,X,G,Q,Y,ee,et,er,en,ei,es,ea,eo,el,ec,eu,ef,eh,ed,em,ep,eg,ey,ev,eb,ew,ex,eA,e$,ek,eS,eO,eC,eI,eE,eP,eT,eM,e_,eL,ej,eR,eN,eU,eV,eD,eq,eF,eB,eH,ez,eW,eK,eJ,eZ,eX,eG,eQ,eY,e0,e1,e2,e4,e5,e9,e3,e7,e6,e8,te,tt,tr,tn,ti,ts,ta,to,tl,tc,tu,tf,th,td,tm,tp,tg,ty,tv,tb,tw,tx,tA,t$,tk,tS,tO,tC,tI,tE,tP,tT,tM,t_,tL,tj,tR,tN,tU,tV,tD,tq,tF=Object.create,tB=Object.defineProperty,tH=Object.getOwnPropertyDescriptor,tz=Object.getOwnPropertyNames,tW=Object.getPrototypeOf,tK=Object.prototype.hasOwnProperty,tJ=Math.pow,tZ=(e,t)=>function(){return t||(0,e[tz(e)[0]])((t={exports:{}}).exports,t),t.exports},tX=(e,t,r,n)=>{if(t&&"object"==typeof t||"function"==typeof t)for(let i of tz(t))tK.call(e,i)||i===r||tB(e,i,{get:()=>t[i],enumerable:!(n=tH(t,i))||n.enumerable});return e},tG=(e,t,r)=>{let n;return(n="symbol"!=typeof t?t+"":t)in e?tB(e,n,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[n]=r},tQ=tZ({"../../node_modules/ace-code/src/lib/deep_copy.js"(e){e.deepCopy=function e(t){var r;if("object"!=typeof t||!t)return t;if(Array.isArray(t)){r=[];for(let n=0;n<t.length;n++)r[n]=e(t[n]);return r}if("[object Object]"!==Object.prototype.toString.call(t))return t;for(let n in r={},t)r[n]=e(t[n]);return r}}}),tY=tZ({"../../node_modules/ace-code/src/lib/lang.js"(e){e.last=function(e){return e[e.length-1]},e.stringReverse=function(e){return e.split("").reverse().join("")},e.stringRepeat=function(e,t){for(var r="";t>0;)1&t&&(r+=e),(t>>=1)&&(e+=e);return r};var t=/^\s\s*/,r=/\s\s*$/;e.stringTrimLeft=function(e){return e.replace(t,"")},e.stringTrimRight=function(e){return e.replace(r,"")},e.copyObject=function(e){var t={};for(var r in e)t[r]=e[r];return t},e.copyArray=function(e){for(var t=[],r=0,n=e.length;r<n;r++)e[r]&&"object"==typeof e[r]?t[r]=this.copyObject(e[r]):t[r]=e[r];return t},e.deepCopy=tQ().deepCopy,e.arrayToMap=function(e){for(var t={},r=0;r<e.length;r++)t[e[r]]=1;return t},e.createMap=function(e){var t=Object.create(null);for(var r in e)t[r]=e[r];return t},e.arrayRemove=function(e,t){for(var r=0;r<=e.length;r++)t===e[r]&&e.splice(r,1)},e.escapeRegExp=function(e){return e.replace(/([.*+?^${}()|[\]\/\\])/g,"\\$1")},e.escapeHTML=function(e){return(""+e).replace(/&/g,"&").replace(/"/g,""").replace(/'/g,"'").replace(/</g,"<")},e.getMatchOffsets=function(e,t){var r=[];return e.replace(t,function(e){r.push({offset:arguments[arguments.length-2],length:e.length})}),r},e.deferredCall=function(e){var t=null,r=function(){t=null,e()},n=function(e){return n.cancel(),t=setTimeout(r,e||0),n};return n.schedule=n,n.call=function(){return this.cancel(),e(),n},n.cancel=function(){return clearTimeout(t),t=null,n},n.isPending=function(){return t},n},e.delayedCall=function(e,t){var r=null,n=function(){r=null,e()},i=function(e){null==r&&(r=setTimeout(n,e||t))};return i.delay=function(e){r&&clearTimeout(r),r=setTimeout(n,e||t)},i.schedule=i,i.call=function(){this.cancel(),e()},i.cancel=function(){r&&clearTimeout(r),r=null},i.isPending=function(){return r},i},e.supportsLookbehind=function(){try{RegExp("(?<=.)")}catch(e){return!1}return!0},e.skipEmptyMatch=function(e,t,r){return r&&e.codePointAt(t)>65535?2:1}}}),t0=tZ({"../../node_modules/ace-code/src/lib/oop.js"(e){e.inherits=function(e,t){e.super_=t,e.prototype=Object.create(t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}})},e.mixin=function(e,t){for(var r in t)e[r]=t[r];return e},e.implement=function(t,r){e.mixin(t,r)}}}),t1=tZ({"../../node_modules/ace-code/src/apply_delta.js"(e){e.applyDelta=function(e,t,r){var n=t.start.row,i=t.start.column,s=e[n]||"";switch(t.action){case"insert":if(1===t.lines.length)e[n]=s.substring(0,i)+t.lines[0]+s.substring(i);else{var a=[n,1].concat(t.lines);e.splice.apply(e,a),e[n]=s.substring(0,i)+e[n],e[n+t.lines.length-1]+=s.substring(i)}break;case"remove":var o=t.end.column,l=t.end.row;n===l?e[n]=s.substring(0,i)+s.substring(o):e.splice(n,l-n+1,s.substring(0,i)+e[l].substring(o))}}}}),t2=tZ({"../../node_modules/ace-code/src/lib/event_emitter.js"(e){var t={},r=function(){this.propagationStopped=!0},n=function(){this.defaultPrevented=!0};t._emit=t._dispatchEvent=function(e,t){this._eventRegistry||(this._eventRegistry={}),this._defaultHandlers||(this._defaultHandlers={});var i=this._eventRegistry[e]||[],s=this._defaultHandlers[e];if(i.length||s){"object"==typeof t&&t||(t={}),t.type||(t.type=e),t.stopPropagation||(t.stopPropagation=r),t.preventDefault||(t.preventDefault=n),i=i.slice();for(var a=0;a<i.length&&(i[a](t,this),!t.propagationStopped);a++);if(s&&!t.defaultPrevented)return s(t,this)}},t._signal=function(e,t){var r=(this._eventRegistry||{})[e];if(r){r=r.slice();for(var n=0;n<r.length;n++)r[n](t,this)}},t.once=function(e,t){var r=this;if(this.on(e,function n(){r.off(e,n),t.apply(null,arguments)}),!t)return new Promise(function(e){t=e})},t.setDefaultHandler=function(e,t){var r=this._defaultHandlers;if(r||(r=this._defaultHandlers={_disabled_:{}}),r[e]){var n=r[e],i=r._disabled_[e];i||(r._disabled_[e]=i=[]),i.push(n);var s=i.indexOf(t);-1!=s&&i.splice(s,1)}r[e]=t},t.removeDefaultHandler=function(e,t){var r=this._defaultHandlers;if(r){var n=r._disabled_[e];if(r[e]==t)n&&this.setDefaultHandler(e,n.pop());else if(n){var i=n.indexOf(t);-1!=i&&n.splice(i,1)}}},t.on=t.addEventListener=function(e,t,r){this._eventRegistry=this._eventRegistry||{};var n=this._eventRegistry[e];return n||(n=this._eventRegistry[e]=[]),-1==n.indexOf(t)&&n[r?"unshift":"push"](t),t},t.off=t.removeListener=t.removeEventListener=function(e,t){this._eventRegistry=this._eventRegistry||{};var r=this._eventRegistry[e];if(r){var n=r.indexOf(t);-1!==n&&r.splice(n,1)}},t.removeAllListeners=function(e){e||(this._eventRegistry=this._defaultHandlers=void 0),this._eventRegistry&&(this._eventRegistry[e]=void 0),this._defaultHandlers&&(this._defaultHandlers[e]=void 0)},e.EventEmitter=t}}),t4=tZ({"../../node_modules/ace-code/src/range.js"(e){var t=class e{constructor(e,t,r,n){this.start={row:e,column:t},this.end={row:r,column:n}}isEqual(e){return this.start.row===e.start.row&&this.end.row===e.end.row&&this.start.column===e.start.column&&this.end.column===e.end.column}toString(){return"Range: ["+this.start.row+"/"+this.start.column+"] -> ["+this.end.row+"/"+this.end.column+"]"}contains(e,t){return 0==this.compare(e,t)}compareRange(e){var t,r=e.end,n=e.start;return 1==(t=this.compare(r.row,r.column))?1==(t=this.compare(n.row,n.column))?2:+(0==t):-1==t?-2:-1==(t=this.compare(n.row,n.column))?-1:42*(1==t)}comparePoint(e){return this.compare(e.row,e.column)}containsRange(e){return 0==this.comparePoint(e.start)&&0==this.comparePoint(e.end)}intersects(e){var t=this.compareRange(e);return -1==t||0==t||1==t}isEnd(e,t){return this.end.row==e&&this.end.column==t}isStart(e,t){return this.start.row==e&&this.start.column==t}setStart(e,t){"object"==typeof e?(this.start.column=e.column,this.start.row=e.row):(this.start.row=e,this.start.column=t)}setEnd(e,t){"object"==typeof e?(this.end.column=e.column,this.end.row=e.row):(this.end.row=e,this.end.column=t)}inside(e,t){if(0==this.compare(e,t)&&!(this.isEnd(e,t)||this.isStart(e,t)))return!0;return!1}insideStart(e,t){if(0==this.compare(e,t)&&!this.isEnd(e,t))return!0;return!1}insideEnd(e,t){if(0==this.compare(e,t)&&!this.isStart(e,t))return!0;return!1}compare(e,t){return this.isMultiLine()||e!==this.start.row?e<this.start.row?-1:e>this.end.row?1:this.start.row===e?t>=this.start.column?0:-1:this.end.row===e?t<=this.end.column?0:1:0:t<this.start.column?-1:+(t>this.end.column)}compareStart(e,t){return this.start.row==e&&this.start.column==t?-1:this.compare(e,t)}compareEnd(e,t){return this.end.row==e&&this.end.column==t?1:this.compare(e,t)}compareInside(e,t){return this.end.row==e&&this.end.column==t?1:this.start.row==e&&this.start.column==t?-1:this.compare(e,t)}clipRows(t,r){if(this.end.row>r)var n={row:r+1,column:0};else if(this.end.row<t)var n={row:t,column:0};if(this.start.row>r)var i={row:r+1,column:0};else if(this.start.row<t)var i={row:t,column:0};return e.fromPoints(i||this.start,n||this.end)}extend(t,r){var n=this.compare(t,r);if(0==n)return this;if(-1==n)var i={row:t,column:r};else var s={row:t,column:r};return e.fromPoints(i||this.start,s||this.end)}isEmpty(){return this.start.row===this.end.row&&this.start.column===this.end.column}isMultiLine(){return this.start.row!==this.end.row}clone(){return e.fromPoints(this.start,this.end)}collapseRows(){return 0==this.end.column?new e(this.start.row,0,Math.max(this.start.row,this.end.row-1),0):new e(this.start.row,0,this.end.row,0)}toScreenRange(t){var r=t.documentToScreenPosition(this.start),n=t.documentToScreenPosition(this.end);return new e(r.row,r.column,n.row,n.column)}moveBy(e,t){this.start.row+=e,this.start.column+=t,this.end.row+=e,this.end.column+=t}};t.fromPoints=function(e,r){return new t(e.row,e.column,r.row,r.column)},t.comparePoints=function(e,t){return e.row-t.row||e.column-t.column},e.Range=t}}),t5={},t9={JsonWorker:()=>nr};for(var t3 in t9)tB(t5,t3,{get:t9[t3],enumerable:!0});var t7=(r=null!=(e=tY())?tF(tW(e)):{},tX(!t&&e&&e.__esModule?r:tB(r,"default",{value:e,enumerable:!0}),e)),t6=t0(),t8=t1().applyDelta,re=t2().EventEmitter,rt=t4().Range,rr=class{constructor(e){this.$autoNewLine="",this.$newLineMode="auto",this.$lines=[""],0===e.length?this.$lines=[""]:Array.isArray(e)?this.insertMergedLines({row:0,column:0},e):this.insert({row:0,column:0},e)}setValue(e){var t=this.getLength()-1;this.remove(new rt(0,0,t,this.getLine(t).length)),this.insert({row:0,column:0},e||"")}getValue(){return this.getAllLines().join(this.getNewLineCharacter())}$detectNewLine(e){var t=e.match(/^.*?(\r\n|\r|\n)/m);this.$autoNewLine=t?t[1]:"\n",this._signal("changeNewLineMode")}getNewLineCharacter(){switch(this.$newLineMode){case"windows":return"\r\n";case"unix":return"\n";default:return this.$autoNewLine||"\n"}}setNewLineMode(e){this.$newLineMode!==e&&(this.$newLineMode=e,this._signal("changeNewLineMode"))}getNewLineMode(){return this.$newLineMode}isNewLine(e){return"\r\n"==e||"\r"==e||"\n"==e}getLine(e){return this.$lines[e]||""}getLines(e,t){return this.$lines.slice(e,t+1)}getAllLines(){return this.getLines(0,this.getLength())}getLength(){return this.$lines.length}getTextRange(e){return this.getLinesForRange(e).join(this.getNewLineCharacter())}getLinesForRange(e){var t;if(e.start.row===e.end.row)t=[this.getLine(e.start.row).substring(e.start.column,e.end.column)];else{(t=this.getLines(e.start.row,e.end.row))[0]=(t[0]||"").substring(e.start.column);var r=t.length-1;e.end.row-e.start.row==r&&(t[r]=t[r].substring(0,e.end.column))}return t}insert(e,t){return 1>=this.getLength()&&this.$detectNewLine(t),this.insertMergedLines(e,this.$split(t))}insertInLine(e,t){var r=this.clippedPos(e.row,e.column),n=this.pos(e.row,e.column+t.length);return this.applyDelta({start:r,end:n,action:"insert",lines:[t]},!0),this.clonePos(n)}clippedPos(e,t){var r=this.getLength();void 0===e?e=r:e<0?e=0:e>=r&&(e=r-1,t=void 0);var n=this.getLine(e);return void 0==t&&(t=n.length),t=Math.min(Math.max(t,0),n.length),{row:e,column:t}}clonePos(e){return{row:e.row,column:e.column}}pos(e,t){return{row:e,column:t}}$clipPosition(e){var t=this.getLength();return e.row>=t?(e.row=Math.max(0,t-1),e.column=this.getLine(t-1).length):(e.row=Math.max(0,e.row),e.column=Math.min(Math.max(e.column,0),this.getLine(e.row).length)),e}insertFullLines(e,t){e=Math.min(Math.max(e,0),this.getLength());var r=0;e<this.getLength()?(t=t.concat([""]),r=0):(t=[""].concat(t),e--,r=this.$lines[e].length),this.insertMergedLines({row:e,column:r},t)}insertMergedLines(e,t){var r=this.clippedPos(e.row,e.column),n={row:r.row+t.length-1,column:(1==t.length?r.column:0)+t[t.length-1].length};return this.applyDelta({start:r,end:n,action:"insert",lines:t}),this.clonePos(n)}remove(e){var t=this.clippedPos(e.start.row,e.start.column),r=this.clippedPos(e.end.row,e.end.column);return this.applyDelta({start:t,end:r,action:"remove",lines:this.getLinesForRange({start:t,end:r})}),this.clonePos(t)}removeInLine(e,t,r){var n=this.clippedPos(e,t),i=this.clippedPos(e,r);return this.applyDelta({start:n,end:i,action:"remove",lines:this.getLinesForRange({start:n,end:i})},!0),this.clonePos(n)}removeFullLines(e,t){e=Math.min(Math.max(0,e),this.getLength()-1);var r=(t=Math.min(Math.max(0,t),this.getLength()-1))==this.getLength()-1&&e>0,n=t<this.getLength()-1,i=r?e-1:e,s=r?this.getLine(i).length:0,a=n?t+1:t,o=n?0:this.getLine(a).length,l=new rt(i,s,a,o),c=this.$lines.slice(e,t+1);return this.applyDelta({start:l.start,end:l.end,action:"remove",lines:this.getLinesForRange(l)}),c}removeNewLine(e){e<this.getLength()-1&&e>=0&&this.applyDelta({start:this.pos(e,this.getLine(e).length),end:this.pos(e+1,0),action:"remove",lines:["",""]})}replace(e,t){return(e instanceof rt||(e=rt.fromPoints(e.start,e.end)),0===t.length&&e.isEmpty())?e.start:t==this.getTextRange(e)?e.end:(this.remove(e),t?this.insert(e.start,t):e.start)}applyDeltas(e){for(var t=0;t<e.length;t++)this.applyDelta(e[t])}revertDeltas(e){for(var t=e.length-1;t>=0;t--)this.revertDelta(e[t])}applyDelta(e,t){var r="insert"==e.action;(r?!(e.lines.length<=1)||e.lines[0]:rt.comparePoints(e.start,e.end))&&(r&&e.lines.length>2e4?this.$splitAndapplyLargeDelta(e,2e4):(t8(this.$lines,e,t),this._signal("change",e)))}$safeApplyDelta(e){var t=this.$lines.length;("remove"==e.action&&e.start.row<t&&e.end.row<t||"insert"==e.action&&e.start.row<=t)&&this.applyDelta(e)}$splitAndapplyLargeDelta(e,t){for(var r=e.lines,n=r.length-t+1,i=e.start.row,s=e.start.column,a=0,o=0;a<n;a=o){o+=t-1;var l=r.slice(a,o);l.push(""),this.applyDelta({start:this.pos(i+a,s),end:this.pos(i+o,s=0),action:e.action,lines:l},!0)}e.lines=r.slice(a),e.start.row=i+a,e.start.column=s,this.applyDelta(e,!0)}revertDelta(e){this.$safeApplyDelta({start:this.clonePos(e.start),end:this.clonePos(e.end),action:"insert"==e.action?"remove":"insert",lines:e.lines.slice()})}indexToPosition(e,t){for(var r=this.$lines||this.getAllLines(),n=this.getNewLineCharacter().length,i=t||0,s=r.length;i<s;i++)if((e-=r[i].length+n)<0)return{row:i,column:e+r[i].length+n};return{row:s-1,column:e+r[s-1].length+n}}positionToIndex(e,t){for(var r=this.$lines||this.getAllLines(),n=this.getNewLineCharacter().length,i=0,s=Math.min(e.row,r.length),a=t||0;a<s;++a)i+=r[a].length+n;return i+e.column}$split(e){return e.split(/\r\n|\r|\n/)}};t6.implement(rr.prototype,re);var rn=class{constructor(e){this.$timeout=500,this.sender=e;var t=this.doc=new rr(""),r=this.deferredUpdate=t7.delayedCall(this.onUpdate.bind(this)),n=this;e.on("change",function(e){var i=e.data;if(i[0].start)t.applyDeltas(i);else for(var s,a,o=0;o<i.length;o+=2){if(("insert"==(s=Array.isArray(i[o+1])?{action:"insert",start:i[o],lines:i[o+1]}:{action:"remove",start:i[o],end:i[o+1]}).action?s.start:s.end).row>=t.$lines.length)throw(a=Error("Invalid delta")).data={path:n.$path,linesLength:t.$lines.length,start:s.start,end:s.end},a;t.applyDelta(s,!0)}if(n.$timeout)return r.schedule(n.$timeout);n.onUpdate()})}setTimeout(e){this.$timeout=e}setValue(e){this.doc.setValue(e),this.deferredUpdate.schedule(this.$timeout)}getValue(e){this.sender.callback(this.doc.getValue(),e)}isPending(){return this.deferredUpdate.isPending()}};(em||(em={})).is=function(e){return"string"==typeof e},(ep||(ep={})).is=function(e){return"string"==typeof e},(i=eg||(eg={})).MIN_VALUE=-0x80000000,i.MAX_VALUE=0x7fffffff,i.is=function(e){return"number"==typeof e&&i.MIN_VALUE<=e&&e<=i.MAX_VALUE},(s=ey||(ey={})).MIN_VALUE=0,s.MAX_VALUE=0x7fffffff,s.is=function(e){return"number"==typeof e&&s.MIN_VALUE<=e&&e<=s.MAX_VALUE},(a=ev||(ev={})).create=function(e,t){return e===Number.MAX_VALUE&&(e=ey.MAX_VALUE),t===Number.MAX_VALUE&&(t=ey.MAX_VALUE),{line:e,character:t}},a.is=function(e){return tE.objectLiteral(e)&&tE.uinteger(e.line)&&tE.uinteger(e.character)},(o=eb||(eb={})).create=function(e,t,r,n){if(tE.uinteger(e)&&tE.uinteger(t)&&tE.uinteger(r)&&tE.uinteger(n))return{start:ev.create(e,t),end:ev.create(r,n)};if(ev.is(e)&&ev.is(t))return{start:e,end:t};throw Error(`Range#create called with invalid arguments[${e}, ${t}, ${r}, ${n}]`)},o.is=function(e){return tE.objectLiteral(e)&&ev.is(e.start)&&ev.is(e.end)},(l=ew||(ew={})).create=function(e,t){return{uri:e,range:t}},l.is=function(e){return tE.objectLiteral(e)&&eb.is(e.range)&&(tE.string(e.uri)||tE.undefined(e.uri))},(c=ex||(ex={})).create=function(e,t,r,n){return{targetUri:e,targetRange:t,targetSelectionRange:r,originSelectionRange:n}},c.is=function(e){return tE.objectLiteral(e)&&eb.is(e.targetRange)&&tE.string(e.targetUri)&&eb.is(e.targetSelectionRange)&&(eb.is(e.originSelectionRange)||tE.undefined(e.originSelectionRange))},(u=eA||(eA={})).create=function(e,t,r,n){return{red:e,green:t,blue:r,alpha:n}},u.is=function(e){return tE.objectLiteral(e)&&tE.numberRange(e.red,0,1)&&tE.numberRange(e.green,0,1)&&tE.numberRange(e.blue,0,1)&&tE.numberRange(e.alpha,0,1)},(f=e$||(e$={})).create=function(e,t){return{range:e,color:t}},f.is=function(e){return tE.objectLiteral(e)&&eb.is(e.range)&&eA.is(e.color)},(h=ek||(ek={})).create=function(e,t,r){return{label:e,textEdit:t,additionalTextEdits:r}},h.is=function(e){return tE.objectLiteral(e)&&tE.string(e.label)&&(tE.undefined(e.textEdit)||e_.is(e))&&(tE.undefined(e.additionalTextEdits)||tE.typedArray(e.additionalTextEdits,e_.is))},(d=eS||(eS={})).Comment="comment",d.Imports="imports",d.Region="region",(m=eO||(eO={})).create=function(e,t,r,n,i,s){let a={startLine:e,endLine:t};return tE.defined(r)&&(a.startCharacter=r),tE.defined(n)&&(a.endCharacter=n),tE.defined(i)&&(a.kind=i),tE.defined(s)&&(a.collapsedText=s),a},m.is=function(e){return tE.objectLiteral(e)&&tE.uinteger(e.startLine)&&tE.uinteger(e.startLine)&&(tE.undefined(e.startCharacter)||tE.uinteger(e.startCharacter))&&(tE.undefined(e.endCharacter)||tE.uinteger(e.endCharacter))&&(tE.undefined(e.kind)||tE.string(e.kind))},(p=eC||(eC={})).create=function(e,t){return{location:e,message:t}},p.is=function(e){return tE.defined(e)&&ew.is(e.location)&&tE.string(e.message)},(g=eI||(eI={})).Error=1,g.Warning=2,g.Information=3,g.Hint=4,(y=eE||(eE={})).Unnecessary=1,y.Deprecated=2,(eP||(eP={})).is=function(e){return tE.objectLiteral(e)&&tE.string(e.href)},(v=eT||(eT={})).create=function(e,t,r,n,i,s){let a={range:e,message:t};return tE.defined(r)&&(a.severity=r),tE.defined(n)&&(a.code=n),tE.defined(i)&&(a.source=i),tE.defined(s)&&(a.relatedInformation=s),a},v.is=function(e){var t;return tE.defined(e)&&eb.is(e.range)&&tE.string(e.message)&&(tE.number(e.severity)||tE.undefined(e.severity))&&(tE.integer(e.code)||tE.string(e.code)||tE.undefined(e.code))&&(tE.undefined(e.codeDescription)||tE.string(null==(t=e.codeDescription)?void 0:t.href))&&(tE.string(e.source)||tE.undefined(e.source))&&(tE.undefined(e.relatedInformation)||tE.typedArray(e.relatedInformation,eC.is))},(b=eM||(eM={})).create=function(e,t,...r){let n={title:e,command:t};return tE.defined(r)&&r.length>0&&(n.arguments=r),n},b.is=function(e){return tE.defined(e)&&tE.string(e.title)&&tE.string(e.command)},(w=e_||(e_={})).replace=function(e,t){return{range:e,newText:t}},w.insert=function(e,t){return{range:{start:e,end:e},newText:t}},w.del=function(e){return{range:e,newText:""}},w.is=function(e){return tE.objectLiteral(e)&&tE.string(e.newText)&&eb.is(e.range)},(x=eL||(eL={})).create=function(e,t,r){let n={label:e};return void 0!==t&&(n.needsConfirmation=t),void 0!==r&&(n.description=r),n},x.is=function(e){return tE.objectLiteral(e)&&tE.string(e.label)&&(tE.boolean(e.needsConfirmation)||void 0===e.needsConfirmation)&&(tE.string(e.description)||void 0===e.description)},(ej||(ej={})).is=function(e){return tE.string(e)},(A=eR||(eR={})).replace=function(e,t,r){return{range:e,newText:t,annotationId:r}},A.insert=function(e,t,r){return{range:{start:e,end:e},newText:t,annotationId:r}},A.del=function(e,t){return{range:e,newText:"",annotationId:t}},A.is=function(e){return e_.is(e)&&(eL.is(e.annotationId)||ej.is(e.annotationId))},($=eN||(eN={})).create=function(e,t){return{textDocument:e,edits:t}},$.is=function(e){return tE.defined(e)&&eH.is(e.textDocument)&&Array.isArray(e.edits)},(k=eU||(eU={})).create=function(e,t,r){let n={kind:"create",uri:e};return void 0!==t&&(void 0!==t.overwrite||void 0!==t.ignoreIfExists)&&(n.options=t),void 0!==r&&(n.annotationId=r),n},k.is=function(e){return e&&"create"===e.kind&&tE.string(e.uri)&&(void 0===e.options||(void 0===e.options.overwrite||tE.boolean(e.options.overwrite))&&(void 0===e.options.ignoreIfExists||tE.boolean(e.options.ignoreIfExists)))&&(void 0===e.annotationId||ej.is(e.annotationId))},(S=eV||(eV={})).create=function(e,t,r,n){let i={kind:"rename",oldUri:e,newUri:t};return void 0!==r&&(void 0!==r.overwrite||void 0!==r.ignoreIfExists)&&(i.options=r),void 0!==n&&(i.annotationId=n),i},S.is=function(e){return e&&"rename"===e.kind&&tE.string(e.oldUri)&&tE.string(e.newUri)&&(void 0===e.options||(void 0===e.options.overwrite||tE.boolean(e.options.overwrite))&&(void 0===e.options.ignoreIfExists||tE.boolean(e.options.ignoreIfExists)))&&(void 0===e.annotationId||ej.is(e.annotationId))},(O=eD||(eD={})).create=function(e,t,r){let n={kind:"delete",uri:e};return void 0!==t&&(void 0!==t.recursive||void 0!==t.ignoreIfNotExists)&&(n.options=t),void 0!==r&&(n.annotationId=r),n},O.is=function(e){return e&&"delete"===e.kind&&tE.string(e.uri)&&(void 0===e.options||(void 0===e.options.recursive||tE.boolean(e.options.recursive))&&(void 0===e.options.ignoreIfNotExists||tE.boolean(e.options.ignoreIfNotExists)))&&(void 0===e.annotationId||ej.is(e.annotationId))},(eq||(eq={})).is=function(e){return e&&(void 0!==e.changes||void 0!==e.documentChanges)&&(void 0===e.documentChanges||e.documentChanges.every(e=>tE.string(e.kind)?eU.is(e)||eV.is(e)||eD.is(e):eN.is(e)))},(C=eF||(eF={})).create=function(e){return{uri:e}},C.is=function(e){return tE.defined(e)&&tE.string(e.uri)},(I=eB||(eB={})).create=function(e,t){return{uri:e,version:t}},I.is=function(e){return tE.defined(e)&&tE.string(e.uri)&&tE.integer(e.version)},(E=eH||(eH={})).create=function(e,t){return{uri:e,version:t}},E.is=function(e){return tE.defined(e)&&tE.string(e.uri)&&(null===e.version||tE.integer(e.version))},(P=ez||(ez={})).create=function(e,t,r,n){return{uri:e,languageId:t,version:r,text:n}},P.is=function(e){return tE.defined(e)&&tE.string(e.uri)&&tE.string(e.languageId)&&tE.integer(e.version)&&tE.string(e.text)},(T=eW||(eW={})).PlainText="plaintext",T.Markdown="markdown",T.is=function(e){return e===T.PlainText||e===T.Markdown},(eK||(eK={})).is=function(e){return tE.objectLiteral(e)&&eW.is(e.kind)&&tE.string(e.value)},(M=eJ||(eJ={})).Text=1,M.Method=2,M.Function=3,M.Constructor=4,M.Field=5,M.Variable=6,M.Class=7,M.Interface=8,M.Module=9,M.Property=10,M.Unit=11,M.Value=12,M.Enum=13,M.Keyword=14,M.Snippet=15,M.Color=16,M.File=17,M.Reference=18,M.Folder=19,M.EnumMember=20,M.Constant=21,M.Struct=22,M.Event=23,M.Operator=24,M.TypeParameter=25,(_=eZ||(eZ={})).PlainText=1,_.Snippet=2,(eX||(eX={})).Deprecated=1,(L=eG||(eG={})).create=function(e,t,r){return{newText:e,insert:t,replace:r}},L.is=function(e){return e&&tE.string(e.newText)&&eb.is(e.insert)&&eb.is(e.replace)},(j=eQ||(eQ={})).asIs=1,j.adjustIndentation=2,(eY||(eY={})).is=function(e){return e&&(tE.string(e.detail)||void 0===e.detail)&&(tE.string(e.description)||void 0===e.description)},(e0||(e0={})).create=function(e){return{label:e}},(e1||(e1={})).create=function(e,t){return{items:e||[],isIncomplete:!!t}},(R=e2||(e2={})).fromPlainText=function(e){return e.replace(/[\\`*_{}[\]()#+\-.!]/g,"\\$&")},R.is=function(e){return tE.string(e)||tE.objectLiteral(e)&&tE.string(e.language)&&tE.string(e.value)},(e4||(e4={})).is=function(e){return!!e&&tE.objectLiteral(e)&&(eK.is(e.contents)||e2.is(e.contents)||tE.typedArray(e.contents,e2.is))&&(void 0===e.range||eb.is(e.range))},(e5||(e5={})).create=function(e,t){return t?{label:e,documentation:t}:{label:e}},(e9||(e9={})).create=function(e,t,...r){let n={label:e};return tE.defined(t)&&(n.documentation=t),tE.defined(r)?n.parameters=r:n.parameters=[],n},(N=e3||(e3={})).Text=1,N.Read=2,N.Write=3,(e7||(e7={})).create=function(e,t){let r={range:e};return tE.number(t)&&(r.kind=t),r},(U=e6||(e6={})).File=1,U.Module=2,U.Namespace=3,U.Package=4,U.Class=5,U.Method=6,U.Property=7,U.Field=8,U.Constructor=9,U.Enum=10,U.Interface=11,U.Function=12,U.Variable=13,U.Constant=14,U.String=15,U.Number=16,U.Boolean=17,U.Array=18,U.Object=19,U.Key=20,U.Null=21,U.EnumMember=22,U.Struct=23,U.Event=24,U.Operator=25,U.TypeParameter=26,(e8||(e8={})).Deprecated=1,(te||(te={})).create=function(e,t,r,n,i){let s={name:e,kind:t,location:{uri:n,range:r}};return i&&(s.containerName=i),s},(tt||(tt={})).create=function(e,t,r,n){return void 0!==n?{name:e,kind:t,location:{uri:r,range:n}}:{name:e,kind:t,location:{uri:r}}},(V=tr||(tr={})).create=function(e,t,r,n,i,s){let a={name:e,detail:t,kind:r,range:n,selectionRange:i};return void 0!==s&&(a.children=s),a},V.is=function(e){return e&&tE.string(e.name)&&tE.number(e.kind)&&eb.is(e.range)&&eb.is(e.selectionRange)&&(void 0===e.detail||tE.string(e.detail))&&(void 0===e.deprecated||tE.boolean(e.deprecated))&&(void 0===e.children||Array.isArray(e.children))&&(void 0===e.tags||Array.isArray(e.tags))},(D=tn||(tn={})).Empty="",D.QuickFix="quickfix",D.Refactor="refactor",D.RefactorExtract="refactor.extract",D.RefactorInline="refactor.inline",D.RefactorRewrite="refactor.rewrite",D.Source="source",D.SourceOrganizeImports="source.organizeImports",D.SourceFixAll="source.fixAll",(q=ti||(ti={})).Invoked=1,q.Automatic=2,(F=ts||(ts={})).create=function(e,t,r){let n={diagnostics:e};return null!=t&&(n.only=t),null!=r&&(n.triggerKind=r),n},F.is=function(e){return tE.defined(e)&&tE.typedArray(e.diagnostics,eT.is)&&(void 0===e.only||tE.typedArray(e.only,tE.string))&&(void 0===e.triggerKind||e.triggerKind===ti.Invoked||e.triggerKind===ti.Automatic)},(B=ta||(ta={})).create=function(e,t,r){let n={title:e},i=!0;return"string"==typeof t?(i=!1,n.kind=t):eM.is(t)?n.command=t:n.edit=t,i&&void 0!==r&&(n.kind=r),n},B.is=function(e){return e&&tE.string(e.title)&&(void 0===e.diagnostics||tE.typedArray(e.diagnostics,eT.is))&&(void 0===e.kind||tE.string(e.kind))&&(void 0!==e.edit||void 0!==e.command)&&(void 0===e.command||eM.is(e.command))&&(void 0===e.isPreferred||tE.boolean(e.isPreferred))&&(void 0===e.edit||eq.is(e.edit))},(H=to||(to={})).create=function(e,t){let r={range:e};return tE.defined(t)&&(r.data=t),r},H.is=function(e){return tE.defined(e)&&eb.is(e.range)&&(tE.undefined(e.command)||eM.is(e.command))},(z=tl||(tl={})).create=function(e,t){return{tabSize:e,insertSpaces:t}},z.is=function(e){return tE.defined(e)&&tE.uinteger(e.tabSize)&&tE.boolean(e.insertSpaces)},(W=tc||(tc={})).create=function(e,t,r){return{range:e,target:t,data:r}},W.is=function(e){return tE.defined(e)&&eb.is(e.range)&&(tE.undefined(e.target)||tE.string(e.target))},(K=tu||(tu={})).create=function(e,t){return{range:e,parent:t}},K.is=function(e){return tE.objectLiteral(e)&&eb.is(e.range)&&(void 0===e.parent||K.is(e.parent))},(J=tf||(tf={})).namespace="namespace",J.type="type",J.class="class",J.enum="enum",J.interface="interface",J.struct="struct",J.typeParameter="typeParameter",J.parameter="parameter",J.variable="variable",J.property="property",J.enumMember="enumMember",J.event="event",J.function="function",J.method="method",J.macro="macro",J.keyword="keyword",J.modifier="modifier",J.comment="comment",J.string="string",J.number="number",J.regexp="regexp",J.operator="operator",J.decorator="decorator",(Z=th||(th={})).declaration="declaration",Z.definition="definition",Z.readonly="readonly",Z.static="static",Z.deprecated="deprecated",Z.abstract="abstract",Z.async="async",Z.modification="modification",Z.documentation="documentation",Z.defaultLibrary="defaultLibrary",(td||(td={})).is=function(e){return tE.objectLiteral(e)&&(void 0===e.resultId||"string"==typeof e.resultId)&&Array.isArray(e.data)&&(0===e.data.length||"number"==typeof e.data[0])},(X=tm||(tm={})).create=function(e,t){return{range:e,text:t}},X.is=function(e){return null!=e&&eb.is(e.range)&&tE.string(e.text)},(G=tp||(tp={})).create=function(e,t,r){return{range:e,variableName:t,caseSensitiveLookup:r}},G.is=function(e){return null!=e&&eb.is(e.range)&&tE.boolean(e.caseSensitiveLookup)&&(tE.string(e.variableName)||void 0===e.variableName)},(Q=tg||(tg={})).create=function(e,t){return{range:e,expression:t}},Q.is=function(e){return null!=e&&eb.is(e.range)&&(tE.string(e.expression)||void 0===e.expression)},(Y=ty||(ty={})).create=function(e,t){return{frameId:e,stoppedLocation:t}},Y.is=function(e){return tE.defined(e)&&eb.is(e.stoppedLocation)},(ee=tv||(tv={})).Type=1,ee.Parameter=2,ee.is=function(e){return 1===e||2===e},(et=tb||(tb={})).create=function(e){return{value:e}},et.is=function(e){return tE.objectLiteral(e)&&(void 0===e.tooltip||tE.string(e.tooltip)||eK.is(e.tooltip))&&(void 0===e.location||ew.is(e.location))&&(void 0===e.command||eM.is(e.command))},(er=tw||(tw={})).create=function(e,t,r){let n={position:e,label:t};return void 0!==r&&(n.kind=r),n},er.is=function(e){return tE.objectLiteral(e)&&ev.is(e.position)&&(tE.string(e.label)||tE.typedArray(e.label,tb.is))&&(void 0===e.kind||tv.is(e.kind))&&void 0===e.textEdits||tE.typedArray(e.textEdits,e_.is)&&(void 0===e.tooltip||tE.string(e.tooltip)||eK.is(e.tooltip))&&(void 0===e.paddingLeft||tE.boolean(e.paddingLeft))&&(void 0===e.paddingRight||tE.boolean(e.paddingRight))},(tx||(tx={})).createSnippet=function(e){return{kind:"snippet",value:e}},(tA||(tA={})).create=function(e,t,r,n){return{insertText:e,filterText:t,range:r,command:n}},(t$||(t$={})).create=function(e){return{items:e}},(en=tk||(tk={})).Invoked=0,en.Automatic=1,(tS||(tS={})).create=function(e,t){return{range:e,text:t}},(tO||(tO={})).create=function(e,t){return{triggerKind:e,selectedCompletionInfo:t}},(tC||(tC={})).is=function(e){return tE.objectLiteral(e)&&ep.is(e.uri)&&tE.string(e.name)},(ei=tI||(tI={})).create=function(e,t,r,n){return new ri(e,t,r,n)},ei.is=function(e){return!!(tE.defined(e)&&tE.string(e.uri)&&(tE.undefined(e.languageId)||tE.string(e.languageId))&&tE.uinteger(e.lineCount)&&tE.func(e.getText)&&tE.func(e.positionAt)&&tE.func(e.offsetAt))},ei.applyEdits=function(e,t){let r=e.getText(),n=function e(t,r){if(t.length<=1)return t;let n=t.length/2|0,i=t.slice(0,n),s=t.slice(n);e(i,r),e(s,r);let a=0,o=0,l=0;for(;a<i.length&&o<s.length;)0>=r(i[a],s[o])?t[l++]=i[a++]:t[l++]=s[o++];for(;a<i.length;)t[l++]=i[a++];for(;o<s.length;)t[l++]=s[o++];return t}(t,(e,t)=>{let r=e.range.start.line-t.range.start.line;return 0===r?e.range.start.character-t.range.start.character:r}),i=r.length;for(let t=n.length-1;t>=0;t--){let s=n[t],a=e.offsetAt(s.range.start),o=e.offsetAt(s.range.end);if(o<=i)r=r.substring(0,a)+s.newText+r.substring(o,r.length);else throw Error("Overlapping edit");i=a}return r};var ri=class{constructor(e,t,r,n){this._uri=e,this._languageId=t,this._version=r,this._content=n,this._lineOffsets=void 0}get uri(){return this._uri}get languageId(){return this._languageId}get version(){return this._version}getText(e){if(e){let t=this.offsetAt(e.start),r=this.offsetAt(e.end);return this._content.substring(t,r)}return this._content}update(e,t){this._content=e.text,this._version=t,this._lineOffsets=void 0}getLineOffsets(){if(void 0===this._lineOffsets){let e=[],t=this._content,r=!0;for(let n=0;n<t.length;n++){r&&(e.push(n),r=!1);let i=t.charAt(n);r="\r"===i||"\n"===i,"\r"===i&&n+1<t.length&&"\n"===t.charAt(n+1)&&n++}r&&t.length>0&&e.push(t.length),this._lineOffsets=e}return this._lineOffsets}positionAt(e){e=Math.max(Math.min(e,this._content.length),0);let t=this.getLineOffsets(),r=0,n=t.length;if(0===n)return ev.create(0,e);for(;r<n;){let i=Math.floor((r+n)/2);t[i]>e?n=i:r=i+1}let i=r-1;return ev.create(i,e-t[i])}offsetAt(e){let t=this.getLineOffsets();if(e.line>=t.length)return this._content.length;if(e.line<0)return 0;let r=t[e.line],n=e.line+1<t.length?t[e.line+1]:this._content.length;return Math.max(Math.min(r+e.character,n),r)}get lineCount(){return this.getLineOffsets().length}};es=tE||(tE={}),n=Object.prototype.toString,es.defined=function(e){return void 0!==e},es.undefined=function(e){return void 0===e},es.boolean=function(e){return!0===e||!1===e},es.string=function(e){return"[object String]"===n.call(e)},es.number=function(e){return"[object Number]"===n.call(e)},es.numberRange=function(e,t,r){return"[object Number]"===n.call(e)&&t<=e&&e<=r},es.integer=function(e){return"[object Number]"===n.call(e)&&-0x80000000<=e&&e<=0x7fffffff},es.uinteger=function(e){return"[object Number]"===n.call(e)&&0<=e&&e<=0x7fffffff},es.func=function(e){return"[object Function]"===n.call(e)},es.objectLiteral=function(e){return null!==e&&"object"==typeof e},es.typedArray=function(e,t){return Array.isArray(e)&&e.every(t)};var rs=class e{constructor(e,t,r,n){this._uri=e,this._languageId=t,this._version=r,this._content=n,this._lineOffsets=void 0}get uri(){return this._uri}get languageId(){return this._languageId}get version(){return this._version}getText(e){if(e){let t=this.offsetAt(e.start),r=this.offsetAt(e.end);return this._content.substring(t,r)}return this._content}update(t,r){for(let r of t)if(e.isIncremental(r)){let e=rl(r.range),t=this.offsetAt(e.start),n=this.offsetAt(e.end);this._content=this._content.substring(0,t)+r.text+this._content.substring(n,this._content.length);let i=Math.max(e.start.line,0),s=Math.max(e.end.line,0),a=this._lineOffsets,o=ra(r.text,!1,t);if(s-i===o.length)for(let e=0,t=o.length;e<t;e++)a[e+i+1]=o[e];else o.length<1e4?a.splice(i+1,s-i,...o):this._lineOffsets=a=a.slice(0,i+1).concat(o,a.slice(s+1));let l=r.text.length-(n-t);if(0!==l)for(let e=i+1+o.length,t=a.length;e<t;e++)a[e]=a[e]+l}else if(e.isFull(r))this._content=r.text,this._lineOffsets=void 0;else throw Error("Unknown change event received");this._version=r}getLineOffsets(){return void 0===this._lineOffsets&&(this._lineOffsets=ra(this._content,!0)),this._lineOffsets}positionAt(e){e=Math.max(Math.min(e,this._content.length),0);let t=this.getLineOffsets(),r=0,n=t.length;if(0===n)return{line:0,character:e};for(;r<n;){let i=Math.floor((r+n)/2);t[i]>e?n=i:r=i+1}let i=r-1;return e=this.ensureBeforeEOL(e,t[i]),{line:i,character:e-t[i]}}offsetAt(e){let t=this.getLineOffsets();if(e.line>=t.length)return this._content.length;if(e.line<0)return 0;let r=t[e.line];if(e.character<=0)return r;let n=e.line+1<t.length?t[e.line+1]:this._content.length,i=Math.min(r+e.character,n);return this.ensureBeforeEOL(i,r)}ensureBeforeEOL(e,t){for(;e>t&&ro(this._content.charCodeAt(e-1));)e--;return e}get lineCount(){return this.getLineOffsets().length}static isIncremental(e){return null!=e&&"string"==typeof e.text&&void 0!==e.range&&(void 0===e.rangeLength||"number"==typeof e.rangeLength)}static isFull(e){return null!=e&&"string"==typeof e.text&&void 0===e.range&&void 0===e.rangeLength}};function ra(e,t,r=0){let n=t?[r]:[];for(let t=0;t<e.length;t++){let i=e.charCodeAt(t);ro(i)&&(13===i&&t+1<e.length&&10===e.charCodeAt(t+1)&&t++,n.push(r+t+1))}return n}function ro(e){return 13===e||10===e}function rl(e){let t=e.start,r=e.end;return t.line>r.line||t.line===r.line&&t.character>r.character?{start:r,end:t}:e}function rc(e){let t=rl(e.range);return t!==e.range?{newText:e.newText,range:t}:e}function ru(...e){var t;let r,n,i,s=e[0];if("string"==typeof s)r=s,n=s,e.splice(0,1),i=e&&"object"==typeof e[0]?e[0]:e;else if(s instanceof Array){let t=e.slice(1);if(s.length!==t.length+1)throw Error("expected a string as the first argument to l10n.t");let r=s[0];for(let e=1;e<s.length;e++)r+=`{${e-1}}`+s[e];return ru(r,...t)}else r=n=s.message,s.comment&&s.comment.length>0&&(r+=`/${Array.isArray(s.comment)?s.comment.join(""):s.comment}`),i=null!=(t=s.args)?t:{};let a=null==tL?void 0:tL[r];return a?"string"==typeof a?rh(a,i):a.comment?rh(a.message,i):rh(n,i):rh(n,i)}(ea=tP||(tP={})).create=function(e,t,r,n){return new rs(e,t,r,n)},ea.update=function(e,t,r){if(e instanceof rs)return e.update(t,r),e;throw Error("TextDocument.update: document must be created by TextDocument.create")},ea.applyEdits=function(e,t){let r=e.getText(),n=function e(t,r){if(t.length<=1)return t;let n=t.length/2|0,i=t.slice(0,n),s=t.slice(n);e(i,r),e(s,r);let a=0,o=0,l=0;for(;a<i.length&&o<s.length;)0>=r(i[a],s[o])?t[l++]=i[a++]:t[l++]=s[o++];for(;a<i.length;)t[l++]=i[a++];for(;o<s.length;)t[l++]=s[o++];return t}(t.map(rc),(e,t)=>{let r=e.range.start.line-t.range.start.line;return 0===r?e.range.start.character-t.range.start.character:r}),i=0,s=[];for(let t of n){let n=e.offsetAt(t.range.start);if(n<i)throw Error("Overlapping edit");n>i&&s.push(r.substring(i,n)),t.newText.length&&s.push(t.newText),i=e.offsetAt(t.range.end)}return s.push(r.substr(i)),s.join("")},(eo=tT||(tT={}))[eo.Undefined=0]="Undefined",eo[eo.EnumValueMismatch=1]="EnumValueMismatch",eo[eo.Deprecated=2]="Deprecated",eo[eo.UnexpectedEndOfComment=257]="UnexpectedEndOfComment",eo[eo.UnexpectedEndOfString=258]="UnexpectedEndOfString",eo[eo.UnexpectedEndOfNumber=259]="UnexpectedEndOfNumber",eo[eo.InvalidUnicode=260]="InvalidUnicode",eo[eo.InvalidEscapeCharacter=261]="InvalidEscapeCharacter",eo[eo.InvalidCharacter=262]="InvalidCharacter",eo[eo.PropertyExpected=513]="PropertyExpected",eo[eo.CommaExpected=514]="CommaExpected",eo[eo.ColonExpected=515]="ColonExpected",eo[eo.ValueExpected=516]="ValueExpected",eo[eo.CommaOrCloseBacketExpected=517]="CommaOrCloseBacketExpected",eo[eo.CommaOrCloseBraceExpected=518]="CommaOrCloseBraceExpected",eo[eo.TrailingComma=519]="TrailingComma",eo[eo.DuplicateKey=520]="DuplicateKey",eo[eo.CommentNotPermitted=521]="CommentNotPermitted",eo[eo.PropertyKeysMustBeDoublequoted=528]="PropertyKeysMustBeDoublequoted",eo[eo.SchemaUnsupportedFeature=769]="SchemaUnsupportedFeature",eo[eo.SchemaResolveError=65536]="SchemaResolveError",(el=tM||(tM={}))[el.v3=3]="v3",el[el.v4=4]="v4",el[el.v6=6]="v6",el[el.v7=7]="v7",el[el.v2019_09=19]="v2019_09",el[el.v2020_12=20]="v2020_12",(t_||(t_={})).LATEST={textDocument:{completion:{completionItem:{documentationFormat:[eW.Markdown,eW.PlainText],commitCharactersSupport:!0,labelDetailsSupport:!0}}}};var rf=/{([^}]+)}/g;function rh(e,t){return 0===Object.keys(t).length?e:e.replace(rf,(e,r)=>{var n;return null!=(n=t[r])?n:e})}function rd(e,t){let r,n;if(e===t)return!0;if(null==e||null==t||typeof e!=typeof t||"object"!=typeof e||Array.isArray(e)!==Array.isArray(t))return!1;if(Array.isArray(e)){if(e.length!==t.length)return!1;for(r=0;r<e.length;r++)if(!rd(e[r],t[r]))return!1}else{let i=[];for(n in e)i.push(n);i.sort();let s=[];for(n in t)s.push(n);if(s.sort(),!rd(i,s))return!1;for(r=0;r<i.length;r++)if(!rd(e[i[r]],t[i[r]]))return!1}return!0}function rm(e){return"number"==typeof e}function rp(e){return"boolean"==typeof e}function rg(e){return"string"==typeof e}function ry(e){return"object"==typeof e&&null!==e&&!Array.isArray(e)}var rv=class{constructor(e,t){this.jsonSchemaService=e,this.promise=t,this.validationEnabled=!0}configure(e){e&&(this.validationEnabled=!1!==e.validate,this.commentSeverity=e.allowComments?void 0:eI.Error)}doValidation(e,t,r,n){if(!this.validationEnabled)return this.promise.resolve([]);let i=[],s={},a=e=>{let t=e.range.start.line+" "+e.range.start.character+" "+e.message;s[t]||(s[t]=!0,i.push(e))},o=n=>{let s=(null==r?void 0:r.trailingCommas)?rw(r.trailingCommas):eI.Error,o=(null==r?void 0:r.comments)?rw(r.comments):this.commentSeverity,l=(null==r?void 0:r.schemaValidation)?rw(r.schemaValidation):eI.Warning,c=(null==r?void 0:r.schemaRequest)?rw(r.schemaRequest):eI.Warning;if(n){let i=(r,n,i)=>{if(t.root&&c){let s=t.root,o="object"===s.type?s.properties[0]:void 0;if(o&&"$schema"===o.keyNode.value){let t=o.valueNode||o,s=eb.create(e.positionAt(t.offset),e.positionAt(t.offset+t.length));a(eT.create(s,r,c,n,"json",i))}else{let t=eb.create(e.positionAt(s.offset),e.positionAt(s.offset+1));a(eT.create(t,r,c,n,"json",i))}}};if(n.errors.length){let e=n.errors[0];i(e.message,e.code,e.relatedInformation)}else if(l){for(let e of n.warnings)i(e.message,e.code,e.relatedInformation);let s=t.validate(e,n.schema,l,null==r?void 0:r.schemaDraft);s&&s.forEach(a)}(function e(t){if(t&&"object"==typeof t){if(rp(t.allowComments))return t.allowComments;if(t.allOf)for(let r of t.allOf){let t=e(r);if(rp(t))return t}}})(n.schema)&&(o=void 0),function e(t){if(t&&"object"==typeof t){if(rp(t.allowTrailingCommas))return t.allowTrailingCommas;if(rp(t.allowsTrailingCommas))return t.allowsTrailingCommas;if(t.allOf)for(let r of t.allOf){let t=e(r);if(rp(t))return t}}}(n.schema)&&(s=void 0)}for(let e of t.syntaxErrors){if(e.code===tT.TrailingComma){if("number"!=typeof s)continue;e.severity=s}a(e)}if("number"==typeof o){let e=ru("Comments are not permitted in JSON.");t.comments.forEach(t=>{a(eT.create(t,e,o,tT.CommentNotPermitted))})}return i};if(n){let e=n.id||"schemaservice://untitled/"+rb++;return this.jsonSchemaService.registerExternalSchema({uri:e,schema:n}).getResolvedSchema().then(e=>o(e))}return this.jsonSchemaService.getSchemaForResource(e.uri,t).then(e=>o(e))}getLanguageStatus(e,t){return{schemas:this.jsonSchemaService.getSchemaURIsForResource(e.uri,t)}}},rb=0;function rw(e){switch(e){case"error":return eI.Error;case"warning":return eI.Warning}}function rx(e,t=!1){let r=e.length,n=0,i="",s=0,a=16,o=0,l=0,c=0,u=0,f=0;function h(){if(i="",f=0,s=n,l=o,u=c,n>=r)return s=r,a=17;let t=e.charCodeAt(n);if(rA(t)){do n++,i+=String.fromCharCode(t),t=e.charCodeAt(n);while(rA(t));return a=15}if(r$(t))return n++,i+=String.fromCharCode(t),13===t&&10===e.charCodeAt(n)&&(n++,i+="\n"),o++,c=n,a=14;switch(t){case 123:return n++,a=1;case 125:return n++,a=2;case 91:return n++,a=3;case 93:return n++,a=4;case 58:return n++,a=6;case 44:return n++,a=5;case 34:return n++,i=function(){let t="",i=n;for(;;){if(n>=r){t+=e.substring(i,n),f=2;break}let s=e.charCodeAt(n);if(34===s){t+=e.substring(i,n),n++;break}if(92===s){if(t+=e.substring(i,n),++n>=r){f=2;break}switch(e.charCodeAt(n++)){case 34:t+='"';break;case 92:t+="\\";break;case 47:t+="/";break;case 98:t+="\b";break;case 102:t+="\f";break;case 110:t+="\n";break;case 114:t+="\r";break;case 116:t+=" ";break;case 117:let s=function(t){let r=0,i=0;for(;r<4||!t;){let t=e.charCodeAt(n);if(t>=48&&t<=57)i=16*i+t-48;else if(t>=65&&t<=70)i=16*i+t-65+10;else if(t>=97&&t<=102)i=16*i+t-97+10;else break;n++,r++}return r<4&&(i=-1),i}(!0);s>=0?t+=String.fromCharCode(s):f=4;break;default:f=5}i=n;continue}if(s>=0&&s<=31)if(r$(s)){t+=e.substring(i,n),f=2;break}else f=6;n++}return t}(),a=10;case 47:let h=n-1;if(47===e.charCodeAt(n+1)){for(n+=2;n<r&&!r$(e.charCodeAt(n));)n++;return i=e.substring(h,n),a=12}if(42===e.charCodeAt(n+1)){n+=2;let t=r-1,s=!1;for(;n<t;){let t=e.charCodeAt(n);if(42===t&&47===e.charCodeAt(n+1)){n+=2,s=!0;break}n++,r$(t)&&(13===t&&10===e.charCodeAt(n)&&n++,o++,c=n)}return s||(n++,f=1),i=e.substring(h,n),a=13}return i+=String.fromCharCode(t),n++,a=16;case 45:if(i+=String.fromCharCode(t),++n===r||!rk(e.charCodeAt(n)))return a=16;case 48:case 49:case 50:case 51:case 52:case 53:case 54:case 55:case 56:case 57:return i+=function(){let t=n;if(48===e.charCodeAt(n))n++;else for(n++;n<e.length&&rk(e.charCodeAt(n));)n++;if(n<e.length&&46===e.charCodeAt(n)){if(!(++n<e.length&&rk(e.charCodeAt(n))))return f=3,e.substring(t,n);for(n++;n<e.length&&rk(e.charCodeAt(n));)n++}let r=n;if(n<e.length&&(69===e.charCodeAt(n)||101===e.charCodeAt(n)))if((++n<e.length&&43===e.charCodeAt(n)||45===e.charCodeAt(n))&&n++,n<e.length&&rk(e.charCodeAt(n))){for(n++;n<e.length&&rk(e.charCodeAt(n));)n++;r=n}else f=3;return e.substring(t,r)}(),a=11;default:for(;n<r&&function(e){if(rA(e)||r$(e))return!1;switch(e){case 125:case 93:case 123:case 91:case 34:case 58:case 44:case 47:return!1}return!0}(t);)n++,t=e.charCodeAt(n);if(s!==n){switch(i=e.substring(s,n)){case"true":return a=8;case"false":return a=9;case"null":return a=7}return a=16}return i+=String.fromCharCode(t),n++,a=16}}return{setPosition:function(e){n=e,i="",s=0,a=16,f=0},getPosition:()=>n,scan:t?function(){let e;do e=h();while(e>=12&&e<=15);return e}:h,getToken:()=>a,getTokenValue:()=>i,getTokenOffset:()=>s,getTokenLength:()=>n-s,getTokenStartLine:()=>l,getTokenStartCharacter:()=>s-u,getTokenError:()=>f}}function rA(e){return 32===e||9===e}function r$(e){return 10===e||13===e}function rk(e){return e>=48&&e<=57}(ec=tj||(tj={}))[ec.lineFeed=10]="lineFeed",ec[ec.carriageReturn=13]="carriageReturn",ec[ec.space=32]="space",ec[ec._0=48]="_0",ec[ec._1=49]="_1",ec[ec._2=50]="_2",ec[ec._3=51]="_3",ec[ec._4=52]="_4",ec[ec._5=53]="_5",ec[ec._6=54]="_6",ec[ec._7=55]="_7",ec[ec._8=56]="_8",ec[ec._9=57]="_9",ec[ec.a=97]="a",ec[ec.b=98]="b",ec[ec.c=99]="c",ec[ec.d=100]="d",ec[ec.e=101]="e",ec[ec.f=102]="f",ec[ec.g=103]="g",ec[ec.h=104]="h",ec[ec.i=105]="i",ec[ec.j=106]="j",ec[ec.k=107]="k",ec[ec.l=108]="l",ec[ec.m=109]="m",ec[ec.n=110]="n",ec[ec.o=111]="o",ec[ec.p=112]="p",ec[ec.q=113]="q",ec[ec.r=114]="r",ec[ec.s=115]="s",ec[ec.t=116]="t",ec[ec.u=117]="u",ec[ec.v=118]="v",ec[ec.w=119]="w",ec[ec.x=120]="x",ec[ec.y=121]="y",ec[ec.z=122]="z",ec[ec.A=65]="A",ec[ec.B=66]="B",ec[ec.C=67]="C",ec[ec.D=68]="D",ec[ec.E=69]="E",ec[ec.F=70]="F",ec[ec.G=71]="G",ec[ec.H=72]="H",ec[ec.I=73]="I",ec[ec.J=74]="J",ec[ec.K=75]="K",ec[ec.L=76]="L",ec[ec.M=77]="M",ec[ec.N=78]="N",ec[ec.O=79]="O",ec[ec.P=80]="P",ec[ec.Q=81]="Q",ec[ec.R=82]="R",ec[ec.S=83]="S",ec[ec.T=84]="T",ec[ec.U=85]="U",ec[ec.V=86]="V",ec[ec.W=87]="W",ec[ec.X=88]="X",ec[ec.Y=89]="Y",ec[ec.Z=90]="Z",ec[ec.asterisk=42]="asterisk",ec[ec.backslash=92]="backslash",ec[ec.closeBrace=125]="closeBrace",ec[ec.closeBracket=93]="closeBracket",ec[ec.colon=58]="colon",ec[ec.comma=44]="comma",ec[ec.dot=46]="dot",ec[ec.doubleQuote=34]="doubleQuote",ec[ec.minus=45]="minus",ec[ec.openBrace=123]="openBrace",ec[ec.openBracket=91]="openBracket",ec[ec.plus=43]="plus",ec[ec.slash=47]="slash",ec[ec.formFeed=12]="formFeed",ec[ec.tab=9]="tab",Array(20).fill(0).map((e,t)=>" ".repeat(t)),Array(200).fill(0).map((e,t)=>"\n"+" ".repeat(t)),Array(200).fill(0).map((e,t)=>"\r"+" ".repeat(t)),Array(200).fill(0).map((e,t)=>"\r\n"+" ".repeat(t)),Array(200).fill(0).map((e,t)=>"\n"+" ".repeat(t)),Array(200).fill(0).map((e,t)=>"\r"+" ".repeat(t)),Array(200).fill(0).map((e,t)=>"\r\n"+" ".repeat(t)),(tR||(tR={})).DEFAULT={allowTrailingComma:!1},(eu=tN||(tN={}))[eu.None=0]="None",eu[eu.UnexpectedEndOfComment=1]="UnexpectedEndOfComment",eu[eu.UnexpectedEndOfString=2]="UnexpectedEndOfString",eu[eu.UnexpectedEndOfNumber=3]="UnexpectedEndOfNumber",eu[eu.InvalidUnicode=4]="InvalidUnicode",eu[eu.InvalidEscapeCharacter=5]="InvalidEscapeCharacter",eu[eu.InvalidCharacter=6]="InvalidCharacter",(ef=tU||(tU={}))[ef.OpenBraceToken=1]="OpenBraceToken",ef[ef.CloseBraceToken=2]="CloseBraceToken",ef[ef.OpenBracketToken=3]="OpenBracketToken",ef[ef.CloseBracketToken=4]="CloseBracketToken",ef[ef.CommaToken=5]="CommaToken",ef[ef.ColonToken=6]="ColonToken",ef[ef.NullKeyword=7]="NullKeyword",ef[ef.TrueKeyword=8]="TrueKeyword",ef[ef.FalseKeyword=9]="FalseKeyword",ef[ef.StringLiteral=10]="StringLiteral",ef[ef.NumericLiteral=11]="NumericLiteral",ef[ef.LineCommentTrivia=12]="LineCommentTrivia",ef[ef.BlockCommentTrivia=13]="BlockCommentTrivia",ef[ef.LineBreakTrivia=14]="LineBreakTrivia",ef[ef.Trivia=15]="Trivia",ef[ef.Unknown=16]="Unknown",ef[ef.EOF=17]="EOF";var rS=function(e,t=[],r=tR.DEFAULT){let n=null,i=[],s=[];function a(e){Array.isArray(i)?i.push(e):null!==n&&(i[n]=e)}return function(e,t,r=tR.DEFAULT){var n;let i=rx(e,!1),s=[],a=0;function o(e){return e?t=>0===a&&e(t,i.getTokenOffset(),i.getTokenLength(),i.getTokenStartLine(),i.getTokenStartCharacter()):()=>!0}function l(e){return e?t=>0===a&&e(t,i.getTokenOffset(),i.getTokenLength(),i.getTokenStartLine(),i.getTokenStartCharacter(),()=>s.slice()):()=>!0}function c(e){return e?()=>{a>0?a++:!1===e(i.getTokenOffset(),i.getTokenLength(),i.getTokenStartLine(),i.getTokenStartCharacter(),()=>s.slice())&&(a=1)}:()=>!0}function u(e){return e?()=>{a>0&&a--,0===a&&e(i.getTokenOffset(),i.getTokenLength(),i.getTokenStartLine(),i.getTokenStartCharacter())}:()=>!0}let f=c(t.onObjectBegin),h=l(t.onObjectProperty),d=u(t.onObjectEnd),m=c(t.onArrayBegin),p=u(t.onArrayEnd),g=l(t.onLiteralValue),y=o(t.onSeparator),v=(n=t.onComment)?()=>0===a&&n(i.getTokenOffset(),i.getTokenLength(),i.getTokenStartLine(),i.getTokenStartCharacter()):()=>!0,b=o(t.onError),w=r&&r.disallowComments,x=r&&r.allowTrailingComma;function A(){for(;;){let e=i.scan();switch(i.getTokenError()){case 4:$(14);break;case 5:$(15);break;case 3:$(13);break;case 1:w||$(11);break;case 2:$(12);break;case 6:$(16)}switch(e){case 12:case 13:w?$(10):v();break;case 16:$(1);break;case 15:case 14:break;default:return e}}}function $(e,t=[],r=[]){if(b(e),t.length+r.length>0){let e=i.getToken();for(;17!==e;){if(-1!==t.indexOf(e)){A();break}if(-1!==r.indexOf(e))break;e=A()}}}function k(e){let t=i.getTokenValue();return e?g(t):(h(t),s.push(t)),A(),!0}if(A(),17===i.getToken())return r.allowEmptyContent||$(4,[],[]);!function e(){switch(i.getToken()){case 3:m(),A();let t=!0,r=!1;for(;4!==i.getToken()&&17!==i.getToken();){if(5===i.getToken()){if(r||$(4,[],[]),y(","),A(),4===i.getToken()&&x)break}else r&&$(6,[],[]);t?(s.push(0),t=!1):s[s.length-1]++,e()||$(4,[],[4,5]),r=!0}return p(),t||s.pop(),4!==i.getToken()?$(8,[4],[]):A(),!0;case 1:f(),A();let n=!1;for(;2!==i.getToken()&&17!==i.getToken();){if(5===i.getToken()){if(n||$(4,[],[]),y(","),A(),2===i.getToken()&&x)break}else n&&$(6,[],[]);(10!==i.getToken()?($(3,[],[2,5]),1):(k(!1),6===i.getToken()?(y(":"),A(),e()||$(4,[],[2,5])):$(5,[],[2,5]),s.pop(),0))&&$(4,[],[2,5]),n=!0}return d(),2!==i.getToken()?$(7,[2],[]):A(),!0;case 10:return k(!0);default:switch(i.getToken()){case 11:let a=Number(i.getTokenValue());isNaN(a)&&($(2),a=0),g(a);break;case 7:g(null);break;case 8:g(!0);break;case 9:g(!1);break;default:return!1}return A(),!0}}()?$(4,[],[]):17!==i.getToken()&&$(9,[],[])}(e,{onObjectBegin:()=>{let e={};a(e),s.push(i),i=e,n=null},onObjectProperty:e=>{n=e},onObjectEnd:()=>{i=s.pop()},onArrayBegin:()=>{let e=[];a(e),s.push(i),i=e,n=null},onArrayEnd:()=>{i=s.pop()},onLiteralValue:a,onError:(e,r,n)=>{t.push({error:e,offset:r,length:n})}},r),i[0]},rO=function e(t,r,n=!1){if(function(e,t,r=!1){return t>=e.offset&&t<e.offset+e.length||r&&t===e.offset+e.length}(t,r,n)){let i=t.children;if(Array.isArray(i))for(let t=0;t<i.length&&i[t].offset<=r;t++){let s=e(i[t],r,n);if(s)return s}return t}},rC=function e(t){switch(t.type){case"array":return t.children.map(e);case"object":let r=Object.create(null);for(let n of t.children){let t=n.children[1];t&&(r[n.children[0].value]=e(t))}return r;case"null":case"string":case"number":case"boolean":return t.value;default:return}};function rI(e){let t="";(function(e,t){if(e.length<t.length)return!1;for(let r=0;r<t.length;r++)if(e[r]!==t[r])return!1;return!0})(e,"(?i)")&&(e=e.substring(4),t="i");try{return RegExp(e,t+"u")}catch(r){try{return new RegExp(e,t)}catch(e){return}}}function rE(e){let t=0;for(let r=0;r<e.length;r++){t++;let n=e.charCodeAt(r);55296<=n&&n<=56319&&r++}return t}(eh=tV||(tV={}))[eh.InvalidSymbol=1]="InvalidSymbol",eh[eh.InvalidNumberFormat=2]="InvalidNumberFormat",eh[eh.PropertyNameExpected=3]="PropertyNameExpected",eh[eh.ValueExpected=4]="ValueExpected",eh[eh.ColonExpected=5]="ColonExpected",eh[eh.CommaExpected=6]="CommaExpected",eh[eh.CloseBraceExpected=7]="CloseBraceExpected",eh[eh.CloseBracketExpected=8]="CloseBracketExpected",eh[eh.EndOfFileExpected=9]="EndOfFileExpected",eh[eh.InvalidCommentToken=10]="InvalidCommentToken",eh[eh.UnexpectedEndOfComment=11]="UnexpectedEndOfComment",eh[eh.UnexpectedEndOfString=12]="UnexpectedEndOfString",eh[eh.UnexpectedEndOfNumber=13]="UnexpectedEndOfNumber",eh[eh.InvalidUnicode=14]="InvalidUnicode",eh[eh.InvalidEscapeCharacter=15]="InvalidEscapeCharacter",eh[eh.InvalidCharacter=16]="InvalidCharacter",(()=>{let e;var t,r,n={975:e=>{function t(e){if("string"!=typeof e)throw TypeError("Path must be a string. Received "+JSON.stringify(e))}function r(e,t){for(var r,n="",i=0,s=-1,a=0,o=0;o<=e.length;++o){if(o<e.length)r=e.charCodeAt(o);else{if(47===r)break;r=47}if(47===r){if(s===o-1||1===a);else if(s!==o-1&&2===a){if(n.length<2||2!==i||46!==n.charCodeAt(n.length-1)||46!==n.charCodeAt(n.length-2)){if(n.length>2){var l=n.lastIndexOf("/");if(l!==n.length-1){-1===l?(n="",i=0):i=(n=n.slice(0,l)).length-1-n.lastIndexOf("/"),s=o,a=0;continue}}else if(2===n.length||1===n.length){n="",i=0,s=o,a=0;continue}}t&&(n.length>0?n+="/..":n="..",i=2)}else n.length>0?n+="/"+e.slice(s+1,o):n=e.slice(s+1,o),i=o-s-1;s=o,a=0}else 46===r&&-1!==a?++a:a=-1}return n}var n={resolve:function(){for(var e,n,i="",s=!1,a=arguments.length-1;a>=-1&&!s;a--)a>=0?e=arguments[a]:(void 0===n&&(n=process.cwd()),e=n),t(e),0!==e.length&&(i=e+"/"+i,s=47===e.charCodeAt(0));return i=r(i,!s),s?i.length>0?"/"+i:"/":i.length>0?i:"."},normalize:function(e){if(t(e),0===e.length)return".";var n=47===e.charCodeAt(0),i=47===e.charCodeAt(e.length-1);return 0!==(e=r(e,!n)).length||n||(e="."),e.length>0&&i&&(e+="/"),n?"/"+e:e},isAbsolute:function(e){return t(e),e.length>0&&47===e.charCodeAt(0)},join:function(){if(0==arguments.length)return".";for(var e,r=0;r<arguments.length;++r){var i=arguments[r];t(i),i.length>0&&(void 0===e?e=i:e+="/"+i)}return void 0===e?".":n.normalize(e)},relative:function(e,r){if(t(e),t(r),e===r||(e=n.resolve(e))===(r=n.resolve(r)))return"";for(var i=1;i<e.length&&47===e.charCodeAt(i);++i);for(var s=e.length,a=s-i,o=1;o<r.length&&47===r.charCodeAt(o);++o);for(var l=r.length-o,c=a<l?a:l,u=-1,f=0;f<=c;++f){if(f===c){if(l>c){if(47===r.charCodeAt(o+f))return r.slice(o+f+1);if(0===f)return r.slice(o+f)}else a>c&&(47===e.charCodeAt(i+f)?u=f:0===f&&(u=0));break}var h=e.charCodeAt(i+f);if(h!==r.charCodeAt(o+f))break;47===h&&(u=f)}var d="";for(f=i+u+1;f<=s;++f)f!==s&&47!==e.charCodeAt(f)||(0===d.length?d+="..":d+="/..");return d.length>0?d+r.slice(o+u):(o+=u,47===r.charCodeAt(o)&&++o,r.slice(o))},_makeLong:function(e){return e},dirname:function(e){if(t(e),0===e.length)return".";for(var r=e.charCodeAt(0),n=47===r,i=-1,s=!0,a=e.length-1;a>=1;--a)if(47===(r=e.charCodeAt(a))){if(!s){i=a;break}}else s=!1;return -1===i?n?"/":".":n&&1===i?"//":e.slice(0,i)},basename:function(e,r){if(void 0!==r&&"string"!=typeof r)throw TypeError('"ext" argument must be a string');t(e);var n,i=0,s=-1,a=!0;if(void 0!==r&&r.length>0&&r.length<=e.length){if(r.length===e.length&&r===e)return"";var o=r.length-1,l=-1;for(n=e.length-1;n>=0;--n){var c=e.charCodeAt(n);if(47===c){if(!a){i=n+1;break}}else -1===l&&(a=!1,l=n+1),o>=0&&(c===r.charCodeAt(o)?-1==--o&&(s=n):(o=-1,s=l))}return i===s?s=l:-1===s&&(s=e.length),e.slice(i,s)}for(n=e.length-1;n>=0;--n)if(47===e.charCodeAt(n)){if(!a){i=n+1;break}}else -1===s&&(a=!1,s=n+1);return -1===s?"":e.slice(i,s)},extname:function(e){t(e);for(var r=-1,n=0,i=-1,s=!0,a=0,o=e.length-1;o>=0;--o){var l=e.charCodeAt(o);if(47!==l)-1===i&&(s=!1,i=o+1),46===l?-1===r?r=o:1!==a&&(a=1):-1!==r&&(a=-1);else if(!s){n=o+1;break}}return -1===r||-1===i||0===a||1===a&&r===i-1&&r===n+1?"":e.slice(r,i)},format:function(e){var t,r;if(null===e||"object"!=typeof e)throw TypeError('The "pathObject" argument must be of type Object. Received type '+typeof e);return t=e.dir||e.root,r=e.base||(e.name||"")+(e.ext||""),t?t===e.root?t+r:t+"/"+r:r},parse:function(e){t(e);var r={root:"",dir:"",base:"",ext:"",name:""};if(0===e.length)return r;var n,i=e.charCodeAt(0),s=47===i;s?(r.root="/",n=1):n=0;for(var a=-1,o=0,l=-1,c=!0,u=e.length-1,f=0;u>=n;--u)if(47!==(i=e.charCodeAt(u)))-1===l&&(c=!1,l=u+1),46===i?-1===a?a=u:1!==f&&(f=1):-1!==a&&(f=-1);else if(!c){o=u+1;break}return -1===a||-1===l||0===f||1===f&&a===l-1&&a===o+1?-1!==l&&(r.base=r.name=0===o&&s?e.slice(1,l):e.slice(o,l)):(0===o&&s?(r.name=e.slice(1,a),r.base=e.slice(1,l)):(r.name=e.slice(o,a),r.base=e.slice(o,l)),r.ext=e.slice(a,l)),o>0?r.dir=e.slice(0,o-1):s&&(r.dir="/"),r},sep:"/",delimiter:":",win32:null,posix:null};n.posix=n,e.exports=n}},i={};function s(e){var t=i[e];if(void 0!==t)return t.exports;var r=i[e]={exports:{}};return n[e](r,r.exports,s),r.exports}s.d=(e,t)=>{for(var r in t)s.o(t,r)&&!s.o(e,r)&&Object.defineProperty(e,r,{enumerable:!0,get:t[r]})},s.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),s.r=e=>{"u">typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})};var a={};(s.r(a),s.d(a,{URI:()=>h,Utils:()=>r}),"object"==typeof process)?e="win32"===process.platform:"object"==typeof navigator&&(e=navigator.userAgent.indexOf("Windows")>=0);let o=/^\w[\w\d+.-]*$/,l=/^\//,c=/^\/\//;function u(e,t){if(!e.scheme&&t)throw Error(`[UriError]: Scheme is missing: {scheme: "", authority: "${e.authority}", path: "${e.path}", query: "${e.query}", fragment: "${e.fragment}"}`);if(e.scheme&&!o.test(e.scheme))throw Error("[UriError]: Scheme contains illegal characters.");if(e.path){if(e.authority){if(!l.test(e.path))throw 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(c.test(e.path))throw Error('[UriError]: If a URI does not contain an authority component, then the path cannot begin with two slash characters ("//")')}}let f=/^(([^:/?#]+?):)?(\/\/([^/?#]*))?([^?#]*)(\?([^#]*))?(#(.*))?/;class h{constructor(e,t,r,n,i,s=!1){tG(this,"scheme"),tG(this,"authority"),tG(this,"path"),tG(this,"query"),tG(this,"fragment"),"object"==typeof e?(this.scheme=e.scheme||"",this.authority=e.authority||"",this.path=e.path||"",this.query=e.query||"",this.fragment=e.fragment||""):(this.scheme=function(e,t){return e||t?e:"file"}(e,s),this.authority=t||"",this.path=function(e,t){switch(e){case"https":case"http":case"file":t?"/"!==t[0]&&(t="/"+t):t="/"}return t}(this.scheme,r||""),this.query=n||"",this.fragment=i||"",u(this,s))}static isUri(e){return e instanceof h||!!e&&"string"==typeof e.authority&&"string"==typeof e.fragment&&"string"==typeof e.path&&"string"==typeof e.query&&"string"==typeof e.scheme&&"string"==typeof e.fsPath&&"function"==typeof e.with&&"function"==typeof e.toString}get fsPath(){return v(this,!1)}with(e){if(!e)return this;let{scheme:t,authority:r,path:n,query:i,fragment:s}=e;return void 0===t?t=this.scheme:null===t&&(t=""),void 0===r?r=this.authority:null===r&&(r=""),void 0===n?n=this.path:null===n&&(n=""),void 0===i?i=this.query:null===i&&(i=""),void 0===s?s=this.fragment:null===s&&(s=""),t===this.scheme&&r===this.authority&&n===this.path&&i===this.query&&s===this.fragment?this:new m(t,r,n,i,s)}static parse(e,t=!1){let r=f.exec(e);return r?new m(r[2]||"",x(r[4]||""),x(r[5]||""),x(r[7]||""),x(r[9]||""),t):new m("","","","","")}static file(t){let r="";if(e&&(t=t.replace(/\\/g,"/")),"/"===t[0]&&"/"===t[1]){let e=t.indexOf("/",2);-1===e?(r=t.substring(2),t="/"):(r=t.substring(2,e),t=t.substring(e)||"/")}return new m("file",r,t,"","")}static from(e){let t=new m(e.scheme,e.authority,e.path,e.query,e.fragment);return u(t,!0),t}toString(e=!1){return b(this,e)}toJSON(){return this}static revive(e){if(e){if(e instanceof h)return e;{let t=new m(e);return t._formatted=e.external,t._fsPath=e._sep===d?e.fsPath:null,t}}return e}}let d=e?1:void 0;class m extends h{constructor(){super(...arguments),tG(this,"_formatted",null),tG(this,"_fsPath",null)}get fsPath(){return this._fsPath||(this._fsPath=v(this,!1)),this._fsPath}toString(e=!1){return e?b(this,!0):(this._formatted||(this._formatted=b(this,!1)),this._formatted)}toJSON(){let e={$mid:1};return this._fsPath&&(e.fsPath=this._fsPath,e._sep=d),this._formatted&&(e.external=this._formatted),this.path&&(e.path=this.path),this.scheme&&(e.scheme=this.scheme),this.authority&&(e.authority=this.authority),this.query&&(e.query=this.query),this.fragment&&(e.fragment=this.fragment),e}}let p={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 g(e,t,r){let n,i=-1;for(let s=0;s<e.length;s++){let a=e.charCodeAt(s);if(a>=97&&a<=122||a>=65&&a<=90||a>=48&&a<=57||45===a||46===a||95===a||126===a||t&&47===a||r&&91===a||r&&93===a||r&&58===a)-1!==i&&(n+=encodeURIComponent(e.substring(i,s)),i=-1),void 0!==n&&(n+=e.charAt(s));else{void 0===n&&(n=e.substr(0,s));let t=p[a];void 0!==t?(-1!==i&&(n+=encodeURIComponent(e.substring(i,s)),i=-1),n+=t):-1===i&&(i=s)}}return -1!==i&&(n+=encodeURIComponent(e.substring(i))),void 0!==n?n:e}function y(e){let t;for(let r=0;r<e.length;r++){let n=e.charCodeAt(r);35===n||63===n?(void 0===t&&(t=e.substr(0,r)),t+=p[n]):void 0!==t&&(t+=e[r])}return void 0!==t?t:e}function v(t,r){let n;return n=t.authority&&t.path.length>1&&"file"===t.scheme?`//${t.authority}${t.path}`:47===t.path.charCodeAt(0)&&(t.path.charCodeAt(1)>=65&&90>=t.path.charCodeAt(1)||t.path.charCodeAt(1)>=97&&122>=t.path.charCodeAt(1))&&58===t.path.charCodeAt(2)?r?t.path.substr(1):t.path[1].toLowerCase()+t.path.substr(2):t.path,e&&(n=n.replace(/\//g,"\\")),n}function b(e,t){let r=t?y:g,n="",{scheme:i,authority:s,path:a,query:o,fragment:l}=e;if(i&&(n+=i,n+=":"),(s||"file"===i)&&(n+="/",n+="/"),s){let e=s.indexOf("@");if(-1!==e){let t=s.substr(0,e);s=s.substr(e+1),-1===(e=t.lastIndexOf(":"))?n+=r(t,!1,!1):(n+=r(t.substr(0,e),!1,!1),n+=":",n+=r(t.substr(e+1),!1,!0)),n+="@"}-1===(e=(s=s.toLowerCase()).lastIndexOf(":"))?n+=r(s,!1,!0):(n+=r(s.substr(0,e),!1,!0),n+=s.substr(e))}if(a){if(a.length>=3&&47===a.charCodeAt(0)&&58===a.charCodeAt(2)){let e=a.charCodeAt(1);e>=65&&e<=90&&(a=`/${String.fromCharCode(e+32)}:${a.substr(3)}`)}else if(a.length>=2&&58===a.charCodeAt(1)){let e=a.charCodeAt(0);e>=65&&e<=90&&(a=`${String.fromCharCode(e+32)}:${a.substr(2)}`)}n+=r(a,!0,!1)}return o&&(n+="?",n+=r(o,!1,!1)),l&&(n+="#",n+=t?l:g(l,!1,!1)),n}let w=/(%[0-9A-Za-z][0-9A-Za-z])+/g;function x(e){return e.match(w)?e.replace(w,e=>(function e(t){try{return decodeURIComponent(t)}catch(r){return t.length>3?t.substr(0,3)+e(t.substr(3)):t}})(e)):e}var A=s(975);let $=A.posix||A;(t=r||(r={})).joinPath=function(e,...t){return e.with({path:$.join(e.path,...t)})},t.resolvePath=function(e,...t){let r=e.path,n=!1;"/"!==r[0]&&(r="/"+r,n=!0);let i=$.resolve(r,...t);return n&&"/"===i[0]&&!e.authority&&(i=i.substring(1)),e.with({path:i})},t.dirname=function(e){if(0===e.path.length||"/"===e.path)return e;let t=$.dirname(e.path);return 1===t.length&&46===t.charCodeAt(0)&&(t=""),e.with({path:t})},t.basename=function(e){return $.basename(e.path)},t.extname=function(e){return $.extname(e.path)},tD=a})();var{URI:rP,Utils:rT}=tD,rM={"color-hex":{errorMessage:ru("Invalid color format. Use #RGB, #RGBA, #RRGGBB or #RRGGBBAA."),pattern:/^#([0-9A-Fa-f]{3,4}|([0-9A-Fa-f]{2}){3,4})$/},"date-time":{errorMessage:ru("String is not a RFC3339 date-time."),pattern:/^(\d{4})-(0[1-9]|1[0-2])-(0[1-9]|[12][0-9]|3[01])T([01][0-9]|2[0-3]):([0-5][0-9]):([0-5][0-9]|60)(\.[0-9]+)?(Z|(\+|-)([01][0-9]|2[0-3]):([0-5][0-9]))$/i},date:{errorMessage:ru("String is not a RFC3339 date."),pattern:/^(\d{4})-(0[1-9]|1[0-2])-(0[1-9]|[12][0-9]|3[01])$/i},time:{errorMessage:ru("String is not a RFC3339 time."),pattern:/^([01][0-9]|2[0-3]):([0-5][0-9]):([0-5][0-9]|60)(\.[0-9]+)?(Z|(\+|-)([01][0-9]|2[0-3]):([0-5][0-9]))$/i},email:{errorMessage:ru("String is not an e-mail address."),pattern:/^(([^<>()\[\]\\.,;:\s@"]+(\.[^<>()\[\]\\.,;:\s@"]+)*)|(".+"))@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}])|(([a-zA-Z0-9-]+\.)+[a-zA-Z]{2,}))$/},hostname:{errorMessage:ru("String is not a hostname."),pattern:/^(?=.{1,253}\.?$)[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?(?:\.[a-z0-9](?:[-0-9a-z]{0,61}[0-9a-z])?)*\.?$/i},ipv4:{errorMessage:ru("String is not an IPv4 address."),pattern:/^(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)\.){3}(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)$/},ipv6:{errorMessage:ru("String is not an IPv6 address."),pattern:/^((([0-9a-f]{1,4}:){7}([0-9a-f]{1,4}|:))|(([0-9a-f]{1,4}:){6}(:[0-9a-f]{1,4}|((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3})|:))|(([0-9a-f]{1,4}:){5}(((:[0-9a-f]{1,4}){1,2})|:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3})|:))|(([0-9a-f]{1,4}:){4}(((:[0-9a-f]{1,4}){1,3})|((:[0-9a-f]{1,4})?:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(([0-9a-f]{1,4}:){3}(((:[0-9a-f]{1,4}){1,4})|((:[0-9a-f]{1,4}){0,2}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(([0-9a-f]{1,4}:){2}(((:[0-9a-f]{1,4}){1,5})|((:[0-9a-f]{1,4}){0,3}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(([0-9a-f]{1,4}:){1}(((:[0-9a-f]{1,4}){1,6})|((:[0-9a-f]{1,4}){0,4}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(:(((:[0-9a-f]{1,4}){1,7})|((:[0-9a-f]{1,4}){0,5}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:)))$/i}},r_=class{constructor(e,t,r=0){this.offset=t,this.length=r,this.parent=e}get children(){return[]}toString(){return"type: "+this.type+" ("+this.offset+"/"+this.length+")"+(this.parent?" parent: {"+this.parent.toString()+"}":"")}},rL=class extends r_{constructor(e,t){super(e,t),this.type="null",this.value=null}},rj=class extends r_{constructor(e,t,r){super(e,r),this.type="boolean",this.value=t}},rR=class extends r_{constructor(e,t){super(e,t),this.type="array",this.items=[]}get children(){return this.items}},rN=class extends r_{constructor(e,t){super(e,t),this.type="number",this.isInteger=!0,this.value=NaN}},rU=class extends r_{constructor(e,t,r){super(e,t,r),this.type="string",this.value=""}},rV=class extends r_{constructor(e,t,r){super(e,t),this.type="property",this.colonOffset=-1,this.keyNode=r}get children(){return this.valueNode?[this.keyNode,this.valueNode]:[this.keyNode]}},rD=class extends r_{constructor(e,t){super(e,t),this.type="object",this.properties=[]}get children(){return this.properties}};function rq(e){return rp(e)?e?{}:{not:{}}:e}(ed=tq||(tq={}))[ed.Key=0]="Key",ed[ed.Enum=1]="Enum";var rF="http://json-schema.org/";function rB(e){e.startsWith(rF)&&(e="https://json-schema.org/"+e.substring(rF.length));try{return rP.parse(e).toString(!0)}catch(t){return e}}function rH(e){var t;return null!=(t=rz[rB(e)])?t:void 0}var rz={"https://json-schema.org/draft-03/schema":tM.v3,"https://json-schema.org/draft-04/schema":tM.v4,"https://json-schema.org/draft-06/schema":tM.v6,"https://json-schema.org/draft-07/schema":tM.v7,"https://json-schema.org/draft/2019-09/schema":tM.v2019_09,"https://json-schema.org/draft/2020-12/schema":tM.v2020_12},rW=class{constructor(e){this.schemaDraft=e}},rK=class e{constructor(e=-1,t){this.focusOffset=e,this.exclude=t,this.schemas=[]}add(e){this.schemas.push(e)}merge(e){Array.prototype.push.apply(this.schemas,e.schemas)}include(e){return(-1===this.focusOffset||function(e,t,r=!1){return t>=e.offset&&t<e.offset+e.length||r&&t===e.offset+e.length}(e,this.focusOffset))&&e!==this.exclude}newSub(){return new e(-1,this.exclude)}},rJ=class{get schemas(){return[]}add(e){}merge(e){}include(e){return!0}newSub(){return this}};rJ.instance=new rJ;var rZ=class{constructor(){this.problems=[],this.propertiesMatches=0,this.processedProperties=new Set,this.propertiesValueMatches=0,this.primaryValueMatches=0,this.enumValueMatch=!1,this.enumValues=void 0}hasProblems(){return!!this.problems.length}merge(e){this.problems=this.problems.concat(e.problems),this.propertiesMatches+=e.propertiesMatches,this.propertiesValueMatches+=e.propertiesValueMatches,this.mergeProcessedProperties(e)}mergeEnumValues(e){!this.enumValueMatch&&!e.enumValueMatch&&this.enumValues&&e.enumValues&&(this.enumValues=this.enumValues.concat(e.enumValues))}updateEnumMismatchProblemMessages(){if(!this.enumValueMatch&&this.enumValues)for(let e of this.problems)e.code===tT.EnumValueMismatch&&(e.message=ru("Value is not accepted. Valid values: {0}.",this.enumValues.map(e=>JSON.stringify(e)).join(", ")))}mergePropertyMatch(e){this.problems=this.problems.concat(e.problems),this.propertiesMatches++,(e.enumValueMatch||!e.hasProblems()&&e.propertiesMatches)&&this.propertiesValueMatches++,e.enumValueMatch&&e.enumValues&&1===e.enumValues.length&&this.primaryValueMatches++}mergeProcessedProperties(e){e.processedProperties.forEach(e=>this.processedProperties.add(e))}compare(e){let t=this.hasProblems();return t!==e.hasProblems()?t?-1:1:this.enumValueMatch!==e.enumValueMatch?e.enumValueMatch?-1:1:this.primaryValueMatches!==e.primaryValueMatches?this.primaryValueMatches-e.primaryValueMatches:this.propertiesValueMatches!==e.propertiesValueMatches?this.propertiesValueMatches-e.propertiesValueMatches:this.propertiesMatches-e.propertiesMatches}},rX=class{constructor(e,t=[],r=[]){this.root=e,this.syntaxErrors=t,this.comments=r}getNodeFromOffset(e,t=!1){if(this.root)return rO(this.root,e,t)}visit(e){if(this.root){let t=r=>{let n=e(r),i=r.children;if(Array.isArray(i))for(let e=0;e<i.length&&n;e++)n=t(i[e]);return n};t(this.root)}}validate(e,t,r=eI.Warning,n){if(this.root&&t){let i=new rZ;return rQ(this.root,t,i,rJ.instance,new rW(null!=n?n:rG(t))),i.problems.map(t=>{var n;let i=eb.create(e.positionAt(t.location.offset),e.positionAt(t.location.offset+t.location.length));return eT.create(i,t.message,null!=(n=t.severity)?n:r,t.code)})}}getMatchingSchemas(e,t=-1,r){if(this.root&&e){let n=new rK(t,r),i=new rW(rG(e));return rQ(this.root,e,new rZ,n,i),n.schemas}return[]}};function rG(e,t=tM.v2020_12){var r;let n=e.$schema;return n&&null!=(r=rH(n))?r:t}function rQ(e,t,r,n,i){if(e&&n.include(e)){if("property"===e.type)return rQ(e.valueNode,t,r,n,i);switch(function(){var s,a,o;let l,c,u;function f(t){return e.type===t||"integer"===t&&"number"===e.type&&e.isInteger}if(Array.isArray(t.type)?t.type.some(f)||r.problems.push({location:{offset:e.offset,length:e.length},message:t.errorMessage||ru("Incorrect type. Expected one of {0}.",t.type.join(", "))}):t.type&&!f(t.type)&&r.problems.push({location:{offset:e.offset,length:e.length},message:t.errorMessage||ru('Incorrect type. Expected "{0}".',t.type)}),Array.isArray(t.allOf))for(let s of t.allOf){let t=new rZ,a=n.newSub();rQ(e,rq(s),t,a,i),r.merge(t),n.merge(a)}let h=rq(t.not);if(h){let s=new rZ,a=n.newSub();for(let o of(rQ(e,h,s,a,i),s.hasProblems()||r.problems.push({location:{offset:e.offset,length:e.length},message:t.errorMessage||ru("Matches a schema that is not allowed.")}),a.schemas))o.inverted=!o.inverted,n.add(o)}let d=(t,s)=>{var a;let o,l=[];for(let r of null!=(a=function(t){var r,n;if(t.length<2)return;let i=e=>{let r=new Map;for(let n=0;n<t.length;n++){let i=e(rq(t[n]),n);if(!i)return;i.forEach(([e,t])=>{if(void 0!==t.const){r.has(e)||r.set(e,new Map);let i=r.get(e);i.has(t.const)||i.set(t.const,[]),i.get(t.const).push(n)}})}return r},s=(e,r)=>{for(let[n,i]of e){let e=new Set;if(i.forEach(t=>t.forEach(t=>e.add(t))),e.size===t.length){let e=r(n),s=i.get(e);if(null==s?void 0:s.length)return s.map(e=>t[e]);break}}};if("object"===e.type&&(null==(r=e.properties)?void 0:r.length)){let t=i(e=>e.properties?Object.entries(e.properties).map(([e,t])=>[e,rq(t)]):void 0);if(t)return s(t,t=>{var r;let n=e.properties.find(e=>e.keyNode.value===t);return(null==(r=null==n?void 0:n.valueNode)?void 0:r.type)==="string"?n.valueNode.value:void 0})}else if("array"===e.type&&(null==(n=e.items)?void 0:n.length)){let t=i(e=>{let t=e.prefixItems||(Array.isArray(e.items)?e.items:void 0);return t?t.map((e,t)=>[t,rq(e)]):void 0});if(t)return s(t,t=>{let r=e.items[t];return(null==r?void 0:r.type)==="string"?r.value:void 0})}}(t))?a:t){let t=rq(r),a=new rZ,c=n.newSub();if(rQ(e,t,a,c,i),a.hasProblems()||l.push(t),o)if(s||a.hasProblems()||o.validationResult.hasProblems()){let e=a.compare(o.validationResult);e>0?o={schema:t,validationResult:a,matchingSchemas:c}:0===e&&(o.matchingSchemas.merge(c),o.validationResult.mergeEnumValues(a))}else o.matchingSchemas.merge(c),o.validationResult.propertiesMatches+=a.propertiesMatches,o.validationResult.propertiesValueMatches+=a.propertiesValueMatches,o.validationResult.mergeProcessedProperties(a);else o={schema:t,validationResult:a,matchingSchemas:c}}return l.length>1&&s&&r.problems.push({location:{offset:e.offset,length:1},message:ru("Matches multiple schemas when only one must validate.")}),o&&(o.validationResult.updateEnumMismatchProblemMessages(),r.merge(o.validationResult),n.merge(o.matchingSchemas)),l.length};Array.isArray(t.anyOf)&&d(t.anyOf,!1),Array.isArray(t.oneOf)&&d(t.oneOf,!0);let m=t=>{let s=new rZ,a=n.newSub();rQ(e,rq(t),s,a,i),r.merge(s),n.merge(a)},p=rq(t.if);if(p&&(a=rq(t.then),o=rq(t.else),l=rq(p),c=new rZ,rQ(e,l,c,u=n.newSub(),i),n.merge(u),r.mergeProcessedProperties(c),c.hasProblems()?o&&m(o):a&&m(a)),Array.isArray(t.enum)){let n=rC(e),i=!1;for(let e of t.enum)if(rd(n,e)){i=!0;break}r.enumValues=t.enum,r.enumValueMatch=i,i||r.problems.push({location:{offset:e.offset,length:e.length},code:tT.EnumValueMismatch,message:t.errorMessage||ru("Value is not accepted. Valid values: {0}.",t.enum.map(e=>JSON.stringify(e)).join(", "))})}void 0!==t.const&&(rd(rC(e),t.const)?r.enumValueMatch=!0:(r.problems.push({location:{offset:e.offset,length:e.length},code:tT.EnumValueMismatch,message:t.errorMessage||ru("Value must be {0}.",JSON.stringify(t.const))}),r.enumValueMatch=!1),r.enumValues=[t.const]);let g=t.deprecationMessage;if(g||t.deprecated){g=g||ru("Value is deprecated");let t=(null==(s=e.parent)?void 0:s.type)==="property"?e.parent:e;r.problems.push({location:{offset:t.offset,length:t.length},severity:eI.Warning,message:g,code:tT.Deprecated})}}(),e.type){case"object":!function(e){let s=Object.create(null),a=new Set;for(let t of e.properties){let e=t.keyNode.value;s[e]=t.valueNode,a.add(e)}if(Array.isArray(t.required)){for(let n of t.required)if(!s[n]){let t=e.parent&&"property"===e.parent.type&&e.parent.keyNode,i=t?{offset:t.offset,length:t.length}:{offset:e.offset,length:1};r.problems.push({location:i,message:ru('Missing property "{0}".',n)})}}let o=e=>{a.delete(e),r.processedProperties.add(e)};if(t.properties)for(let e of Object.keys(t.properties)){o(e);let a=t.properties[e],l=s[e];if(l)if(rp(a))if(a)r.propertiesMatches++,r.propertiesValueMatches++;else{let n=l.parent;r.problems.push({location:{offset:n.keyNode.offset,length:n.keyNode.length},message:t.errorMessage||ru("Property {0} is not allowed.",e)})}else{let e=new rZ;rQ(l,a,e,n,i),r.mergePropertyMatch(e)}}if(t.patternProperties)for(let e of Object.keys(t.patternProperties)){let l=rI(e);if(l){let c=[];for(let o of a)if(l.test(o)){c.push(o);let a=s[o];if(a){let s=t.patternProperties[e];if(rp(s))if(s)r.propertiesMatches++,r.propertiesValueMatches++;else{let e=a.parent;r.problems.push({location:{offset:e.keyNode.offset,length:e.keyNode.length},message:t.errorMessage||ru("Property {0} is not allowed.",o)})}else{let e=new rZ;rQ(a,s,e,n,i),r.mergePropertyMatch(e)}}}c.forEach(o)}}let l=t.additionalProperties;if(void 0!==l)for(let e of a){o(e);let a=s[e];if(a){if(!1===l){let n=a.parent;r.problems.push({location:{offset:n.keyNode.offset,length:n.keyNode.length},message:t.errorMessage||ru("Property {0} is not allowed.",e)})}else if(!0!==l){let e=new rZ;rQ(a,l,e,n,i),r.mergePropertyMatch(e)}}}let c=t.unevaluatedProperties;if(void 0!==c){let e=[];for(let o of a)if(!r.processedProperties.has(o)){e.push(o);let a=s[o];if(a){if(!1===c){let e=a.parent;r.problems.push({location:{offset:e.keyNode.offset,length:e.keyNode.length},message:t.errorMessage||ru("Property {0} is not allowed.",o)})}else if(!0!==c){let e=new rZ;rQ(a,c,e,n,i),r.mergePropertyMatch(e)}}}e.forEach(o)}if(rm(t.maxProperties)&&e.properties.length>t.maxProperties&&r.problems.push({location:{offset:e.offset,length:e.length},message:ru("Object has more properties than limit of {0}.",t.maxProperties)}),rm(t.minProperties)&&e.properties.length<t.minProperties&&r.problems.push({location:{offset:e.offset,length:e.length},message:ru("Object has fewer properties than the required number of {0}",t.minProperties)}),t.dependentRequired)for(let e in t.dependentRequired){let r=s[e],n=t.dependentRequired[e];r&&Array.isArray(n)&&f(e,n)}if(t.dependentSchemas)for(let e in t.dependentSchemas){let r=s[e],n=t.dependentSchemas[e];r&&ry(n)&&f(e,n)}if(t.dependencies)for(let e in t.dependencies)s[e]&&f(e,t.dependencies[e]);let u=rq(t.propertyNames);if(u)for(let t of e.properties){let e=t.keyNode;e&&rQ(e,u,r,n,i)}function f(t,a){if(Array.isArray(a))for(let n of a)s[n]?r.propertiesValueMatches++:r.problems.push({location:{offset:e.offset,length:e.length},message:ru("Object is missing property {0} required by property {1}.",n,t)});else{let t=rq(a);if(t){let s=new rZ;rQ(e,t,s,n,i),r.mergePropertyMatch(s)}}}}(e);break;case"array":!function(e){let s,a;i.schemaDraft>=tM.v2020_12?(s=t.prefixItems,a=Array.isArray(t.items)?void 0:t.items):(s=Array.isArray(t.items)?t.items:void 0,a=Array.isArray(t.items)?t.additionalItems:t.items);let o=0;if(void 0!==s){let t=Math.min(s.length,e.items.length);for(;o<t;o++){let t=rq(s[o]),a=new rZ,l=e.items[o];l&&(rQ(l,t,a,n,i),r.mergePropertyMatch(a)),r.processedProperties.add(String(o))}}if(void 0!==a&&o<e.items.length)if("boolean"==typeof a)for(!1===a&&r.problems.push({location:{offset:e.offset,length:e.length},message:ru("Array has too many items according to schema. Expected {0} or fewer.",o)});o<e.items.length;o++)r.processedProperties.add(String(o)),r.propertiesValueMatches++;else for(;o<e.items.length;o++){let t=new rZ;rQ(e.items[o],a,t,n,i),r.mergePropertyMatch(t),r.processedProperties.add(String(o))}let l=rq(t.contains);if(l){let n=0;for(let t=0;t<e.items.length;t++){let s=e.items[t],a=new rZ;rQ(s,l,a,rJ.instance,i),!a.hasProblems()&&(n++,i.schemaDraft>=tM.v2020_12&&r.processedProperties.add(String(t)))}0!==n||rm(t.minContains)||r.problems.push({location:{offset:e.offset,length:e.length},message:t.errorMessage||ru("Array does not contain required item.")}),rm(t.minContains)&&n<t.minContains&&r.problems.push({location:{offset:e.offset,length:e.length},message:t.errorMessage||ru("Array has too few items that match the contains contraint. Expected {0} or more.",t.minContains)}),rm(t.maxContains)&&n>t.maxContains&&r.problems.push({location:{offset:e.offset,length:e.length},message:t.errorMessage||ru("Array has too many items that match the contains contraint. Expected {0} or less.",t.maxContains)})}let c=t.unevaluatedItems;if(void 0!==c)for(let s=0;s<e.items.length;s++){if(!r.processedProperties.has(String(s)))if(!1===c)r.problems.push({location:{offset:e.offset,length:e.length},message:ru("Item does not match any validation rule from the array.")});else{let a=new rZ;rQ(e.items[s],t.unevaluatedItems,a,n,i),r.mergePropertyMatch(a)}r.processedProperties.add(String(s)),r.propertiesValueMatches++}if(rm(t.minItems)&&e.items.length<t.minItems&&r.problems.push({location:{offset:e.offset,length:e.length},message:ru("Array has too few items. Expected {0} or more.",t.minItems)}),rm(t.maxItems)&&e.items.length>t.maxItems&&r.problems.push({location:{offset:e.offset,length:e.length},message:ru("Array has too many items. Expected {0} or fewer.",t.maxItems)}),!0===t.uniqueItems){let t=rC(e);(function(){for(let e=0;e<t.length-1;e++){let r=t[e];for(let n=e+1;n<t.length;n++)if(rd(r,t[n]))return!0}return!1})()&&r.problems.push({location:{offset:e.offset,length:e.length},message:ru("Array has duplicate items.")})}}(e);break;case"string":var s=e;if(rm(t.minLength)&&rE(s.value)<t.minLength&&r.problems.push({location:{offset:s.offset,length:s.length},message:ru("String is shorter than the minimum length of {0}.",t.minLength)}),rm(t.maxLength)&&rE(s.value)>t.maxLength&&r.problems.push({location:{offset:s.offset,length:s.length},message:ru("String is longer than the maximum length of {0}.",t.maxLength)}),rg(t.pattern)){let e=rI(t.pattern);e&&!e.test(s.value)&&r.problems.push({location:{offset:s.offset,length:s.length},message:t.patternErrorMessage||t.errorMessage||ru('String does not match the pattern of "{0}".',t.pattern)})}if(t.format)switch(t.format){case"uri":case"uri-reference":{let e;if(s.value){let r=/^(([^:/?#]+?):)?(\/\/([^/?#]*))?([^?#]*)(\?([^#]*))?(#(.*))?/.exec(s.value);r?r[2]||"uri"!==t.format||(e=ru("URI with a scheme is expected.")):e=ru("URI is expected.")}else e=ru("URI expected.");e&&r.problems.push({location:{offset:s.offset,length:s.length},message:t.patternErrorMessage||t.errorMessage||ru("String is not a URI: {0}",e)})}break;case"color-hex":case"date-time":case"date":case"time":case"email":case"hostname":case"ipv4":case"ipv6":let a=rM[t.format];s.value&&a.pattern.exec(s.value)||r.problems.push({location:{offset:s.offset,length:s.length},message:t.patternErrorMessage||t.errorMessage||a.errorMessage})}break;case"number":!function(e){let n=e.value;function i(e){var t;let r=/^(-?\d+)(?:\.(\d+))?(?:e([-+]\d+))?$/.exec(e.toString());return r&&{value:Number(r[1]+(r[2]||"")),multiplier:((null==(t=r[2])?void 0:t.length)||0)-(parseInt(r[3])||0)}}if(rm(t.multipleOf)){let s=-1;if(Number.isInteger(t.multipleOf))s=n%t.multipleOf;else{let e=i(t.multipleOf),r=i(n);if(e&&r){let t=tJ(10,Math.abs(r.multiplier-e.multiplier));r.multiplier<e.multiplier?r.value*=t:e.value*=t,s=r.value%e.value}}0!==s&&r.problems.push({location:{offset:e.offset,length:e.length},message:ru("Value is not divisible by {0}.",t.multipleOf)})}function s(e,t){return rm(t)?t:rp(t)&&t?e:void 0}function a(e,t){if(!rp(t)||!t)return e}let o=s(t.minimum,t.exclusiveMinimum);rm(o)&&n<=o&&r.problems.push({location:{offset:e.offset,length:e.length},message:ru("Value is below the exclusive minimum of {0}.",o)});let l=s(t.maximum,t.exclusiveMaximum);rm(l)&&n>=l&&r.problems.push({location:{offset:e.offset,length:e.length},message:ru("Value is above the exclusive maximum of {0}.",l)});let c=a(t.minimum,t.exclusiveMinimum);rm(c)&&n<c&&r.problems.push({location:{offset:e.offset,length:e.length},message:ru("Value is below the minimum of {0}.",c)});let u=a(t.maximum,t.exclusiveMaximum);rm(u)&&n>u&&r.problems.push({location:{offset:e.offset,length:e.length},message:ru("Value is above the maximum of {0}.",u)})}(e)}n.add({node:e,schema:t})}}var rY={schemaAssociations:[],schemas:{"https://json-schema.org/draft-04/schema":{definitions:{schemaArray:{type:"array",minItems:1,items:{$ref:"#"}},positiveInteger:{type:"integer",minimum:0},positiveIntegerDefault0:{allOf:[{$ref:"#/definitions/positiveInteger"},{default:0}]},simpleTypes:{type:"string",enum:["array","boolean","integer","null","number","object","string"]},stringArray:{type:"array",items:{type:"string"},minItems:1,uniqueItems:!0}},type:"object",properties:{id:{type:"string",format:"uri"},$schema:{type:"string",format:"uri"},title:{type:"string"},description:{type:"string"},default:{},multipleOf:{type:"number",minimum:0,exclusiveMinimum:!0},maximum:{type:"number"},exclusiveMaximum:{type:"boolean",default:!1},minimum:{type:"number"},exclusiveMinimum:{type:"boolean",default:!1},maxLength:{allOf:[{$ref:"#/definitions/positiveInteger"}]},minLength:{allOf:[{$ref:"#/definitions/positiveIntegerDefault0"}]},pattern:{type:"string",format:"regex"},additionalItems:{anyOf:[{type:"boolean"},{$ref:"#"}],default:{}},items:{anyOf:[{$ref:"#"},{$ref:"#/definitions/schemaArray"}],default:{}},maxItems:{allOf:[{$ref:"#/definitions/positiveInteger"}]},minItems:{allOf:[{$ref:"#/definitions/positiveIntegerDefault0"}]},uniqueItems:{type:"boolean",default:!1},maxProperties:{allOf:[{$ref:"#/definitions/positiveInteger"}]},minProperties:{allOf:[{$ref:"#/definitions/positiveIntegerDefault0"}]},required:{allOf:[{$ref:"#/definitions/stringArray"}]},additionalProperties:{anyOf:[{type:"boolean"},{$ref:"#"}],default:{}},definitions:{type:"object",additionalProperties:{$ref:"#"},default:{}},properties:{type:"object",additionalProperties:{$ref:"#"},default:{}},patternProperties:{type:"object",additionalProperties:{$ref:"#"},default:{}},dependencies:{type:"object",additionalProperties:{anyOf:[{$ref:"#"},{$ref:"#/definitions/stringArray"}]}},enum:{type:"array",minItems:1,uniqueItems:!0},type:{anyOf:[{$ref:"#/definitions/simpleTypes"},{type:"array",items:{$ref:"#/definitions/simpleTypes"},minItems:1,uniqueItems:!0}]},format:{anyOf:[{type:"string",enum:["date-time","uri","email","hostname","ipv4","ipv6","regex"]},{type:"string"}]},allOf:{allOf:[{$ref:"#/definitions/schemaArray"}]},anyOf:{allOf:[{$ref:"#/definitions/schemaArray"}]},oneOf:{allOf:[{$ref:"#/definitions/schemaArray"}]},not:{allOf:[{$ref:"#"}]}},dependencies:{exclusiveMaximum:["maximum"],exclusiveMinimum:["minimum"]},default:{}},"https://json-schema.org/draft-07/schema":{definitions:{schemaArray:{type:"array",minItems:1,items:{$ref:"#"}},nonNegativeInteger:{type:"integer",minimum:0},nonNegativeIntegerDefault0:{allOf:[{$ref:"#/definitions/nonNegativeInteger"},{default:0}]},simpleTypes:{enum:["array","boolean","integer","null","number","object","string"]},stringArray:{type:"array",items:{type:"string"},uniqueItems:!0,default:[]}},type:["object","boolean"],properties:{$id:{type:"string",format:"uri-reference"},$schema:{type:"string",format:"uri"},$ref:{type:"string",format:"uri-reference"},$comment:{type:"string"},title:{type:"string"},description:{type:"string"},default:!0,readOnly:{type:"boolean",default:!1},examples:{type:"array",items:!0},multipleOf:{type:"number",exclusiveMinimum:0},maximum:{type:"number"},exclusiveMaximum:{type:"number"},minimum:{type:"number"},exclusiveMinimum:{type:"number"},maxLength:{$ref:"#/definitions/nonNegativeInteger"},minLength:{$ref:"#/definitions/nonNegativeIntegerDefault0"},pattern:{type:"string",format:"regex"},additionalItems:{$ref:"#"},items:{anyOf:[{$ref:"#"},{$ref:"#/definitions/schemaArray"}],default:!0},maxItems:{$ref:"#/definitions/nonNegativeInteger"},minItems:{$ref:"#/definitions/nonNegativeIntegerDefault0"},uniqueItems:{type:"boolean",default:!1},contains:{$ref:"#"},maxProperties:{$ref:"#/definitions/nonNegativeInteger"},minProperties:{$ref:"#/definitions/nonNegativeIntegerDefault0"},required:{$ref:"#/definitions/stringArray"},additionalProperties:{$ref:"#"},definitions:{type:"object",additionalProperties:{$ref:"#"},default:{}},properties:{type:"object",additionalProperties:{$ref:"#"},default:{}},patternProperties:{type:"object",additionalProperties:{$ref:"#"},propertyNames:{format:"regex"},default:{}},dependencies:{type:"object",additionalProperties:{anyOf:[{$ref:"#"},{$ref:"#/definitions/stringArray"}]}},propertyNames:{$ref:"#"},const:!0,enum:{type:"array",items:!0,minItems:1,uniqueItems:!0},type:{anyOf:[{$ref:"#/definitions/simpleTypes"},{type:"array",items:{$ref:"#/definitions/simpleTypes"},minItems:1,uniqueItems:!0}]},format:{type:"string"},contentMediaType:{type:"string"},contentEncoding:{type:"string"},if:{$ref:"#"},then:{$ref:"#"},else:{$ref:"#"},allOf:{$ref:"#/definitions/schemaArray"},anyOf:{$ref:"#/definitions/schemaArray"},oneOf:{$ref:"#/definitions/schemaArray"},not:{$ref:"#"}},default:!0},"https://json-schema.org/draft/2020-12/schema":{$id:"https://json-schema.org/draft/2020-12/schema",$schema:"https://json-schema.org/draft/2020-12/schema",title:"(Flattened static) Core and Validation specifications meta-schema",type:["object","boolean"],properties:{definitions:{$comment:"While no longer an official keyword as it is replaced by $defs, this keyword is retained in the meta-schema to prevent incompatible extensions as it remains in common use.",type:"object",additionalProperties:{$ref:"#"},default:{}},dependencies:{$comment:'"dependencies" is no longer a keyword, but schema authors should avoid redefining it to facilitate a smooth transition to "dependentSchemas" and "dependentRequired"',type:"object",additionalProperties:{anyOf:[{$ref:"#"},{$ref:"#/$defs/stringArray"}]}},$id:{type:"string",format:"uri-reference",$comment:"Non-empty fragments not allowed.",pattern:"^[^#]*#?$"},$schema:{type:"string",format:"uri"},$anchor:{type:"string",pattern:"^[A-Za-z_][-A-Za-z0-9._]*$"},$ref:{type:"string",format:"uri-reference"},$dynamicRef:{type:"string",format:"uri-reference"},$vocabulary:{type:"object",propertyNames:{type:"string",format:"uri"},additionalProperties:{type:"boolean"}},$comment:{type:"string"},$defs:{type:"object",additionalProperties:{$ref:"#"},default:{}},prefixItems:{$ref:"#/$defs/schemaArray"},items:{$ref:"#"},contains:{$ref:"#"},additionalProperties:{$ref:"#"},properties:{type:"object",additionalProperties:{$ref:"#"},default:{}},patternProperties:{type:"object",additionalProperties:{$ref:"#"},propertyNames:{format:"regex"},default:{}},dependentSchemas:{type:"object",additionalProperties:{$ref:"#"}},propertyNames:{$ref:"#"},if:{$ref:"#"},then:{$ref:"#"},else:{$ref:"#"},allOf:{$ref:"#/$defs/schemaArray"},anyOf:{$ref:"#/$defs/schemaArray"},oneOf:{$ref:"#/$defs/schemaArray"},not:{$ref:"#"},unevaluatedItems:{$ref:"#"},unevaluatedProperties:{$ref:"#"},multipleOf:{type:"number",exclusiveMinimum:0},maximum:{type:"number"},exclusiveMaximum:{type:"number"},minimum:{type:"number"},exclusiveMinimum:{type:"number"},maxLength:{$ref:"#/$defs/nonNegativeInteger"},minLength:{$ref:"#/$defs/nonNegativeIntegerDefault0"},pattern:{type:"string",format:"regex"},maxItems:{$ref:"#/$defs/nonNegativeInteger"},minItems:{$ref:"#/$defs/nonNegativeIntegerDefault0"},uniqueItems:{type:"boolean",default:!1},maxContains:{$ref:"#/$defs/nonNegativeInteger"},minContains:{$ref:"#/$defs/nonNegativeInteger",default:1},maxProperties:{$ref:"#/$defs/nonNegativeInteger"},minProperties:{$ref:"#/$defs/nonNegativeIntegerDefault0"},required:{$ref:"#/$defs/stringArray"},dependentRequired:{type:"object",additionalProperties:{$ref:"#/$defs/stringArray"}},const:!0,enum:{type:"array",items:!0},type:{anyOf:[{$ref:"#/$defs/simpleTypes"},{type:"array",items:{$ref:"#/$defs/simpleTypes"},minItems:1,uniqueItems:!0}]},title:{type:"string"},description:{type:"string"},default:!0,deprecated:{type:"boolean",default:!1},readOnly:{type:"boolean",default:!1},writeOnly:{type:"boolean",default:!1},examples:{type:"array",items:!0},format:{type:"string"},contentMediaType:{type:"string"},contentEncoding:{type:"string"},contentSchema:{$ref:"#"}},$defs:{schemaArray:{type:"array",minItems:1,items:{$ref:"#"}},nonNegativeInteger:{type:"integer",minimum:0},nonNegativeIntegerDefault0:{$ref:"#/$defs/nonNegativeInteger",default:0},simpleTypes:{enum:["array","boolean","integer","null","number","object","string"]},stringArray:{type:"array",items:{type:"string"},uniqueItems:!0,default:[]}}},"https://json-schema.org/draft/2019-09/schema":{$id:"https://json-schema.org/draft/2019-09/schema",$schema:"https://json-schema.org/draft/2019-09/schema",title:"(Flattened static) Core and Validation specifications meta-schema",type:["object","boolean"],properties:{definitions:{$comment:"While no longer an official keyword as it is replaced by $defs, this keyword is retained in the meta-schema to prevent incompatible extensions as it remains in common use.",type:"object",additionalProperties:{$ref:"#"},default:{}},dependencies:{$comment:'"dependencies" is no longer a keyword, but schema authors should avoid redefining it to facilitate a smooth transition to "dependentSchemas" and "dependentRequired"',type:"object",additionalProperties:{anyOf:[{$ref:"#"},{$ref:"#/$defs/stringArray"}]}},$id:{type:"string",format:"uri-reference",$comment:"Non-empty fragments not allowed.",pattern:"^[^#]*#?$"},$schema:{type:"string",format:"uri"},$anchor:{type:"string",pattern:"^[A-Za-z][-A-Za-z0-9.:_]*$"},$ref:{type:"string",format:"uri-reference"},$recursiveAnchor:{type:"boolean",default:!1},$vocabulary:{type:"object",propertyNames:{type:"string",format:"uri"},additionalProperties:{type:"boolean"}},$comment:{type:"string"},$defs:{type:"object",additionalProperties:{$ref:"#"},default:{}},additionalItems:{$ref:"#"},unevaluatedItems:{$ref:"#"},items:{anyOf:[{$ref:"#"},{$ref:"#/$defs/schemaArray"}]},contains:{$ref:"#"},additionalProperties:{$ref:"#"},unevaluatedProperties:{$ref:"#"},properties:{type:"object",additionalProperties:{$ref:"#"},default:{}},patternProperties:{type:"object",additionalProperties:{$ref:"#"},propertyNames:{format:"regex"},default:{}},dependentSchemas:{type:"object",additionalProperties:{$ref:"#"}},propertyNames:{$ref:"#"},if:{$ref:"#"},then:{$ref:"#"},else:{$ref:"#"},allOf:{$ref:"#/$defs/schemaArray"},anyOf:{$ref:"#/$defs/schemaArray"},oneOf:{$ref:"#/$defs/schemaArray"},not:{$ref:"#"},multipleOf:{type:"number",exclusiveMinimum:0},maximum:{type:"number"},exclusiveMaximum:{type:"number"},minimum:{type:"number"},exclusiveMinimum:{type:"number"},maxLength:{$ref:"#/$defs/nonNegativeInteger"},minLength:{$ref:"#/$defs/nonNegativeIntegerDefault0"},pattern:{type:"string",format:"regex"},maxItems:{$ref:"#/$defs/nonNegativeInteger"},minItems:{$ref:"#/$defs/nonNegativeIntegerDefault0"},uniqueItems:{type:"boolean",default:!1},maxContains:{$ref:"#/$defs/nonNegativeInteger"},minContains:{$ref:"#/$defs/nonNegativeInteger",default:1},maxProperties:{$ref:"#/$defs/nonNegativeInteger"},minProperties:{$ref:"#/$defs/nonNegativeIntegerDefault0"},required:{$ref:"#/$defs/stringArray"},dependentRequired:{type:"object",additionalProperties:{$ref:"#/$defs/stringArray"}},const:!0,enum:{type:"array",items:!0},type:{anyOf:[{$ref:"#/$defs/simpleTypes"},{type:"array",items:{$ref:"#/$defs/simpleTypes"},minItems:1,uniqueItems:!0}]},title:{type:"string"},description:{type:"string"},default:!0,deprecated:{type:"boolean",default:!1},readOnly:{type:"boolean",default:!1},writeOnly:{type:"boolean",default:!1},examples:{type:"array",items:!0},format:{type:"string"},contentMediaType:{type:"string"},contentEncoding:{type:"string"},contentSchema:{$ref:"#"}},$defs:{schemaArray:{type:"array",minItems:1,items:{$ref:"#"}},nonNegativeInteger:{type:"integer",minimum:0},nonNegativeIntegerDefault0:{$ref:"#/$defs/nonNegativeInteger",default:0},simpleTypes:{enum:["array","boolean","integer","null","number","object","string"]},stringArray:{type:"array",items:{type:"string"},uniqueItems:!0,default:[]}}}}},r0={id:ru("A unique identifier for the schema."),$schema:ru("The schema to verify this document against."),title:ru("A descriptive title of the schema."),description:ru("A long description of the schema. Used in hover menus and suggestions."),default:ru("A default value. Used by suggestions."),multipleOf:ru("A number that should cleanly divide the current value (i.e. have no remainder)."),maximum:ru("The maximum numerical value, inclusive by default."),exclusiveMaximum:ru("Makes the maximum property exclusive."),minimum:ru("The minimum numerical value, inclusive by default."),exclusiveMinimum:ru("Makes the minimum property exclusive."),maxLength:ru("The maximum length of a string."),minLength:ru("The minimum length of a string."),pattern:ru("A regular expression to match the string against. It is not implicitly anchored."),additionalItems:ru("For arrays, only when items is set as an array. If items are a schema, this schema validates items after the ones specified by the items schema. If false, additional items will cause validation to fail."),items:ru("For arrays. Can either be a schema to validate every element against or an array of schemas to validate each item against in order (the first schema will validate the first element, the second schema will validate the second element, and so on."),maxItems:ru("The maximum number of items that can be inside an array. Inclusive."),minItems:ru("The minimum number of items that can be inside an array. Inclusive."),uniqueItems:ru("If all of the items in the array must be unique. Defaults to false."),maxProperties:ru("The maximum number of properties an object can have. Inclusive."),minProperties:ru("The minimum number of properties an object can have. Inclusive."),required:ru("An array of strings that lists the names of all properties required on this object."),additionalProperties:ru("Either a schema or a boolean. If a schema, used to validate all properties not matched by 'properties', 'propertyNames', or 'patternProperties'. If false, any properties not defined by the adjacent keywords will cause this schema to fail."),definitions:ru("Not used for validation. Place subschemas here that you wish to reference inline with $ref."),properties:ru("A map of property names to schemas for each property."),patternProperties:ru("A map of regular expressions on property names to schemas for matching properties."),dependencies:ru("A map of property names to either an array of property names or a schema. An array of property names means the property named in the key depends on the properties in the array being present in the object in order to be valid. If the value is a schema, then the schema is only applied to the object if the property in the key exists on the object."),enum:ru("The set of literal values that are valid."),type:ru("Either a string of one of the basic schema types (number, integer, null, array, object, boolean, string) or an array of strings specifying a subset of those types."),format:ru("Describes the format expected for the value. By default, not used for validation"),allOf:ru("An array of schemas, all of which must match."),anyOf:ru("An array of schemas, where at least one must match."),oneOf:ru("An array of schemas, exactly one of which must match."),not:ru("A schema which must not match."),$id:ru("A unique identifier for the schema."),$ref:ru("Reference a definition hosted on any location."),$comment:ru("Comments from schema authors to readers or maintainers of the schema."),readOnly:ru("Indicates that the value of the instance is managed exclusively by the owning authority."),examples:ru("Sample JSON values associated with a particular schema, for the purpose of illustrating usage."),contains:ru('An array instance is valid against "contains" if at least one of its elements is valid against the given schema.'),propertyNames:ru("If the instance is an object, this keyword validates if every property name in the instance validates against the provided schema."),const:ru("An instance validates successfully against this keyword if its value is equal to the value of the keyword."),contentMediaType:ru("Describes the media type of a string property."),contentEncoding:ru("Describes the content encoding of a string property."),if:ru('The validation outcome of the "if" subschema controls which of the "then" or "else" keywords are evaluated.'),then:ru('The "then" subschema is used for validation when the "if" subschema succeeds.'),else:ru('The "else" subschema is used for validation when the "if" subschema fails.')};for(let e in rY.schemas){let t=rY.schemas[e];for(let e in t.properties){let r=t.properties[e];"boolean"==typeof r&&(r=t.properties[e]={});let n=r0[e];n&&(r.description=n)}}var r1=class{constructor(e,t,r){this.folderUri=t,this.uris=r,this.globWrappers=[];try{for(let t of e){const e="!"!==t[0];e||(t=t.substring(1)),t.length>0&&("/"===t[0]&&(t=t.substring(1)),this.globWrappers.push({regexp:function(e,t){let r;if("string"!=typeof e)throw TypeError("Expected a string");let n=String(e),i="",s=!!t&&!!t.extended,a=!!t&&!!t.globstar,o=!1,l=t&&"string"==typeof t.flags?t.flags:"";for(let e=0,t=n.length;e<t;e++)switch(r=n[e]){case"/":case"$":case"^":case"+":case".":case"(":case")":case"=":case"!":case"|":i+="\\"+r;break;case"?":if(s){i+=".";break}case"[":case"]":if(s){i+=r;break}case"{":if(s){o=!0,i+="(";break}case"}":if(s){o=!1,i+=")";break}case",":if(o){i+="|";break}i+="\\"+r;break;case"*":let t=n[e-1],l=1;for(;"*"===n[e+1];)l++,e++;let c=n[e+1];a?l>1&&("/"===t||void 0===t||"{"===t||","===t)&&("/"===c||void 0===c||","===c||"}"===c)?("/"===c?e++:"/"===t&&i.endsWith("\\/")&&(i=i.substr(0,i.length-2)),i+="((?:[^/]*(?:/|$))*)"):i+="([^/]*)":i+=".*";break;default:i+=r}return l&&~l.indexOf("g")||(i="^"+i+"$"),new RegExp(i,l)}("**/"+t,{extended:!0,globstar:!0}),include:e}))}t&&((t=r6(t)).endsWith("/")||(t+="/"),this.folderUri=t)}catch(e){this.globWrappers.length=0,this.uris=[]}}matchesPattern(e){if(this.folderUri&&!e.startsWith(this.folderUri))return!1;let t=!1;for(let{regexp:r,include:n}of this.globWrappers)r.test(e)&&(t=n);return t}getURIs(){return this.uris}},r2=class{constructor(e,t,r){this.service=e,this.uri=t,this.dependencies=new Set,this.anchors=void 0,r&&(this.unresolvedSchema=this.service.promise.resolve(new r4(r)))}getUnresolvedSchema(){return this.unresolvedSchema||(this.unresolvedSchema=this.service.loadSchema(this.uri)),this.unresolvedSchema}getResolvedSchema(){return this.resolvedSchema||(this.resolvedSchema=this.getUnresolvedSchema().then(e=>this.service.resolveSchemaContent(e,this))),this.resolvedSchema}clearSchema(){let e=!!this.unresolvedSchema;return this.resolvedSchema=void 0,this.unresolvedSchema=void 0,this.dependencies.clear(),this.anchors=void 0,e}},r4=class{constructor(e,t=[]){this.schema=e,this.errors=t}};function r5(e,t,r){let n=r?[{location:{uri:r,range:eb.create(0,0,0,0)},message:e}]:void 0;return{message:e,code:t,relatedInformation:n}}var r9=class{constructor(e,t=[],r=[],n){this.schema=e,this.errors=t,this.warnings=r,this.schemaDraft=n}getSection(e){let t=this.getSectionRecursive(e,this.schema);if(t)return rq(t)}getSectionRecursive(e,t){if(!t||"boolean"==typeof t||0===e.length)return t;let r=e.shift();if(t.properties&&(t.properties[r],1))return this.getSectionRecursive(e,t.properties[r]);if(t.patternProperties)for(let n of Object.keys(t.patternProperties)){let i=rI(n);if(null==i?void 0:i.test(r))return this.getSectionRecursive(e,t.patternProperties[n])}else if("object"==typeof t.additionalProperties)return this.getSectionRecursive(e,t.additionalProperties);else if(r.match("[0-9]+")){if(Array.isArray(t.items)){let n=parseInt(r,10);if(!isNaN(n)&&t.items[n])return this.getSectionRecursive(e,t.items[n])}else if(t.items)return this.getSectionRecursive(e,t.items)}}},r3=class{constructor(e,t,r){this.contextService=t,this.requestService=e,this.promiseConstructor=r||Promise,this.callOnDispose=[],this.contributionSchemas={},this.contributionAssociations=[],this.schemasById={},this.filePatternAssociations=[],this.registeredSchemasIds={}}getRegisteredSchemaIds(e){return Object.keys(this.registeredSchemasIds).filter(t=>{let r=rP.parse(t).scheme;return"schemaservice"!==r&&(!e||e(r))})}get promise(){return this.promiseConstructor}dispose(){for(;this.callOnDispose.length>0;)this.callOnDispose.pop()()}onResourceChange(e){this.cachedSchemaForResource=void 0;let t=!1,r=[e=rB(e)],n=Object.keys(this.schemasById).map(e=>this.schemasById[e]);for(;r.length;){let e=r.pop();for(let i=0;i<n.length;i++){let s=n[i];s&&(s.uri===e||s.dependencies.has(e))&&(s.uri!==e&&r.push(s.uri),s.clearSchema()&&(t=!0),n[i]=void 0)}}return t}setSchemaContributions(e){if(e.schemas){let t=e.schemas;for(let e in t){let r=rB(e);this.contributionSchemas[r]=this.addSchemaHandle(r,t[e])}}if(Array.isArray(e.schemaAssociations))for(let t of e.schemaAssociations){let e=t.uris.map(rB),r=this.addFilePatternAssociation(t.pattern,t.folderUri,e);this.contributionAssociations.push(r)}}addSchemaHandle(e,t){let r=new r2(this,e,t);return this.schemasById[e]=r,r}getOrAddSchemaHandle(e,t){return this.schemasById[e]||this.addSchemaHandle(e,t)}addFilePatternAssociation(e,t,r){let n=new r1(e,t,r);return this.filePatternAssociations.push(n),n}registerExternalSchema(e){let t=rB(e.uri);return this.registeredSchemasIds[t]=!0,this.cachedSchemaForResource=void 0,e.fileMatch&&e.fileMatch.length&&this.addFilePatternAssociation(e.fileMatch,e.folderUri,[t]),e.schema?this.addSchemaHandle(t,e.schema):this.getOrAddSchemaHandle(t)}clearExternalSchemas(){for(let e in this.schemasById={},this.filePatternAssociations=[],this.registeredSchemasIds={},this.cachedSchemaForResource=void 0,this.contributionSchemas)this.schemasById[e]=this.contributionSchemas[e],this.registeredSchemasIds[e]=!0;for(let e of this.contributionAssociations)this.filePatternAssociations.push(e)}getResolvedSchema(e){let t=rB(e),r=this.schemasById[t];return r?r.getResolvedSchema():this.promise.resolve(void 0)}loadSchema(e){if(!this.requestService){let t=ru("Unable to load schema from '{0}'. No schema request service available",r8(e));return this.promise.resolve(new r4({},[r5(t,tT.SchemaResolveError,e)]))}return this.requestService(e).then(t=>{if(!t)return new r4({},[r5(ru("Unable to load schema from '{0}': No content.",r8(e)),tT.SchemaResolveError,e)]);let r=[];65279===t.charCodeAt(0)&&(r.push(r5(ru("Problem reading content from '{0}': UTF-8 with BOM detected, only UTF 8 is allowed.",r8(e)),tT.SchemaResolveError,e)),t=t.trimStart());let n={},i=[];return n=rS(t,i),i.length&&r.push(r5(ru("Unable to parse content from '{0}': Parse error at offset {1}.",r8(e),i[0].offset),tT.SchemaResolveError,e)),new r4(n,r)},t=>{let{message:r,code:n}=t;if("string"!=typeof r){var i;let e,n=t.toString(),s=t.toString().split("Error: ");s.length>1&&(n=s[1]),((e=(i=n).length-1)>0?i.lastIndexOf(".")===e:0===e&&"."===i)&&(n=n.substr(0,n.length-1)),r=n}let s=tT.SchemaResolveError;return"number"==typeof n&&n<65536&&(s+=n),new r4({},[r5(ru("Unable to load schema from '{0}': {1}.",r8(e),r),s,e)])})}resolveSchemaContent(e,t){let r=e.errors.slice(0),n=e.schema,i=n.$schema?rH(n.$schema):void 0;if(i===tM.v3)return this.promise.resolve(new r9({},[r5(ru("Draft-03 schemas are not supported."),tT.SchemaUnsupportedFeature)],[],i));let s=new Set,a=this.contextService,o=(e,t,n,i)=>{let s;if(void 0===i||0===i.length)s=t;else if("/"===i.charAt(0)){let e;a=decodeURIComponent(a=i),e=t,"/"===a[0]&&(a=a.substring(1)),a.split("/").some(t=>!(e=e[t=t.replace(/~1/g,"/").replace(/~0/g,"~")])),s=e}else n.anchors||(n.anchors=u(t)),s=n.anchors.get(i);if(s){var a,o=s;for(let t in o)o.hasOwnProperty(t)&&"id"!==t&&"$id"!==t&&(e[t]=o[t])}else{let e=ru("$ref '{0}' in '{1}' can not be resolved.",i||"",n.uri);r.push(r5(e,tT.SchemaResolveError))}},l=(e,t,n,i)=>{a&&!/^[A-Za-z][A-Za-z0-9+\-.+]*:\/.*/.test(t)&&(t=a.resolveRelativePath(t,i.uri)),t=rB(t);let s=this.getOrAddSchemaHandle(t);return s.getUnresolvedSchema().then(a=>{if(i.dependencies.add(t),a.errors.length){let e=a.errors[0],i=n?ru("Problems loading reference '{0}': {1}",n,e.message):e.message;r.push(r5(i,e.code,t))}return o(e,a.schema,s,n),c(e,a.schema,s)})},c=(e,t,r)=>{let n=[];return this.traverseNodes(e,e=>{let i=new Set;for(;e.$ref;){let s=e.$ref,a=s.split("#",2);if(delete e.$ref,a[0].length>0)return void n.push(l(e,a[0],a[1],r));i.has(s)||(o(e,t,r,a[1]),i.add(s))}e.$recursiveRef&&s.add("$recursiveRef"),e.$dynamicRef&&s.add("$dynamicRef")}),this.promise.all(n)},u=e=>{let t=new Map;return this.traverseNodes(e,e=>{let n=e.$id||e.id,i=rg(n)&&"#"===n.charAt(0)?n.substring(1):e.$anchor;i&&(t.has(i)?r.push(r5(ru("Duplicate anchor declaration: '{0}'",i),tT.SchemaResolveError)):t.set(i,e)),e.$recursiveAnchor&&s.add("$recursiveAnchor"),e.$dynamicAnchor&&s.add("$dynamicAnchor")}),t};return c(n,n,t).then(e=>{let t=[];return s.size&&t.push(r5(ru("The schema uses meta-schema features ({0}) that are not yet supported by the validator.",Array.from(s.keys()).join(", ")),tT.SchemaUnsupportedFeature)),new r9(n,r,t,i)})}traverseNodes(e,t){if(!e||"object"!=typeof e)return Promise.resolve(null);let r=new Set,n=(...e)=>{for(let t of e)ry(t)&&o.push(t)},i=(...e)=>{for(let t of e)if(ry(t))for(let e in t){let r=t[e];ry(r)&&o.push(r)}},s=(...e)=>{for(let t of e)if(Array.isArray(t))for(let e of t)ry(e)&&o.push(e)},a=e=>{if(Array.isArray(e))for(let t of e)ry(t)&&o.push(t);else ry(e)&&o.push(e)},o=[e],l=o.pop();for(;l;)r.has(l)||(r.add(l),t(l),n(l.additionalItems,l.additionalProperties,l.not,l.contains,l.propertyNames,l.if,l.then,l.else,l.unevaluatedItems,l.unevaluatedProperties),i(l.definitions,l.$defs,l.properties,l.patternProperties,l.dependencies,l.dependentSchemas),s(l.anyOf,l.allOf,l.oneOf,l.prefixItems),a(l.items)),l=o.pop()}getSchemaFromProperty(e,t){var r,n;if((null==(r=t.root)?void 0:r.type)==="object"){for(let r of t.root.properties)if("$schema"===r.keyNode.value&&(null==(n=r.valueNode)?void 0:n.type)==="string"){let t=r.valueNode.value;return this.contextService&&!/^\w[\w\d+.-]*:/.test(t)&&(t=this.contextService.resolveRelativePath(t,e)),t}}}getAssociatedSchemas(e){let t=Object.create(null),r=[],n=r6(e);for(let e of this.filePatternAssociations)if(e.matchesPattern(n))for(let n of e.getURIs())t[n]||(r.push(n),t[n]=!0);return r}getSchemaURIsForResource(e,t){let r=t&&this.getSchemaFromProperty(e,t);return r?[r]:this.getAssociatedSchemas(e)}getSchemaForResource(e,t){if(t){let r=this.getSchemaFromProperty(e,t);if(r){let e=rB(r);return this.getOrAddSchemaHandle(e).getResolvedSchema()}}if(this.cachedSchemaForResource&&this.cachedSchemaForResource.resource===e)return this.cachedSchemaForResource.resolvedSchema;let r=this.getAssociatedSchemas(e),n=r.length>0?this.createCombinedSchema(e,r).getResolvedSchema():this.promise.resolve(void 0);return this.cachedSchemaForResource={resource:e,resolvedSchema:n},n}createCombinedSchema(e,t){if(1===t.length)return this.getOrAddSchemaHandle(t[0]);{let r="schemaservice://combinedSchema/"+encodeURIComponent(e),n={allOf:t.map(e=>({$ref:e}))};return this.addSchemaHandle(r,n)}}getMatchingSchemas(e,t,r){if(r){let e=r.id||"schemaservice://untitled/matchingSchemas/"+r7++;return this.addSchemaHandle(e,r).getResolvedSchema().then(e=>t.getMatchingSchemas(e.schema).filter(e=>!e.inverted))}return this.getSchemaForResource(e.uri,t).then(e=>e?t.getMatchingSchemas(e.schema).filter(e=>!e.inverted):[])}},r7=0;function r6(e){try{return rP.parse(e).with({fragment:null,query:null}).toString(!0)}catch(t){return e}}function r8(e){try{let t=rP.parse(e);if("file"===t.scheme)return t.fsPath}catch(e){}return e}var ne=class{constructor(e,t,r,n){this._uri=e,this._languageId=t,this._version=r,this._content=n,this._lineOffsets=void 0}get uri(){return this._uri}get languageId(){return this._languageId}get version(){return this._version}getText(e){if(e){let t=this.offsetAt(e.start),r=this.offsetAt(e.end);return this._content.substring(t,r)}return this._content}getLineOffsets(){return void 0===this._lineOffsets&&(this._lineOffsets=function(e,t,r=0){let n=t?[r]:[];for(let t=0;t<e.length;t++){let i=e.charCodeAt(t);nt(i)&&(13===i&&t+1<e.length&&10===e.charCodeAt(t+1)&&t++,n.push(r+t+1))}return n}(this._content,!0)),this._lineOffsets}positionAt(e){e=Math.max(Math.min(e,this._content.length),0);let t=this.getLineOffsets(),r=0,n=t.length;if(0===n)return{line:0,character:e};for(;r<n;){let i=Math.floor((r+n)/2);t[i]>e?n=i:r=i+1}let i=r-1;return e=this.ensureBeforeEOL(e,t[i]),{line:i,character:e-t[i]}}offsetAt(e){let t=this.getLineOffsets();if(e.line>=t.length)return this._content.length;if(e.line<0)return 0;let r=t[e.line];if(e.character<=0)return r;let n=e.line+1<t.length?t[e.line+1]:this._content.length,i=Math.min(r+e.character,n);return this.ensureBeforeEOL(i,r)}ensureBeforeEOL(e,t){for(;e>t&&nt(this._content.charCodeAt(e-1));)e--;return e}get lineCount(){return this.getLineOffsets().length}};function nt(e){return 13===e||10===e}var nr=class extends rn{constructor(e){super(e),this.setTimeout(500),this.service=function(e){let t=Promise,r=new r3(e.schemaRequestService,e.workspaceContext,t);r.setSchemaContributions(rY);let n=new rv(r,t);return{configure:e=>{var t;r.clearExternalSchemas(),null==(t=e.schemas)||t.forEach(r.registerExternalSchema.bind(r)),n.configure(e)},resetSchema:e=>r.onResourceChange(e),doValidation:n.doValidation.bind(n),getLanguageStatus:n.getLanguageStatus.bind(n),parseJSONDocument:e=>(function(e,t){let r,n=[],i=-1,s=e.getText(),a=rx(s,!1),o=t&&t.collectComments?[]:void 0;function l(){for(;;){let t=a.scan();switch(function(){switch(a.getTokenError()){case 4:return u(ru("Invalid unicode sequence in string."),tT.InvalidUnicode);case 5:return u(ru("Invalid escape character in string."),tT.InvalidEscapeCharacter);case 3:return u(ru("Unexpected end of number."),tT.UnexpectedEndOfNumber);case 1:return u(ru("Unexpected end of comment."),tT.UnexpectedEndOfComment);case 2:return u(ru("Unexpected end of string."),tT.UnexpectedEndOfString);case 6:return u(ru("Invalid characters in string. Control characters must be escaped."),tT.InvalidCharacter)}}(),t){case 12:case 13:Array.isArray(o)&&o.push(eb.create(e.positionAt(a.getTokenOffset()),e.positionAt(a.getTokenOffset()+a.getTokenLength())));break;case 15:case 14:break;default:return t}}}function c(t,r,s,a,o=eI.Error){if(0===n.length||s!==i){let l=eb.create(e.positionAt(s),e.positionAt(a));n.push(eT.create(l,t,o,r,e.languageId)),i=s}}function u(e,t,r,n=[],i=[]){let o=a.getTokenOffset(),h=a.getTokenOffset()+a.getTokenLength();if(o===h&&o>0){for(o--;o>0&&/\s/.test(s.charAt(o));)o--;h=o+1}if(c(e,t,o,h),r&&f(r,!1),n.length+i.length>0){let e=a.getToken();for(;17!==e;){if(-1!==n.indexOf(e)){l();break}if(-1!==i.indexOf(e))break;e=l()}}return r}function f(e,t){return e.length=a.getTokenOffset()+a.getTokenLength()-e.offset,t&&l(),e}let h=new rU(void 0,0,0);function d(e){if(10!==a.getToken())return;let t=new rU(e,a.getTokenOffset());return t.value=a.getTokenValue(),f(t,!0)}return 17!==l()&&((r=function t(r){return function(e){if(3!==a.getToken())return;let r=new rR(e,a.getTokenOffset());l();let n=!1;for(;4!==a.getToken()&&17!==a.getToken();){if(5===a.getToken()){n||u(ru("Value expected"),tT.ValueExpected);let e=a.getTokenOffset();if(l(),4===a.getToken()){n&&c(ru("Trailing comma"),tT.TrailingComma,e,e+1);continue}}else n&&u(ru("Expected comma"),tT.CommaExpected);let e=t(r);e?r.items.push(e):u(ru("Value expected"),tT.ValueExpected,void 0,[],[4,5]),n=!0}return 4!==a.getToken()?u(ru("Expected comma or closing bracket"),tT.CommaOrCloseBacketExpected,r):f(r,!0)}(r)||function(r){if(1!==a.getToken())return;let n=new rD(r,a.getTokenOffset()),i=Object.create(null);l();let s=!1;for(;2!==a.getToken()&&17!==a.getToken();){if(5===a.getToken()){s||u(ru("Property expected"),tT.PropertyExpected);let e=a.getTokenOffset();if(l(),2===a.getToken()){s&&c(ru("Trailing comma"),tT.TrailingComma,e,e+1);continue}}else s&&u(ru("Expected comma"),tT.CommaExpected);let r=function(r,n){let i=new rV(r,a.getTokenOffset(),h),s=d(i);if(!s)if(16!==a.getToken())return;else{u(ru("Property keys must be doublequoted"),tT.PropertyKeysMustBeDoublequoted);let e=new rU(i,a.getTokenOffset(),a.getTokenLength());e.value=a.getTokenValue(),s=e,l()}if(i.keyNode=s,"//"!==s.value){let e=n[s.value];e?(c(ru("Duplicate object key"),tT.DuplicateKey,i.keyNode.offset,i.keyNode.offset+i.keyNode.length,eI.Warning),ry(e)&&c(ru("Duplicate object key"),tT.DuplicateKey,e.keyNode.offset,e.keyNode.offset+e.keyNode.length,eI.Warning),n[s.value]=!0):n[s.value]=i}if(6===a.getToken())i.colonOffset=a.getTokenOffset(),l();else if(u(ru("Colon expected"),tT.ColonExpected),10===a.getToken()&&e.positionAt(s.offset+s.length).line<e.positionAt(a.getTokenOffset()).line)return i.length=s.length,i;let o=t(i);return o?(i.valueNode=o,i.length=o.offset+o.length-i.offset,i):u(ru("Value expected"),tT.ValueExpected,i,[],[2,5])}(n,i);r?n.properties.push(r):u(ru("Property expected"),tT.PropertyExpected,void 0,[],[2,5]),s=!0}return 2!==a.getToken()?u(ru("Expected comma or closing brace"),tT.CommaOrCloseBraceExpected,n):f(n,!0)}(r)||d(r)||function(e){if(11!==a.getToken())return;let t=new rN(e,a.getTokenOffset());if(0===a.getTokenError()){let e=a.getTokenValue();try{let r=JSON.parse(e);if(!rm(r))return u(ru("Invalid number format."),tT.Undefined,t);t.value=r}catch(e){return u(ru("Invalid number format."),tT.Undefined,t)}t.isInteger=-1===e.indexOf(".")}return f(t,!0)}(r)||function(e){switch(a.getToken()){case 7:return f(new rL(e,a.getTokenOffset()),!0);case 8:return f(new rj(e,!0,a.getTokenOffset()),!0);case 9:return f(new rj(e,!1,a.getTokenOffset()),!0);default:return}}(r)}(r))?17!==a.getToken()&&u(ru("End of file expected."),tT.Undefined):u(ru("Expected a JSON object, array or literal."),tT.Undefined)),new rX(r,n,o)})(e,{collectComments:!0}),getMatchingSchemas:r.getMatchingSchemas.bind(r)}}({schemaRequestService:e=>{},workspaceContext:{resolveRelativePath:(e,t)=>{}}}),this.$configureService()}$configureService(){this.service.configure({allowComments:this.allowComments,validate:!0})}setOptions(e){this.allowComments=e&&e.allowComments,this.trailingCommas=e&&e.trailingCommas,this.$configureService()}onUpdate(){let e,t;return e=this,t=function*(){var e,t=this.doc.getValue(),r=[],n=new ne("file:///foo.json","json",1,t);try{let t=this.service.parseJSONDocument(n);e=yield this.service.doValidation(n,t,{trailingCommas:this.trailingCommas?"ignore":"error"}),r=null==e?void 0:e.map(e=>({row:e.range.start.line,column:e.range.start.character,text:e.message,type:1===e.severity?"error":2===e.severity?"warning":"info",code:e.code,data:e.data}))}catch(e){console.error(e)}this.sender.emit("annotate",r)},new Promise((r,n)=>{var i=e=>{try{a(t.next(e))}catch(e){n(e)}},s=e=>{try{a(t.throw(e))}catch(e){n(e)}},a=e=>e.done?r(e.value):Promise.resolve(e.value).then(i,s);a((t=t.apply(e,null)).next())})}};return tX(tB({},"__esModule",{value:!0}),t5)})();t.JsonWorker=(n=n.default||n).JsonWorker});
|