code-server
Version:
Run VS Code on a remote server.
80 lines • 1.08 MB
JavaScript
/*!--------------------------------------------------------
* Copyright (C) Microsoft Corporation. All rights reserved.
*--------------------------------------------------------*/(function(){var ye=["exports","require","vs/base/common/uri","vs/platform/instantiation/common/instantiation","vs/base/common/event","vs/workbench/api/common/extHost.protocol","vs/workbench/api/common/extHostTypes","vs/base/common/lifecycle","vs/workbench/api/common/extHostTypeConverters","vs/base/common/strings","vs/base/common/types","vs/base/common/errors","vs/base/common/network","vs/base/common/async","vs/platform/log/common/log","vs/workbench/api/common/extHostRpcService","vs/base/common/arrays","vs/nls","vs/nls!vs/workbench/api/worker/extensionHostWorker","vs/base/common/path","vs/base/common/cancellation","vs/base/common/resources","vs/base/common/buffer","vs/base/common/platform","vs/workbench/services/extensions/common/extensions","vs/base/common/map","vs/base/common/objects","vs/platform/extensions/common/extensions","vs/workbench/api/common/extHostInitDataService","vs/base/common/severity","vs/platform/registry/common/platform","vs/workbench/api/common/extHostWorkspace","vs/workbench/api/common/extHostConfiguration","vs/workbench/api/common/extHostExtensionService","vs/base/common/glob","vs/workbench/api/common/extHostFileSystemInfo","vs/workbench/api/common/extHostCommands","vs/base/common/extpath","vs/platform/contextkey/common/contextkey","vs/platform/files/common/files","vs/workbench/services/extensions/common/proxyIdentifier","vs/workbench/services/search/common/search","vs/base/common/assert","vs/base/common/uuid","vs/base/common/errorMessage","vs/platform/workspace/common/workspace","vs/workbench/contrib/testing/common/testId","vs/workbench/contrib/testing/common/testTypes","vs/editor/common/core/range","vs/workbench/api/common/extHostDocumentsAndEditors","vs/workbench/api/common/extHostEditorTabs","vs/workbench/api/common/extHostFileSystemConsumer","vs/workbench/api/common/extHostTerminalService","vs/workbench/api/common/extHostWebview","vs/base/common/decorators","vs/base/common/marshalling","vs/platform/instantiation/common/extensions","vs/platform/configuration/common/configuration","vs/platform/instantiation/common/serviceCollection","vs/base/common/process","vs/platform/theme/common/themeService","vs/workbench/api/common/cache","vs/workbench/api/common/extHostTunnelService","vs/workbench/api/common/extHostUriTransformerService","vs/workbench/common/webview","vs/workbench/contrib/testing/common/testItemCollection","vs/editor/common/languages","vs/workbench/api/common/exHostSecretState","vs/workbench/api/common/extHostApiDeprecationService","vs/workbench/api/common/extHostStorage","vs/workbench/api/common/extHostStoragePaths","vs/base/common/performance","vs/base/common/collections","vs/base/common/idGenerator","vs/base/common/mime","vs/base/common/htmlContent","vs/base/common/labels","vs/editor/common/services/semanticTokensDto","vs/platform/instantiation/common/descriptors","vs/platform/extensionManagement/common/extensionManagement","vs/platform/markers/common/markers","vs/platform/opener/common/opener","vs/platform/jsonschemas/common/jsonContributionRegistry","vs/platform/configuration/common/configurationRegistry","vs/platform/remote/common/remoteAuthorityResolver","vs/platform/remote/common/remoteHosts","vs/workbench/api/common/extHostTelemetry","vs/workbench/api/common/extHostDocumentData","vs/workbench/contrib/notebook/common/notebookCommon","vs/workbench/api/common/extHostTestingPrivateApi","vs/workbench/services/editor/common/editorGroupsService","vs/workbench/api/common/extHostNotebookEditor","vs/workbench/api/common/extHostTestItem","vs/workbench/api/common/extHostTextEditor","vs/workbench/services/extensions/common/extensionHostProtocol","vs/workbench/api/common/extHostDecorations","vs/base/common/hash","vs/workbench/api/common/extHostWindow","vs/workbench/api/common/extHostOutput","vs/workbench/services/search/common/searchExtTypes","vs/workbench/api/common/extHostTask","vs/workbench/api/common/extHostVariableResolverService","vs/workbench/api/common/extHostDebugService","vs/workbench/api/common/extHostSearch","vs/base/common/json","vs/base/common/marked/marked","vs/base/common/numbers","vs/base/common/stream","vs/base/common/filters","vs/base/common/iconLabels","vs/base/common/codicons","vs/base/common/comparers","vs/base/common/uriIpc","vs/editor/common/core/textModelDefaults","vs/editor/common/languageSelector","vs/editor/common/languages/languageConfiguration","vs/nls!vs/base/common/date","vs/base/common/date","vs/nls!vs/base/common/errorMessage","vs/nls!vs/editor/common/config/editorOptions","vs/editor/common/config/editorOptions","vs/editor/common/core/wordHelper","vs/nls!vs/platform/configuration/common/configurationRegistry","vs/nls!vs/platform/extensionManagement/common/extensionManagement","vs/nls!vs/platform/extensions/common/extensionValidator","vs/nls!vs/platform/files/common/files","vs/nls!vs/platform/markers/common/markers","vs/nls!vs/platform/workspace/common/workspace","vs/nls!vs/workbench/api/common/extHostDiagnostics","vs/nls!vs/workbench/api/common/extHostExtensionService","vs/nls!vs/workbench/api/common/extHostProgress","vs/nls!vs/workbench/api/common/extHostStatusBar","vs/nls!vs/workbench/api/common/extHostTerminalService","vs/nls!vs/workbench/api/common/extHostTreeViews","vs/nls!vs/workbench/api/common/extHostWorkspace","vs/nls!vs/workbench/common/editor","vs/nls!vs/workbench/contrib/debug/common/abstractDebugAdapter","vs/nls!vs/workbench/contrib/debug/common/debug","vs/nls!vs/workbench/contrib/tasks/common/taskDefinitionRegistry","vs/nls!vs/workbench/contrib/tasks/common/tasks","vs/nls!vs/workbench/services/configurationResolver/common/variableResolver","vs/nls!vs/workbench/services/extensions/common/extensionsRegistry","vs/nls!vs/workbench/services/search/common/queryBuilder","vs/platform/editor/common/editor","vs/platform/extensions/common/extensionValidator","vs/platform/instantiation/common/graph","vs/platform/environment/common/environment","vs/platform/instantiation/common/instantiationService","vs/platform/notification/common/notification","vs/platform/product/common/productService","vs/platform/progress/common/progress","vs/platform/configuration/common/configurationModels","vs/platform/extensionManagement/common/extensionManagementUtil","vs/platform/terminal/common/terminalDataBuffering","vs/platform/theme/common/theme","vs/platform/tunnel/common/tunnel","vs/platform/workspace/common/virtualWorkspace","vs/workbench/api/common/extHostMemento","vs/workbench/api/common/extHostNotebookDocuments","vs/workbench/api/common/extHostSecrets","vs/workbench/api/common/extHostTheming","vs/workbench/api/common/extHostWebviewMessaging","vs/workbench/common/editor","vs/workbench/api/common/extHostCodeInsets","vs/workbench/contrib/debug/common/abstractDebugAdapter","vs/workbench/contrib/debug/common/debug","vs/workbench/contrib/debug/common/debugUtils","vs/base/common/iterator","vs/workbench/contrib/notebook/common/notebookExecutionService","vs/workbench/contrib/terminal/common/environmentVariableShared","vs/workbench/services/configurationResolver/common/variableResolver","vs/workbench/services/editor/common/editorService","vs/base/common/functional","vs/workbench/api/common/extHostDocumentSaveParticipant","vs/workbench/api/common/extHostNotebookDocument","vs/workbench/api/common/extHostNotebookEditors","vs/workbench/api/common/extHostProgress","vs/workbench/services/environment/common/environmentService","vs/workbench/services/extensions/common/extensionDescriptionRegistry","vs/workbench/api/common/extHostExtensionActivator","vs/workbench/api/common/extHostLogService","vs/workbench/services/extensions/common/extensionsApiProposals","vs/workbench/services/extensions/common/extensionsRegistry","vs/workbench/contrib/tasks/common/taskDefinitionRegistry","vs/workbench/contrib/tasks/common/tasks","vs/workbench/services/extensions/common/lazyPromise","vs/workbench/api/common/extHostAuthentication","vs/workbench/api/common/extHostBulkEdits","vs/workbench/api/common/extHostClipboard","vs/workbench/api/common/extHostApiCommands","vs/workbench/api/common/extHostComments","vs/workbench/api/common/extHostConsoleForwarder","vs/workbench/api/common/extHostDiagnostics","vs/workbench/api/common/extHostDialogs","vs/workbench/api/common/extHostDocumentContentProviders","vs/workbench/api/common/extHostDocuments","vs/base/common/lazy","vs/workbench/api/common/extHostFileSystem","vs/workbench/api/common/extHostFileSystemEventService","vs/workbench/api/common/extHostInteractive","vs/workbench/api/common/extHostLabelService","vs/workbench/api/common/extHostLanguageFeatures","vs/base/common/stopwatch","vs/workbench/api/common/extHostLanguages","vs/workbench/api/common/extHostLoggerService","vs/workbench/api/common/extHostMessageService","vs/workbench/api/common/extHostNotebook","vs/workbench/api/common/extHostNotebookKernels","vs/workbench/api/common/extHostNotebookRenderers","vs/workbench/api/common/extHostQuickOpen","vs/workbench/api/common/extHostSCM","vs/workbench/api/common/extHostStatusBar","vs/workbench/api/common/extHostTesting","vs/workbench/api/common/extHostTextEditors","vs/workbench/api/common/extHostTimeline","vs/workbench/api/common/extHostUriOpener","vs/workbench/api/common/extHostUrls","vs/workbench/api/common/extHostCustomEditors","vs/workbench/api/common/extHostWebviewPanels","vs/workbench/api/common/extHostWebviewView","vs/workbench/api/worker/extHostConsoleForwarder","vs/workbench/services/extensions/common/rpcProtocol","vs/workbench/services/extensions/worker/polyfillNestedWorker","vs/workbench/services/output/common/output","vs/workbench/services/remote/common/remoteAgentService","vs/workbench/services/path/common/pathService","vs/workbench/services/search/common/fileSearchManager","vs/workbench/services/search/common/queryBuilder","vs/workbench/services/extensions/common/workspaceContains","vs/workbench/api/common/extHostRequireInterceptor","vs/workbench/api/common/extensionHostMain","vs/workbench/services/search/common/textSearchManager","vs/workbench/api/common/extHost.common.services","vs/workbench/services/views/common/treeViewsService","vs/workbench/api/common/extHostTreeViews","vs/workbench/api/common/extHost.api.impl","vs/workbench/api/worker/extHostExtensionService","vs/workbench/api/worker/extHost.worker.services","vs/base/common/semver/semver","vs/editor/common/model/mirrorTextModel","vs/base/common/linkedList","vs/editor/common/core/position","vs/editor/common/languages/linkComputer","vs/editor/common/core/selection","vs/editor/common/model/textModelSearch","vs/editor/common/model","vs/workbench/api/worker/extensionHostWorker"],Ce=function(ee){for(var e=[],s=0,p=ee.length;s<p;s++)e[s]=ye[ee[s]];return e};define(ye[42],Ce([1,0]),function(ee,e){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.ok=void 0;function s(p,b){if(!p)throw new Error(b?`Assertion failed (${b})`:"Assertion Failed")}e.ok=s}),define(ye[72],Ce([1,0]),function(ee,e){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.SetMap=e.diffMaps=e.diffSets=e.groupBy=void 0;function s(C,T){const E=Object.create(null);for(const A of C){const R=T(A);let y=E[R];y||(y=E[R]=[]),y.push(A)}return E}e.groupBy=s;function p(C,T){const E=[],A=[];for(const R of C)T.has(R)||E.push(R);for(const R of T)C.has(R)||A.push(R);return{removed:E,added:A}}e.diffSets=p;function b(C,T){const E=[],A=[];for(const[R,y]of C)T.has(R)||E.push(y);for(const[R,y]of T)C.has(R)||A.push(y);return{removed:E,added:A}}e.diffMaps=b;class L{constructor(){this.map=new Map}add(T,E){let A=this.map.get(T);A||(A=new Set,this.map.set(T,A)),A.add(E)}delete(T,E){const A=this.map.get(T);!A||(A.delete(E),A.size===0&&this.map.delete(T))}forEach(T,E){const A=this.map.get(T);!A||A.forEach(E)}}e.SetMap=L}),define(ye[54],Ce([1,0]),function(ee,e){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.throttle=e.debounce=e.memoize=e.createDecorator=void 0;function s(C){return(T,E,A)=>{let R=null,y=null;if(typeof A.value=="function"?(R="value",y=A.value):typeof A.get=="function"&&(R="get",y=A.get),!y)throw new Error("not supported");A[R]=C(y,E)}}e.createDecorator=s;function p(C,T,E){let A=null,R=null;if(typeof E.value=="function"?(A="value",R=E.value,R.length!==0&&console.warn("Memoize should only be used in functions with zero parameters")):typeof E.get=="function"&&(A="get",R=E.get),!R)throw new Error("not supported");const y=`$memoize$${T}`;E[A]=function(...m){return this.hasOwnProperty(y)||Object.defineProperty(this,y,{configurable:!1,enumerable:!1,writable:!1,value:R.apply(this,m)}),this[y]}}e.memoize=p;function b(C,T,E){return s((A,R)=>{const y=`$debounce$${R}`,m=`$debounce$result$${R}`;return function(...I){this[m]||(this[m]=E?E():void 0),clearTimeout(this[y]),T&&(this[m]=T(this[m],...I),I=[this[m]]),this[y]=setTimeout(()=>{A.apply(this,I),this[m]=E?E():void 0},C)}})}e.debounce=b;function L(C,T,E){return s((A,R)=>{const y=`$throttle$timer$${R}`,m=`$throttle$result$${R}`,I=`$throttle$lastRun$${R}`,f=`$throttle$pending$${R}`;return function(...h){if(this[m]||(this[m]=E?E():void 0),(this[I]===null||this[I]===void 0)&&(this[I]=-Number.MAX_VALUE),T&&(this[m]=T(this[m],...h)),this[f])return;const d=this[I]+C;d<=Date.now()?(this[I]=Date.now(),A.apply(this,[this[m]]),this[m]=E?E():void 0):(this[f]=!0,this[y]=setTimeout(()=>{this[f]=!1,this[I]=Date.now(),A.apply(this,[this[m]]),this[m]=E?E():void 0},d-Date.now()))}})}e.throttle=L}),define(ye[73],Ce([1,0]),function(ee,e){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.defaultGenerator=e.IdGenerator=void 0;class s{constructor(b){this._prefix=b,this._lastId=0}nextId(){return this._prefix+ ++this._lastId}}e.IdGenerator=s,e.defaultGenerator=new s("id#")}),define(ye[104],Ce([1,0]),function(ee,e){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.getNodeType=e.stripComments=e.visit=e.findNodeAtOffset=e.contains=e.getNodeValue=e.getNodePath=e.findNodeAtLocation=e.parseTree=e.parse=e.getLocation=e.createScanner=e.ParseOptions=e.ParseErrorCode=e.SyntaxKind=e.ScanError=void 0;var s;(function(n){n[n.None=0]="None",n[n.UnexpectedEndOfComment=1]="UnexpectedEndOfComment",n[n.UnexpectedEndOfString=2]="UnexpectedEndOfString",n[n.UnexpectedEndOfNumber=3]="UnexpectedEndOfNumber",n[n.InvalidUnicode=4]="InvalidUnicode",n[n.InvalidEscapeCharacter=5]="InvalidEscapeCharacter",n[n.InvalidCharacter=6]="InvalidCharacter"})(s=e.ScanError||(e.ScanError={}));var p;(function(n){n[n.OpenBraceToken=1]="OpenBraceToken",n[n.CloseBraceToken=2]="CloseBraceToken",n[n.OpenBracketToken=3]="OpenBracketToken",n[n.CloseBracketToken=4]="CloseBracketToken",n[n.CommaToken=5]="CommaToken",n[n.ColonToken=6]="ColonToken",n[n.NullKeyword=7]="NullKeyword",n[n.TrueKeyword=8]="TrueKeyword",n[n.FalseKeyword=9]="FalseKeyword",n[n.StringLiteral=10]="StringLiteral",n[n.NumericLiteral=11]="NumericLiteral",n[n.LineCommentTrivia=12]="LineCommentTrivia",n[n.BlockCommentTrivia=13]="BlockCommentTrivia",n[n.LineBreakTrivia=14]="LineBreakTrivia",n[n.Trivia=15]="Trivia",n[n.Unknown=16]="Unknown",n[n.EOF=17]="EOF"})(p=e.SyntaxKind||(e.SyntaxKind={}));var b;(function(n){n[n.InvalidSymbol=1]="InvalidSymbol",n[n.InvalidNumberFormat=2]="InvalidNumberFormat",n[n.PropertyNameExpected=3]="PropertyNameExpected",n[n.ValueExpected=4]="ValueExpected",n[n.ColonExpected=5]="ColonExpected",n[n.CommaExpected=6]="CommaExpected",n[n.CloseBraceExpected=7]="CloseBraceExpected",n[n.CloseBracketExpected=8]="CloseBracketExpected",n[n.EndOfFileExpected=9]="EndOfFileExpected",n[n.InvalidCommentToken=10]="InvalidCommentToken",n[n.UnexpectedEndOfComment=11]="UnexpectedEndOfComment",n[n.UnexpectedEndOfString=12]="UnexpectedEndOfString",n[n.UnexpectedEndOfNumber=13]="UnexpectedEndOfNumber",n[n.InvalidUnicode=14]="InvalidUnicode",n[n.InvalidEscapeCharacter=15]="InvalidEscapeCharacter",n[n.InvalidCharacter=16]="InvalidCharacter"})(b=e.ParseErrorCode||(e.ParseErrorCode={}));var L;(function(n){n.DEFAULT={allowTrailingComma:!0}})(L=e.ParseOptions||(e.ParseOptions={}));function C(n,u=!1){let i=0;const o=n.length;let r="",t=0,c=16,v=0;function g($){let N=0,K=0;for(;N<$;){const V=n.charCodeAt(i);if(V>=48&&V<=57)K=K*16+V-48;else if(V>=65&&V<=70)K=K*16+V-65+10;else if(V>=97&&V<=102)K=K*16+V-97+10;else break;i++,N++}return N<$&&(K=-1),K}function D($){i=$,r="",t=0,c=16,v=0}function U(){const $=i;if(n.charCodeAt(i)===48)i++;else for(i++;i<n.length&&A(n.charCodeAt(i));)i++;if(i<n.length&&n.charCodeAt(i)===46)if(i++,i<n.length&&A(n.charCodeAt(i)))for(i++;i<n.length&&A(n.charCodeAt(i));)i++;else return v=3,n.substring($,i);let N=i;if(i<n.length&&(n.charCodeAt(i)===69||n.charCodeAt(i)===101))if(i++,(i<n.length&&n.charCodeAt(i)===43||n.charCodeAt(i)===45)&&i++,i<n.length&&A(n.charCodeAt(i))){for(i++;i<n.length&&A(n.charCodeAt(i));)i++;N=i}else v=3;return n.substring($,N)}function W(){let $="",N=i;for(;;){if(i>=o){$+=n.substring(N,i),v=2;break}const K=n.charCodeAt(i);if(K===34){$+=n.substring(N,i),i++;break}if(K===92){if($+=n.substring(N,i),i++,i>=o){v=2;break}switch(n.charCodeAt(i++)){case 34:$+='"';break;case 92:$+="\\";break;case 47:$+="/";break;case 98:$+="\b";break;case 102:$+="\f";break;case 110:$+=`
`;break;case 114:$+="\r";break;case 116:$+=" ";break;case 117:{const F=g(4);F>=0?$+=String.fromCharCode(F):v=4;break}default:v=5}N=i;continue}if(K>=0&&K<=31)if(E(K)){$+=n.substring(N,i),v=2;break}else v=6;i++}return $}function M(){if(r="",v=0,t=i,i>=o)return t=o,c=17;let $=n.charCodeAt(i);if(T($)){do i++,r+=String.fromCharCode($),$=n.charCodeAt(i);while(T($));return c=15}if(E($))return i++,r+=String.fromCharCode($),$===13&&n.charCodeAt(i)===10&&(i++,r+=`
`),c=14;switch($){case 123:return i++,c=1;case 125:return i++,c=2;case 91:return i++,c=3;case 93:return i++,c=4;case 58:return i++,c=6;case 44:return i++,c=5;case 34:return i++,r=W(),c=10;case 47:{const N=i-1;if(n.charCodeAt(i+1)===47){for(i+=2;i<o&&!E(n.charCodeAt(i));)i++;return r=n.substring(N,i),c=12}if(n.charCodeAt(i+1)===42){i+=2;const K=o-1;let V=!1;for(;i<K;){if(n.charCodeAt(i)===42&&n.charCodeAt(i+1)===47){i+=2,V=!0;break}i++}return V||(i++,v=1),r=n.substring(N,i),c=13}return r+=String.fromCharCode($),i++,c=16}case 45:if(r+=String.fromCharCode($),i++,i===o||!A(n.charCodeAt(i)))return c=16;case 48:case 49:case 50:case 51:case 52:case 53:case 54:case 55:case 56:case 57:return r+=U(),c=11;default:for(;i<o&&S($);)i++,$=n.charCodeAt(i);if(t!==i){switch(r=n.substring(t,i),r){case"true":return c=8;case"false":return c=9;case"null":return c=7}return c=16}return r+=String.fromCharCode($),i++,c=16}}function S($){if(T($)||E($))return!1;switch($){case 125:case 93:case 123:case 91:case 34:case 58:case 44:case 47:return!1}return!0}function z(){let $;do $=M();while($>=12&&$<=15);return $}return{setPosition:D,getPosition:()=>i,scan:u?z:M,getToken:()=>c,getTokenValue:()=>r,getTokenOffset:()=>t,getTokenLength:()=>i-t,getTokenError:()=>v}}e.createScanner=C;function T(n){return n===32||n===9||n===11||n===12||n===160||n===5760||n>=8192&&n<=8203||n===8239||n===8287||n===12288||n===65279}function E(n){return n===10||n===13||n===8232||n===8233}function A(n){return n>=48&&n<=57}var R;(function(n){n[n.nullCharacter=0]="nullCharacter",n[n.maxAsciiCharacter=127]="maxAsciiCharacter",n[n.lineFeed=10]="lineFeed",n[n.carriageReturn=13]="carriageReturn",n[n.lineSeparator=8232]="lineSeparator",n[n.paragraphSeparator=8233]="paragraphSeparator",n[n.nextLine=133]="nextLine",n[n.space=32]="space",n[n.nonBreakingSpace=160]="nonBreakingSpace",n[n.enQuad=8192]="enQuad",n[n.emQuad=8193]="emQuad",n[n.enSpace=8194]="enSpace",n[n.emSpace=8195]="emSpace",n[n.threePerEmSpace=8196]="threePerEmSpace",n[n.fourPerEmSpace=8197]="fourPerEmSpace",n[n.sixPerEmSpace=8198]="sixPerEmSpace",n[n.figureSpace=8199]="figureSpace",n[n.punctuationSpace=8200]="punctuationSpace",n[n.thinSpace=8201]="thinSpace",n[n.hairSpace=8202]="hairSpace",n[n.zeroWidthSpace=8203]="zeroWidthSpace",n[n.narrowNoBreakSpace=8239]="narrowNoBreakSpace",n[n.ideographicSpace=12288]="ideographicSpace",n[n.mathematicalSpace=8287]="mathematicalSpace",n[n.ogham=5760]="ogham",n[n._=95]="_",n[n.$=36]="$",n[n._0=48]="_0",n[n._1=49]="_1",n[n._2=50]="_2",n[n._3=51]="_3",n[n._4=52]="_4",n[n._5=53]="_5",n[n._6=54]="_6",n[n._7=55]="_7",n[n._8=56]="_8",n[n._9=57]="_9",n[n.a=97]="a",n[n.b=98]="b",n[n.c=99]="c",n[n.d=100]="d",n[n.e=101]="e",n[n.f=102]="f",n[n.g=103]="g",n[n.h=104]="h",n[n.i=105]="i",n[n.j=106]="j",n[n.k=107]="k",n[n.l=108]="l",n[n.m=109]="m",n[n.n=110]="n",n[n.o=111]="o",n[n.p=112]="p",n[n.q=113]="q",n[n.r=114]="r",n[n.s=115]="s",n[n.t=116]="t",n[n.u=117]="u",n[n.v=118]="v",n[n.w=119]="w",n[n.x=120]="x",n[n.y=121]="y",n[n.z=122]="z",n[n.A=65]="A",n[n.B=66]="B",n[n.C=67]="C",n[n.D=68]="D",n[n.E=69]="E",n[n.F=70]="F",n[n.G=71]="G",n[n.H=72]="H",n[n.I=73]="I",n[n.J=74]="J",n[n.K=75]="K",n[n.L=76]="L",n[n.M=77]="M",n[n.N=78]="N",n[n.O=79]="O",n[n.P=80]="P",n[n.Q=81]="Q",n[n.R=82]="R",n[n.S=83]="S",n[n.T=84]="T",n[n.U=85]="U",n[n.V=86]="V",n[n.W=87]="W",n[n.X=88]="X",n[n.Y=89]="Y",n[n.Z=90]="Z",n[n.ampersand=38]="ampersand",n[n.asterisk=42]="asterisk",n[n.at=64]="at",n[n.backslash=92]="backslash",n[n.bar=124]="bar",n[n.caret=94]="caret",n[n.closeBrace=125]="closeBrace",n[n.closeBracket=93]="closeBracket",n[n.closeParen=41]="closeParen",n[n.colon=58]="colon",n[n.comma=44]="comma",n[n.dot=46]="dot",n[n.doubleQuote=34]="doubleQuote",n[n.equals=61]="equals",n[n.exclamation=33]="exclamation",n[n.greaterThan=62]="greaterThan",n[n.lessThan=60]="lessThan",n[n.minus=45]="minus",n[n.openBrace=123]="openBrace",n[n.openBracket=91]="openBracket",n[n.openParen=40]="openParen",n[n.percent=37]="percent",n[n.plus=43]="plus",n[n.question=63]="question",n[n.semicolon=59]="semicolon",n[n.singleQuote=39]="singleQuote",n[n.slash=47]="slash",n[n.tilde=126]="tilde",n[n.backspace=8]="backspace",n[n.formFeed=12]="formFeed",n[n.byteOrderMark=65279]="byteOrderMark",n[n.tab=9]="tab",n[n.verticalTab=11]="verticalTab"})(R||(R={}));function y(n,u){const i=[],o=new Object;let r;const t={value:{},offset:0,length:0,type:"object",parent:void 0};let c=!1;function v(g,D,U,W){t.value=g,t.offset=D,t.length=U,t.type=W,t.colonOffset=void 0,r=t}try{P(n,{onObjectBegin:(g,D)=>{if(u<=g)throw o;r=void 0,c=u>g,i.push("")},onObjectProperty:(g,D,U)=>{if(u<D||(v(g,D,U,"property"),i[i.length-1]=g,u<=D+U))throw o},onObjectEnd:(g,D)=>{if(u<=g)throw o;r=void 0,i.pop()},onArrayBegin:(g,D)=>{if(u<=g)throw o;r=void 0,i.push(0)},onArrayEnd:(g,D)=>{if(u<=g)throw o;r=void 0,i.pop()},onLiteralValue:(g,D,U)=>{if(u<D||(v(g,D,U,_(g)),u<=D+U))throw o},onSeparator:(g,D,U)=>{if(u<=D)throw o;if(g===":"&&r&&r.type==="property")r.colonOffset=D,c=!1,r=void 0;else if(g===","){const W=i[i.length-1];typeof W=="number"?i[i.length-1]=W+1:(c=!0,i[i.length-1]=""),r=void 0}}})}catch(g){if(g!==o)throw g}return{path:i,previousNode:r,isAtPropertyKey:c,matches:g=>{let D=0;for(let U=0;D<g.length&&U<i.length;U++)if(g[D]===i[U]||g[D]==="*")D++;else if(g[D]!=="**")return!1;return D===g.length}}}e.getLocation=y;function m(n,u=[],i=L.DEFAULT){let o=null,r=[];const t=[];function c(g){Array.isArray(r)?r.push(g):o!==null&&(r[o]=g)}return P(n,{onObjectBegin:()=>{const g={};c(g),t.push(r),r=g,o=null},onObjectProperty:g=>{o=g},onObjectEnd:()=>{r=t.pop()},onArrayBegin:()=>{const g=[];c(g),t.push(r),r=g,o=null},onArrayEnd:()=>{r=t.pop()},onLiteralValue:c,onError:(g,D,U)=>{u.push({error:g,offset:D,length:U})}},i),r[0]}e.parse=m;function I(n,u=[],i=L.DEFAULT){let o={type:"array",offset:-1,length:-1,children:[],parent:void 0};function r(g){o.type==="property"&&(o.length=g-o.offset,o=o.parent)}function t(g){return o.children.push(g),g}P(n,{onObjectBegin:g=>{o=t({type:"object",offset:g,length:-1,parent:o,children:[]})},onObjectProperty:(g,D,U)=>{o=t({type:"property",offset:D,length:-1,parent:o,children:[]}),o.children.push({type:"string",value:g,offset:D,length:U,parent:o})},onObjectEnd:(g,D)=>{o.length=g+D-o.offset,o=o.parent,r(g+D)},onArrayBegin:(g,D)=>{o=t({type:"array",offset:g,length:-1,parent:o,children:[]})},onArrayEnd:(g,D)=>{o.length=g+D-o.offset,o=o.parent,r(g+D)},onLiteralValue:(g,D,U)=>{t({type:_(g),offset:D,length:U,parent:o,value:g}),r(D+U)},onSeparator:(g,D,U)=>{o.type==="property"&&(g===":"?o.colonOffset=D:g===","&&r(D))},onError:(g,D,U)=>{u.push({error:g,offset:D,length:U})}},i);const v=o.children[0];return v&&delete v.parent,v}e.parseTree=I;function f(n,u){if(!n)return;let i=n;for(const o of u)if(typeof o=="string"){if(i.type!=="object"||!Array.isArray(i.children))return;let r=!1;for(const t of i.children)if(Array.isArray(t.children)&&t.children[0].value===o){i=t.children[1],r=!0;break}if(!r)return}else{const r=o;if(i.type!=="array"||r<0||!Array.isArray(i.children)||r>=i.children.length)return;i=i.children[r]}return i}e.findNodeAtLocation=f;function h(n){if(!n.parent||!n.parent.children)return[];const u=h(n.parent);if(n.parent.type==="property"){const i=n.parent.children[0].value;u.push(i)}else if(n.parent.type==="array"){const i=n.parent.children.indexOf(n);i!==-1&&u.push(i)}return u}e.getNodePath=h;function d(n){switch(n.type){case"array":return n.children.map(d);case"object":{const u=Object.create(null);for(const i of n.children){const o=i.children[1];o&&(u[i.children[0].value]=d(o))}return u}case"null":case"string":case"number":case"boolean":return n.value;default:return}}e.getNodeValue=d;function a(n,u,i=!1){return u>=n.offset&&u<n.offset+n.length||i&&u===n.offset+n.length}e.contains=a;function w(n,u,i=!1){if(a(n,u,i)){const o=n.children;if(Array.isArray(o))for(let r=0;r<o.length&&o[r].offset<=u;r++){const t=w(o[r],u,i);if(t)return t}return n}}e.findNodeAtOffset=w;function P(n,u,i=L.DEFAULT){const o=C(n,!1);function r(Ee){return Ee?()=>Ee(o.getTokenOffset(),o.getTokenLength()):()=>!0}function t(Ee){return Ee?be=>Ee(be,o.getTokenOffset(),o.getTokenLength()):()=>!0}const c=r(u.onObjectBegin),v=t(u.onObjectProperty),g=r(u.onObjectEnd),D=r(u.onArrayBegin),U=r(u.onArrayEnd),W=t(u.onLiteralValue),M=t(u.onSeparator),S=r(u.onComment),z=t(u.onError),$=i&&i.disallowComments,N=i&&i.allowTrailingComma;function K(){for(;;){const Ee=o.scan();switch(o.getTokenError()){case 4:V(14);break;case 5:V(15);break;case 3:V(13);break;case 1:$||V(11);break;case 2:V(12);break;case 6:V(16);break}switch(Ee){case 12:case 13:$?V(10):S();break;case 16:V(1);break;case 15:case 14:break;default:return Ee}}}function V(Ee,be=[],te=[]){if(z(Ee),be.length+te.length>0){let ve=o.getToken();for(;ve!==17;){if(be.indexOf(ve)!==-1){K();break}else if(te.indexOf(ve)!==-1)break;ve=K()}}}function F(Ee){const be=o.getTokenValue();return Ee?W(be):v(be),K(),!0}function ne(){switch(o.getToken()){case 11:{let Ee=0;try{Ee=JSON.parse(o.getTokenValue()),typeof Ee!="number"&&(V(2),Ee=0)}catch{V(2)}W(Ee);break}case 7:W(null);break;case 8:W(!0);break;case 9:W(!1);break;default:return!1}return K(),!0}function ce(){return o.getToken()!==10?(V(3,[],[2,5]),!1):(F(!1),o.getToken()===6?(M(":"),K(),ie()||V(4,[],[2,5])):V(5,[],[2,5]),!0)}function re(){c(),K();let Ee=!1;for(;o.getToken()!==2&&o.getToken()!==17;){if(o.getToken()===5){if(Ee||V(4,[],[]),M(","),K(),o.getToken()===2&&N)break}else Ee&&V(6,[],[]);ce()||V(4,[],[2,5]),Ee=!0}return g(),o.getToken()!==2?V(7,[2],[]):K(),!0}function fe(){D(),K();let Ee=!1;for(;o.getToken()!==4&&o.getToken()!==17;){if(o.getToken()===5){if(Ee||V(4,[],[]),M(","),K(),o.getToken()===4&&N)break}else Ee&&V(6,[],[]);ie()||V(4,[],[4,5]),Ee=!0}return U(),o.getToken()!==4?V(8,[4],[]):K(),!0}function ie(){switch(o.getToken()){case 3:return fe();case 1:return re();case 10:return F(!0);default:return ne()}}return K(),o.getToken()===17?i.allowEmptyContent?!0:(V(4,[],[]),!1):ie()?(o.getToken()!==17&&V(9,[],[]),!0):(V(4,[],[]),!1)}e.visit=P;function l(n,u){const i=C(n),o=[];let r,t=0,c;do switch(c=i.getPosition(),r=i.scan(),r){case 12:case 13:case 17:t!==c&&o.push(n.substring(t,c)),u!==void 0&&o.push(i.getTokenValue().replace(/[^\r\n]/g,u)),t=i.getPosition();break}while(r!==17);return o.join("")}e.stripComments=l;function _(n){switch(typeof n){case"boolean":return"boolean";case"number":return"number";case"string":return"string";case"object":{if(n){if(Array.isArray(n))return"array"}else return"null";return"object"}default:return"null"}}e.getNodeType=_}),function(ee,e){typeof exports=="object"&&typeof module!="undefined"?e(exports):typeof define=="function"&&define.amd?define(ye[105],Ce([0]),e):(ee=typeof globalThis!="undefined"?globalThis:ee||self,e(ee.marked={}))}(this,function(ee){"use strict";function e(Ie,Se){for(var Te=0;Te<Se.length;Te++){var ae=Se[Te];ae.enumerable=ae.enumerable||!1,ae.configurable=!0,"value"in ae&&(ae.writable=!0),Object.defineProperty(Ie,ae.key,ae)}}function s(Ie,Se,Te){return Se&&e(Ie.prototype,Se),Te&&e(Ie,Te),Object.defineProperty(Ie,"prototype",{writable:!1}),Ie}function p(Ie,Se){if(!!Ie){if(typeof Ie=="string")return b(Ie,Se);var Te=Object.prototype.toString.call(Ie).slice(8,-1);if(Te==="Object"&&Ie.constructor&&(Te=Ie.constructor.name),Te==="Map"||Te==="Set")return Array.from(Ie);if(Te==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(Te))return b(Ie,Se)}}function b(Ie,Se){(Se==null||Se>Ie.length)&&(Se=Ie.length);for(var Te=0,ae=new Array(Se);Te<Se;Te++)ae[Te]=Ie[Te];return ae}function L(Ie,Se){var Te=typeof Symbol!="undefined"&&Ie[Symbol.iterator]||Ie["@@iterator"];if(Te)return(Te=Te.call(Ie)).next.bind(Te);if(Array.isArray(Ie)||(Te=p(Ie))||Se&&Ie&&typeof Ie.length=="number"){Te&&(Ie=Te);var ae=0;return function(){return ae>=Ie.length?{done:!0}:{done:!1,value:Ie[ae++]}}}throw new TypeError(`Invalid attempt to iterate non-iterable instance.
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function C(){return{baseUrl:null,breaks:!1,extensions:null,gfm:!0,headerIds:!0,headerPrefix:"",highlight:null,langPrefix:"language-",mangle:!0,pedantic:!1,renderer:null,sanitize:!1,sanitizer:null,silent:!1,smartLists:!1,smartypants:!1,tokenizer:null,walkTokens:null,xhtml:!1}}ee.defaults=C();function T(Ie){ee.defaults=Ie}var E=/[&<>"']/,A=/[&<>"']/g,R=/[<>"']|&(?!#?\w+;)/,y=/[<>"']|&(?!#?\w+;)/g,m={"&":"&","<":"<",">":">",'"':""","'":"'"},I=function(Se){return m[Se]};function f(Ie,Se){if(Se){if(E.test(Ie))return Ie.replace(A,I)}else if(R.test(Ie))return Ie.replace(y,I);return Ie}var h=/&(#(?:\d+)|(?:#x[0-9A-Fa-f]+)|(?:\w+));?/ig;function d(Ie){return Ie.replace(h,function(Se,Te){return Te=Te.toLowerCase(),Te==="colon"?":":Te.charAt(0)==="#"?Te.charAt(1)==="x"?String.fromCharCode(parseInt(Te.substring(2),16)):String.fromCharCode(+Te.substring(1)):""})}var a=/(^|[^\[])\^/g;function w(Ie,Se){Ie=typeof Ie=="string"?Ie:Ie.source,Se=Se||"";var Te={replace:function(le,X){return X=X.source||X,X=X.replace(a,"$1"),Ie=Ie.replace(le,X),Te},getRegex:function(){return new RegExp(Ie,Se)}};return Te}var P=/[^\w:]/g,l=/^$|^[a-z][a-z0-9+.-]*:|^[?#]/i;function _(Ie,Se,Te){if(Ie){var ae;try{ae=decodeURIComponent(d(Te)).replace(P,"").toLowerCase()}catch{return null}if(ae.indexOf("javascript:")===0||ae.indexOf("vbscript:")===0||ae.indexOf("data:")===0)return null}Se&&!l.test(Te)&&(Te=r(Se,Te));try{Te=encodeURI(Te).replace(/%25/g,"%")}catch{return null}return Te}var n={},u=/^[^:]+:\/*[^/]*$/,i=/^([^:]+:)[\s\S]*$/,o=/^([^:]+:\/*[^/]*)[\s\S]*$/;function r(Ie,Se){n[" "+Ie]||(u.test(Ie)?n[" "+Ie]=Ie+"/":n[" "+Ie]=g(Ie,"/",!0)),Ie=n[" "+Ie];var Te=Ie.indexOf(":")===-1;return Se.substring(0,2)==="//"?Te?Se:Ie.replace(i,"$1")+Se:Se.charAt(0)==="/"?Te?Se:Ie.replace(o,"$1")+Se:Ie+Se}var t={exec:function(){}};function c(Ie){for(var Se=1,Te,ae;Se<arguments.length;Se++){Te=arguments[Se];for(ae in Te)Object.prototype.hasOwnProperty.call(Te,ae)&&(Ie[ae]=Te[ae])}return Ie}function v(Ie,Se){var Te=Ie.replace(/\|/g,function(X,J,k){for(var B=!1,H=J;--H>=0&&k[H]==="\\";)B=!B;return B?"|":" |"}),ae=Te.split(/ \|/),le=0;if(ae[0].trim()||ae.shift(),ae.length>0&&!ae[ae.length-1].trim()&&ae.pop(),ae.length>Se)ae.splice(Se);else for(;ae.length<Se;)ae.push("");for(;le<ae.length;le++)ae[le]=ae[le].trim().replace(/\\\|/g,"|");return ae}function g(Ie,Se,Te){var ae=Ie.length;if(ae===0)return"";for(var le=0;le<ae;){var X=Ie.charAt(ae-le-1);if(X===Se&&!Te)le++;else if(X!==Se&&Te)le++;else break}return Ie.slice(0,ae-le)}function D(Ie,Se){if(Ie.indexOf(Se[1])===-1)return-1;for(var Te=Ie.length,ae=0,le=0;le<Te;le++)if(Ie[le]==="\\")le++;else if(Ie[le]===Se[0])ae++;else if(Ie[le]===Se[1]&&(ae--,ae<0))return le;return-1}function U(Ie){Ie&&Ie.sanitize&&!Ie.silent&&console.warn("marked(): sanitize and sanitizer parameters are deprecated since version 0.7.0, should not be used and will be removed in the future. Read more here: https://marked.js.org/#/USING_ADVANCED.md#options")}function W(Ie,Se){if(Se<1)return"";for(var Te="";Se>1;)Se&1&&(Te+=Ie),Se>>=1,Ie+=Ie;return Te+Ie}function M(Ie,Se,Te,ae){var le=Se.href,X=Se.title?f(Se.title):null,J=Ie[1].replace(/\\([\[\]])/g,"$1");if(Ie[0].charAt(0)!=="!"){ae.state.inLink=!0;var k={type:"link",raw:Te,href:le,title:X,text:J,tokens:ae.inlineTokens(J,[])};return ae.state.inLink=!1,k}return{type:"image",raw:Te,href:le,title:X,text:f(J)}}function S(Ie,Se){var Te=Ie.match(/^(\s+)(?:```)/);if(Te===null)return Se;var ae=Te[1];return Se.split(`
`).map(function(le){var X=le.match(/^\s+/);if(X===null)return le;var J=X[0];return J.length>=ae.length?le.slice(ae.length):le}).join(`
`)}var z=function(){function Ie(Te){this.options=Te||ee.defaults}var Se=Ie.prototype;return Se.space=function(ae){var le=this.rules.block.newline.exec(ae);if(le&&le[0].length>0)return{type:"space",raw:le[0]}},Se.code=function(ae){var le=this.rules.block.code.exec(ae);if(le){var X=le[0].replace(/^ {1,4}/gm,"");return{type:"code",raw:le[0],codeBlockStyle:"indented",text:this.options.pedantic?X:g(X,`
`)}}},Se.fences=function(ae){var le=this.rules.block.fences.exec(ae);if(le){var X=le[0],J=S(X,le[3]||"");return{type:"code",raw:X,lang:le[2]?le[2].trim():le[2],text:J}}},Se.heading=function(ae){var le=this.rules.block.heading.exec(ae);if(le){var X=le[2].trim();if(/#$/.test(X)){var J=g(X,"#");(this.options.pedantic||!J||/ $/.test(J))&&(X=J.trim())}var k={type:"heading",raw:le[0],depth:le[1].length,text:X,tokens:[]};return this.lexer.inline(k.text,k.tokens),k}},Se.hr=function(ae){var le=this.rules.block.hr.exec(ae);if(le)return{type:"hr",raw:le[0]}},Se.blockquote=function(ae){var le=this.rules.block.blockquote.exec(ae);if(le){var X=le[0].replace(/^ *>[ \t]?/gm,"");return{type:"blockquote",raw:le[0],tokens:this.lexer.blockTokens(X,[]),text:X}}},Se.list=function(ae){var le=this.rules.block.list.exec(ae);if(le){var X,J,k,B,H,j,oe,ue,Z,pe,ge,Ne,Be=le[1].trim(),Ze=Be.length>1,Ke={type:"list",raw:"",ordered:Ze,start:Ze?+Be.slice(0,-1):"",loose:!1,items:[]};Be=Ze?"\\d{1,9}\\"+Be.slice(-1):"\\"+Be,this.options.pedantic&&(Be=Ze?Be:"[*+-]");for(var ke=new RegExp("^( {0,3}"+Be+")((?:[ ][^\\n]*)?(?:\\n|$))");ae&&(Ne=!1,!(!(le=ke.exec(ae))||this.rules.block.hr.test(ae)));){if(X=le[0],ae=ae.substring(X.length),ue=le[2].split(`
`,1)[0],Z=ae.split(`
`,1)[0],this.options.pedantic?(B=2,ge=ue.trimLeft()):(B=le[2].search(/[^ ]/),B=B>4?1:B,ge=ue.slice(B),B+=le[1].length),j=!1,!ue&&/^ *$/.test(Z)&&(X+=Z+`
`,ae=ae.substring(Z.length+1),Ne=!0),!Ne)for(var nt=new RegExp("^ {0,"+Math.min(3,B-1)+"}(?:[*+-]|\\d{1,9}[.)])((?: [^\\n]*)?(?:\\n|$))"),G=new RegExp("^ {0,"+Math.min(3,B-1)+"}((?:- *){3,}|(?:_ *){3,}|(?:\\* *){3,})(?:\\n+|$)");ae&&(pe=ae.split(`
`,1)[0],ue=pe,this.options.pedantic&&(ue=ue.replace(/^ {1,4}(?=( {4})*[^ ])/g," ")),!(nt.test(ue)||G.test(ae)));){if(ue.search(/[^ ]/)>=B||!ue.trim())ge+=`
`+ue.slice(B);else if(!j)ge+=`
`+ue;else break;!j&&!ue.trim()&&(j=!0),X+=pe+`
`,ae=ae.substring(pe.length+1)}Ke.loose||(oe?Ke.loose=!0:/\n *\n *$/.test(X)&&(oe=!0)),this.options.gfm&&(J=/^\[[ xX]\] /.exec(ge),J&&(k=J[0]!=="[ ] ",ge=ge.replace(/^\[[ xX]\] +/,""))),Ke.items.push({type:"list_item",raw:X,task:!!J,checked:k,loose:!1,text:ge}),Ke.raw+=X}Ke.items[Ke.items.length-1].raw=X.trimRight(),Ke.items[Ke.items.length-1].text=ge.trimRight(),Ke.raw=Ke.raw.trimRight();var Q=Ke.items.length;for(H=0;H<Q;H++){this.lexer.state.top=!1,Ke.items[H].tokens=this.lexer.blockTokens(Ke.items[H].text,[]);var he=Ke.items[H].tokens.filter(function(We){return We.type==="space"}),Ue=he.every(function(We){for(var et=We.raw.split(""),je=0,He=L(et),it;!(it=He()).done;){var rt=it.value;if(rt===`
`&&(je+=1),je>1)return!0}return!1});!Ke.loose&&he.length&&Ue&&(Ke.loose=!0,Ke.items[H].loose=!0)}return Ke}},Se.html=function(ae){var le=this.rules.block.html.exec(ae);if(le){var X={type:"html",raw:le[0],pre:!this.options.sanitizer&&(le[1]==="pre"||le[1]==="script"||le[1]==="style"),text:le[0]};return this.options.sanitize&&(X.type="paragraph",X.text=this.options.sanitizer?this.options.sanitizer(le[0]):f(le[0]),X.tokens=[],this.lexer.inline(X.text,X.tokens)),X}},Se.def=function(ae){var le=this.rules.block.def.exec(ae);if(le){le[3]&&(le[3]=le[3].substring(1,le[3].length-1));var X=le[1].toLowerCase().replace(/\s+/g," ");return{type:"def",tag:X,raw:le[0],href:le[2],title:le[3]}}},Se.table=function(ae){var le=this.rules.block.table.exec(ae);if(le){var X={type:"table",header:v(le[1]).map(function(oe){return{text:oe}}),align:le[2].replace(/^ *|\| *$/g,"").split(/ *\| */),rows:le[3]&&le[3].trim()?le[3].replace(/\n[ \t]*$/,"").split(`
`):[]};if(X.header.length===X.align.length){X.raw=le[0];var J=X.align.length,k,B,H,j;for(k=0;k<J;k++)/^ *-+: *$/.test(X.align[k])?X.align[k]="right":/^ *:-+: *$/.test(X.align[k])?X.align[k]="center":/^ *:-+ *$/.test(X.align[k])?X.align[k]="left":X.align[k]=null;for(J=X.rows.length,k=0;k<J;k++)X.rows[k]=v(X.rows[k],X.header.length).map(function(oe){return{text:oe}});for(J=X.header.length,B=0;B<J;B++)X.header[B].tokens=[],this.lexer.inline(X.header[B].text,X.header[B].tokens);for(J=X.rows.length,B=0;B<J;B++)for(j=X.rows[B],H=0;H<j.length;H++)j[H].tokens=[],this.lexer.inline(j[H].text,j[H].tokens);return X}}},Se.lheading=function(ae){var le=this.rules.block.lheading.exec(ae);if(le){var X={type:"heading",raw:le[0],depth:le[2].charAt(0)==="="?1:2,text:le[1],tokens:[]};return this.lexer.inline(X.text,X.tokens),X}},Se.paragraph=function(ae){var le=this.rules.block.paragraph.exec(ae);if(le){var X={type:"paragraph",raw:le[0],text:le[1].charAt(le[1].length-1)===`
`?le[1].slice(0,-1):le[1],tokens:[]};return this.lexer.inline(X.text,X.tokens),X}},Se.text=function(ae){var le=this.rules.block.text.exec(ae);if(le){var X={type:"text",raw:le[0],text:le[0],tokens:[]};return this.lexer.inline(X.text,X.tokens),X}},Se.escape=function(ae){var le=this.rules.inline.escape.exec(ae);if(le)return{type:"escape",raw:le[0],text:f(le[1])}},Se.tag=function(ae){var le=this.rules.inline.tag.exec(ae);if(le)return!this.lexer.state.inLink&&/^<a /i.test(le[0])?this.lexer.state.inLink=!0:this.lexer.state.inLink&&/^<\/a>/i.test(le[0])&&(this.lexer.state.inLink=!1),!this.lexer.state.inRawBlock&&/^<(pre|code|kbd|script)(\s|>)/i.test(le[0])?this.lexer.state.inRawBlock=!0:this.lexer.state.inRawBlock&&/^<\/(pre|code|kbd|script)(\s|>)/i.test(le[0])&&(this.lexer.state.inRawBlock=!1),{type:this.options.sanitize?"text":"html",raw:le[0],inLink:this.lexer.state.inLink,inRawBlock:this.lexer.state.inRawBlock,text:this.options.sanitize?this.options.sanitizer?this.options.sanitizer(le[0]):f(le[0]):le[0]}},Se.link=function(ae){var le=this.rules.inline.link.exec(ae);if(le){var X=le[2].trim();if(!this.options.pedantic&&/^</.test(X)){if(!/>$/.test(X))return;var J=g(X.slice(0,-1),"\\");if((X.length-J.length)%2==0)return}else{var k=D(le[2],"()");if(k>-1){var B=le[0].indexOf("!")===0?5:4,H=B+le[1].length+k;le[2]=le[2].substring(0,k),le[0]=le[0].substring(0,H).trim(),le[3]=""}}var j=le[2],oe="";if(this.options.pedantic){var ue=/^([^'"]*[^\s])\s+(['"])(.*)\2/.exec(j);ue&&(j=ue[1],oe=ue[3])}else oe=le[3]?le[3].slice(1,-1):"";return j=j.trim(),/^</.test(j)&&(this.options.pedantic&&!/>$/.test(X)?j=j.slice(1):j=j.slice(1,-1)),M(le,{href:j&&j.replace(this.rules.inline._escapes,"$1"),title:oe&&oe.replace(this.rules.inline._escapes,"$1")},le[0],this.lexer)}},Se.reflink=function(ae,le){var X;if((X=this.rules.inline.reflink.exec(ae))||(X=this.rules.inline.nolink.exec(ae))){var J=(X[2]||X[1]).replace(/\s+/g," ");if(J=le[J.toLowerCase()],!J||!J.href){var k=X[0].charAt(0);return{type:"text",raw:k,text:k}}return M(X,J,X[0],this.lexer)}},Se.emStrong=function(ae,le,X){X===void 0&&(X="");var J=this.rules.inline.emStrong.lDelim.exec(ae);if(!!J&&!(J[3]&&X.match(/(?:[0-9A-Za-z\xAA\xB2\xB3\xB5\xB9\xBA\xBC-\xBE\xC0-\xD6\xD8-\xF6\xF8-\u02C1\u02C6-\u02D1\u02E0-\u02E4\u02EC\u02EE\u0370-\u0374\u0376\u0377\u037A-\u037D\u037F\u0386\u0388-\u038A\u038C\u038E-\u03A1\u03A3-\u03F5\u03F7-\u0481\u048A-\u052F\u0531-\u0556\u0559\u0560-\u0588\u05D0-\u05EA\u05EF-\u05F2\u0620-\u064A\u0660-\u0669\u066E\u066F\u0671-\u06D3\u06D5\u06E5\u06E6\u06EE-\u06FC\u06FF\u0710\u0712-\u072F\u074D-\u07A5\u07B1\u07C0-\u07EA\u07F4\u07F5\u07FA\u0800-\u0815\u081A\u0824\u0828\u0840-\u0858\u0860-\u086A\u0870-\u0887\u0889-\u088E\u08A0-\u08C9\u0904-\u0939\u093D\u0950\u0958-\u0961\u0966-\u096F\u0971-\u0980\u0985-\u098C\u098F\u0990\u0993-\u09A8\u09AA-\u09B0\u09B2\u09B6-\u09B9\u09BD\u09CE\u09DC\u09DD\u09DF-\u09E1\u09E6-\u09F1\u09F4-\u09F9\u09FC\u0A05-\u0A0A\u0A0F\u0A10\u0A13-\u0A28\u0A2A-\u0A30\u0A32\u0A33\u0A35\u0A36\u0A38\u0A39\u0A59-\u0A5C\u0A5E\u0A66-\u0A6F\u0A72-\u0A74\u0A85-\u0A8D\u0A8F-\u0A91\u0A93-\u0AA8\u0AAA-\u0AB0\u0AB2\u0AB3\u0AB5-\u0AB9\u0ABD\u0AD0\u0AE0\u0AE1\u0AE6-\u0AEF\u0AF9\u0B05-\u0B0C\u0B0F\u0B10\u0B13-\u0B28\u0B2A-\u0B30\u0B32\u0B33\u0B35-\u0B39\u0B3D\u0B5C\u0B5D\u0B5F-\u0B61\u0B66-\u0B6F\u0B71-\u0B77\u0B83\u0B85-\u0B8A\u0B8E-\u0B90\u0B92-\u0B95\u0B99\u0B9A\u0B9C\u0B9E\u0B9F\u0BA3\u0BA4\u0BA8-\u0BAA\u0BAE-\u0BB9\u0BD0\u0BE6-\u0BF2\u0C05-\u0C0C\u0C0E-\u0C10\u0C12-\u0C28\u0C2A-\u0C39\u0C3D\u0C58-\u0C5A\u0C5D\u0C60\u0C61\u0C66-\u0C6F\u0C78-\u0C7E\u0C80\u0C85-\u0C8C\u0C8E-\u0C90\u0C92-\u0CA8\u0CAA-\u0CB3\u0CB5-\u0CB9\u0CBD\u0CDD\u0CDE\u0CE0\u0CE1\u0CE6-\u0CEF\u0CF1\u0CF2\u0D04-\u0D0C\u0D0E-\u0D10\u0D12-\u0D3A\u0D3D\u0D4E\u0D54-\u0D56\u0D58-\u0D61\u0D66-\u0D78\u0D7A-\u0D7F\u0D85-\u0D96\u0D9A-\u0DB1\u0DB3-\u0DBB\u0DBD\u0DC0-\u0DC6\u0DE6-\u0DEF\u0E01-\u0E30\u0E32\u0E33\u0E40-\u0E46\u0E50-\u0E59\u0E81\u0E82\u0E84\u0E86-\u0E8A\u0E8C-\u0EA3\u0EA5\u0EA7-\u0EB0\u0EB2\u0EB3\u0EBD\u0EC0-\u0EC4\u0EC6\u0ED0-\u0ED9\u0EDC-\u0EDF\u0F00\u0F20-\u0F33\u0F40-\u0F47\u0F49-\u0F6C\u0F88-\u0F8C\u1000-\u102A\u103F-\u1049\u1050-\u1055\u105A-\u105D\u1061\u1065\u1066\u106E-\u1070\u1075-\u1081\u108E\u1090-\u1099\u10A0-\u10C5\u10C7\u10CD\u10D0-\u10FA\u10FC-\u1248\u124A-\u124D\u1250-\u1256\u1258\u125A-\u125D\u1260-\u1288\u128A-\u128D\u1290-\u12B0\u12B2-\u12B5\u12B8-\u12BE\u12C0\u12C2-\u12C5\u12C8-\u12D6\u12D8-\u1310\u1312-\u1315\u1318-\u135A\u1369-\u137C\u1380-\u138F\u13A0-\u13F5\u13F8-\u13FD\u1401-\u166C\u166F-\u167F\u1681-\u169A\u16A0-\u16EA\u16EE-\u16F8\u1700-\u1711\u171F-\u1731\u1740-\u1751\u1760-\u176C\u176E-\u1770\u1780-\u17B3\u17D7\u17DC\u17E0-\u17E9\u17F0-\u17F9\u1810-\u1819\u1820-\u1878\u1880-\u1884\u1887-\u18A8\u18AA\u18B0-\u18F5\u1900-\u191E\u1946-\u196D\u1970-\u1974\u1980-\u19AB\u19B0-\u19C9\u19D0-\u19DA\u1A00-\u1A16\u1A20-\u1A54\u1A80-\u1A89\u1A90-\u1A99\u1AA7\u1B05-\u1B33\u1B45-\u1B4C\u1B50-\u1B59\u1B83-\u1BA0\u1BAE-\u1BE5\u1C00-\u1C23\u1C40-\u1C49\u1C4D-\u1C7D\u1C80-\u1C88\u1C90-\u1CBA\u1CBD-\u1CBF\u1CE9-\u1CEC\u1CEE-\u1CF3\u1CF5\u1CF6\u1CFA\u1D00-\u1DBF\u1E00-\u1F15\u1F18-\u1F1D\u1F20-\u1F45\u1F48-\u1F4D\u1F50-\u1F57\u1F59\u1F5B\u1F5D\u1F5F-\u1F7D\u1F80-\u1FB4\u1FB6-\u1FBC\u1FBE\u1FC2-\u1FC4\u1FC6-\u1FCC\u1FD0-\u1FD3\u1FD6-\u1FDB\u1FE0-\u1FEC\u1FF2-\u1FF4\u1FF6-\u1FFC\u2070\u2071\u2074-\u2079\u207F-\u2089\u2090-\u209C\u2102\u2107\u210A-\u2113\u2115\u2119-\u211D\u2124\u2126\u2128\u212A-\u212D\u212F-\u2139\u213C-\u213F\u2145-\u2149\u214E\u2150-\u2189\u2460-\u249B\u24EA-\u24FF\u2776-\u2793\u2C00-\u2CE4\u2CEB-\u2CEE\u2CF2\u2CF3\u2CFD\u2D00-\u2D25\u2D27\u2D2D\u2D30-\u2D67\u2D6F\u2D80-\u2D96\u2DA0-\u2DA6\u2DA8-\u2DAE\u2DB0-\u2DB6\u2DB8-\u2DBE\u2DC0-\u2DC6\u2DC8-\u2DCE\u2DD0-\u2DD6\u2DD8-\u2DDE\u2E2F\u3005-\u3007\u3021-\u3029\u3031-\u3035\u3038-\u303C\u3041-\u3096\u309D-\u309F\u30A1-\u30FA\u30FC-\u30FF\u3105-\u312F\u3131-\u318E\u3192-\u3195\u31A0-\u31BF\u31F0-\u31FF\u3220-\u3229\u3248-\u324F\u3251-\u325F\u3280-\u3289\u32B1-\u32BF\u3400-\u4DBF\u4E00-\uA48C\uA4D0-\uA4FD\uA500-\uA60C\uA610-\uA62B\uA640-\uA66E\uA67F-\uA69D\uA6A0-\uA6EF\uA717-\uA71F\uA722-\uA788\uA78B-\uA7CA\uA7D0\uA7D1\uA7D3\uA7D5-\uA7D9\uA7F2-\uA801\uA803-\uA805\uA807-\uA80A\uA80C-\uA822\uA830-\uA835\uA840-\uA873\uA882-\uA8B3\uA8D0-\uA8D9\uA8F2-\uA8F7\uA8FB\uA8FD\uA8FE\uA900-\uA925\uA930-\uA946\uA960-\uA97C\uA984-\uA9B2\uA9CF-\uA9D9\uA9E0-\uA9E4\uA9E6-\uA9FE\uAA00-\uAA28\uAA40-\uAA42\uAA44-\uAA4B\uAA50-\uAA59\uAA60-\uAA76\uAA7A\uAA7E-\uAAAF\uAAB1\uAAB5\uAAB6\uAAB9-\uAABD\uAAC0\uAAC2\uAADB-\uAADD\uAAE0-\uAAEA\uAAF2-\uAAF4\uAB01-\uAB06\uAB09-\uAB0E\uAB11-\uAB16\uAB20-\uAB26\uAB28-\uAB2E\uAB30-\uAB5A\uAB5C-\uAB69\uAB70-\uABE2\uABF0-\uABF9\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uF900-\uFA6D\uFA70-\uFAD9\uFB00-\uFB06\uFB13-\uFB17\uFB1D\uFB1F-\uFB28\uFB2A-\uFB36\uFB38-\uFB3C\uFB3E\uFB40\uFB41\uFB43\uFB44\uFB46-\uFBB1\uFBD3-\uFD3D\uFD50-\uFD8F\uFD92-\uFDC7\uFDF0-\uFDFB\uFE70-\uFE74\uFE76-\uFEFC\uFF10-\uFF19\uFF21-\uFF3A\uFF41-\uFF5A\uFF66-\uFFBE\uFFC2-\uFFC7\uFFCA-\uFFCF\uFFD2-\uFFD7\uFFDA-\uFFDC]|\uD800[\uDC00-\uDC0B\uDC0D-\uDC26\uDC28-\uDC3A\uDC3C\uDC3D\uDC3F-\uDC4D\uDC50-\uDC5D\uDC80-\uDCFA\uDD07-\uDD33\uDD40-\uDD78\uDD8A\uDD8B\uDE80-\uDE9C\uDEA0-\uDED0\uDEE1-\uDEFB\uDF00-\uDF23\uDF2D-\uDF4A\uDF50-\uDF75\uDF80-\uDF9D\uDFA0-\uDFC3\uDFC8-\uDFCF\uDFD1-\uDFD5]|\uD801[\uDC00-\uDC9D\uDCA0-\uDCA9\uDCB0-\uDCD3\uDCD8-\uDCFB\uDD00-\uDD27\uDD30-\uDD63\uDD70-\uDD7A\uDD7C-\uDD8A\uDD8C-\uDD92\uDD94\uDD95\uDD97-\uDDA1\uDDA3-\uDDB1\uDDB3-\uDDB9\uDDBB\uDDBC\uDE00-\uDF36\uDF40-\uDF55\uDF60-\uDF67\uDF80-\uDF85\uDF87-\uDFB0\uDFB2-\uDFBA]|\uD802[\uDC00-\uDC05\uDC08\uDC0A-\uDC35\uDC37\uDC38\uDC3C\uDC3F-\uDC55\uDC58-\uDC76\uDC79-\uDC9E\uDCA7-\uDCAF\uDCE0-\uDCF2\uDCF4\uDCF5\uDCFB-\uDD1B\uDD20-\uDD39\uDD80-\uDDB7\uDDBC-\uDDCF\uDDD2-\uDE00\uDE10-\uDE13\uDE15-\uDE17\uDE19-\uDE35\uDE40-\uDE48\uDE60-\uDE7E\uDE80-\uDE9F\uDEC0-\uDEC7\uDEC9-\uDEE4\uDEEB-\uDEEF\uDF00-\uDF35\uDF40-\uDF55\uDF58-\uDF72\uDF78-\uDF91\uDFA9-\uDFAF]|\uD803[\uDC00-\uDC48\uDC80-\uDCB2\uDCC0-\uDCF2\uDCFA-\uDD23\uDD30-\uDD39\uDE60-\uDE7E\uDE80-\uDEA9\uDEB0\uDEB1\uDF00-\uDF27\uDF30-\uDF45\uDF51-\uDF54\uDF70-\uDF81\uDFB0-\uDFCB\uDFE0-\uDFF6]|\uD804[\uDC03-\uDC37\uDC52-\uDC6F\uDC71\uDC72\uDC75\uDC83-\uDCAF\uDCD0-\uDCE8\uDCF0-\uDCF9\uDD03-\uDD26\uDD36-\uDD3F\uDD44\uDD47\uDD50-\uDD72\uDD76\uDD83-\uDDB2\uDDC1-\uDDC4\uDDD0-\uDDDA\uDDDC\uDDE1-\uDDF4\uDE00-\uDE11\uDE13-\uDE2B\uDE80-\uDE86\uDE88\uDE8A-\uDE8D\uDE8F-\uDE9D\uDE9F-\uDEA8\uDEB0-\uDEDE\uDEF0-\uDEF9\uDF05-\uDF0C\uDF0F\uDF10\uDF13-\uDF28\uDF2A-\uDF30\uDF32\uDF33\uDF35-\uDF39\uDF3D\uDF50\uDF5D-\uDF61]|\uD805[\uDC00-\uDC34\uDC47-\uDC4A\uDC50-\uDC59\uDC5F-\uDC61\uDC80-\uDCAF\uDCC4\uDCC5\uDCC7\uDCD0-\uDCD9\uDD80-\uDDAE\uDDD8-\uDDDB\uDE00-\uDE2F\uDE44\uDE50-\uDE59\uDE80-\uDEAA\uDEB8\uDEC0-\uDEC9\uDF00-\uDF1A\uDF30-\uDF3B\uDF40-\uDF46]|\uD806[\uDC00-\uDC2B\uDCA0-\uDCF2\uDCFF-\uDD06\uDD09\uDD0C-\uDD13\uDD15\uDD16\uDD18-\uDD2F\uDD3F\uDD41\uDD50-\uDD59\uDDA0-\uDDA7\uDDAA-\uDDD0\uDDE1\uDDE3\uDE00\uDE0B-\uDE32\uDE3A\uDE50\uDE5C-\uDE89\uDE9D\uDEB0-\uDEF8]|\uD807[\uDC00-\uDC08\uDC0A-\uDC2E\uDC40\uDC50-\uDC6C\uDC72-\uDC8F\uDD00-\uDD06\uDD08\uDD09\uDD0B-\uDD30\uDD46\uDD50-\uDD59\uDD60-\uDD65\uDD67\uDD68\uDD6A-\uDD89\uDD98\uDDA0-\uDDA9\uDEE0-\uDEF2\uDFB0\uDFC0-\uDFD4]|\uD808[\uDC00-\uDF99]|\uD809[\uDC00-\uDC6E\uDC80-\uDD43]|\uD80B[\uDF90-\uDFF0]|[\uD80C\uD81C-\uD820\uD822\uD840-\uD868\uD86A-\uD86C\uD86F-\uD872\uD874-\uD879\uD880-\uD883][\uDC00-\uDFFF]|\uD80D[\uDC00-\uDC2E]|\uD811[\uDC00-\uDE46]|\uD81A[\uDC00-\uDE38\uDE40-\uDE5E\uDE60-\uDE69\uDE70-\uDEBE\uDEC0-\uDEC9\uDED0-\uDEED\uDF00-\uDF2F\uDF40-\uDF43\uDF50-\uDF59\uDF5B-\uDF61\uDF63-\uDF77\uDF7D-\uDF8F]|\uD81B[\uDE40-\uDE96\uDF00-\uDF4A\uDF50\uDF93-\uDF9F\uDFE0\uDFE1\uDFE3]|\uD821[\uDC00-\uDFF7]|\uD823[\uDC00-\uDCD5\uDD00-\uDD08]|\uD82B[\uDFF0-\uDFF3\uDFF5-\uDFFB\uDFFD\uDFFE]|\uD82C[\uDC00-\uDD22\uDD50-\uDD52\uDD64-\uDD67\uDD70-\uDEFB]|\uD82F[\uDC00-\uDC6A\uDC70-\uDC7C\uDC80-\uDC88\uDC90-\uDC99]|\uD834[\uDEE0-\uDEF3\uDF60-\uDF78]|\uD835[\uDC00-\uDC54\uDC56-\uDC9C\uDC9E\uDC9F\uDCA2\uDCA5\uDCA6\uDCA9-\uDCAC\uDCAE-\uDCB9\uDCBB\uDCBD-\uDCC3\uDCC5-\uDD05\uDD07-\uDD0A\uDD0D-\uDD14\uDD16-\uDD1C\uDD1E-\uDD39\uDD3B-\uDD3E\uDD40-\uDD44\uDD46\uDD4A-\uDD50\uDD52-\uDEA5\uDEA8-\uDEC0\uDEC2-\uDEDA\uDEDC-\uDEFA\uDEFC-\uDF14\uDF16-\uDF34\uDF36-\uDF4E\uDF50-\uDF6E\uDF70-\uDF88\uDF8A-\uDFA8\uDFAA-\uDFC2\uDFC4-\uDFCB\uDFCE-\uDFFF]|\uD837[\uDF00-\uDF1E]|\uD838[\uDD00-\uDD2C\uDD37-\uDD3D\uDD40-\uDD49\uDD4E\uDE90-\uDEAD\uDEC0-\uDEEB\uDEF0-\uDEF9]|\uD839[\uDFE0-\uDFE6\uDFE8-\uDFEB\uDFED\uDFEE\uDFF0-\uDFFE]|\uD83A[\uDC00-\uDCC4\uDCC7-\uDCCF\uDD00-\uDD43\uDD4B\uDD50-\uDD59]|\uD83B[\uDC71-\uDCAB\uDCAD-\uDCAF\uDCB1-\uDCB4\uDD01-\uDD2D\uDD2F-\uDD3D\uDE00-\uDE03\uDE05-\uDE1F\uDE21\uDE22\uDE24\uDE27\uDE29-\uDE32\uDE34-\uDE37\uDE39\uDE3B\uDE42\uDE47\uDE49\uDE4B\uDE4D-\uDE4F\uDE51\uDE52\uDE54\uDE57\uDE59\uDE5B\uDE5D\uDE5F\uDE61\uDE62\uDE64\uDE67-\uDE6A\uDE6C-\uDE72\uDE74-\uDE77\uDE79-\uDE7C\uDE7E\uDE80-\uDE89\uDE8B-\uDE9B\uDEA1-\uDEA3\uDEA5-\uDEA9\uDEAB-\uDEBB]|\uD83C[\uDD00-\uDD0C]|\uD83E[\uDFF0-\uDFF9]|\uD869[\uDC00-\uDEDF\uDF00-\uDFFF]|\uD86D[\uDC00-\uDF38\uDF40-\uDFFF]|\uD86E[\uDC00-\uDC1D\uDC20-\uDFFF]|\uD873[\uDC00-\uDEA1\uDEB0-\uDFFF]|\uD87A[\uDC00-\uDFE0]|\uD87E[\uDC00-\uDE1D]|\uD884[\uDC00-\uDF4A])/))){var k=J[1]||J[2]||"";if(!k||k&&(X===""||this.rules.inline.punctuation.exec(X))){var B=J[0].length-1,H,j,oe=B,ue=0,Z=J[0][0]==="*"?this.rules.inline.emStrong.rDelimAst:this.rules.inline.emStrong.rDelimUnd;for(Z.lastIndex=0,le=le.slice(-1*ae.length+B);(J=Z.exec(le))!=null;)if(H=J[1]||J[2]||J[3]||J[4]||J[5]||J[6],!!H){if(j=H.length,J[3]||J[4]){oe+=j;continue}else if((J[5]||J[6])&&B%3&&!((B+j)%3)){ue+=j;continue}if(oe-=j,!(oe>0)){if(j=Math.min(j,j+oe+ue),Math.min(B,j)%2){var pe=ae.slice(1,B+J.index+j);return{type:"em",raw:ae.slice(0,B+J.index+j+1),text:pe,tokens:this.lexer.inlineTokens(pe,[])}}var ge=ae.slice(2,B+J.index+j-1);return{type:"strong",raw:ae.slice(0,B+J.index+j+1),text:ge,tokens:this.lexer.inlineTokens(ge,[])}}}}}},Se.codespan=function(ae){var le=this.rules.inline.code.exec(ae);if(le){var X=le[2].replace(/\n/g," "),J=/[^ ]/.test(X),k=/^ /.test(X)&&/ $/.test(X);return J&&k&&(X=X.substring(1,X.length-1)),X=f(X,!0),{type:"codespan",raw:le[0],text:X}}},Se.br=function(ae){var le=this.rules.inline.br.exec(ae);if(le)return{type:"br",raw:le[0]}},Se.del=function(ae){var le=this.rules.inline.del.exec(ae);if(le)return{type:"del",raw:le[0],text:le[2],tokens:this.lexer.inlineTokens(le[2],[])}},Se.autolink=function(ae,le){var X=this.rules.inline.autolink.exec(ae);if(X){var J,k;return X[2]==="@"?(J=f(this.options.mangle?le(X[1]):X[1]),k="mailto:"+J):(J=f(X[1]),k=J),{type:"link",raw:X[0],text:J,href:k,tokens:[{type:"text",raw:J,text:J}]}}},Se.url=function(ae,le){var X;if(X=this.rules.inline.url.exec(ae)){var J,k;if(X[2]==="@")J=f(this.options.mangle?le(X[0]):X[0]),k="mailto:"+J;else{var B;do B=X[0],X[0]=this.rules.inline._backpedal.exec(X[0])[0];while(B!==X[0]);J=f(X[0]),X[1]==="www."?k="http://"+J:k=J}return{type:"link",raw:X[0],text:J,href:k,tokens:[{type:"text",raw:J,text:J}]}}},Se.inlineText=function(ae,le){var X=this.rules.inline.text.exec(ae);if(X){var J;return this.lexer.state.inRawBlock?J=this.options.sanitize?this.options.sanitizer?this.options.sanitizer(X[0]):f(X[0]):X[0]:J=f(this.options.smartypants?le(X[0]):X[0]),{type:"text",raw:X[0],text:J}}},Ie}(),$={newline:/^(?: *(?:\n|$))+/,code:/^( {4}[^\n]+(?:\n(?: *(?:\n|$))*)?)+/,fences:/^ {0,3}(`{3,}(?=[^`\n]*\n)|~{3,})([^\n]*)\n(?:|([\s\S]*?)\n)(?: {0,3}\1[~`]* *(?=\n|$)|$)/,hr:/^ {0,3}((?:-[\t ]*){3,}|(?:_[ \t]*){3,}|(?:\*[ \t]*){3,})(?:\n+|$)/,heading:/^ {0,3}(#{1,6})(?=\s|$)(.*)(?:\n+|$)/,blockquote:/^( {0,3}> ?(paragraph|[^\n]*)(?:\n|$))+/,list:/^( {0,3}bull)([ \t][^\n]+?)?(?:\n|$)/,html:"^ {0,3}(?:<(script|pre|style|textarea)[\\s>][\\s\\S]*?(?:</\\1>[^\\n]*\\n+|$)|comment[^\\n]*(\\n+|$)|<\\?[\\s\\S]*?(?:\\?>\\n*|$)|<![A-Z][\\s\\S]*?(?:>\\n*|$)|<!\\[CDATA\\[[\\s\\S]*?(?:\\]\\]>\\n*|$)|</?(tag)(?: +|\\n|/?>)[\\s\\S]*?(?:(?:\\n *)+\\n|$)|<(?!script|pre|style|textarea)([a-z][\\w-]*)(?:attribute)*? */?>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n *)+\\n|$)|</(?!script|pre|style|textarea)[a-z][\\w-]*\\s*>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n *)+\\n|$))",def:/^ {0,3}\[(label)\]: *(?:\n *)?<?([^\s>]+)>?(?:(?: +(?:\n *)?| *\n *)(title))? *(?:\n+|$)/,table:t,lheading:/^([^\n]+)\n {0,3}(=+|-+) *(?:\n+|$)/,_paragraph:/^([^\n]+(?:\n(?!hr|heading|lheading|blockquote|fences|list|html|table| +\n)[^\n]+)*)/,text:/^[^\n]+/};$._label=/(?!\s*\])(?:\\.|[^\[\]\\])+/,$._title=/(?:"(?:\\"?|[^"\\])*"|'[^'\n]*(?:\n[^'\n]+)*\n?'|\([^()]*\))/,$.def=w($.def).replace("label",$._label).replace("title",$._title).getRegex(),$.bullet=/(?:[*+-]|\d{1,9}[.)])/,$.listItemStart=w(/^( *)(bull) */).replace("bull",$.bullet).getRegex(),$.list=w($.list).replace(/bull/g,$.bullet).replace("hr","\\n+(?=\\1?(?:(?:- *){3,}|(?:_ *){3,}|(?:\\* *){3,})(?:\\n+|$))").replace("def","\\n+(?="+$.def.source+")").getRegex(),$._tag="address|article|aside|base|basefont|blockquote|body|caption|center|col|colgroup|dd|details|dialog|dir|div|dl|dt|fieldset|figcaption|figure|footer|form|frame|frameset|h[1-6]|head|header|hr|html|iframe|legend|li|link|main|menu|menuitem|meta|nav|noframes|ol|optgroup|option|p|param|section|source|summary|table|tbody|td|tfoot|th|thead|title|tr|track|ul",$._comment=/<!--(?!-?>)[\s\S]*?(?:-->|$)/,$.html=w($.html,"i").replace("comment",$._comment).replace("tag",$._tag).replace("attribute",/ +[a-zA-Z:_][\w.:-]*(?: *= *"[^"\n]*"| *= *'[^'\n]*'| *= *[^\s"'=<>`]+)?/).getRegex(),$.paragraph=w($._paragraph).replace("hr",$.hr).replace("heading"," {0,3}#{1,6} ").replace("|lheading","").replace("|table","").replace("blockquote"," {0,3}>").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html","</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag",$._tag).getRegex(),$.blockquote=w($.blockquote).replace("paragraph",$.paragraph).getRegex(),$.normal=c({},$),$.gfm=c({},$.normal,{table:"^ *([^\\n ].*\\|.*)\\n {0,3}(?:\\| *)?(:?-+:? *(?:\\| *:?-+:? *)*)(?:\\| *)?(?:\\n((?:(?! *\\n|hr|heading|blockquote|code|fences|list|html).*(?:\\n|$))*)\\n*|$)"}),$.gfm.table=w($.gfm.table).replace("hr",$.hr).replace("heading"," {0,3}#{1,6} ").replace("blockquote"," {0,3}>").replace("code"," {4}[^\\n]").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html","</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag",$._tag).getRegex(),$.gfm.paragraph=w($._paragraph).replace("hr",$.hr).replace("heading"," {0,3}#{1,6} ").replace("|lheading","").replace("table",$.gfm.table).replace("blockquote"," {0,3}>").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html","</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag",$._tag).getRegex(),$.pedantic=c({},$.normal,{html:w(`^ *(?:comment *(?:\\n|\\s*$)|<(tag)[\\s\\S]+?</\\1> *(?:\\n{2,}|\\s*$)|<tag(?:"[^"]*"|'[^']*'|\\s[^'"/>\\s]*)*?/?> *(?:\\n{2,}|\\s*$))`).replace("comment",$._comment).replace(/tag/g,"(?!(?:a|em|strong|small|s|cite|q|dfn|abbr|data|time|code|var|samp|kbd|sub|sup|i|b|u|mark|ruby|rt|rp|bdi|bdo|span|br|wbr|ins|del|img)\\b)\\w+(?!:|[^\\w\\s@]*@)\\b").getRegex(),def:/^ *\[([^\]]+)\]: *<?([^\s>]+)>?(?: +(["(][^\n]+[")]))? *(?:\n+|$)/,heading:/^(#{1,6})(.*)(?:\n+|$)/,fences:t,paragraph:w($.normal._paragraph).replace("hr",$.hr).replace("heading",` *#{1,6} *[^
]`).replace("lheading",$.lheading).replace("blockquote"," {0,3}>").replace("|fences","").replace("|list","").replace("|html","").getRegex()});var N={escape:/^\\([!"#$%&'()*+,\-./:;<=>?@\[\]\\^_`{|}~])/,autolink:/^<(scheme:[^\s\x00-\x1f<>]*|email)>/,url:t,tag:"^comment|^</[a-zA-Z][\\w:-]*\\s*>|^<[a-zA-Z][\\w-]*(?:attribute)*?\\s*/?>|^<\\?[\\s\\S]*?\\?>|^<![a-zA-Z]+\\s[\\s\\S]*?>|^<!\\[CDATA\\[[\\s\\S]*?\\]\\]>",link:/^!?\[(label)\]\(\s*(href)(?:\s+(title))?\s*\)/,reflink:/^!?\[(label)\]\[(ref)\]/,nolink:/^!?\[(ref)\](?:\[\])?/,reflinkSearch:"reflink|nolink(?!\\()",emStrong:{lDelim:/^(?:\*+(?:([punct_])|[^\s*]))|^_+(?:([punct*])|([^\s_]))/,rDelimAst:/^[^_*]*?\_\_[^_*]*?\*[^_*]*?(?=\_\_)|[^*]+(?=[^*])|[punct_](\*+)(?=[\s]|$)|[^punct*_\s](\*+)(?=[punct_\s]|$)|[punct_\s](\*+)(?=[^punct*_\s])|[\s](\*+)(?=[punct_])|[punct_](\*+)(?=[punct_])|[^punct*_\s](\*+)(?=[^punct*_\s])/,rDelimUnd:/^[^_*]*?\*\*[^_*]*?\_[^_*]*?(?=\*\*)|[^_]+(?=[^_])|[punct*](\_+)(?=[\s]|$)|[^punct*_\s](\_+)(?=[punct*\s]|$)|[punct*\s](\_+)(?=[^punct*_\s])|[\s](\_+)(?=[punct*])|[punct*](\_+)(?=[punct*])/},code:/^(`+)([^`]|[^`][\s\S]*?[^`])\1(?!`)/,br:/^( {2,}|\\)\n(?!\s*$)/,del:t,text:/^(`+|[^`])(?:(?= {2,}\n)|[\s\S]*?(?:(?=[\\<!\[`*_]|\b_|$)|[^ ](?= {2,}\n)))/,punctuation:/^([\spunctuation])/};N._punctuation="!\"#$%&'()+\\-.,/:;<=>?@\\[\\]`^{|}~",N.punctuation=w(N.punctuation).replace(/punctuation/g,N._punctuation).getRegex(),N.blockSkip=/\[[^\]]*?\]\([^\)]*?\)|`[^`]*?`|<[^>]*?>/g,N.escapedEmSt=/\\\*|\\_/g,N._comment=w($._comment).replace("(?:-->|$)","-->").getRegex(),N.emStrong.lDelim=w(N.emStrong.lDelim).replace(/punct/g,N._punctuation).getRegex(),N.emStrong.rDelimAst=w(N.emStrong.rDelimAst,"g").replace(/punct/g,N._punctuation).getRegex(),N.emStrong.rDelimUnd=w(N.emStrong.rDelimUnd,"g").replace(/punct/g,N._punctuation).getRegex(),N._escapes=/\\([!"#$%&'()*+,\-./:;<=>?@\[\]\\^_`{|}~])/g,N._scheme=/[a-zA-Z][a-zA-Z0-9+.-]{1,31}/,N._email=/[a-zA-Z0-9.!#$%&'*+/=?^_`{|}~-]+(@)[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)+(?![-_])/,N.autolink=w(N.autolink).replace("scheme",N._scheme).replace("email",N._email).getRegex(),N._attribute=/\s+[a-zA-Z:_][\w.:-]*(?:\s*=\s*"[^"]*"|\s*=\s*'[^']*'|\s*=\s*[^\s"'=<>`]+)?/,N.tag=w(N.tag).replace("comment",N._comment).replace("attribute",N._attribute).getRegex(),N._label=/(?:\[(?:\\.|[^\[\]\\])*\]|\\.|`[^`]*`|[^\[\]\\`])*?/,N._href=/<(?:\\.|[^\n<>\\])+>|[^\s\x00-\x1f]*/,N._title=/"(?:\\"?|[^"\\])*"|'(?:\\'?|[^'\\])*'|\((?:\\\)?|[^)\\])*\)/,N.link=w(N.link).replace("label",N._label).replace("href",N._href).replace("title",N._title).getRegex(),N.reflink=w(N.reflink).replace("label",N._label).replace("ref",$._label).getRegex(),N.nolink=w(N.nolink).replace("ref",$._label).getRegex(),N.reflinkSearch=w(N.reflinkSearch,"g").replace("reflink",N.reflink).replace("nolink",N.nolink).getRegex(),N.normal=c({},N),N.pedantic=c({},N.normal,{strong:{start:/^__|\*\*/,middle:/^__(?=\S)([\s\S]*?\S)__(?!_)|^\*\*(?=\S)([\s\S]*?\S)\*\*(?!\*)/,endAst:/\*\*(?!\*)/g,endUnd:/__(?!_)/g},em:{start:/^_|\*/,middle:/^()\*(?=\S)([\s\S]*?\S)\*(?!\*)|^_(?=\S)([\s\S]*?\S)_(?!_)/,endAst:/\*(?!\*)/g,endUnd:/_(?!_)/g},link:w(/^!?\[(label)\]\((.*?)\)/).replace("label",N._label).getRegex(),reflink:w(/^!?\[(label)\]\s*\[([^\]]*)\]/).replace("label",N._label).getRegex()}),N.gfm=c({},N.normal,{escape:w(N.escape).replace("])","~|])").getRegex(),_extended_email:/[A-Za-z0-9._+-]+(@)[a-zA-Z0-9-_]+(?:\.[a-zA-Z0-9-_]*[a-zA-Z0-9])+(?![-_])/,url:/^((?:ftp|https?):\/\/|www\.)(?:[a-zA-Z0-9\-]+\.?)+[^\s<]*|^email/,_backpedal:/(?:[^?!.,:;*_~()&]+|\([^)]*\)|&(?![a-zA-Z0-9]+;$)|[?!.,:;*_~)]+(?!$))+/,del:/^(~~?)(?=[^\s~])([\s\S]*?[^\s~])\1(?=[^~]|$)/,text:/^([`~]+|[^`~])(?:(?= {2,}\n)|(?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)|[\s\S]*?(?:(?=[\\<!\[`*~_]|\b_|https?:\/\/|ftp:\/\/|www\.|$)|[^ ](?= {2,}\n)|[^a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-](?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)))/}),N.gfm.url=w(N.gfm.url,"i").replace("email",N.gfm._extended_email).getRegex(),N.breaks=c({},N.gfm,{br:w(N.br).replace("{2,}","*").getRegex(),text:w(N.gfm.text).replace("\\b_","\\b_| {2,}\\n").replace(/\{2,\}/g,"*").getRegex()});function K(Ie){return Ie.replace(/---/g,"\u2014").replace(/--/g,"\u2013").replace(/(^|[-\u2014/(\[{"\s])'/g,"$1\u2018").replace(/'/g,"\u2019").replace(/(^|[-\u2014/(\[{\u2018\s])"/g,"$1\u201C").replace(/"/g,"\u201D").replace(/\.{3}/g,"\u2026")}function V(Ie){var Se="",Te,ae,le=Ie.length;for(Te=0;Te<le;Te++)ae=Ie.charCodeAt(Te),Math.random()>.5&&(ae="x"+ae.toString(16)),Se+="&#"+ae+";";return Se}var F=function(){function Ie(Te){this.tokens=[],this.tokens.links=Object.create(null),this.options=Te||ee.defaults,this.options.tokenizer=this.options.tokenizer||new z,this.tokenizer=this.options.tokenizer,this.tokenizer.options=this.options,this.tokenizer.lexer=this,this.inlineQueue=[],this.state={inLink:!1,inRawBlock:!1,top:!0};var ae={block:$.normal,inline:N.normal};this.options.pedantic?(ae.block=$.pedantic,ae.inline=N.pedantic):this.options.gfm&&(ae.block=$.gfm,this.options.breaks?ae.inline=N.breaks:ae.inline=N.gfm),this.tokenizer.rules=ae}Ie.lex=function(ae,le){var X=new Ie(le);return X.lex(ae)},Ie.lexInline=function(ae,le){var X=new Ie(le);return X.inlineTokens(ae)};var Se=Ie.prototype;return Se.lex=function(ae){ae=ae.replace(/\r\n|\r/g,`
`),this.blockTokens(ae,this.tokens);for(var le;le=this.inlineQueue.shift();)this.inlineTokens(le.src,le.tokens);return this.tokens},Se.blockTokens=function(ae,le){var X=this;le===void 0&&(le=[]),this.options.pedantic?ae=ae.replace(/\t/g," ").replace(/^ +$/gm,""):ae=ae.replace(/^( *)(\t+)/gm,function(oe,ue,Z){return ue+" ".repeat(Z.length)});for(var J,k,B,H;ae;)if(!(this.options.extensions&&this.options.extensions.block&&this.options.extensions.block.some(function(oe){return(J=oe.call({lexer:X},ae,le))?(ae=ae.substring(J.raw.length),le.push(J),!0):!1}))){if(J=this.tokenizer.space(ae)){ae=ae.substring(J.raw.length),J.raw.length===1&&le.length>0?le[le.length-1].raw+=`
`:le.push(J);continue}if(J=this.tokenizer.code(ae)){ae=ae.substring(J.raw.length),k=le[le.length-1],k&&(k.type==="paragraph"||k.type==="text")?(k.raw+=`
`+J.raw,k.text+=`
`+J.text,this.inlineQueue[this.inlineQueue.length-1].src=k.text):le.push(J);continue}if(J=this.tokenizer.fences(ae)){ae=ae.substring(J.raw.length),le.push(J);continue}if(J=this.tokenizer.heading(ae)){ae=ae.substring(J.raw.length),le.push(J);continue}if(J=this.tokenizer.hr(ae)){ae=ae.substring(J.raw.length),le.push(J);continue}if(J=this.tokenizer.blockquote(ae)){ae=ae.substring(J.raw.length),le.push(J);continue}if(J=this.tokenizer.list(ae)){ae=ae.substring(J.raw.length),le.push(J);continue}if(J=this.tokenizer.html(ae)){ae=ae.substring(J.raw.length),le.push(J);continue}if(J=this.tokenizer.def(ae)){ae=ae.substring(J.raw.length),k=le[le.length-1],k&&(k.type==="paragraph"||k.type==="text")?(k.raw+=`
`+J.raw,k.text+=`
`+J.raw,this.inlineQueue[this.inlineQueue.length-1].src=k.text):this.tokens.links[J.tag]||(this.tokens.links[J.tag]={href:J.href,title:J.title});continue}if(J=this.tokenizer.table(ae)){ae=ae.substring(J.raw.length),le.push(J);continue}if(J=this.tokenizer.lheading(ae)){ae=ae.substring(J.raw.length),le.push(J);continue}if(B=ae,this.options.extensions&&this.options.extensions.startBlock&&function(){var oe=1/0,ue=ae.slice(1),Z=void 0;X.options.extensions.startBlock.forEach(function(pe){Z=pe.call({lexer:this},ue),typeof Z=="number"&&Z>=0&&(oe=Math.min(oe,Z))}),oe<1/0&&oe>=0&&(B=ae.substring(0,oe+1))}(),this.state.top&&(J=this.tokenizer.paragraph(B))){k=le[le.length-1],H&&k.type==="paragraph"?(k.raw+=`
`+J.raw,k.text+=`
`+J.text,this.inlineQueue.pop(),this.inlineQueue[this.inlineQueue.length-1].src=k.text):le.push(J),H=B.length!==ae.length,ae=ae.substring(J.raw.length);continue}if(J=this.tokenizer.text(ae)){ae=ae.substring(J.raw.length),k=le[le.length-1],k&&k.type==="text"?(k.raw+=`
`+J.raw,k.text+=`
`+J.text,this.inlineQueue.pop(),this.inlineQueue[this.inlineQueue.length-1].src=k.text):le.push(J);continue}if(ae){var j="Infinite loop on byte: "+ae.charCodeAt(0);if(this.options.silent){console.error(j);break}else throw new Error(j)}}return this.state.top=!0,le},Se.inline=function(ae,le){this.inlineQueue.push({src:ae,tokens:le})},Se.inlineTokens=function(ae,le){var X=this;le===void 0&&(le=[]);var J,k,B,H=ae,j,oe,ue;if(this.tokens.links){var Z=Object.keys(this.tokens.links);if(Z.length>0)for(;(j=this.tokenizer.rules.inline.reflinkSearch.exec(H))!=null;)Z.includes(j[0].slice(j[0].lastIndexOf("[")+1,-1))&&(H=H.slice(0,j.index)+"["+W("a",j[0].length-2)+"]"+H.slice(this.tokenizer.rules.inline.reflinkSearch.lastIndex))}for(;(j=this.tokenizer.rules.inline.blockSkip.exec(H))!=null;)H=H.slice(0,j.index)+"["+W("a",j[0].length-2)+"]"+H.slice(this.tokenizer.rules.inline.blockSkip.lastIndex);for(;(j=this.tokenizer.rules.inline.escapedEmSt.exec(H))!=null;)H=H.slice(0,j.index)+"++"+H.slice(this.tokenizer.rules.inline.escapedEmSt.lastIndex);for(;ae;)if(oe||(ue=""),oe=!1,!(this.options.extensions&&this.options.extensions.inline&&this.options.extensions.inline.some(function(ge){return(J=ge.call({lexer:X},ae,le))?(ae=ae.substring(J.raw.length),le.push(J),!0):!1}))){if(J=this.tokenizer.escape(ae)){ae=ae.substring(J.raw.length),le.push(J);continue}if(J=this.tokenizer.tag(ae)){ae=ae.substring(J.raw.length),k=le[le.length-1],k&&J.type==="text"&&k.type==="text"?(k.raw+=J.raw,k.text+=J.text):le.push(J);continue}if(J=this.tokenizer.link(ae)){ae=ae.substring(J.raw.length),le.push(J);continue}if(J=this.tokenizer.reflink(ae,this.tokens.links)){ae=ae.substring(J.raw.length),k=le[le.length-1],k&&J.type==="text"&&k.type==="text"?(k.raw+=J.raw,k.text+=J.text):le.push(J);continue}if(J=this.tokenizer.emStrong(ae,H,ue)){ae=ae.substring(J.raw.length),le.push(J);continue}if(J=this.tokenizer.codespan(ae)){ae=ae.substring(J.raw.length),le.push(J);continue}if(J=this.tokenizer.br(ae)){ae=ae.substring(J.raw.length),le.push(J);continue}if(J=this.tokenizer.del(ae)){ae=ae.substring(J.raw.length),le.push(J);continue}if(J=this.tokenizer.autolink(ae,V)){ae=ae.substring(J.raw.length),le.push(J);continue}if(!this.state.inLink&&(J=this.tokenizer.url(ae,V))){ae=ae.substring(J.raw.length),le.push(J);continue}if(B=ae,this.options.extensions&&this.options.extensions.startInline&&function(){var ge=1/0,Ne=ae.slice(1),Be=void 0;X.options.extensions.startInline.forEach(function(Ze){Be=Ze.call({lexer:this},Ne),typeof Be=="number"&&Be>=0&&(ge=Math.min(ge,Be))}),ge<1/0&&ge>=0&&(B=ae.substring(0,ge+1))}(),J=this.tokenizer.inlineText(B,K)){ae=ae.substring(J.raw.length),J.raw.slice(-1)!=="_"&&(ue=J.raw.slice(-1)),oe=!0,k=le[le.length-1],k&&k.type==="text"?(k.raw+=J.raw,k.text+=J.text):le.push(J);continue}if(ae){var pe="Infinite loop on byte: "+ae.charCodeAt(0);if(this.options.silent){console.error(pe);break}else throw new Error(pe)}}return le},s(Ie,null,[{key:"rules",get:function(){return{block:$,inline:N}}}]),Ie}(),ne=function(){function Ie(Te){this.options=Te||ee.defaults}var Se=Ie.prototype;return Se.code=function(ae,le,X){var J=(le||"").match(/\S*/)[0];if(this.options.highlight){var k=this.options.highlight(ae,J);k!=null&&k!==ae&&(X=!0,ae=k)}return ae=ae.replace(/\n$/,"")+`
`,J?'<pre><code class="'+this.options.langPrefix+f(J,!0)+'">'+(X?ae:f(ae,!0))+`</code></pre>
`:"<pre><code>"+(X?ae:f(ae,!0))+`</code></pre>
`},Se.blockquote=function(ae){return`<blockquote>
`+ae+`</blockquote>
`},Se.html=function(ae){return ae},Se.heading=function(ae,le,X,J){if(this.options.headerIds){var k=this.options.headerPrefix+J.slug(X);return"<h"+le+' id="'+k+'">'+ae+"</h"+le+`>
`}return"<h"+le+">"+ae+"</h"+le+`>
`},Se.hr=function(){return this.options.xhtml?`<hr/>
`:`<hr>
`},Se.list=function(ae,le,X){var J=le?"ol":"ul",k=le&&X!==1?' start="'+X+'"':"";return"<"+J+k+`>
`+ae+"</"+J+`>
`},Se.listitem=function(ae){return"<li>"+ae+`</li>
`},Se.checkbox=function(ae){return"<input "+(ae?'checked="" ':"")+'disabled="" type="checkbox"'+(this.options.xhtml?" /":"")+"> "},Se.paragraph=function(ae){return"<p>"+ae+`</p>
`},Se.table=function(ae,le){return le&&(le="<tbody>"+le+"</tbody>"),`<table>
<thead>
`+ae+`</thead>
`+le+`</table>
`},Se.tablerow=function(ae){return`<tr>
`+ae+`</tr>
`},Se.tablecell=function(ae,le){var X=le.header?"th":"td",J=le.align?"<"+X+' align="'+le.align+'">':"<"+X+">";return J+ae+("</"+X+`>
`)},Se.strong=function(ae){return"<strong>"+ae+"</strong>"},Se.em=function(ae){return"<em>"+ae+"</em>"},Se.codespan=function(ae){return"<code>"+ae+"</code>"},Se.br=function(){return this.options.xhtml?"<br/>":"<br>"},Se.del=function(ae){return"<del>"+ae+"</del>"},Se.link=function(ae,le,X){if(ae=_(this.options.sanitize,this.options.baseUrl,ae),ae===null)return X;var J='<a href="'+f(ae)+'"';return le&&(J+=' title="'+le+'"'),J+=">"+X+"</a>",J},Se.image=function(ae,le,X){if(ae=_(this.options.sanitize,this.options.baseUrl,ae),ae===null)return X;var J='<img src="'+ae+'" alt="'+X+'"';return le&&(J+=' title="'+le+'"'),J+=this.options.xhtml?"/>":">",J},Se.text=function(ae){return ae},Ie}(),ce=function(){function Ie(){}var Se=Ie.prototype;return Se.strong=function(ae){return ae},Se.em=function(ae){return ae},Se.codespan=function(ae){return ae},Se.del=function(ae){return ae},Se.html=function(ae){return ae},Se.text=function(ae){return ae},Se.link=function(ae,le,X){return""+X},Se.image=function(ae,le,X){return""+X},Se.br=function(){return""},Ie}(),re=function(){function Ie(){this.seen={}}var Se=Ie.prototype;return Se.serialize=function(ae){return ae.toLowerCase().trim().replace(/<[!\/a-z].*?>/ig,"").replace(/[\u2000-\u206F\u2E00-\u2E7F\\'!"#$%&()*+,./:;<=>?@[\]^`{|}~]/g,"").replace(/\s/g,"-")},Se.getNextSafeSlug=function(ae,le){var X=ae,J=0;if(this.seen.hasOwnProperty(X)){J=this.seen[ae];do J++,X=ae+"-"+J;while(this.seen.hasOwnProperty(X))}return le||(this.seen[ae]=J,this.seen[X]=0),X},Se.slug=function(ae,le){le===void 0&&(le={});var X=this.serialize(ae);return this.getNextSafeSlug(X,le.dryrun)},Ie}(),fe=function(){function Ie(Te){this.options=Te||ee.defaults,this.options.renderer=this.options.renderer||new ne,this.renderer=this.options.renderer,this.renderer.options=this.options,this.textRenderer=new ce,this.slugger=new re}Ie.parse=function(ae,le){var X=new Ie(le);return X.parse(ae)},Ie.parseInline=function(ae,le){var X=new Ie(le);return X.parseInline(ae)};var Se=Ie.prototype;return Se.parse=function(ae,le){le===void 0&&(le=!0);var X="",J,k,B,H,j,oe,ue,Z,pe,ge,Ne,Be,Ze,Ke,ke,nt,G,Q,he,Ue=ae.length;for(J=0;J<Ue;J++){if(ge=ae[J],this.options.extensions&&this.options.extensions.renderers&&this.options.extensions.renderers[ge.type]&&(he=this.options.extensions.renderers[ge.type].call({parser:this},ge),he!==!1||!["space","hr","heading","code","table","blockquote","list","html","paragraph","text"].includes(ge.type))){X+=he||"";continue}switch(ge.type){case"space":continue;case"hr":{X+=this.renderer.hr();continue}case"heading":{X+=this.renderer.heading(this.parseInline(ge.tokens),ge.depth,d(this.parseInline(ge.tokens,this.textRenderer)),this.slugger);continue}case"code":{X+=this.renderer.code(ge.text,ge.lang,ge.escaped);continue}case"table":{for(Z="",ue="",H=ge.header.length,k=0;k<H;k++)ue+=this.renderer.tablecell(this.parseInline(ge.header[k].tokens),{header:!0,align:ge.align[k]});for(Z+=this.renderer.tablerow(ue),pe="",H=ge.rows.length,k=0;k<H;k++){for(oe=ge.rows[k],ue="",j=oe.length,B=0;B<j;B++)ue+=this.renderer.tablecell(this.parseInline(oe[B].tokens),{header:!1,align:ge.align[B]});pe+=this.renderer.tablerow(ue)}X+=this.renderer.table(Z,pe);continue}case"blockquote":{pe=this.parse(ge.tokens),X+=this.renderer.blockquote(pe);continue}case"list":{for(Ne=ge.ordered,Be=ge.start,Ze=ge.loose,H=ge.items.length,pe="",k=0;k<H;k++)ke=ge.items[k],nt=ke.checked,G=ke.task,Ke="",ke.task&&(Q=this.renderer.checkbox(nt),Ze?ke.tokens.length>0&&ke.tokens[0].type==="paragraph"?(ke.tokens[0].text=Q+" "+ke.tokens[0].text,ke.tokens[0].tokens&&ke.tokens[0].tokens.length>0&&ke.tokens[0].tokens[0].type==="text"&&(ke.tokens[0].tokens[0].text=Q+" "+ke.tokens[0].tokens[0].text)):ke.tokens.unshift({type:"text",text:Q}):Ke+=Q),Ke+=this.parse(ke.tokens,Ze),pe+=this.renderer.listitem(Ke,G,nt);X+=this.renderer.list(pe,Ne,Be);continue}case"html":{X+=this.renderer.html(ge.text);continue}case"paragraph":{X+=this.renderer.paragraph(this.parseInline(ge.tokens));continue}case"text":{for(pe=ge.tokens?this.parseInline(ge.tokens):ge.text;J+1<Ue&&ae[J+1].type==="text";)ge=ae[++J],pe+=`
`+(ge.tokens?this.parseInline(ge.tokens):ge.text);X+=le?this.renderer.paragraph(pe):pe;continue}default:{var We='Token with "'+ge.type+'" type was not found.';if(this.options.silent){console.error(We);return}else throw new Error(We)}}}return X},Se.parseInline=function(ae,le){le=le||this.renderer;var X="",J,k,B,H=ae.length;for(J=0;J<H;J++){if(k=ae[J],this.options.extensions&&this.options.extensions.renderers&&this.options.extensions.renderers[k.type]&&(B=this.options.extensions.renderers[k.type].call({parser:this},k),B!==!1||!["escape","html","link","image","strong","em","codespan","br","del","text"].includes(k.type))){X+=B||"";continue}switch(k.type){case"escape":{X+=le.text(k.text);break}case"html":{X+=le.html(k.text);break}case"link":{X+=le.link(k.href,k.title,this.parseInline(k.tokens,le));break}case"image":{X+=le.image(k.href,k.title,k.text);break}case"strong":{X+=le.strong(this.parseInline(k.tokens,le));break}case"em":{X+=le.em(this.parseInline(k.tokens,le));break}case"codespan":{X+=le.codespan(k.text);break}case"br":{X+=le.br();break}case"del":{X+=le.del(this.parseInline(k.tokens,le));break}case"text":{X+=le.text(k.text);break}default:{var j='Token with "'+k.type+'" type was not found.';if(this.options.silent){console.error(j);return}else throw new Error(j)}}}return X},Ie}();function ie(Ie,Se,Te){if(typeof Ie=="undefined"||Ie===null)throw new Error("marked(): input parameter is undefined or null");if(typeof Ie!="string")throw new Error("marked(): input parameter is of type "+Object.prototype.toString.call(Ie)+", string expected");if(typeof Se=="function"&&(Te=Se,Se=null),Se=c({},ie.defaults,Se||{}),U(Se),Te){var ae=Se.highlight,le;try{le=F.lex(Ie,Se)}catch(B){return Te(B)}var X=function(H){var j;if(!H)try{Se.walkTokens&&ie.walkTokens(le,Se.walkTokens),j=fe.parse(le,Se)}catch(oe){H=oe}return Se.highlight=ae,H?Te(H):Te(null,j)};if(!ae||ae.length<3||(delete Se.highlight,!le.length))return X();var J=0;ie.walkTokens(le,function(B){B.type==="code"&&(J++,setTimeout(function(){ae(B.text,B.lang,function(H,j){if(H)return X(H);j!=null&&j!==B.text&&(B.text=j,B.escaped=!0),J--,J===0&&X()})},0))}),J===0&&X();return}try{var k=F.lex(Ie,Se);return Se.walkTokens&&ie.walkTokens(k,Se.walkTokens),fe.parse(k,Se)}catch(B){if(B.message+=`
Please report this to https://github.com/markedjs/marked.`,Se.silent)return"<p>An error occurred:</p><pre>"+f(B.message+"",!0)+"</pre>";throw B}}ie.options=ie.setOptions=function(Ie){return c(ie.defaults,Ie),T(ie.defaults),ie},ie.getDefaults=C,ie.defaults=ee.defaults,ie.use=function(){for(var Ie=arguments.length,Se=new Array(Ie),Te=0;Te<Ie;Te++)Se[Te]=arguments[Te];var ae=c.apply(void 0,[{}].concat(Se)),le=ie.defaults.extensions||{renderers:{},childTokens:{}},X;Se.forEach(function(J){if(J.extensions&&(X=!0,J.extensions.forEach(function(B){if(!B.name)throw new Error("extension name required");if(B.renderer){var H=le.renderers?le.renderers[B.name]:null;H?le.renderers[B.name]=function(){for(var j=arguments.length,oe=new Array(j),ue=0;ue<j;ue++)oe[ue]=arguments[ue];var Z=B.renderer.apply(this,oe);return Z===!1&&(Z=H.apply(this,oe)),Z}:le.renderers[B.name]=B.renderer}if(B.tokenizer){if(!B.level||B.level!=="block"&&B.level!=="inline")throw new Error("extension level must be 'block' or 'inline'");le[B.level]?le[B.level].unshift(B.tokenizer):le[B.level]=[B.tokenizer],B.start&&(B.level==="block"?le.startBlock?le.startBlock.push(B.start):le.startBlock=[B.start]:B.level==="inline"&&(le.startInline?le.startInline.push(B.start):le.startInline=[B.start]))}B.childTokens&&(le.childTokens[B.name]=B.childTokens)})),J.renderer&&function(){var B=ie.defaults.renderer||new ne,H=function(ue){var Z=B[ue];B[ue]=function(){for(var pe=arguments.length,ge=new Array(pe),Ne=0;Ne<pe;Ne++)ge[Ne]=arguments[Ne];var Be=J.renderer[ue].apply(B,ge);return Be===!1&&(Be=Z.apply(B,ge)),Be}};for(var j in J.renderer)H(j);ae.renderer=B}(),J.tokenizer&&function(){var B=ie.defaults.tokenizer||new z,H=function(ue){var Z=B[ue];B[ue]=function(){for(var pe=arguments.length,ge=new Array(pe),Ne=0;Ne<pe;Ne++)ge[Ne]=arguments[Ne];var Be=J.tokenizer[ue].apply(B,ge);return Be===!1&&(Be=Z.apply(B,ge)),Be}};for(var j in J.tokenizer)H(j);ae.tokenizer=B}(),J.walkTokens){var k=ie.defaults.walkTokens;ae.walkTokens=function(B){J.walkTokens.call(this,B),k&&k.call(this,B)}}X&&(ae.extensions=le),ie.setOptions(ae)})},ie.walkTokens=function(Ie,Se){for(var Te=function(){var J=le.value;switch(Se.call(ie,J),J.type){case"table":{for(var k=L(J.header),B;!(B=k()).done;){var H=B.value;ie.walkTokens(H.tokens,Se)}for(var j=L(J.rows),oe;!(oe=j()).done;)for(var ue=oe.value,Z=L(ue),pe;!(pe=Z()).done;){var ge=pe.value;ie.walkTokens(ge.tokens,Se)}break}case"list":{ie.walkTokens(J.items,Se);break}default:ie.defaults.extensions&&ie.defaults.extensions.childTokens&&ie.defaults.extensions.childTokens[J.type]?ie.defaults.extensions.childTokens[J.type].forEach(function(Ne){ie.walkTokens(J[Ne],Se)}):J.tokens&&ie.walkTokens(J.tokens,Se)}},ae=L(Ie),le;!(le=ae()).done;)Te()},ie.parseInline=function(Ie,Se){if(typeof Ie=="undefined"||Ie===null)throw new Error("marked.parseInline(): input parameter is undefined or null");if(typeof Ie!="string")throw new Error("marked.parseInline(): input parameter is of type "+Object.prototype.toString.call(Ie)+", string expected");Se=c({},ie.defaults,Se||{}),U(Se);try{var Te=F.lexInline(Ie,Se);return Se.walkTokens&&ie.walkTokens(Te,Se.walkTokens),fe.parseInline(Te,Se)}catch(ae){if(ae.message+=`
Please report this to https://github.com/markedjs/marked.`,Se.silent)return"<p>An error occurred:</p><pre>"+f(ae.message+"",!0)+"</pre>";throw ae}},ie.Parser=fe,ie.parser=fe.parse,ie.Renderer=ne,ie.TextRenderer=ce,ie.Lexer=F,ie.lexer=F.lex,ie.Tokenizer=z,ie.Slugger=re,ie.parse=ie;var Ee=ie.options,be=ie.setOptions,te=ie.use,ve=ie.walkTokens,Re=ie.parseInline,Fe=ie,$e=fe.parse,Ye=F.lex;ee.Lexer=F,ee.Parser=fe,ee.Renderer=ne,ee.Slugger=re,ee.TextRenderer=ce,ee.Tokenizer=z,ee.getDefaults=C,ee.lexer=Ye,ee.marked=ie,ee.options=Ee,ee.parse=Fe,ee.parseInline=Re,ee.parser=$e,ee.setOptions=be,ee.use=te,ee.walkTokens=ve,Object.defineProperty(ee,"__esModule",{value:!0})}),define(ye[106],Ce([1,0]),function(ee,e){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.SlidingWindowAverage=e.MovingAverage=e.Counter=e.rot=e.clamp=void 0;function s(T,E,A){return Math.min(Math.max(T,E),A)}e.clamp=s;function p(T,E){return(E+T%E)%E}e.rot=p;class b{constructor(){this._next=0}getNext(){return this._next++}}e.Counter=b;class L{constructor(){this._n=1,this._val=0}update(E){return this._val=this._val+(E-this._val)/this._n,this._n+=1,this._val}get value(){return this._val}}e.MovingAverage=L;class C{constructor(E){this._n=0,this._val=0,this._values=[],this._index=0,this._sum=0,this._values=new Array(E),this._values.fill(0,0,E)}update(E){const A=this._values[this._index];return this._values[this._index]=E,this._index=(this._index+1)%this._values.length,this._sum-=A,this._sum+=E,this._n<this._values.length&&(this._n+=1),this._val=this._sum/this._n,this._val}get value(){return this._val}}e.SlidingWindowAverage=C}),function(){function ee(b){const L=[];typeof b=="number"&&L.push("code/timeOrigin",b);function C(E){L.push(E,Date.now())}function T(){const E=[];for(let A=0;A<L.length;A+=2)E.push({name:L[A],startTime:L[A+1]});return E}return{mark:C,getMarks:T}}function e(){if(typeof performance=="object"&&typeof performance.mark=="function"&&!performance.nodeTiming)return typeof performance.timeOrigin!="number"&&!performance.timing?ee():{mark(b){performance.mark(b)},getMarks(){let b=performance.timeOrigin;typeof b!="number"&&(b=performance.timing.navigationStart||performance.timing.redirectStart||performance.timing.fetchStart);const L=[{name:"code/timeOrigin",startTime:Math.round(b)}];for(const C of performance.getEntriesByType("mark"))L.push({name:C.name,startTime:Math.round(b+C.startTime)});return L}};if(typeof process=="object"){const b=Math.round((require.nodeRequire||require)("perf_hooks").performance.timeOrigin);return ee(b)}else return console.trace("perf-util loaded in UNKNOWN environment"),ee()}function s(b){return b.MonacoPerformanceMarks||(b.MonacoPerformanceMarks=e()),b.MonacoPerformanceMarks}var p;typeof global=="object"?p=global:typeof self=="object"?p=self:p={},typeof define=="function"?define("vs/base/common/performance",[],function(){return s(p)}):typeof module=="object"&&typeof module.exports=="object"?module.exports=s(p):(console.trace("perf-util defined in UNKNOWN context (neither requirejs or commonjs)"),p.perf=s(p))}(),define(ye[74],Ce([1,0,19]),function(ee,e,s){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.normalizeMimeType=e.getExtensionForMimeType=e.getMediaMime=e.getMediaOrTextMime=e.Mimes=void 0,e.Mimes=Object.freeze({text:"text/plain",binary:"application/octet-stream",unknown:"application/unknown",markdown:"text/markdown",latex:"text/latex",uriList:"text/uri-list"});const p={".css":"text/css",".csv":"text/csv",".htm":"text/html",".html":"text/html",".ics":"text/calendar",".js":"text/javascript",".mjs":"text/javascript",".txt":"text/plain",".xml":"text/xml"},b={".aac":"audio/x-aac",".avi":"video/x-msvideo",".bmp":"image/bmp",".flv":"video/x-flv",".gif":"image/gif",".ico":"image/x-icon",".jpe":"image/jpg",".jpeg":"image/jpg",".jpg":"image/jpg",".m1v":"video/mpeg",".m2a":"audio/mpeg",".m2v":"video/mpeg",".m3a":"audio/mpeg",".mid":"audio/midi",".midi":"audio/midi",".mk3d":"video/x-matroska",".mks":"video/x-matroska",".mkv":"video/x-matroska",".mov":"video/quicktime",".movie":"video/x-sgi-movie",".mp2":"audio/mpeg",".mp2a":"audio/mpeg",".mp3":"audio/mpeg",".mp4":"video/mp4",".mp4a":"audio/mp4",".mp4v":"video/mp4",".mpe":"video/mpeg",".mpeg":"video/mpeg",".mpg":"video/mpeg",".mpg4":"video/mp4",".mpga":"audio/mpeg",".oga":"audio/ogg",".ogg":"audio/ogg",".opus":"audio/opus",".ogv":"video/ogg",".png":"image/png",".psd":"image/vnd.adobe.photoshop",".qt":"video/quicktime",".spx":"audio/ogg",".svg":"image/svg+xml",".tga":"image/x-tga",".tif":"image/tiff",".tiff":"image/tiff",".wav":"audio/x-wav",".webm":"video/webm",".webp":"image/webp",".wma":"audio/x-ms-wma",".wmv":"video/x-ms-wmv",".woff":"application/font-woff"};function L(R){const y=(0,s.extname)(R),m=p[y.toLowerCase()];return m!==void 0?m:C(R)}e.getMediaOrTextMime=L;function C(R){const y=(0,s.extname)(R);return b[y.toLowerCase()]}e.getMediaMime=C;function T(R){for(const y in b)if(b[y]===R)return y}e.getExtensionForMimeType=T;const E=/^(.+)\/(.+?)(;.+)?$/;function A(R,y){const m=E.exec(R);return m?`${m[1].toLowerCase()}/${m[2].toLowerCase()}${m[3]??""}`:y?void 0:R}e.normalizeMimeType=A}),function(ee,e){if(typeof exports=="object"&&typeof module=="object")module.exports=e();else if(typeof define=="function"&&define.amd)define("vs/base/common/semver/semver",[],e);else{var s=e();for(var p in s)(typeof exports=="object"?exports:ee)[p]=s[p]}}(typeof self!="undefined"?self:this,function(){return function(ee){var e={};function s(p){if(e[p])return e[p].exports;var b=e[p]={i:p,l:!1,exports:{}};return ee[p].call(b.exports,b,b.exports,s),b.l=!0,b.exports}return s.m=ee,s.c=e,s.d=function(p,b,L){s.o(p,b)||Object.defineProperty(p,b,{enumerable:!0,get:L})},s.r=function(p){typeof Symbol!="undefined"&&Symbol.toStringTag&&Object.defineProperty(p,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(p,"__esModule",{value:!0})},s.t=function(p,b){if(1&b&&(p=s(p)),8&b||4&b&&typeof p=="object"&&p&&p.__esModule)return p;var L=Object.create(null);if(s.r(L),Object.defineProperty(L,"default",{enumerable:!0,value:p}),2&b&&typeof p!="string")for(var C in p)s.d(L,C,function(T){return p[T]}.bind(null,C));return L},s.n=function(p){var b=p&&p.__esModule?function(){return p.default}:function(){return p};return s.d(b,"a",b),b},s.o=function(p,b){return Object.prototype.hasOwnProperty.call(p,b)},s.p="",s(s.s=0)}([function(ee,e,s){(function(p){var b;e=ee.exports=te,b=typeof p=="object"&&p.env&&p.env.NODE_DEBUG&&/\bsemver\b/i.test(p.env.NODE_DEBUG)?function(){var Z=Array.prototype.slice.call(arguments,0);Z.unshift("SEMVER"),console.log.apply(console,Z)}:function(){},e.SEMVER_SPEC_VERSION="2.0.0";var L=256,C=Number.MAX_SAFE_INTEGER||9007199254740991,T=e.re=[],E=e.src=[],A=0,R=A++;E[R]="0|[1-9]\\d*";var y=A++;E[y]="[0-9]+";var m=A++;E[m]="\\d*[a-zA-Z-][a-zA-Z0-9-]*";var I=A++;E[I]="("+E[R]+")\\.("+E[R]+")\\.("+E[R]+")";var f=A++;E[f]="("+E[y]+")\\.("+E[y]+")\\.("+E[y]+")";var h=A++;E[h]="(?:"+E[R]+"|"+E[m]+")";var d=A++;E[d]="(?:"+E[y]+"|"+E[m]+")";var a=A++;E[a]="(?:-("+E[h]+"(?:\\."+E[h]+")*))";var w=A++;E[w]="(?:-?("+E[d]+"(?:\\."+E[d]+")*))";var P=A++;E[P]="[0-9A-Za-z-]+";var l=A++;E[l]="(?:\\+("+E[P]+"(?:\\."+E[P]+")*))";var _=A++,n="v?"+E[I]+E[a]+"?"+E[l]+"?";E[_]="^"+n+"$";var u="[v=\\s]*"+E[f]+E[w]+"?"+E[l]+"?",i=A++;E[i]="^"+u+"$";var o=A++;E[o]="((?:<|>)?=?)";var r=A++;E[r]=E[y]+"|x|X|\\*";var t=A++;E[t]=E[R]+"|x|X|\\*";var c=A++;E[c]="[v=\\s]*("+E[t]+")(?:\\.("+E[t]+")(?:\\.("+E[t]+")(?:"+E[a]+")?"+E[l]+"?)?)?";var v=A++;E[v]="[v=\\s]*("+E[r]+")(?:\\.("+E[r]+")(?:\\.("+E[r]+")(?:"+E[w]+")?"+E[l]+"?)?)?";var g=A++;E[g]="^"+E[o]+"\\s*"+E[c]+"$";var D=A++;E[D]="^"+E[o]+"\\s*"+E[v]+"$";var U=A++;E[U]="(?:^|[^\\d])(\\d{1,16})(?:\\.(\\d{1,16}))?(?:\\.(\\d{1,16}))?(?:$|[^\\d])";var W=A++;E[W]="(?:~>?)";var M=A++;E[M]="(\\s*)"+E[W]+"\\s+",T[M]=new RegExp(E[M],"g");var S=A++;E[S]="^"+E[W]+E[c]+"$";var z=A++;E[z]="^"+E[W]+E[v]+"$";var $=A++;E[$]="(?:\\^)";var N=A++;E[N]="(\\s*)"+E[$]+"\\s+",T[N]=new RegExp(E[N],"g");var K=A++;E[K]="^"+E[$]+E[c]+"$";var V=A++;E[V]="^"+E[$]+E[v]+"$";var F=A++;E[F]="^"+E[o]+"\\s*("+u+")$|^$";var ne=A++;E[ne]="^"+E[o]+"\\s*("+n+")$|^$";var ce=A++;E[ce]="(\\s*)"+E[o]+"\\s*("+u+"|"+E[c]+")",T[ce]=new RegExp(E[ce],"g");var re=A++;E[re]="^\\s*("+E[c]+")\\s+-\\s+("+E[c]+")\\s*$";var fe=A++;E[fe]="^\\s*("+E[v]+")\\s+-\\s+("+E[v]+")\\s*$";var ie=A++;E[ie]="(<|>)?=?\\s*\\*";for(var Ee=0;Ee<35;Ee++)b(Ee,E[Ee]),T[Ee]||(T[Ee]=new RegExp(E[Ee]));function be(Z,pe){if(Z instanceof te)return Z;if(typeof Z!="string"||Z.length>L||!(pe?T[i]:T[_]).test(Z))return null;try{return new te(Z,pe)}catch{return null}}function te(Z,pe){if(Z instanceof te){if(Z.loose===pe)return Z;Z=Z.version}else if(typeof Z!="string")throw new TypeError("Invalid Version: "+Z);if(Z.length>L)throw new TypeError("version is longer than "+L+" characters");if(!(this instanceof te))return new te(Z,pe);b("SemVer",Z,pe),this.loose=pe;var ge=Z.trim().match(pe?T[i]:T[_]);if(!ge)throw new TypeError("Invalid Version: "+Z);if(this.raw=Z,this.major=+ge[1],this.minor=+ge[2],this.patch=+ge[3],this.major>C||this.major<0)throw new TypeError("Invalid major version");if(this.minor>C||this.minor<0)throw new TypeError("Invalid minor version");if(this.patch>C||this.patch<0)throw new TypeError("Invalid patch version");ge[4]?this.prerelease=ge[4].split(".").map(function(Ne){if(/^[0-9]+$/.test(Ne)){var Be=+Ne;if(Be>=0&&Be<C)return Be}return Ne}):this.prerelease=[],this.build=ge[5]?ge[5].split("."):[],this.format()}e.parse=be,e.valid=function(Z,pe){var ge=be(Z,pe);return ge?ge.version:null},e.clean=function(Z,pe){var ge=be(Z.trim().replace(/^[=v]+/,""),pe);return ge?ge.version:null},e.SemVer=te,te.prototype.format=function(){return this.version=this.major+"."+this.minor+"."+this.patch,this.prerelease.length&&(this.version+="-"+this.prerelease.join(".")),this.version},te.prototype.toString=function(){return this.version},te.prototype.compare=function(Z){return b("SemVer.compare",this.version,this.loose,Z),Z instanceof te||(Z=new te(Z,this.loose)),this.compareMain(Z)||this.comparePre(Z)},te.prototype.compareMain=function(Z){return Z instanceof te||(Z=new te(Z,this.loose)),Re(this.major,Z.major)||Re(this.minor,Z.minor)||Re(this.patch,Z.patch)},te.prototype.comparePre=function(Z){if(Z instanceof te||(Z=new te(Z,this.loose)),this.prerelease.length&&!Z.prerelease.length)return-1;if(!this.prerelease.length&&Z.prerelease.length)return 1;if(!this.prerelease.length&&!Z.prerelease.length)return 0;var pe=0;do{var ge=this.prerelease[pe],Ne=Z.prerelease[pe];if(b("prerelease compare",pe,ge,Ne),ge===void 0&&Ne===void 0)return 0;if(Ne===void 0)return 1;if(ge===void 0)return-1;if(ge!==Ne)return Re(ge,Ne)}while(++pe)},te.prototype.inc=function(Z,pe){switch(Z){case"premajor":this.prerelease.length=0,this.patch=0,this.minor=0,this.major++,this.inc("pre",pe);break;case"preminor":this.prerelease.length=0,this.patch=0,this.minor++,this.inc("pre",pe);break;case"prepatch":this.prerelease.length=0,this.inc("patch",pe),this.inc("pre",pe);break;case"prerelease":this.prerelease.length===0&&this.inc("patch",pe),this.inc("pre",pe);break;case"major":this.minor===0&&this.patch===0&&this.prerelease.length!==0||this.major++,this.minor=0,this.patch=0,this.prerelease=[];break;case"minor":this.patch===0&&this.prerelease.length!==0||this.minor++,this.patch=0,this.prerelease=[];break;case"patch":this.prerelease.length===0&&this.patch++,this.prerelease=[];break;case"pre":if(this.prerelease.length===0)this.prerelease=[0];else{for(var ge=this.prerelease.length;--ge>=0;)typeof this.prerelease[ge]=="number"&&(this.prerelease[ge]++,ge=-2);ge===-1&&this.prerelease.push(0)}pe&&(this.prerelease[0]===pe?isNaN(this.prerelease[1])&&(this.prerelease=[pe,0]):this.prerelease=[pe,0]);break;default:throw new Error("invalid increment argument: "+Z)}return this.format(),this.raw=this.version,this},e.inc=function(Z,pe,ge,Ne){typeof ge=="string"&&(Ne=ge,ge=void 0);try{return new te(Z,ge).inc(pe,Ne).version}catch{return null}},e.diff=function(Z,pe){if(Ie(Z,pe))return null;var ge=be(Z),Ne=be(pe);if(ge.prerelease.length||Ne.prerelease.length){for(var Be in ge)if((Be==="major"||Be==="minor"||Be==="patch")&&ge[Be]!==Ne[Be])return"pre"+Be;return"prerelease"}for(var Be in ge)if((Be==="major"||Be==="minor"||Be==="patch")&&ge[Be]!==Ne[Be])return Be},e.compareIdentifiers=Re;var ve=/^[0-9]+$/;function Re(Z,pe){var ge=ve.test(Z),Ne=ve.test(pe);return ge&&Ne&&(Z=+Z,pe=+pe),ge&&!Ne?-1:Ne&&!ge?1:Z<pe?-1:Z>pe?1:0}function Fe(Z,pe,ge){return new te(Z,ge).compare(new te(pe,ge))}function $e(Z,pe,ge){return Fe(Z,pe,ge)>0}function Ye(Z,pe,ge){return Fe(Z,pe,ge)<0}function Ie(Z,pe,ge){return Fe(Z,pe,ge)===0}function Se(Z,pe,ge){return Fe(Z,pe,ge)!==0}function Te(Z,pe,ge){return Fe(Z,pe,ge)>=0}function ae(Z,pe,ge){return Fe(Z,pe,ge)<=0}function le(Z,pe,ge,Ne){var Be;switch(pe){case"===":typeof Z=="object"&&(Z=Z.version),typeof ge=="object"&&(ge=ge.version),Be=Z===ge;break;case"!==":typeof Z=="object"&&(Z=Z.version),typeof ge=="object"&&(ge=ge.version),Be=Z!==ge;break;case"":case"=":case"==":Be=Ie(Z,ge,Ne);break;case"!=":Be=Se(Z,ge,Ne);break;case">":Be=$e(Z,ge,Ne);break;case">=":Be=Te(Z,ge,Ne);break;case"<":Be=Ye(Z,ge,Ne);break;case"<=":Be=ae(Z,ge,Ne);break;default:throw new TypeError("Invalid operator: "+pe)}return Be}function X(Z,pe){if(Z instanceof X){if(Z.loose===pe)return Z;Z=Z.value}if(!(this instanceof X))return new X(Z,pe);b("comparator",Z,pe),this.loose=pe,this.parse(Z),this.semver===J?this.value="":this.value=this.operator+this.semver.version,b("comp",this)}e.rcompareIdentifiers=function(Z,pe){return Re(pe,Z)},e.major=function(Z,pe){return new te(Z,pe).major},e.minor=function(Z,pe){return new te(Z,pe).minor},e.patch=function(Z,pe){return new te(Z,pe).patch},e.compare=Fe,e.compareLoose=function(Z,pe){return Fe(Z,pe,!0)},e.rcompare=function(Z,pe,ge){return Fe(pe,Z,ge)},e.sort=function(Z,pe){return Z.sort(function(ge,Ne){return e.compare(ge,Ne,pe)})},e.rsort=function(Z,pe){return Z.sort(function(ge,Ne){return e.rcompare(ge,Ne,pe)})},e.gt=$e,e.lt=Ye,e.eq=Ie,e.neq=Se,e.gte=Te,e.lte=ae,e.cmp=le,e.Comparator=X;var J={};function k(Z,pe){if(Z instanceof k)return Z.loose===pe?Z:new k(Z.raw,pe);if(Z instanceof X)return new k(Z.value,pe);if(!(this instanceof k))return new k(Z,pe);if(this.loose=pe,this.raw=Z,this.set=Z.split(/\s*\|\|\s*/).map(function(ge){return this.parseRange(ge.trim())},this).filter(function(ge){return ge.length}),!this.set.length)throw new TypeError("Invalid SemVer Range: "+Z);this.format()}function B(Z){return!Z||Z.toLowerCase()==="x"||Z==="*"}function H(Z,pe,ge,Ne,Be,Ze,Ke,ke,nt,G,Q,he,Ue){return((pe=B(ge)?"":B(Ne)?">="+ge+".0.0":B(Be)?">="+ge+"."+Ne+".0":">="+pe)+" "+(ke=B(nt)?"":B(G)?"<"+(+nt+1)+".0.0":B(Q)?"<"+nt+"."+(+G+1)+".0":he?"<="+nt+"."+G+"."+Q+"-"+he:"<="+ke)).trim()}function j(Z,pe){for(var ge=0;ge<Z.length;ge++)if(!Z[ge].test(pe))return!1;if(pe.prerelease.length){for(ge=0;ge<Z.length;ge++)if(b(Z[ge].semver),Z[ge].semver!==J&&Z[ge].semver.prerelease.length>0){var Ne=Z[ge].semver;if(Ne.major===pe.major&&Ne.minor===pe.minor&&Ne.patch===pe.patch)return!0}return!1}return!0}function oe(Z,pe,ge){try{pe=new k(pe,ge)}catch{return!1}return pe.test(Z)}function ue(Z,pe,ge,Ne){var Be,Ze,Ke,ke,nt;switch(Z=new te(Z,Ne),pe=new k(pe,Ne),ge){case">":Be=$e,Ze=ae,Ke=Ye,ke=">",nt=">=";break;case"<":Be=Ye,Ze=Te,Ke=$e,ke="<",nt="<=";break;default:throw new TypeError('Must provide a hilo val of "<" or ">"')}if(oe(Z,pe,Ne))return!1;for(var G=0;G<pe.set.length;++G){var Q=pe.set[G],he=null,Ue=null;if(Q.forEach(function(We){We.semver===J&&(We=new X(">=0.0.0")),he=he||We,Ue=Ue||We,Be(We.semver,he.semver,Ne)?he=We:Ke(We.semver,Ue.semver,Ne)&&(Ue=We)}),he.operator===ke||he.operator===nt||(!Ue.operator||Ue.operator===ke)&&Ze(Z,Ue.semver)||Ue.operator===nt&&Ke(Z,Ue.semver))return!1}return!0}X.prototype.parse=function(Z){var pe=this.loose?T[F]:T[ne],ge=Z.match(pe);if(!ge)throw new TypeError("Invalid comparator: "+Z);this.operator=ge[1],this.operator==="="&&(this.operator=""),ge[2]?this.semver=new te(ge[2],this.loose):this.semver=J},X.prototype.toString=function(){return this.value},X.prototype.test=function(Z){return b("Comparator.test",Z,this.loose),this.semver===J||(typeof Z=="string"&&(Z=new te(Z,this.loose)),le(Z,this.operator,this.semver,this.loose))},X.prototype.intersects=function(Z,pe){if(!(Z instanceof X))throw new TypeError("a Comparator is required");var ge;if(this.operator==="")return ge=new k(Z.value,pe),oe(this.value,ge,pe);if(Z.operator==="")return ge=new k(this.value,pe),oe(Z.semver,ge,pe);var Ne=!(this.operator!==">="&&this.operator!==">"||Z.operator!==">="&&Z.operator!==">"),Be=!(this.operator!=="<="&&this.operator!=="<"||Z.operator!=="<="&&Z.operator!=="<"),Ze=this.semver.version===Z.semver.version,Ke=!(this.operator!==">="&&this.operator!=="<="||Z.operator!==">="&&Z.operator!=="<="),ke=le(this.semver,"<",Z.semver,pe)&&(this.operator===">="||this.operator===">")&&(Z.operator==="<="||Z.operator==="<"),nt=le(this.semver,">",Z.semver,pe)&&(this.operator==="<="||this.operator==="<")&&(Z.operator===">="||Z.operator===">");return Ne||Be||Ze&&Ke||ke||nt},e.Range=k,k.prototype.format=function(){return this.range=this.set.map(function(Z){return Z.join(" ").trim()}).join("||").trim(),this.range},k.prototype.toString=function(){return this.range},k.prototype.parseRange=function(Z){var pe=this.loose;Z=Z.trim(),b("range",Z,pe);var ge=pe?T[fe]:T[re];Z=Z.replace(ge,H),b("hyphen replace",Z),Z=Z.replace(T[ce],"$1$2$3"),b("comparator trim",Z,T[ce]),Z=(Z=(Z=Z.replace(T[M],"$1~")).replace(T[N],"$1^")).split(/\s+/).join(" ");var Ne=pe?T[F]:T[ne],Be=Z.split(" ").map(function(Ze){return function(Ke,ke){return b("comp",Ke),Ke=function(nt,G){return nt.trim().split(/\s+/).map(function(Q){return function(he,Ue){b("caret",he,Ue);var We=Ue?T[V]:T[K];return he.replace(We,function(et,je,He,it,rt){var dt;return b("caret",he,et,je,He,it,rt),B(je)?dt="":B(He)?dt=">="+je+".0.0 <"+(+je+1)+".0.0":B(it)?dt=je==="0"?">="+je+"."+He+".0 <"+je+"."+(+He+1)+".0":">="+je+"."+He+".0 <"+(+je+1)+".0.0":rt?(b("replaceCaret pr",rt),rt.charAt(0)!=="-"&&(rt="-"+rt),dt=je==="0"?He==="0"?">="+je+"."+He+"."+it+rt+" <"+je+"."+He+"."+(+it+1):">="+je+"."+He+"."+it+rt+" <"+je+"."+(+He+1)+".0":">="+je+"."+He+"."+it+rt+" <"+(+je+1)+".0.0"):(b("no pr"),dt=je==="0"?He==="0"?">="+je+"."+He+"."+it+" <"+je+"."+He+"."+(+it+1):">="+je+"."+He+"."+it+" <"+je+"."+(+He+1)+".0":">="+je+"."+He+"."+it+" <"+(+je+1)+".0.0"),b("caret return",dt),dt})}(Q,G)}).join(" ")}(Ke,ke),b("caret",Ke),Ke=function(nt,G){return nt.trim().split(/\s+/).map(function(Q){return function(he,Ue){var We=Ue?T[z]:T[S];return he.replace(We,function(et,je,He,it,rt){var dt;return b("tilde",he,et,je,He,it,rt),B(je)?dt="":B(He)?dt=">="+je+".0.0 <"+(+je+1)+".0.0":B(it)?dt=">="+je+"."+He+".0 <"+je+"."+(+He+1)+".0":rt?(b("replaceTilde pr",rt),rt.charAt(0)!=="-"&&(rt="-"+rt),dt=">="+je+"."+He+"."+it+rt+" <"+je+"."+(+He+1)+".0"):dt=">="+je+"."+He+"."+it+" <"+je+"."+(+He+1)+".0",b("tilde return",dt),dt})}(Q,G)}).join(" ")}(Ke,ke),b("tildes",Ke),Ke=function(nt,G){return b("replaceXRanges",nt,G),nt.split(/\s+/).map(function(Q){return function(he,Ue){he=he.trim();var We=Ue?T[D]:T[g];return he.replace(We,function(et,je,He,it,rt,dt){b("xRange",he,et,je,He,it,rt,dt);var lt=B(He),st=lt||B(it),yt=st||B(rt);return je==="="&&yt&&(je=""),lt?et=je===">"||je==="<"?"<0.0.0":"*":je&&yt?(st&&(it=0),yt&&(rt=0),je===">"?(je=">=",st?(He=+He+1,it=0,rt=0):yt&&(it=+it+1,rt=0)):je==="<="&&(je="<",st?He=+He+1:it=+it+1),et=je+He+"."+it+"."+rt):st?et=">="+He+".0.0 <"+(+He+1)+".0.0":yt&&(et=">="+He+"."+it+".0 <"+He+"."+(+it+1)+".0"),b("xRange return",et),et})}(Q,G)}).join(" ")}(Ke,ke),b("xrange",Ke),Ke=function(nt,G){return b("replaceStars",nt,G),nt.trim().replace(T[ie],"")}(Ke,ke),b("stars",Ke),Ke}(Ze,pe)}).join(" ").split(/\s+/);return this.loose&&(Be=Be.filter(function(Ze){return!!Ze.match(Ne)})),Be=Be.map(function(Ze){return new X(Ze,pe)})},k.prototype.intersects=function(Z,pe){if(!(Z instanceof k))throw new TypeError("a Range is required");return this.set.some(function(ge){return ge.every(function(Ne){return Z.set.some(function(Be){return Be.every(function(Ze){return Ne.intersects(Ze,pe)})})})})},e.toComparators=function(Z,pe){return new k(Z,pe).set.map(function(ge){return ge.map(function(Ne){return Ne.value}).join(" ").trim().split(" ")})},k.prototype.test=function(Z){if(!Z)return!1;typeof Z=="string"&&(Z=new te(Z,this.loose));for(var pe=0;pe<this.set.length;pe++)if(j(this.set[pe],Z))return!0;return!1},e.satisfies=oe,e.maxSatisfying=function(Z,pe,ge){var Ne=null,Be=null;try{var Ze=new k(pe,ge)}catch{return null}return Z.forEach(function(Ke){Ze.test(Ke)&&(Ne&&Be.compare(Ke)!==-1||(Be=new te(Ne=Ke,ge)))}),Ne},e.minSatisfying=function(Z,pe,ge){var Ne=null,Be=null;try{var Ze=new k(pe,ge)}catch{return null}return Z.forEach(function(Ke){Ze.test(Ke)&&(Ne&&Be.compare(Ke)!==1||(Be=new te(Ne=Ke,ge)))}),Ne},e.validRange=function(Z,pe){try{return new k(Z,pe).range||"*"}catch{return null}},e.ltr=function(Z,pe,ge){return ue(Z,pe,"<",ge)},e.gtr=function(Z,pe,ge){return ue(Z,pe,">",ge)},e.outside=ue,e.prerelease=function(Z,pe){var ge=be(Z,pe);return ge&&ge.prerelease.length?ge.prerelease:null},e.intersects=function(Z,pe,ge){return Z=new k(Z,ge),pe=new k(pe,ge),Z.intersects(pe)},e.coerce=function(Z){if(Z instanceof te)return Z;if(typeof Z!="string")return null;var pe=Z.match(T[U]);return pe==null?null:be((pe[1]||"0")+"."+(pe[2]||"0")+"."+(pe[3]||"0"))}}).call(this,s(1))},function(ee,e){var s,p,b=ee.exports={};function L(){throw new Error("setTimeout has not been defined")}function C(){throw new Error("clearTimeout has not been defined")}function T(d){if(s===setTimeout)return setTimeout(d,0);if((s===L||!s)&&setTimeout)return s=setTimeout,setTimeout(d,0);try{return s(d,0)}catch{try{return s.call(null,d,0)}catch{return s.call(this,d,0)}}}(function(){try{s=typeof setTimeout=="function"?setTimeout:L}catch{s=L}try{p=typeof clearTimeout=="function"?clearTimeout:C}catch{p=C}})();var E,A=[],R=!1,y=-1;function m(){R&&E&&(R=!1,E.length?A=E.concat(A):y=-1,A.length&&I())}function I(){if(!R){var d=T(m);R=!0;for(var a=A.length;a;){for(E=A,A=[];++y<a;)E&&E[y].run();y=-1,a=A.length}E=null,R=!1,function(w){if(p===clearTimeout)return clearTimeout(w);if((p===C||!p)&&clearTimeout)return p=clearTimeout,clearTimeout(w);try{p(w)}catch{try{return p.call(null,w)}catch{return p.call(this,w)}}}(d)}}function f(d,a){this.fun=d,this.array=a}function h(){}b.nextTick=function(d){var a=new Array(arguments.length-1);if(arguments.length>1)for(var w=1;w<arguments.length;w++)a[w-1]=arguments[w];A.push(new f(d,a)),A.length!==1||R||T(I)},f.prototype.run=function(){this.fun.apply(null,this.array)},b.title="browser",b.browser=!0,b.env={},b.argv=[],b.version="",b.versions={},b.on=h,b.addListener=h,b.once=h,b.off=h,b.removeListener=h,b.removeAllListeners=h,b.emit=h,b.prependListener=h,b.prependOnceListener=h,b.listeners=function(d){return[]},b.binding=function(d){throw new Error("process.binding is not supported")},b.cwd=function(){return"/"},b.chdir=function(d){throw new Error("process.chdir is not supported")},b.umask=function(){return 0}}])}),define(ye[107],Ce([1,0,11,7]),function(ee,e,s,p){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.prefixedStream=e.prefixedReadable=e.transform=e.toReadable=e.emptyStream=e.toStream=e.peekStream=e.listenStream=e.consumeStream=e.peekReadable=e.consumeReadable=e.newWriteableStream=e.isReadableBufferedStream=e.isReadableStream=e.isReadable=void 0;function b(l){const _=l;return _?typeof _.read=="function":!1}e.isReadable=b;function L(l){const _=l;return _?[_.on,_.pause,_.resume,_.destroy].every(n=>typeof n=="function"):!1}e.isReadableStream=L;function C(l){const _=l;return _?L(_.stream)&&Array.isArray(_.buffer)&&typeof _.ended=="boolean":!1}e.isReadableBufferedStream=C;function T(l,_){return new E(l,_)}e.newWriteableStream=T;class E{constructor(_,n){this.reducer=_,this.options=n,this.state={flowing:!1,ended:!1,destroyed:!1},this.buffer={data:[],error:[]},this.listeners={data:[],error:[],end:[]},this.pendingWritePromises=[]}pause(){this.state.destroyed||(this.state.flowing=!1)}resume(){this.state.destroyed||this.state.flowing||(this.state.flowing=!0,this.flowData(),this.flowErrors(),this.flowEnd())}write(_){if(!this.state.destroyed){if(this.state.flowing)this.emitData(_);else if(this.buffer.data.push(_),typeof this.options?.highWaterMark=="number"&&this.buffer.data.length>this.options.highWaterMark)return new Promise(n=>this.pendingWritePromises.push(n))}}error(_){this.state.destroyed||(this.state.flowing?this.emitError(_):this.buffer.error.push(_))}end(_){this.state.destroyed||(typeof _!="undefined"&&this.write(_),this.state.flowing?(this.emitEnd(),this.destroy()):this.state.ended=!0)}emitData(_){this.listeners.data.slice(0).forEach(n=>n(_))}emitError(_){this.listeners.error.length===0?(0,s.onUnexpectedError)(_):this.listeners.error.slice(0).forEach(n=>n(_))}emitEnd(){this.listeners.end.slice(0).forEach(_=>_())}on(_,n){if(!this.state.destroyed)switch(_){case"data":this.listeners.data.push(n),this.resume();break;case"end":this.listeners.end.push(n),this.state.flowing&&this.flowEnd()&&this.destroy();break;case"error":this.listeners.error.push(n),this.state.flowing&&this.flowErrors();break}}removeListener(_,n){if(this.state.destroyed)return;let u;switch(_){case"data":u=this.listeners.data;break;case"end":u=this.listeners.end;break;case"error":u=this.listeners.error;break}if(u){const i=u.indexOf(n);i>=0&&u.splice(i,1)}}flowData(){if(this.buffer.data.length>0){const _=this.reducer(this.buffer.data);this.emitData(_),this.buffer.data.length=0;const n=[...this.pendingWritePromises];this.pendingWritePromises.length=0,n.forEach(u=>u())}}flowErrors(){if(this.listeners.error.length>0){for(const _ of this.buffer.error)this.emitError(_);this.buffer.error.length=0}}flowEnd(){return this.state.ended?(this.emitEnd(),this.listeners.end.length>0):!1}destroy(){this.state.destroyed||(this.state.destroyed=!0,this.state.ended=!0,this.buffer.data.length=0,this.buffer.error.length=0,this.listeners.data.length=0,this.listeners.error.length=0,this.listeners.end.length=0,this.pendingWritePromises.length=0)}}function A(l,_){const n=[];let u;for(;(u=l.read())!==null;)n.push(u);return _(n)}e.consumeReadable=A;function R(l,_,n){const u=[];let i;for(;(i=l.read())!==null&&u.length<n;)u.push(i);return i===null&&u.length>0?_(u):{read:()=>{if(u.length>0)return u.shift();if(typeof i!="undefined"){const o=i;return i=void 0,o}return l.read()}}}e.peekReadable=R;function y(l,_){return new Promise((n,u)=>{const i=[];m(l,{onData:o=>{_&&i.push(o)},onError:o=>{_?u(o):n(void 0)},onEnd:()=>{n(_?_(i):void 0)}})})}e.consumeStream=y;function m(l,_){let n=!1;return l.on("error",u=>{n||_.onError(u)}),l.on("end",()=>{n||_.onEnd()}),l.on("data",u=>{n||_.onData(u)}),(0,p.toDisposable)(()=>n=!0)}e.listenStream=m;function I(l,_){return new Promise((n,u)=>{const i=new p.DisposableStore,o=[],r=v=>{if(o.push(v),o.length>_)return i.dispose(),l.pause(),n({stream:l,buffer:o,ended:!1})},t=v=>u(v),c=()=>n({stream:l,buffer:o,ended:!0});i.add((0,p.toDisposable)(()=>l.removeListener("error",t))),l.on("error",t),i.add((0,p.toDisposable)(()=>l.removeListener("end",c))),l.on("end",c),i.add((0,p.toDisposable)(()=>l.removeListener("data",r))),l.on("data",r)})}e.peekStream=I;function f(l,_){const n=T(_);return n.end(l),n}e.toStream=f;function h(){const l=T(()=>{throw new Error("not supported")});return l.end(),l}e.emptyStream=h;function d(l){let _=!1;return{read:()=>_?null:(_=!0,l)}}e.toReadable=d;function a(l,_,n){const u=T(n);return m(l,{onData:i=>u.write(_.data(i)),onError:i=>u.error(_.error?_.error(i):i),onEnd:()=>u.end()}),u}e.transform=a;function w(l,_,n){let u=!1;return{read:()=>{const i=_.read();return u?i:(u=!0,i!==null?n([l,i]):l)}}}e.prefixedReadable=w;function P(l,_,n){let u=!1;const i=T(n);return m(_,{onData:o=>u?i.write(o):(u=!0,i.write(n([l,o]))),onError:o=>i.error(o),onEnd:()=>{u||(u=!0,i.write(l)),i.end()}}),i}e.prefixedStream=P}),define(ye[22],Ce([1,0,107]),function(ee,e,s){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.encodeBase64=e.decodeBase64=e.prefixedBufferStream=e.prefixedBufferReadable=e.newWriteableBufferStream=e.streamToBufferReadableStream=e.bufferToStream=e.bufferedStreamToBuffer=e.streamToBuffer=e.bufferToReadable=e.readableToBuffer=e.writeUInt8=e.readUInt8=e.writeUInt32LE=e.readUInt32LE=e.writeUInt32BE=e.readUInt32BE=e.writeUInt16LE=e.readUInt16LE=e.VSBuffer=void 0;const p=typeof Buffer!="undefined";let b,L;class C{constructor(v){this.buffer=v,this.byteLength=this.buffer.byteLength}static alloc(v){return p?new C(Buffer.allocUnsafe(v)):new C(new Uint8Array(v))}static wrap(v){return p&&!Buffer.isBuffer(v)&&(v=Buffer.from(v.buffer,v.byteOffset,v.byteLength)),new C(v)}static fromString(v,g){return!(g?.dontUseNodeBuffer||!1)&&p?new C(Buffer.from(v)):(b||(b=new TextEncoder),new C(b.encode(v)))}static fromByteArray(v){const g=C.alloc(v.length);for(let D=0,U=v.length;D<U;D++)g.buffer[D]=v[D];return g}static concat(v,g){if(typeof g=="undefined"){g=0;for(let W=0,M=v.length;W<M;W++)g+=v[W].byteLength}const D=C.alloc(g);let U=0;for(let W=0,M=v.length;W<M;W++){const S=v[W];D.set(S,U),U+=S.byteLength}return D}clone(){const v=C.alloc(this.byteLength);return v.set(this),v}toString(){return p?this.buffer.toString():(L||(L=new TextDecoder),L.decode(this.buffer))}slice(v,g){return new C(this.buffer.subarray(v,g))}set(v,g){if(v instanceof C)this.buffer.set(v.buffer,g);else if(v instanceof Uint8Array)this.buffer.set(v,g);else if(v instanceof ArrayBuffer)this.buffer.set(new Uint8Array(v),g);else if(ArrayBuffer.isView(v))this.buffer.set(new Uint8Array(v.buffer,v.byteOffset,v.byteLength),g);else throw new Error("Unknown argument 'array'")}readUInt32BE(v){return A(this.buffer,v)}writeUInt32BE(v,g){R(this.buffer,v,g)}readUInt32LE(v){return y(this.buffer,v)}writeUInt32LE(v,g){m(this.buffer,v,g)}readUInt8(v){return I(this.buffer,v)}writeUInt8(v,g){f(this.buffer,v,g)}}e.VSBuffer=C;function T(c,v){return c[v+0]<<0>>>0|c[v+1]<<8>>>0}e.readUInt16LE=T;function E(c,v,g){c[g+0]=v&255,v=v>>>8,c[g+1]=v&255}e.writeUInt16LE=E;function A(c,v){return c[v]*2**24+c[v+1]*2**16+c[v+2]*2**8+c[v+3]}e.readUInt32BE=A;function R(c,v,g){c[g+3]=v,v=v>>>8,c[g+2]=v,v=v>>>8,c[g+1]=v,v=v>>>8,c[g]=v}e.writeUInt32BE=R;function y(c,v){return c[v+0]<<0>>>0|c[v+1]<<8>>>0|c[v+2]<<16>>>0|c[v+3]<<24>>>0}e.readUInt32LE=y;function m(c,v,g){c[g+0]=v&255,v=v>>>8,c[g+1]=v&255,v=v>>>8,c[g+2]=v&255,v=v>>>8,c[g+3]=v&255}e.writeUInt32LE=m;function I(c,v){return c[v]}e.readUInt8=I;function f(c,v,g){c[g]=v}e.writeUInt8=f;function h(c){return s.consumeReadable(c,v=>C.concat(v))}e.readableToBuffer=h;function d(c){return s.toReadable(c)}e.bufferToReadable=d;function a(c){return s.consumeStream(c,v=>C.concat(v))}e.streamToBuffer=a;async function w(c){return c.ended?C.concat(c.buffer):C.concat([...c.buffer,await a(c.stream)])}e.bufferedStreamToBuffer=w;function P(c){return s.toStream(c,v=>C.concat(v))}e.bufferToStream=P;function l(c){return s.transform(c,{data:v=>typeof v=="string"?C.fromString(v):C.wrap(v)},v=>C.concat(v))}e.streamToBufferReadableStream=l;function _(c){return s.newWriteableStream(v=>C.concat(v),c)}e.newWriteableBufferStream=_;function n(c,v){return s.prefixedReadable(c,v,g=>C.concat(g))}e.prefixedBufferReadable=n;function u(c,v){return s.prefixedStream(c,v,g=>C.concat(g))}e.prefixedBufferStream=u;function i(c){let v=0,g=0,D=0;const U=new Uint8Array(Math.floor(c.length/4*3)),W=S=>{switch(g){case 3:U[D++]=v|S,g=0;break;case 2:U[D++]=v|S>>>2,v=S<<6,g=3;break;case 1:U[D++]=v|S>>>4,v=S<<4,g=2;break;default:v=S<<2,g=1}};for(let S=0;S<c.length;S++){const z=c.charCodeAt(S);if(z>=65&&z<=90)W(z-65);else if(z>=97&&z<=122)W(z-97+26);else if(z>=48&&z<=57)W(z-48+52);else if(z===43||z===45)W(62);else if(z===47||z===95)W(63);else{if(z===61)break;throw new SyntaxError(`Unexpected base64 character ${c[S]}`)}}const M=D;for(;g>0;)W(0);return C.wrap(U).slice(0,M)}e.decodeBase64=i;const o="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",r="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-_";function t({buffer:c},v=!0,g=!1){const D=g?r:o;let U="";const W=c.byteLength%3;let M=0;for(;M<c.byteLength-W;M+=3){const S=c[M+0],z=c[M+1],$=c[M+2];U+=D[S>>>2],U+=D[(S<<4|z>>>4)&63],U+=D[(z<<2|$>>>6)&63],U+=D[$&63]}if(W===1){const S=c[M+0];U+=D[S>>>2],U+=D[S<<4&63],v&&(U+="==")}else if(W===2){const S=c[M+0],z=c[M+1];U+=D[S>>>2],U+=D[(S<<4|z>>>4)&63],U+=D[z<<2&63],v&&(U+="=")}return U}e.encodeBase64=t});var Je=this&&this.__classPrivateFieldSet||function(ee,e,s,p,b){if(p==="m")throw new TypeError("Private method is not writable");if(p==="a"&&!b)throw new TypeError("Private accessor was defined without a setter");if(typeof e=="function"?ee!==e||!b:!e.has(ee))throw new TypeError("Cannot write private member to an object whose class did not declare it");return p==="a"?b.call(ee,s):b?b.value=s:e.set(ee,s),s},Ae=this&&this.__classPrivateFieldGet||function(ee,e,s,p){if(s==="a"&&!p)throw new TypeError("Private accessor was defined without a getter");if(typeof e=="function"?ee!==e||!p:!e.has(ee))throw new TypeError("Cannot read private member from an object whose class did not declare it");return s==="m"?p:s==="a"?p.call(ee):p?p.value:e.get(ee)};define(ye[25],Ce([1,0,16,9]),function(ee,e,s,p){"use strict";var b,L,C,T;Object.defineProperty(e,"__esModule",{value:!0}),e.ReadonlyMapView=e.LRUCache=e.LinkedMap=e.Touch=e.ResourceSet=e.ResourceMap=e.TernarySearchTree=e.UriIterator=e.PathIterator=e.ConfigKeysIterator=e.StringIterator=e.setToString=e.mapToString=e.getOrSet=void 0;function E(r,t,c){let v=r.get(t);return v===void 0&&(v=c,r.set(t,v)),v}e.getOrSet=E;function A(r){const t=[];return r.forEach((c,v)=>{t.push(`${v} => ${c}`)}),`Map(${r.size}) {${t.join(", ")}}`}e.mapToString=A;function R(r){const t=[];return r.forEach(c=>{t.push(c)}),`Set(${r.size}) {${t.join(", ")}}`}e.setToString=R;class y{constructor(){this._value="",this._pos=0}reset(t){return this._value=t,this._pos=0,this}next(){return this._pos+=1,this}hasNext(){return this._pos<this._value.length-1}cmp(t){const c=t.charCodeAt(0),v=this._value.charCodeAt(this._pos);return c-v}value(){return this._value[this._pos]}}e.StringIterator=y;class m{constructor(t=!0){this._caseSensitive=t}reset(t){return this._value=t,this._from=0,this._to=0,this.next()}hasNext(){return this._to<this._value.length}next(){this._from=this._to;let t=!0;for(;this._to<this._value.length;this._to++)if(this._value.charCodeAt(this._to)===46)if(t)this._from++;else break;else t=!1;return this}cmp(t){return this._caseSensitive?(0,p.compareSubstring)(t,this._value,0,t.length,this._from,this._to):(0,p.compareSubstringIgnoreCase)(t,this._value,0,t.length,this._from,this._to)}value(){return this._value.substring(this._from,this._to)}}e.ConfigKeysIterator=m;class I{constructor(t=!0,c=!0){this._splitOnBackslash=t,this._caseSensitive=c}reset(t){this._from=0,this._to=0,this._value=t,this._valueLen=t.length;for(let c=t.length-1;c>=0;c--,this._valueLen--){const v=this._value.charCodeAt(c);if(!(v===47||this._splitOnBackslash&&v===92))break}return this.next()}hasNext(){return this._to<this._valueLen}next(){this._from=this._to;let t=!0;for(;this._to<this._valueLen;this._to++){const c=this._value.charCodeAt(this._to);if(c===47||this._splitOnBackslash&&c===92)if(t)this._from++;else break;else t=!1}return this}cmp(t){return this._caseSensitive?(0,p.compareSubstring)(t,this._value,0,t.length,this._from,this._to):(0,p.compareSubstringIgnoreCase)(t,this._value,0,t.length,this._from,this._to)}value(){return this._value.substring(this._from,this._to)}}e.PathIterator=I;var f;(function(r){r[r.Scheme=1]="Scheme",r[r.Authority=2]="Authority",r[r.Path=3]="Path",r[r.Query=4]="Query",r[r.Fragment=5]="Fragment"})(f||(f={}));class h{constructor(t,c){this._ignorePathCasing=t,this._ignoreQueryAndFragment=c,this._states=[],this._stateIdx=0}reset(t){return this._value=t,this._states=[],this._value.scheme&&this._states.push(1),this._value.authority&&this._states.push(2),this._value.path&&(this._pathIterator=new I(!1,!this._ignorePathCasing(t)),this._pathIterator.reset(t.path),this._pathIterator.value()&&this._states.push(3)),this._ignoreQueryAndFragment(t)||(this._value.query&&this._states.push(4),this._value.fragment&&this._states.push(5)),this._stateIdx=0,this}next(){return this._states[this._stateIdx]===3&&this._pathIterator.hasNext()?this._pathIterator.next():this._stateIdx+=1,this}hasNext(){return this._states[this._stateIdx]===3&&this._pathIterator.hasNext()||this._stateIdx<this._states.length-1}cmp(t){if(this._states[this._stateIdx]===1)return(0,p.compareIgnoreCase)(t,this._value.scheme);if(this._states[this._stateIdx]===2)return(0,p.compareIgnoreCase)(t,this._value.authority);if(this._states[this._stateIdx]===3)return this._pathIterator.cmp(t);if(this._states[this._stateIdx]===4)return(0,p.compare)(t,this._value.query);if(this._states[this._stateIdx]===5)return(0,p.compare)(t,this._value.fragment);throw new Error}value(){if(this._states[this._stateIdx]===1)return this._value.scheme;if(this._states[this._stateIdx]===2)return this._value.authority;if(this._states[this._stateIdx]===3)return this._pathIterator.value();if(this._states[this._stateIdx]===4)return this._value.query;if(this._states[this._stateIdx]===5)return this._value.fragment;throw new Error}}e.UriIterator=h;class d{constructor(){this.height=1}isEmpty(){return!this.left&&!this.mid&&!this.right&&!this.value}rotateLeft(){const t=this.right;return this.right=t.left,t.left=this,this.updateHeight(),t.updateHeight(),t}rotateRight(){const t=this.left;return this.left=t.right,t.right=this,this.updateHeight(),t.updateHeight(),t}updateHeight(){this.height=1+Math.max(this.heightLeft,this.heightRight)}balanceFactor(){return this.heightRight-this.heightLeft}get heightLeft(){return this.left?.height??0}get heightRight(){return this.right?.height??0}}var a;(function(r){r[r.Left=-1]="Left",r[r.Mid=0]="Mid",r[r.Right=1]="Right"})(a||(a={}));class w{constructor(t){this._iter=t}static forUris(t=()=>!1,c=()=>!1){return new w(new h(t,c))}static forPaths(t=!1){return new w(new I(void 0,!t))}static forStrings(){return new w(new y)}static forConfigKeys(){return new w(new m)}clear(){this._root=void 0}fill(t,c){if(c){const v=c.slice(0);(0,s.shuffle)(v);for(const g of v)this.set(g,t)}else{const v=t.slice(0);(0,s.shuffle)(v);for(const g of v)this.set(g[0],g[1])}}set(t,c){const v=this._iter.reset(t);let g;this._root||(this._root=new d,this._root.segment=v.value());const D=[];for(g=this._root;;){const W=v.cmp(g.segment);if(W>0)g.left||(g.left=new d,g.left.segment=v.value()),D.push([-1,g]),g=g.left;else if(W<0)g.right||(g.right=new d,g.right.segment=v.value()),D.push([1,g]),g=g.right;else if(v.hasNext())v.next(),g.mid||(g.mid=new d,g.mid.segment=v.value()),D.push([0,g]),g=g.mid;else break}const U=g.value;g.value=c,g.key=t;for(let W=D.length-1;W>=0;W--){const M=D[W][1];M.updateHeight();const S=M.balanceFactor();if(S<-1||S>1){const z=D[W][0],$=D[W+1][0];if(z===1&&$===1)D[W][1]=M.rotateLeft();else if(z===-1&&$===-1)D[W][1]=M.rotateRight();else if(z===1&&$===-1)M.right=D[W+1][1]=D[W+1][1].rotateRight(),D[W][1]=M.rotateLeft();else if(z===-1&&$===1)M.left=D[W+1][1]=D[W+1][1].rotateLeft(),D[W][1]=M.rotateRight();else throw new Error;if(W>0)switch(D[W-1][0]){case-1:D[W-1][1].left=D[W][1];break;case 1:D[W-1][1].right=D[W][1];break;case 0:D[W-1][1].mid=D[W][1];break}else this._root=D[0][1]}}return U}get(t){return this._getNode(t)?.value}_getNode(t){const c=this._iter.reset(t);let v=this._root;for(;v;){const g=c.cmp(v.segment);if(g>0)v=v.left;else if(g<0)v=v.right;else if(c.hasNext())c.next(),v=v.mid;else break}return v}has(t){const c=this._getNode(t);return!(c?.value===void 0&&c?.mid===void 0)}delete(t){return this._delete(t,!1)}deleteSuperstr(t){return this._delete(t,!0)}_delete(t,c){const v=this._iter.reset(t),g=[];let D=this._root;for(;D;){const U=v.cmp(D.segment);if(U>0)g.push([-1,D]),D=D.left;else if(U<0)g.push([1,D]),D=D.right;else if(v.hasNext())v.next(),g.push([0,D]),D=D.mid;else break}if(!!D){if(c?(D.left=void 0,D.mid=void 0,D.right=void 0,D.height=1):(D.key=void 0,D.value=void 0),!D.mid&&!D.value)if(D.left&&D.right){const U=this._min(D.right),{key:W,value:M,segment:S}=U;this._delete(U.key,!1),D.key=W,D.value=M,D.segment=S}else{const U=D.left??D.right;if(g.length>0){const[W,M]=g[g.length-1];switch(W){case-1:M.left=U;break;case 0:M.mid=U;break;case 1:M.right=U;break}}else this._root=U}for(let U=g.length-1;U>=0;U--){const W=g[U][1];W.updateHeight();const M=W.balanceFactor();if(M>1?(W.right.balanceFactor()>=0||(W.right=W.right.rotateRight()),g[U][1]=W.rotateLeft()):M<-1&&(W.left.balanceFactor()<=0||(W.left=W.left.rotateLeft()),g[U][1]=W.rotateRight()),U>0)switch(g[U-1][0]){case-1:g[U-1][1].left=g[U][1];break;case 1:g[U-1][1].right=g[U][1];break;case 0:g[U-1][1].mid=g[U][1];break}else this._root=g[0][1]}}}_min(t){for(;t.left;)t=t.left;return t}findSubstr(t){const c=this._iter.reset(t);let v=this._root,g;for(;v;){const D=c.cmp(v.segment);if(D>0)v=v.left;else if(D<0)v=v.right;else if(c.hasNext())c.next(),g=v.value||g,v=v.mid;else break}return v&&v.value||g}findSuperstr(t){const c=this._iter.reset(t);let v=this._root;for(;v;){const g=c.cmp(v.segment);if(g>0)v=v.left;else if(g<0)v=v.right;else if(c.hasNext())c.next(),v=v.mid;else return v.mid?this._entries(v.mid):void 0}}forEach(t){for(const[c,v]of this)t(v,c)}*[Symbol.iterator](){yield*this._entries(this._root)}_entries(t){const c=[];return this._dfsEntries(t,c),c[Symbol.iterator]()}_dfsEntries(t,c){!t||(t.left&&this._dfsEntries(t.left,c),t.value&&c.push([t.key,t.value]),t.mid&&this._dfsEntries(t.mid,c),t.right&&this._dfsEntries(t.right,c))}_isBalanced(){const t=c=>{if(!c)return!0;const v=c.balanceFactor();return v<-1||v>1?!1:t(c.left)&&t(c.right)};return t(this._root)}}e.TernarySearchTree=w;class P{constructor(t,c){this.uri=t,this.value=c}}class l{constructor(t,c){this[b]="ResourceMap",t instanceof l?(this.map=new Map(t.map),this.toKey=c??l.defaultToKey):(this.map=new Map,this.toKey=t??l.defaultToKey)}set(t,c){return this.map.set(this.toKey(t),new P(t,c)),this}get(t){return this.map.get(this.toKey(t))?.value}has(t){return this.map.has(this.toKey(t))}get size(){return this.map.size}clear(){this.map.clear()}delete(t){return this.map.delete(this.toKey(t))}forEach(t,c){typeof c!="undefined"&&(t=t.bind(c));for(const[v,g]of this.map)t(g.value,g.uri,this)}*values(){for(const t of this.map.values())yield t.value}*keys(){for(const t of this.map.values())yield t.uri}*entries(){for(const t of this.map.values())yield[t.uri,t.value]}*[(b=Symbol.toStringTag,Symbol.iterator)](){for(const[,t]of this.map)yield[t.uri,t.value]}}e.ResourceMap=l,l.defaultToKey=r=>r.toString();class _{constructor(t,c){this[L]="ResourceSet",!t||typeof t=="function"?this._map=new l(t):(this._map=new l(c),t.forEach(this.add,this))}get size(){return this._map.size}add(t){return this._map.set(t,t),this}clear(){this._map.clear()}delete(t){return this._map.delete(t)}forEach(t,c){this._map.forEach((v,g)=>t.call(c,g,g,this))}has(t){return this._map.has(t)}entries(){return this._map.entries()}keys(){return this._map.keys()}values(){return this._map.keys()}[(L=Symbol.toStringTag,Symbol.iterator)](){return this.keys()}}e.ResourceSet=_;var n;(function(r){r[r.None=0]="None",r[r.AsOld=1]="AsOld",r[r.AsNew=2]="AsNew"})(n=e.Touch||(e.Touch={}));class u{constructor(){this[C]="LinkedMap",this._map=new Map,this._head=void 0,this._tail=void 0,this._size=0,this._state=0}clear(){this._map.clear(),this._head=void 0,this._tail=void 0,this._size=0,this._state++}isEmpty(){return!this._head&&!this._tail}get size(){return this._size}get first(){return this._head?.value}get last(){return this._tail?.value}has(t){return this._map.has(t)}get(t,c=0){const v=this._map.get(t);if(!!v)return c!==0&&this.touch(v,c),v.value}set(t,c,v=0){let g=this._map.get(t);if(g)g.value=c,v!==0&&this.touch(g,v);else{switch(g={key:t,value:c,next:void 0,previous:void 0},v){case 0:this.addItemLast(g);break;case 1:this.addItemFirst(g);break;case 2:this.addItemLast(g);break;default:this.addItemLast(g);break}this._map.set(t,g),this._size++}return this}delete(t){return!!this.remove(t)}remove(t){const c=this._map.get(t);if(!!c)return this._map.delete(t),this.removeItem(c),this._size--,c.value}shift(){if(!this._head&&!this._tail)return;if(!this._head||!this._tail)throw new Error("Invalid list");const t=this._head;return this._map.delete(t.key),this.removeItem(t),this._size--,t.value}forEach(t,c){const v=this._state;let g=this._head;for(;g;){if(c?t.bind(c)(g.value,g.key,this):t(g.value,g.key,this),this._state!==v)throw new Error("LinkedMap got modified during iteration.");g=g.next}}keys(){const t=this,c=this._state;let v=this._head;const g={[Symbol.iterator](){return g},next(){if(t._state!==c)throw new Error("LinkedMap got modified during iteration.");if(v){const D={value:v.key,done:!1};return v=v.next,D}else return{value:void 0,done:!0}}};return g}values(){const t=this,c=this._state;let v=this._head;const g={[Symbol.iterator](){return g},next(){if(t._state!==c)throw new Error("LinkedMap got modified during iteration.");if(v){const D={value:v.value,done:!1};return v=v.next,D}else return{value:void 0,done:!0}}};return g}entries(){const t=this,c=this._state;let v=this._head;const g={[Symbol.iterator](){return g},next(){if(t._state!==c)throw new Error("LinkedMap got modified during iteration.");if(v){const D={value:[v.key,v.value],done:!1};return v=v.next,D}else return{value:void 0,done:!0}}};return g}[(C=Symbol.toStringTag,Symbol.iterator)](){return this.entries()}trimOld(t){if(t>=this.size)return;if(t===0){this.clear();return}let c=this._head,v=this.size;for(;c&&v>t;)this._map.delete(c.key),c=c.next,v--;this._head=c,this._size=v,c&&(c.previous=void 0),this._state++}addItemFirst(t){if(!this._head&&!this._tail)this._tail=t;else if(this._head)t.next=this._head,this._head.previous=t;else throw new Error("Invalid list");this._head=t,this._state++}addItemLast(t){if(!this._head&&!this._tail)this._head=t;else if(this._tail)t.previous=this._tail,this._tail.next=t;else throw new Error("Invalid list");this._tail=t,this._state++}removeItem(t){if(t===this._head&&t===this._tail)this._head=void 0,this._tail=void 0;else if(t===this._head){if(!t.next)throw new Error("Invalid list");t.next.previous=void 0,this._head=t.next}else if(t===this._tail){if(!t.previous)throw new Error("Invalid list");t.previous.next=void 0,this._tail=t.previous}else{const c=t.next,v=t.previous;if(!c||!v)throw new Error("Invalid list");c.previous=v,v.next=c}t.next=void 0,t.previous=void 0,this._state++}touch(t,c){if(!this._head||!this._tail)throw new Error("Invalid list");if(!(c!==1&&c!==2)){if(c===1){if(t===this._head)return;const v=t.next,g=t.previous;t===this._tail?(g.next=void 0,this._tail=g):(v.previous=g,g.next=v),t.previous=void 0,t.next=this._head,this._head.previous=t,this._head=t,this._state++}else if(c===2){if(t===this._tail)return;const v=t.next,g=t.previous;t===this._head?(v.previous=void 0,this._head=v):(v.previous=g,g.next=v),t.next=void 0,t.previous=this._tail,this._tail.next=t,this._tail=t,this._state++}}}toJSON(){const t=[];return this.forEach((c,v)=>{t.push([v,c])}),t}fromJSON(t){this.clear();for(const[c,v]of t)this.set(c,v)}}e.LinkedMap=u;class i extends u{constructor(t,c=1){super();this._limit=t,this._ratio=Math.min(Math.max(0,c),1)}get limit(){return this._limit}set limit(t){this._limit=t,this.checkTrim()}get ratio(){return this._ratio}set ratio(t){this._ratio=Math.min(Math.max(0,t),1),this.checkTrim()}get(t,c=2){return super.get(t,c)}peek(t){return super.get(t,0)}set(t,c){return super.set(t,c,2),this.checkTrim(),this}checkTrim(){this.size>this._limit&&this.trimOld(Math.round(this._limit*this._ratio))}}e.LRUCache=i;class o{constructor(t){T.set(this,void 0),Je(this,T,t,"f")}get size(){return Ae(this,T,"f").size}forEach(t,c){Ae(this,T,"f").forEach(t,c)}get(t){return Ae(this,T,"f").get(t)}has(t){return Ae(this,T,"f").has(t)}entries(){return Ae(this,T,"f").entries()}keys(){return Ae(this,T,"f").keys()}values(){return Ae(this,T,"f").values()}[(T=new WeakMap,Symbol.iterator)](){return Ae(this,T,"f").entries()}}e.ReadonlyMapView=o}),define(ye[108],Ce([1,0,25,9]),function(ee,e,s,p){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.fuzzyScoreGraceful=e.fuzzyScoreGracefulAggressive=e.fuzzyScore=e.FuzzyScoreOptions=e.FuzzyScore=e.isPatternInWord=e.createMatches=e.anyScore=e.matchesFuzzy2=e.matchesFuzzy=e.matchesWords=e.matchesCamelCase=e.isUpper=e.matchesSubString=e.matchesContiguousSubString=e.matchesPrefix=e.matchesStrictPrefix=e.or=void 0;function b(...X){return function(J,k){for(let B=0,H=X.length;B<H;B++){const j=X[B](J,k);if(j)return j}return null}}e.or=b,e.matchesStrictPrefix=L.bind(void 0,!1),e.matchesPrefix=L.bind(void 0,!0);function L(X,J,k){if(!k||k.length<J.length)return null;let B;return X?B=p.startsWithIgnoreCase(k,J):B=k.indexOf(J)===0,B?J.length>0?[{start:0,end:J.length}]:[]:null}function C(X,J){const k=J.toLowerCase().indexOf(X.toLowerCase());return k===-1?null:[{start:k,end:k+X.length}]}e.matchesContiguousSubString=C;function T(X,J){return E(X.toLowerCase(),J.toLowerCase(),0,0)}e.matchesSubString=T;function E(X,J,k,B){if(k===X.length)return[];if(B===J.length)return null;if(X[k]===J[B]){let H=null;return(H=E(X,J,k+1,B+1))?a({start:B,end:B+1},H):null}return E(X,J,k,B+1)}function A(X){return 97<=X&&X<=122}function R(X){return 65<=X&&X<=90}e.isUpper=R;function y(X){return 48<=X&&X<=57}function m(X){return X===32||X===9||X===10||X===13}const I=new Set;"()[]{}<>`'\"-/;:,.?!".split("").forEach(X=>I.add(X.charCodeAt(0)));function f(X){return m(X)||I.has(X)}function h(X,J){return X===J||f(X)&&f(J)}function d(X){return A(X)||R(X)||y(X)}function a(X,J){return J.length===0?J=[X]:X.end===J[0].start?J[0].start=X.start:J.unshift(X),J}function w(X,J){for(let k=J;k<X.length;k++){const B=X.charCodeAt(k);if(R(B)||y(B)||k>0&&!d(X.charCodeAt(k-1)))return k}return X.length}function P(X,J,k,B){if(k===X.length)return[];if(B===J.length)return null;if(X[k]!==J[B].toLowerCase())return null;{let H=null,j=B+1;for(H=P(X,J,k+1,B+1);!H&&(j=w(J,j))<J.length;)H=P(X,J,k+1,j),j++;return H===null?null:a({start:B,end:B+1},H)}}function l(X){let J=0,k=0,B=0,H=0,j=0;for(let ge=0;ge<X.length;ge++)j=X.charCodeAt(ge),R(j)&&J++,A(j)&&k++,d(j)&&B++,y(j)&&H++;const oe=J/X.length,ue=k/X.length,Z=B/X.length,pe=H/X.length;return{upperPercent:oe,lowerPercent:ue,alphaPercent:Z,numericPercent:pe}}function _(X){const{upperPercent:J,lowerPercent:k}=X;return k===0&&J>.6}function n(X){const{upperPercent:J,lowerPercent:k,alphaPercent:B,numericPercent:H}=X;return k>.2&&J<.8&&B>.6&&H<.2}function u(X){let J=0,k=0,B=0,H=0;for(let j=0;j<X.length;j++)B=X.charCodeAt(j),R(B)&&J++,A(B)&&k++,m(B)&&H++;return(J===0||k===0)&&H===0?X.length<=30:J<=5}function i(X,J){if(!J||(J=J.trim(),J.length===0)||!u(X)||J.length>60)return null;const k=l(J);if(!n(k)){if(!_(k))return null;J=J.toLowerCase()}let B=null,H=0;for(X=X.toLowerCase();H<J.length&&(B=P(X,J,0,H))===null;)H=w(J,H+1);return B}e.matchesCamelCase=i;function o(X,J,k=!1){if(!J||J.length===0)return null;let B=null,H=0;for(X=X.toLowerCase(),J=J.toLowerCase();H<J.length&&(B=r(X,J,0,H,k))===null;)H=t(J,H+1);return B}e.matchesWords=o;function r(X,J,k,B,H){if(k===X.length)return[];if(B===J.length)return null;if(h(X.charCodeAt(k),J.charCodeAt(B))){let j=null,oe=B+1;if(j=r(X,J,k+1,B+1,H),!H)for(;!j&&(oe=t(J,oe))<J.length;)j=r(X,J,k+1,oe,H),oe++;return j===null?null:a({start:B,end:B+1},j)}else return null}function t(X,J){for(let k=J;k<X.length;k++)if(f(X.charCodeAt(k))||k>0&&f(X.charCodeAt(k-1)))return k;return X.length}const c=b(e.matchesPrefix,i,C),v=b(e.matchesPrefix,i,T),g=new s.LRUCache(1e4);function D(X,J,k=!1){if(typeof X!="string"||typeof J!="string")return null;let B=g.get(X);B||(B=new RegExp(p.convertSimple2RegExpPattern(X),"i"),g.set(X,B));const H=B.exec(J);return H?[{start:H.index,end:H.index+H[0].length}]:k?v(X,J):c(X,J)}e.matchesFuzzy=D;function U(X,J){const k=$e(X,X.toLowerCase(),0,J,J.toLowerCase(),0,{firstMatchCanBeWeak:!0,boostFullMatch:!0});return k?M(k):null}e.matchesFuzzy2=U;function W(X,J,k,B,H,j){const oe=Math.min(13,X.length);for(;k<oe;k++){const ue=$e(X,J,k,B,H,j,{firstMatchCanBeWeak:!1,boostFullMatch:!0});if(ue)return ue}return[0,j]}e.anyScore=W;function M(X){if(typeof X=="undefined")return[];const J=[],k=X[1];for(let B=X.length-1;B>1;B--){const H=X[B]+k,j=J[J.length-1];j&&j.end===H?j.end=H+1:J.push({start:H,end:H+1})}return J}e.createMatches=M;const S=128;function z(){const X=[],J=[];for(let k=0;k<=S;k++)J[k]=0;for(let k=0;k<=S;k++)X.push(J.slice(0));return X}function $(X){const J=[];for(let k=0;k<=X;k++)J[k]=0;return J}const N=$(2*S),K=$(2*S),V=z(),F=z(),ne=z(),ce=!1;function re(X,J,k,B,H){function j(ue,Z,pe=" "){for(;ue.length<Z;)ue=pe+ue;return ue}let oe=` | |${B.split("").map(ue=>j(ue,3)).join("|")}
`;for(let ue=0;ue<=k;ue++)ue===0?oe+=" |":oe+=`${J[ue-1]}|`,oe+=X[ue].slice(0,H+1).map(Z=>j(Z.toString(),3)).join("|")+`
`;return oe}function fe(X,J,k,B){X=X.substr(J),k=k.substr(B),console.log(re(F,X,X.length,k,k.length)),console.log(re(ne,X,X.length,k,k.length)),console.log(re(V,X,X.length,k,k.length))}function ie(X,J){if(J<0||J>=X.length)return!1;const k=X.codePointAt(J);switch(k){case 95:case 45:case 46:case 32:case 47:case 92:case 39:case 34:case 58:case 36:case 60:case 62:case 40:case 41:case 91:case 93:case 123:case 125:return!0;case void 0:return!1;default:return!!p.isEmojiImprecise(k)}}function Ee(X,J){if(J<0||J>=X.length)return!1;switch(X.charCodeAt(J)){case 32:case 9:return!0;default:return!1}}function be(X,J,k){return J[X]!==k[X]}function te(X,J,k,B,H,j,oe=!1){for(;J<k&&H<j;)X[J]===B[H]&&(oe&&(N[J]=H),J+=1),H+=1;return J===k}e.isPatternInWord=te;var ve;(function(X){X[X.Diag=1]="Diag",X[X.Left=2]="Left",X[X.LeftLeft=3]="LeftLeft"})(ve||(ve={}));var Re;(function(X){X.Default=[-100,0];function J(k){return!k||k.length===2&&k[0]===-100&&k[1]===0}X.isDefault=J})(Re=e.FuzzyScore||(e.FuzzyScore={}));class Fe{constructor(J,k){this.firstMatchCanBeWeak=J,this.boostFullMatch=k}}e.FuzzyScoreOptions=Fe,Fe.default={boostFullMatch:!0,firstMatchCanBeWeak:!1};function $e(X,J,k,B,H,j,oe=Fe.default){const ue=X.length>S?S:X.length,Z=B.length>S?S:B.length;if(k>=ue||j>=Z||ue-k>Z-j||!te(J,k,ue,H,j,Z,!0))return;Ye(ue,Z,k,j,J,H);let pe=1,ge=1,Ne=k,Be=j;const Ze=[!1];for(pe=1,Ne=k;Ne<ue;pe++,Ne++){const Q=N[Ne],he=K[Ne],Ue=Ne+1<ue?K[Ne+1]:Z;for(ge=Q-j+1,Be=Q;Be<Ue;ge++,Be++){let We=Number.MIN_SAFE_INTEGER,et=!1;Be<=he&&(We=Ie(X,J,Ne,k,B,H,Be,Z,j,V[pe-1][ge-1]===0,Ze));let je=0;We!==Number.MAX_SAFE_INTEGER&&(et=!0,je=We+F[pe-1][ge-1]);const He=Be>Q,it=He?F[pe][ge-1]+(V[pe][ge-1]>0?-5:0):0,rt=Be>Q+1&&V[pe][ge-1]>0,dt=rt?F[pe][ge-2]+(V[pe][ge-2]>0?-5:0):0;if(rt&&(!He||dt>=it)&&(!et||dt>=je))F[pe][ge]=dt,ne[pe][ge]=3,V[pe][ge]=0;else if(He&&(!et||it>=je))F[pe][ge]=it,ne[pe][ge]=2,V[pe][ge]=0;else if(et)F[pe][ge]=je,ne[pe][ge]=1,V[pe][ge]=V[pe-1][ge-1]+1;else throw new Error("not possible")}}if(ce&&fe(X,k,B,j),!Ze[0]&&!oe.firstMatchCanBeWeak)return;pe--,ge--;const Ke=[F[pe][ge],j];let ke=0,nt=0;for(;pe>=1;){let Q=ge;do{const he=ne[pe][Q];if(he===3)Q=Q-2;else if(he===2)Q=Q-1;else break}while(Q>=1);ke>1&&J[k+pe-1]===H[j+ge-1]&&!be(Q+j-1,B,H)&&ke+1>V[pe][Q]&&(Q=ge),Q===ge?ke++:ke=1,nt||(nt=Q),pe--,ge=Q-1,Ke.push(ge)}Z===ue&&oe.boostFullMatch&&(Ke[0]+=2);const G=nt-ue;return Ke[0]-=G,Ke}e.fuzzyScore=$e;function Ye(X,J,k,B,H,j){let oe=X-1,ue=J-1;for(;oe>=k&&ue>=B;)H[oe]===j[ue]&&(K[oe]=ue,oe--),ue--}function Ie(X,J,k,B,H,j,oe,ue,Z,pe,ge){if(J[k]!==j[oe])return Number.MIN_SAFE_INTEGER;let Ne=1,Be=!1;return oe===k-B?Ne=X[k]===H[oe]?7:5:be(oe,H,j)&&(oe===0||!be(oe-1,H,j))?(Ne=X[k]===H[oe]?7:5,Be=!0):ie(j,oe)&&(oe===0||!ie(j,oe-1))?Ne=5:(ie(j,oe-1)||Ee(j,oe-1))&&(Ne=5,Be=!0),Ne>1&&k===B&&(ge[0]=!0),Be||(Be=be(oe,H,j)||ie(j,oe-1)||Ee(j,oe-1)),k===B?oe>Z&&(Ne-=Be?3:5):pe?Ne+=Be?2:0:Ne+=Be?0:1,oe+1===ue&&(Ne-=Be?3:5),Ne}function Se(X,J,k,B,H,j,oe){return ae(X,J,k,B,H,j,!0,oe)}e.fuzzyScoreGracefulAggressive=Se;function Te(X,J,k,B,H,j,oe){return ae(X,J,k,B,H,j,!1,oe)}e.fuzzyScoreGraceful=Te;function ae(X,J,k,B,H,j,oe,ue){let Z=$e(X,J,k,B,H,j,ue);if(Z&&!oe)return Z;if(X.length>=3){const pe=Math.min(7,X.length-1);for(let ge=k+1;ge<pe;ge++){const Ne=le(X,ge);if(Ne){const Be=$e(Ne,Ne.toLowerCase(),k,B,H,j,ue);Be&&(Be[0]-=3,(!Z||Be[0]>Z[0])&&(Z=Be))}}}return Z}function le(X,J){if(J+1>=X.length)return;const k=X[J],B=X[J+1];if(k!==B)return X.slice(0,J)+B+k+X.slice(J+2)}}),define(ye[109],Ce([1,0,110,108,9]),function(ee,e,s,p,b){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.matchesFuzzyIconAware=e.parseLabelWithIcons=e.stripIcons=e.markdownEscapeEscapedIcons=e.escapeIcons=e.iconStartMarker=void 0,e.iconStartMarker="$(";const L=new RegExp(`\\$\\(${s.CSSIcon.iconNameExpression}(?:${s.CSSIcon.iconModifierExpression})?\\)`,"g"),C=new RegExp(s.CSSIcon.iconNameCharacter),T=new RegExp(`(\\\\)?${L.source}`,"g");function E(d){return d.replace(T,(a,w)=>w?a:`\\${a}`)}e.escapeIcons=E;const A=new RegExp(`\\\\${L.source}`,"g");function R(d){return d.replace(A,a=>`\\${a}`)}e.markdownEscapeEscapedIcons=R;const y=new RegExp(`(\\s)?(\\\\)?${L.source}(\\s)?`,"g");function m(d){return d.indexOf(e.iconStartMarker)===-1?d:d.replace(y,(a,w,P,l)=>P?a:w||l||"")}e.stripIcons=m;function I(d){const a=d.indexOf(e.iconStartMarker);return a===-1?{text:d}:f(d,a)}e.parseLabelWithIcons=I;function f(d,a){const w=[];let P="";function l(c){if(c){P+=c;for(const v of c)w.push(u)}}let _=-1,n="",u=0,i,o,r=a;const t=d.length;for(l(d.substr(0,a));r<t;)i=d[r],o=d[r+1],i===e.iconStartMarker[0]&&o===e.iconStartMarker[1]?(_=r,l(n),n=e.iconStartMarker,r++):i===")"&&_!==-1?(u+=r-_+1,_=-1,n=""):_!==-1?C.test(i)?n+=i:(l(n),_=-1,n=""):l(i),r++;return l(n),{text:P,iconOffsets:w}}function h(d,a,w=!1){const{text:P,iconOffsets:l}=a;if(!l||l.length===0)return(0,p.matchesFuzzy)(d,P,w);const _=(0,b.ltrim)(P," "),n=P.length-_.length,u=(0,p.matchesFuzzy)(d,_,w);if(u)for(const i of u){const o=l[i.start+n]+n;i.start+=o,i.end+=o}return u}e.matchesFuzzyIconAware=h}),define(ye[29],Ce([1,0,9]),function(ee,e,s){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var p;(function(b){b[b.Ignore=0]="Ignore",b[b.Info=1]="Info",b[b.Warning=2]="Warning",b[b.Error=3]="Error"})(p||(p={})),function(b){const L="error",C="warning",T="warn",E="info",A="ignore";function R(m){return m?s.equalsIgnoreCase(L,m)?b.Error:s.equalsIgnoreCase(C,m)||s.equalsIgnoreCase(T,m)?b.Warning:s.equalsIgnoreCase(E,m)?b.Info:b.Ignore:b.Ignore}b.fromValue=R;function y(m){switch(m){case b.Error:return L;case b.Warning:return C;case b.Info:return E;default:return A}}b.toString=y}(p||(p={})),e.default=p}),define(ye[37],Ce([1,0,19,23,9,10]),function(ee,e,s,p,b,L){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.randomPath=e.parseLineAndColumnAware=e.indexOfPath=e.getDriveLetter=e.hasDriveLetter=e.isRootOrDriveLetter=e.sanitizeFilePath=e.isWindowsDriveLetter=e.isEqualOrParent=e.isEqual=e.isValidBasename=e.isUNC=e.getRoot=e.toPosixPath=e.toSlashes=e.isPathSeparator=void 0;function C(r){return r===47||r===92}e.isPathSeparator=C;function T(r){return r.replace(/[\\/]/g,s.posix.sep)}e.toSlashes=T;function E(r){return r.indexOf("/")===-1&&(r=T(r)),/^[a-zA-Z]:(\/|$)/.test(r)&&(r="/"+r),r}e.toPosixPath=E;function A(r,t=s.posix.sep){if(!r)return"";const c=r.length,v=r.charCodeAt(0);if(C(v)){if(C(r.charCodeAt(1))&&!C(r.charCodeAt(2))){let D=3;const U=D;for(;D<c&&!C(r.charCodeAt(D));D++);if(U!==D&&!C(r.charCodeAt(D+1))){for(D+=1;D<c;D++)if(C(r.charCodeAt(D)))return r.slice(0,D+1).replace(/[\\/]/g,t)}}return t}else if(a(v)&&r.charCodeAt(1)===58)return C(r.charCodeAt(2))?r.slice(0,2)+t:r.slice(0,2);let g=r.indexOf("://");if(g!==-1){for(g+=3;g<c;g++)if(C(r.charCodeAt(g)))return r.slice(0,g+1)}return""}e.getRoot=A;function R(r){if(!p.isWindows||!r||r.length<5)return!1;let t=r.charCodeAt(0);if(t!==92||(t=r.charCodeAt(1),t!==92))return!1;let c=2;const v=c;for(;c<r.length&&(t=r.charCodeAt(c),t!==92);c++);return!(v===c||(t=r.charCodeAt(c+1),isNaN(t)||t===92))}e.isUNC=R;const y=/[\\/:\*\?"<>\|]/g,m=/[\\/]/g,I=/^(con|prn|aux|clock\$|nul|lpt[0-9]|com[0-9])(\.(.*?))?$/i;function f(r,t=p.isWindows){const c=t?y:m;return!(!r||r.length===0||/^\s+$/.test(r)||(c.lastIndex=0,c.test(r))||t&&I.test(r)||r==="."||r===".."||t&&r[r.length-1]==="."||t&&r.length!==r.trim().length||r.length>255)}e.isValidBasename=f;function h(r,t,c){const v=r===t;return!c||v?v:!r||!t?!1:(0,b.equalsIgnoreCase)(r,t)}e.isEqual=h;function d(r,t,c,v=s.sep){if(r===t)return!0;if(!r||!t||t.length>r.length)return!1;if(c){if(!(0,b.startsWithIgnoreCase)(r,t))return!1;if(t.length===r.length)return!0;let D=t.length;return t.charAt(t.length-1)===v&&D--,r.charAt(D)===v}return t.charAt(t.length-1)!==v&&(t+=v),r.indexOf(t)===0}e.isEqualOrParent=d;function a(r){return r>=65&&r<=90||r>=97&&r<=122}e.isWindowsDriveLetter=a;function w(r,t){return p.isWindows&&r.endsWith(":")&&(r+=s.sep),(0,s.isAbsolute)(r)||(r=(0,s.join)(t,r)),r=(0,s.normalize)(r),p.isWindows?(r=(0,b.rtrim)(r,s.sep),r.endsWith(":")&&(r+=s.sep)):(r=(0,b.rtrim)(r,s.sep),r||(r=s.sep)),r}e.sanitizeFilePath=w;function P(r){const t=(0,s.normalize)(r);return p.isWindows?r.length>3?!1:l(t)&&(r.length===2||t.charCodeAt(2)===92):t===s.posix.sep}e.isRootOrDriveLetter=P;function l(r,t=p.isWindows){return t?a(r.charCodeAt(0))&&r.charCodeAt(1)===58:!1}e.hasDriveLetter=l;function _(r){return l(r)?r[0]:void 0}e.getDriveLetter=_;function n(r,t,c){return t.length>r.length?-1:r===t?0:(c&&(r=r.toLowerCase(),t=t.toLowerCase()),r.indexOf(t))}e.indexOfPath=n;function u(r){const t=r.split(":");let c,v,g;for(const D of t){const U=Number(D);(0,L.isNumber)(U)?v===void 0?v=U:g===void 0&&(g=U):c=c?[c,D].join(":"):D}if(!c)throw new Error("Format for `--goto` should be: `FILE:LINE(:COLUMN)`");return{path:c,line:v!==void 0?v:void 0,column:g!==void 0?g:v!==void 0?1:void 0}}e.parseLineAndColumnAware=u;const i="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789";function o(r,t,c=8){let v="";for(let D=0;D<c;D++)v+=i.charAt(Math.floor(Math.random()*i.length));let g;return t?g=`${t}-${v}`:g=v,r?(0,s.join)(r,g):g}e.randomPath=o}),define(ye[55],Ce([1,0,22,9,2]),function(ee,e,s,p,b){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.revive=e.parse=e.stringify=void 0;function L(A){return JSON.stringify(A,T)}e.stringify=L;function C(A){let R=JSON.parse(A);return R=E(R),R}e.parse=C;function T(A,R){return R instanceof RegExp?{$mid:2,source:R.source,flags:(0,p.regExpFlags)(R)}:R}function E(A,R=0){if(!A||R>200)return A;if(typeof A=="object"){switch(A.$mid){case 1:return b.URI.revive(A);case 2:return new RegExp(A.source,A.flags);case 14:return new Date(A.source)}if(A instanceof s.VSBuffer||A instanceof Uint8Array)return A;if(Array.isArray(A))for(let y=0;y<A.length;++y)A[y]=E(A[y],R+1);else for(const y in A)Object.hasOwnProperty.call(A,y)&&(A[y]=E(A[y],R+1))}return A}e.revive=E}),define(ye[12],Ce([1,0,23,2]),function(ee,e,s,p){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.FileAccess=e.RemoteAuthorities=e.connectionTokenQueryName=e.connectionTokenCookieName=e.Schemas=void 0;var b;(function(T){T.inMemory="inmemory",T.vscode="vscode",T.internal="private",T.walkThrough="walkThrough",T.walkThroughSnippet="walkThroughSnippet",T.http="http",T.https="https",T.file="file",T.mailto="mailto",T.untitled="untitled",T.data="data",T.command="command",T.vscodeRemote="vscode-remote",T.vscodeRemoteResource="vscode-remote-resource",T.vscodeUserData="vscode-userdata",T.vscodeCustomEditor="vscode-custom-editor",T.vscodeNotebook="vscode-notebook",T.vscodeNotebookCell="vscode-notebook-cell",T.vscodeNotebookCellMetadata="vscode-notebook-cell-metadata",T.vscodeNotebookCellOutput="vscode-notebook-cell-output",T.vscodeInteractive="vscode-interactive",T.vscodeInteractiveInput="vscode-interactive-input",T.vscodeSettings="vscode-settings",T.vscodeWorkspaceTrust="vscode-workspace-trust",T.vscodeTerminal="vscode-terminal",T.webviewPanel="webview-panel",T.vscodeWebview="vscode-webview",T.extension="extension",T.vscodeFileResource="vscode-file",T.tmp="tmp",T.vsls="vsls",T.vscodeSourceControl="vscode-scm"})(b=e.Schemas||(e.Schemas={})),e.connectionTokenCookieName="vscode-tkn",e.connectionTokenQueryName="tkn";class L{constructor(){this._hosts=Object.create(null),this._ports=Object.create(null),this._connectionTokens=Object.create(null),this._preferredWebSchema="http",this._delegate=null,this._remoteResourcesPath=`/${b.vscodeRemoteResource}`}setPreferredWebSchema(E){this._preferredWebSchema=E}setDelegate(E){this._delegate=E}setServerRootPath(E){this._remoteResourcesPath=`${E}/${b.vscodeRemoteResource}`}set(E,A,R){this._hosts[E]=A,this._ports[E]=R}setConnectionToken(E,A){this._connectionTokens[E]=A}getPreferredWebSchema(){return this._preferredWebSchema}rewrite(E){if(this._delegate)return this._delegate(E);const A=E.authority;let R=this._hosts[A];R&&R.indexOf(":")!==-1&&(R=`[${R}]`);const y=this._ports[A],m=this._connectionTokens[A];let I=`path=${encodeURIComponent(E.path)}`;return typeof m=="string"&&(I+=`&${e.connectionTokenQueryName}=${encodeURIComponent(m)}`),p.URI.from({scheme:s.isWeb?this._preferredWebSchema:b.vscodeRemoteResource,authority:`${R}:${y}`,path:s.isWeb?(window.location.pathname+"/"+this._remoteResourcesPath).replace(/\/\/+/g,"/"):this._remoteResourcesPath,query:I})}}e.RemoteAuthorities=new L;class C{asBrowserUri(E,A){const R=this.toUri(E,A);return R.scheme===b.vscodeRemote?e.RemoteAuthorities.rewrite(R):R.scheme===b.file&&(s.isNative||s.isWebWorker&&s.globals.origin===`${b.vscodeFileResource}://${C.FALLBACK_AUTHORITY}`)?R.with({scheme:b.vscodeFileResource,authority:R.authority||C.FALLBACK_AUTHORITY,query:null,fragment:null}):R}asFileUri(E,A){const R=this.toUri(E,A);return R.scheme===b.vscodeFileResource?R.with({scheme:b.file,authority:R.authority!==C.FALLBACK_AUTHORITY?R.authority:null,query:null,fragment:null}):R}toUri(E,A){return p.URI.isUri(E)?E:p.URI.parse(A.toUrl(E))}}C.FALLBACK_AUTHORITY="vscode-app",e.FileAccess=new C}),define(ye[21],Ce([1,0,37,12,19,23,9,2]),function(ee,e,s,p,b,L,C,T){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.toLocalResource=e.DataUri=e.distinctParents=e.addTrailingPathSeparator=e.removeTrailingPathSeparator=e.hasTrailingPathSeparator=e.isEqualAuthority=e.isAbsolutePath=e.resolvePath=e.relativePath=e.normalizePath=e.joinPath=e.dirname=e.extname=e.basename=e.basenameOrAuthority=e.getComparisonKey=e.isEqualOrParent=e.isEqual=e.extUriIgnorePathCase=e.extUriBiasedIgnorePathCase=e.extUri=e.ExtUri=e.originalFSPath=void 0;function E(I){return(0,T.uriToFsPath)(I,!0)}e.originalFSPath=E;class A{constructor(f){this._ignorePathCasing=f}compare(f,h,d=!1){return f===h?0:(0,C.compare)(this.getComparisonKey(f,d),this.getComparisonKey(h,d))}isEqual(f,h,d=!1){return f===h?!0:!f||!h?!1:this.getComparisonKey(f,d)===this.getComparisonKey(h,d)}getComparisonKey(f,h=!1){return f.with({path:this._ignorePathCasing(f)?f.path.toLowerCase():void 0,fragment:h?null:void 0}).toString()}ignorePathCasing(f){return this._ignorePathCasing(f)}isEqualOrParent(f,h,d=!1){if(f.scheme===h.scheme){if(f.scheme===p.Schemas.file)return s.isEqualOrParent(E(f),E(h),this._ignorePathCasing(f))&&f.query===h.query&&(d||f.fragment===h.fragment);if((0,e.isEqualAuthority)(f.authority,h.authority))return s.isEqualOrParent(f.path,h.path,this._ignorePathCasing(f),"/")&&f.query===h.query&&(d||f.fragment===h.fragment)}return!1}joinPath(f,...h){return T.URI.joinPath(f,...h)}basenameOrAuthority(f){return(0,e.basename)(f)||f.authority}basename(f){return b.posix.basename(f.path)}extname(f){return b.posix.extname(f.path)}dirname(f){if(f.path.length===0)return f;let h;return f.scheme===p.Schemas.file?h=T.URI.file(b.dirname(E(f))).path:(h=b.posix.dirname(f.path),f.authority&&h.length&&h.charCodeAt(0)!==47&&(console.error(`dirname("${f.toString})) resulted in a relative path`),h="/")),f.with({path:h})}normalizePath(f){if(!f.path.length)return f;let h;return f.scheme===p.Schemas.file?h=T.URI.file(b.normalize(E(f))).path:h=b.posix.normalize(f.path),f.with({path:h})}relativePath(f,h){if(f.scheme!==h.scheme||!(0,e.isEqualAuthority)(f.authority,h.authority))return;if(f.scheme===p.Schemas.file){const w=b.relative(E(f),E(h));return L.isWindows?s.toSlashes(w):w}let d=f.path||"/";const a=h.path||"/";if(this._ignorePathCasing(f)){let w=0;for(const P=Math.min(d.length,a.length);w<P&&!(d.charCodeAt(w)!==a.charCodeAt(w)&&d.charAt(w).toLowerCase()!==a.charAt(w).toLowerCase());w++);d=a.substr(0,w)+d.substr(w)}return b.posix.relative(d,a)}resolvePath(f,h){if(f.scheme===p.Schemas.file){const d=T.URI.file(b.resolve(E(f),h));return f.with({authority:d.authority,path:d.path})}return h=s.toPosixPath(h),f.with({path:b.posix.resolve(f.path,h)})}isAbsolutePath(f){return!!f.path&&f.path[0]==="/"}isEqualAuthority(f,h){return f===h||f!==void 0&&h!==void 0&&(0,C.equalsIgnoreCase)(f,h)}hasTrailingPathSeparator(f,h=b.sep){if(f.scheme===p.Schemas.file){const d=E(f);return d.length>s.getRoot(d).length&&d[d.length-1]===h}else{const d=f.path;return d.length>1&&d.charCodeAt(d.length-1)===47&&!/^[a-zA-Z]:(\/$|\\$)/.test(f.fsPath)}}removeTrailingPathSeparator(f,h=b.sep){return(0,e.hasTrailingPathSeparator)(f,h)?f.with({path:f.path.substr(0,f.path.length-1)}):f}addTrailingPathSeparator(f,h=b.sep){let d=!1;if(f.scheme===p.Schemas.file){const a=E(f);d=a!==void 0&&a.length===s.getRoot(a).length&&a[a.length-1]===h}else{h="/";const a=f.path;d=a.length===1&&a.charCodeAt(a.length-1)===47}return!d&&!(0,e.hasTrailingPathSeparator)(f,h)?f.with({path:f.path+"/"}):f}}e.ExtUri=A,e.extUri=new A(()=>!1),e.extUriBiasedIgnorePathCase=new A(I=>I.scheme===p.Schemas.file?!L.isLinux:!0),e.extUriIgnorePathCase=new A(I=>!0),e.isEqual=e.extUri.isEqual.bind(e.extUri),e.isEqualOrParent=e.extUri.isEqualOrParent.bind(e.extUri),e.getComparisonKey=e.extUri.getComparisonKey.bind(e.extUri),e.basenameOrAuthority=e.extUri.basenameOrAuthority.bind(e.extUri),e.basename=e.extUri.basename.bind(e.extUri),e.extname=e.extUri.extname.bind(e.extUri),e.dirname=e.extUri.dirname.bind(e.extUri),e.joinPath=e.extUri.joinPath.bind(e.extUri),e.normalizePath=e.extUri.normalizePath.bind(e.extUri),e.relativePath=e.extUri.relativePath.bind(e.extUri),e.resolvePath=e.extUri.resolvePath.bind(e.extUri),e.isAbsolutePath=e.extUri.isAbsolutePath.bind(e.extUri),e.isEqualAuthority=e.extUri.isEqualAuthority.bind(e.extUri),e.hasTrailingPathSeparator=e.extUri.hasTrailingPathSeparator.bind(e.extUri),e.removeTrailingPathSeparator=e.extUri.removeTrailingPathSeparator.bind(e.extUri),e.addTrailingPathSeparator=e.extUri.addTrailingPathSeparator.bind(e.extUri);function R(I,f){const h=[];for(let d=0;d<I.length;d++){const a=f(I[d]);I.some((w,P)=>P===d?!1:(0,e.isEqualOrParent)(a,f(w)))||h.push(I[d])}return h}e.distinctParents=R;var y;(function(I){I.META_DATA_LABEL="label",I.META_DATA_DESCRIPTION="description",I.META_DATA_SIZE="size",I.META_DATA_MIME="mime";function f(h){const d=new Map;h.path.substring(h.path.indexOf(";")+1,h.path.lastIndexOf(";")).split(";").forEach(P=>{const[l,_]=P.split(":");l&&_&&d.set(l,_)});const w=h.path.substring(0,h.path.indexOf(";"));return w&&d.set(I.META_DATA_MIME,w),d}I.parseMetaData=f})(y=e.DataUri||(e.DataUri={}));function m(I,f,h){if(f){let d=I.path;return d&&d[0]!==b.posix.sep&&(d=b.posix.sep+d),I.with({scheme:h,authority:f,path:d})}return I.with({scheme:h})}e.toLocalResource=m}),define(ye[13],Ce([1,0,20,11,4,7,21,23]),function(ee,e,s,p,b,L,C,T){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.createCancelableAsyncIterable=e.CancelableAsyncIterableObject=e.AsyncIterableObject=e.Promises=e.DeferredPromise=e.IntervalCounter=e.TaskSequentializer=e.retry=e.IdleValue=e.runWhenIdle=e.ThrottledWorker=e.RunOnceWorker=e.ProcessTimeRunOnceScheduler=e.RunOnceScheduler=e.IntervalTimer=e.TimeoutTimer=e.ResourceQueue=e.Queue=e.Limiter=e.firstParallel=e.first=e.sequence=e.disposableTimeout=e.timeout=e.AutoOpenBarrier=e.Barrier=e.ThrottledDelayer=e.Delayer=e.MicrotaskDelay=e.SequencerByKey=e.Sequencer=e.Throttler=e.asPromise=e.raceTimeout=e.raceCancellablePromises=e.raceCancellationError=e.raceCancellation=e.createCancelablePromise=e.isThenable=void 0;function E(be){return!!be&&typeof be.then=="function"}e.isThenable=E;function A(be){const te=new s.CancellationTokenSource,ve=be(te.token),Re=new Promise((Fe,$e)=>{const Ye=te.token.onCancellationRequested(()=>{Ye.dispose(),te.dispose(),$e(new p.CancellationError)});Promise.resolve(ve).then(Ie=>{Ye.dispose(),te.dispose(),Fe(Ie)},Ie=>{Ye.dispose(),te.dispose(),$e(Ie)})});return new class{cancel(){te.cancel()}then(Fe,$e){return Re.then(Fe,$e)}catch(Fe){return this.then(void 0,Fe)}finally(Fe){return Re.finally(Fe)}}}e.createCancelablePromise=A;function R(be,te,ve){return new Promise((Re,Fe)=>{const $e=te.onCancellationRequested(()=>{$e.dispose(),Re(ve)});be.then(Re,Fe).finally(()=>$e.dispose())})}e.raceCancellation=R;function y(be,te){return new Promise((ve,Re)=>{const Fe=te.onCancellationRequested(()=>{Fe.dispose(),Re(new p.CancellationError)});be.then(ve,Re).finally(()=>Fe.dispose())})}e.raceCancellationError=y;async function m(be){let te=-1;const ve=be.map((Fe,$e)=>Fe.then(Ye=>(te=$e,Ye))),Re=await Promise.race(ve);return be.forEach((Fe,$e)=>{$e!==te&&Fe.cancel()}),Re}e.raceCancellablePromises=m;function I(be,te,ve){let Re;const Fe=setTimeout(()=>{Re?.(void 0),ve?.()},te);return Promise.race([be.finally(()=>clearTimeout(Fe)),new Promise($e=>Re=$e)])}e.raceTimeout=I;function f(be){return new Promise((te,ve)=>{const Re=be();E(Re)?Re.then(te,ve):te(Re)})}e.asPromise=f;class h{constructor(){this.activePromise=null,this.queuedPromise=null,this.queuedPromiseFactory=null}queue(te){if(this.activePromise){if(this.queuedPromiseFactory=te,!this.queuedPromise){const ve=()=>{this.queuedPromise=null;const Re=this.queue(this.queuedPromiseFactory);return this.queuedPromiseFactory=null,Re};this.queuedPromise=new Promise(Re=>{this.activePromise.then(ve,ve).then(Re)})}return new Promise((ve,Re)=>{this.queuedPromise.then(ve,Re)})}return this.activePromise=te(),new Promise((ve,Re)=>{this.activePromise.then(Fe=>{this.activePromise=null,ve(Fe)},Fe=>{this.activePromise=null,Re(Fe)})})}}e.Throttler=h;class d{constructor(){this.current=Promise.resolve(null)}queue(te){return this.current=this.current.then(()=>te(),()=>te())}}e.Sequencer=d;class a{constructor(){this.promiseMap=new Map}queue(te,ve){const Fe=(this.promiseMap.get(te)??Promise.resolve()).catch(()=>{}).then(ve).finally(()=>{this.promiseMap.get(te)===Fe&&this.promiseMap.delete(te)});return this.promiseMap.set(te,Fe),Fe}}e.SequencerByKey=a;const w=(be,te)=>{let ve=!0;const Re=setTimeout(()=>{ve=!1,te()},be);return{isTriggered:()=>ve,dispose:()=>{clearTimeout(Re),ve=!1}}},P=be=>{let te=!0;return queueMicrotask(()=>{te&&(te=!1,be())}),{isTriggered:()=>te,dispose:()=>{te=!1}}};e.MicrotaskDelay=Symbol("MicrotaskDelay");class l{constructor(te){this.defaultDelay=te,this.deferred=null,this.completionPromise=null,this.doResolve=null,this.doReject=null,this.task=null}trigger(te,ve=this.defaultDelay){this.task=te,this.cancelTimeout(),this.completionPromise||(this.completionPromise=new Promise((Fe,$e)=>{this.doResolve=Fe,this.doReject=$e}).then(()=>{if(this.completionPromise=null,this.doResolve=null,this.task){const Fe=this.task;return this.task=null,Fe()}}));const Re=()=>{this.deferred=null,this.doResolve?.(null)};return this.deferred=ve===e.MicrotaskDelay?P(Re):w(ve,Re),this.completionPromise}isTriggered(){return!!this.deferred?.isTriggered()}cancel(){this.cancelTimeout(),this.completionPromise&&(this.doReject?.(new p.CancellationError),this.completionPromise=null)}cancelTimeout(){this.deferred?.dispose(),this.deferred=null}dispose(){this.cancel()}}e.Delayer=l;class _{constructor(te){this.delayer=new l(te),this.throttler=new h}trigger(te,ve){return this.delayer.trigger(()=>this.throttler.queue(te),ve)}isTriggered(){return this.delayer.isTriggered()}cancel(){this.delayer.cancel()}dispose(){this.delayer.dispose()}}e.ThrottledDelayer=_;class n{constructor(){this._isOpen=!1,this._promise=new Promise((te,ve)=>{this._completePromise=te})}isOpen(){return this._isOpen}open(){this._isOpen=!0,this._completePromise(!0)}wait(){return this._promise}}e.Barrier=n;class u extends n{constructor(te){super();this._timeout=setTimeout(()=>this.open(),te)}open(){clearTimeout(this._timeout),super.open()}}e.AutoOpenBarrier=u;function i(be,te){return te?new Promise((ve,Re)=>{const Fe=setTimeout(()=>{$e.dispose(),ve()},be),$e=te.onCancellationRequested(()=>{clearTimeout(Fe),$e.dispose(),Re(new p.CancellationError)})}):A(ve=>i(be,ve))}e.timeout=i;function o(be,te=0){const ve=setTimeout(be,te);return(0,L.toDisposable)(()=>clearTimeout(ve))}e.disposableTimeout=o;function r(be){const te=[];let ve=0;const Re=be.length;function Fe(){return ve<Re?be[ve++]():null}function $e(Ye){Ye!=null&&te.push(Ye);const Ie=Fe();return Ie?Ie.then($e):Promise.resolve(te)}return Promise.resolve(null).then($e)}e.sequence=r;function t(be,te=Re=>!!Re,ve=null){let Re=0;const Fe=be.length,$e=()=>{if(Re>=Fe)return Promise.resolve(ve);const Ye=be[Re++];return Promise.resolve(Ye()).then(Se=>te(Se)?Promise.resolve(Se):$e())};return $e()}e.first=t;function c(be,te=Re=>!!Re,ve=null){if(be.length===0)return Promise.resolve(ve);let Re=be.length;const Fe=()=>{Re=-1;for(const $e of be)$e.cancel?.()};return new Promise(($e,Ye)=>{for(const Ie of be)Ie.then(Se=>{--Re>=0&&te(Se)?(Fe(),$e(Se)):Re===0&&$e(ve)}).catch(Se=>{--Re>=0&&(Fe(),Ye(Se))})})}e.firstParallel=c;class v{constructor(te){this._size=0,this.maxDegreeOfParalellism=te,this.outstandingPromises=[],this.runningPromises=0,this._onDrained=new b.Emitter}get onDrained(){return this._onDrained.event}get size(){return this._size}queue(te){return this._size++,new Promise((ve,Re)=>{this.outstandingPromises.push({factory:te,c:ve,e:Re}),this.consume()})}consume(){for(;this.outstandingPromises.length&&this.runningPromises<this.maxDegreeOfParalellism;){const te=this.outstandingPromises.shift();this.runningPromises++;const ve=te.factory();ve.then(te.c,te.e),ve.then(()=>this.consumed(),()=>this.consumed())}}consumed(){this._size--,this.runningPromises--,this.outstandingPromises.length>0?this.consume():this._onDrained.fire()}dispose(){this._onDrained.dispose()}}e.Limiter=v;class g extends v{constructor(){super(1)}}e.Queue=g;class D{constructor(){this.queues=new Map,this.drainers=new Set}async whenDrained(){if(this.isDrained())return;const te=new ne;return this.drainers.add(te),te.p}isDrained(){for(const[,te]of this.queues)if(te.size>0)return!1;return!0}queueFor(te,ve=C.extUri){const Re=ve.getComparisonKey(te);let Fe=this.queues.get(Re);return Fe||(Fe=new g,b.Event.once(Fe.onDrained)(()=>{Fe?.dispose(),this.queues.delete(Re),this.onDidQueueDrain()}),this.queues.set(Re,Fe)),Fe}onDidQueueDrain(){!this.isDrained()||this.releaseDrainers()}releaseDrainers(){for(const te of this.drainers)te.complete();this.drainers.clear()}dispose(){for(const[,te]of this.queues)te.dispose();this.queues.clear(),this.releaseDrainers()}}e.ResourceQueue=D;class U{constructor(te,ve){this._token=-1,typeof te=="function"&&typeof ve=="number"&&this.setIfNotSet(te,ve)}dispose(){this.cancel()}cancel(){this._token!==-1&&(clearTimeout(this._token),this._token=-1)}cancelAndSet(te,ve){this.cancel(),this._token=setTimeout(()=>{this._token=-1,te()},ve)}setIfNotSet(te,ve){this._token===-1&&(this._token=setTimeout(()=>{this._token=-1,te()},ve))}}e.TimeoutTimer=U;class W{constructor(){this._token=-1}dispose(){this.cancel()}cancel(){this._token!==-1&&(clearInterval(this._token),this._token=-1)}cancelAndSet(te,ve){this.cancel(),this._token=setInterval(()=>{te()},ve)}}e.IntervalTimer=W;class M{constructor(te,ve){this.timeoutToken=-1,this.runner=te,this.timeout=ve,this.timeoutHandler=this.onTimeout.bind(this)}dispose(){this.cancel(),this.runner=null}cancel(){this.isScheduled()&&(clearTimeout(this.timeoutToken),this.timeoutToken=-1)}schedule(te=this.timeout){this.cancel(),this.timeoutToken=setTimeout(this.timeoutHandler,te)}get delay(){return this.timeout}set delay(te){this.timeout=te}isScheduled(){return this.timeoutToken!==-1}onTimeout(){this.timeoutToken=-1,this.runner&&this.doRun()}doRun(){this.runner?.()}}e.RunOnceScheduler=M;class S{constructor(te,ve){ve%1e3!=0&&console.warn(`ProcessTimeRunOnceScheduler resolution is 1s, ${ve}ms is not a multiple of 1000ms.`),this.runner=te,this.timeout=ve,this.counter=0,this.intervalToken=-1,this.intervalHandler=this.onInterval.bind(this)}dispose(){this.cancel(),this.runner=null}cancel(){this.isScheduled()&&(clearInterval(this.intervalToken),this.intervalToken=-1)}schedule(te=this.timeout){te%1e3!=0&&console.warn(`ProcessTimeRunOnceScheduler resolution is 1s, ${te}ms is not a multiple of 1000ms.`),this.cancel(),this.counter=Math.ceil(te/1e3),this.intervalToken=setInterval(this.intervalHandler,1e3)}isScheduled(){return this.intervalToken!==-1}onInterval(){this.counter--,!(this.counter>0)&&(clearInterval(this.intervalToken),this.intervalToken=-1,this.runner?.())}}e.ProcessTimeRunOnceScheduler=S;class z extends M{constructor(te,ve){super(te,ve);this.units=[]}work(te){this.units.push(te),this.isScheduled()||this.schedule()}doRun(){const te=this.units;this.units=[],this.runner?.(te)}dispose(){this.units=[],super.dispose()}}e.RunOnceWorker=z;class $ extends L.Disposable{constructor(te,ve){super();this.options=te,this.handler=ve,this.pendingWork=[],this.throttler=this._register(new L.MutableDisposable),this.disposed=!1}get pending(){return this.pendingWork.length}work(te){if(this.disposed)return!1;if(typeof this.options.maxBufferedWork=="number"){if(this.throttler.value){if(this.pending+te.length>this.options.maxBufferedWork)return!1}else if(this.pending+te.length-this.options.maxWorkChunkSize>this.options.maxBufferedWork)return!1}return this.pendingWork.push(...te),this.throttler.value||this.doWork(),!0}doWork(){this.handler(this.pendingWork.splice(0,this.options.maxWorkChunkSize)),this.pendingWork.length>0&&(this.throttler.value=new M(()=>{this.throttler.clear(),this.doWork()},this.options.throttleDelay),this.throttler.value.schedule())}dispose(){super.dispose(),this.disposed=!0}}e.ThrottledWorker=$,function(){typeof requestIdleCallback!="function"||typeof cancelIdleCallback!="function"?e.runWhenIdle=be=>{(0,T.setTimeout0)(()=>{if(te)return;const ve=Date.now()+15;be(Object.freeze({didTimeout:!0,timeRemaining(){return Math.max(0,ve-Date.now())}}))});let te=!1;return{dispose(){te||(te=!0)}}}:e.runWhenIdle=(be,te)=>{const ve=requestIdleCallback(be,typeof te=="number"?{timeout:te}:void 0);let Re=!1;return{dispose(){Re||(Re=!0,cancelIdleCallback(ve))}}}}();class N{constructor(te){this._didRun=!1,this._executor=()=>{try{this._value=te()}catch(ve){this._error=ve}finally{this._didRun=!0}},this._handle=(0,e.runWhenIdle)(()=>this._executor())}dispose(){this._handle.dispose()}get value(){if(this._didRun||(this._handle.dispose(),this._executor()),this._error)throw this._error;return this._value}get isInitialized(){return this._didRun}}e.IdleValue=N;async function K(be,te,ve){let Re;for(let Fe=0;Fe<ve;Fe++)try{return await be()}catch($e){Re=$e,await i(te)}throw Re}e.retry=K;class V{hasPending(te){return this._pending?typeof te=="number"?this._pending.taskId===te:!!this._pending:!1}get pending(){return this._pending?this._pending.promise:void 0}cancelPending(){this._pending?.cancel()}setPending(te,ve,Re){return this._pending={taskId:te,cancel:()=>Re?.(),promise:ve},ve.then(()=>this.donePending(te),()=>this.donePending(te)),ve}donePending(te){this._pending&&te===this._pending.taskId&&(this._pending=void 0,this.triggerNext())}triggerNext(){if(this._next){const te=this._next;this._next=void 0,te.run().then(te.promiseResolve,te.promiseReject)}}setNext(te){if(this._next)this._next.run=te;else{let ve,Re;const Fe=new Promise(($e,Ye)=>{ve=$e,Re=Ye});this._next={run:te,promise:Fe,promiseResolve:ve,promiseReject:Re}}return this._next.promise}}e.TaskSequentializer=V;class F{constructor(te,ve=()=>Date.now()){this.interval=te,this.nowFn=ve,this.lastIncrementTime=0,this.value=0}increment(){const te=this.nowFn();return te-this.lastIncrementTime>this.interval&&(this.lastIncrementTime=te,this.value=0),this.value++,this.value}}e.IntervalCounter=F;class ne{constructor(){this.rejected=!1,this.resolved=!1,this.p=new Promise((te,ve)=>{this.completeCallback=te,this.errorCallback=ve})}get isRejected(){return this.rejected}get isResolved(){return this.resolved}get isSettled(){return this.rejected||this.resolved}complete(te){return new Promise(ve=>{this.completeCallback(te),this.resolved=!0,ve()})}error(te){return new Promise(ve=>{this.errorCallback(te),this.rejected=!0,ve()})}cancel(){new Promise(te=>{this.errorCallback(new p.CancellationError),this.rejected=!0,te()})}}e.DeferredPromise=ne;var ce;(function(be){async function te(Re){let Fe;const $e=await Promise.all(Re.map(Ye=>Ye.then(Ie=>Ie,Ie=>{Fe||(Fe=Ie)})));if(typeof Fe!="undefined")throw Fe;return $e}be.settled=te;function ve(Re){return new Promise(async(Fe,$e)=>{try{await Re(Fe,$e)}catch(Ye){$e(Ye)}})}be.withAsyncBody=ve})(ce=e.Promises||(e.Promises={}));var re;(function(be){be[be.Initial=0]="Initial",be[be.DoneOK=1]="DoneOK",be[be.DoneError=2]="DoneError"})(re||(re={}));class fe{constructor(te){this._state=0,this._results=[],this._error=null,this._onStateChanged=new b.Emitter,queueMicrotask(async()=>{const ve={emitOne:Re=>this.emitOne(Re),emitMany:Re=>this.emitMany(Re),reject:Re=>this.reject(Re)};try{await Promise.resolve(te(ve)),this.resolve()}catch(Re){this.reject(Re)}finally{ve.emitOne=void 0,ve.emitMany=void 0,ve.reject=void 0}})}static fromArray(te){return new fe(ve=>{ve.emitMany(te)})}static fromPromise(te){return new fe(async ve=>{ve.emitMany(await te)})}static fromPromises(te){return new fe(async ve=>{await Promise.all(te.map(async Re=>ve.emitOne(await Re)))})}static merge(te){return new fe(async ve=>{await Promise.all(te.map(async Re=>{for await(const Fe of Re)ve.emitOne(Fe)}))})}[Symbol.asyncIterator](){let te=0;return{next:async()=>{do{if(this._state===2)throw this._error;if(te<this._results.length)return{done:!1,value:this._results[te++]};if(this._state===1)return{done:!0,value:void 0};await b.Event.toPromise(this._onStateChanged.event)}while(!0)}}}static map(te,ve){return new fe(async Re=>{for await(const Fe of te)Re.emitOne(ve(Fe))})}map(te){return fe.map(this,te)}static filter(te,ve){return new fe(async Re=>{for await(const Fe of te)ve(Fe)&&Re.emitOne(Fe)})}filter(te){return fe.filter(this,te)}static coalesce(te){return fe.filter(te,ve=>!!ve)}coalesce(){return fe.coalesce(this)}static async toPromise(te){const ve=[];for await(const Re of te)ve.push(Re);return ve}toPromise(){return fe.toPromise(this)}emitOne(te){this._state===0&&(this._results.push(te),this._onStateChanged.fire())}emitMany(te){this._state===0&&(this._results=this._results.concat(te),this._onStateChanged.fire())}resolve(){this._state===0&&(this._state=1,this._onStateChanged.fire())}reject(te){this._state===0&&(this._state=2,this._error=te,this._onStateChanged.fire())}}e.AsyncIterableObject=fe,fe.EMPTY=fe.fromArray([]);class ie extends fe{constructor(te,ve){super(ve);this._source=te}cancel(){this._source.cancel()}}e.CancelableAsyncIterableObject=ie;function Ee(be){const te=new s.CancellationTokenSource,ve=be(te.token);return new ie(te,async Re=>{const Fe=te.token.onCancellationRequested(()=>{Fe.dispose(),te.dispose(),Re.reject(new p.CancellationError)});try{for await(const $e of ve){if(te.token.isCancellationRequested)return;Re.emitOne($e)}Fe.dispose(),te.dispose()}catch($e){Fe.dispose(),te.dispose(),Re.reject($e)}})}e.createCancelableAsyncIterable=Ee}),define(ye[111],Ce([1,0,13,19]),function(ee,e,s,p){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.compareByPrefix=e.compareAnything=e.comparePaths=e.compareFileExtensionsUnicode=e.compareFileExtensionsLower=e.compareFileExtensionsUpper=e.compareFileExtensionsDefault=e.compareFileExtensions=e.noIntlCompareFileNames=e.compareFileNamesUnicode=e.compareFileNamesLower=e.compareFileNamesUpper=e.compareFileNamesDefault=e.compareFileNames=void 0;const b=new s.IdleValue(()=>{const g=new Intl.Collator(void 0,{numeric:!0,sensitivity:"base"});return{collator:g,collatorIsNumeric:g.resolvedOptions().numeric}}),L=new s.IdleValue(()=>({collator:new Intl.Collator(void 0,{numeric:!0})})),C=new s.IdleValue(()=>({collator:new Intl.Collator(void 0,{numeric:!0,sensitivity:"accent"})}));function T(g,D,U=!1){const W=g||"",M=D||"",S=b.value.collator.compare(W,M);return b.value.collatorIsNumeric&&S===0&&W!==M?W<M?-1:1:S}e.compareFileNames=T;function E(g,D){const U=L.value.collator;return g=g||"",D=D||"",_(U,g,D)}e.compareFileNamesDefault=E;function A(g,D){const U=L.value.collator;return g=g||"",D=D||"",o(g,D)||_(U,g,D)}e.compareFileNamesUpper=A;function R(g,D){const U=L.value.collator;return g=g||"",D=D||"",i(g,D)||_(U,g,D)}e.compareFileNamesLower=R;function y(g,D){return g=g||"",D=D||"",g===D?0:g<D?-1:1}e.compareFileNamesUnicode=y;function m(g,D,U=!1){U||(g=g&&g.toLowerCase(),D=D&&D.toLowerCase());const[W,M]=P(g),[S,z]=P(D);return W!==S?W<S?-1:1:M===z?0:M<z?-1:1}e.noIntlCompareFileNames=m;function I(g,D){const[U,W]=P(g),[M,S]=P(D);let z=b.value.collator.compare(W,S);if(z===0){if(b.value.collatorIsNumeric&&W!==S)return W<S?-1:1;if(z=b.value.collator.compare(U,M),b.value.collatorIsNumeric&&z===0&&U!==M)return U<M?-1:1}return z}e.compareFileExtensions=I;function f(g,D){g=g||"",D=D||"";const U=l(g),W=l(D),M=L.value.collator,S=C.value.collator;return _(S,U,W)||_(M,g,D)}e.compareFileExtensionsDefault=f;function h(g,D){g=g||"",D=D||"";const U=l(g),W=l(D),M=L.value.collator,S=C.value.collator;return _(S,U,W)||o(g,D)||_(M,g,D)}e.compareFileExtensionsUpper=h;function d(g,D){g=g||"",D=D||"";const U=l(g),W=l(D),M=L.value.collator,S=C.value.collator;return _(S,U,W)||i(g,D)||_(M,g,D)}e.compareFileExtensionsLower=d;function a(g,D){g=g||"",D=D||"";const U=l(g).toLowerCase(),W=l(D).toLowerCase();return U!==W?U<W?-1:1:g!==D?g<D?-1:1:0}e.compareFileExtensionsUnicode=a;const w=/^(.*?)(\.([^.]*))?$/;function P(g,D=!1){const U=g?w.exec(g):[];let W=[U&&U[1]||"",U&&U[3]||""];return D&&(!W[0]&&W[1]||W[0]&&W[0].charAt(0)===".")&&(W=[W[0]+"."+W[1],""]),W}function l(g){const D=g?w.exec(g):[];return D&&D[1]&&D[1].charAt(0)!=="."&&D[3]||""}function _(g,D,U){const W=g.compare(D,U);return W!==0?W:D.length!==U.length?D.length<U.length?-1:1:0}function n(g){const D=g.charAt(0);return D.toLocaleUpperCase()!==D}function u(g){const D=g.charAt(0);return D.toLocaleLowerCase()!==D}function i(g,D){return n(g)&&u(D)?-1:u(g)&&n(D)?1:0}function o(g,D){return u(g)&&n(D)?-1:n(g)&&u(D)?1:0}function r(g,D,U=!1){return U||(g=g&&g.toLowerCase(),D=D&&D.toLowerCase()),g===D?0:g<D?-1:1}function t(g,D,U=!1){const W=g.split(p.sep),M=D.split(p.sep),S=W.length-1,z=M.length-1;let $,N;for(let K=0;;K++){if($=S===K,N=z===K,$&&N)return T(W[K],M[K],U);if($)return-1;if(N)return 1;const V=r(W[K],M[K],U);if(V!==0)return V}}e.comparePaths=t;function c(g,D,U){const W=g.toLowerCase(),M=D.toLowerCase(),S=v(g,D,U);if(S)return S;const z=W.endsWith(U),$=M.endsWith(U);if(z!==$)return z?-1:1;const N=T(W,M);return N!==0?N:W.localeCompare(M)}e.compareAnything=c;function v(g,D,U){const W=g.toLowerCase(),M=D.toLowerCase(),S=W.startsWith(U),z=M.startsWith(U);if(S!==z)return S?-1:1;if(S&&z){if(W.length<M.length)return-1;if(W.length>M.length)return 1}return 0}e.compareByPrefix=v}),define(ye[34],Ce([1,0,16,13,37,25,19,23,9]),function(ee,e,s,p,b,L,C,T,E){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.patternsEquals=e.getPathTerms=e.getBasenameTerms=e.isRelativePattern=e.parse=e.match=e.splitGlobAware=e.GLOB_SPLIT=e.GLOBSTAR=e.getEmptyExpression=void 0;function A(){return Object.create(null)}e.getEmptyExpression=A,e.GLOBSTAR="**",e.GLOB_SPLIT="/";const R="[/\\\\]",y="[^/\\\\]",m=/\//g;function I(ne,ce){switch(ne){case 0:return"";case 1:return`${y}*?`;default:return`(?:${R}|${y}+${R}${ce?`|${R}${y}+`:""})*?`}}function f(ne,ce){if(!ne)return[];const re=[];let fe=!1,ie=!1,Ee="";for(const be of ne){switch(be){case ce:if(!fe&&!ie){re.push(Ee),Ee="";continue}break;case"{":fe=!0;break;case"}":fe=!1;break;case"[":ie=!0;break;case"]":ie=!1;break}Ee+=be}return Ee&&re.push(Ee),re}e.splitGlobAware=f;function h(ne){if(!ne)return"";let ce="";const re=f(ne,e.GLOB_SPLIT);if(re.every(fe=>fe===e.GLOBSTAR))ce=".*";else{let fe=!1;re.forEach((ie,Ee)=>{if(ie===e.GLOBSTAR){if(fe)return;ce+=I(2,Ee===re.length-1)}else{let be=!1,te="",ve=!1,Re="";for(const Fe of ie){if(Fe!=="}"&&be){te+=Fe;continue}if(ve&&(Fe!=="]"||!Re)){let $e;Fe==="-"?$e=Fe:(Fe==="^"||Fe==="!")&&!Re?$e="^":Fe===e.GLOB_SPLIT?$e="":$e=(0,E.escapeRegExpCharacters)(Fe),Re+=$e;continue}switch(Fe){case"{":be=!0;continue;case"[":ve=!0;continue;case"}":{ce+=`(?:${f(te,",").map(Ie=>h(Ie)).join("|")})`,be=!1,te="";break}case"]":{ce+="["+Re+"]",ve=!1,Re="";break}case"?":ce+=y;continue;case"*":ce+=I(1);continue;default:ce+=(0,E.escapeRegExpCharacters)(Fe)}}Ee<re.length-1&&(re[Ee+1]!==e.GLOBSTAR||Ee+2<re.length)&&(ce+=R)}fe=ie===e.GLOBSTAR})}return ce}const d=/^\*\*\/\*\.[\w\.-]+$/,a=/^\*\*\/([\w\.-]+)\/?$/,w=/^{\*\*\/\*?[\w\.-]+\/?(,\*\*\/\*?[\w\.-]+\/?)*}$/,P=/^{\*\*\/\*?[\w\.-]+(\/(\*\*)?)?(,\*\*\/\*?[\w\.-]+(\/(\*\*)?)?)*}$/,l=/^\*\*((\/[\w\.-]+)+)\/?$/,_=/^([\w\.-]+(\/[\w\.-]+)*)\/?$/,n=new L.LRUCache(1e4),u=function(){return!1},i=function(){return null};function o(ne,ce){if(!ne)return i;let re;typeof ne!="string"?re=ne.pattern:re=ne,re=re.trim();const fe=`${re}_${!!ce.trimForExclusions}`;let ie=n.get(fe);if(ie)return r(ie,ne);let Ee;return d.test(re)?ie=c(re.substr(4),re):(Ee=a.exec(t(re,ce)))?ie=v(Ee[1],re):(ce.trimForExclusions?P:w).test(re)?ie=g(re,ce):(Ee=l.exec(t(re,ce)))?ie=D(Ee[1].substr(1),re,!0):(Ee=_.exec(t(re,ce)))?ie=D(Ee[1],re,!1):ie=U(re),n.set(fe,ie),r(ie,ne)}function r(ne,ce){if(typeof ce=="string")return ne;const re=function(fe,ie){return(0,b.isEqualOrParent)(fe,ce.base,!T.isLinux)?ne(fe.substr(ce.base.length+1),ie):null};return re.allBasenames=ne.allBasenames,re.allPaths=ne.allPaths,re.basenames=ne.basenames,re.patterns=ne.patterns,re}function t(ne,ce){return ce.trimForExclusions&&ne.endsWith("/**")?ne.substr(0,ne.length-2):ne}function c(ne,ce){return function(re,fe){return typeof re=="string"&&re.endsWith(ne)?ce:null}}function v(ne,ce){const re=`/${ne}`,fe=`\\${ne}`,ie=function(be,te){return typeof be!="string"?null:te?te===ne?ce:null:be===ne||be.endsWith(re)||be.endsWith(fe)?ce:null},Ee=[ne];return ie.basenames=Ee,ie.patterns=[ce],ie.allBasenames=Ee,ie}function g(ne,ce){const re=V(ne.slice(1,-1).split(",").map(te=>o(te,ce)).filter(te=>te!==i),ne),fe=re.length;if(!fe)return i;if(fe===1)return re[0];const ie=function(te,ve){for(let Re=0,Fe=re.length;Re<Fe;Re++)if(re[Re](te,ve))return ne;return null},Ee=re.find(te=>!!te.allBasenames);Ee&&(ie.allBasenames=Ee.allBasenames);const be=re.reduce((te,ve)=>ve.allPaths?te.concat(ve.allPaths):te,[]);return be.length&&(ie.allPaths=be),ie}function D(ne,ce,re){const fe=C.sep===C.posix.sep,ie=fe?ne:ne.replace(m,C.sep),Ee=C.sep+ie,be=C.posix.sep+ne;let te;return re?te=function(ve,Re){return typeof ve=="string"&&(ve===ie||ve.endsWith(Ee)||!fe&&(ve===ne||ve.endsWith(be)))?ce:null}:te=function(ve,Re){return typeof ve=="string"&&(ve===ie||!fe&&ve===ne)?ce:null},te.allPaths=[(re?"*/":"./")+ne],te}function U(ne){try{const ce=new RegExp(`^${h(ne)}$`);return function(re){return ce.lastIndex=0,typeof re=="string"&&ce.test(re)?ne:null}}catch{return i}}function W(ne,ce,re){return!ne||typeof ce!="string"?!1:M(ne)(ce,void 0,re)}e.match=W;function M(ne,ce={}){if(!ne)return u;if(typeof ne=="string"||S(ne)){const re=o(ne,ce);if(re===i)return u;const fe=function(ie,Ee){return!!re(ie,Ee)};return re.allBasenames&&(fe.allBasenames=re.allBasenames),re.allPaths&&(fe.allPaths=re.allPaths),fe}return N(ne,ce)}e.parse=M;function S(ne){const ce=ne;return ce?typeof ce.base=="string"&&typeof ce.pattern=="string":!1}e.isRelativePattern=S;function z(ne){return ne.allBasenames||[]}e.getBasenameTerms=z;function $(ne){return ne.allPaths||[]}e.getPathTerms=$;function N(ne,ce){const re=V(Object.getOwnPropertyNames(ne).map(te=>K(te,ne[te],ce)).filter(te=>te!==i)),fe=re.length;if(!fe)return i;if(!re.some(te=>!!te.requiresSiblings)){if(fe===1)return re[0];const te=function(Fe,$e){let Ye;for(let Ie=0,Se=re.length;Ie<Se;Ie++){const Te=re[Ie](Fe,$e);if(typeof Te=="string")return Te;(0,p.isThenable)(Te)&&(Ye||(Ye=[]),Ye.push(Te))}return Ye?(async()=>{for(const Ie of Ye){const Se=await Ie;if(typeof Se=="string")return Se}return null})():null},ve=re.find(Fe=>!!Fe.allBasenames);ve&&(te.allBasenames=ve.allBasenames);const Re=re.reduce((Fe,$e)=>$e.allPaths?Fe.concat($e.allPaths):Fe,[]);return Re.length&&(te.allPaths=Re),te}const ie=function(te,ve,Re){let Fe,$e;for(let Ye=0,Ie=re.length;Ye<Ie;Ye++){const Se=re[Ye];Se.requiresSiblings&&Re&&(ve||(ve=(0,C.basename)(te)),Fe||(Fe=ve.substr(0,ve.length-(0,C.extname)(te).length)));const Te=Se(te,ve,Fe,Re);if(typeof Te=="string")return Te;(0,p.isThenable)(Te)&&($e||($e=[]),$e.push(Te))}return $e?(async()=>{for(const Ye of $e){const Ie=await Ye;if(typeof Ie=="string")return Ie}return null})():null},Ee=re.find(te=>!!te.allBasenames);Ee&&(ie.allBasenames=Ee.allBasenames);const be=re.reduce((te,ve)=>ve.allPaths?te.concat(ve.allPaths):te,[]);return be.length&&(ie.allPaths=be),ie}function K(ne,ce,re){if(ce===!1)return i;const fe=o(ne,re);if(fe===i)return i;if(typeof ce=="boolean")return fe;if(ce){const ie=ce.when;if(typeof ie=="string"){const Ee=(be,te,ve,Re)=>{if(!Re||!fe(be,te))return null;const Fe=ie.replace("$(basename)",ve),$e=Re(Fe);return(0,p.isThenable)($e)?$e.then(Ye=>Ye?ne:null):$e?ne:null};return Ee.requiresSiblings=!0,Ee}}return fe}function V(ne,ce){const re=ne.filter(te=>!!te.basenames);if(re.length<2)return ne;const fe=re.reduce((te,ve)=>{const Re=ve.basenames;return Re?te.concat(Re):te},[]);let ie;if(ce){ie=[];for(let te=0,ve=fe.length;te<ve;te++)ie.push(ce)}else ie=re.reduce((te,ve)=>{const Re=ve.patterns;return Re?te.concat(Re):te},[]);const Ee=function(te,ve){if(typeof te!="string")return null;if(!ve){let Fe;for(Fe=te.length;Fe>0;Fe--){const $e=te.charCodeAt(Fe-1);if($e===47||$e===92)break}ve=te.substr(Fe)}const Re=fe.indexOf(ve);return Re!==-1?ie[Re]:null};Ee.basenames=fe,Ee.patterns=ie,Ee.allBasenames=fe;const be=ne.filter(te=>!te.basenames);return be.push(Ee),be}function F(ne,ce){return(0,s.equals)(ne,ce,(re,fe)=>typeof re=="string"&&typeof fe=="string"?re===fe:typeof re!="string"&&typeof fe!="string"?re.base===fe.base&&re.pattern===fe.pattern:!1)}e.patternsEquals=F}),define(ye[75],Ce([1,0,11,109,21,9,2]),function(ee,e,s,p,b,L,C){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.parseHrefAndDimensions=e.removeMarkdownEscapes=e.escapeDoubleQuotes=e.escapeMarkdownSyntaxTokens=e.markdownStringEqual=e.isMarkdownString=e.isEmptyMarkdownString=e.MarkdownString=e.MarkdownStringTextNewlineStyle=void 0;var T;(function(d){d[d.Paragraph=0]="Paragraph",d[d.Break=1]="Break"})(T=e.MarkdownStringTextNewlineStyle||(e.MarkdownStringTextNewlineStyle={}));class E{constructor(a="",w=!1){if(this.value=a,typeof this.value!="string")throw(0,s.illegalArgument)("value");typeof w=="boolean"?(this.isTrusted=w,this.supportThemeIcons=!1,this.supportHtml=!1):(this.isTrusted=w.isTrusted??void 0,this.supportThemeIcons=w.supportThemeIcons??!1,this.supportHtml=w.supportHtml??!1)}appendText(a,w=0){return this.value+=m(this.supportThemeIcons?(0,p.escapeIcons)(a):a).replace(/([ \t]+)/g,(P,l)=>" ".repeat(l.length)).replace(/\>/gm,"\\>").replace(/\n/g,w===1?`\\
`:`
`),this}appendMarkdown(a){return this.value+=a,this}appendCodeblock(a,w){return this.value+="\n```",this.value+=a,this.value+=`
`,this.value+=w,this.value+="\n```\n",this}appendLink(a,w,P){return this.value+="[",this.value+=this._escape(w,"]"),this.value+="](",this.value+=this._escape(String(a),")"),P&&(this.value+=` "${this._escape(this._escape(P,'"'),")")}"`),this.value+=")",this}_escape(a,w){const P=new RegExp((0,L.escapeRegExpCharacters)(w),"g");return a.replace(P,(l,_)=>a.charAt(_-1)!=="\\"?`\\${l}`:l)}}e.MarkdownString=E;function A(d){return R(d)?!d.value:Array.isArray(d)?d.every(A):!0}e.isEmptyMarkdownString=A;function R(d){return d instanceof E?!0:d&&typeof d=="object"?typeof d.value=="string"&&(typeof d.isTrusted=="boolean"||d.isTrusted===void 0)&&(typeof d.supportThemeIcons=="boolean"||d.supportThemeIcons===void 0):!1}e.isMarkdownString=R;function y(d,a){return d===a?!0:!d||!a?!1:d.value===a.value&&d.isTrusted===a.isTrusted&&d.supportThemeIcons===a.supportThemeIcons&&d.supportHtml===a.supportHtml&&(d.baseUri===a.baseUri||!!d.baseUri&&!!a.baseUri&&(0,b.isEqual)(C.URI.from(d.baseUri),C.URI.from(a.baseUri)))}e.markdownStringEqual=y;function m(d){return d.replace(/[\\`*_{}[\]()#+\-!]/g,"\\$&")}e.escapeMarkdownSyntaxTokens=m;function I(d){return d.replace(/"/g,""")}e.escapeDoubleQuotes=I;function f(d){return d&&d.replace(/\\([\\`*_{}[\]()#+\-.!])/g,"$1")}e.removeMarkdownEscapes=f;function h(d){const a=[],w=d.split("|").map(l=>l.trim());d=w[0];const P=w[1];if(P){const l=/height=(\d+)/.exec(P),_=/width=(\d+)/.exec(P),n=l?l[1]:"",u=_?_[1]:"",i=isFinite(parseInt(u)),o=isFinite(parseInt(n));i&&a.push(`width="${u}"`),o&&a.push(`height="${n}"`)}return{href:d,dimensions:a}}e.parseHrefAndDimensions=h}),define(ye[76],Ce([1,0,16,37,19,23,21,9]),function(ee,e,s,p,b,L,C,T){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.splitName=e.unmnemonicLabel=e.mnemonicButtonLabel=e.mnemonicMenuLabel=e.template=e.shorten=e.untildify=e.tildify=e.normalizeDriveLetter=e.getPathLabel=void 0;function E(i,o){const{os:r,tildify:t,relative:c}=o;if(c){const D=A(i,c,r);if(typeof D=="string")return D}let v=i.fsPath;if(r===1&&!L.isWindows?v=v.replace(/\//g,"\\"):r!==1&&L.isWindows&&(v=v.replace(/\\/g,"/")),r!==1&&t?.userHome){const D=t.userHome.fsPath;let U;i.scheme!==t.userHome.scheme&&i.path.startsWith(b.posix.sep)?U=t.userHome.with({path:i.path}).fsPath:U=i.fsPath,v=m(U,D,r)}return(r===1?b.win32:b.posix).normalize(R(v,r===1))}e.getPathLabel=E;function A(i,o,r){const t=r===1?b.win32:b.posix,c=r===3?C.extUri:C.extUriIgnorePathCase,v=o.getWorkspace(),g=(0,s.firstOrDefault)(v.folders);if(!g)return;i.scheme!==g.uri.scheme&&i.path.startsWith(b.posix.sep)&&(i=g.uri.with({path:i.path}));const D=o.getWorkspaceFolder(i);if(!D)return;let U;if(c.isEqual(D.uri,i)?U="":U=c.relativePath(D.uri,i)??"",U&&(U=t.normalize(U)),v.folders.length>1&&!o.noPrefix){const W=D.name?D.name:c.basenameOrAuthority(D.uri);U=U?`${W} \u2022 ${U}`:W}return U}function R(i,o=L.isWindows){return(0,p.hasDriveLetter)(i,o)?i.charAt(0).toUpperCase()+i.slice(1):i}e.normalizeDriveLetter=R;let y=Object.create(null);function m(i,o,r=L.OS){if(r===1||!i||!o)return i;let t=y.original===o?y.normalized:void 0;t||(t=o,L.isWindows&&(t=(0,p.toSlashes)(t)),t=`${(0,T.rtrim)(t,b.posix.sep)}${b.posix.sep}`,y={original:o,normalized:t});let c=i;return L.isWindows&&(c=(0,p.toSlashes)(c)),(r===3?c.startsWith(t):(0,T.startsWithIgnoreCase)(c,t))?`~/${c.substr(t.length)}`:i}e.tildify=m;function I(i,o){return i.replace(/^~($|\/|\\)/,`${o}$1`)}e.untildify=I;const f="\u2026",h="\\\\",d="~";function a(i,o=b.sep){const r=new Array(i.length);let t=!1;for(let c=0;c<i.length;c++){const v=i[c];if(v===""){r[c]=`.${o}`;continue}if(!v){r[c]=v;continue}t=!0;let g="",D=v;D.indexOf(h)===0?(g=D.substr(0,D.indexOf(h)+h.length),D=D.substr(D.indexOf(h)+h.length)):D.indexOf(o)===0?(g=D.substr(0,D.indexOf(o)+o.length),D=D.substr(D.indexOf(o)+o.length)):D.indexOf(d)===0&&(g=D.substr(0,D.indexOf(d)+d.length),D=D.substr(D.indexOf(d)+d.length));const U=D.split(o);for(let W=1;t&&W<=U.length;W++)for(let M=U.length-W;t&&M>=0;M--){t=!1;let S=U.slice(M,M+W).join(o);for(let z=0;!t&&z<i.length;z++)if(z!==c&&i[z]&&i[z].indexOf(S)>-1){const $=M+W===U.length,N=M>0&&i[z].indexOf(o)>-1?o+S:S,K=i[z].endsWith(N);t=!$||K}if(!t){let z="";(U[0].endsWith(":")||g!=="")&&(M===1&&(M=0,W++,S=U[0]+o+S),M>0&&(z=U[0]+o),z=g+z),M>0&&(z=z+f+o),z=z+S,M+W<U.length&&(z=z+o+f),r[c]=z}}t&&(r[c]=v)}return r}e.shorten=a;var w;(function(i){i[i.TEXT=0]="TEXT",i[i.VARIABLE=1]="VARIABLE",i[i.SEPARATOR=2]="SEPARATOR"})(w||(w={}));function P(i,o=Object.create(null)){const r=[];let t=!1,c="";for(const v of i)if(v==="$"||t&&v==="{")c&&r.push({value:c,type:w.TEXT}),c="",t=!0;else if(v==="}"&&t){const g=o[c];if(typeof g=="string")g.length&&r.push({value:g,type:w.VARIABLE});else if(g){const D=r[r.length-1];(!D||D.type!==w.SEPARATOR)&&r.push({value:g.label,type:w.SEPARATOR})}c="",t=!1}else c+=v;return c&&!t&&r.push({value:c,type:w.TEXT}),r.filter((v,g)=>{if(v.type===w.SEPARATOR){const D=r[g-1],U=r[g+1];return[D,U].every(W=>W&&(W.type===w.VARIABLE||W.type===w.TEXT)&&W.value.length>0)}return!0}).map(v=>v.value).join("")}e.template=P;function l(i,o){return L.isMacintosh||o?i.replace(/\(&&\w\)|&&/g,"").replace(/&/g,L.isMacintosh?"&":"&&"):i.replace(/&&|&/g,r=>r==="&"?"&&":"&")}e.mnemonicMenuLabel=l;function _(i,o){return L.isMacintosh||o?i.replace(/\(&&\w\)|&&/g,""):L.isWindows?i.replace(/&&|&/g,r=>r==="&"?"&&":"&"):i.replace(/&&/g,"_")}e.mnemonicButtonLabel=_;function n(i){return i.replace(/&/g,"&&")}e.unmnemonicLabel=n;function u(i){const o=i.indexOf("/")!==-1?b.posix:b.win32,r=o.basename(i),t=o.dirname(i);return r.length?{name:r,parentPath:t}:{name:t,parentPath:""}}e.splitName=u}),define(ye[112],Ce([1,0,2]),function(ee,e,s){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.transformAndReviveIncomingURIs=e.transformIncomingURIs=e.transformOutgoingURIs=e.DefaultURITransformer=e.URITransformer=void 0;function p(R){return R.toJSON()}class b{constructor(y){this._uriTransformer=y}transformIncoming(y){const m=this._uriTransformer.transformIncoming(y);return m===y?y:p(s.URI.from(m))}transformOutgoing(y){const m=this._uriTransformer.transformOutgoing(y);return m===y?y:p(s.URI.from(m))}transformOutgoingURI(y){const m=this._uriTransformer.transformOutgoing(y);return m===y?y:s.URI.from(m)}transformOutgoingScheme(y){return this._uriTransformer.transformOutgoingScheme(y)}}e.URITransformer=b,e.DefaultURITransformer=new class{transformIncoming(R){return R}transformOutgoing(R){return R}transformOutgoingURI(R){return R}transformOutgoingScheme(R){return R}};function L(R,y,m){if(!R||m>200)return null;if(typeof R=="object"){if(R instanceof s.URI)return y.transformOutgoing(R);for(const I in R)if(Object.hasOwnProperty.call(R,I)){const f=L(R[I],y,m+1);f!==null&&(R[I]=f)}}return null}function C(R,y){const m=L(R,y,0);return m===null?R:m}e.transformOutgoingURIs=C;function T(R,y,m,I){if(!R||I>200)return null;if(typeof R=="object"){if(R.$mid===1)return m?s.URI.revive(y.transformIncoming(R)):y.transformIncoming(R);for(const f in R)if(Object.hasOwnProperty.call(R,f)){const h=T(R[f],y,m,I+1);h!==null&&(R[f]=h)}}return null}function E(R,y){const m=T(R,y,!1,0);return m===null?R:m}e.transformIncomingURIs=E;function A(R,y){const m=T(R,y,!0,0);return m===null?R:m}e.transformAndReviveIncomingURIs=A}),define(ye[43],Ce([1,0]),function(ee,e){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.generateUuid=e.isUUID=void 0;const s=/^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/i;function p(b){return s.test(b)}e.isUUID=p,e.generateUuid=function(){if(typeof crypto=="object"&&typeof crypto.randomUUID=="function")return crypto.randomUUID.bind(crypto);let b;typeof crypto=="object"&&typeof crypto.getRandomValues=="function"?b=crypto.getRandomValues.bind(crypto):b=function(T){for(let E=0;E<T.length;E++)T[E]=Math.floor(Math.random()*256);return T};const L=new Uint8Array(16),C=[];for(let T=0;T<256;T++)C.push(T.toString(16).padStart(2,"0"));return function(){b(L),L[6]=L[6]&15|64,L[8]=L[8]&63|128;let E=0,A="";return A+=C[L[E++]],A+=C[L[E++]],A+=C[L[E++]],A+=C[L[E++]],A+="-",A+=C[L[E++]],A+=C[L[E++]],A+="-",A+=C[L[E++]],A+=C[L[E++]],A+="-",A+=C[L[E++]],A+=C[L[E++]],A+="-",A+=C[L[E++]],A+=C[L[E++]],A+=C[L[E++]],A+=C[L[E++]],A+=C[L[E++]],A+=C[L[E++]],A}}()}),define(ye[113],Ce([1,0]),function(ee,e){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.EDITOR_MODEL_DEFAULTS=void 0,e.EDITOR_MODEL_DEFAULTS={tabSize:4,indentSize:4,insertSpaces:!0,detectIndentation:!0,trimAutoWhitespace:!0,largeFileOptimizations:!0,bracketPairColorizationOptions:{enabled:!0,independentColorPoolPerBracketType:!1}}}),define(ye[114],Ce([1,0,34,19]),function(ee,e,s,p){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.score=void 0;function b(L,C,T,E,A,R){if(Array.isArray(L)){let y=0;for(const m of L){const I=b(m,C,T,E,A,R);if(I===10)return I;I>y&&(y=I)}return y}else{if(typeof L=="string")return E?L==="*"?5:L===T?10:0:0;if(L){const{language:y,pattern:m,scheme:I,hasAccessToAllModels:f,notebookType:h}=L;if(!E&&!f)return 0;h&&A&&(C=A);let d=0;if(I)if(I===C.scheme)d=10;else if(I==="*")d=5;else return 0;if(y)if(y===T)d=10;else if(y==="*")d=Math.max(d,5);else return 0;if(h)if(h===R)d=10;else if(h==="*"&&R!==void 0)d=Math.max(d,5);else return 0;if(m){let a;if(typeof m=="string"?a=m:a={...m,base:(0,p.normalize)(m.base)},a===C.fsPath||(0,s.match)(a,C.fsPath))d=10;else return 0}return d}else return 0}}e.score=b}),define(ye[115],Ce([1,0]),function(ee,e){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.AutoClosingPairs=e.StandardAutoClosingPairConditional=e.IndentAction=void 0;var s;(function(C){C[C.None=0]="None",C[C.Indent=1]="Indent",C[C.IndentOutdent=2]="IndentOutdent",C[C.Outdent=3]="Outdent"})(s=e.IndentAction||(e.IndentAction={}));class p{constructor(T){if(this._neutralCharacter=null,this._neutralCharacterSearched=!1,this.open=T.open,this.close=T.close,this._inString=!0,this._inComment=!0,this._inRegEx=!0,Array.isArray(T.notIn))for(let E=0,A=T.notIn.length;E<A;E++)switch(T.notIn[E]){case"string":this._inString=!1;break;case"comment":this._inComment=!1;break;case"regex":this._inRegEx=!1;break}}isOK(T){switch(T){case 0:return!0;case 1:return this._inComment;case 2:return this._inString;case 3:return this._inRegEx}}shouldAutoClose(T,E){if(T.getTokenCount()===0)return!0;const A=T.findTokenIndexAtOffset(E-2),R=T.getStandardTokenType(A);return this.isOK(R)}_findNeutralCharacterInRange(T,E){for(let A=T;A<=E;A++){const R=String.fromCharCode(A);if(!this.open.includes(R)&&!this.close.includes(R))return R}return null}findNeutralCharacter(){return this._neutralCharacterSearched||(this._neutralCharacterSearched=!0,this._neutralCharacter||(this._neutralCharacter=this._findNeutralCharacterInRange(48,57)),this._neutralCharacter||(this._neutralCharacter=this._findNeutralCharacterInRange(97,122)),this._neutralCharacter||(this._neutralCharacter=this._findNeutralCharacterInRange(65,90))),this._neutralCharacter}}e.StandardAutoClosingPairConditional=p;class b{constructor(T){this.autoClosingPairsOpenByStart=new Map,this.autoClosingPairsOpenByEnd=new Map,this.autoClosingPairsCloseByStart=new Map,this.autoClosingPairsCloseByEnd=new Map,this.autoClosingPairsCloseSingleChar=new Map;for(const E of T)L(this.autoClosingPairsOpenByStart,E.open.charAt(0),E),L(this.autoClosingPairsOpenByEnd,E.open.charAt(E.open.length-1),E),L(this.autoClosingPairsCloseByStart,E.close.charAt(0),E),L(this.autoClosingPairsCloseByEnd,E.close.charAt(E.close.length-1),E),E.close.length===1&&E.open.length===1&&L(this.autoClosingPairsCloseSingleChar,E.close,E)}}e.AutoClosingPairs=b;function L(C,T,E){C.has(T)?C.get(T).push(E):C.set(T,[E])}}),define(ye[77],Ce([1,0,22,23]),function(ee,e,s,p){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.decodeSemanticTokensDto=e.encodeSemanticTokensDto=void 0;var b;(function(y){y[y.Full=1]="Full",y[y.Delta=2]="Delta"})(b||(b={}));function L(y){for(let m=0,I=y.length;m<I;m+=4){const f=y[m+0],h=y[m+1],d=y[m+2],a=y[m+3];y[m+0]=a,y[m+1]=d,y[m+2]=h,y[m+3]=f}}function C(y){const m=new Uint8Array(y.buffer,y.byteOffset,y.length*4);return p.isLittleEndian()||L(m),s.VSBuffer.wrap(m)}function T(y){const m=y.buffer;if(p.isLittleEndian()||L(m),m.byteOffset%4==0)return new Uint32Array(m.buffer,m.byteOffset,m.length/4);{const I=new Uint8Array(m.byteLength);return I.set(m),new Uint32Array(I.buffer,I.byteOffset,I.length/4)}}function E(y){const m=new Uint32Array(A(y));let I=0;if(m[I++]=y.id,y.type==="full")m[I++]=1,m[I++]=y.data.length,m.set(y.data,I),I+=y.data.length;else{m[I++]=2,m[I++]=y.deltas.length;for(const f of y.deltas)m[I++]=f.start,m[I++]=f.deleteCount,f.data?(m[I++]=f.data.length,m.set(f.data,I),I+=f.data.length):m[I++]=0}return C(m)}e.encodeSemanticTokensDto=E;function A(y){let m=0;if(m+=1+1,y.type==="full")m+=1+y.data.length;else{m+=1,m+=(1+1+1)*y.deltas.length;for(const I of y.deltas)I.data&&(m+=I.data.length)}return m}function R(y){const m=T(y);let I=0;const f=m[I++];if(m[I++]===1){const w=m[I++],P=m.subarray(I,I+w);return I+=w,{id:f,type:"full",data:P}}const d=m[I++],a=[];for(let w=0;w<d;w++){const P=m[I++],l=m[I++],_=m[I++];let n;_>0&&(n=m.subarray(I,I+_),I+=_),a[w]={start:P,deleteCount:l,data:n}}return{id:f,type:"delta",deltas:a}}e.decodeSemanticTokensDto=R}),define(ye[116],Ce([17,18]),function(ee,e){return ee.create("vs/base/common/date",e)}),define(ye[117],Ce([1,0,116]),function(ee,e,s){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.toLocalISOString=e.fromNow=void 0;const p=60,b=p*60,L=b*24,C=L*7,T=L*30,E=L*365;function A(y,m,I){typeof y!="number"&&(y=y.getTime());const f=Math.round((new Date().getTime()-y)/1e3);if(f<-30)return(0,s.localize)(0,null,A(new Date().getTime()+f*1e3,!1));if(f<30)return(0,s.localize)(1,null);let h;return f<p?(h=f,m?h===1?I?(0,s.localize)(2,null,h):(0,s.localize)(3,null,h):I?(0,s.localize)(4,null,h):(0,s.localize)(5,null,h):h===1?I?(0,s.localize)(6,null,h):(0,s.localize)(7,null,h):I?(0,s.localize)(8,null,h):(0,s.localize)(9,null,h)):f<b?(h=Math.floor(f/p),m?h===1?I?(0,s.localize)(10,null,h):(0,s.localize)(11,null,h):I?(0,s.localize)(12,null,h):(0,s.localize)(13,null,h):h===1?I?(0,s.localize)(14,null,h):(0,s.localize)(15,null,h):I?(0,s.localize)(16,null,h):(0,s.localize)(17,null,h)):f<L?(h=Math.floor(f/b),m?h===1?I?(0,s.localize)(18,null,h):(0,s.localize)(19,null,h):I?(0,s.localize)(20,null,h):(0,s.localize)(21,null,h):h===1?I?(0,s.localize)(22,null,h):(0,s.localize)(23,null,h):I?(0,s.localize)(24,null,h):(0,s.localize)(25,null,h)):f<C?(h=Math.floor(f/L),m?h===1?(0,s.localize)(26,null,h):(0,s.localize)(27,null,h):h===1?(0,s.localize)(28,null,h):(0,s.localize)(29,null,h)):f<T?(h=Math.floor(f/C),m?h===1?I?(0,s.localize)(30,null,h):(0,s.localize)(31,null,h):I?(0,s.localize)(32,null,h):(0,s.localize)(33,null,h):h===1?I?(0,s.localize)(34,null,h):(0,s.localize)(35,null,h):I?(0,s.localize)(36,null,h):(0,s.localize)(37,null,h)):f<E?(h=Math.floor(f/T),m?h===1?I?(0,s.localize)(38,null,h):(0,s.localize)(39,null,h):I?(0,s.localize)(40,null,h):(0,s.localize)(41,null,h):h===1?I?(0,s.localize)(42,null,h):(0,s.localize)(43,null,h):I?(0,s.localize)(44,null,h):(0,s.localize)(45,null,h)):(h=Math.floor(f/E),m?h===1?I?(0,s.localize)(46,null,h):(0,s.localize)(47,null,h):I?(0,s.localize)(48,null,h):(0,s.localize)(49,null,h):h===1?I?(0,s.localize)(50,null,h):(0,s.localize)(51,null,h):I?(0,s.localize)(52,null,h):(0,s.localize)(53,null,h))}e.fromNow=A;function R(y){return y.getFullYear()+"-"+String(y.getMonth()+1).padStart(2,"0")+"-"+String(y.getDate()).padStart(2,"0")+"T"+String(y.getHours()).padStart(2,"0")+":"+String(y.getMinutes()).padStart(2,"0")+":"+String(y.getSeconds()).padStart(2,"0")+"."+(y.getMilliseconds()/1e3).toFixed(3).slice(2,5)+"Z"}e.toLocalISOString=R}),define(ye[118],Ce([17,18]),function(ee,e){return ee.create("vs/base/common/errorMessage",e)}),define(ye[44],Ce([1,0,16,10,118]),function(ee,e,s,p,b){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.createErrorWithActions=e.isErrorWithActions=e.toErrorMessage=void 0;function L(y,m){return m&&(y.stack||y.stacktrace)?b.localize(0,null,T(y),C(y.stack)||C(y.stacktrace)):T(y)}function C(y){return Array.isArray(y)?y.join(`
`):y}function T(y){return typeof y.code=="string"&&typeof y.errno=="number"&&typeof y.syscall=="string"?b.localize(1,null,y.message):y.message||b.localize(2,null)}function E(y=null,m=!1){if(!y)return b.localize(3,null);if(Array.isArray(y)){const I=s.coalesce(y),f=E(I[0],m);return I.length>1?b.localize(4,null,f,I.length):f}if(p.isString(y))return y;if(y.detail){const I=y.detail;if(I.error)return L(I.error,m);if(I.exception)return L(I.exception,m)}return y.stack?L(y,m):y.message?y.message:b.localize(5,null)}e.toErrorMessage=E;function A(y){const m=y;return m instanceof Error&&Array.isArray(m.actions)}e.isErrorWithActions=A;function R(y,m){let I;return typeof y=="string"?I=new Error(y):I=y,I.actions=m,I}e.createErrorWithActions=R}),define(ye[119],Ce([17,18]),function(ee,e){return ee.create("vs/editor/common/config/editorOptions",e)}),define(ye[120],Ce([1,0,119,23,121,16,26,113]),function(ee,e,s,p,b,L,C,T){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.EditorOptions=e.EditorOption=e.editorOptionsRegistry=e.EDITOR_FONT_DEFAULTS=e.WrappingIndent=e.unicodeHighlightConfigKeys=e.inUntrustedWorkspace=e.filterValidationDecorations=e.RenderLineNumbersType=e.EditorLayoutInfoComputer=e.RenderMinimap=e.EditorFontLigatures=e.cursorStyleToString=e.TextEditorCursorStyle=e.TextEditorCursorBlinkingStyle=e.stringSet=e.clampedInt=e.boolean=e.ApplyUpdateResult=e.ComputeOptionsMemory=e.ConfigurationChangedEvent=e.MINIMAP_GUTTER_WIDTH=e.EditorAutoIndentStrategy=void 0;var E;(function(G){G[G.None=0]="None",G[G.Keep=1]="Keep",G[G.Brackets=2]="Brackets",G[G.Advanced=3]="Advanced",G[G.Full=4]="Full"})(E=e.EditorAutoIndentStrategy||(e.EditorAutoIndentStrategy={})),e.MINIMAP_GUTTER_WIDTH=8;class A{constructor(Q){this._values=Q}hasChanged(Q){return this._values[Q]}}e.ConfigurationChangedEvent=A;class R{constructor(){this.stableMinimapLayoutInput=null,this.stableFitMaxMinimapScale=0,this.stableFitRemainingWidth=0}}e.ComputeOptionsMemory=R;class y{constructor(Q,he,Ue,We){this.id=Q,this.name=he,this.defaultValue=Ue,this.schema=We}applyUpdate(Q,he){return I(Q,he)}compute(Q,he,Ue){return Ue}}class m{constructor(Q,he){this.newValue=Q,this.didChange=he}}e.ApplyUpdateResult=m;function I(G,Q){if(typeof G!="object"||typeof Q!="object"||!G||!Q)return new m(Q,G!==Q);if(Array.isArray(G)||Array.isArray(Q)){const Ue=Array.isArray(G)&&Array.isArray(Q)&&L.equals(G,Q);return new m(Q,!Ue)}let he=!1;for(const Ue in Q)if(Q.hasOwnProperty(Ue)){const We=I(G[Ue],Q[Ue]);We.didChange&&(G[Ue]=We.newValue,he=!0)}return new m(G,he)}class f{constructor(Q){this.schema=void 0,this.id=Q,this.name="_never_",this.defaultValue=void 0}applyUpdate(Q,he){return I(Q,he)}validate(Q){return this.defaultValue}}class h{constructor(Q,he,Ue,We){this.id=Q,this.name=he,this.defaultValue=Ue,this.schema=We}applyUpdate(Q,he){return I(Q,he)}validate(Q){return typeof Q=="undefined"?this.defaultValue:Q}compute(Q,he,Ue){return Ue}}function d(G,Q){return typeof G=="undefined"?Q:G==="false"?!1:Boolean(G)}e.boolean=d;class a extends h{constructor(Q,he,Ue,We=void 0){typeof We!="undefined"&&(We.type="boolean",We.default=Ue);super(Q,he,Ue,We)}validate(Q){return d(Q,this.defaultValue)}}function w(G,Q,he,Ue){if(typeof G=="undefined")return Q;let We=parseInt(G,10);return isNaN(We)?Q:(We=Math.max(he,We),We=Math.min(Ue,We),We|0)}e.clampedInt=w;class P extends h{constructor(Q,he,Ue,We,et,je=void 0){typeof je!="undefined"&&(je.type="integer",je.default=Ue,je.minimum=We,je.maximum=et);super(Q,he,Ue,je);this.minimum=We,this.maximum=et}static clampedInt(Q,he,Ue,We){return w(Q,he,Ue,We)}validate(Q){return P.clampedInt(Q,this.defaultValue,this.minimum,this.maximum)}}class l extends h{constructor(Q,he,Ue,We,et){typeof et!="undefined"&&(et.type="number",et.default=Ue);super(Q,he,Ue,et);this.validationFn=We}static clamp(Q,he,Ue){return Q<he?he:Q>Ue?Ue:Q}static float(Q,he){if(typeof Q=="number")return Q;if(typeof Q=="undefined")return he;const Ue=parseFloat(Q);return isNaN(Ue)?he:Ue}validate(Q){return this.validationFn(l.float(Q,this.defaultValue))}}class _ extends h{static string(Q,he){return typeof Q!="string"?he:Q}constructor(Q,he,Ue,We=void 0){typeof We!="undefined"&&(We.type="string",We.default=Ue);super(Q,he,Ue,We)}validate(Q){return _.string(Q,this.defaultValue)}}function n(G,Q,he){return typeof G!="string"||he.indexOf(G)===-1?Q:G}e.stringSet=n;class u extends h{constructor(Q,he,Ue,We,et=void 0){typeof et!="undefined"&&(et.type="string",et.enum=We,et.default=Ue);super(Q,he,Ue,et);this._allowedValues=We}validate(Q){return n(Q,this.defaultValue,this._allowedValues)}}class i extends y{constructor(Q,he,Ue,We,et,je,He=void 0){typeof He!="undefined"&&(He.type="string",He.enum=et,He.default=We);super(Q,he,Ue,He);this._allowedValues=et,this._convert=je}validate(Q){return typeof Q!="string"?this.defaultValue:this._allowedValues.indexOf(Q)===-1?this.defaultValue:this._convert(Q)}}function o(G){switch(G){case"none":return 0;case"keep":return 1;case"brackets":return 2;case"advanced":return 3;case"full":return 4}}class r extends y{constructor(){super(2,"accessibilitySupport",0,{type:"string",enum:["auto","on","off"],enumDescriptions:[s.localize(0,null),s.localize(1,null),s.localize(2,null)],default:"auto",description:s.localize(3,null)})}validate(Q){switch(Q){case"auto":return 0;case"off":return 1;case"on":return 2}return this.defaultValue}compute(Q,he,Ue){return Ue===0?Q.accessibilitySupport:Ue}}class t extends y{constructor(){const Q={insertSpace:!0,ignoreEmptyLines:!0};super(19,"comments",Q,{"editor.comments.insertSpace":{type:"boolean",default:Q.insertSpace,description:s.localize(4,null)},"editor.comments.ignoreEmptyLines":{type:"boolean",default:Q.ignoreEmptyLines,description:s.localize(5,null)}})}validate(Q){if(!Q||typeof Q!="object")return this.defaultValue;const he=Q;return{insertSpace:d(he.insertSpace,this.defaultValue.insertSpace),ignoreEmptyLines:d(he.ignoreEmptyLines,this.defaultValue.ignoreEmptyLines)}}}var c;(function(G){G[G.Hidden=0]="Hidden",G[G.Blink=1]="Blink",G[G.Smooth=2]="Smooth",G[G.Phase=3]="Phase",G[G.Expand=4]="Expand",G[G.Solid=5]="Solid"})(c=e.TextEditorCursorBlinkingStyle||(e.TextEditorCursorBlinkingStyle={}));function v(G){switch(G){case"blink":return 1;case"smooth":return 2;case"phase":return 3;case"expand":return 4;case"solid":return 5}}var g;(function(G){G[G.Line=1]="Line",G[G.Block=2]="Block",G[G.Underline=3]="Underline",G[G.LineThin=4]="LineThin",G[G.BlockOutline=5]="BlockOutline",G[G.UnderlineThin=6]="UnderlineThin"})(g=e.TextEditorCursorStyle||(e.TextEditorCursorStyle={}));function D(G){switch(G){case g.Line:return"line";case g.Block:return"block";case g.Underline:return"underline";case g.LineThin:return"line-thin";case g.BlockOutline:return"block-outline";case g.UnderlineThin:return"underline-thin"}}e.cursorStyleToString=D;function U(G){switch(G){case"line":return g.Line;case"block":return g.Block;case"underline":return g.Underline;case"line-thin":return g.LineThin;case"block-outline":return g.BlockOutline;case"underline-thin":return g.UnderlineThin}}class W extends f{constructor(){super(130)}compute(Q,he,Ue){const We=["monaco-editor"];return he.get(35)&&We.push(he.get(35)),Q.extraEditorClassName&&We.push(Q.extraEditorClassName),he.get(68)==="default"?We.push("mouse-default"):he.get(68)==="copy"&&We.push("mouse-copy"),he.get(102)&&We.push("showUnused"),he.get(128)&&We.push("showDeprecated"),We.join(" ")}}class M extends a{constructor(){super(33,"emptySelectionClipboard",!0,{description:s.localize(6,null)})}compute(Q,he,Ue){return Ue&&Q.emptySelectionClipboard}}class S extends y{constructor(){const Q={cursorMoveOnType:!0,seedSearchStringFromSelection:"always",autoFindInSelection:"never",globalFindClipboard:!1,addExtraSpaceOnTop:!0,loop:!0};super(37,"find",Q,{"editor.find.cursorMoveOnType":{type:"boolean",default:Q.cursorMoveOnType,description:s.localize(7,null)},"editor.find.seedSearchStringFromSelection":{type:"string",enum:["never","always","selection"],default:Q.seedSearchStringFromSelection,enumDescriptions:[s.localize(8,null),s.localize(9,null),s.localize(10,null)],description:s.localize(11,null)},"editor.find.autoFindInSelection":{type:"string",enum:["never","always","multiline"],default:Q.autoFindInSelection,enumDescriptions:[s.localize(12,null),s.localize(13,null),s.localize(14,null)],description:s.localize(15,null)},"editor.find.globalFindClipboard":{type:"boolean",default:Q.globalFindClipboard,description:s.localize(16,null),included:p.isMacintosh},"editor.find.addExtraSpaceOnTop":{type:"boolean",default:Q.addExtraSpaceOnTop,description:s.localize(17,null)},"editor.find.loop":{type:"boolean",default:Q.loop,description:s.localize(18,null)}})}validate(Q){if(!Q||typeof Q!="object")return this.defaultValue;const he=Q;return{cursorMoveOnType:d(he.cursorMoveOnType,this.defaultValue.cursorMoveOnType),seedSearchStringFromSelection:typeof Q.seedSearchStringFromSelection=="boolean"?Q.seedSearchStringFromSelection?"always":"never":n(he.seedSearchStringFromSelection,this.defaultValue.seedSearchStringFromSelection,["never","always","selection"]),autoFindInSelection:typeof Q.autoFindInSelection=="boolean"?Q.autoFindInSelection?"always":"never":n(he.autoFindInSelection,this.defaultValue.autoFindInSelection,["never","always","multiline"]),globalFindClipboard:d(he.globalFindClipboard,this.defaultValue.globalFindClipboard),addExtraSpaceOnTop:d(he.addExtraSpaceOnTop,this.defaultValue.addExtraSpaceOnTop),loop:d(he.loop,this.defaultValue.loop)}}}class z extends y{constructor(){super(47,"fontLigatures",z.OFF,{anyOf:[{type:"boolean",description:s.localize(19,null)},{type:"string",description:s.localize(20,null)}],description:s.localize(21,null),default:!1})}validate(Q){return typeof Q=="undefined"?this.defaultValue:typeof Q=="string"?Q==="false"?z.OFF:Q==="true"?z.ON:Q:Boolean(Q)?z.ON:z.OFF}}e.EditorFontLigatures=z,z.OFF='"liga" off, "calt" off',z.ON='"liga" on, "calt" on';class $ extends f{constructor(){super(46)}compute(Q,he,Ue){return Q.fontInfo}}class N extends h{constructor(){super(48,"fontSize",e.EDITOR_FONT_DEFAULTS.fontSize,{type:"number",minimum:6,maximum:100,default:e.EDITOR_FONT_DEFAULTS.fontSize,description:s.localize(22,null)})}validate(Q){const he=l.float(Q,this.defaultValue);return he===0?e.EDITOR_FONT_DEFAULTS.fontSize:l.clamp(he,6,100)}compute(Q,he,Ue){return Q.fontInfo.fontSize}}class K extends y{constructor(){super(49,"fontWeight",e.EDITOR_FONT_DEFAULTS.fontWeight,{anyOf:[{type:"number",minimum:K.MINIMUM_VALUE,maximum:K.MAXIMUM_VALUE,errorMessage:s.localize(23,null)},{type:"string",pattern:"^(normal|bold|1000|[1-9][0-9]{0,2})$"},{enum:K.SUGGESTION_VALUES}],default:e.EDITOR_FONT_DEFAULTS.fontWeight,description:s.localize(24,null)})}validate(Q){return Q==="normal"||Q==="bold"?Q:String(P.clampedInt(Q,e.EDITOR_FONT_DEFAULTS.fontWeight,K.MINIMUM_VALUE,K.MAXIMUM_VALUE))}}K.SUGGESTION_VALUES=["normal","bold","100","200","300","400","500","600","700","800","900"],K.MINIMUM_VALUE=1,K.MAXIMUM_VALUE=1e3;class V extends y{constructor(){const Q={multiple:"peek",multipleDefinitions:"peek",multipleTypeDefinitions:"peek",multipleDeclarations:"peek",multipleImplementations:"peek",multipleReferences:"peek",alternativeDefinitionCommand:"editor.action.goToReferences",alternativeTypeDefinitionCommand:"editor.action.goToReferences",alternativeDeclarationCommand:"editor.action.goToReferences",alternativeImplementationCommand:"",alternativeReferenceCommand:""},he={type:"string",enum:["peek","gotoAndPeek","goto"],default:Q.multiple,enumDescriptions:[s.localize(25,null),s.localize(26,null),s.localize(27,null)]},Ue=["","editor.action.referenceSearch.trigger","editor.action.goToReferences","editor.action.peekImplementation","editor.action.goToImplementation","editor.action.peekTypeDefinition","editor.action.goToTypeDefinition","editor.action.peekDeclaration","editor.action.revealDeclaration","editor.action.peekDefinition","editor.action.revealDefinitionAside","editor.action.revealDefinition"];super(53,"gotoLocation",Q,{"editor.gotoLocation.multiple":{deprecationMessage:s.localize(28,null)},"editor.gotoLocation.multipleDefinitions":{description:s.localize(29,null),...he},"editor.gotoLocation.multipleTypeDefinitions":{description:s.localize(30,null),...he},"editor.gotoLocation.multipleDeclarations":{description:s.localize(31,null),...he},"editor.gotoLocation.multipleImplementations":{description:s.localize(32,null),...he},"editor.gotoLocation.multipleReferences":{description:s.localize(33,null),...he},"editor.gotoLocation.alternativeDefinitionCommand":{type:"string",default:Q.alternativeDefinitionCommand,enum:Ue,description:s.localize(34,null)},"editor.gotoLocation.alternativeTypeDefinitionCommand":{type:"string",default:Q.alternativeTypeDefinitionCommand,enum:Ue,description:s.localize(35,null)},"editor.gotoLocation.alternativeDeclarationCommand":{type:"string",default:Q.alternativeDeclarationCommand,enum:Ue,description:s.localize(36,null)},"editor.gotoLocation.alternativeImplementationCommand":{type:"string",default:Q.alternativeImplementationCommand,enum:Ue,description:s.localize(37,null)},"editor.gotoLocation.alternativeReferenceCommand":{type:"string",default:Q.alternativeReferenceCommand,enum:Ue,description:s.localize(38,null)}})}validate(Q){if(!Q||typeof Q!="object")return this.defaultValue;const he=Q;return{multiple:n(he.multiple,this.defaultValue.multiple,["peek","gotoAndPeek","goto"]),multipleDefinitions:he.multipleDefinitions??n(he.multipleDefinitions,"peek",["peek","gotoAndPeek","goto"]),multipleTypeDefinitions:he.multipleTypeDefinitions??n(he.multipleTypeDefinitions,"peek",["peek","gotoAndPeek","goto"]),multipleDeclarations:he.multipleDeclarations??n(he.multipleDeclarations,"peek",["peek","gotoAndPeek","goto"]),multipleImplementations:he.multipleImplementations??n(he.multipleImplementations,"peek",["peek","gotoAndPeek","goto"]),multipleReferences:he.multipleReferences??n(he.multipleReferences,"peek",["peek","gotoAndPeek","goto"]),alternativeDefinitionCommand:_.string(he.alternativeDefinitionCommand,this.defaultValue.alternativeDefinitionCommand),alternativeTypeDefinitionCommand:_.string(he.alternativeTypeDefinitionCommand,this.defaultValue.alternativeTypeDefinitionCommand),alternativeDeclarationCommand:_.string(he.alternativeDeclarationCommand,this.defaultValue.alternativeDeclarationCommand),alternativeImplementationCommand:_.string(he.alternativeImplementationCommand,this.defaultValue.alternativeImplementationCommand),alternativeReferenceCommand:_.string(he.alternativeReferenceCommand,this.defaultValue.alternativeReferenceCommand)}}}class F extends y{constructor(){const Q={enabled:!0,delay:300,sticky:!0,above:!0};super(55,"hover",Q,{"editor.hover.enabled":{type:"boolean",default:Q.enabled,description:s.localize(39,null)},"editor.hover.delay":{type:"number",default:Q.delay,minimum:0,maximum:1e4,description:s.localize(40,null)},"editor.hover.sticky":{type:"boolean",default:Q.sticky,description:s.localize(41,null)},"editor.hover.above":{type:"boolean",default:Q.above,description:s.localize(42,null)}})}validate(Q){if(!Q||typeof Q!="object")return this.defaultValue;const he=Q;return{enabled:d(he.enabled,this.defaultValue.enabled),delay:P.clampedInt(he.delay,this.defaultValue.delay,0,1e4),sticky:d(he.sticky,this.defaultValue.sticky),above:d(he.above,this.defaultValue.above)}}}var ne;(function(G){G[G.None=0]="None",G[G.Text=1]="Text",G[G.Blocks=2]="Blocks"})(ne=e.RenderMinimap||(e.RenderMinimap={}));class ce extends f{constructor(){super(133)}compute(Q,he,Ue){return ce.computeLayout(he,{memory:Q.memory,outerWidth:Q.outerWidth,outerHeight:Q.outerHeight,isDominatedByLongLines:Q.isDominatedByLongLines,lineHeight:Q.fontInfo.lineHeight,viewLineCount:Q.viewLineCount,lineNumbersDigitCount:Q.lineNumbersDigitCount,typicalHalfwidthCharacterWidth:Q.fontInfo.typicalHalfwidthCharacterWidth,maxDigitWidth:Q.fontInfo.maxDigitWidth,pixelRatio:Q.pixelRatio})}static computeContainedMinimapLineCount(Q){const he=Q.height/Q.lineHeight,Ue=Q.scrollBeyondLastLine?he-1:0,We=(Q.viewLineCount+Ue)/(Q.pixelRatio*Q.height),et=Math.floor(Q.viewLineCount/We);return{typicalViewportLineCount:he,extraLinesBeyondLastLine:Ue,desiredRatio:We,minimapLineCount:et}}static _computeMinimapLayout(Q,he){const Ue=Q.outerWidth,We=Q.outerHeight,et=Q.pixelRatio;if(!Q.minimap.enabled)return{renderMinimap:0,minimapLeft:0,minimapWidth:0,minimapHeightIsEditorHeight:!1,minimapIsSampling:!1,minimapScale:1,minimapLineHeight:1,minimapCanvasInnerWidth:0,minimapCanvasInnerHeight:Math.floor(et*We),minimapCanvasOuterWidth:0,minimapCanvasOuterHeight:We};const je=he.stableMinimapLayoutInput,He=je&&Q.outerHeight===je.outerHeight&&Q.lineHeight===je.lineHeight&&Q.typicalHalfwidthCharacterWidth===je.typicalHalfwidthCharacterWidth&&Q.pixelRatio===je.pixelRatio&&Q.scrollBeyondLastLine===je.scrollBeyondLastLine&&Q.minimap.enabled===je.minimap.enabled&&Q.minimap.side===je.minimap.side&&Q.minimap.size===je.minimap.size&&Q.minimap.showSlider===je.minimap.showSlider&&Q.minimap.renderCharacters===je.minimap.renderCharacters&&Q.minimap.maxColumn===je.minimap.maxColumn&&Q.minimap.scale===je.minimap.scale&&Q.verticalScrollbarWidth===je.verticalScrollbarWidth&&Q.isViewportWrapping===je.isViewportWrapping,it=Q.lineHeight,rt=Q.typicalHalfwidthCharacterWidth,dt=Q.scrollBeyondLastLine,lt=Q.minimap.renderCharacters;let st=et>=2?Math.round(Q.minimap.scale*2):Q.minimap.scale;const yt=Q.minimap.maxColumn,Ot=Q.minimap.size,Ft=Q.minimap.side,ft=Q.verticalScrollbarWidth,Dt=Q.viewLineCount,Ut=Q.remainingWidth,Nt=Q.isViewportWrapping,Ve=lt?2:3;let Mt=Math.floor(et*We);const At=Mt/et;let Lt=!1,gt=!1,It=Ve*st,we=st/et,De=1;if(Ot==="fill"||Ot==="fit"){const{typicalViewportLineCount:Ge,extraLinesBeyondLastLine:pt,desiredRatio:bt,minimapLineCount:kt}=ce.computeContainedMinimapLineCount({viewLineCount:Dt,scrollBeyondLastLine:dt,height:We,lineHeight:it,pixelRatio:et});if(Dt/kt>1)Lt=!0,gt=!0,st=1,It=1,we=st/et;else{let ht=!1,Rt=st+1;if(Ot==="fit"){const _t=Math.ceil((Dt+pt)*It);Nt&&He&&Ut<=he.stableFitRemainingWidth?(ht=!0,Rt=he.stableFitMaxMinimapScale):ht=_t>Mt}if(Ot==="fill"||ht){Lt=!0;const _t=st;It=Math.min(it*et,Math.max(1,Math.floor(1/bt))),Nt&&He&&Ut<=he.stableFitRemainingWidth&&(Rt=he.stableFitMaxMinimapScale),st=Math.min(Rt,Math.max(1,Math.floor(It/Ve))),st>_t&&(De=Math.min(2,st/_t)),we=st/et/De,Mt=Math.ceil(Math.max(Ge,Dt+pt)*It),Nt?(he.stableMinimapLayoutInput=Q,he.stableFitRemainingWidth=Ut,he.stableFitMaxMinimapScale=st):(he.stableMinimapLayoutInput=null,he.stableFitRemainingWidth=0)}}}const me=Math.floor(yt*we),q=Math.min(me,Math.max(0,Math.floor((Ut-ft-2)*we/(rt+we)))+e.MINIMAP_GUTTER_WIDTH);let Pe=Math.floor(et*q);const Le=Pe/et;Pe=Math.floor(Pe*De);const Xe=lt?1:2,Qe=Ft==="left"?0:Ue-q-ft;return{renderMinimap:Xe,minimapLeft:Qe,minimapWidth:q,minimapHeightIsEditorHeight:Lt,minimapIsSampling:gt,minimapScale:st,minimapLineHeight:It,minimapCanvasInnerWidth:Pe,minimapCanvasInnerHeight:Mt,minimapCanvasOuterWidth:Le,minimapCanvasOuterHeight:At}}static computeLayout(Q,he){const Ue=he.outerWidth|0,We=he.outerHeight|0,et=he.lineHeight|0,je=he.lineNumbersDigitCount|0,He=he.typicalHalfwidthCharacterWidth,it=he.maxDigitWidth,rt=he.pixelRatio,dt=he.viewLineCount,lt=Q.get(125),st=lt==="inherit"?Q.get(124):lt,yt=st==="inherit"?Q.get(120):st,Ot=Q.get(123),Ft=Q.get(2),ft=he.isDominatedByLongLines,Dt=Q.get(52),Ut=Q.get(62).renderType!==0,Nt=Q.get(63),Ve=Q.get(96),Mt=Q.get(67),At=Q.get(94),Lt=At.verticalScrollbarSize,gt=At.verticalHasArrows,It=At.arrowSize,we=At.horizontalScrollbarSize,De=Q.get(60),me=Q.get(39),q=Q.get(101)!=="never";let Pe;if(typeof De=="string"&&/^\d+(\.\d+)?ch$/.test(De)){const Ht=parseFloat(De.substr(0,De.length-2));Pe=P.clampedInt(Ht*He,0,0,1e3)}else Pe=P.clampedInt(De,0,0,1e3);me&&q&&(Pe+=16);let Le=0;if(Ut){const Ht=Math.max(je,Nt);Le=Math.round(Ht*it)}let Xe=0;Dt&&(Xe=et);let Qe=0,Ge=Qe+Xe,pt=Ge+Le,bt=pt+Pe;const kt=Ue-Xe-Le-Pe;let Et=!1,ht=!1,Rt=-1;Ft!==2&&(st==="inherit"&&ft?(Et=!0,ht=!0):yt==="on"||yt==="bounded"?ht=!0:yt==="wordWrapColumn"&&(Rt=Ot));const _t=ce._computeMinimapLayout({outerWidth:Ue,outerHeight:We,lineHeight:et,typicalHalfwidthCharacterWidth:He,pixelRatio:rt,scrollBeyondLastLine:Ve,minimap:Mt,verticalScrollbarWidth:Lt,viewLineCount:dt,remainingWidth:kt,isViewportWrapping:ht},he.memory||new R);_t.renderMinimap!==0&&_t.minimapLeft===0&&(Qe+=_t.minimapWidth,Ge+=_t.minimapWidth,pt+=_t.minimapWidth,bt+=_t.minimapWidth);const vt=kt-_t.minimapWidth,Gt=Math.max(1,Math.floor((vt-Lt-2)/He)),Xt=gt?It:0;return ht&&(Rt=Math.max(1,Gt),yt==="bounded"&&(Rt=Math.min(Rt,Ot))),{width:Ue,height:We,glyphMarginLeft:Qe,glyphMarginWidth:Xe,lineNumbersLeft:Ge,lineNumbersWidth:Le,decorationsLeft:pt,decorationsWidth:Pe,contentLeft:bt,contentWidth:vt,minimap:_t,viewportColumn:Gt,isWordWrapMinified:Et,isViewportWrapping:ht,wrappingColumn:Rt,verticalScrollbarWidth:Lt,horizontalScrollbarHeight:we,overviewRuler:{top:Xt,width:Lt,height:We-2*Xt,right:0}}}}e.EditorLayoutInfoComputer=ce;class re extends y{constructor(){const Q={enabled:!0};super(59,"lightbulb",Q,{"editor.lightbulb.enabled":{type:"boolean",default:Q.enabled,description:s.localize(43,null)}})}validate(Q){return!Q||typeof Q!="object"?this.defaultValue:{enabled:d(Q.enabled,this.defaultValue.enabled)}}}class fe extends y{constructor(){const Q={stickyScroll:{enabled:!1}};super(34,"experimental",Q,{"editor.experimental.stickyScroll.enabled":{type:"boolean",default:Q.stickyScroll.enabled,description:s.localize(44,null)}})}validate(Q){return!Q||typeof Q!="object"?this.defaultValue:{stickyScroll:{enabled:d(Q.stickyScroll?.enabled,this.defaultValue.stickyScroll.enabled)}}}}class ie extends y{constructor(){const Q={enabled:"on",fontSize:0,fontFamily:"",padding:!1};super(129,"inlayHints",Q,{"editor.inlayHints.enabled":{type:"string",default:Q.enabled,description:s.localize(45,null),enum:["on","onUnlessPressed","offUnlessPressed","off"],markdownEnumDescriptions:[s.localize(46,null),s.localize(47,null),s.localize(48,null),s.localize(49,null)]},"editor.inlayHints.fontSize":{type:"number",default:Q.fontSize,markdownDescription:s.localize(50,null,"`#editor.fontSize#`","`5`")},"editor.inlayHints.fontFamily":{type:"string",default:Q.fontFamily,markdownDescription:s.localize(51,null,"`#editor.fontFamily#`")},"editor.inlayHints.padding":{type:"boolean",default:Q.padding,description:s.localize(52,null)}})}validate(Q){if(!Q||typeof Q!="object")return this.defaultValue;const he=Q;return typeof he.enabled=="boolean"&&(he.enabled=he.enabled?"on":"off"),{enabled:n(he.enabled,this.defaultValue.enabled,["on","off","offUnlessPressed","onUnlessPressed"]),fontSize:P.clampedInt(he.fontSize,this.defaultValue.fontSize,0,100),fontFamily:_.string(he.fontFamily,this.defaultValue.fontFamily),padding:d(he.padding,this.defaultValue.padding)}}}class Ee extends l{constructor(){super(61,"lineHeight",e.EDITOR_FONT_DEFAULTS.lineHeight,Q=>l.clamp(Q,0,150),{markdownDescription:s.localize(53,null)})}compute(Q,he,Ue){return Q.fontInfo.lineHeight}}class be extends y{constructor(){const Q={enabled:!0,size:"proportional",side:"right",showSlider:"mouseover",autohide:!1,renderCharacters:!0,maxColumn:120,scale:1};super(67,"minimap",Q,{"editor.minimap.enabled":{type:"boolean",default:Q.enabled,description:s.localize(54,null)},"editor.minimap.autohide":{type:"boolean",default:Q.autohide,description:s.localize(55,null)},"editor.minimap.size":{type:"string",enum:["proportional","fill","fit"],enumDescriptions:[s.localize(56,null),s.localize(57,null),s.localize(58,null)],default:Q.size,description:s.localize(59,null)},"editor.minimap.side":{type:"string",enum:["left","right"],default:Q.side,description:s.localize(60,null)},"editor.minimap.showSlider":{type:"string",enum:["always","mouseover"],default:Q.showSlider,description:s.localize(61,null)},"editor.minimap.scale":{type:"number",default:Q.scale,minimum:1,maximum:3,enum:[1,2,3],description:s.localize(62,null)},"editor.minimap.renderCharacters":{type:"boolean",default:Q.renderCharacters,description:s.localize(63,null)},"editor.minimap.maxColumn":{type:"number",default:Q.maxColumn,description:s.localize(64,null)}})}validate(Q){if(!Q||typeof Q!="object")return this.defaultValue;const he=Q;return{enabled:d(he.enabled,this.defaultValue.enabled),autohide:d(he.autohide,this.defaultValue.autohide),size:n(he.size,this.defaultValue.size,["proportional","fill","fit"]),side:n(he.side,this.defaultValue.side,["right","left"]),showSlider:n(he.showSlider,this.defaultValue.showSlider,["always","mouseover"]),renderCharacters:d(he.renderCharacters,this.defaultValue.renderCharacters),scale:P.clampedInt(he.scale,1,1,3),maxColumn:P.clampedInt(he.maxColumn,this.defaultValue.maxColumn,1,1e4)}}}function te(G){return G==="ctrlCmd"?p.isMacintosh?"metaKey":"ctrlKey":"altKey"}class ve extends y{constructor(){super(77,"padding",{top:0,bottom:0},{"editor.padding.top":{type:"number",default:0,minimum:0,maximum:1e3,description:s.localize(65,null)},"editor.padding.bottom":{type:"number",default:0,minimum:0,maximum:1e3,description:s.localize(66,null)}})}validate(Q){if(!Q||typeof Q!="object")return this.defaultValue;const he=Q;return{top:P.clampedInt(he.top,0,0,1e3),bottom:P.clampedInt(he.bottom,0,0,1e3)}}}class Re extends y{constructor(){const Q={enabled:!0,cycle:!1};super(78,"parameterHints",Q,{"editor.parameterHints.enabled":{type:"boolean",default:Q.enabled,description:s.localize(67,null)},"editor.parameterHints.cycle":{type:"boolean",default:Q.cycle,description:s.localize(68,null)}})}validate(Q){if(!Q||typeof Q!="object")return this.defaultValue;const he=Q;return{enabled:d(he.enabled,this.defaultValue.enabled),cycle:d(he.cycle,this.defaultValue.cycle)}}}class Fe extends f{constructor(){super(131)}compute(Q,he,Ue){return Q.pixelRatio}}class $e extends y{constructor(){const Q={other:"on",comments:"off",strings:"off"},he=[{type:"boolean"},{type:"string",enum:["on","inline","off"],enumDescriptions:[s.localize(69,null),s.localize(70,null),s.localize(71,null)]}];super(81,"quickSuggestions",Q,{type:"object",additionalProperties:!1,properties:{strings:{anyOf:he,default:Q.strings,description:s.localize(72,null)},comments:{anyOf:he,default:Q.comments,description:s.localize(73,null)},other:{anyOf:he,default:Q.other,description:s.localize(74,null)}},default:Q,markdownDescription:s.localize(75,null,"#editor.suggestOnTriggerCharacters#")});this.defaultValue=Q}validate(Q){if(typeof Q=="boolean"){const rt=Q?"on":"off";return{comments:rt,strings:rt,other:rt}}if(!Q||typeof Q!="object")return this.defaultValue;const{other:he,comments:Ue,strings:We}=Q,et=["on","inline","off"];let je,He,it;return typeof he=="boolean"?je=he?"on":"off":je=n(he,this.defaultValue.other,et),typeof Ue=="boolean"?He=Ue?"on":"off":He=n(Ue,this.defaultValue.comments,et),typeof We=="boolean"?it=We?"on":"off":it=n(We,this.defaultValue.strings,et),{other:je,comments:He,strings:it}}}var Ye;(function(G){G[G.Off=0]="Off",G[G.On=1]="On",G[G.Relative=2]="Relative",G[G.Interval=3]="Interval",G[G.Custom=4]="Custom"})(Ye=e.RenderLineNumbersType||(e.RenderLineNumbersType={}));class Ie extends y{constructor(){super(62,"lineNumbers",{renderType:1,renderFn:null},{type:"string",enum:["off","on","relative","interval"],enumDescriptions:[s.localize(76,null),s.localize(77,null),s.localize(78,null),s.localize(79,null)],default:"on",description:s.localize(80,null)})}validate(Q){let he=this.defaultValue.renderType,Ue=this.defaultValue.renderFn;return typeof Q!="undefined"&&(typeof Q=="function"?(he=4,Ue=Q):Q==="interval"?he=3:Q==="relative"?he=2:Q==="on"?he=1:he=0),{renderType:he,renderFn:Ue}}}function Se(G){const Q=G.get(89);return Q==="editable"?G.get(83):Q!=="on"}e.filterValidationDecorations=Se;class Te extends y{constructor(){const Q=[],he={type:"number",description:s.localize(81,null)};super(93,"rulers",Q,{type:"array",items:{anyOf:[he,{type:["object"],properties:{column:he,color:{type:"string",description:s.localize(82,null),format:"color-hex"}}}]},default:Q,description:s.localize(83,null)})}validate(Q){if(Array.isArray(Q)){const he=[];for(const Ue of Q)if(typeof Ue=="number")he.push({column:P.clampedInt(Ue,0,0,1e4),color:null});else if(Ue&&typeof Ue=="object"){const We=Ue;he.push({column:P.clampedInt(We.column,0,0,1e4),color:We.color})}return he.sort((Ue,We)=>Ue.column-We.column),he}return this.defaultValue}}function ae(G,Q){if(typeof G!="string")return Q;switch(G){case"hidden":return 2;case"visible":return 3;default:return 1}}class le extends y{constructor(){const Q={vertical:1,horizontal:1,arrowSize:11,useShadows:!0,verticalHasArrows:!1,horizontalHasArrows:!1,horizontalScrollbarSize:12,horizontalSliderSize:12,verticalScrollbarSize:14,verticalSliderSize:14,handleMouseWheel:!0,alwaysConsumeMouseWheel:!0,scrollByPage:!1};super(94,"scrollbar",Q,{"editor.scrollbar.vertical":{type:"string",enum:["auto","visible","hidden"],enumDescriptions:[s.localize(84,null),s.localize(85,null),s.localize(86,null)],default:"auto",description:s.localize(87,null)},"editor.scrollbar.horizontal":{type:"string",enum:["auto","visible","hidden"],enumDescriptions:[s.localize(88,null),s.localize(89,null),s.localize(90,null)],default:"auto",description:s.localize(91,null)},"editor.scrollbar.verticalScrollbarSize":{type:"number",default:Q.verticalScrollbarSize,description:s.localize(92,null)},"editor.scrollbar.horizontalScrollbarSize":{type:"number",default:Q.horizontalScrollbarSize,description:s.localize(93,null)},"editor.scrollbar.scrollByPage":{type:"boolean",default:Q.scrollByPage,description:s.localize(94,null)}})}validate(Q){if(!Q||typeof Q!="object")return this.defaultValue;const he=Q,Ue=P.clampedInt(he.horizontalScrollbarSize,this.defaultValue.horizontalScrollbarSize,0,1e3),We=P.clampedInt(he.verticalScrollbarSize,this.defaultValue.verticalScrollbarSize,0,1e3);return{arrowSize:P.clampedInt(he.arrowSize,this.defaultValue.arrowSize,0,1e3),vertical:ae(he.vertical,this.defaultValue.vertical),horizontal:ae(he.horizontal,this.defaultValue.horizontal),useShadows:d(he.useShadows,this.defaultValue.useShadows),verticalHasArrows:d(he.verticalHasArrows,this.defaultValue.verticalHasArrows),horizontalHasArrows:d(he.horizontalHasArrows,this.defaultValue.horizontalHasArrows),handleMouseWheel:d(he.handleMouseWheel,this.defaultValue.handleMouseWheel),alwaysConsumeMouseWheel:d(he.alwaysConsumeMouseWheel,this.defaultValue.alwaysConsumeMouseWheel),horizontalScrollbarSize:Ue,horizontalSliderSize:P.clampedInt(he.horizontalSliderSize,Ue,0,1e3),verticalScrollbarSize:We,verticalSliderSize:P.clampedInt(he.verticalSliderSize,We,0,1e3),scrollByPage:d(he.scrollByPage,this.defaultValue.scrollByPage)}}}e.inUntrustedWorkspace="inUntrustedWorkspace",e.unicodeHighlightConfigKeys={allowedCharacters:"editor.unicodeHighlight.allowedCharacters",invisibleCharacters:"editor.unicodeHighlight.invisibleCharacters",nonBasicASCII:"editor.unicodeHighlight.nonBasicASCII",ambiguousCharacters:"editor.unicodeHighlight.ambiguousCharacters",includeComments:"editor.unicodeHighlight.includeComments",includeStrings:"editor.unicodeHighlight.includeStrings",allowedLocales:"editor.unicodeHighlight.allowedLocales"};class X extends y{constructor(){const Q={nonBasicASCII:e.inUntrustedWorkspace,invisibleCharacters:!0,ambiguousCharacters:!0,includeComments:e.inUntrustedWorkspace,includeStrings:!0,allowedCharacters:{},allowedLocales:{_os:!0,_vscode:!0}};super(115,"unicodeHighlight",Q,{[e.unicodeHighlightConfigKeys.nonBasicASCII]:{restricted:!0,type:["boolean","string"],enum:[!0,!1,e.inUntrustedWorkspace],default:Q.nonBasicASCII,description:s.localize(95,null)},[e.unicodeHighlightConfigKeys.invisibleCharacters]:{restricted:!0,type:"boolean",default:Q.invisibleCharacters,description:s.localize(96,null)},[e.unicodeHighlightConfigKeys.ambiguousCharacters]:{restricted:!0,type:"boolean",default:Q.ambiguousCharacters,description:s.localize(97,null)},[e.unicodeHighlightConfigKeys.includeComments]:{restricted:!0,type:["boolean","string"],enum:[!0,!1,e.inUntrustedWorkspace],default:Q.includeComments,description:s.localize(98,null)},[e.unicodeHighlightConfigKeys.includeStrings]:{restricted:!0,type:["boolean","string"],enum:[!0,!1,e.inUntrustedWorkspace],default:Q.includeStrings,description:s.localize(99,null)},[e.unicodeHighlightConfigKeys.allowedCharacters]:{restricted:!0,type:"object",default:Q.allowedCharacters,description:s.localize(100,null),additionalProperties:{type:"boolean"}},[e.unicodeHighlightConfigKeys.allowedLocales]:{restricted:!0,type:"object",additionalProperties:{type:"boolean"},default:Q.allowedLocales,description:s.localize(101,null)}})}applyUpdate(Q,he){let Ue=!1;he.allowedCharacters&&Q&&(C.equals(Q.allowedCharacters,he.allowedCharacters)||(Q={...Q,allowedCharacters:he.allowedCharacters},Ue=!0)),he.allowedLocales&&Q&&(C.equals(Q.allowedLocales,he.allowedLocales)||(Q={...Q,allowedLocales:he.allowedLocales},Ue=!0));const We=super.applyUpdate(Q,he);return Ue?new m(We.newValue,!0):We}validate(Q){if(!Q||typeof Q!="object")return this.defaultValue;const he=Q;return{nonBasicASCII:H(he.nonBasicASCII,e.inUntrustedWorkspace,[!0,!1,e.inUntrustedWorkspace]),invisibleCharacters:d(he.invisibleCharacters,this.defaultValue.invisibleCharacters),ambiguousCharacters:d(he.ambiguousCharacters,this.defaultValue.ambiguousCharacters),includeComments:H(he.includeComments,e.inUntrustedWorkspace,[!0,!1,e.inUntrustedWorkspace]),includeStrings:H(he.includeStrings,e.inUntrustedWorkspace,[!0,!1,e.inUntrustedWorkspace]),allowedCharacters:this.validateBooleanMap(Q.allowedCharacters,this.defaultValue.allowedCharacters),allowedLocales:this.validateBooleanMap(Q.allowedLocales,this.defaultValue.allowedLocales)}}validateBooleanMap(Q,he){if(typeof Q!="object"||!Q)return he;const Ue={};for(const[We,et]of Object.entries(Q))et===!0&&(Ue[We]=!0);return Ue}}class J extends y{constructor(){const Q={enabled:!0,mode:"subwordSmart"};super(57,"inlineSuggest",Q,{"editor.inlineSuggest.enabled":{type:"boolean",default:Q.enabled,description:s.localize(102,null)}})}validate(Q){if(!Q||typeof Q!="object")return this.defaultValue;const he=Q;return{enabled:d(he.enabled,this.defaultValue.enabled),mode:n(he.mode,this.defaultValue.mode,["prefix","subword","subwordSmart"])}}}class k extends y{constructor(){const Q={enabled:T.EDITOR_MODEL_DEFAULTS.bracketPairColorizationOptions.enabled,independentColorPoolPerBracketType:T.EDITOR_MODEL_DEFAULTS.bracketPairColorizationOptions.independentColorPoolPerBracketType};super(12,"bracketPairColorization",Q,{"editor.bracketPairColorization.enabled":{type:"boolean",default:Q.enabled,markdownDescription:s.localize(103,null,"`#workbench.colorCustomizations#`")},"editor.bracketPairColorization.independentColorPoolPerBracketType":{type:"boolean",default:Q.independentColorPoolPerBracketType,description:s.localize(104,null)}})}validate(Q){if(!Q||typeof Q!="object")return this.defaultValue;const he=Q;return{enabled:d(he.enabled,this.defaultValue.enabled),independentColorPoolPerBracketType:d(he.independentColorPoolPerBracketType,this.defaultValue.independentColorPoolPerBracketType)}}}class B extends y{constructor(){const Q={bracketPairs:!1,bracketPairsHorizontal:"active",highlightActiveBracketPair:!0,indentation:!0,highlightActiveIndentation:!0};super(13,"guides",Q,{"editor.guides.bracketPairs":{type:["boolean","string"],enum:[!0,"active",!1],enumDescriptions:[s.localize(105,null),s.localize(106,null),s.localize(107,null)],default:Q.bracketPairs,description:s.localize(108,null)},"editor.guides.bracketPairsHorizontal":{type:["boolean","string"],enum:[!0,"active",!1],enumDescriptions:[s.localize(109,null),s.localize(110,null),s.localize(111,null)],default:Q.bracketPairsHorizontal,description:s.localize(112,null)},"editor.guides.highlightActiveBracketPair":{type:"boolean",default:Q.highlightActiveBracketPair,description:s.localize(113,null)},"editor.guides.indentation":{type:"boolean",default:Q.indentation,description:s.localize(114,null)},"editor.guides.highlightActiveIndentation":{type:["boolean","string"],enum:[!0,"always",!1],enumDescriptions:[s.localize(115,null),s.localize(116,null),s.localize(117,null)],default:Q.highlightActiveIndentation,description:s.localize(118,null)}})}validate(Q){if(!Q||typeof Q!="object")return this.defaultValue;const he=Q;return{bracketPairs:H(he.bracketPairs,this.defaultValue.bracketPairs,[!0,!1,"active"]),bracketPairsHorizontal:H(he.bracketPairsHorizontal,this.defaultValue.bracketPairsHorizontal,[!0,!1,"active"]),highlightActiveBracketPair:d(he.highlightActiveBracketPair,this.defaultValue.highlightActiveBracketPair),indentation:d(he.indentation,this.defaultValue.indentation),highlightActiveIndentation:H(he.highlightActiveIndentation,this.defaultValue.highlightActiveIndentation,[!0,!1,"always"])}}}function H(G,Q,he){const Ue=he.indexOf(G);return Ue===-1?Q:he[Ue]}class j extends y{constructor(){const Q={insertMode:"insert",filterGraceful:!0,snippetsPreventQuickSuggestions:!0,localityBonus:!1,shareSuggestSelections:!1,showIcons:!0,showStatusBar:!1,preview:!1,previewMode:"subwordSmart",showInlineDetails:!0,showMethods:!0,showFunctions:!0,showConstructors:!0,showDeprecated:!0,showFields:!0,showVariables:!0,showClasses:!0,showStructs:!0,showInterfaces:!0,showModules:!0,showProperties:!0,showEvents:!0,showOperators:!0,showUnits:!0,showValues:!0,showConstants:!0,showEnums:!0,showEnumMembers:!0,showKeywords:!0,showWords:!0,showColors:!0,showFiles:!0,showReferences:!0,showFolders:!0,showTypeParameters:!0,showSnippets:!0,showUsers:!0,showIssues:!0};super(108,"suggest",Q,{"editor.suggest.insertMode":{type:"string",enum:["insert","replace"],enumDescriptions:[s.localize(119,null),s.localize(120,null)],default:Q.insertMode,description:s.localize(121,null)},"editor.suggest.filterGraceful":{type:"boolean",default:Q.filterGraceful,description:s.localize(122,null)},"editor.suggest.localityBonus":{type:"boolean",default:Q.localityBonus,description:s.localize(123,null)},"editor.suggest.shareSuggestSelections":{type:"boolean",default:Q.shareSuggestSelections,markdownDescription:s.localize(124,null)},"editor.suggest.snippetsPreventQuickSuggestions":{type:"boolean",default:Q.snippetsPreventQuickSuggestions,description:s.localize(125,null)},"editor.suggest.showIcons":{type:"boolean",default:Q.showIcons,description:s.localize(126,null)},"editor.suggest.showStatusBar":{type:"boolean",default:Q.showStatusBar,description:s.localize(127,null)},"editor.suggest.preview":{type:"boolean",default:Q.preview,description:s.localize(128,null)},"editor.suggest.showInlineDetails":{type:"boolean",default:Q.showInlineDetails,description:s.localize(129,null)},"editor.suggest.maxVisibleSuggestions":{type:"number",deprecationMessage:s.localize(130,null)},"editor.suggest.filteredTypes":{type:"object",deprecationMessage:s.localize(131,null)},"editor.suggest.showMethods":{type:"boolean",default:!0,markdownDescription:s.localize(132,null)},"editor.suggest.showFunctions":{type:"boolean",default:!0,markdownDescription:s.localize(133,null)},"editor.suggest.showConstructors":{type:"boolean",default:!0,markdownDescription:s.localize(134,null)},"editor.suggest.showDeprecated":{type:"boolean",default:!0,markdownDescription:s.localize(135,null)},"editor.suggest.showFields":{type:"boolean",default:!0,markdownDescription:s.localize(136,null)},"editor.suggest.showVariables":{type:"boolean",default:!0,markdownDescription:s.localize(137,null)},"editor.suggest.showClasses":{type:"boolean",default:!0,markdownDescription:s.localize(138,null)},"editor.suggest.showStructs":{type:"boolean",default:!0,markdownDescription:s.localize(139,null)},"editor.suggest.showInterfaces":{type:"boolean",default:!0,markdownDescription:s.localize(140,null)},"editor.suggest.showModules":{type:"boolean",default:!0,markdownDescription:s.localize(141,null)},"editor.suggest.showProperties":{type:"boolean",default:!0,markdownDescription:s.localize(142,null)},"editor.suggest.showEvents":{type:"boolean",default:!0,markdownDescription:s.localize(143,null)},"editor.suggest.showOperators":{type:"boolean",default:!0,markdownDescription:s.localize(144,null)},"editor.suggest.showUnits":{type:"boolean",default:!0,markdownDescription:s.localize(145,null)},"editor.suggest.showValues":{type:"boolean",default:!0,markdownDescription:s.localize(146,null)},"editor.suggest.showConstants":{type:"boolean",default:!0,markdownDescription:s.localize(147,null)},"editor.suggest.showEnums":{type:"boolean",default:!0,markdownDescription:s.localize(148,null)},"editor.suggest.showEnumMembers":{type:"boolean",default:!0,markdownDescription:s.localize(149,null)},"editor.suggest.showKeywords":{type:"boolean",default:!0,markdownDescription:s.localize(150,null)},"editor.suggest.showWords":{type:"boolean",default:!0,markdownDescription:s.localize(151,null)},"editor.suggest.showColors":{type:"boolean",default:!0,markdownDescription:s.localize(152,null)},"editor.suggest.showFiles":{type:"boolean",default:!0,markdownDescription:s.localize(153,null)},"editor.suggest.showReferences":{type:"boolean",default:!0,markdownDescription:s.localize(154,null)},"editor.suggest.showCustomcolors":{type:"boolean",default:!0,markdownDescription:s.localize(155,null)},"editor.suggest.showFolders":{type:"boolean",default:!0,markdownDescription:s.localize(156,null)},"editor.suggest.showTypeParameters":{type:"boolean",default:!0,markdownDescription:s.localize(157,null)},"editor.suggest.showSnippets":{type:"boolean",default:!0,markdownDescription:s.localize(158,null)},"editor.suggest.showUsers":{type:"boolean",default:!0,markdownDescription:s.localize(159,null)},"editor.suggest.showIssues":{type:"boolean",default:!0,markdownDescription:s.localize(160,null)}})}validate(Q){if(!Q||typeof Q!="object")return this.defaultValue;const he=Q;return{insertMode:n(he.insertMode,this.defaultValue.insertMode,["insert","replace"]),filterGraceful:d(he.filterGraceful,this.defaultValue.filterGraceful),snippetsPreventQuickSuggestions:d(he.snippetsPreventQuickSuggestions,this.defaultValue.filterGraceful),localityBonus:d(he.localityBonus,this.defaultValue.localityBonus),shareSuggestSelections:d(he.shareSuggestSelections,this.defaultValue.shareSuggestSelections),showIcons:d(he.showIcons,this.defaultValue.showIcons),showStatusBar:d(he.showStatusBar,this.defaultValue.showStatusBar),preview:d(he.preview,this.defaultValue.preview),previewMode:n(he.previewMode,this.defaultValue.previewMode,["prefix","subword","subwordSmart"]),showInlineDetails:d(he.showInlineDetails,this.defaultValue.showInlineDetails),showMethods:d(he.showMethods,this.defaultValue.showMethods),showFunctions:d(he.showFunctions,this.defaultValue.showFunctions),showConstructors:d(he.showConstructors,this.defaultValue.showConstructors),showDeprecated:d(he.showDeprecated,this.defaultValue.showDeprecated),showFields:d(he.showFields,this.defaultValue.showFields),showVariables:d(he.showVariables,this.defaultValue.showVariables),showClasses:d(he.showClasses,this.defaultValue.showClasses),showStructs:d(he.showStructs,this.defaultValue.showStructs),showInterfaces:d(he.showInterfaces,this.defaultValue.showInterfaces),showModules:d(he.showModules,this.defaultValue.showModules),showProperties:d(he.showProperties,this.defaultValue.showProperties),showEvents:d(he.showEvents,this.defaultValue.showEvents),showOperators:d(he.showOperators,this.defaultValue.showOperators),showUnits:d(he.showUnits,this.defaultValue.showUnits),showValues:d(he.showValues,this.defaultValue.showValues),showConstants:d(he.showConstants,this.defaultValue.showConstants),showEnums:d(he.showEnums,this.defaultValue.showEnums),showEnumMembers:d(he.showEnumMembers,this.defaultValue.showEnumMembers),showKeywords:d(he.showKeywords,this.defaultValue.showKeywords),showWords:d(he.showWords,this.defaultValue.showWords),showColors:d(he.showColors,this.defaultValue.showColors),showFiles:d(he.showFiles,this.defaultValue.showFiles),showReferences:d(he.showReferences,this.defaultValue.showReferences),showFolders:d(he.showFolders,this.defaultValue.showFolders),showTypeParameters:d(he.showTypeParameters,this.defaultValue.showTypeParameters),showSnippets:d(he.showSnippets,this.defaultValue.showSnippets),showUsers:d(he.showUsers,this.defaultValue.showUsers),showIssues:d(he.showIssues,this.defaultValue.showIssues)}}}class oe extends y{constructor(){super(104,"smartSelect",{selectLeadingAndTrailingWhitespace:!0},{"editor.smartSelect.selectLeadingAndTrailingWhitespace":{description:s.localize(161,null),default:!0,type:"boolean"}})}validate(Q){return!Q||typeof Q!="object"?this.defaultValue:{selectLeadingAndTrailingWhitespace:d(Q.selectLeadingAndTrailingWhitespace,this.defaultValue.selectLeadingAndTrailingWhitespace)}}}class ue extends f{constructor(){super(132)}compute(Q,he,Ue){return he.get(83)?!0:Q.tabFocusMode}}var Z;(function(G){G[G.None=0]="None",G[G.Same=1]="Same",G[G.Indent=2]="Indent",G[G.DeepIndent=3]="DeepIndent"})(Z=e.WrappingIndent||(e.WrappingIndent={}));function pe(G){switch(G){case"none":return 0;case"same":return 1;case"indent":return 2;case"deepIndent":return 3}}class ge extends f{constructor(){super(134)}compute(Q,he,Ue){const We=he.get(133);return{isDominatedByLongLines:Q.isDominatedByLongLines,isWordWrapMinified:We.isWordWrapMinified,isViewportWrapping:We.isViewportWrapping,wrappingColumn:We.wrappingColumn}}}class Ne extends y{constructor(){const Q={enabled:!0};super(32,"dropIntoEditor",Q,{"editor.dropIntoEditor.enabled":{type:"boolean",default:Q.enabled,markdownDescription:s.localize(162,null)}})}validate(Q){return!Q||typeof Q!="object"?this.defaultValue:{enabled:d(Q.enabled,this.defaultValue.enabled)}}}const Be="Consolas, 'Courier New', monospace",Ze="Menlo, Monaco, 'Courier New', monospace",Ke="'Droid Sans Mono', 'monospace', monospace";e.EDITOR_FONT_DEFAULTS={fontFamily:p.isMacintosh?Ze:p.isLinux?Ke:Be,fontWeight:"normal",fontSize:p.isMacintosh?12:14,lineHeight:0,letterSpacing:0},e.editorOptionsRegistry=[];function ke(G){return e.editorOptionsRegistry[G.id]=G,G}var nt;(function(G){G[G.acceptSuggestionOnCommitCharacter=0]="acceptSuggestionOnCommitCharacter",G[G.acceptSuggestionOnEnter=1]="acceptSuggestionOnEnter",G[G.accessibilitySupport=2]="accessibilitySupport",G[G.accessibilityPageSize=3]="accessibilityPageSize",G[G.ariaLabel=4]="ariaLabel",G[G.autoClosingBrackets=5]="autoClosingBrackets",G[G.autoClosingDelete=6]="autoClosingDelete",G[G.autoClosingOvertype=7]="autoClosingOvertype",G[G.autoClosingQuotes=8]="autoClosingQuotes",G[G.autoIndent=9]="autoIndent",G[G.automaticLayout=10]="automaticLayout",G[G.autoSurround=11]="autoSurround",G[G.bracketPairColorization=12]="bracketPairColorization",G[G.guides=13]="guides",G[G.codeLens=14]="codeLens",G[G.codeLensFontFamily=15]="codeLensFontFamily",G[G.codeLensFontSize=16]="codeLensFontSize",G[G.colorDecorators=17]="colorDecorators",G[G.columnSelection=18]="columnSelection",G[G.comments=19]="comments",G[G.contextmenu=20]="contextmenu",G[G.copyWithSyntaxHighlighting=21]="copyWithSyntaxHighlighting",G[G.cursorBlinking=22]="cursorBlinking",G[G.cursorSmoothCaretAnimation=23]="cursorSmoothCaretAnimation",G[G.cursorStyle=24]="cursorStyle",G[G.cursorSurroundingLines=25]="cursorSurroundingLines",G[G.cursorSurroundingLinesStyle=26]="cursorSurroundingLinesStyle",G[G.cursorWidth=27]="cursorWidth",G[G.disableLayerHinting=28]="disableLayerHinting",G[G.disableMonospaceOptimizations=29]="disableMonospaceOptimizations",G[G.domReadOnly=30]="domReadOnly",G[G.dragAndDrop=31]="dragAndDrop",G[G.dropIntoEditor=32]="dropIntoEditor",G[G.emptySelectionClipboard=33]="emptySelectionClipboard",G[G.experimental=34]="experimental",G[G.extraEditorClassName=35]="extraEditorClassName",G[G.fastScrollSensitivity=36]="fastScrollSensitivity",G[G.find=37]="find",G[G.fixedOverflowWidgets=38]="fixedOverflowWidgets",G[G.folding=39]="folding",G[G.foldingStrategy=40]="foldingStrategy",G[G.foldingHighlight=41]="foldingHighlight",G[G.foldingImportsByDefault=42]="foldingImportsByDefault",G[G.foldingMaximumRegions=43]="foldingMaximumRegions",G[G.unfoldOnClickAfterEndOfLine=44]="unfoldOnClickAfterEndOfLine",G[G.fontFamily=45]="fontFamily",G[G.fontInfo=46]="fontInfo",G[G.fontLigatures=47]="fontLigatures",G[G.fontSize=48]="fontSize",G[G.fontWeight=49]="fontWeight",G[G.formatOnPaste=50]="formatOnPaste",G[G.formatOnType=51]="formatOnType",G[G.glyphMargin=52]="glyphMargin",G[G.gotoLocation=53]="gotoLocation",G[G.hideCursorInOverviewRuler=54]="hideCursorInOverviewRuler",G[G.hover=55]="hover",G[G.inDiffEditor=56]="inDiffEditor",G[G.inlineSuggest=57]="inlineSuggest",G[G.letterSpacing=58]="letterSpacing",G[G.lightbulb=59]="lightbulb",G[G.lineDecorationsWidth=60]="lineDecorationsWidth",G[G.lineHeight=61]="lineHeight",G[G.lineNumbers=62]="lineNumbers",G[G.lineNumbersMinChars=63]="lineNumbersMinChars",G[G.linkedEditing=64]="linkedEditing",G[G.links=65]="links",G[G.matchBrackets=66]="matchBrackets",G[G.minimap=67]="minimap",G[G.mouseStyle=68]="mouseStyle",G[G.mouseWheelScrollSensitivity=69]="mouseWheelScrollSensitivity",G[G.mouseWheelZoom=70]="mouseWheelZoom",G[G.multiCursorMergeOverlapping=71]="multiCursorMergeOverlapping",G[G.multiCursorModifier=72]="multiCursorModifier",G[G.multiCursorPaste=73]="multiCursorPaste",G[G.occurrencesHighlight=74]="occurrencesHighlight",G[G.overviewRulerBorder=75]="overviewRulerBorder",G[G.overviewRulerLanes=76]="overviewRulerLanes",G[G.padding=77]="padding",G[G.parameterHints=78]="parameterHints",G[G.peekWidgetDefaultFocus=79]="peekWidgetDefaultFocus",G[G.definitionLinkOpensInPeek=80]="definitionLinkOpensInPeek",G[G.quickSuggestions=81]="quickSuggestions",G[G.quickSuggestionsDelay=82]="quickSuggestionsDelay",G[G.readOnly=83]="readOnly",G[G.renameOnType=84]="renameOnType",G[G.renderControlCharacters=85]="renderControlCharacters",G[G.renderFinalNewline=86]="renderFinalNewline",G[G.renderLineHighlight=87]="renderLineHighlight",G[G.renderLineHighlightOnlyWhenFocus=88]="renderLineHighlightOnlyWhenFocus",G[G.renderValidationDecorations=89]="renderValidationDecorations",G[G.renderWhitespace=90]="renderWhitespace",G[G.revealHorizontalRightPadding=91]="revealHorizontalRightPadding",G[G.roundedSelection=92]="roundedSelection",G[G.rulers=93]="rulers",G[G.scrollbar=94]="scrollbar",G[G.scrollBeyondLastColumn=95]="scrollBeyondLastColumn",G[G.scrollBeyondLastLine=96]="scrollBeyondLastLine",G[G.scrollPredominantAxis=97]="scrollPredominantAxis",G[G.selectionClipboard=98]="selectionClipboard",G[G.selectionHighlight=99]="selectionHighlight",G[G.selectOnLineNumbers=100]="selectOnLineNumbers",G[G.showFoldingControls=101]="showFoldingControls",G[G.showUnused=102]="showUnused",G[G.snippetSuggestions=103]="snippetSuggestions",G[G.smartSelect=104]="smartSelect",G[G.smoothScrolling=105]="smoothScrolling",G[G.stickyTabStops=106]="stickyTabStops",G[G.stopRenderingLineAfter=107]="stopRenderingLineAfter",G[G.suggest=108]="suggest",G[G.suggestFontSize=109]="suggestFontSize",G[G.suggestLineHeight=110]="suggestLineHeight",G[G.suggestOnTriggerCharacters=111]="suggestOnTriggerCharacters",G[G.suggestSelection=112]="suggestSelection",G[G.tabCompletion=113]="tabCompletion",G[G.tabIndex=114]="tabIndex",G[G.unicodeHighlighting=115]="unicodeHighlighting",G[G.unusualLineTerminators=116]="unusualLineTerminators",G[G.useShadowDOM=117]="useShadowDOM",G[G.useTabStops=118]="useTabStops",G[G.wordSeparators=119]="wordSeparators",G[G.wordWrap=120]="wordWrap",G[G.wordWrapBreakAfterCharacters=121]="wordWrapBreakAfterCharacters",G[G.wordWrapBreakBeforeCharacters=122]="wordWrapBreakBeforeCharacters",G[G.wordWrapColumn=123]="wordWrapColumn",G[G.wordWrapOverride1=124]="wordWrapOverride1",G[G.wordWrapOverride2=125]="wordWrapOverride2",G[G.wrappingIndent=126]="wrappingIndent",G[G.wrappingStrategy=127]="wrappingStrategy",G[G.showDeprecated=128]="showDeprecated",G[G.inlayHints=129]="inlayHints",G[G.editorClassName=130]="editorClassName",G[G.pixelRatio=131]="pixelRatio",G[G.tabFocusMode=132]="tabFocusMode",G[G.layoutInfo=133]="layoutInfo",G[G.wrappingInfo=134]="wrappingInfo"})(nt=e.EditorOption||(e.EditorOption={})),e.EditorOptions={acceptSuggestionOnCommitCharacter:ke(new a(0,"acceptSuggestionOnCommitCharacter",!0,{markdownDescription:s.localize(163,null)})),acceptSuggestionOnEnter:ke(new u(1,"acceptSuggestionOnEnter","on",["on","smart","off"],{markdownEnumDescriptions:["",s.localize(164,null),""],markdownDescription:s.localize(165,null)})),accessibilitySupport:ke(new r),accessibilityPageSize:ke(new P(3,"accessibilityPageSize",10,1,1073741824,{description:s.localize(166,null)})),ariaLabel:ke(new _(4,"ariaLabel",s.localize(167,null))),autoClosingBrackets:ke(new u(5,"autoClosingBrackets","languageDefined",["always","languageDefined","beforeWhitespace","never"],{enumDescriptions:["",s.localize(168,null),s.localize(169,null),""],description:s.localize(170,null)})),autoClosingDelete:ke(new u(6,"autoClosingDelete","auto",["always","auto","never"],{enumDescriptions:["",s.localize(171,null),""],description:s.localize(172,null)})),autoClosingOvertype:ke(new u(7,"autoClosingOvertype","auto",["always","auto","never"],{enumDescriptions:["",s.localize(173,null),""],description:s.localize(174,null)})),autoClosingQuotes:ke(new u(8,"autoClosingQuotes","languageDefined",["always","languageDefined","beforeWhitespace","never"],{enumDescriptions:["",s.localize(175,null),s.localize(176,null),""],description:s.localize(177,null)})),autoIndent:ke(new i(9,"autoIndent",4,"full",["none","keep","brackets","advanced","full"],o,{enumDescriptions:[s.localize(178,null),s.localize(179,null),s.localize(180,null),s.localize(181,null),s.localize(182,null)],description:s.localize(183,null)})),automaticLayout:ke(new a(10,"automaticLayout",!1)),autoSurround:ke(new u(11,"autoSurround","languageDefined",["languageDefined","quotes","brackets","never"],{enumDescriptions:[s.localize(184,null),s.localize(185,null),s.localize(186,null),""],description:s.localize(187,null)})),bracketPairColorization:ke(new k),bracketPairGuides:ke(new B),stickyTabStops:ke(new a(106,"stickyTabStops",!1,{description:s.localize(188,null)})),codeLens:ke(new a(14,"codeLens",!0,{description:s.localize(189,null)})),codeLensFontFamily:ke(new _(15,"codeLensFontFamily","",{description:s.localize(190,null)})),codeLensFontSize:ke(new P(16,"codeLensFontSize",0,0,100,{type:"number",default:0,minimum:0,maximum:100,markdownDescription:s.localize(191,null)})),colorDecorators:ke(new a(17,"colorDecorators",!0,{description:s.localize(192,null)})),columnSelection:ke(new a(18,"columnSelection",!1,{description:s.localize(193,null)})),comments:ke(new t),contextmenu:ke(new a(20,"contextmenu",!0)),copyWithSyntaxHighlighting:ke(new a(21,"copyWithSyntaxHighlighting",!0,{description:s.localize(194,null)})),cursorBlinking:ke(new i(22,"cursorBlinking",1,"blink",["blink","smooth","phase","expand","solid"],v,{description:s.localize(195,null)})),cursorSmoothCaretAnimation:ke(new a(23,"cursorSmoothCaretAnimation",!1,{description:s.localize(196,null)})),cursorStyle:ke(new i(24,"cursorStyle",g.Line,"line",["line","block","underline","line-thin","block-outline","underline-thin"],U,{description:s.localize(197,null)})),cursorSurroundingLines:ke(new P(25,"cursorSurroundingLines",0,0,1073741824,{description:s.localize(198,null)})),cursorSurroundingLinesStyle:ke(new u(26,"cursorSurroundingLinesStyle","default",["default","all"],{enumDescriptions:[s.localize(199,null),s.localize(200,null)],description:s.localize(201,null)})),cursorWidth:ke(new P(27,"cursorWidth",0,0,1073741824,{markdownDescription:s.localize(202,null)})),disableLayerHinting:ke(new a(28,"disableLayerHinting",!1)),disableMonospaceOptimizations:ke(new a(29,"disableMonospaceOptimizations",!1)),domReadOnly:ke(new a(30,"domReadOnly",!1)),dragAndDrop:ke(new a(31,"dragAndDrop",!0,{description:s.localize(203,null)})),emptySelectionClipboard:ke(new M),dropIntoEditor:ke(new Ne),experimental:ke(new fe),extraEditorClassName:ke(new _(35,"extraEditorClassName","")),fastScrollSensitivity:ke(new l(36,"fastScrollSensitivity",5,G=>G<=0?5:G,{markdownDescription:s.localize(204,null)})),find:ke(new S),fixedOverflowWidgets:ke(new a(38,"fixedOverflowWidgets",!1)),folding:ke(new a(39,"folding",!0,{description:s.localize(205,null)})),foldingStrategy:ke(new u(40,"foldingStrategy","auto",["auto","indentation"],{enumDescriptions:[s.localize(206,null),s.localize(207,null)],description:s.localize(208,null)})),foldingHighlight:ke(new a(41,"foldingHighlight",!0,{description:s.localize(209,null)})),foldingImportsByDefault:ke(new a(42,"foldingImportsByDefault",!1,{description:s.localize(210,null)})),foldingMaximumRegions:ke(new P(43,"foldingMaximumRegions",5e3,10,65e3,{description:s.localize(211,null)})),unfoldOnClickAfterEndOfLine:ke(new a(44,"unfoldOnClickAfterEndOfLine",!1,{description:s.localize(212,null)})),fontFamily:ke(new _(45,"fontFamily",e.EDITOR_FONT_DEFAULTS.fontFamily,{description:s.localize(213,null)})),fontInfo:ke(new $),fontLigatures2:ke(new z),fontSize:ke(new N),fontWeight:ke(new K),formatOnPaste:ke(new a(50,"formatOnPaste",!1,{description:s.localize(214,null)})),formatOnType:ke(new a(51,"formatOnType",!1,{description:s.localize(215,null)})),glyphMargin:ke(new a(52,"glyphMargin",!0,{description:s.localize(216,null)})),gotoLocation:ke(new V),hideCursorInOverviewRuler:ke(new a(54,"hideCursorInOverviewRuler",!1,{description:s.localize(217,null)})),hover:ke(new F),inDiffEditor:ke(new a(56,"inDiffEditor",!1)),letterSpacing:ke(new l(58,"letterSpacing",e.EDITOR_FONT_DEFAULTS.letterSpacing,G=>l.clamp(G,-5,20),{description:s.localize(218,null)})),lightbulb:ke(new re),lineDecorationsWidth:ke(new h(60,"lineDecorationsWidth",10)),lineHeight:ke(new Ee),lineNumbers:ke(new Ie),lineNumbersMinChars:ke(new P(63,"lineNumbersMinChars",5,1,300)),linkedEditing:ke(new a(64,"linkedEditing",!1,{description:s.localize(219,null)})),links:ke(new a(65,"links",!0,{description:s.localize(220,null)})),matchBrackets:ke(new u(66,"matchBrackets","always",["always","near","never"],{description:s.localize(221,null)})),minimap:ke(new be),mouseStyle:ke(new u(68,"mouseStyle","text",["text","default","copy"])),mouseWheelScrollSensitivity:ke(new l(69,"mouseWheelScrollSensitivity",1,G=>G===0?1:G,{markdownDescription:s.localize(222,null)})),mouseWheelZoom:ke(new a(70,"mouseWheelZoom",!1,{markdownDescription:s.localize(223,null)})),multiCursorMergeOverlapping:ke(new a(71,"multiCursorMergeOverlapping",!0,{description:s.localize(224,null)})),multiCursorModifier:ke(new i(72,"multiCursorModifier","altKey","alt",["ctrlCmd","alt"],te,{markdownEnumDescriptions:[s.localize(225,null),s.localize(226,null)],markdownDescription:s.localize(227,null)})),multiCursorPaste:ke(new u(73,"multiCursorPaste","spread",["spread","full"],{markdownEnumDescriptions:[s.localize(228,null),s.localize(229,null)],markdownDescription:s.localize(230,null)})),occurrencesHighlight:ke(new a(74,"occurrencesHighlight",!0,{description:s.localize(231,null)})),overviewRulerBorder:ke(new a(75,"overviewRulerBorder",!0,{description:s.localize(232,null)})),overviewRulerLanes:ke(new P(76,"overviewRulerLanes",3,0,3)),padding:ke(new ve),parameterHints:ke(new Re),peekWidgetDefaultFocus:ke(new u(79,"peekWidgetDefaultFocus","tree",["tree","editor"],{enumDescriptions:[s.localize(233,null),s.localize(234,null)],description:s.localize(235,null)})),definitionLinkOpensInPeek:ke(new a(80,"definitionLinkOpensInPeek",!1,{description:s.localize(236,null)})),quickSuggestions:ke(new $e),quickSuggestionsDelay:ke(new P(82,"quickSuggestionsDelay",10,0,1073741824,{description:s.localize(237,null)})),readOnly:ke(new a(83,"readOnly",!1)),renameOnType:ke(new a(84,"renameOnType",!1,{description:s.localize(238,null),markdownDeprecationMessage:s.localize(239,null)})),renderControlCharacters:ke(new a(85,"renderControlCharacters",!0,{description:s.localize(240,null),restricted:!0})),renderFinalNewline:ke(new a(86,"renderFinalNewline",!0,{description:s.localize(241,null)})),renderLineHighlight:ke(new u(87,"renderLineHighlight","line",["none","gutter","line","all"],{enumDescriptions:["","","",s.localize(242,null)],description:s.localize(243,null)})),renderLineHighlightOnlyWhenFocus:ke(new a(88,"renderLineHighlightOnlyWhenFocus",!1,{description:s.localize(244,null)})),renderValidationDecorations:ke(new u(89,"renderValidationDecorations","editable",["editable","on","off"])),renderWhitespace:ke(new u(90,"renderWhitespace","selection",["none","boundary","selection","trailing","all"],{enumDescriptions:["",s.localize(245,null),s.localize(246,null),s.localize(247,null),""],description:s.localize(248,null)})),revealHorizontalRightPadding:ke(new P(91,"revealHorizontalRightPadding",30,0,1e3)),roundedSelection:ke(new a(92,"roundedSelection",!0,{description:s.localize(249,null)})),rulers:ke(new Te),scrollbar:ke(new le),scrollBeyondLastColumn:ke(new P(95,"scrollBeyondLastColumn",4,0,1073741824,{description:s.localize(250,null)})),scrollBeyondLastLine:ke(new a(96,"scrollBeyondLastLine",!0,{description:s.localize(251,null)})),scrollPredominantAxis:ke(new a(97,"scrollPredominantAxis",!0,{description:s.localize(252,null)})),selectionClipboard:ke(new a(98,"selectionClipboard",!0,{description:s.localize(253,null),included:p.isLinux})),selectionHighlight:ke(new a(99,"selectionHighlight",!0,{description:s.localize(254,null)})),selectOnLineNumbers:ke(new a(100,"selectOnLineNumbers",!0)),showFoldingControls:ke(new u(101,"showFoldingControls","mouseover",["always","never","mouseover"],{enumDescriptions:[s.localize(255,null),s.localize(256,null),s.localize(257,null)],description:s.localize(258,null)})),showUnused:ke(new a(102,"showUnused",!0,{description:s.localize(259,null)})),showDeprecated:ke(new a(128,"showDeprecated",!0,{description:s.localize(260,null)})),inlayHints:ke(new ie),snippetSuggestions:ke(new u(103,"snippetSuggestions","inline",["top","bottom","inline","none"],{enumDescriptions:[s.localize(261,null),s.localize(262,null),s.localize(263,null),s.localize(264,null)],description:s.localize(265,null)})),smartSelect:ke(new oe),smoothScrolling:ke(new a(105,"smoothScrolling",!1,{description:s.localize(266,null)})),stopRenderingLineAfter:ke(new P(107,"stopRenderingLineAfter",1e4,-1,1073741824)),suggest:ke(new j),inlineSuggest:ke(new J),suggestFontSize:ke(new P(109,"suggestFontSize",0,0,1e3,{markdownDescription:s.localize(267,null,"`0`","`#editor.fontSize#`")})),suggestLineHeight:ke(new P(110,"suggestLineHeight",0,0,1e3,{markdownDescription:s.localize(268,null,"`0`","`#editor.lineHeight#`")})),suggestOnTriggerCharacters:ke(new a(111,"suggestOnTriggerCharacters",!0,{description:s.localize(269,null)})),suggestSelection:ke(new u(112,"suggestSelection","first",["first","recentlyUsed","recentlyUsedByPrefix"],{markdownEnumDescriptions:[s.localize(270,null),s.localize(271,null),s.localize(272,null)],description:s.localize(273,null)})),tabCompletion:ke(new u(113,"tabCompletion","off",["on","off","onlySnippets"],{enumDescriptions:[s.localize(274,null),s.localize(275,null),s.localize(276,null)],description:s.localize(277,null)})),tabIndex:ke(new P(114,"tabIndex",0,-1,1073741824)),unicodeHighlight:ke(new X),unusualLineTerminators:ke(new u(116,"unusualLineTerminators","prompt",["auto","off","prompt"],{enumDescriptions:[s.localize(278,null),s.localize(279,null),s.localize(280,null)],description:s.localize(281,null)})),useShadowDOM:ke(new a(117,"useShadowDOM",!0)),useTabStops:ke(new a(118,"useTabStops",!0,{description:s.localize(282,null)})),wordSeparators:ke(new _(119,"wordSeparators",b.USUAL_WORD_SEPARATORS,{description:s.localize(283,null)})),wordWrap:ke(new u(120,"wordWrap","off",["off","on","wordWrapColumn","bounded"],{markdownEnumDescriptions:[s.localize(284,null),s.localize(285,null),s.localize(286,null),s.localize(287,null)],description:s.localize(288,null)})),wordWrapBreakAfterCharacters:ke(new _(121,"wordWrapBreakAfterCharacters"," })]?|/&.,;\xA2\xB0\u2032\u2033\u2030\u2103\u3001\u3002\uFF61\uFF64\uFFE0\uFF0C\uFF0E\uFF1A\uFF1B\uFF1F\uFF01\uFF05\u30FB\uFF65\u309D\u309E\u30FD\u30FE\u30FC\u30A1\u30A3\u30A5\u30A7\u30A9\u30C3\u30E3\u30E5\u30E7\u30EE\u30F5\u30F6\u3041\u3043\u3045\u3047\u3049\u3063\u3083\u3085\u3087\u308E\u3095\u3096\u31F0\u31F1\u31F2\u31F3\u31F4\u31F5\u31F6\u31F7\u31F8\u31F9\u31FA\u31FB\u31FC\u31FD\u31FE\u31FF\u3005\u303B\uFF67\uFF68\uFF69\uFF6A\uFF6B\uFF6C\uFF6D\uFF6E\uFF6F\uFF70\u201D\u3009\u300B\u300D\u300F\u3011\u3015\uFF09\uFF3D\uFF5D\uFF63")),wordWrapBreakBeforeCharacters:ke(new _(122,"wordWrapBreakBeforeCharacters","([{\u2018\u201C\u3008\u300A\u300C\u300E\u3010\u3014\uFF08\uFF3B\uFF5B\uFF62\xA3\xA5\uFF04\uFFE1\uFFE5+\uFF0B")),wordWrapColumn:ke(new P(123,"wordWrapColumn",80,1,1073741824,{markdownDescription:s.localize(289,null)})),wordWrapOverride1:ke(new u(124,"wordWrapOverride1","inherit",["off","on","inherit"])),wordWrapOverride2:ke(new u(125,"wordWrapOverride2","inherit",["off","on","inherit"])),wrappingIndent:ke(new i(126,"wrappingIndent",1,"same",["none","same","indent","deepIndent"],pe,{enumDescriptions:[s.localize(290,null),s.localize(291,null),s.localize(292,null),s.localize(293,null)],description:s.localize(294,null)})),wrappingStrategy:ke(new u(127,"wrappingStrategy","simple",["simple","advanced"],{enumDescriptions:[s.localize(295,null),s.localize(296,null)],description:s.localize(297,null)})),editorClassName:ke(new W),pixelRatio:ke(new Fe),tabFocusMode:ke(new ue),layoutInfo:ke(new ce),wrappingInfo:ke(new ge)}}),define(ye[122],Ce([17,18]),function(ee,e){return ee.create("vs/platform/configuration/common/configurationRegistry",e)}),define(ye[123],Ce([17,18]),function(ee,e){return ee.create("vs/platform/extensionManagement/common/extensionManagement",e)}),define(ye[124],Ce([17,18]),function(ee,e){return ee.create("vs/platform/extensions/common/extensionValidator",e)}),define(ye[125],Ce([17,18]),function(ee,e){return ee.create("vs/platform/files/common/files",e)}),define(ye[126],Ce([17,18]),function(ee,e){return ee.create("vs/platform/markers/common/markers",e)}),define(ye[127],Ce([17,18]),function(ee,e){return ee.create("vs/platform/workspace/common/workspace",e)}),define(ye[128],Ce([17,18]),function(ee,e){return ee.create("vs/workbench/api/common/extHostDiagnostics",e)}),define(ye[129],Ce([17,18]),function(ee,e){return ee.create("vs/workbench/api/common/extHostExtensionService",e)}),define(ye[130],Ce([17,18]),function(ee,e){return ee.create("vs/workbench/api/common/extHostProgress",e)}),define(ye[131],Ce([17,18]),function(ee,e){return ee.create("vs/workbench/api/common/extHostStatusBar",e)}),define(ye[132],Ce([17,18]),function(ee,e){return ee.create("vs/workbench/api/common/extHostTerminalService",e)}),define(ye[133],Ce([17,18]),function(ee,e){return ee.create("vs/workbench/api/common/extHostTreeViews",e)}),define(ye[134],Ce([17,18]),function(ee,e){return ee.create("vs/workbench/api/common/extHostWorkspace",e)}),define(ye[135],Ce([17,18]),function(ee,e){return ee.create("vs/workbench/common/editor",e)}),define(ye[136],Ce([17,18]),function(ee,e){return ee.create("vs/workbench/contrib/debug/common/abstractDebugAdapter",e)}),define(ye[137],Ce([17,18]),function(ee,e){return ee.create("vs/workbench/contrib/debug/common/debug",e)}),define(ye[138],Ce([17,18]),function(ee,e){return ee.create("vs/workbench/contrib/tasks/common/taskDefinitionRegistry",e)}),define(ye[139],Ce([17,18]),function(ee,e){return ee.create("vs/workbench/contrib/tasks/common/tasks",e)}),define(ye[140],Ce([17,18]),function(ee,e){return ee.create("vs/workbench/services/configurationResolver/common/variableResolver",e)}),define(ye[141],Ce([17,18]),function(ee,e){return ee.create("vs/workbench/services/extensions/common/extensionsRegistry",e)}),define(ye[142],Ce([17,18]),function(ee,e){return ee.create("vs/workbench/services/search/common/queryBuilder",e)}),define(ye[143],Ce([1,0]),function(ee,e){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.TextEditorSelectionSource=e.TextEditorSelectionRevealType=e.EditorOpenSource=e.EditorResolution=e.EditorActivation=void 0;var s;(function(T){T[T.ACTIVATE=1]="ACTIVATE",T[T.RESTORE=2]="RESTORE",T[T.PRESERVE=3]="PRESERVE"})(s=e.EditorActivation||(e.EditorActivation={}));var p;(function(T){T[T.PICK=0]="PICK",T[T.DISABLED=1]="DISABLED",T[T.EXCLUSIVE_ONLY=2]="EXCLUSIVE_ONLY"})(p=e.EditorResolution||(e.EditorResolution={}));var b;(function(T){T[T.API=0]="API",T[T.USER=1]="USER"})(b=e.EditorOpenSource||(e.EditorOpenSource={}));var L;(function(T){T[T.Center=0]="Center",T[T.CenterIfOutsideViewport=1]="CenterIfOutsideViewport",T[T.NearTop=2]="NearTop",T[T.NearTopIfOutsideViewport=3]="NearTopIfOutsideViewport"})(L=e.TextEditorSelectionRevealType||(e.TextEditorSelectionRevealType={}));var C;(function(T){T.PROGRAMMATIC="api",T.NAVIGATION="code.navigation",T.JUMP="code.jump"})(C=e.TextEditorSelectionSource||(e.TextEditorSelectionSource={}))}),define(ye[144],Ce([1,0,21,29,124,238]),function(ee,e,s,p,b,L){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.isEngineValid=e.isValidExtensionVersion=e.validateExtensionManifest=e.isValidVersion=e.normalizeVersion=e.parseVersion=e.isValidVersionStr=void 0;const C=/^(\^|>=)?((\d+)|x)\.((\d+)|x)\.((\d+)|x)(\-.*)?$/,T=/^-(\d{4})(\d{2})(\d{2})$/;function E(a){return a=a.trim(),a==="*"||C.test(a)}e.isValidVersionStr=E;function A(a){if(!E(a))return null;if(a=a.trim(),a==="*")return{hasCaret:!1,hasGreaterEquals:!1,majorBase:0,majorMustEqual:!1,minorBase:0,minorMustEqual:!1,patchBase:0,patchMustEqual:!1,preRelease:null};const w=a.match(C);return w?{hasCaret:w[1]==="^",hasGreaterEquals:w[1]===">=",majorBase:w[2]==="x"?0:parseInt(w[2],10),majorMustEqual:w[2]!=="x",minorBase:w[4]==="x"?0:parseInt(w[4],10),minorMustEqual:w[4]!=="x",patchBase:w[6]==="x"?0:parseInt(w[6],10),patchMustEqual:w[6]!=="x",preRelease:w[8]||null}:null}e.parseVersion=A;function R(a){if(!a)return null;const w=a.majorBase,P=a.majorMustEqual,l=a.minorBase;let _=a.minorMustEqual;const n=a.patchBase;let u=a.patchMustEqual;a.hasCaret&&(w===0||(_=!1),u=!1);let i=0;if(a.preRelease){const o=T.exec(a.preRelease);if(o){const[,r,t,c]=o;i=Date.UTC(Number(r),Number(t)-1,Number(c))}}return{majorBase:w,majorMustEqual:P,minorBase:l,minorMustEqual:_,patchBase:n,patchMustEqual:u,isMinimum:a.hasGreaterEquals,notBefore:i}}e.normalizeVersion=R;function y(a,w,P){let l;typeof a=="string"?l=R(A(a)):l=a;let _;w instanceof Date?_=w.getTime():typeof w=="string"&&(_=new Date(w).getTime());let n;if(typeof P=="string"?n=R(A(P)):n=P,!l||!n)return!1;const u=l.majorBase,i=l.minorBase,o=l.patchBase;let r=n.majorBase,t=n.minorBase,c=n.patchBase;const v=n.notBefore;let g=n.majorMustEqual,D=n.minorMustEqual,U=n.patchMustEqual;return n.isMinimum?u>r?!0:u<r?!1:i>t?!0:i<t||_&&_<v?!1:o>=c:(u===1&&r===0&&(!g||!D||!U)&&(r=1,t=0,c=0,g=!0,D=!1,U=!1),u<r?!1:u>r?!g:i<t?!1:i>t?!D:o<c?!1:o>c?!U:!(_&&_<v))}e.isValidVersion=y;function m(a,w,P,l,_){const n=[];if(typeof l.publisher!="undefined"&&typeof l.publisher!="string")return n.push([p.default.Error,b.localize(0,null)]),n;if(typeof l.name!="string")return n.push([p.default.Error,b.localize(1,null,"name")]),n;if(typeof l.version!="string")return n.push([p.default.Error,b.localize(2,null,"version")]),n;if(!l.engines)return n.push([p.default.Error,b.localize(3,null,"engines")]),n;if(typeof l.engines.vscode!="string")return n.push([p.default.Error,b.localize(4,null,"engines.vscode")]),n;if(typeof l.extensionDependencies!="undefined"&&!d(l.extensionDependencies))return n.push([p.default.Error,b.localize(5,null,"extensionDependencies")]),n;if(typeof l.activationEvents!="undefined"){if(!d(l.activationEvents))return n.push([p.default.Error,b.localize(6,null,"activationEvents")]),n;if(typeof l.main=="undefined"&&typeof l.browser=="undefined")return n.push([p.default.Error,b.localize(7,null,"activationEvents","main")]),n}if(typeof l.extensionKind!="undefined"&&typeof l.main=="undefined"&&n.push([p.default.Warning,b.localize(8,null,"extensionKind")]),typeof l.main!="undefined"){if(typeof l.main!="string")return n.push([p.default.Error,b.localize(9,null,"main")]),n;{const o=(0,s.joinPath)(P,l.main);(0,s.isEqualOrParent)(o,P)||n.push([p.default.Warning,b.localize(10,null,o.path,P.path)])}if(typeof l.activationEvents=="undefined")return n.push([p.default.Error,b.localize(11,null,"activationEvents","main")]),n}if(typeof l.browser!="undefined"){if(typeof l.browser!="string")return n.push([p.default.Error,b.localize(12,null,"browser")]),n;{const o=(0,s.joinPath)(P,l.browser);(0,s.isEqualOrParent)(o,P)||n.push([p.default.Warning,b.localize(13,null,o.path,P.path)])}if(typeof l.activationEvents=="undefined")return n.push([p.default.Error,b.localize(14,null,"activationEvents","browser")]),n}if(!L.valid(l.version))return n.push([p.default.Error,b.localize(15,null)]),n;const u=[];if(!I(a,w,l,_,u))for(const o of u)n.push([p.default.Error,o]);return n}e.validateExtensionManifest=m;function I(a,w,P,l,_){return l||typeof P.main=="undefined"&&typeof P.browser=="undefined"?!0:h(a,w,P.engines.vscode,_)}e.isValidExtensionVersion=I;function f(a,w,P){return a==="*"||h(w,P,a)}e.isEngineValid=f;function h(a,w,P,l=[]){const _=R(A(P));if(!_)return l.push(b.localize(16,null,P)),!1;if(_.majorBase===0){if(!_.majorMustEqual||!_.minorMustEqual)return l.push(b.localize(17,null,P)),!1}else if(!_.majorMustEqual)return l.push(b.localize(18,null,P)),!1;return y(a,w,_)?!0:(l.push(b.localize(19,null,a,P)),!1)}function d(a){if(!Array.isArray(a))return!1;for(let w=0,P=a.length;w<P;w++)if(typeof a[w]!="string")return!1;return!0}}),define(ye[78],Ce([1,0]),function(ee,e){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.SyncDescriptor=void 0;class s{constructor(b,L=[],C=!1){this.ctor=b,this.staticArguments=L,this.supportsDelayedInstantiation=C}}e.SyncDescriptor=s}),define(ye[56],Ce([1,0,78]),function(ee,e,s){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.getSingletonServiceDescriptors=e.registerSingleton=void 0;const p=[];function b(C,T,E){T instanceof s.SyncDescriptor||(T=new s.SyncDescriptor(T,[],E)),p.push([C,T])}e.registerSingleton=b;function L(){return p}e.getSingletonServiceDescriptors=L}),define(ye[145],Ce([1,0]),function(ee,e){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.Graph=e.Node=void 0;class s{constructor(L){this.incoming=new Map,this.outgoing=new Map,this.data=L}}e.Node=s;class p{constructor(L){this._hashFn=L,this._nodes=new Map}roots(){const L=[];for(const C of this._nodes.values())C.outgoing.size===0&&L.push(C);return L}insertEdge(L,C){const T=this.lookupOrInsertNode(L),E=this.lookupOrInsertNode(C);T.outgoing.set(this._hashFn(C),E),E.incoming.set(this._hashFn(L),T)}removeNode(L){const C=this._hashFn(L);this._nodes.delete(C);for(const T of this._nodes.values())T.outgoing.delete(C),T.incoming.delete(C)}lookupOrInsertNode(L){const C=this._hashFn(L);let T=this._nodes.get(C);return T||(T=new s(L),this._nodes.set(C,T)),T}lookup(L){return this._nodes.get(this._hashFn(L))}isEmpty(){return this._nodes.size===0}toString(){const L=[];for(const[C,T]of this._nodes)L.push(`${C}, (incoming)[${[...T.incoming.keys()].join(", ")}], (outgoing)[${[...T.outgoing.keys()].join(",")}]`);return L.join(`
`)}findCycleSlow(){for(const[L,C]of this._nodes){const T=new Set([L]),E=this._findCycle(C,T);if(E)return E}}_findCycle(L,C){for(const[T,E]of L.outgoing){if(C.has(T))return[...C,T].join(" -> ");C.add(T);const A=this._findCycle(E,C);if(A)return A;C.delete(T)}}}e.Graph=p}),define(ye[3],Ce([1,0]),function(ee,e){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.refineServiceDecorator=e.createDecorator=e.IInstantiationService=e._util=void 0;var s;(function(C){C.serviceIds=new Map,C.DI_TARGET="$di$target",C.DI_DEPENDENCIES="$di$dependencies";function T(E){return E[C.DI_DEPENDENCIES]||[]}C.getServiceDependencies=T})(s=e._util||(e._util={})),e.IInstantiationService=b("instantiationService");function p(C,T,E){T[s.DI_TARGET]===T?T[s.DI_DEPENDENCIES].push({id:C,index:E}):(T[s.DI_DEPENDENCIES]=[{id:C,index:E}],T[s.DI_TARGET]=T)}function b(C){if(s.serviceIds.has(C))return s.serviceIds.get(C);const T=function(E,A,R){if(arguments.length!==3)throw new Error("@IServiceName-decorator can only be used to decorate a parameter");p(T,E,R)};return T.toString=()=>C,s.serviceIds.set(C,T),T}e.createDecorator=b;function L(C){return C}e.refineServiceDecorator=L}),define(ye[57],Ce([1,0,10,2,3]),function(ee,e,s,p,b){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.getLanguageTagSettingPlainKey=e.getMigratedSettingValue=e.merge=e.getConfigurationValue=e.removeFromValueTree=e.addToValueTree=e.toValuesTree=e.ConfigurationTargetToString=e.ConfigurationTarget=e.isConfigurationUpdateOverrides=e.isConfigurationOverrides=e.IConfigurationService=void 0,e.IConfigurationService=(0,b.createDecorator)("configurationService");function L(a){return a&&typeof a=="object"&&(!a.overrideIdentifier||typeof a.overrideIdentifier=="string")&&(!a.resource||a.resource instanceof p.URI)}e.isConfigurationOverrides=L;function C(a){return a&&typeof a=="object"&&(!a.overrideIdentifiers||s.isArray(a.overrideIdentifiers))&&!a.overrideIdentifier&&(!a.resource||a.resource instanceof p.URI)}e.isConfigurationUpdateOverrides=C;var T;(function(a){a[a.APPLICATION=1]="APPLICATION",a[a.USER=2]="USER",a[a.USER_LOCAL=3]="USER_LOCAL",a[a.USER_REMOTE=4]="USER_REMOTE",a[a.WORKSPACE=5]="WORKSPACE",a[a.WORKSPACE_FOLDER=6]="WORKSPACE_FOLDER",a[a.DEFAULT=7]="DEFAULT",a[a.MEMORY=8]="MEMORY"})(T=e.ConfigurationTarget||(e.ConfigurationTarget={}));function E(a){switch(a){case 1:return"APPLICATION";case 2:return"USER";case 3:return"USER_LOCAL";case 4:return"USER_REMOTE";case 5:return"WORKSPACE";case 6:return"WORKSPACE_FOLDER";case 7:return"DEFAULT";case 8:return"MEMORY"}}e.ConfigurationTargetToString=E;function A(a,w){const P=Object.create(null);for(const l in a)R(P,l,a[l],w);return P}e.toValuesTree=A;function R(a,w,P,l){const _=w.split("."),n=_.pop();let u=a;for(let i=0;i<_.length;i++){const o=_[i];let r=u[o];switch(typeof r){case"undefined":r=u[o]=Object.create(null);break;case"object":break;default:l(`Ignoring ${w} as ${_.slice(0,i+1).join(".")} is ${JSON.stringify(r)}`);return}u=r}if(typeof u=="object"&&u!==null)try{u[n]=P}catch{l(`Ignoring ${w} as ${_.join(".")} is ${JSON.stringify(u)}`)}else l(`Ignoring ${w} as ${_.join(".")} is ${JSON.stringify(u)}`)}e.addToValueTree=R;function y(a,w){const P=w.split(".");m(a,P)}e.removeFromValueTree=y;function m(a,w){const P=w.shift();if(w.length===0){delete a[P];return}if(Object.keys(a).indexOf(P)!==-1){const l=a[P];typeof l=="object"&&!Array.isArray(l)&&(m(l,w),Object.keys(l).length===0&&delete a[P])}}function I(a,w,P){function l(u,i){let o=u;for(const r of i){if(typeof o!="object"||o===null)return;o=o[r]}return o}const _=w.split("."),n=l(a,_);return typeof n=="undefined"?P:n}e.getConfigurationValue=I;function f(a,w,P){Object.keys(w).forEach(l=>{l!=="__proto__"&&(l in a?s.isObject(a[l])&&s.isObject(w[l])?f(a[l],w[l],P):P&&(a[l]=w[l]):a[l]=w[l])})}e.merge=f;function h(a,w,P){const l=a.inspect(w),_=a.inspect(P);return typeof l.userValue!="undefined"||typeof l.workspaceValue!="undefined"||typeof l.workspaceFolderValue!="undefined"?l.value:typeof _.userValue!="undefined"||typeof _.workspaceValue!="undefined"||typeof _.workspaceFolderValue!="undefined"?_.value:l.defaultValue}e.getMigratedSettingValue=h;function d(a){return a.replace(/[\[\]]/g,"")}e.getLanguageTagSettingPlainKey=d}),define(ye[38],Ce([1,0,23,9,3]),function(ee,e,s,p,b){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.implies=e.SET_CONTEXT_COMMAND_ID=e.IContextKeyService=e.RawContextKey=e.ContextKeyNotRegexExpr=e.ContextKeyRegexExpr=e.ContextKeySmallerEqualsExpr=e.ContextKeySmallerExpr=e.ContextKeyGreaterEqualsExpr=e.ContextKeyGreaterExpr=e.ContextKeyNotExpr=e.ContextKeyNotEqualsExpr=e.ContextKeyNotInExpr=e.ContextKeyInExpr=e.ContextKeyEqualsExpr=e.ContextKeyDefinedExpr=e.ContextKeyTrueExpr=e.ContextKeyFalseExpr=e.expressionsAreEqualWithConstantSubstitution=e.ContextKeyExpr=e.ContextKeyExprType=void 0;const L=new Map;L.set("false",!1),L.set("true",!0),L.set("isMac",s.isMacintosh),L.set("isLinux",s.isLinux),L.set("isWindows",s.isWindows),L.set("isWeb",s.isWeb),L.set("isMacNative",s.isMacintosh&&!s.isWeb),L.set("isEdge",s.isEdge),L.set("isFirefox",s.isFirefox),L.set("isChrome",s.isChrome),L.set("isSafari",s.isSafari);const C=Object.prototype.hasOwnProperty;var T;(function(M){M[M.False=0]="False",M[M.True=1]="True",M[M.Defined=2]="Defined",M[M.Not=3]="Not",M[M.Equals=4]="Equals",M[M.NotEquals=5]="NotEquals",M[M.And=6]="And",M[M.Regex=7]="Regex",M[M.NotRegex=8]="NotRegex",M[M.Or=9]="Or",M[M.In=10]="In",M[M.NotIn=11]="NotIn",M[M.Greater=12]="Greater",M[M.GreaterEquals=13]="GreaterEquals",M[M.Smaller=14]="Smaller",M[M.SmallerEquals=15]="SmallerEquals"})(T=e.ContextKeyExprType||(e.ContextKeyExprType={}));class E{static false(){return y.INSTANCE}static true(){return m.INSTANCE}static has(S){return I.create(S)}static equals(S,z){return f.create(S,z)}static notEquals(S,z){return a.create(S,z)}static regex(S,z){return i.create(S,z)}static in(S,z){return h.create(S,z)}static notIn(S,z){return d.create(S,z)}static not(S){return w.create(S)}static and(...S){return t.create(S,null)}static or(...S){return c.create(S,null,!0)}static greater(S,z){return l.create(S,z)}static greaterEquals(S,z){return _.create(S,z)}static smaller(S,z){return n.create(S,z)}static smallerEquals(S,z){return u.create(S,z)}static deserialize(S,z=!1){if(!!S)return this._deserializeOrExpression(S,z)}static _deserializeOrExpression(S,z){const $=S.split("||");return c.create($.map(N=>this._deserializeAndExpression(N,z)),null,!0)}static _deserializeAndExpression(S,z){const $=S.split("&&");return t.create($.map(N=>this._deserializeOne(N,z)),null)}static _deserializeOne(S,z){if(S=S.trim(),S.indexOf("!=")>=0){const $=S.split("!=");return a.create($[0].trim(),this._deserializeValue($[1],z))}if(S.indexOf("==")>=0){const $=S.split("==");return f.create($[0].trim(),this._deserializeValue($[1],z))}if(S.indexOf("=~")>=0){const $=S.split("=~");return i.create($[0].trim(),this._deserializeRegexValue($[1],z))}if(S.indexOf(" not in ")>=0){const $=S.split(" not in ");return d.create($[0].trim(),$[1].trim())}if(S.indexOf(" in ")>=0){const $=S.split(" in ");return h.create($[0].trim(),$[1].trim())}if(/^[^<=>]+>=[^<=>]+$/.test(S)){const $=S.split(">=");return _.create($[0].trim(),$[1].trim())}if(/^[^<=>]+>[^<=>]+$/.test(S)){const $=S.split(">");return l.create($[0].trim(),$[1].trim())}if(/^[^<=>]+<=[^<=>]+$/.test(S)){const $=S.split("<=");return u.create($[0].trim(),$[1].trim())}if(/^[^<=>]+<[^<=>]+$/.test(S)){const $=S.split("<");return n.create($[0].trim(),$[1].trim())}return/^\!\s*/.test(S)?w.create(S.substr(1).trim()):I.create(S)}static _deserializeValue(S,z){if(S=S.trim(),S==="true")return!0;if(S==="false")return!1;const $=/^'([^']*)'$/.exec(S);return $?$[1].trim():S}static _deserializeRegexValue(S,z){if((0,p.isFalsyOrWhitespace)(S)){if(z)throw new Error("missing regexp-value for =~-expression");return console.warn("missing regexp-value for =~-expression"),null}const $=S.indexOf("/"),N=S.lastIndexOf("/");if($===N||$<0){if(z)throw new Error(`bad regexp-value '${S}', missing /-enclosure`);return console.warn(`bad regexp-value '${S}', missing /-enclosure`),null}const K=S.slice($+1,N),V=S[N+1]==="i"?"i":"";try{return new RegExp(K,V)}catch(F){if(z)throw new Error(`bad regexp-value '${S}', parse error: ${F}`);return console.warn(`bad regexp-value '${S}', parse error: ${F}`),null}}}e.ContextKeyExpr=E;function A(M,S){const z=M?M.substituteConstants():void 0,$=S?S.substituteConstants():void 0;return!z&&!$?!0:!z||!$?!1:z.equals($)}e.expressionsAreEqualWithConstantSubstitution=A;function R(M,S){return M.cmp(S)}class y{constructor(){this.type=0}cmp(S){return this.type-S.type}equals(S){return S.type===this.type}substituteConstants(){return this}evaluate(S){return!1}serialize(){return"false"}keys(){return[]}map(S){return this}negate(){return m.INSTANCE}}e.ContextKeyFalseExpr=y,y.INSTANCE=new y;class m{constructor(){this.type=1}cmp(S){return this.type-S.type}equals(S){return S.type===this.type}substituteConstants(){return this}evaluate(S){return!0}serialize(){return"true"}keys(){return[]}map(S){return this}negate(){return y.INSTANCE}}e.ContextKeyTrueExpr=m,m.INSTANCE=new m;class I{constructor(S,z){this.key=S,this.negated=z,this.type=2}static create(S,z=null){const $=L.get(S);return typeof $=="boolean"?$?m.INSTANCE:y.INSTANCE:new I(S,z)}cmp(S){return S.type!==this.type?this.type-S.type:g(this.key,S.key)}equals(S){return S.type===this.type?this.key===S.key:!1}substituteConstants(){const S=L.get(this.key);return typeof S=="boolean"?S?m.INSTANCE:y.INSTANCE:this}evaluate(S){return!!S.getValue(this.key)}serialize(){return this.key}keys(){return[this.key]}map(S){return S.mapDefined(this.key)}negate(){return this.negated||(this.negated=w.create(this.key,this)),this.negated}}e.ContextKeyDefinedExpr=I;class f{constructor(S,z,$){this.key=S,this.value=z,this.negated=$,this.type=4}static create(S,z,$=null){if(typeof z=="boolean")return z?I.create(S,$):w.create(S,$);const N=L.get(S);return typeof N=="boolean"?z===(N?"true":"false")?m.INSTANCE:y.INSTANCE:new f(S,z,$)}cmp(S){return S.type!==this.type?this.type-S.type:D(this.key,this.value,S.key,S.value)}equals(S){return S.type===this.type?this.key===S.key&&this.value===S.value:!1}substituteConstants(){const S=L.get(this.key);if(typeof S=="boolean"){const z=S?"true":"false";return this.value===z?m.INSTANCE:y.INSTANCE}return this}evaluate(S){return S.getValue(this.key)==this.value}serialize(){return`${this.key} == '${this.value}'`}keys(){return[this.key]}map(S){return S.mapEquals(this.key,this.value)}negate(){return this.negated||(this.negated=a.create(this.key,this.value,this)),this.negated}}e.ContextKeyEqualsExpr=f;class h{constructor(S,z){this.key=S,this.valueKey=z,this.type=10,this.negated=null}static create(S,z){return new h(S,z)}cmp(S){return S.type!==this.type?this.type-S.type:D(this.key,this.valueKey,S.key,S.valueKey)}equals(S){return S.type===this.type?this.key===S.key&&this.valueKey===S.valueKey:!1}substituteConstants(){return this}evaluate(S){const z=S.getValue(this.valueKey),$=S.getValue(this.key);return Array.isArray(z)?z.includes($):typeof $=="string"&&typeof z=="object"&&z!==null?C.call(z,$):!1}serialize(){return`${this.key} in '${this.valueKey}'`}keys(){return[this.key,this.valueKey]}map(S){return S.mapIn(this.key,this.valueKey)}negate(){return this.negated||(this.negated=d.create(this.key,this.valueKey)),this.negated}}e.ContextKeyInExpr=h;class d{constructor(S,z){this.key=S,this.valueKey=z,this.type=11,this._negated=h.create(S,z)}static create(S,z){return new d(S,z)}cmp(S){return S.type!==this.type?this.type-S.type:this._negated.cmp(S._negated)}equals(S){return S.type===this.type?this._negated.equals(S._negated):!1}substituteConstants(){return this}evaluate(S){return!this._negated.evaluate(S)}serialize(){return`${this.key} not in '${this.valueKey}'`}keys(){return this._negated.keys()}map(S){return S.mapNotIn(this.key,this.valueKey)}negate(){return this._negated}}e.ContextKeyNotInExpr=d;class a{constructor(S,z,$){this.key=S,this.value=z,this.negated=$,this.type=5}static create(S,z,$=null){if(typeof z=="boolean")return z?w.create(S,$):I.create(S,$);const N=L.get(S);return typeof N=="boolean"?z===(N?"true":"false")?y.INSTANCE:m.INSTANCE:new a(S,z,$)}cmp(S){return S.type!==this.type?this.type-S.type:D(this.key,this.value,S.key,S.value)}equals(S){return S.type===this.type?this.key===S.key&&this.value===S.value:!1}substituteConstants(){const S=L.get(this.key);if(typeof S=="boolean"){const z=S?"true":"false";return this.value===z?y.INSTANCE:m.INSTANCE}return this}evaluate(S){return S.getValue(this.key)!=this.value}serialize(){return`${this.key} != '${this.value}'`}keys(){return[this.key]}map(S){return S.mapNotEquals(this.key,this.value)}negate(){return this.negated||(this.negated=f.create(this.key,this.value,this)),this.negated}}e.ContextKeyNotEqualsExpr=a;class w{constructor(S,z){this.key=S,this.negated=z,this.type=3}static create(S,z=null){const $=L.get(S);return typeof $=="boolean"?$?y.INSTANCE:m.INSTANCE:new w(S,z)}cmp(S){return S.type!==this.type?this.type-S.type:g(this.key,S.key)}equals(S){return S.type===this.type?this.key===S.key:!1}substituteConstants(){const S=L.get(this.key);return typeof S=="boolean"?S?y.INSTANCE:m.INSTANCE:this}evaluate(S){return!S.getValue(this.key)}serialize(){return`!${this.key}`}keys(){return[this.key]}map(S){return S.mapNot(this.key)}negate(){return this.negated||(this.negated=I.create(this.key,this)),this.negated}}e.ContextKeyNotExpr=w;function P(M,S){if(typeof M=="string"){const z=parseFloat(M);isNaN(z)||(M=z)}return typeof M=="string"||typeof M=="number"?S(M):y.INSTANCE}class l{constructor(S,z,$){this.key=S,this.value=z,this.negated=$,this.type=12}static create(S,z,$=null){return P(z,N=>new l(S,N,$))}cmp(S){return S.type!==this.type?this.type-S.type:D(this.key,this.value,S.key,S.value)}equals(S){return S.type===this.type?this.key===S.key&&this.value===S.value:!1}substituteConstants(){return this}evaluate(S){return typeof this.value=="string"?!1:parseFloat(S.getValue(this.key))>this.value}serialize(){return`${this.key} > ${this.value}`}keys(){return[this.key]}map(S){return S.mapGreater(this.key,this.value)}negate(){return this.negated||(this.negated=u.create(this.key,this.value,this)),this.negated}}e.ContextKeyGreaterExpr=l;class _{constructor(S,z,$){this.key=S,this.value=z,this.negated=$,this.type=13}static create(S,z,$=null){return P(z,N=>new _(S,N,$))}cmp(S){return S.type!==this.type?this.type-S.type:D(this.key,this.value,S.key,S.value)}equals(S){return S.type===this.type?this.key===S.key&&this.value===S.value:!1}substituteConstants(){return this}evaluate(S){return typeof this.value=="string"?!1:parseFloat(S.getValue(this.key))>=this.value}serialize(){return`${this.key} >= ${this.value}`}keys(){return[this.key]}map(S){return S.mapGreaterEquals(this.key,this.value)}negate(){return this.negated||(this.negated=n.create(this.key,this.value,this)),this.negated}}e.ContextKeyGreaterEqualsExpr=_;class n{constructor(S,z,$){this.key=S,this.value=z,this.negated=$,this.type=14}static create(S,z,$=null){return P(z,N=>new n(S,N,$))}cmp(S){return S.type!==this.type?this.type-S.type:D(this.key,this.value,S.key,S.value)}equals(S){return S.type===this.type?this.key===S.key&&this.value===S.value:!1}substituteConstants(){return this}evaluate(S){return typeof this.value=="string"?!1:parseFloat(S.getValue(this.key))<this.value}serialize(){return`${this.key} < ${this.value}`}keys(){return[this.key]}map(S){return S.mapSmaller(this.key,this.value)}negate(){return this.negated||(this.negated=_.create(this.key,this.value,this)),this.negated}}e.ContextKeySmallerExpr=n;class u{constructor(S,z,$){this.key=S,this.value=z,this.negated=$,this.type=15}static create(S,z,$=null){return P(z,N=>new u(S,N,$))}cmp(S){return S.type!==this.type?this.type-S.type:D(this.key,this.value,S.key,S.value)}equals(S){return S.type===this.type?this.key===S.key&&this.value===S.value:!1}substituteConstants(){return this}evaluate(S){return typeof this.value=="string"?!1:parseFloat(S.getValue(this.key))<=this.value}serialize(){return`${this.key} <= ${this.value}`}keys(){return[this.key]}map(S){return S.mapSmallerEquals(this.key,this.value)}negate(){return this.negated||(this.negated=l.create(this.key,this.value,this)),this.negated}}e.ContextKeySmallerEqualsExpr=u;class i{constructor(S,z){this.key=S,this.regexp=z,this.type=7,this.negated=null}static create(S,z){return new i(S,z)}cmp(S){if(S.type!==this.type)return this.type-S.type;if(this.key<S.key)return-1;if(this.key>S.key)return 1;const z=this.regexp?this.regexp.source:"",$=S.regexp?S.regexp.source:"";return z<$?-1:z>$?1:0}equals(S){if(S.type===this.type){const z=this.regexp?this.regexp.source:"",$=S.regexp?S.regexp.source:"";return this.key===S.key&&z===$}return!1}substituteConstants(){return this}evaluate(S){const z=S.getValue(this.key);return this.regexp?this.regexp.test(z):!1}serialize(){const S=this.regexp?`/${this.regexp.source}/${this.regexp.ignoreCase?"i":""}`:"/invalid/";return`${this.key} =~ ${S}`}keys(){return[this.key]}map(S){return S.mapRegex(this.key,this.regexp)}negate(){return this.negated||(this.negated=o.create(this)),this.negated}}e.ContextKeyRegexExpr=i;class o{constructor(S){this._actual=S,this.type=8}static create(S){return new o(S)}cmp(S){return S.type!==this.type?this.type-S.type:this._actual.cmp(S._actual)}equals(S){return S.type===this.type?this._actual.equals(S._actual):!1}substituteConstants(){return this}evaluate(S){return!this._actual.evaluate(S)}serialize(){throw new Error("Method not implemented.")}keys(){return this._actual.keys()}map(S){return new o(this._actual.map(S))}negate(){return this._actual}}e.ContextKeyNotRegexExpr=o;function r(M){let S=null;for(let z=0,$=M.length;z<$;z++){const N=M[z].substituteConstants();if(M[z]!==N&&S===null){S=[];for(let K=0;K<z;K++)S[K]=M[K]}S!==null&&(S[z]=N)}return S===null?M:S}class t{constructor(S,z){this.expr=S,this.negated=z,this.type=6}static create(S,z){return t._normalizeArr(S,z)}cmp(S){if(S.type!==this.type)return this.type-S.type;if(this.expr.length<S.expr.length)return-1;if(this.expr.length>S.expr.length)return 1;for(let z=0,$=this.expr.length;z<$;z++){const N=R(this.expr[z],S.expr[z]);if(N!==0)return N}return 0}equals(S){if(S.type===this.type){if(this.expr.length!==S.expr.length)return!1;for(let z=0,$=this.expr.length;z<$;z++)if(!this.expr[z].equals(S.expr[z]))return!1;return!0}return!1}substituteConstants(){const S=r(this.expr);return S===this.expr?this:t.create(S,this.negated)}evaluate(S){for(let z=0,$=this.expr.length;z<$;z++)if(!this.expr[z].evaluate(S))return!1;return!0}static _normalizeArr(S,z){const $=[];let N=!1;for(const K of S)if(!!K){if(K.type===1){N=!0;continue}if(K.type===0)return y.INSTANCE;if(K.type===6){$.push(...K.expr);continue}$.push(K)}if($.length===0&&N)return m.INSTANCE;if($.length!==0){if($.length===1)return $[0];$.sort(R);for(let K=1;K<$.length;K++)$[K-1].equals($[K])&&($.splice(K,1),K--);if($.length===1)return $[0];for(;$.length>1;){const K=$[$.length-1];if(K.type!==9)break;$.pop();const V=$.pop(),F=$.length===0,ne=c.create(K.expr.map(ce=>t.create([ce,V],null)),null,F);ne&&($.push(ne),$.sort(R))}return $.length===1?$[0]:new t($,z)}}serialize(){return this.expr.map(S=>S.serialize()).join(" && ")}keys(){const S=[];for(const z of this.expr)S.push(...z.keys());return S}map(S){return new t(this.expr.map(z=>z.map(S)),null)}negate(){if(!this.negated){const S=[];for(const z of this.expr)S.push(z.negate());this.negated=c.create(S,this,!0)}return this.negated}}class c{constructor(S,z){this.expr=S,this.negated=z,this.type=9}static create(S,z,$){return c._normalizeArr(S,z,$)}cmp(S){if(S.type!==this.type)return this.type-S.type;if(this.expr.length<S.expr.length)return-1;if(this.expr.length>S.expr.length)return 1;for(let z=0,$=this.expr.length;z<$;z++){const N=R(this.expr[z],S.expr[z]);if(N!==0)return N}return 0}equals(S){if(S.type===this.type){if(this.expr.length!==S.expr.length)return!1;for(let z=0,$=this.expr.length;z<$;z++)if(!this.expr[z].equals(S.expr[z]))return!1;return!0}return!1}substituteConstants(){const S=r(this.expr);return S===this.expr?this:c.create(S,this.negated,!1)}evaluate(S){for(let z=0,$=this.expr.length;z<$;z++)if(this.expr[z].evaluate(S))return!0;return!1}static _normalizeArr(S,z,$){let N=[],K=!1;if(S){for(let V=0,F=S.length;V<F;V++){const ne=S[V];if(!!ne){if(ne.type===0){K=!0;continue}if(ne.type===1)return m.INSTANCE;if(ne.type===9){N=N.concat(ne.expr);continue}N.push(ne)}}if(N.length===0&&K)return y.INSTANCE;N.sort(R)}if(N.length!==0){if(N.length===1)return N[0];for(let V=1;V<N.length;V++)N[V-1].equals(N[V])&&(N.splice(V,1),V--);if(N.length===1)return N[0];if($){for(let V=0;V<N.length;V++)for(let F=V+1;F<N.length;F++)U(N[V],N[F])&&(N.splice(F,1),F--);if(N.length===1)return N[0]}return new c(N,z)}}serialize(){return this.expr.map(S=>S.serialize()).join(" || ")}keys(){const S=[];for(const z of this.expr)S.push(...z.keys());return S}map(S){return new c(this.expr.map(z=>z.map(S)),null)}negate(){if(!this.negated){const S=[];for(const z of this.expr)S.push(z.negate());for(;S.length>1;){const z=S.shift(),$=S.shift(),N=[];for(const V of W(z))for(const F of W($))N.push(t.create([V,F],null));const K=S.length===0;S.unshift(c.create(N,null,K))}this.negated=S[0]}return this.negated}}class v extends I{constructor(S,z,$){super(S,null);this._defaultValue=z,typeof $=="object"?v._info.push({...$,key:S}):$!==!0&&v._info.push({key:S,description:$,type:z!=null?typeof z:void 0})}static all(){return v._info.values()}bindTo(S){return S.createKey(this.key,this._defaultValue)}getValue(S){return S.getContextKeyValue(this.key)}toNegated(){return this.negate()}isEqualTo(S){return f.create(this.key,S)}notEqualsTo(S){return a.create(this.key,S)}}e.RawContextKey=v,v._info=[],e.IContextKeyService=(0,b.createDecorator)("contextKeyService"),e.SET_CONTEXT_COMMAND_ID="setContext";function g(M,S){return M<S?-1:M>S?1:0}function D(M,S,z,$){return M<z?-1:M>z?1:S<$?-1:S>$?1:0}function U(M,S){if(S.type===6&&M.type!==9&&M.type!==6){for(const N of S.expr)if(M.equals(N))return!0}const z=M.negate(),$=W(z).concat(W(S));$.sort(R);for(let N=0;N<$.length;N++){const V=$[N].negate();for(let F=N+1;F<$.length;F++){const ne=$[F];if(V.equals(ne))return!0}}return!1}e.implies=U;function W(M){return M.type===9?M.expr:[M]}}),define(ye[146],Ce([1,0,3]),function(ee,e,s){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.INativeEnvironmentService=e.IEnvironmentService=void 0,e.IEnvironmentService=(0,s.createDecorator)("environmentService"),e.INativeEnvironmentService=(0,s.refineServiceDecorator)(e.IEnvironmentService)}),define(ye[79],Ce([1,0,123,3]),function(ee,e,s,p){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.IDefaultExtensionsProfileInitService=e.IExtensionManagementCLIService=e.PreferencesLocalizedLabel=e.PreferencesLabel=e.ExtensionsChannelId=e.ExtensionsLocalizedLabel=e.ExtensionsLabel=e.IExtensionTipsService=e.IGlobalExtensionEnablementService=e.ENABLED_EXTENSIONS_STORAGE_PATH=e.DISABLED_EXTENSIONS_STORAGE_PATH=e.IServerExtensionManagementService=e.IExtensionManagementService=e.ExtensionManagementError=e.ExtensionManagementErrorCode=e.IExtensionGalleryService=e.InstallOperation=e.StatisticType=e.SortOrder=e.SortBy=e.isIExtensionIdentifier=e.getFallbackTargetPlarforms=e.isTargetPlatformCompatible=e.isNotWebExtensionInWebTargetPlatform=e.getTargetPlatform=e.toTargetPlatform=e.TargetPlatformToString=e.WEB_EXTENSION_TAG=e.EXTENSION_IDENTIFIER_REGEX=e.EXTENSION_IDENTIFIER_PATTERN=void 0,e.EXTENSION_IDENTIFIER_PATTERN="^([a-z0-9A-Z][a-z0-9-A-Z]*)\\.([a-z0-9A-Z][a-z0-9-A-Z]*)$",e.EXTENSION_IDENTIFIER_REGEX=new RegExp(e.EXTENSION_IDENTIFIER_PATTERN),e.WEB_EXTENSION_TAG="__web_extension";function b(a){switch(a){case"win32-x64":return"Windows 64 bit";case"win32-ia32":return"Windows 32 bit";case"win32-arm64":return"Windows ARM";case"linux-x64":return"Linux 64 bit";case"linux-arm64":return"Linux ARM 64";case"linux-armhf":return"Linux ARM";case"alpine-x64":return"Alpine Linux 64 bit";case"alpine-arm64":return"Alpine ARM 64";case"darwin-x64":return"Mac";case"darwin-arm64":return"Mac Silicon";case"web":return"Web";case"universal":return"universal";case"unknown":return"unknown";case"undefined":return"undefined"}}e.TargetPlatformToString=b;function L(a){switch(a){case"win32-x64":return"win32-x64";case"win32-ia32":return"win32-ia32";case"win32-arm64":return"win32-arm64";case"linux-x64":return"linux-x64";case"linux-arm64":return"linux-arm64";case"linux-armhf":return"linux-armhf";case"alpine-x64":return"alpine-x64";case"alpine-arm64":return"alpine-arm64";case"darwin-x64":return"darwin-x64";case"darwin-arm64":return"darwin-arm64";case"web":return"web";case"universal":return"universal";default:return"unknown"}}e.toTargetPlatform=L;function C(a,w){switch(a){case 3:return w==="x64"?"win32-x64":w==="ia32"?"win32-ia32":w==="arm64"?"win32-arm64":"unknown";case 2:return w==="x64"?"linux-x64":w==="arm64"?"linux-arm64":w==="arm"?"linux-armhf":"unknown";case"alpine":return w==="x64"?"alpine-x64":w==="arm64"?"alpine-arm64":"unknown";case 1:return w==="x64"?"darwin-x64":w==="arm64"?"darwin-arm64":"unknown";case 0:return"web"}}e.getTargetPlatform=C;function T(a,w){return w==="web"&&!a.includes("web")}e.isNotWebExtensionInWebTargetPlatform=T;function E(a,w,P){return T(w,P)?!1:a==="undefined"||a==="universal"?!0:a==="unknown"?!1:a===P?!0:A(P).includes(a)}e.isTargetPlatformCompatible=E;function A(a){switch(a){case"win32-x64":return["win32-ia32"];case"win32-arm64":return["win32-ia32"]}return[]}e.getFallbackTargetPlarforms=A;function R(a){return a&&typeof a=="object"&&typeof a.id=="string"&&(!a.uuid||typeof a.uuid=="string")}e.isIExtensionIdentifier=R;var y;(function(a){a[a.NoneOrRelevance=0]="NoneOrRelevance",a[a.LastUpdatedDate=1]="LastUpdatedDate",a[a.Title=2]="Title",a[a.PublisherName=3]="PublisherName",a[a.InstallCount=4]="InstallCount",a[a.PublishedDate=10]="PublishedDate",a[a.AverageRating=6]="AverageRating",a[a.WeightedRating=12]="WeightedRating"})(y=e.SortBy||(e.SortBy={}));var m;(function(a){a[a.Default=0]="Default",a[a.Ascending=1]="Ascending",a[a.Descending=2]="Descending"})(m=e.SortOrder||(e.SortOrder={}));var I;(function(a){a.Install="install",a.Uninstall="uninstall"})(I=e.StatisticType||(e.StatisticType={}));var f;(function(a){a[a.None=1]="None",a[a.Install=2]="Install",a[a.Update=3]="Update",a[a.Migrate=4]="Migrate"})(f=e.InstallOperation||(e.InstallOperation={})),e.IExtensionGalleryService=(0,p.createDecorator)("extensionGalleryService");var h;(function(a){a.Unsupported="Unsupported",a.Deprecated="Deprecated",a.Malicious="Malicious",a.Incompatible="Incompatible",a.IncompatiblePreRelease="IncompatiblePreRelease",a.IncompatibleTargetPlatform="IncompatibleTargetPlatform",a.ReleaseVersionNotFound="ReleaseVersionNotFound",a.Invalid="Invalid",a.Download="Download",a.Extract="Extract",a.Delete="Delete",a.Rename="Rename",a.CorruptZip="CorruptZip",a.IncompleteZip="IncompleteZip",a.Internal="Internal"})(h=e.ExtensionManagementErrorCode||(e.ExtensionManagementErrorCode={}));class d extends Error{constructor(w,P){super(w);this.code=P,this.name=P}}e.ExtensionManagementError=d,e.IExtensionManagementService=(0,p.createDecorator)("extensionManagementService"),e.IServerExtensionManagementService=(0,p.refineServiceDecorator)(e.IExtensionManagementService),e.DISABLED_EXTENSIONS_STORAGE_PATH="extensionsIdentifiers/disabled",e.ENABLED_EXTENSIONS_STORAGE_PATH="extensionsIdentifiers/enabled",e.IGlobalExtensionEnablementService=(0,p.createDecorator)("IGlobalExtensionEnablementService"),e.IExtensionTipsService=(0,p.createDecorator)("IExtensionTipsService"),e.ExtensionsLabel=(0,s.localize)(0,null),e.ExtensionsLocalizedLabel={value:e.ExtensionsLabel,original:"Extensions"},e.ExtensionsChannelId="extensions",e.PreferencesLabel=(0,s.localize)(1,null),e.PreferencesLocalizedLabel={value:e.PreferencesLabel,original:"Preferences"},e.IExtensionManagementCLIService=(0,p.createDecorator)("IExtensionManagementCLIService"),e.IDefaultExtensionsProfileInitService=(0,p.createDecorator)("IDefaultExtensionsProfileInitService")}),define(ye[39],Ce([1,0,25,19,9,10,2,125,3]),function(ee,e,s,p,b,L,C,T,E){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.getPlatformLimits=e.Arch=e.ByteSize=e.FALLBACK_MAX_MEMORY_SIZE_MB=e.MIN_MAX_MEMORY_SIZE_MB=e.whenProviderRegistered=e.etag=e.ETAG_DISABLED=e.FileKind=e.FILES_EXCLUDE_CONFIG=e.FILES_ASSOCIATIONS_CONFIG=e.HotExitConfiguration=e.AutoSaveConfiguration=e.FileOperationResult=e.NotModifiedSinceFileOperationError=e.FileOperationError=e.isParent=e.FileChangesEvent=e.FileChangeType=e.FileOperationEvent=e.FileOperation=e.toFileOperationResult=e.toFileSystemProviderErrorCode=e.markAsFileSystemProviderError=e.ensureFileSystemProviderError=e.createFileSystemProviderError=e.FileSystemProviderError=e.FileSystemProviderErrorCode=e.hasFileAtomicReadCapability=e.hasFileReadStreamCapability=e.hasOpenReadWriteCloseCapability=e.hasFileCloneCapability=e.hasFileFolderCopyCapability=e.hasReadWriteCapability=e.FileSystemProviderCapabilities=e.FilePermission=e.FileType=e.isFileOpenForWriteOptions=e.IFileService=void 0,e.IFileService=(0,E.createDecorator)("fileService");function A(V){return V.create===!0}e.isFileOpenForWriteOptions=A;var R;(function(V){V[V.Unknown=0]="Unknown",V[V.File=1]="File",V[V.Directory=2]="Directory",V[V.SymbolicLink=64]="SymbolicLink"})(R=e.FileType||(e.FileType={}));var y;(function(V){V[V.Readonly=1]="Readonly"})(y=e.FilePermission||(e.FilePermission={}));var m;(function(V){V[V.FileReadWrite=2]="FileReadWrite",V[V.FileOpenReadWriteClose=4]="FileOpenReadWriteClose",V[V.FileReadStream=16]="FileReadStream",V[V.FileFolderCopy=8]="FileFolderCopy",V[V.PathCaseSensitive=1024]="PathCaseSensitive",V[V.Readonly=2048]="Readonly",V[V.Trash=4096]="Trash",V[V.FileWriteUnlock=8192]="FileWriteUnlock",V[V.FileAtomicRead=16384]="FileAtomicRead",V[V.FileClone=32768]="FileClone"})(m=e.FileSystemProviderCapabilities||(e.FileSystemProviderCapabilities={}));function I(V){return!!(V.capabilities&2)}e.hasReadWriteCapability=I;function f(V){return!!(V.capabilities&8)}e.hasFileFolderCopyCapability=f;function h(V){return!!(V.capabilities&32768)}e.hasFileCloneCapability=h;function d(V){return!!(V.capabilities&4)}e.hasOpenReadWriteCloseCapability=d;function a(V){return!!(V.capabilities&16)}e.hasFileReadStreamCapability=a;function w(V){return I(V)?!!(V.capabilities&16384):!1}e.hasFileAtomicReadCapability=w;var P;(function(V){V.FileExists="EntryExists",V.FileNotFound="EntryNotFound",V.FileNotADirectory="EntryNotADirectory",V.FileIsADirectory="EntryIsADirectory",V.FileExceedsMemoryLimit="EntryExceedsMemoryLimit",V.FileTooLarge="EntryTooLarge",V.FileWriteLocked="EntryWriteLocked",V.NoPermissions="NoPermissions",V.Unavailable="Unavailable",V.Unknown="Unknown"})(P=e.FileSystemProviderErrorCode||(e.FileSystemProviderErrorCode={}));class l extends Error{constructor(F,ne){super(F);this.code=ne}}e.FileSystemProviderError=l;function _(V,F){const ne=new l(V.toString(),F);return u(ne,F),ne}e.createFileSystemProviderError=_;function n(V){return V||_((0,T.localize)(0,null),P.Unknown)}e.ensureFileSystemProviderError=n;function u(V,F){return V.name=F?`${F} (FileSystemError)`:"FileSystemError",V}e.markAsFileSystemProviderError=u;function i(V){if(!V)return P.Unknown;if(V instanceof l)return V.code;const F=/^(.+) \(FileSystemError\)$/.exec(V.name);if(!F)return P.Unknown;switch(F[1]){case P.FileExists:return P.FileExists;case P.FileIsADirectory:return P.FileIsADirectory;case P.FileNotADirectory:return P.FileNotADirectory;case P.FileNotFound:return P.FileNotFound;case P.FileExceedsMemoryLimit:return P.FileExceedsMemoryLimit;case P.FileTooLarge:return P.FileTooLarge;case P.FileWriteLocked:return P.FileWriteLocked;case P.NoPermissions:return P.NoPermissions;case P.Unavailable:return P.Unavailable}return P.Unknown}e.toFileSystemProviderErrorCode=i;function o(V){if(V instanceof D)return V.fileOperationResult;switch(i(V)){case P.FileNotFound:return 1;case P.FileIsADirectory:return 0;case P.FileNotADirectory:return 10;case P.FileWriteLocked:return 5;case P.NoPermissions:return 6;case P.FileExists:return 4;case P.FileExceedsMemoryLimit:return 9;case P.FileTooLarge:return 7;default:return 11}}e.toFileOperationResult=o;var r;(function(V){V[V.CREATE=0]="CREATE",V[V.DELETE=1]="DELETE",V[V.MOVE=2]="MOVE",V[V.COPY=3]="COPY",V[V.WRITE=4]="WRITE"})(r=e.FileOperation||(e.FileOperation={}));class t{constructor(F,ne,ce){this.resource=F,this.operation=ne,this.target=ce}isOperation(F){return this.operation===F}}e.FileOperationEvent=t;var c;(function(V){V[V.UPDATED=0]="UPDATED",V[V.ADDED=1]="ADDED",V[V.DELETED=2]="DELETED"})(c=e.FileChangeType||(e.FileChangeType={}));class v{constructor(F,ne){this.added=void 0,this.updated=void 0,this.deleted=void 0,this.rawChanges=[],this.rawAdded=[],this.rawUpdated=[],this.rawDeleted=[],this.rawChanges=F;const ce=new Map;for(const re of F){const fe=ce.get(re.type);switch(fe?fe.push([re.resource,re]):ce.set(re.type,[[re.resource,re]]),re.type){case 1:this.rawAdded.push(re.resource);break;case 0:this.rawUpdated.push(re.resource);break;case 2:this.rawDeleted.push(re.resource);break}}for(const[re,fe]of ce)switch(re){case 1:this.added=s.TernarySearchTree.forUris(()=>ne),this.added.fill(fe);break;case 0:this.updated=s.TernarySearchTree.forUris(()=>ne),this.updated.fill(fe);break;case 2:this.deleted=s.TernarySearchTree.forUris(()=>ne),this.deleted.fill(fe);break}}contains(F,...ne){return this.doContains(F,{includeChildren:!1},...ne)}affects(F,...ne){return this.doContains(F,{includeChildren:!0},...ne)}doContains(F,ne,...ce){if(!F)return!1;const re=ce.length>0;return!!((!re||ce.includes(1))&&(this.added?.get(F)||ne.includeChildren&&this.added?.findSuperstr(F))||(!re||ce.includes(0))&&(this.updated?.get(F)||ne.includeChildren&&this.updated?.findSuperstr(F))||(!re||ce.includes(2))&&(this.deleted?.findSubstr(F)||ne.includeChildren&&this.deleted?.findSuperstr(F)))}gotAdded(){return!!this.added}gotDeleted(){return!!this.deleted}gotUpdated(){return!!this.updated}}e.FileChangesEvent=v;function g(V,F,ne){return!V||!F||V===F||F.length>V.length?!1:(F.charAt(F.length-1)!==p.sep&&(F+=p.sep),ne?(0,b.startsWithIgnoreCase)(V,F):V.indexOf(F)===0)}e.isParent=g;class D extends Error{constructor(F,ne,ce){super(F);this.fileOperationResult=ne,this.options=ce}}e.FileOperationError=D;class U extends D{constructor(F,ne,ce){super(F,2,ce);this.stat=ne}}e.NotModifiedSinceFileOperationError=U;var W;(function(V){V[V.FILE_IS_DIRECTORY=0]="FILE_IS_DIRECTORY",V[V.FILE_NOT_FOUND=1]="FILE_NOT_FOUND",V[V.FILE_NOT_MODIFIED_SINCE=2]="FILE_NOT_MODIFIED_SINCE",V[V.FILE_MODIFIED_SINCE=3]="FILE_MODIFIED_SINCE",V[V.FILE_MOVE_CONFLICT=4]="FILE_MOVE_CONFLICT",V[V.FILE_WRITE_LOCKED=5]="FILE_WRITE_LOCKED",V[V.FILE_PERMISSION_DENIED=6]="FILE_PERMISSION_DENIED",V[V.FILE_TOO_LARGE=7]="FILE_TOO_LARGE",V[V.FILE_INVALID_PATH=8]="FILE_INVALID_PATH",V[V.FILE_EXCEEDS_MEMORY_LIMIT=9]="FILE_EXCEEDS_MEMORY_LIMIT",V[V.FILE_NOT_DIRECTORY=10]="FILE_NOT_DIRECTORY",V[V.FILE_OTHER_ERROR=11]="FILE_OTHER_ERROR"})(W=e.FileOperationResult||(e.FileOperationResult={})),e.AutoSaveConfiguration={OFF:"off",AFTER_DELAY:"afterDelay",ON_FOCUS_CHANGE:"onFocusChange",ON_WINDOW_CHANGE:"onWindowChange"},e.HotExitConfiguration={OFF:"off",ON_EXIT:"onExit",ON_EXIT_AND_WINDOW_CLOSE:"onExitAndWindowClose"},e.FILES_ASSOCIATIONS_CONFIG="files.associations",e.FILES_EXCLUDE_CONFIG="files.exclude";var M;(function(V){V[V.FILE=0]="FILE",V[V.FOLDER=1]="FOLDER",V[V.ROOT_FOLDER=2]="ROOT_FOLDER"})(M=e.FileKind||(e.FileKind={})),e.ETAG_DISABLED="";function S(V){if(!(typeof V.size!="number"||typeof V.mtime!="number"))return V.mtime.toString(29)+V.size.toString(31)}e.etag=S;async function z(V,F){if(!F.hasProvider(C.URI.from({scheme:V.scheme})))return new Promise(ne=>{const ce=F.onDidChangeFileSystemProviderRegistrations(re=>{re.scheme===V.scheme&&re.added&&(ce.dispose(),ne())})})}e.whenProviderRegistered=z,e.MIN_MAX_MEMORY_SIZE_MB=2048,e.FALLBACK_MAX_MEMORY_SIZE_MB=4096;class ${static formatSize(F){return(0,L.isNumber)(F)||(F=0),F<$.KB?(0,T.localize)(1,null,F.toFixed(0)):F<$.MB?(0,T.localize)(2,null,(F/$.KB).toFixed(2)):F<$.GB?(0,T.localize)(3,null,(F/$.MB).toFixed(2)):F<$.TB?(0,T.localize)(4,null,(F/$.GB).toFixed(2)):(0,T.localize)(5,null,(F/$.TB).toFixed(2))}}e.ByteSize=$,$.KB=1024,$.MB=$.KB*$.KB,$.GB=$.MB*$.KB,$.TB=$.GB*$.KB;var N;(function(V){V[V.IA32=0]="IA32",V[V.OTHER=1]="OTHER"})(N=e.Arch||(e.Arch={}));function K(V){return{maxFileSize:V===0?300*$.MB:16*$.GB,maxHeapSize:V===0?700*$.MB:2*700*$.MB}}e.getPlatformLimits=K}),define(ye[58],Ce([1,0]),function(ee,e){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.ServiceCollection=void 0;class s{constructor(...b){this._entries=new Map;for(const[L,C]of b)this.set(L,C)}set(b,L){const C=this._entries.get(b);return this._entries.set(b,L),C}has(b){return this._entries.has(b)}get(b){return this._entries.get(b)}}e.ServiceCollection=s}),define(ye[147],Ce([1,0,13,11,78,145,3,58]),function(ee,e,s,p,b,L,C,T){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.Trace=e.InstantiationService=void 0;const E=!1;class A extends Error{constructor(f){super("cyclic dependency between services");this.message=f.findCycleSlow()??`UNABLE to detect cycle, dumping graph:
${f.toString()}`}}class R{constructor(f=new T.ServiceCollection,h=!1,d){this._activeInstantiations=new Set,this._services=f,this._strict=h,this._parent=d,this._services.set(C.IInstantiationService,this)}createChild(f){return new R(f,this._strict,this)}invokeFunction(f,...h){const d=m.traceInvocation(f);let a=!1;try{return f({get:P=>{if(a)throw(0,p.illegalState)("service accessor is only valid during the invocation of its target method");const l=this._getOrCreateServiceInstance(P,d);if(!l)throw new Error(`[invokeFunction] unknown service '${P}'`);return l}},...h)}finally{a=!0,d.stop()}}createInstance(f,...h){let d,a;return f instanceof b.SyncDescriptor?(d=m.traceCreation(f.ctor),a=this._createInstance(f.ctor,f.staticArguments.concat(h),d)):(d=m.traceCreation(f),a=this._createInstance(f,h,d)),d.stop(),a}_createInstance(f,h=[],d){const a=C._util.getServiceDependencies(f).sort((l,_)=>l.index-_.index),w=[];for(const l of a){const _=this._getOrCreateServiceInstance(l.id,d);_||this._throwIfStrict(`[createInstance] ${f.name} depends on UNKNOWN service ${l.id}.`,!1),w.push(_)}const P=a.length>0?a[0].index:h.length;if(h.length!==P){console.trace(`[createInstance] First service dependency of ${f.name} at position ${P+1} conflicts with ${h.length} static arguments`);const l=P-h.length;l>0?h=h.concat(new Array(l)):h=h.slice(0,P)}return new f(...[...h,...w])}_setServiceInstance(f,h){if(this._services.get(f)instanceof b.SyncDescriptor)this._services.set(f,h);else if(this._parent)this._parent._setServiceInstance(f,h);else throw new Error("illegalState - setting UNKNOWN service instance")}_getServiceInstanceOrDescriptor(f){const h=this._services.get(f);return!h&&this._parent?this._parent._getServiceInstanceOrDescriptor(f):h}_getOrCreateServiceInstance(f,h){const d=this._getServiceInstanceOrDescriptor(f);return d instanceof b.SyncDescriptor?this._safeCreateAndCacheServiceInstance(f,d,h.branch(f,!0)):(h.branch(f,!1),d)}_safeCreateAndCacheServiceInstance(f,h,d){if(this._activeInstantiations.has(f))throw new Error(`illegal state - RECURSIVELY instantiating service '${f}'`);this._activeInstantiations.add(f);try{return this._createAndCacheServiceInstance(f,h,d)}finally{this._activeInstantiations.delete(f)}}_createAndCacheServiceInstance(f,h,d){const a=new L.Graph(l=>l.id.toString());let w=0;const P=[{id:f,desc:h,_trace:d}];for(;P.length;){const l=P.pop();if(a.lookupOrInsertNode(l),w++>1e3)throw new A(a);for(const _ of C._util.getServiceDependencies(l.desc.ctor)){const n=this._getServiceInstanceOrDescriptor(_.id);if(n||this._throwIfStrict(`[createInstance] ${f} depends on ${_.id} which is NOT registered.`,!0),n instanceof b.SyncDescriptor){const u={id:_.id,desc:n,_trace:l._trace.branch(_.id,!0)};a.insertEdge(l,u),P.push(u)}}}for(;;){const l=a.roots();if(l.length===0){if(!a.isEmpty())throw new A(a);break}for(const{data:_}of l){if(this._getServiceInstanceOrDescriptor(_.id)instanceof b.SyncDescriptor){const u=this._createServiceInstanceWithOwner(_.id,_.desc.ctor,_.desc.staticArguments,_.desc.supportsDelayedInstantiation,_._trace);this._setServiceInstance(_.id,u)}a.removeNode(_)}}return this._getServiceInstanceOrDescriptor(f)}_createServiceInstanceWithOwner(f,h,d=[],a,w){if(this._services.get(f)instanceof b.SyncDescriptor)return this._createServiceInstance(h,d,a,w);if(this._parent)return this._parent._createServiceInstanceWithOwner(f,h,d,a,w);throw new Error(`illegalState - creating UNKNOWN service instance ${h.name}`)}_createServiceInstance(f,h=[],d,a){if(d){const w=new s.IdleValue(()=>this._createInstance(f,h,a));return new Proxy(Object.create(null),{get(P,l){if(l in P)return P[l];const _=w.value;let n=_[l];return typeof n!="function"||(n=n.bind(_),P[l]=n),n},set(P,l,_){return w.value[l]=_,!0}})}else return this._createInstance(f,h,a)}_throwIfStrict(f,h){if(h&&console.warn(f),this._strict)throw new Error(f)}}e.InstantiationService=R;var y;(function(I){I[I.Creation=0]="Creation",I[I.Invocation=1]="Invocation",I[I.Branch=2]="Branch"})(y||(y={}));class m{constructor(f,h){this.type=f,this.name=h,this._start=Date.now(),this._dep=[]}static traceInvocation(f){return E?new m(1,f.name||f.toString().substring(0,42).replace(/\n/g,"")):m._None}static traceCreation(f){return E?new m(0,f.name):m._None}branch(f,h){const d=new m(2,f.toString());return this._dep.push([f,h,d]),d}stop(){const f=Date.now()-this._start;m._totals+=f;let h=!1;function d(w,P){const l=[],_=new Array(w+1).join(" ");for(const[n,u,i]of P._dep)if(u&&i){h=!0,l.push(`${_}CREATES -> ${n}`);const o=d(w+1,i);o&&l.push(o)}else l.push(`${_}uses -> ${n}`);return l.join(`
`)}const a=[`${this.type===0?"CREATE":"CALL"} ${this.name}`,`${d(1,this)}`,`DONE, took ${f.toFixed(2)}ms (grand total ${m._totals.toFixed(2)}ms)`];(f>2||h)&&console.log(a.join(`
`))}}e.Trace=m,m._None=new class extends m{constructor(){super(-1,null)}stop(){}branch(){return this}},m._totals=0}),define(ye[14],Ce([1,0,44,4,7,23,3]),function(ee,e,s,p,b,L,C){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.LogLevelToString=e.parseLogLevel=e.getLogLevel=e.NullLogService=e.AbstractLoggerService=e.LogService=e.MultiplexLogService=e.AdapterLogger=e.ConsoleLogger=e.ConsoleMainLogger=e.AbstractMessageLogger=e.AbstractLogger=e.format=e.log=e.DEFAULT_LOG_LEVEL=e.LogLevel=e.ILoggerService=e.ILogService=void 0,e.ILogService=(0,C.createDecorator)("logService"),e.ILoggerService=(0,C.createDecorator)("loggerService");function T(){return new Date().toISOString()}var E;(function(u){u[u.Trace=0]="Trace",u[u.Debug=1]="Debug",u[u.Info=2]="Info",u[u.Warning=3]="Warning",u[u.Error=4]="Error",u[u.Critical=5]="Critical",u[u.Off=6]="Off"})(E=e.LogLevel||(e.LogLevel={})),e.DEFAULT_LOG_LEVEL=E.Info;function A(u,i,o){switch(i){case E.Trace:u.trace(o);break;case E.Debug:u.debug(o);break;case E.Info:u.info(o);break;case E.Warning:u.warn(o);break;case E.Error:u.error(o);break;case E.Critical:u.critical(o);break;default:throw new Error("Invalid log level")}}e.log=A;function R(u){let i="";for(let o=0;o<u.length;o++){let r=u[o];if(typeof r=="object")try{r=JSON.stringify(r)}catch{}i+=(o>0?" ":"")+r}return i}e.format=R;class y extends b.Disposable{constructor(){super(...arguments);this.level=e.DEFAULT_LOG_LEVEL,this._onDidChangeLogLevel=this._register(new p.Emitter),this.onDidChangeLogLevel=this._onDidChangeLogLevel.event}setLevel(i){this.level!==i&&(this.level=i,this._onDidChangeLogLevel.fire(this.level))}getLevel(){return this.level}}e.AbstractLogger=y;class m extends y{constructor(i){super();this.logAlways=i}checkLogLevel(i){return this.logAlways||this.getLevel()<=i}trace(i,...o){this.checkLogLevel(E.Trace)&&this.log(E.Trace,R([i,...o]))}debug(i,...o){this.checkLogLevel(E.Debug)&&this.log(E.Debug,R([i,...o]))}info(i,...o){this.checkLogLevel(E.Info)&&this.log(E.Info,R([i,...o]))}warn(i,...o){this.checkLogLevel(E.Warning)&&this.log(E.Warning,R([i,...o]))}error(i,...o){if(this.checkLogLevel(E.Error))if(i instanceof Error){const r=Array.prototype.slice.call(arguments);r[0]=i.stack,this.log(E.Error,R(r))}else this.log(E.Error,R([i,...o]))}critical(i,...o){this.checkLogLevel(E.Critical)&&this.log(E.Critical,R([i,...o]))}flush(){}}e.AbstractMessageLogger=m;class I extends y{constructor(i=e.DEFAULT_LOG_LEVEL){super();this.setLevel(i),this.useColors=!L.isWindows}trace(i,...o){this.getLevel()<=E.Trace&&(this.useColors?console.log(`[90m[main ${T()}][0m`,i,...o):console.log(`[main ${T()}]`,i,...o))}debug(i,...o){this.getLevel()<=E.Debug&&(this.useColors?console.log(`[90m[main ${T()}][0m`,i,...o):console.log(`[main ${T()}]`,i,...o))}info(i,...o){this.getLevel()<=E.Info&&(this.useColors?console.log(`[90m[main ${T()}][0m`,i,...o):console.log(`[main ${T()}]`,i,...o))}warn(i,...o){this.getLevel()<=E.Warning&&(this.useColors?console.warn(`[93m[main ${T()}][0m`,i,...o):console.warn(`[main ${T()}]`,i,...o))}error(i,...o){this.getLevel()<=E.Error&&(this.useColors?console.error(`[91m[main ${T()}][0m`,i,...o):console.error(`[main ${T()}]`,i,...o))}critical(i,...o){this.getLevel()<=E.Critical&&(this.useColors?console.error(`[90m[main ${T()}][0m`,i,...o):console.error(`[main ${T()}]`,i,...o))}dispose(){}flush(){}}e.ConsoleMainLogger=I;class f extends y{constructor(i=e.DEFAULT_LOG_LEVEL){super();this.setLevel(i)}trace(i,...o){this.getLevel()<=E.Trace&&console.log("%cTRACE","color: #888",i,...o)}debug(i,...o){this.getLevel()<=E.Debug&&console.log("%cDEBUG","background: #eee; color: #888",i,...o)}info(i,...o){this.getLevel()<=E.Info&&console.log("%c INFO","color: #33f",i,...o)}warn(i,...o){this.getLevel()<=E.Warning&&console.log("%c WARN","color: #993",i,...o)}error(i,...o){this.getLevel()<=E.Error&&console.log("%c ERR","color: #f33",i,...o)}critical(i,...o){this.getLevel()<=E.Critical&&console.log("%cCRITI","background: #f33; color: white",i,...o)}dispose(){}flush(){}}e.ConsoleLogger=f;class h extends y{constructor(i,o=e.DEFAULT_LOG_LEVEL){super();this.adapter=i,this.setLevel(o)}trace(i,...o){this.getLevel()<=E.Trace&&this.adapter.log(E.Trace,[this.extractMessage(i),...o])}debug(i,...o){this.getLevel()<=E.Debug&&this.adapter.log(E.Debug,[this.extractMessage(i),...o])}info(i,...o){this.getLevel()<=E.Info&&this.adapter.log(E.Info,[this.extractMessage(i),...o])}warn(i,...o){this.getLevel()<=E.Warning&&this.adapter.log(E.Warning,[this.extractMessage(i),...o])}error(i,...o){this.getLevel()<=E.Error&&this.adapter.log(E.Error,[this.extractMessage(i),...o])}critical(i,...o){this.getLevel()<=E.Critical&&this.adapter.log(E.Critical,[this.extractMessage(i),...o])}extractMessage(i){return typeof i=="string"?i:(0,s.toErrorMessage)(i,this.getLevel()<=E.Trace)}dispose(){}flush(){}}e.AdapterLogger=h;class d extends y{constructor(i){super();this.logServices=i,i.length&&this.setLevel(i[0].getLevel())}setLevel(i){for(const o of this.logServices)o.setLevel(i);super.setLevel(i)}trace(i,...o){for(const r of this.logServices)r.trace(i,...o)}debug(i,...o){for(const r of this.logServices)r.debug(i,...o)}info(i,...o){for(const r of this.logServices)r.info(i,...o)}warn(i,...o){for(const r of this.logServices)r.warn(i,...o)}error(i,...o){for(const r of this.logServices)r.error(i,...o)}critical(i,...o){for(const r of this.logServices)r.critical(i,...o)}flush(){for(const i of this.logServices)i.flush()}dispose(){for(const i of this.logServices)i.dispose()}}e.MultiplexLogService=d;class a extends b.Disposable{constructor(i){super();this.logger=i,this._register(i)}get onDidChangeLogLevel(){return this.logger.onDidChangeLogLevel}setLevel(i){this.logger.setLevel(i)}getLevel(){return this.logger.getLevel()}trace(i,...o){this.logger.trace(i,...o)}debug(i,...o){this.logger.debug(i,...o)}info(i,...o){this.logger.info(i,...o)}warn(i,...o){this.logger.warn(i,...o)}error(i,...o){this.logger.error(i,...o)}critical(i,...o){this.logger.critical(i,...o)}flush(){this.logger.flush()}}e.LogService=a;class w extends b.Disposable{constructor(i,o){super();this.logLevel=i,this.loggers=new Map,this.logLevelChangeableLoggers=[],this._register(o(r=>{this.logLevel=r,this.logLevelChangeableLoggers.forEach(t=>t.setLevel(r))}))}getLogger(i){return this.loggers.get(i.toString())}createLogger(i,o){let r=this.loggers.get(i.toString());return r||(r=this.doCreateLogger(i,o?.always?E.Trace:this.logLevel,o),this.loggers.set(i.toString(),r),o?.always||this.logLevelChangeableLoggers.push(r)),r}dispose(){this.logLevelChangeableLoggers.splice(0,this.logLevelChangeableLoggers.length),this.loggers.forEach(i=>i.dispose()),this.loggers.clear(),super.dispose()}}e.AbstractLoggerService=w;class P{constructor(){this.onDidChangeLogLevel=new p.Emitter().event}setLevel(i){}getLevel(){return E.Info}trace(i,...o){}debug(i,...o){}info(i,...o){}warn(i,...o){}error(i,...o){}critical(i,...o){}dispose(){}flush(){}}e.NullLogService=P;function l(u){if(u.verbose)return E.Trace;if(typeof u.logLevel=="string"){const i=_(u.logLevel.toLowerCase());if(i!==void 0)return i}return e.DEFAULT_LOG_LEVEL}e.getLogLevel=l;function _(u){switch(u){case"trace":return E.Trace;case"debug":return E.Debug;case"info":return E.Info;case"warn":return E.Warning;case"error":return E.Error;case"critical":return E.Critical;case"off":return E.Off}}e.parseLogLevel=_;function n(u){switch(u){case E.Trace:return"trace";case E.Debug:return"debug";case E.Info:return"info";case E.Warning:return"warn";case E.Error:return"error";case E.Critical:return"critical";case E.Off:return"off"}}e.LogLevelToString=n}),define(ye[80],Ce([1,0,29,126,3]),function(ee,e,s,p,b){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.IMarkerService=e.IMarkerData=e.MarkerSeverity=e.MarkerTag=void 0;var L;(function(E){E[E.Unnecessary=1]="Unnecessary",E[E.Deprecated=2]="Deprecated"})(L=e.MarkerTag||(e.MarkerTag={}));var C;(function(E){E[E.Hint=1]="Hint",E[E.Info=2]="Info",E[E.Warning=4]="Warning",E[E.Error=8]="Error"})(C=e.MarkerSeverity||(e.MarkerSeverity={})),function(E){function A(f,h){return h-f}E.compare=A;const R=Object.create(null);R[E.Error]=(0,p.localize)(0,null),R[E.Warning]=(0,p.localize)(1,null),R[E.Info]=(0,p.localize)(2,null);function y(f){return R[f]||""}E.toString=y;function m(f){switch(f){case s.default.Error:return E.Error;case s.default.Warning:return E.Warning;case s.default.Info:return E.Info;case s.default.Ignore:return E.Hint}}E.fromSeverity=m;function I(f){switch(f){case E.Error:return s.default.Error;case E.Warning:return s.default.Warning;case E.Info:return s.default.Info;case E.Hint:return s.default.Ignore}}E.toSeverity=I}(C=e.MarkerSeverity||(e.MarkerSeverity={}));var T;(function(E){const A="";function R(m){return y(m,!0)}E.makeKey=R;function y(m,I){const f=[A];return m.source?f.push(m.source.replace("\xA6","\\\xA6")):f.push(A),m.code?typeof m.code=="string"?f.push(m.code.replace("\xA6","\\\xA6")):f.push(m.code.value.replace("\xA6","\\\xA6")):f.push(A),m.severity!==void 0&&m.severity!==null?f.push(C.toString(m.severity)):f.push(A),m.message&&I?f.push(m.message.replace("\xA6","\\\xA6")):f.push(A),m.startLineNumber!==void 0&&m.startLineNumber!==null?f.push(m.startLineNumber.toString()):f.push(A),m.startColumn!==void 0&&m.startColumn!==null?f.push(m.startColumn.toString()):f.push(A),m.endLineNumber!==void 0&&m.endLineNumber!==null?f.push(m.endLineNumber.toString()):f.push(A),m.endColumn!==void 0&&m.endColumn!==null?f.push(m.endColumn.toString()):f.push(A),f.push(A),f.join("\xA6")}E.makeKeyOptionalMessage=y})(T=e.IMarkerData||(e.IMarkerData={})),e.IMarkerService=(0,b.createDecorator)("markerService")}),define(ye[148],Ce([1,0,4,29,3]),function(ee,e,s,p,b){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.NoOpProgress=e.NoOpNotification=e.NotificationsFilter=e.NeverShowAgainScope=e.INotificationService=e.Severity=void 0,e.Severity=p.default,e.INotificationService=(0,b.createDecorator)("notificationService");var L;(function(A){A[A.WORKSPACE=0]="WORKSPACE",A[A.PROFILE=1]="PROFILE",A[A.APPLICATION=2]="APPLICATION"})(L=e.NeverShowAgainScope||(e.NeverShowAgainScope={}));var C;(function(A){A[A.OFF=0]="OFF",A[A.SILENT=1]="SILENT",A[A.ERROR=2]="ERROR"})(C=e.NotificationsFilter||(e.NotificationsFilter={}));class T{constructor(){this.progress=new E,this.onDidClose=s.Event.None,this.onDidChangeVisibility=s.Event.None}updateSeverity(R){}updateMessage(R){}updateActions(R){}close(){}}e.NoOpNotification=T;class E{infinite(){}done(){}total(R){}worked(R){}}e.NoOpProgress=E}),define(ye[81],Ce([1,0,7,9,2,3]),function(ee,e,s,p,b,L){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.extractSelection=e.withSelection=e.matchesSomeScheme=e.matchesScheme=e.NullOpenerService=e.IOpenerService=void 0,e.IOpenerService=(0,L.createDecorator)("openerService"),e.NullOpenerService=Object.freeze({_serviceBrand:void 0,registerOpener(){return s.Disposable.None},registerValidator(){return s.Disposable.None},registerExternalUriResolver(){return s.Disposable.None},setDefaultExternalOpener(){},registerExternalOpener(){return s.Disposable.None},async open(){return!1},async resolveExternalUri(R){return{resolved:R,dispose(){}}}});function C(R,y){return b.URI.isUri(R)?(0,p.equalsIgnoreCase)(R.scheme,y):(0,p.startsWithIgnoreCase)(R,y+":")}e.matchesScheme=C;function T(R,...y){return y.some(m=>C(R,m))}e.matchesSomeScheme=T;function E(R,y){return R.with({fragment:`${y.startLineNumber},${y.startColumn}${y.endLineNumber?`-${y.endLineNumber}${y.endColumn?`,${y.endColumn}`:""}`:""}`})}e.withSelection=E;function A(R){let y;const m=/^L?(\d+)(?:,(\d+))?(-L?(\d+)(?:,(\d+))?)?/.exec(R.fragment);return m&&(y={startLineNumber:parseInt(m[1]),startColumn:m[2]?parseInt(m[2]):1,endLineNumber:m[4]?parseInt(m[4]):void 0,endColumn:m[4]?m[5]?parseInt(m[5]):1:void 0},R=R.with({fragment:""})),{selection:y,uri:R}}e.extractSelection=A}),define(ye[149],Ce([1,0,3]),function(ee,e,s){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.productSchemaId=e.IProductService=void 0,e.IProductService=(0,s.createDecorator)("productService"),e.productSchemaId="vscode://schemas/vscode-product"});var ze=this&&this.__decorate||function(ee,e,s,p){var b=arguments.length,L=b<3?e:p===null?p=Object.getOwnPropertyDescriptor(e,s):p,C;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")L=Reflect.decorate(ee,e,s,p);else for(var T=ee.length-1;T>=0;T--)(C=ee[T])&&(L=(b<3?C(L):b>3?C(e,s,L):C(e,s))||L);return b>3&&L&&Object.defineProperty(e,s,L),L},xe=this&&this.__param||function(ee,e){return function(s,p){e(s,p,ee)}};define(ye[150],Ce([1,0,13,20,7,3]),function(ee,e,s,p,b,L){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.IEditorProgressService=e.LongRunningOperation=e.UnmanagedProgress=e.Progress=e.emptyProgressRunner=e.ProgressLocation=e.IProgressService=void 0,e.IProgressService=(0,L.createDecorator)("progressService");var C;(function(R){R[R.Explorer=1]="Explorer",R[R.Scm=3]="Scm",R[R.Extensions=5]="Extensions",R[R.Window=10]="Window",R[R.Notification=15]="Notification",R[R.Dialog=20]="Dialog"})(C=e.ProgressLocation||(e.ProgressLocation={})),e.emptyProgressRunner=Object.freeze({total(){},worked(){},done(){}});class T{constructor(y){this.callback=y}get value(){return this._value}report(y){this._value=y,this.callback(this._value)}}e.Progress=T,T.None=Object.freeze({report(){}});let E=class extends b.Disposable{constructor(y,m){super();this.deferred=new s.DeferredPromise,m.withProgress(y,I=>(this.reporter=I,this.lastStep&&I.report(this.lastStep),this.deferred.p)),this._register((0,b.toDisposable)(()=>this.deferred.complete()))}report(y){this.reporter?this.reporter.report(y):this.lastStep=y}};E=ze([xe(1,e.IProgressService)],E),e.UnmanagedProgress=E;class A extends b.Disposable{constructor(y){super();this.progressIndicator=y,this.currentOperationId=0,this.currentOperationDisposables=this._register(new b.DisposableStore)}start(y){this.stop();const m=++this.currentOperationId,I=new p.CancellationTokenSource;return this.currentProgressTimeout=setTimeout(()=>{m===this.currentOperationId&&(this.currentProgressRunner=this.progressIndicator.show(!0))},y),this.currentOperationDisposables.add((0,b.toDisposable)(()=>clearTimeout(this.currentProgressTimeout))),this.currentOperationDisposables.add((0,b.toDisposable)(()=>I.cancel())),this.currentOperationDisposables.add((0,b.toDisposable)(()=>this.currentProgressRunner?this.currentProgressRunner.done():void 0)),{id:m,token:I.token,stop:()=>this.doStop(m),isCurrent:()=>this.currentOperationId===m}}stop(){this.doStop(this.currentOperationId)}doStop(y){this.currentOperationId===y&&this.currentOperationDisposables.clear()}}e.LongRunningOperation=A,e.IEditorProgressService=(0,L.createDecorator)("editorProgressService")}),define(ye[30],Ce([1,0,42,10]),function(ee,e,s,p){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.Registry=void 0;class b{constructor(){this.data=new Map}add(C,T){s.ok(p.isString(C)),s.ok(p.isObject(T)),s.ok(!this.data.has(C),"There is already an extension with this id"),this.data.set(C,T)}knows(C){return this.data.has(C)}as(C){return this.data.get(C)||null}}e.Registry=new b}),define(ye[82],Ce([1,0,4,30]),function(ee,e,s,p){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.Extensions=void 0,e.Extensions={JSONContribution:"base.contributions.json"};function b(T){return T.length>0&&T.charAt(T.length-1)==="#"?T.substring(0,T.length-1):T}class L{constructor(){this._onDidChangeSchema=new s.Emitter,this.onDidChangeSchema=this._onDidChangeSchema.event,this.schemasById={}}registerSchema(E,A){this.schemasById[b(E)]=A,this._onDidChangeSchema.fire(E)}notifySchemaChanged(E){this._onDidChangeSchema.fire(E)}getSchemaContributions(){return{schemas:this.schemasById}}}const C=new L;p.Registry.add(e.Extensions.JSONContribution,C)}),define(ye[83],Ce([1,0,16,4,10,122,57,82,30]),function(ee,e,s,p,b,L,C,T,E){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.getScopes=e.validateProperty=e.getDefaultValue=e.keyFromOverrideIdentifiers=e.overrideIdentifiersFromKey=e.OVERRIDE_PROPERTY_REGEX=e.OVERRIDE_PROPERTY_PATTERN=e.configurationDefaultsSchemaId=e.resourceLanguageSettingsSchemaId=e.resourceSettings=e.windowSettings=e.machineOverridableSettings=e.machineSettings=e.applicationSettings=e.allSettings=e.ConfigurationScope=e.Extensions=e.EditPresentationTypes=void 0;var A;(function(_){_.Multiline="multilineText",_.Singleline="singlelineText"})(A=e.EditPresentationTypes||(e.EditPresentationTypes={})),e.Extensions={Configuration:"base.contributions.configuration"};var R;(function(_){_[_.APPLICATION=1]="APPLICATION",_[_.MACHINE=2]="MACHINE",_[_.WINDOW=3]="WINDOW",_[_.RESOURCE=4]="RESOURCE",_[_.LANGUAGE_OVERRIDABLE=5]="LANGUAGE_OVERRIDABLE",_[_.MACHINE_OVERRIDABLE=6]="MACHINE_OVERRIDABLE"})(R=e.ConfigurationScope||(e.ConfigurationScope={})),e.allSettings={properties:{},patternProperties:{}},e.applicationSettings={properties:{},patternProperties:{}},e.machineSettings={properties:{},patternProperties:{}},e.machineOverridableSettings={properties:{},patternProperties:{}},e.windowSettings={properties:{},patternProperties:{}},e.resourceSettings={properties:{},patternProperties:{}},e.resourceLanguageSettingsSchemaId="vscode://schemas/settings/resourceLanguage",e.configurationDefaultsSchemaId="vscode://schemas/settings/configurationDefaults";const y=E.Registry.as(T.Extensions.JSONContribution);class m{constructor(){this.overrideIdentifiers=new Set,this._onDidSchemaChange=new p.Emitter,this.onDidSchemaChange=this._onDidSchemaChange.event,this._onDidUpdateConfiguration=new p.Emitter,this.onDidUpdateConfiguration=this._onDidUpdateConfiguration.event,this.configurationDefaultsOverrides=new Map,this.defaultLanguageConfigurationOverridesNode={id:"defaultOverrides",title:L.localize(0,null),properties:{}},this.configurationContributors=[this.defaultLanguageConfigurationOverridesNode],this.resourceLanguageSettingsSchema={properties:{},patternProperties:{},additionalProperties:!1,errorMessage:"Unknown editor configuration setting",allowTrailingCommas:!0,allowComments:!0},this.configurationProperties={},this.policyConfigurations=new Map,this.excludedConfigurationProperties={},y.registerSchema(e.resourceLanguageSettingsSchemaId,this.resourceLanguageSettingsSchema),this.registerOverridePropertyPatternKey()}registerConfiguration(n,u=!0){this.registerConfigurations([n],u)}registerConfigurations(n,u=!0){const i=this.doRegisterConfigurations(n,u);y.registerSchema(e.resourceLanguageSettingsSchemaId,this.resourceLanguageSettingsSchema),this._onDidSchemaChange.fire(),this._onDidUpdateConfiguration.fire({properties:i})}deregisterConfigurations(n){const u=this.doDeregisterConfigurations(n);y.registerSchema(e.resourceLanguageSettingsSchemaId,this.resourceLanguageSettingsSchema),this._onDidSchemaChange.fire(),this._onDidUpdateConfiguration.fire({properties:u})}updateConfigurations({add:n,remove:u}){const i=[];i.push(...this.doDeregisterConfigurations(u)),i.push(...this.doRegisterConfigurations(n,!1)),y.registerSchema(e.resourceLanguageSettingsSchemaId,this.resourceLanguageSettingsSchema),this._onDidSchemaChange.fire(),this._onDidUpdateConfiguration.fire({properties:(0,s.distinct)(i)})}registerDefaultConfigurations(n){const u=[],i=[];for(const{overrides:o,source:r}of n)for(const t in o)if(u.push(t),e.OVERRIDE_PROPERTY_REGEX.test(t)){const c=this.configurationDefaultsOverrides.get(t),v=c?.valuesSources??new Map;if(r)for(const W of Object.keys(o[t]))v.set(W,r);const g={...c?.value||{},...o[t]};this.configurationDefaultsOverrides.set(t,{source:r,value:g,valuesSources:v});const D=(0,C.getLanguageTagSettingPlainKey)(t),U={type:"object",default:g,description:L.localize(1,null,D),$ref:e.resourceLanguageSettingsSchemaId,defaultDefaultValue:g,source:b.isString(r)?void 0:r,defaultValueSource:r};i.push(...h(t)),this.configurationProperties[t]=U,this.defaultLanguageConfigurationOverridesNode.properties[t]=U}else{this.configurationDefaultsOverrides.set(t,{value:o[t],source:r});const c=this.configurationProperties[t];c&&(this.updatePropertyDefaultValue(t,c),this.updateSchema(t,c))}this.registerOverrideIdentifiers(i),this._onDidSchemaChange.fire(),this._onDidUpdateConfiguration.fire({properties:u,defaultsOverrides:!0})}deregisterDefaultConfigurations(n){const u=[];for(const{overrides:i,source:o}of n)for(const r in i){const t=this.configurationDefaultsOverrides.get(r),c=b.isString(o)?o:o?.id,v=b.isString(t?.source)?t?.source:t?.source?.id;if(c===v)if(u.push(r),this.configurationDefaultsOverrides.delete(r),e.OVERRIDE_PROPERTY_REGEX.test(r))delete this.configurationProperties[r],delete this.defaultLanguageConfigurationOverridesNode.properties[r];else{const g=this.configurationProperties[r];g&&(this.updatePropertyDefaultValue(r,g),this.updateSchema(r,g))}}this.updateOverridePropertyPatternKey(),this._onDidSchemaChange.fire(),this._onDidUpdateConfiguration.fire({properties:u,defaultsOverrides:!0})}notifyConfigurationSchemaUpdated(...n){this._onDidSchemaChange.fire()}registerOverrideIdentifiers(n){for(const u of n)this.overrideIdentifiers.add(u);this.updateOverridePropertyPatternKey()}doRegisterConfigurations(n,u){const i=[];return n.forEach(o=>{i.push(...this.validateAndRegisterProperties(o,u,o.extensionInfo,o.restrictedProperties)),this.configurationContributors.push(o),this.registerJSONConfiguration(o)}),i}doDeregisterConfigurations(n){const u=[],i=o=>{if(o.properties)for(const r in o.properties){u.push(r);const t=this.configurationProperties[r];t?.policy?.name&&this.policyConfigurations.delete(t.policy.name),delete this.configurationProperties[r],this.removeFromSchema(r,o.properties[r])}o.allOf?.forEach(r=>i(r))};for(const o of n){i(o);const r=this.configurationContributors.indexOf(o);r!==-1&&this.configurationContributors.splice(r,1)}return u}validateAndRegisterProperties(n,u=!0,i,o,r=3){r=b.isUndefinedOrNull(n.scope)?r:n.scope;const t=[],c=n.properties;if(c)for(const g in c){const D=c[g];if(u&&P(g,D)){delete c[g];continue}if(D.source=i,D.defaultDefaultValue=c[g].default,this.updatePropertyDefaultValue(g,D),e.OVERRIDE_PROPERTY_REGEX.test(g)?D.scope=void 0:(D.scope=b.isUndefinedOrNull(D.scope)?r:D.scope,D.restricted=b.isUndefinedOrNull(D.restricted)?!!o?.includes(g):D.restricted),c[g].hasOwnProperty("included")&&!c[g].included){this.excludedConfigurationProperties[g]=c[g],delete c[g];continue}else this.configurationProperties[g]=c[g],c[g].policy?.name&&this.policyConfigurations.set(c[g].policy.name,g);!c[g].deprecationMessage&&c[g].markdownDeprecationMessage&&(c[g].deprecationMessage=c[g].markdownDeprecationMessage),t.push(g)}const v=n.allOf;if(v)for(const g of v)t.push(...this.validateAndRegisterProperties(g,u,i,o,r));return t}getConfigurations(){return this.configurationContributors}getConfigurationProperties(){return this.configurationProperties}getPolicyConfigurations(){return this.policyConfigurations}getExcludedConfigurationProperties(){return this.excludedConfigurationProperties}getConfigurationDefaultsOverrides(){return this.configurationDefaultsOverrides}registerJSONConfiguration(n){const u=i=>{const o=i.properties;if(o)for(const t in o)this.updateSchema(t,o[t]);i.allOf?.forEach(u)};u(n)}updateSchema(n,u){switch(e.allSettings.properties[n]=u,u.scope){case 1:e.applicationSettings.properties[n]=u;break;case 2:e.machineSettings.properties[n]=u;break;case 6:e.machineOverridableSettings.properties[n]=u;break;case 3:e.windowSettings.properties[n]=u;break;case 4:e.resourceSettings.properties[n]=u;break;case 5:e.resourceSettings.properties[n]=u,this.resourceLanguageSettingsSchema.properties[n]=u;break}}removeFromSchema(n,u){switch(delete e.allSettings.properties[n],u.scope){case 1:delete e.applicationSettings.properties[n];break;case 2:delete e.machineSettings.properties[n];break;case 6:delete e.machineOverridableSettings.properties[n];break;case 3:delete e.windowSettings.properties[n];break;case 4:case 5:delete e.resourceSettings.properties[n],delete this.resourceLanguageSettingsSchema.properties[n];break}}updateOverridePropertyPatternKey(){for(const n of this.overrideIdentifiers.values()){const u=`[${n}]`,i={type:"object",description:L.localize(2,null),errorMessage:L.localize(3,null),$ref:e.resourceLanguageSettingsSchemaId};this.updatePropertyDefaultValue(u,i),e.allSettings.properties[u]=i,e.applicationSettings.properties[u]=i,e.machineSettings.properties[u]=i,e.machineOverridableSettings.properties[u]=i,e.windowSettings.properties[u]=i,e.resourceSettings.properties[u]=i}this._onDidSchemaChange.fire()}registerOverridePropertyPatternKey(){const n={type:"object",description:L.localize(4,null),errorMessage:L.localize(5,null),$ref:e.resourceLanguageSettingsSchemaId};e.allSettings.patternProperties[e.OVERRIDE_PROPERTY_PATTERN]=n,e.applicationSettings.patternProperties[e.OVERRIDE_PROPERTY_PATTERN]=n,e.machineSettings.patternProperties[e.OVERRIDE_PROPERTY_PATTERN]=n,e.machineOverridableSettings.patternProperties[e.OVERRIDE_PROPERTY_PATTERN]=n,e.windowSettings.patternProperties[e.OVERRIDE_PROPERTY_PATTERN]=n,e.resourceSettings.patternProperties[e.OVERRIDE_PROPERTY_PATTERN]=n,this._onDidSchemaChange.fire()}updatePropertyDefaultValue(n,u){const i=this.configurationDefaultsOverrides.get(n);let o=i?.value,r=i?.source;b.isUndefined(o)&&(o=u.defaultDefaultValue,r=void 0),b.isUndefined(o)&&(o=a(u.type)),u.default=o,u.defaultValueSource=r}}const I="\\[([^\\]]+)\\]",f=new RegExp(I,"g");e.OVERRIDE_PROPERTY_PATTERN=`^(${I})+$`,e.OVERRIDE_PROPERTY_REGEX=new RegExp(e.OVERRIDE_PROPERTY_PATTERN);function h(_){const n=[];if(e.OVERRIDE_PROPERTY_REGEX.test(_)){let u=f.exec(_);for(;u?.length;){const i=u[1].trim();i&&n.push(i),u=f.exec(_)}}return(0,s.distinct)(n)}e.overrideIdentifiersFromKey=h;function d(_){return _.reduce((n,u)=>`${n}[${u}]`,"")}e.keyFromOverrideIdentifiers=d;function a(_){switch(Array.isArray(_)?_[0]:_){case"boolean":return!1;case"integer":case"number":return 0;case"string":return"";case"array":return[];case"object":return{};default:return null}}e.getDefaultValue=a;const w=new m;E.Registry.add(e.Extensions.Configuration,w);function P(_,n){return _.trim()?e.OVERRIDE_PROPERTY_REGEX.test(_)?L.localize(7,null,_):w.getConfigurationProperties()[_]!==void 0?L.localize(8,null,_):n.policy?.name&&w.getPolicyConfigurations().get(n.policy?.name)!==void 0?L.localize(9,null,_,n.policy?.name,w.getPolicyConfigurations().get(n.policy?.name)):null:L.localize(6,null)}e.validateProperty=P;function l(){const _=[],n=w.getConfigurationProperties();for(const u of Object.keys(n))_.push([u,n[u].scope]);return _.push(["launch",4]),_.push(["task",4]),_}e.getScopes=l}),define(ye[151],Ce([1,0,16,4,104,7,25,26,10,2,57,83,30]),function(ee,e,s,p,b,L,C,T,E,A,R,y,m){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.AllKeysConfigurationChangeEvent=e.ConfigurationChangeEvent=e.mergeChanges=e.Configuration=e.UserSettings=e.ConfigurationModelParser=e.ConfigurationModel=void 0;class I{constructor(u={},i=[],o=[]){this._contents=u,this._keys=i,this._overrides=o,this.frozen=!1,this.overrideConfigurations=new Map}get contents(){return this.checkAndFreeze(this._contents)}get overrides(){return this.checkAndFreeze(this._overrides)}get keys(){return this.checkAndFreeze(this._keys)}isEmpty(){return this._keys.length===0&&Object.keys(this._contents).length===0&&this._overrides.length===0}isFrozen(){return this.frozen}getValue(u){return u?(0,R.getConfigurationValue)(this.contents,u):this.contents}getOverrideValue(u,i){const o=this.getContentsForOverrideIdentifer(i);return o?u?(0,R.getConfigurationValue)(o,u):o:void 0}getKeysForOverrideIdentifier(u){const i=[];for(const o of this.overrides)o.identifiers.includes(u)&&i.push(...o.keys);return s.distinct(i)}getAllOverrideIdentifiers(){const u=[];for(const i of this.overrides)u.push(...i.identifiers);return s.distinct(u)}override(u){let i=this.overrideConfigurations.get(u);return i||(i=this.createOverrideConfigurationModel(u),this.overrideConfigurations.set(u,i)),i}merge(...u){const i=T.deepClone(this.contents),o=T.deepClone(this.overrides),r=[...this.keys];for(const t of u)if(!t.isEmpty()){this.mergeContents(i,t.contents);for(const c of t.overrides){const[v]=o.filter(g=>s.equals(g.identifiers,c.identifiers));v?(this.mergeContents(v.contents,c.contents),v.keys.push(...c.keys),v.keys=s.distinct(v.keys)):o.push(T.deepClone(c))}for(const c of t.keys)r.indexOf(c)===-1&&r.push(c)}return new I(i,r,o)}freeze(){return this.frozen=!0,this}clone(){return new I(T.deepClone(this.contents),[...this.keys],T.deepClone(this.overrides))}createOverrideConfigurationModel(u){const i=this.getContentsForOverrideIdentifer(u);if(!i||typeof i!="object"||!Object.keys(i).length)return this;const o={};for(const r of s.distinct([...Object.keys(this.contents),...Object.keys(i)])){let t=this.contents[r];const c=i[r];c&&(typeof t=="object"&&typeof c=="object"?(t=T.deepClone(t),this.mergeContents(t,c)):t=c),o[r]=t}return new I(o,this.keys,this.overrides)}mergeContents(u,i){for(const o of Object.keys(i)){if(o in u&&E.isObject(u[o])&&E.isObject(i[o])){this.mergeContents(u[o],i[o]);continue}u[o]=T.deepClone(i[o])}}checkAndFreeze(u){return this.frozen&&!Object.isFrozen(u)?T.deepFreeze(u):u}getContentsForOverrideIdentifer(u){let i=null,o=null;const r=t=>{t&&(o?this.mergeContents(o,t):o=T.deepClone(t))};for(const t of this.overrides)s.equals(t.identifiers,[u])?i=t.contents:t.identifiers.includes(u)&&r(t.contents);return r(i),o}toJSON(){return{contents:this.contents,overrides:this.overrides,keys:this.keys}}setValue(u,i){this.addKey(u),(0,R.addToValueTree)(this.contents,u,i,o=>{throw new Error(o)})}removeValue(u){this.removeKey(u)&&(0,R.removeFromValueTree)(this.contents,u)}addKey(u){let i=this.keys.length;for(let o=0;o<i;o++)u.indexOf(this.keys[o])===0&&(i=o);this.keys.splice(i,1,u)}removeKey(u){const i=this.keys.indexOf(u);return i!==-1?(this.keys.splice(i,1),!0):!1}}e.ConfigurationModel=I;class f{constructor(u){this._name=u,this._raw=null,this._configurationModel=null,this._restrictedConfigurations=[],this._parseErrors=[]}get configurationModel(){return this._configurationModel||new I}get restrictedConfigurations(){return this._restrictedConfigurations}get errors(){return this._parseErrors}parse(u,i){if(!E.isUndefinedOrNull(u)){const o=this.doParseContent(u);this.parseRaw(o,i)}}reparse(u){this._raw&&this.parseRaw(this._raw,u)}parseRaw(u,i){this._raw=u;const{contents:o,keys:r,overrides:t,restricted:c}=this.doParseRaw(u,i);this._configurationModel=new I(o,r,t),this._restrictedConfigurations=c||[]}doParseContent(u){let i={},o=null,r=[];const t=[],c=[];function v(D){Array.isArray(r)?r.push(D):o!==null&&(r[o]=D)}const g={onObjectBegin:()=>{const D={};v(D),t.push(r),r=D,o=null},onObjectProperty:D=>{o=D},onObjectEnd:()=>{r=t.pop()},onArrayBegin:()=>{const D=[];v(D),t.push(r),r=D,o=null},onArrayEnd:()=>{r=t.pop()},onLiteralValue:v,onError:(D,U,W)=>{c.push({error:D,offset:U,length:W})}};if(u)try{b.visit(u,g),i=r[0]||{}}catch(D){console.error(`Error while parsing settings file ${this._name}: ${D}`),this._parseErrors=[D]}return i}doParseRaw(u,i){const o=m.Registry.as(y.Extensions.Configuration).getConfigurationProperties(),r=this.filter(u,o,!0,i);u=r.raw;const t=(0,R.toValuesTree)(u,g=>console.error(`Conflict in settings file ${this._name}: ${g}`)),c=Object.keys(u),v=this.toOverrides(u,g=>console.error(`Conflict in settings file ${this._name}: ${g}`));return{contents:t,keys:c,overrides:v,restricted:r.restricted}}filter(u,i,o,r){if(!r?.scopes&&!r?.skipRestricted)return{raw:u,restricted:[]};const t={},c=[];for(const v in u)if(y.OVERRIDE_PROPERTY_REGEX.test(v)&&o){const g=this.filter(u[v],i,!1,r);t[v]=g.raw,c.push(...g.restricted)}else{const g=i[v],D=g?typeof g.scope!="undefined"?g.scope:3:void 0;g?.restricted&&c.push(v),(D===void 0||r.scopes===void 0||r.scopes.includes(D))&&(r.skipRestricted&&g?.restricted||(t[v]=u[v]))}return{raw:t,restricted:c}}toOverrides(u,i){const o=[];for(const r of Object.keys(u))if(y.OVERRIDE_PROPERTY_REGEX.test(r)){const t={};for(const c in u[r])t[c]=u[r][c];o.push({identifiers:(0,y.overrideIdentifiersFromKey)(r),keys:Object.keys(t),contents:(0,R.toValuesTree)(t,i)})}return o}}e.ConfigurationModelParser=f;class h extends L.Disposable{constructor(u,i,o,r){super();this.userSettingsResource=u,this.scopes=i,this.fileService=r,this._onDidChange=this._register(new p.Emitter),this.onDidChange=this._onDidChange.event,this.parser=new f(this.userSettingsResource.toString()),this.parseOptions={scopes:this.scopes},this._register(this.fileService.watch(o.dirname(this.userSettingsResource))),this._register(this.fileService.watch(this.userSettingsResource)),this._register(p.Event.any(p.Event.filter(this.fileService.onDidFilesChange,t=>t.contains(this.userSettingsResource)),p.Event.filter(this.fileService.onDidRunOperation,t=>(t.isOperation(0)||t.isOperation(3)||t.isOperation(1)||t.isOperation(4))&&o.isEqual(t.resource,u)))(()=>this._onDidChange.fire()))}async loadConfiguration(){try{const u=await this.fileService.readFile(this.userSettingsResource);return this.parser.parse(u.value.toString()||"{}",this.parseOptions),this.parser.configurationModel}catch{return new I}}reparse(){return this.parser.reparse(this.parseOptions),this.parser.configurationModel}getRestrictedSettings(){return this.parser.restrictedConfigurations}}e.UserSettings=h;class d{constructor(u,i,o,r,t=new I,c=new I,v=new C.ResourceMap,g=new I,D=new C.ResourceMap,U=!0){this._defaultConfiguration=u,this._policyConfiguration=i,this._applicationConfiguration=o,this._localUserConfiguration=r,this._remoteUserConfiguration=t,this._workspaceConfiguration=c,this._folderConfigurations=v,this._memoryConfiguration=g,this._memoryConfigurationByResource=D,this._freeze=U,this._workspaceConsolidatedConfiguration=null,this._foldersConsolidatedConfigurations=new C.ResourceMap,this._userConfiguration=null}getValue(u,i,o){return this.getConsolidatedConfigurationModel(u,i,o).getValue(u)}updateValue(u,i,o={}){let r;o.resource?(r=this._memoryConfigurationByResource.get(o.resource),r||(r=new I,this._memoryConfigurationByResource.set(o.resource,r))):r=this._memoryConfiguration,i===void 0?r.removeValue(u):r.setValue(u,i),o.resource||(this._workspaceConsolidatedConfiguration=null)}inspect(u,i,o){const r=this.getConsolidatedConfigurationModel(u,i,o),t=this.getFolderConfigurationModelForResource(i.resource,o),c=i.resource?this._memoryConfigurationByResource.get(i.resource)||this._memoryConfiguration:this._memoryConfiguration,v=i.overrideIdentifier?this._defaultConfiguration.freeze().override(i.overrideIdentifier).getValue(u):this._defaultConfiguration.freeze().getValue(u),g=this._policyConfiguration.isEmpty()?void 0:this._policyConfiguration.freeze().getValue(u),D=this.applicationConfiguration.isEmpty()?void 0:this.applicationConfiguration.freeze().getValue(u),U=i.overrideIdentifier?this.userConfiguration.freeze().override(i.overrideIdentifier).getValue(u):this.userConfiguration.freeze().getValue(u),W=i.overrideIdentifier?this.localUserConfiguration.freeze().override(i.overrideIdentifier).getValue(u):this.localUserConfiguration.freeze().getValue(u),M=i.overrideIdentifier?this.remoteUserConfiguration.freeze().override(i.overrideIdentifier).getValue(u):this.remoteUserConfiguration.freeze().getValue(u),S=o?i.overrideIdentifier?this._workspaceConfiguration.freeze().override(i.overrideIdentifier).getValue(u):this._workspaceConfiguration.freeze().getValue(u):void 0,z=t?i.overrideIdentifier?t.freeze().override(i.overrideIdentifier).getValue(u):t.freeze().getValue(u):void 0,$=i.overrideIdentifier?c.override(i.overrideIdentifier).getValue(u):c.getValue(u),N=r.getValue(u),K=s.distinct(r.overrides.map(V=>V.identifiers).flat()).filter(V=>r.getOverrideValue(u,V)!==void 0);return{defaultValue:v,policyValue:g,applicationValue:D,userValue:U,userLocalValue:W,userRemoteValue:M,workspaceValue:S,workspaceFolderValue:z,memoryValue:$,value:N,default:v!==void 0?{value:this._defaultConfiguration.freeze().getValue(u),override:i.overrideIdentifier?this._defaultConfiguration.freeze().getOverrideValue(u,i.overrideIdentifier):void 0}:void 0,policy:g!==void 0?{value:g}:void 0,application:D!==void 0?{value:D,override:i.overrideIdentifier?this.applicationConfiguration.freeze().getOverrideValue(u,i.overrideIdentifier):void 0}:void 0,user:U!==void 0?{value:this.userConfiguration.freeze().getValue(u),override:i.overrideIdentifier?this.userConfiguration.freeze().getOverrideValue(u,i.overrideIdentifier):void 0}:void 0,userLocal:W!==void 0?{value:this.localUserConfiguration.freeze().getValue(u),override:i.overrideIdentifier?this.localUserConfiguration.freeze().getOverrideValue(u,i.overrideIdentifier):void 0}:void 0,userRemote:M!==void 0?{value:this.remoteUserConfiguration.freeze().getValue(u),override:i.overrideIdentifier?this.remoteUserConfiguration.freeze().getOverrideValue(u,i.overrideIdentifier):void 0}:void 0,workspace:S!==void 0?{value:this._workspaceConfiguration.freeze().getValue(u),override:i.overrideIdentifier?this._workspaceConfiguration.freeze().getOverrideValue(u,i.overrideIdentifier):void 0}:void 0,workspaceFolder:z!==void 0?{value:t?.freeze().getValue(u),override:i.overrideIdentifier?t?.freeze().getOverrideValue(u,i.overrideIdentifier):void 0}:void 0,memory:$!==void 0?{value:c.getValue(u),override:i.overrideIdentifier?c.getOverrideValue(u,i.overrideIdentifier):void 0}:void 0,overrideIdentifiers:K.length?K:void 0}}keys(u){const i=this.getFolderConfigurationModelForResource(void 0,u);return{default:this._defaultConfiguration.freeze().keys,user:this.userConfiguration.freeze().keys,workspace:this._workspaceConfiguration.freeze().keys,workspaceFolder:i?i.freeze().keys:[]}}updateDefaultConfiguration(u){this._defaultConfiguration=u,this._workspaceConsolidatedConfiguration=null,this._foldersConsolidatedConfigurations.clear()}updatePolicyConfiguration(u){this._policyConfiguration=u}updateApplicationConfiguration(u){this._applicationConfiguration=u,this._workspaceConsolidatedConfiguration=null,this._foldersConsolidatedConfigurations.clear()}updateLocalUserConfiguration(u){this._localUserConfiguration=u,this._userConfiguration=null,this._workspaceConsolidatedConfiguration=null,this._foldersConsolidatedConfigurations.clear()}updateRemoteUserConfiguration(u){this._remoteUserConfiguration=u,this._userConfiguration=null,this._workspaceConsolidatedConfiguration=null,this._foldersConsolidatedConfigurations.clear()}updateWorkspaceConfiguration(u){this._workspaceConfiguration=u,this._workspaceConsolidatedConfiguration=null,this._foldersConsolidatedConfigurations.clear()}updateFolderConfiguration(u,i){this._folderConfigurations.set(u,i),this._foldersConsolidatedConfigurations.delete(u)}deleteFolderConfiguration(u){this.folderConfigurations.delete(u),this._foldersConsolidatedConfigurations.delete(u)}compareAndUpdateDefaultConfiguration(u,i){const o=[];if(!i){const{added:r,updated:t,removed:c}=l(this._defaultConfiguration,u);i=[...r,...t,...c]}for(const r of i)for(const t of(0,y.overrideIdentifiersFromKey)(r)){const c=this._defaultConfiguration.getKeysForOverrideIdentifier(t),v=u.getKeysForOverrideIdentifier(t),g=[...v.filter(D=>c.indexOf(D)===-1),...c.filter(D=>v.indexOf(D)===-1),...c.filter(D=>!T.equals(this._defaultConfiguration.override(t).getValue(D),u.override(t).getValue(D)))];o.push([t,g])}return this.updateDefaultConfiguration(u),{keys:i,overrides:o}}compareAndUpdatePolicyConfiguration(u){const{added:i,updated:o,removed:r}=l(this._policyConfiguration,u),t=[...i,...o,...r];return t.length&&this.updatePolicyConfiguration(u),{keys:t,overrides:[]}}compareAndUpdateApplicationConfiguration(u){const{added:i,updated:o,removed:r,overrides:t}=l(this.applicationConfiguration,u),c=[...i,...o,...r];return c.length&&this.updateApplicationConfiguration(u),{keys:c,overrides:t}}compareAndUpdateLocalUserConfiguration(u){const{added:i,updated:o,removed:r,overrides:t}=l(this.localUserConfiguration,u),c=[...i,...o,...r];return c.length&&this.updateLocalUserConfiguration(u),{keys:c,overrides:t}}compareAndUpdateRemoteUserConfiguration(u){const{added:i,updated:o,removed:r,overrides:t}=l(this.remoteUserConfiguration,u),c=[...i,...o,...r];return c.length&&this.updateRemoteUserConfiguration(u),{keys:c,overrides:t}}compareAndUpdateWorkspaceConfiguration(u){const{added:i,updated:o,removed:r,overrides:t}=l(this.workspaceConfiguration,u),c=[...i,...o,...r];return c.length&&this.updateWorkspaceConfiguration(u),{keys:c,overrides:t}}compareAndUpdateFolderConfiguration(u,i){const o=this.folderConfigurations.get(u),{added:r,updated:t,removed:c,overrides:v}=l(o,i),g=[...r,...t,...c];return(g.length||!o)&&this.updateFolderConfiguration(u,i),{keys:g,overrides:v}}compareAndDeleteFolderConfiguration(u){const i=this.folderConfigurations.get(u);if(!i)throw new Error("Unknown folder");this.deleteFolderConfiguration(u);const{added:o,updated:r,removed:t,overrides:c}=l(i,void 0);return{keys:[...o,...r,...t],overrides:c}}get defaults(){return this._defaultConfiguration}get applicationConfiguration(){return this._applicationConfiguration}get userConfiguration(){return this._userConfiguration||(this._userConfiguration=this._remoteUserConfiguration.isEmpty()?this._localUserConfiguration:this._localUserConfiguration.merge(this._remoteUserConfiguration),this._freeze&&this._userConfiguration.freeze()),this._userConfiguration}get localUserConfiguration(){return this._localUserConfiguration}get remoteUserConfiguration(){return this._remoteUserConfiguration}get workspaceConfiguration(){return this._workspaceConfiguration}get folderConfigurations(){return this._folderConfigurations}getConsolidatedConfigurationModel(u,i,o){let r=this.getConsolidatedConfigurationModelForResource(i,o);return i.overrideIdentifier&&(r=r.override(i.overrideIdentifier)),!this._policyConfiguration.isEmpty()&&this._policyConfiguration.getValue(u)!==void 0&&(r=r.merge(this._policyConfiguration)),r}getConsolidatedConfigurationModelForResource({resource:u},i){let o=this.getWorkspaceConsolidatedConfiguration();if(i&&u){const r=i.getFolder(u);r&&(o=this.getFolderConsolidatedConfiguration(r.uri)||o);const t=this._memoryConfigurationByResource.get(u);t&&(o=o.merge(t))}return o}getWorkspaceConsolidatedConfiguration(){return this._workspaceConsolidatedConfiguration||(this._workspaceConsolidatedConfiguration=this._defaultConfiguration.merge(this.applicationConfiguration,this.userConfiguration,this._workspaceConfiguration,this._memoryConfiguration),this._freeze&&(this._workspaceConfiguration=this._workspaceConfiguration.freeze())),this._workspaceConsolidatedConfiguration}getFolderConsolidatedConfiguration(u){let i=this._foldersConsolidatedConfigurations.get(u);if(!i){const o=this.getWorkspaceConsolidatedConfiguration(),r=this._folderConfigurations.get(u);r?(i=o.merge(r),this._freeze&&(i=i.freeze()),this._foldersConsolidatedConfigurations.set(u,i)):i=o}return i}getFolderConfigurationModelForResource(u,i){if(i&&u){const o=i.getFolder(u);if(o)return this._folderConfigurations.get(o.uri)}}toData(){return{defaults:{contents:this._defaultConfiguration.contents,overrides:this._defaultConfiguration.overrides,keys:this._defaultConfiguration.keys},policy:{contents:this._policyConfiguration.contents,overrides:this._policyConfiguration.overrides,keys:this._policyConfiguration.keys},application:{contents:this.applicationConfiguration.contents,overrides:this.applicationConfiguration.overrides,keys:this.applicationConfiguration.keys},user:{contents:this.userConfiguration.contents,overrides:this.userConfiguration.overrides,keys:this.userConfiguration.keys},workspace:{contents:this._workspaceConfiguration.contents,overrides:this._workspaceConfiguration.overrides,keys:this._workspaceConfiguration.keys},folders:[...this._folderConfigurations.keys()].reduce((u,i)=>{const{contents:o,overrides:r,keys:t}=this._folderConfigurations.get(i);return u.push([i,{contents:o,overrides:r,keys:t}]),u},[])}}allKeys(){const u=new Set;return this._defaultConfiguration.freeze().keys.forEach(i=>u.add(i)),this.userConfiguration.freeze().keys.forEach(i=>u.add(i)),this._workspaceConfiguration.freeze().keys.forEach(i=>u.add(i)),this._folderConfigurations.forEach(i=>i.freeze().keys.forEach(o=>u.add(o))),[...u.values()]}allOverrideIdentifiers(){const u=new Set;return this._defaultConfiguration.freeze().getAllOverrideIdentifiers().forEach(i=>u.add(i)),this.userConfiguration.freeze().getAllOverrideIdentifiers().forEach(i=>u.add(i)),this._workspaceConfiguration.freeze().getAllOverrideIdentifiers().forEach(i=>u.add(i)),this._folderConfigurations.forEach(i=>i.freeze().getAllOverrideIdentifiers().forEach(o=>u.add(o))),[...u.values()]}getAllKeysForOverrideIdentifier(u){const i=new Set;return this._defaultConfiguration.getKeysForOverrideIdentifier(u).forEach(o=>i.add(o)),this.userConfiguration.getKeysForOverrideIdentifier(u).forEach(o=>i.add(o)),this._workspaceConfiguration.getKeysForOverrideIdentifier(u).forEach(o=>i.add(o)),this._folderConfigurations.forEach(o=>o.getKeysForOverrideIdentifier(u).forEach(r=>i.add(r))),[...i.values()]}static parse(u){const i=this.parseConfigurationModel(u.defaults),o=this.parseConfigurationModel(u.policy),r=this.parseConfigurationModel(u.application),t=this.parseConfigurationModel(u.user),c=this.parseConfigurationModel(u.workspace),v=u.folders.reduce((g,D)=>(g.set(A.URI.revive(D[0]),this.parseConfigurationModel(D[1])),g),new C.ResourceMap);return new d(i,o,r,t,new I,c,v,new I,new C.ResourceMap,!1)}static parseConfigurationModel(u){return new I(u.contents,u.keys,u.overrides).freeze()}}e.Configuration=d;function a(...n){if(n.length===0)return{keys:[],overrides:[]};if(n.length===1)return n[0];const u=new Set,i=new Map;for(const r of n)r.keys.forEach(t=>u.add(t)),r.overrides.forEach(([t,c])=>{const v=(0,C.getOrSet)(i,t,new Set);c.forEach(g=>v.add(g))});const o=[];return i.forEach((r,t)=>o.push([t,[...r.values()]])),{keys:[...u.values()],overrides:o}}e.mergeChanges=a;class w{constructor(u,i,o,r){this.change=u,this.previous=i,this.currentConfiguraiton=o,this.currentWorkspace=r,this._previousConfiguration=void 0;const t=new Set;u.keys.forEach(v=>t.add(v)),u.overrides.forEach(([,v])=>v.forEach(g=>t.add(g))),this.affectedKeys=[...t.values()];const c=new I;this.affectedKeys.forEach(v=>c.setValue(v,{})),this.affectedKeysTree=c.contents}get previousConfiguration(){return!this._previousConfiguration&&this.previous&&(this._previousConfiguration=d.parse(this.previous.data)),this._previousConfiguration}affectsConfiguration(u,i){if(this.doesAffectedKeysTreeContains(this.affectedKeysTree,u)){if(i){const o=this.previousConfiguration?this.previousConfiguration.getValue(u,i,this.previous?.workspace):void 0,r=this.currentConfiguraiton.getValue(u,i,this.currentWorkspace);return!T.equals(o,r)}return!0}return!1}doesAffectedKeysTreeContains(u,i){let o=(0,R.toValuesTree)({[i]:!0},()=>{}),r;for(;typeof o=="object"&&(r=Object.keys(o)[0]);){if(u=u[r],!u)return!1;o=o[r]}return!0}}e.ConfigurationChangeEvent=w;class P extends w{constructor(u,i,o,r){super({keys:u.allKeys(),overrides:[]},void 0,u,i);this.source=o,this.sourceConfig=r}}e.AllKeysConfigurationChangeEvent=P;function l(n,u){const{added:i,removed:o,updated:r}=_(u,n),t=[],c=n?.getAllOverrideIdentifiers()||[],v=u?.getAllOverrideIdentifiers()||[];if(u){const g=v.filter(D=>!c.includes(D));for(const D of g)t.push([D,u.getKeysForOverrideIdentifier(D)])}if(n){const g=c.filter(D=>!v.includes(D));for(const D of g)t.push([D,n.getKeysForOverrideIdentifier(D)])}if(u&&n){for(const g of c)if(v.includes(g)){const D=_({contents:n.getOverrideValue(void 0,g)||{},keys:n.getKeysForOverrideIdentifier(g)},{contents:u.getOverrideValue(void 0,g)||{},keys:u.getKeysForOverrideIdentifier(g)});t.push([g,[...D.added,...D.removed,...D.updated]])}}return{added:i,removed:o,updated:r,overrides:t}}function _(n,u){const i=n?u?n.keys.filter(t=>u.keys.indexOf(t)===-1):[...n.keys]:[],o=u?n?u.keys.filter(t=>n.keys.indexOf(t)===-1):[...u.keys]:[],r=[];if(n&&u){for(const t of u.keys)if(n.keys.indexOf(t)!==-1){const c=(0,R.getConfigurationValue)(u.contents,t),v=(0,R.getConfigurationValue)(n.contents,t);T.equals(c,v)||r.push(t)}}return{added:i,removed:o,updated:r}}}),define(ye[84],Ce([1,0,11,3]),function(ee,e,s,p){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.RemoteAuthorityResolverError=e.RemoteAuthorityResolverErrorCode=e.IRemoteAuthorityResolverService=void 0,e.IRemoteAuthorityResolverService=(0,p.createDecorator)("remoteAuthorityResolverService");var b;(function(C){C.Unknown="Unknown",C.NotAvailable="NotAvailable",C.TemporarilyNotAvailable="TemporarilyNotAvailable",C.NoResolverFound="NoResolverFound"})(b=e.RemoteAuthorityResolverErrorCode||(e.RemoteAuthorityResolverErrorCode={}));class L extends s.ErrorNoTelemetry{constructor(T,E=b.Unknown,A){super(T);this._message=T,this._code=E,this._detail=A,this.isHandled=E===b.NotAvailable&&A===!0,typeof Object.setPrototypeOf=="function"&&Object.setPrototypeOf(this,L.prototype)}static isTemporarilyNotAvailable(T){return T instanceof L&&T._code===b.TemporarilyNotAvailable}static isNoResolverFound(T){return T instanceof L&&T._code===b.NoResolverFound}static isHandled(T){return T instanceof L&&T.isHandled}}e.RemoteAuthorityResolverError=L}),define(ye[85],Ce([1,0,12]),function(ee,e,s){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.parseAuthorityWithOptionalPort=e.parseAuthorityWithPort=e.getRemoteServerRootPath=e.getRemoteName=e.getRemoteAuthority=void 0;function p(A){return A.scheme===s.Schemas.vscodeRemote?A.authority:void 0}e.getRemoteAuthority=p;function b(A){if(!A)return;const R=A.indexOf("+");return R<0?A:A.substr(0,R)}e.getRemoteName=b;function L(A){return`/${A.quality??"oss"}-${A.commit??"dev"}`}e.getRemoteServerRootPath=L;function C(A){const{host:R,port:y}=E(A);if(typeof y=="undefined")throw new Error("Remote authority doesn't contain a port!");return{host:R,port:y}}e.parseAuthorityWithPort=C;function T(A,R){let{host:y,port:m}=E(A);return typeof m=="undefined"&&(m=R),{host:y,port:m}}e.parseAuthorityWithOptionalPort=T;function E(A){const R=A.match(/^(\[[0-9a-z:]+\]):(\d+)$/);if(R)return{host:R[1],port:parseInt(R[2],10)};const y=A.match(/^(\[[0-9a-z:]+\])$/);if(y)return{host:y[1],port:void 0};const m=A.match(/(.*):(\d+)$/);return m?{host:m[1],port:parseInt(m[2],10)}:{host:A,port:void 0}}}),define(ye[27],Ce([1,0,9,3,85]),function(ee,e,s,p,b){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.IBuiltinExtensionsScannerService=e.isResolverExtension=e.isAuthenticationProviderExtension=e.isLanguagePackExtension=e.isApplicationScopedExtension=e.ExtensionIdentifier=e.TargetPlatform=e.ExtensionType=e.EXTENSION_CATEGORIES=e.isIExtensionIdentifier=e.getWorkspaceSupportTypeMessage=e.ALL_EXTENSION_KINDS=e.UNDEFINED_PUBLISHER=e.BUILTIN_MANIFEST_CACHE_FILE=e.USER_MANIFEST_CACHE_FILE=e.MANIFEST_CACHE_FOLDER=void 0,e.MANIFEST_CACHE_FOLDER="CachedExtensions",e.USER_MANIFEST_CACHE_FILE="user",e.BUILTIN_MANIFEST_CACHE_FILE="builtin",e.UNDEFINED_PUBLISHER="undefined_publisher",e.ALL_EXTENSION_KINDS=["ui","workspace","web"];function L(f){if(typeof f=="object"&&f!==null&&f.supported!==!0)return f.description}e.getWorkspaceSupportTypeMessage=L;function C(f){return f&&typeof f=="object"&&typeof f.id=="string"&&(!f.uuid||typeof f.uuid=="string")}e.isIExtensionIdentifier=C,e.EXTENSION_CATEGORIES=["Azure","Data Science","Debuggers","Extension Packs","Education","Formatters","Keymaps","Language Packs","Linters","Machine Learning","Notebooks","Programming Languages","SCM Providers","Snippets","Testing","Themes","Visualization","Other"];var T;(function(f){f[f.System=0]="System",f[f.User=1]="User"})(T=e.ExtensionType||(e.ExtensionType={}));var E;(function(f){f.WIN32_X64="win32-x64",f.WIN32_IA32="win32-ia32",f.WIN32_ARM64="win32-arm64",f.LINUX_X64="linux-x64",f.LINUX_ARM64="linux-arm64",f.LINUX_ARMHF="linux-armhf",f.ALPINE_X64="alpine-x64",f.ALPINE_ARM64="alpine-arm64",f.DARWIN_X64="darwin-x64",f.DARWIN_ARM64="darwin-arm64",f.WEB="web",f.UNIVERSAL="universal",f.UNKNOWN="unknown",f.UNDEFINED="undefined"})(E=e.TargetPlatform||(e.TargetPlatform={}));class A{constructor(h){this.value=h,this._lower=h.toLowerCase()}static equals(h,d){if(typeof h=="undefined"||h===null)return typeof d=="undefined"||d===null;if(typeof d=="undefined"||d===null)return!1;if(typeof h=="string"||typeof d=="string"){const a=typeof h=="string"?h:h.value,w=typeof d=="string"?d:d.value;return s.equalsIgnoreCase(a,w)}return h._lower===d._lower}static toKey(h){return typeof h=="string"?h.toLowerCase():h._lower}}e.ExtensionIdentifier=A;function R(f){return y(f)}e.isApplicationScopedExtension=R;function y(f){return f.contributes&&f.contributes.localizations?f.contributes.localizations.length>0:!1}e.isLanguagePackExtension=y;function m(f){return f.contributes&&f.contributes.authentication?f.contributes.authentication.length>0:!1}e.isAuthenticationProviderExtension=m;function I(f,h){if(h){const d=`onResolveRemoteAuthority:${(0,b.getRemoteName)(h)}`;return f.activationEvents?.indexOf(d)!==-1}return!1}e.isResolverExtension=I,e.IBuiltinExtensionsScannerService=(0,p.createDecorator)("IBuiltinExtensionsScannerService")}),define(ye[152],Ce([1,0,9,79,27,23,2,11,59]),function(ee,e,s,p,b,L,C,T,E){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.computeTargetPlatform=e.isAlpineLinux=e.getExtensionDependencies=e.BetterMergeId=e.getGalleryExtensionTelemetryData=e.getLocalExtensionTelemetryData=e.groupByExtension=e.getGalleryExtensionId=e.adoptToGalleryExtensionId=e.getExtensionId=e.getIdAndVersion=e.ExtensionKey=e.areSameExtensions=void 0;function A(u,i){return u.uuid&&i.uuid?u.uuid===i.uuid:u.id===i.id?!0:(0,s.compareIgnoreCase)(u.id,i.id)===0}e.areSameExtensions=A;const R=/^([^.]+\..+)-(\d+\.\d+\.\d+)(-(.+))?$/;class y{constructor(i,o,r="undefined"){this.version=o,this.targetPlatform=r,this.id=i.id}static create(i){const o=i.manifest?i.manifest.version:i.version,r=i.manifest?i.targetPlatform:i.properties.targetPlatform;return new y(i.identifier,o,r)}static parse(i){const o=R.exec(i);return o&&o[1]&&o[2]?new y({id:o[1]},o[2],o[4]||void 0):null}toString(){return`${this.id}-${this.version}${this.targetPlatform!=="undefined"?`-${this.targetPlatform}`:""}`}equals(i){return i instanceof y?A(this,i)&&this.version===i.version&&this.targetPlatform===i.targetPlatform:!1}}e.ExtensionKey=y;const m=/^([^.]+\..+)@((prerelease)|(\d+\.\d+\.\d+(-.*)?))$/;function I(u){const i=m.exec(u);return i&&i[1]?[h(i[1]),i[2]]:[h(u),void 0]}e.getIdAndVersion=I;function f(u,i){return`${u}.${i}`}e.getExtensionId=f;function h(u){return u.toLocaleLowerCase()}e.adoptToGalleryExtensionId=h;function d(u,i){return h(f(u,i))}e.getGalleryExtensionId=d;function a(u,i){const o=[],r=t=>{for(const c of o)if(c.some(v=>A(i(v),i(t))))return c;return null};for(const t of u){const c=r(t);c?c.push(t):o.push([t])}return o}e.groupByExtension=a;function w(u){return{id:u.identifier.id,name:u.manifest.name,galleryId:null,publisherId:u.publisherId,publisherName:u.manifest.publisher,publisherDisplayName:u.publisherDisplayName,dependencies:u.manifest.extensionDependencies&&u.manifest.extensionDependencies.length>0}}e.getLocalExtensionTelemetryData=w;function P(u){return{id:u.identifier.id,name:u.name,galleryId:u.identifier.uuid,publisherId:u.publisherId,publisherName:u.publisher,publisherDisplayName:u.publisherDisplayName,isPreReleaseVersion:u.properties.isPreReleaseVersion,dependencies:!!(u.properties.dependencies&&u.properties.dependencies.length>0),...u.telemetryData}}e.getGalleryExtensionTelemetryData=P,e.BetterMergeId=new b.ExtensionIdentifier("pprice.better-merge");function l(u,i){const o=[],r=i.manifest.extensionDependencies?.slice(0)??[];for(;r.length;){const t=r.shift();if(t&&o.every(c=>!A(c.identifier,{id:t}))){const c=u.filter(v=>A(v.identifier,{id:t}));c.length===1&&(o.push(c[0]),r.push(...c[0].manifest.extensionDependencies?.slice(0)??[]))}}return o}e.getExtensionDependencies=l;async function _(u,i){if(!L.isLinux)return!1;let o;try{o=(await u.readFile(C.URI.file("/etc/os-release"))).value.toString()}catch{try{o=(await u.readFile(C.URI.file("/usr/lib/os-release"))).value.toString()}catch(t){i.debug("Error while getting the os-release file.",(0,T.getErrorMessage)(t))}}return!!o&&(o.match(/^ID=([^\u001b\r\n]*)/m)||[])[1]==="alpine"}e.isAlpineLinux=_;async function n(u,i){const o=await _(u,i),r=(0,p.getTargetPlatform)(o?"alpine":L.platform,E.arch);return i.debug("ComputeTargetPlatform:",r),r}e.computeTargetPlatform=n}),define(ye[153],Ce([1,0]),function(ee,e){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.TerminalDataBufferer=void 0;class s{constructor(b){this._callback=b,this._terminalBufferMap=new Map}dispose(){for(const b of this._terminalBufferMap.values())b.dispose()}startBuffering(b,L,C=5){const T=L(E=>{const A=typeof E=="string"?E:E.data;let R=this._terminalBufferMap.get(b);if(R){R.data.push(A);return}const y=setTimeout(()=>this.flushBuffer(b),C);R={data:[A],timeoutId:y,dispose:()=>{clearTimeout(y),this.flushBuffer(b),T.dispose()}},this._terminalBufferMap.set(b,R)});return T}stopBuffering(b){const L=this._terminalBufferMap.get(b);L&&L.dispose()}flushBuffer(b){const L=this._terminalBufferMap.get(b);L&&(this._terminalBufferMap.delete(b),this._callback(b,L.data.join("")))}}e.TerminalDataBufferer=s}),define(ye[154],Ce([1,0]),function(ee,e){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.isDark=e.isHighContrast=e.ColorScheme=void 0;var s;(function(L){L.DARK="dark",L.LIGHT="light",L.HIGH_CONTRAST_DARK="hcDark",L.HIGH_CONTRAST_LIGHT="hcLight"})(s=e.ColorScheme||(e.ColorScheme={}));function p(L){return L===s.HIGH_CONTRAST_DARK||L===s.HIGH_CONTRAST_LIGHT}e.isHighContrast=p;function b(L){return L===s.DARK||L===s.HIGH_CONTRAST_DARK}e.isDark=b}),define(ye[60],Ce([1,0,110,4,7,3,30,154]),function(ee,e,s,p,b,L,C,T){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.Themable=e.registerThemingParticipant=e.Extensions=e.getThemeTypeSelector=e.FolderThemeIcon=e.FileThemeIcon=e.ThemeIcon=e.themeColorFromId=e.ThemeColor=e.IThemeService=void 0,e.IThemeService=(0,L.createDecorator)("themeService");var E;(function(d){function a(w){return w&&typeof w=="object"&&typeof w.id=="string"}d.isThemeColor=a})(E=e.ThemeColor||(e.ThemeColor={}));function A(d){return{id:d}}e.themeColorFromId=A;var R;(function(d){function a(o){return o&&typeof o=="object"&&typeof o.id=="string"&&(typeof o.color=="undefined"||E.isThemeColor(o.color))}d.isThemeIcon=a;const w=new RegExp(`^\\$\\((${s.CSSIcon.iconNameExpression}(?:${s.CSSIcon.iconModifierExpression})?)\\)$`);function P(o){const r=w.exec(o);if(!r)return;const[,t]=r;return{id:t}}d.fromString=P;function l(o){return{id:o}}d.fromId=l;function _(o,r){let t=o.id;const c=t.lastIndexOf("~");return c!==-1&&(t=t.substring(0,c)),r&&(t=`${t}~${r}`),{id:t}}d.modify=_;function n(o){const r=o.id.lastIndexOf("~");if(r!==-1)return o.id.substring(r+1)}d.getModifier=n;function u(o,r){return o.id===r.id&&o.color?.id===r.color?.id}d.isEqual=u;function i(o,r){return{id:o.id,color:r?A(r):void 0}}d.asThemeIcon=i,d.asClassNameArray=s.CSSIcon.asClassNameArray,d.asClassName=s.CSSIcon.asClassName,d.asCSSSelector=s.CSSIcon.asCSSSelector})(R=e.ThemeIcon||(e.ThemeIcon={})),e.FileThemeIcon=s.Codicon.file,e.FolderThemeIcon=s.Codicon.folder;function y(d){switch(d){case T.ColorScheme.DARK:return"vs-dark";case T.ColorScheme.HIGH_CONTRAST_DARK:return"hc-black";case T.ColorScheme.HIGH_CONTRAST_LIGHT:return"hc-light";default:return"vs"}}e.getThemeTypeSelector=y,e.Extensions={ThemingContribution:"base.contributions.theming"};class m{constructor(){this.themingParticipants=[],this.themingParticipants=[],this.onThemingParticipantAddedEmitter=new p.Emitter}onColorThemeChange(a){return this.themingParticipants.push(a),this.onThemingParticipantAddedEmitter.fire(a),(0,b.toDisposable)(()=>{const w=this.themingParticipants.indexOf(a);this.themingParticipants.splice(w,1)})}get onThemingParticipantAdded(){return this.onThemingParticipantAddedEmitter.event}getThemingParticipants(){return this.themingParticipants}}const I=new m;C.Registry.add(e.Extensions.ThemingContribution,I);function f(d){return I.onColorThemeChange(d)}e.registerThemingParticipant=f;class h extends b.Disposable{constructor(a){super();this.themeService=a,this.theme=a.getColorTheme(),this._register(this.themeService.onDidColorThemeChange(w=>this.onThemeChange(w)))}onThemeChange(a){this.theme=a,this.updateStyles()}updateStyles(){}getColor(a,w){let P=this.theme.getColor(a);return P&&w&&(P=w(P,this.theme)),P?P.toString():null}}e.Themable=h}),define(ye[155],Ce([1,0,4,23,3,14]),function(ee,e,s,p,b,L){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.AbstractTunnelService=e.DisposableTunnel=e.isPortPrivileged=e.isAllInterfaces=e.ALL_INTERFACES_ADDRESSES=e.isLocalhost=e.LOCALHOST_ADDRESSES=e.extractLocalHostUriMetaDataForPortMapping=e.ProvidedOnAutoForward=e.TunnelPrivacyId=e.TunnelProtocol=e.ISharedTunnelsService=e.ITunnelService=void 0,e.ITunnelService=(0,b.createDecorator)("tunnelService"),e.ISharedTunnelsService=(0,b.createDecorator)("sharedTunnelsService");var C;(function(h){h.Http="http",h.Https="https"})(C=e.TunnelProtocol||(e.TunnelProtocol={}));var T;(function(h){h.ConstantPrivate="constantPrivate",h.Private="private",h.Public="public"})(T=e.TunnelPrivacyId||(e.TunnelPrivacyId={}));var E;(function(h){h[h.Notify=1]="Notify",h[h.OpenBrowser=2]="OpenBrowser",h[h.OpenPreview=3]="OpenPreview",h[h.Silent=4]="Silent",h[h.Ignore=5]="Ignore",h[h.OpenBrowserOnce=6]="OpenBrowserOnce"})(E=e.ProvidedOnAutoForward||(e.ProvidedOnAutoForward={}));function A(h){if(h.scheme!=="http"&&h.scheme!=="https")return;const d=/^(localhost|127\.0\.0\.1|0\.0\.0\.0):(\d+)$/.exec(h.authority);if(!!d)return{address:d[1],port:+d[2]}}e.extractLocalHostUriMetaDataForPortMapping=A,e.LOCALHOST_ADDRESSES=["localhost","127.0.0.1","0:0:0:0:0:0:0:1","::1"];function R(h){return e.LOCALHOST_ADDRESSES.indexOf(h)>=0}e.isLocalhost=R,e.ALL_INTERFACES_ADDRESSES=["0.0.0.0","0:0:0:0:0:0:0:0","::"];function y(h){return e.ALL_INTERFACES_ADDRESSES.indexOf(h)>=0}e.isAllInterfaces=y;function m(h,d){return d?d!==1&&h<1024:!p.isWindows&&h<1024}e.isPortPrivileged=m;class I{constructor(d,a,w){this.remoteAddress=d,this.localAddress=a,this._dispose=w,this._onDispose=new s.Emitter,this.onDidDispose=this._onDispose.event}dispose(){return this._onDispose.fire(),this._dispose()}}e.DisposableTunnel=I;let f=class{constructor(d){this.logService=d,this._onTunnelOpened=new s.Emitter,this.onTunnelOpened=this._onTunnelOpened.event,this._onTunnelClosed=new s.Emitter,this.onTunnelClosed=this._onTunnelClosed.event,this._onAddedTunnelProvider=new s.Emitter,this.onAddedTunnelProvider=this._onAddedTunnelProvider.event,this._tunnels=new Map,this._canElevate=!1,this._privacyOptions=[],this._factoryInProgress=new Set}get hasTunnelProvider(){return!!this._tunnelProvider}setTunnelProvider(d){return this._tunnelProvider=d,d?(this._onAddedTunnelProvider.fire(),{dispose:()=>{this._tunnelProvider=void 0,this._canElevate=!1,this._privacyOptions=[]}}):(this._canElevate=!1,this._privacyOptions=[],this._onAddedTunnelProvider.fire(),{dispose:()=>{}})}setTunnelFeatures(d){this._canElevate=d.elevation,this._privacyOptions=d.privacyOptions}get canElevate(){return this._canElevate}get canChangePrivacy(){return this._privacyOptions.length>0}get privacyOptions(){return this._privacyOptions}get tunnels(){return this.getTunnels()}async getTunnels(){const d=[],a=Array.from(this._tunnels.values());for(const w of a){const P=Array.from(w.values());for(const l of P){const _=await l.value;_&&d.push(_)}}return d}async dispose(){for(const d of this._tunnels.values()){for(const{value:a}of d.values())await a.then(w=>w?.dispose());d.clear()}this._tunnels.clear()}openTunnel(d,a,w,P,l=!1,_,n){if(this.logService.trace(`ForwardedPorts: (TunnelService) openTunnel request for ${a}:${w} on local port ${P}.`),!d)return;if(a||(a="localhost"),this._tunnelProvider&&this._factoryInProgress.has(w)){this.logService.debug("ForwardedPorts: (TunnelService) Another call to create a tunnel with the same address has occurred before the last one completed. This call will be ignored.");return}const u=this.retainOrCreateTunnel(d,a,w,P,l,_,n);return u?u.then(i=>{if(!i){this.logService.trace("ForwardedPorts: (TunnelService) New tunnel is undefined."),this.removeEmptyTunnelFromMap(a,w);return}this.logService.trace("ForwardedPorts: (TunnelService) New tunnel established.");const o=this.makeTunnel(i);return(i.tunnelRemoteHost!==a||i.tunnelRemotePort!==w)&&this.logService.warn("ForwardedPorts: (TunnelService) Created tunnel does not match requirements of requested tunnel. Host or port mismatch."),this._onTunnelOpened.fire(o),o}):(this.logService.trace("ForwardedPorts: (TunnelService) Tunnel was not created."),u)}makeTunnel(d){return{tunnelRemotePort:d.tunnelRemotePort,tunnelRemoteHost:d.tunnelRemoteHost,tunnelLocalPort:d.tunnelLocalPort,localAddress:d.localAddress,privacy:d.privacy,protocol:d.protocol,dispose:async()=>{this.logService.trace(`ForwardedPorts: (TunnelService) dispose request for ${d.tunnelRemoteHost}:${d.tunnelRemotePort} `);const a=this._tunnels.get(d.tunnelRemoteHost);if(a){const w=a.get(d.tunnelRemotePort);w&&(w.refcount--,await this.tryDisposeTunnel(d.tunnelRemoteHost,d.tunnelRemotePort,w))}}}}async tryDisposeTunnel(d,a,w){if(w.refcount<=0){this.logService.trace(`ForwardedPorts: (TunnelService) Tunnel is being disposed ${d}:${a}.`);const P=w.value.then(async l=>{l&&(await l.dispose(!0),this._onTunnelClosed.fire({host:l.tunnelRemoteHost,port:l.tunnelRemotePort}))});return this._tunnels.has(d)&&this._tunnels.get(d).delete(a),P}}async closeTunnel(d,a){this.logService.trace(`ForwardedPorts: (TunnelService) close request for ${d}:${a} `);const w=this._tunnels.get(d);if(w&&w.has(a)){const P=w.get(a);P.refcount=0,await this.tryDisposeTunnel(d,a,P)}}addTunnelToMap(d,a,w){this._tunnels.has(d)||this._tunnels.set(d,new Map),this._tunnels.get(d).set(a,{refcount:1,value:w})}async removeEmptyTunnelFromMap(d,a){const w=this._tunnels.get(d);w&&(await w.get(a)||w.delete(a),w.size===0&&this._tunnels.delete(d))}getTunnelFromMap(d,a){const w=[d];R(d)?(w.push(...e.LOCALHOST_ADDRESSES),w.push(...e.ALL_INTERFACES_ADDRESSES)):y(d)&&w.push(...e.ALL_INTERFACES_ADDRESSES);const P=w.map(l=>this._tunnels.get(l));for(const l of P){const _=l?.get(a);if(_)return _}}canTunnel(d){return!!A(d)}createWithProvider(d,a,w,P,l,_,n){this.logService.trace(`ForwardedPorts: (TunnelService) Creating tunnel with provider ${a}:${w} on local port ${P}.`);const u=w;this._factoryInProgress.add(u);const o={elevationRequired:l?m(P===void 0?w:P):!1},r={remoteAddress:{host:a,port:w},localAddressPort:P,privacy:_,public:_?_!==T.Private:void 0,protocol:n},t=d.forwardPort(r,o);return t?(this.addTunnelToMap(a,w,t),t.finally(()=>{this.logService.trace("ForwardedPorts: (TunnelService) Tunnel created by provider."),this._factoryInProgress.delete(u)})):this._factoryInProgress.delete(u),t}};f=ze([xe(0,L.ILogService)],f),e.AbstractTunnelService=f}),define(ye[156],Ce([1,0,12]),function(ee,e,s){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.isVirtualWorkspace=e.getVirtualWorkspaceAuthority=e.getVirtualWorkspaceScheme=e.getVirtualWorkspaceLocation=e.isVirtualResource=void 0;function p(E){return E.scheme!==s.Schemas.file&&E.scheme!==s.Schemas.vscodeRemote}e.isVirtualResource=p;function b(E){if(E.folders.length)return E.folders.every(A=>p(A.uri))?E.folders[0].uri:void 0;if(E.configuration&&p(E.configuration))return E.configuration}e.getVirtualWorkspaceLocation=b;function L(E){return b(E)?.scheme}e.getVirtualWorkspaceScheme=L;function C(E){return b(E)?.authority}e.getVirtualWorkspaceAuthority=C;function T(E){return b(E)!==void 0}e.isVirtualWorkspace=T}),define(ye[45],Ce([1,0,127,19,25,21,2,3,12]),function(ee,e,s,p,b,L,C,T,E){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.hasWorkspaceFileExtension=e.isSavedWorkspace=e.isTemporaryWorkspace=e.isUntitledWorkspace=e.UNTITLED_WORKSPACE_NAME=e.WORKSPACE_FILTER=e.WORKSPACE_EXTENSION=e.toWorkspaceFolder=e.WorkspaceFolder=e.Workspace=e.isWorkspaceFolder=e.isWorkspace=e.WorkbenchState=e.reviveIdentifier=e.isWorkspaceIdentifier=e.toWorkspaceIdentifier=e.isSingleFolderWorkspaceIdentifier=e.IWorkspaceContextService=void 0,e.IWorkspaceContextService=(0,T.createDecorator)("contextService");function A(i){const o=i;return typeof o?.id=="string"&&C.URI.isUri(o.uri)}e.isSingleFolderWorkspaceIdentifier=A;function R(i){if(i.configuration)return{id:i.id,configPath:i.configuration};if(i.folders.length===1)return{id:i.id,uri:i.folders[0].uri}}e.toWorkspaceIdentifier=R;function y(i){const o=i;return typeof o?.id=="string"&&C.URI.isUri(o.configPath)}e.isWorkspaceIdentifier=y;function m(i){const o=i;if(o?.uri)return{id:o.id,uri:C.URI.revive(o.uri)};const r=i;if(r?.configPath)return{id:r.id,configPath:C.URI.revive(r.configPath)};if(i?.id)return{id:i.id}}e.reviveIdentifier=m;var I;(function(i){i[i.EMPTY=1]="EMPTY",i[i.FOLDER=2]="FOLDER",i[i.WORKSPACE=3]="WORKSPACE"})(I=e.WorkbenchState||(e.WorkbenchState={}));function f(i){const o=i;return!!(o&&typeof o=="object"&&typeof o.id=="string"&&Array.isArray(o.folders))}e.isWorkspace=f;function h(i){const o=i;return!!(o&&typeof o=="object"&&C.URI.isUri(o.uri)&&typeof o.name=="string"&&typeof o.toResource=="function")}e.isWorkspaceFolder=h;class d{constructor(o,r,t,c,v){this._id=o,this._transient=t,this._configuration=c,this._ignorePathCasing=v,this._foldersMap=b.TernarySearchTree.forUris(this._ignorePathCasing,()=>!0),this.folders=r}update(o){this._id=o.id,this._configuration=o.configuration,this._transient=o.transient,this._ignorePathCasing=o._ignorePathCasing,this.folders=o.folders}get folders(){return this._folders}set folders(o){this._folders=o,this.updateFoldersMap()}get id(){return this._id}get transient(){return this._transient}get configuration(){return this._configuration}set configuration(o){this._configuration=o}getFolder(o){return o&&this._foldersMap.findSubstr(o)||null}updateFoldersMap(){this._foldersMap=b.TernarySearchTree.forUris(this._ignorePathCasing,()=>!0);for(const o of this.folders)this._foldersMap.set(o.uri,o)}toJSON(){return{id:this.id,folders:this.folders,transient:this.transient,configuration:this.configuration}}}e.Workspace=d;class a{constructor(o,r){this.raw=r,this.uri=o.uri,this.index=o.index,this.name=o.name}toResource(o){return(0,L.joinPath)(this.uri,o)}toJSON(){return{uri:this.uri,name:this.name,index:this.index}}}e.WorkspaceFolder=a;function w(i){return new a({uri:i,index:0,name:(0,L.basenameOrAuthority)(i)},{uri:i.toString()})}e.toWorkspaceFolder=w,e.WORKSPACE_EXTENSION="code-workspace";const P=`.${e.WORKSPACE_EXTENSION}`;e.WORKSPACE_FILTER=[{name:(0,s.localize)(0,null),extensions:[e.WORKSPACE_EXTENSION]}],e.UNTITLED_WORKSPACE_NAME="workspace.json";function l(i,o){return L.extUriBiasedIgnorePathCase.isEqualOrParent(i,o.untitledWorkspacesHome)}e.isUntitledWorkspace=l;function _(i){let o;return C.URI.isUri(i)?o=i:o=i.configuration,o?.scheme===E.Schemas.tmp}e.isTemporaryWorkspace=_;function n(i,o){return!l(i,o)&&!_(i)}e.isSavedWorkspace=n;function u(i){return(typeof i=="string"?(0,p.extname)(i):(0,L.extname)(i))===P}e.hasWorkspaceFileExtension=u}),define(ye[61],Ce([1,0]),function(ee,e){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.Cache=void 0;class s{constructor(b){this.id=b,this._data=new Map,this._idPool=1}add(b){const L=this._idPool++;return this._data.set(L,b),this.logDebugInfo(),L}get(b,L){return this._data.has(b)?this._data.get(b)[L]:void 0}delete(b){this._data.delete(b),this.logDebugInfo()}logDebugInfo(){!s.enableDebugLogging||console.log(`${this.id} cache size - ${this._data.size}`)}}e.Cache=s,s.enableDebugLogging=!1}),define(ye[35],Ce([1,0,12,21,3]),function(ee,e,s,p,b){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.IExtHostFileSystemInfo=e.ExtHostFileSystemInfo=void 0;class L{constructor(){this._systemSchemes=new Set(Object.keys(s.Schemas)),this._providerInfo=new Map,this.extUri=new p.ExtUri(T=>{const E=this._providerInfo.get(T.scheme);return!(E===void 0||E&1024)})}$acceptProviderInfos(T,E){E===null?this._providerInfo.delete(T.scheme):this._providerInfo.set(T.scheme,E)}isFreeScheme(T){return!this._providerInfo.has(T)&&!this._systemSchemes.has(T)}getCapabilities(T){return this._providerInfo.get(T)}}e.ExtHostFileSystemInfo=L,e.IExtHostFileSystemInfo=(0,b.createDecorator)("IExtHostFileSystemInfo")}),define(ye[28],Ce([1,0,3]),function(ee,e,s){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.IExtHostInitDataService=void 0,e.IExtHostInitDataService=(0,s.createDecorator)("IExtHostInitDataService")}),define(ye[157],Ce([1,0,13]),function(ee,e,s){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.ExtensionGlobalMemento=e.ExtensionMemento=void 0;class p{constructor(C,T,E){this._deferredPromises=new Map,this._id=C,this._shared=T,this._storage=E,this._init=this._storage.initializeExtensionStorage(this._shared,this._id,Object.create(null)).then(A=>(this._value=A,this)),this._storageListener=this._storage.onDidChangeStorage(A=>{A.shared===this._shared&&A.key===this._id&&(this._value=A.value)}),this._scheduler=new s.RunOnceScheduler(()=>{const A=this._deferredPromises;this._deferredPromises=new Map,(async()=>{try{await this._storage.setValue(this._shared,this._id,this._value);for(const R of A.values())R.complete()}catch(R){for(const y of A.values())y.error(R)}})()},0)}keys(){return Object.entries(this._value??{}).filter(([,C])=>C!==void 0).map(([C])=>C)}get whenReady(){return this._init}get(C,T){let E=this._value[C];return typeof E=="undefined"&&(E=T),E}update(C,T){this._value[C]=T;const E=this._deferredPromises.get(C);if(E!==void 0)return E.p;const A=new s.DeferredPromise;return this._deferredPromises.set(C,A),this._scheduler.isScheduled()||this._scheduler.schedule(),A.p}dispose(){this._storageListener.dispose()}}e.ExtensionMemento=p;class b extends p{constructor(C,T){super(C.identifier.value,!0,T);this._extension=C}setKeysForSync(C){this._storage.registerExtensionStorageKeysToSync({id:this._id,version:this._extension.version},C)}}e.ExtensionGlobalMemento=b}),define(ye[158],Ce([1,0,4,2]),function(ee,e,s,p){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.ExtHostNotebookDocuments=void 0;class b{constructor(C){this._notebooksAndEditors=C,this._onDidSaveNotebookDocument=new s.Emitter,this.onDidSaveNotebookDocument=this._onDidSaveNotebookDocument.event,this._onDidChangeNotebookDocument=new s.Emitter,this.onDidChangeNotebookDocument=this._onDidChangeNotebookDocument.event}$acceptModelChanged(C,T,E,A){const y=this._notebooksAndEditors.getNotebookDocument(p.URI.revive(C)).acceptModelChanged(T.value,E,A);this._onDidChangeNotebookDocument.fire(y)}$acceptDirtyStateChanged(C,T){this._notebooksAndEditors.getNotebookDocument(p.URI.revive(C)).acceptDirty(T)}$acceptModelSaved(C){const T=this._notebooksAndEditors.getNotebookDocument(p.URI.revive(C));this._onDidSaveNotebookDocument.fire(T.apiNotebook)}}e.ExtHostNotebookDocuments=b}),define(ye[15],Ce([1,0,3]),function(ee,e,s){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.ExtHostRpcService=e.IExtHostRpcService=void 0,e.IExtHostRpcService=(0,s.createDecorator)("IExtHostRpcService");class p{constructor(L){this.getProxy=L.getProxy.bind(L),this.set=L.set.bind(L),this.dispose=L.dispose.bind(L),this.assertRegistered=L.assertRegistered.bind(L),this.drain=L.drain.bind(L)}}e.ExtHostRpcService=p});var Je=this&&this.__classPrivateFieldSet||function(ee,e,s,p,b){if(p==="m")throw new TypeError("Private method is not writable");if(p==="a"&&!b)throw new TypeError("Private accessor was defined without a setter");if(typeof e=="function"?ee!==e||!b:!e.has(ee))throw new TypeError("Cannot write private member to an object whose class did not declare it");return p==="a"?b.call(ee,s):b?b.value=s:e.set(ee,s),s},Ae=this&&this.__classPrivateFieldGet||function(ee,e,s,p){if(s==="a"&&!p)throw new TypeError("Private accessor was defined without a getter");if(typeof e=="function"?ee!==e||!p:!e.has(ee))throw new TypeError("Cannot read private member from an object whose class did not declare it");return s==="m"?p:s==="a"?p.call(ee):p?p.value:e.get(ee)};define(ye[159],Ce([1,0,27,4]),function(ee,e,s,p){"use strict";var b;Object.defineProperty(e,"__esModule",{value:!0}),e.ExtensionSecrets=void 0;class L{constructor(T,E){b.set(this,void 0),this._onDidChange=new p.Emitter,this.onDidChange=this._onDidChange.event,this._id=s.ExtensionIdentifier.toKey(T.identifier),Je(this,b,E,"f"),Ae(this,b,"f").onDidChangePassword(A=>{A.extensionId===this._id&&this._onDidChange.fire({key:A.key})})}get(T){return Ae(this,b,"f").get(this._id,T)}store(T,E){return Ae(this,b,"f").store(this._id,T,E)}delete(T){return Ae(this,b,"f").delete(this._id,T)}}e.ExtensionSecrets=L,b=new WeakMap}),define(ye[86],Ce([1,0,3,4]),function(ee,e,s,p){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.IExtHostTelemetry=e.ExtHostTelemetry=void 0;class b{constructor(){this._onDidChangeTelemetryEnabled=new p.Emitter,this.onDidChangeTelemetryEnabled=this._onDidChangeTelemetryEnabled.event,this._onDidChangeTelemetryConfiguration=new p.Emitter,this.onDidChangeTelemetryConfiguration=this._onDidChangeTelemetryConfiguration.event,this._productConfig={usage:!0,error:!0},this._level=0}getTelemetryConfiguration(){return this._level===3}getTelemetryDetails(){return{isCrashEnabled:this._level>=1,isErrorsEnabled:this._productConfig.error?this._level>=2:!1,isUsageEnabled:this._productConfig.usage?this._level>=3:!1}}$initializeTelemetryLevel(C,T){this._level=C,this._productConfig=T||{usage:!0,error:!0}}$onDidChangeTelemetryLevel(C){this._oldTelemetryEnablement=this.getTelemetryConfiguration(),this._level=C,this._oldTelemetryEnablement!==this.getTelemetryConfiguration()&&this._onDidChangeTelemetryEnabled.fire(this.getTelemetryConfiguration()),this._onDidChangeTelemetryConfiguration.fire(this.getTelemetryDetails())}}e.ExtHostTelemetry=b,e.IExtHostTelemetry=(0,s.createDecorator)("IExtHostTelemetry")}),define(ye[62],Ce([1,0,3,155,4,15]),function(ee,e,s,p,b,L){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.ExtHostTunnelService=e.IExtHostTunnelService=e.TunnelDtoConverter=void 0;var C;(function(E){function A(y){return{remoteAddress:y.remoteAddress,localAddress:y.localAddress,public:!!y.public,privacy:y.privacy??(y.public?p.TunnelPrivacyId.Public:p.TunnelPrivacyId.Private),protocol:y.protocol}}E.fromApiTunnel=A;function R(y){return{remoteAddress:{host:y.tunnelRemoteHost,port:y.tunnelRemotePort},localAddress:y.localAddress,public:y.privacy!==p.TunnelPrivacyId.ConstantPrivate&&y.privacy!==p.TunnelPrivacyId.ConstantPrivate,privacy:y.privacy,protocol:y.protocol}}E.fromServiceTunnel=R})(C=e.TunnelDtoConverter||(e.TunnelDtoConverter={})),e.IExtHostTunnelService=(0,s.createDecorator)("IExtHostTunnelService");let T=class{constructor(A){this.onDidChangeTunnels=new b.Emitter().event}async $applyCandidateFilter(A){return A}async openTunnel(A,R){}async getTunnels(){return[]}async setTunnelFactory(A){return{dispose:()=>{}}}registerPortsAttributesProvider(A,R){return{dispose:()=>{}}}async $providePortAttributes(A,R,y,m,I){return[]}async $forwardPort(A,R){}async $closeTunnel(A){}async $onDidTunnelsChange(){}async $registerCandidateFinder(){}};T=ze([xe(0,L.IExtHostRpcService)],T),e.ExtHostTunnelService=T});var Je=this&&this.__classPrivateFieldSet||function(ee,e,s,p,b){if(p==="m")throw new TypeError("Private method is not writable");if(p==="a"&&!b)throw new TypeError("Private accessor was defined without a setter");if(typeof e=="function"?ee!==e||!b:!e.has(ee))throw new TypeError("Cannot write private member to an object whose class did not declare it");return p==="a"?b.call(ee,s):b?b.value=s:e.set(ee,s),s},Ae=this&&this.__classPrivateFieldGet||function(ee,e,s,p){if(s==="a"&&!p)throw new TypeError("Private accessor was defined without a getter");if(typeof e=="function"?ee!==e||!p:!e.has(ee))throw new TypeError("Cannot read private member from an object whose class did not declare it");return s==="m"?p:s==="a"?p.call(ee):p?p.value:e.get(ee)};define(ye[6],Ce([1,0,16,11,75,25,74,9,10,2,43,39,84]),function(ee,e,s,p,b,L,C,T,E,A,R,y,m){"use strict";var I,f,h,d,a,w,P,l,_,n,u,i,o,r,t,c,v,g,D,U,W,M,S;Object.defineProperty(e,"__esModule",{value:!0}),e.InteractiveWindowInput=e.TerminalEditorTabInput=e.NotebookDiffEditorTabInput=e.NotebookEditorTabInput=e.WebviewEditorTabInput=e.CustomEditorTabInput=e.TextMergeTabInput=e.TextDiffTabInput=e.TextTabInput=e.TypeHierarchyItem=e.PortAutoForwardAction=e.WorkspaceTrustState=e.ExternalUriOpenerPriority=e.FunctionCoverage=e.BranchCoverage=e.StatementCoverage=e.FileCoverage=e.CoveredCount=e.TestTag=e.TestMessage=e.TestRunRequest=e.TestRunProfileKind=e.TestResultState=e.PortAttributes=e.LinkedEditingRanges=e.StandardTokenType=e.ExtensionRuntime=e.ExtensionMode=e.TimelineItem=e.NotebookRendererScript=e.NotebookControllerAffinity=e.NotebookCellStatusBarItem=e.NotebookEditorRevealType=e.NotebookCellStatusBarAlignment=e.NotebookCellExecutionState=e.NotebookCellKind=e.NotebookCellOutput=e.NotebookCellOutputItem=e.NotebookData=e.NotebookCellData=e.NotebookRange=e.ColorThemeKind=e.ColorTheme=e.FileDecoration=e.ExtensionKind=e.InputBoxValidationSeverity=e.QuickPickItemKind=e.QuickInputButtons=e.DebugConsoleMode=e.SemanticTokensEdits=e.SemanticTokensEdit=e.SemanticTokens=e.SemanticTokensBuilder=e.SemanticTokensLegend=e.CommentThreadState=e.CommentMode=e.CommentThreadCollapsibleState=e.FoldingRangeKind=e.FoldingRange=e.FileSystemError=e.FileChangeType=e.InlineValueContext=e.InlineValueEvaluatableExpression=e.InlineValueVariableLookup=e.InlineValueText=e.InlineCompletionTriggerKindNew=e.InlineCompletionTriggerKind=e.EvaluatableExpression=e.DebugAdapterInlineImplementation=e.DebugAdapterNamedPipeServer=e.DebugAdapterServer=e.DebugAdapterExecutable=e.DataBreakpoint=e.FunctionBreakpoint=e.SourceBreakpoint=e.Breakpoint=e.RelativePattern=e.ConfigurationTarget=e.ThemeColor=e.ThemeIcon=e.DocumentPasteEdit=e.DocumentDropEdit=e.DataTransfer=e.DataTransferItem=e.TreeItemCollapsibleState=e.TreeItem=e.ProgressLocation=e.Task=e.CustomExecution=e.TaskScope=e.ShellQuoting=e.ShellExecution=e.ProcessExecution=e.TaskGroup=e.TaskPanelKind=e.TaskRevealKind=e.TerminalProfile=e.TerminalLocation=e.TerminalLink=e.TerminalExitReason=e.SourceControlInputBoxValidationType=e.ColorFormat=e.ColorPresentation=e.ColorInformation=e.Color=e.DocumentLink=e.DecorationRangeBehavior=e.TextDocumentChangeReason=e.TextEditorSelectionChangeKind=e.TextEditorRevealType=e.TextDocumentSaveReason=e.TextEditorLineNumbersStyle=e.StatusBarAlignment=e.ViewColumn=e.InlineSuggestionsNew=e.InlineSuggestionNew=e.InlineSuggestionList=e.InlineSuggestion=e.CompletionList=e.CompletionItem=e.CompletionItemTag=e.CompletionItemKind=e.CompletionTriggerKind=e.InlayHint=e.InlayHintLabelPart=e.InlayHintKind=e.SignatureHelpTriggerKind=e.SignatureHelp=e.SignatureInformation=e.ParameterInformation=e.MarkdownString=e.CodeLens=e.LanguageStatusSeverity=e.CallHierarchyOutgoingCall=e.CallHierarchyIncomingCall=e.CallHierarchyItem=e.SelectionRange=e.CodeActionKind=e.CodeAction=e.CodeActionTriggerKind=e.DocumentSymbol=e.SymbolInformation=e.SymbolTag=e.SymbolKind=e.DocumentHighlight=e.DocumentHighlightKind=e.Hover=e.Diagnostic=e.DiagnosticRelatedInformation=e.Location=e.DiagnosticSeverity=e.DiagnosticTag=e.SnippetString=e.WorkspaceEdit=e.FileEditType=e.NotebookEdit=e.TextEdit=e.EnvironmentVariableMutatorType=e.EndOfLine=e.RemoteAuthorityResolverError=e.ResolvedAuthority=e.Selection=e.Range=e.Position=e.Disposable=void 0;function z(x){function O(){return Reflect.construct(x,arguments,this.constructor)}return Object.defineProperty(O,"name",Object.getOwnPropertyDescriptor(x,"name")),Object.setPrototypeOf(O,x),Object.setPrototypeOf(O.prototype,x.prototype),O}let $=w=class{constructor(O){I.set(this,void 0),Je(this,I,O,"f")}static from(...O){let Y=O;return new w(function(){if(Y){for(const _e of Y)_e&&typeof _e.dispose=="function"&&_e.dispose();Y=void 0}})}dispose(){typeof Ae(this,I,"f")=="function"&&(Ae(this,I,"f").call(this),Je(this,I,void 0,"f"))}};I=new WeakMap,$=w=ze([z],$),e.Disposable=$;let N=P=class{constructor(O,Y){if(O<0)throw(0,p.illegalArgument)("line must be non-negative");if(Y<0)throw(0,p.illegalArgument)("character must be non-negative");this._line=O,this._character=Y}static Min(...O){if(O.length===0)throw new TypeError;let Y=O[0];for(let _e=1;_e<O.length;_e++){const qe=O[_e];qe.isBefore(Y)&&(Y=qe)}return Y}static Max(...O){if(O.length===0)throw new TypeError;let Y=O[0];for(let _e=1;_e<O.length;_e++){const qe=O[_e];qe.isAfter(Y)&&(Y=qe)}return Y}static isPosition(O){if(!O)return!1;if(O instanceof P)return!0;const{line:Y,character:_e}=O;return typeof Y=="number"&&typeof _e=="number"}static of(O){if(O instanceof P)return O;if(this.isPosition(O))return new P(O.line,O.character);throw new Error("Invalid argument, is NOT a position-like object")}get line(){return this._line}get character(){return this._character}isBefore(O){return this._line<O._line?!0:O._line<this._line?!1:this._character<O._character}isBeforeOrEqual(O){return this._line<O._line?!0:O._line<this._line?!1:this._character<=O._character}isAfter(O){return!this.isBeforeOrEqual(O)}isAfterOrEqual(O){return!this.isBefore(O)}isEqual(O){return this._line===O._line&&this._character===O._character}compareTo(O){return this._line<O._line?-1:this._line>O.line?1:this._character<O._character?-1:this._character>O._character?1:0}translate(O,Y=0){if(O===null||Y===null)throw(0,p.illegalArgument)();let _e;return typeof O=="undefined"?_e=0:typeof O=="number"?_e=O:(_e=typeof O.lineDelta=="number"?O.lineDelta:0,Y=typeof O.characterDelta=="number"?O.characterDelta:0),_e===0&&Y===0?this:new P(this.line+_e,this.character+Y)}with(O,Y=this.character){if(O===null||Y===null)throw(0,p.illegalArgument)();let _e;return typeof O=="undefined"?_e=this.line:typeof O=="number"?_e=O:(_e=typeof O.line=="number"?O.line:this.line,Y=typeof O.character=="number"?O.character:this.character),_e===this.line&&Y===this.character?this:new P(_e,Y)}toJSON(){return{line:this.line,character:this.character}}};N=P=ze([z],N),e.Position=N;let K=l=class{constructor(O,Y,_e,qe){let tt,at;if(typeof O=="number"&&typeof Y=="number"&&typeof _e=="number"&&typeof qe=="number"?(tt=new N(O,Y),at=new N(_e,qe)):N.isPosition(O)&&N.isPosition(Y)&&(tt=N.of(O),at=N.of(Y)),!tt||!at)throw new Error("Invalid arguments");tt.isBefore(at)?(this._start=tt,this._end=at):(this._start=at,this._end=tt)}static isRange(O){return O instanceof l?!0:O?N.isPosition(O.start)&&N.isPosition(O.end):!1}static of(O){if(O instanceof l)return O;if(this.isRange(O))return new l(O.start,O.end);throw new Error("Invalid argument, is NOT a range-like object")}get start(){return this._start}get end(){return this._end}contains(O){return l.isRange(O)?this.contains(O.start)&&this.contains(O.end):N.isPosition(O)?!(N.of(O).isBefore(this._start)||this._end.isBefore(O)):!1}isEqual(O){return this._start.isEqual(O._start)&&this._end.isEqual(O._end)}intersection(O){const Y=N.Max(O.start,this._start),_e=N.Min(O.end,this._end);if(!Y.isAfter(_e))return new l(Y,_e)}union(O){if(this.contains(O))return this;if(O.contains(this))return O;const Y=N.Min(O.start,this._start),_e=N.Max(O.end,this.end);return new l(Y,_e)}get isEmpty(){return this._start.isEqual(this._end)}get isSingleLine(){return this._start.line===this._end.line}with(O,Y=this.end){if(O===null||Y===null)throw(0,p.illegalArgument)();let _e;return O?N.isPosition(O)?_e=O:(_e=O.start||this.start,Y=O.end||this.end):_e=this.start,_e.isEqual(this._start)&&Y.isEqual(this.end)?this:new l(_e,Y)}toJSON(){return[this.start,this.end]}};K=l=ze([z],K),e.Range=K;let V=_=class extends K{constructor(O,Y,_e,qe){let tt,at;if(typeof O=="number"&&typeof Y=="number"&&typeof _e=="number"&&typeof qe=="number"?(tt=new N(O,Y),at=new N(_e,qe)):N.isPosition(O)&&N.isPosition(Y)&&(tt=N.of(O),at=N.of(Y)),!tt||!at)throw new Error("Invalid arguments");super(tt,at);this._anchor=tt,this._active=at}static isSelection(O){return O instanceof _?!0:O?K.isRange(O)&&N.isPosition(O.anchor)&&N.isPosition(O.active)&&typeof O.isReversed=="boolean":!1}get anchor(){return this._anchor}get active(){return this._active}get isReversed(){return this._anchor===this._end}toJSON(){return{start:this.start,end:this.end,active:this.active,anchor:this.anchor}}};V=_=ze([z],V),e.Selection=V;class F{constructor(O,Y,_e){if(typeof O!="string"||O.length===0)throw(0,p.illegalArgument)("host");if(typeof Y!="number"||Y===0||Math.round(Y)!==Y)throw(0,p.illegalArgument)("port");if(typeof _e!="undefined"&&(typeof _e!="string"||_e.length===0||!/^[0-9A-Za-z\-]+$/.test(_e)))throw(0,p.illegalArgument)("connectionToken");this.host=O,this.port=Math.round(Y),this.connectionToken=_e}}e.ResolvedAuthority=F;class ne extends Error{constructor(O,Y=m.RemoteAuthorityResolverErrorCode.Unknown,_e){super(O);this._message=O,this._code=Y,this._detail=_e,typeof Object.setPrototypeOf=="function"&&Object.setPrototypeOf(this,ne.prototype)}static NotAvailable(O,Y){return new ne(O,m.RemoteAuthorityResolverErrorCode.NotAvailable,Y)}static TemporarilyNotAvailable(O){return new ne(O,m.RemoteAuthorityResolverErrorCode.TemporarilyNotAvailable)}}e.RemoteAuthorityResolverError=ne;var ce;(function(x){x[x.LF=1]="LF",x[x.CRLF=2]="CRLF"})(ce=e.EndOfLine||(e.EndOfLine={}));var re;(function(x){x[x.Replace=1]="Replace",x[x.Append=2]="Append",x[x.Prepend=3]="Prepend"})(re=e.EnvironmentVariableMutatorType||(e.EnvironmentVariableMutatorType={}));let fe=n=class{constructor(O,Y){this._range=O,this._newText=Y}static isTextEdit(O){return O instanceof n?!0:O?K.isRange(O)&&typeof O.newText=="string":!1}static replace(O,Y){return new n(O,Y)}static insert(O,Y){return n.replace(new K(O,O),Y)}static delete(O){return n.replace(O,"")}static setEndOfLine(O){const Y=new n(new K(new N(0,0),new N(0,0)),"");return Y.newEol=O,Y}get range(){return this._range}set range(O){if(O&&!K.isRange(O))throw(0,p.illegalArgument)("range");this._range=O}get newText(){return this._newText||""}set newText(O){if(O&&typeof O!="string")throw(0,p.illegalArgument)("newText");this._newText=O}get newEol(){return this._newEol}set newEol(O){if(O&&typeof O!="number")throw(0,p.illegalArgument)("newEol");this._newEol=O}toJSON(){return{range:this.range,newText:this.newText,newEol:this._newEol}}};fe=n=ze([z],fe),e.TextEdit=fe;let ie=u=class{constructor(O,Y){this.range=O,this.newCells=Y}static isNotebookCellEdit(O){return O instanceof u?!0:O?$t.isNotebookRange(O)&&Array.isArray(O.newCells):!1}static replaceCells(O,Y){return new u(O,Y)}static insertCells(O,Y){return new u(new $t(O,O),Y)}static deleteCells(O){return new u(O,[])}static updateCellMetadata(O,Y){const _e=new u(new $t(O,O),[]);return _e.newCellMetadata=Y,_e}static updateNotebookMetadata(O){const Y=new u(new $t(0,0),[]);return Y.newNotebookMetadata=O,Y}};ie=u=ze([z],ie),e.NotebookEdit=ie;var Ee;(function(x){x[x.File=1]="File",x[x.Text=2]="Text",x[x.Cell=3]="Cell",x[x.CellReplace=5]="CellReplace",x[x.Snippet=6]="Snippet"})(Ee=e.FileEditType||(e.FileEditType={}));let be=class{constructor(){this._edits=[]}_allEntries(){return this._edits}renameFile(O,Y,_e,qe){this._edits.push({_type:1,from:O,to:Y,options:_e,metadata:qe})}createFile(O,Y,_e){this._edits.push({_type:1,from:void 0,to:O,options:Y,metadata:_e})}deleteFile(O,Y,_e){this._edits.push({_type:1,from:O,to:void 0,options:Y,metadata:_e})}replaceNotebookMetadata(O,Y,_e){this._edits.push({_type:3,metadata:_e,uri:O,edit:{editType:5,metadata:Y},notebookMetadata:Y})}replaceNotebookCells(O,Y,_e,qe,tt){let at,ct,St=[],Pt;if($t.isNotebookRange(Y)&&qt.isNotebookCellDataArray(_e)&&!qt.isNotebookCellDataArray(qe)?(at=Y.start,ct=Y.end,St=_e,Pt=qe):typeof Y=="number"&&typeof _e=="number"&&qt.isNotebookCellDataArray(qe)&&(at=Y,ct=_e,St=qe,Pt=tt),at===void 0||ct===void 0)throw new Error("Invalid arguments");(at!==ct||St.length>0)&&this._edits.push({_type:5,uri:O,index:at,count:ct-at,cells:St,metadata:Pt})}replaceNotebookCellMetadata(O,Y,_e,qe){this._edits.push({_type:3,metadata:qe,uri:O,edit:{editType:8,index:Y,metadata:_e}})}replace(O,Y,_e,qe){typeof _e=="string"?this._edits.push({_type:2,uri:O,edit:new fe(Y,_e),metadata:qe}):this._edits.push({_type:6,uri:O,range:Y,edit:_e,metadata:qe})}insert(O,Y,_e,qe){this.replace(O,new K(Y,Y),_e,qe)}delete(O,Y,_e){this.replace(O,Y,"",_e)}has(O){return this._edits.some(Y=>Y._type===2&&Y.uri.toString()===O.toString())}set(O,Y){if(Y)for(const _e of Y)_e&&(ie.isNotebookCellEdit(_e)?_e.newCellMetadata?this.replaceNotebookCellMetadata(O,_e.range.start,_e.newCellMetadata):_e.newNotebookMetadata?this.replaceNotebookMetadata(O,_e.newNotebookMetadata):this.replaceNotebookCells(O,_e.range,_e.newCells):this._edits.push({_type:2,uri:O,edit:_e}));else{for(let _e=0;_e<this._edits.length;_e++){const qe=this._edits[_e];qe._type===2&&qe.uri.toString()===O.toString()&&(this._edits[_e]=void 0)}(0,s.coalesceInPlace)(this._edits)}}get(O){const Y=[];for(const _e of this._edits)_e._type===2&&_e.uri.toString()===O.toString()&&Y.push(_e.edit);return Y}entries(){const O=new L.ResourceMap;for(const Y of this._edits)if(Y._type===2){let _e=O.get(Y.uri);_e||(_e=[Y.uri,[]],O.set(Y.uri,_e)),_e[1].push(Y.edit)}return[...O.values()]}get size(){return this.entries().length}toJSON(){return this.entries()}};be=ze([z],be),e.WorkspaceEdit=be;let te=i=class{constructor(O){this._tabstop=1,this.value=O||""}static isSnippetString(O){return O instanceof i?!0:O?typeof O.value=="string":!1}static _escape(O){return O.replace(/\$|}|\\/g,"\\$&")}appendText(O){return this.value+=i._escape(O),this}appendTabstop(O=this._tabstop++){return this.value+="$",this.value+=O,this}appendPlaceholder(O,Y=this._tabstop++){if(typeof O=="function"){const _e=new i;_e._tabstop=this._tabstop,O(_e),this._tabstop=_e._tabstop,O=_e.value}else O=i._escape(O);return this.value+="${",this.value+=Y,this.value+=":",this.value+=O,this.value+="}",this}appendChoice(O,Y=this._tabstop++){const _e=O.map(qe=>qe.replace(/\$|}|\\|,/g,"\\$&")).join(",");return this.value+="${",this.value+=Y,this.value+="|",this.value+=_e,this.value+="|}",this}appendVariable(O,Y){if(typeof Y=="function"){const _e=new i;_e._tabstop=this._tabstop,Y(_e),this._tabstop=_e._tabstop,Y=_e.value}else typeof Y=="string"&&(Y=Y.replace(/\$|}/g,"\\$&"));return this.value+="${",this.value+=O,Y&&(this.value+=":",this.value+=Y),this.value+="}",this}};te=i=ze([z],te),e.SnippetString=te;var ve;(function(x){x[x.Unnecessary=1]="Unnecessary",x[x.Deprecated=2]="Deprecated"})(ve=e.DiagnosticTag||(e.DiagnosticTag={}));var Re;(function(x){x[x.Hint=3]="Hint",x[x.Information=2]="Information",x[x.Warning=1]="Warning",x[x.Error=0]="Error"})(Re=e.DiagnosticSeverity||(e.DiagnosticSeverity={}));let Fe=o=class{constructor(O,Y){if(this.uri=O,Y)if(K.isRange(Y))this.range=K.of(Y);else if(N.isPosition(Y))this.range=new K(Y,Y);else throw new Error("Illegal argument")}static isLocation(O){return O instanceof o?!0:O?K.isRange(O.range)&&A.URI.isUri(O.uri):!1}toJSON(){return{uri:this.uri,range:this.range}}};Fe=o=ze([z],Fe),e.Location=Fe;let $e=class{constructor(O,Y){this.location=O,this.message=Y}static is(O){return O?typeof O.message=="string"&&O.location&&K.isRange(O.location.range)&&A.URI.isUri(O.location.uri):!1}static isEqual(O,Y){return O===Y?!0:!O||!Y?!1:O.message===Y.message&&O.location.range.isEqual(Y.location.range)&&O.location.uri.toString()===Y.location.uri.toString()}};$e=ze([z],$e),e.DiagnosticRelatedInformation=$e;let Ye=class{constructor(O,Y,_e=Re.Error){if(!K.isRange(O))throw new TypeError("range must be set");if(!Y)throw new TypeError("message must be set");this.range=O,this.message=Y,this.severity=_e}toJSON(){return{severity:Re[this.severity],message:this.message,range:this.range,source:this.source,code:this.code}}static isEqual(O,Y){return O===Y?!0:!O||!Y?!1:O.message===Y.message&&O.severity===Y.severity&&O.code===Y.code&&O.severity===Y.severity&&O.source===Y.source&&O.range.isEqual(Y.range)&&(0,s.equals)(O.tags,Y.tags)&&(0,s.equals)(O.relatedInformation,Y.relatedInformation,$e.isEqual)}};Ye=ze([z],Ye),e.Diagnostic=Ye;let Ie=class{constructor(O,Y){if(!O)throw new Error("Illegal argument, contents must be defined");Array.isArray(O)?this.contents=O:this.contents=[O],this.range=Y}};Ie=ze([z],Ie),e.Hover=Ie;var Se;(function(x){x[x.Text=0]="Text",x[x.Read=1]="Read",x[x.Write=2]="Write"})(Se=e.DocumentHighlightKind||(e.DocumentHighlightKind={}));let Te=class{constructor(O,Y=Se.Text){this.range=O,this.kind=Y}toJSON(){return{range:this.range,kind:Se[this.kind]}}};Te=ze([z],Te),e.DocumentHighlight=Te;var ae;(function(x){x[x.File=0]="File",x[x.Module=1]="Module",x[x.Namespace=2]="Namespace",x[x.Package=3]="Package",x[x.Class=4]="Class",x[x.Method=5]="Method",x[x.Property=6]="Property",x[x.Field=7]="Field",x[x.Constructor=8]="Constructor",x[x.Enum=9]="Enum",x[x.Interface=10]="Interface",x[x.Function=11]="Function",x[x.Variable=12]="Variable",x[x.Constant=13]="Constant",x[x.String=14]="String",x[x.Number=15]="Number",x[x.Boolean=16]="Boolean",x[x.Array=17]="Array",x[x.Object=18]="Object",x[x.Key=19]="Key",x[x.Null=20]="Null",x[x.EnumMember=21]="EnumMember",x[x.Struct=22]="Struct",x[x.Event=23]="Event",x[x.Operator=24]="Operator",x[x.TypeParameter=25]="TypeParameter"})(ae=e.SymbolKind||(e.SymbolKind={}));var le;(function(x){x[x.Deprecated=1]="Deprecated"})(le=e.SymbolTag||(e.SymbolTag={}));let X=r=class{constructor(O,Y,_e,qe,tt){this.name=O,this.kind=Y,this.containerName=tt,typeof _e=="string"&&(this.containerName=_e),qe instanceof Fe?this.location=qe:_e instanceof K&&(this.location=new Fe(qe,_e)),r.validate(this)}static validate(O){if(!O.name)throw new Error("name must not be falsy")}toJSON(){return{name:this.name,kind:ae[this.kind],location:this.location,containerName:this.containerName}}};X=r=ze([z],X),e.SymbolInformation=X;let J=t=class{constructor(O,Y,_e,qe,tt){this.name=O,this.detail=Y,this.kind=_e,this.range=qe,this.selectionRange=tt,this.children=[],t.validate(this)}static validate(O){if(!O.name)throw new Error("name must not be falsy");if(!O.range.contains(O.selectionRange))throw new Error("selectionRange must be contained in fullRange");O.children?.forEach(t.validate)}};J=t=ze([z],J),e.DocumentSymbol=J;var k;(function(x){x[x.Invoke=1]="Invoke",x[x.Automatic=2]="Automatic"})(k=e.CodeActionTriggerKind||(e.CodeActionTriggerKind={}));let B=class{constructor(O,Y){this.title=O,this.kind=Y}};B=ze([z],B),e.CodeAction=B;let H=c=class{constructor(O){this.value=O}append(O){return new c(this.value?this.value+c.sep+O:O)}intersects(O){return this.contains(O)||O.contains(this)}contains(O){return this.value===O.value||O.value.startsWith(this.value+c.sep)}};H.sep=".",H=c=ze([z],H),e.CodeActionKind=H,H.Empty=new H(""),H.QuickFix=H.Empty.append("quickfix"),H.Refactor=H.Empty.append("refactor"),H.RefactorExtract=H.Refactor.append("extract"),H.RefactorInline=H.Refactor.append("inline"),H.RefactorRewrite=H.Refactor.append("rewrite"),H.Source=H.Empty.append("source"),H.SourceOrganizeImports=H.Source.append("organizeImports"),H.SourceFixAll=H.Source.append("fixAll");let j=class{constructor(O,Y){if(this.range=O,this.parent=Y,Y&&!Y.range.contains(this.range))throw new Error("Invalid argument: parent must contain this range")}};j=ze([z],j),e.SelectionRange=j;class oe{constructor(O,Y,_e,qe,tt,at){this.kind=O,this.name=Y,this.detail=_e,this.uri=qe,this.range=tt,this.selectionRange=at}}e.CallHierarchyItem=oe;class ue{constructor(O,Y){this.fromRanges=Y,this.from=O}}e.CallHierarchyIncomingCall=ue;class Z{constructor(O,Y){this.fromRanges=Y,this.to=O}}e.CallHierarchyOutgoingCall=Z;var pe;(function(x){x[x.Information=0]="Information",x[x.Warning=1]="Warning",x[x.Error=2]="Error"})(pe=e.LanguageStatusSeverity||(e.LanguageStatusSeverity={}));let ge=class{constructor(O,Y){this.range=O,this.command=Y}get isResolved(){return!!this.command}};ge=ze([z],ge),e.CodeLens=ge;let Ne=v=class{constructor(O,Y=!1){f.set(this,void 0),Je(this,f,new b.MarkdownString(O,{supportThemeIcons:Y}),"f")}static isMarkdownString(O){return O instanceof v?!0:O&&O.appendCodeblock&&O.appendMarkdown&&O.appendText&&O.value!==void 0}get value(){return Ae(this,f,"f").value}set value(O){Ae(this,f,"f").value=O}get isTrusted(){return Ae(this,f,"f").isTrusted}set isTrusted(O){Ae(this,f,"f").isTrusted=O}get supportThemeIcons(){return Ae(this,f,"f").supportThemeIcons}set supportThemeIcons(O){Ae(this,f,"f").supportThemeIcons=O}get supportHtml(){return Ae(this,f,"f").supportHtml}set supportHtml(O){Ae(this,f,"f").supportHtml=O}get baseUri(){return Ae(this,f,"f").baseUri}set baseUri(O){Ae(this,f,"f").baseUri=O}appendText(O){return Ae(this,f,"f").appendText(O),this}appendMarkdown(O){return Ae(this,f,"f").appendMarkdown(O),this}appendCodeblock(O,Y){return Ae(this,f,"f").appendCodeblock(Y??"",O),this}};f=new WeakMap,Ne=v=ze([z],Ne),e.MarkdownString=Ne;let Be=class{constructor(O,Y){this.label=O,this.documentation=Y}};Be=ze([z],Be),e.ParameterInformation=Be;let Ze=class{constructor(O,Y){this.label=O,this.documentation=Y,this.parameters=[]}};Ze=ze([z],Ze),e.SignatureInformation=Ze;let Ke=class{constructor(){this.activeSignature=0,this.activeParameter=0,this.signatures=[]}};Ke=ze([z],Ke),e.SignatureHelp=Ke;var ke;(function(x){x[x.Invoke=1]="Invoke",x[x.TriggerCharacter=2]="TriggerCharacter",x[x.ContentChange=3]="ContentChange"})(ke=e.SignatureHelpTriggerKind||(e.SignatureHelpTriggerKind={}));var nt;(function(x){x[x.Type=1]="Type",x[x.Parameter=2]="Parameter"})(nt=e.InlayHintKind||(e.InlayHintKind={}));let G=class{constructor(O){this.value=O}};G=ze([z],G),e.InlayHintLabelPart=G;let Q=class{constructor(O,Y,_e){this.position=O,this.label=Y,this.kind=_e}};Q=ze([z],Q),e.InlayHint=Q;var he;(function(x){x[x.Invoke=0]="Invoke",x[x.TriggerCharacter=1]="TriggerCharacter",x[x.TriggerForIncompleteCompletions=2]="TriggerForIncompleteCompletions"})(he=e.CompletionTriggerKind||(e.CompletionTriggerKind={}));var Ue;(function(x){x[x.Text=0]="Text",x[x.Method=1]="Method",x[x.Function=2]="Function",x[x.Constructor=3]="Constructor",x[x.Field=4]="Field",x[x.Variable=5]="Variable",x[x.Class=6]="Class",x[x.Interface=7]="Interface",x[x.Module=8]="Module",x[x.Property=9]="Property",x[x.Unit=10]="Unit",x[x.Value=11]="Value",x[x.Enum=12]="Enum",x[x.Keyword=13]="Keyword",x[x.Snippet=14]="Snippet",x[x.Color=15]="Color",x[x.File=16]="File",x[x.Reference=17]="Reference",x[x.Folder=18]="Folder",x[x.EnumMember=19]="EnumMember",x[x.Constant=20]="Constant",x[x.Struct=21]="Struct",x[x.Event=22]="Event",x[x.Operator=23]="Operator",x[x.TypeParameter=24]="TypeParameter",x[x.User=25]="User",x[x.Issue=26]="Issue"})(Ue=e.CompletionItemKind||(e.CompletionItemKind={}));var We;(function(x){x[x.Deprecated=1]="Deprecated"})(We=e.CompletionItemTag||(e.CompletionItemTag={}));let et=class{constructor(O,Y){this.label=O,this.kind=Y}toJSON(){return{label:this.label,kind:this.kind&&Ue[this.kind],detail:this.detail,documentation:this.documentation,sortText:this.sortText,filterText:this.filterText,preselect:this.preselect,insertText:this.insertText,textEdit:this.textEdit}}};et=ze([z],et),e.CompletionItem=et;let je=class{constructor(O=[],Y=!1){this.items=O,this.isIncomplete=Y}};je=ze([z],je),e.CompletionList=je;let He=class{constructor(O,Y,_e){this.insertText=O,this.range=Y,this.command=_e}};He=ze([z],He),e.InlineSuggestion=He;let it=class{constructor(O){this.commands=void 0,this.items=O}};it=ze([z],it),e.InlineSuggestionList=it;let rt=class{constructor(O,Y,_e){this.insertText=O,this.range=Y,this.command=_e}};rt=ze([z],rt),e.InlineSuggestionNew=rt;let dt=class{constructor(O,Y){this.items=O,this.commands=Y}};dt=ze([z],dt),e.InlineSuggestionsNew=dt;var lt;(function(x){x[x.Active=-1]="Active",x[x.Beside=-2]="Beside",x[x.One=1]="One",x[x.Two=2]="Two",x[x.Three=3]="Three",x[x.Four=4]="Four",x[x.Five=5]="Five",x[x.Six=6]="Six",x[x.Seven=7]="Seven",x[x.Eight=8]="Eight",x[x.Nine=9]="Nine"})(lt=e.ViewColumn||(e.ViewColumn={}));var st;(function(x){x[x.Left=1]="Left",x[x.Right=2]="Right"})(st=e.StatusBarAlignment||(e.StatusBarAlignment={}));var yt;(function(x){x[x.Off=0]="Off",x[x.On=1]="On",x[x.Relative=2]="Relative"})(yt=e.TextEditorLineNumbersStyle||(e.TextEditorLineNumbersStyle={}));var Ot;(function(x){x[x.Manual=1]="Manual",x[x.AfterDelay=2]="AfterDelay",x[x.FocusOut=3]="FocusOut"})(Ot=e.TextDocumentSaveReason||(e.TextDocumentSaveReason={}));var Ft;(function(x){x[x.Default=0]="Default",x[x.InCenter=1]="InCenter",x[x.InCenterIfOutsideViewport=2]="InCenterIfOutsideViewport",x[x.AtTop=3]="AtTop"})(Ft=e.TextEditorRevealType||(e.TextEditorRevealType={}));var ft;(function(x){x[x.Keyboard=1]="Keyboard",x[x.Mouse=2]="Mouse",x[x.Command=3]="Command"})(ft=e.TextEditorSelectionChangeKind||(e.TextEditorSelectionChangeKind={}));var Dt;(function(x){x[x.Undo=1]="Undo",x[x.Redo=2]="Redo"})(Dt=e.TextDocumentChangeReason||(e.TextDocumentChangeReason={}));var Ut;(function(x){x[x.OpenOpen=0]="OpenOpen",x[x.ClosedClosed=1]="ClosedClosed",x[x.OpenClosed=2]="OpenClosed",x[x.ClosedOpen=3]="ClosedOpen"})(Ut=e.DecorationRangeBehavior||(e.DecorationRangeBehavior={})),function(x){function O(Y){switch(Y){case"keyboard":return x.Keyboard;case"mouse":return x.Mouse;case"api":return x.Command}}x.fromValue=O}(ft=e.TextEditorSelectionChangeKind||(e.TextEditorSelectionChangeKind={}));let Nt=class{constructor(O,Y){if(Y&&!A.URI.isUri(Y))throw(0,p.illegalArgument)("target");if(!K.isRange(O)||O.isEmpty)throw(0,p.illegalArgument)("range");this.range=O,this.target=Y}};Nt=ze([z],Nt),e.DocumentLink=Nt;let Ve=class{constructor(O,Y,_e,qe){this.red=O,this.green=Y,this.blue=_e,this.alpha=qe}};Ve=ze([z],Ve),e.Color=Ve;let Mt=class{constructor(O,Y){if(Y&&!(Y instanceof Ve))throw(0,p.illegalArgument)("color");if(!K.isRange(O)||O.isEmpty)throw(0,p.illegalArgument)("range");this.range=O,this.color=Y}};Mt=ze([z],Mt),e.ColorInformation=Mt;let At=class{constructor(O){if(!O||typeof O!="string")throw(0,p.illegalArgument)("label");this.label=O}};At=ze([z],At),e.ColorPresentation=At;var Lt;(function(x){x[x.RGB=0]="RGB",x[x.HEX=1]="HEX",x[x.HSL=2]="HSL"})(Lt=e.ColorFormat||(e.ColorFormat={}));var gt;(function(x){x[x.Error=0]="Error",x[x.Warning=1]="Warning",x[x.Information=2]="Information"})(gt=e.SourceControlInputBoxValidationType||(e.SourceControlInputBoxValidationType={}));var It;(function(x){x[x.Unknown=0]="Unknown",x[x.Shutdown=1]="Shutdown",x[x.Process=2]="Process",x[x.User=3]="User",x[x.Extension=4]="Extension"})(It=e.TerminalExitReason||(e.TerminalExitReason={}));class we{constructor(O,Y,_e){if(this.startIndex=O,this.length=Y,this.tooltip=_e,typeof O!="number"||O<0)throw(0,p.illegalArgument)("startIndex");if(typeof Y!="number"||Y<1)throw(0,p.illegalArgument)("length");if(_e!==void 0&&typeof _e!="string")throw(0,p.illegalArgument)("tooltip")}}e.TerminalLink=we;var De;(function(x){x[x.Panel=1]="Panel",x[x.Editor=2]="Editor"})(De=e.TerminalLocation||(e.TerminalLocation={}));class me{constructor(O){if(this.options=O,typeof O!="object")throw(0,p.illegalArgument)("options")}}e.TerminalProfile=me;var q;(function(x){x[x.Always=1]="Always",x[x.Silent=2]="Silent",x[x.Never=3]="Never"})(q=e.TaskRevealKind||(e.TaskRevealKind={}));var Pe;(function(x){x[x.Shared=1]="Shared",x[x.Dedicated=2]="Dedicated",x[x.New=3]="New"})(Pe=e.TaskPanelKind||(e.TaskPanelKind={}));let Le=g=class{constructor(O,Y){if(this.label=Y,typeof O!="string"||typeof Y!="string")throw(0,p.illegalArgument)("name");this._id=O}static from(O){switch(O){case"clean":return g.Clean;case"build":return g.Build;case"rebuild":return g.Rebuild;case"test":return g.Test;default:return}}get id(){return this._id}};Le.Clean=new g("clean","Clean"),Le.Build=new g("build","Build"),Le.Rebuild=new g("rebuild","Rebuild"),Le.Test=new g("test","Test"),Le=g=ze([z],Le),e.TaskGroup=Le;function Xe(x){let O="";for(let Y=0;Y<x.length;Y++)O+=x[Y].replace(/,/g,",,")+",";return O}let Qe=class{constructor(O,Y,_e){if(typeof O!="string")throw(0,p.illegalArgument)("process");this._args=[],this._process=O,Y!==void 0&&(Array.isArray(Y)?(this._args=Y,this._options=_e):this._options=Y)}get process(){return this._process}set process(O){if(typeof O!="string")throw(0,p.illegalArgument)("process");this._process=O}get args(){return this._args}set args(O){Array.isArray(O)||(O=[]),this._args=O}get options(){return this._options}set options(O){this._options=O}computeId(){const O=[];if(O.push("process"),this._process!==void 0&&O.push(this._process),this._args&&this._args.length>0)for(const Y of this._args)O.push(Y);return Xe(O)}};Qe=ze([z],Qe),e.ProcessExecution=Qe;let Ge=class{constructor(O,Y,_e){if(this._args=[],Array.isArray(Y)){if(!O)throw(0,p.illegalArgument)("command can't be undefined or null");if(typeof O!="string"&&typeof O.value!="string")throw(0,p.illegalArgument)("command");this._command=O,this._args=Y,this._options=_e}else{if(typeof O!="string")throw(0,p.illegalArgument)("commandLine");this._commandLine=O,this._options=Y}}get commandLine(){return this._commandLine}set commandLine(O){if(typeof O!="string")throw(0,p.illegalArgument)("commandLine");this._commandLine=O}get command(){return this._command?this._command:""}set command(O){if(typeof O!="string"&&typeof O.value!="string")throw(0,p.illegalArgument)("command");this._command=O}get args(){return this._args}set args(O){this._args=O||[]}get options(){return this._options}set options(O){this._options=O}computeId(){const O=[];if(O.push("shell"),this._commandLine!==void 0&&O.push(this._commandLine),this._command!==void 0&&O.push(typeof this._command=="string"?this._command:this._command.value),this._args&&this._args.length>0)for(const Y of this._args)O.push(typeof Y=="string"?Y:Y.value);return Xe(O)}};Ge=ze([z],Ge),e.ShellExecution=Ge;var pt;(function(x){x[x.Escape=1]="Escape",x[x.Strong=2]="Strong",x[x.Weak=3]="Weak"})(pt=e.ShellQuoting||(e.ShellQuoting={}));var bt;(function(x){x[x.Global=1]="Global",x[x.Workspace=2]="Workspace"})(bt=e.TaskScope||(e.TaskScope={}));class kt{constructor(O){this._callback=O}computeId(){return"customExecution"+(0,R.generateUuid)()}set callback(O){this._callback=O}get callback(){return this._callback}}e.CustomExecution=kt;let Et=D=class{constructor(O,Y,_e,qe,tt,at){this.__deprecated=!1,this._definition=this.definition=O;let ct;typeof Y=="string"?(this._name=this.name=Y,this._source=this.source=_e,this.execution=qe,ct=tt,this.__deprecated=!0):Y===bt.Global||Y===bt.Workspace?(this.target=Y,this._name=this.name=_e,this._source=this.source=qe,this.execution=tt,ct=at):(this.target=Y,this._name=this.name=_e,this._source=this.source=qe,this.execution=tt,ct=at),typeof ct=="string"?(this._problemMatchers=[ct],this._hasDefinedMatchers=!0):Array.isArray(ct)?(this._problemMatchers=ct,this._hasDefinedMatchers=!0):(this._problemMatchers=[],this._hasDefinedMatchers=!1),this._isBackground=!1,this._presentationOptions=Object.create(null),this._runOptions=Object.create(null)}get _id(){return this.__id}set _id(O){this.__id=O}get _deprecated(){return this.__deprecated}clear(){this.__id!==void 0&&(this.__id=void 0,this._scope=void 0,this.computeDefinitionBasedOnExecution())}computeDefinitionBasedOnExecution(){this._execution instanceof Qe?this._definition={type:D.ProcessType,id:this._execution.computeId()}:this._execution instanceof Ge?this._definition={type:D.ShellType,id:this._execution.computeId()}:this._execution instanceof kt?this._definition={type:D.ExtensionCallbackType,id:this._execution.computeId()}:this._definition={type:D.EmptyType,id:(0,R.generateUuid)()}}get definition(){return this._definition}set definition(O){if(O==null)throw(0,p.illegalArgument)("Kind can't be undefined or null");this.clear(),this._definition=O}get scope(){return this._scope}set target(O){this.clear(),this._scope=O}get name(){return this._name}set name(O){if(typeof O!="string")throw(0,p.illegalArgument)("name");this.clear(),this._name=O}get execution(){return this._execution}set execution(O){O===null&&(O=void 0),this.clear(),this._execution=O;const Y=this._definition.type;(D.EmptyType===Y||D.ProcessType===Y||D.ShellType===Y||D.ExtensionCallbackType===Y)&&this.computeDefinitionBasedOnExecution()}get problemMatchers(){return this._problemMatchers}set problemMatchers(O){if(Array.isArray(O))this.clear(),this._problemMatchers=O,this._hasDefinedMatchers=!0;else{this.clear(),this._problemMatchers=[],this._hasDefinedMatchers=!1;return}}get hasDefinedMatchers(){return this._hasDefinedMatchers}get isBackground(){return this._isBackground}set isBackground(O){O!==!0&&O!==!1&&(O=!1),this.clear(),this._isBackground=O}get source(){return this._source}set source(O){if(typeof O!="string"||O.length===0)throw(0,p.illegalArgument)("source must be a string of length > 0");this.clear(),this._source=O}get group(){return this._group}set group(O){O===null&&(O=void 0),this.clear(),this._group=O}get detail(){return this._detail}set detail(O){O===null&&(O=void 0),this._detail=O}get presentationOptions(){return this._presentationOptions}set presentationOptions(O){O==null&&(O=Object.create(null)),this.clear(),this._presentationOptions=O}get runOptions(){return this._runOptions}set runOptions(O){O==null&&(O=Object.create(null)),this.clear(),this._runOptions=O}};Et.ExtensionCallbackType="customExecution",Et.ProcessType="process",Et.ShellType="shell",Et.EmptyType="$empty",Et=D=ze([z],Et),e.Task=Et;var ht;(function(x){x[x.SourceControl=1]="SourceControl",x[x.Window=10]="Window",x[x.Notification=15]="Notification"})(ht=e.ProgressLocation||(e.ProgressLocation={}));let Rt=U=class{constructor(O,Y=_t.None){this.collapsibleState=Y,A.URI.isUri(O)?this.resourceUri=O:this.label=O}static isTreeItem(O){if(O instanceof U)return!0;const Y=O;if(Y.label!==void 0&&!(0,E.isString)(Y.label)&&!Y.label.label)return console.log("INVALID tree item, invalid label",Y.label),!1;if(Y.id!==void 0&&!(0,E.isString)(Y.id))return console.log("INVALID tree item, invalid id",Y.id),!1;if(Y.iconPath!==void 0&&!(0,E.isString)(Y.iconPath)&&!A.URI.isUri(Y.iconPath)&&!(0,E.isString)(Y.iconPath.id)){const _e=Y.iconPath;if(!(0,E.isString)(_e.light)&&!A.URI.isUri(_e.light)&&!(0,E.isString)(_e.dark)&&!A.URI.isUri(_e.dark))return console.log("INVALID tree item, invalid iconPath",Y.iconPath),!1}return Y.description!==void 0&&!(0,E.isString)(Y.description)&&typeof Y.description!="boolean"?(console.log("INVALID tree item, invalid description",Y.description),!1):Y.resourceUri!==void 0&&!A.URI.isUri(Y.resourceUri)?(console.log("INVALID tree item, invalid resourceUri",Y.resourceUri),!1):Y.tooltip!==void 0&&!(0,E.isString)(Y.tooltip)&&!(Y.tooltip instanceof Ne)?(console.log("INVALID tree item, invalid tooltip",Y.tooltip),!1):Y.command!==void 0&&!Y.command.command?(console.log("INVALID tree item, invalid command",Y.command),!1):Y.collapsibleState!==void 0&&Y.collapsibleState<_t.None&&Y.collapsibleState>_t.Expanded?(console.log("INVALID tree item, invalid collapsibleState",Y.collapsibleState),!1):Y.contextValue!==void 0&&!(0,E.isString)(Y.contextValue)?(console.log("INVALID tree item, invalid contextValue",Y.contextValue),!1):Y.accessibilityInformation!==void 0&&!Y.accessibilityInformation.label?(console.log("INVALID tree item, invalid accessibilityInformation",Y.accessibilityInformation),!1):!0}};Rt=U=ze([z],Rt),e.TreeItem=Rt;var _t;(function(x){x[x.None=0]="None",x[x.Collapsed=1]="Collapsed",x[x.Expanded=2]="Expanded"})(_t=e.TreeItemCollapsibleState||(e.TreeItemCollapsibleState={}));let vt=class{constructor(O){this.value=O}async asString(){return typeof this.value=="string"?this.value:JSON.stringify(this.value)}asFile(){}};vt=ze([z],vt),e.DataTransferItem=vt;let Gt=class{constructor(O){h.set(this,new Map);for(const[Y,_e]of O??[]){const qe=Ae(this,h,"f").get(Y);qe?qe.push(_e):Ae(this,h,"f").set(Y,[_e])}}get(O){return Ae(this,h,"f").get(O)?.[0]}set(O,Y){Ae(this,h,"f").set(O,[Y])}forEach(O,Y){for(const[_e,qe]of Ae(this,h,"f"))for(const tt of qe)O.call(Y,tt,_e,this)}*[(h=new WeakMap,Symbol.iterator)](){for(const[O,Y]of Ae(this,h,"f"))for(const _e of Y)yield[O,_e]}};Gt=ze([z],Gt),e.DataTransfer=Gt;let Xt=class{constructor(O){this.insertText=O}};Xt=ze([z],Xt),e.DocumentDropEdit=Xt;let Ht=class{constructor(O){this.insertText=O}};Ht=ze([z],Ht),e.DocumentPasteEdit=Ht;let Vt=class{constructor(O,Y){this.id=O,this.color=Y}};Vt=ze([z],Vt),e.ThemeIcon=Vt,Vt.File=new Vt("file"),Vt.Folder=new Vt("folder");let Tt=class{constructor(O){this.id=O}};Tt=ze([z],Tt),e.ThemeColor=Tt;var _i;(function(x){x[x.Global=1]="Global",x[x.Workspace=2]="Workspace",x[x.WorkspaceFolder=3]="WorkspaceFolder"})(_i=e.ConfigurationTarget||(e.ConfigurationTarget={}));let hi=class{constructor(O,Y){if(typeof O!="string"&&(!O||!A.URI.isUri(O)&&!A.URI.isUri(O.uri)))throw(0,p.illegalArgument)("base");if(typeof Y!="string")throw(0,p.illegalArgument)("pattern");typeof O=="string"?this.baseUri=A.URI.file(O):A.URI.isUri(O)?this.baseUri=O:this.baseUri=O.uri,this.pattern=Y}get base(){return this._base}set base(O){this._base=O,this._baseUri=A.URI.file(O)}get baseUri(){return this._baseUri}set baseUri(O){this._baseUri=O,this._base=O.fsPath}toJSON(){return{pattern:this.pattern,base:this.base,baseUri:this.baseUri.toJSON()}}};hi=ze([z],hi),e.RelativePattern=hi;let zt=class{constructor(O,Y,_e,qe){this.enabled=typeof O=="boolean"?O:!0,typeof Y=="string"&&(this.condition=Y),typeof _e=="string"&&(this.hitCondition=_e),typeof qe=="string"&&(this.logMessage=qe)}get id(){return this._id||(this._id=(0,R.generateUuid)()),this._id}};zt=ze([z],zt),e.Breakpoint=zt;let ei=class extends zt{constructor(O,Y,_e,qe,tt){super(Y,_e,qe,tt);if(O===null)throw(0,p.illegalArgument)("location");this.location=O}};ei=ze([z],ei),e.SourceBreakpoint=ei;let ut=class extends zt{constructor(O,Y,_e,qe,tt){super(Y,_e,qe,tt);this.functionName=O}};ut=ze([z],ut),e.FunctionBreakpoint=ut;let fi=class extends zt{constructor(O,Y,_e,qe,tt,at,ct){super(qe,tt,at,ct);if(!Y)throw(0,p.illegalArgument)("dataId");this.label=O,this.dataId=Y,this.canPersist=_e}};fi=ze([z],fi),e.DataBreakpoint=fi;let xt=class{constructor(O,Y,_e){this.command=O,this.args=Y||[],this.options=_e}};xt=ze([z],xt),e.DebugAdapterExecutable=xt;let Qt=class{constructor(O,Y){this.port=O,this.host=Y}};Qt=ze([z],Qt),e.DebugAdapterServer=Qt;let ri=class{constructor(O){this.path=O}};ri=ze([z],ri),e.DebugAdapterNamedPipeServer=ri;let mi=class{constructor(O){this.implementation=O}};mi=ze([z],mi),e.DebugAdapterInlineImplementation=mi;let si=class{constructor(O,Y){this.range=O,this.expression=Y}};si=ze([z],si),e.EvaluatableExpression=si;var Ti;(function(x){x[x.Invoke=0]="Invoke",x[x.Automatic=1]="Automatic"})(Ti=e.InlineCompletionTriggerKind||(e.InlineCompletionTriggerKind={}));var Si;(function(x){x[x.Invoke=0]="Invoke",x[x.Automatic=1]="Automatic"})(Si=e.InlineCompletionTriggerKindNew||(e.InlineCompletionTriggerKindNew={}));let ti=class{constructor(O,Y){this.range=O,this.text=Y}};ti=ze([z],ti),e.InlineValueText=ti;let gi=class{constructor(O,Y,_e=!0){this.range=O,this.variableName=Y,this.caseSensitiveLookup=_e}};gi=ze([z],gi),e.InlineValueVariableLookup=gi;let ii=class{constructor(O,Y){this.range=O,this.expression=Y}};ii=ze([z],ii),e.InlineValueEvaluatableExpression=ii;let ni=class{constructor(O,Y){this.frameId=O,this.stoppedLocation=Y}};ni=ze([z],ni),e.InlineValueContext=ni;var Pi;(function(x){x[x.Changed=1]="Changed",x[x.Created=2]="Created",x[x.Deleted=3]="Deleted"})(Pi=e.FileChangeType||(e.FileChangeType={}));let pi=W=class extends Error{constructor(O,Y=y.FileSystemProviderErrorCode.Unknown,_e){super(A.URI.isUri(O)?O.toString(!0):O);this.code=_e?.name??"Unknown",(0,y.markAsFileSystemProviderError)(this,Y),typeof Object.setPrototypeOf=="function"&&Object.setPrototypeOf(this,W.prototype),typeof Error.captureStackTrace=="function"&&typeof _e=="function"&&Error.captureStackTrace(this,_e)}static FileExists(O){return new W(O,y.FileSystemProviderErrorCode.FileExists,W.FileExists)}static FileNotFound(O){return new W(O,y.FileSystemProviderErrorCode.FileNotFound,W.FileNotFound)}static FileNotADirectory(O){return new W(O,y.FileSystemProviderErrorCode.FileNotADirectory,W.FileNotADirectory)}static FileIsADirectory(O){return new W(O,y.FileSystemProviderErrorCode.FileIsADirectory,W.FileIsADirectory)}static NoPermissions(O){return new W(O,y.FileSystemProviderErrorCode.NoPermissions,W.NoPermissions)}static Unavailable(O){return new W(O,y.FileSystemProviderErrorCode.Unavailable,W.Unavailable)}};pi=W=ze([z],pi),e.FileSystemError=pi;let Yt=class{constructor(O,Y,_e){this.start=O,this.end=Y,this.kind=_e}};Yt=ze([z],Yt),e.FoldingRange=Yt;var Ai;(function(x){x[x.Comment=1]="Comment",x[x.Imports=2]="Imports",x[x.Region=3]="Region"})(Ai=e.FoldingRangeKind||(e.FoldingRangeKind={}));var Ri;(function(x){x[x.Collapsed=0]="Collapsed",x[x.Expanded=1]="Expanded"})(Ri=e.CommentThreadCollapsibleState||(e.CommentThreadCollapsibleState={}));var Oi;(function(x){x[x.Editing=0]="Editing",x[x.Preview=1]="Preview"})(Oi=e.CommentMode||(e.CommentMode={}));var Fi;(function(x){x[x.Unresolved=0]="Unresolved",x[x.Resolved=1]="Resolved"})(Fi=e.CommentThreadState||(e.CommentThreadState={}));class vi{constructor(O,Y=[]){this.tokenTypes=O,this.tokenModifiers=Y}}e.SemanticTokensLegend=vi;function yi(x){return typeof x=="undefined"||(0,E.isStringArray)(x)}class oi{constructor(O){if(this._prevLine=0,this._prevChar=0,this._dataIsSortedAndDeltaEncoded=!0,this._data=[],this._dataLen=0,this._tokenTypeStrToInt=new Map,this._tokenModifierStrToInt=new Map,this._hasLegend=!1,O){this._hasLegend=!0;for(let Y=0,_e=O.tokenTypes.length;Y<_e;Y++)this._tokenTypeStrToInt.set(O.tokenTypes[Y],Y);for(let Y=0,_e=O.tokenModifiers.length;Y<_e;Y++)this._tokenModifierStrToInt.set(O.tokenModifiers[Y],Y)}}push(O,Y,_e,qe,tt){if(typeof O=="number"&&typeof Y=="number"&&typeof _e=="number"&&typeof qe=="number"&&(typeof tt=="number"||typeof tt=="undefined"))return typeof tt=="undefined"&&(tt=0),this._pushEncoded(O,Y,_e,qe,tt);if(K.isRange(O)&&typeof Y=="string"&&yi(_e))return this._push(O,Y,_e);throw(0,p.illegalArgument)()}_push(O,Y,_e){if(!this._hasLegend)throw new Error("Legend must be provided in constructor");if(O.start.line!==O.end.line)throw new Error("`range` cannot span multiple lines");if(!this._tokenTypeStrToInt.has(Y))throw new Error("`tokenType` is not in the provided legend");const qe=O.start.line,tt=O.start.character,at=O.end.character-O.start.character,ct=this._tokenTypeStrToInt.get(Y);let St=0;if(_e)for(const Pt of _e){if(!this._tokenModifierStrToInt.has(Pt))throw new Error("`tokenModifier` is not in the provided legend");const Wt=this._tokenModifierStrToInt.get(Pt);St|=1<<Wt>>>0}this._pushEncoded(qe,tt,at,ct,St)}_pushEncoded(O,Y,_e,qe,tt){if(this._dataIsSortedAndDeltaEncoded&&(O<this._prevLine||O===this._prevLine&&Y<this._prevChar)){this._dataIsSortedAndDeltaEncoded=!1;const St=this._data.length/5|0;let Pt=0,Wt=0;for(let Kt=0;Kt<St;Kt++){let Jt=this._data[5*Kt],bi=this._data[5*Kt+1];Jt===0?(Jt=Pt,bi+=Wt):Jt+=Pt,this._data[5*Kt]=Jt,this._data[5*Kt+1]=bi,Pt=Jt,Wt=bi}}let at=O,ct=Y;this._dataIsSortedAndDeltaEncoded&&this._dataLen>0&&(at-=this._prevLine,at===0&&(ct-=this._prevChar)),this._data[this._dataLen++]=at,this._data[this._dataLen++]=ct,this._data[this._dataLen++]=_e,this._data[this._dataLen++]=qe,this._data[this._dataLen++]=tt,this._prevLine=O,this._prevChar=Y}static _sortAndDeltaEncode(O){const Y=[],_e=O.length/5|0;for(let ct=0;ct<_e;ct++)Y[ct]=ct;Y.sort((ct,St)=>{const Pt=O[5*ct],Wt=O[5*St];if(Pt===Wt){const Kt=O[5*ct+1],Jt=O[5*St+1];return Kt-Jt}return Pt-Wt});const qe=new Uint32Array(O.length);let tt=0,at=0;for(let ct=0;ct<_e;ct++){const St=5*Y[ct],Pt=O[St+0],Wt=O[St+1],Kt=O[St+2],Jt=O[St+3],bi=O[St+4],Gi=Pt-tt,bn=Gi===0?Wt-at:Wt,wi=5*ct;qe[wi+0]=Gi,qe[wi+1]=bn,qe[wi+2]=Kt,qe[wi+3]=Jt,qe[wi+4]=bi,tt=Pt,at=Wt}return qe}build(O){return this._dataIsSortedAndDeltaEncoded?new Me(new Uint32Array(this._data),O):new Me(oi._sortAndDeltaEncode(this._data),O)}}e.SemanticTokensBuilder=oi;class Me{constructor(O,Y){this.resultId=Y,this.data=O}}e.SemanticTokens=Me;class jt{constructor(O,Y,_e){this.start=O,this.deleteCount=Y,this.data=_e}}e.SemanticTokensEdit=jt;class Di{constructor(O,Y){this.resultId=Y,this.edits=O}}e.SemanticTokensEdits=Di;var mt;(function(x){x[x.Separate=0]="Separate",x[x.MergeWithParent=1]="MergeWithParent"})(mt=e.DebugConsoleMode||(e.DebugConsoleMode={}));let ai=class{constructor(){}};ai.Back={iconPath:new Vt("arrow-left")},ai=ze([z],ai),e.QuickInputButtons=ai;var Ni;(function(x){x[x.Separator=-1]="Separator",x[x.Default=0]="Default"})(Ni=e.QuickPickItemKind||(e.QuickPickItemKind={}));var Ci;(function(x){x[x.Info=1]="Info",x[x.Warning=2]="Warning",x[x.Error=3]="Error"})(Ci=e.InputBoxValidationSeverity||(e.InputBoxValidationSeverity={}));var Mi;(function(x){x[x.UI=1]="UI",x[x.Workspace=2]="Workspace"})(Mi=e.ExtensionKind||(e.ExtensionKind={}));class ci{constructor(O,Y,_e){this.badge=O,this.tooltip=Y,this.color=_e}static validate(O){if(O.badge){let Y=(0,T.nextCharLength)(O.badge,0);if(Y<O.badge.length&&(Y+=(0,T.nextCharLength)(O.badge,Y)),O.badge.length>Y)throw new Error("The 'badge'-property must be undefined or a short character")}if(!O.color&&!O.badge&&!O.tooltip)throw new Error("The decoration is empty");return!0}}e.FileDecoration=ci;let Ei=class{constructor(O){this.kind=O}};Ei=ze([z],Ei),e.ColorTheme=Ei;var Li;(function(x){x[x.Light=1]="Light",x[x.Dark=2]="Dark",x[x.HighContrast=3]="HighContrast",x[x.HighContrastLight=4]="HighContrastLight"})(Li=e.ColorThemeKind||(e.ColorThemeKind={}));class $t{constructor(O,Y){if(O<0)throw(0,p.illegalArgument)("start must be positive");if(Y<0)throw(0,p.illegalArgument)("end must be positive");O<=Y?(this._start=O,this._end=Y):(this._start=Y,this._end=O)}static isNotebookRange(O){return O instanceof $t?!0:O?typeof O.start=="number"&&typeof O.end=="number":!1}get start(){return this._start}get end(){return this._end}get isEmpty(){return this._start===this._end}with(O){let Y=this._start,_e=this._end;return O.start!==void 0&&(Y=O.start),O.end!==void 0&&(_e=O.end),Y===this._start&&_e===this._end?this:new $t(Y,_e)}}e.NotebookRange=$t;class qt{constructor(O,Y,_e,qe,tt,at,ct){this.kind=O,this.value=Y,this.languageId=_e,this.mime=qe,this.outputs=tt??[],this.metadata=at,this.executionSummary=ct,qt.validate(this)}static validate(O){if(typeof O.kind!="number")throw new Error("NotebookCellData MUST have 'kind' property");if(typeof O.value!="string")throw new Error("NotebookCellData MUST have 'value' property");if(typeof O.languageId!="string")throw new Error("NotebookCellData MUST have 'languageId' property")}static isNotebookCellDataArray(O){return Array.isArray(O)&&O.every(Y=>qt.isNotebookCellData(Y))}static isNotebookCellData(O){return!0}}e.NotebookCellData=qt;class Ui{constructor(O){this.cells=O}}e.NotebookData=Ui;class Bt{constructor(O,Y){this.data=O,this.mime=Y;const _e=(0,C.normalizeMimeType)(Y,!0);if(!_e)throw new Error(`INVALID mime type: ${Y}. Must be in the format "type/subtype[;optionalparameter]"`);this.mime=_e}static isNotebookCellOutputItem(O){return O instanceof Bt?!0:O?typeof O.mime=="string"&&O.data instanceof Uint8Array:!1}static error(O){const Y={name:O.name,message:O.message,stack:O.stack};return Bt.json(Y,"application/vnd.code.notebook.error")}static stdout(O){return Bt.text(O,"application/vnd.code.notebook.stdout")}static stderr(O){return Bt.text(O,"application/vnd.code.notebook.stderr")}static bytes(O,Y="application/octet-stream"){return new Bt(O,Y)}static text(O,Y=C.Mimes.text){const _e=Ae(Bt,d,"f",a).encode(String(O));return new Bt(_e,Y)}static json(O,Y="text/x-json"){const _e=JSON.stringify(O,void 0," ");return Bt.text(_e,Y)}}e.NotebookCellOutputItem=Bt,d=Bt,a={value:new TextEncoder};class li{constructor(O,Y,_e){this.items=li.ensureUniqueMimeTypes(O,!0),typeof Y=="string"?(this.id=Y,this.metadata=_e):(this.id=(0,R.generateUuid)(),this.metadata=Y??_e)}static isNotebookCellOutput(O){return O instanceof li?!0:!O||typeof O!="object"?!1:typeof O.id=="string"&&(0,E.isArray)(O.items)}static ensureUniqueMimeTypes(O,Y=!1){const _e=new Set,qe=new Set;for(let tt=0;tt<O.length;tt++){const at=O[tt],ct=(0,C.normalizeMimeType)(at.mime);if(!_e.has(ct)){_e.add(ct);continue}qe.add(tt),Y&&console.warn(`DUPLICATED mime type '${at.mime}' will be dropped`)}return qe.size===0?O:O.filter((tt,at)=>!qe.has(at))}}e.NotebookCellOutput=li;var Bi;(function(x){x[x.Markup=1]="Markup",x[x.Code=2]="Code"})(Bi=e.NotebookCellKind||(e.NotebookCellKind={}));var zi;(function(x){x[x.Idle=1]="Idle",x[x.Pending=2]="Pending",x[x.Executing=3]="Executing"})(zi=e.NotebookCellExecutionState||(e.NotebookCellExecutionState={}));var se;(function(x){x[x.Left=1]="Left",x[x.Right=2]="Right"})(se=e.NotebookCellStatusBarAlignment||(e.NotebookCellStatusBarAlignment={}));var de;(function(x){x[x.Default=0]="Default",x[x.InCenter=1]="InCenter",x[x.InCenterIfOutsideViewport=2]="InCenterIfOutsideViewport",x[x.AtTop=3]="AtTop"})(de=e.NotebookEditorRevealType||(e.NotebookEditorRevealType={}));class Oe{constructor(O,Y){this.text=O,this.alignment=Y}}e.NotebookCellStatusBarItem=Oe;var ot;(function(x){x[x.Default=1]="Default",x[x.Preferred=2]="Preferred"})(ot=e.NotebookControllerAffinity||(e.NotebookControllerAffinity={}));class wt{constructor(O,Y=[]){this.uri=O,this.provides=(0,s.asArray)(Y)}}e.NotebookRendererScript=wt;let Ct=class{constructor(O,Y){this.label=O,this.timestamp=Y}};Ct=ze([z],Ct),e.TimelineItem=Ct;var Ji;(function(x){x[x.Production=1]="Production",x[x.Development=2]="Development",x[x.Test=3]="Test"})(Ji=e.ExtensionMode||(e.ExtensionMode={}));var Zi;(function(x){x[x.Node=1]="Node",x[x.Webworker=2]="Webworker"})(Zi=e.ExtensionRuntime||(e.ExtensionRuntime={}));var en;(function(x){x[x.Other=0]="Other",x[x.Comment=1]="Comment",x[x.String=2]="String",x[x.RegEx=3]="RegEx"})(en=e.StandardTokenType||(e.StandardTokenType={}));class tn{constructor(O,Y){this.ranges=O,this.wordPattern=Y}}e.LinkedEditingRanges=tn;class nn{constructor(O,Y){this._port=O,this._autoForwardAction=Y}get port(){return this._port}get autoForwardAction(){return this._autoForwardAction}}e.PortAttributes=nn;var rn;(function(x){x[x.Queued=1]="Queued",x[x.Running=2]="Running",x[x.Passed=3]="Passed",x[x.Failed=4]="Failed",x[x.Skipped=5]="Skipped",x[x.Errored=6]="Errored"})(rn=e.TestResultState||(e.TestResultState={}));var sn;(function(x){x[x.Run=1]="Run",x[x.Debug=2]="Debug",x[x.Coverage=3]="Coverage"})(sn=e.TestRunProfileKind||(e.TestRunProfileKind={}));let xi=class{constructor(O=void 0,Y=void 0,_e=void 0){this.include=O,this.exclude=Y,this.profile=_e}};xi=ze([z],xi),e.TestRunRequest=xi;let $i=M=class{constructor(O){this.message=O}static diff(O,Y,_e){const qe=new M(O);return qe.expectedOutput=Y,qe.actualOutput=_e,qe}};$i=M=ze([z],$i),e.TestMessage=$i;let Wi=class{constructor(O){this.id=O}};Wi=ze([z],Wi),e.TestTag=Wi;let ui=class{constructor(O,Y){this.covered=O,this.total=Y}};ui=ze([z],ui),e.CoveredCount=ui;let Hi=S=class{constructor(O,Y,_e,qe){this.uri=O,this.statementCoverage=Y,this.branchCoverage=_e,this.functionCoverage=qe}static fromDetails(O,Y){const _e=new ui(0,0),qe=new ui(0,0),tt=new ui(0,0);for(const ct of Y)if("branches"in ct){_e.total+=1,_e.covered+=ct.executionCount>0?1:0;for(const St of ct.branches)qe.total+=1,qe.covered+=St.executionCount>0?1:0}else tt.total+=1,tt.covered+=ct.executionCount>0?1:0;const at=new S(O,_e,qe.total>0?qe:void 0,tt.total>0?tt:void 0);return at.detailedCoverage=Y,at}};Hi=S=ze([z],Hi),e.FileCoverage=Hi;let Vi=class{constructor(O,Y,_e=[]){this.executionCount=O,this.location=Y,this.branches=_e}};Vi=ze([z],Vi),e.StatementCoverage=Vi;let ji=class{constructor(O,Y){this.executionCount=O,this.location=Y}};ji=ze([z],ji),e.BranchCoverage=ji;let qi=class{constructor(O,Y){this.executionCount=O,this.location=Y}};qi=ze([z],qi),e.FunctionCoverage=qi;var on;(function(x){x[x.None=0]="None",x[x.Option=1]="Option",x[x.Default=2]="Default",x[x.Preferred=3]="Preferred"})(on=e.ExternalUriOpenerPriority||(e.ExternalUriOpenerPriority={}));var an;(function(x){x[x.Untrusted=0]="Untrusted",x[x.Trusted=1]="Trusted",x[x.Unspecified=2]="Unspecified"})(an=e.WorkspaceTrustState||(e.WorkspaceTrustState={}));var cn;(function(x){x[x.Notify=1]="Notify",x[x.OpenBrowser=2]="OpenBrowser",x[x.OpenPreview=3]="OpenPreview",x[x.Silent=4]="Silent",x[x.Ignore=5]="Ignore",x[x.OpenBrowserOnce=6]="OpenBrowserOnce"})(cn=e.PortAutoForwardAction||(e.PortAutoForwardAction={}));class ln{constructor(O,Y,_e,qe,tt,at){this.kind=O,this.name=Y,this.detail=_e,this.uri=qe,this.range=tt,this.selectionRange=at}}e.TypeHierarchyItem=ln;class un{constructor(O){this.uri=O}}e.TextTabInput=un;class dn{constructor(O,Y){this.original=O,this.modified=Y}}e.TextDiffTabInput=dn;class hn{constructor(O,Y,_e,qe){this.base=O,this.input1=Y,this.input2=_e,this.result=qe}}e.TextMergeTabInput=hn;class fn{constructor(O,Y){this.uri=O,this.viewType=Y}}e.CustomEditorTabInput=fn;class mn{constructor(O){this.viewType=O}}e.WebviewEditorTabInput=mn;class gn{constructor(O,Y){this.uri=O,this.notebookType=Y}}e.NotebookEditorTabInput=gn;class pn{constructor(O,Y,_e){this.original=O,this.modified=Y,this.notebookType=_e}}e.NotebookDiffEditorTabInput=pn;class vn{constructor(){}}e.TerminalEditorTabInput=vn;class En{constructor(O,Y){this.uri=O,this.inputBoxUri=Y}}e.InteractiveWindowInput=En}),define(ye[87],Ce([1,0,42,12,9,239,121,6,16]),function(ee,e,s,p,b,L,C,T,E){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.ExtHostDocumentLine=e.ExtHostDocumentData=e.getWordDefinitionFor=e.setWordDefinitionFor=void 0;const A=new Map;function R(f,h){h?A.set(f,h):A.delete(f)}e.setWordDefinitionFor=R;function y(f){return A.get(f)}e.getWordDefinitionFor=y;class m extends L.MirrorTextModel{constructor(h,d,a,w,P,l,_,n){super(d,a,w,P);this._proxy=h,this._languageId=l,this._isDirty=_,this.notebook=n,this._isDisposed=!1}dispose(){(0,s.ok)(!this._isDisposed),this._isDisposed=!0,this._isDirty=!1}equalLines(h){return(0,E.equals)(this._lines,h)}get document(){if(!this._document){const h=this;this._document={get uri(){return h._uri},get fileName(){return h._uri.fsPath},get isUntitled(){return h._uri.scheme===p.Schemas.untitled},get languageId(){return h._languageId},get version(){return h._versionId},get isClosed(){return h._isDisposed},get isDirty(){return h._isDirty},save(){return h._save()},getText(d){return d?h._getTextInRange(d):h.getText()},get eol(){return h._eol===`
`?T.EndOfLine.LF:T.EndOfLine.CRLF},get lineCount(){return h._lines.length},lineAt(d){return h._lineAt(d)},offsetAt(d){return h._offsetAt(d)},positionAt(d){return h._positionAt(d)},validateRange(d){return h._validateRange(d)},validatePosition(d){return h._validatePosition(d)},getWordRangeAtPosition(d,a){return h._getWordRangeAtPosition(d,a)}}}return Object.freeze(this._document)}_acceptLanguageId(h){(0,s.ok)(!this._isDisposed),this._languageId=h}_acceptIsDirty(h){(0,s.ok)(!this._isDisposed),this._isDirty=h}_save(){return this._isDisposed?Promise.reject(new Error("Document has been closed")):this._proxy.$trySaveDocument(this._uri)}_getTextInRange(h){const d=this._validateRange(h);if(d.isEmpty)return"";if(d.isSingleLine)return this._lines[d.start.line].substring(d.start.character,d.end.character);const a=this._eol,w=d.start.line,P=d.end.line,l=[];l.push(this._lines[w].substring(d.start.character));for(let _=w+1;_<P;_++)l.push(this._lines[_]);return l.push(this._lines[P].substring(0,d.end.character)),l.join(a)}_lineAt(h){let d;if(h instanceof T.Position?d=h.line:typeof h=="number"&&(d=h),typeof d!="number"||d<0||d>=this._lines.length||Math.floor(d)!==d)throw new Error("Illegal value for `line`");return new I(d,this._lines[d],d===this._lines.length-1)}_offsetAt(h){return h=this._validatePosition(h),this._ensureLineStarts(),this._lineStarts.getPrefixSum(h.line-1)+h.character}_positionAt(h){h=Math.floor(h),h=Math.max(0,h),this._ensureLineStarts();const d=this._lineStarts.getIndexOf(h),a=this._lines[d.index].length;return new T.Position(d.index,Math.min(d.remainder,a))}_validateRange(h){if(!(h instanceof T.Range))throw new Error("Invalid argument");const d=this._validatePosition(h.start),a=this._validatePosition(h.end);return d===h.start&&a===h.end?h:new T.Range(d.line,d.character,a.line,a.character)}_validatePosition(h){if(!(h instanceof T.Position))throw new Error("Invalid argument");if(this._lines.length===0)return h.with(0,0);let{line:d,character:a}=h,w=!1;if(d<0)d=0,a=0,w=!0;else if(d>=this._lines.length)d=this._lines.length-1,a=this._lines[d].length,w=!0;else{const P=this._lines[d].length;a<0?(a=0,w=!0):a>P&&(a=P,w=!0)}return w?new T.Position(d,a):h}_getWordRangeAtPosition(h,d){const a=this._validatePosition(h);if(!d)d=y(this._languageId);else if((0,b.regExpLeadsToEndlessLoop)(d))throw new Error(`[getWordRangeAtPosition]: ignoring custom regexp '${d.source}' because it matches the empty string.`);const w=(0,C.getWordAtText)(a.character+1,(0,C.ensureValidWordDefinition)(d),this._lines[a.line],0);if(w)return new T.Range(a.line,w.startColumn-1,a.line,w.endColumn-1)}}e.ExtHostDocumentData=m;class I{constructor(h,d,a){this._line=h,this._text=d,this._isLastLine=a}get lineNumber(){return this._line}get text(){return this._text}get range(){return new T.Range(this._line,0,this._line,this._text.length)}get rangeIncludingLineBreak(){return this._isLastLine?this.range:new T.Range(this._line,0,this._line+1,0)}get firstNonWhitespaceCharacterIndex(){return/^(\s*)/.exec(this._text)[1].length}get isEmptyOrWhitespace(){return this.firstNonWhitespaceCharacterIndex===this._text.length}}e.ExtHostDocumentLine=I}),define(ye[160],Ce([1,0,6,15,4]),function(ee,e,s,p,b){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.ExtHostTheming=void 0;let L=class{constructor(T){this._actual=new s.ColorTheme(s.ColorThemeKind.Dark),this._onDidChangeActiveColorTheme=new b.Emitter}get activeColorTheme(){return this._actual}$onColorThemeChange(T){let E;switch(T){case"light":E=s.ColorThemeKind.Light;break;case"hcDark":E=s.ColorThemeKind.HighContrast;break;case"hcLight":E=s.ColorThemeKind.HighContrastLight;break;default:E=s.ColorThemeKind.Dark}this._actual=new s.ColorTheme(E),this._onDidChangeActiveColorTheme.fire(this._actual)}get onDidChangeActiveColorTheme(){return this._onDidChangeActiveColorTheme.event}};L=ze([xe(0,p.IExtHostRpcService)],L),e.ExtHostTheming=L}),define(ye[63],Ce([1,0,3]),function(ee,e,s){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.URITransformerService=e.IURITransformerService=void 0,e.IURITransformerService=(0,s.createDecorator)("IURITransformerService");class p{constructor(L){L?(this.transformIncoming=L.transformIncoming.bind(L),this.transformOutgoing=L.transformOutgoing.bind(L),this.transformOutgoingURI=L.transformOutgoingURI.bind(L),this.transformOutgoingScheme=L.transformOutgoingScheme.bind(L)):(this.transformIncoming=C=>C,this.transformOutgoing=C=>C,this.transformOutgoingURI=C=>C,this.transformOutgoingScheme=C=>C)}}e.URITransformerService=p}),define(ye[161],Ce([1,0,22]),function(ee,e,s){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.deserializeWebviewMessage=e.serializeWebviewMessage=void 0;class p{constructor(){this.buffers=[]}add(E){let A=this.buffers.indexOf(E);return A<0&&(A=this.buffers.length,this.buffers.push(E)),A}}function b(T,E){if(E.serializeBuffersForPostMessage){const A=new p,R=(I,f)=>{if(f instanceof ArrayBuffer){const h=A.add(f);return{$$vscode_array_buffer_reference$$:!0,index:h}}else if(ArrayBuffer.isView(f)){const h=L(f);if(h){const d=A.add(f.buffer);return{$$vscode_array_buffer_reference$$:!0,index:d,view:{type:h,byteLength:f.byteLength,byteOffset:f.byteOffset}}}}return f},y=JSON.stringify(T,R),m=A.buffers.map(I=>{const f=new Uint8Array(I);return s.VSBuffer.wrap(f)});return{message:y,buffers:m}}else return{message:JSON.stringify(T),buffers:[]}}e.serializeWebviewMessage=b;function L(T){switch(T.constructor.name){case"Int8Array":return 1;case"Uint8Array":return 2;case"Uint8ClampedArray":return 3;case"Int16Array":return 4;case"Uint16Array":return 5;case"Int32Array":return 6;case"Uint32Array":return 7;case"Float32Array":return 8;case"Float64Array":return 9;case"BigInt64Array":return 10;case"BigUint64Array":return 11}}function C(T,E){const A=E.map(m=>{const I=new ArrayBuffer(m.byteLength);return new Uint8Array(I).set(m.buffer),I}),R=E.length?(m,I)=>{if(I&&typeof I=="object"&&I.$$vscode_array_buffer_reference$$){const f=I,{index:h}=f,d=A[h];if(f.view)switch(f.view.type){case 1:return new Int8Array(d,f.view.byteOffset,f.view.byteLength/Int8Array.BYTES_PER_ELEMENT);case 2:return new Uint8Array(d,f.view.byteOffset,f.view.byteLength/Uint8Array.BYTES_PER_ELEMENT);case 3:return new Uint8ClampedArray(d,f.view.byteOffset,f.view.byteLength/Uint8ClampedArray.BYTES_PER_ELEMENT);case 4:return new Int16Array(d,f.view.byteOffset,f.view.byteLength/Int16Array.BYTES_PER_ELEMENT);case 5:return new Uint16Array(d,f.view.byteOffset,f.view.byteLength/Uint16Array.BYTES_PER_ELEMENT);case 6:return new Int32Array(d,f.view.byteOffset,f.view.byteLength/Int32Array.BYTES_PER_ELEMENT);case 7:return new Uint32Array(d,f.view.byteOffset,f.view.byteLength/Uint32Array.BYTES_PER_ELEMENT);case 8:return new Float32Array(d,f.view.byteOffset,f.view.byteLength/Float32Array.BYTES_PER_ELEMENT);case 9:return new Float64Array(d,f.view.byteOffset,f.view.byteLength/Float64Array.BYTES_PER_ELEMENT);case 10:return new BigInt64Array(d,f.view.byteOffset,f.view.byteLength/BigInt64Array.BYTES_PER_ELEMENT);case 11:return new BigUint64Array(d,f.view.byteOffset,f.view.byteLength/BigUint64Array.BYTES_PER_ELEMENT);default:throw new Error("Unknown array buffer view type")}return d}return I}:void 0;return{message:JSON.parse(T,R),arrayBuffers:A}}e.deserializeWebviewMessage=C}),define(ye[162],Ce([1,0,135,10,2,7,3,30,39,16,12]),function(ee,e,s,p,b,L,C,T,E,A,R){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.isTextEditorViewState=e.EditorsOrder=e.pathsToEditors=e.CloseDirection=e.EditorResourceAccessor=e.SideBySideEditor=e.GroupModelChangeKind=e.EditorCloseContext=e.isEditorIdentifier=e.isEditorInputWithOptionsAndGroup=e.isEditorInputWithOptions=e.isDiffEditorInput=e.isSideBySideEditorInput=e.isEditorInput=e.AbstractEditorInput=e.EditorInputCapabilities=e.SaveSourceRegistry=e.SaveReason=e.Verbosity=e.isResourceMergeEditorInput=e.isUntitledResourceEditorInput=e.isResourceSideBySideEditorInput=e.isResourceDiffEditorInput=e.isResourceEditorInput=e.findViewStateForEditor=e.isEditorPaneWithSelection=e.EditorPaneSelectionCompareResult=e.EditorPaneSelectionChangeReason=e.BINARY_DIFF_EDITOR_ID=e.TEXT_DIFF_EDITOR_ID=e.SIDE_BY_SIDE_EDITOR_ID=e.DEFAULT_EDITOR_ASSOCIATION=e.EditorExtensions=void 0,e.EditorExtensions={EditorPane:"workbench.contributions.editors",EditorFactory:"workbench.contributions.editor.inputFactories"},e.DEFAULT_EDITOR_ASSOCIATION={id:"default",displayName:(0,s.localize)(0,null),providerDisplayName:(0,s.localize)(1,null)},e.SIDE_BY_SIDE_EDITOR_ID="workbench.editor.sidebysideEditor",e.TEXT_DIFF_EDITOR_ID="workbench.editors.textDiffEditor",e.BINARY_DIFF_EDITOR_ID="workbench.editors.binaryResourceDiffEditor";var y;(function(F){F[F.PROGRAMMATIC=1]="PROGRAMMATIC",F[F.USER=2]="USER",F[F.EDIT=3]="EDIT",F[F.NAVIGATION=4]="NAVIGATION",F[F.JUMP=5]="JUMP"})(y=e.EditorPaneSelectionChangeReason||(e.EditorPaneSelectionChangeReason={}));var m;(function(F){F[F.IDENTICAL=1]="IDENTICAL",F[F.SIMILAR=2]="SIMILAR",F[F.DIFFERENT=3]="DIFFERENT"})(m=e.EditorPaneSelectionCompareResult||(e.EditorPaneSelectionCompareResult={}));function I(F){const ne=F;return!!ne&&typeof ne.getSelection=="function"&&!!ne.onDidChangeSelection}e.isEditorPaneWithSelection=I;function f(F,ne,ce){for(const re of ce.visibleEditorPanes)if(re.group.id===ne&&F.matches(re.input))return re.getViewState()}e.findViewStateForEditor=f;function h(F){if(o(F))return!1;const ne=F;return b.URI.isUri(ne?.resource)}e.isResourceEditorInput=h;function d(F){if(o(F))return!1;const ne=F;return ne?.original!==void 0&&ne.modified!==void 0}e.isResourceDiffEditorInput=d;function a(F){if(o(F)||d(F))return!1;const ne=F;return ne?.primary!==void 0&&ne.secondary!==void 0}e.isResourceSideBySideEditorInput=a;function w(F){if(o(F))return!1;const ne=F;return ne?ne.resource===void 0||ne.resource.scheme===R.Schemas.untitled||ne.forceUntitled===!0:!1}e.isUntitledResourceEditorInput=w;function P(F){if(o(F))return!1;const ne=F;return b.URI.isUri(ne?.base?.resource)&&b.URI.isUri(ne?.input1?.resource)&&b.URI.isUri(ne?.input2?.resource)&&b.URI.isUri(ne?.result?.resource)}e.isResourceMergeEditorInput=P;var l;(function(F){F[F.SHORT=0]="SHORT",F[F.MEDIUM=1]="MEDIUM",F[F.LONG=2]="LONG"})(l=e.Verbosity||(e.Verbosity={}));var _;(function(F){F[F.EXPLICIT=1]="EXPLICIT",F[F.AUTO=2]="AUTO",F[F.FOCUS_CHANGE=3]="FOCUS_CHANGE",F[F.WINDOW_CHANGE=4]="WINDOW_CHANGE"})(_=e.SaveReason||(e.SaveReason={}));class n{constructor(){this.mapIdToSaveSource=new Map}registerSource(ne,ce){let re=this.mapIdToSaveSource.get(ne);return re||(re={source:ne,label:ce},this.mapIdToSaveSource.set(ne,re)),re.source}getSourceLabel(ne){return this.mapIdToSaveSource.get(ne)?.label??ne}}e.SaveSourceRegistry=new n;var u;(function(F){F[F.None=0]="None",F[F.Readonly=2]="Readonly",F[F.Untitled=4]="Untitled",F[F.Singleton=8]="Singleton",F[F.RequiresTrust=16]="RequiresTrust",F[F.CanSplitInGroup=32]="CanSplitInGroup",F[F.ForceDescription=64]="ForceDescription",F[F.CanDropIntoEditor=128]="CanDropIntoEditor",F[F.MultipleEditors=256]="MultipleEditors"})(u=e.EditorInputCapabilities||(e.EditorInputCapabilities={}));class i extends L.Disposable{}e.AbstractEditorInput=i;function o(F){return F instanceof i}e.isEditorInput=o;function r(F){const ne=F;return b.URI.isUri(ne?.preferredResource)}function t(F){const ne=F;return o(ne?.primary)&&o(ne?.secondary)}e.isSideBySideEditorInput=t;function c(F){const ne=F;return o(ne?.modified)&&o(ne?.original)}e.isDiffEditorInput=c;function v(F){return o(F?.editor)}e.isEditorInputWithOptions=v;function g(F){const ne=F;return v(F)&&ne?.group!==void 0}e.isEditorInputWithOptionsAndGroup=g;function D(F){const ne=F;return typeof ne?.groupId=="number"&&o(ne.editor)}e.isEditorIdentifier=D;var U;(function(F){F[F.UNKNOWN=0]="UNKNOWN",F[F.REPLACE=1]="REPLACE",F[F.MOVE=2]="MOVE",F[F.UNPIN=3]="UNPIN"})(U=e.EditorCloseContext||(e.EditorCloseContext={}));var W;(function(F){F[F.GROUP_ACTIVE=0]="GROUP_ACTIVE",F[F.GROUP_INDEX=1]="GROUP_INDEX",F[F.GROUP_LOCKED=2]="GROUP_LOCKED",F[F.EDITOR_OPEN=3]="EDITOR_OPEN",F[F.EDITOR_CLOSE=4]="EDITOR_CLOSE",F[F.EDITOR_MOVE=5]="EDITOR_MOVE",F[F.EDITOR_ACTIVE=6]="EDITOR_ACTIVE",F[F.EDITOR_LABEL=7]="EDITOR_LABEL",F[F.EDITOR_CAPABILITIES=8]="EDITOR_CAPABILITIES",F[F.EDITOR_PIN=9]="EDITOR_PIN",F[F.EDITOR_STICKY=10]="EDITOR_STICKY",F[F.EDITOR_DIRTY=11]="EDITOR_DIRTY",F[F.EDITOR_WILL_DISPOSE=12]="EDITOR_WILL_DISPOSE"})(W=e.GroupModelChangeKind||(e.GroupModelChangeKind={}));var M;(function(F){F[F.PRIMARY=1]="PRIMARY",F[F.SECONDARY=2]="SECONDARY",F[F.BOTH=3]="BOTH",F[F.ANY=4]="ANY"})(M=e.SideBySideEditor||(e.SideBySideEditor={}));class S{getOriginalUri(ne,ce){if(!ne)return;if(P(ne))return e.EditorResourceAccessor.getOriginalUri(ne.result,ce);if(ce?.supportSideBySide){const{primary:fe,secondary:ie}=this.getSideEditors(ne);if(fe&&ie){if(ce?.supportSideBySide===M.BOTH)return{primary:this.getOriginalUri(fe,{filterByScheme:ce.filterByScheme}),secondary:this.getOriginalUri(ie,{filterByScheme:ce.filterByScheme})};if(ce?.supportSideBySide===M.ANY)return this.getOriginalUri(fe,{filterByScheme:ce.filterByScheme})??this.getOriginalUri(ie,{filterByScheme:ce.filterByScheme});ne=ce.supportSideBySide===M.PRIMARY?fe:ie}}if(d(ne)||a(ne)||P(ne))return;const re=r(ne)?ne.preferredResource:ne.resource;return!re||!ce||!ce.filterByScheme?re:this.filterUri(re,ce.filterByScheme)}getSideEditors(ne){return t(ne)||a(ne)?{primary:ne.primary,secondary:ne.secondary}:c(ne)||d(ne)?{primary:ne.modified,secondary:ne.original}:{primary:void 0,secondary:void 0}}getCanonicalUri(ne,ce){if(!ne)return;if(P(ne))return e.EditorResourceAccessor.getCanonicalUri(ne.result,ce);if(ce?.supportSideBySide){const{primary:fe,secondary:ie}=this.getSideEditors(ne);if(fe&&ie){if(ce?.supportSideBySide===M.BOTH)return{primary:this.getCanonicalUri(fe,{filterByScheme:ce.filterByScheme}),secondary:this.getCanonicalUri(ie,{filterByScheme:ce.filterByScheme})};if(ce?.supportSideBySide===M.ANY)return this.getCanonicalUri(fe,{filterByScheme:ce.filterByScheme})??this.getCanonicalUri(ie,{filterByScheme:ce.filterByScheme});ne=ce.supportSideBySide===M.PRIMARY?fe:ie}}if(d(ne)||a(ne)||P(ne))return;const re=ne.resource;return!re||!ce||!ce.filterByScheme?re:this.filterUri(re,ce.filterByScheme)}filterUri(ne,ce){if(Array.isArray(ce)){if(ce.some(re=>ne.scheme===re))return ne}else if(ce===ne.scheme)return ne}}e.EditorResourceAccessor=new S;var z;(function(F){F[F.LEFT=0]="LEFT",F[F.RIGHT=1]="RIGHT"})(z=e.CloseDirection||(e.CloseDirection={}));class ${constructor(){this.editorSerializerConstructors=new Map,this.editorSerializerInstances=new Map}start(ne){const ce=this.instantiationService=ne.get(C.IInstantiationService);for(const[re,fe]of this.editorSerializerConstructors)this.createEditorSerializer(re,fe,ce);this.editorSerializerConstructors.clear()}createEditorSerializer(ne,ce,re){const fe=re.createInstance(ce);this.editorSerializerInstances.set(ne,fe)}registerFileEditorFactory(ne){if(this.fileEditorFactory)throw new Error("Can only register one file editor factory.");this.fileEditorFactory=ne}getFileEditorFactory(){return(0,p.assertIsDefined)(this.fileEditorFactory)}registerEditorSerializer(ne,ce){if(this.editorSerializerConstructors.has(ne)||this.editorSerializerInstances.has(ne))throw new Error(`A editor serializer with type ID '${ne}' was already registered.`);return this.instantiationService?this.createEditorSerializer(ne,ce,this.instantiationService):this.editorSerializerConstructors.set(ne,ce),(0,L.toDisposable)(()=>{this.editorSerializerConstructors.delete(ne),this.editorSerializerInstances.delete(ne)})}getEditorSerializer(ne){return this.editorSerializerInstances.get(typeof ne=="string"?ne:ne.typeId)}}T.Registry.add(e.EditorExtensions.EditorFactory,new $);async function N(F,ne){if(!F||!F.length)return[];const ce=await Promise.all(F.map(async re=>{const fe=b.URI.revive(re.fileUri);if(!fe||!await ne.canHandleResource(fe))return;let Ee=re.exists,be=re.type;if(typeof Ee!="boolean"||typeof be!="number")try{be=(await ne.stat(fe)).isDirectory?E.FileType.Directory:E.FileType.Unknown,Ee=!0}catch{Ee=!1}if(!Ee&&re.openOnlyIfExists||be===E.FileType.Directory)return;const te={...re.options,pinned:!0};let ve;return Ee?ve={resource:fe,options:te}:ve={resource:fe,options:te,forceUntitled:!0},ve}));return(0,A.coalesce)(ce)}e.pathsToEditors=N;var K;(function(F){F[F.MOST_RECENTLY_ACTIVE=0]="MOST_RECENTLY_ACTIVE",F[F.SEQUENTIAL=1]="SEQUENTIAL"})(K=e.EditorsOrder||(e.EditorsOrder={}));function V(F){const ne=F;if(!ne)return!1;const ce=ne;if(ce.modified)return V(ce.modified);const re=ne;return!!(re.contributionsState&&re.viewState&&Array.isArray(re.cursorState))}e.isTextEditorViewState=V}),define(ye[64],Ce([1,0,12,2]),function(ee,e,s,p){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.decodeAuthority=e.asWebviewUri=e.webviewGenericCspSource=e.webviewRootResourceAuthority=e.webviewResourceBaseHost=void 0,e.webviewResourceBaseHost="vscode-cdn.net",e.webviewRootResourceAuthority=`vscode-resource.${e.webviewResourceBaseHost}`,e.webviewGenericCspSource=`'self' https://*.${e.webviewResourceBaseHost}`;function b(T,E){return T.scheme===s.Schemas.http||T.scheme===s.Schemas.https?T:(E&&E.authority&&E.isRemote&&T.scheme===s.Schemas.file&&(T=p.URI.from({scheme:s.Schemas.vscodeRemote,authority:E.authority,path:T.path})),p.URI.from({scheme:s.Schemas.https,authority:`${T.scheme}+${L(T.authority)}.${e.webviewRootResourceAuthority}`,path:T.path,fragment:T.fragment,query:T.query}))}e.asWebviewUri=b;function L(T){return T.replace(/./g,E=>{const A=E.charCodeAt(0);return A>=97&&A<=122||A>=65&&A<=90||A>=48&&A<=57?E:"-"+A.toString(16).padStart(4,"0")})}function C(T){return T.replace(/-([0-9a-f]{4})/g,(E,A)=>String.fromCharCode(parseInt(A,16)))}e.decodeAuthority=C}),define(ye[163],Ce([1,0,4,7,64]),function(ee,e,s,p,b){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.ExtHostEditorInsets=void 0;class L{constructor(T,E,A){this._proxy=T,this._editors=E,this._remoteInfo=A,this._handlePool=0,this._disposables=new p.DisposableStore,this._insets=new Map,this._disposables.add(E.onDidChangeVisibleTextEditors(()=>{const R=E.getVisibleTextEditors();for(const y of this._insets.values())R.indexOf(y.editor)<0&&y.inset.dispose()}))}dispose(){this._insets.forEach(T=>T.inset.dispose()),this._disposables.dispose()}createWebviewEditorInset(T,E,A,R,y){let m;for(const P of this._editors.getVisibleTextEditors(!0))if(P.value===T){m=P;break}if(!m)throw new Error("not a visible editor");const I=this,f=this._handlePool++,h=new s.Emitter,d=new s.Emitter,a=new class{constructor(){this._html="",this._options=Object.create(null)}asWebviewUri(P){return(0,b.asWebviewUri)(P,I._remoteInfo)}get cspSource(){return b.webviewGenericCspSource}set options(P){this._options=P,I._proxy.$setOptions(f,P)}get options(){return this._options}set html(P){this._html=P,I._proxy.$setHtml(f,P)}get html(){return this._html}get onDidReceiveMessage(){return h.event}postMessage(P){return I._proxy.$postMessage(f,P)}},w=new class{constructor(){this.editor=T,this.line=E,this.height=A,this.webview=a,this.onDidDispose=d.event}dispose(){I._insets.has(f)&&(I._insets.delete(f),I._proxy.$disposeEditorInset(f),d.fire(),d.dispose(),h.dispose())}};return this._proxy.$createEditorInset(f,m.id,m.value.document.uri,E+1,A,R||{},y.identifier,y.extensionLocation),this._insets.set(f,{editor:T,inset:w,onDidReceiveMessage:h}),w}$onDidDispose(T){const E=this._insets.get(T);E&&E.inset.dispose()}$onDidReceiveMessage(T,E){this._insets.get(T)?.onDidReceiveMessage.fire(E)}}e.ExtHostEditorInsets=L}),define(ye[164],Ce([1,0,4,13,136]),function(ee,e,s,p,b){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.AbstractDebugAdapter=void 0;class L{constructor(){this.pendingRequests=new Map,this.queue=[],this._onError=new s.Emitter,this._onExit=new s.Emitter,this.sequence=1}get onError(){return this._onError.event}get onExit(){return this._onExit.event}onMessage(T){this.messageCallback&&this._onError.fire(new Error("attempt to set more than one 'Message' callback")),this.messageCallback=T}onEvent(T){this.eventCallback&&this._onError.fire(new Error("attempt to set more than one 'Event' callback")),this.eventCallback=T}onRequest(T){this.requestCallback&&this._onError.fire(new Error("attempt to set more than one 'Request' callback")),this.requestCallback=T}sendResponse(T){T.seq>0?this._onError.fire(new Error(`attempt to send more than one response for command ${T.command}`)):this.internalSend("response",T)}sendRequest(T,E,A,R){const y={command:T};if(E&&Object.keys(E).length>0&&(y.arguments=E),this.internalSend("request",y),typeof R=="number"){const m=setTimeout(()=>{clearTimeout(m);const I=this.pendingRequests.get(y.seq);if(I){this.pendingRequests.delete(y.seq);const f={type:"response",seq:0,request_seq:y.seq,success:!1,command:T,message:(0,b.localize)(0,null,R,T)};I(f)}},R)}return A&&this.pendingRequests.set(y.seq,A),y.seq}acceptMessage(T){this.messageCallback?this.messageCallback(T):(this.queue.push(T),this.queue.length===1&&this.processQueue())}needsTaskBoundaryBetween(T,E){return T.type!=="event"||E.type!=="event"}async processQueue(){let T;for(;this.queue.length;){if((!T||this.needsTaskBoundaryBetween(this.queue[0],T))&&await(0,p.timeout)(0),T=this.queue.shift(),!T)return;switch(T.type){case"event":this.eventCallback?.(T);break;case"request":this.requestCallback?.(T);break;case"response":{const E=T,A=this.pendingRequests.get(E.request_seq);A&&(this.pendingRequests.delete(E.request_seq),A(E));break}}}}internalSend(T,E){E.type=T,E.seq=this.sequence++,this.sendMessage(E)}async cancelPendingRequests(){if(this.pendingRequests.size===0)return Promise.resolve();const T=new Map;this.pendingRequests.forEach((E,A)=>T.set(A,E)),await(0,p.timeout)(500),T.forEach((E,A)=>{E({type:"response",seq:0,request_seq:A,success:!1,command:"canceled",message:"canceled"}),this.pendingRequests.delete(A)})}getPendingRequestIds(){return Array.from(this.pendingRequests.keys())}dispose(){this.queue=[]}}e.AbstractDebugAdapter=L}),define(ye[165],Ce([1,0,137,38,3]),function(ee,e,s,p,b){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.BreakpointWidgetContext=e.IDebugService=e.DebuggerUiMessage=e.DebugConfigurationProviderTriggerKind=e.DEBUG_MEMORY_SCHEME=e.MemoryRangeType=e.getStateLabel=e.State=e.INTERNAL_CONSOLE_OPTIONS_SCHEMA=e.DEBUG_SCHEME=e.BREAKPOINT_EDITOR_CONTRIBUTION_ID=e.EDITOR_CONTRIBUTION_ID=e.debuggerDisabledMessage=e.CONTEXT_FOCUSED_STACK_FRAME_HAS_INSTRUCTION_POINTER_REFERENCE=e.CONTEXT_LANGUAGE_SUPPORTS_DISASSEMBLE_REQUEST=e.CONTEXT_DISASSEMBLY_VIEW_FOCUS=e.CONTEXT_DISASSEMBLE_REQUEST_SUPPORTED=e.CONTEXT_MULTI_SESSION_DEBUG=e.CONTEXT_MULTI_SESSION_REPL=e.CONTEXT_EXCEPTION_WIDGET_VISIBLE=e.CONTEXT_VARIABLE_IS_READONLY=e.CONTEXT_VARIABLE_EVALUATE_NAME_PRESENT=e.CONTEXT_SUSPEND_DEBUGGEE_SUPPORTED=e.CONTEXT_TERMINATE_DEBUGGEE_SUPPORTED=e.CONTEXT_BREAK_WHEN_VALUE_IS_READ_SUPPORTED=e.CONTEXT_BREAK_WHEN_VALUE_IS_ACCESSED_SUPPORTED=e.CONTEXT_BREAK_WHEN_VALUE_CHANGES_SUPPORTED=e.CONTEXT_SET_EXPRESSION_SUPPORTED=e.CONTEXT_SET_VARIABLE_SUPPORTED=e.CONTEXT_DEBUG_PROTOCOL_VARIABLE_MENU_CONTEXT=e.CONTEXT_DEBUG_EXTENSION_AVAILABLE=e.CONTEXT_DEBUGGERS_AVAILABLE=e.CONTEXT_BREAKPOINTS_EXIST=e.CONTEXT_STEP_INTO_TARGETS_SUPPORTED=e.CONTEXT_JUMP_TO_CURSOR_SUPPORTED=e.CONTEXT_STACK_FRAME_SUPPORTS_RESTART=e.CONTEXT_RESTART_FRAME_SUPPORTED=e.CONTEXT_STEP_BACK_SUPPORTED=e.CONTEXT_FOCUSED_SESSION_IS_ATTACH=e.CONTEXT_LOADED_SCRIPTS_ITEM_TYPE=e.CONTEXT_LOADED_SCRIPTS_SUPPORTED=e.CONTEXT_BREAKPOINT_SUPPORTS_CONDITION=e.CONTEXT_BREAKPOINT_ACCESS_TYPE=e.CONTEXT_BREAKPOINT_ITEM_TYPE=e.CONTEXT_CAN_VIEW_MEMORY=e.CONTEXT_WATCH_ITEM_TYPE=e.CONTEXT_CALLSTACK_SESSION_HAS_ONE_THREAD=e.CONTEXT_CALLSTACK_ITEM_STOPPED=e.CONTEXT_CALLSTACK_SESSION_IS_ATTACH=e.CONTEXT_CALLSTACK_ITEM_TYPE=e.CONTEXT_BREAKPOINT_INPUT_FOCUSED=e.CONTEXT_EXPRESSION_SELECTED=e.CONTEXT_VARIABLES_FOCUSED=e.CONTEXT_WATCH_EXPRESSIONS_EXIST=e.CONTEXT_WATCH_EXPRESSIONS_FOCUSED=e.CONTEXT_BREAKPOINTS_FOCUSED=e.CONTEXT_IN_BREAKPOINT_WIDGET=e.CONTEXT_BREAKPOINT_WIDGET_VISIBLE=e.CONTEXT_IN_DEBUG_REPL=e.CONTEXT_IN_DEBUG_MODE=e.CONTEXT_DEBUG_UX=e.CONTEXT_DEBUG_UX_KEY=e.CONTEXT_DEBUG_STATE=e.CONTEXT_DEBUG_CONFIGURATION_TYPE=e.CONTEXT_DEBUG_TYPE=e.DEBUG_SERVICE_ID=e.REPL_VIEW_ID=e.DEBUG_PANEL_ID=e.DISASSEMBLY_VIEW_ID=e.BREAKPOINTS_VIEW_ID=e.LOADED_SCRIPTS_VIEW_ID=e.CALLSTACK_VIEW_ID=e.WATCH_VIEW_ID=e.VARIABLES_VIEW_ID=e.VIEWLET_ID=void 0,e.VIEWLET_ID="workbench.view.debug",e.VARIABLES_VIEW_ID="workbench.debug.variablesView",e.WATCH_VIEW_ID="workbench.debug.watchExpressionsView",e.CALLSTACK_VIEW_ID="workbench.debug.callStackView",e.LOADED_SCRIPTS_VIEW_ID="workbench.debug.loadedScriptsView",e.BREAKPOINTS_VIEW_ID="workbench.debug.breakPointsView",e.DISASSEMBLY_VIEW_ID="workbench.debug.disassemblyView",e.DEBUG_PANEL_ID="workbench.panel.repl",e.REPL_VIEW_ID="workbench.panel.repl.view",e.DEBUG_SERVICE_ID="debugService",e.CONTEXT_DEBUG_TYPE=new p.RawContextKey("debugType",void 0,{type:"string",description:s.localize(0,null)}),e.CONTEXT_DEBUG_CONFIGURATION_TYPE=new p.RawContextKey("debugConfigurationType",void 0,{type:"string",description:s.localize(1,null)}),e.CONTEXT_DEBUG_STATE=new p.RawContextKey("debugState","inactive",{type:"string",description:s.localize(2,null)}),e.CONTEXT_DEBUG_UX_KEY="debugUx",e.CONTEXT_DEBUG_UX=new p.RawContextKey(e.CONTEXT_DEBUG_UX_KEY,"default",{type:"string",description:s.localize(3,null)}),e.CONTEXT_IN_DEBUG_MODE=new p.RawContextKey("inDebugMode",!1,{type:"boolean",description:s.localize(4,null)}),e.CONTEXT_IN_DEBUG_REPL=new p.RawContextKey("inDebugRepl",!1,{type:"boolean",description:s.localize(5,null)}),e.CONTEXT_BREAKPOINT_WIDGET_VISIBLE=new p.RawContextKey("breakpointWidgetVisible",!1,{type:"boolean",description:s.localize(6,null)}),e.CONTEXT_IN_BREAKPOINT_WIDGET=new p.RawContextKey("inBreakpointWidget",!1,{type:"boolean",description:s.localize(7,null)}),e.CONTEXT_BREAKPOINTS_FOCUSED=new p.RawContextKey("breakpointsFocused",!0,{type:"boolean",description:s.localize(8,null)}),e.CONTEXT_WATCH_EXPRESSIONS_FOCUSED=new p.RawContextKey("watchExpressionsFocused",!0,{type:"boolean",description:s.localize(9,null)}),e.CONTEXT_WATCH_EXPRESSIONS_EXIST=new p.RawContextKey("watchExpressionsExist",!1,{type:"boolean",description:s.localize(10,null)}),e.CONTEXT_VARIABLES_FOCUSED=new p.RawContextKey("variablesFocused",!0,{type:"boolean",description:s.localize(11,null)}),e.CONTEXT_EXPRESSION_SELECTED=new p.RawContextKey("expressionSelected",!1,{type:"boolean",description:s.localize(12,null)}),e.CONTEXT_BREAKPOINT_INPUT_FOCUSED=new p.RawContextKey("breakpointInputFocused",!1,{type:"boolean",description:s.localize(13,null)}),e.CONTEXT_CALLSTACK_ITEM_TYPE=new p.RawContextKey("callStackItemType",void 0,{type:"string",description:s.localize(14,null)}),e.CONTEXT_CALLSTACK_SESSION_IS_ATTACH=new p.RawContextKey("callStackSessionIsAttach",!1,{type:"boolean",description:s.localize(15,null)}),e.CONTEXT_CALLSTACK_ITEM_STOPPED=new p.RawContextKey("callStackItemStopped",!1,{type:"boolean",description:s.localize(16,null)}),e.CONTEXT_CALLSTACK_SESSION_HAS_ONE_THREAD=new p.RawContextKey("callStackSessionHasOneThread",!1,{type:"boolean",description:s.localize(17,null)}),e.CONTEXT_WATCH_ITEM_TYPE=new p.RawContextKey("watchItemType",void 0,{type:"string",description:s.localize(18,null)}),e.CONTEXT_CAN_VIEW_MEMORY=new p.RawContextKey("canViewMemory",void 0,{type:"boolean",description:s.localize(19,null)}),e.CONTEXT_BREAKPOINT_ITEM_TYPE=new p.RawContextKey("breakpointItemType",void 0,{type:"string",description:s.localize(20,null)}),e.CONTEXT_BREAKPOINT_ACCESS_TYPE=new p.RawContextKey("breakpointAccessType",void 0,{type:"string",description:s.localize(21,null)}),e.CONTEXT_BREAKPOINT_SUPPORTS_CONDITION=new p.RawContextKey("breakpointSupportsCondition",!1,{type:"boolean",description:s.localize(22,null)}),e.CONTEXT_LOADED_SCRIPTS_SUPPORTED=new p.RawContextKey("loadedScriptsSupported",!1,{type:"boolean",description:s.localize(23,null)}),e.CONTEXT_LOADED_SCRIPTS_ITEM_TYPE=new p.RawContextKey("loadedScriptsItemType",void 0,{type:"string",description:s.localize(24,null)}),e.CONTEXT_FOCUSED_SESSION_IS_ATTACH=new p.RawContextKey("focusedSessionIsAttach",!1,{type:"boolean",description:s.localize(25,null)}),e.CONTEXT_STEP_BACK_SUPPORTED=new p.RawContextKey("stepBackSupported",!1,{type:"boolean",description:s.localize(26,null)}),e.CONTEXT_RESTART_FRAME_SUPPORTED=new p.RawContextKey("restartFrameSupported",!1,{type:"boolean",description:s.localize(27,null)}),e.CONTEXT_STACK_FRAME_SUPPORTS_RESTART=new p.RawContextKey("stackFrameSupportsRestart",!1,{type:"boolean",description:s.localize(28,null)}),e.CONTEXT_JUMP_TO_CURSOR_SUPPORTED=new p.RawContextKey("jumpToCursorSupported",!1,{type:"boolean",description:s.localize(29,null)}),e.CONTEXT_STEP_INTO_TARGETS_SUPPORTED=new p.RawContextKey("stepIntoTargetsSupported",!1,{type:"boolean",description:s.localize(30,null)}),e.CONTEXT_BREAKPOINTS_EXIST=new p.RawContextKey("breakpointsExist",!1,{type:"boolean",description:s.localize(31,null)}),e.CONTEXT_DEBUGGERS_AVAILABLE=new p.RawContextKey("debuggersAvailable",!1,{type:"boolean",description:s.localize(32,null)}),e.CONTEXT_DEBUG_EXTENSION_AVAILABLE=new p.RawContextKey("debugExtensionAvailable",!1,{type:"boolean",description:s.localize(33,null)}),e.CONTEXT_DEBUG_PROTOCOL_VARIABLE_MENU_CONTEXT=new p.RawContextKey("debugProtocolVariableMenuContext",void 0,{type:"string",description:s.localize(34,null)}),e.CONTEXT_SET_VARIABLE_SUPPORTED=new p.RawContextKey("debugSetVariableSupported",!1,{type:"boolean",description:s.localize(35,null)}),e.CONTEXT_SET_EXPRESSION_SUPPORTED=new p.RawContextKey("debugSetExpressionSupported",!1,{type:"boolean",description:s.localize(36,null)}),e.CONTEXT_BREAK_WHEN_VALUE_CHANGES_SUPPORTED=new p.RawContextKey("breakWhenValueChangesSupported",!1,{type:"boolean",description:s.localize(37,null)}),e.CONTEXT_BREAK_WHEN_VALUE_IS_ACCESSED_SUPPORTED=new p.RawContextKey("breakWhenValueIsAccessedSupported",!1,{type:"boolean",description:s.localize(38,null)}),e.CONTEXT_BREAK_WHEN_VALUE_IS_READ_SUPPORTED=new p.RawContextKey("breakWhenValueIsReadSupported",!1,{type:"boolean",description:s.localize(39,null)}),e.CONTEXT_TERMINATE_DEBUGGEE_SUPPORTED=new p.RawContextKey("terminateDebuggeeSupported",!1,{type:"boolean",description:s.localize(40,null)}),e.CONTEXT_SUSPEND_DEBUGGEE_SUPPORTED=new p.RawContextKey("suspendDebuggeeSupported",!1,{type:"boolean",description:s.localize(41,null)}),e.CONTEXT_VARIABLE_EVALUATE_NAME_PRESENT=new p.RawContextKey("variableEvaluateNamePresent",!1,{type:"boolean",description:s.localize(42,null)}),e.CONTEXT_VARIABLE_IS_READONLY=new p.RawContextKey("variableIsReadonly",!1,{type:"boolean",description:s.localize(43,null)}),e.CONTEXT_EXCEPTION_WIDGET_VISIBLE=new p.RawContextKey("exceptionWidgetVisible",!1,{type:"boolean",description:s.localize(44,null)}),e.CONTEXT_MULTI_SESSION_REPL=new p.RawContextKey("multiSessionRepl",!1,{type:"boolean",description:s.localize(45,null)}),e.CONTEXT_MULTI_SESSION_DEBUG=new p.RawContextKey("multiSessionDebug",!1,{type:"boolean",description:s.localize(46,null)}),e.CONTEXT_DISASSEMBLE_REQUEST_SUPPORTED=new p.RawContextKey("disassembleRequestSupported",!1,{type:"boolean",description:s.localize(47,null)}),e.CONTEXT_DISASSEMBLY_VIEW_FOCUS=new p.RawContextKey("disassemblyViewFocus",!1,{type:"boolean",description:s.localize(48,null)}),e.CONTEXT_LANGUAGE_SUPPORTS_DISASSEMBLE_REQUEST=new p.RawContextKey("languageSupportsDisassembleRequest",!1,{type:"boolean",description:s.localize(49,null)}),e.CONTEXT_FOCUSED_STACK_FRAME_HAS_INSTRUCTION_POINTER_REFERENCE=new p.RawContextKey("focusedStackFrameHasInstructionReference",!1,{type:"boolean",description:s.localize(50,null)});const L=m=>s.localize(51,null,m);e.debuggerDisabledMessage=L,e.EDITOR_CONTRIBUTION_ID="editor.contrib.debug",e.BREAKPOINT_EDITOR_CONTRIBUTION_ID="editor.contrib.breakpoint",e.DEBUG_SCHEME="debug",e.INTERNAL_CONSOLE_OPTIONS_SCHEMA={enum:["neverOpen","openOnSessionStart","openOnFirstSessionStart"],default:"openOnFirstSessionStart",description:s.localize(52,null)};var C;(function(m){m[m.Inactive=0]="Inactive",m[m.Initializing=1]="Initializing",m[m.Stopped=2]="Stopped",m[m.Running=3]="Running"})(C=e.State||(e.State={}));function T(m){switch(m){case 1:return"initializing";case 2:return"stopped";case 3:return"running";default:return"inactive"}}e.getStateLabel=T;var E;(function(m){m[m.Valid=0]="Valid",m[m.Unreadable=1]="Unreadable",m[m.Error=2]="Error"})(E=e.MemoryRangeType||(e.MemoryRangeType={})),e.DEBUG_MEMORY_SCHEME="vscode-debug-memory";var A;(function(m){m[m.Initial=1]="Initial",m[m.Dynamic=2]="Dynamic"})(A=e.DebugConfigurationProviderTriggerKind||(e.DebugConfigurationProviderTriggerKind={}));var R;(function(m){m.UnverifiedBreakpoints="unverifiedBreakpoints"})(R=e.DebuggerUiMessage||(e.DebuggerUiMessage={})),e.IDebugService=(0,b.createDecorator)(e.DEBUG_SERVICE_ID);var y;(function(m){m[m.CONDITION=0]="CONDITION",m[m.HIT_COUNT=1]="HIT_COUNT",m[m.LOG_MESSAGE=2]="LOG_MESSAGE"})(y=e.BreakpointWidgetContext||(e.BreakpointWidgetContext={}))}),define(ye[166],Ce([1,0,9,2,19,26,12]),function(ee,e,s,p,b,L,C){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.saveAllBeforeDebugStart=e.getVisibleAndSorted=e.convertToVSCPaths=e.convertToDAPaths=e.isUri=e.getExactExpressionStartAndEnd=e.isDebuggerMainContribution=e.getExtensionHostDebugSession=e.isSessionAttach=e.filterExceptionsFromTelemetry=e.formatPII=void 0;const T=/{([^}]+)}/g;function E(i,o,r){return i.replace(T,function(t,c){return o&&c.length>0&&c[0]!=="_"?t:r&&r.hasOwnProperty(c)?r[c]:t})}e.formatPII=E;function A(i){const o={};for(const r of Object.keys(i))r.startsWith("!")||(o[r]=i[r]);return o}e.filterExceptionsFromTelemetry=A;function R(i){return i.configuration.request==="attach"&&!y(i)&&(!i.parentSession||R(i.parentSession))}e.isSessionAttach=R;function y(i){let o=i.configuration.type;if(!!o)return o==="vslsShare"&&(o=i.configuration.adapterProxy.configuration.type),(0,s.equalsIgnoreCase)(o,"extensionhost")||(0,s.equalsIgnoreCase)(o,"pwa-extensionhost")?i:i.parentSession?y(i.parentSession):void 0}e.getExtensionHostDebugSession=y;function m(i){return i.type&&(i.label||i.program||i.runtime)}e.isDebuggerMainContribution=m;function I(i,o,r){let t,c=0;const v=/([^()\[\]{}<>\s+\-/%~#^;=|,`!]|\->)+/g;let g=null;for(;g=v.exec(i);){const D=g.index+1,U=D+g[0].length;if(D<=o&&U>=r){t=g[0],c=D;break}}if(t){const D=/\w+/g;let U=null;for(;(U=D.exec(t))&&!(U.index+1+c+U[0].length>=r););U&&(t=t.substring(0,D.lastIndex))}return t?{start:c,end:c+t.length-1}:{start:0,end:0}}e.getExactExpressionStartAndEnd=I;const f=/^[a-zA-Z][a-zA-Z0-9\+\-\.]+:/;function h(i){return!!(i&&i.match(f))}e.isUri=h;function d(i){if(typeof i.path=="string"&&!(typeof i.sourceReference=="number"&&i.sourceReference>0)){if(h(i.path))return p.URI.parse(i.path);if((0,b.isAbsolute)(i.path))return p.URI.file(i.path)}return i.path}function a(i){if(typeof i.path=="object"){const o=p.URI.revive(i.path);if(o)return o.scheme===C.Schemas.file?o.fsPath:o.toString()}return i.path}function w(i,o){const r=o?d:a,t=(0,L.deepClone)(i);return l(t,(c,v)=>{c&&v&&(v.path=r(v))}),t}e.convertToDAPaths=w;function P(i,o){const r=o?d:a,t=(0,L.deepClone)(i);return l(t,(c,v)=>{!c&&v&&(v.path=r(v))}),t}e.convertToVSCPaths=P;function l(i,o){switch(i.type){case"event":{const r=i;switch(r.event){case"output":o(!1,r.body.source);break;case"loadedSource":o(!1,r.body.source);break;case"breakpoint":o(!1,r.body.breakpoint.source);break;default:break}break}case"request":{const r=i;switch(r.command){case"setBreakpoints":o(!0,r.arguments.source);break;case"breakpointLocations":o(!0,r.arguments.source);break;case"source":o(!0,r.arguments.source);break;case"gotoTargets":o(!0,r.arguments.source);break;case"launchVSCode":r.arguments.args.forEach(t=>o(!1,t));break;default:break}break}case"response":{const r=i;if(r.success&&r.body)switch(r.command){case"stackTrace":r.body.stackFrames.forEach(t=>o(!1,t.source));break;case"loadedSources":r.body.sources.forEach(t=>o(!1,t));break;case"scopes":r.body.scopes.forEach(t=>o(!1,t.source));break;case"setFunctionBreakpoints":r.body.breakpoints.forEach(t=>o(!1,t.source));break;case"setBreakpoints":r.body.breakpoints.forEach(t=>o(!1,t.source));break;case"disassemble":r.body?.instructions.forEach(c=>o(!1,c.location));break;default:break}break}}}function _(i){return i.filter(o=>!o.presentation?.hidden).sort((o,r)=>o.presentation?r.presentation?o.presentation.group?r.presentation.group?o.presentation.group!==r.presentation.group?o.presentation.group.localeCompare(r.presentation.group):n(o.presentation.order,r.presentation.order):-1:r.presentation.group?1:n(o.presentation.order,r.presentation.order):-1:r.presentation?1:0)}e.getVisibleAndSorted=_;function n(i,o){return typeof i!="number"?typeof o!="number"?0:1:typeof o!="number"?-1:i-o}async function u(i,o){const r=i.getValue("debug.saveBeforeStart",{overrideIdentifier:o.activeTextEditorLanguageId});if(r!=="none"&&(await o.saveAll(),r==="allEditorsInActiveGroup")){const t=o.activeEditorPane;t&&t.input.resource?.scheme===C.Schemas.untitled&&await o.save({editor:t.input,groupId:t.group.id})}await i.reloadConfiguration()}e.saveAllBeforeDebugStart=u}),define(ye[88],Ce([1,0,22,34,167,74,12,19,23,38]),function(ee,e,s,p,b,L,C,T,E,A){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.NotebookWorkingCopyTypeIdentifier=e.CellStatusbarAlignment=e.NotebookSetting=e.notebookDocumentFilterMatch=e.isDocumentExcludePattern=e.NotebookEditorPriority=e.NOTEBOOK_EDITOR_CURSOR_BOUNDARY=e.diff=e.MimeTypeDisplayOrder=e.CellUri=e.CellEditType=e.SelectionStateType=e.NotebookCellsChangeType=e.RendererMessagingSpec=e.NotebookRendererMatch=e.NotebookCellExecutionState=e.NotebookRunState=e.RENDERER_NOT_AVAILABLE=e.RENDERER_EQUIVALENT_EXTENSIONS=e.ACCESSIBLE_NOTEBOOK_DISPLAY_ORDER=e.NOTEBOOK_DISPLAY_ORDER=e.CellKind=e.NOTEBOOK_DIFF_EDITOR_ID=e.NOTEBOOK_EDITOR_ID=void 0,e.NOTEBOOK_EDITOR_ID="workbench.editor.notebook",e.NOTEBOOK_DIFF_EDITOR_ID="workbench.editor.notebookTextDiffEditor";var R;(function(t){t[t.Markup=1]="Markup",t[t.Code=2]="Code"})(R=e.CellKind||(e.CellKind={})),e.NOTEBOOK_DISPLAY_ORDER=["application/json","application/javascript","text/html","image/svg+xml",L.Mimes.latex,L.Mimes.markdown,"image/png","image/jpeg",L.Mimes.text],e.ACCESSIBLE_NOTEBOOK_DISPLAY_ORDER=[L.Mimes.latex,L.Mimes.markdown,"application/json",L.Mimes.text,"text/html","image/svg+xml","image/png","image/jpeg"],e.RENDERER_EQUIVALENT_EXTENSIONS=new Map([["ms-toolsai.jupyter",new Set(["jupyter-notebook","interactive"])],["ms-toolsai.jupyter-renderers",new Set(["jupyter-notebook","interactive"])]]),e.RENDERER_NOT_AVAILABLE="_notAvailable";var y;(function(t){t[t.Running=1]="Running",t[t.Idle=2]="Idle"})(y=e.NotebookRunState||(e.NotebookRunState={}));var m;(function(t){t[t.Unconfirmed=1]="Unconfirmed",t[t.Pending=2]="Pending",t[t.Executing=3]="Executing"})(m=e.NotebookCellExecutionState||(e.NotebookCellExecutionState={}));var I;(function(t){t[t.WithHardKernelDependency=0]="WithHardKernelDependency",t[t.WithOptionalKernelDependency=1]="WithOptionalKernelDependency",t[t.Pure=2]="Pure",t[t.Never=3]="Never"})(I=e.NotebookRendererMatch||(e.NotebookRendererMatch={}));var f;(function(t){t.Always="always",t.Never="never",t.Optional="optional"})(f=e.RendererMessagingSpec||(e.RendererMessagingSpec={}));var h;(function(t){t[t.ModelChange=1]="ModelChange",t[t.Move=2]="Move",t[t.ChangeCellLanguage=5]="ChangeCellLanguage",t[t.Initialize=6]="Initialize",t[t.ChangeCellMetadata=7]="ChangeCellMetadata",t[t.Output=8]="Output",t[t.OutputItem=9]="OutputItem",t[t.ChangeCellContent=10]="ChangeCellContent",t[t.ChangeDocumentMetadata=11]="ChangeDocumentMetadata",t[t.ChangeCellInternalMetadata=12]="ChangeCellInternalMetadata",t[t.ChangeCellMime=13]="ChangeCellMime",t[t.Unknown=100]="Unknown"})(h=e.NotebookCellsChangeType||(e.NotebookCellsChangeType={}));var d;(function(t){t[t.Handle=0]="Handle",t[t.Index=1]="Index"})(d=e.SelectionStateType||(e.SelectionStateType={}));var a;(function(t){t[t.Replace=1]="Replace",t[t.Output=2]="Output",t[t.Metadata=3]="Metadata",t[t.CellLanguage=4]="CellLanguage",t[t.DocumentMetadata=5]="DocumentMetadata",t[t.Move=6]="Move",t[t.OutputItems=7]="OutputItems",t[t.PartialMetadata=8]="PartialMetadata",t[t.PartialInternalMetadata=9]="PartialInternalMetadata"})(a=e.CellEditType||(e.CellEditType={}));var w;(function(t){t.scheme=C.Schemas.vscodeNotebookCell;const c=["W","X","Y","Z","a","b","c","d","e","f"],v=new RegExp(`^[${c.join("")}]+`),g=7;function D(N,K){const V=K.toString(g),ne=`${V.length<c.length?c[V.length-1]:"z"}${V}s${(0,s.encodeBase64)(s.VSBuffer.fromString(N.scheme),!0,!0)}`;return N.with({scheme:t.scheme,fragment:ne})}t.generate=D;function U(N){if(N.scheme!==t.scheme)return;const K=N.fragment.indexOf("s");if(K<0)return;const V=parseInt(N.fragment.substring(0,K).replace(v,""),g),F=(0,s.decodeBase64)(N.fragment.substring(K+1)).toString();if(!isNaN(V))return{handle:V,notebook:N.with({scheme:F,fragment:null})}}t.parse=U;const W=/^(\d{8,})(\w[\w\d+.-]*)$/;function M(N,K){return N.with({scheme:C.Schemas.vscodeNotebookCellOutput,fragment:`op${K??""},${N.scheme!==C.Schemas.file?N.scheme:""}`})}t.generateCellOutputUri=M;function S(N){if(N.scheme!==C.Schemas.vscodeNotebookCellOutput)return;const K=/^op([0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12})?\,(.*)$/i.exec(N.fragment);if(!K)return;const V=K[1]&&K[1]!==""?K[1]:void 0,F=K[2];return{outputId:V,notebook:N.with({scheme:F||C.Schemas.file,fragment:null})}}t.parseCellOutputUri=S;function z(N,K,V){return N.with({scheme:V,fragment:`ch${K.toString().padStart(7,"0")}${N.scheme!==C.Schemas.file?N.scheme:""}`})}t.generateCellUri=z;function $(N,K){if(N.scheme!==K)return;const V=W.exec(N.fragment);return V?{handle:Number(V[1]),notebook:N.with({scheme:N.fragment.substring(V[0].length)||C.Schemas.file,fragment:null})}:void 0}t.parseCellUri=$})(w=e.CellUri||(e.CellUri={}));const P=t=>E.isWindows?t.replace(/\//g,"\\"):t;class l{constructor(c=[],v=e.NOTEBOOK_DISPLAY_ORDER){this.defaultOrder=v,this.order=[...new Set(c)].map(g=>({pattern:g,matches:p.parse(P(g))}))}sort(c){const v=new Map(b.Iterable.map(c,D=>[D,P(D)]));let g=[];for(const{matches:D}of this.order)for(const[U,W]of v)if(D(W)){g.push(U),v.delete(U);break}return v.size&&(g=g.concat([...v.keys()].sort((D,U)=>this.defaultOrder.indexOf(D)-this.defaultOrder.indexOf(U)))),g}prioritize(c,v){const g=this.findIndex(c);if(g===-1){this.order.unshift({pattern:c,matches:p.parse(P(c))});return}const D=new Set(v.map(W=>this.findIndex(W,g)));D.delete(-1);const U=Array.from(D).sort();this.order.splice(g+1,0,...U.map(W=>this.order[W]));for(let W=U.length-1;W>=0;W--)this.order.splice(U[W],1)}toArray(){return this.order.map(c=>c.pattern)}findIndex(c,v=this.order.length){const g=P(c);for(let D=0;D<v;D++)if(this.order[D].matches(g))return D;return-1}}e.MimeTypeDisplayOrder=l;function _(t,c,v,g=(D,U)=>D===U){const D=[];function U(S,z,$){if(z===0&&$.length===0)return;const N=D[D.length-1];N&&N.start+N.deleteCount===S?(N.deleteCount+=z,N.toInsert.push(...$)):D.push({start:S,deleteCount:z,toInsert:$})}let W=0,M=0;for(;;){if(W===t.length){U(W,0,c.slice(M));break}if(M===c.length){U(W,t.length-W,[]);break}const S=t[W],z=c[M];if(g(S,z)){W+=1,M+=1;continue}v(z)?(U(W,1,[]),W+=1):(U(W,0,[z]),M+=1)}return D}e.diff=_,e.NOTEBOOK_EDITOR_CURSOR_BOUNDARY=new A.RawContextKey("notebookEditorCursorAtBoundary","none");var n;(function(t){t.default="default",t.option="option"})(n=e.NotebookEditorPriority||(e.NotebookEditorPriority={}));function u(t){const c=t;return!!((typeof c.include=="string"||p.isRelativePattern(c.include))&&(typeof c.exclude=="string"||p.isRelativePattern(c.exclude)))}e.isDocumentExcludePattern=u;function i(t,c,v){if(Array.isArray(t.viewType)&&t.viewType.indexOf(c)>=0||t.viewType===c)return!0;if(t.filenamePattern){const g=u(t.filenamePattern)?t.filenamePattern.include:t.filenamePattern,D=u(t.filenamePattern)?t.filenamePattern.exclude:void 0;if(p.match(g,(0,T.basename)(v.fsPath).toLowerCase()))return!(D&&p.match(D,(0,T.basename)(v.fsPath).toLowerCase()))}return!1}e.notebookDocumentFilterMatch=i,e.NotebookSetting={displayOrder:"notebook.displayOrder",cellToolbarLocation:"notebook.cellToolbarLocation",cellToolbarVisibility:"notebook.cellToolbarVisibility",showCellStatusBar:"notebook.showCellStatusBar",textDiffEditorPreview:"notebook.diff.enablePreview",experimentalInsertToolbarAlignment:"notebook.experimental.insertToolbarAlignment",compactView:"notebook.compactView",focusIndicator:"notebook.cellFocusIndicator",insertToolbarLocation:"notebook.insertToolbarLocation",globalToolbar:"notebook.globalToolbar",undoRedoPerCell:"notebook.undoRedoPerCell",consolidatedOutputButton:"notebook.consolidatedOutputButton",showFoldingControls:"notebook.showFoldingControls",dragAndDropEnabled:"notebook.dragAndDropEnabled",cellEditorOptionsCustomizations:"notebook.editorOptionsCustomizations",consolidatedRunButton:"notebook.consolidatedRunButton",openGettingStarted:"notebook.experimental.openGettingStarted",textOutputLineLimit:"notebook.output.textLineLimit",globalToolbarShowLabel:"notebook.globalToolbarShowLabel",markupFontSize:"notebook.markup.fontSize",interactiveWindowCollapseCodeCells:"interactiveWindow.collapseCellInputCode",outputLineHeight:"notebook.outputLineHeight",outputFontSize:"notebook.outputFontSize",outputFontFamily:"notebook.outputFontFamily"};var o;(function(t){t[t.Left=1]="Left",t[t.Right=2]="Right"})(o=e.CellStatusbarAlignment||(e.CellStatusbarAlignment={}));class r{static create(c){return`${r._prefix}${c}`}static parse(c){if(c.startsWith(r._prefix))return c.substring(r._prefix.length)}}e.NotebookWorkingCopyTypeIdentifier=r,r._prefix="notebook/"}),define(ye[168],Ce([1,0,3]),function(ee,e,s){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.INotebookExecutionService=e.CellExecutionUpdateType=void 0;var p;(function(b){b[b.Output=1]="Output",b[b.OutputItems=2]="OutputItems",b[b.ExecutionState=3]="ExecutionState"})(p=e.CellExecutionUpdateType||(e.CellExecutionUpdateType={})),e.INotebookExecutionService=(0,s.createDecorator)("INotebookExecutionService")}),define(ye[169],Ce([1,0]),function(ee,e){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.deserializeEnvironmentVariableCollections=e.serializeEnvironmentVariableCollections=e.deserializeEnvironmentVariableCollection=e.serializeEnvironmentVariableCollection=void 0;function s(C){return[...C.entries()]}e.serializeEnvironmentVariableCollection=s;function p(C){return new Map(C)}e.deserializeEnvironmentVariableCollection=p;function b(C){return Array.from(C.entries()).map(T=>[T[0],s(T[1].map)])}e.serializeEnvironmentVariableCollections=b;function L(C){return new Map(C.map(T=>[T[0],{map:p(T[1])}]))}e.deserializeEnvironmentVariableCollections=L}),define(ye[46],Ce([1,0]),function(ee,e){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.TestId=e.TestPosition=e.TestIdPathParts=void 0;var s;(function(L){L.Delimiter="\0"})(s=e.TestIdPathParts||(e.TestIdPathParts={}));var p;(function(L){L[L.IsSame=0]="IsSame",L[L.Disconnected=1]="Disconnected",L[L.IsChild=2]="IsChild",L[L.IsParent=3]="IsParent"})(p=e.TestPosition||(e.TestPosition={}));class b{constructor(C,T=C.length){if(this.path=C,this.viewEnd=T,C.length===0||T<1)throw new Error("cannot create test with empty path")}static fromExtHostTestItem(C,T,E=C.parent){if(C.id===T)return new b([T]);const A=[C.id];for(let R=E;R&&R.id!==T;R=R.parent)A.push(R.id);return A.push(T),new b(A.reverse())}static isRoot(C){return!C.includes("\0")}static root(C){const T=C.indexOf("\0");return T===-1?C:C.slice(0,T)}static fromString(C){return new b(C.split("\0"))}static join(C,T){return new b([...C.path,T])}static joinToString(C,T){return C.toString()+"\0"+T}static compare(C,T){return C===T?0:T.startsWith(C+"\0")?2:C.startsWith(T+"\0")?3:1}get parentId(){return this.viewEnd>1?new b(this.path,this.viewEnd-1):this}get localId(){return this.path[this.viewEnd-1]}get controllerId(){return this.path[0]}get isRoot(){return this.viewEnd===1}*idsFromRoot(){for(let C=1;C<=this.viewEnd;C++)yield new b(this.path,C)}compare(C){if(typeof C=="string")return b.compare(this.toString(),C);for(let T=0;T<C.viewEnd&&T<this.viewEnd;T++)if(C.path[T]!==this.path[T])return 1;return C.viewEnd>this.viewEnd?2:C.viewEnd<this.viewEnd?3:0}toJSON(){return this.toString()}toString(){if(!this.stringifed){this.stringifed=this.path[0];for(let C=1;C<this.viewEnd;C++)this.stringifed+="\0",this.stringifed+=this.path[C]}return this.stringifed}}e.TestId=b}),define(ye[47],Ce([1,0,2,48]),function(ee,e,s,p){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.AbstractIncrementalTestCollection=e.IncrementalChangeCollector=e.TestsDiffOp=e.TestDiffOpType=e.DetailType=e.TestResultItem=e.applyTestItemUpdate=e.ITestItemUpdate=e.InternalTestItem=e.TestItemExpandState=e.ITestItem=e.denamespaceTestTag=e.namespaceTestTag=e.ITestTaskState=e.ITestMessage=e.ITestOutputMessage=e.ITestErrorMessage=e.TestMessageType=e.IRichLocation=e.testRunProfileBitsetList=e.TestRunProfileBitset=e.TestResultState=void 0;var b;(function(r){r[r.Unset=0]="Unset",r[r.Queued=1]="Queued",r[r.Running=2]="Running",r[r.Passed=3]="Passed",r[r.Failed=4]="Failed",r[r.Skipped=5]="Skipped",r[r.Errored=6]="Errored"})(b=e.TestResultState||(e.TestResultState={}));var L;(function(r){r[r.Run=2]="Run",r[r.Debug=4]="Debug",r[r.Coverage=8]="Coverage",r[r.HasNonDefaultProfile=16]="HasNonDefaultProfile",r[r.HasConfigurable=32]="HasConfigurable"})(L=e.TestRunProfileBitset||(e.TestRunProfileBitset={})),e.testRunProfileBitsetList=[2,4,8,16];var C;(function(r){r.serialize=t=>({range:t.range.toJSON(),uri:t.uri.toJSON()}),r.deserialize=t=>({range:p.Range.lift(t.range),uri:s.URI.revive(t.uri)})})(C=e.IRichLocation||(e.IRichLocation={}));var T;(function(r){r[r.Error=0]="Error",r[r.Output=1]="Output"})(T=e.TestMessageType||(e.TestMessageType={}));var E;(function(r){r.serialize=t=>({message:t.message,type:0,expected:t.expected,actual:t.actual,location:t.location&&C.serialize(t.location)}),r.deserialize=t=>({message:t.message,type:0,expected:t.expected,actual:t.actual,location:t.location&&C.deserialize(t.location)})})(E=e.ITestErrorMessage||(e.ITestErrorMessage={}));var A;(function(r){r.serialize=t=>({message:t.message,type:1,offset:t.offset,location:t.location&&C.serialize(t.location)}),r.deserialize=t=>({message:t.message,type:1,offset:t.offset,location:t.location&&C.deserialize(t.location)})})(A=e.ITestOutputMessage||(e.ITestOutputMessage={}));var R;(function(r){r.serialize=t=>t.type===0?E.serialize(t):A.serialize(t),r.deserialize=t=>t.type===0?E.deserialize(t):A.deserialize(t)})(R=e.ITestMessage||(e.ITestMessage={}));var y;(function(r){r.serialize=t=>({state:t.state,duration:t.duration,messages:t.messages.map(R.serialize)}),r.deserialize=t=>({state:t.state,duration:t.duration,messages:t.messages.map(R.deserialize)})})(y=e.ITestTaskState||(e.ITestTaskState={}));const m="\0",I=(r,t)=>r+m+t;e.namespaceTestTag=I;const f=r=>{const t=r.indexOf(m);return{ctrlId:r.slice(0,t),tagId:r.slice(t+1)}};e.denamespaceTestTag=f;var h;(function(r){r.serialize=t=>({extId:t.extId,label:t.label,tags:t.tags,busy:t.busy,children:void 0,uri:t.uri?.toJSON(),range:t.range?.toJSON()||null,description:t.description,error:t.error,sortText:t.sortText}),r.deserialize=t=>({extId:t.extId,label:t.label,tags:t.tags,busy:t.busy,children:void 0,uri:t.uri?s.URI.revive(t.uri):void 0,range:t.range?p.Range.lift(t.range):null,description:t.description,error:t.error,sortText:t.sortText})})(h=e.ITestItem||(e.ITestItem={}));var d;(function(r){r[r.NotExpandable=0]="NotExpandable",r[r.Expandable=1]="Expandable",r[r.BusyExpanding=2]="BusyExpanding",r[r.Expanded=3]="Expanded"})(d=e.TestItemExpandState||(e.TestItemExpandState={}));var a;(function(r){r.serialize=t=>({controllerId:t.controllerId,expand:t.expand,parent:t.parent,item:h.serialize(t.item)}),r.deserialize=t=>({controllerId:t.controllerId,expand:t.expand,parent:t.parent,item:h.deserialize(t.item)})})(a=e.InternalTestItem||(e.InternalTestItem={}));var w;(function(r){r.serialize=t=>{let c;return t.item&&(c={},t.item.label!==void 0&&(c.label=t.item.label),t.item.tags!==void 0&&(c.tags=t.item.tags),t.item.busy!==void 0&&(c.busy=t.item.busy),t.item.uri!==void 0&&(c.uri=t.item.uri?.toJSON()),t.item.range!==void 0&&(c.range=t.item.range?.toJSON()),t.item.description!==void 0&&(c.description=t.item.description),t.item.error!==void 0&&(c.error=t.item.error),t.item.sortText!==void 0&&(c.sortText=t.item.sortText)),{extId:t.extId,expand:t.expand,item:c}},r.deserialize=t=>{let c;return t.item&&(c={},t.item.label!==void 0&&(c.label=t.item.label),t.item.tags!==void 0&&(c.tags=t.item.tags),t.item.busy!==void 0&&(c.busy=t.item.busy),t.item.range!==void 0&&(c.range=t.item.range?p.Range.lift(t.item.range):null),t.item.description!==void 0&&(c.description=t.item.description),t.item.error!==void 0&&(c.error=t.item.error),t.item.sortText!==void 0&&(c.sortText=t.item.sortText)),{extId:t.extId,expand:t.expand,item:c}}})(w=e.ITestItemUpdate||(e.ITestItemUpdate={}));const P=(r,t)=>{t.expand!==void 0&&(r.expand=t.expand),t.item!==void 0&&(r.item=r.item?Object.assign(r.item,t.item):t.item)};e.applyTestItemUpdate=P;var l;(function(r){r.serialize=(t,c)=>({...a.serialize(t),children:c,ownComputedState:t.ownComputedState,computedState:t.computedState,tasks:t.tasks.map(y.serialize)})})(l=e.TestResultItem||(e.TestResultItem={}));var _;(function(r){r[r.Function=0]="Function",r[r.Statement=1]="Statement"})(_=e.DetailType||(e.DetailType={}));var n;(function(r){r[r.Add=0]="Add",r[r.Update=1]="Update",r[r.Remove=2]="Remove",r[r.IncrementPendingExtHosts=3]="IncrementPendingExtHosts",r[r.Retire=4]="Retire",r[r.AddTag=5]="AddTag",r[r.RemoveTag=6]="RemoveTag"})(n=e.TestDiffOpType||(e.TestDiffOpType={}));var u;(function(r){r.deserialize=t=>t.op===0?{op:t.op,item:a.deserialize(t.item)}:t.op===1?{op:t.op,item:w.deserialize(t.item)}:t,r.serialize=t=>t.op===0?{op:t.op,item:a.serialize(t.item)}:t.op===1?{op:t.op,item:w.serialize(t.item)}:t})(u=e.TestsDiffOp||(e.TestsDiffOp={}));class i{add(t){}update(t){}remove(t,c){}complete(){}}e.IncrementalChangeCollector=i;class o{constructor(){this._tags=new Map,this.items=new Map,this.roots=new Set,this.busyControllerCount=0,this.pendingRootCount=0,this.tags=this._tags}apply(t){const c=this.createChangeCollector();for(const v of t)switch(v.op){case 0:{const g=a.deserialize(v.item);if(g.parent){if(this.items.has(g.parent)){const D=this.items.get(g.parent);D.children.add(g.item.extId);const U=this.createItem(g,D);this.items.set(g.item.extId,U),c.add(U)}}else{const D=this.createItem(g);this.roots.add(D),this.items.set(g.item.extId,D),c.add(D)}g.expand===2&&this.busyControllerCount++;break}case 1:{const g=w.deserialize(v.item),D=this.items.get(g.extId);if(!D)break;g.expand!==void 0&&(D.expand===2&&this.busyControllerCount--,g.expand===2&&this.busyControllerCount++),(0,e.applyTestItemUpdate)(D,g),c.update(D);break}case 2:{const g=this.items.get(v.itemId);if(!g)break;g.parent?this.items.get(g.parent).children.delete(g.item.extId):this.roots.delete(g);const D=[[v.itemId]];for(;D.length;)for(const U of D.pop()){const W=this.items.get(U);W&&(D.push(W.children),this.items.delete(U),c.remove(W,W!==g),W.expand===2&&this.busyControllerCount--)}break}case 4:this.retireTest(v.itemId);break;case 3:this.updatePendingRoots(v.amount);break;case 5:this._tags.set(v.tag.id,v.tag);break;case 6:this._tags.delete(v.id);break}c.complete()}retireTest(t){}updatePendingRoots(t){this.pendingRootCount+=t}createChangeCollector(){return new i}}e.AbstractIncrementalTestCollection=o}),define(ye[65],Ce([1,0,13,4,7,10,47,46]),function(ee,e,s,p,b,L,C,T){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.createTestItemChildren=e.MixedTestItemController=e.InvalidTestItemError=e.DuplicateTestItemError=e.TestItemCollection=e.TestItemEventOp=void 0;var E;(function(a){a[a.Upsert=0]="Upsert",a[a.SetTags=1]="SetTags",a[a.UpdateCanResolveChildren=2]="UpdateCanResolveChildren",a[a.RemoveChild=3]="RemoveChild",a[a.SetProp=4]="SetProp",a[a.Bulk=5]="Bulk"})(E=e.TestItemEventOp||(e.TestItemEventOp={}));const A=(a,w)=>a===w,R={range:(a,w)=>a===w?!0:!a||!w?!1:a.equalsRange(w),busy:A,label:A,description:A,error:A,tags:(a,w)=>!(a.length!==w.length||a.some(P=>!w.includes(P)))},y=(a,w)=>{let P;for(const[l,_]of Object.entries(R))_(a[l],w[l])||(P?P[l]=w[l]:P={[l]:w[l]});return P};class m extends b.Disposable{constructor(w){super();this.options=w,this.debounceSendDiff=this._register(new s.RunOnceScheduler(()=>this.flushDiff(),200)),this.diffOpEmitter=this._register(new p.Emitter),this.tree=new Map,this.tags=new Map,this.diff=[],this.onDidGenerateDiff=this.diffOpEmitter.event,this.root.canResolveChildren=!0,this.upsertItem(this.root,void 0)}get root(){return this.options.root}set resolveHandler(w){this._resolveHandler=w;for(const P of this.tree.values())this.updateExpandability(P)}collectDiff(){const w=this.diff;return this.diff=[],w}pushDiff(w){const P=this.diff[this.diff.length-1];if(P&&w.op===1){if(P.op===1&&P.item.extId===w.item.extId){(0,C.applyTestItemUpdate)(P.item,w.item);return}if(P.op===0&&P.item.item.extId===w.item.extId){(0,C.applyTestItemUpdate)(P.item,w.item);return}}this.diff.push(w),this.debounceSendDiff.isScheduled()||this.debounceSendDiff.schedule()}expand(w,P){const l=this.tree.get(w);if(!!l){if((l.expandLevels===void 0||P>l.expandLevels)&&(l.expandLevels=P),l.expand===1){const _=this.resolveChildren(l);return _.isOpen()?this.expandChildren(l,P-1):_.wait().then(()=>this.expandChildren(l,P-1))}else if(l.expand===3)return l.resolveBarrier?.isOpen()===!1?l.resolveBarrier.wait().then(()=>this.expandChildren(l,P-1)):this.expandChildren(l,P-1)}}dispose(){for(const w of this.tree.values())this.options.getApiFor(w.actual).listener=void 0;this.tree.clear(),this.diff=[],super.dispose()}onTestItemEvent(w,P){switch(P.op){case 3:this.removeItem(T.TestId.joinToString(w.fullId,P.id));break;case 0:this.upsertItem(P.item,w);break;case 5:for(const l of P.ops)this.onTestItemEvent(w,l);break;case 1:this.diffTagRefs(P.new,P.old,w.fullId.toString());break;case 2:this.updateExpandability(w);break;case 4:this.pushDiff({op:1,item:{extId:w.fullId.toString(),item:P.update}});break;default:(0,L.assertNever)(P)}}upsertItem(w,P){const l=T.TestId.fromExtHostTestItem(w,this.root.id,P?.actual),_=this.options.getApiFor(w);_.parent&&_.parent!==P?.actual&&this.options.getChildren(_.parent).delete(w.id);let n=this.tree.get(l.toString());if(!n){n={fullId:l,actual:w,parent:P?l.parentId:null,expandLevels:P?.expandLevels?P.expandLevels-1:void 0,expand:0},w.tags.forEach(this.incrementTagRefs,this),this.tree.set(n.fullId.toString(),n),this.setItemParent(w,P),this.pushDiff({op:0,item:{parent:n.parent&&n.parent.toString(),controllerId:this.options.controllerId,expand:n.expand,item:this.options.toITestItem(w)}}),this.connectItemAndChildren(w,n,P);return}if(n.actual===w){this.connectItem(w,n,P);return}const u=this.options.getChildren(n.actual),i=n.actual,o=y(this.options.toITestItem(i),this.options.toITestItem(w));this.options.getApiFor(i).listener=void 0,n.actual=w,n.expand=0,o&&(o.hasOwnProperty("tags")&&(this.diffTagRefs(w.tags,i.tags,l.toString()),delete o.tags),this.onTestItemEvent(n,{op:4,update:o})),this.connectItemAndChildren(w,n,P);for(const[r,t]of u)this.options.getChildren(w).get(t.id)||this.removeItem(T.TestId.joinToString(l,t.id))}diffTagRefs(w,P,l){const _=new Set(P.map(n=>n.id));for(const n of w)_.delete(n.id)||this.incrementTagRefs(n);this.pushDiff({op:1,item:{extId:l,item:{tags:w.map(n=>(0,C.namespaceTestTag)(this.options.controllerId,n.id))}}}),_.forEach(this.decrementTagRefs,this)}incrementTagRefs(w){const P=this.tags.get(w.id);P?P.refCount++:(this.tags.set(w.id,{refCount:1}),this.pushDiff({op:5,tag:{id:(0,C.namespaceTestTag)(this.options.controllerId,w.id)}}))}decrementTagRefs(w){const P=this.tags.get(w);P&&!--P.refCount&&(this.tags.delete(w),this.pushDiff({op:6,id:(0,C.namespaceTestTag)(this.options.controllerId,w)}))}setItemParent(w,P){this.options.getApiFor(w).parent=P&&P.actual!==this.root?P.actual:void 0}connectItem(w,P,l){this.setItemParent(w,l);const _=this.options.getApiFor(w);_.parent=l?.actual,_.listener=n=>this.onTestItemEvent(P,n),this.updateExpandability(P)}connectItemAndChildren(w,P,l){this.connectItem(w,P,l);for(const[_,n]of this.options.getChildren(w))this.upsertItem(n,P)}updateExpandability(w){let P;this._resolveHandler?w.resolveBarrier?P=w.resolveBarrier.isOpen()?3:2:P=w.actual.canResolveChildren?1:0:P=0,P!==w.expand&&(w.expand=P,this.pushDiff({op:1,item:{extId:w.fullId.toString(),expand:P}}),P===1&&w.expandLevels!==void 0&&this.resolveChildren(w))}expandChildren(w,P){if(P<0)return;const l=[];for(const[_,n]of this.options.getChildren(w.actual)){const u=this.expand(T.TestId.joinToString(w.fullId,n.id),P);(0,s.isThenable)(u)&&l.push(u)}if(l.length)return Promise.all(l).then(()=>{})}resolveChildren(w){if(w.resolveBarrier)return w.resolveBarrier;if(!this._resolveHandler){const n=new s.Barrier;return n.open(),n}w.expand=2,this.pushExpandStateUpdate(w);const P=w.resolveBarrier=new s.Barrier,l=n=>{console.error(`Unhandled error in resolveHandler of test controller "${this.options.controllerId}"`,n)};let _;try{_=this._resolveHandler(w.actual===this.root?void 0:w.actual)}catch(n){l(n)}return(0,s.isThenable)(_)?_.catch(l).then(()=>{P.open(),this.updateExpandability(w)}):(P.open(),this.updateExpandability(w)),w.resolveBarrier}pushExpandStateUpdate(w){this.pushDiff({op:1,item:{extId:w.fullId.toString(),expand:w.expand}})}removeItem(w){const P=this.tree.get(w);if(!P)throw new Error("attempting to remove non-existent child");this.pushDiff({op:2,itemId:w});const l=[P];for(;l.length;){const _=l.pop();if(!!_){this.options.getApiFor(_.actual).listener=void 0;for(const n of _.actual.tags)this.decrementTagRefs(n.id);this.tree.delete(_.fullId.toString());for(const[n,u]of this.options.getChildren(_.actual))l.push(this.tree.get(T.TestId.joinToString(_.fullId,u.id)))}}}flushDiff(){const w=this.collectDiff();w.length&&this.diffOpEmitter.fire(w)}}e.TestItemCollection=m;class I extends Error{constructor(w){super(`Attempted to insert a duplicate test item ID ${w}`)}}e.DuplicateTestItemError=I;class f extends Error{constructor(w){super(`TestItem with ID "${w}" is invalid. Make sure to create it from the createTestItem method.`)}}e.InvalidTestItemError=f;class h extends Error{constructor(w,P,l){super(`TestItem with ID "${w}" is from controller "${P}" and cannot be added as a child of an item from controller "${l}".`)}}e.MixedTestItemController=h;const d=(a,w,P)=>{let l=new Map;return{get size(){return l.size},forEach(_,n){for(const u of l.values())_.call(n,u,this)},[Symbol.iterator](){return l.entries()},replace(_){const n=new Map,u=new Set(l.keys()),i={op:5,ops:[]};for(const o of _){if(!(o instanceof P))throw new f(o.id);const r=w(o).controllerId;if(r!==a.controllerId)throw new h(o.id,r,a.controllerId);if(n.has(o.id))throw new I(o.id);n.set(o.id,o),u.delete(o.id),i.ops.push({op:0,item:o})}for(const o of u.keys())i.ops.push({op:3,id:o});a.listener?.(i),l=n},add(_){if(!(_ instanceof P))throw new f(_.id);l.set(_.id,_),a.listener?.({op:0,item:_})},delete(_){l.delete(_)&&a.listener?.({op:3,id:_})},get(_){return l.get(_)},toJSON(){return Array.from(l.values())}}};e.createTestItemChildren=d}),define(ye[89],Ce([1,0,65]),function(ee,e,s){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.getPrivateApiFor=e.createPrivateApiFor=void 0;const p=new WeakMap,b=(C,T)=>{const E={controllerId:T};return p.set(C,E),E};e.createPrivateApiFor=b;const L=C=>{const T=p.get(C);if(!T)throw new s.InvalidTestItemError(C?.id||"<unknown>");return T};e.getPrivateApiFor=L}),define(ye[170],Ce([1,0,19,59,10,26,23,76,140,9]),function(ee,e,s,p,b,L,C,T,E,A){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.AbstractVariableResolverService=void 0;class R{constructor(m,I,f,h){this._contributedVariables=new Map,this._context=m,this._labelService=I,this._userHomePromise=f,h&&(this._envVariablesPromise=h.then(d=>this.prepareEnv(d)))}prepareEnv(m){if(C.isWindows){const I=Object.create(null);return Object.keys(m).forEach(f=>{I[f.toLowerCase()]=m[f]}),I}return m}resolveWithEnvironment(m,I,f){return this.recursiveResolve({env:this.prepareEnv(m),userHome:void 0},I?I.uri:void 0,f)}async resolveAsync(m,I){const f={env:await this._envVariablesPromise,userHome:await this._userHomePromise};return this.recursiveResolve(f,m?m.uri:void 0,I)}async resolveAnyBase(m,I,f,h){const d=L.deepClone(I);C.isWindows&&d.windows?Object.keys(d.windows).forEach(w=>d[w]=d.windows[w]):C.isMacintosh&&d.osx?Object.keys(d.osx).forEach(w=>d[w]=d.osx[w]):C.isLinux&&d.linux&&Object.keys(d.linux).forEach(w=>d[w]=d.linux[w]),delete d.windows,delete d.osx,delete d.linux;const a={env:await this._envVariablesPromise,userHome:await this._userHomePromise};return this.recursiveResolve(a,m?m.uri:void 0,d,f,h)}async resolveAnyAsync(m,I,f){return this.resolveAnyBase(m,I,f)}async resolveAnyMap(m,I,f){const h=new Map;return{newConfig:await this.resolveAnyBase(m,I,f,h),resolvedVariables:h}}resolveWithInteractionReplace(m,I,f,h){throw new Error("resolveWithInteractionReplace not implemented.")}resolveWithInteraction(m,I,f,h){throw new Error("resolveWithInteraction not implemented.")}contributeVariable(m,I){if(this._contributedVariables.has(m))throw new Error("Variable "+m+" is contributed twice.");this._contributedVariables.set(m,I)}async recursiveResolve(m,I,f,h,d){if(b.isString(f))return this.resolveString(m,I,f,h,d);if(b.isArray(f))return Promise.all(f.map(a=>this.recursiveResolve(m,I,a,h,d)));if(b.isObject(f)){const a=Object.create(null),w=await Promise.all(Object.keys(f).map(async P=>[await this.resolveString(m,I,P,h,d),await this.recursiveResolve(m,I,f[P],h,d)]));for(const[P,l]of w)a[P]=l;return a}return f}resolveString(m,I,f,h,d){return(0,A.replaceAsync)(f,R.VARIABLE_REGEXP,async(a,w)=>{if(w.includes(R.VARIABLE_LHS))return a;let P=await this.evaluateSingleVariable(m,a,w,I,h);return d?.set(w,P),P!==a&&b.isString(P)&&P.match(R.VARIABLE_REGEXP)&&(P=await this.resolveString(m,I,P,h,d)),P})}fsPath(m){return this._labelService?this._labelService.getUriLabel(m,{noPrefix:!0}):m.fsPath}async evaluateSingleVariable(m,I,f,h,d){let a;const w=f.split(":");w.length>1&&(f=w[0],a=w[1]);const P=()=>{const n=this._context.getFilePath();if(n)return n;throw new Error((0,E.localize)(0,null,I))},l=()=>{const n=P();if(this._context.getWorkspaceFolderPathForFile){const u=this._context.getWorkspaceFolderPathForFile();if(u)return u}throw new Error((0,E.localize)(1,null,I,s.basename(n)))},_=()=>{if(a){const n=this._context.getFolderUri(a);if(n)return n;throw new Error((0,E.localize)(2,null,I,a))}if(h)return h;throw this._context.getWorkspaceFolderCount()>1?new Error((0,E.localize)(3,null,I)):new Error((0,E.localize)(4,null,I))};switch(f){case"env":if(a){if(m.env){const n=m.env[C.isWindows?a.toLowerCase():a];if(b.isString(n))return n}return""}throw new Error((0,E.localize)(5,null,I));case"config":if(a){const n=this._context.getConfigurationValue(h,a);if(b.isUndefinedOrNull(n))throw new Error((0,E.localize)(6,null,I,a));if(b.isObject(n))throw new Error((0,E.localize)(7,null,I,a));return n}throw new Error((0,E.localize)(8,null,I));case"command":return this.resolveFromMap(I,a,d,"command");case"input":return this.resolveFromMap(I,a,d,"input");case"extensionInstallFolder":if(a){const n=await this._context.getExtension(a);if(!n)throw new Error((0,E.localize)(9,null,I,a));return this.fsPath(n.extensionLocation)}throw new Error((0,E.localize)(10,null,I));default:switch(f){case"workspaceRoot":case"workspaceFolder":return(0,T.normalizeDriveLetter)(this.fsPath(_()));case"cwd":return h||a?(0,T.normalizeDriveLetter)(this.fsPath(_())):p.cwd();case"workspaceRootFolderName":case"workspaceFolderBasename":return s.basename(this.fsPath(_()));case"userHome":{if(m.userHome)return m.userHome;throw new Error((0,E.localize)(11,null,I))}case"lineNumber":{const n=this._context.getLineNumber();if(n)return n;throw new Error((0,E.localize)(12,null,I))}case"selectedText":{const n=this._context.getSelectedText();if(n)return n;throw new Error((0,E.localize)(13,null,I))}case"file":return P();case"fileWorkspaceFolder":return l();case"relativeFile":return h||a?s.relative(this.fsPath(_()),P()):P();case"relativeFileDirname":{const n=s.dirname(P());if(h||a){const u=s.relative(this.fsPath(_()),n);return u.length===0?".":u}return n}case"fileDirname":return s.dirname(P());case"fileExtname":return s.extname(P());case"fileBasename":return s.basename(P());case"fileBasenameNoExtension":{const n=s.basename(P());return n.slice(0,n.length-s.extname(n).length)}case"fileDirnameBasename":return s.basename(s.dirname(P()));case"execPath":{const n=this._context.getExecPath();return n||I}case"execInstallFolder":{const n=this._context.getAppRoot();return n||I}case"pathSeparator":return s.sep;default:try{const n=a?`${f}:${a}`:f;return this.resolveFromMap(I,n,d,void 0)}catch{return I}}}}resolveFromMap(m,I,f,h){if(I&&f){const d=h===void 0?f[I]:f[h+":"+I];if(typeof d=="string")return d;throw new Error((0,E.localize)(14,null,m))}return m}}e.AbstractVariableResolverService=R,R.VARIABLE_LHS="${",R.VARIABLE_REGEXP=/\$\{(.*?)\}/g}),define(ye[90],Ce([1,0,3,162]),function(ee,e,s,p){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.preferredSideBySideGroupDirection=e.isEditorGroup=e.OpenEditorContext=e.GroupsOrder=e.isEditorReplacement=e.MergeGroupMode=e.GroupsArrangement=e.GroupLocation=e.GroupOrientation=e.GroupDirection=e.IEditorGroupsService=void 0,e.IEditorGroupsService=(0,s.createDecorator)("editorGroupsService");var b;(function(f){f[f.UP=0]="UP",f[f.DOWN=1]="DOWN",f[f.LEFT=2]="LEFT",f[f.RIGHT=3]="RIGHT"})(b=e.GroupDirection||(e.GroupDirection={}));var L;(function(f){f[f.HORIZONTAL=0]="HORIZONTAL",f[f.VERTICAL=1]="VERTICAL"})(L=e.GroupOrientation||(e.GroupOrientation={}));var C;(function(f){f[f.FIRST=0]="FIRST",f[f.LAST=1]="LAST",f[f.NEXT=2]="NEXT",f[f.PREVIOUS=3]="PREVIOUS"})(C=e.GroupLocation||(e.GroupLocation={}));var T;(function(f){f[f.MAXIMIZE=0]="MAXIMIZE",f[f.EVEN=1]="EVEN",f[f.TOGGLE=2]="TOGGLE"})(T=e.GroupsArrangement||(e.GroupsArrangement={}));var E;(function(f){f[f.COPY_EDITORS=0]="COPY_EDITORS",f[f.MOVE_EDITORS=1]="MOVE_EDITORS"})(E=e.MergeGroupMode||(e.MergeGroupMode={}));function A(f){const h=f;return(0,p.isEditorInput)(h?.editor)&&(0,p.isEditorInput)(h?.replacement)}e.isEditorReplacement=A;var R;(function(f){f[f.CREATION_TIME=0]="CREATION_TIME",f[f.MOST_RECENTLY_ACTIVE=1]="MOST_RECENTLY_ACTIVE",f[f.GRID_APPEARANCE=2]="GRID_APPEARANCE"})(R=e.GroupsOrder||(e.GroupsOrder={}));var y;(function(f){f[f.NEW_EDITOR=1]="NEW_EDITOR",f[f.MOVE_EDITOR=2]="MOVE_EDITOR",f[f.COPY_EDITOR=3]="COPY_EDITOR"})(y=e.OpenEditorContext||(e.OpenEditorContext={}));function m(f){const h=f;return!!h&&typeof h.id=="number"&&Array.isArray(h.editors)}e.isEditorGroup=m;function I(f){return f.getValue("workbench.editor.openSideBySideDirection")==="down"?1:3}e.preferredSideBySideGroupDirection=I}),define(ye[171],Ce([1,0,3,90]),function(ee,e,s,p){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.isPreferredGroup=e.SIDE_GROUP=e.ACTIVE_GROUP=e.IEditorService=void 0,e.IEditorService=(0,s.createDecorator)("editorService"),e.ACTIVE_GROUP=-1,e.SIDE_GROUP=-2;function b(L){const C=L;return typeof L=="number"||(0,p.isEditorGroup)(C)}e.isPreferredGroup=b}),define(ye[8],Ce([1,0,16,22,75,25,105,55,26,10,2,48,66,143,80,89,88,46,47,171,6,172]),function(ee,e,s,p,b,L,C,T,E,A,R,y,m,I,f,h,d,a,w,P,l,_){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.DataTransfer=e.DataTransferItem=e.ViewBadge=e.TypeHierarchyItem=e.CodeActionTriggerKind=e.TestCoverage=e.TestResults=e.TestItem=e.TestTag=e.TestMessage=e.NotebookRendererScript=e.NotebookDocumentContentOptions=e.NotebookStatusBarItem=e.NotebookExclusiveDocumentPattern=e.NotebookCellOutput=e.NotebookCellOutputItem=e.NotebookCellData=e.NotebookData=e.NotebookCellKind=e.NotebookCellExecutionState=e.NotebookCellExecutionSummary=e.NotebookRange=e.LanguageSelector=e.GlobPattern=e.TextEditorOpenOptions=e.FoldingRangeKind=e.FoldingRange=e.ProgressLocation=e.EndOfLine=e.TextEditorLineNumbersStyle=e.TextDocumentSaveReason=e.SelectionRange=e.Color=e.ColorPresentation=e.DocumentLink=e.InlayHintKind=e.InlayHintLabelPart=e.InlayHint=e.SignatureHelp=e.SignatureInformation=e.ParameterInformation=e.CompletionItem=e.CompletionItemKind=e.CompletionItemTag=e.CompletionContext=e.CompletionTriggerKind=e.DocumentHighlight=e.InlineValueContext=e.InlineValue=e.EvaluatableExpression=e.Hover=e.DefinitionLink=e.location=e.CallHierarchyOutgoingCall=e.CallHierarchyIncomingCall=e.CallHierarchyItem=e.DocumentSymbol=e.WorkspaceSymbol=e.SymbolTag=e.SymbolKind=e.WorkspaceEdit=e.TextEdit=e.DecorationRenderOptions=e.DecorationRangeBehavior=e.ThemableDecorationRenderOptions=e.ThemableDecorationAttachmentRenderOptions=e.pathOrURIToURI=e.fromRangeOrRangeWithMessage=e.MarkdownString=e.isDecorationOptionsArr=e.ViewColumn=e.DiagnosticSeverity=e.DiagnosticRelatedInformation=e.Diagnostic=e.DiagnosticTag=e.DocumentSelector=e.Position=e.TokenType=e.Range=e.Selection=void 0;var n;(function(we){function De(q){const{selectionStartLineNumber:Pe,selectionStartColumn:Le,positionLineNumber:Xe,positionColumn:Qe}=q,Ge=new l.Position(Pe-1,Le-1),pt=new l.Position(Xe-1,Qe-1);return new l.Selection(Ge,pt)}we.to=De;function me(q){const{anchor:Pe,active:Le}=q;return{selectionStartLineNumber:Pe.line+1,selectionStartColumn:Pe.character+1,positionLineNumber:Le.line+1,positionColumn:Le.character+1}}we.from=me})(n=e.Selection||(e.Selection={}));var u;(function(we){function De(q){if(!q)return;const{start:Pe,end:Le}=q;return{startLineNumber:Pe.line+1,startColumn:Pe.character+1,endLineNumber:Le.line+1,endColumn:Le.character+1}}we.from=De;function me(q){if(!q)return;const{startLineNumber:Pe,startColumn:Le,endLineNumber:Xe,endColumn:Qe}=q;return new l.Range(Pe-1,Le-1,Xe-1,Qe-1)}we.to=me})(u=e.Range||(e.Range={}));var i;(function(we){function De(me){switch(me){case 1:return l.StandardTokenType.Comment;case 0:return l.StandardTokenType.Other;case 3:return l.StandardTokenType.RegEx;case 2:return l.StandardTokenType.String}}we.to=De})(i=e.TokenType||(e.TokenType={}));var o;(function(we){function De(q){return new l.Position(q.lineNumber-1,q.column-1)}we.to=De;function me(q){return{lineNumber:q.line+1,column:q.character+1}}we.from=me})(o=e.Position||(e.Position={}));var r;(function(we){function De(Pe,Le){return(0,s.coalesce)((0,s.asArray)(Pe).map(Xe=>me(Xe,Le)))}we.from=De;function me(Pe,Le){if(typeof Pe=="string")return{$serialized:!0,language:Pe};if(Pe)return{$serialized:!0,language:Pe.language,scheme:q(Pe.scheme,Le),pattern:he.from(Pe.pattern)??void 0,exclusive:Pe.exclusive,notebookType:Pe.notebookType}}function q(Pe,Le){return Le&&typeof Pe=="string"?Le.transformOutgoingScheme(Pe):Pe}})(r=e.DocumentSelector||(e.DocumentSelector={}));var t;(function(we){function De(q){switch(q){case l.DiagnosticTag.Unnecessary:return 1;case l.DiagnosticTag.Deprecated:return 2}}we.from=De;function me(q){switch(q){case 1:return l.DiagnosticTag.Unnecessary;case 2:return l.DiagnosticTag.Deprecated;default:return}}we.to=me})(t=e.DiagnosticTag||(e.DiagnosticTag={}));var c;(function(we){function De(q){let Pe;return q.code&&((0,A.isString)(q.code)||(0,A.isNumber)(q.code)?Pe=String(q.code):Pe={value:String(q.code.value),target:q.code.target}),{...u.from(q.range),message:q.message,source:q.source,code:Pe,severity:g.from(q.severity),relatedInformation:q.relatedInformation&&q.relatedInformation.map(v.from),tags:Array.isArray(q.tags)?(0,s.coalesce)(q.tags.map(t.from)):void 0}}we.from=De;function me(q){const Pe=new l.Diagnostic(u.to(q),q.message,g.to(q.severity));return Pe.source=q.source,Pe.code=(0,A.isString)(q.code)?q.code:q.code?.value,Pe.relatedInformation=q.relatedInformation&&q.relatedInformation.map(v.to),Pe.tags=q.tags&&(0,s.coalesce)(q.tags.map(t.to)),Pe}we.to=me})(c=e.Diagnostic||(e.Diagnostic={}));var v;(function(we){function De(q){return{...u.from(q.location.range),message:q.message,resource:q.location.uri}}we.from=De;function me(q){return new l.DiagnosticRelatedInformation(new l.Location(q.resource,u.to(q)),q.message)}we.to=me})(v=e.DiagnosticRelatedInformation||(e.DiagnosticRelatedInformation={}));var g;(function(we){function De(q){switch(q){case l.DiagnosticSeverity.Error:return f.MarkerSeverity.Error;case l.DiagnosticSeverity.Warning:return f.MarkerSeverity.Warning;case l.DiagnosticSeverity.Information:return f.MarkerSeverity.Info;case l.DiagnosticSeverity.Hint:return f.MarkerSeverity.Hint}return f.MarkerSeverity.Error}we.from=De;function me(q){switch(q){case f.MarkerSeverity.Info:return l.DiagnosticSeverity.Information;case f.MarkerSeverity.Warning:return l.DiagnosticSeverity.Warning;case f.MarkerSeverity.Error:return l.DiagnosticSeverity.Error;case f.MarkerSeverity.Hint:return l.DiagnosticSeverity.Hint;default:return l.DiagnosticSeverity.Error}}we.to=me})(g=e.DiagnosticSeverity||(e.DiagnosticSeverity={}));var D;(function(we){function De(q){return typeof q=="number"&&q>=l.ViewColumn.One?q-1:q===l.ViewColumn.Beside?P.SIDE_GROUP:P.ACTIVE_GROUP}we.from=De;function me(q){if(typeof q=="number"&&q>=0)return q+1;throw new Error("invalid 'EditorGroupColumn'")}we.to=me})(D=e.ViewColumn||(e.ViewColumn={}));function U(we){return typeof we.range!="undefined"}function W(we){return we.length===0?!0:!!U(we[0])}e.isDecorationOptionsArr=W;var M;(function(we){function De(Qe){return Qe.map(we.from)}we.fromMany=De;function me(Qe){return Qe&&typeof Qe=="object"&&typeof Qe.language=="string"&&typeof Qe.value=="string"}function q(Qe){let Ge;if(me(Qe)){const{language:Et,value:ht}=Qe;Ge={value:"```"+Et+`
`+ht+"\n```\n"}}else l.MarkdownString.isMarkdownString(Qe)?Ge={value:Qe.value,isTrusted:Qe.isTrusted,supportThemeIcons:Qe.supportThemeIcons,supportHtml:Qe.supportHtml,baseUri:Qe.baseUri}:typeof Qe=="string"?Ge={value:Qe}:Ge={value:""};const pt=Object.create(null);Ge.uris=pt;const bt=Et=>{try{let ht=R.URI.parse(Et,!0);ht=ht.with({query:Pe(ht.query,pt)}),pt[Et]=ht}catch{}return""},kt=new C.marked.Renderer;return kt.link=bt,kt.image=Et=>typeof Et=="string"?bt(b.parseHrefAndDimensions(Et).href):"",(0,C.marked)(Ge.value,{renderer:kt}),Ge}we.from=q;function Pe(Qe,Ge){if(!Qe)return Qe;let pt;try{pt=(0,T.parse)(Qe)}catch{}if(!pt)return Qe;let bt=!1;return pt=(0,E.cloneAndChange)(pt,kt=>{if(R.URI.isUri(kt)){const Et=`__uri_${Math.random().toString(16).slice(2,8)}`;return Ge[Et]=kt,bt=!0,Et}else return}),bt?JSON.stringify(pt):Qe}function Le(Qe){const Ge=new l.MarkdownString(Qe.value,Qe.supportThemeIcons);return Ge.isTrusted=Qe.isTrusted,Ge.supportHtml=Qe.supportHtml,Ge.baseUri=Qe.baseUri?R.URI.from(Qe.baseUri):void 0,Ge}we.to=Le;function Xe(Qe){if(!!Qe)return typeof Qe=="string"?Qe:we.from(Qe)}we.fromStrict=Xe})(M=e.MarkdownString||(e.MarkdownString={}));function S(we){return W(we)?we.map(De=>({range:u.from(De.range),hoverMessage:Array.isArray(De.hoverMessage)?M.fromMany(De.hoverMessage):De.hoverMessage?M.from(De.hoverMessage):void 0,renderOptions:De.renderOptions})):we.map(De=>({range:u.from(De)}))}e.fromRangeOrRangeWithMessage=S;function z(we){return typeof we=="undefined"?we:typeof we=="string"?R.URI.file(we):we}e.pathOrURIToURI=z;var $;(function(we){function De(me){return typeof me=="undefined"?me:{contentText:me.contentText,contentIconPath:me.contentIconPath?z(me.contentIconPath):void 0,border:me.border,borderColor:me.borderColor,fontStyle:me.fontStyle,fontWeight:me.fontWeight,textDecoration:me.textDecoration,color:me.color,backgroundColor:me.backgroundColor,margin:me.margin,width:me.width,height:me.height}}we.from=De})($=e.ThemableDecorationAttachmentRenderOptions||(e.ThemableDecorationAttachmentRenderOptions={}));var N;(function(we){function De(me){return typeof me=="undefined"?me:{backgroundColor:me.backgroundColor,outline:me.outline,outlineColor:me.outlineColor,outlineStyle:me.outlineStyle,outlineWidth:me.outlineWidth,border:me.border,borderColor:me.borderColor,borderRadius:me.borderRadius,borderSpacing:me.borderSpacing,borderStyle:me.borderStyle,borderWidth:me.borderWidth,fontStyle:me.fontStyle,fontWeight:me.fontWeight,textDecoration:me.textDecoration,cursor:me.cursor,color:me.color,opacity:me.opacity,letterSpacing:me.letterSpacing,gutterIconPath:me.gutterIconPath?z(me.gutterIconPath):void 0,gutterIconSize:me.gutterIconSize,overviewRulerColor:me.overviewRulerColor,before:me.before?$.from(me.before):void 0,after:me.after?$.from(me.after):void 0}}we.from=De})(N=e.ThemableDecorationRenderOptions||(e.ThemableDecorationRenderOptions={}));var K;(function(we){function De(me){if(typeof me=="undefined")return me;switch(me){case l.DecorationRangeBehavior.OpenOpen:return 0;case l.DecorationRangeBehavior.ClosedClosed:return 1;case l.DecorationRangeBehavior.OpenClosed:return 2;case l.DecorationRangeBehavior.ClosedOpen:return 3}}we.from=De})(K=e.DecorationRangeBehavior||(e.DecorationRangeBehavior={}));var V;(function(we){function De(me){return{isWholeLine:me.isWholeLine,rangeBehavior:me.rangeBehavior?K.from(me.rangeBehavior):void 0,overviewRulerLane:me.overviewRulerLane,light:me.light?N.from(me.light):void 0,dark:me.dark?N.from(me.dark):void 0,backgroundColor:me.backgroundColor,outline:me.outline,outlineColor:me.outlineColor,outlineStyle:me.outlineStyle,outlineWidth:me.outlineWidth,border:me.border,borderColor:me.borderColor,borderRadius:me.borderRadius,borderSpacing:me.borderSpacing,borderStyle:me.borderStyle,borderWidth:me.borderWidth,fontStyle:me.fontStyle,fontWeight:me.fontWeight,textDecoration:me.textDecoration,cursor:me.cursor,color:me.color,opacity:me.opacity,letterSpacing:me.letterSpacing,gutterIconPath:me.gutterIconPath?z(me.gutterIconPath):void 0,gutterIconSize:me.gutterIconSize,overviewRulerColor:me.overviewRulerColor,before:me.before?$.from(me.before):void 0,after:me.after?$.from(me.after):void 0}}we.from=De})(V=e.DecorationRenderOptions||(e.DecorationRenderOptions={}));var F;(function(we){function De(q){return{text:q.newText,eol:q.newEol&&Ke.from(q.newEol),range:u.from(q.range)}}we.from=De;function me(q){const Pe=new l.TextEdit(u.to(q.range),q.text);return Pe.newEol=typeof q.eol=="undefined"?void 0:Ke.to(q.eol),Pe}we.to=me})(F=e.TextEdit||(e.TextEdit={}));var ne;(function(we){function De(q,Pe,Le){const Xe={edits:[]};if(q instanceof l.WorkspaceEdit){const Qe=new L.ResourceSet;for(const Ge of q._allEntries())Ge._type===1&&R.URI.isUri(Ge.to)&&Ge.from===void 0&&Qe.add(Ge.to);for(const Ge of q._allEntries())if(Ge._type===1)Xe.edits.push({oldResource:Ge.from,newResource:Ge.to,options:Ge.options,metadata:Ge.metadata});else if(Ge._type===2)Xe.edits.push({resource:Ge.uri,textEdit:F.from(Ge.edit),versionId:Qe.has(Ge.uri)?void 0:Pe?.getTextDocumentVersion(Ge.uri),metadata:Ge.metadata});else if(Ge._type===6){if(!Le){console.warn("DROPPING snippet text edit because proposal IS NOT ENABLED",Ge);continue}Xe.edits.push({resource:Ge.uri,textEdit:{range:u.from(Ge.range),text:Ge.edit.value,insertAsSnippet:!0},versionId:Qe.has(Ge.uri)?void 0:Pe?.getTextDocumentVersion(Ge.uri),metadata:Ge.metadata})}else Ge._type===3?Xe.edits.push({metadata:Ge.metadata,resource:Ge.uri,cellEdit:Ge.edit,notebookMetadata:Ge.notebookMetadata,notebookVersionId:Pe?.getNotebookDocumentVersion(Ge.uri)}):Ge._type===5&&Xe.edits.push({metadata:Ge.metadata,resource:Ge.uri,notebookVersionId:Pe?.getNotebookDocumentVersion(Ge.uri),cellEdit:{editType:1,index:Ge.index,count:Ge.count,cells:Ge.cells.map(rt.from)}})}return Xe}we.from=De;function me(q){const Pe=new l.WorkspaceEdit;for(const Le of q.edits)Le.textEdit?Pe.replace(R.URI.revive(Le.resource),u.to(Le.textEdit.range),Le.textEdit.text):Pe.renameFile(R.URI.revive(Le.oldResource),R.URI.revive(Le.newResource),Le.options);return Pe}we.to=me})(ne=e.WorkspaceEdit||(e.WorkspaceEdit={}));var ce;(function(we){const De=Object.create(null);De[l.SymbolKind.File]=0,De[l.SymbolKind.Module]=1,De[l.SymbolKind.Namespace]=2,De[l.SymbolKind.Package]=3,De[l.SymbolKind.Class]=4,De[l.SymbolKind.Method]=5,De[l.SymbolKind.Property]=6,De[l.SymbolKind.Field]=7,De[l.SymbolKind.Constructor]=8,De[l.SymbolKind.Enum]=9,De[l.SymbolKind.Interface]=10,De[l.SymbolKind.Function]=11,De[l.SymbolKind.Variable]=12,De[l.SymbolKind.Constant]=13,De[l.SymbolKind.String]=14,De[l.SymbolKind.Number]=15,De[l.SymbolKind.Boolean]=16,De[l.SymbolKind.Array]=17,De[l.SymbolKind.Object]=18,De[l.SymbolKind.Key]=19,De[l.SymbolKind.Null]=20,De[l.SymbolKind.EnumMember]=21,De[l.SymbolKind.Struct]=22,De[l.SymbolKind.Event]=23,De[l.SymbolKind.Operator]=24,De[l.SymbolKind.TypeParameter]=25;function me(Pe){return typeof De[Pe]=="number"?De[Pe]:6}we.from=me;function q(Pe){for(const Le in De)if(De[Le]===Pe)return Number(Le);return l.SymbolKind.Property}we.to=q})(ce=e.SymbolKind||(e.SymbolKind={}));var re;(function(we){function De(q){switch(q){case l.SymbolTag.Deprecated:return 1}}we.from=De;function me(q){switch(q){case 1:return l.SymbolTag.Deprecated}}we.to=me})(re=e.SymbolTag||(e.SymbolTag={}));var fe;(function(we){function De(q){return{name:q.name,kind:ce.from(q.kind),tags:q.tags&&q.tags.map(re.from),containerName:q.containerName,location:ve.from(q.location)}}we.from=De;function me(q){const Pe=new l.SymbolInformation(q.name,ce.to(q.kind),q.containerName,ve.to(q.location));return Pe.tags=q.tags&&q.tags.map(re.to),Pe}we.to=me})(fe=e.WorkspaceSymbol||(e.WorkspaceSymbol={}));var ie;(function(we){function De(q){const Pe={name:q.name||"!!MISSING: name!!",detail:q.detail,range:u.from(q.range),selectionRange:u.from(q.selectionRange),kind:ce.from(q.kind),tags:q.tags?.map(re.from)??[]};return q.children&&(Pe.children=q.children.map(De)),Pe}we.from=De;function me(q){const Pe=new l.DocumentSymbol(q.name,q.detail,ce.to(q.kind),u.to(q.range),u.to(q.selectionRange));return(0,s.isNonEmptyArray)(q.tags)&&(Pe.tags=q.tags.map(re.to)),q.children&&(Pe.children=q.children.map(me)),Pe}we.to=me})(ie=e.DocumentSymbol||(e.DocumentSymbol={}));var Ee;(function(we){function De(q){const Pe=new l.CallHierarchyItem(ce.to(q.kind),q.name,q.detail||"",R.URI.revive(q.uri),u.to(q.range),u.to(q.selectionRange));return Pe._sessionId=q._sessionId,Pe._itemId=q._itemId,Pe}we.to=De;function me(q,Pe,Le){if(Pe=Pe??q._sessionId,Le=Le??q._itemId,Pe===void 0||Le===void 0)throw new Error("invalid item");return{_sessionId:Pe,_itemId:Le,name:q.name,detail:q.detail,kind:ce.from(q.kind),uri:q.uri,range:u.from(q.range),selectionRange:u.from(q.selectionRange),tags:q.tags?.map(re.from)}}we.from=me})(Ee=e.CallHierarchyItem||(e.CallHierarchyItem={}));var be;(function(we){function De(me){return new l.CallHierarchyIncomingCall(Ee.to(me.from),me.fromRanges.map(q=>u.to(q)))}we.to=De})(be=e.CallHierarchyIncomingCall||(e.CallHierarchyIncomingCall={}));var te;(function(we){function De(me){return new l.CallHierarchyOutgoingCall(Ee.to(me.to),me.fromRanges.map(q=>u.to(q)))}we.to=De})(te=e.CallHierarchyOutgoingCall||(e.CallHierarchyOutgoingCall={}));var ve;(function(we){function De(q){return{range:q.range&&u.from(q.range),uri:q.uri}}we.from=De;function me(q){return new l.Location(R.URI.revive(q.uri),u.to(q.range))}we.to=me})(ve=e.location||(e.location={}));var Re;(function(we){function De(q){const Pe=q,Le=q;return{originSelectionRange:Pe.originSelectionRange?u.from(Pe.originSelectionRange):void 0,uri:Pe.targetUri?Pe.targetUri:Le.uri,range:u.from(Pe.targetRange?Pe.targetRange:Le.range),targetSelectionRange:Pe.targetSelectionRange?u.from(Pe.targetSelectionRange):void 0}}we.from=De;function me(q){return{targetUri:R.URI.revive(q.uri),targetRange:u.to(q.range),targetSelectionRange:q.targetSelectionRange?u.to(q.targetSelectionRange):void 0,originSelectionRange:q.originSelectionRange?u.to(q.originSelectionRange):void 0}}we.to=me})(Re=e.DefinitionLink||(e.DefinitionLink={}));var Fe;(function(we){function De(q){return{range:u.from(q.range),contents:M.fromMany(q.contents)}}we.from=De;function me(q){return new l.Hover(q.contents.map(M.to),u.to(q.range))}we.to=me})(Fe=e.Hover||(e.Hover={}));var $e;(function(we){function De(q){return{range:u.from(q.range),expression:q.expression}}we.from=De;function me(q){return new l.EvaluatableExpression(u.to(q.range),q.expression)}we.to=me})($e=e.EvaluatableExpression||(e.EvaluatableExpression={}));var Ye;(function(we){function De(q){if(q instanceof l.InlineValueText)return{type:"text",range:u.from(q.range),text:q.text};if(q instanceof l.InlineValueVariableLookup)return{type:"variable",range:u.from(q.range),variableName:q.variableName,caseSensitiveLookup:q.caseSensitiveLookup};if(q instanceof l.InlineValueEvaluatableExpression)return{type:"expression",range:u.from(q.range),expression:q.expression};throw new Error("Unknown 'InlineValue' type")}we.from=De;function me(q){switch(q.type){case"text":return{range:u.to(q.range),text:q.text};case"variable":return{range:u.to(q.range),variableName:q.variableName,caseSensitiveLookup:q.caseSensitiveLookup};case"expression":return{range:u.to(q.range),expression:q.expression}}}we.to=me})(Ye=e.InlineValue||(e.InlineValue={}));var Ie;(function(we){function De(q){return{frameId:q.frameId,stoppedLocation:u.from(q.stoppedLocation)}}we.from=De;function me(q){return new l.InlineValueContext(q.frameId,u.to(q.stoppedLocation))}we.to=me})(Ie=e.InlineValueContext||(e.InlineValueContext={}));var Se;(function(we){function De(q){return{range:u.from(q.range),kind:q.kind}}we.from=De;function me(q){return new l.DocumentHighlight(u.to(q.range),q.kind)}we.to=me})(Se=e.DocumentHighlight||(e.DocumentHighlight={}));var Te;(function(we){function De(me){switch(me){case 1:return l.CompletionTriggerKind.TriggerCharacter;case 2:return l.CompletionTriggerKind.TriggerForIncompleteCompletions;case 0:default:return l.CompletionTriggerKind.Invoke}}we.to=De})(Te=e.CompletionTriggerKind||(e.CompletionTriggerKind={}));var ae;(function(we){function De(me){return{triggerKind:Te.to(me.triggerKind),triggerCharacter:me.triggerCharacter}}we.to=De})(ae=e.CompletionContext||(e.CompletionContext={}));var le;(function(we){function De(q){switch(q){case l.CompletionItemTag.Deprecated:return 1}}we.from=De;function me(q){switch(q){case 1:return l.CompletionItemTag.Deprecated}}we.to=me})(le=e.CompletionItemTag||(e.CompletionItemTag={}));var X;(function(we){const De=new Map([[l.CompletionItemKind.Method,0],[l.CompletionItemKind.Function,1],[l.CompletionItemKind.Constructor,2],[l.CompletionItemKind.Field,3],[l.CompletionItemKind.Variable,4],[l.CompletionItemKind.Class,5],[l.CompletionItemKind.Interface,7],[l.CompletionItemKind.Struct,6],[l.CompletionItemKind.Module,8],[l.CompletionItemKind.Property,9],[l.CompletionItemKind.Unit,12],[l.CompletionItemKind.Value,13],[l.CompletionItemKind.Constant,14],[l.CompletionItemKind.Enum,15],[l.CompletionItemKind.EnumMember,16],[l.CompletionItemKind.Keyword,17],[l.CompletionItemKind.Snippet,27],[l.CompletionItemKind.Text,18],[l.CompletionItemKind.Color,19],[l.CompletionItemKind.File,20],[l.CompletionItemKind.Reference,21],[l.CompletionItemKind.Folder,23],[l.CompletionItemKind.Event,10],[l.CompletionItemKind.Operator,11],[l.CompletionItemKind.TypeParameter,24],[l.CompletionItemKind.Issue,26],[l.CompletionItemKind.User,25]]);function me(Le){return De.get(Le)??9}we.from=me;const q=new Map([[0,l.CompletionItemKind.Method],[1,l.CompletionItemKind.Function],[2,l.CompletionItemKind.Constructor],[3,l.CompletionItemKind.Field],[4,l.CompletionItemKind.Variable],[5,l.CompletionItemKind.Class],[7,l.CompletionItemKind.Interface],[6,l.CompletionItemKind.Struct],[8,l.CompletionItemKind.Module],[9,l.CompletionItemKind.Property],[12,l.CompletionItemKind.Unit],[13,l.CompletionItemKind.Value],[14,l.CompletionItemKind.Constant],[15,l.CompletionItemKind.Enum],[16,l.CompletionItemKind.EnumMember],[17,l.CompletionItemKind.Keyword],[27,l.CompletionItemKind.Snippet],[18,l.CompletionItemKind.Text],[19,l.CompletionItemKind.Color],[20,l.CompletionItemKind.File],[21,l.CompletionItemKind.Reference],[23,l.CompletionItemKind.Folder],[10,l.CompletionItemKind.Event],[11,l.CompletionItemKind.Operator],[24,l.CompletionItemKind.TypeParameter],[25,l.CompletionItemKind.User],[26,l.CompletionItemKind.Issue]]);function Pe(Le){return q.get(Le)??l.CompletionItemKind.Property}we.to=Pe})(X=e.CompletionItemKind||(e.CompletionItemKind={}));var J;(function(we){function De(me,q){const Pe=new l.CompletionItem(me.label);return Pe.insertText=me.insertText,Pe.kind=X.to(me.kind),Pe.tags=me.tags?.map(le.to),Pe.detail=me.detail,Pe.documentation=b.isMarkdownString(me.documentation)?M.to(me.documentation):me.documentation,Pe.sortText=me.sortText,Pe.filterText=me.filterText,Pe.preselect=me.preselect,Pe.commitCharacters=me.commitCharacters,y.Range.isIRange(me.range)?Pe.range=u.to(me.range):typeof me.range=="object"&&(Pe.range={inserting:u.to(me.range.insert),replacing:u.to(me.range.replace)}),Pe.keepWhitespace=typeof me.insertTextRules=="undefined"?!1:Boolean(me.insertTextRules&1),typeof me.insertTextRules!="undefined"&&me.insertTextRules&4?Pe.insertText=new l.SnippetString(me.insertText):(Pe.insertText=me.insertText,Pe.textEdit=Pe.range instanceof l.Range?new l.TextEdit(Pe.range,Pe.insertText):void 0),me.additionalTextEdits&&me.additionalTextEdits.length>0&&(Pe.additionalTextEdits=me.additionalTextEdits.map(Le=>F.to(Le))),Pe.command=q&&me.command?q.fromInternal(me.command):void 0,Pe}we.to=De})(J=e.CompletionItem||(e.CompletionItem={}));var k;(function(we){function De(q){return{label:q.label,documentation:M.fromStrict(q.documentation)}}we.from=De;function me(q){return{label:q.label,documentation:b.isMarkdownString(q.documentation)?M.to(q.documentation):q.documentation}}we.to=me})(k=e.ParameterInformation||(e.ParameterInformation={}));var B;(function(we){function De(q){return{label:q.label,documentation:M.fromStrict(q.documentation),parameters:Array.isArray(q.parameters)?q.parameters.map(k.from):[],activeParameter:q.activeParameter}}we.from=De;function me(q){return{label:q.label,documentation:b.isMarkdownString(q.documentation)?M.to(q.documentation):q.documentation,parameters:Array.isArray(q.parameters)?q.parameters.map(k.to):[],activeParameter:q.activeParameter}}we.to=me})(B=e.SignatureInformation||(e.SignatureInformation={}));var H;(function(we){function De(q){return{activeSignature:q.activeSignature,activeParameter:q.activeParameter,signatures:Array.isArray(q.signatures)?q.signatures.map(B.from):[]}}we.from=De;function me(q){return{activeSignature:q.activeSignature,activeParameter:q.activeParameter,signatures:Array.isArray(q.signatures)?q.signatures.map(B.to):[]}}we.to=me})(H=e.SignatureHelp||(e.SignatureHelp={}));var j;(function(we){function De(me,q){const Pe=new l.InlayHint(o.to(q.position),typeof q.label=="string"?q.label:q.label.map(oe.to.bind(void 0,me)),q.kind&&ue.to(q.kind));return Pe.textEdits=q.textEdits&&q.textEdits.map(F.to),Pe.tooltip=b.isMarkdownString(q.tooltip)?M.to(q.tooltip):q.tooltip,Pe.paddingLeft=q.paddingLeft,Pe.paddingRight=q.paddingRight,Pe}we.to=De})(j=e.InlayHint||(e.InlayHint={}));var oe;(function(we){function De(me,q){const Pe=new l.InlayHintLabelPart(q.label);return Pe.tooltip=b.isMarkdownString(q.tooltip)?M.to(q.tooltip):q.tooltip,m.Command.is(q.command)&&(Pe.command=me.fromInternal(q.command)),q.location&&(Pe.location=ve.to(q.location)),Pe}we.to=De})(oe=e.InlayHintLabelPart||(e.InlayHintLabelPart={}));var ue;(function(we){function De(q){return q}we.from=De;function me(q){return q}we.to=me})(ue=e.InlayHintKind||(e.InlayHintKind={}));var Z;(function(we){function De(q){return{range:u.from(q.range),url:q.target,tooltip:q.tooltip}}we.from=De;function me(q){let Pe;if(q.url)try{Pe=typeof q.url=="string"?R.URI.parse(q.url,!0):R.URI.revive(q.url)}catch{}return new l.DocumentLink(u.to(q.range),Pe)}we.to=me})(Z=e.DocumentLink||(e.DocumentLink={}));var pe;(function(we){function De(q){const Pe=new l.ColorPresentation(q.label);return q.textEdit&&(Pe.textEdit=F.to(q.textEdit)),q.additionalTextEdits&&(Pe.additionalTextEdits=q.additionalTextEdits.map(Le=>F.to(Le))),Pe}we.to=De;function me(q){return{label:q.label,textEdit:q.textEdit?F.from(q.textEdit):void 0,additionalTextEdits:q.additionalTextEdits?q.additionalTextEdits.map(Pe=>F.from(Pe)):void 0}}we.from=me})(pe=e.ColorPresentation||(e.ColorPresentation={}));var ge;(function(we){function De(q){return new l.Color(q[0],q[1],q[2],q[3])}we.to=De;function me(q){return[q.red,q.green,q.blue,q.alpha]}we.from=me})(ge=e.Color||(e.Color={}));var Ne;(function(we){function De(q){return{range:u.from(q.range)}}we.from=De;function me(q){return new l.SelectionRange(u.to(q.range))}we.to=me})(Ne=e.SelectionRange||(e.SelectionRange={}));var Be;(function(we){function De(me){switch(me){case 2:return l.TextDocumentSaveReason.AfterDelay;case 1:return l.TextDocumentSaveReason.Manual;case 3:case 4:return l.TextDocumentSaveReason.FocusOut}}we.to=De})(Be=e.TextDocumentSaveReason||(e.TextDocumentSaveReason={}));var Ze;(function(we){function De(q){switch(q){case l.TextEditorLineNumbersStyle.Off:return 0;case l.TextEditorLineNumbersStyle.Relative:return 2;case l.TextEditorLineNumbersStyle.On:default:return 1}}we.from=De;function me(q){switch(q){case 0:return l.TextEditorLineNumbersStyle.Off;case 2:return l.TextEditorLineNumbersStyle.Relative;case 1:default:return l.TextEditorLineNumbersStyle.On}}we.to=me})(Ze=e.TextEditorLineNumbersStyle||(e.TextEditorLineNumbersStyle={}));var Ke;(function(we){function De(q){if(q===l.EndOfLine.CRLF)return 1;if(q===l.EndOfLine.LF)return 0}we.from=De;function me(q){if(q===1)return l.EndOfLine.CRLF;if(q===0)return l.EndOfLine.LF}we.to=me})(Ke=e.EndOfLine||(e.EndOfLine={}));var ke;(function(we){function De(me){if(typeof me=="object")return me.viewId;switch(me){case l.ProgressLocation.SourceControl:return 3;case l.ProgressLocation.Window:return 10;case l.ProgressLocation.Notification:return 15}throw new Error("Unknown 'ProgressLocation'")}we.from=De})(ke=e.ProgressLocation||(e.ProgressLocation={}));var nt;(function(we){function De(me){const q={start:me.start+1,end:me.end+1};return me.kind&&(q.kind=G.from(me.kind)),q}we.from=De})(nt=e.FoldingRange||(e.FoldingRange={}));var G;(function(we){function De(me){if(me)switch(me){case l.FoldingRangeKind.Comment:return m.FoldingRangeKind.Comment;case l.FoldingRangeKind.Imports:return m.FoldingRangeKind.Imports;case l.FoldingRangeKind.Region:return m.FoldingRangeKind.Region}}we.from=De})(G=e.FoldingRangeKind||(e.FoldingRangeKind={}));var Q;(function(we){function De(me){if(me)return{pinned:typeof me.preview=="boolean"?!me.preview:void 0,inactive:me.background,preserveFocus:me.preserveFocus,selection:typeof me.selection=="object"?u.from(me.selection):void 0,override:typeof me.override=="boolean"?I.EditorResolution.DISABLED:void 0}}we.from=De})(Q=e.TextEditorOpenOptions||(e.TextEditorOpenOptions={}));var he;(function(we){function De(Le){return Le instanceof l.RelativePattern?Le.toJSON():typeof Le=="string"?Le:me(Le)||q(Le)?new l.RelativePattern(Le.baseUri??Le.base,Le.pattern).toJSON():Le}we.from=De;function me(Le){const Xe=Le;return Xe?R.URI.isUri(Xe.baseUri)&&typeof Xe.pattern=="string":!1}function q(Le){const Xe=Le;return Xe?typeof Xe.base=="string"&&typeof Xe.pattern=="string":!1}function Pe(Le){return typeof Le=="string"?Le:new l.RelativePattern(R.URI.revive(Le.baseUri),Le.pattern)}we.to=Pe})(he=e.GlobPattern||(e.GlobPattern={}));var Ue;(function(we){function De(me){if(me){if(Array.isArray(me))return me.map(De);if(typeof me=="string")return me;{const q=me;return{language:q.language,scheme:q.scheme,pattern:he.from(q.pattern),exclusive:q.exclusive,notebookType:q.notebookType}}}else return}we.from=De})(Ue=e.LanguageSelector||(e.LanguageSelector={}));var We;(function(we){function De(q){return{start:q.start,end:q.end}}we.from=De;function me(q){return new l.NotebookRange(q.start,q.end)}we.to=me})(We=e.NotebookRange||(e.NotebookRange={}));var et;(function(we){function De(q){return{timing:typeof q.runStartTime=="number"&&typeof q.runEndTime=="number"?{startTime:q.runStartTime,endTime:q.runEndTime}:void 0,executionOrder:q.executionOrder,success:q.lastRunSuccess}}we.to=De;function me(q){return{lastRunSuccess:q.success,runStartTime:q.timing?.startTime,runEndTime:q.timing?.endTime,executionOrder:q.executionOrder}}we.from=me})(et=e.NotebookCellExecutionSummary||(e.NotebookCellExecutionSummary={}));var je;(function(we){function De(me){if(me===d.NotebookCellExecutionState.Executing)return l.NotebookCellExecutionState.Executing;if(me===d.NotebookCellExecutionState.Pending)return l.NotebookCellExecutionState.Pending;if(me===d.NotebookCellExecutionState.Unconfirmed)return l.NotebookCellExecutionState.Pending;throw new Error(`Unknown state: ${me}`)}we.to=De})(je=e.NotebookCellExecutionState||(e.NotebookCellExecutionState={}));var He;(function(we){function De(q){switch(q){case l.NotebookCellKind.Markup:return d.CellKind.Markup;case l.NotebookCellKind.Code:default:return d.CellKind.Code}}we.from=De;function me(q){switch(q){case d.CellKind.Markup:return l.NotebookCellKind.Markup;case d.CellKind.Code:default:return l.NotebookCellKind.Code}}we.to=me})(He=e.NotebookCellKind||(e.NotebookCellKind={}));var it;(function(we){function De(q){const Pe={metadata:q.metadata??Object.create(null),cells:[]};for(const Le of q.cells)l.NotebookCellData.validate(Le),Pe.cells.push(rt.from(Le));return Pe}we.from=De;function me(q){const Pe=new l.NotebookData(q.cells.map(rt.to));return(0,A.isEmptyObject)(q.metadata)||(Pe.metadata=q.metadata),Pe}we.to=me})(it=e.NotebookData||(e.NotebookData={}));var rt;(function(we){function De(q){return{cellKind:He.from(q.kind),language:q.languageId,mime:q.mime,source:q.value,metadata:q.metadata,internalMetadata:et.from(q.executionSummary??{}),outputs:q.outputs?q.outputs.map(lt.from):[]}}we.from=De;function me(q){return new l.NotebookCellData(He.to(q.cellKind),q.source,q.language,q.mime,q.outputs?q.outputs.map(lt.to):void 0,q.metadata,q.internalMetadata?et.to(q.internalMetadata):void 0)}we.to=me})(rt=e.NotebookCellData||(e.NotebookCellData={}));var dt;(function(we){function De(q){return{mime:q.mime,valueBytes:p.VSBuffer.wrap(q.data)}}we.from=De;function me(q){return new l.NotebookCellOutputItem(q.valueBytes.buffer,q.mime)}we.to=me})(dt=e.NotebookCellOutputItem||(e.NotebookCellOutputItem={}));var lt;(function(we){function De(q){return{outputId:q.id,items:q.items.map(dt.from),metadata:q.metadata}}we.from=De;function me(q){const Pe=q.items.map(dt.to);return new l.NotebookCellOutput(Pe,q.outputId,q.metadata)}we.to=me})(lt=e.NotebookCellOutput||(e.NotebookCellOutput={}));var st;(function(we){function De(Pe){return q(Pe)?{include:(0,A.withNullAsUndefined)(he.from(Pe.include)),exclude:(0,A.withNullAsUndefined)(he.from(Pe.exclude))}:(0,A.withNullAsUndefined)(he.from(Pe))}we.from=De;function me(Pe){return q(Pe)?{include:he.to(Pe.include),exclude:he.to(Pe.exclude)}:he.to(Pe)}we.to=me;function q(Pe){const Le=Pe;return Le?!(0,A.isUndefinedOrNull)(Le.include)&&!(0,A.isUndefinedOrNull)(Le.exclude):!1}})(st=e.NotebookExclusiveDocumentPattern||(e.NotebookExclusiveDocumentPattern={}));var yt;(function(we){function De(me,q,Pe){const Le=typeof me.command=="string"?{title:"",command:me.command}:me.command;return{alignment:me.alignment===l.NotebookCellStatusBarAlignment.Left?1:2,command:q.toInternal(Le,Pe),text:me.text,tooltip:me.tooltip,accessibilityInformation:me.accessibilityInformation,priority:me.priority}}we.from=De})(yt=e.NotebookStatusBarItem||(e.NotebookStatusBarItem={}));var Ot;(function(we){function De(me){return{transientOutputs:me?.transientOutputs??!1,transientCellMetadata:me?.transientCellMetadata??{},transientDocumentMetadata:me?.transientDocumentMetadata??{}}}we.from=De})(Ot=e.NotebookDocumentContentOptions||(e.NotebookDocumentContentOptions={}));var Ft;(function(we){function De(q){return{uri:q.uri,provides:q.provides}}we.from=De;function me(q){return new l.NotebookRendererScript(R.URI.revive(q.uri),q.provides)}we.to=me})(Ft=e.NotebookRendererScript||(e.NotebookRendererScript={}));var ft;(function(we){function De(q){return{message:M.fromStrict(q.message)||"",type:0,expected:q.expectedOutput,actual:q.actualOutput,location:q.location&&{range:u.from(q.location.range),uri:q.location.uri}}}we.from=De;function me(q){const Pe=new l.TestMessage(typeof q.message=="string"?q.message:M.to(q.message));return Pe.actualOutput=q.actual,Pe.expectedOutput=q.expected,Pe.location=q.location?ve.to(q.location):void 0,Pe}we.to=me})(ft=e.TestMessage||(e.TestMessage={}));var Dt;(function(we){we.namespace=w.namespaceTestTag,we.denamespace=w.denamespaceTestTag})(Dt=e.TestTag||(e.TestTag={}));var Ut;(function(we){function De(q){const Pe=(0,h.getPrivateApiFor)(q).controllerId;return{extId:a.TestId.fromExtHostTestItem(q,Pe).toString(),label:q.label,uri:R.URI.revive(q.uri),busy:!1,tags:q.tags.map(Le=>Dt.namespace(Pe,Le.id)),range:y.Range.lift(u.from(q.range)),description:q.description||null,sortText:q.sortText||null,error:q.error&&M.fromStrict(q.error)||null}}we.from=De;function me(q){return{parent:void 0,error:void 0,id:a.TestId.fromString(q.extId).localId,label:q.label,uri:R.URI.revive(q.uri),tags:(q.tags||[]).map(Pe=>{const{tagId:Le}=Dt.denamespace(Pe);return new l.TestTag(Le)}),children:{add:()=>{},delete:()=>{},forEach:()=>{},*[Symbol.iterator](){},get:()=>{},replace:()=>{},size:0},range:u.to(q.range||void 0),canResolveChildren:!1,busy:!1,description:q.description||void 0,sortText:q.sortText||void 0}}we.toPlain=me})(Ut=e.TestItem||(e.TestItem={})),function(we){function De(q){return{id:q.id}}we.from=De;function me(q){return new l.TestTag(q.id)}we.to=me}(Dt=e.TestTag||(e.TestTag={}));var Nt;(function(we){const De=(q,Pe)=>{const Le={...Ut.toPlain(q.item),parent:void 0,taskStates:q.tasks.map(Xe=>({state:Xe.state,duration:Xe.duration,messages:Xe.messages.filter(Qe=>Qe.type===0).map(ft.to)})),children:q.children.map(Xe=>Pe.get(Xe)).filter(A.isDefined).map(Xe=>De(Xe,Pe))};for(const Xe of Le.children)Xe.parent=Le;return Le};function me(q){const Pe=[],Le=new Map;for(const Xe of q.items)Le.set(Xe.item.extId,Xe),q.request.targets.some(Qe=>Qe.controllerId===Xe.controllerId&&Qe.testIds.includes(Xe.item.extId))&&Pe.push(Xe);return{completedAt:q.completedAt,results:Pe.map(Xe=>De(Xe,Le))}}we.to=me})(Nt=e.TestResults||(e.TestResults={}));var Ve;(function(we){function De(Le){return{covered:Le.covered,total:Le.covered}}function me(Le){return"line"in Le?o.from(Le):u.from(Le)}function q(Le){return"branches"in Le?{count:Le.executionCount,location:me(Le.location),type:1,branches:Le.branches.length?Le.branches.map(Xe=>({count:Xe.executionCount,location:Xe.location&&me(Xe.location)})):void 0}:{type:0,count:Le.executionCount,location:me(Le.location)}}we.fromDetailed=q;function Pe(Le){return{uri:Le.uri,statement:De(Le.statementCoverage),branch:Le.branchCoverage&&De(Le.branchCoverage),function:Le.functionCoverage&&De(Le.functionCoverage),details:Le.detailedCoverage?.map(q)}}we.fromFile=Pe})(Ve=e.TestCoverage||(e.TestCoverage={}));var Mt;(function(we){function De(me){switch(me){case 1:return l.CodeActionTriggerKind.Invoke;case 2:return l.CodeActionTriggerKind.Automatic}}we.to=De})(Mt=e.CodeActionTriggerKind||(e.CodeActionTriggerKind={}));var At;(function(we){function De(q){const Pe=new l.TypeHierarchyItem(ce.to(q.kind),q.name,q.detail||"",R.URI.revive(q.uri),u.to(q.range),u.to(q.selectionRange));return Pe._sessionId=q._sessionId,Pe._itemId=q._itemId,Pe}we.to=De;function me(q,Pe,Le){if(Pe=Pe??q._sessionId,Le=Le??q._itemId,Pe===void 0||Le===void 0)throw new Error("invalid item");return{_sessionId:Pe,_itemId:Le,kind:ce.from(q.kind),name:q.name,detail:q.detail??"",uri:q.uri,range:u.from(q.range),selectionRange:u.from(q.selectionRange),tags:q.tags?.map(re.from)}}we.from=me})(At=e.TypeHierarchyItem||(e.TypeHierarchyItem={}));var Lt;(function(we){function De(me){if(!!me)return{value:me.value,tooltip:me.tooltip}}we.from=De})(Lt=e.ViewBadge||(e.ViewBadge={}));var gt;(function(we){function De(me,q){const Pe=me.fileData;return Pe?new class extends l.DataTransferItem{asFile(){return{name:Pe.name,uri:R.URI.revive(Pe.uri),data:(0,_.once)(()=>q())}}}(""):new l.DataTransferItem(me.asString)}we.toDataTransferItem=De})(gt=e.DataTransferItem||(e.DataTransferItem={}));var It;(function(we){function De(q,Pe){const Le=q.items.map(([Xe,Qe],Ge)=>[Xe,gt.toDataTransferItem(Qe,()=>Pe(Ge))]);return new l.DataTransfer(Le)}we.toDataTransfer=De;async function me(q){const Pe={items:[]},Le=[];return q.forEach((Xe,Qe)=>{Le.push((async()=>{const Ge=await Xe.asString(),pt=Xe.asFile();Pe.items.push([Qe,{asString:Ge,fileData:pt?{name:pt.name,uri:pt.uri}:void 0}])})())}),await Promise.all(Le),Pe}we.toDataTransferDTO=me})(It=e.DataTransfer||(e.DataTransfer={}))}),define(ye[173],Ce([1,0,2,11,6,8,240]),function(ee,e,s,p,b,L,C){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.ExtHostDocumentSaveParticipant=void 0;class T{constructor(A,R,y,m={timeout:1500,errors:3}){this._logService=A,this._documents=R,this._mainThreadBulkEdits=y,this._thresholds=m,this._callbacks=new C.LinkedList,this._badListeners=new WeakMap}dispose(){this._callbacks.clear()}getOnWillSaveTextDocumentEvent(A){return(R,y,m)=>{const f={dispose:this._callbacks.push([R,y,A])};return Array.isArray(m)&&m.push(f),f}}async $participateInSave(A,R){const y=s.URI.revive(A);let m=!1;const I=setTimeout(()=>m=!0,this._thresholds.timeout),f=[];try{for(const h of[...this._callbacks]){if(m)break;const d=this._documents.getDocument(y),a=await this._deliverEventAsyncAndBlameBadListeners(h,{document:d,reason:L.TextDocumentSaveReason.to(R)});f.push(a)}}finally{clearTimeout(I)}return f}_deliverEventAsyncAndBlameBadListeners([A,R,y],m){const I=this._badListeners.get(A);return typeof I=="number"&&I>this._thresholds.errors?Promise.resolve(!1):this._deliverEventAsync(y,A,R,m).then(()=>!0,f=>{if(this._logService.error(`onWillSaveTextDocument-listener from extension '${y.identifier.value}' threw ERROR`),this._logService.error(f),!(f instanceof Error)||f.message!=="concurrent_edits"){const h=this._badListeners.get(A);this._badListeners.set(A,h?h+1:1),typeof h=="number"&&h>this._thresholds.errors&&this._logService.info(`onWillSaveTextDocument-listener from extension '${y.identifier.value}' will now be IGNORED because of timeouts and/or errors`)}return!1})}_deliverEventAsync(A,R,y,m){const I=[],f=Date.now(),{document:h,reason:d}=m,{version:a}=h,w=Object.freeze({document:h,reason:d,waitUntil(P){if(Object.isFrozen(I))throw(0,p.illegalState)("waitUntil can not be called async");I.push(Promise.resolve(P))}});try{R.apply(y,[w])}catch(P){return Promise.reject(P)}return Object.freeze(I),new Promise((P,l)=>{const _=setTimeout(()=>l(new Error("timeout")),this._thresholds.timeout);return Promise.all(I).then(n=>{this._logService.debug(`onWillSaveTextDocument-listener from extension '${A.identifier.value}' finished after ${Date.now()-f}ms`),clearTimeout(_),P(n)}).catch(n=>{clearTimeout(_),l(n)})}).then(P=>{const l={edits:[]};for(const _ of P)if(Array.isArray(_)&&_.every(n=>n instanceof b.TextEdit))for(const{newText:n,newEol:u,range:i}of _)l.edits.push({resource:h.uri,versionId:void 0,textEdit:{range:i&&L.Range.from(i),text:n,eol:u&&L.EndOfLine.from(u)}});if(l.edits.length!==0)return a===h.version?this._mainThreadBulkEdits.$tryApplyWorkspaceEdit(l):Promise.reject(new Error("concurrent_edits"))})}}e.ExtHostDocumentSaveParticipant=T}),define(ye[174],Ce([1,0,12,2,8,6,88]),function(ee,e,s,p,b,L,C){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.ExtHostNotebookDocument=e.ExtHostCell=void 0;class T{constructor(y,m,I,f){this.start=y,this.deletedCount=m,this.deletedItems=I,this.items=f}asApiEvent(){return{range:new L.NotebookRange(this.start,this.start+this.deletedCount),addedCells:this.items.map(y=>y.apiCell),removedCells:this.deletedItems}}}class E{constructor(y,m,I){this.notebook=y,this._extHostDocument=m,this._cellData=I,this.handle=I.handle,this.uri=p.URI.revive(I.uri),this.cellKind=I.cellKind,this._outputs=I.outputs.map(b.NotebookCellOutput.to),this._internalMetadata=I.internalMetadata??{},this._metadata=Object.freeze(I.metadata??{}),this._previousResult=Object.freeze(b.NotebookCellExecutionSummary.to(I.internalMetadata??{}))}static asModelAddData(y,m){return{EOL:m.eol,lines:m.source,languageId:m.language,uri:m.uri,isDirty:!1,versionId:1,notebook:y}}get internalMetadata(){return this._internalMetadata}get apiCell(){if(!this._apiCell){const y=this,m=this._extHostDocument.getDocument(this.uri);if(!m)throw new Error(`MISSING extHostDocument for notebook cell: ${this.uri}`);const I={get index(){return y.notebook.getCellIndex(y)},notebook:y.notebook.apiNotebook,kind:b.NotebookCellKind.to(this._cellData.cellKind),document:m.document,get mime(){return y._mime},set mime(f){y._mime=f},get outputs(){return y._outputs.slice(0)},get metadata(){return y._metadata},get executionSummary(){return y._previousResult}};this._apiCell=Object.freeze(I)}return this._apiCell}setOutputs(y){this._outputs=y.map(b.NotebookCellOutput.to)}setOutputItems(y,m,I){const f=I.map(b.NotebookCellOutputItem.to),h=this._outputs.find(d=>d.id===y);h&&(m||(h.items.length=0),h.items.push(...f))}setMetadata(y){this._metadata=Object.freeze(y)}setInternalMetadata(y){this._internalMetadata=y,this._previousResult=Object.freeze(b.NotebookCellExecutionSummary.to(y))}setMime(y){}}e.ExtHostCell=E;class A{constructor(y,m,I,f,h){this._proxy=y,this._textDocumentsAndEditors=m,this._textDocuments=I,this.uri=f,this.handle=A._handlePool++,this._cells=[],this._versionId=0,this._isDirty=!1,this._disposed=!1,this._notebookType=h.viewType,this._metadata=Object.freeze(h.metadata??Object.create(null)),this._spliceNotebookCells([[0,0,h.cells]],!0,void 0),this._versionId=h.versionId}dispose(){this._disposed=!0}get apiNotebook(){if(!this._notebook){const y=this,m={get uri(){return y.uri},get version(){return y._versionId},get notebookType(){return y._notebookType},get isDirty(){return y._isDirty},get isUntitled(){return y.uri.scheme===s.Schemas.untitled},get isClosed(){return y._disposed},get metadata(){return y._metadata},get cellCount(){return y._cells.length},cellAt(I){return I=y._validateIndex(I),y._cells[I].apiCell},getCells(I){return(I?y._getCells(I):y._cells).map(h=>h.apiCell)},save(){return y._save()}};this._notebook=Object.freeze(m)}return this._notebook}updateBackup(y){this._backup?.delete(),this._backup=y}disposeBackup(){this._backup?.delete(),this._backup=void 0}acceptDocumentPropertiesChanged(y){y.metadata&&(this._metadata=Object.freeze({...this._metadata,...y.metadata}))}acceptDirty(y){this._isDirty=y}acceptModelChanged(y,m,I){this._versionId=y.versionId,this._isDirty=m,this.acceptDocumentPropertiesChanged({metadata:I});const f={notebook:this.apiNotebook,metadata:I,cellChanges:[],contentChanges:[]},h=[];for(const a of y.rawEvents)a.kind===C.NotebookCellsChangeType.ModelChange?this._spliceNotebookCells(a.changes,!1,f.contentChanges):a.kind===C.NotebookCellsChangeType.Move?this._moveCell(a.index,a.newIdx,f.contentChanges):a.kind===C.NotebookCellsChangeType.Output?(this._setCellOutputs(a.index,a.outputs),h.push({cell:this._cells[a.index].apiCell,outputs:this._cells[a.index].apiCell.outputs})):a.kind===C.NotebookCellsChangeType.OutputItem?(this._setCellOutputItems(a.index,a.outputId,a.append,a.outputItems),h.push({cell:this._cells[a.index].apiCell,outputs:this._cells[a.index].apiCell.outputs})):a.kind===C.NotebookCellsChangeType.ChangeCellLanguage?(this._changeCellLanguage(a.index,a.language),h.push({cell:this._cells[a.index].apiCell,document:this._cells[a.index].apiCell.document})):a.kind===C.NotebookCellsChangeType.ChangeCellContent?h.push({cell:this._cells[a.index].apiCell,document:this._cells[a.index].apiCell.document}):a.kind===C.NotebookCellsChangeType.ChangeCellMime?this._changeCellMime(a.index,a.mime):a.kind===C.NotebookCellsChangeType.ChangeCellMetadata?(this._changeCellMetadata(a.index,a.metadata),h.push({cell:this._cells[a.index].apiCell,metadata:this._cells[a.index].apiCell.metadata})):a.kind===C.NotebookCellsChangeType.ChangeCellInternalMetadata&&(this._changeCellInternalMetadata(a.index,a.internalMetadata),h.push({cell:this._cells[a.index].apiCell,executionSummary:this._cells[a.index].apiCell.executionSummary}));const d=new Map;for(let a=0;a<h.length;a++){const w=h[a],P=d.get(w.cell);if(P===void 0){const l=f.cellChanges.push({document:void 0,executionSummary:void 0,metadata:void 0,outputs:void 0,...w});d.set(w.cell,l-1)}else f.cellChanges[P]={...f.cellChanges[P],...w}}return Object.freeze(f),Object.freeze(f.cellChanges),Object.freeze(f.contentChanges),f}_validateIndex(y){return y=y|0,y<0?0:y>=this._cells.length?this._cells.length-1:y}_validateRange(y){let m=y.start|0,I=y.end|0;return m<0&&(m=0),I>this._cells.length&&(I=this._cells.length),y.with({start:m,end:I})}_getCells(y){y=this._validateRange(y);const m=[];for(let I=y.start;I<y.end;I++)m.push(this._cells[I]);return m}async _save(){return this._disposed?Promise.reject(new Error("Notebook has been closed")):this._proxy.$trySaveNotebook(this.uri)}_spliceNotebookCells(y,m,I){if(this._disposed)return;const f=[],h=[],d=[];if(y.reverse().forEach(a=>{const P=a[2].map(n=>{const u=new E(this,this._textDocumentsAndEditors,n);return m||h.push(E.asModelAddData(this.apiNotebook,n)),u}),l=new T(a[0],a[1],[],P),_=this._cells.splice(a[0],a[1],...P);for(const n of _)d.push(n.uri),l.deletedItems.push(n.apiCell);f.push(l)}),this._textDocumentsAndEditors.acceptDocumentsAndEditorsDelta({addedDocuments:h,removedDocuments:d}),I)for(const a of f)I.push(a.asApiEvent())}_moveCell(y,m,I){const f=this._cells.splice(y,1);this._cells.splice(m,0,...f);const h=[new T(y,1,f.map(d=>d.apiCell),[]),new T(m,0,[],f)];for(const d of h)I.push(d.asApiEvent())}_setCellOutputs(y,m){this._cells[y].setOutputs(m)}_setCellOutputItems(y,m,I,f){this._cells[y].setOutputItems(m,I,f)}_changeCellLanguage(y,m){const I=this._cells[y];I.apiCell.document.languageId!==m&&this._textDocuments.$acceptModelLanguageChanged(I.uri,m)}_changeCellMime(y,m){const I=this._cells[y];I.apiCell.mime=m}_changeCellMetadata(y,m){this._cells[y].setMetadata(m)}_changeCellInternalMetadata(y,m){this._cells[y].setInternalMetadata(m)}getCellFromApiCell(y){return this._cells.find(m=>m.apiCell===y)}getCellFromIndex(y){return this._cells[y]}getCell(y){return this._cells.find(m=>m.handle===y)}getCellIndex(y){return this._cells.indexOf(y)}}e.ExtHostNotebookDocument=A,A._handlePool=0}),define(ye[91],Ce([1,0,6,8,11]),function(ee,e,s,p,b){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.ExtHostNotebookEditor=void 0;class L{constructor(E){this._finalized=!1,this._collectedEdits=[],this._documentVersionId=E}finalize(){return this._finalized=!0,{documentVersionId:this._documentVersionId,cellEdits:this._collectedEdits}}_throwIfFinalized(){if(this._finalized)throw new Error("Edit is only valid while callback runs")}replaceMetadata(E){this._throwIfFinalized(),this._collectedEdits.push({editType:5,metadata:E})}replaceCellMetadata(E,A){this._throwIfFinalized(),this._collectedEdits.push({editType:8,index:E,metadata:A})}replaceCells(E,A,R){this._throwIfFinalized(),!(E===A&&R.length===0)&&this._collectedEdits.push({editType:1,index:E,count:A-E,cells:R.map(p.NotebookCellData.from)})}}class C{constructor(E,A,R,y,m,I){this.id=E,this._proxy=A,this.notebookData=R,this._selections=[],this._visibleRanges=[],this._visible=!1,this._selections=m,this._visibleRanges=y,this._viewColumn=I}get apiEditor(){if(!this._editor){const E=this;this._editor={get document(){return E.notebookData.apiNotebook},get notebook(){return E.notebookData.apiNotebook},get selection(){return E._selections[0]},set selection(A){this.selections=[A]},get selections(){return E._selections},set selections(A){if(!Array.isArray(A)||!A.every(s.NotebookRange.isNotebookRange))throw(0,b.illegalArgument)("selections");E._selections=A,E._trySetSelections(A)},get visibleRanges(){return E._visibleRanges},revealRange(A,R){E._proxy.$tryRevealRange(E.id,p.NotebookRange.from(A),R??s.NotebookEditorRevealType.Default)},get viewColumn(){return E._viewColumn},edit(A){const R=new L(this.document.version);return A(R),E._applyEdit(R.finalize())}},C.apiEditorsToExtHost.set(this._editor,this)}return this._editor}get visible(){return this._visible}_acceptVisibility(E){this._visible=E}_acceptVisibleRanges(E){this._visibleRanges=E}_acceptSelections(E){this._selections=E}_trySetSelections(E){this._proxy.$trySetSelections(this.id,E.map(p.NotebookRange.from))}_acceptViewColumn(E){this._viewColumn=E}_applyEdit(E){if(E.cellEdits.length===0)return Promise.resolve(!0);const A=[];let R=-1;for(let y=0;y<E.cellEdits.length;y++){if(R<0){A.push(E.cellEdits[y]),R++;continue}const I=A[R],f=E.cellEdits[y];if(I.editType===1&&f.editType===1&&I.index===f.index){I.cells.push(...E.cellEdits[y].cells),I.count+=E.cellEdits[y].count;continue}A.push(E.cellEdits[y]),R++}return this._proxy.$tryApplyEdits(this.id,E.documentVersionId,A)}}e.ExtHostNotebookEditor=C,C.apiEditorsToExtHost=new WeakMap}),define(ye[175],Ce([1,0,4,14,8]),function(ee,e,s,p,b){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.ExtHostNotebookEditors=void 0;let L=class{constructor(T,E){this._logService=T,this._notebooksAndEditors=E,this._onDidChangeNotebookEditorSelection=new s.Emitter,this._onDidChangeNotebookEditorVisibleRanges=new s.Emitter,this.onDidChangeNotebookEditorSelection=this._onDidChangeNotebookEditorSelection.event,this.onDidChangeNotebookEditorVisibleRanges=this._onDidChangeNotebookEditorVisibleRanges.event}$acceptEditorPropertiesChanged(T,E){this._logService.debug("ExtHostNotebook#$acceptEditorPropertiesChanged",T,E);const A=this._notebooksAndEditors.getEditorById(T);E.visibleRanges&&A._acceptVisibleRanges(E.visibleRanges.ranges.map(b.NotebookRange.to)),E.selections&&A._acceptSelections(E.selections.selections.map(b.NotebookRange.to)),E.visibleRanges&&this._onDidChangeNotebookEditorVisibleRanges.fire({notebookEditor:A.apiEditor,visibleRanges:A.apiEditor.visibleRanges}),E.selections&&this._onDidChangeNotebookEditorSelection.fire(Object.freeze({notebookEditor:A.apiEditor,selections:A.apiEditor.selections}))}$acceptEditorViewColumns(T){for(const E in T)this._notebooksAndEditors.getEditorById(E)._acceptViewColumn(b.ViewColumn.to(T[E]))}};L=ze([xe(0,p.ILogService)],L),e.ExtHostNotebookEditors=L}),define(ye[176],Ce([1,0,8,150,130,20,54,11]),function(ee,e,s,p,b,L,C,T){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.ExtHostProgress=void 0;class E{constructor(m){this._handles=0,this._mapHandleToCancellationSource=new Map,this._proxy=m}async withProgress(m,I,f){const h=this._handles++,{title:d,location:a,cancellable:w}=I,P={label:(0,b.localize)(0,null,m.displayName||m.name),id:m.identifier.value};return this._proxy.$startProgress(h,{location:s.ProgressLocation.from(a),title:d,source:P,cancellable:w},m.isUnderDevelopment?void 0:m.identifier.value).catch(T.onUnexpectedExternalError),this._withProgress(h,f,!!w)}_withProgress(m,I,f){let h;f&&(h=new L.CancellationTokenSource,this._mapHandleToCancellationSource.set(m,h));const d=w=>{this._proxy.$progressEnd(w),this._mapHandleToCancellationSource.delete(w),h&&h.dispose()};let a;try{a=I(new R(this._proxy,m),f&&h?h.token:L.CancellationToken.None)}catch(w){throw d(m),w}return a.then(w=>d(m),w=>d(m)),a}$acceptProgressCanceled(m){const I=this._mapHandleToCancellationSource.get(m);I&&(I.cancel(),this._mapHandleToCancellationSource.delete(m))}}e.ExtHostProgress=E;function A(y,m){return y.message=m.message,typeof m.increment=="number"&&(typeof y.increment=="number"?y.increment+=m.increment:y.increment=m.increment),y}class R extends p.Progress{constructor(m,I){super(f=>this.throttledReport(f));this._proxy=m,this._handle=I}throttledReport(m){this._proxy.$progressReport(this._handle,m)}}ze([(0,C.throttle)(100,(y,m)=>A(y,m),()=>Object.create(null))],R.prototype,"throttledReport",null)}),define(ye[92],Ce([1,0,48,89,46,65,47,8,2]),function(ee,e,s,p,b,L,C,T,E){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.ExtHostTestItemCollection=e.TestItemRootImpl=e.TestItemImpl=e.toItemFromContext=void 0;const A=(P,l,_,n)=>{let u=l;return{enumerable:!0,configurable:!1,get(){return u},set(i){if(!_(u,i)){const o=u;u=i,P.listener?.(n(i,o))}}}},R=(P,l)=>P===l,y={range:(P,l)=>P===l?!0:!P||!l?!1:P.isEqual(l),label:R,description:R,sortText:R,busy:R,error:R,canResolveChildren:R,tags:(P,l)=>!(P.length!==l.length||P.some(_=>!l.find(n=>_.id===n.id)))},m=P=>l=>({op:4,update:P(l)}),I=(P,l)=>({range:A(P,void 0,y.range,m(_=>({range:s.Range.lift(T.Range.from(_))}))),label:A(P,l,y.label,m(_=>({label:_}))),description:A(P,void 0,y.description,m(_=>({description:_}))),sortText:A(P,void 0,y.sortText,m(_=>({sortText:_}))),canResolveChildren:A(P,!1,y.canResolveChildren,_=>({op:2,state:_})),busy:A(P,!1,y.busy,m(_=>({busy:_}))),error:A(P,void 0,y.error,m(_=>({error:T.MarkdownString.fromStrict(_)||null}))),tags:A(P,[],y.tags,(_,n)=>({op:1,new:_.map(T.TestTag.from),old:n.map(T.TestTag.from)}))}),f=P=>{const l=b.TestId.fromString(P.extId),_=new d(l.controllerId,l.localId,P.label,E.URI.revive(P.uri)||void 0);return _.range=T.Range.to(P.range||void 0),_.description=P.description||void 0,_.sortText=P.sortText||void 0,_.tags=P.tags.map(n=>T.TestTag.to({id:(0,C.denamespaceTestTag)(n).tagId})),_},h=P=>{let l;for(const _ of P.tests){const n=f(_.item);(0,p.getPrivateApiFor)(n).parent=l,l=n}return l};e.toItemFromContext=h;class d{constructor(l,_,n,u){if(_.includes("\0"))throw new Error(`Test IDs may not include the ${JSON.stringify(_)} symbol`);const i=(0,p.createPrivateApiFor)(this,l);Object.defineProperties(this,{id:{value:_,enumerable:!0,writable:!1},uri:{value:u,enumerable:!0,writable:!1},parent:{enumerable:!1,get(){return i.parent instanceof a?void 0:i.parent}},children:{value:(0,L.createTestItemChildren)(i,p.getPrivateApiFor,d),enumerable:!0,writable:!1},...I(i,n)})}}e.TestItemImpl=d;class a extends d{constructor(l,_){super(l,l,_,void 0)}}e.TestItemRootImpl=a;class w extends L.TestItemCollection{constructor(l,_){super({controllerId:l,getApiFor:p.getPrivateApiFor,getChildren:n=>n.children,root:new a(l,_),toITestItem:T.TestItem.from})}}e.ExtHostTestItemCollection=w}),define(ye[93],Ce([1,0,42,11,73,8,6]),function(ee,e,s,p,b,L,C){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.ExtHostTextEditor=e.ExtHostTextEditorOptions=e.TextEditorEdit=e.TextEditorDecorationType=void 0;class T{constructor(m,I,f){const h=T._Keys.nextId();m.$registerTextEditorDecorationType(I.identifier,h,L.DecorationRenderOptions.from(f)),this.value=Object.freeze({key:h,dispose(){m.$removeTextEditorDecorationType(h)}})}}e.TextEditorDecorationType=T,T._Keys=new b.IdGenerator("TextEditorDecorationType");class E{constructor(m,I){this._collectedEdits=[],this._setEndOfLine=void 0,this._finalized=!1,this._document=m,this._documentVersionId=m.version,this._undoStopBefore=I.undoStopBefore,this._undoStopAfter=I.undoStopAfter}finalize(){return this._finalized=!0,{documentVersionId:this._documentVersionId,edits:this._collectedEdits,setEndOfLine:this._setEndOfLine,undoStopBefore:this._undoStopBefore,undoStopAfter:this._undoStopAfter}}_throwIfFinalized(){if(this._finalized)throw new Error("Edit is only valid while callback runs")}replace(m,I){this._throwIfFinalized();let f=null;if(m instanceof C.Position)f=new C.Range(m,m);else if(m instanceof C.Range)f=m;else throw new Error("Unrecognized location");this._pushEdit(f,I,!1)}insert(m,I){this._throwIfFinalized(),this._pushEdit(new C.Range(m,m),I,!0)}delete(m){this._throwIfFinalized();let I=null;if(m instanceof C.Range)I=m;else throw new Error("Unrecognized location");this._pushEdit(I,null,!0)}_pushEdit(m,I,f){const h=this._document.validateRange(m);this._collectedEdits.push({range:h,text:I,forceMoveMarkers:f})}setEndOfLine(m){if(this._throwIfFinalized(),m!==C.EndOfLine.LF&&m!==C.EndOfLine.CRLF)throw(0,p.illegalArgument)("endOfLine");this._setEndOfLine=m}}e.TextEditorEdit=E;class A{constructor(m,I,f,h){this._proxy=m,this._id=I,this._accept(f),this._logService=h;const d=this;this.value={get tabSize(){return d._tabSize},set tabSize(a){d._setTabSize(a)},get insertSpaces(){return d._insertSpaces},set insertSpaces(a){d._setInsertSpaces(a)},get cursorStyle(){return d._cursorStyle},set cursorStyle(a){d._setCursorStyle(a)},get lineNumbers(){return d._lineNumbers},set lineNumbers(a){d._setLineNumbers(a)}}}_accept(m){this._tabSize=m.tabSize,this._insertSpaces=m.insertSpaces,this._cursorStyle=m.cursorStyle,this._lineNumbers=L.TextEditorLineNumbersStyle.to(m.lineNumbers)}_validateTabSize(m){if(m==="auto")return"auto";if(typeof m=="number"){const I=Math.floor(m);return I>0?I:null}if(typeof m=="string"){const I=parseInt(m,10);return isNaN(I)?null:I>0?I:null}return null}_setTabSize(m){const I=this._validateTabSize(m);if(I!==null){if(typeof I=="number"){if(this._tabSize===I)return;this._tabSize=I}this._warnOnError("setTabSize",this._proxy.$trySetOptions(this._id,{tabSize:I}))}}_validateInsertSpaces(m){return m==="auto"?"auto":m==="false"?!1:Boolean(m)}_setInsertSpaces(m){const I=this._validateInsertSpaces(m);if(typeof I=="boolean"){if(this._insertSpaces===I)return;this._insertSpaces=I}this._warnOnError("setInsertSpaces",this._proxy.$trySetOptions(this._id,{insertSpaces:I}))}_setCursorStyle(m){this._cursorStyle!==m&&(this._cursorStyle=m,this._warnOnError("setCursorStyle",this._proxy.$trySetOptions(this._id,{cursorStyle:m})))}_setLineNumbers(m){this._lineNumbers!==m&&(this._lineNumbers=m,this._warnOnError("setLineNumbers",this._proxy.$trySetOptions(this._id,{lineNumbers:L.TextEditorLineNumbersStyle.from(m)})))}assign(m){const I={};let f=!1;if(typeof m.tabSize!="undefined"){const h=this._validateTabSize(m.tabSize);h==="auto"?(f=!0,I.tabSize=h):typeof h=="number"&&this._tabSize!==h&&(this._tabSize=h,f=!0,I.tabSize=h)}if(typeof m.insertSpaces!="undefined"){const h=this._validateInsertSpaces(m.insertSpaces);h==="auto"?(f=!0,I.insertSpaces=h):this._insertSpaces!==h&&(this._insertSpaces=h,f=!0,I.insertSpaces=h)}typeof m.cursorStyle!="undefined"&&this._cursorStyle!==m.cursorStyle&&(this._cursorStyle=m.cursorStyle,f=!0,I.cursorStyle=m.cursorStyle),typeof m.lineNumbers!="undefined"&&this._lineNumbers!==m.lineNumbers&&(this._lineNumbers=m.lineNumbers,f=!0,I.lineNumbers=L.TextEditorLineNumbersStyle.from(m.lineNumbers)),f&&this._warnOnError("setOptions",this._proxy.$trySetOptions(this._id,I))}_warnOnError(m,I){I.catch(f=>{this._logService.warn(`ExtHostTextEditorOptions '${m}' failed:'`),this._logService.warn(f)})}}e.ExtHostTextEditorOptions=A;class R{constructor(m,I,f,h,d,a,w,P){this.id=m,this._proxy=I,this._logService=f,this._disposed=!1,this._hasDecorationsForKey=new Set,this._selections=d,this._options=new A(this._proxy,this.id,a,f),this._visibleRanges=w,this._viewColumn=P;const l=this;this.value=Object.freeze({get document(){return h.getValue()},set document(_){throw(0,p.readonly)("document")},get selection(){return l._selections&&l._selections[0]},set selection(_){if(!(_ instanceof C.Selection))throw(0,p.illegalArgument)("selection");l._selections=[_],l._trySetSelection()},get selections(){return l._selections},set selections(_){if(!Array.isArray(_)||_.some(n=>!(n instanceof C.Selection)))throw(0,p.illegalArgument)("selections");l._selections=_,l._trySetSelection()},get visibleRanges(){return l._visibleRanges},set visibleRanges(_){throw(0,p.readonly)("visibleRanges")},get options(){return l._options.value},set options(_){l._disposed||l._options.assign(_)},get viewColumn(){return l._viewColumn},set viewColumn(_){throw(0,p.readonly)("viewColumn")},edit(_,n={undoStopBefore:!0,undoStopAfter:!0}){if(l._disposed)return Promise.reject(new Error("TextEditor#edit not possible on closed editors"));const u=new E(h.getValue(),n);return _(u),l._applyEdit(u)},insertSnippet(_,n,u={undoStopBefore:!0,undoStopAfter:!0}){if(l._disposed)return Promise.reject(new Error("TextEditor#insertSnippet not possible on closed editors"));let i;if(!n||Array.isArray(n)&&n.length===0)i=l._selections.map(o=>L.Range.from(o));else if(n instanceof C.Position){const{lineNumber:o,column:r}=L.Position.from(n);i=[{startLineNumber:o,startColumn:r,endLineNumber:o,endColumn:r}]}else if(n instanceof C.Range)i=[L.Range.from(n)];else{i=[];for(const o of n)if(o instanceof C.Range)i.push(L.Range.from(o));else{const{lineNumber:r,column:t}=L.Position.from(o);i.push({startLineNumber:r,startColumn:t,endLineNumber:r,endColumn:t})}}return I.$tryInsertSnippet(m,h.getValue().version,_.value,i,u)},setDecorations(_,n){const u=n.length===0;u&&!l._hasDecorationsForKey.has(_.key)||(u?l._hasDecorationsForKey.delete(_.key):l._hasDecorationsForKey.add(_.key),l._runOnProxy(()=>{if(L.isDecorationOptionsArr(n))return I.$trySetDecorations(m,_.key,L.fromRangeOrRangeWithMessage(n));{const i=new Array(4*n.length);for(let o=0,r=n.length;o<r;o++){const t=n[o];i[4*o]=t.start.line+1,i[4*o+1]=t.start.character+1,i[4*o+2]=t.end.line+1,i[4*o+3]=t.end.character+1}return I.$trySetDecorationsFast(m,_.key,i)}}))},revealRange(_,n){l._runOnProxy(()=>I.$tryRevealRange(m,L.Range.from(_),n||C.TextEditorRevealType.Default))},show(_){I.$tryShowEditor(m,L.ViewColumn.from(_))},hide(){I.$tryHideEditor(m)}})}dispose(){(0,s.ok)(!this._disposed),this._disposed=!0}_acceptOptions(m){(0,s.ok)(!this._disposed),this._options._accept(m)}_acceptVisibleRanges(m){(0,s.ok)(!this._disposed),this._visibleRanges=m}_acceptViewColumn(m){(0,s.ok)(!this._disposed),this._viewColumn=m}_acceptSelections(m){(0,s.ok)(!this._disposed),this._selections=m}async _trySetSelection(){const m=this._selections.map(L.Selection.from);return await this._runOnProxy(()=>this._proxy.$trySetSelections(this.id,m)),this.value}_applyEdit(m){const I=m.finalize();if(I.edits.length===0&&!I.setEndOfLine)return Promise.resolve(!0);const f=I.edits.map(d=>d.range);f.sort((d,a)=>d.end.line===a.end.line?d.end.character===a.end.character?d.start.line===a.start.line?d.start.character-a.start.character:d.start.line-a.start.line:d.end.character-a.end.character:d.end.line-a.end.line);for(let d=0,a=f.length-1;d<a;d++){const w=f[d].end;if(f[d+1].start.isBefore(w))return Promise.reject(new Error("Overlapping ranges are not allowed!"))}const h=I.edits.map(d=>({range:L.Range.from(d.range),text:d.text,forceMoveMarkers:d.forceMoveMarkers}));return this._proxy.$tryApplyEdits(this.id,I.documentVersionId,h,{setEndOfLine:typeof I.setEndOfLine=="number"?L.EndOfLine.from(I.setEndOfLine):void 0,undoStopBefore:I.undoStopBefore,undoStopAfter:I.undoStopAfter})}_runOnProxy(m){return this._disposed?(this._logService.warn("TextEditor is closed/disposed"),Promise.resolve(void 0)):m().then(()=>this,I=>(I instanceof Error&&I.name==="DISPOSED"||this._logService.warn(I),null))}}e.ExtHostTextEditor=R}),define(ye[177],Ce([1,0,3,146]),function(ee,e,s,p){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.IWorkbenchEnvironmentService=void 0,e.IWorkbenchEnvironmentService=(0,s.refineServiceDecorator)(p.IEnvironmentService)}),define(ye[178],Ce([1,0,27,4,19]),function(ee,e,s,p,b){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.ExtensionDescriptionRegistry=e.DeltaExtensionsResult=void 0;class L{constructor(y){this.removedDueToLooping=y}}e.DeltaExtensionsResult=L;class C{constructor(y){this._onDidChange=new p.Emitter,this.onDidChange=this._onDidChange.event,this._extensionDescriptions=y,this._initialize()}_initialize(){this._extensionDescriptions.sort(E),this._extensionsMap=new Map,this._extensionsArr=[],this._activationMap=new Map;for(const y of this._extensionDescriptions){if(this._extensionsMap.has(s.ExtensionIdentifier.toKey(y.identifier))){console.error("Extension `"+y.identifier.value+"` is already registered");continue}if(this._extensionsMap.set(s.ExtensionIdentifier.toKey(y.identifier),y),this._extensionsArr.push(y),Array.isArray(y.activationEvents))for(let m of y.activationEvents)m==="onUri"&&(m=`onUri:${s.ExtensionIdentifier.toKey(y.identifier)}`),this._activationMap.has(m)||this._activationMap.set(m,[]),this._activationMap.get(m).push(y)}}set(y){this._extensionDescriptions=y,this._initialize(),this._onDidChange.fire(void 0)}deltaExtensions(y,m){this._extensionDescriptions=A(this._extensionDescriptions,m),this._extensionDescriptions=this._extensionDescriptions.concat(y);const I=C._findLoopingExtensions(this._extensionDescriptions);return this._extensionDescriptions=A(this._extensionDescriptions,I.map(f=>f.identifier)),this._initialize(),this._onDidChange.fire(void 0),new L(I)}static _findLoopingExtensions(y){const m=new class{constructor(){this._arcs=new Map,this._nodesSet=new Set,this._nodesArr=[]}addNode(a){this._nodesSet.has(a)||(this._nodesSet.add(a),this._nodesArr.push(a))}addArc(a,w){this.addNode(a),this.addNode(w),this._arcs.has(a)?this._arcs.get(a).push(w):this._arcs.set(a,[w])}getArcs(a){return this._arcs.has(a)?this._arcs.get(a):[]}hasOnlyGoodArcs(a,w){const P=m.getArcs(a);for(let l=0;l<P.length;l++)if(!w.has(P[l]))return!1;return!0}getNodes(){return this._nodesArr}},I=new Map;for(const a of y){const w=s.ExtensionIdentifier.toKey(a.identifier);if(I.set(w,a),a.extensionDependencies)for(const P of a.extensionDependencies){const l=s.ExtensionIdentifier.toKey(P);m.addArc(w,l)}}const f=new Set;m.getNodes().filter(a=>m.getArcs(a).length===0).forEach(a=>f.add(a));const h=m.getNodes().filter(a=>!f.has(a));let d;do{d=!1;for(let a=0;a<h.length;a++){const w=h[a];m.hasOnlyGoodArcs(w,f)&&(h.splice(a,1),a--,f.add(w),d=!0)}}while(d);return h.map(a=>I.get(a))}containsActivationEvent(y){return this._activationMap.has(y)}containsExtension(y){return this._extensionsMap.has(s.ExtensionIdentifier.toKey(y))}getExtensionDescriptionsForActivationEvent(y){const m=this._activationMap.get(y);return m?m.slice(0):[]}getAllExtensionDescriptions(){return this._extensionsArr.slice(0)}getExtensionDescription(y){const m=this._extensionsMap.get(s.ExtensionIdentifier.toKey(y));return m||void 0}getExtensionDescriptionByUUID(y){for(const m of this._extensionsArr)if(m.uuid===y)return m}getExtensionDescriptionByIdOrUUID(y,m){return this.getExtensionDescription(y)??(m?this.getExtensionDescriptionByUUID(m):void 0)}}e.ExtensionDescriptionRegistry=C;var T;(function(R){R[R.Builtin=0]="Builtin",R[R.User=1]="User",R[R.Dev=2]="Dev"})(T||(T={}));function E(R,y){const m=R.isBuiltin?0:R.isUnderDevelopment?2:1,I=y.isBuiltin?0:y.isUnderDevelopment?2:1;if(m!==I)return m-I;const f=b.posix.basename(R.extensionLocation.path),h=b.posix.basename(y.extensionLocation.path);return f<h?-1:f>h?1:0}function A(R,y){const m=new Set;return y.forEach(I=>m.add(s.ExtensionIdentifier.toKey(I))),R.filter(I=>!m.has(s.ExtensionIdentifier.toKey(I.identifier)))}}),define(ye[94],Ce([1,0,22]),function(ee,e,s){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.NativeLogMarkers=e.isMessageOfType=e.createMessageOfType=e.MessageType=e.ExtensionHostExitCode=e.UIKind=void 0;var p;(function(A){A[A.Desktop=1]="Desktop",A[A.Web=2]="Web"})(p=e.UIKind||(e.UIKind={}));var b;(function(A){A[A.VersionMismatch=55]="VersionMismatch",A[A.UnexpectedError=81]="UnexpectedError"})(b=e.ExtensionHostExitCode||(e.ExtensionHostExitCode={}));var L;(function(A){A[A.Initialized=0]="Initialized",A[A.Ready=1]="Ready",A[A.Terminate=2]="Terminate"})(L=e.MessageType||(e.MessageType={}));function C(A){const R=s.VSBuffer.alloc(1);switch(A){case 0:R.writeUInt8(1,0);break;case 1:R.writeUInt8(2,0);break;case 2:R.writeUInt8(3,0);break}return R}e.createMessageOfType=C;function T(A,R){if(A.byteLength!==1)return!1;switch(A.readUInt8(0)){case 1:return R===0;case 2:return R===1;case 3:return R===2;default:return!1}}e.isMessageOfType=T;var E;(function(A){A.Start="START_NATIVE_LOG",A.End="END_NATIVE_LOG"})(E=e.NativeLogMarkers||(e.NativeLogMarkers={}))}),define(ye[24],Ce([1,0,4,2,3,27,152]),function(ee,e,s,p,b,L,C){"use strict";var T;Object.defineProperty(e,"__esModule",{value:!0}),e.NullExtensionService=e.toExtensionDescription=e.toExtension=e.ActivationKind=e.ExtensionHostLogFileName=e.ExtensionPointContribution=e.ActivationTimes=e.checkProposedApiEnabled=e.isProposedApiEnabled=e.extensionIdentifiersArrayToSet=e.ExtensionIdentifierSet=e.ExtensionHostExtensions=e.extensionHostKindToString=e.ExtensionHostKind=e.MissingExtensionDependency=e.RemoteRunningLocation=e.LocalWebWorkerRunningLocation=e.LocalProcessRunningLocation=e.IExtensionService=e.webWorkerExtHostConfig=e.nullExtensionDescription=void 0,e.nullExtensionDescription=Object.freeze({identifier:new L.ExtensionIdentifier("nullExtensionDescription"),name:"Null Extension Description",version:"0.0.0",publisher:"vscode",engines:{vscode:""},extensionLocation:p.URI.parse("void:location"),isBuiltin:!1,targetPlatform:"undefined",isUserBuiltin:!1,isUnderDevelopment:!1}),e.webWorkerExtHostConfig="extensions.webWorker",e.IExtensionService=(0,b.createDecorator)("extensionService");class E{constructor(t){this.affinity=t,this.kind=1}equals(t){return this.kind===t.kind&&this.affinity===t.affinity}asString(){return this.affinity===0?"LocalProcess":`LocalProcess${this.affinity}`}}e.LocalProcessRunningLocation=E;class A{constructor(){this.kind=2,this.affinity=0}equals(t){return this.kind===t.kind}asString(){return"LocalWebWorker"}}e.LocalWebWorkerRunningLocation=A;class R{constructor(){this.kind=3,this.affinity=0}equals(t){return this.kind===t.kind}asString(){return"Remote"}}e.RemoteRunningLocation=R;class y{constructor(t){this.dependency=t}}e.MissingExtensionDependency=y;var m;(function(r){r[r.LocalProcess=1]="LocalProcess",r[r.LocalWebWorker=2]="LocalWebWorker",r[r.Remote=3]="Remote"})(m=e.ExtensionHostKind||(e.ExtensionHostKind={}));function I(r){if(r===null)return"None";switch(r){case 1:return"LocalProcess";case 2:return"LocalWebWorker";case 3:return"Remote"}}e.extensionHostKindToString=I;class f{constructor(){this._allExtensions=[],this._myExtensions=[]}toDelta(){return{toRemove:[],toAdd:this._allExtensions,myToRemove:[],myToAdd:this._myExtensions}}set(t,c){const v=[],g=[],D=[],U=[],W=a(this._allExtensions),M=a(t),S=(K,V)=>K.extensionLocation.toString()===V.extensionLocation.toString()||K.isBuiltin===V.isBuiltin||K.isUserBuiltin===V.isUserBuiltin||K.isUnderDevelopment===V.isUnderDevelopment;for(const K of this._allExtensions){const V=M.get(L.ExtensionIdentifier.toKey(K.identifier));if(!V){v.push(K.identifier),W.delete(L.ExtensionIdentifier.toKey(K.identifier));continue}if(!S(K,V)){v.push(K.identifier),W.delete(L.ExtensionIdentifier.toKey(K.identifier));continue}}for(const K of t){const V=W.get(L.ExtensionIdentifier.toKey(K.identifier));if(!V){g.push(K);continue}if(!S(V,K)){v.push(V.identifier),W.delete(L.ExtensionIdentifier.toKey(V.identifier));continue}}const z=d(this._myExtensions),$=d(c);for(const K of this._myExtensions)$.has(L.ExtensionIdentifier.toKey(K))||D.push(K);for(const K of c)z.has(L.ExtensionIdentifier.toKey(K))||U.push(K);const N={toRemove:v,toAdd:g,myToRemove:D,myToAdd:U};return this.delta(N),N}delta(t){const{toRemove:c,toAdd:v,myToRemove:g,myToAdd:D}=t,U=d(c),W=d(g);for(let M=0;M<this._allExtensions.length;M++)U.has(L.ExtensionIdentifier.toKey(this._allExtensions[M].identifier))&&(this._allExtensions.splice(M,1),M--);for(let M=0;M<this._myExtensions.length;M++)W.has(L.ExtensionIdentifier.toKey(this._myExtensions[M]))&&(this._myExtensions.splice(M,1),M--);for(const M of v)this._allExtensions.push(M);for(const M of D)this._myExtensions.push(M)}containsExtension(t){for(const c of this._myExtensions)if(L.ExtensionIdentifier.equals(c,t))return!0;return!1}}e.ExtensionHostExtensions=f;class h{constructor(t){if(this[T]="ExtensionIdentifierSet",this._map=new Map,this._toKey=L.ExtensionIdentifier.toKey,t)for(const c of t)this.add(c)}get size(){return this._map.size}add(t){return this._map.set(this._toKey(t),t),this}clear(){this._map.clear()}delete(t){return this._map.delete(this._toKey(t))}has(t){return this._map.has(this._toKey(t))}forEach(t,c){this._map.forEach(v=>t.call(c,v,v,this))}*entries(){for(const[t,c]of this._map)yield[c,c]}keys(){return this._map.values()}values(){return this._map.values()}[(T=Symbol.toStringTag,Symbol.iterator)](){return this._map.values()}}e.ExtensionIdentifierSet=h;function d(r){const t=new Set;for(const c of r)t.add(L.ExtensionIdentifier.toKey(c));return t}e.extensionIdentifiersArrayToSet=d;function a(r){const t=new Map;for(const c of r)t.set(L.ExtensionIdentifier.toKey(c.identifier),c);return t}function w(r,t){return!0}e.isProposedApiEnabled=w;function P(r,t){if(!w(r,t))throw new Error(`Extension '${r.identifier.value}' CANNOT use API proposal: ${t}.
Its package.json#enabledApiProposals-property declares: ${r.enabledApiProposals?.join(", ")??"[]"} but NOT ${t}.
The missing proposal MUST be added and you must start in extension development mode or use the following command line switch: --enable-proposed-api ${r.identifier.value}`)}e.checkProposedApiEnabled=P;class l{constructor(t,c,v,g){this.codeLoadingTime=t,this.activateCallTime=c,this.activateResolvedTime=v,this.activationReason=g}}e.ActivationTimes=l;class _{constructor(t,c){this.description=t,this.value=c}}e.ExtensionPointContribution=_,e.ExtensionHostLogFileName="exthost";var n;(function(r){r[r.Normal=0]="Normal",r[r.Immediate=1]="Immediate"})(n=e.ActivationKind||(e.ActivationKind={}));function u(r){return{type:r.isBuiltin?0:1,isBuiltin:r.isBuiltin||r.isUserBuiltin,identifier:{id:(0,C.getGalleryExtensionId)(r.publisher,r.name),uuid:r.uuid},manifest:r,location:r.extensionLocation,targetPlatform:r.targetPlatform,validations:[],isValid:!0}}e.toExtension=u;function i(r,t){return{identifier:new L.ExtensionIdentifier((0,C.getExtensionId)(r.manifest.publisher,r.manifest.name)),isBuiltin:r.type===0,isUserBuiltin:r.type===1&&r.isBuiltin,isUnderDevelopment:!!t,extensionLocation:r.location,...r.manifest,uuid:r.identifier.uuid,targetPlatform:r.targetPlatform}}e.toExtensionDescription=i;class o{constructor(){this.onDidRegisterExtensions=s.Event.None,this.onDidChangeExtensionsStatus=s.Event.None,this.onDidChangeExtensions=s.Event.None,this.onWillActivateByEvent=s.Event.None,this.onDidChangeResponsiveChange=s.Event.None}activateByEvent(t){return Promise.resolve(void 0)}activationEventIsDone(t){return!1}whenInstalledExtensionsRegistered(){return Promise.resolve(!0)}getExtensions(){return Promise.resolve([])}getExtension(){return Promise.resolve(void 0)}readExtensionPointContributions(t){return Promise.resolve(Object.create(null))}getExtensionsStatus(){return Object.create(null)}getInspectPort(t,c){return Promise.resolve(0)}getInspectPorts(t,c){return Promise.resolve([])}stopExtensionHosts(){}async restartExtensionHost(){}async startExtensionHosts(){}async setRemoteEnvironment(t){}canAddExtension(){return!1}canRemoveExtension(){return!1}_activateById(t,c){return Promise.resolve()}}e.NullExtensionService=o}),define(ye[179],Ce([1,0,11,27,24,14,13]),function(ee,e,s,p,b,L,C){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.ExtensionsActivator=e.FailedExtension=e.HostExtension=e.EmptyExtension=e.ActivatedExtension=e.ExtensionActivationTimesBuilder=e.ExtensionActivationTimes=void 0;class T{constructor(d,a,w,P){this.startup=d,this.codeLoadingTime=a,this.activateCallTime=w,this.activateResolvedTime=P}}e.ExtensionActivationTimes=T,T.NONE=new T(!1,-1,-1,-1);class E{constructor(d){this._startup=d,this._codeLoadingStart=-1,this._codeLoadingStop=-1,this._activateCallStart=-1,this._activateCallStop=-1,this._activateResolveStart=-1,this._activateResolveStop=-1}_delta(d,a){return d===-1||a===-1?-1:a-d}build(){return new T(this._startup,this._delta(this._codeLoadingStart,this._codeLoadingStop),this._delta(this._activateCallStart,this._activateCallStop),this._delta(this._activateResolveStart,this._activateResolveStop))}codeLoadingStart(){this._codeLoadingStart=Date.now()}codeLoadingStop(){this._codeLoadingStop=Date.now()}activateCallStart(){this._activateCallStart=Date.now()}activateCallStop(){this._activateCallStop=Date.now()}activateResolveStart(){this._activateResolveStart=Date.now()}activateResolveStop(){this._activateResolveStop=Date.now()}}e.ExtensionActivationTimesBuilder=E;class A{constructor(d,a,w,P,l,_){this.activationFailed=d,this.activationFailedError=a,this.activationTimes=w,this.module=P,this.exports=l,this.subscriptions=_}}e.ActivatedExtension=A;class R extends A{constructor(d){super(!1,null,d,{activate:void 0,deactivate:void 0},void 0,[])}}e.EmptyExtension=R;class y extends A{constructor(){super(!1,null,T.NONE,{activate:void 0,deactivate:void 0},void 0,[])}}e.HostExtension=y;class m extends A{constructor(d){super(!0,d,T.NONE,{activate:void 0,deactivate:void 0},void 0,[])}}e.FailedExtension=m;let I=class{constructor(d,a,w,P,l){this._logService=l,this._registry=d,this._resolvedExtensionsSet=new Set,a.forEach(_=>this._resolvedExtensionsSet.add(p.ExtensionIdentifier.toKey(_))),this._externalExtensionsMap=new Map,w.forEach(_=>this._externalExtensionsMap.set(p.ExtensionIdentifier.toKey(_),_)),this._host=P,this._operations=new Map,this._alreadyActivatedEvents=Object.create(null)}dispose(){for(const[d,a]of this._operations)a.dispose()}isActivated(d){const a=this._operations.get(p.ExtensionIdentifier.toKey(d));return Boolean(a&&a.value)}getActivatedExtension(d){const a=this._operations.get(p.ExtensionIdentifier.toKey(d));if(!a||!a.value)throw new Error(`Extension '${d.value}' is not known or not activated`);return a.value}async activateByEvent(d,a){if(this._alreadyActivatedEvents[d])return;const w=this._registry.getExtensionDescriptionsForActivationEvent(d);await this._activateExtensions(w.map(P=>({id:P.identifier,reason:{startup:a,extensionId:P.identifier,activationEvent:d}}))),this._alreadyActivatedEvents[d]=!0}activateById(d,a){const w=this._registry.getExtensionDescription(d);if(!w)throw new Error(`Extension '${d}' is not known`);return this._activateExtensions([{id:w.identifier,reason:a}])}async _activateExtensions(d){const a=d.filter(w=>!this.isActivated(w.id)).map(w=>this._handleActivationRequest(w));await Promise.all(a.map(w=>w.wait()))}_handleActivationRequest(d){if(this._operations.has(p.ExtensionIdentifier.toKey(d.id)))return this._operations.get(p.ExtensionIdentifier.toKey(d.id));if(this._externalExtensionsMap.has(p.ExtensionIdentifier.toKey(d.id)))return this._createAndSaveOperation(d,null,[],null);const a=this._registry.getExtensionDescription(d.id);if(!a){const l=new Error(`Cannot activate unknown extension '${d.id.value}'`),_=this._createAndSaveOperation(d,null,[],new m(l));return this._host.onExtensionActivationError(d.id,l,new b.MissingExtensionDependency(d.id.value)),_}const w=[],P=typeof a.extensionDependencies=="undefined"?[]:a.extensionDependencies;for(const l of P){if(this._resolvedExtensionsSet.has(p.ExtensionIdentifier.toKey(l)))continue;const _=this._operations.get(p.ExtensionIdentifier.toKey(l));if(_){w.push(_);continue}if(this._externalExtensionsMap.has(p.ExtensionIdentifier.toKey(l))){w.push(this._handleActivationRequest({id:this._externalExtensionsMap.get(p.ExtensionIdentifier.toKey(l)),reason:d.reason}));continue}const n=this._registry.getExtensionDescription(l);if(n){if(!n.main&&!n.browser)continue;w.push(this._handleActivationRequest({id:n.identifier,reason:d.reason}));continue}const u=a.displayName||a.identifier.value,i=new Error(`Cannot activate the '${u}' extension because it depends on unknown extension '${l}'`),o=this._createAndSaveOperation(d,a.displayName,[],new m(i));return this._host.onExtensionActivationError(a.identifier,i,new b.MissingExtensionDependency(l)),o}return this._createAndSaveOperation(d,a.displayName,w,null)}_createAndSaveOperation(d,a,w,P){const l=new f(d.id,a,d.reason,w,P,this._host,this._logService);return this._operations.set(p.ExtensionIdentifier.toKey(d.id),l),l}};I=ze([xe(4,L.ILogService)],I),e.ExtensionsActivator=I;let f=class{constructor(d,a,w,P,l,_,n){this._id=d,this._displayName=a,this._reason=w,this._deps=P,this._value=l,this._host=_,this._logService=n,this._barrier=new C.Barrier,this._isDisposed=!1,this._initialize()}get value(){return this._value}get friendlyName(){return this._displayName||this._id.value}dispose(){this._isDisposed=!0}wait(){return this._barrier.wait()}async _initialize(){await this._waitForDepsThenActivate(),this._barrier.open()}async _waitForDepsThenActivate(){if(!this._value){for(;this._deps.length>0;){for(let d=0;d<this._deps.length;d++){const a=this._deps[d];if(a.value&&!a.value.activationFailed){this._deps.splice(d,1),d--;continue}if(a.value&&a.value.activationFailed){const w=new Error(`Cannot activate the '${this.friendlyName}' extension because its dependency '${a.friendlyName}' failed to activate`);w.detail=a.value.activationFailedError,this._value=new m(w),this._host.onExtensionActivationError(this._id,w,null);return}}this._deps.length>0&&await Promise.race(this._deps.map(d=>d.wait()))}await this._activate()}}async _activate(){try{this._value=await this._host.actualActivateExtension(this._id,this._reason)}catch(d){const a=new Error;if(d&&d.name&&(a.name=d.name),d&&d.message?a.message=`Activating extension '${this._id.value}' failed: ${d.message}.`:a.message=`Activating extension '${this._id.value}' failed: ${d}.`,d&&d.stack&&(a.stack=d.stack),this._value=new m(a),this._isDisposed&&s.isCancellationError(d))return;this._host.onExtensionActivationError(this._id,a,null),this._logService.error(`Activating extension ${this._id.value} failed due to an error:`),this._logService.error(d)}}};f=ze([xe(6,L.ILogService)],f)}),define(ye[180],Ce([1,0,14,28,24]),function(ee,e,s,p,b){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.ExtHostLogService=void 0;let L=class extends s.LogService{constructor(T,E){super(T.createLogger(E.logFile,{name:b.ExtensionHostLogFileName}))}};L=ze([xe(0,s.ILoggerService),xe(1,p.IExtHostInitDataService)],L),e.ExtHostLogService=L}),define(ye[181],Ce([1,0]),function(ee,e){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.allApiProposals=void 0,e.allApiProposals=Object.freeze({authSession:"https://raw.githubusercontent.com/microsoft/vscode/main/src/vscode-dts/vscode.proposed.authSession.d.ts",badges:"https://raw.githubusercontent.com/microsoft/vscode/main/src/vscode-dts/vscode.proposed.badges.d.ts",commentsResolvedState:"https://raw.githubusercontent.com/microsoft/vscode/main/src/vscode-dts/vscode.proposed.commentsResolvedState.d.ts",contribEditSessions:"https://raw.githubusercontent.com/microsoft/vscode/main/src/vscode-dts/vscode.proposed.contribEditSessions.d.ts",contribLabelFormatterWorkspaceTooltip:"https://raw.githubusercontent.com/microsoft/vscode/main/src/vscode-dts/vscode.proposed.contribLabelFormatterWorkspaceTooltip.d.ts",contribMenuBarHome:"https://raw.githubusercontent.com/microsoft/vscode/main/src/vscode-dts/vscode.proposed.contribMenuBarHome.d.ts",contribMergeEditorToolbar:"https://raw.githubusercontent.com/microsoft/vscode/main/src/vscode-dts/vscode.proposed.contribMergeEditorToolbar.d.ts",contribRemoteHelp:"https://raw.githubusercontent.com/microsoft/vscode/main/src/vscode-dts/vscode.proposed.contribRemoteHelp.d.ts",contribShareMenu:"https://raw.githubusercontent.com/microsoft/vscode/main/src/vscode-dts/vscode.proposed.contribShareMenu.d.ts",contribViewSize:"https://raw.githubusercontent.com/microsoft/vscode/main/src/vscode-dts/vscode.proposed.contribViewSize.d.ts",contribViewsRemote:"https://raw.githubusercontent.com/microsoft/vscode/main/src/vscode-dts/vscode.proposed.contribViewsRemote.d.ts",contribViewsWelcome:"https://raw.githubusercontent.com/microsoft/vscode/main/src/vscode-dts/vscode.proposed.contribViewsWelcome.d.ts",contribWebviewContext:"https://raw.githubusercontent.com/microsoft/vscode/main/src/vscode-dts/vscode.proposed.contribWebviewContext.d.ts",customEditorMove:"https://raw.githubusercontent.com/microsoft/vscode/main/src/vscode-dts/vscode.proposed.customEditorMove.d.ts",diffCommand:"https://raw.githubusercontent.com/microsoft/vscode/main/src/vscode-dts/vscode.proposed.diffCommand.d.ts",documentFiltersExclusive:"https://raw.githubusercontent.com/microsoft/vscode/main/src/vscode-dts/vscode.proposed.documentFiltersExclusive.d.ts",documentPaste:"https://raw.githubusercontent.com/microsoft/vscode/main/src/vscode-dts/vscode.proposed.documentPaste.d.ts",editorInsets:"https://raw.githubusercontent.com/microsoft/vscode/main/src/vscode-dts/vscode.proposed.editorInsets.d.ts",extensionRuntime:"https://raw.githubusercontent.com/microsoft/vscode/main/src/vscode-dts/vscode.proposed.extensionRuntime.d.ts",extensionsAny:"https://raw.githubusercontent.com/microsoft/vscode/main/src/vscode-dts/vscode.proposed.extensionsAny.d.ts",externalUriOpener:"https://raw.githubusercontent.com/microsoft/vscode/main/src/vscode-dts/vscode.proposed.externalUriOpener.d.ts",fileSearchProvider:"https://raw.githubusercontent.com/microsoft/vscode/main/src/vscode-dts/vscode.proposed.fileSearchProvider.d.ts",findTextInFiles:"https://raw.githubusercontent.com/microsoft/vscode/main/src/vscode-dts/vscode.proposed.findTextInFiles.d.ts",fsChunks:"https://raw.githubusercontent.com/microsoft/vscode/main/src/vscode-dts/vscode.proposed.fsChunks.d.ts",idToken:"https://raw.githubusercontent.com/microsoft/vscode/main/src/vscode-dts/vscode.proposed.idToken.d.ts",inlineCompletionsAdditions:"https://raw.githubusercontent.com/microsoft/vscode/main/src/vscode-dts/vscode.proposed.inlineCompletionsAdditions.d.ts",inlineCompletionsNew:"https://raw.githubusercontent.com/microsoft/vscode/main/src/vscode-dts/vscode.proposed.inlineCompletionsNew.d.ts",interactiveWindow:"https://raw.githubusercontent.com/microsoft/vscode/main/src/vscode-dts/vscode.proposed.interactiveWindow.d.ts",ipc:"https://raw.githubusercontent.com/microsoft/vscode/main/src/vscode-dts/vscode.proposed.ipc.d.ts",notebookCellExecutionState:"https://raw.githubusercontent.com/microsoft/vscode/main/src/vscode-dts/vscode.proposed.notebookCellExecutionState.d.ts",notebookContentProvider:"https://raw.githubusercontent.com/microsoft/vscode/main/src/vscode-dts/vscode.proposed.notebookContentProvider.d.ts",notebookControllerKind:"https://raw.githubusercontent.com/microsoft/vscode/main/src/vscode-dts/vscode.proposed.notebookControllerKind.d.ts",notebookDebugOptions:"https://raw.githubusercontent.com/microsoft/vscode/main/src/vscode-dts/vscode.proposed.notebookDebugOptions.d.ts",notebookDeprecated:"https://raw.githubusercontent.com/microsoft/vscode/main/src/vscode-dts/vscode.proposed.notebookDeprecated.d.ts",notebookEditor:"https://raw.githubusercontent.com/microsoft/vscode/main/src/vscode-dts/vscode.proposed.notebookEditor.d.ts",notebookEditorEdit:"https://raw.githubusercontent.com/microsoft/vscode/main/src/vscode-dts/vscode.proposed.notebookEditorEdit.d.ts",notebookKernelSource:"https://raw.githubusercontent.com/microsoft/vscode/main/src/vscode-dts/vscode.proposed.notebookKernelSource.d.ts",notebookLiveShare:"https://raw.githubusercontent.com/microsoft/vscode/main/src/vscode-dts/vscode.proposed.notebookLiveShare.d.ts",notebookMessaging:"https://raw.githubusercontent.com/microsoft/vscode/main/src/vscode-dts/vscode.proposed.notebookMessaging.d.ts",notebookMime:"https://raw.githubusercontent.com/microsoft/vscode/main/src/vscode-dts/vscode.proposed.notebookMime.d.ts",notebookWorkspaceEdit:"https://raw.githubusercontent.com/microsoft/vscode/main/src/vscode-dts/vscode.proposed.notebookWorkspaceEdit.d.ts",portsAttributes:"https://raw.githubusercontent.com/microsoft/vscode/main/src/vscode-dts/vscode.proposed.portsAttributes.d.ts",quickPickSortByLabel:"https://raw.githubusercontent.com/microsoft/vscode/main/src/vscode-dts/vscode.proposed.quickPickSortByLabel.d.ts",resolvers:"https://raw.githubusercontent.com/microsoft/vscode/main/src/vscode-dts/vscode.proposed.resolvers.d.ts",scmActionButton:"https://raw.githubusercontent.com/microsoft/vscode/main/src/vscode-dts/vscode.proposed.scmActionButton.d.ts",scmSelectedProvider:"https://raw.githubusercontent.com/microsoft/vscode/main/src/vscode-dts/vscode.proposed.scmSelectedProvider.d.ts",scmValidation:"https://raw.githubusercontent.com/microsoft/vscode/main/src/vscode-dts/vscode.proposed.scmValidation.d.ts",snippetWorkspaceEdit:"https://raw.githubusercontent.com/microsoft/vscode/main/src/vscode-dts/vscode.proposed.snippetWorkspaceEdit.d.ts",tabInputTextMerge:"https://raw.githubusercontent.com/microsoft/vscode/main/src/vscode-dts/vscode.proposed.tabInputTextMerge.d.ts",taskPresentationGroup:"https://raw.githubusercontent.com/microsoft/vscode/main/src/vscode-dts/vscode.proposed.taskPresentationGroup.d.ts",telemetry:"https://raw.githubusercontent.com/microsoft/vscode/main/src/vscode-dts/vscode.proposed.telemetry.d.ts",terminalDataWriteEvent:"https://raw.githubusercontent.com/microsoft/vscode/main/src/vscode-dts/vscode.proposed.terminalDataWriteEvent.d.ts",terminalDimensions:"https://raw.githubusercontent.com/microsoft/vscode/main/src/vscode-dts/vscode.proposed.terminalDimensions.d.ts",terminalExitReason:"https://raw.githubusercontent.com/microsoft/vscode/main/src/vscode-dts/vscode.proposed.terminalExitReason.d.ts",testCoverage:"https://raw.githubusercontent.com/microsoft/vscode/main/src/vscode-dts/vscode.proposed.testCoverage.d.ts",testObserver:"https://raw.githubusercontent.com/microsoft/vscode/main/src/vscode-dts/vscode.proposed.testObserver.d.ts",textSearchProvider:"https://raw.githubusercontent.com/microsoft/vscode/main/src/vscode-dts/vscode.proposed.textSearchProvider.d.ts",timeline:"https://raw.githubusercontent.com/microsoft/vscode/main/src/vscode-dts/vscode.proposed.timeline.d.ts",tokenInformation:"https://raw.githubusercontent.com/microsoft/vscode/main/src/vscode-dts/vscode.proposed.tokenInformation.d.ts",treeViewReveal:"https://raw.githubusercontent.com/microsoft/vscode/main/src/vscode-dts/vscode.proposed.treeViewReveal.d.ts",workspaceTrust:"https://raw.githubusercontent.com/microsoft/vscode/main/src/vscode-dts/vscode.proposed.workspaceTrust.d.ts"})}),define(ye[182],Ce([1,0,141,11,29,79,82,30,27,181,149]),function(ee,e,s,p,b,L,C,T,E,A,R){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.ExtensionsRegistry=e.ExtensionsRegistryImpl=e.schema=e.ExtensionPoint=e.ExtensionPointUserDelta=e.ExtensionMessageCollector=void 0;const y=T.Registry.as(C.Extensions.JSONContribution);class m{constructor(l,_,n){this._messageHandler=l,this._extension=_,this._extensionPointId=n}_msg(l,_){this._messageHandler({type:l,message:_,extensionId:this._extension.identifier,extensionPointId:this._extensionPointId})}error(l){this._msg(b.default.Error,l)}warn(l){this._msg(b.default.Warning,l)}info(l){this._msg(b.default.Info,l)}}e.ExtensionMessageCollector=m;class I{constructor(l,_){this.added=l,this.removed=_}static _toSet(l){const _=new Set;for(let n=0,u=l.length;n<u;n++)_.add(E.ExtensionIdentifier.toKey(l[n].description.identifier));return _}static compute(l,_){if(!l||!l.length)return new I(_,[]);if(!_||!_.length)return new I([],l);const n=this._toSet(l),u=this._toSet(_),i=_.filter(r=>!n.has(E.ExtensionIdentifier.toKey(r.description.identifier))),o=l.filter(r=>!u.has(E.ExtensionIdentifier.toKey(r.description.identifier)));return new I(i,o)}}e.ExtensionPointUserDelta=I;class f{constructor(l,_){this.name=l,this.defaultExtensionKind=_,this._handler=null,this._users=null,this._delta=null}setHandler(l){if(this._handler!==null)throw new Error("Handler already set!");this._handler=l,this._handle()}acceptUsers(l){this._delta=I.compute(this._users,l),this._users=l,this._handle()}_handle(){if(!(this._handler===null||this._users===null||this._delta===null))try{this._handler(this._users,this._delta)}catch(l){(0,p.onUnexpectedError)(l)}}}e.ExtensionPoint=f;const h={type:"string",enum:["ui","workspace"],enumDescriptions:[s.localize(0,null),s.localize(1,null)]},d="vscode://schemas/vscode-extensions";e.schema={properties:{engines:{type:"object",description:s.localize(2,null),properties:{vscode:{type:"string",description:s.localize(3,null),default:"^1.22.0"}}},publisher:{description:s.localize(4,null),type:"string"},displayName:{description:s.localize(5,null),type:"string"},categories:{description:s.localize(6,null),type:"array",uniqueItems:!0,items:{oneOf:[{type:"string",enum:E.EXTENSION_CATEGORIES},{type:"string",const:"Languages",deprecationMessage:s.localize(7,null)}]}},galleryBanner:{type:"object",description:s.localize(8,null),properties:{color:{description:s.localize(9,null),type:"string"},theme:{description:s.localize(10,null),type:"string",enum:["dark","light"]}}},contributes:{description:s.localize(11,null),type:"object",properties:{},default:{}},preview:{type:"boolean",description:s.localize(12,null)},enableProposedApi:{type:"boolean",deprecationMessage:s.localize(13,null)},enabledApiProposals:{markdownDescription:s.localize(14,null),type:"array",uniqueItems:!0,items:{type:"string",enum:Object.keys(A.allApiProposals),markdownEnumDescriptions:Object.values(A.allApiProposals)}},activationEvents:{description:s.localize(15,null),type:"array",items:{type:"string",defaultSnippets:[{label:"onWebviewPanel",description:s.localize(16,null),body:"onWebviewPanel:viewType"},{label:"onLanguage",description:s.localize(17,null),body:"onLanguage:${1:languageId}"},{label:"onCommand",description:s.localize(18,null),body:"onCommand:${2:commandId}"},{label:"onDebug",description:s.localize(19,null),body:"onDebug"},{label:"onDebugInitialConfigurations",description:s.localize(20,null),body:"onDebugInitialConfigurations"},{label:"onDebugDynamicConfigurations",description:s.localize(21,null),body:"onDebugDynamicConfigurations"},{label:"onDebugResolve",description:s.localize(22,null),body:"onDebugResolve:${6:type}"},{label:"onDebugAdapterProtocolTracker",description:s.localize(23,null),body:"onDebugAdapterProtocolTracker:${6:type}"},{label:"workspaceContains",description:s.localize(24,null),body:"workspaceContains:${4:filePattern}"},{label:"onStartupFinished",description:s.localize(25,null),body:"onStartupFinished"},{label:"onTaskType",description:s.localize(26,null),body:"onTaskType:${1:taskType}"},{label:"onFileSystem",description:s.localize(27,null),body:"onFileSystem:${1:scheme}"},{label:"onSearch",description:s.localize(28,null),body:"onSearch:${7:scheme}"},{label:"onView",body:"onView:${5:viewId}",description:s.localize(29,null)},{label:"onIdentity",body:"onIdentity:${8:identity}",description:s.localize(30,null)},{label:"onUri",body:"onUri",description:s.localize(31,null)},{label:"onOpenExternalUri",body:"onOpenExternalUri",description:s.localize(32,null)},{label:"onCustomEditor",body:"onCustomEditor:${9:viewType}",description:s.localize(33,null)},{label:"onNotebook",body:"onNotebook:${1:type}",description:s.localize(34,null)},{label:"onAuthenticationRequest",body:"onAuthenticationRequest:${11:authenticationProviderId}",description:s.localize(35,null)},{label:"onRenderer",description:s.localize(36,null),body:"onRenderer:${11:rendererId}"},{label:"onTerminalProfile",body:"onTerminalProfile:${1:terminalId}",description:s.localize(37,null)},{label:"onWalkthrough",body:"onWalkthrough:${1:walkthroughID}",description:s.localize(38,null)},{label:"*",description:s.localize(39,null),body:"*"}]}},badges:{type:"array",description:s.localize(40,null),items:{type:"object",required:["url","href","description"],properties:{url:{type:"string",description:s.localize(41,null)},href:{type:"string",description:s.localize(42,null)},description:{type:"string",description:s.localize(43,null)}}}},markdown:{type:"string",description:s.localize(44,null),enum:["github","standard"],default:"github"},qna:{default:"marketplace",description:s.localize(45,null),anyOf:[{type:["string","boolean"],enum:["marketplace",!1]},{type:"string"}]},extensionDependencies:{description:s.localize(46,null),type:"array",uniqueItems:!0,items:{type:"string",pattern:L.EXTENSION_IDENTIFIER_PATTERN}},extensionPack:{description:s.localize(47,null),type:"array",uniqueItems:!0,items:{type:"string",pattern:L.EXTENSION_IDENTIFIER_PATTERN}},extensionKind:{description:s.localize(48,null),type:"array",items:h,default:["workspace"],defaultSnippets:[{body:["ui"],description:s.localize(49,null)},{body:["workspace"],description:s.localize(50,null)},{body:["ui","workspace"],description:s.localize(51,null)},{body:["workspace","ui"],description:s.localize(52,null)},{body:[],description:s.localize(53,null)}]},capabilities:{description:s.localize(54,null),type:"object",properties:{virtualWorkspaces:{description:s.localize(55,null),type:["boolean","object"],defaultSnippets:[{label:"limited",body:{supported:"${1:limited}",description:"${2}"}},{label:"false",body:{supported:!1,description:"${2}"}}],default:(!0).valueOf,properties:{supported:{markdownDescription:s.localize(56,null),type:["string","boolean"],enum:["limited",!0,!1],enumDescriptions:[s.localize(57,null),s.localize(58,null),s.localize(59,null)]},description:{type:"string",markdownDescription:s.localize(60,null)}}},untrustedWorkspaces:{description:s.localize(61,null),type:"object",required:["supported"],defaultSnippets:[{body:{supported:"${1:limited}",description:"${2}"}}],properties:{supported:{markdownDescription:s.localize(62,null),type:["string","boolean"],enum:["limited",!0,!1],enumDescriptions:[s.localize(63,null),s.localize(64,null),s.localize(65,null)]},restrictedConfigurations:{description:s.localize(66,null),type:"array",items:{type:"string"}},description:{type:"string",markdownDescription:s.localize(67,null)}}}}},sponsor:{description:s.localize(68,null),type:"object",defaultSnippets:[{body:{url:"${1:https:}"}}],properties:{url:{description:s.localize(69,null),type:"string"}}},scripts:{type:"object",properties:{"vscode:prepublish":{description:s.localize(70,null),type:"string"},"vscode:uninstall":{description:s.localize(71,null),type:"string"}}},icon:{type:"string",description:s.localize(72,null)}}};class a{constructor(){this._extensionPoints=new Map}registerExtensionPoint(l){if(this._extensionPoints.has(l.extensionPoint))throw new Error("Duplicate extension point: "+l.extensionPoint);const _=new f(l.extensionPoint,l.defaultExtensionKind);return this._extensionPoints.set(l.extensionPoint,_),e.schema.properties.contributes.properties[l.extensionPoint]=l.jsonSchema,y.registerSchema(d,e.schema),_}getExtensionPoints(){return Array.from(this._extensionPoints.values())}}e.ExtensionsRegistryImpl=a;const w={ExtensionsRegistry:"ExtensionsRegistry"};T.Registry.add(w.ExtensionsRegistry,new a),e.ExtensionsRegistry=T.Registry.as(w.ExtensionsRegistry),y.registerSchema(d,e.schema),y.registerSchema(R.productSchemaId,{properties:{extensionEnabledApiProposals:{description:s.localize(73,null),type:"object",properties:{},additionalProperties:{anyOf:[{type:"array",uniqueItems:!0,items:{type:"string",enum:Object.keys(A.allApiProposals),markdownEnumDescriptions:Object.values(A.allApiProposals)}}]}}}})}),define(ye[183],Ce([1,0,138,10,26,182,38,4]),function(ee,e,s,p,b,L,C,T){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.TaskDefinitionRegistry=e.TaskDefinitionRegistryImpl=void 0;const E={type:"object",additionalProperties:!1,properties:{type:{type:"string",description:s.localize(0,null)},required:{type:"array",items:{type:"string"}},properties:{type:"object",description:s.localize(1,null),additionalProperties:{$ref:"http://json-schema.org/draft-07/schema#"}},when:{type:"string",markdownDescription:s.localize(2,null),default:""}}};var A;(function(m){function I(f,h,d){if(!f)return;const a=p.isString(f.type)?f.type:void 0;if(!a||a.length===0){d.error(s.localize(3,null));return}const w=[];if(Array.isArray(f.required))for(const P of f.required)p.isString(P)&&w.push(P);return{extensionId:h.value,taskType:a,required:w,properties:f.properties?b.deepClone(f.properties):{},when:f.when?C.ContextKeyExpr.deserialize(f.when):void 0}}m.from=I})(A||(A={}));const R=L.ExtensionsRegistry.registerExtensionPoint({extensionPoint:"taskDefinitions",jsonSchema:{description:s.localize(4,null),type:"array",items:E}});class y{constructor(){this._onDefinitionsChanged=new T.Emitter,this.onDefinitionsChanged=this._onDefinitionsChanged.event,this.taskTypes=Object.create(null),this.readyPromise=new Promise((I,f)=>{R.setHandler((h,d)=>{this._schema=void 0;try{for(const a of d.removed){const w=a.value;for(const P of w)this.taskTypes&&P.type&&this.taskTypes[P.type]&&delete this.taskTypes[P.type]}for(const a of d.added){const w=a.value;for(const P of w){const l=A.from(P,a.description.identifier,a.collector);l&&(this.taskTypes[l.taskType]=l)}}(d.removed.length>0||d.added.length>0)&&this._onDefinitionsChanged.fire()}catch{}I(void 0)})})}onReady(){return this.readyPromise}get(I){return this.taskTypes[I]}all(){return Object.keys(this.taskTypes).map(I=>this.taskTypes[I])}getJsonSchema(){if(this._schema===void 0){const I=[];for(const f of this.all()){const h={type:"object",additionalProperties:!1};f.required.length>0&&(h.required=f.required.slice(0)),f.properties!==void 0?h.properties=b.deepClone(f.properties):h.properties=Object.create(null),h.properties.type={type:"string",enum:[f.taskType]},I.push(h)}this._schema={oneOf:I}}return this._schema}}e.TaskDefinitionRegistryImpl=y,e.TaskDefinitionRegistry=new y}),define(ye[184],Ce([1,0,139,10,21,26,38,183]),function(ee,e,s,p,b,L,C,T){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.TaskDefinition=e.TasksSchemaProperties=e.TaskSettingId=e.KeyedTaskIdentifier=e.TaskEvent=e.TaskRunSource=e.TaskRunType=e.TaskEventKind=e.TaskSorter=e.JsonSchemaVersion=e.ExecutionEngine=e.InMemoryTask=e.ContributedTask=e.ConfiguringTask=e.CustomTask=e.CommonTask=e.RunOptions=e.RunOnOptions=e.DependsOrder=e.TaskSourceKind=e.TaskScope=e.TaskGroup=e.CommandString=e.RuntimeType=e.PresentationOptions=e.PanelKind=e.RevealProblemKind=e.RevealKind=e.CommandOptions=e.CUSTOMIZED_TASK_TYPE=e.ShellQuoting=e.TASKS_CATEGORY=e.TASK_RUNNING_STATE=e.USER_TASKS_GROUP_KEY=void 0,e.USER_TASKS_GROUP_KEY="settings",e.TASK_RUNNING_STATE=new C.RawContextKey("taskRunning",!1,s.localize(0,null)),e.TASKS_CATEGORY={value:s.localize(1,null),original:"Tasks"};var E;(function(N){N[N.Escape=1]="Escape",N[N.Strong=2]="Strong",N[N.Weak=3]="Weak"})(E=e.ShellQuoting||(e.ShellQuoting={})),e.CUSTOMIZED_TASK_TYPE="$customized",function(N){function K(V){if(!V)return N.Strong;switch(V.toLowerCase()){case"escape":return N.Escape;case"strong":return N.Strong;case"weak":return N.Weak;default:return N.Strong}}N.from=K}(E=e.ShellQuoting||(e.ShellQuoting={}));var A;(function(N){N.defaults={cwd:"${workspaceFolder}"}})(A=e.CommandOptions||(e.CommandOptions={}));var R;(function(N){N[N.Always=1]="Always",N[N.Silent=2]="Silent",N[N.Never=3]="Never"})(R=e.RevealKind||(e.RevealKind={})),function(N){function K(V){switch(V.toLowerCase()){case"always":return N.Always;case"silent":return N.Silent;case"never":return N.Never;default:return N.Always}}N.fromString=K}(R=e.RevealKind||(e.RevealKind={}));var y;(function(N){N[N.Never=1]="Never",N[N.OnProblem=2]="OnProblem",N[N.Always=3]="Always"})(y=e.RevealProblemKind||(e.RevealProblemKind={})),function(N){function K(V){switch(V.toLowerCase()){case"always":return N.Always;case"never":return N.Never;case"onproblem":return N.OnProblem;default:return N.OnProblem}}N.fromString=K}(y=e.RevealProblemKind||(e.RevealProblemKind={}));var m;(function(N){N[N.Shared=1]="Shared",N[N.Dedicated=2]="Dedicated",N[N.New=3]="New"})(m=e.PanelKind||(e.PanelKind={})),function(N){function K(V){switch(V.toLowerCase()){case"shared":return N.Shared;case"dedicated":return N.Dedicated;case"new":return N.New;default:return N.Shared}}N.fromString=K}(m=e.PanelKind||(e.PanelKind={}));var I;(function(N){N.defaults={echo:!0,reveal:R.Always,revealProblems:y.Never,focus:!1,panel:m.Shared,showReuseMessage:!0,clear:!1}})(I=e.PresentationOptions||(e.PresentationOptions={}));var f;(function(N){N[N.Shell=1]="Shell",N[N.Process=2]="Process",N[N.CustomExecution=3]="CustomExecution"})(f=e.RuntimeType||(e.RuntimeType={})),function(N){function K(F){switch(F.toLowerCase()){case"shell":return N.Shell;case"process":return N.Process;case"customExecution":return N.CustomExecution;default:return N.Process}}N.fromString=K;function V(F){switch(F){case N.Shell:return"shell";case N.Process:return"process";case N.CustomExecution:return"customExecution";default:return"process"}}N.toString=V}(f=e.RuntimeType||(e.RuntimeType={}));var h;(function(N){function K(V){return p.isString(V)?V:V.value}N.value=K})(h=e.CommandString||(e.CommandString={}));var d;(function(N){N.Clean={_id:"clean",isDefault:!1},N.Build={_id:"build",isDefault:!1},N.Rebuild={_id:"rebuild",isDefault:!1},N.Test={_id:"test",isDefault:!1};function K(F){return F===N.Clean._id||F===N.Build._id||F===N.Rebuild._id||F===N.Test._id}N.is=K;function V(F){if(F!==void 0)return p.isString(F)?K(F)?{_id:F,isDefault:!1}:void 0:F}N.from=V})(d=e.TaskGroup||(e.TaskGroup={}));var a;(function(N){N[N.Global=1]="Global",N[N.Workspace=2]="Workspace",N[N.Folder=3]="Folder"})(a=e.TaskScope||(e.TaskScope={}));var w;(function(N){N.Workspace="workspace",N.Extension="extension",N.InMemory="inMemory",N.WorkspaceFile="workspaceFile",N.User="user";function K(V){switch(V){case N.User:return 2;case N.WorkspaceFile:return 5;default:return 6}}N.toConfigurationTarget=K})(w=e.TaskSourceKind||(e.TaskSourceKind={}));var P;(function(N){N.parallel="parallel",N.sequence="sequence"})(P=e.DependsOrder||(e.DependsOrder={}));var l;(function(N){N[N.default=1]="default",N[N.folderOpen=2]="folderOpen"})(l=e.RunOnOptions||(e.RunOnOptions={}));var _;(function(N){N.defaults={reevaluateOnRerun:!0,runOn:l.default,instanceLimit:1}})(_=e.RunOptions||(e.RunOptions={}));class n{constructor(K,V,F,ne,ce,re){this._label="",this._id=K,V&&(this._label=V),F&&(this.type=F),this.runOptions=ne,this.configurationProperties=ce,this._source=re}getDefinition(K){}getMapKey(){return this._id}getRecentlyUsedKey(){}getCommonTaskId(){const K={folder:this.getFolderId(),id:this._id};return JSON.stringify(K)}clone(){return this.fromObject(Object.assign({},this))}getWorkspaceFolder(){}getWorkspaceFileName(){}getTelemetryKind(){return"unknown"}matches(K,V=!1){if(K===void 0)return!1;if(p.isString(K))return K===this._label||K===this.configurationProperties.identifier||V&&K===this._id;const F=this.getDefinition(!0);return F!==void 0&&F._key===K._key}getQualifiedLabel(){const K=this.getWorkspaceFolder();return K?`${this._label} (${K.name})`:this._label}getTaskExecution(){return{id:this._id,task:this}}addTaskLoadMessages(K){this._taskLoadMessages===void 0&&(this._taskLoadMessages=[]),K&&(this._taskLoadMessages=this._taskLoadMessages.concat(K))}get taskLoadMessages(){return this._taskLoadMessages}}e.CommonTask=n;class u extends n{constructor(K,V,F,ne,ce,re,fe,ie){super(K,F,void 0,fe,ie,V);this.command={},this._source=V,this.hasDefinedMatchers=re,ce&&(this.command=ce)}clone(){return new u(this._id,this._source,this._label,this.type,this.command,this.hasDefinedMatchers,this.runOptions,this.configurationProperties)}customizes(){if(this._source&&this._source.customizes)return this._source.customizes}getDefinition(K=!1){if(K&&this._source.customizes!==void 0)return this._source.customizes;{let V;switch(this.command?this.command.runtime:void 0){case f.Shell:V="shell";break;case f.Process:V="process";break;case f.CustomExecution:V="customExecution";break;case void 0:V="$composite";break;default:throw new Error("Unexpected task runtime")}return{type:V,_key:this._id,id:this._id}}}static is(K){return K instanceof u}getMapKey(){const K=this._source.config.workspaceFolder;return K?`${K.uri.toString()}|${this._id}|${this.instance}`:`${this._id}|${this.instance}`}getFolderId(){return this._source.kind===w.User?e.USER_TASKS_GROUP_KEY:this._source.config.workspaceFolder?.uri.toString()}getCommonTaskId(){return this._source.customizes?super.getCommonTaskId():this.getRecentlyUsedKey()??super.getCommonTaskId()}getRecentlyUsedKey(){const K=this.getFolderId();if(!K)return;let V=this.configurationProperties.identifier;this._source.kind!==w.Workspace&&(V+=this._source.kind);const F={type:e.CUSTOMIZED_TASK_TYPE,folder:K,id:V};return JSON.stringify(F)}getWorkspaceFolder(){return this._source.config.workspaceFolder}getWorkspaceFileName(){return this._source.config.workspace&&this._source.config.workspace.configuration?b.basename(this._source.config.workspace.configuration):void 0}getTelemetryKind(){return this._source.customizes?"workspace>extension":"workspace"}fromObject(K){return new u(K._id,K._source,K._label,K.type,K.command,K.hasDefinedMatchers,K.runOptions,K.configurationProperties)}}e.CustomTask=u;class i extends n{constructor(K,V,F,ne,ce,re,fe){super(K,F,ne,re,fe,V);this._source=V,this.configures=ce}static is(K){return K instanceof i}fromObject(K){return K}getDefinition(){return this.configures}getWorkspaceFileName(){return this._source.config.workspace&&this._source.config.workspace.configuration?b.basename(this._source.config.workspace.configuration):void 0}getWorkspaceFolder(){return this._source.config.workspaceFolder}getFolderId(){return this._source.kind===w.User?e.USER_TASKS_GROUP_KEY:this._source.config.workspaceFolder?.uri.toString()}getRecentlyUsedKey(){const K=this.getFolderId();if(!K)return;let V=this.configurationProperties.identifier;this._source.kind!==w.Workspace&&(V+=this._source.kind);const F={type:e.CUSTOMIZED_TASK_TYPE,folder:K,id:V};return JSON.stringify(F)}}e.ConfiguringTask=i;class o extends n{constructor(K,V,F,ne,ce,re,fe,ie,Ee){super(K,F,ne,ie,Ee,V);this.defines=ce,this.hasDefinedMatchers=fe,this.command=re,this.icon=Ee.icon,this.hide=Ee.hide}clone(){return new o(this._id,this._source,this._label,this.type,this.defines,this.command,this.hasDefinedMatchers,this.runOptions,this.configurationProperties)}getDefinition(){return this.defines}static is(K){return K instanceof o}getMapKey(){const K=this._source.workspaceFolder;return K?`${this._source.scope.toString()}|${K.uri.toString()}|${this._id}|${this.instance}`:`${this._source.scope.toString()}|${this._id}|${this.instance}`}getFolderId(){if(this._source.scope===3&&this._source.workspaceFolder)return this._source.workspaceFolder.uri.toString()}getRecentlyUsedKey(){const K={type:"contributed",scope:this._source.scope,id:this._id};return K.folder=this.getFolderId(),JSON.stringify(K)}getWorkspaceFolder(){return this._source.workspaceFolder}getTelemetryKind(){return"extension"}fromObject(K){return new o(K._id,K._source,K._label,K.type,K.defines,K.command,K.hasDefinedMatchers,K.runOptions,K.configurationProperties)}}e.ContributedTask=o;class r extends n{constructor(K,V,F,ne,ce,re){super(K,F,ne,ce,re,V);this._source=V}clone(){return new r(this._id,this._source,this._label,this.type,this.runOptions,this.configurationProperties)}static is(K){return K instanceof r}getTelemetryKind(){return"composite"}getMapKey(){return`${this._id}|${this.instance}`}getFolderId(){}fromObject(K){return new r(K._id,K._source,K._label,K.type,K.runOptions,K.configurationProperties)}}e.InMemoryTask=r;var t;(function(N){N[N.Process=1]="Process",N[N.Terminal=2]="Terminal"})(t=e.ExecutionEngine||(e.ExecutionEngine={})),function(N){N._default=N.Terminal}(t=e.ExecutionEngine||(e.ExecutionEngine={}));var c;(function(N){N[N.V0_1_0=1]="V0_1_0",N[N.V2_0_0=2]="V2_0_0"})(c=e.JsonSchemaVersion||(e.JsonSchemaVersion={}));class v{constructor(K){this._order=new Map;for(let V=0;V<K.length;V++)this._order.set(K[V].uri.toString(),V)}compare(K,V){const F=K.getWorkspaceFolder(),ne=V.getWorkspaceFolder();if(F&&ne){let ce=this._order.get(F.uri.toString());ce=ce===void 0?0:ce+1;let re=this._order.get(ne.uri.toString());return re=re===void 0?0:re+1,ce===re?K._label.localeCompare(V._label):ce-re}else return!F&&ne?-1:F&&!ne?1:0}}e.TaskSorter=v;var g;(function(N){N.DependsOnStarted="dependsOnStarted",N.AcquiredInput="acquiredInput",N.Start="start",N.ProcessStarted="processStarted",N.Active="active",N.Inactive="inactive",N.Changed="changed",N.Terminated="terminated",N.ProcessEnded="processEnded",N.End="end"})(g=e.TaskEventKind||(e.TaskEventKind={}));var D;(function(N){N.SingleRun="singleRun",N.Background="background"})(D=e.TaskRunType||(e.TaskRunType={}));var U;(function(N){N[N.System=0]="System",N[N.User=1]="User",N[N.FolderOpen=2]="FolderOpen",N[N.ConfigurationChange=3]="ConfigurationChange",N[N.Reconnect=4]="Reconnect"})(U=e.TaskRunSource||(e.TaskRunSource={}));var W;(function(N){function K(V,F,ne,ce){if(F){const re={kind:V,taskId:F._id,taskName:F.configurationProperties.name,runType:F.configurationProperties.isBackground?"background":"singleRun",group:F.configurationProperties.group,processId:void 0,exitCode:void 0,terminalId:void 0,__task:F};return V==="start"?(re.terminalId=ne,re.resolvedVariables=ce):V==="processStarted"?re.processId=ne:V==="processEnded"&&(re.exitCode=ne),Object.freeze(re)}else return Object.freeze({kind:"changed"})}N.create=K})(W=e.TaskEvent||(e.TaskEvent={}));var M;(function(N){function K(F){const ne=Object.keys(F).sort();let ce="";for(const re of ne){let fe=F[re];fe instanceof Object?fe=K(fe):typeof fe=="string"&&(fe=fe.replace(/,/g,",,")),ce+=re+","+fe+","}return ce}function V(F){const ce={_key:K(F),type:F.taskType};return Object.assign(ce,F),ce}N.create=V})(M=e.KeyedTaskIdentifier||(e.KeyedTaskIdentifier={}));var S;(function(N){N.AutoDetect="task.autoDetect",N.SaveBeforeRun="task.saveBeforeRun",N.ShowDecorations="task.showDecorations",N.ProblemMatchersNeverPrompt="task.problemMatchers.neverPrompt",N.SlowProviderWarning="task.slowProviderWarning",N.QuickOpenHistory="task.quickOpen.history",N.QuickOpenDetail="task.quickOpen.detail",N.QuickOpenSkip="task.quickOpen.skip",N.QuickOpenShowAll="task.quickOpen.showAll",N.AllowAutomaticTasks="task.allowAutomaticTasks",N.Reconnection="task.experimental.reconnection"})(S=e.TaskSettingId||(e.TaskSettingId={}));var z;(function(N){N.Tasks="tasks",N.SuppressTaskName="tasks.suppressTaskName",N.Windows="tasks.windows",N.Osx="tasks.osx",N.Linux="tasks.linux",N.ShowOutput="tasks.showOutput",N.IsShellCommand="tasks.isShellCommand",N.ServiceTestSetting="tasks.service.testSetting"})(z=e.TasksSchemaProperties||(e.TasksSchemaProperties={}));var $;(function(N){function K(V,F){const ne=T.TaskDefinitionRegistry.get(V.type);if(ne===void 0){const ie=L.deepClone(V);return delete ie._key,M.create(ie)}const ce=Object.create(null);ce.type=ne.taskType;const re=new Set;ne.required.forEach(ie=>re.add(ie));const fe=ne.properties;for(const ie of Object.keys(fe)){const Ee=V[ie];if(Ee!=null)ce[ie]=Ee;else if(re.has(ie)){const be=fe[ie];if(be.default!==void 0)ce[ie]=L.deepClone(be.default);else switch(be.type){case"boolean":ce[ie]=!1;break;case"number":case"integer":ce[ie]=0;break;case"string":ce[ie]="";break;default:F.error(s.localize(2,null,JSON.stringify(V,void 0,0),ie));return}}}return M.create(ce)}N.createTaskIdentifier=K})($=e.TaskDefinition||(e.TaskDefinition={}))}),define(ye[185],Ce([1,0,11]),function(ee,e,s){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.CanceledLazyPromise=e.LazyPromise=void 0;class p{constructor(){this._actual=null,this._actualOk=null,this._actualErr=null,this._hasValue=!1,this._value=null,this._hasErr=!1,this._err=null}get[Symbol.toStringTag](){return this.toString()}_ensureActual(){return this._actual||(this._actual=new Promise((C,T)=>{this._actualOk=C,this._actualErr=T,this._hasValue&&this._actualOk(this._value),this._hasErr&&this._actualErr(this._err)})),this._actual}resolveOk(C){this._hasValue||this._hasErr||(this._hasValue=!0,this._value=C,this._actual&&this._actualOk(C))}resolveErr(C){this._hasValue||this._hasErr||(this._hasErr=!0,this._err=C,this._actual?this._actualErr(C):(0,s.onUnexpectedError)(C))}then(C,T){return this._ensureActual().then(C,T)}catch(C){return this._ensureActual().then(void 0,C)}finally(C){return this._ensureActual().finally(C)}}e.LazyPromise=p;class b extends p{constructor(){super();this._hasErr=!0,this._err=new s.CancellationError}}e.CanceledLazyPromise=b}),define(ye[40],Ce([1,0]),function(ee,e){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.SerializableObjectWithBuffers=e.getStringIdentifierForProxy=e.createProxyIdentifier=e.ProxyIdentifier=void 0;class s{constructor(E){this._proxyIdentifierBrand=void 0,this.sid=E,this.nid=++s.count}}e.ProxyIdentifier=s,s.count=0;const p=[];function b(T){const E=new s(T);return p[E.nid]=E,E}e.createProxyIdentifier=b;function L(T){return p[T].sid}e.getStringIdentifierForProxy=L;class C{constructor(E){this.value=E}}e.SerializableObjectWithBuffers=C}),define(ye[5],Ce([1,0,55,40]),function(ee,e,s,p){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.ExtHostContext=e.MainContext=e.ExtHostTestingResource=e.reviveWorkspaceEditDto=e.ISuggestResultDtoField=e.ISuggestDataDtoField=e.IdObject=e.CandidatePortSource=e.NotebookEditorRevealType=e.CellOutputKind=e.WebviewMessageArrayBufferViewType=e.WebviewEditorCapabilities=e.TabModelOperationKind=e.TabInputKind=e.TextEditorRevealType=void 0;var b;(function(a){a[a.Default=0]="Default",a[a.InCenter=1]="InCenter",a[a.InCenterIfOutsideViewport=2]="InCenterIfOutsideViewport",a[a.AtTop=3]="AtTop"})(b=e.TextEditorRevealType||(e.TextEditorRevealType={}));var L;(function(a){a[a.UnknownInput=0]="UnknownInput",a[a.TextInput=1]="TextInput",a[a.TextDiffInput=2]="TextDiffInput",a[a.TextMergeInput=3]="TextMergeInput",a[a.NotebookInput=4]="NotebookInput",a[a.NotebookDiffInput=5]="NotebookDiffInput",a[a.CustomEditorInput=6]="CustomEditorInput",a[a.WebviewEditorInput=7]="WebviewEditorInput",a[a.TerminalEditorInput=8]="TerminalEditorInput",a[a.InteractiveEditorInput=9]="InteractiveEditorInput"})(L=e.TabInputKind||(e.TabInputKind={}));var C;(function(a){a[a.TAB_OPEN=0]="TAB_OPEN",a[a.TAB_CLOSE=1]="TAB_CLOSE",a[a.TAB_UPDATE=2]="TAB_UPDATE",a[a.TAB_MOVE=3]="TAB_MOVE"})(C=e.TabModelOperationKind||(e.TabModelOperationKind={}));var T;(function(a){a[a.Editable=0]="Editable",a[a.SupportsHotExit=1]="SupportsHotExit"})(T=e.WebviewEditorCapabilities||(e.WebviewEditorCapabilities={}));var E;(function(a){a[a.Int8Array=1]="Int8Array",a[a.Uint8Array=2]="Uint8Array",a[a.Uint8ClampedArray=3]="Uint8ClampedArray",a[a.Int16Array=4]="Int16Array",a[a.Uint16Array=5]="Uint16Array",a[a.Int32Array=6]="Int32Array",a[a.Uint32Array=7]="Uint32Array",a[a.Float32Array=8]="Float32Array",a[a.Float64Array=9]="Float64Array",a[a.BigInt64Array=10]="BigInt64Array",a[a.BigUint64Array=11]="BigUint64Array"})(E=e.WebviewMessageArrayBufferViewType||(e.WebviewMessageArrayBufferViewType={}));var A;(function(a){a[a.Text=1]="Text",a[a.Error=2]="Error",a[a.Rich=3]="Rich"})(A=e.CellOutputKind||(e.CellOutputKind={}));var R;(function(a){a[a.Default=0]="Default",a[a.InCenter=1]="InCenter",a[a.InCenterIfOutsideViewport=2]="InCenterIfOutsideViewport",a[a.AtTop=3]="AtTop"})(R=e.NotebookEditorRevealType||(e.NotebookEditorRevealType={}));var y;(function(a){a[a.None=0]="None",a[a.Process=1]="Process",a[a.Output=2]="Output"})(y=e.CandidatePortSource||(e.CandidatePortSource={}));class m{static mixin(w){return w._id=m._n++,w}}e.IdObject=m,m._n=0;var I;(function(a){a.label="a",a.kind="b",a.detail="c",a.documentation="d",a.sortText="e",a.filterText="f",a.preselect="g",a.insertText="h",a.insertTextRules="i",a.range="j",a.commitCharacters="k",a.additionalTextEdits="l",a.command="m",a.kindModifier="n"})(I=e.ISuggestDataDtoField||(e.ISuggestDataDtoField={}));var f;(function(a){a.defaultRanges="a",a.completions="b",a.isIncomplete="c",a.duration="d"})(f=e.ISuggestResultDtoField||(e.ISuggestResultDtoField={}));function h(a){return a&&a.edits&&(0,s.revive)(a),a}e.reviveWorkspaceEditDto=h;var d;(function(a){a[a.Workspace=0]="Workspace",a[a.TextDocument=1]="TextDocument"})(d=e.ExtHostTestingResource||(e.ExtHostTestingResource={})),e.MainContext={MainThreadAuthentication:(0,p.createProxyIdentifier)("MainThreadAuthentication"),MainThreadBulkEdits:(0,p.createProxyIdentifier)("MainThreadBulkEdits"),MainThreadClipboard:(0,p.createProxyIdentifier)("MainThreadClipboard"),MainThreadCommands:(0,p.createProxyIdentifier)("MainThreadCommands"),MainThreadComments:(0,p.createProxyIdentifier)("MainThreadComments"),MainThreadConfiguration:(0,p.createProxyIdentifier)("MainThreadConfiguration"),MainThreadConsole:(0,p.createProxyIdentifier)("MainThreadConsole"),MainThreadDebugService:(0,p.createProxyIdentifier)("MainThreadDebugService"),MainThreadDecorations:(0,p.createProxyIdentifier)("MainThreadDecorations"),MainThreadDiagnostics:(0,p.createProxyIdentifier)("MainThreadDiagnostics"),MainThreadDialogs:(0,p.createProxyIdentifier)("MainThreadDiaglogs"),MainThreadDocuments:(0,p.createProxyIdentifier)("MainThreadDocuments"),MainThreadDocumentContentProviders:(0,p.createProxyIdentifier)("MainThreadDocumentContentProviders"),MainThreadTextEditors:(0,p.createProxyIdentifier)("MainThreadTextEditors"),MainThreadEditorInsets:(0,p.createProxyIdentifier)("MainThreadEditorInsets"),MainThreadEditorTabs:(0,p.createProxyIdentifier)("MainThreadEditorTabs"),MainThreadErrors:(0,p.createProxyIdentifier)("MainThreadErrors"),MainThreadTreeViews:(0,p.createProxyIdentifier)("MainThreadTreeViews"),MainThreadDownloadService:(0,p.createProxyIdentifier)("MainThreadDownloadService"),MainThreadKeytar:(0,p.createProxyIdentifier)("MainThreadKeytar"),MainThreadLanguageFeatures:(0,p.createProxyIdentifier)("MainThreadLanguageFeatures"),MainThreadLanguages:(0,p.createProxyIdentifier)("MainThreadLanguages"),MainThreadLogger:(0,p.createProxyIdentifier)("MainThreadLogger"),MainThreadMessageService:(0,p.createProxyIdentifier)("MainThreadMessageService"),MainThreadOutputService:(0,p.createProxyIdentifier)("MainThreadOutputService"),MainThreadProgress:(0,p.createProxyIdentifier)("MainThreadProgress"),MainThreadQuickOpen:(0,p.createProxyIdentifier)("MainThreadQuickOpen"),MainThreadStatusBar:(0,p.createProxyIdentifier)("MainThreadStatusBar"),MainThreadSecretState:(0,p.createProxyIdentifier)("MainThreadSecretState"),MainThreadStorage:(0,p.createProxyIdentifier)("MainThreadStorage"),MainThreadTelemetry:(0,p.createProxyIdentifier)("MainThreadTelemetry"),MainThreadTerminalService:(0,p.createProxyIdentifier)("MainThreadTerminalService"),MainThreadWebviews:(0,p.createProxyIdentifier)("MainThreadWebviews"),MainThreadWebviewPanels:(0,p.createProxyIdentifier)("MainThreadWebviewPanels"),MainThreadWebviewViews:(0,p.createProxyIdentifier)("MainThreadWebviewViews"),MainThreadCustomEditors:(0,p.createProxyIdentifier)("MainThreadCustomEditors"),MainThreadUrls:(0,p.createProxyIdentifier)("MainThreadUrls"),MainThreadUriOpeners:(0,p.createProxyIdentifier)("MainThreadUriOpeners"),MainThreadWorkspace:(0,p.createProxyIdentifier)("MainThreadWorkspace"),MainThreadFileSystem:(0,p.createProxyIdentifier)("MainThreadFileSystem"),MainThreadExtensionService:(0,p.createProxyIdentifier)("MainThreadExtensionService"),MainThreadSCM:(0,p.createProxyIdentifier)("MainThreadSCM"),MainThreadSearch:(0,p.createProxyIdentifier)("MainThreadSearch"),MainThreadTask:(0,p.createProxyIdentifier)("MainThreadTask"),MainThreadWindow:(0,p.createProxyIdentifier)("MainThreadWindow"),MainThreadLabelService:(0,p.createProxyIdentifier)("MainThreadLabelService"),MainThreadNotebook:(0,p.createProxyIdentifier)("MainThreadNotebook"),MainThreadNotebookDocuments:(0,p.createProxyIdentifier)("MainThreadNotebookDocumentsShape"),MainThreadNotebookEditors:(0,p.createProxyIdentifier)("MainThreadNotebookEditorsShape"),MainThreadNotebookKernels:(0,p.createProxyIdentifier)("MainThreadNotebookKernels"),MainThreadNotebookRenderers:(0,p.createProxyIdentifier)("MainThreadNotebookRenderers"),MainThreadInteractive:(0,p.createProxyIdentifier)("MainThreadInteractive"),MainThreadTheming:(0,p.createProxyIdentifier)("MainThreadTheming"),MainThreadTunnelService:(0,p.createProxyIdentifier)("MainThreadTunnelService"),MainThreadTimeline:(0,p.createProxyIdentifier)("MainThreadTimeline"),MainThreadTesting:(0,p.createProxyIdentifier)("MainThreadTesting")},e.ExtHostContext={ExtHostCommands:(0,p.createProxyIdentifier)("ExtHostCommands"),ExtHostConfiguration:(0,p.createProxyIdentifier)("ExtHostConfiguration"),ExtHostDiagnostics:(0,p.createProxyIdentifier)("ExtHostDiagnostics"),ExtHostDebugService:(0,p.createProxyIdentifier)("ExtHostDebugService"),ExtHostDecorations:(0,p.createProxyIdentifier)("ExtHostDecorations"),ExtHostDocumentsAndEditors:(0,p.createProxyIdentifier)("ExtHostDocumentsAndEditors"),ExtHostDocuments:(0,p.createProxyIdentifier)("ExtHostDocuments"),ExtHostDocumentContentProviders:(0,p.createProxyIdentifier)("ExtHostDocumentContentProviders"),ExtHostDocumentSaveParticipant:(0,p.createProxyIdentifier)("ExtHostDocumentSaveParticipant"),ExtHostEditors:(0,p.createProxyIdentifier)("ExtHostEditors"),ExtHostTreeViews:(0,p.createProxyIdentifier)("ExtHostTreeViews"),ExtHostFileSystem:(0,p.createProxyIdentifier)("ExtHostFileSystem"),ExtHostFileSystemInfo:(0,p.createProxyIdentifier)("ExtHostFileSystemInfo"),ExtHostFileSystemEventService:(0,p.createProxyIdentifier)("ExtHostFileSystemEventService"),ExtHostLanguages:(0,p.createProxyIdentifier)("ExtHostLanguages"),ExtHostLanguageFeatures:(0,p.createProxyIdentifier)("ExtHostLanguageFeatures"),ExtHostQuickOpen:(0,p.createProxyIdentifier)("ExtHostQuickOpen"),ExtHostExtensionService:(0,p.createProxyIdentifier)("ExtHostExtensionService"),ExtHostLogLevelServiceShape:(0,p.createProxyIdentifier)("ExtHostLogLevelServiceShape"),ExtHostTerminalService:(0,p.createProxyIdentifier)("ExtHostTerminalService"),ExtHostSCM:(0,p.createProxyIdentifier)("ExtHostSCM"),ExtHostSearch:(0,p.createProxyIdentifier)("ExtHostSearch"),ExtHostTask:(0,p.createProxyIdentifier)("ExtHostTask"),ExtHostWorkspace:(0,p.createProxyIdentifier)("ExtHostWorkspace"),ExtHostWindow:(0,p.createProxyIdentifier)("ExtHostWindow"),ExtHostWebviews:(0,p.createProxyIdentifier)("ExtHostWebviews"),ExtHostWebviewPanels:(0,p.createProxyIdentifier)("ExtHostWebviewPanels"),ExtHostCustomEditors:(0,p.createProxyIdentifier)("ExtHostCustomEditors"),ExtHostWebviewViews:(0,p.createProxyIdentifier)("ExtHostWebviewViews"),ExtHostEditorInsets:(0,p.createProxyIdentifier)("ExtHostEditorInsets"),ExtHostEditorTabs:(0,p.createProxyIdentifier)("ExtHostEditorTabs"),ExtHostProgress:(0,p.createProxyIdentifier)("ExtHostProgress"),ExtHostComments:(0,p.createProxyIdentifier)("ExtHostComments"),ExtHostSecretState:(0,p.createProxyIdentifier)("ExtHostSecretState"),ExtHostStorage:(0,p.createProxyIdentifier)("ExtHostStorage"),ExtHostUrls:(0,p.createProxyIdentifier)("ExtHostUrls"),ExtHostUriOpeners:(0,p.createProxyIdentifier)("ExtHostUriOpeners"),ExtHostOutputService:(0,p.createProxyIdentifier)("ExtHostOutputService"),ExtHosLabelService:(0,p.createProxyIdentifier)("ExtHostLabelService"),ExtHostNotebook:(0,p.createProxyIdentifier)("ExtHostNotebook"),ExtHostNotebookDocuments:(0,p.createProxyIdentifier)("ExtHostNotebookDocuments"),ExtHostNotebookEditors:(0,p.createProxyIdentifier)("ExtHostNotebookEditors"),ExtHostNotebookKernels:(0,p.createProxyIdentifier)("ExtHostNotebookKernels"),ExtHostNotebookRenderers:(0,p.createProxyIdentifier)("ExtHostNotebookRenderers"),ExtHostInteractive:(0,p.createProxyIdentifier)("ExtHostInteractive"),ExtHostTheming:(0,p.createProxyIdentifier)("ExtHostTheming"),ExtHostTunnelService:(0,p.createProxyIdentifier)("ExtHostTunnelService"),ExtHostAuthentication:(0,p.createProxyIdentifier)("ExtHostAuthentication"),ExtHostTimeline:(0,p.createProxyIdentifier)("ExtHostTimeline"),ExtHostTesting:(0,p.createProxyIdentifier)("ExtHostTesting"),ExtHostTelemetry:(0,p.createProxyIdentifier)("ExtHostTelemetry")}}),define(ye[67],Ce([1,0,5,4,3]),function(ee,e,s,p,b){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.IExtHostSecretState=e.ExtHostSecretState=void 0;class L{constructor(T){this._onDidChangePassword=new p.Emitter,this.onDidChangePassword=this._onDidChangePassword.event,this._proxy=T.getProxy(s.MainContext.MainThreadSecretState)}async $onDidChangePassword(T){this._onDidChangePassword.fire(T)}get(T,E){return this._proxy.$getPassword(T,E)}store(T,E,A){return this._proxy.$setPassword(T,E,A)}delete(T,E){return this._proxy.$deletePassword(T,E)}}e.ExtHostSecretState=L,e.IExtHostSecretState=(0,b.createDecorator)("IExtHostSecretState")}),define(ye[68],Ce([1,0,3,14,5,15]),function(ee,e,s,p,b,L){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.NullApiDeprecationService=e.ExtHostApiDeprecationService=e.IExtHostApiDeprecationService=void 0,e.IExtHostApiDeprecationService=(0,s.createDecorator)("IExtHostApiDeprecationService");let C=class{constructor(E,A){this._extHostLogService=A,this._reportedUsages=new Set,this._telemetryShape=E.getProxy(b.MainContext.MainThreadTelemetry)}report(E,A,R){const y=this.getUsageKey(E,A);this._reportedUsages.has(y)||(this._reportedUsages.add(y),A.isUnderDevelopment&&this._extHostLogService.warn(`[Deprecation Warning] '${E}' is deprecated. ${R}`),this._telemetryShape.$publicLog2("extHostDeprecatedApiUsage",{extensionId:A.identifier.value,apiId:E}))}getUsageKey(E,A){return`${E}-${A.identifier.value}`}};C=ze([xe(0,L.IExtHostRpcService),xe(1,p.ILogService)],C),e.ExtHostApiDeprecationService=C,e.NullApiDeprecationService=Object.freeze(new class{report(T,E,A){}})}),define(ye[186],Ce([1,0,4,5,6,27]),function(ee,e,s,p,b,L){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.ExtHostAuthentication=void 0;class C{constructor(E){this._authenticationProviders=new Map,this._providers=[],this._onDidChangeSessions=new s.Emitter,this.onDidChangeSessions=this._onDidChangeSessions.event,this._inFlightRequests=new Map,this._proxy=E.getProxy(p.MainContext.MainThreadAuthentication)}$setProviders(E){return this._providers=E,Promise.resolve()}async getSession(E,A,R,y={}){const m=L.ExtensionIdentifier.toKey(E.identifier),I=this._inFlightRequests.get(m)||[],f=[...R].sort().join(" ");let h=I.find(d=>d.providerId===A&&d.scopes===f);if(h)return h.result;{const d=this._getSession(E,m,A,R,y);h={providerId:A,scopes:f,result:d},I.push(h),this._inFlightRequests.set(m,I);try{await d}finally{const a=I.findIndex(w=>w.providerId===A&&w.scopes===f);a>-1&&(I.splice(a),this._inFlightRequests.set(m,I))}return d}}async _getSession(E,A,R,y,m={}){await this._proxy.$ensureProvider(R);const I=E.displayName||E.name;return this._proxy.$getSession(R,y,A,I,m)}async removeSession(E,A){const R=this._authenticationProviders.get(E);return R?R.provider.removeSession(A):this._proxy.$removeSession(E,A)}registerAuthenticationProvider(E,A,R,y){if(this._authenticationProviders.get(E))throw new Error(`An authentication provider with id '${E}' is already registered.`);this._authenticationProviders.set(E,{label:A,provider:R,options:y??{supportsMultipleAccounts:!1}}),this._providers.find(I=>I.id===E)||this._providers.push({id:E,label:A});const m=R.onDidChangeSessions(I=>{this._proxy.$sendDidChangeSessions(E,{added:I.added??[],changed:I.changed??[],removed:I.removed??[]})});return this._proxy.$registerAuthenticationProvider(E,A,y?.supportsMultipleAccounts??!1),new b.Disposable(()=>{m.dispose(),this._authenticationProviders.delete(E);const I=this._providers.findIndex(f=>f.id===E);I>-1&&this._providers.splice(I),this._proxy.$unregisterAuthenticationProvider(E)})}$createSession(E,A){const R=this._authenticationProviders.get(E);if(R)return Promise.resolve(R.provider.createSession(A));throw new Error(`Unable to find authentication provider with handle: ${E}`)}$removeSession(E,A){const R=this._authenticationProviders.get(E);if(R)return Promise.resolve(R.provider.removeSession(A));throw new Error(`Unable to find authentication provider with handle: ${E}`)}$getSessions(E,A){const R=this._authenticationProviders.get(E);if(R)return Promise.resolve(R.provider.getSessions(A));throw new Error(`Unable to find authentication provider with handle: ${E}`)}$onDidChangeAuthenticationSessions(E,A){return this._onDidChangeSessions.fire({provider:{id:E,label:A}}),Promise.resolve()}}e.ExtHostAuthentication=C}),define(ye[187],Ce([1,0,5,15,8,24]),function(ee,e,s,p,b,L){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.ExtHostBulkEdits=void 0;let C=class{constructor(E,A){this._proxy=E.getProxy(s.MainContext.MainThreadBulkEdits),this._versionInformationProvider={getTextDocumentVersion:R=>A.getDocument(R)?.version,getNotebookDocumentVersion:()=>{}}}applyWorkspaceEdit(E,A){const R=(0,L.isProposedApiEnabled)(A,"snippetWorkspaceEdit"),y=b.WorkspaceEdit.from(E,this._versionInformationProvider,R);return this._proxy.$tryApplyWorkspaceEdit(y)}};C=ze([xe(0,p.IExtHostRpcService)],C),e.ExtHostBulkEdits=C}),define(ye[188],Ce([1,0,5]),function(ee,e,s){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.ExtHostClipboard=void 0;class p{constructor(L){const C=L.getProxy(s.MainContext.MainThreadClipboard);this.value=Object.freeze({readText(){return C.$readText()},writeText(T){return C.$writeText(T)}})}}e.ExtHostClipboard=p});var Je=this&&this.__classPrivateFieldSet||function(ee,e,s,p,b){if(p==="m")throw new TypeError("Private method is not writable");if(p==="a"&&!b)throw new TypeError("Private accessor was defined without a setter");if(typeof e=="function"?ee!==e||!b:!e.has(ee))throw new TypeError("Cannot write private member to an object whose class did not declare it");return p==="a"?b.call(ee,s):b?b.value=s:e.set(ee,s),s},Ae=this&&this.__classPrivateFieldGet||function(ee,e,s,p){if(s==="a"&&!p)throw new TypeError("Private accessor was defined without a getter");if(typeof e=="function"?ee!==e||!p:!e.has(ee))throw new TypeError("Cannot read private member from an object whose class did not declare it");return s==="m"?p:s==="a"?p.call(ee):p?p.value:e.get(ee)};define(ye[36],Ce([1,0,10,6,8,26,5,16,14,55,48,241,2,7,3,15,92,22,40,44]),function(ee,e,s,p,b,L,C,T,E,A,R,y,m,I,f,h,d,a,w,P){"use strict";var l,_;Object.defineProperty(e,"__esModule",{value:!0}),e.ApiCommand=e.ApiCommandResult=e.ApiCommandArgument=e.CommandsConverter=e.IExtHostCommands=e.ExtHostCommands=void 0;let n=class{constructor(c,v){l.set(this,void 0),this._commands=new Map,this._apiCommands=new Map,_.set(this,void 0),Je(this,l,c.getProxy(C.MainContext.MainThreadCommands),"f"),this._logService=v,Je(this,_,c.getProxy(C.MainContext.MainThreadTelemetry),"f"),this.converter=new u(this,g=>{const D=this._apiCommands.get(g);return D?.result===o.Void?D:void 0},v),this._argumentProcessors=[{processArgument(g){return(0,A.revive)(g)}},{processArgument(g){return(0,L.cloneAndChange)(g,function(D){if(R.Range.isIRange(D))return b.Range.to(D);if(y.Position.isIPosition(D))return b.Position.to(D);if(R.Range.isIRange(D.range)&&m.URI.isUri(D.uri))return b.location.to(D);if(D instanceof a.VSBuffer)return D.buffer.buffer;if(!Array.isArray(D))return D})}}]}registerArgumentProcessor(c){this._argumentProcessors.push(c)}registerApiCommand(c){const v=this.registerCommand(!1,c.id,async(...g)=>{const D=c.args.map((W,M)=>{if(!W.validate(g[M]))throw new Error(`Invalid argument '${W.name}' when running '${c.id}', received: ${g[M]}`);return W.convert(g[M])}),U=await this.executeCommand(c.internalId,...D);return c.result.convert(U,g,this.converter)},void 0,{description:c.description,args:c.args,returns:c.result.description});return this._apiCommands.set(c.id,c),new p.Disposable(()=>{v.dispose(),this._apiCommands.delete(c.id)})}registerCommand(c,v,g,D,U,W){if(this._logService.trace("ExtHostCommands#registerCommand",v),!v.trim().length)throw new Error("invalid id");if(this._commands.has(v))throw new Error(`command '${v}' already exists`);return this._commands.set(v,{callback:g,thisArg:D,description:U,extension:W}),c&&Ae(this,l,"f").$registerCommand(v),new p.Disposable(()=>{this._commands.delete(v)&&c&&Ae(this,l,"f").$unregisterCommand(v)})}executeCommand(c,...v){return this._logService.trace("ExtHostCommands#executeCommand",c),this._doExecuteCommand(c,v,!0)}async _doExecuteCommand(c,v,g){if(this._commands.has(c))return Ae(this,l,"f").$fireCommandActivationEvent(c),this._executeContributedCommand(c,v,!1);{let D=!1;const U=(0,L.cloneAndChange)(v,function(W){if(W instanceof p.Position)return b.Position.from(W);if(W instanceof p.Range)return b.Range.from(W);if(W instanceof p.Location)return b.location.from(W);if(p.NotebookRange.isNotebookRange(W))return b.NotebookRange.from(W);if(W instanceof ArrayBuffer)return D=!0,a.VSBuffer.wrap(new Uint8Array(W));if(W instanceof Uint8Array)return D=!0,a.VSBuffer.wrap(W);if(W instanceof a.VSBuffer)return D=!0,W;if(!Array.isArray(W))return W});try{const W=await Ae(this,l,"f").$executeCommand(c,D?new w.SerializableObjectWithBuffers(U):U,g);return(0,A.revive)(W)}catch(W){if(W instanceof Error&&W.message==="$executeCommand:retry")return this._doExecuteCommand(c,v,!1);throw W}}}async _executeContributedCommand(c,v,g){const D=this._commands.get(c);if(!D)throw new Error("Unknown command");this._reportTelemetry(D,c);const{callback:U,thisArg:W,description:M}=D;if(M)for(let S=0;S<M.args.length;S++)try{(0,s.validateConstraint)(v[S],M.args[S].constraint)}catch{throw new Error(`Running the contributed command: '${c}' failed. Illegal argument '${M.args[S].name}' - ${M.args[S].description}`)}try{return await U.apply(W,v)}catch(S){if(c===this.converter.delegatingCommandId){const z=this.converter.getActualCommand(...v);z&&(c=z.command)}throw this._logService.error(S,c,D.extension?.identifier),g?new class extends Error{constructor(){super((0,P.toErrorMessage)(S));this.id=c,this.source=D.extension?.displayName??D.extension?.name}}:S}}_reportTelemetry(c,v){!c.extension||c.extension.isBuiltin||Ae(this,_,"f").$publicLog2("Extension:ActionExecuted",{extensionId:c.extension.identifier.value,id:v})}$executeContributedCommand(c,...v){return this._logService.trace("ExtHostCommands#$executeContributedCommand",c),this._commands.has(c)?(v=v.map(g=>this._argumentProcessors.reduce((D,U)=>U.processArgument(D),g)),this._executeContributedCommand(c,v,!0)):Promise.reject(new Error(`Contributed command '${c}' does not exist.`))}getCommands(c=!1){return this._logService.trace("ExtHostCommands#getCommands",c),Ae(this,l,"f").$getCommands().then(v=>(c&&(v=v.filter(g=>g[0]!=="_")),v))}$getContributedCommandHandlerDescriptions(){const c=Object.create(null);for(const[v,g]of this._commands){const{description:D}=g;D&&(c[v]=D)}return Promise.resolve(c)}};l=new WeakMap,_=new WeakMap,n=ze([xe(0,h.IExtHostRpcService),xe(1,E.ILogService)],n),e.ExtHostCommands=n,e.IExtHostCommands=(0,f.createDecorator)("IExtHostCommands");class u{constructor(c,v,g){this._commands=c,this._lookupApiCommand=v,this._logService=g,this.delegatingCommandId=`_vscode_delegate_cmd_${Date.now().toString(36)}`,this._cache=new Map,this._cachIdPool=0,this._commands.registerCommand(!0,this.delegatingCommandId,this._executeConvertedCommand,this)}toInternal(c,v){if(!c)return;const g={$ident:void 0,id:c.command,title:c.title,tooltip:c.tooltip};if(!c.command)return g;const D=this._lookupApiCommand(c.command);if(D)g.id=D.internalId,g.arguments=D.args.map((U,W)=>U.convert(c.arguments&&c.arguments[W]));else if((0,T.isNonEmptyArray)(c.arguments)){const U=++this._cachIdPool;this._cache.set(U,c),v.add((0,I.toDisposable)(()=>{this._cache.delete(U),this._logService.trace("CommandsConverter#DISPOSE",U)})),g.$ident=U,g.id=this.delegatingCommandId,g.arguments=[U],this._logService.trace("CommandsConverter#CREATE",c.command,U)}return g}fromInternal(c){return typeof c.$ident=="number"?this._cache.get(c.$ident):{command:c.id,title:c.title,arguments:c.arguments}}getActualCommand(...c){return this._cache.get(c[0])}_executeConvertedCommand(...c){const v=this.getActualCommand(...c);return this._logService.trace("CommandsConverter#EXECUTE",c[0],v?v.command:"MISSING"),v?this._commands.executeCommand(v.command,...v.arguments||[]):Promise.reject("actual command NOT FOUND")}}e.CommandsConverter=u;class i{constructor(c,v,g,D){this.name=c,this.description=v,this.validate=g,this.convert=D}optional(){return new i(this.name,`(optional) ${this.description}`,c=>c==null||this.validate(c),c=>c===void 0?void 0:c===null?null:this.convert(c))}with(c,v){return new i(c??this.name,v??this.description,this.validate,this.convert)}}e.ApiCommandArgument=i,i.Uri=new i("uri","Uri of a text document",t=>m.URI.isUri(t),t=>t),i.Position=new i("position","A position in a text document",t=>p.Position.isPosition(t),b.Position.from),i.Range=new i("range","A range in a text document",t=>p.Range.isRange(t),b.Range.from),i.Selection=new i("selection","A selection in a text document",t=>p.Selection.isSelection(t),b.Selection.from),i.Number=new i("number","",t=>typeof t=="number",t=>t),i.String=new i("string","",t=>typeof t=="string",t=>t),i.CallHierarchyItem=new i("item","A call hierarchy item",t=>t instanceof p.CallHierarchyItem,b.CallHierarchyItem.from),i.TypeHierarchyItem=new i("item","A type hierarchy item",t=>t instanceof p.TypeHierarchyItem,b.TypeHierarchyItem.from),i.TestItem=new i("testItem","A VS Code TestItem",t=>t instanceof d.TestItemImpl,b.TestItem.from);class o{constructor(c,v){this.description=c,this.convert=v}}e.ApiCommandResult=o,o.Void=new o("no result",t=>t);class r{constructor(c,v,g,D,U){this.id=c,this.internalId=v,this.description=g,this.args=D,this.result=U}}e.ApiCommand=r}),define(ye[189],Ce([1,0,2,8,6,66,36,16,77,81,12]),function(ee,e,s,p,b,L,C,T,E,A,R){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.ExtHostApiCommands=void 0;const y=[new C.ApiCommand("vscode.executeDocumentHighlights","_executeDocumentHighlights","Execute document highlight provider.",[C.ApiCommandArgument.Uri,C.ApiCommandArgument.Position],new C.ApiCommandResult("A promise that resolves to an array of DocumentHighlight-instances.",I(p.DocumentHighlight.to))),new C.ApiCommand("vscode.executeDocumentSymbolProvider","_executeDocumentSymbolProvider","Execute document symbol provider.",[C.ApiCommandArgument.Uri],new C.ApiCommandResult("A promise that resolves to an array of SymbolInformation and DocumentSymbol instances.",(h,d)=>{if((0,T.isFalsyOrEmpty)(h))return;class a extends b.SymbolInformation{static to(P){const l=new a(P.name,p.SymbolKind.to(P.kind),P.containerName||"",new b.Location(d[0],p.Range.to(P.range)));return l.detail=P.detail,l.range=l.location.range,l.selectionRange=p.Range.to(P.selectionRange),l.children=P.children?P.children.map(a.to):[],l}}return h.map(a.to)})),new C.ApiCommand("vscode.executeFormatDocumentProvider","_executeFormatDocumentProvider","Execute document format provider.",[C.ApiCommandArgument.Uri,new C.ApiCommandArgument("options","Formatting options",h=>!0,h=>h)],new C.ApiCommandResult("A promise that resolves to an array of TextEdits.",I(p.TextEdit.to))),new C.ApiCommand("vscode.executeFormatRangeProvider","_executeFormatRangeProvider","Execute range format provider.",[C.ApiCommandArgument.Uri,C.ApiCommandArgument.Range,new C.ApiCommandArgument("options","Formatting options",h=>!0,h=>h)],new C.ApiCommandResult("A promise that resolves to an array of TextEdits.",I(p.TextEdit.to))),new C.ApiCommand("vscode.executeFormatOnTypeProvider","_executeFormatOnTypeProvider","Execute format on type provider.",[C.ApiCommandArgument.Uri,C.ApiCommandArgument.Position,new C.ApiCommandArgument("ch","Trigger character",h=>typeof h=="string",h=>h),new C.ApiCommandArgument("options","Formatting options",h=>!0,h=>h)],new C.ApiCommandResult("A promise that resolves to an array of TextEdits.",I(p.TextEdit.to))),new C.ApiCommand("vscode.executeDefinitionProvider","_executeDefinitionProvider","Execute all definition providers.",[C.ApiCommandArgument.Uri,C.ApiCommandArgument.Position],new C.ApiCommandResult("A promise that resolves to an array of Location or LocationLink instances.",f)),new C.ApiCommand("vscode.executeTypeDefinitionProvider","_executeTypeDefinitionProvider","Execute all type definition providers.",[C.ApiCommandArgument.Uri,C.ApiCommandArgument.Position],new C.ApiCommandResult("A promise that resolves to an array of Location or LocationLink instances.",f)),new C.ApiCommand("vscode.executeDeclarationProvider","_executeDeclarationProvider","Execute all declaration providers.",[C.ApiCommandArgument.Uri,C.ApiCommandArgument.Position],new C.ApiCommandResult("A promise that resolves to an array of Location or LocationLink instances.",f)),new C.ApiCommand("vscode.executeImplementationProvider","_executeImplementationProvider","Execute all implementation providers.",[C.ApiCommandArgument.Uri,C.ApiCommandArgument.Position],new C.ApiCommandResult("A promise that resolves to an array of Location or LocationLink instances.",f)),new C.ApiCommand("vscode.executeReferenceProvider","_executeReferenceProvider","Execute all reference providers.",[C.ApiCommandArgument.Uri,C.ApiCommandArgument.Position],new C.ApiCommandResult("A promise that resolves to an array of Location-instances.",I(p.location.to))),new C.ApiCommand("vscode.executeHoverProvider","_executeHoverProvider","Execute all hover providers.",[C.ApiCommandArgument.Uri,C.ApiCommandArgument.Position],new C.ApiCommandResult("A promise that resolves to an array of Hover-instances.",I(p.Hover.to))),new C.ApiCommand("vscode.executeSelectionRangeProvider","_executeSelectionRangeProvider","Execute selection range provider.",[C.ApiCommandArgument.Uri,new C.ApiCommandArgument("position","A position in a text document",h=>Array.isArray(h)&&h.every(d=>b.Position.isPosition(d)),h=>h.map(p.Position.from))],new C.ApiCommandResult("A promise that resolves to an array of ranges.",h=>h.map(d=>{let a;for(const w of d.reverse())a=new b.SelectionRange(p.Range.to(w),a);return a}))),new C.ApiCommand("vscode.executeWorkspaceSymbolProvider","_executeWorkspaceSymbolProvider","Execute all workspace symbol providers.",[C.ApiCommandArgument.String.with("query","Search string")],new C.ApiCommandResult("A promise that resolves to an array of SymbolInformation-instances.",h=>h.map(p.WorkspaceSymbol.to))),new C.ApiCommand("vscode.prepareCallHierarchy","_executePrepareCallHierarchy","Prepare call hierarchy at a position inside a document",[C.ApiCommandArgument.Uri,C.ApiCommandArgument.Position],new C.ApiCommandResult("A CallHierarchyItem or undefined",h=>h.map(p.CallHierarchyItem.to))),new C.ApiCommand("vscode.provideIncomingCalls","_executeProvideIncomingCalls","Compute incoming calls for an item",[C.ApiCommandArgument.CallHierarchyItem],new C.ApiCommandResult("A CallHierarchyItem or undefined",h=>h.map(p.CallHierarchyIncomingCall.to))),new C.ApiCommand("vscode.provideOutgoingCalls","_executeProvideOutgoingCalls","Compute outgoing calls for an item",[C.ApiCommandArgument.CallHierarchyItem],new C.ApiCommandResult("A CallHierarchyItem or undefined",h=>h.map(p.CallHierarchyOutgoingCall.to))),new C.ApiCommand("vscode.prepareRename","_executePrepareRename","Execute the prepareRename of rename provider.",[C.ApiCommandArgument.Uri,C.ApiCommandArgument.Position],new C.ApiCommandResult("A promise that resolves to a range and placeholder text.",h=>{if(!!h)return{range:p.Range.to(h.range),placeholder:h.text}})),new C.ApiCommand("vscode.executeDocumentRenameProvider","_executeDocumentRenameProvider","Execute rename provider.",[C.ApiCommandArgument.Uri,C.ApiCommandArgument.Position,C.ApiCommandArgument.String.with("newName","The new symbol name")],new C.ApiCommandResult("A promise that resolves to a WorkspaceEdit.",h=>{if(!!h){if(h.rejectReason)throw new Error(h.rejectReason);return p.WorkspaceEdit.to(h)}})),new C.ApiCommand("vscode.executeLinkProvider","_executeLinkProvider","Execute document link provider.",[C.ApiCommandArgument.Uri,C.ApiCommandArgument.Number.with("linkResolveCount","Number of links that should be resolved, only when links are unresolved.").optional()],new C.ApiCommandResult("A promise that resolves to an array of DocumentLink-instances.",h=>h.map(p.DocumentLink.to))),new C.ApiCommand("vscode.provideDocumentSemanticTokensLegend","_provideDocumentSemanticTokensLegend","Provide semantic tokens legend for a document",[C.ApiCommandArgument.Uri],new C.ApiCommandResult("A promise that resolves to SemanticTokensLegend.",h=>{if(!!h)return new b.SemanticTokensLegend(h.tokenTypes,h.tokenModifiers)})),new C.ApiCommand("vscode.provideDocumentSemanticTokens","_provideDocumentSemanticTokens","Provide semantic tokens for a document",[C.ApiCommandArgument.Uri],new C.ApiCommandResult("A promise that resolves to SemanticTokens.",h=>{if(!h)return;const d=(0,E.decodeSemanticTokensDto)(h);if(d.type==="full")return new b.SemanticTokens(d.data,void 0)})),new C.ApiCommand("vscode.provideDocumentRangeSemanticTokensLegend","_provideDocumentRangeSemanticTokensLegend","Provide semantic tokens legend for a document range",[C.ApiCommandArgument.Uri,C.ApiCommandArgument.Range.optional()],new C.ApiCommandResult("A promise that resolves to SemanticTokensLegend.",h=>{if(!!h)return new b.SemanticTokensLegend(h.tokenTypes,h.tokenModifiers)})),new C.ApiCommand("vscode.provideDocumentRangeSemanticTokens","_provideDocumentRangeSemanticTokens","Provide semantic tokens for a document range",[C.ApiCommandArgument.Uri,C.ApiCommandArgument.Range],new C.ApiCommandResult("A promise that resolves to SemanticTokens.",h=>{if(!h)return;const d=(0,E.decodeSemanticTokensDto)(h);if(d.type==="full")return new b.SemanticTokens(d.data,void 0)})),new C.ApiCommand("vscode.executeCompletionItemProvider","_executeCompletionItemProvider","Execute completion item provider.",[C.ApiCommandArgument.Uri,C.ApiCommandArgument.Position,C.ApiCommandArgument.String.with("triggerCharacter","Trigger completion when the user types the character, like `,` or `(`").optional(),C.ApiCommandArgument.Number.with("itemResolveCount","Number of completions to resolve (too large numbers slow down completions)").optional()],new C.ApiCommandResult("A promise that resolves to a CompletionList-instance.",(h,d,a)=>{if(!h)return new b.CompletionList([]);const w=h.suggestions.map(P=>p.CompletionItem.to(P,a));return new b.CompletionList(w,h.incomplete)})),new C.ApiCommand("vscode.executeSignatureHelpProvider","_executeSignatureHelpProvider","Execute signature help provider.",[C.ApiCommandArgument.Uri,C.ApiCommandArgument.Position,C.ApiCommandArgument.String.with("triggerCharacter","Trigger signature help when the user types the character, like `,` or `(`").optional()],new C.ApiCommandResult("A promise that resolves to SignatureHelp.",h=>{if(h)return p.SignatureHelp.to(h)})),new C.ApiCommand("vscode.executeCodeLensProvider","_executeCodeLensProvider","Execute code lens provider.",[C.ApiCommandArgument.Uri,C.ApiCommandArgument.Number.with("itemResolveCount","Number of lenses that should be resolved and returned. Will only return resolved lenses, will impact performance)").optional()],new C.ApiCommandResult("A promise that resolves to an array of CodeLens-instances.",(h,d,a)=>I(w=>new b.CodeLens(p.Range.to(w.range),w.command&&a.fromInternal(w.command)))(h))),new C.ApiCommand("vscode.executeCodeActionProvider","_executeCodeActionProvider","Execute code action provider.",[C.ApiCommandArgument.Uri,new C.ApiCommandArgument("rangeOrSelection","Range in a text document. Some refactoring provider requires Selection object.",h=>b.Range.isRange(h),h=>b.Selection.isSelection(h)?p.Selection.from(h):p.Range.from(h)),C.ApiCommandArgument.String.with("kind","Code action kind to return code actions for").optional(),C.ApiCommandArgument.Number.with("itemResolveCount","Number of code actions to resolve (too large numbers slow down code actions)").optional()],new C.ApiCommandResult("A promise that resolves to an array of Command-instances.",(h,d,a)=>I(w=>{if(w._isSynthetic){if(!w.command)throw new Error("Synthetic code actions must have a command");return a.fromInternal(w.command)}else{const P=new b.CodeAction(w.title,w.kind?new b.CodeActionKind(w.kind):void 0);return w.edit&&(P.edit=p.WorkspaceEdit.to(w.edit)),w.command&&(P.command=a.fromInternal(w.command)),P.isPreferred=w.isPreferred,P}})(h))),new C.ApiCommand("vscode.executeDocumentColorProvider","_executeDocumentColorProvider","Execute document color provider.",[C.ApiCommandArgument.Uri],new C.ApiCommandResult("A promise that resolves to an array of ColorInformation objects.",h=>h?h.map(d=>new b.ColorInformation(p.Range.to(d.range),p.Color.to(d.color))):[])),new C.ApiCommand("vscode.executeColorPresentationProvider","_executeColorPresentationProvider","Execute color presentation provider.",[new C.ApiCommandArgument("color","The color to show and insert",h=>h instanceof b.Color,p.Color.from),new C.ApiCommandArgument("context","Context object with uri and range",h=>!0,h=>({uri:h.uri,range:p.Range.from(h.range)}))],new C.ApiCommandResult("A promise that resolves to an array of ColorPresentation objects.",h=>h?h.map(p.ColorPresentation.to):[])),new C.ApiCommand("vscode.executeInlayHintProvider","_executeInlayHintProvider","Execute inlay hints provider",[C.ApiCommandArgument.Uri,C.ApiCommandArgument.Range],new C.ApiCommandResult("A promise that resolves to an array of Inlay objects",(h,d,a)=>h.map(p.InlayHint.to.bind(void 0,a)))),new C.ApiCommand("vscode.resolveNotebookContentProviders","_resolveNotebookContentProvider","Resolve Notebook Content Providers",[],new C.ApiCommandResult("A promise that resolves to an array of NotebookContentProvider static info objects.",I(h=>({viewType:h.viewType,displayName:h.displayName,options:{transientOutputs:h.options.transientOutputs,transientCellMetadata:h.options.transientCellMetadata,transientDocumentMetadata:h.options.transientDocumentMetadata},filenamePattern:h.filenamePattern.map(d=>p.NotebookExclusiveDocumentPattern.to(d))})))),new C.ApiCommand("vscode.executeInlineValueProvider","_executeInlineValueProvider","Execute inline value provider",[C.ApiCommandArgument.Uri,C.ApiCommandArgument.Range],new C.ApiCommandResult("A promise that resolves to an array of InlineValue objects",h=>h.map(p.InlineValue.to))),new C.ApiCommand("vscode.open","_workbench.open","Opens the provided resource in the editor. Can be a text or binary file, or an http(s) URL. If you need more control over the options for opening a text file, use vscode.window.showTextDocument instead.",[new C.ApiCommandArgument("uriOrString","Uri-instance or string (only http/https)",h=>s.URI.isUri(h)||typeof h=="string"&&(0,A.matchesSomeScheme)(h,R.Schemas.http,R.Schemas.https),h=>h),new C.ApiCommandArgument("columnOrOptions","Either the column in which to open or editor options, see vscode.TextDocumentShowOptions",h=>h===void 0||typeof h=="number"||typeof h=="object",h=>h&&(typeof h=="number"?[p.ViewColumn.from(h),void 0]:[p.ViewColumn.from(h.viewColumn),p.TextEditorOpenOptions.from(h)])).optional(),C.ApiCommandArgument.String.with("label","").optional()],C.ApiCommandResult.Void),new C.ApiCommand("vscode.openWith","_workbench.openWith","Opens the provided resource with a specific editor.",[C.ApiCommandArgument.Uri.with("resource","Resource to open"),C.ApiCommandArgument.String.with("viewId","Custom editor view id or 'default' to use VS Code's default editor"),new C.ApiCommandArgument("columnOrOptions","Either the column in which to open or editor options, see vscode.TextDocumentShowOptions",h=>h===void 0||typeof h=="number"||typeof h=="object",h=>h&&(typeof h=="number"?[p.ViewColumn.from(h),void 0]:[p.ViewColumn.from(h.viewColumn),p.TextEditorOpenOptions.from(h)])).optional()],C.ApiCommandResult.Void),new C.ApiCommand("vscode.diff","_workbench.diff","Opens the provided resources in the diff editor to compare their contents.",[C.ApiCommandArgument.Uri.with("left","Left-hand side resource of the diff editor"),C.ApiCommandArgument.Uri.with("right","Right-hand side resource of the diff editor"),C.ApiCommandArgument.String.with("title","Human readable title for the diff editor").optional(),new C.ApiCommandArgument("columnOrOptions","Either the column in which to open or editor options, see vscode.TextDocumentShowOptions",h=>h===void 0||typeof h=="object",h=>h&&[p.ViewColumn.from(h.viewColumn),p.TextEditorOpenOptions.from(h)]).optional()],C.ApiCommandResult.Void),new C.ApiCommand("vscode.prepareTypeHierarchy","_executePrepareTypeHierarchy","Prepare type hierarchy at a position inside a document",[C.ApiCommandArgument.Uri,C.ApiCommandArgument.Position],new C.ApiCommandResult("A TypeHierarchyItem or undefined",h=>h.map(p.TypeHierarchyItem.to))),new C.ApiCommand("vscode.provideSupertypes","_executeProvideSupertypes","Compute supertypes for an item",[C.ApiCommandArgument.TypeHierarchyItem],new C.ApiCommandResult("A TypeHierarchyItem or undefined",h=>h.map(p.TypeHierarchyItem.to))),new C.ApiCommand("vscode.provideSubtypes","_executeProvideSubtypes","Compute subtypes for an item",[C.ApiCommandArgument.TypeHierarchyItem],new C.ApiCommandResult("A TypeHierarchyItem or undefined",h=>h.map(p.TypeHierarchyItem.to))),new C.ApiCommand("vscode.revealTestInExplorer","_revealTestInExplorer","Reveals a test instance in the explorer",[C.ApiCommandArgument.TestItem],C.ApiCommandResult.Void),new C.ApiCommand("vscode.experimental.editSession.continue","_workbench.experimental.editSessions.actions.continueEditSession","Continue the current edit session in a different workspace",[C.ApiCommandArgument.Uri.with("workspaceUri","The target workspace to continue the current edit session in")],C.ApiCommandResult.Void)];class m{static register(d){y.forEach(d.registerApiCommand,d)}}e.ExtHostApiCommands=m;function I(h){return d=>{if(Array.isArray(d))return d.map(h)}}function f(h){if(!Array.isArray(h))return;const d=[];for(const a of h)L.isLocationLink(a)?d.push(p.DefinitionLink.to(a)):d.push(p.location.to(a));return d}}),define(ye[190],Ce([1,0,13,54,4,7,2,66,27,8,6,24,5]),function(ee,e,s,p,b,L,C,T,E,A,R,y,m){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.createExtHostComments=void 0;function I(f,h,d){const a=f.getProxy(m.MainContext.MainThreadComments);class w{constructor(){this._commentControllers=new Map,this._commentControllersByExtension=new Map,h.registerArgumentProcessor({processArgument:t=>{if(t&&t.$mid===6){const c=this._commentControllers.get(t.handle);return c?c.value:t}else if(t&&t.$mid===7){const c=this._commentControllers.get(t.commentControlHandle);if(!c)return t;const v=c.getCommentThread(t.commentThreadHandle);return v?v.value:t}else if(t&&t.$mid===8){const c=this._commentControllers.get(t.thread.commentControlHandle);if(!c)return t;const v=c.getCommentThread(t.thread.commentThreadHandle);return v?{thread:v.value,text:t.text}:t}else if(t&&t.$mid===9){const c=this._commentControllers.get(t.thread.commentControlHandle);if(!c)return t;const v=c.getCommentThread(t.thread.commentThreadHandle);if(!v)return t;const g=t.commentUniqueId,D=v.getCommentByUniqueId(g);return D||t}else if(t&&t.$mid===10){const c=this._commentControllers.get(t.thread.commentControlHandle);if(!c)return t;const v=c.getCommentThread(t.thread.commentThreadHandle);if(!v)return t;const g=t.text,D=t.commentUniqueId,U=v.getCommentByUniqueId(D);return U?(U.body=g,U):t}return t}})}createCommentController(t,c,v){const g=w.handlePool++,D=new l(t,g,c,v);this._commentControllers.set(D.handle,D);const U=this._commentControllersByExtension.get(E.ExtensionIdentifier.toKey(t.identifier))||[];return U.push(D),this._commentControllersByExtension.set(E.ExtensionIdentifier.toKey(t.identifier),U),D.value}$createCommentThreadTemplate(t,c,v){const g=this._commentControllers.get(t);!g||g.$createCommentThreadTemplate(c,v)}async $updateCommentThreadTemplate(t,c,v){const g=this._commentControllers.get(t);!g||g.$updateCommentThreadTemplate(c,v)}$deleteCommentThread(t,c){this._commentControllers.get(t)?.$deleteCommentThread(c)}$provideCommentingRanges(t,c,v){const g=this._commentControllers.get(t);if(!g||!g.commentingRangeProvider)return Promise.resolve(void 0);const D=d.getDocument(C.URI.revive(c));return(0,s.asPromise)(()=>g.commentingRangeProvider.provideCommentingRanges(D,v)).then(U=>U?U.map(W=>A.Range.from(W)):void 0)}$toggleReaction(t,c,v,g,D){const U=this._commentControllers.get(t);return!U||!U.reactionHandler?Promise.resolve(void 0):(0,s.asPromise)(()=>{const W=U.getCommentThread(c);if(W){const M=W.getCommentByUniqueId(g.uniqueIdInThread);if(U!==void 0&&M&&U.reactionHandler)return U.reactionHandler(M,u(D))}return Promise.resolve(void 0)})}dispose(){}}w.handlePool=0;class P{constructor(t,c,v,g,D,U,W,M){this._commentControllerHandle=c,this._id=v,this._uri=g,this._range=D,this._comments=U,this.extensionDescription=W,this._isTemplate=M,this.handle=P._handlePool++,this.commentHandle=0,this.modifications=Object.create(null),this._onDidUpdateCommentThread=new b.Emitter,this.onDidUpdateCommentThread=this._onDidUpdateCommentThread.event,this._canReply=!0,this._commentsMap=new Map,this._acceptInputDisposables=new L.MutableDisposable,this._acceptInputDisposables.value=new L.DisposableStore,this._id===void 0&&(this._id=`${t}.${this.handle}`),a.$createCommentThread(c,this.handle,this._id,this._uri,A.Range.from(this._range),W.identifier,this._isTemplate),this._localDisposables=[],this._isDiposed=!1,this._localDisposables.push(this.onDidUpdateCommentThread(()=>{this.eventuallyUpdateCommentThread()})),this.comments=U,this._localDisposables.push({dispose:()=>{a.$deleteCommentThread(c,this.handle)}});const S=this;this.value={get uri(){return S.uri},get range(){return S.range},set range(z){S.range=z},get comments(){return S.comments},set comments(z){S.comments=z},get collapsibleState(){return S.collapsibleState},set collapsibleState(z){S.collapsibleState=z},get canReply(){return S.canReply},set canReply(z){S.canReply=z},get contextValue(){return S.contextValue},set contextValue(z){S.contextValue=z},get label(){return S.label},set label(z){S.label=z},get state(){return S.state},set state(z){S.state=z},dispose:()=>{S.dispose()}}}set threadId(t){this._id=t}get threadId(){return this._id}get id(){return this._id}get resource(){return this._uri}get uri(){return this._uri}set range(t){t.isEqual(this._range)||(this._range=t,this.modifications.range=t,this._onDidUpdateCommentThread.fire())}get range(){return this._range}set canReply(t){this._canReply!==t&&(this._canReply=t,this.modifications.canReply=t,this._onDidUpdateCommentThread.fire())}get canReply(){return this._canReply}get label(){return this._label}set label(t){this._label=t,this.modifications.label=t,this._onDidUpdateCommentThread.fire()}get contextValue(){return this._contextValue}set contextValue(t){this._contextValue=t,this.modifications.contextValue=t,this._onDidUpdateCommentThread.fire()}get comments(){return this._comments}set comments(t){this._comments=t,this.modifications.comments=t,this._onDidUpdateCommentThread.fire()}get collapsibleState(){return this._collapseState}set collapsibleState(t){this._collapseState=t,this.modifications.collapsibleState=t,this._onDidUpdateCommentThread.fire()}get state(){return(0,y.checkProposedApiEnabled)(this.extensionDescription,"commentsResolvedState"),this._state}set state(t){(0,y.checkProposedApiEnabled)(this.extensionDescription,"commentsResolvedState"),this._state=t,this.modifications.state=t,this._onDidUpdateCommentThread.fire()}get isDisposed(){return this._isDiposed}updateIsTemplate(){this._isTemplate&&(this._isTemplate=!1,this.modifications.isTemplate=!1)}eventuallyUpdateCommentThread(){if(this._isDiposed)return;this.updateIsTemplate(),this._acceptInputDisposables.value||(this._acceptInputDisposables.value=new L.DisposableStore);const t=v=>Object.prototype.hasOwnProperty.call(this.modifications,v),c={};t("range")&&(c.range=A.Range.from(this._range)),t("label")&&(c.label=this.label),t("contextValue")&&(c.contextValue=this.contextValue??null),t("comments")&&(c.comments=this._comments.map(v=>_(this,v,this._commentsMap))),t("collapsibleState")&&(c.collapseState=i(this._collapseState)),t("canReply")&&(c.canReply=this.canReply),t("state")&&(c.state=o(this._state)),t("isTemplate")&&(c.isTemplate=this._isTemplate),this.modifications={},a.$updateCommentThread(this._commentControllerHandle,this.handle,this._id,this._uri,c)}getCommentByUniqueId(t){for(const c of this._commentsMap){const v=c[0],g=c[1];if(t===g)return v}}dispose(){this._isDiposed=!0,this._acceptInputDisposables.dispose(),this._localDisposables.forEach(t=>t.dispose())}}P._handlePool=0,ze([(0,p.debounce)(100)],P.prototype,"eventuallyUpdateCommentThread",null);class l{constructor(t,c,v,g){this._extension=t,this._handle=c,this._id=v,this._label=g,this._threads=new Map,a.$registerCommentController(this.handle,v,g);const D=this;this.value=Object.freeze({id:D.id,label:D.label,get options(){return D.options},set options(U){D.options=U},get commentingRangeProvider(){return D.commentingRangeProvider},set commentingRangeProvider(U){D.commentingRangeProvider=U},get reactionHandler(){return D.reactionHandler},set reactionHandler(U){D.reactionHandler=U},createCommentThread(U,W,M){return D.createCommentThread(U,W,M).value},dispose:()=>{D.dispose()}}),this._localDisposables=[],this._localDisposables.push({dispose:()=>{a.$unregisterCommentController(this.handle)}})}get id(){return this._id}get label(){return this._label}get handle(){return this._handle}get commentingRangeProvider(){return this._commentingRangeProvider}set commentingRangeProvider(t){this._commentingRangeProvider=t,a.$updateCommentingRanges(this.handle)}get reactionHandler(){return this._reactionHandler}set reactionHandler(t){this._reactionHandler=t,a.$updateCommentControllerFeatures(this.handle,{reactionHandler:!!t})}get options(){return this._options}set options(t){this._options=t,a.$updateCommentControllerFeatures(this.handle,{options:this._options})}createCommentThread(t,c,v,g){if(typeof t=="string"){const D=new P(this.id,this.handle,t,c,v,g,this._extension,!1);return this._threads.set(D.handle,D),D}else{const D=new P(this.id,this.handle,void 0,t,c,v,this._extension,!1);return this._threads.set(D.handle,D),D}}$createCommentThreadTemplate(t,c){const v=new P(this.id,this.handle,void 0,C.URI.revive(t),A.Range.to(c),[],this._extension,!0);return v.collapsibleState=T.CommentThreadCollapsibleState.Expanded,this._threads.set(v.handle,v),v}$updateCommentThreadTemplate(t,c){const v=this._threads.get(t);v&&(v.range=A.Range.to(c))}$deleteCommentThread(t){const c=this._threads.get(t);c&&c.dispose(),this._threads.delete(t)}getCommentThread(t){return this._threads.get(t)}dispose(){this._threads.forEach(t=>{t.dispose()}),this._localDisposables.forEach(t=>t.dispose())}}function _(r,t,c){let v=c.get(t);v||(v=++r.commentHandle,c.set(t,v));const g=t.author&&t.author.iconPath?t.author.iconPath.toString():void 0;return{mode:t.mode,contextValue:t.contextValue,uniqueIdInThread:v,body:typeof t.body=="string"?t.body:A.MarkdownString.from(t.body),userName:t.author.name,userIconPath:g,label:t.label,commentReactions:t.reactions?t.reactions.map(D=>n(D)):void 0,timestamp:t.timestamp?.toJSON()}}function n(r){return{label:r.label,iconPath:r.iconPath?A.pathOrURIToURI(r.iconPath):void 0,count:r.count,hasReacted:r.authorHasReacted}}function u(r){return{label:r.label||"",count:r.count||0,iconPath:r.iconPath?C.URI.revive(r.iconPath):"",authorHasReacted:r.hasReacted||!1}}function i(r){if(r!==void 0)switch(r){case R.CommentThreadCollapsibleState.Expanded:return T.CommentThreadCollapsibleState.Expanded;case R.CommentThreadCollapsibleState.Collapsed:return T.CommentThreadCollapsibleState.Collapsed}return T.CommentThreadCollapsibleState.Collapsed}function o(r){if(r!==void 0)switch(r){case R.CommentThreadState.Unresolved:return T.CommentThreadState.Unresolved;case R.CommentThreadState.Resolved:return T.CommentThreadState.Resolved}return T.CommentThreadState.Unresolved}return new w}e.createExtHostComments=I}),define(ye[191],Ce([1,0,26,5,28,15]),function(ee,e,s,p,b,L){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.AbstractExtHostConsoleForwarder=void 0;let C=class{constructor(R,y){this._mainThreadConsole=R.getProxy(p.MainContext.MainThreadConsole),this._includeStack=y.consoleForward.includeStack,this._logNative=y.consoleForward.logNative,this._wrapConsoleMethod("info","log"),this._wrapConsoleMethod("log","log"),this._wrapConsoleMethod("warn","warn"),this._wrapConsoleMethod("error","error")}_wrapConsoleMethod(R,y){const m=this,I=console[R];Object.defineProperty(console,R,{set:()=>{},get:()=>function(){m._handleConsoleCall(R,y,I,arguments)}})}_handleConsoleCall(R,y,m,I){this._mainThreadConsole.$logExtensionHostMessage({type:"__$console",severity:y,arguments:E(I,this._includeStack)}),this._logNative&&this._nativeConsoleLogMessage(R,m,I)}};C=ze([xe(0,L.IExtHostRpcService),xe(1,b.IExtHostInitDataService)],C),e.AbstractExtHostConsoleForwarder=C;const T=1e5;function E(A,R){const y=[];if(A.length)for(let m=0;m<A.length;m++){let I=A[m];if(typeof I=="undefined")I="undefined";else if(I instanceof Error){const f=I;f.stack?I=f.stack:I=f.toString()}y.push(I)}if(R){const m=new Error().stack;m&&y.push({__$stack:m.split(`
`).slice(3).join(`
`)})}try{const m=(0,s.safeStringify)(y);return m.length>T?"Output omitted for a large object that exceeds the limits":m}catch(m){return`Output omitted for an object that cannot be inspected ('${m.toString()}')`}}}),define(ye[95],Ce([1,0,2,5,6,3,15,14,16,9,19]),function(ee,e,s,p,b,L,C,T,E,A,R){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.IExtHostDecorations=e.ExtHostDecorations=void 0;let y=class Ii{constructor(I,f){this._logService=f,this._provider=new Map,this._proxy=I.getProxy(p.MainContext.MainThreadDecorations)}registerFileDecorationProvider(I,f){const h=Ii._handlePool++;this._provider.set(h,{provider:I,extensionId:f}),this._proxy.$registerDecorationProvider(h,f.value);const d=I.onDidChangeFileDecorations&&I.onDidChangeFileDecorations(a=>{if(!a){this._proxy.$onDidChange(h,null);return}const w=(0,E.asArray)(a);if(w.length<=Ii._maxEventSize){this._proxy.$onDidChange(h,w);return}this._logService.warn("[Decorations] CAPPING events from decorations provider",f.value,w.length);const P=w.map(n=>({uri:n,rank:(0,A.count)(n.path,"/")})),l=(0,E.groupBy)(P,(n,u)=>n.rank-u.rank||(0,A.compare)(n.uri.path,u.uri.path)),_=[];e:for(const n of l){let u;for(const i of n){const o=(0,R.dirname)(i.uri.path);if(u!==o&&(u=o,_.push(i.uri)>=Ii._maxEventSize))break e}}this._proxy.$onDidChange(h,_)});return new b.Disposable(()=>{d?.dispose(),this._proxy.$unregisterDecorationProvider(h),this._provider.delete(h)})}async $provideDecorations(I,f,h){if(!this._provider.has(I))return Object.create(null);const d=Object.create(null),{provider:a,extensionId:w}=this._provider.get(I);return await Promise.all(f.map(async P=>{try{const{uri:l,id:_}=P,n=await Promise.resolve(a.provideFileDecoration(s.URI.revive(l),h));if(!n)return;try{b.FileDecoration.validate(n),d[_]=[n.propagate,n.tooltip,n.badge,n.color]}catch(u){this._logService.warn(`INVALID decoration from extension '${w.value}': ${u}`)}}catch(l){this._logService.error(l)}})),d}};y._handlePool=0,y._maxEventSize=250,y=ze([xe(0,C.IExtHostRpcService),xe(1,T.ILogService)],y),e.ExtHostDecorations=y,e.IExtHostDecorations=(0,L.createDecorator)("IExtHostDecorations")});var Je=this&&this.__classPrivateFieldSet||function(ee,e,s,p,b){if(p==="m")throw new TypeError("Private method is not writable");if(p==="a"&&!b)throw new TypeError("Private accessor was defined without a setter");if(typeof e=="function"?ee!==e||!b:!e.has(ee))throw new TypeError("Cannot write private member to an object whose class did not declare it");return p==="a"?b.call(ee,s):b?b.value=s:e.set(ee,s),s},Ae=this&&this.__classPrivateFieldGet||function(ee,e,s,p){if(s==="a"&&!p)throw new TypeError("Private accessor was defined without a getter");if(typeof e=="function"?ee!==e||!p:!e.has(ee))throw new TypeError("Cannot read private member from an object whose class did not declare it");return s==="m"?p:s==="a"?p.call(ee):p?p.value:e.get(ee)};define(ye[192],Ce([1,0,128,80,2,5,6,8,4,14,25,35]),function(ee,e,s,p,b,L,C,T,E,A,R,y){"use strict";var m,I,f;Object.defineProperty(e,"__esModule",{value:!0}),e.ExtHostDiagnostics=e.DiagnosticCollection=void 0;class h{constructor(w,P,l,_,n,u){this._name=w,this._owner=P,this._maxDiagnosticsPerFile=l,m.set(this,void 0),I.set(this,void 0),f.set(this,void 0),this._isDisposed=!1,Je(this,f,new R.ResourceMap(i=>_.getComparisonKey(i)),"f"),Je(this,m,n,"f"),Je(this,I,u,"f")}dispose(){this._isDisposed||(Ae(this,I,"f").fire([...Ae(this,f,"f").keys()]),Ae(this,m,"f")?.$clear(this._owner),Ae(this,f,"f").clear(),this._isDisposed=!0)}get name(){return this._checkDisposed(),this._name}set(w,P){if(!w){this.clear();return}this._checkDisposed();let l=[];if(b.URI.isUri(w)){if(!P){this.delete(w);return}Ae(this,f,"f").set(w,P.slice()),l=[w]}else if(Array.isArray(w)){l=[];let n;w=[...w].sort(h._compareIndexedTuplesByUri);for(const u of w){const[i,o]=u;if((!n||i.toString()!==n.toString())&&(n&&Ae(this,f,"f").get(n).length===0&&Ae(this,f,"f").delete(n),n=i,l.push(i),Ae(this,f,"f").set(i,[])),o)Ae(this,f,"f").get(i)?.push(...o);else{const r=Ae(this,f,"f").get(i);r&&(r.length=0)}}}if(Ae(this,I,"f").fire(l),!Ae(this,m,"f"))return;const _=[];for(const n of l){let u=[];const i=Ae(this,f,"f").get(n);if(i)if(i.length>this._maxDiagnosticsPerFile){u=[];const o=[C.DiagnosticSeverity.Error,C.DiagnosticSeverity.Warning,C.DiagnosticSeverity.Information,C.DiagnosticSeverity.Hint];e:for(let r=0;r<4;r++)for(const t of i)if(t.severity===o[r]&&u.push(T.Diagnostic.from(t))===this._maxDiagnosticsPerFile)break e;u.push({severity:p.MarkerSeverity.Info,message:(0,s.localize)(0,null,i.length-this._maxDiagnosticsPerFile),startLineNumber:u[u.length-1].startLineNumber,startColumn:u[u.length-1].startColumn,endLineNumber:u[u.length-1].endLineNumber,endColumn:u[u.length-1].endColumn})}else u=i.map(o=>T.Diagnostic.from(o));_.push([n,u])}Ae(this,m,"f").$changeMany(this._owner,_)}delete(w){this._checkDisposed(),Ae(this,I,"f").fire([w]),Ae(this,f,"f").delete(w),Ae(this,m,"f")?.$changeMany(this._owner,[[w,void 0]])}clear(){this._checkDisposed(),Ae(this,I,"f").fire([...Ae(this,f,"f").keys()]),Ae(this,f,"f").clear(),Ae(this,m,"f")?.$clear(this._owner)}forEach(w,P){this._checkDisposed();for(const[l,_]of this)w.call(P,l,_,this)}*[(m=new WeakMap,I=new WeakMap,f=new WeakMap,Symbol.iterator)](){this._checkDisposed();for(const w of Ae(this,f,"f").keys())yield[w,this.get(w)]}get(w){this._checkDisposed();const P=Ae(this,f,"f").get(w);return Array.isArray(P)?Object.freeze(P.slice(0)):[]}has(w){return this._checkDisposed(),Array.isArray(Ae(this,f,"f").get(w))}_checkDisposed(){if(this._isDisposed)throw new Error("illegal state - object is disposed")}static _compareIndexedTuplesByUri(w,P){return w[0].toString()<P[0].toString()?-1:w[0].toString()>P[0].toString()?1:0}}e.DiagnosticCollection=h;let d=class di{constructor(w,P,l){this._logService=P,this._fileSystemInfoService=l,this._collections=new Map,this._onDidChangeDiagnostics=new E.DebounceEmitter({merge:_=>_.flat(),delay:50}),this.onDidChangeDiagnostics=E.Event.map(this._onDidChangeDiagnostics.event,di._mapper),this._proxy=w.getProxy(L.MainContext.MainThreadDiagnostics)}static _mapper(w){const P=new R.ResourceMap;for(const l of w)P.set(l,l);return{uris:Object.freeze(Array.from(P.values()))}}createDiagnosticCollection(w,P){const{_collections:l,_proxy:_,_onDidChangeDiagnostics:n,_logService:u,_fileSystemInfoService:i}=this,o=new class{$changeMany(c,v){_.$changeMany(c,v),u.trace("[DiagnosticCollection] change many (extension, owner, uris)",w.value,c,v.length===0?"CLEARING":v)}$clear(c){_.$clear(c),u.trace("[DiagnosticCollection] remove all (extension, owner)",w.value,c)}dispose(){_.dispose()}};let r;if(!P)P="_generated_diagnostic_collection_name_#"+di._idPool++,r=P;else if(!l.has(P))r=P;else{this._logService.warn(`DiagnosticCollection with name '${P}' does already exist.`);do r=P+di._idPool++;while(l.has(r))}return new class extends h{constructor(){super(P,r,di._maxDiagnosticsPerFile,i.extUri,o,n);l.set(r,this)}dispose(){super.dispose(),l.delete(r)}}}getDiagnostics(w){if(w)return this._getDiagnostics(w);{const P=new Map,l=[];for(const _ of this._collections.values())_.forEach((n,u)=>{let i=P.get(n.toString());typeof i=="undefined"&&(i=l.length,P.set(n.toString(),i),l.push([n,[]])),l[i][1]=l[i][1].concat(...u)});return l}}_getDiagnostics(w){let P=[];for(const l of this._collections.values())l.has(w)&&(P=P.concat(l.get(w)));return P}$acceptMarkersChange(w){if(!this._mirrorCollection){const P="_generated_mirror",l=new h(P,P,di._maxDiagnosticsPerFile,this._fileSystemInfoService.extUri,void 0,this._onDidChangeDiagnostics);this._collections.set(P,l),this._mirrorCollection=l}for(const[P,l]of w)this._mirrorCollection.set(b.URI.revive(P),l.map(T.Diagnostic.to))}};d._idPool=0,d._maxDiagnosticsPerFile=1e3,d=ze([xe(1,A.ILogService),xe(2,y.IExtHostFileSystemInfo)],d),e.ExtHostDiagnostics=d}),define(ye[193],Ce([1,0,2,5]),function(ee,e,s,p){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.ExtHostDialogs=void 0;class b{constructor(C){this._proxy=C.getProxy(p.MainContext.MainThreadDialogs)}showOpenDialog(C){return this._proxy.$showOpenDialog(C).then(T=>T?T.map(E=>s.URI.revive(E)):void 0)}showSaveDialog(C){return this._proxy.$showSaveDialog(C).then(T=>T?s.URI.revive(T):void 0)}}e.ExtHostDialogs=b}),define(ye[194],Ce([1,0,11,2,6,5,12,20,9]),function(ee,e,s,p,b,L,C,T,E){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.ExtHostDocumentContentProvider=void 0;class A{constructor(y,m,I){this._documentsAndEditors=m,this._logService=I,this._documentContentProviders=new Map,this._proxy=y.getProxy(L.MainContext.MainThreadDocumentContentProviders)}registerTextDocumentContentProvider(y,m){if(Object.keys(C.Schemas).indexOf(y)>=0)throw new Error(`scheme '${y}' already registered`);const I=A._handlePool++;this._documentContentProviders.set(I,m),this._proxy.$registerTextContentProvider(I,y);let f;return typeof m.onDidChange=="function"&&(f=m.onDidChange(h=>{if(h.scheme!==y){this._logService.warn(`Provider for scheme '${y}' is firing event for schema '${h.scheme}' which will be IGNORED`);return}this._documentsAndEditors.getDocument(h)&&this.$provideTextDocumentContent(I,h).then(d=>{if(!d&&typeof d!="string")return;const a=this._documentsAndEditors.getDocument(h);if(!a)return;const w=(0,E.splitLines)(d);if(!a.equalLines(w))return this._proxy.$onVirtualDocumentChange(h,d)},s.onUnexpectedError)})),new b.Disposable(()=>{this._documentContentProviders.delete(I)&&this._proxy.$unregisterTextContentProvider(I),f&&(f.dispose(),f=void 0)})}$provideTextDocumentContent(y,m){const I=this._documentContentProviders.get(y);return I?Promise.resolve(I.provideTextDocumentContent(p.URI.revive(m),T.CancellationToken.None)):Promise.reject(new Error(`unsupported uri-scheme: ${m.scheme}`))}}e.ExtHostDocumentContentProvider=A,A._handlePool=0}),define(ye[195],Ce([1,0,4,7,2,5,87,8,10,26,6]),function(ee,e,s,p,b,L,C,T,E,A,R){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.ExtHostDocuments=void 0;class y{constructor(I,f){this._onDidAddDocument=new s.Emitter,this._onDidRemoveDocument=new s.Emitter,this._onDidChangeDocument=new s.Emitter,this._onDidSaveDocument=new s.Emitter,this.onDidAddDocument=this._onDidAddDocument.event,this.onDidRemoveDocument=this._onDidRemoveDocument.event,this.onDidChangeDocument=this._onDidChangeDocument.event,this.onDidSaveDocument=this._onDidSaveDocument.event,this._toDispose=new p.DisposableStore,this._documentLoader=new Map,this._proxy=I.getProxy(L.MainContext.MainThreadDocuments),this._documentsAndEditors=f,this._documentsAndEditors.onDidRemoveDocuments(h=>{for(const d of h)this._onDidRemoveDocument.fire(d.document)},void 0,this._toDispose),this._documentsAndEditors.onDidAddDocuments(h=>{for(const d of h)this._onDidAddDocument.fire(d.document)},void 0,this._toDispose)}dispose(){this._toDispose.dispose()}getAllDocumentData(){return[...this._documentsAndEditors.allDocuments()]}getDocumentData(I){if(!I)return;const f=this._documentsAndEditors.getDocument(I);if(f)return f}getDocument(I){const f=this.getDocumentData(I);if(!f?.document)throw new Error(`Unable to retrieve document from URI '${I}'`);return f.document}ensureDocumentData(I){const f=this._documentsAndEditors.getDocument(I);if(f)return Promise.resolve(f);let h=this._documentLoader.get(I.toString());return h||(h=this._proxy.$tryOpenDocument(I).then(d=>{this._documentLoader.delete(I.toString());const a=b.URI.revive(d);return(0,E.assertIsDefined)(this._documentsAndEditors.getDocument(a))},d=>(this._documentLoader.delete(I.toString()),Promise.reject(d))),this._documentLoader.set(I.toString(),h)),h}createDocumentData(I){return this._proxy.$tryCreateDocument(I).then(f=>b.URI.revive(f))}$acceptModelLanguageChanged(I,f){const h=b.URI.revive(I),d=this._documentsAndEditors.getDocument(h);if(!d)throw new Error("unknown document");this._onDidRemoveDocument.fire(d.document),d._acceptLanguageId(f),this._onDidAddDocument.fire(d.document)}$acceptModelSaved(I){const f=b.URI.revive(I),h=this._documentsAndEditors.getDocument(f);if(!h)throw new Error("unknown document");this.$acceptDirtyStateChanged(I,!1),this._onDidSaveDocument.fire(h.document)}$acceptDirtyStateChanged(I,f){const h=b.URI.revive(I),d=this._documentsAndEditors.getDocument(h);if(!d)throw new Error("unknown document");d._acceptIsDirty(f),this._onDidChangeDocument.fire({document:d.document,contentChanges:[],reason:void 0})}$acceptModelChanged(I,f,h){const d=b.URI.revive(I),a=this._documentsAndEditors.getDocument(d);if(!a)throw new Error("unknown document");a._acceptIsDirty(h),a.onEvents(f);let w;f.isUndoing?w=R.TextDocumentChangeReason.Undo:f.isRedoing&&(w=R.TextDocumentChangeReason.Redo),this._onDidChangeDocument.fire((0,A.deepFreeze)({document:a.document,contentChanges:f.changes.map(P=>({range:T.Range.to(P.range),rangeOffset:P.rangeOffset,rangeLength:P.rangeLength,text:P.text})),reason:w}))}setWordDefinitionFor(I,f){(0,C.setWordDefinitionFor)(I,f)}}e.ExtHostDocuments=y}),define(ye[49],Ce([1,0,42,4,7,2,3,5,87,15,93,8,14,25,12,167,196]),function(ee,e,s,p,b,L,C,T,E,A,R,y,m,I,f,h,d){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.IExtHostDocumentsAndEditors=e.ExtHostDocumentsAndEditors=void 0;class a{constructor(l){this.value=l,this._count=0}ref(){this._count++}unref(){return--this._count==0}}let w=class{constructor(l,_){this._extHostRpc=l,this._logService=_,this._activeEditorId=null,this._editors=new Map,this._documents=new I.ResourceMap,this._onDidAddDocuments=new p.Emitter,this._onDidRemoveDocuments=new p.Emitter,this._onDidChangeVisibleTextEditors=new p.Emitter,this._onDidChangeActiveTextEditor=new p.Emitter,this.onDidAddDocuments=this._onDidAddDocuments.event,this.onDidRemoveDocuments=this._onDidRemoveDocuments.event,this.onDidChangeVisibleTextEditors=this._onDidChangeVisibleTextEditors.event,this.onDidChangeActiveTextEditor=this._onDidChangeActiveTextEditor.event}$acceptDocumentsAndEditorsDelta(l){this.acceptDocumentsAndEditorsDelta(l)}acceptDocumentsAndEditorsDelta(l){const _=[],n=[],u=[];if(l.removedDocuments)for(const i of l.removedDocuments){const o=L.URI.revive(i),r=this._documents.get(o);r?.unref()&&(this._documents.delete(o),_.push(r.value))}if(l.addedDocuments)for(const i of l.addedDocuments){const o=L.URI.revive(i.uri);let r=this._documents.get(o);if(r&&o.scheme!==f.Schemas.vscodeNotebookCell&&o.scheme!==f.Schemas.vscodeInteractiveInput)throw new Error(`document '${o} already exists!'`);r||(r=new a(new E.ExtHostDocumentData(this._extHostRpc.getProxy(T.MainContext.MainThreadDocuments),o,i.lines,i.EOL,i.versionId,i.languageId,i.isDirty,i.notebook)),this._documents.set(o,r),n.push(r.value)),r.ref()}if(l.removedEditors)for(const i of l.removedEditors){const o=this._editors.get(i);this._editors.delete(i),o&&u.push(o)}if(l.addedEditors)for(const i of l.addedEditors){const o=L.URI.revive(i.documentUri);s.ok(this._documents.has(o),`document '${o}' does not exist`),s.ok(!this._editors.has(i.id),`editor '${i.id}' already exists!`);const r=this._documents.get(o).value,t=new R.ExtHostTextEditor(i.id,this._extHostRpc.getProxy(T.MainContext.MainThreadTextEditors),this._logService,new d.Lazy(()=>r.document),i.selections.map(y.Selection.to),i.options,i.visibleRanges.map(c=>y.Range.to(c)),typeof i.editorPosition=="number"?y.ViewColumn.to(i.editorPosition):void 0);this._editors.set(i.id,t)}l.newActiveEditor!==void 0&&(s.ok(l.newActiveEditor===null||this._editors.has(l.newActiveEditor),`active editor '${l.newActiveEditor}' does not exist`),this._activeEditorId=l.newActiveEditor),(0,b.dispose)(_),(0,b.dispose)(u),l.removedDocuments&&this._onDidRemoveDocuments.fire(_),l.addedDocuments&&this._onDidAddDocuments.fire(n),(l.removedEditors||l.addedEditors)&&this._onDidChangeVisibleTextEditors.fire(this.allEditors().map(i=>i.value)),l.newActiveEditor!==void 0&&this._onDidChangeActiveTextEditor.fire(this.activeEditor())}getDocument(l){return this._documents.get(l)?.value}allDocuments(){return h.Iterable.map(this._documents.values(),l=>l.value)}getEditor(l){return this._editors.get(l)}activeEditor(l){if(!this._activeEditorId)return;const _=this._editors.get(this._activeEditorId);return l?_:_?.value}allEditors(){return[...this._editors.values()]}};w=ze([xe(0,A.IExtHostRpcService),xe(1,m.ILogService)],w),e.ExtHostDocumentsAndEditors=w,e.IExtHostDocumentsAndEditors=(0,C.createDecorator)("IExtHostDocumentsAndEditors")}),define(ye[50],Ce([1,0,8,5,2,4,3,6,15,10,72]),function(ee,e,s,p,b,L,C,T,E,A,R){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.ExtHostEditorTabs=e.IExtHostEditorTabs=void 0,e.IExtHostEditorTabs=(0,C.createDecorator)("IExtHostEditorTabs");class y{constructor(d,a,w){this._activeTabIdGetter=w,this._parentGroup=a,this.acceptDtoUpdate(d)}get apiObject(){if(!this._apiObject){const d=this,a={get isActive(){return d._dto.id===d._activeTabIdGetter()},get label(){return d._dto.label},get input(){return d._input},get isDirty(){return d._dto.isDirty},get isPinned(){return d._dto.isPinned},get isPreview(){return d._dto.isPreview},get group(){return d._parentGroup.apiObject}};this._apiObject=Object.freeze(a)}return this._apiObject}get tabId(){return this._dto.id}acceptDtoUpdate(d){this._dto=d,this._input=this._initInput()}_initInput(){switch(this._dto.input.kind){case 1:return new T.TextTabInput(b.URI.revive(this._dto.input.uri));case 2:return new T.TextDiffTabInput(b.URI.revive(this._dto.input.original),b.URI.revive(this._dto.input.modified));case 3:return new T.TextMergeTabInput(b.URI.revive(this._dto.input.base),b.URI.revive(this._dto.input.input1),b.URI.revive(this._dto.input.input2),b.URI.revive(this._dto.input.result));case 6:return new T.CustomEditorTabInput(b.URI.revive(this._dto.input.uri),this._dto.input.viewType);case 7:return new T.WebviewEditorTabInput(this._dto.input.viewType);case 4:return new T.NotebookEditorTabInput(b.URI.revive(this._dto.input.uri),this._dto.input.notebookType);case 5:return new T.NotebookDiffEditorTabInput(b.URI.revive(this._dto.input.original),b.URI.revive(this._dto.input.modified),this._dto.input.notebookType);case 8:return new T.TerminalEditorTabInput;case 9:return new T.InteractiveWindowInput(b.URI.revive(this._dto.input.uri),b.URI.revive(this._dto.input.inputBoxUri));default:return}}}class m{constructor(d,a){this._tabs=[],this._activeTabId="",this._dto=d,this._activeGroupIdGetter=a;for(const w of d.tabs)w.isActive&&(this._activeTabId=w.id),this._tabs.push(new y(w,this,()=>this.activeTabId()))}get apiObject(){if(!this._apiObject){const d=this,a={get isActive(){return d._dto.groupId===d._activeGroupIdGetter()},get viewColumn(){return s.ViewColumn.to(d._dto.viewColumn)},get activeTab(){return d._tabs.find(w=>w.tabId===d._activeTabId)?.apiObject},get tabs(){return Object.freeze(d._tabs.map(w=>w.apiObject))}};this._apiObject=Object.freeze(a)}return this._apiObject}get groupId(){return this._dto.groupId}get tabs(){return this._tabs}acceptGroupDtoUpdate(d){this._dto=d}acceptTabOperation(d){if(d.kind===0){const w=new y(d.tabDto,this,()=>this.activeTabId());return this._tabs.splice(d.index,0,w),d.tabDto.isActive&&(this._activeTabId=w.tabId),w}else if(d.kind===1){const w=this._tabs.splice(d.index,1)[0];if(!w)throw new Error(`Tab close updated received for index ${d.index} which does not exist`);return w.tabId===this._activeTabId&&(this._activeTabId=""),w}else if(d.kind===3){if(d.oldIndex===void 0)throw new Error("Invalid old index on move IPC");const w=this._tabs.splice(d.oldIndex,1)[0];if(!w)throw new Error(`Tab move updated received for index ${d.oldIndex} which does not exist`);return this._tabs.splice(d.index,0,w),w}const a=this._tabs.find(w=>w.tabId===d.tabDto.id);if(!a)throw new Error("INVALID tab");return d.tabDto.isActive?this._activeTabId=d.tabDto.id:this._activeTabId===d.tabDto.id&&!d.tabDto.isActive&&(this._activeTabId=""),a.acceptDtoUpdate(d.tabDto),a}activeTabId(){return this._activeTabId}}let I=class{constructor(d){this._onDidChangeTabs=new L.Emitter,this._onDidChangeTabGroups=new L.Emitter,this._extHostTabGroups=[],this._proxy=d.getProxy(p.MainContext.MainThreadEditorTabs)}get tabGroups(){if(!this._apiObject){const d=this,a={onDidChangeTabGroups:d._onDidChangeTabGroups.event,onDidChangeTabs:d._onDidChangeTabs.event,get all(){return Object.freeze(d._extHostTabGroups.map(w=>w.apiObject))},get activeTabGroup(){const w=d._activeGroupId;return(0,A.assertIsDefined)(d._extHostTabGroups.find(l=>l.groupId===w)?.apiObject)},close:async(w,P)=>{const l=Array.isArray(w)?w:[w];return l.length?f(l[0])?this._closeGroups(l,P):this._closeTabs(l,P):!0}};this._apiObject=Object.freeze(a)}return this._apiObject}$acceptEditorTabModel(d){const a=new Set(this._extHostTabGroups.map(i=>i.groupId)),w=new Set(d.map(i=>i.groupId)),P=(0,R.diffSets)(a,w),l=this._extHostTabGroups.filter(i=>P.removed.includes(i.groupId)).map(i=>i.apiObject),_=[],n=[];this._extHostTabGroups=d.map(i=>{const o=new m(i,()=>this._activeGroupId);return P.added.includes(o.groupId)?_.push(o.apiObject):n.push(o.apiObject),o});const u=(0,A.assertIsDefined)(d.find(i=>i.isActive===!0)?.groupId);u!==void 0&&this._activeGroupId!==u&&(this._activeGroupId=u),this._onDidChangeTabGroups.fire(Object.freeze({opened:_,closed:l,changed:n}))}$acceptTabGroupUpdate(d){const a=this._extHostTabGroups.find(w=>w.groupId===d.groupId);if(!a)throw new Error("Update Group IPC call received before group creation.");a.acceptGroupDtoUpdate(d),d.isActive&&(this._activeGroupId=d.groupId),this._onDidChangeTabGroups.fire(Object.freeze({changed:[a.apiObject],opened:[],closed:[]}))}$acceptTabOperation(d){const a=this._extHostTabGroups.find(P=>P.groupId===d.groupId);if(!a)throw new Error("Update Tabs IPC call received before group creation.");const w=a.acceptTabOperation(d);switch(d.kind){case 0:this._onDidChangeTabs.fire(Object.freeze({opened:[w.apiObject],closed:[],changed:[]}));return;case 1:this._onDidChangeTabs.fire(Object.freeze({opened:[],closed:[w.apiObject],changed:[]}));return;case 3:case 2:this._onDidChangeTabs.fire(Object.freeze({opened:[],closed:[],changed:[w.apiObject]}));return}}_findExtHostTabFromApi(d){for(const a of this._extHostTabGroups)for(const w of a.tabs)if(w.apiObject===d)return w}_findExtHostTabGroupFromApi(d){return this._extHostTabGroups.find(a=>a.apiObject===d)}async _closeTabs(d,a){const w=[];for(const P of d){const l=this._findExtHostTabFromApi(P);if(!l)throw new Error("Tab close: Invalid tab not found!");w.push(l.tabId)}return this._proxy.$closeTab(w,a)}async _closeGroups(d,a){const w=[];for(const P of d){const l=this._findExtHostTabGroupFromApi(P);if(!l)throw new Error("Group close: Invalid group not found!");w.push(l.groupId)}return this._proxy.$closeGroup(w,a)}};I=ze([xe(0,E.IExtHostRpcService)],I),e.ExtHostEditorTabs=I;function f(h){return h.tabs!==void 0}}),define(ye[197],Ce([1,0,2,5,7,6,8,242,9,22,24]),function(ee,e,s,p,b,L,C,T,E,A,R){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.ExtHostFileSystem=void 0;class y{constructor(){this._schemes=[]}add(f){this._stateMachine=void 0,this._schemes.push(f)}delete(f){const h=this._schemes.indexOf(f);h>=0&&(this._schemes.splice(h,1),this._stateMachine=void 0)}_initStateMachine(){if(!this._stateMachine){const f=this._schemes.sort(),h=[];let d,a,w=14,P=14;for(const l of f){let _=d?(0,E.commonPrefixLength)(d,l):0;for(_===0?a=1:a=P;_<l.length;_++)_+1===l.length?(w=P,P=9):P+=1,h.push([a,l.toUpperCase().charCodeAt(_),P]),h.push([a,l.toLowerCase().charCodeAt(_),P]),a=P;d=l,P=w}h.push([9,58,10]),h.push([10,47,12]),this._stateMachine=new T.StateMachine(h)}}provideDocumentLinks(f){this._initStateMachine();const h=[],d=T.LinkComputer.computeLinks({getLineContent(a){return f.lineAt(a-1).text},getLineCount(){return f.lineCount}},this._stateMachine);for(const a of d){const w=C.DocumentLink.to(a);w.target&&h.push(w)}return h}}class m{constructor(f,h){this._extHostLanguageFeatures=h,this._linkProvider=new y,this._fsProvider=new Map,this._registeredSchemes=new Set,this._watches=new Map,this._handlePool=0,this._proxy=f.getProxy(p.MainContext.MainThreadFileSystem)}dispose(){this._linkProviderRegistration?.dispose()}registerFileSystemProvider(f,h,d,a={}){if(this._registeredSchemes.has(h))throw new Error(`a provider for the scheme '${h}' is already registered`);this._linkProviderRegistration||(this._linkProviderRegistration=this._extHostLanguageFeatures.registerDocumentLinkProvider(f,"*",this._linkProvider));const w=this._handlePool++;this._linkProvider.add(h),this._registeredSchemes.add(h),this._fsProvider.set(w,d);let P=2;a.isCaseSensitive&&(P+=1024),a.isReadonly&&(P+=2048),typeof d.copy=="function"&&(P+=8),typeof d.open=="function"&&typeof d.close=="function"&&typeof d.read=="function"&&typeof d.write=="function"&&((0,R.checkProposedApiEnabled)(f,"fsChunks"),P+=4),this._proxy.$registerFileSystemProvider(w,h,P).catch(_=>{console.error(`FAILED to register filesystem provider of ${f.identifier.value}-extension for the scheme ${h}`),console.error(_)});const l=d.onDidChangeFile(_=>{const n=[];for(const u of _){const{uri:i,type:o}=u;if(i.scheme!==h)continue;let r;switch(o){case L.FileChangeType.Changed:r=0;break;case L.FileChangeType.Created:r=1;break;case L.FileChangeType.Deleted:r=2;break;default:throw new Error("Unknown FileChangeType")}n.push({resource:i,type:r})}this._proxy.$onFileSystemChange(w,n)});return(0,b.toDisposable)(()=>{l.dispose(),this._linkProvider.delete(h),this._registeredSchemes.delete(h),this._fsProvider.delete(w),this._proxy.$unregisterProvider(w)})}static _asIStat(f){const{type:h,ctime:d,mtime:a,size:w,permissions:P}=f;return{type:h,ctime:d,mtime:a,size:w,permissions:P}}$stat(f,h){return Promise.resolve(this._getFsProvider(f).stat(s.URI.revive(h))).then(d=>m._asIStat(d))}$readdir(f,h){return Promise.resolve(this._getFsProvider(f).readDirectory(s.URI.revive(h)))}$readFile(f,h){return Promise.resolve(this._getFsProvider(f).readFile(s.URI.revive(h))).then(d=>A.VSBuffer.wrap(d))}$writeFile(f,h,d,a){return Promise.resolve(this._getFsProvider(f).writeFile(s.URI.revive(h),d.buffer,a))}$delete(f,h,d){return Promise.resolve(this._getFsProvider(f).delete(s.URI.revive(h),d))}$rename(f,h,d,a){return Promise.resolve(this._getFsProvider(f).rename(s.URI.revive(h),s.URI.revive(d),a))}$copy(f,h,d,a){const w=this._getFsProvider(f);if(!w.copy)throw new Error('FileSystemProvider does not implement "copy"');return Promise.resolve(w.copy(s.URI.revive(h),s.URI.revive(d),a))}$mkdir(f,h){return Promise.resolve(this._getFsProvider(f).createDirectory(s.URI.revive(h)))}$watch(f,h,d,a){const w=this._getFsProvider(f).watch(s.URI.revive(d),a);this._watches.set(h,w)}$unwatch(f,h){const d=this._watches.get(h);d&&(d.dispose(),this._watches.delete(h))}$open(f,h,d){const a=this._getFsProvider(f);if(!a.open)throw new Error('FileSystemProvider does not implement "open"');return Promise.resolve(a.open(s.URI.revive(h),d))}$close(f,h){const d=this._getFsProvider(f);if(!d.close)throw new Error('FileSystemProvider does not implement "close"');return Promise.resolve(d.close(h))}$read(f,h,d,a){const w=this._getFsProvider(f);if(!w.read)throw new Error('FileSystemProvider does not implement "read"');const P=A.VSBuffer.alloc(a);return Promise.resolve(w.read(h,d,P.buffer,0,a)).then(l=>P.slice(0,l))}$write(f,h,d,a){const w=this._getFsProvider(f);if(!w.write)throw new Error('FileSystemProvider does not implement "write"');return Promise.resolve(w.write(h,d,a.buffer,0,a.byteLength))}_getFsProvider(f){const h=this._fsProvider.get(f);if(!h){const d=new Error;throw d.name="ENOPRO",d.message="no provider",d}return h}}e.ExtHostFileSystem=m}),define(ye[51],Ce([1,0,5,39,6,22,3,15,35,7]),function(ee,e,s,p,b,L,C,T,E,A){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.IExtHostConsumerFileSystem=e.ExtHostConsumerFileSystem=void 0;let R=class Zt{constructor(m,I){this._fileSystemProvider=new Map,this._proxy=m.getProxy(s.MainContext.MainThreadFileSystem);const f=this;this.value=Object.freeze({async stat(h){try{const d=f._fileSystemProvider.get(h.scheme);if(!d)return await f._proxy.$stat(h);await f._proxy.$ensureActivation(h.scheme);const a=await d.stat(h);return{type:a.type,ctime:a.ctime,mtime:a.mtime,size:a.size,permissions:a.permissions}}catch(d){Zt._handleError(d)}},async readDirectory(h){try{const d=f._fileSystemProvider.get(h.scheme);return d?(await f._proxy.$ensureActivation(h.scheme),(await d.readDirectory(h)).slice()):await f._proxy.$readdir(h)}catch(d){return Zt._handleError(d)}},async createDirectory(h){try{return await f._proxy.$mkdir(h)}catch(d){return Zt._handleError(d)}},async readFile(h){try{const d=f._fileSystemProvider.get(h.scheme);return d?(await f._proxy.$ensureActivation(h.scheme),(await d.readFile(h)).slice()):(await f._proxy.$readFile(h)).buffer}catch(d){return Zt._handleError(d)}},async writeFile(h,d){try{return await f._proxy.$writeFile(h,L.VSBuffer.wrap(d))}catch(a){return Zt._handleError(a)}},async delete(h,d){try{const a=f._fileSystemProvider.get(h.scheme);return a?(await f._proxy.$ensureActivation(h.scheme),await a.delete(h,{recursive:!1,...d})):await f._proxy.$delete(h,{recursive:!1,useTrash:!1,...d})}catch(a){return Zt._handleError(a)}},async rename(h,d,a){try{return await f._proxy.$rename(h,d,{overwrite:!1,...a})}catch(w){return Zt._handleError(w)}},async copy(h,d,a){try{return await f._proxy.$copy(h,d,{overwrite:!1,...a})}catch(w){return Zt._handleError(w)}},isWritableFileSystem(h){const d=I.getCapabilities(h);if(typeof d=="number")return!(d&2048)}})}static _handleError(m){if(m instanceof b.FileSystemError)throw m;if(!(m instanceof Error))throw new b.FileSystemError(String(m));if(m.name==="ENOPRO")throw b.FileSystemError.Unavailable(m.message);switch(m.name){case p.FileSystemProviderErrorCode.FileExists:throw b.FileSystemError.FileExists(m.message);case p.FileSystemProviderErrorCode.FileNotFound:throw b.FileSystemError.FileNotFound(m.message);case p.FileSystemProviderErrorCode.FileNotADirectory:throw b.FileSystemError.FileNotADirectory(m.message);case p.FileSystemProviderErrorCode.FileIsADirectory:throw b.FileSystemError.FileIsADirectory(m.message);case p.FileSystemProviderErrorCode.NoPermissions:throw b.FileSystemError.NoPermissions(m.message);case p.FileSystemProviderErrorCode.Unavailable:throw b.FileSystemError.Unavailable(m.message);default:throw new b.FileSystemError(m.message,m.name)}}addFileSystemProvider(m,I){return this._fileSystemProvider.set(m,I),(0,A.toDisposable)(()=>this._fileSystemProvider.delete(m))}};R=ze([xe(0,T.IExtHostRpcService),xe(1,E.IExtHostFileSystemInfo)],R),e.ExtHostConsumerFileSystem=R,e.IExtHostConsumerFileSystem=(0,C.createDecorator)("IExtHostConsumerFileSystem")}),define(ye[198],Ce([1,0,4,34,2,5,8,6,24]),function(ee,e,s,p,b,L,C,T,E){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.ExtHostFileSystemEventService=void 0;class A{constructor(m,I,f,h,d,a,w,P){this._onDidCreate=new s.Emitter,this._onDidChange=new s.Emitter,this._onDidDelete=new s.Emitter;const l=this.ensureWatching(m,f,d);this._config=0,a&&(this._config+=1),w&&(this._config+=2),P&&(this._config+=4);const _=(0,p.parse)(d),n=typeof d=="string",u=h(i=>{if(!a)for(const o of i.created){const r=b.URI.revive(o);_(r.fsPath)&&(!n||I.getWorkspaceFolder(r))&&this._onDidCreate.fire(r)}if(!w)for(const o of i.changed){const r=b.URI.revive(o);_(r.fsPath)&&(!n||I.getWorkspaceFolder(r))&&this._onDidChange.fire(r)}if(!P)for(const o of i.deleted){const r=b.URI.revive(o);_(r.fsPath)&&(!n||I.getWorkspaceFolder(r))&&this._onDidDelete.fire(r)}});this._disposable=T.Disposable.from(l,this._onDidCreate,this._onDidChange,this._onDidDelete,u)}get ignoreCreateEvents(){return Boolean(this._config&1)}get ignoreChangeEvents(){return Boolean(this._config&2)}get ignoreDeleteEvents(){return Boolean(this._config&4)}ensureWatching(m,I,f){const h=T.Disposable.from();if(typeof f=="string")return h;const d=m.getProxy(L.MainContext.MainThreadFileSystem);let a=!1;(f.pattern.includes(p.GLOBSTAR)||f.pattern.includes(p.GLOB_SPLIT))&&(a=!0);const w=Math.random();return d.$watch(I.identifier.value,w,f.baseUri,{recursive:a,excludes:[]}),T.Disposable.from({dispose:()=>d.$unwatch(w)})}dispose(){this._disposable.dispose()}get onDidCreate(){return this._onDidCreate.event}get onDidChange(){return this._onDidChange.event}get onDidDelete(){return this._onDidDelete.event}}class R{constructor(m,I,f){this._mainContext=m,this._logService=I,this._extHostDocumentsAndEditors=f,this._onFileSystemEvent=new s.Emitter,this._onDidRenameFile=new s.Emitter,this._onDidCreateFile=new s.Emitter,this._onDidDeleteFile=new s.Emitter,this._onWillRenameFile=new s.AsyncEmitter,this._onWillCreateFile=new s.AsyncEmitter,this._onWillDeleteFile=new s.AsyncEmitter,this.onDidRenameFile=this._onDidRenameFile.event,this.onDidCreateFile=this._onDidCreateFile.event,this.onDidDeleteFile=this._onDidDeleteFile.event}createFileSystemWatcher(m,I,f,h,d,a){return new A(this._mainContext,m,I,this._onFileSystemEvent.event,C.GlobPattern.from(f),h,d,a)}$onFileEvent(m){this._onFileSystemEvent.fire(m)}$onDidRunFileOperation(m,I){switch(m){case 2:this._onDidRenameFile.fire(Object.freeze({files:I.map(f=>({oldUri:b.URI.revive(f.source),newUri:b.URI.revive(f.target)}))}));break;case 1:this._onDidDeleteFile.fire(Object.freeze({files:I.map(f=>b.URI.revive(f.target))}));break;case 0:case 3:this._onDidCreateFile.fire(Object.freeze({files:I.map(f=>b.URI.revive(f.target))}));break;default:}}getOnWillRenameFileEvent(m){return this._createWillExecuteEvent(m,this._onWillRenameFile)}getOnWillCreateFileEvent(m){return this._createWillExecuteEvent(m,this._onWillCreateFile)}getOnWillDeleteFileEvent(m){return this._createWillExecuteEvent(m,this._onWillDeleteFile)}_createWillExecuteEvent(m,I){return(f,h,d)=>{const a=function(P){f.call(h,P)};return a.extension=m,I.event(a,void 0,d)}}async $onWillRunFileOperation(m,I,f,h){switch(m){case 2:return await this._fireWillEvent(this._onWillRenameFile,{files:I.map(d=>({oldUri:b.URI.revive(d.source),newUri:b.URI.revive(d.target)}))},f,h);case 1:return await this._fireWillEvent(this._onWillDeleteFile,{files:I.map(d=>b.URI.revive(d.target))},f,h);case 0:case 3:return await this._fireWillEvent(this._onWillCreateFile,{files:I.map(d=>b.URI.revive(d.target))},f,h)}}async _fireWillEvent(m,I,f,h){const d=new Set,a=[];if(await m.fireAsync(I,h,async(P,l)=>{const _=Date.now(),n=await Promise.resolve(P);n instanceof T.WorkspaceEdit&&(a.push([l.extension,n]),d.add(l.extension.displayName??l.extension.identifier.value)),Date.now()-_>f&&this._logService.warn("SLOW file-participant",l.extension.identifier)}),h.isCancellationRequested||a.length===0)return;const w={edits:[]};for(const[P,l]of a){const{edits:_}=C.WorkspaceEdit.from(l,{getTextDocumentVersion:n=>this._extHostDocumentsAndEditors.getDocument(n)?.version,getNotebookDocumentVersion:()=>{}},(0,E.isProposedApiEnabled)(P,"snippetWorkspaceEdit"));w.edits=w.edits.concat(_)}return{edit:w,extensionNames:Array.from(d)}}}e.ExtHostFileSystemEventService=R}),define(ye[199],Ce([1,0,2,36]),function(ee,e,s,p){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.ExtHostInteractive=void 0;class b{constructor(C,T,E,A,R){this._extHostNotebooks=T,this._textDocumentsAndEditors=E,this._commands=A;const y=new p.ApiCommand("interactive.open","_interactive.open","Open interactive window and return notebook editor and input URI",[new p.ApiCommandArgument("showOptions","Show Options",m=>!0,m=>m),new p.ApiCommandArgument("resource","Interactive resource Uri",m=>!0,m=>m),new p.ApiCommandArgument("controllerId","Notebook controller Id",m=>!0,m=>m),new p.ApiCommandArgument("title","Interactive editor title",m=>!0,m=>m)],new p.ApiCommandResult("Notebook and input URI",m=>{if(R.debug("[ExtHostInteractive] open iw with notebook editor id",m.notebookEditorId),m.notebookEditorId!==void 0){const I=this._extHostNotebooks.getEditorById(m.notebookEditorId);return R.debug("[ExtHostInteractive] notebook editor found",I.id),{notebookUri:s.URI.revive(m.notebookUri),inputUri:s.URI.revive(m.inputUri),notebookEditor:I.apiEditor}}return R.debug("[ExtHostInteractive] notebook editor not found, uris for the interactive document",m.notebookUri,m.inputUri),{notebookUri:s.URI.revive(m.notebookUri),inputUri:s.URI.revive(m.inputUri)}}));this._commands.registerApiCommand(y)}$willAddInteractiveDocument(C,T,E,A){this._textDocumentsAndEditors.acceptDocumentsAndEditorsDelta({addedDocuments:[{EOL:T,lines:[""],languageId:E,uri:C,isDirty:!1,versionId:1,notebook:this._extHostNotebooks.getNotebookDocument(s.URI.revive(A))?.apiNotebook}]})}$willRemoveInteractiveDocument(C,T){this._textDocumentsAndEditors.acceptDocumentsAndEditorsDelta({removedDocuments:[C]})}}e.ExtHostInteractive=b}),define(ye[200],Ce([1,0,7,5]),function(ee,e,s,p){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.ExtHostLabelService=void 0;class b{constructor(C){this._handlePool=0,this._proxy=C.getProxy(p.MainContext.MainThreadLabelService)}$registerResourceLabelFormatter(C){const T=this._handlePool++;return this._proxy.$registerResourceLabelFormatter(T,C),(0,s.toDisposable)(()=>{this._proxy.$unregisterResourceLabelFormatter(T)})}}e.ExtHostLabelService=b}),define(ye[201],Ce([1,0,2,26,8,6,66,5,9,48,16,10,243,20,7,77,73,61,202,11,13,24]),function(ee,e,s,p,b,L,C,T,E,A,R,y,m,I,f,h,d,a,w,P,l,_){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.ExtHostLanguageFeatures=e.DocumentRangeSemanticTokensAdapter=e.DocumentSemanticTokensAdapter=void 0;class n{constructor(k,B){this._documents=k,this._provider=B}async provideDocumentSymbols(k,B){const H=this._documents.getDocument(k),j=await this._provider.provideDocumentSymbols(H,B);if(!(0,R.isFalsyOrEmpty)(j))return j[0]instanceof L.DocumentSymbol?j.map(b.DocumentSymbol.from):n._asDocumentSymbolTree(j)}static _asDocumentSymbolTree(k){k=k.slice(0).sort((j,oe)=>{let ue=j.location.range.start.compareTo(oe.location.range.start);return ue===0&&(ue=oe.location.range.end.compareTo(j.location.range.end)),ue});const B=[],H=[];for(const j of k){const oe={name:j.name||"!!MISSING: name!!",kind:b.SymbolKind.from(j.kind),tags:j.tags?.map(b.SymbolTag.from)||[],detail:"",containerName:j.containerName,range:b.Range.from(j.location.range),selectionRange:b.Range.from(j.location.range),children:[]};for(;;){if(H.length===0){H.push(oe),B.push(oe);break}const ue=H[H.length-1];if(A.Range.containsRange(ue.range,oe.range)&&!A.Range.equalsRange(ue.range,oe.range)){ue.children?.push(oe),H.push(oe);break}H.pop()}}return B}}class u{constructor(k,B,H){this._documents=k,this._commands=B,this._provider=H,this._cache=new a.Cache("CodeLens"),this._disposables=new Map}async provideCodeLenses(k,B){const H=this._documents.getDocument(k),j=await this._provider.provideCodeLenses(H,B);if(!j||B.isCancellationRequested)return;const oe=this._cache.add(j),ue=new f.DisposableStore;this._disposables.set(oe,ue);const Z={cacheId:oe,lenses:[]};for(let pe=0;pe<j.length;pe++)Z.lenses.push({cacheId:[oe,pe],range:b.Range.from(j[pe].range),command:this._commands.toInternal(j[pe].command,ue)});return Z}async resolveCodeLens(k,B){const H=k.cacheId&&this._cache.get(...k.cacheId);if(!H)return;let j;if(typeof this._provider.resolveCodeLens!="function"||H.isResolved?j=H:j=await this._provider.resolveCodeLens(H,B),j||(j=H),B.isCancellationRequested)return;const oe=k.cacheId&&this._disposables.get(k.cacheId[0]);if(!!oe)return k.command=this._commands.toInternal(j.command??u._badCmd,oe),k}releaseCodeLenses(k){this._disposables.get(k)?.dispose(),this._disposables.delete(k),this._cache.delete(k)}}u._badCmd={command:"missing",title:"!!MISSING: command!!"};function i(J){return Array.isArray(J)?J.map(b.DefinitionLink.from):J?[b.DefinitionLink.from(J)]:[]}class o{constructor(k,B){this._documents=k,this._provider=B}async provideDefinition(k,B,H){const j=this._documents.getDocument(k),oe=b.Position.to(B),ue=await this._provider.provideDefinition(j,oe,H);return i(ue)}}class r{constructor(k,B){this._documents=k,this._provider=B}async provideDeclaration(k,B,H){const j=this._documents.getDocument(k),oe=b.Position.to(B),ue=await this._provider.provideDeclaration(j,oe,H);return i(ue)}}class t{constructor(k,B){this._documents=k,this._provider=B}async provideImplementation(k,B,H){const j=this._documents.getDocument(k),oe=b.Position.to(B),ue=await this._provider.provideImplementation(j,oe,H);return i(ue)}}class c{constructor(k,B){this._documents=k,this._provider=B}async provideTypeDefinition(k,B,H){const j=this._documents.getDocument(k),oe=b.Position.to(B),ue=await this._provider.provideTypeDefinition(j,oe,H);return i(ue)}}class v{constructor(k,B){this._documents=k,this._provider=B}async provideHover(k,B,H){const j=this._documents.getDocument(k),oe=b.Position.to(B),ue=await this._provider.provideHover(j,oe,H);if(!(!ue||(0,R.isFalsyOrEmpty)(ue.contents)))return ue.range||(ue.range=j.getWordRangeAtPosition(oe)),ue.range||(ue.range=new L.Range(oe,oe)),b.Hover.from(ue)}}class g{constructor(k,B){this._documents=k,this._provider=B}async provideEvaluatableExpression(k,B,H){const j=this._documents.getDocument(k),oe=b.Position.to(B),ue=await this._provider.provideEvaluatableExpression(j,oe,H);if(ue)return b.EvaluatableExpression.from(ue)}}class D{constructor(k,B){this._documents=k,this._provider=B}async provideInlineValues(k,B,H,j){const oe=this._documents.getDocument(k),ue=await this._provider.provideInlineValues(oe,b.Range.to(B),b.InlineValueContext.to(H),j);if(Array.isArray(ue))return ue.map(Z=>b.InlineValue.from(Z))}}class U{constructor(k,B){this._documents=k,this._provider=B}async provideDocumentHighlights(k,B,H){const j=this._documents.getDocument(k),oe=b.Position.to(B),ue=await this._provider.provideDocumentHighlights(j,oe,H);if(Array.isArray(ue))return ue.map(b.DocumentHighlight.from)}}class W{constructor(k,B){this._documents=k,this._provider=B}async provideLinkedEditingRanges(k,B,H){const j=this._documents.getDocument(k),oe=b.Position.to(B),ue=await this._provider.provideLinkedEditingRanges(j,oe,H);if(ue&&Array.isArray(ue.ranges))return{ranges:(0,R.coalesce)(ue.ranges.map(b.Range.from)),wordPattern:ue.wordPattern}}}class M{constructor(k,B){this._documents=k,this._provider=B}async provideReferences(k,B,H,j){const oe=this._documents.getDocument(k),ue=b.Position.to(B),Z=await this._provider.provideReferences(oe,ue,H,j);if(Array.isArray(Z))return Z.map(b.location.from)}}class S{constructor(k,B,H,j,oe,ue,Z){this._documents=k,this._commands=B,this._diagnostics=H,this._provider=j,this._logService=oe,this._extension=ue,this._apiDeprecation=Z,this._cache=new a.Cache("CodeAction"),this._disposables=new Map}async provideCodeActions(k,B,H,j){const oe=this._documents.getDocument(k),ue=m.Selection.isISelection(B)?b.Selection.to(B):b.Range.to(B),Z=[];for(const Ke of this._diagnostics.getDiagnostics(k))if(ue.intersection(Ke.range)&&Z.push(Ke)>S._maxCodeActionsPerFile)break;const pe={diagnostics:Z,only:H.only?new L.CodeActionKind(H.only):void 0,triggerKind:b.CodeActionTriggerKind.to(H.trigger)},ge=await this._provider.provideCodeActions(oe,ue,pe,j);if(!(0,R.isNonEmptyArray)(ge)||j.isCancellationRequested)return;const Ne=this._cache.add(ge),Be=new f.DisposableStore;this._disposables.set(Ne,Be);const Ze=[];for(let Ke=0;Ke<ge.length;Ke++){const ke=ge[Ke];!ke||(S._isCommand(ke)?(this._apiDeprecation.report("CodeActionProvider.provideCodeActions - return commands",this._extension,"Return 'CodeAction' instances instead."),Ze.push({_isSynthetic:!0,title:ke.title,command:this._commands.toInternal(ke,Be)})):(pe.only&&(ke.kind?pe.only.contains(ke.kind)||this._logService.warn(`${this._extension.identifier.value} - Code actions of kind '${pe.only.value} 'requested but returned code action is of kind '${ke.kind.value}'. Code action will be dropped. Please check 'CodeActionContext.only' to only return requested code actions.`):this._logService.warn(`${this._extension.identifier.value} - Code actions of kind '${pe.only.value} 'requested but returned code action does not have a 'kind'. Code action will be dropped. Please set 'CodeAction.kind'.`)),Ze.push({cacheId:[Ne,Ke],title:ke.title,command:ke.command&&this._commands.toInternal(ke.command,Be),diagnostics:ke.diagnostics&&ke.diagnostics.map(b.Diagnostic.from),edit:ke.edit&&b.WorkspaceEdit.from(ke.edit,void 0,(0,_.isProposedApiEnabled)(this._extension,"snippetWorkspaceEdit")),kind:ke.kind&&ke.kind.value,isPreferred:ke.isPreferred,disabled:ke.disabled?.reason})))}return{cacheId:Ne,actions:Ze}}async resolveCodeAction(k,B){const[H,j]=k,oe=this._cache.get(H,j);if(!oe||S._isCommand(oe)||!this._provider.resolveCodeAction)return;const ue=await this._provider.resolveCodeAction(oe,B)??oe;return ue?.edit?b.WorkspaceEdit.from(ue.edit,void 0,(0,_.isProposedApiEnabled)(this._extension,"snippetWorkspaceEdit")):void 0}releaseCodeActions(k){this._disposables.get(k)?.dispose(),this._disposables.delete(k),this._cache.delete(k)}static _isCommand(k){return typeof k.command=="string"&&typeof k.title=="string"}}S._maxCodeActionsPerFile=1e3;class z{constructor(k,B,H,j){this._proxy=k,this._documents=B,this._provider=H,this._handle=j}async prepareDocumentPaste(k,B,H,j){if(!this._provider.prepareDocumentPaste)return;const oe=this._documents.getDocument(k),ue=B.map(pe=>b.Range.to(pe)),Z=b.DataTransfer.toDataTransfer(H,()=>{throw new P.NotImplementedError});return await this._provider.prepareDocumentPaste(oe,ue,Z,j),b.DataTransfer.toDataTransferDTO(Z)}async providePasteEdits(k,B,H,j,oe){const ue=this._documents.getDocument(B),Z=H.map(Ne=>b.Range.to(Ne)),pe=b.DataTransfer.toDataTransfer(j,async Ne=>(await this._proxy.$resolvePasteFileData(this._handle,k,Ne)).buffer),ge=await this._provider.provideDocumentPasteEdits(ue,Z,pe,oe);if(!!ge)return{insertText:typeof ge.insertText=="string"?ge.insertText:{snippet:ge.insertText.value},additionalEdit:ge.additionalEdit?b.WorkspaceEdit.from(ge.additionalEdit,void 0,!0):void 0}}}class ${constructor(k,B){this._documents=k,this._provider=B}async provideDocumentFormattingEdits(k,B,H){const j=this._documents.getDocument(k),oe=await this._provider.provideDocumentFormattingEdits(j,B,H);if(Array.isArray(oe))return oe.map(b.TextEdit.from)}}class N{constructor(k,B){this._documents=k,this._provider=B}async provideDocumentRangeFormattingEdits(k,B,H,j){const oe=this._documents.getDocument(k),ue=b.Range.to(B),Z=await this._provider.provideDocumentRangeFormattingEdits(oe,ue,H,j);if(Array.isArray(Z))return Z.map(b.TextEdit.from)}}class K{constructor(k,B){this._documents=k,this._provider=B,this.autoFormatTriggerCharacters=[]}async provideOnTypeFormattingEdits(k,B,H,j,oe){const ue=this._documents.getDocument(k),Z=b.Position.to(B),pe=await this._provider.provideOnTypeFormattingEdits(ue,Z,H,j,oe);if(Array.isArray(pe))return pe.map(b.TextEdit.from)}}class V{constructor(k,B){this._provider=k,this._logService=B,this._cache=new a.Cache("WorkspaceSymbols")}async provideWorkspaceSymbols(k,B){const H=await this._provider.provideWorkspaceSymbols(k,B);if(!(0,R.isNonEmptyArray)(H))return{symbols:[]};const j=this._cache.add(H),oe={cacheId:j,symbols:[]};for(let ue=0;ue<H.length;ue++){const Z=H[ue];if(!Z||!Z.name){this._logService.warn("INVALID SymbolInformation",Z);continue}oe.symbols.push({...b.WorkspaceSymbol.from(Z),cacheId:[j,ue]})}return oe}async resolveWorkspaceSymbol(k,B){if(typeof this._provider.resolveWorkspaceSymbol!="function"||!k.cacheId)return k;const H=this._cache.get(...k.cacheId);if(H){const j=await this._provider.resolveWorkspaceSymbol(H,B);return j&&(0,p.mixin)(k,b.WorkspaceSymbol.from(j),!0)}}releaseWorkspaceSymbols(k){this._cache.delete(k)}}class F{constructor(k,B,H){this._documents=k,this._provider=B,this._logService=H}static supportsResolving(k){return typeof k.prepareRename=="function"}async provideRenameEdits(k,B,H,j){const oe=this._documents.getDocument(k),ue=b.Position.to(B);try{const Z=await this._provider.provideRenameEdits(oe,ue,H,j);return Z?b.WorkspaceEdit.from(Z):void 0}catch(Z){const pe=F._asMessage(Z);return pe?{rejectReason:pe,edits:void 0}:Promise.reject(Z)}}async resolveRenameLocation(k,B,H){if(typeof this._provider.prepareRename!="function")return Promise.resolve(void 0);const j=this._documents.getDocument(k),oe=b.Position.to(B);try{const ue=await this._provider.prepareRename(j,oe,H);let Z,pe;if(L.Range.isRange(ue)?(Z=ue,pe=j.getText(ue)):(0,y.isObject)(ue)&&(Z=ue.range,pe=ue.placeholder),!Z||!pe)return;if(Z.start.line>oe.line||Z.end.line<oe.line){this._logService.warn("INVALID rename location: position line must be within range start/end lines");return}return{range:b.Range.from(Z),text:pe}}catch(ue){const Z=F._asMessage(ue);return Z?{rejectReason:Z,range:void 0,text:void 0}:Promise.reject(ue)}}static _asMessage(k){return typeof k=="string"?k:k instanceof Error&&typeof k.message=="string"?k.message:void 0}}class ne{constructor(k,B){this.resultId=k,this.tokens=B}}class ce{constructor(k,B){this._documents=k,this._provider=B,this._nextResultId=1,this._previousResults=new Map}async provideDocumentSemanticTokens(k,B,H){const j=this._documents.getDocument(k),oe=B!==0?this._previousResults.get(B):null;let ue=typeof oe?.resultId=="string"&&typeof this._provider.provideDocumentSemanticTokensEdits=="function"?await this._provider.provideDocumentSemanticTokensEdits(j,oe.resultId,H):await this._provider.provideDocumentSemanticTokens(j,H);return oe&&this._previousResults.delete(B),ue?(ue=ce._fixProvidedSemanticTokens(ue),this._send(ce._convertToEdits(oe,ue),ue)):null}async releaseDocumentSemanticColoring(k){this._previousResults.delete(k)}static _fixProvidedSemanticTokens(k){return ce._isSemanticTokens(k)?ce._isCorrectSemanticTokens(k)?k:new L.SemanticTokens(new Uint32Array(k.data),k.resultId):ce._isSemanticTokensEdits(k)?ce._isCorrectSemanticTokensEdits(k)?k:new L.SemanticTokensEdits(k.edits.map(B=>new L.SemanticTokensEdit(B.start,B.deleteCount,B.data?new Uint32Array(B.data):B.data)),k.resultId):k}static _isSemanticTokens(k){return k&&!!k.data}static _isCorrectSemanticTokens(k){return k.data instanceof Uint32Array}static _isSemanticTokensEdits(k){return k&&Array.isArray(k.edits)}static _isCorrectSemanticTokensEdits(k){for(const B of k.edits)if(!(B.data instanceof Uint32Array))return!1;return!0}static _convertToEdits(k,B){if(!ce._isSemanticTokens(B)||!k||!k.tokens)return B;const H=k.tokens,j=H.length,oe=B.data,ue=oe.length;let Z=0;const pe=Math.min(j,ue);for(;Z<pe&&H[Z]===oe[Z];)Z++;if(Z===j&&Z===ue)return new L.SemanticTokensEdits([],B.resultId);let ge=0;const Ne=pe-Z;for(;ge<Ne&&H[j-ge-1]===oe[ue-ge-1];)ge++;return new L.SemanticTokensEdits([{start:Z,deleteCount:j-Z-ge,data:oe.subarray(Z,ue-ge)}],B.resultId)}_send(k,B){if(ce._isSemanticTokens(k)){const H=this._nextResultId++;return this._previousResults.set(H,new ne(k.resultId,k.data)),(0,h.encodeSemanticTokensDto)({id:H,type:"full",data:k.data})}if(ce._isSemanticTokensEdits(k)){const H=this._nextResultId++;return ce._isSemanticTokens(B)?this._previousResults.set(H,new ne(B.resultId,B.data)):this._previousResults.set(H,new ne(k.resultId)),(0,h.encodeSemanticTokensDto)({id:H,type:"delta",deltas:(k.edits||[]).map(j=>({start:j.start,deleteCount:j.deleteCount,data:j.data}))})}return null}}e.DocumentSemanticTokensAdapter=ce;class re{constructor(k,B){this._documents=k,this._provider=B}async provideDocumentRangeSemanticTokens(k,B,H){const j=this._documents.getDocument(k),oe=await this._provider.provideDocumentRangeSemanticTokens(j,b.Range.to(B),H);return oe?this._send(oe):null}_send(k){return(0,h.encodeSemanticTokensDto)({id:0,type:"full",data:k.data})}}e.DocumentRangeSemanticTokensAdapter=re;class fe{constructor(k,B,H,j,oe){this._documents=k,this._commands=B,this._provider=H,this._apiDeprecation=j,this._extension=oe,this._cache=new a.Cache("CompletionItem"),this._disposables=new Map}static supportsResolving(k){return typeof k.resolveCompletionItem=="function"}async provideCompletionItems(k,B,H,j){const oe=this._documents.getDocument(k),ue=b.Position.to(B),Z=oe.getWordRangeAtPosition(ue)||new L.Range(ue,ue),pe=Z.with({end:ue}),ge=new w.StopWatch(!0),Ne=await this._provider.provideCompletionItems(oe,ue,j,b.CompletionContext.to(H));if(!Ne||j.isCancellationRequested)return;const Be=Array.isArray(Ne)?new L.CompletionList(Ne):Ne,Ze=fe.supportsResolving(this._provider)?this._cache.add(Be.items):this._cache.add([]),Ke=new f.DisposableStore;this._disposables.set(Ze,Ke);const ke=[],nt={x:Ze,b:ke,a:{replace:b.Range.from(Z),insert:b.Range.from(pe)},c:Be.isIncomplete||void 0,d:ge.elapsed()};for(let G=0;G<Be.items.length;G++){const Q=Be.items[G],he=this._convertCompletionItem(Q,[Ze,G],pe,Z);ke.push(he)}return nt}async resolveCompletionItem(k,B){if(typeof this._provider.resolveCompletionItem!="function")return;const H=this._cache.get(...k);if(!H)return;const j=await this._provider.resolveCompletionItem(H,B);if(!!j)return this._convertCompletionItem(j,k)}releaseCompletionItems(k){this._disposables.get(k)?.dispose(),this._disposables.delete(k),this._cache.delete(k)}_convertCompletionItem(k,B,H,j){const oe=this._disposables.get(B[0]);if(!oe)throw Error("DisposableStore is missing...");const ue={x:B,a:k.label,b:k.kind!==void 0?b.CompletionItemKind.from(k.kind):void 0,n:k.tags&&k.tags.map(b.CompletionItemTag.from),c:k.detail,d:typeof k.documentation=="undefined"?void 0:b.MarkdownString.fromStrict(k.documentation),e:k.sortText!==k.label?k.sortText:void 0,f:k.filterText!==k.label?k.filterText:void 0,g:k.preselect||void 0,i:k.keepWhitespace?1:0,k:k.commitCharacters,l:k.additionalTextEdits&&k.additionalTextEdits.map(b.TextEdit.from),m:this._commands.toInternal(k.command,oe)};k.textEdit?(this._apiDeprecation.report("CompletionItem.textEdit",this._extension,"Use 'CompletionItem.insertText' and 'CompletionItem.range' instead."),ue.h=k.textEdit.newText):typeof k.insertText=="string"?ue.h=k.insertText:k.insertText instanceof L.SnippetString&&(ue.h=k.insertText.value,ue.i|=4);let Z;return k.textEdit?Z=k.textEdit.range:k.range&&(Z=k.range),L.Range.isRange(Z)?ue.j=b.Range.from(Z):Z&&(!H?.isEqual(Z.inserting)||!j?.isEqual(Z.replacing))&&(ue.j={insert:b.Range.from(Z.inserting),replace:b.Range.from(Z.replacing)}),ue}}class ie{async provideInlineCompletions(k,B,H,j){}disposeCompletions(k){}handleDidShowCompletionItem(k,B){}}class Ee extends ie{constructor(k,B,H,j){super();this._extension=k,this._documents=B,this._provider=H,this._commands=j,this._references=new te,this._isAdditionsProposedApiEnabled=(0,_.isProposedApiEnabled)(this._extension,"inlineCompletionsAdditions"),this.languageTriggerKindToVSCodeTriggerKind={[C.InlineCompletionTriggerKind.Automatic]:L.InlineCompletionTriggerKind.Automatic,[C.InlineCompletionTriggerKind.Explicit]:L.InlineCompletionTriggerKind.Invoke}}get supportsHandleDidShowCompletionItem(){return(0,_.isProposedApiEnabled)(this._extension,"inlineCompletionsAdditions")&&typeof this._provider.handleDidShowCompletionItem=="function"}async provideInlineCompletions(k,B,H,j){const oe=this._documents.getDocument(k),ue=b.Position.to(B),Z=await this._provider.provideInlineCompletionItems(oe,ue,{selectedCompletionInfo:H.selectedSuggestionInfo?{range:b.Range.to(H.selectedSuggestionInfo.range),text:H.selectedSuggestionInfo.text}:void 0,triggerKind:this.languageTriggerKindToVSCodeTriggerKind[H.triggerKind]},j);if(!Z||j.isCancellationRequested)return;const pe=(0,y.isArray)(Z)?Z:Z.items,ge=this._isAdditionsProposedApiEnabled?(0,y.isArray)(Z)?[]:Z.commands||[]:[];let Ne;return{pid:this._references.createReferenceId({dispose(){Ne&&Ne.dispose()},items:pe}),items:pe.map((Ze,Ke)=>{let ke;Ze.command&&(Ne||(Ne=new f.DisposableStore),ke=this._commands.toInternal(Ze.command,Ne));const nt=Ze.insertText;return{insertText:typeof nt=="string"?nt:{snippet:nt.value},filterText:Ze.filterText,range:Ze.range?b.Range.from(Ze.range):void 0,command:ke,idx:Ke,completeBracketPairs:this._isAdditionsProposedApiEnabled?Ze.completeBracketPairs:!1}}),commands:ge.map(Ze=>(Ne||(Ne=new f.DisposableStore),this._commands.toInternal(Ze,Ne)))}}disposeCompletions(k){this._references.disposeReferenceId(k)?.dispose()}handleDidShowCompletionItem(k,B){const H=this._references.get(k)?.items[B];H&&this._provider.handleDidShowCompletionItem&&this._isAdditionsProposedApiEnabled&&this._provider.handleDidShowCompletionItem(H)}}class be extends ie{constructor(k,B,H,j){super();this.extension=k,this._documents=B,this._provider=H,this._commands=j,this._references=new te,this.isAdditionProposedApiEnabled=(0,_.isProposedApiEnabled)(this.extension,"inlineCompletionsAdditions"),this.languageTriggerKindToVSCodeTriggerKind={[C.InlineCompletionTriggerKind.Automatic]:L.InlineCompletionTriggerKindNew.Automatic,[C.InlineCompletionTriggerKind.Explicit]:L.InlineCompletionTriggerKindNew.Invoke}}async provideInlineCompletions(k,B,H,j){const oe=this._documents.getDocument(k),ue=b.Position.to(B),Z=await this._provider.provideInlineCompletionItems(oe,ue,{selectedCompletionInfo:H.selectedSuggestionInfo?{range:b.Range.to(H.selectedSuggestionInfo.range),text:H.selectedSuggestionInfo.text}:void 0,triggerKind:this.languageTriggerKindToVSCodeTriggerKind[H.triggerKind]},j);if(!Z||j.isCancellationRequested)return;const pe=(0,y.isArray)(Z)?Z:Z.items,ge=(0,y.isArray)(Z)?[]:Z.commands||[];let Ne;return{pid:this._references.createReferenceId({dispose(){Ne&&Ne.dispose()},items:pe}),items:pe.map((Ze,Ke)=>{let ke;Ze.command&&(Ne||(Ne=new f.DisposableStore),ke=this._commands.toInternal(Ze.command,Ne));const nt=Ze.insertText;return{insertText:typeof nt=="string"?nt:{snippet:nt.value},filterText:Ze.filterText,range:Ze.range?b.Range.from(Ze.range):void 0,command:ke,idx:Ke,completeBracketPairs:this.isAdditionProposedApiEnabled?Ze.completeBracketPairs:!1}}),commands:ge.map(Ze=>(Ne||(Ne=new f.DisposableStore),this._commands.toInternal(Ze,Ne)))}}disposeCompletions(k){this._references.disposeReferenceId(k)?.dispose()}handleDidShowCompletionItem(k,B){const H=this._references.get(k)?.items[B];H&&this._provider.handleDidShowCompletionItem&&this.isAdditionProposedApiEnabled&&this._provider.handleDidShowCompletionItem(H)}}class te{constructor(){this._references=new Map,this._idPool=1}createReferenceId(k){const B=this._idPool++;return this._references.set(B,k),B}disposeReferenceId(k){const B=this._references.get(k);return this._references.delete(k),B}get(k){return this._references.get(k)}}class ve{constructor(k,B){this._documents=k,this._provider=B,this._cache=new a.Cache("SignatureHelp")}async provideSignatureHelp(k,B,H,j){const oe=this._documents.getDocument(k),ue=b.Position.to(B),Z=this.reviveContext(H),pe=await this._provider.provideSignatureHelp(oe,ue,j,Z);if(pe){const ge=this._cache.add([pe]);return{...b.SignatureHelp.from(pe),id:ge}}}reviveContext(k){let B;if(k.activeSignatureHelp){const H=b.SignatureHelp.to(k.activeSignatureHelp),j=this._cache.get(k.activeSignatureHelp.id,0);j?(B=j,B.activeSignature=H.activeSignature,B.activeParameter=H.activeParameter):B=H}return{...k,activeSignatureHelp:B}}releaseSignatureHelp(k){this._cache.delete(k)}}class Re{constructor(k,B,H,j,oe){this._documents=k,this._commands=B,this._provider=H,this._logService=j,this._extension=oe,this._cache=new a.Cache("InlayHints"),this._disposables=new Map}async provideInlayHints(k,B,H){const j=this._documents.getDocument(k),oe=b.Range.to(B),ue=await this._provider.provideInlayHints(j,oe,H);if(!Array.isArray(ue)||ue.length===0){this._logService.trace(`[InlayHints] NO inlay hints from '${this._extension.identifier.value}' for ${B}`);return}if(H.isCancellationRequested)return;const Z=this._cache.add(ue);this._disposables.set(Z,new f.DisposableStore);const pe={hints:[],cacheId:Z};for(let ge=0;ge<ue.length;ge++)this._isValidInlayHint(ue[ge],oe)&&pe.hints.push(this._convertInlayHint(ue[ge],[Z,ge]));return this._logService.trace(`[InlayHints] ${pe.hints.length} inlay hints from '${this._extension.identifier.value}' for ${B}`),pe}async resolveInlayHint(k,B){if(typeof this._provider.resolveInlayHint!="function")return;const H=this._cache.get(...k);if(!H)return;const j=await this._provider.resolveInlayHint(H,B);if(!!j&&!!this._isValidInlayHint(j))return this._convertInlayHint(j,k)}releaseHints(k){this._disposables.get(k)?.dispose(),this._disposables.delete(k),this._cache.delete(k)}_isValidInlayHint(k,B){return k.label.length===0||Array.isArray(k.label)&&k.label.every(H=>H.value.length===0)?(console.log("INVALID inlay hint, empty label",k),!1):!(B&&!B.contains(k.position))}_convertInlayHint(k,B){const H=this._disposables.get(B[0]);if(!H)throw Error("DisposableStore is missing...");const j={label:"",cacheId:B,tooltip:b.MarkdownString.fromStrict(k.tooltip),position:b.Position.from(k.position),textEdits:k.textEdits&&k.textEdits.map(b.TextEdit.from),kind:k.kind&&b.InlayHintKind.from(k.kind),paddingLeft:k.paddingLeft,paddingRight:k.paddingRight};return typeof k.label=="string"?j.label=k.label:j.label=k.label.map(oe=>{const ue={label:oe.value};return ue.tooltip=b.MarkdownString.fromStrict(oe.tooltip),L.Location.isLocation(oe.location)&&(ue.location=b.location.from(oe.location)),oe.command&&(ue.command=this._commands.toInternal(oe.command,H)),ue}),j}}class Fe{constructor(k,B){this._documents=k,this._provider=B,this._cache=new a.Cache("DocumentLink")}async provideLinks(k,B){const H=this._documents.getDocument(k),j=await this._provider.provideDocumentLinks(H,B);if(!(!Array.isArray(j)||j.length===0)&&!B.isCancellationRequested){if(typeof this._provider.resolveDocumentLink!="function")return{links:j.filter(Fe._validateLink).map(b.DocumentLink.from)};{const oe=this._cache.add(j),ue={links:[],cacheId:oe};for(let Z=0;Z<j.length;Z++){if(!Fe._validateLink(j[Z]))continue;const pe=b.DocumentLink.from(j[Z]);pe.cacheId=[oe,Z],ue.links.push(pe)}return ue}}}static _validateLink(k){return k.target&&k.target.path.length>5e4?(console.warn("DROPPING link because it is too long"),!1):!0}async resolveLink(k,B){if(typeof this._provider.resolveDocumentLink!="function")return;const H=this._cache.get(...k);if(!H)return;const j=await this._provider.resolveDocumentLink(H,B);if(!(!j||!Fe._validateLink(j)))return b.DocumentLink.from(j)}releaseLinks(k){this._cache.delete(k)}}class $e{constructor(k,B){this._documents=k,this._provider=B}async provideColors(k,B){const H=this._documents.getDocument(k),j=await this._provider.provideDocumentColors(H,B);return Array.isArray(j)?j.map(ue=>({color:b.Color.from(ue.color),range:b.Range.from(ue.range)})):[]}async provideColorPresentations(k,B,H){const j=this._documents.getDocument(k),oe=b.Range.to(B.range),ue=b.Color.to(B.color),Z=await this._provider.provideColorPresentations(ue,{document:j,range:oe},H);if(!!Array.isArray(Z))return Z.map(b.ColorPresentation.from)}}class Ye{constructor(k,B){this._documents=k,this._provider=B}async provideFoldingRanges(k,B,H){const j=this._documents.getDocument(k),oe=await this._provider.provideFoldingRanges(j,B,H);if(!!Array.isArray(oe))return oe.map(b.FoldingRange.from)}}class Ie{constructor(k,B,H){this._documents=k,this._provider=B,this._logService=H}async provideSelectionRanges(k,B,H){const j=this._documents.getDocument(k),oe=B.map(b.Position.to),ue=await this._provider.provideSelectionRanges(j,oe,H);if(!(0,R.isNonEmptyArray)(ue))return[];if(ue.length!==oe.length)return this._logService.warn("BAD selection ranges, provider must return ranges for each position"),[];const Z=[];for(let pe=0;pe<oe.length;pe++){const ge=[];Z.push(ge);let Ne=oe[pe],Be=ue[pe];for(;;){if(!Be.range.contains(Ne))throw new Error("INVALID selection range, must contain the previous range");if(ge.push(b.SelectionRange.from(Be)),!Be.parent)break;Ne=Be.range,Be=Be.parent}}return Z}}class Se{constructor(k,B){this._documents=k,this._provider=B,this._idPool=new d.IdGenerator(""),this._cache=new Map}async prepareSession(k,B,H){const j=this._documents.getDocument(k),oe=b.Position.to(B),ue=await this._provider.prepareCallHierarchy(j,oe,H);if(!ue)return;const Z=this._idPool.nextId();return this._cache.set(Z,new Map),Array.isArray(ue)?ue.map(pe=>this._cacheAndConvertItem(Z,pe)):[this._cacheAndConvertItem(Z,ue)]}async provideCallsTo(k,B,H){const j=this._itemFromCache(k,B);if(!j)throw new Error("missing call hierarchy item");const oe=await this._provider.provideCallHierarchyIncomingCalls(j,H);if(!!oe)return oe.map(ue=>({from:this._cacheAndConvertItem(k,ue.from),fromRanges:ue.fromRanges.map(Z=>b.Range.from(Z))}))}async provideCallsFrom(k,B,H){const j=this._itemFromCache(k,B);if(!j)throw new Error("missing call hierarchy item");const oe=await this._provider.provideCallHierarchyOutgoingCalls(j,H);if(!!oe)return oe.map(ue=>({to:this._cacheAndConvertItem(k,ue.to),fromRanges:ue.fromRanges.map(Z=>b.Range.from(Z))}))}releaseSession(k){this._cache.delete(k)}_cacheAndConvertItem(k,B){const H=this._cache.get(k),j=b.CallHierarchyItem.from(B,k,H.size.toString(36));return H.set(j._itemId,B),j}_itemFromCache(k,B){return this._cache.get(k)?.get(B)}}class Te{constructor(k,B){this._documents=k,this._provider=B,this._idPool=new d.IdGenerator(""),this._cache=new Map}async prepareSession(k,B,H){const j=this._documents.getDocument(k),oe=b.Position.to(B),ue=await this._provider.prepareTypeHierarchy(j,oe,H);if(!ue)return;const Z=this._idPool.nextId();return this._cache.set(Z,new Map),Array.isArray(ue)?ue.map(pe=>this._cacheAndConvertItem(Z,pe)):[this._cacheAndConvertItem(Z,ue)]}async provideSupertypes(k,B,H){const j=this._itemFromCache(k,B);if(!j)throw new Error("missing type hierarchy item");const oe=await this._provider.provideTypeHierarchySupertypes(j,H);if(!!oe)return oe.map(ue=>this._cacheAndConvertItem(k,ue))}async provideSubtypes(k,B,H){const j=this._itemFromCache(k,B);if(!j)throw new Error("missing type hierarchy item");const oe=await this._provider.provideTypeHierarchySubtypes(j,H);if(!!oe)return oe.map(ue=>this._cacheAndConvertItem(k,ue))}releaseSession(k){this._cache.delete(k)}_cacheAndConvertItem(k,B){const H=this._cache.get(k),j=b.TypeHierarchyItem.from(B,k,H.size.toString(36));return H.set(j._itemId,B),j}_itemFromCache(k,B){return this._cache.get(k)?.get(B)}}class ae{constructor(k,B,H,j){this._proxy=k,this._documents=B,this._provider=H,this._handle=j}async provideDocumentOnDropEdits(k,B,H,j,oe){const ue=this._documents.getDocument(B),Z=b.Position.to(H),pe=b.DataTransfer.toDataTransfer(j,async Ne=>(await this._proxy.$resolveDocumentOnDropFileData(this._handle,k,Ne)).buffer),ge=await this._provider.provideDocumentDropEdits(ue,Z,pe,oe);if(!!ge)return{insertText:typeof ge.insertText=="string"?ge.insertText:{snippet:ge.insertText.value},additionalEdit:ge.additionalEdit?b.WorkspaceEdit.from(ge.additionalEdit,void 0,!0):void 0}}}class le{constructor(k,B){this.adapter=k,this.extension=B}}class X{constructor(k,B,H,j,oe,ue,Z){this._adapter=new Map,this._uriTransformer=B,this._proxy=k.getProxy(T.MainContext.MainThreadLanguageFeatures),this._documents=H,this._commands=j,this._diagnostics=oe,this._logService=ue,this._apiDeprecation=Z}_transformDocumentSelector(k){return b.DocumentSelector.from(k,this._uriTransformer)}_createDisposable(k){return new L.Disposable(()=>{this._adapter.delete(k),this._proxy.$unregister(k)})}_nextHandle(){return X._handlePool++}async _withAdapter(k,B,H,j,oe,ue=!1){const Z=this._adapter.get(k);if(!Z||!(Z.adapter instanceof B))return j;const pe=Date.now();ue||this._logService.trace(`[${Z.extension.identifier.value}] INVOKE provider '${H.toString().replace(/[\r\n]/g,"")}'`);const ge=H(Z.adapter,Z.extension);return Promise.resolve(ge).catch(Ne=>{(0,P.isCancellationError)(Ne)||(this._logService.error(`[${Z.extension.identifier.value}] provider FAILED`),this._logService.error(Ne))}).finally(()=>{ue||this._logService.trace(`[${Z.extension.identifier.value}] provider DONE after ${Date.now()-pe}ms`)}),I.CancellationToken.isCancellationToken(oe)?(0,l.raceCancellationError)(ge,oe):ge}_addNewAdapter(k,B){const H=this._nextHandle();return this._adapter.set(H,new le(k,B)),H}static _extLabel(k){return k.displayName||k.name}registerDocumentSymbolProvider(k,B,H,j){const oe=this._addNewAdapter(new n(this._documents,H),k),ue=j&&j.label||X._extLabel(k);return this._proxy.$registerDocumentSymbolProvider(oe,this._transformDocumentSelector(B),ue),this._createDisposable(oe)}$provideDocumentSymbols(k,B,H){return this._withAdapter(k,n,j=>j.provideDocumentSymbols(s.URI.revive(B),H),void 0,H)}registerCodeLensProvider(k,B,H){const j=this._nextHandle(),oe=typeof H.onDidChangeCodeLenses=="function"?this._nextHandle():void 0;this._adapter.set(j,new le(new u(this._documents,this._commands.converter,H),k)),this._proxy.$registerCodeLensSupport(j,this._transformDocumentSelector(B),oe);let ue=this._createDisposable(j);if(oe!==void 0){const Z=H.onDidChangeCodeLenses(pe=>this._proxy.$emitCodeLensEvent(oe));ue=L.Disposable.from(ue,Z)}return ue}$provideCodeLenses(k,B,H){return this._withAdapter(k,u,j=>j.provideCodeLenses(s.URI.revive(B),H),void 0,H)}$resolveCodeLens(k,B,H){return this._withAdapter(k,u,j=>j.resolveCodeLens(B,H),void 0,void 0)}$releaseCodeLenses(k,B){this._withAdapter(k,u,H=>Promise.resolve(H.releaseCodeLenses(B)),void 0,void 0)}registerDefinitionProvider(k,B,H){const j=this._addNewAdapter(new o(this._documents,H),k);return this._proxy.$registerDefinitionSupport(j,this._transformDocumentSelector(B)),this._createDisposable(j)}$provideDefinition(k,B,H,j){return this._withAdapter(k,o,oe=>oe.provideDefinition(s.URI.revive(B),H,j),[],j)}registerDeclarationProvider(k,B,H){const j=this._addNewAdapter(new r(this._documents,H),k);return this._proxy.$registerDeclarationSupport(j,this._transformDocumentSelector(B)),this._createDisposable(j)}$provideDeclaration(k,B,H,j){return this._withAdapter(k,r,oe=>oe.provideDeclaration(s.URI.revive(B),H,j),[],j)}registerImplementationProvider(k,B,H){const j=this._addNewAdapter(new t(this._documents,H),k);return this._proxy.$registerImplementationSupport(j,this._transformDocumentSelector(B)),this._createDisposable(j)}$provideImplementation(k,B,H,j){return this._withAdapter(k,t,oe=>oe.provideImplementation(s.URI.revive(B),H,j),[],j)}registerTypeDefinitionProvider(k,B,H){const j=this._addNewAdapter(new c(this._documents,H),k);return this._proxy.$registerTypeDefinitionSupport(j,this._transformDocumentSelector(B)),this._createDisposable(j)}$provideTypeDefinition(k,B,H,j){return this._withAdapter(k,c,oe=>oe.provideTypeDefinition(s.URI.revive(B),H,j),[],j)}registerHoverProvider(k,B,H,j){const oe=this._addNewAdapter(new v(this._documents,H),k);return this._proxy.$registerHoverProvider(oe,this._transformDocumentSelector(B)),this._createDisposable(oe)}$provideHover(k,B,H,j){return this._withAdapter(k,v,oe=>oe.provideHover(s.URI.revive(B),H,j),void 0,j)}registerEvaluatableExpressionProvider(k,B,H,j){const oe=this._addNewAdapter(new g(this._documents,H),k);return this._proxy.$registerEvaluatableExpressionProvider(oe,this._transformDocumentSelector(B)),this._createDisposable(oe)}$provideEvaluatableExpression(k,B,H,j){return this._withAdapter(k,g,oe=>oe.provideEvaluatableExpression(s.URI.revive(B),H,j),void 0,j)}registerInlineValuesProvider(k,B,H,j){const oe=typeof H.onDidChangeInlineValues=="function"?this._nextHandle():void 0,ue=this._addNewAdapter(new D(this._documents,H),k);this._proxy.$registerInlineValuesProvider(ue,this._transformDocumentSelector(B),oe);let Z=this._createDisposable(ue);if(oe!==void 0){const pe=H.onDidChangeInlineValues(ge=>this._proxy.$emitInlineValuesEvent(oe));Z=L.Disposable.from(Z,pe)}return Z}$provideInlineValues(k,B,H,j,oe){return this._withAdapter(k,D,ue=>ue.provideInlineValues(s.URI.revive(B),H,j,oe),void 0,oe)}registerDocumentHighlightProvider(k,B,H){const j=this._addNewAdapter(new U(this._documents,H),k);return this._proxy.$registerDocumentHighlightProvider(j,this._transformDocumentSelector(B)),this._createDisposable(j)}$provideDocumentHighlights(k,B,H,j){return this._withAdapter(k,U,oe=>oe.provideDocumentHighlights(s.URI.revive(B),H,j),void 0,j)}registerLinkedEditingRangeProvider(k,B,H){const j=this._addNewAdapter(new W(this._documents,H),k);return this._proxy.$registerLinkedEditingRangeProvider(j,this._transformDocumentSelector(B)),this._createDisposable(j)}$provideLinkedEditingRanges(k,B,H,j){return this._withAdapter(k,W,async oe=>{const ue=await oe.provideLinkedEditingRanges(s.URI.revive(B),H,j);if(ue)return{ranges:ue.ranges,wordPattern:ue.wordPattern?X._serializeRegExp(ue.wordPattern):void 0}},void 0,j)}registerReferenceProvider(k,B,H){const j=this._addNewAdapter(new M(this._documents,H),k);return this._proxy.$registerReferenceSupport(j,this._transformDocumentSelector(B)),this._createDisposable(j)}$provideReferences(k,B,H,j,oe){return this._withAdapter(k,M,ue=>ue.provideReferences(s.URI.revive(B),H,j,oe),void 0,oe)}registerCodeActionProvider(k,B,H,j){const oe=new f.DisposableStore,ue=this._addNewAdapter(new S(this._documents,this._commands.converter,this._diagnostics,H,this._logService,k,this._apiDeprecation),k);return this._proxy.$registerQuickFixSupport(ue,this._transformDocumentSelector(B),{providedKinds:j?.providedCodeActionKinds?.map(Z=>Z.value),documentation:j?.documentation?.map(Z=>({kind:Z.kind.value,command:this._commands.converter.toInternal(Z.command,oe)}))},X._extLabel(k),Boolean(H.resolveCodeAction)),oe.add(this._createDisposable(ue)),oe}$provideCodeActions(k,B,H,j,oe){return this._withAdapter(k,S,ue=>ue.provideCodeActions(s.URI.revive(B),H,j,oe),void 0,oe)}$resolveCodeAction(k,B,H){return this._withAdapter(k,S,j=>j.resolveCodeAction(B,H),void 0,void 0)}$releaseCodeActions(k,B){this._withAdapter(k,S,H=>Promise.resolve(H.releaseCodeActions(B)),void 0,void 0)}registerDocumentFormattingEditProvider(k,B,H){const j=this._addNewAdapter(new $(this._documents,H),k);return this._proxy.$registerDocumentFormattingSupport(j,this._transformDocumentSelector(B),k.identifier,k.displayName||k.name),this._createDisposable(j)}$provideDocumentFormattingEdits(k,B,H,j){return this._withAdapter(k,$,oe=>oe.provideDocumentFormattingEdits(s.URI.revive(B),H,j),void 0,j)}registerDocumentRangeFormattingEditProvider(k,B,H){const j=this._addNewAdapter(new N(this._documents,H),k);return this._proxy.$registerRangeFormattingSupport(j,this._transformDocumentSelector(B),k.identifier,k.displayName||k.name),this._createDisposable(j)}$provideDocumentRangeFormattingEdits(k,B,H,j,oe){return this._withAdapter(k,N,ue=>ue.provideDocumentRangeFormattingEdits(s.URI.revive(B),H,j,oe),void 0,oe)}registerOnTypeFormattingEditProvider(k,B,H,j){const oe=this._addNewAdapter(new K(this._documents,H),k);return this._proxy.$registerOnTypeFormattingSupport(oe,this._transformDocumentSelector(B),j,k.identifier),this._createDisposable(oe)}$provideOnTypeFormattingEdits(k,B,H,j,oe,ue){return this._withAdapter(k,K,Z=>Z.provideOnTypeFormattingEdits(s.URI.revive(B),H,j,oe,ue),void 0,ue)}registerWorkspaceSymbolProvider(k,B){const H=this._addNewAdapter(new V(B,this._logService),k);return this._proxy.$registerNavigateTypeSupport(H,typeof B.resolveWorkspaceSymbol=="function"),this._createDisposable(H)}$provideWorkspaceSymbols(k,B,H){return this._withAdapter(k,V,j=>j.provideWorkspaceSymbols(B,H),{symbols:[]},H)}$resolveWorkspaceSymbol(k,B,H){return this._withAdapter(k,V,j=>j.resolveWorkspaceSymbol(B,H),void 0,void 0)}$releaseWorkspaceSymbols(k,B){this._withAdapter(k,V,H=>H.releaseWorkspaceSymbols(B),void 0,void 0)}registerRenameProvider(k,B,H){const j=this._addNewAdapter(new F(this._documents,H,this._logService),k);return this._proxy.$registerRenameSupport(j,this._transformDocumentSelector(B),F.supportsResolving(H)),this._createDisposable(j)}$provideRenameEdits(k,B,H,j,oe){return this._withAdapter(k,F,ue=>ue.provideRenameEdits(s.URI.revive(B),H,j,oe),void 0,oe)}$resolveRenameLocation(k,B,H,j){return this._withAdapter(k,F,oe=>oe.resolveRenameLocation(s.URI.revive(B),H,j),void 0,j)}registerDocumentSemanticTokensProvider(k,B,H,j){const oe=this._addNewAdapter(new ce(this._documents,H),k),ue=typeof H.onDidChangeSemanticTokens=="function"?this._nextHandle():void 0;this._proxy.$registerDocumentSemanticTokensProvider(oe,this._transformDocumentSelector(B),j,ue);let Z=this._createDisposable(oe);if(ue){const pe=H.onDidChangeSemanticTokens(ge=>this._proxy.$emitDocumentSemanticTokensEvent(ue));Z=L.Disposable.from(Z,pe)}return Z}$provideDocumentSemanticTokens(k,B,H,j){return this._withAdapter(k,ce,oe=>oe.provideDocumentSemanticTokens(s.URI.revive(B),H,j),null,j)}$releaseDocumentSemanticTokens(k,B){this._withAdapter(k,ce,H=>H.releaseDocumentSemanticColoring(B),void 0,void 0)}registerDocumentRangeSemanticTokensProvider(k,B,H,j){const oe=this._addNewAdapter(new re(this._documents,H),k);return this._proxy.$registerDocumentRangeSemanticTokensProvider(oe,this._transformDocumentSelector(B),j),this._createDisposable(oe)}$provideDocumentRangeSemanticTokens(k,B,H,j){return this._withAdapter(k,re,oe=>oe.provideDocumentRangeSemanticTokens(s.URI.revive(B),H,j),null,j)}registerCompletionItemProvider(k,B,H,j){const oe=this._addNewAdapter(new fe(this._documents,this._commands.converter,H,this._apiDeprecation,k),k);return this._proxy.$registerCompletionsProvider(oe,this._transformDocumentSelector(B),j,fe.supportsResolving(H),`${k.identifier.value}(${j.join("")})`),this._createDisposable(oe)}$provideCompletionItems(k,B,H,j,oe){return this._withAdapter(k,fe,ue=>ue.provideCompletionItems(s.URI.revive(B),H,j,oe),void 0,oe)}$resolveCompletionItem(k,B,H){return this._withAdapter(k,fe,j=>j.resolveCompletionItem(B,H),void 0,H)}$releaseCompletionItems(k,B){this._withAdapter(k,fe,H=>H.releaseCompletionItems(B),void 0,void 0)}registerInlineCompletionsProvider(k,B,H){const j=new Ee(k,this._documents,H,this._commands.converter),oe=this._addNewAdapter(j,k);return this._proxy.$registerInlineCompletionsSupport(oe,this._transformDocumentSelector(B),j.supportsHandleDidShowCompletionItem),this._createDisposable(oe)}registerInlineCompletionsProviderNew(k,B,H){const j=this._addNewAdapter(new be(k,this._documents,H,this._commands.converter),k);return this._proxy.$registerInlineCompletionsSupport(j,this._transformDocumentSelector(B),!0),this._createDisposable(j)}$provideInlineCompletions(k,B,H,j,oe){return this._withAdapter(k,ie,ue=>ue.provideInlineCompletions(s.URI.revive(B),H,j,oe),void 0,oe)}$handleInlineCompletionDidShow(k,B,H){this._withAdapter(k,ie,async j=>{j.handleDidShowCompletionItem(B,H)},void 0,void 0)}$freeInlineCompletionsList(k,B){this._withAdapter(k,ie,async H=>{H.disposeCompletions(B)},void 0,void 0)}registerSignatureHelpProvider(k,B,H,j){const oe=Array.isArray(j)?{triggerCharacters:j,retriggerCharacters:[]}:j,ue=this._addNewAdapter(new ve(this._documents,H),k);return this._proxy.$registerSignatureHelpProvider(ue,this._transformDocumentSelector(B),oe),this._createDisposable(ue)}$provideSignatureHelp(k,B,H,j,oe){return this._withAdapter(k,ve,ue=>ue.provideSignatureHelp(s.URI.revive(B),H,j,oe),void 0,oe)}$releaseSignatureHelp(k,B){this._withAdapter(k,ve,H=>H.releaseSignatureHelp(B),void 0,void 0)}registerInlayHintsProvider(k,B,H){const j=typeof H.onDidChangeInlayHints=="function"?this._nextHandle():void 0,oe=this._addNewAdapter(new Re(this._documents,this._commands.converter,H,this._logService,k),k);this._proxy.$registerInlayHintsProvider(oe,this._transformDocumentSelector(B),typeof H.resolveInlayHint=="function",j,X._extLabel(k));let ue=this._createDisposable(oe);if(j!==void 0){const Z=H.onDidChangeInlayHints(pe=>this._proxy.$emitInlayHintsEvent(j));ue=L.Disposable.from(ue,Z)}return ue}$provideInlayHints(k,B,H,j){return this._withAdapter(k,Re,oe=>oe.provideInlayHints(s.URI.revive(B),H,j),void 0,j)}$resolveInlayHint(k,B,H){return this._withAdapter(k,Re,j=>j.resolveInlayHint(B,H),void 0,H)}$releaseInlayHints(k,B){this._withAdapter(k,Re,H=>H.releaseHints(B),void 0,void 0)}registerDocumentLinkProvider(k,B,H){const j=this._addNewAdapter(new Fe(this._documents,H),k);return this._proxy.$registerDocumentLinkProvider(j,this._transformDocumentSelector(B),typeof H.resolveDocumentLink=="function"),this._createDisposable(j)}$provideDocumentLinks(k,B,H){return this._withAdapter(k,Fe,j=>j.provideLinks(s.URI.revive(B),H),void 0,H,B.scheme==="output")}$resolveDocumentLink(k,B,H){return this._withAdapter(k,Fe,j=>j.resolveLink(B,H),void 0,void 0,!0)}$releaseDocumentLinks(k,B){this._withAdapter(k,Fe,H=>H.releaseLinks(B),void 0,void 0,!0)}registerColorProvider(k,B,H){const j=this._addNewAdapter(new $e(this._documents,H),k);return this._proxy.$registerDocumentColorProvider(j,this._transformDocumentSelector(B)),this._createDisposable(j)}$provideDocumentColors(k,B,H){return this._withAdapter(k,$e,j=>j.provideColors(s.URI.revive(B),H),[],H)}$provideColorPresentations(k,B,H,j){return this._withAdapter(k,$e,oe=>oe.provideColorPresentations(s.URI.revive(B),H,j),void 0,j)}registerFoldingRangeProvider(k,B,H){const j=this._nextHandle(),oe=typeof H.onDidChangeFoldingRanges=="function"?this._nextHandle():void 0;this._adapter.set(j,new le(new Ye(this._documents,H),k)),this._proxy.$registerFoldingRangeProvider(j,this._transformDocumentSelector(B),oe);let ue=this._createDisposable(j);if(oe!==void 0){const Z=H.onDidChangeFoldingRanges(()=>this._proxy.$emitFoldingRangeEvent(oe));ue=L.Disposable.from(ue,Z)}return ue}$provideFoldingRanges(k,B,H,j){return this._withAdapter(k,Ye,oe=>oe.provideFoldingRanges(s.URI.revive(B),H,j),void 0,j)}registerSelectionRangeProvider(k,B,H){const j=this._addNewAdapter(new Ie(this._documents,H,this._logService),k);return this._proxy.$registerSelectionRangeProvider(j,this._transformDocumentSelector(B)),this._createDisposable(j)}$provideSelectionRanges(k,B,H,j){return this._withAdapter(k,Ie,oe=>oe.provideSelectionRanges(s.URI.revive(B),H,j),[],j)}registerCallHierarchyProvider(k,B,H){const j=this._addNewAdapter(new Se(this._documents,H),k);return this._proxy.$registerCallHierarchyProvider(j,this._transformDocumentSelector(B)),this._createDisposable(j)}$prepareCallHierarchy(k,B,H,j){return this._withAdapter(k,Se,oe=>Promise.resolve(oe.prepareSession(s.URI.revive(B),H,j)),void 0,j)}$provideCallHierarchyIncomingCalls(k,B,H,j){return this._withAdapter(k,Se,oe=>oe.provideCallsTo(B,H,j),void 0,j)}$provideCallHierarchyOutgoingCalls(k,B,H,j){return this._withAdapter(k,Se,oe=>oe.provideCallsFrom(B,H,j),void 0,j)}$releaseCallHierarchy(k,B){this._withAdapter(k,Se,H=>Promise.resolve(H.releaseSession(B)),void 0,void 0)}registerTypeHierarchyProvider(k,B,H){const j=this._addNewAdapter(new Te(this._documents,H),k);return this._proxy.$registerTypeHierarchyProvider(j,this._transformDocumentSelector(B)),this._createDisposable(j)}$prepareTypeHierarchy(k,B,H,j){return this._withAdapter(k,Te,oe=>Promise.resolve(oe.prepareSession(s.URI.revive(B),H,j)),void 0,j)}$provideTypeHierarchySupertypes(k,B,H,j){return this._withAdapter(k,Te,oe=>oe.provideSupertypes(B,H,j),void 0,j)}$provideTypeHierarchySubtypes(k,B,H,j){return this._withAdapter(k,Te,oe=>oe.provideSubtypes(B,H,j),void 0,j)}$releaseTypeHierarchy(k,B){this._withAdapter(k,Te,H=>Promise.resolve(H.releaseSession(B)),void 0,void 0)}registerDocumentOnDropEditProvider(k,B,H){const j=this._nextHandle();return this._adapter.set(j,new le(new ae(this._proxy,this._documents,H,j),k)),this._proxy.$registerDocumentOnDropEditProvider(j,this._transformDocumentSelector(B)),this._createDisposable(j)}$provideDocumentOnDropEdits(k,B,H,j,oe,ue){return this._withAdapter(k,ae,Z=>Promise.resolve(Z.provideDocumentOnDropEdits(B,s.URI.revive(H),j,oe,ue)),void 0,void 0)}registerDocumentPasteEditProvider(k,B,H,j){const oe=this._nextHandle();return this._adapter.set(oe,new le(new z(this._proxy,this._documents,H,oe),k)),this._proxy.$registerPasteEditProvider(oe,this._transformDocumentSelector(B),!!H.prepareDocumentPaste,j.pasteMimeTypes),this._createDisposable(oe)}$prepareDocumentPaste(k,B,H,j,oe){return this._withAdapter(k,z,ue=>ue.prepareDocumentPaste(s.URI.revive(B),H,j,oe),void 0,oe)}$providePasteEdits(k,B,H,j,oe,ue){return this._withAdapter(k,z,Z=>Z.providePasteEdits(B,s.URI.revive(H),j,oe,ue),void 0,ue)}static _serializeRegExp(k){return{pattern:k.source,flags:(0,E.regExpFlags)(k)}}static _serializeIndentationRule(k){return{decreaseIndentPattern:X._serializeRegExp(k.decreaseIndentPattern),increaseIndentPattern:X._serializeRegExp(k.increaseIndentPattern),indentNextLinePattern:k.indentNextLinePattern?X._serializeRegExp(k.indentNextLinePattern):void 0,unIndentedLinePattern:k.unIndentedLinePattern?X._serializeRegExp(k.unIndentedLinePattern):void 0}}static _serializeOnEnterRule(k){return{beforeText:X._serializeRegExp(k.beforeText),afterText:k.afterText?X._serializeRegExp(k.afterText):void 0,previousLineText:k.previousLineText?X._serializeRegExp(k.previousLineText):void 0,action:k.action}}static _serializeOnEnterRules(k){return k.map(X._serializeOnEnterRule)}setLanguageConfiguration(k,B,H){const{wordPattern:j}=H;if(j&&(0,E.regExpLeadsToEndlessLoop)(j))throw new Error(`Invalid language configuration: wordPattern '${j}' is not allowed to match the empty string.`);j?this._documents.setWordDefinitionFor(B,j):this._documents.setWordDefinitionFor(B,void 0),H.__electricCharacterSupport&&this._apiDeprecation.report("LanguageConfiguration.__electricCharacterSupport",k,"Do not use."),H.__characterPairSupport&&this._apiDeprecation.report("LanguageConfiguration.__characterPairSupport",k,"Do not use.");const oe=this._nextHandle(),ue={comments:H.comments,brackets:H.brackets,wordPattern:H.wordPattern?X._serializeRegExp(H.wordPattern):void 0,indentationRules:H.indentationRules?X._serializeIndentationRule(H.indentationRules):void 0,onEnterRules:H.onEnterRules?X._serializeOnEnterRules(H.onEnterRules):void 0,__electricCharacterSupport:H.__electricCharacterSupport,__characterPairSupport:H.__characterPairSupport};return this._proxy.$setLanguageConfiguration(oe,B,ue),this._createDisposable(oe)}$setWordDefinitions(k){for(const B of k)this._documents.setWordDefinitionFor(B.languageId,new RegExp(B.regexSource,B.regexFlags))}}e.ExtHostLanguageFeatures=X,X._handlePool=0}),define(ye[203],Ce([1,0,5,8,6,29,13,7]),function(ee,e,s,p,b,L,C,T){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.ExtHostLanguages=void 0;class E{constructor(R,y,m,I){this._documents=y,this._commands=m,this._uriTransformer=I,this._languageIds=[],this._handlePool=0,this._ids=new Set,this._proxy=R.getProxy(s.MainContext.MainThreadLanguages)}$acceptLanguageIds(R){this._languageIds=R}async getLanguages(){return this._languageIds.slice(0)}async changeLanguage(R,y){await this._proxy.$changeLanguage(R,y);const m=this._documents.getDocumentData(R);if(!m)throw new Error(`document '${R.toString()}' NOT found`);return m.document}async tokenAtPosition(R,y){const m=R.version,I=p.Position.from(y),f=await this._proxy.$tokensAtPosition(R.uri,I),h={type:b.StandardTokenType.Other,range:R.getWordRangeAtPosition(y)??new b.Range(y.line,y.character,y.line,y.character)};if(!f)return h;const d={range:p.Range.to(f.range),type:p.TokenType.to(f.type)};return!d.range.contains(y)||m!==R.version?h:d}createLanguageStatusItem(R,y,m){const I=this._handlePool++,f=this._proxy,h=this._ids,d=`${R.identifier.value}/${y}`;if(h.has(d))throw new Error(`LanguageStatusItem with id '${y}' ALREADY exists`);h.add(d);const a={selector:m,id:y,name:R.displayName??R.name,severity:b.LanguageStatusSeverity.Information,command:void 0,text:"",detail:"",busy:!1};let w;const P=new T.DisposableStore,l=()=>{w?.dispose(),w=(0,C.disposableTimeout)(()=>{P.clear(),this._proxy.$setLanguageStatus(I,{id:d,name:a.name??R.displayName??R.name,source:R.displayName??R.name,selector:p.DocumentSelector.from(a.selector,this._uriTransformer),label:a.text,detail:a.detail??"",severity:a.severity===b.LanguageStatusSeverity.Error?L.default.Error:a.severity===b.LanguageStatusSeverity.Warning?L.default.Warning:L.default.Info,command:a.command&&this._commands.toInternal(a.command,P),accessibilityInfo:a.accessibilityInformation,busy:a.busy})},0)},_={dispose(){P.dispose(),w?.dispose(),f.$removeLanguageStatus(I),h.delete(d)},get id(){return a.id},get name(){return a.name},set name(n){a.name=n,l()},get selector(){return a.selector},set selector(n){a.selector=n,l()},get text(){return a.text},set text(n){a.text=n,l()},get detail(){return a.detail},set detail(n){a.detail=n,l()},get severity(){return a.severity},set severity(n){a.severity=n,l()},get accessibilityInformation(){return a.accessibilityInformation},set accessibilityInformation(n){a.accessibilityInformation=n,l()},get command(){return a.command},set command(n){a.command=n,l()},get busy(){return a.busy},set busy(n){a.busy=n,l()}};return l(),_}}e.ExtHostLanguages=E}),define(ye[204],Ce([1,0,14,5,28,15,4]),function(ee,e,s,p,b,L,C){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.ExtHostLoggerService=void 0;let T=class extends s.AbstractLoggerService{constructor(R,y){const m=new C.Emitter;super(y.logLevel,m.event);this._proxy=R.getProxy(p.MainContext.MainThreadLogger),this._onDidChangeLogLevel=this._register(m)}$setLevel(R){this._onDidChangeLogLevel.fire(R)}doCreateLogger(R,y,m){return new E(this._proxy,R,y,m)}};T=ze([xe(0,L.IExtHostRpcService),xe(1,b.IExtHostInitDataService)],T),e.ExtHostLoggerService=T;class E extends s.AbstractMessageLogger{constructor(R,y,m,I){super(I?.always);this.proxy=R,this.file=y,this.isLoggerCreated=!1,this.buffer=[],this.setLevel(m),this.proxy.$createLogger(y,I).then(()=>{this.doLog(this.buffer),this.isLoggerCreated=!0})}log(R,y){const m=[[R,y]];this.isLoggerCreated?this.doLog(m):this.buffer.push(...m)}doLog(R){this.proxy.$log(this.file,R)}}}),define(ye[205],Ce([1,0,5,14,24]),function(ee,e,s,p,b){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.ExtHostMessageService=void 0;function L(T){return T&&T.title}let C=class{constructor(E,A){this._logService=A,this._proxy=E.getProxy(s.MainContext.MainThreadMessageService)}showMessage(E,A,R,y,m){const I={source:{identifier:E.identifier,label:E.displayName||E.name}};let f;typeof y=="string"||L(y)?f=[y,...m]:(I.modal=y?.modal,I.useCustom=y?.useCustom,I.detail=y?.detail,f=m),I.useCustom&&(0,b.checkProposedApiEnabled)(E,"resolvers");const h=[];for(let d=0;d<f.length;d++){const a=f[d];if(typeof a=="string")h.push({title:a,handle:d,isCloseAffordance:!1});else if(typeof a=="object"){const{title:w,isCloseAffordance:P}=a;h.push({title:w,isCloseAffordance:!!P,handle:d})}else this._logService.warn("Invalid message item:",a)}return this._proxy.$showMessage(A,R,I,h).then(d=>{if(typeof d=="number")return f[d]})}};C=ze([xe(1,p.ILogService)],C),e.ExtHostMessageService=C}),define(ye[206],Ce([1,0,22,4,96,7,25,9,10,2,61,5,36,8,6,40,174,91]),function(ee,e,s,p,b,L,C,T,E,A,R,y,m,I,f,h,d,a){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.ExtHostNotebookController=void 0;class w{constructor(l,_,n,u,i){this._textDocumentsAndEditors=n,this._textDocuments=u,this._extensionStoragePaths=i,this._notebookContentProviders=new Map,this._notebookStatusBarItemProviders=new Map,this._documents=new C.ResourceMap,this._editors=new Map,this._onDidChangeActiveNotebookEditor=new p.Emitter,this.onDidChangeActiveNotebookEditor=this._onDidChangeActiveNotebookEditor.event,this._visibleNotebookEditors=[],this._onDidOpenNotebookDocument=new p.Emitter,this.onDidOpenNotebookDocument=this._onDidOpenNotebookDocument.event,this._onDidCloseNotebookDocument=new p.Emitter,this.onDidCloseNotebookDocument=this._onDidCloseNotebookDocument.event,this._onDidChangeVisibleNotebookEditors=new p.Emitter,this.onDidChangeVisibleNotebookEditors=this._onDidChangeVisibleNotebookEditors.event,this._statusBarCache=new R.Cache("NotebookCellStatusBarCache"),this._handlePool=0,this._notebookSerializer=new Map,this._backupIdPool=0,this._notebookProxy=l.getProxy(y.MainContext.MainThreadNotebook),this._notebookDocumentsProxy=l.getProxy(y.MainContext.MainThreadNotebookDocuments),this._notebookEditorsProxy=l.getProxy(y.MainContext.MainThreadNotebookEditors),this._commandsConverter=_.converter,_.registerArgumentProcessor({processArgument:o=>{if(o&&o.$mid===12){const r=o.notebookEditor?.notebookUri,t=o.cell.handle,v=this._documents.get(r)?.getCell(t);if(v)return v.apiCell}return o}}),w._registerApiCommands(_)}get activeNotebookEditor(){return this._activeNotebookEditor?.apiEditor}get visibleNotebookEditors(){return this._visibleNotebookEditors.map(l=>l.apiEditor)}getEditorById(l){const _=this._editors.get(l);if(!_)throw new Error(`unknown text editor: ${l}. known editors: ${[...this._editors.keys()]} `);return _}getIdByEditor(l){for(const[_,n]of this._editors)if(n.apiEditor===l)return _}get notebookDocuments(){return[...this._documents.values()]}getNotebookDocument(l,_){const n=this._documents.get(l);if(!n&&!_)throw new Error(`NO notebook document for '${l}'`);return n}_getProviderData(l){const _=this._notebookContentProviders.get(l);if(!_)throw new Error(`NO provider for '${l}'`);return _}registerNotebookContentProvider(l,_,n,u,i){if((0,T.isFalsyOrWhitespace)(_))throw new Error("viewType cannot be empty or just whitespace");if(this._notebookContentProviders.has(_))throw new Error(`Notebook provider for '${_}' already registered`);this._notebookContentProviders.set(_,{extension:l,provider:n});let o;return n.onDidChangeNotebookContentOptions&&(o=n.onDidChangeNotebookContentOptions(()=>{const r=I.NotebookDocumentContentOptions.from(n.options);this._notebookProxy.$updateNotebookProviderOptions(_,r)})),this._notebookProxy.$registerNotebookProvider({id:l.identifier,location:l.extensionLocation},_,I.NotebookDocumentContentOptions.from(u),w._convertNotebookRegistrationData(l,i)),new f.Disposable(()=>{o?.dispose(),this._notebookContentProviders.delete(_),this._notebookProxy.$unregisterNotebookProvider(_)})}static _convertNotebookRegistrationData(l,_){if(!_)return;const n=_.filenamePattern.map(u=>I.NotebookExclusiveDocumentPattern.from(u)).filter(u=>u!==void 0);if(_.filenamePattern&&!n){console.warn(`Notebook content provider view options file name pattern is invalid ${_.filenamePattern}`);return}return{extension:l.identifier,providerDisplayName:l.displayName||l.name,displayName:_.displayName,filenamePattern:n,exclusive:_.exclusive||!1}}registerNotebookCellStatusBarItemProvider(l,_,n){const u=w._notebookStatusBarItemProviderHandlePool++,i=typeof n.onDidChangeCellStatusBarItems=="function"?w._notebookStatusBarItemProviderHandlePool++:void 0;this._notebookStatusBarItemProviders.set(u,n),this._notebookProxy.$registerNotebookCellStatusBarItemProvider(u,i,_);let o;return i!==void 0&&(o=n.onDidChangeCellStatusBarItems(r=>this._notebookProxy.$emitCellStatusBarEvent(i))),new f.Disposable(()=>{this._notebookStatusBarItemProviders.delete(u),this._notebookProxy.$unregisterNotebookCellStatusBarItemProvider(u,i),o&&o.dispose()})}async createNotebookDocument(l){const _=await this._notebookDocumentsProxy.$tryCreateNotebook({viewType:l.viewType,content:l.content&&I.NotebookData.from(l.content)});return A.URI.revive(_)}async openNotebookDocument(l){const _=this._documents.get(l);if(_)return _.apiNotebook;const n=await this._notebookDocumentsProxy.$tryOpenNotebook(l),u=this._documents.get(A.URI.revive(n));return(0,E.assertIsDefined)(u?.apiNotebook)}async showNotebookDocument(l,_){A.URI.isUri(l)&&(l=await this.openNotebookDocument(l));let n;typeof _=="object"?n={position:I.ViewColumn.from(_.viewColumn),preserveFocus:_.preserveFocus,selections:_.selections&&_.selections.map(I.NotebookRange.from),pinned:typeof _.preview=="boolean"?!_.preview:void 0}:n={preserveFocus:!1};const u=await this._notebookEditorsProxy.$tryShowNotebookDocument(l.uri,l.notebookType,n),i=u&&this._editors.get(u)?.apiEditor;if(i)return i;throw u?new Error(`Could NOT open editor for "${l.uri.toString()}" because another editor opened in the meantime.`):new Error(`Could NOT open editor for "${l.uri.toString()}".`)}async $provideNotebookCellStatusBarItems(l,_,n,u){const i=this._notebookStatusBarItemProviders.get(l),o=A.URI.revive(_),r=this._documents.get(o);if(!r||!i)return;const t=r.getCellFromIndex(n);if(!t)return;const c=await i.provideCellStatusBarItems(t.apiCell,u);if(!c)return;const v=new L.DisposableStore,g=this._statusBarCache.add([v]),U=(Array.isArray(c)?c:[c]).map(W=>I.NotebookStatusBarItem.from(W,this._commandsConverter,v));return{cacheId:g,items:U}}$releaseNotebookCellStatusBarItems(l){this._statusBarCache.delete(l)}registerNotebookSerializer(l,_,n,u,i){if((0,T.isFalsyOrWhitespace)(_))throw new Error("viewType cannot be empty or just whitespace");const o=this._handlePool++;return this._notebookSerializer.set(o,n),this._notebookProxy.$registerNotebookSerializer(o,{id:l.identifier,location:l.extensionLocation},_,I.NotebookDocumentContentOptions.from(u),w._convertNotebookRegistrationData(l,i)),(0,L.toDisposable)(()=>{this._notebookProxy.$unregisterNotebookSerializer(o)})}async $dataToNotebook(l,_,n){const u=this._notebookSerializer.get(l);if(!u)throw new Error("NO serializer found");const i=await u.deserializeNotebook(_.buffer,n);return new h.SerializableObjectWithBuffers(I.NotebookData.from(i))}async $notebookToData(l,_,n){const u=this._notebookSerializer.get(l);if(!u)throw new Error("NO serializer found");const i=await u.serializeNotebook(I.NotebookData.to(_.value),n);return s.VSBuffer.wrap(i)}async $openNotebook(l,_,n,u,i){const{provider:o}=this._getProviderData(l),r=await o.openNotebook(A.URI.revive(_),{backupId:n,untitledDocumentData:u?.buffer},i);return new h.SerializableObjectWithBuffers({metadata:r.metadata??Object.create(null),cells:r.cells.map(I.NotebookCellData.from)})}async $saveNotebook(l,_,n){const u=this.getNotebookDocument(A.URI.revive(_)),{provider:i}=this._getProviderData(l);return await i.saveNotebook(u.apiNotebook,n),!0}async $saveNotebookAs(l,_,n,u){const i=this.getNotebookDocument(A.URI.revive(_)),{provider:o}=this._getProviderData(l);return await o.saveNotebookAs(A.URI.revive(n),i.apiNotebook,u),!0}async $backupNotebook(l,_,n){const u=this.getNotebookDocument(A.URI.revive(_)),i=this._getProviderData(l),o=this._extensionStoragePaths.workspaceValue(i.extension)??this._extensionStoragePaths.globalValue(i.extension),r=String((0,b.hash)([u.uri.toString(),this._backupIdPool++])),t=A.URI.joinPath(o,r),c=await i.provider.backupNotebook(u.apiNotebook,{destination:t},n);return u.updateBackup(c),c.id}_createExtHostEditor(l,_,n){if(this._editors.has(_))throw new Error(`editor with id ALREADY EXSIST: ${_}`);const u=new a.ExtHostNotebookEditor(_,this._notebookEditorsProxy,l,n.visibleRanges.map(I.NotebookRange.to),n.selections.map(I.NotebookRange.to),typeof n.viewColumn=="number"?I.ViewColumn.to(n.viewColumn):void 0);this._editors.set(_,u)}$acceptDocumentAndEditorsDelta(l){if(l.value.removedDocuments)for(const n of l.value.removedDocuments){const u=A.URI.revive(n),i=this._documents.get(u);i&&(i.dispose(),this._documents.delete(u),this._textDocumentsAndEditors.$acceptDocumentsAndEditorsDelta({removedDocuments:i.apiNotebook.getCells().map(o=>o.document.uri)}),this._onDidCloseNotebookDocument.fire(i.apiNotebook));for(const o of this._editors.values())o.notebookData.uri.toString()===u.toString()&&this._editors.delete(o.id)}if(l.value.addedDocuments){const n=[];for(const u of l.value.addedDocuments){const i=A.URI.revive(u.uri);if(this._documents.has(i))throw new Error(`adding EXISTING notebook ${i} `);const o=new d.ExtHostNotebookDocument(this._notebookDocumentsProxy,this._textDocumentsAndEditors,this._textDocuments,i,u);n.push(...u.cells.map(r=>d.ExtHostCell.asModelAddData(o.apiNotebook,r))),this._documents.get(i)?.dispose(),this._documents.set(i,o),this._textDocumentsAndEditors.$acceptDocumentsAndEditorsDelta({addedDocuments:n}),this._onDidOpenNotebookDocument.fire(o.apiNotebook)}}if(l.value.addedEditors)for(const n of l.value.addedEditors){if(this._editors.has(n.id))return;const u=A.URI.revive(n.documentUri),i=this._documents.get(u);i&&this._createExtHostEditor(i,n.id,n)}const _=[];if(l.value.removedEditors)for(const n of l.value.removedEditors){const u=this._editors.get(n);u&&(this._editors.delete(n),this._activeNotebookEditor?.id===u.id&&(this._activeNotebookEditor=void 0),_.push(u))}if(l.value.visibleEditors){this._visibleNotebookEditors=l.value.visibleEditors.map(u=>this._editors.get(u)).filter(u=>!!u);const n=new Set;this._visibleNotebookEditors.forEach(u=>n.add(u.id));for(const u of this._editors.values()){const i=n.has(u.id);u._acceptVisibility(i)}this._visibleNotebookEditors=[...this._editors.values()].map(u=>u).filter(u=>u.visible),this._onDidChangeVisibleNotebookEditors.fire(this.visibleNotebookEditors)}l.value.newActiveEditor===null?this._activeNotebookEditor=void 0:l.value.newActiveEditor&&(this._activeNotebookEditor=this._editors.get(l.value.newActiveEditor)),l.value.newActiveEditor!==void 0&&this._onDidChangeActiveNotebookEditor.fire(this._activeNotebookEditor?.apiEditor)}static _registerApiCommands(l){const _=m.ApiCommandArgument.String.with("notebookType","A notebook type"),n=new m.ApiCommand("vscode.executeDataToNotebook","_executeDataToNotebook","Invoke notebook serializer",[_,new m.ApiCommandArgument("data","Bytes to convert to data",i=>i instanceof Uint8Array,i=>s.VSBuffer.wrap(i))],new m.ApiCommandResult("Notebook Data",i=>I.NotebookData.to(i.value))),u=new m.ApiCommand("vscode.executeNotebookToData","_executeNotebookToData","Invoke notebook serializer",[_,new m.ApiCommandArgument("NotebookData","Notebook data to convert to bytes",i=>!0,i=>new h.SerializableObjectWithBuffers(I.NotebookData.from(i)))],new m.ApiCommandResult("Bytes",i=>i.buffer));l.registerApiCommand(n),l.registerApiCommand(u)}}e.ExtHostNotebookController=w,w._notebookStatusBarItemProviderHandlePool=0}),define(ye[207],Ce([1,0,16,13,20,4,7,25,2,27,14,5,36,8,6,64,168,24,40]),function(ee,e,s,p,b,L,C,T,E,A,R,y,m,I,f,h,d,a,w){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.createKernelId=e.ExtHostNotebookKernels=void 0;let P=class{constructor(o,r,t,c,v){this._initData=r,this._extHostNotebook=t,this._commands=c,this._logService=v,this._activeExecutions=new T.ResourceMap,this._kernelData=new Map,this._handlePool=0,this._onDidChangeCellExecutionState=new L.Emitter,this.onDidChangeNotebookCellExecutionState=this._onDidChangeCellExecutionState.event,this._proxy=o.getProxy(y.MainContext.MainThreadNotebookKernels);const g=new m.ApiCommand("notebook.selectKernel","_notebook.selectKernel","Trigger kernel picker for specified notebook editor widget",[new m.ApiCommandArgument("options","Select kernel options",D=>!0,D=>{if(D&&"notebookEditor"in D&&"id"in D){const U=this._extHostNotebook.getIdByEditor(D.notebookEditor);return{id:D.id,extension:D.extension,notebookEditorId:U}}else if(D&&"notebookEditor"in D){const U=this._extHostNotebook.getIdByEditor(D.notebookEditor);if(U===void 0)throw new Error(`Cannot invoke 'notebook.selectKernel' for unrecognized notebook editor ${D.notebookEditor.document.uri.toString()}`);return{notebookEditorId:U}}return D})],m.ApiCommandResult.Void);this._commands.registerApiCommand(g)}createNotebookController(o,r,t,c,v,g){for(const fe of this._kernelData.values())if(fe.controller.id===r&&A.ExtensionIdentifier.equals(o.identifier,fe.extensionId))throw new Error(`notebook controller with id '${r}' ALREADY exist`);const D=this._handlePool++,U=this;this._logService.trace(`NotebookController[${D}], CREATED by ${o.identifier.value}, ${r}`);const W=()=>console.warn(`NO execute handler from notebook controller '${N.id}' of extension: '${o.identifier}'`);let M=!1;const S=new C.DisposableStore,z=new L.Emitter,$=new L.Emitter,N={id:u(o.identifier,r),notebookType:t,extensionId:o.identifier,extensionLocation:o.extensionLocation,label:c||o.identifier.value,preloads:g?g.map(I.NotebookRendererScript.from):[]};let K=v??W,V;this._proxy.$addKernel(D,N).catch(fe=>{console.log(fe),M=!0});let F=0;const ne=()=>{if(M)return;const fe=++F;Promise.resolve().then(()=>{fe===F&&this._proxy.$updateKernel(D,N)})},ce=new T.ResourceMap,re={get id(){return r},get notebookType(){return N.notebookType},onDidChangeSelectedNotebooks:z.event,get label(){return N.label},set label(fe){N.label=fe??o.displayName??o.name,ne()},get detail(){return N.detail??""},set detail(fe){N.detail=fe,ne()},get description(){return N.description??""},set description(fe){N.description=fe,ne()},get kind(){return(0,a.checkProposedApiEnabled)(o,"notebookControllerKind"),N.kind??""},set kind(fe){(0,a.checkProposedApiEnabled)(o,"notebookControllerKind"),N.kind=fe,ne()},get supportedLanguages(){return N.supportedLanguages},set supportedLanguages(fe){N.supportedLanguages=fe,ne()},get supportsExecutionOrder(){return N.supportsExecutionOrder??!1},set supportsExecutionOrder(fe){N.supportsExecutionOrder=fe,ne()},get rendererScripts(){return N.preloads?N.preloads.map(I.NotebookRendererScript.to):[]},get executeHandler(){return K},set executeHandler(fe){K=fe??W},get interruptHandler(){return V},set interruptHandler(fe){V=fe,N.supportsInterrupt=Boolean(fe),ne()},createNotebookCellExecution(fe){if(M)throw new Error("notebook controller is DISPOSED");if(!ce.has(fe.notebook.uri))throw U._logService.trace(`NotebookController[${D}] NOT associated to notebook, associated to THESE notebooks:`,Array.from(ce.keys()).map(ie=>ie.toString())),new Error(`notebook controller is NOT associated to notebook: ${fe.notebook.uri.toString()}`);return U._createNotebookCellExecution(fe,u(o.identifier,this.id))},dispose:()=>{M||(this._logService.trace(`NotebookController[${D}], DISPOSED`),M=!0,this._kernelData.delete(D),S.dispose(),z.dispose(),$.dispose(),this._proxy.$removeKernel(D))},updateNotebookAffinity(fe,ie){U._proxy.$updateNotebookPriority(D,fe.uri,ie)},onDidReceiveMessage:$.event,postMessage(fe,ie){return(0,a.checkProposedApiEnabled)(o,"notebookMessaging"),U._proxy.$postMessage(D,ie&&U._extHostNotebook.getIdByEditor(ie),fe)},asWebviewUri(fe){return(0,a.checkProposedApiEnabled)(o,"notebookMessaging"),(0,h.asWebviewUri)(fe,U._initData.remote)}};return this._kernelData.set(D,{extensionId:o.identifier,controller:re,onDidReceiveMessage:$,onDidChangeSelection:z,associatedNotebooks:ce}),re}getIdByController(o){for(const[r,t]of this._kernelData)if(t.controller===o)return u(t.extensionId,o.id);return null}$acceptNotebookAssociation(o,r,t){const c=this._kernelData.get(o);if(c){const v=this._extHostNotebook.getNotebookDocument(E.URI.revive(r));t?c.associatedNotebooks.set(v.uri,!0):c.associatedNotebooks.delete(v.uri),this._logService.trace(`NotebookController[${o}] ASSOCIATE notebook`,v.uri.toString(),t),c.onDidChangeSelection.fire({selected:t,notebook:v.apiNotebook})}}async $executeCells(o,r,t){const c=this._kernelData.get(o);if(!c)return;const v=this._extHostNotebook.getNotebookDocument(E.URI.revive(r)),g=[];for(const D of t){const U=v.getCell(D);U&&g.push(U.apiCell)}try{this._logService.trace(`NotebookController[${o}] EXECUTE cells`,v.uri.toString(),g.length),await c.controller.executeHandler.call(c.controller,g,v.apiNotebook,c.controller)}catch(D){this._logService.error(`NotebookController[${o}] execute cells FAILED`,D),console.error(D)}}async $cancelCells(o,r,t){const c=this._kernelData.get(o);if(!c)return;const v=this._extHostNotebook.getNotebookDocument(E.URI.revive(r));if(c.controller.interruptHandler)await c.controller.interruptHandler.call(c.controller,v.apiNotebook);else for(const g of t){const D=v.getCell(g);D&&this._activeExecutions.get(D.uri)?.cancel()}}$acceptKernelMessageFromRenderer(o,r,t){const c=this._kernelData.get(o);if(!c)return;const v=this._extHostNotebook.getEditorById(r);c.onDidReceiveMessage.fire(Object.freeze({editor:v.apiEditor,message:t}))}$cellExecutionChanged(o,r,t){const v=this._extHostNotebook.getNotebookDocument(E.URI.revive(o)).getCell(r);v&&this._onDidChangeCellExecutionState.fire({cell:v.apiCell,state:t?I.NotebookCellExecutionState.to(t):f.NotebookCellExecutionState.Idle})}_createNotebookCellExecution(o,r){if(o.index<0)throw new Error("CANNOT execute cell that has been REMOVED from notebook");const c=this._extHostNotebook.getNotebookDocument(o.notebook.uri).getCellFromApiCell(o);if(!c)throw new Error("invalid cell");if(this._activeExecutions.has(c.uri))throw new Error(`duplicate execution for ${c.uri}`);const v=new _(r,c,this._proxy);this._activeExecutions.set(c.uri,v);const g=v.onDidChangeState(()=>{v.state===l.Resolved&&(v.dispose(),g.dispose(),this._activeExecutions.delete(c.uri))});return v.asApiObject()}};P=ze([xe(4,R.ILogService)],P),e.ExtHostNotebookKernels=P;var l;(function(i){i[i.Init=0]="Init",i[i.Started=1]="Started",i[i.Resolved=2]="Resolved"})(l||(l={}));class _ extends C.Disposable{constructor(o,r,t){super();this._cell=r,this._proxy=t,this._handle=_.HANDLE++,this._onDidChangeState=new L.Emitter,this.onDidChangeState=this._onDidChangeState.event,this._state=l.Init,this._tokenSource=this._register(new b.CancellationTokenSource),this._collector=new n(10,c=>this.update(c)),this._executionOrder=r.internalMetadata.executionOrder,this._proxy.$createExecution(this._handle,o,this._cell.notebook.uri,this._cell.handle)}get state(){return this._state}cancel(){this._tokenSource.cancel()}async updateSoon(o){await this._collector.addItem(o)}async update(o){const r=Array.isArray(o)?o:[o];return this._proxy.$updateExecution(this._handle,new w.SerializableObjectWithBuffers(r))}verifyStateForOutput(){if(this._state===l.Init)throw new Error("Must call start before modifying cell output");if(this._state===l.Resolved)throw new Error("Cannot modify cell output after calling resolve")}cellIndexToHandle(o){let r=this._cell;if(o&&(r=this._cell.notebook.getCellFromApiCell(o)),!r)throw new Error("INVALID cell");return r.handle}validateAndConvertOutputs(o){return o.map(r=>{const t=f.NotebookCellOutput.ensureUniqueMimeTypes(r.items,!0);return t===r.items?I.NotebookCellOutput.from(r):I.NotebookCellOutput.from({items:t,id:r.id,metadata:r.metadata})})}async updateOutputs(o,r,t){const c=this.cellIndexToHandle(r),v=this.validateAndConvertOutputs((0,s.asArray)(o));return this.updateSoon({editType:d.CellExecutionUpdateType.Output,cellHandle:c,append:t,outputs:v})}async updateOutputItems(o,r,t){return o=f.NotebookCellOutput.ensureUniqueMimeTypes((0,s.asArray)(o),!0),this.updateSoon({editType:d.CellExecutionUpdateType.OutputItems,items:o.map(I.NotebookCellOutputItem.from),outputId:r.id,append:t})}asApiObject(){const o=this;return Object.freeze({get token(){return o._tokenSource.token},get cell(){return o._cell.apiCell},get executionOrder(){return o._executionOrder},set executionOrder(t){o._executionOrder=t,o.update([{editType:d.CellExecutionUpdateType.ExecutionState,executionOrder:o._executionOrder}])},start(t){if(o._state===l.Resolved||o._state===l.Started)throw new Error("Cannot call start again");o._state=l.Started,o._onDidChangeState.fire(),o.update({editType:d.CellExecutionUpdateType.ExecutionState,runStartTime:t})},end(t,c){if(o._state===l.Resolved)throw new Error("Cannot call resolve twice");o._state=l.Resolved,o._onDidChangeState.fire(),o._collector.flush(),o._proxy.$completeExecution(o._handle,new w.SerializableObjectWithBuffers({runEndTime:c,lastRunSuccess:t}))},clearOutput(t){return o.verifyStateForOutput(),o.updateOutputs([],t,!1)},appendOutput(t,c){return o.verifyStateForOutput(),o.updateOutputs(t,c,!0)},replaceOutput(t,c){return o.verifyStateForOutput(),o.updateOutputs(t,c,!1)},appendOutputItems(t,c){return o.verifyStateForOutput(),o.updateOutputItems(t,c,!0)},replaceOutputItems(t,c){return o.verifyStateForOutput(),o.updateOutputItems(t,c,!1)}})}}_.HANDLE=0;class n{constructor(o,r){this.delay=o,this.callback=r,this.batch=[],this.startedTimer=Date.now()}addItem(o){return this.batch.push(o),this.currentDeferred||(this.currentDeferred=new p.DeferredPromise,this.startedTimer=Date.now(),(0,p.timeout)(this.delay).then(()=>this.flush())),Date.now()-this.startedTimer>this.delay?this.flush():this.currentDeferred.p}flush(){if(this.batch.length===0||!this.currentDeferred)return Promise.resolve();const o=this.currentDeferred;this.currentDeferred=void 0;const r=this.batch;return this.batch=[],this.callback(r).finally(()=>o.complete())}}function u(i,o){return`${i.value}/${o}`}e.createKernelId=u}),define(ye[208],Ce([1,0,4,5,91]),function(ee,e,s,p,b){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.ExtHostNotebookRenderers=void 0;class L{constructor(T,E){this._extHostNotebook=E,this._rendererMessageEmitters=new Map,this.proxy=T.getProxy(p.MainContext.MainThreadNotebookRenderers)}$postRendererMessage(T,E,A){const R=this._extHostNotebook.getEditorById(T);this._rendererMessageEmitters.get(E)?.fire({editor:R.apiEditor,message:A})}createRendererMessaging(T,E){if(!T.contributes?.notebookRenderer?.some(R=>R.id===E))throw new Error(`Extensions may only call createRendererMessaging() for renderers they contribute (got ${E})`);return{onDidReceiveMessage:(R,y,m)=>this.getOrCreateEmitterFor(E).event(R,y,m),postMessage:(R,y)=>{b.ExtHostNotebookEditor.apiEditorsToExtHost.has(R)&&([R,y]=[y,R]);const m=y&&b.ExtHostNotebookEditor.apiEditorsToExtHost.get(y);return this.proxy.$postMessage(m?.id,E,R)}}}getOrCreateEmitterFor(T){let E=this._rendererMessageEmitters.get(T);return E||(E=new s.Emitter({onLastListenerRemove:()=>{E?.dispose(),this._rendererMessageEmitters.delete(T)}}),this._rendererMessageEmitters.set(T,E),E)}}e.ExtHostNotebookRenderers=L}),define(ye[209],Ce([1,0,20,4,7,5,2,6,11,16,29,60]),function(ee,e,s,p,b,L,C,T,E,A,R,y){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.createExtHostQuickOpen=void 0;function m(I,f,h){const d=I.getProxy(L.MainContext.MainThreadQuickOpen);class a{constructor(r,t){this._sessions=new Map,this._instances=0,this._workspace=r,this._commands=t}showQuickPick(r,t,c=s.CancellationToken.None){this._onDidSelectItem=void 0;const v=Promise.resolve(r),g=++this._instances,D=d.$show(g,{title:t?.title,placeHolder:t?.placeHolder,matchOnDescription:t?.matchOnDescription,matchOnDetail:t?.matchOnDetail,ignoreFocusLost:t?.ignoreFocusOut,canPickMany:t?.canPickMany},c),U={},W=D.then(()=>U);return Promise.race([W,v]).then(M=>{if(M!==U)return v.then(S=>{const z=[];for(let $=0;$<S.length;$++){const N=S[$];typeof N=="string"?z.push({label:N,handle:$}):N.kind===T.QuickPickItemKind.Separator?z.push({type:"separator",label:N.label}):z.push({label:N.label,description:N.description,detail:N.detail,picked:N.picked,alwaysShow:N.alwaysShow,handle:$})}return t&&typeof t.onDidSelectItem=="function"&&(this._onDidSelectItem=$=>{t.onDidSelectItem(S[$])}),d.$setItems(g,z),D.then($=>{if(typeof $=="number")return S[$];if(Array.isArray($))return $.map(N=>S[N])})})}).then(void 0,M=>{if(!(0,E.isCancellationError)(M))return d.$setError(g,M),Promise.reject(M)})}$onItemSelected(r){this._onDidSelectItem?.(r)}showInput(r,t=s.CancellationToken.None){return this._validateInput=r?.validateInput,d.$input(r,typeof this._validateInput=="function",t).then(void 0,c=>{if(!(0,E.isCancellationError)(c))return Promise.reject(c)})}async $validateInput(r){if(!this._validateInput)return;const t=await this._validateInput(r);if(!t||typeof t=="string")return t;let c;switch(t.severity){case T.InputBoxValidationSeverity.Info:c=R.default.Info;break;case T.InputBoxValidationSeverity.Warning:c=R.default.Warning;break;case T.InputBoxValidationSeverity.Error:c=R.default.Error;break;default:c=t.message?R.default.Error:R.default.Ignore;break}return{content:t.message,severity:c}}async showWorkspaceFolderPick(r,t=s.CancellationToken.None){const c=await this._commands.executeCommand("_workbench.pickWorkspaceFolder",[r]);if(!c)return;const v=await this._workspace.getWorkspaceFolders2();if(!!v)return v.find(g=>g.uri.toString()===c.uri.toString())}createQuickPick(r){const t=new u(r,()=>this._sessions.delete(t._id));return this._sessions.set(t._id,t),t}createInputBox(r){const t=new i(r,()=>this._sessions.delete(t._id));return this._sessions.set(t._id,t),t}$onDidChangeValue(r,t){this._sessions.get(r)?._fireDidChangeValue(t)}$onDidAccept(r){const t=this._sessions.get(r);t&&t._fireDidAccept()}$onDidChangeActive(r,t){const c=this._sessions.get(r);c instanceof u&&c._fireDidChangeActive(t)}$onDidChangeSelection(r,t){const c=this._sessions.get(r);c instanceof u&&c._fireDidChangeSelection(t)}$onDidTriggerButton(r,t){this._sessions.get(r)?._fireDidTriggerButton(t)}$onDidTriggerItemButton(r,t,c){const v=this._sessions.get(r);v instanceof u&&v._fireDidTriggerItemButton(t,c)}$onDidHide(r){const t=this._sessions.get(r);t&&t._fireDidHide()}}class w{constructor(r,t){this._extensionId=r,this._onDidDispose=t,this._id=u._nextId++,this._visible=!1,this._expectingHide=!1,this._enabled=!0,this._busy=!1,this._ignoreFocusOut=!0,this._value="",this._buttons=[],this._handlesToButtons=new Map,this._onDidAcceptEmitter=new p.Emitter,this._onDidChangeValueEmitter=new p.Emitter,this._onDidTriggerButtonEmitter=new p.Emitter,this._onDidHideEmitter=new p.Emitter,this._pendingUpdate={id:this._id},this._disposed=!1,this._disposables=[this._onDidTriggerButtonEmitter,this._onDidHideEmitter,this._onDidAcceptEmitter,this._onDidChangeValueEmitter],this.onDidChangeValue=this._onDidChangeValueEmitter.event,this.onDidAccept=this._onDidAcceptEmitter.event,this.onDidTriggerButton=this._onDidTriggerButtonEmitter.event,this.onDidHide=this._onDidHideEmitter.event}get title(){return this._title}set title(r){this._title=r,this.update({title:r})}get step(){return this._steps}set step(r){this._steps=r,this.update({step:r})}get totalSteps(){return this._totalSteps}set totalSteps(r){this._totalSteps=r,this.update({totalSteps:r})}get enabled(){return this._enabled}set enabled(r){this._enabled=r,this.update({enabled:r})}get busy(){return this._busy}set busy(r){this._busy=r,this.update({busy:r})}get ignoreFocusOut(){return this._ignoreFocusOut}set ignoreFocusOut(r){this._ignoreFocusOut=r,this.update({ignoreFocusOut:r})}get value(){return this._value}set value(r){this._value=r,this.update({value:r})}get placeholder(){return this._placeholder}set placeholder(r){this._placeholder=r,this.update({placeholder:r})}get buttons(){return this._buttons}set buttons(r){this._buttons=r.slice(),this._handlesToButtons.clear(),r.forEach((t,c)=>{const v=t===T.QuickInputButtons.Back?-1:c;this._handlesToButtons.set(v,t)}),this.update({buttons:r.map((t,c)=>({...n(t),tooltip:t.tooltip,handle:t===T.QuickInputButtons.Back?-1:c}))})}show(){this._visible=!0,this._expectingHide=!0,this.update({visible:!0})}hide(){this._visible=!1,this.update({visible:!1})}_fireDidAccept(){this._onDidAcceptEmitter.fire()}_fireDidChangeValue(r){this._value=r,this._onDidChangeValueEmitter.fire(r)}_fireDidTriggerButton(r){const t=this._handlesToButtons.get(r);t&&this._onDidTriggerButtonEmitter.fire(t)}_fireDidHide(){this._expectingHide&&(this._expectingHide=this._visible,this._onDidHideEmitter.fire())}dispose(){this._disposed||(this._disposed=!0,this._fireDidHide(),this._disposables=(0,b.dispose)(this._disposables),this._updateTimeout&&(clearTimeout(this._updateTimeout),this._updateTimeout=void 0),this._onDidDispose(),d.$dispose(this._id))}update(r){if(!this._disposed){for(const t of Object.keys(r)){const c=r[t];this._pendingUpdate[t]=c===void 0?null:c}"visible"in this._pendingUpdate?(this._updateTimeout&&(clearTimeout(this._updateTimeout),this._updateTimeout=void 0),this.dispatchUpdate()):this._visible&&!this._updateTimeout&&(this._updateTimeout=setTimeout(()=>{this._updateTimeout=void 0,this.dispatchUpdate()},0))}}dispatchUpdate(){d.$createOrUpdate(this._pendingUpdate),this._pendingUpdate={id:this._id}}}w._nextId=1;function P(o){if(o instanceof T.ThemeIcon)return{id:o.id};const r=_(o),t=l(o);return{dark:typeof r=="string"?C.URI.file(r):r,light:typeof t=="string"?C.URI.file(t):t}}function l(o){return typeof o=="object"&&"light"in o?o.light:o}function _(o){return typeof o=="object"&&"dark"in o?o.dark:o}function n(o){const r=P(o.iconPath);let t,c;return"id"in r?c=y.ThemeIcon.asClassName(r):t=r,{iconPath:t,iconClass:c}}class u extends w{constructor(r,t){super(r.identifier,t);this._items=[],this._handlesToItems=new Map,this._itemsToHandles=new Map,this._canSelectMany=!1,this._matchOnDescription=!0,this._matchOnDetail=!0,this._sortByLabel=!0,this._keepScrollPosition=!1,this._activeItems=[],this._onDidChangeActiveEmitter=new p.Emitter,this._selectedItems=[],this._onDidChangeSelectionEmitter=new p.Emitter,this._onDidTriggerItemButtonEmitter=new p.Emitter,this.onDidChangeActive=this._onDidChangeActiveEmitter.event,this.onDidChangeSelection=this._onDidChangeSelectionEmitter.event,this.onDidTriggerItemButton=this._onDidTriggerItemButtonEmitter.event,this._disposables.push(this._onDidChangeActiveEmitter,this._onDidChangeSelectionEmitter,this._onDidTriggerItemButtonEmitter),this.update({type:"quickPick"})}get items(){return this._items}set items(r){this._items=r.slice(),this._handlesToItems.clear(),this._itemsToHandles.clear(),r.forEach((c,v)=>{this._handlesToItems.set(v,c),this._itemsToHandles.set(c,v)});const t=[];for(let c=0;c<r.length;c++){const v=r[c];v.kind===T.QuickPickItemKind.Separator?t.push({type:"separator",label:v.label}):t.push({handle:c,label:v.label,description:v.description,detail:v.detail,picked:v.picked,alwaysShow:v.alwaysShow,buttons:v.buttons?.map((g,D)=>({...n(g),tooltip:g.tooltip,handle:D}))})}this.update({items:t})}get canSelectMany(){return this._canSelectMany}set canSelectMany(r){this._canSelectMany=r,this.update({canSelectMany:r})}get matchOnDescription(){return this._matchOnDescription}set matchOnDescription(r){this._matchOnDescription=r,this.update({matchOnDescription:r})}get matchOnDetail(){return this._matchOnDetail}set matchOnDetail(r){this._matchOnDetail=r,this.update({matchOnDetail:r})}get sortByLabel(){return this._sortByLabel}set sortByLabel(r){this._sortByLabel=r,this.update({sortByLabel:r})}get keepScrollPosition(){return this._keepScrollPosition}set keepScrollPosition(r){this._keepScrollPosition=r,this.update({keepScrollPosition:r})}get activeItems(){return this._activeItems}set activeItems(r){this._activeItems=r.filter(t=>this._itemsToHandles.has(t)),this.update({activeItems:this._activeItems.map(t=>this._itemsToHandles.get(t))})}get selectedItems(){return this._selectedItems}set selectedItems(r){this._selectedItems=r.filter(t=>this._itemsToHandles.has(t)),this.update({selectedItems:this._selectedItems.map(t=>this._itemsToHandles.get(t))})}_fireDidChangeActive(r){const t=(0,A.coalesce)(r.map(c=>this._handlesToItems.get(c)));this._activeItems=t,this._onDidChangeActiveEmitter.fire(t)}_fireDidChangeSelection(r){const t=(0,A.coalesce)(r.map(c=>this._handlesToItems.get(c)));this._selectedItems=t,this._onDidChangeSelectionEmitter.fire(t)}_fireDidTriggerItemButton(r,t){const c=this._handlesToItems.get(r);if(!c||!c.buttons||!c.buttons.length)return;const v=c.buttons[t];v&&this._onDidTriggerItemButtonEmitter.fire({button:v,item:c})}}class i extends w{constructor(r,t){super(r.identifier,t);this._password=!1,this.update({type:"inputBox"})}get password(){return this._password}set password(r){this._password=r,this.update({password:r})}get prompt(){return this._prompt}set prompt(r){this._prompt=r,this.update({prompt:r})}get validationMessage(){return this._validationMessage}set validationMessage(r){this._validationMessage=r,r?typeof r=="string"?this.update({validationMessage:r,severity:R.default.Error}):this.update({validationMessage:r.message,severity:r.severity??R.default.Error}):this.update({validationMessage:void 0,severity:R.default.Ignore})}}return new a(f,h)}e.createExtHostQuickOpen=m});var Je=this&&this.__classPrivateFieldSet||function(ee,e,s,p,b){if(p==="m")throw new TypeError("Private method is not writable");if(p==="a"&&!b)throw new TypeError("Private accessor was defined without a setter");if(typeof e=="function"?ee!==e||!b:!e.has(ee))throw new TypeError("Cannot write private member to an object whose class did not declare it");return p==="a"?b.call(ee,s):b?b.value=s:e.set(ee,s),s},Ae=this&&this.__classPrivateFieldGet||function(ee,e,s,p){if(s==="a"&&!p)throw new TypeError("Private accessor was defined without a getter");if(typeof e=="function"?ee!==e||!p:!e.has(ee))throw new TypeError("Cannot read private member from an object whose class did not declare it");return s==="m"?p:s==="a"?p.call(ee):p?p.value:e.get(ee)};define(ye[210],Ce([1,0,2,4,54,7,13,5,16,111,14,27,60,8,24]),function(ee,e,s,p,b,L,C,T,E,A,R,y,m,I,f){"use strict";var h,d;Object.defineProperty(e,"__esModule",{value:!0}),e.ExtHostSCM=e.ExtHostSCMInputBox=void 0;function a(v){if(v)return typeof v.iconPath=="string"?s.URI.file(v.iconPath):s.URI.isUri(v.iconPath)||m.ThemeIcon.isThemeIcon(v.iconPath)?v.iconPath:void 0}function w(v,g){if(!v.iconPath&&!g.iconPath)return 0;if(v.iconPath){if(!g.iconPath)return 1}else return-1;const D=typeof v.iconPath=="string"?v.iconPath:s.URI.isUri(v.iconPath)?v.iconPath.fsPath:v.iconPath.id,U=typeof g.iconPath=="string"?g.iconPath:s.URI.isUri(g.iconPath)?g.iconPath.fsPath:g.iconPath.id;return(0,A.comparePaths)(D,U)}function P(v,g){let D=0;if(v.strikeThrough!==g.strikeThrough)return v.strikeThrough?1:-1;if(v.faded!==g.faded)return v.faded?1:-1;if(v.tooltip!==g.tooltip)return(v.tooltip||"").localeCompare(g.tooltip||"");if(D=w(v,g),D!==0)return D;if(v.light&&g.light)D=w(v.light,g.light);else{if(v.light)return 1;if(g.light)return-1}if(D!==0)return D;if(v.dark&&g.dark)D=w(v.dark,g.dark);else{if(v.dark)return 1;if(g.dark)return-1}return D}function l(v,g){if(v.command!==g.command)return v.command<g.command?-1:1;if(v.title!==g.title)return v.title<g.title?-1:1;if(v.tooltip!==g.tooltip){if(v.tooltip!==void 0&&g.tooltip!==void 0)return v.tooltip<g.tooltip?-1:1;if(v.tooltip!==void 0)return 1;if(g.tooltip!==void 0)return-1}if(v.arguments===g.arguments)return 0;if(v.arguments)if(g.arguments){if(v.arguments.length!==g.arguments.length)return v.arguments.length-g.arguments.length}else return 1;else return-1;for(let D=0;D<v.arguments.length;D++){const U=v.arguments[D],W=g.arguments[D];if(U!==W)return U<W?-1:1}return 0}function _(v,g){let D=(0,A.comparePaths)(v.resourceUri.fsPath,g.resourceUri.fsPath,!0);if(D!==0)return D;if(v.command&&g.command)D=l(v.command,g.command);else{if(v.command)return 1;if(g.command)return-1}if(D!==0)return D;if(v.decorations&&g.decorations)D=P(v.decorations,g.decorations);else{if(v.decorations)return 1;if(g.decorations)return-1}return D}function n(v,g){for(let D=0;D<v.length;D++)if(v[D]!==g[D])return!1;return!0}function u(v,g){return v.command===g.command&&v.title===g.title&&v.tooltip===g.tooltip&&(v.arguments&&g.arguments?n(v.arguments,g.arguments):v.arguments===g.arguments)}function i(v,g){return(0,E.equals)(v,g,u)}class o{constructor(g,D,U){this._extension=g,this._sourceControlHandle=U,h.set(this,void 0),this._value="",this._onDidChange=new p.Emitter,this._placeholder="",this._enabled=!0,this._visible=!0,Je(this,h,D,"f")}get value(){return this._value}set value(g){g=g??"",Ae(this,h,"f").$setInputBoxValue(this._sourceControlHandle,g),this.updateValue(g)}get onDidChange(){return this._onDidChange.event}get placeholder(){return this._placeholder}set placeholder(g){Ae(this,h,"f").$setInputBoxPlaceholder(this._sourceControlHandle,g),this._placeholder=g}get validateInput(){return(0,f.checkProposedApiEnabled)(this._extension,"scmValidation"),this._validateInput}set validateInput(g){if((0,f.checkProposedApiEnabled)(this._extension,"scmValidation"),g&&typeof g!="function")throw new Error(`[${this._extension.identifier.value}]: Invalid SCM input box validation function`);this._validateInput=g,Ae(this,h,"f").$setValidationProviderIsEnabled(this._sourceControlHandle,!!g)}get enabled(){return this._enabled}set enabled(g){g=!!g,this._enabled!==g&&(this._enabled=g,Ae(this,h,"f").$setInputBoxEnablement(this._sourceControlHandle,g))}get visible(){return this._visible}set visible(g){g=!!g,this._visible!==g&&(this._visible=g,Ae(this,h,"f").$setInputBoxVisibility(this._sourceControlHandle,g))}showValidationMessage(g,D){(0,f.checkProposedApiEnabled)(this._extension,"scmValidation"),Ae(this,h,"f").$showValidationMessage(this._sourceControlHandle,g,D)}$onInputBoxValueChange(g){this.updateValue(g)}updateValue(g){this._value=g,this._onDidChange.fire(g)}}e.ExtHostSCMInputBox=o,h=new WeakMap;class r{constructor(g,D,U,W,M){this._proxy=g,this._commands=D,this._sourceControlHandle=U,this._id=W,this._label=M,this._resourceHandlePool=0,this._resourceStates=[],this._resourceStatesMap=new Map,this._resourceStatesCommandsMap=new Map,this._resourceStatesDisposablesMap=new Map,this._onDidUpdateResourceStates=new p.Emitter,this.onDidUpdateResourceStates=this._onDidUpdateResourceStates.event,this._disposed=!1,this._onDidDispose=new p.Emitter,this.onDidDispose=this._onDidDispose.event,this._handlesSnapshot=[],this._resourceSnapshot=[],this._hideWhenEmpty=void 0,this.handle=r._handlePool++}get disposed(){return this._disposed}get id(){return this._id}get label(){return this._label}set label(g){this._label=g,this._proxy.$updateGroupLabel(this._sourceControlHandle,this.handle,g)}get hideWhenEmpty(){return this._hideWhenEmpty}set hideWhenEmpty(g){this._hideWhenEmpty=g,this._proxy.$updateGroup(this._sourceControlHandle,this.handle,this.features)}get features(){return{hideWhenEmpty:this.hideWhenEmpty}}get resourceStates(){return[...this._resourceStates]}set resourceStates(g){this._resourceStates=[...g],this._onDidUpdateResourceStates.fire()}getResourceState(g){return this._resourceStatesMap.get(g)}$executeResourceCommand(g,D){const U=this._resourceStatesCommandsMap.get(g);return U?(0,C.asPromise)(()=>this._commands.executeCommand(U.command,...U.arguments||[],D)):Promise.resolve(void 0)}_takeResourceStateSnapshot(){const g=[...this._resourceStates].sort(_),U=(0,E.sortedDiff)(this._resourceSnapshot,g,_).map(S=>{const z=S.toInsert.map($=>{const N=this._resourceHandlePool++;this._resourceStatesMap.set(N,$);const K=$.resourceUri;let V;if($.command)if($.command.command==="vscode.open"||$.command.command==="vscode.diff"){const ve=new L.DisposableStore;V=this._commands.converter.toInternal($.command,ve),this._resourceStatesDisposablesMap.set(N,ve)}else this._resourceStatesCommandsMap.set(N,$.command);const F=a($.decorations),ne=$.decorations&&a($.decorations.light)||F,ce=$.decorations&&a($.decorations.dark)||F,re=[ne,ce],fe=$.decorations&&$.decorations.tooltip||"",ie=$.decorations&&!!$.decorations.strikeThrough,Ee=$.decorations&&!!$.decorations.faded,be=$.contextValue||"";return{rawResource:[N,K,re,fe,ie,Ee,be,V],handle:N}});return{start:S.start,deleteCount:S.deleteCount,toInsert:z}}),W=U.map(({start:S,deleteCount:z,toInsert:$})=>[S,z,$.map(N=>N.rawResource)]),M=U.reverse();for(const{start:S,deleteCount:z,toInsert:$}of M){const N=$.map(V=>V.handle),K=this._handlesSnapshot.splice(S,z,...N);for(const V of K)this._resourceStatesMap.delete(V),this._resourceStatesCommandsMap.delete(V),this._resourceStatesDisposablesMap.get(V)?.dispose(),this._resourceStatesDisposablesMap.delete(V)}return this._resourceSnapshot=g,W}dispose(){this._disposed=!0,this._onDidDispose.fire()}}r._handlePool=0;class t{constructor(g,D,U,W,M,S){this._extension=g,this._commands=U,this._id=W,this._label=M,this._rootUri=S,d.set(this,void 0),this._groups=new Map,this._count=void 0,this._quickDiffProvider=void 0,this._commitTemplate=void 0,this._acceptInputDisposables=new L.MutableDisposable,this._acceptInputCommand=void 0,this._actionButtonDisposables=new L.MutableDisposable,this._statusBarDisposables=new L.MutableDisposable,this._statusBarCommands=void 0,this._selected=!1,this._onDidChangeSelection=new p.Emitter,this.onDidChangeSelection=this._onDidChangeSelection.event,this.handle=t._handlePool++,this.createdResourceGroups=new Map,this.updatedResourceGroups=new Set,Je(this,d,D,"f"),this._inputBox=new o(g,Ae(this,d,"f"),this.handle),Ae(this,d,"f").$registerSourceControl(this.handle,W,M,S)}get id(){return this._id}get label(){return this._label}get rootUri(){return this._rootUri}get inputBox(){return this._inputBox}get count(){return this._count}set count(g){this._count!==g&&(this._count=g,Ae(this,d,"f").$updateSourceControl(this.handle,{count:g}))}get quickDiffProvider(){return this._quickDiffProvider}set quickDiffProvider(g){this._quickDiffProvider=g,Ae(this,d,"f").$updateSourceControl(this.handle,{hasQuickDiffProvider:!!g})}get commitTemplate(){return this._commitTemplate}set commitTemplate(g){g!==this._commitTemplate&&(this._commitTemplate=g,Ae(this,d,"f").$updateSourceControl(this.handle,{commitTemplate:g}))}get acceptInputCommand(){return this._acceptInputCommand}set acceptInputCommand(g){this._acceptInputDisposables.value=new L.DisposableStore,this._acceptInputCommand=g;const D=this._commands.converter.toInternal(g,this._acceptInputDisposables.value);Ae(this,d,"f").$updateSourceControl(this.handle,{acceptInputCommand:D})}get actionButton(){return(0,f.checkProposedApiEnabled)(this._extension,"scmActionButton"),this._actionButton}set actionButton(g){(0,f.checkProposedApiEnabled)(this._extension,"scmActionButton"),this._actionButtonDisposables.value=new L.DisposableStore,this._actionButton=g;const D=g!==void 0?{command:this._commands.converter.toInternal(g.command,this._actionButtonDisposables.value),secondaryCommands:g.secondaryCommands?.map(U=>U.map(W=>this._commands.converter.toInternal(W,this._actionButtonDisposables.value))),description:g.description,enabled:g.enabled}:void 0;Ae(this,d,"f").$updateSourceControl(this.handle,{actionButton:D??null})}get statusBarCommands(){return this._statusBarCommands}set statusBarCommands(g){if(this._statusBarCommands&&g&&i(this._statusBarCommands,g))return;this._statusBarDisposables.value=new L.DisposableStore,this._statusBarCommands=g;const D=(g||[]).map(U=>this._commands.converter.toInternal(U,this._statusBarDisposables.value));Ae(this,d,"f").$updateSourceControl(this.handle,{statusBarCommands:D})}get selected(){return this._selected}createResourceGroup(g,D){const U=new r(Ae(this,d,"f"),this._commands,this.handle,g,D),W=p.Event.once(U.onDidDispose)(()=>this.createdResourceGroups.delete(U));return this.createdResourceGroups.set(U,W),this.eventuallyAddResourceGroups(),U}eventuallyAddResourceGroups(){const g=[],D=[];for(const[U,W]of this.createdResourceGroups){W.dispose();const M=U.onDidUpdateResourceStates(()=>{this.updatedResourceGroups.add(U),this.eventuallyUpdateResourceStates()});p.Event.once(U.onDidDispose)(()=>{this.updatedResourceGroups.delete(U),M.dispose(),this._groups.delete(U.handle),Ae(this,d,"f").$unregisterGroup(this.handle,U.handle)}),g.push([U.handle,U.id,U.label,U.features]);const S=U._takeResourceStateSnapshot();S.length>0&&D.push([U.handle,S]),this._groups.set(U.handle,U)}Ae(this,d,"f").$registerGroups(this.handle,g,D),this.createdResourceGroups.clear()}eventuallyUpdateResourceStates(){const g=[];this.updatedResourceGroups.forEach(D=>{const U=D._takeResourceStateSnapshot();U.length!==0&&g.push([D.handle,U])}),g.length>0&&Ae(this,d,"f").$spliceResourceStates(this.handle,g),this.updatedResourceGroups.clear()}getResourceGroup(g){return this._groups.get(g)}setSelectionState(g){this._selected=g,this._onDidChangeSelection.fire(g)}dispose(){this._acceptInputDisposables.dispose(),this._actionButtonDisposables.dispose(),this._statusBarDisposables.dispose(),this._groups.forEach(g=>g.dispose()),Ae(this,d,"f").$unregisterSourceControl(this.handle)}}d=new WeakMap,t._handlePool=0,ze([(0,b.debounce)(100)],t.prototype,"eventuallyAddResourceGroups",null),ze([(0,b.debounce)(100)],t.prototype,"eventuallyUpdateResourceStates",null);let c=class Xi{constructor(g,D,U){this._commands=D,this.logService=U,this._sourceControls=new Map,this._sourceControlsByExtension=new Map,this._onDidChangeActiveProvider=new p.Emitter,this._proxy=g.getProxy(T.MainContext.MainThreadSCM),this._telemetry=g.getProxy(T.MainContext.MainThreadTelemetry),D.registerArgumentProcessor({processArgument:W=>{if(W&&W.$mid===3){const M=this._sourceControls.get(W.sourceControlHandle);if(!M)return W;const S=M.getResourceGroup(W.groupHandle);return S?S.getResourceState(W.handle):W}else if(W&&W.$mid===4){const M=this._sourceControls.get(W.sourceControlHandle);return M?M.getResourceGroup(W.groupHandle):W}else if(W&&W.$mid===5){const M=this._sourceControls.get(W.handle);return M||W}return W}})}get onDidChangeActiveProvider(){return this._onDidChangeActiveProvider.event}createSourceControl(g,D,U,W){this.logService.trace("ExtHostSCM#createSourceControl",g.identifier.value,D,U,W),this._telemetry.$publicLog2("api/scm/createSourceControl",{extensionId:g.identifier.value});const M=Xi._handlePool++,S=new t(g,this._proxy,this._commands,D,U,W);this._sourceControls.set(M,S);const z=this._sourceControlsByExtension.get(y.ExtensionIdentifier.toKey(g.identifier))||[];return z.push(S),this._sourceControlsByExtension.set(y.ExtensionIdentifier.toKey(g.identifier),z),S}getLastInputBox(g){this.logService.trace("ExtHostSCM#getLastInputBox",g.identifier.value);const D=this._sourceControlsByExtension.get(y.ExtensionIdentifier.toKey(g.identifier)),U=D&&D[D.length-1];return U&&U.inputBox}$provideOriginalResource(g,D,U){const W=s.URI.revive(D);this.logService.trace("ExtHostSCM#$provideOriginalResource",g,W.toString());const M=this._sourceControls.get(g);return!M||!M.quickDiffProvider||!M.quickDiffProvider.provideOriginalResource?Promise.resolve(null):(0,C.asPromise)(()=>M.quickDiffProvider.provideOriginalResource(W,U)).then(S=>S||null)}$onInputBoxValueChange(g,D){this.logService.trace("ExtHostSCM#$onInputBoxValueChange",g);const U=this._sourceControls.get(g);return U&&U.inputBox.$onInputBoxValueChange(D),Promise.resolve(void 0)}$executeResourceCommand(g,D,U,W){this.logService.trace("ExtHostSCM#$executeResourceCommand",g,D,U);const M=this._sourceControls.get(g);if(!M)return Promise.resolve(void 0);const S=M.getResourceGroup(D);return S?S.$executeResourceCommand(U,W):Promise.resolve(void 0)}$validateInput(g,D,U){this.logService.trace("ExtHostSCM#$validateInput",g);const W=this._sourceControls.get(g);return!W||!W.inputBox.validateInput?Promise.resolve(void 0):(0,C.asPromise)(()=>W.inputBox.validateInput(D,U)).then(M=>{if(!M)return Promise.resolve(void 0);const S=I.MarkdownString.fromStrict(M.message);return S?Promise.resolve([S,M.type]):Promise.resolve(void 0)})}$setSelectedSourceControl(g){return this.logService.trace("ExtHostSCM#$setSelectedSourceControl",g),g!==void 0&&this._sourceControls.get(g)?.setSelectionState(!0),this._selectedSourceControlHandle!==void 0&&this._sourceControls.get(this._selectedSourceControlHandle)?.setSelectionState(!1),this._selectedSourceControlHandle=g,Promise.resolve(void 0)}};c._handlePool=0,c=ze([xe(2,R.ILogService)],c),e.ExtHostSCM=c});var Je=this&&this.__classPrivateFieldSet||function(ee,e,s,p,b){if(p==="m")throw new TypeError("Private method is not writable");if(p==="a"&&!b)throw new TypeError("Private accessor was defined without a setter");if(typeof e=="function"?ee!==e||!b:!e.has(ee))throw new TypeError("Cannot write private member to an object whose class did not declare it");return p==="a"?b.call(ee,s):b?b.value=s:e.set(ee,s),s},Ae=this&&this.__classPrivateFieldGet||function(ee,e,s,p){if(s==="a"&&!p)throw new TypeError("Private accessor was defined without a getter");if(typeof e=="function"?ee!==e||!p:!e.has(ee))throw new TypeError("Cannot read private member from an object whose class did not declare it");return s==="m"?p:s==="a"?p.call(ee):p?p.value:e.get(ee)};define(ye[211],Ce([1,0,6,5,131,7,8,10]),function(ee,e,s,p,b,L,C,T){"use strict";var E,A;Object.defineProperty(e,"__esModule",{value:!0}),e.ExtHostStatusBar=e.ExtHostStatusBarEntry=void 0;class R{constructor(f,h,d,a,w=s.StatusBarAlignment.Left,P){E.set(this,void 0),A.set(this,void 0),this._disposed=!1,this._visible=!1,this._text="",this._internalCommandRegistration=new L.DisposableStore,Je(this,E,f,"f"),Je(this,A,h,"f"),this._entryId=R.ID_GEN++,this._extension=d,this._id=a,this._alignment=w,this._priority=this.validatePriority(P)}validatePriority(f){if(!!(0,T.isNumber)(f))return f===Number.POSITIVE_INFINITY?Number.MAX_VALUE:f===Number.NEGATIVE_INFINITY?-Number.MAX_VALUE:f}get id(){return this._id??this._extension.identifier.value}get alignment(){return this._alignment}get priority(){return this._priority}get text(){return this._text}get name(){return this._name}get tooltip(){return this._tooltip}get color(){return this._color}get backgroundColor(){return this._backgroundColor}get command(){return this._command?.fromApi}get accessibilityInformation(){return this._accessibilityInformation}set text(f){this._text=f,this.update()}set name(f){this._name=f,this.update()}set tooltip(f){this._tooltip=f,this.update()}set color(f){this._color=f,this.update()}set backgroundColor(f){f&&!R.ALLOWED_BACKGROUND_COLORS.has(f.id)&&(f=void 0),this._backgroundColor=f,this.update()}set command(f){this._command?.fromApi!==f&&(this._internalCommandRegistration.clear(),typeof f=="string"?this._command={fromApi:f,internal:Ae(this,A,"f").toInternal({title:"",command:f},this._internalCommandRegistration)}:f?this._command={fromApi:f,internal:Ae(this,A,"f").toInternal(f,this._internalCommandRegistration)}:this._command=void 0,this.update())}set accessibilityInformation(f){this._accessibilityInformation=f,this.update()}show(){this._visible=!0,this.update()}hide(){clearTimeout(this._timeoutHandle),this._visible=!1,Ae(this,E,"f").$dispose(this._entryId)}update(){this._disposed||!this._visible||(clearTimeout(this._timeoutHandle),this._timeoutHandle=setTimeout(()=>{this._timeoutHandle=void 0;let f;this._extension?this._id?f=`${this._extension.identifier.value}.${this._id}`:f=this._extension.identifier.value:f=this._id;let h;this._name?h=this._name:h=(0,b.localize)(0,null,this._extension.displayName||this._extension.name);let d=this._color;this._backgroundColor&&(d=R.ALLOWED_BACKGROUND_COLORS.get(this._backgroundColor.id));const a=C.MarkdownString.fromStrict(this._tooltip);Ae(this,E,"f").$setEntry(this._entryId,f,h,this._text,a,this._command?.internal,d,this._backgroundColor,this._alignment===s.StatusBarAlignment.Left,this._priority,this._accessibilityInformation)},0))}dispose(){this.hide(),this._disposed=!0}}e.ExtHostStatusBarEntry=R,E=new WeakMap,A=new WeakMap,R.ID_GEN=0,R.ALLOWED_BACKGROUND_COLORS=new Map([["statusBarItem.errorBackground",new s.ThemeColor("statusBarItem.errorForeground")],["statusBarItem.warningBackground",new s.ThemeColor("statusBarItem.warningForeground")]]);class y{constructor(f){this._messages=[],this._item=f.createStatusBarEntry(void 0,"status.extensionMessage",s.StatusBarAlignment.Left,Number.MIN_VALUE),this._item.name=(0,b.localize)(1,null)}dispose(){this._messages.length=0,this._item.dispose()}setMessage(f){const h={message:f};return this._messages.unshift(h),this._update(),new s.Disposable(()=>{const d=this._messages.indexOf(h);d>=0&&(this._messages.splice(d,1),this._update())})}_update(){this._messages.length>0?(this._item.text=this._messages[0].message,this._item.show()):this._item.hide()}}class m{constructor(f,h){this._proxy=f.getProxy(p.MainContext.MainThreadStatusBar),this._commands=h,this._statusMessage=new y(this)}createStatusBarEntry(f,h,d,a){return new R(this._proxy,this._commands,f,h,d,a)}setStatusBarMessage(f,h){const d=this._statusMessage.setMessage(f);let a;return typeof h=="number"?a=setTimeout(()=>d.dispose(),h):typeof h!="undefined"&&h.then(()=>d.dispose(),()=>d.dispose()),new s.Disposable(()=>{d.dispose(),clearTimeout(a)})}}e.ExtHostStatusBar=m}),define(ye[69],Ce([1,0,5,4,3]),function(ee,e,s,p,b){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.IExtHostStorage=e.ExtHostStorage=void 0;class L{constructor(T){this._onDidChangeStorage=new p.Emitter,this.onDidChangeStorage=this._onDidChangeStorage.event,this._proxy=T.getProxy(s.MainContext.MainThreadStorage)}registerExtensionStorageKeysToSync(T,E){this._proxy.$registerExtensionStorageKeysToSync(T,E)}initializeExtensionStorage(T,E,A){return this._proxy.$initializeExtensionStorage(T,E).then(R=>R||A)}setValue(T,E,A){return this._proxy.$setValue(T,E,A)}$acceptValue(T,E,A){this._onDidChangeStorage.fire({shared:T,key:E,value:A})}}e.ExtHostStorage=L,e.IExtHostStorage=(0,b.createDecorator)("IExtHostStorage")}),define(ye[70],Ce([1,0,3,28,14,51,2]),function(ee,e,s,p,b,L,C){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.ExtensionStoragePaths=e.IExtensionStoragePaths=void 0,e.IExtensionStoragePaths=(0,s.createDecorator)("IExtensionStoragePaths");let T=class{constructor(A,R,y){this._logService=R,this._extHostFileSystem=y,this._workspace=A.workspace??void 0,this._environment=A.environment,this.whenReady=this._getOrCreateWorkspaceStoragePath().then(m=>this._value=m)}async _getWorkspaceStorageURI(A){return C.URI.joinPath(this._environment.workspaceStorageHome,A)}async _getOrCreateWorkspaceStoragePath(){if(!this._workspace)return Promise.resolve(void 0);const A=this._workspace.id,R=await this._getWorkspaceStorageURI(A);try{return await this._extHostFileSystem.value.stat(R),this._logService.trace("[ExtHostStorage] storage dir already exists",R),R}catch{}try{return this._logService.trace("[ExtHostStorage] creating dir and metadata-file",R),await this._extHostFileSystem.value.createDirectory(R),await this._extHostFileSystem.value.writeFile(C.URI.joinPath(R,"meta.json"),new TextEncoder().encode(JSON.stringify({id:this._workspace.id,configuration:C.URI.revive(this._workspace.configuration)?.toString(),name:this._workspace.name},void 0,2))),R}catch(y){this._logService.error("[ExtHostStorage]",y);return}}workspaceValue(A){if(this._value)return C.URI.joinPath(this._value,A.identifier.value)}globalValue(A){return C.URI.joinPath(this._environment.globalStorageHome,A.identifier.value.toLowerCase())}onWillDeactivateAll(){}};T=ze([xe(0,p.IExtHostInitDataService),xe(1,b.ILogService),xe(2,L.IExtHostConsumerFileSystem)],T),e.ExtensionStoragePaths=T}),define(ye[52],Ce([1,0,4,5,3,2,15,7,6,132,11,169,20,43,153,60,10,13]),function(ee,e,s,p,b,L,C,T,E,A,R,y,m,I,f,h,d,a){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.WorkerExtHostTerminalService=e.EnvironmentVariableCollection=e.BaseExtHostTerminalService=e.ExtHostPseudoterminal=e.ExtHostTerminal=e.IExtHostTerminalService=void 0,e.IExtHostTerminalService=(0,b.createDecorator)("IExtHostTerminalService");class w{constructor(t,c,v,g){this._proxy=t,this._id=c,this._creationOptions=v,this._name=g,this._disposed=!1,this._state={isInteractedWith:!1},this.isOpen=!1,this._creationOptions=Object.freeze(this._creationOptions),this._pidPromise=new Promise(U=>this._pidPromiseComplete=U);const D=this;this.value={get name(){return D._name||""},get processId(){return D._pidPromise},get creationOptions(){return D._creationOptions},get exitStatus(){return D._exitStatus},get state(){return D._state},sendText(U,W=!0){D._checkDisposed(),D._proxy.$sendText(D._id,U,W)},show(U){D._checkDisposed(),D._proxy.$show(D._id,U)},hide(){D._checkDisposed(),D._proxy.$hide(D._id)},dispose(){D._disposed||(D._disposed=!0,D._proxy.$dispose(D._id))},get dimensions(){if(!(D._cols===void 0||D._rows===void 0))return{columns:D._cols,rows:D._rows}}}}async create(t,c){if(typeof this._id!="string")throw new Error("Terminal has already been created");await this._proxy.$createTerminal(this._id,{name:t.name,shellPath:(0,d.withNullAsUndefined)(t.shellPath),shellArgs:(0,d.withNullAsUndefined)(t.shellArgs),cwd:(0,d.withNullAsUndefined)(t.cwd),env:(0,d.withNullAsUndefined)(t.env),icon:(0,d.withNullAsUndefined)(i(t.iconPath)),color:h.ThemeColor.isThemeColor(t.color)?t.color.id:void 0,initialText:(0,d.withNullAsUndefined)(t.message),strictEnv:(0,d.withNullAsUndefined)(t.strictEnv),hideFromUser:(0,d.withNullAsUndefined)(t.hideFromUser),isFeatureTerminal:(0,d.withNullAsUndefined)(c?.isFeatureTerminal),isExtensionOwnedTerminal:!0,useShellEnvironment:(0,d.withNullAsUndefined)(c?.useShellEnvironment),location:c?.location||this._serializeParentTerminal(t.location,c?.resolvedExtHostIdentifier),isTransient:(0,d.withNullAsUndefined)(t.isTransient)})}async createExtensionTerminal(t,c,v,g){if(typeof this._id!="string")throw new Error("Terminal has already been created");if(await this._proxy.$createTerminal(this._id,{name:this._name,isExtensionCustomPtyTerminal:!0,icon:v,color:h.ThemeColor.isThemeColor(g)?g.id:void 0,location:this._serializeParentTerminal(t,c),isTransient:!0}),typeof this._id=="string")throw new Error("Terminal creation failed");return this._id}_serializeParentTerminal(t,c){return typeof t=="object"?"parentTerminal"in t&&t.parentTerminal&&c?{parentTerminal:c}:"viewColumn"in t?{viewColumn:t.viewColumn,preserveFocus:t.preserveFocus}:void 0:t}_checkDisposed(){if(this._disposed)throw new Error("Terminal has already been disposed")}set name(t){this._name=t}setExitStatus(t,c){this._exitStatus=Object.freeze({code:t,reason:c})}setDimensions(t,c){return t===this._cols&&c===this._rows||t===0||c===0?!1:(this._cols=t,this._rows=c,!0)}setInteractedWith(){return this._state.isInteractedWith?!1:(this._state={isInteractedWith:!0},!0)}_setProcessId(t){this._pidPromiseComplete?(this._pidPromiseComplete(t),this._pidPromiseComplete=void 0):this._pidPromise.then(c=>{c!==t&&(this._pidPromise=Promise.resolve(t))})}}e.ExtHostTerminal=w;class P{constructor(t){this._pty=t,this.id=0,this.shouldPersist=!1,this._onProcessData=new s.Emitter,this.onProcessData=this._onProcessData.event,this._onProcessReady=new s.Emitter,this._onDidChangeProperty=new s.Emitter,this.onDidChangeProperty=this._onDidChangeProperty.event,this._onProcessExit=new s.Emitter,this.onProcessExit=this._onProcessExit.event}get onProcessReady(){return this._onProcessReady.event}refreshProperty(t){throw new Error(`refreshProperty is not suppported in extension owned terminals. property: ${t}`)}updateProperty(t,c){throw new Error(`updateProperty is not suppported in extension owned terminals. property: ${t}, value: ${c}`)}async start(){}shutdown(){this._pty.close()}input(t){this._pty.handleInput?.(t)}resize(t,c){this._pty.setDimensions?.({columns:t,rows:c})}async processBinary(t){}acknowledgeDataEvent(t){}async setUnicodeVersion(t){}getInitialCwd(){return Promise.resolve("")}getCwd(){return Promise.resolve("")}getLatency(){return Promise.resolve(0)}startSendingEvents(t){this._pty.onDidWrite(c=>this._onProcessData.fire(c)),this._pty.onDidClose?.((c=void 0)=>{this._onProcessExit.fire(c===void 0?void 0:c)}),this._pty.onDidOverrideDimensions?.(c=>{c&&this._onDidChangeProperty.fire({type:"overrideDimensions",value:{cols:c.columns,rows:c.rows}})}),this._pty.onDidChangeName?.(c=>{this._onDidChangeProperty.fire({type:"title",value:c})}),this._pty.open(t||void 0),t&&this._pty.setDimensions?.(t),this._onProcessReady.fire({pid:-1,cwd:""})}}e.ExtHostPseudoterminal=P;let l=1,_=class extends T.Disposable{constructor(t,c){super();this._terminals=[],this._terminalProcesses=new Map,this._terminalProcessDisposables={},this._extensionTerminalAwaitingStart={},this._getTerminalPromises={},this._environmentVariableCollections=new Map,this._linkProviders=new Set,this._profileProviders=new Map,this._terminalLinkCache=new Map,this._terminalLinkCancellationSource=new Map,this._onDidCloseTerminal=new s.Emitter,this.onDidCloseTerminal=this._onDidCloseTerminal.event,this._onDidOpenTerminal=new s.Emitter,this.onDidOpenTerminal=this._onDidOpenTerminal.event,this._onDidChangeActiveTerminal=new s.Emitter,this.onDidChangeActiveTerminal=this._onDidChangeActiveTerminal.event,this._onDidChangeTerminalDimensions=new s.Emitter,this.onDidChangeTerminalDimensions=this._onDidChangeTerminalDimensions.event,this._onDidChangeTerminalState=new s.Emitter,this.onDidChangeTerminalState=this._onDidChangeTerminalState.event,this._proxy=c.getProxy(p.MainContext.MainThreadTerminalService),this._bufferer=new f.TerminalDataBufferer(this._proxy.$sendProcessData),this._onDidWriteTerminalData=new s.Emitter({onFirstListenerAdd:()=>this._proxy.$startSendingDataEvents(),onLastListenerRemove:()=>this._proxy.$stopSendingDataEvents()}),this._proxy.$registerProcessSupport(t),this._register({dispose:()=>{for(const[v,g]of this._terminalProcesses)g.shutdown(!0)}})}get activeTerminal(){return this._activeTerminal?.value}get terminals(){return this._terminals.map(t=>t.value)}get onDidWriteTerminalData(){return this._onDidWriteTerminalData.event}getDefaultShell(t){return(t?this._defaultAutomationProfile:this._defaultProfile)?.path||""}getDefaultShellArgs(t){return(t?this._defaultAutomationProfile:this._defaultProfile)?.args||[]}createExtensionTerminal(t,c){const v=new w(this._proxy,(0,I.generateUuid)(),t,t.name),g=new P(t.pty);return v.createExtensionTerminal(t.location,this._serializeParentTerminal(t,c).resolvedExtHostIdentifier,i(t.iconPath),o(t.color)).then(D=>{const U=this._setupExtHostProcessListeners(D,g);this._terminalProcessDisposables[D]=U}),this._terminals.push(v),v.value}_serializeParentTerminal(t,c){if(c=c||{},t.location&&typeof t.location=="object"&&"parentTerminal"in t.location){const v=t.location.parentTerminal;if(v){const g=this._terminals.find(D=>D.value===v);g&&(c.resolvedExtHostIdentifier=g._id)}}else t.location&&typeof t.location!="object"?c.location=t.location:c.location&&typeof c.location=="object"&&"splitActiveTerminal"in c.location&&(c.location={splitActiveTerminal:!0});return c}attachPtyToTerminal(t,c){if(!this._getTerminalById(t))throw new Error(`Cannot resolve terminal with id ${t} for virtual process`);const g=new P(c),D=this._setupExtHostProcessListeners(t,g);this._terminalProcessDisposables[t]=D}async $acceptActiveTerminalChanged(t){const c=this._activeTerminal;if(t===null){this._activeTerminal=void 0,c!==this._activeTerminal&&this._onDidChangeActiveTerminal.fire(this._activeTerminal);return}const v=this._getTerminalById(t);v&&(this._activeTerminal=v,c!==this._activeTerminal&&this._onDidChangeActiveTerminal.fire(this._activeTerminal.value))}async $acceptTerminalProcessData(t,c){const v=this._getTerminalById(t);v&&this._onDidWriteTerminalData.fire({terminal:v.value,data:c})}async $acceptTerminalDimensions(t,c,v){const g=this._getTerminalById(t);g&&g.setDimensions(c,v)&&this._onDidChangeTerminalDimensions.fire({terminal:g.value,dimensions:g.value.dimensions})}async $acceptTerminalMaximumDimensions(t,c,v){this._terminalProcesses.get(t)?.resize(c,v)}async $acceptTerminalTitleChange(t,c){const v=this._getTerminalById(t);v&&(v.name=c)}async $acceptTerminalClosed(t,c,v){const g=this._getTerminalObjectIndexById(this._terminals,t);if(g!==null){const D=this._terminals.splice(g,1)[0];D.setExitStatus(c,v),this._onDidCloseTerminal.fire(D.value)}}$acceptTerminalOpened(t,c,v,g){if(c){const W=this._getTerminalObjectIndexById(this._terminals,c);if(W!==null){this._terminals[W]._id=t,this._onDidOpenTerminal.fire(this.terminals[W]),this._terminals[W].isOpen=!0;return}}const D={name:g.name,shellPath:g.executable,shellArgs:g.args,cwd:typeof g.cwd=="string"?g.cwd:L.URI.revive(g.cwd),env:g.env,hideFromUser:g.hideFromUser},U=new w(this._proxy,t,D,v);this._terminals.push(U),this._onDidOpenTerminal.fire(U.value),U.isOpen=!0}async $acceptTerminalProcessId(t,c){this._getTerminalById(t)?._setProcessId(c)}async $startExtensionTerminal(t,c){const v=this._getTerminalById(t);if(!v)return{message:(0,A.localize)(0,null,t)};v.isOpen||await new Promise(D=>{const U=this.onDidOpenTerminal(async W=>{W===v.value&&(U.dispose(),D())})});const g=this._terminalProcesses.get(t);g?g.startSendingEvents(c):this._extensionTerminalAwaitingStart[t]={initialDimensions:c}}_setupExtHostProcessListeners(t,c){const v=new T.DisposableStore;v.add(c.onProcessReady(D=>this._proxy.$sendProcessReady(t,D.pid,D.cwd))),v.add(c.onDidChangeProperty(D=>this._proxy.$sendProcessProperty(t,D))),this._bufferer.startBuffering(t,c.onProcessData),v.add(c.onProcessExit(D=>this._onProcessExit(t,D))),this._terminalProcesses.set(t,c);const g=this._extensionTerminalAwaitingStart[t];return g&&c instanceof P&&(c.startSendingEvents(g.initialDimensions),delete this._extensionTerminalAwaitingStart[t]),v}$acceptProcessAckDataEvent(t,c){this._terminalProcesses.get(t)?.acknowledgeDataEvent(c)}$acceptProcessInput(t,c){this._terminalProcesses.get(t)?.input(c)}$acceptTerminalInteraction(t){const c=this._getTerminalById(t);c?.setInteractedWith()&&this._onDidChangeTerminalState.fire(c.value)}$acceptProcessResize(t,c,v){try{this._terminalProcesses.get(t)?.resize(c,v)}catch(g){if(g.code!=="EPIPE"&&g.code!=="ERR_IPC_CHANNEL_CLOSED")throw g}}$acceptProcessShutdown(t,c){this._terminalProcesses.get(t)?.shutdown(c)}$acceptProcessRequestInitialCwd(t){this._terminalProcesses.get(t)?.getInitialCwd().then(c=>this._proxy.$sendProcessProperty(t,{type:"initialCwd",value:c}))}$acceptProcessRequestCwd(t){this._terminalProcesses.get(t)?.getCwd().then(c=>this._proxy.$sendProcessProperty(t,{type:"cwd",value:c}))}$acceptProcessRequestLatency(t){return Promise.resolve(t)}registerLinkProvider(t){return this._linkProviders.add(t),this._linkProviders.size===1&&this._proxy.$startLinkProvider(),new E.Disposable(()=>{this._linkProviders.delete(t),this._linkProviders.size===0&&this._proxy.$stopLinkProvider()})}registerProfileProvider(t,c,v){if(this._profileProviders.has(c))throw new Error(`Terminal profile provider "${c}" already registered`);return this._profileProviders.set(c,v),this._proxy.$registerProfileProvider(c,t.identifier.value),new E.Disposable(()=>{this._profileProviders.delete(c),this._proxy.$unregisterProfileProvider(c)})}async $createContributedProfileTerminal(t,c){const v=new m.CancellationTokenSource().token;let g=await this._profileProviders.get(t)?.provideTerminalProfile(v);if(!v.isCancellationRequested){if(g&&!("options"in g)&&(g={options:g}),!g||!("options"in g))throw new Error(`No terminal profile options provided for id "${t}"`);if("pty"in g.options){this.createExtensionTerminal(g.options,c);return}this.createTerminalFromOptions(g.options,c)}}async $provideLinks(t,c){const v=this._getTerminalById(t);if(!v)return[];this._terminalLinkCache.delete(t),this._terminalLinkCancellationSource.get(t)?.dispose(!0);const D=new m.CancellationTokenSource;this._terminalLinkCancellationSource.set(t,D);const U=[],W={terminal:v.value,line:c},M=[];for(const $ of this._linkProviders)M.push(a.Promises.withAsyncBody(async N=>{D.token.onCancellationRequested(()=>N({provider:$,links:[]}));const K=await $.provideTerminalLinks(W,D.token)||[];D.token.isCancellationRequested||N({provider:$,links:K})}));const S=await Promise.all(M);if(D.token.isCancellationRequested)return[];const z=new Map;for(const $ of S)$&&$.links.length>0&&U.push(...$.links.map(N=>{const K={id:l++,startIndex:N.startIndex,length:N.length,label:N.tooltip};return z.set(K.id,{provider:$.provider,link:N}),K}));return this._terminalLinkCache.set(t,z),U}$activateLink(t,c){const v=this._terminalLinkCache.get(t)?.get(c);!v||v.provider.handleTerminalLink(v.link)}_onProcessExit(t,c){this._bufferer.stopBuffering(t),this._terminalProcesses.delete(t),delete this._extensionTerminalAwaitingStart[t];const v=this._terminalProcessDisposables[t];v&&(v.dispose(),delete this._terminalProcessDisposables[t]),this._proxy.$sendProcessExit(t,c)}_getTerminalById(t){return this._getTerminalObjectById(this._terminals,t)}_getTerminalObjectById(t,c){const v=this._getTerminalObjectIndexById(t,c);return v!==null?t[v]:null}_getTerminalObjectIndexById(t,c){let v=null;return t.some((g,D)=>g._id===c?(v=D,!0):!1),v}getEnvironmentVariableCollection(t){let c=this._environmentVariableCollections.get(t.identifier.value);return c||(c=new n,this._setEnvironmentVariableCollection(t.identifier.value,c)),c}_syncEnvironmentVariableCollection(t,c){const v=(0,y.serializeEnvironmentVariableCollection)(c.map);this._proxy.$setEnvironmentVariableCollection(t,c.persistent,v.length===0?void 0:v)}$initEnvironmentVariableCollections(t){t.forEach(c=>{const v=c[0],g=new n(c[1]);this._setEnvironmentVariableCollection(v,g)})}$acceptDefaultProfile(t,c){this._defaultProfile=t,this._defaultAutomationProfile=c}_setEnvironmentVariableCollection(t,c){this._environmentVariableCollections.set(t,c),c.onDidChangeCollection(()=>{this._syncEnvironmentVariableCollection(t,c)})}};_=ze([xe(1,C.IExtHostRpcService)],_),e.BaseExtHostTerminalService=_;class n{constructor(t){this.map=new Map,this._persistent=!0,this._onDidChangeCollection=new s.Emitter,this.map=new Map(t)}get persistent(){return this._persistent}set persistent(t){this._persistent=t,this._onDidChangeCollection.fire()}get onDidChangeCollection(){return this._onDidChangeCollection&&this._onDidChangeCollection.event}get size(){return this.map.size}replace(t,c){this._setIfDiffers(t,{value:c,type:E.EnvironmentVariableMutatorType.Replace})}append(t,c){this._setIfDiffers(t,{value:c,type:E.EnvironmentVariableMutatorType.Append})}prepend(t,c){this._setIfDiffers(t,{value:c,type:E.EnvironmentVariableMutatorType.Prepend})}_setIfDiffers(t,c){const v=this.map.get(t);(!v||v.value!==c.value||v.type!==c.type)&&(this.map.set(t,c),this._onDidChangeCollection.fire())}get(t){return this.map.get(t)}forEach(t,c){this.map.forEach((v,g)=>t.call(c,g,v,this))}[Symbol.iterator](){return this.map.entries()}delete(t){this.map.delete(t),this._onDidChangeCollection.fire()}clear(){this.map.clear(),this._onDidChangeCollection.fire()}}e.EnvironmentVariableCollection=n;let u=class extends _{constructor(t){super(!1,t)}createTerminal(t,c,v){throw new R.NotSupportedError}createTerminalFromOptions(t,c){throw new R.NotSupportedError}};u=ze([xe(0,C.IExtHostRpcService)],u),e.WorkerExtHostTerminalService=u;function i(r){if(!(!r||typeof r=="string"))return"id"in r?{id:r.id,color:r.color}:r}function o(r){return h.ThemeColor.isThemeColor(r)?r:void 0}});var Je=this&&this.__classPrivateFieldSet||function(ee,e,s,p,b){if(p==="m")throw new TypeError("Private method is not writable");if(p==="a"&&!b)throw new TypeError("Private accessor was defined without a setter");if(typeof e=="function"?ee!==e||!b:!e.has(ee))throw new TypeError("Cannot write private member to an object whose class did not declare it");return p==="a"?b.call(ee,s):b?b.value=s:e.set(ee,s),s},Ae=this&&this.__classPrivateFieldGet||function(ee,e,s,p){if(s==="a"&&!p)throw new TypeError("Private accessor was defined without a getter");if(typeof e=="function"?ee!==e||!p:!e.has(ee))throw new TypeError("Cannot read private member from an object whose class did not declare it");return s==="m"?p:s==="a"?p.call(ee):p?p.value:e.get(ee)};define(ye[212],Ce([1,0,16,22,20,4,172,96,7,26,10,43,5,15,92,8,6,46,65,47]),function(ee,e,s,p,b,L,C,T,E,A,R,y,m,I,f,h,d,a,w,P){"use strict";var l,_;Object.defineProperty(e,"__esModule",{value:!0}),e.TestRunProfileImpl=e.MirroredTestCollection=e.TestRunDto=e.TestRunCoordinator=e.ExtHostTesting=void 0;let n=class{constructor(M,S){this.resultsChangedEmitter=new L.Emitter,this.controllers=new Map,this.onResultsChanged=this.resultsChangedEmitter.event,this.results=[],this.proxy=M.getProxy(m.MainContext.MainThreadTesting),this.observer=new g(this.proxy),this.runTracker=new i(this.proxy),S.registerArgumentProcessor({processArgument:z=>z?.$mid===13?(0,f.toItemFromContext)(z):z})}createTestController(M,S,z){if(this.controllers.has(M))throw new Error(`Attempt to insert a duplicate controller with ID "${M}"`);const $=new E.DisposableStore,N=$.add(new f.ExtHostTestItemCollection(M,S));N.root.label=S;const K=new Map,V=this.proxy,F={items:N.root.children,get label(){return S},set label(ce){S=ce,N.root.label=ce,V.$updateController(M,{label:S})},get refreshHandler(){return z},set refreshHandler(ce){z=ce,V.$updateController(M,{canRefresh:!!ce})},get id(){return M},createRunProfile:(ce,re,fe,ie,Ee)=>{let be=(0,T.hash)(ce);for(;K.has(be);)be++;return new D(this.proxy,K,M,be,ce,re,fe,ie,Ee)},createTestItem(ce,re,fe){return new f.TestItemImpl(M,ce,re,fe)},createTestRun:(ce,re,fe=!0)=>this.runTracker.createTestRun(M,N,ce,re,fe),set resolveHandler(ce){N.resolveHandler=ce},get resolveHandler(){return N.resolveHandler},dispose:()=>{$.dispose()}};V.$registerTestController(M,S,!!z),$.add((0,E.toDisposable)(()=>V.$unregisterTestController(M)));const ne={controller:F,collection:N,profiles:K};return this.controllers.set(M,ne),$.add((0,E.toDisposable)(()=>this.controllers.delete(M))),$.add(N.onDidGenerateDiff(ce=>V.$publishDiff(M,ce.map(P.TestsDiffOp.serialize)))),F}createTestObserver(){return this.observer.checkout()}async runTests(M,S=b.CancellationToken.None){const z=o(M);if(!z)throw new Error("The request passed to `vscode.test.runTests` must include a profile");const $=this.controllers.get(z.controllerId);if(!$)throw new Error("Controller not found");await this.proxy.$runTests({isUiTriggered:!1,targets:[{testIds:M.include?.map(N=>a.TestId.fromExtHostTestItem(N,$.collection.root.id).toString())??[$.collection.root.id],profileGroup:U[z.kind],profileId:z.profileId,controllerId:z.controllerId}],exclude:M.exclude?.map(N=>N.id)},S)}$provideFileCoverage(M,S,z){return(0,s.mapFind)(this.runTracker.trackers,N=>N.id===M?N.getCoverage(S):void 0)?.provideFileCoverage(z)??Promise.resolve([])}$resolveFileCoverage(M,S,z,$){return(0,s.mapFind)(this.runTracker.trackers,K=>K.id===M?K.getCoverage(S):void 0)?.resolveFileCoverage(z,$)??Promise.resolve([])}$configureRunProfile(M,S){this.controllers.get(M)?.profiles.get(S)?.configureHandler?.()}async $refreshTests(M,S){await this.controllers.get(M)?.controller.refreshHandler?.(S)}$publishTestResults(M){this.results=Object.freeze(M.map(S=>(0,A.deepFreeze)(h.TestResults.to(S))).concat(this.results).sort((S,z)=>z.completedAt-S.completedAt).slice(0,32)),this.resultsChangedEmitter.fire()}async $expandTest(M,S){const z=this.controllers.get(a.TestId.fromString(M).controllerId)?.collection;z&&(await z.expand(M,S<0?1/0:S),z.flushDiff())}$acceptDiff(M){this.observer.applyDiff(M.map(P.TestsDiffOp.deserialize))}async $runControllerTests(M,S){const z=this.controllers.get(M.controllerId);if(!z)return;const{collection:$,profiles:N}=z,K=N.get(M.profileId);if(!K)return;const V=M.testIds.map(re=>$.tree.get(re)).filter(R.isDefined),F=M.excludeExtIds.map(re=>z.collection.tree.get(re)).filter(R.isDefined).filter(re=>V.some(fe=>fe.fullId.compare(re.fullId)===2));if(!V.length)return;const ne=new d.TestRunRequest(V.some(re=>re.actual instanceof f.TestItemRootImpl)?void 0:V.map(re=>re.actual),F.map(re=>re.actual),K),ce=this.runTracker.prepareForMainThreadTestRun(ne,r.fromInternal(M,z.collection),S);try{await K.runHandler(ne,S)}finally{ce.isRunning&&!S.isCancellationRequested&&await L.Event.toPromise(ce.onEnd),ce.dispose()}}$cancelExtensionTestRun(M){M===void 0?this.runTracker.cancelAllRuns():this.runTracker.cancelRunById(M)}};n=ze([xe(0,I.IExtHostRpcService)],n),e.ExtHostTesting=n;class u extends E.Disposable{constructor(M,S,z){super();this.dto=M,this.proxy=S,this.tasks=new Map,this.sharedTestIds=new Set,this.endEmitter=this._register(new L.Emitter),this.disposed=!1,this.onEnd=this.endEmitter.event,this.cts=this._register(new b.CancellationTokenSource(z)),this._register(this.cts.token.onCancellationRequested(()=>{for(const{run:$}of this.tasks.values())$.end()}))}get isRunning(){return this.tasks.size>0}get id(){return this.dto.id}getCoverage(M){return this.tasks.get(M)?.coverage}createRun(M){const S=this.dto.id,z=this.dto.controllerId,$=(0,y.generateUuid)(),N=new t(this.proxy,S,$),K=ce=>(re,...fe)=>{if(F){console.warn(`Setting the state of test "${re.id}" is a no-op after the run ends.`);return}!this.dto.isIncluded(re)||(this.ensureTestIsKnown(re),ce(re,...fe))},V=(ce,re)=>{const fe=re instanceof Array?re.map(h.TestMessage.from):[h.TestMessage.from(re)];if(ce.uri&&ce.range){const ie={range:h.Range.from(ce.range),uri:ce.uri};for(const Ee of fe)Ee.location=Ee.location||ie}this.proxy.$appendTestMessagesInRun(S,$,a.TestId.fromExtHostTestItem(ce,z).toString(),fe)};let F=!1;const ne={isPersisted:this.dto.isPersisted,token:this.cts.token,name:M,get coverageProvider(){return N.coverageProvider},set coverageProvider(ce){N.coverageProvider=ce},enqueued:K(ce=>{this.proxy.$updateTestStateInRun(S,$,a.TestId.fromExtHostTestItem(ce,z).toString(),1)}),skipped:K(ce=>{this.proxy.$updateTestStateInRun(S,$,a.TestId.fromExtHostTestItem(ce,z).toString(),5)}),started:K(ce=>{this.proxy.$updateTestStateInRun(S,$,a.TestId.fromExtHostTestItem(ce,z).toString(),2)}),errored:K((ce,re,fe)=>{V(ce,re),this.proxy.$updateTestStateInRun(S,$,a.TestId.fromExtHostTestItem(ce,z).toString(),6,fe)}),failed:K((ce,re,fe)=>{V(ce,re),this.proxy.$updateTestStateInRun(S,$,a.TestId.fromExtHostTestItem(ce,z).toString(),4,fe)}),passed:K((ce,re)=>{this.proxy.$updateTestStateInRun(S,$,a.TestId.fromExtHostTestItem(ce,this.dto.controllerId).toString(),3,re)}),appendOutput:(ce,re,fe)=>{F||(fe&&(this.dto.isIncluded(fe)?this.ensureTestIsKnown(fe):fe=void 0),this.proxy.$appendOutputToRun(S,$,p.VSBuffer.fromString(ce),re&&h.location.from(re),fe&&a.TestId.fromExtHostTestItem(fe,z).toString()))},end:()=>{F||(F=!0,this.proxy.$finishedTestRunTask(S,$),this.tasks.delete($),this.isRunning||this.dispose())}};return this.tasks.set($,{run:ne,coverage:N}),this.proxy.$startedTestRunTask(S,{id:$,name:M,running:!0}),ne}dispose(){this.disposed||(this.disposed=!0,this.endEmitter.fire(),this.cts.cancel(),super.dispose())}ensureTestIsKnown(M){if(!(M instanceof f.TestItemImpl))throw new w.InvalidTestItemError(M.id);if(this.sharedTestIds.has(a.TestId.fromExtHostTestItem(M,this.dto.controllerId).toString()))return;const S=[],z=this.dto.colllection.root;for(;;){const $=h.TestItem.from(M);if(S.unshift($),this.sharedTestIds.has($.extId)||(this.sharedTestIds.add($.extId),M===z))break;M=M.parent||z}this.proxy.$addTestsToRun(this.dto.controllerId,this.dto.id,S)}}class i{constructor(M){this.proxy=M,this.tracked=new Map}get trackers(){return this.tracked.values()}prepareForMainThreadTestRun(M,S,z){return this.getTracker(M,S,z)}cancelRunById(M){for(const S of this.tracked.values())if(S.id===M){S.dispose();return}}cancelAllRuns(){for(const M of this.tracked.values())M.dispose()}createTestRun(M,S,z,$,N){const K=this.tracked.get(z);if(K)return K.createRun($);const V=r.fromPublic(M,S,z,N),F=o(z);this.proxy.$startedExtensionTestRun({controllerId:M,profile:F&&{group:U[F.kind],id:F.profileId},exclude:z.exclude?.map(ce=>a.TestId.fromExtHostTestItem(ce,S.root.id).toString())??[],id:V.id,include:z.include?.map(ce=>a.TestId.fromExtHostTestItem(ce,S.root.id).toString())??[S.root.id],persist:N});const ne=this.getTracker(z,V);return ne.onEnd(()=>this.proxy.$finishedExtensionTestRun(V.id)),ne.createRun($)}getTracker(M,S,z){const $=new u(S,this.proxy,z);return this.tracked.set(M,$),$.onEnd(()=>this.tracked.delete(M)),$}}e.TestRunCoordinator=i;const o=W=>{if(!!W.profile){if(!(W.profile instanceof D))throw new Error("TestRunRequest.profile is not an instance created from TestController.createRunProfile");return W.profile}};class r{constructor(M,S,z,$,N,K){this.controllerId=M,this.id=S,this.isPersisted=N,this.colllection=K,this.includePrefix=z.map(V=>V+"\0"),this.excludePrefix=$.map(V=>V+"\0")}static fromPublic(M,S,z,$){return new r(M,(0,y.generateUuid)(),z.include?.map(N=>a.TestId.fromExtHostTestItem(N,M).toString())??[M],z.exclude?.map(N=>a.TestId.fromExtHostTestItem(N,M).toString())??[],$,S)}static fromInternal(M,S){return new r(M.controllerId,M.runId,M.testIds,M.excludeExtIds,!0,S)}isIncluded(M){const S=a.TestId.fromExtHostTestItem(M,this.controllerId).toString()+"\0";for(const z of this.excludePrefix)if(S===z||S.startsWith(z))return!1;for(const z of this.includePrefix)if(S===z||S.startsWith(z))return!0;return!1}}e.TestRunDto=r;class t{constructor(M,S,z){this.proxy=M,this.runId=S,this.taskId=z}set coverageProvider(M){if(this._coverageProvider)throw new Error("The TestCoverageProvider cannot be replaced after being provided");!M||(this._coverageProvider=M,this.proxy.$signalCoverageAvailable(this.runId,this.taskId))}get coverageProvider(){return this._coverageProvider}async provideFileCoverage(M){if(!this._coverageProvider)return[];this.fileCoverage||(this.fileCoverage=(async()=>this._coverageProvider.provideFileCoverage(M))());try{return(await this.fileCoverage)?.map(h.TestCoverage.fromFile)??[]}catch(S){throw this.fileCoverage=void 0,S}}async resolveFileCoverage(M,S){const z=await this.fileCoverage;let $=z?.[M];return!this._coverageProvider||!z||!$?[]:($.detailedCoverage||($=z[M]=await this._coverageProvider.resolveFileCoverage?.($,S)??$),$.detailedCoverage?.map(h.TestCoverage.fromDetailed)??[])}}class c extends P.IncrementalChangeCollector{constructor(M){super();this.emitter=M,this.added=new Set,this.updated=new Set,this.removed=new Set,this.alreadyRemoved=new Set}get isEmpty(){return this.added.size===0&&this.removed.size===0&&this.updated.size===0}add(M){this.added.add(M)}update(M){Object.assign(M.revived,h.TestItem.toPlain(M.item)),this.added.has(M)||this.updated.add(M)}remove(M){if(this.added.has(M)){this.added.delete(M);return}if(this.updated.delete(M),M.parent&&this.alreadyRemoved.has(M.parent)){this.alreadyRemoved.add(M.item.extId);return}this.removed.add(M)}getChangeEvent(){const{added:M,updated:S,removed:z}=this;return{get added(){return[...M].map($=>$.revived)},get updated(){return[...S].map($=>$.revived)},get removed(){return[...z].map($=>$.revived)}}}complete(){this.isEmpty||this.emitter.fire(this.getChangeEvent())}}class v extends P.AbstractIncrementalTestCollection{constructor(){super(...arguments);this.changeEmitter=new L.Emitter,this.onDidChangeTests=this.changeEmitter.event}get rootTests(){return super.roots}getMirroredTestDataById(M){return this.items.get(M)}getMirroredTestDataByReference(M){return this.items.get(M.id)}createItem(M,S){return{...M,revived:h.TestItem.toPlain(M.item),depth:S?S.depth+1:0,children:new Set}}createChangeCollector(){return new c(this.changeEmitter)}}e.MirroredTestCollection=v;class g{constructor(M){this.proxy=M}checkout(){this.current||(this.current=this.createObserverData());const M=this.current;return M.observers++,{onDidChangeTest:M.tests.onDidChangeTests,get tests(){return[...M.tests.rootTests].map(S=>S.revived)},dispose:(0,C.once)(()=>{--M.observers==0&&(this.proxy.$unsubscribeFromDiffs(),this.current=void 0)})}}getMirroredTestDataByReference(M){return this.current?.tests.getMirroredTestDataByReference(M)}applyDiff(M){this.current?.tests.apply(M)}createObserverData(){const M=new v;return this.proxy.$subscribeToDiffs(),{observers:0,tests:M}}}class D{constructor(M,S,z,$,N,K,V,F=!1,ne=void 0){this.controllerId=z,this.profileId=$,this._label=N,this.kind=K,this.runHandler=V,this._isDefault=F,this._tag=ne,l.set(this,void 0),_.set(this,void 0),Je(this,l,M,"f"),Je(this,_,S,"f"),S.set($,this);const ce=U[K];if(typeof ce!="number")throw new Error(`Unknown TestRunProfile.group ${K}`);Ae(this,l,"f").$publishTestRunProfile({profileId:$,controllerId:z,tag:ne?h.TestTag.namespace(this.controllerId,ne.id):null,label:N,group:ce,isDefault:F,hasConfigurationHandler:!1})}get label(){return this._label}set label(M){M!==this._label&&(this._label=M,Ae(this,l,"f").$updateTestRunConfig(this.controllerId,this.profileId,{label:M}))}get isDefault(){return this._isDefault}set isDefault(M){M!==this._isDefault&&(this._isDefault=M,Ae(this,l,"f").$updateTestRunConfig(this.controllerId,this.profileId,{isDefault:M}))}get tag(){return this._tag}set tag(M){M?.id!==this._tag?.id&&(this._tag=M,Ae(this,l,"f").$updateTestRunConfig(this.controllerId,this.profileId,{tag:M?h.TestTag.namespace(this.controllerId,M.id):null}))}get configureHandler(){return this._configureHandler}set configureHandler(M){M!==this._configureHandler&&(this._configureHandler=M,Ae(this,l,"f").$updateTestRunConfig(this.controllerId,this.profileId,{hasConfigurationHandler:!!M}))}dispose(){Ae(this,_,"f")?.delete(this.profileId)&&(Je(this,_,void 0,"f"),Ae(this,l,"f").$removeTestProfile(this.controllerId,this.profileId))}}e.TestRunProfileImpl=D,l=new WeakMap,_=new WeakMap;const U={[d.TestRunProfileKind.Coverage]:8,[d.TestRunProfileKind.Debug]:4,[d.TestRunProfileKind.Run]:2}}),define(ye[213],Ce([1,0,16,4,5,93,8,6]),function(ee,e,s,p,b,L,C,T){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.ExtHostEditors=void 0;class E{constructor(R,y){this._extHostDocumentsAndEditors=y,this._onDidChangeTextEditorSelection=new p.Emitter,this._onDidChangeTextEditorOptions=new p.Emitter,this._onDidChangeTextEditorVisibleRanges=new p.Emitter,this._onDidChangeTextEditorViewColumn=new p.Emitter,this._onDidChangeActiveTextEditor=new p.Emitter,this._onDidChangeVisibleTextEditors=new p.Emitter,this.onDidChangeTextEditorSelection=this._onDidChangeTextEditorSelection.event,this.onDidChangeTextEditorOptions=this._onDidChangeTextEditorOptions.event,this.onDidChangeTextEditorVisibleRanges=this._onDidChangeTextEditorVisibleRanges.event,this.onDidChangeTextEditorViewColumn=this._onDidChangeTextEditorViewColumn.event,this.onDidChangeActiveTextEditor=this._onDidChangeActiveTextEditor.event,this.onDidChangeVisibleTextEditors=this._onDidChangeVisibleTextEditors.event,this._proxy=R.getProxy(b.MainContext.MainThreadTextEditors),this._extHostDocumentsAndEditors.onDidChangeVisibleTextEditors(m=>this._onDidChangeVisibleTextEditors.fire(m)),this._extHostDocumentsAndEditors.onDidChangeActiveTextEditor(m=>this._onDidChangeActiveTextEditor.fire(m))}getActiveTextEditor(){return this._extHostDocumentsAndEditors.activeEditor()}getVisibleTextEditors(R){const y=this._extHostDocumentsAndEditors.allEditors();return R?y:y.map(m=>m.value)}async showTextDocument(R,y,m){let I;typeof y=="number"?I={position:C.ViewColumn.from(y),preserveFocus:m}:typeof y=="object"?I={position:C.ViewColumn.from(y.viewColumn),preserveFocus:y.preserveFocus,selection:typeof y.selection=="object"?C.Range.from(y.selection):void 0,pinned:typeof y.preview=="boolean"?!y.preview:void 0}:I={preserveFocus:!1};const f=await this._proxy.$tryShowTextDocument(R.uri,I),h=f&&this._extHostDocumentsAndEditors.getEditor(f);if(h)return h.value;throw f?new Error(`Could NOT open editor for "${R.uri.toString()}" because another editor opened in the meantime.`):new Error(`Could NOT open editor for "${R.uri.toString()}".`)}createTextEditorDecorationType(R,y){return new L.TextEditorDecorationType(this._proxy,R,y).value}$acceptEditorPropertiesChanged(R,y){const m=this._extHostDocumentsAndEditors.getEditor(R);if(!m)throw new Error("unknown text editor");if(y.options&&m._acceptOptions(y.options),y.selections){const I=y.selections.selections.map(C.Selection.to);m._acceptSelections(I)}if(y.visibleRanges){const I=s.coalesce(y.visibleRanges.map(C.Range.to));m._acceptVisibleRanges(I)}if(y.options&&this._onDidChangeTextEditorOptions.fire({textEditor:m.value,options:{...y.options,lineNumbers:C.TextEditorLineNumbersStyle.to(y.options.lineNumbers)}}),y.selections){const I=T.TextEditorSelectionChangeKind.fromValue(y.selections.source),f=y.selections.selections.map(C.Selection.to);this._onDidChangeTextEditorSelection.fire({textEditor:m.value,selections:f,kind:I})}if(y.visibleRanges){const I=s.coalesce(y.visibleRanges.map(C.Range.to));this._onDidChangeTextEditorVisibleRanges.fire({textEditor:m.value,visibleRanges:I})}}$acceptEditorPositionData(R){for(const y in R){const m=this._extHostDocumentsAndEditors.getEditor(y);if(!m)throw new Error("Unknown text editor");const I=C.ViewColumn.to(R[y]);m.value.viewColumn!==I&&(m._acceptViewColumn(I),this._onDidChangeTextEditorViewColumn.fire({textEditor:m.value,viewColumn:I}))}}getDiffInformation(R){return Promise.resolve(this._proxy.$getDiffInformation(R))}}e.ExtHostEditors=E}),define(ye[214],Ce([1,0,2,3,5,7,6,8,10]),function(ee,e,s,p,b,L,C,T,E){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.ExtHostTimeline=e.IExtHostTimeline=void 0,e.IExtHostTimeline=(0,p.createDecorator)("IExtHostTimeline");class A{constructor(m,I){this._providers=new Map,this._itemsBySourceAndUriMap=new Map,this._proxy=m.getProxy(b.MainContext.MainThreadTimeline),I.registerArgumentProcessor({processArgument:f=>{if(f&&f.$mid===11){const h=f.uri===void 0?void 0:s.URI.revive(f.uri);return this._itemsBySourceAndUriMap.get(f.source)?.get(R(h))?.get(f.handle)}return f}})}async $getTimeline(m,I,f,h){return this._providers.get(m)?.provideTimeline(s.URI.revive(I),f,h)}registerTimelineProvider(m,I,f,h){const d=new L.DisposableStore,a=this.convertTimelineItem(I.id,h,d).bind(this);let w;I.onDidChange&&(w=I.onDidChange(l=>this._proxy.$emitTimelineChangeEvent({uri:void 0,reset:!0,...l,id:I.id}),this));const P=this._itemsBySourceAndUriMap;return this.registerTimelineProviderCore({...I,scheme:m,onDidChange:void 0,async provideTimeline(l,_,n){_?.resetCache&&(d.clear(),P.get(I.id)?.clear());const u=await I.provideTimeline(l,_,n);if(u==null)return;const i=a(l,_);return{...u,source:I.id,items:u.items.map(i)}},dispose(){for(const l of P.values())l.get(I.id)?.clear();w?.dispose(),d.dispose()}})}convertTimelineItem(m,I,f){return(h,d)=>{let a;if(d?.cacheResults){let w=this._itemsBySourceAndUriMap.get(m);w===void 0&&(w=new Map,this._itemsBySourceAndUriMap.set(m,w));const P=R(h);a=w.get(P),a===void 0&&(a=new Map,w.set(P,a))}return w=>{const{iconPath:P,...l}=w,_=`${m}|${w.id??w.timestamp}`;a?.set(_,w);let n,u,i;w.iconPath&&(P instanceof C.ThemeIcon?i={id:P.id,color:P.color}:s.URI.isUri(P)?(n=P,u=P):{light:n,dark:u}=P);let o;return C.MarkdownString.isMarkdownString(l.tooltip)?o=T.MarkdownString.from(l.tooltip):(0,E.isString)(l.tooltip)?o=l.tooltip:C.MarkdownString.isMarkdownString(l.detail)?(console.warn("Using deprecated TimelineItem.detail, migrate to TimelineItem.tooltip"),o=T.MarkdownString.from(l.detail)):(0,E.isString)(l.detail)&&(console.warn("Using deprecated TimelineItem.detail, migrate to TimelineItem.tooltip"),o=l.detail),{...l,id:l.id??void 0,handle:_,source:m,command:w.command?I.toInternal(w.command,f):void 0,icon:n,iconDark:u,themeIcon:i,tooltip:o,accessibilityInformation:w.accessibilityInformation}}}}registerTimelineProviderCore(m){if(this._providers.get(m.id))throw new Error(`Timeline Provider ${m.id} already exists.`);return this._proxy.$registerTimelineProvider({id:m.id,label:m.label,scheme:m.scheme}),this._providers.set(m.id,m),(0,L.toDisposable)(()=>{for(const f of this._itemsBySourceAndUriMap.values())f.get(m.id)?.clear();this._providers.delete(m.id),this._proxy.$unregisterTimelineProvider(m.id),m.dispose()})}}e.ExtHostTimeline=A;function R(y){return y?.toString()}}),define(ye[215],Ce([1,0,7,12,2,5]),function(ee,e,s,p,b,L){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.ExtHostUriOpeners=void 0;class C{constructor(E){this._openers=new Map,this._proxy=E.getProxy(L.MainContext.MainThreadUriOpeners)}registerExternalUriOpener(E,A,R,y){if(this._openers.has(A))throw new Error(`Opener with id '${A}' already registered`);const m=y.schemes.find(I=>!C.supportedSchemes.has(I));if(m)throw new Error(`Scheme '${m}' is not supported. Only http and https are currently supported.`);return this._openers.set(A,R),this._proxy.$registerUriOpener(A,y.schemes,E,y.label),(0,s.toDisposable)(()=>{this._openers.delete(A),this._proxy.$unregisterUriOpener(A)})}async $canOpenUri(E,A,R){const y=this._openers.get(E);if(!y)throw new Error(`Unknown opener with id: ${E}`);const m=b.URI.revive(A);return y.canOpenExternalUri(m,R)}async $openUri(E,A,R){const y=this._openers.get(E);if(!y)throw new Error(`Unknown opener id: '${E}'`);return y.openExternalUri(b.URI.revive(A.resolvedUri),{sourceUri:b.URI.revive(A.sourceUri)},R)}}e.ExtHostUriOpeners=C,C.supportedSchemes=new Set([p.Schemas.http,p.Schemas.https])}),define(ye[216],Ce([1,0,5,2,7,11,27]),function(ee,e,s,p,b,L,C){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.ExtHostUrls=void 0;class T{constructor(A){this.handles=new Set,this.handlers=new Map,this._proxy=A.getProxy(s.MainContext.MainThreadUrls)}registerUriHandler(A,R){if(this.handles.has(C.ExtensionIdentifier.toKey(A)))throw new Error(`Protocol handler already registered for extension ${A}`);const y=T.HandlePool++;return this.handles.add(C.ExtensionIdentifier.toKey(A)),this.handlers.set(y,R),this._proxy.$registerUriHandler(y,A),(0,b.toDisposable)(()=>{this.handles.delete(C.ExtensionIdentifier.toKey(A)),this.handlers.delete(y),this._proxy.$unregisterUriHandler(y)})}$handleExternalUri(A,R){const y=this.handlers.get(A);if(!y)return Promise.resolve(void 0);try{y.handleUri(p.URI.revive(R))}catch(m){(0,L.onUnexpectedError)(m)}return Promise.resolve(void 0)}async createAppUri(A){return p.URI.revive(await this._proxy.$createAppUri(A))}}e.ExtHostUrls=T,T.HandlePool=0});var Je=this&&this.__classPrivateFieldSet||function(ee,e,s,p,b){if(p==="m")throw new TypeError("Private method is not writable");if(p==="a"&&!b)throw new TypeError("Private accessor was defined without a setter");if(typeof e=="function"?ee!==e||!b:!e.has(ee))throw new TypeError("Cannot write private member to an object whose class did not declare it");return p==="a"?b.call(ee,s):b?b.value=s:e.set(ee,s),s},Ae=this&&this.__classPrivateFieldGet||function(ee,e,s,p){if(s==="a"&&!p)throw new TypeError("Private accessor was defined without a getter");if(typeof e=="function"?ee!==e||!p:!e.has(ee))throw new TypeError("Cannot read private member from an object whose class did not declare it");return s==="m"?p:s==="a"?p.call(ee):p?p.value:e.get(ee)};define(ye[53],Ce([1,0,4,12,2,144,161,64,5]),function(ee,e,s,p,b,L,C,T,E){"use strict";var A,R,y,m,I,f,h,d,a,w,P,l;Object.defineProperty(e,"__esModule",{value:!0}),e.reviveOptions=e.serializeWebviewOptions=e.toExtensionData=e.ExtHostWebviews=e.shouldSerializeBuffersForPostMessage=e.ExtHostWebview=void 0;class _{constructor(v,g,D,U,W,M,S){A.set(this,void 0),R.set(this,void 0),y.set(this,void 0),m.set(this,void 0),I.set(this,void 0),f.set(this,void 0),h.set(this,""),d.set(this,void 0),a.set(this,!1),w.set(this,!1),P.set(this,!1),this._onMessageEmitter=new s.Emitter,this.onDidReceiveMessage=this._onMessageEmitter.event,l.set(this,new s.Emitter),this._onDidDispose=Ae(this,l,"f").event,Je(this,A,v,"f"),Je(this,R,g,"f"),Je(this,d,D,"f"),Je(this,m,U,"f"),Je(this,I,W,"f"),Je(this,f,M,"f"),Je(this,P,n(M),"f"),Je(this,y,S,"f")}dispose(){Je(this,a,!0,"f"),Ae(this,l,"f").fire(),Ae(this,l,"f").dispose(),this._onMessageEmitter.dispose()}asWebviewUri(v){return Je(this,w,!0,"f"),(0,T.asWebviewUri)(v,Ae(this,m,"f"))}get cspSource(){const v=Ae(this,f,"f").extensionLocation;if(v.scheme===p.Schemas.https||v.scheme===p.Schemas.http){let g=v.toString();return g.endsWith("/")||(g+="/"),g+" "+T.webviewGenericCspSource}return T.webviewGenericCspSource}get html(){return this.assertNotDisposed(),Ae(this,h,"f")}set html(v){this.assertNotDisposed(),Ae(this,h,"f")!==v&&(Je(this,h,v,"f"),!Ae(this,w,"f")&&/(["'])vscode-resource:([^\s'"]+?)(["'])/i.test(v)&&(Je(this,w,!0,"f"),Ae(this,y,"f").report("Webview vscode-resource: uris",Ae(this,f,"f"),"Please migrate to use the 'webview.asWebviewUri' api instead: https://aka.ms/vscode-webview-use-aswebviewuri")),Ae(this,R,"f").$setHtml(Ae(this,A,"f"),v))}get options(){return this.assertNotDisposed(),Ae(this,d,"f")}set options(v){this.assertNotDisposed(),Ae(this,R,"f").$setOptions(Ae(this,A,"f"),o(Ae(this,f,"f"),Ae(this,I,"f"),v)),Je(this,d,v,"f")}async postMessage(v){if(Ae(this,a,"f"))return!1;const g=(0,C.serializeWebviewMessage)(v,{serializeBuffersForPostMessage:Ae(this,P,"f")});return Ae(this,R,"f").$postMessage(Ae(this,A,"f"),g.message,...g.buffers)}assertNotDisposed(){if(Ae(this,a,"f"))throw new Error("Webview is disposed")}}e.ExtHostWebview=_,A=new WeakMap,R=new WeakMap,y=new WeakMap,m=new WeakMap,I=new WeakMap,f=new WeakMap,h=new WeakMap,d=new WeakMap,a=new WeakMap,w=new WeakMap,P=new WeakMap,l=new WeakMap;function n(c){try{const v=(0,L.normalizeVersion)((0,L.parseVersion)(c.engines.vscode));return!!v&&v.majorBase>=1&&v.minorBase>=57}catch{return!1}}e.shouldSerializeBuffersForPostMessage=n;class u{constructor(v,g,D,U,W){this.remoteInfo=g,this.workspace=D,this._logService=U,this._deprecationService=W,this._webviews=new Map,this._webviewProxy=v.getProxy(E.MainContext.MainThreadWebviews)}$onMessage(v,g,D){const U=this.getWebview(v);if(U){const{message:W}=(0,C.deserializeWebviewMessage)(g,D.value);U._onMessageEmitter.fire(W)}}$onMissingCsp(v,g){this._logService.warn(`${g} created a webview without a content security policy: https://aka.ms/vscode-webview-missing-csp`)}createNewWebview(v,g,D){const U=new _(v,this._webviewProxy,r(g),this.remoteInfo,this.workspace,D,this._deprecationService);return this._webviews.set(v,U),U._onDidDispose(()=>{this._webviews.delete(v)}),U}deleteWebview(v){this._webviews.delete(v)}getWebview(v){return this._webviews.get(v)}}e.ExtHostWebviews=u;function i(c){return{id:c.identifier,location:c.extensionLocation}}e.toExtensionData=i;function o(c,v,g){return{enableCommandUris:g.enableCommandUris,enableScripts:g.enableScripts,enableForms:g.enableForms,portMapping:g.portMapping,localResourceRoots:g.localResourceRoots||t(c,v)}}e.serializeWebviewOptions=o;function r(c){return{enableCommandUris:c.enableCommandUris,enableScripts:c.enableScripts,enableForms:c.enableForms,portMapping:c.portMapping,localResourceRoots:c.localResourceRoots?.map(v=>b.URI.from(v))}}e.reviveOptions=r;function t(c,v){return[...(v?.getWorkspaceFolders()||[]).map(g=>g.uri),c.extensionLocation]}}),define(ye[217],Ce([1,0,20,96,7,12,21,2,8,53,61,5,6]),function(ee,e,s,p,b,L,C,T,E,A,R,y,m){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.ExtHostCustomEditors=void 0;class I{constructor(n,u){this.document=n,this._storagePath=u,this._backupCounter=1,this._edits=new R.Cache("custom documents")}addEdit(n){return this._edits.add([n])}async undo(n,u){await this.getEdit(n).undo(),u||this.disposeBackup()}async redo(n,u){await this.getEdit(n).redo(),u||this.disposeBackup()}disposeEdits(n){for(const u of n)this._edits.delete(u)}getNewBackupUri(){if(!this._storagePath)throw new Error("Backup requires a valid storage path");const n=l(this.document.uri)+this._backupCounter++;return(0,C.joinPath)(this._storagePath,n)}updateBackup(n){this._backup?.delete(),this._backup=n}disposeBackup(){this._backup?.delete(),this._backup=void 0}getEdit(n){const u=this._edits.get(n,0);if(!u)throw new Error("No edit found");return u}}class f{constructor(){this._documents=new Map}get(n,u){return this._documents.get(this.key(n,u))}add(n,u,i){const o=this.key(n,u.uri);if(this._documents.has(o))throw new Error(`Document already exists for viewType:${n} resource:${u.uri}`);const r=new I(u,i);return this._documents.set(o,r),r}delete(n,u){const i=this.key(n,u.uri);this._documents.delete(i)}key(n,u){return`${n}@@@${u}`}}var h;(function(_){_[_.Text=0]="Text",_[_.Custom=1]="Custom"})(h||(h={}));class d{constructor(){this._providers=new Map}addTextProvider(n,u,i){return this.add(0,n,u,i)}addCustomProvider(n,u,i){return this.add(1,n,u,i)}get(n){return this._providers.get(n)}add(n,u,i,o){if(this._providers.has(u))throw new Error(`Provider for viewType:${u} already registered`);return this._providers.set(u,{type:n,extension:i,provider:o}),new m.Disposable(()=>this._providers.delete(u))}}class a{constructor(n,u,i,o,r){this._extHostDocuments=u,this._extensionStoragePaths=i,this._extHostWebview=o,this._extHostWebviewPanels=r,this._editorProviders=new d,this._documents=new f,this._proxy=n.getProxy(y.MainContext.MainThreadCustomEditors)}registerCustomEditorProvider(n,u,i,o){const r=new b.DisposableStore;return w(i)?(r.add(this._editorProviders.addTextProvider(u,n,i)),this._proxy.$registerTextEditorProvider((0,A.toExtensionData)(n),u,o.webviewOptions||{},{supportsMove:!!i.moveCustomTextEditor},(0,A.shouldSerializeBuffersForPostMessage)(n))):(r.add(this._editorProviders.addCustomProvider(u,n,i)),this.supportEditing(i)&&r.add(i.onDidChangeCustomDocument(t=>{const c=this.getCustomDocumentEntry(u,t.document.uri);if(P(t)){const v=c.addEdit(t);this._proxy.$onDidEdit(t.document.uri,u,v,t.label)}else this._proxy.$onContentChange(t.document.uri,u)})),this._proxy.$registerCustomEditorProvider((0,A.toExtensionData)(n),u,o.webviewOptions||{},!!o.supportsMultipleEditorsPerDocument,(0,A.shouldSerializeBuffersForPostMessage)(n))),m.Disposable.from(r,new m.Disposable(()=>{this._proxy.$unregisterEditorProvider(u)}))}async $createCustomDocument(n,u,i,o,r){const t=this._editorProviders.get(u);if(!t)throw new Error(`No provider found for '${u}'`);if(t.type!==1)throw new Error(`Invalid provide type for '${u}'`);const c=T.URI.revive(n),v=await t.provider.openCustomDocument(c,{backupId:i,untitledDocumentData:o?.buffer},r);let g;return this.supportEditing(t.provider)&&this._extensionStoragePaths&&(g=this._extensionStoragePaths.workspaceValue(t.extension)??this._extensionStoragePaths.globalValue(t.extension)),this._documents.add(u,v,g),{editable:this.supportEditing(t.provider)}}async $disposeCustomDocument(n,u){const i=this._editorProviders.get(u);if(!i)throw new Error(`No provider found for '${u}'`);if(i.type!==1)throw new Error(`Invalid provider type for '${u}'`);const o=T.URI.revive(n),{document:r}=this.getCustomDocumentEntry(u,o);this._documents.delete(u,r),r.dispose()}async $resolveWebviewEditor(n,u,i,o,r,t){const c=this._editorProviders.get(i);if(!c)throw new Error(`No provider found for '${i}'`);const v=E.ViewColumn.to(r),g=this._extHostWebview.createNewWebview(u,o.webviewOptions,c.extension),D=this._extHostWebviewPanels.createNewWebviewPanel(u,i,o.title,v,o.panelOptions,g,!0),U=T.URI.revive(n);switch(c.type){case 1:{const{document:W}=this.getCustomDocumentEntry(i,U);return c.provider.resolveCustomEditor(W,D,t)}case 0:{const W=this._extHostDocuments.getDocument(U);return c.provider.resolveCustomTextEditor(W,D,t)}default:throw new Error("Unknown webview provider type")}}$disposeEdits(n,u,i){this.getCustomDocumentEntry(u,n).disposeEdits(i)}async $onMoveCustomEditor(n,u,i){const o=this._editorProviders.get(i);if(!o)throw new Error(`No provider found for '${i}'`);if(!o.provider.moveCustomTextEditor)throw new Error(`Provider does not implement move '${i}'`);const r=this._extHostWebviewPanels.getWebviewPanel(n);if(!r)throw new Error("No webview found");const t=T.URI.revive(u),c=this._extHostDocuments.getDocument(t);await o.provider.moveCustomTextEditor(c,r,s.CancellationToken.None)}async $undo(n,u,i,o){return this.getCustomDocumentEntry(u,n).undo(i,o)}async $redo(n,u,i,o){return this.getCustomDocumentEntry(u,n).redo(i,o)}async $revert(n,u,i){const o=this.getCustomDocumentEntry(u,n);await this.getCustomEditorProvider(u).revertCustomDocument(o.document,i),o.disposeBackup()}async $onSave(n,u,i){const o=this.getCustomDocumentEntry(u,n);await this.getCustomEditorProvider(u).saveCustomDocument(o.document,i),o.disposeBackup()}async $onSaveAs(n,u,i,o){const r=this.getCustomDocumentEntry(u,n);return this.getCustomEditorProvider(u).saveCustomDocumentAs(r.document,T.URI.revive(i),o)}async $backup(n,u,i){const o=this.getCustomDocumentEntry(u,n),t=await this.getCustomEditorProvider(u).backupCustomDocument(o.document,{destination:o.getNewBackupUri()},i);return o.updateBackup(t),t.id}getCustomDocumentEntry(n,u){const i=this._documents.get(n,T.URI.revive(u));if(!i)throw new Error("No custom document found");return i}getCustomEditorProvider(n){const i=this._editorProviders.get(n)?.provider;if(!i||!this.supportEditing(i))throw new Error("Custom document is not editable");return i}supportEditing(n){return!!n.onDidChangeCustomDocument}}e.ExtHostCustomEditors=a;function w(_){return typeof _.resolveCustomTextEditor=="function"}function P(_){return typeof _.undo=="function"&&typeof _.redo=="function"}function l(_){const n=_.scheme===L.Schemas.file||_.scheme===L.Schemas.untitled?_.fsPath:_.toString();return(0,p.hash)(n)+""}});var Je=this&&this.__classPrivateFieldSet||function(ee,e,s,p,b){if(p==="m")throw new TypeError("Private method is not writable");if(p==="a"&&!b)throw new TypeError("Private accessor was defined without a setter");if(typeof e=="function"?ee!==e||!b:!e.has(ee))throw new TypeError("Cannot write private member to an object whose class did not declare it");return p==="a"?b.call(ee,s):b?b.value=s:e.set(ee,s),s},Ae=this&&this.__classPrivateFieldGet||function(ee,e,s,p){if(s==="a"&&!p)throw new TypeError("Private accessor was defined without a getter");if(typeof e=="function"?ee!==e||!p:!e.has(ee))throw new TypeError("Cannot read private member from an object whose class did not declare it");return s==="m"?p:s==="a"?p.call(ee):p?p.value:e.get(ee)};define(ye[218],Ce([1,0,4,7,2,43,8,53,5,6]),function(ee,e,s,p,b,L,C,T,E,A){"use strict";var R,y,m,I,f,h,d,a,w,P,l,_,n;Object.defineProperty(e,"__esModule",{value:!0}),e.ExtHostWebviewPanels=void 0;class u extends p.Disposable{constructor(t,c,v,g){super();R.set(this,void 0),y.set(this,void 0),m.set(this,void 0),I.set(this,void 0),f.set(this,void 0),h.set(this,void 0),d.set(this,void 0),a.set(this,void 0),w.set(this,!0),P.set(this,void 0),l.set(this,!1),_.set(this,this._register(new s.Emitter)),this.onDidDispose=Ae(this,_,"f").event,n.set(this,this._register(new s.Emitter)),this.onDidChangeViewState=Ae(this,n,"f").event,Je(this,R,t,"f"),Je(this,y,c,"f"),Je(this,I,v,"f"),Je(this,m,g.viewType,"f"),Je(this,f,g.panelOptions,"f"),Je(this,a,g.viewColumn,"f"),Je(this,h,g.title,"f"),Je(this,P,g.active,"f")}dispose(){Ae(this,l,"f")||(Je(this,l,!0,"f"),Ae(this,_,"f").fire(),Ae(this,y,"f").$disposeWebview(Ae(this,R,"f")),Ae(this,I,"f").dispose(),super.dispose())}get webview(){return this.assertNotDisposed(),Ae(this,I,"f")}get viewType(){return this.assertNotDisposed(),Ae(this,m,"f")}get title(){return this.assertNotDisposed(),Ae(this,h,"f")}set title(t){this.assertNotDisposed(),Ae(this,h,"f")!==t&&(Je(this,h,t,"f"),Ae(this,y,"f").$setTitle(Ae(this,R,"f"),t))}get iconPath(){return this.assertNotDisposed(),Ae(this,d,"f")}set iconPath(t){this.assertNotDisposed(),Ae(this,d,"f")!==t&&(Je(this,d,t,"f"),Ae(this,y,"f").$setIconPath(Ae(this,R,"f"),b.URI.isUri(t)?{light:t,dark:t}:t))}get options(){return Ae(this,f,"f")}get viewColumn(){if(this.assertNotDisposed(),!(typeof Ae(this,a,"f")=="number"&&Ae(this,a,"f")<0))return Ae(this,a,"f")}get active(){return this.assertNotDisposed(),Ae(this,P,"f")}get visible(){return this.assertNotDisposed(),Ae(this,w,"f")}_updateViewState(t){Ae(this,l,"f")||(this.active!==t.active||this.visible!==t.visible||this.viewColumn!==t.viewColumn)&&(Je(this,P,t.active,"f"),Je(this,w,t.visible,"f"),Je(this,a,t.viewColumn,"f"),Ae(this,n,"f").fire({webviewPanel:this}))}reveal(t,c){this.assertNotDisposed(),Ae(this,y,"f").$reveal(Ae(this,R,"f"),{viewColumn:typeof t=="undefined"?void 0:C.ViewColumn.from(t),preserveFocus:!!c})}assertNotDisposed(){if(Ae(this,l,"f"))throw new Error("Webview is disposed")}}R=new WeakMap,y=new WeakMap,m=new WeakMap,I=new WeakMap,f=new WeakMap,h=new WeakMap,d=new WeakMap,a=new WeakMap,w=new WeakMap,P=new WeakMap,l=new WeakMap,_=new WeakMap,n=new WeakMap;class i{constructor(t,c,v){this.webviews=c,this.workspace=v,this._webviewPanels=new Map,this._serializers=new Map,this._proxy=t.getProxy(E.MainContext.MainThreadWebviewPanels)}static newHandle(){return(0,L.generateUuid)()}createWebviewPanel(t,c,v,g,D={}){const U=typeof g=="object"?g.viewColumn:g,W={viewColumn:C.ViewColumn.from(U),preserveFocus:typeof g=="object"&&!!g.preserveFocus},M=(0,T.shouldSerializeBuffersForPostMessage)(t),S=i.newHandle();this._proxy.$createWebviewPanel((0,T.toExtensionData)(t),S,c,{title:v,panelOptions:o(D),webviewOptions:(0,T.serializeWebviewOptions)(t,this.workspace,D),serializeBuffersForPostMessage:M},W);const z=this.webviews.createNewWebview(S,D,t);return this.createNewWebviewPanel(S,c,v,U,D,z,!0)}$onDidChangeWebviewPanelViewStates(t){const c=Object.keys(t);c.sort((v,g)=>{const D=t[v],U=t[g];return D.active?1:U.active?-1:+D.visible-+U.visible});for(const v of c){const g=this.getWebviewPanel(v);if(!g)continue;const D=t[v];g._updateViewState({active:D.active,visible:D.visible,viewColumn:C.ViewColumn.to(D.position)})}}async $onDidDisposeWebviewPanel(t){this.getWebviewPanel(t)?.dispose(),this._webviewPanels.delete(t),this.webviews.deleteWebview(t)}registerWebviewPanelSerializer(t,c,v){if(this._serializers.has(c))throw new Error(`Serializer for '${c}' already registered`);return this._serializers.set(c,{serializer:v,extension:t}),this._proxy.$registerSerializer(c,{serializeBuffersForPostMessage:(0,T.shouldSerializeBuffersForPostMessage)(t)}),new A.Disposable(()=>{this._serializers.delete(c),this._proxy.$unregisterSerializer(c)})}async $deserializeWebviewPanel(t,c,v,g){const D=this._serializers.get(c);if(!D)throw new Error(`No serializer found for '${c}'`);const{serializer:U,extension:W}=D,M=this.webviews.createNewWebview(t,v.webviewOptions,W),S=this.createNewWebviewPanel(t,c,v.title,g,v.panelOptions,M,v.active);await U.deserializeWebviewPanel(S,v.state)}createNewWebviewPanel(t,c,v,g,D,U,W){const M=new u(t,this._proxy,U,{viewType:c,title:v,viewColumn:g,panelOptions:D,active:W});return this._webviewPanels.set(t,M),M}getWebviewPanel(t){return this._webviewPanels.get(t)}}e.ExtHostWebviewPanels=i;function o(r){return{enableFindWidget:r.enableFindWidget,retainContextWhenHidden:r.retainContextWhenHidden}}});var Je=this&&this.__classPrivateFieldSet||function(ee,e,s,p,b){if(p==="m")throw new TypeError("Private method is not writable");if(p==="a"&&!b)throw new TypeError("Private accessor was defined without a setter");if(typeof e=="function"?ee!==e||!b:!e.has(ee))throw new TypeError("Cannot write private member to an object whose class did not declare it");return p==="a"?b.call(ee,s):b?b.value=s:e.set(ee,s),s},Ae=this&&this.__classPrivateFieldGet||function(ee,e,s,p){if(s==="a"&&!p)throw new TypeError("Private accessor was defined without a getter");if(typeof e=="function"?ee!==e||!p:!e.has(ee))throw new TypeError("Cannot read private member from an object whose class did not declare it");return s==="m"?p:s==="a"?p.call(ee):p?p.value:e.get(ee)};define(ye[219],Ce([1,0,4,7,53,24,8,5,6]),function(ee,e,s,p,b,L,C,T,E){"use strict";var A,R,y,m,I,f,h,d,a,w,P,l;Object.defineProperty(e,"__esModule",{value:!0}),e.ExtHostWebviewViews=void 0;class _ extends p.Disposable{constructor(i,o,r,t,c,v,g){super();A.set(this,void 0),R.set(this,void 0),y.set(this,void 0),m.set(this,void 0),I.set(this,void 0),f.set(this,!1),h.set(this,void 0),d.set(this,void 0),a.set(this,void 0),w.set(this,void 0),P.set(this,this._register(new s.Emitter)),this.onDidChangeVisibility=Ae(this,P,"f").event,l.set(this,this._register(new s.Emitter)),this.onDidDispose=Ae(this,l,"f").event,Je(this,y,r,"f"),Je(this,d,t,"f"),Je(this,A,i,"f"),Je(this,R,o,"f"),Je(this,m,c,"f"),Je(this,I,v,"f"),Je(this,h,g,"f")}dispose(){Ae(this,f,"f")||(Je(this,f,!0,"f"),Ae(this,l,"f").fire(),Ae(this,m,"f").dispose(),super.dispose())}get title(){return this.assertNotDisposed(),Ae(this,d,"f")}set title(i){this.assertNotDisposed(),Ae(this,d,"f")!==i&&(Je(this,d,i,"f"),Ae(this,R,"f").$setWebviewViewTitle(Ae(this,A,"f"),i))}get description(){return this.assertNotDisposed(),Ae(this,a,"f")}set description(i){this.assertNotDisposed(),Ae(this,a,"f")!==i&&(Je(this,a,i,"f"),Ae(this,R,"f").$setWebviewViewDescription(Ae(this,A,"f"),i))}get visible(){return Ae(this,h,"f")}get webview(){return Ae(this,m,"f")}get viewType(){return Ae(this,y,"f")}_setVisible(i){i===Ae(this,h,"f")||Ae(this,f,"f")||(Je(this,h,i,"f"),Ae(this,P,"f").fire())}get badge(){return this.assertNotDisposed(),(0,L.checkProposedApiEnabled)(Ae(this,I,"f"),"badges"),Ae(this,w,"f")}set badge(i){this.assertNotDisposed(),(0,L.checkProposedApiEnabled)(Ae(this,I,"f"),"badges"),!(i?.value===Ae(this,w,"f")?.value&&i?.tooltip===Ae(this,w,"f")?.tooltip)&&(Je(this,w,C.ViewBadge.from(i),"f"),Ae(this,R,"f").$setWebviewViewBadge(Ae(this,A,"f"),i))}show(i){this.assertNotDisposed(),Ae(this,R,"f").$show(Ae(this,A,"f"),!!i)}assertNotDisposed(){if(Ae(this,f,"f"))throw new Error("Webview is disposed")}}A=new WeakMap,R=new WeakMap,y=new WeakMap,m=new WeakMap,I=new WeakMap,f=new WeakMap,h=new WeakMap,d=new WeakMap,a=new WeakMap,w=new WeakMap,P=new WeakMap,l=new WeakMap;class n{constructor(i,o){this._extHostWebview=o,this._viewProviders=new Map,this._webviewViews=new Map,this._proxy=i.getProxy(T.MainContext.MainThreadWebviewViews)}registerWebviewViewProvider(i,o,r,t){if(this._viewProviders.has(o))throw new Error(`View provider for '${o}' already registered`);return this._viewProviders.set(o,{provider:r,extension:i}),this._proxy.$registerWebviewViewProvider((0,b.toExtensionData)(i),o,{retainContextWhenHidden:t?.retainContextWhenHidden,serializeBuffersForPostMessage:(0,b.shouldSerializeBuffersForPostMessage)(i)}),new E.Disposable(()=>{this._viewProviders.delete(o),this._proxy.$unregisterWebviewViewProvider(o)})}async $resolveWebviewView(i,o,r,t,c){const v=this._viewProviders.get(o);if(!v)throw new Error(`No view provider found for '${o}'`);const{provider:g,extension:D}=v,U=this._extHostWebview.createNewWebview(i,{},D),W=new _(i,this._proxy,o,r,U,D,!0);this._webviewViews.set(i,W),await g.resolveWebviewView(W,{state:t},c)}async $onDidChangeWebviewViewVisibility(i,o){this.getWebviewView(i)._setVisible(o)}async $disposeWebviewView(i){const o=this.getWebviewView(i);this._webviewViews.delete(i),o.dispose(),this._extHostWebview.deleteWebview(i)}getWebviewView(i){const o=this._webviewViews.get(i);if(!o)throw new Error("No webview found");return o}}e.ExtHostWebviewViews=n}),define(ye[97],Ce([1,0,4,5,2,12,9,3,15]),function(ee,e,s,p,b,L,C,T,E){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.IExtHostWindow=e.ExtHostWindow=void 0;let A=class Qi{constructor(y){this._onDidChangeWindowState=new s.Emitter,this.onDidChangeWindowState=this._onDidChangeWindowState.event,this._state=Qi.InitialState,this._proxy=y.getProxy(p.MainContext.MainThreadWindow),this._proxy.$getWindowVisibility().then(m=>this.$onDidChangeWindowFocus(m))}get state(){return this._state}$onDidChangeWindowFocus(y){y!==this._state.focused&&(this._state={...this._state,focused:y},this._onDidChangeWindowState.fire(this._state))}openUri(y,m){let I;if(typeof y=="string"){I=y;try{y=b.URI.parse(y)}catch{return Promise.reject(`Invalid uri - '${y}'`)}}return(0,C.isFalsyOrWhitespace)(y.scheme)?Promise.reject("Invalid scheme - cannot be empty"):y.scheme===L.Schemas.command?Promise.reject(`Invalid scheme '${y.scheme}'`):this._proxy.$openUri(y,I,m)}async asExternalUri(y,m){if((0,C.isFalsyOrWhitespace)(y.scheme))return Promise.reject("Invalid scheme - cannot be empty");const I=await this._proxy.$asExternalUri(y,m);return b.URI.from(I)}};A.InitialState={focused:!0},A=ze([xe(0,E.IExtHostRpcService)],A),e.ExtHostWindow=A,e.IExtHostWindow=(0,T.createDecorator)("IExtHostWindow")}),define(ye[220],Ce([1,0,191,28,15]),function(ee,e,s,p,b){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.ExtHostConsoleForwarder=void 0;let L=class extends s.AbstractExtHostConsoleForwarder{constructor(T,E){super(T,E)}_nativeConsoleLogMessage(T,E,A){E.apply(console,A)}};L=ze([xe(0,b.IExtHostRpcService),xe(1,p.IExtHostInitDataService)],L),e.ExtHostConsoleForwarder=L}),define(ye[221],Ce([1,0,13,22,20,11,4,7,112,185,40]),function(ee,e,s,p,b,L,C,T,E,A,R){"use strict";var y;Object.defineProperty(e,"__esModule",{value:!0}),e.RPCProtocol=e.ResponsiveState=e.RequestInitiator=e.parseJsonAndRestoreBufferRefs=e.stringifyJsonWithBufferRefs=void 0;function m(D,U){try{return JSON.stringify(D,U)}catch{return"null"}}const I="$$ref$$",f={[I]:-1};class h{constructor(U,W){this.jsonString=U,this.referencedBuffers=W}}function d(D,U=null,W=!1){const M=[];return{jsonString:(W?m:JSON.stringify)(D,(z,$)=>{if(typeof $=="undefined")return f;if(typeof $=="object"){if($ instanceof p.VSBuffer){const N=M.push($)-1;return{[I]:N}}if(U)return U(z,$)}return $}),referencedBuffers:M}}e.stringifyJsonWithBufferRefs=d;function a(D,U,W){return JSON.parse(D,(M,S)=>{if(S){const z=S[I];if(typeof z=="number")return U[z];if(W&&S.$mid===1)return W.transformIncoming(S)}return S})}e.parseJsonAndRestoreBufferRefs=a;function w(D,U){return JSON.stringify(D,U)}function P(D){return D?(U,W)=>W&&W.$mid===1?D.transformOutgoing(W):W:null}var l;(function(D){D[D.LocalSide=0]="LocalSide",D[D.OtherSide=1]="OtherSide"})(l=e.RequestInitiator||(e.RequestInitiator={}));var _;(function(D){D[D.Responsive=0]="Responsive",D[D.Unresponsive=1]="Unresponsive"})(_=e.ResponsiveState||(e.ResponsiveState={}));const n=()=>{},u=Symbol.for("rpcProtocol"),i=Symbol.for("rpcProxy");class o extends T.Disposable{constructor(U,W=null,M=null){super();this[y]=!0,this._onDidChangeResponsiveState=this._register(new C.Emitter),this.onDidChangeResponsiveState=this._onDidChangeResponsiveState.event,this._protocol=U,this._logger=W,this._uriTransformer=M,this._uriReplacer=P(this._uriTransformer),this._isDisposed=!1,this._locals=[],this._proxies=[];for(let S=0,z=R.ProxyIdentifier.count;S<z;S++)this._locals[S]=null,this._proxies[S]=null;this._lastMessageId=0,this._cancelInvokedHandlers=Object.create(null),this._pendingRPCReplies={},this._responsiveState=0,this._unacknowledgedCount=0,this._unresponsiveTime=0,this._asyncCheckUresponsive=this._register(new s.RunOnceScheduler(()=>this._checkUnresponsive(),1e3)),this._protocol.onMessage(S=>this._receiveOneMessage(S))}dispose(){this._isDisposed=!0,Object.keys(this._pendingRPCReplies).forEach(U=>{this._pendingRPCReplies[U].resolveErr(L.canceled())})}drain(){return typeof this._protocol.drain=="function"?this._protocol.drain():Promise.resolve()}_onWillSendRequest(U){this._unacknowledgedCount===0&&(this._unresponsiveTime=Date.now()+o.UNRESPONSIVE_TIME),this._unacknowledgedCount++,this._asyncCheckUresponsive.isScheduled()||this._asyncCheckUresponsive.schedule()}_onDidReceiveAcknowledge(U){this._unresponsiveTime=Date.now()+o.UNRESPONSIVE_TIME,this._unacknowledgedCount--,this._unacknowledgedCount===0&&this._asyncCheckUresponsive.cancel(),this._setResponsiveState(0)}_checkUnresponsive(){this._unacknowledgedCount!==0&&(Date.now()>this._unresponsiveTime?this._setResponsiveState(1):this._asyncCheckUresponsive.schedule())}_setResponsiveState(U){this._responsiveState!==U&&(this._responsiveState=U,this._onDidChangeResponsiveState.fire(this._responsiveState))}get responsiveState(){return this._responsiveState}transformIncomingURIs(U){return this._uriTransformer?(0,E.transformIncomingURIs)(U,this._uriTransformer):U}getProxy(U){const{nid:W,sid:M}=U;return this._proxies[W]||(this._proxies[W]=this._createProxy(W,M)),this._proxies[W]}_createProxy(U,W){const M={get:(S,z)=>(typeof z=="string"&&!S[z]&&z.charCodeAt(0)===36&&(S[z]=(...$)=>this._remoteCall(U,z,$)),z===i?W:S[z])};return new Proxy(Object.create(null),M)}set(U,W){return this._locals[U.nid]=W,W}assertRegistered(U){for(let W=0,M=U.length;W<M;W++){const S=U[W];if(!this._locals[S.nid])throw new Error(`Missing proxy instance ${S.sid}`)}}_receiveOneMessage(U){if(this._isDisposed)return;const W=U.byteLength,M=r.read(U,0),S=M.readUInt8(),z=M.readUInt32();switch(S){case 1:case 2:{let{rpcId:$,method:N,args:K}=c.deserializeRequestJSONArgs(M);this._uriTransformer&&(K=(0,E.transformIncomingURIs)(K,this._uriTransformer)),this._receiveRequest(W,z,$,N,K,S===2);break}case 3:case 4:{let{rpcId:$,method:N,args:K}=c.deserializeRequestMixedArgs(M);this._uriTransformer&&(K=(0,E.transformIncomingURIs)(K,this._uriTransformer)),this._receiveRequest(W,z,$,N,K,S===4);break}case 5:{this._logger?.logIncoming(W,z,0,"ack"),this._onDidReceiveAcknowledge(z);break}case 6:{this._receiveCancel(W,z);break}case 7:{this._receiveReply(W,z,void 0);break}case 9:{let $=c.deserializeReplyOKJSON(M);this._uriTransformer&&($=(0,E.transformIncomingURIs)($,this._uriTransformer)),this._receiveReply(W,z,$);break}case 10:{const $=c.deserializeReplyOKJSONWithBuffers(M,this._uriTransformer);this._receiveReply(W,z,$);break}case 8:{const $=c.deserializeReplyOKVSBuffer(M);this._receiveReply(W,z,$);break}case 11:{let $=c.deserializeReplyErrError(M);this._uriTransformer&&($=(0,E.transformIncomingURIs)($,this._uriTransformer)),this._receiveReplyErr(W,z,$);break}case 12:{this._receiveReplyErr(W,z,void 0);break}default:console.error("received unexpected message"),console.error(U)}}_receiveRequest(U,W,M,S,z,$){this._logger?.logIncoming(U,W,1,`receiveRequest ${(0,R.getStringIdentifierForProxy)(M)}.${S}(`,z);const N=String(W);let K,V;if($){const ne=new b.CancellationTokenSource;z.push(ne.token),K=this._invokeHandler(M,S,z),V=()=>ne.cancel()}else K=this._invokeHandler(M,S,z),V=n;this._cancelInvokedHandlers[N]=V;const F=c.serializeAcknowledged(W);this._logger?.logOutgoing(F.byteLength,W,1,"ack"),this._protocol.send(F),K.then(ne=>{delete this._cancelInvokedHandlers[N];const ce=c.serializeReplyOK(W,ne,this._uriReplacer);this._logger?.logOutgoing(ce.byteLength,W,1,"reply:",ne),this._protocol.send(ce)},ne=>{delete this._cancelInvokedHandlers[N];const ce=c.serializeReplyErr(W,ne);this._logger?.logOutgoing(ce.byteLength,W,1,"replyErr:",ne),this._protocol.send(ce)})}_receiveCancel(U,W){this._logger?.logIncoming(U,W,1,"receiveCancel");const M=String(W);this._cancelInvokedHandlers[M]?.()}_receiveReply(U,W,M){this._logger?.logIncoming(U,W,0,"receiveReply:",M);const S=String(W);if(!this._pendingRPCReplies.hasOwnProperty(S))return;const z=this._pendingRPCReplies[S];delete this._pendingRPCReplies[S],z.resolveOk(M)}_receiveReplyErr(U,W,M){this._logger?.logIncoming(U,W,0,"receiveReplyErr:",M);const S=String(W);if(!this._pendingRPCReplies.hasOwnProperty(S))return;const z=this._pendingRPCReplies[S];delete this._pendingRPCReplies[S];let $;M&&(M.$isError?($=new Error,$.name=M.name,$.message=M.message,$.stack=M.stack):$=M),z.resolveErr($)}_invokeHandler(U,W,M){try{return Promise.resolve(this._doInvokeHandler(U,W,M))}catch(S){return Promise.reject(S)}}_doInvokeHandler(U,W,M){const S=this._locals[U];if(!S)throw new Error("Unknown actor "+(0,R.getStringIdentifierForProxy)(U));const z=S[W];if(typeof z!="function")throw new Error("Unknown method "+W+" on actor "+(0,R.getStringIdentifierForProxy)(U));return z.apply(S,M)}_remoteCall(U,W,M){if(this._isDisposed)return new A.CanceledLazyPromise;let S=null;if(M.length>0&&b.CancellationToken.isCancellationToken(M[M.length-1])&&(S=M.pop()),S&&S.isCancellationRequested)return Promise.reject(L.canceled());const z=c.serializeRequestArguments(M,this._uriReplacer),$=++this._lastMessageId,N=String($),K=new A.LazyPromise;S&&S.onCancellationRequested(()=>{const F=c.serializeCancel($);this._logger?.logOutgoing(F.byteLength,$,0,"cancel"),this._protocol.send(c.serializeCancel($))}),this._pendingRPCReplies[N]=K,this._onWillSendRequest($);const V=c.serializeRequest($,U,W,z,!!S);return this._logger?.logOutgoing(V.byteLength,$,0,`request: ${(0,R.getStringIdentifierForProxy)(U)}.${W}(`,M),this._protocol.send(V),K}}e.RPCProtocol=o,y=u,o.UNRESPONSIVE_TIME=3*1e3;class r{constructor(U,W){this._buff=U,this._offset=W}static alloc(U,W,M){const S=new r(p.VSBuffer.alloc(M+1+4),0);return S.writeUInt8(U),S.writeUInt32(W),S}static read(U,W){return new r(U,W)}get buffer(){return this._buff}static sizeUInt8(){return 1}writeUInt8(U){this._buff.writeUInt8(U,this._offset),this._offset+=1}readUInt8(){const U=this._buff.readUInt8(this._offset);return this._offset+=1,U}writeUInt32(U){this._buff.writeUInt32BE(U,this._offset),this._offset+=4}readUInt32(){const U=this._buff.readUInt32BE(this._offset);return this._offset+=4,U}static sizeShortString(U){return 1+U.byteLength}writeShortString(U){this._buff.writeUInt8(U.byteLength,this._offset),this._offset+=1,this._buff.set(U,this._offset),this._offset+=U.byteLength}readShortString(){const U=this._buff.readUInt8(this._offset);this._offset+=1;const M=this._buff.slice(this._offset,this._offset+U).toString();return this._offset+=U,M}static sizeLongString(U){return 4+U.byteLength}writeLongString(U){this._buff.writeUInt32BE(U.byteLength,this._offset),this._offset+=4,this._buff.set(U,this._offset),this._offset+=U.byteLength}readLongString(){const U=this._buff.readUInt32BE(this._offset);this._offset+=4;const M=this._buff.slice(this._offset,this._offset+U).toString();return this._offset+=U,M}writeBuffer(U){this._buff.writeUInt32BE(U.byteLength,this._offset),this._offset+=4,this._buff.set(U,this._offset),this._offset+=U.byteLength}static sizeVSBuffer(U){return 4+U.byteLength}writeVSBuffer(U){this._buff.writeUInt32BE(U.byteLength,this._offset),this._offset+=4,this._buff.set(U,this._offset),this._offset+=U.byteLength}readVSBuffer(){const U=this._buff.readUInt32BE(this._offset);this._offset+=4;const W=this._buff.slice(this._offset,this._offset+U);return this._offset+=U,W}static sizeMixedArray(U){let W=0;W+=1;for(let M=0,S=U.length;M<S;M++){const z=U[M];switch(W+=1,z.type){case 1:W+=this.sizeLongString(z.value);break;case 2:W+=this.sizeVSBuffer(z.value);break;case 3:W+=this.sizeUInt32,W+=this.sizeLongString(z.value);for(let $=0;$<z.buffers.length;++$)W+=this.sizeVSBuffer(z.buffers[$]);break;case 4:break}}return W}writeMixedArray(U){this._buff.writeUInt8(U.length,this._offset),this._offset+=1;for(let W=0,M=U.length;W<M;W++){const S=U[W];switch(S.type){case 1:this.writeUInt8(1),this.writeLongString(S.value);break;case 2:this.writeUInt8(2),this.writeVSBuffer(S.value);break;case 3:this.writeUInt8(3),this.writeUInt32(S.buffers.length),this.writeLongString(S.value);for(let z=0;z<S.buffers.length;++z)this.writeBuffer(S.buffers[z]);break;case 4:this.writeUInt8(4);break}}}readMixedArray(){const U=this._buff.readUInt8(this._offset);this._offset+=1;const W=new Array(U);for(let M=0;M<U;M++)switch(this.readUInt8()){case 1:W[M]=this.readLongString();break;case 2:W[M]=this.readVSBuffer();break;case 3:{const z=this.readUInt32(),$=this.readLongString(),N=[];for(let K=0;K<z;++K)N.push(this.readVSBuffer());W[M]=new R.SerializableObjectWithBuffers(a($,N,null));break}case 4:W[M]=void 0;break}return W}}r.sizeUInt32=4;var t;(function(D){D[D.Simple=0]="Simple",D[D.Mixed=1]="Mixed"})(t||(t={}));class c{static _useMixedArgSerialization(U){for(let W=0,M=U.length;W<M;W++)if(U[W]instanceof p.VSBuffer||U[W]instanceof R.SerializableObjectWithBuffers||typeof U[W]=="undefined")return!0;return!1}static serializeRequestArguments(U,W){if(this._useMixedArgSerialization(U)){const M=[];for(let S=0,z=U.length;S<z;S++){const $=U[S];if($ instanceof p.VSBuffer)M[S]={type:2,value:$};else if(typeof $=="undefined")M[S]={type:4};else if($ instanceof R.SerializableObjectWithBuffers){const{jsonString:N,referencedBuffers:K}=d($.value,W);M[S]={type:3,value:p.VSBuffer.fromString(N),buffers:K}}else M[S]={type:1,value:p.VSBuffer.fromString(w($,W))}}return{type:1,args:M}}return{type:0,args:w(U,W)}}static serializeRequest(U,W,M,S,z){switch(S.type){case 0:return this._requestJSONArgs(U,W,M,S.args,z);case 1:return this._requestMixedArgs(U,W,M,S.args,z)}}static _requestJSONArgs(U,W,M,S,z){const $=p.VSBuffer.fromString(M),N=p.VSBuffer.fromString(S);let K=0;K+=r.sizeUInt8(),K+=r.sizeShortString($),K+=r.sizeLongString(N);const V=r.alloc(z?2:1,U,K);return V.writeUInt8(W),V.writeShortString($),V.writeLongString(N),V.buffer}static deserializeRequestJSONArgs(U){const W=U.readUInt8(),M=U.readShortString(),S=U.readLongString();return{rpcId:W,method:M,args:JSON.parse(S)}}static _requestMixedArgs(U,W,M,S,z){const $=p.VSBuffer.fromString(M);let N=0;N+=r.sizeUInt8(),N+=r.sizeShortString($),N+=r.sizeMixedArray(S);const K=r.alloc(z?4:3,U,N);return K.writeUInt8(W),K.writeShortString($),K.writeMixedArray(S),K.buffer}static deserializeRequestMixedArgs(U){const W=U.readUInt8(),M=U.readShortString(),S=U.readMixedArray(),z=new Array(S.length);for(let $=0,N=S.length;$<N;$++){const K=S[$];typeof K=="string"?z[$]=JSON.parse(K):z[$]=K}return{rpcId:W,method:M,args:z}}static serializeAcknowledged(U){return r.alloc(5,U,0).buffer}static serializeCancel(U){return r.alloc(6,U,0).buffer}static serializeReplyOK(U,W,M){if(typeof W=="undefined")return this._serializeReplyOKEmpty(U);if(W instanceof p.VSBuffer)return this._serializeReplyOKVSBuffer(U,W);if(W instanceof R.SerializableObjectWithBuffers){const{jsonString:S,referencedBuffers:z}=d(W.value,M,!0);return this._serializeReplyOKJSONWithBuffers(U,S,z)}else return this._serializeReplyOKJSON(U,m(W,M))}static _serializeReplyOKEmpty(U){return r.alloc(7,U,0).buffer}static _serializeReplyOKVSBuffer(U,W){let M=0;M+=r.sizeVSBuffer(W);const S=r.alloc(8,U,M);return S.writeVSBuffer(W),S.buffer}static deserializeReplyOKVSBuffer(U){return U.readVSBuffer()}static _serializeReplyOKJSON(U,W){const M=p.VSBuffer.fromString(W);let S=0;S+=r.sizeLongString(M);const z=r.alloc(9,U,S);return z.writeLongString(M),z.buffer}static _serializeReplyOKJSONWithBuffers(U,W,M){const S=p.VSBuffer.fromString(W);let z=0;z+=r.sizeUInt32,z+=r.sizeLongString(S);for(const N of M)z+=r.sizeVSBuffer(N);const $=r.alloc(10,U,z);$.writeUInt32(M.length),$.writeLongString(S);for(const N of M)$.writeBuffer(N);return $.buffer}static deserializeReplyOKJSON(U){const W=U.readLongString();return JSON.parse(W)}static deserializeReplyOKJSONWithBuffers(U,W){const M=U.readUInt32(),S=U.readLongString(),z=[];for(let $=0;$<M;++$)z.push(U.readVSBuffer());return new R.SerializableObjectWithBuffers(a(S,z,W))}static serializeReplyErr(U,W){const M=W?m(L.transformErrorForSerialization(W),null):void 0;if(typeof M!="string")return this._serializeReplyErrEmpty(U);const S=p.VSBuffer.fromString(M);let z=0;z+=r.sizeLongString(S);const $=r.alloc(11,U,z);return $.writeLongString(S),$.buffer}static deserializeReplyErrError(U){const W=U.readLongString();return JSON.parse(W)}static _serializeReplyErrEmpty(U){return r.alloc(12,U,0).buffer}}var v;(function(D){D[D.RequestJSONArgs=1]="RequestJSONArgs",D[D.RequestJSONArgsWithCancellation=2]="RequestJSONArgsWithCancellation",D[D.RequestMixedArgs=3]="RequestMixedArgs",D[D.RequestMixedArgsWithCancellation=4]="RequestMixedArgsWithCancellation",D[D.Acknowledged=5]="Acknowledged",D[D.Cancel=6]="Cancel",D[D.ReplyOKEmpty=7]="ReplyOKEmpty",D[D.ReplyOKVSBuffer=8]="ReplyOKVSBuffer",D[D.ReplyOKJSON=9]="ReplyOKJSON",D[D.ReplyOKJSONWithBuffers=10]="ReplyOKJSONWithBuffers",D[D.ReplyErrError=11]="ReplyErrError",D[D.ReplyErrEmpty=12]="ReplyErrEmpty"})(v||(v={}));var g;(function(D){D[D.String=1]="String",D[D.VSBuffer=2]="VSBuffer",D[D.SerializedObjectWithBuffers=3]="SerializedObjectWithBuffers",D[D.Undefined=4]="Undefined"})(g||(g={}))}),define(ye[222],Ce([1,0]),function(ee,e){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.NestedWorker=void 0;const s=function(L){const C=T=>{self.removeEventListener("message",C);const E=T.data;Object.defineProperties(self,{postMessage:{value(A,R){E.postMessage(A,R)}},onmessage:{get(){return E.onmessage},set(A){E.onmessage=A}}}),E.addEventListener("message",A=>{self.dispatchEvent(new MessageEvent("message",{data:A.data}))}),E.start(),self.Worker=class{constructor(){throw new TypeError("Nested workers from within nested worker are NOT supported.")}},importScripts(L)};self.addEventListener("message",C)}.toString();class p extends EventTarget{constructor(L,C,T){super();this.onmessage=null,this.onmessageerror=null,this.onerror=null;const E=`((${s})('${C}'))`,A=new Blob([E],{type:"application/javascript"}),R=URL.createObjectURL(A),y=new MessageChannel,m=R,I={type:"_newWorker",id:m,port:y.port2,url:R,options:T};L(I,[y.port2]),this.postMessage=y.port1.postMessage.bind(y.port1),this.terminate=()=>{L({type:"_terminateWorker",id:m}),URL.revokeObjectURL(R),y.port1.close(),y.port2.close()},Object.defineProperties(this,{onmessage:{get(){return y.port1.onmessage},set(f){y.port1.onmessage=f}},onmessageerror:{get(){return y.port1.onmessageerror},set(f){y.port1.onmessageerror=f}}}),y.port1.addEventListener("messageerror",f=>{const h=new MessageEvent("messageerror",{data:f.data});this.dispatchEvent(h)}),y.port1.addEventListener("message",f=>{const h=new MessageEvent("message",{data:f.data});this.dispatchEvent(h)}),y.port1.start()}}e.NestedWorker=p}),define(ye[223],Ce([1,0,4,30,38,3,39,11,13]),function(ee,e,s,p,b,L,C,T,E){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.registerLogChannel=e.Extensions=e.OutputChannelUpdateMode=e.IOutputService=e.CONTEXT_OUTPUT_SCROLL_LOCK=e.CONTEXT_ACTIVE_LOG_OUTPUT=e.CONTEXT_IN_OUTPUT=e.MAX_OUTPUT_LENGTH=e.OUTPUT_SERVICE_ID=e.OUTPUT_VIEW_ID=e.LOG_MODE_ID=e.LOG_SCHEME=e.LOG_MIME=e.OUTPUT_MODE_ID=e.OUTPUT_SCHEME=e.OUTPUT_MIME=void 0,e.OUTPUT_MIME="text/x-code-output",e.OUTPUT_SCHEME="output",e.OUTPUT_MODE_ID="Log",e.LOG_MIME="text/x-code-log-output",e.LOG_SCHEME="log",e.LOG_MODE_ID="log",e.OUTPUT_VIEW_ID="workbench.panel.output",e.OUTPUT_SERVICE_ID="outputService",e.MAX_OUTPUT_LENGTH=1e4*100,e.CONTEXT_IN_OUTPUT=new b.RawContextKey("inOutput",!1),e.CONTEXT_ACTIVE_LOG_OUTPUT=new b.RawContextKey("activeLogOutput",!1),e.CONTEXT_OUTPUT_SCROLL_LOCK=new b.RawContextKey("outputView.scrollLock",!1),e.IOutputService=(0,L.createDecorator)(e.OUTPUT_SERVICE_ID);var A;(function(I){I[I.Append=1]="Append",I[I.Replace=2]="Replace",I[I.Clear=3]="Clear"})(A=e.OutputChannelUpdateMode||(e.OutputChannelUpdateMode={})),e.Extensions={OutputChannels:"workbench.contributions.outputChannels"};class R{constructor(){this.channels=new Map,this._onDidRegisterChannel=new s.Emitter,this.onDidRegisterChannel=this._onDidRegisterChannel.event,this._onDidRemoveChannel=new s.Emitter,this.onDidRemoveChannel=this._onDidRemoveChannel.event}registerChannel(f){this.channels.has(f.id)||(this.channels.set(f.id,f),this._onDidRegisterChannel.fire(f.id))}getChannels(){const f=[];return this.channels.forEach(h=>f.push(h)),f}getChannel(f){return this.channels.get(f)}removeChannel(f){this.channels.delete(f),this._onDidRemoveChannel.fire(f)}}p.Registry.add(e.Extensions.OutputChannels,new R);function y(I,f,h,d,a){return(0,E.createCancelablePromise)(async w=>{await(0,C.whenProviderRegistered)(h,d);const P=p.Registry.as(e.Extensions.OutputChannels);try{await m(h,1,d,a,w),P.registerChannel({id:I,label:f,file:h,log:!0})}catch(l){(0,T.isCancellationError)(l)||a.error("Error while registering log channel",h.toString(),(0,T.getErrorMessage)(l))}})}e.registerLogChannel=y;async function m(I,f,h,d,a){if(!await h.exists(I)){if(a.isCancellationRequested)throw new T.CancellationError;if(f>10)throw new Error("Timed out while waiting for file to be created");d.debug("[Registering Log Channel] File does not exist. Waiting for 1s to retry.",I.toString()),await(0,E.timeout)(1e3,a),await m(I,f+1,h,d,a)}}}),define(ye[98],Ce([1,0,5,7,3,15,14,223,51,28,35,117,22,10]),function(ee,e,s,p,b,L,C,T,E,A,R,y,m,I){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.IExtHostOutputService=e.ExtHostOutputService=e.ExtHostOutputChannel=void 0;class f extends p.Disposable{constructor(a,w,P,l){super();this.id=a,this.name=w,this.logger=P,this.proxy=l,this.offset=0,this.visible=!1,this._disposed=!1}get disposed(){return this._disposed}appendLine(a){this.append(a+`
`)}append(a){this.write(a),this.visible&&(this.logger.flush(),this.proxy.$update(this.id,T.OutputChannelUpdateMode.Append))}clear(){const a=this.offset;this.logger.flush(),this.proxy.$update(this.id,T.OutputChannelUpdateMode.Clear,a)}replace(a){const w=this.offset;this.write(a),this.proxy.$update(this.id,T.OutputChannelUpdateMode.Replace,w),this.visible&&this.logger.flush()}show(a,w){this.logger.flush(),this.proxy.$reveal(this.id,!!(typeof a=="boolean"?a:w))}hide(){this.proxy.$close(this.id)}write(a){this.offset+=m.VSBuffer.fromString(a).byteLength,this.logger.info(a)}dispose(){super.dispose(),this._disposed||(this.proxy.$dispose(this.id),this._disposed=!0)}}e.ExtHostOutputChannel=f;let h=class{constructor(a,w,P,l,_){this.extHostFileSystem=P,this.extHostFileSystemInfo=l,this.loggerService=_,this.namePool=1,this.channels=new Map,this.visibleChannelId=null,this.proxy=a.getProxy(s.MainContext.MainThreadOutputService),this.outputsLocation=this.extHostFileSystemInfo.extUri.joinPath(w.logsLocation,`output_logging_${(0,y.toLocalISOString)(new Date).replace(/-|:|\.\d+Z$/g,"")}`)}$setVisibleChannel(a){this.visibleChannelId=a;for(const[w,P]of this.channels)P.visible=w===this.visibleChannelId}createOutputChannel(a,w,P){if(a=a.trim(),!a)throw new Error("illegal argument `name`. must not be falsy");if((0,I.isString)(w)&&!w.trim())throw new Error("illegal argument `languageId`. must not be empty");const l=this.doCreateOutputChannel(a,w,P);return l.then(_=>{this.channels.set(_.id,_),_.visible=_.id===this.visibleChannelId}),this.createExtHostOutputChannel(a,l)}async doCreateOutputChannel(a,w,P){const l=await this.createOutputDirectory(),_=this.extHostFileSystemInfo.extUri.joinPath(l,`${this.namePool++}-${a.replace(/[\\/:\*\?"<>\|]/g,"")}.log`),n=this.loggerService.createLogger(_,{always:!0,donotRotate:!0,donotUseFormatters:!0}),u=await this.proxy.$register(a,!1,_,w,P.identifier.value);return new f(u,a,n,this.proxy)}createOutputDirectory(){return this.outputDirectoryPromise||(this.outputDirectoryPromise=this.extHostFileSystem.value.createDirectory(this.outputsLocation).then(()=>this.outputsLocation)),this.outputDirectoryPromise}createExtHostOutputChannel(a,w){let P=!1;const l=()=>{if(P)throw new Error("Channel has been closed")};return{get name(){return a},append(_){l(),w.then(n=>n.append(_))},appendLine(_){l(),w.then(n=>n.appendLine(_))},clear(){l(),w.then(_=>_.clear())},replace(_){l(),w.then(n=>n.replace(_))},show(_,n){l(),w.then(u=>u.show(_,n))},hide(){l(),w.then(_=>_.hide())},dispose(){P=!0,w.then(_=>_.dispose())}}}};h=ze([xe(0,L.IExtHostRpcService),xe(1,A.IExtHostInitDataService),xe(2,E.IExtHostConsumerFileSystem),xe(3,R.IExtHostFileSystemInfo),xe(4,C.ILoggerService)],h),e.ExtHostOutputService=h,e.IExtHostOutputService=(0,b.createDecorator)("IExtHostOutputService")}),define(ye[224],Ce([1,0,3]),function(ee,e,s){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.IRemoteAgentService=e.RemoteExtensionLogFileName=void 0,e.RemoteExtensionLogFileName="remoteagent",e.IRemoteAgentService=(0,s.createDecorator)("remoteAgentService")}),define(ye[225],Ce([1,0,37,12,19,23,21,2,3,156,45,177,224]),function(ee,e,s,p,b,L,C,T,E,A,R,y,m){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.AbstractPathService=e.IPathService=void 0,e.IPathService=(0,E.createDecorator)("pathService");let I=class Yi{constructor(h,d,a,w){this.localUserHome=h,this.remoteAgentService=d,this.environmentService=a,this.contextService=w,this.resolveOS=(async()=>(await this.remoteAgentService.getEnvironment())?.os||L.OS)(),this.resolveUserHome=(async()=>{const P=await this.remoteAgentService.getEnvironment();return this.maybeUnresolvedUserHome=P?.userHome??h})()}hasValidBasename(h,d,a){return typeof d=="string"||typeof d=="undefined"?this.resolveOS.then(w=>this.doHasValidBasename(h,w,d)):this.doHasValidBasename(h,d,a)}doHasValidBasename(h,d,a){return h.scheme===p.Schemas.file||h.scheme===p.Schemas.vscodeRemote?(0,s.isValidBasename)(a??(0,C.basename)(h),d===1):!0}get defaultUriScheme(){return Yi.findDefaultUriScheme(this.environmentService,this.contextService)}static findDefaultUriScheme(h,d){if(h.remoteAuthority)return p.Schemas.vscodeRemote;const a=(0,A.getVirtualWorkspaceScheme)(d.getWorkspace());if(a)return a;const w=d.getWorkspace().folders[0];if(w)return w.uri.scheme;const P=d.getWorkspace().configuration;return P?P.scheme:p.Schemas.file}userHome(h){return h?.preferLocal?this.localUserHome:this.resolveUserHome}get resolvedUserHome(){return this.maybeUnresolvedUserHome}get path(){return this.resolveOS.then(h=>h===1?b.win32:b.posix)}async fileURI(h){let d="";if(await this.resolveOS===1&&(h=h.replace(/\\/g,"/")),h[0]==="/"&&h[1]==="/"){const w=h.indexOf("/",2);w===-1?(d=h.substring(2),h="/"):(d=h.substring(2,w),h=h.substring(w)||"/")}return T.URI.from({scheme:p.Schemas.file,authority:d,path:h,query:"",fragment:""})}};I=ze([xe(1,m.IRemoteAgentService),xe(2,y.IWorkbenchEnvironmentService),xe(3,R.IWorkspaceContextService)],I),e.AbstractPathService=I}),define(ye[99],Ce([1,0]),function(ee,e){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.TextSearchCompleteMessageType=e.Range=e.Position=void 0;class s{constructor(C,T){this.line=C,this.character=T}isBefore(C){return!1}isBeforeOrEqual(C){return!1}isAfter(C){return!1}isAfterOrEqual(C){return!1}isEqual(C){return!1}compareTo(C){return 0}translate(C,T){return new s(0,0)}with(C){return new s(0,0)}}e.Position=s;class p{constructor(C,T,E,A){this.isEmpty=!1,this.isSingleLine=!1,this.start=new s(C,T),this.end=new s(E,A)}contains(C){return!1}isEqual(C){return!1}intersection(C){}union(C){return new p(0,0,0,0)}with(C){return new p(0,0,0,0)}}e.Range=p;var b;(function(L){L[L.Information=1]="Information",L[L.Warning=2]="Warning"})(b=e.TextSearchCompleteMessageType||(e.TextSearchCompleteMessageType={}))}),define(ye[41],Ce([1,0,16,34,26,37,9,3,19,11,99,13]),function(ee,e,s,p,b,L,C,T,E,A,R,y){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.hasSiblingFn=e.hasSiblingPromiseFn=e.QueryGlobTester=e.resolvePatternsForProvider=e.SerializableFileMatch=e.isFilePatternMatch=e.isSerializedFileMatch=e.isSerializedSearchSuccess=e.isSerializedSearchComplete=e.serializeSearchError=e.deserializeSearchError=e.SearchError=e.SearchErrorCode=e.pathIncludedInQuery=e.getExcludes=e.SearchSortOrder=e.OneLineRange=e.SearchRange=e.TextSearchMatch=e.FileMatch=e.SearchCompletionExitCode=e.isProgressMessage=e.isFileMatch=e.resultIsMatch=e.QueryType=e.SearchProviderType=e.ISearchService=e.SEARCH_EXCLUDE_CONFIG=e.VIEW_ID=e.PANEL_ID=e.VIEWLET_ID=e.TextSearchCompleteMessageType=void 0,Object.defineProperty(e,"TextSearchCompleteMessageType",{enumerable:!0,get:function(){return R.TextSearchCompleteMessageType}}),e.VIEWLET_ID="workbench.view.search",e.PANEL_ID="workbench.panel.search",e.VIEW_ID="workbench.view.search",e.SEARCH_EXCLUDE_CONFIG="search.exclude";const m="\u27EA ",I=" characters skipped \u27EB",f=(m.length+I.length+5)*2;e.ISearchService=(0,T.createDecorator)("searchService");var h;(function(re){re[re.file=0]="file",re[re.text=1]="text"})(h=e.SearchProviderType||(e.SearchProviderType={}));var d;(function(re){re[re.File=1]="File",re[re.Text=2]="Text"})(d=e.QueryType||(e.QueryType={}));function a(re){return!!re.preview}e.resultIsMatch=a;function w(re){return!!re.resource}e.isFileMatch=w;function P(re){return!!re.message}e.isProgressMessage=P;var l;(function(re){re[re.Normal=0]="Normal",re[re.NewSearchStarted=1]="NewSearchStarted"})(l=e.SearchCompletionExitCode||(e.SearchCompletionExitCode={}));class _{constructor(fe){this.resource=fe,this.results=[]}}e.FileMatch=_;class n{constructor(fe,ie,Ee){this.ranges=ie;const be=Array.isArray(ie)?ie:[ie];if(Ee&&Ee.matchLines===1&&u(be)){fe=(0,C.getNLines)(fe,Ee.matchLines);let te="",ve=0,Re=0;const Fe=Math.floor(Ee.charsPerLine/5),$e=[];for(const Ye of be){const Ie=Math.max(Ye.startColumn-Fe,0),Se=Ye.startColumn+Ee.charsPerLine;if(Ie>Re+Fe+f){const Te=m+(Ie-Re)+I;te+=Te+fe.slice(Ie,Se),ve+=Ie-(Re+Te.length)}else te+=fe.slice(Re,Se);$e.push(new o(0,Ye.startColumn-ve,Ye.endColumn-ve)),Re=Se}this.preview={text:te,matches:Array.isArray(this.ranges)?$e:$e[0]}}else{const te=Array.isArray(ie)?ie[0].startLineNumber:ie.startLineNumber;this.preview={text:fe,matches:(0,s.mapArrayOrNot)(ie,ve=>new i(ve.startLineNumber-te,ve.startColumn,ve.endLineNumber-te,ve.endColumn))}}}}e.TextSearchMatch=n;function u(re){const fe=re[0].startLineNumber;for(const ie of re)if(ie.startLineNumber!==fe||ie.endLineNumber!==fe)return!1;return!0}class i{constructor(fe,ie,Ee,be){this.startLineNumber=fe,this.startColumn=ie,this.endLineNumber=Ee,this.endColumn=be}}e.SearchRange=i;class o extends i{constructor(fe,ie,Ee){super(fe,ie,fe,Ee)}}e.OneLineRange=o;var r;(function(re){re.Default="default",re.FileNames="fileNames",re.Type="type",re.Modified="modified",re.CountDescending="countDescending",re.CountAscending="countAscending"})(r=e.SearchSortOrder||(e.SearchSortOrder={}));function t(re,fe=!0){const ie=re&&re.files&&re.files.exclude,Ee=fe&&re&&re.search&&re.search.exclude;if(!ie&&!Ee)return;if(!ie||!Ee)return ie||Ee;let be=Object.create(null);return be=b.mixin(be,b.deepClone(ie)),be=b.mixin(be,b.deepClone(Ee),!0),be}e.getExcludes=t;function c(re,fe){return re.excludePattern&&p.match(re.excludePattern,fe)?!1:re.includePattern||re.usingSearchPaths?re.includePattern&&p.match(re.includePattern,fe)?!0:re.usingSearchPaths?!!re.folderQueries&&re.folderQueries.some(ie=>{const Ee=ie.folder.fsPath;if(L.isEqualOrParent(fe,Ee)){const be=E.relative(Ee,fe);return!ie.includePattern||!!p.match(ie.includePattern,be)}else return!1}):!1:!0}e.pathIncludedInQuery=c;var v;(function(re){re[re.unknownEncoding=1]="unknownEncoding",re[re.regexParseError=2]="regexParseError",re[re.globParseError=3]="globParseError",re[re.invalidLiteral=4]="invalidLiteral",re[re.rgProcessError=5]="rgProcessError",re[re.other=6]="other",re[re.canceled=7]="canceled"})(v=e.SearchErrorCode||(e.SearchErrorCode={}));class g extends Error{constructor(fe,ie){super(fe);this.code=ie}}e.SearchError=g;function D(re){const fe=re.message;if((0,A.isCancellationError)(re))return new g(fe,v.canceled);try{const ie=JSON.parse(fe);return new g(ie.message,ie.code)}catch{return new g(fe,v.other)}}e.deserializeSearchError=D;function U(re){const fe={message:re.message,code:re.code};return new Error(JSON.stringify(fe))}e.serializeSearchError=U;function W(re){return re.type==="error"?!0:re.type==="success"}e.isSerializedSearchComplete=W;function M(re){return re.type==="success"}e.isSerializedSearchSuccess=M;function S(re){return!!re.path}e.isSerializedFileMatch=S;function z(re,fe){const ie=re.searchPath?re.searchPath:re.relativePath;return(0,C.fuzzyContains)(ie,fe)}e.isFilePatternMatch=z;class ${constructor(fe){this.path=fe,this.results=[]}addMatch(fe){this.results.push(fe)}serialize(){return{path:this.path,results:this.results,numMatches:this.results.length}}}e.SerializableFileMatch=$;function N(re,fe){const ie={...re||{},...fe||{}};return Object.keys(ie).filter(Ee=>{const be=ie[Ee];return typeof be=="boolean"&&be})}e.resolvePatternsForProvider=N;class K{constructor(fe,ie){this._parsedIncludeExpression=null,this._excludeExpression={...fe.excludePattern||{},...ie.excludePattern||{}},this._parsedExcludeExpression=p.parse(this._excludeExpression);let Ee=fe.includePattern;ie.includePattern&&(Ee?Ee={...Ee,...ie.includePattern}:Ee=ie.includePattern),Ee&&(this._parsedIncludeExpression=p.parse(Ee))}matchesExcludesSync(fe,ie,Ee){return!!(this._parsedExcludeExpression&&this._parsedExcludeExpression(fe,ie,Ee))}includedInQuerySync(fe,ie,Ee){return!(this._parsedExcludeExpression&&this._parsedExcludeExpression(fe,ie,Ee)||this._parsedIncludeExpression&&!this._parsedIncludeExpression(fe,ie,Ee))}includedInQuery(fe,ie,Ee){const be=this._parsedExcludeExpression(fe,ie,Ee),te=()=>this._parsedIncludeExpression?!!this._parsedIncludeExpression(fe,ie,Ee):!0;return(0,y.isThenable)(be)?be.then(ve=>ve?!1:te()):te()}hasSiblingExcludeClauses(){return V(this._excludeExpression)}}e.QueryGlobTester=K;function V(re){for(const fe in re)if(typeof re[fe]!="boolean")return!0;return!1}function F(re){if(!re)return;let fe;return ie=>(fe||(fe=(re()||Promise.resolve([])).then(Ee=>Ee?ce(Ee):{})),fe.then(Ee=>!!Ee[ie]))}e.hasSiblingPromiseFn=F;function ne(re){if(!re)return;let fe;return ie=>{if(!fe){const Ee=re();fe=Ee?ce(Ee):{}}return!!fe[ie]}}e.hasSiblingFn=ne;function ce(re){const fe={};for(const ie of re)fe[ie]=!0;return fe}}),define(ye[31],Ce([1,0,16,13,20,4,25,12,106,21,9,10,2,134,3,14,148,45,35,28,15,8,6,41,5]),function(ee,e,s,p,b,L,C,T,E,A,R,y,m,I,f,h,d,a,w,P,l,_,n,u,i){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.IExtHostWorkspace=e.ExtHostWorkspace=void 0;function o(W,M,S){return new A.ExtUri(z=>v(z,S)).isEqual(W,M)}function r(W,M,S){return o(W.uri,M.uri,S)?0:(0,R.compare)(W.uri.toString(),M.uri.toString())}function t(W,M,S){return W.index!==M.index?W.index<M.index?-1:1:o(W.uri,M.uri,S)?(0,R.compare)(W.name,M.name):(0,R.compare)(W.uri.toString(),M.uri.toString())}function c(W,M,S,z){const $=W.slice(0).sort((K,V)=>S(K,V,z)),N=M.slice(0).sort((K,V)=>S(K,V,z));return(0,s.delta)($,N,(K,V)=>S(K,V,z))}function v(W,M){const S=M.getCapabilities(W.scheme);return!(S&&S&1024)}class g extends a.Workspace{constructor(M,S,z,$,N,K,V){super(M,z.map(F=>new a.WorkspaceFolder(F)),$,N,V);this._name=S,this._isUntitled=K,this._workspaceFolders=[],this._structure=C.TernarySearchTree.forUris(V),z.forEach(F=>{this._workspaceFolders.push(F),this._structure.set(F.uri,F)})}static toExtHostWorkspace(M,S,z,$){if(!M)return{workspace:null,added:[],removed:[]};const{id:N,name:K,folders:V,configuration:F,transient:ne,isUntitled:ce}=M,re=[],fe=S;S?V.forEach((te,ve)=>{const Re=m.URI.revive(te.uri),Fe=g._findFolder(z||S,Re,$);Fe?(Fe.name=te.name,Fe.index=te.index,re.push(Fe)):re.push({uri:Re,name:te.name,index:ve})}):re.push(...V.map(({uri:te,name:ve,index:Re})=>({uri:m.URI.revive(te),name:ve,index:Re}))),re.sort((te,ve)=>te.index<ve.index?-1:1);const ie=new g(N,K,re,!!ne,F?m.URI.revive(F):null,!!ce,te=>v(te,$)),{added:Ee,removed:be}=c(fe?fe.workspaceFolders:[],ie.workspaceFolders,r,$);return{workspace:ie,added:Ee,removed:be}}static _findFolder(M,S,z){for(let $=0;$<M.folders.length;$++){const N=M.workspaceFolders[$];if(o(N.uri,S,z))return N}}get name(){return this._name}get isUntitled(){return this._isUntitled}get workspaceFolders(){return this._workspaceFolders.slice(0)}getWorkspaceFolder(M,S){return S&&this._structure.get(M)&&(M=(0,A.dirname)(M)),this._structure.findSubstr(M)}resolveWorkspaceFolder(M){return this._structure.get(M)}}let D=class{constructor(M,S,z,$){this._onDidChangeWorkspace=new L.Emitter,this.onDidChangeWorkspace=this._onDidChangeWorkspace.event,this._onDidGrantWorkspaceTrust=new L.Emitter,this.onDidGrantWorkspaceTrust=this._onDidGrantWorkspaceTrust.event,this._activeSearchCallbacks=[],this._trusted=!1,this._logService=$,this._extHostFileSystemInfo=z,this._requestIdProvider=new E.Counter,this._barrier=new p.Barrier,this._proxy=M.getProxy(i.MainContext.MainThreadWorkspace),this._messageService=M.getProxy(i.MainContext.MainThreadMessageService);const N=S.workspace;this._confirmedWorkspace=N?new g(N.id,N.name,[],!!N.transient,N.configuration?m.URI.revive(N.configuration):null,!!N.isUntitled,K=>v(K,z)):void 0}$initializeWorkspace(M,S){this._trusted=S,this.$acceptWorkspaceData(M),this._barrier.open()}waitForInitializeCall(){return this._barrier.wait()}get workspace(){return this._actualWorkspace}get name(){return this._actualWorkspace?this._actualWorkspace.name:void 0}get workspaceFile(){if(this._actualWorkspace&&this._actualWorkspace.configuration)return this._actualWorkspace.isUntitled?m.URI.from({scheme:T.Schemas.untitled,path:(0,A.basename)((0,A.dirname)(this._actualWorkspace.configuration))}):this._actualWorkspace.configuration}get _actualWorkspace(){return this._unconfirmedWorkspace||this._confirmedWorkspace}getWorkspaceFolders(){if(!!this._actualWorkspace)return this._actualWorkspace.workspaceFolders.slice(0)}async getWorkspaceFolders2(){if(await this._barrier.wait(),!!this._actualWorkspace)return this._actualWorkspace.workspaceFolders.slice(0)}updateWorkspaceFolders(M,S,z,...$){const N=[];if(Array.isArray($)&&$.forEach(ce=>{m.URI.isUri(ce.uri)&&!N.some(re=>o(re.uri,ce.uri,this._extHostFileSystemInfo))&&N.push({uri:ce.uri,name:ce.name||(0,A.basenameOrAuthority)(ce.uri)})}),this._unconfirmedWorkspace||[S,z].some(ce=>typeof ce!="number"||ce<0)||z===0&&N.length===0)return!1;const K=this._actualWorkspace?this._actualWorkspace.workspaceFolders:[];if(S+z>K.length)return!1;const V=K.slice(0);V.splice(S,z,...N.map(ce=>({uri:ce.uri,name:ce.name||(0,A.basenameOrAuthority)(ce.uri),index:void 0})));for(let ce=0;ce<V.length;ce++){const re=V[ce];if(V.some((fe,ie)=>ie!==ce&&o(re.uri,fe.uri,this._extHostFileSystemInfo)))return!1}V.forEach((ce,re)=>ce.index=re);const{added:F,removed:ne}=c(K,V,t,this._extHostFileSystemInfo);if(F.length===0&&ne.length===0)return!1;if(this._proxy){const ce=M.displayName||M.name;this._proxy.$updateWorkspaceFolders(ce,S,z,N).then(void 0,re=>{this._unconfirmedWorkspace=void 0;const fe={source:{identifier:M.identifier,label:M.displayName||M.name}};this._messageService.$showMessage(d.Severity.Error,(0,I.localize)(0,null,ce,re.toString()),fe,[])})}return this.trySetWorkspaceFolders(V),!0}getWorkspaceFolder(M,S){if(!!this._actualWorkspace)return this._actualWorkspace.getWorkspaceFolder(M,S)}async getWorkspaceFolder2(M,S){if(await this._barrier.wait(),!!this._actualWorkspace)return this._actualWorkspace.getWorkspaceFolder(M,S)}async resolveWorkspaceFolder(M){if(await this._barrier.wait(),!!this._actualWorkspace)return this._actualWorkspace.resolveWorkspaceFolder(M)}getPath(){if(!this._actualWorkspace)return;const{folders:M}=this._actualWorkspace;if(M.length!==0)return M[0].uri.fsPath}getRelativePath(M,S){let z,$="";if(typeof M=="string"?(z=m.URI.file(M),$=M):typeof M!="undefined"&&(z=M,$=M.fsPath),!z)return $;const N=this.getWorkspaceFolder(z,!0);if(!N)return $;typeof S=="undefined"&&this._actualWorkspace&&(S=this._actualWorkspace.folders.length>1);let K=(0,A.relativePath)(N.uri,z);return S&&N.name&&(K=`${N.name}/${K}`),K}trySetWorkspaceFolders(M){this._actualWorkspace&&(this._unconfirmedWorkspace=g.toExtHostWorkspace({id:this._actualWorkspace.id,name:this._actualWorkspace.name,configuration:this._actualWorkspace.configuration,folders:M,isUntitled:this._actualWorkspace.isUntitled},this._actualWorkspace,void 0,this._extHostFileSystemInfo).workspace||void 0)}$acceptWorkspaceData(M){const{workspace:S,added:z,removed:$}=g.toExtHostWorkspace(M,this._confirmedWorkspace,this._unconfirmedWorkspace,this._extHostFileSystemInfo);this._confirmedWorkspace=S||void 0,this._unconfirmedWorkspace=void 0,this._onDidChangeWorkspace.fire(Object.freeze({added:z,removed:$}))}findFiles(M,S,z,$,N=b.CancellationToken.None){this._logService.trace(`extHostWorkspace#findFiles: fileSearch, extension: ${$.value}, entryPoint: findFiles`);let K;if(S===null?K=!1:S&&(typeof S=="string"?K=S:K=S.pattern),N&&N.isCancellationRequested)return Promise.resolve([]);const{includePattern:V,folder:F}=U(_.GlobPattern.from(M));return this._proxy.$startFileSearch((0,y.withUndefinedAsNull)(V),(0,y.withUndefinedAsNull)(F),(0,y.withUndefinedAsNull)(K),(0,y.withUndefinedAsNull)(z),N).then(ne=>Array.isArray(ne)?ne.map(ce=>m.URI.revive(ce)):[])}async findTextInFiles(M,S,z,$,N=b.CancellationToken.None){this._logService.trace(`extHostWorkspace#findTextInFiles: textSearch, extension: ${$.value}, entryPoint: findTextInFiles`);const K=this._requestIdProvider.getNext(),V=typeof S.previewOptions=="undefined"?{matchLines:100,charsPerLine:1e4}:S.previewOptions,{includePattern:F,folder:ne}=U(_.GlobPattern.from(S.include)),ce=typeof S.exclude=="string"?S.exclude:S.exclude?S.exclude.pattern:void 0,re={ignoreSymlinks:typeof S.followSymlinks=="boolean"?!S.followSymlinks:void 0,disregardIgnoreFiles:typeof S.useIgnoreFiles=="boolean"?!S.useIgnoreFiles:void 0,disregardGlobalIgnoreFiles:typeof S.useGlobalIgnoreFiles=="boolean"?!S.useGlobalIgnoreFiles:void 0,disregardParentIgnoreFiles:typeof S.useParentIgnoreFiles=="boolean"?!S.useParentIgnoreFiles:void 0,disregardExcludeSettings:typeof S.useDefaultExcludes=="boolean"?!S.useDefaultExcludes:!0,fileEncoding:S.encoding,maxResults:S.maxResults,previewOptions:V,afterContext:S.afterContext,beforeContext:S.beforeContext,includePattern:F,excludePattern:ce},fe=!1;if(this._activeSearchCallbacks[K]=ie=>{if(fe)return;const Ee=m.URI.revive(ie.resource);ie.results.forEach(be=>{(0,u.resultIsMatch)(be)?z({uri:Ee,preview:{text:be.preview.text,matches:(0,s.mapArrayOrNot)(be.preview.matches,te=>new n.Range(te.startLineNumber,te.startColumn,te.endLineNumber,te.endColumn))},ranges:(0,s.mapArrayOrNot)(be.ranges,te=>new n.Range(te.startLineNumber,te.startColumn,te.endLineNumber,te.endColumn))}):z({uri:Ee,text:be.text,lineNumber:be.lineNumber})})},N.isCancellationRequested)return{};try{const ie=await this._proxy.$startTextSearch(M,(0,y.withUndefinedAsNull)(ne),re,K,N);return delete this._activeSearchCallbacks[K],ie||{}}catch(ie){throw delete this._activeSearchCallbacks[K],ie}}$handleTextSearchResult(M,S){this._activeSearchCallbacks[S]?.(M)}saveAll(M){return this._proxy.$saveAll(M)}resolveProxy(M){return this._proxy.$resolveProxy(M)}get trusted(){return this._trusted}requestWorkspaceTrust(M){return this._proxy.$requestWorkspaceTrust(M)}$onDidGrantWorkspaceTrust(){this._trusted||(this._trusted=!0,this._onDidGrantWorkspaceTrust.fire())}};D=ze([xe(0,l.IExtHostRpcService),xe(1,P.IExtHostInitDataService),xe(2,w.IExtHostFileSystemInfo),xe(3,h.ILogService)],D),e.ExtHostWorkspace=D,e.IExtHostWorkspace=(0,f.createDecorator)("IExtHostWorkspace");function U(W){let M,S;return W&&(typeof W=="string"?M=W:(M=W.pattern,S=m.URI.revive(W.baseUri))),{includePattern:M,folder:S}}}),define(ye[32],Ce([1,0,26,4,31,5,6,151,83,10,13,3,15,14,2]),function(ee,e,s,p,b,L,C,T,E,A,R,y,m,I,f){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.IExtHostConfiguration=e.ExtHostConfigProvider=e.ExtHostConfiguration=void 0;function h(u,i){if(i){const o=i.split(".");let r=u;for(let t=0;r&&t<o.length;t++)r=r[o[t]];return r}}function d(u){return u instanceof f.URI}function a(u){return u&&u.uri instanceof f.URI&&u.languageId&&typeof u.languageId=="string"}function w(u){return u&&!u.uri&&u.languageId&&typeof u.languageId=="string"}function P(u){return u&&u.uri instanceof f.URI&&(!u.name||typeof u.name=="string")&&(!u.index||typeof u.index=="number")}function l(u){if(d(u))return{resource:u};if(a(u))return{resource:u.uri,overrideIdentifier:u.languageId};if(w(u))return{overrideIdentifier:u.languageId};if(P(u))return{resource:u.uri};if(u===null)return{resource:null}}let _=class{constructor(i,o,r){this._proxy=i.getProxy(L.MainContext.MainThreadConfiguration),this._extHostWorkspace=o,this._logService=r,this._barrier=new R.Barrier,this._actual=null}getConfigProvider(){return this._barrier.wait().then(i=>this._actual)}$initializeConfiguration(i){this._actual=new n(this._proxy,this._extHostWorkspace,i,this._logService),this._barrier.open()}$acceptConfigurationChanged(i,o){this.getConfigProvider().then(r=>r.$acceptConfigurationChanged(i,o))}};_=ze([xe(0,m.IExtHostRpcService),xe(1,b.IExtHostWorkspace),xe(2,I.ILogService)],_),e.ExtHostConfiguration=_;class n{constructor(i,o,r,t){this._onDidChangeConfiguration=new p.Emitter,this._proxy=i,this._logService=t,this._extHostWorkspace=o,this._configuration=T.Configuration.parse(r),this._configurationScopes=this._toMap(r.configurationScopes)}get onDidChangeConfiguration(){return this._onDidChangeConfiguration&&this._onDidChangeConfiguration.event}$acceptConfigurationChanged(i,o){const r={data:this._configuration.toData(),workspace:this._extHostWorkspace.workspace};this._configuration=T.Configuration.parse(i),this._configurationScopes=this._toMap(i.configurationScopes),this._onDidChangeConfiguration.fire(this._toConfigurationChangeEvent(o,r))}getConfiguration(i,o,r){const t=l(o)||{},c=this._toReadonlyValue(i?h(this._configuration.getValue(void 0,t,this._extHostWorkspace.workspace),i):this._configuration.getValue(void 0,t,this._extHostWorkspace.workspace));i&&this._validateConfigurationAccess(i,t,r?.identifier);function v(D){if(D==null)return null;if(typeof D=="boolean")return D?2:5;switch(D){case C.ConfigurationTarget.Global:return 2;case C.ConfigurationTarget.Workspace:return 5;case C.ConfigurationTarget.WorkspaceFolder:return 6}}const g={has(D){return typeof h(c,D)!="undefined"},get:(D,U)=>{this._validateConfigurationAccess(i?`${i}.${D}`:D,t,r?.identifier);let W=h(c,D);if(typeof W=="undefined")W=U;else{let M;const S=(z,$)=>{let N;const K=()=>{M=M||(0,s.deepClone)(c),N=N||h(M,$)};return(0,A.isObject)(z)?new Proxy(z,{get:(V,F)=>{if(typeof F=="string"&&F.toLowerCase()==="tojson")return K(),()=>N;if(M)return N=N||h(M,$),N[F];const ne=V[F];return typeof F=="string"?S(ne,`${$}.${F}`):ne},set:(V,F,ne)=>(K(),N&&(N[F]=ne),!0),deleteProperty:(V,F)=>(K(),N&&delete N[F],!0),defineProperty:(V,F,ne)=>(K(),N&&Object.defineProperty(N,F,ne),!0)}):z};W=S(W,D)}return W},update:(D,U,W,M)=>{D=i?`${i}.${D}`:D;const S=v(W);return U!==void 0?this._proxy.$updateConfigurationOption(S,D,U,t,M):this._proxy.$removeConfigurationOption(S,D,t,M)},inspect:D=>{D=i?`${i}.${D}`:D;const U=(0,s.deepClone)(this._configuration.inspect(D,t,this._extHostWorkspace.workspace));if(U)return{key:D,defaultValue:U.policy?.value??U.default?.value,globalValue:U.user?.value??U.application?.value,workspaceValue:U.workspace?.value,workspaceFolderValue:U.workspaceFolder?.value,defaultLanguageValue:U.default?.override,globalLanguageValue:U.user?.override??U.application?.override,workspaceLanguageValue:U.workspace?.override,workspaceFolderLanguageValue:U.workspaceFolder?.override,languageIds:U.overrideIdentifiers}}};return typeof c=="object"&&(0,s.mixin)(g,c,!1),Object.freeze(g)}_toReadonlyValue(i){const o=r=>(0,A.isObject)(r)?new Proxy(r,{get:(t,c)=>o(t[c]),set:(t,c,v)=>{throw new Error(`TypeError: Cannot assign to read only property '${String(c)}' of object`)},deleteProperty:(t,c)=>{throw new Error(`TypeError: Cannot delete read only property '${String(c)}' of object`)},defineProperty:(t,c)=>{throw new Error(`TypeError: Cannot define property '${String(c)}' for a readonly object`)},setPrototypeOf:t=>{throw new Error("TypeError: Cannot set prototype for a readonly object")},isExtensible:()=>!1,preventExtensions:()=>!0}):r;return o(i)}_validateConfigurationAccess(i,o,r){const t=E.OVERRIDE_PROPERTY_REGEX.test(i)?4:this._configurationScopes.get(i),c=r?`[${r.value}] `:"";if(t===4){typeof o?.resource=="undefined"&&this._logService.warn(`${c}Accessing a resource scoped configuration without providing a resource is not expected. To get the effective value for '${i}', provide the URI of a resource or 'null' for any resource.`);return}if(t===3){o?.resource&&this._logService.warn(`${c}Accessing a window scoped configuration for a resource is not expected. To associate '${i}' to a resource, define its scope to 'resource' in configuration contributions in 'package.json'.`);return}}_toConfigurationChangeEvent(i,o){const r=new T.ConfigurationChangeEvent(i,o,this._configuration,this._extHostWorkspace.workspace);return Object.freeze({affectsConfiguration:(t,c)=>r.affectsConfiguration(t,l(c))})}_toMap(i){return i.reduce((o,r)=>(o.set(r[0],r[1]),o),new Map)}}e.ExtHostConfigProvider=n,e.IExtHostConfiguration=(0,y.createDecorator)("IExtHostConfiguration")});var Je=this&&this.__classPrivateFieldSet||function(ee,e,s,p,b){if(p==="m")throw new TypeError("Private method is not writable");if(p==="a"&&!b)throw new TypeError("Private accessor was defined without a setter");if(typeof e=="function"?ee!==e||!b:!e.has(ee))throw new TypeError("Cannot write private member to an object whose class did not declare it");return p==="a"?b.call(ee,s):b?b.value=s:e.set(ee,s),s},Ae=this&&this.__classPrivateFieldGet||function(ee,e,s,p){if(s==="a"&&!p)throw new TypeError("Private accessor was defined without a getter");if(typeof e=="function"?ee!==e||!p:!e.has(ee))throw new TypeError("Cannot read private member from an object whose class did not declare it");return s==="m"?p:s==="a"?p.call(ee):p?p.value:e.get(ee)};define(ye[100],Ce([1,0,2,13,4,5,6,31,49,32,20,52,15,28,3,12,23,14,68,184,11]),function(ee,e,s,p,b,L,C,T,E,A,R,y,m,I,f,h,d,a,w,P,l){"use strict";var _;Object.defineProperty(e,"__esModule",{value:!0}),e.IExtHostTask=e.WorkerExtHostTask=e.ExtHostTaskBase=e.TaskExecutionDTO=e.TaskFilterDTO=e.TaskDTO=e.TaskGroupDTO=e.TaskHandleDTO=e.CustomExecutionDTO=e.ShellExecutionDTO=e.ShellExecutionOptionsDTO=e.ProcessExecutionDTO=e.ProcessExecutionOptionsDTO=e.TaskPresentationOptionsDTO=e.TaskDefinitionDTO=void 0;var n;(function($){function N(V){if(V!=null)return V}$.from=N;function K(V){if(V!=null)return V}$.to=K})(n=e.TaskDefinitionDTO||(e.TaskDefinitionDTO={}));var u;(function($){function N(V){if(V!=null)return V}$.from=N;function K(V){if(V!=null)return V}$.to=K})(u=e.TaskPresentationOptionsDTO||(e.TaskPresentationOptionsDTO={}));var i;(function($){function N(V){if(V!=null)return V}$.from=N;function K(V){if(V!=null)return V}$.to=K})(i=e.ProcessExecutionOptionsDTO||(e.ProcessExecutionOptionsDTO={}));var o;(function($){function N(F){if(F){const ne=F;return ne&&!!ne.process}else return!1}$.is=N;function K(F){if(F==null)return;const ne={process:F.process,args:F.args};return F.options&&(ne.options=i.from(F.options)),ne}$.from=K;function V(F){if(F!=null)return new C.ProcessExecution(F.process,F.args,F.options)}$.to=V})(o=e.ProcessExecutionDTO||(e.ProcessExecutionDTO={}));var r;(function($){function N(V){if(V!=null)return V}$.from=N;function K(V){if(V!=null)return V}$.to=K})(r=e.ShellExecutionOptionsDTO||(e.ShellExecutionOptionsDTO={}));var t;(function($){function N(F){if(F){const ne=F;return ne&&(!!ne.commandLine||!!ne.command)}else return!1}$.is=N;function K(F){if(F==null)return;const ne={};return F.commandLine!==void 0?ne.commandLine=F.commandLine:(ne.command=F.command,ne.args=F.args),F.options&&(ne.options=r.from(F.options)),ne}$.from=K;function V(F){if(!(F==null||F.command===void 0&&F.commandLine===void 0))return F.commandLine?new C.ShellExecution(F.commandLine,F.options):new C.ShellExecution(F.command,F.args?F.args:[],F.options)}$.to=V})(t=e.ShellExecutionDTO||(e.ShellExecutionDTO={}));var c;(function($){function N(F){if(F){const ne=F;return ne&&ne.customExecution==="customExecution"}else return!1}$.is=N;function K(F){return{customExecution:"customExecution"}}$.from=K;function V(F,ne){return ne.get(F)}$.to=V})(c=e.CustomExecutionDTO||(e.CustomExecutionDTO={}));var v;(function($){function N(K,V){let F;return K.scope!==void 0&&typeof K.scope!="number"?F=K.scope.uri:K.scope!==void 0&&typeof K.scope=="number"&&(K.scope===C.TaskScope.Workspace&&V&&V.workspaceFile?F=V.workspaceFile:F=P.USER_TASKS_GROUP_KEY),{id:K._id,workspaceFolder:F}}$.from=N})(v=e.TaskHandleDTO||(e.TaskHandleDTO={}));var g;(function($){function N(K){if(K!=null)return{_id:K.id,isDefault:K.isDefault}}$.from=N})(g=e.TaskGroupDTO||(e.TaskGroupDTO={}));var D;(function($){function N(F,ne){if(F==null)return[];const ce=[];for(const re of F){const fe=K(re,ne);fe&&ce.push(fe)}return ce}$.fromMany=N;function K(F,ne){if(F==null)return;let ce;F.execution instanceof C.ProcessExecution?ce=o.from(F.execution):F.execution instanceof C.ShellExecution?ce=t.from(F.execution):F.execution&&F.execution instanceof C.CustomExecution&&(ce=c.from(F.execution));const re=n.from(F.definition);let fe;return F.scope?typeof F.scope=="number"?fe=F.scope:fe=F.scope.uri:fe=C.TaskScope.Workspace,!re||!fe?void 0:{_id:F._id,definition:re,name:F.name,source:{extensionId:ne.identifier.value,label:F.source,scope:fe},execution:ce,isBackground:F.isBackground,group:g.from(F.group),presentationOptions:u.from(F.presentationOptions),problemMatchers:F.problemMatchers,hasDefinedMatchers:F.hasDefinedMatchers,runOptions:F.runOptions?F.runOptions:{reevaluateOnRerun:!0},detail:F.detail}}$.from=K;async function V(F,ne,ce){if(F==null)return;let re;o.is(F.execution)?re=o.to(F.execution):t.is(F.execution)?re=t.to(F.execution):c.is(F.execution)&&(re=c.to(F._id,ce));const fe=n.to(F.definition);let ie;if(F.source&&(F.source.scope!==void 0?typeof F.source.scope=="number"?ie=F.source.scope:ie=await ne.resolveWorkspaceFolder(s.URI.revive(F.source.scope)):ie=C.TaskScope.Workspace),!fe||!ie)return;const Ee=new C.Task(fe,ie,F.name,F.source.label,re,F.problemMatchers);return F.isBackground!==void 0&&(Ee.isBackground=F.isBackground),F.group!==void 0&&(Ee.group=C.TaskGroup.from(F.group._id),Ee.group&&F.group.isDefault&&(Ee.group=new C.TaskGroup(Ee.group.id,Ee.group.label),F.group.isDefault===!0&&(Ee.group.isDefault=F.group.isDefault))),F.presentationOptions&&(Ee.presentationOptions=u.to(F.presentationOptions)),F._id&&(Ee._id=F._id),F.detail&&(Ee.detail=F.detail),Ee}$.to=V})(D=e.TaskDTO||(e.TaskDTO={}));var U;(function($){function N(V){return V}$.from=N;function K(V){if(!!V)return Object.assign(Object.create(null),V)}$.to=K})(U=e.TaskFilterDTO||(e.TaskFilterDTO={}));class W{constructor(N,K,V){this._id=K,this._task=V,_.set(this,void 0),Je(this,_,N,"f")}get task(){return this._task}terminate(){Ae(this,_,"f").terminateTask(this)}fireDidStartProcess(N){}fireDidEndProcess(N){}}_=new WeakMap;var M;(function($){function N(K){return{id:K._id,task:void 0}}$.from=N})(M=e.TaskExecutionDTO||(e.TaskExecutionDTO={}));let S=class{constructor(N,K,V,F,ne,ce,re,fe){this._onDidExecuteTask=new b.Emitter,this._onDidTerminateTask=new b.Emitter,this._onDidTaskProcessStarted=new b.Emitter,this._onDidTaskProcessEnded=new b.Emitter,this._proxy=N.getProxy(L.MainContext.MainThreadTask),this._workspaceProvider=V,this._editorService=F,this._configurationService=ne,this._terminalService=ce,this._handleCounter=0,this._handlers=new Map,this._taskExecutions=new Map,this._taskExecutionPromises=new Map,this._providedCustomExecutions2=new Map,this._notProvidedCustomExecutions=new Set,this._activeCustomExecutions2=new Map,this._logService=re,this._deprecationService=fe,this._proxy.$registerSupportedExecutions(!0)}registerTaskProvider(N,K,V){if(!V)return new C.Disposable(()=>{});const F=this.nextHandle();return this._handlers.set(F,{type:K,provider:V,extension:N}),this._proxy.$registerTaskProvider(F,K),new C.Disposable(()=>{this._handlers.delete(F),this._proxy.$unregisterTaskProvider(F)})}registerTaskSystem(N,K){this._proxy.$registerTaskSystem(N,K)}fetchTasks(N){return this._proxy.$fetchTasks(U.from(N)).then(async K=>{const V=[];for(const F of K){const ne=await D.to(F,this._workspaceProvider,this._providedCustomExecutions2);ne&&V.push(ne)}return V})}get taskExecutions(){const N=[];return this._taskExecutions.forEach(K=>N.push(K)),N}terminateTask(N){if(!(N instanceof W))throw new Error("No valid task execution provided");return this._proxy.$terminateTask(N._id)}get onDidStartTask(){return this._onDidExecuteTask.event}async $onDidStartTask(N,K,V){const F=this._providedCustomExecutions2.get(N.id);F&&(this._activeCustomExecutions2.set(N.id,F),this._terminalService.attachPtyToTerminal(K,await F.callback(V))),this._lastStartedTask=N.id,this._onDidExecuteTask.fire({execution:await this.getTaskExecution(N)})}get onDidEndTask(){return this._onDidTerminateTask.event}async $OnDidEndTask(N){const K=await this.getTaskExecution(N);this._taskExecutionPromises.delete(N.id),this._taskExecutions.delete(N.id),this.customExecutionComplete(N),this._onDidTerminateTask.fire({execution:K})}get onDidStartTaskProcess(){return this._onDidTaskProcessStarted.event}async $onDidStartTaskProcess(N){const K=await this.getTaskExecution(N.id);this._onDidTaskProcessStarted.fire({execution:K,processId:N.processId})}get onDidEndTaskProcess(){return this._onDidTaskProcessEnded.event}async $onDidEndTaskProcess(N){const K=await this.getTaskExecution(N.id);this._onDidTaskProcessEnded.fire({execution:K,exitCode:N.exitCode})}$provideTasks(N,K){const V=this._handlers.get(N);if(!V)return Promise.reject(new Error("no handler found"));const F=[],ne=(0,p.asPromise)(()=>V.provider.provideTasks(R.CancellationToken.None)).then(ce=>this.provideTasksInternal(K,F,V,ce));return new Promise(ce=>{ne.then(re=>{Promise.all(F).then(()=>{ce(re)})})})}async $resolveTask(N,K){const V=this._handlers.get(N);if(!V)return Promise.reject(new Error("no handler found"));if(K.definition.type!==V.type)throw new Error(`Unexpected: Task of type [${K.definition.type}] cannot be resolved by provider of type [${V.type}].`);const F=await D.to(K,this._workspaceProvider,this._providedCustomExecutions2);if(!F)throw new Error("Unexpected: Task cannot be resolved.");const ne=await V.provider.resolveTask(F,R.CancellationToken.None);if(!ne)return;this.checkDeprecation(ne,V);const ce=D.from(ne,V.extension);if(!ce)throw new Error("Unexpected: Task cannot be resolved.");if(ne.definition!==F.definition)throw new Error("Unexpected: The resolved task definition must be the same object as the original task definition. The task definition cannot be changed.");return c.is(ce.execution)&&await this.addCustomExecution(ce,ne,!0),await this.resolveTaskInternal(ce)}nextHandle(){return this._handleCounter++}async addCustomExecution(N,K,V){const F=await this._proxy.$createTaskId(N);!V&&!this._providedCustomExecutions2.has(F)&&(this._notProvidedCustomExecutions.add(F),this._activeCustomExecutions2.set(F,K.execution)),this._providedCustomExecutions2.set(F,K.execution)}async getTaskExecution(N,K){if(typeof N=="string"){const ne=this._taskExecutionPromises.get(N);if(!ne)throw new Error("Unexpected: The specified task is missing an execution");return ne}const V=this._taskExecutionPromises.get(N.id);if(V)return V;const F=new Promise((ne,ce)=>{function re(fe,ie,Ee){Ee?ne(new W(fe,ie.id,Ee)):ce("Unexpected: Task does not exist.")}K?re(this,N,K):D.to(N.task,this._workspaceProvider,this._providedCustomExecutions2).then(fe=>re(this,N,fe))});return this._taskExecutionPromises.set(N.id,F),F.then(ne=>(this._taskExecutions.set(N.id,ne),ne),ne=>Promise.reject(ne))}checkDeprecation(N,K){N._deprecated&&this._deprecationService.report("Task.constructor",K.extension,"Use the Task constructor that takes a `scope` instead.")}customExecutionComplete(N){this._activeCustomExecutions2.get(N.id)&&this._activeCustomExecutions2.delete(N.id),this._notProvidedCustomExecutions.has(N.id)&&this._lastStartedTask!==N.id&&(this._providedCustomExecutions2.delete(N.id),this._notProvidedCustomExecutions.delete(N.id));const V=this._notProvidedCustomExecutions.values();let F=V.next();for(;!F.done;)!this._activeCustomExecutions2.has(F.value)&&this._lastStartedTask!==F.value&&(this._providedCustomExecutions2.delete(F.value),this._notProvidedCustomExecutions.delete(F.value)),F=V.next()}};S=ze([xe(0,m.IExtHostRpcService),xe(1,I.IExtHostInitDataService),xe(2,T.IExtHostWorkspace),xe(3,E.IExtHostDocumentsAndEditors),xe(4,A.IExtHostConfiguration),xe(5,y.IExtHostTerminalService),xe(6,a.ILogService),xe(7,w.IExtHostApiDeprecationService)],S),e.ExtHostTaskBase=S;let z=class extends S{constructor(N,K,V,F,ne,ce,re,fe){super(N,K,V,F,ne,ce,re,fe);this.registerTaskSystem(h.Schemas.vscodeRemote,{scheme:h.Schemas.vscodeRemote,authority:"",platform:d.PlatformToString(0)})}async executeTask(N,K){if(!K.execution)throw new Error("Tasks to execute must include an execution");const V=D.from(K,N);if(V===void 0)throw new Error("Task is not valid");if(c.is(V.execution))await this.addCustomExecution(V,K,!1);else throw new l.NotSupportedError;const F=await this.getTaskExecution(await this._proxy.$getTaskExecution(V),K);return this._proxy.$executeTask(V).catch(ne=>{throw new Error(ne)}),F}provideTasksInternal(N,K,V,F){const ne=[];if(F)for(const ce of F){this.checkDeprecation(ce,V),(!ce.definition||!N[ce.definition.type])&&this._logService.warn(`The task [${ce.source}, ${ce.name}] uses an undefined task type. The task will be ignored in the future.`);const re=D.from(ce,V.extension);re&&c.is(re.execution)?(ne.push(re),K.push(this.addCustomExecution(re,ce,!0))):this._logService.warn("Only custom execution tasks supported.")}return{tasks:ne,extension:V.extension}}async resolveTaskInternal(N){if(c.is(N.execution))return N;this._logService.warn("Only custom execution tasks supported.")}async $resolveVariables(N,K){return{process:void 0,variables:Object.create(null)}}async $jsonTasksSupported(){return!1}async $findExecutable(N,K,V){}};z=ze([xe(0,m.IExtHostRpcService),xe(1,I.IExtHostInitDataService),xe(2,T.IExtHostWorkspace),xe(3,E.IExtHostDocumentsAndEditors),xe(4,A.IExtHostConfiguration),xe(5,y.IExtHostTerminalService),xe(6,a.ILogService),xe(7,w.IExtHostApiDeprecationService)],z),e.WorkerExtHostTask=z,e.IExtHostTask=(0,f.createDecorator)("IExtHostTask")}),define(ye[226],Ce([1,0,19,20,44,34,21,202,41]),function(ee,e,s,p,b,L,C,T,E){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.FileSearchManager=void 0;class A{constructor(m,I,f){this.config=m,this.provider=I,this.sessionToken=f,this.isLimitHit=!1,this.resultCount=0,this.isCanceled=!1,this.filePattern=m.filePattern,this.includePattern=m.includePattern&&L.parse(m.includePattern),this.maxResults=m.maxResults||void 0,this.exists=m.exists,this.activeCancellationTokens=new Set,this.globalExcludePattern=m.excludePattern&&L.parse(m.excludePattern)}cancel(){this.isCanceled=!0,this.activeCancellationTokens.forEach(m=>m.cancel()),this.activeCancellationTokens=new Set}search(m){const I=this.config.folderQueries||[];return new Promise((f,h)=>{const d=a=>{this.resultCount++,m(a)};if(this.isCanceled)return f({limitHit:this.isLimitHit});this.config.extraFileResources&&this.config.extraFileResources.forEach(a=>{const w=a.toString(),P=s.basename(w);this.globalExcludePattern&&this.globalExcludePattern(w,P)||this.matchFile(d,{base:a,basename:P})}),Promise.all(I.map(a=>this.searchInFolder(a,d))).then(a=>{f({limitHit:this.isLimitHit,stats:a[0]||void 0})},a=>{h(new Error((0,b.toErrorMessage)(a)))})})}async searchInFolder(m,I){const f=new p.CancellationTokenSource,h=this.getSearchOptionsForFolder(m),d=this.initDirectoryTree(),a=new E.QueryGlobTester(this.config,m),w=!a.hasSiblingExcludeClauses();let P;try{this.activeCancellationTokens.add(f),P=T.StopWatch.create();const l=await this.provider.provideFileSearchResults({pattern:this.config.filePattern||""},h,f.token),_=P.elapsed(),n=T.StopWatch.create();return this.isCanceled&&!this.isLimitHit||(l&&l.forEach(u=>{const i=s.posix.relative(m.folder.path,u.path);if(w){const o=s.basename(u.path);this.matchFile(I,{base:m.folder,relativePath:i,basename:o});return}this.addDirectoryEntries(d,m.folder,i,I)}),this.isCanceled&&!this.isLimitHit)?null:(this.matchDirectoryTree(d,a,I),{providerTime:_,postProcessTime:n.elapsed()})}finally{f.dispose(),this.activeCancellationTokens.delete(f)}}getSearchOptionsForFolder(m){const I=(0,E.resolvePatternsForProvider)(this.config.includePattern,m.includePattern),f=(0,E.resolvePatternsForProvider)(this.config.excludePattern,m.excludePattern);return{folder:m.folder,excludes:f,includes:I,useIgnoreFiles:!m.disregardIgnoreFiles,useGlobalIgnoreFiles:!m.disregardGlobalIgnoreFiles,useParentIgnoreFiles:!m.disregardParentIgnoreFiles,followSymlinks:!m.ignoreSymlinks,maxResults:this.config.maxResults,session:this.sessionToken}}initDirectoryTree(){const m={rootEntries:[],pathToEntries:Object.create(null)};return m.pathToEntries["."]=m.rootEntries,m}addDirectoryEntries({pathToEntries:m},I,f,h){if(f===this.filePattern){const a=s.basename(this.filePattern);this.matchFile(h,{base:I,relativePath:this.filePattern,basename:a})}function d(a){const w=s.basename(a),P=s.dirname(a);let l=m[P];l||(l=m[P]=[],d(P)),l.push({base:I,relativePath:a,basename:w})}d(f)}matchDirectoryTree({rootEntries:m,pathToEntries:I},f,h){const d=this,a=this.filePattern;function w(P){const l=(0,E.hasSiblingFn)(()=>P.map(_=>_.basename));for(let _=0,n=P.length;_<n;_++){const u=P[_],{relativePath:i,basename:o}=u;if(f.matchesExcludesSync(i,o,a!==o?l:void 0))continue;const r=I[i];if(r)w(r);else{if(i===a)continue;d.matchFile(h,u)}if(d.isLimitHit)break}}w(m)}matchFile(m,I){(!this.includePattern||I.relativePath&&this.includePattern(I.relativePath,I.basename))&&((this.exists||this.maxResults&&this.resultCount>=this.maxResults)&&(this.isLimitHit=!0,this.cancel()),this.isLimitHit||m(I))}}class R{constructor(){this.sessions=new Map}fileSearch(m,I,f,h){const d=this.getSessionTokenSource(m.cacheKey),a=new A(m,I,d&&d.token);let w=0;const P=l=>{w+=l.length,f(l.map(_=>this.rawMatchToSearchItem(_)))};return this.doSearch(a,R.BATCH_SIZE,P,h).then(l=>({limitHit:l.limitHit,stats:{fromCache:!1,type:"fileSearchProvider",resultCount:w,detailStats:l.stats}}))}clearCache(m){const I=this.getSessionTokenSource(m);I&&I.cancel()}getSessionTokenSource(m){if(!!m)return this.sessions.has(m)||this.sessions.set(m,new p.CancellationTokenSource),this.sessions.get(m)}rawMatchToSearchItem(m){return m.relativePath?{resource:C.joinPath(m.base,m.relativePath)}:{resource:m.base}}doSearch(m,I,f,h){h.onCancellationRequested(()=>{m.cancel()});const d=w=>{w&&(a.push(w),I>0&&a.length>=I&&(f(a),a=[]))};let a=[];return m.search(d).then(w=>(a.length&&f(a),w),w=>(a.length&&f(a),Promise.reject(w)))}}e.FileSearchManager=R,R.BATCH_SIZE=512}),define(ye[227],Ce([1,0,16,72,34,76,25,12,19,21,9,10,2,244,142,57,14,45,90,225,41]),function(ee,e,s,p,b,L,C,T,E,A,R,y,m,I,f,h,d,a,w,P,l){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.resolveResourcesForSearchIncludes=e.QueryBuilder=void 0;let _=class{constructor(g,D,U,W,M){this.configurationService=g,this.workspaceContextService=D,this.editorGroupsService=U,this.logService=W,this.pathService=M}text(g,D,U={}){g=this.getContentPattern(g,U);const W=this.configurationService.getValue(),M=D&&D.some(z=>!this.configurationService.getValue({resource:z}).search.useRipgrep);return{...this.commonQuery(D?.map(a.toWorkspaceFolder),U),type:2,contentPattern:g,previewOptions:U.previewOptions,maxFileSize:U.maxFileSize,usePCRE2:W.search.usePCRE2||M||!1,beforeContext:U.beforeContext,afterContext:U.afterContext,userDisabledExcludesAndIgnoreFiles:U.disregardExcludeSettings&&U.disregardIgnoreFiles}}getContentPattern(g,D){const U=this.configurationService.getValue();g.isRegExp&&(g.pattern=g.pattern.replace(/\r?\n/g,"\\n"));const W={...g,wordSeparators:U.editor.wordSeparators};return this.isCaseSensitive(g,D)&&(W.isCaseSensitive=!0),this.isMultiline(g)&&(W.isMultiline=!0),W}file(g,D={}){return{...this.commonQuery(g,D),type:1,filePattern:D.filePattern?D.filePattern.trim():D.filePattern,exists:D.exists,sortByScore:D.sortByScore,cacheKey:D.cacheKey}}handleIncludeExclude(g,D){return g?(g=Array.isArray(g)?g.map(r):r(g),D?this.parseSearchPaths(g):{pattern:u(...Array.isArray(g)?g:[g])}):{}}commonQuery(g=[],D={}){const U=this.handleIncludeExclude(D.includePattern,D.expandPatterns),W=this.handleIncludeExclude(D.excludePattern,D.expandPatterns),M=g.length>1,S=(U.searchPaths&&U.searchPaths.length?U.searchPaths.map(N=>this.getFolderQueryForSearchPath(N,D,W)):g.map(N=>this.getFolderQueryForRoot(N,D,W,M))).filter(N=>!!N),z={_reason:D._reason,folderQueries:S,usingSearchPaths:!!(U.searchPaths&&U.searchPaths.length),extraFileResources:D.extraFileResources,excludePattern:W.pattern,includePattern:U.pattern,onlyOpenEditors:D.onlyOpenEditors,maxResults:D.maxResults};if(D.onlyOpenEditors){const N=s.coalesce(s.flatten(this.editorGroupsService.groups.map(F=>F.editors.map(ne=>ne.resource))));this.logService.trace("QueryBuilder#commonQuery - openEditor URIs",JSON.stringify(N));const K=N.filter(F=>(0,l.pathIncludedInQuery)(z,F.fsPath)),V=this.commonQueryFromFileList(K);return this.logService.trace("QueryBuilder#commonQuery - openEditor Query",JSON.stringify(V)),{...z,...V}}const $=D.extraFileResources&&D.extraFileResources.filter(N=>(0,l.pathIncludedInQuery)(z,N.fsPath));return z.extraFileResources=$&&$.length?$:void 0,z}commonQueryFromFileList(g){const D=[],U=new C.ResourceMap,W={};let M=!1;return g.forEach(S=>{if(S.scheme===T.Schemas.walkThrough)return;if((0,A.isAbsolutePath)(S)){const $=this.workspaceContextService.getWorkspaceFolder(S)?.uri??S.with({path:E.dirname(S.fsPath)});let N=U.get($);N||(M=!0,N={folder:$,includePattern:{}},D.push(N),U.set($,N));const K=E.relative($.fsPath,S.fsPath);(0,y.assertIsDefined)(N.includePattern)[K.replace(/\\/g,"/")]=!0}else S.fsPath&&(M=!0,W[S.fsPath]=!0)}),{folderQueries:D,includePattern:W,usingSearchPaths:!0,excludePattern:M?void 0:{"**/*":!0}}}isCaseSensitive(g,D){if(D.isSmartCase){if(g.isRegExp){if(R.containsUppercaseCharacter(g.pattern,!0))return!0}else if(R.containsUppercaseCharacter(g.pattern))return!0}return!!g.isCaseSensitive}isMultiline(g){return g.isMultiline||g.isRegExp&&(0,I.isMultilineRegexSource)(g.pattern)||g.pattern.indexOf(`
`)>=0?!0:!!g.isMultiline}parseSearchPaths(g){const D=V=>E.isAbsolute(V)||/^\.\.?([\/\\]|$)/.test(V),W=(Array.isArray(g)?g:i(g)).map(V=>{const F=this.pathService.resolvedUserHome;return F?(0,L.untildify)(V,F.scheme===T.Schemas.file?F.fsPath:F.path):V}),M=p.groupBy(W,V=>D(V)?"searchPaths":"exprSegments"),S=(M.exprSegments||[]).map(V=>R.rtrim(V,"/")).map(V=>R.rtrim(V,"\\")).map(V=>(V[0]==="."&&(V="*"+V),o(V))),z={},$=this.expandSearchPathPatterns(M.searchPaths||[]);$&&$.length&&(z.searchPaths=$);const N=s.flatten(S),K=u(...N);return K&&(z.pattern=K),z}getExcludesForFolder(g,D){return D.disregardExcludeSettings?void 0:(0,l.getExcludes)(g,!D.disregardSearchExcludeSettings)}expandSearchPathPatterns(g){if(!g||!g.length)return[];const D=s.flatten(g.map(W=>{let{pathPortion:M,globPortion:S}=n(W);S&&(S=t(S));const z=this.expandOneSearchPath(M);return s.flatten(z.map($=>this.resolveOneSearchPathPattern($,S)))})),U=new Map;return D.forEach(W=>{const M=W.searchPath.toString(),S=U.get(M);S?W.pattern&&(S.pattern=S.pattern||{},S.pattern[W.pattern]=!0):U.set(M,{searchPath:W.searchPath,pattern:W.pattern?u(W.pattern):void 0})}),Array.from(U.values())}expandOneSearchPath(g){if(E.isAbsolute(g)){const D=this.workspaceContextService.getWorkspace().folders;return D[0]&&D[0].uri.scheme!==T.Schemas.file?[{searchPath:D[0].uri.with({path:g})}]:[{searchPath:m.URI.file(E.normalize(g))}]}if(this.workspaceContextService.getWorkbenchState()===2){const D=this.workspaceContextService.getWorkspace().folders[0].uri;if(g=r(g),g.startsWith("../")||g===".."){const W=E.posix.resolve(D.path,g);return[{searchPath:D.with({path:W})}]}const U=t(g);return[{searchPath:D,pattern:U}]}else{if(g==="./"||g===".\\")return[];{const D=g.replace(/^\.[\/\\]/,""),W=this.workspaceContextService.getWorkspace().folders.map(M=>{const S=D.match(new RegExp(`^${R.escapeRegExpCharacters(M.name)}(?:/(.*)|$)`));return S?{match:S,folder:M}:null}).filter(y.isDefined);if(W.length)return W.map(M=>{const S=M.match[1];return{searchPath:M.folder.uri,pattern:S&&t(S)}});{const M=g.match(/\.[\/\\](.+)[\/\\]?/),S=M?M[1]:g,z=f.localize(0,null,S);throw new Error(z)}}}}resolveOneSearchPathPattern(g,D){const U=g.pattern&&D?`${g.pattern}/${D}`:g.pattern||D,W=[{searchPath:g.searchPath,pattern:U}];return U&&!U.endsWith("**")&&W.push({searchPath:g.searchPath,pattern:U+"/**"}),W}getFolderQueryForSearchPath(g,D,U){const W=this.getFolderQueryForRoot((0,a.toWorkspaceFolder)(g.searchPath),D,U,!1);return W?{...W,includePattern:g.pattern}:null}getFolderQueryForRoot(g,D,U,W){let M;const S=m.URI.isUri(g)?g:g.uri;if(U.searchPaths){const V=U.searchPaths.filter(F=>(0,A.isEqual)(F.searchPath,S))[0];if(V&&!V.pattern)return null;V&&(M=V.pattern)}const z=this.configurationService.getValue({resource:S}),N={...this.getExcludesForFolder(z,D)||{},...M||{}},K=m.URI.isUri(g)?(0,A.basename)(g):g.name;return{folder:S,folderName:W?K:void 0,excludePattern:Object.keys(N).length>0?N:void 0,fileEncoding:z.files&&z.files.encoding,disregardIgnoreFiles:typeof D.disregardIgnoreFiles=="boolean"?D.disregardIgnoreFiles:!z.search.useIgnoreFiles,disregardGlobalIgnoreFiles:typeof D.disregardGlobalIgnoreFiles=="boolean"?D.disregardGlobalIgnoreFiles:!z.search.useGlobalIgnoreFiles,disregardParentIgnoreFiles:typeof D.disregardParentIgnoreFiles=="boolean"?D.disregardParentIgnoreFiles:!z.search.useParentIgnoreFiles,ignoreSymlinks:typeof D.ignoreSymlinks=="boolean"?D.ignoreSymlinks:!z.search.followSymlinks}}};_=ze([xe(0,h.IConfigurationService),xe(1,a.IWorkspaceContextService),xe(2,w.IEditorGroupsService),xe(3,d.ILogService),xe(4,P.IPathService)],_),e.QueryBuilder=_;function n(v){const g=v.match(/[\*\{\}\(\)\[\]\?]/);if(g){const D=g.index,U=v.substr(0,D).match(/[/|\\][^/\\]*$/);if(U){let W=v.substr(0,U.index);return W.match(/[/\\]/)||(W+="/"),{pathPortion:W,globPortion:v.substr((U.index||0)+1)}}}return{pathPortion:v}}function u(...v){return v.length?v.reduce((g,D)=>(g[D]=!0,g),Object.create(null)):void 0}function i(v){return b.splitGlobAware(v,",").map(g=>g.trim()).filter(g=>!!g.length)}function o(v){return[`**/${v}/**`,`**/${v}`].map(D=>D.replace(/\*\*\/\*\*/g,"**"))}function r(v){return v.replace(/\\/g,"/")}function t(v){return r(v).replace(/^\.\//,"").replace(/\/+$/g,"")}function c(v,g){v=s.distinct(v,W=>W.toString());const D=[],U=g.getWorkspace();return v&&v.forEach(W=>{let M;if(g.getWorkbenchState()===2)M=(0,A.relativePath)(U.folders[0].uri,W),M&&M!=="."&&(M="./"+M);else{const S=g.getWorkspaceFolder(W);if(S){const z=S.name;if(U.folders.filter(N=>N.name===z).length===1){const N=(0,A.relativePath)(S.uri,W);N===""?M=`./${S.name}`:M=`./${S.name}/${N}`}else M=W.fsPath}}M&&D.push(M)}),D}e.resolveResourcesForSearchIncludes=c}),define(ye[228],Ce([1,0,21,2,20,11,3,227,41,45]),function(ee,e,s,p,b,L,C,T,E,A){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.checkGlobFileExists=e.checkActivateWorkspaceContainsExtension=void 0;const R=7e3;function y(h,d){const a=d.activationEvents;if(!a)return Promise.resolve(void 0);const w=[],P=[];for(const o of a)if(/^workspaceContains:/.test(o)){const r=o.substr("workspaceContains:".length);r.indexOf("*")>=0||r.indexOf("?")>=0||h.forceUsingSearch?P.push(r):w.push(r)}if(w.length===0&&P.length===0)return Promise.resolve(void 0);let l;const _=new Promise((o,r)=>{l=o}),n=o=>l({activationEvent:o}),u=Promise.all(w.map(o=>m(h,o,n))).then(()=>{}),i=I(h,d.identifier,P,n);return Promise.all([u,i]).then(()=>{l(void 0)}),_}e.checkActivateWorkspaceContainsExtension=y;async function m(h,d,a){for(const w of h.folders)if(await h.exists(s.joinPath(p.URI.revive(w),d))){a(`workspaceContains:${d}`);return}}async function I(h,d,a,w){if(a.length===0)return Promise.resolve(void 0);const P=new b.CancellationTokenSource,l=h.checkExists(h.folders,a,P.token),_=setTimeout(async()=>{P.cancel(),h.logService.info(`Not activating extension '${d.value}': Timed out while searching for 'workspaceContains' pattern ${a.join(",")}`)},R);let n=!1;try{n=await l}catch(u){L.isCancellationError(u)||L.onUnexpectedError(u)}P.dispose(),clearTimeout(_),n&&w(`workspaceContains:${a.join(",")}`)}function f(h,d,a,w){const P=h.get(C.IInstantiationService),l=h.get(E.ISearchService),n=P.createInstance(T.QueryBuilder).file(d.map(u=>(0,A.toWorkspaceFolder)(p.URI.revive(u))),{_reason:"checkExists",includePattern:a,exists:!0});return l.fileSearch(n,w).then(u=>!!u.limitHit,u=>L.isCancellationError(u)?!1:Promise.reject(u))}e.checkGlobFileExists=f});var Je=this&&this.__classPrivateFieldSet||function(ee,e,s,p,b){if(p==="m")throw new TypeError("Private method is not writable");if(p==="a"&&!b)throw new TypeError("Private accessor was defined without a setter");if(typeof e=="function"?ee!==e||!b:!e.has(ee))throw new TypeError("Cannot write private member to an object whose class did not declare it");return p==="a"?b.call(ee,s):b?b.value=s:e.set(ee,s),s},Ae=this&&this.__classPrivateFieldGet||function(ee,e,s,p){if(s==="a"&&!p)throw new TypeError("Private accessor was defined without a getter");if(typeof e=="function"?ee!==e||!p:!e.has(ee))throw new TypeError("Cannot read private member from an object whose class did not declare it");return s==="m"?p:s==="a"?p.call(ee):p?p.value:e.get(ee)};define(ye[33],Ce([1,0,129,19,71,21,13,7,25,2,14,5,32,179,69,31,24,178,11,27,22,157,6,84,3,28,70,15,58,62,52,4,228,67,159,12]),function(ee,e,s,p,b,L,C,T,E,A,R,y,m,I,f,h,d,a,w,P,l,_,n,u,i,o,r,t,c,v,g,D,U,W,M,S){"use strict";var z,$,N;Object.defineProperty(e,"__esModule",{value:!0}),e.ExtensionPaths=e.Extension=e.IExtHostExtensionService=e.AbstractExtHostExtensionService=e.IHostUtils=void 0,e.IHostUtils=(0,i.createDecorator)("IHostUtils");let K=class ki extends T.Disposable{constructor(ie,Ee,be,te,ve,Re,Fe,$e,Ye,Ie){super();this._onDidChangeRemoteConnectionData=this._register(new D.Emitter),this.onDidChangeRemoteConnectionData=this._onDidChangeRemoteConnectionData.event,this._isTerminating=!1,this._hostUtils=Ee,this._extHostContext=be,this._initData=Fe,this._extHostWorkspace=te,this._extHostConfiguration=ve,this._logService=Re,this._extHostTunnelService=Ye,this._extHostTerminalService=Ie,this._mainThreadWorkspaceProxy=this._extHostContext.getProxy(y.MainContext.MainThreadWorkspace),this._mainThreadTelemetryProxy=this._extHostContext.getProxy(y.MainContext.MainThreadTelemetry),this._mainThreadExtensionsProxy=this._extHostContext.getProxy(y.MainContext.MainThreadExtensionService),this._almostReadyToRunExtensions=new C.Barrier,this._readyToStartExtensionHost=new C.Barrier,this._readyToRunExtensions=new C.Barrier,this._eagerExtensionsActivated=new C.Barrier,this._globalRegistry=new a.ExtensionDescriptionRegistry(this._initData.allExtensions);const Se=(0,d.extensionIdentifiersArrayToSet)(this._initData.myExtensions);this._myRegistry=new a.ExtensionDescriptionRegistry(ne(this._globalRegistry,Se)),this._storage=new f.ExtHostStorage(this._extHostContext),this._secretState=new W.ExtHostSecretState(this._extHostContext),this._storagePath=$e,this._instaService=ie.createChild(new c.ServiceCollection([f.IExtHostStorage,this._storage],[W.IExtHostSecretState,this._secretState]));let Te=[],ae=[];this._initData.remote.isRemote&&(Te=this._initData.allExtensions.filter(X=>!X.main&&!X.browser).map(X=>X.identifier),ae=this._initData.allExtensions.filter(X=>!Se.has(P.ExtensionIdentifier.toKey(X.identifier.value))).filter(X=>(X.main||X.browser)&&X.api==="none").map(X=>X.identifier));const le=(0,d.extensionIdentifiersArrayToSet)(ae);this._activator=this._register(new I.ExtensionsActivator(this._myRegistry,Te,ae,{onExtensionActivationError:(X,J,k)=>{this._mainThreadExtensionsProxy.$onExtensionActivationError(X,w.transformErrorForSerialization(J),k)},actualActivateExtension:async(X,J)=>{if(le.has(P.ExtensionIdentifier.toKey(X)))return await this._mainThreadExtensionsProxy.$activateExtension(X,J),new I.HostExtension;const k=this._myRegistry.getExtensionDescription(X);return this._activateExtension(k,J)}},this._logService)),this._extensionPathIndex=null,this._resolvers=Object.create(null),this._started=!1,this._remoteConnectionData=this._initData.remote.connectionData}getRemoteConnectionData(){return this._remoteConnectionData}async initialize(){try{await this._beforeAlmostReadyToRunExtensions(),this._almostReadyToRunExtensions.open(),await this._extHostWorkspace.waitForInitializeCall(),b.mark("code/extHost/ready"),this._readyToStartExtensionHost.open(),this._initData.autoStart&&this._startExtensionHost()}catch(ie){w.onUnexpectedError(ie)}}async _deactivateAll(){this._storagePath.onWillDeactivateAll();let ie=[];try{ie=this._myRegistry.getAllExtensionDescriptions().map(ve=>ve.identifier).filter(ve=>this.isActivated(ve)).map(ve=>this._deactivate(ve))}catch{}await Promise.all(ie)}terminate(ie,Ee=0){if(this._isTerminating)return;this._isTerminating=!0,this._logService.info(`Extension host terminating: ${ie}`),this._logService.flush(),this._extHostTerminalService.dispose(),this._activator.dispose(),w.setUnexpectedErrorHandler(te=>{this._logService.error(te)}),this._extHostContext.dispose();const be=this._deactivateAll();Promise.race([(0,C.timeout)(5e3),be]).finally(()=>{this._hostUtils.pid?this._logService.info(`Extension host with pid ${this._hostUtils.pid} exiting with code ${Ee}`):this._logService.info(`Extension host exiting with code ${Ee}`),this._logService.flush(),this._logService.dispose(),this._hostUtils.exit(Ee)})}isActivated(ie){return this._readyToRunExtensions.isOpen()?this._activator.isActivated(ie):!1}async getExtension(ie){const Ee=await this._mainThreadExtensionsProxy.$getExtension(ie);return Ee&&{...Ee,identifier:new P.ExtensionIdentifier(Ee.identifier.value),extensionLocation:A.URI.revive(Ee.extensionLocation)}}_activateByEvent(ie,Ee){return this._activator.activateByEvent(ie,Ee)}_activateById(ie,Ee){return this._activator.activateById(ie,Ee)}activateByIdWithErrors(ie,Ee){return this._activateById(ie,Ee).then(()=>{const be=this._activator.getActivatedExtension(ie);if(be.activationFailed)return Promise.reject(be.activationFailedError)})}getExtensionRegistry(){return this._readyToRunExtensions.wait().then(ie=>this._myRegistry)}getExtensionExports(ie){return this._readyToRunExtensions.isOpen()?this._activator.getActivatedExtension(ie).exports:null}async _realPathExtensionUri(ie){if(ie.scheme!==S.Schemas.file)return ie;const Ee=await this._hostUtils.realpath(ie.fsPath);return A.URI.file(Ee)}async getExtensionPathIndex(){return this._extensionPathIndex||(this._extensionPathIndex=this._createExtensionPathIndex(this._myRegistry.getAllExtensionDescriptions()).then(ie=>new re(ie))),this._extensionPathIndex}async _createExtensionPathIndex(ie){const Ee=E.TernarySearchTree.forUris(be=>L.extUriBiasedIgnorePathCase.ignorePathCasing(be));return await Promise.all(ie.map(async be=>{if(this._getEntryPoint(be)){const te=await this._realPathExtensionUri(be.extensionLocation);Ee.set(te,be)}})),Ee}_deactivate(ie){let Ee=Promise.resolve(void 0);if(!this._readyToRunExtensions.isOpen()||!this._activator.isActivated(ie))return Ee;const be=this._activator.getActivatedExtension(ie);if(!be)return Ee;try{typeof be.module.deactivate=="function"&&(Ee=Promise.resolve(be.module.deactivate()).then(void 0,te=>(this._logService.error(te),Promise.resolve(void 0))))}catch(te){this._logService.error(`An error occurred when deactivating the extension '${ie.value}':`),this._logService.error(te)}try{(0,T.dispose)(be.subscriptions)}catch(te){this._logService.error(`An error occurred when deactivating the subscriptions for extension '${ie.value}':`),this._logService.error(te)}return Ee}async _activateExtension(ie,Ee){return this._initData.remote.isRemote?this._mainThreadExtensionsProxy.$onWillActivateExtension(ie.identifier):await this._mainThreadExtensionsProxy.$onWillActivateExtension(ie.identifier),this._doActivateExtension(ie,Ee).then(be=>{const te=be.activationTimes;return this._mainThreadExtensionsProxy.$onDidActivateExtension(ie.identifier,te.codeLoadingTime,te.activateCallTime,te.activateResolvedTime,Ee),this._logExtensionActivationTimes(ie,Ee,"success",te),be},be=>{throw this._logExtensionActivationTimes(ie,Ee,"failure"),be})}_logExtensionActivationTimes(ie,Ee,be,te){const ve=V(ie,Ee);this._mainThreadTelemetryProxy.$publicLog2("extensionActivationTimes",{...ve,...te||{},outcome:be})}_doActivateExtension(ie,Ee){const be=V(ie,Ee);this._mainThreadTelemetryProxy.$publicLog2("activatePlugin",be);const te=this._getEntryPoint(ie);if(!te)return Promise.resolve(new I.EmptyExtension(I.ExtensionActivationTimes.NONE));this._logService.info(`ExtensionService#_doActivateExtension ${ie.identifier.value}, startup: ${Ee.startup}, activationEvent: '${Ee.activationEvent}'${ie.identifier.value!==Ee.extensionId.value?`, root cause: ${Ee.extensionId.value}`:""}`),this._logService.flush();const ve=new I.ExtensionActivationTimesBuilder(Ee.startup);return Promise.all([this._loadCommonJSModule(ie.identifier,(0,L.joinPath)(ie.extensionLocation,te),ve),this._loadExtensionContext(ie)]).then(Re=>(b.mark(`code/extHost/willActivateExtension/${ie.identifier.value}`),ki._callActivate(this._logService,ie.identifier,Re[0],Re[1],ve))).then(Re=>(b.mark(`code/extHost/didActivateExtension/${ie.identifier.value}`),Re))}_loadExtensionContext(ie){const Ee=new _.ExtensionGlobalMemento(ie,this._storage),be=new _.ExtensionMemento(ie.identifier.value,!1,this._storage),te=new M.ExtensionSecrets(ie,this._secretState),ve=ie.isUnderDevelopment?this._initData.environment.extensionTestsLocationURI?n.ExtensionMode.Test:n.ExtensionMode.Development:n.ExtensionMode.Production,Re=this._initData.remote.isRemote?n.ExtensionKind.Workspace:n.ExtensionKind.UI;return this._logService.trace(`ExtensionService#loadExtensionContext ${ie.identifier.value}`),Promise.all([Ee.whenReady,be.whenReady,this._storagePath.whenReady]).then(()=>{const Fe=this;let $e,Ye;const Ie=(0,d.isProposedApiEnabled)(ie,"ipc")?this._initData.messagePorts?.get(P.ExtensionIdentifier.toKey(ie.identifier)):void 0;return Object.freeze({globalState:Ee,workspaceState:be,secrets:te,subscriptions:[],get extensionUri(){return ie.extensionLocation},get extensionPath(){return ie.extensionLocation.fsPath},asAbsolutePath(Se){return p.join(ie.extensionLocation.fsPath,Se)},get storagePath(){return Fe._storagePath.workspaceValue(ie)?.fsPath},get globalStoragePath(){return Fe._storagePath.globalValue(ie).fsPath},get logPath(){return p.join(Fe._initData.logsLocation.fsPath,ie.identifier.value)},get logUri(){return A.URI.joinPath(Fe._initData.logsLocation,ie.identifier.value)},get storageUri(){return Fe._storagePath.workspaceValue(ie)},get globalStorageUri(){return Fe._storagePath.globalValue(ie)},get extensionMode(){return ve},get extension(){return $e===void 0&&($e=new F(Fe,ie.identifier,ie,Re,!1)),$e},get extensionRuntime(){return(0,d.checkProposedApiEnabled)(ie,"extensionRuntime"),Fe.extensionRuntime},get environmentVariableCollection(){return Fe._extHostTerminalService.getEnvironmentVariableCollection(ie)},get messagePassingProtocol(){if(!Ye){if(!Ie)return;const Se=D.Event.buffer(D.Event.fromDOMEventEmitter(Ie,"message",Te=>Te.data));Ie.start(),Ye={onDidReceiveMessage:Se,postMessage:Ie.postMessage.bind(Ie)}}return Ye}})})}static _callActivate(ie,Ee,be,te,ve){return be=be||{activate:void 0,deactivate:void 0},this._callActivateOptional(ie,Ee,be,te,ve).then(Re=>new I.ActivatedExtension(!1,null,ve.build(),be,Re,te.subscriptions))}static _callActivateOptional(ie,Ee,be,te,ve){if(typeof be.activate=="function")try{ve.activateCallStart(),ie.trace(`ExtensionService#_callActivateOptional ${Ee.value}`);const Re=typeof global=="object"?global:self,Fe=be.activate.apply(Re,[te]);return ve.activateCallStop(),ve.activateResolveStart(),Promise.resolve(Fe).then($e=>(ve.activateResolveStop(),$e))}catch(Re){return Promise.reject(Re)}else return Promise.resolve(be)}_activateOneStartupFinished(ie,Ee){this._activateById(ie.identifier,{startup:!1,extensionId:ie.identifier,activationEvent:Ee}).then(void 0,be=>{this._logService.error(be)})}_activateAllStartupFinished(){this._mainThreadExtensionsProxy.$setPerformanceMarks(b.getMarks());for(const ie of this._myRegistry.getAllExtensionDescriptions())if(ie.activationEvents)for(const Ee of ie.activationEvents)Ee==="onStartupFinished"&&this._activateOneStartupFinished(ie,Ee)}_handleEagerExtensions(){const ie=this._activateByEvent("*",!0).then(void 0,ve=>{this._logService.error(ve)});this._register(this._extHostWorkspace.onDidChangeWorkspace(ve=>this._handleWorkspaceContainsEagerExtensions(ve.added)));const Ee=this._extHostWorkspace.workspace?this._extHostWorkspace.workspace.folders:[],be=this._handleWorkspaceContainsEagerExtensions(Ee),te=Promise.all([ie,be]).then(()=>{});return Promise.race([te,(0,C.timeout)(1e4)]).then(()=>{this._activateAllStartupFinished()}),te}_handleWorkspaceContainsEagerExtensions(ie){return ie.length===0?Promise.resolve(void 0):Promise.all(this._myRegistry.getAllExtensionDescriptions().map(Ee=>this._handleWorkspaceContainsEagerExtension(ie,Ee))).then(()=>{})}async _handleWorkspaceContainsEagerExtension(ie,Ee){if(this.isActivated(Ee.identifier))return;const be=!this._initData.remote.isRemote&&!!this._initData.remote.authority,te={logService:this._logService,folders:ie.map(Re=>Re.uri),forceUsingSearch:be,exists:Re=>this._hostUtils.exists(Re.fsPath),checkExists:(Re,Fe,$e)=>this._mainThreadWorkspaceProxy.$checkExists(Re,Fe,$e)},ve=await(0,U.checkActivateWorkspaceContainsExtension)(te,Ee);if(!!ve)return this._activateById(Ee.identifier,{startup:!0,extensionId:Ee.identifier,activationEvent:ve.activationEvent}).then(void 0,Re=>this._logService.error(Re))}async $extensionTestsExecute(){await this._eagerExtensionsActivated.wait();try{return await this._doHandleExtensionTests()}catch(ie){throw console.error(ie),ie}}async _doHandleExtensionTests(){const{extensionDevelopmentLocationURI:ie,extensionTestsLocationURI:Ee}=this._initData.environment;if(!ie||!Ee)throw new Error(s.localize(0,null));const be=await this._loadCommonJSModule(null,Ee,new I.ExtensionActivationTimesBuilder(!1));if(!be||typeof be.run!="function")throw new Error(s.localize(1,null,Ee.toString()));return new Promise((te,ve)=>{const Re=(Ye,Ie)=>{Ye?ve(Ye):te(typeof Ie=="number"&&Ie>0?1:0)},Fe=(0,L.originalFSPath)(Ee),$e=be.run(Fe,Re);$e&&$e.then&&$e.then(()=>{te(0)}).catch(Ye=>{ve(Ye instanceof Error&&Ye.stack?Ye.stack:String(Ye))})})}_startExtensionHost(){if(this._started)throw new Error("Extension host is already started!");return this._started=!0,this._readyToStartExtensionHost.wait().then(()=>this._readyToRunExtensions.open()).then(()=>this._handleEagerExtensions()).then(()=>{this._eagerExtensionsActivated.open(),this._logService.info("Eager extensions activated")})}registerRemoteAuthorityResolver(ie,Ee){return this._resolvers[ie]=Ee,(0,T.toDisposable)(()=>{delete this._resolvers[ie]})}async _activateAndGetResolver(ie){const Ee=ie.indexOf("+");if(Ee===-1)throw new Error("Not an authority that can be resolved!");const be=ie.substr(0,Ee);return await this._almostReadyToRunExtensions.wait(),await this._activateByEvent(`onResolveRemoteAuthority:${be}`,!1),{authorityPrefix:be,resolver:this._resolvers[be]}}async $resolveAuthority(ie,Ee){this._logService.info(`$resolveAuthority invoked for authority (${ce(ie)})`);const{authorityPrefix:be,resolver:te}=await this._activateAndGetResolver(ie);if(!te)return{type:"error",error:{code:u.RemoteAuthorityResolverErrorCode.NoResolverFound,message:`No remote extension installed to resolve ${be}.`,detail:void 0}};try{this._register(await this._extHostTunnelService.setTunnelFactory(te)),b.mark(`code/extHost/willResolveAuthority/${be}`);const ve=await te.resolve(ie,{resolveAttempt:Ee});b.mark(`code/extHost/didResolveAuthorityOK/${be}`);const Re={authority:ie,host:ve.host,port:ve.port,connectionToken:ve.connectionToken},Fe={extensionHostEnv:ve.extensionHostEnv,isTrusted:ve.isTrusted,authenticationSession:ve.authenticationSessionForInitializingExtensions?{id:ve.authenticationSessionForInitializingExtensions.id,providerId:ve.authenticationSessionForInitializingExtensions.providerId}:void 0};return{type:"ok",value:{authority:Re,options:Fe,tunnelInformation:{environmentTunnels:ve.environmentTunnels,features:ve.tunnelFeatures}}}}catch(ve){if(b.mark(`code/extHost/didResolveAuthorityError/${be}`),ve instanceof n.RemoteAuthorityResolverError)return{type:"error",error:{code:ve._code,message:ve._message,detail:ve._detail}};throw ve}}async $getCanonicalURI(ie,Ee){this._logService.info(`$getCanonicalURI invoked for authority (${ce(ie)})`);const{resolver:be}=await this._activateAndGetResolver(ie);if(!be)return null;const te=A.URI.revive(Ee);if(typeof be.getCanonicalURI=="undefined")return te;const ve=await(0,C.asPromise)(()=>be.getCanonicalURI(te));return ve||te}static _applyExtensionsDelta(ie,Ee,be){const te=new a.ExtensionDescriptionRegistry(ie.getAllExtensionDescriptions());te.deltaExtensions(be.toAdd,be.toRemove);const ve=(0,d.extensionIdentifiersArrayToSet)(Ee.getAllExtensionDescriptions().map(Fe=>Fe.identifier));for(const Fe of be.myToRemove)ve.delete(P.ExtensionIdentifier.toKey(Fe));for(const Fe of be.myToAdd)ve.add(P.ExtensionIdentifier.toKey(Fe));const Re=ne(te,ve);return{globalRegistry:te,myExtensions:Re}}$startExtensionHost(ie){ie.toAdd.forEach(te=>te.extensionLocation=A.URI.revive(te.extensionLocation));const{globalRegistry:Ee,myExtensions:be}=ki._applyExtensionsDelta(this._globalRegistry,this._myRegistry,ie);return this._globalRegistry.set(Ee.getAllExtensionDescriptions()),this._myRegistry.set(be),this._startExtensionHost()}$activateByEvent(ie,Ee){return Ee===1?this._activateByEvent(ie,!1):this._readyToRunExtensions.wait().then(be=>this._activateByEvent(ie,!1))}async $activate(ie,Ee){return await this._readyToRunExtensions.wait(),this._myRegistry.getExtensionDescription(ie)?(await this._activateById(ie,Ee),!0):!1}async $deltaExtensions(ie){ie.toAdd.forEach(Re=>Re.extensionLocation=A.URI.revive(Re.extensionLocation));const{globalRegistry:Ee,myExtensions:be}=ki._applyExtensionsDelta(this._globalRegistry,this._myRegistry,ie),te=await this._createExtensionPathIndex(be);return(await this.getExtensionPathIndex()).setSearchTree(te),this._globalRegistry.set(Ee.getAllExtensionDescriptions()),this._myRegistry.set(be),Promise.resolve(void 0)}async $test_latency(ie){return ie}async $test_up(ie){return ie.byteLength}async $test_down(ie){const Ee=l.VSBuffer.alloc(ie),be=Math.random()%256;for(let te=0;te<ie;te++)Ee.writeUInt8(be,te);return Ee}async $updateRemoteConnectionData(ie){this._remoteConnectionData=ie,this._onDidChangeRemoteConnectionData.fire()}};K=ze([xe(0,i.IInstantiationService),xe(1,e.IHostUtils),xe(2,t.IExtHostRpcService),xe(3,h.IExtHostWorkspace),xe(4,m.IExtHostConfiguration),xe(5,R.ILogService),xe(6,o.IExtHostInitDataService),xe(7,r.IExtensionStoragePaths),xe(8,v.IExtHostTunnelService),xe(9,g.IExtHostTerminalService)],K),e.AbstractExtHostExtensionService=K;function V(fe,ie){return{id:fe.identifier.value,name:fe.name,extensionVersion:fe.version,publisherDisplayName:fe.publisher,activationEvents:fe.activationEvents?fe.activationEvents.join(","):null,isBuiltin:fe.isBuiltin,reason:ie.activationEvent,reasonId:ie.extensionId.value}}e.IExtHostExtensionService=(0,i.createDecorator)("IExtHostExtensionService");class F{constructor(ie,Ee,be,te,ve){z.set(this,void 0),$.set(this,void 0),N.set(this,void 0),Je(this,z,ie,"f"),Je(this,$,Ee,"f"),Je(this,N,be.identifier,"f"),this.id=be.identifier.value,this.extensionUri=be.extensionLocation,this.extensionPath=p.normalize((0,L.originalFSPath)(be.extensionLocation)),this.packageJSON=be,this.extensionKind=te,this.isFromDifferentExtensionHost=ve}get isActive(){return Ae(this,z,"f").isActivated(Ae(this,N,"f"))}get exports(){if(!(this.packageJSON.api==="none"||this.isFromDifferentExtensionHost))return Ae(this,z,"f").getExtensionExports(Ae(this,N,"f"))}async activate(){if(this.isFromDifferentExtensionHost)throw new Error("Cannot activate foreign extension");return await Ae(this,z,"f").activateByIdWithErrors(Ae(this,N,"f"),{startup:!1,extensionId:Ae(this,$,"f"),activationEvent:"api"}),this.exports}}e.Extension=F,z=new WeakMap,$=new WeakMap,N=new WeakMap;function ne(fe,ie){return fe.getAllExtensionDescriptions().filter(Ee=>ie.has(P.ExtensionIdentifier.toKey(Ee.identifier)))}function ce(fe){const ie=fe.indexOf("+");return ie===-1?fe:fe.substring(0,ie)}class re{constructor(ie){this._searchTree=ie}setSearchTree(ie){this._searchTree=ie}findSubstr(ie){return this._searchTree.findSubstr(ie)}forEach(ie){return this._searchTree.forEach(ie)}}e.ExtensionPaths=re}),define(ye[229],Ce([1,0,71,2,5,32,24,27,15,28,3,33,59,14,9]),function(ee,e,s,p,b,L,C,T,E,A,R,y,m,I,f){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.RequireInterceptor=void 0;let h=class{constructor(_,n,u,i,o,r,t){this._apiFactory=_,this._extensionRegistry=n,this._instaService=u,this._extHostConfiguration=i,this._extHostExtensionService=o,this._initData=r,this._logService=t,this._factories=new Map,this._alternatives=[]}async install(){this._installInterceptor(),s.mark("code/extHost/willWaitForConfig");const _=await this._extHostConfiguration.getConfigProvider();s.mark("code/extHost/didWaitForConfig");const n=await this._extHostExtensionService.getExtensionPathIndex();this.register(new a(this._apiFactory,n,this._extensionRegistry,_,this._logService)),this.register(this._instaService.createInstance(w,n)),this.register(this._instaService.createInstance(d)),this._initData.remote.isRemote&&this.register(this._instaService.createInstance(P,n,this._initData.environment.appUriScheme))}register(_){if("nodeModuleName"in _)if(Array.isArray(_.nodeModuleName))for(const n of _.nodeModuleName)this._factories.set(n,_);else this._factories.set(_.nodeModuleName,_);typeof _.alternativeModuleName=="function"&&this._alternatives.push(n=>_.alternativeModuleName(n))}};h=ze([xe(2,R.IInstantiationService),xe(3,L.IExtHostConfiguration),xe(4,y.IExtHostExtensionService),xe(5,A.IExtHostInitDataService),xe(6,I.ILogService)],h),e.RequireInterceptor=h;let d=class Ki{constructor(_){if(_.environment.appRoot&&Ki.aliased.size){const n=(0,f.escapeRegExpCharacters)(this.forceForwardSlashes(_.environment.appRoot.fsPath)),u="[a-z0-9_.-]",i=`@${u}+\\/${u}+|${u}+`,o="node_modules|node_modules\\.asar(?:\\.unpacked)?";this.re=new RegExp(`^(${n}/${o}\\/)(${i})(.*)$`,"i")}}alternativeModuleName(_){if(!this.re)return;const n=this.re.exec(this.forceForwardSlashes(_));if(!n)return;const[,u,i,o]=n,r=Ki.aliased.get(i);if(r!==void 0)return console.warn(`${i} as been renamed to ${r}, please update your imports`),u+r+o}forceForwardSlashes(_){return _.replace(/\\/g,"/")}};d.aliased=new Map([["vscode-ripgrep","@vscode/ripgrep"],["vscode-windows-registry","@vscode/windows-registry"]]),d=ze([xe(0,A.IExtHostInitDataService)],d);class a{constructor(_,n,u,i,o){this._apiFactory=_,this._extensionPaths=n,this._extensionRegistry=u,this._configProvider=i,this._logService=o,this.nodeModuleName="vscode",this._extApiImpl=new Map}load(_,n){const u=this._extensionPaths.findSubstr(n);if(u){let i=this._extApiImpl.get(T.ExtensionIdentifier.toKey(u.identifier));return i||(i=this._apiFactory(u,this._extensionRegistry,this._configProvider),this._extApiImpl.set(T.ExtensionIdentifier.toKey(u.identifier),i)),i}if(!this._defaultApiImpl){let i="";this._extensionPaths.forEach((o,r)=>i+=` ${r} -> ${o.identifier.value}
`),this._logService.warn(`Could not identify extension for 'vscode' require call from ${n}. These are the extension path mappings:
${i}`),this._defaultApiImpl=this._apiFactory(C.nullExtensionDescription,this._extensionRegistry,this._configProvider)}return this._defaultApiImpl}}let w=class{constructor(_,n,u){this._extensionPaths=_,this.nodeModuleName="keytar",this._mainThreadTelemetry=n.getProxy(b.MainContext.MainThreadTelemetry);const{environment:i}=u,o=n.getProxy(b.MainContext.MainThreadKeytar);if(i.appRoot){let r=i.appRoot.fsPath;m.platform==="win32"&&(r=r.replace(/\\/g,"/")),r[r.length-1]==="/"&&(r=r.substr(0,r.length-1)),this.alternativeNames=new Set,this.alternativeNames.add(`${r}/node_modules.asar/keytar`),this.alternativeNames.add(`${r}/node_modules/keytar`)}this._impl={getPassword:(r,t)=>o.$getPassword(r,t),setPassword:(r,t,c)=>o.$setPassword(r,t,c),deletePassword:(r,t)=>o.$deletePassword(r,t),findPassword:r=>o.$findPassword(r),findCredentials(r){return o.$findCredentials(r)}}}load(_,n){const u=this._extensionPaths.findSubstr(n);return this._mainThreadTelemetry.$publicLog2("shimming.keytar",{extension:u?.identifier.value??"unknown_extension"}),this._impl}alternativeModuleName(_){const n=_.length;if(n<=7||!this.alternativeNames)return;const u=n-7;if((_.charAt(u)==="/"||_.charAt(u)==="\\")&&_.endsWith("keytar")&&(_=_.replace(/\\/g,"/"),this.alternativeNames.has(_)))return"keytar"}};w=ze([xe(1,E.IExtHostRpcService),xe(2,A.IExtHostInitDataService)],w);let P=class{constructor(_,n,u){this._extensionPaths=_,this._appUriScheme=n,this.nodeModuleName=["open","opn"],this._mainThreadTelemetry=u.getProxy(b.MainContext.MainThreadTelemetry);const i=u.getProxy(b.MainContext.MainThreadWindow);this._impl=(o,r)=>{const t=p.URI.parse(o);return r?this.callOriginal(o,r):t.scheme==="http"||t.scheme==="https"?i.$openUri(t,o,{allowTunneling:!0}):t.scheme==="mailto"||t.scheme===this._appUriScheme?i.$openUri(t,o,{}):this.callOriginal(o,r)}}load(_,n,u){const i=this._extensionPaths.findSubstr(n);return i&&(this._extensionId=i.identifier.value,this.sendShimmingTelemetry()),this._original=u(_),this._impl}callOriginal(_,n){return this.sendNoForwardTelemetry(),this._original(_,n)}sendShimmingTelemetry(){!this._extensionId||this._mainThreadTelemetry.$publicLog2("shimming.open",{extension:this._extensionId})}sendNoForwardTelemetry(){!this._extensionId||this._mainThreadTelemetry.$publicLog2("shimming.open.call.noForward",{extension:this._extensionId})}};P=ze([xe(2,E.IExtHostRpcService)],P)}),define(ye[101],Ce([1,0,196,7,19,59,3,49,50,33,6,31,170,32]),function(ee,e,s,p,b,L,C,T,E,A,R,y,m,I){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.ExtHostVariableResolverProviderService=e.IExtHostVariableResolverProvider=void 0,e.IExtHostVariableResolverProvider=(0,C.createDecorator)("IExtHostVariableResolverProvider");class f extends m.AbstractVariableResolverService{constructor(a,w,P,l,_,n,u){function i(){if(P){const o=P.activeEditor();if(o)return o.document.uri;const r=l.tabGroups.all.find(t=>t.isActive)?.activeTab;if(r!==void 0){if(r.input instanceof R.TextDiffTabInput||r.input instanceof R.NotebookDiffEditorTabInput)return r.input.modified;if(r.input instanceof R.TextTabInput||r.input instanceof R.NotebookEditorTabInput||r.input instanceof R.CustomEditorTabInput)return r.input.uri}}}super({getFolderUri:o=>{const r=n.folders.filter(t=>t.name===o);if(r&&r.length>0)return r[0].uri},getWorkspaceFolderCount:()=>n.folders.length,getConfigurationValue:(o,r)=>_.getConfiguration(void 0,o).get(r),getAppRoot:()=>L.cwd(),getExecPath:()=>L.env.VSCODE_EXEC_PATH,getFilePath:()=>{const o=i();if(o)return b.normalize(o.fsPath)},getWorkspaceFolderPathForFile:()=>{if(w){const o=i();if(o){const r=w.getWorkspaceFolder(o);if(r)return b.normalize(r.uri.fsPath)}}},getSelectedText:()=>{if(P){const o=P.activeEditor();if(o&&!o.selection.isEmpty)return o.document.getText(o.selection)}},getLineNumber:()=>{if(P){const o=P.activeEditor();if(o)return String(o.selection.end.line+1)}},getExtension:o=>a.getExtension(o)},void 0,u?Promise.resolve(u):void 0,Promise.resolve(L.env))}}let h=class extends p.Disposable{constructor(a,w,P,l,_){super();this.extensionService=a,this.workspaceService=w,this.editorService=P,this.configurationService=l,this.editorTabs=_,this._resolver=new s.Lazy(async()=>{const n=await this.configurationService.getConfigProvider(),i={folders:await this.workspaceService.getWorkspaceFolders2()||[]};return this._register(this.workspaceService.onDidChangeWorkspace(async o=>{i.folders=await this.workspaceService.getWorkspaceFolders2()||[]})),new f(this.extensionService,this.workspaceService,this.editorService,this.editorTabs,n,i,this.homeDir())})}getResolver(){return this._resolver.getValue()}homeDir(){}};h=ze([xe(0,A.IExtHostExtensionService),xe(1,y.IExtHostWorkspace),xe(2,T.IExtHostDocumentsAndEditors),xe(3,I.IExtHostConfiguration),xe(4,E.IExtHostEditorTabs)],h),e.ExtHostVariableResolverProviderService=h}),define(ye[102],Ce([1,0,13,4,10,2,3,5,50,33,15,6,31,164,166,32,101]),function(ee,e,s,p,b,L,C,T,E,A,R,y,m,I,f,h,d){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.WorkerExtHostDebugService=e.ExtHostDebugConsole=e.ExtHostDebugSession=e.ExtHostDebugServiceBase=e.IExtHostDebugService=void 0,e.IExtHostDebugService=(0,C.createDecorator)("IExtHostDebugService");let a=class{constructor(i,o,r,t,c,v){this._workspaceService=o,this._extensionService=r,this._configurationService=t,this._editorTabs=c,this._variableResolver=v,this._debugSessions=new Map,this._configProviderHandleCounter=0,this._configProviders=[],this._adapterFactoryHandleCounter=0,this._adapterFactories=[],this._trackerFactoryHandleCounter=0,this._trackerFactories=[],this._debugAdapters=new Map,this._debugAdaptersTrackers=new Map,this._onDidStartDebugSession=new p.Emitter,this._onDidTerminateDebugSession=new p.Emitter,this._onDidChangeActiveDebugSession=new p.Emitter,this._onDidReceiveDebugSessionCustomEvent=new p.Emitter,this._debugServiceProxy=i.getProxy(T.MainContext.MainThreadDebugService),this._onDidChangeBreakpoints=new p.Emitter({onFirstListenerAdd:()=>{this.startBreakpoints()}}),this._activeDebugConsole=new P(this._debugServiceProxy),this._breakpoints=new Map,this._breakpointEventsActive=!1,this._extensionService.getExtensionRegistry().then(g=>{g.onDidChange(D=>{this.registerAllDebugTypes(g)}),this.registerAllDebugTypes(g)})}get onDidStartDebugSession(){return this._onDidStartDebugSession.event}get onDidTerminateDebugSession(){return this._onDidTerminateDebugSession.event}get onDidChangeActiveDebugSession(){return this._onDidChangeActiveDebugSession.event}get activeDebugSession(){return this._activeDebugSession}get onDidReceiveDebugSessionCustomEvent(){return this._onDidReceiveDebugSessionCustomEvent.event}get activeDebugConsole(){return this._activeDebugConsole.value}asDebugSourceUri(i,o){const r=i;if(typeof r.sourceReference=="number"&&r.sourceReference>0){let t=`debug:${encodeURIComponent(r.path||"")}`,c="?";return o&&(t+=`${c}session=${encodeURIComponent(o.id)}`,c="&"),t+=`${c}ref=${r.sourceReference}`,L.URI.parse(t)}else{if(r.path)return L.URI.file(r.path);throw new Error("cannot create uri from DAP 'source' object; properties 'path' and 'sourceReference' are both missing.")}}registerAllDebugTypes(i){const o=[];for(const r of i.getAllExtensionDescriptions())if(r.contributes){const t=r.contributes.debuggers;if(t&&t.length>0)for(const c of t)(0,f.isDebuggerMainContribution)(c)&&o.push(c.type)}this._debugServiceProxy.$registerDebugTypes(o)}get onDidChangeBreakpoints(){return this._onDidChangeBreakpoints.event}get breakpoints(){this.startBreakpoints();const i=[];return this._breakpoints.forEach(o=>i.push(o)),i}addBreakpoints(i){this.startBreakpoints();const o=i.filter(c=>{const v=c.id;return this._breakpoints.has(v)?!1:(this._breakpoints.set(v,c),!0)});this.fireBreakpointChanges(o,[],[]);const r=[],t=new Map;for(const c of o)if(c instanceof y.SourceBreakpoint){let v=t.get(c.location.uri.toString());v||(v={type:"sourceMulti",uri:c.location.uri,lines:[]},t.set(c.location.uri.toString(),v),r.push(v)),v.lines.push({id:c.id,enabled:c.enabled,condition:c.condition,hitCondition:c.hitCondition,logMessage:c.logMessage,line:c.location.range.start.line,character:c.location.range.start.character})}else c instanceof y.FunctionBreakpoint&&r.push({type:"function",id:c.id,enabled:c.enabled,hitCondition:c.hitCondition,logMessage:c.logMessage,condition:c.condition,functionName:c.functionName});return this._debugServiceProxy.$registerBreakpoints(r)}removeBreakpoints(i){this.startBreakpoints();const o=i.filter(v=>this._breakpoints.delete(v.id));this.fireBreakpointChanges([],o,[]);const r=o.filter(v=>v instanceof y.SourceBreakpoint).map(v=>v.id),t=o.filter(v=>v instanceof y.FunctionBreakpoint).map(v=>v.id),c=o.filter(v=>v instanceof y.DataBreakpoint).map(v=>v.id);return this._debugServiceProxy.$unregisterBreakpoints(r,t,c)}startDebugging(i,o,r){return this._debugServiceProxy.$startDebugging(i?i.uri:void 0,o,{parentSessionID:r.parentSession?r.parentSession.id:void 0,lifecycleManagedByParent:r.lifecycleManagedByParent,repl:r.consoleMode===y.DebugConsoleMode.MergeWithParent?"mergeWithParent":"separate",noDebug:r.noDebug,compact:r.compact,debugUI:r.debugUI,suppressSaveBeforeStart:r.suppressSaveBeforeStart})}stopDebugging(i){return this._debugServiceProxy.$stopDebugging(i?i.id:void 0)}registerDebugConfigurationProvider(i,o,r){if(!o)return new y.Disposable(()=>{});const t=this._configProviderHandleCounter++;return this._configProviders.push({type:i,handle:t,provider:o}),this._debugServiceProxy.$registerDebugConfigurationProvider(i,r,!!o.provideDebugConfigurations,!!o.resolveDebugConfiguration,!!o.resolveDebugConfigurationWithSubstitutedVariables,t),new y.Disposable(()=>{this._configProviders=this._configProviders.filter(c=>c.provider!==o),this._debugServiceProxy.$unregisterDebugConfigurationProvider(t)})}registerDebugAdapterDescriptorFactory(i,o,r){if(!r)return new y.Disposable(()=>{});if(!this.definesDebugType(i,o))throw new Error(`a DebugAdapterDescriptorFactory can only be registered from the extension that defines the '${o}' debugger.`);if(this.getAdapterDescriptorFactoryByType(o))throw new Error("a DebugAdapterDescriptorFactory can only be registered once per a type.");const t=this._adapterFactoryHandleCounter++;return this._adapterFactories.push({type:o,handle:t,factory:r}),this._debugServiceProxy.$registerDebugAdapterDescriptorFactory(o,t),new y.Disposable(()=>{this._adapterFactories=this._adapterFactories.filter(c=>c.factory!==r),this._debugServiceProxy.$unregisterDebugAdapterDescriptorFactory(t)})}registerDebugAdapterTrackerFactory(i,o){if(!o)return new y.Disposable(()=>{});const r=this._trackerFactoryHandleCounter++;return this._trackerFactories.push({type:i,handle:r,factory:o}),new y.Disposable(()=>{this._trackerFactories=this._trackerFactories.filter(t=>t.factory!==o)})}async $runInTerminal(i,o){return Promise.resolve(void 0)}async $substituteVariables(i,o){let r;const t=await this.getFolder(i);return t&&(r={uri:t.uri,name:t.name,index:t.index,toResource:()=>{throw new Error("Not implemented")}}),(await this._variableResolver.getResolver()).resolveAnyAsync(r,o)}createDebugAdapter(i,o){if(i.type==="implementation")return new _(i.implementation)}createSignService(){}async $startDASession(i,o){const r=this,t=await this.getSession(o);return this.getAdapterDescriptor(this.getAdapterDescriptorFactoryByType(t.type),t).then(c=>{if(!c)throw new Error(`Couldn't find a debug adapter descriptor for debug type '${t.type}' (extension might have failed to activate)`);const v=this.convertToDto(c),g=this.createDebugAdapter(v,t);if(!g)throw new Error(`Couldn't create a debug adapter for type '${t.type}'.`);const D=g;return this._debugAdapters.set(i,D),this.getDebugAdapterTrackers(t).then(U=>(U&&this._debugAdaptersTrackers.set(i,U),D.onMessage(async W=>{if(W.type==="request"&&W.command==="handshake"){const M=W,S={type:"response",seq:0,command:M.command,request_seq:M.seq,success:!0};this._signService||(this._signService=this.createSignService());try{if(this._signService){const z=await this._signService.sign(M.arguments.value);S.body={signature:z},D.sendResponse(S)}else throw new Error("no signer")}catch(z){S.success=!1,S.message=z.message,D.sendResponse(S)}}else U&&U.onDidSendMessage&&U.onDidSendMessage(W),W=(0,f.convertToVSCPaths)(W,!0),r._debugServiceProxy.$acceptDAMessage(i,W)}),D.onError(W=>{U&&U.onError&&U.onError(W),this._debugServiceProxy.$acceptDAError(i,W.name,W.message,W.stack)}),D.onExit(W=>{U&&U.onExit&&U.onExit((0,b.withNullAsUndefined)(W),void 0),this._debugServiceProxy.$acceptDAExit(i,(0,b.withNullAsUndefined)(W),void 0)}),U&&U.onWillStartSession&&U.onWillStartSession(),D.startSession()))})}$sendDAMessage(i,o){o=(0,f.convertToDAPaths)(o,!1);const r=this._debugAdaptersTrackers.get(i);r&&r.onWillReceiveMessage&&r.onWillReceiveMessage(o),this._debugAdapters.get(i)?.sendMessage(o)}$stopDASession(i){const o=this._debugAdaptersTrackers.get(i);this._debugAdaptersTrackers.delete(i),o&&o.onWillStopSession&&o.onWillStopSession();const r=this._debugAdapters.get(i);return this._debugAdapters.delete(i),r?r.stopSession():Promise.resolve(void 0)}$acceptBreakpointsDelta(i){const o=[],r=[],t=[];if(i.added)for(const c of i.added){const v=c.id;if(v&&!this._breakpoints.has(v)){let g;if(c.type==="function")g=new y.FunctionBreakpoint(c.functionName,c.enabled,c.condition,c.hitCondition,c.logMessage);else if(c.type==="data")g=new y.DataBreakpoint(c.label,c.dataId,c.canPersist,c.enabled,c.hitCondition,c.condition,c.logMessage);else{const D=L.URI.revive(c.uri);g=new y.SourceBreakpoint(new y.Location(D,new y.Position(c.line,c.character)),c.enabled,c.condition,c.hitCondition,c.logMessage)}g._id=v,this._breakpoints.set(v,g),o.push(g)}}if(i.removed)for(const c of i.removed){const v=this._breakpoints.get(c);v&&(this._breakpoints.delete(c),r.push(v))}if(i.changed){for(const c of i.changed)if(c.id){const v=this._breakpoints.get(c.id);if(v){if(v instanceof y.FunctionBreakpoint&&c.type==="function"){const g=v;g.enabled=c.enabled,g.condition=c.condition,g.hitCondition=c.hitCondition,g.logMessage=c.logMessage,g.functionName=c.functionName}else if(v instanceof y.SourceBreakpoint&&c.type==="source"){const g=v;g.enabled=c.enabled,g.condition=c.condition,g.hitCondition=c.hitCondition,g.logMessage=c.logMessage,g.location=new y.Location(L.URI.revive(c.uri),new y.Position(c.line,c.character))}t.push(v)}}}this.fireBreakpointChanges(o,r,t)}$provideDebugConfigurations(i,o,r){return(0,s.asPromise)(async()=>{const t=this.getConfigProviderByHandle(i);if(!t)throw new Error("no DebugConfigurationProvider found");if(!t.provideDebugConfigurations)throw new Error("DebugConfigurationProvider has no method provideDebugConfigurations");const c=await this.getFolder(o);return t.provideDebugConfigurations(c,r)}).then(t=>{if(!t)throw new Error("nothing returned from DebugConfigurationProvider.provideDebugConfigurations");return t})}$resolveDebugConfiguration(i,o,r,t){return(0,s.asPromise)(async()=>{const c=this.getConfigProviderByHandle(i);if(!c)throw new Error("no DebugConfigurationProvider found");if(!c.resolveDebugConfiguration)throw new Error("DebugConfigurationProvider has no method resolveDebugConfiguration");const v=await this.getFolder(o);return c.resolveDebugConfiguration(v,r,t)})}$resolveDebugConfigurationWithSubstitutedVariables(i,o,r,t){return(0,s.asPromise)(async()=>{const c=this.getConfigProviderByHandle(i);if(!c)throw new Error("no DebugConfigurationProvider found");if(!c.resolveDebugConfigurationWithSubstitutedVariables)throw new Error("DebugConfigurationProvider has no method resolveDebugConfigurationWithSubstitutedVariables");const v=await this.getFolder(o);return c.resolveDebugConfigurationWithSubstitutedVariables(v,r,t)})}async $provideDebugAdapter(i,o){const r=this.getAdapterDescriptorFactoryByHandle(i);if(!r)return Promise.reject(new Error("no adapter descriptor factory found for handle"));const t=await this.getSession(o);return this.getAdapterDescriptor(r,t).then(c=>{if(!c)throw new Error(`Couldn't find a debug adapter descriptor for debug type '${t.type}'`);return this.convertToDto(c)})}async $acceptDebugSessionStarted(i){const o=await this.getSession(i);this._onDidStartDebugSession.fire(o)}async $acceptDebugSessionTerminated(i){const o=await this.getSession(i);o&&(this._onDidTerminateDebugSession.fire(o),this._debugSessions.delete(o.id))}async $acceptDebugSessionActiveChanged(i){this._activeDebugSession=i?await this.getSession(i):void 0,this._onDidChangeActiveDebugSession.fire(this._activeDebugSession)}async $acceptDebugSessionNameChanged(i,o){(await this.getSession(i))?._acceptNameChanged(o)}async $acceptDebugSessionCustomEvent(i,o){const t={session:await this.getSession(i),event:o.event,body:o.body};this._onDidReceiveDebugSessionCustomEvent.fire(t)}convertToDto(i){if(i instanceof y.DebugAdapterExecutable)return{type:"executable",command:i.command,args:i.args,options:i.options};if(i instanceof y.DebugAdapterServer)return{type:"server",port:i.port,host:i.host};if(i instanceof y.DebugAdapterNamedPipeServer)return{type:"pipeServer",path:i.path};if(i instanceof y.DebugAdapterInlineImplementation)return{type:"implementation",implementation:i.implementation};throw new Error("convertToDto unexpected type")}getAdapterDescriptorFactoryByType(i){const o=this._adapterFactories.filter(r=>r.type===i);if(o.length>0)return o[0].factory}getAdapterDescriptorFactoryByHandle(i){const o=this._adapterFactories.filter(r=>r.handle===i);if(o.length>0)return o[0].factory}getConfigProviderByHandle(i){const o=this._configProviders.filter(r=>r.handle===i);if(o.length>0)return o[0].provider}definesDebugType(i,o){if(i.contributes){const r=i.contributes.debuggers;if(r&&r.length>0){for(const t of r)if(t.label&&t.type&&t.type===o)return!0}}return!1}getDebugAdapterTrackers(i){const r=i.configuration.type,t=this._trackerFactories.filter(c=>c.type===r||c.type==="*").map(c=>(0,s.asPromise)(()=>c.factory.createDebugAdapterTracker(i)).then(v=>v,v=>null));return Promise.race([Promise.all(t).then(c=>{const v=c.filter(g=>!!g);if(v.length>0)return new l(v)}),new Promise((c,v)=>{const g=setTimeout(()=>{clearTimeout(g),v(new Error("timeout"))},1e3)})]).catch(c=>{})}async getAdapterDescriptor(i,o){const r=o.configuration.debugServer;if(typeof r=="number")return Promise.resolve(new y.DebugAdapterServer(r));if(i){const c=await this._extensionService.getExtensionRegistry();return(0,s.asPromise)(()=>i.createDebugAdapterDescriptor(o,this.daExecutableFromPackage(o,c))).then(v=>{if(v)return v})}const t=await this._extensionService.getExtensionRegistry();return Promise.resolve(this.daExecutableFromPackage(o,t))}daExecutableFromPackage(i,o){}startBreakpoints(){this._breakpointEventsActive||(this._breakpointEventsActive=!0,this._debugServiceProxy.$startBreakpointEvents())}fireBreakpointChanges(i,o,r){(i.length>0||o.length>0||r.length>0)&&this._onDidChangeBreakpoints.fire(Object.freeze({added:i,removed:o,changed:r}))}async getSession(i){if(i)if(typeof i=="string"){const o=this._debugSessions.get(i);if(o)return o}else{let o=this._debugSessions.get(i.id);if(!o){const r=await this.getFolder(i.folderUri),t=i.parent?this._debugSessions.get(i.parent):void 0;o=new w(this._debugServiceProxy,i.id,i.type,i.name,r,i.configuration,t),this._debugSessions.set(o.id,o),this._debugServiceProxy.$sessionCached(o.id)}return o}throw new Error("cannot find session")}getFolder(i){if(i){const o=L.URI.revive(i);return this._workspaceService.resolveWorkspaceFolder(o)}return Promise.resolve(void 0)}};a=ze([xe(0,R.IExtHostRpcService),xe(1,m.IExtHostWorkspace),xe(2,A.IExtHostExtensionService),xe(3,h.IExtHostConfiguration),xe(4,E.IExtHostEditorTabs),xe(5,d.IExtHostVariableResolverProvider)],a),e.ExtHostDebugServiceBase=a;class w{constructor(i,o,r,t,c,v,g){this._debugServiceProxy=i,this._id=o,this._type=r,this._name=t,this._workspaceFolder=c,this._configuration=v,this._parentSession=g}get id(){return this._id}get type(){return this._type}get name(){return this._name}set name(i){this._name=i,this._debugServiceProxy.$setDebugSessionName(this._id,i)}get parentSession(){return this._parentSession}_acceptNameChanged(i){this._name=i}get workspaceFolder(){return this._workspaceFolder}get configuration(){return this._configuration}customRequest(i,o){return this._debugServiceProxy.$customDebugAdapterRequest(this._id,i,o)}getDebugProtocolBreakpoint(i){return this._debugServiceProxy.$getDebugProtocolBreakpoint(this._id,i.id)}}e.ExtHostDebugSession=w;class P{constructor(i){this.value=Object.freeze({append(o){i.$appendDebugConsole(o)},appendLine(o){this.append(o+`
`)}})}}e.ExtHostDebugConsole=P;class l{constructor(i){this.trackers=i}onWillStartSession(){this.trackers.forEach(i=>i.onWillStartSession?i.onWillStartSession():void 0)}onWillReceiveMessage(i){this.trackers.forEach(o=>o.onWillReceiveMessage?o.onWillReceiveMessage(i):void 0)}onDidSendMessage(i){this.trackers.forEach(o=>o.onDidSendMessage?o.onDidSendMessage(i):void 0)}onWillStopSession(){this.trackers.forEach(i=>i.onWillStopSession?i.onWillStopSession():void 0)}onError(i){this.trackers.forEach(o=>o.onError?o.onError(i):void 0)}onExit(i,o){this.trackers.forEach(r=>r.onExit?r.onExit(i,o):void 0)}}class _ extends I.AbstractDebugAdapter{constructor(i){super();this.implementation=i,i.onDidSendMessage(o=>{this.acceptMessage(o)})}startSession(){return Promise.resolve(void 0)}sendMessage(i){this.implementation.handleMessage(i)}stopSession(){return this.implementation.dispose(),Promise.resolve(void 0)}}let n=class extends a{constructor(i,o,r,t,c,v){super(i,o,r,t,c,v)}};n=ze([xe(0,R.IExtHostRpcService),xe(1,m.IExtHostWorkspace),xe(2,A.IExtHostExtensionService),xe(3,h.IExtHostConfiguration),xe(4,E.IExtHostEditorTabs),xe(5,d.IExtHostVariableResolverProvider)],n),e.WorkerExtHostDebugService=n}),define(ye[230],Ce([1,0,11,71,2,5,221,14,56,58,28,147,15,63,33]),function(ee,e,s,p,b,L,C,T,E,A,R,y,m,I,f){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.ExtensionHostMain=void 0;class h{constructor(a,w,P,l,_){this._hostUtils=P,this._rpcProtocol=new C.RPCProtocol(a,null,l),w=h._transform(w,this._rpcProtocol);const n=new A.ServiceCollection(...(0,E.getSingletonServiceDescriptors)());n.set(R.IExtHostInitDataService,{_serviceBrand:void 0,...w,messagePorts:_}),n.set(m.IExtHostRpcService,new m.ExtHostRpcService(this._rpcProtocol)),n.set(I.IURITransformerService,new I.URITransformerService(l)),n.set(f.IHostUtils,P);const u=new y.InstantiationService(n,!0);this._logService=u.invokeFunction(t=>t.get(T.ILogService)),p.mark("code/extHost/didCreateServices"),this._hostUtils.pid?this._logService.info(`Extension host with pid ${this._hostUtils.pid} started`):this._logService.info("Extension host started"),this._logService.trace("initData",w),this._extensionService=u.invokeFunction(t=>t.get(f.IExtHostExtensionService)),this._extensionService.initialize(),Error.stackTraceLimit=100;const i=new WeakMap;this._extensionService.getExtensionPathIndex().then(t=>{Error.prepareStackTrace=(c,v)=>{let g="",D,U;for(const W of v)g+=`
at ${W.toString()}`,U=W.getFileName(),!D&&U&&(D=t.findSubstr(b.URI.file(U)));return i.set(c,D),`${c.name||"Error"}: ${c.message||""}${g}`}});const o=this._rpcProtocol.getProxy(L.MainContext.MainThreadExtensionService),r=this._rpcProtocol.getProxy(L.MainContext.MainThreadErrors);s.setUnexpectedErrorHandler(t=>{const c=s.transformErrorForSerialization(t),v=i.get(t);v?o.$onExtensionRuntimeError(v.identifier,c):r.$onUnexpectedError(c)})}async asBrowserUri(a){const w=this._rpcProtocol.getProxy(L.MainContext.MainThreadExtensionService);return b.URI.revive(await w.$asBrowserUri(a))}terminate(a){this._extensionService.terminate(a)}static _transform(a,w){a.allExtensions.forEach(l=>l.extensionLocation=b.URI.revive(w.transformIncomingURIs(l.extensionLocation))),a.environment.appRoot=b.URI.revive(w.transformIncomingURIs(a.environment.appRoot));const P=a.environment.extensionDevelopmentLocationURI;return P&&(a.environment.extensionDevelopmentLocationURI=P.map(l=>b.URI.revive(w.transformIncomingURIs(l)))),a.environment.extensionTestsLocationURI=b.URI.revive(w.transformIncomingURIs(a.environment.extensionTestsLocationURI)),a.environment.globalStorageHome=b.URI.revive(w.transformIncomingURIs(a.environment.globalStorageHome)),a.environment.workspaceStorageHome=b.URI.revive(w.transformIncomingURIs(a.environment.workspaceStorageHome)),a.logsLocation=b.URI.revive(w.transformIncomingURIs(a.logsLocation)),a.logFile=b.URI.revive(w.transformIncomingURIs(a.logFile)),a.workspace=w.transformIncomingURIs(a.workspace),a}}e.ExtensionHostMain=h}),define(ye[231],Ce([1,0,16,13,20,44,12,19,21,10,2,41]),function(ee,e,s,p,b,L,C,T,E,A,R,y){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.BatchedCollector=e.extensionResultIsMatch=e.TextSearchResultsCollector=e.TextSearchManager=void 0;class m{constructor(P,l,_,n){this.query=P,this.provider=l,this.fileUtils=_,this.processType=n,this.collector=null,this.isLimitHit=!1,this.resultCount=0}search(P,l){const _=this.query.folderQueries||[],n=new b.CancellationTokenSource;return l.onCancellationRequested(()=>n.cancel()),new Promise((u,i)=>{this.collector=new f(P);let o=!1;const r=(t,c)=>{if(!o&&!this.isLimitHit){const v=this.resultSize(t);d(t)&&typeof this.query.maxResults=="number"&&this.resultCount+v>this.query.maxResults&&(this.isLimitHit=!0,o=!0,n.cancel(),t=this.trimResultToSize(t,this.query.maxResults-this.resultCount));const g=this.resultSize(t);this.resultCount+=g,(g>0||!d(t))&&this.collector.add(t,c)}};Promise.all(_.map((t,c)=>this.searchInFolder(t,v=>r(v,c),n.token))).then(t=>{n.dispose(),this.collector.flush();const c=t.some(v=>!!v&&!!v.limitHit);u({limitHit:this.isLimitHit||c,messages:(0,s.flatten)(t.map(v=>v?.message?(0,A.isArray)(v.message)?v.message:[v.message]:[])),stats:{type:this.processType}})},t=>{n.dispose();const c=(0,L.toErrorMessage)(t);i(new Error(c))})})}resultSize(P){return d(P)?Array.isArray(P.ranges)?P.ranges.length:1:0}trimResultToSize(P,l){const _=Array.isArray(P.ranges)?P.ranges:[P.ranges],n=Array.isArray(P.preview.matches)?P.preview.matches:[P.preview.matches];return{ranges:_.slice(0,l),preview:{matches:n.slice(0,l),text:P.preview.text},uri:P.uri}}async searchInFolder(P,l,_){const n=new y.QueryGlobTester(this.query,P),u=[],i={report:t=>{if(!this.validateProviderResult(t))return;const c=P.folder.scheme===C.Schemas.file?(0,y.hasSiblingPromiseFn)(()=>this.fileUtils.readdir(E.dirname(t.uri))):void 0,v=E.relativePath(P.folder,t.uri);if(v){const g=n.includedInQuery(v,T.basename(v),c);(0,p.isThenable)(g)?u.push(g.then(D=>{D&&l(t)})):g&&l(t)}}},o=this.getSearchOptionsForFolder(P),r=await this.provider.provideTextSearchResults(I(this.query.contentPattern),o,i,_);return u.length&&await Promise.all(u),r}validateProviderResult(P){if(d(P)){if(Array.isArray(P.ranges)){if(!Array.isArray(P.preview.matches))return console.warn("INVALID - A text search provider match's`ranges` and`matches` properties must have the same type."),!1;if(P.preview.matches.length!==P.ranges.length)return console.warn("INVALID - A text search provider match's`ranges` and`matches` properties must have the same length."),!1}else if(Array.isArray(P.preview.matches))return console.warn("INVALID - A text search provider match's`ranges` and`matches` properties must have the same length."),!1}return!0}getSearchOptionsForFolder(P){const l=(0,y.resolvePatternsForProvider)(this.query.includePattern,P.includePattern),_=(0,y.resolvePatternsForProvider)(this.query.excludePattern,P.excludePattern),n={folder:R.URI.from(P.folder),excludes:_,includes:l,useIgnoreFiles:!P.disregardIgnoreFiles,useGlobalIgnoreFiles:!P.disregardGlobalIgnoreFiles,useParentIgnoreFiles:!P.disregardParentIgnoreFiles,followSymlinks:!P.ignoreSymlinks,encoding:P.fileEncoding&&this.fileUtils.toCanonicalName(P.fileEncoding),maxFileSize:this.query.maxFileSize,maxResults:this.query.maxResults,previewOptions:this.query.previewOptions,afterContext:this.query.afterContext,beforeContext:this.query.beforeContext};return n.usePCRE2=this.query.usePCRE2,n}}e.TextSearchManager=m;function I(w){return{isCaseSensitive:w.isCaseSensitive||!1,isRegExp:w.isRegExp||!1,isWordMatch:w.isWordMatch||!1,isMultiline:w.isMultiline||!1,pattern:w.pattern}}class f{constructor(P){this._onResult=P,this._currentFolderIdx=-1,this._currentFileMatch=null,this._batchedCollector=new a(512,l=>this.sendItems(l))}add(P,l){this._currentFileMatch&&(this._currentFolderIdx!==l||!E.isEqual(this._currentUri,P.uri))&&(this.pushToCollector(),this._currentFileMatch=null),this._currentFileMatch||(this._currentFolderIdx=l,this._currentFileMatch={resource:P.uri,results:[]}),this._currentFileMatch.results.push(h(P))}pushToCollector(){const P=this._currentFileMatch&&this._currentFileMatch.results?this._currentFileMatch.results.length:0;this._batchedCollector.addItem(this._currentFileMatch,P)}flush(){this.pushToCollector(),this._batchedCollector.flush()}sendItems(P){this._onResult(P)}}e.TextSearchResultsCollector=f;function h(w){return d(w)?{preview:{matches:(0,s.mapArrayOrNot)(w.preview.matches,P=>({startLineNumber:P.start.line,startColumn:P.start.character,endLineNumber:P.end.line,endColumn:P.end.character})),text:w.preview.text},ranges:(0,s.mapArrayOrNot)(w.ranges,P=>({startLineNumber:P.start.line,startColumn:P.start.character,endLineNumber:P.end.line,endColumn:P.end.character}))}:{text:w.text,lineNumber:w.lineNumber}}function d(w){return!!w.preview}e.extensionResultIsMatch=d;class a{constructor(P,l){this.maxBatchSize=P,this.cb=l,this.totalNumberCompleted=0,this.batch=[],this.batchSize=0}addItem(P,l){!P||this.addItemToBatch(P,l)}addItems(P,l){!P||this.addItemsToBatch(P,l)}addItemToBatch(P,l){this.batch.push(P),this.batchSize+=l,this.onUpdate()}addItemsToBatch(P,l){this.batch=this.batch.concat(P),this.batchSize+=l,this.onUpdate()}onUpdate(){this.totalNumberCompleted<a.START_BATCH_AFTER_COUNT?this.flush():this.batchSize>=this.maxBatchSize?this.flush():this.timeoutHandle||(this.timeoutHandle=setTimeout(()=>{this.flush()},a.TIMEOUT))}flush(){this.batchSize&&(this.totalNumberCompleted+=this.batchSize,this.cb(this.batch),this.batch=[],this.batchSize=0,this.timeoutHandle&&(clearTimeout(this.timeoutHandle),this.timeoutHandle=0))}}e.BatchedCollector=a,a.TIMEOUT=4e3,a.START_BATCH_AFTER_COUNT=50}),define(ye[103],Ce([1,0,7,5,3,226,15,63,14,2,231]),function(ee,e,s,p,b,L,C,T,E,A,R){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.reviveQuery=e.ExtHostSearch=e.IExtHostSearch=void 0,e.IExtHostSearch=(0,b.createDecorator)("IExtHostSearch");let y=class{constructor(h,d,a){this.extHostRpc=h,this._uriTransformer=d,this._logService=a,this._proxy=this.extHostRpc.getProxy(p.MainContext.MainThreadSearch),this._handlePool=0,this._textSearchProvider=new Map,this._textSearchUsedSchemes=new Set,this._fileSearchProvider=new Map,this._fileSearchUsedSchemes=new Set,this._fileSearchManager=new L.FileSearchManager}_transformScheme(h){return this._uriTransformer.transformOutgoingScheme(h)}registerTextSearchProvider(h,d){if(this._textSearchUsedSchemes.has(h))throw new Error(`a text search provider for the scheme '${h}' is already registered`);this._textSearchUsedSchemes.add(h);const a=this._handlePool++;return this._textSearchProvider.set(a,d),this._proxy.$registerTextSearchProvider(a,this._transformScheme(h)),(0,s.toDisposable)(()=>{this._textSearchUsedSchemes.delete(h),this._textSearchProvider.delete(a),this._proxy.$unregisterProvider(a)})}registerFileSearchProvider(h,d){if(this._fileSearchUsedSchemes.has(h))throw new Error(`a file search provider for the scheme '${h}' is already registered`);this._fileSearchUsedSchemes.add(h);const a=this._handlePool++;return this._fileSearchProvider.set(a,d),this._proxy.$registerFileSearchProvider(a,this._transformScheme(h)),(0,s.toDisposable)(()=>{this._fileSearchUsedSchemes.delete(h),this._fileSearchProvider.delete(a),this._proxy.$unregisterProvider(a)})}$provideFileSearchResults(h,d,a,w){const P=m(a),l=this._fileSearchProvider.get(h);if(l)return this._fileSearchManager.fileSearch(P,l,_=>{this._proxy.$handleFileMatch(h,d,_.map(n=>n.resource))},w);throw new Error("unknown provider: "+h)}$clearCache(h){return this._fileSearchManager.clearCache(h),Promise.resolve(void 0)}$provideTextSearchResults(h,d,a,w){const P=this._textSearchProvider.get(h);if(!P||!P.provideTextSearchResults)throw new Error(`Unknown provider ${h}`);const l=m(a);return this.createTextSearchManager(l,P).search(n=>this._proxy.$handleTextMatch(h,d,n),w)}$enableExtensionHostSearch(){}createTextSearchManager(h,d){return new R.TextSearchManager(h,d,{readdir:a=>Promise.resolve([]),toCanonicalName:a=>a},"textSearchProvider")}};y=ze([xe(0,C.IExtHostRpcService),xe(1,T.IURITransformerService),xe(2,E.ILogService)],y),e.ExtHostSearch=y;function m(f){return{...f,folderQueries:f.folderQueries&&f.folderQueries.map(I),extraFileResources:f.extraFileResources&&f.extraFileResources.map(h=>A.URI.revive(h))}}e.reviveQuery=m;function I(f){return{...f,folder:A.URI.revive(f.folder)}}}),define(ye[232],Ce([1,0,56,98,31,95,32,36,49,52,100,102,103,69,62,68,97,51,35,67,86,50,204,14,180,101]),function(ee,e,s,p,b,L,C,T,E,A,R,y,m,I,f,h,d,a,w,P,l,_,n,u,i,o){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),(0,s.registerSingleton)(u.ILoggerService,n.ExtHostLoggerService),(0,s.registerSingleton)(u.ILogService,i.ExtHostLogService),(0,s.registerSingleton)(h.IExtHostApiDeprecationService,h.ExtHostApiDeprecationService),(0,s.registerSingleton)(T.IExtHostCommands,T.ExtHostCommands),(0,s.registerSingleton)(C.IExtHostConfiguration,C.ExtHostConfiguration),(0,s.registerSingleton)(a.IExtHostConsumerFileSystem,a.ExtHostConsumerFileSystem),(0,s.registerSingleton)(y.IExtHostDebugService,y.WorkerExtHostDebugService),(0,s.registerSingleton)(L.IExtHostDecorations,L.ExtHostDecorations),(0,s.registerSingleton)(E.IExtHostDocumentsAndEditors,E.ExtHostDocumentsAndEditors),(0,s.registerSingleton)(w.IExtHostFileSystemInfo,w.ExtHostFileSystemInfo),(0,s.registerSingleton)(p.IExtHostOutputService,p.ExtHostOutputService),(0,s.registerSingleton)(m.IExtHostSearch,m.ExtHostSearch),(0,s.registerSingleton)(I.IExtHostStorage,I.ExtHostStorage),(0,s.registerSingleton)(R.IExtHostTask,R.WorkerExtHostTask),(0,s.registerSingleton)(A.IExtHostTerminalService,A.WorkerExtHostTerminalService),(0,s.registerSingleton)(f.IExtHostTunnelService,f.ExtHostTunnelService),(0,s.registerSingleton)(d.IExtHostWindow,d.ExtHostWindow),(0,s.registerSingleton)(b.IExtHostWorkspace,b.ExtHostWorkspace),(0,s.registerSingleton)(P.IExtHostSecretState,P.ExtHostSecretState),(0,s.registerSingleton)(l.IExtHostTelemetry,l.ExtHostTelemetry),(0,s.registerSingleton)(_.IExtHostEditorTabs,_.ExtHostEditorTabs),(0,s.registerSingleton)(o.IExtHostVariableResolverProvider,o.ExtHostVariableResolverProviderService)}),define(ye[233],Ce([1,0]),function(ee,e){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.TreeviewsService=void 0;class s{constructor(){this._dragOperations=new Map,this._renderedElements=new Map}removeDragOperationTransfer(b){if(b&&this._dragOperations.has(b)){const L=this._dragOperations.get(b);return this._dragOperations.delete(b),L}}addDragOperationTransfer(b,L){this._dragOperations.set(b,L)}getRenderedTreeElement(b){if(this._renderedElements.has(b))return this._renderedElements.get(b)}addRenderedTreeItemElement(b,L){this._renderedElements.set(b,L)}removeRenderedTreeItemElement(b){this._renderedElements.has(b)&&this._renderedElements.delete(b)}}e.TreeviewsService=s}),define(ye[234],Ce([1,0,133,6,21,2,4,7,13,6,10,16,8,20,233,24]),function(ee,e,s,p,b,L,C,T,E,A,R,y,m,I,f,h){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.ExtHostTreeViews=void 0;function d(P,l){if((0,R.isString)(P))return{label:P};if(P&&typeof P=="object"&&typeof P.label=="string"){let _;return Array.isArray(P.highlights)&&(_=P.highlights.filter(n=>n.length===2&&typeof n[0]=="number"&&typeof n[1]=="number"),_=_.length?_:void 0),{label:P.label,highlights:_}}}class a{constructor(l,_,n){this._proxy=l,this.commands=_,this.logService=n,this.treeViews=new Map,this.treeDragAndDropService=new f.TreeviewsService;function u(i){return i&&i.$treeViewId&&i.$treeItemHandle}_.registerArgumentProcessor({processArgument:i=>u(i)?this.convertArgument(i):Array.isArray(i)&&i.length>0?i.map(o=>u(o)?this.convertArgument(o):o):i})}registerTreeDataProvider(l,_,n){const u=this.createTreeView(l,{treeDataProvider:_},n);return{dispose:()=>u.dispose()}}createTreeView(l,_,n){if(!_||!_.treeDataProvider)throw new Error("Options with treeDataProvider is mandatory");const u=_.dragAndDropController?.dropMimeTypes??[],i=_.dragAndDropController?.dragMimeTypes??[],o=!!_.dragAndDropController?.handleDrag,r=!!_.dragAndDropController?.handleDrop,t=this._proxy.$registerTreeViewDataProvider(l,{showCollapseAll:!!_.showCollapseAll,canSelectMany:!!_.canSelectMany,dropMimeTypes:u,dragMimeTypes:i,hasHandleDrag:o,hasHandleDrop:r}),c=this.createExtHostTreeView(l,_,n);return{get onDidCollapseElement(){return c.onDidCollapseElement},get onDidExpandElement(){return c.onDidExpandElement},get selection(){return c.selectedElements},get onDidChangeSelection(){return c.onDidChangeSelection},get visible(){return c.visible},get onDidChangeVisibility(){return c.onDidChangeVisibility},get message(){return c.message},set message(v){c.message=v},get title(){return c.title},set title(v){c.title=v},get description(){return c.description},set description(v){c.description=v},get badge(){return(0,h.checkProposedApiEnabled)(n,"badges"),c.badge},set badge(v){(0,h.checkProposedApiEnabled)(n,"badges"),c.badge=v},reveal:(v,g)=>c.reveal(v,g),dispose:async()=>{await t,this.treeViews.delete(l),c.dispose()}}}$getChildren(l,_){const n=this.treeViews.get(l);return n?n.getChildren(_):Promise.reject(new Error((0,s.localize)(0,null,l)))}async $handleDrop(l,_,n,u,i,o,r,t){const c=this.treeViews.get(l);if(!c)return Promise.reject(new Error((0,s.localize)(1,null,l)));const v=m.DataTransfer.toDataTransfer(n,async g=>(await this._proxy.$resolveDropFileData(l,_,g)).buffer);return r===l&&t&&await this.addAdditionalTransferItems(v,c,t,i,o),c.onDrop(v,u,i)}async addAdditionalTransferItems(l,_,n,u,i){const o=this.treeDragAndDropService.removeDragOperationTransfer(i);if(o)(await o)?.forEach((r,t)=>{r&&l.set(t,r)});else if(i&&_.handleDrag){const r=_.handleDrag(n,l,u);this.treeDragAndDropService.addDragOperationTransfer(i,r),await r}return l}async $handleDrag(l,_,n,u){const i=this.treeViews.get(l);if(!i)return Promise.reject(new Error((0,s.localize)(2,null,l)));const o=await this.addAdditionalTransferItems(new p.DataTransfer,i,_,u,n);if(!!o)return m.DataTransfer.toDataTransferDTO(o)}async $hasResolve(l){const _=this.treeViews.get(l);if(!_)throw new Error((0,s.localize)(3,null,l));return _.hasResolve}$resolve(l,_,n){const u=this.treeViews.get(l);if(!u)throw new Error((0,s.localize)(4,null,l));return u.resolveTreeItem(_,n)}$setExpanded(l,_,n){const u=this.treeViews.get(l);if(!u)throw new Error((0,s.localize)(5,null,l));u.setExpanded(_,n)}$setSelection(l,_){const n=this.treeViews.get(l);if(!n)throw new Error((0,s.localize)(6,null,l));n.setSelection(_)}$setVisible(l,_){const n=this.treeViews.get(l);if(!n)throw new Error((0,s.localize)(7,null,l));n.setVisible(_)}createExtHostTreeView(l,_,n){const u=new w(l,_,this._proxy,this.commands.converter,this.logService,n);return this.treeViews.set(l,u),u}convertArgument(l){const _=this.treeViews.get(l.$treeViewId);return _?_.getExtensionElement(l.$treeItemHandle):null}}e.ExtHostTreeViews=a;class w extends T.Disposable{constructor(l,_,n,u,i,o){super();if(this.viewId=l,this.proxy=n,this.commands=u,this.logService=i,this.extension=o,this.roots=void 0,this.elements=new Map,this.nodes=new Map,this._visible=!1,this._selectedHandles=[],this._onDidExpandElement=this._register(new C.Emitter),this.onDidExpandElement=this._onDidExpandElement.event,this._onDidCollapseElement=this._register(new C.Emitter),this.onDidCollapseElement=this._onDidCollapseElement.event,this._onDidChangeSelection=this._register(new C.Emitter),this.onDidChangeSelection=this._onDidChangeSelection.event,this._onDidChangeVisibility=this._register(new C.Emitter),this.onDidChangeVisibility=this._onDidChangeVisibility.event,this._onDidChangeData=this._register(new C.Emitter),this.refreshPromise=Promise.resolve(),this.refreshQueue=Promise.resolve(),this._message="",this._title="",this._refreshCancellationSource=new I.CancellationTokenSource,o.contributes&&o.contributes.views)for(const c in o.contributes.views)for(const v of o.contributes.views[c])v.id===l&&(this._title=v.name);this.dataProvider=_.treeDataProvider,this.dndController=_.dragAndDropController,this.dataProvider.onDidChangeTreeData&&this._register(this.dataProvider.onDidChangeTreeData(c=>this._onDidChangeData.fire({message:!1,element:c})));let r,t;this._register(C.Event.debounce(this._onDidChangeData.event,(c,v)=>(c||(c={message:!1,elements:[]}),v.element!==!1&&(r||(r=new Promise(g=>t=g),this.refreshPromise=this.refreshPromise.then(()=>r)),Array.isArray(v.element)?c.elements.push(...v.element):c.elements.push(v.element)),v.message&&(c.message=!0),c),200,!0)(({message:c,elements:v})=>{v.length&&(this.refreshQueue=this.refreshQueue.then(()=>{const g=t;return r=null,this.refresh(v).then(()=>g())})),c&&this.proxy.$setMessage(this.viewId,this._message)}))}get visible(){return this._visible}get selectedElements(){return this._selectedHandles.map(l=>this.getExtensionElement(l)).filter(l=>!(0,R.isUndefinedOrNull)(l))}async getChildren(l){const _=l?this.getExtensionElement(l):void 0;if(l&&!_)return this.logService.error(`No tree item with id '${l}' found.`),Promise.resolve([]);let n=this.getChildrenNodes(l);return n||(n=await this.fetchChildrenNodes(_)),n?n.map(u=>u.item):void 0}getExtensionElement(l){return this.elements.get(l)}reveal(l,_){_=_||{select:!0,focus:!1};const n=(0,R.isUndefinedOrNull)(_.select)?!0:_.select,u=(0,R.isUndefinedOrNull)(_.focus)?!1:_.focus,i=(0,R.isUndefinedOrNull)(_.expand)?!1:_.expand;return typeof this.dataProvider.getParent!="function"?Promise.reject(new Error("Required registered TreeDataProvider to implement 'getParent' method to access 'reveal' method")):l?this.refreshPromise.then(()=>this.resolveUnknownParentChain(l)).then(o=>this.resolveTreeNode(l,o[o.length-1]).then(r=>this.proxy.$reveal(this.viewId,{item:r.item,parentChain:o.map(t=>t.item)},{select:n,focus:u,expand:i})),o=>this.logService.error(o)):this.proxy.$reveal(this.viewId,void 0,{select:n,focus:u,expand:i})}get message(){return this._message}set message(l){this._message=l,this._onDidChangeData.fire({message:!0,element:!1})}get title(){return this._title}set title(l){this._title=l,this.proxy.$setTitle(this.viewId,l,this._description)}get description(){return this._description}set description(l){this._description=l,this.proxy.$setTitle(this.viewId,this._title,l)}get badge(){return this._badge}set badge(l){this._badge?.value===l?.value&&this._badge?.tooltip===l?.tooltip||(this._badge=m.ViewBadge.from(l),this.proxy.$setBadge(this.viewId,l))}setExpanded(l,_){const n=this.getExtensionElement(l);n&&(_?this._onDidExpandElement.fire(Object.freeze({element:n})):this._onDidCollapseElement.fire(Object.freeze({element:n})))}setSelection(l){(0,y.equals)(this._selectedHandles,l)||(this._selectedHandles=l,this._onDidChangeSelection.fire(Object.freeze({selection:this.selectedElements})))}setVisible(l){l!==this._visible&&(this._visible=l,this._onDidChangeVisibility.fire(Object.freeze({visible:this._visible})))}async handleDrag(l,_,n){const u=[];for(const i of l){const o=this.getExtensionElement(i);o&&u.push(o)}if(!(!this.dndController?.handleDrag||u.length===0))return await this.dndController.handleDrag(u,_,n),_}get hasHandleDrag(){return!!this.dndController?.handleDrag}async onDrop(l,_,n){const u=_?this.getExtensionElement(_):void 0;if(!(!u&&_||!this.dndController?.handleDrop))return(0,E.asPromise)(()=>this.dndController?.handleDrop?this.dndController.handleDrop(u,l,n):void 0)}get hasResolve(){return!!this.dataProvider.resolveTreeItem}async resolveTreeItem(l,_){if(!this.dataProvider.resolveTreeItem)return;const n=this.elements.get(l);if(n){const u=this.nodes.get(n);if(u){const i=await this.dataProvider.resolveTreeItem(u.extensionItem,n,_)??u.extensionItem;return this.validateTreeItem(i),u.item.tooltip=this.getTooltip(i.tooltip),u.item.command=this.getCommand(u.disposableStore,i.command),u.item}}}resolveUnknownParentChain(l){return this.resolveParent(l).then(_=>_?this.resolveUnknownParentChain(_).then(n=>this.resolveTreeNode(_,n[n.length-1]).then(u=>(n.push(u),n))):Promise.resolve([]))}resolveParent(l){const _=this.nodes.get(l);return _?Promise.resolve(_.parent?this.elements.get(_.parent.item.handle):void 0):(0,E.asPromise)(()=>this.dataProvider.getParent(l))}resolveTreeNode(l,_){const n=this.nodes.get(l);return n?Promise.resolve(n):(0,E.asPromise)(()=>this.dataProvider.getTreeItem(l)).then(u=>this.createHandle(l,u,_,!0)).then(u=>this.getChildren(_?_.item.handle:void 0).then(()=>{const i=this.getExtensionElement(u);if(i){const o=this.nodes.get(i);if(o)return Promise.resolve(o)}throw new Error(`Cannot resolve tree item for element ${u}`)}))}getChildrenNodes(l){if(l){let _;if(typeof l=="string"){const n=this.getExtensionElement(l);_=n?this.nodes.get(n):void 0}else _=l;return _&&_.children||void 0}return this.roots}async fetchChildrenNodes(l){this.clearChildren(l);const _=new I.CancellationTokenSource(this._refreshCancellationSource.token);try{const n=l?this.nodes.get(l):void 0,u=await this.dataProvider.getChildren(l);if(_.token.isCancellationRequested)return;const i=await Promise.all((0,y.coalesce)(u||[]).map(async o=>{const r=await this.dataProvider.getTreeItem(o);return r&&!_.token.isCancellationRequested?this.createAndRegisterTreeNode(o,r,n):null}));return _.token.isCancellationRequested?void 0:(0,y.coalesce)(i)}finally{_.dispose()}}refresh(l){if(l.some(n=>!n))return this._refreshCancellationSource.dispose(!0),this._refreshCancellationSource=new I.CancellationTokenSource,this.clearAll(),this.proxy.$refresh(this.viewId);{const n=this.getHandlesToRefresh(l);if(n.length)return this.refreshHandles(n)}return Promise.resolve(void 0)}getHandlesToRefresh(l){const _=new Set,n=l.map(i=>this.nodes.get(i));for(const i of n)if(i&&!_.has(i.item.handle)){let o=i;for(;o&&o.parent&&n.findIndex(r=>o&&o.parent&&r&&r.item.handle===o.parent.item.handle)===-1;){const r=this.elements.get(o.parent.item.handle);o=r?this.nodes.get(r):void 0}o&&!o.parent&&_.add(i.item.handle)}const u=[];return _.forEach(i=>{const o=this.elements.get(i);if(o){const r=this.nodes.get(o);r&&(!r.parent||!_.has(r.parent.item.handle))&&u.push(i)}}),u}refreshHandles(l){const _={};return Promise.all(l.map(n=>this.refreshNode(n).then(u=>{u&&(_[n]=u.item)}))).then(()=>Object.keys(_).length?this.proxy.$refresh(this.viewId,_):void 0)}refreshNode(l){const _=this.getExtensionElement(l);if(_){const n=this.nodes.get(_);if(n)return this.clearChildren(_),(0,E.asPromise)(()=>this.dataProvider.getTreeItem(_)).then(u=>{if(u){const i=this.createTreeNode(_,u,n.parent);return this.updateNodeCache(_,i,n,n.parent),n.dispose(),i}return null})}return Promise.resolve(null)}createAndRegisterTreeNode(l,_,n){const u=this.createTreeNode(l,_,n);if(_.id&&this.elements.has(u.item.handle))throw new Error((0,s.localize)(8,null,_.id));return this.addNodeToCache(l,u),this.addNodeToParentCache(u,n),u}getTooltip(l){return A.MarkdownString.isMarkdownString(l)?m.MarkdownString.from(l):l}getCommand(l,_){return _?this.commands.toInternal(_,l):void 0}validateTreeItem(l){A.TreeItem.isTreeItem(l)||console.log(`Extension ${this.extension.identifier.value} has provided an invalid tree item.`)}createTreeNode(l,_,n){this.validateTreeItem(_);const u=new T.DisposableStore,i=this.createHandle(l,_,n),o=this.getLightIconPath(_);return{item:{handle:i,parentHandle:n?n.item.handle:void 0,label:d(_.label,this.extension),description:_.description,resourceUri:_.resourceUri,tooltip:this.getTooltip(_.tooltip),command:this.getCommand(u,_.command),contextValue:_.contextValue,icon:o,iconDark:this.getDarkIconPath(_)||o,themeIcon:this.getThemeIcon(_),collapsibleState:(0,R.isUndefinedOrNull)(_.collapsibleState)?A.TreeItemCollapsibleState.None:_.collapsibleState,accessibilityInformation:_.accessibilityInformation},extensionItem:_,parent:n,children:void 0,disposableStore:u,dispose(){u.dispose()}}}getThemeIcon(l){return l.iconPath instanceof A.ThemeIcon?l.iconPath:void 0}createHandle(l,{id:_,label:n,resourceUri:u},i,o){if(_)return`${w.ID_HANDLE_PREFIX}/${_}`;const r=d(n,this.extension),t=i?i.item.handle:w.LABEL_HANDLE_PREFIX;let c=r?r.label:u?(0,b.basename)(u):"";c=c.indexOf("/")!==-1?c.replace("/","//"):c;const v=this.nodes.has(l)?this.nodes.get(l).item.handle:void 0,g=this.getChildrenNodes(i)||[];let D,U=0;do{if(D=`${t}/${U}:${c}`,o||!this.elements.has(D)||v===D)break;U++}while(U<=g.length);return D}getLightIconPath(l){if(l.iconPath&&!(l.iconPath instanceof A.ThemeIcon))return typeof l.iconPath=="string"||L.URI.isUri(l.iconPath)?this.getIconPath(l.iconPath):this.getIconPath(l.iconPath.light)}getDarkIconPath(l){if(l.iconPath&&!(l.iconPath instanceof A.ThemeIcon)&&l.iconPath.dark)return this.getIconPath(l.iconPath.dark)}getIconPath(l){return L.URI.isUri(l)?l:L.URI.file(l)}addNodeToCache(l,_){this.elements.set(_.item.handle,l),this.nodes.set(l,_)}updateNodeCache(l,_,n,u){this.elements.delete(_.item.handle),this.nodes.delete(l),_.item.handle!==n.item.handle&&this.elements.delete(n.item.handle),this.addNodeToCache(l,_);const i=this.getChildrenNodes(u)||[],o=i.filter(r=>r.item.handle===n.item.handle)[0];o&&i.splice(i.indexOf(o),1,_)}addNodeToParentCache(l,_){_?(_.children||(_.children=[]),_.children.push(l)):(this.roots||(this.roots=[]),this.roots.push(l))}clearChildren(l){if(l){const _=this.nodes.get(l);if(_){if(_.children)for(const n of _.children){const u=this.elements.get(n.item.handle);u&&this.clear(u)}_.children=void 0}}else this.clearAll()}clear(l){const _=this.nodes.get(l);if(_){if(_.children)for(const n of _.children){const u=this.elements.get(n.item.handle);u&&this.clear(u)}this.nodes.delete(l),this.elements.delete(_.item.handle),_.dispose()}}clearAll(){this.roots=void 0,this.elements.clear(),this.nodes.forEach(l=>l.dispose()),this.nodes.clear()}dispose(){this._refreshCancellationSource.dispose(),this.clearAll()}}w.LABEL_HANDLE_PREFIX="0",w.ID_HANDLE_PREFIX="1"}),define(ye[235],Ce([1,0,20,11,4,29,2,120,245,115,114,39,5,94,189,188,36,190,32,192,193,194,173,195,49,33,197,198,201,203,205,98,176,209,210,211,69,52,213,234,8,6,216,53,97,31,163,200,85,95,100,102,103,14,63,15,28,206,160,62,68,186,214,70,51,219,217,218,187,35,212,215,67,50,86,207,99,208,12,81,175,158,199,7,24,165,9]),function(ee,e,s,p,b,L,C,T,E,A,R,y,m,I,f,h,d,a,w,P,l,_,n,u,i,o,r,t,c,v,g,D,U,W,M,S,z,$,N,K,V,F,ne,ce,re,fe,ie,Ee,be,te,ve,Re,Fe,$e,Ye,Ie,Se,Te,ae,le,X,J,k,B,H,j,oe,ue,Z,pe,ge,Ne,Be,Ze,Ke,ke,nt,G,Q,he,Ue,We,et,je,He,it,rt){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.createApiFactoryAndRegisterActors=void 0;function dt(lt){const st=lt.get(Se.IExtHostInitDataService),yt=lt.get(pe.IExtHostFileSystemInfo),Ot=lt.get(H.IExtHostConsumerFileSystem),Ft=lt.get(o.IExtHostExtensionService),ft=lt.get(fe.IExtHostWorkspace),Dt=lt.get(Ke.IExtHostTelemetry),Ut=lt.get(w.IExtHostConfiguration),Nt=lt.get(Ye.IURITransformerService),Ve=lt.get(Ie.IExtHostRpcService),Mt=lt.get(z.IExtHostStorage),At=lt.get(B.IExtensionStoragePaths),Lt=lt.get($e.ILoggerService),gt=lt.get($e.ILogService),It=lt.get(le.IExtHostTunnelService),we=lt.get(X.IExtHostApiDeprecationService),De=lt.get(re.IExtHostWindow),me=lt.get(Be.IExtHostSecretState),q=lt.get(Ze.IExtHostEditorTabs);Ve.set(m.ExtHostContext.ExtHostFileSystemInfo,yt),Ve.set(m.ExtHostContext.ExtHostLogLevelServiceShape,Lt),Ve.set(m.ExtHostContext.ExtHostWorkspace,ft),Ve.set(m.ExtHostContext.ExtHostConfiguration,Ut),Ve.set(m.ExtHostContext.ExtHostExtensionService,Ft),Ve.set(m.ExtHostContext.ExtHostStorage,Mt),Ve.set(m.ExtHostContext.ExtHostTunnelService,It),Ve.set(m.ExtHostContext.ExtHostWindow,De),Ve.set(m.ExtHostContext.ExtHostSecretState,me),Ve.set(m.ExtHostContext.ExtHostTelemetry,Dt),Ve.set(m.ExtHostContext.ExtHostEditorTabs,q);const Pe=Ve.set(m.ExtHostContext.ExtHostDecorations,lt.get(te.IExtHostDecorations)),Le=Ve.set(m.ExtHostContext.ExtHostDocumentsAndEditors,lt.get(i.IExtHostDocumentsAndEditors)),Xe=Ve.set(m.ExtHostContext.ExtHostCommands,lt.get(d.IExtHostCommands)),Qe=Ve.set(m.ExtHostContext.ExtHostTerminalService,lt.get($.IExtHostTerminalService)),Ge=Ve.set(m.ExtHostContext.ExtHostDebugService,lt.get(Re.IExtHostDebugService)),pt=Ve.set(m.ExtHostContext.ExtHostSearch,lt.get(Fe.IExtHostSearch)),bt=Ve.set(m.ExtHostContext.ExtHostTask,lt.get(ve.IExtHostTask)),kt=Ve.set(m.ExtHostContext.ExtHostOutputService,lt.get(D.IExtHostOutputService)),Et=Ve.set(m.ExtHostContext.ExtHostUrls,new ne.ExtHostUrls(Ve)),ht=Ve.set(m.ExtHostContext.ExtHostDocuments,new u.ExtHostDocuments(Ve,Le)),Rt=Ve.set(m.ExtHostContext.ExtHostDocumentContentProviders,new _.ExtHostDocumentContentProvider(Ve,Le,gt)),_t=Ve.set(m.ExtHostContext.ExtHostDocumentSaveParticipant,new n.ExtHostDocumentSaveParticipant(gt,ht,Ve.getProxy(m.MainContext.MainThreadBulkEdits))),vt=Ve.set(m.ExtHostContext.ExtHostNotebook,new Te.ExtHostNotebookController(Ve,Xe,Le,ht,At)),Gt=Ve.set(m.ExtHostContext.ExtHostNotebookDocuments,new We.ExtHostNotebookDocuments(vt)),Xt=Ve.set(m.ExtHostContext.ExtHostNotebookEditors,new Ue.ExtHostNotebookEditors(gt,vt)),Ht=Ve.set(m.ExtHostContext.ExtHostNotebookKernels,new ke.ExtHostNotebookKernels(Ve,st,vt,Xe,gt)),Vt=Ve.set(m.ExtHostContext.ExtHostNotebookRenderers,new G.ExtHostNotebookRenderers(Ve,vt)),Tt=Ve.set(m.ExtHostContext.ExtHostEditors,new N.ExtHostEditors(Ve,Le)),_i=Ve.set(m.ExtHostContext.ExtHostTreeViews,new K.ExtHostTreeViews(Ve.getProxy(m.MainContext.MainThreadTreeViews),Xe,gt)),hi=Ve.set(m.ExtHostContext.ExtHostEditorInsets,new ie.ExtHostEditorInsets(Ve.getProxy(m.MainContext.MainThreadEditorInsets),Tt,st.remote)),zt=Ve.set(m.ExtHostContext.ExtHostDiagnostics,new P.ExtHostDiagnostics(Ve,gt,yt)),ei=Ve.set(m.ExtHostContext.ExtHostLanguages,new v.ExtHostLanguages(Ve,ht,Xe.converter,Nt)),ut=Ve.set(m.ExtHostContext.ExtHostLanguageFeatures,new c.ExtHostLanguageFeatures(Ve,Nt,ht,Xe,zt,gt,we)),fi=Ve.set(m.ExtHostContext.ExtHostFileSystem,new r.ExtHostFileSystem(Ve,ut)),xt=Ve.set(m.ExtHostContext.ExtHostFileSystemEventService,new t.ExtHostFileSystemEventService(Ve,gt,Le)),Qt=Ve.set(m.ExtHostContext.ExtHostQuickOpen,(0,W.createExtHostQuickOpen)(Ve,ft,Xe)),ri=Ve.set(m.ExtHostContext.ExtHostSCM,new M.ExtHostSCM(Ve,Xe,gt)),mi=Ve.set(m.ExtHostContext.ExtHostComments,(0,a.createExtHostComments)(Ve,Xe,ht)),si=Ve.set(m.ExtHostContext.ExtHostProgress,new U.ExtHostProgress(Ve.getProxy(m.MainContext.MainThreadProgress))),Ti=Ve.set(m.ExtHostContext.ExtHosLabelService,new Ee.ExtHostLabelService(Ve)),Si=Ve.set(m.ExtHostContext.ExtHostTheming,new ae.ExtHostTheming(Ve)),ti=Ve.set(m.ExtHostContext.ExtHostAuthentication,new J.ExtHostAuthentication(Ve)),gi=Ve.set(m.ExtHostContext.ExtHostTimeline,new k.ExtHostTimeline(Ve,Xe)),ii=Ve.set(m.ExtHostContext.ExtHostWebviews,new ce.ExtHostWebviews(Ve,st.remote,ft,gt,we)),ni=Ve.set(m.ExtHostContext.ExtHostWebviewPanels,new ue.ExtHostWebviewPanels(Ve,ii,ft)),Pi=Ve.set(m.ExtHostContext.ExtHostCustomEditors,new oe.ExtHostCustomEditors(Ve,ht,At,ii,ni)),pi=Ve.set(m.ExtHostContext.ExtHostWebviewViews,new j.ExtHostWebviewViews(Ve,ii)),Yt=Ve.set(m.ExtHostContext.ExtHostTesting,new ge.ExtHostTesting(Ve,Xe)),Ai=Ve.set(m.ExtHostContext.ExtHostUriOpeners,new Ne.ExtHostUriOpeners(Ve));Ve.set(m.ExtHostContext.ExtHostInteractive,new et.ExtHostInteractive(Ve,vt,Le,Xe,gt));const Ri=Object.values(m.ExtHostContext);Ve.assertRegistered(Ri);const Oi=new Z.ExtHostBulkEdits(Ve,Le),Fi=new h.ExtHostClipboard(Ve),vi=new g.ExtHostMessageService(Ve,gt),yi=new l.ExtHostDialogs(Ve),oi=new S.ExtHostStatusBar(Ve,Xe.converter);return f.ExtHostApiCommands.register(Xe),function(Me,jt,Di){const mt=function(){let se=!Me.isUnderDevelopment;function de(){se||(gt.info(`Extension '${Me.identifier.value}' uses a document selector without scheme. Learn more about this: https://go.microsoft.com/fwlink/?linkid=872305`),se=!0)}return function Oe(ot){if(Array.isArray(ot))ot.forEach(Oe);else if(typeof ot=="string")de();else{const wt=ot;typeof wt.scheme=="undefined"&&de(),typeof wt.exclusive=="boolean"&&(0,He.checkProposedApiEnabled)(Me,"documentFiltersExclusive")}return ot}}(),ai={getSession(se,de,Oe){return ti.getSession(Me,se,de,Oe)},async hasSession(se,de){return(0,He.checkProposedApiEnabled)(Me,"authSession"),!!await ti.getSession(Me,se,de,{silent:!0})},get onDidChangeSessions(){return ti.onDidChangeSessions},registerAuthenticationProvider(se,de,Oe,ot){return ti.registerAuthenticationProvider(se,de,Oe,ot)}},Ni={registerCommand(se,de,Oe){return Xe.registerCommand(!0,se,de,Oe,void 0,Me)},registerTextEditorCommand(se,de,Oe){return Xe.registerCommand(!0,se,(...ot)=>{const wt=Tt.getActiveTextEditor();if(!wt){gt.warn("Cannot execute "+se+" because there is no active text editor.");return}return wt.edit(Ct=>{de.apply(Oe,[wt,Ct,...ot])}).then(Ct=>{Ct||gt.warn("Edits from command "+se+" were not applied.")},Ct=>{gt.warn("An error occurred while running command "+se,Ct)})},void 0,void 0,Me)},registerDiffInformationCommand:(se,de,Oe)=>((0,He.checkProposedApiEnabled)(Me,"diffCommand"),Xe.registerCommand(!0,se,async(...ot)=>{const wt=Le.activeEditor(!0);if(!wt){gt.warn("Cannot execute "+se+" because there is no active text editor.");return}const Ct=await Tt.getDiffInformation(wt.id);de.apply(Oe,[Ct,...ot])},void 0,void 0,Me)),executeCommand(se,...de){return Xe.executeCommand(se,...de)},getCommands(se=!1){return Xe.getCommands(se)}},Ci={get machineId(){return st.telemetryInfo.machineId},get sessionId(){return st.telemetryInfo.sessionId},get language(){return st.environment.appLanguage},get appName(){return st.environment.appName},get appRoot(){return st.environment.appRoot?.fsPath??""},get appHost(){return st.environment.appHost},get uriScheme(){return st.environment.appUriScheme},get clipboard(){return Fi.value},get shell(){return Qe.getDefaultShell(!1)},get isTelemetryEnabled(){return Dt.getTelemetryConfiguration()},get onDidChangeTelemetryEnabled(){return Dt.onDidChangeTelemetryEnabled},get telemetryConfiguration(){return(0,He.checkProposedApiEnabled)(Me,"telemetry"),Dt.getTelemetryDetails()},get onDidChangeTelemetryConfiguration(){return(0,He.checkProposedApiEnabled)(Me,"telemetry"),Dt.onDidChangeTelemetryConfiguration},get isNewAppInstall(){const se=Date.now()-new Date(st.telemetryInfo.firstSessionDate).getTime();return isNaN(se)?!1:se<1e3*60*60*24},openExternal(se,de){return De.openUri(se,{allowTunneling:!!st.remote.authority,allowContributedOpeners:de?.allowContributedOpeners})},async asExternalUri(se){if(se.scheme===st.environment.appUriScheme)return Et.createAppUri(se);try{return await De.asExternalUri(se,{allowTunneling:!!st.remote.authority})}catch(de){if((0,he.matchesScheme)(se,Q.Schemas.http)||(0,he.matchesScheme)(se,Q.Schemas.https))return se;throw de}},get remoteName(){return(0,be.getRemoteName)(st.remote.authority)},get remoteAuthority(){return(0,He.checkProposedApiEnabled)(Me,"resolvers"),st.remote.authority},get uiKind(){return st.uiKind}};st.environment.extensionTestsLocationURI||Object.freeze(Ci);const Mi={createTestController(se,de,Oe){return Yt.createTestController(se,de,Oe)},createTestObserver(){return(0,He.checkProposedApiEnabled)(Me,"testObserver"),Yt.createTestObserver()},runTests(se){return(0,He.checkProposedApiEnabled)(Me,"testObserver"),Yt.runTests(se)},get onDidChangeTestResults(){return(0,He.checkProposedApiEnabled)(Me,"testObserver"),Yt.onResultsChanged},get testResults(){return(0,He.checkProposedApiEnabled)(Me,"testObserver"),Yt.results}},ci=st.remote.isRemote?F.ExtensionKind.Workspace:F.ExtensionKind.UI,Ei={getExtension(se,de){(0,rt.equalsIgnoreCase)(se,"ms-vscode.references-view")&&(we.report("The extension 'ms-vscode.references-view' has been renamed.",Me,"Use 'vscode.references-view' instead."),se="vscode.references-view"),(0,He.isProposedApiEnabled)(Me,"extensionsAny")||(de=!1);const Oe=jt.mine.getExtensionDescription(se);if(Oe)return new o.Extension(Ft,Me.identifier,Oe,ci,!1);if(de){const ot=jt.all.getExtensionDescription(se);if(ot)return new o.Extension(Ft,Me.identifier,ot,ci,!0)}},get all(){const se=[];for(const de of jt.mine.getAllExtensionDescriptions())se.push(new o.Extension(Ft,Me.identifier,de,ci,!1));return se},get allAcrossExtensionHosts(){(0,He.checkProposedApiEnabled)(Me,"extensionsAny");const se=new He.ExtensionIdentifierSet(jt.mine.getAllExtensionDescriptions().map(Oe=>Oe.identifier)),de=[];for(const Oe of jt.all.getAllExtensionDescriptions()){const ot=!se.has(Oe.identifier);de.push(new o.Extension(Ft,Me.identifier,Oe,ci,ot))}return de},get onDidChange(){return(0,He.isProposedApiEnabled)(Me,"extensionsAny")?b.Event.any(jt.mine.onDidChange,jt.all.onDidChange):jt.mine.onDidChange}},Li={createDiagnosticCollection(se){return zt.createDiagnosticCollection(Me.identifier,se)},get onDidChangeDiagnostics(){return zt.onDidChangeDiagnostics},getDiagnostics:se=>zt.getDiagnostics(se),getLanguages(){return ei.getLanguages()},setTextDocumentLanguage(se,de){return ei.changeLanguage(se.uri,de)},match(se,de){const Oe=ht.getDocumentData(de.uri)?.notebook;return(0,R.score)(V.LanguageSelector.from(se),de.uri,de.languageId,!0,Oe?.uri,Oe?.notebookType)},registerCodeActionsProvider(se,de,Oe){return ut.registerCodeActionProvider(Me,mt(se),de,Oe)},registerDocumentPasteEditProvider(se,de,Oe){return(0,He.checkProposedApiEnabled)(Me,"documentPaste"),ut.registerDocumentPasteEditProvider(Me,mt(se),de,Oe)},registerCodeLensProvider(se,de){return ut.registerCodeLensProvider(Me,mt(se),de)},registerDefinitionProvider(se,de){return ut.registerDefinitionProvider(Me,mt(se),de)},registerDeclarationProvider(se,de){return ut.registerDeclarationProvider(Me,mt(se),de)},registerImplementationProvider(se,de){return ut.registerImplementationProvider(Me,mt(se),de)},registerTypeDefinitionProvider(se,de){return ut.registerTypeDefinitionProvider(Me,mt(se),de)},registerHoverProvider(se,de){return ut.registerHoverProvider(Me,mt(se),de,Me.identifier)},registerEvaluatableExpressionProvider(se,de){return ut.registerEvaluatableExpressionProvider(Me,mt(se),de,Me.identifier)},registerInlineValuesProvider(se,de){return ut.registerInlineValuesProvider(Me,mt(se),de,Me.identifier)},registerDocumentHighlightProvider(se,de){return ut.registerDocumentHighlightProvider(Me,mt(se),de)},registerLinkedEditingRangeProvider(se,de){return ut.registerLinkedEditingRangeProvider(Me,mt(se),de)},registerReferenceProvider(se,de){return ut.registerReferenceProvider(Me,mt(se),de)},registerRenameProvider(se,de){return ut.registerRenameProvider(Me,mt(se),de)},registerDocumentSymbolProvider(se,de,Oe){return ut.registerDocumentSymbolProvider(Me,mt(se),de,Oe)},registerWorkspaceSymbolProvider(se){return ut.registerWorkspaceSymbolProvider(Me,se)},registerDocumentFormattingEditProvider(se,de){return ut.registerDocumentFormattingEditProvider(Me,mt(se),de)},registerDocumentRangeFormattingEditProvider(se,de){return ut.registerDocumentRangeFormattingEditProvider(Me,mt(se),de)},registerOnTypeFormattingEditProvider(se,de,Oe,...ot){return ut.registerOnTypeFormattingEditProvider(Me,mt(se),de,[Oe].concat(ot))},registerDocumentSemanticTokensProvider(se,de,Oe){return ut.registerDocumentSemanticTokensProvider(Me,mt(se),de,Oe)},registerDocumentRangeSemanticTokensProvider(se,de,Oe){return ut.registerDocumentRangeSemanticTokensProvider(Me,mt(se),de,Oe)},registerSignatureHelpProvider(se,de,Oe,...ot){return typeof Oe=="object"?ut.registerSignatureHelpProvider(Me,mt(se),de,Oe):ut.registerSignatureHelpProvider(Me,mt(se),de,typeof Oe=="undefined"?[]:[Oe,...ot])},registerCompletionItemProvider(se,de,...Oe){return ut.registerCompletionItemProvider(Me,mt(se),de,Oe)},registerInlineCompletionItemProvider(se,de){return de.handleDidShowCompletionItem&&(0,He.checkProposedApiEnabled)(Me,"inlineCompletionsAdditions"),ut.registerInlineCompletionsProvider(Me,mt(se),de)},registerInlineCompletionItemProviderNew(se,de){if((0,He.checkProposedApiEnabled)(Me,"inlineCompletionsNew"),de.handleDidShowCompletionItem&&!(0,He.isProposedApiEnabled)(Me,"inlineCompletionsAdditions"))throw new Error(`When the method "handleDidShowCompletionItem" is implemented on a provider, the usage of the proposed api 'inlineCompletionsAdditions' must be declared!`);return ut.registerInlineCompletionsProviderNew(Me,mt(se),de)},registerDocumentLinkProvider(se,de){return ut.registerDocumentLinkProvider(Me,mt(se),de)},registerColorProvider(se,de){return ut.registerColorProvider(Me,mt(se),de)},registerFoldingRangeProvider(se,de){return ut.registerFoldingRangeProvider(Me,mt(se),de)},registerSelectionRangeProvider(se,de){return ut.registerSelectionRangeProvider(Me,se,de)},registerCallHierarchyProvider(se,de){return ut.registerCallHierarchyProvider(Me,se,de)},registerTypeHierarchyProvider(se,de){return ut.registerTypeHierarchyProvider(Me,se,de)},setLanguageConfiguration:(se,de)=>ut.setLanguageConfiguration(Me,se,de),getTokenInformationAtPosition(se,de){return(0,He.checkProposedApiEnabled)(Me,"tokenInformation"),ei.tokenAtPosition(se,de)},registerInlayHintsProvider(se,de){return ut.registerInlayHintsProvider(Me,se,de)},createLanguageStatusItem(se,de){return ei.createLanguageStatusItem(Me,se,de)},registerDocumentDropEditProvider(se,de){return ut.registerDocumentOnDropEditProvider(Me,se,de)}},$t={get activeTextEditor(){return Tt.getActiveTextEditor()},get visibleTextEditors(){return Tt.getVisibleTextEditors()},get activeTerminal(){return Qe.activeTerminal},get terminals(){return Qe.terminals},async showTextDocument(se,de,Oe){const ot=await(C.URI.isUri(se)?Promise.resolve(qt.openTextDocument(se)):Promise.resolve(se));return Tt.showTextDocument(ot,de,Oe)},createTextEditorDecorationType(se){return Tt.createTextEditorDecorationType(Me,se)},onDidChangeActiveTextEditor(se,de,Oe){return Tt.onDidChangeActiveTextEditor(se,de,Oe)},onDidChangeVisibleTextEditors(se,de,Oe){return Tt.onDidChangeVisibleTextEditors(se,de,Oe)},onDidChangeTextEditorSelection(se,de,Oe){return Tt.onDidChangeTextEditorSelection(se,de,Oe)},onDidChangeTextEditorOptions(se,de,Oe){return Tt.onDidChangeTextEditorOptions(se,de,Oe)},onDidChangeTextEditorVisibleRanges(se,de,Oe){return Tt.onDidChangeTextEditorVisibleRanges(se,de,Oe)},onDidChangeTextEditorViewColumn(se,de,Oe){return Tt.onDidChangeTextEditorViewColumn(se,de,Oe)},onDidCloseTerminal(se,de,Oe){return Qe.onDidCloseTerminal(se,de,Oe)},onDidOpenTerminal(se,de,Oe){return Qe.onDidOpenTerminal(se,de,Oe)},onDidChangeActiveTerminal(se,de,Oe){return Qe.onDidChangeActiveTerminal(se,de,Oe)},onDidChangeTerminalDimensions(se,de,Oe){return(0,He.checkProposedApiEnabled)(Me,"terminalDimensions"),Qe.onDidChangeTerminalDimensions(se,de,Oe)},onDidChangeTerminalState(se,de,Oe){return Qe.onDidChangeTerminalState(se,de,Oe)},onDidWriteTerminalData(se,de,Oe){return(0,He.checkProposedApiEnabled)(Me,"terminalDataWriteEvent"),Qe.onDidWriteTerminalData(se,de,Oe)},get state(){return De.state},onDidChangeWindowState(se,de,Oe){return De.onDidChangeWindowState(se,de,Oe)},showInformationMessage(se,...de){return vi.showMessage(Me,L.default.Info,se,de[0],de.slice(1))},showWarningMessage(se,...de){return vi.showMessage(Me,L.default.Warning,se,de[0],de.slice(1))},showErrorMessage(se,...de){return vi.showMessage(Me,L.default.Error,se,de[0],de.slice(1))},showQuickPick(se,de,Oe){return Qt.showQuickPick(se,de,Oe)},showWorkspaceFolderPick(se){return Qt.showWorkspaceFolderPick(se)},showInputBox(se,de){return Qt.showInput(se,de)},showOpenDialog(se){return yi.showOpenDialog(se)},showSaveDialog(se){return yi.showSaveDialog(se)},createStatusBarItem(se,de,Oe){let ot,wt,Ct;return typeof se=="string"?(ot=se,wt=de,Ct=Oe):(wt=se,Ct=de),oi.createStatusBarEntry(Me,ot,wt,Ct)},setStatusBarMessage(se,de){return oi.setStatusBarMessage(se,de)},withScmProgress(se){return we.report("window.withScmProgress",Me,"Use 'withProgress' instead."),si.withProgress(Me,{location:F.ProgressLocation.SourceControl},(de,Oe)=>se({report(ot){}}))},withProgress(se,de){return si.withProgress(Me,se,de)},createOutputChannel(se,de){return kt.createOutputChannel(se,de,Me)},createWebviewPanel(se,de,Oe,ot){return ni.createWebviewPanel(Me,se,de,Oe,ot)},createWebviewTextEditorInset(se,de,Oe,ot){return(0,He.checkProposedApiEnabled)(Me,"editorInsets"),hi.createWebviewEditorInset(se,de,Oe,ot,Me)},createTerminal(se,de,Oe){return typeof se=="object"?"pty"in se?Qe.createExtensionTerminal(se):Qe.createTerminalFromOptions(se):Qe.createTerminal(se,de,Oe)},registerTerminalLinkProvider(se){return Qe.registerLinkProvider(se)},registerTerminalProfileProvider(se,de){return Qe.registerProfileProvider(Me,se,de)},registerTreeDataProvider(se,de){return _i.registerTreeDataProvider(se,de,Me)},createTreeView(se,de){return _i.createTreeView(se,de,Me)},registerWebviewPanelSerializer:(se,de)=>ni.registerWebviewPanelSerializer(Me,se,de),registerCustomEditorProvider:(se,de,Oe={})=>Pi.registerCustomEditorProvider(Me,se,de,Oe),registerFileDecorationProvider(se){return Pe.registerFileDecorationProvider(se,Me.identifier)},registerUriHandler(se){return Et.registerUriHandler(Me.identifier,se)},createQuickPick(){return Qt.createQuickPick(Me)},createInputBox(){return Qt.createInputBox(Me)},get activeColorTheme(){return Si.activeColorTheme},onDidChangeActiveColorTheme(se,de,Oe){return Si.onDidChangeActiveColorTheme(se,de,Oe)},registerWebviewViewProvider(se,de,Oe){return pi.registerWebviewViewProvider(Me,se,de,Oe?.webviewOptions)},get activeNotebookEditor(){return vt.activeNotebookEditor},onDidChangeActiveNotebookEditor(se,de,Oe){return vt.onDidChangeActiveNotebookEditor(se,de,Oe)},get visibleNotebookEditors(){return vt.visibleNotebookEditors},get onDidChangeVisibleNotebookEditors(){return vt.onDidChangeVisibleNotebookEditors},onDidChangeNotebookEditorSelection(se,de,Oe){return Xt.onDidChangeNotebookEditorSelection(se,de,Oe)},onDidChangeNotebookEditorVisibleRanges(se,de,Oe){return Xt.onDidChangeNotebookEditorVisibleRanges(se,de,Oe)},showNotebookDocument(se,de){return C.URI.isUri(se)&&we.report("window.showNotebookDocument(uri)",Me,"Please use 'workspace.openNotebookDocument' and 'window.showNotebookDocument'"),vt.showNotebookDocument(se,de)},registerExternalUriOpener(se,de,Oe){return(0,He.checkProposedApiEnabled)(Me,"externalUriOpener"),Ai.registerExternalUriOpener(Me.identifier,se,de,Oe)},get tabGroups(){return q.tabGroups}},qt={get rootPath(){return we.report("workspace.rootPath",Me,"Please use 'workspace.workspaceFolders' instead. More details: https://aka.ms/vscode-eliminating-rootpath"),ft.getPath()},set rootPath(se){throw p.readonly()},getWorkspaceFolder(se){return ft.getWorkspaceFolder(se)},get workspaceFolders(){return ft.getWorkspaceFolders()},get name(){return ft.name},set name(se){throw p.readonly()},get workspaceFile(){return ft.workspaceFile},set workspaceFile(se){throw p.readonly()},updateWorkspaceFolders:(se,de,...Oe)=>ft.updateWorkspaceFolders(Me,se,de||0,...Oe),onDidChangeWorkspaceFolders:function(se,de,Oe){return ft.onDidChangeWorkspace(se,de,Oe)},asRelativePath:(se,de)=>ft.getRelativePath(se,de),findFiles:(se,de,Oe,ot)=>ft.findFiles(se,de,Oe,Me.identifier,ot),findTextInFiles:(se,de,Oe,ot)=>{(0,He.checkProposedApiEnabled)(Me,"findTextInFiles");let wt,Ct;return typeof de=="object"?(wt=de,Ct=Oe):(wt={},Ct=de,ot=Oe),ft.findTextInFiles(se,wt||{},Ct,Me.identifier,ot)},saveAll:se=>ft.saveAll(se),applyEdit(se){return Oi.applyWorkspaceEdit(se,Me)},createFileSystemWatcher:(se,de,Oe,ot)=>xt.createFileSystemWatcher(ft,Me,se,de,Oe,ot),get textDocuments(){return ht.getAllDocumentData().map(se=>se.document)},set textDocuments(se){throw p.readonly()},openTextDocument(se){let de;const Oe=se;if(typeof se=="string")de=Promise.resolve(C.URI.file(se));else if(C.URI.isUri(se))de=Promise.resolve(se);else if(!Oe||typeof Oe=="object")de=ht.createDocumentData(Oe);else throw new Error("illegal argument - uriOrFileNameOrOptions");return de.then(ot=>ht.ensureDocumentData(ot).then(wt=>wt.document))},onDidOpenTextDocument:(se,de,Oe)=>ht.onDidAddDocument(se,de,Oe),onDidCloseTextDocument:(se,de,Oe)=>ht.onDidRemoveDocument(se,de,Oe),onDidChangeTextDocument:(se,de,Oe)=>ht.onDidChangeDocument(se,de,Oe),onDidSaveTextDocument:(se,de,Oe)=>ht.onDidSaveDocument(se,de,Oe),onWillSaveTextDocument:(se,de,Oe)=>_t.getOnWillSaveTextDocumentEvent(Me)(se,de,Oe),get notebookDocuments(){return vt.notebookDocuments.map(se=>se.apiNotebook)},async openNotebookDocument(se,de){let Oe;if(C.URI.isUri(se))Oe=se,await vt.openNotebookDocument(se);else if(typeof se=="string")Oe=C.URI.revive(await vt.createNotebookDocument({viewType:se,content:de}));else throw new Error("Invalid arguments");return vt.getNotebookDocument(Oe).apiNotebook},onDidSaveNotebookDocument(se,de,Oe){return Gt.onDidSaveNotebookDocument(se,de,Oe)},onDidChangeNotebookDocument(se,de,Oe){return Gt.onDidChangeNotebookDocument(se,de,Oe)},get onDidOpenNotebookDocument(){return vt.onDidOpenNotebookDocument},get onDidCloseNotebookDocument(){return vt.onDidCloseNotebookDocument},registerNotebookSerializer(se,de,Oe,ot){return vt.registerNotebookSerializer(Me,se,de,Oe,(0,He.isProposedApiEnabled)(Me,"notebookLiveShare")?ot:void 0)},registerNotebookContentProvider:(se,de,Oe,ot)=>((0,He.checkProposedApiEnabled)(Me,"notebookContentProvider"),we.report("workspace.registerNotebookContentProvider",Me,"The notebookContentProvider API is not on track for finalization and will be removed."),vt.registerNotebookContentProvider(Me,se,de,Oe,(0,He.isProposedApiEnabled)(Me,"notebookLiveShare")?ot:void 0)),onDidChangeConfiguration:(se,de,Oe)=>Di.onDidChangeConfiguration(se,de,Oe),getConfiguration(se,de){return de=arguments.length===1?void 0:de,Di.getConfiguration(se,de,Me)},registerTextDocumentContentProvider(se,de){return Rt.registerTextDocumentContentProvider(se,de)},registerTaskProvider:(se,de)=>(we.report("window.registerTaskProvider",Me,"Use the corresponding function on the 'tasks' namespace instead"),bt.registerTaskProvider(Me,se,de)),registerFileSystemProvider(se,de,Oe){return(0,je.combinedDisposable)(fi.registerFileSystemProvider(Me,se,de,Oe),Ot.addFileSystemProvider(se,de))},get fs(){return Ot.value},registerFileSearchProvider:(se,de)=>((0,He.checkProposedApiEnabled)(Me,"fileSearchProvider"),pt.registerFileSearchProvider(se,de)),registerTextSearchProvider:(se,de)=>((0,He.checkProposedApiEnabled)(Me,"textSearchProvider"),pt.registerTextSearchProvider(se,de)),registerRemoteAuthorityResolver:(se,de)=>((0,He.checkProposedApiEnabled)(Me,"resolvers"),Ft.registerRemoteAuthorityResolver(se,de)),registerResourceLabelFormatter:se=>((0,He.checkProposedApiEnabled)(Me,"resolvers"),Ti.$registerResourceLabelFormatter(se)),onDidCreateFiles:(se,de,Oe)=>xt.onDidCreateFile(se,de,Oe),onDidDeleteFiles:(se,de,Oe)=>xt.onDidDeleteFile(se,de,Oe),onDidRenameFiles:(se,de,Oe)=>xt.onDidRenameFile(se,de,Oe),onWillCreateFiles:(se,de,Oe)=>xt.getOnWillCreateFileEvent(Me)(se,de,Oe),onWillDeleteFiles:(se,de,Oe)=>xt.getOnWillDeleteFileEvent(Me)(se,de,Oe),onWillRenameFiles:(se,de,Oe)=>xt.getOnWillRenameFileEvent(Me)(se,de,Oe),openTunnel:se=>((0,He.checkProposedApiEnabled)(Me,"resolvers"),It.openTunnel(Me,se).then(de=>{if(!de)throw new Error("cannot open tunnel");return de})),get tunnels(){return(0,He.checkProposedApiEnabled)(Me,"resolvers"),It.getTunnels()},onDidChangeTunnels:(se,de,Oe)=>((0,He.checkProposedApiEnabled)(Me,"resolvers"),It.onDidChangeTunnels(se,de,Oe)),registerPortAttributesProvider:(se,de)=>((0,He.checkProposedApiEnabled)(Me,"portsAttributes"),It.registerPortsAttributesProvider(se,de)),registerTimelineProvider:(se,de)=>((0,He.checkProposedApiEnabled)(Me,"timeline"),gi.registerTimelineProvider(se,de,Me.identifier,Xe.converter)),get isTrusted(){return ft.trusted},requestWorkspaceTrust:se=>((0,He.checkProposedApiEnabled)(Me,"workspaceTrust"),ft.requestWorkspaceTrust(se)),onDidGrantWorkspaceTrust:(se,de,Oe)=>ft.onDidGrantWorkspaceTrust(se,de,Oe)},Ui={get inputBox(){return we.report("scm.inputBox",Me,"Use 'SourceControl.inputBox' instead"),ri.getLastInputBox(Me)},createSourceControl(se,de,Oe){return ri.createSourceControl(Me,se,de,Oe)}},Bt={createCommentController(se,de){return mi.createCommentController(Me,se,de)}},li={get activeDebugSession(){return Ge.activeDebugSession},get activeDebugConsole(){return Ge.activeDebugConsole},get breakpoints(){return Ge.breakpoints},onDidStartDebugSession(se,de,Oe){return Ge.onDidStartDebugSession(se,de,Oe)},onDidTerminateDebugSession(se,de,Oe){return Ge.onDidTerminateDebugSession(se,de,Oe)},onDidChangeActiveDebugSession(se,de,Oe){return Ge.onDidChangeActiveDebugSession(se,de,Oe)},onDidReceiveDebugSessionCustomEvent(se,de,Oe){return Ge.onDidReceiveDebugSessionCustomEvent(se,de,Oe)},onDidChangeBreakpoints(se,de,Oe){return Ge.onDidChangeBreakpoints(se,de,Oe)},registerDebugConfigurationProvider(se,de,Oe){return Ge.registerDebugConfigurationProvider(se,de,Oe||it.DebugConfigurationProviderTriggerKind.Initial)},registerDebugAdapterDescriptorFactory(se,de){return Ge.registerDebugAdapterDescriptorFactory(Me,se,de)},registerDebugAdapterTrackerFactory(se,de){return Ge.registerDebugAdapterTrackerFactory(se,de)},startDebugging(se,de,Oe){return!Oe||typeof Oe=="object"&&"configuration"in Oe?Ge.startDebugging(se,de,{parentSession:Oe}):Ge.startDebugging(se,de,Oe||{})},stopDebugging(se){return Ge.stopDebugging(se)},addBreakpoints(se){return Ge.addBreakpoints(se)},removeBreakpoints(se){return Ge.removeBreakpoints(se)},asDebugSourceUri(se,de){return Ge.asDebugSourceUri(se,de)}},Bi={registerTaskProvider:(se,de)=>bt.registerTaskProvider(Me,se,de),fetchTasks:se=>bt.fetchTasks(se),executeTask:se=>bt.executeTask(Me,se),get taskExecutions(){return bt.taskExecutions},onDidStartTask:(se,de,Oe)=>bt.onDidStartTask(se,de,Oe),onDidEndTask:(se,de,Oe)=>bt.onDidEndTask(se,de,Oe),onDidStartTaskProcess:(se,de,Oe)=>bt.onDidStartTaskProcess(se,de,Oe),onDidEndTaskProcess:(se,de,Oe)=>bt.onDidEndTaskProcess(se,de,Oe)},zi={createNotebookController(se,de,Oe,ot,wt){return Ht.createNotebookController(Me,se,de,Oe,ot,(0,He.isProposedApiEnabled)(Me,"notebookMessaging")?wt:void 0)},registerNotebookCellStatusBarItemProvider:(se,de)=>vt.registerNotebookCellStatusBarItemProvider(Me,se,de),createRendererMessaging(se){return Vt.createRendererMessaging(Me,se)},onDidChangeNotebookCellExecutionState(se,de,Oe){return(0,He.checkProposedApiEnabled)(Me,"notebookCellExecutionState"),Ht.onDidChangeNotebookCellExecutionState(se,de,Oe)}};return{version:st.version,authentication:ai,commands:Ni,comments:Bt,debug:li,env:Ci,extensions:Ei,languages:Li,notebooks:zi,scm:Ui,tasks:Bi,tests:Mi,window:$t,workspace:qt,Breakpoint:F.Breakpoint,CallHierarchyIncomingCall:F.CallHierarchyIncomingCall,CallHierarchyItem:F.CallHierarchyItem,CallHierarchyOutgoingCall:F.CallHierarchyOutgoingCall,CancellationError:p.CancellationError,CancellationTokenSource:s.CancellationTokenSource,CandidatePortSource:m.CandidatePortSource,CodeAction:F.CodeAction,CodeActionKind:F.CodeActionKind,CodeActionTriggerKind:F.CodeActionTriggerKind,CodeLens:F.CodeLens,Color:F.Color,ColorInformation:F.ColorInformation,ColorPresentation:F.ColorPresentation,ColorThemeKind:F.ColorThemeKind,CommentMode:F.CommentMode,CommentThreadCollapsibleState:F.CommentThreadCollapsibleState,CommentThreadState:F.CommentThreadState,CompletionItem:F.CompletionItem,CompletionItemKind:F.CompletionItemKind,CompletionItemTag:F.CompletionItemTag,CompletionList:F.CompletionList,CompletionTriggerKind:F.CompletionTriggerKind,ConfigurationTarget:F.ConfigurationTarget,CustomExecution:F.CustomExecution,DebugAdapterExecutable:F.DebugAdapterExecutable,DebugAdapterInlineImplementation:F.DebugAdapterInlineImplementation,DebugAdapterNamedPipeServer:F.DebugAdapterNamedPipeServer,DebugAdapterServer:F.DebugAdapterServer,DebugConfigurationProviderTriggerKind:it.DebugConfigurationProviderTriggerKind,DebugConsoleMode:F.DebugConsoleMode,DecorationRangeBehavior:F.DecorationRangeBehavior,Diagnostic:F.Diagnostic,DiagnosticRelatedInformation:F.DiagnosticRelatedInformation,DiagnosticSeverity:F.DiagnosticSeverity,DiagnosticTag:F.DiagnosticTag,Disposable:F.Disposable,DocumentHighlight:F.DocumentHighlight,DocumentHighlightKind:F.DocumentHighlightKind,DocumentLink:F.DocumentLink,DocumentSymbol:F.DocumentSymbol,EndOfLine:F.EndOfLine,EnvironmentVariableMutatorType:F.EnvironmentVariableMutatorType,EvaluatableExpression:F.EvaluatableExpression,InlineValueText:F.InlineValueText,InlineValueVariableLookup:F.InlineValueVariableLookup,InlineValueEvaluatableExpression:F.InlineValueEvaluatableExpression,InlineCompletionTriggerKind:F.InlineCompletionTriggerKind,InlineCompletionTriggerKindNew:F.InlineCompletionTriggerKindNew,EventEmitter:b.Emitter,ExtensionKind:F.ExtensionKind,ExtensionMode:F.ExtensionMode,ExternalUriOpenerPriority:F.ExternalUriOpenerPriority,FileChangeType:F.FileChangeType,FileDecoration:F.FileDecoration,FileSystemError:F.FileSystemError,FileType:y.FileType,FilePermission:y.FilePermission,FoldingRange:F.FoldingRange,FoldingRangeKind:F.FoldingRangeKind,FunctionBreakpoint:F.FunctionBreakpoint,InlineCompletionItem:F.InlineSuggestion,InlineCompletionItemNew:F.InlineSuggestionNew,InlineCompletionList:F.InlineSuggestionList,InlineCompletionListNew:F.InlineSuggestionsNew,Hover:F.Hover,IndentAction:A.IndentAction,Location:F.Location,MarkdownString:F.MarkdownString,OverviewRulerLane:E.OverviewRulerLane,ParameterInformation:F.ParameterInformation,PortAutoForwardAction:F.PortAutoForwardAction,Position:F.Position,ProcessExecution:F.ProcessExecution,ProgressLocation:F.ProgressLocation,QuickInputButtons:F.QuickInputButtons,Range:F.Range,RelativePattern:F.RelativePattern,Selection:F.Selection,SelectionRange:F.SelectionRange,SemanticTokens:F.SemanticTokens,SemanticTokensBuilder:F.SemanticTokensBuilder,SemanticTokensEdit:F.SemanticTokensEdit,SemanticTokensEdits:F.SemanticTokensEdits,SemanticTokensLegend:F.SemanticTokensLegend,ShellExecution:F.ShellExecution,ShellQuoting:F.ShellQuoting,SignatureHelp:F.SignatureHelp,SignatureHelpTriggerKind:F.SignatureHelpTriggerKind,SignatureInformation:F.SignatureInformation,SnippetString:F.SnippetString,SourceBreakpoint:F.SourceBreakpoint,StandardTokenType:F.StandardTokenType,StatusBarAlignment:F.StatusBarAlignment,SymbolInformation:F.SymbolInformation,SymbolKind:F.SymbolKind,SymbolTag:F.SymbolTag,Task:F.Task,TaskGroup:F.TaskGroup,TaskPanelKind:F.TaskPanelKind,TaskRevealKind:F.TaskRevealKind,TaskScope:F.TaskScope,TerminalLink:F.TerminalLink,TerminalLocation:F.TerminalLocation,TerminalProfile:F.TerminalProfile,TextDocumentSaveReason:F.TextDocumentSaveReason,TextEdit:F.TextEdit,TextEditorCursorStyle:T.TextEditorCursorStyle,TextEditorLineNumbersStyle:F.TextEditorLineNumbersStyle,TextEditorRevealType:F.TextEditorRevealType,TextEditorSelectionChangeKind:F.TextEditorSelectionChangeKind,TextDocumentChangeReason:F.TextDocumentChangeReason,ThemeColor:F.ThemeColor,ThemeIcon:F.ThemeIcon,TreeItem:F.TreeItem,TreeItemCollapsibleState:F.TreeItemCollapsibleState,TypeHierarchyItem:F.TypeHierarchyItem,UIKind:I.UIKind,Uri:C.URI,ViewColumn:F.ViewColumn,WorkspaceEdit:F.WorkspaceEdit,DocumentDropEdit:F.DocumentDropEdit,DocumentPasteEdit:F.DocumentPasteEdit,InlayHint:F.InlayHint,InlayHintLabelPart:F.InlayHintLabelPart,InlayHintKind:F.InlayHintKind,RemoteAuthorityResolverError:F.RemoteAuthorityResolverError,ResolvedAuthority:F.ResolvedAuthority,SourceControlInputBoxValidationType:F.SourceControlInputBoxValidationType,ExtensionRuntime:F.ExtensionRuntime,TimelineItem:F.TimelineItem,NotebookRange:F.NotebookRange,NotebookCellKind:F.NotebookCellKind,NotebookCellExecutionState:F.NotebookCellExecutionState,NotebookCellData:F.NotebookCellData,NotebookData:F.NotebookData,NotebookRendererScript:F.NotebookRendererScript,NotebookCellStatusBarAlignment:F.NotebookCellStatusBarAlignment,NotebookEditorRevealType:F.NotebookEditorRevealType,NotebookCellOutput:F.NotebookCellOutput,NotebookCellOutputItem:F.NotebookCellOutputItem,NotebookCellStatusBarItem:F.NotebookCellStatusBarItem,NotebookControllerAffinity:F.NotebookControllerAffinity,NotebookEdit:F.NotebookEdit,PortAttributes:F.PortAttributes,LinkedEditingRanges:F.LinkedEditingRanges,TestResultState:F.TestResultState,TestRunRequest:F.TestRunRequest,TestMessage:F.TestMessage,TestTag:F.TestTag,TestRunProfileKind:F.TestRunProfileKind,TextSearchCompleteMessageType:nt.TextSearchCompleteMessageType,DataTransfer:F.DataTransfer,DataTransferItem:F.DataTransferItem,CoveredCount:F.CoveredCount,FileCoverage:F.FileCoverage,StatementCoverage:F.StatementCoverage,BranchCoverage:F.BranchCoverage,FunctionCoverage:F.FunctionCoverage,WorkspaceTrustState:F.WorkspaceTrustState,LanguageStatusSeverity:F.LanguageStatusSeverity,QuickPickItemKind:F.QuickPickItemKind,InputBoxValidationSeverity:F.InputBoxValidationSeverity,TabInputText:F.TextTabInput,TabInputTextDiff:F.TextDiffTabInput,TabInputTextMerge:F.TextMergeTabInput,TabInputCustom:F.CustomEditorTabInput,TabInputNotebook:F.NotebookEditorTabInput,TabInputNotebookDiff:F.NotebookDiffEditorTabInput,TabInputWebview:F.WebviewEditorTabInput,TabInputTerminal:F.TerminalEditorTabInput,TabInputInteractiveWindow:F.InteractiveWindowInput,TerminalExitReason:F.TerminalExitReason}}}e.createApiFactoryAndRegisterActors=dt}),define(ye[236],Ce([1,0,235,33,2,229,6,13,220]),function(ee,e,s,p,b,L,C,T,E){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.ExtHostExtensionService=void 0;class A extends L.RequireInterceptor{_installInterceptor(){}getModule(I,f){for(const h of this._alternatives){const d=h(I);if(d){I=d;break}}if(this._factories.has(I))return this._factories.get(I).load(I,f,()=>{throw new Error("CANNOT LOAD MODULE from here.")})}}class R extends p.AbstractExtHostExtensionService{constructor(){super(...arguments);this.extensionRuntime=C.ExtensionRuntime.Webworker}async _beforeAlmostReadyToRunExtensions(){this._instaService.createInstance(E.ExtHostConsoleForwarder);const I=this._instaService.invokeFunction(s.createApiFactoryAndRegisterActors);this._fakeModules=this._instaService.createInstance(A,I,{mine:this._myRegistry,all:this._globalRegistry}),await this._fakeModules.install(),performance.mark("code/extHost/didInitAPI"),await this._waitForDebuggerAttachment()}_getEntryPoint(I){return I.browser}async _loadCommonJSModule(I,f,h){f=f.with({path:y(f.path,".js")}),I&&performance.mark(`code/extHost/willFetchExtensionCode/${I.value}`);const d=b.URI.revive(await this._mainThreadExtensionsProxy.$asBrowserUri(f)),a=await fetch(d.toString(!0));if(I&&performance.mark(`code/extHost/didFetchExtensionCode/${I.value}`),a.status!==200)throw new Error(a.statusText);const w=await a.text(),P=`${f.toString(!0)}#vscode-extension`,l=`${w}
//# sourceURL=${P}`;let _;try{_=new Function("module","exports","require",l)}catch(o){throw console.error(I?`Loading code for extension ${I.value} failed: ${o.message}`:`Loading code failed: ${o.message}`),console.error(`${f.toString(!0)}${typeof o.line=="number"?` line ${o.line}`:""}${typeof o.column=="number"?` column ${o.column}`:""}`),console.error(o),o}const n={},u={exports:n},i=o=>{const r=this._fakeModules.getModule(o,f);if(r===void 0)throw new Error(`Cannot load module '${o}'`);return r};try{return h.codeLoadingStart(),I&&performance.mark(`code/extHost/willLoadExtensionCode/${I.value}`),_(u,n,i),u.exports!==n?u.exports:n}finally{I&&performance.mark(`code/extHost/didLoadExtensionCode/${I.value}`),h.codeLoadingStop()}}async $setRemoteEnvironment(I){}async _waitForDebuggerAttachment(I=5e3){if(!this._initData.environment.isExtensionDevelopmentDebug)return;const f=Date.now()+I;for(;Date.now()<f&&!("__jsDebugIsReady"in globalThis);)await(0,T.timeout)(10)}}e.ExtHostExtensionService=R;function y(m,I){return m.endsWith(I)?m:m+I}}),define(ye[237],Ce([1,0,56,33,70,236]),function(ee,e,s,p,b,L){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),(0,s.registerSingleton)(p.IExtHostExtensionService,L.ExtHostExtensionService),(0,s.registerSingleton)(b.IExtensionStoragePaths,b.ExtensionStoragePaths)}),define(ye[246],Ce([1,0,22,4,94,230,222,19,71,12,2,232,237]),function(ee,e,s,p,b,L,C,T,E,A,R){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.create=void 0;const y=self.close.bind(self);self.close=()=>console.trace("'close' has been blocked");const m=postMessage.bind(self);self.postMessage=()=>console.trace("'postMessage' has been blocked");function I(n){return/^(file|vscode-remote):/i.test(n)}const f=fetch.bind(self);function h(n){self.fetch=async function(u,i){return u instanceof Request||I(String(u))&&(u=(await n(R.URI.parse(String(u)))).toString(!0)),f(u,i)},self.XMLHttpRequest=class extends XMLHttpRequest{open(u,i,o,r,t){(async()=>{I(i.toString())&&(i=(await n(R.URI.parse(i.toString()))).toString(!0)),super.open(u,i,o??!0,r,t)})()}}}if(self.importScripts=()=>{throw new Error("'importScripts' has been blocked")},self.addEventListener=()=>console.trace("'addEventListener' has been blocked"),self.AMDLoader=void 0,self.NLSLoaderPlugin=void 0,self.define=void 0,self.require=void 0,self.webkitRequestFileSystem=void 0,self.webkitRequestFileSystemSync=void 0,self.webkitResolveLocalFileSystemSyncURL=void 0,self.webkitResolveLocalFileSystemURL=void 0,self.Worker){const n=self.Worker;Worker=function(u,i){if(/^file:/i.test(u.toString()))u=A.FileAccess.asBrowserUri(R.URI.parse(u.toString())).toString(!0);else if(/^vscode-remote:/i.test(u.toString()))throw new Error("Creating workers from remote extensions is currently not supported.");const r=`(${function(g){function D(M){return typeof M=="string"||M instanceof URL?String(M).replace(/^file:\/\//i,"vscode-file://vscode-app"):M}const U=fetch.bind(self);self.fetch=function(M,S){return M instanceof Request?U(M,S):U(D(M),S)},self.XMLHttpRequest=class extends XMLHttpRequest{open(M,S,z,$,N){return super.open(M,D(S),z??!0,$,N)}};const W=importScripts.bind(self);self.importScripts=(...M)=>{W(...M.map(D))},W(g)}.toString()}('${u}'))`;i=i||{},i.name=i.name||T.basename(u.toString());const t=new Blob([r],{type:"application/javascript"}),c=URL.createObjectURL(t);return new n(c,i)}}else self.Worker=class extends C.NestedWorker{constructor(n,u){super(m,n,{name:T.basename(n.toString()),...u})}};const d=new class{constructor(){this.pid=void 0}exit(n){y()}async exists(n){return!0}async realpath(n){return n}};class a{constructor(){const u=new MessageChannel,i=new p.Emitter;let o=!1;m(u.port2,[u.port2]),u.port1.onmessage=r=>{const{data:t}=r;if(!(t instanceof ArrayBuffer)){console.warn("UNKNOWN data received",t);return}const c=s.VSBuffer.wrap(new Uint8Array(t,0,t.byteLength));if((0,b.isMessageOfType)(c,2)){o=!0,P("received terminate message from renderer");return}i.fire(c)},this.protocol={onMessage:i.event,send:r=>{if(!o){const t=r.buffer.buffer.slice(r.buffer.byteOffset,r.buffer.byteOffset+r.buffer.byteLength);u.port1.postMessage(t,[t])}}}}}function w(n){return new Promise(u=>{const i=n.onMessage(o=>{i.dispose();const r=JSON.parse(o.toString());n.send((0,b.createMessageOfType)(0)),u({protocol:n,initData:r})});n.send((0,b.createMessageOfType)(1))})}let P=n=>y();function l(n){return!!n&&typeof n=="object"&&n.type==="vscode.init"&&n.data instanceof Map}function _(){E.mark("code/extHost/willConnectToRenderer");const n=new a;return{onmessage(u){!l(u)||w(n.protocol).then(i=>{E.mark("code/extHost/didWaitForInitData");const o=new L.ExtensionHostMain(i.protocol,i.initData,d,null,u.data);h(r=>o.asBrowserUri(r)),P=r=>o.terminate(r)})}}}e.create=_})}).call(this);
//# sourceMappingURL=extensionHostWorker.js.map