(window.webpackJsonp=window.webpackJsonp||[]).push([[35],{7796:function(n,i,o){"use strict";o.r(i),o.d(i,"setupMode",(function(){return setupMode}));var a,s=o(1473),c=function(){function WorkerManager(n){var i=this;this._defaults=n,this._worker=null,this._idleCheckInterval=setInterval((function(){return i._checkIfIdle()}),3e4),this._lastUsedTime=0,this._configChangeListener=this._defaults.onDidChange((function(){return i._stopWorker()}))}return WorkerManager.prototype._stopWorker=function(){this._worker&&(this._worker.dispose(),this._worker=null),this._client=null},WorkerManager.prototype.dispose=function(){clearInterval(this._idleCheckInterval),this._configChangeListener.dispose(),this._stopWorker()},WorkerManager.prototype._checkIfIdle=function(){this._worker&&(Date.now()-this._lastUsedTime>12e4&&this._stopWorker())},WorkerManager.prototype._getClient=function(){return this._lastUsedTime=Date.now(),this._client||(this._worker=s.editor.createWebWorker({moduleId:"vs/language/json/jsonWorker",label:this._defaults.languageId,createData:{languageSettings:this._defaults.diagnosticsOptions,languageId:this._defaults.languageId,enableSchemaRequest:this._defaults.diagnosticsOptions.enableSchemaRequest}}),this._client=this._worker.getProxy()),this._client},WorkerManager.prototype.getLanguageServiceWorker=function(){for(var n,i=this,o=[],a=0;a=48&&u<=57)c=16*c+u-48;else if(u>=65&&u<=70)c=16*c+u-65+10;else{if(!(u>=97&&u<=102))break;c=16*c+u-97+10}a++,s++}return s=o)return c=o,u=17;var i=n.charCodeAt(a);if(isWhiteSpace(i)){do{a++,s+=String.fromCharCode(i),i=n.charCodeAt(a)}while(isWhiteSpace(i));return u=15}if(isLineBreak(i))return a++,s+=String.fromCharCode(i),13===i&&10===n.charCodeAt(a)&&(a++,s+="\n"),l++,h=a,u=14;switch(i){case 123:return a++,u=1;case 125:return a++,u=2;case 91:return a++,u=3;case 93:return a++,u=4;case 58:return a++,u=6;case 44:return a++,u=5;case 34:return a++,s=function scanString(){for(var i="",s=a;;){if(a>=o){i+=n.substring(s,a),p=2;break}var c=n.charCodeAt(a);if(34===c){i+=n.substring(s,a),a++;break}if(92!==c){if(c>=0&&c<=31){if(isLineBreak(c)){i+=n.substring(s,a),p=2;break}p=6}a++}else{if(i+=n.substring(s,a),++a>=o){p=2;break}switch(n.charCodeAt(a++)){case 34:i+='"';break;case 92:i+="\\";break;case 47:i+="/";break;case 98:i+="\b";break;case 102:i+="\f";break;case 110:i+="\n";break;case 114:i+="\r";break;case 116:i+="\t";break;case 117:var u=scanHexDigits(4,!0);u>=0?i+=String.fromCharCode(u):p=4;break;default:p=5}s=a}}return i}(),u=10;case 47:var m=a-1;if(47===n.charCodeAt(a+1)){for(a+=2;a=12&&n<=15);return n}:scanNext,getToken:function(){return u},getTokenValue:function(){return s},getTokenOffset:function(){return c},getTokenLength:function(){return a-c},getTokenStartLine:function(){return f},getTokenStartCharacter:function(){return c-d},getTokenError:function(){return p}}}function isWhiteSpace(n){return 32===n||9===n||11===n||12===n||160===n||5760===n||n>=8192&&n<=8203||8239===n||8287===n||12288===n||65279===n}function isLineBreak(n){return 10===n||13===n||8232===n||8233===n}function isDigit(n){return n>=48&&n<=57}function visit(n,i,o){void 0===o&&(o=a.DEFAULT);var s=createScanner(n,!1);function toNoArgVisit(n){return n?function(){return n(s.getTokenOffset(),s.getTokenLength(),s.getTokenStartLine(),s.getTokenStartCharacter())}:function(){return!0}}function toOneArgVisit(n){return n?function(i){return n(i,s.getTokenOffset(),s.getTokenLength(),s.getTokenStartLine(),s.getTokenStartCharacter())}:function(){return!0}}var c=toNoArgVisit(i.onObjectBegin),u=toOneArgVisit(i.onObjectProperty),l=toNoArgVisit(i.onObjectEnd),f=toNoArgVisit(i.onArrayBegin),h=toNoArgVisit(i.onArrayEnd),d=toOneArgVisit(i.onLiteralValue),p=toOneArgVisit(i.onSeparator),m=toNoArgVisit(i.onComment),g=toOneArgVisit(i.onError),v=o&&o.disallowComments,S=o&&o.allowTrailingComma;function scanNext(){for(;;){var n=s.scan();switch(s.getTokenError()){case 4:handleError(14);break;case 5:handleError(15);break;case 3:handleError(13);break;case 1:v||handleError(11);break;case 2:handleError(12);break;case 6:handleError(16)}switch(n){case 12:case 13:v?handleError(10):m();break;case 16:handleError(1);break;case 15:case 14:break;default:return n}}}function handleError(n,i,o){if(void 0===i&&(i=[]),void 0===o&&(o=[]),g(n),i.length+o.length>0)for(var a=s.getToken();17!==a;){if(-1!==i.indexOf(a)){scanNext();break}if(-1!==o.indexOf(a))break;a=scanNext()}}function parseString(n){var i=s.getTokenValue();return n?d(i):u(i),scanNext(),!0}function parseValue(){switch(s.getToken()){case 3:return function parseArray(){f(),scanNext();for(var n=!1;4!==s.getToken()&&17!==s.getToken();){if(5===s.getToken()){if(n||handleError(4,[],[]),p(","),scanNext(),4===s.getToken()&&S)break}else n&&handleError(6,[],[]);parseValue()||handleError(4,[],[4,5]),n=!0}return h(),4!==s.getToken()?handleError(8,[4],[]):scanNext(),!0}();case 1:return function parseObject(){c(),scanNext();for(var n=!1;2!==s.getToken()&&17!==s.getToken();){if(5===s.getToken()){if(n||handleError(4,[],[]),p(","),scanNext(),2===s.getToken()&&S)break}else n&&handleError(6,[],[]);(10!==s.getToken()?(handleError(3,[],[2,5]),0):(parseString(!1),6===s.getToken()?(p(":"),scanNext(),parseValue()||handleError(4,[],[2,5])):handleError(5,[],[2,5]),1))||handleError(4,[],[2,5]),n=!0}return l(),2!==s.getToken()?handleError(7,[2],[]):scanNext(),!0}();case 10:return parseString(!0);default:return function parseLiteral(){switch(s.getToken()){case 11:var n=s.getTokenValue(),i=Number(n);isNaN(i)&&(handleError(2),i=0),d(i);break;case 7:d(null);break;case 8:d(!0);break;case 9:d(!1);break;default:return!1}return scanNext(),!0}()}}return scanNext(),17===s.getToken()?!!o.allowEmptyContent||(handleError(4,[],[]),!1):parseValue()?(17!==s.getToken()&&handleError(9,[],[]),!0):(handleError(4,[],[]),!1)}!function(n){n.DEFAULT={allowTrailingComma:!1}}(a||(a={}));var u,l,f,h,d,p,m,g,v,S,k,O,N,T,E,I,P,_,M,D,V,F,R,L,$,W,J=createScanner,U=function parse(n,i,o){void 0===i&&(i=[]),void 0===o&&(o=a.DEFAULT);var s=null,c=[],u=[];function onValue(n){Array.isArray(c)?c.push(n):null!==s&&(c[s]=n)}return visit(n,{onObjectBegin:function(){var n={};onValue(n),u.push(c),c=n,s=null},onObjectProperty:function(n){s=n},onObjectEnd:function(){c=u.pop()},onArrayBegin:function(){var n=[];onValue(n),u.push(c),c=n,s=null},onArrayEnd:function(){c=u.pop()},onLiteralValue:onValue,onError:function(n,o,a){i.push({error:n,offset:o,length:a})}},o),c[0]},q=function findNodeAtOffset(n,i,o){if(void 0===o&&(o=!1),function contains(n,i,o){return void 0===o&&(o=!1),i>=n.offset&&i0?n.lastIndexOf(i)===o:0===o&&n===i}function extendedRegExp(n){return startsWith(n,"(?i)")?new RegExp(n.substring(4),"i"):new RegExp(n)}!function(n){n.MIN_VALUE=-2147483648,n.MAX_VALUE=2147483647}(u||(u={})),function(n){n.MIN_VALUE=0,n.MAX_VALUE=2147483647}(l||(l={})),function(n){n.create=function create(n,i){return n===Number.MAX_VALUE&&(n=l.MAX_VALUE),i===Number.MAX_VALUE&&(i=l.MAX_VALUE),{line:n,character:i}},n.is=function is(n){var i=n;return Oe.objectLiteral(i)&&Oe.uinteger(i.line)&&Oe.uinteger(i.character)}}(f||(f={})),function(n){n.create=function create(n,i,o,a){if(Oe.uinteger(n)&&Oe.uinteger(i)&&Oe.uinteger(o)&&Oe.uinteger(a))return{start:f.create(n,i),end:f.create(o,a)};if(f.is(n)&&f.is(i))return{start:n,end:i};throw new Error("Range#create called with invalid arguments["+n+", "+i+", "+o+", "+a+"]")},n.is=function is(n){var i=n;return Oe.objectLiteral(i)&&f.is(i.start)&&f.is(i.end)}}(h||(h={})),function(n){n.create=function create(n,i){return{uri:n,range:i}},n.is=function is(n){var i=n;return Oe.defined(i)&&h.is(i.range)&&(Oe.string(i.uri)||Oe.undefined(i.uri))}}(d||(d={})),function(n){n.create=function create(n,i,o,a){return{targetUri:n,targetRange:i,targetSelectionRange:o,originSelectionRange:a}},n.is=function is(n){var i=n;return Oe.defined(i)&&h.is(i.targetRange)&&Oe.string(i.targetUri)&&(h.is(i.targetSelectionRange)||Oe.undefined(i.targetSelectionRange))&&(h.is(i.originSelectionRange)||Oe.undefined(i.originSelectionRange))}}(p||(p={})),function(n){n.create=function create(n,i,o,a){return{red:n,green:i,blue:o,alpha:a}},n.is=function is(n){var i=n;return Oe.numberRange(i.red,0,1)&&Oe.numberRange(i.green,0,1)&&Oe.numberRange(i.blue,0,1)&&Oe.numberRange(i.alpha,0,1)}}(m||(m={})),function(n){n.create=function create(n,i){return{range:n,color:i}},n.is=function is(n){var i=n;return h.is(i.range)&&m.is(i.color)}}(g||(g={})),function(n){n.create=function create(n,i,o){return{label:n,textEdit:i,additionalTextEdits:o}},n.is=function is(n){var i=n;return Oe.string(i.label)&&(Oe.undefined(i.textEdit)||_.is(i))&&(Oe.undefined(i.additionalTextEdits)||Oe.typedArray(i.additionalTextEdits,_.is))}}(v||(v={})),function(n){n.Comment="comment",n.Imports="imports",n.Region="region"}(S||(S={})),function(n){n.create=function create(n,i,o,a,s){var c={startLine:n,endLine:i};return Oe.defined(o)&&(c.startCharacter=o),Oe.defined(a)&&(c.endCharacter=a),Oe.defined(s)&&(c.kind=s),c},n.is=function is(n){var i=n;return Oe.uinteger(i.startLine)&&Oe.uinteger(i.startLine)&&(Oe.undefined(i.startCharacter)||Oe.uinteger(i.startCharacter))&&(Oe.undefined(i.endCharacter)||Oe.uinteger(i.endCharacter))&&(Oe.undefined(i.kind)||Oe.string(i.kind))}}(k||(k={})),function(n){n.create=function create(n,i){return{location:n,message:i}},n.is=function is(n){var i=n;return Oe.defined(i)&&d.is(i.location)&&Oe.string(i.message)}}(O||(O={})),function(n){n.Error=1,n.Warning=2,n.Information=3,n.Hint=4}(N||(N={})),function(n){n.Unnecessary=1,n.Deprecated=2}(T||(T={})),function(n){n.is=function is(n){var i=n;return null!=i&&Oe.string(i.href)}}(E||(E={})),function(n){n.create=function create(n,i,o,a,s,c){var u={range:n,message:i};return Oe.defined(o)&&(u.severity=o),Oe.defined(a)&&(u.code=a),Oe.defined(s)&&(u.source=s),Oe.defined(c)&&(u.relatedInformation=c),u},n.is=function is(n){var i,o=n;return Oe.defined(o)&&h.is(o.range)&&Oe.string(o.message)&&(Oe.number(o.severity)||Oe.undefined(o.severity))&&(Oe.integer(o.code)||Oe.string(o.code)||Oe.undefined(o.code))&&(Oe.undefined(o.codeDescription)||Oe.string(null===(i=o.codeDescription)||void 0===i?void 0:i.href))&&(Oe.string(o.source)||Oe.undefined(o.source))&&(Oe.undefined(o.relatedInformation)||Oe.typedArray(o.relatedInformation,O.is))}}(I||(I={})),function(n){n.create=function create(n,i){for(var o=[],a=2;a0&&(s.arguments=o),s},n.is=function is(n){var i=n;return Oe.defined(i)&&Oe.string(i.title)&&Oe.string(i.command)}}(P||(P={})),function(n){n.replace=function replace(n,i){return{range:n,newText:i}},n.insert=function insert(n,i){return{range:{start:n,end:n},newText:i}},n.del=function del(n){return{range:n,newText:""}},n.is=function is(n){var i=n;return Oe.objectLiteral(i)&&Oe.string(i.newText)&&h.is(i.range)}}(_||(_={})),function(n){n.create=function create(n,i,o){var a={label:n};return void 0!==i&&(a.needsConfirmation=i),void 0!==o&&(a.description=o),a},n.is=function is(n){var i=n;return void 0!==i&&Oe.objectLiteral(i)&&Oe.string(i.label)&&(Oe.boolean(i.needsConfirmation)||void 0===i.needsConfirmation)&&(Oe.string(i.description)||void 0===i.description)}}(M||(M={})),function(n){n.is=function is(n){return"string"==typeof n}}(D||(D={})),function(n){n.replace=function replace(n,i,o){return{range:n,newText:i,annotationId:o}},n.insert=function insert(n,i,o){return{range:{start:n,end:n},newText:i,annotationId:o}},n.del=function del(n,i){return{range:n,newText:"",annotationId:i}},n.is=function is(n){var i=n;return _.is(i)&&(M.is(i.annotationId)||D.is(i.annotationId))}}(V||(V={})),function(n){n.create=function create(n,i){return{textDocument:n,edits:i}},n.is=function is(n){var i=n;return Oe.defined(i)&&G.is(i.textDocument)&&Array.isArray(i.edits)}}(F||(F={})),function(n){n.create=function create(n,i,o){var a={kind:"create",uri:n};return void 0===i||void 0===i.overwrite&&void 0===i.ignoreIfExists||(a.options=i),void 0!==o&&(a.annotationId=o),a},n.is=function is(n){var i=n;return i&&"create"===i.kind&&Oe.string(i.uri)&&(void 0===i.options||(void 0===i.options.overwrite||Oe.boolean(i.options.overwrite))&&(void 0===i.options.ignoreIfExists||Oe.boolean(i.options.ignoreIfExists)))&&(void 0===i.annotationId||D.is(i.annotationId))}}(R||(R={})),function(n){n.create=function create(n,i,o,a){var s={kind:"rename",oldUri:n,newUri:i};return void 0===o||void 0===o.overwrite&&void 0===o.ignoreIfExists||(s.options=o),void 0!==a&&(s.annotationId=a),s},n.is=function is(n){var i=n;return i&&"rename"===i.kind&&Oe.string(i.oldUri)&&Oe.string(i.newUri)&&(void 0===i.options||(void 0===i.options.overwrite||Oe.boolean(i.options.overwrite))&&(void 0===i.options.ignoreIfExists||Oe.boolean(i.options.ignoreIfExists)))&&(void 0===i.annotationId||D.is(i.annotationId))}}(L||(L={})),function(n){n.create=function create(n,i,o){var a={kind:"delete",uri:n};return void 0===i||void 0===i.recursive&&void 0===i.ignoreIfNotExists||(a.options=i),void 0!==o&&(a.annotationId=o),a},n.is=function is(n){var i=n;return i&&"delete"===i.kind&&Oe.string(i.uri)&&(void 0===i.options||(void 0===i.options.recursive||Oe.boolean(i.options.recursive))&&(void 0===i.options.ignoreIfNotExists||Oe.boolean(i.options.ignoreIfNotExists)))&&(void 0===i.annotationId||D.is(i.annotationId))}}($||($={})),function(n){n.is=function is(n){var i=n;return i&&(void 0!==i.changes||void 0!==i.documentChanges)&&(void 0===i.documentChanges||i.documentChanges.every((function(n){return Oe.string(n.kind)?R.is(n)||L.is(n)||$.is(n):F.is(n)})))}}(W||(W={}));var z,K,G,X,Z,Q,Y,ee,te,ne,re,ie,oe,ae,se,ce,ue,le,fe,he,de,pe,me,ge,ve,ye,be,Se,xe,Ae,Ce=function(){function TextEditChangeImpl(n,i){this.edits=n,this.changeAnnotations=i}return TextEditChangeImpl.prototype.insert=function(n,i,o){var a,s;if(void 0===o?a=_.insert(n,i):D.is(o)?(s=o,a=V.insert(n,i,o)):(this.assertChangeAnnotations(this.changeAnnotations),s=this.changeAnnotations.manage(o),a=V.insert(n,i,s)),this.edits.push(a),void 0!==s)return s},TextEditChangeImpl.prototype.replace=function(n,i,o){var a,s;if(void 0===o?a=_.replace(n,i):D.is(o)?(s=o,a=V.replace(n,i,o)):(this.assertChangeAnnotations(this.changeAnnotations),s=this.changeAnnotations.manage(o),a=V.replace(n,i,s)),this.edits.push(a),void 0!==s)return s},TextEditChangeImpl.prototype.delete=function(n,i){var o,a;if(void 0===i?o=_.del(n):D.is(i)?(a=i,o=V.del(n,i)):(this.assertChangeAnnotations(this.changeAnnotations),a=this.changeAnnotations.manage(i),o=V.del(n,a)),this.edits.push(o),void 0!==a)return a},TextEditChangeImpl.prototype.add=function(n){this.edits.push(n)},TextEditChangeImpl.prototype.all=function(){return this.edits},TextEditChangeImpl.prototype.clear=function(){this.edits.splice(0,this.edits.length)},TextEditChangeImpl.prototype.assertChangeAnnotations=function(n){if(void 0===n)throw new Error("Text edit change is not configured to manage change annotations.")},TextEditChangeImpl}(),ke=function(){function ChangeAnnotations(n){this._annotations=void 0===n?Object.create(null):n,this._counter=0,this._size=0}return ChangeAnnotations.prototype.all=function(){return this._annotations},Object.defineProperty(ChangeAnnotations.prototype,"size",{get:function(){return this._size},enumerable:!1,configurable:!0}),ChangeAnnotations.prototype.manage=function(n,i){var o;if(D.is(n)?o=n:(o=this.nextId(),i=n),void 0!==this._annotations[o])throw new Error("Id "+o+" is already in use.");if(void 0===i)throw new Error("No annotation provided for id "+o);return this._annotations[o]=i,this._size++,o},ChangeAnnotations.prototype.nextId=function(){return this._counter++,this._counter.toString()},ChangeAnnotations}();!function(){function WorkspaceChange(n){var i=this;this._textEditChanges=Object.create(null),void 0!==n?(this._workspaceEdit=n,n.documentChanges?(this._changeAnnotations=new ke(n.changeAnnotations),n.changeAnnotations=this._changeAnnotations.all(),n.documentChanges.forEach((function(n){if(F.is(n)){var o=new Ce(n.edits,i._changeAnnotations);i._textEditChanges[n.textDocument.uri]=o}}))):n.changes&&Object.keys(n.changes).forEach((function(o){var a=new Ce(n.changes[o]);i._textEditChanges[o]=a}))):this._workspaceEdit={}}Object.defineProperty(WorkspaceChange.prototype,"edit",{get:function(){return this.initDocumentChanges(),void 0!==this._changeAnnotations&&(0===this._changeAnnotations.size?this._workspaceEdit.changeAnnotations=void 0:this._workspaceEdit.changeAnnotations=this._changeAnnotations.all()),this._workspaceEdit},enumerable:!1,configurable:!0}),WorkspaceChange.prototype.getTextEditChange=function(n){if(G.is(n)){if(this.initDocumentChanges(),void 0===this._workspaceEdit.documentChanges)throw new Error("Workspace edit is not configured for document changes.");var i={uri:n.uri,version:n.version};if(!(a=this._textEditChanges[i.uri])){var o={textDocument:i,edits:s=[]};this._workspaceEdit.documentChanges.push(o),a=new Ce(s,this._changeAnnotations),this._textEditChanges[i.uri]=a}return a}if(this.initChanges(),void 0===this._workspaceEdit.changes)throw new Error("Workspace edit is not configured for normal text edit changes.");var a;if(!(a=this._textEditChanges[n])){var s=[];this._workspaceEdit.changes[n]=s,a=new Ce(s),this._textEditChanges[n]=a}return a},WorkspaceChange.prototype.initDocumentChanges=function(){void 0===this._workspaceEdit.documentChanges&&void 0===this._workspaceEdit.changes&&(this._changeAnnotations=new ke,this._workspaceEdit.documentChanges=[],this._workspaceEdit.changeAnnotations=this._changeAnnotations.all())},WorkspaceChange.prototype.initChanges=function(){void 0===this._workspaceEdit.documentChanges&&void 0===this._workspaceEdit.changes&&(this._workspaceEdit.changes=Object.create(null))},WorkspaceChange.prototype.createFile=function(n,i,o){if(this.initDocumentChanges(),void 0===this._workspaceEdit.documentChanges)throw new Error("Workspace edit is not configured for document changes.");var a,s,c;if(M.is(i)||D.is(i)?a=i:o=i,void 0===a?s=R.create(n,o):(c=D.is(a)?a:this._changeAnnotations.manage(a),s=R.create(n,o,c)),this._workspaceEdit.documentChanges.push(s),void 0!==c)return c},WorkspaceChange.prototype.renameFile=function(n,i,o,a){if(this.initDocumentChanges(),void 0===this._workspaceEdit.documentChanges)throw new Error("Workspace edit is not configured for document changes.");var s,c,u;if(M.is(o)||D.is(o)?s=o:a=o,void 0===s?c=L.create(n,i,a):(u=D.is(s)?s:this._changeAnnotations.manage(s),c=L.create(n,i,a,u)),this._workspaceEdit.documentChanges.push(c),void 0!==u)return u},WorkspaceChange.prototype.deleteFile=function(n,i,o){if(this.initDocumentChanges(),void 0===this._workspaceEdit.documentChanges)throw new Error("Workspace edit is not configured for document changes.");var a,s,c;if(M.is(i)||D.is(i)?a=i:o=i,void 0===a?s=$.create(n,o):(c=D.is(a)?a:this._changeAnnotations.manage(a),s=$.create(n,o,c)),this._workspaceEdit.documentChanges.push(s),void 0!==c)return c}}();!function(n){n.create=function create(n){return{uri:n}},n.is=function is(n){var i=n;return Oe.defined(i)&&Oe.string(i.uri)}}(z||(z={})),function(n){n.create=function create(n,i){return{uri:n,version:i}},n.is=function is(n){var i=n;return Oe.defined(i)&&Oe.string(i.uri)&&Oe.integer(i.version)}}(K||(K={})),function(n){n.create=function create(n,i){return{uri:n,version:i}},n.is=function is(n){var i=n;return Oe.defined(i)&&Oe.string(i.uri)&&(null===i.version||Oe.integer(i.version))}}(G||(G={})),function(n){n.create=function create(n,i,o,a){return{uri:n,languageId:i,version:o,text:a}},n.is=function is(n){var i=n;return Oe.defined(i)&&Oe.string(i.uri)&&Oe.string(i.languageId)&&Oe.integer(i.version)&&Oe.string(i.text)}}(X||(X={})),function(n){n.PlainText="plaintext",n.Markdown="markdown"}(Z||(Z={})),function(n){n.is=function is(i){var o=i;return o===n.PlainText||o===n.Markdown}}(Z||(Z={})),function(n){n.is=function is(n){var i=n;return Oe.objectLiteral(n)&&Z.is(i.kind)&&Oe.string(i.value)}}(Q||(Q={})),function(n){n.Text=1,n.Method=2,n.Function=3,n.Constructor=4,n.Field=5,n.Variable=6,n.Class=7,n.Interface=8,n.Module=9,n.Property=10,n.Unit=11,n.Value=12,n.Enum=13,n.Keyword=14,n.Snippet=15,n.Color=16,n.File=17,n.Reference=18,n.Folder=19,n.EnumMember=20,n.Constant=21,n.Struct=22,n.Event=23,n.Operator=24,n.TypeParameter=25}(Y||(Y={})),function(n){n.PlainText=1,n.Snippet=2}(ee||(ee={})),function(n){n.Deprecated=1}(te||(te={})),function(n){n.create=function create(n,i,o){return{newText:n,insert:i,replace:o}},n.is=function is(n){var i=n;return i&&Oe.string(i.newText)&&h.is(i.insert)&&h.is(i.replace)}}(ne||(ne={})),function(n){n.asIs=1,n.adjustIndentation=2}(re||(re={})),function(n){n.create=function create(n){return{label:n}}}(ie||(ie={})),function(n){n.create=function create(n,i){return{items:n||[],isIncomplete:!!i}}}(oe||(oe={})),function(n){n.fromPlainText=function fromPlainText(n){return n.replace(/[\\`*_{}[\]()#+\-.!]/g,"\\$&")},n.is=function is(n){var i=n;return Oe.string(i)||Oe.objectLiteral(i)&&Oe.string(i.language)&&Oe.string(i.value)}}(ae||(ae={})),function(n){n.is=function is(n){var i=n;return!!i&&Oe.objectLiteral(i)&&(Q.is(i.contents)||ae.is(i.contents)||Oe.typedArray(i.contents,ae.is))&&(void 0===n.range||h.is(n.range))}}(se||(se={})),function(n){n.create=function create(n,i){return i?{label:n,documentation:i}:{label:n}}}(ce||(ce={})),function(n){n.create=function create(n,i){for(var o=[],a=2;a=0;c--){var u=a[c],l=n.offsetAt(u.range.start),f=n.offsetAt(u.range.end);if(!(f<=s))throw new Error("Overlapping edit");o=o.substring(0,l)+u.newText+o.substring(f,o.length),s=l}return o}}(we||(we={}));var Oe,Ne=function(){function FullTextDocument(n,i,o,a){this._uri=n,this._languageId=i,this._version=o,this._content=a,this._lineOffsets=void 0}return Object.defineProperty(FullTextDocument.prototype,"uri",{get:function(){return this._uri},enumerable:!1,configurable:!0}),Object.defineProperty(FullTextDocument.prototype,"languageId",{get:function(){return this._languageId},enumerable:!1,configurable:!0}),Object.defineProperty(FullTextDocument.prototype,"version",{get:function(){return this._version},enumerable:!1,configurable:!0}),FullTextDocument.prototype.getText=function(n){if(n){var i=this.offsetAt(n.start),o=this.offsetAt(n.end);return this._content.substring(i,o)}return this._content},FullTextDocument.prototype.update=function(n,i){this._content=n.text,this._version=i,this._lineOffsets=void 0},FullTextDocument.prototype.getLineOffsets=function(){if(void 0===this._lineOffsets){for(var n=[],i=this._content,o=!0,a=0;a0&&n.push(i.length),this._lineOffsets=n}return this._lineOffsets},FullTextDocument.prototype.positionAt=function(n){n=Math.max(Math.min(n,this._content.length),0);var i=this.getLineOffsets(),o=0,a=i.length;if(0===a)return f.create(0,n);for(;on?a=s:o=s+1}var c=o-1;return f.create(c,n-i[c])},FullTextDocument.prototype.offsetAt=function(n){var i=this.getLineOffsets();if(n.line>=i.length)return this._content.length;if(n.line<0)return 0;var o=i[n.line],a=n.line+1n?a=s:o=s+1}var c=o-1;return{line:c,character:n-i[c]}},FullTextDocument.prototype.offsetAt=function(n){var i=this.getLineOffsets();if(n.line>=i.length)return this._content.length;if(n.line<0)return 0;var o=i[n.line],a=n.line+1o.line||i.line===o.line&&i.character>o.character?{start:o,end:i}:n}function getWellformedEdit(n){var i=getWellformedRange(n.range);return i!==n.range?{newText:n.newText,range:i}:n}function vscode_nls_format(n,i){return 0===i.length?n:n.replace(/\{(\d+)\}/g,(function(n,o){var a=o[0];return void 0!==i[a]?i[a]:n}))}function localize(n,i){for(var o=[],a=2;aa&&s.push(o.substring(a,f)),l.newText.length&&s.push(l.newText),a=n.offsetAt(l.range.end)}return s.push(o.substr(a)),s.join("")}}(Te||(Te={})),function(n){n[n.Undefined=0]="Undefined",n[n.EnumValueMismatch=1]="EnumValueMismatch",n[n.Deprecated=2]="Deprecated",n[n.UnexpectedEndOfComment=257]="UnexpectedEndOfComment",n[n.UnexpectedEndOfString=258]="UnexpectedEndOfString",n[n.UnexpectedEndOfNumber=259]="UnexpectedEndOfNumber",n[n.InvalidUnicode=260]="InvalidUnicode",n[n.InvalidEscapeCharacter=261]="InvalidEscapeCharacter",n[n.InvalidCharacter=262]="InvalidCharacter",n[n.PropertyExpected=513]="PropertyExpected",n[n.CommaExpected=514]="CommaExpected",n[n.ColonExpected=515]="ColonExpected",n[n.ValueExpected=516]="ValueExpected",n[n.CommaOrCloseBacketExpected=517]="CommaOrCloseBacketExpected",n[n.CommaOrCloseBraceExpected=518]="CommaOrCloseBraceExpected",n[n.TrailingComma=519]="TrailingComma",n[n.DuplicateKey=520]="DuplicateKey",n[n.CommentNotPermitted=521]="CommentNotPermitted",n[n.SchemaResolveError=768]="SchemaResolveError"}(Ee||(Ee={})),(Ie||(Ie={})).LATEST={textDocument:{completion:{completionItem:{documentationFormat:[Z.Markdown,Z.PlainText],commitCharactersSupport:!0}}}};var Pe,_e,Me=(Pe=function(n,i){return(Pe=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,i){n.__proto__=i}||function(n,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(n[o]=i[o])})(n,i)},function(n,i){if("function"!=typeof i&&null!==i)throw new TypeError("Class extends value "+String(i)+" is not a constructor or null");function __(){this.constructor=n}Pe(n,i),n.prototype=null===i?Object.create(i):(__.prototype=i.prototype,new __)}),De=loadMessageBundle(),Ve={"color-hex":{errorMessage:De("colorHexFormatWarning","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:De("dateTimeFormatWarning","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:De("dateFormatWarning","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:De("timeFormatWarning","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:De("emailFormatWarning","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-Z\-0-9]+\.)+[a-zA-Z]{2,}))$/}},Fe=function(){function ASTNodeImpl(n,i,o){void 0===o&&(o=0),this.offset=i,this.length=o,this.parent=n}return Object.defineProperty(ASTNodeImpl.prototype,"children",{get:function(){return[]},enumerable:!1,configurable:!0}),ASTNodeImpl.prototype.toString=function(){return"type: "+this.type+" ("+this.offset+"/"+this.length+")"+(this.parent?" parent: {"+this.parent.toString()+"}":"")},ASTNodeImpl}();(function(n){function NullASTNodeImpl(i,o){var a=n.call(this,i,o)||this;return a.type="null",a.value=null,a}Me(NullASTNodeImpl,n)})(Fe),function(n){function BooleanASTNodeImpl(i,o,a){var s=n.call(this,i,a)||this;return s.type="boolean",s.value=o,s}Me(BooleanASTNodeImpl,n)}(Fe),function(n){function ArrayASTNodeImpl(i,o){var a=n.call(this,i,o)||this;return a.type="array",a.items=[],a}Me(ArrayASTNodeImpl,n),Object.defineProperty(ArrayASTNodeImpl.prototype,"children",{get:function(){return this.items},enumerable:!1,configurable:!0})}(Fe),function(n){function NumberASTNodeImpl(i,o){var a=n.call(this,i,o)||this;return a.type="number",a.isInteger=!0,a.value=Number.NaN,a}Me(NumberASTNodeImpl,n)}(Fe),function(n){function StringASTNodeImpl(i,o,a){var s=n.call(this,i,o,a)||this;return s.type="string",s.value="",s}Me(StringASTNodeImpl,n)}(Fe),function(n){function PropertyASTNodeImpl(i,o,a){var s=n.call(this,i,o)||this;return s.type="property",s.colonOffset=-1,s.keyNode=a,s}Me(PropertyASTNodeImpl,n),Object.defineProperty(PropertyASTNodeImpl.prototype,"children",{get:function(){return this.valueNode?[this.keyNode,this.valueNode]:[this.keyNode]},enumerable:!1,configurable:!0})}(Fe),function(n){function ObjectASTNodeImpl(i,o){var a=n.call(this,i,o)||this;return a.type="object",a.properties=[],a}Me(ObjectASTNodeImpl,n),Object.defineProperty(ObjectASTNodeImpl.prototype,"children",{get:function(){return this.properties},enumerable:!1,configurable:!0})}(Fe);function asSchema(n){return isBoolean(n)?n?{}:{not:{}}:n}!function(n){n[n.Key=0]="Key",n[n.Enum=1]="Enum"}(_e||(_e={}));var Re=function(){function SchemaCollector(n,i){void 0===n&&(n=-1),this.focusOffset=n,this.exclude=i,this.schemas=[]}return SchemaCollector.prototype.add=function(n){this.schemas.push(n)},SchemaCollector.prototype.merge=function(n){Array.prototype.push.apply(this.schemas,n.schemas)},SchemaCollector.prototype.include=function(n){return(-1===this.focusOffset||jsonParser_contains(n,this.focusOffset))&&n!==this.exclude},SchemaCollector.prototype.newSub=function(){return new SchemaCollector(-1,this.exclude)},SchemaCollector}(),Le=function(){function NoOpSchemaCollector(){}return Object.defineProperty(NoOpSchemaCollector.prototype,"schemas",{get:function(){return[]},enumerable:!1,configurable:!0}),NoOpSchemaCollector.prototype.add=function(n){},NoOpSchemaCollector.prototype.merge=function(n){},NoOpSchemaCollector.prototype.include=function(n){return!0},NoOpSchemaCollector.prototype.newSub=function(){return this},NoOpSchemaCollector.instance=new NoOpSchemaCollector,NoOpSchemaCollector}(),$e=function(){function ValidationResult(){this.problems=[],this.propertiesMatches=0,this.propertiesValueMatches=0,this.primaryValueMatches=0,this.enumValueMatch=!1,this.enumValues=void 0}return ValidationResult.prototype.hasProblems=function(){return!!this.problems.length},ValidationResult.prototype.mergeAll=function(n){for(var i=0,o=n;i=n.offset&&i=0;)c.splice(i,1),i=c.indexOf(n)};if(i.properties)for(var v=0,S=Object.keys(i.properties);v0)for(var F=0,R=c;Fi.maxProperties&&o.problems.push({location:{offset:n.offset,length:n.length},message:De("MaxPropWarning","Object has more properties than limit of {0}.",i.maxProperties)});isNumber(i.minProperties)&&n.properties.length=s.length&&o.propertiesValueMatches++}if(n.items.length>s.length)if("object"==typeof i.additionalItems)for(var f=s.length;fi.maxItems&&o.problems.push({location:{offset:n.offset,length:n.length},message:De("maxItemsWarning","Array has too many items. Expected {0} or fewer.",i.maxItems)});if(!0===i.uniqueItems){var v=jsonParser_getNodeValue(n);v.some((function(n,i){return i!==v.lastIndexOf(n)}))&&o.problems.push({location:{offset:n.offset,length:n.length},message:De("uniqueItemsWarning","Array has duplicate items.")})}}(s,i,o,a);break;case"string":!function _validateStringNode(n,i,o,a){isNumber(i.minLength)&&n.value.lengthi.maxLength&&o.problems.push({location:{offset:n.offset,length:n.length},message:De("maxLengthWarning","String is longer than the maximum length of {0}.",i.maxLength)});if(function isString(n){return"string"==typeof n}(i.pattern)){extendedRegExp(i.pattern).test(n.value)||o.problems.push({location:{offset:n.offset,length:n.length},message:i.patternErrorMessage||i.errorMessage||De("patternWarning",'String does not match the pattern of "{0}".',i.pattern)})}if(i.format)switch(i.format){case"uri":case"uri-reference":var s=void 0;if(n.value){var c=/^(([^:/?#]+?):)?(\/\/([^/?#]*))?([^?#]*)(\?([^#]*))?(#(.*))?/.exec(n.value);c?c[2]||"uri"!==i.format||(s=De("uriSchemeMissing","URI with a scheme is expected.")):s=De("uriMissing","URI is expected.")}else s=De("uriEmpty","URI expected.");s&&o.problems.push({location:{offset:n.offset,length:n.length},message:i.patternErrorMessage||i.errorMessage||De("uriFormatWarning","String is not a URI: {0}",s)});break;case"color-hex":case"date-time":case"date":case"time":case"email":var u=Ve[i.format];n.value&&u.pattern.exec(n.value)||o.problems.push({location:{offset:n.offset,length:n.length},message:i.patternErrorMessage||i.errorMessage||u.errorMessage})}}(s,i,o);break;case"number":!function _validateNumberNode(n,i,o,a){var s=n.value;function normalizeFloats(n){var i,o=/^(-?\d+)(?:\.(\d+))?(?:e([-+]\d+))?$/.exec(n.toString());return o&&{value:Number(o[1]+(o[2]||"")),multiplier:((null===(i=o[2])||void 0===i?void 0:i.length)||0)-(parseInt(o[3])||0)}}if(isNumber(i.multipleOf)){var c=-1;if(Number.isInteger(i.multipleOf))c=s%i.multipleOf;else{var u=normalizeFloats(i.multipleOf),l=normalizeFloats(s);if(u&&l){var f=Math.pow(10,Math.abs(l.multiplier-u.multiplier));l.multiplier=d&&o.problems.push({location:{offset:n.offset,length:n.length},message:De("exclusiveMaximumWarning","Value is above the exclusive maximum of {0}.",d)});var p=getLimit(i.minimum,i.exclusiveMinimum);isNumber(p)&&sm&&o.problems.push({location:{offset:n.offset,length:n.length},message:De("maximumWarning","Value is above the maximum of {0}.",m)})}(s,i,o);break;case"property":return validate(s.valueNode,i,o,a)}!function _validateNode(){function matchesType(n){return s.type===n||"integer"===n&&"number"===s.type&&s.isInteger}Array.isArray(i.type)?i.type.some(matchesType)||o.problems.push({location:{offset:s.offset,length:s.length},message:i.errorMessage||De("typeArrayMismatchWarning","Incorrect type. Expected one of {0}.",i.type.join(", "))}):i.type&&(matchesType(i.type)||o.problems.push({location:{offset:s.offset,length:s.length},message:i.errorMessage||De("typeMismatchWarning",'Incorrect type. Expected "{0}".',i.type)}));if(Array.isArray(i.allOf))for(var n=0,c=i.allOf;n0?u={schema:h,validationResult:d,matchingSchemas:p}:0===m&&(u.matchingSchemas.merge(p),u.validationResult.mergeEnumValues(d))}else u.matchingSchemas.merge(p),u.validationResult.propertiesMatches+=d.propertiesMatches,u.validationResult.propertiesValueMatches+=d.propertiesValueMatches;else u={schema:h,validationResult:d,matchingSchemas:p}}return c.length>1&&i&&o.problems.push({location:{offset:s.offset,length:1},message:De("oneOfWarning","Matches multiple schemas when only one must validate.")}),u&&(o.merge(u.validationResult),o.propertiesMatches+=u.validationResult.propertiesMatches,o.propertiesValueMatches+=u.validationResult.propertiesValueMatches,a.merge(u.matchingSchemas)),c.length};Array.isArray(i.anyOf)&&testAlternatives(i.anyOf,!1);Array.isArray(i.oneOf)&&testAlternatives(i.oneOf,!0);var testBranch=function(n){var i=new $e,c=a.newSub();validate(s,asSchema(n),i,c),o.merge(i),o.propertiesMatches+=i.propertiesMatches,o.propertiesValueMatches+=i.propertiesValueMatches,a.merge(c)},g=asSchema(i.if);g&&function(n,i,o){var c=asSchema(n),u=new $e,l=a.newSub();validate(s,c,u,l),a.merge(l),u.hasProblems()?o&&testBranch(o):i&&testBranch(i)}(g,asSchema(i.then),asSchema(i.else));if(Array.isArray(i.enum)){for(var v=jsonParser_getNodeValue(s),S=!1,k=0,O=i.enum;k=0;i--){var o=this.contributions[i].resolveCompletion;if(o){var a=o(n);if(a)return a}}return this.promiseConstructor.resolve(n)},JSONCompletion.prototype.doComplete=function(n,i,o){var a=this,s={items:[],isIncomplete:!1},c=n.getText(),u=n.offsetAt(i),l=o.getNodeFromOffset(u,!0);if(this.isInComment(n,l?l.offset:0,u))return Promise.resolve(s);if(l&&u===l.offset+l.length&&u>0){var f=c[u-1];("object"===l.type&&"}"===f||"array"===l.type&&"]"===f)&&(l=l.parent)}var d,p=this.getCurrentWord(n,u);if(!l||"string"!==l.type&&"number"!==l.type&&"boolean"!==l.type&&"null"!==l.type){var m=u-p.length;m>0&&'"'===c[m-1]&&m--,d=h.create(n.positionAt(m),i)}else d=h.create(n.positionAt(l.offset),n.positionAt(l.offset+l.length));var g={},v={add:function(n){var i=n.label,o=g[i];if(o)o.documentation||(o.documentation=n.documentation),o.detail||(o.detail=n.detail);else{if((i=i.replace(/[\n]/g,"↵")).length>60){var a=i.substr(0,57).trim()+"...";g[a]||(i=a)}d&&void 0!==n.insertText&&(n.textEdit=_.replace(d,n.insertText)),n.label=i,g[i]=n,s.items.push(n)}},setAsIncomplete:function(){s.isIncomplete=!0},error:function(n){console.error(n)},log:function(n){console.log(n)},getNumberOfProposals:function(){return s.items.length}};return this.schemaService.getSchemaForResource(n.uri,o).then((function(i){var f=[],h=!0,m="",S=void 0;if(l&&"string"===l.type){var k=l.parent;k&&"property"===k.type&&k.keyNode===l&&(h=!k.valueNode,S=k,m=c.substr(l.offset+1,l.length-2),k&&(l=k.parent))}if(l&&"object"===l.type){if(l.offset===u)return s;l.properties.forEach((function(n){S&&S===n||(g[n.keyNode.value]=ie.create("__"))}));var O="";h&&(O=a.evaluateSeparatorAfter(n,n.offsetAt(d.end))),i?a.getPropertyCompletions(i,o,l,h,O,v):a.getSchemaLessPropertyCompletions(o,l,m,v);var N=jsonParser_getNodePath(l);a.contributions.forEach((function(i){var o=i.collectPropertyCompletions(n.uri,N,p,h,""===O,v);o&&f.push(o)})),!i&&p.length>0&&'"'!==c.charAt(u-p.length-1)&&(v.add({kind:Y.Property,label:a.getLabelForValue(p),insertText:a.getInsertTextForProperty(p,void 0,!1,O),insertTextFormat:ee.Snippet,documentation:""}),v.setAsIncomplete())}var T={};return i?a.getValueCompletions(i,o,l,u,n,v,T):a.getSchemaLessValueCompletions(o,l,u,n,v),a.contributions.length>0&&a.getContributedValueCompletions(o,l,u,n,v,f),a.promiseConstructor.all(f).then((function(){if(0===v.getNumberOfProposals()){var i=u;!l||"string"!==l.type&&"number"!==l.type&&"boolean"!==l.type&&"null"!==l.type||(i=l.offset+l.length);var o=a.evaluateSeparatorAfter(n,i);a.addFillerValueCompletions(T,o,v)}return s}))}))},JSONCompletion.prototype.getPropertyCompletions=function(n,i,o,a,s,c){var u=this;i.getMatchingSchemas(n.schema,o.offset).forEach((function(n){if(n.node===o&&!n.inverted){var i=n.schema.properties;i&&Object.keys(i).forEach((function(n){var o=i[n];if("object"==typeof o&&!o.deprecationMessage&&!o.doNotSuggest){var l={kind:Y.Property,label:n,insertText:u.getInsertTextForProperty(n,o,a,s),insertTextFormat:ee.Snippet,filterText:u.getFilterTextForValue(n),documentation:u.fromMarkup(o.markdownDescription)||o.description||""};void 0!==o.suggestSortText&&(l.sortText=o.suggestSortText),l.insertText&&endsWith(l.insertText,"$1"+s)&&(l.command={title:"Suggest",command:"editor.action.triggerSuggest"}),c.add(l)}}));var l=n.schema.propertyNames;if("object"==typeof l&&!l.deprecationMessage&&!l.doNotSuggest){var propertyNameCompletionItem=function(n,i){void 0===i&&(i=void 0);var o={kind:Y.Property,label:n,insertText:u.getInsertTextForProperty(n,void 0,a,s),insertTextFormat:ee.Snippet,filterText:u.getFilterTextForValue(n),documentation:i||u.fromMarkup(l.markdownDescription)||l.description||""};void 0!==l.suggestSortText&&(o.sortText=l.suggestSortText),o.insertText&&endsWith(o.insertText,"$1"+s)&&(o.command={title:"Suggest",command:"editor.action.triggerSuggest"}),c.add(o)};if(l.enum)for(var f=0;f(i.colonOffset||0)){var f=i.valueNode;if(f&&(o>f.offset+f.length||"object"===f.type||"array"===f.type))return;var h=i.keyNode.value;n.visit((function(n){return"property"===n.type&&n.keyNode.value===h&&n.valueNode&&collectSuggestionsForValues(n.valueNode),!0})),"$schema"===h&&i.parent&&!i.parent.parent&&this.addDollarSchemaCompletions(l,s)}if("array"===i.type)if(i.parent&&"property"===i.parent.type){var d=i.parent.keyNode.value;n.visit((function(n){return"property"===n.type&&n.keyNode.value===d&&n.valueNode&&"array"===n.valueNode.type&&n.valueNode.items.forEach(collectSuggestionsForValues),!0}))}else i.items.forEach(collectSuggestionsForValues)},JSONCompletion.prototype.getValueCompletions=function(n,i,o,a,s,c,u){var l=a,f=void 0,h=void 0;if(!o||"string"!==o.type&&"number"!==o.type&&"boolean"!==o.type&&"null"!==o.type||(l=o.offset+o.length,h=o,o=o.parent),o){if("property"===o.type&&a>(o.colonOffset||0)){var d=o.valueNode;if(d&&a>d.offset+d.length)return;f=o.keyNode.value,o=o.parent}if(o&&(void 0!==f||"array"===o.type)){for(var p=this.evaluateSeparatorAfter(s,l),m=0,g=i.getMatchingSchemas(n.schema,o.offset,h);m(i.colonOffset||0)){var u=i.keyNode.value,l=i.valueNode;if((!l||o<=l.offset+l.length)&&i.parent){var f=jsonParser_getNodePath(i.parent);this.contributions.forEach((function(n){var i=n.collectValueCompletions(a.uri,f,u,s);i&&c.push(i)}))}}}else this.contributions.forEach((function(n){var i=n.collectDefaultCompletions(a.uri,s);i&&c.push(i)}))},JSONCompletion.prototype.addSchemaValueCompletions=function(n,i,o,a){var s=this;"object"==typeof n&&(this.addEnumValueCompletions(n,i,o),this.addDefaultValueCompletions(n,i,o),this.collectTypes(n,a),Array.isArray(n.allOf)&&n.allOf.forEach((function(n){return s.addSchemaValueCompletions(n,i,o,a)})),Array.isArray(n.anyOf)&&n.anyOf.forEach((function(n){return s.addSchemaValueCompletions(n,i,o,a)})),Array.isArray(n.oneOf)&&n.oneOf.forEach((function(n){return s.addSchemaValueCompletions(n,i,o,a)})))},JSONCompletion.prototype.addDefaultValueCompletions=function(n,i,o,a){var s=this;void 0===a&&(a=0);var c=!1;if(isDefined(n.default)){for(var u=n.type,l=n.default,f=a;f>0;f--)l=[l],u="array";o.add({kind:this.getSuggestionKind(u),label:this.getLabelForValue(l),insertText:this.getInsertTextForValue(l,i),insertTextFormat:ee.Snippet,detail:We("json.suggest.default","Default value")}),c=!0}Array.isArray(n.examples)&&n.examples.forEach((function(u){for(var l=n.type,f=u,h=a;h>0;h--)f=[f],l="array";o.add({kind:s.getSuggestionKind(l),label:s.getLabelForValue(f),insertText:s.getInsertTextForValue(f,i),insertTextFormat:ee.Snippet}),c=!0})),Array.isArray(n.defaultSnippets)&&n.defaultSnippets.forEach((function(u){var l,f,h=n.type,d=u.body,p=u.label;if(isDefined(d)){n.type;for(var m=a;m>0;m--)d=[d],"array";l=s.getInsertTextForSnippetValue(d,i),f=s.getFilterTextForSnippetValue(d),p=p||s.getLabelForSnippetValue(d)}else{if("string"!=typeof u.bodyText)return;var g="",v="",S="";for(m=a;m>0;m--)g=g+S+"[\n",v=v+"\n"+S+"]",S+="\t",h="array";l=g+S+u.bodyText.split("\n").join("\n"+S)+v+i,p=p||l,f=l.replace(/[\n]/g,"")}o.add({kind:s.getSuggestionKind(h),label:p,documentation:s.fromMarkup(u.markdownDescription)||u.description,insertText:l,insertTextFormat:ee.Snippet,filterText:f}),c=!0})),!c&&"object"==typeof n.items&&!Array.isArray(n.items)&&a<5&&this.addDefaultValueCompletions(n.items,i,o,a+1)},JSONCompletion.prototype.addEnumValueCompletions=function(n,i,o){if(isDefined(n.const)&&o.add({kind:this.getSuggestionKind(n.type),label:this.getLabelForValue(n.const),insertText:this.getInsertTextForValue(n.const,i),insertTextFormat:ee.Snippet,documentation:this.fromMarkup(n.markdownDescription)||n.description}),Array.isArray(n.enum))for(var a=0,s=n.enum.length;a0?i[0]:void 0}if(!n)return Y.Value;switch(n){case"string":return Y.Value;case"object":return Y.Module;case"property":return Y.Property;default:return Y.Value}},JSONCompletion.prototype.getLabelTextForMatchingNode=function(n,i){switch(n.type){case"array":return"[]";case"object":return"{}";default:return i.getText().substr(n.offset,n.length)}},JSONCompletion.prototype.getInsertTextForMatchingNode=function(n,i,o){switch(n.type){case"array":return this.getInsertTextForValue([],o);case"object":return this.getInsertTextForValue({},o);default:var a=i.getText().substr(n.offset,n.length)+o;return this.getInsertTextForPlainText(a)}},JSONCompletion.prototype.getInsertTextForProperty=function(n,i,o,a){var s=this.getInsertTextForValue(n,"");if(!o)return s;var c,u=s+": ",l=0;if(i){if(Array.isArray(i.defaultSnippets)){if(1===i.defaultSnippets.length){var f=i.defaultSnippets[0].body;isDefined(f)&&(c=this.getInsertTextForSnippetValue(f,""))}l+=i.defaultSnippets.length}if(i.enum&&(c||1!==i.enum.length||(c=this.getInsertTextForGuessedValue(i.enum[0],"")),l+=i.enum.length),isDefined(i.default)&&(c||(c=this.getInsertTextForGuessedValue(i.default,"")),l++),Array.isArray(i.examples)&&i.examples.length&&(c||(c=this.getInsertTextForGuessedValue(i.examples[0],"")),l+=i.examples.length),0===l){var h=Array.isArray(i.type)?i.type[0]:i.type;switch(h||(i.properties?h="object":i.items&&(h="array")),h){case"boolean":c="$1";break;case"string":c='"$1"';break;case"object":c="{$1}";break;case"array":c="[$1]";break;case"number":case"integer":c="${1:0}";break;case"null":c="${1:null}";break;default:return s}}}return(!c||l>1)&&(c="$1"),u+c+a},JSONCompletion.prototype.getCurrentWord=function(n,i){for(var o=i-1,a=n.getText();o>=0&&-1===' \t\n\r\v":{[,]}'.indexOf(a.charAt(o));)o--;return a.substring(o+1,i)},JSONCompletion.prototype.evaluateSeparatorAfter=function(n,i){var o=J(n.getText(),!0);switch(o.setPosition(i),o.scan()){case 5:case 2:case 4:case 17:return"";default:return","}},JSONCompletion.prototype.findItemAtOffset=function(n,i,o){for(var a=J(i.getText(),!0),s=n.items,c=s.length-1;c>=0;c--){var u=s[c];if(o>u.offset+u.length)return a.setPosition(u.offset+u.length),5===a.scan()&&o>=a.getTokenOffset()+a.getTokenLength()?c+1:c;if(o>=u.offset)return c}return 0},JSONCompletion.prototype.isInComment=function(n,i,o){var a=J(n.getText(),!1);a.setPosition(i);for(var s=a.scan();17!==s&&a.getTokenOffset()+a.getTokenLength()s.offset+1&&a=0;d--){var p=this.contributions[d].getInfoContribution(n.uri,f);if(p)return p.then((function(n){return createHover(n)}))}return this.schemaService.getSchemaForResource(n.uri,o).then((function(n){if(n&&s){var i=o.getMatchingSchemas(n.schema,s.offset),a=void 0,c=void 0,u=void 0,l=void 0;i.every((function(n){if(n.node===s&&!n.inverted&&n.schema&&(a=a||n.schema.title,c=c||n.schema.markdownDescription||toMarkdown(n.schema.description),n.schema.enum)){var i=n.schema.enum.indexOf(jsonParser_getNodeValue(s));n.schema.markdownEnumDescriptions?u=n.schema.markdownEnumDescriptions[i]:n.schema.enumDescriptions&&(u=toMarkdown(n.schema.enumDescriptions[i])),u&&"string"!=typeof(l=n.schema.enum[i])&&(l=JSON.stringify(l))}return!0}));var f="";return a&&(f=toMarkdown(a)),c&&(f.length>0&&(f+="\n\n"),f+=c),u&&(f.length>0&&(f+="\n\n"),f+="`"+function toMarkdownCodeBlock(n){if(-1!==n.indexOf("`"))return"`` "+n+" ``";return n}(l)+"`: "+u),createHover([f])}return null}))}}();function toMarkdown(n){if(n)return n.replace(/([^\n\r])(\r?\n)([^\n\r])/gm,"$1\n\n$3").replace(/[\\`*_{}[\]()#+\-.!]/g,"\\$&")}var Je=o(8030);function createRegex(n,i){if("string"!=typeof n)throw new TypeError("Expected a string");for(var o,a=String(n),s="",c=!!i&&!!i.extended,u=!!i&&!!i.globstar,l=!1,f=i&&"string"==typeof i.flags?i.flags:"",h=0,d=a.length;h1&&("/"===p||void 0===p||"{"===p||","===p)&&("/"===g||void 0===g||","===g||"}"===g)?("/"===g?h++:"/"===p&&s.endsWith("\\/")&&(s=s.substr(0,s.length-2)),s+="((?:[^/]*(?:/|$))*)"):s+="([^/]*)";else s+=".*";break;default:s+=o}return f&&~f.indexOf("g")||(s="^"+s+"$"),new RegExp(s,f)}var Ue=loadMessageBundle(),qe=function(){function FilePatternAssociation(n,i){this.globWrappers=[];try{for(var o=0,a=n;o0&&("/"===s[0]&&(s=s.substring(1)),this.globWrappers.push({regexp:createRegex("**/"+s,{extended:!0,globstar:!0}),include:c}))}this.uris=i}catch(n){this.globWrappers.length=0,this.uris=[]}}return FilePatternAssociation.prototype.matchesPattern=function(n){for(var i=!1,o=0,a=this.globWrappers;o0;)this.callOnDispose.pop()()},JSONSchemaService.prototype.onResourceChange=function(n){for(var i=this,o=!1,a=[n=normalizeId(n)],s=Object.keys(this.schemasById).map((function(n){return i.schemasById[n]}));a.length;)for(var c=a.pop(),u=0;u1&&(o=a[1]),endsWith(o,".")&&(o=o.substr(0,o.length-1)),new He({},[Ue("json.schema.nocontent","Unable to load schema from '{0}': {1}.",toDisplayString(n),o)])}))},JSONSchemaService.prototype.resolveSchemaContent=function(n,i,o){var a=this,s=n.errors.slice(0),c=n.schema;if(c.$schema){var u=normalizeId(c.$schema);if("http://json-schema.org/draft-03/schema"===u)return this.promise.resolve(new ze({},[Ue("json.schema.draft03.notsupported","Draft-03 schemas are not supported.")]));"https://json-schema.org/draft/2019-09/schema"===u&&s.push(Ue("json.schema.draft201909.notsupported","Draft 2019-09 schemas are not yet fully supported."))}var l=this.contextService,merge=function(n,i,o,a){var c=a?decodeURIComponent(a):void 0,u=function(n,i){if(!i)return n;var o=n;return"/"===i[0]&&(i=i.substr(1)),i.split("/").some((function(n){return n=n.replace(/~1/g,"/").replace(/~0/g,"~"),!(o=o[n])})),o}(i,c);if(u)for(var l in u)u.hasOwnProperty(l)&&!n.hasOwnProperty(l)&&(n[l]=u[l]);else s.push(Ue("json.schema.invalidref","$ref '{0}' in '{1}' can not be resolved.",c,o))},resolveExternalLink=function(n,i,o,c,u){l&&!/^[A-Za-z][A-Za-z0-9+\-.+]*:\/\/.*/.test(i)&&(i=l.resolveRelativePath(i,c)),i=normalizeId(i);var f=a.getOrAddSchemaHandle(i);return f.getUnresolvedSchema().then((function(a){if(u[i]=!0,a.errors.length){var c=o?i+"#"+o:i;s.push(Ue("json.schema.problemloadingref","Problems loading reference '{0}': {1}",c,a.errors[0]))}return merge(n,a.schema,i,o),resolveRefs(n,a.schema,i,f.dependencies)}))},resolveRefs=function(n,i,o,s){if(!n||"object"!=typeof n)return Promise.resolve(null);for(var c=[n],u=[],l=[],handleRef=function(n){for(var a=[];n.$ref;){var u=n.$ref,f=u.split("#",2);if(delete n.$ref,f[0].length>0)return void l.push(resolveExternalLink(n,f[0],f[1],o,s));-1===a.indexOf(u)&&(merge(n,i,o,f[1]),a.push(u))}!function(){for(var n=[],i=0;i=0||(u.push(f),handleRef(f))}return a.promise.all(l)};return resolveRefs(c,c,i,o).then((function(n){return new ze(c,s)}))},JSONSchemaService.prototype.getSchemaForResource=function(n,i){if(i&&i.root&&"object"===i.root.type){var o=i.root.properties.filter((function(n){return"$schema"===n.keyNode.value&&n.valueNode&&"string"===n.valueNode.type}));if(o.length>0){var a=o[0].valueNode;if(a&&"string"===a.type){var s=jsonParser_getNodeValue(a);if(s&&startsWith(s,".")&&this.contextService&&(s=this.contextService.resolveRelativePath(s,n)),s){var c=normalizeId(s);return this.getOrAddSchemaHandle(c).getResolvedSchema()}}}}if(this.cachedSchemaForResource&&this.cachedSchemaForResource.resource===n)return this.cachedSchemaForResource.resolvedSchema;for(var u=Object.create(null),l=[],f=function normalizeResourceForMatching(n){try{return Je.a.parse(n).with({fragment:null,query:null}).toString()}catch(i){return n}}(n),h=0,d=this.filePatternAssociations;h0?this.createCombinedSchema(n,l).getResolvedSchema():this.promise.resolve(void 0);return this.cachedSchemaForResource={resource:n,resolvedSchema:S},S},JSONSchemaService.prototype.createCombinedSchema=function(n,i){if(1===i.length)return this.getOrAddSchemaHandle(i[0]);var o="schemaservice://combinedSchema/"+encodeURIComponent(n),a={allOf:i.map((function(n){return{$ref:n}}))};return this.addSchemaHandle(o,a)},JSONSchemaService.prototype.getMatchingSchemas=function(n,i,o){if(o){var a=o.id||"schemaservice://untitled/matchingSchemas/"+Ke++;return this.resolveSchemaContent(new He(o),a,{}).then((function(n){return i.getMatchingSchemas(n.schema).filter((function(n){return!n.inverted}))}))}return this.getSchemaForResource(n.uri,i).then((function(n){return n?i.getMatchingSchemas(n.schema).filter((function(n){return!n.inverted})):[]}))}}(),0);function normalizeId(n){try{return Je.a.parse(n).toString()}catch(i){return n}}function toDisplayString(n){try{var i=Je.a.parse(n);if("file"===i.scheme)return i.fsPath}catch(n){}return n}var Ge=loadMessageBundle(),Xe=(function(){function JSONValidation(n,i){this.jsonSchemaService=n,this.promise=i,this.validationEnabled=!0}JSONValidation.prototype.configure=function(n){n&&(this.validationEnabled=!1!==n.validate,this.commentSeverity=n.allowComments?void 0:N.Error)},JSONValidation.prototype.doValidation=function(n,i,o,a){var s=this;if(!this.validationEnabled)return this.promise.resolve([]);var c=[],u={},addProblem=function(n){var i=n.range.start.line+" "+n.range.start.character+" "+n.message;u[i]||(u[i]=!0,c.push(n))},getDiagnostics=function(a){var u=(null==o?void 0:o.trailingCommas)?toDiagnosticSeverity(o.trailingCommas):N.Error,l=(null==o?void 0:o.comments)?toDiagnosticSeverity(o.comments):s.commentSeverity,f=(null==o?void 0:o.schemaValidation)?toDiagnosticSeverity(o.schemaValidation):N.Warning,d=(null==o?void 0:o.schemaRequest)?toDiagnosticSeverity(o.schemaRequest):N.Warning;if(a){if(a.errors.length&&i.root&&d){var p=i.root,m="object"===p.type?p.properties[0]:void 0;if(m&&"$schema"===m.keyNode.value){var g=m.valueNode||m,v=h.create(n.positionAt(g.offset),n.positionAt(g.offset+g.length));addProblem(I.create(v,a.errors[0],d,Ee.SchemaResolveError))}else{v=h.create(n.positionAt(p.offset),n.positionAt(p.offset+1));addProblem(I.create(v,a.errors[0],d,Ee.SchemaResolveError))}}else if(f){var S=i.validate(n,a.schema,f);S&&S.forEach(addProblem)}(function schemaAllowsComments(n){if(n&&"object"==typeof n){if(isBoolean(n.allowComments))return n.allowComments;if(n.allOf)for(var i=0,o=n.allOf;i=97&&n<=102?n-97+10:0)}function colorFromHex(n){if("#"===n[0])switch(n.length){case 4:return{red:17*hexDigit(n.charCodeAt(1))/255,green:17*hexDigit(n.charCodeAt(2))/255,blue:17*hexDigit(n.charCodeAt(3))/255,alpha:1};case 5:return{red:17*hexDigit(n.charCodeAt(1))/255,green:17*hexDigit(n.charCodeAt(2))/255,blue:17*hexDigit(n.charCodeAt(3))/255,alpha:17*hexDigit(n.charCodeAt(4))/255};case 7:return{red:(16*hexDigit(n.charCodeAt(1))+hexDigit(n.charCodeAt(2)))/255,green:(16*hexDigit(n.charCodeAt(3))+hexDigit(n.charCodeAt(4)))/255,blue:(16*hexDigit(n.charCodeAt(5))+hexDigit(n.charCodeAt(6)))/255,alpha:1};case 9:return{red:(16*hexDigit(n.charCodeAt(1))+hexDigit(n.charCodeAt(2)))/255,green:(16*hexDigit(n.charCodeAt(3))+hexDigit(n.charCodeAt(4)))/255,blue:(16*hexDigit(n.charCodeAt(5))+hexDigit(n.charCodeAt(6)))/255,alpha:(16*hexDigit(n.charCodeAt(7))+hexDigit(n.charCodeAt(8)))/255}}}!function(){function JSONDocumentSymbols(n){this.schemaService=n}JSONDocumentSymbols.prototype.findDocumentSymbols=function(n,i,o){var a=this;void 0===o&&(o={resultLimit:Number.MAX_VALUE});var s=i.root;if(!s)return[];var c=o.resultLimit||Number.MAX_VALUE,u=n.uri;if(("vscode://defaultsettings/keybindings.json"===u||endsWith(u.toLowerCase(),"/user/keybindings.json"))&&"array"===s.type){for(var l=[],f=0,h=s.items;f0){c--;var u=d.create(n.uri,getRange(n,i)),l=o?o+"."+i.keyNode.value:i.keyNode.value;T.push({name:a.getKeyLabel(i),kind:a.getSymbolKind(s.type),location:u,containerName:o}),k.push({node:s,containerName:l})}else N=!0}))};O0){c--;var u=getRange(n,i),l=u,f={name:String(s),kind:a.getSymbolKind(i.type),range:u,selectionRange:l,children:[]};o.push(f),O.push({result:f.children,node:i})}else T=!0})):"object"===i.type&&i.properties.forEach((function(i){var s=i.valueNode;if(s)if(c>0){c--;var u=getRange(n,i),l=getRange(n,i.keyNode),f=[],h={name:a.getKeyLabel(i),kind:a.getSymbolKind(s.type),range:u,selectionRange:l,children:f,detail:a.getDetail(s)};o.push(h),O.push({result:f,node:s})}else T=!0}))};N0,g){case 1:h=pt.push(h,0),m="delimiter.bracket.json",f=!1;break;case 2:h=pt.pop(h),m="delimiter.bracket.json",f=!1;break;case 3:h=pt.push(h,1),m="delimiter.array.json",f=!1;break;case 4:h=pt.pop(h),m="delimiter.array.json",f=!1;break;case 6:m="delimiter.colon.json",f=!0;break;case 5:m="delimiter.comma.json",f=!1;break;case 8:case 9:case 7:m="keyword.json",f=!1;break;case 10:var v=1===(h?h.type:0);m=f||v?"string.value.json":"string.key.json",f=!1;break;case 11:m="number.json",f=!1}if(n)switch(g){case 12:m="comment.line.json";break;case 13:m="comment.block.json"}d.endState=new mt(o.getStateData(),l.getTokenError(),f,h),d.tokens.push({startIndex:p,scopes:m})}return d}(n,i,o,a)}}}var pt=function(){function ParentsStack(n,i){this.parent=n,this.type=i}return ParentsStack.pop=function(n){return n?n.parent:null},ParentsStack.push=function(n,i){return new ParentsStack(n,i)},ParentsStack.equals=function(n,i){if(!n&&!i)return!0;if(!n||!i)return!1;for(;n&&i;){if(n===i)return!0;if(n.type!==i.type)return!1;n=n.parent,i=i.parent}return!0},ParentsStack}(),mt=function(){function JSONState(n,i,o,a){this._state=n,this.scanError=i,this.lastWasColon=o,this.parents=a}return JSONState.prototype.clone=function(){return new JSONState(this._state,this.scanError,this.lastWasColon,this.parents)},JSONState.prototype.equals=function(n){return n===this||!!(n&&n instanceof JSONState)&&(this.scanError===n.scanError&&this.lastWasColon===n.lastWasColon&&pt.equals(this.parents,n.parents))},JSONState.prototype.getStateData=function(){return this._state},JSONState.prototype.setStateData=function(n){this._state=n},JSONState}();function setupMode(n){var i=[],o=[],a=new c(n);i.push(a);var worker=function(){for(var n=[],i=0;i{var i={470:i=>{function e(n){if("string"!=typeof n)throw new TypeError("Path must be a string. Received "+JSON.stringify(n))}function r(n,i){for(var o,a="",s=0,c=-1,u=0,l=0;l<=n.length;++l){if(l2){var f=a.lastIndexOf("/");if(f!==a.length-1){-1===f?(a="",s=0):s=(a=a.slice(0,f)).length-1-a.lastIndexOf("/"),c=l,u=0;continue}}else if(2===a.length||1===a.length){a="",s=0,c=l,u=0;continue}i&&(a.length>0?a+="/..":a="..",s=2)}else a.length>0?a+="/"+n.slice(c+1,l):a=n.slice(c+1,l),s=l-c-1;c=l,u=0}else 46===o&&-1!==u?++u:u=-1}return a}var o={resolve:function(){for(var i,o="",a=!1,s=arguments.length-1;s>=-1&&!a;s--){var c;s>=0?c=arguments[s]:(void 0===i&&(i=n.cwd()),c=i),e(c),0!==c.length&&(o=c+"/"+o,a=47===c.charCodeAt(0))}return o=r(o,!a),a?o.length>0?"/"+o:"/":o.length>0?o:"."},normalize:function(n){if(e(n),0===n.length)return".";var i=47===n.charCodeAt(0),o=47===n.charCodeAt(n.length-1);return 0!==(n=r(n,!i)).length||i||(n="."),n.length>0&&o&&(n+="/"),i?"/"+n:n},isAbsolute:function(n){return e(n),n.length>0&&47===n.charCodeAt(0)},join:function(){if(0===arguments.length)return".";for(var n,i=0;i0&&(void 0===n?n=a:n+="/"+a)}return void 0===n?".":o.normalize(n)},relative:function(n,i){if(e(n),e(i),n===i)return"";if((n=o.resolve(n))===(i=o.resolve(i)))return"";for(var a=1;af){if(47===i.charCodeAt(u+d))return i.slice(u+d+1);if(0===d)return i.slice(u+d)}else c>f&&(47===n.charCodeAt(a+d)?h=d:0===d&&(h=0));break}var p=n.charCodeAt(a+d);if(p!==i.charCodeAt(u+d))break;47===p&&(h=d)}var m="";for(d=a+h+1;d<=s;++d)d!==s&&47!==n.charCodeAt(d)||(0===m.length?m+="..":m+="/..");return m.length>0?m+i.slice(u+h):(u+=h,47===i.charCodeAt(u)&&++u,i.slice(u))},_makeLong:function(n){return n},dirname:function(n){if(e(n),0===n.length)return".";for(var i=n.charCodeAt(0),o=47===i,a=-1,s=!0,c=n.length-1;c>=1;--c)if(47===(i=n.charCodeAt(c))){if(!s){a=c;break}}else s=!1;return-1===a?o?"/":".":o&&1===a?"//":n.slice(0,a)},basename:function(n,i){if(void 0!==i&&"string"!=typeof i)throw new TypeError('"ext" argument must be a string');e(n);var o,a=0,s=-1,c=!0;if(void 0!==i&&i.length>0&&i.length<=n.length){if(i.length===n.length&&i===n)return"";var u=i.length-1,l=-1;for(o=n.length-1;o>=0;--o){var f=n.charCodeAt(o);if(47===f){if(!c){a=o+1;break}}else-1===l&&(c=!1,l=o+1),u>=0&&(f===i.charCodeAt(u)?-1==--u&&(s=o):(u=-1,s=l))}return a===s?s=l:-1===s&&(s=n.length),n.slice(a,s)}for(o=n.length-1;o>=0;--o)if(47===n.charCodeAt(o)){if(!c){a=o+1;break}}else-1===s&&(c=!1,s=o+1);return-1===s?"":n.slice(a,s)},extname:function(n){e(n);for(var i=-1,o=0,a=-1,s=!0,c=0,u=n.length-1;u>=0;--u){var l=n.charCodeAt(u);if(47!==l)-1===a&&(s=!1,a=u+1),46===l?-1===i?i=u:1!==c&&(c=1):-1!==i&&(c=-1);else if(!s){o=u+1;break}}return-1===i||-1===a||0===c||1===c&&i===a-1&&i===o+1?"":n.slice(i,a)},format:function(n){if(null===n||"object"!=typeof n)throw new TypeError('The "pathObject" argument must be of type Object. Received type '+typeof n);return function(n,i){var o=i.dir||i.root,a=i.base||(i.name||"")+(i.ext||"");return o?o===i.root?o+a:o+"/"+a:a}(0,n)},parse:function(n){e(n);var i={root:"",dir:"",base:"",ext:"",name:""};if(0===n.length)return i;var o,a=n.charCodeAt(0),s=47===a;s?(i.root="/",o=1):o=0;for(var c=-1,u=0,l=-1,f=!0,h=n.length-1,d=0;h>=o;--h)if(47!==(a=n.charCodeAt(h)))-1===l&&(f=!1,l=h+1),46===a?-1===c?c=h:1!==d&&(d=1):-1!==c&&(d=-1);else if(!f){u=h+1;break}return-1===c||-1===l||0===d||1===d&&c===l-1&&c===u+1?-1!==l&&(i.base=i.name=0===u&&s?n.slice(1,l):n.slice(u,l)):(0===u&&s?(i.name=n.slice(1,c),i.base=n.slice(1,l)):(i.name=n.slice(u,c),i.base=n.slice(u,l)),i.ext=n.slice(c,l)),u>0?i.dir=n.slice(0,u-1):s&&(i.dir="/"),i},sep:"/",delimiter:":",win32:null,posix:null};o.posix=o,i.exports=o},447:(i,o,a)=>{var s;if(a.r(o),a.d(o,{URI:()=>S,Utils:()=>E}),"object"==typeof n)s="win32"===n.platform;else if("object"==typeof navigator){var c=navigator.userAgent;s=c.indexOf("Windows")>=0}var u,l,f=(u=function(n,i){return(u=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,i){n.__proto__=i}||function(n,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(n[o]=i[o])})(n,i)},function(n,i){function r(){this.constructor=n}u(n,i),n.prototype=null===i?Object.create(i):(r.prototype=i.prototype,new r)}),h=/^\w[\w\d+.-]*$/,d=/^\//,p=/^\/\//,m="",g="/",v=/^(([^:/?#]+?):)?(\/\/([^/?#]*))?([^?#]*)(\?([^#]*))?(#(.*))?/,S=function(){function t(n,i,o,a,s,c){void 0===c&&(c=!1),"object"==typeof n?(this.scheme=n.scheme||m,this.authority=n.authority||m,this.path=n.path||m,this.query=n.query||m,this.fragment=n.fragment||m):(this.scheme=function(n,i){return n||i?n:"file"}(n,c),this.authority=i||m,this.path=function(n,i){switch(n){case"https":case"http":case"file":i?i[0]!==g&&(i=g+i):i=g}return i}(this.scheme,o||m),this.query=a||m,this.fragment=s||m,function(n,i){if(!n.scheme&&i)throw new Error('[UriError]: Scheme is missing: {scheme: "", authority: "'+n.authority+'", path: "'+n.path+'", query: "'+n.query+'", fragment: "'+n.fragment+'"}');if(n.scheme&&!h.test(n.scheme))throw new Error("[UriError]: Scheme contains illegal characters.");if(n.path)if(n.authority){if(!d.test(n.path))throw new Error('[UriError]: If a URI contains an authority component, then the path component must either be empty or begin with a slash ("/") character')}else if(p.test(n.path))throw new Error('[UriError]: If a URI does not contain an authority component, then the path cannot begin with two slash characters ("//")')}(this,c))}return t.isUri=function(n){return n instanceof t||!!n&&"string"==typeof n.authority&&"string"==typeof n.fragment&&"string"==typeof n.path&&"string"==typeof n.query&&"string"==typeof n.scheme&&"function"==typeof n.fsPath&&"function"==typeof n.with&&"function"==typeof n.toString},Object.defineProperty(t.prototype,"fsPath",{get:function(){return C(this,!1)},enumerable:!1,configurable:!0}),t.prototype.with=function(n){if(!n)return this;var i=n.scheme,o=n.authority,a=n.path,s=n.query,c=n.fragment;return void 0===i?i=this.scheme:null===i&&(i=m),void 0===o?o=this.authority:null===o&&(o=m),void 0===a?a=this.path:null===a&&(a=m),void 0===s?s=this.query:null===s&&(s=m),void 0===c?c=this.fragment:null===c&&(c=m),i===this.scheme&&o===this.authority&&a===this.path&&s===this.query&&c===this.fragment?this:new O(i,o,a,s,c)},t.parse=function(n,i){void 0===i&&(i=!1);var o=v.exec(n);return o?new O(o[2]||m,x(o[4]||m),x(o[5]||m),x(o[7]||m),x(o[9]||m),i):new O(m,m,m,m,m)},t.file=function(n){var i=m;if(s&&(n=n.replace(/\\/g,g)),n[0]===g&&n[1]===g){var o=n.indexOf(g,2);-1===o?(i=n.substring(2),n=g):(i=n.substring(2,o),n=n.substring(o)||g)}return new O("file",i,n,m,m)},t.from=function(n){return new O(n.scheme,n.authority,n.path,n.query,n.fragment)},t.prototype.toString=function(n){return void 0===n&&(n=!1),A(this,n)},t.prototype.toJSON=function(){return this},t.revive=function(n){if(n){if(n instanceof t)return n;var i=new O(n);return i._formatted=n.external,i._fsPath=n._sep===k?n.fsPath:null,i}return n},t}(),k=s?1:void 0,O=function(n){function e(){var i=null!==n&&n.apply(this,arguments)||this;return i._formatted=null,i._fsPath=null,i}return f(e,n),Object.defineProperty(e.prototype,"fsPath",{get:function(){return this._fsPath||(this._fsPath=C(this,!1)),this._fsPath},enumerable:!1,configurable:!0}),e.prototype.toString=function(n){return void 0===n&&(n=!1),n?A(this,!0):(this._formatted||(this._formatted=A(this,!1)),this._formatted)},e.prototype.toJSON=function(){var n={$mid:1};return this._fsPath&&(n.fsPath=this._fsPath,n._sep=k),this._formatted&&(n.external=this._formatted),this.path&&(n.path=this.path),this.scheme&&(n.scheme=this.scheme),this.authority&&(n.authority=this.authority),this.query&&(n.query=this.query),this.fragment&&(n.fragment=this.fragment),n},e}(S),N=((l={})[58]="%3A",l[47]="%2F",l[63]="%3F",l[35]="%23",l[91]="%5B",l[93]="%5D",l[64]="%40",l[33]="%21",l[36]="%24",l[38]="%26",l[39]="%27",l[40]="%28",l[41]="%29",l[42]="%2A",l[43]="%2B",l[44]="%2C",l[59]="%3B",l[61]="%3D",l[32]="%20",l);function y(n,i){for(var o=void 0,a=-1,s=0;s=97&&c<=122||c>=65&&c<=90||c>=48&&c<=57||45===c||46===c||95===c||126===c||i&&47===c)-1!==a&&(o+=encodeURIComponent(n.substring(a,s)),a=-1),void 0!==o&&(o+=n.charAt(s));else{void 0===o&&(o=n.substr(0,s));var u=N[c];void 0!==u?(-1!==a&&(o+=encodeURIComponent(n.substring(a,s)),a=-1),o+=u):-1===a&&(a=s)}}return-1!==a&&(o+=encodeURIComponent(n.substring(a))),void 0!==o?o:n}function b(n){for(var i=void 0,o=0;o1&&"file"===n.scheme?"//"+n.authority+n.path:47===n.path.charCodeAt(0)&&(n.path.charCodeAt(1)>=65&&n.path.charCodeAt(1)<=90||n.path.charCodeAt(1)>=97&&n.path.charCodeAt(1)<=122)&&58===n.path.charCodeAt(2)?i?n.path.substr(1):n.path[1].toLowerCase()+n.path.substr(2):n.path,s&&(o=o.replace(/\//g,"\\")),o}function A(n,i){var o=i?b:y,a="",s=n.scheme,c=n.authority,u=n.path,l=n.query,f=n.fragment;if(s&&(a+=s,a+=":"),(c||"file"===s)&&(a+=g,a+=g),c){var h=c.indexOf("@");if(-1!==h){var d=c.substr(0,h);c=c.substr(h+1),-1===(h=d.indexOf(":"))?a+=o(d,!1):(a+=o(d.substr(0,h),!1),a+=":",a+=o(d.substr(h+1),!1)),a+="@"}-1===(h=(c=c.toLowerCase()).indexOf(":"))?a+=o(c,!1):(a+=o(c.substr(0,h),!1),a+=c.substr(h))}if(u){if(u.length>=3&&47===u.charCodeAt(0)&&58===u.charCodeAt(2))(p=u.charCodeAt(1))>=65&&p<=90&&(u="/"+String.fromCharCode(p+32)+":"+u.substr(3));else if(u.length>=2&&58===u.charCodeAt(1)){var p;(p=u.charCodeAt(0))>=65&&p<=90&&(u=String.fromCharCode(p+32)+":"+u.substr(2))}a+=o(u,!0)}return l&&(a+="?",a+=o(l,!1)),f&&(a+="#",a+=i?f:y(f,!1)),a}var T=/(%[0-9A-Za-z][0-9A-Za-z])+/g;function x(n){return n.match(T)?n.replace(T,(function(n){return function w(n){try{return decodeURIComponent(n)}catch(i){return n.length>3?n.substr(0,3)+w(n.substr(3)):n}}(n)})):n}var E,I=a(470),j=function(){for(var n=0,i=0,o=arguments.length;i{for(var o in i)r.o(i,o)&&!r.o(n,o)&&Object.defineProperty(n,o,{enumerable:!0,get:i[o]})},r.o=(n,i)=>Object.prototype.hasOwnProperty.call(n,i),r.r=n=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(n,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(n,"__esModule",{value:!0})},r(447)})();const{URI:s,Utils:c}=a}).call(this,o(343))}}]);