/usr/share/grafana/public/build
"use strict";(self.webpackChunkgrafana=self.webpackChunkgrafana||[]).push([[7396],{104:(rt,ye,y)=>{y.d(ye,{W5:()=>u,dr:()=>T,hB:()=>d,lt:()=>P,wC:()=>l});var b=y(16844),o=y(82862),K=y(15365),$=y(50442),L=y(66055);const U=999;class P{constructor(C,m,v,k){this.searchString=C,this.isRegex=m,this.matchCase=v,this.wordSeparators=k}parseSearchRequest(){if(this.searchString==="")return null;let C;this.isRegex?C=B(this.searchString):C=this.searchString.indexOf(` `)>=0;let m=null;try{m=b.OS(this.searchString,this.isRegex,{matchCase:this.matchCase,wholeWord:!1,multiline:C,global:!0,unicode:!0})}catch{return null}if(!m)return null;let v=!this.isRegex&&!C;return v&&this.searchString.toLowerCase()!==this.searchString.toUpperCase()&&(v=this.matchCase),new L.L5(m,this.wordSeparators?(0,o.i)(this.wordSeparators):null,v?this.searchString:null)}}function B(w){if(!w||w.length===0)return!1;for(let C=0,m=w.length;C<m;C++){const v=w.charCodeAt(C);if(v===10)return!0;if(v===92){if(C++,C>=m)break;const k=w.charCodeAt(C);if(k===110||k===114||k===87)return!0}}return!1}function T(w,C,m){if(!m)return new L.Dg(w,null);const v=[];for(let k=0,D=C.length;k<D;k++)v[k]=C[k];return new L.Dg(w,v)}class p{constructor(C){const m=[];let v=0;for(let k=0,D=C.length;k<D;k++)C.charCodeAt(k)===10&&(m[v++]=k);this._lineFeedsOffsets=m}findLineFeedCountBeforeOffset(C){const m=this._lineFeedsOffsets;let v=0,k=m.length-1;if(k===-1||C<=m[0])return 0;for(;v<k;){const D=v+((k-v)/2>>0);m[D]>=C?k=D-1:m[D+1]>=C?(v=D,k=D):v=D+1}return v+1}}class d{static findMatches(C,m,v,k,D){const x=m.parseSearchRequest();return x?x.regex.multiline?this._doFindMatchesMultiline(C,v,new u(x.wordSeparators,x.regex),k,D):this._doFindMatchesLineByLine(C,v,x,k,D):[]}static _getMultilineMatchRange(C,m,v,k,D,x){let A,W=0;k?(W=k.findLineFeedCountBeforeOffset(D),A=m+D+W):A=m+D;let Y;if(k){const X=k.findLineFeedCountBeforeOffset(D+x.length)-W;Y=A+x.length+X}else Y=A+x.length;const ne=C.getPositionAt(A),j=C.getPositionAt(Y);return new $.Q(ne.lineNumber,ne.column,j.lineNumber,j.column)}static _doFindMatchesMultiline(C,m,v,k,D){const x=C.getOffsetAt(m.getStartPosition()),A=C.getValueInRange(m,1),W=C.getEOL()===`\r `?new p(A):null,Y=[];let ne=0,j;for(v.reset(0);j=v.next(A);)if(Y[ne++]=T(this._getMultilineMatchRange(C,x,A,W,j.index,j[0]),j,k),ne>=D)return Y;return Y}static _doFindMatchesLineByLine(C,m,v,k,D){const x=[];let A=0;if(m.startLineNumber===m.endLineNumber){const Y=C.getLineContent(m.startLineNumber).substring(m.startColumn-1,m.endColumn-1);return A=this._findMatchesInLine(v,Y,m.startLineNumber,m.startColumn-1,A,x,k,D),x}const W=C.getLineContent(m.startLineNumber).substring(m.startColumn-1);A=this._findMatchesInLine(v,W,m.startLineNumber,m.startColumn-1,A,x,k,D);for(let Y=m.startLineNumber+1;Y<m.endLineNumber&&A<D;Y++)A=this._findMatchesInLine(v,C.getLineContent(Y),Y,0,A,x,k,D);if(A<D){const Y=C.getLineContent(m.endLineNumber).substring(0,m.endColumn-1);A=this._findMatchesInLine(v,Y,m.endLineNumber,0,A,x,k,D)}return x}static _findMatchesInLine(C,m,v,k,D,x,A,W){const Y=C.wordSeparators;if(!A&&C.simpleSearch){const Q=C.simpleSearch,X=Q.length,R=m.length;let H=-X;for(;(H=m.indexOf(Q,H+X))!==-1;)if((!Y||l(Y,m,R,H,X))&&(x[D++]=new L.Dg(new $.Q(v,H+1+k,v,H+1+X+k),null),D>=W))return D;return D}const ne=new u(C.wordSeparators,C.regex);let j;ne.reset(0);do if(j=ne.next(m),j&&(x[D++]=T(new $.Q(v,j.index+1+k,v,j.index+1+j[0].length+k),j,A),D>=W))return D;while(j);return D}static findNextMatch(C,m,v,k){const D=m.parseSearchRequest();if(!D)return null;const x=new u(D.wordSeparators,D.regex);return D.regex.multiline?this._doFindNextMatchMultiline(C,v,x,k):this._doFindNextMatchLineByLine(C,v,x,k)}static _doFindNextMatchMultiline(C,m,v,k){const D=new K.y(m.lineNumber,1),x=C.getOffsetAt(D),A=C.getLineCount(),W=C.getValueInRange(new $.Q(D.lineNumber,D.column,A,C.getLineMaxColumn(A)),1),Y=C.getEOL()===`\r `?new p(W):null;v.reset(m.column-1);const ne=v.next(W);return ne?T(this._getMultilineMatchRange(C,x,W,Y,ne.index,ne[0]),ne,k):m.lineNumber!==1||m.column!==1?this._doFindNextMatchMultiline(C,new K.y(1,1),v,k):null}static _doFindNextMatchLineByLine(C,m,v,k){const D=C.getLineCount(),x=m.lineNumber,A=C.getLineContent(x),W=this._findFirstMatchInLine(v,A,x,m.column,k);if(W)return W;for(let Y=1;Y<=D;Y++){const ne=(x+Y-1)%D,j=C.getLineContent(ne+1),Q=this._findFirstMatchInLine(v,j,ne+1,1,k);if(Q)return Q}return null}static _findFirstMatchInLine(C,m,v,k,D){C.reset(k-1);const x=C.next(m);return x?T(new $.Q(v,x.index+1,v,x.index+1+x[0].length),x,D):null}static findPreviousMatch(C,m,v,k){const D=m.parseSearchRequest();if(!D)return null;const x=new u(D.wordSeparators,D.regex);return D.regex.multiline?this._doFindPreviousMatchMultiline(C,v,x,k):this._doFindPreviousMatchLineByLine(C,v,x,k)}static _doFindPreviousMatchMultiline(C,m,v,k){const D=this._doFindMatchesMultiline(C,new $.Q(1,1,m.lineNumber,m.column),v,k,10*U);if(D.length>0)return D[D.length-1];const x=C.getLineCount();return m.lineNumber!==x||m.column!==C.getLineMaxColumn(x)?this._doFindPreviousMatchMultiline(C,new K.y(x,C.getLineMaxColumn(x)),v,k):null}static _doFindPreviousMatchLineByLine(C,m,v,k){const D=C.getLineCount(),x=m.lineNumber,A=C.getLineContent(x).substring(0,m.column-1),W=this._findLastMatchInLine(v,A,x,k);if(W)return W;for(let Y=1;Y<=D;Y++){const ne=(D+x-Y-1)%D,j=C.getLineContent(ne+1),Q=this._findLastMatchInLine(v,j,ne+1,k);if(Q)return Q}return null}static _findLastMatchInLine(C,m,v,k){let D=null,x;for(C.reset(0);x=C.next(m);)D=T(new $.Q(v,x.index+1,v,x.index+1+x[0].length),x,k);return D}}function g(w,C,m,v,k){if(v===0)return!0;const D=C.charCodeAt(v-1);if(w.get(D)!==0||D===13||D===10)return!0;if(k>0){const x=C.charCodeAt(v);if(w.get(x)!==0)return!0}return!1}function h(w,C,m,v,k){if(v+k===m)return!0;const D=C.charCodeAt(v+k);if(w.get(D)!==0||D===13||D===10)return!0;if(k>0){const x=C.charCodeAt(v+k-1);if(w.get(x)!==0)return!0}return!1}function l(w,C,m,v,k){return g(w,C,m,v,k)&&h(w,C,m,v,k)}class u{constructor(C,m){this._wordSeparators=C,this._searchRegex=m,this._prevMatchStartIndex=-1,this._prevMatchLength=0}reset(C){this._searchRegex.lastIndex=C,this._prevMatchStartIndex=-1,this._prevMatchLength=0}next(C){const m=C.length;let v;do{if(this._prevMatchStartIndex+this._prevMatchLength===m||(v=this._searchRegex.exec(C),!v))return null;const k=v.index,D=v[0].length;if(k===this._prevMatchStartIndex&&D===this._prevMatchLength){if(D===0){b.Z5(C,m,this._searchRegex.lastIndex)>65535?this._searchRegex.lastIndex+=2:this._searchRegex.lastIndex+=1;continue}return null}if(this._prevMatchStartIndex=k,this._prevMatchLength=D,!this._wordSeparators||l(this._wordSeparators,C,m,k,D))return v}while(v);return null}}},648:(rt,ye,y)=>{y.d(ye,{T:()=>Pt});var b=y(3765),o=y(14333),K=y(87110),$=y(5043),L=y(86843),U=y(65958),P=y(2106),B=y(10998),T=y(25837),p=y(80878),d=y(87301),g=y(76680),h=y(77439),l=y(63781),u=y(50350),w=y(50946),C=y(66476),m=y(57445),v=y(15365),k=y(48295),D=y(39723),x=y(11608),A=y(96655),W=y(4874),Y=y(89044),ne=y(26048),j=y(11210),Q=y(77922),X=function(St,ve,Te,je){var nt=arguments.length,at=nt<3?ve:je===null?je=Object.getOwnPropertyDescriptor(ve,Te):je,vt;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")at=Reflect.decorate(St,ve,Te,je);else for(var It=St.length-1;It>=0;It--)(vt=St[It])&&(at=(nt<3?vt(at):nt>3?vt(ve,Te,at):vt(ve,Te))||at);return nt>3&&at&&Object.defineProperty(ve,Te,at),at},R=function(St,ve){return function(Te,je){ve(Te,je,St)}},H=function(St,ve,Te,je){function nt(at){return at instanceof Te?at:new Te(function(vt){vt(at)})}return new(Te||(Te=Promise))(function(at,vt){function It(kt){try{wt(je.next(kt))}catch(Ct){vt(Ct)}}function At(kt){try{wt(je.throw(kt))}catch(Ct){vt(Ct)}}function wt(kt){kt.done?at(kt.value):nt(kt.value).then(It,At)}wt((je=je.apply(St,ve||[])).next())})},Z;const N=3;class G{constructor(ve,Te,je,nt){this.originalLineStart=ve,this.originalLineEnd=Te,this.modifiedLineStart=je,this.modifiedLineEnd=nt}getType(){return this.originalLineStart===0?1:this.modifiedLineStart===0?2:0}}class O{constructor(ve){this.entries=ve}}const te=(0,j.pU)("diff-review-insert",ne.W6.add,b.kg("diffReviewInsertIcon","Icon for 'Insert' in diff review.")),oe=(0,j.pU)("diff-review-remove",ne.W6.remove,b.kg("diffReviewRemoveIcon","Icon for 'Remove' in diff review.")),ue=(0,j.pU)("diff-review-close",ne.W6.close,b.kg("diffReviewCloseIcon","Icon for 'Close' in diff review."));let E=class go extends B.jG{constructor(ve,Te){super(),this._languageService=Te,this._width=0,this._diffEditor=ve,this._isVisible=!1,this.shadow=(0,$.Z)(document.createElement("div")),this.shadow.setClassName("diff-review-shadow"),this.actionBarContainer=(0,$.Z)(document.createElement("div")),this.actionBarContainer.setClassName("diff-review-actions"),this._actionBar=this._register(new h.E(this.actionBarContainer.domNode)),this._actionBar.push(new u.rc("diffreview.close",b.kg("label.close","Close"),"close-diff-review "+Y.L0.asClassName(ue),!0,()=>H(this,void 0,void 0,function*(){return this.hide()})),{label:!1,icon:!0}),this.domNode=(0,$.Z)(document.createElement("div")),this.domNode.setClassName("diff-review monaco-editor-background"),this._content=(0,$.Z)(document.createElement("div")),this._content.setClassName("diff-review-content"),this._content.setAttribute("role","code"),this.scrollbar=this._register(new l.MU(this._content.domNode,{})),this.domNode.domNode.appendChild(this.scrollbar.getDomNode()),this._register(ve.onDidUpdateDiff(()=>{this._isVisible&&(this._diffs=this._compute(),this._render())})),this._register(ve.getModifiedEditor().onDidChangeCursorPosition(()=>{this._isVisible&&this._render()})),this._register(o.b2(this.domNode.domNode,"click",je=>{je.preventDefault();const nt=o.m1(je.target,"diff-review-row");nt&&this._goToRow(nt)})),this._register(o.b2(this.domNode.domNode,"keydown",je=>{(je.equals(18)||je.equals(2066)||je.equals(530))&&(je.preventDefault(),this._goToRow(this._getNextRow())),(je.equals(16)||je.equals(2064)||je.equals(528))&&(je.preventDefault(),this._goToRow(this._getPrevRow())),(je.equals(9)||je.equals(2057)||je.equals(521)||je.equals(1033))&&(je.preventDefault(),this.hide()),(je.equals(10)||je.equals(3))&&(je.preventDefault(),this.accept())})),this._diffs=[],this._currentDiff=null}prev(){let ve=0;if(this._isVisible||(this._diffs=this._compute()),this._isVisible){let je=-1;for(let nt=0,at=this._diffs.length;nt<at;nt++)if(this._diffs[nt]===this._currentDiff){je=nt;break}ve=this._diffs.length+je-1}else ve=this._findDiffIndex(this._diffEditor.getPosition());if(this._diffs.length===0)return;ve=ve%this._diffs.length;const Te=this._diffs[ve].entries;this._diffEditor.setPosition(new v.y(Te[0].modifiedLineStart,1)),this._diffEditor.setSelection({startColumn:1,startLineNumber:Te[0].modifiedLineStart,endColumn:1073741824,endLineNumber:Te[Te.length-1].modifiedLineEnd}),this._isVisible=!0,this._diffEditor.doLayout(),this._render(),this._goToRow(this._getNextRow())}next(){let ve=0;if(this._isVisible||(this._diffs=this._compute()),this._isVisible){let je=-1;for(let nt=0,at=this._diffs.length;nt<at;nt++)if(this._diffs[nt]===this._currentDiff){je=nt;break}ve=je+1}else ve=this._findDiffIndex(this._diffEditor.getPosition());if(this._diffs.length===0)return;ve=ve%this._diffs.length;const Te=this._diffs[ve].entries;this._diffEditor.setPosition(new v.y(Te[0].modifiedLineStart,1)),this._diffEditor.setSelection({startColumn:1,startLineNumber:Te[0].modifiedLineStart,endColumn:1073741824,endLineNumber:Te[Te.length-1].modifiedLineEnd}),this._isVisible=!0,this._diffEditor.doLayout(),this._render(),this._goToRow(this._getNextRow())}accept(){let ve=-1;const Te=this._getCurrentFocusedRow();if(Te){const je=parseInt(Te.getAttribute("data-line"),10);isNaN(je)||(ve=je)}this.hide(),ve!==-1&&(this._diffEditor.setPosition(new v.y(ve,1)),this._diffEditor.revealPosition(new v.y(ve,1),1))}hide(){this._isVisible=!1,this._diffEditor.updateOptions({readOnly:!1}),this._diffEditor.focus(),this._diffEditor.doLayout(),this._render()}_getPrevRow(){const ve=this._getCurrentFocusedRow();return ve?ve.previousElementSibling?ve.previousElementSibling:ve:this._getFirstRow()}_getNextRow(){const ve=this._getCurrentFocusedRow();return ve?ve.nextElementSibling?ve.nextElementSibling:ve:this._getFirstRow()}_getFirstRow(){return this.domNode.domNode.querySelector(".diff-review-row")}_getCurrentFocusedRow(){const ve=document.activeElement;return ve&&/diff-review-row/.test(ve.className)?ve:null}_goToRow(ve){const Te=this._getCurrentFocusedRow();ve.tabIndex=0,ve.focus(),Te&&Te!==ve&&(Te.tabIndex=-1),this.scrollbar.scanDomNode()}isVisible(){return this._isVisible}layout(ve,Te,je){this._width=Te,this.shadow.setTop(ve-6),this.shadow.setWidth(Te),this.shadow.setHeight(this._isVisible?6:0),this.domNode.setTop(ve),this.domNode.setWidth(Te),this.domNode.setHeight(je),this._content.setHeight(je),this._content.setWidth(Te),this._isVisible?(this.actionBarContainer.setAttribute("aria-hidden","false"),this.actionBarContainer.setDisplay("block")):(this.actionBarContainer.setAttribute("aria-hidden","true"),this.actionBarContainer.setDisplay("none"))}_compute(){const ve=this._diffEditor.getLineChanges();if(!ve||ve.length===0)return[];const Te=this._diffEditor.getOriginalEditor().getModel(),je=this._diffEditor.getModifiedEditor().getModel();return!Te||!je?[]:go._mergeAdjacent(ve,Te.getLineCount(),je.getLineCount())}static _mergeAdjacent(ve,Te,je){if(!ve||ve.length===0)return[];const nt=[];let at=0;for(let wt=0,kt=ve.length;wt<kt;wt++){const Ct=ve[wt],Gt=Ct.originalStartLineNumber,Ht=Ct.originalEndLineNumber,Ut=Ct.modifiedStartLineNumber,Ue=Ct.modifiedEndLineNumber,ei=[];let ui=0;{const oi=Ht===0?Gt:Gt-1,ki=Ue===0?Ut:Ut-1;let Kt=1,li=1;if(wt>0){const Tt=ve[wt-1];Tt.originalEndLineNumber===0?Kt=Tt.originalStartLineNumber+1:Kt=Tt.originalEndLineNumber+1,Tt.modifiedEndLineNumber===0?li=Tt.modifiedStartLineNumber+1:li=Tt.modifiedEndLineNumber+1}let Ci=oi-N+1,mi=ki-N+1;if(Ci<Kt){const Tt=Kt-Ci;Ci=Ci+Tt,mi=mi+Tt}if(mi<li){const Tt=li-mi;Ci=Ci+Tt,mi=mi+Tt}ei[ui++]=new G(Ci,oi,mi,ki)}Ht!==0&&(ei[ui++]=new G(Gt,Ht,0,0)),Ue!==0&&(ei[ui++]=new G(0,0,Ut,Ue));{const oi=Ht===0?Gt+1:Ht+1,ki=Ue===0?Ut+1:Ue+1;let Kt=Te,li=je;if(wt+1<kt){const Tt=ve[wt+1];Tt.originalEndLineNumber===0?Kt=Tt.originalStartLineNumber:Kt=Tt.originalStartLineNumber-1,Tt.modifiedEndLineNumber===0?li=Tt.modifiedStartLineNumber:li=Tt.modifiedStartLineNumber-1}let Ci=oi+N-1,mi=ki+N-1;if(Ci>Kt){const Tt=Kt-Ci;Ci=Ci+Tt,mi=mi+Tt}if(mi>li){const Tt=li-mi;Ci=Ci+Tt,mi=mi+Tt}ei[ui++]=new G(oi,Ci,ki,mi)}nt[at++]=new O(ei)}let vt=nt[0].entries;const It=[];let At=0;for(let wt=1,kt=nt.length;wt<kt;wt++){const Ct=nt[wt].entries,Gt=vt[vt.length-1],Ht=Ct[0];if(Gt.getType()===0&&Ht.getType()===0&&Ht.originalLineStart<=Gt.originalLineEnd){vt[vt.length-1]=new G(Gt.originalLineStart,Ht.originalLineEnd,Gt.modifiedLineStart,Ht.modifiedLineEnd),vt=vt.concat(Ct.slice(1));continue}It[At++]=new O(vt),vt=Ct}return It[At++]=new O(vt),It}_findDiffIndex(ve){const Te=ve.lineNumber;for(let je=0,nt=this._diffs.length;je<nt;je++){const at=this._diffs[je].entries,vt=at[at.length-1].modifiedLineEnd;if(Te<=vt)return je}return 0}_render(){const ve=this._diffEditor.getOriginalEditor().getOptions(),Te=this._diffEditor.getModifiedEditor().getOptions(),je=this._diffEditor.getOriginalEditor().getModel(),nt=this._diffEditor.getModifiedEditor().getModel(),at=je.getOptions(),vt=nt.getOptions();if(!this._isVisible||!je||!nt){o.w_(this._content.domNode),this._currentDiff=null,this.scrollbar.scanDomNode();return}this._diffEditor.updateOptions({readOnly:!0});const It=this._findDiffIndex(this._diffEditor.getPosition());if(this._diffs[It]===this._currentDiff)return;this._currentDiff=this._diffs[It];const At=this._diffs[It].entries,wt=document.createElement("div");wt.className="diff-review-table",wt.setAttribute("role","list"),wt.setAttribute("aria-label",'Difference review. Use "Stage | Unstage | Revert Selected Ranges" commands'),(0,T.M)(wt,Te.get(46));let kt=0,Ct=0,Gt=0,Ht=0;for(let mi=0,Tt=At.length;mi<Tt;mi++){const qt=At[mi],Ni=qt.originalLineStart,Fi=qt.originalLineEnd,yi=qt.modifiedLineStart,ti=qt.modifiedLineEnd;Ni!==0&&(kt===0||Ni<kt)&&(kt=Ni),Fi!==0&&(Ct===0||Fi>Ct)&&(Ct=Fi),yi!==0&&(Gt===0||yi<Gt)&&(Gt=yi),ti!==0&&(Ht===0||ti>Ht)&&(Ht=ti)}const Ut=document.createElement("div");Ut.className="diff-review-row";const Ue=document.createElement("div");Ue.className="diff-review-cell diff-review-summary";const ei=Ct-kt+1,ui=Ht-Gt+1;Ue.appendChild(document.createTextNode(`${It+1}/${this._diffs.length}: @@ -${kt},${ei} +${Gt},${ui} @@`)),Ut.setAttribute("data-line",String(Gt));const oi=mi=>mi===0?b.kg("no_lines_changed","no lines changed"):mi===1?b.kg("one_line_changed","1 line changed"):b.kg("more_lines_changed","{0} lines changed",mi),ki=oi(ei),Kt=oi(ui);Ut.setAttribute("aria-label",b.kg({key:"header",comment:["This is the ARIA label for a git diff header.","A git diff header looks like this: @@ -154,12 +159,39 @@.","That encodes that at original line 154 (which is now line 159), 12 lines were removed/changed with 39 lines.","Variables 0 and 1 refer to the diff index out of total number of diffs.","Variables 2 and 4 will be numbers (a line number).",'Variables 3 and 5 will be "no lines changed", "1 line changed" or "X lines changed", localized separately.']},"Difference {0} of {1}: original line {2}, {3}, modified line {4}, {5}",It+1,this._diffs.length,kt,ki,Gt,Kt)),Ut.appendChild(Ue),Ut.setAttribute("role","listitem"),wt.appendChild(Ut);const li=Te.get(61);let Ci=Gt;for(let mi=0,Tt=At.length;mi<Tt;mi++){const qt=At[mi];go._renderSection(wt,qt,Ci,li,this._width,ve,je,at,Te,nt,vt,this._languageService.languageIdCodec),qt.modifiedLineStart!==0&&(Ci=qt.modifiedLineEnd)}o.w_(this._content.domNode),this._content.domNode.appendChild(wt),this.scrollbar.scanDomNode()}static _renderSection(ve,Te,je,nt,at,vt,It,At,wt,kt,Ct,Gt){const Ht=Te.getType();let Ut="diff-review-row",Ue="";const ei="diff-review-spacer";let ui=null;switch(Ht){case 1:Ut="diff-review-row line-insert",Ue=" char-insert",ui=te;break;case 2:Ut="diff-review-row line-delete",Ue=" char-delete",ui=oe;break}const oi=Te.originalLineStart,ki=Te.originalLineEnd,Kt=Te.modifiedLineStart,li=Te.modifiedLineEnd,Ci=Math.max(li-Kt,ki-oi),mi=vt.get(133),Tt=mi.glyphMarginWidth+mi.lineNumbersWidth,qt=wt.get(133),Ni=10+qt.glyphMarginWidth+qt.lineNumbersWidth;for(let Fi=0;Fi<=Ci;Fi++){const yi=oi===0?0:oi+Fi,ti=Kt===0?0:Kt+Fi,wi=document.createElement("div");wi.style.minWidth=at+"px",wi.className=Ut,wi.setAttribute("role","listitem"),ti!==0&&(je=ti),wi.setAttribute("data-line",String(je));const Qi=document.createElement("div");Qi.className="diff-review-cell",Qi.style.height=`${nt}px`,wi.appendChild(Qi);const Vi=document.createElement("span");Vi.style.width=Tt+"px",Vi.style.minWidth=Tt+"px",Vi.className="diff-review-line-number"+Ue,yi!==0?Vi.appendChild(document.createTextNode(String(yi))):Vi.innerText="\xA0",Qi.appendChild(Vi);const Zi=document.createElement("span");Zi.style.width=Ni+"px",Zi.style.minWidth=Ni+"px",Zi.style.paddingRight="10px",Zi.className="diff-review-line-number"+Ue,ti!==0?Zi.appendChild(document.createTextNode(String(ti))):Zi.innerText="\xA0",Qi.appendChild(Zi);const Ji=document.createElement("span");if(Ji.className=ei,ui){const fi=document.createElement("span");fi.className=Y.L0.asClassName(ui),fi.innerText="\xA0\xA0",Ji.appendChild(fi)}else Ji.innerText="\xA0\xA0";Qi.appendChild(Ji);let qi;if(ti!==0){let fi=this._renderLine(kt,wt,Ct.tabSize,ti,Gt);go._ttPolicy&&(fi=go._ttPolicy.createHTML(fi)),Qi.insertAdjacentHTML("beforeend",fi),qi=kt.getLineContent(ti)}else{let fi=this._renderLine(It,vt,At.tabSize,yi,Gt);go._ttPolicy&&(fi=go._ttPolicy.createHTML(fi)),Qi.insertAdjacentHTML("beforeend",fi),qi=It.getLineContent(yi)}qi.length===0&&(qi=b.kg("blankLine","blank"));let Pi="";switch(Ht){case 0:yi===ti?Pi=b.kg({key:"unchangedLine",comment:["The placeholders are contents of the line and should not be translated."]},"{0} unchanged line {1}",qi,yi):Pi=b.kg("equalLine","{0} original line {1} modified line {2}",qi,yi,ti);break;case 1:Pi=b.kg("insertLine","+ {0} modified line {1}",qi,ti);break;case 2:Pi=b.kg("deleteLine","- {0} original line {1}",qi,yi);break}wi.setAttribute("aria-label",Pi),ve.appendChild(wi)}}static _renderLine(ve,Te,je,nt,at){const vt=ve.getLineContent(nt),It=Te.get(46),At=m.f.createEmpty(vt,at),wt=x.qL.isBasicASCII(vt,ve.mightContainNonBasicASCII()),kt=x.qL.containsRTL(vt,wt,ve.mightContainRTL());return(0,D.Md)(new D.zL(It.isMonospace&&!Te.get(29),It.canUseHalfwidthRightwardsArrow,vt,!1,wt,kt,0,At,[],je,0,It.spaceWidth,It.middotWidth,It.wsmiddotWidth,Te.get(107),Te.get(90),Te.get(85),Te.get(47)!==C.Bc.OFF,null)).html}};E._ttPolicy=(Z=window.trustedTypes)===null||Z===void 0?void 0:Z.createPolicy("diffReview",{createHTML:St=>St}),E=X([R(1,Q.L)],E),(0,Y.zy)((St,ve)=>{const Te=St.getColor(k.Qt);Te&&ve.addRule(`.monaco-diff-editor .diff-review-line-number { color: ${Te}; }`);const je=St.getColor(W.bXl);je&&ve.addRule(`.monaco-diff-editor .diff-review-shadow { box-shadow: ${je} 0 -6px 6px -6px inset; }`)});class Qe extends w.ks{constructor(){super({id:"editor.action.diffReview.next",label:b.kg("editor.action.diffReview.next","Go to Next Difference"),alias:"Go to Next Difference",precondition:A.M$.has("isInDiffEditor"),kbOpts:{kbExpr:null,primary:65,weight:100}})}run(ve,Te){const je=Se(ve);je&&je.diffReviewNext()}}class Ke extends w.ks{constructor(){super({id:"editor.action.diffReview.prev",label:b.kg("editor.action.diffReview.prev","Go to Previous Difference"),alias:"Go to Previous Difference",precondition:A.M$.has("isInDiffEditor"),kbOpts:{kbExpr:null,primary:1089,weight:100}})}run(ve,Te){const je=Se(ve);je&&je.diffReviewPrev()}}function Se(St){const ve=St.get(d.T),Te=ve.listDiffEditors(),je=ve.getActiveCodeEditor();if(!je)return null;for(let nt=0,at=Te.length;nt<at;nt++){const vt=Te[nt];if(vt.getModifiedEditor().getId()===je.getId()||vt.getOriginalEditor().getId()===je.getId())return vt}return null}(0,w.Fl)(Qe),(0,w.Fl)(Ke);var Me=y(50442),ce=y(54324),pe=y(12596),be=y(59922),ge=y(90304),ke=y(96803),We=y(45561),Ge=y(82399),Ae=y(30657),he=y(29879),Pe=y(52348),$e=function(St,ve,Te,je){function nt(at){return at instanceof Te?at:new Te(function(vt){vt(at)})}return new(Te||(Te=Promise))(function(at,vt){function It(kt){try{wt(je.next(kt))}catch(Ct){vt(Ct)}}function At(kt){try{wt(je.throw(kt))}catch(Ct){vt(Ct)}}function wt(kt){kt.done?at(kt.value):nt(kt.value).then(It,At)}wt((je=je.apply(St,ve||[])).next())})};class it extends B.jG{constructor(ve,Te,je,nt,at,vt){super(),this._viewZoneId=ve,this._marginDomNode=Te,this.editor=je,this.diff=nt,this._contextMenuService=at,this._clipboardService=vt,this._visibility=!1,this._marginDomNode.style.zIndex="10",this._diffActions=document.createElement("div"),this._diffActions.className=ne.W6.lightBulb.classNames+" lightbulb-glyph",this._diffActions.style.position="absolute";const It=je.getOption(61),At=je.getModel().getEOL();this._diffActions.style.right="0px",this._diffActions.style.visibility="hidden",this._diffActions.style.height=`${It}px`,this._diffActions.style.lineHeight=`${It}px`,this._marginDomNode.appendChild(this._diffActions);const wt=[],kt=nt.modifiedEndLineNumber===0;wt.push(new u.rc("diff.clipboard.copyDeletedContent",kt?nt.originalEndLineNumber>nt.modifiedStartLineNumber?b.kg("diff.clipboard.copyDeletedLinesContent.label","Copy deleted lines"):b.kg("diff.clipboard.copyDeletedLinesContent.single.label","Copy deleted line"):nt.originalEndLineNumber>nt.modifiedStartLineNumber?b.kg("diff.clipboard.copyChangedLinesContent.label","Copy changed lines"):b.kg("diff.clipboard.copyChangedLinesContent.single.label","Copy changed line"),void 0,!0,()=>$e(this,void 0,void 0,function*(){const Ue=new Me.Q(nt.originalStartLineNumber,1,nt.originalEndLineNumber+1,1),ei=nt.originalModel.getValueInRange(Ue);yield this._clipboardService.writeText(ei)})));let Ct=0,Gt;nt.originalEndLineNumber>nt.modifiedStartLineNumber&&(Gt=new u.rc("diff.clipboard.copyDeletedLineContent",kt?b.kg("diff.clipboard.copyDeletedLineContent.label","Copy deleted line ({0})",nt.originalStartLineNumber):b.kg("diff.clipboard.copyChangedLineContent.label","Copy changed line ({0})",nt.originalStartLineNumber),void 0,!0,()=>$e(this,void 0,void 0,function*(){const Ue=nt.originalModel.getLineContent(nt.originalStartLineNumber+Ct);if(Ue===""){const ei=nt.originalModel.getEndOfLineSequence();yield this._clipboardService.writeText(ei===0?` `:`\r `)}else yield this._clipboardService.writeText(Ue)})),wt.push(Gt)),je.getOption(83)||wt.push(new u.rc("diff.inline.revertChange",b.kg("diff.inline.revertChange.label","Revert this change"),void 0,!0,()=>$e(this,void 0,void 0,function*(){const Ue=new Me.Q(nt.originalStartLineNumber,1,nt.originalEndLineNumber,nt.originalModel.getLineMaxColumn(nt.originalEndLineNumber)),ei=nt.originalModel.getValueInRange(Ue);if(nt.modifiedEndLineNumber===0){const ui=je.getModel().getLineMaxColumn(nt.modifiedStartLineNumber);je.executeEdits("diffEditor",[{range:new Me.Q(nt.modifiedStartLineNumber,ui,nt.modifiedStartLineNumber,ui),text:At+ei}])}else{const ui=je.getModel().getLineMaxColumn(nt.modifiedEndLineNumber);je.executeEdits("diffEditor",[{range:new Me.Q(nt.modifiedStartLineNumber,1,nt.modifiedEndLineNumber,ui),text:ei}])}})));const Ut=(Ue,ei)=>{this._contextMenuService.showContextMenu({getAnchor:()=>({x:Ue,y:ei}),getActions:()=>(Gt&&(Gt.label=kt?b.kg("diff.clipboard.copyDeletedLineContent.label","Copy deleted line ({0})",nt.originalStartLineNumber+Ct):b.kg("diff.clipboard.copyChangedLineContent.label","Copy changed line ({0})",nt.originalStartLineNumber+Ct)),wt),autoSelectFirstItem:!0})};this._register(o.b2(this._diffActions,"mousedown",Ue=>{const{top:ei,height:ui}=o.BK(this._diffActions),oi=Math.floor(It/3);Ue.preventDefault(),Ut(Ue.posx,ei+ui+oi)})),this._register(je.onMouseMove(Ue=>{Ue.target.type===8||Ue.target.type===5?Ue.target.detail.viewZoneId===this._viewZoneId?(this.visibility=!0,Ct=this._updateLightBulbPosition(this._marginDomNode,Ue.event.browserEvent.y,It)):this.visibility=!1:this.visibility=!1})),this._register(je.onMouseDown(Ue=>{Ue.event.rightButton&&(Ue.target.type===8||Ue.target.type===5)&&Ue.target.detail.viewZoneId===this._viewZoneId&&(Ue.event.preventDefault(),Ct=this._updateLightBulbPosition(this._marginDomNode,Ue.event.browserEvent.y,It),Ut(Ue.event.posx,Ue.event.posy+It))}))}get visibility(){return this._visibility}set visibility(ve){this._visibility!==ve&&(this._visibility=ve,ve?this._diffActions.style.visibility="visible":this._diffActions.style.visibility="hidden")}_updateLightBulbPosition(ve,Te,je){const{top:nt}=o.BK(ve),at=Te-nt,vt=Math.floor(at/je),It=vt*je;if(this._diffActions.style.top=`${It}px`,this.diff.viewLineCounts){let At=0;for(let wt=0;wt<this.diff.viewLineCounts.length;wt++)if(At+=this.diff.viewLineCounts[wt],vt<At)return wt}return vt}}var ft=y(3338),Wt=y(94327),tt=y(44023),Ye=y(5711),ht=y(68107),Lt=y(89563),Rt=function(St,ve,Te,je){var nt=arguments.length,at=nt<3?ve:je===null?je=Object.getOwnPropertyDescriptor(ve,Te):je,vt;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")at=Reflect.decorate(St,ve,Te,je);else for(var It=St.length-1;It>=0;It--)(vt=St[It])&&(at=(nt<3?vt(at):nt>3?vt(ve,Te,at):vt(ve,Te))||at);return nt>3&&at&&Object.defineProperty(ve,Te,at),at},Ie=function(St,ve){return function(Te,je){ve(Te,je,St)}},Ve;class dt{constructor(ve,Te){this._contextMenuService=ve,this._clipboardService=Te,this._zones=[],this._inlineDiffMargins=[],this._zonesMap={},this._decorations=[]}getForeignViewZones(ve){return ve.filter(Te=>!this._zonesMap[String(Te.id)])}clean(ve){this._zones.length>0&&ve.changeViewZones(Te=>{for(const je of this._zones)Te.removeZone(je)}),this._zones=[],this._zonesMap={},ve.changeDecorations(Te=>{this._decorations=Te.deltaDecorations(this._decorations,[])})}apply(ve,Te,je,nt){const at=nt?p.D.capture(ve):null;ve.changeViewZones(vt=>{var It;for(const At of this._zones)vt.removeZone(At);for(const At of this._inlineDiffMargins)At.dispose();this._zones=[],this._zonesMap={},this._inlineDiffMargins=[];for(let At=0,wt=je.zones.length;At<wt;At++){const kt=je.zones[At];kt.suppressMouseDown=!0;const Ct=vt.addZone(kt);this._zones.push(Ct),this._zonesMap[String(Ct)]=!0,je.zones[At].diff&&kt.marginDomNode&&(kt.suppressMouseDown=!1,((It=je.zones[At].diff)===null||It===void 0?void 0:It.originalModel.getValueLength())!==0&&this._inlineDiffMargins.push(new it(Ct,kt.marginDomNode,ve,je.zones[At].diff,this._contextMenuService,this._clipboardService)))}}),at?.restore(ve),ve.changeDecorations(vt=>{this._decorations=vt.deltaDecorations(this._decorations,je.decorations)}),Te?.setZones(je.overviewZones)}}let bt=0;const Mt=(0,j.pU)("diff-insert",ne.W6.add,b.kg("diffInsertIcon","Line decoration for inserts in the diff editor.")),Yt=(0,j.pU)("diff-remove",ne.W6.remove,b.kg("diffRemoveIcon","Line decoration for removals in the diff editor.")),Nt=(Ve=window.trustedTypes)===null||Ve===void 0?void 0:Ve.createPolicy("diffEditorWidget",{createHTML:St=>St});let Pt=class Kn extends B.jG{constructor(ve,Te,je,nt,at,vt,It,At,wt,kt,Ct,Gt){super(),this._editorProgressService=Gt,this._onDidDispose=this._register(new P.vl),this.onDidDispose=this._onDidDispose.event,this._onDidUpdateDiff=this._register(new P.vl),this.onDidUpdateDiff=this._onDidUpdateDiff.event,this._onDidContentSizeChange=this._register(new P.vl),this._lastOriginalWarning=null,this._lastModifiedWarning=null,this._editorWorkerService=at,this._codeEditorService=At,this._contextKeyService=this._register(vt.createScoped(ve)),this._instantiationService=It.createChild(new Ae.a([A.fN,this._contextKeyService])),this._contextKeyService.createKey("isInDiffEditor",!0),this._themeService=wt,this._notificationService=kt,this._id=++bt,this._state=0,this._updatingDiffProgress=null,this._domElement=ve,Te=Te||{},this._options=vi(Te,{enableSplitViewResizing:!0,renderSideBySide:!0,renderMarginRevertIcon:!0,maxComputationTime:5e3,maxFileSize:50,ignoreTrimWhitespace:!0,renderIndicators:!0,originalEditable:!1,diffCodeLens:!1,renderOverviewRuler:!0,diffWordWrap:"inherit"}),typeof Te.isInEmbeddedEditor<"u"?this._contextKeyService.createKey("isInEmbeddedDiffEditor",Te.isInEmbeddedEditor):this._contextKeyService.createKey("isInEmbeddedDiffEditor",!1),this._updateDecorationsRunner=this._register(new U.uC(()=>this._updateDecorations(),0)),this._containerDomElement=document.createElement("div"),this._containerDomElement.className=Kn._getClassName(this._themeService.getColorTheme(),this._options.renderSideBySide),this._containerDomElement.style.position="relative",this._containerDomElement.style.height="100%",this._domElement.appendChild(this._containerDomElement),this._overviewViewportDomElement=(0,$.Z)(document.createElement("div")),this._overviewViewportDomElement.setClassName("diffViewport"),this._overviewViewportDomElement.setPosition("absolute"),this._overviewDomElement=document.createElement("div"),this._overviewDomElement.className="diffOverview",this._overviewDomElement.style.position="absolute",this._overviewDomElement.appendChild(this._overviewViewportDomElement.domNode),this._register(o.b2(this._overviewDomElement,o.Bx.POINTER_DOWN,Ut=>{this._modifiedEditor.delegateVerticalScrollbarPointerDown(Ut)})),this._options.renderOverviewRuler&&this._containerDomElement.appendChild(this._overviewDomElement),this._originalDomNode=document.createElement("div"),this._originalDomNode.className="editor original",this._originalDomNode.style.position="absolute",this._originalDomNode.style.height="100%",this._containerDomElement.appendChild(this._originalDomNode),this._modifiedDomNode=document.createElement("div"),this._modifiedDomNode.className="editor modified",this._modifiedDomNode.style.position="absolute",this._modifiedDomNode.style.height="100%",this._containerDomElement.appendChild(this._modifiedDomNode),this._beginUpdateDecorationsTimeout=-1,this._currentlyChangingViewZones=!1,this._diffComputationToken=0,this._originalEditorState=new dt(Ct,nt),this._modifiedEditorState=new dt(Ct,nt),this._isVisible=!0,this._isHandlingScrollEvent=!1,this._elementSizeObserver=this._register(new Ye.u(this._containerDomElement,Te.dimension)),this._register(this._elementSizeObserver.onDidChange(()=>this._onDidContainerSizeChanged())),Te.automaticLayout&&this._elementSizeObserver.startObserving(),this._diffComputationResult=null,this._originalEditor=this._createLeftHandSideEditor(Te,je.originalEditor||{}),this._modifiedEditor=this._createRightHandSideEditor(Te,je.modifiedEditor||{}),this._originalOverviewRuler=null,this._modifiedOverviewRuler=null,this._reviewPane=It.createInstance(E,this),this._containerDomElement.appendChild(this._reviewPane.domNode.domNode),this._containerDomElement.appendChild(this._reviewPane.shadow.domNode),this._containerDomElement.appendChild(this._reviewPane.actionBarContainer.domNode),this._options.renderSideBySide?this._setStrategy(new fe(this._createDataSource(),this._options.enableSplitViewResizing)):this._setStrategy(new Et(this._createDataSource(),this._options.enableSplitViewResizing)),this._register(wt.onDidColorThemeChange(Ut=>{this._strategy&&this._strategy.applyColors(Ut)&&this._updateDecorationsRunner.schedule(),this._containerDomElement.className=Kn._getClassName(this._themeService.getColorTheme(),this._options.renderSideBySide)}));const Ht=w.dS.getDiffEditorContributions();for(const Ut of Ht)try{this._register(It.createInstance(Ut.ctor,this))}catch(Ue){(0,Wt.dz)(Ue)}this._codeEditorService.addDiffEditor(this)}_setState(ve){this._state!==ve&&(this._state=ve,this._updatingDiffProgress&&(this._updatingDiffProgress.done(),this._updatingDiffProgress=null),this._state===1&&(this._updatingDiffProgress=this._editorProgressService.show(!0,1e3)))}diffReviewNext(){this._reviewPane.next()}diffReviewPrev(){this._reviewPane.prev()}static _getClassName(ve,Te){let je="monaco-diff-editor monaco-editor-background ";return Te&&(je+="side-by-side "),je+=(0,Y.Pz)(ve.type),je}_disposeOverviewRulers(){this._originalOverviewRuler&&(this._overviewDomElement.removeChild(this._originalOverviewRuler.getDomNode()),this._originalOverviewRuler.dispose(),this._originalOverviewRuler=null),this._modifiedOverviewRuler&&(this._overviewDomElement.removeChild(this._modifiedOverviewRuler.getDomNode()),this._modifiedOverviewRuler.dispose(),this._modifiedOverviewRuler=null)}_createOverviewRulers(){this._options.renderOverviewRuler&&(K.ok(!this._originalOverviewRuler&&!this._modifiedOverviewRuler),this._originalEditor.hasModel()&&(this._originalOverviewRuler=this._originalEditor.createOverviewRuler("original diffOverviewRuler"),this._overviewDomElement.appendChild(this._originalOverviewRuler.getDomNode())),this._modifiedEditor.hasModel()&&(this._modifiedOverviewRuler=this._modifiedEditor.createOverviewRuler("modified diffOverviewRuler"),this._overviewDomElement.appendChild(this._modifiedOverviewRuler.getDomNode())),this._layoutOverviewRulers())}_createLeftHandSideEditor(ve,Te){const je=this._createInnerEditor(this._instantiationService,this._originalDomNode,this._adjustOptionsForLeftHandSide(ve),Te);this._register(je.onDidScrollChange(at=>{this._isHandlingScrollEvent||!at.scrollTopChanged&&!at.scrollLeftChanged&&!at.scrollHeightChanged||(this._isHandlingScrollEvent=!0,this._modifiedEditor.setScrollPosition({scrollLeft:at.scrollLeft,scrollTop:at.scrollTop}),this._isHandlingScrollEvent=!1,this._layoutOverviewViewport())})),this._register(je.onDidChangeViewZones(()=>{this._onViewZonesChanged()})),this._register(je.onDidChangeConfiguration(at=>{je.getModel()&&(at.hasChanged(46)&&this._updateDecorationsRunner.schedule(),at.hasChanged(134)&&(this._updateDecorationsRunner.cancel(),this._updateDecorations()))})),this._register(je.onDidChangeHiddenAreas(()=>{this._updateDecorationsRunner.cancel(),this._updateDecorations()})),this._register(je.onDidChangeModelContent(()=>{this._isVisible&&this._beginUpdateDecorationsSoon()}));const nt=this._contextKeyService.createKey("isInDiffLeftEditor",je.hasWidgetFocus());return this._register(je.onDidFocusEditorWidget(()=>nt.set(!0))),this._register(je.onDidBlurEditorWidget(()=>nt.set(!1))),this._register(je.onDidContentSizeChange(at=>{const vt=this._originalEditor.getContentWidth()+this._modifiedEditor.getContentWidth()+Kn.ONE_OVERVIEW_WIDTH,It=Math.max(this._modifiedEditor.getContentHeight(),this._originalEditor.getContentHeight());this._onDidContentSizeChange.fire({contentHeight:It,contentWidth:vt,contentHeightChanged:at.contentHeightChanged,contentWidthChanged:at.contentWidthChanged})})),je}_createRightHandSideEditor(ve,Te){const je=this._createInnerEditor(this._instantiationService,this._modifiedDomNode,this._adjustOptionsForRightHandSide(ve),Te);this._register(je.onDidScrollChange(at=>{this._isHandlingScrollEvent||!at.scrollTopChanged&&!at.scrollLeftChanged&&!at.scrollHeightChanged||(this._isHandlingScrollEvent=!0,this._originalEditor.setScrollPosition({scrollLeft:at.scrollLeft,scrollTop:at.scrollTop}),this._isHandlingScrollEvent=!1,this._layoutOverviewViewport())})),this._register(je.onDidChangeViewZones(()=>{this._onViewZonesChanged()})),this._register(je.onDidChangeConfiguration(at=>{je.getModel()&&(at.hasChanged(46)&&this._updateDecorationsRunner.schedule(),at.hasChanged(134)&&(this._updateDecorationsRunner.cancel(),this._updateDecorations()))})),this._register(je.onDidChangeHiddenAreas(()=>{this._updateDecorationsRunner.cancel(),this._updateDecorations()})),this._register(je.onDidChangeModelContent(()=>{this._isVisible&&this._beginUpdateDecorationsSoon()})),this._register(je.onDidChangeModelOptions(at=>{at.tabSize&&this._updateDecorationsRunner.schedule()}));const nt=this._contextKeyService.createKey("isInDiffRightEditor",je.hasWidgetFocus());return this._register(je.onDidFocusEditorWidget(()=>nt.set(!0))),this._register(je.onDidBlurEditorWidget(()=>nt.set(!1))),this._register(je.onDidContentSizeChange(at=>{const vt=this._originalEditor.getContentWidth()+this._modifiedEditor.getContentWidth()+Kn.ONE_OVERVIEW_WIDTH,It=Math.max(this._modifiedEditor.getContentHeight(),this._originalEditor.getContentHeight());this._onDidContentSizeChange.fire({contentHeight:It,contentWidth:vt,contentHeightChanged:at.contentHeightChanged,contentWidthChanged:at.contentWidthChanged})})),this._register(je.onMouseDown(at=>{var vt,It;if(!at.event.rightButton&&at.target.position&&(!((vt=at.target.element)===null||vt===void 0)&&vt.className.includes("arrow-revert-change"))){const At=at.target.position.lineNumber,wt=(It=this._diffComputationResult)===null||It===void 0?void 0:It.changes.find(kt=>kt.modifiedStartLineNumber===At-1||kt.modifiedStartLineNumber===At);wt&&this.revertChange(wt),at.event.stopPropagation(),this._updateDecorations();return}})),je}revertChange(ve){const Te=this._modifiedEditor,je=this._originalEditor.getModel(),nt=this._modifiedEditor.getModel();if(!je||!nt||!Te)return;const at=ve.originalEndLineNumber>0?new Me.Q(ve.originalStartLineNumber,1,ve.originalEndLineNumber,je.getLineMaxColumn(ve.originalEndLineNumber)):null,vt=at?je.getValueInRange(at):null,It=ve.modifiedEndLineNumber>0?new Me.Q(ve.modifiedStartLineNumber,1,ve.modifiedEndLineNumber,nt.getLineMaxColumn(ve.modifiedEndLineNumber)):null,At=nt.getEOL();if(ve.originalEndLineNumber===0&&It){let wt=It;ve.modifiedStartLineNumber>1?wt=It.setStartPosition(ve.modifiedStartLineNumber-1,nt.getLineMaxColumn(ve.modifiedStartLineNumber-1)):ve.modifiedEndLineNumber<nt.getLineCount()&&(wt=It.setEndPosition(ve.modifiedEndLineNumber+1,1)),Te.executeEdits("diffEditor",[{range:wt,text:""}])}else if(ve.modifiedEndLineNumber===0&&vt!==null){const wt=ve.modifiedStartLineNumber<nt.getLineCount()?new v.y(ve.modifiedStartLineNumber+1,1):new v.y(ve.modifiedStartLineNumber,nt.getLineMaxColumn(ve.modifiedStartLineNumber));Te.executeEdits("diffEditor",[{range:Me.Q.fromPositions(wt,wt),text:ve.modifiedStartLineNumber<nt.getLineCount()?vt+At:At+vt}])}else It&&vt!==null&&Te.executeEdits("diffEditor",[{range:It,text:vt}])}_createInnerEditor(ve,Te,je,nt){return ve.createInstance(g.x,Te,je,nt)}dispose(){this._codeEditorService.removeDiffEditor(this),this._beginUpdateDecorationsTimeout!==-1&&(window.clearTimeout(this._beginUpdateDecorationsTimeout),this._beginUpdateDecorationsTimeout=-1),this._cleanViewZonesAndDecorations(),this._originalOverviewRuler&&(this._overviewDomElement.removeChild(this._originalOverviewRuler.getDomNode()),this._originalOverviewRuler.dispose()),this._modifiedOverviewRuler&&(this._overviewDomElement.removeChild(this._modifiedOverviewRuler.getDomNode()),this._modifiedOverviewRuler.dispose()),this._overviewDomElement.removeChild(this._overviewViewportDomElement.domNode),this._options.renderOverviewRuler&&this._containerDomElement.removeChild(this._overviewDomElement),this._containerDomElement.removeChild(this._originalDomNode),this._originalEditor.dispose(),this._containerDomElement.removeChild(this._modifiedDomNode),this._modifiedEditor.dispose(),this._strategy.dispose(),this._containerDomElement.removeChild(this._reviewPane.domNode.domNode),this._containerDomElement.removeChild(this._reviewPane.shadow.domNode),this._containerDomElement.removeChild(this._reviewPane.actionBarContainer.domNode),this._reviewPane.dispose(),this._domElement.removeChild(this._containerDomElement),this._onDidDispose.fire(),super.dispose()}getId(){return this.getEditorType()+":"+this._id}getEditorType(){return pe._.IDiffEditor}getLineChanges(){return this._diffComputationResult?this._diffComputationResult.changes:null}getOriginalEditor(){return this._originalEditor}getModifiedEditor(){return this._modifiedEditor}updateOptions(ve){const Te=vi(ve,this._options),je=Ri(this._options,Te);this._options=Te;const nt=je.ignoreTrimWhitespace||je.renderIndicators||je.renderMarginRevertIcon,at=this._isVisible&&(je.maxComputationTime||je.maxFileSize);nt?this._beginUpdateDecorations():at&&this._beginUpdateDecorationsSoon(),this._modifiedEditor.updateOptions(this._adjustOptionsForRightHandSide(ve)),this._originalEditor.updateOptions(this._adjustOptionsForLeftHandSide(ve)),this._strategy.setEnableSplitViewResizing(this._options.enableSplitViewResizing),je.renderSideBySide&&(this._options.renderSideBySide?this._setStrategy(new fe(this._createDataSource(),this._options.enableSplitViewResizing)):this._setStrategy(new Et(this._createDataSource(),this._options.enableSplitViewResizing)),this._containerDomElement.className=Kn._getClassName(this._themeService.getColorTheme(),this._options.renderSideBySide)),je.renderOverviewRuler&&(this._options.renderOverviewRuler?this._containerDomElement.appendChild(this._overviewDomElement):this._containerDomElement.removeChild(this._overviewDomElement))}getModel(){return{original:this._originalEditor.getModel(),modified:this._modifiedEditor.getModel()}}setModel(ve){if(ve&&(!ve.original||!ve.modified))throw new Error(ve.original?"DiffEditorWidget.setModel: Modified model is null":"DiffEditorWidget.setModel: Original model is null");this._cleanViewZonesAndDecorations(),this._disposeOverviewRulers(),this._originalEditor.setModel(ve?ve.original:null),this._modifiedEditor.setModel(ve?ve.modified:null),this._updateDecorationsRunner.cancel(),ve&&(this._originalEditor.setScrollTop(0),this._modifiedEditor.setScrollTop(0)),this._diffComputationResult=null,this._diffComputationToken++,this._setState(0),ve&&(this._createOverviewRulers(),this._beginUpdateDecorations()),this._layoutOverviewViewport()}getContainerDomNode(){return this._domElement}getVisibleColumnFromPosition(ve){return this._modifiedEditor.getVisibleColumnFromPosition(ve)}getPosition(){return this._modifiedEditor.getPosition()}setPosition(ve,Te="api"){this._modifiedEditor.setPosition(ve,Te)}revealLine(ve,Te=0){this._modifiedEditor.revealLine(ve,Te)}revealLineInCenter(ve,Te=0){this._modifiedEditor.revealLineInCenter(ve,Te)}revealLineInCenterIfOutsideViewport(ve,Te=0){this._modifiedEditor.revealLineInCenterIfOutsideViewport(ve,Te)}revealLineNearTop(ve,Te=0){this._modifiedEditor.revealLineNearTop(ve,Te)}revealPosition(ve,Te=0){this._modifiedEditor.revealPosition(ve,Te)}revealPositionInCenter(ve,Te=0){this._modifiedEditor.revealPositionInCenter(ve,Te)}revealPositionInCenterIfOutsideViewport(ve,Te=0){this._modifiedEditor.revealPositionInCenterIfOutsideViewport(ve,Te)}revealPositionNearTop(ve,Te=0){this._modifiedEditor.revealPositionNearTop(ve,Te)}getSelection(){return this._modifiedEditor.getSelection()}getSelections(){return this._modifiedEditor.getSelections()}setSelection(ve,Te="api"){this._modifiedEditor.setSelection(ve,Te)}setSelections(ve,Te="api"){this._modifiedEditor.setSelections(ve,Te)}revealLines(ve,Te,je=0){this._modifiedEditor.revealLines(ve,Te,je)}revealLinesInCenter(ve,Te,je=0){this._modifiedEditor.revealLinesInCenter(ve,Te,je)}revealLinesInCenterIfOutsideViewport(ve,Te,je=0){this._modifiedEditor.revealLinesInCenterIfOutsideViewport(ve,Te,je)}revealLinesNearTop(ve,Te,je=0){this._modifiedEditor.revealLinesNearTop(ve,Te,je)}revealRange(ve,Te=0,je=!1,nt=!0){this._modifiedEditor.revealRange(ve,Te,je,nt)}revealRangeInCenter(ve,Te=0){this._modifiedEditor.revealRangeInCenter(ve,Te)}revealRangeInCenterIfOutsideViewport(ve,Te=0){this._modifiedEditor.revealRangeInCenterIfOutsideViewport(ve,Te)}revealRangeNearTop(ve,Te=0){this._modifiedEditor.revealRangeNearTop(ve,Te)}revealRangeNearTopIfOutsideViewport(ve,Te=0){this._modifiedEditor.revealRangeNearTopIfOutsideViewport(ve,Te)}revealRangeAtTop(ve,Te=0){this._modifiedEditor.revealRangeAtTop(ve,Te)}getSupportedActions(){return this._modifiedEditor.getSupportedActions()}saveViewState(){const ve=this._originalEditor.saveViewState(),Te=this._modifiedEditor.saveViewState();return{original:ve,modified:Te}}restoreViewState(ve){if(ve&&ve.original&&ve.modified){const Te=ve;this._originalEditor.restoreViewState(Te.original),this._modifiedEditor.restoreViewState(Te.modified)}}layout(ve){this._elementSizeObserver.observe(ve)}focus(){this._modifiedEditor.focus()}hasTextFocus(){return this._originalEditor.hasTextFocus()||this._modifiedEditor.hasTextFocus()}trigger(ve,Te,je){this._modifiedEditor.trigger(ve,Te,je)}createDecorationsCollection(ve){return this._modifiedEditor.createDecorationsCollection(ve)}changeDecorations(ve){return this._modifiedEditor.changeDecorations(ve)}_onDidContainerSizeChanged(){this._doLayout()}_getReviewHeight(){return this._reviewPane.isVisible()?this._elementSizeObserver.getHeight():0}_layoutOverviewRulers(){if(!this._options.renderOverviewRuler||!this._originalOverviewRuler||!this._modifiedOverviewRuler)return;const ve=this._elementSizeObserver.getHeight(),Te=this._getReviewHeight(),je=Kn.ENTIRE_DIFF_OVERVIEW_WIDTH-2*Kn.ONE_OVERVIEW_WIDTH;this._modifiedEditor.getLayoutInfo()&&(this._originalOverviewRuler.setLayout({top:0,width:Kn.ONE_OVERVIEW_WIDTH,right:je+Kn.ONE_OVERVIEW_WIDTH,height:ve-Te}),this._modifiedOverviewRuler.setLayout({top:0,right:0,width:Kn.ONE_OVERVIEW_WIDTH,height:ve-Te}))}_onViewZonesChanged(){this._currentlyChangingViewZones||this._updateDecorationsRunner.schedule()}_beginUpdateDecorationsSoon(){this._beginUpdateDecorationsTimeout!==-1&&(window.clearTimeout(this._beginUpdateDecorationsTimeout),this._beginUpdateDecorationsTimeout=-1),this._beginUpdateDecorationsTimeout=window.setTimeout(()=>this._beginUpdateDecorations(),Kn.UPDATE_DIFF_DECORATIONS_DELAY)}static _equals(ve,Te){return!ve&&!Te?!0:!ve||!Te?!1:ve.toString()===Te.toString()}_beginUpdateDecorations(){this._beginUpdateDecorationsTimeout=-1;const ve=this._originalEditor.getModel(),Te=this._modifiedEditor.getModel();if(!ve||!Te)return;this._diffComputationToken++;const je=this._diffComputationToken,nt=this._options.maxFileSize*1024*1024,at=vt=>{const It=vt.getValueLength();return nt===0||It<=nt};if(!at(ve)||!at(Te)){(!Kn._equals(ve.uri,this._lastOriginalWarning)||!Kn._equals(Te.uri,this._lastModifiedWarning))&&(this._lastOriginalWarning=ve.uri,this._lastModifiedWarning=Te.uri,this._notificationService.warn(b.kg("diff.tooLarge","Cannot compare files because one file is too large.")));return}this._setState(1),this._editorWorkerService.computeDiff(ve.uri,Te.uri,this._options.ignoreTrimWhitespace,this._options.maxComputationTime).then(vt=>{je===this._diffComputationToken&&ve===this._originalEditor.getModel()&&Te===this._modifiedEditor.getModel()&&(this._setState(2),this._diffComputationResult=vt,this._updateDecorationsRunner.schedule(),this._onDidUpdateDiff.fire())},vt=>{je===this._diffComputationToken&&ve===this._originalEditor.getModel()&&Te===this._modifiedEditor.getModel()&&(this._setState(2),this._diffComputationResult=null,this._updateDecorationsRunner.schedule())})}_cleanViewZonesAndDecorations(){this._originalEditorState.clean(this._originalEditor),this._modifiedEditorState.clean(this._modifiedEditor)}_updateDecorations(){if(!this._originalEditor.getModel()||!this._modifiedEditor.getModel())return;const ve=this._diffComputationResult?this._diffComputationResult.changes:[],Te=this._originalEditorState.getForeignViewZones(this._originalEditor.getWhitespaces()),je=this._modifiedEditorState.getForeignViewZones(this._modifiedEditor.getWhitespaces()),nt=this._strategy.getEditorsDiffDecorations(ve,this._options.ignoreTrimWhitespace,this._options.renderIndicators,this._options.renderMarginRevertIcon,Te,je);try{this._currentlyChangingViewZones=!0,this._originalEditorState.apply(this._originalEditor,this._originalOverviewRuler,nt.original,!1),this._modifiedEditorState.apply(this._modifiedEditor,this._modifiedOverviewRuler,nt.modified,!0)}finally{this._currentlyChangingViewZones=!1}}_adjustOptionsForSubEditor(ve){const Te=Object.assign({},ve);return Te.inDiffEditor=!0,Te.automaticLayout=!1,Te.scrollbar=Object.assign({},Te.scrollbar||{}),Te.scrollbar.vertical="visible",Te.folding=!1,Te.codeLens=this._options.diffCodeLens,Te.fixedOverflowWidgets=!0,Te.minimap=Object.assign({},Te.minimap||{}),Te.minimap.enabled=!1,Te}_adjustOptionsForLeftHandSide(ve){const Te=this._adjustOptionsForSubEditor(ve);return this._options.renderSideBySide?Te.wordWrapOverride1=this._options.diffWordWrap:(Te.wordWrapOverride1="off",Te.wordWrapOverride2="off"),ve.originalAriaLabel&&(Te.ariaLabel=ve.originalAriaLabel),Te.readOnly=!this._options.originalEditable,Te.dropIntoEditor={enabled:!Te.readOnly},Te.extraEditorClassName="original-in-monaco-diff-editor",Object.assign(Object.assign({},Te),{dimension:{height:0,width:0}})}_adjustOptionsForRightHandSide(ve){const Te=this._adjustOptionsForSubEditor(ve);return ve.modifiedAriaLabel&&(Te.ariaLabel=ve.modifiedAriaLabel),Te.wordWrapOverride1=this._options.diffWordWrap,Te.revealHorizontalRightPadding=C.qB.revealHorizontalRightPadding.defaultValue+Kn.ENTIRE_DIFF_OVERVIEW_WIDTH,Te.scrollbar.verticalHasArrows=!1,Te.extraEditorClassName="modified-in-monaco-diff-editor",Object.assign(Object.assign({},Te),{dimension:{height:0,width:0}})}doLayout(){this._elementSizeObserver.observe(),this._doLayout()}_doLayout(){const ve=this._elementSizeObserver.getWidth(),Te=this._elementSizeObserver.getHeight(),je=this._getReviewHeight(),nt=this._strategy.layout();this._originalDomNode.style.width=nt+"px",this._originalDomNode.style.left="0px",this._modifiedDomNode.style.width=ve-nt+"px",this._modifiedDomNode.style.left=nt+"px",this._overviewDomElement.style.top="0px",this._overviewDomElement.style.height=Te-je+"px",this._overviewDomElement.style.width=Kn.ENTIRE_DIFF_OVERVIEW_WIDTH+"px",this._overviewDomElement.style.left=ve-Kn.ENTIRE_DIFF_OVERVIEW_WIDTH+"px",this._overviewViewportDomElement.setWidth(Kn.ENTIRE_DIFF_OVERVIEW_WIDTH),this._overviewViewportDomElement.setHeight(30),this._originalEditor.layout({width:nt,height:Te-je}),this._modifiedEditor.layout({width:ve-nt-(this._options.renderOverviewRuler?Kn.ENTIRE_DIFF_OVERVIEW_WIDTH:0),height:Te-je}),(this._originalOverviewRuler||this._modifiedOverviewRuler)&&this._layoutOverviewRulers(),this._reviewPane.layout(Te-je,ve,je),this._layoutOverviewViewport()}_layoutOverviewViewport(){const ve=this._computeOverviewViewport();ve?(this._overviewViewportDomElement.setTop(ve.top),this._overviewViewportDomElement.setHeight(ve.height)):(this._overviewViewportDomElement.setTop(0),this._overviewViewportDomElement.setHeight(0))}_computeOverviewViewport(){const ve=this._modifiedEditor.getLayoutInfo();if(!ve)return null;const Te=this._modifiedEditor.getScrollTop(),je=this._modifiedEditor.getScrollHeight(),nt=Math.max(0,ve.height),at=Math.max(0,nt-0),vt=je>0?at/je:0,It=Math.max(0,Math.floor(ve.height*vt)),At=Math.floor(Te*vt);return{height:It,top:At}}_createDataSource(){return{getWidth:()=>this._elementSizeObserver.getWidth(),getHeight:()=>this._elementSizeObserver.getHeight()-this._getReviewHeight(),getOptions:()=>({renderOverviewRuler:this._options.renderOverviewRuler}),getContainerDomNode:()=>this._containerDomElement,relayoutEditors:()=>{this._doLayout()},getOriginalEditor:()=>this._originalEditor,getModifiedEditor:()=>this._modifiedEditor}}_setStrategy(ve){this._strategy&&this._strategy.dispose(),this._strategy=ve,ve.applyColors(this._themeService.getColorTheme()),this._diffComputationResult&&this._updateDecorations(),this._doLayout()}_getLineChangeAtOrBeforeLineNumber(ve,Te){const je=this._diffComputationResult?this._diffComputationResult.changes:[];if(je.length===0||ve<Te(je[0]))return null;let nt=0,at=je.length-1;for(;nt<at;){const vt=Math.floor((nt+at)/2),It=Te(je[vt]),At=vt+1<=at?Te(je[vt+1]):1073741824;ve<It?at=vt-1:ve>=At?nt=vt+1:(nt=vt,at=vt)}return je[nt]}_getEquivalentLineForOriginalLineNumber(ve){const Te=this._getLineChangeAtOrBeforeLineNumber(ve,At=>At.originalStartLineNumber);if(!Te)return ve;const je=Te.originalStartLineNumber+(Te.originalEndLineNumber>0?-1:0),nt=Te.modifiedStartLineNumber+(Te.modifiedEndLineNumber>0?-1:0),at=Te.originalEndLineNumber>0?Te.originalEndLineNumber-Te.originalStartLineNumber+1:0,vt=Te.modifiedEndLineNumber>0?Te.modifiedEndLineNumber-Te.modifiedStartLineNumber+1:0,It=ve-je;return It<=at?nt+Math.min(It,vt):nt+vt-at+It}_getEquivalentLineForModifiedLineNumber(ve){const Te=this._getLineChangeAtOrBeforeLineNumber(ve,At=>At.modifiedStartLineNumber);if(!Te)return ve;const je=Te.originalStartLineNumber+(Te.originalEndLineNumber>0?-1:0),nt=Te.modifiedStartLineNumber+(Te.modifiedEndLineNumber>0?-1:0),at=Te.originalEndLineNumber>0?Te.originalEndLineNumber-Te.originalStartLineNumber+1:0,vt=Te.modifiedEndLineNumber>0?Te.modifiedEndLineNumber-Te.modifiedStartLineNumber+1:0,It=ve-nt;return It<=vt?je+Math.min(It,at):je+at-vt+It}getDiffLineInformationForOriginal(ve){return this._diffComputationResult?{equivalentLineNumber:this._getEquivalentLineForOriginalLineNumber(ve)}:null}getDiffLineInformationForModified(ve){return this._diffComputationResult?{equivalentLineNumber:this._getEquivalentLineForModifiedLineNumber(ve)}:null}};Pt.ONE_OVERVIEW_WIDTH=15,Pt.ENTIRE_DIFF_OVERVIEW_WIDTH=30,Pt.UPDATE_DIFF_DECORATIONS_DELAY=200,Pt=Rt([Ie(3,ft.h),Ie(4,ge.w),Ie(5,A.fN),Ie(6,Ge._Y),Ie(7,d.T),Ie(8,Y.Gy),Ie(9,he.Ot),Ie(10,Pe.Z),Ie(11,tt.N8)],Pt);class Ti extends B.jG{constructor(ve){super(),this._dataSource=ve,this._insertColor=null,this._removeColor=null}applyColors(ve){const Te=ve.getColor(W.ld8)||(ve.getColor(W.Gj6)||W.EY1).transparent(2),je=ve.getColor(W.$BZ)||(ve.getColor(W.GNm)||W.ZEf).transparent(2),nt=!Te.equals(this._insertColor)||!je.equals(this._removeColor);return this._insertColor=Te,this._removeColor=je,nt}getEditorsDiffDecorations(ve,Te,je,nt,at,vt){vt=vt.sort((kt,Ct)=>kt.afterLineNumber-Ct.afterLineNumber),at=at.sort((kt,Ct)=>kt.afterLineNumber-Ct.afterLineNumber);const It=this._getViewZones(ve,at,vt,je),At=this._getOriginalEditorDecorations(It,ve,Te,je),wt=this._getModifiedEditorDecorations(It,ve,Te,je,nt);return{original:{decorations:At.decorations,overviewZones:At.overviewZones,zones:It.original},modified:{decorations:wt.decorations,overviewZones:wt.overviewZones,zones:It.modified}}}}class Ii{constructor(ve){this._source=ve,this._index=-1,this.current=null,this.advance()}advance(){this._index++,this._index<this._source.length?this.current=this._source[this._index]:this.current=null}}class ut{constructor(ve,Te,je,nt,at){this._lineChanges=ve,this._originalForeignVZ=Te,this._modifiedForeignVZ=je,this._originalEditor=nt,this._modifiedEditor=at}static _getViewLineCount(ve,Te,je){const nt=ve.getModel(),at=ve._getViewModel();if(nt&&at){const vt=ni(nt,at,Te,je);return vt.endLineNumber-vt.startLineNumber+1}return je-Te+1}getViewZones(){const ve=this._originalEditor.getOption(61),Te=this._modifiedEditor.getOption(61),je=this._originalEditor.getOption(134).wrappingColumn!==-1,nt=this._modifiedEditor.getOption(134).wrappingColumn!==-1,at=je||nt,vt=this._originalEditor.getModel(),It=this._originalEditor._getViewModel().coordinatesConverter,At=this._modifiedEditor._getViewModel().coordinatesConverter,wt={original:[],modified:[]};let kt=0,Ct=0,Gt=0,Ht=0,Ut=0,Ue=0;const ei=(Ci,mi)=>Ci.afterLineNumber-mi.afterLineNumber,ui=(Ci,mi)=>{if(mi.domNode===null&&Ci.length>0){const Tt=Ci[Ci.length-1];if(Tt.afterLineNumber===mi.afterLineNumber&&Tt.domNode===null){Tt.heightInLines+=mi.heightInLines;return}}Ci.push(mi)},oi=new Ii(this._modifiedForeignVZ),ki=new Ii(this._originalForeignVZ);let Kt=1,li=1;for(let Ci=0,mi=this._lineChanges.length;Ci<=mi;Ci++){const Tt=Ci<mi?this._lineChanges[Ci]:null;Tt!==null?(Gt=Tt.originalStartLineNumber+(Tt.originalEndLineNumber>0?-1:0),Ht=Tt.modifiedStartLineNumber+(Tt.modifiedEndLineNumber>0?-1:0),Ct=Tt.originalEndLineNumber>0?ut._getViewLineCount(this._originalEditor,Tt.originalStartLineNumber,Tt.originalEndLineNumber):0,kt=Tt.modifiedEndLineNumber>0?ut._getViewLineCount(this._modifiedEditor,Tt.modifiedStartLineNumber,Tt.modifiedEndLineNumber):0,Ut=Math.max(Tt.originalStartLineNumber,Tt.originalEndLineNumber),Ue=Math.max(Tt.modifiedStartLineNumber,Tt.modifiedEndLineNumber)):(Gt+=1e7+Ct,Ht+=1e7+kt,Ut=Gt,Ue=Ht);let qt=[],Ni=[];if(at){let ti;Tt?Tt.originalEndLineNumber>0?ti=Tt.originalStartLineNumber-Kt:ti=Tt.modifiedStartLineNumber-li:ti=vt.getLineCount()-Kt+1;for(let wi=0;wi<ti;wi++){const Qi=Kt+wi,Vi=li+wi,Zi=It.getModelLineViewLineCount(Qi),Ji=At.getModelLineViewLineCount(Vi);Zi<Ji?qt.push({afterLineNumber:Qi,heightInLines:Ji-Zi,domNode:null,marginDomNode:null}):Zi>Ji&&Ni.push({afterLineNumber:Vi,heightInLines:Zi-Ji,domNode:null,marginDomNode:null})}Tt&&(Kt=(Tt.originalEndLineNumber>0?Tt.originalEndLineNumber:Tt.originalStartLineNumber)+1,li=(Tt.modifiedEndLineNumber>0?Tt.modifiedEndLineNumber:Tt.modifiedStartLineNumber)+1)}for(;oi.current&&oi.current.afterLineNumber<=Ue;){let ti;oi.current.afterLineNumber<=Ht?ti=Gt-Ht+oi.current.afterLineNumber:ti=Ut;let wi=null;Tt&&Tt.modifiedStartLineNumber<=oi.current.afterLineNumber&&oi.current.afterLineNumber<=Tt.modifiedEndLineNumber&&(wi=this._createOriginalMarginDomNodeForModifiedForeignViewZoneInAddedRegion()),qt.push({afterLineNumber:ti,heightInLines:oi.current.height/Te,domNode:null,marginDomNode:wi}),oi.advance()}for(;ki.current&&ki.current.afterLineNumber<=Ut;){let ti;ki.current.afterLineNumber<=Gt?ti=Ht-Gt+ki.current.afterLineNumber:ti=Ue,Ni.push({afterLineNumber:ti,heightInLines:ki.current.height/ve,domNode:null}),ki.advance()}if(Tt!==null&&_i(Tt)){const ti=this._produceOriginalFromDiff(Tt,Ct,kt);ti&&qt.push(ti)}if(Tt!==null&&Fe(Tt)){const ti=this._produceModifiedFromDiff(Tt,Ct,kt);ti&&Ni.push(ti)}let Fi=0,yi=0;for(qt=qt.sort(ei),Ni=Ni.sort(ei);Fi<qt.length&&yi<Ni.length;){const ti=qt[Fi],wi=Ni[yi],Qi=ti.afterLineNumber-Gt,Vi=wi.afterLineNumber-Ht;Qi<Vi?(ui(wt.original,ti),Fi++):Vi<Qi?(ui(wt.modified,wi),yi++):ti.shouldNotShrink?(ui(wt.original,ti),Fi++):wi.shouldNotShrink?(ui(wt.modified,wi),yi++):ti.heightInLines>=wi.heightInLines?(ti.heightInLines-=wi.heightInLines,yi++):(wi.heightInLines-=ti.heightInLines,Fi++)}for(;Fi<qt.length;)ui(wt.original,qt[Fi]),Fi++;for(;yi<Ni.length;)ui(wt.modified,Ni[yi]),yi++}return{original:ut._ensureDomNodes(wt.original),modified:ut._ensureDomNodes(wt.modified)}}static _ensureDomNodes(ve){return ve.map(Te=>(Te.domNode||(Te.domNode=Xt()),Te))}}function Si(St,ve,Te,je,nt){return{range:new Me.Q(St,ve,Te,je),options:nt}}const yt={arrowRevertChange:be.kI.register({description:"diff-editor-arrow-revert-change",glyphMarginClassName:"arrow-revert-change "+Y.L0.asClassName(ne.W6.arrowRight)}),charDelete:be.kI.register({description:"diff-editor-char-delete",className:"char-delete"}),charDeleteWholeLine:be.kI.register({description:"diff-editor-char-delete-whole-line",className:"char-delete",isWholeLine:!0}),charInsert:be.kI.register({description:"diff-editor-char-insert",className:"char-insert"}),charInsertWholeLine:be.kI.register({description:"diff-editor-char-insert-whole-line",className:"char-insert",isWholeLine:!0}),lineInsert:be.kI.register({description:"diff-editor-line-insert",className:"line-insert",marginClassName:"gutter-insert",isWholeLine:!0}),lineInsertWithSign:be.kI.register({description:"diff-editor-line-insert-with-sign",className:"line-insert",linesDecorationsClassName:"insert-sign "+Y.L0.asClassName(Mt),marginClassName:"gutter-insert",isWholeLine:!0}),lineDelete:be.kI.register({description:"diff-editor-line-delete",className:"line-delete",marginClassName:"gutter-delete",isWholeLine:!0}),lineDeleteWithSign:be.kI.register({description:"diff-editor-line-delete-with-sign",className:"line-delete",linesDecorationsClassName:"delete-sign "+Y.L0.asClassName(Yt),marginClassName:"gutter-delete",isWholeLine:!0}),lineDeleteMargin:be.kI.register({description:"diff-editor-line-delete-margin",marginClassName:"gutter-delete"})};class fe extends Ti{constructor(ve,Te){super(ve),this._disableSash=Te===!1,this._sashRatio=null,this._sashPosition=null,this._startSashPosition=null,this._sash=this._register(new L.m(this._dataSource.getContainerDomNode(),this,{orientation:0})),this._disableSash&&(this._sash.state=0),this._sash.onDidStart(()=>this._onSashDragStart()),this._sash.onDidChange(je=>this._onSashDrag(je)),this._sash.onDidEnd(()=>this._onSashDragEnd()),this._sash.onDidReset(()=>this._onSashReset())}setEnableSplitViewResizing(ve){const Te=ve===!1;this._disableSash!==Te&&(this._disableSash=Te,this._sash.state=this._disableSash?0:3)}layout(ve=this._sashRatio){const je=this._dataSource.getWidth()-(this._dataSource.getOptions().renderOverviewRuler?Pt.ENTIRE_DIFF_OVERVIEW_WIDTH:0);let nt=Math.floor((ve||.5)*je);const at=Math.floor(.5*je);return nt=this._disableSash?at:nt||at,je>fe.MINIMUM_EDITOR_WIDTH*2?(nt<fe.MINIMUM_EDITOR_WIDTH&&(nt=fe.MINIMUM_EDITOR_WIDTH),nt>je-fe.MINIMUM_EDITOR_WIDTH&&(nt=je-fe.MINIMUM_EDITOR_WIDTH)):nt=at,this._sashPosition!==nt&&(this._sashPosition=nt),this._sash.layout(),this._sashPosition}_onSashDragStart(){this._startSashPosition=this._sashPosition}_onSashDrag(ve){const je=this._dataSource.getWidth()-(this._dataSource.getOptions().renderOverviewRuler?Pt.ENTIRE_DIFF_OVERVIEW_WIDTH:0),nt=this.layout((this._startSashPosition+(ve.currentX-ve.startX))/je);this._sashRatio=nt/je,this._dataSource.relayoutEditors()}_onSashDragEnd(){this._sash.layout()}_onSashReset(){this._sashRatio=.5,this._dataSource.relayoutEditors(),this._sash.layout()}getVerticalSashTop(ve){return 0}getVerticalSashLeft(ve){return this._sashPosition}getVerticalSashHeight(ve){return this._dataSource.getHeight()}_getViewZones(ve,Te,je){const nt=this._dataSource.getOriginalEditor(),at=this._dataSource.getModifiedEditor();return new ze(ve,Te,je,nt,at).getViewZones()}_getOriginalEditorDecorations(ve,Te,je,nt){const at=this._dataSource.getOriginalEditor(),vt=String(this._removeColor),It={decorations:[],overviewZones:[]},At=at.getModel(),wt=at._getViewModel();for(const kt of Te)if(Fe(kt)){It.decorations.push({range:new Me.Q(kt.originalStartLineNumber,1,kt.originalEndLineNumber,1073741824),options:nt?yt.lineDeleteWithSign:yt.lineDelete}),(!_i(kt)||!kt.charChanges)&&It.decorations.push(Si(kt.originalStartLineNumber,1,kt.originalEndLineNumber,1073741824,yt.charDeleteWholeLine));const Ct=ni(At,wt,kt.originalStartLineNumber,kt.originalEndLineNumber);if(It.overviewZones.push(new ke.iE(Ct.startLineNumber,Ct.endLineNumber,0,vt)),kt.charChanges){for(const Gt of kt.charChanges)if(gt(Gt))if(je)for(let Ht=Gt.originalStartLineNumber;Ht<=Gt.originalEndLineNumber;Ht++){let Ut,Ue;Ht===Gt.originalStartLineNumber?Ut=Gt.originalStartColumn:Ut=At.getLineFirstNonWhitespaceColumn(Ht),Ht===Gt.originalEndLineNumber?Ue=Gt.originalEndColumn:Ue=At.getLineLastNonWhitespaceColumn(Ht),It.decorations.push(Si(Ht,Ut,Ht,Ue,yt.charDelete))}else It.decorations.push(Si(Gt.originalStartLineNumber,Gt.originalStartColumn,Gt.originalEndLineNumber,Gt.originalEndColumn,yt.charDelete))}}return It}_getModifiedEditorDecorations(ve,Te,je,nt,at){const vt=this._dataSource.getModifiedEditor(),It=String(this._insertColor),At={decorations:[],overviewZones:[]},wt=vt.getModel(),kt=vt._getViewModel();for(const Ct of Te){if(at)if(Ct.modifiedEndLineNumber>0)At.decorations.push({range:new Me.Q(Ct.modifiedStartLineNumber,1,Ct.modifiedStartLineNumber,1),options:yt.arrowRevertChange});else{const Gt=ve.modified.find(Ht=>Ht.afterLineNumber===Ct.modifiedStartLineNumber);Gt&&(Gt.marginDomNode=Vt())}if(_i(Ct)){At.decorations.push({range:new Me.Q(Ct.modifiedStartLineNumber,1,Ct.modifiedEndLineNumber,1073741824),options:nt?yt.lineInsertWithSign:yt.lineInsert}),(!Fe(Ct)||!Ct.charChanges)&&At.decorations.push(Si(Ct.modifiedStartLineNumber,1,Ct.modifiedEndLineNumber,1073741824,yt.charInsertWholeLine));const Gt=ni(wt,kt,Ct.modifiedStartLineNumber,Ct.modifiedEndLineNumber);if(At.overviewZones.push(new ke.iE(Gt.startLineNumber,Gt.endLineNumber,0,It)),Ct.charChanges){for(const Ht of Ct.charChanges)if(Xe(Ht))if(je)for(let Ut=Ht.modifiedStartLineNumber;Ut<=Ht.modifiedEndLineNumber;Ut++){let Ue,ei;Ut===Ht.modifiedStartLineNumber?Ue=Ht.modifiedStartColumn:Ue=wt.getLineFirstNonWhitespaceColumn(Ut),Ut===Ht.modifiedEndLineNumber?ei=Ht.modifiedEndColumn:ei=wt.getLineLastNonWhitespaceColumn(Ut),At.decorations.push(Si(Ut,Ue,Ut,ei,yt.charInsert))}else At.decorations.push(Si(Ht.modifiedStartLineNumber,Ht.modifiedStartColumn,Ht.modifiedEndLineNumber,Ht.modifiedEndColumn,yt.charInsert))}}}return At}}fe.MINIMUM_EDITOR_WIDTH=100;class ze extends ut{constructor(ve,Te,je,nt,at){super(ve,Te,je,nt,at)}_createOriginalMarginDomNodeForModifiedForeignViewZoneInAddedRegion(){return null}_produceOriginalFromDiff(ve,Te,je){return je>Te?{afterLineNumber:Math.max(ve.originalStartLineNumber,ve.originalEndLineNumber),heightInLines:je-Te,domNode:null}:null}_produceModifiedFromDiff(ve,Te,je){return Te>je?{afterLineNumber:Math.max(ve.modifiedStartLineNumber,ve.modifiedEndLineNumber),heightInLines:Te-je,domNode:null}:null}}class Et extends Ti{constructor(ve,Te){super(ve),this._decorationsLeft=ve.getOriginalEditor().getLayoutInfo().decorationsLeft,this._register(ve.getOriginalEditor().onDidLayoutChange(je=>{this._decorationsLeft!==je.decorationsLeft&&(this._decorationsLeft=je.decorationsLeft,ve.relayoutEditors())}))}setEnableSplitViewResizing(ve){}_getViewZones(ve,Te,je,nt){const at=this._dataSource.getOriginalEditor(),vt=this._dataSource.getModifiedEditor();return new Ot(ve,Te,je,at,vt,nt).getViewZones()}_getOriginalEditorDecorations(ve,Te,je,nt){const at=String(this._removeColor),vt={decorations:[],overviewZones:[]},It=this._dataSource.getOriginalEditor(),At=It.getModel(),wt=It._getViewModel();let kt=0;for(const Ct of Te)if(Fe(Ct)){for(vt.decorations.push({range:new Me.Q(Ct.originalStartLineNumber,1,Ct.originalEndLineNumber,1073741824),options:yt.lineDeleteMargin});kt<ve.modified.length;){const Ut=ve.modified[kt];if(Ut.diff&&Ut.diff.originalStartLineNumber>=Ct.originalStartLineNumber)break;kt++}let Gt=0;if(kt<ve.modified.length){const Ut=ve.modified[kt];Ut.diff&&Ut.diff.originalStartLineNumber===Ct.originalStartLineNumber&&Ut.diff.originalEndLineNumber===Ct.originalEndLineNumber&&Ut.diff.modifiedStartLineNumber===Ct.modifiedStartLineNumber&&Ut.diff.modifiedEndLineNumber===Ct.modifiedEndLineNumber&&(Gt=Ut.heightInLines)}const Ht=ni(At,wt,Ct.originalStartLineNumber,Ct.originalEndLineNumber);vt.overviewZones.push(new ke.iE(Ht.startLineNumber,Ht.endLineNumber,Gt,at))}return vt}_getModifiedEditorDecorations(ve,Te,je,nt,at){const vt=this._dataSource.getModifiedEditor(),It=String(this._insertColor),At={decorations:[],overviewZones:[]},wt=vt.getModel(),kt=vt._getViewModel();for(const Ct of Te)if(_i(Ct)){At.decorations.push({range:new Me.Q(Ct.modifiedStartLineNumber,1,Ct.modifiedEndLineNumber,1073741824),options:nt?yt.lineInsertWithSign:yt.lineInsert});const Gt=ni(wt,kt,Ct.modifiedStartLineNumber,Ct.modifiedEndLineNumber);if(At.overviewZones.push(new ke.iE(Gt.startLineNumber,Gt.endLineNumber,0,It)),Ct.charChanges){for(const Ht of Ct.charChanges)if(Xe(Ht))if(je)for(let Ut=Ht.modifiedStartLineNumber;Ut<=Ht.modifiedEndLineNumber;Ut++){let Ue,ei;Ut===Ht.modifiedStartLineNumber?Ue=Ht.modifiedStartColumn:Ue=wt.getLineFirstNonWhitespaceColumn(Ut),Ut===Ht.modifiedEndLineNumber?ei=Ht.modifiedEndColumn:ei=wt.getLineLastNonWhitespaceColumn(Ut),At.decorations.push(Si(Ut,Ue,Ut,ei,yt.charInsert))}else At.decorations.push(Si(Ht.modifiedStartLineNumber,Ht.modifiedStartColumn,Ht.modifiedEndLineNumber,Ht.modifiedEndColumn,yt.charInsert))}else At.decorations.push(Si(Ct.modifiedStartLineNumber,1,Ct.modifiedEndLineNumber,1073741824,yt.charInsertWholeLine))}return At}layout(){return Math.max(5,this._decorationsLeft)}}class Ot extends ut{constructor(ve,Te,je,nt,at,vt){super(ve,Te,je,nt,at),this._originalModel=nt.getModel(),this._renderIndicators=vt,this._pendingLineChange=[],this._pendingViewZones=[],this._lineBreaksComputer=this._modifiedEditor._getViewModel().createLineBreaksComputer()}getViewZones(){const ve=super.getViewZones();return this._finalize(ve),ve}_createOriginalMarginDomNodeForModifiedForeignViewZoneInAddedRegion(){const ve=document.createElement("div");return ve.className="inline-added-margin-view-zone",ve}_produceOriginalFromDiff(ve,Te,je){const nt=document.createElement("div");return nt.className="inline-added-margin-view-zone",{afterLineNumber:Math.max(ve.originalStartLineNumber,ve.originalEndLineNumber),heightInLines:je,domNode:document.createElement("div"),marginDomNode:nt}}_produceModifiedFromDiff(ve,Te,je){const nt=document.createElement("div");nt.className=`view-lines line-delete ${ht.S}`;const at=document.createElement("div");at.className="inline-deleted-margin-view-zone";const vt={shouldNotShrink:!0,afterLineNumber:ve.modifiedEndLineNumber===0?ve.modifiedStartLineNumber:ve.modifiedStartLineNumber-1,heightInLines:Te,minWidthInPx:0,domNode:nt,marginDomNode:at,diff:{originalStartLineNumber:ve.originalStartLineNumber,originalEndLineNumber:ve.originalEndLineNumber,modifiedStartLineNumber:ve.modifiedStartLineNumber,modifiedEndLineNumber:ve.modifiedEndLineNumber,originalModel:this._originalModel,viewLineCounts:null}};for(let It=ve.originalStartLineNumber;It<=ve.originalEndLineNumber;It++)this._lineBreaksComputer.addRequest(this._originalModel.getLineContent(It),null,null);return this._pendingLineChange.push(ve),this._pendingViewZones.push(vt),vt}_finalize(ve){const Te=this._modifiedEditor.getOptions(),je=this._modifiedEditor.getModel().getOptions().tabSize,nt=Te.get(46),at=Te.get(29),vt=nt.typicalHalfwidthCharacterWidth,It=Te.get(95),At=this._originalModel.mightContainNonBasicASCII(),wt=this._originalModel.mightContainRTL(),kt=Te.get(61),Gt=Te.get(133).decorationsWidth,Ht=Te.get(107),Ut=Te.get(90),Ue=Te.get(85),ei=Te.get(47),ui=this._lineBreaksComputer.finalize();let oi=0;for(let ki=0;ki<this._pendingLineChange.length;ki++){const Kt=this._pendingLineChange[ki],li=this._pendingViewZones[ki],Ci=li.domNode;(0,T.M)(Ci,nt);const mi=li.marginDomNode;(0,T.M)(mi,nt);const Tt=[];if(Kt.charChanges)for(const Vi of Kt.charChanges)gt(Vi)&&Tt.push(new x.kI(new Me.Q(Vi.originalStartLineNumber,Vi.originalStartColumn,Vi.originalEndLineNumber,Vi.originalEndColumn),"char-delete",0));const qt=Tt.length>0,Ni=(0,ce.Du)(1e4);let Fi=0,yi=0,ti=null;for(let Vi=Kt.originalStartLineNumber;Vi<=Kt.originalEndLineNumber;Vi++){const Zi=Vi-Kt.originalStartLineNumber,Ji=this._originalModel.tokenization.getLineTokens(Vi),qi=Ji.getLineContent(),Pi=ui[oi++],fi=We.d.filter(Tt,Vi,1,qi.length+1);if(Pi){let Sn=0;for(const en of Pi.breakOffsets){const dn=Ji.sliceAndInflate(Sn,en,0),Li=qi.substring(Sn,en);Fi=Math.max(Fi,this._renderOriginalLine(yi++,Li,dn,We.d.extractWrapped(fi,Sn,en),qt,At,wt,nt,at,kt,Gt,Ht,Ut,Ue,ei,je,Ni,mi)),Sn=en}for(ti||(ti=[]);ti.length<Zi;)ti[ti.length]=1;ti[Zi]=Pi.breakOffsets.length,li.heightInLines+=Pi.breakOffsets.length-1;const cn=document.createElement("div");cn.className="gutter-delete",ve.original.push({afterLineNumber:Vi,afterColumn:0,heightInLines:Pi.breakOffsets.length-1,domNode:Xt(),marginDomNode:cn})}else Fi=Math.max(Fi,this._renderOriginalLine(yi++,qi,Ji,fi,qt,At,wt,nt,at,kt,Gt,Ht,Ut,Ue,ei,je,Ni,mi))}Fi+=It;const wi=Ni.build(),Qi=Nt?Nt.createHTML(wi):wi;if(Ci.innerHTML=Qi,li.minWidthInPx=Fi*vt,ti){const Vi=Kt.originalEndLineNumber-Kt.originalStartLineNumber;for(;ti.length<=Vi;)ti[ti.length]=1}li.diff.viewLineCounts=ti}ve.original.sort((ki,Kt)=>ki.afterLineNumber-Kt.afterLineNumber)}_renderOriginalLine(ve,Te,je,nt,at,vt,It,At,wt,kt,Ct,Gt,Ht,Ut,Ue,ei,ui,oi){ui.appendASCIIString('<div class="view-line'),at||ui.appendASCIIString(" char-delete"),ui.appendASCIIString('" style="top:'),ui.appendASCIIString(String(ve*kt)),ui.appendASCIIString('px;width:1000000px;">');const ki=x.qL.isBasicASCII(Te,vt),Kt=x.qL.containsRTL(Te,ki,It),li=(0,D.UW)(new D.zL(At.isMonospace&&!wt,At.canUseHalfwidthRightwardsArrow,Te,!1,ki,Kt,0,je,nt,ei,0,At.spaceWidth,At.middotWidth,At.wsmiddotWidth,Gt,Ht,Ut,Ue!==C.Bc.OFF,null),ui);if(ui.appendASCIIString("</div>"),this._renderIndicators){const Ci=document.createElement("div");Ci.className=`delete-sign ${Y.L0.asClassName(Yt)}`,Ci.setAttribute("style",`position:absolute;top:${ve*kt}px;width:${Ct}px;height:${kt}px;right:0;`),oi.appendChild(Ci)}return li.characterMapping.getHorizontalOffset(li.characterMapping.length)}}function si(St,ve){return(0,C.O4)(St,ve,["off","on","inherit"])}function _i(St){return St.modifiedEndLineNumber>0}function Fe(St){return St.originalEndLineNumber>0}function Xe(St){return St.modifiedStartLineNumber===St.modifiedEndLineNumber?St.modifiedEndColumn-St.modifiedStartColumn>0:St.modifiedEndLineNumber-St.modifiedStartLineNumber>0}function gt(St){return St.originalStartLineNumber===St.originalEndLineNumber?St.originalEndColumn-St.originalStartColumn>0:St.originalEndLineNumber-St.originalStartLineNumber>0}function Xt(){const St=document.createElement("div");return St.className="diagonal-fill",St}function Vt(){const St=document.createElement("div");return St.className="arrow-revert-change "+Y.L0.asClassName(ne.W6.arrowRight),o.$("div",{},St)}function ni(St,ve,Te,je){const nt=St.getLineCount();return Te=Math.min(nt,Math.max(1,Te)),je=Math.min(nt,Math.max(1,je)),ve.coordinatesConverter.convertModelRangeToViewRange(new Me.Q(Te,St.getLineMinColumn(Te),je,St.getLineMaxColumn(je)))}function vi(St,ve){return{enableSplitViewResizing:(0,C.zM)(St.enableSplitViewResizing,ve.enableSplitViewResizing),renderSideBySide:(0,C.zM)(St.renderSideBySide,ve.renderSideBySide),renderMarginRevertIcon:(0,C.zM)(St.renderMarginRevertIcon,ve.renderMarginRevertIcon),maxComputationTime:(0,C.wA)(St.maxComputationTime,ve.maxComputationTime,0,1073741824),maxFileSize:(0,C.wA)(St.maxFileSize,ve.maxFileSize,0,1073741824),ignoreTrimWhitespace:(0,C.zM)(St.ignoreTrimWhitespace,ve.ignoreTrimWhitespace),renderIndicators:(0,C.zM)(St.renderIndicators,ve.renderIndicators),originalEditable:(0,C.zM)(St.originalEditable,ve.originalEditable),diffCodeLens:(0,C.zM)(St.diffCodeLens,ve.diffCodeLens),renderOverviewRuler:(0,C.zM)(St.renderOverviewRuler,ve.renderOverviewRuler),diffWordWrap:si(St.diffWordWrap,ve.diffWordWrap)}}function Ri(St,ve){return{enableSplitViewResizing:St.enableSplitViewResizing!==ve.enableSplitViewResizing,renderSideBySide:St.renderSideBySide!==ve.renderSideBySide,renderMarginRevertIcon:St.renderMarginRevertIcon!==ve.renderMarginRevertIcon,maxComputationTime:St.maxComputationTime!==ve.maxComputationTime,maxFileSize:St.maxFileSize!==ve.maxFileSize,ignoreTrimWhitespace:St.ignoreTrimWhitespace!==ve.ignoreTrimWhitespace,renderIndicators:St.renderIndicators!==ve.renderIndicators,originalEditable:St.originalEditable!==ve.originalEditable,diffCodeLens:St.diffCodeLens!==ve.diffCodeLens,renderOverviewRuler:St.renderOverviewRuler!==ve.renderOverviewRuler,diffWordWrap:St.diffWordWrap!==ve.diffWordWrap}}(0,Y.zy)((St,ve)=>{const Te=St.getColor(W.Gj6);Te&&ve.addRule(`.monaco-editor .char-insert, .monaco-diff-editor .char-insert { background-color: ${Te}; }`);const je=St.getColor(W.w3w)||Te;je&&ve.addRule(`.monaco-editor .line-insert, .monaco-diff-editor .line-insert { background-color: ${je}; }`);const nt=St.getColor(W.NXK)||je;nt&&(ve.addRule(`.monaco-editor .inline-added-margin-view-zone { background-color: ${nt}; }`),ve.addRule(`.monaco-editor .gutter-insert, .monaco-diff-editor .gutter-insert { background-color: ${nt}; }`));const at=St.getColor(W.GNm);at&&ve.addRule(`.monaco-editor .char-delete, .monaco-diff-editor .char-delete { background-color: ${at}; }`);const vt=St.getColor(W.MHP)||at;vt&&ve.addRule(`.monaco-editor .line-delete, .monaco-diff-editor .line-delete { background-color: ${vt}; }`);const It=St.getColor(W.$Qy)||vt;It&&(ve.addRule(`.monaco-editor .inline-deleted-margin-view-zone { background-color: ${It}; }`),ve.addRule(`.monaco-editor .gutter-delete, .monaco-diff-editor .gutter-delete { background-color: ${It}; }`));const At=St.getColor(W.YZM);At&&ve.addRule(`.monaco-editor .line-insert, .monaco-editor .char-insert { border: 1px ${(0,Lt.Bb)(St.type)?"dashed":"solid"} ${At}; }`);const wt=St.getColor(W.qaw);wt&&ve.addRule(`.monaco-editor .line-delete, .monaco-editor .char-delete { border: 1px ${(0,Lt.Bb)(St.type)?"dashed":"solid"} ${wt}; }`);const kt=St.getColor(W.bXl);kt&&ve.addRule(`.monaco-diff-editor.side-by-side .editor.modified { box-shadow: -6px 0 5px -5px ${kt}; }`);const Ct=St.getColor(W.w3C);Ct&&ve.addRule(`.monaco-diff-editor.side-by-side .editor.modified { border-left: 1px solid ${Ct}; }`);const Gt=St.getColor(W.gnV);Gt&&ve.addRule(` .monaco-diff-editor .diffViewport { background: ${Gt}; } `);const Ht=St.getColor(W.cI_);Ht&&ve.addRule(` .monaco-diff-editor .diffViewport:hover { background: ${Ht}; } `);const Ut=St.getColor(W.mhZ);Ut&&ve.addRule(` .monaco-diff-editor .diffViewport:active { background: ${Ut}; } `);const Ue=St.getColor(W.WmU);ve.addRule(` .monaco-editor .diagonal-fill { background-image: linear-gradient( -45deg, ${Ue} 12.5%, #0000 12.5%, #0000 50%, ${Ue} 50%, ${Ue} 62.5%, #0000 62.5%, #0000 100% ); background-size: 8px 8px; } `)})},1458:(rt,ye,y)=>{y.d(ye,{Yj:()=>P,s0:()=>B});var b=y(16844),o=y(57445),K=y(47317),$=y(97036),L=function(p,d,g,h){function l(u){return u instanceof g?u:new g(function(w){w(u)})}return new(g||(g=Promise))(function(u,w){function C(k){try{v(h.next(k))}catch(D){w(D)}}function m(k){try{v(h.throw(k))}catch(D){w(D)}}function v(k){k.done?u(k.value):l(k.value).then(C,m)}v((h=h.apply(p,d||[])).next())})};const U={getInitialState:()=>$.r3,tokenizeEncoded:(p,d,g)=>(0,$.Lh)(0,g)};function P(p,d,g){return L(this,void 0,void 0,function*(){if(!g)return T(d,p.languageIdCodec,U);const h=yield K.dG.getOrCreate(g);return T(d,p.languageIdCodec,h||U)})}function B(p,d,g,h,l,u,w){let C="<div>",m=h,v=0,k=!0;for(let D=0,x=d.getCount();D<x;D++){const A=d.getEndOffset(D);if(A<=h)continue;let W="";for(;m<A&&m<l;m++){const Y=p.charCodeAt(m);switch(Y){case 9:{let ne=u-(m+v)%u;for(v+=ne-1;ne>0;)w&&k?(W+=" ",k=!1):(W+=" ",k=!0),ne--;break}case 60:W+="<",k=!1;break;case 62:W+=">",k=!1;break;case 38:W+="&",k=!1;break;case 0:W+="�",k=!1;break;case 65279:case 8232:case 8233:case 133:W+="\uFFFD",k=!1;break;case 13:W+="​",k=!1;break;case 32:w&&k?(W+=" ",k=!1):(W+=" ",k=!0);break;default:W+=String.fromCharCode(Y),k=!1}}if(C+=`<span style="${d.getInlineStyle(D,g)}">${W}</span>`,A>l||m>=l)break}return C+="</div>",C}function T(p,d,g){let h='<div class="monaco-tokenized-source">';const l=b.uz(p);let u=g.getInitialState();for(let w=0,C=l.length;w<C;w++){const m=l[w];w>0&&(h+="<br/>");const v=g.tokenizeEncoded(m,!0,u);o.f.convertToEndOffset(v.tokens,m.length);const D=new o.f(v.tokens,m,d).inflate();let x=0;for(let A=0,W=D.getCount();A<W;A++){const Y=D.getClassName(A),ne=D.getEndOffset(A);h+=`<span class="${Y}">${b.ih(m.substring(x,ne))}</span>`,x=ne}u=v.endState}return h+="</div>",h}},1597:(rt,ye,y)=>{y.d(ye,{DD:()=>L,Gd:()=>$,IN:()=>U,KC:()=>o,kg:()=>B});var b=y(4874);function o(T,p){const d=Object.create(null);for(const g in p){const h=p[g];h&&(d[g]=(0,b.n__)(h,T))}return d}function K(T,p,d){function g(){const h=o(T.getColorTheme(),p);typeof d=="function"?d(h):d.style(h)}return g(),T.onDidColorThemeChange(g)}function $(T,p,d){return K(p,{badgeBackground:d?.badgeBackground||b.WMx,badgeForeground:d?.badgeForeground||b.zRE,badgeBorder:b.b1q},T)}function L(T,p,d){return K(p,Object.assign(Object.assign({},U),d||{}),T)}const U={listFocusBackground:b.VFX,listFocusForeground:b.efJ,listFocusOutline:b.p7Y,listActiveSelectionBackground:b.Rjz,listActiveSelectionForeground:b.GVV,listActiveSelectionIconForeground:b.fED,listFocusAndSelectionOutline:b.gtq,listFocusAndSelectionBackground:b.Rjz,listFocusAndSelectionForeground:b.GVV,listInactiveSelectionBackground:b.uNx,listInactiveSelectionIconForeground:b.C9U,listInactiveSelectionForeground:b.f4y,listInactiveFocusBackground:b.CQ3,listInactiveFocusOutline:b.ijf,listHoverBackground:b.lO1,listHoverForeground:b.QRv,listDropBackground:b.iAJ,listSelectionOutline:b.buw,listHoverOutline:b.buw,listFilterWidgetBackground:b.pnl,listFilterWidgetOutline:b.fiM,listFilterWidgetNoMatchesOutline:b.P9Z,listFilterWidgetShadow:b.H8q,treeIndentGuidesStroke:b.U4U,tableColumnsBorder:b.k5u,tableOddRowsBackgroundColor:b.sbQ,inputActiveOptionBorder:b.uNK,inputActiveOptionForeground:b.$$0,inputActiveOptionBackground:b.c1f,inputBackground:b.L4c,inputForeground:b.cws,inputBorder:b.Zgs,inputValidationInfoBackground:b.I$A,inputValidationInfoForeground:b.L9Z,inputValidationInfoBorder:b.YSW,inputValidationWarningBackground:b.ULt,inputValidationWarningForeground:b.T5N,inputValidationWarningBorder:b.C1n,inputValidationErrorBackground:b._$n,inputValidationErrorForeground:b.h9z,inputValidationErrorBorder:b.eYZ},P={shadowColor:b.f9l,borderColor:b.g$2,foregroundColor:b.dd_,backgroundColor:b.c6Y,selectionForegroundColor:b.pmr,selectionBackgroundColor:b.Ux$,selectionBorderColor:b.SNb,separatorColor:b.D7X,scrollbarShadow:b.bXl,scrollbarSliderBackground:b.gnV,scrollbarSliderHoverBackground:b.cI_,scrollbarSliderActiveBackground:b.mhZ};function B(T,p,d){return K(p,Object.assign(Object.assign({},P),d),T)}},1804:(rt,ye,y)=>{y.d(ye,{Fu:()=>C,az:()=>U});var b=y(16844),o=y(54324),K=y(50442);class ${constructor(v,k,D,x,A,W){this._richEditBracketBrand=void 0,this.languageId=v,this.index=k,this.open=D,this.close=x,this.forwardRegex=A,this.reversedRegex=W,this._openSet=$._toSet(this.open),this._closeSet=$._toSet(this.close)}isOpen(v){return this._openSet.has(v)}isClose(v){return this._closeSet.has(v)}static _toSet(v){const k=new Set;for(const D of v)k.add(D);return k}}function L(m){const v=m.length;m=m.map(W=>[W[0].toLowerCase(),W[1].toLowerCase()]);const k=[];for(let W=0;W<v;W++)k[W]=W;const D=(W,Y)=>{const[ne,j]=W,[Q,X]=Y;return ne===Q||ne===X||j===Q||j===X},x=(W,Y)=>{const ne=Math.min(W,Y),j=Math.max(W,Y);for(let Q=0;Q<v;Q++)k[Q]===j&&(k[Q]=ne)};for(let W=0;W<v;W++){const Y=m[W];for(let ne=W+1;ne<v;ne++){const j=m[ne];D(Y,j)&&x(k[W],k[ne])}}const A=[];for(let W=0;W<v;W++){const Y=[],ne=[];for(let j=0;j<v;j++)if(k[j]===W){const[Q,X]=m[j];Y.push(Q),ne.push(X)}Y.length>0&&A.push({open:Y,close:ne})}return A}class U{constructor(v,k){this._richEditBracketsBrand=void 0;const D=L(k);this.brackets=D.map((x,A)=>new $(v,A,x.open,x.close,p(x.open,x.close,D,A),d(x.open,x.close,D,A))),this.forwardRegex=g(this.brackets),this.reversedRegex=h(this.brackets),this.textIsBracket={},this.textIsOpenBracket={},this.maxBracketLength=0;for(const x of this.brackets){for(const A of x.open)this.textIsBracket[A]=x,this.textIsOpenBracket[A]=!0,this.maxBracketLength=Math.max(this.maxBracketLength,A.length);for(const A of x.close)this.textIsBracket[A]=x,this.textIsOpenBracket[A]=!1,this.maxBracketLength=Math.max(this.maxBracketLength,A.length)}}}function P(m,v,k,D){for(let x=0,A=v.length;x<A;x++){if(x===k)continue;const W=v[x];for(const Y of W.open)Y.indexOf(m)>=0&&D.push(Y);for(const Y of W.close)Y.indexOf(m)>=0&&D.push(Y)}}function B(m,v){return m.length-v.length}function T(m){if(m.length<=1)return m;const v=[],k=new Set;for(const D of m)k.has(D)||(v.push(D),k.add(D));return v}function p(m,v,k,D){let x=[];x=x.concat(m),x=x.concat(v);for(let A=0,W=x.length;A<W;A++)P(x[A],k,D,x);return x=T(x),x.sort(B),x.reverse(),u(x)}function d(m,v,k,D){let x=[];x=x.concat(m),x=x.concat(v);for(let A=0,W=x.length;A<W;A++)P(x[A],k,D,x);return x=T(x),x.sort(B),x.reverse(),u(x.map(w))}function g(m){let v=[];for(const k of m){for(const D of k.open)v.push(D);for(const D of k.close)v.push(D)}return v=T(v),u(v)}function h(m){let v=[];for(const k of m){for(const D of k.open)v.push(D);for(const D of k.close)v.push(D)}return v=T(v),u(v.map(w))}function l(m){const v=/^[\w ]+$/.test(m);return m=b.bm(m),v?`\\b${m}\\b`:m}function u(m){const v=`(${m.map(l).join(")|(")})`;return b.OS(v,!0)}const w=function(){function m(D){if(o.aI){const x=new Uint16Array(D.length);let A=0;for(let W=D.length-1;W>=0;W--)x[A++]=D.charCodeAt(W);return o.b7().decode(x)}else{const x=[];let A=0;for(let W=D.length-1;W>=0;W--)x[A++]=D.charAt(W);return x.join("")}}let v=null,k=null;return function(x){return v!==x&&(v=x,k=m(v)),k}}();class C{static _findPrevBracketInText(v,k,D,x){const A=D.match(v);if(!A)return null;const W=D.length-(A.index||0),Y=A[0].length,ne=x+W;return new K.Q(k,ne-Y+1,k,ne+1)}static findPrevBracketInRange(v,k,D,x,A){const Y=w(D).substring(D.length-A,D.length-x);return this._findPrevBracketInText(v,k,Y,x)}static findNextBracketInText(v,k,D,x){const A=D.match(v);if(!A)return null;const W=A.index||0,Y=A[0].length;if(Y===0)return null;const ne=x+W;return new K.Q(k,ne+1,k,ne+1+Y)}static findNextBracketInRange(v,k,D,x,A){const W=D.substring(x,A);return this.findNextBracketInText(v,k,W,x)}}},2106:(rt,ye,y)=>{y.d(ye,{Jh:()=>P,Wj:()=>k,at:()=>v,ci:()=>l,fV:()=>C,uI:()=>m,vl:()=>h});var b=y(94327),o=y(10998),K=y(85525),$=y(23013);const L=!1,U=!1;var P;(function(D){D.None=()=>o.jG.None;function x(ce){if(U){const{onListenerDidAdd:pe}=ce,be=d.create();let ge=0;ce.onListenerDidAdd=()=>{++ge===2&&(console.warn("snapshotted emitter LIKELY used public and SHOULD HAVE BEEN created with DisposableStore. snapshotted here"),be.print()),pe?.()}}}function A(ce){return(pe,be=null,ge)=>{let ke=!1,We;return We=ce(Ge=>{if(!ke)return We?We.dispose():ke=!0,pe.call(be,Ge)},null,ge),ke&&We.dispose(),We}}D.once=A;function W(ce,pe,be){return R((ge,ke=null,We)=>ce(Ge=>ge.call(ke,pe(Ge)),null,We),be)}D.map=W;function Y(ce,pe,be){return R((ge,ke=null,We)=>ce(Ge=>{pe(Ge),ge.call(ke,Ge)},null,We),be)}D.forEach=Y;function ne(ce,pe,be){return R((ge,ke=null,We)=>ce(Ge=>pe(Ge)&&ge.call(ke,Ge),null,We),be)}D.filter=ne;function j(ce){return ce}D.signal=j;function Q(...ce){return(pe,be=null,ge)=>(0,o.qE)(...ce.map(ke=>ke(We=>pe.call(be,We),null,ge)))}D.any=Q;function X(ce,pe,be,ge){let ke=be;return W(ce,We=>(ke=pe(ke,We),ke),ge)}D.reduce=X;function R(ce,pe){let be;const ge={onFirstListenerAdd(){be=ce(ke.fire,ke)},onLastListenerRemove(){be?.dispose()}};pe||x(ge);const ke=new h(ge);return pe?.add(ke),ke.event}function H(ce,pe,be=100,ge=!1,ke,We){let Ge,Ae,he,Pe=0;const $e={leakWarningThreshold:ke,onFirstListenerAdd(){Ge=ce(ft=>{Pe++,Ae=pe(Ae,ft),ge&&!he&&(it.fire(Ae),Ae=void 0),clearTimeout(he),he=setTimeout(()=>{const Wt=Ae;Ae=void 0,he=void 0,(!ge||Pe>1)&&it.fire(Wt),Pe=0},be)})},onLastListenerRemove(){Ge.dispose()}};We||x($e);const it=new h($e);return We?.add(it),it.event}D.debounce=H;function Z(ce,pe=(ge,ke)=>ge===ke,be){let ge=!0,ke;return ne(ce,We=>{const Ge=ge||!pe(We,ke);return ge=!1,ke=We,Ge},be)}D.latch=Z;function N(ce,pe,be){return[D.filter(ce,pe,be),D.filter(ce,ge=>!pe(ge),be)]}D.split=N;function G(ce,pe=!1,be=[]){let ge=be.slice(),ke=ce(Ae=>{ge?ge.push(Ae):Ge.fire(Ae)});const We=()=>{ge?.forEach(Ae=>Ge.fire(Ae)),ge=null},Ge=new h({onFirstListenerAdd(){ke||(ke=ce(Ae=>Ge.fire(Ae)))},onFirstListenerDidAdd(){ge&&(pe?setTimeout(We):We())},onLastListenerRemove(){ke&&ke.dispose(),ke=null}});return Ge.event}D.buffer=G;class O{constructor(pe){this.event=pe,this.disposables=new o.Cm}map(pe){return new O(W(this.event,pe,this.disposables))}forEach(pe){return new O(Y(this.event,pe,this.disposables))}filter(pe){return new O(ne(this.event,pe,this.disposables))}reduce(pe,be){return new O(X(this.event,pe,be,this.disposables))}latch(){return new O(Z(this.event,void 0,this.disposables))}debounce(pe,be=100,ge=!1,ke){return new O(H(this.event,pe,be,ge,ke,this.disposables))}on(pe,be,ge){return this.event(pe,be,ge)}once(pe,be,ge){return A(this.event)(pe,be,ge)}dispose(){this.disposables.dispose()}}function te(ce){return new O(ce)}D.chain=te;function oe(ce,pe,be=ge=>ge){const ge=(...Ae)=>Ge.fire(be(...Ae)),ke=()=>ce.on(pe,ge),We=()=>ce.removeListener(pe,ge),Ge=new h({onFirstListenerAdd:ke,onLastListenerRemove:We});return Ge.event}D.fromNodeEventEmitter=oe;function ue(ce,pe,be=ge=>ge){const ge=(...Ae)=>Ge.fire(be(...Ae)),ke=()=>ce.addEventListener(pe,ge),We=()=>ce.removeEventListener(pe,ge),Ge=new h({onFirstListenerAdd:ke,onLastListenerRemove:We});return Ge.event}D.fromDOMEventEmitter=ue;function E(ce){return new Promise(pe=>A(ce)(pe))}D.toPromise=E;function Qe(ce,pe){return pe(void 0),ce(be=>pe(be))}D.runAndSubscribe=Qe;function Ke(ce,pe){let be=null;function ge(We){be?.dispose(),be=new o.Cm,pe(We,be)}ge(void 0);const ke=ce(We=>ge(We));return(0,o.s)(()=>{ke.dispose(),be?.dispose()})}D.runAndSubscribeWithStore=Ke;class Se{constructor(pe,be){this.obs=pe,this._counter=0,this._hasChanged=!1;const ge={onFirstListenerAdd:()=>{pe.addObserver(this)},onLastListenerRemove:()=>{pe.removeObserver(this)}};be||x(ge),this.emitter=new h(ge),be&&be.add(this.emitter)}beginUpdate(pe){this._counter++}handleChange(pe,be){this._hasChanged=!0}endUpdate(pe){--this._counter===0&&this._hasChanged&&(this._hasChanged=!1,this.emitter.fire(this.obs.get()))}}function Me(ce,pe){return new Se(ce,pe).emitter.event}D.fromObservable=Me})(P||(P={}));class B{constructor(x){this._listenerCount=0,this._invocationCount=0,this._elapsedOverall=0,this._name=`${x}_${B._idPool++}`}start(x){this._stopWatch=new $.W(!0),this._listenerCount=x}stop(){if(this._stopWatch){const x=this._stopWatch.elapsed();this._elapsedOverall+=x,this._invocationCount+=1,console.info(`did FIRE ${this._name}: elapsed_ms: ${x.toFixed(5)}, listener: ${this._listenerCount} (elapsed_overall: ${this._elapsedOverall.toFixed(2)}, invocations: ${this._invocationCount})`),this._stopWatch=void 0}}}B._idPool=0;let T=-1;class p{constructor(x,A=Math.random().toString(18).slice(2,5)){this.customThreshold=x,this.name=A,this._warnCountdown=0}dispose(){this._stacks&&this._stacks.clear()}check(x,A){let W=T;if(typeof this.customThreshold=="number"&&(W=this.customThreshold),W<=0||A<W)return;this._stacks||(this._stacks=new Map);const Y=this._stacks.get(x.value)||0;if(this._stacks.set(x.value,Y+1),this._warnCountdown-=1,this._warnCountdown<=0){this._warnCountdown=W*.5;let ne,j=0;for(const[Q,X]of this._stacks)(!ne||j<X)&&(ne=Q,j=X);console.warn(`[${this.name}] potential listener LEAK detected, having ${A} listeners already. MOST frequent listener (${j}):`),console.warn(ne)}return()=>{const ne=this._stacks.get(x.value)||0;this._stacks.set(x.value,ne-1)}}}class d{constructor(x){this.value=x}static create(){var x;return new d((x=new Error().stack)!==null&&x!==void 0?x:"")}print(){console.warn(this.value.split(` `).slice(2).join(` `))}}class g{constructor(x,A,W){this.callback=x,this.callbackThis=A,this.stack=W,this.subscription=new o.St}invoke(x){this.callback.call(this.callbackThis,x)}}class h{constructor(x){var A,W;this._disposed=!1,this._options=x,this._leakageMon=T>0?new p(this._options&&this._options.leakWarningThreshold):void 0,this._perfMon=!((A=this._options)===null||A===void 0)&&A._profName?new B(this._options._profName):void 0,this._deliveryQueue=(W=this._options)===null||W===void 0?void 0:W.deliveryQueue}dispose(){var x,A,W,Y;if(!this._disposed){if(this._disposed=!0,this._listeners){if(L){const ne=Array.from(this._listeners);queueMicrotask(()=>{var j;for(const Q of ne)Q.subscription.isset()&&(Q.subscription.unset(),(j=Q.stack)===null||j===void 0||j.print())})}this._listeners.clear()}(x=this._deliveryQueue)===null||x===void 0||x.clear(this),(W=(A=this._options)===null||A===void 0?void 0:A.onLastListenerRemove)===null||W===void 0||W.call(A),(Y=this._leakageMon)===null||Y===void 0||Y.dispose()}}get event(){return this._event||(this._event=(x,A,W)=>{var Y,ne,j;this._listeners||(this._listeners=new K.w);const Q=this._listeners.isEmpty();Q&&(!((Y=this._options)===null||Y===void 0)&&Y.onFirstListenerAdd)&&this._options.onFirstListenerAdd(this);let X,R;this._leakageMon&&this._listeners.size>=30&&(R=d.create(),X=this._leakageMon.check(R,this._listeners.size+1)),L&&(R=R??d.create());const H=new g(x,A,R),Z=this._listeners.push(H);Q&&(!((ne=this._options)===null||ne===void 0)&&ne.onFirstListenerDidAdd)&&this._options.onFirstListenerDidAdd(this),!((j=this._options)===null||j===void 0)&&j.onListenerDidAdd&&this._options.onListenerDidAdd(this,x,A);const N=H.subscription.set(()=>{X?.(),this._disposed||(Z(),this._options&&this._options.onLastListenerRemove&&(this._listeners&&!this._listeners.isEmpty()||this._options.onLastListenerRemove(this)))});return W instanceof o.Cm?W.add(N):Array.isArray(W)&&W.push(N),N}),this._event}fire(x){var A,W;if(this._listeners){this._deliveryQueue||(this._deliveryQueue=new u);for(const Y of this._listeners)this._deliveryQueue.push(this,Y,x);(A=this._perfMon)===null||A===void 0||A.start(this._deliveryQueue.size),this._deliveryQueue.deliver(),(W=this._perfMon)===null||W===void 0||W.stop()}}}class l{constructor(){this._queue=new K.w}get size(){return this._queue.size}push(x,A,W){this._queue.push(new w(x,A,W))}clear(x){const A=new K.w;for(const W of this._queue)W.emitter!==x&&A.push(W);this._queue=A}deliver(){for(;this._queue.size>0;){const x=this._queue.shift();try{x.listener.invoke(x.event)}catch(A){(0,b.dz)(A)}}}}class u extends l{clear(x){this._queue.clear()}}class w{constructor(x,A,W){this.emitter=x,this.listener=A,this.event=W}}class C extends h{constructor(x){super(x),this._isPaused=0,this._eventQueue=new K.w,this._mergeFn=x?.merge}pause(){this._isPaused++}resume(){if(this._isPaused!==0&&--this._isPaused===0)if(this._mergeFn){const x=Array.from(this._eventQueue);this._eventQueue.clear(),super.fire(this._mergeFn(x))}else for(;!this._isPaused&&this._eventQueue.size!==0;)super.fire(this._eventQueue.shift())}fire(x){this._listeners&&(this._isPaused!==0?this._eventQueue.push(x):super.fire(x))}}class m extends C{constructor(x){var A;super(x),this._delay=(A=x.delay)!==null&&A!==void 0?A:100}fire(x){this._handle||(this.pause(),this._handle=setTimeout(()=>{this._handle=void 0,this.resume()},this._delay)),super.fire(x)}}class v{constructor(){this.buffers=[]}wrapEvent(x){return(A,W,Y)=>x(ne=>{const j=this.buffers[this.buffers.length-1];j?j.push(()=>A.call(W,ne)):A.call(W,ne)},void 0,Y)}bufferEvents(x){const A=[];this.buffers.push(A);const W=x();return this.buffers.pop(),A.forEach(Y=>Y()),W}}class k{constructor(){this.listening=!1,this.inputEvent=P.None,this.inputEventListener=o.jG.None,this.emitter=new h({onFirstListenerDidAdd:()=>{this.listening=!0,this.inputEventListener=this.inputEvent(this.emitter.fire,this.emitter)},onLastListenerRemove:()=>{this.listening=!1,this.inputEventListener.dispose()}}),this.event=this.emitter.event}set input(x){this.inputEvent=x,this.listening&&(this.inputEventListener.dispose(),this.inputEventListener=x(this.emitter.fire,this.emitter))}dispose(){this.inputEventListener.dispose(),this.emitter.dispose()}}},3338:(rt,ye,y)=>{y.d(ye,{h:()=>o});var b=y(82399);const o=(0,b.u1)("clipboardService")},3765:(rt,ye,y)=>{y.d(ye,{AM:()=>p,kg:()=>T});var b=function(l,u,w,C){function m(v){return v instanceof w?v:new w(function(k){k(v)})}return new(w||(w=Promise))(function(v,k){function D(W){try{A(C.next(W))}catch(Y){k(Y)}}function x(W){try{A(C.throw(W))}catch(Y){k(Y)}}function A(W){W.done?v(W.value):m(W.value).then(D,x)}A((C=C.apply(l,u||[])).next())})};let o=typeof document<"u"&&document.location&&document.location.hash.indexOf("pseudo=true")>=0;const K="i-default";function $(l,u){let w;return u.length===0?w=l:w=l.replace(/\{(\d+)\}/g,(C,m)=>{const v=m[0],k=u[v];let D=C;return typeof k=="string"?D=k:(typeof k=="number"||typeof k=="boolean"||k===void 0||k===null)&&(D=String(k)),D}),o&&(w="\uFF3B"+w.replace(/[aouei]/g,"$&$&")+"\uFF3D"),w}function L(l,u){let w=l[u];return w||(w=l["*"],w)?w:null}function U(l){return l.charAt(l.length-1)==="/"?l:l+"/"}function P(l,u,w){return b(this,void 0,void 0,function*(){const C=U(l)+U(u)+"vscode/"+U(w),m=yield fetch(C);if(m.ok)return yield m.json();throw new Error(`${m.status} - ${m.statusText}`)})}function B(l){return function(u,w){const C=Array.prototype.slice.call(arguments,2);return $(l[u],C)}}function T(l,u,...w){return $(u,w)}function p(l){}function d(l){o=l}function g(l,u){var w;return{localize:B(u[l]),getConfiguredDefaultLocale:(w=u.getConfiguredDefaultLocale)!==null&&w!==void 0?w:C=>{}}}function h(l,u,w,C){var m;const v=(m=C["vs/nls"])!==null&&m!==void 0?m:{};if(!l||l.length===0)return w({localize:T,getConfiguredDefaultLocale:()=>{var W;return(W=v.availableLanguages)===null||W===void 0?void 0:W["*"]}});const k=v.availableLanguages?L(v.availableLanguages,l):null,D=k===null||k===K;let x=".nls";D||(x=x+"."+k);const A=W=>{Array.isArray(W)?W.localize=B(W):W.localize=B(W[l]),W.getConfiguredDefaultLocale=()=>{var Y;return(Y=v.availableLanguages)===null||Y===void 0?void 0:Y["*"]},w(W)};typeof v.loadBundle=="function"?v.loadBundle(l,k,(W,Y)=>{W?u([l+".nls"],A):A(Y)}):v.translationServiceUrl&&!D?b(this,void 0,void 0,function*(){var W;try{const Y=yield P(v.translationServiceUrl,k,l);return A(Y)}catch(Y){if(!k.includes("-"))return console.error(Y),u([l+".nls"],A);try{const ne=k.split("-")[0],j=yield P(v.translationServiceUrl,ne,l);return(W=v.availableLanguages)!==null&&W!==void 0||(v.availableLanguages={}),v.availableLanguages["*"]=ne,A(j)}catch(ne){return console.error(ne),u([l+".nls"],A)}}}):u([l+x],A,W=>{if(x===".nls"){console.error("Failed trying to load default language strings",W);return}console.error(`Failed to load message bundle for language ${k}. Falling back to the default language:`,W),u([l+".nls"],A)})}},3902:(rt,ye,y)=>{y.d(ye,{W:()=>b});function b(o){let K=0,$=0,L=0,U=0;for(let P=0,B=o.length;P<B;P++){const T=o.charCodeAt(P);T===13?(K===0&&($=P),K++,P+1<B&&o.charCodeAt(P+1)===10?(U|=2,P++):U|=3,L=P+1):T===10&&(U|=1,K===0&&($=P),K++,L=P+1)}return K===0&&($=o.length),[K,$,o.length-L,U]}},4169:(rt,ye,y)=>{y.d(ye,{PE:()=>li,aG:()=>Ci,er:()=>zt,Ei:()=>Hn,YD:()=>qt,Nf:()=>Qi,cH:()=>Zi});var b=y(14333),o=y(13338),K=y(78903),$=y(2106),L=y(10998),U=y(67954);class P{constructor(n,c){this.renderer=n,this.modelProvider=c}get templateId(){return this.renderer.templateId}renderTemplate(n){return{data:this.renderer.renderTemplate(n),disposable:L.jG.None}}renderElement(n,c,I,F){if(I.disposable&&I.disposable.dispose(),!I.data)return;const J=this.modelProvider();if(J.isResolved(n))return this.renderer.renderElement(J.get(n),n,I.data,F);const ae=new K.Q,de=J.resolve(n,ae.token);I.disposable={dispose:()=>ae.cancel()},this.renderer.renderPlaceholder(n,I.data),de.then(Ce=>this.renderer.renderElement(Ce,n,I.data,F))}disposeTemplate(n){n.disposable&&(n.disposable.dispose(),n.disposable=void 0),n.data&&(this.renderer.disposeTemplate(n.data),n.data=void 0)}}class B{constructor(n,c){this.modelProvider=n,this.accessibilityProvider=c}getWidgetAriaLabel(){return this.accessibilityProvider.getWidgetAriaLabel()}getAriaLabel(n){const c=this.modelProvider();return c.isResolved(n)?this.accessibilityProvider.getAriaLabel(c.get(n)):null}}function T(a,n){return Object.assign(Object.assign({},n),{accessibilityProvider:n.accessibilityProvider&&new B(a,n.accessibilityProvider)})}class p{constructor(n,c,I,F,J={}){const ae=()=>this.model,de=F.map(Ce=>new P(Ce,ae));this.list=new U.B8(n,c,I,de,T(ae,J))}updateOptions(n){this.list.updateOptions(n)}getHTMLElement(){return this.list.getHTMLElement()}get onDidFocus(){return this.list.onDidFocus}get onDidDispose(){return this.list.onDidDispose}get onMouseDblClick(){return $.Jh.map(this.list.onMouseDblClick,({element:n,index:c,browserEvent:I})=>({element:n===void 0?void 0:this._model.get(n),index:c,browserEvent:I}))}get onPointer(){return $.Jh.map(this.list.onPointer,({element:n,index:c,browserEvent:I})=>({element:n===void 0?void 0:this._model.get(n),index:c,browserEvent:I}))}get onDidChangeSelection(){return $.Jh.map(this.list.onDidChangeSelection,({elements:n,indexes:c,browserEvent:I})=>({elements:n.map(F=>this._model.get(F)),indexes:c,browserEvent:I}))}get model(){return this._model}set model(n){this._model=n,this.list.splice(0,this.list.length,(0,o.y1)(n.length))}getFocus(){return this.list.getFocus()}getSelection(){return this.list.getSelection()}getSelectedElements(){return this.getSelection().map(n=>this.model.get(n))}style(n){this.list.style(n)}dispose(){this.list.dispose()}}var d=y(67003);class g{constructor(n,c,I){this.columns=n,this.getColumnSize=I,this.templateId=g.TemplateId,this.renderedTemplates=new Set;const F=new Map(c.map(J=>[J.templateId,J]));this.renderers=[];for(const J of n){const ae=F.get(J.templateId);if(!ae)throw new Error(`Table cell renderer for template id ${J.templateId} not found.`);this.renderers.push(ae)}}renderTemplate(n){const c=(0,b.BC)(n,(0,b.$)(".monaco-table-tr")),I=[],F=[];for(let ae=0;ae<this.columns.length;ae++){const de=this.renderers[ae],Ce=(0,b.BC)(c,(0,b.$)(".monaco-table-td",{"data-col-index":ae}));Ce.style.width=`${this.getColumnSize(ae)}px`,I.push(Ce),F.push(de.renderTemplate(Ce))}const J={container:n,cellContainers:I,cellTemplateData:F};return this.renderedTemplates.add(J),J}renderElement(n,c,I,F){for(let J=0;J<this.columns.length;J++){const de=this.columns[J].project(n);this.renderers[J].renderElement(de,c,I.cellTemplateData[J],F)}}disposeElement(n,c,I,F){for(let J=0;J<this.columns.length;J++){const ae=this.renderers[J];if(ae.disposeElement){const Ce=this.columns[J].project(n);ae.disposeElement(Ce,c,I.cellTemplateData[J],F)}}}disposeTemplate(n){for(let c=0;c<this.columns.length;c++)this.renderers[c].disposeTemplate(n.cellTemplateData[c]);(0,b.w_)(n.container),this.renderedTemplates.delete(n)}layoutColumn(n,c){for(const{cellContainers:I}of this.renderedTemplates)I[n].style.width=`${c}px`}}g.TemplateId="row";function h(a){return{getHeight(n){return a.getHeight(n)},getTemplateId(){return g.TemplateId}}}class l{constructor(n,c){this.column=n,this.index=c,this._onDidLayout=new $.vl,this.onDidLayout=this._onDidLayout.event,this.element=(0,b.$)(".monaco-table-th",{"data-col-index":c,title:n.tooltip},n.label)}get minimumSize(){var n;return(n=this.column.minimumWidth)!==null&&n!==void 0?n:120}get maximumSize(){var n;return(n=this.column.maximumWidth)!==null&&n!==void 0?n:Number.POSITIVE_INFINITY}get onDidChange(){var n;return(n=this.column.onDidChangeWidthConstraints)!==null&&n!==void 0?n:$.Jh.None}layout(n){this._onDidLayout.fire([this.index,n])}}class u{constructor(n,c,I,F,J,ae){this.virtualDelegate=I,this.domId=`table_id_${++u.InstanceCount}`,this.disposables=new L.Cm,this.cachedWidth=0,this.cachedHeight=0,this.domNode=(0,b.BC)(c,(0,b.$)(`.monaco-table.${this.domId}`));const de=F.map((Ne,He)=>new l(Ne,He)),Ce={size:de.reduce((Ne,He)=>Ne+He.column.weight,0),views:de.map(Ne=>({size:Ne.column.weight,view:Ne}))};this.splitview=this.disposables.add(new d.U(this.domNode,{orientation:1,scrollbarVisibility:2,getSashOrthogonalSize:()=>this.cachedHeight,descriptor:Ce})),this.splitview.el.style.height=`${I.headerRowHeight}px`,this.splitview.el.style.lineHeight=`${I.headerRowHeight}px`;const Ee=new g(F,J,Ne=>this.splitview.getViewSize(Ne));this.list=this.disposables.add(new U.B8(n,this.domNode,h(I),[Ee],ae)),$.Jh.any(...de.map(Ne=>Ne.onDidLayout))(([Ne,He])=>Ee.layoutColumn(Ne,He),null,this.disposables),this.splitview.onDidSashReset(Ne=>{const He=F.reduce((et,ot)=>et+ot.weight,0),Ze=F[Ne].weight/He*this.cachedWidth;this.splitview.resizeView(Ne,Ze)},null,this.disposables),this.styleElement=(0,b.li)(this.domNode),this.style({})}get onDidChangeFocus(){return this.list.onDidChangeFocus}get onDidChangeSelection(){return this.list.onDidChangeSelection}get onMouseDblClick(){return this.list.onMouseDblClick}get onPointer(){return this.list.onPointer}get onDidFocus(){return this.list.onDidFocus}get onDidDispose(){return this.list.onDidDispose}updateOptions(n){this.list.updateOptions(n)}splice(n,c,I=[]){this.list.splice(n,c,I)}getHTMLElement(){return this.domNode}style(n){const c=[];c.push(`.monaco-table.${this.domId} > .monaco-split-view2 .monaco-sash.vertical::before { top: ${this.virtualDelegate.headerRowHeight+1}px; height: calc(100% - ${this.virtualDelegate.headerRowHeight}px); }`),this.styleElement.textContent=c.join(` `),this.list.style(n)}getSelectedElements(){return this.list.getSelectedElements()}getSelection(){return this.list.getSelection()}getFocus(){return this.list.getFocus()}dispose(){this.disposables.dispose()}}u.InstanceCount=0;var w=y(34061),C=y(87594),m=y(77439),v=y(6595),k=y(83022),D=y(50585),x;(function(a){a[a.Unknown=0]="Unknown",a[a.Twistie=1]="Twistie",a[a.Element=2]="Element",a[a.Filter=3]="Filter"})(x||(x={}));class A extends Error{constructor(n,c){super(`TreeError [${n}] ${c}`)}}class W{constructor(n){this.fn=n,this._map=new WeakMap}map(n){let c=this._map.get(n);return c||(c=this.fn(n),this._map.set(n,c)),c}}var Y=y(65958),ne=y(6341),j=y(17954);function Q(a){return typeof a=="object"&&"visibility"in a&&"data"in a}function X(a){switch(a){case!0:return 1;case!1:return 0;default:return a}}function R(a){return typeof a.collapsible=="boolean"}class H{constructor(n,c,I,F={}){this.user=n,this.list=c,this.rootRef=[],this.eventBufferer=new $.at,this._onDidChangeCollapseState=new $.vl,this.onDidChangeCollapseState=this.eventBufferer.wrapEvent(this._onDidChangeCollapseState.event),this._onDidChangeRenderNodeCount=new $.vl,this.onDidChangeRenderNodeCount=this.eventBufferer.wrapEvent(this._onDidChangeRenderNodeCount.event),this._onDidSplice=new $.vl,this.onDidSplice=this._onDidSplice.event,this.refilterDelayer=new Y.ve(Y.hW),this.collapseByDefault=typeof F.collapseByDefault>"u"?!1:F.collapseByDefault,this.filter=F.filter,this.autoExpandSingleChildren=typeof F.autoExpandSingleChildren>"u"?!1:F.autoExpandSingleChildren,this.root={parent:void 0,element:I,children:[],depth:0,visibleChildrenCount:0,visibleChildIndex:-1,collapsible:!1,collapsed:!1,renderNodeCount:0,visibility:1,visible:!0,filterData:void 0}}splice(n,c,I=j.f.empty(),F={}){if(n.length===0)throw new A(this.user,"Invalid tree location");F.diffIdentityProvider?this.spliceSmart(F.diffIdentityProvider,n,c,I,F):this.spliceSimple(n,c,I,F)}spliceSmart(n,c,I,F,J,ae){var de;F===void 0&&(F=j.f.empty()),ae===void 0&&(ae=(de=J.diffDepth)!==null&&de!==void 0?de:0);const{parentNode:Ce}=this.getParentNodeWithListIndex(c);if(!Ce.lastDiffIds)return this.spliceSimple(c,I,F,J);const Ee=[...F],Ne=c[c.length-1],He=new ne.uP({getElements:()=>Ce.lastDiffIds},{getElements:()=>[...Ce.children.slice(0,Ne),...Ee,...Ce.children.slice(Ne+I)].map(_t=>n.getId(_t.element).toString())}).ComputeDiff(!1);if(He.quitEarly)return Ce.lastDiffIds=void 0,this.spliceSimple(c,I,Ee,J);const Ze=c.slice(0,-1),et=(_t,Ft,ci)=>{if(ae>0)for(let Oi=0;Oi<ci;Oi++)_t--,Ft--,this.spliceSmart(n,[...Ze,_t,0],Number.MAX_SAFE_INTEGER,Ee[Ft].children,J,ae-1)};let ot=Math.min(Ce.children.length,Ne+I),lt=Ee.length;for(const _t of He.changes.sort((Ft,ci)=>ci.originalStart-Ft.originalStart))et(ot,lt,ot-(_t.originalStart+_t.originalLength)),ot=_t.originalStart,lt=_t.modifiedStart-Ne,this.spliceSimple([...Ze,ot],_t.originalLength,j.f.slice(Ee,lt,lt+_t.modifiedLength),J);et(ot,lt,ot)}spliceSimple(n,c,I=j.f.empty(),{onDidCreateNode:F,onDidDeleteNode:J,diffIdentityProvider:ae}){const{parentNode:de,listIndex:Ce,revealed:Ee,visible:Ne}=this.getParentNodeWithListIndex(n),He=[],Ze=j.f.map(I,Yi=>this.createTreeNode(Yi,de,de.visible?1:0,Ee,He,F)),et=n[n.length-1],ot=de.children.length>0;let lt=0;for(let Yi=et;Yi>=0&&Yi<de.children.length;Yi--){const Ei=de.children[Yi];if(Ei.visible){lt=Ei.visibleChildIndex;break}}const _t=[];let Ft=0,ci=0;for(const Yi of Ze)_t.push(Yi),ci+=Yi.renderNodeCount,Yi.visible&&(Yi.visibleChildIndex=lt+Ft++);const Oi=(0,o.V4)(de.children,et,c,_t);ae?de.lastDiffIds?(0,o.V4)(de.lastDiffIds,et,c,_t.map(Yi=>ae.getId(Yi.element).toString())):de.lastDiffIds=de.children.map(Yi=>ae.getId(Yi.element).toString()):de.lastDiffIds=void 0;let on=0;for(const Yi of Oi)Yi.visible&&on++;if(on!==0)for(let Yi=et+_t.length;Yi<de.children.length;Yi++){const Ei=de.children[Yi];Ei.visible&&(Ei.visibleChildIndex-=on)}if(de.visibleChildrenCount+=Ft-on,Ee&&Ne){const Yi=Oi.reduce((Ei,An)=>Ei+(An.visible?An.renderNodeCount:0),0);this._updateAncestorsRenderNodeCount(de,ci-Yi),this.list.splice(Ce,Yi,He)}if(Oi.length>0&&J){const Yi=Ei=>{J(Ei),Ei.children.forEach(Yi)};Oi.forEach(Yi)}this._onDidSplice.fire({insertedNodes:_t,deletedNodes:Oi});const gn=de.children.length>0;ot!==gn&&this.setCollapsible(n.slice(0,-1),gn);let hn=de;for(;hn;){if(hn.visibility===2){this.refilterDelayer.trigger(()=>this.refilter());break}hn=hn.parent}}rerender(n){if(n.length===0)throw new A(this.user,"Invalid tree location");const{node:c,listIndex:I,revealed:F}=this.getTreeNodeWithListIndex(n);c.visible&&F&&this.list.splice(I,1,[c])}has(n){return this.hasTreeNode(n)}getListIndex(n){const{listIndex:c,visible:I,revealed:F}=this.getTreeNodeWithListIndex(n);return I&&F?c:-1}getListRenderCount(n){return this.getTreeNode(n).renderNodeCount}isCollapsible(n){return this.getTreeNode(n).collapsible}setCollapsible(n,c){const I=this.getTreeNode(n);typeof c>"u"&&(c=!I.collapsible);const F={collapsible:c};return this.eventBufferer.bufferEvents(()=>this._setCollapseState(n,F))}isCollapsed(n){return this.getTreeNode(n).collapsed}setCollapsed(n,c,I){const F=this.getTreeNode(n);typeof c>"u"&&(c=!F.collapsed);const J={collapsed:c,recursive:I||!1};return this.eventBufferer.bufferEvents(()=>this._setCollapseState(n,J))}_setCollapseState(n,c){const{node:I,listIndex:F,revealed:J}=this.getTreeNodeWithListIndex(n),ae=this._setListNodeCollapseState(I,F,J,c);if(I!==this.root&&this.autoExpandSingleChildren&&ae&&!R(c)&&I.collapsible&&!I.collapsed&&!c.recursive){let de=-1;for(let Ce=0;Ce<I.children.length;Ce++)if(I.children[Ce].visible)if(de>-1){de=-1;break}else de=Ce;de>-1&&this._setCollapseState([...n,de],c)}return ae}_setListNodeCollapseState(n,c,I,F){const J=this._setNodeCollapseState(n,F,!1);if(!I||!n.visible||!J)return J;const ae=n.renderNodeCount,de=this.updateNodeAfterCollapseChange(n),Ce=ae-(c===-1?0:1);return this.list.splice(c+1,Ce,de.slice(1)),J}_setNodeCollapseState(n,c,I){let F;if(n===this.root?F=!1:(R(c)?(F=n.collapsible!==c.collapsible,n.collapsible=c.collapsible):n.collapsible?(F=n.collapsed!==c.collapsed,n.collapsed=c.collapsed):F=!1,F&&this._onDidChangeCollapseState.fire({node:n,deep:I})),!R(c)&&c.recursive)for(const J of n.children)F=this._setNodeCollapseState(J,c,!0)||F;return F}expandTo(n){this.eventBufferer.bufferEvents(()=>{let c=this.getTreeNode(n);for(;c.parent;)c=c.parent,n=n.slice(0,n.length-1),c.collapsed&&this._setCollapseState(n,{collapsed:!1,recursive:!1})})}refilter(){const n=this.root.renderNodeCount,c=this.updateNodeAfterFilterChange(this.root);this.list.splice(0,n,c),this.refilterDelayer.cancel()}createTreeNode(n,c,I,F,J,ae){const de={parent:c,element:n.element,children:[],depth:c.depth+1,visibleChildrenCount:0,visibleChildIndex:-1,collapsible:typeof n.collapsible=="boolean"?n.collapsible:typeof n.collapsed<"u",collapsed:typeof n.collapsed>"u"?this.collapseByDefault:n.collapsed,renderNodeCount:1,visibility:1,visible:!0,filterData:void 0},Ce=this._filterNode(de,I);de.visibility=Ce,F&&J.push(de);const Ee=n.children||j.f.empty(),Ne=F&&Ce!==0&&!de.collapsed,He=j.f.map(Ee,ot=>this.createTreeNode(ot,de,Ce,Ne,J,ae));let Ze=0,et=1;for(const ot of He)de.children.push(ot),et+=ot.renderNodeCount,ot.visible&&(ot.visibleChildIndex=Ze++);return de.collapsible=de.collapsible||de.children.length>0,de.visibleChildrenCount=Ze,de.visible=Ce===2?Ze>0:Ce===1,de.visible?de.collapsed||(de.renderNodeCount=et):(de.renderNodeCount=0,F&&J.pop()),ae?.(de),de}updateNodeAfterCollapseChange(n){const c=n.renderNodeCount,I=[];return this._updateNodeAfterCollapseChange(n,I),this._updateAncestorsRenderNodeCount(n.parent,I.length-c),I}_updateNodeAfterCollapseChange(n,c){if(n.visible===!1)return 0;if(c.push(n),n.renderNodeCount=1,!n.collapsed)for(const I of n.children)n.renderNodeCount+=this._updateNodeAfterCollapseChange(I,c);return this._onDidChangeRenderNodeCount.fire(n),n.renderNodeCount}updateNodeAfterFilterChange(n){const c=n.renderNodeCount,I=[];return this._updateNodeAfterFilterChange(n,n.visible?1:0,I),this._updateAncestorsRenderNodeCount(n.parent,I.length-c),I}_updateNodeAfterFilterChange(n,c,I,F=!0){let J;if(n!==this.root){if(J=this._filterNode(n,c),J===0)return n.visible=!1,n.renderNodeCount=0,!1;F&&I.push(n)}const ae=I.length;n.renderNodeCount=n===this.root?0:1;let de=!1;if(!n.collapsed||J!==0){let Ce=0;for(const Ee of n.children)de=this._updateNodeAfterFilterChange(Ee,J,I,F&&!n.collapsed)||de,Ee.visible&&(Ee.visibleChildIndex=Ce++);n.visibleChildrenCount=Ce}else n.visibleChildrenCount=0;return n!==this.root&&(n.visible=J===2?de:J===1,n.visibility=J),n.visible?n.collapsed||(n.renderNodeCount+=I.length-ae):(n.renderNodeCount=0,F&&I.pop()),this._onDidChangeRenderNodeCount.fire(n),n.visible}_updateAncestorsRenderNodeCount(n,c){if(c!==0)for(;n;)n.renderNodeCount+=c,this._onDidChangeRenderNodeCount.fire(n),n=n.parent}_filterNode(n,c){const I=this.filter?this.filter.filter(n.element,c):1;return typeof I=="boolean"?(n.filterData=void 0,I?1:0):Q(I)?(n.filterData=I.data,X(I.visibility)):(n.filterData=void 0,X(I))}hasTreeNode(n,c=this.root){if(!n||n.length===0)return!0;const[I,...F]=n;return I<0||I>c.children.length?!1:this.hasTreeNode(F,c.children[I])}getTreeNode(n,c=this.root){if(!n||n.length===0)return c;const[I,...F]=n;if(I<0||I>c.children.length)throw new A(this.user,"Invalid tree location");return this.getTreeNode(F,c.children[I])}getTreeNodeWithListIndex(n){if(n.length===0)return{node:this.root,listIndex:-1,revealed:!0,visible:!1};const{parentNode:c,listIndex:I,revealed:F,visible:J}=this.getParentNodeWithListIndex(n),ae=n[n.length-1];if(ae<0||ae>c.children.length)throw new A(this.user,"Invalid tree location");const de=c.children[ae];return{node:de,listIndex:I,revealed:F,visible:J&&de.visible}}getParentNodeWithListIndex(n,c=this.root,I=0,F=!0,J=!0){const[ae,...de]=n;if(ae<0||ae>c.children.length)throw new A(this.user,"Invalid tree location");for(let Ce=0;Ce<ae;Ce++)I+=c.children[Ce].renderNodeCount;return F=F&&!c.collapsed,J=J&&c.visible,de.length===0?{parentNode:c,listIndex:I,revealed:F,visible:J}:this.getParentNodeWithListIndex(de,c.children[ae],I+1,F,J)}getNode(n=[]){return this.getTreeNode(n)}getNodeLocation(n){const c=[];let I=n;for(;I.parent;)c.push(I.parent.children.indexOf(I)),I=I.parent;return c.reverse()}getParentNodeLocation(n){if(n.length!==0)return n.length===1?[]:(0,o.bS)(n)[0]}getFirstElementChild(n){const c=this.getTreeNode(n);if(c.children.length!==0)return c.children[0].element}}var Z=y(50350),N=y(26048);class G{constructor(){this.map=new Map}add(n,c){let I=this.map.get(n);I||(I=new Set,this.map.set(n,I)),I.add(c)}delete(n,c){const I=this.map.get(n);I&&(I.delete(c),I.size===0&&this.map.delete(n))}forEach(n,c){const I=this.map.get(n);I&&I.forEach(c)}}var O=y(97669),te=y(62992),oe=y(79359),ue=y(3765),E=function(a,n,c,I){function F(J){return J instanceof c?J:new c(function(ae){ae(J)})}return new(c||(c=Promise))(function(J,ae){function de(Ne){try{Ee(I.next(Ne))}catch(He){ae(He)}}function Ce(Ne){try{Ee(I.throw(Ne))}catch(He){ae(He)}}function Ee(Ne){Ne.done?J(Ne.value):F(Ne.value).then(de,Ce)}Ee((I=I.apply(a,n||[])).next())})};class Qe extends k.ur{constructor(n){super(n.elements.map(c=>c.element)),this.data=n}}function Ke(a){return a instanceof k.ur?new Qe(a):a}class Se{constructor(n,c){this.modelProvider=n,this.dnd=c,this.autoExpandDisposable=L.jG.None}getDragURI(n){return this.dnd.getDragURI(n.element)}getDragLabel(n,c){if(this.dnd.getDragLabel)return this.dnd.getDragLabel(n.map(I=>I.element),c)}onDragStart(n,c){var I,F;(F=(I=this.dnd).onDragStart)===null||F===void 0||F.call(I,Ke(n),c)}onDragOver(n,c,I,F,J=!0){const ae=this.dnd.onDragOver(Ke(n),c&&c.element,I,F),de=this.autoExpandNode!==c;if(de&&(this.autoExpandDisposable.dispose(),this.autoExpandNode=c),typeof c>"u")return ae;if(de&&typeof ae!="boolean"&&ae.autoExpand&&(this.autoExpandDisposable=(0,Y.EQ)(()=>{const Ze=this.modelProvider(),et=Ze.getNodeLocation(c);Ze.isCollapsed(et)&&Ze.setCollapsed(et,!1),this.autoExpandNode=void 0},500)),typeof ae=="boolean"||!ae.accept||typeof ae.bubble>"u"||ae.feedback){if(!J){const Ze=typeof ae=="boolean"?ae:ae.accept,et=typeof ae=="boolean"?void 0:ae.effect;return{accept:Ze,effect:et,feedback:[I]}}return ae}if(ae.bubble===1){const Ze=this.modelProvider(),et=Ze.getNodeLocation(c),ot=Ze.getParentNodeLocation(et),lt=Ze.getNode(ot),_t=ot&&Ze.getListIndex(ot);return this.onDragOver(n,lt,_t,F,!1)}const Ce=this.modelProvider(),Ee=Ce.getNodeLocation(c),Ne=Ce.getListIndex(Ee),He=Ce.getListRenderCount(Ee);return Object.assign(Object.assign({},ae),{feedback:(0,o.y1)(Ne,Ne+He)})}drop(n,c,I,F){this.autoExpandDisposable.dispose(),this.autoExpandNode=void 0,this.dnd.drop(Ke(n),c&&c.element,I,F)}onDragEnd(n){var c,I;(I=(c=this.dnd).onDragEnd)===null||I===void 0||I.call(c,n)}}function Me(a,n){return n&&Object.assign(Object.assign({},n),{identityProvider:n.identityProvider&&{getId(c){return n.identityProvider.getId(c.element)}},dnd:n.dnd&&new Se(a,n.dnd),multipleSelectionController:n.multipleSelectionController&&{isSelectionSingleChangeEvent(c){return n.multipleSelectionController.isSelectionSingleChangeEvent(Object.assign(Object.assign({},c),{element:c.element}))},isSelectionRangeChangeEvent(c){return n.multipleSelectionController.isSelectionRangeChangeEvent(Object.assign(Object.assign({},c),{element:c.element}))}},accessibilityProvider:n.accessibilityProvider&&Object.assign(Object.assign({},n.accessibilityProvider),{getSetSize(c){const I=a(),F=I.getNodeLocation(c),J=I.getParentNodeLocation(F);return I.getNode(J).visibleChildrenCount},getPosInSet(c){return c.visibleChildIndex+1},isChecked:n.accessibilityProvider&&n.accessibilityProvider.isChecked?c=>n.accessibilityProvider.isChecked(c.element):void 0,getRole:n.accessibilityProvider&&n.accessibilityProvider.getRole?c=>n.accessibilityProvider.getRole(c.element):()=>"treeitem",getAriaLabel(c){return n.accessibilityProvider.getAriaLabel(c.element)},getWidgetAriaLabel(){return n.accessibilityProvider.getWidgetAriaLabel()},getWidgetRole:n.accessibilityProvider&&n.accessibilityProvider.getWidgetRole?()=>n.accessibilityProvider.getWidgetRole():()=>"tree",getAriaLevel:n.accessibilityProvider&&n.accessibilityProvider.getAriaLevel?c=>n.accessibilityProvider.getAriaLevel(c.element):c=>c.depth,getActiveDescendantId:n.accessibilityProvider.getActiveDescendantId&&(c=>n.accessibilityProvider.getActiveDescendantId(c.element))}),keyboardNavigationLabelProvider:n.keyboardNavigationLabelProvider&&Object.assign(Object.assign({},n.keyboardNavigationLabelProvider),{getKeyboardNavigationLabel(c){return n.keyboardNavigationLabelProvider.getKeyboardNavigationLabel(c.element)}})})}class ce{constructor(n){this.delegate=n}getHeight(n){return this.delegate.getHeight(n.element)}getTemplateId(n){return this.delegate.getTemplateId(n.element)}hasDynamicHeight(n){return!!this.delegate.hasDynamicHeight&&this.delegate.hasDynamicHeight(n.element)}setDynamicHeight(n,c){var I,F;(F=(I=this.delegate).setDynamicHeight)===null||F===void 0||F.call(I,n.element,c)}}var pe;(function(a){a.None="none",a.OnHover="onHover",a.Always="always"})(pe||(pe={}));class be{constructor(n,c=[]){this._elements=c,this.disposables=new L.Cm,this.onDidChange=$.Jh.forEach(n,I=>this._elements=I,this.disposables)}get elements(){return this._elements}dispose(){this.disposables.dispose()}}class ge{constructor(n,c,I,F,J={}){var ae;this.renderer=n,this.modelProvider=c,this.activeNodes=F,this.renderedElements=new Map,this.renderedNodes=new Map,this.indent=ge.DefaultIndent,this.hideTwistiesOfChildlessElements=!1,this.shouldRenderIndentGuides=!1,this.renderedIndentGuides=new G,this.activeIndentNodes=new Set,this.indentGuidesDisposable=L.jG.None,this.disposables=new L.Cm,this.templateId=n.templateId,this.updateOptions(J),$.Jh.map(I,de=>de.node)(this.onDidChangeNodeTwistieState,this,this.disposables),(ae=n.onDidChangeTwistieState)===null||ae===void 0||ae.call(n,this.onDidChangeTwistieState,this,this.disposables)}updateOptions(n={}){if(typeof n.indent<"u"&&(this.indent=(0,te.qE)(n.indent,0,40)),typeof n.renderIndentGuides<"u"){const c=n.renderIndentGuides!==pe.None;if(c!==this.shouldRenderIndentGuides&&(this.shouldRenderIndentGuides=c,this.indentGuidesDisposable.dispose(),c)){const I=new L.Cm;this.activeNodes.onDidChange(this._onDidChangeActiveNodes,this,I),this.indentGuidesDisposable=I,this._onDidChangeActiveNodes(this.activeNodes.elements)}}typeof n.hideTwistiesOfChildlessElements<"u"&&(this.hideTwistiesOfChildlessElements=n.hideTwistiesOfChildlessElements)}renderTemplate(n){const c=(0,b.BC)(n,(0,b.$)(".monaco-tl-row")),I=(0,b.BC)(c,(0,b.$)(".monaco-tl-indent")),F=(0,b.BC)(c,(0,b.$)(".monaco-tl-twistie")),J=(0,b.BC)(c,(0,b.$)(".monaco-tl-contents")),ae=this.renderer.renderTemplate(J);return{container:n,indent:I,twistie:F,indentGuidesDisposable:L.jG.None,templateData:ae}}renderElement(n,c,I,F){typeof F=="number"&&(this.renderedNodes.set(n,{templateData:I,height:F}),this.renderedElements.set(n.element,n));const J=ge.DefaultIndent+(n.depth-1)*this.indent;I.twistie.style.paddingLeft=`${J}px`,I.indent.style.width=`${J+this.indent-16}px`,this.renderTwistie(n,I),typeof F=="number"&&this.renderIndentGuides(n,I),this.renderer.renderElement(n,c,I.templateData,F)}disposeElement(n,c,I,F){var J,ae;I.indentGuidesDisposable.dispose(),(ae=(J=this.renderer).disposeElement)===null||ae===void 0||ae.call(J,n,c,I.templateData,F),typeof F=="number"&&(this.renderedNodes.delete(n),this.renderedElements.delete(n.element))}disposeTemplate(n){this.renderer.disposeTemplate(n.templateData)}onDidChangeTwistieState(n){const c=this.renderedElements.get(n);c&&this.onDidChangeNodeTwistieState(c)}onDidChangeNodeTwistieState(n){const c=this.renderedNodes.get(n);c&&(this.renderTwistie(n,c.templateData),this._onDidChangeActiveNodes(this.activeNodes.elements),this.renderIndentGuides(n,c.templateData))}renderTwistie(n,c){c.twistie.classList.remove(...N.W6.treeItemExpanded.classNamesArray);let I=!1;this.renderer.renderTwistie&&(I=this.renderer.renderTwistie(n.element,c.twistie)),n.collapsible&&(!this.hideTwistiesOfChildlessElements||n.visibleChildrenCount>0)?(I||c.twistie.classList.add(...N.W6.treeItemExpanded.classNamesArray),c.twistie.classList.add("collapsible"),c.twistie.classList.toggle("collapsed",n.collapsed)):c.twistie.classList.remove("collapsible","collapsed"),n.collapsible?c.container.setAttribute("aria-expanded",String(!n.collapsed)):c.container.removeAttribute("aria-expanded")}renderIndentGuides(n,c){if((0,b.w_)(c.indent),c.indentGuidesDisposable.dispose(),!this.shouldRenderIndentGuides)return;const I=new L.Cm,F=this.modelProvider();let J=n;for(;;){const ae=F.getNodeLocation(J),de=F.getParentNodeLocation(ae);if(!de)break;const Ce=F.getNode(de),Ee=(0,b.$)(".indent-guide",{style:`width: ${this.indent}px`});this.activeIndentNodes.has(Ce)&&Ee.classList.add("active"),c.indent.childElementCount===0?c.indent.appendChild(Ee):c.indent.insertBefore(Ee,c.indent.firstElementChild),this.renderedIndentGuides.add(Ce,Ee),I.add((0,L.s)(()=>this.renderedIndentGuides.delete(Ce,Ee))),J=Ce}c.indentGuidesDisposable=I}_onDidChangeActiveNodes(n){if(!this.shouldRenderIndentGuides)return;const c=new Set,I=this.modelProvider();n.forEach(F=>{const J=I.getNodeLocation(F);try{const ae=I.getParentNodeLocation(J);F.collapsible&&F.children.length>0&&!F.collapsed?c.add(F):ae&&c.add(I.getNode(ae))}catch{}}),this.activeIndentNodes.forEach(F=>{c.has(F)||this.renderedIndentGuides.forEach(F,J=>J.classList.remove("active"))}),c.forEach(F=>{this.activeIndentNodes.has(F)||this.renderedIndentGuides.forEach(F,J=>J.classList.add("active"))}),this.activeIndentNodes=c}dispose(){this.renderedNodes.clear(),this.renderedElements.clear(),this.indentGuidesDisposable.dispose(),(0,L.AS)(this.disposables)}}ge.DefaultIndent=8;class ke{constructor(n,c,I){this.tree=n,this.keyboardNavigationLabelProvider=c,this._filter=I,this._totalCount=0,this._matchCount=0,this._pattern="",this._lowercasePattern="",this.disposables=new L.Cm,n.onWillRefilter(this.reset,this,this.disposables)}get totalCount(){return this._totalCount}get matchCount(){return this._matchCount}filter(n,c){let I=1;if(this._filter){const ae=this._filter.filter(n,c);if(typeof ae=="boolean"?I=ae?1:0:Q(ae)?I=X(ae.visibility):I=ae,I===0)return!1}if(this._totalCount++,!this._pattern)return this._matchCount++,{data:O.ne.Default,visibility:I};const F=this.keyboardNavigationLabelProvider.getKeyboardNavigationLabel(n),J=Array.isArray(F)?F:[F];for(const ae of J){const de=ae&&ae.toString();if(typeof de>"u")return{data:O.ne.Default,visibility:I};const Ce=(0,O.dt)(this._pattern,this._lowercasePattern,0,de,de.toLowerCase(),0,{firstMatchCanBeWeak:!0,boostFullMatch:!0});if(Ce)return this._matchCount++,J.length===1?{data:Ce,visibility:I}:{data:{label:de,score:Ce},visibility:I}}return this.tree.findMode===Ge.Filter?2:{data:O.ne.Default,visibility:I}}reset(){this._totalCount=0,this._matchCount=0}dispose(){(0,L.AS)(this.disposables)}}class We extends D.l{constructor(n){var c;super({icon:N.W6.filter,title:(0,ue.kg)("filter","Filter"),isChecked:(c=n?.isChecked)!==null&&c!==void 0?c:!1,inputActiveOptionBorder:n?.inputActiveOptionBorder,inputActiveOptionForeground:n?.inputActiveOptionForeground,inputActiveOptionBackground:n?.inputActiveOptionBackground})}}var Ge;(function(a){a[a.Highlight=0]="Highlight",a[a.Filter=1]="Filter"})(Ge||(Ge={}));class Ae extends L.jG{constructor(n,c,I,F,J){super(),this.tree=c,this.elements=(0,b.h)(".monaco-tree-type-filter",[(0,b.h)(".monaco-tree-type-filter-grab.codicon.codicon-debug-gripper@grab",{tabIndex:0}),(0,b.h)(".monaco-tree-type-filter-input@findInput"),(0,b.h)(".monaco-tree-type-filter-actionbar@actionbar")]),this.width=0,this.right=0,this._onDidDisable=new $.vl,n.appendChild(this.elements.root),this._register((0,L.s)(()=>n.removeChild(this.elements.root))),this.modeToggle=this._register(new We(Object.assign(Object.assign({},J),{isChecked:F===Ge.Filter}))),this.onDidChangeMode=$.Jh.map(this.modeToggle.onChange,()=>this.modeToggle.checked?Ge.Filter:Ge.Highlight,this._store),this.findInput=this._register(new v.c(this.elements.findInput,I,!1,{label:(0,ue.kg)("type to search","Type to search"),additionalToggles:[this.modeToggle]})),this.actionbar=this._register(new m.E(this.elements.actionbar)),this.mode=F;const ae=this._register(new w.f(this.findInput.inputBox.inputElement,"keydown")),de=this._register($.Jh.chain(ae.event)).map(He=>new C.Z(He)).event;this._register(de(He=>{switch(He.keyCode){case 18:He.preventDefault(),He.stopPropagation(),this.tree.domFocus();return}}));const Ce=this._register(new Z.rc("close",(0,ue.kg)("close","Close"),"codicon codicon-close",!0,()=>this.dispose()));this.actionbar.push(Ce,{icon:!0,label:!1});const Ee=this._register(new w.f(this.elements.grab,"mousedown"));this._register(Ee.event(He=>{const Ze=new L.Cm,et=Ze.add(new w.f(window,"mousemove")),ot=Ze.add(new w.f(window,"mouseup")),lt=this.right,_t=He.pageX;this.elements.grab.classList.add("grabbing");const Ft=ci=>{const Oi=ci.pageX-_t;this.right=lt-Oi,this.layout()};Ze.add(et.event(Ft)),Ze.add(ot.event(ci=>{Ft(ci),this.elements.grab.classList.remove("grabbing"),Ze.dispose()}))}));const Ne=this._register($.Jh.chain(this._register(new w.f(this.elements.grab,"keydown")).event)).map(He=>new C.Z(He)).event;this._register(Ne(He=>{let Ze;He.keyCode===15?Ze=Number.POSITIVE_INFINITY:He.keyCode===17?Ze=0:He.keyCode===10&&(Ze=this.right===0?Number.POSITIVE_INFINITY:0),Ze!==void 0&&(He.preventDefault(),He.stopPropagation(),this.right=Ze,this.layout())})),this.onDidChangeValue=this.findInput.onDidChange,this.style(J??{})}set mode(n){this.modeToggle.checked=n===Ge.Filter,this.findInput.inputBox.setPlaceHolder(n===Ge.Filter?(0,ue.kg)("type to filter","Type to filter"):(0,ue.kg)("type to search","Type to search"))}style(n){this.findInput.style(n),n.listFilterWidgetBackground&&(this.elements.root.style.backgroundColor=n.listFilterWidgetBackground.toString()),n.listFilterWidgetShadow&&(this.elements.root.style.boxShadow=`0 0 8px 2px ${n.listFilterWidgetShadow}`)}layout(n=this.width){this.width=n,this.right=(0,te.qE)(this.right,0,Math.max(0,n-212)),this.elements.root.style.right=`${this.right}px`}showMessage(n){this.findInput.showMessage(n)}clearMessage(){this.findInput.clearMessage()}dispose(){const n=Object.create(null,{dispose:{get:()=>super.dispose}});return E(this,void 0,void 0,function*(){this._onDidDisable.fire(),this.elements.root.classList.add("disabled"),yield(0,Y.wR)(300),n.dispose.call(this)})}}class he{constructor(n,c,I,F,J){var ae;this.tree=n,this.view=I,this.filter=F,this.contextViewProvider=J,this._pattern="",this.width=0,this._onDidChangeMode=new $.vl,this.onDidChangeMode=this._onDidChangeMode.event,this._onDidChangePattern=new $.vl,this._onDidChangeOpenState=new $.vl,this.onDidChangeOpenState=this._onDidChangeOpenState.event,this.enabledDisposables=new L.Cm,this.disposables=new L.Cm,this._mode=(ae=n.options.defaultFindMode)!==null&&ae!==void 0?ae:Ge.Highlight,c.onDidSplice(this.onDidSpliceModel,this,this.disposables)}get pattern(){return this._pattern}get mode(){return this._mode}set mode(n){n!==this._mode&&(this._mode=n,this.widget&&(this.widget.mode=this._mode),this.tree.refilter(),this.render(),this._onDidChangeMode.fire(n))}onDidSpliceModel(){!this.widget||this.pattern.length===0||(this.tree.refilter(),this.render())}render(){var n,c;const I=this.filter.totalCount>0&&this.filter.matchCount===0;this.pattern&&I?(n=this.widget)===null||n===void 0||n.showMessage({type:2,content:(0,ue.kg)("not found","No elements found.")}):(c=this.widget)===null||c===void 0||c.clearMessage()}shouldAllowFocus(n){return!this.widget||!this.pattern||this._mode===Ge.Filter||this.filter.totalCount>0&&this.filter.matchCount<=1?!0:!O.ne.isDefault(n.filterData)}style(n){var c;this.styles=n,(c=this.widget)===null||c===void 0||c.style(n)}layout(n){var c;this.width=n,(c=this.widget)===null||c===void 0||c.layout(n)}dispose(){this._onDidChangePattern.dispose(),this.enabledDisposables.dispose(),this.disposables.dispose()}}function Pe(a){let n=x.Unknown;return(0,b.XD)(a.browserEvent.target,"monaco-tl-twistie","monaco-tl-row")?n=x.Twistie:(0,b.XD)(a.browserEvent.target,"monaco-tl-contents","monaco-tl-row")?n=x.Element:(0,b.XD)(a.browserEvent.target,"monaco-tree-type-filter","monaco-list")&&(n=x.Filter),{browserEvent:a.browserEvent,element:a.element?a.element.element:null,target:n}}function $e(a,n){n(a),a.children.forEach(c=>$e(c,n))}class it{constructor(n,c){this.getFirstViewElementWithTrait=n,this.identityProvider=c,this.nodes=[],this._onDidChange=new $.vl,this.onDidChange=this._onDidChange.event}get nodeSet(){return this._nodeSet||(this._nodeSet=this.createNodeSet()),this._nodeSet}set(n,c){!c?.__forceEvent&&(0,o.aI)(this.nodes,n)||this._set(n,!1,c)}_set(n,c,I){if(this.nodes=[...n],this.elements=void 0,this._nodeSet=void 0,!c){const F=this;this._onDidChange.fire({get elements(){return F.get()},browserEvent:I})}}get(){return this.elements||(this.elements=this.nodes.map(n=>n.element)),[...this.elements]}getNodes(){return this.nodes}has(n){return this.nodeSet.has(n)}onDidModelSplice({insertedNodes:n,deletedNodes:c}){if(!this.identityProvider){const Ce=this.createNodeSet(),Ee=Ne=>Ce.delete(Ne);c.forEach(Ne=>$e(Ne,Ee)),this.set([...Ce.values()]);return}const I=new Set,F=Ce=>I.add(this.identityProvider.getId(Ce.element).toString());c.forEach(Ce=>$e(Ce,F));const J=new Map,ae=Ce=>J.set(this.identityProvider.getId(Ce.element).toString(),Ce);n.forEach(Ce=>$e(Ce,ae));const de=[];for(const Ce of this.nodes){const Ee=this.identityProvider.getId(Ce.element).toString();if(!I.has(Ee))de.push(Ce);else{const He=J.get(Ee);He&&de.push(He)}}if(this.nodes.length>0&&de.length===0){const Ce=this.getFirstViewElementWithTrait();Ce&&de.push(Ce)}this._set(de,!0)}createNodeSet(){const n=new Set;for(const c of this.nodes)n.add(c);return n}}class ft extends U.MH{constructor(n,c){super(n),this.tree=c}onViewPointer(n){if((0,U.Bm)(n.browserEvent.target)||(0,U.B6)(n.browserEvent.target)||(0,U.bm)(n.browserEvent.target))return;const c=n.element;if(!c)return super.onViewPointer(n);if(this.isSelectionRangeChangeEvent(n)||this.isSelectionSingleChangeEvent(n))return super.onViewPointer(n);const I=n.browserEvent.target,F=I.classList.contains("monaco-tl-twistie")||I.classList.contains("monaco-icon-label")&&I.classList.contains("folder-icon")&&n.browserEvent.offsetX<16;let J=!1;if(typeof this.tree.expandOnlyOnTwistieClick=="function"?J=this.tree.expandOnlyOnTwistieClick(c.element):J=!!this.tree.expandOnlyOnTwistieClick,J&&!F&&n.browserEvent.detail!==2)return super.onViewPointer(n);if(!this.tree.expandOnDoubleClick&&n.browserEvent.detail===2)return super.onViewPointer(n);if(c.collapsible){const ae=this.tree.model,de=ae.getNodeLocation(c),Ce=n.browserEvent.altKey;if(this.tree.setFocus([de]),ae.setCollapsed(de,void 0,Ce),J&&F)return}super.onViewPointer(n)}onDoubleClick(n){n.browserEvent.target.classList.contains("monaco-tl-twistie")||!this.tree.expandOnDoubleClick||super.onDoubleClick(n)}}class Wt extends U.B8{constructor(n,c,I,F,J,ae,de,Ce){super(n,c,I,F,Ce),this.focusTrait=J,this.selectionTrait=ae,this.anchorTrait=de}createMouseController(n){return new ft(this,n.tree)}splice(n,c,I=[]){if(super.splice(n,c,I),I.length===0)return;const F=[],J=[];let ae;I.forEach((de,Ce)=>{this.focusTrait.has(de)&&F.push(n+Ce),this.selectionTrait.has(de)&&J.push(n+Ce),this.anchorTrait.has(de)&&(ae=n+Ce)}),F.length>0&&super.setFocus((0,o.dM)([...super.getFocus(),...F])),J.length>0&&super.setSelection((0,o.dM)([...super.getSelection(),...J])),typeof ae=="number"&&super.setAnchor(ae)}setFocus(n,c,I=!1){super.setFocus(n,c),I||this.focusTrait.set(n.map(F=>this.element(F)),c)}setSelection(n,c,I=!1){super.setSelection(n,c),I||this.selectionTrait.set(n.map(F=>this.element(F)),c)}setAnchor(n,c=!1){super.setAnchor(n),c||(typeof n>"u"?this.anchorTrait.set([]):this.anchorTrait.set([this.element(n)]))}}class tt{constructor(n,c,I,F,J={}){var ae;this._user=n,this._options=J,this.eventBufferer=new $.at,this.onDidChangeFindOpenState=$.Jh.None,this.disposables=new L.Cm,this._onWillRefilter=new $.vl,this.onWillRefilter=this._onWillRefilter.event,this._onDidUpdateOptions=new $.vl;const de=new ce(I),Ce=new $.Wj,Ee=new $.Wj,Ne=this.disposables.add(new be(Ee.event));this.renderers=F.map(et=>new ge(et,()=>this.model,Ce.event,Ne,J));for(const et of this.renderers)this.disposables.add(et);let He;J.keyboardNavigationLabelProvider&&(He=new ke(this,J.keyboardNavigationLabelProvider,J.filter),J=Object.assign(Object.assign({},J),{filter:He}),this.disposables.add(He)),this.focus=new it(()=>this.view.getFocusedElements()[0],J.identityProvider),this.selection=new it(()=>this.view.getSelectedElements()[0],J.identityProvider),this.anchor=new it(()=>this.view.getAnchorElement(),J.identityProvider),this.view=new Wt(n,c,de,this.renderers,this.focus,this.selection,this.anchor,Object.assign(Object.assign({},Me(()=>this.model,J)),{tree:this})),this.model=this.createModel(n,this.view,J),Ce.input=this.model.onDidChangeCollapseState;const Ze=$.Jh.forEach(this.model.onDidSplice,et=>{this.eventBufferer.bufferEvents(()=>{this.focus.onDidModelSplice(et),this.selection.onDidModelSplice(et)})},this.disposables);if(Ze(()=>null,null,this.disposables),Ee.input=$.Jh.chain($.Jh.any(Ze,this.focus.onDidChange,this.selection.onDidChange)).debounce(()=>null,0).map(()=>{const et=new Set;for(const ot of this.focus.getNodes())et.add(ot);for(const ot of this.selection.getNodes())et.add(ot);return[...et.values()]}).event,J.keyboardSupport!==!1){const et=$.Jh.chain(this.view.onKeyDown).filter(ot=>!(0,U.B6)(ot.target)).map(ot=>new C.Z(ot));et.filter(ot=>ot.keyCode===15).on(this.onLeftArrow,this,this.disposables),et.filter(ot=>ot.keyCode===17).on(this.onRightArrow,this,this.disposables),et.filter(ot=>ot.keyCode===10).on(this.onSpace,this,this.disposables)}(!((ae=J.findWidgetEnabled)!==null&&ae!==void 0)||ae)&&J.keyboardNavigationLabelProvider&&J.contextViewProvider?(this.findController=new he(this,this.model,this.view,He,J.contextViewProvider),this.focusNavigationFilter=et=>this.findController.shouldAllowFocus(et),this.onDidChangeFindOpenState=this.findController.onDidChangeOpenState,this.disposables.add(this.findController),this.onDidChangeFindMode=this.findController.onDidChangeMode):this.onDidChangeFindMode=$.Jh.None,this.styleElement=(0,b.li)(this.view.getHTMLElement()),this.getHTMLElement().classList.toggle("always",this._options.renderIndentGuides===pe.Always)}get onDidChangeFocus(){return this.eventBufferer.wrapEvent(this.focus.onDidChange)}get onDidChangeSelection(){return this.eventBufferer.wrapEvent(this.selection.onDidChange)}get onMouseDblClick(){return $.Jh.filter($.Jh.map(this.view.onMouseDblClick,Pe),n=>n.target!==x.Filter)}get onPointer(){return $.Jh.map(this.view.onPointer,Pe)}get onDidFocus(){return this.view.onDidFocus}get onDidChangeModel(){return $.Jh.signal(this.model.onDidSplice)}get onDidChangeCollapseState(){return this.model.onDidChangeCollapseState}get findMode(){var n,c;return(c=(n=this.findController)===null||n===void 0?void 0:n.mode)!==null&&c!==void 0?c:Ge.Highlight}set findMode(n){this.findController&&(this.findController.mode=n)}get expandOnDoubleClick(){return typeof this._options.expandOnDoubleClick>"u"?!0:this._options.expandOnDoubleClick}get expandOnlyOnTwistieClick(){return typeof this._options.expandOnlyOnTwistieClick>"u"?!0:this._options.expandOnlyOnTwistieClick}get onDidDispose(){return this.view.onDidDispose}updateOptions(n={}){this._options=Object.assign(Object.assign({},this._options),n);for(const c of this.renderers)c.updateOptions(n);this.view.updateOptions(this._options),this._onDidUpdateOptions.fire(this._options),this.getHTMLElement().classList.toggle("always",this._options.renderIndentGuides===pe.Always)}get options(){return this._options}getHTMLElement(){return this.view.getHTMLElement()}get scrollTop(){return this.view.scrollTop}set scrollTop(n){this.view.scrollTop=n}domFocus(){this.view.domFocus()}layout(n,c){var I;this.view.layout(n,c),(0,oe.Et)(c)&&((I=this.findController)===null||I===void 0||I.layout(c))}style(n){var c;const I=`.${this.view.domId}`,F=[];n.treeIndentGuidesStroke&&(F.push(`.monaco-list${I}:hover .monaco-tl-indent > .indent-guide, .monaco-list${I}.always .monaco-tl-indent > .indent-guide { border-color: ${n.treeIndentGuidesStroke.transparent(.4)}; }`),F.push(`.monaco-list${I} .monaco-tl-indent > .indent-guide.active { border-color: ${n.treeIndentGuidesStroke}; }`)),this.styleElement.textContent=F.join(` `),(c=this.findController)===null||c===void 0||c.style(n),this.view.style(n)}getParentElement(n){const c=this.model.getParentNodeLocation(n);return this.model.getNode(c).element}getFirstElementChild(n){return this.model.getFirstElementChild(n)}getNode(n){return this.model.getNode(n)}collapse(n,c=!1){return this.model.setCollapsed(n,!0,c)}expand(n,c=!1){return this.model.setCollapsed(n,!1,c)}isCollapsible(n){return this.model.isCollapsible(n)}setCollapsible(n,c){return this.model.setCollapsible(n,c)}isCollapsed(n){return this.model.isCollapsed(n)}refilter(){this._onWillRefilter.fire(void 0),this.model.refilter()}setSelection(n,c){const I=n.map(J=>this.model.getNode(J));this.selection.set(I,c);const F=n.map(J=>this.model.getListIndex(J)).filter(J=>J>-1);this.view.setSelection(F,c,!0)}getSelection(){return this.selection.get()}setFocus(n,c){const I=n.map(J=>this.model.getNode(J));this.focus.set(I,c);const F=n.map(J=>this.model.getListIndex(J)).filter(J=>J>-1);this.view.setFocus(F,c,!0)}getFocus(){return this.focus.get()}reveal(n,c){this.model.expandTo(n);const I=this.model.getListIndex(n);I!==-1&&this.view.reveal(I,c)}onLeftArrow(n){n.preventDefault(),n.stopPropagation();const c=this.view.getFocusedElements();if(c.length===0)return;const I=c[0],F=this.model.getNodeLocation(I);if(!this.model.setCollapsed(F,!0)){const ae=this.model.getParentNodeLocation(F);if(!ae)return;const de=this.model.getListIndex(ae);this.view.reveal(de),this.view.setFocus([de])}}onRightArrow(n){n.preventDefault(),n.stopPropagation();const c=this.view.getFocusedElements();if(c.length===0)return;const I=c[0],F=this.model.getNodeLocation(I);if(!this.model.setCollapsed(F,!1)){if(!I.children.some(Ce=>Ce.visible))return;const[ae]=this.view.getFocus(),de=ae+1;this.view.reveal(de),this.view.setFocus([de])}}onSpace(n){n.preventDefault(),n.stopPropagation();const c=this.view.getFocusedElements();if(c.length===0)return;const I=c[0],F=this.model.getNodeLocation(I),J=n.browserEvent.altKey;this.model.setCollapsed(F,void 0,J)}dispose(){(0,L.AS)(this.disposables),this.view.dispose()}}class Ye{constructor(n,c,I={}){this.user=n,this.rootRef=null,this.nodes=new Map,this.nodesByIdentity=new Map,this.model=new H(n,c,null,I),this.onDidSplice=this.model.onDidSplice,this.onDidChangeCollapseState=this.model.onDidChangeCollapseState,this.onDidChangeRenderNodeCount=this.model.onDidChangeRenderNodeCount,I.sorter&&(this.sorter={compare(F,J){return I.sorter.compare(F.element,J.element)}}),this.identityProvider=I.identityProvider}setChildren(n,c=j.f.empty(),I={}){const F=this.getElementLocation(n);this._setChildren(F,this.preserveCollapseState(c),I)}_setChildren(n,c=j.f.empty(),I){const F=new Set,J=new Set,ae=Ce=>{var Ee;if(Ce.element===null)return;const Ne=Ce;if(F.add(Ne.element),this.nodes.set(Ne.element,Ne),this.identityProvider){const He=this.identityProvider.getId(Ne.element).toString();J.add(He),this.nodesByIdentity.set(He,Ne)}(Ee=I.onDidCreateNode)===null||Ee===void 0||Ee.call(I,Ne)},de=Ce=>{var Ee;if(Ce.element===null)return;const Ne=Ce;if(F.has(Ne.element)||this.nodes.delete(Ne.element),this.identityProvider){const He=this.identityProvider.getId(Ne.element).toString();J.has(He)||this.nodesByIdentity.delete(He)}(Ee=I.onDidDeleteNode)===null||Ee===void 0||Ee.call(I,Ne)};this.model.splice([...n,0],Number.MAX_VALUE,c,Object.assign(Object.assign({},I),{onDidCreateNode:ae,onDidDeleteNode:de}))}preserveCollapseState(n=j.f.empty()){return this.sorter&&(n=[...n].sort(this.sorter.compare.bind(this.sorter))),j.f.map(n,c=>{let I=this.nodes.get(c.element);if(!I&&this.identityProvider){const ae=this.identityProvider.getId(c.element).toString();I=this.nodesByIdentity.get(ae)}if(!I)return Object.assign(Object.assign({},c),{children:this.preserveCollapseState(c.children)});const F=typeof c.collapsible=="boolean"?c.collapsible:I.collapsible,J=typeof c.collapsed<"u"?c.collapsed:I.collapsed;return Object.assign(Object.assign({},c),{collapsible:F,collapsed:J,children:this.preserveCollapseState(c.children)})})}rerender(n){const c=this.getElementLocation(n);this.model.rerender(c)}getFirstElementChild(n=null){const c=this.getElementLocation(n);return this.model.getFirstElementChild(c)}has(n){return this.nodes.has(n)}getListIndex(n){const c=this.getElementLocation(n);return this.model.getListIndex(c)}getListRenderCount(n){const c=this.getElementLocation(n);return this.model.getListRenderCount(c)}isCollapsible(n){const c=this.getElementLocation(n);return this.model.isCollapsible(c)}setCollapsible(n,c){const I=this.getElementLocation(n);return this.model.setCollapsible(I,c)}isCollapsed(n){const c=this.getElementLocation(n);return this.model.isCollapsed(c)}setCollapsed(n,c,I){const F=this.getElementLocation(n);return this.model.setCollapsed(F,c,I)}expandTo(n){const c=this.getElementLocation(n);this.model.expandTo(c)}refilter(){this.model.refilter()}getNode(n=null){if(n===null)return this.model.getNode(this.model.rootRef);const c=this.nodes.get(n);if(!c)throw new A(this.user,`Tree element not found: ${n}`);return c}getNodeLocation(n){return n.element}getParentNodeLocation(n){if(n===null)throw new A(this.user,"Invalid getParentNodeLocation call");const c=this.nodes.get(n);if(!c)throw new A(this.user,`Tree element not found: ${n}`);const I=this.model.getNodeLocation(c),F=this.model.getParentNodeLocation(I);return this.model.getNode(F).element}getElementLocation(n){if(n===null)return[];const c=this.nodes.get(n);if(!c)throw new A(this.user,`Tree element not found: ${n}`);return this.model.getNodeLocation(c)}}function ht(a){const n=[a.element],c=a.incompressible||!1;return{element:{elements:n,incompressible:c},children:j.f.map(j.f.from(a.children),ht),collapsible:a.collapsible,collapsed:a.collapsed}}function Lt(a){const n=[a.element],c=a.incompressible||!1;let I,F;for(;[F,I]=j.f.consume(j.f.from(a.children),2),!(F.length!==1||F[0].incompressible);)a=F[0],n.push(a.element);return{element:{elements:n,incompressible:c},children:j.f.map(j.f.concat(F,I),Lt),collapsible:a.collapsible,collapsed:a.collapsed}}function Rt(a,n=0){let c;return n<a.element.elements.length-1?c=[Rt(a,n+1)]:c=j.f.map(j.f.from(a.children),I=>Rt(I,0)),n===0&&a.element.incompressible?{element:a.element.elements[n],children:c,incompressible:!0,collapsible:a.collapsible,collapsed:a.collapsed}:{element:a.element.elements[n],children:c,collapsible:a.collapsible,collapsed:a.collapsed}}function Ie(a){return Rt(a,0)}function Ve(a,n,c){return a.element===n?Object.assign(Object.assign({},a),{children:c}):Object.assign(Object.assign({},a),{children:j.f.map(j.f.from(a.children),I=>Ve(I,n,c))})}const dt=a=>({getId(n){return n.elements.map(c=>a.getId(c).toString()).join("\0")}});class bt{constructor(n,c,I={}){this.user=n,this.rootRef=null,this.nodes=new Map,this.model=new Ye(n,c,I),this.enabled=typeof I.compressionEnabled>"u"?!0:I.compressionEnabled,this.identityProvider=I.identityProvider}get onDidSplice(){return this.model.onDidSplice}get onDidChangeCollapseState(){return this.model.onDidChangeCollapseState}get onDidChangeRenderNodeCount(){return this.model.onDidChangeRenderNodeCount}setChildren(n,c=j.f.empty(),I){const F=I.diffIdentityProvider&&dt(I.diffIdentityProvider);if(n===null){const et=j.f.map(c,this.enabled?Lt:ht);this._setChildren(null,et,{diffIdentityProvider:F,diffDepth:1/0});return}const J=this.nodes.get(n);if(!J)throw new Error("Unknown compressed tree node");const ae=this.model.getNode(J),de=this.model.getParentNodeLocation(J),Ce=this.model.getNode(de),Ee=Ie(ae),Ne=Ve(Ee,n,c),He=(this.enabled?Lt:ht)(Ne),Ze=Ce.children.map(et=>et===ae?He:et);this._setChildren(Ce.element,Ze,{diffIdentityProvider:F,diffDepth:ae.depth-Ce.depth})}setCompressionEnabled(n){if(n===this.enabled)return;this.enabled=n;const I=this.model.getNode().children,F=j.f.map(I,Ie),J=j.f.map(F,n?Lt:ht);this._setChildren(null,J,{diffIdentityProvider:this.identityProvider,diffDepth:1/0})}_setChildren(n,c,I){const F=new Set,J=de=>{for(const Ce of de.element.elements)F.add(Ce),this.nodes.set(Ce,de.element)},ae=de=>{for(const Ce of de.element.elements)F.has(Ce)||this.nodes.delete(Ce)};this.model.setChildren(n,c,Object.assign(Object.assign({},I),{onDidCreateNode:J,onDidDeleteNode:ae}))}has(n){return this.nodes.has(n)}getListIndex(n){const c=this.getCompressedNode(n);return this.model.getListIndex(c)}getListRenderCount(n){const c=this.getCompressedNode(n);return this.model.getListRenderCount(c)}getNode(n){if(typeof n>"u")return this.model.getNode();const c=this.getCompressedNode(n);return this.model.getNode(c)}getNodeLocation(n){const c=this.model.getNodeLocation(n);return c===null?null:c.elements[c.elements.length-1]}getParentNodeLocation(n){const c=this.getCompressedNode(n),I=this.model.getParentNodeLocation(c);return I===null?null:I.elements[I.elements.length-1]}getFirstElementChild(n){const c=this.getCompressedNode(n);return this.model.getFirstElementChild(c)}isCollapsible(n){const c=this.getCompressedNode(n);return this.model.isCollapsible(c)}setCollapsible(n,c){const I=this.getCompressedNode(n);return this.model.setCollapsible(I,c)}isCollapsed(n){const c=this.getCompressedNode(n);return this.model.isCollapsed(c)}setCollapsed(n,c,I){const F=this.getCompressedNode(n);return this.model.setCollapsed(F,c,I)}expandTo(n){const c=this.getCompressedNode(n);this.model.expandTo(c)}rerender(n){const c=this.getCompressedNode(n);this.model.rerender(c)}refilter(){this.model.refilter()}getCompressedNode(n){if(n===null)return null;const c=this.nodes.get(n);if(!c)throw new A(this.user,`Tree element not found: ${n}`);return c}}const Mt=a=>a[a.length-1];class Yt{constructor(n,c){this.unwrapper=n,this.node=c}get element(){return this.node.element===null?null:this.unwrapper(this.node.element)}get children(){return this.node.children.map(n=>new Yt(this.unwrapper,n))}get depth(){return this.node.depth}get visibleChildrenCount(){return this.node.visibleChildrenCount}get visibleChildIndex(){return this.node.visibleChildIndex}get collapsible(){return this.node.collapsible}get collapsed(){return this.node.collapsed}get visible(){return this.node.visible}get filterData(){return this.node.filterData}}function Nt(a,n){return{splice(c,I,F){n.splice(c,I,F.map(J=>a.map(J)))},updateElementHeight(c,I){n.updateElementHeight(c,I)}}}function Pt(a,n){return Object.assign(Object.assign({},n),{identityProvider:n.identityProvider&&{getId(c){return n.identityProvider.getId(a(c))}},sorter:n.sorter&&{compare(c,I){return n.sorter.compare(c.elements[0],I.elements[0])}},filter:n.filter&&{filter(c,I){return n.filter.filter(a(c),I)}}})}class Ti{constructor(n,c,I={}){this.rootRef=null,this.elementMapper=I.elementMapper||Mt;const F=J=>this.elementMapper(J.elements);this.nodeMapper=new W(J=>new Yt(F,J)),this.model=new bt(n,Nt(this.nodeMapper,c),Pt(F,I))}get onDidSplice(){return $.Jh.map(this.model.onDidSplice,({insertedNodes:n,deletedNodes:c})=>({insertedNodes:n.map(I=>this.nodeMapper.map(I)),deletedNodes:c.map(I=>this.nodeMapper.map(I))}))}get onDidChangeCollapseState(){return $.Jh.map(this.model.onDidChangeCollapseState,({node:n,deep:c})=>({node:this.nodeMapper.map(n),deep:c}))}get onDidChangeRenderNodeCount(){return $.Jh.map(this.model.onDidChangeRenderNodeCount,n=>this.nodeMapper.map(n))}setChildren(n,c=j.f.empty(),I={}){this.model.setChildren(n,c,I)}setCompressionEnabled(n){this.model.setCompressionEnabled(n)}has(n){return this.model.has(n)}getListIndex(n){return this.model.getListIndex(n)}getListRenderCount(n){return this.model.getListRenderCount(n)}getNode(n){return this.nodeMapper.map(this.model.getNode(n))}getNodeLocation(n){return n.element}getParentNodeLocation(n){return this.model.getParentNodeLocation(n)}getFirstElementChild(n){const c=this.model.getFirstElementChild(n);return c===null||typeof c>"u"?c:this.elementMapper(c.elements)}isCollapsible(n){return this.model.isCollapsible(n)}setCollapsible(n,c){return this.model.setCollapsible(n,c)}isCollapsed(n){return this.model.isCollapsed(n)}setCollapsed(n,c,I){return this.model.setCollapsed(n,c,I)}expandTo(n){return this.model.expandTo(n)}rerender(n){return this.model.rerender(n)}refilter(){return this.model.refilter()}getCompressedTreeNode(n=null){return this.model.getNode(n)}}var Ii=y(88846),ut=function(a,n,c,I){var F=arguments.length,J=F<3?n:I===null?I=Object.getOwnPropertyDescriptor(n,c):I,ae;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")J=Reflect.decorate(a,n,c,I);else for(var de=a.length-1;de>=0;de--)(ae=a[de])&&(J=(F<3?ae(J):F>3?ae(n,c,J):ae(n,c))||J);return F>3&&J&&Object.defineProperty(n,c,J),J};class Si extends tt{constructor(n,c,I,F,J={}){super(n,c,I,F,J),this.user=n}get onDidChangeCollapseState(){return this.model.onDidChangeCollapseState}setChildren(n,c=j.f.empty(),I){this.model.setChildren(n,c,I)}rerender(n){if(n===void 0){this.view.rerender();return}this.model.rerender(n)}hasElement(n){return this.model.has(n)}createModel(n,c,I){return new Ye(n,c,I)}}class yt{constructor(n,c){this._compressedTreeNodeProvider=n,this.renderer=c,this.templateId=c.templateId,c.onDidChangeTwistieState&&(this.onDidChangeTwistieState=c.onDidChangeTwistieState)}get compressedTreeNodeProvider(){return this._compressedTreeNodeProvider()}renderTemplate(n){return{compressedTreeNode:void 0,data:this.renderer.renderTemplate(n)}}renderElement(n,c,I,F){const J=this.compressedTreeNodeProvider.getCompressedTreeNode(n.element);J.element.elements.length===1?(I.compressedTreeNode=void 0,this.renderer.renderElement(n,c,I.data,F)):(I.compressedTreeNode=J,this.renderer.renderCompressedElements(J,c,I.data,F))}disposeElement(n,c,I,F){var J,ae,de,Ce;I.compressedTreeNode?(ae=(J=this.renderer).disposeCompressedElements)===null||ae===void 0||ae.call(J,I.compressedTreeNode,c,I.data,F):(Ce=(de=this.renderer).disposeElement)===null||Ce===void 0||Ce.call(de,n,c,I.data,F)}disposeTemplate(n){this.renderer.disposeTemplate(n.data)}renderTwistie(n,c){return this.renderer.renderTwistie?this.renderer.renderTwistie(n,c):!1}}ut([Ii.B],yt.prototype,"compressedTreeNodeProvider",null);function fe(a,n){return n&&Object.assign(Object.assign({},n),{keyboardNavigationLabelProvider:n.keyboardNavigationLabelProvider&&{getKeyboardNavigationLabel(c){let I;try{I=a().getCompressedTreeNode(c)}catch{return n.keyboardNavigationLabelProvider.getKeyboardNavigationLabel(c)}return I.element.elements.length===1?n.keyboardNavigationLabelProvider.getKeyboardNavigationLabel(c):n.keyboardNavigationLabelProvider.getCompressedNodeKeyboardNavigationLabel(I.element.elements)}}})}class ze extends Si{constructor(n,c,I,F,J={}){const ae=()=>this,de=F.map(Ce=>new yt(ae,Ce));super(n,c,I,de,fe(ae,J))}setChildren(n,c=j.f.empty(),I){this.model.setChildren(n,c,I)}createModel(n,c,I){return new Ti(n,c,I)}updateOptions(n={}){super.updateOptions(n),typeof n.compressionEnabled<"u"&&this.model.setCompressionEnabled(n.compressionEnabled)}getCompressedTreeNode(n=null){return this.model.getCompressedTreeNode(n)}}var Et=y(94327),Ot=function(a,n,c,I){function F(J){return J instanceof c?J:new c(function(ae){ae(J)})}return new(c||(c=Promise))(function(J,ae){function de(Ne){try{Ee(I.next(Ne))}catch(He){ae(He)}}function Ce(Ne){try{Ee(I.throw(Ne))}catch(He){ae(He)}}function Ee(Ne){Ne.done?J(Ne.value):F(Ne.value).then(de,Ce)}Ee((I=I.apply(a,n||[])).next())})};function si(a){return Object.assign(Object.assign({},a),{children:[],refreshPromise:void 0,stale:!0,slow:!1,collapsedByDefault:void 0})}function _i(a,n){return n.parent?n.parent===a?!0:_i(a,n.parent):!1}function Fe(a,n){return a===n||_i(a,n)||_i(n,a)}class Xe{constructor(n){this.node=n}get element(){return this.node.element.element}get children(){return this.node.children.map(n=>new Xe(n))}get depth(){return this.node.depth}get visibleChildrenCount(){return this.node.visibleChildrenCount}get visibleChildIndex(){return this.node.visibleChildIndex}get collapsible(){return this.node.collapsible}get collapsed(){return this.node.collapsed}get visible(){return this.node.visible}get filterData(){return this.node.filterData}}class gt{constructor(n,c,I){this.renderer=n,this.nodeMapper=c,this.onDidChangeTwistieState=I,this.renderedNodes=new Map,this.templateId=n.templateId}renderTemplate(n){return{templateData:this.renderer.renderTemplate(n)}}renderElement(n,c,I,F){this.renderer.renderElement(this.nodeMapper.map(n),c,I.templateData,F)}renderTwistie(n,c){return n.slow?(c.classList.add(...N.W6.treeItemLoading.classNamesArray),!0):(c.classList.remove(...N.W6.treeItemLoading.classNamesArray),!1)}disposeElement(n,c,I,F){var J,ae;(ae=(J=this.renderer).disposeElement)===null||ae===void 0||ae.call(J,this.nodeMapper.map(n),c,I.templateData,F)}disposeTemplate(n){this.renderer.disposeTemplate(n.templateData)}dispose(){this.renderedNodes.clear()}}function Xt(a){return{browserEvent:a.browserEvent,elements:a.elements.map(n=>n.element)}}function Vt(a){return{browserEvent:a.browserEvent,element:a.element&&a.element.element,target:a.target}}class ni extends k.ur{constructor(n){super(n.elements.map(c=>c.element)),this.data=n}}function vi(a){return a instanceof k.ur?new ni(a):a}class Ri{constructor(n){this.dnd=n}getDragURI(n){return this.dnd.getDragURI(n.element)}getDragLabel(n,c){if(this.dnd.getDragLabel)return this.dnd.getDragLabel(n.map(I=>I.element),c)}onDragStart(n,c){var I,F;(F=(I=this.dnd).onDragStart)===null||F===void 0||F.call(I,vi(n),c)}onDragOver(n,c,I,F,J=!0){return this.dnd.onDragOver(vi(n),c&&c.element,I,F)}drop(n,c,I,F){this.dnd.drop(vi(n),c&&c.element,I,F)}onDragEnd(n){var c,I;(I=(c=this.dnd).onDragEnd)===null||I===void 0||I.call(c,n)}}function St(a){return a&&Object.assign(Object.assign({},a),{collapseByDefault:!0,identityProvider:a.identityProvider&&{getId(n){return a.identityProvider.getId(n.element)}},dnd:a.dnd&&new Ri(a.dnd),multipleSelectionController:a.multipleSelectionController&&{isSelectionSingleChangeEvent(n){return a.multipleSelectionController.isSelectionSingleChangeEvent(Object.assign(Object.assign({},n),{element:n.element}))},isSelectionRangeChangeEvent(n){return a.multipleSelectionController.isSelectionRangeChangeEvent(Object.assign(Object.assign({},n),{element:n.element}))}},accessibilityProvider:a.accessibilityProvider&&Object.assign(Object.assign({},a.accessibilityProvider),{getPosInSet:void 0,getSetSize:void 0,getRole:a.accessibilityProvider.getRole?n=>a.accessibilityProvider.getRole(n.element):()=>"treeitem",isChecked:a.accessibilityProvider.isChecked?n=>{var c;return!!(!((c=a.accessibilityProvider)===null||c===void 0)&&c.isChecked(n.element))}:void 0,getAriaLabel(n){return a.accessibilityProvider.getAriaLabel(n.element)},getWidgetAriaLabel(){return a.accessibilityProvider.getWidgetAriaLabel()},getWidgetRole:a.accessibilityProvider.getWidgetRole?()=>a.accessibilityProvider.getWidgetRole():()=>"tree",getAriaLevel:a.accessibilityProvider.getAriaLevel&&(n=>a.accessibilityProvider.getAriaLevel(n.element)),getActiveDescendantId:a.accessibilityProvider.getActiveDescendantId&&(n=>a.accessibilityProvider.getActiveDescendantId(n.element))}),filter:a.filter&&{filter(n,c){return a.filter.filter(n.element,c)}},keyboardNavigationLabelProvider:a.keyboardNavigationLabelProvider&&Object.assign(Object.assign({},a.keyboardNavigationLabelProvider),{getKeyboardNavigationLabel(n){return a.keyboardNavigationLabelProvider.getKeyboardNavigationLabel(n.element)}}),sorter:void 0,expandOnlyOnTwistieClick:typeof a.expandOnlyOnTwistieClick>"u"?void 0:typeof a.expandOnlyOnTwistieClick!="function"?a.expandOnlyOnTwistieClick:n=>a.expandOnlyOnTwistieClick(n.element),additionalScrollHeight:a.additionalScrollHeight})}function ve(a,n){n(a),a.children.forEach(c=>ve(c,n))}class Te{constructor(n,c,I,F,J,ae={}){this.user=n,this.dataSource=J,this.nodes=new Map,this.subTreeRefreshPromises=new Map,this.refreshPromises=new Map,this._onDidRender=new $.vl,this._onDidChangeNodeSlowState=new $.vl,this.nodeMapper=new W(de=>new Xe(de)),this.disposables=new L.Cm,this.identityProvider=ae.identityProvider,this.autoExpandSingleChildren=typeof ae.autoExpandSingleChildren>"u"?!1:ae.autoExpandSingleChildren,this.sorter=ae.sorter,this.collapseByDefault=ae.collapseByDefault,this.tree=this.createTree(n,c,I,F,ae),this.onDidChangeFindMode=this.tree.onDidChangeFindMode,this.root=si({element:void 0,parent:null,hasChildren:!0}),this.identityProvider&&(this.root=Object.assign(Object.assign({},this.root),{id:null})),this.nodes.set(null,this.root),this.tree.onDidChangeCollapseState(this._onDidChangeCollapseState,this,this.disposables)}get onDidChangeFocus(){return $.Jh.map(this.tree.onDidChangeFocus,Xt)}get onDidChangeSelection(){return $.Jh.map(this.tree.onDidChangeSelection,Xt)}get onMouseDblClick(){return $.Jh.map(this.tree.onMouseDblClick,Vt)}get onPointer(){return $.Jh.map(this.tree.onPointer,Vt)}get onDidFocus(){return this.tree.onDidFocus}get onDidChangeModel(){return this.tree.onDidChangeModel}get onDidChangeCollapseState(){return this.tree.onDidChangeCollapseState}get onDidChangeFindOpenState(){return this.tree.onDidChangeFindOpenState}get onDidDispose(){return this.tree.onDidDispose}createTree(n,c,I,F,J){const ae=new ce(I),de=F.map(Ee=>new gt(Ee,this.nodeMapper,this._onDidChangeNodeSlowState.event)),Ce=St(J)||{};return new Si(n,c,ae,de,Ce)}updateOptions(n={}){this.tree.updateOptions(n)}getHTMLElement(){return this.tree.getHTMLElement()}get scrollTop(){return this.tree.scrollTop}set scrollTop(n){this.tree.scrollTop=n}domFocus(){this.tree.domFocus()}layout(n,c){this.tree.layout(n,c)}style(n){this.tree.style(n)}getInput(){return this.root.element}setInput(n,c){return Ot(this,void 0,void 0,function*(){this.refreshPromises.forEach(F=>F.cancel()),this.refreshPromises.clear(),this.root.element=n;const I=c&&{viewState:c,focus:[],selection:[]};yield this._updateChildren(n,!0,!1,I),I&&(this.tree.setFocus(I.focus),this.tree.setSelection(I.selection)),c&&typeof c.scrollTop=="number"&&(this.scrollTop=c.scrollTop)})}_updateChildren(n=this.root.element,c=!0,I=!1,F,J){return Ot(this,void 0,void 0,function*(){if(typeof this.root.element>"u")throw new A(this.user,"Tree input not set");this.root.refreshPromise&&(yield this.root.refreshPromise,yield $.Jh.toPromise(this._onDidRender.event));const ae=this.getDataNode(n);if(yield this.refreshAndRenderNode(ae,c,F,J),I)try{this.tree.rerender(ae)}catch{}})}rerender(n){if(n===void 0||n===this.root.element){this.tree.rerender();return}const c=this.getDataNode(n);this.tree.rerender(c)}getNode(n=this.root.element){const c=this.getDataNode(n),I=this.tree.getNode(c===this.root?null:c);return this.nodeMapper.map(I)}collapse(n,c=!1){const I=this.getDataNode(n);return this.tree.collapse(I===this.root?null:I,c)}expand(n,c=!1){return Ot(this,void 0,void 0,function*(){if(typeof this.root.element>"u")throw new A(this.user,"Tree input not set");this.root.refreshPromise&&(yield this.root.refreshPromise,yield $.Jh.toPromise(this._onDidRender.event));const I=this.getDataNode(n);if(this.tree.hasElement(I)&&!this.tree.isCollapsible(I)||(I.refreshPromise&&(yield this.root.refreshPromise,yield $.Jh.toPromise(this._onDidRender.event)),I!==this.root&&!I.refreshPromise&&!this.tree.isCollapsed(I)))return!1;const F=this.tree.expand(I===this.root?null:I,c);return I.refreshPromise&&(yield this.root.refreshPromise,yield $.Jh.toPromise(this._onDidRender.event)),F})}setSelection(n,c){const I=n.map(F=>this.getDataNode(F));this.tree.setSelection(I,c)}getSelection(){return this.tree.getSelection().map(c=>c.element)}setFocus(n,c){const I=n.map(F=>this.getDataNode(F));this.tree.setFocus(I,c)}getFocus(){return this.tree.getFocus().map(c=>c.element)}reveal(n,c){this.tree.reveal(this.getDataNode(n),c)}getParentElement(n){const c=this.tree.getParentElement(this.getDataNode(n));return c&&c.element}getFirstElementChild(n=this.root.element){const c=this.getDataNode(n),I=this.tree.getFirstElementChild(c===this.root?null:c);return I&&I.element}getDataNode(n){const c=this.nodes.get(n===this.root.element?null:n);if(!c)throw new A(this.user,`Data tree node not found: ${n}`);return c}refreshAndRenderNode(n,c,I,F){return Ot(this,void 0,void 0,function*(){yield this.refreshNode(n,c,I),this.render(n,I,F)})}refreshNode(n,c,I){return Ot(this,void 0,void 0,function*(){let F;if(this.subTreeRefreshPromises.forEach((J,ae)=>{!F&&Fe(ae,n)&&(F=J.then(()=>this.refreshNode(n,c,I)))}),F)return F;if(n!==this.root&&this.tree.getNode(n).collapsed){n.hasChildren=!!this.dataSource.hasChildren(n.element),n.stale=!0;return}return this.doRefreshSubTree(n,c,I)})}doRefreshSubTree(n,c,I){return Ot(this,void 0,void 0,function*(){let F;n.refreshPromise=new Promise(J=>F=J),this.subTreeRefreshPromises.set(n,n.refreshPromise),n.refreshPromise.finally(()=>{n.refreshPromise=void 0,this.subTreeRefreshPromises.delete(n)});try{const J=yield this.doRefreshNode(n,c,I);n.stale=!1,yield Y.HC.settled(J.map(ae=>this.doRefreshSubTree(ae,c,I)))}finally{F()}})}doRefreshNode(n,c,I){return Ot(this,void 0,void 0,function*(){n.hasChildren=!!this.dataSource.hasChildren(n.element);let F;if(!n.hasChildren)F=Promise.resolve(j.f.empty());else{const J=this.doGetChildren(n);if((0,oe.xZ)(J))F=Promise.resolve(J);else{const ae=(0,Y.wR)(800);ae.then(()=>{n.slow=!0,this._onDidChangeNodeSlowState.fire(n)},de=>null),F=J.finally(()=>ae.cancel())}}try{const J=yield F;return this.setChildren(n,J,c,I)}catch(J){if(n!==this.root&&this.tree.hasElement(n)&&this.tree.collapse(n),(0,Et.MB)(J))return[];throw J}finally{n.slow&&(n.slow=!1,this._onDidChangeNodeSlowState.fire(n))}})}doGetChildren(n){let c=this.refreshPromises.get(n);if(c)return c;const I=this.dataSource.getChildren(n.element);return(0,oe.xZ)(I)?this.processChildren(I):(c=(0,Y.SS)(()=>Ot(this,void 0,void 0,function*(){return this.processChildren(yield I)})),this.refreshPromises.set(n,c),c.finally(()=>{this.refreshPromises.delete(n)}))}_onDidChangeCollapseState({node:n,deep:c}){n.element!==null&&!n.collapsed&&n.element.stale&&(c?this.collapse(n.element.element):this.refreshAndRenderNode(n.element,!1).catch(Et.dz))}setChildren(n,c,I,F){const J=[...c];if(n.children.length===0&&J.length===0)return[];const ae=new Map,de=new Map;for(const Ne of n.children)if(ae.set(Ne.element,Ne),this.identityProvider){const He=this.tree.isCollapsed(Ne);de.set(Ne.id,{node:Ne,collapsed:He})}const Ce=[],Ee=J.map(Ne=>{const He=!!this.dataSource.hasChildren(Ne);if(!this.identityProvider){const lt=si({element:Ne,parent:n,hasChildren:He});return He&&this.collapseByDefault&&!this.collapseByDefault(Ne)&&(lt.collapsedByDefault=!1,Ce.push(lt)),lt}const Ze=this.identityProvider.getId(Ne).toString(),et=de.get(Ze);if(et){const lt=et.node;return ae.delete(lt.element),this.nodes.delete(lt.element),this.nodes.set(Ne,lt),lt.element=Ne,lt.hasChildren=He,I?et.collapsed?(lt.children.forEach(_t=>ve(_t,Ft=>this.nodes.delete(Ft.element))),lt.children.splice(0,lt.children.length),lt.stale=!0):Ce.push(lt):He&&this.collapseByDefault&&!this.collapseByDefault(Ne)&&(lt.collapsedByDefault=!1,Ce.push(lt)),lt}const ot=si({element:Ne,parent:n,id:Ze,hasChildren:He});return F&&F.viewState.focus&&F.viewState.focus.indexOf(Ze)>-1&&F.focus.push(ot),F&&F.viewState.selection&&F.viewState.selection.indexOf(Ze)>-1&&F.selection.push(ot),F&&F.viewState.expanded&&F.viewState.expanded.indexOf(Ze)>-1?Ce.push(ot):He&&this.collapseByDefault&&!this.collapseByDefault(Ne)&&(ot.collapsedByDefault=!1,Ce.push(ot)),ot});for(const Ne of ae.values())ve(Ne,He=>this.nodes.delete(He.element));for(const Ne of Ee)this.nodes.set(Ne.element,Ne);return n.children.splice(0,n.children.length,...Ee),n!==this.root&&this.autoExpandSingleChildren&&Ee.length===1&&Ce.length===0&&(Ee[0].collapsedByDefault=!1,Ce.push(Ee[0])),Ce}render(n,c,I){const F=n.children.map(ae=>this.asTreeElement(ae,c)),J=I&&Object.assign(Object.assign({},I),{diffIdentityProvider:I.diffIdentityProvider&&{getId(ae){return I.diffIdentityProvider.getId(ae.element)}}});this.tree.setChildren(n===this.root?null:n,F,J),n!==this.root&&this.tree.setCollapsible(n,n.hasChildren),this._onDidRender.fire()}asTreeElement(n,c){if(n.stale)return{element:n,collapsible:n.hasChildren,collapsed:!0};let I;return c&&c.viewState.expanded&&n.id&&c.viewState.expanded.indexOf(n.id)>-1?I=!1:I=n.collapsedByDefault,n.collapsedByDefault=void 0,{element:n,children:n.hasChildren?j.f.map(n.children,F=>this.asTreeElement(F,c)):[],collapsible:n.hasChildren,collapsed:I}}processChildren(n){return this.sorter&&(n=[...n].sort(this.sorter.compare.bind(this.sorter))),n}dispose(){this.disposables.dispose()}}class je{constructor(n){this.node=n}get element(){return{elements:this.node.element.elements.map(n=>n.element),incompressible:this.node.element.incompressible}}get children(){return this.node.children.map(n=>new je(n))}get depth(){return this.node.depth}get visibleChildrenCount(){return this.node.visibleChildrenCount}get visibleChildIndex(){return this.node.visibleChildIndex}get collapsible(){return this.node.collapsible}get collapsed(){return this.node.collapsed}get visible(){return this.node.visible}get filterData(){return this.node.filterData}}class nt{constructor(n,c,I,F){this.renderer=n,this.nodeMapper=c,this.compressibleNodeMapperProvider=I,this.onDidChangeTwistieState=F,this.renderedNodes=new Map,this.disposables=[],this.templateId=n.templateId}renderTemplate(n){return{templateData:this.renderer.renderTemplate(n)}}renderElement(n,c,I,F){this.renderer.renderElement(this.nodeMapper.map(n),c,I.templateData,F)}renderCompressedElements(n,c,I,F){this.renderer.renderCompressedElements(this.compressibleNodeMapperProvider().map(n),c,I.templateData,F)}renderTwistie(n,c){return n.slow?(c.classList.add(...N.W6.treeItemLoading.classNamesArray),!0):(c.classList.remove(...N.W6.treeItemLoading.classNamesArray),!1)}disposeElement(n,c,I,F){var J,ae;(ae=(J=this.renderer).disposeElement)===null||ae===void 0||ae.call(J,this.nodeMapper.map(n),c,I.templateData,F)}disposeCompressedElements(n,c,I,F){var J,ae;(ae=(J=this.renderer).disposeCompressedElements)===null||ae===void 0||ae.call(J,this.compressibleNodeMapperProvider().map(n),c,I.templateData,F)}disposeTemplate(n){this.renderer.disposeTemplate(n.templateData)}dispose(){this.renderedNodes.clear(),this.disposables=(0,L.AS)(this.disposables)}}function at(a){const n=a&&St(a);return n&&Object.assign(Object.assign({},n),{keyboardNavigationLabelProvider:n.keyboardNavigationLabelProvider&&Object.assign(Object.assign({},n.keyboardNavigationLabelProvider),{getCompressedNodeKeyboardNavigationLabel(c){return a.keyboardNavigationLabelProvider.getCompressedNodeKeyboardNavigationLabel(c.map(I=>I.element))}})})}class vt extends Te{constructor(n,c,I,F,J,ae,de={}){super(n,c,I,J,ae,de),this.compressionDelegate=F,this.compressibleNodeMapper=new W(Ce=>new je(Ce)),this.filter=de.filter}createTree(n,c,I,F,J){const ae=new ce(I),de=F.map(Ee=>new nt(Ee,this.nodeMapper,()=>this.compressibleNodeMapper,this._onDidChangeNodeSlowState.event)),Ce=at(J)||{};return new ze(n,c,ae,de,Ce)}asTreeElement(n,c){return Object.assign({incompressible:this.compressionDelegate.isIncompressible(n.element)},super.asTreeElement(n,c))}updateOptions(n={}){this.tree.updateOptions(n)}render(n,c){if(!this.identityProvider)return super.render(n,c);const I=Ze=>this.identityProvider.getId(Ze).toString(),F=Ze=>{const et=new Set;for(const ot of Ze){const lt=this.tree.getCompressedTreeNode(ot===this.root?null:ot);if(lt.element)for(const _t of lt.element.elements)et.add(I(_t.element))}return et},J=F(this.tree.getSelection()),ae=F(this.tree.getFocus());super.render(n,c);const de=this.getSelection();let Ce=!1;const Ee=this.getFocus();let Ne=!1;const He=Ze=>{const et=Ze.element;if(et)for(let ot=0;ot<et.elements.length;ot++){const lt=I(et.elements[ot].element),_t=et.elements[et.elements.length-1].element;J.has(lt)&&de.indexOf(_t)===-1&&(de.push(_t),Ce=!0),ae.has(lt)&&Ee.indexOf(_t)===-1&&(Ee.push(_t),Ne=!0)}Ze.children.forEach(He)};He(this.tree.getCompressedTreeNode(n===this.root?null:n)),Ce&&this.setSelection(de),Ne&&this.setFocus(Ee)}processChildren(n){return this.filter&&(n=j.f.filter(n,c=>{const I=this.filter.filter(c,1),F=It(I);if(F===2)throw new Error("Recursive tree visibility not supported in async data compressed trees");return F===1})),super.processChildren(n)}}function It(a){return typeof a=="boolean"?a?1:0:Q(a)?X(a.visibility):X(a)}class At extends tt{constructor(n,c,I,F,J,ae={}){super(n,c,I,F,ae),this.user=n,this.dataSource=J,this.identityProvider=ae.identityProvider}createModel(n,c,I){return new Ye(n,c,I)}}var wt=y(85753),kt=y(27142),Ct=y(96655),Gt=y(13034),Ht=y(52348),Ut=y(82399),Ue=y(56071),ei=y(67167),ui=y(1597),oi=y(89044),ki=function(a,n,c,I){var F=arguments.length,J=F<3?n:I===null?I=Object.getOwnPropertyDescriptor(n,c):I,ae;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")J=Reflect.decorate(a,n,c,I);else for(var de=a.length-1;de>=0;de--)(ae=a[de])&&(J=(F<3?ae(J):F>3?ae(n,c,J):ae(n,c))||J);return F>3&&J&&Object.defineProperty(n,c,J),J},Kt=function(a,n){return function(c,I){n(c,I,a)}};const li=(0,Ut.u1)("listService");let Ci=class{constructor(n){this._themeService=n,this.disposables=new L.Cm,this.lists=[],this._lastFocusedWidget=void 0,this._hasCreatedStyleController=!1}get lastFocusedList(){return this._lastFocusedWidget}setLastFocusedList(n){var c,I;n!==this._lastFocusedWidget&&((c=this._lastFocusedWidget)===null||c===void 0||c.getHTMLElement().classList.remove("last-focused"),this._lastFocusedWidget=n,(I=this._lastFocusedWidget)===null||I===void 0||I.getHTMLElement().classList.add("last-focused"))}register(n,c){if(!this._hasCreatedStyleController){this._hasCreatedStyleController=!0;const F=new U.hb((0,b.li)(),"");this.disposables.add((0,ui.DD)(F,this._themeService))}if(this.lists.some(F=>F.widget===n))throw new Error("Cannot register the same widget multiple times");const I={widget:n,extraContextKeys:c};return this.lists.push(I),n.getHTMLElement()===document.activeElement&&this.setLastFocusedList(n),(0,L.qE)(n.onDidFocus(()=>this.setLastFocusedList(n)),(0,L.s)(()=>this.lists.splice(this.lists.indexOf(I),1)),n.onDidDispose(()=>{this.lists=this.lists.filter(F=>F!==I),this._lastFocusedWidget===n&&this.setLastFocusedList(void 0)}))}dispose(){this.disposables.dispose()}};Ci=ki([Kt(0,oi.Gy)],Ci);const mi=new Ct.N1("listFocus",!0),Tt=new Ct.N1("listSupportsMultiselect",!0),qt=Ct.M$.and(mi,Ct.M$.not(Gt.aV)),Ni=new Ct.N1("listHasSelectionOrFocus",!1),Fi=new Ct.N1("listDoubleSelection",!1),yi=new Ct.N1("listMultiSelection",!1),ti=new Ct.N1("listSelectionNavigation",!1),wi=new Ct.N1("listSupportsFind",!0),Qi=new Ct.N1("treeElementCanCollapse",!1),Vi=new Ct.N1("treeElementHasParent",!1),Zi=new Ct.N1("treeElementCanExpand",!1),Ji=new Ct.N1("treeElementHasChild",!1),qi=new Ct.N1("treeFindOpen",!1),Pi="listTypeNavigationMode",fi="listAutomaticKeyboardNavigation";function Sn(a,n){const c=a.createScoped(n.getHTMLElement());return mi.bindTo(c),c}const cn="workbench.list.multiSelectModifier",en="workbench.list.openMode",dn="workbench.list.horizontalScrolling",Li="workbench.list.defaultFindMode",Rn="workbench.list.keyboardNavigation",In="workbench.tree.indent",xn="workbench.tree.renderIndentGuides",Tn="workbench.list.smoothScrolling",wn="workbench.list.mouseWheelScrollSensitivity",Ln="workbench.list.fastScrollSensitivity",Cn="workbench.tree.expandMode";function Bn(a){return a.getValue(cn)==="alt"}class Mn extends L.jG{constructor(n){super(),this.configurationService=n,this.useAltAsMultipleSelectionModifier=Bn(n),this.registerListeners()}registerListeners(){this._register(this.configurationService.onDidChangeConfiguration(n=>{n.affectsConfiguration(cn)&&(this.useAltAsMultipleSelectionModifier=Bn(this.configurationService))}))}isSelectionSingleChangeEvent(n){return this.useAltAsMultipleSelectionModifier?n.browserEvent.altKey:(0,U.tX)(n)}isSelectionRangeChangeEvent(n){return(0,U.mh)(n)}}function Yn(a,n){var c;const I=a.get(wt.pG),F=a.get(Ue.b),J=new L.Cm;return[Object.assign(Object.assign({},n),{keyboardNavigationDelegate:{mightProducePrintableCharacter(de){return F.mightProducePrintableCharacter(de)}},smoothScrolling:!!I.getValue(Tn),mouseWheelScrollSensitivity:I.getValue(wn),fastScrollSensitivity:I.getValue(Ln),multipleSelectionController:(c=n.multipleSelectionController)!==null&&c!==void 0?c:J.add(new Mn(I)),keyboardNavigationEventFilter:$n(F)}),J]}let Hn=class extends U.B8{constructor(n,c,I,F,J,ae,de,Ce,Ee,Ne){const He=typeof J.horizontalScrolling<"u"?J.horizontalScrolling:!!Ee.getValue(dn),[Ze,et]=Ne.invokeFunction(Yn,J);super(n,c,I,F,Object.assign(Object.assign(Object.assign({keyboardSupport:!1},(0,ui.KC)(Ce.getColorTheme(),ui.IN)),Ze),{horizontalScrolling:He})),this.disposables.add(et),this.contextKeyService=Sn(ae,this),this.themeService=Ce,this.listSupportsMultiSelect=Tt.bindTo(this.contextKeyService),this.listSupportsMultiSelect.set(J.multipleSelectionSupport!==!1),ti.bindTo(this.contextKeyService).set(!!J.selectionNavigation),this.listHasSelectionOrFocus=Ni.bindTo(this.contextKeyService),this.listDoubleSelection=Fi.bindTo(this.contextKeyService),this.listMultiSelection=yi.bindTo(this.contextKeyService),this.horizontalScrolling=J.horizontalScrolling,this._useAltAsMultipleSelectionModifier=Bn(Ee),this.disposables.add(this.contextKeyService),this.disposables.add(de.register(this)),J.overrideStyles&&this.updateStyles(J.overrideStyles),this.disposables.add(this.onDidChangeSelection(()=>{const lt=this.getSelection(),_t=this.getFocus();this.contextKeyService.bufferChangeEvents(()=>{this.listHasSelectionOrFocus.set(lt.length>0||_t.length>0),this.listMultiSelection.set(lt.length>1),this.listDoubleSelection.set(lt.length===2)})})),this.disposables.add(this.onDidChangeFocus(()=>{const lt=this.getSelection(),_t=this.getFocus();this.listHasSelectionOrFocus.set(lt.length>0||_t.length>0)})),this.disposables.add(Ee.onDidChangeConfiguration(lt=>{lt.affectsConfiguration(cn)&&(this._useAltAsMultipleSelectionModifier=Bn(Ee));let _t={};if(lt.affectsConfiguration(dn)&&this.horizontalScrolling===void 0){const Ft=!!Ee.getValue(dn);_t=Object.assign(Object.assign({},_t),{horizontalScrolling:Ft})}if(lt.affectsConfiguration(Tn)){const Ft=!!Ee.getValue(Tn);_t=Object.assign(Object.assign({},_t),{smoothScrolling:Ft})}if(lt.affectsConfiguration(wn)){const Ft=Ee.getValue(wn);_t=Object.assign(Object.assign({},_t),{mouseWheelScrollSensitivity:Ft})}if(lt.affectsConfiguration(Ln)){const Ft=Ee.getValue(Ln);_t=Object.assign(Object.assign({},_t),{fastScrollSensitivity:Ft})}Object.keys(_t).length>0&&this.updateOptions(_t)})),this.navigator=new sn(this,Object.assign({configurationService:Ee},J)),this.disposables.add(this.navigator)}updateOptions(n){super.updateOptions(n),n.overrideStyles&&this.updateStyles(n.overrideStyles),n.multipleSelectionSupport!==void 0&&this.listSupportsMultiSelect.set(!!n.multipleSelectionSupport)}updateStyles(n){var c;(c=this._styler)===null||c===void 0||c.dispose(),this._styler=(0,ui.DD)(this,this.themeService,n)}dispose(){var n;(n=this._styler)===null||n===void 0||n.dispose(),super.dispose()}};Hn=ki([Kt(5,Ct.fN),Kt(6,li),Kt(7,oi.Gy),Kt(8,wt.pG),Kt(9,Ut._Y)],Hn);let _n=class extends p{constructor(n,c,I,F,J,ae,de,Ce,Ee,Ne){const He=typeof J.horizontalScrolling<"u"?J.horizontalScrolling:!!Ee.getValue(dn),[Ze,et]=Ne.invokeFunction(Yn,J);super(n,c,I,F,Object.assign(Object.assign(Object.assign({keyboardSupport:!1},(0,ui.KC)(Ce.getColorTheme(),ui.IN)),Ze),{horizontalScrolling:He})),this.disposables=new L.Cm,this.disposables.add(et),this.contextKeyService=Sn(ae,this),this.themeService=Ce,this.horizontalScrolling=J.horizontalScrolling,this.listSupportsMultiSelect=Tt.bindTo(this.contextKeyService),this.listSupportsMultiSelect.set(J.multipleSelectionSupport!==!1),ti.bindTo(this.contextKeyService).set(!!J.selectionNavigation),this._useAltAsMultipleSelectionModifier=Bn(Ee),this.disposables.add(this.contextKeyService),this.disposables.add(de.register(this)),J.overrideStyles&&this.updateStyles(J.overrideStyles),J.overrideStyles&&this.disposables.add((0,ui.DD)(this,Ce,J.overrideStyles)),this.disposables.add(Ee.onDidChangeConfiguration(lt=>{lt.affectsConfiguration(cn)&&(this._useAltAsMultipleSelectionModifier=Bn(Ee));let _t={};if(lt.affectsConfiguration(dn)&&this.horizontalScrolling===void 0){const Ft=!!Ee.getValue(dn);_t=Object.assign(Object.assign({},_t),{horizontalScrolling:Ft})}if(lt.affectsConfiguration(Tn)){const Ft=!!Ee.getValue(Tn);_t=Object.assign(Object.assign({},_t),{smoothScrolling:Ft})}if(lt.affectsConfiguration(wn)){const Ft=Ee.getValue(wn);_t=Object.assign(Object.assign({},_t),{mouseWheelScrollSensitivity:Ft})}if(lt.affectsConfiguration(Ln)){const Ft=Ee.getValue(Ln);_t=Object.assign(Object.assign({},_t),{fastScrollSensitivity:Ft})}Object.keys(_t).length>0&&this.updateOptions(_t)})),this.navigator=new sn(this,Object.assign({configurationService:Ee},J)),this.disposables.add(this.navigator)}updateOptions(n){super.updateOptions(n),n.overrideStyles&&this.updateStyles(n.overrideStyles),n.multipleSelectionSupport!==void 0&&this.listSupportsMultiSelect.set(!!n.multipleSelectionSupport)}updateStyles(n){var c;(c=this._styler)===null||c===void 0||c.dispose(),this._styler=(0,ui.DD)(this,this.themeService,n)}dispose(){var n;(n=this._styler)===null||n===void 0||n.dispose(),this.disposables.dispose(),super.dispose()}};_n=ki([Kt(5,Ct.fN),Kt(6,li),Kt(7,oi.Gy),Kt(8,wt.pG),Kt(9,Ut._Y)],_n);let yn=class extends u{constructor(n,c,I,F,J,ae,de,Ce,Ee,Ne,He){const Ze=typeof ae.horizontalScrolling<"u"?ae.horizontalScrolling:!!Ne.getValue(dn),[et,ot]=He.invokeFunction(Yn,ae);super(n,c,I,F,J,Object.assign(Object.assign(Object.assign({keyboardSupport:!1},(0,ui.KC)(Ee.getColorTheme(),ui.IN)),et),{horizontalScrolling:Ze})),this.disposables.add(ot),this.contextKeyService=Sn(de,this),this.themeService=Ee,this.listSupportsMultiSelect=Tt.bindTo(this.contextKeyService),this.listSupportsMultiSelect.set(ae.multipleSelectionSupport!==!1),ti.bindTo(this.contextKeyService).set(!!ae.selectionNavigation),this.listHasSelectionOrFocus=Ni.bindTo(this.contextKeyService),this.listDoubleSelection=Fi.bindTo(this.contextKeyService),this.listMultiSelection=yi.bindTo(this.contextKeyService),this.horizontalScrolling=ae.horizontalScrolling,this._useAltAsMultipleSelectionModifier=Bn(Ne),this.disposables.add(this.contextKeyService),this.disposables.add(Ce.register(this)),ae.overrideStyles&&this.updateStyles(ae.overrideStyles),this.disposables.add(this.onDidChangeSelection(()=>{const _t=this.getSelection(),Ft=this.getFocus();this.contextKeyService.bufferChangeEvents(()=>{this.listHasSelectionOrFocus.set(_t.length>0||Ft.length>0),this.listMultiSelection.set(_t.length>1),this.listDoubleSelection.set(_t.length===2)})})),this.disposables.add(this.onDidChangeFocus(()=>{const _t=this.getSelection(),Ft=this.getFocus();this.listHasSelectionOrFocus.set(_t.length>0||Ft.length>0)})),this.disposables.add(Ne.onDidChangeConfiguration(_t=>{_t.affectsConfiguration(cn)&&(this._useAltAsMultipleSelectionModifier=Bn(Ne));let Ft={};if(_t.affectsConfiguration(dn)&&this.horizontalScrolling===void 0){const ci=!!Ne.getValue(dn);Ft=Object.assign(Object.assign({},Ft),{horizontalScrolling:ci})}if(_t.affectsConfiguration(Tn)){const ci=!!Ne.getValue(Tn);Ft=Object.assign(Object.assign({},Ft),{smoothScrolling:ci})}if(_t.affectsConfiguration(wn)){const ci=Ne.getValue(wn);Ft=Object.assign(Object.assign({},Ft),{mouseWheelScrollSensitivity:ci})}if(_t.affectsConfiguration(Ln)){const ci=Ne.getValue(Ln);Ft=Object.assign(Object.assign({},Ft),{fastScrollSensitivity:ci})}Object.keys(Ft).length>0&&this.updateOptions(Ft)})),this.navigator=new zn(this,Object.assign({configurationService:Ne},ae)),this.disposables.add(this.navigator)}updateOptions(n){super.updateOptions(n),n.overrideStyles&&this.updateStyles(n.overrideStyles),n.multipleSelectionSupport!==void 0&&this.listSupportsMultiSelect.set(!!n.multipleSelectionSupport)}updateStyles(n){var c;(c=this._styler)===null||c===void 0||c.dispose(),this._styler=(0,ui.DD)(this,this.themeService,n)}dispose(){var n;(n=this._styler)===null||n===void 0||n.dispose(),this.disposables.dispose(),super.dispose()}};yn=ki([Kt(6,Ct.fN),Kt(7,li),Kt(8,oi.Gy),Kt(9,wt.pG),Kt(10,Ut._Y)],yn);class On extends L.jG{constructor(n,c){var I;super(),this.widget=n,this._onDidOpen=this._register(new $.vl),this.onDidOpen=this._onDidOpen.event,this._register($.Jh.filter(this.widget.onDidChangeSelection,F=>F.browserEvent instanceof KeyboardEvent)(F=>this.onSelectionFromKeyboard(F))),this._register(this.widget.onPointer(F=>this.onPointer(F.element,F.browserEvent))),this._register(this.widget.onMouseDblClick(F=>this.onMouseDblClick(F.element,F.browserEvent))),typeof c?.openOnSingleClick!="boolean"&&c?.configurationService?(this.openOnSingleClick=c?.configurationService.getValue(en)!=="doubleClick",this._register(c?.configurationService.onDidChangeConfiguration(()=>{this.openOnSingleClick=c?.configurationService.getValue(en)!=="doubleClick"}))):this.openOnSingleClick=(I=c?.openOnSingleClick)!==null&&I!==void 0?I:!0}onSelectionFromKeyboard(n){if(n.elements.length!==1)return;const c=n.browserEvent,I=typeof c.preserveFocus=="boolean"?c.preserveFocus:!0,F=typeof c.pinned=="boolean"?c.pinned:!I;this._open(this.getSelectedElement(),I,F,!1,n.browserEvent)}onPointer(n,c){if(!this.openOnSingleClick||c.detail===2)return;const F=c.button===1,J=!0,ae=F,de=c.ctrlKey||c.metaKey||c.altKey;this._open(n,J,ae,de,c)}onMouseDblClick(n,c){if(!c)return;const I=c.target;if(I.classList.contains("monaco-tl-twistie")||I.classList.contains("monaco-icon-label")&&I.classList.contains("folder-icon")&&c.offsetX<16)return;const J=!1,ae=!0,de=c.ctrlKey||c.metaKey||c.altKey;this._open(n,J,ae,de,c)}_open(n,c,I,F,J){n&&this._onDidOpen.fire({editorOptions:{preserveFocus:c,pinned:I,revealIfVisible:!0},sideBySide:F,element:n,browserEvent:J})}}class sn extends On{constructor(n,c){super(n,c),this.widget=n}getSelectedElement(){return this.widget.getSelectedElements()[0]}}class zn extends On{constructor(n,c){super(n,c)}getSelectedElement(){return this.widget.getSelectedElements()[0]}}class Gi extends On{constructor(n,c){super(n,c)}getSelectedElement(){var n;return(n=this.widget.getSelection()[0])!==null&&n!==void 0?n:void 0}}function $n(a){let n=!1;return c=>{if(c.toKeybinding().isModifierKey())return!1;if(n)return n=!1,!1;const I=a.softDispatch(c,c.target);return I?.enterChord?(n=!0,!1):(n=!1,!I)}}let Nn=class extends Si{constructor(n,c,I,F,J,ae,de,Ce,Ee,Ne){const{options:He,getTypeNavigationMode:Ze,disposable:et}=ae.invokeFunction(Ui,J);super(n,c,I,F,He),this.disposables.add(et),this.internals=new Wi(this,J,Ze,J.overrideStyles,de,Ce,Ee,Ne),this.disposables.add(this.internals)}updateOptions(n){super.updateOptions(n),this.internals.updateOptions(n)}};Nn=ki([Kt(5,Ut._Y),Kt(6,Ct.fN),Kt(7,li),Kt(8,oi.Gy),Kt(9,wt.pG)],Nn);let bi=class extends ze{constructor(n,c,I,F,J,ae,de,Ce,Ee,Ne){const{options:He,getTypeNavigationMode:Ze,disposable:et}=ae.invokeFunction(Ui,J);super(n,c,I,F,He),this.disposables.add(et),this.internals=new Wi(this,J,Ze,J.overrideStyles,de,Ce,Ee,Ne),this.disposables.add(this.internals)}updateOptions(n={}){super.updateOptions(n),n.overrideStyles&&this.internals.updateStyleOverrides(n.overrideStyles),this.internals.updateOptions(n)}};bi=ki([Kt(5,Ut._Y),Kt(6,Ct.fN),Kt(7,li),Kt(8,oi.Gy),Kt(9,wt.pG)],bi);let pt=class extends At{constructor(n,c,I,F,J,ae,de,Ce,Ee,Ne,He){const{options:Ze,getTypeNavigationMode:et,disposable:ot}=de.invokeFunction(Ui,ae);super(n,c,I,F,J,Ze),this.disposables.add(ot),this.internals=new Wi(this,ae,et,ae.overrideStyles,Ce,Ee,Ne,He),this.disposables.add(this.internals)}updateOptions(n={}){super.updateOptions(n),n.overrideStyles&&this.internals.updateStyleOverrides(n.overrideStyles),this.internals.updateOptions(n)}};pt=ki([Kt(6,Ut._Y),Kt(7,Ct.fN),Kt(8,li),Kt(9,oi.Gy),Kt(10,wt.pG)],pt);let zt=class extends Te{constructor(n,c,I,F,J,ae,de,Ce,Ee,Ne,He){const{options:Ze,getTypeNavigationMode:et,disposable:ot}=de.invokeFunction(Ui,ae);super(n,c,I,F,J,Ze),this.disposables.add(ot),this.internals=new Wi(this,ae,et,ae.overrideStyles,Ce,Ee,Ne,He),this.disposables.add(this.internals)}get onDidOpen(){return this.internals.onDidOpen}updateOptions(n={}){super.updateOptions(n),n.overrideStyles&&this.internals.updateStyleOverrides(n.overrideStyles),this.internals.updateOptions(n)}};zt=ki([Kt(6,Ut._Y),Kt(7,Ct.fN),Kt(8,li),Kt(9,oi.Gy),Kt(10,wt.pG)],zt);let Qt=class extends vt{constructor(n,c,I,F,J,ae,de,Ce,Ee,Ne,He,Ze){const{options:et,getTypeNavigationMode:ot,disposable:lt}=Ce.invokeFunction(Ui,de);super(n,c,I,F,J,ae,et),this.disposables.add(lt),this.internals=new Wi(this,de,ot,de.overrideStyles,Ee,Ne,He,Ze),this.disposables.add(this.internals)}updateOptions(n){super.updateOptions(n),this.internals.updateOptions(n)}};Qt=ki([Kt(7,Ut._Y),Kt(8,Ct.fN),Kt(9,li),Kt(10,oi.Gy),Kt(11,wt.pG)],Qt);function Di(a){const n=a.getValue(Li);if(n==="highlight")return Ge.Highlight;if(n==="filter")return Ge.Filter;const c=a.getValue(Rn);if(c==="simple"||c==="highlight")return Ge.Highlight;if(c==="filter")return Ge.Filter}function Ui(a,n){var c;const I=a.get(wt.pG),F=a.get(Ht.l),J=a.get(Ct.fN),ae=a.get(Ut._Y),de=()=>{const Ze=J.getContextKeyValue(Pi);if(Ze==="automatic")return U._C.Automatic;if(Ze==="trigger"||J.getContextKeyValue(fi)===!1)return U._C.Trigger},Ce=n.horizontalScrolling!==void 0?n.horizontalScrolling:!!I.getValue(dn),[Ee,Ne]=ae.invokeFunction(Yn,n),He=n.additionalScrollHeight;return{getTypeNavigationMode:de,disposable:Ne,options:Object.assign(Object.assign({keyboardSupport:!1},Ee),{indent:typeof I.getValue(In)=="number"?I.getValue(In):void 0,renderIndentGuides:I.getValue(xn),smoothScrolling:!!I.getValue(Tn),defaultFindMode:Di(I),horizontalScrolling:Ce,additionalScrollHeight:He,hideTwistiesOfChildlessElements:n.hideTwistiesOfChildlessElements,expandOnlyOnTwistieClick:(c=n.expandOnlyOnTwistieClick)!==null&&c!==void 0?c:I.getValue(Cn)==="doubleClick",contextViewProvider:F})}}let Wi=class{constructor(n,c,I,F,J,ae,de,Ce){var Ee;this.tree=n,this.themeService=de,this.disposables=[],this.contextKeyService=Sn(J,n),this.listSupportsMultiSelect=Tt.bindTo(this.contextKeyService),this.listSupportsMultiSelect.set(c.multipleSelectionSupport!==!1),ti.bindTo(this.contextKeyService).set(!!c.selectionNavigation),this.listSupportFindWidget=wi.bindTo(this.contextKeyService),this.listSupportFindWidget.set((Ee=c.findWidgetEnabled)!==null&&Ee!==void 0?Ee:!0),this.hasSelectionOrFocus=Ni.bindTo(this.contextKeyService),this.hasDoubleSelection=Fi.bindTo(this.contextKeyService),this.hasMultiSelection=yi.bindTo(this.contextKeyService),this.treeElementCanCollapse=Qi.bindTo(this.contextKeyService),this.treeElementHasParent=Vi.bindTo(this.contextKeyService),this.treeElementCanExpand=Zi.bindTo(this.contextKeyService),this.treeElementHasChild=Ji.bindTo(this.contextKeyService),this.treeFindOpen=qi.bindTo(this.contextKeyService),this._useAltAsMultipleSelectionModifier=Bn(Ce),this.updateStyleOverrides(F);const He=()=>{const et=n.getFocus()[0];if(!et)return;const ot=n.getNode(et);this.treeElementCanCollapse.set(ot.collapsible&&!ot.collapsed),this.treeElementHasParent.set(!!n.getParentElement(et)),this.treeElementCanExpand.set(ot.collapsible&&ot.collapsed),this.treeElementHasChild.set(!!n.getFirstElementChild(et))},Ze=new Set;Ze.add(Pi),Ze.add(fi),this.disposables.push(this.contextKeyService,ae.register(n),n.onDidChangeSelection(()=>{const et=n.getSelection(),ot=n.getFocus();this.contextKeyService.bufferChangeEvents(()=>{this.hasSelectionOrFocus.set(et.length>0||ot.length>0),this.hasMultiSelection.set(et.length>1),this.hasDoubleSelection.set(et.length===2)})}),n.onDidChangeFocus(()=>{const et=n.getSelection(),ot=n.getFocus();this.hasSelectionOrFocus.set(et.length>0||ot.length>0),He()}),n.onDidChangeCollapseState(He),n.onDidChangeModel(He),n.onDidChangeFindOpenState(et=>this.treeFindOpen.set(et)),Ce.onDidChangeConfiguration(et=>{let ot={};if(et.affectsConfiguration(cn)&&(this._useAltAsMultipleSelectionModifier=Bn(Ce)),et.affectsConfiguration(In)){const lt=Ce.getValue(In);ot=Object.assign(Object.assign({},ot),{indent:lt})}if(et.affectsConfiguration(xn)){const lt=Ce.getValue(xn);ot=Object.assign(Object.assign({},ot),{renderIndentGuides:lt})}if(et.affectsConfiguration(Tn)){const lt=!!Ce.getValue(Tn);ot=Object.assign(Object.assign({},ot),{smoothScrolling:lt})}if((et.affectsConfiguration(Li)||et.affectsConfiguration(Rn))&&n.updateOptions({defaultFindMode:Di(Ce)}),et.affectsConfiguration(dn)&&c.horizontalScrolling===void 0){const lt=!!Ce.getValue(dn);ot=Object.assign(Object.assign({},ot),{horizontalScrolling:lt})}if(et.affectsConfiguration(Cn)&&c.expandOnlyOnTwistieClick===void 0&&(ot=Object.assign(Object.assign({},ot),{expandOnlyOnTwistieClick:Ce.getValue(Cn)==="doubleClick"})),et.affectsConfiguration(wn)){const lt=Ce.getValue(wn);ot=Object.assign(Object.assign({},ot),{mouseWheelScrollSensitivity:lt})}if(et.affectsConfiguration(Ln)){const lt=Ce.getValue(Ln);ot=Object.assign(Object.assign({},ot),{fastScrollSensitivity:lt})}Object.keys(ot).length>0&&n.updateOptions(ot)}),this.contextKeyService.onDidChangeContext(et=>{et.affectsSome(Ze)&&n.updateOptions({typeNavigationMode:I()})})),this.navigator=new Gi(n,Object.assign({configurationService:Ce},c)),this.disposables.push(this.navigator)}get onDidOpen(){return this.navigator.onDidOpen}updateOptions(n){n.multipleSelectionSupport!==void 0&&this.listSupportsMultiSelect.set(!!n.multipleSelectionSupport)}updateStyleOverrides(n){(0,L.AS)(this.styler),this.styler=n?(0,ui.DD)(this.tree,this.themeService,n):L.jG.None}dispose(){this.disposables=(0,L.AS)(this.disposables),(0,L.AS)(this.styler),this.styler=void 0}};Wi=ki([Kt(4,Ct.fN),Kt(5,li),Kt(6,oi.Gy),Kt(7,wt.pG)],Wi),ei.O.as(kt.Fd.Configuration).registerConfiguration({id:"workbench",order:7,title:(0,ue.kg)("workbenchConfigurationTitle","Workbench"),type:"object",properties:{[cn]:{type:"string",enum:["ctrlCmd","alt"],markdownEnumDescriptions:[(0,ue.kg)("multiSelectModifier.ctrlCmd","Maps to `Control` on Windows and Linux and to `Command` on macOS."),(0,ue.kg)("multiSelectModifier.alt","Maps to `Alt` on Windows and Linux and to `Option` on macOS.")],default:"ctrlCmd",description:(0,ue.kg)({key:"multiSelectModifier",comment:["- `ctrlCmd` refers to a value the setting can take and should not be localized.","- `Control` and `Command` refer to the modifier keys Ctrl or Cmd on the keyboard and can be localized."]},"The modifier to be used to add an item in trees and lists to a multi-selection with the mouse (for example in the explorer, open editors and scm view). The 'Open to Side' mouse gestures - if supported - will adapt such that they do not conflict with the multiselect modifier.")},[en]:{type:"string",enum:["singleClick","doubleClick"],default:"singleClick",description:(0,ue.kg)({key:"openModeModifier",comment:["`singleClick` and `doubleClick` refers to a value the setting can take and should not be localized."]},"Controls how to open items in trees and lists using the mouse (if supported). Note that some trees and lists might choose to ignore this setting if it is not applicable.")},[dn]:{type:"boolean",default:!1,description:(0,ue.kg)("horizontalScrolling setting","Controls whether lists and trees support horizontal scrolling in the workbench. Warning: turning on this setting has a performance implication.")},[In]:{type:"number",default:8,minimum:4,maximum:40,description:(0,ue.kg)("tree indent setting","Controls tree indentation in pixels.")},[xn]:{type:"string",enum:["none","onHover","always"],default:"onHover",description:(0,ue.kg)("render tree indent guides","Controls whether the tree should render indent guides.")},[Tn]:{type:"boolean",default:!1,description:(0,ue.kg)("list smoothScrolling setting","Controls whether lists and trees have smooth scrolling.")},[wn]:{type:"number",default:1,markdownDescription:(0,ue.kg)("Mouse Wheel Scroll Sensitivity","A multiplier to be used on the `deltaX` and `deltaY` of mouse wheel scroll events.")},[Ln]:{type:"number",default:5,description:(0,ue.kg)("Fast Scroll Sensitivity","Scrolling speed multiplier when pressing `Alt`.")},[Li]:{type:"string",enum:["highlight","filter"],enumDescriptions:[(0,ue.kg)("defaultFindModeSettingKey.highlight","Highlight elements when searching. Further up and down navigation will traverse only the highlighted elements."),(0,ue.kg)("defaultFindModeSettingKey.filter","Filter elements when searching.")],default:"highlight",description:(0,ue.kg)("defaultFindModeSettingKey","Controls the default find mode for lists and trees in the workbench.")},[Rn]:{type:"string",enum:["simple","highlight","filter"],enumDescriptions:[(0,ue.kg)("keyboardNavigationSettingKey.simple","Simple keyboard navigation focuses elements which match the keyboard input. Matching is done only on prefixes."),(0,ue.kg)("keyboardNavigationSettingKey.highlight","Highlight keyboard navigation highlights elements which match the keyboard input. Further up and down navigation will traverse only the highlighted elements."),(0,ue.kg)("keyboardNavigationSettingKey.filter","Filter keyboard navigation will filter out and hide all the elements which do not match the keyboard input.")],default:"highlight",description:(0,ue.kg)("keyboardNavigationSettingKey","Controls the keyboard navigation style for lists and trees in the workbench. Can be simple, highlight and filter."),deprecated:!0,deprecationMessage:(0,ue.kg)("keyboardNavigationSettingKeyDeprecated","Please use 'workbench.list.defaultFindMode' instead.")},[Cn]:{type:"string",enum:["singleClick","doubleClick"],default:"singleClick",description:(0,ue.kg)("expand mode","Controls how tree folders are expanded when clicking the folder names. Note that some trees and lists might choose to ignore this setting if it is not applicable.")}}})},4580:(rt,ye,y)=>{y.d(ye,{Q:()=>b});var b;(function(o){function K(P,B){if(P.start>=B.end||B.start>=P.end)return{start:0,end:0};const T=Math.max(P.start,B.start),p=Math.min(P.end,B.end);return p-T<=0?{start:0,end:0}:{start:T,end:p}}o.intersect=K;function $(P){return P.end-P.start<=0}o.isEmpty=$;function L(P,B){return!$(K(P,B))}o.intersects=L;function U(P,B){const T=[],p={start:P.start,end:Math.min(B.start,P.end)},d={start:Math.max(B.end,P.start),end:P.end};return $(p)||T.push(p),$(d)||T.push(d),T}o.relativeComplement=U})(b||(b={}))},4874:(rt,ye,y)=>{y.d(ye,{$$0:()=>oe,$BZ:()=>xn,$Qy:()=>Rn,AN$:()=>Ii,AjU:()=>Gn,AlL:()=>et,B2L:()=>Zi,BTi:()=>Nt,Bbc:()=>B,By2:()=>Xe,C1n:()=>ce,C9U:()=>Gi,CMg:()=>Ht,CQ3:()=>$n,CU6:()=>l,CgL:()=>Vt,D7X:()=>on,ECk:()=>oi,ELA:()=>St,EY1:()=>Pi,FEE:()=>Y,FdG:()=>T,FiB:()=>ni,GNm:()=>cn,GVV:()=>yn,G_h:()=>it,Gj6:()=>Sn,H8q:()=>I,HDX:()=>at,HJZ:()=>ve,HWC:()=>si,Hng:()=>Si,HwT:()=>wi,I$A:()=>E,IIb:()=>Et,ILr:()=>qs,JO0:()=>ri,JPj:()=>$o,JVY:()=>Ko,K1Z:()=>Vs,L4c:()=>H,L9Z:()=>Qe,MHP:()=>dn,NBf:()=>je,NXK:()=>Li,ObF:()=>gn,P6i:()=>yi,P9Z:()=>c,Q96:()=>ei,QI5:()=>Qt,QRv:()=>pt,Qfh:()=>At,QwA:()=>Gt,Rbi:()=>Ti,Rig:()=>jo,Rjz:()=>_n,S5J:()=>ki,S6W:()=>X,SNb:()=>Oi,Sj:()=>Pt,Stt:()=>yt,Syz:()=>Ut,T5N:()=>Me,T9h:()=>tt,U4U:()=>ae,ULt:()=>Se,UPX:()=>w,US:()=>Ri,Ubg:()=>Ue,Ux$:()=>ci,VFX:()=>Bn,WL6:()=>ti,WMx:()=>Ie,WfR:()=>mi,WmU:()=>Cn,XJc:()=>Wt,Xo2:()=>Tt,Xp1:()=>Xs,YSW:()=>Ke,YZM:()=>Tn,YtV:()=>Fe,ZEf:()=>fi,Zgs:()=>N,Ztu:()=>Fi,_$n:()=>pe,_NC:()=>ui,_pU:()=>Qi,b1q:()=>k,bNw:()=>Go,bXl:()=>dt,buw:()=>D,c1f:()=>te,c6Y:()=>_t,c7i:()=>Ze,cI_:()=>Mt,cws:()=>Z,dd_:()=>lt,eMz:()=>Di,eUu:()=>vt,eYZ:()=>ge,efJ:()=>Mn,er1:()=>Te,f4y:()=>zn,f9l:()=>R,fAP:()=>vs,fED:()=>On,fiM:()=>n,g$2:()=>ot,gnV:()=>bt,gtq:()=>Hn,h9z:()=>be,i61:()=>Ot,iAJ:()=>zt,ijf:()=>Nn,iwL:()=>nt,k5u:()=>de,lO1:()=>bi,ld8:()=>In,mH6:()=>Ci,mhZ:()=>Yt,nH:()=>He,n__:()=>Fn,oZ8:()=>qt,p7Y:()=>Yn,pOz:()=>ze,pmr:()=>Ft,pnl:()=>a,qTN:()=>qi,qaw:()=>wn,rB3:()=>_o,rRi:()=>Ni,rm4:()=>kt,sDQ:()=>fe,sIe:()=>vi,sbQ:()=>Ce,seu:()=>wt,sjA:()=>Vi,t4B:()=>m,tAP:()=>v,tYX:()=>vo,tan:()=>Ct,uMG:()=>Js,uNK:()=>G,uNx:()=>sn,vwp:()=>W,w3C:()=>Ln,w3w:()=>en,whs:()=>ut,x1A:()=>h,yHf:()=>Ji,yLC:()=>Ws,yLr:()=>io,yr0:()=>Ns,z5H:()=>Ms,zRE:()=>Ve,zUX:()=>It});var b=y(65958),o=y(94901),K=y(2106),$=y(79359),L=y(3765),U=y(51460),P=y(67167);function B(pi){return`--vscode-${pi.replace(/\./g,"-")}`}const T={ColorContribution:"base.contributions.colors"};class p{constructor(){this._onDidChangeSchema=new K.vl,this.onDidChangeSchema=this._onDidChangeSchema.event,this.colorSchema={type:"object",properties:{}},this.colorReferenceSchema={type:"string",enum:[],enumDescriptions:[]},this.colorsById={}}registerColor(zi,vn,xi,jn=!1,Wn){const Qn={id:zi,description:xi,defaults:vn,needsTransparency:jn,deprecationMessage:Wn};this.colorsById[zi]=Qn;const Rs={type:"string",description:xi,format:"color-hex",defaultSnippets:[{body:"${1:#ff0000}"}]};return Wn&&(Rs.deprecationMessage=Wn),this.colorSchema.properties[zi]=Rs,this.colorReferenceSchema.enum.push(zi),this.colorReferenceSchema.enumDescriptions.push(xi),this._onDidChangeSchema.fire(),zi}getColors(){return Object.keys(this.colorsById).map(zi=>this.colorsById[zi])}resolveDefaultColor(zi,vn){const xi=this.colorsById[zi];if(xi&&xi.defaults){const jn=xi.defaults[vn.type];return Fn(jn,vn)}}getColorSchema(){return this.colorSchema}toString(){const zi=(vn,xi)=>{const jn=vn.indexOf(".")===-1?0:1,Wn=xi.indexOf(".")===-1?0:1;return jn!==Wn?jn-Wn:vn.localeCompare(xi)};return Object.keys(this.colorsById).sort(zi).map(vn=>`- \`${vn}\`: ${this.colorsById[vn].description}`).join(` `)}}const d=new p;P.O.add(T.ColorContribution,d);function g(pi){return pi===null||typeof pi.hcLight>"u"&&(pi.hcDark===null||typeof pi.hcDark=="string"?pi.hcLight=pi.hcDark:pi.hcLight=pi.light),pi}function h(pi,zi,vn,xi,jn){return d.registerColor(pi,g(zi),vn,xi,jn)}const l=h("foreground",{dark:"#CCCCCC",light:"#616161",hcDark:"#FFFFFF",hcLight:"#292929"},L.kg("foreground","Overall foreground color. This color is only used if not overridden by a component.")),u=h("disabledForeground",{dark:"#CCCCCC80",light:"#61616180",hcDark:"#A5A5A5",hcLight:"#7F7F7F"},L.kg("disabledForeground","Overall foreground for disabled elements. This color is only used if not overridden by a component.")),w=h("errorForeground",{dark:"#F48771",light:"#A1260D",hcDark:"#F48771",hcLight:"#B5200D"},L.kg("errorForeground","Overall foreground color for error messages. This color is only used if not overridden by a component.")),C=h("descriptionForeground",{light:"#717171",dark:ri(l,.7),hcDark:ri(l,.7),hcLight:ri(l,.7)},L.kg("descriptionForeground","Foreground color for description text providing additional information, for example for a label.")),m=h("icon.foreground",{dark:"#C5C5C5",light:"#424242",hcDark:"#FFFFFF",hcLight:"#292929"},L.kg("iconForeground","The default color for icons in the workbench.")),v=h("focusBorder",{dark:"#007FD4",light:"#0090F1",hcDark:"#F38518",hcLight:"#0F4A85"},L.kg("focusBorder","Overall border color for focused elements. This color is only used if not overridden by a component.")),k=h("contrastBorder",{light:null,dark:null,hcDark:"#6FC3DF",hcLight:"#0F4A85"},L.kg("contrastBorder","An extra border around elements to separate them from others for greater contrast.")),D=h("contrastActiveBorder",{light:null,dark:null,hcDark:v,hcLight:v},L.kg("activeContrastBorder","An extra border around active elements to separate them from others for greater contrast.")),x=h("selection.background",{light:null,dark:null,hcDark:null,hcLight:null},L.kg("selectionBackground","The background color of text selections in the workbench (e.g. for input fields or text areas). Note that this does not apply to selections within the editor.")),A=h("textSeparator.foreground",{light:"#0000002e",dark:"#ffffff2e",hcDark:o.Q1.black,hcLight:"#292929"},L.kg("textSeparatorForeground","Color for text separators.")),W=h("textLink.foreground",{light:"#006AB1",dark:"#3794FF",hcDark:"#3794FF",hcLight:"#0F4A85"},L.kg("textLinkForeground","Foreground color for links in text.")),Y=h("textLink.activeForeground",{light:"#006AB1",dark:"#3794FF",hcDark:"#3794FF",hcLight:"#0F4A85"},L.kg("textLinkActiveForeground","Foreground color for links in text when clicked on and on mouse hover.")),ne=h("textPreformat.foreground",{light:"#A31515",dark:"#D7BA7D",hcDark:"#D7BA7D",hcLight:"#292929"},L.kg("textPreformatForeground","Foreground color for preformatted text segments.")),j=h("textBlockQuote.background",{light:"#7f7f7f1a",dark:"#7f7f7f1a",hcDark:null,hcLight:"#F2F2F2"},L.kg("textBlockQuoteBackground","Background color for block quotes in text.")),Q=h("textBlockQuote.border",{light:"#007acc80",dark:"#007acc80",hcDark:o.Q1.white,hcLight:"#292929"},L.kg("textBlockQuoteBorder","Border color for block quotes in text.")),X=h("textCodeBlock.background",{light:"#dcdcdc66",dark:"#0a0a0a66",hcDark:o.Q1.black,hcLight:"#F2F2F2"},L.kg("textCodeBlockBackground","Background color for code blocks in text.")),R=h("widget.shadow",{dark:ri(o.Q1.black,.36),light:ri(o.Q1.black,.16),hcDark:null,hcLight:null},L.kg("widgetShadow","Shadow color of widgets such as find/replace inside the editor.")),H=h("input.background",{dark:"#3C3C3C",light:o.Q1.white,hcDark:o.Q1.black,hcLight:o.Q1.white},L.kg("inputBoxBackground","Input box background.")),Z=h("input.foreground",{dark:l,light:l,hcDark:l,hcLight:l},L.kg("inputBoxForeground","Input box foreground.")),N=h("input.border",{dark:null,light:null,hcDark:k,hcLight:k},L.kg("inputBoxBorder","Input box border.")),G=h("inputOption.activeBorder",{dark:"#007ACC00",light:"#007ACC00",hcDark:k,hcLight:k},L.kg("inputBoxActiveOptionBorder","Border color of activated options in input fields.")),O=h("inputOption.hoverBackground",{dark:"#5a5d5e80",light:"#b8b8b850",hcDark:null,hcLight:null},L.kg("inputOption.hoverBackground","Background color of activated options in input fields.")),te=h("inputOption.activeBackground",{dark:ri(v,.4),light:ri(v,.2),hcDark:o.Q1.transparent,hcLight:o.Q1.transparent},L.kg("inputOption.activeBackground","Background hover color of options in input fields.")),oe=h("inputOption.activeForeground",{dark:o.Q1.white,light:o.Q1.black,hcDark:null,hcLight:l},L.kg("inputOption.activeForeground","Foreground color of activated options in input fields.")),ue=h("input.placeholderForeground",{light:ri(l,.5),dark:ri(l,.5),hcDark:ri(l,.7),hcLight:ri(l,.7)},L.kg("inputPlaceholderForeground","Input box foreground color for placeholder text.")),E=h("inputValidation.infoBackground",{dark:"#063B49",light:"#D6ECF2",hcDark:o.Q1.black,hcLight:o.Q1.white},L.kg("inputValidationInfoBackground","Input validation background color for information severity.")),Qe=h("inputValidation.infoForeground",{dark:null,light:null,hcDark:null,hcLight:l},L.kg("inputValidationInfoForeground","Input validation foreground color for information severity.")),Ke=h("inputValidation.infoBorder",{dark:"#007acc",light:"#007acc",hcDark:k,hcLight:k},L.kg("inputValidationInfoBorder","Input validation border color for information severity.")),Se=h("inputValidation.warningBackground",{dark:"#352A05",light:"#F6F5D2",hcDark:o.Q1.black,hcLight:o.Q1.white},L.kg("inputValidationWarningBackground","Input validation background color for warning severity.")),Me=h("inputValidation.warningForeground",{dark:null,light:null,hcDark:null,hcLight:l},L.kg("inputValidationWarningForeground","Input validation foreground color for warning severity.")),ce=h("inputValidation.warningBorder",{dark:"#B89500",light:"#B89500",hcDark:k,hcLight:k},L.kg("inputValidationWarningBorder","Input validation border color for warning severity.")),pe=h("inputValidation.errorBackground",{dark:"#5A1D1D",light:"#F2DEDE",hcDark:o.Q1.black,hcLight:o.Q1.white},L.kg("inputValidationErrorBackground","Input validation background color for error severity.")),be=h("inputValidation.errorForeground",{dark:null,light:null,hcDark:null,hcLight:l},L.kg("inputValidationErrorForeground","Input validation foreground color for error severity.")),ge=h("inputValidation.errorBorder",{dark:"#BE1100",light:"#BE1100",hcDark:k,hcLight:k},L.kg("inputValidationErrorBorder","Input validation border color for error severity.")),ke=h("dropdown.background",{dark:"#3C3C3C",light:o.Q1.white,hcDark:o.Q1.black,hcLight:o.Q1.white},L.kg("dropdownBackground","Dropdown background.")),We=h("dropdown.listBackground",{dark:null,light:null,hcDark:o.Q1.black,hcLight:o.Q1.white},L.kg("dropdownListBackground","Dropdown list background.")),Ge=h("dropdown.foreground",{dark:"#F0F0F0",light:null,hcDark:o.Q1.white,hcLight:l},L.kg("dropdownForeground","Dropdown foreground.")),Ae=h("dropdown.border",{dark:ke,light:"#CECECE",hcDark:k,hcLight:k},L.kg("dropdownBorder","Dropdown border.")),he=h("checkbox.background",{dark:ke,light:ke,hcDark:ke,hcLight:ke},L.kg("checkbox.background","Background color of checkbox widget.")),Pe=h("checkbox.foreground",{dark:Ge,light:Ge,hcDark:Ge,hcLight:Ge},L.kg("checkbox.foreground","Foreground color of checkbox widget.")),$e=h("checkbox.border",{dark:Ae,light:Ae,hcDark:Ae,hcLight:Ae},L.kg("checkbox.border","Border color of checkbox widget.")),it=h("button.foreground",{dark:o.Q1.white,light:o.Q1.white,hcDark:o.Q1.white,hcLight:o.Q1.white},L.kg("buttonForeground","Button foreground color.")),ft=h("button.separator",{dark:ri(it,.4),light:ri(it,.4),hcDark:ri(it,.4),hcLight:ri(it,.4)},L.kg("buttonSeparator","Button separator color.")),Wt=h("button.background",{dark:"#0E639C",light:"#007ACC",hcDark:null,hcLight:"#0F4A85"},L.kg("buttonBackground","Button background color.")),tt=h("button.hoverBackground",{dark:os(Wt,.2),light:Cs(Wt,.2),hcDark:null,hcLight:null},L.kg("buttonHoverBackground","Button background color when hovering.")),Ye=h("button.border",{dark:k,light:k,hcDark:k,hcLight:k},L.kg("buttonBorder","Button border color.")),ht=h("button.secondaryForeground",{dark:o.Q1.white,light:o.Q1.white,hcDark:o.Q1.white,hcLight:l},L.kg("buttonSecondaryForeground","Secondary button foreground color.")),Lt=h("button.secondaryBackground",{dark:"#3A3D41",light:"#5F6A79",hcDark:null,hcLight:o.Q1.white},L.kg("buttonSecondaryBackground","Secondary button background color.")),Rt=h("button.secondaryHoverBackground",{dark:os(Lt,.2),light:Cs(Lt,.2),hcDark:null,hcLight:null},L.kg("buttonSecondaryHoverBackground","Secondary button background color when hovering.")),Ie=h("badge.background",{dark:"#4D4D4D",light:"#C4C4C4",hcDark:o.Q1.black,hcLight:"#0F4A85"},L.kg("badgeBackground","Badge background color. Badges are small information labels, e.g. for search results count.")),Ve=h("badge.foreground",{dark:o.Q1.white,light:"#333",hcDark:o.Q1.white,hcLight:o.Q1.white},L.kg("badgeForeground","Badge foreground color. Badges are small information labels, e.g. for search results count.")),dt=h("scrollbar.shadow",{dark:"#000000",light:"#DDDDDD",hcDark:null,hcLight:null},L.kg("scrollbarShadow","Scrollbar shadow to indicate that the view is scrolled.")),bt=h("scrollbarSlider.background",{dark:o.Q1.fromHex("#797979").transparent(.4),light:o.Q1.fromHex("#646464").transparent(.4),hcDark:ri(k,.6),hcLight:ri(k,.4)},L.kg("scrollbarSliderBackground","Scrollbar slider background color.")),Mt=h("scrollbarSlider.hoverBackground",{dark:o.Q1.fromHex("#646464").transparent(.7),light:o.Q1.fromHex("#646464").transparent(.7),hcDark:ri(k,.8),hcLight:ri(k,.8)},L.kg("scrollbarSliderHoverBackground","Scrollbar slider background color when hovering.")),Yt=h("scrollbarSlider.activeBackground",{dark:o.Q1.fromHex("#BFBFBF").transparent(.4),light:o.Q1.fromHex("#000000").transparent(.6),hcDark:k,hcLight:k},L.kg("scrollbarSliderActiveBackground","Scrollbar slider background color when clicked on.")),Nt=h("progressBar.background",{dark:o.Q1.fromHex("#0E70C0"),light:o.Q1.fromHex("#0E70C0"),hcDark:k,hcLight:k},L.kg("progressBarBackground","Background color of the progress bar that can show for long running operations.")),Pt=h("editorError.background",{dark:null,light:null,hcDark:null,hcLight:null},L.kg("editorError.background","Background color of error text in the editor. The color must not be opaque so as not to hide underlying decorations."),!0),Ti=h("editorError.foreground",{dark:"#F14C4C",light:"#E51400",hcDark:"#F48771",hcLight:"#B5200D"},L.kg("editorError.foreground","Foreground color of error squigglies in the editor.")),Ii=h("editorError.border",{dark:null,light:null,hcDark:o.Q1.fromHex("#E47777").transparent(.8),hcLight:"#B5200D"},L.kg("errorBorder","Border color of error boxes in the editor.")),ut=h("editorWarning.background",{dark:null,light:null,hcDark:null,hcLight:null},L.kg("editorWarning.background","Background color of warning text in the editor. The color must not be opaque so as not to hide underlying decorations."),!0),Si=h("editorWarning.foreground",{dark:"#CCA700",light:"#BF8803",hcDark:"#FFD37",hcLight:"#895503"},L.kg("editorWarning.foreground","Foreground color of warning squigglies in the editor.")),yt=h("editorWarning.border",{dark:null,light:null,hcDark:o.Q1.fromHex("#FFCC00").transparent(.8),hcLight:"#"},L.kg("warningBorder","Border color of warning boxes in the editor.")),fe=h("editorInfo.background",{dark:null,light:null,hcDark:null,hcLight:null},L.kg("editorInfo.background","Background color of info text in the editor. The color must not be opaque so as not to hide underlying decorations."),!0),ze=h("editorInfo.foreground",{dark:"#3794FF",light:"#1a85ff",hcDark:"#3794FF",hcLight:"#1a85ff"},L.kg("editorInfo.foreground","Foreground color of info squigglies in the editor.")),Et=h("editorInfo.border",{dark:null,light:null,hcDark:o.Q1.fromHex("#3794FF").transparent(.8),hcLight:"#292929"},L.kg("infoBorder","Border color of info boxes in the editor.")),Ot=h("editorHint.foreground",{dark:o.Q1.fromHex("#eeeeee").transparent(.7),light:"#6c6c6c",hcDark:null,hcLight:null},L.kg("editorHint.foreground","Foreground color of hint squigglies in the editor.")),si=h("editorHint.border",{dark:null,light:null,hcDark:o.Q1.fromHex("#eeeeee").transparent(.8),hcLight:"#292929"},L.kg("hintBorder","Border color of hint boxes in the editor.")),_i=h("sash.hoverBorder",{dark:v,light:v,hcDark:v,hcLight:v},L.kg("sashActiveBorder","Border color of active sashes.")),Fe=h("editor.background",{light:"#ffffff",dark:"#1E1E1E",hcDark:o.Q1.black,hcLight:o.Q1.white},L.kg("editorBackground","Editor background color.")),Xe=h("editor.foreground",{light:"#333333",dark:"#BBBBBB",hcDark:o.Q1.white,hcLight:l},L.kg("editorForeground","Editor default foreground color.")),gt=h("editorStickyScroll.background",{light:Fe,dark:Fe,hcDark:Fe,hcLight:Fe},L.kg("editorStickyScrollBackground","Sticky scroll background color for the editor")),Xt=h("editorStickyScrollHover.background",{dark:"#2A2D2E",light:"#F0F0F0",hcDark:null,hcLight:o.Q1.fromHex("#0F4A85").transparent(.1)},L.kg("editorStickyScrollHoverBackground","Sticky scroll on hover background color for the editor")),Vt=h("editorWidget.background",{dark:"#252526",light:"#F3F3F3",hcDark:"#0C141F",hcLight:o.Q1.white},L.kg("editorWidgetBackground","Background color of editor widgets, such as find/replace.")),ni=h("editorWidget.foreground",{dark:l,light:l,hcDark:l,hcLight:l},L.kg("editorWidgetForeground","Foreground color of editor widgets, such as find/replace.")),vi=h("editorWidget.border",{dark:"#454545",light:"#C8C8C8",hcDark:k,hcLight:k},L.kg("editorWidgetBorder","Border color of editor widgets. The color is only used if the widget chooses to have a border and if the color is not overridden by a widget.")),Ri=h("editorWidget.resizeBorder",{light:null,dark:null,hcDark:null,hcLight:null},L.kg("editorWidgetResizeBorder","Border color of the resize bar of editor widgets. The color is only used if the widget chooses to have a resize border and if the color is not overridden by a widget.")),St=h("quickInput.background",{dark:Vt,light:Vt,hcDark:Vt,hcLight:Vt},L.kg("pickerBackground","Quick picker background color. The quick picker widget is the container for pickers like the command palette.")),ve=h("quickInput.foreground",{dark:ni,light:ni,hcDark:ni,hcLight:ni},L.kg("pickerForeground","Quick picker foreground color. The quick picker widget is the container for pickers like the command palette.")),Te=h("quickInputTitle.background",{dark:new o.Q1(new o.bU(255,255,255,.105)),light:new o.Q1(new o.bU(0,0,0,.06)),hcDark:"#000000",hcLight:o.Q1.white},L.kg("pickerTitleBackground","Quick picker title background color. The quick picker widget is the container for pickers like the command palette.")),je=h("pickerGroup.foreground",{dark:"#3794FF",light:"#0066BF",hcDark:o.Q1.white,hcLight:"#0F4A85"},L.kg("pickerGroupForeground","Quick picker color for grouping labels.")),nt=h("pickerGroup.border",{dark:"#3F3F46",light:"#CCCEDB",hcDark:o.Q1.white,hcLight:"#0F4A85"},L.kg("pickerGroupBorder","Quick picker color for grouping borders.")),at=h("keybindingLabel.background",{dark:new o.Q1(new o.bU(128,128,128,.17)),light:new o.Q1(new o.bU(221,221,221,.4)),hcDark:o.Q1.transparent,hcLight:o.Q1.transparent},L.kg("keybindingLabelBackground","Keybinding label background color. The keybinding label is used to represent a keyboard shortcut.")),vt=h("keybindingLabel.foreground",{dark:o.Q1.fromHex("#CCCCCC"),light:o.Q1.fromHex("#555555"),hcDark:o.Q1.white,hcLight:l},L.kg("keybindingLabelForeground","Keybinding label foreground color. The keybinding label is used to represent a keyboard shortcut.")),It=h("keybindingLabel.border",{dark:new o.Q1(new o.bU(51,51,51,.6)),light:new o.Q1(new o.bU(204,204,204,.4)),hcDark:new o.Q1(new o.bU(111,195,223)),hcLight:k},L.kg("keybindingLabelBorder","Keybinding label border color. The keybinding label is used to represent a keyboard shortcut.")),At=h("keybindingLabel.bottomBorder",{dark:new o.Q1(new o.bU(68,68,68,.6)),light:new o.Q1(new o.bU(187,187,187,.4)),hcDark:new o.Q1(new o.bU(111,195,223)),hcLight:l},L.kg("keybindingLabelBottomBorder","Keybinding label border bottom color. The keybinding label is used to represent a keyboard shortcut.")),wt=h("editor.selectionBackground",{light:"#ADD6FF",dark:"#264F78",hcDark:"#f3f518",hcLight:"#0F4A85"},L.kg("editorSelectionBackground","Color of the editor selection.")),kt=h("editor.selectionForeground",{light:null,dark:null,hcDark:"#000000",hcLight:o.Q1.white},L.kg("editorSelectionForeground","Color of the selected text for high contrast.")),Ct=h("editor.inactiveSelectionBackground",{light:ri(wt,.5),dark:ri(wt,.5),hcDark:ri(wt,.7),hcLight:ri(wt,.5)},L.kg("editorInactiveSelection","Color of the selection in an inactive editor. The color must not be opaque so as not to hide underlying decorations."),!0),Gt=h("editor.selectionHighlightBackground",{light:bs(wt,Fe,.3,.6),dark:bs(wt,Fe,.3,.6),hcDark:null,hcLight:null},L.kg("editorSelectionHighlight","Color for regions with the same content as the selection. The color must not be opaque so as not to hide underlying decorations."),!0),Ht=h("editor.selectionHighlightBorder",{light:null,dark:null,hcDark:D,hcLight:D},L.kg("editorSelectionHighlightBorder","Border color for regions with the same content as the selection.")),Ut=h("editor.findMatchBackground",{light:"#A8AC94",dark:"#515C6A",hcDark:null,hcLight:null},L.kg("editorFindMatch","Color of the current search match.")),Ue=h("editor.findMatchHighlightBackground",{light:"#EA5C0055",dark:"#EA5C0055",hcDark:null,hcLight:null},L.kg("findMatchHighlight","Color of the other search matches. The color must not be opaque so as not to hide underlying decorations."),!0),ei=h("editor.findRangeHighlightBackground",{dark:"#3a3d4166",light:"#b4b4b44d",hcDark:null,hcLight:null},L.kg("findRangeHighlight","Color of the range limiting the search. The color must not be opaque so as not to hide underlying decorations."),!0),ui=h("editor.findMatchBorder",{light:null,dark:null,hcDark:D,hcLight:D},L.kg("editorFindMatchBorder","Border color of the current search match.")),oi=h("editor.findMatchHighlightBorder",{light:null,dark:null,hcDark:D,hcLight:D},L.kg("findMatchHighlightBorder","Border color of the other search matches.")),ki=h("editor.findRangeHighlightBorder",{dark:null,light:null,hcDark:ri(D,.4),hcLight:ri(D,.4)},L.kg("findRangeHighlightBorder","Border color of the range limiting the search. The color must not be opaque so as not to hide underlying decorations."),!0),Kt=h("searchEditor.findMatchBackground",{light:ri(Ue,.66),dark:ri(Ue,.66),hcDark:Ue,hcLight:Ue},L.kg("searchEditor.queryMatch","Color of the Search Editor query matches.")),li=h("searchEditor.findMatchBorder",{light:ri(oi,.66),dark:ri(oi,.66),hcDark:oi,hcLight:oi},L.kg("searchEditor.editorFindMatchBorder","Border color of the Search Editor query matches.")),Ci=h("editor.hoverHighlightBackground",{light:"#ADD6FF26",dark:"#264f7840",hcDark:"#ADD6FF26",hcLight:null},L.kg("hoverHighlight","Highlight below the word for which a hover is shown. The color must not be opaque so as not to hide underlying decorations."),!0),mi=h("editorHoverWidget.background",{light:Vt,dark:Vt,hcDark:Vt,hcLight:Vt},L.kg("hoverBackground","Background color of the editor hover.")),Tt=h("editorHoverWidget.foreground",{light:ni,dark:ni,hcDark:ni,hcLight:ni},L.kg("hoverForeground","Foreground color of the editor hover.")),qt=h("editorHoverWidget.border",{light:vi,dark:vi,hcDark:vi,hcLight:vi},L.kg("hoverBorder","Border color of the editor hover.")),Ni=h("editorHoverWidget.statusBarBackground",{dark:os(mi,.2),light:Cs(mi,.05),hcDark:Vt,hcLight:Vt},L.kg("statusBarBackground","Background color of the editor hover status bar.")),Fi=h("editorLink.activeForeground",{dark:"#4E94CE",light:o.Q1.blue,hcDark:o.Q1.cyan,hcLight:"#292929"},L.kg("activeLinkForeground","Color of active links.")),yi=h("editorInlayHint.foreground",{dark:ri(Ve,.8),light:ri(Ve,.8),hcDark:Ve,hcLight:Ve},L.kg("editorInlayHintForeground","Foreground color of inline hints")),ti=h("editorInlayHint.background",{dark:ri(Ie,.6),light:ri(Ie,.3),hcDark:Ie,hcLight:Ie},L.kg("editorInlayHintBackground","Background color of inline hints")),wi=h("editorInlayHint.typeForeground",{dark:yi,light:yi,hcDark:yi,hcLight:yi},L.kg("editorInlayHintForegroundTypes","Foreground color of inline hints for types")),Qi=h("editorInlayHint.typeBackground",{dark:ti,light:ti,hcDark:ti,hcLight:ti},L.kg("editorInlayHintBackgroundTypes","Background color of inline hints for types")),Vi=h("editorInlayHint.parameterForeground",{dark:yi,light:yi,hcDark:yi,hcLight:yi},L.kg("editorInlayHintForegroundParameter","Foreground color of inline hints for parameters")),Zi=h("editorInlayHint.parameterBackground",{dark:ti,light:ti,hcDark:ti,hcLight:ti},L.kg("editorInlayHintBackgroundParameter","Background color of inline hints for parameters")),Ji=h("editorLightBulb.foreground",{dark:"#FFCC00",light:"#DDB100",hcDark:"#FFCC00",hcLight:"#007ACC"},L.kg("editorLightBulbForeground","The color used for the lightbulb actions icon.")),qi=h("editorLightBulbAutoFix.foreground",{dark:"#75BEFF",light:"#007ACC",hcDark:"#75BEFF",hcLight:"#007ACC"},L.kg("editorLightBulbAutoFixForeground","The color used for the lightbulb auto fix actions icon.")),Pi=new o.Q1(new o.bU(155,185,85,.2)),fi=new o.Q1(new o.bU(255,0,0,.2)),Sn=h("diffEditor.insertedTextBackground",{dark:"#9ccc2c33",light:"#9ccc2c66",hcDark:null,hcLight:null},L.kg("diffEditorInserted","Background color for text that got inserted. The color must not be opaque so as not to hide underlying decorations."),!0),cn=h("diffEditor.removedTextBackground",{dark:"#ff000066",light:"#ff00004d",hcDark:null,hcLight:null},L.kg("diffEditorRemoved","Background color for text that got removed. The color must not be opaque so as not to hide underlying decorations."),!0),en=h("diffEditor.insertedLineBackground",{dark:Pi,light:Pi,hcDark:null,hcLight:null},L.kg("diffEditorInsertedLines","Background color for lines that got inserted. The color must not be opaque so as not to hide underlying decorations."),!0),dn=h("diffEditor.removedLineBackground",{dark:fi,light:fi,hcDark:null,hcLight:null},L.kg("diffEditorRemovedLines","Background color for lines that got removed. The color must not be opaque so as not to hide underlying decorations."),!0),Li=h("diffEditorGutter.insertedLineBackground",{dark:null,light:null,hcDark:null,hcLight:null},L.kg("diffEditorInsertedLineGutter","Background color for the margin where lines got inserted.")),Rn=h("diffEditorGutter.removedLineBackground",{dark:null,light:null,hcDark:null,hcLight:null},L.kg("diffEditorRemovedLineGutter","Background color for the margin where lines got removed.")),In=h("diffEditorOverview.insertedForeground",{dark:null,light:null,hcDark:null,hcLight:null},L.kg("diffEditorOverviewInserted","Diff overview ruler foreground for inserted content.")),xn=h("diffEditorOverview.removedForeground",{dark:null,light:null,hcDark:null,hcLight:null},L.kg("diffEditorOverviewRemoved","Diff overview ruler foreground for removed content.")),Tn=h("diffEditor.insertedTextBorder",{dark:null,light:null,hcDark:"#33ff2eff",hcLight:"#374E06"},L.kg("diffEditorInsertedOutline","Outline color for the text that got inserted.")),wn=h("diffEditor.removedTextBorder",{dark:null,light:null,hcDark:"#FF008F",hcLight:"#AD0707"},L.kg("diffEditorRemovedOutline","Outline color for text that got removed.")),Ln=h("diffEditor.border",{dark:null,light:null,hcDark:k,hcLight:k},L.kg("diffEditorBorder","Border color between the two text editors.")),Cn=h("diffEditor.diagonalFill",{dark:"#cccccc33",light:"#22222233",hcDark:null,hcLight:null},L.kg("diffDiagonalFill","Color of the diff editor's diagonal fill. The diagonal fill is used in side-by-side diff views.")),Bn=h("list.focusBackground",{dark:null,light:null,hcDark:null,hcLight:null},L.kg("listFocusBackground","List/Tree background color for the focused item when the list/tree is active. An active list/tree has keyboard focus, an inactive does not.")),Mn=h("list.focusForeground",{dark:null,light:null,hcDark:null,hcLight:null},L.kg("listFocusForeground","List/Tree foreground color for the focused item when the list/tree is active. An active list/tree has keyboard focus, an inactive does not.")),Yn=h("list.focusOutline",{dark:v,light:v,hcDark:D,hcLight:D},L.kg("listFocusOutline","List/Tree outline color for the focused item when the list/tree is active. An active list/tree has keyboard focus, an inactive does not.")),Hn=h("list.focusAndSelectionOutline",{dark:null,light:null,hcDark:null,hcLight:null},L.kg("listFocusAndSelectionOutline","List/Tree outline color for the focused item when the list/tree is active and selected. An active list/tree has keyboard focus, an inactive does not.")),_n=h("list.activeSelectionBackground",{dark:"#04395E",light:"#0060C0",hcDark:null,hcLight:o.Q1.fromHex("#0F4A85").transparent(.1)},L.kg("listActiveSelectionBackground","List/Tree background color for the selected item when the list/tree is active. An active list/tree has keyboard focus, an inactive does not.")),yn=h("list.activeSelectionForeground",{dark:o.Q1.white,light:o.Q1.white,hcDark:null,hcLight:null},L.kg("listActiveSelectionForeground","List/Tree foreground color for the selected item when the list/tree is active. An active list/tree has keyboard focus, an inactive does not.")),On=h("list.activeSelectionIconForeground",{dark:null,light:null,hcDark:null,hcLight:null},L.kg("listActiveSelectionIconForeground","List/Tree icon foreground color for the selected item when the list/tree is active. An active list/tree has keyboard focus, an inactive does not.")),sn=h("list.inactiveSelectionBackground",{dark:"#37373D",light:"#E4E6F1",hcDark:null,hcLight:o.Q1.fromHex("#0F4A85").transparent(.1)},L.kg("listInactiveSelectionBackground","List/Tree background color for the selected item when the list/tree is inactive. An active list/tree has keyboard focus, an inactive does not.")),zn=h("list.inactiveSelectionForeground",{dark:null,light:null,hcDark:null,hcLight:null},L.kg("listInactiveSelectionForeground","List/Tree foreground color for the selected item when the list/tree is inactive. An active list/tree has keyboard focus, an inactive does not.")),Gi=h("list.inactiveSelectionIconForeground",{dark:null,light:null,hcDark:null,hcLight:null},L.kg("listInactiveSelectionIconForeground","List/Tree icon foreground color for the selected item when the list/tree is inactive. An active list/tree has keyboard focus, an inactive does not.")),$n=h("list.inactiveFocusBackground",{dark:null,light:null,hcDark:null,hcLight:null},L.kg("listInactiveFocusBackground","List/Tree background color for the focused item when the list/tree is inactive. An active list/tree has keyboard focus, an inactive does not.")),Nn=h("list.inactiveFocusOutline",{dark:null,light:null,hcDark:null,hcLight:null},L.kg("listInactiveFocusOutline","List/Tree outline color for the focused item when the list/tree is inactive. An active list/tree has keyboard focus, an inactive does not.")),bi=h("list.hoverBackground",{dark:"#2A2D2E",light:"#F0F0F0",hcDark:null,hcLight:o.Q1.fromHex("#0F4A85").transparent(.1)},L.kg("listHoverBackground","List/Tree background when hovering over items using the mouse.")),pt=h("list.hoverForeground",{dark:null,light:null,hcDark:null,hcLight:null},L.kg("listHoverForeground","List/Tree foreground when hovering over items using the mouse.")),zt=h("list.dropBackground",{dark:"#062F4A",light:"#D6EBFF",hcDark:null,hcLight:null},L.kg("listDropBackground","List/Tree drag and drop background when moving items around using the mouse.")),Qt=h("list.highlightForeground",{dark:"#2AAAFF",light:"#0066BF",hcDark:v,hcLight:v},L.kg("highlight","List/Tree foreground color of the match highlights when searching inside the list/tree.")),Di=h("list.focusHighlightForeground",{dark:Qt,light:bo(_n,Qt,"#BBE7FF"),hcDark:Qt,hcLight:Qt},L.kg("listFocusHighlightForeground","List/Tree foreground color of the match highlights on actively focused items when searching inside the list/tree.")),Ui=h("list.invalidItemForeground",{dark:"#B89500",light:"#B89500",hcDark:"#B89500",hcLight:"#B5200D"},L.kg("invalidItemForeground","List/Tree foreground color for invalid items, for example an unresolved root in explorer.")),Wi=h("list.errorForeground",{dark:"#F88070",light:"#B01011",hcDark:null,hcLight:null},L.kg("listErrorForeground","Foreground color of list items containing errors.")),xe=h("list.warningForeground",{dark:"#CCA700",light:"#855F00",hcDark:null,hcLight:null},L.kg("listWarningForeground","Foreground color of list items containing warnings.")),a=h("listFilterWidget.background",{light:Cs(Vt,0),dark:os(Vt,0),hcDark:Vt,hcLight:Vt},L.kg("listFilterWidgetBackground","Background color of the type filter widget in lists and trees.")),n=h("listFilterWidget.outline",{dark:o.Q1.transparent,light:o.Q1.transparent,hcDark:"#f38518",hcLight:"#007ACC"},L.kg("listFilterWidgetOutline","Outline color of the type filter widget in lists and trees.")),c=h("listFilterWidget.noMatchesOutline",{dark:"#BE1100",light:"#BE1100",hcDark:k,hcLight:k},L.kg("listFilterWidgetNoMatchesOutline","Outline color of the type filter widget in lists and trees, when there are no matches.")),I=h("listFilterWidget.shadow",{dark:R,light:R,hcDark:R,hcLight:R},L.kg("listFilterWidgetShadow","Shadown color of the type filter widget in lists and trees.")),F=h("list.filterMatchBackground",{dark:Ue,light:Ue,hcDark:null,hcLight:null},L.kg("listFilterMatchHighlight","Background color of the filtered match.")),J=h("list.filterMatchBorder",{dark:oi,light:oi,hcDark:k,hcLight:D},L.kg("listFilterMatchHighlightBorder","Border color of the filtered match.")),ae=h("tree.indentGuidesStroke",{dark:"#585858",light:"#a9a9a9",hcDark:"#a9a9a9",hcLight:"#a5a5a5"},L.kg("treeIndentGuidesStroke","Tree stroke color for the indentation guides.")),de=h("tree.tableColumnsBorder",{dark:"#CCCCCC20",light:"#61616120",hcDark:null,hcLight:null},L.kg("tableColumnsBorder","Table border color between columns.")),Ce=h("tree.tableOddRowsBackground",{dark:ri(l,.04),light:ri(l,.04),hcDark:null,hcLight:null},L.kg("tableOddRowsBackgroundColor","Background color for odd table rows.")),Ee=h("list.deemphasizedForeground",{dark:"#8C8C8C",light:"#8E8E90",hcDark:"#A7A8A9",hcLight:"#666666"},L.kg("listDeemphasizedForeground","List/Tree foreground color for items that are deemphasized. ")),Ne=h("quickInput.list.focusBackground",{dark:null,light:null,hcDark:null,hcLight:null},"",void 0,L.kg("quickInput.list.focusBackground deprecation","Please use quickInputList.focusBackground instead")),He=h("quickInputList.focusForeground",{dark:yn,light:yn,hcDark:yn,hcLight:yn},L.kg("quickInput.listFocusForeground","Quick picker foreground color for the focused item.")),Ze=h("quickInputList.focusIconForeground",{dark:On,light:On,hcDark:On,hcLight:On},L.kg("quickInput.listFocusIconForeground","Quick picker icon foreground color for the focused item.")),et=h("quickInputList.focusBackground",{dark:io(Ne,_n),light:io(Ne,_n),hcDark:null,hcLight:null},L.kg("quickInput.listFocusBackground","Quick picker background color for the focused item.")),ot=h("menu.border",{dark:null,light:null,hcDark:k,hcLight:k},L.kg("menuBorder","Border color of menus.")),lt=h("menu.foreground",{dark:Ge,light:l,hcDark:Ge,hcLight:Ge},L.kg("menuForeground","Foreground color of menu items.")),_t=h("menu.background",{dark:ke,light:ke,hcDark:ke,hcLight:ke},L.kg("menuBackground","Background color of menu items.")),Ft=h("menu.selectionForeground",{dark:yn,light:yn,hcDark:yn,hcLight:yn},L.kg("menuSelectionForeground","Foreground color of the selected menu item in menus.")),ci=h("menu.selectionBackground",{dark:_n,light:_n,hcDark:_n,hcLight:_n},L.kg("menuSelectionBackground","Background color of the selected menu item in menus.")),Oi=h("menu.selectionBorder",{dark:null,light:null,hcDark:D,hcLight:D},L.kg("menuSelectionBorder","Border color of the selected menu item in menus.")),on=h("menu.separatorBackground",{dark:"#606060",light:"#D4D4D4",hcDark:k,hcLight:k},L.kg("menuSeparatorBackground","Color of a separator menu item in menus.")),gn=h("toolbar.hoverBackground",{dark:"#5a5d5e50",light:"#b8b8b850",hcDark:null,hcLight:null},L.kg("toolbarHoverBackground","Toolbar background when hovering over actions using the mouse")),hn=h("toolbar.hoverOutline",{dark:null,light:null,hcDark:D,hcLight:D},L.kg("toolbarHoverOutline","Toolbar outline when hovering over actions using the mouse")),Yi=h("toolbar.activeBackground",{dark:os(gn,.1),light:Cs(gn,.1),hcDark:null,hcLight:null},L.kg("toolbarActiveBackground","Toolbar background when holding the mouse over actions")),Ei=h("editor.snippetTabstopHighlightBackground",{dark:new o.Q1(new o.bU(124,124,124,.3)),light:new o.Q1(new o.bU(10,50,100,.2)),hcDark:new o.Q1(new o.bU(124,124,124,.3)),hcLight:new o.Q1(new o.bU(10,50,100,.2))},L.kg("snippetTabstopHighlightBackground","Highlight background color of a snippet tabstop.")),An=h("editor.snippetTabstopHighlightBorder",{dark:null,light:null,hcDark:null,hcLight:null},L.kg("snippetTabstopHighlightBorder","Highlight border color of a snippet tabstop.")),Xn=h("editor.snippetFinalTabstopHighlightBackground",{dark:null,light:null,hcDark:null,hcLight:null},L.kg("snippetFinalTabstopHighlightBackground","Highlight background color of the final tabstop of a snippet.")),rs=h("editor.snippetFinalTabstopHighlightBorder",{dark:"#525252",light:new o.Q1(new o.bU(10,50,100,.5)),hcDark:"#525252",hcLight:"#292929"},L.kg("snippetFinalTabstopHighlightBorder","Highlight border color of the final tabstop of a snippet.")),is=h("breadcrumb.foreground",{light:ri(l,.8),dark:ri(l,.8),hcDark:ri(l,.8),hcLight:ri(l,.8)},L.kg("breadcrumbsFocusForeground","Color of focused breadcrumb items.")),xs=h("breadcrumb.background",{light:Fe,dark:Fe,hcDark:Fe,hcLight:Fe},L.kg("breadcrumbsBackground","Background color of breadcrumb items.")),ys=h("breadcrumb.focusForeground",{light:Cs(l,.2),dark:os(l,.1),hcDark:os(l,.1),hcLight:os(l,.1)},L.kg("breadcrumbsFocusForeground","Color of focused breadcrumb items.")),Ss=h("breadcrumb.activeSelectionForeground",{light:Cs(l,.2),dark:os(l,.1),hcDark:os(l,.1),hcLight:os(l,.1)},L.kg("breadcrumbsSelectedForeground","Color of selected breadcrumb items.")),Fs=h("breadcrumbPicker.background",{light:Vt,dark:Vt,hcDark:Vt,hcLight:Vt},L.kg("breadcrumbsSelectedBackground","Background color of breadcrumb item picker.")),ns=.5,Zs=o.Q1.fromHex("#40C8AE").transparent(ns),Ts=o.Q1.fromHex("#40A6FF").transparent(ns),Ys=o.Q1.fromHex("#606060").transparent(.4),Un=.4,rn=1,hs=h("merge.currentHeaderBackground",{dark:Zs,light:Zs,hcDark:null,hcLight:null},L.kg("mergeCurrentHeaderBackground","Current header background in inline merge-conflicts. The color must not be opaque so as not to hide underlying decorations."),!0),po=h("merge.currentContentBackground",{dark:ri(hs,Un),light:ri(hs,Un),hcDark:ri(hs,Un),hcLight:ri(hs,Un)},L.kg("mergeCurrentContentBackground","Current content background in inline merge-conflicts. The color must not be opaque so as not to hide underlying decorations."),!0),gs=h("merge.incomingHeaderBackground",{dark:Ts,light:Ts,hcDark:null,hcLight:null},L.kg("mergeIncomingHeaderBackground","Incoming header background in inline merge-conflicts. The color must not be opaque so as not to hide underlying decorations."),!0),Uo=h("merge.incomingContentBackground",{dark:ri(gs,Un),light:ri(gs,Un),hcDark:ri(gs,Un),hcLight:ri(gs,Un)},L.kg("mergeIncomingContentBackground","Incoming content background in inline merge-conflicts. The color must not be opaque so as not to hide underlying decorations."),!0),es=h("merge.commonHeaderBackground",{dark:Ys,light:Ys,hcDark:null,hcLight:null},L.kg("mergeCommonHeaderBackground","Common ancestor header background in inline merge-conflicts. The color must not be opaque so as not to hide underlying decorations."),!0),us=h("merge.commonContentBackground",{dark:ri(es,Un),light:ri(es,Un),hcDark:ri(es,Un),hcLight:ri(es,Un)},L.kg("mergeCommonContentBackground","Common ancestor content background in inline merge-conflicts. The color must not be opaque so as not to hide underlying decorations."),!0),Ls=h("merge.border",{dark:null,light:null,hcDark:"#C3DF6F",hcLight:"#007ACC"},L.kg("mergeBorder","Border color on headers and the splitter in inline merge-conflicts.")),_r=h("editorOverviewRuler.currentContentForeground",{dark:ri(hs,rn),light:ri(hs,rn),hcDark:Ls,hcLight:Ls},L.kg("overviewRulerCurrentContentForeground","Current overview ruler foreground for inline merge-conflicts.")),vr=h("editorOverviewRuler.incomingContentForeground",{dark:ri(gs,rn),light:ri(gs,rn),hcDark:Ls,hcLight:Ls},L.kg("overviewRulerIncomingContentForeground","Incoming overview ruler foreground for inline merge-conflicts.")),Cr=h("editorOverviewRuler.commonContentForeground",{dark:ri(es,rn),light:ri(es,rn),hcDark:Ls,hcLight:Ls},L.kg("overviewRulerCommonContentForeground","Common ancestor overview ruler foreground for inline merge-conflicts.")),vs=h("editorOverviewRuler.findMatchForeground",{dark:"#d186167e",light:"#d186167e",hcDark:"#AB5A00",hcLight:""},L.kg("overviewRulerFindMatchForeground","Overview ruler marker color for find matches. The color must not be opaque so as not to hide underlying decorations."),!0),Ms=h("editorOverviewRuler.selectionHighlightForeground",{dark:"#A0A0A0CC",light:"#A0A0A0CC",hcDark:"#A0A0A0CC",hcLight:"#A0A0A0CC"},L.kg("overviewRulerSelectionHighlightForeground","Overview ruler marker color for selection highlights. The color must not be opaque so as not to hide underlying decorations."),!0),Gn=h("minimap.findMatchHighlight",{light:"#d18616",dark:"#d18616",hcDark:"#AB5A00",hcLight:"#0F4A85"},L.kg("minimapFindMatchHighlight","Minimap marker color for find matches."),!0),Xs=h("minimap.selectionOccurrenceHighlight",{light:"#c9c9c9",dark:"#676767",hcDark:"#ffffff",hcLight:"#0F4A85"},L.kg("minimapSelectionOccurrenceHighlight","Minimap marker color for repeating editor selections."),!0),Ns=h("minimap.selectionHighlight",{light:"#ADD6FF",dark:"#264F78",hcDark:"#ffffff",hcLight:"#0F4A85"},L.kg("minimapSelectionHighlight","Minimap marker color for the editor selection."),!0),Ws=h("minimap.errorHighlight",{dark:new o.Q1(new o.bU(255,18,18,.7)),light:new o.Q1(new o.bU(255,18,18,.7)),hcDark:new o.Q1(new o.bU(255,50,50,1)),hcLight:"#B5200D"},L.kg("minimapError","Minimap marker color for errors.")),Js=h("minimap.warningHighlight",{dark:Si,light:Si,hcDark:yt,hcLight:yt},L.kg("overviewRuleWarning","Minimap marker color for warnings.")),qs=h("minimap.background",{dark:null,light:null,hcDark:null,hcLight:null},L.kg("minimapBackground","Minimap background color.")),Vs=h("minimap.foregroundOpacity",{dark:o.Q1.fromHex("#000f"),light:o.Q1.fromHex("#000f"),hcDark:o.Q1.fromHex("#000f"),hcLight:o.Q1.fromHex("#000f")},L.kg("minimapForegroundOpacity",'Opacity of foreground elements rendered in the minimap. For example, "#000000c0" will render the elements with 75% opacity.')),_o=h("minimapSlider.background",{light:ri(bt,.5),dark:ri(bt,.5),hcDark:ri(bt,.5),hcLight:ri(bt,.5)},L.kg("minimapSliderBackground","Minimap slider background color.")),jo=h("minimapSlider.hoverBackground",{light:ri(Mt,.5),dark:ri(Mt,.5),hcDark:ri(Mt,.5),hcLight:ri(Mt,.5)},L.kg("minimapSliderHoverBackground","Minimap slider background color when hovering.")),Ko=h("minimapSlider.activeBackground",{light:ri(Yt,.5),dark:ri(Yt,.5),hcDark:ri(Yt,.5),hcLight:ri(Yt,.5)},L.kg("minimapSliderActiveBackground","Minimap slider background color when clicked on.")),vo=h("problemsErrorIcon.foreground",{dark:Ti,light:Ti,hcDark:Ti,hcLight:Ti},L.kg("problemsErrorIconForeground","The color used for the problems error icon.")),$o=h("problemsWarningIcon.foreground",{dark:Si,light:Si,hcDark:Si,hcLight:Si},L.kg("problemsWarningIconForeground","The color used for the problems warning icon.")),Go=h("problemsInfoIcon.foreground",{dark:ze,light:ze,hcDark:ze,hcLight:ze},L.kg("problemsInfoIconForeground","The color used for the problems info icon.")),br=h("charts.foreground",{dark:l,light:l,hcDark:l,hcLight:l},L.kg("chartsForeground","The foreground color used in charts.")),eo=h("charts.lines",{dark:ri(l,.5),light:ri(l,.5),hcDark:ri(l,.5),hcLight:ri(l,.5)},L.kg("chartsLines","The color used for horizontal lines in charts.")),Es=h("charts.red",{dark:Ti,light:Ti,hcDark:Ti,hcLight:Ti},L.kg("chartsRed","The red color used in chart visualizations.")),ss=h("charts.blue",{dark:ze,light:ze,hcDark:ze,hcLight:ze},L.kg("chartsBlue","The blue color used in chart visualizations.")),Ps=h("charts.yellow",{dark:Si,light:Si,hcDark:Si,hcLight:Si},L.kg("chartsYellow","The yellow color used in chart visualizations.")),Co=h("charts.orange",{dark:Gn,light:Gn,hcDark:Gn,hcLight:Gn},L.kg("chartsOrange","The orange color used in chart visualizations.")),Hs=h("charts.green",{dark:"#89D185",light:"#388A34",hcDark:"#89D185",hcLight:"#374e06"},L.kg("chartsGreen","The green color used in chart visualizations.")),to=h("charts.purple",{dark:"#B180D7",light:"#652D90",hcDark:"#B180D7",hcLight:"#652D90"},L.kg("chartsPurple","The purple color used in chart visualizations."));function Qo(pi,zi){var vn,xi,jn;switch(pi.op){case 0:return(vn=Fn(pi.value,zi))===null||vn===void 0?void 0:vn.darken(pi.factor);case 1:return(xi=Fn(pi.value,zi))===null||xi===void 0?void 0:xi.lighten(pi.factor);case 2:return(jn=Fn(pi.value,zi))===null||jn===void 0?void 0:jn.transparent(pi.factor);case 3:for(const Wn of pi.values){const Qn=Fn(Wn,zi);if(Qn)return Qn}return;case 5:return Fn(zi.defines(pi.if)?pi.then:pi.else,zi);case 4:{const Wn=Fn(pi.value,zi);if(!Wn)return;const Qn=Fn(pi.background,zi);return Qn?Wn.isDarkerThan(Qn)?o.Q1.getLighterColor(Wn,Qn,pi.factor).transparent(pi.transparency):o.Q1.getDarkerColor(Wn,Qn,pi.factor).transparent(pi.transparency):Wn.transparent(pi.factor*pi.transparency)}default:throw(0,$.xb)(pi)}}function Cs(pi,zi){return{op:0,value:pi,factor:zi}}function os(pi,zi){return{op:1,value:pi,factor:zi}}function ri(pi,zi){return{op:2,value:pi,factor:zi}}function io(...pi){return{op:3,values:pi}}function bo(pi,zi,vn){return{op:5,if:pi,then:zi,else:vn}}function bs(pi,zi,vn,xi){return{op:4,value:pi,background:zi,factor:vn,transparency:xi}}function Fn(pi,zi){if(pi!==null){if(typeof pi=="string")return pi[0]==="#"?o.Q1.fromHex(pi):zi.getColor(pi);if(pi instanceof o.Q1)return pi;if(typeof pi=="object")return Qo(pi,zi)}}const Os="vscode://schemas/workbench-colors",As=P.O.as(U.F.JSONContribution);As.registerSchema(Os,d.getColorSchema());const no=new b.uC(()=>As.notifySchemaChanged(Os),200);d.onDidChangeSchema(()=>{no.isScheduled()||no.schedule()})},5043:(rt,ye,y)=>{y.d(ye,{D:()=>b,Z:()=>K});class b{constructor(L){this.domNode=L,this._maxWidth="",this._width="",this._height="",this._top="",this._left="",this._bottom="",this._right="",this._fontFamily="",this._fontWeight="",this._fontSize="",this._fontStyle="",this._fontFeatureSettings="",this._textDecoration="",this._lineHeight="",this._letterSpacing="",this._className="",this._display="",this._position="",this._visibility="",this._color="",this._backgroundColor="",this._layerHint=!1,this._contain="none",this._boxShadow=""}setMaxWidth(L){const U=o(L);this._maxWidth!==U&&(this._maxWidth=U,this.domNode.style.maxWidth=this._maxWidth)}setWidth(L){const U=o(L);this._width!==U&&(this._width=U,this.domNode.style.width=this._width)}setHeight(L){const U=o(L);this._height!==U&&(this._height=U,this.domNode.style.height=this._height)}setTop(L){const U=o(L);this._top!==U&&(this._top=U,this.domNode.style.top=this._top)}setLeft(L){const U=o(L);this._left!==U&&(this._left=U,this.domNode.style.left=this._left)}setBottom(L){const U=o(L);this._bottom!==U&&(this._bottom=U,this.domNode.style.bottom=this._bottom)}setRight(L){const U=o(L);this._right!==U&&(this._right=U,this.domNode.style.right=this._right)}setFontFamily(L){this._fontFamily!==L&&(this._fontFamily=L,this.domNode.style.fontFamily=this._fontFamily)}setFontWeight(L){this._fontWeight!==L&&(this._fontWeight=L,this.domNode.style.fontWeight=this._fontWeight)}setFontSize(L){const U=o(L);this._fontSize!==U&&(this._fontSize=U,this.domNode.style.fontSize=this._fontSize)}setFontStyle(L){this._fontStyle!==L&&(this._fontStyle=L,this.domNode.style.fontStyle=this._fontStyle)}setFontFeatureSettings(L){this._fontFeatureSettings!==L&&(this._fontFeatureSettings=L,this.domNode.style.fontFeatureSettings=this._fontFeatureSettings)}setTextDecoration(L){this._textDecoration!==L&&(this._textDecoration=L,this.domNode.style.textDecoration=this._textDecoration)}setLineHeight(L){const U=o(L);this._lineHeight!==U&&(this._lineHeight=U,this.domNode.style.lineHeight=this._lineHeight)}setLetterSpacing(L){const U=o(L);this._letterSpacing!==U&&(this._letterSpacing=U,this.domNode.style.letterSpacing=this._letterSpacing)}setClassName(L){this._className!==L&&(this._className=L,this.domNode.className=this._className)}toggleClassName(L,U){this.domNode.classList.toggle(L,U),this._className=this.domNode.className}setDisplay(L){this._display!==L&&(this._display=L,this.domNode.style.display=this._display)}setPosition(L){this._position!==L&&(this._position=L,this.domNode.style.position=this._position)}setVisibility(L){this._visibility!==L&&(this._visibility=L,this.domNode.style.visibility=this._visibility)}setColor(L){this._color!==L&&(this._color=L,this.domNode.style.color=this._color)}setBackgroundColor(L){this._backgroundColor!==L&&(this._backgroundColor=L,this.domNode.style.backgroundColor=this._backgroundColor)}setLayerHinting(L){this._layerHint!==L&&(this._layerHint=L,this.domNode.style.transform=this._layerHint?"translate3d(0px, 0px, 0px)":"")}setBoxShadow(L){this._boxShadow!==L&&(this._boxShadow=L,this.domNode.style.boxShadow=L)}setContain(L){this._contain!==L&&(this._contain=L,this.domNode.style.contain=this._contain)}setAttribute(L,U){this.domNode.setAttribute(L,U)}removeAttribute(L){this.domNode.removeAttribute(L)}appendChild(L){this.domNode.appendChild(L.domNode)}removeChild(L){this.domNode.removeChild(L.domNode)}}function o($){return typeof $=="number"?`${$}px`:$}function K($){return new b($)}},5711:(rt,ye,y)=>{y.d(ye,{u:()=>K});var b=y(10998),o=y(2106);class K extends b.jG{constructor(L,U){super(),this._onDidChange=this._register(new o.vl),this.onDidChange=this._onDidChange.event,this._referenceDomElement=L,this._width=-1,this._height=-1,this._resizeObserver=null,this.measureReferenceDomElement(!1,U)}dispose(){this.stopObserving(),super.dispose()}getWidth(){return this._width}getHeight(){return this._height}startObserving(){!this._resizeObserver&&this._referenceDomElement&&(this._resizeObserver=new ResizeObserver(L=>{L&&L[0]&&L[0].contentRect?this.observe({width:L[0].contentRect.width,height:L[0].contentRect.height}):this.observe()}),this._resizeObserver.observe(this._referenceDomElement))}stopObserving(){this._resizeObserver&&(this._resizeObserver.disconnect(),this._resizeObserver=null)}observe(L){this.measureReferenceDomElement(!0,L)}measureReferenceDomElement(L,U){let P=0,B=0;U?(P=U.width,B=U.height):this._referenceDomElement&&(P=this._referenceDomElement.clientWidth,B=this._referenceDomElement.clientHeight),P=Math.max(5,P),B=Math.max(5,B),(this._width!==P||this._height!==B)&&(this._width=P,this._height=B,L&&this._onDidChange.fire())}}},5906:(rt,ye,y)=>{y.d(ye,{Ix:()=>T,bc:()=>P,nV:()=>B});var b=y(50585),o=y(26048),K=y(3765);const $=K.kg("caseDescription","Match Case"),L=K.kg("wordsDescription","Match Whole Word"),U=K.kg("regexDescription","Use Regular Expression");class P extends b.l{constructor(d){super({icon:o.W6.caseSensitive,title:$+d.appendTitle,isChecked:d.isChecked,inputActiveOptionBorder:d.inputActiveOptionBorder,inputActiveOptionForeground:d.inputActiveOptionForeground,inputActiveOptionBackground:d.inputActiveOptionBackground})}}class B extends b.l{constructor(d){super({icon:o.W6.wholeWord,title:L+d.appendTitle,isChecked:d.isChecked,inputActiveOptionBorder:d.inputActiveOptionBorder,inputActiveOptionForeground:d.inputActiveOptionForeground,inputActiveOptionBackground:d.inputActiveOptionBackground})}}class T extends b.l{constructor(d){super({icon:o.W6.regex,title:U+d.appendTitle,isChecked:d.isChecked,inputActiveOptionBorder:d.inputActiveOptionBorder,inputActiveOptionForeground:d.inputActiveOptionForeground,inputActiveOptionBackground:d.inputActiveOptionBackground})}}},6341:(rt,ye,y)=>{y.d(ye,{F1:()=>$,uP:()=>B});var b=y(24489),o=y(22344);class K{constructor(p){this.source=p}getElements(){const p=this.source,d=new Int32Array(p.length);for(let g=0,h=p.length;g<h;g++)d[g]=p.charCodeAt(g);return d}}function $(T,p,d){return new B(new K(T),new K(p)).ComputeDiff(d).changes}class L{static Assert(p,d){if(!p)throw new Error(d)}}class U{static Copy(p,d,g,h,l){for(let u=0;u<l;u++)g[h+u]=p[d+u]}static Copy2(p,d,g,h,l){for(let u=0;u<l;u++)g[h+u]=p[d+u]}}class P{constructor(){this.m_changes=[],this.m_originalStart=1073741824,this.m_modifiedStart=1073741824,this.m_originalCount=0,this.m_modifiedCount=0}MarkNextChange(){(this.m_originalCount>0||this.m_modifiedCount>0)&&this.m_changes.push(new b.y(this.m_originalStart,this.m_originalCount,this.m_modifiedStart,this.m_modifiedCount)),this.m_originalCount=0,this.m_modifiedCount=0,this.m_originalStart=1073741824,this.m_modifiedStart=1073741824}AddOriginalElement(p,d){this.m_originalStart=Math.min(this.m_originalStart,p),this.m_modifiedStart=Math.min(this.m_modifiedStart,d),this.m_originalCount++}AddModifiedElement(p,d){this.m_originalStart=Math.min(this.m_originalStart,p),this.m_modifiedStart=Math.min(this.m_modifiedStart,d),this.m_modifiedCount++}getChanges(){return(this.m_originalCount>0||this.m_modifiedCount>0)&&this.MarkNextChange(),this.m_changes}getReverseChanges(){return(this.m_originalCount>0||this.m_modifiedCount>0)&&this.MarkNextChange(),this.m_changes.reverse(),this.m_changes}}class B{constructor(p,d,g=null){this.ContinueProcessingPredicate=g,this._originalSequence=p,this._modifiedSequence=d;const[h,l,u]=B._getElements(p),[w,C,m]=B._getElements(d);this._hasStrings=u&&m,this._originalStringElements=h,this._originalElementsOrHash=l,this._modifiedStringElements=w,this._modifiedElementsOrHash=C,this.m_forwardHistory=[],this.m_reverseHistory=[]}static _isStringArray(p){return p.length>0&&typeof p[0]=="string"}static _getElements(p){const d=p.getElements();if(B._isStringArray(d)){const g=new Int32Array(d.length);for(let h=0,l=d.length;h<l;h++)g[h]=(0,o.e2)(d[h],0);return[d,g,!0]}return d instanceof Int32Array?[[],d,!1]:[[],new Int32Array(d),!1]}ElementsAreEqual(p,d){return this._originalElementsOrHash[p]!==this._modifiedElementsOrHash[d]?!1:this._hasStrings?this._originalStringElements[p]===this._modifiedStringElements[d]:!0}ElementsAreStrictEqual(p,d){if(!this.ElementsAreEqual(p,d))return!1;const g=B._getStrictElement(this._originalSequence,p),h=B._getStrictElement(this._modifiedSequence,d);return g===h}static _getStrictElement(p,d){return typeof p.getStrictElement=="function"?p.getStrictElement(d):null}OriginalElementsAreEqual(p,d){return this._originalElementsOrHash[p]!==this._originalElementsOrHash[d]?!1:this._hasStrings?this._originalStringElements[p]===this._originalStringElements[d]:!0}ModifiedElementsAreEqual(p,d){return this._modifiedElementsOrHash[p]!==this._modifiedElementsOrHash[d]?!1:this._hasStrings?this._modifiedStringElements[p]===this._modifiedStringElements[d]:!0}ComputeDiff(p){return this._ComputeDiff(0,this._originalElementsOrHash.length-1,0,this._modifiedElementsOrHash.length-1,p)}_ComputeDiff(p,d,g,h,l){const u=[!1];let w=this.ComputeDiffRecursive(p,d,g,h,u);return l&&(w=this.PrettifyChanges(w)),{quitEarly:u[0],changes:w}}ComputeDiffRecursive(p,d,g,h,l){for(l[0]=!1;p<=d&&g<=h&&this.ElementsAreEqual(p,g);)p++,g++;for(;d>=p&&h>=g&&this.ElementsAreEqual(d,h);)d--,h--;if(p>d||g>h){let k;return g<=h?(L.Assert(p===d+1,"originalStart should only be one more than originalEnd"),k=[new b.y(p,0,g,h-g+1)]):p<=d?(L.Assert(g===h+1,"modifiedStart should only be one more than modifiedEnd"),k=[new b.y(p,d-p+1,g,0)]):(L.Assert(p===d+1,"originalStart should only be one more than originalEnd"),L.Assert(g===h+1,"modifiedStart should only be one more than modifiedEnd"),k=[]),k}const u=[0],w=[0],C=this.ComputeRecursionPoint(p,d,g,h,u,w,l),m=u[0],v=w[0];if(C!==null)return C;if(!l[0]){const k=this.ComputeDiffRecursive(p,m,g,v,l);let D=[];return l[0]?D=[new b.y(m+1,d-(m+1)+1,v+1,h-(v+1)+1)]:D=this.ComputeDiffRecursive(m+1,d,v+1,h,l),this.ConcatenateChanges(k,D)}return[new b.y(p,d-p+1,g,h-g+1)]}WALKTRACE(p,d,g,h,l,u,w,C,m,v,k,D,x,A,W,Y,ne,j){let Q=null,X=null,R=new P,H=d,Z=g,N=x[0]-Y[0]-h,G=-1073741824,O=this.m_forwardHistory.length-1;do{const te=N+p;te===H||te<Z&&m[te-1]<m[te+1]?(k=m[te+1],A=k-N-h,k<G&&R.MarkNextChange(),G=k,R.AddModifiedElement(k+1,A),N=te+1-p):(k=m[te-1]+1,A=k-N-h,k<G&&R.MarkNextChange(),G=k-1,R.AddOriginalElement(k,A+1),N=te-1-p),O>=0&&(m=this.m_forwardHistory[O],p=m[0],H=1,Z=m.length-1)}while(--O>=-1);if(Q=R.getReverseChanges(),j[0]){let te=x[0]+1,oe=Y[0]+1;if(Q!==null&&Q.length>0){const ue=Q[Q.length-1];te=Math.max(te,ue.getOriginalEnd()),oe=Math.max(oe,ue.getModifiedEnd())}X=[new b.y(te,D-te+1,oe,W-oe+1)]}else{R=new P,H=u,Z=w,N=x[0]-Y[0]-C,G=1073741824,O=ne?this.m_reverseHistory.length-1:this.m_reverseHistory.length-2;do{const te=N+l;te===H||te<Z&&v[te-1]>=v[te+1]?(k=v[te+1]-1,A=k-N-C,k>G&&R.MarkNextChange(),G=k+1,R.AddOriginalElement(k+1,A+1),N=te+1-l):(k=v[te-1],A=k-N-C,k>G&&R.MarkNextChange(),G=k,R.AddModifiedElement(k+1,A+1),N=te-1-l),O>=0&&(v=this.m_reverseHistory[O],l=v[0],H=1,Z=v.length-1)}while(--O>=-1);X=R.getChanges()}return this.ConcatenateChanges(Q,X)}ComputeRecursionPoint(p,d,g,h,l,u,w){let C=0,m=0,v=0,k=0,D=0,x=0;p--,g--,l[0]=0,u[0]=0,this.m_forwardHistory=[],this.m_reverseHistory=[];const A=d-p+(h-g),W=A+1,Y=new Int32Array(W),ne=new Int32Array(W),j=h-g,Q=d-p,X=p-g,R=d-h,Z=(Q-j)%2===0;Y[j]=p,ne[Q]=d,w[0]=!1;for(let N=1;N<=A/2+1;N++){let G=0,O=0;v=this.ClipDiagonalBound(j-N,N,j,W),k=this.ClipDiagonalBound(j+N,N,j,W);for(let oe=v;oe<=k;oe+=2){oe===v||oe<k&&Y[oe-1]<Y[oe+1]?C=Y[oe+1]:C=Y[oe-1]+1,m=C-(oe-j)-X;const ue=C;for(;C<d&&m<h&&this.ElementsAreEqual(C+1,m+1);)C++,m++;if(Y[oe]=C,C+m>G+O&&(G=C,O=m),!Z&&Math.abs(oe-Q)<=N-1&&C>=ne[oe])return l[0]=C,u[0]=m,ue<=ne[oe]&&N<=1448?this.WALKTRACE(j,v,k,X,Q,D,x,R,Y,ne,C,d,l,m,h,u,Z,w):null}const te=(G-p+(O-g)-N)/2;if(this.ContinueProcessingPredicate!==null&&!this.ContinueProcessingPredicate(G,te))return w[0]=!0,l[0]=G,u[0]=O,te>0&&N<=1448?this.WALKTRACE(j,v,k,X,Q,D,x,R,Y,ne,C,d,l,m,h,u,Z,w):(p++,g++,[new b.y(p,d-p+1,g,h-g+1)]);D=this.ClipDiagonalBound(Q-N,N,Q,W),x=this.ClipDiagonalBound(Q+N,N,Q,W);for(let oe=D;oe<=x;oe+=2){oe===D||oe<x&&ne[oe-1]>=ne[oe+1]?C=ne[oe+1]-1:C=ne[oe-1],m=C-(oe-Q)-R;const ue=C;for(;C>p&&m>g&&this.ElementsAreEqual(C,m);)C--,m--;if(ne[oe]=C,Z&&Math.abs(oe-j)<=N&&C<=Y[oe])return l[0]=C,u[0]=m,ue>=Y[oe]&&N<=1448?this.WALKTRACE(j,v,k,X,Q,D,x,R,Y,ne,C,d,l,m,h,u,Z,w):null}if(N<=1447){let oe=new Int32Array(k-v+2);oe[0]=j-v+1,U.Copy2(Y,v,oe,1,k-v+1),this.m_forwardHistory.push(oe),oe=new Int32Array(x-D+2),oe[0]=Q-D+1,U.Copy2(ne,D,oe,1,x-D+1),this.m_reverseHistory.push(oe)}}return this.WALKTRACE(j,v,k,X,Q,D,x,R,Y,ne,C,d,l,m,h,u,Z,w)}PrettifyChanges(p){for(let d=0;d<p.length;d++){const g=p[d],h=d<p.length-1?p[d+1].originalStart:this._originalElementsOrHash.length,l=d<p.length-1?p[d+1].modifiedStart:this._modifiedElementsOrHash.length,u=g.originalLength>0,w=g.modifiedLength>0;for(;g.originalStart+g.originalLength<h&&g.modifiedStart+g.modifiedLength<l&&(!u||this.OriginalElementsAreEqual(g.originalStart,g.originalStart+g.originalLength))&&(!w||this.ModifiedElementsAreEqual(g.modifiedStart,g.modifiedStart+g.modifiedLength));){const m=this.ElementsAreStrictEqual(g.originalStart,g.modifiedStart);if(this.ElementsAreStrictEqual(g.originalStart+g.originalLength,g.modifiedStart+g.modifiedLength)&&!m)break;g.originalStart++,g.modifiedStart++}const C=[null];if(d<p.length-1&&this.ChangesOverlap(p[d],p[d+1],C)){p[d]=C[0],p.splice(d+1,1),d--;continue}}for(let d=p.length-1;d>=0;d--){const g=p[d];let h=0,l=0;if(d>0){const k=p[d-1];h=k.originalStart+k.originalLength,l=k.modifiedStart+k.modifiedLength}const u=g.originalLength>0,w=g.modifiedLength>0;let C=0,m=this._boundaryScore(g.originalStart,g.originalLength,g.modifiedStart,g.modifiedLength);for(let k=1;;k++){const D=g.originalStart-k,x=g.modifiedStart-k;if(D<h||x<l||u&&!this.OriginalElementsAreEqual(D,D+g.originalLength)||w&&!this.ModifiedElementsAreEqual(x,x+g.modifiedLength))break;const W=(D===h&&x===l?5:0)+this._boundaryScore(D,g.originalLength,x,g.modifiedLength);W>m&&(m=W,C=k)}g.originalStart-=C,g.modifiedStart-=C;const v=[null];if(d>0&&this.ChangesOverlap(p[d-1],p[d],v)){p[d-1]=v[0],p.splice(d,1),d++;continue}}if(this._hasStrings)for(let d=1,g=p.length;d<g;d++){const h=p[d-1],l=p[d],u=l.originalStart-h.originalStart-h.originalLength,w=h.originalStart,C=l.originalStart+l.originalLength,m=C-w,v=h.modifiedStart,k=l.modifiedStart+l.modifiedLength,D=k-v;if(u<5&&m<20&&D<20){const x=this._findBetterContiguousSequence(w,m,v,D,u);if(x){const[A,W]=x;(A!==h.originalStart+h.originalLength||W!==h.modifiedStart+h.modifiedLength)&&(h.originalLength=A-h.originalStart,h.modifiedLength=W-h.modifiedStart,l.originalStart=A+u,l.modifiedStart=W+u,l.originalLength=C-l.originalStart,l.modifiedLength=k-l.modifiedStart)}}}return p}_findBetterContiguousSequence(p,d,g,h,l){if(d<l||h<l)return null;const u=p+d-l+1,w=g+h-l+1;let C=0,m=0,v=0;for(let k=p;k<u;k++)for(let D=g;D<w;D++){const x=this._contiguousSequenceScore(k,D,l);x>0&&x>C&&(C=x,m=k,v=D)}return C>0?[m,v]:null}_contiguousSequenceScore(p,d,g){let h=0;for(let l=0;l<g;l++){if(!this.ElementsAreEqual(p+l,d+l))return 0;h+=this._originalStringElements[p+l].length}return h}_OriginalIsBoundary(p){return p<=0||p>=this._originalElementsOrHash.length-1?!0:this._hasStrings&&/^\s*$/.test(this._originalStringElements[p])}_OriginalRegionIsBoundary(p,d){if(this._OriginalIsBoundary(p)||this._OriginalIsBoundary(p-1))return!0;if(d>0){const g=p+d;if(this._OriginalIsBoundary(g-1)||this._OriginalIsBoundary(g))return!0}return!1}_ModifiedIsBoundary(p){return p<=0||p>=this._modifiedElementsOrHash.length-1?!0:this._hasStrings&&/^\s*$/.test(this._modifiedStringElements[p])}_ModifiedRegionIsBoundary(p,d){if(this._ModifiedIsBoundary(p)||this._ModifiedIsBoundary(p-1))return!0;if(d>0){const g=p+d;if(this._ModifiedIsBoundary(g-1)||this._ModifiedIsBoundary(g))return!0}return!1}_boundaryScore(p,d,g,h){const l=this._OriginalRegionIsBoundary(p,d)?1:0,u=this._ModifiedRegionIsBoundary(g,h)?1:0;return l+u}ConcatenateChanges(p,d){const g=[];if(p.length===0||d.length===0)return d.length>0?d:p;if(this.ChangesOverlap(p[p.length-1],d[0],g)){const h=new Array(p.length+d.length-1);return U.Copy(p,0,h,0,p.length-1),h[p.length-1]=g[0],U.Copy(d,1,h,p.length,d.length-1),h}else{const h=new Array(p.length+d.length);return U.Copy(p,0,h,0,p.length),U.Copy(d,0,h,p.length,d.length),h}}ChangesOverlap(p,d,g){if(L.Assert(p.originalStart<=d.originalStart,"Left change is not less than or equal to right change"),L.Assert(p.modifiedStart<=d.modifiedStart,"Left change is not less than or equal to right change"),p.originalStart+p.originalLength>=d.originalStart||p.modifiedStart+p.modifiedLength>=d.modifiedStart){const h=p.originalStart;let l=p.originalLength;const u=p.modifiedStart;let w=p.modifiedLength;return p.originalStart+p.originalLength>=d.originalStart&&(l=d.originalStart+d.originalLength-p.originalStart),p.modifiedStart+p.modifiedLength>=d.modifiedStart&&(w=d.modifiedStart+d.modifiedLength-p.modifiedStart),g[0]=new b.y(h,l,u,w),!0}else return g[0]=null,!1}ClipDiagonalBound(p,d,g,h){if(p>=0&&p<h)return p;const l=g,u=h-g-1,w=d%2===0;if(p<0){const C=l%2===0;return w===C?0:1}else{const C=u%2===0;return w===C?h-1:h-2}}}},6595:(rt,ye,y)=>{y.d(ye,{c:()=>B});var b=y(14333),o=y(5906),K=y(29004),$=y(45222),L=y(2106),U=y(3765);const P=U.kg("defaultLabel","input");class B extends $.x{constructor(p,d,g,h){var l;super(),this._showOptionButtons=g,this.fixFocusOnOptionClickEnabled=!0,this.imeSessionInProgress=!1,this.additionalToggles=[],this._onDidOptionChange=this._register(new L.vl),this.onDidOptionChange=this._onDidOptionChange.event,this._onKeyDown=this._register(new L.vl),this.onKeyDown=this._onKeyDown.event,this._onMouseDown=this._register(new L.vl),this.onMouseDown=this._onMouseDown.event,this._onInput=this._register(new L.vl),this._onKeyUp=this._register(new L.vl),this._onCaseSensitiveKeyDown=this._register(new L.vl),this.onCaseSensitiveKeyDown=this._onCaseSensitiveKeyDown.event,this._onRegexKeyDown=this._register(new L.vl),this.onRegexKeyDown=this._onRegexKeyDown.event,this._lastHighlightFindOptions=0,this.contextViewProvider=d,this.placeholder=h.placeholder||"",this.validation=h.validation,this.label=h.label||P,this.inputActiveOptionBorder=h.inputActiveOptionBorder,this.inputActiveOptionForeground=h.inputActiveOptionForeground,this.inputActiveOptionBackground=h.inputActiveOptionBackground,this.inputBackground=h.inputBackground,this.inputForeground=h.inputForeground,this.inputBorder=h.inputBorder,this.inputValidationInfoBorder=h.inputValidationInfoBorder,this.inputValidationInfoBackground=h.inputValidationInfoBackground,this.inputValidationInfoForeground=h.inputValidationInfoForeground,this.inputValidationWarningBorder=h.inputValidationWarningBorder,this.inputValidationWarningBackground=h.inputValidationWarningBackground,this.inputValidationWarningForeground=h.inputValidationWarningForeground,this.inputValidationErrorBorder=h.inputValidationErrorBorder,this.inputValidationErrorBackground=h.inputValidationErrorBackground,this.inputValidationErrorForeground=h.inputValidationErrorForeground;const u=h.appendCaseSensitiveLabel||"",w=h.appendWholeWordsLabel||"",C=h.appendRegexLabel||"",m=h.history||[],v=!!h.flexibleHeight,k=!!h.flexibleWidth,D=h.flexibleMaxHeight;this.domNode=document.createElement("div"),this.domNode.classList.add("monaco-findInput"),this.inputBox=this._register(new K.m(this.domNode,this.contextViewProvider,{placeholder:this.placeholder||"",ariaLabel:this.label||"",validationOptions:{validation:this.validation},inputBackground:this.inputBackground,inputForeground:this.inputForeground,inputBorder:this.inputBorder,inputValidationInfoBackground:this.inputValidationInfoBackground,inputValidationInfoForeground:this.inputValidationInfoForeground,inputValidationInfoBorder:this.inputValidationInfoBorder,inputValidationWarningBackground:this.inputValidationWarningBackground,inputValidationWarningForeground:this.inputValidationWarningForeground,inputValidationWarningBorder:this.inputValidationWarningBorder,inputValidationErrorBackground:this.inputValidationErrorBackground,inputValidationErrorForeground:this.inputValidationErrorForeground,inputValidationErrorBorder:this.inputValidationErrorBorder,history:m,showHistoryHint:h.showHistoryHint,flexibleHeight:v,flexibleWidth:k,flexibleMaxHeight:D})),this.regex=this._register(new o.Ix({appendTitle:C,isChecked:!1,inputActiveOptionBorder:this.inputActiveOptionBorder,inputActiveOptionForeground:this.inputActiveOptionForeground,inputActiveOptionBackground:this.inputActiveOptionBackground})),this._register(this.regex.onChange(A=>{this._onDidOptionChange.fire(A),!A&&this.fixFocusOnOptionClickEnabled&&this.inputBox.focus(),this.validate()})),this._register(this.regex.onKeyDown(A=>{this._onRegexKeyDown.fire(A)})),this.wholeWords=this._register(new o.nV({appendTitle:w,isChecked:!1,inputActiveOptionBorder:this.inputActiveOptionBorder,inputActiveOptionForeground:this.inputActiveOptionForeground,inputActiveOptionBackground:this.inputActiveOptionBackground})),this._register(this.wholeWords.onChange(A=>{this._onDidOptionChange.fire(A),!A&&this.fixFocusOnOptionClickEnabled&&this.inputBox.focus(),this.validate()})),this.caseSensitive=this._register(new o.bc({appendTitle:u,isChecked:!1,inputActiveOptionBorder:this.inputActiveOptionBorder,inputActiveOptionForeground:this.inputActiveOptionForeground,inputActiveOptionBackground:this.inputActiveOptionBackground})),this._register(this.caseSensitive.onChange(A=>{this._onDidOptionChange.fire(A),!A&&this.fixFocusOnOptionClickEnabled&&this.inputBox.focus(),this.validate()})),this._register(this.caseSensitive.onKeyDown(A=>{this._onCaseSensitiveKeyDown.fire(A)}));const x=[this.caseSensitive.domNode,this.wholeWords.domNode,this.regex.domNode];this.onkeydown(this.domNode,A=>{if(A.equals(15)||A.equals(17)||A.equals(9)){const W=x.indexOf(document.activeElement);if(W>=0){let Y=-1;A.equals(17)?Y=(W+1)%x.length:A.equals(15)&&(W===0?Y=x.length-1:Y=W-1),A.equals(9)?(x[W].blur(),this.inputBox.focus()):Y>=0&&x[Y].focus(),b.fs.stop(A,!0)}}}),this.controls=document.createElement("div"),this.controls.className="controls",this.controls.style.display=this._showOptionButtons?"block":"none",this.controls.appendChild(this.caseSensitive.domNode),this.controls.appendChild(this.wholeWords.domNode),this.controls.appendChild(this.regex.domNode),this._showOptionButtons||(this.caseSensitive.domNode.style.display="none",this.wholeWords.domNode.style.display="none",this.regex.domNode.style.display="none");for(const A of(l=h?.additionalToggles)!==null&&l!==void 0?l:[])this._register(A),this.controls.appendChild(A.domNode),this._register(A.onChange(W=>{this._onDidOptionChange.fire(W),!W&&this.fixFocusOnOptionClickEnabled&&this.inputBox.focus()})),this.additionalToggles.push(A);this.additionalToggles.length>0&&(this.controls.style.display="block"),this.inputBox.paddingRight=(this._showOptionButtons?this.caseSensitive.width()+this.wholeWords.width()+this.regex.width():0)+this.additionalToggles.reduce((A,W)=>A+W.width(),0),this.domNode.appendChild(this.controls),p?.appendChild(this.domNode),this._register(b.ko(this.inputBox.inputElement,"compositionstart",A=>{this.imeSessionInProgress=!0})),this._register(b.ko(this.inputBox.inputElement,"compositionend",A=>{this.imeSessionInProgress=!1,this._onInput.fire()})),this.onkeydown(this.inputBox.inputElement,A=>this._onKeyDown.fire(A)),this.onkeyup(this.inputBox.inputElement,A=>this._onKeyUp.fire(A)),this.oninput(this.inputBox.inputElement,A=>this._onInput.fire()),this.onmousedown(this.inputBox.inputElement,A=>this._onMouseDown.fire(A))}get onDidChange(){return this.inputBox.onDidChange}enable(){this.domNode.classList.remove("disabled"),this.inputBox.enable(),this.regex.enable(),this.wholeWords.enable(),this.caseSensitive.enable();for(const p of this.additionalToggles)p.enable()}disable(){this.domNode.classList.add("disabled"),this.inputBox.disable(),this.regex.disable(),this.wholeWords.disable(),this.caseSensitive.disable();for(const p of this.additionalToggles)p.disable()}setFocusInputOnOptionClick(p){this.fixFocusOnOptionClickEnabled=p}setEnabled(p){p?this.enable():this.disable()}getValue(){return this.inputBox.value}setValue(p){this.inputBox.value!==p&&(this.inputBox.value=p)}style(p){this.inputActiveOptionBorder=p.inputActiveOptionBorder,this.inputActiveOptionForeground=p.inputActiveOptionForeground,this.inputActiveOptionBackground=p.inputActiveOptionBackground,this.inputBackground=p.inputBackground,this.inputForeground=p.inputForeground,this.inputBorder=p.inputBorder,this.inputValidationInfoBackground=p.inputValidationInfoBackground,this.inputValidationInfoForeground=p.inputValidationInfoForeground,this.inputValidationInfoBorder=p.inputValidationInfoBorder,this.inputValidationWarningBackground=p.inputValidationWarningBackground,this.inputValidationWarningForeground=p.inputValidationWarningForeground,this.inputValidationWarningBorder=p.inputValidationWarningBorder,this.inputValidationErrorBackground=p.inputValidationErrorBackground,this.inputValidationErrorForeground=p.inputValidationErrorForeground,this.inputValidationErrorBorder=p.inputValidationErrorBorder,this.applyStyles()}applyStyles(){if(this.domNode){const p={inputActiveOptionBorder:this.inputActiveOptionBorder,inputActiveOptionForeground:this.inputActiveOptionForeground,inputActiveOptionBackground:this.inputActiveOptionBackground};this.regex.style(p),this.wholeWords.style(p),this.caseSensitive.style(p);for(const g of this.additionalToggles)g.style(p);const d={inputBackground:this.inputBackground,inputForeground:this.inputForeground,inputBorder:this.inputBorder,inputValidationInfoBackground:this.inputValidationInfoBackground,inputValidationInfoForeground:this.inputValidationInfoForeground,inputValidationInfoBorder:this.inputValidationInfoBorder,inputValidationWarningBackground:this.inputValidationWarningBackground,inputValidationWarningForeground:this.inputValidationWarningForeground,inputValidationWarningBorder:this.inputValidationWarningBorder,inputValidationErrorBackground:this.inputValidationErrorBackground,inputValidationErrorForeground:this.inputValidationErrorForeground,inputValidationErrorBorder:this.inputValidationErrorBorder};this.inputBox.style(d)}}select(){this.inputBox.select()}focus(){this.inputBox.focus()}getCaseSensitive(){return this.caseSensitive.checked}setCaseSensitive(p){this.caseSensitive.checked=p}getWholeWords(){return this.wholeWords.checked}setWholeWords(p){this.wholeWords.checked=p}getRegex(){return this.regex.checked}setRegex(p){this.regex.checked=p,this.validate()}focusOnCaseSensitive(){this.caseSensitive.focus()}highlightFindOptions(){this.domNode.classList.remove("highlight-"+this._lastHighlightFindOptions),this._lastHighlightFindOptions=1-this._lastHighlightFindOptions,this.domNode.classList.add("highlight-"+this._lastHighlightFindOptions)}validate(){this.inputBox.validate()}showMessage(p){this.inputBox.showMessage(p)}clearMessage(){this.inputBox.hideMessage()}}},6949:(rt,ye,y)=>{y.d(ye,{k:()=>$,x:()=>L});var b=y(42802),o=y(54324);function K(P){return P.replace(/\n/g,"\\n").replace(/\r/g,"\\r")}class ${constructor(B,T,p,d){this.oldPosition=B,this.oldText=T,this.newPosition=p,this.newText=d}get oldLength(){return this.oldText.length}get oldEnd(){return this.oldPosition+this.oldText.length}get newLength(){return this.newText.length}get newEnd(){return this.newPosition+this.newText.length}toString(){return this.oldText.length===0?`(insert@${this.oldPosition} "${K(this.newText)}")`:this.newText.length===0?`(delete@${this.oldPosition} "${K(this.oldText)}")`:`(replace@${this.oldPosition} "${K(this.oldText)}" with "${K(this.newText)}")`}static _writeStringSize(B){return 4+2*B.length}static _writeString(B,T,p){const d=T.length;b.Sw(B,d,p),p+=4;for(let g=0;g<d;g++)b.gN(B,T.charCodeAt(g),p),p+=2;return p}static _readString(B,T){const p=b.bb(B,T);return T+=4,(0,o.Su)(B,T,p)}writeSize(){return 8+$._writeStringSize(this.oldText)+$._writeStringSize(this.newText)}write(B,T){return b.Sw(B,this.oldPosition,T),T+=4,b.Sw(B,this.newPosition,T),T+=4,T=$._writeString(B,this.oldText,T),T=$._writeString(B,this.newText,T),T}static read(B,T,p){const d=b.bb(B,T);T+=4;const g=b.bb(B,T);T+=4;const h=$._readString(B,T);T+=$._writeStringSize(h);const l=$._readString(B,T);return T+=$._writeStringSize(l),p.push(new $(d,h,g,l)),T}}function L(P,B){return P===null||P.length===0?B:new U(P,B).compress()}class U{constructor(B,T){this._prevEdits=B,this._currEdits=T,this._result=[],this._resultLen=0,this._prevLen=this._prevEdits.length,this._prevDeltaOffset=0,this._currLen=this._currEdits.length,this._currDeltaOffset=0}compress(){let B=0,T=0,p=this._getPrev(B),d=this._getCurr(T);for(;B<this._prevLen||T<this._currLen;){if(p===null){this._acceptCurr(d),d=this._getCurr(++T);continue}if(d===null){this._acceptPrev(p),p=this._getPrev(++B);continue}if(d.oldEnd<=p.newPosition){this._acceptCurr(d),d=this._getCurr(++T);continue}if(p.newEnd<=d.oldPosition){this._acceptPrev(p),p=this._getPrev(++B);continue}if(d.oldPosition<p.newPosition){const[w,C]=U._splitCurr(d,p.newPosition-d.oldPosition);this._acceptCurr(w),d=C;continue}if(p.newPosition<d.oldPosition){const[w,C]=U._splitPrev(p,d.oldPosition-p.newPosition);this._acceptPrev(w),p=C;continue}let l,u;if(d.oldEnd===p.newEnd)l=p,u=d,p=this._getPrev(++B),d=this._getCurr(++T);else if(d.oldEnd<p.newEnd){const[w,C]=U._splitPrev(p,d.oldLength);l=w,u=d,p=C,d=this._getCurr(++T)}else{const[w,C]=U._splitCurr(d,p.newLength);l=p,u=w,p=this._getPrev(++B),d=C}this._result[this._resultLen++]=new $(l.oldPosition,l.oldText,u.newPosition,u.newText),this._prevDeltaOffset+=l.newLength-l.oldLength,this._currDeltaOffset+=u.newLength-u.oldLength}const g=U._merge(this._result);return U._removeNoOps(g)}_acceptCurr(B){this._result[this._resultLen++]=U._rebaseCurr(this._prevDeltaOffset,B),this._currDeltaOffset+=B.newLength-B.oldLength}_getCurr(B){return B<this._currLen?this._currEdits[B]:null}_acceptPrev(B){this._result[this._resultLen++]=U._rebasePrev(this._currDeltaOffset,B),this._prevDeltaOffset+=B.newLength-B.oldLength}_getPrev(B){return B<this._prevLen?this._prevEdits[B]:null}static _rebaseCurr(B,T){return new $(T.oldPosition-B,T.oldText,T.newPosition,T.newText)}static _rebasePrev(B,T){return new $(T.oldPosition,T.oldText,T.newPosition+B,T.newText)}static _splitPrev(B,T){const p=B.newText.substr(0,T),d=B.newText.substr(T);return[new $(B.oldPosition,B.oldText,B.newPosition,p),new $(B.oldEnd,"",B.newPosition+T,d)]}static _splitCurr(B,T){const p=B.oldText.substr(0,T),d=B.oldText.substr(T);return[new $(B.oldPosition,p,B.newPosition,B.newText),new $(B.oldPosition+T,d,B.newEnd,"")]}static _merge(B){if(B.length===0)return B;const T=[];let p=0,d=B[0];for(let g=1;g<B.length;g++){const h=B[g];d.oldEnd===h.oldPosition?d=new $(d.oldPosition,d.oldText+h.oldText,d.newPosition,d.newText+h.newText):(T[p++]=d,d=h)}return T[p++]=d,T}static _removeNoOps(B){if(B.length===0)return B;const T=[];let p=0;for(let d=0;d<B.length;d++){const g=B[d];g.oldText!==g.newText&&(T[p++]=g)}return T}}},8377:(rt,ye,y)=>{y.d(ye,{L:()=>o});var b=y(82399);const o=(0,b.u1)("labelService")},9520:(rt,ye,y)=>{y.d(ye,{i:()=>h,b:()=>l});var b=y(15910),o=y(89044),K=y(46441),$=y(15365),L=y(50442),U=y(3902);class P{constructor(m,v){this._startLineNumber=m,this._tokens=v,this._endLineNumber=this._startLineNumber+this._tokens.getMaxDeltaLine()}static create(m,v){return new P(m,new B(v))}get startLineNumber(){return this._startLineNumber}get endLineNumber(){return this._endLineNumber}toString(){return this._tokens.toString(this._startLineNumber)}_updateEndLineNumber(){this._endLineNumber=this._startLineNumber+this._tokens.getMaxDeltaLine()}isEmpty(){return this._tokens.isEmpty()}getLineTokens(m){return this._startLineNumber<=m&&m<=this._endLineNumber?this._tokens.getLineTokens(m-this._startLineNumber):null}getRange(){const m=this._tokens.getRange();return m&&new L.Q(this._startLineNumber+m.startLineNumber,m.startColumn,this._startLineNumber+m.endLineNumber,m.endColumn)}removeTokens(m){const v=m.startLineNumber-this._startLineNumber,k=m.endLineNumber-this._startLineNumber;this._startLineNumber+=this._tokens.removeTokens(v,m.startColumn-1,k,m.endColumn-1),this._updateEndLineNumber()}split(m){const v=m.startLineNumber-this._startLineNumber,k=m.endLineNumber-this._startLineNumber,[D,x,A]=this._tokens.split(v,m.startColumn-1,k,m.endColumn-1);return[new P(this._startLineNumber,D),new P(this._startLineNumber+A,x)]}applyEdit(m,v){const[k,D,x]=(0,U.W)(v);this.acceptEdit(m,k,D,x,v.length>0?v.charCodeAt(0):0)}acceptEdit(m,v,k,D,x){this._acceptDeleteRange(m),this._acceptInsertText(new $.y(m.startLineNumber,m.startColumn),v,k,D,x),this._updateEndLineNumber()}_acceptDeleteRange(m){if(m.startLineNumber===m.endLineNumber&&m.startColumn===m.endColumn)return;const v=m.startLineNumber-this._startLineNumber,k=m.endLineNumber-this._startLineNumber;if(k<0){const x=k-v;this._startLineNumber-=x;return}const D=this._tokens.getMaxDeltaLine();if(!(v>=D+1)){if(v<0&&k>=D+1){this._startLineNumber=0,this._tokens.clear();return}if(v<0){const x=-v;this._startLineNumber-=x,this._tokens.acceptDeleteRange(m.startColumn-1,0,0,k,m.endColumn-1)}else this._tokens.acceptDeleteRange(0,v,m.startColumn-1,k,m.endColumn-1)}}_acceptInsertText(m,v,k,D,x){if(v===0&&k===0)return;const A=m.lineNumber-this._startLineNumber;if(A<0){this._startLineNumber+=v;return}const W=this._tokens.getMaxDeltaLine();A>=W+1||this._tokens.acceptInsertText(A,m.column-1,v,k,D,x)}}class B{constructor(m){this._tokens=m,this._tokenCount=m.length/4}toString(m){const v=[];for(let k=0;k<this._tokenCount;k++)v.push(`(${this._getDeltaLine(k)+m},${this._getStartCharacter(k)}-${this._getEndCharacter(k)})`);return`[${v.join(",")}]`}getMaxDeltaLine(){const m=this._getTokenCount();return m===0?-1:this._getDeltaLine(m-1)}getRange(){const m=this._getTokenCount();if(m===0)return null;const v=this._getStartCharacter(0),k=this._getDeltaLine(m-1),D=this._getEndCharacter(m-1);return new L.Q(0,v+1,k,D+1)}_getTokenCount(){return this._tokenCount}_getDeltaLine(m){return this._tokens[4*m]}_getStartCharacter(m){return this._tokens[4*m+1]}_getEndCharacter(m){return this._tokens[4*m+2]}isEmpty(){return this._getTokenCount()===0}getLineTokens(m){let v=0,k=this._getTokenCount()-1;for(;v<k;){const D=v+Math.floor((k-v)/2),x=this._getDeltaLine(D);if(x<m)v=D+1;else if(x>m)k=D-1;else{let A=D;for(;A>v&&this._getDeltaLine(A-1)===m;)A--;let W=D;for(;W<k&&this._getDeltaLine(W+1)===m;)W++;return new T(this._tokens.subarray(4*A,4*W+4))}}return this._getDeltaLine(v)===m?new T(this._tokens.subarray(4*v,4*v+4)):null}clear(){this._tokenCount=0}removeTokens(m,v,k,D){const x=this._tokens,A=this._tokenCount;let W=0,Y=!1,ne=0;for(let j=0;j<A;j++){const Q=4*j,X=x[Q],R=x[Q+1],H=x[Q+2],Z=x[Q+3];if((X>m||X===m&&H>=v)&&(X<k||X===k&&R<=D))Y=!0;else{if(W===0&&(ne=X),Y){const N=4*W;x[N]=X-ne,x[N+1]=R,x[N+2]=H,x[N+3]=Z}W++}}return this._tokenCount=W,ne}split(m,v,k,D){const x=this._tokens,A=this._tokenCount,W=[],Y=[];let ne=W,j=0,Q=0;for(let X=0;X<A;X++){const R=4*X,H=x[R],Z=x[R+1],N=x[R+2],G=x[R+3];if(H>m||H===m&&N>=v){if(H<k||H===k&&Z<=D)continue;ne!==Y&&(ne=Y,j=0,Q=H)}ne[j++]=H-Q,ne[j++]=Z,ne[j++]=N,ne[j++]=G}return[new B(new Uint32Array(W)),new B(new Uint32Array(Y)),Q]}acceptDeleteRange(m,v,k,D,x){const A=this._tokens,W=this._tokenCount,Y=D-v;let ne=0,j=!1;for(let Q=0;Q<W;Q++){const X=4*Q;let R=A[X],H=A[X+1],Z=A[X+2];const N=A[X+3];if(R<v||R===v&&Z<=k){ne++;continue}else if(R===v&&H<k)R===D&&Z>x?Z-=x-k:Z=k;else if(R===v&&H===k)if(R===D&&Z>x)Z-=x-k;else{j=!0;continue}else if(R<D||R===D&&H<x)if(R===D&&Z>x)R===v?(H=k,Z=H+(Z-x)):(H=0,Z=H+(Z-x));else{j=!0;continue}else if(R>D){if(Y===0&&!j){ne=W;break}R-=Y}else if(R===D&&H>=x)m&&R===0&&(H+=m,Z+=m),R-=Y,H-=x-k,Z-=x-k;else throw new Error("Not possible!");const G=4*ne;A[G]=R,A[G+1]=H,A[G+2]=Z,A[G+3]=N,ne++}this._tokenCount=ne}acceptInsertText(m,v,k,D,x,A){const W=k===0&&D===1&&(A>=48&&A<=57||A>=65&&A<=90||A>=97&&A<=122),Y=this._tokens,ne=this._tokenCount;for(let j=0;j<ne;j++){const Q=4*j;let X=Y[Q],R=Y[Q+1],H=Y[Q+2];if(!(X<m||X===m&&H<v)){if(X===m&&H===v)if(W)H+=1;else continue;else if(X===m&&R<v&&v<H)k===0?H+=D:H=v;else{if(X===m&&R===v&&W)continue;if(X===m)if(X+=k,k===0)R+=D,H+=D;else{const Z=H-R;R=x+(R-v),H=R+Z}else X+=k}Y[Q]=X,Y[Q+1]=R,Y[Q+2]=H}}}}class T{constructor(m){this._tokens=m}getCount(){return this._tokens.length/4}getStartCharacter(m){return this._tokens[4*m+1]}getEndCharacter(m){return this._tokens[4*m+2]}getMetadata(m){return this._tokens[4*m+3]}}var p=y(77922),d=function(C,m,v,k){var D=arguments.length,x=D<3?m:k===null?k=Object.getOwnPropertyDescriptor(m,v):k,A;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")x=Reflect.decorate(C,m,v,k);else for(var W=C.length-1;W>=0;W--)(A=C[W])&&(x=(D<3?A(x):D>3?A(m,v,x):A(m,v))||x);return D>3&&x&&Object.defineProperty(m,v,x),x},g=function(C,m){return function(v,k){m(v,k,C)}};let h=class{constructor(m,v,k,D){this._legend=m,this._themeService=v,this._languageService=k,this._logService=D,this._hasWarnedOverlappingTokens=!1,this._hasWarnedInvalidLengthTokens=!1,this._hasWarnedInvalidEditStart=!1,this._hashTable=new w}getMetadata(m,v,k){const D=this._languageService.languageIdCodec.encodeLanguageId(k),x=this._hashTable.get(m,v,D);let A;if(x)A=x.metadata,this._logService.getLevel()===K.$b.Trace&&this._logService.trace(`SemanticTokensProviderStyling [CACHED] ${m} / ${v}: foreground ${b.x.getForeground(A)}, fontStyle ${b.x.getFontStyle(A).toString(2)}`);else{let W=this._legend.tokenTypes[m];const Y=[];if(W){let ne=v;for(let Q=0;ne>0&&Q<this._legend.tokenModifiers.length;Q++)ne&1&&Y.push(this._legend.tokenModifiers[Q]),ne=ne>>1;ne>0&&this._logService.getLevel()===K.$b.Trace&&(this._logService.trace(`SemanticTokensProviderStyling: unknown token modifier index: ${v.toString(2)} for legend: ${JSON.stringify(this._legend.tokenModifiers)}`),Y.push("not-in-legend"));const j=this._themeService.getColorTheme().getTokenStyleMetadata(W,Y,k);if(typeof j>"u")A=2147483647;else{if(A=0,typeof j.italic<"u"){const Q=(j.italic?1:0)<<11;A|=Q|1}if(typeof j.bold<"u"){const Q=(j.bold?2:0)<<11;A|=Q|2}if(typeof j.underline<"u"){const Q=(j.underline?4:0)<<11;A|=Q|4}if(typeof j.strikethrough<"u"){const Q=(j.strikethrough?8:0)<<11;A|=Q|8}if(j.foreground){const Q=j.foreground<<15;A|=Q|16}A===0&&(A=2147483647)}}else this._logService.getLevel()===K.$b.Trace&&this._logService.trace(`SemanticTokensProviderStyling: unknown token type index: ${m} for legend: ${JSON.stringify(this._legend.tokenTypes)}`),A=2147483647,W="not-in-legend";this._hashTable.add(m,v,D,A),this._logService.getLevel()===K.$b.Trace&&this._logService.trace(`SemanticTokensProviderStyling ${m} (${W}) / ${v} (${Y.join(" ")}): foreground ${b.x.getForeground(A)}, fontStyle ${b.x.getFontStyle(A).toString(2)}`)}return A}warnOverlappingSemanticTokens(m,v){this._hasWarnedOverlappingTokens||(this._hasWarnedOverlappingTokens=!0,console.warn(`Overlapping semantic tokens detected at lineNumber ${m}, column ${v}`))}warnInvalidLengthSemanticTokens(m,v){this._hasWarnedInvalidLengthTokens||(this._hasWarnedInvalidLengthTokens=!0,console.warn(`Semantic token with invalid length detected at lineNumber ${m}, column ${v}`))}warnInvalidEditStart(m,v,k,D,x){this._hasWarnedInvalidEditStart||(this._hasWarnedInvalidEditStart=!0,console.warn(`Invalid semantic tokens edit detected (previousResultId: ${m}, resultId: ${v}) at edit #${k}: The provided start offset ${D} is outside the previous data (length ${x}).`))}};h=d([g(1,o.Gy),g(2,p.L),g(3,K.rr)],h);function l(C,m,v){const k=C.data,D=C.data.length/5|0,x=Math.max(Math.ceil(D/1024),400),A=[];let W=0,Y=1,ne=0;for(;W<D;){const j=W;let Q=Math.min(j+x,D);if(Q<D){let O=Q;for(;O-1>j&&k[5*O]===0;)O--;if(O-1===j){let te=Q;for(;te+1<D&&k[5*te]===0;)te++;Q=te}else Q=O}let X=new Uint32Array((Q-j)*4),R=0,H=0,Z=0,N=0;for(;W<Q;){const O=5*W,te=k[O],oe=k[O+1],ue=Y+te|0,E=te===0?ne+oe|0:oe,Qe=k[O+2],Ke=E+Qe|0,Se=k[O+3],Me=k[O+4];if(Ke<=E)m.warnInvalidLengthSemanticTokens(ue,E+1);else if(Z===ue&&N>E)m.warnOverlappingSemanticTokens(ue,E+1);else{const ce=m.getMetadata(Se,Me,v);ce!==2147483647&&(H===0&&(H=ue),X[R]=ue-H,X[R+1]=E,X[R+2]=Ke,X[R+3]=ce,R+=4,Z=ue,N=Ke)}Y=ue,ne=E,W++}R!==X.length&&(X=X.subarray(0,R));const G=P.create(H,X);A.push(G)}return A}class u{constructor(m,v,k,D){this.tokenTypeIndex=m,this.tokenModifierSet=v,this.languageId=k,this.metadata=D,this.next=null}}class w{constructor(){this._elementsCount=0,this._currentLengthIndex=0,this._currentLength=w._SIZES[this._currentLengthIndex],this._growCount=Math.round(this._currentLengthIndex+1<w._SIZES.length?2/3*this._currentLength:0),this._elements=[],w._nullOutEntries(this._elements,this._currentLength)}static _nullOutEntries(m,v){for(let k=0;k<v;k++)m[k]=null}_hash2(m,v){return(m<<5)-m+v|0}_hashFunc(m,v,k){return this._hash2(this._hash2(m,v),k)%this._currentLength}get(m,v,k){const D=this._hashFunc(m,v,k);let x=this._elements[D];for(;x;){if(x.tokenTypeIndex===m&&x.tokenModifierSet===v&&x.languageId===k)return x;x=x.next}return null}add(m,v,k,D){if(this._elementsCount++,this._growCount!==0&&this._elementsCount>=this._growCount){const x=this._elements;this._currentLengthIndex++,this._currentLength=w._SIZES[this._currentLengthIndex],this._growCount=Math.round(this._currentLengthIndex+1<w._SIZES.length?2/3*this._currentLength:0),this._elements=[],w._nullOutEntries(this._elements,this._currentLength);for(const A of x){let W=A;for(;W;){const Y=W.next;W.next=null,this._add(W),W=Y}}}this._add(new u(m,v,k,D))}_add(m){const v=this._hashFunc(m.tokenTypeIndex,m.tokenModifierSet,m.languageId);m.next=this._elements[v],this._elements[v]=m}}w._SIZES=[3,7,13,31,61,127,251,509,1021,2039,4093,8191,16381,32749,65521,131071,262139,524287,1048573,2097143]},9715:(rt,ye,y)=>{y.d(ye,{P:()=>P,$:()=>B});var b=y(55893);let o=!1,K=null;function $(T){if(!T.parent||T.parent===T)return null;try{const p=T.location,d=T.parent.location;if(p.origin!=="null"&&d.origin!=="null"&&p.origin!==d.origin)return o=!0,null}catch{return o=!0,null}return T.parent}class L{static getSameOriginWindowChain(){if(!K){K=[];let p=window,d;do d=$(p),d?K.push({window:p,iframeElement:p.frameElement||null}):K.push({window:p,iframeElement:null}),p=d;while(p)}return K.slice(0)}static getPositionOfChildWindowRelativeToAncestorWindow(p,d){if(!d||p===d)return{top:0,left:0};let g=0,h=0;const l=this.getSameOriginWindowChain();for(const u of l){if(g+=u.window.scrollY,h+=u.window.scrollX,u.window===d||!u.iframeElement)break;const w=u.iframeElement.getBoundingClientRect();g+=w.top,h+=w.left}return{top:g,left:h}}}var U=y(63339);class P{constructor(p){this.timestamp=Date.now(),this.browserEvent=p,this.leftButton=p.button===0,this.middleButton=p.button===1,this.rightButton=p.button===2,this.buttons=p.buttons,this.target=p.target,this.detail=p.detail||1,p.type==="dblclick"&&(this.detail=2),this.ctrlKey=p.ctrlKey,this.shiftKey=p.shiftKey,this.altKey=p.altKey,this.metaKey=p.metaKey,typeof p.pageX=="number"?(this.posx=p.pageX,this.posy=p.pageY):(this.posx=p.clientX+document.body.scrollLeft+document.documentElement.scrollLeft,this.posy=p.clientY+document.body.scrollTop+document.documentElement.scrollTop);const d=L.getPositionOfChildWindowRelativeToAncestorWindow(self,p.view);this.posx-=d.left,this.posy-=d.top}preventDefault(){this.browserEvent.preventDefault()}stopPropagation(){this.browserEvent.stopPropagation()}}class B{constructor(p,d=0,g=0){if(this.browserEvent=p||null,this.target=p?p.target||p.targetNode||p.srcElement:null,this.deltaY=g,this.deltaX=d,p){const h=p,l=p;if(typeof h.wheelDeltaY<"u")this.deltaY=h.wheelDeltaY/120;else if(typeof l.VERTICAL_AXIS<"u"&&l.axis===l.VERTICAL_AXIS)this.deltaY=-l.detail/3;else if(p.type==="wheel"){const u=p;u.deltaMode===u.DOM_DELTA_LINE?b.isFirefox&&!U.zx?this.deltaY=-p.deltaY/3:this.deltaY=-p.deltaY:this.deltaY=-p.deltaY/40}if(typeof h.wheelDeltaX<"u")b.isSafari&&U.uF?this.deltaX=-(h.wheelDeltaX/120):this.deltaX=h.wheelDeltaX/120;else if(typeof l.HORIZONTAL_AXIS<"u"&&l.axis===l.HORIZONTAL_AXIS)this.deltaX=-p.detail/3;else if(p.type==="wheel"){const u=p;u.deltaMode===u.DOM_DELTA_LINE?b.isFirefox&&!U.zx?this.deltaX=-p.deltaX/3:this.deltaX=-p.deltaX:this.deltaX=-p.deltaX/40}this.deltaY===0&&this.deltaX===0&&p.wheelDelta&&(this.deltaY=p.wheelDelta/120)}}preventDefault(){this.browserEvent&&this.browserEvent.preventDefault()}stopPropagation(){this.browserEvent&&this.browserEvent.stopPropagation()}}},10176:(rt,ye,y)=>{y.d(ye,{_:()=>K});var b=y(14333),o=y(10998);class K{constructor(){this._hooks=new o.Cm,this._pointerMoveCallback=null,this._onStopCallback=null}dispose(){this.stopMonitoring(!1),this._hooks.dispose()}stopMonitoring(L,U){if(!this.isMonitoring())return;this._hooks.clear(),this._pointerMoveCallback=null;const P=this._onStopCallback;this._onStopCallback=null,L&&P&&P(U)}isMonitoring(){return!!this._pointerMoveCallback}startMonitoring(L,U,P,B,T){this.isMonitoring()&&this.stopMonitoring(!1),this._pointerMoveCallback=B,this._onStopCallback=T;let p=L;try{L.setPointerCapture(U),this._hooks.add((0,o.s)(()=>{L.releasePointerCapture(U)}))}catch{p=window}this._hooks.add(b.ko(p,b.Bx.POINTER_MOVE,d=>{if(d.buttons!==P){this.stopMonitoring(!0);return}d.preventDefault(),this._pointerMoveCallback(d)})),this._hooks.add(b.ko(p,b.Bx.POINTER_UP,d=>this.stopMonitoring(!0)))}}},10998:(rt,ye,y)=>{y.d(ye,{AS:()=>h,BO:()=>D,Cm:()=>w,HE:()=>m,St:()=>k,Xm:()=>g,jG:()=>C,lC:()=>p,mp:()=>v,qE:()=>l,s:()=>u});var b=y(48289),o=y(17954);const K=!1;let $=null;function L(x){$=x}if(K){const x="__is_disposable_tracked__";L(new class{trackDisposable(A){const W=new Error("Potentially leaked disposable").stack;setTimeout(()=>{A[x]||console.log(W)},3e3)}setParent(A,W){if(A&&A!==C.None)try{A[x]=!0}catch{}}markAsDisposed(A){if(A&&A!==C.None)try{A[x]=!0}catch{}}markAsSingleton(A){}})}function U(x){return $?.trackDisposable(x),x}function P(x){$?.markAsDisposed(x)}function B(x,A){$?.setParent(x,A)}function T(x,A){if($)for(const W of x)$.setParent(W,A)}function p(x){return $?.markAsSingleton(x),x}class d extends Error{constructor(A){super(`Encountered errors while disposing of store. Errors: [${A.join(", ")}]`),this.errors=A}}function g(x){return typeof x.dispose=="function"&&x.dispose.length===0}function h(x){if(o.f.is(x)){const A=[];for(const W of x)if(W)try{W.dispose()}catch(Y){A.push(Y)}if(A.length===1)throw A[0];if(A.length>1)throw new d(A);return Array.isArray(x)?[]:x}else if(x)return x.dispose(),x}function l(...x){const A=u(()=>h(x));return T(x,A),A}function u(x){const A=U({dispose:(0,b.O)(()=>{P(A),x()})});return A}class w{constructor(){this._toDispose=new Set,this._isDisposed=!1,U(this)}dispose(){this._isDisposed||(P(this),this._isDisposed=!0,this.clear())}get isDisposed(){return this._isDisposed}clear(){try{h(this._toDispose.values())}finally{this._toDispose.clear()}}add(A){if(!A)return A;if(A===this)throw new Error("Cannot register a disposable on itself!");return B(A,this),this._isDisposed?w.DISABLE_DISPOSED_WARNING||console.warn(new Error("Trying to add a disposable to a DisposableStore that has already been disposed of. The added object will be leaked!").stack):this._toDispose.add(A),A}}w.DISABLE_DISPOSED_WARNING=!1;class C{constructor(){this._store=new w,U(this),B(this._store,this)}dispose(){P(this),this._store.dispose()}_register(A){if(A===this)throw new Error("Cannot register a disposable on itself!");return this._store.add(A)}}C.None=Object.freeze({dispose(){}});class m{constructor(){this._isDisposed=!1,U(this)}get value(){return this._isDisposed?void 0:this._value}set value(A){var W;this._isDisposed||A===this._value||((W=this._value)===null||W===void 0||W.dispose(),A&&B(A,this),this._value=A)}clear(){this.value=void 0}dispose(){var A;this._isDisposed=!0,P(this),(A=this._value)===null||A===void 0||A.dispose(),this._value=void 0}clearAndLeak(){const A=this._value;return this._value=void 0,A&&B(A,null),A}}class v{constructor(A){this._disposable=A,this._counter=1}acquire(){return this._counter++,this}release(){return--this._counter===0&&this._disposable.dispose(),this}}class k{constructor(){this.dispose=()=>{},this.unset=()=>{},this.isset=()=>!1,U(this)}set(A){let W=A;return this.unset=()=>W=void 0,this.isset=()=>W!==void 0,this.dispose=()=>{W&&(W(),W=void 0,P(this))},this}}class D{constructor(A){this.object=A}dispose(){}}},11210:(rt,ye,y)=>{y.d(ye,{$_:()=>D,HT:()=>w,pU:()=>u});var b=y(65958),o=y(26048),K=y(2106),$=y(79359),L=y(37264),U=y(3765),P=y(51460),B=y(67167),T=y(89044);const p={IconContribution:"base.contributions.icons"};var d;(function(ne){function j(Q,X){let R=Q.defaults;for(;T.L0.isThemeIcon(R);){const H=l.getIcon(R.id);if(!H)return;R=H.defaults}return R}ne.getDefinition=j})(d||(d={}));var g;(function(ne){function j(X){return{weight:X.weight,style:X.style,src:X.src.map(R=>({format:R.format,location:R.location.toString()}))}}ne.toJSONObject=j;function Q(X){const R=H=>(0,$.Kg)(H)?H:void 0;if(X&&Array.isArray(X.src)&&X.src.every(H=>(0,$.Kg)(H.format)&&(0,$.Kg)(H.location)))return{weight:R(X.weight),style:R(X.style),src:X.src.map(H=>({format:H.format,location:L.r.parse(H.location)}))}}ne.fromJSONObject=Q})(g||(g={}));class h{constructor(){this._onDidChange=new K.vl,this.onDidChange=this._onDidChange.event,this.iconSchema={definitions:{icons:{type:"object",properties:{fontId:{type:"string",description:(0,U.kg)("iconDefinition.fontId","The id of the font to use. If not set, the font that is defined first is used.")},fontCharacter:{type:"string",description:(0,U.kg)("iconDefinition.fontCharacter","The font character associated with the icon definition.")}},additionalProperties:!1,defaultSnippets:[{body:{fontCharacter:"\\\\e030"}}]}},type:"object",properties:{}},this.iconReferenceSchema={type:"string",pattern:`^${o.j3.iconNameExpression}$`,enum:[],enumDescriptions:[]},this.iconsById={},this.iconFontsById={}}registerIcon(j,Q,X,R){const H=this.iconsById[j];if(H){if(X&&!H.description){H.description=X,this.iconSchema.properties[j].markdownDescription=`${X} $(${j})`;const G=this.iconReferenceSchema.enum.indexOf(j);G!==-1&&(this.iconReferenceSchema.enumDescriptions[G]=X),this._onDidChange.fire()}return H}const Z={id:j,description:X,defaults:Q,deprecationMessage:R};this.iconsById[j]=Z;const N={$ref:"#/definitions/icons"};return R&&(N.deprecationMessage=R),X&&(N.markdownDescription=`${X}: $(${j})`),this.iconSchema.properties[j]=N,this.iconReferenceSchema.enum.push(j),this.iconReferenceSchema.enumDescriptions.push(X||""),this._onDidChange.fire(),{id:j}}getIcons(){return Object.keys(this.iconsById).map(j=>this.iconsById[j])}getIcon(j){return this.iconsById[j]}getIconSchema(){return this.iconSchema}toString(){const j=(H,Z)=>H.id.localeCompare(Z.id),Q=H=>{for(;T.L0.isThemeIcon(H.defaults);)H=this.iconsById[H.defaults.id];return`codicon codicon-${H?H.id:""}`},X=[];X.push("| preview | identifier | default codicon ID | description"),X.push("| ----------- | --------------------------------- | --------------------------------- | --------------------------------- |");const R=Object.keys(this.iconsById).map(H=>this.iconsById[H]);for(const H of R.filter(Z=>!!Z.description).sort(j))X.push(`|<i class="${Q(H)}"></i>|${H.id}|${T.L0.isThemeIcon(H.defaults)?H.defaults.id:H.id}|${H.description||""}|`);X.push("| preview | identifier "),X.push("| ----------- | --------------------------------- |");for(const H of R.filter(Z=>!T.L0.isThemeIcon(Z.defaults)).sort(j))X.push(`|<i class="${Q(H)}"></i>|${H.id}|`);return X.join(` `)}}const l=new h;B.O.add(p.IconContribution,l);function u(ne,j,Q,X){return l.registerIcon(ne,j,Q,X)}function w(){return l}function C(){for(const ne of o.W6.getAll())l.registerIcon(ne.id,ne.definition,ne.description)}C();const m="vscode://schemas/icons",v=B.O.as(P.F.JSONContribution);v.registerSchema(m,l.getIconSchema());const k=new b.uC(()=>v.notifySchemaChanged(m),200);l.onDidChange(()=>{k.isScheduled()||k.schedule()});const D=u("widget-close",o.W6.close,(0,U.kg)("widgetClose","Icon for the close action in widgets.")),x=u("goto-previous-location",o.W6.arrowUp,(0,U.kg)("previousChangeIcon","Icon for goto previous editor location.")),A=u("goto-next-location",o.W6.arrowDown,(0,U.kg)("nextChangeIcon","Icon for goto next editor location.")),W=T.L0.modify(o.W6.sync,"spin"),Y=T.L0.modify(o.W6.loading,"spin")},11608:(rt,ye,y)=>{y.d(ye,{GP:()=>L,LM:()=>K,Uv:()=>p,kI:()=>P,nt:()=>$,or:()=>B,qL:()=>U,vo:()=>T});var b=y(16844),o=y(50442);class K{constructor(g,h,l,u){this._viewportBrand=void 0,this.top=g|0,this.left=h|0,this.width=l|0,this.height=u|0}}class ${constructor(g,h){this.tabSize=g,this.data=h}}class L{constructor(g,h,l,u,w,C,m){this._viewLineDataBrand=void 0,this.content=g,this.continuesWithWrappedLine=h,this.minColumn=l,this.maxColumn=u,this.startVisibleColumn=w,this.tokens=C,this.inlineDecorations=m}}class U{constructor(g,h,l,u,w,C,m,v,k,D){this.minColumn=g,this.maxColumn=h,this.content=l,this.continuesWithWrappedLine=u,this.isBasicASCII=U.isBasicASCII(l,C),this.containsRTL=U.containsRTL(l,this.isBasicASCII,w),this.tokens=m,this.inlineDecorations=v,this.tabSize=k,this.startVisibleColumn=D}static isBasicASCII(g,h){return h?b.aC(g):!0}static containsRTL(g,h,l){return!h&&l?b.E_(g):!1}}class P{constructor(g,h,l){this.range=g,this.inlineClassName=h,this.type=l}}class B{constructor(g,h,l,u){this.startOffset=g,this.endOffset=h,this.inlineClassName=l,this.inlineClassNameAffectsLetterSpacing=u}toInlineDecoration(g){return new P(new o.Q(g,this.startOffset+1,g,this.endOffset+1),this.inlineClassName,this.inlineClassNameAffectsLetterSpacing?3:0)}}class T{constructor(g,h){this._viewModelDecorationBrand=void 0,this.range=g,this.options=h}}class p{constructor(g,h,l){this.color=g,this.zIndex=h,this.data=l}static cmp(g,h){return g.zIndex===h.zIndex?g.color<h.color?-1:g.color>h.color?1:0:g.zIndex-h.zIndex}}},12060:(rt,ye,y)=>{y.d(ye,{U:()=>p});var b=y(22344),o=y(27992),K=y(62992),$=y(66726),L=y(82399),U=y(46441),P=y(54435),B=function(l,u,w,C){var m=arguments.length,v=m<3?u:C===null?C=Object.getOwnPropertyDescriptor(u,w):C,k;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")v=Reflect.decorate(l,u,w,C);else for(var D=l.length-1;D>=0;D--)(k=l[D])&&(v=(m<3?k(v):m>3?k(u,w,v):k(u,w))||v);return m>3&&v&&Object.defineProperty(u,w,v),v},T=function(l,u){return function(w,C){u(w,C,l)}};const p=(0,L.u1)("ILanguageFeatureDebounceService");var d;(function(l){const u=new WeakMap;let w=0;function C(m){let v=u.get(m);return v===void 0&&(v=++w,u.set(m,v)),v}l.of=C})(d||(d={}));class g{constructor(u,w,C,m,v,k){this._logService=u,this._name=w,this._registry=C,this._default=m,this._min=v,this._max=k,this._cache=new o.qK(50,.7)}_key(u){return u.id+this._registry.all(u).reduce((w,C)=>(0,b.sN)(d.of(C),w),0)}get(u){const w=this._key(u),C=this._cache.get(w);return C?(0,K.qE)(C.value,this._min,this._max):this.default()}update(u,w){const C=this._key(u);let m=this._cache.get(C);m||(m=new K.mu(6),this._cache.set(C,m));const v=(0,K.qE)(m.update(w),this._min,this._max);return(0,P.v$)(u.uri,"output")||this._logService.trace(`[DEBOUNCE: ${this._name}] for ${u.uri.toString()} is ${v}ms`),v}_overall(){const u=new K.Uq;for(const[,w]of this._cache)u.update(w.value);return u.value}default(){const u=this._overall()|0||this._default;return(0,K.qE)(u,this._min,this._max)}}let h=class{constructor(u){this._logService=u,this._data=new Map}for(u,w,C){var m,v,k;const D=(m=C?.min)!==null&&m!==void 0?m:50,x=(v=C?.max)!==null&&v!==void 0?v:Math.pow(D,2),A=(k=C?.key)!==null&&k!==void 0?k:void 0,W=`${d.of(u)},${D}${A?","+A:""}`;let Y=this._data.get(W);return Y||(Y=new g(this._logService,w,u,this._overallAverage()|0||D*1.5,D,x),this._data.set(W,Y)),Y}_overallAverage(){const u=new K.Uq;for(const w of this._data.values())u.update(w.default());return u.value}};h=B([T(0,U.rr)],h),(0,$.v)(p,h,!0)},12590:(rt,ye,y)=>{y.d(ye,{R:()=>b});const b={tabSize:4,indentSize:4,insertSpaces:!0,detectIndentation:!0,trimAutoWhitespace:!0,largeFileOptimizations:!0,bracketPairColorizationOptions:{enabled:!0,independentColorPoolPerBracketType:!1}}},12596:(rt,ye,y)=>{y.d(ye,{_:()=>b});const b={ICodeEditor:"vs.editor.ICodeEditor",IDiffEditor:"vs.editor.IDiffEditor"}},13034:(rt,ye,y)=>{y.d(ye,{aV:()=>g,nd:()=>U});var b=y(63339),o=y(3765),K=y(96655);const $=new K.N1("isMac",b.zx,(0,o.kg)("isMac","Whether the operating system is macOS")),L=new K.N1("isLinux",b.j9,(0,o.kg)("isLinux","Whether the operating system is Linux")),U=new K.N1("isWindows",b.uF,(0,o.kg)("isWindows","Whether the operating system is Windows")),P=new K.N1("isWeb",b.HZ,(0,o.kg)("isWeb","Whether the platform is a web browser")),B=new K.N1("isMacNative",b.zx&&!b.HZ,(0,o.kg)("isMacNative","Whether the operating system is macOS on a non-browser platform")),T=new K.N1("isIOS",b.un,(0,o.kg)("isIOS","Whether the operating system is iOS")),p=new K.N1("isDevelopment",!1,!0),d=new K.N1("productQualityType","",(0,o.kg)("productQualityType","Quality type of VS Code")),g="inputFocus",h=new K.N1(g,!1,(0,o.kg)("inputFocus","Whether keyboard focus is inside an input box"))},13072:(rt,ye,y)=>{y.d(ye,{Ez:()=>U,ny:()=>K,zl:()=>B});var b=y(63339),o=y(37264),K;(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"})(K||(K={}));const $="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=`/${K.vscodeRemoteResource}`}setPreferredWebSchema(p){this._preferredWebSchema=p}rewrite(p){if(this._delegate)return this._delegate(p);const d=p.authority;let g=this._hosts[d];g&&g.indexOf(":")!==-1&&(g=`[${g}]`);const h=this._ports[d],l=this._connectionTokens[d];let u=`path=${encodeURIComponent(p.path)}`;return typeof l=="string"&&(u+=`&${$}=${encodeURIComponent(l)}`),o.r.from({scheme:b.HZ?this._preferredWebSchema:K.vscodeRemoteResource,authority:`${g}:${h}`,path:this._remoteResourcesPath,query:u})}}const U=new L;class P{asBrowserUri(p,d){const g=this.toUri(p,d);return g.scheme===K.vscodeRemote?U.rewrite(g):g.scheme===K.file&&(b.ib||b.p7&&b.zQ.origin===`${K.vscodeFileResource}://${P.FALLBACK_AUTHORITY}`)?g.with({scheme:K.vscodeFileResource,authority:g.authority||P.FALLBACK_AUTHORITY,query:null,fragment:null}):g}toUri(p,d){return o.r.isUri(p)?p:o.r.parse(d.toUrl(p))}}P.FALLBACK_AUTHORITY="vscode-app";const B=new P},13338:(rt,ye,y)=>{y.d(ye,{$z:()=>T,Ct:()=>d,E4:()=>D,EI:()=>g,El:()=>L,Fy:()=>w,Jw:()=>R,Ly:()=>H,RT:()=>b,SO:()=>B,U9:()=>Q,UH:()=>$,Uk:()=>l,V4:()=>W,VE:()=>j,Yc:()=>p,_A:()=>v,_j:()=>x,aB:()=>P,aI:()=>K,bS:()=>o,dM:()=>h,j3:()=>Z,nK:()=>m,r7:()=>k,vj:()=>X,y1:()=>C});function b(N,G=0){return N[N.length-(1+G)]}function o(N){if(N.length===0)throw new Error("Invalid tail call");return[N.slice(0,N.length-1),N[N.length-1]]}function K(N,G,O=(te,oe)=>te===oe){if(N===G)return!0;if(!N||!G||N.length!==G.length)return!1;for(let te=0,oe=N.length;te<oe;te++)if(!O(N[te],G[te]))return!1;return!0}function $(N,G){const O=N.length-1;G<O&&(N[G]=N[O]),N.pop()}function L(N,G,O){return U(N.length,te=>O(N[te],G))}function U(N,G){let O=0,te=N-1;for(;O<=te;){const oe=(O+te)/2|0,ue=G(oe);if(ue<0)O=oe+1;else if(ue>0)te=oe-1;else return oe}return-(O+1)}function P(N,G){let O=0,te=N.length;if(te===0)return 0;for(;O<te;){const oe=Math.floor((O+te)/2);G(N[oe])?te=oe:O=oe+1}return O}function B(N,G,O){if(N=N|0,N>=G.length)throw new TypeError("invalid index");const te=G[Math.floor(G.length*Math.random())],oe=[],ue=[],E=[];for(const Qe of G){const Ke=O(Qe,te);Ke<0?oe.push(Qe):Ke>0?ue.push(Qe):E.push(Qe)}return N<oe.length?B(N,oe,O):N<oe.length+E.length?E[0]:B(N-(oe.length+E.length),ue,O)}function T(N,G){const O=[];let te;for(const oe of N.slice(0).sort(G))!te||G(te[0],oe)!==0?(te=[oe],O.push(te)):te.push(oe);return O}function p(N){return N.filter(G=>!!G)}function d(N){return!Array.isArray(N)||N.length===0}function g(N){return Array.isArray(N)&&N.length>0}function h(N,G=O=>O){const O=new Set;return N.filter(te=>{const oe=G(te);return O.has(oe)?!1:(O.add(oe),!0)})}function l(N,G){const O=u(N,G);if(O!==-1)return N[O]}function u(N,G){for(let O=N.length-1;O>=0;O--){const te=N[O];if(G(te))return O}return-1}function w(N,G){return N.length>0?N[0]:G}function C(N,G){let O=typeof G=="number"?N:0;typeof G=="number"?O=N:(O=0,G=N);const te=[];if(O<=G)for(let oe=O;oe<G;oe++)te.push(oe);else for(let oe=O;oe>G;oe--)te.push(oe);return te}function m(N,G,O){const te=N.slice(0,G),oe=N.slice(G);return te.concat(O,oe)}function v(N,G){const O=N.indexOf(G);O>-1&&(N.splice(O,1),N.unshift(G))}function k(N,G){const O=N.indexOf(G);O>-1&&(N.splice(O,1),N.push(G))}function D(N,G){for(const O of G)N.push(O)}function x(N){return Array.isArray(N)?N:[N]}function A(N,G,O){const te=Y(N,G),oe=N.length,ue=O.length;N.length=oe+ue;for(let E=oe-1;E>=te;E--)N[E+ue]=N[E];for(let E=0;E<ue;E++)N[E+te]=O[E]}function W(N,G,O,te){const oe=Y(N,G),ue=N.splice(oe,O);return A(N,oe,te),ue}function Y(N,G){return G<0?Math.max(G+N.length,0):Math.min(G,N.length)}var ne;(function(N){function G(oe){return oe<0}N.isLessThan=G;function O(oe){return oe>0}N.isGreaterThan=O;function te(oe){return oe===0}N.isNeitherLessOrGreaterThan=te,N.greaterThan=1,N.lessThan=-1,N.neitherLessOrGreaterThan=0})(ne||(ne={}));function j(N,G){return(O,te)=>G(N(O),N(te))}const Q=(N,G)=>N-G;function X(N,G){if(N.length===0)return;let O=N[0];for(let te=1;te<N.length;te++){const oe=N[te];G(oe,O)>0&&(O=oe)}return O}function R(N,G){if(N.length===0)return;let O=N[0];for(let te=1;te<N.length;te++){const oe=N[te];G(oe,O)>=0&&(O=oe)}return O}function H(N,G){return X(N,(O,te)=>-G(O,te))}class Z{constructor(G){this.items=G,this.firstIdx=0,this.lastIdx=this.items.length-1}get length(){return this.lastIdx-this.firstIdx+1}takeWhile(G){let O=this.firstIdx;for(;O<this.items.length&&G(this.items[O]);)O++;const te=O===this.firstIdx?null:this.items.slice(this.firstIdx,O);return this.firstIdx=O,te}takeFromEndWhile(G){let O=this.lastIdx;for(;O>=0&&G(this.items[O]);)O--;const te=O===this.lastIdx?null:this.items.slice(O+1,this.lastIdx+1);return this.lastIdx=O,te}peek(){if(this.length!==0)return this.items[this.firstIdx]}dequeue(){const G=this.items[this.firstIdx];return this.firstIdx++,G}takeCount(G){const O=this.items.slice(this.firstIdx,this.firstIdx+G);return this.firstIdx+=G,O}}},13377:(rt,ye,y)=>{y.d(ye,{Al:()=>U,Hf:()=>$,_O:()=>L});var b=y(16844),o=y(15365),K=y(50442);const $=!1;class L{constructor(B,T,p,d,g){this.value=B,this.selectionStart=T,this.selectionEnd=p,this.selectionStartPosition=d,this.selectionEndPosition=g}toString(){return`[ <${this.value}>, selectionStart: ${this.selectionStart}, selectionEnd: ${this.selectionEnd}]`}static readFromTextArea(B){return new L(B.getValue(),B.getSelectionStart(),B.getSelectionEnd(),null,null)}collapseSelection(){return new L(this.value,this.value.length,this.value.length,null,null)}writeToTextArea(B,T,p){$&&console.log(`writeToTextArea ${B}: ${this.toString()}`),T.setValue(B,this.value),p&&T.setSelectionRange(B,this.selectionStart,this.selectionEnd)}deduceEditorPosition(B){if(B<=this.selectionStart){const d=this.value.substring(B,this.selectionStart);return this._finishDeduceEditorPosition(this.selectionStartPosition,d,-1)}if(B>=this.selectionEnd){const d=this.value.substring(this.selectionEnd,B);return this._finishDeduceEditorPosition(this.selectionEndPosition,d,1)}const T=this.value.substring(this.selectionStart,B);if(T.indexOf("\u2026")===-1)return this._finishDeduceEditorPosition(this.selectionStartPosition,T,1);const p=this.value.substring(B,this.selectionEnd);return this._finishDeduceEditorPosition(this.selectionEndPosition,p,-1)}_finishDeduceEditorPosition(B,T,p){let d=0,g=-1;for(;(g=T.indexOf(` `,g+1))!==-1;)d++;return[B,p*T.length,d]}static deduceInput(B,T,p){if(!B)return{text:"",replacePrevCharCnt:0,replaceNextCharCnt:0,positionDelta:0};$&&(console.log("------------------------deduceInput"),console.log(`PREVIOUS STATE: ${B.toString()}`),console.log(`CURRENT STATE: ${T.toString()}`));const d=Math.min(b.Qp(B.value,T.value),B.selectionStart,T.selectionStart),g=Math.min(b.Vi(B.value,T.value),B.value.length-B.selectionEnd,T.value.length-T.selectionEnd),h=B.value.substring(d,B.value.length-g),l=T.value.substring(d,T.value.length-g),u=B.selectionStart-d,w=B.selectionEnd-d,C=T.selectionStart-d,m=T.selectionEnd-d;if($&&(console.log(`AFTER DIFFING PREVIOUS STATE: <${h}>, selectionStart: ${u}, selectionEnd: ${w}`),console.log(`AFTER DIFFING CURRENT STATE: <${l}>, selectionStart: ${C}, selectionEnd: ${m}`)),C===m){const k=B.selectionStart-d;return $&&console.log(`REMOVE PREVIOUS: ${k} chars`),{text:l,replacePrevCharCnt:k,replaceNextCharCnt:0,positionDelta:0}}const v=w-u;return{text:l,replacePrevCharCnt:v,replaceNextCharCnt:0,positionDelta:0}}static deduceAndroidCompositionInput(B,T){if(!B)return{text:"",replacePrevCharCnt:0,replaceNextCharCnt:0,positionDelta:0};if($&&(console.log("------------------------deduceAndroidCompositionInput"),console.log(`PREVIOUS STATE: ${B.toString()}`),console.log(`CURRENT STATE: ${T.toString()}`)),B.value===T.value)return{text:"",replacePrevCharCnt:0,replaceNextCharCnt:0,positionDelta:T.selectionEnd-B.selectionEnd};const p=Math.min(b.Qp(B.value,T.value),B.selectionEnd),d=Math.min(b.Vi(B.value,T.value),B.value.length-B.selectionEnd),g=B.value.substring(p,B.value.length-d),h=T.value.substring(p,T.value.length-d),l=B.selectionStart-p,u=B.selectionEnd-p,w=T.selectionStart-p,C=T.selectionEnd-p;return $&&(console.log(`AFTER DIFFING PREVIOUS STATE: <${g}>, selectionStart: ${l}, selectionEnd: ${u}`),console.log(`AFTER DIFFING CURRENT STATE: <${h}>, selectionStart: ${w}, selectionEnd: ${C}`)),{text:h,replacePrevCharCnt:u,replaceNextCharCnt:g.length-u,positionDelta:C-h.length}}}L.EMPTY=new L("",0,0,null,null);class U{static _getPageOfLine(B,T){return Math.floor((B-1)/T)}static _getRangeForPage(B,T){const p=B*T,d=p+1,g=p+T;return new K.Q(d,1,g+1,1)}static fromEditorSelection(B,T,p,d,g){const h=U._getPageOfLine(p.startLineNumber,d),l=U._getRangeForPage(h,d),u=U._getPageOfLine(p.endLineNumber,d),w=U._getRangeForPage(u,d),C=l.intersectRanges(new K.Q(1,1,p.startLineNumber,p.startColumn));let m=T.getValueInRange(C,1);const v=T.getLineCount(),k=T.getLineMaxColumn(v),D=w.intersectRanges(new K.Q(p.endLineNumber,p.endColumn,v,k));let x=T.getValueInRange(D,1),A;if(h===u||h+1===u)A=T.getValueInRange(p,1);else{const W=l.intersectRanges(p),Y=w.intersectRanges(p);A=T.getValueInRange(W,1)+"\u2026"+T.getValueInRange(Y,1)}return g&&(m.length>500&&(m=m.substring(m.length-500,m.length)),x.length>500&&(x=x.substring(0,500)),A.length>2*500&&(A=A.substring(0,500)+"\u2026"+A.substring(A.length-500,A.length))),new L(m+A+x,m.length,m.length+A.length,new o.y(p.startLineNumber,p.startColumn),new o.y(p.endLineNumber,p.endColumn))}}},14333:(rt,ye,y)=>{y.d(ye,{$:()=>Mt,BC:()=>Lt,BK:()=>G,Bx:()=>it,Cl:()=>pe,Di:()=>ze,Ej:()=>N,H4:()=>E,Hs:()=>Rt,L9:()=>Q,Ln:()=>Ie,OK:()=>Qe,Oq:()=>Y,PG:()=>ne,QX:()=>Ke,Tf:()=>Si,Tr:()=>oe,U2:()=>Pe,WU:()=>Yt,Wt:()=>he,XD:()=>Me,Xc:()=>m,Yx:()=>te,a4:()=>fe,b2:()=>C,bq:()=>ge,cL:()=>Z,dl:()=>x,fg:()=>H,fs:()=>ft,h:()=>si,i0:()=>ut,jD:()=>Nt,jG:()=>be,jh:()=>Ii,ko:()=>l,li:()=>ke,m1:()=>Se,mU:()=>O,pN:()=>Et,qD:()=>g,sb:()=>$e,tG:()=>X,vT:()=>Ti,w5:()=>ht,w_:()=>d,wk:()=>tt,y6:()=>ue,yB:()=>Pt,yt:()=>yt,zK:()=>Wt});var b=y(55893),o=y(51577),K=y(87594),$=y(9715),L=y(94327),U=y(2106),P=y(92542),B=y(10998),T=y(13072),p=y(63339);function d(Fe){for(;Fe.firstChild;)Fe.firstChild.remove()}function g(Fe){var Xe;return(Xe=Fe?.isConnected)!==null&&Xe!==void 0?Xe:!1}class h{constructor(Xe,gt,Xt,Vt){this._node=Xe,this._type=gt,this._handler=Xt,this._options=Vt||!1,this._node.addEventListener(this._type,this._handler,this._options)}dispose(){this._handler&&(this._node.removeEventListener(this._type,this._handler,this._options),this._node=null,this._handler=null)}}function l(Fe,Xe,gt,Xt){return new h(Fe,Xe,gt,Xt)}function u(Fe){return function(Xe){return Fe(new $.P(Xe))}}function w(Fe){return function(Xe){return Fe(new K.Z(Xe))}}const C=function(Xe,gt,Xt,Vt){let ni=Xt;return gt==="click"||gt==="mousedown"?ni=u(Xt):(gt==="keydown"||gt==="keypress"||gt==="keyup")&&(ni=w(Xt)),l(Xe,gt,ni,Vt)},m=function(Xe,gt,Xt){const Vt=u(gt);return k(Xe,Vt,Xt)},v=function(Xe,gt,Xt){const Vt=u(gt);return D(Xe,Vt,Xt)};function k(Fe,Xe,gt){return l(Fe,p.un&&o.e.pointerEvents?it.POINTER_DOWN:it.MOUSE_DOWN,Xe,gt)}function D(Fe,Xe,gt){return l(Fe,platform.isIOS&&BrowserFeatures.pointerEvents?it.POINTER_UP:it.MOUSE_UP,Xe,gt)}function x(Fe,Xe,gt){let Xt=null;const Vt=St=>Ri.fire(St),ni=()=>{Xt||(Xt=new h(Fe,Xe,Vt,gt))},vi=()=>{Xt&&(Xt.dispose(),Xt=null)},Ri=new U.vl({onFirstListenerAdd:ni,onLastListenerRemove:vi});return Ri}let A=null;function W(Fe){if(!A){const Xe=gt=>setTimeout(()=>gt(new Date().getTime()),0);A=self.requestAnimationFrame||self.msRequestAnimationFrame||self.webkitRequestAnimationFrame||self.mozRequestAnimationFrame||self.oRequestAnimationFrame||Xe}return A.call(self,Fe)}let Y,ne;class j{constructor(Xe,gt=0){this._runner=Xe,this.priority=gt,this._canceled=!1}dispose(){this._canceled=!0}execute(){if(!this._canceled)try{this._runner()}catch(Xe){(0,L.dz)(Xe)}}static sort(Xe,gt){return gt.priority-Xe.priority}}(function(){let Fe=[],Xe=null,gt=!1,Xt=!1;const Vt=()=>{for(gt=!1,Xe=Fe,Fe=[],Xt=!0;Xe.length>0;)Xe.sort(j.sort),Xe.shift().execute();Xt=!1};ne=(ni,vi=0)=>{const Ri=new j(ni,vi);return Fe.push(Ri),gt||(gt=!0,W(Vt)),Ri},Y=(ni,vi)=>{if(Xt){const Ri=new j(ni,vi);return Xe.push(Ri),Ri}else return ne(ni,vi)}})();function Q(Fe){return document.defaultView.getComputedStyle(Fe,null)}function X(Fe){if(Fe!==document.body)return new H(Fe.clientWidth,Fe.clientHeight);if(p.un&&window.visualViewport)return new H(window.visualViewport.width,window.visualViewport.height);if(window.innerWidth&&window.innerHeight)return new H(window.innerWidth,window.innerHeight);if(document.body&&document.body.clientWidth&&document.body.clientHeight)return new H(document.body.clientWidth,document.body.clientHeight);if(document.documentElement&&document.documentElement.clientWidth&&document.documentElement.clientHeight)return new H(document.documentElement.clientWidth,document.documentElement.clientHeight);throw new Error("Unable to figure out browser width and height")}class R{static convertToPixels(Xe,gt){return parseFloat(gt)||0}static getDimension(Xe,gt,Xt){const Vt=Q(Xe);let ni="0";return Vt&&(Vt.getPropertyValue?ni=Vt.getPropertyValue(gt):ni=Vt.getAttribute(Xt)),R.convertToPixels(Xe,ni)}static getBorderLeftWidth(Xe){return R.getDimension(Xe,"border-left-width","borderLeftWidth")}static getBorderRightWidth(Xe){return R.getDimension(Xe,"border-right-width","borderRightWidth")}static getBorderTopWidth(Xe){return R.getDimension(Xe,"border-top-width","borderTopWidth")}static getBorderBottomWidth(Xe){return R.getDimension(Xe,"border-bottom-width","borderBottomWidth")}static getPaddingLeft(Xe){return R.getDimension(Xe,"padding-left","paddingLeft")}static getPaddingRight(Xe){return R.getDimension(Xe,"padding-right","paddingRight")}static getPaddingTop(Xe){return R.getDimension(Xe,"padding-top","paddingTop")}static getPaddingBottom(Xe){return R.getDimension(Xe,"padding-bottom","paddingBottom")}static getMarginLeft(Xe){return R.getDimension(Xe,"margin-left","marginLeft")}static getMarginTop(Xe){return R.getDimension(Xe,"margin-top","marginTop")}static getMarginRight(Xe){return R.getDimension(Xe,"margin-right","marginRight")}static getMarginBottom(Xe){return R.getDimension(Xe,"margin-bottom","marginBottom")}}class H{constructor(Xe,gt){this.width=Xe,this.height=gt}with(Xe=this.width,gt=this.height){return Xe!==this.width||gt!==this.height?new H(Xe,gt):this}static is(Xe){return typeof Xe=="object"&&typeof Xe.height=="number"&&typeof Xe.width=="number"}static lift(Xe){return Xe instanceof H?Xe:new H(Xe.width,Xe.height)}static equals(Xe,gt){return Xe===gt?!0:!Xe||!gt?!1:Xe.width===gt.width&&Xe.height===gt.height}}H.None=new H(0,0);function Z(Fe){let Xe=Fe.offsetParent,gt=Fe.offsetTop,Xt=Fe.offsetLeft;for(;(Fe=Fe.parentNode)!==null&&Fe!==document.body&&Fe!==document.documentElement;){gt-=Fe.scrollTop;const Vt=ce(Fe)?null:Q(Fe);Vt&&(Xt-=Vt.direction!=="rtl"?Fe.scrollLeft:-Fe.scrollLeft),Fe===Xe&&(Xt+=R.getBorderLeftWidth(Fe),gt+=R.getBorderTopWidth(Fe),gt+=Fe.offsetTop,Xt+=Fe.offsetLeft,Xe=Fe.offsetParent)}return{left:Xt,top:gt}}function N(Fe,Xe,gt){typeof Xe=="number"&&(Fe.style.width=`${Xe}px`),typeof gt=="number"&&(Fe.style.height=`${gt}px`)}function G(Fe){const Xe=Fe.getBoundingClientRect();return{left:Xe.left+te.scrollX,top:Xe.top+te.scrollY,width:Xe.width,height:Xe.height}}function O(Fe){let Xe=Fe,gt=1;do{const Xt=Q(Xe).zoom;Xt!=null&&Xt!=="1"&&(gt*=Xt),Xe=Xe.parentElement}while(Xe!==null&&Xe!==document.documentElement);return gt}const te=new class{get scrollX(){return typeof window.scrollX=="number"?window.scrollX:document.body.scrollLeft+document.documentElement.scrollLeft}get scrollY(){return typeof window.scrollY=="number"?window.scrollY:document.body.scrollTop+document.documentElement.scrollTop}};function oe(Fe){const Xe=R.getMarginLeft(Fe)+R.getMarginRight(Fe);return Fe.offsetWidth+Xe}function ue(Fe){const Xe=R.getBorderLeftWidth(Fe)+R.getBorderRightWidth(Fe),gt=R.getPaddingLeft(Fe)+R.getPaddingRight(Fe);return Fe.offsetWidth-Xe-gt}function E(Fe){const Xe=R.getBorderTopWidth(Fe)+R.getBorderBottomWidth(Fe),gt=R.getPaddingTop(Fe)+R.getPaddingBottom(Fe);return Fe.offsetHeight-Xe-gt}function Qe(Fe){const Xe=R.getMarginTop(Fe)+R.getMarginBottom(Fe);return Fe.offsetHeight+Xe}function Ke(Fe,Xe){for(;Fe;){if(Fe===Xe)return!0;Fe=Fe.parentNode}return!1}function Se(Fe,Xe,gt){for(;Fe&&Fe.nodeType===Fe.ELEMENT_NODE;){if(Fe.classList.contains(Xe))return Fe;if(gt){if(typeof gt=="string"){if(Fe.classList.contains(gt))return null}else if(Fe===gt)return null}Fe=Fe.parentNode}return null}function Me(Fe,Xe,gt){return!!Se(Fe,Xe,gt)}function ce(Fe){return Fe&&!!Fe.host&&!!Fe.mode}function pe(Fe){return!!be(Fe)}function be(Fe){for(;Fe.parentNode;){if(Fe===document.body)return null;Fe=Fe.parentNode}return ce(Fe)?Fe:null}function ge(){let Fe=document.activeElement;for(;Fe?.shadowRoot;)Fe=Fe.shadowRoot.activeElement;return Fe}function ke(Fe=document.getElementsByTagName("head")[0]){const Xe=document.createElement("style");return Xe.type="text/css",Xe.media="screen",Fe.appendChild(Xe),Xe}let We=null;function Ge(){return We||(We=ke()),We}function Ae(Fe){var Xe,gt;return!((Xe=Fe?.sheet)===null||Xe===void 0)&&Xe.rules?Fe.sheet.rules:!((gt=Fe?.sheet)===null||gt===void 0)&>.cssRules?Fe.sheet.cssRules:[]}function he(Fe,Xe,gt=Ge()){!gt||!Xe||gt.sheet.insertRule(Fe+"{"+Xe+"}",0)}function Pe(Fe,Xe=Ge()){if(!Xe)return;const gt=Ae(Xe),Xt=[];for(let Vt=0;Vt<gt.length;Vt++)gt[Vt].selectorText.indexOf(Fe)!==-1&&Xt.push(Vt);for(let Vt=Xt.length-1;Vt>=0;Vt--)Xe.sheet.deleteRule(Xt[Vt])}function $e(Fe){return typeof HTMLElement=="object"?Fe instanceof HTMLElement:Fe&&typeof Fe=="object"&&Fe.nodeType===1&&typeof Fe.nodeName=="string"}const it={CLICK:"click",AUXCLICK:"auxclick",DBLCLICK:"dblclick",MOUSE_UP:"mouseup",MOUSE_DOWN:"mousedown",MOUSE_OVER:"mouseover",MOUSE_MOVE:"mousemove",MOUSE_OUT:"mouseout",MOUSE_ENTER:"mouseenter",MOUSE_LEAVE:"mouseleave",MOUSE_WHEEL:"wheel",POINTER_UP:"pointerup",POINTER_DOWN:"pointerdown",POINTER_MOVE:"pointermove",POINTER_LEAVE:"pointerleave",CONTEXT_MENU:"contextmenu",WHEEL:"wheel",KEY_DOWN:"keydown",KEY_PRESS:"keypress",KEY_UP:"keyup",LOAD:"load",BEFORE_UNLOAD:"beforeunload",UNLOAD:"unload",PAGE_SHOW:"pageshow",PAGE_HIDE:"pagehide",ABORT:"abort",ERROR:"error",RESIZE:"resize",SCROLL:"scroll",FULLSCREEN_CHANGE:"fullscreenchange",WK_FULLSCREEN_CHANGE:"webkitfullscreenchange",SELECT:"select",CHANGE:"change",SUBMIT:"submit",RESET:"reset",FOCUS:"focus",FOCUS_IN:"focusin",FOCUS_OUT:"focusout",BLUR:"blur",INPUT:"input",STORAGE:"storage",DRAG_START:"dragstart",DRAG:"drag",DRAG_ENTER:"dragenter",DRAG_LEAVE:"dragleave",DRAG_OVER:"dragover",DROP:"drop",DRAG_END:"dragend",ANIMATION_START:b.isWebKit?"webkitAnimationStart":"animationstart",ANIMATION_END:b.isWebKit?"webkitAnimationEnd":"animationend",ANIMATION_ITERATION:b.isWebKit?"webkitAnimationIteration":"animationiteration"},ft={stop:function(Fe,Xe){Fe.preventDefault?Fe.preventDefault():Fe.returnValue=!1,Xe&&(Fe.stopPropagation?Fe.stopPropagation():Fe.cancelBubble=!0)}};function Wt(Fe){const Xe=[];for(let gt=0;Fe&&Fe.nodeType===Fe.ELEMENT_NODE;gt++)Xe[gt]=Fe.scrollTop,Fe=Fe.parentNode;return Xe}function tt(Fe,Xe){for(let gt=0;Fe&&Fe.nodeType===Fe.ELEMENT_NODE;gt++)Fe.scrollTop!==Xe[gt]&&(Fe.scrollTop=Xe[gt]),Fe=Fe.parentNode}class Ye extends B.jG{constructor(Xe){super(),this._onDidFocus=this._register(new U.vl),this.onDidFocus=this._onDidFocus.event,this._onDidBlur=this._register(new U.vl),this.onDidBlur=this._onDidBlur.event;let gt=Ye.hasFocusWithin(Xe),Xt=!1;const Vt=()=>{Xt=!1,gt||(gt=!0,this._onDidFocus.fire())},ni=()=>{gt&&(Xt=!0,window.setTimeout(()=>{Xt&&(Xt=!1,gt=!1,this._onDidBlur.fire())},0))};this._refreshStateHandler=()=>{Ye.hasFocusWithin(Xe)!==gt&&(gt?ni():Vt())},this._register(l(Xe,it.FOCUS,Vt,!0)),this._register(l(Xe,it.BLUR,ni,!0)),this._register(l(Xe,it.FOCUS_IN,()=>this._refreshStateHandler())),this._register(l(Xe,it.FOCUS_OUT,()=>this._refreshStateHandler()))}static hasFocusWithin(Xe){const gt=be(Xe),Xt=gt?gt.activeElement:document.activeElement;return Ke(Xt,Xe)}}function ht(Fe){return new Ye(Fe)}function Lt(Fe,...Xe){if(Fe.append(...Xe),Xe.length===1&&typeof Xe[0]!="string")return Xe[0]}function Rt(Fe,Xe){return Fe.insertBefore(Xe,Fe.firstChild),Xe}function Ie(Fe,...Xe){Fe.innerText="",Lt(Fe,...Xe)}const Ve=/([\w\-]+)?(#([\w\-]+))?((\.([\w\-]+))*)/;var dt;(function(Fe){Fe.HTML="http://www.w3.org/1999/xhtml",Fe.SVG="http://www.w3.org/2000/svg"})(dt||(dt={}));function bt(Fe,Xe,gt,...Xt){const Vt=Ve.exec(Xe);if(!Vt)throw new Error("Bad use of emmet");gt=Object.assign({},gt||{});const ni=Vt[1]||"div";let vi;return Fe!==dt.HTML?vi=document.createElementNS(Fe,ni):vi=document.createElement(ni),Vt[3]&&(vi.id=Vt[3]),Vt[4]&&(vi.className=Vt[4].replace(/\./g," ").trim()),Object.keys(gt).forEach(Ri=>{const St=gt[Ri];typeof St>"u"||(/^on\w+$/.test(Ri)?vi[Ri]=St:Ri==="selected"?St&&vi.setAttribute(Ri,"true"):vi.setAttribute(Ri,St))}),vi.append(...Xt),vi}function Mt(Fe,Xe,...gt){return bt(dt.HTML,Fe,Xe,...gt)}Mt.SVG=function(Fe,Xe,...gt){return bt(dt.SVG,Fe,Xe,...gt)};function Yt(...Fe){for(const Xe of Fe)Xe.style.display="",Xe.removeAttribute("aria-hidden")}function Nt(...Fe){for(const Xe of Fe)Xe.style.display="none",Xe.setAttribute("aria-hidden","true")}function Pt(Fe){return Array.prototype.slice.call(document.getElementsByTagName(Fe),0)}function Ti(Fe){const Xe=window.devicePixelRatio*Fe;return Math.max(1,Math.floor(Xe))/window.devicePixelRatio}function Ii(Fe){window.open(Fe,"_blank","noopener")}function ut(Fe){const Xe=()=>{Fe(),gt=ne(Xe)};let gt=ne(Xe);return(0,B.s)(()=>gt.dispose())}T.Ez.setPreferredWebSchema(/^https:/.test(window.location.href)?"https":"http");function Si(Fe){return Fe?`url('${T.zl.asBrowserUri(Fe).toString(!0).replace(/'/g,"%27")}')`:"url('')"}function yt(Fe){return`'${Fe.replace(/'/g,"%27")}'`}function fe(Fe,Xe=!1){const gt=document.createElement("a");return P.$w("afterSanitizeAttributes",Xt=>{for(const Vt of["href","src"])if(Xt.hasAttribute(Vt)){const ni=Xt.getAttribute(Vt);if(Vt==="href"&&ni.startsWith("#"))continue;if(gt.href=ni,!Fe.includes(gt.protocol.replace(/:$/,""))){if(Xe&&Vt==="src"&>.href.startsWith("data:"))continue;Xt.removeAttribute(Vt)}}}),(0,B.s)(()=>{P.SV("afterSanitizeAttributes")})}class ze extends U.vl{constructor(){super(),this._subscriptions=new B.Cm,this._keyStatus={altKey:!1,shiftKey:!1,ctrlKey:!1,metaKey:!1},this._subscriptions.add(l(window,"keydown",Xe=>{if(Xe.defaultPrevented)return;const gt=new K.Z(Xe);if(!(gt.keyCode===6&&Xe.repeat)){if(Xe.altKey&&!this._keyStatus.altKey)this._keyStatus.lastKeyPressed="alt";else if(Xe.ctrlKey&&!this._keyStatus.ctrlKey)this._keyStatus.lastKeyPressed="ctrl";else if(Xe.metaKey&&!this._keyStatus.metaKey)this._keyStatus.lastKeyPressed="meta";else if(Xe.shiftKey&&!this._keyStatus.shiftKey)this._keyStatus.lastKeyPressed="shift";else if(gt.keyCode!==6)this._keyStatus.lastKeyPressed=void 0;else return;this._keyStatus.altKey=Xe.altKey,this._keyStatus.ctrlKey=Xe.ctrlKey,this._keyStatus.metaKey=Xe.metaKey,this._keyStatus.shiftKey=Xe.shiftKey,this._keyStatus.lastKeyPressed&&(this._keyStatus.event=Xe,this.fire(this._keyStatus))}},!0)),this._subscriptions.add(l(window,"keyup",Xe=>{Xe.defaultPrevented||(!Xe.altKey&&this._keyStatus.altKey?this._keyStatus.lastKeyReleased="alt":!Xe.ctrlKey&&this._keyStatus.ctrlKey?this._keyStatus.lastKeyReleased="ctrl":!Xe.metaKey&&this._keyStatus.metaKey?this._keyStatus.lastKeyReleased="meta":!Xe.shiftKey&&this._keyStatus.shiftKey?this._keyStatus.lastKeyReleased="shift":this._keyStatus.lastKeyReleased=void 0,this._keyStatus.lastKeyPressed!==this._keyStatus.lastKeyReleased&&(this._keyStatus.lastKeyPressed=void 0),this._keyStatus.altKey=Xe.altKey,this._keyStatus.ctrlKey=Xe.ctrlKey,this._keyStatus.metaKey=Xe.metaKey,this._keyStatus.shiftKey=Xe.shiftKey,this._keyStatus.lastKeyReleased&&(this._keyStatus.event=Xe,this.fire(this._keyStatus)))},!0)),this._subscriptions.add(l(document.body,"mousedown",()=>{this._keyStatus.lastKeyPressed=void 0},!0)),this._subscriptions.add(l(document.body,"mouseup",()=>{this._keyStatus.lastKeyPressed=void 0},!0)),this._subscriptions.add(l(document.body,"mousemove",Xe=>{Xe.buttons&&(this._keyStatus.lastKeyPressed=void 0)},!0)),this._subscriptions.add(l(window,"blur",()=>{this.resetKeyStatus()}))}get keyStatus(){return this._keyStatus}resetKeyStatus(){this.doResetKeyStatus(),this.fire(this._keyStatus)}doResetKeyStatus(){this._keyStatus={altKey:!1,shiftKey:!1,ctrlKey:!1,metaKey:!1}}static getInstance(){return ze.instance||(ze.instance=new ze),ze.instance}dispose(){super.dispose(),this._subscriptions.dispose()}}class Et extends B.jG{constructor(Xe,gt){super(),this.element=Xe,this.callbacks=gt,this.counter=0,this.dragStartTime=0,this.registerListeners()}registerListeners(){this._register(l(this.element,it.DRAG_ENTER,Xe=>{this.counter++,this.dragStartTime=Xe.timeStamp,this.callbacks.onDragEnter(Xe)})),this._register(l(this.element,it.DRAG_OVER,Xe=>{var gt,Xt;Xe.preventDefault(),(Xt=(gt=this.callbacks).onDragOver)===null||Xt===void 0||Xt.call(gt,Xe,Xe.timeStamp-this.dragStartTime)})),this._register(l(this.element,it.DRAG_LEAVE,Xe=>{this.counter--,this.counter===0&&(this.dragStartTime=0,this.callbacks.onDragLeave(Xe))})),this._register(l(this.element,it.DRAG_END,Xe=>{this.counter=0,this.dragStartTime=0,this.callbacks.onDragEnd(Xe)})),this._register(l(this.element,it.DROP,Xe=>{this.counter=0,this.dragStartTime=0,this.callbacks.onDrop(Xe)}))}}const Ot=/(?<tag>[\w\-]+)?(?:#(?<id>[\w\-]+))?(?<class>(?:\.(?:[\w\-]+))*)(?:@(?<name>(?:[\w\_])+))?/;function si(Fe,...Xe){let gt,Xt;Array.isArray(Xe[0])?(gt={},Xt=Xe[0]):(gt=Xe[0]||{},Xt=Xe[1]);const Vt=Ot.exec(Fe);if(!Vt||!Vt.groups)throw new Error("Bad use of h");const ni=Vt.groups.tag||"div",vi=document.createElement(ni);Vt.groups.id&&(vi.id=Vt.groups.id),Vt.groups.class&&(vi.className=Vt.groups.class.replace(/\./g," ").trim());const Ri={};if(Vt.groups.name&&(Ri[Vt.groups.name]=vi),Xt)for(const St of Xt)St instanceof HTMLElement?vi.appendChild(St):typeof St=="string"?vi.append(St):(Object.assign(Ri,St),vi.appendChild(St.root));for(const[St,ve]of Object.entries(gt))if(St==="style")for(const[Te,je]of Object.entries(ve))vi.style.setProperty(_i(Te),typeof je=="number"?je+"px":""+je);else St==="tabIndex"?vi.tabIndex=ve:vi.setAttribute(_i(St),ve.toString());return Ri.root=vi,Ri}function _i(Fe){return Fe.replace(/([a-z])([A-Z])/g,"$1-$2").toLowerCase()}},15910:(rt,ye,y)=>{y.d(ye,{x:()=>b});class b{static getLanguageId(K){return(K&255)>>>0}static getTokenType(K){return(K&768)>>>8}static containsBalancedBrackets(K){return(K&1024)!==0}static getFontStyle(K){return(K&30720)>>>11}static getForeground(K){return(K&16744448)>>>15}static getBackground(K){return(K&4278190080)>>>24}static getClassNameFromMetadata(K){let L="mtk"+this.getForeground(K);const U=this.getFontStyle(K);return U&1&&(L+=" mtki"),U&2&&(L+=" mtkb"),U&4&&(L+=" mtku"),U&8&&(L+=" mtks"),L}static getInlineStyleFromMetadata(K,$){const L=this.getForeground(K),U=this.getFontStyle(K);let P=`color: ${$[L]};`;U&1&&(P+="font-style: italic;"),U&2&&(P+="font-weight: bold;");let B="";return U&4&&(B+=" underline"),U&8&&(B+=" line-through"),B&&(P+=`text-decoration:${B};`),P}static getPresentationFromMetadata(K){const $=this.getForeground(K),L=this.getFontStyle(K);return{foreground:$,italic:!!(L&1),bold:!!(L&2),underline:!!(L&4),strikethrough:!!(L&8)}}}},16844:(rt,ye,y)=>{y.d(ye,{$X:()=>ge,AV:()=>$,BO:()=>d,Bm:()=>g,Bq:()=>T,DB:()=>Y,E_:()=>Me,GP:()=>U,HG:()=>m,LJ:()=>N,LU:()=>Ae,Lv:()=>ne,MV:()=>Qe,NB:()=>p,OS:()=>l,Q_:()=>Q,Qp:()=>R,RH:()=>w,S8:()=>ht,Ss:()=>We,UD:()=>D,UU:()=>v,Vi:()=>H,W1:()=>A,Wd:()=>Wt,Wv:()=>j,Z5:()=>O,_J:()=>be,aC:()=>pe,bm:()=>B,eY:()=>u,ih:()=>P,iy:()=>E,km:()=>ue,lF:()=>x,lT:()=>k,m:()=>Ke,ne:()=>ke,ns:()=>X,pc:()=>Z,r_:()=>Ge,tk:()=>Pe,tl:()=>Lt,uz:()=>C,wB:()=>h,y_:()=>Rt,zY:()=>he,z_:()=>G,zd:()=>W});var b=y(36260),o=y(63946),K;function $(Ie){return!Ie||typeof Ie!="string"?!0:Ie.trim().length===0}const L=/{(\d+)}/g;function U(Ie,...Ve){return Ve.length===0?Ie:Ie.replace(L,function(dt,bt){const Mt=parseInt(bt,10);return isNaN(Mt)||Mt<0||Mt>=Ve.length?dt:Ve[Mt]})}function P(Ie){return Ie.replace(/[<>&]/g,function(Ve){switch(Ve){case"<":return"<";case">":return">";case"&":return"&";default:return Ve}})}function B(Ie){return Ie.replace(/[\\\{\}\*\+\?\|\^\$\.\[\]\(\)]/g,"\\$&")}function T(Ie,Ve=" "){const dt=p(Ie,Ve);return d(dt,Ve)}function p(Ie,Ve){if(!Ie||!Ve)return Ie;const dt=Ve.length;if(dt===0||Ie.length===0)return Ie;let bt=0;for(;Ie.indexOf(Ve,bt)===bt;)bt=bt+dt;return Ie.substring(bt)}function d(Ie,Ve){if(!Ie||!Ve)return Ie;const dt=Ve.length,bt=Ie.length;if(dt===0||bt===0)return Ie;let Mt=bt,Yt=-1;for(;Yt=Ie.lastIndexOf(Ve,Mt-1),!(Yt===-1||Yt+dt!==Mt);){if(Yt===0)return"";Mt=Yt}return Ie.substring(0,Mt)}function g(Ie){return Ie.replace(/[\-\\\{\}\+\?\|\^\$\.\,\[\]\(\)\#\s]/g,"\\$&").replace(/[\*]/g,".*")}function h(Ie){return Ie.replace(/\*/g,"")}function l(Ie,Ve,dt={}){if(!Ie)throw new Error("Cannot create regex from empty string");Ve||(Ie=B(Ie)),dt.wholeWord&&(/\B/.test(Ie.charAt(0))||(Ie="\\b"+Ie),/\B/.test(Ie.charAt(Ie.length-1))||(Ie=Ie+"\\b"));let bt="";return dt.global&&(bt+="g"),dt.matchCase||(bt+="i"),dt.multiline&&(bt+="m"),dt.unicode&&(bt+="u"),new RegExp(Ie,bt)}function u(Ie){return Ie.source==="^"||Ie.source==="^$"||Ie.source==="$"||Ie.source==="^\\s*$"?!1:!!(Ie.exec("")&&Ie.lastIndex===0)}function w(Ie){return(Ie.global?"g":"")+(Ie.ignoreCase?"i":"")+(Ie.multiline?"m":"")+(Ie.unicode?"u":"")}function C(Ie){return Ie.split(/\r\n|\r|\n/)}function m(Ie){for(let Ve=0,dt=Ie.length;Ve<dt;Ve++){const bt=Ie.charCodeAt(Ve);if(bt!==32&&bt!==9)return Ve}return-1}function v(Ie,Ve=0,dt=Ie.length){for(let bt=Ve;bt<dt;bt++){const Mt=Ie.charCodeAt(bt);if(Mt!==32&&Mt!==9)return Ie.substring(Ve,bt)}return Ie.substring(Ve,dt)}function k(Ie,Ve=Ie.length-1){for(let dt=Ve;dt>=0;dt--){const bt=Ie.charCodeAt(dt);if(bt!==32&&bt!==9)return dt}return-1}function D(Ie,Ve){return Ie<Ve?-1:Ie>Ve?1:0}function x(Ie,Ve,dt=0,bt=Ie.length,Mt=0,Yt=Ve.length){for(;dt<bt&&Mt<Yt;dt++,Mt++){const Ti=Ie.charCodeAt(dt),Ii=Ve.charCodeAt(Mt);if(Ti<Ii)return-1;if(Ti>Ii)return 1}const Nt=bt-dt,Pt=Yt-Mt;return Nt<Pt?-1:Nt>Pt?1:0}function A(Ie,Ve){return W(Ie,Ve,0,Ie.length,0,Ve.length)}function W(Ie,Ve,dt=0,bt=Ie.length,Mt=0,Yt=Ve.length){for(;dt<bt&&Mt<Yt;dt++,Mt++){let Ti=Ie.charCodeAt(dt),Ii=Ve.charCodeAt(Mt);if(Ti===Ii)continue;if(Ti>=128||Ii>=128)return x(Ie.toLowerCase(),Ve.toLowerCase(),dt,bt,Mt,Yt);ne(Ti)&&(Ti-=32),ne(Ii)&&(Ii-=32);const ut=Ti-Ii;if(ut!==0)return ut}const Nt=bt-dt,Pt=Yt-Mt;return Nt<Pt?-1:Nt>Pt?1:0}function Y(Ie){return Ie>=48&&Ie<=57}function ne(Ie){return Ie>=97&&Ie<=122}function j(Ie){return Ie>=65&&Ie<=90}function Q(Ie,Ve){return Ie.length===Ve.length&&W(Ie,Ve)===0}function X(Ie,Ve){const dt=Ve.length;return Ve.length>Ie.length?!1:W(Ie,Ve,0,dt)===0}function R(Ie,Ve){const dt=Math.min(Ie.length,Ve.length);let bt;for(bt=0;bt<dt;bt++)if(Ie.charCodeAt(bt)!==Ve.charCodeAt(bt))return bt;return dt}function H(Ie,Ve){const dt=Math.min(Ie.length,Ve.length);let bt;const Mt=Ie.length-1,Yt=Ve.length-1;for(bt=0;bt<dt;bt++)if(Ie.charCodeAt(Mt-bt)!==Ve.charCodeAt(Yt-bt))return bt;return dt}function Z(Ie){return 55296<=Ie&&Ie<=56319}function N(Ie){return 56320<=Ie&&Ie<=57343}function G(Ie,Ve){return(Ie-55296<<10)+(Ve-56320)+65536}function O(Ie,Ve,dt){const bt=Ie.charCodeAt(dt);if(Z(bt)&&dt+1<Ve){const Mt=Ie.charCodeAt(dt+1);if(N(Mt))return G(bt,Mt)}return bt}function te(Ie,Ve){const dt=Ie.charCodeAt(Ve-1);if(N(dt)&&Ve>1){const bt=Ie.charCodeAt(Ve-2);if(Z(bt))return G(bt,dt)}return dt}class oe{constructor(Ve,dt=0){this._str=Ve,this._len=Ve.length,this._offset=dt}get offset(){return this._offset}setOffset(Ve){this._offset=Ve}prevCodePoint(){const Ve=te(this._str,this._offset);return this._offset-=Ve>=65536?2:1,Ve}nextCodePoint(){const Ve=O(this._str,this._len,this._offset);return this._offset+=Ve>=65536?2:1,Ve}eol(){return this._offset>=this._len}}class ue{constructor(Ve,dt=0){this._iterator=new oe(Ve,dt)}get offset(){return this._iterator.offset}nextGraphemeLength(){const Ve=it.getInstance(),dt=this._iterator,bt=dt.offset;let Mt=Ve.getGraphemeBreakType(dt.nextCodePoint());for(;!dt.eol();){const Yt=dt.offset,Nt=Ve.getGraphemeBreakType(dt.nextCodePoint());if($e(Mt,Nt)){dt.setOffset(Yt);break}Mt=Nt}return dt.offset-bt}prevGraphemeLength(){const Ve=it.getInstance(),dt=this._iterator,bt=dt.offset;let Mt=Ve.getGraphemeBreakType(dt.prevCodePoint());for(;dt.offset>0;){const Yt=dt.offset,Nt=Ve.getGraphemeBreakType(dt.prevCodePoint());if($e(Nt,Mt)){dt.setOffset(Yt);break}Mt=Nt}return bt-dt.offset}eol(){return this._iterator.eol()}}function E(Ie,Ve){return new ue(Ie,Ve).nextGraphemeLength()}function Qe(Ie,Ve){return new ue(Ie,Ve).prevGraphemeLength()}function Ke(Ie,Ve){Ve>0&&N(Ie.charCodeAt(Ve))&&Ve--;const dt=Ve+E(Ie,Ve);return[dt-Qe(Ie,dt),dt]}const Se=/(?:[\u05BE\u05C0\u05C3\u05C6\u05D0-\u05F4\u0608\u060B\u060D\u061B-\u064A\u066D-\u066F\u0671-\u06D5\u06E5\u06E6\u06EE\u06EF\u06FA-\u0710\u0712-\u072F\u074D-\u07A5\u07B1-\u07EA\u07F4\u07F5\u07FA\u07FE-\u0815\u081A\u0824\u0828\u0830-\u0858\u085E-\u088E\u08A0-\u08C9\u200F\uFB1D\uFB1F-\uFB28\uFB2A-\uFD3D\uFD50-\uFDC7\uFDF0-\uFDFC\uFE70-\uFEFC]|\uD802[\uDC00-\uDD1B\uDD20-\uDE00\uDE10-\uDE35\uDE40-\uDEE4\uDEEB-\uDF35\uDF40-\uDFFF]|\uD803[\uDC00-\uDD23\uDE80-\uDEA9\uDEAD-\uDF45\uDF51-\uDF81\uDF86-\uDFF6]|\uD83A[\uDC00-\uDCCF\uDD00-\uDD43\uDD4B-\uDFFF]|\uD83B[\uDC00-\uDEBB])/;function Me(Ie){return Se.test(Ie)}const ce=/^[\t\n\r\x20-\x7E]*$/;function pe(Ie){return ce.test(Ie)}const be=/[\u2028\u2029]/;function ge(Ie){return be.test(Ie)}function ke(Ie){return Ie>=11904&&Ie<=55215||Ie>=63744&&Ie<=64255||Ie>=65281&&Ie<=65374}function We(Ie){return Ie>=127462&&Ie<=127487||Ie===8986||Ie===8987||Ie===9200||Ie===9203||Ie>=9728&&Ie<=10175||Ie===11088||Ie===11093||Ie>=127744&&Ie<=128591||Ie>=128640&&Ie<=128764||Ie>=128992&&Ie<=129008||Ie>=129280&&Ie<=129535||Ie>=129648&&Ie<=129782}const Ge="\uFEFF";function Ae(Ie){return!!(Ie&&Ie.length>0&&Ie.charCodeAt(0)===65279)}function he(Ie,Ve=!1){return Ie?(Ve&&(Ie=Ie.replace(/\\./g,"")),Ie.toLowerCase()!==Ie):!1}function Pe(Ie){return Ie=Ie%52,Ie<26?String.fromCharCode(97+Ie):String.fromCharCode(65+Ie-26)}function $e(Ie,Ve){return Ie===0?Ve!==5&&Ve!==7:Ie===2&&Ve===3?!1:Ie===4||Ie===2||Ie===3||Ve===4||Ve===2||Ve===3?!0:!(Ie===8&&(Ve===8||Ve===9||Ve===11||Ve===12)||(Ie===11||Ie===9)&&(Ve===9||Ve===10)||(Ie===12||Ie===10)&&Ve===10||Ve===5||Ve===13||Ve===7||Ie===1||Ie===13&&Ve===14||Ie===6&&Ve===6)}class it{constructor(){this._data=ft()}static getInstance(){return it._INSTANCE||(it._INSTANCE=new it),it._INSTANCE}getGraphemeBreakType(Ve){if(Ve<32)return Ve===10?3:Ve===13?2:4;if(Ve<127)return 0;const dt=this._data,bt=dt.length/3;let Mt=1;for(;Mt<=bt;)if(Ve<dt[3*Mt])Mt=2*Mt;else if(Ve>dt[3*Mt+1])Mt=2*Mt+1;else return dt[3*Mt+2];return 0}}it._INSTANCE=null;function ft(){return JSON.parse("[0,0,0,51229,51255,12,44061,44087,12,127462,127487,6,7083,7085,5,47645,47671,12,54813,54839,12,128678,128678,14,3270,3270,5,9919,9923,14,45853,45879,12,49437,49463,12,53021,53047,12,71216,71218,7,128398,128399,14,129360,129374,14,2519,2519,5,4448,4519,9,9742,9742,14,12336,12336,14,44957,44983,12,46749,46775,12,48541,48567,12,50333,50359,12,52125,52151,12,53917,53943,12,69888,69890,5,73018,73018,5,127990,127990,14,128558,128559,14,128759,128760,14,129653,129655,14,2027,2035,5,2891,2892,7,3761,3761,5,6683,6683,5,8293,8293,4,9825,9826,14,9999,9999,14,43452,43453,5,44509,44535,12,45405,45431,12,46301,46327,12,47197,47223,12,48093,48119,12,48989,49015,12,49885,49911,12,50781,50807,12,51677,51703,12,52573,52599,12,53469,53495,12,54365,54391,12,65279,65279,4,70471,70472,7,72145,72147,7,119173,119179,5,127799,127818,14,128240,128244,14,128512,128512,14,128652,128652,14,128721,128722,14,129292,129292,14,129445,129450,14,129734,129743,14,1476,1477,5,2366,2368,7,2750,2752,7,3076,3076,5,3415,3415,5,4141,4144,5,6109,6109,5,6964,6964,5,7394,7400,5,9197,9198,14,9770,9770,14,9877,9877,14,9968,9969,14,10084,10084,14,43052,43052,5,43713,43713,5,44285,44311,12,44733,44759,12,45181,45207,12,45629,45655,12,46077,46103,12,46525,46551,12,46973,46999,12,47421,47447,12,47869,47895,12,48317,48343,12,48765,48791,12,49213,49239,12,49661,49687,12,50109,50135,12,50557,50583,12,51005,51031,12,51453,51479,12,51901,51927,12,52349,52375,12,52797,52823,12,53245,53271,12,53693,53719,12,54141,54167,12,54589,54615,12,55037,55063,12,69506,69509,5,70191,70193,5,70841,70841,7,71463,71467,5,72330,72342,5,94031,94031,5,123628,123631,5,127763,127765,14,127941,127941,14,128043,128062,14,128302,128317,14,128465,128467,14,128539,128539,14,128640,128640,14,128662,128662,14,128703,128703,14,128745,128745,14,129004,129007,14,129329,129330,14,129402,129402,14,129483,129483,14,129686,129704,14,130048,131069,14,173,173,4,1757,1757,1,2200,2207,5,2434,2435,7,2631,2632,5,2817,2817,5,3008,3008,5,3201,3201,5,3387,3388,5,3542,3542,5,3902,3903,7,4190,4192,5,6002,6003,5,6439,6440,5,6765,6770,7,7019,7027,5,7154,7155,7,8205,8205,13,8505,8505,14,9654,9654,14,9757,9757,14,9792,9792,14,9852,9853,14,9890,9894,14,9937,9937,14,9981,9981,14,10035,10036,14,11035,11036,14,42654,42655,5,43346,43347,7,43587,43587,5,44006,44007,7,44173,44199,12,44397,44423,12,44621,44647,12,44845,44871,12,45069,45095,12,45293,45319,12,45517,45543,12,45741,45767,12,45965,45991,12,46189,46215,12,46413,46439,12,46637,46663,12,46861,46887,12,47085,47111,12,47309,47335,12,47533,47559,12,47757,47783,12,47981,48007,12,48205,48231,12,48429,48455,12,48653,48679,12,48877,48903,12,49101,49127,12,49325,49351,12,49549,49575,12,49773,49799,12,49997,50023,12,50221,50247,12,50445,50471,12,50669,50695,12,50893,50919,12,51117,51143,12,51341,51367,12,51565,51591,12,51789,51815,12,52013,52039,12,52237,52263,12,52461,52487,12,52685,52711,12,52909,52935,12,53133,53159,12,53357,53383,12,53581,53607,12,53805,53831,12,54029,54055,12,54253,54279,12,54477,54503,12,54701,54727,12,54925,54951,12,55149,55175,12,68101,68102,5,69762,69762,7,70067,70069,7,70371,70378,5,70720,70721,7,71087,71087,5,71341,71341,5,71995,71996,5,72249,72249,7,72850,72871,5,73109,73109,5,118576,118598,5,121505,121519,5,127245,127247,14,127568,127569,14,127777,127777,14,127872,127891,14,127956,127967,14,128015,128016,14,128110,128172,14,128259,128259,14,128367,128368,14,128424,128424,14,128488,128488,14,128530,128532,14,128550,128551,14,128566,128566,14,128647,128647,14,128656,128656,14,128667,128673,14,128691,128693,14,128715,128715,14,128728,128732,14,128752,128752,14,128765,128767,14,129096,129103,14,129311,129311,14,129344,129349,14,129394,129394,14,129413,129425,14,129466,129471,14,129511,129535,14,129664,129666,14,129719,129722,14,129760,129767,14,917536,917631,5,13,13,2,1160,1161,5,1564,1564,4,1807,1807,1,2085,2087,5,2307,2307,7,2382,2383,7,2497,2500,5,2563,2563,7,2677,2677,5,2763,2764,7,2879,2879,5,2914,2915,5,3021,3021,5,3142,3144,5,3263,3263,5,3285,3286,5,3398,3400,7,3530,3530,5,3633,3633,5,3864,3865,5,3974,3975,5,4155,4156,7,4229,4230,5,5909,5909,7,6078,6085,7,6277,6278,5,6451,6456,7,6744,6750,5,6846,6846,5,6972,6972,5,7074,7077,5,7146,7148,7,7222,7223,5,7416,7417,5,8234,8238,4,8417,8417,5,9000,9000,14,9203,9203,14,9730,9731,14,9748,9749,14,9762,9763,14,9776,9783,14,9800,9811,14,9831,9831,14,9872,9873,14,9882,9882,14,9900,9903,14,9929,9933,14,9941,9960,14,9974,9974,14,9989,9989,14,10006,10006,14,10062,10062,14,10160,10160,14,11647,11647,5,12953,12953,14,43019,43019,5,43232,43249,5,43443,43443,5,43567,43568,7,43696,43696,5,43765,43765,7,44013,44013,5,44117,44143,12,44229,44255,12,44341,44367,12,44453,44479,12,44565,44591,12,44677,44703,12,44789,44815,12,44901,44927,12,45013,45039,12,45125,45151,12,45237,45263,12,45349,45375,12,45461,45487,12,45573,45599,12,45685,45711,12,45797,45823,12,45909,45935,12,46021,46047,12,46133,46159,12,46245,46271,12,46357,46383,12,46469,46495,12,46581,46607,12,46693,46719,12,46805,46831,12,46917,46943,12,47029,47055,12,47141,47167,12,47253,47279,12,47365,47391,12,47477,47503,12,47589,47615,12,47701,47727,12,47813,47839,12,47925,47951,12,48037,48063,12,48149,48175,12,48261,48287,12,48373,48399,12,48485,48511,12,48597,48623,12,48709,48735,12,48821,48847,12,48933,48959,12,49045,49071,12,49157,49183,12,49269,49295,12,49381,49407,12,49493,49519,12,49605,49631,12,49717,49743,12,49829,49855,12,49941,49967,12,50053,50079,12,50165,50191,12,50277,50303,12,50389,50415,12,50501,50527,12,50613,50639,12,50725,50751,12,50837,50863,12,50949,50975,12,51061,51087,12,51173,51199,12,51285,51311,12,51397,51423,12,51509,51535,12,51621,51647,12,51733,51759,12,51845,51871,12,51957,51983,12,52069,52095,12,52181,52207,12,52293,52319,12,52405,52431,12,52517,52543,12,52629,52655,12,52741,52767,12,52853,52879,12,52965,52991,12,53077,53103,12,53189,53215,12,53301,53327,12,53413,53439,12,53525,53551,12,53637,53663,12,53749,53775,12,53861,53887,12,53973,53999,12,54085,54111,12,54197,54223,12,54309,54335,12,54421,54447,12,54533,54559,12,54645,54671,12,54757,54783,12,54869,54895,12,54981,55007,12,55093,55119,12,55243,55291,10,66045,66045,5,68325,68326,5,69688,69702,5,69817,69818,5,69957,69958,7,70089,70092,5,70198,70199,5,70462,70462,5,70502,70508,5,70750,70750,5,70846,70846,7,71100,71101,5,71230,71230,7,71351,71351,5,71737,71738,5,72000,72000,7,72160,72160,5,72273,72278,5,72752,72758,5,72882,72883,5,73031,73031,5,73461,73462,7,94192,94193,7,119149,119149,7,121403,121452,5,122915,122916,5,126980,126980,14,127358,127359,14,127535,127535,14,127759,127759,14,127771,127771,14,127792,127793,14,127825,127867,14,127897,127899,14,127945,127945,14,127985,127986,14,128000,128007,14,128021,128021,14,128066,128100,14,128184,128235,14,128249,128252,14,128266,128276,14,128335,128335,14,128379,128390,14,128407,128419,14,128444,128444,14,128481,128481,14,128499,128499,14,128526,128526,14,128536,128536,14,128543,128543,14,128556,128556,14,128564,128564,14,128577,128580,14,128643,128645,14,128649,128649,14,128654,128654,14,128660,128660,14,128664,128664,14,128675,128675,14,128686,128689,14,128695,128696,14,128705,128709,14,128717,128719,14,128725,128725,14,128736,128741,14,128747,128748,14,128755,128755,14,128762,128762,14,128981,128991,14,129009,129023,14,129160,129167,14,129296,129304,14,129320,129327,14,129340,129342,14,129356,129356,14,129388,129392,14,129399,129400,14,129404,129407,14,129432,129442,14,129454,129455,14,129473,129474,14,129485,129487,14,129648,129651,14,129659,129660,14,129671,129679,14,129709,129711,14,129728,129730,14,129751,129753,14,129776,129782,14,917505,917505,4,917760,917999,5,10,10,3,127,159,4,768,879,5,1471,1471,5,1536,1541,1,1648,1648,5,1767,1768,5,1840,1866,5,2070,2073,5,2137,2139,5,2274,2274,1,2363,2363,7,2377,2380,7,2402,2403,5,2494,2494,5,2507,2508,7,2558,2558,5,2622,2624,7,2641,2641,5,2691,2691,7,2759,2760,5,2786,2787,5,2876,2876,5,2881,2884,5,2901,2902,5,3006,3006,5,3014,3016,7,3072,3072,5,3134,3136,5,3157,3158,5,3260,3260,5,3266,3266,5,3274,3275,7,3328,3329,5,3391,3392,7,3405,3405,5,3457,3457,5,3536,3537,7,3551,3551,5,3636,3642,5,3764,3772,5,3895,3895,5,3967,3967,7,3993,4028,5,4146,4151,5,4182,4183,7,4226,4226,5,4253,4253,5,4957,4959,5,5940,5940,7,6070,6070,7,6087,6088,7,6158,6158,4,6432,6434,5,6448,6449,7,6679,6680,5,6742,6742,5,6754,6754,5,6783,6783,5,6912,6915,5,6966,6970,5,6978,6978,5,7042,7042,7,7080,7081,5,7143,7143,7,7150,7150,7,7212,7219,5,7380,7392,5,7412,7412,5,8203,8203,4,8232,8232,4,8265,8265,14,8400,8412,5,8421,8432,5,8617,8618,14,9167,9167,14,9200,9200,14,9410,9410,14,9723,9726,14,9733,9733,14,9745,9745,14,9752,9752,14,9760,9760,14,9766,9766,14,9774,9774,14,9786,9786,14,9794,9794,14,9823,9823,14,9828,9828,14,9833,9850,14,9855,9855,14,9875,9875,14,9880,9880,14,9885,9887,14,9896,9897,14,9906,9916,14,9926,9927,14,9935,9935,14,9939,9939,14,9962,9962,14,9972,9972,14,9978,9978,14,9986,9986,14,9997,9997,14,10002,10002,14,10017,10017,14,10055,10055,14,10071,10071,14,10133,10135,14,10548,10549,14,11093,11093,14,12330,12333,5,12441,12442,5,42608,42610,5,43010,43010,5,43045,43046,5,43188,43203,7,43302,43309,5,43392,43394,5,43446,43449,5,43493,43493,5,43571,43572,7,43597,43597,7,43703,43704,5,43756,43757,5,44003,44004,7,44009,44010,7,44033,44059,12,44089,44115,12,44145,44171,12,44201,44227,12,44257,44283,12,44313,44339,12,44369,44395,12,44425,44451,12,44481,44507,12,44537,44563,12,44593,44619,12,44649,44675,12,44705,44731,12,44761,44787,12,44817,44843,12,44873,44899,12,44929,44955,12,44985,45011,12,45041,45067,12,45097,45123,12,45153,45179,12,45209,45235,12,45265,45291,12,45321,45347,12,45377,45403,12,45433,45459,12,45489,45515,12,45545,45571,12,45601,45627,12,45657,45683,12,45713,45739,12,45769,45795,12,45825,45851,12,45881,45907,12,45937,45963,12,45993,46019,12,46049,46075,12,46105,46131,12,46161,46187,12,46217,46243,12,46273,46299,12,46329,46355,12,46385,46411,12,46441,46467,12,46497,46523,12,46553,46579,12,46609,46635,12,46665,46691,12,46721,46747,12,46777,46803,12,46833,46859,12,46889,46915,12,46945,46971,12,47001,47027,12,47057,47083,12,47113,47139,12,47169,47195,12,47225,47251,12,47281,47307,12,47337,47363,12,47393,47419,12,47449,47475,12,47505,47531,12,47561,47587,12,47617,47643,12,47673,47699,12,47729,47755,12,47785,47811,12,47841,47867,12,47897,47923,12,47953,47979,12,48009,48035,12,48065,48091,12,48121,48147,12,48177,48203,12,48233,48259,12,48289,48315,12,48345,48371,12,48401,48427,12,48457,48483,12,48513,48539,12,48569,48595,12,48625,48651,12,48681,48707,12,48737,48763,12,48793,48819,12,48849,48875,12,48905,48931,12,48961,48987,12,49017,49043,12,49073,49099,12,49129,49155,12,49185,49211,12,49241,49267,12,49297,49323,12,49353,49379,12,49409,49435,12,49465,49491,12,49521,49547,12,49577,49603,12,49633,49659,12,49689,49715,12,49745,49771,12,49801,49827,12,49857,49883,12,49913,49939,12,49969,49995,12,50025,50051,12,50081,50107,12,50137,50163,12,50193,50219,12,50249,50275,12,50305,50331,12,50361,50387,12,50417,50443,12,50473,50499,12,50529,50555,12,50585,50611,12,50641,50667,12,50697,50723,12,50753,50779,12,50809,50835,12,50865,50891,12,50921,50947,12,50977,51003,12,51033,51059,12,51089,51115,12,51145,51171,12,51201,51227,12,51257,51283,12,51313,51339,12,51369,51395,12,51425,51451,12,51481,51507,12,51537,51563,12,51593,51619,12,51649,51675,12,51705,51731,12,51761,51787,12,51817,51843,12,51873,51899,12,51929,51955,12,51985,52011,12,52041,52067,12,52097,52123,12,52153,52179,12,52209,52235,12,52265,52291,12,52321,52347,12,52377,52403,12,52433,52459,12,52489,52515,12,52545,52571,12,52601,52627,12,52657,52683,12,52713,52739,12,52769,52795,12,52825,52851,12,52881,52907,12,52937,52963,12,52993,53019,12,53049,53075,12,53105,53131,12,53161,53187,12,53217,53243,12,53273,53299,12,53329,53355,12,53385,53411,12,53441,53467,12,53497,53523,12,53553,53579,12,53609,53635,12,53665,53691,12,53721,53747,12,53777,53803,12,53833,53859,12,53889,53915,12,53945,53971,12,54001,54027,12,54057,54083,12,54113,54139,12,54169,54195,12,54225,54251,12,54281,54307,12,54337,54363,12,54393,54419,12,54449,54475,12,54505,54531,12,54561,54587,12,54617,54643,12,54673,54699,12,54729,54755,12,54785,54811,12,54841,54867,12,54897,54923,12,54953,54979,12,55009,55035,12,55065,55091,12,55121,55147,12,55177,55203,12,65024,65039,5,65520,65528,4,66422,66426,5,68152,68154,5,69291,69292,5,69633,69633,5,69747,69748,5,69811,69814,5,69826,69826,5,69932,69932,7,70016,70017,5,70079,70080,7,70095,70095,5,70196,70196,5,70367,70367,5,70402,70403,7,70464,70464,5,70487,70487,5,70709,70711,7,70725,70725,7,70833,70834,7,70843,70844,7,70849,70849,7,71090,71093,5,71103,71104,5,71227,71228,7,71339,71339,5,71344,71349,5,71458,71461,5,71727,71735,5,71985,71989,7,71998,71998,5,72002,72002,7,72154,72155,5,72193,72202,5,72251,72254,5,72281,72283,5,72344,72345,5,72766,72766,7,72874,72880,5,72885,72886,5,73023,73029,5,73104,73105,5,73111,73111,5,92912,92916,5,94095,94098,5,113824,113827,4,119142,119142,7,119155,119162,4,119362,119364,5,121476,121476,5,122888,122904,5,123184,123190,5,125252,125258,5,127183,127183,14,127340,127343,14,127377,127386,14,127491,127503,14,127548,127551,14,127744,127756,14,127761,127761,14,127769,127769,14,127773,127774,14,127780,127788,14,127796,127797,14,127820,127823,14,127869,127869,14,127894,127895,14,127902,127903,14,127943,127943,14,127947,127950,14,127972,127972,14,127988,127988,14,127992,127994,14,128009,128011,14,128019,128019,14,128023,128041,14,128064,128064,14,128102,128107,14,128174,128181,14,128238,128238,14,128246,128247,14,128254,128254,14,128264,128264,14,128278,128299,14,128329,128330,14,128348,128359,14,128371,128377,14,128392,128393,14,128401,128404,14,128421,128421,14,128433,128434,14,128450,128452,14,128476,128478,14,128483,128483,14,128495,128495,14,128506,128506,14,128519,128520,14,128528,128528,14,128534,128534,14,128538,128538,14,128540,128542,14,128544,128549,14,128552,128555,14,128557,128557,14,128560,128563,14,128565,128565,14,128567,128576,14,128581,128591,14,128641,128642,14,128646,128646,14,128648,128648,14,128650,128651,14,128653,128653,14,128655,128655,14,128657,128659,14,128661,128661,14,128663,128663,14,128665,128666,14,128674,128674,14,128676,128677,14,128679,128685,14,128690,128690,14,128694,128694,14,128697,128702,14,128704,128704,14,128710,128714,14,128716,128716,14,128720,128720,14,128723,128724,14,128726,128727,14,128733,128735,14,128742,128744,14,128746,128746,14,128749,128751,14,128753,128754,14,128756,128758,14,128761,128761,14,128763,128764,14,128884,128895,14,128992,129003,14,129008,129008,14,129036,129039,14,129114,129119,14,129198,129279,14,129293,129295,14,129305,129310,14,129312,129319,14,129328,129328,14,129331,129338,14,129343,129343,14,129351,129355,14,129357,129359,14,129375,129387,14,129393,129393,14,129395,129398,14,129401,129401,14,129403,129403,14,129408,129412,14,129426,129431,14,129443,129444,14,129451,129453,14,129456,129465,14,129472,129472,14,129475,129482,14,129484,129484,14,129488,129510,14,129536,129647,14,129652,129652,14,129656,129658,14,129661,129663,14,129667,129670,14,129680,129685,14,129705,129708,14,129712,129718,14,129723,129727,14,129731,129733,14,129744,129750,14,129754,129759,14,129768,129775,14,129783,129791,14,917504,917504,4,917506,917535,4,917632,917759,4,918000,921599,4,0,9,4,11,12,4,14,31,4,169,169,14,174,174,14,1155,1159,5,1425,1469,5,1473,1474,5,1479,1479,5,1552,1562,5,1611,1631,5,1750,1756,5,1759,1764,5,1770,1773,5,1809,1809,5,1958,1968,5,2045,2045,5,2075,2083,5,2089,2093,5,2192,2193,1,2250,2273,5,2275,2306,5,2362,2362,5,2364,2364,5,2369,2376,5,2381,2381,5,2385,2391,5,2433,2433,5,2492,2492,5,2495,2496,7,2503,2504,7,2509,2509,5,2530,2531,5,2561,2562,5,2620,2620,5,2625,2626,5,2635,2637,5,2672,2673,5,2689,2690,5,2748,2748,5,2753,2757,5,2761,2761,7,2765,2765,5,2810,2815,5,2818,2819,7,2878,2878,5,2880,2880,7,2887,2888,7,2893,2893,5,2903,2903,5,2946,2946,5,3007,3007,7,3009,3010,7,3018,3020,7,3031,3031,5,3073,3075,7,3132,3132,5,3137,3140,7,3146,3149,5,3170,3171,5,3202,3203,7,3262,3262,7,3264,3265,7,3267,3268,7,3271,3272,7,3276,3277,5,3298,3299,5,3330,3331,7,3390,3390,5,3393,3396,5,3402,3404,7,3406,3406,1,3426,3427,5,3458,3459,7,3535,3535,5,3538,3540,5,3544,3550,7,3570,3571,7,3635,3635,7,3655,3662,5,3763,3763,7,3784,3789,5,3893,3893,5,3897,3897,5,3953,3966,5,3968,3972,5,3981,3991,5,4038,4038,5,4145,4145,7,4153,4154,5,4157,4158,5,4184,4185,5,4209,4212,5,4228,4228,7,4237,4237,5,4352,4447,8,4520,4607,10,5906,5908,5,5938,5939,5,5970,5971,5,6068,6069,5,6071,6077,5,6086,6086,5,6089,6099,5,6155,6157,5,6159,6159,5,6313,6313,5,6435,6438,7,6441,6443,7,6450,6450,5,6457,6459,5,6681,6682,7,6741,6741,7,6743,6743,7,6752,6752,5,6757,6764,5,6771,6780,5,6832,6845,5,6847,6862,5,6916,6916,7,6965,6965,5,6971,6971,7,6973,6977,7,6979,6980,7,7040,7041,5,7073,7073,7,7078,7079,7,7082,7082,7,7142,7142,5,7144,7145,5,7149,7149,5,7151,7153,5,7204,7211,7,7220,7221,7,7376,7378,5,7393,7393,7,7405,7405,5,7415,7415,7,7616,7679,5,8204,8204,5,8206,8207,4,8233,8233,4,8252,8252,14,8288,8292,4,8294,8303,4,8413,8416,5,8418,8420,5,8482,8482,14,8596,8601,14,8986,8987,14,9096,9096,14,9193,9196,14,9199,9199,14,9201,9202,14,9208,9210,14,9642,9643,14,9664,9664,14,9728,9729,14,9732,9732,14,9735,9741,14,9743,9744,14,9746,9746,14,9750,9751,14,9753,9756,14,9758,9759,14,9761,9761,14,9764,9765,14,9767,9769,14,9771,9773,14,9775,9775,14,9784,9785,14,9787,9791,14,9793,9793,14,9795,9799,14,9812,9822,14,9824,9824,14,9827,9827,14,9829,9830,14,9832,9832,14,9851,9851,14,9854,9854,14,9856,9861,14,9874,9874,14,9876,9876,14,9878,9879,14,9881,9881,14,9883,9884,14,9888,9889,14,9895,9895,14,9898,9899,14,9904,9905,14,9917,9918,14,9924,9925,14,9928,9928,14,9934,9934,14,9936,9936,14,9938,9938,14,9940,9940,14,9961,9961,14,9963,9967,14,9970,9971,14,9973,9973,14,9975,9977,14,9979,9980,14,9982,9985,14,9987,9988,14,9992,9996,14,9998,9998,14,10000,10001,14,10004,10004,14,10013,10013,14,10024,10024,14,10052,10052,14,10060,10060,14,10067,10069,14,10083,10083,14,10085,10087,14,10145,10145,14,10175,10175,14,11013,11015,14,11088,11088,14,11503,11505,5,11744,11775,5,12334,12335,5,12349,12349,14,12951,12951,14,42607,42607,5,42612,42621,5,42736,42737,5,43014,43014,5,43043,43044,7,43047,43047,7,43136,43137,7,43204,43205,5,43263,43263,5,43335,43345,5,43360,43388,8,43395,43395,7,43444,43445,7,43450,43451,7,43454,43456,7,43561,43566,5,43569,43570,5,43573,43574,5,43596,43596,5,43644,43644,5,43698,43700,5,43710,43711,5,43755,43755,7,43758,43759,7,43766,43766,5,44005,44005,5,44008,44008,5,44012,44012,7,44032,44032,11,44060,44060,11,44088,44088,11,44116,44116,11,44144,44144,11,44172,44172,11,44200,44200,11,44228,44228,11,44256,44256,11,44284,44284,11,44312,44312,11,44340,44340,11,44368,44368,11,44396,44396,11,44424,44424,11,44452,44452,11,44480,44480,11,44508,44508,11,44536,44536,11,44564,44564,11,44592,44592,11,44620,44620,11,44648,44648,11,44676,44676,11,44704,44704,11,44732,44732,11,44760,44760,11,44788,44788,11,44816,44816,11,44844,44844,11,44872,44872,11,44900,44900,11,44928,44928,11,44956,44956,11,44984,44984,11,45012,45012,11,45040,45040,11,45068,45068,11,45096,45096,11,45124,45124,11,45152,45152,11,45180,45180,11,45208,45208,11,45236,45236,11,45264,45264,11,45292,45292,11,45320,45320,11,45348,45348,11,45376,45376,11,45404,45404,11,45432,45432,11,45460,45460,11,45488,45488,11,45516,45516,11,45544,45544,11,45572,45572,11,45600,45600,11,45628,45628,11,45656,45656,11,45684,45684,11,45712,45712,11,45740,45740,11,45768,45768,11,45796,45796,11,45824,45824,11,45852,45852,11,45880,45880,11,45908,45908,11,45936,45936,11,45964,45964,11,45992,45992,11,46020,46020,11,46048,46048,11,46076,46076,11,46104,46104,11,46132,46132,11,46160,46160,11,46188,46188,11,46216,46216,11,46244,46244,11,46272,46272,11,46300,46300,11,46328,46328,11,46356,46356,11,46384,46384,11,46412,46412,11,46440,46440,11,46468,46468,11,46496,46496,11,46524,46524,11,46552,46552,11,46580,46580,11,46608,46608,11,46636,46636,11,46664,46664,11,46692,46692,11,46720,46720,11,46748,46748,11,46776,46776,11,46804,46804,11,46832,46832,11,46860,46860,11,46888,46888,11,46916,46916,11,46944,46944,11,46972,46972,11,47000,47000,11,47028,47028,11,47056,47056,11,47084,47084,11,47112,47112,11,47140,47140,11,47168,47168,11,47196,47196,11,47224,47224,11,47252,47252,11,47280,47280,11,47308,47308,11,47336,47336,11,47364,47364,11,47392,47392,11,47420,47420,11,47448,47448,11,47476,47476,11,47504,47504,11,47532,47532,11,47560,47560,11,47588,47588,11,47616,47616,11,47644,47644,11,47672,47672,11,47700,47700,11,47728,47728,11,47756,47756,11,47784,47784,11,47812,47812,11,47840,47840,11,47868,47868,11,47896,47896,11,47924,47924,11,47952,47952,11,47980,47980,11,48008,48008,11,48036,48036,11,48064,48064,11,48092,48092,11,48120,48120,11,48148,48148,11,48176,48176,11,48204,48204,11,48232,48232,11,48260,48260,11,48288,48288,11,48316,48316,11,48344,48344,11,48372,48372,11,48400,48400,11,48428,48428,11,48456,48456,11,48484,48484,11,48512,48512,11,48540,48540,11,48568,48568,11,48596,48596,11,48624,48624,11,48652,48652,11,48680,48680,11,48708,48708,11,48736,48736,11,48764,48764,11,48792,48792,11,48820,48820,11,48848,48848,11,48876,48876,11,48904,48904,11,48932,48932,11,48960,48960,11,48988,48988,11,49016,49016,11,49044,49044,11,49072,49072,11,49100,49100,11,49128,49128,11,49156,49156,11,49184,49184,11,49212,49212,11,49240,49240,11,49268,49268,11,49296,49296,11,49324,49324,11,49352,49352,11,49380,49380,11,49408,49408,11,49436,49436,11,49464,49464,11,49492,49492,11,49520,49520,11,49548,49548,11,49576,49576,11,49604,49604,11,49632,49632,11,49660,49660,11,49688,49688,11,49716,49716,11,49744,49744,11,49772,49772,11,49800,49800,11,49828,49828,11,49856,49856,11,49884,49884,11,49912,49912,11,49940,49940,11,49968,49968,11,49996,49996,11,50024,50024,11,50052,50052,11,50080,50080,11,50108,50108,11,50136,50136,11,50164,50164,11,50192,50192,11,50220,50220,11,50248,50248,11,50276,50276,11,50304,50304,11,50332,50332,11,50360,50360,11,50388,50388,11,50416,50416,11,50444,50444,11,50472,50472,11,50500,50500,11,50528,50528,11,50556,50556,11,50584,50584,11,50612,50612,11,50640,50640,11,50668,50668,11,50696,50696,11,50724,50724,11,50752,50752,11,50780,50780,11,50808,50808,11,50836,50836,11,50864,50864,11,50892,50892,11,50920,50920,11,50948,50948,11,50976,50976,11,51004,51004,11,51032,51032,11,51060,51060,11,51088,51088,11,51116,51116,11,51144,51144,11,51172,51172,11,51200,51200,11,51228,51228,11,51256,51256,11,51284,51284,11,51312,51312,11,51340,51340,11,51368,51368,11,51396,51396,11,51424,51424,11,51452,51452,11,51480,51480,11,51508,51508,11,51536,51536,11,51564,51564,11,51592,51592,11,51620,51620,11,51648,51648,11,51676,51676,11,51704,51704,11,51732,51732,11,51760,51760,11,51788,51788,11,51816,51816,11,51844,51844,11,51872,51872,11,51900,51900,11,51928,51928,11,51956,51956,11,51984,51984,11,52012,52012,11,52040,52040,11,52068,52068,11,52096,52096,11,52124,52124,11,52152,52152,11,52180,52180,11,52208,52208,11,52236,52236,11,52264,52264,11,52292,52292,11,52320,52320,11,52348,52348,11,52376,52376,11,52404,52404,11,52432,52432,11,52460,52460,11,52488,52488,11,52516,52516,11,52544,52544,11,52572,52572,11,52600,52600,11,52628,52628,11,52656,52656,11,52684,52684,11,52712,52712,11,52740,52740,11,52768,52768,11,52796,52796,11,52824,52824,11,52852,52852,11,52880,52880,11,52908,52908,11,52936,52936,11,52964,52964,11,52992,52992,11,53020,53020,11,53048,53048,11,53076,53076,11,53104,53104,11,53132,53132,11,53160,53160,11,53188,53188,11,53216,53216,11,53244,53244,11,53272,53272,11,53300,53300,11,53328,53328,11,53356,53356,11,53384,53384,11,53412,53412,11,53440,53440,11,53468,53468,11,53496,53496,11,53524,53524,11,53552,53552,11,53580,53580,11,53608,53608,11,53636,53636,11,53664,53664,11,53692,53692,11,53720,53720,11,53748,53748,11,53776,53776,11,53804,53804,11,53832,53832,11,53860,53860,11,53888,53888,11,53916,53916,11,53944,53944,11,53972,53972,11,54000,54000,11,54028,54028,11,54056,54056,11,54084,54084,11,54112,54112,11,54140,54140,11,54168,54168,11,54196,54196,11,54224,54224,11,54252,54252,11,54280,54280,11,54308,54308,11,54336,54336,11,54364,54364,11,54392,54392,11,54420,54420,11,54448,54448,11,54476,54476,11,54504,54504,11,54532,54532,11,54560,54560,11,54588,54588,11,54616,54616,11,54644,54644,11,54672,54672,11,54700,54700,11,54728,54728,11,54756,54756,11,54784,54784,11,54812,54812,11,54840,54840,11,54868,54868,11,54896,54896,11,54924,54924,11,54952,54952,11,54980,54980,11,55008,55008,11,55036,55036,11,55064,55064,11,55092,55092,11,55120,55120,11,55148,55148,11,55176,55176,11,55216,55238,9,64286,64286,5,65056,65071,5,65438,65439,5,65529,65531,4,66272,66272,5,68097,68099,5,68108,68111,5,68159,68159,5,68900,68903,5,69446,69456,5,69632,69632,7,69634,69634,7,69744,69744,5,69759,69761,5,69808,69810,7,69815,69816,7,69821,69821,1,69837,69837,1,69927,69931,5,69933,69940,5,70003,70003,5,70018,70018,7,70070,70078,5,70082,70083,1,70094,70094,7,70188,70190,7,70194,70195,7,70197,70197,7,70206,70206,5,70368,70370,7,70400,70401,5,70459,70460,5,70463,70463,7,70465,70468,7,70475,70477,7,70498,70499,7,70512,70516,5,70712,70719,5,70722,70724,5,70726,70726,5,70832,70832,5,70835,70840,5,70842,70842,5,70845,70845,5,70847,70848,5,70850,70851,5,71088,71089,7,71096,71099,7,71102,71102,7,71132,71133,5,71219,71226,5,71229,71229,5,71231,71232,5,71340,71340,7,71342,71343,7,71350,71350,7,71453,71455,5,71462,71462,7,71724,71726,7,71736,71736,7,71984,71984,5,71991,71992,7,71997,71997,7,71999,71999,1,72001,72001,1,72003,72003,5,72148,72151,5,72156,72159,7,72164,72164,7,72243,72248,5,72250,72250,1,72263,72263,5,72279,72280,7,72324,72329,1,72343,72343,7,72751,72751,7,72760,72765,5,72767,72767,5,72873,72873,7,72881,72881,7,72884,72884,7,73009,73014,5,73020,73021,5,73030,73030,1,73098,73102,7,73107,73108,7,73110,73110,7,73459,73460,5,78896,78904,4,92976,92982,5,94033,94087,7,94180,94180,5,113821,113822,5,118528,118573,5,119141,119141,5,119143,119145,5,119150,119154,5,119163,119170,5,119210,119213,5,121344,121398,5,121461,121461,5,121499,121503,5,122880,122886,5,122907,122913,5,122918,122922,5,123566,123566,5,125136,125142,5,126976,126979,14,126981,127182,14,127184,127231,14,127279,127279,14,127344,127345,14,127374,127374,14,127405,127461,14,127489,127490,14,127514,127514,14,127538,127546,14,127561,127567,14,127570,127743,14,127757,127758,14,127760,127760,14,127762,127762,14,127766,127768,14,127770,127770,14,127772,127772,14,127775,127776,14,127778,127779,14,127789,127791,14,127794,127795,14,127798,127798,14,127819,127819,14,127824,127824,14,127868,127868,14,127870,127871,14,127892,127893,14,127896,127896,14,127900,127901,14,127904,127940,14,127942,127942,14,127944,127944,14,127946,127946,14,127951,127955,14,127968,127971,14,127973,127984,14,127987,127987,14,127989,127989,14,127991,127991,14,127995,127999,5,128008,128008,14,128012,128014,14,128017,128018,14,128020,128020,14,128022,128022,14,128042,128042,14,128063,128063,14,128065,128065,14,128101,128101,14,128108,128109,14,128173,128173,14,128182,128183,14,128236,128237,14,128239,128239,14,128245,128245,14,128248,128248,14,128253,128253,14,128255,128258,14,128260,128263,14,128265,128265,14,128277,128277,14,128300,128301,14,128326,128328,14,128331,128334,14,128336,128347,14,128360,128366,14,128369,128370,14,128378,128378,14,128391,128391,14,128394,128397,14,128400,128400,14,128405,128406,14,128420,128420,14,128422,128423,14,128425,128432,14,128435,128443,14,128445,128449,14,128453,128464,14,128468,128475,14,128479,128480,14,128482,128482,14,128484,128487,14,128489,128494,14,128496,128498,14,128500,128505,14,128507,128511,14,128513,128518,14,128521,128525,14,128527,128527,14,128529,128529,14,128533,128533,14,128535,128535,14,128537,128537,14]")}function Wt(Ie,Ve){if(Ie===0)return 0;const dt=tt(Ie,Ve);if(dt!==void 0)return dt;const bt=new oe(Ve,Ie);return bt.prevCodePoint(),bt.offset}function tt(Ie,Ve){const dt=new oe(Ve,Ie);let bt=dt.prevCodePoint();for(;Ye(bt)||bt===65039||bt===8419;){if(dt.offset===0)return;bt=dt.prevCodePoint()}if(!We(bt))return;let Mt=dt.offset;return Mt>0&&dt.prevCodePoint()===8205&&(Mt=dt.offset),Mt}function Ye(Ie){return 127995<=Ie&&Ie<=127999}const ht="\xA0";class Lt{constructor(Ve){this.confusableDictionary=Ve}static getInstance(Ve){return Lt.cache.get(Array.from(Ve))}static getLocales(){return Lt._locales.getValue()}isAmbiguous(Ve){return this.confusableDictionary.has(Ve)}getPrimaryConfusable(Ve){return this.confusableDictionary.get(Ve)}getConfusableCodePoints(){return new Set(this.confusableDictionary.keys())}}K=Lt,Lt.ambiguousCharacterData=new o.d(()=>JSON.parse('{"_common":[8232,32,8233,32,5760,32,8192,32,8193,32,8194,32,8195,32,8196,32,8197,32,8198,32,8200,32,8201,32,8202,32,8287,32,8199,32,8239,32,2042,95,65101,95,65102,95,65103,95,8208,45,8209,45,8210,45,65112,45,1748,45,8259,45,727,45,8722,45,10134,45,11450,45,1549,44,1643,44,8218,44,184,44,42233,44,894,59,2307,58,2691,58,1417,58,1795,58,1796,58,5868,58,65072,58,6147,58,6153,58,8282,58,1475,58,760,58,42889,58,8758,58,720,58,42237,58,451,33,11601,33,660,63,577,63,2429,63,5038,63,42731,63,119149,46,8228,46,1793,46,1794,46,42510,46,68176,46,1632,46,1776,46,42232,46,1373,96,65287,96,8219,96,8242,96,1370,96,1523,96,8175,96,65344,96,900,96,8189,96,8125,96,8127,96,8190,96,697,96,884,96,712,96,714,96,715,96,756,96,699,96,701,96,700,96,702,96,42892,96,1497,96,2036,96,2037,96,5194,96,5836,96,94033,96,94034,96,65339,91,10088,40,10098,40,12308,40,64830,40,65341,93,10089,41,10099,41,12309,41,64831,41,10100,123,119060,123,10101,125,65342,94,8270,42,1645,42,8727,42,66335,42,5941,47,8257,47,8725,47,8260,47,9585,47,10187,47,10744,47,119354,47,12755,47,12339,47,11462,47,20031,47,12035,47,65340,92,65128,92,8726,92,10189,92,10741,92,10745,92,119311,92,119355,92,12756,92,20022,92,12034,92,42872,38,708,94,710,94,5869,43,10133,43,66203,43,8249,60,10094,60,706,60,119350,60,5176,60,5810,60,5120,61,11840,61,12448,61,42239,61,8250,62,10095,62,707,62,119351,62,5171,62,94015,62,8275,126,732,126,8128,126,8764,126,65372,124,65293,45,120784,50,120794,50,120804,50,120814,50,120824,50,130034,50,42842,50,423,50,1000,50,42564,50,5311,50,42735,50,119302,51,120785,51,120795,51,120805,51,120815,51,120825,51,130035,51,42923,51,540,51,439,51,42858,51,11468,51,1248,51,94011,51,71882,51,120786,52,120796,52,120806,52,120816,52,120826,52,130036,52,5070,52,71855,52,120787,53,120797,53,120807,53,120817,53,120827,53,130037,53,444,53,71867,53,120788,54,120798,54,120808,54,120818,54,120828,54,130038,54,11474,54,5102,54,71893,54,119314,55,120789,55,120799,55,120809,55,120819,55,120829,55,130039,55,66770,55,71878,55,2819,56,2538,56,2666,56,125131,56,120790,56,120800,56,120810,56,120820,56,120830,56,130040,56,547,56,546,56,66330,56,2663,57,2920,57,2541,57,3437,57,120791,57,120801,57,120811,57,120821,57,120831,57,130041,57,42862,57,11466,57,71884,57,71852,57,71894,57,9082,97,65345,97,119834,97,119886,97,119938,97,119990,97,120042,97,120094,97,120146,97,120198,97,120250,97,120302,97,120354,97,120406,97,120458,97,593,97,945,97,120514,97,120572,97,120630,97,120688,97,120746,97,65313,65,119808,65,119860,65,119912,65,119964,65,120016,65,120068,65,120120,65,120172,65,120224,65,120276,65,120328,65,120380,65,120432,65,913,65,120488,65,120546,65,120604,65,120662,65,120720,65,5034,65,5573,65,42222,65,94016,65,66208,65,119835,98,119887,98,119939,98,119991,98,120043,98,120095,98,120147,98,120199,98,120251,98,120303,98,120355,98,120407,98,120459,98,388,98,5071,98,5234,98,5551,98,65314,66,8492,66,119809,66,119861,66,119913,66,120017,66,120069,66,120121,66,120173,66,120225,66,120277,66,120329,66,120381,66,120433,66,42932,66,914,66,120489,66,120547,66,120605,66,120663,66,120721,66,5108,66,5623,66,42192,66,66178,66,66209,66,66305,66,65347,99,8573,99,119836,99,119888,99,119940,99,119992,99,120044,99,120096,99,120148,99,120200,99,120252,99,120304,99,120356,99,120408,99,120460,99,7428,99,1010,99,11429,99,43951,99,66621,99,128844,67,71922,67,71913,67,65315,67,8557,67,8450,67,8493,67,119810,67,119862,67,119914,67,119966,67,120018,67,120174,67,120226,67,120278,67,120330,67,120382,67,120434,67,1017,67,11428,67,5087,67,42202,67,66210,67,66306,67,66581,67,66844,67,8574,100,8518,100,119837,100,119889,100,119941,100,119993,100,120045,100,120097,100,120149,100,120201,100,120253,100,120305,100,120357,100,120409,100,120461,100,1281,100,5095,100,5231,100,42194,100,8558,68,8517,68,119811,68,119863,68,119915,68,119967,68,120019,68,120071,68,120123,68,120175,68,120227,68,120279,68,120331,68,120383,68,120435,68,5024,68,5598,68,5610,68,42195,68,8494,101,65349,101,8495,101,8519,101,119838,101,119890,101,119942,101,120046,101,120098,101,120150,101,120202,101,120254,101,120306,101,120358,101,120410,101,120462,101,43826,101,1213,101,8959,69,65317,69,8496,69,119812,69,119864,69,119916,69,120020,69,120072,69,120124,69,120176,69,120228,69,120280,69,120332,69,120384,69,120436,69,917,69,120492,69,120550,69,120608,69,120666,69,120724,69,11577,69,5036,69,42224,69,71846,69,71854,69,66182,69,119839,102,119891,102,119943,102,119995,102,120047,102,120099,102,120151,102,120203,102,120255,102,120307,102,120359,102,120411,102,120463,102,43829,102,42905,102,383,102,7837,102,1412,102,119315,70,8497,70,119813,70,119865,70,119917,70,120021,70,120073,70,120125,70,120177,70,120229,70,120281,70,120333,70,120385,70,120437,70,42904,70,988,70,120778,70,5556,70,42205,70,71874,70,71842,70,66183,70,66213,70,66853,70,65351,103,8458,103,119840,103,119892,103,119944,103,120048,103,120100,103,120152,103,120204,103,120256,103,120308,103,120360,103,120412,103,120464,103,609,103,7555,103,397,103,1409,103,119814,71,119866,71,119918,71,119970,71,120022,71,120074,71,120126,71,120178,71,120230,71,120282,71,120334,71,120386,71,120438,71,1292,71,5056,71,5107,71,42198,71,65352,104,8462,104,119841,104,119945,104,119997,104,120049,104,120101,104,120153,104,120205,104,120257,104,120309,104,120361,104,120413,104,120465,104,1211,104,1392,104,5058,104,65320,72,8459,72,8460,72,8461,72,119815,72,119867,72,119919,72,120023,72,120179,72,120231,72,120283,72,120335,72,120387,72,120439,72,919,72,120494,72,120552,72,120610,72,120668,72,120726,72,11406,72,5051,72,5500,72,42215,72,66255,72,731,105,9075,105,65353,105,8560,105,8505,105,8520,105,119842,105,119894,105,119946,105,119998,105,120050,105,120102,105,120154,105,120206,105,120258,105,120310,105,120362,105,120414,105,120466,105,120484,105,618,105,617,105,953,105,8126,105,890,105,120522,105,120580,105,120638,105,120696,105,120754,105,1110,105,42567,105,1231,105,43893,105,5029,105,71875,105,65354,106,8521,106,119843,106,119895,106,119947,106,119999,106,120051,106,120103,106,120155,106,120207,106,120259,106,120311,106,120363,106,120415,106,120467,106,1011,106,1112,106,65322,74,119817,74,119869,74,119921,74,119973,74,120025,74,120077,74,120129,74,120181,74,120233,74,120285,74,120337,74,120389,74,120441,74,42930,74,895,74,1032,74,5035,74,5261,74,42201,74,119844,107,119896,107,119948,107,120000,107,120052,107,120104,107,120156,107,120208,107,120260,107,120312,107,120364,107,120416,107,120468,107,8490,75,65323,75,119818,75,119870,75,119922,75,119974,75,120026,75,120078,75,120130,75,120182,75,120234,75,120286,75,120338,75,120390,75,120442,75,922,75,120497,75,120555,75,120613,75,120671,75,120729,75,11412,75,5094,75,5845,75,42199,75,66840,75,1472,108,8739,73,9213,73,65512,73,1633,108,1777,73,66336,108,125127,108,120783,73,120793,73,120803,73,120813,73,120823,73,130033,73,65321,73,8544,73,8464,73,8465,73,119816,73,119868,73,119920,73,120024,73,120128,73,120180,73,120232,73,120284,73,120336,73,120388,73,120440,73,65356,108,8572,73,8467,108,119845,108,119897,108,119949,108,120001,108,120053,108,120105,73,120157,73,120209,73,120261,73,120313,73,120365,73,120417,73,120469,73,448,73,120496,73,120554,73,120612,73,120670,73,120728,73,11410,73,1030,73,1216,73,1493,108,1503,108,1575,108,126464,108,126592,108,65166,108,65165,108,1994,108,11599,73,5825,73,42226,73,93992,73,66186,124,66313,124,119338,76,8556,76,8466,76,119819,76,119871,76,119923,76,120027,76,120079,76,120131,76,120183,76,120235,76,120287,76,120339,76,120391,76,120443,76,11472,76,5086,76,5290,76,42209,76,93974,76,71843,76,71858,76,66587,76,66854,76,65325,77,8559,77,8499,77,119820,77,119872,77,119924,77,120028,77,120080,77,120132,77,120184,77,120236,77,120288,77,120340,77,120392,77,120444,77,924,77,120499,77,120557,77,120615,77,120673,77,120731,77,1018,77,11416,77,5047,77,5616,77,5846,77,42207,77,66224,77,66321,77,119847,110,119899,110,119951,110,120003,110,120055,110,120107,110,120159,110,120211,110,120263,110,120315,110,120367,110,120419,110,120471,110,1400,110,1404,110,65326,78,8469,78,119821,78,119873,78,119925,78,119977,78,120029,78,120081,78,120185,78,120237,78,120289,78,120341,78,120393,78,120445,78,925,78,120500,78,120558,78,120616,78,120674,78,120732,78,11418,78,42208,78,66835,78,3074,111,3202,111,3330,111,3458,111,2406,111,2662,111,2790,111,3046,111,3174,111,3302,111,3430,111,3664,111,3792,111,4160,111,1637,111,1781,111,65359,111,8500,111,119848,111,119900,111,119952,111,120056,111,120108,111,120160,111,120212,111,120264,111,120316,111,120368,111,120420,111,120472,111,7439,111,7441,111,43837,111,959,111,120528,111,120586,111,120644,111,120702,111,120760,111,963,111,120532,111,120590,111,120648,111,120706,111,120764,111,11423,111,4351,111,1413,111,1505,111,1607,111,126500,111,126564,111,126596,111,65259,111,65260,111,65258,111,65257,111,1726,111,64428,111,64429,111,64427,111,64426,111,1729,111,64424,111,64425,111,64423,111,64422,111,1749,111,3360,111,4125,111,66794,111,71880,111,71895,111,66604,111,1984,79,2534,79,2918,79,12295,79,70864,79,71904,79,120782,79,120792,79,120802,79,120812,79,120822,79,130032,79,65327,79,119822,79,119874,79,119926,79,119978,79,120030,79,120082,79,120134,79,120186,79,120238,79,120290,79,120342,79,120394,79,120446,79,927,79,120502,79,120560,79,120618,79,120676,79,120734,79,11422,79,1365,79,11604,79,4816,79,2848,79,66754,79,42227,79,71861,79,66194,79,66219,79,66564,79,66838,79,9076,112,65360,112,119849,112,119901,112,119953,112,120005,112,120057,112,120109,112,120161,112,120213,112,120265,112,120317,112,120369,112,120421,112,120473,112,961,112,120530,112,120544,112,120588,112,120602,112,120646,112,120660,112,120704,112,120718,112,120762,112,120776,112,11427,112,65328,80,8473,80,119823,80,119875,80,119927,80,119979,80,120031,80,120083,80,120187,80,120239,80,120291,80,120343,80,120395,80,120447,80,929,80,120504,80,120562,80,120620,80,120678,80,120736,80,11426,80,5090,80,5229,80,42193,80,66197,80,119850,113,119902,113,119954,113,120006,113,120058,113,120110,113,120162,113,120214,113,120266,113,120318,113,120370,113,120422,113,120474,113,1307,113,1379,113,1382,113,8474,81,119824,81,119876,81,119928,81,119980,81,120032,81,120084,81,120188,81,120240,81,120292,81,120344,81,120396,81,120448,81,11605,81,119851,114,119903,114,119955,114,120007,114,120059,114,120111,114,120163,114,120215,114,120267,114,120319,114,120371,114,120423,114,120475,114,43847,114,43848,114,7462,114,11397,114,43905,114,119318,82,8475,82,8476,82,8477,82,119825,82,119877,82,119929,82,120033,82,120189,82,120241,82,120293,82,120345,82,120397,82,120449,82,422,82,5025,82,5074,82,66740,82,5511,82,42211,82,94005,82,65363,115,119852,115,119904,115,119956,115,120008,115,120060,115,120112,115,120164,115,120216,115,120268,115,120320,115,120372,115,120424,115,120476,115,42801,115,445,115,1109,115,43946,115,71873,115,66632,115,65331,83,119826,83,119878,83,119930,83,119982,83,120034,83,120086,83,120138,83,120190,83,120242,83,120294,83,120346,83,120398,83,120450,83,1029,83,1359,83,5077,83,5082,83,42210,83,94010,83,66198,83,66592,83,119853,116,119905,116,119957,116,120009,116,120061,116,120113,116,120165,116,120217,116,120269,116,120321,116,120373,116,120425,116,120477,116,8868,84,10201,84,128872,84,65332,84,119827,84,119879,84,119931,84,119983,84,120035,84,120087,84,120139,84,120191,84,120243,84,120295,84,120347,84,120399,84,120451,84,932,84,120507,84,120565,84,120623,84,120681,84,120739,84,11430,84,5026,84,42196,84,93962,84,71868,84,66199,84,66225,84,66325,84,119854,117,119906,117,119958,117,120010,117,120062,117,120114,117,120166,117,120218,117,120270,117,120322,117,120374,117,120426,117,120478,117,42911,117,7452,117,43854,117,43858,117,651,117,965,117,120534,117,120592,117,120650,117,120708,117,120766,117,1405,117,66806,117,71896,117,8746,85,8899,85,119828,85,119880,85,119932,85,119984,85,120036,85,120088,85,120140,85,120192,85,120244,85,120296,85,120348,85,120400,85,120452,85,1357,85,4608,85,66766,85,5196,85,42228,85,94018,85,71864,85,8744,118,8897,118,65366,118,8564,118,119855,118,119907,118,119959,118,120011,118,120063,118,120115,118,120167,118,120219,118,120271,118,120323,118,120375,118,120427,118,120479,118,7456,118,957,118,120526,118,120584,118,120642,118,120700,118,120758,118,1141,118,1496,118,71430,118,43945,118,71872,118,119309,86,1639,86,1783,86,8548,86,119829,86,119881,86,119933,86,119985,86,120037,86,120089,86,120141,86,120193,86,120245,86,120297,86,120349,86,120401,86,120453,86,1140,86,11576,86,5081,86,5167,86,42719,86,42214,86,93960,86,71840,86,66845,86,623,119,119856,119,119908,119,119960,119,120012,119,120064,119,120116,119,120168,119,120220,119,120272,119,120324,119,120376,119,120428,119,120480,119,7457,119,1121,119,1309,119,1377,119,71434,119,71438,119,71439,119,43907,119,71919,87,71910,87,119830,87,119882,87,119934,87,119986,87,120038,87,120090,87,120142,87,120194,87,120246,87,120298,87,120350,87,120402,87,120454,87,1308,87,5043,87,5076,87,42218,87,5742,120,10539,120,10540,120,10799,120,65368,120,8569,120,119857,120,119909,120,119961,120,120013,120,120065,120,120117,120,120169,120,120221,120,120273,120,120325,120,120377,120,120429,120,120481,120,5441,120,5501,120,5741,88,9587,88,66338,88,71916,88,65336,88,8553,88,119831,88,119883,88,119935,88,119987,88,120039,88,120091,88,120143,88,120195,88,120247,88,120299,88,120351,88,120403,88,120455,88,42931,88,935,88,120510,88,120568,88,120626,88,120684,88,120742,88,11436,88,11613,88,5815,88,42219,88,66192,88,66228,88,66327,88,66855,88,611,121,7564,121,65369,121,119858,121,119910,121,119962,121,120014,121,120066,121,120118,121,120170,121,120222,121,120274,121,120326,121,120378,121,120430,121,120482,121,655,121,7935,121,43866,121,947,121,8509,121,120516,121,120574,121,120632,121,120690,121,120748,121,1199,121,4327,121,71900,121,65337,89,119832,89,119884,89,119936,89,119988,89,120040,89,120092,89,120144,89,120196,89,120248,89,120300,89,120352,89,120404,89,120456,89,933,89,978,89,120508,89,120566,89,120624,89,120682,89,120740,89,11432,89,1198,89,5033,89,5053,89,42220,89,94019,89,71844,89,66226,89,119859,122,119911,122,119963,122,120015,122,120067,122,120119,122,120171,122,120223,122,120275,122,120327,122,120379,122,120431,122,120483,122,7458,122,43923,122,71876,122,66293,90,71909,90,65338,90,8484,90,8488,90,119833,90,119885,90,119937,90,119989,90,120041,90,120197,90,120249,90,120301,90,120353,90,120405,90,120457,90,918,90,120493,90,120551,90,120609,90,120667,90,120725,90,5059,90,42204,90,71849,90,65282,34,65284,36,65285,37,65286,38,65290,42,65291,43,65294,46,65295,47,65296,48,65297,49,65298,50,65299,51,65300,52,65301,53,65302,54,65303,55,65304,56,65305,57,65308,60,65309,61,65310,62,65312,64,65316,68,65318,70,65319,71,65324,76,65329,81,65330,82,65333,85,65334,86,65335,87,65343,95,65346,98,65348,100,65350,102,65355,107,65357,109,65358,110,65361,113,65362,114,65364,116,65365,117,65367,119,65370,122,65371,123,65373,125],"_default":[160,32,8211,45,65374,126,65306,58,65281,33,8216,96,8217,96,8245,96,180,96,12494,47,1047,51,1073,54,1072,97,1040,65,1068,98,1042,66,1089,99,1057,67,1077,101,1045,69,1053,72,305,105,1050,75,921,73,1052,77,1086,111,1054,79,1009,112,1088,112,1056,80,1075,114,1058,84,215,120,1093,120,1061,88,1091,121,1059,89,65283,35,65288,40,65289,41,65292,44,65307,59,65311,63],"cs":[65374,126,65306,58,65281,33,8216,96,8217,96,8245,96,180,96,12494,47,1047,51,1073,54,1072,97,1040,65,1068,98,1042,66,1089,99,1057,67,1077,101,1045,69,1053,72,305,105,1050,75,921,73,1052,77,1086,111,1054,79,1009,112,1088,112,1056,80,1075,114,1058,84,1093,120,1061,88,1091,121,1059,89,65283,35,65288,40,65289,41,65292,44,65307,59,65311,63],"de":[65374,126,65306,58,65281,33,8216,96,8217,96,8245,96,180,96,12494,47,1047,51,1073,54,1072,97,1040,65,1068,98,1042,66,1089,99,1057,67,1077,101,1045,69,1053,72,305,105,1050,75,921,73,1052,77,1086,111,1054,79,1009,112,1088,112,1056,80,1075,114,1058,84,1093,120,1061,88,1091,121,1059,89,65283,35,65288,40,65289,41,65292,44,65307,59,65311,63],"es":[8211,45,65374,126,65306,58,65281,33,8245,96,180,96,12494,47,1047,51,1073,54,1072,97,1040,65,1068,98,1042,66,1089,99,1057,67,1077,101,1045,69,1053,72,305,105,1050,75,1052,77,1086,111,1054,79,1009,112,1088,112,1056,80,1075,114,1058,84,215,120,1093,120,1061,88,1091,121,1059,89,65283,35,65288,40,65289,41,65292,44,65307,59,65311,63],"fr":[65374,126,65306,58,65281,33,8216,96,8245,96,12494,47,1047,51,1073,54,1072,97,1040,65,1068,98,1042,66,1089,99,1057,67,1077,101,1045,69,1053,72,305,105,1050,75,921,73,1052,77,1086,111,1054,79,1009,112,1088,112,1056,80,1075,114,1058,84,215,120,1093,120,1061,88,1091,121,1059,89,65283,35,65288,40,65289,41,65292,44,65307,59,65311,63],"it":[160,32,8211,45,65374,126,65306,58,65281,33,8216,96,8245,96,180,96,12494,47,1047,51,1073,54,1072,97,1040,65,1068,98,1042,66,1089,99,1057,67,1077,101,1045,69,1053,72,305,105,1050,75,921,73,1052,77,1086,111,1054,79,1009,112,1088,112,1056,80,1075,114,1058,84,215,120,1093,120,1061,88,1091,121,1059,89,65283,35,65288,40,65289,41,65292,44,65307,59,65311,63],"ja":[8211,45,65306,58,65281,33,8216,96,8217,96,8245,96,180,96,1047,51,1073,54,1072,97,1040,65,1068,98,1042,66,1089,99,1057,67,1077,101,1045,69,1053,72,305,105,1050,75,921,73,1052,77,1086,111,1054,79,1009,112,1088,112,1056,80,1075,114,1058,84,215,120,1093,120,1061,88,1091,121,1059,89,65283,35,65292,44,65307,59],"ko":[8211,45,65374,126,65306,58,65281,33,8245,96,180,96,12494,47,1047,51,1073,54,1072,97,1040,65,1068,98,1042,66,1089,99,1057,67,1077,101,1045,69,1053,72,305,105,1050,75,921,73,1052,77,1086,111,1054,79,1009,112,1088,112,1056,80,1075,114,1058,84,215,120,1093,120,1061,88,1091,121,1059,89,65283,35,65288,40,65289,41,65292,44,65307,59,65311,63],"pl":[65374,126,65306,58,65281,33,8216,96,8217,96,8245,96,180,96,12494,47,1047,51,1073,54,1072,97,1040,65,1068,98,1042,66,1089,99,1057,67,1077,101,1045,69,1053,72,305,105,1050,75,921,73,1052,77,1086,111,1054,79,1009,112,1088,112,1056,80,1075,114,1058,84,215,120,1093,120,1061,88,1091,121,1059,89,65283,35,65288,40,65289,41,65292,44,65307,59,65311,63],"pt-BR":[65374,126,65306,58,65281,33,8216,96,8217,96,8245,96,180,96,12494,47,1047,51,1073,54,1072,97,1040,65,1068,98,1042,66,1089,99,1057,67,1077,101,1045,69,1053,72,305,105,1050,75,921,73,1052,77,1086,111,1054,79,1009,112,1088,112,1056,80,1075,114,1058,84,215,120,1093,120,1061,88,1091,121,1059,89,65283,35,65288,40,65289,41,65292,44,65307,59,65311,63],"qps-ploc":[160,32,8211,45,65374,126,65306,58,65281,33,8216,96,8217,96,8245,96,180,96,12494,47,1047,51,1073,54,1072,97,1040,65,1068,98,1042,66,1089,99,1057,67,1077,101,1045,69,1053,72,305,105,1050,75,921,73,1052,77,1086,111,1054,79,1088,112,1056,80,1075,114,1058,84,215,120,1093,120,1061,88,1091,121,1059,89,65283,35,65288,40,65289,41,65292,44,65307,59,65311,63],"ru":[65374,126,65306,58,65281,33,8216,96,8217,96,8245,96,180,96,12494,47,305,105,921,73,1009,112,215,120,65283,35,65288,40,65289,41,65292,44,65307,59,65311,63],"tr":[160,32,8211,45,65374,126,65306,58,65281,33,8245,96,180,96,12494,47,1047,51,1073,54,1072,97,1040,65,1068,98,1042,66,1089,99,1057,67,1077,101,1045,69,1053,72,1050,75,921,73,1052,77,1086,111,1054,79,1009,112,1088,112,1056,80,1075,114,1058,84,215,120,1093,120,1061,88,1091,121,1059,89,65283,35,65288,40,65289,41,65292,44,65307,59,65311,63],"zh-hans":[65374,126,65306,58,65281,33,8245,96,180,96,12494,47,1047,51,1073,54,1072,97,1040,65,1068,98,1042,66,1089,99,1057,67,1077,101,1045,69,1053,72,305,105,1050,75,921,73,1052,77,1086,111,1054,79,1009,112,1088,112,1056,80,1075,114,1058,84,215,120,1093,120,1061,88,1091,121,1059,89,65288,40,65289,41],"zh-hant":[8211,45,65374,126,180,96,12494,47,1047,51,1073,54,1072,97,1040,65,1068,98,1042,66,1089,99,1057,67,1077,101,1045,69,1053,72,305,105,1050,75,921,73,1052,77,1086,111,1054,79,1009,112,1088,112,1056,80,1075,114,1058,84,215,120,1093,120,1061,88,1091,121,1059,89,65283,35,65307,59]}')),Lt.cache=new b.o(Ie=>{function Ve(Ii){const ut=new Map;for(let Si=0;Si<Ii.length;Si+=2)ut.set(Ii[Si],Ii[Si+1]);return ut}function dt(Ii,ut){const Si=new Map(Ii);for(const[yt,fe]of ut)Si.set(yt,fe);return Si}function bt(Ii,ut){if(!Ii)return ut;const Si=new Map;for(const[yt,fe]of Ii)ut.has(yt)&&Si.set(yt,fe);return Si}const Mt=K.ambiguousCharacterData.getValue();let Yt=Ie.filter(Ii=>!Ii.startsWith("_")&&Ii in Mt);Yt.length===0&&(Yt=["_default"]);let Nt;for(const Ii of Yt){const ut=Ve(Mt[Ii]);Nt=bt(Nt,ut)}const Pt=Ve(Mt._common),Ti=dt(Pt,Nt);return new Lt(Ti)}),Lt._locales=new o.d(()=>Object.keys(Lt.ambiguousCharacterData.getValue()).filter(Ie=>!Ie.startsWith("_")));class Rt{static getRawData(){return JSON.parse("[9,10,11,12,13,32,127,160,173,847,1564,4447,4448,6068,6069,6155,6156,6157,6158,7355,7356,8192,8193,8194,8195,8196,8197,8198,8199,8200,8201,8202,8203,8204,8205,8206,8207,8234,8235,8236,8237,8238,8239,8287,8288,8289,8290,8291,8292,8293,8294,8295,8296,8297,8298,8299,8300,8301,8302,8303,10240,12288,12644,65024,65025,65026,65027,65028,65029,65030,65031,65032,65033,65034,65035,65036,65037,65038,65039,65279,65440,65520,65521,65522,65523,65524,65525,65526,65527,65528,65532,78844,119155,119156,119157,119158,119159,119160,119161,119162,917504,917505,917506,917507,917508,917509,917510,917511,917512,917513,917514,917515,917516,917517,917518,917519,917520,917521,917522,917523,917524,917525,917526,917527,917528,917529,917530,917531,917532,917533,917534,917535,917536,917537,917538,917539,917540,917541,917542,917543,917544,917545,917546,917547,917548,917549,917550,917551,917552,917553,917554,917555,917556,917557,917558,917559,917560,917561,917562,917563,917564,917565,917566,917567,917568,917569,917570,917571,917572,917573,917574,917575,917576,917577,917578,917579,917580,917581,917582,917583,917584,917585,917586,917587,917588,917589,917590,917591,917592,917593,917594,917595,917596,917597,917598,917599,917600,917601,917602,917603,917604,917605,917606,917607,917608,917609,917610,917611,917612,917613,917614,917615,917616,917617,917618,917619,917620,917621,917622,917623,917624,917625,917626,917627,917628,917629,917630,917631,917760,917761,917762,917763,917764,917765,917766,917767,917768,917769,917770,917771,917772,917773,917774,917775,917776,917777,917778,917779,917780,917781,917782,917783,917784,917785,917786,917787,917788,917789,917790,917791,917792,917793,917794,917795,917796,917797,917798,917799,917800,917801,917802,917803,917804,917805,917806,917807,917808,917809,917810,917811,917812,917813,917814,917815,917816,917817,917818,917819,917820,917821,917822,917823,917824,917825,917826,917827,917828,917829,917830,917831,917832,917833,917834,917835,917836,917837,917838,917839,917840,917841,917842,917843,917844,917845,917846,917847,917848,917849,917850,917851,917852,917853,917854,917855,917856,917857,917858,917859,917860,917861,917862,917863,917864,917865,917866,917867,917868,917869,917870,917871,917872,917873,917874,917875,917876,917877,917878,917879,917880,917881,917882,917883,917884,917885,917886,917887,917888,917889,917890,917891,917892,917893,917894,917895,917896,917897,917898,917899,917900,917901,917902,917903,917904,917905,917906,917907,917908,917909,917910,917911,917912,917913,917914,917915,917916,917917,917918,917919,917920,917921,917922,917923,917924,917925,917926,917927,917928,917929,917930,917931,917932,917933,917934,917935,917936,917937,917938,917939,917940,917941,917942,917943,917944,917945,917946,917947,917948,917949,917950,917951,917952,917953,917954,917955,917956,917957,917958,917959,917960,917961,917962,917963,917964,917965,917966,917967,917968,917969,917970,917971,917972,917973,917974,917975,917976,917977,917978,917979,917980,917981,917982,917983,917984,917985,917986,917987,917988,917989,917990,917991,917992,917993,917994,917995,917996,917997,917998,917999]")}static getData(){return this._data||(this._data=new Set(Rt.getRawData())),this._data}static isInvisibleCharacter(Ve){return Rt.getData().has(Ve)}static get codePoints(){return Rt.getData()}}Rt._data=void 0},16878:(rt,ye,y)=>{y.d(ye,{b:()=>P});var b=y(87110),o=y(2106),K=y(10998),$=y(71386),L=y(50442);const U={followsCaret:!0,ignoreCharChanges:!0,alwaysRevealFirst:!0};class P extends K.jG{constructor(T,p={}){super(),this._onDidUpdate=this._register(new o.vl),this._editor=T,this._options=$.co(p,U,!1),this.disposed=!1,this.nextIdx=-1,this.ranges=[],this.ignoreSelectionChange=!1,this.revealFirst=!!this._options.alwaysRevealFirst,this._register(this._editor.onDidDispose(()=>this.dispose())),this._register(this._editor.onDidUpdateDiff(()=>this._onDiffUpdated())),this._options.followsCaret&&this._register(this._editor.getModifiedEditor().onDidChangeCursorPosition(d=>{this.ignoreSelectionChange||(this.nextIdx=-1)})),this._options.alwaysRevealFirst&&this._register(this._editor.getModifiedEditor().onDidChangeModel(d=>{this.revealFirst=!0})),this._init()}_init(){this._editor.getLineChanges()}_onDiffUpdated(){this._init(),this._compute(this._editor.getLineChanges()),this.revealFirst&&this._editor.getLineChanges()!==null&&(this.revealFirst=!1,this.nextIdx=-1,this.next(1))}_compute(T){this.ranges=[],T&&T.forEach(p=>{!this._options.ignoreCharChanges&&p.charChanges?p.charChanges.forEach(d=>{this.ranges.push({rhs:!0,range:new L.Q(d.modifiedStartLineNumber,d.modifiedStartColumn,d.modifiedEndLineNumber,d.modifiedEndColumn)})}):p.modifiedEndLineNumber===0?this.ranges.push({rhs:!0,range:new L.Q(p.modifiedStartLineNumber,1,p.modifiedStartLineNumber+1,1)}):this.ranges.push({rhs:!0,range:new L.Q(p.modifiedStartLineNumber,1,p.modifiedEndLineNumber+1,1)})}),this.ranges.sort((p,d)=>L.Q.compareRangesUsingStarts(p.range,d.range)),this._onDidUpdate.fire(this)}_initIdx(T){let p=!1;const d=this._editor.getPosition();if(!d){this.nextIdx=0;return}for(let g=0,h=this.ranges.length;g<h&&!p;g++){const l=this.ranges[g].range;d.isBeforeOrEqual(l.getStartPosition())&&(this.nextIdx=g+(T?0:-1),p=!0)}p||(this.nextIdx=T?0:this.ranges.length-1),this.nextIdx<0&&(this.nextIdx=this.ranges.length-1)}_move(T,p){if(b.ok(!this.disposed,"Illegal State - diff navigator has been disposed"),!this.canNavigate())return;this.nextIdx===-1?this._initIdx(T):T?(this.nextIdx+=1,this.nextIdx>=this.ranges.length&&(this.nextIdx=0)):(this.nextIdx-=1,this.nextIdx<0&&(this.nextIdx=this.ranges.length-1));const d=this.ranges[this.nextIdx];this.ignoreSelectionChange=!0;try{const g=d.range.getStartPosition();this._editor.setPosition(g),this._editor.revealRangeInCenter(d.range,p)}finally{this.ignoreSelectionChange=!1}}canNavigate(){return this.ranges&&this.ranges.length>0}next(T=0){this._move(!0,T)}previous(T=0){this._move(!1,T)}dispose(){super.dispose(),this.ranges=[],this.disposed=!0}}},16916:(rt,ye,y)=>{y.d(ye,{X:()=>o});var b=y(82399);const o=(0,b.u1)("dialogService")},17589:(rt,ye,y)=>{y.d(ye,{$:()=>p,f:()=>g});var b=y(14333),o=y(65958),K=y(78903),$=y(90028),L=y(24594),U=y(10998),P=y(79359),B=y(3765),T=function(h,l,u,w){function C(m){return m instanceof u?m:new u(function(v){v(m)})}return new(u||(u=Promise))(function(m,v){function k(A){try{x(w.next(A))}catch(W){v(W)}}function D(A){try{x(w.throw(A))}catch(W){v(W)}}function x(A){A.done?m(A.value):C(A.value).then(k,D)}x((w=w.apply(h,l||[])).next())})};function p(h,l){(0,P.Kg)(l)?h.title=(0,L.pS)(l):l?.markdownNotSupportedFallback?h.title=l.markdownNotSupportedFallback:h.removeAttribute("title")}class d{constructor(l,u,w){this.hoverDelegate=l,this.target=u,this.fadeInAnimation=w}update(l,u,w){var C;return T(this,void 0,void 0,function*(){if(this._cancellationTokenSource&&(this._cancellationTokenSource.dispose(!0),this._cancellationTokenSource=void 0),this.isDisposed)return;let m;if(l===void 0||(0,P.Kg)(l)||l instanceof HTMLElement)m=l;else if(!(0,P.Tn)(l.markdown))m=(C=l.markdown)!==null&&C!==void 0?C:l.markdownNotSupportedFallback;else{this._hoverWidget||this.show((0,B.kg)("iconLabel.loading","Loading..."),u),this._cancellationTokenSource=new K.Q;const v=this._cancellationTokenSource.token;if(m=yield l.markdown(v),m===void 0&&(m=l.markdownNotSupportedFallback),this.isDisposed||v.isCancellationRequested)return}this.show(m,u,w)})}show(l,u,w){const C=this._hoverWidget;if(this.hasContent(l)){const m=Object.assign({content:l,target:this.target,showPointer:this.hoverDelegate.placement==="element",hoverPosition:2,skipFadeInAnimation:!this.fadeInAnimation||!!C},w);this._hoverWidget=this.hoverDelegate.showHover(m,u)}C?.dispose()}hasContent(l){return l?(0,$.VS)(l)?!!l.value:!0:!1}get isDisposed(){var l;return(l=this._hoverWidget)===null||l===void 0?void 0:l.isDisposed}dispose(){var l,u;(l=this._hoverWidget)===null||l===void 0||l.dispose(),(u=this._cancellationTokenSource)===null||u===void 0||u.dispose(!0),this._cancellationTokenSource=void 0}}function g(h,l,u,w){let C,m;const v=(W,Y)=>{var ne;W&&(m?.dispose(),m=void 0),Y&&(C?.dispose(),C=void 0),(ne=h.onDidHideHover)===null||ne===void 0||ne.call(h)},k=(W,Y,ne)=>new o.pc(()=>T(this,void 0,void 0,function*(){(!m||m.isDisposed)&&(m=new d(h,ne||l,W>0),yield m.update(u,Y,w))}),W),D=()=>{if(C)return;const W=new U.Cm,Y=Q=>v(!1,Q.fromElement===l);W.add(b.ko(l,b.Bx.MOUSE_LEAVE,Y,!0));const ne=()=>v(!0,!0);W.add(b.ko(l,b.Bx.MOUSE_DOWN,ne,!0));const j={targetElements:[l],dispose:()=>{}};if(h.placement===void 0||h.placement==="mouse"){const Q=X=>{j.x=X.x+10,X.target instanceof HTMLElement&&X.target.classList.contains("action-label")&&v(!0,!0)};W.add(b.ko(l,b.Bx.MOUSE_MOVE,Q,!0))}W.add(k(h.delay,!1,j)),C=W},x=b.ko(l,b.Bx.MOUSE_OVER,D,!0);return{show:W=>{v(!1,!0),k(0,W)},hide:()=>{v(!0,!0)},update:(W,Y)=>T(this,void 0,void 0,function*(){u=W,yield m?.update(u,void 0,Y)}),dispose:()=>{x.dispose(),v(!0,!0)}}}},17954:(rt,ye,y)=>{y.d(ye,{f:()=>b});var b;(function(o){function K(x){return x&&typeof x=="object"&&typeof x[Symbol.iterator]=="function"}o.is=K;const $=Object.freeze([]);function L(){return $}o.empty=L;function*U(x){yield x}o.single=U;function P(x){return x||$}o.from=P;function B(x){return!x||x[Symbol.iterator]().next().done===!0}o.isEmpty=B;function T(x){return x[Symbol.iterator]().next().value}o.first=T;function p(x,A){for(const W of x)if(A(W))return!0;return!1}o.some=p;function d(x,A){for(const W of x)if(A(W))return W}o.find=d;function*g(x,A){for(const W of x)A(W)&&(yield W)}o.filter=g;function*h(x,A){let W=0;for(const Y of x)yield A(Y,W++)}o.map=h;function*l(...x){for(const A of x)for(const W of A)yield W}o.concat=l;function*u(x){for(const A of x)for(const W of A)yield W}o.concatNested=u;function w(x,A,W){let Y=W;for(const ne of x)Y=A(Y,ne);return Y}o.reduce=w;function C(x,A){let W=0;for(const Y of x)A(Y,W++)}o.forEach=C;function*m(x,A,W=x.length){for(A<0&&(A+=x.length),W<0?W+=x.length:W>x.length&&(W=x.length);A<W;A++)yield x[A]}o.slice=m;function v(x,A=Number.POSITIVE_INFINITY){const W=[];if(A===0)return[W,x];const Y=x[Symbol.iterator]();for(let ne=0;ne<A;ne++){const j=Y.next();if(j.done)return[W,o.empty()];W.push(j.value)}return[W,{[Symbol.iterator](){return Y}}]}o.consume=v;function k(x){return v(x)[0]}o.collect=k;function D(x,A,W=(Y,ne)=>Y===ne){const Y=x[Symbol.iterator](),ne=A[Symbol.iterator]();for(;;){const j=Y.next(),Q=ne.next();if(j.done!==Q.done)return!1;if(j.done)return!0;if(!W(j.value,Q.value))return!1}}o.equals=D})(b||(b={}))},18019:(rt,ye,y)=>{y.d(ye,{IN:()=>m,LC:()=>Y,P8:()=>W,S8:()=>k,SA:()=>v,V8:()=>x,Vn:()=>ne,hd:()=>D,pD:()=>A});var b=y(9871);const o=65,K=97,$=90,L=122,U=46,P=47,B=92,T=58,p=63;class d extends Error{constructor(Q,X,R){let H;typeof X=="string"&&X.indexOf("not ")===0?(H="must not be",X=X.replace(/^not /,"")):H="must be";const Z=Q.indexOf(".")!==-1?"property":"argument";let N=`The "${Q}" ${Z} ${H} of type ${X}`;N+=`. Received type ${typeof R}`,super(N),this.code="ERR_INVALID_ARG_TYPE"}}function g(j,Q){if(typeof j!="string")throw new d(Q,"string",j)}function h(j){return j===P||j===B}function l(j){return j===P}function u(j){return j>=o&&j<=$||j>=K&&j<=L}function w(j,Q,X,R){let H="",Z=0,N=-1,G=0,O=0;for(let te=0;te<=j.length;++te){if(te<j.length)O=j.charCodeAt(te);else{if(R(O))break;O=P}if(R(O)){if(!(N===te-1||G===1))if(G===2){if(H.length<2||Z!==2||H.charCodeAt(H.length-1)!==U||H.charCodeAt(H.length-2)!==U){if(H.length>2){const oe=H.lastIndexOf(X);oe===-1?(H="",Z=0):(H=H.slice(0,oe),Z=H.length-1-H.lastIndexOf(X)),N=te,G=0;continue}else if(H.length!==0){H="",Z=0,N=te,G=0;continue}}Q&&(H+=H.length>0?`${X}..`:"..",Z=2)}else H.length>0?H+=`${X}${j.slice(N+1,te)}`:H=j.slice(N+1,te),Z=te-N-1;N=te,G=0}else O===U&&G!==-1?++G:G=-1}return H}function C(j,Q){if(Q===null||typeof Q!="object")throw new d("pathObject","Object",Q);const X=Q.dir||Q.root,R=Q.base||`${Q.name||""}${Q.ext||""}`;return X?X===Q.root?`${X}${R}`:`${X}${j}${R}`:R}const m={resolve(...j){let Q="",X="",R=!1;for(let H=j.length-1;H>=-1;H--){let Z;if(H>=0){if(Z=j[H],g(Z,"path"),Z.length===0)continue}else Q.length===0?Z=b.bJ():(Z=b._K[`=${Q}`]||b.bJ(),(Z===void 0||Z.slice(0,2).toLowerCase()!==Q.toLowerCase()&&Z.charCodeAt(2)===B)&&(Z=`${Q}\\`));const N=Z.length;let G=0,O="",te=!1;const oe=Z.charCodeAt(0);if(N===1)h(oe)&&(G=1,te=!0);else if(h(oe))if(te=!0,h(Z.charCodeAt(1))){let ue=2,E=ue;for(;ue<N&&!h(Z.charCodeAt(ue));)ue++;if(ue<N&&ue!==E){const Qe=Z.slice(E,ue);for(E=ue;ue<N&&h(Z.charCodeAt(ue));)ue++;if(ue<N&&ue!==E){for(E=ue;ue<N&&!h(Z.charCodeAt(ue));)ue++;(ue===N||ue!==E)&&(O=`\\\\${Qe}\\${Z.slice(E,ue)}`,G=ue)}}}else G=1;else u(oe)&&Z.charCodeAt(1)===T&&(O=Z.slice(0,2),G=2,N>2&&h(Z.charCodeAt(2))&&(te=!0,G=3));if(O.length>0)if(Q.length>0){if(O.toLowerCase()!==Q.toLowerCase())continue}else Q=O;if(R){if(Q.length>0)break}else if(X=`${Z.slice(G)}\\${X}`,R=te,te&&Q.length>0)break}return X=w(X,!R,"\\",h),R?`${Q}\\${X}`:`${Q}${X}`||"."},normalize(j){g(j,"path");const Q=j.length;if(Q===0)return".";let X=0,R,H=!1;const Z=j.charCodeAt(0);if(Q===1)return l(Z)?"\\":j;if(h(Z))if(H=!0,h(j.charCodeAt(1))){let G=2,O=G;for(;G<Q&&!h(j.charCodeAt(G));)G++;if(G<Q&&G!==O){const te=j.slice(O,G);for(O=G;G<Q&&h(j.charCodeAt(G));)G++;if(G<Q&&G!==O){for(O=G;G<Q&&!h(j.charCodeAt(G));)G++;if(G===Q)return`\\\\${te}\\${j.slice(O)}\\`;G!==O&&(R=`\\\\${te}\\${j.slice(O,G)}`,X=G)}}}else X=1;else u(Z)&&j.charCodeAt(1)===T&&(R=j.slice(0,2),X=2,Q>2&&h(j.charCodeAt(2))&&(H=!0,X=3));let N=X<Q?w(j.slice(X),!H,"\\",h):"";return N.length===0&&!H&&(N="."),N.length>0&&h(j.charCodeAt(Q-1))&&(N+="\\"),R===void 0?H?`\\${N}`:N:H?`${R}\\${N}`:`${R}${N}`},isAbsolute(j){g(j,"path");const Q=j.length;if(Q===0)return!1;const X=j.charCodeAt(0);return h(X)||Q>2&&u(X)&&j.charCodeAt(1)===T&&h(j.charCodeAt(2))},join(...j){if(j.length===0)return".";let Q,X;for(let Z=0;Z<j.length;++Z){const N=j[Z];g(N,"path"),N.length>0&&(Q===void 0?Q=X=N:Q+=`\\${N}`)}if(Q===void 0)return".";let R=!0,H=0;if(typeof X=="string"&&h(X.charCodeAt(0))){++H;const Z=X.length;Z>1&&h(X.charCodeAt(1))&&(++H,Z>2&&(h(X.charCodeAt(2))?++H:R=!1))}if(R){for(;H<Q.length&&h(Q.charCodeAt(H));)H++;H>=2&&(Q=`\\${Q.slice(H)}`)}return m.normalize(Q)},relative(j,Q){if(g(j,"from"),g(Q,"to"),j===Q)return"";const X=m.resolve(j),R=m.resolve(Q);if(X===R||(j=X.toLowerCase(),Q=R.toLowerCase(),j===Q))return"";let H=0;for(;H<j.length&&j.charCodeAt(H)===B;)H++;let Z=j.length;for(;Z-1>H&&j.charCodeAt(Z-1)===B;)Z--;const N=Z-H;let G=0;for(;G<Q.length&&Q.charCodeAt(G)===B;)G++;let O=Q.length;for(;O-1>G&&Q.charCodeAt(O-1)===B;)O--;const te=O-G,oe=N<te?N:te;let ue=-1,E=0;for(;E<oe;E++){const Ke=j.charCodeAt(H+E);if(Ke!==Q.charCodeAt(G+E))break;Ke===B&&(ue=E)}if(E!==oe){if(ue===-1)return R}else{if(te>oe){if(Q.charCodeAt(G+E)===B)return R.slice(G+E+1);if(E===2)return R.slice(G+E)}N>oe&&(j.charCodeAt(H+E)===B?ue=E:E===2&&(ue=3)),ue===-1&&(ue=0)}let Qe="";for(E=H+ue+1;E<=Z;++E)(E===Z||j.charCodeAt(E)===B)&&(Qe+=Qe.length===0?"..":"\\..");return G+=ue,Qe.length>0?`${Qe}${R.slice(G,O)}`:(R.charCodeAt(G)===B&&++G,R.slice(G,O))},toNamespacedPath(j){if(typeof j!="string")return j;if(j.length===0)return"";const Q=m.resolve(j);if(Q.length<=2)return j;if(Q.charCodeAt(0)===B){if(Q.charCodeAt(1)===B){const X=Q.charCodeAt(2);if(X!==p&&X!==U)return`\\\\?\\UNC\\${Q.slice(2)}`}}else if(u(Q.charCodeAt(0))&&Q.charCodeAt(1)===T&&Q.charCodeAt(2)===B)return`\\\\?\\${Q}`;return j},dirname(j){g(j,"path");const Q=j.length;if(Q===0)return".";let X=-1,R=0;const H=j.charCodeAt(0);if(Q===1)return h(H)?j:".";if(h(H)){if(X=R=1,h(j.charCodeAt(1))){let G=2,O=G;for(;G<Q&&!h(j.charCodeAt(G));)G++;if(G<Q&&G!==O){for(O=G;G<Q&&h(j.charCodeAt(G));)G++;if(G<Q&&G!==O){for(O=G;G<Q&&!h(j.charCodeAt(G));)G++;if(G===Q)return j;G!==O&&(X=R=G+1)}}}}else u(H)&&j.charCodeAt(1)===T&&(X=Q>2&&h(j.charCodeAt(2))?3:2,R=X);let Z=-1,N=!0;for(let G=Q-1;G>=R;--G)if(h(j.charCodeAt(G))){if(!N){Z=G;break}}else N=!1;if(Z===-1){if(X===-1)return".";Z=X}return j.slice(0,Z)},basename(j,Q){Q!==void 0&&g(Q,"ext"),g(j,"path");let X=0,R=-1,H=!0,Z;if(j.length>=2&&u(j.charCodeAt(0))&&j.charCodeAt(1)===T&&(X=2),Q!==void 0&&Q.length>0&&Q.length<=j.length){if(Q===j)return"";let N=Q.length-1,G=-1;for(Z=j.length-1;Z>=X;--Z){const O=j.charCodeAt(Z);if(h(O)){if(!H){X=Z+1;break}}else G===-1&&(H=!1,G=Z+1),N>=0&&(O===Q.charCodeAt(N)?--N===-1&&(R=Z):(N=-1,R=G))}return X===R?R=G:R===-1&&(R=j.length),j.slice(X,R)}for(Z=j.length-1;Z>=X;--Z)if(h(j.charCodeAt(Z))){if(!H){X=Z+1;break}}else R===-1&&(H=!1,R=Z+1);return R===-1?"":j.slice(X,R)},extname(j){g(j,"path");let Q=0,X=-1,R=0,H=-1,Z=!0,N=0;j.length>=2&&j.charCodeAt(1)===T&&u(j.charCodeAt(0))&&(Q=R=2);for(let G=j.length-1;G>=Q;--G){const O=j.charCodeAt(G);if(h(O)){if(!Z){R=G+1;break}continue}H===-1&&(Z=!1,H=G+1),O===U?X===-1?X=G:N!==1&&(N=1):X!==-1&&(N=-1)}return X===-1||H===-1||N===0||N===1&&X===H-1&&X===R+1?"":j.slice(X,H)},format:C.bind(null,"\\"),parse(j){g(j,"path");const Q={root:"",dir:"",base:"",ext:"",name:""};if(j.length===0)return Q;const X=j.length;let R=0,H=j.charCodeAt(0);if(X===1)return h(H)?(Q.root=Q.dir=j,Q):(Q.base=Q.name=j,Q);if(h(H)){if(R=1,h(j.charCodeAt(1))){let ue=2,E=ue;for(;ue<X&&!h(j.charCodeAt(ue));)ue++;if(ue<X&&ue!==E){for(E=ue;ue<X&&h(j.charCodeAt(ue));)ue++;if(ue<X&&ue!==E){for(E=ue;ue<X&&!h(j.charCodeAt(ue));)ue++;ue===X?R=ue:ue!==E&&(R=ue+1)}}}}else if(u(H)&&j.charCodeAt(1)===T){if(X<=2)return Q.root=Q.dir=j,Q;if(R=2,h(j.charCodeAt(2))){if(X===3)return Q.root=Q.dir=j,Q;R=3}}R>0&&(Q.root=j.slice(0,R));let Z=-1,N=R,G=-1,O=!0,te=j.length-1,oe=0;for(;te>=R;--te){if(H=j.charCodeAt(te),h(H)){if(!O){N=te+1;break}continue}G===-1&&(O=!1,G=te+1),H===U?Z===-1?Z=te:oe!==1&&(oe=1):Z!==-1&&(oe=-1)}return G!==-1&&(Z===-1||oe===0||oe===1&&Z===G-1&&Z===N+1?Q.base=Q.name=j.slice(N,G):(Q.name=j.slice(N,Z),Q.base=j.slice(N,G),Q.ext=j.slice(Z,G))),N>0&&N!==R?Q.dir=j.slice(0,N-1):Q.dir=Q.root,Q},sep:"\\",delimiter:";",win32:null,posix:null},v={resolve(...j){let Q="",X=!1;for(let R=j.length-1;R>=-1&&!X;R--){const H=R>=0?j[R]:b.bJ();g(H,"path"),H.length!==0&&(Q=`${H}/${Q}`,X=H.charCodeAt(0)===P)}return Q=w(Q,!X,"/",l),X?`/${Q}`:Q.length>0?Q:"."},normalize(j){if(g(j,"path"),j.length===0)return".";const Q=j.charCodeAt(0)===P,X=j.charCodeAt(j.length-1)===P;return j=w(j,!Q,"/",l),j.length===0?Q?"/":X?"./":".":(X&&(j+="/"),Q?`/${j}`:j)},isAbsolute(j){return g(j,"path"),j.length>0&&j.charCodeAt(0)===P},join(...j){if(j.length===0)return".";let Q;for(let X=0;X<j.length;++X){const R=j[X];g(R,"path"),R.length>0&&(Q===void 0?Q=R:Q+=`/${R}`)}return Q===void 0?".":v.normalize(Q)},relative(j,Q){if(g(j,"from"),g(Q,"to"),j===Q||(j=v.resolve(j),Q=v.resolve(Q),j===Q))return"";const X=1,R=j.length,H=R-X,Z=1,N=Q.length-Z,G=H<N?H:N;let O=-1,te=0;for(;te<G;te++){const ue=j.charCodeAt(X+te);if(ue!==Q.charCodeAt(Z+te))break;ue===P&&(O=te)}if(te===G)if(N>G){if(Q.charCodeAt(Z+te)===P)return Q.slice(Z+te+1);if(te===0)return Q.slice(Z+te)}else H>G&&(j.charCodeAt(X+te)===P?O=te:te===0&&(O=0));let oe="";for(te=X+O+1;te<=R;++te)(te===R||j.charCodeAt(te)===P)&&(oe+=oe.length===0?"..":"/..");return`${oe}${Q.slice(Z+O)}`},toNamespacedPath(j){return j},dirname(j){if(g(j,"path"),j.length===0)return".";const Q=j.charCodeAt(0)===P;let X=-1,R=!0;for(let H=j.length-1;H>=1;--H)if(j.charCodeAt(H)===P){if(!R){X=H;break}}else R=!1;return X===-1?Q?"/":".":Q&&X===1?"//":j.slice(0,X)},basename(j,Q){Q!==void 0&&g(Q,"ext"),g(j,"path");let X=0,R=-1,H=!0,Z;if(Q!==void 0&&Q.length>0&&Q.length<=j.length){if(Q===j)return"";let N=Q.length-1,G=-1;for(Z=j.length-1;Z>=0;--Z){const O=j.charCodeAt(Z);if(O===P){if(!H){X=Z+1;break}}else G===-1&&(H=!1,G=Z+1),N>=0&&(O===Q.charCodeAt(N)?--N===-1&&(R=Z):(N=-1,R=G))}return X===R?R=G:R===-1&&(R=j.length),j.slice(X,R)}for(Z=j.length-1;Z>=0;--Z)if(j.charCodeAt(Z)===P){if(!H){X=Z+1;break}}else R===-1&&(H=!1,R=Z+1);return R===-1?"":j.slice(X,R)},extname(j){g(j,"path");let Q=-1,X=0,R=-1,H=!0,Z=0;for(let N=j.length-1;N>=0;--N){const G=j.charCodeAt(N);if(G===P){if(!H){X=N+1;break}continue}R===-1&&(H=!1,R=N+1),G===U?Q===-1?Q=N:Z!==1&&(Z=1):Q!==-1&&(Z=-1)}return Q===-1||R===-1||Z===0||Z===1&&Q===R-1&&Q===X+1?"":j.slice(Q,R)},format:C.bind(null,"/"),parse(j){g(j,"path");const Q={root:"",dir:"",base:"",ext:"",name:""};if(j.length===0)return Q;const X=j.charCodeAt(0)===P;let R;X?(Q.root="/",R=1):R=0;let H=-1,Z=0,N=-1,G=!0,O=j.length-1,te=0;for(;O>=R;--O){const oe=j.charCodeAt(O);if(oe===P){if(!G){Z=O+1;break}continue}N===-1&&(G=!1,N=O+1),oe===U?H===-1?H=O:te!==1&&(te=1):H!==-1&&(te=-1)}if(N!==-1){const oe=Z===0&&X?1:Z;H===-1||te===0||te===1&&H===N-1&&H===Z+1?Q.base=Q.name=j.slice(oe,N):(Q.name=j.slice(oe,H),Q.base=j.slice(oe,N),Q.ext=j.slice(H,N))}return Z>0?Q.dir=j.slice(0,Z-1):X&&(Q.dir="/"),Q},sep:"/",delimiter:":",win32:null,posix:null};v.win32=m.win32=m,v.posix=m.posix=v;const k=b.iD==="win32"?m.normalize:v.normalize,D=b.iD==="win32"?m.resolve:v.resolve,x=b.iD==="win32"?m.relative:v.relative,A=b.iD==="win32"?m.dirname:v.dirname,W=b.iD==="win32"?m.basename:v.basename,Y=b.iD==="win32"?m.extname:v.extname,ne=b.iD==="win32"?m.sep:v.sep},18782:(rt,ye,y)=>{y.d(ye,{Io:()=>U,J3:()=>K,Ld:()=>L,Th:()=>B});var b=y(17954),o=y(85525);const K="`~!@#$%^&*()-=+[{]}\\|;:'\",.<>/?";function $(p=""){let d="(-?\\d*\\.\\d\\w*)|([^";for(const g of K)p.indexOf(g)>=0||(d+="\\"+g);return d+="\\s]+)",new RegExp(d,"g")}const L=$();function U(p){let d=L;if(p&&p instanceof RegExp)if(p.global)d=p;else{let g="g";p.ignoreCase&&(g+="i"),p.multiline&&(g+="m"),p.unicode&&(g+="u"),d=new RegExp(p.source,g)}return d.lastIndex=0,d}const P=new o.w;P.unshift({maxLen:1e3,windowSize:15,timeBudget:150});function B(p,d,g,h,l){if(l||(l=b.f.first(P)),g.length>l.maxLen){let v=p-l.maxLen/2;return v<0?v=0:h+=v,g=g.substring(v,p+l.maxLen/2),B(p,d,g,h,l)}const u=Date.now(),w=p-1-h;let C=-1,m=null;for(let v=1;!(Date.now()-u>=l.timeBudget);v++){const k=w-l.windowSize*v;d.lastIndex=Math.max(0,k);const D=T(d,g,w,C);if(!D&&m||(m=D,k<=0))break;C=k}if(m){const v={word:m[0],startColumn:h+1+m.index,endColumn:h+1+m.index+m[0].length};return d.lastIndex=0,v}return null}function T(p,d,g,h){let l;for(;l=p.exec(d);){const u=l.index||0;if(u<=g&&p.lastIndex>=g)return l;if(h>0&&u>h)return null}return null}},19184:(rt,ye,y)=>{y.d(ye,{BQ:()=>b,Yo:()=>K});function b($,L){const U=$.getCount(),P=$.findTokenIndexAtOffset(L),B=$.getLanguageId(P);let T=P;for(;T+1<U&&$.getLanguageId(T+1)===B;)T++;let p=P;for(;p>0&&$.getLanguageId(p-1)===B;)p--;return new o($,B,p,T+1,$.getStartOffset(p),$.getEndOffset(T))}class o{constructor(L,U,P,B,T,p){this._scopedLineTokensBrand=void 0,this._actual=L,this.languageId=U,this._firstTokenIndex=P,this._lastTokenIndex=B,this.firstCharOffset=T,this._lastCharOffset=p}getLineContent(){return this._actual.getLineContent().substring(this.firstCharOffset,this._lastCharOffset)}getActualLineContentBefore(L){return this._actual.getLineContent().substring(0,this.firstCharOffset+L)}getTokenCount(){return this._lastTokenIndex-this._firstTokenIndex}findTokenIndexAtOffset(L){return this._actual.findTokenIndexAtOffset(L+this.firstCharOffset)-this._firstTokenIndex}getStandardTokenType(L){return this._actual.getStandardTokenType(L+this._firstTokenIndex)}}function K($){return($&3)!==0}},19381:(rt,ye,y)=>{y.d(ye,{Fd:()=>L,aJ:()=>$});var b=y(13338),o=y(10998),K=y(67167),$;(function(P){P[P.PRESERVE=0]="PRESERVE",P[P.LAST=1]="LAST"})($||($={}));const L={Quickaccess:"workbench.contributions.quickaccess"};class U{constructor(){this.providers=[],this.defaultProvider=void 0}registerQuickAccessProvider(B){return B.prefix.length===0?this.defaultProvider=B:this.providers.push(B),this.providers.sort((T,p)=>p.prefix.length-T.prefix.length),(0,o.s)(()=>{this.providers.splice(this.providers.indexOf(B),1),this.defaultProvider===B&&(this.defaultProvider=void 0)})}getQuickAccessProviders(){return(0,b.Yc)([this.defaultProvider,...this.providers])}getQuickAccessProvider(B){return B&&this.providers.find(p=>B.startsWith(p.prefix))||void 0||this.defaultProvider}}K.O.add(L.Quickaccess,new U)},22344:(rt,ye,y)=>{y.d(ye,{e2:()=>U,sN:()=>K,tW:()=>o,v7:()=>h});var b=y(16844);function o(l){return K(l,0)}function K(l,u){switch(typeof l){case"object":return l===null?$(349,u):Array.isArray(l)?P(l,u):B(l,u);case"string":return U(l,u);case"boolean":return L(l,u);case"number":return $(l,u);case"undefined":return $(937,u);default:return $(617,u)}}function $(l,u){return(u<<5)-u+l|0}function L(l,u){return $(l?433:863,u)}function U(l,u){u=$(149417,u);for(let w=0,C=l.length;w<C;w++)u=$(l.charCodeAt(w),u);return u}function P(l,u){return u=$(104579,u),l.reduce((w,C)=>K(C,w),u)}function B(l,u){return u=$(181387,u),Object.keys(l).sort().reduce((w,C)=>(w=U(C,w),K(l[C],w)),u)}function T(l,u,w=32){const C=w-u,m=~((1<<C)-1);return(l<<u|(m&l)>>>C)>>>0}function p(l,u=0,w=l.byteLength,C=0){for(let m=0;m<w;m++)l[u+m]=C}function d(l,u,w="0"){for(;l.length<u;)l=w+l;return l}function g(l,u=32){return l instanceof ArrayBuffer?Array.from(new Uint8Array(l)).map(w=>w.toString(16).padStart(2,"0")).join(""):d((l>>>0).toString(16),u/4)}class h{constructor(){this._h0=1732584193,this._h1=4023233417,this._h2=2562383102,this._h3=271733878,this._h4=3285377520,this._buff=new Uint8Array(67),this._buffDV=new DataView(this._buff.buffer),this._buffLen=0,this._totalLen=0,this._leftoverHighSurrogate=0,this._finished=!1}update(u){const w=u.length;if(w===0)return;const C=this._buff;let m=this._buffLen,v=this._leftoverHighSurrogate,k,D;for(v!==0?(k=v,D=-1,v=0):(k=u.charCodeAt(0),D=0);;){let x=k;if(b.pc(k))if(D+1<w){const A=u.charCodeAt(D+1);b.LJ(A)?(D++,x=b.z_(k,A)):x=65533}else{v=k;break}else b.LJ(k)&&(x=65533);if(m=this._push(C,m,x),D++,D<w)k=u.charCodeAt(D);else break}this._buffLen=m,this._leftoverHighSurrogate=v}_push(u,w,C){return C<128?u[w++]=C:C<2048?(u[w++]=192|(C&1984)>>>6,u[w++]=128|(C&63)>>>0):C<65536?(u[w++]=224|(C&61440)>>>12,u[w++]=128|(C&4032)>>>6,u[w++]=128|(C&63)>>>0):(u[w++]=240|(C&1835008)>>>18,u[w++]=128|(C&258048)>>>12,u[w++]=128|(C&4032)>>>6,u[w++]=128|(C&63)>>>0),w>=64&&(this._step(),w-=64,this._totalLen+=64,u[0]=u[64],u[1]=u[65],u[2]=u[66]),w}digest(){return this._finished||(this._finished=!0,this._leftoverHighSurrogate&&(this._leftoverHighSurrogate=0,this._buffLen=this._push(this._buff,this._buffLen,65533)),this._totalLen+=this._buffLen,this._wrapUp()),g(this._h0)+g(this._h1)+g(this._h2)+g(this._h3)+g(this._h4)}_wrapUp(){this._buff[this._buffLen++]=128,p(this._buff,this._buffLen),this._buffLen>56&&(this._step(),p(this._buff));const u=8*this._totalLen;this._buffDV.setUint32(56,Math.floor(u/4294967296),!1),this._buffDV.setUint32(60,u%4294967296,!1),this._step()}_step(){const u=h._bigBlock32,w=this._buffDV;for(let Y=0;Y<64;Y+=4)u.setUint32(Y,w.getUint32(Y,!1),!1);for(let Y=64;Y<320;Y+=4)u.setUint32(Y,T(u.getUint32(Y-12,!1)^u.getUint32(Y-32,!1)^u.getUint32(Y-56,!1)^u.getUint32(Y-64,!1),1),!1);let C=this._h0,m=this._h1,v=this._h2,k=this._h3,D=this._h4,x,A,W;for(let Y=0;Y<80;Y++)Y<20?(x=m&v|~m&k,A=1518500249):Y<40?(x=m^v^k,A=1859775393):Y<60?(x=m&v|m&k|v&k,A=2400959708):(x=m^v^k,A=3395469782),W=T(C,5)+x+D+A+u.getUint32(Y*4,!1)&4294967295,D=k,k=v,v=T(m,30),m=C,C=W;this._h0=this._h0+C&4294967295,this._h1=this._h1+m&4294967295,this._h2=this._h2+v&4294967295,this._h3=this._h3+k&4294967295,this._h4=this._h4+D&4294967295}}h._bigBlock32=new DataView(new ArrayBuffer(320))},22467:(rt,ye,y)=>{y.d(ye,{B6:()=>Q,Fd:()=>k,LC:()=>C,P8:()=>w,Pi:()=>u,er:()=>T,iZ:()=>D,n4:()=>g,o1:()=>x,pD:()=>m,su:()=>P,uJ:()=>v});var b=y(78518),o=y(13072),K=y(18019),$=y(63339),L=y(16844),U=y(37264);function P(X){return(0,U.I)(X,!0)}class B{constructor(R){this._ignorePathCasing=R}compare(R,H,Z=!1){return R===H?0:(0,L.UD)(this.getComparisonKey(R,Z),this.getComparisonKey(H,Z))}isEqual(R,H,Z=!1){return R===H?!0:!R||!H?!1:this.getComparisonKey(R,Z)===this.getComparisonKey(H,Z)}getComparisonKey(R,H=!1){return R.with({path:this._ignorePathCasing(R)?R.path.toLowerCase():void 0,fragment:H?null:void 0}).toString()}isEqualOrParent(R,H,Z=!1){if(R.scheme===H.scheme){if(R.scheme===o.ny.file)return b._1(P(R),P(H),this._ignorePathCasing(R))&&R.query===H.query&&(Z||R.fragment===H.fragment);if(W(R.authority,H.authority))return b._1(R.path,H.path,this._ignorePathCasing(R),"/")&&R.query===H.query&&(Z||R.fragment===H.fragment)}return!1}joinPath(R,...H){return U.r.joinPath(R,...H)}basenameOrAuthority(R){return w(R)||R.authority}basename(R){return K.SA.basename(R.path)}extname(R){return K.SA.extname(R.path)}dirname(R){if(R.path.length===0)return R;let H;return R.scheme===o.ny.file?H=U.r.file(K.pD(P(R))).path:(H=K.SA.dirname(R.path),R.authority&&H.length&&H.charCodeAt(0)!==47&&(console.error(`dirname("${R.toString})) resulted in a relative path`),H="/")),R.with({path:H})}normalizePath(R){if(!R.path.length)return R;let H;return R.scheme===o.ny.file?H=U.r.file(K.S8(P(R))).path:H=K.SA.normalize(R.path),R.with({path:H})}relativePath(R,H){if(R.scheme!==H.scheme||!W(R.authority,H.authority))return;if(R.scheme===o.ny.file){const G=K.V8(P(R),P(H));return $.uF?b.TH(G):G}let Z=R.path||"/";const N=H.path||"/";if(this._ignorePathCasing(R)){let G=0;for(const O=Math.min(Z.length,N.length);G<O&&!(Z.charCodeAt(G)!==N.charCodeAt(G)&&Z.charAt(G).toLowerCase()!==N.charAt(G).toLowerCase());G++);Z=N.substr(0,G)+Z.substr(G)}return K.SA.relative(Z,N)}resolvePath(R,H){if(R.scheme===o.ny.file){const Z=U.r.file(K.hd(P(R),H));return R.with({authority:Z.authority,path:Z.path})}return H=b.kb(H),R.with({path:K.SA.resolve(R.path,H)})}isAbsolutePath(R){return!!R.path&&R.path[0]==="/"}isEqualAuthority(R,H){return R===H||R!==void 0&&H!==void 0&&(0,L.Q_)(R,H)}hasTrailingPathSeparator(R,H=K.Vn){if(R.scheme===o.ny.file){const Z=P(R);return Z.length>b.Zn(Z).length&&Z[Z.length-1]===H}else{const Z=R.path;return Z.length>1&&Z.charCodeAt(Z.length-1)===47&&!/^[a-zA-Z]:(\/$|\\$)/.test(R.fsPath)}}removeTrailingPathSeparator(R,H=K.Vn){return Y(R,H)?R.with({path:R.path.substr(0,R.path.length-1)}):R}addTrailingPathSeparator(R,H=K.Vn){let Z=!1;if(R.scheme===o.ny.file){const N=P(R);Z=N!==void 0&&N.length===b.Zn(N).length&&N[N.length-1]===H}else{H="/";const N=R.path;Z=N.length===1&&N.charCodeAt(N.length-1)===47}return!Z&&!Y(R,H)?R.with({path:R.path+"/"}):R}}const T=new B(()=>!1),p=new B(X=>X.scheme===o.ny.file?!$.j9:!0),d=new B(X=>!0),g=T.isEqual.bind(T),h=T.isEqualOrParent.bind(T),l=T.getComparisonKey.bind(T),u=T.basenameOrAuthority.bind(T),w=T.basename.bind(T),C=T.extname.bind(T),m=T.dirname.bind(T),v=T.joinPath.bind(T),k=T.normalizePath.bind(T),D=T.relativePath.bind(T),x=T.resolvePath.bind(T),A=T.isAbsolutePath.bind(T),W=T.isEqualAuthority.bind(T),Y=T.hasTrailingPathSeparator.bind(T),ne=T.removeTrailingPathSeparator.bind(T),j=T.addTrailingPathSeparator.bind(T);var Q;(function(X){X.META_DATA_LABEL="label",X.META_DATA_DESCRIPTION="description",X.META_DATA_SIZE="size",X.META_DATA_MIME="mime";function R(H){const Z=new Map;H.path.substring(H.path.indexOf(";")+1,H.path.lastIndexOf(";")).split(";").forEach(O=>{const[te,oe]=O.split(":");te&&oe&&Z.set(te,oe)});const G=H.path.substring(0,H.path.indexOf(";"));return G&&Z.set(X.META_DATA_MIME,G),Z}X.parseMetaData=R})(Q||(Q={}))},22595:(rt,ye,y)=>{y.d(ye,{f:()=>b});class b{constructor(K,$,L,U,P,B){this.id=K,this.label=$,this.alias=L,this._precondition=U,this._run=P,this._contextKeyService=B}isSupported(){return this._contextKeyService.contextMatchesRules(this._precondition)}run(){return this.isSupported()?this._run():Promise.resolve(void 0)}}},22994:(rt,ye,y)=>{y.d(ye,{W:()=>K,c:()=>o});var b=y(34883);class o{constructor(U,P,B){this.startOffset=U,this.endOffset=P,this.newLength=B}}class K{constructor(U,P){this.documentLength=P,this.nextEditIdx=0,this.deltaOldToNewLineCount=0,this.deltaOldToNewColumnCount=0,this.deltaLineIdxInOld=-1,this.edits=U.map(B=>$.from(B))}getOffsetBeforeChange(U){return this.adjustNextEdit(U),this.translateCurToOld(U)}getDistanceToNextChange(U){this.adjustNextEdit(U);const P=this.edits[this.nextEditIdx],B=P?this.translateOldToCur(P.offsetObj):this.documentLength;return(0,b.MS)(U,B)}translateOldToCur(U){return U.lineCount===this.deltaLineIdxInOld?(0,b.qe)(U.lineCount+this.deltaOldToNewLineCount,U.columnCount+this.deltaOldToNewColumnCount):(0,b.qe)(U.lineCount+this.deltaOldToNewLineCount,U.columnCount)}translateCurToOld(U){const P=(0,b.l4)(U);return P.lineCount-this.deltaOldToNewLineCount===this.deltaLineIdxInOld?(0,b.qe)(P.lineCount-this.deltaOldToNewLineCount,P.columnCount-this.deltaOldToNewColumnCount):(0,b.qe)(P.lineCount-this.deltaOldToNewLineCount,P.columnCount)}adjustNextEdit(U){for(;this.nextEditIdx<this.edits.length;){const P=this.edits[this.nextEditIdx],B=this.translateOldToCur(P.endOffsetAfterObj);if((0,b.vr)(B,U)){this.nextEditIdx++;const T=(0,b.l4)(B),p=(0,b.l4)(this.translateOldToCur(P.endOffsetBeforeObj)),d=T.lineCount-p.lineCount;this.deltaOldToNewLineCount+=d;const g=this.deltaLineIdxInOld===P.endOffsetBeforeObj.lineCount?this.deltaOldToNewColumnCount:0,h=T.columnCount-p.columnCount;this.deltaOldToNewColumnCount=g+h,this.deltaLineIdxInOld=P.endOffsetBeforeObj.lineCount}else break}}}class ${constructor(U,P,B){this.endOffsetBeforeObj=(0,b.l4)(P),this.endOffsetAfterObj=(0,b.l4)((0,b.QB)(U,B)),this.offsetObj=(0,b.l4)(U)}static from(U){return new $(U.startOffset,U.endOffset,U.newLength)}}},23877:(rt,ye,y)=>{y.d(ye,{k:()=>o});var b=y(50442);class o{static insert($,L){return{range:new b.Q($.lineNumber,$.column,$.lineNumber,$.column),text:L,forceMoveMarkers:!0}}static delete($){return{range:$,text:null}}static replace($,L){return{range:$,text:L}}static replaceMove($,L){return{range:$,text:L,forceMoveMarkers:!0}}}},24594:(rt,ye,y)=>{y.d(ye,{_k:()=>h,m2:()=>B,pS:()=>g,pz:()=>u,sA:()=>p});var b=y(26048),o=y(97669),K=y(16844);const $="$(",L=new RegExp(`\\$\\(${b.j3.iconNameExpression}(?:${b.j3.iconModifierExpression})?\\)`,"g"),U=new RegExp(b.j3.iconNameCharacter),P=new RegExp(`(\\\\)?${L.source}`,"g");function B(w){return w.replace(P,(C,m)=>m?C:`\\${C}`)}const T=new RegExp(`\\\\${L.source}`,"g");function p(w){return w.replace(T,C=>`\\${C}`)}const d=new RegExp(`(\\s)?(\\\\)?${L.source}(\\s)?`,"g");function g(w){return w.indexOf($)===-1?w:w.replace(d,(C,m,v,k)=>v?C:m||k||"")}function h(w){const C=w.indexOf($);return C===-1?{text:w}:l(w,C)}function l(w,C){const m=[];let v="";function k(Q){if(Q){v+=Q;for(const X of Q)m.push(A)}}let D=-1,x="",A=0,W,Y,ne=C;const j=w.length;for(k(w.substr(0,C));ne<j;){if(W=w[ne],Y=w[ne+1],W===$[0]&&Y===$[1])D=ne,k(x),x=$,ne++;else if(W===")"&&D!==-1){const Q=ne-D+1;A+=Q,D=-1,x=""}else D!==-1?U.test(W)?x+=W:(k(x),D=-1,x=""):k(W);ne++}return k(x),{text:v,iconOffsets:m}}function u(w,C,m=!1){const{text:v,iconOffsets:k}=C;if(!k||k.length===0)return(0,o.yr)(w,v,m);const D=(0,K.NB)(v," "),x=v.length-D.length,A=(0,o.yr)(w,D,m);if(A)for(const W of A){const Y=k[W.start+x]+x;W.start+=Y,W.end+=Y}return A}},25155:(rt,ye,y)=>{y.d(ye,{M:()=>K});var b=y(2106);class o{constructor(){this._tabFocus=!1,this._onDidChangeTabFocus=new b.vl,this.onDidChangeTabFocus=this._onDidChangeTabFocus.event}getTabFocusMode(){return this._tabFocus}setTabFocusMode(L){this._tabFocus!==L&&(this._tabFocus=L,this._onDidChangeTabFocus.fire(this._tabFocus))}}const K=new o},25837:(rt,ye,y)=>{y.d(ye,{M:()=>o});var b=y(5043);function o(K,$){K instanceof b.D?(K.setFontFamily($.getMassagedFontFamily()),K.setFontWeight($.fontWeight),K.setFontSize($.fontSize),K.setFontFeatureSettings($.fontFeatureSettings),K.setLineHeight($.lineHeight),K.setLetterSpacing($.letterSpacing)):(K.style.fontFamily=$.getMassagedFontFamily(),K.style.fontWeight=$.fontWeight,K.style.fontSize=$.fontSize+"px",K.style.fontFeatureSettings=$.fontFeatureSettings,K.style.lineHeight=$.lineHeight+"px",K.style.letterSpacing=$.letterSpacing+"px")}},26048:(rt,ye,y)=>{y.d(ye,{R$:()=>b,W6:()=>o,j3:()=>K});function b($){return $?$.replace(/\$\((.*?)\)/g,(L,U)=>` ${U} `).trim():""}class o{constructor(L,U,P){this.id=L,this.definition=U,this.description=P,o._allCodicons.push(this)}get classNames(){return"codicon codicon-"+this.id}get classNamesArray(){return["codicon","codicon-"+this.id]}get cssSelector(){return".codicon.codicon-"+this.id}static getAll(){return o._allCodicons}}o._allCodicons=[],o.add=new o("add",{fontCharacter:"\\ea60"}),o.plus=new o("plus",o.add.definition),o.gistNew=new o("gist-new",o.add.definition),o.repoCreate=new o("repo-create",o.add.definition),o.lightbulb=new o("lightbulb",{fontCharacter:"\\ea61"}),o.lightBulb=new o("light-bulb",{fontCharacter:"\\ea61"}),o.repo=new o("repo",{fontCharacter:"\\ea62"}),o.repoDelete=new o("repo-delete",{fontCharacter:"\\ea62"}),o.gistFork=new o("gist-fork",{fontCharacter:"\\ea63"}),o.repoForked=new o("repo-forked",{fontCharacter:"\\ea63"}),o.gitPullRequest=new o("git-pull-request",{fontCharacter:"\\ea64"}),o.gitPullRequestAbandoned=new o("git-pull-request-abandoned",{fontCharacter:"\\ea64"}),o.recordKeys=new o("record-keys",{fontCharacter:"\\ea65"}),o.keyboard=new o("keyboard",{fontCharacter:"\\ea65"}),o.tag=new o("tag",{fontCharacter:"\\ea66"}),o.tagAdd=new o("tag-add",{fontCharacter:"\\ea66"}),o.tagRemove=new o("tag-remove",{fontCharacter:"\\ea66"}),o.person=new o("person",{fontCharacter:"\\ea67"}),o.personFollow=new o("person-follow",{fontCharacter:"\\ea67"}),o.personOutline=new o("person-outline",{fontCharacter:"\\ea67"}),o.personFilled=new o("person-filled",{fontCharacter:"\\ea67"}),o.gitBranch=new o("git-branch",{fontCharacter:"\\ea68"}),o.gitBranchCreate=new o("git-branch-create",{fontCharacter:"\\ea68"}),o.gitBranchDelete=new o("git-branch-delete",{fontCharacter:"\\ea68"}),o.sourceControl=new o("source-control",{fontCharacter:"\\ea68"}),o.mirror=new o("mirror",{fontCharacter:"\\ea69"}),o.mirrorPublic=new o("mirror-public",{fontCharacter:"\\ea69"}),o.star=new o("star",{fontCharacter:"\\ea6a"}),o.starAdd=new o("star-add",{fontCharacter:"\\ea6a"}),o.starDelete=new o("star-delete",{fontCharacter:"\\ea6a"}),o.starEmpty=new o("star-empty",{fontCharacter:"\\ea6a"}),o.comment=new o("comment",{fontCharacter:"\\ea6b"}),o.commentAdd=new o("comment-add",{fontCharacter:"\\ea6b"}),o.alert=new o("alert",{fontCharacter:"\\ea6c"}),o.warning=new o("warning",{fontCharacter:"\\ea6c"}),o.search=new o("search",{fontCharacter:"\\ea6d"}),o.searchSave=new o("search-save",{fontCharacter:"\\ea6d"}),o.logOut=new o("log-out",{fontCharacter:"\\ea6e"}),o.signOut=new o("sign-out",{fontCharacter:"\\ea6e"}),o.logIn=new o("log-in",{fontCharacter:"\\ea6f"}),o.signIn=new o("sign-in",{fontCharacter:"\\ea6f"}),o.eye=new o("eye",{fontCharacter:"\\ea70"}),o.eyeUnwatch=new o("eye-unwatch",{fontCharacter:"\\ea70"}),o.eyeWatch=new o("eye-watch",{fontCharacter:"\\ea70"}),o.circleFilled=new o("circle-filled",{fontCharacter:"\\ea71"}),o.primitiveDot=new o("primitive-dot",{fontCharacter:"\\ea71"}),o.closeDirty=new o("close-dirty",{fontCharacter:"\\ea71"}),o.debugBreakpoint=new o("debug-breakpoint",{fontCharacter:"\\ea71"}),o.debugBreakpointDisabled=new o("debug-breakpoint-disabled",{fontCharacter:"\\ea71"}),o.debugHint=new o("debug-hint",{fontCharacter:"\\ea71"}),o.primitiveSquare=new o("primitive-square",{fontCharacter:"\\ea72"}),o.edit=new o("edit",{fontCharacter:"\\ea73"}),o.pencil=new o("pencil",{fontCharacter:"\\ea73"}),o.info=new o("info",{fontCharacter:"\\ea74"}),o.issueOpened=new o("issue-opened",{fontCharacter:"\\ea74"}),o.gistPrivate=new o("gist-private",{fontCharacter:"\\ea75"}),o.gitForkPrivate=new o("git-fork-private",{fontCharacter:"\\ea75"}),o.lock=new o("lock",{fontCharacter:"\\ea75"}),o.mirrorPrivate=new o("mirror-private",{fontCharacter:"\\ea75"}),o.close=new o("close",{fontCharacter:"\\ea76"}),o.removeClose=new o("remove-close",{fontCharacter:"\\ea76"}),o.x=new o("x",{fontCharacter:"\\ea76"}),o.repoSync=new o("repo-sync",{fontCharacter:"\\ea77"}),o.sync=new o("sync",{fontCharacter:"\\ea77"}),o.clone=new o("clone",{fontCharacter:"\\ea78"}),o.desktopDownload=new o("desktop-download",{fontCharacter:"\\ea78"}),o.beaker=new o("beaker",{fontCharacter:"\\ea79"}),o.microscope=new o("microscope",{fontCharacter:"\\ea79"}),o.vm=new o("vm",{fontCharacter:"\\ea7a"}),o.deviceDesktop=new o("device-desktop",{fontCharacter:"\\ea7a"}),o.file=new o("file",{fontCharacter:"\\ea7b"}),o.fileText=new o("file-text",{fontCharacter:"\\ea7b"}),o.more=new o("more",{fontCharacter:"\\ea7c"}),o.ellipsis=new o("ellipsis",{fontCharacter:"\\ea7c"}),o.kebabHorizontal=new o("kebab-horizontal",{fontCharacter:"\\ea7c"}),o.mailReply=new o("mail-reply",{fontCharacter:"\\ea7d"}),o.reply=new o("reply",{fontCharacter:"\\ea7d"}),o.organization=new o("organization",{fontCharacter:"\\ea7e"}),o.organizationFilled=new o("organization-filled",{fontCharacter:"\\ea7e"}),o.organizationOutline=new o("organization-outline",{fontCharacter:"\\ea7e"}),o.newFile=new o("new-file",{fontCharacter:"\\ea7f"}),o.fileAdd=new o("file-add",{fontCharacter:"\\ea7f"}),o.newFolder=new o("new-folder",{fontCharacter:"\\ea80"}),o.fileDirectoryCreate=new o("file-directory-create",{fontCharacter:"\\ea80"}),o.trash=new o("trash",{fontCharacter:"\\ea81"}),o.trashcan=new o("trashcan",{fontCharacter:"\\ea81"}),o.history=new o("history",{fontCharacter:"\\ea82"}),o.clock=new o("clock",{fontCharacter:"\\ea82"}),o.folder=new o("folder",{fontCharacter:"\\ea83"}),o.fileDirectory=new o("file-directory",{fontCharacter:"\\ea83"}),o.symbolFolder=new o("symbol-folder",{fontCharacter:"\\ea83"}),o.logoGithub=new o("logo-github",{fontCharacter:"\\ea84"}),o.markGithub=new o("mark-github",{fontCharacter:"\\ea84"}),o.github=new o("github",{fontCharacter:"\\ea84"}),o.terminal=new o("terminal",{fontCharacter:"\\ea85"}),o.console=new o("console",{fontCharacter:"\\ea85"}),o.repl=new o("repl",{fontCharacter:"\\ea85"}),o.zap=new o("zap",{fontCharacter:"\\ea86"}),o.symbolEvent=new o("symbol-event",{fontCharacter:"\\ea86"}),o.error=new o("error",{fontCharacter:"\\ea87"}),o.stop=new o("stop",{fontCharacter:"\\ea87"}),o.variable=new o("variable",{fontCharacter:"\\ea88"}),o.symbolVariable=new o("symbol-variable",{fontCharacter:"\\ea88"}),o.array=new o("array",{fontCharacter:"\\ea8a"}),o.symbolArray=new o("symbol-array",{fontCharacter:"\\ea8a"}),o.symbolModule=new o("symbol-module",{fontCharacter:"\\ea8b"}),o.symbolPackage=new o("symbol-package",{fontCharacter:"\\ea8b"}),o.symbolNamespace=new o("symbol-namespace",{fontCharacter:"\\ea8b"}),o.symbolObject=new o("symbol-object",{fontCharacter:"\\ea8b"}),o.symbolMethod=new o("symbol-method",{fontCharacter:"\\ea8c"}),o.symbolFunction=new o("symbol-function",{fontCharacter:"\\ea8c"}),o.symbolConstructor=new o("symbol-constructor",{fontCharacter:"\\ea8c"}),o.symbolBoolean=new o("symbol-boolean",{fontCharacter:"\\ea8f"}),o.symbolNull=new o("symbol-null",{fontCharacter:"\\ea8f"}),o.symbolNumeric=new o("symbol-numeric",{fontCharacter:"\\ea90"}),o.symbolNumber=new o("symbol-number",{fontCharacter:"\\ea90"}),o.symbolStructure=new o("symbol-structure",{fontCharacter:"\\ea91"}),o.symbolStruct=new o("symbol-struct",{fontCharacter:"\\ea91"}),o.symbolParameter=new o("symbol-parameter",{fontCharacter:"\\ea92"}),o.symbolTypeParameter=new o("symbol-type-parameter",{fontCharacter:"\\ea92"}),o.symbolKey=new o("symbol-key",{fontCharacter:"\\ea93"}),o.symbolText=new o("symbol-text",{fontCharacter:"\\ea93"}),o.symbolReference=new o("symbol-reference",{fontCharacter:"\\ea94"}),o.goToFile=new o("go-to-file",{fontCharacter:"\\ea94"}),o.symbolEnum=new o("symbol-enum",{fontCharacter:"\\ea95"}),o.symbolValue=new o("symbol-value",{fontCharacter:"\\ea95"}),o.symbolRuler=new o("symbol-ruler",{fontCharacter:"\\ea96"}),o.symbolUnit=new o("symbol-unit",{fontCharacter:"\\ea96"}),o.activateBreakpoints=new o("activate-breakpoints",{fontCharacter:"\\ea97"}),o.archive=new o("archive",{fontCharacter:"\\ea98"}),o.arrowBoth=new o("arrow-both",{fontCharacter:"\\ea99"}),o.arrowDown=new o("arrow-down",{fontCharacter:"\\ea9a"}),o.arrowLeft=new o("arrow-left",{fontCharacter:"\\ea9b"}),o.arrowRight=new o("arrow-right",{fontCharacter:"\\ea9c"}),o.arrowSmallDown=new o("arrow-small-down",{fontCharacter:"\\ea9d"}),o.arrowSmallLeft=new o("arrow-small-left",{fontCharacter:"\\ea9e"}),o.arrowSmallRight=new o("arrow-small-right",{fontCharacter:"\\ea9f"}),o.arrowSmallUp=new o("arrow-small-up",{fontCharacter:"\\eaa0"}),o.arrowUp=new o("arrow-up",{fontCharacter:"\\eaa1"}),o.bell=new o("bell",{fontCharacter:"\\eaa2"}),o.bold=new o("bold",{fontCharacter:"\\eaa3"}),o.book=new o("book",{fontCharacter:"\\eaa4"}),o.bookmark=new o("bookmark",{fontCharacter:"\\eaa5"}),o.debugBreakpointConditionalUnverified=new o("debug-breakpoint-conditional-unverified",{fontCharacter:"\\eaa6"}),o.debugBreakpointConditional=new o("debug-breakpoint-conditional",{fontCharacter:"\\eaa7"}),o.debugBreakpointConditionalDisabled=new o("debug-breakpoint-conditional-disabled",{fontCharacter:"\\eaa7"}),o.debugBreakpointDataUnverified=new o("debug-breakpoint-data-unverified",{fontCharacter:"\\eaa8"}),o.debugBreakpointData=new o("debug-breakpoint-data",{fontCharacter:"\\eaa9"}),o.debugBreakpointDataDisabled=new o("debug-breakpoint-data-disabled",{fontCharacter:"\\eaa9"}),o.debugBreakpointLogUnverified=new o("debug-breakpoint-log-unverified",{fontCharacter:"\\eaaa"}),o.debugBreakpointLog=new o("debug-breakpoint-log",{fontCharacter:"\\eaab"}),o.debugBreakpointLogDisabled=new o("debug-breakpoint-log-disabled",{fontCharacter:"\\eaab"}),o.briefcase=new o("briefcase",{fontCharacter:"\\eaac"}),o.broadcast=new o("broadcast",{fontCharacter:"\\eaad"}),o.browser=new o("browser",{fontCharacter:"\\eaae"}),o.bug=new o("bug",{fontCharacter:"\\eaaf"}),o.calendar=new o("calendar",{fontCharacter:"\\eab0"}),o.caseSensitive=new o("case-sensitive",{fontCharacter:"\\eab1"}),o.check=new o("check",{fontCharacter:"\\eab2"}),o.checklist=new o("checklist",{fontCharacter:"\\eab3"}),o.chevronDown=new o("chevron-down",{fontCharacter:"\\eab4"}),o.dropDownButton=new o("drop-down-button",o.chevronDown.definition),o.chevronLeft=new o("chevron-left",{fontCharacter:"\\eab5"}),o.chevronRight=new o("chevron-right",{fontCharacter:"\\eab6"}),o.chevronUp=new o("chevron-up",{fontCharacter:"\\eab7"}),o.chromeClose=new o("chrome-close",{fontCharacter:"\\eab8"}),o.chromeMaximize=new o("chrome-maximize",{fontCharacter:"\\eab9"}),o.chromeMinimize=new o("chrome-minimize",{fontCharacter:"\\eaba"}),o.chromeRestore=new o("chrome-restore",{fontCharacter:"\\eabb"}),o.circleOutline=new o("circle-outline",{fontCharacter:"\\eabc"}),o.debugBreakpointUnverified=new o("debug-breakpoint-unverified",{fontCharacter:"\\eabc"}),o.circleSlash=new o("circle-slash",{fontCharacter:"\\eabd"}),o.circuitBoard=new o("circuit-board",{fontCharacter:"\\eabe"}),o.clearAll=new o("clear-all",{fontCharacter:"\\eabf"}),o.clippy=new o("clippy",{fontCharacter:"\\eac0"}),o.closeAll=new o("close-all",{fontCharacter:"\\eac1"}),o.cloudDownload=new o("cloud-download",{fontCharacter:"\\eac2"}),o.cloudUpload=new o("cloud-upload",{fontCharacter:"\\eac3"}),o.code=new o("code",{fontCharacter:"\\eac4"}),o.collapseAll=new o("collapse-all",{fontCharacter:"\\eac5"}),o.colorMode=new o("color-mode",{fontCharacter:"\\eac6"}),o.commentDiscussion=new o("comment-discussion",{fontCharacter:"\\eac7"}),o.compareChanges=new o("compare-changes",{fontCharacter:"\\eafd"}),o.creditCard=new o("credit-card",{fontCharacter:"\\eac9"}),o.dash=new o("dash",{fontCharacter:"\\eacc"}),o.dashboard=new o("dashboard",{fontCharacter:"\\eacd"}),o.database=new o("database",{fontCharacter:"\\eace"}),o.debugContinue=new o("debug-continue",{fontCharacter:"\\eacf"}),o.debugDisconnect=new o("debug-disconnect",{fontCharacter:"\\ead0"}),o.debugPause=new o("debug-pause",{fontCharacter:"\\ead1"}),o.debugRestart=new o("debug-restart",{fontCharacter:"\\ead2"}),o.debugStart=new o("debug-start",{fontCharacter:"\\ead3"}),o.debugStepInto=new o("debug-step-into",{fontCharacter:"\\ead4"}),o.debugStepOut=new o("debug-step-out",{fontCharacter:"\\ead5"}),o.debugStepOver=new o("debug-step-over",{fontCharacter:"\\ead6"}),o.debugStop=new o("debug-stop",{fontCharacter:"\\ead7"}),o.debug=new o("debug",{fontCharacter:"\\ead8"}),o.deviceCameraVideo=new o("device-camera-video",{fontCharacter:"\\ead9"}),o.deviceCamera=new o("device-camera",{fontCharacter:"\\eada"}),o.deviceMobile=new o("device-mobile",{fontCharacter:"\\eadb"}),o.diffAdded=new o("diff-added",{fontCharacter:"\\eadc"}),o.diffIgnored=new o("diff-ignored",{fontCharacter:"\\eadd"}),o.diffModified=new o("diff-modified",{fontCharacter:"\\eade"}),o.diffRemoved=new o("diff-removed",{fontCharacter:"\\eadf"}),o.diffRenamed=new o("diff-renamed",{fontCharacter:"\\eae0"}),o.diff=new o("diff",{fontCharacter:"\\eae1"}),o.discard=new o("discard",{fontCharacter:"\\eae2"}),o.editorLayout=new o("editor-layout",{fontCharacter:"\\eae3"}),o.emptyWindow=new o("empty-window",{fontCharacter:"\\eae4"}),o.exclude=new o("exclude",{fontCharacter:"\\eae5"}),o.extensions=new o("extensions",{fontCharacter:"\\eae6"}),o.eyeClosed=new o("eye-closed",{fontCharacter:"\\eae7"}),o.fileBinary=new o("file-binary",{fontCharacter:"\\eae8"}),o.fileCode=new o("file-code",{fontCharacter:"\\eae9"}),o.fileMedia=new o("file-media",{fontCharacter:"\\eaea"}),o.filePdf=new o("file-pdf",{fontCharacter:"\\eaeb"}),o.fileSubmodule=new o("file-submodule",{fontCharacter:"\\eaec"}),o.fileSymlinkDirectory=new o("file-symlink-directory",{fontCharacter:"\\eaed"}),o.fileSymlinkFile=new o("file-symlink-file",{fontCharacter:"\\eaee"}),o.fileZip=new o("file-zip",{fontCharacter:"\\eaef"}),o.files=new o("files",{fontCharacter:"\\eaf0"}),o.filter=new o("filter",{fontCharacter:"\\eaf1"}),o.flame=new o("flame",{fontCharacter:"\\eaf2"}),o.foldDown=new o("fold-down",{fontCharacter:"\\eaf3"}),o.foldUp=new o("fold-up",{fontCharacter:"\\eaf4"}),o.fold=new o("fold",{fontCharacter:"\\eaf5"}),o.folderActive=new o("folder-active",{fontCharacter:"\\eaf6"}),o.folderOpened=new o("folder-opened",{fontCharacter:"\\eaf7"}),o.gear=new o("gear",{fontCharacter:"\\eaf8"}),o.gift=new o("gift",{fontCharacter:"\\eaf9"}),o.gistSecret=new o("gist-secret",{fontCharacter:"\\eafa"}),o.gist=new o("gist",{fontCharacter:"\\eafb"}),o.gitCommit=new o("git-commit",{fontCharacter:"\\eafc"}),o.gitCompare=new o("git-compare",{fontCharacter:"\\eafd"}),o.gitMerge=new o("git-merge",{fontCharacter:"\\eafe"}),o.githubAction=new o("github-action",{fontCharacter:"\\eaff"}),o.githubAlt=new o("github-alt",{fontCharacter:"\\eb00"}),o.globe=new o("globe",{fontCharacter:"\\eb01"}),o.grabber=new o("grabber",{fontCharacter:"\\eb02"}),o.graph=new o("graph",{fontCharacter:"\\eb03"}),o.gripper=new o("gripper",{fontCharacter:"\\eb04"}),o.heart=new o("heart",{fontCharacter:"\\eb05"}),o.home=new o("home",{fontCharacter:"\\eb06"}),o.horizontalRule=new o("horizontal-rule",{fontCharacter:"\\eb07"}),o.hubot=new o("hubot",{fontCharacter:"\\eb08"}),o.inbox=new o("inbox",{fontCharacter:"\\eb09"}),o.issueClosed=new o("issue-closed",{fontCharacter:"\\eba4"}),o.issueReopened=new o("issue-reopened",{fontCharacter:"\\eb0b"}),o.issues=new o("issues",{fontCharacter:"\\eb0c"}),o.italic=new o("italic",{fontCharacter:"\\eb0d"}),o.jersey=new o("jersey",{fontCharacter:"\\eb0e"}),o.json=new o("json",{fontCharacter:"\\eb0f"}),o.kebabVertical=new o("kebab-vertical",{fontCharacter:"\\eb10"}),o.key=new o("key",{fontCharacter:"\\eb11"}),o.law=new o("law",{fontCharacter:"\\eb12"}),o.lightbulbAutofix=new o("lightbulb-autofix",{fontCharacter:"\\eb13"}),o.linkExternal=new o("link-external",{fontCharacter:"\\eb14"}),o.link=new o("link",{fontCharacter:"\\eb15"}),o.listOrdered=new o("list-ordered",{fontCharacter:"\\eb16"}),o.listUnordered=new o("list-unordered",{fontCharacter:"\\eb17"}),o.liveShare=new o("live-share",{fontCharacter:"\\eb18"}),o.loading=new o("loading",{fontCharacter:"\\eb19"}),o.location=new o("location",{fontCharacter:"\\eb1a"}),o.mailRead=new o("mail-read",{fontCharacter:"\\eb1b"}),o.mail=new o("mail",{fontCharacter:"\\eb1c"}),o.markdown=new o("markdown",{fontCharacter:"\\eb1d"}),o.megaphone=new o("megaphone",{fontCharacter:"\\eb1e"}),o.mention=new o("mention",{fontCharacter:"\\eb1f"}),o.milestone=new o("milestone",{fontCharacter:"\\eb20"}),o.mortarBoard=new o("mortar-board",{fontCharacter:"\\eb21"}),o.move=new o("move",{fontCharacter:"\\eb22"}),o.multipleWindows=new o("multiple-windows",{fontCharacter:"\\eb23"}),o.mute=new o("mute",{fontCharacter:"\\eb24"}),o.noNewline=new o("no-newline",{fontCharacter:"\\eb25"}),o.note=new o("note",{fontCharacter:"\\eb26"}),o.octoface=new o("octoface",{fontCharacter:"\\eb27"}),o.openPreview=new o("open-preview",{fontCharacter:"\\eb28"}),o.package_=new o("package",{fontCharacter:"\\eb29"}),o.paintcan=new o("paintcan",{fontCharacter:"\\eb2a"}),o.pin=new o("pin",{fontCharacter:"\\eb2b"}),o.play=new o("play",{fontCharacter:"\\eb2c"}),o.run=new o("run",{fontCharacter:"\\eb2c"}),o.plug=new o("plug",{fontCharacter:"\\eb2d"}),o.preserveCase=new o("preserve-case",{fontCharacter:"\\eb2e"}),o.preview=new o("preview",{fontCharacter:"\\eb2f"}),o.project=new o("project",{fontCharacter:"\\eb30"}),o.pulse=new o("pulse",{fontCharacter:"\\eb31"}),o.question=new o("question",{fontCharacter:"\\eb32"}),o.quote=new o("quote",{fontCharacter:"\\eb33"}),o.radioTower=new o("radio-tower",{fontCharacter:"\\eb34"}),o.reactions=new o("reactions",{fontCharacter:"\\eb35"}),o.references=new o("references",{fontCharacter:"\\eb36"}),o.refresh=new o("refresh",{fontCharacter:"\\eb37"}),o.regex=new o("regex",{fontCharacter:"\\eb38"}),o.remoteExplorer=new o("remote-explorer",{fontCharacter:"\\eb39"}),o.remote=new o("remote",{fontCharacter:"\\eb3a"}),o.remove=new o("remove",{fontCharacter:"\\eb3b"}),o.replaceAll=new o("replace-all",{fontCharacter:"\\eb3c"}),o.replace=new o("replace",{fontCharacter:"\\eb3d"}),o.repoClone=new o("repo-clone",{fontCharacter:"\\eb3e"}),o.repoForcePush=new o("repo-force-push",{fontCharacter:"\\eb3f"}),o.repoPull=new o("repo-pull",{fontCharacter:"\\eb40"}),o.repoPush=new o("repo-push",{fontCharacter:"\\eb41"}),o.report=new o("report",{fontCharacter:"\\eb42"}),o.requestChanges=new o("request-changes",{fontCharacter:"\\eb43"}),o.rocket=new o("rocket",{fontCharacter:"\\eb44"}),o.rootFolderOpened=new o("root-folder-opened",{fontCharacter:"\\eb45"}),o.rootFolder=new o("root-folder",{fontCharacter:"\\eb46"}),o.rss=new o("rss",{fontCharacter:"\\eb47"}),o.ruby=new o("ruby",{fontCharacter:"\\eb48"}),o.saveAll=new o("save-all",{fontCharacter:"\\eb49"}),o.saveAs=new o("save-as",{fontCharacter:"\\eb4a"}),o.save=new o("save",{fontCharacter:"\\eb4b"}),o.screenFull=new o("screen-full",{fontCharacter:"\\eb4c"}),o.screenNormal=new o("screen-normal",{fontCharacter:"\\eb4d"}),o.searchStop=new o("search-stop",{fontCharacter:"\\eb4e"}),o.server=new o("server",{fontCharacter:"\\eb50"}),o.settingsGear=new o("settings-gear",{fontCharacter:"\\eb51"}),o.settings=new o("settings",{fontCharacter:"\\eb52"}),o.shield=new o("shield",{fontCharacter:"\\eb53"}),o.smiley=new o("smiley",{fontCharacter:"\\eb54"}),o.sortPrecedence=new o("sort-precedence",{fontCharacter:"\\eb55"}),o.splitHorizontal=new o("split-horizontal",{fontCharacter:"\\eb56"}),o.splitVertical=new o("split-vertical",{fontCharacter:"\\eb57"}),o.squirrel=new o("squirrel",{fontCharacter:"\\eb58"}),o.starFull=new o("star-full",{fontCharacter:"\\eb59"}),o.starHalf=new o("star-half",{fontCharacter:"\\eb5a"}),o.symbolClass=new o("symbol-class",{fontCharacter:"\\eb5b"}),o.symbolColor=new o("symbol-color",{fontCharacter:"\\eb5c"}),o.symbolCustomColor=new o("symbol-customcolor",{fontCharacter:"\\eb5c"}),o.symbolConstant=new o("symbol-constant",{fontCharacter:"\\eb5d"}),o.symbolEnumMember=new o("symbol-enum-member",{fontCharacter:"\\eb5e"}),o.symbolField=new o("symbol-field",{fontCharacter:"\\eb5f"}),o.symbolFile=new o("symbol-file",{fontCharacter:"\\eb60"}),o.symbolInterface=new o("symbol-interface",{fontCharacter:"\\eb61"}),o.symbolKeyword=new o("symbol-keyword",{fontCharacter:"\\eb62"}),o.symbolMisc=new o("symbol-misc",{fontCharacter:"\\eb63"}),o.symbolOperator=new o("symbol-operator",{fontCharacter:"\\eb64"}),o.symbolProperty=new o("symbol-property",{fontCharacter:"\\eb65"}),o.wrench=new o("wrench",{fontCharacter:"\\eb65"}),o.wrenchSubaction=new o("wrench-subaction",{fontCharacter:"\\eb65"}),o.symbolSnippet=new o("symbol-snippet",{fontCharacter:"\\eb66"}),o.tasklist=new o("tasklist",{fontCharacter:"\\eb67"}),o.telescope=new o("telescope",{fontCharacter:"\\eb68"}),o.textSize=new o("text-size",{fontCharacter:"\\eb69"}),o.threeBars=new o("three-bars",{fontCharacter:"\\eb6a"}),o.thumbsdown=new o("thumbsdown",{fontCharacter:"\\eb6b"}),o.thumbsup=new o("thumbsup",{fontCharacter:"\\eb6c"}),o.tools=new o("tools",{fontCharacter:"\\eb6d"}),o.triangleDown=new o("triangle-down",{fontCharacter:"\\eb6e"}),o.triangleLeft=new o("triangle-left",{fontCharacter:"\\eb6f"}),o.triangleRight=new o("triangle-right",{fontCharacter:"\\eb70"}),o.triangleUp=new o("triangle-up",{fontCharacter:"\\eb71"}),o.twitter=new o("twitter",{fontCharacter:"\\eb72"}),o.unfold=new o("unfold",{fontCharacter:"\\eb73"}),o.unlock=new o("unlock",{fontCharacter:"\\eb74"}),o.unmute=new o("unmute",{fontCharacter:"\\eb75"}),o.unverified=new o("unverified",{fontCharacter:"\\eb76"}),o.verified=new o("verified",{fontCharacter:"\\eb77"}),o.versions=new o("versions",{fontCharacter:"\\eb78"}),o.vmActive=new o("vm-active",{fontCharacter:"\\eb79"}),o.vmOutline=new o("vm-outline",{fontCharacter:"\\eb7a"}),o.vmRunning=new o("vm-running",{fontCharacter:"\\eb7b"}),o.watch=new o("watch",{fontCharacter:"\\eb7c"}),o.whitespace=new o("whitespace",{fontCharacter:"\\eb7d"}),o.wholeWord=new o("whole-word",{fontCharacter:"\\eb7e"}),o.window=new o("window",{fontCharacter:"\\eb7f"}),o.wordWrap=new o("word-wrap",{fontCharacter:"\\eb80"}),o.zoomIn=new o("zoom-in",{fontCharacter:"\\eb81"}),o.zoomOut=new o("zoom-out",{fontCharacter:"\\eb82"}),o.listFilter=new o("list-filter",{fontCharacter:"\\eb83"}),o.listFlat=new o("list-flat",{fontCharacter:"\\eb84"}),o.listSelection=new o("list-selection",{fontCharacter:"\\eb85"}),o.selection=new o("selection",{fontCharacter:"\\eb85"}),o.listTree=new o("list-tree",{fontCharacter:"\\eb86"}),o.debugBreakpointFunctionUnverified=new o("debug-breakpoint-function-unverified",{fontCharacter:"\\eb87"}),o.debugBreakpointFunction=new o("debug-breakpoint-function",{fontCharacter:"\\eb88"}),o.debugBreakpointFunctionDisabled=new o("debug-breakpoint-function-disabled",{fontCharacter:"\\eb88"}),o.debugStackframeActive=new o("debug-stackframe-active",{fontCharacter:"\\eb89"}),o.circleSmallFilled=new o("circle-small-filled",{fontCharacter:"\\eb8a"}),o.debugStackframeDot=new o("debug-stackframe-dot",o.circleSmallFilled.definition),o.debugStackframe=new o("debug-stackframe",{fontCharacter:"\\eb8b"}),o.debugStackframeFocused=new o("debug-stackframe-focused",{fontCharacter:"\\eb8b"}),o.debugBreakpointUnsupported=new o("debug-breakpoint-unsupported",{fontCharacter:"\\eb8c"}),o.symbolString=new o("symbol-string",{fontCharacter:"\\eb8d"}),o.debugReverseContinue=new o("debug-reverse-continue",{fontCharacter:"\\eb8e"}),o.debugStepBack=new o("debug-step-back",{fontCharacter:"\\eb8f"}),o.debugRestartFrame=new o("debug-restart-frame",{fontCharacter:"\\eb90"}),o.callIncoming=new o("call-incoming",{fontCharacter:"\\eb92"}),o.callOutgoing=new o("call-outgoing",{fontCharacter:"\\eb93"}),o.menu=new o("menu",{fontCharacter:"\\eb94"}),o.expandAll=new o("expand-all",{fontCharacter:"\\eb95"}),o.feedback=new o("feedback",{fontCharacter:"\\eb96"}),o.groupByRefType=new o("group-by-ref-type",{fontCharacter:"\\eb97"}),o.ungroupByRefType=new o("ungroup-by-ref-type",{fontCharacter:"\\eb98"}),o.account=new o("account",{fontCharacter:"\\eb99"}),o.bellDot=new o("bell-dot",{fontCharacter:"\\eb9a"}),o.debugConsole=new o("debug-console",{fontCharacter:"\\eb9b"}),o.library=new o("library",{fontCharacter:"\\eb9c"}),o.output=new o("output",{fontCharacter:"\\eb9d"}),o.runAll=new o("run-all",{fontCharacter:"\\eb9e"}),o.syncIgnored=new o("sync-ignored",{fontCharacter:"\\eb9f"}),o.pinned=new o("pinned",{fontCharacter:"\\eba0"}),o.githubInverted=new o("github-inverted",{fontCharacter:"\\eba1"}),o.debugAlt=new o("debug-alt",{fontCharacter:"\\eb91"}),o.serverProcess=new o("server-process",{fontCharacter:"\\eba2"}),o.serverEnvironment=new o("server-environment",{fontCharacter:"\\eba3"}),o.pass=new o("pass",{fontCharacter:"\\eba4"}),o.stopCircle=new o("stop-circle",{fontCharacter:"\\eba5"}),o.playCircle=new o("play-circle",{fontCharacter:"\\eba6"}),o.record=new o("record",{fontCharacter:"\\eba7"}),o.debugAltSmall=new o("debug-alt-small",{fontCharacter:"\\eba8"}),o.vmConnect=new o("vm-connect",{fontCharacter:"\\eba9"}),o.cloud=new o("cloud",{fontCharacter:"\\ebaa"}),o.merge=new o("merge",{fontCharacter:"\\ebab"}),o.exportIcon=new o("export",{fontCharacter:"\\ebac"}),o.graphLeft=new o("graph-left",{fontCharacter:"\\ebad"}),o.magnet=new o("magnet",{fontCharacter:"\\ebae"}),o.notebook=new o("notebook",{fontCharacter:"\\ebaf"}),o.redo=new o("redo",{fontCharacter:"\\ebb0"}),o.checkAll=new o("check-all",{fontCharacter:"\\ebb1"}),o.pinnedDirty=new o("pinned-dirty",{fontCharacter:"\\ebb2"}),o.passFilled=new o("pass-filled",{fontCharacter:"\\ebb3"}),o.circleLargeFilled=new o("circle-large-filled",{fontCharacter:"\\ebb4"}),o.circleLargeOutline=new o("circle-large-outline",{fontCharacter:"\\ebb5"}),o.combine=new o("combine",{fontCharacter:"\\ebb6"}),o.gather=new o("gather",{fontCharacter:"\\ebb6"}),o.table=new o("table",{fontCharacter:"\\ebb7"}),o.variableGroup=new o("variable-group",{fontCharacter:"\\ebb8"}),o.typeHierarchy=new o("type-hierarchy",{fontCharacter:"\\ebb9"}),o.typeHierarchySub=new o("type-hierarchy-sub",{fontCharacter:"\\ebba"}),o.typeHierarchySuper=new o("type-hierarchy-super",{fontCharacter:"\\ebbb"}),o.gitPullRequestCreate=new o("git-pull-request-create",{fontCharacter:"\\ebbc"}),o.runAbove=new o("run-above",{fontCharacter:"\\ebbd"}),o.runBelow=new o("run-below",{fontCharacter:"\\ebbe"}),o.notebookTemplate=new o("notebook-template",{fontCharacter:"\\ebbf"}),o.debugRerun=new o("debug-rerun",{fontCharacter:"\\ebc0"}),o.workspaceTrusted=new o("workspace-trusted",{fontCharacter:"\\ebc1"}),o.workspaceUntrusted=new o("workspace-untrusted",{fontCharacter:"\\ebc2"}),o.workspaceUnspecified=new o("workspace-unspecified",{fontCharacter:"\\ebc3"}),o.terminalCmd=new o("terminal-cmd",{fontCharacter:"\\ebc4"}),o.terminalDebian=new o("terminal-debian",{fontCharacter:"\\ebc5"}),o.terminalLinux=new o("terminal-linux",{fontCharacter:"\\ebc6"}),o.terminalPowershell=new o("terminal-powershell",{fontCharacter:"\\ebc7"}),o.terminalTmux=new o("terminal-tmux",{fontCharacter:"\\ebc8"}),o.terminalUbuntu=new o("terminal-ubuntu",{fontCharacter:"\\ebc9"}),o.terminalBash=new o("terminal-bash",{fontCharacter:"\\ebca"}),o.arrowSwap=new o("arrow-swap",{fontCharacter:"\\ebcb"}),o.copy=new o("copy",{fontCharacter:"\\ebcc"}),o.personAdd=new o("person-add",{fontCharacter:"\\ebcd"}),o.filterFilled=new o("filter-filled",{fontCharacter:"\\ebce"}),o.wand=new o("wand",{fontCharacter:"\\ebcf"}),o.debugLineByLine=new o("debug-line-by-line",{fontCharacter:"\\ebd0"}),o.inspect=new o("inspect",{fontCharacter:"\\ebd1"}),o.layers=new o("layers",{fontCharacter:"\\ebd2"}),o.layersDot=new o("layers-dot",{fontCharacter:"\\ebd3"}),o.layersActive=new o("layers-active",{fontCharacter:"\\ebd4"}),o.compass=new o("compass",{fontCharacter:"\\ebd5"}),o.compassDot=new o("compass-dot",{fontCharacter:"\\ebd6"}),o.compassActive=new o("compass-active",{fontCharacter:"\\ebd7"}),o.azure=new o("azure",{fontCharacter:"\\ebd8"}),o.issueDraft=new o("issue-draft",{fontCharacter:"\\ebd9"}),o.gitPullRequestClosed=new o("git-pull-request-closed",{fontCharacter:"\\ebda"}),o.gitPullRequestDraft=new o("git-pull-request-draft",{fontCharacter:"\\ebdb"}),o.debugAll=new o("debug-all",{fontCharacter:"\\ebdc"}),o.debugCoverage=new o("debug-coverage",{fontCharacter:"\\ebdd"}),o.runErrors=new o("run-errors",{fontCharacter:"\\ebde"}),o.folderLibrary=new o("folder-library",{fontCharacter:"\\ebdf"}),o.debugContinueSmall=new o("debug-continue-small",{fontCharacter:"\\ebe0"}),o.beakerStop=new o("beaker-stop",{fontCharacter:"\\ebe1"}),o.graphLine=new o("graph-line",{fontCharacter:"\\ebe2"}),o.graphScatter=new o("graph-scatter",{fontCharacter:"\\ebe3"}),o.pieChart=new o("pie-chart",{fontCharacter:"\\ebe4"}),o.bracket=new o("bracket",o.json.definition),o.bracketDot=new o("bracket-dot",{fontCharacter:"\\ebe5"}),o.bracketError=new o("bracket-error",{fontCharacter:"\\ebe6"}),o.lockSmall=new o("lock-small",{fontCharacter:"\\ebe7"}),o.azureDevops=new o("azure-devops",{fontCharacter:"\\ebe8"}),o.verifiedFilled=new o("verified-filled",{fontCharacter:"\\ebe9"}),o.newLine=new o("newline",{fontCharacter:"\\ebea"}),o.layout=new o("layout",{fontCharacter:"\\ebeb"}),o.layoutActivitybarLeft=new o("layout-activitybar-left",{fontCharacter:"\\ebec"}),o.layoutActivitybarRight=new o("layout-activitybar-right",{fontCharacter:"\\ebed"}),o.layoutPanelLeft=new o("layout-panel-left",{fontCharacter:"\\ebee"}),o.layoutPanelCenter=new o("layout-panel-center",{fontCharacter:"\\ebef"}),o.layoutPanelJustify=new o("layout-panel-justify",{fontCharacter:"\\ebf0"}),o.layoutPanelRight=new o("layout-panel-right",{fontCharacter:"\\ebf1"}),o.layoutPanel=new o("layout-panel",{fontCharacter:"\\ebf2"}),o.layoutSidebarLeft=new o("layout-sidebar-left",{fontCharacter:"\\ebf3"}),o.layoutSidebarRight=new o("layout-sidebar-right",{fontCharacter:"\\ebf4"}),o.layoutStatusbar=new o("layout-statusbar",{fontCharacter:"\\ebf5"}),o.layoutMenubar=new o("layout-menubar",{fontCharacter:"\\ebf6"}),o.layoutCentered=new o("layout-centered",{fontCharacter:"\\ebf7"}),o.layoutSidebarRightOff=new o("layout-sidebar-right-off",{fontCharacter:"\\ec00"}),o.layoutPanelOff=new o("layout-panel-off",{fontCharacter:"\\ec01"}),o.layoutSidebarLeftOff=new o("layout-sidebar-left-off",{fontCharacter:"\\ec02"}),o.target=new o("target",{fontCharacter:"\\ebf8"}),o.indent=new o("indent",{fontCharacter:"\\ebf9"}),o.recordSmall=new o("record-small",{fontCharacter:"\\ebfa"}),o.errorSmall=new o("error-small",{fontCharacter:"\\ebfb"}),o.arrowCircleDown=new o("arrow-circle-down",{fontCharacter:"\\ebfc"}),o.arrowCircleLeft=new o("arrow-circle-left",{fontCharacter:"\\ebfd"}),o.arrowCircleRight=new o("arrow-circle-right",{fontCharacter:"\\ebfe"}),o.arrowCircleUp=new o("arrow-circle-up",{fontCharacter:"\\ebff"}),o.heartFilled=new o("heart-filled",{fontCharacter:"\\ec04"}),o.map=new o("map",{fontCharacter:"\\ec05"}),o.mapFilled=new o("map-filled",{fontCharacter:"\\ec06"}),o.circleSmall=new o("circle-small",{fontCharacter:"\\ec07"}),o.bellSlash=new o("bell-slash",{fontCharacter:"\\ec08"}),o.bellSlashDot=new o("bell-slash-dot",{fontCharacter:"\\ec09"}),o.commentUnresolved=new o("comment-unresolved",{fontCharacter:"\\ec0a"}),o.gitPullRequestGoToChanges=new o("git-pull-request-go-to-changes",{fontCharacter:"\\ec0b"}),o.gitPullRequestNewChanges=new o("git-pull-request-new-changes",{fontCharacter:"\\ec0c"}),o.dialogError=new o("dialog-error",o.error.definition),o.dialogWarning=new o("dialog-warning",o.warning.definition),o.dialogInfo=new o("dialog-info",o.info.definition),o.dialogClose=new o("dialog-close",o.close.definition),o.treeItemExpanded=new o("tree-item-expanded",o.chevronDown.definition),o.treeFilterOnTypeOn=new o("tree-filter-on-type-on",o.listFilter.definition),o.treeFilterOnTypeOff=new o("tree-filter-on-type-off",o.listSelection.definition),o.treeFilterClear=new o("tree-filter-clear",o.close.definition),o.treeItemLoading=new o("tree-item-loading",o.loading.definition),o.menuSelection=new o("menu-selection",o.check.definition),o.menuSubmenu=new o("menu-submenu",o.chevronRight.definition),o.menuBarMore=new o("menubar-more",o.more.definition),o.scrollbarButtonLeft=new o("scrollbar-button-left",o.triangleLeft.definition),o.scrollbarButtonRight=new o("scrollbar-button-right",o.triangleRight.definition),o.scrollbarButtonUp=new o("scrollbar-button-up",o.triangleUp.definition),o.scrollbarButtonDown=new o("scrollbar-button-down",o.triangleDown.definition),o.toolBarMore=new o("toolbar-more",o.more.definition),o.quickInputBack=new o("quick-input-back",o.arrowLeft.definition);var K;(function($){$.iconNameSegment="[A-Za-z0-9]+",$.iconNameExpression="[A-Za-z0-9-]+",$.iconModifierExpression="~[A-Za-z]+",$.iconNameCharacter="[A-Za-z0-9~-]";const L=new RegExp(`^(${$.iconNameExpression})(${$.iconModifierExpression})?$`);function U(T){if(T instanceof o)return["codicon","codicon-"+T.id];const p=L.exec(T.id);if(!p)return U(o.error);const[,d,g]=p,h=["codicon","codicon-"+d];return g&&h.push("codicon-modifier-"+g.substr(1)),h}$.asClassNameArray=U;function P(T){return U(T).join(" ")}$.asClassName=P;function B(T){return"."+U(T).join(".")}$.asCSSSelector=B})(K||(K={}))},26851:(rt,ye,y)=>{y.d(ye,{Q_:()=>P,VR:()=>L,jB:()=>U,kF:()=>p,mX:()=>T});var b=y(3765),o=y(27992),K=y(37264),$=y(82399);const L=(0,$.u1)("contextService");function U(g){const h=g;return typeof h?.id=="string"&&K.r.isUri(h.uri)}function P(g){if(g.configuration)return{id:g.id,configPath:g.configuration};if(g.folders.length===1)return{id:g.id,uri:g.folders[0].uri}}class B{constructor(h,l,u,w,C){this._id=h,this._transient=u,this._configuration=w,this._ignorePathCasing=C,this._foldersMap=TernarySearchTree.forUris(this._ignorePathCasing,()=>!0),this.folders=l}get folders(){return this._folders}set folders(h){this._folders=h,this.updateFoldersMap()}get id(){return this._id}get transient(){return this._transient}get configuration(){return this._configuration}set configuration(h){this._configuration=h}getFolder(h){return h&&this._foldersMap.findSubstr(h)||null}updateFoldersMap(){this._foldersMap=TernarySearchTree.forUris(this._ignorePathCasing,()=>!0);for(const h of this.folders)this._foldersMap.set(h.uri,h)}toJSON(){return{id:this.id,folders:this.folders,transient:this.transient,configuration:this.configuration}}}class T{constructor(h,l){this.raw=l,this.uri=h.uri,this.index=h.index,this.name=h.name}toJSON(){return{uri:this.uri,name:this.name,index:this.index}}}const p="code-workspace",d=[{name:(0,b.kg)("codeWorkspace","Code Workspace"),extensions:[p]}]},27064:(rt,ye,y)=>{y.d(ye,{S:()=>B,c:()=>P});var b=y(79359),o=y(29895),K=y(50572),$=y(89673),L=y(15365),U=y(50442);class P{static addCursorDown(p,d,g){const h=[];let l=0;for(let u=0,w=d.length;u<w;u++){const C=d[u];h[l++]=new o.MF(C.modelState,C.viewState),g?h[l++]=o.MF.fromModelState(K.I.translateDown(p.cursorConfig,p.model,C.modelState)):h[l++]=o.MF.fromViewState(K.I.translateDown(p.cursorConfig,p,C.viewState))}return h}static addCursorUp(p,d,g){const h=[];let l=0;for(let u=0,w=d.length;u<w;u++){const C=d[u];h[l++]=new o.MF(C.modelState,C.viewState),g?h[l++]=o.MF.fromModelState(K.I.translateUp(p.cursorConfig,p.model,C.modelState)):h[l++]=o.MF.fromViewState(K.I.translateUp(p.cursorConfig,p,C.viewState))}return h}static moveToBeginningOfLine(p,d,g){const h=[];for(let l=0,u=d.length;l<u;l++){const w=d[l];h[l]=this._moveToLineStart(p,w,g)}return h}static _moveToLineStart(p,d,g){const h=d.viewState.position.column,l=d.modelState.position.column,u=h===l,w=d.viewState.position.lineNumber,C=p.getLineFirstNonWhitespaceColumn(w);return!u&&!(h===C)?this._moveToLineStartByView(p,d,g):this._moveToLineStartByModel(p,d,g)}static _moveToLineStartByView(p,d,g){return o.MF.fromViewState(K.I.moveToBeginningOfLine(p.cursorConfig,p,d.viewState,g))}static _moveToLineStartByModel(p,d,g){return o.MF.fromModelState(K.I.moveToBeginningOfLine(p.cursorConfig,p.model,d.modelState,g))}static moveToEndOfLine(p,d,g,h){const l=[];for(let u=0,w=d.length;u<w;u++){const C=d[u];l[u]=this._moveToLineEnd(p,C,g,h)}return l}static _moveToLineEnd(p,d,g,h){const l=d.viewState.position,u=p.getLineMaxColumn(l.lineNumber),w=l.column===u,C=d.modelState.position,m=p.model.getLineMaxColumn(C.lineNumber),v=u-l.column===m-C.column;return w||v?this._moveToLineEndByModel(p,d,g,h):this._moveToLineEndByView(p,d,g,h)}static _moveToLineEndByView(p,d,g,h){return o.MF.fromViewState(K.I.moveToEndOfLine(p.cursorConfig,p,d.viewState,g,h))}static _moveToLineEndByModel(p,d,g,h){return o.MF.fromModelState(K.I.moveToEndOfLine(p.cursorConfig,p.model,d.modelState,g,h))}static expandLineSelection(p,d){const g=[];for(let h=0,l=d.length;h<l;h++){const u=d[h],w=u.modelState.selection.startLineNumber,C=p.model.getLineCount();let m=u.modelState.selection.endLineNumber,v;m===C?v=p.model.getLineMaxColumn(C):(m++,v=1),g[h]=o.MF.fromModelState(new o.mG(new U.Q(w,1,w,1),0,new L.y(m,v),0))}return g}static moveToBeginningOfBuffer(p,d,g){const h=[];for(let l=0,u=d.length;l<u;l++){const w=d[l];h[l]=o.MF.fromModelState(K.I.moveToBeginningOfBuffer(p.cursorConfig,p.model,w.modelState,g))}return h}static moveToEndOfBuffer(p,d,g){const h=[];for(let l=0,u=d.length;l<u;l++){const w=d[l];h[l]=o.MF.fromModelState(K.I.moveToEndOfBuffer(p.cursorConfig,p.model,w.modelState,g))}return h}static selectAll(p,d){const g=p.model.getLineCount(),h=p.model.getLineMaxColumn(g);return o.MF.fromModelState(new o.mG(new U.Q(1,1,1,1),0,new L.y(g,h),0))}static line(p,d,g,h,l){const u=p.model.validatePosition(h),w=l?p.coordinatesConverter.validateViewPosition(new L.y(l.lineNumber,l.column),u):p.coordinatesConverter.convertModelPositionToViewPosition(u);if(!g||!d.modelState.hasSelection()){const m=p.model.getLineCount();let v=u.lineNumber+1,k=1;return v>m&&(v=m,k=p.model.getLineMaxColumn(v)),o.MF.fromModelState(new o.mG(new U.Q(u.lineNumber,1,v,k),0,new L.y(v,k),0))}const C=d.modelState.selectionStart.getStartPosition().lineNumber;if(u.lineNumber<C)return o.MF.fromViewState(d.viewState.move(d.modelState.hasSelection(),w.lineNumber,1,0));if(u.lineNumber>C){const m=p.getLineCount();let v=w.lineNumber+1,k=1;return v>m&&(v=m,k=p.getLineMaxColumn(v)),o.MF.fromViewState(d.viewState.move(d.modelState.hasSelection(),v,k,0))}else{const m=d.modelState.selectionStart.getEndPosition();return o.MF.fromModelState(d.modelState.move(d.modelState.hasSelection(),m.lineNumber,m.column,0))}}static word(p,d,g,h){const l=p.model.validatePosition(h);return o.MF.fromModelState($.z.word(p.cursorConfig,p.model,d.modelState,g,l))}static cancelSelection(p,d){if(!d.modelState.hasSelection())return new o.MF(d.modelState,d.viewState);const g=d.viewState.position.lineNumber,h=d.viewState.position.column;return o.MF.fromViewState(new o.mG(new U.Q(g,h,g,h),0,new L.y(g,h),0))}static moveTo(p,d,g,h,l){const u=p.model.validatePosition(h),w=l?p.coordinatesConverter.validateViewPosition(new L.y(l.lineNumber,l.column),u):p.coordinatesConverter.convertModelPositionToViewPosition(u);return o.MF.fromViewState(d.viewState.move(g,w.lineNumber,w.column,0))}static simpleMove(p,d,g,h,l,u){switch(g){case 0:return u===4?this._moveHalfLineLeft(p,d,h):this._moveLeft(p,d,h,l);case 1:return u===4?this._moveHalfLineRight(p,d,h):this._moveRight(p,d,h,l);case 2:return u===2?this._moveUpByViewLines(p,d,h,l):this._moveUpByModelLines(p,d,h,l);case 3:return u===2?this._moveDownByViewLines(p,d,h,l):this._moveDownByModelLines(p,d,h,l);case 4:return u===2?d.map(w=>o.MF.fromViewState(K.I.moveToPrevBlankLine(p.cursorConfig,p,w.viewState,h))):d.map(w=>o.MF.fromModelState(K.I.moveToPrevBlankLine(p.cursorConfig,p.model,w.modelState,h)));case 5:return u===2?d.map(w=>o.MF.fromViewState(K.I.moveToNextBlankLine(p.cursorConfig,p,w.viewState,h))):d.map(w=>o.MF.fromModelState(K.I.moveToNextBlankLine(p.cursorConfig,p.model,w.modelState,h)));case 6:return this._moveToViewMinColumn(p,d,h);case 7:return this._moveToViewFirstNonWhitespaceColumn(p,d,h);case 8:return this._moveToViewCenterColumn(p,d,h);case 9:return this._moveToViewMaxColumn(p,d,h);case 10:return this._moveToViewLastNonWhitespaceColumn(p,d,h);default:return null}}static viewportMove(p,d,g,h,l){const u=p.getCompletelyVisibleViewRange(),w=p.coordinatesConverter.convertViewRangeToModelRange(u);switch(g){case 11:{const C=this._firstLineNumberInRange(p.model,w,l),m=p.model.getLineFirstNonWhitespaceColumn(C);return[this._moveToModelPosition(p,d[0],h,C,m)]}case 13:{const C=this._lastLineNumberInRange(p.model,w,l),m=p.model.getLineFirstNonWhitespaceColumn(C);return[this._moveToModelPosition(p,d[0],h,C,m)]}case 12:{const C=Math.round((w.startLineNumber+w.endLineNumber)/2),m=p.model.getLineFirstNonWhitespaceColumn(C);return[this._moveToModelPosition(p,d[0],h,C,m)]}case 14:{const C=[];for(let m=0,v=d.length;m<v;m++){const k=d[m];C[m]=this.findPositionInViewportIfOutside(p,k,u,h)}return C}default:return null}}static findPositionInViewportIfOutside(p,d,g,h){const l=d.viewState.position.lineNumber;if(g.startLineNumber<=l&&l<=g.endLineNumber-1)return new o.MF(d.modelState,d.viewState);{let u;l>g.endLineNumber-1?u=g.endLineNumber-1:l<g.startLineNumber?u=g.startLineNumber:u=l;const w=K.I.vertical(p.cursorConfig,p,l,d.viewState.position.column,d.viewState.leftoverVisibleColumns,u,!1);return o.MF.fromViewState(d.viewState.move(h,w.lineNumber,w.column,w.leftoverVisibleColumns))}}static _firstLineNumberInRange(p,d,g){let h=d.startLineNumber;return d.startColumn!==p.getLineMinColumn(h)&&h++,Math.min(d.endLineNumber,h+g-1)}static _lastLineNumberInRange(p,d,g){let h=d.startLineNumber;return d.startColumn!==p.getLineMinColumn(h)&&h++,Math.max(h,d.endLineNumber-g+1)}static _moveLeft(p,d,g,h){return d.map(l=>o.MF.fromViewState(K.I.moveLeft(p.cursorConfig,p,l.viewState,g,h)))}static _moveHalfLineLeft(p,d,g){const h=[];for(let l=0,u=d.length;l<u;l++){const w=d[l],C=w.viewState.position.lineNumber,m=Math.round(p.getLineContent(C).length/2);h[l]=o.MF.fromViewState(K.I.moveLeft(p.cursorConfig,p,w.viewState,g,m))}return h}static _moveRight(p,d,g,h){return d.map(l=>o.MF.fromViewState(K.I.moveRight(p.cursorConfig,p,l.viewState,g,h)))}static _moveHalfLineRight(p,d,g){const h=[];for(let l=0,u=d.length;l<u;l++){const w=d[l],C=w.viewState.position.lineNumber,m=Math.round(p.getLineContent(C).length/2);h[l]=o.MF.fromViewState(K.I.moveRight(p.cursorConfig,p,w.viewState,g,m))}return h}static _moveDownByViewLines(p,d,g,h){const l=[];for(let u=0,w=d.length;u<w;u++){const C=d[u];l[u]=o.MF.fromViewState(K.I.moveDown(p.cursorConfig,p,C.viewState,g,h))}return l}static _moveDownByModelLines(p,d,g,h){const l=[];for(let u=0,w=d.length;u<w;u++){const C=d[u];l[u]=o.MF.fromModelState(K.I.moveDown(p.cursorConfig,p.model,C.modelState,g,h))}return l}static _moveUpByViewLines(p,d,g,h){const l=[];for(let u=0,w=d.length;u<w;u++){const C=d[u];l[u]=o.MF.fromViewState(K.I.moveUp(p.cursorConfig,p,C.viewState,g,h))}return l}static _moveUpByModelLines(p,d,g,h){const l=[];for(let u=0,w=d.length;u<w;u++){const C=d[u];l[u]=o.MF.fromModelState(K.I.moveUp(p.cursorConfig,p.model,C.modelState,g,h))}return l}static _moveToViewPosition(p,d,g,h,l){return o.MF.fromViewState(d.viewState.move(g,h,l,0))}static _moveToModelPosition(p,d,g,h,l){return o.MF.fromModelState(d.modelState.move(g,h,l,0))}static _moveToViewMinColumn(p,d,g){const h=[];for(let l=0,u=d.length;l<u;l++){const w=d[l],C=w.viewState.position.lineNumber,m=p.getLineMinColumn(C);h[l]=this._moveToViewPosition(p,w,g,C,m)}return h}static _moveToViewFirstNonWhitespaceColumn(p,d,g){const h=[];for(let l=0,u=d.length;l<u;l++){const w=d[l],C=w.viewState.position.lineNumber,m=p.getLineFirstNonWhitespaceColumn(C);h[l]=this._moveToViewPosition(p,w,g,C,m)}return h}static _moveToViewCenterColumn(p,d,g){const h=[];for(let l=0,u=d.length;l<u;l++){const w=d[l],C=w.viewState.position.lineNumber,m=Math.round((p.getLineMaxColumn(C)+p.getLineMinColumn(C))/2);h[l]=this._moveToViewPosition(p,w,g,C,m)}return h}static _moveToViewMaxColumn(p,d,g){const h=[];for(let l=0,u=d.length;l<u;l++){const w=d[l],C=w.viewState.position.lineNumber,m=p.getLineMaxColumn(C);h[l]=this._moveToViewPosition(p,w,g,C,m)}return h}static _moveToViewLastNonWhitespaceColumn(p,d,g){const h=[];for(let l=0,u=d.length;l<u;l++){const w=d[l],C=w.viewState.position.lineNumber,m=p.getLineLastNonWhitespaceColumn(C);h[l]=this._moveToViewPosition(p,w,g,C,m)}return h}}var B;(function(T){const p=function(g){if(!b.Gv(g))return!1;const h=g;return!(!b.Kg(h.to)||!b.b0(h.select)&&!b.Lm(h.select)||!b.b0(h.by)&&!b.Kg(h.by)||!b.b0(h.value)&&!b.Et(h.value))};T.description={description:"Move cursor to a logical position in the view",args:[{name:"Cursor move argument object",description:`Property-value pairs that can be passed through this argument: * 'to': A mandatory logical position value providing where to move the cursor. \`\`\` 'left', 'right', 'up', 'down', 'prevBlankLine', 'nextBlankLine', 'wrappedLineStart', 'wrappedLineEnd', 'wrappedLineColumnCenter' 'wrappedLineFirstNonWhitespaceCharacter', 'wrappedLineLastNonWhitespaceCharacter' 'viewPortTop', 'viewPortCenter', 'viewPortBottom', 'viewPortIfOutside' \`\`\` * 'by': Unit to move. Default is computed based on 'to' value. \`\`\` 'line', 'wrappedLine', 'character', 'halfLine' \`\`\` * 'value': Number of units to move. Default is '1'. * 'select': If 'true' makes the selection. Default is 'false'. `,constraint:p,schema:{type:"object",required:["to"],properties:{to:{type:"string",enum:["left","right","up","down","prevBlankLine","nextBlankLine","wrappedLineStart","wrappedLineEnd","wrappedLineColumnCenter","wrappedLineFirstNonWhitespaceCharacter","wrappedLineLastNonWhitespaceCharacter","viewPortTop","viewPortCenter","viewPortBottom","viewPortIfOutside"]},by:{type:"string",enum:["line","wrappedLine","character","halfLine"]},value:{type:"number",default:1},select:{type:"boolean",default:!1}}}}]},T.RawDirection={Left:"left",Right:"right",Up:"up",Down:"down",PrevBlankLine:"prevBlankLine",NextBlankLine:"nextBlankLine",WrappedLineStart:"wrappedLineStart",WrappedLineFirstNonWhitespaceCharacter:"wrappedLineFirstNonWhitespaceCharacter",WrappedLineColumnCenter:"wrappedLineColumnCenter",WrappedLineEnd:"wrappedLineEnd",WrappedLineLastNonWhitespaceCharacter:"wrappedLineLastNonWhitespaceCharacter",ViewPortTop:"viewPortTop",ViewPortCenter:"viewPortCenter",ViewPortBottom:"viewPortBottom",ViewPortIfOutside:"viewPortIfOutside"},T.RawUnit={Line:"line",WrappedLine:"wrappedLine",Character:"character",HalfLine:"halfLine"};function d(g){if(!g.to)return null;let h;switch(g.to){case T.RawDirection.Left:h=0;break;case T.RawDirection.Right:h=1;break;case T.RawDirection.Up:h=2;break;case T.RawDirection.Down:h=3;break;case T.RawDirection.PrevBlankLine:h=4;break;case T.RawDirection.NextBlankLine:h=5;break;case T.RawDirection.WrappedLineStart:h=6;break;case T.RawDirection.WrappedLineFirstNonWhitespaceCharacter:h=7;break;case T.RawDirection.WrappedLineColumnCenter:h=8;break;case T.RawDirection.WrappedLineEnd:h=9;break;case T.RawDirection.WrappedLineLastNonWhitespaceCharacter:h=10;break;case T.RawDirection.ViewPortTop:h=11;break;case T.RawDirection.ViewPortBottom:h=13;break;case T.RawDirection.ViewPortCenter:h=12;break;case T.RawDirection.ViewPortIfOutside:h=14;break;default:return null}let l=0;switch(g.by){case T.RawUnit.Line:l=1;break;case T.RawUnit.WrappedLine:l=2;break;case T.RawUnit.Character:l=3;break;case T.RawUnit.HalfLine:l=4;break}return{direction:h,unit:l,select:!!g.select,value:g.value||1}}T.parse=d})(B||(B={}))},27142:(rt,ye,y)=>{y.d(ye,{Fd:()=>B,Gv:()=>x,rC:()=>D});var b=y(13338),o=y(2106),K=y(79359),$=y(3765),L=y(85753),U=y(51460),P=y(67167);const B={Configuration:"base.contributions.configuration"},T={properties:{},patternProperties:{}},p={properties:{},patternProperties:{}},d={properties:{},patternProperties:{}},g={properties:{},patternProperties:{}},h={properties:{},patternProperties:{}},l={properties:{},patternProperties:{}},u="vscode://schemas/settings/resourceLanguage",w=P.O.as(U.F.JSONContribution);class C{constructor(){this.overrideIdentifiers=new Set,this._onDidSchemaChange=new o.vl,this._onDidUpdateConfiguration=new o.vl,this.configurationDefaultsOverrides=new Map,this.defaultLanguageConfigurationOverridesNode={id:"defaultOverrides",title:$.kg("defaultLanguageConfigurationOverrides.title","Default Language Configuration Overrides"),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={},w.registerSchema(u,this.resourceLanguageSettingsSchema),this.registerOverridePropertyPatternKey()}registerConfiguration(j,Q=!0){this.registerConfigurations([j],Q)}registerConfigurations(j,Q=!0){const X=this.doRegisterConfigurations(j,Q);w.registerSchema(u,this.resourceLanguageSettingsSchema),this._onDidSchemaChange.fire(),this._onDidUpdateConfiguration.fire({properties:X})}registerDefaultConfigurations(j){var Q;const X=[],R=[];for(const{overrides:H,source:Z}of j)for(const N in H)if(X.push(N),D.test(N)){const G=this.configurationDefaultsOverrides.get(N),O=(Q=G?.valuesSources)!==null&&Q!==void 0?Q:new Map;if(Z)for(const E of Object.keys(H[N]))O.set(E,Z);const te=Object.assign(Object.assign({},G?.value||{}),H[N]);this.configurationDefaultsOverrides.set(N,{source:Z,value:te,valuesSources:O});const oe=(0,L.Mo)(N),ue={type:"object",default:te,description:$.kg("defaultLanguageConfiguration.description","Configure settings to be overridden for the {0} language.",oe),$ref:u,defaultDefaultValue:te,source:K.Kg(Z)?void 0:Z,defaultValueSource:Z};R.push(...x(N)),this.configurationProperties[N]=ue,this.defaultLanguageConfigurationOverridesNode.properties[N]=ue}else{this.configurationDefaultsOverrides.set(N,{value:H[N],source:Z});const G=this.configurationProperties[N];G&&(this.updatePropertyDefaultValue(N,G),this.updateSchema(N,G))}this.registerOverrideIdentifiers(R),this._onDidSchemaChange.fire(),this._onDidUpdateConfiguration.fire({properties:X,defaultsOverrides:!0})}registerOverrideIdentifiers(j){for(const Q of j)this.overrideIdentifiers.add(Q);this.updateOverridePropertyPatternKey()}doRegisterConfigurations(j,Q){const X=[];return j.forEach(R=>{X.push(...this.validateAndRegisterProperties(R,Q,R.extensionInfo,R.restrictedProperties)),this.configurationContributors.push(R),this.registerJSONConfiguration(R)}),X}validateAndRegisterProperties(j,Q=!0,X,R,H=3){var Z;H=K.z(j.scope)?H:j.scope;const N=[],G=j.properties;if(G)for(const te in G){const oe=G[te];if(Q&&Y(te,oe)){delete G[te];continue}if(oe.source=X,oe.defaultDefaultValue=G[te].default,this.updatePropertyDefaultValue(te,oe),D.test(te)?oe.scope=void 0:(oe.scope=K.z(oe.scope)?H:oe.scope,oe.restricted=K.z(oe.restricted)?!!R?.includes(te):oe.restricted),G[te].hasOwnProperty("included")&&!G[te].included){this.excludedConfigurationProperties[te]=G[te],delete G[te];continue}else this.configurationProperties[te]=G[te],!((Z=G[te].policy)===null||Z===void 0)&&Z.name&&this.policyConfigurations.set(G[te].policy.name,te);!G[te].deprecationMessage&&G[te].markdownDeprecationMessage&&(G[te].deprecationMessage=G[te].markdownDeprecationMessage),N.push(te)}const O=j.allOf;if(O)for(const te of O)N.push(...this.validateAndRegisterProperties(te,Q,X,R,H));return N}getConfigurationProperties(){return this.configurationProperties}getPolicyConfigurations(){return this.policyConfigurations}registerJSONConfiguration(j){const Q=X=>{const R=X.properties;if(R)for(const Z in R)this.updateSchema(Z,R[Z]);const H=X.allOf;H?.forEach(Q)};Q(j)}updateSchema(j,Q){switch(T.properties[j]=Q,Q.scope){case 1:p.properties[j]=Q;break;case 2:d.properties[j]=Q;break;case 6:g.properties[j]=Q;break;case 3:h.properties[j]=Q;break;case 4:l.properties[j]=Q;break;case 5:l.properties[j]=Q,this.resourceLanguageSettingsSchema.properties[j]=Q;break}}updateOverridePropertyPatternKey(){for(const j of this.overrideIdentifiers.values()){const Q=`[${j}]`,X={type:"object",description:$.kg("overrideSettings.defaultDescription","Configure editor settings to be overridden for a language."),errorMessage:$.kg("overrideSettings.errorMessage","This setting does not support per-language configuration."),$ref:u};this.updatePropertyDefaultValue(Q,X),T.properties[Q]=X,p.properties[Q]=X,d.properties[Q]=X,g.properties[Q]=X,h.properties[Q]=X,l.properties[Q]=X}this._onDidSchemaChange.fire()}registerOverridePropertyPatternKey(){const j={type:"object",description:$.kg("overrideSettings.defaultDescription","Configure editor settings to be overridden for a language."),errorMessage:$.kg("overrideSettings.errorMessage","This setting does not support per-language configuration."),$ref:u};T.patternProperties[k]=j,p.patternProperties[k]=j,d.patternProperties[k]=j,g.patternProperties[k]=j,h.patternProperties[k]=j,l.patternProperties[k]=j,this._onDidSchemaChange.fire()}updatePropertyDefaultValue(j,Q){const X=this.configurationDefaultsOverrides.get(j);let R=X?.value,H=X?.source;K.b0(R)&&(R=Q.defaultDefaultValue,H=void 0),K.b0(R)&&(R=A(Q.type)),Q.default=R,Q.defaultValueSource=H}}const m="\\[([^\\]]+)\\]",v=new RegExp(m,"g"),k=`^(${m})+$`,D=new RegExp(k);function x(ne){const j=[];if(D.test(ne)){let Q=v.exec(ne);for(;Q?.length;){const X=Q[1].trim();X&&j.push(X),Q=v.exec(ne)}}return(0,b.dM)(j)}function A(ne){switch(Array.isArray(ne)?ne[0]:ne){case"boolean":return!1;case"integer":case"number":return 0;case"string":return"";case"array":return[];case"object":return{};default:return null}}const W=new C;P.O.add(B.Configuration,W);function Y(ne,j){var Q,X,R,H;return ne.trim()?D.test(ne)?$.kg("config.property.languageDefault","Cannot register '{0}'. This matches property pattern '\\\\[.*\\\\]$' for describing language specific editor settings. Use 'configurationDefaults' contribution.",ne):W.getConfigurationProperties()[ne]!==void 0?$.kg("config.property.duplicate","Cannot register '{0}'. This property is already registered.",ne):!((Q=j.policy)===null||Q===void 0)&&Q.name&&W.getPolicyConfigurations().get((X=j.policy)===null||X===void 0?void 0:X.name)!==void 0?$.kg("config.policy.duplicate","Cannot register '{0}'. The associated policy {1} is already registered with {2}.",ne,(R=j.policy)===null||R===void 0?void 0:R.name,W.getPolicyConfigurations().get((H=j.policy)===null||H===void 0?void 0:H.name)):null:$.kg("config.property.empty","Cannot register an empty property")}},27454:(rt,ye,y)=>{y.d(ye,{V:()=>o,y:()=>K});var b=y(37512);class o{constructor(L){const U=(0,b.W)(L);this._defaultValue=U,this._asciiMap=o._createAsciiMap(U),this._map=new Map}static _createAsciiMap(L){const U=new Uint8Array(256);for(let P=0;P<256;P++)U[P]=L;return U}set(L,U){const P=(0,b.W)(U);L>=0&&L<256?this._asciiMap[L]=P:this._map.set(L,P)}get(L){return L>=0&&L<256?this._asciiMap[L]:this._map.get(L)||this._defaultValue}}class K{constructor(){this._actual=new o(0)}add(L){this._actual.set(L,1)}has(L){return this._actual.get(L)===1}}},27619:(rt,ye,y)=>{y.d(ye,{DR:()=>U,cj:()=>$,oc:()=>L});var b=y(66459),o=y(3765),K=y(82399),$;(function(P){P[P.Hint=1]="Hint",P[P.Info=2]="Info",P[P.Warning=4]="Warning",P[P.Error=8]="Error"})($||($={})),function(P){function B(h,l){return l-h}P.compare=B;const T=Object.create(null);T[P.Error]=(0,o.kg)("sev.error","Error"),T[P.Warning]=(0,o.kg)("sev.warning","Warning"),T[P.Info]=(0,o.kg)("sev.info","Info");function p(h){return T[h]||""}P.toString=p;function d(h){switch(h){case b.A.Error:return P.Error;case b.A.Warning:return P.Warning;case b.A.Info:return P.Info;case b.A.Ignore:return P.Hint}}P.fromSeverity=d;function g(h){switch(h){case P.Error:return b.A.Error;case P.Warning:return b.A.Warning;case P.Info:return b.A.Info;case P.Hint:return b.A.Ignore}}P.toSeverity=g}($||($={}));var L;(function(P){function T(d){return p(d,!0)}P.makeKey=T;function p(d,g){const h=[""];return d.source?h.push(d.source.replace("\xA6","\\\xA6")):h.push(""),d.code?typeof d.code=="string"?h.push(d.code.replace("\xA6","\\\xA6")):h.push(d.code.value.replace("\xA6","\\\xA6")):h.push(""),d.severity!==void 0&&d.severity!==null?h.push($.toString(d.severity)):h.push(""),d.message&&g?h.push(d.message.replace("\xA6","\\\xA6")):h.push(""),d.startLineNumber!==void 0&&d.startLineNumber!==null?h.push(d.startLineNumber.toString()):h.push(""),d.startColumn!==void 0&&d.startColumn!==null?h.push(d.startColumn.toString()):h.push(""),d.endLineNumber!==void 0&&d.endLineNumber!==null?h.push(d.endLineNumber.toString()):h.push(""),d.endColumn!==void 0&&d.endColumn!==null?h.push(d.endColumn.toString()):h.push(""),h.push(""),h.join("\xA6")}P.makeKeyOptionalMessage=p})(L||(L={}));const U=(0,K.u1)("markerService")},27992:(rt,ye,y)=>{y.d(ye,{cB:()=>T,fT:()=>d,qK:()=>h});var b=y(16844),o,K;class ${constructor(){this._value="",this._pos=0}reset(u){return this._value=u,this._pos=0,this}next(){return this._pos+=1,this}hasNext(){return this._pos<this._value.length-1}cmp(u){const w=u.charCodeAt(0),C=this._value.charCodeAt(this._pos);return w-C}value(){return this._value[this._pos]}}class L{constructor(u=!0){this._caseSensitive=u}reset(u){return this._value=u,this._from=0,this._to=0,this.next()}hasNext(){return this._to<this._value.length}next(){this._from=this._to;let u=!0;for(;this._to<this._value.length;this._to++)if(this._value.charCodeAt(this._to)===46)if(u)this._from++;else break;else u=!1;return this}cmp(u){return this._caseSensitive?(0,b.lF)(u,this._value,0,u.length,this._from,this._to):(0,b.zd)(u,this._value,0,u.length,this._from,this._to)}value(){return this._value.substring(this._from,this._to)}}class U{constructor(u=!0,w=!0){this._splitOnBackslash=u,this._caseSensitive=w}reset(u){this._from=0,this._to=0,this._value=u,this._valueLen=u.length;for(let w=u.length-1;w>=0;w--,this._valueLen--){const C=this._value.charCodeAt(w);if(!(C===47||this._splitOnBackslash&&C===92))break}return this.next()}hasNext(){return this._to<this._valueLen}next(){this._from=this._to;let u=!0;for(;this._to<this._valueLen;this._to++){const w=this._value.charCodeAt(this._to);if(w===47||this._splitOnBackslash&&w===92)if(u)this._from++;else break;else u=!1}return this}cmp(u){return this._caseSensitive?(0,b.lF)(u,this._value,0,u.length,this._from,this._to):(0,b.zd)(u,this._value,0,u.length,this._from,this._to)}value(){return this._value.substring(this._from,this._to)}}class P{constructor(u,w){this._ignorePathCasing=u,this._ignoreQueryAndFragment=w,this._states=[],this._stateIdx=0}reset(u){return this._value=u,this._states=[],this._value.scheme&&this._states.push(1),this._value.authority&&this._states.push(2),this._value.path&&(this._pathIterator=new U(!1,!this._ignorePathCasing(u)),this._pathIterator.reset(u.path),this._pathIterator.value()&&this._states.push(3)),this._ignoreQueryAndFragment(u)||(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(u){if(this._states[this._stateIdx]===1)return(0,b.W1)(u,this._value.scheme);if(this._states[this._stateIdx]===2)return(0,b.W1)(u,this._value.authority);if(this._states[this._stateIdx]===3)return this._pathIterator.cmp(u);if(this._states[this._stateIdx]===4)return(0,b.UD)(u,this._value.query);if(this._states[this._stateIdx]===5)return(0,b.UD)(u,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}}class B{constructor(){this.height=1}rotateLeft(){const u=this.right;return this.right=u.left,u.left=this,this.updateHeight(),u.updateHeight(),u}rotateRight(){const u=this.left;return this.left=u.right,u.right=this,this.updateHeight(),u.updateHeight(),u}updateHeight(){this.height=1+Math.max(this.heightLeft,this.heightRight)}balanceFactor(){return this.heightRight-this.heightLeft}get heightLeft(){var u,w;return(w=(u=this.left)===null||u===void 0?void 0:u.height)!==null&&w!==void 0?w:0}get heightRight(){var u,w;return(w=(u=this.right)===null||u===void 0?void 0:u.height)!==null&&w!==void 0?w:0}}class T{constructor(u){this._iter=u}static forUris(u=()=>!1,w=()=>!1){return new T(new P(u,w))}static forStrings(){return new T(new $)}static forConfigKeys(){return new T(new L)}clear(){this._root=void 0}set(u,w){const C=this._iter.reset(u);let m;this._root||(this._root=new B,this._root.segment=C.value());const v=[];for(m=this._root;;){const D=C.cmp(m.segment);if(D>0)m.left||(m.left=new B,m.left.segment=C.value()),v.push([-1,m]),m=m.left;else if(D<0)m.right||(m.right=new B,m.right.segment=C.value()),v.push([1,m]),m=m.right;else if(C.hasNext())C.next(),m.mid||(m.mid=new B,m.mid.segment=C.value()),v.push([0,m]),m=m.mid;else break}const k=m.value;m.value=w,m.key=u;for(let D=v.length-1;D>=0;D--){const x=v[D][1];x.updateHeight();const A=x.balanceFactor();if(A<-1||A>1){const W=v[D][0],Y=v[D+1][0];if(W===1&&Y===1)v[D][1]=x.rotateLeft();else if(W===-1&&Y===-1)v[D][1]=x.rotateRight();else if(W===1&&Y===-1)x.right=v[D+1][1]=v[D+1][1].rotateRight(),v[D][1]=x.rotateLeft();else if(W===-1&&Y===1)x.left=v[D+1][1]=v[D+1][1].rotateLeft(),v[D][1]=x.rotateRight();else throw new Error;if(D>0)switch(v[D-1][0]){case-1:v[D-1][1].left=v[D][1];break;case 1:v[D-1][1].right=v[D][1];break;case 0:v[D-1][1].mid=v[D][1];break}else this._root=v[0][1]}}return k}get(u){var w;return(w=this._getNode(u))===null||w===void 0?void 0:w.value}_getNode(u){const w=this._iter.reset(u);let C=this._root;for(;C;){const m=w.cmp(C.segment);if(m>0)C=C.left;else if(m<0)C=C.right;else if(w.hasNext())w.next(),C=C.mid;else break}return C}has(u){const w=this._getNode(u);return!(w?.value===void 0&&w?.mid===void 0)}delete(u){return this._delete(u,!1)}deleteSuperstr(u){return this._delete(u,!0)}_delete(u,w){var C;const m=this._iter.reset(u),v=[];let k=this._root;for(;k;){const D=m.cmp(k.segment);if(D>0)v.push([-1,k]),k=k.left;else if(D<0)v.push([1,k]),k=k.right;else if(m.hasNext())m.next(),v.push([0,k]),k=k.mid;else break}if(k){if(w?(k.left=void 0,k.mid=void 0,k.right=void 0,k.height=1):(k.key=void 0,k.value=void 0),!k.mid&&!k.value)if(k.left&&k.right){const D=this._min(k.right),{key:x,value:A,segment:W}=D;this._delete(D.key,!1),k.key=x,k.value=A,k.segment=W}else{const D=(C=k.left)!==null&&C!==void 0?C:k.right;if(v.length>0){const[x,A]=v[v.length-1];switch(x){case-1:A.left=D;break;case 0:A.mid=D;break;case 1:A.right=D;break}}else this._root=D}for(let D=v.length-1;D>=0;D--){const x=v[D][1];x.updateHeight();const A=x.balanceFactor();if(A>1?(x.right.balanceFactor()>=0||(x.right=x.right.rotateRight()),v[D][1]=x.rotateLeft()):A<-1&&(x.left.balanceFactor()<=0||(x.left=x.left.rotateLeft()),v[D][1]=x.rotateRight()),D>0)switch(v[D-1][0]){case-1:v[D-1][1].left=v[D][1];break;case 1:v[D-1][1].right=v[D][1];break;case 0:v[D-1][1].mid=v[D][1];break}else this._root=v[0][1]}}}_min(u){for(;u.left;)u=u.left;return u}findSubstr(u){const w=this._iter.reset(u);let C=this._root,m;for(;C;){const v=w.cmp(C.segment);if(v>0)C=C.left;else if(v<0)C=C.right;else if(w.hasNext())w.next(),m=C.value||m,C=C.mid;else break}return C&&C.value||m}findSuperstr(u){const w=this._iter.reset(u);let C=this._root;for(;C;){const m=w.cmp(C.segment);if(m>0)C=C.left;else if(m<0)C=C.right;else if(w.hasNext())w.next(),C=C.mid;else return C.mid?this._entries(C.mid):void 0}}forEach(u){for(const[w,C]of this)u(C,w)}*[Symbol.iterator](){yield*this._entries(this._root)}_entries(u){const w=[];return this._dfsEntries(u,w),w[Symbol.iterator]()}_dfsEntries(u,w){u&&(u.left&&this._dfsEntries(u.left,w),u.value&&w.push([u.key,u.value]),u.mid&&this._dfsEntries(u.mid,w),u.right&&this._dfsEntries(u.right,w))}}class p{constructor(u,w){this.uri=u,this.value=w}}class d{constructor(u,w){this[o]="ResourceMap",u instanceof d?(this.map=new Map(u.map),this.toKey=w??d.defaultToKey):(this.map=new Map,this.toKey=u??d.defaultToKey)}set(u,w){return this.map.set(this.toKey(u),new p(u,w)),this}get(u){var w;return(w=this.map.get(this.toKey(u)))===null||w===void 0?void 0:w.value}has(u){return this.map.has(this.toKey(u))}get size(){return this.map.size}clear(){this.map.clear()}delete(u){return this.map.delete(this.toKey(u))}forEach(u,w){typeof w<"u"&&(u=u.bind(w));for(const[C,m]of this.map)u(m.value,m.uri,this)}*values(){for(const u of this.map.values())yield u.value}*keys(){for(const u of this.map.values())yield u.uri}*entries(){for(const u of this.map.values())yield[u.uri,u.value]}*[(o=Symbol.toStringTag,Symbol.iterator)](){for(const[,u]of this.map)yield[u.uri,u.value]}}d.defaultToKey=l=>l.toString();class g{constructor(){this[K]="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(){var u;return(u=this._head)===null||u===void 0?void 0:u.value}get last(){var u;return(u=this._tail)===null||u===void 0?void 0:u.value}has(u){return this._map.has(u)}get(u,w=0){const C=this._map.get(u);if(C)return w!==0&&this.touch(C,w),C.value}set(u,w,C=0){let m=this._map.get(u);if(m)m.value=w,C!==0&&this.touch(m,C);else{switch(m={key:u,value:w,next:void 0,previous:void 0},C){case 0:this.addItemLast(m);break;case 1:this.addItemFirst(m);break;case 2:this.addItemLast(m);break;default:this.addItemLast(m);break}this._map.set(u,m),this._size++}return this}delete(u){return!!this.remove(u)}remove(u){const w=this._map.get(u);if(w)return this._map.delete(u),this.removeItem(w),this._size--,w.value}shift(){if(!this._head&&!this._tail)return;if(!this._head||!this._tail)throw new Error("Invalid list");const u=this._head;return this._map.delete(u.key),this.removeItem(u),this._size--,u.value}forEach(u,w){const C=this._state;let m=this._head;for(;m;){if(w?u.bind(w)(m.value,m.key,this):u(m.value,m.key,this),this._state!==C)throw new Error("LinkedMap got modified during iteration.");m=m.next}}keys(){const u=this,w=this._state;let C=this._head;const m={[Symbol.iterator](){return m},next(){if(u._state!==w)throw new Error("LinkedMap got modified during iteration.");if(C){const v={value:C.key,done:!1};return C=C.next,v}else return{value:void 0,done:!0}}};return m}values(){const u=this,w=this._state;let C=this._head;const m={[Symbol.iterator](){return m},next(){if(u._state!==w)throw new Error("LinkedMap got modified during iteration.");if(C){const v={value:C.value,done:!1};return C=C.next,v}else return{value:void 0,done:!0}}};return m}entries(){const u=this,w=this._state;let C=this._head;const m={[Symbol.iterator](){return m},next(){if(u._state!==w)throw new Error("LinkedMap got modified during iteration.");if(C){const v={value:[C.key,C.value],done:!1};return C=C.next,v}else return{value:void 0,done:!0}}};return m}[(K=Symbol.toStringTag,Symbol.iterator)](){return this.entries()}trimOld(u){if(u>=this.size)return;if(u===0){this.clear();return}let w=this._head,C=this.size;for(;w&&C>u;)this._map.delete(w.key),w=w.next,C--;this._head=w,this._size=C,w&&(w.previous=void 0),this._state++}addItemFirst(u){if(!this._head&&!this._tail)this._tail=u;else if(this._head)u.next=this._head,this._head.previous=u;else throw new Error("Invalid list");this._head=u,this._state++}addItemLast(u){if(!this._head&&!this._tail)this._head=u;else if(this._tail)u.previous=this._tail,this._tail.next=u;else throw new Error("Invalid list");this._tail=u,this._state++}removeItem(u){if(u===this._head&&u===this._tail)this._head=void 0,this._tail=void 0;else if(u===this._head){if(!u.next)throw new Error("Invalid list");u.next.previous=void 0,this._head=u.next}else if(u===this._tail){if(!u.previous)throw new Error("Invalid list");u.previous.next=void 0,this._tail=u.previous}else{const w=u.next,C=u.previous;if(!w||!C)throw new Error("Invalid list");w.previous=C,C.next=w}u.next=void 0,u.previous=void 0,this._state++}touch(u,w){if(!this._head||!this._tail)throw new Error("Invalid list");if(!(w!==1&&w!==2)){if(w===1){if(u===this._head)return;const C=u.next,m=u.previous;u===this._tail?(m.next=void 0,this._tail=m):(C.previous=m,m.next=C),u.previous=void 0,u.next=this._head,this._head.previous=u,this._head=u,this._state++}else if(w===2){if(u===this._tail)return;const C=u.next,m=u.previous;u===this._head?(C.previous=void 0,this._head=C):(C.previous=m,m.next=C),u.next=void 0,u.previous=this._tail,this._tail.next=u,this._tail=u,this._state++}}}toJSON(){const u=[];return this.forEach((w,C)=>{u.push([C,w])}),u}fromJSON(u){this.clear();for(const[w,C]of u)this.set(w,C)}}class h extends g{constructor(u,w=1){super(),this._limit=u,this._ratio=Math.min(Math.max(0,w),1)}get limit(){return this._limit}set limit(u){this._limit=u,this.checkTrim()}get(u,w=2){return super.get(u,w)}peek(u){return super.get(u,0)}set(u,w){return super.set(u,w,2),this.checkTrim(),this}checkTrim(){this.size>this._limit&&this.trimOld(Math.round(this._limit*this._ratio))}}},28060:(rt,ye,y)=>{y.d(ye,{YJ:()=>B,_8:()=>U});var b=y(63339),o=y(66476),K=y(84587);const $=b.zx?1.5:1.35,L=8;class U{constructor(p){this._bareFontInfoBrand=void 0,this.pixelRatio=p.pixelRatio,this.fontFamily=String(p.fontFamily),this.fontWeight=String(p.fontWeight),this.fontSize=p.fontSize,this.fontFeatureSettings=p.fontFeatureSettings,this.lineHeight=p.lineHeight|0,this.letterSpacing=p.letterSpacing}static createFromValidatedSettings(p,d,g){const h=p.get(45),l=p.get(49),u=p.get(48),w=p.get(47),C=p.get(61),m=p.get(58);return U._create(h,l,u,w,C,m,d,g)}static _create(p,d,g,h,l,u,w,C){l===0?l=$*g:l<L&&(l=l*g),l=Math.round(l),l<L&&(l=L);const m=1+(C?0:K.D.getZoomLevel()*.1);return g*=m,l*=m,new U({pixelRatio:w,fontFamily:p,fontWeight:d,fontSize:g,fontFeatureSettings:h,lineHeight:l,letterSpacing:u})}getId(){return`${this.pixelRatio}-${this.fontFamily}-${this.fontWeight}-${this.fontSize}-${this.fontFeatureSettings}-${this.lineHeight}-${this.letterSpacing}`}getMassagedFontFamily(){const p=o.jU.fontFamily,d=U._wrapInQuotes(this.fontFamily);return p&&this.fontFamily!==p?`${d}, ${p}`:d}static _wrapInQuotes(p){return/[,"']/.test(p)?p:/[+ ]/.test(p)?`"${p}"`:p}}const P=1;class B extends U{constructor(p,d){super(p),this._editorStylingBrand=void 0,this.version=P,this.isTrusted=d,this.isMonospace=p.isMonospace,this.typicalHalfwidthCharacterWidth=p.typicalHalfwidthCharacterWidth,this.typicalFullwidthCharacterWidth=p.typicalFullwidthCharacterWidth,this.canUseHalfwidthRightwardsArrow=p.canUseHalfwidthRightwardsArrow,this.spaceWidth=p.spaceWidth,this.middotWidth=p.middotWidth,this.wsmiddotWidth=p.wsmiddotWidth,this.maxDigitWidth=p.maxDigitWidth}equals(p){return this.fontFamily===p.fontFamily&&this.fontWeight===p.fontWeight&&this.fontSize===p.fontSize&&this.fontFeatureSettings===p.fontFeatureSettings&&this.lineHeight===p.lineHeight&&this.letterSpacing===p.letterSpacing&&this.typicalHalfwidthCharacterWidth===p.typicalHalfwidthCharacterWidth&&this.typicalFullwidthCharacterWidth===p.typicalFullwidthCharacterWidth&&this.canUseHalfwidthRightwardsArrow===p.canUseHalfwidthRightwardsArrow&&this.spaceWidth===p.spaceWidth&&this.middotWidth===p.middotWidth&&this.wsmiddotWidth===p.wsmiddotWidth&&this.maxDigitWidth===p.maxDigitWidth}}},29004:(rt,ye,y)=>{y.d(ye,{m:()=>C,c:()=>w});var b=y(14333),o=y(34061),K=y(88213),$=y(77439),L=y(59407),U=y(63781),P=y(45222),B=y(94901),T=y(2106);class p{constructor(v,k=0,D=v.length,x=k-1){this.items=v,this.start=k,this.end=D,this.index=x}current(){return this.index===this.start-1||this.index===this.end?null:this.items[this.index]}next(){return this.index=Math.min(this.index+1,this.end),this.current()}previous(){return this.index=Math.max(this.index-1,this.start-1),this.current()}first(){return this.index=this.start,this.current()}last(){return this.index=this.end-1,this.current()}}class d{constructor(v=[],k=10){this._initialize(v),this._limit=k,this._onChange()}getHistory(){return this._elements}add(v){this._history.delete(v),this._history.add(v),this._onChange()}next(){return this._currentPosition()!==this._elements.length-1?this._navigator.next():null}previous(){return this._currentPosition()!==0?this._navigator.previous():null}current(){return this._navigator.current()}first(){return this._navigator.first()}last(){return this._navigator.last()}has(v){return this._history.has(v)}_onChange(){this._reduceToLimit();const v=this._elements;this._navigator=new p(v,0,v.length,v.length)}_reduceToLimit(){const v=this._elements;v.length>this._limit&&this._initialize(v.slice(v.length-this._limit))}_currentPosition(){const v=this._navigator.current();return v?this._elements.indexOf(v):-1}_initialize(v){this._history=new Set;for(const k of v)this._history.add(k)}get _elements(){const v=[];return this._history.forEach(k=>v.push(k)),v}}var g=y(71386),h=y(3765);const l=b.$,u={inputBackground:B.Q1.fromHex("#3C3C3C"),inputForeground:B.Q1.fromHex("#CCCCCC"),inputValidationInfoBorder:B.Q1.fromHex("#55AAFF"),inputValidationInfoBackground:B.Q1.fromHex("#063B49"),inputValidationWarningBorder:B.Q1.fromHex("#B89500"),inputValidationWarningBackground:B.Q1.fromHex("#352A05"),inputValidationErrorBorder:B.Q1.fromHex("#BE1100"),inputValidationErrorBackground:B.Q1.fromHex("#5A1D1D")};class w extends P.x{constructor(v,k,D){var x;super(),this.state="idle",this.maxHeight=Number.POSITIVE_INFINITY,this._onDidChange=this._register(new T.vl),this.onDidChange=this._onDidChange.event,this._onDidHeightChange=this._register(new T.vl),this.onDidHeightChange=this._onDidHeightChange.event,this.contextViewProvider=k,this.options=D||Object.create(null),(0,g.co)(this.options,u,!1),this.message=null,this.placeholder=this.options.placeholder||"",this.tooltip=(x=this.options.tooltip)!==null&&x!==void 0?x:this.placeholder||"",this.ariaLabel=this.options.ariaLabel||"",this.inputBackground=this.options.inputBackground,this.inputForeground=this.options.inputForeground,this.inputBorder=this.options.inputBorder,this.inputValidationInfoBorder=this.options.inputValidationInfoBorder,this.inputValidationInfoBackground=this.options.inputValidationInfoBackground,this.inputValidationInfoForeground=this.options.inputValidationInfoForeground,this.inputValidationWarningBorder=this.options.inputValidationWarningBorder,this.inputValidationWarningBackground=this.options.inputValidationWarningBackground,this.inputValidationWarningForeground=this.options.inputValidationWarningForeground,this.inputValidationErrorBorder=this.options.inputValidationErrorBorder,this.inputValidationErrorBackground=this.options.inputValidationErrorBackground,this.inputValidationErrorForeground=this.options.inputValidationErrorForeground,this.options.validationOptions&&(this.validation=this.options.validationOptions.validation),this.element=b.BC(v,l(".monaco-inputbox.idle"));const A=this.options.flexibleHeight?"textarea":"input",W=b.BC(this.element,l(".ibwrapper"));if(this.input=b.BC(W,l(A+".input.empty")),this.input.setAttribute("autocorrect","off"),this.input.setAttribute("autocapitalize","off"),this.input.setAttribute("spellcheck","false"),this.onfocus(this.input,()=>this.element.classList.add("synthetic-focus")),this.onblur(this.input,()=>this.element.classList.remove("synthetic-focus")),this.options.flexibleHeight){this.maxHeight=typeof this.options.flexibleMaxHeight=="number"?this.options.flexibleMaxHeight:Number.POSITIVE_INFINITY,this.mirror=b.BC(W,l("div.mirror")),this.mirror.innerText="\xA0",this.scrollableElement=new U.Se(this.element,{vertical:1}),this.options.flexibleWidth&&(this.input.setAttribute("wrap","off"),this.mirror.style.whiteSpace="pre",this.mirror.style.wordWrap="initial"),b.BC(v,this.scrollableElement.getDomNode()),this._register(this.scrollableElement),this._register(this.scrollableElement.onScroll(j=>this.input.scrollTop=j.scrollTop));const Y=this._register(new o.f(document,"selectionchange")),ne=T.Jh.filter(Y.event,()=>{const j=document.getSelection();return j?.anchorNode===W});this._register(ne(this.updateScrollDimensions,this)),this._register(this.onDidHeightChange(this.updateScrollDimensions,this))}else this.input.type=this.options.type||"text",this.input.setAttribute("wrap","off");this.ariaLabel&&this.input.setAttribute("aria-label",this.ariaLabel),this.placeholder&&!this.options.showPlaceholderOnFocus&&this.setPlaceHolder(this.placeholder),this.tooltip&&this.setTooltip(this.tooltip),this.oninput(this.input,()=>this.onValueChange()),this.onblur(this.input,()=>this.onBlur()),this.onfocus(this.input,()=>this.onFocus()),this.ignoreGesture(this.input),setTimeout(()=>this.updateMirror(),0),this.options.actions&&(this.actionbar=this._register(new $.E(this.element)),this.actionbar.push(this.options.actions,{icon:!0,label:!1})),this.applyStyles()}onBlur(){this._hideMessage(),this.options.showPlaceholderOnFocus&&this.input.setAttribute("placeholder","")}onFocus(){this._showMessage(),this.options.showPlaceholderOnFocus&&this.input.setAttribute("placeholder",this.placeholder||"")}setPlaceHolder(v){this.placeholder=v,this.input.setAttribute("placeholder",v)}setTooltip(v){this.tooltip=v,this.input.title=v}setAriaLabel(v){this.ariaLabel=v,v?this.input.setAttribute("aria-label",this.ariaLabel):this.input.removeAttribute("aria-label")}getAriaLabel(){return this.ariaLabel}get inputElement(){return this.input}get value(){return this.input.value}set value(v){this.input.value!==v&&(this.input.value=v,this.onValueChange())}get height(){return typeof this.cachedHeight=="number"?this.cachedHeight:b.OK(this.element)}focus(){this.input.focus()}blur(){this.input.blur()}hasFocus(){return document.activeElement===this.input}select(v=null){this.input.select(),v&&(this.input.setSelectionRange(v.start,v.end),v.end===this.input.value.length&&(this.input.scrollLeft=this.input.scrollWidth))}isSelectionAtEnd(){return this.input.selectionEnd===this.input.value.length&&this.input.selectionStart===this.input.selectionEnd}enable(){this.input.removeAttribute("disabled")}disable(){this.blur(),this.input.disabled=!0,this._hideMessage()}get width(){return b.Tr(this.input)}set width(v){if(this.options.flexibleHeight&&this.options.flexibleWidth){let k=0;if(this.mirror){const D=parseFloat(this.mirror.style.paddingLeft||"")||0,x=parseFloat(this.mirror.style.paddingRight||"")||0;k=D+x}this.input.style.width=v-k+"px"}else this.input.style.width=v+"px";this.mirror&&(this.mirror.style.width=v+"px")}set paddingRight(v){this.input.style.width=`calc(100% - ${v}px)`,this.mirror&&(this.mirror.style.paddingRight=v+"px")}updateScrollDimensions(){if(typeof this.cachedContentHeight!="number"||typeof this.cachedHeight!="number"||!this.scrollableElement)return;const v=this.cachedContentHeight,k=this.cachedHeight,D=this.input.scrollTop;this.scrollableElement.setScrollDimensions({scrollHeight:v,height:k}),this.scrollableElement.setScrollPosition({scrollTop:D})}showMessage(v,k){this.message=v,this.element.classList.remove("idle"),this.element.classList.remove("info"),this.element.classList.remove("warning"),this.element.classList.remove("error"),this.element.classList.add(this.classForType(v.type));const D=this.stylesForType(this.message.type);this.element.style.border=D.border?`1px solid ${D.border}`:"",(this.hasFocus()||k)&&this._showMessage()}hideMessage(){this.message=null,this.element.classList.remove("info"),this.element.classList.remove("warning"),this.element.classList.remove("error"),this.element.classList.add("idle"),this._hideMessage(),this.applyStyles()}validate(){let v=null;return this.validation&&(v=this.validation(this.value),v?(this.inputElement.setAttribute("aria-invalid","true"),this.showMessage(v)):this.inputElement.hasAttribute("aria-invalid")&&(this.inputElement.removeAttribute("aria-invalid"),this.hideMessage())),v?.type}stylesForType(v){switch(v){case 1:return{border:this.inputValidationInfoBorder,background:this.inputValidationInfoBackground,foreground:this.inputValidationInfoForeground};case 2:return{border:this.inputValidationWarningBorder,background:this.inputValidationWarningBackground,foreground:this.inputValidationWarningForeground};default:return{border:this.inputValidationErrorBorder,background:this.inputValidationErrorBackground,foreground:this.inputValidationErrorForeground}}}classForType(v){switch(v){case 1:return"info";case 2:return"warning";default:return"error"}}_showMessage(){if(!this.contextViewProvider||!this.message)return;let v;const k=()=>v.style.width=b.Tr(this.element)+"px";this.contextViewProvider.showContextView({getAnchor:()=>this.element,anchorAlignment:1,render:x=>{if(!this.message)return null;v=b.BC(x,l(".monaco-inputbox-container")),k();const A={inline:!0,className:"monaco-inputbox-message"},W=this.message.formatContent?(0,K.yk)(this.message.content,A):(0,K.S5)(this.message.content,A);W.classList.add(this.classForType(this.message.type));const Y=this.stylesForType(this.message.type);return W.style.backgroundColor=Y.background?Y.background.toString():"",W.style.color=Y.foreground?Y.foreground.toString():"",W.style.border=Y.border?`1px solid ${Y.border}`:"",b.BC(v,W),null},onHide:()=>{this.state="closed"},layout:k});let D;this.message.type===3?D=h.kg("alertErrorMessage","Error: {0}",this.message.content):this.message.type===2?D=h.kg("alertWarningMessage","Warning: {0}",this.message.content):D=h.kg("alertInfoMessage","Info: {0}",this.message.content),L.xE(D),this.state="open"}_hideMessage(){this.contextViewProvider&&(this.state==="open"&&this.contextViewProvider.hideContextView(),this.state="idle")}onValueChange(){this._onDidChange.fire(this.value),this.validate(),this.updateMirror(),this.input.classList.toggle("empty",!this.value),this.state==="open"&&this.contextViewProvider&&this.contextViewProvider.layout()}updateMirror(){if(!this.mirror)return;const v=this.value,D=v.charCodeAt(v.length-1)===10?" ":"";(v+D).replace(/\u000c/g,"")?this.mirror.textContent=v+D:this.mirror.innerText="\xA0",this.layout()}style(v){this.inputBackground=v.inputBackground,this.inputForeground=v.inputForeground,this.inputBorder=v.inputBorder,this.inputValidationInfoBackground=v.inputValidationInfoBackground,this.inputValidationInfoForeground=v.inputValidationInfoForeground,this.inputValidationInfoBorder=v.inputValidationInfoBorder,this.inputValidationWarningBackground=v.inputValidationWarningBackground,this.inputValidationWarningForeground=v.inputValidationWarningForeground,this.inputValidationWarningBorder=v.inputValidationWarningBorder,this.inputValidationErrorBackground=v.inputValidationErrorBackground,this.inputValidationErrorForeground=v.inputValidationErrorForeground,this.inputValidationErrorBorder=v.inputValidationErrorBorder,this.applyStyles()}applyStyles(){const v=this.inputBackground?this.inputBackground.toString():"",k=this.inputForeground?this.inputForeground.toString():"",D=this.inputBorder?this.inputBorder.toString():"";this.element.style.backgroundColor=v,this.element.style.color=k,this.input.style.backgroundColor="inherit",this.input.style.color=k,this.element.style.borderWidth=D?"1px":"",this.element.style.borderStyle=D?"solid":"",this.element.style.borderColor=D}layout(){if(!this.mirror)return;const v=this.cachedContentHeight;this.cachedContentHeight=b.OK(this.mirror),v!==this.cachedContentHeight&&(this.cachedHeight=Math.min(this.cachedContentHeight,this.maxHeight),this.input.style.height=this.cachedHeight+"px",this._onDidHeightChange.fire(this.cachedContentHeight))}insertAtCursor(v){const k=this.inputElement,D=k.selectionStart,x=k.selectionEnd,A=k.value;D!==null&&x!==null&&(this.value=A.substr(0,D)+v+A.substr(x),k.setSelectionRange(D+1,D+1),this.layout())}dispose(){this._hideMessage(),this.message=null,this.actionbar&&this.actionbar.dispose(),super.dispose()}}class C extends w{constructor(v,k,D){const x=h.kg({key:"history.inputbox.hint",comment:["Text will be prefixed with \u21C5 plus a single space, then used as a hint where input field keeps history"]},"for history"),A=` or \u21C5 ${x}`,W=` (\u21C5 ${x})`;super(v,k,D),this._onDidFocus=this._register(new T.vl),this.onDidFocus=this._onDidFocus.event,this._onDidBlur=this._register(new T.vl),this.onDidBlur=this._onDidBlur.event,this.history=new d(D.history,100);const Y=()=>{if(D.showHistoryHint&&D.showHistoryHint()&&!this.placeholder.endsWith(A)&&!this.placeholder.endsWith(W)&&this.history.getHistory().length){const ne=this.placeholder.endsWith(")")?A:W,j=this.placeholder+ne;D.showPlaceholderOnFocus&&document.activeElement!==this.input?this.placeholder=j:this.setPlaceHolder(j)}};this.observer=new MutationObserver((ne,j)=>{ne.forEach(Q=>{Q.target.textContent||Y()})}),this.observer.observe(this.input,{attributeFilter:["class"]}),this.onfocus(this.input,()=>Y()),this.onblur(this.input,()=>{const ne=j=>{if(this.placeholder.endsWith(j)){const Q=this.placeholder.slice(0,this.placeholder.length-j.length);return D.showPlaceholderOnFocus?this.placeholder=Q:this.setPlaceHolder(Q),!0}else return!1};ne(W)||ne(A)})}dispose(){super.dispose(),this.observer&&(this.observer.disconnect(),this.observer=void 0)}addToHistory(){this.value&&this.value!==this.getCurrentValue()&&this.history.add(this.value)}showNextValue(){this.history.has(this.value)||this.addToHistory();let v=this.getNextValue();v&&(v=v===this.value?this.getNextValue():v),v&&(this.value=v,L.h5(this.value))}showPreviousValue(){this.history.has(this.value)||this.addToHistory();let v=this.getPreviousValue();v&&(v=v===this.value?this.getPreviousValue():v),v&&(this.value=v,L.h5(this.value))}onBlur(){super.onBlur(),this._onDidBlur.fire()}onFocus(){super.onFocus(),this._onDidFocus.fire()}getCurrentValue(){let v=this.history.current();return v||(v=this.history.last(),this.history.next()),v}getPreviousValue(){return this.history.previous()||this.history.first()}getNextValue(){return this.history.next()||this.history.last()}}},29879:(rt,ye,y)=>{y.d(ye,{AI:()=>K,Kz:()=>L,Ot:()=>$});var b=y(66459),o=y(82399),K=b.A;const $=(0,o.u1)("notificationService");class L{}},29895:(rt,ye,y)=>{y.d(ye,{MF:()=>d,d$:()=>p,mG:()=>l,vG:()=>w,vY:()=>u});var b=y(15365),o=y(50442),K=y(93702),$=y(19184),L=y(62549),U=y(57999);const P=()=>!0,B=()=>!1,T=C=>C===" "||C===" ";class p{constructor(m,v,k,D){this.languageConfigurationService=D,this._cursorMoveConfigurationBrand=void 0,this._languageId=m;const x=k.options,A=x.get(133);this.readOnly=x.get(83),this.tabSize=v.tabSize,this.indentSize=v.indentSize,this.insertSpaces=v.insertSpaces,this.stickyTabStops=x.get(106),this.lineHeight=x.get(61),this.pageSize=Math.max(1,Math.floor(A.height/this.lineHeight)-2),this.useTabStops=x.get(118),this.wordSeparators=x.get(119),this.emptySelectionClipboard=x.get(33),this.copyWithSyntaxHighlighting=x.get(21),this.multiCursorMergeOverlapping=x.get(71),this.multiCursorPaste=x.get(73),this.autoClosingBrackets=x.get(5),this.autoClosingQuotes=x.get(8),this.autoClosingDelete=x.get(6),this.autoClosingOvertype=x.get(7),this.autoSurround=x.get(11),this.autoIndent=x.get(9),this.surroundingPairs={},this._electricChars=null,this.shouldAutoCloseBefore={quote:this._getShouldAutoClose(m,this.autoClosingQuotes),bracket:this._getShouldAutoClose(m,this.autoClosingBrackets)},this.autoClosingPairs=this.languageConfigurationService.getLanguageConfiguration(m).getAutoClosingPairs();const W=this.languageConfigurationService.getLanguageConfiguration(m).getSurroundingPairs();if(W)for(const Y of W)this.surroundingPairs[Y.open]=Y.close}static shouldRecreate(m){return m.hasChanged(133)||m.hasChanged(119)||m.hasChanged(33)||m.hasChanged(71)||m.hasChanged(73)||m.hasChanged(5)||m.hasChanged(8)||m.hasChanged(6)||m.hasChanged(7)||m.hasChanged(11)||m.hasChanged(118)||m.hasChanged(61)||m.hasChanged(83)}get electricChars(){var m;if(!this._electricChars){this._electricChars={};const v=(m=this.languageConfigurationService.getLanguageConfiguration(this._languageId).electricCharacter)===null||m===void 0?void 0:m.getElectricCharacters();if(v)for(const k of v)this._electricChars[k]=!0}return this._electricChars}onElectricCharacter(m,v,k){const D=(0,$.BQ)(v,k-1),x=this.languageConfigurationService.getLanguageConfiguration(D.languageId).electricCharacter;return x?x.onElectricCharacter(m,D,k-D.firstCharOffset):null}normalizeIndentation(m){return(0,U.P)(m,this.indentSize,this.insertSpaces)}_getShouldAutoClose(m,v){switch(v){case"beforeWhitespace":return T;case"languageDefined":return this._getLanguageDefinedShouldAutoClose(m);case"always":return P;case"never":return B}}_getLanguageDefinedShouldAutoClose(m){const v=this.languageConfigurationService.getLanguageConfiguration(m).getAutoCloseBeforeSet();return k=>v.indexOf(k)!==-1}visibleColumnFromColumn(m,v){return L.A.visibleColumnFromColumn(m.getLineContent(v.lineNumber),v.column,this.tabSize)}columnFromVisibleColumn(m,v,k){const D=L.A.columnFromVisibleColumn(m.getLineContent(v),k,this.tabSize),x=m.getLineMinColumn(v);if(D<x)return x;const A=m.getLineMaxColumn(v);return D>A?A:D}}class d{constructor(m,v){this._cursorStateBrand=void 0,this.modelState=m,this.viewState=v}static fromModelState(m){return new g(m)}static fromViewState(m){return new h(m)}static fromModelSelection(m){const v=K.L.liftSelection(m),k=new l(o.Q.fromPositions(v.getSelectionStart()),0,v.getPosition(),0);return d.fromModelState(k)}static fromModelSelections(m){const v=[];for(let k=0,D=m.length;k<D;k++)v[k]=this.fromModelSelection(m[k]);return v}equals(m){return this.viewState.equals(m.viewState)&&this.modelState.equals(m.modelState)}}class g{constructor(m){this.modelState=m,this.viewState=null}}class h{constructor(m){this.modelState=null,this.viewState=m}}class l{constructor(m,v,k,D){this._singleCursorStateBrand=void 0,this.selectionStart=m,this.selectionStartLeftoverVisibleColumns=v,this.position=k,this.leftoverVisibleColumns=D,this.selection=l._computeSelection(this.selectionStart,this.position)}equals(m){return this.selectionStartLeftoverVisibleColumns===m.selectionStartLeftoverVisibleColumns&&this.leftoverVisibleColumns===m.leftoverVisibleColumns&&this.position.equals(m.position)&&this.selectionStart.equalsRange(m.selectionStart)}hasSelection(){return!this.selection.isEmpty()||!this.selectionStart.isEmpty()}move(m,v,k,D){return m?new l(this.selectionStart,this.selectionStartLeftoverVisibleColumns,new b.y(v,k),D):new l(new o.Q(v,k,v,k),D,new b.y(v,k),D)}static _computeSelection(m,v){return m.isEmpty()||!v.isBeforeOrEqual(m.getStartPosition())?K.L.fromPositions(m.getStartPosition(),v):K.L.fromPositions(m.getEndPosition(),v)}}class u{constructor(m,v,k){this._editOperationResultBrand=void 0,this.type=m,this.commands=v,this.shouldPushStackElementBefore=k.shouldPushStackElementBefore,this.shouldPushStackElementAfter=k.shouldPushStackElementAfter}}function w(C){return C==="'"||C==='"'||C==="`"}},30474:(rt,ye,y)=>{y.d(ye,{B:()=>U,q:()=>P});var b=y(14333),o=y(13338),K=y(88846),$=y(10998),L=function(B,T,p,d){var g=arguments.length,h=g<3?T:d===null?d=Object.getOwnPropertyDescriptor(T,p):d,l;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")h=Reflect.decorate(B,T,p,d);else for(var u=B.length-1;u>=0;u--)(l=B[u])&&(h=(g<3?l(h):g>3?l(T,p,h):l(T,p))||h);return g>3&&h&&Object.defineProperty(T,p,h),h},U;(function(B){B.Tap="-monaco-gesturetap",B.Change="-monaco-gesturechange",B.Start="-monaco-gesturestart",B.End="-monaco-gesturesend",B.Contextmenu="-monaco-gesturecontextmenu"})(U||(U={}));class P extends $.jG{constructor(){super(),this.dispatched=!1,this.activeTouches={},this.handle=null,this.targets=[],this.ignoreTargets=[],this._lastSetTapCountTime=0,this._register(b.ko(document,"touchstart",T=>this.onTouchStart(T),{passive:!1})),this._register(b.ko(document,"touchend",T=>this.onTouchEnd(T))),this._register(b.ko(document,"touchmove",T=>this.onTouchMove(T),{passive:!1}))}static addTarget(T){return P.isTouchDevice()?(P.INSTANCE||(P.INSTANCE=new P),P.INSTANCE.targets.push(T),{dispose:()=>{P.INSTANCE.targets=P.INSTANCE.targets.filter(p=>p!==T)}}):$.jG.None}static ignoreTarget(T){return P.isTouchDevice()?(P.INSTANCE||(P.INSTANCE=new P),P.INSTANCE.ignoreTargets.push(T),{dispose:()=>{P.INSTANCE.ignoreTargets=P.INSTANCE.ignoreTargets.filter(p=>p!==T)}}):$.jG.None}static isTouchDevice(){return"ontouchstart"in window||navigator.maxTouchPoints>0}dispose(){this.handle&&(this.handle.dispose(),this.handle=null),super.dispose()}onTouchStart(T){const p=Date.now();this.handle&&(this.handle.dispose(),this.handle=null);for(let d=0,g=T.targetTouches.length;d<g;d++){const h=T.targetTouches.item(d);this.activeTouches[h.identifier]={id:h.identifier,initialTarget:h.target,initialTimeStamp:p,initialPageX:h.pageX,initialPageY:h.pageY,rollingTimestamps:[p],rollingPageX:[h.pageX],rollingPageY:[h.pageY]};const l=this.newGestureEvent(U.Start,h.target);l.pageX=h.pageX,l.pageY=h.pageY,this.dispatchEvent(l)}this.dispatched&&(T.preventDefault(),T.stopPropagation(),this.dispatched=!1)}onTouchEnd(T){const p=Date.now(),d=Object.keys(this.activeTouches).length;for(let g=0,h=T.changedTouches.length;g<h;g++){const l=T.changedTouches.item(g);if(!this.activeTouches.hasOwnProperty(String(l.identifier))){console.warn("move of an UNKNOWN touch",l);continue}const u=this.activeTouches[l.identifier],w=Date.now()-u.initialTimeStamp;if(w<P.HOLD_DELAY&&Math.abs(u.initialPageX-o.RT(u.rollingPageX))<30&&Math.abs(u.initialPageY-o.RT(u.rollingPageY))<30){const C=this.newGestureEvent(U.Tap,u.initialTarget);C.pageX=o.RT(u.rollingPageX),C.pageY=o.RT(u.rollingPageY),this.dispatchEvent(C)}else if(w>=P.HOLD_DELAY&&Math.abs(u.initialPageX-o.RT(u.rollingPageX))<30&&Math.abs(u.initialPageY-o.RT(u.rollingPageY))<30){const C=this.newGestureEvent(U.Contextmenu,u.initialTarget);C.pageX=o.RT(u.rollingPageX),C.pageY=o.RT(u.rollingPageY),this.dispatchEvent(C)}else if(d===1){const C=o.RT(u.rollingPageX),m=o.RT(u.rollingPageY),v=o.RT(u.rollingTimestamps)-u.rollingTimestamps[0],k=C-u.rollingPageX[0],D=m-u.rollingPageY[0],x=this.targets.filter(A=>u.initialTarget instanceof Node&&A.contains(u.initialTarget));this.inertia(x,p,Math.abs(k)/v,k>0?1:-1,C,Math.abs(D)/v,D>0?1:-1,m)}this.dispatchEvent(this.newGestureEvent(U.End,u.initialTarget)),delete this.activeTouches[l.identifier]}this.dispatched&&(T.preventDefault(),T.stopPropagation(),this.dispatched=!1)}newGestureEvent(T,p){const d=document.createEvent("CustomEvent");return d.initEvent(T,!1,!0),d.initialTarget=p,d.tapCount=0,d}dispatchEvent(T){if(T.type===U.Tap){const p=new Date().getTime();let d=0;p-this._lastSetTapCountTime>P.CLEAR_TAP_COUNT_TIME?d=1:d=2,this._lastSetTapCountTime=p,T.tapCount=d}else(T.type===U.Change||T.type===U.Contextmenu)&&(this._lastSetTapCountTime=0);for(let p=0;p<this.ignoreTargets.length;p++)if(T.initialTarget instanceof Node&&this.ignoreTargets[p].contains(T.initialTarget))return;this.targets.forEach(p=>{T.initialTarget instanceof Node&&p.contains(T.initialTarget)&&(p.dispatchEvent(T),this.dispatched=!0)})}inertia(T,p,d,g,h,l,u,w){this.handle=b.PG(()=>{const C=Date.now(),m=C-p;let v=0,k=0,D=!0;d+=P.SCROLL_FRICTION*m,l+=P.SCROLL_FRICTION*m,d>0&&(D=!1,v=g*d*m),l>0&&(D=!1,k=u*l*m);const x=this.newGestureEvent(U.Change);x.translationX=v,x.translationY=k,T.forEach(A=>A.dispatchEvent(x)),D||this.inertia(T,C,d,g,h+v,l,u,w+k)})}onTouchMove(T){const p=Date.now();for(let d=0,g=T.changedTouches.length;d<g;d++){const h=T.changedTouches.item(d);if(!this.activeTouches.hasOwnProperty(String(h.identifier))){console.warn("end of an UNKNOWN touch",h);continue}const l=this.activeTouches[h.identifier],u=this.newGestureEvent(U.Change,l.initialTarget);u.translationX=h.pageX-o.RT(l.rollingPageX),u.translationY=h.pageY-o.RT(l.rollingPageY),u.pageX=h.pageX,u.pageY=h.pageY,this.dispatchEvent(u),l.rollingPageX.length>3&&(l.rollingPageX.shift(),l.rollingPageY.shift(),l.rollingTimestamps.shift()),l.rollingPageX.push(h.pageX),l.rollingPageY.push(h.pageY),l.rollingTimestamps.push(p)}this.dispatched&&(T.preventDefault(),T.stopPropagation(),this.dispatched=!1)}}P.SCROLL_FRICTION=-.005,P.HOLD_DELAY=700,P.CLEAR_TAP_COUNT_TIME=400,L([K.B],P,"isTouchDevice",null)},30657:(rt,ye,y)=>{y.d(ye,{a:()=>b});class b{constructor(...K){this._entries=new Map;for(const[$,L]of K)this.set($,L)}set(K,$){const L=this._entries.get(K);return this._entries.set(K,$),L}get(K){return this._entries.get(K)}}},30812:(rt,ye,y)=>{y.d(ye,{_:()=>$});var b=y(14333),o=y(91818),K=y(71386);class ${constructor(U,P){var B;this.text="",this.title="",this.highlights=[],this.didEverRender=!1,this.supportIcons=(B=P?.supportIcons)!==null&&B!==void 0?B:!1,this.domNode=b.BC(U,b.$("span.monaco-highlighted-label"))}get element(){return this.domNode}set(U,P=[],B="",T){U||(U=""),T&&(U=$.escapeNewLines(U,P)),!(this.didEverRender&&this.text===U&&this.title===B&&K.aI(this.highlights,P))&&(this.text=U,this.title=B,this.highlights=P,this.render())}render(){const U=[];let P=0;for(const B of this.highlights){if(B.end===B.start)continue;if(P<B.start){const d=this.text.substring(P,B.start);U.push(b.$("span",void 0,...this.supportIcons?(0,o.n)(d):[d])),P=B.end}const T=this.text.substring(B.start,B.end),p=b.$("span.highlight",void 0,...this.supportIcons?(0,o.n)(T):[T]);B.extraClasses&&p.classList.add(...B.extraClasses),U.push(p),P=B.end}if(P<this.text.length){const B=this.text.substring(P);U.push(b.$("span",void 0,...this.supportIcons?(0,o.n)(B):[B]))}b.Ln(this.domNode,...U),this.title?this.domNode.title=this.title:this.domNode.removeAttribute("title"),this.didEverRender=!0}static escapeNewLines(U,P){let B=0,T=0;return U.replace(/\r\n|\r|\n/g,(p,d)=>{T=p===`\r `?-1:0,d+=B;for(const g of P)g.end<=d||(g.start>=d&&(g.start+=T),g.end>=d&&(g.end+=T));return B+=T,"\u23CE"})}}},31430:(rt,ye,y)=>{y.d(ye,{GN:()=>U,UB:()=>L,a6:()=>P,wc:()=>B});var b=y(15365),o=y(50442),K=y(11608),$=y(66476);class L{constructor(d,g,h,l,u){this.editorId=d,this.model=g,this.configuration=h,this._linesCollection=l,this._coordinatesConverter=u,this._decorationsCache=Object.create(null),this._cachedModelDecorationsResolver=null,this._cachedModelDecorationsResolverViewRange=null}_clearCachedModelDecorationsResolver(){this._cachedModelDecorationsResolver=null,this._cachedModelDecorationsResolverViewRange=null}dispose(){this._decorationsCache=Object.create(null),this._clearCachedModelDecorationsResolver()}reset(){this._decorationsCache=Object.create(null),this._clearCachedModelDecorationsResolver()}onModelDecorationsChanged(){this._decorationsCache=Object.create(null),this._clearCachedModelDecorationsResolver()}onLineMappingChanged(){this._decorationsCache=Object.create(null),this._clearCachedModelDecorationsResolver()}_getOrCreateViewModelDecoration(d){const g=d.id;let h=this._decorationsCache[g];if(!h){const l=d.range,u=d.options;let w;if(u.isWholeLine){const C=this._coordinatesConverter.convertModelPositionToViewPosition(new b.y(l.startLineNumber,1),0),m=this._coordinatesConverter.convertModelPositionToViewPosition(new b.y(l.endLineNumber,this.model.getLineMaxColumn(l.endLineNumber)),1);w=new o.Q(C.lineNumber,C.column,m.lineNumber,m.column)}else w=this._coordinatesConverter.convertModelRangeToViewRange(l,1);h=new K.vo(w,u),this._decorationsCache[g]=h}return h}getDecorationsViewportData(d){let g=this._cachedModelDecorationsResolver!==null;return g=g&&d.equalsRange(this._cachedModelDecorationsResolverViewRange),g||(this._cachedModelDecorationsResolver=this._getDecorationsInRange(d),this._cachedModelDecorationsResolverViewRange=d),this._cachedModelDecorationsResolver}getInlineDecorationsOnLine(d){const g=new o.Q(d,this._linesCollection.getViewLineMinColumn(d),d,this._linesCollection.getViewLineMaxColumn(d));return this._getDecorationsInRange(g).inlineDecorations[0]}_getDecorationsInRange(d){const g=this._linesCollection.getDecorationsInRange(d,this.editorId,(0,$.$C)(this.configuration.options)),h=d.startLineNumber,l=d.endLineNumber,u=[];let w=0;const C=[];for(let m=h;m<=l;m++)C[m-h]=[];for(let m=0,v=g.length;m<v;m++){const k=g[m],D=k.options;if(!U(this.model,k))continue;const x=this._getOrCreateViewModelDecoration(k),A=x.range;if(u[w++]=x,D.inlineClassName){const W=new K.kI(A,D.inlineClassName,D.inlineClassNameAffectsLetterSpacing?3:0),Y=Math.max(h,A.startLineNumber),ne=Math.min(l,A.endLineNumber);for(let j=Y;j<=ne;j++)C[j-h].push(W)}if(D.beforeContentClassName&&h<=A.startLineNumber&&A.startLineNumber<=l){const W=new K.kI(new o.Q(A.startLineNumber,A.startColumn,A.startLineNumber,A.startColumn),D.beforeContentClassName,1);C[A.startLineNumber-h].push(W)}if(D.afterContentClassName&&h<=A.endLineNumber&&A.endLineNumber<=l){const W=new K.kI(new o.Q(A.endLineNumber,A.endColumn,A.endLineNumber,A.endColumn),D.afterContentClassName,2);C[A.endLineNumber-h].push(W)}}return{decorations:u,inlineDecorations:C}}}function U(p,d){return!(d.options.hideInCommentTokens&&P(p,d)||d.options.hideInStringTokens&&B(p,d))}function P(p,d){return T(p,d.range,g=>g===1)}function B(p,d){return T(p,d.range,g=>g===2)}function T(p,d,g){for(let h=d.startLineNumber;h<=d.endLineNumber;h++){const l=p.tokenization.getLineTokens(h),u=h===d.startLineNumber,w=h===d.endLineNumber;let C=u?l.findTokenIndexAtOffset(d.startColumn-1):0;for(;C<l.getCount()&&!(w&&l.getStartOffset(C)>d.endColumn-1);){if(!g(l.getStandardTokenType(C)))return!1;C++}}return!0}},32177:(rt,ye,y)=>{y.d(ye,{_:()=>o});var b=y(10998);class o extends b.jG{constructor(){super(...arguments),this._isDisposed=!1}dispose(){super.dispose(),this._isDisposed=!0}assertNotDisposed(){if(this._isDisposed)throw new Error("TextModelPart is disposed!")}}},32802:(rt,ye,y)=>{y.d(ye,{C1:()=>K,Ym:()=>b,kF:()=>o});const b={ctrlCmd:!1,alt:!1};var o;(function(U){U[U.Blur=1]="Blur",U[U.Gesture=2]="Gesture",U[U.Other=3]="Other"})(o||(o={}));var K;(function(U){U[U.NONE=0]="NONE",U[U.FIRST=1]="FIRST",U[U.SECOND=2]="SECOND",U[U.LAST=3]="LAST"})(K||(K={}));class ${constructor(P){this.options=P}}const L=new $},33206:(rt,ye,y)=>{y.d(ye,{_:()=>T,ou:()=>U,tk:()=>P});var b=y(94327),o=y(15910),K=y(64651),$=y(34883),L=y(60756);class U{constructor(d,g,h,l,u){this.length=d,this.kind=g,this.bracketId=h,this.bracketIds=l,this.astNode=u}}class P{constructor(d,g){this.textModel=d,this.bracketTokens=g,this.reader=new B(this.textModel,this.bracketTokens),this._offset=$.Vp,this.didPeek=!1,this.peeked=null,this.textBufferLineCount=d.getLineCount(),this.textBufferLastLineLength=d.getLineLength(this.textBufferLineCount)}get offset(){return this._offset}get length(){return(0,$.qe)(this.textBufferLineCount,this.textBufferLastLineLength)}skip(d){this.didPeek=!1,this._offset=(0,$.QB)(this._offset,d);const g=(0,$.l4)(this._offset);this.reader.setPosition(g.lineCount,g.columnCount)}read(){let d;return this.peeked?(this.didPeek=!1,d=this.peeked):d=this.reader.read(),d&&(this._offset=(0,$.QB)(this._offset,d.length)),d}peek(){return this.didPeek||(this.peeked=this.reader.read(),this.didPeek=!0),this.peeked}}class B{constructor(d,g){this.textModel=d,this.bracketTokens=g,this.lineIdx=0,this.line=null,this.lineCharOffset=0,this.lineTokens=null,this.lineTokenOffset=0,this.peekedToken=null,this.textBufferLineCount=d.getLineCount(),this.textBufferLastLineLength=d.getLineLength(this.textBufferLineCount)}setPosition(d,g){d===this.lineIdx?(this.lineCharOffset=g,this.lineTokenOffset=this.lineCharOffset===0?0:this.lineTokens.findTokenIndexAtOffset(this.lineCharOffset)):(this.lineIdx=d,this.lineCharOffset=g,this.line=null),this.peekedToken=null}read(){if(this.peekedToken){const u=this.peekedToken;return this.peekedToken=null,this.lineCharOffset+=(0,$.sS)(u.length),u}if(this.lineIdx>this.textBufferLineCount-1||this.lineIdx===this.textBufferLineCount-1&&this.lineCharOffset>=this.textBufferLastLineLength)return null;this.line===null&&(this.lineTokens=this.textModel.tokenization.getLineTokens(this.lineIdx+1),this.line=this.lineTokens.getLineContent(),this.lineTokenOffset=this.lineCharOffset===0?0:this.lineTokens.findTokenIndexAtOffset(this.lineCharOffset));const d=this.lineIdx,g=this.lineCharOffset;let h=0;for(;;){const u=this.lineTokens,w=u.getCount();let C=null;if(this.lineTokenOffset<w){const m=u.getMetadata(this.lineTokenOffset);for(;this.lineTokenOffset+1<w&&m===u.getMetadata(this.lineTokenOffset+1);)this.lineTokenOffset++;const v=o.x.getTokenType(m)===0,k=o.x.containsBalancedBrackets(m),D=u.getEndOffset(this.lineTokenOffset);if(k&&v&&this.lineCharOffset<D){const x=u.getLanguageId(this.lineTokenOffset),A=this.line.substring(this.lineCharOffset,D),W=this.bracketTokens.getSingleLanguageBracketTokens(x),Y=W.regExpGlobal;if(Y){Y.lastIndex=0;const ne=Y.exec(A);ne&&(C=W.getToken(ne[0]),C&&(this.lineCharOffset+=ne.index))}}if(h+=D-this.lineCharOffset,C)if(d!==this.lineIdx||g!==this.lineCharOffset){this.peekedToken=C;break}else return this.lineCharOffset+=(0,$.sS)(C.length),C;else this.lineTokenOffset++,this.lineCharOffset=D}else if(this.lineIdx===this.textBufferLineCount-1||(this.lineIdx++,this.lineTokens=this.textModel.tokenization.getLineTokens(this.lineIdx+1),this.lineTokenOffset=0,this.line=this.lineTokens.getLineContent(),this.lineCharOffset=0,h+=33,h>1e3))break;if(h>1500)break}const l=(0,$.C7)(d,g,this.lineIdx,this.lineCharOffset);return new U(l,0,-1,L.gV.getEmpty(),new K.yF(l))}}class T{constructor(d,g){this.text=d,this._offset=$.Vp,this.idx=0;const h=g.getRegExpStr(),l=h?new RegExp(h+`| `,"gi"):null,u=[];let w,C=0,m=0,v=0,k=0;const D=new Array;for(let W=0;W<60;W++)D.push(new U((0,$.qe)(0,W),0,-1,L.gV.getEmpty(),new K.yF((0,$.qe)(0,W))));const x=new Array;for(let W=0;W<60;W++)x.push(new U((0,$.qe)(1,W),0,-1,L.gV.getEmpty(),new K.yF((0,$.qe)(1,W))));if(l)for(l.lastIndex=0;(w=l.exec(d))!==null;){const W=w.index,Y=w[0];if(Y===` `)C++,m=W+1;else{if(v!==W){let ne;if(k===C){const j=W-v;if(j<D.length)ne=D[j];else{const Q=(0,$.qe)(0,j);ne=new U(Q,0,-1,L.gV.getEmpty(),new K.yF(Q))}}else{const j=C-k,Q=W-m;if(j===1&&Q<x.length)ne=x[Q];else{const X=(0,$.qe)(j,Q);ne=new U(X,0,-1,L.gV.getEmpty(),new K.yF(X))}}u.push(ne)}u.push(g.getToken(Y)),v=W+Y.length,k=C}}const A=d.length;if(v!==A){const W=k===C?(0,$.qe)(0,A-v):(0,$.qe)(C-k,A-m);u.push(new U(W,0,-1,L.gV.getEmpty(),new K.yF(W)))}this.length=(0,$.qe)(C,A-m),this.tokens=u}get offset(){return this._offset}read(){return this.tokens[this.idx++]||null}peek(){return this.tokens[this.idx]||null}skip(d){throw new b.EM}}},34061:(rt,ye,y)=>{y.d(ye,{f:()=>o,j:()=>K});var b=y(2106);class o{constructor(L,U,P){const B=T=>this.emitter.fire(T);this.emitter=new b.vl({onFirstListenerAdd:()=>L.addEventListener(U,B,P),onLastListenerRemove:()=>L.removeEventListener(U,B,P)})}get event(){return this.emitter.event}dispose(){this.emitter.dispose()}}function K($){return $.preventDefault(),$.stopPropagation(),$}},34883:(rt,ye,y)=>{y.d(ye,{C7:()=>$,MS:()=>h,QB:()=>g,Qx:()=>m,VL:()=>C,Vh:()=>U,Vp:()=>L,eu:()=>p,l4:()=>T,o0:()=>w,qe:()=>B,rR:()=>v,sS:()=>d,vr:()=>u,zG:()=>l});var b=y(16844),o=y(50442);class K{constructor(D,x){this.lineCount=D,this.columnCount=x}toString(){return`${this.lineCount},${this.columnCount}`}}K.zero=new K(0,0);function $(k,D,x,A){return k!==x?B(x-k,A):B(0,A-D)}const L=0;function U(k){return k===0}const P=Math.pow(2,26);function B(k,D){return k*P+D}function T(k){const D=k,x=Math.floor(D/P),A=D-x*P;return new K(x,A)}function p(k){return Math.floor(k/P)}function d(k){return k}function g(k,D){return D<P?k+D:k-k%P+D}function h(k,D){const x=k,A=D;if(A-x<=0)return L;const Y=Math.floor(x/P),ne=Math.floor(A/P),j=A-ne*P;if(Y===ne){const Q=x-Y*P;return B(0,j-Q)}else return B(ne-Y,j)}function l(k,D){return k<D}function u(k,D){return k<=D}function w(k,D){return k>=D}function C(k){return B(k.lineNumber-1,k.column-1)}function m(k,D){const x=k,A=Math.floor(x/P),W=x-A*P,Y=D,ne=Math.floor(Y/P),j=Y-ne*P;return new o.Q(A+1,W+1,ne+1,j+1)}function v(k){const D=(0,b.uz)(k);return B(D.length-1,D[D.length-1].length)}},36260:(rt,ye,y)=>{y.d(ye,{V:()=>o,o:()=>b});class b{constructor($){this.fn=$,this.lastCache=void 0,this.lastArgKey=void 0}get($){const L=JSON.stringify($);return this.lastArgKey!==L&&(this.lastArgKey=L,this.lastCache=this.fn($)),this.lastCache}}class o{constructor($){this.fn=$,this._map=new Map}get cachedValues(){return this._map}get($){if(this._map.has($))return this._map.get($);const L=this.fn($);return this._map.set($,L),L}}},37042:(rt,ye,y)=>{y.d(ye,{b:()=>o});var b=y(82399);const o=(0,b.u1)("textModelService")},37264:(rt,ye,y)=>{y.d(ye,{I:()=>m,r:()=>g});var b=y(18019),o=y(63339);const K=/^\w[\w\d+.-]*$/,$=/^\//,L=/^\/\//;function U(A,W){if(!A.scheme&&W)throw new Error(`[UriError]: Scheme is missing: {scheme: "", authority: "${A.authority}", path: "${A.path}", query: "${A.query}", fragment: "${A.fragment}"}`);if(A.scheme&&!K.test(A.scheme))throw new Error("[UriError]: Scheme contains illegal characters.");if(A.path){if(A.authority){if(!$.test(A.path))throw new Error('[UriError]: If a URI contains an authority component, then the path component must either be empty or begin with a slash ("/") character')}else if(L.test(A.path))throw new Error('[UriError]: If a URI does not contain an authority component, then the path cannot begin with two slash characters ("//")')}}function P(A,W){return!A&&!W?"file":A}function B(A,W){switch(A){case"https":case"http":case"file":W?W[0]!==p&&(W=p+W):W=p;break}return W}const T="",p="/",d=/^(([^:/?#]+?):)?(\/\/([^/?#]*))?([^?#]*)(\?([^#]*))?(#(.*))?/;class g{constructor(W,Y,ne,j,Q,X=!1){typeof W=="object"?(this.scheme=W.scheme||T,this.authority=W.authority||T,this.path=W.path||T,this.query=W.query||T,this.fragment=W.fragment||T):(this.scheme=P(W,X),this.authority=Y||T,this.path=B(this.scheme,ne||T),this.query=j||T,this.fragment=Q||T,U(this,X))}static isUri(W){return W instanceof g?!0:W?typeof W.authority=="string"&&typeof W.fragment=="string"&&typeof W.path=="string"&&typeof W.query=="string"&&typeof W.scheme=="string"&&typeof W.fsPath=="string"&&typeof W.with=="function"&&typeof W.toString=="function":!1}get fsPath(){return m(this,!1)}with(W){if(!W)return this;let{scheme:Y,authority:ne,path:j,query:Q,fragment:X}=W;return Y===void 0?Y=this.scheme:Y===null&&(Y=T),ne===void 0?ne=this.authority:ne===null&&(ne=T),j===void 0?j=this.path:j===null&&(j=T),Q===void 0?Q=this.query:Q===null&&(Q=T),X===void 0?X=this.fragment:X===null&&(X=T),Y===this.scheme&&ne===this.authority&&j===this.path&&Q===this.query&&X===this.fragment?this:new l(Y,ne,j,Q,X)}static parse(W,Y=!1){const ne=d.exec(W);return ne?new l(ne[2]||T,x(ne[4]||T),x(ne[5]||T),x(ne[7]||T),x(ne[9]||T),Y):new l(T,T,T,T,T)}static file(W){let Y=T;if(o.uF&&(W=W.replace(/\\/g,p)),W[0]===p&&W[1]===p){const ne=W.indexOf(p,2);ne===-1?(Y=W.substring(2),W=p):(Y=W.substring(2,ne),W=W.substring(ne)||p)}return new l("file",Y,W,T,T)}static from(W){const Y=new l(W.scheme,W.authority,W.path,W.query,W.fragment);return U(Y,!0),Y}static joinPath(W,...Y){if(!W.path)throw new Error("[UriError]: cannot call joinPath on URI without path");let ne;return o.uF&&W.scheme==="file"?ne=g.file(b.IN.join(m(W,!0),...Y)).path:ne=b.SA.join(W.path,...Y),W.with({path:ne})}toString(W=!1){return v(this,W)}toJSON(){return this}static revive(W){if(W){if(W instanceof g)return W;{const Y=new l(W);return Y._formatted=W.external,Y._fsPath=W._sep===h?W.fsPath:null,Y}}else return W}}const h=o.uF?1:void 0;class l extends g{constructor(){super(...arguments),this._formatted=null,this._fsPath=null}get fsPath(){return this._fsPath||(this._fsPath=m(this,!1)),this._fsPath}toString(W=!1){return W?v(this,!0):(this._formatted||(this._formatted=v(this,!1)),this._formatted)}toJSON(){const W={$mid:1};return this._fsPath&&(W.fsPath=this._fsPath,W._sep=h),this._formatted&&(W.external=this._formatted),this.path&&(W.path=this.path),this.scheme&&(W.scheme=this.scheme),this.authority&&(W.authority=this.authority),this.query&&(W.query=this.query),this.fragment&&(W.fragment=this.fragment),W}}const u={58:"%3A",47:"%2F",63:"%3F",35:"%23",91:"%5B",93:"%5D",64:"%40",33:"%21",36:"%24",38:"%26",39:"%27",40:"%28",41:"%29",42:"%2A",43:"%2B",44:"%2C",59:"%3B",61:"%3D",32:"%20"};function w(A,W){let Y,ne=-1;for(let j=0;j<A.length;j++){const Q=A.charCodeAt(j);if(Q>=97&&Q<=122||Q>=65&&Q<=90||Q>=48&&Q<=57||Q===45||Q===46||Q===95||Q===126||W&&Q===47)ne!==-1&&(Y+=encodeURIComponent(A.substring(ne,j)),ne=-1),Y!==void 0&&(Y+=A.charAt(j));else{Y===void 0&&(Y=A.substr(0,j));const X=u[Q];X!==void 0?(ne!==-1&&(Y+=encodeURIComponent(A.substring(ne,j)),ne=-1),Y+=X):ne===-1&&(ne=j)}}return ne!==-1&&(Y+=encodeURIComponent(A.substring(ne))),Y!==void 0?Y:A}function C(A){let W;for(let Y=0;Y<A.length;Y++){const ne=A.charCodeAt(Y);ne===35||ne===63?(W===void 0&&(W=A.substr(0,Y)),W+=u[ne]):W!==void 0&&(W+=A[Y])}return W!==void 0?W:A}function m(A,W){let Y;return A.authority&&A.path.length>1&&A.scheme==="file"?Y=`//${A.authority}${A.path}`:A.path.charCodeAt(0)===47&&(A.path.charCodeAt(1)>=65&&A.path.charCodeAt(1)<=90||A.path.charCodeAt(1)>=97&&A.path.charCodeAt(1)<=122)&&A.path.charCodeAt(2)===58?W?Y=A.path.substr(1):Y=A.path[1].toLowerCase()+A.path.substr(2):Y=A.path,o.uF&&(Y=Y.replace(/\//g,"\\")),Y}function v(A,W){const Y=W?C:w;let ne="",{scheme:j,authority:Q,path:X,query:R,fragment:H}=A;if(j&&(ne+=j,ne+=":"),(Q||j==="file")&&(ne+=p,ne+=p),Q){let Z=Q.indexOf("@");if(Z!==-1){const N=Q.substr(0,Z);Q=Q.substr(Z+1),Z=N.indexOf(":"),Z===-1?ne+=Y(N,!1):(ne+=Y(N.substr(0,Z),!1),ne+=":",ne+=Y(N.substr(Z+1),!1)),ne+="@"}Q=Q.toLowerCase(),Z=Q.indexOf(":"),Z===-1?ne+=Y(Q,!1):(ne+=Y(Q.substr(0,Z),!1),ne+=Q.substr(Z))}if(X){if(X.length>=3&&X.charCodeAt(0)===47&&X.charCodeAt(2)===58){const Z=X.charCodeAt(1);Z>=65&&Z<=90&&(X=`/${String.fromCharCode(Z+32)}:${X.substr(3)}`)}else if(X.length>=2&&X.charCodeAt(1)===58){const Z=X.charCodeAt(0);Z>=65&&Z<=90&&(X=`${String.fromCharCode(Z+32)}:${X.substr(2)}`)}ne+=Y(X,!0)}return R&&(ne+="?",ne+=Y(R,!1)),H&&(ne+="#",ne+=W?H:w(H,!1)),ne}function k(A){try{return decodeURIComponent(A)}catch{return A.length>3?A.substr(0,3)+k(A.substr(3)):A}}const D=/(%[0-9A-Za-z][0-9A-Za-z])+/g;function x(A){return A.match(D)?A.replace(D,W=>k(W)):A}},38122:(rt,ye,y)=>{y.d(ye,{R:()=>K});var b=y(3765),o=y(96655),K;(function($){$.editorSimpleInput=new o.N1("editorSimpleInput",!1,!0),$.editorTextFocus=new o.N1("editorTextFocus",!1,b.kg("editorTextFocus","Whether the editor text has focus (cursor is blinking)")),$.focus=new o.N1("editorFocus",!1,b.kg("editorFocus","Whether the editor or an editor widget has focus (e.g. focus is in the find widget)")),$.textInputFocus=new o.N1("textInputFocus",!1,b.kg("textInputFocus","Whether an editor or a rich text input has focus (cursor is blinking)")),$.readOnly=new o.N1("editorReadonly",!1,b.kg("editorReadonly","Whether the editor is read only")),$.inDiffEditor=new o.N1("inDiffEditor",!1,b.kg("inDiffEditor","Whether the context is a diff editor")),$.columnSelection=new o.N1("editorColumnSelection",!1,b.kg("editorColumnSelection","Whether `editor.columnSelection` is enabled")),$.writable=$.readOnly.toNegated(),$.hasNonEmptySelection=new o.N1("editorHasSelection",!1,b.kg("editorHasSelection","Whether the editor has text selected")),$.hasOnlyEmptySelection=$.hasNonEmptySelection.toNegated(),$.hasMultipleSelections=new o.N1("editorHasMultipleSelections",!1,b.kg("editorHasMultipleSelections","Whether the editor has multiple selections")),$.hasSingleSelection=$.hasMultipleSelections.toNegated(),$.tabMovesFocus=new o.N1("editorTabMovesFocus",!1,b.kg("editorTabMovesFocus","Whether `Tab` will move focus out of the editor")),$.tabDoesNotMoveFocus=$.tabMovesFocus.toNegated(),$.isInWalkThroughSnippet=new o.N1("isInEmbeddedEditor",!1,!0),$.canUndo=new o.N1("canUndo",!1,!0),$.canRedo=new o.N1("canRedo",!1,!0),$.hoverVisible=new o.N1("editorHoverVisible",!1,b.kg("editorHoverVisible","Whether the editor hover is visible")),$.inCompositeEditor=new o.N1("inCompositeEditor",void 0,b.kg("inCompositeEditor","Whether the editor is part of a larger editor (e.g. notebooks)")),$.notInCompositeEditor=$.inCompositeEditor.toNegated(),$.languageId=new o.N1("editorLangId","",b.kg("editorLangId","The language identifier of the editor")),$.hasCompletionItemProvider=new o.N1("editorHasCompletionItemProvider",!1,b.kg("editorHasCompletionItemProvider","Whether the editor has a completion item provider")),$.hasCodeActionsProvider=new o.N1("editorHasCodeActionsProvider",!1,b.kg("editorHasCodeActionsProvider","Whether the editor has a code actions provider")),$.hasCodeLensProvider=new o.N1("editorHasCodeLensProvider",!1,b.kg("editorHasCodeLensProvider","Whether the editor has a code lens provider")),$.hasDefinitionProvider=new o.N1("editorHasDefinitionProvider",!1,b.kg("editorHasDefinitionProvider","Whether the editor has a definition provider")),$.hasDeclarationProvider=new o.N1("editorHasDeclarationProvider",!1,b.kg("editorHasDeclarationProvider","Whether the editor has a declaration provider")),$.hasImplementationProvider=new o.N1("editorHasImplementationProvider",!1,b.kg("editorHasImplementationProvider","Whether the editor has an implementation provider")),$.hasTypeDefinitionProvider=new o.N1("editorHasTypeDefinitionProvider",!1,b.kg("editorHasTypeDefinitionProvider","Whether the editor has a type definition provider")),$.hasHoverProvider=new o.N1("editorHasHoverProvider",!1,b.kg("editorHasHoverProvider","Whether the editor has a hover provider")),$.hasDocumentHighlightProvider=new o.N1("editorHasDocumentHighlightProvider",!1,b.kg("editorHasDocumentHighlightProvider","Whether the editor has a document highlight provider")),$.hasDocumentSymbolProvider=new o.N1("editorHasDocumentSymbolProvider",!1,b.kg("editorHasDocumentSymbolProvider","Whether the editor has a document symbol provider")),$.hasReferenceProvider=new o.N1("editorHasReferenceProvider",!1,b.kg("editorHasReferenceProvider","Whether the editor has a reference provider")),$.hasRenameProvider=new o.N1("editorHasRenameProvider",!1,b.kg("editorHasRenameProvider","Whether the editor has a rename provider")),$.hasSignatureHelpProvider=new o.N1("editorHasSignatureHelpProvider",!1,b.kg("editorHasSignatureHelpProvider","Whether the editor has a signature help provider")),$.hasInlayHintsProvider=new o.N1("editorHasInlayHintsProvider",!1,b.kg("editorHasInlayHintsProvider","Whether the editor has an inline hints provider")),$.hasDocumentFormattingProvider=new o.N1("editorHasDocumentFormattingProvider",!1,b.kg("editorHasDocumentFormattingProvider","Whether the editor has a document formatting provider")),$.hasDocumentSelectionFormattingProvider=new o.N1("editorHasDocumentSelectionFormattingProvider",!1,b.kg("editorHasDocumentSelectionFormattingProvider","Whether the editor has a document selection formatting provider")),$.hasMultipleDocumentFormattingProvider=new o.N1("editorHasMultipleDocumentFormattingProvider",!1,b.kg("editorHasMultipleDocumentFormattingProvider","Whether the editor has multiple document formatting providers")),$.hasMultipleDocumentSelectionFormattingProvider=new o.N1("editorHasMultipleDocumentSelectionFormattingProvider",!1,b.kg("editorHasMultipleDocumentSelectionFormattingProvider","Whether the editor has multiple document selection formatting providers"))})(K||(K={}))},38801:(rt,ye,y)=>{y.d(ye,{Pj:()=>Y,pD:()=>A,jX:()=>ne,vg:()=>Q,_V:()=>Z});var b=y(59407),o=y(13338),K=y(78903),$=y(94327),L=y(17954),U=y(85525),P=y(79359),B=y(37264),T=y(62105),p=y(66638),d=y(15365),g=y(50442),h=y(93702),l=y(90304),u=y(37042),w=y(55406),C=y(3765),m=y(59715);class v{constructor(G){this.value=G,this._lower=G.toLowerCase()}static toKey(G){return typeof G=="string"?G.toLowerCase():G._lower}}var k=y(82399),D=y(52230),x=function(N,G,O,te){function oe(ue){return ue instanceof O?ue:new O(function(E){E(ue)})}return new(O||(O=Promise))(function(ue,E){function Qe(Me){try{Se(te.next(Me))}catch(ce){E(ce)}}function Ke(Me){try{Se(te.throw(Me))}catch(ce){E(ce)}}function Se(Me){Me.done?ue(Me.value):oe(Me.value).then(Qe,Ke)}Se((te=te.apply(N,G||[])).next())})};function A(N){if(N=N.filter(oe=>oe.range),!N.length)return;let{range:G}=N[0];for(let oe=1;oe<N.length;oe++)G=g.Q.plusRange(G,N[oe].range);const{startLineNumber:O,endLineNumber:te}=G;O===te?N.length===1?(0,b.xE)(C.kg("hint11","Made 1 formatting edit on line {0}",O)):(0,b.xE)(C.kg("hintn1","Made {0} formatting edits on line {1}",N.length,O)):N.length===1?(0,b.xE)(C.kg("hint1n","Made 1 formatting edit between lines {0} and {1}",O,te)):(0,b.xE)(C.kg("hintnn","Made {0} formatting edits between lines {1} and {2}",N.length,O,te))}function W(N,G,O){const te=[],oe=new Set,ue=N.ordered(O);for(const Qe of ue)te.push(Qe),Qe.extensionId&&oe.add(v.toKey(Qe.extensionId));const E=G.ordered(O);for(const Qe of E){if(Qe.extensionId){if(oe.has(v.toKey(Qe.extensionId)))continue;oe.add(v.toKey(Qe.extensionId))}te.push({displayName:Qe.displayName,extensionId:Qe.extensionId,provideDocumentFormattingEdits(Ke,Se,Me){return Qe.provideDocumentRangeFormattingEdits(Ke,Ke.getFullModelRange(),Se,Me)}})}return te}class Y{static setFormatterSelector(G){return{dispose:Y._selectors.unshift(G)}}static select(G,O,te){return x(this,void 0,void 0,function*(){if(G.length===0)return;const oe=L.f.first(Y._selectors);if(oe)return yield oe(G,O,te)})}}Y._selectors=new U.w;function ne(N,G,O,te,oe,ue){return x(this,void 0,void 0,function*(){const E=N.get(k._Y),{documentRangeFormattingEditProvider:Qe}=N.get(D.u),Ke=(0,p.z9)(G)?G.getModel():G,Se=Qe.ordered(Ke),Me=yield Y.select(Se,Ke,te);Me&&(oe.report(Me),yield E.invokeFunction(j,Me,G,O,ue))})}function j(N,G,O,te,oe){return x(this,void 0,void 0,function*(){const ue=N.get(l.w);let E,Qe;(0,p.z9)(O)?(E=O.getModel(),Qe=new T.gI(O,5,void 0,oe)):(E=O,Qe=new T.ER(O,oe));const Ke=[];let Se=0;for(const ge of(0,o._j)(te).sort(g.Q.compareRangesUsingStarts))Se>0&&g.Q.areIntersectingOrTouching(Ke[Se-1],ge)?Ke[Se-1]=g.Q.fromPositions(Ke[Se-1].getStartPosition(),ge.getEndPosition()):Se=Ke.push(ge);const Me=ge=>x(this,void 0,void 0,function*(){return(yield G.provideDocumentRangeFormattingEdits(E,ge,E.getFormattingOptions(),Qe.token))||[]}),ce=(ge,ke)=>{if(!ge.length||!ke.length)return!1;const We=ge.reduce((Ge,Ae)=>g.Q.plusRange(Ge,Ae.range),ge[0].range);if(!ke.some(Ge=>g.Q.intersectRanges(We,Ge.range)))return!1;for(const Ge of ge)for(const Ae of ke)if(g.Q.intersectRanges(Ge.range,Ae.range))return!0;return!1},pe=[],be=[];try{for(const ge of Ke){if(Qe.token.isCancellationRequested)return!0;be.push(yield Me(ge))}for(let ge=0;ge<Ke.length;++ge)for(let ke=ge+1;ke<Ke.length;++ke){if(Qe.token.isCancellationRequested)return!0;if(ce(be[ge],be[ke])){const We=g.Q.plusRange(Ke[ge],Ke[ke]),Ge=yield Me(We);Ke.splice(ke,1),Ke.splice(ge,1),Ke.push(We),be.splice(ke,1),be.splice(ge,1),be.push(Ge),ge=0,ke=0}}for(const ge of be){if(Qe.token.isCancellationRequested)return!0;const ke=yield ue.computeMoreMinimalEdits(E.uri,ge);ke&&pe.push(...ke)}}finally{Qe.dispose()}if(pe.length===0)return!1;if((0,p.z9)(O))w.c.execute(O,pe,!0),A(pe),O.revealPositionInCenterIfOutsideViewport(O.getPosition(),1);else{const[{range:ge}]=pe,ke=new h.L(ge.startLineNumber,ge.startColumn,ge.endLineNumber,ge.endColumn);E.pushEditOperations([ke],pe.map(We=>({text:We.text,range:g.Q.lift(We.range),forceMoveMarkers:!0})),We=>{for(const{range:Ge}of We)if(g.Q.areIntersectingOrTouching(Ge,ke))return[new h.L(Ge.startLineNumber,Ge.startColumn,Ge.endLineNumber,Ge.endColumn)];return null})}return!0})}function Q(N,G,O,te,oe){return x(this,void 0,void 0,function*(){const ue=N.get(k._Y),E=N.get(D.u),Qe=(0,p.z9)(G)?G.getModel():G,Ke=W(E.documentFormattingEditProvider,E.documentRangeFormattingEditProvider,Qe),Se=yield Y.select(Ke,Qe,O);Se&&(te.report(Se),yield ue.invokeFunction(X,Se,G,O,oe))})}function X(N,G,O,te,oe){return x(this,void 0,void 0,function*(){const ue=N.get(l.w);let E,Qe;(0,p.z9)(O)?(E=O.getModel(),Qe=new T.gI(O,5,void 0,oe)):(E=O,Qe=new T.ER(O,oe));let Ke;try{const Se=yield G.provideDocumentFormattingEdits(E,E.getFormattingOptions(),Qe.token);if(Ke=yield ue.computeMoreMinimalEdits(E.uri,Se),Qe.token.isCancellationRequested)return!0}finally{Qe.dispose()}if(!Ke||Ke.length===0)return!1;if((0,p.z9)(O))w.c.execute(O,Ke,te!==2),te!==2&&(A(Ke),O.revealPositionInCenterIfOutsideViewport(O.getPosition(),1));else{const[{range:Se}]=Ke,Me=new h.L(Se.startLineNumber,Se.startColumn,Se.endLineNumber,Se.endColumn);E.pushEditOperations([Me],Ke.map(ce=>({text:ce.text,range:g.Q.lift(ce.range),forceMoveMarkers:!0})),ce=>{for(const{range:pe}of ce)if(g.Q.areIntersectingOrTouching(pe,Me))return[new h.L(pe.startLineNumber,pe.startColumn,pe.endLineNumber,pe.endColumn)];return null})}return!0})}function R(N,G,O,te,oe,ue){return x(this,void 0,void 0,function*(){const E=G.documentRangeFormattingEditProvider.ordered(O);for(const Qe of E){const Ke=yield Promise.resolve(Qe.provideDocumentRangeFormattingEdits(O,te,oe,ue)).catch($.M_);if((0,o.EI)(Ke))return yield N.computeMoreMinimalEdits(O.uri,Ke)}})}function H(N,G,O,te,oe){return x(this,void 0,void 0,function*(){const ue=W(G.documentFormattingEditProvider,G.documentRangeFormattingEditProvider,O);for(const E of ue){const Qe=yield Promise.resolve(E.provideDocumentFormattingEdits(O,te,oe)).catch($.M_);if((0,o.EI)(Qe))return yield N.computeMoreMinimalEdits(O.uri,Qe)}})}function Z(N,G,O,te,oe,ue,E){const Qe=G.onTypeFormattingEditProvider.ordered(O);return Qe.length===0||Qe[0].autoFormatTriggerCharacters.indexOf(oe)<0?Promise.resolve(void 0):Promise.resolve(Qe[0].provideOnTypeFormattingEdits(O,te,oe,ue,E)).catch($.M_).then(Ke=>N.computeMoreMinimalEdits(O.uri,Ke))}m.wb.registerCommand("_executeFormatRangeProvider",function(N,...G){return x(this,void 0,void 0,function*(){const[O,te,oe]=G;(0,P.j)(B.r.isUri(O)),(0,P.j)(g.Q.isIRange(te));const ue=N.get(u.b),E=N.get(l.w),Qe=N.get(D.u),Ke=yield ue.createModelReference(O);try{return R(E,Qe,Ke.object.textEditorModel,g.Q.lift(te),oe,K.X.None)}finally{Ke.dispose()}})}),m.wb.registerCommand("_executeFormatDocumentProvider",function(N,...G){return x(this,void 0,void 0,function*(){const[O,te]=G;(0,P.j)(B.r.isUri(O));const oe=N.get(u.b),ue=N.get(l.w),E=N.get(D.u),Qe=yield oe.createModelReference(O);try{return H(ue,E,Qe.object.textEditorModel,te,K.X.None)}finally{Qe.dispose()}})}),m.wb.registerCommand("_executeFormatOnTypeProvider",function(N,...G){return x(this,void 0,void 0,function*(){const[O,te,oe,ue]=G;(0,P.j)(B.r.isUri(O)),(0,P.j)(d.y.isIPosition(te)),(0,P.j)(typeof oe=="string");const E=N.get(u.b),Qe=N.get(l.w),Ke=N.get(D.u),Se=yield E.createModelReference(O);try{return Z(Qe,Ke,Se.object.textEditorModel,d.y.lift(te),oe,ue,K.X.None)}finally{Se.dispose()}})})},38803:(rt,ye,y)=>{y.d(ye,{$D:()=>o,I_:()=>$,To:()=>K,Ym:()=>L});var b=y(82399);const o=(0,b.u1)("undoRedoService");class K{constructor(P,B){this.resource=P,this.elements=B}}class ${constructor(){this.id=$._ID++,this.order=1}nextOrder(){return this.id===0?0:this.order++}}$._ID=0,$.None=new $;class L{constructor(){this.id=L._ID++,this.order=1}nextOrder(){return this.id===0?0:this.order++}}L._ID=0,L.None=new L},39587:(rt,ye,y)=>{y.d(ye,{M:()=>K,t:()=>o});var b=y(53720);const o={RESOURCES:"ResourceURLs",DOWNLOAD_URL:"DownloadURL",FILES:"Files",TEXT:b.K.text},K={CurrentDragAndDropData:void 0}},39619:(rt,ye,y)=>{y.d(ye,{QB:()=>P,ZU:()=>o,h$:()=>$,p:()=>L,z5:()=>B});var b=y(94327);function o(T,p){if(T===0)return null;const d=(T&65535)>>>0,g=(T&4294901760)>>>16;return g!==0?new L([K(d,p),K(g,p)]):new L([K(d,p)])}function K(T,p){const d=!!(T&2048),g=!!(T&256),h=p===2?g:d,l=!!(T&1024),u=!!(T&512),w=p===2?d:g,C=T&255;return new $(h,l,u,w,C)}class ${constructor(p,d,g,h,l){this.ctrlKey=p,this.shiftKey=d,this.altKey=g,this.metaKey=h,this.keyCode=l}equals(p){return this.ctrlKey===p.ctrlKey&&this.shiftKey===p.shiftKey&&this.altKey===p.altKey&&this.metaKey===p.metaKey&&this.keyCode===p.keyCode}isModifierKey(){return this.keyCode===0||this.keyCode===5||this.keyCode===57||this.keyCode===6||this.keyCode===4}toChord(){return new L([this])}isDuplicateModifierCase(){return this.ctrlKey&&this.keyCode===5||this.shiftKey&&this.keyCode===4||this.altKey&&this.keyCode===6||this.metaKey&&this.keyCode===57}}class L{constructor(p){if(p.length===0)throw(0,b.Qg)("parts");this.parts=p}}class U{constructor(p,d,g,h,l){this.ctrlKey=p,this.shiftKey=d,this.altKey=g,this.metaKey=h,this.scanCode=l}isDuplicateModifierCase(){return this.ctrlKey&&(this.scanCode===157||this.scanCode===161)||this.shiftKey&&(this.scanCode===158||this.scanCode===162)||this.altKey&&(this.scanCode===159||this.scanCode===163)||this.metaKey&&(this.scanCode===160||this.scanCode===164)}}class P{constructor(p,d,g,h,l,u){this.ctrlKey=p,this.shiftKey=d,this.altKey=g,this.metaKey=h,this.keyLabel=l,this.keyAriaLabel=u}}class B{}},39723:(rt,ye,y)=>{y.d(ye,{wZ:()=>P,MT:()=>L,zL:()=>U,UW:()=>p,Md:()=>g});var b=y(16844),o=y(54324),K=y(45561);class ${constructor(W,Y,ne,j){this.endIndex=W,this.type=Y,this.metadata=ne,this.containsRTL=j,this._linePartBrand=void 0}isWhitespace(){return!!(this.metadata&1)}isPseudoAfter(){return!!(this.metadata&4)}}class L{constructor(W,Y){this.startOffset=W,this.endOffset=Y}equals(W){return this.startOffset===W.startOffset&&this.endOffset===W.endOffset}}class U{constructor(W,Y,ne,j,Q,X,R,H,Z,N,G,O,te,oe,ue,E,Qe,Ke,Se){this.useMonospaceOptimizations=W,this.canUseHalfwidthRightwardsArrow=Y,this.lineContent=ne,this.continuesWithWrappedLine=j,this.isBasicASCII=Q,this.containsRTL=X,this.fauxIndentLength=R,this.lineTokens=H,this.lineDecorations=Z.sort(K.d.compare),this.tabSize=N,this.startVisibleColumn=G,this.spaceWidth=O,this.stopRenderingLineAfter=ue,this.renderWhitespace=E==="all"?4:E==="boundary"?1:E==="selection"?2:E==="trailing"?3:0,this.renderControlCharacters=Qe,this.fontLigatures=Ke,this.selectionsOnLine=Se&&Se.sort((pe,be)=>pe.startOffset<be.startOffset?-1:1);const Me=Math.abs(oe-O),ce=Math.abs(te-O);Me<ce?(this.renderSpaceWidth=oe,this.renderSpaceCharCode=11825):(this.renderSpaceWidth=te,this.renderSpaceCharCode=183)}sameSelection(W){if(this.selectionsOnLine===null)return W===null;if(W===null||W.length!==this.selectionsOnLine.length)return!1;for(let Y=0;Y<this.selectionsOnLine.length;Y++)if(!this.selectionsOnLine[Y].equals(W[Y]))return!1;return!0}equals(W){return this.useMonospaceOptimizations===W.useMonospaceOptimizations&&this.canUseHalfwidthRightwardsArrow===W.canUseHalfwidthRightwardsArrow&&this.lineContent===W.lineContent&&this.continuesWithWrappedLine===W.continuesWithWrappedLine&&this.isBasicASCII===W.isBasicASCII&&this.containsRTL===W.containsRTL&&this.fauxIndentLength===W.fauxIndentLength&&this.tabSize===W.tabSize&&this.startVisibleColumn===W.startVisibleColumn&&this.spaceWidth===W.spaceWidth&&this.renderSpaceWidth===W.renderSpaceWidth&&this.renderSpaceCharCode===W.renderSpaceCharCode&&this.stopRenderingLineAfter===W.stopRenderingLineAfter&&this.renderWhitespace===W.renderWhitespace&&this.renderControlCharacters===W.renderControlCharacters&&this.fontLigatures===W.fontLigatures&&K.d.equalsArr(this.lineDecorations,W.lineDecorations)&&this.lineTokens.equals(W.lineTokens)&&this.sameSelection(W.selectionsOnLine)}}class P{constructor(W,Y){this.partIndex=W,this.charIndex=Y}}class B{constructor(W,Y){this.length=W,this._data=new Uint32Array(this.length),this._horizontalOffset=new Uint32Array(this.length)}static getPartIndex(W){return(W&4294901760)>>>16}static getCharIndex(W){return(W&65535)>>>0}setColumnInfo(W,Y,ne,j){const Q=(Y<<16|ne<<0)>>>0;this._data[W-1]=Q,this._horizontalOffset[W-1]=j}getHorizontalOffset(W){return this._horizontalOffset.length===0?0:this._horizontalOffset[W-1]}charOffsetToPartData(W){return this.length===0?0:W<0?this._data[0]:W>=this.length?this._data[this.length-1]:this._data[W]}getDomPosition(W){const Y=this.charOffsetToPartData(W-1),ne=B.getPartIndex(Y),j=B.getCharIndex(Y);return new P(ne,j)}getColumn(W,Y){return this.partDataToCharOffset(W.partIndex,Y,W.charIndex)+1}partDataToCharOffset(W,Y,ne){if(this.length===0)return 0;const j=(W<<16|ne<<0)>>>0;let Q=0,X=this.length-1;for(;Q+1<X;){const ue=Q+X>>>1,E=this._data[ue];if(E===j)return ue;E>j?X=ue:Q=ue}if(Q===X)return Q;const R=this._data[Q],H=this._data[X];if(R===j)return Q;if(H===j)return X;const Z=B.getPartIndex(R),N=B.getCharIndex(R),G=B.getPartIndex(H);let O;Z!==G?O=Y:O=B.getCharIndex(H);const te=ne-N,oe=O-ne;return te<=oe?Q:X}}class T{constructor(W,Y,ne){this._renderLineOutputBrand=void 0,this.characterMapping=W,this.containsRTL=Y,this.containsForeignElements=ne}}function p(A,W){if(A.lineContent.length===0){if(A.lineDecorations.length>0){W.appendASCIIString("<span>");let Y=0,ne=0,j=0;for(const X of A.lineDecorations)(X.type===1||X.type===2)&&(W.appendASCIIString('<span class="'),W.appendASCIIString(X.className),W.appendASCIIString('"></span>'),X.type===1&&(j|=1,Y++),X.type===2&&(j|=2,ne++));W.appendASCIIString("</span>");const Q=new B(1,Y+ne);return Q.setColumnInfo(1,Y,0,0),new T(Q,!1,j)}return W.appendASCIIString("<span><span></span></span>"),new T(new B(0,0),!1,0)}return D(l(A),W)}class d{constructor(W,Y,ne,j){this.characterMapping=W,this.html=Y,this.containsRTL=ne,this.containsForeignElements=j}}function g(A){const W=(0,o.Du)(1e4),Y=p(A,W);return new d(Y.characterMapping,W.build(),Y.containsRTL,Y.containsForeignElements)}class h{constructor(W,Y,ne,j,Q,X,R,H,Z,N,G,O,te,oe,ue){this.fontIsMonospace=W,this.canUseHalfwidthRightwardsArrow=Y,this.lineContent=ne,this.len=j,this.isOverflowing=Q,this.parts=X,this.containsForeignElements=R,this.fauxIndentLength=H,this.tabSize=Z,this.startVisibleColumn=N,this.containsRTL=G,this.spaceWidth=O,this.renderSpaceCharCode=te,this.renderWhitespace=oe,this.renderControlCharacters=ue}}function l(A){const W=A.lineContent;let Y,ne;A.stopRenderingLineAfter!==-1&&A.stopRenderingLineAfter<W.length?(Y=!0,ne=A.stopRenderingLineAfter):(Y=!1,ne=W.length);let j=u(W,A.containsRTL,A.lineTokens,A.fauxIndentLength,ne);A.renderControlCharacters&&!A.isBasicASCII&&(j=m(W,j)),(A.renderWhitespace===4||A.renderWhitespace===1||A.renderWhitespace===2&&A.selectionsOnLine||A.renderWhitespace===3)&&(j=v(A,W,ne,j));let Q=0;if(A.lineDecorations.length>0){for(let X=0,R=A.lineDecorations.length;X<R;X++){const H=A.lineDecorations[X];H.type===3||H.type===1?Q|=1:H.type===2&&(Q|=2)}j=k(W,ne,j,A.lineDecorations)}return A.containsRTL||(j=w(W,j,!A.isBasicASCII||A.fontLigatures)),new h(A.useMonospaceOptimizations,A.canUseHalfwidthRightwardsArrow,W,ne,Y,j,Q,A.fauxIndentLength,A.tabSize,A.startVisibleColumn,A.containsRTL,A.spaceWidth,A.renderSpaceCharCode,A.renderWhitespace,A.renderControlCharacters)}function u(A,W,Y,ne,j){const Q=[];let X=0;ne>0&&(Q[X++]=new $(ne,"",0,!1));let R=ne;for(let H=0,Z=Y.getCount();H<Z;H++){const N=Y.getEndOffset(H);if(N<=ne)continue;const G=Y.getClassName(H);if(N>=j){const te=W?b.E_(A.substring(R,j)):!1;Q[X++]=new $(j,G,0,te);break}const O=W?b.E_(A.substring(R,N)):!1;Q[X++]=new $(N,G,0,O),R=N}return Q}function w(A,W,Y){let ne=0;const j=[];let Q=0;if(Y)for(let X=0,R=W.length;X<R;X++){const H=W[X],Z=H.endIndex;if(ne+50<Z){const N=H.type,G=H.metadata,O=H.containsRTL;let te=-1,oe=ne;for(let ue=ne;ue<Z;ue++)A.charCodeAt(ue)===32&&(te=ue),te!==-1&&ue-oe>=50&&(j[Q++]=new $(te+1,N,G,O),oe=te+1,te=-1);oe!==Z&&(j[Q++]=new $(Z,N,G,O))}else j[Q++]=H;ne=Z}else for(let X=0,R=W.length;X<R;X++){const H=W[X],Z=H.endIndex,N=Z-ne;if(N>50){const G=H.type,O=H.metadata,te=H.containsRTL,oe=Math.ceil(N/50);for(let ue=1;ue<oe;ue++){const E=ne+ue*50;j[Q++]=new $(E,G,O,te)}j[Q++]=new $(Z,G,O,te)}else j[Q++]=H;ne=Z}return j}function C(A){return A<32?A!==9:A===127||A>=8234&&A<=8238||A>=8294&&A<=8297||A>=8206&&A<=8207||A===1564}function m(A,W){const Y=[];let ne=new $(0,"",0,!1),j=0;for(const Q of W){const X=Q.endIndex;for(;j<X;j++){const R=A.charCodeAt(j);C(R)&&(j>ne.endIndex&&(ne=new $(j,Q.type,Q.metadata,Q.containsRTL),Y.push(ne)),ne=new $(j+1,"mtkcontrol",Q.metadata,!1),Y.push(ne))}j>ne.endIndex&&(ne=new $(X,Q.type,Q.metadata,Q.containsRTL),Y.push(ne))}return Y}function v(A,W,Y,ne){const j=A.continuesWithWrappedLine,Q=A.fauxIndentLength,X=A.tabSize,R=A.startVisibleColumn,H=A.useMonospaceOptimizations,Z=A.selectionsOnLine,N=A.renderWhitespace===1,G=A.renderWhitespace===3,O=A.renderSpaceWidth!==A.spaceWidth,te=[];let oe=0,ue=0,E=ne[ue].type,Qe=ne[ue].containsRTL,Ke=ne[ue].endIndex;const Se=ne.length;let Me=!1,ce=b.HG(W),pe;ce===-1?(Me=!0,ce=Y,pe=Y):pe=b.lT(W);let be=!1,ge=0,ke=Z&&Z[ge],We=R%X;for(let Ae=Q;Ae<Y;Ae++){const he=W.charCodeAt(Ae);ke&&Ae>=ke.endOffset&&(ge++,ke=Z&&Z[ge]);let Pe;if(Ae<ce||Ae>pe)Pe=!0;else if(he===9)Pe=!0;else if(he===32)if(N)if(be)Pe=!0;else{const $e=Ae+1<Y?W.charCodeAt(Ae+1):0;Pe=$e===32||$e===9}else Pe=!0;else Pe=!1;if(Pe&&Z&&(Pe=!!ke&&ke.startOffset<=Ae&&ke.endOffset>Ae),Pe&&G&&(Pe=Me||Ae>pe),Pe&&Qe&&Ae>=ce&&Ae<=pe&&(Pe=!1),be){if(!Pe||!H&&We>=X){if(O){const $e=oe>0?te[oe-1].endIndex:Q;for(let it=$e+1;it<=Ae;it++)te[oe++]=new $(it,"mtkw",1,!1)}else te[oe++]=new $(Ae,"mtkw",1,!1);We=We%X}}else(Ae===Ke||Pe&&Ae>Q)&&(te[oe++]=new $(Ae,E,0,Qe),We=We%X);for(he===9?We=X:b.ne(he)?We+=2:We++,be=Pe;Ae===Ke&&(ue++,ue<Se);)E=ne[ue].type,Qe=ne[ue].containsRTL,Ke=ne[ue].endIndex}let Ge=!1;if(be)if(j&&N){const Ae=Y>0?W.charCodeAt(Y-1):0,he=Y>1?W.charCodeAt(Y-2):0;Ae===32&&he!==32&&he!==9||(Ge=!0)}else Ge=!0;if(Ge)if(O){const Ae=oe>0?te[oe-1].endIndex:Q;for(let he=Ae+1;he<=Y;he++)te[oe++]=new $(he,"mtkw",1,!1)}else te[oe++]=new $(Y,"mtkw",1,!1);else te[oe++]=new $(Y,E,0,Qe);return te}function k(A,W,Y,ne){ne.sort(K.d.compare);const j=K.Bs.normalize(A,ne),Q=j.length;let X=0;const R=[];let H=0,Z=0;for(let G=0,O=Y.length;G<O;G++){const te=Y[G],oe=te.endIndex,ue=te.type,E=te.metadata,Qe=te.containsRTL;for(;X<Q&&j[X].startOffset<oe;){const Ke=j[X];if(Ke.startOffset>Z&&(Z=Ke.startOffset,R[H++]=new $(Z,ue,E,Qe)),Ke.endOffset+1<=oe)Z=Ke.endOffset+1,R[H++]=new $(Z,ue+" "+Ke.className,E|Ke.metadata,Qe),X++;else{Z=oe,R[H++]=new $(Z,ue+" "+Ke.className,E|Ke.metadata,Qe);break}}oe>Z&&(Z=oe,R[H++]=new $(Z,ue,E,Qe))}const N=Y[Y.length-1].endIndex;if(X<Q&&j[X].startOffset===N)for(;X<Q&&j[X].startOffset===N;){const G=j[X];R[H++]=new $(Z,G.className,G.metadata,!1),X++}return R}function D(A,W){const Y=A.fontIsMonospace,ne=A.canUseHalfwidthRightwardsArrow,j=A.containsForeignElements,Q=A.lineContent,X=A.len,R=A.isOverflowing,H=A.parts,Z=A.fauxIndentLength,N=A.tabSize,G=A.startVisibleColumn,O=A.containsRTL,te=A.spaceWidth,oe=A.renderSpaceCharCode,ue=A.renderWhitespace,E=A.renderControlCharacters,Qe=new B(X+1,H.length);let Ke=!1,Se=0,Me=G,ce=0,pe=0,be=0;O?W.appendASCIIString('<span dir="ltr">'):W.appendASCIIString("<span>");for(let ge=0,ke=H.length;ge<ke;ge++){const We=H[ge],Ge=We.endIndex,Ae=We.type,he=We.containsRTL,Pe=ue!==0&&We.isWhitespace(),$e=Pe&&!Y&&(Ae==="mtkw"||!j),it=Se===Ge&&We.isPseudoAfter();if(ce=0,W.appendASCIIString("<span "),he&&W.appendASCIIString('style="unicode-bidi:isolate" '),W.appendASCIIString('class="'),W.appendASCIIString($e?"mtkz":Ae),W.appendASCII(34),Pe){let ft=0;{let Wt=Se,tt=Me;for(;Wt<Ge;Wt++){const ht=(Q.charCodeAt(Wt)===9?N-tt%N:1)|0;ft+=ht,Wt>=Z&&(tt+=ht)}}for($e&&(W.appendASCIIString(' style="width:'),W.appendASCIIString(String(te*ft)),W.appendASCIIString('px"')),W.appendASCII(62);Se<Ge;Se++){Qe.setColumnInfo(Se+1,ge-be,ce,pe),be=0;const Wt=Q.charCodeAt(Se);let tt,Ye;if(Wt===9){tt=N-Me%N|0,Ye=tt,!ne||Ye>1?W.write1(8594):W.write1(65515);for(let ht=2;ht<=Ye;ht++)W.write1(160)}else tt=2,Ye=1,W.write1(oe),W.write1(8204);ce+=tt,pe+=Ye,Se>=Z&&(Me+=Ye)}}else for(W.appendASCII(62);Se<Ge;Se++){Qe.setColumnInfo(Se+1,ge-be,ce,pe),be=0;const ft=Q.charCodeAt(Se);let Wt=1,tt=1;switch(ft){case 9:Wt=N-Me%N,tt=Wt;for(let Ye=1;Ye<=Wt;Ye++)W.write1(160);break;case 32:W.write1(160);break;case 60:W.appendASCIIString("<");break;case 62:W.appendASCIIString(">");break;case 38:W.appendASCIIString("&");break;case 0:E?W.write1(9216):W.appendASCIIString("�");break;case 65279:case 8232:case 8233:case 133:W.write1(65533);break;default:b.ne(ft)&&tt++,E&&ft<32?W.write1(9216+ft):E&&ft===127?W.write1(9249):E&&C(ft)?(W.appendASCIIString("[U+"),W.appendASCIIString(x(ft)),W.appendASCIIString("]"),Wt=8,tt=Wt):W.write1(ft)}ce+=Wt,pe+=tt,Se>=Z&&(Me+=tt)}it?be++:be=0,Se>=X&&!Ke&&We.isPseudoAfter()&&(Ke=!0,Qe.setColumnInfo(Se+1,ge,ce,pe)),W.appendASCIIString("</span>")}return Ke||Qe.setColumnInfo(X+1,H.length-1,ce,pe),R&&W.appendASCIIString("<span>…</span>"),W.appendASCIIString("</span>"),new T(Qe,O,j)}function x(A){return A.toString(16).toUpperCase().padStart(4,"0")}},40931:(rt,ye,y)=>{y.d(ye,{JW:()=>G,r8:()=>O,rT:()=>te});var b=y(2106),o=y(10998),K=y(63339),$=y(94327),L=y(59922),U=y(12590),P=y(54957),B=y(77922),T=y(64830),p=y(41504),d=y(85753),g=y(65958),h=y(78903),l=y(89044),u=y(46441),w=y(38803),C=y(22344),m=y(54296),v=y(13072),k=y(9520),D=y(52677),x=y(71386),A=y(52394),W=y(12060),Y=y(23013),ne=y(52230),j=function(Ke,Se,Me,ce){var pe=arguments.length,be=pe<3?Se:ce===null?ce=Object.getOwnPropertyDescriptor(Se,Me):ce,ge;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")be=Reflect.decorate(Ke,Se,Me,ce);else for(var ke=Ke.length-1;ke>=0;ke--)(ge=Ke[ke])&&(be=(pe<3?ge(be):pe>3?ge(Se,Me,be):ge(Se,Me))||be);return pe>3&&be&&Object.defineProperty(Se,Me,be),be},Q=function(Ke,Se){return function(Me,ce){Se(Me,ce,Ke)}};function X(Ke){return Ke.toString()}function R(Ke){const Se=new C.v7,Me=Ke.createSnapshot();let ce;for(;ce=Me.read();)Se.update(ce);return Se.digest()}class H{constructor(Se,Me,ce){this._modelEventListeners=new o.Cm,this.model=Se,this._languageSelection=null,this._languageSelectionListener=null,this._modelEventListeners.add(Se.onWillDispose(()=>Me(Se))),this._modelEventListeners.add(Se.onDidChangeLanguage(pe=>ce(Se,pe)))}_disposeLanguageSelection(){this._languageSelectionListener&&(this._languageSelectionListener.dispose(),this._languageSelectionListener=null)}dispose(){this._modelEventListeners.dispose(),this._disposeLanguageSelection()}setLanguage(Se){this._disposeLanguageSelection(),this._languageSelection=Se,this._languageSelectionListener=this._languageSelection.onDidChange(()=>this.model.setMode(Se.languageId)),this.model.setMode(Se.languageId)}}const Z=K.j9||K.zx?1:2;class N{constructor(Se,Me,ce,pe,be,ge,ke,We){this.uri=Se,this.initialUndoRedoSnapshot=Me,this.time=ce,this.sharesUndoRedoStack=pe,this.heapSize=be,this.sha1=ge,this.versionId=ke,this.alternativeVersionId=We}}let G=class gr extends o.jG{constructor(Se,Me,ce,pe,be,ge,ke,We,Ge){super(),this._configurationService=Se,this._resourcePropertiesService=Me,this._themeService=ce,this._logService=pe,this._undoRedoService=be,this._languageService=ge,this._languageConfigurationService=ke,this._languageFeatureDebounceService=We,this._onModelAdded=this._register(new b.vl),this.onModelAdded=this._onModelAdded.event,this._onModelRemoved=this._register(new b.vl),this.onModelRemoved=this._onModelRemoved.event,this._onModelModeChanged=this._register(new b.vl),this.onModelLanguageChanged=this._onModelModeChanged.event,this._modelCreationOptionsByLanguageAndResource=Object.create(null),this._models={},this._disposedModels=new Map,this._disposedModelsHeapSize=0,this._semanticStyling=this._register(new ue(this._themeService,this._languageService,this._logService)),this._register(this._configurationService.onDidChangeConfiguration(()=>this._updateModelOptions())),this._updateModelOptions(),this._register(new oe(this._semanticStyling,this,this._themeService,this._configurationService,this._languageFeatureDebounceService,Ge))}static _readModelOptions(Se,Me){var ce;let pe=U.R.tabSize;if(Se.editor&&typeof Se.editor.tabSize<"u"){const $e=parseInt(Se.editor.tabSize,10);isNaN($e)||(pe=$e),pe<1&&(pe=1)}let be=pe;if(Se.editor&&typeof Se.editor.indentSize<"u"&&Se.editor.indentSize!=="tabSize"){const $e=parseInt(Se.editor.indentSize,10);isNaN($e)||(be=$e),be<1&&(be=1)}let ge=U.R.insertSpaces;Se.editor&&typeof Se.editor.insertSpaces<"u"&&(ge=Se.editor.insertSpaces==="false"?!1:!!Se.editor.insertSpaces);let ke=Z;const We=Se.eol;We===`\r `?ke=2:We===` `&&(ke=1);let Ge=U.R.trimAutoWhitespace;Se.editor&&typeof Se.editor.trimAutoWhitespace<"u"&&(Ge=Se.editor.trimAutoWhitespace==="false"?!1:!!Se.editor.trimAutoWhitespace);let Ae=U.R.detectIndentation;Se.editor&&typeof Se.editor.detectIndentation<"u"&&(Ae=Se.editor.detectIndentation==="false"?!1:!!Se.editor.detectIndentation);let he=U.R.largeFileOptimizations;Se.editor&&typeof Se.editor.largeFileOptimizations<"u"&&(he=Se.editor.largeFileOptimizations==="false"?!1:!!Se.editor.largeFileOptimizations);let Pe=U.R.bracketPairColorizationOptions;return!((ce=Se.editor)===null||ce===void 0)&&ce.bracketPairColorization&&typeof Se.editor.bracketPairColorization=="object"&&(Pe={enabled:!!Se.editor.bracketPairColorization.enabled,independentColorPoolPerBracketType:!!Se.editor.bracketPairColorization.independentColorPoolPerBracketType}),{isForSimpleWidget:Me,tabSize:pe,indentSize:be,insertSpaces:ge,detectIndentation:Ae,defaultEOL:ke,trimAutoWhitespace:Ge,largeFileOptimizations:he,bracketPairColorizationOptions:Pe}}_getEOL(Se,Me){if(Se)return this._resourcePropertiesService.getEOL(Se,Me);const ce=this._configurationService.getValue("files.eol",{overrideIdentifier:Me});return ce&&typeof ce=="string"&&ce!=="auto"?ce:K.OS===3||K.OS===2?` `:`\r `}_shouldRestoreUndoStack(){const Se=this._configurationService.getValue("files.restoreUndoStack");return typeof Se=="boolean"?Se:!0}getCreationOptions(Se,Me,ce){let pe=this._modelCreationOptionsByLanguageAndResource[Se+Me];if(!pe){const be=this._configurationService.getValue("editor",{overrideIdentifier:Se,resource:Me}),ge=this._getEOL(Me,Se);pe=gr._readModelOptions({editor:be,eol:ge},ce),this._modelCreationOptionsByLanguageAndResource[Se+Me]=pe}return pe}_updateModelOptions(){const Se=this._modelCreationOptionsByLanguageAndResource;this._modelCreationOptionsByLanguageAndResource=Object.create(null);const Me=Object.keys(this._models);for(let ce=0,pe=Me.length;ce<pe;ce++){const be=Me[ce],ge=this._models[be],ke=ge.model.getLanguageId(),We=ge.model.uri,Ge=Se[ke+We],Ae=this.getCreationOptions(ke,We,ge.model.isForSimpleWidget);gr._setModelOptionsForModel(ge.model,Ae,Ge)}}static _setModelOptionsForModel(Se,Me,ce){ce&&ce.defaultEOL!==Me.defaultEOL&&Se.getLineCount()===1&&Se.setEOL(Me.defaultEOL===1?0:1),!(ce&&ce.detectIndentation===Me.detectIndentation&&ce.insertSpaces===Me.insertSpaces&&ce.tabSize===Me.tabSize&&ce.indentSize===Me.indentSize&&ce.trimAutoWhitespace===Me.trimAutoWhitespace&&(0,x.aI)(ce.bracketPairColorizationOptions,Me.bracketPairColorizationOptions))&&(Me.detectIndentation?(Se.detectIndentation(Me.insertSpaces,Me.tabSize),Se.updateOptions({trimAutoWhitespace:Me.trimAutoWhitespace,bracketColorizationOptions:Me.bracketPairColorizationOptions})):Se.updateOptions({insertSpaces:Me.insertSpaces,tabSize:Me.tabSize,indentSize:Me.indentSize,trimAutoWhitespace:Me.trimAutoWhitespace,bracketColorizationOptions:Me.bracketPairColorizationOptions}))}_insertDisposedModel(Se){this._disposedModels.set(X(Se.uri),Se),this._disposedModelsHeapSize+=Se.heapSize}_removeDisposedModel(Se){const Me=this._disposedModels.get(X(Se));return Me&&(this._disposedModelsHeapSize-=Me.heapSize),this._disposedModels.delete(X(Se)),Me}_ensureDisposedModelsHeapSize(Se){if(this._disposedModelsHeapSize>Se){const Me=[];for(this._disposedModels.forEach(ce=>{ce.sharesUndoRedoStack||Me.push(ce)}),Me.sort((ce,pe)=>ce.time-pe.time);Me.length>0&&this._disposedModelsHeapSize>Se;){const ce=Me.shift();this._removeDisposedModel(ce.uri),ce.initialUndoRedoSnapshot!==null&&this._undoRedoService.restoreSnapshot(ce.initialUndoRedoSnapshot)}}}_createModelData(Se,Me,ce,pe){const be=this.getCreationOptions(Me,ce,pe),ge=new L.Bz(Se,Me,be,ce,this._undoRedoService,this._languageService,this._languageConfigurationService);if(ce&&this._disposedModels.has(X(ce))){const Ge=this._removeDisposedModel(ce),Ae=this._undoRedoService.getElements(ce),he=R(ge)===Ge.sha1;if(he||Ge.sharesUndoRedoStack){for(const Pe of Ae.past)(0,m.Th)(Pe)&&Pe.matchesResource(ce)&&Pe.setModel(ge);for(const Pe of Ae.future)(0,m.Th)(Pe)&&Pe.matchesResource(ce)&&Pe.setModel(ge);this._undoRedoService.setElementsValidFlag(ce,!0,Pe=>(0,m.Th)(Pe)&&Pe.matchesResource(ce)),he&&(ge._overwriteVersionId(Ge.versionId),ge._overwriteAlternativeVersionId(Ge.alternativeVersionId),ge._overwriteInitialUndoRedoSnapshot(Ge.initialUndoRedoSnapshot))}else Ge.initialUndoRedoSnapshot!==null&&this._undoRedoService.restoreSnapshot(Ge.initialUndoRedoSnapshot)}const ke=X(ge.uri);if(this._models[ke])throw new Error("ModelService: Cannot add model because it already exists!");const We=new H(ge,Ge=>this._onWillDispose(Ge),(Ge,Ae)=>this._onDidChangeLanguage(Ge,Ae));return this._models[ke]=We,We}createModel(Se,Me,ce,pe=!1){let be;return Me?(be=this._createModelData(Se,Me.languageId,ce,pe),this.setMode(be.model,Me)):be=this._createModelData(Se,P.vH,ce,pe),this._onModelAdded.fire(be.model),be.model}setMode(Se,Me){if(!Me)return;const ce=this._models[X(Se.uri)];ce&&ce.setLanguage(Me)}getModels(){const Se=[],Me=Object.keys(this._models);for(let ce=0,pe=Me.length;ce<pe;ce++){const be=Me[ce];Se.push(this._models[be].model)}return Se}getModel(Se){const Me=X(Se),ce=this._models[Me];return ce?ce.model:null}getSemanticTokensProviderStyling(Se){return this._semanticStyling.get(Se)}_schemaShouldMaintainUndoRedoElements(Se){return Se.scheme===v.ny.file||Se.scheme===v.ny.vscodeRemote||Se.scheme===v.ny.vscodeUserData||Se.scheme===v.ny.vscodeNotebookCell||Se.scheme==="fake-fs"}_onWillDispose(Se){const Me=X(Se.uri),ce=this._models[Me],pe=this._undoRedoService.getUriComparisonKey(Se.uri)!==Se.uri.toString();let be=!1,ge=0;if(pe||this._shouldRestoreUndoStack()&&this._schemaShouldMaintainUndoRedoElements(Se.uri)){const We=this._undoRedoService.getElements(Se.uri);if(We.past.length>0||We.future.length>0){for(const Ge of We.past)(0,m.Th)(Ge)&&Ge.matchesResource(Se.uri)&&(be=!0,ge+=Ge.heapSize(Se.uri),Ge.setModel(Se.uri));for(const Ge of We.future)(0,m.Th)(Ge)&&Ge.matchesResource(Se.uri)&&(be=!0,ge+=Ge.heapSize(Se.uri),Ge.setModel(Se.uri))}}const ke=gr.MAX_MEMORY_FOR_CLOSED_FILES_UNDO_STACK;if(be)if(!pe&&ge>ke){const We=ce.model.getInitialUndoRedoSnapshot();We!==null&&this._undoRedoService.restoreSnapshot(We)}else this._ensureDisposedModelsHeapSize(ke-ge),this._undoRedoService.setElementsValidFlag(Se.uri,!1,We=>(0,m.Th)(We)&&We.matchesResource(Se.uri)),this._insertDisposedModel(new N(Se.uri,ce.model.getInitialUndoRedoSnapshot(),Date.now(),pe,ge,R(Se),Se.getVersionId(),Se.getAlternativeVersionId()));else if(!pe){const We=ce.model.getInitialUndoRedoSnapshot();We!==null&&this._undoRedoService.restoreSnapshot(We)}delete this._models[Me],ce.dispose(),delete this._modelCreationOptionsByLanguageAndResource[Se.getLanguageId()+Se.uri],this._onModelRemoved.fire(Se)}_onDidChangeLanguage(Se,Me){const ce=Me.oldLanguage,pe=Se.getLanguageId(),be=this.getCreationOptions(ce,Se.uri,Se.isForSimpleWidget),ge=this.getCreationOptions(pe,Se.uri,Se.isForSimpleWidget);gr._setModelOptionsForModel(Se,ge,be),this._onModelModeChanged.fire({model:Se,oldLanguageId:ce})}};G.MAX_MEMORY_FOR_CLOSED_FILES_UNDO_STACK=20*1024*1024,G=j([Q(0,d.pG),Q(1,p.J),Q(2,l.Gy),Q(3,u.rr),Q(4,w.$D),Q(5,B.L),Q(6,A.JZ),Q(7,W.U),Q(8,ne.u)],G);const O="editor.semanticHighlighting";function te(Ke,Se,Me){var ce;const pe=(ce=Me.getValue(O,{overrideIdentifier:Ke.getLanguageId(),resource:Ke.uri}))===null||ce===void 0?void 0:ce.enabled;return typeof pe=="boolean"?pe:Se.getColorTheme().semanticHighlighting}let oe=class extends o.jG{constructor(Se,Me,ce,pe,be,ge){super(),this._watchers=Object.create(null),this._semanticStyling=Se;const ke=Ae=>{this._watchers[Ae.uri.toString()]=new Qe(Ae,this._semanticStyling,ce,be,ge)},We=(Ae,he)=>{he.dispose(),delete this._watchers[Ae.uri.toString()]},Ge=()=>{for(const Ae of Me.getModels()){const he=this._watchers[Ae.uri.toString()];te(Ae,ce,pe)?he||ke(Ae):he&&We(Ae,he)}};this._register(Me.onModelAdded(Ae=>{te(Ae,ce,pe)&&ke(Ae)})),this._register(Me.onModelRemoved(Ae=>{const he=this._watchers[Ae.uri.toString()];he&&We(Ae,he)})),this._register(pe.onDidChangeConfiguration(Ae=>{Ae.affectsConfiguration(O)&&Ge()})),this._register(ce.onDidColorThemeChange(Ge))}dispose(){for(const Se of Object.values(this._watchers))Se.dispose();super.dispose()}};oe=j([Q(1,T.S),Q(2,l.Gy),Q(3,d.pG),Q(4,W.U),Q(5,ne.u)],oe);class ue extends o.jG{constructor(Se,Me,ce){super(),this._themeService=Se,this._languageService=Me,this._logService=ce,this._caches=new WeakMap,this._register(this._themeService.onDidColorThemeChange(()=>{this._caches=new WeakMap}))}get(Se){return this._caches.has(Se)||this._caches.set(Se,new k.i(Se.getLegend(),this._themeService,this._languageService,this._logService)),this._caches.get(Se)}}class E{constructor(Se,Me,ce){this.provider=Se,this.resultId=Me,this.data=ce}dispose(){this.provider.releaseDocumentSemanticTokens(this.resultId)}}let Qe=class mo extends o.jG{constructor(Se,Me,ce,pe,be){super(),this._isDisposed=!1,this._model=Se,this._semanticStyling=Me,this._provider=be.documentSemanticTokensProvider,this._debounceInformation=pe.for(this._provider,"DocumentSemanticTokens",{min:mo.REQUEST_MIN_DELAY,max:mo.REQUEST_MAX_DELAY}),this._fetchDocumentSemanticTokens=this._register(new g.uC(()=>this._fetchDocumentSemanticTokensNow(),mo.REQUEST_MIN_DELAY)),this._currentDocumentResponse=null,this._currentDocumentRequestCancellationTokenSource=null,this._documentProvidersChangeListeners=[],this._register(this._model.onDidChangeContent(()=>{this._fetchDocumentSemanticTokens.isScheduled()||this._fetchDocumentSemanticTokens.schedule(this._debounceInformation.get(this._model))})),this._register(this._model.onDidChangeLanguage(()=>{this._currentDocumentResponse&&(this._currentDocumentResponse.dispose(),this._currentDocumentResponse=null),this._currentDocumentRequestCancellationTokenSource&&(this._currentDocumentRequestCancellationTokenSource.cancel(),this._currentDocumentRequestCancellationTokenSource=null),this._setDocumentSemanticTokens(null,null,null,[]),this._fetchDocumentSemanticTokens.schedule(0)}));const ge=()=>{(0,o.AS)(this._documentProvidersChangeListeners),this._documentProvidersChangeListeners=[];for(const ke of this._provider.all(Se))typeof ke.onDidChange=="function"&&this._documentProvidersChangeListeners.push(ke.onDidChange(()=>this._fetchDocumentSemanticTokens.schedule(0)))};ge(),this._register(this._provider.onDidChange(()=>{ge(),this._fetchDocumentSemanticTokens.schedule(this._debounceInformation.get(this._model))})),this._register(ce.onDidColorThemeChange(ke=>{this._setDocumentSemanticTokens(null,null,null,[]),this._fetchDocumentSemanticTokens.schedule(this._debounceInformation.get(this._model))})),this._fetchDocumentSemanticTokens.schedule(0)}dispose(){this._currentDocumentResponse&&(this._currentDocumentResponse.dispose(),this._currentDocumentResponse=null),this._currentDocumentRequestCancellationTokenSource&&(this._currentDocumentRequestCancellationTokenSource.cancel(),this._currentDocumentRequestCancellationTokenSource=null),this._setDocumentSemanticTokens(null,null,null,[]),this._isDisposed=!0,super.dispose()}_fetchDocumentSemanticTokensNow(){if(this._currentDocumentRequestCancellationTokenSource)return;if(!(0,D.br)(this._provider,this._model)){this._currentDocumentResponse&&this._model.tokenization.setSemanticTokens(null,!1);return}const Se=new h.Q,Me=this._currentDocumentResponse?this._currentDocumentResponse.provider:null,ce=this._currentDocumentResponse&&this._currentDocumentResponse.resultId||null,pe=(0,D.aw)(this._provider,this._model,Me,ce,Se.token);this._currentDocumentRequestCancellationTokenSource=Se;const be=[],ge=this._model.onDidChangeContent(We=>{be.push(We)}),ke=new Y.W(!1);pe.then(We=>{if(this._debounceInformation.update(this._model,ke.elapsed()),this._currentDocumentRequestCancellationTokenSource=null,ge.dispose(),!We)this._setDocumentSemanticTokens(null,null,null,be);else{const{provider:Ge,tokens:Ae}=We,he=this._semanticStyling.get(Ge);this._setDocumentSemanticTokens(Ge,Ae||null,he,be)}},We=>{We&&($.MB(We)||typeof We.message=="string"&&We.message.indexOf("busy")!==-1)||$.dz(We),this._currentDocumentRequestCancellationTokenSource=null,ge.dispose(),be.length>0&&(this._fetchDocumentSemanticTokens.isScheduled()||this._fetchDocumentSemanticTokens.schedule(this._debounceInformation.get(this._model)))})}static _copy(Se,Me,ce,pe,be){be=Math.min(be,ce.length-pe,Se.length-Me);for(let ge=0;ge<be;ge++)ce[pe+ge]=Se[Me+ge]}_setDocumentSemanticTokens(Se,Me,ce,pe){const be=this._currentDocumentResponse,ge=()=>{pe.length>0&&!this._fetchDocumentSemanticTokens.isScheduled()&&this._fetchDocumentSemanticTokens.schedule(this._debounceInformation.get(this._model))};if(this._currentDocumentResponse&&(this._currentDocumentResponse.dispose(),this._currentDocumentResponse=null),this._isDisposed){Se&&Me&&Se.releaseDocumentSemanticTokens(Me.resultId);return}if(!Se||!ce){this._model.tokenization.setSemanticTokens(null,!1);return}if(!Me){this._model.tokenization.setSemanticTokens(null,!0),ge();return}if((0,D.yS)(Me)){if(!be){this._model.tokenization.setSemanticTokens(null,!0);return}if(Me.edits.length===0)Me={resultId:Me.resultId,data:be.data};else{let ke=0;for(const Pe of Me.edits)ke+=(Pe.data?Pe.data.length:0)-Pe.deleteCount;const We=be.data,Ge=new Uint32Array(We.length+ke);let Ae=We.length,he=Ge.length;for(let Pe=Me.edits.length-1;Pe>=0;Pe--){const $e=Me.edits[Pe];if($e.start>We.length){ce.warnInvalidEditStart(be.resultId,Me.resultId,Pe,$e.start,We.length),this._model.tokenization.setSemanticTokens(null,!0);return}const it=Ae-($e.start+$e.deleteCount);it>0&&(mo._copy(We,Ae-it,Ge,he-it,it),he-=it),$e.data&&(mo._copy($e.data,0,Ge,he-$e.data.length,$e.data.length),he-=$e.data.length),Ae=$e.start}Ae>0&&mo._copy(We,0,Ge,0,Ae),Me={resultId:Me.resultId,data:Ge}}}if((0,D.BB)(Me)){this._currentDocumentResponse=new E(Se,Me.resultId,Me.data);const ke=(0,k.b)(Me,ce,this._model.getLanguageId());if(pe.length>0)for(const We of pe)for(const Ge of ke)for(const Ae of We.changes)Ge.applyEdit(Ae.range,Ae.text);this._model.tokenization.setSemanticTokens(ke,!0)}else this._model.tokenization.setSemanticTokens(null,!0);ge()}};Qe.REQUEST_MIN_DELAY=300,Qe.REQUEST_MAX_DELAY=2e3,Qe=j([Q(2,l.Gy),Q(3,W.U),Q(4,ne.u)],Qe)},41106:(rt,ye,y)=>{y.d(ye,{T:()=>g});var b=y(55893),o=y(2106),K=y(10998),$=y(25837);class L{constructor(l,u){this.chr=l,this.type=u,this.width=0}fulfill(l){this.width=l}}class U{constructor(l,u){this._bareFontInfo=l,this._requests=u,this._container=null,this._testElements=null}read(){this._createDomElements(),document.body.appendChild(this._container),this._readFromDomElements(),document.body.removeChild(this._container),this._container=null,this._testElements=null}_createDomElements(){const l=document.createElement("div");l.style.position="absolute",l.style.top="-50000px",l.style.width="50000px";const u=document.createElement("div");(0,$.M)(u,this._bareFontInfo),l.appendChild(u);const w=document.createElement("div");(0,$.M)(w,this._bareFontInfo),w.style.fontWeight="bold",l.appendChild(w);const C=document.createElement("div");(0,$.M)(C,this._bareFontInfo),C.style.fontStyle="italic",l.appendChild(C);const m=[];for(const v of this._requests){let k;v.type===0&&(k=u),v.type===2&&(k=w),v.type===1&&(k=C),k.appendChild(document.createElement("br"));const D=document.createElement("span");U._render(D,v),k.appendChild(D),m.push(D)}this._container=l,this._testElements=m}static _render(l,u){if(u.chr===" "){let w="\xA0";for(let C=0;C<8;C++)w+=w;l.innerText=w}else{let w=u.chr;for(let C=0;C<8;C++)w+=w;l.textContent=w}}_readFromDomElements(){for(let l=0,u=this._requests.length;l<u;l++){const w=this._requests[l],C=this._testElements[l];w.fulfill(C.offsetWidth/256)}}}function P(h,l){new U(h,l).read()}var B=y(66476),T=y(28060);class p extends K.jG{constructor(){super(),this._onDidChange=this._register(new o.vl),this.onDidChange=this._onDidChange.event,this._cache=new d,this._evictUntrustedReadingsTimeout=-1}dispose(){this._evictUntrustedReadingsTimeout!==-1&&(window.clearTimeout(this._evictUntrustedReadingsTimeout),this._evictUntrustedReadingsTimeout=-1),super.dispose()}clearAllFontInfos(){this._cache=new d,this._onDidChange.fire()}_writeToCache(l,u){this._cache.put(l,u),!u.isTrusted&&this._evictUntrustedReadingsTimeout===-1&&(this._evictUntrustedReadingsTimeout=window.setTimeout(()=>{this._evictUntrustedReadingsTimeout=-1,this._evictUntrustedReadings()},5e3))}_evictUntrustedReadings(){const l=this._cache.getValues();let u=!1;for(const w of l)w.isTrusted||(u=!0,this._cache.remove(w));u&&this._onDidChange.fire()}readFontInfo(l){if(!this._cache.has(l)){let u=this._actualReadFontInfo(l);(u.typicalHalfwidthCharacterWidth<=2||u.typicalFullwidthCharacterWidth<=2||u.spaceWidth<=2||u.maxDigitWidth<=2)&&(u=new T.YJ({pixelRatio:b.PixelRatio.value,fontFamily:u.fontFamily,fontWeight:u.fontWeight,fontSize:u.fontSize,fontFeatureSettings:u.fontFeatureSettings,lineHeight:u.lineHeight,letterSpacing:u.letterSpacing,isMonospace:u.isMonospace,typicalHalfwidthCharacterWidth:Math.max(u.typicalHalfwidthCharacterWidth,5),typicalFullwidthCharacterWidth:Math.max(u.typicalFullwidthCharacterWidth,5),canUseHalfwidthRightwardsArrow:u.canUseHalfwidthRightwardsArrow,spaceWidth:Math.max(u.spaceWidth,5),middotWidth:Math.max(u.middotWidth,5),wsmiddotWidth:Math.max(u.wsmiddotWidth,5),maxDigitWidth:Math.max(u.maxDigitWidth,5)},!1)),this._writeToCache(l,u)}return this._cache.get(l)}_createRequest(l,u,w,C){const m=new L(l,u);return w.push(m),C?.push(m),m}_actualReadFontInfo(l){const u=[],w=[],C=this._createRequest("n",0,u,w),m=this._createRequest("\uFF4D",0,u,null),v=this._createRequest(" ",0,u,w),k=this._createRequest("0",0,u,w),D=this._createRequest("1",0,u,w),x=this._createRequest("2",0,u,w),A=this._createRequest("3",0,u,w),W=this._createRequest("4",0,u,w),Y=this._createRequest("5",0,u,w),ne=this._createRequest("6",0,u,w),j=this._createRequest("7",0,u,w),Q=this._createRequest("8",0,u,w),X=this._createRequest("9",0,u,w),R=this._createRequest("\u2192",0,u,w),H=this._createRequest("\uFFEB",0,u,null),Z=this._createRequest("\xB7",0,u,w),N=this._createRequest("\u2E31",0,u,null),G="|/-_ilm%";for(let E=0,Qe=G.length;E<Qe;E++)this._createRequest(G.charAt(E),0,u,w),this._createRequest(G.charAt(E),1,u,w),this._createRequest(G.charAt(E),2,u,w);P(l,u);const O=Math.max(k.width,D.width,x.width,A.width,W.width,Y.width,ne.width,j.width,Q.width,X.width);let te=l.fontFeatureSettings===B.Bc.OFF;const oe=w[0].width;for(let E=1,Qe=w.length;te&&E<Qe;E++){const Ke=oe-w[E].width;if(Ke<-.001||Ke>.001){te=!1;break}}let ue=!0;return te&&H.width!==oe&&(ue=!1),H.width>R.width&&(ue=!1),new T.YJ({pixelRatio:b.PixelRatio.value,fontFamily:l.fontFamily,fontWeight:l.fontWeight,fontSize:l.fontSize,fontFeatureSettings:l.fontFeatureSettings,lineHeight:l.lineHeight,letterSpacing:l.letterSpacing,isMonospace:te,typicalHalfwidthCharacterWidth:C.width,typicalFullwidthCharacterWidth:m.width,canUseHalfwidthRightwardsArrow:ue,spaceWidth:v.width,middotWidth:Z.width,wsmiddotWidth:N.width,maxDigitWidth:O},!0)}}class d{constructor(){this._keys=Object.create(null),this._values=Object.create(null)}has(l){const u=l.getId();return!!this._values[u]}get(l){const u=l.getId();return this._values[u]}put(l,u){const w=l.getId();this._keys[w]=l,this._values[w]=u}remove(l){const u=l.getId();delete this._keys[u],delete this._values[u]}getValues(){return Object.keys(this._keys).map(l=>this._values[l])}}const g=new p},41504:(rt,ye,y)=>{y.d(ye,{J:()=>K,U:()=>o});var b=y(82399);const o=(0,b.u1)("textResourceConfigurationService"),K=(0,b.u1)("textResourcePropertiesService")},41672:(rt,ye,y)=>{y.d(ye,{Y:()=>d});var b=y(16844),o=y(62549),K=y(50442),$=y(93702),L=y(80794),U=y(52394),P=function(g,h,l,u){var w=arguments.length,C=w<3?h:u===null?u=Object.getOwnPropertyDescriptor(h,l):u,m;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")C=Reflect.decorate(g,h,l,u);else for(var v=g.length-1;v>=0;v--)(m=g[v])&&(C=(w<3?m(C):w>3?m(h,l,C):m(h,l))||C);return w>3&&C&&Object.defineProperty(h,l,C),C},B=function(g,h){return function(l,u){h(l,u,g)}};const T=Object.create(null);function p(g,h){if(h<=0)return"";T[g]||(T[g]=["",g]);const l=T[g];for(let u=l.length;u<=h;u++)l[u]=l[u-1]+g;return l[h]}let d=class _a{constructor(h,l,u){this._languageConfigurationService=u,this._opts=l,this._selection=h,this._selectionId=null,this._useLastEditRangeForCursorEndPosition=!1,this._selectionStartColumnStaysPut=!1}static unshiftIndent(h,l,u,w,C){const m=o.A.visibleColumnFromColumn(h,l,u);if(C){const v=p(" ",w),D=o.A.prevIndentTabStop(m,w)/w;return p(v,D)}else{const D=o.A.prevRenderTabStop(m,u)/u;return p(" ",D)}}static shiftIndent(h,l,u,w,C){const m=o.A.visibleColumnFromColumn(h,l,u);if(C){const v=p(" ",w),D=o.A.nextIndentTabStop(m,w)/w;return p(v,D)}else{const D=o.A.nextRenderTabStop(m,u)/u;return p(" ",D)}}_addEditOperation(h,l,u){this._useLastEditRangeForCursorEndPosition?h.addTrackedEditOperation(l,u):h.addEditOperation(l,u)}getEditOperations(h,l){const u=this._selection.startLineNumber;let w=this._selection.endLineNumber;this._selection.endColumn===1&&u!==w&&(w=w-1);const{tabSize:C,indentSize:m,insertSpaces:v}=this._opts,k=u===w;if(this._opts.useTabStops){this._selection.isEmpty()&&/^\s*$/.test(h.getLineContent(u))&&(this._useLastEditRangeForCursorEndPosition=!0);let D=0,x=0;for(let A=u;A<=w;A++,D=x){x=0;const W=h.getLineContent(A);let Y=b.HG(W);if(this._opts.isUnshift&&(W.length===0||Y===0)||!k&&!this._opts.isUnshift&&W.length===0)continue;if(Y===-1&&(Y=W.length),A>1&&o.A.visibleColumnFromColumn(W,Y+1,C)%m!==0&&h.tokenization.isCheapToTokenize(A-1)){const Q=(0,L.h)(this._opts.autoIndent,h,new K.Q(A-1,h.getLineMaxColumn(A-1),A-1,h.getLineMaxColumn(A-1)),this._languageConfigurationService);if(Q){if(x=D,Q.appendText)for(let X=0,R=Q.appendText.length;X<R&&x<m&&Q.appendText.charCodeAt(X)===32;X++)x++;Q.removeText&&(x=Math.max(0,x-Q.removeText));for(let X=0;X<x&&!(Y===0||W.charCodeAt(Y-1)!==32);X++)Y--}}if(this._opts.isUnshift&&Y===0)continue;let ne;this._opts.isUnshift?ne=_a.unshiftIndent(W,Y+1,C,m,v):ne=_a.shiftIndent(W,Y+1,C,m,v),this._addEditOperation(l,new K.Q(A,1,A,Y+1),ne),A===u&&!this._selection.isEmpty()&&(this._selectionStartColumnStaysPut=this._selection.startColumn<=Y+1)}}else{!this._opts.isUnshift&&this._selection.isEmpty()&&h.getLineLength(u)===0&&(this._useLastEditRangeForCursorEndPosition=!0);const D=v?p(" ",m):" ";for(let x=u;x<=w;x++){const A=h.getLineContent(x);let W=b.HG(A);if(!(this._opts.isUnshift&&(A.length===0||W===0))&&!(!k&&!this._opts.isUnshift&&A.length===0)&&(W===-1&&(W=A.length),!(this._opts.isUnshift&&W===0)))if(this._opts.isUnshift){W=Math.min(W,m);for(let Y=0;Y<W;Y++)if(A.charCodeAt(Y)===9){W=Y+1;break}this._addEditOperation(l,new K.Q(x,1,x,W+1),"")}else this._addEditOperation(l,new K.Q(x,1,x,1),D),x===u&&!this._selection.isEmpty()&&(this._selectionStartColumnStaysPut=this._selection.startColumn===1)}}this._selectionId=l.trackSelection(this._selection)}computeCursorState(h,l){if(this._useLastEditRangeForCursorEndPosition){const w=l.getInverseEditOperations()[0];return new $.L(w.range.endLineNumber,w.range.endColumn,w.range.endLineNumber,w.range.endColumn)}const u=l.getTrackedSelection(this._selectionId);if(this._selectionStartColumnStaysPut){const w=this._selection.startColumn;return u.startColumn<=w?u:u.getDirection()===0?new $.L(u.startLineNumber,w,u.endLineNumber,u.endColumn):new $.L(u.endLineNumber,u.endColumn,u.startLineNumber,w)}return u}};d=P([B(2,U.JZ)],d)},42783:(rt,ye,y)=>{y.d(ye,{A5:()=>Y,Ah:()=>Q,DD:()=>v,DO:()=>j,Gn:()=>b,H_:()=>G,Ic:()=>ne,Io:()=>$,Kb:()=>p,QP:()=>L,Qj:()=>P,R3:()=>x,SB:()=>H,U7:()=>O,VW:()=>w,WA:()=>Z,WU:()=>l,XR:()=>R,_E:()=>K,cj:()=>k,dE:()=>W,d_:()=>D,e0:()=>d,h5:()=>B,hS:()=>A,kK:()=>oe,kf:()=>h,l:()=>u,m9:()=>te,of:()=>T,ok:()=>o,ov:()=>X,p2:()=>g,qw:()=>m,r4:()=>C,t7:()=>U,tJ:()=>ue,v0:()=>N});var b;(function(E){E[E.Unknown=0]="Unknown",E[E.Disabled=1]="Disabled",E[E.Enabled=2]="Enabled"})(b||(b={}));var o;(function(E){E[E.Invoke=1]="Invoke",E[E.Auto=2]="Auto"})(o||(o={}));var K;(function(E){E[E.KeepWhitespace=1]="KeepWhitespace",E[E.InsertAsSnippet=4]="InsertAsSnippet"})(K||(K={}));var $;(function(E){E[E.Method=0]="Method",E[E.Function=1]="Function",E[E.Constructor=2]="Constructor",E[E.Field=3]="Field",E[E.Variable=4]="Variable",E[E.Class=5]="Class",E[E.Struct=6]="Struct",E[E.Interface=7]="Interface",E[E.Module=8]="Module",E[E.Property=9]="Property",E[E.Event=10]="Event",E[E.Operator=11]="Operator",E[E.Unit=12]="Unit",E[E.Value=13]="Value",E[E.Constant=14]="Constant",E[E.Enum=15]="Enum",E[E.EnumMember=16]="EnumMember",E[E.Keyword=17]="Keyword",E[E.Text=18]="Text",E[E.Color=19]="Color",E[E.File=20]="File",E[E.Reference=21]="Reference",E[E.Customcolor=22]="Customcolor",E[E.Folder=23]="Folder",E[E.TypeParameter=24]="TypeParameter",E[E.User=25]="User",E[E.Issue=26]="Issue",E[E.Snippet=27]="Snippet"})($||($={}));var L;(function(E){E[E.Deprecated=1]="Deprecated"})(L||(L={}));var U;(function(E){E[E.Invoke=0]="Invoke",E[E.TriggerCharacter=1]="TriggerCharacter",E[E.TriggerForIncompleteCompletions=2]="TriggerForIncompleteCompletions"})(U||(U={}));var P;(function(E){E[E.EXACT=0]="EXACT",E[E.ABOVE=1]="ABOVE",E[E.BELOW=2]="BELOW"})(P||(P={}));var B;(function(E){E[E.NotSet=0]="NotSet",E[E.ContentFlush=1]="ContentFlush",E[E.RecoverFromMarkers=2]="RecoverFromMarkers",E[E.Explicit=3]="Explicit",E[E.Paste=4]="Paste",E[E.Undo=5]="Undo",E[E.Redo=6]="Redo"})(B||(B={}));var T;(function(E){E[E.LF=1]="LF",E[E.CRLF=2]="CRLF"})(T||(T={}));var p;(function(E){E[E.Text=0]="Text",E[E.Read=1]="Read",E[E.Write=2]="Write"})(p||(p={}));var d;(function(E){E[E.None=0]="None",E[E.Keep=1]="Keep",E[E.Brackets=2]="Brackets",E[E.Advanced=3]="Advanced",E[E.Full=4]="Full"})(d||(d={}));var g;(function(E){E[E.acceptSuggestionOnCommitCharacter=0]="acceptSuggestionOnCommitCharacter",E[E.acceptSuggestionOnEnter=1]="acceptSuggestionOnEnter",E[E.accessibilitySupport=2]="accessibilitySupport",E[E.accessibilityPageSize=3]="accessibilityPageSize",E[E.ariaLabel=4]="ariaLabel",E[E.autoClosingBrackets=5]="autoClosingBrackets",E[E.autoClosingDelete=6]="autoClosingDelete",E[E.autoClosingOvertype=7]="autoClosingOvertype",E[E.autoClosingQuotes=8]="autoClosingQuotes",E[E.autoIndent=9]="autoIndent",E[E.automaticLayout=10]="automaticLayout",E[E.autoSurround=11]="autoSurround",E[E.bracketPairColorization=12]="bracketPairColorization",E[E.guides=13]="guides",E[E.codeLens=14]="codeLens",E[E.codeLensFontFamily=15]="codeLensFontFamily",E[E.codeLensFontSize=16]="codeLensFontSize",E[E.colorDecorators=17]="colorDecorators",E[E.columnSelection=18]="columnSelection",E[E.comments=19]="comments",E[E.contextmenu=20]="contextmenu",E[E.copyWithSyntaxHighlighting=21]="copyWithSyntaxHighlighting",E[E.cursorBlinking=22]="cursorBlinking",E[E.cursorSmoothCaretAnimation=23]="cursorSmoothCaretAnimation",E[E.cursorStyle=24]="cursorStyle",E[E.cursorSurroundingLines=25]="cursorSurroundingLines",E[E.cursorSurroundingLinesStyle=26]="cursorSurroundingLinesStyle",E[E.cursorWidth=27]="cursorWidth",E[E.disableLayerHinting=28]="disableLayerHinting",E[E.disableMonospaceOptimizations=29]="disableMonospaceOptimizations",E[E.domReadOnly=30]="domReadOnly",E[E.dragAndDrop=31]="dragAndDrop",E[E.dropIntoEditor=32]="dropIntoEditor",E[E.emptySelectionClipboard=33]="emptySelectionClipboard",E[E.experimental=34]="experimental",E[E.extraEditorClassName=35]="extraEditorClassName",E[E.fastScrollSensitivity=36]="fastScrollSensitivity",E[E.find=37]="find",E[E.fixedOverflowWidgets=38]="fixedOverflowWidgets",E[E.folding=39]="folding",E[E.foldingStrategy=40]="foldingStrategy",E[E.foldingHighlight=41]="foldingHighlight",E[E.foldingImportsByDefault=42]="foldingImportsByDefault",E[E.foldingMaximumRegions=43]="foldingMaximumRegions",E[E.unfoldOnClickAfterEndOfLine=44]="unfoldOnClickAfterEndOfLine",E[E.fontFamily=45]="fontFamily",E[E.fontInfo=46]="fontInfo",E[E.fontLigatures=47]="fontLigatures",E[E.fontSize=48]="fontSize",E[E.fontWeight=49]="fontWeight",E[E.formatOnPaste=50]="formatOnPaste",E[E.formatOnType=51]="formatOnType",E[E.glyphMargin=52]="glyphMargin",E[E.gotoLocation=53]="gotoLocation",E[E.hideCursorInOverviewRuler=54]="hideCursorInOverviewRuler",E[E.hover=55]="hover",E[E.inDiffEditor=56]="inDiffEditor",E[E.inlineSuggest=57]="inlineSuggest",E[E.letterSpacing=58]="letterSpacing",E[E.lightbulb=59]="lightbulb",E[E.lineDecorationsWidth=60]="lineDecorationsWidth",E[E.lineHeight=61]="lineHeight",E[E.lineNumbers=62]="lineNumbers",E[E.lineNumbersMinChars=63]="lineNumbersMinChars",E[E.linkedEditing=64]="linkedEditing",E[E.links=65]="links",E[E.matchBrackets=66]="matchBrackets",E[E.minimap=67]="minimap",E[E.mouseStyle=68]="mouseStyle",E[E.mouseWheelScrollSensitivity=69]="mouseWheelScrollSensitivity",E[E.mouseWheelZoom=70]="mouseWheelZoom",E[E.multiCursorMergeOverlapping=71]="multiCursorMergeOverlapping",E[E.multiCursorModifier=72]="multiCursorModifier",E[E.multiCursorPaste=73]="multiCursorPaste",E[E.occurrencesHighlight=74]="occurrencesHighlight",E[E.overviewRulerBorder=75]="overviewRulerBorder",E[E.overviewRulerLanes=76]="overviewRulerLanes",E[E.padding=77]="padding",E[E.parameterHints=78]="parameterHints",E[E.peekWidgetDefaultFocus=79]="peekWidgetDefaultFocus",E[E.definitionLinkOpensInPeek=80]="definitionLinkOpensInPeek",E[E.quickSuggestions=81]="quickSuggestions",E[E.quickSuggestionsDelay=82]="quickSuggestionsDelay",E[E.readOnly=83]="readOnly",E[E.renameOnType=84]="renameOnType",E[E.renderControlCharacters=85]="renderControlCharacters",E[E.renderFinalNewline=86]="renderFinalNewline",E[E.renderLineHighlight=87]="renderLineHighlight",E[E.renderLineHighlightOnlyWhenFocus=88]="renderLineHighlightOnlyWhenFocus",E[E.renderValidationDecorations=89]="renderValidationDecorations",E[E.renderWhitespace=90]="renderWhitespace",E[E.revealHorizontalRightPadding=91]="revealHorizontalRightPadding",E[E.roundedSelection=92]="roundedSelection",E[E.rulers=93]="rulers",E[E.scrollbar=94]="scrollbar",E[E.scrollBeyondLastColumn=95]="scrollBeyondLastColumn",E[E.scrollBeyondLastLine=96]="scrollBeyondLastLine",E[E.scrollPredominantAxis=97]="scrollPredominantAxis",E[E.selectionClipboard=98]="selectionClipboard",E[E.selectionHighlight=99]="selectionHighlight",E[E.selectOnLineNumbers=100]="selectOnLineNumbers",E[E.showFoldingControls=101]="showFoldingControls",E[E.showUnused=102]="showUnused",E[E.snippetSuggestions=103]="snippetSuggestions",E[E.smartSelect=104]="smartSelect",E[E.smoothScrolling=105]="smoothScrolling",E[E.stickyTabStops=106]="stickyTabStops",E[E.stopRenderingLineAfter=107]="stopRenderingLineAfter",E[E.suggest=108]="suggest",E[E.suggestFontSize=109]="suggestFontSize",E[E.suggestLineHeight=110]="suggestLineHeight",E[E.suggestOnTriggerCharacters=111]="suggestOnTriggerCharacters",E[E.suggestSelection=112]="suggestSelection",E[E.tabCompletion=113]="tabCompletion",E[E.tabIndex=114]="tabIndex",E[E.unicodeHighlighting=115]="unicodeHighlighting",E[E.unusualLineTerminators=116]="unusualLineTerminators",E[E.useShadowDOM=117]="useShadowDOM",E[E.useTabStops=118]="useTabStops",E[E.wordSeparators=119]="wordSeparators",E[E.wordWrap=120]="wordWrap",E[E.wordWrapBreakAfterCharacters=121]="wordWrapBreakAfterCharacters",E[E.wordWrapBreakBeforeCharacters=122]="wordWrapBreakBeforeCharacters",E[E.wordWrapColumn=123]="wordWrapColumn",E[E.wordWrapOverride1=124]="wordWrapOverride1",E[E.wordWrapOverride2=125]="wordWrapOverride2",E[E.wrappingIndent=126]="wrappingIndent",E[E.wrappingStrategy=127]="wrappingStrategy",E[E.showDeprecated=128]="showDeprecated",E[E.inlayHints=129]="inlayHints",E[E.editorClassName=130]="editorClassName",E[E.pixelRatio=131]="pixelRatio",E[E.tabFocusMode=132]="tabFocusMode",E[E.layoutInfo=133]="layoutInfo",E[E.wrappingInfo=134]="wrappingInfo"})(g||(g={}));var h;(function(E){E[E.TextDefined=0]="TextDefined",E[E.LF=1]="LF",E[E.CRLF=2]="CRLF"})(h||(h={}));var l;(function(E){E[E.LF=0]="LF",E[E.CRLF=1]="CRLF"})(l||(l={}));var u;(function(E){E[E.None=0]="None",E[E.Indent=1]="Indent",E[E.IndentOutdent=2]="IndentOutdent",E[E.Outdent=3]="Outdent"})(u||(u={}));var w;(function(E){E[E.Both=0]="Both",E[E.Right=1]="Right",E[E.Left=2]="Left",E[E.None=3]="None"})(w||(w={}));var C;(function(E){E[E.Type=1]="Type",E[E.Parameter=2]="Parameter"})(C||(C={}));var m;(function(E){E[E.Automatic=0]="Automatic",E[E.Explicit=1]="Explicit"})(m||(m={}));var v;(function(E){E[E.DependsOnKbLayout=-1]="DependsOnKbLayout",E[E.Unknown=0]="Unknown",E[E.Backspace=1]="Backspace",E[E.Tab=2]="Tab",E[E.Enter=3]="Enter",E[E.Shift=4]="Shift",E[E.Ctrl=5]="Ctrl",E[E.Alt=6]="Alt",E[E.PauseBreak=7]="PauseBreak",E[E.CapsLock=8]="CapsLock",E[E.Escape=9]="Escape",E[E.Space=10]="Space",E[E.PageUp=11]="PageUp",E[E.PageDown=12]="PageDown",E[E.End=13]="End",E[E.Home=14]="Home",E[E.LeftArrow=15]="LeftArrow",E[E.UpArrow=16]="UpArrow",E[E.RightArrow=17]="RightArrow",E[E.DownArrow=18]="DownArrow",E[E.Insert=19]="Insert",E[E.Delete=20]="Delete",E[E.Digit0=21]="Digit0",E[E.Digit1=22]="Digit1",E[E.Digit2=23]="Digit2",E[E.Digit3=24]="Digit3",E[E.Digit4=25]="Digit4",E[E.Digit5=26]="Digit5",E[E.Digit6=27]="Digit6",E[E.Digit7=28]="Digit7",E[E.Digit8=29]="Digit8",E[E.Digit9=30]="Digit9",E[E.KeyA=31]="KeyA",E[E.KeyB=32]="KeyB",E[E.KeyC=33]="KeyC",E[E.KeyD=34]="KeyD",E[E.KeyE=35]="KeyE",E[E.KeyF=36]="KeyF",E[E.KeyG=37]="KeyG",E[E.KeyH=38]="KeyH",E[E.KeyI=39]="KeyI",E[E.KeyJ=40]="KeyJ",E[E.KeyK=41]="KeyK",E[E.KeyL=42]="KeyL",E[E.KeyM=43]="KeyM",E[E.KeyN=44]="KeyN",E[E.KeyO=45]="KeyO",E[E.KeyP=46]="KeyP",E[E.KeyQ=47]="KeyQ",E[E.KeyR=48]="KeyR",E[E.KeyS=49]="KeyS",E[E.KeyT=50]="KeyT",E[E.KeyU=51]="KeyU",E[E.KeyV=52]="KeyV",E[E.KeyW=53]="KeyW",E[E.KeyX=54]="KeyX",E[E.KeyY=55]="KeyY",E[E.KeyZ=56]="KeyZ",E[E.Meta=57]="Meta",E[E.ContextMenu=58]="ContextMenu",E[E.F1=59]="F1",E[E.F2=60]="F2",E[E.F3=61]="F3",E[E.F4=62]="F4",E[E.F5=63]="F5",E[E.F6=64]="F6",E[E.F7=65]="F7",E[E.F8=66]="F8",E[E.F9=67]="F9",E[E.F10=68]="F10",E[E.F11=69]="F11",E[E.F12=70]="F12",E[E.F13=71]="F13",E[E.F14=72]="F14",E[E.F15=73]="F15",E[E.F16=74]="F16",E[E.F17=75]="F17",E[E.F18=76]="F18",E[E.F19=77]="F19",E[E.NumLock=78]="NumLock",E[E.ScrollLock=79]="ScrollLock",E[E.Semicolon=80]="Semicolon",E[E.Equal=81]="Equal",E[E.Comma=82]="Comma",E[E.Minus=83]="Minus",E[E.Period=84]="Period",E[E.Slash=85]="Slash",E[E.Backquote=86]="Backquote",E[E.BracketLeft=87]="BracketLeft",E[E.Backslash=88]="Backslash",E[E.BracketRight=89]="BracketRight",E[E.Quote=90]="Quote",E[E.OEM_8=91]="OEM_8",E[E.IntlBackslash=92]="IntlBackslash",E[E.Numpad0=93]="Numpad0",E[E.Numpad1=94]="Numpad1",E[E.Numpad2=95]="Numpad2",E[E.Numpad3=96]="Numpad3",E[E.Numpad4=97]="Numpad4",E[E.Numpad5=98]="Numpad5",E[E.Numpad6=99]="Numpad6",E[E.Numpad7=100]="Numpad7",E[E.Numpad8=101]="Numpad8",E[E.Numpad9=102]="Numpad9",E[E.NumpadMultiply=103]="NumpadMultiply",E[E.NumpadAdd=104]="NumpadAdd",E[E.NUMPAD_SEPARATOR=105]="NUMPAD_SEPARATOR",E[E.NumpadSubtract=106]="NumpadSubtract",E[E.NumpadDecimal=107]="NumpadDecimal",E[E.NumpadDivide=108]="NumpadDivide",E[E.KEY_IN_COMPOSITION=109]="KEY_IN_COMPOSITION",E[E.ABNT_C1=110]="ABNT_C1",E[E.ABNT_C2=111]="ABNT_C2",E[E.AudioVolumeMute=112]="AudioVolumeMute",E[E.AudioVolumeUp=113]="AudioVolumeUp",E[E.AudioVolumeDown=114]="AudioVolumeDown",E[E.BrowserSearch=115]="BrowserSearch",E[E.BrowserHome=116]="BrowserHome",E[E.BrowserBack=117]="BrowserBack",E[E.BrowserForward=118]="BrowserForward",E[E.MediaTrackNext=119]="MediaTrackNext",E[E.MediaTrackPrevious=120]="MediaTrackPrevious",E[E.MediaStop=121]="MediaStop",E[E.MediaPlayPause=122]="MediaPlayPause",E[E.LaunchMediaPlayer=123]="LaunchMediaPlayer",E[E.LaunchMail=124]="LaunchMail",E[E.LaunchApp2=125]="LaunchApp2",E[E.Clear=126]="Clear",E[E.MAX_VALUE=127]="MAX_VALUE"})(v||(v={}));var k;(function(E){E[E.Hint=1]="Hint",E[E.Info=2]="Info",E[E.Warning=4]="Warning",E[E.Error=8]="Error"})(k||(k={}));var D;(function(E){E[E.Unnecessary=1]="Unnecessary",E[E.Deprecated=2]="Deprecated"})(D||(D={}));var x;(function(E){E[E.Inline=1]="Inline",E[E.Gutter=2]="Gutter"})(x||(x={}));var A;(function(E){E[E.UNKNOWN=0]="UNKNOWN",E[E.TEXTAREA=1]="TEXTAREA",E[E.GUTTER_GLYPH_MARGIN=2]="GUTTER_GLYPH_MARGIN",E[E.GUTTER_LINE_NUMBERS=3]="GUTTER_LINE_NUMBERS",E[E.GUTTER_LINE_DECORATIONS=4]="GUTTER_LINE_DECORATIONS",E[E.GUTTER_VIEW_ZONE=5]="GUTTER_VIEW_ZONE",E[E.CONTENT_TEXT=6]="CONTENT_TEXT",E[E.CONTENT_EMPTY=7]="CONTENT_EMPTY",E[E.CONTENT_VIEW_ZONE=8]="CONTENT_VIEW_ZONE",E[E.CONTENT_WIDGET=9]="CONTENT_WIDGET",E[E.OVERVIEW_RULER=10]="OVERVIEW_RULER",E[E.SCROLLBAR=11]="SCROLLBAR",E[E.OVERLAY_WIDGET=12]="OVERLAY_WIDGET",E[E.OUTSIDE_EDITOR=13]="OUTSIDE_EDITOR"})(A||(A={}));var W;(function(E){E[E.TOP_RIGHT_CORNER=0]="TOP_RIGHT_CORNER",E[E.BOTTOM_RIGHT_CORNER=1]="BOTTOM_RIGHT_CORNER",E[E.TOP_CENTER=2]="TOP_CENTER"})(W||(W={}));var Y;(function(E){E[E.Left=1]="Left",E[E.Center=2]="Center",E[E.Right=4]="Right",E[E.Full=7]="Full"})(Y||(Y={}));var ne;(function(E){E[E.Left=0]="Left",E[E.Right=1]="Right",E[E.None=2]="None",E[E.LeftOfInjectedText=3]="LeftOfInjectedText",E[E.RightOfInjectedText=4]="RightOfInjectedText"})(ne||(ne={}));var j;(function(E){E[E.Off=0]="Off",E[E.On=1]="On",E[E.Relative=2]="Relative",E[E.Interval=3]="Interval",E[E.Custom=4]="Custom"})(j||(j={}));var Q;(function(E){E[E.None=0]="None",E[E.Text=1]="Text",E[E.Blocks=2]="Blocks"})(Q||(Q={}));var X;(function(E){E[E.Smooth=0]="Smooth",E[E.Immediate=1]="Immediate"})(X||(X={}));var R;(function(E){E[E.Auto=1]="Auto",E[E.Hidden=2]="Hidden",E[E.Visible=3]="Visible"})(R||(R={}));var H;(function(E){E[E.LTR=0]="LTR",E[E.RTL=1]="RTL"})(H||(H={}));var Z;(function(E){E[E.Invoke=1]="Invoke",E[E.TriggerCharacter=2]="TriggerCharacter",E[E.ContentChange=3]="ContentChange"})(Z||(Z={}));var N;(function(E){E[E.File=0]="File",E[E.Module=1]="Module",E[E.Namespace=2]="Namespace",E[E.Package=3]="Package",E[E.Class=4]="Class",E[E.Method=5]="Method",E[E.Property=6]="Property",E[E.Field=7]="Field",E[E.Constructor=8]="Constructor",E[E.Enum=9]="Enum",E[E.Interface=10]="Interface",E[E.Function=11]="Function",E[E.Variable=12]="Variable",E[E.Constant=13]="Constant",E[E.String=14]="String",E[E.Number=15]="Number",E[E.Boolean=16]="Boolean",E[E.Array=17]="Array",E[E.Object=18]="Object",E[E.Key=19]="Key",E[E.Null=20]="Null",E[E.EnumMember=21]="EnumMember",E[E.Struct=22]="Struct",E[E.Event=23]="Event",E[E.Operator=24]="Operator",E[E.TypeParameter=25]="TypeParameter"})(N||(N={}));var G;(function(E){E[E.Deprecated=1]="Deprecated"})(G||(G={}));var O;(function(E){E[E.Hidden=0]="Hidden",E[E.Blink=1]="Blink",E[E.Smooth=2]="Smooth",E[E.Phase=3]="Phase",E[E.Expand=4]="Expand",E[E.Solid=5]="Solid"})(O||(O={}));var te;(function(E){E[E.Line=1]="Line",E[E.Block=2]="Block",E[E.Underline=3]="Underline",E[E.LineThin=4]="LineThin",E[E.BlockOutline=5]="BlockOutline",E[E.UnderlineThin=6]="UnderlineThin"})(te||(te={}));var oe;(function(E){E[E.AlwaysGrowsWhenTypingAtEdges=0]="AlwaysGrowsWhenTypingAtEdges",E[E.NeverGrowsWhenTypingAtEdges=1]="NeverGrowsWhenTypingAtEdges",E[E.GrowsOnlyWhenTypingBefore=2]="GrowsOnlyWhenTypingBefore",E[E.GrowsOnlyWhenTypingAfter=3]="GrowsOnlyWhenTypingAfter"})(oe||(oe={}));var ue;(function(E){E[E.None=0]="None",E[E.Same=1]="Same",E[E.Indent=2]="Indent",E[E.DeepIndent=3]="DeepIndent"})(ue||(ue={}))},42802:(rt,ye,y)=>{y.d(ye,{$l:()=>L,Gs:()=>p,MB:()=>$,Sw:()=>B,bb:()=>P,gN:()=>U,pJ:()=>T});var b=y(48287).Buffer;const o=typeof b<"u";let K;class ${constructor(g){this.buffer=g,this.byteLength=this.buffer.byteLength}static wrap(g){return o&&!b.isBuffer(g)&&(g=b.from(g.buffer,g.byteOffset,g.byteLength)),new $(g)}toString(){return o?this.buffer.toString():(K||(K=new TextDecoder),K.decode(this.buffer))}}function L(d,g){return d[g+0]<<0>>>0|d[g+1]<<8>>>0}function U(d,g,h){d[h+0]=g&255,g=g>>>8,d[h+1]=g&255}function P(d,g){return d[g]*Math.pow(2,24)+d[g+1]*Math.pow(2,16)+d[g+2]*Math.pow(2,8)+d[g+3]}function B(d,g,h){d[h+3]=g,g=g>>>8,d[h+2]=g,g=g>>>8,d[h+1]=g,g=g>>>8,d[h]=g}function T(d,g){return d[g]}function p(d,g,h){d[h]=g}},44023:(rt,ye,y)=>{y.d(ye,{G5:()=>o,N8:()=>L,ke:()=>$});var b=y(82399);const o=(0,b.u1)("progressService"),K=Object.freeze({total(){},worked(){},done(){}});class ${constructor(P){this.callback=P}report(P){this._value=P,this.callback(this._value)}}$.None=Object.freeze({report(){}});const L=(0,b.u1)("editorProgressService")},45222:(rt,ye,y)=>{y.d(ye,{x:()=>U});var b=y(14333),o=y(87594),K=y(9715),$=y(30474),L=y(10998);class U extends L.jG{onclick(B,T){this._register(b.ko(B,b.Bx.CLICK,p=>T(new K.P(p))))}onmousedown(B,T){this._register(b.ko(B,b.Bx.MOUSE_DOWN,p=>T(new K.P(p))))}onmouseover(B,T){this._register(b.ko(B,b.Bx.MOUSE_OVER,p=>T(new K.P(p))))}onmouseleave(B,T){this._register(b.ko(B,b.Bx.MOUSE_LEAVE,p=>T(new K.P(p))))}onkeydown(B,T){this._register(b.ko(B,b.Bx.KEY_DOWN,p=>T(new o.Z(p))))}onkeyup(B,T){this._register(b.ko(B,b.Bx.KEY_UP,p=>T(new o.Z(p))))}oninput(B,T){this._register(b.ko(B,b.Bx.INPUT,T))}onblur(B,T){this._register(b.ko(B,b.Bx.BLUR,T))}onfocus(B,T){this._register(b.ko(B,b.Bx.FOCUS,T))}ignoreGesture(B){$.q.ignoreTarget(B)}}},45561:(rt,ye,y)=>{y.d(ye,{Bs:()=>L,d:()=>o});var b=y(16844);class o{constructor(P,B,T,p){this.startColumn=P,this.endColumn=B,this.className=T,this.type=p,this._lineDecorationBrand=void 0}static _equals(P,B){return P.startColumn===B.startColumn&&P.endColumn===B.endColumn&&P.className===B.className&&P.type===B.type}static equalsArr(P,B){const T=P.length,p=B.length;if(T!==p)return!1;for(let d=0;d<T;d++)if(!o._equals(P[d],B[d]))return!1;return!0}static extractWrapped(P,B,T){if(P.length===0)return P;const p=B+1,d=T+1,g=T-B,h=[];let l=0;for(const u of P)u.endColumn<=p||u.startColumn>=d||(h[l++]=new o(Math.max(1,u.startColumn-p+1),Math.min(g+1,u.endColumn-p+1),u.className,u.type));return h}static filter(P,B,T,p){if(P.length===0)return[];const d=[];let g=0;for(let h=0,l=P.length;h<l;h++){const u=P[h],w=u.range;if(w.endLineNumber<B||w.startLineNumber>B||w.isEmpty()&&(u.type===0||u.type===3))continue;const C=w.startLineNumber===B?w.startColumn:T,m=w.endLineNumber===B?w.endColumn:p;d[g++]=new o(C,m,u.inlineClassName,u.type)}return d}static _typeCompare(P,B){const T=[2,0,1,3];return T[P]-T[B]}static compare(P,B){if(P.startColumn!==B.startColumn)return P.startColumn-B.startColumn;if(P.endColumn!==B.endColumn)return P.endColumn-B.endColumn;const T=o._typeCompare(P.type,B.type);return T!==0?T:P.className!==B.className?P.className<B.className?-1:1:0}}class K{constructor(P,B,T,p){this.startOffset=P,this.endOffset=B,this.className=T,this.metadata=p}}class ${constructor(){this.stopOffsets=[],this.classNames=[],this.metadata=[],this.count=0}static _metadata(P){let B=0;for(let T=0,p=P.length;T<p;T++)B|=P[T];return B}consumeLowerThan(P,B,T){for(;this.count>0&&this.stopOffsets[0]<P;){let p=0;for(;p+1<this.count&&this.stopOffsets[p]===this.stopOffsets[p+1];)p++;T.push(new K(B,this.stopOffsets[p],this.classNames.join(" "),$._metadata(this.metadata))),B=this.stopOffsets[p]+1,this.stopOffsets.splice(0,p+1),this.classNames.splice(0,p+1),this.metadata.splice(0,p+1),this.count-=p+1}return this.count>0&&B<P&&(T.push(new K(B,P-1,this.classNames.join(" "),$._metadata(this.metadata))),B=P),B}insert(P,B,T){if(this.count===0||this.stopOffsets[this.count-1]<=P)this.stopOffsets.push(P),this.classNames.push(B),this.metadata.push(T);else for(let p=0;p<this.count;p++)if(this.stopOffsets[p]>=P){this.stopOffsets.splice(p,0,P),this.classNames.splice(p,0,B),this.metadata.splice(p,0,T);break}this.count++}}class L{static normalize(P,B){if(B.length===0)return[];const T=[],p=new $;let d=0;for(let g=0,h=B.length;g<h;g++){const l=B[g];let u=l.startColumn,w=l.endColumn;const C=l.className,m=l.type===1?2:l.type===2?4:0;if(u>1){const D=P.charCodeAt(u-2);b.pc(D)&&u--}if(w>1){const D=P.charCodeAt(w-2);b.pc(D)&&w--}const v=u-1,k=w-2;d=p.consumeLowerThan(v,d,T),p.count===0&&(d=v),p.insert(k,C,m)}return p.consumeLowerThan(1073741824,d,T),T}}},45854:(rt,ye,y)=>{y.d(ye,{E:()=>d,Z:()=>g});var b=y(55893),o=y(39587),K=y(14333),$=y(30474),L=y(17589),U=y(50350),P=y(10998),B=y(63339),T=y(79359),p=y(3765);class d extends P.jG{constructor(l,u,w={}){super(),this.options=w,this._context=l||this,this._action=u,u instanceof U.rc&&this._register(u.onDidChange(C=>{this.element&&this.handleActionChangeEvent(C)}))}get action(){return this._action}handleActionChangeEvent(l){l.enabled!==void 0&&this.updateEnabled(),l.checked!==void 0&&this.updateChecked(),l.class!==void 0&&this.updateClass(),l.label!==void 0&&(this.updateLabel(),this.updateTooltip()),l.tooltip!==void 0&&this.updateTooltip()}get actionRunner(){return this._actionRunner||(this._actionRunner=this._register(new U.LN)),this._actionRunner}set actionRunner(l){this._actionRunner=l}getAction(){return this._action}isEnabled(){return this._action.enabled}setActionContext(l){this._context=l}render(l){const u=this.element=l;this._register($.q.addTarget(l));const w=this.options&&this.options.draggable;w&&(l.draggable=!0,b.isFirefox&&this._register((0,K.ko)(l,K.Bx.DRAG_START,C=>{var m;return(m=C.dataTransfer)===null||m===void 0?void 0:m.setData(o.t.TEXT,this._action.label)}))),this._register((0,K.ko)(u,$.B.Tap,C=>this.onClick(C,!0))),this._register((0,K.ko)(u,K.Bx.MOUSE_DOWN,C=>{w||K.fs.stop(C,!0),this._action.enabled&&C.button===0&&u.classList.add("active")})),B.zx&&this._register((0,K.ko)(u,K.Bx.CONTEXT_MENU,C=>{C.button===0&&C.ctrlKey===!0&&this.onClick(C)})),this._register((0,K.ko)(u,K.Bx.CLICK,C=>{K.fs.stop(C,!0),this.options&&this.options.isMenu||this.onClick(C)})),this._register((0,K.ko)(u,K.Bx.DBLCLICK,C=>{K.fs.stop(C,!0)})),[K.Bx.MOUSE_UP,K.Bx.MOUSE_OUT].forEach(C=>{this._register((0,K.ko)(u,C,m=>{K.fs.stop(m),u.classList.remove("active")}))})}onClick(l,u=!1){var w;K.fs.stop(l,!0);const C=T.z(this._context)?!((w=this.options)===null||w===void 0)&&w.useEventAsContext?l:{preserveFocus:u}:this._context;this.actionRunner.run(this._action,C)}focus(){this.element&&(this.element.tabIndex=0,this.element.focus(),this.element.classList.add("focused"))}blur(){this.element&&(this.element.blur(),this.element.tabIndex=-1,this.element.classList.remove("focused"))}setFocusable(l){this.element&&(this.element.tabIndex=l?0:-1)}get trapsArrowNavigation(){return!1}updateEnabled(){}updateLabel(){}getTooltip(){return this.getAction().tooltip}updateTooltip(){var l;if(!this.element)return;const u=(l=this.getTooltip())!==null&&l!==void 0?l:"";this.element.setAttribute("aria-label",u),this.options.hoverDelegate?(this.element.title="",this.customHover?this.customHover.update(u):(this.customHover=(0,L.f)(this.options.hoverDelegate,this.element,u),this._store.add(this.customHover))):this.element.title=u}updateClass(){}updateChecked(){}dispose(){this.element&&(this.element.remove(),this.element=void 0),super.dispose()}}class g extends d{constructor(l,u,w={}){super(l,u,w),this.options=w,this.options.icon=w.icon!==void 0?w.icon:!1,this.options.label=w.label!==void 0?w.label:!0,this.cssClass=""}render(l){super.render(l),this.element&&(this.label=(0,K.BC)(this.element,(0,K.$)("a.action-label"))),this.label&&(this._action.id===U.wv.ID?this.label.setAttribute("role","presentation"):this.options.isMenu?this.label.setAttribute("role","menuitem"):this.label.setAttribute("role","button")),this.options.label&&this.options.keybinding&&this.element&&((0,K.BC)(this.element,(0,K.$)("span.keybinding")).textContent=this.options.keybinding),this.updateClass(),this.updateLabel(),this.updateTooltip(),this.updateEnabled(),this.updateChecked()}focus(){this.label&&(this.label.tabIndex=0,this.label.focus())}blur(){this.label&&(this.label.tabIndex=-1)}setFocusable(l){this.label&&(this.label.tabIndex=l?0:-1)}updateLabel(){this.options.label&&this.label&&(this.label.textContent=this.getAction().label)}getTooltip(){let l=null;return this.getAction().tooltip?l=this.getAction().tooltip:!this.options.label&&this.getAction().label&&this.options.icon&&(l=this.getAction().label,this.options.keybinding&&(l=p.kg({key:"titleLabel",comment:["action title","action keybinding"]},"{0} ({1})",l,this.options.keybinding))),l??void 0}updateClass(){var l;this.cssClass&&this.label&&this.label.classList.remove(...this.cssClass.split(" ")),this.options.icon?(this.cssClass=this.getAction().class,this.label&&(this.label.classList.add("codicon"),this.cssClass&&this.label.classList.add(...this.cssClass.split(" "))),this.updateEnabled()):(l=this.label)===null||l===void 0||l.classList.remove("codicon")}updateEnabled(){var l,u;this.getAction().enabled?(this.label&&(this.label.removeAttribute("aria-disabled"),this.label.classList.remove("disabled")),(l=this.element)===null||l===void 0||l.classList.remove("disabled")):(this.label&&(this.label.setAttribute("aria-disabled","true"),this.label.classList.add("disabled")),(u=this.element)===null||u===void 0||u.classList.add("disabled"))}updateChecked(){this.label&&(this.getAction().checked?this.label.classList.add("checked"):this.label.classList.remove("checked"))}}},45933:(rt,ye,y)=>{y.d(ye,{E6:()=>T,Hw:()=>$,YN:()=>K,b2:()=>o,gf:()=>U,n9:()=>P,oq:()=>L,tu:()=>p,vp:()=>B});var b=y(3765),o;(function(d){d.noSelection=b.kg("noSelection","No selection"),d.singleSelectionRange=b.kg("singleSelectionRange","Line {0}, Column {1} ({2} selected)"),d.singleSelection=b.kg("singleSelection","Line {0}, Column {1}"),d.multiSelectionRange=b.kg("multiSelectionRange","{0} selections ({1} characters selected)"),d.multiSelection=b.kg("multiSelection","{0} selections"),d.emergencyConfOn=b.kg("emergencyConfOn","Now changing the setting `accessibilitySupport` to 'on'."),d.openingDocs=b.kg("openingDocs","Now opening the Editor Accessibility documentation page."),d.readonlyDiffEditor=b.kg("readonlyDiffEditor"," in a read-only pane of a diff editor."),d.editableDiffEditor=b.kg("editableDiffEditor"," in a pane of a diff editor."),d.readonlyEditor=b.kg("readonlyEditor"," in a read-only code editor"),d.editableEditor=b.kg("editableEditor"," in a code editor"),d.changeConfigToOnMac=b.kg("changeConfigToOnMac","To configure the editor to be optimized for usage with a Screen Reader press Command+E now."),d.changeConfigToOnWinLinux=b.kg("changeConfigToOnWinLinux","To configure the editor to be optimized for usage with a Screen Reader press Control+E now."),d.auto_on=b.kg("auto_on","The editor is configured to be optimized for usage with a Screen Reader."),d.auto_off=b.kg("auto_off","The editor is configured to never be optimized for usage with a Screen Reader, which is not the case at this time."),d.tabFocusModeOnMsg=b.kg("tabFocusModeOnMsg","Pressing Tab in the current editor will move focus to the next focusable element. Toggle this behavior by pressing {0}."),d.tabFocusModeOnMsgNoKb=b.kg("tabFocusModeOnMsgNoKb","Pressing Tab in the current editor will move focus to the next focusable element. The command {0} is currently not triggerable by a keybinding."),d.tabFocusModeOffMsg=b.kg("tabFocusModeOffMsg","Pressing Tab in the current editor will insert the tab character. Toggle this behavior by pressing {0}."),d.tabFocusModeOffMsgNoKb=b.kg("tabFocusModeOffMsgNoKb","Pressing Tab in the current editor will insert the tab character. The command {0} is currently not triggerable by a keybinding."),d.openDocMac=b.kg("openDocMac","Press Command+H now to open a browser window with more information related to editor accessibility."),d.openDocWinLinux=b.kg("openDocWinLinux","Press Control+H now to open a browser window with more information related to editor accessibility."),d.outroMsg=b.kg("outroMsg","You can dismiss this tooltip and return to the editor by pressing Escape or Shift+Escape."),d.showAccessibilityHelpAction=b.kg("showAccessibilityHelpAction","Show Accessibility Help")})(o||(o={}));var K;(function(d){d.inspectTokensAction=b.kg("inspectTokens","Developer: Inspect Tokens")})(K||(K={}));var $;(function(d){d.gotoLineActionLabel=b.kg("gotoLineActionLabel","Go to Line/Column...")})($||($={}));var L;(function(d){d.helpQuickAccessActionLabel=b.kg("helpQuickAccess","Show all Quick Access Providers")})(L||(L={}));var U;(function(d){d.quickCommandActionLabel=b.kg("quickCommandActionLabel","Command Palette"),d.quickCommandHelp=b.kg("quickCommandActionHelp","Show And Run Commands")})(U||(U={}));var P;(function(d){d.quickOutlineActionLabel=b.kg("quickOutlineActionLabel","Go to Symbol..."),d.quickOutlineByCategoryActionLabel=b.kg("quickOutlineByCategoryActionLabel","Go to Symbol by Category...")})(P||(P={}));var B;(function(d){d.editorViewAccessibleLabel=b.kg("editorViewAccessibleLabel","Editor content"),d.accessibilityHelpMessage=b.kg("accessibilityHelpMessage","Press Alt+F1 for Accessibility Options.")})(B||(B={}));var T;(function(d){d.toggleHighContrast=b.kg("toggleHighContrast","Toggle High Contrast Theme")})(T||(T={}));var p;(function(d){d.bulkEditServiceSummary=b.kg("bulkEditServiceSummary","Made {0} edits in {1} files")})(p||(p={}))},46441:(rt,ye,y)=>{y.d(ye,{$b:()=>L,Cr:()=>B,Kc:()=>T,rr:()=>$});var b=y(2106),o=y(10998),K=y(82399);const $=(0,K.u1)("logService");var L;(function(p){p[p.Trace=0]="Trace",p[p.Debug=1]="Debug",p[p.Info=2]="Info",p[p.Warning=3]="Warning",p[p.Error=4]="Error",p[p.Critical=5]="Critical",p[p.Off=6]="Off"})(L||(L={}));const U=L.Info;class P extends o.jG{constructor(){super(...arguments),this.level=U,this._onDidChangeLogLevel=this._register(new b.vl)}setLevel(d){this.level!==d&&(this.level=d,this._onDidChangeLogLevel.fire(this.level))}getLevel(){return this.level}}class B extends P{constructor(d=U){super(),this.setLevel(d)}trace(d,...g){this.getLevel()<=L.Trace&&console.log("%cTRACE","color: #888",d,...g)}debug(d,...g){this.getLevel()<=L.Debug&&console.log("%cDEBUG","background: #eee; color: #888",d,...g)}info(d,...g){this.getLevel()<=L.Info&&console.log("%c INFO","color: #33f",d,...g)}error(d,...g){this.getLevel()<=L.Error&&console.log("%c ERR","color: #f33",d,...g)}dispose(){}}class T extends o.jG{constructor(d){super(),this.logger=d,this._register(d)}getLevel(){return this.logger.getLevel()}trace(d,...g){this.logger.trace(d,...g)}debug(d,...g){this.logger.debug(d,...g)}info(d,...g){this.logger.info(d,...g)}error(d,...g){this.logger.error(d,...g)}}},47317:(rt,ye,y)=>{y.d(ye,{$M:()=>U,HC:()=>B,Iu:()=>g,Kb:()=>d,WA:()=>p,dG:()=>C,gP:()=>h,lO:()=>l,ou:()=>L,qw:()=>T,r4:()=>w,rY:()=>P,uB:()=>u});var b=y(26048),o=y(37264),K=y(50442),$=y(72564);class L{constructor(v,k,D){this._tokenBrand=void 0,this.offset=v,this.type=k,this.language=D}toString(){return"("+this.offset+", "+this.type+")"}}class U{constructor(v,k){this._tokenizationResultBrand=void 0,this.tokens=v,this.endState=k}}class P{constructor(v,k){this._encodedTokenizationResultBrand=void 0,this.tokens=v,this.endState=k}}var B;(function(m){const v=new Map;v.set(0,b.W6.symbolMethod),v.set(1,b.W6.symbolFunction),v.set(2,b.W6.symbolConstructor),v.set(3,b.W6.symbolField),v.set(4,b.W6.symbolVariable),v.set(5,b.W6.symbolClass),v.set(6,b.W6.symbolStruct),v.set(7,b.W6.symbolInterface),v.set(8,b.W6.symbolModule),v.set(9,b.W6.symbolProperty),v.set(10,b.W6.symbolEvent),v.set(11,b.W6.symbolOperator),v.set(12,b.W6.symbolUnit),v.set(13,b.W6.symbolValue),v.set(15,b.W6.symbolEnum),v.set(14,b.W6.symbolConstant),v.set(15,b.W6.symbolEnum),v.set(16,b.W6.symbolEnumMember),v.set(17,b.W6.symbolKeyword),v.set(27,b.W6.symbolSnippet),v.set(18,b.W6.symbolText),v.set(19,b.W6.symbolColor),v.set(20,b.W6.symbolFile),v.set(21,b.W6.symbolReference),v.set(22,b.W6.symbolCustomColor),v.set(23,b.W6.symbolFolder),v.set(24,b.W6.symbolTypeParameter),v.set(25,b.W6.account),v.set(26,b.W6.issues);function k(A){let W=v.get(A);return W||(console.info("No codicon found for CompletionItemKind "+A),W=b.W6.symbolProperty),W}m.toIcon=k;const D=new Map;D.set("method",0),D.set("function",1),D.set("constructor",2),D.set("field",3),D.set("variable",4),D.set("class",5),D.set("struct",6),D.set("interface",7),D.set("module",8),D.set("property",9),D.set("event",10),D.set("operator",11),D.set("unit",12),D.set("value",13),D.set("constant",14),D.set("enum",15),D.set("enum-member",16),D.set("enumMember",16),D.set("keyword",17),D.set("snippet",27),D.set("text",18),D.set("color",19),D.set("file",20),D.set("reference",21),D.set("customcolor",22),D.set("folder",23),D.set("type-parameter",24),D.set("typeParameter",24),D.set("account",25),D.set("issue",26);function x(A,W){let Y=D.get(A);return typeof Y>"u"&&!W&&(Y=9),Y}m.fromString=x})(B||(B={}));var T;(function(m){m[m.Automatic=0]="Automatic",m[m.Explicit=1]="Explicit"})(T||(T={}));var p;(function(m){m[m.Invoke=1]="Invoke",m[m.TriggerCharacter=2]="TriggerCharacter",m[m.ContentChange=3]="ContentChange"})(p||(p={}));var d;(function(m){m[m.Text=0]="Text",m[m.Read=1]="Read",m[m.Write=2]="Write"})(d||(d={}));function g(m){return m&&o.r.isUri(m.uri)&&K.Q.isIRange(m.range)&&(K.Q.isIRange(m.originSelectionRange)||K.Q.isIRange(m.targetSelectionRange))}var h;(function(m){const v=new Map;v.set(0,b.W6.symbolFile),v.set(1,b.W6.symbolModule),v.set(2,b.W6.symbolNamespace),v.set(3,b.W6.symbolPackage),v.set(4,b.W6.symbolClass),v.set(5,b.W6.symbolMethod),v.set(6,b.W6.symbolProperty),v.set(7,b.W6.symbolField),v.set(8,b.W6.symbolConstructor),v.set(9,b.W6.symbolEnum),v.set(10,b.W6.symbolInterface),v.set(11,b.W6.symbolFunction),v.set(12,b.W6.symbolVariable),v.set(13,b.W6.symbolConstant),v.set(14,b.W6.symbolString),v.set(15,b.W6.symbolNumber),v.set(16,b.W6.symbolBoolean),v.set(17,b.W6.symbolArray),v.set(18,b.W6.symbolObject),v.set(19,b.W6.symbolKey),v.set(20,b.W6.symbolNull),v.set(21,b.W6.symbolEnumMember),v.set(22,b.W6.symbolStruct),v.set(23,b.W6.symbolEvent),v.set(24,b.W6.symbolOperator),v.set(25,b.W6.symbolTypeParameter);function k(D){let x=v.get(D);return x||(console.info("No codicon found for SymbolKind "+D),x=b.W6.symbolProperty),x}m.toIcon=k})(h||(h={}));class l{constructor(v){this.value=v}}l.Comment=new l("comment"),l.Imports=new l("imports"),l.Region=new l("region");var u;(function(m){function v(k){return!k||typeof k!="object"?!1:typeof k.id=="string"&&typeof k.title=="string"}m.is=v})(u||(u={}));var w;(function(m){m[m.Type=1]="Type",m[m.Parameter=2]="Parameter"})(w||(w={}));const C=new $.d},48295:(rt,ye,y)=>{y.d(ye,{$u:()=>A,AQ:()=>te,BD:()=>ke,Bo:()=>be,D0:()=>g,DH:()=>X,Ek:()=>R,I2:()=>pe,IW:()=>We,If:()=>ge,Ln:()=>j,Mf:()=>P,P1:()=>$e,Pe:()=>he,Qt:()=>C,RH:()=>H,RU:()=>x,WD:()=>Pe,WS:()=>Ae,WY:()=>it,Xr:()=>Y,aZ:()=>O,bB:()=>Ge,fj:()=>w,ik:()=>k,kG:()=>U,kM:()=>h,l5:()=>Qe,lQ:()=>ue,n4:()=>ce,pw:()=>v,s7:()=>Me,sH:()=>Ke,sN:()=>oe,ss:()=>E,v0:()=>u,vp:()=>N,x9:()=>W,yI:()=>G,yw:()=>Q,zp:()=>Se});var b=y(3765),o=y(94901),K=y(4874),$=y(89044),L=y(89563);const U=(0,K.x1A)("editor.lineHighlightBackground",{dark:null,light:null,hcDark:null,hcLight:null},b.kg("lineHighlight","Background color for the highlight of line at the cursor position.")),P=(0,K.x1A)("editor.lineHighlightBorder",{dark:"#282828",light:"#eeeeee",hcDark:"#f38518",hcLight:K.b1q},b.kg("lineHighlightBorderBox","Background color for the border around the line at the cursor position.")),B=(0,K.x1A)("editor.rangeHighlightBackground",{dark:"#ffffff0b",light:"#fdff0033",hcDark:null,hcLight:null},b.kg("rangeHighlight","Background color of highlighted ranges, like by quick open and find features. The color must not be opaque so as not to hide underlying decorations."),!0),T=(0,K.x1A)("editor.rangeHighlightBorder",{dark:null,light:null,hcDark:K.buw,hcLight:K.buw},b.kg("rangeHighlightBorder","Background color of the border around highlighted ranges."),!0),p=(0,K.x1A)("editor.symbolHighlightBackground",{dark:K.Ubg,light:K.Ubg,hcDark:null,hcLight:null},b.kg("symbolHighlight","Background color of highlighted symbol, like for go to definition or go next/previous symbol. The color must not be opaque so as not to hide underlying decorations."),!0),d=(0,K.x1A)("editor.symbolHighlightBorder",{dark:null,light:null,hcDark:K.buw,hcLight:K.buw},b.kg("symbolHighlightBorder","Background color of the border around highlighted symbols."),!0),g=(0,K.x1A)("editorCursor.foreground",{dark:"#AEAFAD",light:o.Q1.black,hcDark:o.Q1.white,hcLight:"#0F4A85"},b.kg("caret","Color of the editor cursor.")),h=(0,K.x1A)("editorCursor.background",null,b.kg("editorCursorBackground","The background color of the editor cursor. Allows customizing the color of a character overlapped by a block cursor.")),l=(0,K.x1A)("editorWhitespace.foreground",{dark:"#e3e4e229",light:"#33333333",hcDark:"#e3e4e229",hcLight:"#CCCCCC"},b.kg("editorWhitespaces","Color of whitespace characters in the editor.")),u=(0,K.x1A)("editorIndentGuide.background",{dark:l,light:l,hcDark:l,hcLight:l},b.kg("editorIndentGuides","Color of the editor indentation guides.")),w=(0,K.x1A)("editorIndentGuide.activeBackground",{dark:l,light:l,hcDark:l,hcLight:l},b.kg("editorActiveIndentGuide","Color of the active editor indentation guides.")),C=(0,K.x1A)("editorLineNumber.foreground",{dark:"#858585",light:"#237893",hcDark:o.Q1.white,hcLight:"#292929"},b.kg("editorLineNumbers","Color of editor line numbers.")),m=(0,K.x1A)("editorActiveLineNumber.foreground",{dark:"#c6c6c6",light:"#0B216F",hcDark:K.buw,hcLight:K.buw},b.kg("editorActiveLineNumber","Color of editor active line number"),!1,b.kg("deprecatedEditorActiveLineNumber","Id is deprecated. Use 'editorLineNumber.activeForeground' instead.")),v=(0,K.x1A)("editorLineNumber.activeForeground",{dark:m,light:m,hcDark:m,hcLight:m},b.kg("editorActiveLineNumber","Color of editor active line number")),k=(0,K.x1A)("editorRuler.foreground",{dark:"#5A5A5A",light:o.Q1.lightgrey,hcDark:o.Q1.white,hcLight:"#292929"},b.kg("editorRuler","Color of the editor rulers.")),D=(0,K.x1A)("editorCodeLens.foreground",{dark:"#999999",light:"#919191",hcDark:"#999999",hcLight:"#292929"},b.kg("editorCodeLensForeground","Foreground color of editor CodeLens")),x=(0,K.x1A)("editorBracketMatch.background",{dark:"#0064001a",light:"#0064001a",hcDark:"#0064001a",hcLight:"#0000"},b.kg("editorBracketMatchBackground","Background color behind matching brackets")),A=(0,K.x1A)("editorBracketMatch.border",{dark:"#888",light:"#B9B9B9",hcDark:K.b1q,hcLight:K.b1q},b.kg("editorBracketMatchBorder","Color for matching brackets boxes")),W=(0,K.x1A)("editorOverviewRuler.border",{dark:"#7f7f7f4d",light:"#7f7f7f4d",hcDark:"#7f7f7f4d",hcLight:"#666666"},b.kg("editorOverviewRulerBorder","Color of the overview ruler border.")),Y=(0,K.x1A)("editorOverviewRuler.background",null,b.kg("editorOverviewRulerBackground","Background color of the editor overview ruler. Only used when the minimap is enabled and placed on the right side of the editor.")),ne=(0,K.x1A)("editorGutter.background",{dark:K.YtV,light:K.YtV,hcDark:K.YtV,hcLight:K.YtV},b.kg("editorGutter","Background color of the editor gutter. The gutter contains the glyph margins and the line numbers.")),j=(0,K.x1A)("editorUnnecessaryCode.border",{dark:null,light:null,hcDark:o.Q1.fromHex("#fff").transparent(.8),hcLight:K.b1q},b.kg("unnecessaryCodeBorder","Border color of unnecessary (unused) source code in the editor.")),Q=(0,K.x1A)("editorUnnecessaryCode.opacity",{dark:o.Q1.fromHex("#000a"),light:o.Q1.fromHex("#0007"),hcDark:null,hcLight:null},b.kg("unnecessaryCodeOpacity",`Opacity of unnecessary (unused) source code in the editor. For example, "#000000c0" will render the code with 75% opacity. For high contrast themes, use the 'editorUnnecessaryCode.border' theme color to underline unnecessary code instead of fading it out.`)),X=(0,K.x1A)("editorGhostText.border",{dark:null,light:null,hcDark:o.Q1.fromHex("#fff").transparent(.8),hcLight:o.Q1.fromHex("#292929").transparent(.8)},b.kg("editorGhostTextBorder","Border color of ghost text in the editor.")),R=(0,K.x1A)("editorGhostText.foreground",{dark:o.Q1.fromHex("#ffffff56"),light:o.Q1.fromHex("#0007"),hcDark:null,hcLight:null},b.kg("editorGhostTextForeground","Foreground color of the ghost text in the editor.")),H=(0,K.x1A)("editorGhostText.background",{dark:null,light:null,hcDark:null,hcLight:null},b.kg("editorGhostTextBackground","Background color of the ghost text in the editor.")),Z=new o.Q1(new o.bU(0,122,204,.6)),N=(0,K.x1A)("editorOverviewRuler.rangeHighlightForeground",{dark:Z,light:Z,hcDark:Z,hcLight:Z},b.kg("overviewRulerRangeHighlight","Overview ruler marker color for range highlights. The color must not be opaque so as not to hide underlying decorations."),!0),G=(0,K.x1A)("editorOverviewRuler.errorForeground",{dark:new o.Q1(new o.bU(255,18,18,.7)),light:new o.Q1(new o.bU(255,18,18,.7)),hcDark:new o.Q1(new o.bU(255,50,50,1)),hcLight:"#B5200D"},b.kg("overviewRuleError","Overview ruler marker color for errors.")),O=(0,K.x1A)("editorOverviewRuler.warningForeground",{dark:K.Hng,light:K.Hng,hcDark:K.Stt,hcLight:K.Stt},b.kg("overviewRuleWarning","Overview ruler marker color for warnings.")),te=(0,K.x1A)("editorOverviewRuler.infoForeground",{dark:K.pOz,light:K.pOz,hcDark:K.IIb,hcLight:K.IIb},b.kg("overviewRuleInfo","Overview ruler marker color for infos.")),oe=(0,K.x1A)("editorBracketHighlight.foreground1",{dark:"#FFD700",light:"#0431FAFF",hcDark:"#FFD700",hcLight:"#0431FAFF"},b.kg("editorBracketHighlightForeground1","Foreground color of brackets (1). Requires enabling bracket pair colorization.")),ue=(0,K.x1A)("editorBracketHighlight.foreground2",{dark:"#DA70D6",light:"#319331FF",hcDark:"#DA70D6",hcLight:"#319331FF"},b.kg("editorBracketHighlightForeground2","Foreground color of brackets (2). Requires enabling bracket pair colorization.")),E=(0,K.x1A)("editorBracketHighlight.foreground3",{dark:"#179FFF",light:"#7B3814FF",hcDark:"#87CEFA",hcLight:"#7B3814FF"},b.kg("editorBracketHighlightForeground3","Foreground color of brackets (3). Requires enabling bracket pair colorization.")),Qe=(0,K.x1A)("editorBracketHighlight.foreground4",{dark:"#00000000",light:"#00000000",hcDark:"#00000000",hcLight:"#00000000"},b.kg("editorBracketHighlightForeground4","Foreground color of brackets (4). Requires enabling bracket pair colorization.")),Ke=(0,K.x1A)("editorBracketHighlight.foreground5",{dark:"#00000000",light:"#00000000",hcDark:"#00000000",hcLight:"#00000000"},b.kg("editorBracketHighlightForeground5","Foreground color of brackets (5). Requires enabling bracket pair colorization.")),Se=(0,K.x1A)("editorBracketHighlight.foreground6",{dark:"#00000000",light:"#00000000",hcDark:"#00000000",hcLight:"#00000000"},b.kg("editorBracketHighlightForeground6","Foreground color of brackets (6). Requires enabling bracket pair colorization.")),Me=(0,K.x1A)("editorBracketHighlight.unexpectedBracket.foreground",{dark:new o.Q1(new o.bU(255,18,18,.8)),light:new o.Q1(new o.bU(255,18,18,.8)),hcDark:new o.Q1(new o.bU(255,50,50,1)),hcLight:""},b.kg("editorBracketHighlightUnexpectedBracketForeground","Foreground color of unexpected brackets.")),ce=(0,K.x1A)("editorBracketPairGuide.background1",{dark:"#00000000",light:"#00000000",hcDark:"#00000000",hcLight:"#00000000"},b.kg("editorBracketPairGuide.background1","Background color of inactive bracket pair guides (1). Requires enabling bracket pair guides.")),pe=(0,K.x1A)("editorBracketPairGuide.background2",{dark:"#00000000",light:"#00000000",hcDark:"#00000000",hcLight:"#00000000"},b.kg("editorBracketPairGuide.background2","Background color of inactive bracket pair guides (2). Requires enabling bracket pair guides.")),be=(0,K.x1A)("editorBracketPairGuide.background3",{dark:"#00000000",light:"#00000000",hcDark:"#00000000",hcLight:"#00000000"},b.kg("editorBracketPairGuide.background3","Background color of inactive bracket pair guides (3). Requires enabling bracket pair guides.")),ge=(0,K.x1A)("editorBracketPairGuide.background4",{dark:"#00000000",light:"#00000000",hcDark:"#00000000",hcLight:"#00000000"},b.kg("editorBracketPairGuide.background4","Background color of inactive bracket pair guides (4). Requires enabling bracket pair guides.")),ke=(0,K.x1A)("editorBracketPairGuide.background5",{dark:"#00000000",light:"#00000000",hcDark:"#00000000",hcLight:"#00000000"},b.kg("editorBracketPairGuide.background5","Background color of inactive bracket pair guides (5). Requires enabling bracket pair guides.")),We=(0,K.x1A)("editorBracketPairGuide.background6",{dark:"#00000000",light:"#00000000",hcDark:"#00000000",hcLight:"#00000000"},b.kg("editorBracketPairGuide.background6","Background color of inactive bracket pair guides (6). Requires enabling bracket pair guides.")),Ge=(0,K.x1A)("editorBracketPairGuide.activeBackground1",{dark:"#00000000",light:"#00000000",hcDark:"#00000000",hcLight:"#00000000"},b.kg("editorBracketPairGuide.activeBackground1","Background color of active bracket pair guides (1). Requires enabling bracket pair guides.")),Ae=(0,K.x1A)("editorBracketPairGuide.activeBackground2",{dark:"#00000000",light:"#00000000",hcDark:"#00000000",hcLight:"#00000000"},b.kg("editorBracketPairGuide.activeBackground2","Background color of active bracket pair guides (2). Requires enabling bracket pair guides.")),he=(0,K.x1A)("editorBracketPairGuide.activeBackground3",{dark:"#00000000",light:"#00000000",hcDark:"#00000000",hcLight:"#00000000"},b.kg("editorBracketPairGuide.activeBackground3","Background color of active bracket pair guides (3). Requires enabling bracket pair guides.")),Pe=(0,K.x1A)("editorBracketPairGuide.activeBackground4",{dark:"#00000000",light:"#00000000",hcDark:"#00000000",hcLight:"#00000000"},b.kg("editorBracketPairGuide.activeBackground4","Background color of active bracket pair guides (4). Requires enabling bracket pair guides.")),$e=(0,K.x1A)("editorBracketPairGuide.activeBackground5",{dark:"#00000000",light:"#00000000",hcDark:"#00000000",hcLight:"#00000000"},b.kg("editorBracketPairGuide.activeBackground5","Background color of active bracket pair guides (5). Requires enabling bracket pair guides.")),it=(0,K.x1A)("editorBracketPairGuide.activeBackground6",{dark:"#00000000",light:"#00000000",hcDark:"#00000000",hcLight:"#00000000"},b.kg("editorBracketPairGuide.activeBackground6","Background color of active bracket pair guides (6). Requires enabling bracket pair guides.")),ft=(0,K.x1A)("editorUnicodeHighlight.border",{dark:"#BD9B03",light:"#CEA33D",hcDark:"#ff0000",hcLight:""},b.kg("editorUnicodeHighlight.border","Border color used to highlight unicode characters.")),Wt=(0,K.x1A)("editorUnicodeHighlight.background",{dark:"#bd9b0326",light:"#cea33d14",hcDark:"#00000000",hcLight:""},b.kg("editorUnicodeHighlight.background","Background color used to highlight unicode characters."));(0,$.zy)((tt,Ye)=>{const ht=tt.getColor(K.YtV);ht&&Ye.addRule(`.monaco-editor, .monaco-editor-background { background-color: ${ht}; }`);const Lt=tt.getColor(U),Rt=Lt&&!Lt.isTransparent()?Lt:ht;Rt&&Ye.addRule(`.monaco-editor .inputarea.ime-input { background-color: ${Rt}; }`);const Ie=tt.getColor(K.By2);Ie&&Ye.addRule(`.monaco-editor, .monaco-editor .inputarea.ime-input { color: ${Ie}; }`);const Ve=tt.getColor(ne);Ve&&Ye.addRule(`.monaco-editor .margin { background-color: ${Ve}; }`);const dt=tt.getColor(B);dt&&Ye.addRule(`.monaco-editor .rangeHighlight { background-color: ${dt}; }`);const bt=tt.getColor(T);bt&&Ye.addRule(`.monaco-editor .rangeHighlight { border: 1px ${(0,L.Bb)(tt.type)?"dotted":"solid"} ${bt}; }`);const Mt=tt.getColor(p);Mt&&Ye.addRule(`.monaco-editor .symbolHighlight { background-color: ${Mt}; }`);const Yt=tt.getColor(d);Yt&&Ye.addRule(`.monaco-editor .symbolHighlight { border: 1px ${(0,L.Bb)(tt.type)?"dotted":"solid"} ${Yt}; }`);const Nt=tt.getColor(l);Nt&&(Ye.addRule(`.monaco-editor .mtkw { color: ${Nt} !important; }`),Ye.addRule(`.monaco-editor .mtkz { color: ${Nt} !important; }`))})},49233:(rt,ye,y)=>{y.d(ye,{x:()=>U});var b=y(14333),o=y(94901),K=y(71386),$=y(16844);const L={badgeBackground:o.Q1.fromHex("#4D4D4D"),badgeForeground:o.Q1.fromHex("#FFFFFF")};class U{constructor(B,T){this.count=0,this.options=T||Object.create(null),(0,K.co)(this.options,L,!1),this.badgeBackground=this.options.badgeBackground,this.badgeForeground=this.options.badgeForeground,this.badgeBorder=this.options.badgeBorder,this.element=(0,b.BC)(B,(0,b.$)(".monaco-count-badge")),this.countFormat=this.options.countFormat||"{0}",this.titleFormat=this.options.titleFormat||"",this.setCount(this.options.count||0)}setCount(B){this.count=B,this.render()}setTitleFormat(B){this.titleFormat=B,this.render()}render(){this.element.textContent=(0,$.GP)(this.countFormat,this.count),this.element.title=(0,$.GP)(this.titleFormat,this.count),this.applyStyles()}style(B){this.badgeBackground=B.badgeBackground,this.badgeForeground=B.badgeForeground,this.badgeBorder=B.badgeBorder,this.applyStyles()}applyStyles(){if(this.element){const B=this.badgeBackground?this.badgeBackground.toString():"",T=this.badgeForeground?this.badgeForeground.toString():"",p=this.badgeBorder?this.badgeBorder.toString():"";this.element.style.backgroundColor=B,this.element.style.color=T,this.element.style.borderWidth=p?"1px":"",this.element.style.borderStyle=p?"solid":"",this.element.style.borderColor=p}}}},49550:(rt,ye,y)=>{y.d(ye,{GB:()=>K,i3:()=>o,l:()=>b});var b;(function(L){L[L.None=0]="None",L[L.Indent=1]="Indent",L[L.IndentOutdent=2]="IndentOutdent",L[L.Outdent=3]="Outdent"})(b||(b={}));class o{constructor(U){if(this._neutralCharacter=null,this._neutralCharacterSearched=!1,this.open=U.open,this.close=U.close,this._inString=!0,this._inComment=!0,this._inRegEx=!0,Array.isArray(U.notIn))for(let P=0,B=U.notIn.length;P<B;P++)switch(U.notIn[P]){case"string":this._inString=!1;break;case"comment":this._inComment=!1;break;case"regex":this._inRegEx=!1;break}}isOK(U){switch(U){case 0:return!0;case 1:return this._inComment;case 2:return this._inString;case 3:return this._inRegEx}}shouldAutoClose(U,P){if(U.getTokenCount()===0)return!0;const B=U.findTokenIndexAtOffset(P-2),T=U.getStandardTokenType(B);return this.isOK(T)}_findNeutralCharacterInRange(U,P){for(let B=U;B<=P;B++){const T=String.fromCharCode(B);if(!this.open.includes(T)&&!this.close.includes(T))return T}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}}class K{constructor(U){this.autoClosingPairsOpenByStart=new Map,this.autoClosingPairsOpenByEnd=new Map,this.autoClosingPairsCloseByStart=new Map,this.autoClosingPairsCloseByEnd=new Map,this.autoClosingPairsCloseSingleChar=new Map;for(const P of U)$(this.autoClosingPairsOpenByStart,P.open.charAt(0),P),$(this.autoClosingPairsOpenByEnd,P.open.charAt(P.open.length-1),P),$(this.autoClosingPairsCloseByStart,P.close.charAt(0),P),$(this.autoClosingPairsCloseByEnd,P.close.charAt(P.close.length-1),P),P.close.length===1&&P.open.length===1&&$(this.autoClosingPairsCloseSingleChar,P.close,P)}}function $(L,U,P){L.has(U)?L.get(U).push(P):L.set(U,[P])}},50180:(rt,ye,y)=>{y.d(ye,{q:()=>K});var b=y(42802),o=y(37264);function K(L){let U=JSON.parse(L);return U=$(U),U}function $(L,U=0){if(!L||U>200)return L;if(typeof L=="object"){switch(L.$mid){case 1:return o.r.revive(L);case 2:return new RegExp(L.source,L.flags);case 14:return new Date(L.source)}if(L instanceof b.MB||L instanceof Uint8Array)return L;if(Array.isArray(L))for(let P=0;P<L.length;++P)L[P]=$(L[P],U+1);else for(const P in L)Object.hasOwnProperty.call(L,P)&&(L[P]=$(L[P],U+1))}return L}},50350:(rt,ye,y)=>{y.d(ye,{HJ:()=>T,LN:()=>U,YH:()=>B,ih:()=>p,rc:()=>L,wv:()=>P});var b=y(2106),o=y(10998),K=y(3765),$=function(d,g,h,l){function u(w){return w instanceof h?w:new h(function(C){C(w)})}return new(h||(h=Promise))(function(w,C){function m(D){try{k(l.next(D))}catch(x){C(x)}}function v(D){try{k(l.throw(D))}catch(x){C(x)}}function k(D){D.done?w(D.value):u(D.value).then(m,v)}k((l=l.apply(d,g||[])).next())})};class L extends o.jG{constructor(g,h="",l="",u=!0,w){super(),this._onDidChange=this._register(new b.vl),this.onDidChange=this._onDidChange.event,this._enabled=!0,this._id=g,this._label=h,this._cssClass=l,this._enabled=u,this._actionCallback=w}get id(){return this._id}get label(){return this._label}set label(g){this._setLabel(g)}_setLabel(g){this._label!==g&&(this._label=g,this._onDidChange.fire({label:g}))}get tooltip(){return this._tooltip||""}set tooltip(g){this._setTooltip(g)}_setTooltip(g){this._tooltip!==g&&(this._tooltip=g,this._onDidChange.fire({tooltip:g}))}get class(){return this._cssClass}set class(g){this._setClass(g)}_setClass(g){this._cssClass!==g&&(this._cssClass=g,this._onDidChange.fire({class:g}))}get enabled(){return this._enabled}set enabled(g){this._setEnabled(g)}_setEnabled(g){this._enabled!==g&&(this._enabled=g,this._onDidChange.fire({enabled:g}))}get checked(){return this._checked}set checked(g){this._setChecked(g)}_setChecked(g){this._checked!==g&&(this._checked=g,this._onDidChange.fire({checked:g}))}run(g,h){return $(this,void 0,void 0,function*(){this._actionCallback&&(yield this._actionCallback(g))})}}class U extends o.jG{constructor(){super(...arguments),this._onBeforeRun=this._register(new b.vl),this.onBeforeRun=this._onBeforeRun.event,this._onDidRun=this._register(new b.vl),this.onDidRun=this._onDidRun.event}run(g,h){return $(this,void 0,void 0,function*(){if(!g.enabled)return;this._onBeforeRun.fire({action:g});let l;try{yield this.runAction(g,h)}catch(u){l=u}this._onDidRun.fire({action:g,error:l})})}runAction(g,h){return $(this,void 0,void 0,function*(){yield g.run(h)})}}class P extends L{constructor(g){super(P.ID,g,g?"separator text":"separator"),this.checked=!1,this.enabled=!1}}P.ID="vs.actions.separator";class B{constructor(g,h,l,u){this.tooltip="",this.enabled=!0,this.checked=void 0,this.id=g,this.label=h,this.class=u,this._actions=l}get actions(){return this._actions}dispose(){}run(){return $(this,void 0,void 0,function*(){})}}class T extends L{constructor(){super(T.ID,K.kg("submenu.empty","(empty)"),void 0,!1)}}T.ID="vs.actions.empty";function p(d){var g,h;return{id:d.id,label:d.label,class:void 0,enabled:(g=d.enabled)!==null&&g!==void 0?g:!0,checked:(h=d.checked)!==null&&h!==void 0?h:!1,run:()=>$(this,void 0,void 0,function*(){return d.run()}),tooltip:d.label,dispose:()=>{}}}},50572:(rt,ye,y)=>{y.d(ye,{I:()=>B});var b=y(29895),o=y(62549),K=y(15365),$=y(50442),L=y(16844),U=y(71937);class P{constructor(p,d,g){this._cursorPositionBrand=void 0,this.lineNumber=p,this.column=d,this.leftoverVisibleColumns=g}}class B{static leftPosition(p,d){if(d.column>p.getLineMinColumn(d.lineNumber))return d.delta(void 0,-L.MV(p.getLineContent(d.lineNumber),d.column-1));if(d.lineNumber>1){const g=d.lineNumber-1;return new K.y(g,p.getLineMaxColumn(g))}else return d}static leftPositionAtomicSoftTabs(p,d,g){if(d.column<=p.getLineIndentColumn(d.lineNumber)){const h=p.getLineMinColumn(d.lineNumber),l=p.getLineContent(d.lineNumber),u=U.s.atomicPosition(l,d.column-1,g,0);if(u!==-1&&u+1>=h)return new K.y(d.lineNumber,u+1)}return this.leftPosition(p,d)}static left(p,d,g){const h=p.stickyTabStops?B.leftPositionAtomicSoftTabs(d,g,p.tabSize):B.leftPosition(d,g);return new P(h.lineNumber,h.column,0)}static moveLeft(p,d,g,h,l){let u,w;if(g.hasSelection()&&!h)u=g.selection.startLineNumber,w=g.selection.startColumn;else{const C=g.position.delta(void 0,-(l-1)),m=d.normalizePosition(B.clipPositionColumn(C,d),0),v=B.left(p,d,m);u=v.lineNumber,w=v.column}return g.move(h,u,w,0)}static clipPositionColumn(p,d){return new K.y(p.lineNumber,B.clipRange(p.column,d.getLineMinColumn(p.lineNumber),d.getLineMaxColumn(p.lineNumber)))}static clipRange(p,d,g){return p<d?d:p>g?g:p}static rightPosition(p,d,g){return g<p.getLineMaxColumn(d)?g=g+L.iy(p.getLineContent(d),g-1):d<p.getLineCount()&&(d=d+1,g=p.getLineMinColumn(d)),new K.y(d,g)}static rightPositionAtomicSoftTabs(p,d,g,h,l){if(g<p.getLineIndentColumn(d)){const u=p.getLineContent(d),w=U.s.atomicPosition(u,g-1,h,1);if(w!==-1)return new K.y(d,w+1)}return this.rightPosition(p,d,g)}static right(p,d,g){const h=p.stickyTabStops?B.rightPositionAtomicSoftTabs(d,g.lineNumber,g.column,p.tabSize,p.indentSize):B.rightPosition(d,g.lineNumber,g.column);return new P(h.lineNumber,h.column,0)}static moveRight(p,d,g,h,l){let u,w;if(g.hasSelection()&&!h)u=g.selection.endLineNumber,w=g.selection.endColumn;else{const C=g.position.delta(void 0,l-1),m=d.normalizePosition(B.clipPositionColumn(C,d),1),v=B.right(p,d,m);u=v.lineNumber,w=v.column}return g.move(h,u,w,0)}static vertical(p,d,g,h,l,u,w,C){const m=o.A.visibleColumnFromColumn(d.getLineContent(g),h,p.tabSize)+l,v=d.getLineCount(),k=g===1&&h===1,D=g===v&&h===d.getLineMaxColumn(g),x=u<g?k:D;if(g=u,g<1?(g=1,w?h=d.getLineMinColumn(g):h=Math.min(d.getLineMaxColumn(g),h)):g>v?(g=v,w?h=d.getLineMaxColumn(g):h=Math.min(d.getLineMaxColumn(g),h)):h=p.columnFromVisibleColumn(d,g,m),x?l=0:l=m-o.A.visibleColumnFromColumn(d.getLineContent(g),h,p.tabSize),C!==void 0){const A=new K.y(g,h),W=d.normalizePosition(A,C);l=l+(h-W.column),g=W.lineNumber,h=W.column}return new P(g,h,l)}static down(p,d,g,h,l,u,w){return this.vertical(p,d,g,h,l,g+u,w,4)}static moveDown(p,d,g,h,l){let u,w;g.hasSelection()&&!h?(u=g.selection.endLineNumber,w=g.selection.endColumn):(u=g.position.lineNumber,w=g.position.column);const C=B.down(p,d,u,w,g.leftoverVisibleColumns,l,!0);return g.move(h,C.lineNumber,C.column,C.leftoverVisibleColumns)}static translateDown(p,d,g){const h=g.selection,l=B.down(p,d,h.selectionStartLineNumber,h.selectionStartColumn,g.selectionStartLeftoverVisibleColumns,1,!1),u=B.down(p,d,h.positionLineNumber,h.positionColumn,g.leftoverVisibleColumns,1,!1);return new b.mG(new $.Q(l.lineNumber,l.column,l.lineNumber,l.column),l.leftoverVisibleColumns,new K.y(u.lineNumber,u.column),u.leftoverVisibleColumns)}static up(p,d,g,h,l,u,w){return this.vertical(p,d,g,h,l,g-u,w,3)}static moveUp(p,d,g,h,l){let u,w;g.hasSelection()&&!h?(u=g.selection.startLineNumber,w=g.selection.startColumn):(u=g.position.lineNumber,w=g.position.column);const C=B.up(p,d,u,w,g.leftoverVisibleColumns,l,!0);return g.move(h,C.lineNumber,C.column,C.leftoverVisibleColumns)}static translateUp(p,d,g){const h=g.selection,l=B.up(p,d,h.selectionStartLineNumber,h.selectionStartColumn,g.selectionStartLeftoverVisibleColumns,1,!1),u=B.up(p,d,h.positionLineNumber,h.positionColumn,g.leftoverVisibleColumns,1,!1);return new b.mG(new $.Q(l.lineNumber,l.column,l.lineNumber,l.column),l.leftoverVisibleColumns,new K.y(u.lineNumber,u.column),u.leftoverVisibleColumns)}static _isBlankLine(p,d){return p.getLineFirstNonWhitespaceColumn(d)===0}static moveToPrevBlankLine(p,d,g,h){let l=g.position.lineNumber;for(;l>1&&this._isBlankLine(d,l);)l--;for(;l>1&&!this._isBlankLine(d,l);)l--;return g.move(h,l,d.getLineMinColumn(l),0)}static moveToNextBlankLine(p,d,g,h){const l=d.getLineCount();let u=g.position.lineNumber;for(;u<l&&this._isBlankLine(d,u);)u++;for(;u<l&&!this._isBlankLine(d,u);)u++;return g.move(h,u,d.getLineMinColumn(u),0)}static moveToBeginningOfLine(p,d,g,h){const l=g.position.lineNumber,u=d.getLineMinColumn(l),w=d.getLineFirstNonWhitespaceColumn(l)||u;let C;return g.position.column===w?C=u:C=w,g.move(h,l,C,0)}static moveToEndOfLine(p,d,g,h,l){const u=g.position.lineNumber,w=d.getLineMaxColumn(u);return g.move(h,u,w,l?1073741824-w:0)}static moveToBeginningOfBuffer(p,d,g,h){return g.move(h,1,1,0)}static moveToEndOfBuffer(p,d,g,h){const l=d.getLineCount(),u=d.getLineMaxColumn(l);return g.move(h,l,u,0)}}},50585:(rt,ye,y)=>{y.d(ye,{l:()=>U});var b=y(45222),o=y(26048),K=y(94901),$=y(2106);const L={inputActiveOptionBorder:K.Q1.fromHex("#007ACC00"),inputActiveOptionForeground:K.Q1.fromHex("#FFFFFF"),inputActiveOptionBackground:K.Q1.fromHex("#0E639C50")};class U extends b.x{constructor(B){super(),this._onChange=this._register(new $.vl),this.onChange=this._onChange.event,this._onKeyDown=this._register(new $.vl),this.onKeyDown=this._onKeyDown.event,this._opts=Object.assign(Object.assign({},L),B),this._checked=this._opts.isChecked;const T=["monaco-custom-toggle"];this._opts.icon&&(this._icon=this._opts.icon,T.push(...o.j3.asClassNameArray(this._icon))),this._opts.actionClassName&&T.push(...this._opts.actionClassName.split(" ")),this._checked&&T.push("checked"),this.domNode=document.createElement("div"),this.domNode.title=this._opts.title,this.domNode.classList.add(...T),this._opts.notFocusable||(this.domNode.tabIndex=0),this.domNode.setAttribute("role","checkbox"),this.domNode.setAttribute("aria-checked",String(this._checked)),this.domNode.setAttribute("aria-label",this._opts.title),this.applyStyles(),this.onclick(this.domNode,p=>{this.enabled&&(this.checked=!this._checked,this._onChange.fire(!1),p.preventDefault())}),this.ignoreGesture(this.domNode),this.onkeydown(this.domNode,p=>{if(p.keyCode===10||p.keyCode===3){this.checked=!this._checked,this._onChange.fire(!0),p.preventDefault(),p.stopPropagation();return}this._onKeyDown.fire(p)})}get enabled(){return this.domNode.getAttribute("aria-disabled")!=="true"}focus(){this.domNode.focus()}get checked(){return this._checked}set checked(B){this._checked=B,this.domNode.setAttribute("aria-checked",String(this._checked)),this.domNode.classList.toggle("checked",this._checked),this.applyStyles()}width(){return 22}style(B){B.inputActiveOptionBorder&&(this._opts.inputActiveOptionBorder=B.inputActiveOptionBorder),B.inputActiveOptionForeground&&(this._opts.inputActiveOptionForeground=B.inputActiveOptionForeground),B.inputActiveOptionBackground&&(this._opts.inputActiveOptionBackground=B.inputActiveOptionBackground),this.applyStyles()}applyStyles(){this.domNode&&(this.domNode.style.borderColor=this._checked&&this._opts.inputActiveOptionBorder?this._opts.inputActiveOptionBorder.toString():"",this.domNode.style.color=this._checked&&this._opts.inputActiveOptionForeground?this._opts.inputActiveOptionForeground.toString():"inherit",this.domNode.style.backgroundColor=this._checked&&this._opts.inputActiveOptionBackground?this._opts.inputActiveOptionBackground.toString():"")}enable(){this.domNode.setAttribute("aria-disabled",String(!1))}disable(){this.domNode.setAttribute("aria-disabled",String(!0))}}},50946:(rt,ye,y)=>{y.d(ye,{DX:()=>v,E_:()=>A,Fl:()=>W,HW:()=>j,PF:()=>D,aU:()=>Z,dS:()=>Q,fE:()=>C,gW:()=>Y,ih:()=>N,ke:()=>x,ks:()=>k,tc:()=>G,uB:()=>w,xX:()=>ne});var b=y(3765),o=y(37264),K=y(87301),$=y(15365),L=y(64830),U=y(37042),P=y(58067),B=y(59715),T=y(96655),p=y(82399),d=y(70802),g=y(67167),h=y(76243),l=y(79359),u=y(46441);class w{constructor(te){this.id=te.id,this.precondition=te.precondition,this._kbOpts=te.kbOpts,this._menuOpts=te.menuOpts,this._description=te.description}register(){if(Array.isArray(this._menuOpts)?this._menuOpts.forEach(this._registerMenuItem,this):this._menuOpts&&this._registerMenuItem(this._menuOpts),this._kbOpts){const te=Array.isArray(this._kbOpts)?this._kbOpts:[this._kbOpts];for(const oe of te){let ue=oe.kbExpr;this.precondition&&(ue?ue=T.M$.and(ue,this.precondition):ue=this.precondition);const E={id:this.id,weight:oe.weight,args:oe.args,when:ue,primary:oe.primary,secondary:oe.secondary,win:oe.win,linux:oe.linux,mac:oe.mac};d.f.registerKeybindingRule(E)}}B.wb.registerCommand({id:this.id,handler:(te,oe)=>this.runCommand(te,oe),description:this._description})}_registerMenuItem(te){P.ZG.appendMenuItem(te.menuId,{group:te.group,command:{id:this.id,title:te.title,icon:te.icon,precondition:this.precondition},when:te.when,order:te.order})}}class C extends w{constructor(){super(...arguments),this._implementations=[]}addImplementation(te,oe,ue){return this._implementations.push({priority:te,name:oe,implementation:ue}),this._implementations.sort((E,Qe)=>Qe.priority-E.priority),{dispose:()=>{for(let E=0;E<this._implementations.length;E++)if(this._implementations[E].implementation===ue){this._implementations.splice(E,1);return}}}}runCommand(te,oe){const ue=te.get(u.rr);ue.trace(`Executing Command '${this.id}' which has ${this._implementations.length} bound.`);for(const E of this._implementations){const Qe=E.implementation(te,oe);if(Qe)return ue.trace(`Command '${this.id}' was handled by '${E.name}'.`),typeof Qe=="boolean"?void 0:Qe}ue.trace(`The Command '${this.id}' was not handled by any implementation.`)}}class m extends w{constructor(te,oe){super(oe),this.command=te}runCommand(te,oe){return this.command.runCommand(te,oe)}}class v extends w{static bindToContribution(te){return class extends v{constructor(ue){super(ue),this._callback=ue.handler}runEditorCommand(ue,E,Qe){const Ke=te(E);Ke&&this._callback(Ke,Qe)}}}static runEditorCommand(te,oe,ue,E){const Qe=te.get(K.T),Ke=Qe.getFocusedCodeEditor()||Qe.getActiveCodeEditor();if(Ke)return Ke.invokeWithinContext(Se=>{if(Se.get(T.fN).contextMatchesRules((0,l.UH)(ue)))return E(Se,Ke,oe)})}runCommand(te,oe){return v.runEditorCommand(te,oe,this.precondition,(ue,E,Qe)=>this.runEditorCommand(ue,E,Qe))}}class k extends v{constructor(te){super(k.convertOptions(te)),this.label=te.label,this.alias=te.alias}static convertOptions(te){let oe;Array.isArray(te.menuOpts)?oe=te.menuOpts:te.menuOpts?oe=[te.menuOpts]:oe=[];function ue(E){return E.menuId||(E.menuId=P.D8.EditorContext),E.title||(E.title=te.label),E.when=T.M$.and(te.precondition,E.when),E}return Array.isArray(te.contextMenuOpts)?oe.push(...te.contextMenuOpts.map(ue)):te.contextMenuOpts&&oe.push(ue(te.contextMenuOpts)),te.menuOpts=oe,te}runEditorCommand(te,oe,ue){return this.reportTelemetry(te,oe),this.run(te,oe,ue||{})}reportTelemetry(te,oe){te.get(h.k).publicLog2("editorActionInvoked",{name:this.label,id:this.id})}}class D extends k{constructor(){super(...arguments),this._implementations=[]}addImplementation(te,oe){return this._implementations.push([te,oe]),this._implementations.sort((ue,E)=>E[0]-ue[0]),{dispose:()=>{for(let ue=0;ue<this._implementations.length;ue++)if(this._implementations[ue][1]===oe){this._implementations.splice(ue,1);return}}}}run(te,oe,ue){for(const E of this._implementations){const Qe=E[1](te,oe,ue);if(Qe)return typeof Qe=="boolean"?void 0:Qe}}}function x(O,te){B.wb.registerCommand(O,function(oe,...ue){const E=oe.get(p._Y),[Qe,Ke]=ue;(0,l.j)(o.r.isUri(Qe)),(0,l.j)($.y.isIPosition(Ke));const Se=oe.get(L.S).getModel(Qe);if(Se){const Me=$.y.lift(Ke);return E.invokeFunction(te,Se,Me,...ue.slice(2))}return oe.get(U.b).createModelReference(Qe).then(Me=>new Promise((ce,pe)=>{try{const be=E.invokeFunction(te,Me.object.textEditorModel,$.y.lift(Ke),ue.slice(2));ce(be)}catch(be){pe(be)}}).finally(()=>{Me.dispose()}))})}function A(O){return R.INSTANCE.registerEditorCommand(O),O}function W(O){const te=new O;return R.INSTANCE.registerEditorAction(te),te}function Y(O){return R.INSTANCE.registerEditorAction(O),O}function ne(O){R.INSTANCE.registerEditorAction(O)}function j(O,te){R.INSTANCE.registerEditorContribution(O,te)}var Q;(function(O){function te(Ke){return R.INSTANCE.getEditorCommand(Ke)}O.getEditorCommand=te;function oe(){return R.INSTANCE.getEditorActions()}O.getEditorActions=oe;function ue(){return R.INSTANCE.getEditorContributions()}O.getEditorContributions=ue;function E(Ke){return R.INSTANCE.getEditorContributions().filter(Se=>Ke.indexOf(Se.id)>=0)}O.getSomeEditorContributions=E;function Qe(){return R.INSTANCE.getDiffEditorContributions()}O.getDiffEditorContributions=Qe})(Q||(Q={}));const X={EditorCommonContributions:"editor.contributions"};class R{constructor(){this.editorContributions=[],this.diffEditorContributions=[],this.editorActions=[],this.editorCommands=Object.create(null)}registerEditorContribution(te,oe){this.editorContributions.push({id:te,ctor:oe})}getEditorContributions(){return this.editorContributions.slice(0)}getDiffEditorContributions(){return this.diffEditorContributions.slice(0)}registerEditorAction(te){te.register(),this.editorActions.push(te)}getEditorActions(){return this.editorActions.slice(0)}registerEditorCommand(te){te.register(),this.editorCommands[te.id]=te}getEditorCommand(te){return this.editorCommands[te]||null}}R.INSTANCE=new R,g.O.add(X.EditorCommonContributions,R.INSTANCE);function H(O){return O.register(),O}const Z=H(new C({id:"undo",precondition:void 0,kbOpts:{weight:0,primary:2104},menuOpts:[{menuId:P.D8.MenubarEditMenu,group:"1_do",title:b.kg({key:"miUndo",comment:["&& denotes a mnemonic"]},"&&Undo"),order:1},{menuId:P.D8.CommandPalette,group:"",title:b.kg("undo","Undo"),order:1}]}));H(new m(Z,{id:"default:undo",precondition:void 0}));const N=H(new C({id:"redo",precondition:void 0,kbOpts:{weight:0,primary:2103,secondary:[3128],mac:{primary:3128}},menuOpts:[{menuId:P.D8.MenubarEditMenu,group:"1_do",title:b.kg({key:"miRedo",comment:["&& denotes a mnemonic"]},"&&Redo"),order:2},{menuId:P.D8.CommandPalette,group:"",title:b.kg("redo","Redo"),order:1}]}));H(new m(N,{id:"default:redo",precondition:void 0}));const G=H(new C({id:"editor.action.selectAll",precondition:void 0,kbOpts:{weight:0,kbExpr:null,primary:2079},menuOpts:[{menuId:P.D8.MenubarSelectionMenu,group:"1_basic",title:b.kg({key:"miSelectAll",comment:["&& denotes a mnemonic"]},"&&Select All"),order:1},{menuId:P.D8.CommandPalette,group:"",title:b.kg("selectAll","Select All"),order:1}]}))},50969:(rt,ye,y)=>{y.d(ye,{G:()=>b});function b(o,K){let $=0,L=0;const U=o.length;for(;L<U;){const P=o.charCodeAt(L);if(P===32)$++;else if(P===9)$=$-$%K+K;else break;L++}return L===U?-1:$}},51460:(rt,ye,y)=>{y.d(ye,{F:()=>K});var b=y(2106),o=y(67167);const K={JSONContribution:"base.contributions.json"};function $(P){return P.length>0&&P.charAt(P.length-1)==="#"?P.substring(0,P.length-1):P}class L{constructor(){this._onDidChangeSchema=new b.vl,this.schemasById={}}registerSchema(B,T){this.schemasById[$(B)]=T,this._onDidChangeSchema.fire(B)}notifySchemaChanged(B){this._onDidChangeSchema.fire(B)}}const U=new L;o.O.add(K.JSONContribution,U)},51577:(rt,ye,y)=>{y.d(ye,{e:()=>K});var b=y(55893),o=y(63339);const K={clipboard:{writeText:o.ib||document.queryCommandSupported&&document.queryCommandSupported("copy")||!!(navigator&&navigator.clipboard&&navigator.clipboard.writeText),readText:o.ib||!!(navigator&&navigator.clipboard&&navigator.clipboard.readText)},keyboard:o.ib||b.isStandalone()?0:navigator.keyboard||b.isSafari?1:2,touch:"ontouchstart"in window||navigator.maxTouchPoints>0,pointerEvents:window.PointerEvent&&("ontouchstart"in window||window.navigator.maxTouchPoints>0||navigator.maxTouchPoints>0)}},52230:(rt,ye,y)=>{y.d(ye,{u:()=>o});var b=y(82399);const o=(0,b.u1)("ILanguageFeaturesService")},52348:(rt,ye,y)=>{y.d(ye,{Z:()=>K,l:()=>o});var b=y(82399);const o=(0,b.u1)("contextViewService"),K=(0,b.u1)("contextMenuService")},52394:(rt,ye,y)=>{y.d(ye,{JZ:()=>X,Cw:()=>O,P6:()=>te});var b=y(2106),o=y(10998),K=y(16844),$=y(18782),L=y(49550),U=y(19184);class P{constructor(ce){if(ce.autoClosingPairs?this._autoClosingPairs=ce.autoClosingPairs.map(pe=>new L.i3(pe)):ce.brackets?this._autoClosingPairs=ce.brackets.map(pe=>new L.i3({open:pe[0],close:pe[1]})):this._autoClosingPairs=[],ce.__electricCharacterSupport&&ce.__electricCharacterSupport.docComment){const pe=ce.__electricCharacterSupport.docComment;this._autoClosingPairs.push(new L.i3({open:pe.open,close:pe.close||""}))}this._autoCloseBefore=typeof ce.autoCloseBefore=="string"?ce.autoCloseBefore:P.DEFAULT_AUTOCLOSE_BEFORE_LANGUAGE_DEFINED,this._surroundingPairs=ce.surroundingPairs||this._autoClosingPairs}getAutoClosingPairs(){return this._autoClosingPairs}getAutoCloseBeforeSet(){return this._autoCloseBefore}getSurroundingPairs(){return this._surroundingPairs}}P.DEFAULT_AUTOCLOSE_BEFORE_LANGUAGE_DEFINED=`;:.,=}])> `;var B=y(13338),T=y(1804);class p{constructor(ce){this._richEditBrackets=ce}getElectricCharacters(){const ce=[];if(this._richEditBrackets)for(const pe of this._richEditBrackets.brackets)for(const be of pe.close){const ge=be.charAt(be.length-1);ce.push(ge)}return(0,B.dM)(ce)}onElectricCharacter(ce,pe,be){if(!this._richEditBrackets||this._richEditBrackets.brackets.length===0)return null;const ge=pe.findTokenIndexAtOffset(be-1);if((0,U.Yo)(pe.getStandardTokenType(ge)))return null;const ke=this._richEditBrackets.reversedRegex,We=pe.getLineContent().substring(0,be-1)+ce,Ge=T.Fu.findPrevBracketInRange(ke,1,We,0,We.length);if(!Ge)return null;const Ae=We.substring(Ge.startColumn-1,Ge.endColumn-1).toLowerCase();if(this._richEditBrackets.textIsOpenBracket[Ae])return null;const Pe=pe.getActualLineContentBefore(Ge.startColumn-1);return/^\s*$/.test(Pe)?{matchOpenBracket:Ae}:null}}function d(Me){return Me.global&&(Me.lastIndex=0),!0}class g{constructor(ce){this._indentationRules=ce}shouldIncrease(ce){return!!(this._indentationRules&&this._indentationRules.increaseIndentPattern&&d(this._indentationRules.increaseIndentPattern)&&this._indentationRules.increaseIndentPattern.test(ce))}shouldDecrease(ce){return!!(this._indentationRules&&this._indentationRules.decreaseIndentPattern&&d(this._indentationRules.decreaseIndentPattern)&&this._indentationRules.decreaseIndentPattern.test(ce))}shouldIndentNextLine(ce){return!!(this._indentationRules&&this._indentationRules.indentNextLinePattern&&d(this._indentationRules.indentNextLinePattern)&&this._indentationRules.indentNextLinePattern.test(ce))}shouldIgnore(ce){return!!(this._indentationRules&&this._indentationRules.unIndentedLinePattern&&d(this._indentationRules.unIndentedLinePattern)&&this._indentationRules.unIndentedLinePattern.test(ce))}getIndentMetadata(ce){let pe=0;return this.shouldIncrease(ce)&&(pe+=1),this.shouldDecrease(ce)&&(pe+=2),this.shouldIndentNextLine(ce)&&(pe+=4),this.shouldIgnore(ce)&&(pe+=8),pe}}var h=y(94327);class l{constructor(ce){ce=ce||{},ce.brackets=ce.brackets||[["(",")"],["{","}"],["[","]"]],this._brackets=[],ce.brackets.forEach(pe=>{const be=l._createOpenBracketRegExp(pe[0]),ge=l._createCloseBracketRegExp(pe[1]);be&&ge&&this._brackets.push({open:pe[0],openRegExp:be,close:pe[1],closeRegExp:ge})}),this._regExpRules=ce.onEnterRules||[]}onEnter(ce,pe,be,ge){if(ce>=3)for(let ke=0,We=this._regExpRules.length;ke<We;ke++){const Ge=this._regExpRules[ke];if([{reg:Ge.beforeText,text:be},{reg:Ge.afterText,text:ge},{reg:Ge.previousLineText,text:pe}].every(he=>he.reg?(he.reg.lastIndex=0,he.reg.test(he.text)):!0))return Ge.action}if(ce>=2&&be.length>0&&ge.length>0)for(let ke=0,We=this._brackets.length;ke<We;ke++){const Ge=this._brackets[ke];if(Ge.openRegExp.test(be)&&Ge.closeRegExp.test(ge))return{indentAction:L.l.IndentOutdent}}if(ce>=2&&be.length>0){for(let ke=0,We=this._brackets.length;ke<We;ke++)if(this._brackets[ke].openRegExp.test(be))return{indentAction:L.l.Indent}}return null}static _createOpenBracketRegExp(ce){let pe=K.bm(ce);return/\B/.test(pe.charAt(0))||(pe="\\b"+pe),pe+="\\s*$",l._safeRegExp(pe)}static _createCloseBracketRegExp(ce){let pe=K.bm(ce);return/\B/.test(pe.charAt(pe.length-1))||(pe=pe+"\\b"),pe="^\\s*"+pe,l._safeRegExp(pe)}static _safeRegExp(ce){try{return new RegExp(ce)}catch(pe){return(0,h.dz)(pe),null}}}var u=y(82399),w=y(85753),C=y(77922),m=y(66726),v=y(54957),k=y(36260);class D{constructor(ce,pe){this.languageId=ce;let be;pe.colorizedBracketPairs?be=x(pe.colorizedBracketPairs.map(We=>[We[0],We[1]])):pe.brackets?be=x(pe.brackets.map(We=>[We[0],We[1]]).filter(We=>!(We[0]==="<"&&We[1]===">"))):be=[];const ge=new k.V(We=>{const Ge=new Set;return{info:new W(this,We,Ge),closing:Ge}}),ke=new k.V(We=>{const Ge=new Set;return{info:new Y(this,We,Ge),opening:Ge}});for(const[We,Ge]of be){const Ae=ge.get(We),he=ke.get(Ge);Ae.closing.add(he.info),he.opening.add(Ae.info)}this._openingBrackets=new Map([...ge.cachedValues].map(([We,Ge])=>[We,Ge.info])),this._closingBrackets=new Map([...ke.cachedValues].map(([We,Ge])=>[We,Ge.info]))}get openingBrackets(){return[...this._openingBrackets.values()]}get closingBrackets(){return[...this._closingBrackets.values()]}getOpeningBracketInfo(ce){return this._openingBrackets.get(ce)}getClosingBracketInfo(ce){return this._closingBrackets.get(ce)}getBracketInfo(ce){return this.getOpeningBracketInfo(ce)||this.getClosingBracketInfo(ce)}}function x(Me){return Me.filter(([ce,pe])=>ce!==""&&pe!=="")}class A{constructor(ce,pe){this.config=ce,this.bracketText=pe}get languageId(){return this.config.languageId}}class W extends A{constructor(ce,pe,be){super(ce,pe),this.openedBrackets=be,this.isOpeningBracket=!0}}class Y extends A{constructor(ce,pe,be){super(ce,pe),this.closedBrackets=be,this.isOpeningBracket=!1}closes(ce){if(ce.languageId===this.languageId&&ce.config!==this.config)throw new h.D7("Brackets from different language configuration cannot be used.");return this.closedBrackets.has(ce)}getClosedBrackets(){return[...this.closedBrackets]}}var ne=function(Me,ce,pe,be){var ge=arguments.length,ke=ge<3?ce:be===null?be=Object.getOwnPropertyDescriptor(ce,pe):be,We;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")ke=Reflect.decorate(Me,ce,pe,be);else for(var Ge=Me.length-1;Ge>=0;Ge--)(We=Me[Ge])&&(ke=(ge<3?We(ke):ge>3?We(ce,pe,ke):We(ce,pe))||ke);return ge>3&&ke&&Object.defineProperty(ce,pe,ke),ke},j=function(Me,ce){return function(pe,be){ce(pe,be,Me)}};class Q{constructor(ce){this.languageId=ce}affects(ce){return this.languageId?this.languageId===ce:!0}}const X=(0,u.u1)("languageConfigurationService");let R=class extends o.jG{constructor(ce,pe){super(),this.configurationService=ce,this.languageService=pe,this._registry=this._register(new Ke),this.onDidChangeEmitter=this._register(new b.vl),this.onDidChange=this.onDidChangeEmitter.event,this.configurations=new Map;const be=new Set(Object.values(Z));this._register(this.configurationService.onDidChangeConfiguration(ge=>{const ke=ge.change.keys.some(Ge=>be.has(Ge)),We=ge.change.overrides.filter(([Ge,Ae])=>Ae.some(he=>be.has(he))).map(([Ge])=>Ge);if(ke)this.configurations.clear(),this.onDidChangeEmitter.fire(new Q(void 0));else for(const Ge of We)this.languageService.isRegisteredLanguageId(Ge)&&(this.configurations.delete(Ge),this.onDidChangeEmitter.fire(new Q(Ge)))})),this._register(this._registry.onDidChange(ge=>{this.configurations.delete(ge.languageId),this.onDidChangeEmitter.fire(new Q(ge.languageId))}))}register(ce,pe,be){return this._registry.register(ce,pe,be)}getLanguageConfiguration(ce){let pe=this.configurations.get(ce);return pe||(pe=H(ce,this._registry,this.configurationService,this.languageService),this.configurations.set(ce,pe)),pe}};R=ne([j(0,w.pG),j(1,C.L)],R);function H(Me,ce,pe,be){let ge=ce.getLanguageConfiguration(Me);if(!ge){if(!be.isRegisteredLanguageId(Me))throw new Error(`Language id "${Me}" is not configured nor known`);ge=new Se(Me,{})}const ke=N(ge.languageId,pe),We=ue([ge.underlyingConfig,ke]);return new Se(ge.languageId,We)}const Z={brackets:"editor.language.brackets",colorizedBracketPairs:"editor.language.colorizedBracketPairs"};function N(Me,ce){const pe=ce.getValue(Z.brackets,{overrideIdentifier:Me}),be=ce.getValue(Z.colorizedBracketPairs,{overrideIdentifier:Me});return{brackets:G(pe),colorizedBracketPairs:G(be)}}function G(Me){if(Array.isArray(Me))return Me.map(ce=>{if(!(!Array.isArray(ce)||ce.length!==2))return[ce[0],ce[1]]}).filter(ce=>!!ce)}function O(Me,ce,pe){const be=Me.getLineContent(ce);let ge=K.UU(be);return ge.length>pe-1&&(ge=ge.substring(0,pe-1)),ge}function te(Me,ce,pe){Me.tokenization.forceTokenization(ce);const be=Me.tokenization.getLineTokens(ce),ge=typeof pe>"u"?Me.getLineMaxColumn(ce)-1:pe-1;return(0,U.BQ)(be,ge)}class oe{constructor(ce){this.languageId=ce,this._resolved=null,this._entries=[],this._order=0,this._resolved=null}register(ce,pe){const be=new E(ce,pe,++this._order);return this._entries.push(be),this._resolved=null,(0,o.s)(()=>{for(let ge=0;ge<this._entries.length;ge++)if(this._entries[ge]===be){this._entries.splice(ge,1),this._resolved=null;break}})}getResolvedConfiguration(){if(!this._resolved){const ce=this._resolve();ce&&(this._resolved=new Se(this.languageId,ce))}return this._resolved}_resolve(){return this._entries.length===0?null:(this._entries.sort(E.cmp),ue(this._entries.map(ce=>ce.configuration)))}}function ue(Me){let ce={comments:void 0,brackets:void 0,wordPattern:void 0,indentationRules:void 0,onEnterRules:void 0,autoClosingPairs:void 0,surroundingPairs:void 0,autoCloseBefore:void 0,folding:void 0,colorizedBracketPairs:void 0,__electricCharacterSupport:void 0};for(const pe of Me)ce={comments:pe.comments||ce.comments,brackets:pe.brackets||ce.brackets,wordPattern:pe.wordPattern||ce.wordPattern,indentationRules:pe.indentationRules||ce.indentationRules,onEnterRules:pe.onEnterRules||ce.onEnterRules,autoClosingPairs:pe.autoClosingPairs||ce.autoClosingPairs,surroundingPairs:pe.surroundingPairs||ce.surroundingPairs,autoCloseBefore:pe.autoCloseBefore||ce.autoCloseBefore,folding:pe.folding||ce.folding,colorizedBracketPairs:pe.colorizedBracketPairs||ce.colorizedBracketPairs,__electricCharacterSupport:pe.__electricCharacterSupport||ce.__electricCharacterSupport};return ce}class E{constructor(ce,pe,be){this.configuration=ce,this.priority=pe,this.order=be}static cmp(ce,pe){return ce.priority===pe.priority?ce.order-pe.order:ce.priority-pe.priority}}class Qe{constructor(ce){this.languageId=ce}}class Ke extends o.jG{constructor(){super(),this._entries=new Map,this._onDidChange=this._register(new b.vl),this.onDidChange=this._onDidChange.event,this._register(this.register(v.vH,{brackets:[["(",")"],["[","]"],["{","}"]],surroundingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:"<",close:">"},{open:'"',close:'"'},{open:"'",close:"'"},{open:"`",close:"`"}],colorizedBracketPairs:[],folding:{offSide:!0}},0))}register(ce,pe,be=0){let ge=this._entries.get(ce);ge||(ge=new oe(ce),this._entries.set(ce,ge));const ke=ge.register(pe,be);return this._onDidChange.fire(new Qe(ce)),(0,o.s)(()=>{ke.dispose(),this._onDidChange.fire(new Qe(ce))})}getLanguageConfiguration(ce){const pe=this._entries.get(ce);return pe?.getResolvedConfiguration()||null}}class Se{constructor(ce,pe){this.languageId=ce,this.underlyingConfig=pe,this._brackets=null,this._electricCharacter=null,this._onEnterSupport=this.underlyingConfig.brackets||this.underlyingConfig.indentationRules||this.underlyingConfig.onEnterRules?new l(this.underlyingConfig):null,this.comments=Se._handleComments(this.underlyingConfig),this.characterPair=new P(this.underlyingConfig),this.wordDefinition=this.underlyingConfig.wordPattern||$.Ld,this.indentationRules=this.underlyingConfig.indentationRules,this.underlyingConfig.indentationRules?this.indentRulesSupport=new g(this.underlyingConfig.indentationRules):this.indentRulesSupport=null,this.foldingRules=this.underlyingConfig.folding||{},this.bracketsNew=new D(ce,this.underlyingConfig)}getWordDefinition(){return(0,$.Io)(this.wordDefinition)}get brackets(){return!this._brackets&&this.underlyingConfig.brackets&&(this._brackets=new T.az(this.languageId,this.underlyingConfig.brackets)),this._brackets}get electricCharacter(){return this._electricCharacter||(this._electricCharacter=new p(this.brackets)),this._electricCharacter}onEnter(ce,pe,be,ge){return this._onEnterSupport?this._onEnterSupport.onEnter(ce,pe,be,ge):null}getAutoClosingPairs(){return new L.GB(this.characterPair.getAutoClosingPairs())}getAutoCloseBeforeSet(){return this.characterPair.getAutoCloseBeforeSet()}getSurroundingPairs(){return this.characterPair.getSurroundingPairs()}static _handleComments(ce){const pe=ce.comments;if(!pe)return null;const be={};if(pe.lineComment&&(be.lineCommentToken=pe.lineComment),pe.blockComment){const[ge,ke]=pe.blockComment;be.blockCommentStartToken=ge,be.blockCommentEndToken=ke}return be}}(0,m.v)(X,R)},52677:(rt,ye,y)=>{y.d(ye,{nZ:()=>ne,aw:()=>D,WG:()=>W,br:()=>v,BB:()=>w,yS:()=>C});var b=y(78903),o=y(94327),K=y(37264),$=y(64830),L=y(59715),U=y(79359),P=y(42802),B=y(63339);function T(j){for(let Q=0,X=j.length;Q<X;Q+=4){const R=j[Q+0],H=j[Q+1],Z=j[Q+2],N=j[Q+3];j[Q+0]=N,j[Q+1]=Z,j[Q+2]=H,j[Q+3]=R}}function p(j){const Q=new Uint8Array(j.buffer,j.byteOffset,j.length*4);return B.cm()||T(Q),P.MB.wrap(Q)}function d(j){const Q=new Uint32Array(g(j));let X=0;if(Q[X++]=j.id,j.type==="full")Q[X++]=1,Q[X++]=j.data.length,Q.set(j.data,X),X+=j.data.length;else{Q[X++]=2,Q[X++]=j.deltas.length;for(const R of j.deltas)Q[X++]=R.start,Q[X++]=R.deleteCount,R.data?(Q[X++]=R.data.length,Q.set(R.data,X),X+=R.data.length):Q[X++]=0}return p(Q)}function g(j){let Q=0;if(Q+=2,j.type==="full")Q+=1+j.data.length;else{Q+=1,Q+=3*j.deltas.length;for(const X of j.deltas)X.data&&(Q+=X.data.length)}return Q}var h=y(50442),l=y(52230),u=function(j,Q,X,R){function H(Z){return Z instanceof X?Z:new X(function(N){N(Z)})}return new(X||(X=Promise))(function(Z,N){function G(oe){try{te(R.next(oe))}catch(ue){N(ue)}}function O(oe){try{te(R.throw(oe))}catch(ue){N(ue)}}function te(oe){oe.done?Z(oe.value):H(oe.value).then(G,O)}te((R=R.apply(j,Q||[])).next())})};function w(j){return j&&!!j.data}function C(j){return j&&Array.isArray(j.edits)}class m{constructor(Q,X,R){this.provider=Q,this.tokens=X,this.error=R}}function v(j,Q){return j.has(Q)}function k(j,Q){const X=j.orderedGroups(Q);return X.length>0?X[0]:[]}function D(j,Q,X,R,H){return u(this,void 0,void 0,function*(){const Z=k(j,Q),N=yield Promise.all(Z.map(G=>u(this,void 0,void 0,function*(){let O,te=null;try{O=yield G.provideDocumentSemanticTokens(Q,G===X?R:null,H)}catch(oe){te=oe,O=null}return(!O||!w(O)&&!C(O))&&(O=null),new m(G,O,te)})));for(const G of N){if(G.error)throw G.error;if(G.tokens)return G}return N.length>0?N[0]:null})}function x(j,Q){const X=j.orderedGroups(Q);return X.length>0?X[0]:null}class A{constructor(Q,X){this.provider=Q,this.tokens=X}}function W(j,Q){return j.has(Q)}function Y(j,Q){const X=j.orderedGroups(Q);return X.length>0?X[0]:[]}function ne(j,Q,X,R){return u(this,void 0,void 0,function*(){const H=Y(j,Q),Z=yield Promise.all(H.map(N=>u(this,void 0,void 0,function*(){let G;try{G=yield N.provideDocumentRangeSemanticTokens(Q,X,R)}catch(O){(0,o.M_)(O),G=null}return(!G||!w(G))&&(G=null),new A(N,G)})));for(const N of Z)if(N.tokens)return N;return Z.length>0?Z[0]:null})}L.wb.registerCommand("_provideDocumentSemanticTokensLegend",(j,...Q)=>u(void 0,void 0,void 0,function*(){const[X]=Q;(0,U.j)(X instanceof K.r);const R=j.get($.S).getModel(X);if(!R)return;const{documentSemanticTokensProvider:H}=j.get(l.u),Z=x(H,R);return Z?Z[0].getLegend():j.get(L.wT).executeCommand("_provideDocumentRangeSemanticTokensLegend",X)})),L.wb.registerCommand("_provideDocumentSemanticTokens",(j,...Q)=>u(void 0,void 0,void 0,function*(){const[X]=Q;(0,U.j)(X instanceof K.r);const R=j.get($.S).getModel(X);if(!R)return;const{documentSemanticTokensProvider:H}=j.get(l.u);if(!v(H,R))return j.get(L.wT).executeCommand("_provideDocumentRangeSemanticTokens",X,R.getFullModelRange());const Z=yield D(H,R,null,null,b.X.None);if(!Z)return;const{provider:N,tokens:G}=Z;if(!G||!w(G))return;const O=d({id:0,type:"full",data:G.data});return G.resultId&&N.releaseDocumentSemanticTokens(G.resultId),O})),L.wb.registerCommand("_provideDocumentRangeSemanticTokensLegend",(j,...Q)=>u(void 0,void 0,void 0,function*(){const[X,R]=Q;(0,U.j)(X instanceof K.r);const H=j.get($.S).getModel(X);if(!H)return;const{documentRangeSemanticTokensProvider:Z}=j.get(l.u),N=Y(Z,H);if(N.length===0)return;if(N.length===1)return N[0].getLegend();if(!R||!h.Q.isIRange(R))return console.warn("provideDocumentRangeSemanticTokensLegend might be out-of-sync with provideDocumentRangeSemanticTokens unless a range argument is passed in"),N[0].getLegend();const G=yield ne(Z,H,h.Q.lift(R),b.X.None);if(G)return G.provider.getLegend()})),L.wb.registerCommand("_provideDocumentRangeSemanticTokens",(j,...Q)=>u(void 0,void 0,void 0,function*(){const[X,R]=Q;(0,U.j)(X instanceof K.r),(0,U.j)(h.Q.isIRange(R));const H=j.get($.S).getModel(X);if(!H)return;const{documentRangeSemanticTokensProvider:Z}=j.get(l.u),N=yield ne(Z,H,h.Q.lift(R),b.X.None);if(!(!N||!N.tokens))return d({id:0,type:"full",data:N.tokens.data})}))},52818:(rt,ye,y)=>{y.d(ye,{P:()=>B,k:()=>T});var b=y(13338),o=y(16844),K=y(62549),$=y(50442),L=y(32177),U=y(50969),P=y(60779);class B extends L._{constructor(d,g){super(),this.textModel=d,this.languageConfigurationService=g}getLanguageConfiguration(d){return this.languageConfigurationService.getLanguageConfiguration(d)}_computeIndentLevel(d){return(0,U.G)(this.textModel.getLineContent(d+1),this.textModel.getOptions().tabSize)}getActiveIndentGuide(d,g,h){this.assertNotDisposed();const l=this.textModel.getLineCount();if(d<1||d>l)throw new Error("Illegal value for lineNumber");const u=this.getLanguageConfiguration(this.textModel.getLanguageId()).foldingRules,w=!!(u&&u.offSide);let C=-2,m=-1,v=-2,k=-1;const D=N=>{if(C!==-1&&(C===-2||C>N-1)){C=-1,m=-1;for(let G=N-2;G>=0;G--){const O=this._computeIndentLevel(G);if(O>=0){C=G,m=O;break}}}if(v===-2){v=-1,k=-1;for(let G=N;G<l;G++){const O=this._computeIndentLevel(G);if(O>=0){v=G,k=O;break}}}};let x=-2,A=-1,W=-2,Y=-1;const ne=N=>{if(x===-2){x=-1,A=-1;for(let G=N-2;G>=0;G--){const O=this._computeIndentLevel(G);if(O>=0){x=G,A=O;break}}}if(W!==-1&&(W===-2||W<N-1)){W=-1,Y=-1;for(let G=N;G<l;G++){const O=this._computeIndentLevel(G);if(O>=0){W=G,Y=O;break}}}};let j=0,Q=!0,X=0,R=!0,H=0,Z=0;for(let N=0;Q||R;N++){const G=d-N,O=d+N;N>1&&(G<1||G<g)&&(Q=!1),N>1&&(O>l||O>h)&&(R=!1),N>5e4&&(Q=!1,R=!1);let te=-1;if(Q&&G>=1){const ue=this._computeIndentLevel(G-1);ue>=0?(v=G-1,k=ue,te=Math.ceil(ue/this.textModel.getOptions().indentSize)):(D(G),te=this._getIndentLevelForWhitespaceLine(w,m,k))}let oe=-1;if(R&&O<=l){const ue=this._computeIndentLevel(O-1);ue>=0?(x=O-1,A=ue,oe=Math.ceil(ue/this.textModel.getOptions().indentSize)):(ne(O),oe=this._getIndentLevelForWhitespaceLine(w,A,Y))}if(N===0){Z=te;continue}if(N===1){if(O<=l&&oe>=0&&Z+1===oe){Q=!1,j=O,X=O,H=oe;continue}if(G>=1&&te>=0&&te-1===Z){R=!1,j=G,X=G,H=te;continue}if(j=d,X=d,H=Z,H===0)return{startLineNumber:j,endLineNumber:X,indent:H}}Q&&(te>=H?j=G:Q=!1),R&&(oe>=H?X=O:R=!1)}return{startLineNumber:j,endLineNumber:X,indent:H}}getLinesBracketGuides(d,g,h,l){var u;const w=[];for(let x=d;x<=g;x++)w.push([]);const C=!0,m=this.textModel.bracketPairs.getBracketPairsInRangeWithMinIndentation(new $.Q(d,1,g,this.textModel.getLineMaxColumn(g)));let v;if(h&&m.length>0){const x=(d<=h.lineNumber&&h.lineNumber<=g?m:this.textModel.bracketPairs.getBracketPairsInRange($.Q.fromPositions(h))).filter(A=>$.Q.strictContainsPosition(A.range,h));v=(u=(0,b.Uk)(x,A=>C||A.range.startLineNumber!==A.range.endLineNumber))===null||u===void 0?void 0:u.range}const k=this.textModel.getOptions().bracketPairColorizationOptions.independentColorPoolPerBracketType,D=new T;for(const x of m){if(!x.closingBracketRange)continue;const A=v&&x.range.equalsRange(v);if(!A&&!l.includeInactive)continue;const W=D.getInlineClassName(x.nestingLevel,x.nestingLevelOfEqualBracketType,k)+(l.highlightActive&&A?" "+D.activeClassName:""),Y=x.openingBracketRange.getStartPosition(),ne=x.closingBracketRange.getStartPosition(),j=l.horizontalGuides===P.N6.Enabled||l.horizontalGuides===P.N6.EnabledForActive&&A;if(x.range.startLineNumber===x.range.endLineNumber){C&&j&&w[x.range.startLineNumber-d].push(new P.TH(-1,x.openingBracketRange.getEndPosition().column,W,new P.pv(!1,ne.column),-1,-1));continue}const Q=this.getVisibleColumnFromPosition(ne),X=this.getVisibleColumnFromPosition(x.openingBracketRange.getStartPosition()),R=Math.min(X,Q,x.minVisibleColumnIndentation+1);let H=!1;o.HG(this.textModel.getLineContent(x.closingBracketRange.startLineNumber))<x.closingBracketRange.startColumn-1&&(H=!0);const G=Math.max(Y.lineNumber,d),O=Math.min(ne.lineNumber,g),te=H?1:0;for(let oe=G;oe<O+te;oe++)w[oe-d].push(new P.TH(R,-1,W,null,oe===Y.lineNumber?Y.column:-1,oe===ne.lineNumber?ne.column:-1));j&&(Y.lineNumber>=d&&X>R&&w[Y.lineNumber-d].push(new P.TH(R,-1,W,new P.pv(!1,Y.column),-1,-1)),ne.lineNumber<=g&&Q>R&&w[ne.lineNumber-d].push(new P.TH(R,-1,W,new P.pv(!H,ne.column),-1,-1)))}for(const x of w)x.sort((A,W)=>A.visibleColumn-W.visibleColumn);return w}getVisibleColumnFromPosition(d){return K.A.visibleColumnFromColumn(this.textModel.getLineContent(d.lineNumber),d.column,this.textModel.getOptions().tabSize)+1}getLinesIndentGuides(d,g){this.assertNotDisposed();const h=this.textModel.getLineCount();if(d<1||d>h)throw new Error("Illegal value for startLineNumber");if(g<1||g>h)throw new Error("Illegal value for endLineNumber");const l=this.textModel.getOptions(),u=this.getLanguageConfiguration(this.textModel.getLanguageId()).foldingRules,w=!!(u&&u.offSide),C=new Array(g-d+1);let m=-2,v=-1,k=-2,D=-1;for(let x=d;x<=g;x++){const A=x-d,W=this._computeIndentLevel(x-1);if(W>=0){m=x-1,v=W,C[A]=Math.ceil(W/l.indentSize);continue}if(m===-2){m=-1,v=-1;for(let Y=x-2;Y>=0;Y--){const ne=this._computeIndentLevel(Y);if(ne>=0){m=Y,v=ne;break}}}if(k!==-1&&(k===-2||k<x-1)){k=-1,D=-1;for(let Y=x;Y<h;Y++){const ne=this._computeIndentLevel(Y);if(ne>=0){k=Y,D=ne;break}}}C[A]=this._getIndentLevelForWhitespaceLine(w,v,D)}return C}_getIndentLevelForWhitespaceLine(d,g,h){const l=this.textModel.getOptions();return g===-1||h===-1?0:g<h?1+Math.floor(g/l.indentSize):g===h||d?Math.ceil(h/l.indentSize):1+Math.floor(h/l.indentSize)}}class T{constructor(){this.activeClassName="indent-active"}getInlineClassName(d,g,h){return this.getInlineClassNameOfLevel(h?g:d)}getInlineClassNameOfLevel(d){return`bracket-indent-guide lvl-${d%30}`}}},53720:(rt,ye,y)=>{y.d(ye,{K:()=>b});const b=Object.freeze({text:"text/plain",binary:"application/octet-stream",unknown:"application/unknown",markdown:"text/markdown",latex:"text/latex",uriList:"text/uri-list"})},53909:(rt,ye,y)=>{y.d(ye,{f:()=>$,j:()=>K});var b=y(96655),o=y(82399);const K=(0,o.u1)("accessibilityService"),$=new b.N1("accessibilityModeEnabled",!1)},54296:(rt,ye,y)=>{y.d(ye,{Th:()=>h,z8:()=>l});var b=y(3765),o=y(94327),K=y(93702),$=y(37264),L=y(6949),U=y(42802),P=y(22467);function B(u){return u.toString()}class T{constructor(w,C,m,v,k,D,x){this.beforeVersionId=w,this.afterVersionId=C,this.beforeEOL=m,this.afterEOL=v,this.beforeCursorState=k,this.afterCursorState=D,this.changes=x}static create(w,C){const m=w.getAlternativeVersionId(),v=g(w);return new T(m,m,v,v,C,C,[])}append(w,C,m,v,k){C.length>0&&(this.changes=(0,L.x)(this.changes,C)),this.afterEOL=m,this.afterVersionId=v,this.afterCursorState=k}static _writeSelectionsSize(w){return 4+16*(w?w.length:0)}static _writeSelections(w,C,m){if(U.Sw(w,C?C.length:0,m),m+=4,C)for(const v of C)U.Sw(w,v.selectionStartLineNumber,m),m+=4,U.Sw(w,v.selectionStartColumn,m),m+=4,U.Sw(w,v.positionLineNumber,m),m+=4,U.Sw(w,v.positionColumn,m),m+=4;return m}static _readSelections(w,C,m){const v=U.bb(w,C);C+=4;for(let k=0;k<v;k++){const D=U.bb(w,C);C+=4;const x=U.bb(w,C);C+=4;const A=U.bb(w,C);C+=4;const W=U.bb(w,C);C+=4,m.push(new K.L(D,x,A,W))}return C}serialize(){let w=10+T._writeSelectionsSize(this.beforeCursorState)+T._writeSelectionsSize(this.afterCursorState)+4;for(const v of this.changes)w+=v.writeSize();const C=new Uint8Array(w);let m=0;U.Sw(C,this.beforeVersionId,m),m+=4,U.Sw(C,this.afterVersionId,m),m+=4,U.Gs(C,this.beforeEOL,m),m+=1,U.Gs(C,this.afterEOL,m),m+=1,m=T._writeSelections(C,this.beforeCursorState,m),m=T._writeSelections(C,this.afterCursorState,m),U.Sw(C,this.changes.length,m),m+=4;for(const v of this.changes)m=v.write(C,m);return C.buffer}static deserialize(w){const C=new Uint8Array(w);let m=0;const v=U.bb(C,m);m+=4;const k=U.bb(C,m);m+=4;const D=U.pJ(C,m);m+=1;const x=U.pJ(C,m);m+=1;const A=[];m=T._readSelections(C,m,A);const W=[];m=T._readSelections(C,m,W);const Y=U.bb(C,m);m+=4;const ne=[];for(let j=0;j<Y;j++)m=L.k.read(C,m,ne);return new T(v,k,D,x,A,W,ne)}}class p{constructor(w,C,m,v){this.label=w,this.code=C,this.model=m,this._data=T.create(m,v)}get type(){return 0}get resource(){return $.r.isUri(this.model)?this.model:this.model.uri}toString(){return(this._data instanceof T?this._data:T.deserialize(this._data)).changes.map(C=>C.toString()).join(", ")}matchesResource(w){return($.r.isUri(this.model)?this.model:this.model.uri).toString()===w.toString()}setModel(w){this.model=w}canAppend(w){return this.model===w&&this._data instanceof T}append(w,C,m,v,k){this._data instanceof T&&this._data.append(w,C,m,v,k)}close(){this._data instanceof T&&(this._data=this._data.serialize())}open(){this._data instanceof T||(this._data=T.deserialize(this._data))}undo(){if($.r.isUri(this.model))throw new Error("Invalid SingleModelEditStackElement");this._data instanceof T&&(this._data=this._data.serialize());const w=T.deserialize(this._data);this.model._applyUndo(w.changes,w.beforeEOL,w.beforeVersionId,w.beforeCursorState)}redo(){if($.r.isUri(this.model))throw new Error("Invalid SingleModelEditStackElement");this._data instanceof T&&(this._data=this._data.serialize());const w=T.deserialize(this._data);this.model._applyRedo(w.changes,w.afterEOL,w.afterVersionId,w.afterCursorState)}heapSize(){return this._data instanceof T&&(this._data=this._data.serialize()),this._data.byteLength+168}}class d{constructor(w,C,m){this.label=w,this.code=C,this.type=1,this._isOpen=!0,this._editStackElementsArr=m.slice(0),this._editStackElementsMap=new Map;for(const v of this._editStackElementsArr){const k=B(v.resource);this._editStackElementsMap.set(k,v)}this._delegate=null}get resources(){return this._editStackElementsArr.map(w=>w.resource)}prepareUndoRedo(){if(this._delegate)return this._delegate.prepareUndoRedo(this)}matchesResource(w){const C=B(w);return this._editStackElementsMap.has(C)}setModel(w){const C=B($.r.isUri(w)?w:w.uri);this._editStackElementsMap.has(C)&&this._editStackElementsMap.get(C).setModel(w)}canAppend(w){if(!this._isOpen)return!1;const C=B(w.uri);return this._editStackElementsMap.has(C)?this._editStackElementsMap.get(C).canAppend(w):!1}append(w,C,m,v,k){const D=B(w.uri);this._editStackElementsMap.get(D).append(w,C,m,v,k)}close(){this._isOpen=!1}open(){}undo(){this._isOpen=!1;for(const w of this._editStackElementsArr)w.undo()}redo(){for(const w of this._editStackElementsArr)w.redo()}heapSize(w){const C=B(w);return this._editStackElementsMap.has(C)?this._editStackElementsMap.get(C).heapSize():0}split(){return this._editStackElementsArr}toString(){const w=[];for(const C of this._editStackElementsArr)w.push(`${(0,P.P8)(C.resource)}: ${C}`);return`{${w.join(", ")}}`}}function g(u){return u.getEOL()===` `?0:1}function h(u){return u?u instanceof p||u instanceof d:!1}class l{constructor(w,C){this._model=w,this._undoRedoService=C}pushStackElement(){const w=this._undoRedoService.getLastElement(this._model.uri);h(w)&&w.close()}popStackElement(){const w=this._undoRedoService.getLastElement(this._model.uri);h(w)&&w.open()}clear(){this._undoRedoService.removeElements(this._model.uri)}_getOrCreateEditStackElement(w){const C=this._undoRedoService.getLastElement(this._model.uri);if(h(C)&&C.canAppend(this._model))return C;const m=new p(b.kg("edit","Typing"),"undoredo.textBufferEdit",this._model,w);return this._undoRedoService.pushElement(m),m}pushEOL(w){const C=this._getOrCreateEditStackElement(null);this._model.setEOL(w),C.append(this._model,[],g(this._model),this._model.getAlternativeVersionId(),null)}pushEditOperation(w,C,m){const v=this._getOrCreateEditStackElement(w),k=this._model.applyEdits(C,!0),D=l._computeCursorState(m,k),x=k.map((A,W)=>({index:W,textChange:A.textChange}));return x.sort((A,W)=>A.textChange.oldPosition===W.textChange.oldPosition?A.index-W.index:A.textChange.oldPosition-W.textChange.oldPosition),v.append(this._model,x.map(A=>A.textChange),g(this._model),this._model.getAlternativeVersionId(),D),D}static _computeCursorState(w,C){try{return w?w(C):null}catch(m){return(0,o.dz)(m),null}}}},54324:(rt,ye,y)=>{y.d(ye,{Du:()=>d,Su:()=>g,aI:()=>p,b7:()=>T});var b=y(16844),o=y(63339),K=y(42802);let $;function L(){return $||($=new TextDecoder("UTF-16LE")),$}let U;function P(){return U||(U=new TextDecoder("UTF-16BE")),U}let B;function T(){return B||(B=o.cm()?L():P()),B}const p=typeof TextDecoder<"u";let d,g;p?(d=C=>new u(C),g=h):(d=C=>new w,g=l);function h(C,m,v){const k=new Uint16Array(C.buffer,m,v);return v>0&&(k[0]===65279||k[0]===65534)?l(C,m,v):L().decode(k)}function l(C,m,v){const k=[];let D=0;for(let x=0;x<v;x++){const A=K.$l(C,m);m+=2,k[D++]=String.fromCharCode(A)}return k.join("")}class u{constructor(m){this._capacity=m|0,this._buffer=new Uint16Array(this._capacity),this._completedStrings=null,this._bufferLength=0}reset(){this._completedStrings=null,this._bufferLength=0}build(){return this._completedStrings!==null?(this._flushBuffer(),this._completedStrings.join("")):this._buildBuffer()}_buildBuffer(){if(this._bufferLength===0)return"";const m=new Uint16Array(this._buffer.buffer,0,this._bufferLength);return T().decode(m)}_flushBuffer(){const m=this._buildBuffer();this._bufferLength=0,this._completedStrings===null?this._completedStrings=[m]:this._completedStrings[this._completedStrings.length]=m}write1(m){const v=this._capacity-this._bufferLength;v<=1&&(v===0||b.pc(m))&&this._flushBuffer(),this._buffer[this._bufferLength++]=m}appendASCII(m){this._bufferLength===this._capacity&&this._flushBuffer(),this._buffer[this._bufferLength++]=m}appendASCIIString(m){const v=m.length;if(this._bufferLength+v>=this._capacity){this._flushBuffer(),this._completedStrings[this._completedStrings.length]=m;return}for(let k=0;k<v;k++)this._buffer[this._bufferLength++]=m.charCodeAt(k)}}class w{constructor(){this._pieces=[],this._piecesLen=0}reset(){this._pieces=[],this._piecesLen=0}build(){return this._pieces.join("")}write1(m){this._pieces[this._piecesLen++]=String.fromCharCode(m)}appendASCII(m){this._pieces[this._piecesLen++]=String.fromCharCode(m)}appendASCIIString(m){this._pieces[this._piecesLen++]=m}}},54435:(rt,ye,y)=>{y.d(ye,{Cr:()=>U,ew:()=>p,fV:()=>T,m5:()=>P,v$:()=>B});var b=y(10998),o=y(16844),K=y(37264),$=y(82399),L=function(d,g,h,l){function u(w){return w instanceof h?w:new h(function(C){C(w)})}return new(h||(h=Promise))(function(w,C){function m(D){try{k(l.next(D))}catch(x){C(x)}}function v(D){try{k(l.throw(D))}catch(x){C(x)}}function k(D){D.done?w(D.value):u(D.value).then(m,v)}k((l=l.apply(d,g||[])).next())})};const U=(0,$.u1)("openerService"),P=Object.freeze({_serviceBrand:void 0,registerOpener(){return b.jG.None},registerValidator(){return b.jG.None},registerExternalUriResolver(){return b.jG.None},setDefaultExternalOpener(){},registerExternalOpener(){return b.jG.None},open(){return L(this,void 0,void 0,function*(){return!1})},resolveExternalUri(d){return L(this,void 0,void 0,function*(){return{resolved:d,dispose(){}}})}});function B(d,g){return K.r.isUri(d)?(0,o.Q_)(d.scheme,g):(0,o.ns)(d,g+":")}function T(d,...g){return g.some(h=>B(d,h))}function p(d){let g;const h=/^L?(\d+)(?:,(\d+))?(-L?(\d+)(?:,(\d+))?)?/.exec(d.fragment);return h&&(g={startLineNumber:parseInt(h[1]),startColumn:h[2]?parseInt(h[2]):1,endLineNumber:h[4]?parseInt(h[4]):void 0,endColumn:h[4]?h[5]?parseInt(h[5]):1:void 0},d=d.with({fragment:""})),{selection:g,uri:d}}},54957:(rt,ye,y)=>{y.d(ye,{W6:()=>B,vH:()=>T});var b=y(3765),o=y(2106),K=y(67167),$=y(53720),L=y(27142);const U={ModesRegistry:"editor.modesRegistry"};class P{constructor(){this._onDidChangeLanguages=new o.vl,this.onDidChangeLanguages=this._onDidChangeLanguages.event,this._languages=[]}registerLanguage(g){return this._languages.push(g),this._onDidChangeLanguages.fire(void 0),{dispose:()=>{for(let h=0,l=this._languages.length;h<l;h++)if(this._languages[h]===g){this._languages.splice(h,1);return}}}}getLanguages(){return this._languages}}const B=new P;K.O.add(U.ModesRegistry,B);const T="plaintext";B.registerLanguage({id:T,extensions:[".txt"],aliases:[b.kg("plainText.alias","Plain Text"),"text"],mimetypes:[$.K.text]}),K.O.as(L.Fd.Configuration).registerDefaultConfigurations([{overrides:{"[plaintext]":{"editor.unicodeHighlight.ambiguousCharacters":!1,"editor.unicodeHighlight.invisibleCharacters":!1}}}])},55406:(rt,ye,y)=>{y.d(ye,{c:()=>K});var b=y(23877),o=y(50442);class K{static _handleEolEdits(L,U){let P;const B=[];for(const T of U)typeof T.eol=="number"&&(P=T.eol),T.range&&typeof T.text=="string"&&B.push(T);return typeof P=="number"&&L.hasModel()&&L.getModel().pushEOL(P),B}static _isFullModelReplaceEdit(L,U){if(!L.hasModel())return!1;const P=L.getModel(),B=P.validateRange(U.range);return P.getFullModelRange().equalsRange(B)}static execute(L,U,P){P&&L.pushUndoStop();const B=K._handleEolEdits(L,U);B.length===1&&K._isFullModelReplaceEdit(L,B[0])?L.executeEdits("formatEditsCommand",B.map(T=>b.k.replace(o.Q.lift(T.range),T.text))):L.executeEdits("formatEditsCommand",B.map(T=>b.k.replaceMove(o.Q.lift(T.range),T.text))),P&&L.pushUndoStop()}}},55893:(rt,ye,y)=>{y.r(ye),y.d(ye,{PixelRatio:()=>B,addMatchMediaChangeListener:()=>P,getZoomFactor:()=>T,isAndroid:()=>C,isChrome:()=>h,isElectron:()=>w,isFirefox:()=>d,isSafari:()=>l,isStandalone:()=>v,isWebKit:()=>g,isWebkitWebView:()=>u});var b=y(2106),o=y(10998);class K{constructor(){this._zoomFactor=1}getZoomFactor(){return this._zoomFactor}}K.INSTANCE=new K;class $ extends o.jG{constructor(){super(),this._onDidChange=this._register(new b.vl),this.onDidChange=this._onDidChange.event,this._listener=()=>this._handleChange(!0),this._mediaQueryList=null,this._handleChange(!1)}_handleChange(D){var x;(x=this._mediaQueryList)===null||x===void 0||x.removeEventListener("change",this._listener),this._mediaQueryList=matchMedia(`(resolution: ${window.devicePixelRatio}dppx)`),this._mediaQueryList.addEventListener("change",this._listener),D&&this._onDidChange.fire()}}class L extends o.jG{constructor(){super(),this._onDidChange=this._register(new b.vl),this.onDidChange=this._onDidChange.event,this._value=this._getPixelRatio();const D=this._register(new $);this._register(D.onDidChange(()=>{this._value=this._getPixelRatio(),this._onDidChange.fire(this._value)}))}get value(){return this._value}_getPixelRatio(){const D=document.createElement("canvas").getContext("2d"),x=window.devicePixelRatio||1,A=D.webkitBackingStorePixelRatio||D.mozBackingStorePixelRatio||D.msBackingStorePixelRatio||D.oBackingStorePixelRatio||D.backingStorePixelRatio||1;return x/A}}class U{constructor(){this._pixelRatioMonitor=null}_getOrCreatePixelRatioMonitor(){return this._pixelRatioMonitor||(this._pixelRatioMonitor=(0,o.lC)(new L)),this._pixelRatioMonitor}get value(){return this._getOrCreatePixelRatioMonitor().value}get onDidChange(){return this._getOrCreatePixelRatioMonitor().onDidChange}}function P(k,D){typeof k=="string"&&(k=window.matchMedia(k)),k.addEventListener("change",D)}const B=new U;function T(){return K.INSTANCE.getZoomFactor()}const p=navigator.userAgent,d=p.indexOf("Firefox")>=0,g=p.indexOf("AppleWebKit")>=0,h=p.indexOf("Chrome")>=0,l=!h&&p.indexOf("Safari")>=0,u=!h&&!l&&g,w=p.indexOf("Electron/")>=0,C=p.indexOf("Android")>=0;let m=!1;if(window.matchMedia){const k=window.matchMedia("(display-mode: standalone)");m=k.matches,P(k,({matches:D})=>{m=D})}function v(){return m}},56071:(rt,ye,y)=>{y.d(ye,{b:()=>o});var b=y(82399);const o=(0,b.u1)("keybindingService")},56158:(rt,ye,y)=>{y.d(ye,{N:()=>K,c2:()=>$});var b=y(13338),o=y(37512);class K{constructor(P){this.values=P,this.prefixSum=new Uint32Array(P.length),this.prefixSumValidIndex=new Int32Array(1),this.prefixSumValidIndex[0]=-1}insertValues(P,B){P=(0,o.j)(P);const T=this.values,p=this.prefixSum,d=B.length;return d===0?!1:(this.values=new Uint32Array(T.length+d),this.values.set(T.subarray(0,P),0),this.values.set(T.subarray(P),P+d),this.values.set(B,P),P-1<this.prefixSumValidIndex[0]&&(this.prefixSumValidIndex[0]=P-1),this.prefixSum=new Uint32Array(this.values.length),this.prefixSumValidIndex[0]>=0&&this.prefixSum.set(p.subarray(0,this.prefixSumValidIndex[0]+1)),!0)}setValue(P,B){return P=(0,o.j)(P),B=(0,o.j)(B),this.values[P]===B?!1:(this.values[P]=B,P-1<this.prefixSumValidIndex[0]&&(this.prefixSumValidIndex[0]=P-1),!0)}removeValues(P,B){P=(0,o.j)(P),B=(0,o.j)(B);const T=this.values,p=this.prefixSum;if(P>=T.length)return!1;const d=T.length-P;return B>=d&&(B=d),B===0?!1:(this.values=new Uint32Array(T.length-B),this.values.set(T.subarray(0,P),0),this.values.set(T.subarray(P+B),P),this.prefixSum=new Uint32Array(this.values.length),P-1<this.prefixSumValidIndex[0]&&(this.prefixSumValidIndex[0]=P-1),this.prefixSumValidIndex[0]>=0&&this.prefixSum.set(p.subarray(0,this.prefixSumValidIndex[0]+1)),!0)}getTotalSum(){return this.values.length===0?0:this._getPrefixSum(this.values.length-1)}getPrefixSum(P){return P<0?0:(P=(0,o.j)(P),this._getPrefixSum(P))}_getPrefixSum(P){if(P<=this.prefixSumValidIndex[0])return this.prefixSum[P];let B=this.prefixSumValidIndex[0]+1;B===0&&(this.prefixSum[0]=this.values[0],B++),P>=this.values.length&&(P=this.values.length-1);for(let T=B;T<=P;T++)this.prefixSum[T]=this.prefixSum[T-1]+this.values[T];return this.prefixSumValidIndex[0]=Math.max(this.prefixSumValidIndex[0],P),this.prefixSum[P]}getIndexOf(P){P=Math.floor(P),this.getTotalSum();let B=0,T=this.values.length-1,p=0,d=0,g=0;for(;B<=T;)if(p=B+(T-B)/2|0,d=this.prefixSum[p],g=d-this.values[p],P<g)T=p-1;else if(P>=d)B=p+1;else break;return new L(p,P-g)}}class ${constructor(P){this._values=P,this._isValid=!1,this._validEndIndex=-1,this._prefixSum=[],this._indexBySum=[]}getTotalSum(){return this._ensureValid(),this._indexBySum.length}getPrefixSum(P){return this._ensureValid(),P===0?0:this._prefixSum[P-1]}getIndexOf(P){this._ensureValid();const B=this._indexBySum[P],T=B>0?this._prefixSum[B-1]:0;return new L(B,P-T)}removeValues(P,B){this._values.splice(P,B),this._invalidate(P)}insertValues(P,B){this._values=(0,b.nK)(this._values,P,B),this._invalidate(P)}_invalidate(P){this._isValid=!1,this._validEndIndex=Math.min(this._validEndIndex,P-1)}_ensureValid(){if(!this._isValid){for(let P=this._validEndIndex+1,B=this._values.length;P<B;P++){const T=this._values[P],p=P>0?this._prefixSum[P-1]:0;this._prefixSum[P]=p+T;for(let d=0;d<T;d++)this._indexBySum[p+d]=P}this._prefixSum.length=this._values.length,this._indexBySum.length=this._prefixSum[this._prefixSum.length-1],this._isValid=!0,this._validEndIndex=this._values.length-1}}setValue(P,B){this._values[P]!==B&&(this._values[P]=B,this._invalidate(P))}}class L{constructor(P,B){this.index=P,this.remainder=B,this._prefixSumIndexOfResultBrand=void 0,this.index=P,this.remainder=B}}},57445:(rt,ye,y)=>{y.d(ye,{f:()=>o});var b=y(15910);class o{constructor(L,U,P){this._lineTokensBrand=void 0,this._tokens=L,this._tokensCount=this._tokens.length>>>1,this._text=U,this._languageIdCodec=P}static createEmpty(L,U){const P=o.defaultTokenMetadata,B=new Uint32Array(2);return B[0]=L.length,B[1]=P,new o(B,L,U)}equals(L){return L instanceof o?this.slicedEquals(L,0,this._tokensCount):!1}slicedEquals(L,U,P){if(this._text!==L._text||this._tokensCount!==L._tokensCount)return!1;const B=U<<1,T=B+(P<<1);for(let p=B;p<T;p++)if(this._tokens[p]!==L._tokens[p])return!1;return!0}getLineContent(){return this._text}getCount(){return this._tokensCount}getStartOffset(L){return L>0?this._tokens[L-1<<1]:0}getMetadata(L){return this._tokens[(L<<1)+1]}getLanguageId(L){const U=this._tokens[(L<<1)+1],P=b.x.getLanguageId(U);return this._languageIdCodec.decodeLanguageId(P)}getStandardTokenType(L){const U=this._tokens[(L<<1)+1];return b.x.getTokenType(U)}getForeground(L){const U=this._tokens[(L<<1)+1];return b.x.getForeground(U)}getClassName(L){const U=this._tokens[(L<<1)+1];return b.x.getClassNameFromMetadata(U)}getInlineStyle(L,U){const P=this._tokens[(L<<1)+1];return b.x.getInlineStyleFromMetadata(P,U)}getPresentation(L){const U=this._tokens[(L<<1)+1];return b.x.getPresentationFromMetadata(U)}getEndOffset(L){return this._tokens[L<<1]}findTokenIndexAtOffset(L){return o.findIndexInTokensArray(this._tokens,L)}inflate(){return this}sliceAndInflate(L,U,P){return new K(this,L,U,P)}static convertToEndOffset(L,U){const B=(L.length>>>1)-1;for(let T=0;T<B;T++)L[T<<1]=L[T+1<<1];L[B<<1]=U}static findIndexInTokensArray(L,U){if(L.length<=2)return 0;let P=0,B=(L.length>>>1)-1;for(;P<B;){const T=P+Math.floor((B-P)/2),p=L[T<<1];if(p===U)return T+1;p<U?P=T+1:p>U&&(B=T)}return P}withInserted(L){if(L.length===0)return this;let U=0,P=0,B="";const T=new Array;let p=0;for(;;){const d=U<this._tokensCount?this._tokens[U<<1]:-1,g=P<L.length?L[P]:null;if(d!==-1&&(g===null||d<=g.offset)){B+=this._text.substring(p,d);const h=this._tokens[(U<<1)+1];T.push(B.length,h),U++,p=d}else if(g){if(g.offset>p){B+=this._text.substring(p,g.offset);const h=this._tokens[(U<<1)+1];T.push(B.length,h),p=g.offset}B+=g.text,T.push(B.length,g.tokenMetadata),P++}else break}return new o(new Uint32Array(T),B,this._languageIdCodec)}}o.defaultTokenMetadata=(32768|2<<24)>>>0;class K{constructor(L,U,P,B){this._source=L,this._startOffset=U,this._endOffset=P,this._deltaOffset=B,this._firstTokenIndex=L.findTokenIndexAtOffset(U),this._tokensCount=0;for(let T=this._firstTokenIndex,p=L.getCount();T<p&&!(L.getStartOffset(T)>=P);T++)this._tokensCount++}getMetadata(L){return this._source.getMetadata(this._firstTokenIndex+L)}getLanguageId(L){return this._source.getLanguageId(this._firstTokenIndex+L)}getLineContent(){return this._source.getLineContent().substring(this._startOffset,this._endOffset)}equals(L){return L instanceof K?this._startOffset===L._startOffset&&this._endOffset===L._endOffset&&this._deltaOffset===L._deltaOffset&&this._source.slicedEquals(L._source,this._firstTokenIndex,this._tokensCount):!1}getCount(){return this._tokensCount}getForeground(L){return this._source.getForeground(this._firstTokenIndex+L)}getEndOffset(L){const U=this._source.getEndOffset(this._firstTokenIndex+L);return Math.min(this._endOffset,U)-this._startOffset+this._deltaOffset}getClassName(L){return this._source.getClassName(this._firstTokenIndex+L)}getInlineStyle(L,U){return this._source.getInlineStyle(this._firstTokenIndex+L,U)}getPresentation(L){return this._source.getPresentation(this._firstTokenIndex+L)}findTokenIndexAtOffset(L){return this._source.findTokenIndexAtOffset(L+this._startOffset-this._deltaOffset)-this._firstTokenIndex}}},57999:(rt,ye,y)=>{y.d(ye,{P:()=>$});var b=y(16844),o=y(62549);function K(L,U,P){let B=0;for(let p=0;p<L.length;p++)L.charAt(p)===" "?B=o.A.nextIndentTabStop(B,U):B++;let T="";if(!P){const p=Math.floor(B/U);B=B%U;for(let d=0;d<p;d++)T+=" "}for(let p=0;p<B;p++)T+=" ";return T}function $(L,U,P){let B=b.HG(L);return B===-1&&(B=L.length),K(L.substring(0,B),U,P)+L.substring(B)}},58067:(rt,ye,y)=>{y.d(ye,{D8:()=>l,Xe:()=>m,ZG:()=>w,ez:()=>u,is:()=>h,nI:()=>C});var b=y(50350),o=y(26048),K=y(2106),$=y(17954),L=y(10998),U=y(85525),P=y(59715),B=y(96655),T=y(82399),p=y(89044),d=function(v,k,D,x){var A=arguments.length,W=A<3?k:x===null?x=Object.getOwnPropertyDescriptor(k,D):x,Y;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")W=Reflect.decorate(v,k,D,x);else for(var ne=v.length-1;ne>=0;ne--)(Y=v[ne])&&(W=(A<3?Y(W):A>3?Y(k,D,W):Y(k,D))||W);return A>3&&W&&Object.defineProperty(k,D,W),W},g=function(v,k){return function(D,x){k(D,x,v)}};function h(v){return v.command!==void 0}class l{constructor(k){if(l._instances.has(k))throw new TypeError(`MenuId with identifier '${k}' already exists. Use MenuId.for(ident) or a unique identifier`);l._instances.set(k,this),this.id=k}}l._instances=new Map,l.CommandPalette=new l("CommandPalette"),l.DebugBreakpointsContext=new l("DebugBreakpointsContext"),l.DebugCallStackContext=new l("DebugCallStackContext"),l.DebugConsoleContext=new l("DebugConsoleContext"),l.DebugVariablesContext=new l("DebugVariablesContext"),l.DebugWatchContext=new l("DebugWatchContext"),l.DebugToolBar=new l("DebugToolBar"),l.DebugToolBarStop=new l("DebugToolBarStop"),l.EditorContext=new l("EditorContext"),l.SimpleEditorContext=new l("SimpleEditorContext"),l.EditorContextCopy=new l("EditorContextCopy"),l.EditorContextPeek=new l("EditorContextPeek"),l.EditorContextShare=new l("EditorContextShare"),l.EditorTitle=new l("EditorTitle"),l.EditorTitleRun=new l("EditorTitleRun"),l.EditorTitleContext=new l("EditorTitleContext"),l.EmptyEditorGroup=new l("EmptyEditorGroup"),l.EmptyEditorGroupContext=new l("EmptyEditorGroupContext"),l.ExplorerContext=new l("ExplorerContext"),l.ExtensionContext=new l("ExtensionContext"),l.GlobalActivity=new l("GlobalActivity"),l.CommandCenter=new l("CommandCenter"),l.LayoutControlMenuSubmenu=new l("LayoutControlMenuSubmenu"),l.LayoutControlMenu=new l("LayoutControlMenu"),l.MenubarMainMenu=new l("MenubarMainMenu"),l.MenubarAppearanceMenu=new l("MenubarAppearanceMenu"),l.MenubarDebugMenu=new l("MenubarDebugMenu"),l.MenubarEditMenu=new l("MenubarEditMenu"),l.MenubarCopy=new l("MenubarCopy"),l.MenubarFileMenu=new l("MenubarFileMenu"),l.MenubarGoMenu=new l("MenubarGoMenu"),l.MenubarHelpMenu=new l("MenubarHelpMenu"),l.MenubarLayoutMenu=new l("MenubarLayoutMenu"),l.MenubarNewBreakpointMenu=new l("MenubarNewBreakpointMenu"),l.MenubarPanelAlignmentMenu=new l("MenubarPanelAlignmentMenu"),l.MenubarPanelPositionMenu=new l("MenubarPanelPositionMenu"),l.MenubarPreferencesMenu=new l("MenubarPreferencesMenu"),l.MenubarRecentMenu=new l("MenubarRecentMenu"),l.MenubarSelectionMenu=new l("MenubarSelectionMenu"),l.MenubarShare=new l("MenubarShare"),l.MenubarSwitchEditorMenu=new l("MenubarSwitchEditorMenu"),l.MenubarSwitchGroupMenu=new l("MenubarSwitchGroupMenu"),l.MenubarTerminalMenu=new l("MenubarTerminalMenu"),l.MenubarViewMenu=new l("MenubarViewMenu"),l.MenubarHomeMenu=new l("MenubarHomeMenu"),l.OpenEditorsContext=new l("OpenEditorsContext"),l.ProblemsPanelContext=new l("ProblemsPanelContext"),l.SCMChangeContext=new l("SCMChangeContext"),l.SCMResourceContext=new l("SCMResourceContext"),l.SCMResourceFolderContext=new l("SCMResourceFolderContext"),l.SCMResourceGroupContext=new l("SCMResourceGroupContext"),l.SCMSourceControl=new l("SCMSourceControl"),l.SCMTitle=new l("SCMTitle"),l.SearchContext=new l("SearchContext"),l.StatusBarWindowIndicatorMenu=new l("StatusBarWindowIndicatorMenu"),l.StatusBarRemoteIndicatorMenu=new l("StatusBarRemoteIndicatorMenu"),l.TestItem=new l("TestItem"),l.TestItemGutter=new l("TestItemGutter"),l.TestPeekElement=new l("TestPeekElement"),l.TestPeekTitle=new l("TestPeekTitle"),l.TouchBarContext=new l("TouchBarContext"),l.TitleBarContext=new l("TitleBarContext"),l.TitleBarTitleContext=new l("TitleBarTitleContext"),l.TunnelContext=new l("TunnelContext"),l.TunnelPrivacy=new l("TunnelPrivacy"),l.TunnelProtocol=new l("TunnelProtocol"),l.TunnelPortInline=new l("TunnelInline"),l.TunnelTitle=new l("TunnelTitle"),l.TunnelLocalAddressInline=new l("TunnelLocalAddressInline"),l.TunnelOriginInline=new l("TunnelOriginInline"),l.ViewItemContext=new l("ViewItemContext"),l.ViewContainerTitle=new l("ViewContainerTitle"),l.ViewContainerTitleContext=new l("ViewContainerTitleContext"),l.ViewTitle=new l("ViewTitle"),l.ViewTitleContext=new l("ViewTitleContext"),l.CommentThreadTitle=new l("CommentThreadTitle"),l.CommentThreadActions=new l("CommentThreadActions"),l.CommentTitle=new l("CommentTitle"),l.CommentActions=new l("CommentActions"),l.InteractiveToolbar=new l("InteractiveToolbar"),l.InteractiveCellTitle=new l("InteractiveCellTitle"),l.InteractiveCellDelete=new l("InteractiveCellDelete"),l.InteractiveCellExecute=new l("InteractiveCellExecute"),l.InteractiveInputExecute=new l("InteractiveInputExecute"),l.NotebookToolbar=new l("NotebookToolbar"),l.NotebookCellTitle=new l("NotebookCellTitle"),l.NotebookCellDelete=new l("NotebookCellDelete"),l.NotebookCellInsert=new l("NotebookCellInsert"),l.NotebookCellBetween=new l("NotebookCellBetween"),l.NotebookCellListTop=new l("NotebookCellTop"),l.NotebookCellExecute=new l("NotebookCellExecute"),l.NotebookCellExecutePrimary=new l("NotebookCellExecutePrimary"),l.NotebookDiffCellInputTitle=new l("NotebookDiffCellInputTitle"),l.NotebookDiffCellMetadataTitle=new l("NotebookDiffCellMetadataTitle"),l.NotebookDiffCellOutputsTitle=new l("NotebookDiffCellOutputsTitle"),l.NotebookOutputToolbar=new l("NotebookOutputToolbar"),l.NotebookEditorLayoutConfigure=new l("NotebookEditorLayoutConfigure"),l.NotebookKernelSource=new l("NotebookKernelSource"),l.BulkEditTitle=new l("BulkEditTitle"),l.BulkEditContext=new l("BulkEditContext"),l.TimelineItemContext=new l("TimelineItemContext"),l.TimelineTitle=new l("TimelineTitle"),l.TimelineTitleContext=new l("TimelineTitleContext"),l.TimelineFilterSubMenu=new l("TimelineFilterSubMenu"),l.AccountsContext=new l("AccountsContext"),l.PanelTitle=new l("PanelTitle"),l.AuxiliaryBarTitle=new l("AuxiliaryBarTitle"),l.TerminalInstanceContext=new l("TerminalInstanceContext"),l.TerminalEditorInstanceContext=new l("TerminalEditorInstanceContext"),l.TerminalNewDropdownContext=new l("TerminalNewDropdownContext"),l.TerminalTabContext=new l("TerminalTabContext"),l.TerminalTabEmptyAreaContext=new l("TerminalTabEmptyAreaContext"),l.TerminalInlineTabContext=new l("TerminalInlineTabContext"),l.WebviewContext=new l("WebviewContext"),l.InlineCompletionsActions=new l("InlineCompletionsActions"),l.NewFile=new l("NewFile"),l.MergeToolbar=new l("MergeToolbar"),l.MergeInput1Toolbar=new l("MergeToolbar1Toolbar"),l.MergeInput2Toolbar=new l("MergeToolbar2Toolbar");const u=(0,T.u1)("menuService"),w=new class{constructor(){this._commands=new Map,this._menuItems=new Map,this._onDidChangeMenu=new K.vl,this.onDidChangeMenu=this._onDidChangeMenu.event,this._commandPaletteChangeEvent={has:v=>v===l.CommandPalette}}addCommand(v){return this.addCommands($.f.single(v))}addCommands(v){for(const k of v)this._commands.set(k.id,k);return this._onDidChangeMenu.fire(this._commandPaletteChangeEvent),(0,L.s)(()=>{let k=!1;for(const D of v)k=this._commands.delete(D.id)||k;k&&this._onDidChangeMenu.fire(this._commandPaletteChangeEvent)})}getCommand(v){return this._commands.get(v)}getCommands(){const v=new Map;return this._commands.forEach((k,D)=>v.set(D,k)),v}appendMenuItem(v,k){return this.appendMenuItems($.f.single({id:v,item:k}))}appendMenuItems(v){const k=new Set,D=new U.w;for(const{id:x,item:A}of v){let W=this._menuItems.get(x);W||(W=new U.w,this._menuItems.set(x,W)),D.push(W.push(A)),k.add(x)}return this._onDidChangeMenu.fire(k),(0,L.s)(()=>{if(D.size>0){for(const x of D)x();this._onDidChangeMenu.fire(k),D.clear()}})}getMenuItems(v){let k;return this._menuItems.has(v)?k=[...this._menuItems.get(v)]:k=[],v===l.CommandPalette&&this._appendImplicitItems(k),k}_appendImplicitItems(v){const k=new Set;for(const D of v)h(D)&&(k.add(D.command.id),D.alt&&k.add(D.alt.id));this._commands.forEach((D,x)=>{k.has(x)||v.push({command:D})})}};class C extends b.YH{constructor(k,D,x,A){super(`submenuitem.${k.submenu.id}`,typeof k.title=="string"?k.title:k.title.value,[],"submenu"),this.item=k,this._menuService=D,this._contextKeyService=x,this._options=A}get actions(){const k=[],D=this._menuService.createMenu(this.item.submenu,this._contextKeyService),x=D.getActions(this._options);D.dispose();for(const[,A]of x)A.length>0&&(k.push(...A),k.push(new b.wv));return k.length&&k.pop(),k}}let m=class za{constructor(k,D,x,A,W,Y){var ne,j;if(this.hideActions=A,this._commandService=Y,this.id=k.id,this.label=x?.renderShortTitle&&k.shortTitle?typeof k.shortTitle=="string"?k.shortTitle:k.shortTitle.value:typeof k.title=="string"?k.title:k.title.value,this.tooltip=(j=typeof k.tooltip=="string"?k.tooltip:(ne=k.tooltip)===null||ne===void 0?void 0:ne.value)!==null&&j!==void 0?j:"",this.enabled=!k.precondition||W.contextMatchesRules(k.precondition),this.checked=void 0,k.toggled){const Q=k.toggled.condition?k.toggled:{condition:k.toggled};this.checked=W.contextMatchesRules(Q.condition),this.checked&&Q.tooltip&&(this.tooltip=typeof Q.tooltip=="string"?Q.tooltip:Q.tooltip.value),Q.title&&(this.label=typeof Q.title=="string"?Q.title:Q.title.value)}this.item=k,this.alt=D?new za(D,void 0,x,A,W,Y):void 0,this._options=x,p.L0.isThemeIcon(k.icon)&&(this.class=o.j3.asClassName(k.icon))}dispose(){}run(...k){var D,x;let A=[];return!((D=this._options)===null||D===void 0)&&D.arg&&(A=[...A,this._options.arg]),!((x=this._options)===null||x===void 0)&&x.shouldForwardArgs&&(A=[...A,...k]),this._commandService.executeCommand(this.id,...A)}};m=d([g(4,B.fN),g(5,P.wT)],m)},58574:(rt,ye,y)=>{y.d(ye,{$z:()=>l,BA:()=>w,DW:()=>u,Hh:()=>B,Qn:()=>C,dO:()=>h,i_:()=>g,nz:()=>P,wt:()=>d});var b=y(14333),o=y(10176),K=y(9715),$=y(65958),L=y(10998),U=y(4874);class P{constructor(D,x){this.x=D,this.y=x,this._pageCoordinatesBrand=void 0}toClientCoordinates(){return new B(this.x-b.Yx.scrollX,this.y-b.Yx.scrollY)}}class B{constructor(D,x){this.clientX=D,this.clientY=x,this._clientCoordinatesBrand=void 0}toPageCoordinates(){return new P(this.clientX+b.Yx.scrollX,this.clientY+b.Yx.scrollY)}}class T{constructor(D,x,A,W){this.x=D,this.y=x,this.width=A,this.height=W,this._editorPagePositionBrand=void 0}}class p{constructor(D,x){this.x=D,this.y=x,this._positionRelativeToEditorBrand=void 0}}function d(k){const D=b.BK(k);return new T(D.left,D.top,D.width,D.height)}function g(k,D,x){const A=D.width/k.offsetWidth,W=D.height/k.offsetHeight,Y=(x.x-D.x)/A,ne=(x.y-D.y)/W;return new p(Y,ne)}class h extends K.P{constructor(D,x,A){super(D),this._editorMouseEventBrand=void 0,this.isFromPointerCapture=x,this.pos=new P(this.posx,this.posy),this.editorPos=d(A),this.relativePos=g(A,this.editorPos,this.pos)}}class l{constructor(D){this._editorViewDomNode=D}_create(D){return new h(D,!1,this._editorViewDomNode)}onContextMenu(D,x){return b.ko(D,"contextmenu",A=>{x(this._create(A))})}onMouseUp(D,x){return b.ko(D,"mouseup",A=>{x(this._create(A))})}onMouseDown(D,x){return b.ko(D,b.Bx.MOUSE_DOWN,A=>{x(this._create(A))})}onPointerDown(D,x){return b.ko(D,b.Bx.POINTER_DOWN,A=>{x(this._create(A),A.pointerId)})}onMouseLeave(D,x){return b.ko(D,b.Bx.MOUSE_LEAVE,A=>{x(this._create(A))})}onMouseMove(D,x){return b.ko(D,"mousemove",A=>x(this._create(A)))}}class u{constructor(D){this._editorViewDomNode=D}_create(D){return new h(D,!1,this._editorViewDomNode)}onPointerUp(D,x){return b.ko(D,"pointerup",A=>{x(this._create(A))})}onPointerDown(D,x){return b.ko(D,b.Bx.POINTER_DOWN,A=>{x(this._create(A),A.pointerId)})}onPointerLeave(D,x){return b.ko(D,b.Bx.POINTER_LEAVE,A=>{x(this._create(A))})}onPointerMove(D,x){return b.ko(D,"pointermove",A=>x(this._create(A)))}}class w extends L.jG{constructor(D){super(),this._editorViewDomNode=D,this._globalPointerMoveMonitor=this._register(new o._),this._keydownListener=null}startMonitoring(D,x,A,W,Y){this._keydownListener=b.b2(document,"keydown",ne=>{ne.toKeybinding().isModifierKey()||this._globalPointerMoveMonitor.stopMonitoring(!0,ne.browserEvent)},!0),this._globalPointerMoveMonitor.startMonitoring(D,x,A,ne=>{W(new h(ne,!0,this._editorViewDomNode))},ne=>{this._keydownListener.dispose(),Y(ne)})}stopMonitoring(){this._globalPointerMoveMonitor.stopMonitoring(!0)}}class C{constructor(D){this._editor=D,this._instanceId=++C._idPool,this._counter=0,this._rules=new Map,this._garbageCollectionScheduler=new $.uC(()=>this.garbageCollect(),1e3)}createClassNameRef(D){const x=this.getOrCreateRule(D);return x.increaseRefCount(),{className:x.className,dispose:()=>{x.decreaseRefCount(),this._garbageCollectionScheduler.schedule()}}}getOrCreateRule(D){const x=this.computeUniqueKey(D);let A=this._rules.get(x);if(!A){const W=this._counter++;A=new m(x,`dyn-rule-${this._instanceId}-${W}`,b.Cl(this._editor.getContainerDomNode())?this._editor.getContainerDomNode():void 0,D),this._rules.set(x,A)}return A}computeUniqueKey(D){return JSON.stringify(D)}garbageCollect(){for(const D of this._rules.values())D.hasReferences()||(this._rules.delete(D.key),D.dispose())}}C._idPool=0;class m{constructor(D,x,A,W){this.key=D,this.className=x,this.properties=W,this._referenceCount=0,this._styleElement=b.li(A),this._styleElement.textContent=this.getCssText(this.className,this.properties)}getCssText(D,x){let A=`.${D} {`;for(const W in x){const Y=x[W];let ne;typeof Y=="object"?ne=`var(${(0,U.Bbc)(Y.id)})`:ne=Y;const j=v(W);A+=` ${j}: ${ne};`}return A+=` }`,A}dispose(){this._styleElement.remove()}increaseRefCount(){this._referenceCount++}decreaseRefCount(){this._referenceCount--}hasReferences(){return this._referenceCount>0}}function v(k){return k.replace(/(^[A-Z])/,([D])=>D.toLowerCase()).replace(/([A-Z])/g,([D])=>`-${D.toLowerCase()}`)}},59407:(rt,ye,y)=>{y.d(ye,{h5:()=>d,vr:()=>T,xE:()=>p});var b=y(14333),o=y(63339);const K=2e4;let $,L,U,P,B;function T(h){$=document.createElement("div"),$.className="monaco-aria-container";const l=()=>{const w=document.createElement("div");return w.className="monaco-alert",w.setAttribute("role","alert"),w.setAttribute("aria-atomic","true"),$.appendChild(w),w};L=l(),U=l();const u=()=>{const w=document.createElement("div");return w.className="monaco-status",w.setAttribute("role","complementary"),w.setAttribute("aria-live","polite"),w.setAttribute("aria-atomic","true"),$.appendChild(w),w};P=u(),B=u(),h.appendChild($)}function p(h){$&&(L.textContent!==h?(b.w_(U),g(L,h)):(b.w_(L),g(U,h)))}function d(h){$&&(o.zx?p(h):P.textContent!==h?(b.w_(B),g(P,h)):(b.w_(P),g(B,h)))}function g(h,l){b.w_(h),l.length>K&&(l=l.substr(0,K)),h.textContent=l,h.style.visibility="hidden",h.style.visibility="visible"}},59715:(rt,ye,y)=>{y.d(ye,{wT:()=>P,wb:()=>B});var b=y(2106),o=y(17954),K=y(10998),$=y(85525),L=y(79359),U=y(82399);const P=(0,U.u1)("commandService"),B=new class{constructor(){this._commands=new Map,this._onDidRegisterCommand=new b.vl,this.onDidRegisterCommand=this._onDidRegisterCommand.event}registerCommand(p,d){if(!p)throw new Error("invalid command");if(typeof p=="string"){if(!d)throw new Error("invalid command");return this.registerCommand({id:p,handler:d})}if(p.description){const w=[];for(const m of p.description.args)w.push(m.constraint);const C=p.handler;p.handler=function(m,...v){return(0,L.jx)(v,w),C(m,...v)}}const{id:g}=p;let h=this._commands.get(g);h||(h=new $.w,this._commands.set(g,h));const l=h.unshift(p),u=(0,K.s)(()=>{l();const w=this._commands.get(g);w?.isEmpty()&&this._commands.delete(g)});return this._onDidRegisterCommand.fire(g),u}registerCommandAlias(p,d){return B.registerCommand(p,(g,...h)=>g.get(P).executeCommand(d,...h))}getCommand(p){const d=this._commands.get(p);if(!(!d||d.isEmpty()))return o.f.first(d)}getCommands(){const p=new Map;for(const d of this._commands.keys()){const g=this.getCommand(d);g&&p.set(d,g)}return p}},T={_serviceBrand:void 0,onWillExecuteCommand:()=>K.jG.None,onDidExecuteCommand:()=>K.jG.None,executeCommand(){return Promise.resolve(void 0)}};B.registerCommand("noop",()=>{})},59922:(rt,ye,y)=>{y.d(ye,{Ho:()=>pt,kI:()=>zt,Bz:()=>_n});var b=y(13338),o=y(94901),K=y(94327),$=y(2106),L=y(10998),U=y(16844),P=y(37264),B=y(3902),T=y(57999),p=y(15365),d=y(50442),g=y(93702),h=y(12590),l=y(77922),u=y(52394),w=y(66055);class C{constructor(a,n,c,I){this.range=a,this.nestingLevel=n,this.nestingLevelOfEqualBracketType=c,this.isInvalid=I}}class m{constructor(a,n,c,I,F,J){this.range=a,this.openingBracketRange=n,this.closingBracketRange=c,this.nestingLevel=I,this.nestingLevelOfEqualBracketType=F,this.bracketPairNode=J}get openingBracketInfo(){return this.bracketPairNode.openingBracket.bracketInfo}}class v extends m{constructor(a,n,c,I,F,J,ae){super(a,n,c,I,F,J),this.minVisibleColumnIndentation=ae}}var k=y(22994),D=y(85702),x=y(34883),A=y(68302),W=y(60756),Y=y(33206);class ne extends L.jG{constructor(a,n){if(super(),this.textModel=a,this.getLanguageConfiguration=n,this.didChangeEmitter=new $.vl,this.denseKeyProvider=new W.Mg,this.brackets=new D.Z(this.denseKeyProvider,this.getLanguageConfiguration),this.onDidChange=this.didChangeEmitter.event,a.tokenization.backgroundTokenizationState===0){const c=this.brackets.getSingleLanguageBracketTokens(this.textModel.getLanguageId()),I=new Y._(this.textModel.getValue(),c);this.initialAstWithoutTokens=(0,A.T)(I,[],void 0,!0),this.astWithTokens=this.initialAstWithoutTokens}else a.tokenization.backgroundTokenizationState===2?(this.initialAstWithoutTokens=void 0,this.astWithTokens=this.parseDocumentFromTextBuffer([],void 0,!1)):a.tokenization.backgroundTokenizationState===1&&(this.initialAstWithoutTokens=this.parseDocumentFromTextBuffer([],void 0,!0),this.astWithTokens=this.initialAstWithoutTokens)}didLanguageChange(a){return this.brackets.didLanguageChange(a)}handleDidChangeBackgroundTokenizationState(){if(this.textModel.tokenization.backgroundTokenizationState===2){const a=this.initialAstWithoutTokens===void 0;this.initialAstWithoutTokens=void 0,a||this.didChangeEmitter.fire()}}handleDidChangeTokens({ranges:a}){const n=a.map(c=>new k.c((0,x.qe)(c.fromLineNumber-1,0),(0,x.qe)(c.toLineNumber,0),(0,x.qe)(c.toLineNumber-c.fromLineNumber+1,0)));this.astWithTokens=this.parseDocumentFromTextBuffer(n,this.astWithTokens,!1),this.initialAstWithoutTokens||this.didChangeEmitter.fire()}handleContentChanged(a){const n=a.changes.map(c=>{const I=d.Q.lift(c.range);return new k.c((0,x.VL)(I.getStartPosition()),(0,x.VL)(I.getEndPosition()),(0,x.rR)(c.text))}).reverse();this.astWithTokens=this.parseDocumentFromTextBuffer(n,this.astWithTokens,!1),this.initialAstWithoutTokens&&(this.initialAstWithoutTokens=this.parseDocumentFromTextBuffer(n,this.initialAstWithoutTokens,!1))}parseDocumentFromTextBuffer(a,n,c){const F=n,J=new Y.tk(this.textModel,this.brackets);return(0,A.T)(J,a,F,c)}getBracketsInRange(a){const n=(0,x.qe)(a.startLineNumber-1,a.startColumn-1),c=(0,x.qe)(a.endLineNumber-1,a.endColumn-1),I=new Array,F=this.initialAstWithoutTokens||this.astWithTokens;return X(F,x.Vp,F.length,n,c,I,0,new Map),I}getBracketPairsInRange(a,n){const c=new Array,I=(0,x.VL)(a.getStartPosition()),F=(0,x.VL)(a.getEndPosition()),J=this.initialAstWithoutTokens||this.astWithTokens,ae=new R(c,n,this.textModel);return H(J,x.Vp,J.length,I,F,ae,0,new Map),c}getFirstBracketAfter(a){const n=this.initialAstWithoutTokens||this.astWithTokens;return Q(n,x.Vp,n.length,(0,x.VL)(a))}getFirstBracketBefore(a){const n=this.initialAstWithoutTokens||this.astWithTokens;return j(n,x.Vp,n.length,(0,x.VL)(a))}}function j(xe,a,n,c){if(xe.kind===4||xe.kind===2){const I=[];for(const F of xe.children)n=(0,x.QB)(a,F.length),I.push({nodeOffsetStart:a,nodeOffsetEnd:n}),a=n;for(let F=I.length-1;F>=0;F--){const{nodeOffsetStart:J,nodeOffsetEnd:ae}=I[F];if((0,x.zG)(J,c)){const de=j(xe.children[F],J,ae,c);if(de)return de}}return null}else{if(xe.kind===3)return null;if(xe.kind===1){const I=(0,x.Qx)(a,n);return{bracketInfo:xe.bracketInfo,range:I}}}return null}function Q(xe,a,n,c){if(xe.kind===4||xe.kind===2){for(const I of xe.children){if(n=(0,x.QB)(a,I.length),(0,x.zG)(c,n)){const F=Q(I,a,n,c);if(F)return F}a=n}return null}else{if(xe.kind===3)return null;if(xe.kind===1){const I=(0,x.Qx)(a,n);return{bracketInfo:xe.bracketInfo,range:I}}}return null}function X(xe,a,n,c,I,F,J,ae){if(!(J>200)){if(xe.kind===4)for(const de of xe.children)n=(0,x.QB)(a,de.length),(0,x.vr)(a,I)&&(0,x.o0)(n,c)&&X(de,a,n,c,I,F,J,ae),a=n;else if(xe.kind===2){let de=0;if(ae){let Ce=ae.get(xe.openingBracket.text);Ce===void 0&&(Ce=0),de=Ce,Ce++,ae.set(xe.openingBracket.text,Ce)}{const Ce=xe.openingBracket;if(n=(0,x.QB)(a,Ce.length),(0,x.vr)(a,I)&&(0,x.o0)(n,c)){const Ee=(0,x.Qx)(a,n);F.push(new C(Ee,J,de,!xe.closingBracket))}a=n}if(xe.child){const Ce=xe.child;n=(0,x.QB)(a,Ce.length),(0,x.vr)(a,I)&&(0,x.o0)(n,c)&&X(Ce,a,n,c,I,F,J+1,ae),a=n}if(xe.closingBracket){const Ce=xe.closingBracket;if(n=(0,x.QB)(a,Ce.length),(0,x.vr)(a,I)&&(0,x.o0)(n,c)){const Ee=(0,x.Qx)(a,n);F.push(new C(Ee,J,de,!1))}a=n}ae?.set(xe.openingBracket.text,de)}else if(xe.kind===3){const de=(0,x.Qx)(a,n);F.push(new C(de,J-1,0,!0))}else if(xe.kind===1){const de=(0,x.Qx)(a,n);F.push(new C(de,J-1,0,!1))}}}class R{constructor(a,n,c){this.result=a,this.includeMinIndentation=n,this.textModel=c}}function H(xe,a,n,c,I,F,J,ae){var de;if(!(J>200))if(xe.kind===2){let Ce=0;if(ae){let He=ae.get(xe.openingBracket.text);He===void 0&&(He=0),Ce=He,He++,ae.set(xe.openingBracket.text,He)}const Ee=(0,x.QB)(a,xe.openingBracket.length);let Ne=-1;if(F.includeMinIndentation&&(Ne=xe.computeMinIndentation(a,F.textModel)),F.result.push(new v((0,x.Qx)(a,n),(0,x.Qx)(a,Ee),xe.closingBracket?(0,x.Qx)((0,x.QB)(Ee,((de=xe.child)===null||de===void 0?void 0:de.length)||x.Vp),n):void 0,J,Ce,xe,Ne)),a=Ee,xe.child){const He=xe.child;n=(0,x.QB)(a,He.length),(0,x.vr)(a,I)&&(0,x.o0)(n,c)&&H(He,a,n,c,I,F,J+1,ae)}ae?.set(xe.openingBracket.text,Ce)}else{let Ce=a;for(const Ee of xe.children){const Ne=Ce;Ce=(0,x.QB)(Ce,Ee.length),(0,x.vr)(Ne,I)&&(0,x.vr)(c,Ce)&&H(Ee,Ne,Ce,c,I,F,J,ae)}}}var Z=y(19184),N=y(1804);class G extends L.jG{constructor(a,n){super(),this.textModel=a,this.languageConfigurationService=n,this.bracketPairsTree=this._register(new L.HE),this.onDidChangeEmitter=new $.vl,this.onDidChange=this.onDidChangeEmitter.event,this.bracketsRequested=!1,this._register(this.languageConfigurationService.onDidChange(c=>{var I;(!c.languageId||!((I=this.bracketPairsTree.value)===null||I===void 0)&&I.object.didLanguageChange(c.languageId))&&(this.bracketPairsTree.clear(),this.updateBracketPairsTree())}))}get canBuildAST(){return this.textModel.getValueLength()<=5e6}handleDidChangeOptions(a){this.bracketPairsTree.clear(),this.updateBracketPairsTree()}handleDidChangeLanguage(a){this.bracketPairsTree.clear(),this.updateBracketPairsTree()}handleDidChangeContent(a){var n;(n=this.bracketPairsTree.value)===null||n===void 0||n.object.handleContentChanged(a)}handleDidChangeBackgroundTokenizationState(){var a;(a=this.bracketPairsTree.value)===null||a===void 0||a.object.handleDidChangeBackgroundTokenizationState()}handleDidChangeTokens(a){var n;(n=this.bracketPairsTree.value)===null||n===void 0||n.object.handleDidChangeTokens(a)}updateBracketPairsTree(){if(this.bracketsRequested&&this.canBuildAST){if(!this.bracketPairsTree.value){const a=new L.Cm;this.bracketPairsTree.value=O(a.add(new ne(this.textModel,n=>this.languageConfigurationService.getLanguageConfiguration(n))),a),a.add(this.bracketPairsTree.value.object.onDidChange(n=>this.onDidChangeEmitter.fire(n))),this.onDidChangeEmitter.fire()}}else this.bracketPairsTree.value&&(this.bracketPairsTree.clear(),this.onDidChangeEmitter.fire())}getBracketPairsInRange(a){var n;return this.bracketsRequested=!0,this.updateBracketPairsTree(),((n=this.bracketPairsTree.value)===null||n===void 0?void 0:n.object.getBracketPairsInRange(a,!1))||[]}getBracketPairsInRangeWithMinIndentation(a){var n;return this.bracketsRequested=!0,this.updateBracketPairsTree(),((n=this.bracketPairsTree.value)===null||n===void 0?void 0:n.object.getBracketPairsInRange(a,!0))||[]}getBracketsInRange(a){var n;return this.bracketsRequested=!0,this.updateBracketPairsTree(),((n=this.bracketPairsTree.value)===null||n===void 0?void 0:n.object.getBracketsInRange(a))||[]}findMatchingBracketUp(a,n,c){const I=this.textModel.validatePosition(n),F=this.textModel.getLanguageIdAtPosition(I.lineNumber,I.column);if(this.canBuildAST){const J=this.languageConfigurationService.getLanguageConfiguration(F).bracketsNew.getClosingBracketInfo(a);if(!J)return null;const ae=(0,b.Uk)(this.getBracketPairsInRange(d.Q.fromPositions(n,n))||[],de=>J.closes(de.openingBracketInfo));return ae?ae.openingBracketRange:null}else{const J=a.toLowerCase(),ae=this.languageConfigurationService.getLanguageConfiguration(F).brackets;if(!ae)return null;const de=ae.textIsBracket[J];return de?ue(this._findMatchingBracketUp(de,I,te(c))):null}}matchBracket(a,n){if(this.canBuildAST){const c=(0,b.Jw)(this.getBracketPairsInRange(d.Q.fromPositions(a,a)).filter(I=>I.closingBracketRange!==void 0&&(I.openingBracketRange.containsPosition(a)||I.closingBracketRange.containsPosition(a))),(0,b.VE)(I=>I.openingBracketRange.containsPosition(a)?I.openingBracketRange:I.closingBracketRange,d.Q.compareRangesUsingStarts));return c?[c.openingBracketRange,c.closingBracketRange]:null}else{const c=te(n);return this._matchBracket(this.textModel.validatePosition(a),c)}}_establishBracketSearchOffsets(a,n,c,I){const F=n.getCount(),J=n.getLanguageId(I);let ae=Math.max(0,a.column-1-c.maxBracketLength);for(let Ce=I-1;Ce>=0;Ce--){const Ee=n.getEndOffset(Ce);if(Ee<=ae)break;if((0,Z.Yo)(n.getStandardTokenType(Ce))||n.getLanguageId(Ce)!==J){ae=Ee;break}}let de=Math.min(n.getLineContent().length,a.column-1+c.maxBracketLength);for(let Ce=I+1;Ce<F;Ce++){const Ee=n.getStartOffset(Ce);if(Ee>=de)break;if((0,Z.Yo)(n.getStandardTokenType(Ce))||n.getLanguageId(Ce)!==J){de=Ee;break}}return{searchStartOffset:ae,searchEndOffset:de}}_matchBracket(a,n){const c=a.lineNumber,I=this.textModel.tokenization.getLineTokens(c),F=this.textModel.getLineContent(c),J=I.findTokenIndexAtOffset(a.column-1);if(J<0)return null;const ae=this.languageConfigurationService.getLanguageConfiguration(I.getLanguageId(J)).brackets;if(ae&&!(0,Z.Yo)(I.getStandardTokenType(J))){let{searchStartOffset:de,searchEndOffset:Ce}=this._establishBracketSearchOffsets(a,I,ae,J),Ee=null;for(;;){const Ne=N.Fu.findNextBracketInRange(ae.forwardRegex,c,F,de,Ce);if(!Ne)break;if(Ne.startColumn<=a.column&&a.column<=Ne.endColumn){const He=F.substring(Ne.startColumn-1,Ne.endColumn-1).toLowerCase(),Ze=this._matchFoundBracket(Ne,ae.textIsBracket[He],ae.textIsOpenBracket[He],n);if(Ze){if(Ze instanceof oe)return null;Ee=Ze}}de=Ne.endColumn-1}if(Ee)return Ee}if(J>0&&I.getStartOffset(J)===a.column-1){const de=J-1,Ce=this.languageConfigurationService.getLanguageConfiguration(I.getLanguageId(de)).brackets;if(Ce&&!(0,Z.Yo)(I.getStandardTokenType(de))){const{searchStartOffset:Ee,searchEndOffset:Ne}=this._establishBracketSearchOffsets(a,I,Ce,de),He=N.Fu.findPrevBracketInRange(Ce.reversedRegex,c,F,Ee,Ne);if(He&&He.startColumn<=a.column&&a.column<=He.endColumn){const Ze=F.substring(He.startColumn-1,He.endColumn-1).toLowerCase(),et=this._matchFoundBracket(He,Ce.textIsBracket[Ze],Ce.textIsOpenBracket[Ze],n);if(et)return et instanceof oe?null:et}}}return null}_matchFoundBracket(a,n,c,I){if(!n)return null;const F=c?this._findMatchingBracketDown(n,a.getEndPosition(),I):this._findMatchingBracketUp(n,a.getStartPosition(),I);return F?F instanceof oe?F:[a,F]:null}_findMatchingBracketUp(a,n,c){const I=a.languageId,F=a.reversedRegex;let J=-1,ae=0;const de=(Ce,Ee,Ne,He)=>{for(;;){if(c&&++ae%100===0&&!c())return oe.INSTANCE;const Ze=N.Fu.findPrevBracketInRange(F,Ce,Ee,Ne,He);if(!Ze)break;const et=Ee.substring(Ze.startColumn-1,Ze.endColumn-1).toLowerCase();if(a.isOpen(et)?J++:a.isClose(et)&&J--,J===0)return Ze;He=Ze.startColumn-1}return null};for(let Ce=n.lineNumber;Ce>=1;Ce--){const Ee=this.textModel.tokenization.getLineTokens(Ce),Ne=Ee.getCount(),He=this.textModel.getLineContent(Ce);let Ze=Ne-1,et=He.length,ot=He.length;Ce===n.lineNumber&&(Ze=Ee.findTokenIndexAtOffset(n.column-1),et=n.column-1,ot=n.column-1);let lt=!0;for(;Ze>=0;Ze--){const _t=Ee.getLanguageId(Ze)===I&&!(0,Z.Yo)(Ee.getStandardTokenType(Ze));if(_t)lt?et=Ee.getStartOffset(Ze):(et=Ee.getStartOffset(Ze),ot=Ee.getEndOffset(Ze));else if(lt&&et!==ot){const Ft=de(Ce,He,et,ot);if(Ft)return Ft}lt=_t}if(lt&&et!==ot){const _t=de(Ce,He,et,ot);if(_t)return _t}}return null}_findMatchingBracketDown(a,n,c){const I=a.languageId,F=a.forwardRegex;let J=1,ae=0;const de=(Ee,Ne,He,Ze)=>{for(;;){if(c&&++ae%100===0&&!c())return oe.INSTANCE;const et=N.Fu.findNextBracketInRange(F,Ee,Ne,He,Ze);if(!et)break;const ot=Ne.substring(et.startColumn-1,et.endColumn-1).toLowerCase();if(a.isOpen(ot)?J++:a.isClose(ot)&&J--,J===0)return et;He=et.endColumn-1}return null},Ce=this.textModel.getLineCount();for(let Ee=n.lineNumber;Ee<=Ce;Ee++){const Ne=this.textModel.tokenization.getLineTokens(Ee),He=Ne.getCount(),Ze=this.textModel.getLineContent(Ee);let et=0,ot=0,lt=0;Ee===n.lineNumber&&(et=Ne.findTokenIndexAtOffset(n.column-1),ot=n.column-1,lt=n.column-1);let _t=!0;for(;et<He;et++){const Ft=Ne.getLanguageId(et)===I&&!(0,Z.Yo)(Ne.getStandardTokenType(et));if(Ft)_t||(ot=Ne.getStartOffset(et)),lt=Ne.getEndOffset(et);else if(_t&&ot!==lt){const ci=de(Ee,Ze,ot,lt);if(ci)return ci}_t=Ft}if(_t&&ot!==lt){const Ft=de(Ee,Ze,ot,lt);if(Ft)return Ft}}return null}findPrevBracket(a){var n;const c=this.textModel.validatePosition(a);if(this.canBuildAST)return this.bracketsRequested=!0,this.updateBracketPairsTree(),((n=this.bracketPairsTree.value)===null||n===void 0?void 0:n.object.getFirstBracketBefore(c))||null;let I=null,F=null,J=null;for(let ae=c.lineNumber;ae>=1;ae--){const de=this.textModel.tokenization.getLineTokens(ae),Ce=de.getCount(),Ee=this.textModel.getLineContent(ae);let Ne=Ce-1,He=Ee.length,Ze=Ee.length;if(ae===c.lineNumber){Ne=de.findTokenIndexAtOffset(c.column-1),He=c.column-1,Ze=c.column-1;const ot=de.getLanguageId(Ne);I!==ot&&(I=ot,F=this.languageConfigurationService.getLanguageConfiguration(I).brackets,J=this.languageConfigurationService.getLanguageConfiguration(I).bracketsNew)}let et=!0;for(;Ne>=0;Ne--){const ot=de.getLanguageId(Ne);if(I!==ot){if(F&&J&&et&&He!==Ze){const _t=N.Fu.findPrevBracketInRange(F.reversedRegex,ae,Ee,He,Ze);if(_t)return this._toFoundBracket(J,_t);et=!1}I=ot,F=this.languageConfigurationService.getLanguageConfiguration(I).brackets,J=this.languageConfigurationService.getLanguageConfiguration(I).bracketsNew}const lt=!!F&&!(0,Z.Yo)(de.getStandardTokenType(Ne));if(lt)et?He=de.getStartOffset(Ne):(He=de.getStartOffset(Ne),Ze=de.getEndOffset(Ne));else if(J&&F&&et&&He!==Ze){const _t=N.Fu.findPrevBracketInRange(F.reversedRegex,ae,Ee,He,Ze);if(_t)return this._toFoundBracket(J,_t)}et=lt}if(J&&F&&et&&He!==Ze){const ot=N.Fu.findPrevBracketInRange(F.reversedRegex,ae,Ee,He,Ze);if(ot)return this._toFoundBracket(J,ot)}}return null}findNextBracket(a){var n;const c=this.textModel.validatePosition(a);if(this.canBuildAST)return this.bracketsRequested=!0,this.updateBracketPairsTree(),((n=this.bracketPairsTree.value)===null||n===void 0?void 0:n.object.getFirstBracketAfter(c))||null;const I=this.textModel.getLineCount();let F=null,J=null,ae=null;for(let de=c.lineNumber;de<=I;de++){const Ce=this.textModel.tokenization.getLineTokens(de),Ee=Ce.getCount(),Ne=this.textModel.getLineContent(de);let He=0,Ze=0,et=0;if(de===c.lineNumber){He=Ce.findTokenIndexAtOffset(c.column-1),Ze=c.column-1,et=c.column-1;const lt=Ce.getLanguageId(He);F!==lt&&(F=lt,J=this.languageConfigurationService.getLanguageConfiguration(F).brackets,ae=this.languageConfigurationService.getLanguageConfiguration(F).bracketsNew)}let ot=!0;for(;He<Ee;He++){const lt=Ce.getLanguageId(He);if(F!==lt){if(ae&&J&&ot&&Ze!==et){const Ft=N.Fu.findNextBracketInRange(J.forwardRegex,de,Ne,Ze,et);if(Ft)return this._toFoundBracket(ae,Ft);ot=!1}F=lt,J=this.languageConfigurationService.getLanguageConfiguration(F).brackets,ae=this.languageConfigurationService.getLanguageConfiguration(F).bracketsNew}const _t=!!J&&!(0,Z.Yo)(Ce.getStandardTokenType(He));if(_t)ot||(Ze=Ce.getStartOffset(He)),et=Ce.getEndOffset(He);else if(ae&&J&&ot&&Ze!==et){const Ft=N.Fu.findNextBracketInRange(J.forwardRegex,de,Ne,Ze,et);if(Ft)return this._toFoundBracket(ae,Ft)}ot=_t}if(ae&&J&&ot&&Ze!==et){const lt=N.Fu.findNextBracketInRange(J.forwardRegex,de,Ne,Ze,et);if(lt)return this._toFoundBracket(ae,lt)}}return null}findEnclosingBrackets(a,n){const c=this.textModel.validatePosition(a);if(this.canBuildAST){const Ze=d.Q.fromPositions(c),et=(0,b.Uk)(this.getBracketPairsInRange(d.Q.fromPositions(c,c)),ot=>ot.closingBracketRange!==void 0&&ot.range.strictContainsRange(Ze));return et?[et.openingBracketRange,et.closingBracketRange]:null}const I=te(n),F=this.textModel.getLineCount(),J=new Map;let ae=[];const de=(Ze,et)=>{if(!J.has(Ze)){const ot=[];for(let lt=0,_t=et?et.brackets.length:0;lt<_t;lt++)ot[lt]=0;J.set(Ze,ot)}ae=J.get(Ze)};let Ce=0;const Ee=(Ze,et,ot,lt,_t)=>{for(;;){if(I&&++Ce%100===0&&!I())return oe.INSTANCE;const Ft=N.Fu.findNextBracketInRange(Ze.forwardRegex,et,ot,lt,_t);if(!Ft)break;const ci=ot.substring(Ft.startColumn-1,Ft.endColumn-1).toLowerCase(),Oi=Ze.textIsBracket[ci];if(Oi&&(Oi.isOpen(ci)?ae[Oi.index]++:Oi.isClose(ci)&&ae[Oi.index]--,ae[Oi.index]===-1))return this._matchFoundBracket(Ft,Oi,!1,I);lt=Ft.endColumn-1}return null};let Ne=null,He=null;for(let Ze=c.lineNumber;Ze<=F;Ze++){const et=this.textModel.tokenization.getLineTokens(Ze),ot=et.getCount(),lt=this.textModel.getLineContent(Ze);let _t=0,Ft=0,ci=0;if(Ze===c.lineNumber){_t=et.findTokenIndexAtOffset(c.column-1),Ft=c.column-1,ci=c.column-1;const on=et.getLanguageId(_t);Ne!==on&&(Ne=on,He=this.languageConfigurationService.getLanguageConfiguration(Ne).brackets,de(Ne,He))}let Oi=!0;for(;_t<ot;_t++){const on=et.getLanguageId(_t);if(Ne!==on){if(He&&Oi&&Ft!==ci){const hn=Ee(He,Ze,lt,Ft,ci);if(hn)return ue(hn);Oi=!1}Ne=on,He=this.languageConfigurationService.getLanguageConfiguration(Ne).brackets,de(Ne,He)}const gn=!!He&&!(0,Z.Yo)(et.getStandardTokenType(_t));if(gn)Oi||(Ft=et.getStartOffset(_t)),ci=et.getEndOffset(_t);else if(He&&Oi&&Ft!==ci){const hn=Ee(He,Ze,lt,Ft,ci);if(hn)return ue(hn)}Oi=gn}if(He&&Oi&&Ft!==ci){const on=Ee(He,Ze,lt,Ft,ci);if(on)return ue(on)}}return null}_toFoundBracket(a,n){if(!n)return null;let c=this.textModel.getValueInRange(n);c=c.toLowerCase();const I=a.getBracketInfo(c);return I?{range:n,bracketInfo:I}:null}}function O(xe,a){return{object:xe,dispose:()=>a?.dispose()}}function te(xe){if(typeof xe>"u")return()=>!0;{const a=Date.now();return()=>Date.now()-a<=xe}}class oe{constructor(){this._searchCanceledBrand=void 0}}oe.INSTANCE=new oe;function ue(xe){return xe instanceof oe?null:xe}var E=y(48295),Qe=y(89044);class Ke extends L.jG{constructor(a){super(),this.textModel=a,this.colorProvider=new Se,this.onDidChangeEmitter=new $.vl,this.onDidChange=this.onDidChangeEmitter.event,this.colorizationOptions=a.getOptions().bracketPairColorizationOptions,this._register(a.bracketPairs.onDidChange(n=>{this.onDidChangeEmitter.fire()}))}handleDidChangeOptions(a){this.colorizationOptions=this.textModel.getOptions().bracketPairColorizationOptions}getDecorationsInRange(a,n,c){if(n===void 0)return[];if(!this.colorizationOptions.enabled)return[];const I=new Array,F=this.textModel.bracketPairs.getBracketsInRange(a);for(const J of F)I.push({id:`bracket${J.range.toString()}-${J.nestingLevel}`,options:{description:"BracketPairColorization",inlineClassName:this.colorProvider.getInlineClassName(J,this.colorizationOptions.independentColorPoolPerBracketType)},ownerId:0,range:J.range});return I}getAllDecorations(a,n){return a===void 0?[]:this.colorizationOptions.enabled?this.getDecorationsInRange(new d.Q(1,1,this.textModel.getLineCount(),1),a,n):[]}}class Se{constructor(){this.unexpectedClosingBracketClassName="unexpected-closing-bracket"}getInlineClassName(a,n){return a.isInvalid?this.unexpectedClosingBracketClassName:this.getInlineClassNameOfLevel(n?a.nestingLevelOfEqualBracketType:a.nestingLevel)}getInlineClassNameOfLevel(a){return`bracket-highlighting-${a%30}`}}(0,Qe.zy)((xe,a)=>{const n=[E.sN,E.lQ,E.ss,E.l5,E.sH,E.zp],c=new Se;a.addRule(`.monaco-editor .${c.unexpectedClosingBracketClassName} { color: ${xe.getColor(E.s7)}; }`);const I=n.map(F=>xe.getColor(F)).filter(F=>!!F).filter(F=>!F.isTransparent());for(let F=0;F<30;F++){const J=I[F%I.length];a.addRule(`.monaco-editor .${c.getInlineClassNameOfLevel(F)} { color: ${J}; }`)}});var Me=y(54296),ce=y(52818);class pe{constructor(){this.spacesDiff=0,this.looksLikeAlignment=!1}}function be(xe,a,n,c,I){I.spacesDiff=0,I.looksLikeAlignment=!1;let F;for(F=0;F<a&&F<c;F++){const He=xe.charCodeAt(F),Ze=n.charCodeAt(F);if(He!==Ze)break}let J=0,ae=0;for(let He=F;He<a;He++)xe.charCodeAt(He)===32?J++:ae++;let de=0,Ce=0;for(let He=F;He<c;He++)n.charCodeAt(He)===32?de++:Ce++;if(J>0&&ae>0||de>0&&Ce>0)return;const Ee=Math.abs(ae-Ce),Ne=Math.abs(J-de);if(Ee===0){I.spacesDiff=Ne,Ne>0&&0<=de-1&&de-1<xe.length&&de<n.length&&n.charCodeAt(de)!==32&&xe.charCodeAt(de-1)===32&&xe.charCodeAt(xe.length-1)===44&&(I.looksLikeAlignment=!0);return}if(Ne%Ee===0){I.spacesDiff=Ne/Ee;return}}function ge(xe,a,n){const c=Math.min(xe.getLineCount(),1e4);let I=0,F=0,J="",ae=0;const de=[2,4,6,8,3,5,7],Ce=8,Ee=[0,0,0,0,0,0,0,0,0],Ne=new pe;for(let et=1;et<=c;et++){const ot=xe.getLineLength(et),lt=xe.getLineContent(et),_t=ot<=65536;let Ft=!1,ci=0,Oi=0,on=0;for(let hn=0,Yi=ot;hn<Yi;hn++){const Ei=_t?lt.charCodeAt(hn):xe.getLineCharCode(et,hn);if(Ei===9)on++;else if(Ei===32)Oi++;else{Ft=!0,ci=hn;break}}if(!Ft||(on>0?I++:Oi>1&&F++,be(J,ae,lt,ci,Ne),Ne.looksLikeAlignment&&!(n&&a===Ne.spacesDiff)))continue;const gn=Ne.spacesDiff;gn<=Ce&&Ee[gn]++,J=lt,ae=ci}let He=n;I!==F&&(He=I<F);let Ze=a;if(He){let et=He?0:.1*c;de.forEach(ot=>{const lt=Ee[ot];lt>et&&(et=lt,Ze=ot)}),Ze===4&&Ee[4]>0&&Ee[2]>0&&Ee[2]>=Ee[4]/2&&(Ze=2)}return{insertSpaces:He,tabSize:Ze}}function ke(xe){return(xe.metadata&1)>>>0}function We(xe,a){xe.metadata=xe.metadata&254|a<<0}function Ge(xe){return(xe.metadata&2)>>>1===1}function Ae(xe,a){xe.metadata=xe.metadata&253|(a?1:0)<<1}function he(xe){return(xe.metadata&4)>>>2===1}function Pe(xe,a){xe.metadata=xe.metadata&251|(a?1:0)<<2}function $e(xe){return(xe.metadata&24)>>>3}function it(xe,a){xe.metadata=xe.metadata&231|a<<3}function ft(xe){return(xe.metadata&32)>>>5===1}function Wt(xe,a){xe.metadata=xe.metadata&223|(a?1:0)<<5}class tt{constructor(a,n,c){this.metadata=0,this.parent=this,this.left=this,this.right=this,We(this,1),this.start=n,this.end=c,this.delta=0,this.maxEnd=c,this.id=a,this.ownerId=0,this.options=null,Pe(this,!1),it(this,1),Wt(this,!1),this.cachedVersionId=0,this.cachedAbsoluteStart=n,this.cachedAbsoluteEnd=c,this.range=null,Ae(this,!1)}reset(a,n,c,I){this.start=n,this.end=c,this.maxEnd=c,this.cachedVersionId=a,this.cachedAbsoluteStart=n,this.cachedAbsoluteEnd=c,this.range=I}setOptions(a){this.options=a;const n=this.options.className;Pe(this,n==="squiggly-error"||n==="squiggly-warning"||n==="squiggly-info"),it(this,this.options.stickiness),Wt(this,this.options.collapseOnReplaceEdit)}setCachedOffsets(a,n,c){this.cachedVersionId!==c&&(this.range=null),this.cachedVersionId=c,this.cachedAbsoluteStart=a,this.cachedAbsoluteEnd=n}detach(){this.parent=null,this.left=null,this.right=null}}const Ye=new tt(null,0,0);Ye.parent=Ye,Ye.left=Ye,Ye.right=Ye,We(Ye,0);class ht{constructor(){this.root=Ye,this.requestNormalizeDelta=!1}intervalSearch(a,n,c,I,F){return this.root===Ye?[]:Nt(this,a,n,c,I,F)}search(a,n,c){return this.root===Ye?[]:Yt(this,a,n,c)}collectNodesFromOwner(a){return bt(this,a)}collectNodesPostOrder(){return Mt(this)}insert(a){Pt(this,a),this._normalizeDeltaIfNecessary()}delete(a){Ii(this,a),this._normalizeDeltaIfNecessary()}resolveNode(a,n){const c=a;let I=0;for(;a!==this.root;)a===a.parent.right&&(I+=a.parent.delta),a=a.parent;const F=c.start+I,J=c.end+I;c.setCachedOffsets(F,J,n)}acceptReplace(a,n,c,I){const F=Ve(this,a,a+n);for(let J=0,ae=F.length;J<ae;J++){const de=F[J];Ii(this,de)}this._normalizeDeltaIfNecessary(),dt(this,a,a+n,c),this._normalizeDeltaIfNecessary();for(let J=0,ae=F.length;J<ae;J++){const de=F[J];de.start=de.cachedAbsoluteStart,de.end=de.cachedAbsoluteEnd,Ie(de,a,a+n,c,I),de.maxEnd=de.end,Pt(this,de)}this._normalizeDeltaIfNecessary()}_normalizeDeltaIfNecessary(){this.requestNormalizeDelta&&(this.requestNormalizeDelta=!1,Lt(this))}}function Lt(xe){let a=xe.root,n=0;for(;a!==Ye;){if(a.left!==Ye&&!Ge(a.left)){a=a.left;continue}if(a.right!==Ye&&!Ge(a.right)){n+=a.delta,a=a.right;continue}a.start=n+a.start,a.end=n+a.end,a.delta=0,Et(a),Ae(a,!0),Ae(a.left,!1),Ae(a.right,!1),a===a.parent.right&&(n-=a.parent.delta),a=a.parent}Ae(xe.root,!1)}function Rt(xe,a,n,c){return xe<n?!0:xe>n||c===1?!1:c===2?!0:a}function Ie(xe,a,n,c,I){const F=$e(xe),J=F===0||F===2,ae=F===1||F===2,de=n-a,Ce=c,Ee=Math.min(de,Ce),Ne=xe.start;let He=!1;const Ze=xe.end;let et=!1;a<=Ne&&Ze<=n&&ft(xe)&&(xe.start=a,He=!0,xe.end=a,et=!0);{const lt=I?1:de>0?2:0;!He&&Rt(Ne,J,a,lt)&&(He=!0),!et&&Rt(Ze,ae,a,lt)&&(et=!0)}if(Ee>0&&!I){const lt=de>Ce?2:0;!He&&Rt(Ne,J,a+Ee,lt)&&(He=!0),!et&&Rt(Ze,ae,a+Ee,lt)&&(et=!0)}{const lt=I?1:0;!He&&Rt(Ne,J,n,lt)&&(xe.start=a+Ce,He=!0),!et&&Rt(Ze,ae,n,lt)&&(xe.end=a+Ce,et=!0)}const ot=Ce-de;He||(xe.start=Math.max(0,Ne+ot)),et||(xe.end=Math.max(0,Ze+ot)),xe.start>xe.end&&(xe.end=xe.start)}function Ve(xe,a,n){let c=xe.root,I=0,F=0,J=0,ae=0;const de=[];let Ce=0;for(;c!==Ye;){if(Ge(c)){Ae(c.left,!1),Ae(c.right,!1),c===c.parent.right&&(I-=c.parent.delta),c=c.parent;continue}if(!Ge(c.left)){if(F=I+c.maxEnd,F<a){Ae(c,!0);continue}if(c.left!==Ye){c=c.left;continue}}if(J=I+c.start,J>n){Ae(c,!0);continue}if(ae=I+c.end,ae>=a&&(c.setCachedOffsets(J,ae,0),de[Ce++]=c),Ae(c,!0),c.right!==Ye&&!Ge(c.right)){I+=c.delta,c=c.right;continue}}return Ae(xe.root,!1),de}function dt(xe,a,n,c){let I=xe.root,F=0,J=0,ae=0;const de=c-(n-a);for(;I!==Ye;){if(Ge(I)){Ae(I.left,!1),Ae(I.right,!1),I===I.parent.right&&(F-=I.parent.delta),Et(I),I=I.parent;continue}if(!Ge(I.left)){if(J=F+I.maxEnd,J<a){Ae(I,!0);continue}if(I.left!==Ye){I=I.left;continue}}if(ae=F+I.start,ae>n){I.start+=de,I.end+=de,I.delta+=de,(I.delta<-1073741824||I.delta>1073741824)&&(xe.requestNormalizeDelta=!0),Ae(I,!0);continue}if(Ae(I,!0),I.right!==Ye&&!Ge(I.right)){F+=I.delta,I=I.right;continue}}Ae(xe.root,!1)}function bt(xe,a){let n=xe.root;const c=[];let I=0;for(;n!==Ye;){if(Ge(n)){Ae(n.left,!1),Ae(n.right,!1),n=n.parent;continue}if(n.left!==Ye&&!Ge(n.left)){n=n.left;continue}if(n.ownerId===a&&(c[I++]=n),Ae(n,!0),n.right!==Ye&&!Ge(n.right)){n=n.right;continue}}return Ae(xe.root,!1),c}function Mt(xe){let a=xe.root;const n=[];let c=0;for(;a!==Ye;){if(Ge(a)){Ae(a.left,!1),Ae(a.right,!1),a=a.parent;continue}if(a.left!==Ye&&!Ge(a.left)){a=a.left;continue}if(a.right!==Ye&&!Ge(a.right)){a=a.right;continue}n[c++]=a,Ae(a,!0)}return Ae(xe.root,!1),n}function Yt(xe,a,n,c){let I=xe.root,F=0,J=0,ae=0;const de=[];let Ce=0;for(;I!==Ye;){if(Ge(I)){Ae(I.left,!1),Ae(I.right,!1),I===I.parent.right&&(F-=I.parent.delta),I=I.parent;continue}if(I.left!==Ye&&!Ge(I.left)){I=I.left;continue}J=F+I.start,ae=F+I.end,I.setCachedOffsets(J,ae,c);let Ee=!0;if(a&&I.ownerId&&I.ownerId!==a&&(Ee=!1),n&&he(I)&&(Ee=!1),Ee&&(de[Ce++]=I),Ae(I,!0),I.right!==Ye&&!Ge(I.right)){F+=I.delta,I=I.right;continue}}return Ae(xe.root,!1),de}function Nt(xe,a,n,c,I,F){let J=xe.root,ae=0,de=0,Ce=0,Ee=0;const Ne=[];let He=0;for(;J!==Ye;){if(Ge(J)){Ae(J.left,!1),Ae(J.right,!1),J===J.parent.right&&(ae-=J.parent.delta),J=J.parent;continue}if(!Ge(J.left)){if(de=ae+J.maxEnd,de<a){Ae(J,!0);continue}if(J.left!==Ye){J=J.left;continue}}if(Ce=ae+J.start,Ce>n){Ae(J,!0);continue}if(Ee=ae+J.end,Ee>=a){J.setCachedOffsets(Ce,Ee,F);let Ze=!0;c&&J.ownerId&&J.ownerId!==c&&(Ze=!1),I&&he(J)&&(Ze=!1),Ze&&(Ne[He++]=J)}if(Ae(J,!0),J.right!==Ye&&!Ge(J.right)){ae+=J.delta,J=J.right;continue}}return Ae(xe.root,!1),Ne}function Pt(xe,a){if(xe.root===Ye)return a.parent=Ye,a.left=Ye,a.right=Ye,We(a,0),xe.root=a,xe.root;Ti(xe,a),Ot(a.parent);let n=a;for(;n!==xe.root&&ke(n.parent)===1;)if(n.parent===n.parent.parent.left){const c=n.parent.parent.right;ke(c)===1?(We(n.parent,0),We(c,0),We(n.parent.parent,1),n=n.parent.parent):(n===n.parent.right&&(n=n.parent,yt(xe,n)),We(n.parent,0),We(n.parent.parent,1),fe(xe,n.parent.parent))}else{const c=n.parent.parent.left;ke(c)===1?(We(n.parent,0),We(c,0),We(n.parent.parent,1),n=n.parent.parent):(n===n.parent.left&&(n=n.parent,fe(xe,n)),We(n.parent,0),We(n.parent.parent,1),yt(xe,n.parent.parent))}return We(xe.root,0),a}function Ti(xe,a){let n=0,c=xe.root;const I=a.start,F=a.end;for(;;)if(si(I,F,c.start+n,c.end+n)<0)if(c.left===Ye){a.start-=n,a.end-=n,a.maxEnd-=n,c.left=a;break}else c=c.left;else if(c.right===Ye){a.start-=n+c.delta,a.end-=n+c.delta,a.maxEnd-=n+c.delta,c.right=a;break}else n+=c.delta,c=c.right;a.parent=c,a.left=Ye,a.right=Ye,We(a,1)}function Ii(xe,a){let n,c;if(a.left===Ye?(n=a.right,c=a,n.delta+=a.delta,(n.delta<-1073741824||n.delta>1073741824)&&(xe.requestNormalizeDelta=!0),n.start+=a.delta,n.end+=a.delta):a.right===Ye?(n=a.left,c=a):(c=ut(a.right),n=c.right,n.start+=c.delta,n.end+=c.delta,n.delta+=c.delta,(n.delta<-1073741824||n.delta>1073741824)&&(xe.requestNormalizeDelta=!0),c.start+=a.delta,c.end+=a.delta,c.delta=a.delta,(c.delta<-1073741824||c.delta>1073741824)&&(xe.requestNormalizeDelta=!0)),c===xe.root){xe.root=n,We(n,0),a.detach(),Si(),Et(n),xe.root.parent=Ye;return}const I=ke(c)===1;if(c===c.parent.left?c.parent.left=n:c.parent.right=n,c===a?n.parent=c.parent:(c.parent===a?n.parent=c:n.parent=c.parent,c.left=a.left,c.right=a.right,c.parent=a.parent,We(c,ke(a)),a===xe.root?xe.root=c:a===a.parent.left?a.parent.left=c:a.parent.right=c,c.left!==Ye&&(c.left.parent=c),c.right!==Ye&&(c.right.parent=c)),a.detach(),I){Ot(n.parent),c!==a&&(Ot(c),Ot(c.parent)),Si();return}Ot(n),Ot(n.parent),c!==a&&(Ot(c),Ot(c.parent));let F;for(;n!==xe.root&&ke(n)===0;)n===n.parent.left?(F=n.parent.right,ke(F)===1&&(We(F,0),We(n.parent,1),yt(xe,n.parent),F=n.parent.right),ke(F.left)===0&&ke(F.right)===0?(We(F,1),n=n.parent):(ke(F.right)===0&&(We(F.left,0),We(F,1),fe(xe,F),F=n.parent.right),We(F,ke(n.parent)),We(n.parent,0),We(F.right,0),yt(xe,n.parent),n=xe.root)):(F=n.parent.left,ke(F)===1&&(We(F,0),We(n.parent,1),fe(xe,n.parent),F=n.parent.left),ke(F.left)===0&&ke(F.right)===0?(We(F,1),n=n.parent):(ke(F.left)===0&&(We(F.right,0),We(F,1),yt(xe,F),F=n.parent.left),We(F,ke(n.parent)),We(n.parent,0),We(F.left,0),fe(xe,n.parent),n=xe.root));We(n,0),Si()}function ut(xe){for(;xe.left!==Ye;)xe=xe.left;return xe}function Si(){Ye.parent=Ye,Ye.delta=0,Ye.start=0,Ye.end=0}function yt(xe,a){const n=a.right;n.delta+=a.delta,(n.delta<-1073741824||n.delta>1073741824)&&(xe.requestNormalizeDelta=!0),n.start+=a.delta,n.end+=a.delta,a.right=n.left,n.left!==Ye&&(n.left.parent=a),n.parent=a.parent,a.parent===Ye?xe.root=n:a===a.parent.left?a.parent.left=n:a.parent.right=n,n.left=a,a.parent=n,Et(a),Et(n)}function fe(xe,a){const n=a.left;a.delta-=n.delta,(a.delta<-1073741824||a.delta>1073741824)&&(xe.requestNormalizeDelta=!0),a.start-=n.delta,a.end-=n.delta,a.left=n.right,n.right!==Ye&&(n.right.parent=a),n.parent=a.parent,a.parent===Ye?xe.root=n:a===a.parent.right?a.parent.right=n:a.parent.left=n,n.right=a,a.parent=n,Et(a),Et(n)}function ze(xe){let a=xe.end;if(xe.left!==Ye){const n=xe.left.maxEnd;n>a&&(a=n)}if(xe.right!==Ye){const n=xe.right.maxEnd+xe.delta;n>a&&(a=n)}return a}function Et(xe){xe.maxEnd=ze(xe)}function Ot(xe){for(;xe!==Ye;){const a=ze(xe);if(xe.maxEnd===a)return;xe.maxEnd=a,xe=xe.parent}}function si(xe,a,n,c){return xe===n?a-c:xe-n}class _i{constructor(a,n){this.piece=a,this.color=n,this.size_left=0,this.lf_left=0,this.parent=this,this.left=this,this.right=this}next(){if(this.right!==Fe)return Xe(this.right);let a=this;for(;a.parent!==Fe&&a.parent.left!==a;)a=a.parent;return a.parent===Fe?Fe:a.parent}prev(){if(this.left!==Fe)return gt(this.left);let a=this;for(;a.parent!==Fe&&a.parent.right!==a;)a=a.parent;return a.parent===Fe?Fe:a.parent}detach(){this.parent=null,this.left=null,this.right=null}}const Fe=new _i(null,0);Fe.parent=Fe,Fe.left=Fe,Fe.right=Fe,Fe.color=0;function Xe(xe){for(;xe.left!==Fe;)xe=xe.left;return xe}function gt(xe){for(;xe.right!==Fe;)xe=xe.right;return xe}function Xt(xe){return xe===Fe?0:xe.size_left+xe.piece.length+Xt(xe.right)}function Vt(xe){return xe===Fe?0:xe.lf_left+xe.piece.lineFeedCnt+Vt(xe.right)}function ni(){Fe.parent=Fe}function vi(xe,a){const n=a.right;n.size_left+=a.size_left+(a.piece?a.piece.length:0),n.lf_left+=a.lf_left+(a.piece?a.piece.lineFeedCnt:0),a.right=n.left,n.left!==Fe&&(n.left.parent=a),n.parent=a.parent,a.parent===Fe?xe.root=n:a.parent.left===a?a.parent.left=n:a.parent.right=n,n.left=a,a.parent=n}function Ri(xe,a){const n=a.left;a.left=n.right,n.right!==Fe&&(n.right.parent=a),n.parent=a.parent,a.size_left-=n.size_left+(n.piece?n.piece.length:0),a.lf_left-=n.lf_left+(n.piece?n.piece.lineFeedCnt:0),a.parent===Fe?xe.root=n:a===a.parent.right?a.parent.right=n:a.parent.left=n,n.right=a,a.parent=n}function St(xe,a){let n,c;if(a.left===Fe?(c=a,n=c.right):a.right===Fe?(c=a,n=c.left):(c=Xe(a.right),n=c.right),c===xe.root){xe.root=n,n.color=0,a.detach(),ni(),xe.root.parent=Fe;return}const I=c.color===1;if(c===c.parent.left?c.parent.left=n:c.parent.right=n,c===a?(n.parent=c.parent,je(xe,n)):(c.parent===a?n.parent=c:n.parent=c.parent,je(xe,n),c.left=a.left,c.right=a.right,c.parent=a.parent,c.color=a.color,a===xe.root?xe.root=c:a===a.parent.left?a.parent.left=c:a.parent.right=c,c.left!==Fe&&(c.left.parent=c),c.right!==Fe&&(c.right.parent=c),c.size_left=a.size_left,c.lf_left=a.lf_left,je(xe,c)),a.detach(),n.parent.left===n){const J=Xt(n),ae=Vt(n);if(J!==n.parent.size_left||ae!==n.parent.lf_left){const de=J-n.parent.size_left,Ce=ae-n.parent.lf_left;n.parent.size_left=J,n.parent.lf_left=ae,Te(xe,n.parent,de,Ce)}}if(je(xe,n.parent),I){ni();return}let F;for(;n!==xe.root&&n.color===0;)n===n.parent.left?(F=n.parent.right,F.color===1&&(F.color=0,n.parent.color=1,vi(xe,n.parent),F=n.parent.right),F.left.color===0&&F.right.color===0?(F.color=1,n=n.parent):(F.right.color===0&&(F.left.color=0,F.color=1,Ri(xe,F),F=n.parent.right),F.color=n.parent.color,n.parent.color=0,F.right.color=0,vi(xe,n.parent),n=xe.root)):(F=n.parent.left,F.color===1&&(F.color=0,n.parent.color=1,Ri(xe,n.parent),F=n.parent.left),F.left.color===0&&F.right.color===0?(F.color=1,n=n.parent):(F.left.color===0&&(F.right.color=0,F.color=1,vi(xe,F),F=n.parent.left),F.color=n.parent.color,n.parent.color=0,F.left.color=0,Ri(xe,n.parent),n=xe.root));n.color=0,ni()}function ve(xe,a){for(je(xe,a);a!==xe.root&&a.parent.color===1;)if(a.parent===a.parent.parent.left){const n=a.parent.parent.right;n.color===1?(a.parent.color=0,n.color=0,a.parent.parent.color=1,a=a.parent.parent):(a===a.parent.right&&(a=a.parent,vi(xe,a)),a.parent.color=0,a.parent.parent.color=1,Ri(xe,a.parent.parent))}else{const n=a.parent.parent.left;n.color===1?(a.parent.color=0,n.color=0,a.parent.parent.color=1,a=a.parent.parent):(a===a.parent.left&&(a=a.parent,Ri(xe,a)),a.parent.color=0,a.parent.parent.color=1,vi(xe,a.parent.parent))}xe.root.color=0}function Te(xe,a,n,c){for(;a!==xe.root&&a!==Fe;)a.parent.left===a&&(a.parent.size_left+=n,a.parent.lf_left+=c),a=a.parent}function je(xe,a){let n=0,c=0;if(a!==xe.root){for(;a!==xe.root&&a===a.parent.right;)a=a.parent;if(a!==xe.root)for(a=a.parent,n=Xt(a.left)-a.size_left,c=Vt(a.left)-a.lf_left,a.size_left+=n,a.lf_left+=c;a!==xe.root&&(n!==0||c!==0);)a.parent.left===a&&(a.parent.size_left+=n,a.parent.lf_left+=c),a=a.parent}}var nt=y(104);const at=65535;function vt(xe){let a;return xe[xe.length-1]<65536?a=new Uint16Array(xe.length):a=new Uint32Array(xe.length),a.set(xe,0),a}class It{constructor(a,n,c,I,F){this.lineStarts=a,this.cr=n,this.lf=c,this.crlf=I,this.isBasicASCII=F}}function At(xe,a=!0){const n=[0];let c=1;for(let I=0,F=xe.length;I<F;I++){const J=xe.charCodeAt(I);J===13?I+1<F&&xe.charCodeAt(I+1)===10?(n[c++]=I+2,I++):n[c++]=I+1:J===10&&(n[c++]=I+1)}return a?vt(n):n}function wt(xe,a){xe.length=0,xe[0]=0;let n=1,c=0,I=0,F=0,J=!0;for(let de=0,Ce=a.length;de<Ce;de++){const Ee=a.charCodeAt(de);Ee===13?de+1<Ce&&a.charCodeAt(de+1)===10?(F++,xe[n++]=de+2,de++):(c++,xe[n++]=de+1):Ee===10?(I++,xe[n++]=de+1):J&&Ee!==9&&(Ee<32||Ee>126)&&(J=!1)}const ae=new It(vt(xe),c,I,F,J);return xe.length=0,ae}class kt{constructor(a,n,c,I,F){this.bufferIndex=a,this.start=n,this.end=c,this.lineFeedCnt=I,this.length=F}}class Ct{constructor(a,n){this.buffer=a,this.lineStarts=n}}class Gt{constructor(a,n){this._pieces=[],this._tree=a,this._BOM=n,this._index=0,a.root!==Fe&&a.iterate(a.root,c=>(c!==Fe&&this._pieces.push(c.piece),!0))}read(){return this._pieces.length===0?this._index===0?(this._index++,this._BOM):null:this._index>this._pieces.length-1?null:this._index===0?this._BOM+this._tree.getPieceContent(this._pieces[this._index++]):this._tree.getPieceContent(this._pieces[this._index++])}}class Ht{constructor(a){this._limit=a,this._cache=[]}get(a){for(let n=this._cache.length-1;n>=0;n--){const c=this._cache[n];if(c.nodeStartOffset<=a&&c.nodeStartOffset+c.node.piece.length>=a)return c}return null}get2(a){for(let n=this._cache.length-1;n>=0;n--){const c=this._cache[n];if(c.nodeStartLineNumber&&c.nodeStartLineNumber<a&&c.nodeStartLineNumber+c.node.piece.lineFeedCnt>=a)return c}return null}set(a){this._cache.length>=this._limit&&this._cache.shift(),this._cache.push(a)}validate(a){let n=!1;const c=this._cache;for(let I=0;I<c.length;I++){const F=c[I];if(F.node.parent===null||F.nodeStartOffset>=a){c[I]=null,n=!0;continue}}if(n){const I=[];for(const F of c)F!==null&&I.push(F);this._cache=I}}}class Ut{constructor(a,n,c){this.create(a,n,c)}create(a,n,c){this._buffers=[new Ct("",[0])],this._lastChangeBufferPos={line:0,column:0},this.root=Fe,this._lineCnt=1,this._length=0,this._EOL=n,this._EOLLength=n.length,this._EOLNormalized=c;let I=null;for(let F=0,J=a.length;F<J;F++)if(a[F].buffer.length>0){a[F].lineStarts||(a[F].lineStarts=At(a[F].buffer));const ae=new kt(F+1,{line:0,column:0},{line:a[F].lineStarts.length-1,column:a[F].buffer.length-a[F].lineStarts[a[F].lineStarts.length-1]},a[F].lineStarts.length-1,a[F].buffer.length);this._buffers.push(a[F]),I=this.rbInsertRight(I,ae)}this._searchCache=new Ht(1),this._lastVisitedLine={lineNumber:0,value:""},this.computeBufferMetadata()}normalizeEOL(a){const n=at,c=n-Math.floor(n/3),I=c*2;let F="",J=0;const ae=[];if(this.iterate(this.root,de=>{const Ce=this.getNodeContent(de),Ee=Ce.length;if(J<=c||J+Ee<I)return F+=Ce,J+=Ee,!0;const Ne=F.replace(/\r\n|\r|\n/g,a);return ae.push(new Ct(Ne,At(Ne))),F=Ce,J=Ee,!0}),J>0){const de=F.replace(/\r\n|\r|\n/g,a);ae.push(new Ct(de,At(de)))}this.create(ae,a,!0)}getEOL(){return this._EOL}setEOL(a){this._EOL=a,this._EOLLength=this._EOL.length,this.normalizeEOL(a)}createSnapshot(a){return new Gt(this,a)}getOffsetAt(a,n){let c=0,I=this.root;for(;I!==Fe;)if(I.left!==Fe&&I.lf_left+1>=a)I=I.left;else if(I.lf_left+I.piece.lineFeedCnt+1>=a){c+=I.size_left;const F=this.getAccumulatedValue(I,a-I.lf_left-2);return c+=F+n-1}else a-=I.lf_left+I.piece.lineFeedCnt,c+=I.size_left+I.piece.length,I=I.right;return c}getPositionAt(a){a=Math.floor(a),a=Math.max(0,a);let n=this.root,c=0;const I=a;for(;n!==Fe;)if(n.size_left!==0&&n.size_left>=a)n=n.left;else if(n.size_left+n.piece.length>=a){const F=this.getIndexOf(n,a-n.size_left);if(c+=n.lf_left+F.index,F.index===0){const J=this.getOffsetAt(c+1,1),ae=I-J;return new p.y(c+1,ae+1)}return new p.y(c+1,F.remainder+1)}else if(a-=n.size_left+n.piece.length,c+=n.lf_left+n.piece.lineFeedCnt,n.right===Fe){const F=this.getOffsetAt(c+1,1),J=I-a-F;return new p.y(c+1,J+1)}else n=n.right;return new p.y(1,1)}getValueInRange(a,n){if(a.startLineNumber===a.endLineNumber&&a.startColumn===a.endColumn)return"";const c=this.nodeAt2(a.startLineNumber,a.startColumn),I=this.nodeAt2(a.endLineNumber,a.endColumn),F=this.getValueInRange2(c,I);return n?n!==this._EOL||!this._EOLNormalized?F.replace(/\r\n|\r|\n/g,n):n===this.getEOL()&&this._EOLNormalized?F:F.replace(/\r\n|\r|\n/g,n):F}getValueInRange2(a,n){if(a.node===n.node){const ae=a.node,de=this._buffers[ae.piece.bufferIndex].buffer,Ce=this.offsetInBuffer(ae.piece.bufferIndex,ae.piece.start);return de.substring(Ce+a.remainder,Ce+n.remainder)}let c=a.node;const I=this._buffers[c.piece.bufferIndex].buffer,F=this.offsetInBuffer(c.piece.bufferIndex,c.piece.start);let J=I.substring(F+a.remainder,F+c.piece.length);for(c=c.next();c!==Fe;){const ae=this._buffers[c.piece.bufferIndex].buffer,de=this.offsetInBuffer(c.piece.bufferIndex,c.piece.start);if(c===n.node){J+=ae.substring(de,de+n.remainder);break}else J+=ae.substr(de,c.piece.length);c=c.next()}return J}getLinesContent(){const a=[];let n=0,c="",I=!1;return this.iterate(this.root,F=>{if(F===Fe)return!0;const J=F.piece;let ae=J.length;if(ae===0)return!0;const de=this._buffers[J.bufferIndex].buffer,Ce=this._buffers[J.bufferIndex].lineStarts,Ee=J.start.line,Ne=J.end.line;let He=Ce[Ee]+J.start.column;if(I&&(de.charCodeAt(He)===10&&(He++,ae--),a[n++]=c,c="",I=!1,ae===0))return!0;if(Ee===Ne)return!this._EOLNormalized&&de.charCodeAt(He+ae-1)===13?(I=!0,c+=de.substr(He,ae-1)):c+=de.substr(He,ae),!0;c+=this._EOLNormalized?de.substring(He,Math.max(He,Ce[Ee+1]-this._EOLLength)):de.substring(He,Ce[Ee+1]).replace(/(\r\n|\r|\n)$/,""),a[n++]=c;for(let Ze=Ee+1;Ze<Ne;Ze++)c=this._EOLNormalized?de.substring(Ce[Ze],Ce[Ze+1]-this._EOLLength):de.substring(Ce[Ze],Ce[Ze+1]).replace(/(\r\n|\r|\n)$/,""),a[n++]=c;return!this._EOLNormalized&&de.charCodeAt(Ce[Ne]+J.end.column-1)===13?(I=!0,J.end.column===0?n--:c=de.substr(Ce[Ne],J.end.column-1)):c=de.substr(Ce[Ne],J.end.column),!0}),I&&(a[n++]=c,c=""),a[n++]=c,a}getLength(){return this._length}getLineCount(){return this._lineCnt}getLineContent(a){return this._lastVisitedLine.lineNumber===a?this._lastVisitedLine.value:(this._lastVisitedLine.lineNumber=a,a===this._lineCnt?this._lastVisitedLine.value=this.getLineRawContent(a):this._EOLNormalized?this._lastVisitedLine.value=this.getLineRawContent(a,this._EOLLength):this._lastVisitedLine.value=this.getLineRawContent(a).replace(/(\r\n|\r|\n)$/,""),this._lastVisitedLine.value)}_getCharCode(a){if(a.remainder===a.node.piece.length){const n=a.node.next();if(!n)return 0;const c=this._buffers[n.piece.bufferIndex],I=this.offsetInBuffer(n.piece.bufferIndex,n.piece.start);return c.buffer.charCodeAt(I)}else{const n=this._buffers[a.node.piece.bufferIndex],I=this.offsetInBuffer(a.node.piece.bufferIndex,a.node.piece.start)+a.remainder;return n.buffer.charCodeAt(I)}}getLineCharCode(a,n){const c=this.nodeAt2(a,n+1);return this._getCharCode(c)}getLineLength(a){if(a===this.getLineCount()){const n=this.getOffsetAt(a,1);return this.getLength()-n}return this.getOffsetAt(a+1,1)-this.getOffsetAt(a,1)-this._EOLLength}findMatchesInNode(a,n,c,I,F,J,ae,de,Ce,Ee,Ne){const He=this._buffers[a.piece.bufferIndex],Ze=this.offsetInBuffer(a.piece.bufferIndex,a.piece.start),et=this.offsetInBuffer(a.piece.bufferIndex,F),ot=this.offsetInBuffer(a.piece.bufferIndex,J);let lt;const _t={line:0,column:0};let Ft,ci;n._wordSeparators?(Ft=He.buffer.substring(et,ot),ci=Oi=>Oi+et,n.reset(0)):(Ft=He.buffer,ci=Oi=>Oi,n.reset(et));do if(lt=n.next(Ft),lt){if(ci(lt.index)>=ot)return Ee;this.positionInBuffer(a,ci(lt.index)-Ze,_t);const Oi=this.getLineFeedCnt(a.piece.bufferIndex,F,_t),on=_t.line===F.line?_t.column-F.column+I:_t.column+1,gn=on+lt[0].length;if(Ne[Ee++]=(0,nt.dr)(new d.Q(c+Oi,on,c+Oi,gn),lt,de),ci(lt.index)+lt[0].length>=ot||Ee>=Ce)return Ee}while(lt);return Ee}findMatchesLineByLine(a,n,c,I){const F=[];let J=0;const ae=new nt.W5(n.wordSeparators,n.regex);let de=this.nodeAt2(a.startLineNumber,a.startColumn);if(de===null)return[];const Ce=this.nodeAt2(a.endLineNumber,a.endColumn);if(Ce===null)return[];let Ee=this.positionInBuffer(de.node,de.remainder);const Ne=this.positionInBuffer(Ce.node,Ce.remainder);if(de.node===Ce.node)return this.findMatchesInNode(de.node,ae,a.startLineNumber,a.startColumn,Ee,Ne,n,c,I,J,F),F;let He=a.startLineNumber,Ze=de.node;for(;Ze!==Ce.node;){const ot=this.getLineFeedCnt(Ze.piece.bufferIndex,Ee,Ze.piece.end);if(ot>=1){const _t=this._buffers[Ze.piece.bufferIndex].lineStarts,Ft=this.offsetInBuffer(Ze.piece.bufferIndex,Ze.piece.start),ci=_t[Ee.line+ot],Oi=He===a.startLineNumber?a.startColumn:1;if(J=this.findMatchesInNode(Ze,ae,He,Oi,Ee,this.positionInBuffer(Ze,ci-Ft),n,c,I,J,F),J>=I)return F;He+=ot}const lt=He===a.startLineNumber?a.startColumn-1:0;if(He===a.endLineNumber){const _t=this.getLineContent(He).substring(lt,a.endColumn-1);return J=this._findMatchesInLine(n,ae,_t,a.endLineNumber,lt,J,F,c,I),F}if(J=this._findMatchesInLine(n,ae,this.getLineContent(He).substr(lt),He,lt,J,F,c,I),J>=I)return F;He++,de=this.nodeAt2(He,1),Ze=de.node,Ee=this.positionInBuffer(de.node,de.remainder)}if(He===a.endLineNumber){const ot=He===a.startLineNumber?a.startColumn-1:0,lt=this.getLineContent(He).substring(ot,a.endColumn-1);return J=this._findMatchesInLine(n,ae,lt,a.endLineNumber,ot,J,F,c,I),F}const et=He===a.startLineNumber?a.startColumn:1;return J=this.findMatchesInNode(Ce.node,ae,He,et,Ee,Ne,n,c,I,J,F),F}_findMatchesInLine(a,n,c,I,F,J,ae,de,Ce){const Ee=a.wordSeparators;if(!de&&a.simpleSearch){const He=a.simpleSearch,Ze=He.length,et=c.length;let ot=-Ze;for(;(ot=c.indexOf(He,ot+Ze))!==-1;)if((!Ee||(0,nt.wC)(Ee,c,et,ot,Ze))&&(ae[J++]=new w.Dg(new d.Q(I,ot+1+F,I,ot+1+Ze+F),null),J>=Ce))return J;return J}let Ne;n.reset(0);do if(Ne=n.next(c),Ne&&(ae[J++]=(0,nt.dr)(new d.Q(I,Ne.index+1+F,I,Ne.index+1+Ne[0].length+F),Ne,de),J>=Ce))return J;while(Ne);return J}insert(a,n,c=!1){if(this._EOLNormalized=this._EOLNormalized&&c,this._lastVisitedLine.lineNumber=0,this._lastVisitedLine.value="",this.root!==Fe){const{node:I,remainder:F,nodeStartOffset:J}=this.nodeAt(a),ae=I.piece,de=ae.bufferIndex,Ce=this.positionInBuffer(I,F);if(I.piece.bufferIndex===0&&ae.end.line===this._lastChangeBufferPos.line&&ae.end.column===this._lastChangeBufferPos.column&&J+ae.length===a&&n.length<at){this.appendToNode(I,n),this.computeBufferMetadata();return}if(J===a)this.insertContentToNodeLeft(n,I),this._searchCache.validate(a);else if(J+I.piece.length>a){const Ee=[];let Ne=new kt(ae.bufferIndex,Ce,ae.end,this.getLineFeedCnt(ae.bufferIndex,Ce,ae.end),this.offsetInBuffer(de,ae.end)-this.offsetInBuffer(de,Ce));if(this.shouldCheckCRLF()&&this.endWithCR(n)&&this.nodeCharCodeAt(I,F)===10){const ot={line:Ne.start.line+1,column:0};Ne=new kt(Ne.bufferIndex,ot,Ne.end,this.getLineFeedCnt(Ne.bufferIndex,ot,Ne.end),Ne.length-1),n+=` `}if(this.shouldCheckCRLF()&&this.startWithLF(n))if(this.nodeCharCodeAt(I,F-1)===13){const ot=this.positionInBuffer(I,F-1);this.deleteNodeTail(I,ot),n="\r"+n,I.piece.length===0&&Ee.push(I)}else this.deleteNodeTail(I,Ce);else this.deleteNodeTail(I,Ce);const He=this.createNewPieces(n);Ne.length>0&&this.rbInsertRight(I,Ne);let Ze=I;for(let et=0;et<He.length;et++)Ze=this.rbInsertRight(Ze,He[et]);this.deleteNodes(Ee)}else this.insertContentToNodeRight(n,I)}else{const I=this.createNewPieces(n);let F=this.rbInsertLeft(null,I[0]);for(let J=1;J<I.length;J++)F=this.rbInsertRight(F,I[J])}this.computeBufferMetadata()}delete(a,n){if(this._lastVisitedLine.lineNumber=0,this._lastVisitedLine.value="",n<=0||this.root===Fe)return;const c=this.nodeAt(a),I=this.nodeAt(a+n),F=c.node,J=I.node;if(F===J){const He=this.positionInBuffer(F,c.remainder),Ze=this.positionInBuffer(F,I.remainder);if(c.nodeStartOffset===a){if(n===F.piece.length){const et=F.next();St(this,F),this.validateCRLFWithPrevNode(et),this.computeBufferMetadata();return}this.deleteNodeHead(F,Ze),this._searchCache.validate(a),this.validateCRLFWithPrevNode(F),this.computeBufferMetadata();return}if(c.nodeStartOffset+F.piece.length===a+n){this.deleteNodeTail(F,He),this.validateCRLFWithNextNode(F),this.computeBufferMetadata();return}this.shrinkNode(F,He,Ze),this.computeBufferMetadata();return}const ae=[],de=this.positionInBuffer(F,c.remainder);this.deleteNodeTail(F,de),this._searchCache.validate(a),F.piece.length===0&&ae.push(F);const Ce=this.positionInBuffer(J,I.remainder);this.deleteNodeHead(J,Ce),J.piece.length===0&&ae.push(J);const Ee=F.next();for(let He=Ee;He!==Fe&&He!==J;He=He.next())ae.push(He);const Ne=F.piece.length===0?F.prev():F;this.deleteNodes(ae),this.validateCRLFWithNextNode(Ne),this.computeBufferMetadata()}insertContentToNodeLeft(a,n){const c=[];if(this.shouldCheckCRLF()&&this.endWithCR(a)&&this.startWithLF(n)){const J=n.piece,ae={line:J.start.line+1,column:0},de=new kt(J.bufferIndex,ae,J.end,this.getLineFeedCnt(J.bufferIndex,ae,J.end),J.length-1);n.piece=de,a+=` `,Te(this,n,-1,-1),n.piece.length===0&&c.push(n)}const I=this.createNewPieces(a);let F=this.rbInsertLeft(n,I[I.length-1]);for(let J=I.length-2;J>=0;J--)F=this.rbInsertLeft(F,I[J]);this.validateCRLFWithPrevNode(F),this.deleteNodes(c)}insertContentToNodeRight(a,n){this.adjustCarriageReturnFromNext(a,n)&&(a+=` `);const c=this.createNewPieces(a),I=this.rbInsertRight(n,c[0]);let F=I;for(let J=1;J<c.length;J++)F=this.rbInsertRight(F,c[J]);this.validateCRLFWithPrevNode(I)}positionInBuffer(a,n,c){const I=a.piece,F=a.piece.bufferIndex,J=this._buffers[F].lineStarts,de=J[I.start.line]+I.start.column+n;let Ce=I.start.line,Ee=I.end.line,Ne=0,He=0,Ze=0;for(;Ce<=Ee&&(Ne=Ce+(Ee-Ce)/2|0,Ze=J[Ne],Ne!==Ee);)if(He=J[Ne+1],de<Ze)Ee=Ne-1;else if(de>=He)Ce=Ne+1;else break;return c?(c.line=Ne,c.column=de-Ze,null):{line:Ne,column:de-Ze}}getLineFeedCnt(a,n,c){if(c.column===0)return c.line-n.line;const I=this._buffers[a].lineStarts;if(c.line===I.length-1)return c.line-n.line;const F=I[c.line+1],J=I[c.line]+c.column;if(F>J+1)return c.line-n.line;const ae=J-1;return this._buffers[a].buffer.charCodeAt(ae)===13?c.line-n.line+1:c.line-n.line}offsetInBuffer(a,n){return this._buffers[a].lineStarts[n.line]+n.column}deleteNodes(a){for(let n=0;n<a.length;n++)St(this,a[n])}createNewPieces(a){if(a.length>at){const Ee=[];for(;a.length>at;){const He=a.charCodeAt(at-1);let Ze;He===13||He>=55296&&He<=56319?(Ze=a.substring(0,at-1),a=a.substring(at-1)):(Ze=a.substring(0,at),a=a.substring(at));const et=At(Ze);Ee.push(new kt(this._buffers.length,{line:0,column:0},{line:et.length-1,column:Ze.length-et[et.length-1]},et.length-1,Ze.length)),this._buffers.push(new Ct(Ze,et))}const Ne=At(a);return Ee.push(new kt(this._buffers.length,{line:0,column:0},{line:Ne.length-1,column:a.length-Ne[Ne.length-1]},Ne.length-1,a.length)),this._buffers.push(new Ct(a,Ne)),Ee}let n=this._buffers[0].buffer.length;const c=At(a,!1);let I=this._lastChangeBufferPos;if(this._buffers[0].lineStarts[this._buffers[0].lineStarts.length-1]===n&&n!==0&&this.startWithLF(a)&&this.endWithCR(this._buffers[0].buffer)){this._lastChangeBufferPos={line:this._lastChangeBufferPos.line,column:this._lastChangeBufferPos.column+1},I=this._lastChangeBufferPos;for(let Ee=0;Ee<c.length;Ee++)c[Ee]+=n+1;this._buffers[0].lineStarts=this._buffers[0].lineStarts.concat(c.slice(1)),this._buffers[0].buffer+="_"+a,n+=1}else{if(n!==0)for(let Ee=0;Ee<c.length;Ee++)c[Ee]+=n;this._buffers[0].lineStarts=this._buffers[0].lineStarts.concat(c.slice(1)),this._buffers[0].buffer+=a}const F=this._buffers[0].buffer.length,J=this._buffers[0].lineStarts.length-1,ae=F-this._buffers[0].lineStarts[J],de={line:J,column:ae},Ce=new kt(0,I,de,this.getLineFeedCnt(0,I,de),F-n);return this._lastChangeBufferPos=de,[Ce]}getLineRawContent(a,n=0){let c=this.root,I="";const F=this._searchCache.get2(a);if(F){c=F.node;const J=this.getAccumulatedValue(c,a-F.nodeStartLineNumber-1),ae=this._buffers[c.piece.bufferIndex].buffer,de=this.offsetInBuffer(c.piece.bufferIndex,c.piece.start);if(F.nodeStartLineNumber+c.piece.lineFeedCnt===a)I=ae.substring(de+J,de+c.piece.length);else{const Ce=this.getAccumulatedValue(c,a-F.nodeStartLineNumber);return ae.substring(de+J,de+Ce-n)}}else{let J=0;const ae=a;for(;c!==Fe;)if(c.left!==Fe&&c.lf_left>=a-1)c=c.left;else if(c.lf_left+c.piece.lineFeedCnt>a-1){const de=this.getAccumulatedValue(c,a-c.lf_left-2),Ce=this.getAccumulatedValue(c,a-c.lf_left-1),Ee=this._buffers[c.piece.bufferIndex].buffer,Ne=this.offsetInBuffer(c.piece.bufferIndex,c.piece.start);return J+=c.size_left,this._searchCache.set({node:c,nodeStartOffset:J,nodeStartLineNumber:ae-(a-1-c.lf_left)}),Ee.substring(Ne+de,Ne+Ce-n)}else if(c.lf_left+c.piece.lineFeedCnt===a-1){const de=this.getAccumulatedValue(c,a-c.lf_left-2),Ce=this._buffers[c.piece.bufferIndex].buffer,Ee=this.offsetInBuffer(c.piece.bufferIndex,c.piece.start);I=Ce.substring(Ee+de,Ee+c.piece.length);break}else a-=c.lf_left+c.piece.lineFeedCnt,J+=c.size_left+c.piece.length,c=c.right}for(c=c.next();c!==Fe;){const J=this._buffers[c.piece.bufferIndex].buffer;if(c.piece.lineFeedCnt>0){const ae=this.getAccumulatedValue(c,0),de=this.offsetInBuffer(c.piece.bufferIndex,c.piece.start);return I+=J.substring(de,de+ae-n),I}else{const ae=this.offsetInBuffer(c.piece.bufferIndex,c.piece.start);I+=J.substr(ae,c.piece.length)}c=c.next()}return I}computeBufferMetadata(){let a=this.root,n=1,c=0;for(;a!==Fe;)n+=a.lf_left+a.piece.lineFeedCnt,c+=a.size_left+a.piece.length,a=a.right;this._lineCnt=n,this._length=c,this._searchCache.validate(this._length)}getIndexOf(a,n){const c=a.piece,I=this.positionInBuffer(a,n),F=I.line-c.start.line;if(this.offsetInBuffer(c.bufferIndex,c.end)-this.offsetInBuffer(c.bufferIndex,c.start)===n){const J=this.getLineFeedCnt(a.piece.bufferIndex,c.start,I);if(J!==F)return{index:J,remainder:0}}return{index:F,remainder:I.column}}getAccumulatedValue(a,n){if(n<0)return 0;const c=a.piece,I=this._buffers[c.bufferIndex].lineStarts,F=c.start.line+n+1;return F>c.end.line?I[c.end.line]+c.end.column-I[c.start.line]-c.start.column:I[F]-I[c.start.line]-c.start.column}deleteNodeTail(a,n){const c=a.piece,I=c.lineFeedCnt,F=this.offsetInBuffer(c.bufferIndex,c.end),J=n,ae=this.offsetInBuffer(c.bufferIndex,J),de=this.getLineFeedCnt(c.bufferIndex,c.start,J),Ce=de-I,Ee=ae-F,Ne=c.length+Ee;a.piece=new kt(c.bufferIndex,c.start,J,de,Ne),Te(this,a,Ee,Ce)}deleteNodeHead(a,n){const c=a.piece,I=c.lineFeedCnt,F=this.offsetInBuffer(c.bufferIndex,c.start),J=n,ae=this.getLineFeedCnt(c.bufferIndex,J,c.end),de=this.offsetInBuffer(c.bufferIndex,J),Ce=ae-I,Ee=F-de,Ne=c.length+Ee;a.piece=new kt(c.bufferIndex,J,c.end,ae,Ne),Te(this,a,Ee,Ce)}shrinkNode(a,n,c){const I=a.piece,F=I.start,J=I.end,ae=I.length,de=I.lineFeedCnt,Ce=n,Ee=this.getLineFeedCnt(I.bufferIndex,I.start,Ce),Ne=this.offsetInBuffer(I.bufferIndex,n)-this.offsetInBuffer(I.bufferIndex,F);a.piece=new kt(I.bufferIndex,I.start,Ce,Ee,Ne),Te(this,a,Ne-ae,Ee-de);const He=new kt(I.bufferIndex,c,J,this.getLineFeedCnt(I.bufferIndex,c,J),this.offsetInBuffer(I.bufferIndex,J)-this.offsetInBuffer(I.bufferIndex,c)),Ze=this.rbInsertRight(a,He);this.validateCRLFWithPrevNode(Ze)}appendToNode(a,n){this.adjustCarriageReturnFromNext(n,a)&&(n+=` `);const c=this.shouldCheckCRLF()&&this.startWithLF(n)&&this.endWithCR(a),I=this._buffers[0].buffer.length;this._buffers[0].buffer+=n;const F=At(n,!1);for(let Ze=0;Ze<F.length;Ze++)F[Ze]+=I;if(c){const Ze=this._buffers[0].lineStarts[this._buffers[0].lineStarts.length-2];this._buffers[0].lineStarts.pop(),this._lastChangeBufferPos={line:this._lastChangeBufferPos.line-1,column:I-Ze}}this._buffers[0].lineStarts=this._buffers[0].lineStarts.concat(F.slice(1));const J=this._buffers[0].lineStarts.length-1,ae=this._buffers[0].buffer.length-this._buffers[0].lineStarts[J],de={line:J,column:ae},Ce=a.piece.length+n.length,Ee=a.piece.lineFeedCnt,Ne=this.getLineFeedCnt(0,a.piece.start,de),He=Ne-Ee;a.piece=new kt(a.piece.bufferIndex,a.piece.start,de,Ne,Ce),this._lastChangeBufferPos=de,Te(this,a,n.length,He)}nodeAt(a){let n=this.root;const c=this._searchCache.get(a);if(c)return{node:c.node,nodeStartOffset:c.nodeStartOffset,remainder:a-c.nodeStartOffset};let I=0;for(;n!==Fe;)if(n.size_left>a)n=n.left;else if(n.size_left+n.piece.length>=a){I+=n.size_left;const F={node:n,remainder:a-n.size_left,nodeStartOffset:I};return this._searchCache.set(F),F}else a-=n.size_left+n.piece.length,I+=n.size_left+n.piece.length,n=n.right;return null}nodeAt2(a,n){let c=this.root,I=0;for(;c!==Fe;)if(c.left!==Fe&&c.lf_left>=a-1)c=c.left;else if(c.lf_left+c.piece.lineFeedCnt>a-1){const F=this.getAccumulatedValue(c,a-c.lf_left-2),J=this.getAccumulatedValue(c,a-c.lf_left-1);return I+=c.size_left,{node:c,remainder:Math.min(F+n-1,J),nodeStartOffset:I}}else if(c.lf_left+c.piece.lineFeedCnt===a-1){const F=this.getAccumulatedValue(c,a-c.lf_left-2);if(F+n-1<=c.piece.length)return{node:c,remainder:F+n-1,nodeStartOffset:I};n-=c.piece.length-F;break}else a-=c.lf_left+c.piece.lineFeedCnt,I+=c.size_left+c.piece.length,c=c.right;for(c=c.next();c!==Fe;){if(c.piece.lineFeedCnt>0){const F=this.getAccumulatedValue(c,0),J=this.offsetOfNode(c);return{node:c,remainder:Math.min(n-1,F),nodeStartOffset:J}}else if(c.piece.length>=n-1){const F=this.offsetOfNode(c);return{node:c,remainder:n-1,nodeStartOffset:F}}else n-=c.piece.length;c=c.next()}return null}nodeCharCodeAt(a,n){if(a.piece.lineFeedCnt<1)return-1;const c=this._buffers[a.piece.bufferIndex],I=this.offsetInBuffer(a.piece.bufferIndex,a.piece.start)+n;return c.buffer.charCodeAt(I)}offsetOfNode(a){if(!a)return 0;let n=a.size_left;for(;a!==this.root;)a.parent.right===a&&(n+=a.parent.size_left+a.parent.piece.length),a=a.parent;return n}shouldCheckCRLF(){return!(this._EOLNormalized&&this._EOL===` `)}startWithLF(a){if(typeof a=="string")return a.charCodeAt(0)===10;if(a===Fe||a.piece.lineFeedCnt===0)return!1;const n=a.piece,c=this._buffers[n.bufferIndex].lineStarts,I=n.start.line,F=c[I]+n.start.column;return I===c.length-1||c[I+1]>F+1?!1:this._buffers[n.bufferIndex].buffer.charCodeAt(F)===10}endWithCR(a){return typeof a=="string"?a.charCodeAt(a.length-1)===13:a===Fe||a.piece.lineFeedCnt===0?!1:this.nodeCharCodeAt(a,a.piece.length-1)===13}validateCRLFWithPrevNode(a){if(this.shouldCheckCRLF()&&this.startWithLF(a)){const n=a.prev();this.endWithCR(n)&&this.fixCRLF(n,a)}}validateCRLFWithNextNode(a){if(this.shouldCheckCRLF()&&this.endWithCR(a)){const n=a.next();this.startWithLF(n)&&this.fixCRLF(a,n)}}fixCRLF(a,n){const c=[],I=this._buffers[a.piece.bufferIndex].lineStarts;let F;a.piece.end.column===0?F={line:a.piece.end.line-1,column:I[a.piece.end.line]-I[a.piece.end.line-1]-1}:F={line:a.piece.end.line,column:a.piece.end.column-1};const J=a.piece.length-1,ae=a.piece.lineFeedCnt-1;a.piece=new kt(a.piece.bufferIndex,a.piece.start,F,ae,J),Te(this,a,-1,-1),a.piece.length===0&&c.push(a);const de={line:n.piece.start.line+1,column:0},Ce=n.piece.length-1,Ee=this.getLineFeedCnt(n.piece.bufferIndex,de,n.piece.end);n.piece=new kt(n.piece.bufferIndex,de,n.piece.end,Ee,Ce),Te(this,n,-1,-1),n.piece.length===0&&c.push(n);const Ne=this.createNewPieces(`\r `);this.rbInsertRight(a,Ne[0]);for(let He=0;He<c.length;He++)St(this,c[He])}adjustCarriageReturnFromNext(a,n){if(this.shouldCheckCRLF()&&this.endWithCR(a)){const c=n.next();if(this.startWithLF(c)){if(a+=` `,c.piece.length===1)St(this,c);else{const I=c.piece,F={line:I.start.line+1,column:0},J=I.length-1,ae=this.getLineFeedCnt(I.bufferIndex,F,I.end);c.piece=new kt(I.bufferIndex,F,I.end,ae,J),Te(this,c,-1,-1)}return!0}}return!1}iterate(a,n){if(a===Fe)return n(Fe);const c=this.iterate(a.left,n);return c&&n(a)&&this.iterate(a.right,n)}getNodeContent(a){if(a===Fe)return"";const n=this._buffers[a.piece.bufferIndex],c=a.piece,I=this.offsetInBuffer(c.bufferIndex,c.start),F=this.offsetInBuffer(c.bufferIndex,c.end);return n.buffer.substring(I,F)}getPieceContent(a){const n=this._buffers[a.bufferIndex],c=this.offsetInBuffer(a.bufferIndex,a.start),I=this.offsetInBuffer(a.bufferIndex,a.end);return n.buffer.substring(c,I)}rbInsertRight(a,n){const c=new _i(n,1);if(c.left=Fe,c.right=Fe,c.parent=Fe,c.size_left=0,c.lf_left=0,this.root===Fe)this.root=c,c.color=0;else if(a.right===Fe)a.right=c,c.parent=a;else{const F=Xe(a.right);F.left=c,c.parent=F}return ve(this,c),c}rbInsertLeft(a,n){const c=new _i(n,1);if(c.left=Fe,c.right=Fe,c.parent=Fe,c.size_left=0,c.lf_left=0,this.root===Fe)this.root=c,c.color=0;else if(a.left===Fe)a.left=c,c.parent=a;else{const I=gt(a.left);I.right=c,c.parent=I}return ve(this,c),c}}var Ue=y(6949);class ei extends L.jG{constructor(a,n,c,I,F,J,ae){super(),this._onDidChangeContent=this._register(new $.vl),this._BOM=n,this._mightContainNonBasicASCII=!J,this._mightContainRTL=I,this._mightContainUnusualLineTerminators=F,this._pieceTree=new Ut(a,c,ae)}mightContainRTL(){return this._mightContainRTL}mightContainUnusualLineTerminators(){return this._mightContainUnusualLineTerminators}resetMightContainUnusualLineTerminators(){this._mightContainUnusualLineTerminators=!1}mightContainNonBasicASCII(){return this._mightContainNonBasicASCII}getBOM(){return this._BOM}getEOL(){return this._pieceTree.getEOL()}createSnapshot(a){return this._pieceTree.createSnapshot(a?this._BOM:"")}getOffsetAt(a,n){return this._pieceTree.getOffsetAt(a,n)}getPositionAt(a){return this._pieceTree.getPositionAt(a)}getRangeAt(a,n){const c=a+n,I=this.getPositionAt(a),F=this.getPositionAt(c);return new d.Q(I.lineNumber,I.column,F.lineNumber,F.column)}getValueInRange(a,n=0){if(a.isEmpty())return"";const c=this._getEndOfLine(n);return this._pieceTree.getValueInRange(a,c)}getValueLengthInRange(a,n=0){if(a.isEmpty())return 0;if(a.startLineNumber===a.endLineNumber)return a.endColumn-a.startColumn;const c=this.getOffsetAt(a.startLineNumber,a.startColumn);return this.getOffsetAt(a.endLineNumber,a.endColumn)-c}getCharacterCountInRange(a,n=0){if(this._mightContainNonBasicASCII){let c=0;const I=a.startLineNumber,F=a.endLineNumber;for(let J=I;J<=F;J++){const ae=this.getLineContent(J),de=J===I?a.startColumn-1:0,Ce=J===F?a.endColumn-1:ae.length;for(let Ee=de;Ee<Ce;Ee++)U.pc(ae.charCodeAt(Ee))?(c=c+1,Ee=Ee+1):c=c+1}return c+=this._getEndOfLine(n).length*(F-I),c}return this.getValueLengthInRange(a,n)}getLength(){return this._pieceTree.getLength()}getLineCount(){return this._pieceTree.getLineCount()}getLinesContent(){return this._pieceTree.getLinesContent()}getLineContent(a){return this._pieceTree.getLineContent(a)}getLineCharCode(a,n){return this._pieceTree.getLineCharCode(a,n)}getLineLength(a){return this._pieceTree.getLineLength(a)}getLineFirstNonWhitespaceColumn(a){const n=U.HG(this.getLineContent(a));return n===-1?0:n+1}getLineLastNonWhitespaceColumn(a){const n=U.lT(this.getLineContent(a));return n===-1?0:n+2}_getEndOfLine(a){switch(a){case 1:return` `;case 2:return`\r `;case 0:return this.getEOL();default:throw new Error("Unknown EOL preference")}}setEOL(a){this._pieceTree.setEOL(a)}applyEdits(a,n,c){let I=this._mightContainRTL,F=this._mightContainUnusualLineTerminators,J=this._mightContainNonBasicASCII,ae=!0,de=[];for(let ot=0;ot<a.length;ot++){const lt=a[ot];ae&<._isTracked&&(ae=!1);const _t=lt.range;if(lt.text){let gn=!0;J||(gn=!U.aC(lt.text),J=gn),!I&&gn&&(I=U.E_(lt.text)),!F&&gn&&(F=U.$X(lt.text))}let Ft="",ci=0,Oi=0,on=0;if(lt.text){let gn;[ci,Oi,on,gn]=(0,B.W)(lt.text);const hn=this.getEOL();gn===0||gn===(hn===`\r `?2:1)?Ft=lt.text:Ft=lt.text.replace(/\r\n|\r|\n/g,hn)}de[ot]={sortIndex:ot,identifier:lt.identifier||null,range:_t,rangeOffset:this.getOffsetAt(_t.startLineNumber,_t.startColumn),rangeLength:this.getValueLengthInRange(_t),text:Ft,eolCount:ci,firstLineLength:Oi,lastLineLength:on,forceMoveMarkers:!!lt.forceMoveMarkers,isAutoWhitespaceEdit:lt.isAutoWhitespaceEdit||!1}}de.sort(ei._sortOpsAscending);let Ce=!1;for(let ot=0,lt=de.length-1;ot<lt;ot++){const _t=de[ot].range.getEndPosition(),Ft=de[ot+1].range.getStartPosition();if(Ft.isBeforeOrEqual(_t)){if(Ft.isBefore(_t))throw new Error("Overlapping ranges are not allowed!");Ce=!0}}ae&&(de=this._reduceOperations(de));const Ee=c||n?ei._getInverseEditRanges(de):[],Ne=[];if(n)for(let ot=0;ot<de.length;ot++){const lt=de[ot],_t=Ee[ot];if(lt.isAutoWhitespaceEdit&<.range.isEmpty())for(let Ft=_t.startLineNumber;Ft<=_t.endLineNumber;Ft++){let ci="";Ft===_t.startLineNumber&&(ci=this.getLineContent(lt.range.startLineNumber),U.HG(ci)!==-1)||Ne.push({lineNumber:Ft,oldContent:ci})}}let He=null;if(c){let ot=0;He=[];for(let lt=0;lt<de.length;lt++){const _t=de[lt],Ft=Ee[lt],ci=this.getValueInRange(_t.range),Oi=_t.rangeOffset+ot;ot+=_t.text.length-ci.length,He[lt]={sortIndex:_t.sortIndex,identifier:_t.identifier,range:Ft,text:ci,textChange:new Ue.k(_t.rangeOffset,ci,Oi,_t.text)}}Ce||He.sort((lt,_t)=>lt.sortIndex-_t.sortIndex)}this._mightContainRTL=I,this._mightContainUnusualLineTerminators=F,this._mightContainNonBasicASCII=J;const Ze=this._doApplyEdits(de);let et=null;if(n&&Ne.length>0){Ne.sort((ot,lt)=>lt.lineNumber-ot.lineNumber),et=[];for(let ot=0,lt=Ne.length;ot<lt;ot++){const _t=Ne[ot].lineNumber;if(ot>0&&Ne[ot-1].lineNumber===_t)continue;const Ft=Ne[ot].oldContent,ci=this.getLineContent(_t);ci.length===0||ci===Ft||U.HG(ci)!==-1||et.push(_t)}}return this._onDidChangeContent.fire(),new w.F4(He,Ze,et)}_reduceOperations(a){return a.length<1e3?a:[this._toSingleEditOperation(a)]}_toSingleEditOperation(a){let n=!1;const c=a[0].range,I=a[a.length-1].range,F=new d.Q(c.startLineNumber,c.startColumn,I.endLineNumber,I.endColumn);let J=c.startLineNumber,ae=c.startColumn;const de=[];for(let Ze=0,et=a.length;Ze<et;Ze++){const ot=a[Ze],lt=ot.range;n=n||ot.forceMoveMarkers,de.push(this.getValueInRange(new d.Q(J,ae,lt.startLineNumber,lt.startColumn))),ot.text.length>0&&de.push(ot.text),J=lt.endLineNumber,ae=lt.endColumn}const Ce=de.join(""),[Ee,Ne,He]=(0,B.W)(Ce);return{sortIndex:0,identifier:a[0].identifier,range:F,rangeOffset:this.getOffsetAt(F.startLineNumber,F.startColumn),rangeLength:this.getValueLengthInRange(F,0),text:Ce,eolCount:Ee,firstLineLength:Ne,lastLineLength:He,forceMoveMarkers:n,isAutoWhitespaceEdit:!1}}_doApplyEdits(a){a.sort(ei._sortOpsDescending);const n=[];for(let c=0;c<a.length;c++){const I=a[c],F=I.range.startLineNumber,J=I.range.startColumn,ae=I.range.endLineNumber,de=I.range.endColumn;if(F===ae&&J===de&&I.text.length===0)continue;I.text?(this._pieceTree.delete(I.rangeOffset,I.rangeLength),this._pieceTree.insert(I.rangeOffset,I.text,!0)):this._pieceTree.delete(I.rangeOffset,I.rangeLength);const Ce=new d.Q(F,J,ae,de);n.push({range:Ce,rangeLength:I.rangeLength,text:I.text,rangeOffset:I.rangeOffset,forceMoveMarkers:I.forceMoveMarkers})}return n}findMatchesLineByLine(a,n,c,I){return this._pieceTree.findMatchesLineByLine(a,n,c,I)}static _getInverseEditRanges(a){const n=[];let c=0,I=0,F=null;for(let J=0,ae=a.length;J<ae;J++){const de=a[J];let Ce,Ee;F?F.range.endLineNumber===de.range.startLineNumber?(Ce=c,Ee=I+(de.range.startColumn-F.range.endColumn)):(Ce=c+(de.range.startLineNumber-F.range.endLineNumber),Ee=de.range.startColumn):(Ce=de.range.startLineNumber,Ee=de.range.startColumn);let Ne;if(de.text.length>0){const He=de.eolCount+1;He===1?Ne=new d.Q(Ce,Ee,Ce,Ee+de.firstLineLength):Ne=new d.Q(Ce,Ee,Ce+He-1,de.lastLineLength+1)}else Ne=new d.Q(Ce,Ee,Ce,Ee);c=Ne.endLineNumber,I=Ne.endColumn,n.push(Ne),F=de}return n}static _sortOpsAscending(a,n){const c=d.Q.compareRangesUsingEnds(a.range,n.range);return c===0?a.sortIndex-n.sortIndex:c}static _sortOpsDescending(a,n){const c=d.Q.compareRangesUsingEnds(a.range,n.range);return c===0?n.sortIndex-a.sortIndex:-c}}class ui{constructor(a,n,c,I,F,J,ae,de,Ce){this._chunks=a,this._bom=n,this._cr=c,this._lf=I,this._crlf=F,this._containsRTL=J,this._containsUnusualLineTerminators=ae,this._isBasicASCII=de,this._normalizeEOL=Ce}_getEOL(a){const n=this._cr+this._lf+this._crlf,c=this._cr+this._crlf;return n===0?a===1?` `:`\r `:c>n/2?`\r `:` `}create(a){const n=this._getEOL(a),c=this._chunks;if(this._normalizeEOL&&(n===`\r `&&(this._cr>0||this._lf>0)||n===` `&&(this._cr>0||this._crlf>0)))for(let F=0,J=c.length;F<J;F++){const ae=c[F].buffer.replace(/\r\n|\r|\n/g,n),de=At(ae);c[F]=new Ct(ae,de)}const I=new ei(c,this._bom,n,this._containsRTL,this._containsUnusualLineTerminators,this._isBasicASCII,this._normalizeEOL);return{textBuffer:I,disposable:I}}}class oi{constructor(){this.chunks=[],this.BOM="",this._hasPreviousChar=!1,this._previousChar=0,this._tmpLineStarts=[],this.cr=0,this.lf=0,this.crlf=0,this.containsRTL=!1,this.containsUnusualLineTerminators=!1,this.isBasicASCII=!0}acceptChunk(a){if(a.length===0)return;this.chunks.length===0&&U.LU(a)&&(this.BOM=U.r_,a=a.substr(1));const n=a.charCodeAt(a.length-1);n===13||n>=55296&&n<=56319?(this._acceptChunk1(a.substr(0,a.length-1),!1),this._hasPreviousChar=!0,this._previousChar=n):(this._acceptChunk1(a,!1),this._hasPreviousChar=!1,this._previousChar=n)}_acceptChunk1(a,n){!n&&a.length===0||(this._hasPreviousChar?this._acceptChunk2(String.fromCharCode(this._previousChar)+a):this._acceptChunk2(a))}_acceptChunk2(a){const n=wt(this._tmpLineStarts,a);this.chunks.push(new Ct(a,n.lineStarts)),this.cr+=n.cr,this.lf+=n.lf,this.crlf+=n.crlf,this.isBasicASCII&&(this.isBasicASCII=n.isBasicASCII),!this.isBasicASCII&&!this.containsRTL&&(this.containsRTL=U.E_(a)),!this.isBasicASCII&&!this.containsUnusualLineTerminators&&(this.containsUnusualLineTerminators=U.$X(a))}finish(a=!0){return this._finish(),new ui(this.chunks,this.BOM,this.cr,this.lf,this.crlf,this.containsRTL,this.containsUnusualLineTerminators,this.isBasicASCII,a)}_finish(){if(this.chunks.length===0&&this._acceptChunk1("",!0),this._hasPreviousChar){this._hasPreviousChar=!1;const a=this.chunks[this.chunks.length-1];a.buffer+=String.fromCharCode(this._previousChar);const n=At(a.buffer);a.lineStarts=n,this._previousChar===13&&this.cr++}}}var ki=y(18782),Kt=y(32177),li=y(57445),Ci=y(47317),mi=y(97036),Tt=y(23013);class qt{constructor(a,n){this._startLineNumber=a,this._tokens=n}get startLineNumber(){return this._startLineNumber}get endLineNumber(){return this._startLineNumber+this._tokens.length-1}getLineTokens(a){return this._tokens[a-this._startLineNumber]}appendLineTokens(a){this._tokens.push(a)}}class Ni{constructor(){this._tokens=[]}add(a,n){if(this._tokens.length>0){const c=this._tokens[this._tokens.length-1];if(c.endLineNumber+1===a){c.appendLineTokens(n);return}}this._tokens.push(new qt(a,[n]))}finalize(){return this._tokens}}var Fi=y(65958),yi=y(63339);class ti{constructor(a){this._default=a,this._store=[]}get(a){return a<this._store.length?this._store[a]:this._default}set(a,n){for(;a>=this._store.length;)this._store[this._store.length]=this._default;this._store[a]=n}delete(a,n){n===0||a>=this._store.length||this._store.splice(a,n)}insert(a,n){if(n===0||a>=this._store.length)return;const c=[];for(let I=0;I<n;I++)c[I]=this._default;this._store=b.nK(this._store,a,c)}}class wi{constructor(a,n){this.tokenizationSupport=a,this.initialState=n,this._lineBeginState=new ti(null),this._lineNeedsTokenization=new ti(!0),this._firstLineNeedsTokenization=0,this._lineBeginState.set(0,this.initialState)}get invalidLineStartIndex(){return this._firstLineNeedsTokenization}markMustBeTokenized(a){this._lineNeedsTokenization.set(a,!0),this._firstLineNeedsTokenization=Math.min(this._firstLineNeedsTokenization,a)}getBeginState(a){return this._lineBeginState.get(a)}setEndState(a,n,c){if(this._lineNeedsTokenization.set(n,!1),this._firstLineNeedsTokenization=n+1,n===a-1)return;const I=this._lineBeginState.get(n+1);if(I===null||!c.equals(I)){this._lineBeginState.set(n+1,c),this.markMustBeTokenized(n+1);return}let F=n+1;for(;F<a&&!this._lineNeedsTokenization.get(F);)F++;this._firstLineNeedsTokenization=F}applyEdits(a,n){this.markMustBeTokenized(a.startLineNumber-1),this._lineBeginState.delete(a.startLineNumber,a.endLineNumber-a.startLineNumber),this._lineNeedsTokenization.delete(a.startLineNumber,a.endLineNumber-a.startLineNumber),this._lineBeginState.insert(a.startLineNumber,n),this._lineNeedsTokenization.insert(a.startLineNumber,n)}}class Qi extends L.jG{constructor(a,n,c){super(),this._textModel=a,this._tokenizationPart=n,this._languageIdCodec=c,this._isScheduled=!1,this._isDisposed=!1,this._tokenizationStateStore=null,this._register(Ci.dG.onDidChange(I=>{const F=this._textModel.getLanguageId();I.changedLanguages.indexOf(F)!==-1&&(this._resetTokenizationState(),this._tokenizationPart.clearTokens())})),this._resetTokenizationState()}dispose(){this._isDisposed=!0,super.dispose()}handleDidChangeContent(a){if(a.isFlush){this._resetTokenizationState();return}if(this._tokenizationStateStore)for(let n=0,c=a.changes.length;n<c;n++){const I=a.changes[n],[F]=(0,B.W)(I.text);this._tokenizationStateStore.applyEdits(I.range,F)}this._beginBackgroundTokenization()}handleDidChangeAttached(){this._beginBackgroundTokenization()}handleDidChangeLanguage(a){this._resetTokenizationState(),this._tokenizationPart.clearTokens()}_resetTokenizationState(){const[a,n]=Vi(this._textModel,this._tokenizationPart);a&&n?this._tokenizationStateStore=new wi(a,n):this._tokenizationStateStore=null,this._beginBackgroundTokenization()}_beginBackgroundTokenization(){this._isScheduled||!this._textModel.isAttachedToEditor()||!this._hasLinesToTokenize()||(this._isScheduled=!0,(0,Fi.cx)(a=>{this._isScheduled=!1,this._backgroundTokenizeWithDeadline(a)}))}_backgroundTokenizeWithDeadline(a){const n=Date.now()+a.timeRemaining(),c=()=>{this._isDisposed||!this._textModel.isAttachedToEditor()||!this._hasLinesToTokenize()||(this._backgroundTokenizeForAtLeast1ms(),Date.now()<n?(0,yi._p)(c):this._beginBackgroundTokenization())};c()}_backgroundTokenizeForAtLeast1ms(){const a=this._textModel.getLineCount(),n=new Ni,c=Tt.W.create(!1);do if(c.elapsed()>1||this._tokenizeOneInvalidLine(n)>=a)break;while(this._hasLinesToTokenize());this._tokenizationPart.setTokens(n.finalize(),this._isTokenizationComplete())}tokenizeViewport(a,n){const c=new Ni;this._tokenizeViewport(c,a,n),this._tokenizationPart.setTokens(c.finalize(),this._isTokenizationComplete())}reset(){this._resetTokenizationState(),this._tokenizationPart.clearTokens()}forceTokenization(a){const n=new Ni;this._updateTokensUntilLine(n,a),this._tokenizationPart.setTokens(n.finalize(),this._isTokenizationComplete())}getTokenTypeIfInsertingCharacter(a,n){if(!this._tokenizationStateStore)return 0;this.forceTokenization(a.lineNumber);const c=this._tokenizationStateStore.getBeginState(a.lineNumber-1);if(!c)return 0;const I=this._textModel.getLanguageId(),F=this._textModel.getLineContent(a.lineNumber),J=F.substring(0,a.column-1)+n+F.substring(a.column-1),ae=Zi(this._languageIdCodec,I,this._tokenizationStateStore.tokenizationSupport,J,!0,c),de=new li.f(ae.tokens,J,this._languageIdCodec);if(de.getCount()===0)return 0;const Ce=de.findTokenIndexAtOffset(a.column-1);return de.getStandardTokenType(Ce)}tokenizeLineWithEdit(a,n,c){const I=a.lineNumber,F=a.column;if(!this._tokenizationStateStore)return null;this.forceTokenization(I);const J=this._tokenizationStateStore.getBeginState(I-1);if(!J)return null;const ae=this._textModel.getLineContent(I),de=ae.substring(0,F-1)+c+ae.substring(F-1+n),Ce=this._textModel.getLanguageIdAtPosition(I,0),Ee=Zi(this._languageIdCodec,Ce,this._tokenizationStateStore.tokenizationSupport,de,!0,J);return new li.f(Ee.tokens,de,this._languageIdCodec)}isCheapToTokenize(a){if(!this._tokenizationStateStore)return!0;const n=this._tokenizationStateStore.invalidLineStartIndex+1;return a>n?!1:a<n||this._textModel.getLineLength(a)<2048}_hasLinesToTokenize(){return this._tokenizationStateStore?this._tokenizationStateStore.invalidLineStartIndex<this._textModel.getLineCount():!1}_isTokenizationComplete(){return this._tokenizationStateStore?this._tokenizationStateStore.invalidLineStartIndex>=this._textModel.getLineCount():!1}_tokenizeOneInvalidLine(a){if(!this._tokenizationStateStore||!this._hasLinesToTokenize())return this._textModel.getLineCount()+1;const n=this._tokenizationStateStore.invalidLineStartIndex+1;return this._updateTokensUntilLine(a,n),n}_updateTokensUntilLine(a,n){if(!this._tokenizationStateStore)return;const c=this._textModel.getLanguageId(),I=this._textModel.getLineCount(),F=n-1;for(let J=this._tokenizationStateStore.invalidLineStartIndex;J<=F;J++){const ae=this._textModel.getLineContent(J+1),de=this._tokenizationStateStore.getBeginState(J),Ce=Zi(this._languageIdCodec,c,this._tokenizationStateStore.tokenizationSupport,ae,!0,de);a.add(J+1,Ce.tokens),this._tokenizationStateStore.setEndState(I,J,Ce.endState),J=this._tokenizationStateStore.invalidLineStartIndex-1}}_tokenizeViewport(a,n,c){if(!this._tokenizationStateStore||c<=this._tokenizationStateStore.invalidLineStartIndex)return;if(n<=this._tokenizationStateStore.invalidLineStartIndex){this._updateTokensUntilLine(a,c);return}let I=this._textModel.getLineFirstNonWhitespaceColumn(n);const F=[];let J=null;for(let Ce=n-1;I>1&&Ce>=1;Ce--){const Ee=this._textModel.getLineFirstNonWhitespaceColumn(Ce);if(Ee!==0&&Ee<I&&(F.push(this._textModel.getLineContent(Ce)),I=Ee,J=this._tokenizationStateStore.getBeginState(Ce-1),J))break}J||(J=this._tokenizationStateStore.initialState);const ae=this._textModel.getLanguageId();let de=J;for(let Ce=F.length-1;Ce>=0;Ce--)de=Zi(this._languageIdCodec,ae,this._tokenizationStateStore.tokenizationSupport,F[Ce],!1,de).endState;for(let Ce=n;Ce<=c;Ce++){const Ee=this._textModel.getLineContent(Ce),Ne=Zi(this._languageIdCodec,ae,this._tokenizationStateStore.tokenizationSupport,Ee,!0,de);a.add(Ce,Ne.tokens),this._tokenizationStateStore.markMustBeTokenized(Ce-1),de=Ne.endState}}}function Vi(xe,a){if(xe.isTooLargeForTokenization())return[null,null];const n=Ci.dG.get(a.getLanguageId());if(!n)return[null,null];let c;try{c=n.getInitialState()}catch(I){return(0,K.dz)(I),[null,null]}return[n,c]}function Zi(xe,a,n,c,I,F){let J=null;if(n)try{J=n.tokenizeEncoded(c,I,F.clone())}catch(ae){(0,K.dz)(ae)}return J||(J=(0,mi.Lh)(xe.encodeLanguageId(a),F)),li.f.convertToEndOffset(J.tokens,c.length),J}const Ji=new Uint32Array(0).buffer;class qi{static deleteBeginning(a,n){return a===null||a===Ji?a:qi.delete(a,0,n)}static deleteEnding(a,n){if(a===null||a===Ji)return a;const c=Pi(a),I=c[c.length-2];return qi.delete(a,n,I)}static delete(a,n,c){if(a===null||a===Ji||n===c)return a;const I=Pi(a),F=I.length>>>1;if(n===0&&I[I.length-2]===c)return Ji;const J=li.f.findIndexInTokensArray(I,n),ae=J>0?I[J-1<<1]:0,de=I[J<<1];if(c<de){const Ze=c-n;for(let et=J;et<F;et++)I[et<<1]-=Ze;return a}let Ce,Ee;ae!==n?(I[J<<1]=n,Ce=J+1<<1,Ee=n):(Ce=J<<1,Ee=ae);const Ne=c-n;for(let Ze=J+1;Ze<F;Ze++){const et=I[Ze<<1]-Ne;et>Ee&&(I[Ce++]=et,I[Ce++]=I[(Ze<<1)+1],Ee=et)}if(Ce===I.length)return a;const He=new Uint32Array(Ce);return He.set(I.subarray(0,Ce),0),He.buffer}static append(a,n){if(n===Ji)return a;if(a===Ji)return n;if(a===null)return a;if(n===null)return null;const c=Pi(a),I=Pi(n),F=I.length>>>1,J=new Uint32Array(c.length+I.length);J.set(c,0);let ae=c.length;const de=c[c.length-2];for(let Ce=0;Ce<F;Ce++)J[ae++]=I[Ce<<1]+de,J[ae++]=I[(Ce<<1)+1];return J.buffer}static insert(a,n,c){if(a===null||a===Ji)return a;const I=Pi(a),F=I.length>>>1;let J=li.f.findIndexInTokensArray(I,n);J>0&&I[J-1<<1]===n&&J--;for(let ae=J;ae<F;ae++)I[ae<<1]+=c;return a}}function Pi(xe){return xe instanceof Uint32Array?xe:new Uint32Array(xe)}var fi=y(15910);class Sn{constructor(a){this._lineTokens=[],this._len=0,this._languageIdCodec=a}flush(){this._lineTokens=[],this._len=0}getTokens(a,n,c){let I=null;if(n<this._len&&(I=this._lineTokens[n]),I!==null&&I!==Ji)return new li.f(Pi(I),c,this._languageIdCodec);const F=new Uint32Array(2);return F[0]=c.length,F[1]=cn(this._languageIdCodec.encodeLanguageId(a)),new li.f(F,c,this._languageIdCodec)}static _massageTokens(a,n,c){const I=c?Pi(c):null;if(n===0){let F=!1;if(I&&I.length>1&&(F=fi.x.getLanguageId(I[1])!==a),!F)return Ji}if(!I||I.length===0){const F=new Uint32Array(2);return F[0]=n,F[1]=cn(a),F.buffer}return I[I.length-2]=n,I.byteOffset===0&&I.byteLength===I.buffer.byteLength?I.buffer:I}_ensureLine(a){for(;a>=this._len;)this._lineTokens[this._len]=null,this._len++}_deleteLines(a,n){n!==0&&(a+n>this._len&&(n=this._len-a),this._lineTokens.splice(a,n),this._len-=n)}_insertLines(a,n){if(n===0)return;const c=[];for(let I=0;I<n;I++)c[I]=null;this._lineTokens=b.nK(this._lineTokens,a,c),this._len+=n}setTokens(a,n,c,I,F){const J=Sn._massageTokens(this._languageIdCodec.encodeLanguageId(a),c,I);this._ensureLine(n);const ae=this._lineTokens[n];return this._lineTokens[n]=J,F?!Sn._equals(ae,J):!1}static _equals(a,n){if(!a||!n)return!a&&!n;const c=Pi(a),I=Pi(n);if(c.length!==I.length)return!1;for(let F=0,J=c.length;F<J;F++)if(c[F]!==I[F])return!1;return!0}acceptEdit(a,n,c){this._acceptDeleteRange(a),this._acceptInsertText(new p.y(a.startLineNumber,a.startColumn),n,c)}_acceptDeleteRange(a){const n=a.startLineNumber-1;if(n>=this._len)return;if(a.startLineNumber===a.endLineNumber){if(a.startColumn===a.endColumn)return;this._lineTokens[n]=qi.delete(this._lineTokens[n],a.startColumn-1,a.endColumn-1);return}this._lineTokens[n]=qi.deleteEnding(this._lineTokens[n],a.startColumn-1);const c=a.endLineNumber-1;let I=null;c<this._len&&(I=qi.deleteBeginning(this._lineTokens[c],a.endColumn-1)),this._lineTokens[n]=qi.append(this._lineTokens[n],I),this._deleteLines(a.startLineNumber,a.endLineNumber-a.startLineNumber)}_acceptInsertText(a,n,c){if(n===0&&c===0)return;const I=a.lineNumber-1;if(!(I>=this._len)){if(n===0){this._lineTokens[I]=qi.insert(this._lineTokens[I],a.column-1,c);return}this._lineTokens[I]=qi.deleteEnding(this._lineTokens[I],a.column-1),this._lineTokens[I]=qi.insert(this._lineTokens[I],a.column-1,c),this._insertLines(a.lineNumber,n)}}}function cn(xe){return(xe<<0|0|0|32768|2<<24|1024)>>>0}class en{constructor(a){this._pieces=[],this._isComplete=!1,this._languageIdCodec=a}flush(){this._pieces=[],this._isComplete=!1}isEmpty(){return this._pieces.length===0}set(a,n){this._pieces=a||[],this._isComplete=n}setPartial(a,n){let c=a;if(n.length>0){const F=n[0].getRange(),J=n[n.length-1].getRange();if(!F||!J)return a;c=a.plusRange(F).plusRange(J)}let I=null;for(let F=0,J=this._pieces.length;F<J;F++){const ae=this._pieces[F];if(ae.endLineNumber<c.startLineNumber)continue;if(ae.startLineNumber>c.endLineNumber){I=I||{index:F};break}if(ae.removeTokens(c),ae.isEmpty()){this._pieces.splice(F,1),F--,J--;continue}if(ae.endLineNumber<c.startLineNumber)continue;if(ae.startLineNumber>c.endLineNumber){I=I||{index:F};continue}const[de,Ce]=ae.split(c);if(de.isEmpty()){I=I||{index:F};continue}Ce.isEmpty()||(this._pieces.splice(F,1,de,Ce),F++,J++,I=I||{index:F})}return I=I||{index:this._pieces.length},n.length>0&&(this._pieces=b.nK(this._pieces,I.index,n)),c}isComplete(){return this._isComplete}addSparseTokens(a,n){if(n.getLineContent().length===0)return n;const c=this._pieces;if(c.length===0)return n;const I=en._findFirstPieceWithLine(c,a),F=c[I].getLineTokens(a);if(!F)return n;const J=n.getCount(),ae=F.getCount();let de=0;const Ce=[];let Ee=0,Ne=0;const He=(Ze,et)=>{Ze!==Ne&&(Ne=Ze,Ce[Ee++]=Ze,Ce[Ee++]=et)};for(let Ze=0;Ze<ae;Ze++){const et=F.getStartCharacter(Ze),ot=F.getEndCharacter(Ze),lt=F.getMetadata(Ze),_t=((lt&1?2048:0)|(lt&2?4096:0)|(lt&4?8192:0)|(lt&8?16384:0)|(lt&16?16744448:0)|(lt&32?4278190080:0))>>>0,Ft=~_t>>>0;for(;de<J&&n.getEndOffset(de)<=et;)He(n.getEndOffset(de),n.getMetadata(de)),de++;for(de<J&&n.getStartOffset(de)<et&&He(et,n.getMetadata(de));de<J&&n.getEndOffset(de)<ot;)He(n.getEndOffset(de),n.getMetadata(de)&Ft|lt&_t),de++;if(de<J)He(ot,n.getMetadata(de)&Ft|lt&_t),n.getEndOffset(de)===ot&&de++;else{const ci=Math.min(Math.max(0,de-1),J-1);He(ot,n.getMetadata(ci)&Ft|lt&_t)}}for(;de<J;)He(n.getEndOffset(de),n.getMetadata(de)),de++;return new li.f(new Uint32Array(Ce),n.getLineContent(),this._languageIdCodec)}static _findFirstPieceWithLine(a,n){let c=0,I=a.length-1;for(;c<I;){let F=c+Math.floor((I-c)/2);if(a[F].endLineNumber<n)c=F+1;else if(a[F].startLineNumber>n)I=F-1;else{for(;F>c&&a[F-1].startLineNumber<=n&&n<=a[F-1].endLineNumber;)F--;return F}}return c}acceptEdit(a,n,c,I,F){for(const J of this._pieces)J.acceptEdit(a,n,c,I,F)}}class dn extends Kt._{constructor(a,n,c,I,F){super(),this._languageService=a,this._languageConfigurationService=n,this._textModel=c,this.bracketPairsTextModelPart=I,this._languageId=F,this._onDidChangeLanguage=this._register(new $.vl),this.onDidChangeLanguage=this._onDidChangeLanguage.event,this._onDidChangeLanguageConfiguration=this._register(new $.vl),this.onDidChangeLanguageConfiguration=this._onDidChangeLanguageConfiguration.event,this._onDidChangeTokens=this._register(new $.vl),this.onDidChangeTokens=this._onDidChangeTokens.event,this._backgroundTokenizationState=0,this._onBackgroundTokenizationStateChanged=this._register(new $.vl),this._tokens=new Sn(this._languageService.languageIdCodec),this._semanticTokens=new en(this._languageService.languageIdCodec),this._tokenization=new Qi(c,this,this._languageService.languageIdCodec),this._languageRegistryListener=this._languageConfigurationService.onDidChange(J=>{J.affects(this._languageId)&&this._onDidChangeLanguageConfiguration.fire({})})}acceptEdit(a,n,c,I,F){this._tokens.acceptEdit(a,c,I),this._semanticTokens.acceptEdit(a,c,I,F,n.length>0?n.charCodeAt(0):0)}handleDidChangeAttached(){this._tokenization.handleDidChangeAttached()}flush(){this._tokens.flush(),this._semanticTokens.flush()}handleDidChangeContent(a){this._tokenization.handleDidChangeContent(a)}dispose(){this._languageRegistryListener.dispose(),this._tokenization.dispose(),super.dispose()}get backgroundTokenizationState(){return this._backgroundTokenizationState}handleTokenizationProgress(a){if(this._backgroundTokenizationState===2)return;const n=a?2:1;this._backgroundTokenizationState!==n&&(this._backgroundTokenizationState=n,this.bracketPairsTextModelPart.handleDidChangeBackgroundTokenizationState(),this._onBackgroundTokenizationStateChanged.fire())}setTokens(a,n=!1){if(a.length!==0){const c=[];for(let I=0,F=a.length;I<F;I++){const J=a[I];let ae=0,de=0,Ce=!1;for(let Ee=J.startLineNumber;Ee<=J.endLineNumber;Ee++)Ce?(this._tokens.setTokens(this._languageId,Ee-1,this._textModel.getLineLength(Ee),J.getLineTokens(Ee),!1),de=Ee):this._tokens.setTokens(this._languageId,Ee-1,this._textModel.getLineLength(Ee),J.getLineTokens(Ee),!0)&&(Ce=!0,ae=Ee,de=Ee);Ce&&c.push({fromLineNumber:ae,toLineNumber:de})}c.length>0&&this._emitModelTokensChangedEvent({tokenizationSupportChanged:!1,semanticTokensApplied:!1,ranges:c})}this.handleTokenizationProgress(n)}setSemanticTokens(a,n){this._semanticTokens.set(a,n),this._emitModelTokensChangedEvent({tokenizationSupportChanged:!1,semanticTokensApplied:a!==null,ranges:[{fromLineNumber:1,toLineNumber:this._textModel.getLineCount()}]})}hasCompleteSemanticTokens(){return this._semanticTokens.isComplete()}hasSomeSemanticTokens(){return!this._semanticTokens.isEmpty()}setPartialSemanticTokens(a,n){if(this.hasCompleteSemanticTokens())return;const c=this._textModel.validateRange(this._semanticTokens.setPartial(a,n));this._emitModelTokensChangedEvent({tokenizationSupportChanged:!1,semanticTokensApplied:!0,ranges:[{fromLineNumber:c.startLineNumber,toLineNumber:c.endLineNumber}]})}tokenizeViewport(a,n){a=Math.max(1,a),n=Math.min(this._textModel.getLineCount(),n),this._tokenization.tokenizeViewport(a,n)}clearTokens(){this._tokens.flush(),this._emitModelTokensChangedEvent({tokenizationSupportChanged:!0,semanticTokensApplied:!1,ranges:[{fromLineNumber:1,toLineNumber:this._textModel.getLineCount()}]})}_emitModelTokensChangedEvent(a){this._textModel._isDisposing()||(this.bracketPairsTextModelPart.handleDidChangeTokens(a),this._onDidChangeTokens.fire(a))}resetTokenization(){this._tokenization.reset()}forceTokenization(a){if(a<1||a>this._textModel.getLineCount())throw new Error("Illegal value for lineNumber");this._tokenization.forceTokenization(a)}isCheapToTokenize(a){return this._tokenization.isCheapToTokenize(a)}tokenizeIfCheap(a){this.isCheapToTokenize(a)&&this.forceTokenization(a)}getLineTokens(a){if(a<1||a>this._textModel.getLineCount())throw new Error("Illegal value for lineNumber");return this._getLineTokens(a)}_getLineTokens(a){const n=this._textModel.getLineContent(a),c=this._tokens.getTokens(this._languageId,a-1,n);return this._semanticTokens.addSparseTokens(a,c)}getTokenTypeIfInsertingCharacter(a,n,c){const I=this._textModel.validatePosition(new p.y(a,n));return this._tokenization.getTokenTypeIfInsertingCharacter(I,c)}tokenizeLineWithEdit(a,n,c){const I=this._textModel.validatePosition(a);return this._tokenization.tokenizeLineWithEdit(I,n,c)}getLanguageConfiguration(a){return this._languageConfigurationService.getLanguageConfiguration(a)}getWordAtPosition(a){this.assertNotDisposed();const n=this._textModel.validatePosition(a),c=this._textModel.getLineContent(n.lineNumber),I=this._getLineTokens(n.lineNumber),F=I.findTokenIndexAtOffset(n.column-1),[J,ae]=dn._findLanguageBoundaries(I,F),de=(0,ki.Th)(n.column,this.getLanguageConfiguration(I.getLanguageId(F)).getWordDefinition(),c.substring(J,ae),J);if(de&&de.startColumn<=a.column&&a.column<=de.endColumn)return de;if(F>0&&J===n.column-1){const[Ce,Ee]=dn._findLanguageBoundaries(I,F-1),Ne=(0,ki.Th)(n.column,this.getLanguageConfiguration(I.getLanguageId(F-1)).getWordDefinition(),c.substring(Ce,Ee),Ce);if(Ne&&Ne.startColumn<=a.column&&a.column<=Ne.endColumn)return Ne}return null}static _findLanguageBoundaries(a,n){const c=a.getLanguageId(n);let I=0;for(let J=n;J>=0&&a.getLanguageId(J)===c;J--)I=a.getStartOffset(J);let F=a.getLineContent().length;for(let J=n,ae=a.getCount();J<ae&&a.getLanguageId(J)===c;J++)F=a.getEndOffset(J);return[I,F]}getWordUntilPosition(a){const n=this.getWordAtPosition(a);return n?{word:n.word.substr(0,a.column-n.startColumn),startColumn:n.startColumn,endColumn:a.column}:{word:"",startColumn:a.column,endColumn:a.column}}getLanguageId(){return this._languageId}getLanguageIdAtPosition(a,n){const c=this._textModel.validatePosition(new p.y(a,n)),I=this.getLineTokens(c.lineNumber);return I.getLanguageId(I.findTokenIndexAtOffset(c.column-1))}setLanguageId(a){if(this._languageId===a)return;const n={oldLanguage:this._languageId,newLanguage:a};this._languageId=a,this.bracketPairsTextModelPart.handleDidChangeLanguage(n),this._tokenization.handleDidChangeLanguage(n),this._onDidChangeLanguage.fire(n),this._onDidChangeLanguageConfiguration.fire({})}}var Li=y(83455),Rn=y(38803),In=function(xe,a,n,c){var I=arguments.length,F=I<3?a:c===null?c=Object.getOwnPropertyDescriptor(a,n):c,J;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")F=Reflect.decorate(xe,a,n,c);else for(var ae=xe.length-1;ae>=0;ae--)(J=xe[ae])&&(F=(I<3?J(F):I>3?J(a,n,F):J(a,n))||F);return I>3&&F&&Object.defineProperty(a,n,F),F},xn=function(xe,a){return function(n,c){a(n,c,xe)}};function Tn(xe){const a=new oi;return a.acceptChunk(xe),a.finish()}function wn(xe){const a=new oi;let n;for(;typeof(n=xe.read())=="string";)a.acceptChunk(n);return a.finish()}function Ln(xe,a){let n;return typeof xe=="string"?n=Tn(xe):w.nk(xe)?n=wn(xe):n=xe,n.create(a)}let Cn=0;const Bn=999,Mn=1e4;class Yn{constructor(a){this._source=a,this._eos=!1}read(){if(this._eos)return null;const a=[];let n=0,c=0;do{const I=this._source.read();if(I===null)return this._eos=!0,n===0?null:a.join("");if(I.length>0&&(a[n++]=I,c+=I.length),c>=64*1024)return a.join("")}while(!0)}}const Hn=()=>{throw new Error("Invalid change accessor")};let _n=class mr extends L.jG{constructor(a,n,c,I=null,F,J,ae){super(),this._undoRedoService=F,this._languageService=J,this._languageConfigurationService=ae,this._onWillDispose=this._register(new $.vl),this.onWillDispose=this._onWillDispose.event,this._onDidChangeDecorations=this._register(new Ui(He=>this.handleBeforeFireDecorationsChangedEvent(He))),this.onDidChangeDecorations=this._onDidChangeDecorations.event,this._onDidChangeOptions=this._register(new $.vl),this.onDidChangeOptions=this._onDidChangeOptions.event,this._onDidChangeAttached=this._register(new $.vl),this.onDidChangeAttached=this._onDidChangeAttached.event,this._onDidChangeInjectedText=this._register(new $.vl),this._eventEmitter=this._register(new Wi),this._deltaDecorationCallCnt=0,Cn++,this.id="$model"+Cn,this.isForSimpleWidget=c.isForSimpleWidget,typeof I>"u"||I===null?this._associatedResource=P.r.parse("inmemory://model/"+Cn):this._associatedResource=I,this._attachedEditorCount=0;const{textBuffer:de,disposable:Ce}=Ln(a,c.defaultEOL);this._buffer=de,this._bufferDisposable=Ce,this._options=mr.resolveOptions(this._buffer,c),this._bracketPairs=this._register(new G(this,this._languageConfigurationService)),this._guidesTextModelPart=this._register(new ce.P(this,this._languageConfigurationService)),this._decorationProvider=this._register(new Ke(this)),this._tokenizationTextModelPart=new dn(this._languageService,this._languageConfigurationService,this,this._bracketPairs,n);const Ee=this._buffer.getLineCount(),Ne=this._buffer.getValueLengthInRange(new d.Q(1,1,Ee,this._buffer.getLineLength(Ee)+1),0);c.largeFileOptimizations?this._isTooLargeForTokenization=Ne>mr.LARGE_FILE_SIZE_THRESHOLD||Ee>mr.LARGE_FILE_LINE_COUNT_THRESHOLD:this._isTooLargeForTokenization=!1,this._isTooLargeForSyncing=Ne>mr.MODEL_SYNC_LIMIT,this._versionId=1,this._alternativeVersionId=1,this._initialUndoRedoSnapshot=null,this._isDisposed=!1,this.__isDisposing=!1,this._instanceId=U.tk(Cn),this._lastDecorationId=0,this._decorations=Object.create(null),this._decorationsTree=new zn,this._commandManager=new Me.z8(this,this._undoRedoService),this._isUndoing=!1,this._isRedoing=!1,this._trimAutoWhitespaceLines=null,this._register(this._decorationProvider.onDidChange(()=>{this._onDidChangeDecorations.beginDeferredEmit(),this._onDidChangeDecorations.fire(),this._onDidChangeDecorations.endDeferredEmit()}))}static resolveOptions(a,n){if(n.detectIndentation){const c=ge(a,n.tabSize,n.insertSpaces);return new w.X2({tabSize:c.tabSize,indentSize:c.tabSize,insertSpaces:c.insertSpaces,trimAutoWhitespace:n.trimAutoWhitespace,defaultEOL:n.defaultEOL,bracketPairColorizationOptions:n.bracketPairColorizationOptions})}return new w.X2({tabSize:n.tabSize,indentSize:n.indentSize,insertSpaces:n.insertSpaces,trimAutoWhitespace:n.trimAutoWhitespace,defaultEOL:n.defaultEOL,bracketPairColorizationOptions:n.bracketPairColorizationOptions})}get onDidChangeLanguage(){return this._tokenizationTextModelPart.onDidChangeLanguage}get onDidChangeLanguageConfiguration(){return this._tokenizationTextModelPart.onDidChangeLanguageConfiguration}get onDidChangeTokens(){return this._tokenizationTextModelPart.onDidChangeTokens}onDidChangeContent(a){return this._eventEmitter.slowEvent(n=>a(n.contentChangedEvent))}onDidChangeContentOrInjectedText(a){return(0,L.qE)(this._eventEmitter.fastEvent(n=>a(n)),this._onDidChangeInjectedText.event(n=>a(n)))}_isDisposing(){return this.__isDisposing}get tokenization(){return this._tokenizationTextModelPart}get bracketPairs(){return this._bracketPairs}get guides(){return this._guidesTextModelPart}dispose(){this.__isDisposing=!0,this._onWillDispose.fire(),this._tokenizationTextModelPart.dispose(),this._isDisposed=!0,super.dispose(),this._bufferDisposable.dispose(),this.__isDisposing=!1;const a=new ei([],"",` `,!1,!1,!0,!0);a.dispose(),this._buffer=a,this._bufferDisposable=L.jG.None}_assertNotDisposed(){if(this._isDisposed)throw new Error("Model is disposed!")}_emitContentChangedEvent(a,n){this.__isDisposing||(this._tokenizationTextModelPart.handleDidChangeContent(n),this._bracketPairs.handleDidChangeContent(n),this._eventEmitter.fire(new Li.Ic(a,n)))}setValue(a){if(this._assertNotDisposed(),a===null)return;const{textBuffer:n,disposable:c}=Ln(a,this._options.defaultEOL);this._setValueFromTextBuffer(n,c)}_createContentChanged2(a,n,c,I,F,J,ae){return{changes:[{range:a,rangeOffset:n,rangeLength:c,text:I}],eol:this._buffer.getEOL(),versionId:this.getVersionId(),isUndoing:F,isRedoing:J,isFlush:ae}}_setValueFromTextBuffer(a,n){this._assertNotDisposed();const c=this.getFullModelRange(),I=this.getValueLengthInRange(c),F=this.getLineCount(),J=this.getLineMaxColumn(F);this._buffer=a,this._bufferDisposable.dispose(),this._bufferDisposable=n,this._increaseVersionId(),this._tokenizationTextModelPart.flush(),this._decorations=Object.create(null),this._decorationsTree=new zn,this._commandManager.clear(),this._trimAutoWhitespaceLines=null,this._emitContentChangedEvent(new Li.HP([new Li.Wn],this._versionId,!1,!1),this._createContentChanged2(new d.Q(1,1,F,J),0,I,this.getValue(),!1,!1,!0))}setEOL(a){this._assertNotDisposed();const n=a===1?`\r `:` `;if(this._buffer.getEOL()===n)return;const c=this.getFullModelRange(),I=this.getValueLengthInRange(c),F=this.getLineCount(),J=this.getLineMaxColumn(F);this._onBeforeEOLChange(),this._buffer.setEOL(n),this._increaseVersionId(),this._onAfterEOLChange(),this._emitContentChangedEvent(new Li.HP([new Li.mS],this._versionId,!1,!1),this._createContentChanged2(new d.Q(1,1,F,J),0,I,this.getValue(),!1,!1,!1))}_onBeforeEOLChange(){this._decorationsTree.ensureAllNodesHaveRanges(this)}_onAfterEOLChange(){const a=this.getVersionId(),n=this._decorationsTree.collectNodesPostOrder();for(let c=0,I=n.length;c<I;c++){const F=n[c],J=F.range,ae=F.cachedAbsoluteStart-F.start,de=this._buffer.getOffsetAt(J.startLineNumber,J.startColumn),Ce=this._buffer.getOffsetAt(J.endLineNumber,J.endColumn);F.cachedAbsoluteStart=de,F.cachedAbsoluteEnd=Ce,F.cachedVersionId=a,F.start=de-ae,F.end=Ce-ae,Et(F)}}onBeforeAttached(){this._attachedEditorCount++,this._attachedEditorCount===1&&(this._tokenizationTextModelPart.handleDidChangeAttached(),this._onDidChangeAttached.fire(void 0))}onBeforeDetached(){this._attachedEditorCount--,this._attachedEditorCount===0&&(this._tokenizationTextModelPart.handleDidChangeAttached(),this._onDidChangeAttached.fire(void 0))}isAttachedToEditor(){return this._attachedEditorCount>0}getAttachedEditorCount(){return this._attachedEditorCount}isTooLargeForSyncing(){return this._isTooLargeForSyncing}isTooLargeForTokenization(){return this._isTooLargeForTokenization}isDisposed(){return this._isDisposed}isDominatedByLongLines(){if(this._assertNotDisposed(),this.isTooLargeForTokenization())return!1;let a=0,n=0;const c=this._buffer.getLineCount();for(let I=1;I<=c;I++){const F=this._buffer.getLineLength(I);F>=Mn?n+=F:a+=F}return n>a}get uri(){return this._associatedResource}getOptions(){return this._assertNotDisposed(),this._options}getFormattingOptions(){return{tabSize:this._options.indentSize,insertSpaces:this._options.insertSpaces}}updateOptions(a){this._assertNotDisposed();const n=typeof a.tabSize<"u"?a.tabSize:this._options.tabSize,c=typeof a.indentSize<"u"?a.indentSize:this._options.indentSize,I=typeof a.insertSpaces<"u"?a.insertSpaces:this._options.insertSpaces,F=typeof a.trimAutoWhitespace<"u"?a.trimAutoWhitespace:this._options.trimAutoWhitespace,J=typeof a.bracketColorizationOptions<"u"?a.bracketColorizationOptions:this._options.bracketPairColorizationOptions,ae=new w.X2({tabSize:n,indentSize:c,insertSpaces:I,defaultEOL:this._options.defaultEOL,trimAutoWhitespace:F,bracketPairColorizationOptions:J});if(this._options.equals(ae))return;const de=this._options.createChangeEvent(ae);this._options=ae,this._bracketPairs.handleDidChangeOptions(de),this._decorationProvider.handleDidChangeOptions(de),this._onDidChangeOptions.fire(de)}detectIndentation(a,n){this._assertNotDisposed();const c=ge(this._buffer,n,a);this.updateOptions({insertSpaces:c.insertSpaces,tabSize:c.tabSize,indentSize:c.tabSize})}normalizeIndentation(a){return this._assertNotDisposed(),(0,T.P)(a,this._options.indentSize,this._options.insertSpaces)}getVersionId(){return this._assertNotDisposed(),this._versionId}mightContainRTL(){return this._buffer.mightContainRTL()}mightContainUnusualLineTerminators(){return this._buffer.mightContainUnusualLineTerminators()}removeUnusualLineTerminators(a=null){const n=this.findMatches(U._J.source,!1,!0,!1,null,!1,1073741824);this._buffer.resetMightContainUnusualLineTerminators(),this.pushEditOperations(a,n.map(c=>({range:c.range,text:null})),()=>null)}mightContainNonBasicASCII(){return this._buffer.mightContainNonBasicASCII()}getAlternativeVersionId(){return this._assertNotDisposed(),this._alternativeVersionId}getInitialUndoRedoSnapshot(){return this._assertNotDisposed(),this._initialUndoRedoSnapshot}getOffsetAt(a){this._assertNotDisposed();const n=this._validatePosition(a.lineNumber,a.column,0);return this._buffer.getOffsetAt(n.lineNumber,n.column)}getPositionAt(a){this._assertNotDisposed();const n=Math.min(this._buffer.getLength(),Math.max(0,a));return this._buffer.getPositionAt(n)}_increaseVersionId(){this._versionId=this._versionId+1,this._alternativeVersionId=this._versionId}_overwriteVersionId(a){this._versionId=a}_overwriteAlternativeVersionId(a){this._alternativeVersionId=a}_overwriteInitialUndoRedoSnapshot(a){this._initialUndoRedoSnapshot=a}getValue(a,n=!1){this._assertNotDisposed();const c=this.getFullModelRange(),I=this.getValueInRange(c,a);return n?this._buffer.getBOM()+I:I}createSnapshot(a=!1){return new Yn(this._buffer.createSnapshot(a))}getValueLength(a,n=!1){this._assertNotDisposed();const c=this.getFullModelRange(),I=this.getValueLengthInRange(c,a);return n?this._buffer.getBOM().length+I:I}getValueInRange(a,n=0){return this._assertNotDisposed(),this._buffer.getValueInRange(this.validateRange(a),n)}getValueLengthInRange(a,n=0){return this._assertNotDisposed(),this._buffer.getValueLengthInRange(this.validateRange(a),n)}getCharacterCountInRange(a,n=0){return this._assertNotDisposed(),this._buffer.getCharacterCountInRange(this.validateRange(a),n)}getLineCount(){return this._assertNotDisposed(),this._buffer.getLineCount()}getLineContent(a){if(this._assertNotDisposed(),a<1||a>this.getLineCount())throw new Error("Illegal value for lineNumber");return this._buffer.getLineContent(a)}getLineLength(a){if(this._assertNotDisposed(),a<1||a>this.getLineCount())throw new Error("Illegal value for lineNumber");return this._buffer.getLineLength(a)}getLinesContent(){return this._assertNotDisposed(),this._buffer.getLinesContent()}getEOL(){return this._assertNotDisposed(),this._buffer.getEOL()}getEndOfLineSequence(){return this._assertNotDisposed(),this._buffer.getEOL()===` `?0:1}getLineMinColumn(a){return this._assertNotDisposed(),1}getLineMaxColumn(a){if(this._assertNotDisposed(),a<1||a>this.getLineCount())throw new Error("Illegal value for lineNumber");return this._buffer.getLineLength(a)+1}getLineFirstNonWhitespaceColumn(a){if(this._assertNotDisposed(),a<1||a>this.getLineCount())throw new Error("Illegal value for lineNumber");return this._buffer.getLineFirstNonWhitespaceColumn(a)}getLineLastNonWhitespaceColumn(a){if(this._assertNotDisposed(),a<1||a>this.getLineCount())throw new Error("Illegal value for lineNumber");return this._buffer.getLineLastNonWhitespaceColumn(a)}_validateRangeRelaxedNoAllocations(a){const n=this._buffer.getLineCount(),c=a.startLineNumber,I=a.startColumn;let F=Math.floor(typeof c=="number"&&!isNaN(c)?c:1),J=Math.floor(typeof I=="number"&&!isNaN(I)?I:1);if(F<1)F=1,J=1;else if(F>n)F=n,J=this.getLineMaxColumn(F);else if(J<=1)J=1;else{const Ne=this.getLineMaxColumn(F);J>=Ne&&(J=Ne)}const ae=a.endLineNumber,de=a.endColumn;let Ce=Math.floor(typeof ae=="number"&&!isNaN(ae)?ae:1),Ee=Math.floor(typeof de=="number"&&!isNaN(de)?de:1);if(Ce<1)Ce=1,Ee=1;else if(Ce>n)Ce=n,Ee=this.getLineMaxColumn(Ce);else if(Ee<=1)Ee=1;else{const Ne=this.getLineMaxColumn(Ce);Ee>=Ne&&(Ee=Ne)}return c===F&&I===J&&ae===Ce&&de===Ee&&a instanceof d.Q&&!(a instanceof g.L)?a:new d.Q(F,J,Ce,Ee)}_isValidPosition(a,n,c){if(typeof a!="number"||typeof n!="number"||isNaN(a)||isNaN(n)||a<1||n<1||(a|0)!==a||(n|0)!==n)return!1;const I=this._buffer.getLineCount();if(a>I)return!1;if(n===1)return!0;const F=this.getLineMaxColumn(a);if(n>F)return!1;if(c===1){const J=this._buffer.getLineCharCode(a,n-2);if(U.pc(J))return!1}return!0}_validatePosition(a,n,c){const I=Math.floor(typeof a=="number"&&!isNaN(a)?a:1),F=Math.floor(typeof n=="number"&&!isNaN(n)?n:1),J=this._buffer.getLineCount();if(I<1)return new p.y(1,1);if(I>J)return new p.y(J,this.getLineMaxColumn(J));if(F<=1)return new p.y(I,1);const ae=this.getLineMaxColumn(I);if(F>=ae)return new p.y(I,ae);if(c===1){const de=this._buffer.getLineCharCode(I,F-2);if(U.pc(de))return new p.y(I,F-1)}return new p.y(I,F)}validatePosition(a){return this._assertNotDisposed(),a instanceof p.y&&this._isValidPosition(a.lineNumber,a.column,1)?a:this._validatePosition(a.lineNumber,a.column,1)}_isValidRange(a,n){const c=a.startLineNumber,I=a.startColumn,F=a.endLineNumber,J=a.endColumn;if(!this._isValidPosition(c,I,0)||!this._isValidPosition(F,J,0))return!1;if(n===1){const ae=I>1?this._buffer.getLineCharCode(c,I-2):0,de=J>1&&J<=this._buffer.getLineLength(F)?this._buffer.getLineCharCode(F,J-2):0,Ce=U.pc(ae),Ee=U.pc(de);return!Ce&&!Ee}return!0}validateRange(a){if(this._assertNotDisposed(),a instanceof d.Q&&!(a instanceof g.L)&&this._isValidRange(a,1))return a;const c=this._validatePosition(a.startLineNumber,a.startColumn,0),I=this._validatePosition(a.endLineNumber,a.endColumn,0),F=c.lineNumber,J=c.column,ae=I.lineNumber,de=I.column;{const Ce=J>1?this._buffer.getLineCharCode(F,J-2):0,Ee=de>1&&de<=this._buffer.getLineLength(ae)?this._buffer.getLineCharCode(ae,de-2):0,Ne=U.pc(Ce),He=U.pc(Ee);return!Ne&&!He?new d.Q(F,J,ae,de):F===ae&&J===de?new d.Q(F,J-1,ae,de-1):Ne&&He?new d.Q(F,J-1,ae,de+1):Ne?new d.Q(F,J-1,ae,de):new d.Q(F,J,ae,de+1)}return new d.Q(F,J,ae,de)}modifyPosition(a,n){this._assertNotDisposed();const c=this.getOffsetAt(a)+n;return this.getPositionAt(Math.min(this._buffer.getLength(),Math.max(0,c)))}getFullModelRange(){this._assertNotDisposed();const a=this.getLineCount();return new d.Q(1,1,a,this.getLineMaxColumn(a))}findMatchesLineByLine(a,n,c,I){return this._buffer.findMatchesLineByLine(a,n,c,I)}findMatches(a,n,c,I,F,J,ae=Bn){this._assertNotDisposed();let de=null;n!==null&&(Array.isArray(n)||(n=[n]),n.every(Ne=>d.Q.isIRange(Ne))&&(de=n.map(Ne=>this.validateRange(Ne)))),de===null&&(de=[this.getFullModelRange()]),de=de.sort((Ne,He)=>Ne.startLineNumber-He.startLineNumber||Ne.startColumn-He.startColumn);const Ce=[];Ce.push(de.reduce((Ne,He)=>d.Q.areIntersecting(Ne,He)?Ne.plusRange(He):(Ce.push(Ne),He)));let Ee;if(!c&&a.indexOf(` `)<0){const He=new nt.lt(a,c,I,F).parseSearchRequest();if(!He)return[];Ee=Ze=>this.findMatchesLineByLine(Ze,He,J,ae)}else Ee=Ne=>nt.hB.findMatches(this,new nt.lt(a,c,I,F),Ne,J,ae);return Ce.map(Ee).reduce((Ne,He)=>Ne.concat(He),[])}findNextMatch(a,n,c,I,F,J){this._assertNotDisposed();const ae=this.validatePosition(n);if(!c&&a.indexOf(` `)<0){const Ce=new nt.lt(a,c,I,F).parseSearchRequest();if(!Ce)return null;const Ee=this.getLineCount();let Ne=new d.Q(ae.lineNumber,ae.column,Ee,this.getLineMaxColumn(Ee)),He=this.findMatchesLineByLine(Ne,Ce,J,1);return nt.hB.findNextMatch(this,new nt.lt(a,c,I,F),ae,J),He.length>0||(Ne=new d.Q(1,1,ae.lineNumber,this.getLineMaxColumn(ae.lineNumber)),He=this.findMatchesLineByLine(Ne,Ce,J,1),He.length>0)?He[0]:null}return nt.hB.findNextMatch(this,new nt.lt(a,c,I,F),ae,J)}findPreviousMatch(a,n,c,I,F,J){this._assertNotDisposed();const ae=this.validatePosition(n);return nt.hB.findPreviousMatch(this,new nt.lt(a,c,I,F),ae,J)}pushStackElement(){this._commandManager.pushStackElement()}popStackElement(){this._commandManager.popStackElement()}pushEOL(a){if((this.getEOL()===` `?0:1)!==a)try{this._onDidChangeDecorations.beginDeferredEmit(),this._eventEmitter.beginDeferredEmit(),this._initialUndoRedoSnapshot===null&&(this._initialUndoRedoSnapshot=this._undoRedoService.createSnapshot(this.uri)),this._commandManager.pushEOL(a)}finally{this._eventEmitter.endDeferredEmit(),this._onDidChangeDecorations.endDeferredEmit()}}_validateEditOperation(a){return a instanceof w.Wo?a:new w.Wo(a.identifier||null,this.validateRange(a.range),a.text,a.forceMoveMarkers||!1,a.isAutoWhitespaceEdit||!1,a._isTracked||!1)}_validateEditOperations(a){const n=[];for(let c=0,I=a.length;c<I;c++)n[c]=this._validateEditOperation(a[c]);return n}pushEditOperations(a,n,c){try{return this._onDidChangeDecorations.beginDeferredEmit(),this._eventEmitter.beginDeferredEmit(),this._pushEditOperations(a,this._validateEditOperations(n),c)}finally{this._eventEmitter.endDeferredEmit(),this._onDidChangeDecorations.endDeferredEmit()}}_pushEditOperations(a,n,c){if(this._options.trimAutoWhitespace&&this._trimAutoWhitespaceLines){const I=n.map(J=>({range:this.validateRange(J.range),text:J.text}));let F=!0;if(a)for(let J=0,ae=a.length;J<ae;J++){const de=a[J];let Ce=!1;for(let Ee=0,Ne=I.length;Ee<Ne;Ee++){const He=I[Ee].range,Ze=He.startLineNumber>de.endLineNumber,et=de.startLineNumber>He.endLineNumber;if(!Ze&&!et){Ce=!0;break}}if(!Ce){F=!1;break}}if(F)for(let J=0,ae=this._trimAutoWhitespaceLines.length;J<ae;J++){const de=this._trimAutoWhitespaceLines[J],Ce=this.getLineMaxColumn(de);let Ee=!0;for(let Ne=0,He=I.length;Ne<He;Ne++){const Ze=I[Ne].range,et=I[Ne].text;if(!(de<Ze.startLineNumber||de>Ze.endLineNumber)&&!(de===Ze.startLineNumber&&Ze.startColumn===Ce&&Ze.isEmpty()&&et&&et.length>0&&et.charAt(0)===` `)&&!(de===Ze.startLineNumber&&Ze.startColumn===1&&Ze.isEmpty()&&et&&et.length>0&&et.charAt(et.length-1)===` `)){Ee=!1;break}}if(Ee){const Ne=new d.Q(de,1,de,Ce);n.push(new w.Wo(null,Ne,null,!1,!1,!1))}}this._trimAutoWhitespaceLines=null}return this._initialUndoRedoSnapshot===null&&(this._initialUndoRedoSnapshot=this._undoRedoService.createSnapshot(this.uri)),this._commandManager.pushEditOperation(a,n,c)}_applyUndo(a,n,c,I){const F=a.map(J=>{const ae=this.getPositionAt(J.newPosition),de=this.getPositionAt(J.newEnd);return{range:new d.Q(ae.lineNumber,ae.column,de.lineNumber,de.column),text:J.oldText}});this._applyUndoRedoEdits(F,n,!0,!1,c,I)}_applyRedo(a,n,c,I){const F=a.map(J=>{const ae=this.getPositionAt(J.oldPosition),de=this.getPositionAt(J.oldEnd);return{range:new d.Q(ae.lineNumber,ae.column,de.lineNumber,de.column),text:J.newText}});this._applyUndoRedoEdits(F,n,!1,!0,c,I)}_applyUndoRedoEdits(a,n,c,I,F,J){try{this._onDidChangeDecorations.beginDeferredEmit(),this._eventEmitter.beginDeferredEmit(),this._isUndoing=c,this._isRedoing=I,this.applyEdits(a,!1),this.setEOL(n),this._overwriteAlternativeVersionId(F)}finally{this._isUndoing=!1,this._isRedoing=!1,this._eventEmitter.endDeferredEmit(J),this._onDidChangeDecorations.endDeferredEmit()}}applyEdits(a,n=!1){try{this._onDidChangeDecorations.beginDeferredEmit(),this._eventEmitter.beginDeferredEmit();const c=this._validateEditOperations(a);return this._doApplyEdits(c,n)}finally{this._eventEmitter.endDeferredEmit(),this._onDidChangeDecorations.endDeferredEmit()}}_doApplyEdits(a,n){const c=this._buffer.getLineCount(),I=this._buffer.applyEdits(a,this._options.trimAutoWhitespace,n),F=this._buffer.getLineCount(),J=I.changes;if(this._trimAutoWhitespaceLines=I.trimAutoWhitespaceLineNumbers,J.length!==0){for(let Ce=0,Ee=J.length;Ce<Ee;Ce++){const Ne=J[Ce],[He,Ze,et]=(0,B.W)(Ne.text);this._tokenizationTextModelPart.acceptEdit(Ne.range,Ne.text,He,Ze,et),this._decorationsTree.acceptReplace(Ne.rangeOffset,Ne.rangeLength,Ne.text.length,Ne.forceMoveMarkers)}const ae=[];this._increaseVersionId();let de=c;for(let Ce=0,Ee=J.length;Ce<Ee;Ce++){const Ne=J[Ce],[He]=(0,B.W)(Ne.text);this._onDidChangeDecorations.fire();const Ze=Ne.range.startLineNumber,et=Ne.range.endLineNumber,ot=et-Ze,lt=He,_t=Math.min(ot,lt),Ft=lt-ot,ci=F-de-Ft+Ze,Oi=ci,on=ci+lt,gn=this._decorationsTree.getInjectedTextInInterval(this,this.getOffsetAt(new p.y(Oi,1)),this.getOffsetAt(new p.y(on,this.getLineMaxColumn(on))),0),hn=Li.uK.fromDecorations(gn),Yi=new b.j3(hn);for(let Ei=_t;Ei>=0;Ei--){const An=Ze+Ei,Xn=ci+Ei;Yi.takeFromEndWhile(is=>is.lineNumber>Xn);const rs=Yi.takeFromEndWhile(is=>is.lineNumber===Xn);ae.push(new Li.U0(An,this.getLineContent(Xn),rs))}if(_t<ot){const Ei=Ze+_t;ae.push(new Li.E$(Ei+1,et))}if(_t<lt){const Ei=new b.j3(hn),An=Ze+_t,Xn=lt-_t,rs=F-de-Xn+An+1,is=[],xs=[];for(let ys=0;ys<Xn;ys++){const Ss=rs+ys;xs[ys]=this.getLineContent(Ss),Ei.takeWhile(Fs=>Fs.lineNumber<Ss),is[ys]=Ei.takeWhile(Fs=>Fs.lineNumber===Ss)}ae.push(new Li.bg(An+1,Ze+lt,xs,is))}de+=Ft}this._emitContentChangedEvent(new Li.HP(ae,this.getVersionId(),this._isUndoing,this._isRedoing),{changes:J,eol:this._buffer.getEOL(),versionId:this.getVersionId(),isUndoing:this._isUndoing,isRedoing:this._isRedoing,isFlush:!1})}return I.reverseEdits===null?void 0:I.reverseEdits}undo(){return this._undoRedoService.undo(this.uri)}canUndo(){return this._undoRedoService.canUndo(this.uri)}redo(){return this._undoRedoService.redo(this.uri)}canRedo(){return this._undoRedoService.canRedo(this.uri)}handleBeforeFireDecorationsChangedEvent(a){if(a===null||a.size===0)return;const c=Array.from(a).map(I=>new Li.U0(I,this.getLineContent(I),this._getInjectedTextInLine(I)));this._onDidChangeInjectedText.fire(new Li.vn(c))}changeDecorations(a,n=0){this._assertNotDisposed();try{return this._onDidChangeDecorations.beginDeferredEmit(),this._changeDecorations(n,a)}finally{this._onDidChangeDecorations.endDeferredEmit()}}_changeDecorations(a,n){const c={addDecoration:(F,J)=>this._deltaDecorationsImpl(a,[],[{range:F,options:J}])[0],changeDecoration:(F,J)=>{this._changeDecorationImpl(F,J)},changeDecorationOptions:(F,J)=>{this._changeDecorationOptionsImpl(F,Di(J))},removeDecoration:F=>{this._deltaDecorationsImpl(a,[F],[])},deltaDecorations:(F,J)=>F.length===0&&J.length===0?[]:this._deltaDecorationsImpl(a,F,J)};let I=null;try{I=n(c)}catch(F){(0,K.dz)(F)}return c.addDecoration=Hn,c.changeDecoration=Hn,c.changeDecorationOptions=Hn,c.removeDecoration=Hn,c.deltaDecorations=Hn,I}deltaDecorations(a,n,c=0){if(this._assertNotDisposed(),a||(a=[]),a.length===0&&n.length===0)return[];try{return this._deltaDecorationCallCnt++,this._deltaDecorationCallCnt>1&&(console.warn("Invoking deltaDecorations recursively could lead to leaking decorations."),(0,K.dz)(new Error("Invoking deltaDecorations recursively could lead to leaking decorations."))),this._onDidChangeDecorations.beginDeferredEmit(),this._deltaDecorationsImpl(c,a,n)}finally{this._onDidChangeDecorations.endDeferredEmit(),this._deltaDecorationCallCnt--}}_getTrackedRange(a){return this.getDecorationRange(a)}_setTrackedRange(a,n,c){const I=a?this._decorations[a]:null;if(!I)return n?this._deltaDecorationsImpl(0,[],[{range:n,options:Qt[c]}])[0]:null;if(!n)return this._decorationsTree.delete(I),delete this._decorations[I.id],null;const F=this._validateRangeRelaxedNoAllocations(n),J=this._buffer.getOffsetAt(F.startLineNumber,F.startColumn),ae=this._buffer.getOffsetAt(F.endLineNumber,F.endColumn);return this._decorationsTree.delete(I),I.reset(this.getVersionId(),J,ae,F),I.setOptions(Qt[c]),this._decorationsTree.insert(I),I.id}removeAllDecorationsWithOwnerId(a){if(this._isDisposed)return;const n=this._decorationsTree.collectNodesFromOwner(a);for(let c=0,I=n.length;c<I;c++){const F=n[c];this._decorationsTree.delete(F),delete this._decorations[F.id]}}getDecorationOptions(a){const n=this._decorations[a];return n?n.options:null}getDecorationRange(a){const n=this._decorations[a];return n?this._decorationsTree.getNodeRange(this,n):null}getLineDecorations(a,n=0,c=!1){return a<1||a>this.getLineCount()?[]:this.getLinesDecorations(a,a,n,c)}getLinesDecorations(a,n,c=0,I=!1){const F=this.getLineCount(),J=Math.min(F,Math.max(1,a)),ae=Math.min(F,Math.max(1,n)),de=this.getLineMaxColumn(ae),Ce=new d.Q(J,1,ae,de),Ee=this._getDecorationsInRange(Ce,c,I);return(0,b.E4)(Ee,this._decorationProvider.getDecorationsInRange(Ce,c,I)),Ee}getDecorationsInRange(a,n=0,c=!1){const I=this.validateRange(a),F=this._getDecorationsInRange(I,n,c);return(0,b.E4)(F,this._decorationProvider.getDecorationsInRange(I,n,c)),F}getOverviewRulerDecorations(a=0,n=!1){return this._decorationsTree.getAll(this,a,n,!0)}getInjectedTextDecorations(a=0){return this._decorationsTree.getAllInjectedText(this,a)}_getInjectedTextInLine(a){const n=this._buffer.getOffsetAt(a,1),c=n+this._buffer.getLineLength(a),I=this._decorationsTree.getInjectedTextInInterval(this,n,c,0);return Li.uK.fromDecorations(I).filter(F=>F.lineNumber===a)}getAllDecorations(a=0,n=!1){let c=this._decorationsTree.getAll(this,a,n,!1);return c=c.concat(this._decorationProvider.getAllDecorations(a,n)),c}_getDecorationsInRange(a,n,c){const I=this._buffer.getOffsetAt(a.startLineNumber,a.startColumn),F=this._buffer.getOffsetAt(a.endLineNumber,a.endColumn);return this._decorationsTree.getAllInInterval(this,I,F,n,c)}getRangeAt(a,n){return this._buffer.getRangeAt(a,n-a)}_changeDecorationImpl(a,n){const c=this._decorations[a];if(!c)return;if(c.options.after){const ae=this.getDecorationRange(a);this._onDidChangeDecorations.recordLineAffectedByInjectedText(ae.endLineNumber)}if(c.options.before){const ae=this.getDecorationRange(a);this._onDidChangeDecorations.recordLineAffectedByInjectedText(ae.startLineNumber)}const I=this._validateRangeRelaxedNoAllocations(n),F=this._buffer.getOffsetAt(I.startLineNumber,I.startColumn),J=this._buffer.getOffsetAt(I.endLineNumber,I.endColumn);this._decorationsTree.delete(c),c.reset(this.getVersionId(),F,J,I),this._decorationsTree.insert(c),this._onDidChangeDecorations.checkAffectedAndFire(c.options),c.options.after&&this._onDidChangeDecorations.recordLineAffectedByInjectedText(I.endLineNumber),c.options.before&&this._onDidChangeDecorations.recordLineAffectedByInjectedText(I.startLineNumber)}_changeDecorationOptionsImpl(a,n){const c=this._decorations[a];if(!c)return;const I=!!(c.options.overviewRuler&&c.options.overviewRuler.color),F=!!(n.overviewRuler&&n.overviewRuler.color);if(this._onDidChangeDecorations.checkAffectedAndFire(c.options),this._onDidChangeDecorations.checkAffectedAndFire(n),c.options.after||n.after){const J=this._decorationsTree.getNodeRange(this,c);this._onDidChangeDecorations.recordLineAffectedByInjectedText(J.endLineNumber)}if(c.options.before||n.before){const J=this._decorationsTree.getNodeRange(this,c);this._onDidChangeDecorations.recordLineAffectedByInjectedText(J.startLineNumber)}I!==F?(this._decorationsTree.delete(c),c.setOptions(n),this._decorationsTree.insert(c)):c.setOptions(n)}_deltaDecorationsImpl(a,n,c){const I=this.getVersionId(),F=n.length;let J=0;const ae=c.length;let de=0;const Ce=new Array(ae);for(;J<F||de<ae;){let Ee=null;if(J<F){do Ee=this._decorations[n[J++]];while(!Ee&&J<F);if(Ee){if(Ee.options.after){const Ne=this._decorationsTree.getNodeRange(this,Ee);this._onDidChangeDecorations.recordLineAffectedByInjectedText(Ne.endLineNumber)}if(Ee.options.before){const Ne=this._decorationsTree.getNodeRange(this,Ee);this._onDidChangeDecorations.recordLineAffectedByInjectedText(Ne.startLineNumber)}this._decorationsTree.delete(Ee),this._onDidChangeDecorations.checkAffectedAndFire(Ee.options)}}if(de<ae){if(!Ee){const lt=++this._lastDecorationId,_t=`${this._instanceId};${lt}`;Ee=new tt(_t,0,0),this._decorations[_t]=Ee}const Ne=c[de],He=this._validateRangeRelaxedNoAllocations(Ne.range),Ze=Di(Ne.options),et=this._buffer.getOffsetAt(He.startLineNumber,He.startColumn),ot=this._buffer.getOffsetAt(He.endLineNumber,He.endColumn);Ee.ownerId=a,Ee.reset(I,et,ot,He),Ee.setOptions(Ze),Ee.options.after&&this._onDidChangeDecorations.recordLineAffectedByInjectedText(He.endLineNumber),Ee.options.before&&this._onDidChangeDecorations.recordLineAffectedByInjectedText(He.startLineNumber),this._onDidChangeDecorations.checkAffectedAndFire(Ze),this._decorationsTree.insert(Ee),Ce[de]=Ee.id,de++}else Ee&&delete this._decorations[Ee.id]}return Ce}getLanguageId(){return this.tokenization.getLanguageId()}setMode(a){this.tokenization.setLanguageId(a)}getLanguageIdAtPosition(a,n){return this.tokenization.getLanguageIdAtPosition(a,n)}getWordAtPosition(a){return this._tokenizationTextModelPart.getWordAtPosition(a)}getWordUntilPosition(a){return this._tokenizationTextModelPart.getWordUntilPosition(a)}normalizePosition(a,n){return a}getLineIndentColumn(a){return yn(this.getLineContent(a))+1}};_n.MODEL_SYNC_LIMIT=50*1024*1024,_n.LARGE_FILE_SIZE_THRESHOLD=20*1024*1024,_n.LARGE_FILE_LINE_COUNT_THRESHOLD=300*1e3,_n.DEFAULT_CREATION_OPTIONS={isForSimpleWidget:!1,tabSize:h.R.tabSize,indentSize:h.R.indentSize,insertSpaces:h.R.insertSpaces,detectIndentation:!1,defaultEOL:1,trimAutoWhitespace:h.R.trimAutoWhitespace,largeFileOptimizations:h.R.largeFileOptimizations,bracketPairColorizationOptions:h.R.bracketPairColorizationOptions},_n=In([xn(4,Rn.$D),xn(5,l.L),xn(6,u.JZ)],_n);function yn(xe){let a=0;for(const n of xe)if(n===" "||n===" ")a++;else break;return a}function On(xe){return!!(xe.options.overviewRuler&&xe.options.overviewRuler.color)}function sn(xe){return!!xe.options.after||!!xe.options.before}class zn{constructor(){this._decorationsTree0=new ht,this._decorationsTree1=new ht,this._injectedTextDecorationsTree=new ht}ensureAllNodesHaveRanges(a){this.getAll(a,0,!1,!1)}_ensureNodesHaveRanges(a,n){for(const c of n)c.range===null&&(c.range=a.getRangeAt(c.cachedAbsoluteStart,c.cachedAbsoluteEnd));return n}getAllInInterval(a,n,c,I,F){const J=a.getVersionId(),ae=this._intervalSearch(n,c,I,F,J);return this._ensureNodesHaveRanges(a,ae)}_intervalSearch(a,n,c,I,F){const J=this._decorationsTree0.intervalSearch(a,n,c,I,F),ae=this._decorationsTree1.intervalSearch(a,n,c,I,F),de=this._injectedTextDecorationsTree.intervalSearch(a,n,c,I,F);return J.concat(ae).concat(de)}getInjectedTextInInterval(a,n,c,I){const F=a.getVersionId(),J=this._injectedTextDecorationsTree.intervalSearch(n,c,I,!1,F);return this._ensureNodesHaveRanges(a,J).filter(ae=>ae.options.showIfCollapsed||!ae.range.isEmpty())}getAllInjectedText(a,n){const c=a.getVersionId(),I=this._injectedTextDecorationsTree.search(n,!1,c);return this._ensureNodesHaveRanges(a,I).filter(F=>F.options.showIfCollapsed||!F.range.isEmpty())}getAll(a,n,c,I){const F=a.getVersionId(),J=this._search(n,c,I,F);return this._ensureNodesHaveRanges(a,J)}_search(a,n,c,I){if(c)return this._decorationsTree1.search(a,n,I);{const F=this._decorationsTree0.search(a,n,I),J=this._decorationsTree1.search(a,n,I),ae=this._injectedTextDecorationsTree.search(a,n,I);return F.concat(J).concat(ae)}}collectNodesFromOwner(a){const n=this._decorationsTree0.collectNodesFromOwner(a),c=this._decorationsTree1.collectNodesFromOwner(a),I=this._injectedTextDecorationsTree.collectNodesFromOwner(a);return n.concat(c).concat(I)}collectNodesPostOrder(){const a=this._decorationsTree0.collectNodesPostOrder(),n=this._decorationsTree1.collectNodesPostOrder(),c=this._injectedTextDecorationsTree.collectNodesPostOrder();return a.concat(n).concat(c)}insert(a){sn(a)?this._injectedTextDecorationsTree.insert(a):On(a)?this._decorationsTree1.insert(a):this._decorationsTree0.insert(a)}delete(a){sn(a)?this._injectedTextDecorationsTree.delete(a):On(a)?this._decorationsTree1.delete(a):this._decorationsTree0.delete(a)}getNodeRange(a,n){const c=a.getVersionId();return n.cachedVersionId!==c&&this._resolveNode(n,c),n.range===null&&(n.range=a.getRangeAt(n.cachedAbsoluteStart,n.cachedAbsoluteEnd)),n.range}_resolveNode(a,n){sn(a)?this._injectedTextDecorationsTree.resolveNode(a,n):On(a)?this._decorationsTree1.resolveNode(a,n):this._decorationsTree0.resolveNode(a,n)}acceptReplace(a,n,c,I){this._decorationsTree0.acceptReplace(a,n,c,I),this._decorationsTree1.acceptReplace(a,n,c,I),this._injectedTextDecorationsTree.acceptReplace(a,n,c,I)}}function Gi(xe){return xe.replace(/[^a-z0-9\-_]/gi," ")}class $n{constructor(a){this.color=a.color||"",this.darkColor=a.darkColor||""}}class Nn extends $n{constructor(a){super(a),this._resolvedColor=null,this.position=typeof a.position=="number"?a.position:w.A5.Center}getColor(a){return this._resolvedColor||(a.type!=="light"&&this.darkColor?this._resolvedColor=this._resolveColor(this.darkColor,a):this._resolvedColor=this._resolveColor(this.color,a)),this._resolvedColor}invalidateCachedColor(){this._resolvedColor=null}_resolveColor(a,n){if(typeof a=="string")return a;const c=a?n.getColor(a.id):null;return c?c.toString():""}}class bi extends $n{constructor(a){super(a),this.position=a.position}getColor(a){return this._resolvedColor||(a.type!=="light"&&this.darkColor?this._resolvedColor=this._resolveColor(this.darkColor,a):this._resolvedColor=this._resolveColor(this.color,a)),this._resolvedColor}invalidateCachedColor(){this._resolvedColor=void 0}_resolveColor(a,n){return typeof a=="string"?o.Q1.fromHex(a):n.getColor(a.id)}}class pt{constructor(a){this.content=a.content||"",this.inlineClassName=a.inlineClassName||null,this.inlineClassNameAffectsLetterSpacing=a.inlineClassNameAffectsLetterSpacing||!1,this.attachedData=a.attachedData||null,this.cursorStops=a.cursorStops||null}static from(a){return a instanceof pt?a:new pt(a)}}class zt{constructor(a){var n,c;this.description=a.description,this.blockClassName=a.blockClassName?Gi(a.blockClassName):null,this.stickiness=a.stickiness||0,this.zIndex=a.zIndex||0,this.className=a.className?Gi(a.className):null,this.hoverMessage=a.hoverMessage||null,this.glyphMarginHoverMessage=a.glyphMarginHoverMessage||null,this.isWholeLine=a.isWholeLine||!1,this.showIfCollapsed=a.showIfCollapsed||!1,this.collapseOnReplaceEdit=a.collapseOnReplaceEdit||!1,this.overviewRuler=a.overviewRuler?new Nn(a.overviewRuler):null,this.minimap=a.minimap?new bi(a.minimap):null,this.glyphMarginClassName=a.glyphMarginClassName?Gi(a.glyphMarginClassName):null,this.linesDecorationsClassName=a.linesDecorationsClassName?Gi(a.linesDecorationsClassName):null,this.firstLineDecorationClassName=a.firstLineDecorationClassName?Gi(a.firstLineDecorationClassName):null,this.marginClassName=a.marginClassName?Gi(a.marginClassName):null,this.inlineClassName=a.inlineClassName?Gi(a.inlineClassName):null,this.inlineClassNameAffectsLetterSpacing=a.inlineClassNameAffectsLetterSpacing||!1,this.beforeContentClassName=a.beforeContentClassName?Gi(a.beforeContentClassName):null,this.afterContentClassName=a.afterContentClassName?Gi(a.afterContentClassName):null,this.after=a.after?pt.from(a.after):null,this.before=a.before?pt.from(a.before):null,this.hideInCommentTokens=(n=a.hideInCommentTokens)!==null&&n!==void 0?n:!1,this.hideInStringTokens=(c=a.hideInStringTokens)!==null&&c!==void 0?c:!1}static register(a){return new zt(a)}static createDynamic(a){return new zt(a)}}zt.EMPTY=zt.register({description:"empty"});const Qt=[zt.register({description:"tracked-range-always-grows-when-typing-at-edges",stickiness:0}),zt.register({description:"tracked-range-never-grows-when-typing-at-edges",stickiness:1}),zt.register({description:"tracked-range-grows-only-when-typing-before",stickiness:2}),zt.register({description:"tracked-range-grows-only-when-typing-after",stickiness:3})];function Di(xe){return xe instanceof zt?xe:zt.createDynamic(xe)}class Ui extends L.jG{constructor(a){super(),this.handleBeforeFire=a,this._actual=this._register(new $.vl),this.event=this._actual.event,this._affectedInjectedTextLines=null,this._deferredCnt=0,this._shouldFire=!1,this._affectsMinimap=!1,this._affectsOverviewRuler=!1}beginDeferredEmit(){this._deferredCnt++}endDeferredEmit(){var a;if(this._deferredCnt--,this._deferredCnt===0){if(this._shouldFire){this.handleBeforeFire(this._affectedInjectedTextLines);const n={affectsMinimap:this._affectsMinimap,affectsOverviewRuler:this._affectsOverviewRuler};this._shouldFire=!1,this._affectsMinimap=!1,this._affectsOverviewRuler=!1,this._actual.fire(n)}(a=this._affectedInjectedTextLines)===null||a===void 0||a.clear(),this._affectedInjectedTextLines=null}}recordLineAffectedByInjectedText(a){this._affectedInjectedTextLines||(this._affectedInjectedTextLines=new Set),this._affectedInjectedTextLines.add(a)}checkAffectedAndFire(a){this._affectsMinimap||(this._affectsMinimap=!!(a.minimap&&a.minimap.position)),this._affectsOverviewRuler||(this._affectsOverviewRuler=!!(a.overviewRuler&&a.overviewRuler.color)),this._shouldFire=!0}fire(){this._affectsMinimap=!0,this._affectsOverviewRuler=!0,this._shouldFire=!0}}class Wi extends L.jG{constructor(){super(),this._fastEmitter=this._register(new $.vl),this.fastEvent=this._fastEmitter.event,this._slowEmitter=this._register(new $.vl),this.slowEvent=this._slowEmitter.event,this._deferredCnt=0,this._deferredEvent=null}beginDeferredEmit(){this._deferredCnt++}endDeferredEmit(a=null){if(this._deferredCnt--,this._deferredCnt===0&&this._deferredEvent!==null){this._deferredEvent.rawContentChangedEvent.resultingSelection=a;const n=this._deferredEvent;this._deferredEvent=null,this._fastEmitter.fire(n),this._slowEmitter.fire(n)}}fire(a){if(this._deferredCnt>0){this._deferredEvent?this._deferredEvent=this._deferredEvent.merge(a):this._deferredEvent=a;return}this._fastEmitter.fire(a),this._slowEmitter.fire(a)}}},60756:(rt,ye,y)=>{y.d(ye,{FD:()=>K,Mg:()=>$,gV:()=>o});const b=new Array;class o{constructor(U,P){this.items=U,this.additionalItems=P}static create(U,P){if(U<=128&&P.length===0){let B=o.cache[U];return B||(B=new o(U,P),o.cache[U]=B),B}return new o(U,P)}static getEmpty(){return this.empty}add(U,P){const B=P.getKey(U);let T=B>>5;if(T===0){const d=1<<B|this.items;return d===this.items?this:o.create(d,this.additionalItems)}T--;const p=this.additionalItems.slice(0);for(;p.length<T;)p.push(0);return p[T]|=1<<(B&31),o.create(this.items,p)}merge(U){const P=this.items|U.items;if(this.additionalItems===b&&U.additionalItems===b)return P===this.items?this:P===U.items?U:o.create(P,b);const B=new Array;for(let T=0;T<Math.max(this.additionalItems.length,U.additionalItems.length);T++){const p=this.additionalItems[T]||0,d=U.additionalItems[T]||0;B.push(p|d)}return o.create(P,B)}intersects(U){if((this.items&U.items)!==0)return!0;for(let P=0;P<Math.min(this.additionalItems.length,U.additionalItems.length);P++)if((this.additionalItems[P]&U.additionalItems[P])!==0)return!0;return!1}}o.cache=new Array(129),o.empty=o.create(0,b);const K={getKey(L){return L}};class ${constructor(){this.items=new Map}getKey(U){let P=this.items.get(U);return P===void 0&&(P=this.items.size,this.items.set(U,P)),P}}},60779:(rt,ye,y)=>{y.d(ye,{N6:()=>b,TH:()=>o,pv:()=>K});var b;(function($){$[$.Disabled=0]="Disabled",$[$.EnabledForActive=1]="EnabledForActive",$[$.Enabled=2]="Enabled"})(b||(b={}));class o{constructor(L,U,P,B,T,p){if(this.visibleColumn=L,this.column=U,this.className=P,this.horizontalLine=B,this.forWrappedLinesAfterColumn=T,this.forWrappedLinesBeforeOrAtColumn=p,L!==-1==(U!==-1))throw new Error}}class K{constructor(L,U){this.top=L,this.endColumn=U}}},61710:(rt,ye,y)=>{y.d(ye,{vS:()=>v,TK:()=>C,yl:()=>m});var b=y(94327),o=y(16844),K=y(66316),$=y(41672),L=y(50442),U=y(93702);class P{constructor(Y,ne,j){this._range=Y,this._charBeforeSelection=ne,this._charAfterSelection=j}getEditOperations(Y,ne){ne.addTrackedEditOperation(new L.Q(this._range.startLineNumber,this._range.startColumn,this._range.startLineNumber,this._range.startColumn),this._charBeforeSelection),ne.addTrackedEditOperation(new L.Q(this._range.endLineNumber,this._range.endColumn,this._range.endLineNumber,this._range.endColumn),this._charAfterSelection)}computeCursorState(Y,ne){const j=ne.getInverseEditOperations(),Q=j[0].range,X=j[1].range;return new U.L(Q.endLineNumber,Q.endColumn,X.endLineNumber,X.endColumn-this._charAfterSelection.length)}}class B{constructor(Y,ne,j){this._position=Y,this._text=ne,this._charAfter=j}getEditOperations(Y,ne){ne.addTrackedEditOperation(new L.Q(this._position.lineNumber,this._position.column,this._position.lineNumber,this._position.column),this._text+this._charAfter)}computeCursorState(Y,ne){const Q=ne.getInverseEditOperations()[0].range;return new U.L(Q.endLineNumber,Q.startColumn,Q.endLineNumber,Q.endColumn-this._charAfter.length)}}var T=y(29895),p=y(82862),d=y(15365),g=y(49550),h=y(52394),l=y(19184),u=y(70645),w=y(80794);class C{static indent(Y,ne,j){if(ne===null||j===null)return[];const Q=[];for(let X=0,R=j.length;X<R;X++)Q[X]=new $.Y(j[X],{isUnshift:!1,tabSize:Y.tabSize,indentSize:Y.indentSize,insertSpaces:Y.insertSpaces,useTabStops:Y.useTabStops,autoIndent:Y.autoIndent},Y.languageConfigurationService);return Q}static outdent(Y,ne,j){const Q=[];for(let X=0,R=j.length;X<R;X++)Q[X]=new $.Y(j[X],{isUnshift:!0,tabSize:Y.tabSize,indentSize:Y.indentSize,insertSpaces:Y.insertSpaces,useTabStops:Y.useTabStops,autoIndent:Y.autoIndent},Y.languageConfigurationService);return Q}static shiftIndent(Y,ne,j){return j=j||1,$.Y.shiftIndent(ne,ne.length+j,Y.tabSize,Y.indentSize,Y.insertSpaces)}static unshiftIndent(Y,ne,j){return j=j||1,$.Y.unshiftIndent(ne,ne.length+j,Y.tabSize,Y.indentSize,Y.insertSpaces)}static _distributedPaste(Y,ne,j,Q){const X=[];for(let R=0,H=j.length;R<H;R++)X[R]=new K.iu(j[R],Q[R]);return new T.vY(0,X,{shouldPushStackElementBefore:!0,shouldPushStackElementAfter:!0})}static _simplePaste(Y,ne,j,Q,X){const R=[];for(let H=0,Z=j.length;H<Z;H++){const N=j[H],G=N.getPosition();if(X&&!N.isEmpty()&&(X=!1),X&&Q.indexOf(` `)!==Q.length-1&&(X=!1),X){const O=new L.Q(G.lineNumber,1,G.lineNumber,1);R[H]=new K.ui(O,Q,N,!0)}else R[H]=new K.iu(N,Q)}return new T.vY(0,R,{shouldPushStackElementBefore:!0,shouldPushStackElementAfter:!0})}static _distributePasteToCursors(Y,ne,j,Q,X){if(Q||ne.length===1)return null;if(X&&X.length===ne.length)return X;if(Y.multiCursorPaste==="spread"){j.charCodeAt(j.length-1)===10&&(j=j.substr(0,j.length-1)),j.charCodeAt(j.length-1)===13&&(j=j.substr(0,j.length-1));const R=o.uz(j);if(R.length===ne.length)return R}return null}static paste(Y,ne,j,Q,X,R){const H=this._distributePasteToCursors(Y,j,Q,X,R);return H?(j=j.sort(L.Q.compareRangesUsingStarts),this._distributedPaste(Y,ne,j,H)):this._simplePaste(Y,ne,j,Q,X)}static _goodIndentForLine(Y,ne,j){let Q=null,X="";const R=(0,u.vn)(Y.autoIndent,ne,j,!1,Y.languageConfigurationService);if(R)Q=R.action,X=R.indentation;else if(j>1){let H;for(H=j-1;H>=1;H--){const G=ne.getLineContent(H);if(o.lT(G)>=0)break}if(H<1)return null;const Z=ne.getLineMaxColumn(H),N=(0,w.h)(Y.autoIndent,ne,new L.Q(H,Z,H,Z),Y.languageConfigurationService);N&&(X=N.indentation+N.appendText)}return Q&&(Q===g.l.Indent&&(X=C.shiftIndent(Y,X)),Q===g.l.Outdent&&(X=C.unshiftIndent(Y,X)),X=Y.normalizeIndentation(X)),X||null}static _replaceJumpToNextIndent(Y,ne,j,Q){let X="";const R=j.getStartPosition();if(Y.insertSpaces){const H=Y.visibleColumnFromColumn(ne,R),Z=Y.indentSize,N=Z-H%Z;for(let G=0;G<N;G++)X+=" "}else X=" ";return new K.iu(j,X,Q)}static tab(Y,ne,j){const Q=[];for(let X=0,R=j.length;X<R;X++){const H=j[X];if(H.isEmpty()){const Z=ne.getLineContent(H.startLineNumber);if(/^\s*$/.test(Z)&&ne.tokenization.isCheapToTokenize(H.startLineNumber)){let N=this._goodIndentForLine(Y,ne,H.startLineNumber);N=N||" ";const G=Y.normalizeIndentation(N);if(!Z.startsWith(G)){Q[X]=new K.iu(new L.Q(H.startLineNumber,1,H.startLineNumber,Z.length+1),G,!0);continue}}Q[X]=this._replaceJumpToNextIndent(Y,ne,H,!0)}else{if(H.startLineNumber===H.endLineNumber){const Z=ne.getLineMaxColumn(H.startLineNumber);if(H.startColumn!==1||H.endColumn!==Z){Q[X]=this._replaceJumpToNextIndent(Y,ne,H,!1);continue}}Q[X]=new $.Y(H,{isUnshift:!1,tabSize:Y.tabSize,indentSize:Y.indentSize,insertSpaces:Y.insertSpaces,useTabStops:Y.useTabStops,autoIndent:Y.autoIndent},Y.languageConfigurationService)}}return Q}static compositionType(Y,ne,j,Q,X,R,H,Z){const N=Q.map(G=>this._compositionType(j,G,X,R,H,Z));return new T.vY(4,N,{shouldPushStackElementBefore:D(Y,4),shouldPushStackElementAfter:!1})}static _compositionType(Y,ne,j,Q,X,R){if(!ne.isEmpty())return null;const H=ne.getPosition(),Z=Math.max(1,H.column-Q),N=Math.min(Y.getLineMaxColumn(H.lineNumber),H.column+X),G=new L.Q(H.lineNumber,Z,H.lineNumber,N);return Y.getValueInRange(G)===j&&R===0?null:new K.iP(G,j,0,R)}static _typeCommand(Y,ne,j){return j?new K.q2(Y,ne,!0):new K.iu(Y,ne,!0)}static _enter(Y,ne,j,Q){if(Y.autoIndent===0)return C._typeCommand(Q,` `,j);if(!ne.tokenization.isCheapToTokenize(Q.getStartPosition().lineNumber)||Y.autoIndent===1){const Z=ne.getLineContent(Q.startLineNumber),N=o.UU(Z).substring(0,Q.startColumn-1);return C._typeCommand(Q,` `+Y.normalizeIndentation(N),j)}const X=(0,w.h)(Y.autoIndent,ne,Q,Y.languageConfigurationService);if(X){if(X.indentAction===g.l.None)return C._typeCommand(Q,` `+Y.normalizeIndentation(X.indentation+X.appendText),j);if(X.indentAction===g.l.Indent)return C._typeCommand(Q,` `+Y.normalizeIndentation(X.indentation+X.appendText),j);if(X.indentAction===g.l.IndentOutdent){const Z=Y.normalizeIndentation(X.indentation),N=Y.normalizeIndentation(X.indentation+X.appendText),G=` `+N+` `+Z;return j?new K.q2(Q,G,!0):new K.iP(Q,G,-1,N.length-Z.length,!0)}else if(X.indentAction===g.l.Outdent){const Z=C.unshiftIndent(Y,X.indentation);return C._typeCommand(Q,` `+Y.normalizeIndentation(Z+X.appendText),j)}}const R=ne.getLineContent(Q.startLineNumber),H=o.UU(R).substring(0,Q.startColumn-1);if(Y.autoIndent>=4){const Z=(0,u.MU)(Y.autoIndent,ne,Q,{unshiftIndent:N=>C.unshiftIndent(Y,N),shiftIndent:N=>C.shiftIndent(Y,N),normalizeIndentation:N=>Y.normalizeIndentation(N)},Y.languageConfigurationService);if(Z){let N=Y.visibleColumnFromColumn(ne,Q.getEndPosition());const G=Q.endColumn,O=ne.getLineContent(Q.endLineNumber),te=o.HG(O);if(te>=0?Q=Q.setEndPosition(Q.endLineNumber,Math.max(Q.endColumn,te+1)):Q=Q.setEndPosition(Q.endLineNumber,ne.getLineMaxColumn(Q.endLineNumber)),j)return new K.q2(Q,` `+Y.normalizeIndentation(Z.afterEnter),!0);{let oe=0;return G<=te+1&&(Y.insertSpaces||(N=Math.ceil(N/Y.indentSize)),oe=Math.min(N+1-Y.normalizeIndentation(Z.afterEnter).length-1,0)),new K.iP(Q,` `+Y.normalizeIndentation(Z.afterEnter),0,oe,!0)}}}return C._typeCommand(Q,` `+Y.normalizeIndentation(H),j)}static _isAutoIndentType(Y,ne,j){if(Y.autoIndent<4)return!1;for(let Q=0,X=j.length;Q<X;Q++)if(!ne.tokenization.isCheapToTokenize(j[Q].getEndPosition().lineNumber))return!1;return!0}static _runAutoIndentType(Y,ne,j,Q){const X=(0,h.Cw)(ne,j.startLineNumber,j.startColumn),R=(0,u._t)(Y.autoIndent,ne,j,Q,{shiftIndent:H=>C.shiftIndent(Y,H),unshiftIndent:H=>C.unshiftIndent(Y,H)},Y.languageConfigurationService);if(R===null)return null;if(R!==Y.normalizeIndentation(X)){const H=ne.getLineFirstNonWhitespaceColumn(j.startLineNumber);return H===0?C._typeCommand(new L.Q(j.startLineNumber,1,j.endLineNumber,j.endColumn),Y.normalizeIndentation(R)+Q,!1):C._typeCommand(new L.Q(j.startLineNumber,1,j.endLineNumber,j.endColumn),Y.normalizeIndentation(R)+ne.getLineContent(j.startLineNumber).substring(H-1,j.startColumn-1)+Q,!1)}return null}static _isAutoClosingOvertype(Y,ne,j,Q,X){if(Y.autoClosingOvertype==="never"||!Y.autoClosingPairs.autoClosingPairsCloseSingleChar.has(X))return!1;for(let R=0,H=j.length;R<H;R++){const Z=j[R];if(!Z.isEmpty())return!1;const N=Z.getPosition(),G=ne.getLineContent(N.lineNumber);if(G.charAt(N.column-1)!==X)return!1;const te=(0,T.vG)(X);if((N.column>2?G.charCodeAt(N.column-2):0)===92&&te)return!1;if(Y.autoClosingOvertype==="auto"){let ue=!1;for(let E=0,Qe=Q.length;E<Qe;E++){const Ke=Q[E];if(N.lineNumber===Ke.startLineNumber&&N.column===Ke.startColumn){ue=!0;break}}if(!ue)return!1}}return!0}static _runAutoClosingOvertype(Y,ne,j,Q,X){const R=[];for(let H=0,Z=Q.length;H<Z;H++){const G=Q[H].getPosition(),O=new L.Q(G.lineNumber,G.column,G.lineNumber,G.column+1);R[H]=new K.iu(O,X)}return new T.vY(4,R,{shouldPushStackElementBefore:D(Y,4),shouldPushStackElementAfter:!1})}static _isBeforeClosingBrace(Y,ne){const j=ne.charAt(0),Q=Y.autoClosingPairs.autoClosingPairsOpenByStart.get(j)||[],X=Y.autoClosingPairs.autoClosingPairsCloseByStart.get(j)||[],R=Q.some(Z=>ne.startsWith(Z.open)),H=X.some(Z=>ne.startsWith(Z.close));return!R&&H}static _findAutoClosingPairOpen(Y,ne,j,Q){const X=Y.autoClosingPairs.autoClosingPairsOpenByEnd.get(Q);if(!X)return null;let R=null;for(const H of X)if(R===null||H.open.length>R.open.length){let Z=!0;for(const N of j)if(ne.getValueInRange(new L.Q(N.lineNumber,N.column-H.open.length+1,N.lineNumber,N.column))+Q!==H.open){Z=!1;break}Z&&(R=H)}return R}static _findContainedAutoClosingPair(Y,ne){if(ne.open.length<=1)return null;const j=ne.close.charAt(ne.close.length-1),Q=Y.autoClosingPairs.autoClosingPairsCloseByEnd.get(j)||[];let X=null;for(const R of Q)R.open!==ne.open&&ne.open.includes(R.open)&&ne.close.endsWith(R.close)&&(!X||R.open.length>X.open.length)&&(X=R);return X}static _getAutoClosingPairClose(Y,ne,j,Q,X){const R=(0,T.vG)(Q),H=R?Y.autoClosingQuotes:Y.autoClosingBrackets,Z=R?Y.shouldAutoCloseBefore.quote:Y.shouldAutoCloseBefore.bracket;if(H==="never")return null;for(const ue of j)if(!ue.isEmpty())return null;const N=j.map(ue=>{const E=ue.getPosition();return X?{lineNumber:E.lineNumber,beforeColumn:E.column-Q.length,afterColumn:E.column}:{lineNumber:E.lineNumber,beforeColumn:E.column,afterColumn:E.column}}),G=this._findAutoClosingPairOpen(Y,ne,N.map(ue=>new d.y(ue.lineNumber,ue.beforeColumn)),Q);if(!G)return null;const O=this._findContainedAutoClosingPair(Y,G),te=O?O.close:"";let oe=!0;for(const ue of N){const{lineNumber:E,beforeColumn:Qe,afterColumn:Ke}=ue,Se=ne.getLineContent(E),Me=Se.substring(0,Qe-1),ce=Se.substring(Ke-1);if(ce.startsWith(te)||(oe=!1),ce.length>0){const ke=ce.charAt(0);if(!C._isBeforeClosingBrace(Y,ce)&&!Z(ke))return null}if(G.open.length===1&&(Q==="'"||Q==='"')&&H!=="always"){const ke=(0,p.i)(Y.wordSeparators);if(Me.length>0){const We=Me.charCodeAt(Me.length-1);if(ke.get(We)===0)return null}}if(!ne.tokenization.isCheapToTokenize(E))return null;ne.tokenization.forceTokenization(E);const pe=ne.tokenization.getLineTokens(E),be=(0,l.BQ)(pe,Qe-1);if(!G.shouldAutoClose(be,Qe-be.firstCharOffset))return null;const ge=G.findNeutralCharacter();if(ge){const ke=ne.tokenization.getTokenTypeIfInsertingCharacter(E,Qe,ge);if(!G.isOK(ke))return null}}return oe?G.close.substring(0,G.close.length-te.length):G.close}static _runAutoClosingOpenCharType(Y,ne,j,Q,X,R,H){const Z=[];for(let N=0,G=Q.length;N<G;N++){const O=Q[N];Z[N]=new m(O,X,!R,H)}return new T.vY(4,Z,{shouldPushStackElementBefore:!0,shouldPushStackElementAfter:!1})}static _shouldSurroundChar(Y,ne){return(0,T.vG)(ne)?Y.autoSurround==="quotes"||Y.autoSurround==="languageDefined":Y.autoSurround==="brackets"||Y.autoSurround==="languageDefined"}static _isSurroundSelectionType(Y,ne,j,Q){if(!C._shouldSurroundChar(Y,Q)||!Y.surroundingPairs.hasOwnProperty(Q))return!1;const X=(0,T.vG)(Q);for(const R of j){if(R.isEmpty())return!1;let H=!0;for(let Z=R.startLineNumber;Z<=R.endLineNumber;Z++){const N=ne.getLineContent(Z),G=Z===R.startLineNumber?R.startColumn-1:0,O=Z===R.endLineNumber?R.endColumn-1:N.length,te=N.substring(G,O);if(/[^ \t]/.test(te)){H=!1;break}}if(H)return!1;if(X&&R.startLineNumber===R.endLineNumber&&R.startColumn+1===R.endColumn){const Z=ne.getValueInRange(R);if((0,T.vG)(Z))return!1}}return!0}static _runSurroundSelectionType(Y,ne,j,Q,X){const R=[];for(let H=0,Z=Q.length;H<Z;H++){const N=Q[H],G=ne.surroundingPairs[X];R[H]=new P(N,X,G)}return new T.vY(0,R,{shouldPushStackElementBefore:!0,shouldPushStackElementAfter:!0})}static _isTypeInterceptorElectricChar(Y,ne,j){return!!(j.length===1&&ne.tokenization.isCheapToTokenize(j[0].getEndPosition().lineNumber))}static _typeInterceptorElectricChar(Y,ne,j,Q,X){if(!ne.electricChars.hasOwnProperty(X)||!Q.isEmpty())return null;const R=Q.getPosition();j.tokenization.forceTokenization(R.lineNumber);const H=j.tokenization.getLineTokens(R.lineNumber);let Z;try{Z=ne.onElectricCharacter(X,H,R.column)}catch(N){return(0,b.dz)(N),null}if(!Z)return null;if(Z.matchOpenBracket){const N=(H.getLineContent()+X).lastIndexOf(Z.matchOpenBracket)+1,G=j.bracketPairs.findMatchingBracketUp(Z.matchOpenBracket,{lineNumber:R.lineNumber,column:N},500);if(G){if(G.startLineNumber===R.lineNumber)return null;const O=j.getLineContent(G.startLineNumber),te=o.UU(O),oe=ne.normalizeIndentation(te),ue=j.getLineContent(R.lineNumber),E=j.getLineFirstNonWhitespaceColumn(R.lineNumber)||R.column,Qe=ue.substring(E-1,R.column-1),Ke=oe+Qe+X,Se=new L.Q(R.lineNumber,1,R.lineNumber,R.column),Me=new K.iu(Se,Ke);return new T.vY(k(Ke,Y),[Me],{shouldPushStackElementBefore:!1,shouldPushStackElementAfter:!0})}}return null}static compositionEndWithInterceptors(Y,ne,j,Q,X,R){if(!Q)return null;let H=null;for(const O of Q)if(H===null)H=O.insertedText;else if(H!==O.insertedText)return null;if(!H||H.length!==1)return null;const Z=H;let N=!1;for(const O of Q)if(O.deletedText.length!==0){N=!0;break}if(N){if(!C._shouldSurroundChar(ne,Z)||!ne.surroundingPairs.hasOwnProperty(Z))return null;const O=(0,T.vG)(Z);for(const ue of Q)if(ue.deletedSelectionStart!==0||ue.deletedSelectionEnd!==ue.deletedText.length||/^[ \t]+$/.test(ue.deletedText)||O&&(0,T.vG)(ue.deletedText))return null;const te=[];for(const ue of X){if(!ue.isEmpty())return null;te.push(ue.getPosition())}if(te.length!==Q.length)return null;const oe=[];for(let ue=0,E=te.length;ue<E;ue++)oe.push(new B(te[ue],Q[ue].deletedText,Z));return new T.vY(4,oe,{shouldPushStackElementBefore:!0,shouldPushStackElementAfter:!1})}if(this._isAutoClosingOvertype(ne,j,X,R,Z)){const O=X.map(te=>new K.iu(new L.Q(te.positionLineNumber,te.positionColumn,te.positionLineNumber,te.positionColumn+1),"",!1));return new T.vY(4,O,{shouldPushStackElementBefore:!0,shouldPushStackElementAfter:!1})}const G=this._getAutoClosingPairClose(ne,j,X,Z,!0);return G!==null?this._runAutoClosingOpenCharType(Y,ne,j,X,Z,!0,G):null}static typeWithInterceptors(Y,ne,j,Q,X,R,H){if(!Y&&H===` `){const G=[];for(let O=0,te=X.length;O<te;O++)G[O]=C._enter(j,Q,!1,X[O]);return new T.vY(4,G,{shouldPushStackElementBefore:!0,shouldPushStackElementAfter:!1})}if(!Y&&this._isAutoIndentType(j,Q,X)){const G=[];let O=!1;for(let te=0,oe=X.length;te<oe;te++)if(G[te]=this._runAutoIndentType(j,Q,X[te],H),!G[te]){O=!0;break}if(!O)return new T.vY(4,G,{shouldPushStackElementBefore:!0,shouldPushStackElementAfter:!1})}if(this._isAutoClosingOvertype(j,Q,X,R,H))return this._runAutoClosingOvertype(ne,j,Q,X,H);if(!Y){const G=this._getAutoClosingPairClose(j,Q,X,H,!1);if(G)return this._runAutoClosingOpenCharType(ne,j,Q,X,H,!1,G)}if(!Y&&this._isSurroundSelectionType(j,Q,X,H))return this._runSurroundSelectionType(ne,j,Q,X,H);if(!Y&&this._isTypeInterceptorElectricChar(j,Q,X)){const G=this._typeInterceptorElectricChar(ne,j,Q,X[0],H);if(G)return G}const Z=[];for(let G=0,O=X.length;G<O;G++)Z[G]=new K.iu(X[G],H);const N=k(H,ne);return new T.vY(N,Z,{shouldPushStackElementBefore:D(ne,N),shouldPushStackElementAfter:!1})}static typeWithoutInterceptors(Y,ne,j,Q,X){const R=[];for(let Z=0,N=Q.length;Z<N;Z++)R[Z]=new K.iu(Q[Z],X);const H=k(X,Y);return new T.vY(H,R,{shouldPushStackElementBefore:D(Y,H),shouldPushStackElementAfter:!1})}static lineInsertBefore(Y,ne,j){if(ne===null||j===null)return[];const Q=[];for(let X=0,R=j.length;X<R;X++){let H=j[X].positionLineNumber;if(H===1)Q[X]=new K.q2(new L.Q(1,1,1,1),` `);else{H--;const Z=ne.getLineMaxColumn(H);Q[X]=this._enter(Y,ne,!1,new L.Q(H,Z,H,Z))}}return Q}static lineInsertAfter(Y,ne,j){if(ne===null||j===null)return[];const Q=[];for(let X=0,R=j.length;X<R;X++){const H=j[X].positionLineNumber,Z=ne.getLineMaxColumn(H);Q[X]=this._enter(Y,ne,!1,new L.Q(H,Z,H,Z))}return Q}static lineBreakInsert(Y,ne,j){const Q=[];for(let X=0,R=j.length;X<R;X++)Q[X]=this._enter(Y,ne,!0,j[X]);return Q}}class m extends K.iP{constructor(Y,ne,j,Q){super(Y,(j?ne:"")+Q,0,-Q.length),this._openCharacter=ne,this._closeCharacter=Q,this.closeCharacterRange=null,this.enclosingRange=null}computeCursorState(Y,ne){const Q=ne.getInverseEditOperations()[0].range;return this.closeCharacterRange=new L.Q(Q.startLineNumber,Q.endColumn-this._closeCharacter.length,Q.endLineNumber,Q.endColumn),this.enclosingRange=new L.Q(Q.startLineNumber,Q.endColumn-this._openCharacter.length-this._closeCharacter.length,Q.endLineNumber,Q.endColumn),super.computeCursorState(Y,ne)}}class v{constructor(Y,ne,j,Q,X,R){this.deletedText=Y,this.deletedSelectionStart=ne,this.deletedSelectionEnd=j,this.insertedText=Q,this.insertedSelectionStart=X,this.insertedSelectionEnd=R}}function k(W,Y){return W===" "?Y===5||Y===6?6:5:4}function D(W,Y){return A(W)&&!A(Y)?!0:W===5?!1:x(W)!==x(Y)}function x(W){return W===6||W===5?"space":W}function A(W){return W===4||W===5||W===6}},62105:(rt,ye,y)=>{y.d(ye,{$t:()=>l,gI:()=>u,ER:()=>w});var b=y(16844),o=y(50442),K=y(78903),$=y(10998),L=y(50946),U=y(96655),P=y(85525),B=y(82399),T=y(66726),p=y(3765);const d=(0,B.u1)("IEditorCancelService"),g=new U.N1("cancellableOperation",!1,(0,p.kg)("cancellableOperation","Whether the editor runs a cancellable operation, e.g. like 'Peek References'"));(0,T.v)(d,class{constructor(){this._tokens=new WeakMap}add(C,m){let v=this._tokens.get(C);v||(v=C.invokeWithinContext(D=>{const x=g.bindTo(D.get(U.fN)),A=new P.w;return{key:x,tokens:A}}),this._tokens.set(C,v));let k;return v.key.set(!0),k=v.tokens.push(m),()=>{k&&(k(),v.key.set(!v.tokens.isEmpty()),k=void 0)}}cancel(C){const m=this._tokens.get(C);if(!m)return;const v=m.tokens.pop();v&&(v.cancel(),m.key.set(!m.tokens.isEmpty()))}},!0);class h extends K.Q{constructor(m,v){super(v),this.editor=m,this._unregister=m.invokeWithinContext(k=>k.get(d).add(m,this))}dispose(){this._unregister(),super.dispose()}}(0,L.E_)(new class extends L.DX{constructor(){super({id:"editor.cancelOperation",kbOpts:{weight:100,primary:9},precondition:g})}runEditorCommand(C,m){C.get(d).cancel(m)}});class l{constructor(m,v){if(this.flags=v,(this.flags&1)!==0){const k=m.getModel();this.modelVersionId=k?b.GP("{0}#{1}",k.uri.toString(),k.getVersionId()):null}else this.modelVersionId=null;(this.flags&4)!==0?this.position=m.getPosition():this.position=null,(this.flags&2)!==0?this.selection=m.getSelection():this.selection=null,(this.flags&8)!==0?(this.scrollLeft=m.getScrollLeft(),this.scrollTop=m.getScrollTop()):(this.scrollLeft=-1,this.scrollTop=-1)}_equals(m){if(!(m instanceof l))return!1;const v=m;return!(this.modelVersionId!==v.modelVersionId||this.scrollLeft!==v.scrollLeft||this.scrollTop!==v.scrollTop||!this.position&&v.position||this.position&&!v.position||this.position&&v.position&&!this.position.equals(v.position)||!this.selection&&v.selection||this.selection&&!v.selection||this.selection&&v.selection&&!this.selection.equalsRange(v.selection))}validate(m){return this._equals(new l(m,this.flags))}}class u extends h{constructor(m,v,k,D){super(m,D),this._listener=new $.Cm,v&4&&this._listener.add(m.onDidChangeCursorPosition(x=>{(!k||!o.Q.containsPosition(k,x.position))&&this.cancel()})),v&2&&this._listener.add(m.onDidChangeCursorSelection(x=>{(!k||!o.Q.containsRange(k,x.selection))&&this.cancel()})),v&8&&this._listener.add(m.onDidScrollChange(x=>this.cancel())),v&1&&(this._listener.add(m.onDidChangeModel(x=>this.cancel())),this._listener.add(m.onDidChangeModelContent(x=>this.cancel())))}dispose(){this._listener.dispose(),super.dispose()}}class w extends K.Q{constructor(m,v){super(v),this._listener=m.onDidChangeContent(()=>this.cancel())}dispose(){this._listener.dispose(),super.dispose()}}},62549:(rt,ye,y)=>{y.d(ye,{A:()=>o});var b=y(16844);class o{static _nextVisibleColumn($,L,U){return $===9?o.nextRenderTabStop(L,U):b.ne($)||b.Ss($)?L+2:L+1}static visibleColumnFromColumn($,L,U){const P=Math.min(L-1,$.length),B=$.substring(0,P),T=new b.km(B);let p=0;for(;!T.eol();){const d=b.Z5(B,P,T.offset);T.nextGraphemeLength(),p=this._nextVisibleColumn(d,p,U)}return p}static columnFromVisibleColumn($,L,U){if(L<=0)return 1;const P=$.length,B=new b.km($);let T=0,p=1;for(;!B.eol();){const d=b.Z5($,P,B.offset);B.nextGraphemeLength();const g=this._nextVisibleColumn(d,T,U),h=B.offset+1;if(g>=L){const l=L-T;return g-L<l?h:p}T=g,p=h}return P+1}static nextRenderTabStop($,L){return $+L-$%L}static nextIndentTabStop($,L){return $+L-$%L}static prevRenderTabStop($,L){return Math.max(0,$-1-($-1)%L)}static prevIndentTabStop($,L){return Math.max(0,$-1-($-1)%L)}}},62992:(rt,ye,y)=>{y.d(ye,{Uq:()=>o,mu:()=>K,qE:()=>b});function b($,L,U){return Math.min(Math.max($,L),U)}class o{constructor(){this._n=1,this._val=0}update(L){return this._val=this._val+(L-this._val)/this._n,this._n+=1,this._val}get value(){return this._val}}class K{constructor(L){this._n=0,this._val=0,this._values=[],this._index=0,this._sum=0,this._values=new Array(L),this._values.fill(0,0,L)}update(L){const U=this._values[this._index];return this._values[this._index]=L,this._index=(this._index+1)%this._values.length,this._sum-=U,this._sum+=L,this._n<this._values.length&&(this._n+=1),this._val=this._sum/this._n,this._val}get value(){return this._val}}},63339:(rt,ye,y)=>{y.d(ye,{BH:()=>R,H8:()=>oe,HZ:()=>ne,OS:()=>N,UP:()=>Qe,_p:()=>Z,cm:()=>te,gm:()=>ue,ib:()=>Y,j9:()=>W,nr:()=>E,p7:()=>j,uF:()=>x,un:()=>Q,zQ:()=>C,zx:()=>A});var b=y(3765),o;const K="en";let $=!1,L=!1,U=!1,P=!1,B=!1,T=!1,p=!1,d=!1,g=!1,h,l=K,u=null,w;const C=typeof self=="object"?self:typeof y.g=="object"?y.g:{};let m;typeof C.vscode<"u"&&typeof C.vscode.process<"u"?m=C.vscode.process:typeof process<"u"&&(m=process);const v=typeof((o=m?.versions)===null||o===void 0?void 0:o.electron)=="string",k=v&&m?.type==="renderer";if(typeof navigator=="object"&&!k)w=navigator.userAgent,$=w.indexOf("Windows")>=0,L=w.indexOf("Macintosh")>=0,d=(w.indexOf("Macintosh")>=0||w.indexOf("iPad")>=0||w.indexOf("iPhone")>=0)&&!!navigator.maxTouchPoints&&navigator.maxTouchPoints>0,U=w.indexOf("Linux")>=0,T=!0,h=b.AM(b.kg({key:"ensureLoaderPluginIsLoaded",comment:["{Locked}"]},"_"))||K,l=h;else if(typeof m=="object"){$=m.platform==="win32",L=m.platform==="darwin",U=m.platform==="linux",P=U&&!!m.env.SNAP&&!!m.env.SNAP_REVISION,p=v,g=!!m.env.CI||!!m.env.BUILD_ARTIFACTSTAGINGDIRECTORY,h=K,l=K;const Se=m.env.VSCODE_NLS_CONFIG;if(Se)try{const Me=JSON.parse(Se),ce=Me.availableLanguages["*"];h=Me.locale,l=ce||K,u=Me._translationsConfigFile}catch{}B=!0}else console.error("Unable to resolve platform.");let D=0;L?D=1:$?D=3:U&&(D=2);const x=$,A=L,W=U,Y=B,ne=T,j=T&&typeof C.importScripts=="function",Q=d,X=w,R=l,H=typeof C.postMessage=="function"&&!C.importScripts,Z=(()=>{if(H){const Se=[];C.addEventListener("message",ce=>{if(ce.data&&ce.data.vscodeScheduleAsyncWork)for(let pe=0,be=Se.length;pe<be;pe++){const ge=Se[pe];if(ge.id===ce.data.vscodeScheduleAsyncWork){Se.splice(pe,1),ge.callback();return}}});let Me=0;return ce=>{const pe=++Me;Se.push({id:pe,callback:ce}),C.postMessage({vscodeScheduleAsyncWork:pe},"*")}}return Se=>setTimeout(Se)})(),N=L||d?2:$?1:3;let G=!0,O=!1;function te(){if(!O){O=!0;const Se=new Uint8Array(2);Se[0]=1,Se[1]=2,G=new Uint16Array(Se.buffer)[0]===513}return G}const oe=!!(X&&X.indexOf("Chrome")>=0),ue=!!(X&&X.indexOf("Firefox")>=0),E=!!(!oe&&X&&X.indexOf("Safari")>=0),Qe=!!(X&&X.indexOf("Edg/")>=0),Ke=!!(X&&X.indexOf("Android")>=0)},63781:(rt,ye,y)=>{y.d(ye,{MU:()=>R,Se:()=>Q,oO:()=>X});var b=y(55893),o=y(14333),K=y(5043),$=y(9715),L=y(10176),U=y(45222),P=y(65958);const B=11;class T extends U.x{constructor(N){super(),this._onActivate=N.onActivate,this.bgDomNode=document.createElement("div"),this.bgDomNode.className="arrow-background",this.bgDomNode.style.position="absolute",this.bgDomNode.style.width=N.bgWidth+"px",this.bgDomNode.style.height=N.bgHeight+"px",typeof N.top<"u"&&(this.bgDomNode.style.top="0px"),typeof N.left<"u"&&(this.bgDomNode.style.left="0px"),typeof N.bottom<"u"&&(this.bgDomNode.style.bottom="0px"),typeof N.right<"u"&&(this.bgDomNode.style.right="0px"),this.domNode=document.createElement("div"),this.domNode.className=N.className,this.domNode.classList.add(...N.icon.classNamesArray),this.domNode.style.position="absolute",this.domNode.style.width=B+"px",this.domNode.style.height=B+"px",typeof N.top<"u"&&(this.domNode.style.top=N.top+"px"),typeof N.left<"u"&&(this.domNode.style.left=N.left+"px"),typeof N.bottom<"u"&&(this.domNode.style.bottom=N.bottom+"px"),typeof N.right<"u"&&(this.domNode.style.right=N.right+"px"),this._pointerMoveMonitor=this._register(new L._),this._register(o.b2(this.bgDomNode,o.Bx.POINTER_DOWN,G=>this._arrowPointerDown(G))),this._register(o.b2(this.domNode,o.Bx.POINTER_DOWN,G=>this._arrowPointerDown(G))),this._pointerdownRepeatTimer=this._register(new P.vb),this._pointerdownScheduleRepeatTimer=this._register(new P.pc)}_arrowPointerDown(N){if(!N.target||!(N.target instanceof Element))return;const G=()=>{this._pointerdownRepeatTimer.cancelAndSet(()=>this._onActivate(),1e3/24)};this._onActivate(),this._pointerdownRepeatTimer.cancel(),this._pointerdownScheduleRepeatTimer.cancelAndSet(G,200),this._pointerMoveMonitor.startMonitoring(N.target,N.pointerId,N.buttons,O=>{},()=>{this._pointerdownRepeatTimer.cancel(),this._pointerdownScheduleRepeatTimer.cancel()}),N.preventDefault()}}var p=y(10998);class d extends p.jG{constructor(N,G,O){super(),this._visibility=N,this._visibleClassName=G,this._invisibleClassName=O,this._domNode=null,this._isVisible=!1,this._isNeeded=!1,this._rawShouldBeVisible=!1,this._shouldBeVisible=!1,this._revealTimer=this._register(new P.pc)}setVisibility(N){this._visibility!==N&&(this._visibility=N,this._updateShouldBeVisible())}setShouldBeVisible(N){this._rawShouldBeVisible=N,this._updateShouldBeVisible()}_applyVisibilitySetting(){return this._visibility===2?!1:this._visibility===3?!0:this._rawShouldBeVisible}_updateShouldBeVisible(){const N=this._applyVisibilitySetting();this._shouldBeVisible!==N&&(this._shouldBeVisible=N,this.ensureVisibility())}setIsNeeded(N){this._isNeeded!==N&&(this._isNeeded=N,this.ensureVisibility())}setDomNode(N){this._domNode=N,this._domNode.setClassName(this._invisibleClassName),this.setShouldBeVisible(!1)}ensureVisibility(){if(!this._isNeeded){this._hide(!1);return}this._shouldBeVisible?this._reveal():this._hide(!0)}_reveal(){this._isVisible||(this._isVisible=!0,this._revealTimer.setIfNotSet(()=>{var N;(N=this._domNode)===null||N===void 0||N.setClassName(this._visibleClassName)},0))}_hide(N){var G;this._revealTimer.cancel(),this._isVisible&&(this._isVisible=!1,(G=this._domNode)===null||G===void 0||G.setClassName(this._invisibleClassName+(N?" fade":"")))}}var g=y(63339);const h=140;class l extends U.x{constructor(N){super(),this._lazyRender=N.lazyRender,this._host=N.host,this._scrollable=N.scrollable,this._scrollByPage=N.scrollByPage,this._scrollbarState=N.scrollbarState,this._visibilityController=this._register(new d(N.visibility,"visible scrollbar "+N.extraScrollbarClassName,"invisible scrollbar "+N.extraScrollbarClassName)),this._visibilityController.setIsNeeded(this._scrollbarState.isNeeded()),this._pointerMoveMonitor=this._register(new L._),this._shouldRender=!0,this.domNode=(0,K.Z)(document.createElement("div")),this.domNode.setAttribute("role","presentation"),this.domNode.setAttribute("aria-hidden","true"),this._visibilityController.setDomNode(this.domNode),this.domNode.setPosition("absolute"),this._register(o.ko(this.domNode.domNode,o.Bx.POINTER_DOWN,G=>this._domNodePointerDown(G)))}_createArrow(N){const G=this._register(new T(N));this.domNode.domNode.appendChild(G.bgDomNode),this.domNode.domNode.appendChild(G.domNode)}_createSlider(N,G,O,te){this.slider=(0,K.Z)(document.createElement("div")),this.slider.setClassName("slider"),this.slider.setPosition("absolute"),this.slider.setTop(N),this.slider.setLeft(G),typeof O=="number"&&this.slider.setWidth(O),typeof te=="number"&&this.slider.setHeight(te),this.slider.setLayerHinting(!0),this.slider.setContain("strict"),this.domNode.domNode.appendChild(this.slider.domNode),this._register(o.ko(this.slider.domNode,o.Bx.POINTER_DOWN,oe=>{oe.button===0&&(oe.preventDefault(),this._sliderPointerDown(oe))})),this.onclick(this.slider.domNode,oe=>{oe.leftButton&&oe.stopPropagation()})}_onElementSize(N){return this._scrollbarState.setVisibleSize(N)&&(this._visibilityController.setIsNeeded(this._scrollbarState.isNeeded()),this._shouldRender=!0,this._lazyRender||this.render()),this._shouldRender}_onElementScrollSize(N){return this._scrollbarState.setScrollSize(N)&&(this._visibilityController.setIsNeeded(this._scrollbarState.isNeeded()),this._shouldRender=!0,this._lazyRender||this.render()),this._shouldRender}_onElementScrollPosition(N){return this._scrollbarState.setScrollPosition(N)&&(this._visibilityController.setIsNeeded(this._scrollbarState.isNeeded()),this._shouldRender=!0,this._lazyRender||this.render()),this._shouldRender}beginReveal(){this._visibilityController.setShouldBeVisible(!0)}beginHide(){this._visibilityController.setShouldBeVisible(!1)}render(){this._shouldRender&&(this._shouldRender=!1,this._renderDomNode(this._scrollbarState.getRectangleLargeSize(),this._scrollbarState.getRectangleSmallSize()),this._updateSlider(this._scrollbarState.getSliderSize(),this._scrollbarState.getArrowSize()+this._scrollbarState.getSliderPosition()))}_domNodePointerDown(N){N.target===this.domNode.domNode&&this._onPointerDown(N)}delegatePointerDown(N){const G=this.domNode.domNode.getClientRects()[0].top,O=G+this._scrollbarState.getSliderPosition(),te=G+this._scrollbarState.getSliderPosition()+this._scrollbarState.getSliderSize(),oe=this._sliderPointerPosition(N);O<=oe&&oe<=te?N.button===0&&(N.preventDefault(),this._sliderPointerDown(N)):this._onPointerDown(N)}_onPointerDown(N){let G,O;if(N.target===this.domNode.domNode&&typeof N.offsetX=="number"&&typeof N.offsetY=="number")G=N.offsetX,O=N.offsetY;else{const oe=o.BK(this.domNode.domNode);G=N.pageX-oe.left,O=N.pageY-oe.top}const te=this._pointerDownRelativePosition(G,O);this._setDesiredScrollPositionNow(this._scrollByPage?this._scrollbarState.getDesiredScrollPositionFromOffsetPaged(te):this._scrollbarState.getDesiredScrollPositionFromOffset(te)),N.button===0&&(N.preventDefault(),this._sliderPointerDown(N))}_sliderPointerDown(N){if(!N.target||!(N.target instanceof Element))return;const G=this._sliderPointerPosition(N),O=this._sliderOrthogonalPointerPosition(N),te=this._scrollbarState.clone();this.slider.toggleClassName("active",!0),this._pointerMoveMonitor.startMonitoring(N.target,N.pointerId,N.buttons,oe=>{const ue=this._sliderOrthogonalPointerPosition(oe),E=Math.abs(ue-O);if(g.uF&&E>h){this._setDesiredScrollPositionNow(te.getScrollPosition());return}const Ke=this._sliderPointerPosition(oe)-G;this._setDesiredScrollPositionNow(te.getDesiredScrollPositionFromDelta(Ke))},()=>{this.slider.toggleClassName("active",!1),this._host.onDragEnd()}),this._host.onDragStart()}_setDesiredScrollPositionNow(N){const G={};this.writeScrollPosition(G,N),this._scrollable.setScrollPositionNow(G)}updateScrollbarSize(N){this._updateScrollbarSize(N),this._scrollbarState.setScrollbarSize(N),this._shouldRender=!0,this._lazyRender||this.render()}isNeeded(){return this._scrollbarState.isNeeded()}}const u=20;class w{constructor(N,G,O,te,oe,ue){this._scrollbarSize=Math.round(G),this._oppositeScrollbarSize=Math.round(O),this._arrowSize=Math.round(N),this._visibleSize=te,this._scrollSize=oe,this._scrollPosition=ue,this._computedAvailableSize=0,this._computedIsNeeded=!1,this._computedSliderSize=0,this._computedSliderRatio=0,this._computedSliderPosition=0,this._refreshComputedValues()}clone(){return new w(this._arrowSize,this._scrollbarSize,this._oppositeScrollbarSize,this._visibleSize,this._scrollSize,this._scrollPosition)}setVisibleSize(N){const G=Math.round(N);return this._visibleSize!==G?(this._visibleSize=G,this._refreshComputedValues(),!0):!1}setScrollSize(N){const G=Math.round(N);return this._scrollSize!==G?(this._scrollSize=G,this._refreshComputedValues(),!0):!1}setScrollPosition(N){const G=Math.round(N);return this._scrollPosition!==G?(this._scrollPosition=G,this._refreshComputedValues(),!0):!1}setScrollbarSize(N){this._scrollbarSize=Math.round(N)}setOppositeScrollbarSize(N){this._oppositeScrollbarSize=Math.round(N)}static _computeValues(N,G,O,te,oe){const ue=Math.max(0,O-N),E=Math.max(0,ue-2*G),Qe=te>0&&te>O;if(!Qe)return{computedAvailableSize:Math.round(ue),computedIsNeeded:Qe,computedSliderSize:Math.round(E),computedSliderRatio:0,computedSliderPosition:0};const Ke=Math.round(Math.max(u,Math.floor(O*E/te))),Se=(E-Ke)/(te-O),Me=oe*Se;return{computedAvailableSize:Math.round(ue),computedIsNeeded:Qe,computedSliderSize:Math.round(Ke),computedSliderRatio:Se,computedSliderPosition:Math.round(Me)}}_refreshComputedValues(){const N=w._computeValues(this._oppositeScrollbarSize,this._arrowSize,this._visibleSize,this._scrollSize,this._scrollPosition);this._computedAvailableSize=N.computedAvailableSize,this._computedIsNeeded=N.computedIsNeeded,this._computedSliderSize=N.computedSliderSize,this._computedSliderRatio=N.computedSliderRatio,this._computedSliderPosition=N.computedSliderPosition}getArrowSize(){return this._arrowSize}getScrollPosition(){return this._scrollPosition}getRectangleLargeSize(){return this._computedAvailableSize}getRectangleSmallSize(){return this._scrollbarSize}isNeeded(){return this._computedIsNeeded}getSliderSize(){return this._computedSliderSize}getSliderPosition(){return this._computedSliderPosition}getDesiredScrollPositionFromOffset(N){if(!this._computedIsNeeded)return 0;const G=N-this._arrowSize-this._computedSliderSize/2;return Math.round(G/this._computedSliderRatio)}getDesiredScrollPositionFromOffsetPaged(N){if(!this._computedIsNeeded)return 0;const G=N-this._arrowSize;let O=this._scrollPosition;return G<this._computedSliderPosition?O-=this._visibleSize:O+=this._visibleSize,O}getDesiredScrollPositionFromDelta(N){if(!this._computedIsNeeded)return 0;const G=this._computedSliderPosition+N;return Math.round(G/this._computedSliderRatio)}}var C=y(26048);class m extends l{constructor(N,G,O){const te=N.getScrollDimensions(),oe=N.getCurrentScrollPosition();if(super({lazyRender:G.lazyRender,host:O,scrollbarState:new w(G.horizontalHasArrows?G.arrowSize:0,G.horizontal===2?0:G.horizontalScrollbarSize,G.vertical===2?0:G.verticalScrollbarSize,te.width,te.scrollWidth,oe.scrollLeft),visibility:G.horizontal,extraScrollbarClassName:"horizontal",scrollable:N,scrollByPage:G.scrollByPage}),G.horizontalHasArrows){const ue=(G.arrowSize-B)/2,E=(G.horizontalScrollbarSize-B)/2;this._createArrow({className:"scra",icon:C.W6.scrollbarButtonLeft,top:E,left:ue,bottom:void 0,right:void 0,bgWidth:G.arrowSize,bgHeight:G.horizontalScrollbarSize,onActivate:()=>this._host.onMouseWheel(new $.$(null,1,0))}),this._createArrow({className:"scra",icon:C.W6.scrollbarButtonRight,top:E,left:void 0,bottom:void 0,right:ue,bgWidth:G.arrowSize,bgHeight:G.horizontalScrollbarSize,onActivate:()=>this._host.onMouseWheel(new $.$(null,-1,0))})}this._createSlider(Math.floor((G.horizontalScrollbarSize-G.horizontalSliderSize)/2),0,void 0,G.horizontalSliderSize)}_updateSlider(N,G){this.slider.setWidth(N),this.slider.setLeft(G)}_renderDomNode(N,G){this.domNode.setWidth(N),this.domNode.setHeight(G),this.domNode.setLeft(0),this.domNode.setBottom(0)}onDidScroll(N){return this._shouldRender=this._onElementScrollSize(N.scrollWidth)||this._shouldRender,this._shouldRender=this._onElementScrollPosition(N.scrollLeft)||this._shouldRender,this._shouldRender=this._onElementSize(N.width)||this._shouldRender,this._shouldRender}_pointerDownRelativePosition(N,G){return N}_sliderPointerPosition(N){return N.pageX}_sliderOrthogonalPointerPosition(N){return N.pageY}_updateScrollbarSize(N){this.slider.setHeight(N)}writeScrollPosition(N,G){N.scrollLeft=G}updateOptions(N){this.updateScrollbarSize(N.horizontal===2?0:N.horizontalScrollbarSize),this._scrollbarState.setOppositeScrollbarSize(N.vertical===2?0:N.verticalScrollbarSize),this._visibilityController.setVisibility(N.horizontal),this._scrollByPage=N.scrollByPage}}class v extends l{constructor(N,G,O){const te=N.getScrollDimensions(),oe=N.getCurrentScrollPosition();if(super({lazyRender:G.lazyRender,host:O,scrollbarState:new w(G.verticalHasArrows?G.arrowSize:0,G.vertical===2?0:G.verticalScrollbarSize,0,te.height,te.scrollHeight,oe.scrollTop),visibility:G.vertical,extraScrollbarClassName:"vertical",scrollable:N,scrollByPage:G.scrollByPage}),G.verticalHasArrows){const ue=(G.arrowSize-B)/2,E=(G.verticalScrollbarSize-B)/2;this._createArrow({className:"scra",icon:C.W6.scrollbarButtonUp,top:ue,left:E,bottom:void 0,right:void 0,bgWidth:G.verticalScrollbarSize,bgHeight:G.arrowSize,onActivate:()=>this._host.onMouseWheel(new $.$(null,0,1))}),this._createArrow({className:"scra",icon:C.W6.scrollbarButtonDown,top:void 0,left:E,bottom:ue,right:void 0,bgWidth:G.verticalScrollbarSize,bgHeight:G.arrowSize,onActivate:()=>this._host.onMouseWheel(new $.$(null,0,-1))})}this._createSlider(0,Math.floor((G.verticalScrollbarSize-G.verticalSliderSize)/2),G.verticalSliderSize,void 0)}_updateSlider(N,G){this.slider.setHeight(N),this.slider.setTop(G)}_renderDomNode(N,G){this.domNode.setWidth(G),this.domNode.setHeight(N),this.domNode.setRight(0),this.domNode.setTop(0)}onDidScroll(N){return this._shouldRender=this._onElementScrollSize(N.scrollHeight)||this._shouldRender,this._shouldRender=this._onElementScrollPosition(N.scrollTop)||this._shouldRender,this._shouldRender=this._onElementSize(N.height)||this._shouldRender,this._shouldRender}_pointerDownRelativePosition(N,G){return G}_sliderPointerPosition(N){return N.pageY}_sliderOrthogonalPointerPosition(N){return N.pageX}_updateScrollbarSize(N){this.slider.setWidth(N)}writeScrollPosition(N,G){N.scrollTop=G}updateOptions(N){this.updateScrollbarSize(N.vertical===2?0:N.verticalScrollbarSize),this._scrollbarState.setOppositeScrollbarSize(0),this._visibilityController.setVisibility(N.vertical),this._scrollByPage=N.scrollByPage}}var k=y(2106),D=y(94513);const x=500,A=50,W=!0;class Y{constructor(N,G,O){this.timestamp=N,this.deltaX=G,this.deltaY=O,this.score=0}}class ne{constructor(){this._capacity=5,this._memory=[],this._front=-1,this._rear=-1}isPhysicalMouseWheel(){if(this._front===-1&&this._rear===-1)return!1;let N=1,G=0,O=1,te=this._rear;do{const oe=te===this._front?N:Math.pow(2,-O);if(N-=oe,G+=this._memory[te].score*oe,te===this._front)break;te=(this._capacity+te-1)%this._capacity,O++}while(!0);return G<=.5}accept(N,G,O){const te=new Y(N,G,O);te.score=this._computeScore(te),this._front===-1&&this._rear===-1?(this._memory[0]=te,this._front=0,this._rear=0):(this._rear=(this._rear+1)%this._capacity,this._rear===this._front&&(this._front=(this._front+1)%this._capacity),this._memory[this._rear]=te)}_computeScore(N){if(Math.abs(N.deltaX)>0&&Math.abs(N.deltaY)>0)return 1;let G=.5;const O=this._front===-1&&this._rear===-1?null:this._memory[this._rear];return(!this._isAlmostInt(N.deltaX)||!this._isAlmostInt(N.deltaY))&&(G+=.25),Math.min(Math.max(G,0),1)}_isAlmostInt(N){return Math.abs(Math.round(N)-N)<.01}}ne.INSTANCE=new ne;class j extends U.x{constructor(N,G,O){super(),this._onScroll=this._register(new k.vl),this.onScroll=this._onScroll.event,this._onWillScroll=this._register(new k.vl),N.style.overflow="hidden",this._options=H(G),this._scrollable=O,this._register(this._scrollable.onScroll(oe=>{this._onWillScroll.fire(oe),this._onDidScroll(oe),this._onScroll.fire(oe)}));const te={onMouseWheel:oe=>this._onMouseWheel(oe),onDragStart:()=>this._onDragStart(),onDragEnd:()=>this._onDragEnd()};this._verticalScrollbar=this._register(new v(this._scrollable,this._options,te)),this._horizontalScrollbar=this._register(new m(this._scrollable,this._options,te)),this._domNode=document.createElement("div"),this._domNode.className="monaco-scrollable-element "+this._options.className,this._domNode.setAttribute("role","presentation"),this._domNode.style.position="relative",this._domNode.style.overflow="hidden",this._domNode.appendChild(N),this._domNode.appendChild(this._horizontalScrollbar.domNode.domNode),this._domNode.appendChild(this._verticalScrollbar.domNode.domNode),this._options.useShadows?(this._leftShadowDomNode=(0,K.Z)(document.createElement("div")),this._leftShadowDomNode.setClassName("shadow"),this._domNode.appendChild(this._leftShadowDomNode.domNode),this._topShadowDomNode=(0,K.Z)(document.createElement("div")),this._topShadowDomNode.setClassName("shadow"),this._domNode.appendChild(this._topShadowDomNode.domNode),this._topLeftShadowDomNode=(0,K.Z)(document.createElement("div")),this._topLeftShadowDomNode.setClassName("shadow"),this._domNode.appendChild(this._topLeftShadowDomNode.domNode)):(this._leftShadowDomNode=null,this._topShadowDomNode=null,this._topLeftShadowDomNode=null),this._listenOnDomNode=this._options.listenOnDomNode||this._domNode,this._mouseWheelToDispose=[],this._setListeningToMouseWheel(this._options.handleMouseWheel),this.onmouseover(this._listenOnDomNode,oe=>this._onMouseOver(oe)),this.onmouseleave(this._listenOnDomNode,oe=>this._onMouseLeave(oe)),this._hideTimeout=this._register(new P.pc),this._isDragging=!1,this._mouseIsOver=!1,this._shouldRender=!0,this._revealOnScroll=!0}get options(){return this._options}dispose(){this._mouseWheelToDispose=(0,p.AS)(this._mouseWheelToDispose),super.dispose()}getDomNode(){return this._domNode}getOverviewRulerLayoutInfo(){return{parent:this._domNode,insertBefore:this._verticalScrollbar.domNode.domNode}}delegateVerticalScrollbarPointerDown(N){this._verticalScrollbar.delegatePointerDown(N)}getScrollDimensions(){return this._scrollable.getScrollDimensions()}setScrollDimensions(N){this._scrollable.setScrollDimensions(N,!1)}updateClassName(N){this._options.className=N,g.zx&&(this._options.className+=" mac"),this._domNode.className="monaco-scrollable-element "+this._options.className}updateOptions(N){typeof N.handleMouseWheel<"u"&&(this._options.handleMouseWheel=N.handleMouseWheel,this._setListeningToMouseWheel(this._options.handleMouseWheel)),typeof N.mouseWheelScrollSensitivity<"u"&&(this._options.mouseWheelScrollSensitivity=N.mouseWheelScrollSensitivity),typeof N.fastScrollSensitivity<"u"&&(this._options.fastScrollSensitivity=N.fastScrollSensitivity),typeof N.scrollPredominantAxis<"u"&&(this._options.scrollPredominantAxis=N.scrollPredominantAxis),typeof N.horizontal<"u"&&(this._options.horizontal=N.horizontal),typeof N.vertical<"u"&&(this._options.vertical=N.vertical),typeof N.horizontalScrollbarSize<"u"&&(this._options.horizontalScrollbarSize=N.horizontalScrollbarSize),typeof N.verticalScrollbarSize<"u"&&(this._options.verticalScrollbarSize=N.verticalScrollbarSize),typeof N.scrollByPage<"u"&&(this._options.scrollByPage=N.scrollByPage),this._horizontalScrollbar.updateOptions(this._options),this._verticalScrollbar.updateOptions(this._options),this._options.lazyRender||this._render()}_setListeningToMouseWheel(N){if(this._mouseWheelToDispose.length>0!==N&&(this._mouseWheelToDispose=(0,p.AS)(this._mouseWheelToDispose),N)){const O=te=>{this._onMouseWheel(new $.$(te))};this._mouseWheelToDispose.push(o.ko(this._listenOnDomNode,o.Bx.MOUSE_WHEEL,O,{passive:!1}))}}_onMouseWheel(N){const G=ne.INSTANCE;if(W){const oe=window.devicePixelRatio/(0,b.getZoomFactor)();g.uF||g.j9?G.accept(Date.now(),N.deltaX/oe,N.deltaY/oe):G.accept(Date.now(),N.deltaX,N.deltaY)}let O=!1;if(N.deltaY||N.deltaX){let oe=N.deltaY*this._options.mouseWheelScrollSensitivity,ue=N.deltaX*this._options.mouseWheelScrollSensitivity;this._options.scrollPredominantAxis&&(Math.abs(oe)>=Math.abs(ue)?ue=0:oe=0),this._options.flipAxes&&([oe,ue]=[ue,oe]);const E=!g.zx&&N.browserEvent&&N.browserEvent.shiftKey;(this._options.scrollYToX||E)&&!ue&&(ue=oe,oe=0),N.browserEvent&&N.browserEvent.altKey&&(ue=ue*this._options.fastScrollSensitivity,oe=oe*this._options.fastScrollSensitivity);const Qe=this._scrollable.getFutureScrollPosition();let Ke={};if(oe){const Se=A*oe,Me=Qe.scrollTop-(Se<0?Math.floor(Se):Math.ceil(Se));this._verticalScrollbar.writeScrollPosition(Ke,Me)}if(ue){const Se=A*ue,Me=Qe.scrollLeft-(Se<0?Math.floor(Se):Math.ceil(Se));this._horizontalScrollbar.writeScrollPosition(Ke,Me)}Ke=this._scrollable.validateScrollPosition(Ke),(Qe.scrollLeft!==Ke.scrollLeft||Qe.scrollTop!==Ke.scrollTop)&&(W&&this._options.mouseWheelSmoothScroll&&G.isPhysicalMouseWheel()?this._scrollable.setScrollPositionSmooth(Ke):this._scrollable.setScrollPositionNow(Ke),O=!0)}let te=O;!te&&this._options.alwaysConsumeMouseWheel&&(te=!0),!te&&this._options.consumeMouseWheelIfScrollbarIsNeeded&&(this._verticalScrollbar.isNeeded()||this._horizontalScrollbar.isNeeded())&&(te=!0),te&&(N.preventDefault(),N.stopPropagation())}_onDidScroll(N){this._shouldRender=this._horizontalScrollbar.onDidScroll(N)||this._shouldRender,this._shouldRender=this._verticalScrollbar.onDidScroll(N)||this._shouldRender,this._options.useShadows&&(this._shouldRender=!0),this._revealOnScroll&&this._reveal(),this._options.lazyRender||this._render()}renderNow(){if(!this._options.lazyRender)throw new Error("Please use `lazyRender` together with `renderNow`!");this._render()}_render(){if(this._shouldRender&&(this._shouldRender=!1,this._horizontalScrollbar.render(),this._verticalScrollbar.render(),this._options.useShadows)){const N=this._scrollable.getCurrentScrollPosition(),G=N.scrollTop>0,O=N.scrollLeft>0,te=O?" left":"",oe=G?" top":"",ue=O||G?" top-left-corner":"";this._leftShadowDomNode.setClassName(`shadow${te}`),this._topShadowDomNode.setClassName(`shadow${oe}`),this._topLeftShadowDomNode.setClassName(`shadow${ue}${oe}${te}`)}}_onDragStart(){this._isDragging=!0,this._reveal()}_onDragEnd(){this._isDragging=!1,this._hide()}_onMouseLeave(N){this._mouseIsOver=!1,this._hide()}_onMouseOver(N){this._mouseIsOver=!0,this._reveal()}_reveal(){this._verticalScrollbar.beginReveal(),this._horizontalScrollbar.beginReveal(),this._scheduleHide()}_hide(){!this._mouseIsOver&&!this._isDragging&&(this._verticalScrollbar.beginHide(),this._horizontalScrollbar.beginHide())}_scheduleHide(){!this._mouseIsOver&&!this._isDragging&&this._hideTimeout.cancelAndSet(()=>this._hide(),x)}}class Q extends j{constructor(N,G){G=G||{},G.mouseWheelSmoothScroll=!1;const O=new D.yE({forceIntegerValues:!0,smoothScrollDuration:0,scheduleAtNextAnimationFrame:te=>o.PG(te)});super(N,G,O),this._register(O)}setScrollPosition(N){this._scrollable.setScrollPositionNow(N)}}class X extends j{constructor(N,G,O){super(N,G,O)}setScrollPosition(N){N.reuseAnimation?this._scrollable.setScrollPositionSmooth(N,N.reuseAnimation):this._scrollable.setScrollPositionNow(N)}getScrollPosition(){return this._scrollable.getCurrentScrollPosition()}}class R extends j{constructor(N,G){G=G||{},G.mouseWheelSmoothScroll=!1;const O=new D.yE({forceIntegerValues:!1,smoothScrollDuration:0,scheduleAtNextAnimationFrame:te=>o.PG(te)});super(N,G,O),this._register(O),this._element=N,this.onScroll(te=>{te.scrollTopChanged&&(this._element.scrollTop=te.scrollTop),te.scrollLeftChanged&&(this._element.scrollLeft=te.scrollLeft)}),this.scanDomNode()}setScrollPosition(N){this._scrollable.setScrollPositionNow(N)}getScrollPosition(){return this._scrollable.getCurrentScrollPosition()}scanDomNode(){this.setScrollDimensions({width:this._element.clientWidth,scrollWidth:this._element.scrollWidth,height:this._element.clientHeight,scrollHeight:this._element.scrollHeight}),this.setScrollPosition({scrollLeft:this._element.scrollLeft,scrollTop:this._element.scrollTop})}}function H(Z){const N={lazyRender:typeof Z.lazyRender<"u"?Z.lazyRender:!1,className:typeof Z.className<"u"?Z.className:"",useShadows:typeof Z.useShadows<"u"?Z.useShadows:!0,handleMouseWheel:typeof Z.handleMouseWheel<"u"?Z.handleMouseWheel:!0,flipAxes:typeof Z.flipAxes<"u"?Z.flipAxes:!1,consumeMouseWheelIfScrollbarIsNeeded:typeof Z.consumeMouseWheelIfScrollbarIsNeeded<"u"?Z.consumeMouseWheelIfScrollbarIsNeeded:!1,alwaysConsumeMouseWheel:typeof Z.alwaysConsumeMouseWheel<"u"?Z.alwaysConsumeMouseWheel:!1,scrollYToX:typeof Z.scrollYToX<"u"?Z.scrollYToX:!1,mouseWheelScrollSensitivity:typeof Z.mouseWheelScrollSensitivity<"u"?Z.mouseWheelScrollSensitivity:1,fastScrollSensitivity:typeof Z.fastScrollSensitivity<"u"?Z.fastScrollSensitivity:5,scrollPredominantAxis:typeof Z.scrollPredominantAxis<"u"?Z.scrollPredominantAxis:!0,mouseWheelSmoothScroll:typeof Z.mouseWheelSmoothScroll<"u"?Z.mouseWheelSmoothScroll:!0,arrowSize:typeof Z.arrowSize<"u"?Z.arrowSize:11,listenOnDomNode:typeof Z.listenOnDomNode<"u"?Z.listenOnDomNode:null,horizontal:typeof Z.horizontal<"u"?Z.horizontal:1,horizontalScrollbarSize:typeof Z.horizontalScrollbarSize<"u"?Z.horizontalScrollbarSize:10,horizontalSliderSize:typeof Z.horizontalSliderSize<"u"?Z.horizontalSliderSize:0,horizontalHasArrows:typeof Z.horizontalHasArrows<"u"?Z.horizontalHasArrows:!1,vertical:typeof Z.vertical<"u"?Z.vertical:1,verticalScrollbarSize:typeof Z.verticalScrollbarSize<"u"?Z.verticalScrollbarSize:10,verticalHasArrows:typeof Z.verticalHasArrows<"u"?Z.verticalHasArrows:!1,verticalSliderSize:typeof Z.verticalSliderSize<"u"?Z.verticalSliderSize:0,scrollByPage:typeof Z.scrollByPage<"u"?Z.scrollByPage:!1};return N.horizontalSliderSize=typeof Z.horizontalSliderSize<"u"?Z.horizontalSliderSize:N.horizontalScrollbarSize,N.verticalSliderSize=typeof Z.verticalSliderSize<"u"?Z.verticalSliderSize:N.verticalScrollbarSize,g.zx&&(N.className+=" mac"),N}},64651:(rt,ye,y)=>{y.d(ye,{Gc:()=>u,Nn:()=>L,Xw:()=>U,rh:()=>l,yF:()=>h});var b=y(62549),o=y(34883),K=y(60756);class ${constructor(C){this._length=C}get length(){return this._length}}class L extends ${constructor(C,m,v,k,D){super(C),this.openingBracket=m,this.child=v,this.closingBracket=k,this.missingOpeningBracketIds=D}static create(C,m,v){let k=C.length;return m&&(k=(0,o.QB)(k,m.length)),v&&(k=(0,o.QB)(k,v.length)),new L(k,C,m,v,m?m.missingOpeningBracketIds:K.gV.getEmpty())}get kind(){return 2}get listHeight(){return 0}get childrenLength(){return 3}getChild(C){switch(C){case 0:return this.openingBracket;case 1:return this.child;case 2:return this.closingBracket}throw new Error("Invalid child index")}get children(){const C=new Array;return C.push(this.openingBracket),this.child&&C.push(this.child),this.closingBracket&&C.push(this.closingBracket),C}canBeReused(C){return!(this.closingBracket===null||C.intersects(this.missingOpeningBracketIds))}deepClone(){return new L(this.length,this.openingBracket.deepClone(),this.child&&this.child.deepClone(),this.closingBracket&&this.closingBracket.deepClone(),this.missingOpeningBracketIds)}computeMinIndentation(C,m){return this.child?this.child.computeMinIndentation((0,o.QB)(C,this.openingBracket.length),m):Number.MAX_SAFE_INTEGER}}class U extends ${constructor(C,m,v){super(C),this.listHeight=m,this._missingOpeningBracketIds=v,this.cachedMinIndentation=-1}static create23(C,m,v,k=!1){let D=C.length,x=C.missingOpeningBracketIds;if(C.listHeight!==m.listHeight)throw new Error("Invalid list heights");if(D=(0,o.QB)(D,m.length),x=x.merge(m.missingOpeningBracketIds),v){if(C.listHeight!==v.listHeight)throw new Error("Invalid list heights");D=(0,o.QB)(D,v.length),x=x.merge(v.missingOpeningBracketIds)}return k?new B(D,C.listHeight+1,C,m,v,x):new P(D,C.listHeight+1,C,m,v,x)}static getEmpty(){return new p(o.Vp,0,[],K.gV.getEmpty())}get kind(){return 4}get missingOpeningBracketIds(){return this._missingOpeningBracketIds}throwIfImmutable(){}makeLastElementMutable(){this.throwIfImmutable();const C=this.childrenLength;if(C===0)return;const m=this.getChild(C-1),v=m.kind===4?m.toMutable():m;return m!==v&&this.setChild(C-1,v),v}makeFirstElementMutable(){if(this.throwIfImmutable(),this.childrenLength===0)return;const m=this.getChild(0),v=m.kind===4?m.toMutable():m;return m!==v&&this.setChild(0,v),v}canBeReused(C){if(C.intersects(this.missingOpeningBracketIds))return!1;let m=this,v;for(;m.kind===4&&(v=m.childrenLength)>0;)m=m.getChild(v-1);return m.canBeReused(C)}handleChildrenChanged(){this.throwIfImmutable();const C=this.childrenLength;let m=this.getChild(0).length,v=this.getChild(0).missingOpeningBracketIds;for(let k=1;k<C;k++){const D=this.getChild(k);m=(0,o.QB)(m,D.length),v=v.merge(D.missingOpeningBracketIds)}this._length=m,this._missingOpeningBracketIds=v,this.cachedMinIndentation=-1}computeMinIndentation(C,m){if(this.cachedMinIndentation!==-1)return this.cachedMinIndentation;let v=Number.MAX_SAFE_INTEGER,k=C;for(let D=0;D<this.childrenLength;D++){const x=this.getChild(D);x&&(v=Math.min(v,x.computeMinIndentation(k,m)),k=(0,o.QB)(k,x.length))}return this.cachedMinIndentation=v,v}}class P extends U{constructor(C,m,v,k,D,x){super(C,m,x),this._item1=v,this._item2=k,this._item3=D}get childrenLength(){return this._item3!==null?3:2}getChild(C){switch(C){case 0:return this._item1;case 1:return this._item2;case 2:return this._item3}throw new Error("Invalid child index")}setChild(C,m){switch(C){case 0:this._item1=m;return;case 1:this._item2=m;return;case 2:this._item3=m;return}throw new Error("Invalid child index")}get children(){return this._item3?[this._item1,this._item2,this._item3]:[this._item1,this._item2]}get item1(){return this._item1}get item2(){return this._item2}get item3(){return this._item3}deepClone(){return new P(this.length,this.listHeight,this._item1.deepClone(),this._item2.deepClone(),this._item3?this._item3.deepClone():null,this.missingOpeningBracketIds)}appendChildOfSameHeight(C){if(this._item3)throw new Error("Cannot append to a full (2,3) tree node");this.throwIfImmutable(),this._item3=C,this.handleChildrenChanged()}unappendChild(){if(!this._item3)throw new Error("Cannot remove from a non-full (2,3) tree node");this.throwIfImmutable();const C=this._item3;return this._item3=null,this.handleChildrenChanged(),C}prependChildOfSameHeight(C){if(this._item3)throw new Error("Cannot prepend to a full (2,3) tree node");this.throwIfImmutable(),this._item3=this._item2,this._item2=this._item1,this._item1=C,this.handleChildrenChanged()}unprependChild(){if(!this._item3)throw new Error("Cannot remove from a non-full (2,3) tree node");this.throwIfImmutable();const C=this._item1;return this._item1=this._item2,this._item2=this._item3,this._item3=null,this.handleChildrenChanged(),C}toMutable(){return this}}class B extends P{toMutable(){return new P(this.length,this.listHeight,this.item1,this.item2,this.item3,this.missingOpeningBracketIds)}throwIfImmutable(){throw new Error("this instance is immutable")}}class T extends U{constructor(C,m,v,k){super(C,m,k),this._children=v}get childrenLength(){return this._children.length}getChild(C){return this._children[C]}setChild(C,m){this._children[C]=m}get children(){return this._children}deepClone(){const C=new Array(this._children.length);for(let m=0;m<this._children.length;m++)C[m]=this._children[m].deepClone();return new T(this.length,this.listHeight,C,this.missingOpeningBracketIds)}appendChildOfSameHeight(C){this.throwIfImmutable(),this._children.push(C),this.handleChildrenChanged()}unappendChild(){this.throwIfImmutable();const C=this._children.pop();return this.handleChildrenChanged(),C}prependChildOfSameHeight(C){this.throwIfImmutable(),this._children.unshift(C),this.handleChildrenChanged()}unprependChild(){this.throwIfImmutable();const C=this._children.shift();return this.handleChildrenChanged(),C}toMutable(){return this}}class p extends T{toMutable(){return new T(this.length,this.listHeight,[...this.children],this.missingOpeningBracketIds)}throwIfImmutable(){throw new Error("this instance is immutable")}}const d=[];class g extends ${get listHeight(){return 0}get childrenLength(){return 0}getChild(C){return null}get children(){return d}deepClone(){return this}}class h extends g{get kind(){return 0}get missingOpeningBracketIds(){return K.gV.getEmpty()}canBeReused(C){return!0}computeMinIndentation(C,m){const v=(0,o.l4)(C),k=(v.columnCount===0?v.lineCount:v.lineCount+1)+1,D=(0,o.eu)((0,o.QB)(C,this.length))+1;let x=Number.MAX_SAFE_INTEGER;for(let A=k;A<=D;A++){const W=m.getLineFirstNonWhitespaceColumn(A),Y=m.getLineContent(A);if(W===0)continue;const ne=b.A.visibleColumnFromColumn(Y,W,m.getOptions().tabSize);x=Math.min(x,ne)}return x}}class l extends g{constructor(C,m,v){super(C),this.bracketInfo=m,this.bracketIds=v}static create(C,m,v){return new l(C,m,v)}get kind(){return 1}get missingOpeningBracketIds(){return K.gV.getEmpty()}get text(){return this.bracketInfo.bracketText}get languageId(){return this.bracketInfo.languageId}canBeReused(C){return!1}computeMinIndentation(C,m){return Number.MAX_SAFE_INTEGER}}class u extends g{constructor(C,m){super(m),this.missingOpeningBracketIds=C}get kind(){return 3}canBeReused(C){return!C.intersects(this.missingOpeningBracketIds)}computeMinIndentation(C,m){return Number.MAX_SAFE_INTEGER}}},64830:(rt,ye,y)=>{y.d(ye,{S:()=>o});var b=y(82399);const o=(0,b.u1)("modelService")},65958:(rt,ye,y)=>{y.d(ye,{$1:()=>v,AE:()=>j,EQ:()=>m,HC:()=>ne,PK:()=>p,Qg:()=>B,SS:()=>T,Th:()=>w,Zv:()=>Y,bI:()=>X,cx:()=>A,hW:()=>l,kb:()=>W,pc:()=>k,uC:()=>x,vb:()=>D,ve:()=>u,wR:()=>C});var b=y(78903),o=y(94327),K=y(2106),$=y(10998),L=y(63339),U=function(R,H,Z,N){function G(O){return O instanceof Z?O:new Z(function(te){te(O)})}return new(Z||(Z=Promise))(function(O,te){function oe(Qe){try{E(N.next(Qe))}catch(Ke){te(Ke)}}function ue(Qe){try{E(N.throw(Qe))}catch(Ke){te(Ke)}}function E(Qe){Qe.done?O(Qe.value):G(Qe.value).then(oe,ue)}E((N=N.apply(R,H||[])).next())})},P=function(R){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var H=R[Symbol.asyncIterator],Z;return H?H.call(R):(R=typeof __values=="function"?__values(R):R[Symbol.iterator](),Z={},N("next"),N("throw"),N("return"),Z[Symbol.asyncIterator]=function(){return this},Z);function N(O){Z[O]=R[O]&&function(te){return new Promise(function(oe,ue){te=R[O](te),G(oe,ue,te.done,te.value)})}}function G(O,te,oe,ue){Promise.resolve(ue).then(function(E){O({value:E,done:oe})},te)}};function B(R){return!!R&&typeof R.then=="function"}function T(R){const H=new b.Q,Z=R(H.token),N=new Promise((G,O)=>{const te=H.token.onCancellationRequested(()=>{te.dispose(),H.dispose(),O(new o.AL)});Promise.resolve(Z).then(oe=>{te.dispose(),H.dispose(),G(oe)},oe=>{te.dispose(),H.dispose(),O(oe)})});return new class{cancel(){H.cancel()}then(G,O){return N.then(G,O)}catch(G){return this.then(void 0,G)}finally(G){return N.finally(G)}}}function p(R,H,Z){return new Promise((N,G)=>{const O=H.onCancellationRequested(()=>{O.dispose(),N(Z)});R.then(N,G).finally(()=>O.dispose())})}class d{constructor(){this.activePromise=null,this.queuedPromise=null,this.queuedPromiseFactory=null}queue(H){if(this.activePromise){if(this.queuedPromiseFactory=H,!this.queuedPromise){const Z=()=>{this.queuedPromise=null;const N=this.queue(this.queuedPromiseFactory);return this.queuedPromiseFactory=null,N};this.queuedPromise=new Promise(N=>{this.activePromise.then(Z,Z).then(N)})}return new Promise((Z,N)=>{this.queuedPromise.then(Z,N)})}return this.activePromise=H(),new Promise((Z,N)=>{this.activePromise.then(G=>{this.activePromise=null,Z(G)},G=>{this.activePromise=null,N(G)})})}}const g=(R,H)=>{let Z=!0;const N=setTimeout(()=>{Z=!1,H()},R);return{isTriggered:()=>Z,dispose:()=>{clearTimeout(N),Z=!1}}},h=R=>{let H=!0;return queueMicrotask(()=>{H&&(H=!1,R())}),{isTriggered:()=>H,dispose:()=>{H=!1}}},l=Symbol("MicrotaskDelay");class u{constructor(H){this.defaultDelay=H,this.deferred=null,this.completionPromise=null,this.doResolve=null,this.doReject=null,this.task=null}trigger(H,Z=this.defaultDelay){this.task=H,this.cancelTimeout(),this.completionPromise||(this.completionPromise=new Promise((G,O)=>{this.doResolve=G,this.doReject=O}).then(()=>{if(this.completionPromise=null,this.doResolve=null,this.task){const G=this.task;return this.task=null,G()}}));const N=()=>{var G;this.deferred=null,(G=this.doResolve)===null||G===void 0||G.call(this,null)};return this.deferred=Z===l?h(N):g(Z,N),this.completionPromise}isTriggered(){var H;return!!(!((H=this.deferred)===null||H===void 0)&&H.isTriggered())}cancel(){var H;this.cancelTimeout(),this.completionPromise&&((H=this.doReject)===null||H===void 0||H.call(this,new o.AL),this.completionPromise=null)}cancelTimeout(){var H;(H=this.deferred)===null||H===void 0||H.dispose(),this.deferred=null}dispose(){this.cancel()}}class w{constructor(H){this.delayer=new u(H),this.throttler=new d}trigger(H,Z){return this.delayer.trigger(()=>this.throttler.queue(H),Z)}dispose(){this.delayer.dispose()}}function C(R,H){return H?new Promise((Z,N)=>{const G=setTimeout(()=>{O.dispose(),Z()},R),O=H.onCancellationRequested(()=>{clearTimeout(G),O.dispose(),N(new o.AL)})}):T(Z=>C(R,Z))}function m(R,H=0){const Z=setTimeout(R,H);return(0,$.s)(()=>clearTimeout(Z))}function v(R,H=N=>!!N,Z=null){let N=0;const G=R.length,O=()=>{if(N>=G)return Promise.resolve(Z);const te=R[N++];return Promise.resolve(te()).then(ue=>H(ue)?Promise.resolve(ue):O())};return O()}class k{constructor(H,Z){this._token=-1,typeof H=="function"&&typeof Z=="number"&&this.setIfNotSet(H,Z)}dispose(){this.cancel()}cancel(){this._token!==-1&&(clearTimeout(this._token),this._token=-1)}cancelAndSet(H,Z){this.cancel(),this._token=setTimeout(()=>{this._token=-1,H()},Z)}setIfNotSet(H,Z){this._token===-1&&(this._token=setTimeout(()=>{this._token=-1,H()},Z))}}class D{constructor(){this._token=-1}dispose(){this.cancel()}cancel(){this._token!==-1&&(clearInterval(this._token),this._token=-1)}cancelAndSet(H,Z){this.cancel(),this._token=setInterval(()=>{H()},Z)}}class x{constructor(H,Z){this.timeoutToken=-1,this.runner=H,this.timeout=Z,this.timeoutHandler=this.onTimeout.bind(this)}dispose(){this.cancel(),this.runner=null}cancel(){this.isScheduled()&&(clearTimeout(this.timeoutToken),this.timeoutToken=-1)}schedule(H=this.timeout){this.cancel(),this.timeoutToken=setTimeout(this.timeoutHandler,H)}get delay(){return this.timeout}set delay(H){this.timeout=H}isScheduled(){return this.timeoutToken!==-1}onTimeout(){this.timeoutToken=-1,this.runner&&this.doRun()}doRun(){var H;(H=this.runner)===null||H===void 0||H.call(this)}}let A;(function(){typeof requestIdleCallback!="function"||typeof cancelIdleCallback!="function"?A=R=>{(0,L._p)(()=>{if(H)return;const Z=Date.now()+15;R(Object.freeze({didTimeout:!0,timeRemaining(){return Math.max(0,Z-Date.now())}}))});let H=!1;return{dispose(){H||(H=!0)}}}:A=(R,H)=>{const Z=requestIdleCallback(R,typeof H=="number"?{timeout:H}:void 0);let N=!1;return{dispose(){N||(N=!0,cancelIdleCallback(Z))}}}})();class W{constructor(H){this._didRun=!1,this._executor=()=>{try{this._value=H()}catch(Z){this._error=Z}finally{this._didRun=!0}},this._handle=A(()=>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}}class Y{constructor(){this.rejected=!1,this.resolved=!1,this.p=new Promise((H,Z)=>{this.completeCallback=H,this.errorCallback=Z})}get isRejected(){return this.rejected}get isSettled(){return this.rejected||this.resolved}complete(H){return new Promise(Z=>{this.completeCallback(H),this.resolved=!0,Z()})}cancel(){new Promise(H=>{this.errorCallback(new o.AL),this.rejected=!0,H()})}}var ne;(function(R){function H(N){return U(this,void 0,void 0,function*(){let G;const O=yield Promise.all(N.map(te=>te.then(oe=>oe,oe=>{G||(G=oe)})));if(typeof G<"u")throw G;return O})}R.settled=H;function Z(N){return new Promise((G,O)=>U(this,void 0,void 0,function*(){try{yield N(G,O)}catch(te){O(te)}}))}R.withAsyncBody=Z})(ne||(ne={}));class j{constructor(H){this._state=0,this._results=[],this._error=null,this._onStateChanged=new K.vl,queueMicrotask(()=>U(this,void 0,void 0,function*(){const Z={emitOne:N=>this.emitOne(N),emitMany:N=>this.emitMany(N),reject:N=>this.reject(N)};try{yield Promise.resolve(H(Z)),this.resolve()}catch(N){this.reject(N)}finally{Z.emitOne=void 0,Z.emitMany=void 0,Z.reject=void 0}}))}static fromArray(H){return new j(Z=>{Z.emitMany(H)})}static fromPromise(H){return new j(Z=>U(this,void 0,void 0,function*(){Z.emitMany(yield H)}))}static fromPromises(H){return new j(Z=>U(this,void 0,void 0,function*(){yield Promise.all(H.map(N=>U(this,void 0,void 0,function*(){return Z.emitOne(yield N)})))}))}static merge(H){return new j(Z=>U(this,void 0,void 0,function*(){yield Promise.all(H.map(N=>{var G,O;return U(this,void 0,void 0,function*(){var te,oe;try{for(G=P(N);O=yield G.next(),!O.done;){const ue=O.value;Z.emitOne(ue)}}catch(ue){te={error:ue}}finally{try{O&&!O.done&&(oe=G.return)&&(yield oe.call(G))}finally{if(te)throw te.error}}})}))}))}[Symbol.asyncIterator](){let H=0;return{next:()=>U(this,void 0,void 0,function*(){do{if(this._state===2)throw this._error;if(H<this._results.length)return{done:!1,value:this._results[H++]};if(this._state===1)return{done:!0,value:void 0};yield K.Jh.toPromise(this._onStateChanged.event)}while(!0)})}}static map(H,Z){return new j(N=>U(this,void 0,void 0,function*(){var G,O;try{for(var te=P(H),oe;oe=yield te.next(),!oe.done;){const ue=oe.value;N.emitOne(Z(ue))}}catch(ue){G={error:ue}}finally{try{oe&&!oe.done&&(O=te.return)&&(yield O.call(te))}finally{if(G)throw G.error}}}))}map(H){return j.map(this,H)}static filter(H,Z){return new j(N=>U(this,void 0,void 0,function*(){var G,O;try{for(var te=P(H),oe;oe=yield te.next(),!oe.done;){const ue=oe.value;Z(ue)&&N.emitOne(ue)}}catch(ue){G={error:ue}}finally{try{oe&&!oe.done&&(O=te.return)&&(yield O.call(te))}finally{if(G)throw G.error}}}))}filter(H){return j.filter(this,H)}static coalesce(H){return j.filter(H,Z=>!!Z)}coalesce(){return j.coalesce(this)}static toPromise(H){var Z,N,G,O;return U(this,void 0,void 0,function*(){const te=[];try{for(Z=P(H);N=yield Z.next(),!N.done;){const oe=N.value;te.push(oe)}}catch(oe){G={error:oe}}finally{try{N&&!N.done&&(O=Z.return)&&(yield O.call(Z))}finally{if(G)throw G.error}}return te})}toPromise(){return j.toPromise(this)}emitOne(H){this._state===0&&(this._results.push(H),this._onStateChanged.fire())}emitMany(H){this._state===0&&(this._results=this._results.concat(H),this._onStateChanged.fire())}resolve(){this._state===0&&(this._state=1,this._onStateChanged.fire())}reject(H){this._state===0&&(this._state=2,this._error=H,this._onStateChanged.fire())}}j.EMPTY=j.fromArray([]);class Q extends j{constructor(H,Z){super(Z),this._source=H}cancel(){this._source.cancel()}}function X(R){const H=new b.Q,Z=R(H.token);return new Q(H,N=>U(this,void 0,void 0,function*(){var G,O;const te=H.token.onCancellationRequested(()=>{te.dispose(),H.dispose(),N.reject(new o.AL)});try{try{for(var oe=P(Z),ue;ue=yield oe.next(),!ue.done;){const E=ue.value;if(H.token.isCancellationRequested)return;N.emitOne(E)}}catch(E){G={error:E}}finally{try{ue&&!ue.done&&(O=oe.return)&&(yield O.call(oe))}finally{if(G)throw G.error}}te.dispose(),H.dispose()}catch(E){te.dispose(),H.dispose(),N.reject(E)}}))}},66055:(rt,ye,y)=>{y.d(ye,{A5:()=>o,Dg:()=>U,F4:()=>p,L5:()=>T,R3:()=>K,VW:()=>$,Wo:()=>B,X2:()=>L,nk:()=>P,vd:()=>d});var b=y(71386),o;(function(g){g[g.Left=1]="Left",g[g.Center=2]="Center",g[g.Right=4]="Right",g[g.Full=7]="Full"})(o||(o={}));var K;(function(g){g[g.Inline=1]="Inline",g[g.Gutter=2]="Gutter"})(K||(K={}));var $;(function(g){g[g.Both=0]="Both",g[g.Right=1]="Right",g[g.Left=2]="Left",g[g.None=3]="None"})($||($={}));class L{constructor(h){this._textModelResolvedOptionsBrand=void 0,this.tabSize=Math.max(1,h.tabSize|0),this.indentSize=h.tabSize|0,this.insertSpaces=!!h.insertSpaces,this.defaultEOL=h.defaultEOL|0,this.trimAutoWhitespace=!!h.trimAutoWhitespace,this.bracketPairColorizationOptions=h.bracketPairColorizationOptions}equals(h){return this.tabSize===h.tabSize&&this.indentSize===h.indentSize&&this.insertSpaces===h.insertSpaces&&this.defaultEOL===h.defaultEOL&&this.trimAutoWhitespace===h.trimAutoWhitespace&&(0,b.aI)(this.bracketPairColorizationOptions,h.bracketPairColorizationOptions)}createChangeEvent(h){return{tabSize:this.tabSize!==h.tabSize,indentSize:this.indentSize!==h.indentSize,insertSpaces:this.insertSpaces!==h.insertSpaces,trimAutoWhitespace:this.trimAutoWhitespace!==h.trimAutoWhitespace}}}class U{constructor(h,l){this._findMatchBrand=void 0,this.range=h,this.matches=l}}function P(g){return g&&typeof g.read=="function"}class B{constructor(h,l,u,w,C,m){this.identifier=h,this.range=l,this.text=u,this.forceMoveMarkers=w,this.isAutoWhitespaceEdit=C,this._isTracked=m}}class T{constructor(h,l,u){this.regex=h,this.wordSeparators=l,this.simpleSearch=u}}class p{constructor(h,l,u){this.reverseEdits=h,this.changes=l,this.trimAutoWhitespaceLineNumbers=u}}function d(g){return!g.isTooLargeForSyncing()&&!g.isForSimpleWidget}},66316:(rt,ye,y)=>{y.d(ye,{iP:()=>L,iu:()=>o,q2:()=>$,tA:()=>K,ui:()=>U});var b=y(93702);class o{constructor(B,T,p=!1){this._range=B,this._text=T,this.insertsAutoWhitespace=p}getEditOperations(B,T){T.addTrackedEditOperation(this._range,this._text)}computeCursorState(B,T){const d=T.getInverseEditOperations()[0].range;return b.L.fromPositions(d.getEndPosition())}}class K{constructor(B,T){this._range=B,this._text=T}getEditOperations(B,T){T.addTrackedEditOperation(this._range,this._text)}computeCursorState(B,T){const d=T.getInverseEditOperations()[0].range;return b.L.fromRange(d,0)}}class ${constructor(B,T,p=!1){this._range=B,this._text=T,this.insertsAutoWhitespace=p}getEditOperations(B,T){T.addTrackedEditOperation(this._range,this._text)}computeCursorState(B,T){const d=T.getInverseEditOperations()[0].range;return b.L.fromPositions(d.getStartPosition())}}class L{constructor(B,T,p,d,g=!1){this._range=B,this._text=T,this._columnDeltaOffset=d,this._lineNumberDeltaOffset=p,this.insertsAutoWhitespace=g}getEditOperations(B,T){T.addTrackedEditOperation(this._range,this._text)}computeCursorState(B,T){const d=T.getInverseEditOperations()[0].range;return b.L.fromPositions(d.getEndPosition().delta(this._lineNumberDeltaOffset,this._columnDeltaOffset))}}class U{constructor(B,T,p,d=!1){this._range=B,this._text=T,this._initialSelection=p,this._forceMoveMarkers=d,this._selectionId=null}getEditOperations(B,T){T.addTrackedEditOperation(this._range,this._text,this._forceMoveMarkers),this._selectionId=T.trackSelection(this._initialSelection)}computeCursorState(B,T){return T.getTrackedSelection(this._selectionId)}}},66459:(rt,ye,y)=>{y.d(ye,{A:()=>K});var b=y(16844),o;(function($){$[$.Ignore=0]="Ignore",$[$.Info=1]="Info",$[$.Warning=2]="Warning",$[$.Error=3]="Error"})(o||(o={})),function($){const L="error",U="warning",P="warn",B="info",T="ignore";function p(g){return g?b.Q_(L,g)?$.Error:b.Q_(U,g)||b.Q_(P,g)?$.Warning:b.Q_(B,g)?$.Info:$.Ignore:$.Ignore}$.fromValue=p;function d(g){switch(g){case $.Error:return L;case $.Warning:return U;case $.Info:return B;default:return T}}$.toString=d}(o||(o={}));const K=o},66476:(rt,ye,y)=>{y.d(ye,{$C:()=>Ae,BE:()=>Ii,Bc:()=>N,O4:()=>D,Of:()=>ft,XR:()=>it,hZ:()=>d,jU:()=>Ti,lw:()=>B,m9:()=>Q,n0:()=>T,qB:()=>Si,wA:()=>C,xZ:()=>E,xq:()=>P,zM:()=>u});var b=y(3765),o=y(63339),K=y(18782),$=y(13338),L=y(71386),U=y(12590);const P=8;class B{constructor(fe){this._values=fe}hasChanged(fe){return this._values[fe]}}class T{constructor(){this.stableMinimapLayoutInput=null,this.stableFitMaxMinimapScale=0,this.stableFitRemainingWidth=0}}class p{constructor(fe,ze,Et,Ot){this.id=fe,this.name=ze,this.defaultValue=Et,this.schema=Ot}applyUpdate(fe,ze){return g(fe,ze)}compute(fe,ze,Et){return Et}}class d{constructor(fe,ze){this.newValue=fe,this.didChange=ze}}function g(yt,fe){if(typeof yt!="object"||typeof fe!="object"||!yt||!fe)return new d(fe,yt!==fe);if(Array.isArray(yt)||Array.isArray(fe)){const Et=Array.isArray(yt)&&Array.isArray(fe)&&$.aI(yt,fe);return new d(fe,!Et)}let ze=!1;for(const Et in fe)if(fe.hasOwnProperty(Et)){const Ot=g(yt[Et],fe[Et]);Ot.didChange&&(yt[Et]=Ot.newValue,ze=!0)}return new d(yt,ze)}class h{constructor(fe){this.schema=void 0,this.id=fe,this.name="_never_",this.defaultValue=void 0}applyUpdate(fe,ze){return g(fe,ze)}validate(fe){return this.defaultValue}}class l{constructor(fe,ze,Et,Ot){this.id=fe,this.name=ze,this.defaultValue=Et,this.schema=Ot}applyUpdate(fe,ze){return g(fe,ze)}validate(fe){return typeof fe>"u"?this.defaultValue:fe}compute(fe,ze,Et){return Et}}function u(yt,fe){return typeof yt>"u"?fe:yt==="false"?!1:!!yt}class w extends l{constructor(fe,ze,Et,Ot=void 0){typeof Ot<"u"&&(Ot.type="boolean",Ot.default=Et),super(fe,ze,Et,Ot)}validate(fe){return u(fe,this.defaultValue)}}function C(yt,fe,ze,Et){if(typeof yt>"u")return fe;let Ot=parseInt(yt,10);return isNaN(Ot)?fe:(Ot=Math.max(ze,Ot),Ot=Math.min(Et,Ot),Ot|0)}class m extends l{constructor(fe,ze,Et,Ot,si,_i=void 0){typeof _i<"u"&&(_i.type="integer",_i.default=Et,_i.minimum=Ot,_i.maximum=si),super(fe,ze,Et,_i),this.minimum=Ot,this.maximum=si}static clampedInt(fe,ze,Et,Ot){return C(fe,ze,Et,Ot)}validate(fe){return m.clampedInt(fe,this.defaultValue,this.minimum,this.maximum)}}class v extends l{constructor(fe,ze,Et,Ot,si){typeof si<"u"&&(si.type="number",si.default=Et),super(fe,ze,Et,si),this.validationFn=Ot}static clamp(fe,ze,Et){return fe<ze?ze:fe>Et?Et:fe}static float(fe,ze){if(typeof fe=="number")return fe;if(typeof fe>"u")return ze;const Et=parseFloat(fe);return isNaN(Et)?ze:Et}validate(fe){return this.validationFn(v.float(fe,this.defaultValue))}}class k extends l{static string(fe,ze){return typeof fe!="string"?ze:fe}constructor(fe,ze,Et,Ot=void 0){typeof Ot<"u"&&(Ot.type="string",Ot.default=Et),super(fe,ze,Et,Ot)}validate(fe){return k.string(fe,this.defaultValue)}}function D(yt,fe,ze){return typeof yt!="string"||ze.indexOf(yt)===-1?fe:yt}class x extends l{constructor(fe,ze,Et,Ot,si=void 0){typeof si<"u"&&(si.type="string",si.enum=Ot,si.default=Et),super(fe,ze,Et,si),this._allowedValues=Ot}validate(fe){return D(fe,this.defaultValue,this._allowedValues)}}class A extends p{constructor(fe,ze,Et,Ot,si,_i,Fe=void 0){typeof Fe<"u"&&(Fe.type="string",Fe.enum=si,Fe.default=Ot),super(fe,ze,Et,Fe),this._allowedValues=si,this._convert=_i}validate(fe){return typeof fe!="string"?this.defaultValue:this._allowedValues.indexOf(fe)===-1?this.defaultValue:this._convert(fe)}}function W(yt){switch(yt){case"none":return 0;case"keep":return 1;case"brackets":return 2;case"advanced":return 3;case"full":return 4}}class Y extends p{constructor(){super(2,"accessibilitySupport",0,{type:"string",enum:["auto","on","off"],enumDescriptions:[b.kg("accessibilitySupport.auto","The editor will use platform APIs to detect when a Screen Reader is attached."),b.kg("accessibilitySupport.on","The editor will be permanently optimized for usage with a Screen Reader. Word wrapping will be disabled."),b.kg("accessibilitySupport.off","The editor will never be optimized for usage with a Screen Reader.")],default:"auto",description:b.kg("accessibilitySupport","Controls whether the editor should run in a mode where it is optimized for screen readers. Setting to on will disable word wrapping.")})}validate(fe){switch(fe){case"auto":return 0;case"off":return 1;case"on":return 2}return this.defaultValue}compute(fe,ze,Et){return Et===0?fe.accessibilitySupport:Et}}class ne extends p{constructor(){const fe={insertSpace:!0,ignoreEmptyLines:!0};super(19,"comments",fe,{"editor.comments.insertSpace":{type:"boolean",default:fe.insertSpace,description:b.kg("comments.insertSpace","Controls whether a space character is inserted when commenting.")},"editor.comments.ignoreEmptyLines":{type:"boolean",default:fe.ignoreEmptyLines,description:b.kg("comments.ignoreEmptyLines","Controls if empty lines should be ignored with toggle, add or remove actions for line comments.")}})}validate(fe){if(!fe||typeof fe!="object")return this.defaultValue;const ze=fe;return{insertSpace:u(ze.insertSpace,this.defaultValue.insertSpace),ignoreEmptyLines:u(ze.ignoreEmptyLines,this.defaultValue.ignoreEmptyLines)}}}function j(yt){switch(yt){case"blink":return 1;case"smooth":return 2;case"phase":return 3;case"expand":return 4;case"solid":return 5}}var Q;(function(yt){yt[yt.Line=1]="Line",yt[yt.Block=2]="Block",yt[yt.Underline=3]="Underline",yt[yt.LineThin=4]="LineThin",yt[yt.BlockOutline=5]="BlockOutline",yt[yt.UnderlineThin=6]="UnderlineThin"})(Q||(Q={}));function X(yt){switch(yt){case"line":return Q.Line;case"block":return Q.Block;case"underline":return Q.Underline;case"line-thin":return Q.LineThin;case"block-outline":return Q.BlockOutline;case"underline-thin":return Q.UnderlineThin}}class R extends h{constructor(){super(130)}compute(fe,ze,Et){const Ot=["monaco-editor"];return ze.get(35)&&Ot.push(ze.get(35)),fe.extraEditorClassName&&Ot.push(fe.extraEditorClassName),ze.get(68)==="default"?Ot.push("mouse-default"):ze.get(68)==="copy"&&Ot.push("mouse-copy"),ze.get(102)&&Ot.push("showUnused"),ze.get(128)&&Ot.push("showDeprecated"),Ot.join(" ")}}class H extends w{constructor(){super(33,"emptySelectionClipboard",!0,{description:b.kg("emptySelectionClipboard","Controls whether copying without a selection copies the current line.")})}compute(fe,ze,Et){return Et&&fe.emptySelectionClipboard}}class Z extends p{constructor(){const fe={cursorMoveOnType:!0,seedSearchStringFromSelection:"always",autoFindInSelection:"never",globalFindClipboard:!1,addExtraSpaceOnTop:!0,loop:!0};super(37,"find",fe,{"editor.find.cursorMoveOnType":{type:"boolean",default:fe.cursorMoveOnType,description:b.kg("find.cursorMoveOnType","Controls whether the cursor should jump to find matches while typing.")},"editor.find.seedSearchStringFromSelection":{type:"string",enum:["never","always","selection"],default:fe.seedSearchStringFromSelection,enumDescriptions:[b.kg("editor.find.seedSearchStringFromSelection.never","Never seed search string from the editor selection."),b.kg("editor.find.seedSearchStringFromSelection.always","Always seed search string from the editor selection, including word at cursor position."),b.kg("editor.find.seedSearchStringFromSelection.selection","Only seed search string from the editor selection.")],description:b.kg("find.seedSearchStringFromSelection","Controls whether the search string in the Find Widget is seeded from the editor selection.")},"editor.find.autoFindInSelection":{type:"string",enum:["never","always","multiline"],default:fe.autoFindInSelection,enumDescriptions:[b.kg("editor.find.autoFindInSelection.never","Never turn on Find in Selection automatically (default)."),b.kg("editor.find.autoFindInSelection.always","Always turn on Find in Selection automatically."),b.kg("editor.find.autoFindInSelection.multiline","Turn on Find in Selection automatically when multiple lines of content are selected.")],description:b.kg("find.autoFindInSelection","Controls the condition for turning on Find in Selection automatically.")},"editor.find.globalFindClipboard":{type:"boolean",default:fe.globalFindClipboard,description:b.kg("find.globalFindClipboard","Controls whether the Find Widget should read or modify the shared find clipboard on macOS."),included:o.zx},"editor.find.addExtraSpaceOnTop":{type:"boolean",default:fe.addExtraSpaceOnTop,description:b.kg("find.addExtraSpaceOnTop","Controls whether the Find Widget should add extra lines on top of the editor. When true, you can scroll beyond the first line when the Find Widget is visible.")},"editor.find.loop":{type:"boolean",default:fe.loop,description:b.kg("find.loop","Controls whether the search automatically restarts from the beginning (or the end) when no further matches can be found.")}})}validate(fe){if(!fe||typeof fe!="object")return this.defaultValue;const ze=fe;return{cursorMoveOnType:u(ze.cursorMoveOnType,this.defaultValue.cursorMoveOnType),seedSearchStringFromSelection:typeof fe.seedSearchStringFromSelection=="boolean"?fe.seedSearchStringFromSelection?"always":"never":D(ze.seedSearchStringFromSelection,this.defaultValue.seedSearchStringFromSelection,["never","always","selection"]),autoFindInSelection:typeof fe.autoFindInSelection=="boolean"?fe.autoFindInSelection?"always":"never":D(ze.autoFindInSelection,this.defaultValue.autoFindInSelection,["never","always","multiline"]),globalFindClipboard:u(ze.globalFindClipboard,this.defaultValue.globalFindClipboard),addExtraSpaceOnTop:u(ze.addExtraSpaceOnTop,this.defaultValue.addExtraSpaceOnTop),loop:u(ze.loop,this.defaultValue.loop)}}}class N extends p{constructor(){super(47,"fontLigatures",N.OFF,{anyOf:[{type:"boolean",description:b.kg("fontLigatures","Enables/Disables font ligatures ('calt' and 'liga' font features). Change this to a string for fine-grained control of the 'font-feature-settings' CSS property.")},{type:"string",description:b.kg("fontFeatureSettings","Explicit 'font-feature-settings' CSS property. A boolean can be passed instead if one only needs to turn on/off ligatures.")}],description:b.kg("fontLigaturesGeneral","Configures font ligatures or font features. Can be either a boolean to enable/disable ligatures or a string for the value of the CSS 'font-feature-settings' property."),default:!1})}validate(fe){return typeof fe>"u"?this.defaultValue:typeof fe=="string"?fe==="false"?N.OFF:fe==="true"?N.ON:fe:fe?N.ON:N.OFF}}N.OFF='"liga" off, "calt" off',N.ON='"liga" on, "calt" on';class G extends h{constructor(){super(46)}compute(fe,ze,Et){return fe.fontInfo}}class O extends l{constructor(){super(48,"fontSize",Ti.fontSize,{type:"number",minimum:6,maximum:100,default:Ti.fontSize,description:b.kg("fontSize","Controls the font size in pixels.")})}validate(fe){const ze=v.float(fe,this.defaultValue);return ze===0?Ti.fontSize:v.clamp(ze,6,100)}compute(fe,ze,Et){return fe.fontInfo.fontSize}}class te extends p{constructor(){super(49,"fontWeight",Ti.fontWeight,{anyOf:[{type:"number",minimum:te.MINIMUM_VALUE,maximum:te.MAXIMUM_VALUE,errorMessage:b.kg("fontWeightErrorMessage",'Only "normal" and "bold" keywords or numbers between 1 and 1000 are allowed.')},{type:"string",pattern:"^(normal|bold|1000|[1-9][0-9]{0,2})$"},{enum:te.SUGGESTION_VALUES}],default:Ti.fontWeight,description:b.kg("fontWeight",'Controls the font weight. Accepts "normal" and "bold" keywords or numbers between 1 and 1000.')})}validate(fe){return fe==="normal"||fe==="bold"?fe:String(m.clampedInt(fe,Ti.fontWeight,te.MINIMUM_VALUE,te.MAXIMUM_VALUE))}}te.SUGGESTION_VALUES=["normal","bold","100","200","300","400","500","600","700","800","900"],te.MINIMUM_VALUE=1,te.MAXIMUM_VALUE=1e3;class oe extends p{constructor(){const fe={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:""},ze={type:"string",enum:["peek","gotoAndPeek","goto"],default:fe.multiple,enumDescriptions:[b.kg("editor.gotoLocation.multiple.peek","Show peek view of the results (default)"),b.kg("editor.gotoLocation.multiple.gotoAndPeek","Go to the primary result and show a peek view"),b.kg("editor.gotoLocation.multiple.goto","Go to the primary result and enable peek-less navigation to others")]},Et=["","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",fe,{"editor.gotoLocation.multiple":{deprecationMessage:b.kg("editor.gotoLocation.multiple.deprecated","This setting is deprecated, please use separate settings like 'editor.editor.gotoLocation.multipleDefinitions' or 'editor.editor.gotoLocation.multipleImplementations' instead.")},"editor.gotoLocation.multipleDefinitions":Object.assign({description:b.kg("editor.editor.gotoLocation.multipleDefinitions","Controls the behavior the 'Go to Definition'-command when multiple target locations exist.")},ze),"editor.gotoLocation.multipleTypeDefinitions":Object.assign({description:b.kg("editor.editor.gotoLocation.multipleTypeDefinitions","Controls the behavior the 'Go to Type Definition'-command when multiple target locations exist.")},ze),"editor.gotoLocation.multipleDeclarations":Object.assign({description:b.kg("editor.editor.gotoLocation.multipleDeclarations","Controls the behavior the 'Go to Declaration'-command when multiple target locations exist.")},ze),"editor.gotoLocation.multipleImplementations":Object.assign({description:b.kg("editor.editor.gotoLocation.multipleImplemenattions","Controls the behavior the 'Go to Implementations'-command when multiple target locations exist.")},ze),"editor.gotoLocation.multipleReferences":Object.assign({description:b.kg("editor.editor.gotoLocation.multipleReferences","Controls the behavior the 'Go to References'-command when multiple target locations exist.")},ze),"editor.gotoLocation.alternativeDefinitionCommand":{type:"string",default:fe.alternativeDefinitionCommand,enum:Et,description:b.kg("alternativeDefinitionCommand","Alternative command id that is being executed when the result of 'Go to Definition' is the current location.")},"editor.gotoLocation.alternativeTypeDefinitionCommand":{type:"string",default:fe.alternativeTypeDefinitionCommand,enum:Et,description:b.kg("alternativeTypeDefinitionCommand","Alternative command id that is being executed when the result of 'Go to Type Definition' is the current location.")},"editor.gotoLocation.alternativeDeclarationCommand":{type:"string",default:fe.alternativeDeclarationCommand,enum:Et,description:b.kg("alternativeDeclarationCommand","Alternative command id that is being executed when the result of 'Go to Declaration' is the current location.")},"editor.gotoLocation.alternativeImplementationCommand":{type:"string",default:fe.alternativeImplementationCommand,enum:Et,description:b.kg("alternativeImplementationCommand","Alternative command id that is being executed when the result of 'Go to Implementation' is the current location.")},"editor.gotoLocation.alternativeReferenceCommand":{type:"string",default:fe.alternativeReferenceCommand,enum:Et,description:b.kg("alternativeReferenceCommand","Alternative command id that is being executed when the result of 'Go to Reference' is the current location.")}})}validate(fe){var ze,Et,Ot,si,_i;if(!fe||typeof fe!="object")return this.defaultValue;const Fe=fe;return{multiple:D(Fe.multiple,this.defaultValue.multiple,["peek","gotoAndPeek","goto"]),multipleDefinitions:(ze=Fe.multipleDefinitions)!==null&&ze!==void 0?ze:D(Fe.multipleDefinitions,"peek",["peek","gotoAndPeek","goto"]),multipleTypeDefinitions:(Et=Fe.multipleTypeDefinitions)!==null&&Et!==void 0?Et:D(Fe.multipleTypeDefinitions,"peek",["peek","gotoAndPeek","goto"]),multipleDeclarations:(Ot=Fe.multipleDeclarations)!==null&&Ot!==void 0?Ot:D(Fe.multipleDeclarations,"peek",["peek","gotoAndPeek","goto"]),multipleImplementations:(si=Fe.multipleImplementations)!==null&&si!==void 0?si:D(Fe.multipleImplementations,"peek",["peek","gotoAndPeek","goto"]),multipleReferences:(_i=Fe.multipleReferences)!==null&&_i!==void 0?_i:D(Fe.multipleReferences,"peek",["peek","gotoAndPeek","goto"]),alternativeDefinitionCommand:k.string(Fe.alternativeDefinitionCommand,this.defaultValue.alternativeDefinitionCommand),alternativeTypeDefinitionCommand:k.string(Fe.alternativeTypeDefinitionCommand,this.defaultValue.alternativeTypeDefinitionCommand),alternativeDeclarationCommand:k.string(Fe.alternativeDeclarationCommand,this.defaultValue.alternativeDeclarationCommand),alternativeImplementationCommand:k.string(Fe.alternativeImplementationCommand,this.defaultValue.alternativeImplementationCommand),alternativeReferenceCommand:k.string(Fe.alternativeReferenceCommand,this.defaultValue.alternativeReferenceCommand)}}}class ue extends p{constructor(){const fe={enabled:!0,delay:300,sticky:!0,above:!0};super(55,"hover",fe,{"editor.hover.enabled":{type:"boolean",default:fe.enabled,description:b.kg("hover.enabled","Controls whether the hover is shown.")},"editor.hover.delay":{type:"number",default:fe.delay,minimum:0,maximum:1e4,description:b.kg("hover.delay","Controls the delay in milliseconds after which the hover is shown.")},"editor.hover.sticky":{type:"boolean",default:fe.sticky,description:b.kg("hover.sticky","Controls whether the hover should remain visible when mouse is moved over it.")},"editor.hover.above":{type:"boolean",default:fe.above,description:b.kg("hover.above","Prefer showing hovers above the line, if there's space.")}})}validate(fe){if(!fe||typeof fe!="object")return this.defaultValue;const ze=fe;return{enabled:u(ze.enabled,this.defaultValue.enabled),delay:m.clampedInt(ze.delay,this.defaultValue.delay,0,1e4),sticky:u(ze.sticky,this.defaultValue.sticky),above:u(ze.above,this.defaultValue.above)}}}class E extends h{constructor(){super(133)}compute(fe,ze,Et){return E.computeLayout(ze,{memory:fe.memory,outerWidth:fe.outerWidth,outerHeight:fe.outerHeight,isDominatedByLongLines:fe.isDominatedByLongLines,lineHeight:fe.fontInfo.lineHeight,viewLineCount:fe.viewLineCount,lineNumbersDigitCount:fe.lineNumbersDigitCount,typicalHalfwidthCharacterWidth:fe.fontInfo.typicalHalfwidthCharacterWidth,maxDigitWidth:fe.fontInfo.maxDigitWidth,pixelRatio:fe.pixelRatio})}static computeContainedMinimapLineCount(fe){const ze=fe.height/fe.lineHeight,Et=fe.scrollBeyondLastLine?ze-1:0,Ot=(fe.viewLineCount+Et)/(fe.pixelRatio*fe.height),si=Math.floor(fe.viewLineCount/Ot);return{typicalViewportLineCount:ze,extraLinesBeyondLastLine:Et,desiredRatio:Ot,minimapLineCount:si}}static _computeMinimapLayout(fe,ze){const Et=fe.outerWidth,Ot=fe.outerHeight,si=fe.pixelRatio;if(!fe.minimap.enabled)return{renderMinimap:0,minimapLeft:0,minimapWidth:0,minimapHeightIsEditorHeight:!1,minimapIsSampling:!1,minimapScale:1,minimapLineHeight:1,minimapCanvasInnerWidth:0,minimapCanvasInnerHeight:Math.floor(si*Ot),minimapCanvasOuterWidth:0,minimapCanvasOuterHeight:Ot};const _i=ze.stableMinimapLayoutInput,Fe=_i&&fe.outerHeight===_i.outerHeight&&fe.lineHeight===_i.lineHeight&&fe.typicalHalfwidthCharacterWidth===_i.typicalHalfwidthCharacterWidth&&fe.pixelRatio===_i.pixelRatio&&fe.scrollBeyondLastLine===_i.scrollBeyondLastLine&&fe.minimap.enabled===_i.minimap.enabled&&fe.minimap.side===_i.minimap.side&&fe.minimap.size===_i.minimap.size&&fe.minimap.showSlider===_i.minimap.showSlider&&fe.minimap.renderCharacters===_i.minimap.renderCharacters&&fe.minimap.maxColumn===_i.minimap.maxColumn&&fe.minimap.scale===_i.minimap.scale&&fe.verticalScrollbarWidth===_i.verticalScrollbarWidth&&fe.isViewportWrapping===_i.isViewportWrapping,Xe=fe.lineHeight,gt=fe.typicalHalfwidthCharacterWidth,Xt=fe.scrollBeyondLastLine,Vt=fe.minimap.renderCharacters;let ni=si>=2?Math.round(fe.minimap.scale*2):fe.minimap.scale;const vi=fe.minimap.maxColumn,Ri=fe.minimap.size,St=fe.minimap.side,ve=fe.verticalScrollbarWidth,Te=fe.viewLineCount,je=fe.remainingWidth,nt=fe.isViewportWrapping,at=Vt?2:3;let vt=Math.floor(si*Ot);const It=vt/si;let At=!1,wt=!1,kt=at*ni,Ct=ni/si,Gt=1;if(Ri==="fill"||Ri==="fit"){const{typicalViewportLineCount:ki,extraLinesBeyondLastLine:Kt,desiredRatio:li,minimapLineCount:Ci}=E.computeContainedMinimapLineCount({viewLineCount:Te,scrollBeyondLastLine:Xt,height:Ot,lineHeight:Xe,pixelRatio:si});if(Te/Ci>1)At=!0,wt=!0,ni=1,kt=1,Ct=ni/si;else{let Tt=!1,qt=ni+1;if(Ri==="fit"){const Ni=Math.ceil((Te+Kt)*kt);nt&&Fe&&je<=ze.stableFitRemainingWidth?(Tt=!0,qt=ze.stableFitMaxMinimapScale):Tt=Ni>vt}if(Ri==="fill"||Tt){At=!0;const Ni=ni;kt=Math.min(Xe*si,Math.max(1,Math.floor(1/li))),nt&&Fe&&je<=ze.stableFitRemainingWidth&&(qt=ze.stableFitMaxMinimapScale),ni=Math.min(qt,Math.max(1,Math.floor(kt/at))),ni>Ni&&(Gt=Math.min(2,ni/Ni)),Ct=ni/si/Gt,vt=Math.ceil(Math.max(ki,Te+Kt)*kt),nt?(ze.stableMinimapLayoutInput=fe,ze.stableFitRemainingWidth=je,ze.stableFitMaxMinimapScale=ni):(ze.stableMinimapLayoutInput=null,ze.stableFitRemainingWidth=0)}}}const Ht=Math.floor(vi*Ct),Ut=Math.min(Ht,Math.max(0,Math.floor((je-ve-2)*Ct/(gt+Ct)))+P);let Ue=Math.floor(si*Ut);const ei=Ue/si;Ue=Math.floor(Ue*Gt);const ui=Vt?1:2,oi=St==="left"?0:Et-Ut-ve;return{renderMinimap:ui,minimapLeft:oi,minimapWidth:Ut,minimapHeightIsEditorHeight:At,minimapIsSampling:wt,minimapScale:ni,minimapLineHeight:kt,minimapCanvasInnerWidth:Ue,minimapCanvasInnerHeight:vt,minimapCanvasOuterWidth:ei,minimapCanvasOuterHeight:It}}static computeLayout(fe,ze){const Et=ze.outerWidth|0,Ot=ze.outerHeight|0,si=ze.lineHeight|0,_i=ze.lineNumbersDigitCount|0,Fe=ze.typicalHalfwidthCharacterWidth,Xe=ze.maxDigitWidth,gt=ze.pixelRatio,Xt=ze.viewLineCount,Vt=fe.get(125),ni=Vt==="inherit"?fe.get(124):Vt,vi=ni==="inherit"?fe.get(120):ni,Ri=fe.get(123),St=fe.get(2),ve=ze.isDominatedByLongLines,Te=fe.get(52),je=fe.get(62).renderType!==0,nt=fe.get(63),at=fe.get(96),vt=fe.get(67),It=fe.get(94),At=It.verticalScrollbarSize,wt=It.verticalHasArrows,kt=It.arrowSize,Ct=It.horizontalScrollbarSize,Gt=fe.get(60),Ht=fe.get(39),Ut=fe.get(101)!=="never";let Ue;if(typeof Gt=="string"&&/^\d+(\.\d+)?ch$/.test(Gt)){const wi=parseFloat(Gt.substr(0,Gt.length-2));Ue=m.clampedInt(wi*Fe,0,0,1e3)}else Ue=m.clampedInt(Gt,0,0,1e3);Ht&&Ut&&(Ue+=16);let ei=0;if(je){const wi=Math.max(_i,nt);ei=Math.round(wi*Xe)}let ui=0;Te&&(ui=si);let oi=0,ki=oi+ui,Kt=ki+ei,li=Kt+Ue;const Ci=Et-ui-ei-Ue;let mi=!1,Tt=!1,qt=-1;St!==2&&(ni==="inherit"&&ve?(mi=!0,Tt=!0):vi==="on"||vi==="bounded"?Tt=!0:vi==="wordWrapColumn"&&(qt=Ri));const Ni=E._computeMinimapLayout({outerWidth:Et,outerHeight:Ot,lineHeight:si,typicalHalfwidthCharacterWidth:Fe,pixelRatio:gt,scrollBeyondLastLine:at,minimap:vt,verticalScrollbarWidth:At,viewLineCount:Xt,remainingWidth:Ci,isViewportWrapping:Tt},ze.memory||new T);Ni.renderMinimap!==0&&Ni.minimapLeft===0&&(oi+=Ni.minimapWidth,ki+=Ni.minimapWidth,Kt+=Ni.minimapWidth,li+=Ni.minimapWidth);const Fi=Ci-Ni.minimapWidth,yi=Math.max(1,Math.floor((Fi-At-2)/Fe)),ti=wt?kt:0;return Tt&&(qt=Math.max(1,yi),vi==="bounded"&&(qt=Math.min(qt,Ri))),{width:Et,height:Ot,glyphMarginLeft:oi,glyphMarginWidth:ui,lineNumbersLeft:ki,lineNumbersWidth:ei,decorationsLeft:Kt,decorationsWidth:Ue,contentLeft:li,contentWidth:Fi,minimap:Ni,viewportColumn:yi,isWordWrapMinified:mi,isViewportWrapping:Tt,wrappingColumn:qt,verticalScrollbarWidth:At,horizontalScrollbarHeight:Ct,overviewRuler:{top:ti,width:At,height:Ot-2*ti,right:0}}}}class Qe extends p{constructor(){const fe={enabled:!0};super(59,"lightbulb",fe,{"editor.lightbulb.enabled":{type:"boolean",default:fe.enabled,description:b.kg("codeActions","Enables the code action lightbulb in the editor.")}})}validate(fe){return!fe||typeof fe!="object"?this.defaultValue:{enabled:u(fe.enabled,this.defaultValue.enabled)}}}class Ke extends p{constructor(){const fe={stickyScroll:{enabled:!1}};super(34,"experimental",fe,{"editor.experimental.stickyScroll.enabled":{type:"boolean",default:fe.stickyScroll.enabled,description:b.kg("editor.experimental.stickyScroll","Shows the nested current scopes during the scroll at the top of the editor.")}})}validate(fe){var ze;return!fe||typeof fe!="object"?this.defaultValue:{stickyScroll:{enabled:u((ze=fe.stickyScroll)===null||ze===void 0?void 0:ze.enabled,this.defaultValue.stickyScroll.enabled)}}}}class Se extends p{constructor(){const fe={enabled:"on",fontSize:0,fontFamily:"",padding:!1};super(129,"inlayHints",fe,{"editor.inlayHints.enabled":{type:"string",default:fe.enabled,description:b.kg("inlayHints.enable","Enables the inlay hints in the editor."),enum:["on","onUnlessPressed","offUnlessPressed","off"],markdownEnumDescriptions:[b.kg("editor.inlayHints.on","Inlay hints are enabled"),b.kg("editor.inlayHints.onUnlessPressed","Inlay hints are showing by default and hide when holding `Ctrl+Alt`"),b.kg("editor.inlayHints.offUnlessPressed","Inlay hints are hidden by default and show when holding `Ctrl+Alt`"),b.kg("editor.inlayHints.off","Inlay hints are disabled")]},"editor.inlayHints.fontSize":{type:"number",default:fe.fontSize,markdownDescription:b.kg("inlayHints.fontSize","Controls font size of inlay hints in the editor. As default the {0} is used when the configured value is less than {1} or greater than the editor font size.","`#editor.fontSize#`","`5`")},"editor.inlayHints.fontFamily":{type:"string",default:fe.fontFamily,markdownDescription:b.kg("inlayHints.fontFamily","Controls font family of inlay hints in the editor. When set to empty, the {0} is used.","`#editor.fontFamily#`")},"editor.inlayHints.padding":{type:"boolean",default:fe.padding,description:b.kg("inlayHints.padding","Enables the padding around the inlay hints in the editor.")}})}validate(fe){if(!fe||typeof fe!="object")return this.defaultValue;const ze=fe;return typeof ze.enabled=="boolean"&&(ze.enabled=ze.enabled?"on":"off"),{enabled:D(ze.enabled,this.defaultValue.enabled,["on","off","offUnlessPressed","onUnlessPressed"]),fontSize:m.clampedInt(ze.fontSize,this.defaultValue.fontSize,0,100),fontFamily:k.string(ze.fontFamily,this.defaultValue.fontFamily),padding:u(ze.padding,this.defaultValue.padding)}}}class Me extends v{constructor(){super(61,"lineHeight",Ti.lineHeight,fe=>v.clamp(fe,0,150),{markdownDescription:b.kg("lineHeight",`Controls the line height. - Use 0 to automatically compute the line height from the font size. - Values between 0 and 8 will be used as a multiplier with the font size. - Values greater than or equal to 8 will be used as effective values.`)})}compute(fe,ze,Et){return fe.fontInfo.lineHeight}}class ce extends p{constructor(){const fe={enabled:!0,size:"proportional",side:"right",showSlider:"mouseover",autohide:!1,renderCharacters:!0,maxColumn:120,scale:1};super(67,"minimap",fe,{"editor.minimap.enabled":{type:"boolean",default:fe.enabled,description:b.kg("minimap.enabled","Controls whether the minimap is shown.")},"editor.minimap.autohide":{type:"boolean",default:fe.autohide,description:b.kg("minimap.autohide","Controls whether the minimap is hidden automatically.")},"editor.minimap.size":{type:"string",enum:["proportional","fill","fit"],enumDescriptions:[b.kg("minimap.size.proportional","The minimap has the same size as the editor contents (and might scroll)."),b.kg("minimap.size.fill","The minimap will stretch or shrink as necessary to fill the height of the editor (no scrolling)."),b.kg("minimap.size.fit","The minimap will shrink as necessary to never be larger than the editor (no scrolling).")],default:fe.size,description:b.kg("minimap.size","Controls the size of the minimap.")},"editor.minimap.side":{type:"string",enum:["left","right"],default:fe.side,description:b.kg("minimap.side","Controls the side where to render the minimap.")},"editor.minimap.showSlider":{type:"string",enum:["always","mouseover"],default:fe.showSlider,description:b.kg("minimap.showSlider","Controls when the minimap slider is shown.")},"editor.minimap.scale":{type:"number",default:fe.scale,minimum:1,maximum:3,enum:[1,2,3],description:b.kg("minimap.scale","Scale of content drawn in the minimap: 1, 2 or 3.")},"editor.minimap.renderCharacters":{type:"boolean",default:fe.renderCharacters,description:b.kg("minimap.renderCharacters","Render the actual characters on a line as opposed to color blocks.")},"editor.minimap.maxColumn":{type:"number",default:fe.maxColumn,description:b.kg("minimap.maxColumn","Limit the width of the minimap to render at most a certain number of columns.")}})}validate(fe){if(!fe||typeof fe!="object")return this.defaultValue;const ze=fe;return{enabled:u(ze.enabled,this.defaultValue.enabled),autohide:u(ze.autohide,this.defaultValue.autohide),size:D(ze.size,this.defaultValue.size,["proportional","fill","fit"]),side:D(ze.side,this.defaultValue.side,["right","left"]),showSlider:D(ze.showSlider,this.defaultValue.showSlider,["always","mouseover"]),renderCharacters:u(ze.renderCharacters,this.defaultValue.renderCharacters),scale:m.clampedInt(ze.scale,1,1,3),maxColumn:m.clampedInt(ze.maxColumn,this.defaultValue.maxColumn,1,1e4)}}}function pe(yt){return yt==="ctrlCmd"?o.zx?"metaKey":"ctrlKey":"altKey"}class be extends p{constructor(){super(77,"padding",{top:0,bottom:0},{"editor.padding.top":{type:"number",default:0,minimum:0,maximum:1e3,description:b.kg("padding.top","Controls the amount of space between the top edge of the editor and the first line.")},"editor.padding.bottom":{type:"number",default:0,minimum:0,maximum:1e3,description:b.kg("padding.bottom","Controls the amount of space between the bottom edge of the editor and the last line.")}})}validate(fe){if(!fe||typeof fe!="object")return this.defaultValue;const ze=fe;return{top:m.clampedInt(ze.top,0,0,1e3),bottom:m.clampedInt(ze.bottom,0,0,1e3)}}}class ge extends p{constructor(){const fe={enabled:!0,cycle:!1};super(78,"parameterHints",fe,{"editor.parameterHints.enabled":{type:"boolean",default:fe.enabled,description:b.kg("parameterHints.enabled","Enables a pop-up that shows parameter documentation and type information as you type.")},"editor.parameterHints.cycle":{type:"boolean",default:fe.cycle,description:b.kg("parameterHints.cycle","Controls whether the parameter hints menu cycles or closes when reaching the end of the list.")}})}validate(fe){if(!fe||typeof fe!="object")return this.defaultValue;const ze=fe;return{enabled:u(ze.enabled,this.defaultValue.enabled),cycle:u(ze.cycle,this.defaultValue.cycle)}}}class ke extends h{constructor(){super(131)}compute(fe,ze,Et){return fe.pixelRatio}}class We extends p{constructor(){const fe={other:"on",comments:"off",strings:"off"},ze=[{type:"boolean"},{type:"string",enum:["on","inline","off"],enumDescriptions:[b.kg("on","Quick suggestions show inside the suggest widget"),b.kg("inline","Quick suggestions show as ghost text"),b.kg("off","Quick suggestions are disabled")]}];super(81,"quickSuggestions",fe,{type:"object",additionalProperties:!1,properties:{strings:{anyOf:ze,default:fe.strings,description:b.kg("quickSuggestions.strings","Enable quick suggestions inside strings.")},comments:{anyOf:ze,default:fe.comments,description:b.kg("quickSuggestions.comments","Enable quick suggestions inside comments.")},other:{anyOf:ze,default:fe.other,description:b.kg("quickSuggestions.other","Enable quick suggestions outside of strings and comments.")}},default:fe,markdownDescription:b.kg("quickSuggestions","Controls whether suggestions should automatically show up while typing. This can be controlled for typing in comments, strings, and other code. Quick suggestion can be configured to show as ghost text or with the suggest widget. Also be aware of the '{0}'-setting which controls if suggestions are triggered by special characters.","#editor.suggestOnTriggerCharacters#")}),this.defaultValue=fe}validate(fe){if(typeof fe=="boolean"){const gt=fe?"on":"off";return{comments:gt,strings:gt,other:gt}}if(!fe||typeof fe!="object")return this.defaultValue;const{other:ze,comments:Et,strings:Ot}=fe,si=["on","inline","off"];let _i,Fe,Xe;return typeof ze=="boolean"?_i=ze?"on":"off":_i=D(ze,this.defaultValue.other,si),typeof Et=="boolean"?Fe=Et?"on":"off":Fe=D(Et,this.defaultValue.comments,si),typeof Ot=="boolean"?Xe=Ot?"on":"off":Xe=D(Ot,this.defaultValue.strings,si),{other:_i,comments:Fe,strings:Xe}}}class Ge extends p{constructor(){super(62,"lineNumbers",{renderType:1,renderFn:null},{type:"string",enum:["off","on","relative","interval"],enumDescriptions:[b.kg("lineNumbers.off","Line numbers are not rendered."),b.kg("lineNumbers.on","Line numbers are rendered as absolute number."),b.kg("lineNumbers.relative","Line numbers are rendered as distance in lines to cursor position."),b.kg("lineNumbers.interval","Line numbers are rendered every 10 lines.")],default:"on",description:b.kg("lineNumbers","Controls the display of line numbers.")})}validate(fe){let ze=this.defaultValue.renderType,Et=this.defaultValue.renderFn;return typeof fe<"u"&&(typeof fe=="function"?(ze=4,Et=fe):fe==="interval"?ze=3:fe==="relative"?ze=2:fe==="on"?ze=1:ze=0),{renderType:ze,renderFn:Et}}}function Ae(yt){const fe=yt.get(89);return fe==="editable"?yt.get(83):fe!=="on"}class he extends p{constructor(){const fe=[],ze={type:"number",description:b.kg("rulers.size","Number of monospace characters at which this editor ruler will render.")};super(93,"rulers",fe,{type:"array",items:{anyOf:[ze,{type:["object"],properties:{column:ze,color:{type:"string",description:b.kg("rulers.color","Color of this editor ruler."),format:"color-hex"}}}]},default:fe,description:b.kg("rulers","Render vertical rulers after a certain number of monospace characters. Use multiple values for multiple rulers. No rulers are drawn if array is empty.")})}validate(fe){if(Array.isArray(fe)){const ze=[];for(const Et of fe)if(typeof Et=="number")ze.push({column:m.clampedInt(Et,0,0,1e4),color:null});else if(Et&&typeof Et=="object"){const Ot=Et;ze.push({column:m.clampedInt(Ot.column,0,0,1e4),color:Ot.color})}return ze.sort((Et,Ot)=>Et.column-Ot.column),ze}return this.defaultValue}}function Pe(yt,fe){if(typeof yt!="string")return fe;switch(yt){case"hidden":return 2;case"visible":return 3;default:return 1}}class $e extends p{constructor(){const fe={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",fe,{"editor.scrollbar.vertical":{type:"string",enum:["auto","visible","hidden"],enumDescriptions:[b.kg("scrollbar.vertical.auto","The vertical scrollbar will be visible only when necessary."),b.kg("scrollbar.vertical.visible","The vertical scrollbar will always be visible."),b.kg("scrollbar.vertical.fit","The vertical scrollbar will always be hidden.")],default:"auto",description:b.kg("scrollbar.vertical","Controls the visibility of the vertical scrollbar.")},"editor.scrollbar.horizontal":{type:"string",enum:["auto","visible","hidden"],enumDescriptions:[b.kg("scrollbar.horizontal.auto","The horizontal scrollbar will be visible only when necessary."),b.kg("scrollbar.horizontal.visible","The horizontal scrollbar will always be visible."),b.kg("scrollbar.horizontal.fit","The horizontal scrollbar will always be hidden.")],default:"auto",description:b.kg("scrollbar.horizontal","Controls the visibility of the horizontal scrollbar.")},"editor.scrollbar.verticalScrollbarSize":{type:"number",default:fe.verticalScrollbarSize,description:b.kg("scrollbar.verticalScrollbarSize","The width of the vertical scrollbar.")},"editor.scrollbar.horizontalScrollbarSize":{type:"number",default:fe.horizontalScrollbarSize,description:b.kg("scrollbar.horizontalScrollbarSize","The height of the horizontal scrollbar.")},"editor.scrollbar.scrollByPage":{type:"boolean",default:fe.scrollByPage,description:b.kg("scrollbar.scrollByPage","Controls whether clicks scroll by page or jump to click position.")}})}validate(fe){if(!fe||typeof fe!="object")return this.defaultValue;const ze=fe,Et=m.clampedInt(ze.horizontalScrollbarSize,this.defaultValue.horizontalScrollbarSize,0,1e3),Ot=m.clampedInt(ze.verticalScrollbarSize,this.defaultValue.verticalScrollbarSize,0,1e3);return{arrowSize:m.clampedInt(ze.arrowSize,this.defaultValue.arrowSize,0,1e3),vertical:Pe(ze.vertical,this.defaultValue.vertical),horizontal:Pe(ze.horizontal,this.defaultValue.horizontal),useShadows:u(ze.useShadows,this.defaultValue.useShadows),verticalHasArrows:u(ze.verticalHasArrows,this.defaultValue.verticalHasArrows),horizontalHasArrows:u(ze.horizontalHasArrows,this.defaultValue.horizontalHasArrows),handleMouseWheel:u(ze.handleMouseWheel,this.defaultValue.handleMouseWheel),alwaysConsumeMouseWheel:u(ze.alwaysConsumeMouseWheel,this.defaultValue.alwaysConsumeMouseWheel),horizontalScrollbarSize:Et,horizontalSliderSize:m.clampedInt(ze.horizontalSliderSize,Et,0,1e3),verticalScrollbarSize:Ot,verticalSliderSize:m.clampedInt(ze.verticalSliderSize,Ot,0,1e3),scrollByPage:u(ze.scrollByPage,this.defaultValue.scrollByPage)}}}const it="inUntrustedWorkspace",ft={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 Wt extends p{constructor(){const fe={nonBasicASCII:it,invisibleCharacters:!0,ambiguousCharacters:!0,includeComments:it,includeStrings:!0,allowedCharacters:{},allowedLocales:{_os:!0,_vscode:!0}};super(115,"unicodeHighlight",fe,{[ft.nonBasicASCII]:{restricted:!0,type:["boolean","string"],enum:[!0,!1,it],default:fe.nonBasicASCII,description:b.kg("unicodeHighlight.nonBasicASCII","Controls whether all non-basic ASCII characters are highlighted. Only characters between U+0020 and U+007E, tab, line-feed and carriage-return are considered basic ASCII.")},[ft.invisibleCharacters]:{restricted:!0,type:"boolean",default:fe.invisibleCharacters,description:b.kg("unicodeHighlight.invisibleCharacters","Controls whether characters that just reserve space or have no width at all are highlighted.")},[ft.ambiguousCharacters]:{restricted:!0,type:"boolean",default:fe.ambiguousCharacters,description:b.kg("unicodeHighlight.ambiguousCharacters","Controls whether characters are highlighted that can be confused with basic ASCII characters, except those that are common in the current user locale.")},[ft.includeComments]:{restricted:!0,type:["boolean","string"],enum:[!0,!1,it],default:fe.includeComments,description:b.kg("unicodeHighlight.includeComments","Controls whether characters in comments should also be subject to unicode highlighting.")},[ft.includeStrings]:{restricted:!0,type:["boolean","string"],enum:[!0,!1,it],default:fe.includeStrings,description:b.kg("unicodeHighlight.includeStrings","Controls whether characters in strings should also be subject to unicode highlighting.")},[ft.allowedCharacters]:{restricted:!0,type:"object",default:fe.allowedCharacters,description:b.kg("unicodeHighlight.allowedCharacters","Defines allowed characters that are not being highlighted."),additionalProperties:{type:"boolean"}},[ft.allowedLocales]:{restricted:!0,type:"object",additionalProperties:{type:"boolean"},default:fe.allowedLocales,description:b.kg("unicodeHighlight.allowedLocales","Unicode characters that are common in allowed locales are not being highlighted.")}})}applyUpdate(fe,ze){let Et=!1;ze.allowedCharacters&&fe&&(L.aI(fe.allowedCharacters,ze.allowedCharacters)||(fe=Object.assign(Object.assign({},fe),{allowedCharacters:ze.allowedCharacters}),Et=!0)),ze.allowedLocales&&fe&&(L.aI(fe.allowedLocales,ze.allowedLocales)||(fe=Object.assign(Object.assign({},fe),{allowedLocales:ze.allowedLocales}),Et=!0));const Ot=super.applyUpdate(fe,ze);return Et?new d(Ot.newValue,!0):Ot}validate(fe){if(!fe||typeof fe!="object")return this.defaultValue;const ze=fe;return{nonBasicASCII:Lt(ze.nonBasicASCII,it,[!0,!1,it]),invisibleCharacters:u(ze.invisibleCharacters,this.defaultValue.invisibleCharacters),ambiguousCharacters:u(ze.ambiguousCharacters,this.defaultValue.ambiguousCharacters),includeComments:Lt(ze.includeComments,it,[!0,!1,it]),includeStrings:Lt(ze.includeStrings,it,[!0,!1,it]),allowedCharacters:this.validateBooleanMap(fe.allowedCharacters,this.defaultValue.allowedCharacters),allowedLocales:this.validateBooleanMap(fe.allowedLocales,this.defaultValue.allowedLocales)}}validateBooleanMap(fe,ze){if(typeof fe!="object"||!fe)return ze;const Et={};for(const[Ot,si]of Object.entries(fe))si===!0&&(Et[Ot]=!0);return Et}}class tt extends p{constructor(){const fe={enabled:!0,mode:"subwordSmart"};super(57,"inlineSuggest",fe,{"editor.inlineSuggest.enabled":{type:"boolean",default:fe.enabled,description:b.kg("inlineSuggest.enabled","Controls whether to automatically show inline suggestions in the editor.")}})}validate(fe){if(!fe||typeof fe!="object")return this.defaultValue;const ze=fe;return{enabled:u(ze.enabled,this.defaultValue.enabled),mode:D(ze.mode,this.defaultValue.mode,["prefix","subword","subwordSmart"])}}}class Ye extends p{constructor(){const fe={enabled:U.R.bracketPairColorizationOptions.enabled,independentColorPoolPerBracketType:U.R.bracketPairColorizationOptions.independentColorPoolPerBracketType};super(12,"bracketPairColorization",fe,{"editor.bracketPairColorization.enabled":{type:"boolean",default:fe.enabled,markdownDescription:b.kg("bracketPairColorization.enabled","Controls whether bracket pair colorization is enabled or not. Use {0} to override the bracket highlight colors.","`#workbench.colorCustomizations#`")},"editor.bracketPairColorization.independentColorPoolPerBracketType":{type:"boolean",default:fe.independentColorPoolPerBracketType,description:b.kg("bracketPairColorization.independentColorPoolPerBracketType","Controls whether each bracket type has its own independent color pool.")}})}validate(fe){if(!fe||typeof fe!="object")return this.defaultValue;const ze=fe;return{enabled:u(ze.enabled,this.defaultValue.enabled),independentColorPoolPerBracketType:u(ze.independentColorPoolPerBracketType,this.defaultValue.independentColorPoolPerBracketType)}}}class ht extends p{constructor(){const fe={bracketPairs:!1,bracketPairsHorizontal:"active",highlightActiveBracketPair:!0,indentation:!0,highlightActiveIndentation:!0};super(13,"guides",fe,{"editor.guides.bracketPairs":{type:["boolean","string"],enum:[!0,"active",!1],enumDescriptions:[b.kg("editor.guides.bracketPairs.true","Enables bracket pair guides."),b.kg("editor.guides.bracketPairs.active","Enables bracket pair guides only for the active bracket pair."),b.kg("editor.guides.bracketPairs.false","Disables bracket pair guides.")],default:fe.bracketPairs,description:b.kg("editor.guides.bracketPairs","Controls whether bracket pair guides are enabled or not.")},"editor.guides.bracketPairsHorizontal":{type:["boolean","string"],enum:[!0,"active",!1],enumDescriptions:[b.kg("editor.guides.bracketPairsHorizontal.true","Enables horizontal guides as addition to vertical bracket pair guides."),b.kg("editor.guides.bracketPairsHorizontal.active","Enables horizontal guides only for the active bracket pair."),b.kg("editor.guides.bracketPairsHorizontal.false","Disables horizontal bracket pair guides.")],default:fe.bracketPairsHorizontal,description:b.kg("editor.guides.bracketPairsHorizontal","Controls whether horizontal bracket pair guides are enabled or not.")},"editor.guides.highlightActiveBracketPair":{type:"boolean",default:fe.highlightActiveBracketPair,description:b.kg("editor.guides.highlightActiveBracketPair","Controls whether the editor should highlight the active bracket pair.")},"editor.guides.indentation":{type:"boolean",default:fe.indentation,description:b.kg("editor.guides.indentation","Controls whether the editor should render indent guides.")},"editor.guides.highlightActiveIndentation":{type:["boolean","string"],enum:[!0,"always",!1],enumDescriptions:[b.kg("editor.guides.highlightActiveIndentation.true","Highlights the active indent guide."),b.kg("editor.guides.highlightActiveIndentation.always","Highlights the active indent guide even if bracket guides are highlighted."),b.kg("editor.guides.highlightActiveIndentation.false","Do not highlight the active indent guide.")],default:fe.highlightActiveIndentation,description:b.kg("editor.guides.highlightActiveIndentation","Controls whether the editor should highlight the active indent guide.")}})}validate(fe){if(!fe||typeof fe!="object")return this.defaultValue;const ze=fe;return{bracketPairs:Lt(ze.bracketPairs,this.defaultValue.bracketPairs,[!0,!1,"active"]),bracketPairsHorizontal:Lt(ze.bracketPairsHorizontal,this.defaultValue.bracketPairsHorizontal,[!0,!1,"active"]),highlightActiveBracketPair:u(ze.highlightActiveBracketPair,this.defaultValue.highlightActiveBracketPair),indentation:u(ze.indentation,this.defaultValue.indentation),highlightActiveIndentation:Lt(ze.highlightActiveIndentation,this.defaultValue.highlightActiveIndentation,[!0,!1,"always"])}}}function Lt(yt,fe,ze){const Et=ze.indexOf(yt);return Et===-1?fe:ze[Et]}class Rt extends p{constructor(){const fe={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",fe,{"editor.suggest.insertMode":{type:"string",enum:["insert","replace"],enumDescriptions:[b.kg("suggest.insertMode.insert","Insert suggestion without overwriting text right of the cursor."),b.kg("suggest.insertMode.replace","Insert suggestion and overwrite text right of the cursor.")],default:fe.insertMode,description:b.kg("suggest.insertMode","Controls whether words are overwritten when accepting completions. Note that this depends on extensions opting into this feature.")},"editor.suggest.filterGraceful":{type:"boolean",default:fe.filterGraceful,description:b.kg("suggest.filterGraceful","Controls whether filtering and sorting suggestions accounts for small typos.")},"editor.suggest.localityBonus":{type:"boolean",default:fe.localityBonus,description:b.kg("suggest.localityBonus","Controls whether sorting favors words that appear close to the cursor.")},"editor.suggest.shareSuggestSelections":{type:"boolean",default:fe.shareSuggestSelections,markdownDescription:b.kg("suggest.shareSuggestSelections","Controls whether remembered suggestion selections are shared between multiple workspaces and windows (needs `#editor.suggestSelection#`).")},"editor.suggest.snippetsPreventQuickSuggestions":{type:"boolean",default:fe.snippetsPreventQuickSuggestions,description:b.kg("suggest.snippetsPreventQuickSuggestions","Controls whether an active snippet prevents quick suggestions.")},"editor.suggest.showIcons":{type:"boolean",default:fe.showIcons,description:b.kg("suggest.showIcons","Controls whether to show or hide icons in suggestions.")},"editor.suggest.showStatusBar":{type:"boolean",default:fe.showStatusBar,description:b.kg("suggest.showStatusBar","Controls the visibility of the status bar at the bottom of the suggest widget.")},"editor.suggest.preview":{type:"boolean",default:fe.preview,description:b.kg("suggest.preview","Controls whether to preview the suggestion outcome in the editor.")},"editor.suggest.showInlineDetails":{type:"boolean",default:fe.showInlineDetails,description:b.kg("suggest.showInlineDetails","Controls whether suggest details show inline with the label or only in the details widget")},"editor.suggest.maxVisibleSuggestions":{type:"number",deprecationMessage:b.kg("suggest.maxVisibleSuggestions.dep","This setting is deprecated. The suggest widget can now be resized.")},"editor.suggest.filteredTypes":{type:"object",deprecationMessage:b.kg("deprecated","This setting is deprecated, please use separate settings like 'editor.suggest.showKeywords' or 'editor.suggest.showSnippets' instead.")},"editor.suggest.showMethods":{type:"boolean",default:!0,markdownDescription:b.kg("editor.suggest.showMethods","When enabled IntelliSense shows `method`-suggestions.")},"editor.suggest.showFunctions":{type:"boolean",default:!0,markdownDescription:b.kg("editor.suggest.showFunctions","When enabled IntelliSense shows `function`-suggestions.")},"editor.suggest.showConstructors":{type:"boolean",default:!0,markdownDescription:b.kg("editor.suggest.showConstructors","When enabled IntelliSense shows `constructor`-suggestions.")},"editor.suggest.showDeprecated":{type:"boolean",default:!0,markdownDescription:b.kg("editor.suggest.showDeprecated","When enabled IntelliSense shows `deprecated`-suggestions.")},"editor.suggest.showFields":{type:"boolean",default:!0,markdownDescription:b.kg("editor.suggest.showFields","When enabled IntelliSense shows `field`-suggestions.")},"editor.suggest.showVariables":{type:"boolean",default:!0,markdownDescription:b.kg("editor.suggest.showVariables","When enabled IntelliSense shows `variable`-suggestions.")},"editor.suggest.showClasses":{type:"boolean",default:!0,markdownDescription:b.kg("editor.suggest.showClasss","When enabled IntelliSense shows `class`-suggestions.")},"editor.suggest.showStructs":{type:"boolean",default:!0,markdownDescription:b.kg("editor.suggest.showStructs","When enabled IntelliSense shows `struct`-suggestions.")},"editor.suggest.showInterfaces":{type:"boolean",default:!0,markdownDescription:b.kg("editor.suggest.showInterfaces","When enabled IntelliSense shows `interface`-suggestions.")},"editor.suggest.showModules":{type:"boolean",default:!0,markdownDescription:b.kg("editor.suggest.showModules","When enabled IntelliSense shows `module`-suggestions.")},"editor.suggest.showProperties":{type:"boolean",default:!0,markdownDescription:b.kg("editor.suggest.showPropertys","When enabled IntelliSense shows `property`-suggestions.")},"editor.suggest.showEvents":{type:"boolean",default:!0,markdownDescription:b.kg("editor.suggest.showEvents","When enabled IntelliSense shows `event`-suggestions.")},"editor.suggest.showOperators":{type:"boolean",default:!0,markdownDescription:b.kg("editor.suggest.showOperators","When enabled IntelliSense shows `operator`-suggestions.")},"editor.suggest.showUnits":{type:"boolean",default:!0,markdownDescription:b.kg("editor.suggest.showUnits","When enabled IntelliSense shows `unit`-suggestions.")},"editor.suggest.showValues":{type:"boolean",default:!0,markdownDescription:b.kg("editor.suggest.showValues","When enabled IntelliSense shows `value`-suggestions.")},"editor.suggest.showConstants":{type:"boolean",default:!0,markdownDescription:b.kg("editor.suggest.showConstants","When enabled IntelliSense shows `constant`-suggestions.")},"editor.suggest.showEnums":{type:"boolean",default:!0,markdownDescription:b.kg("editor.suggest.showEnums","When enabled IntelliSense shows `enum`-suggestions.")},"editor.suggest.showEnumMembers":{type:"boolean",default:!0,markdownDescription:b.kg("editor.suggest.showEnumMembers","When enabled IntelliSense shows `enumMember`-suggestions.")},"editor.suggest.showKeywords":{type:"boolean",default:!0,markdownDescription:b.kg("editor.suggest.showKeywords","When enabled IntelliSense shows `keyword`-suggestions.")},"editor.suggest.showWords":{type:"boolean",default:!0,markdownDescription:b.kg("editor.suggest.showTexts","When enabled IntelliSense shows `text`-suggestions.")},"editor.suggest.showColors":{type:"boolean",default:!0,markdownDescription:b.kg("editor.suggest.showColors","When enabled IntelliSense shows `color`-suggestions.")},"editor.suggest.showFiles":{type:"boolean",default:!0,markdownDescription:b.kg("editor.suggest.showFiles","When enabled IntelliSense shows `file`-suggestions.")},"editor.suggest.showReferences":{type:"boolean",default:!0,markdownDescription:b.kg("editor.suggest.showReferences","When enabled IntelliSense shows `reference`-suggestions.")},"editor.suggest.showCustomcolors":{type:"boolean",default:!0,markdownDescription:b.kg("editor.suggest.showCustomcolors","When enabled IntelliSense shows `customcolor`-suggestions.")},"editor.suggest.showFolders":{type:"boolean",default:!0,markdownDescription:b.kg("editor.suggest.showFolders","When enabled IntelliSense shows `folder`-suggestions.")},"editor.suggest.showTypeParameters":{type:"boolean",default:!0,markdownDescription:b.kg("editor.suggest.showTypeParameters","When enabled IntelliSense shows `typeParameter`-suggestions.")},"editor.suggest.showSnippets":{type:"boolean",default:!0,markdownDescription:b.kg("editor.suggest.showSnippets","When enabled IntelliSense shows `snippet`-suggestions.")},"editor.suggest.showUsers":{type:"boolean",default:!0,markdownDescription:b.kg("editor.suggest.showUsers","When enabled IntelliSense shows `user`-suggestions.")},"editor.suggest.showIssues":{type:"boolean",default:!0,markdownDescription:b.kg("editor.suggest.showIssues","When enabled IntelliSense shows `issues`-suggestions.")}})}validate(fe){if(!fe||typeof fe!="object")return this.defaultValue;const ze=fe;return{insertMode:D(ze.insertMode,this.defaultValue.insertMode,["insert","replace"]),filterGraceful:u(ze.filterGraceful,this.defaultValue.filterGraceful),snippetsPreventQuickSuggestions:u(ze.snippetsPreventQuickSuggestions,this.defaultValue.filterGraceful),localityBonus:u(ze.localityBonus,this.defaultValue.localityBonus),shareSuggestSelections:u(ze.shareSuggestSelections,this.defaultValue.shareSuggestSelections),showIcons:u(ze.showIcons,this.defaultValue.showIcons),showStatusBar:u(ze.showStatusBar,this.defaultValue.showStatusBar),preview:u(ze.preview,this.defaultValue.preview),previewMode:D(ze.previewMode,this.defaultValue.previewMode,["prefix","subword","subwordSmart"]),showInlineDetails:u(ze.showInlineDetails,this.defaultValue.showInlineDetails),showMethods:u(ze.showMethods,this.defaultValue.showMethods),showFunctions:u(ze.showFunctions,this.defaultValue.showFunctions),showConstructors:u(ze.showConstructors,this.defaultValue.showConstructors),showDeprecated:u(ze.showDeprecated,this.defaultValue.showDeprecated),showFields:u(ze.showFields,this.defaultValue.showFields),showVariables:u(ze.showVariables,this.defaultValue.showVariables),showClasses:u(ze.showClasses,this.defaultValue.showClasses),showStructs:u(ze.showStructs,this.defaultValue.showStructs),showInterfaces:u(ze.showInterfaces,this.defaultValue.showInterfaces),showModules:u(ze.showModules,this.defaultValue.showModules),showProperties:u(ze.showProperties,this.defaultValue.showProperties),showEvents:u(ze.showEvents,this.defaultValue.showEvents),showOperators:u(ze.showOperators,this.defaultValue.showOperators),showUnits:u(ze.showUnits,this.defaultValue.showUnits),showValues:u(ze.showValues,this.defaultValue.showValues),showConstants:u(ze.showConstants,this.defaultValue.showConstants),showEnums:u(ze.showEnums,this.defaultValue.showEnums),showEnumMembers:u(ze.showEnumMembers,this.defaultValue.showEnumMembers),showKeywords:u(ze.showKeywords,this.defaultValue.showKeywords),showWords:u(ze.showWords,this.defaultValue.showWords),showColors:u(ze.showColors,this.defaultValue.showColors),showFiles:u(ze.showFiles,this.defaultValue.showFiles),showReferences:u(ze.showReferences,this.defaultValue.showReferences),showFolders:u(ze.showFolders,this.defaultValue.showFolders),showTypeParameters:u(ze.showTypeParameters,this.defaultValue.showTypeParameters),showSnippets:u(ze.showSnippets,this.defaultValue.showSnippets),showUsers:u(ze.showUsers,this.defaultValue.showUsers),showIssues:u(ze.showIssues,this.defaultValue.showIssues)}}}class Ie extends p{constructor(){super(104,"smartSelect",{selectLeadingAndTrailingWhitespace:!0},{"editor.smartSelect.selectLeadingAndTrailingWhitespace":{description:b.kg("selectLeadingAndTrailingWhitespace","Whether leading and trailing whitespace should always be selected."),default:!0,type:"boolean"}})}validate(fe){return!fe||typeof fe!="object"?this.defaultValue:{selectLeadingAndTrailingWhitespace:u(fe.selectLeadingAndTrailingWhitespace,this.defaultValue.selectLeadingAndTrailingWhitespace)}}}class Ve extends h{constructor(){super(132)}compute(fe,ze,Et){return ze.get(83)?!0:fe.tabFocusMode}}function dt(yt){switch(yt){case"none":return 0;case"same":return 1;case"indent":return 2;case"deepIndent":return 3}}class bt extends h{constructor(){super(134)}compute(fe,ze,Et){const Ot=ze.get(133);return{isDominatedByLongLines:fe.isDominatedByLongLines,isWordWrapMinified:Ot.isWordWrapMinified,isViewportWrapping:Ot.isViewportWrapping,wrappingColumn:Ot.wrappingColumn}}}class Mt extends p{constructor(){const fe={enabled:!0};super(32,"dropIntoEditor",fe,{"editor.dropIntoEditor.enabled":{type:"boolean",default:fe.enabled,markdownDescription:b.kg("dropIntoEditor.enabled","Controls whether you can drag and drop a file into a text editor by holding down `shift` (instead of opening the file in an editor).")}})}validate(fe){return!fe||typeof fe!="object"?this.defaultValue:{enabled:u(fe.enabled,this.defaultValue.enabled)}}}const Ti={fontFamily:o.zx?"Menlo, Monaco, 'Courier New', monospace":o.j9?"'Droid Sans Mono', 'monospace', monospace":"Consolas, 'Courier New', monospace",fontWeight:"normal",fontSize:o.zx?12:14,lineHeight:0,letterSpacing:0},Ii=[];function ut(yt){return Ii[yt.id]=yt,yt}const Si={acceptSuggestionOnCommitCharacter:ut(new w(0,"acceptSuggestionOnCommitCharacter",!0,{markdownDescription:b.kg("acceptSuggestionOnCommitCharacter","Controls whether suggestions should be accepted on commit characters. For example, in JavaScript, the semi-colon (`; `) can be a commit character that accepts a suggestion and types that character.")})),acceptSuggestionOnEnter:ut(new x(1,"acceptSuggestionOnEnter","on",["on","smart","off"],{markdownEnumDescriptions:["",b.kg("acceptSuggestionOnEnterSmart","Only accept a suggestion with `Enter` when it makes a textual change."),""],markdownDescription:b.kg("acceptSuggestionOnEnter","Controls whether suggestions should be accepted on `Enter`, in addition to `Tab`. Helps to avoid ambiguity between inserting new lines or accepting suggestions.")})),accessibilitySupport:ut(new Y),accessibilityPageSize:ut(new m(3,"accessibilityPageSize",10,1,1073741824,{description:b.kg("accessibilityPageSize","Controls the number of lines in the editor that can be read out by a screen reader at once. When we detect a screen reader we automatically set the default to be 500. Warning: this has a performance implication for numbers larger than the default.")})),ariaLabel:ut(new k(4,"ariaLabel",b.kg("editorViewAccessibleLabel","Editor content"))),autoClosingBrackets:ut(new x(5,"autoClosingBrackets","languageDefined",["always","languageDefined","beforeWhitespace","never"],{enumDescriptions:["",b.kg("editor.autoClosingBrackets.languageDefined","Use language configurations to determine when to autoclose brackets."),b.kg("editor.autoClosingBrackets.beforeWhitespace","Autoclose brackets only when the cursor is to the left of whitespace."),""],description:b.kg("autoClosingBrackets","Controls whether the editor should automatically close brackets after the user adds an opening bracket.")})),autoClosingDelete:ut(new x(6,"autoClosingDelete","auto",["always","auto","never"],{enumDescriptions:["",b.kg("editor.autoClosingDelete.auto","Remove adjacent closing quotes or brackets only if they were automatically inserted."),""],description:b.kg("autoClosingDelete","Controls whether the editor should remove adjacent closing quotes or brackets when deleting.")})),autoClosingOvertype:ut(new x(7,"autoClosingOvertype","auto",["always","auto","never"],{enumDescriptions:["",b.kg("editor.autoClosingOvertype.auto","Type over closing quotes or brackets only if they were automatically inserted."),""],description:b.kg("autoClosingOvertype","Controls whether the editor should type over closing quotes or brackets.")})),autoClosingQuotes:ut(new x(8,"autoClosingQuotes","languageDefined",["always","languageDefined","beforeWhitespace","never"],{enumDescriptions:["",b.kg("editor.autoClosingQuotes.languageDefined","Use language configurations to determine when to autoclose quotes."),b.kg("editor.autoClosingQuotes.beforeWhitespace","Autoclose quotes only when the cursor is to the left of whitespace."),""],description:b.kg("autoClosingQuotes","Controls whether the editor should automatically close quotes after the user adds an opening quote.")})),autoIndent:ut(new A(9,"autoIndent",4,"full",["none","keep","brackets","advanced","full"],W,{enumDescriptions:[b.kg("editor.autoIndent.none","The editor will not insert indentation automatically."),b.kg("editor.autoIndent.keep","The editor will keep the current line's indentation."),b.kg("editor.autoIndent.brackets","The editor will keep the current line's indentation and honor language defined brackets."),b.kg("editor.autoIndent.advanced","The editor will keep the current line's indentation, honor language defined brackets and invoke special onEnterRules defined by languages."),b.kg("editor.autoIndent.full","The editor will keep the current line's indentation, honor language defined brackets, invoke special onEnterRules defined by languages, and honor indentationRules defined by languages.")],description:b.kg("autoIndent","Controls whether the editor should automatically adjust the indentation when users type, paste, move or indent lines.")})),automaticLayout:ut(new w(10,"automaticLayout",!1)),autoSurround:ut(new x(11,"autoSurround","languageDefined",["languageDefined","quotes","brackets","never"],{enumDescriptions:[b.kg("editor.autoSurround.languageDefined","Use language configurations to determine when to automatically surround selections."),b.kg("editor.autoSurround.quotes","Surround with quotes but not brackets."),b.kg("editor.autoSurround.brackets","Surround with brackets but not quotes."),""],description:b.kg("autoSurround","Controls whether the editor should automatically surround selections when typing quotes or brackets.")})),bracketPairColorization:ut(new Ye),bracketPairGuides:ut(new ht),stickyTabStops:ut(new w(106,"stickyTabStops",!1,{description:b.kg("stickyTabStops","Emulate selection behavior of tab characters when using spaces for indentation. Selection will stick to tab stops.")})),codeLens:ut(new w(14,"codeLens",!0,{description:b.kg("codeLens","Controls whether the editor shows CodeLens.")})),codeLensFontFamily:ut(new k(15,"codeLensFontFamily","",{description:b.kg("codeLensFontFamily","Controls the font family for CodeLens.")})),codeLensFontSize:ut(new m(16,"codeLensFontSize",0,0,100,{type:"number",default:0,minimum:0,maximum:100,markdownDescription:b.kg("codeLensFontSize","Controls the font size in pixels for CodeLens. When set to `0`, 90% of `#editor.fontSize#` is used.")})),colorDecorators:ut(new w(17,"colorDecorators",!0,{description:b.kg("colorDecorators","Controls whether the editor should render the inline color decorators and color picker.")})),columnSelection:ut(new w(18,"columnSelection",!1,{description:b.kg("columnSelection","Enable that the selection with the mouse and keys is doing column selection.")})),comments:ut(new ne),contextmenu:ut(new w(20,"contextmenu",!0)),copyWithSyntaxHighlighting:ut(new w(21,"copyWithSyntaxHighlighting",!0,{description:b.kg("copyWithSyntaxHighlighting","Controls whether syntax highlighting should be copied into the clipboard.")})),cursorBlinking:ut(new A(22,"cursorBlinking",1,"blink",["blink","smooth","phase","expand","solid"],j,{description:b.kg("cursorBlinking","Control the cursor animation style.")})),cursorSmoothCaretAnimation:ut(new w(23,"cursorSmoothCaretAnimation",!1,{description:b.kg("cursorSmoothCaretAnimation","Controls whether the smooth caret animation should be enabled.")})),cursorStyle:ut(new A(24,"cursorStyle",Q.Line,"line",["line","block","underline","line-thin","block-outline","underline-thin"],X,{description:b.kg("cursorStyle","Controls the cursor style.")})),cursorSurroundingLines:ut(new m(25,"cursorSurroundingLines",0,0,1073741824,{description:b.kg("cursorSurroundingLines","Controls the minimal number of visible leading and trailing lines surrounding the cursor. Known as 'scrollOff' or 'scrollOffset' in some other editors.")})),cursorSurroundingLinesStyle:ut(new x(26,"cursorSurroundingLinesStyle","default",["default","all"],{enumDescriptions:[b.kg("cursorSurroundingLinesStyle.default","`cursorSurroundingLines` is enforced only when triggered via the keyboard or API."),b.kg("cursorSurroundingLinesStyle.all","`cursorSurroundingLines` is enforced always.")],description:b.kg("cursorSurroundingLinesStyle","Controls when `cursorSurroundingLines` should be enforced.")})),cursorWidth:ut(new m(27,"cursorWidth",0,0,1073741824,{markdownDescription:b.kg("cursorWidth","Controls the width of the cursor when `#editor.cursorStyle#` is set to `line`.")})),disableLayerHinting:ut(new w(28,"disableLayerHinting",!1)),disableMonospaceOptimizations:ut(new w(29,"disableMonospaceOptimizations",!1)),domReadOnly:ut(new w(30,"domReadOnly",!1)),dragAndDrop:ut(new w(31,"dragAndDrop",!0,{description:b.kg("dragAndDrop","Controls whether the editor should allow moving selections via drag and drop.")})),emptySelectionClipboard:ut(new H),dropIntoEditor:ut(new Mt),experimental:ut(new Ke),extraEditorClassName:ut(new k(35,"extraEditorClassName","")),fastScrollSensitivity:ut(new v(36,"fastScrollSensitivity",5,yt=>yt<=0?5:yt,{markdownDescription:b.kg("fastScrollSensitivity","Scrolling speed multiplier when pressing `Alt`.")})),find:ut(new Z),fixedOverflowWidgets:ut(new w(38,"fixedOverflowWidgets",!1)),folding:ut(new w(39,"folding",!0,{description:b.kg("folding","Controls whether the editor has code folding enabled.")})),foldingStrategy:ut(new x(40,"foldingStrategy","auto",["auto","indentation"],{enumDescriptions:[b.kg("foldingStrategy.auto","Use a language-specific folding strategy if available, else the indentation-based one."),b.kg("foldingStrategy.indentation","Use the indentation-based folding strategy.")],description:b.kg("foldingStrategy","Controls the strategy for computing folding ranges.")})),foldingHighlight:ut(new w(41,"foldingHighlight",!0,{description:b.kg("foldingHighlight","Controls whether the editor should highlight folded ranges.")})),foldingImportsByDefault:ut(new w(42,"foldingImportsByDefault",!1,{description:b.kg("foldingImportsByDefault","Controls whether the editor automatically collapses import ranges.")})),foldingMaximumRegions:ut(new m(43,"foldingMaximumRegions",5e3,10,65e3,{description:b.kg("foldingMaximumRegions","The maximum number of foldable regions. Increasing this value may result in the editor becoming less responsive when the current source has a large number of foldable regions.")})),unfoldOnClickAfterEndOfLine:ut(new w(44,"unfoldOnClickAfterEndOfLine",!1,{description:b.kg("unfoldOnClickAfterEndOfLine","Controls whether clicking on the empty content after a folded line will unfold the line.")})),fontFamily:ut(new k(45,"fontFamily",Ti.fontFamily,{description:b.kg("fontFamily","Controls the font family.")})),fontInfo:ut(new G),fontLigatures2:ut(new N),fontSize:ut(new O),fontWeight:ut(new te),formatOnPaste:ut(new w(50,"formatOnPaste",!1,{description:b.kg("formatOnPaste","Controls whether the editor should automatically format the pasted content. A formatter must be available and the formatter should be able to format a range in a document.")})),formatOnType:ut(new w(51,"formatOnType",!1,{description:b.kg("formatOnType","Controls whether the editor should automatically format the line after typing.")})),glyphMargin:ut(new w(52,"glyphMargin",!0,{description:b.kg("glyphMargin","Controls whether the editor should render the vertical glyph margin. Glyph margin is mostly used for debugging.")})),gotoLocation:ut(new oe),hideCursorInOverviewRuler:ut(new w(54,"hideCursorInOverviewRuler",!1,{description:b.kg("hideCursorInOverviewRuler","Controls whether the cursor should be hidden in the overview ruler.")})),hover:ut(new ue),inDiffEditor:ut(new w(56,"inDiffEditor",!1)),letterSpacing:ut(new v(58,"letterSpacing",Ti.letterSpacing,yt=>v.clamp(yt,-5,20),{description:b.kg("letterSpacing","Controls the letter spacing in pixels.")})),lightbulb:ut(new Qe),lineDecorationsWidth:ut(new l(60,"lineDecorationsWidth",10)),lineHeight:ut(new Me),lineNumbers:ut(new Ge),lineNumbersMinChars:ut(new m(63,"lineNumbersMinChars",5,1,300)),linkedEditing:ut(new w(64,"linkedEditing",!1,{description:b.kg("linkedEditing","Controls whether the editor has linked editing enabled. Depending on the language, related symbols, e.g. HTML tags, are updated while editing.")})),links:ut(new w(65,"links",!0,{description:b.kg("links","Controls whether the editor should detect links and make them clickable.")})),matchBrackets:ut(new x(66,"matchBrackets","always",["always","near","never"],{description:b.kg("matchBrackets","Highlight matching brackets.")})),minimap:ut(new ce),mouseStyle:ut(new x(68,"mouseStyle","text",["text","default","copy"])),mouseWheelScrollSensitivity:ut(new v(69,"mouseWheelScrollSensitivity",1,yt=>yt===0?1:yt,{markdownDescription:b.kg("mouseWheelScrollSensitivity","A multiplier to be used on the `deltaX` and `deltaY` of mouse wheel scroll events.")})),mouseWheelZoom:ut(new w(70,"mouseWheelZoom",!1,{markdownDescription:b.kg("mouseWheelZoom","Zoom the font of the editor when using mouse wheel and holding `Ctrl`.")})),multiCursorMergeOverlapping:ut(new w(71,"multiCursorMergeOverlapping",!0,{description:b.kg("multiCursorMergeOverlapping","Merge multiple cursors when they are overlapping.")})),multiCursorModifier:ut(new A(72,"multiCursorModifier","altKey","alt",["ctrlCmd","alt"],pe,{markdownEnumDescriptions:[b.kg("multiCursorModifier.ctrlCmd","Maps to `Control` on Windows and Linux and to `Command` on macOS."),b.kg("multiCursorModifier.alt","Maps to `Alt` on Windows and Linux and to `Option` on macOS.")],markdownDescription:b.kg({key:"multiCursorModifier",comment:["- `ctrlCmd` refers to a value the setting can take and should not be localized.","- `Control` and `Command` refer to the modifier keys Ctrl or Cmd on the keyboard and can be localized."]},"The modifier to be used to add multiple cursors with the mouse. The Go to Definition and Open Link mouse gestures will adapt such that they do not conflict with the [multicursor modifier](https://code.visualstudio.com/docs/editor/codebasics#_multicursor-modifier).")})),multiCursorPaste:ut(new x(73,"multiCursorPaste","spread",["spread","full"],{markdownEnumDescriptions:[b.kg("multiCursorPaste.spread","Each cursor pastes a single line of the text."),b.kg("multiCursorPaste.full","Each cursor pastes the full text.")],markdownDescription:b.kg("multiCursorPaste","Controls pasting when the line count of the pasted text matches the cursor count.")})),occurrencesHighlight:ut(new w(74,"occurrencesHighlight",!0,{description:b.kg("occurrencesHighlight","Controls whether the editor should highlight semantic symbol occurrences.")})),overviewRulerBorder:ut(new w(75,"overviewRulerBorder",!0,{description:b.kg("overviewRulerBorder","Controls whether a border should be drawn around the overview ruler.")})),overviewRulerLanes:ut(new m(76,"overviewRulerLanes",3,0,3)),padding:ut(new be),parameterHints:ut(new ge),peekWidgetDefaultFocus:ut(new x(79,"peekWidgetDefaultFocus","tree",["tree","editor"],{enumDescriptions:[b.kg("peekWidgetDefaultFocus.tree","Focus the tree when opening peek"),b.kg("peekWidgetDefaultFocus.editor","Focus the editor when opening peek")],description:b.kg("peekWidgetDefaultFocus","Controls whether to focus the inline editor or the tree in the peek widget.")})),definitionLinkOpensInPeek:ut(new w(80,"definitionLinkOpensInPeek",!1,{description:b.kg("definitionLinkOpensInPeek","Controls whether the Go to Definition mouse gesture always opens the peek widget.")})),quickSuggestions:ut(new We),quickSuggestionsDelay:ut(new m(82,"quickSuggestionsDelay",10,0,1073741824,{description:b.kg("quickSuggestionsDelay","Controls the delay in milliseconds after which quick suggestions will show up.")})),readOnly:ut(new w(83,"readOnly",!1)),renameOnType:ut(new w(84,"renameOnType",!1,{description:b.kg("renameOnType","Controls whether the editor auto renames on type."),markdownDeprecationMessage:b.kg("renameOnTypeDeprecate","Deprecated, use `editor.linkedEditing` instead.")})),renderControlCharacters:ut(new w(85,"renderControlCharacters",!0,{description:b.kg("renderControlCharacters","Controls whether the editor should render control characters."),restricted:!0})),renderFinalNewline:ut(new w(86,"renderFinalNewline",!0,{description:b.kg("renderFinalNewline","Render last line number when the file ends with a newline.")})),renderLineHighlight:ut(new x(87,"renderLineHighlight","line",["none","gutter","line","all"],{enumDescriptions:["","","",b.kg("renderLineHighlight.all","Highlights both the gutter and the current line.")],description:b.kg("renderLineHighlight","Controls how the editor should render the current line highlight.")})),renderLineHighlightOnlyWhenFocus:ut(new w(88,"renderLineHighlightOnlyWhenFocus",!1,{description:b.kg("renderLineHighlightOnlyWhenFocus","Controls if the editor should render the current line highlight only when the editor is focused.")})),renderValidationDecorations:ut(new x(89,"renderValidationDecorations","editable",["editable","on","off"])),renderWhitespace:ut(new x(90,"renderWhitespace","selection",["none","boundary","selection","trailing","all"],{enumDescriptions:["",b.kg("renderWhitespace.boundary","Render whitespace characters except for single spaces between words."),b.kg("renderWhitespace.selection","Render whitespace characters only on selected text."),b.kg("renderWhitespace.trailing","Render only trailing whitespace characters."),""],description:b.kg("renderWhitespace","Controls how the editor should render whitespace characters.")})),revealHorizontalRightPadding:ut(new m(91,"revealHorizontalRightPadding",30,0,1e3)),roundedSelection:ut(new w(92,"roundedSelection",!0,{description:b.kg("roundedSelection","Controls whether selections should have rounded corners.")})),rulers:ut(new he),scrollbar:ut(new $e),scrollBeyondLastColumn:ut(new m(95,"scrollBeyondLastColumn",4,0,1073741824,{description:b.kg("scrollBeyondLastColumn","Controls the number of extra characters beyond which the editor will scroll horizontally.")})),scrollBeyondLastLine:ut(new w(96,"scrollBeyondLastLine",!0,{description:b.kg("scrollBeyondLastLine","Controls whether the editor will scroll beyond the last line.")})),scrollPredominantAxis:ut(new w(97,"scrollPredominantAxis",!0,{description:b.kg("scrollPredominantAxis","Scroll only along the predominant axis when scrolling both vertically and horizontally at the same time. Prevents horizontal drift when scrolling vertically on a trackpad.")})),selectionClipboard:ut(new w(98,"selectionClipboard",!0,{description:b.kg("selectionClipboard","Controls whether the Linux primary clipboard should be supported."),included:o.j9})),selectionHighlight:ut(new w(99,"selectionHighlight",!0,{description:b.kg("selectionHighlight","Controls whether the editor should highlight matches similar to the selection.")})),selectOnLineNumbers:ut(new w(100,"selectOnLineNumbers",!0)),showFoldingControls:ut(new x(101,"showFoldingControls","mouseover",["always","never","mouseover"],{enumDescriptions:[b.kg("showFoldingControls.always","Always show the folding controls."),b.kg("showFoldingControls.never","Never show the folding controls and reduce the gutter size."),b.kg("showFoldingControls.mouseover","Only show the folding controls when the mouse is over the gutter.")],description:b.kg("showFoldingControls","Controls when the folding controls on the gutter are shown.")})),showUnused:ut(new w(102,"showUnused",!0,{description:b.kg("showUnused","Controls fading out of unused code.")})),showDeprecated:ut(new w(128,"showDeprecated",!0,{description:b.kg("showDeprecated","Controls strikethrough deprecated variables.")})),inlayHints:ut(new Se),snippetSuggestions:ut(new x(103,"snippetSuggestions","inline",["top","bottom","inline","none"],{enumDescriptions:[b.kg("snippetSuggestions.top","Show snippet suggestions on top of other suggestions."),b.kg("snippetSuggestions.bottom","Show snippet suggestions below other suggestions."),b.kg("snippetSuggestions.inline","Show snippets suggestions with other suggestions."),b.kg("snippetSuggestions.none","Do not show snippet suggestions.")],description:b.kg("snippetSuggestions","Controls whether snippets are shown with other suggestions and how they are sorted.")})),smartSelect:ut(new Ie),smoothScrolling:ut(new w(105,"smoothScrolling",!1,{description:b.kg("smoothScrolling","Controls whether the editor will scroll using an animation.")})),stopRenderingLineAfter:ut(new m(107,"stopRenderingLineAfter",1e4,-1,1073741824)),suggest:ut(new Rt),inlineSuggest:ut(new tt),suggestFontSize:ut(new m(109,"suggestFontSize",0,0,1e3,{markdownDescription:b.kg("suggestFontSize","Font size for the suggest widget. When set to {0}, the value of {1} is used.","`0`","`#editor.fontSize#`")})),suggestLineHeight:ut(new m(110,"suggestLineHeight",0,0,1e3,{markdownDescription:b.kg("suggestLineHeight","Line height for the suggest widget. When set to {0}, the value of {1} is used. The minimum value is 8.","`0`","`#editor.lineHeight#`")})),suggestOnTriggerCharacters:ut(new w(111,"suggestOnTriggerCharacters",!0,{description:b.kg("suggestOnTriggerCharacters","Controls whether suggestions should automatically show up when typing trigger characters.")})),suggestSelection:ut(new x(112,"suggestSelection","first",["first","recentlyUsed","recentlyUsedByPrefix"],{markdownEnumDescriptions:[b.kg("suggestSelection.first","Always select the first suggestion."),b.kg("suggestSelection.recentlyUsed","Select recent suggestions unless further typing selects one, e.g. `console.| -> console.log` because `log` has been completed recently."),b.kg("suggestSelection.recentlyUsedByPrefix","Select suggestions based on previous prefixes that have completed those suggestions, e.g. `co -> console` and `con -> const`.")],description:b.kg("suggestSelection","Controls how suggestions are pre-selected when showing the suggest list.")})),tabCompletion:ut(new x(113,"tabCompletion","off",["on","off","onlySnippets"],{enumDescriptions:[b.kg("tabCompletion.on","Tab complete will insert the best matching suggestion when pressing tab."),b.kg("tabCompletion.off","Disable tab completions."),b.kg("tabCompletion.onlySnippets","Tab complete snippets when their prefix match. Works best when 'quickSuggestions' aren't enabled.")],description:b.kg("tabCompletion","Enables tab completions.")})),tabIndex:ut(new m(114,"tabIndex",0,-1,1073741824)),unicodeHighlight:ut(new Wt),unusualLineTerminators:ut(new x(116,"unusualLineTerminators","prompt",["auto","off","prompt"],{enumDescriptions:[b.kg("unusualLineTerminators.auto","Unusual line terminators are automatically removed."),b.kg("unusualLineTerminators.off","Unusual line terminators are ignored."),b.kg("unusualLineTerminators.prompt","Unusual line terminators prompt to be removed.")],description:b.kg("unusualLineTerminators","Remove unusual line terminators that might cause problems.")})),useShadowDOM:ut(new w(117,"useShadowDOM",!0)),useTabStops:ut(new w(118,"useTabStops",!0,{description:b.kg("useTabStops","Inserting and deleting whitespace follows tab stops.")})),wordSeparators:ut(new k(119,"wordSeparators",K.J3,{description:b.kg("wordSeparators","Characters that will be used as word separators when doing word related navigations or operations.")})),wordWrap:ut(new x(120,"wordWrap","off",["off","on","wordWrapColumn","bounded"],{markdownEnumDescriptions:[b.kg("wordWrap.off","Lines will never wrap."),b.kg("wordWrap.on","Lines will wrap at the viewport width."),b.kg({key:"wordWrap.wordWrapColumn",comment:["- `editor.wordWrapColumn` refers to a different setting and should not be localized."]},"Lines will wrap at `#editor.wordWrapColumn#`."),b.kg({key:"wordWrap.bounded",comment:["- viewport means the edge of the visible window size.","- `editor.wordWrapColumn` refers to a different setting and should not be localized."]},"Lines will wrap at the minimum of viewport and `#editor.wordWrapColumn#`.")],description:b.kg({key:"wordWrap",comment:["- 'off', 'on', 'wordWrapColumn' and 'bounded' refer to values the setting can take and should not be localized.","- `editor.wordWrapColumn` refers to a different setting and should not be localized."]},"Controls how lines should wrap.")})),wordWrapBreakAfterCharacters:ut(new k(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:ut(new k(122,"wordWrapBreakBeforeCharacters","([{\u2018\u201C\u3008\u300A\u300C\u300E\u3010\u3014\uFF08\uFF3B\uFF5B\uFF62\xA3\xA5\uFF04\uFFE1\uFFE5+\uFF0B")),wordWrapColumn:ut(new m(123,"wordWrapColumn",80,1,1073741824,{markdownDescription:b.kg({key:"wordWrapColumn",comment:["- `editor.wordWrap` refers to a different setting and should not be localized.","- 'wordWrapColumn' and 'bounded' refer to values the different setting can take and should not be localized."]},"Controls the wrapping column of the editor when `#editor.wordWrap#` is `wordWrapColumn` or `bounded`.")})),wordWrapOverride1:ut(new x(124,"wordWrapOverride1","inherit",["off","on","inherit"])),wordWrapOverride2:ut(new x(125,"wordWrapOverride2","inherit",["off","on","inherit"])),wrappingIndent:ut(new A(126,"wrappingIndent",1,"same",["none","same","indent","deepIndent"],dt,{enumDescriptions:[b.kg("wrappingIndent.none","No indentation. Wrapped lines begin at column 1."),b.kg("wrappingIndent.same","Wrapped lines get the same indentation as the parent."),b.kg("wrappingIndent.indent","Wrapped lines get +1 indentation toward the parent."),b.kg("wrappingIndent.deepIndent","Wrapped lines get +2 indentation toward the parent.")],description:b.kg("wrappingIndent","Controls the indentation of wrapped lines.")})),wrappingStrategy:ut(new x(127,"wrappingStrategy","simple",["simple","advanced"],{enumDescriptions:[b.kg("wrappingStrategy.simple","Assumes that all characters are of the same width. This is a fast algorithm that works correctly for monospace fonts and certain scripts (like Latin characters) where glyphs are of equal width."),b.kg("wrappingStrategy.advanced","Delegates wrapping points computation to the browser. This is a slow algorithm, that might cause freezes for large files, but it works correctly in all cases.")],description:b.kg("wrappingStrategy","Controls the algorithm that computes wrapping points.")})),editorClassName:ut(new R),pixelRatio:ut(new ke),tabFocusMode:ut(new Ve),layoutInfo:ut(new E),wrappingInfo:ut(new bt)}},66638:(rt,ye,y)=>{y.d(ye,{Np:()=>K,jA:()=>$,z9:()=>o});var b=y(12596);function o(L){return L&&typeof L.getEditorType=="function"?L.getEditorType()===b._.ICodeEditor:!1}function K(L){return L&&typeof L.getEditorType=="function"?L.getEditorType()===b._.IDiffEditor:!1}function $(L){return o(L)?L:K(L)?L.getModifiedEditor():null}},66726:(rt,ye,y)=>{y.d(ye,{N:()=>$,v:()=>K});var b=y(83312);const o=[];function K(L,U,P){U instanceof b.d||(U=new b.d(U,[],P)),o.push([L,U])}function $(){return o}},67003:(rt,ye,y)=>{y.d(ye,{U:()=>C,X:()=>w});var b=y(14333),o=y(86843),K=y(63781),$=y(13338),L=y(94901),U=y(2106),P=y(10998),B=y(62992),T=y(94513),p=y(79359);const d={separatorBorder:L.Q1.transparent};class g{constructor(v,k,D,x){this.container=v,this.view=k,this.disposable=x,this._cachedVisibleSize=void 0,typeof D=="number"?(this._size=D,this._cachedVisibleSize=void 0,v.classList.add("visible")):(this._size=0,this._cachedVisibleSize=D.cachedVisibleSize)}set size(v){this._size=v}get size(){return this._size}get visible(){return typeof this._cachedVisibleSize>"u"}setVisible(v,k){var D,x;v!==this.visible&&(v?(this.size=(0,B.qE)(this._cachedVisibleSize,this.viewMinimumSize,this.viewMaximumSize),this._cachedVisibleSize=void 0):(this._cachedVisibleSize=typeof k=="number"?k:this.size,this.size=0),this.container.classList.toggle("visible",v),(x=(D=this.view).setVisible)===null||x===void 0||x.call(D,v))}get minimumSize(){return this.visible?this.view.minimumSize:0}get viewMinimumSize(){return this.view.minimumSize}get maximumSize(){return this.visible?this.view.maximumSize:0}get viewMaximumSize(){return this.view.maximumSize}get priority(){return this.view.priority}get snap(){return!!this.view.snap}set enabled(v){this.container.style.pointerEvents=v?"":"none"}layout(v,k){this.layoutContainer(v),this.view.layout(this.size,v,k)}dispose(){return this.disposable.dispose(),this.view}}class h extends g{layoutContainer(v){this.container.style.top=`${v}px`,this.container.style.height=`${this.size}px`}}class l extends g{layoutContainer(v){this.container.style.left=`${v}px`,this.container.style.width=`${this.size}px`}}var u;(function(m){m[m.Idle=0]="Idle",m[m.Busy=1]="Busy"})(u||(u={}));var w;(function(m){m.Distribute={type:"distribute"};function v(D){return{type:"split",index:D}}m.Split=v;function k(D){return{type:"invisible",cachedVisibleSize:D}}m.Invisible=k})(w||(w={}));class C extends P.jG{constructor(v,k={}){var D,x,A,W,Y;super(),this.size=0,this.contentSize=0,this.proportions=void 0,this.viewItems=[],this.sashItems=[],this.state=u.Idle,this._onDidSashChange=this._register(new U.vl),this._onDidSashReset=this._register(new U.vl),this._startSnappingEnabled=!0,this._endSnappingEnabled=!0,this.onDidSashChange=this._onDidSashChange.event,this.onDidSashReset=this._onDidSashReset.event,this.orientation=(D=k.orientation)!==null&&D!==void 0?D:0,this.inverseAltBehavior=(x=k.inverseAltBehavior)!==null&&x!==void 0?x:!1,this.proportionalLayout=(A=k.proportionalLayout)!==null&&A!==void 0?A:!0,this.getSashOrthogonalSize=k.getSashOrthogonalSize,this.el=document.createElement("div"),this.el.classList.add("monaco-split-view2"),this.el.classList.add(this.orientation===0?"vertical":"horizontal"),v.appendChild(this.el),this.sashContainer=(0,b.BC)(this.el,(0,b.$)(".sash-container")),this.viewContainer=(0,b.$)(".split-view-container"),this.scrollable=new T.yE({forceIntegerValues:!0,smoothScrollDuration:125,scheduleAtNextAnimationFrame:b.PG}),this.scrollableElement=this._register(new K.oO(this.viewContainer,{vertical:this.orientation===0?(W=k.scrollbarVisibility)!==null&&W!==void 0?W:1:2,horizontal:this.orientation===1?(Y=k.scrollbarVisibility)!==null&&Y!==void 0?Y:1:2},this.scrollable)),this.onDidScroll=this.scrollableElement.onScroll,this._register(this.onDidScroll(ne=>{this.viewContainer.scrollTop=ne.scrollTop,this.viewContainer.scrollLeft=ne.scrollLeft})),(0,b.BC)(this.el,this.scrollableElement.getDomNode()),this.style(k.styles||d),k.descriptor&&(this.size=k.descriptor.size,k.descriptor.views.forEach((ne,j)=>{const Q=p.b0(ne.visible)||ne.visible?ne.size:{type:"invisible",cachedVisibleSize:ne.size},X=ne.view;this.doAddView(X,Q,j,!0)}),this.contentSize=this.viewItems.reduce((ne,j)=>ne+j.size,0),this.saveProportions())}get orthogonalStartSash(){return this._orthogonalStartSash}get orthogonalEndSash(){return this._orthogonalEndSash}get startSnappingEnabled(){return this._startSnappingEnabled}get endSnappingEnabled(){return this._endSnappingEnabled}set orthogonalStartSash(v){for(const k of this.sashItems)k.sash.orthogonalStartSash=v;this._orthogonalStartSash=v}set orthogonalEndSash(v){for(const k of this.sashItems)k.sash.orthogonalEndSash=v;this._orthogonalEndSash=v}set startSnappingEnabled(v){this._startSnappingEnabled!==v&&(this._startSnappingEnabled=v,this.updateSashEnablement())}set endSnappingEnabled(v){this._endSnappingEnabled!==v&&(this._endSnappingEnabled=v,this.updateSashEnablement())}style(v){v.separatorBorder.isTransparent()?(this.el.classList.remove("separator-border"),this.el.style.removeProperty("--separator-border")):(this.el.classList.add("separator-border"),this.el.style.setProperty("--separator-border",v.separatorBorder.toString()))}addView(v,k,D=this.viewItems.length,x){this.doAddView(v,k,D,x)}layout(v,k){const D=Math.max(this.size,this.contentSize);if(this.size=v,this.layoutContext=k,this.proportions)for(let x=0;x<this.viewItems.length;x++){const A=this.viewItems[x];A.size=(0,B.qE)(Math.round(this.proportions[x]*v),A.minimumSize,A.maximumSize)}else{const x=(0,$.y1)(this.viewItems.length),A=x.filter(Y=>this.viewItems[Y].priority===1),W=x.filter(Y=>this.viewItems[Y].priority===2);this.resize(this.viewItems.length-1,v-D,void 0,A,W)}this.distributeEmptySpace(),this.layoutViews()}saveProportions(){this.proportionalLayout&&this.contentSize>0&&(this.proportions=this.viewItems.map(v=>v.size/this.contentSize))}onSashStart({sash:v,start:k,alt:D}){for(const Y of this.viewItems)Y.enabled=!1;const x=this.sashItems.findIndex(Y=>Y.sash===v),A=(0,P.qE)((0,b.ko)(document.body,"keydown",Y=>W(this.sashDragState.current,Y.altKey)),(0,b.ko)(document.body,"keyup",()=>W(this.sashDragState.current,!1))),W=(Y,ne)=>{const j=this.viewItems.map(Z=>Z.size);let Q=Number.NEGATIVE_INFINITY,X=Number.POSITIVE_INFINITY;if(this.inverseAltBehavior&&(ne=!ne),ne)if(x===this.sashItems.length-1){const N=this.viewItems[x];Q=(N.minimumSize-N.size)/2,X=(N.maximumSize-N.size)/2}else{const N=this.viewItems[x+1];Q=(N.size-N.maximumSize)/2,X=(N.size-N.minimumSize)/2}let R,H;if(!ne){const Z=(0,$.y1)(x,-1),N=(0,$.y1)(x+1,this.viewItems.length),G=Z.reduce((Se,Me)=>Se+(this.viewItems[Me].minimumSize-j[Me]),0),O=Z.reduce((Se,Me)=>Se+(this.viewItems[Me].viewMaximumSize-j[Me]),0),te=N.length===0?Number.POSITIVE_INFINITY:N.reduce((Se,Me)=>Se+(j[Me]-this.viewItems[Me].minimumSize),0),oe=N.length===0?Number.NEGATIVE_INFINITY:N.reduce((Se,Me)=>Se+(j[Me]-this.viewItems[Me].viewMaximumSize),0),ue=Math.max(G,oe),E=Math.min(te,O),Qe=this.findFirstSnapIndex(Z),Ke=this.findFirstSnapIndex(N);if(typeof Qe=="number"){const Se=this.viewItems[Qe],Me=Math.floor(Se.viewMinimumSize/2);R={index:Qe,limitDelta:Se.visible?ue-Me:ue+Me,size:Se.size}}if(typeof Ke=="number"){const Se=this.viewItems[Ke],Me=Math.floor(Se.viewMinimumSize/2);H={index:Ke,limitDelta:Se.visible?E+Me:E-Me,size:Se.size}}}this.sashDragState={start:Y,current:Y,index:x,sizes:j,minDelta:Q,maxDelta:X,alt:ne,snapBefore:R,snapAfter:H,disposable:A}};W(k,D)}onSashChange({current:v}){const{index:k,start:D,sizes:x,alt:A,minDelta:W,maxDelta:Y,snapBefore:ne,snapAfter:j}=this.sashDragState;this.sashDragState.current=v;const Q=v-D,X=this.resize(k,Q,x,void 0,void 0,W,Y,ne,j);if(A){const R=k===this.sashItems.length-1,H=this.viewItems.map(oe=>oe.size),Z=R?k:k+1,N=this.viewItems[Z],G=N.size-N.maximumSize,O=N.size-N.minimumSize,te=R?k-1:k+1;this.resize(te,-X,H,void 0,void 0,G,O)}this.distributeEmptySpace(),this.layoutViews()}onSashEnd(v){this._onDidSashChange.fire(v),this.sashDragState.disposable.dispose(),this.saveProportions();for(const k of this.viewItems)k.enabled=!0}onViewChange(v,k){const D=this.viewItems.indexOf(v);D<0||D>=this.viewItems.length||(k=typeof k=="number"?k:v.size,k=(0,B.qE)(k,v.minimumSize,v.maximumSize),this.inverseAltBehavior&&D>0?(this.resize(D-1,Math.floor((v.size-k)/2)),this.distributeEmptySpace(),this.layoutViews()):(v.size=k,this.relayout([D],void 0)))}resizeView(v,k){if(this.state!==u.Idle)throw new Error("Cant modify splitview");if(this.state=u.Busy,v<0||v>=this.viewItems.length)return;const D=(0,$.y1)(this.viewItems.length).filter(Y=>Y!==v),x=[...D.filter(Y=>this.viewItems[Y].priority===1),v],A=D.filter(Y=>this.viewItems[Y].priority===2),W=this.viewItems[v];k=Math.round(k),k=(0,B.qE)(k,W.minimumSize,Math.min(W.maximumSize,this.size)),W.size=k,this.relayout(x,A),this.state=u.Idle}distributeViewSizes(){const v=[];let k=0;for(const Y of this.viewItems)Y.maximumSize-Y.minimumSize>0&&(v.push(Y),k+=Y.size);const D=Math.floor(k/v.length);for(const Y of v)Y.size=(0,B.qE)(D,Y.minimumSize,Y.maximumSize);const x=(0,$.y1)(this.viewItems.length),A=x.filter(Y=>this.viewItems[Y].priority===1),W=x.filter(Y=>this.viewItems[Y].priority===2);this.relayout(A,W)}getViewSize(v){return v<0||v>=this.viewItems.length?-1:this.viewItems[v].size}doAddView(v,k,D=this.viewItems.length,x){if(this.state!==u.Idle)throw new Error("Cant modify splitview");this.state=u.Busy;const A=(0,b.$)(".split-view-view");D===this.viewItems.length?this.viewContainer.appendChild(A):this.viewContainer.insertBefore(A,this.viewContainer.children.item(D));const W=v.onDidChange(R=>this.onViewChange(Q,R)),Y=(0,P.s)(()=>this.viewContainer.removeChild(A)),ne=(0,P.qE)(W,Y);let j;typeof k=="number"?j=k:k.type==="split"?j=this.getViewSize(k.index)/2:k.type==="invisible"?j={cachedVisibleSize:k.cachedVisibleSize}:j=v.minimumSize;const Q=this.orientation===0?new h(A,v,j,ne):new l(A,v,j,ne);if(this.viewItems.splice(D,0,Q),this.viewItems.length>1){const R={orthogonalStartSash:this.orthogonalStartSash,orthogonalEndSash:this.orthogonalEndSash},H=this.orientation===0?new o.m(this.sashContainer,{getHorizontalSashTop:Se=>this.getSashPosition(Se),getHorizontalSashWidth:this.getSashOrthogonalSize},Object.assign(Object.assign({},R),{orientation:1})):new o.m(this.sashContainer,{getVerticalSashLeft:Se=>this.getSashPosition(Se),getVerticalSashHeight:this.getSashOrthogonalSize},Object.assign(Object.assign({},R),{orientation:0})),Z=this.orientation===0?Se=>({sash:H,start:Se.startY,current:Se.currentY,alt:Se.altKey}):Se=>({sash:H,start:Se.startX,current:Se.currentX,alt:Se.altKey}),G=U.Jh.map(H.onDidStart,Z)(this.onSashStart,this),te=U.Jh.map(H.onDidChange,Z)(this.onSashChange,this),ue=U.Jh.map(H.onDidEnd,()=>this.sashItems.findIndex(Se=>Se.sash===H))(this.onSashEnd,this),E=H.onDidReset(()=>{const Se=this.sashItems.findIndex(ge=>ge.sash===H),Me=(0,$.y1)(Se,-1),ce=(0,$.y1)(Se+1,this.viewItems.length),pe=this.findFirstSnapIndex(Me),be=this.findFirstSnapIndex(ce);typeof pe=="number"&&!this.viewItems[pe].visible||typeof be=="number"&&!this.viewItems[be].visible||this._onDidSashReset.fire(Se)}),Qe=(0,P.qE)(G,te,ue,E,H),Ke={sash:H,disposable:Qe};this.sashItems.splice(D-1,0,Ke)}A.appendChild(v.element);let X;typeof k!="number"&&k.type==="split"&&(X=[k.index]),x||this.relayout([D],X),this.state=u.Idle,!x&&typeof k!="number"&&k.type==="distribute"&&this.distributeViewSizes()}relayout(v,k){const D=this.viewItems.reduce((x,A)=>x+A.size,0);this.resize(this.viewItems.length-1,this.size-D,void 0,v,k),this.distributeEmptySpace(),this.layoutViews(),this.saveProportions()}resize(v,k,D=this.viewItems.map(Q=>Q.size),x,A,W=Number.NEGATIVE_INFINITY,Y=Number.POSITIVE_INFINITY,ne,j){if(v<0||v>=this.viewItems.length)return 0;const Q=(0,$.y1)(v,-1),X=(0,$.y1)(v+1,this.viewItems.length);if(A)for(const Ke of A)(0,$._A)(Q,Ke),(0,$._A)(X,Ke);if(x)for(const Ke of x)(0,$.r7)(Q,Ke),(0,$.r7)(X,Ke);const R=Q.map(Ke=>this.viewItems[Ke]),H=Q.map(Ke=>D[Ke]),Z=X.map(Ke=>this.viewItems[Ke]),N=X.map(Ke=>D[Ke]),G=Q.reduce((Ke,Se)=>Ke+(this.viewItems[Se].minimumSize-D[Se]),0),O=Q.reduce((Ke,Se)=>Ke+(this.viewItems[Se].maximumSize-D[Se]),0),te=X.length===0?Number.POSITIVE_INFINITY:X.reduce((Ke,Se)=>Ke+(D[Se]-this.viewItems[Se].minimumSize),0),oe=X.length===0?Number.NEGATIVE_INFINITY:X.reduce((Ke,Se)=>Ke+(D[Se]-this.viewItems[Se].maximumSize),0),ue=Math.max(G,oe,W),E=Math.min(te,O,Y);let Qe=!1;if(ne){const Ke=this.viewItems[ne.index],Se=k>=ne.limitDelta;Qe=Se!==Ke.visible,Ke.setVisible(Se,ne.size)}if(!Qe&&j){const Ke=this.viewItems[j.index],Se=k<j.limitDelta;Qe=Se!==Ke.visible,Ke.setVisible(Se,j.size)}if(Qe)return this.resize(v,k,D,x,A,W,Y);k=(0,B.qE)(k,ue,E);for(let Ke=0,Se=k;Ke<R.length;Ke++){const Me=R[Ke],ce=(0,B.qE)(H[Ke]+Se,Me.minimumSize,Me.maximumSize),pe=ce-H[Ke];Se-=pe,Me.size=ce}for(let Ke=0,Se=k;Ke<Z.length;Ke++){const Me=Z[Ke],ce=(0,B.qE)(N[Ke]-Se,Me.minimumSize,Me.maximumSize),pe=ce-N[Ke];Se+=pe,Me.size=ce}return k}distributeEmptySpace(v){const k=this.viewItems.reduce((Y,ne)=>Y+ne.size,0);let D=this.size-k;const x=(0,$.y1)(this.viewItems.length-1,-1),A=x.filter(Y=>this.viewItems[Y].priority===1),W=x.filter(Y=>this.viewItems[Y].priority===2);for(const Y of W)(0,$._A)(x,Y);for(const Y of A)(0,$.r7)(x,Y);typeof v=="number"&&(0,$.r7)(x,v);for(let Y=0;D!==0&&Y<x.length;Y++){const ne=this.viewItems[x[Y]],j=(0,B.qE)(ne.size+D,ne.minimumSize,ne.maximumSize),Q=j-ne.size;D-=Q,ne.size=j}}layoutViews(){this.contentSize=this.viewItems.reduce((k,D)=>k+D.size,0);let v=0;for(const k of this.viewItems)k.layout(v,this.layoutContext),v+=k.size;this.sashItems.forEach(k=>k.sash.layout()),this.updateSashEnablement(),this.updateScrollableElement()}updateScrollableElement(){this.orientation===0?this.scrollableElement.setScrollDimensions({height:this.size,scrollHeight:this.contentSize}):this.scrollableElement.setScrollDimensions({width:this.size,scrollWidth:this.contentSize})}updateSashEnablement(){let v=!1;const k=this.viewItems.map(ne=>v=ne.size-ne.minimumSize>0||v);v=!1;const D=this.viewItems.map(ne=>v=ne.maximumSize-ne.size>0||v),x=[...this.viewItems].reverse();v=!1;const A=x.map(ne=>v=ne.size-ne.minimumSize>0||v).reverse();v=!1;const W=x.map(ne=>v=ne.maximumSize-ne.size>0||v).reverse();let Y=0;for(let ne=0;ne<this.sashItems.length;ne++){const{sash:j}=this.sashItems[ne],Q=this.viewItems[ne];Y+=Q.size;const X=!(k[ne]&&W[ne+1]),R=!(D[ne]&&A[ne+1]);if(X&&R){const H=(0,$.y1)(ne,-1),Z=(0,$.y1)(ne+1,this.viewItems.length),N=this.findFirstSnapIndex(H),G=this.findFirstSnapIndex(Z),O=typeof N=="number"&&!this.viewItems[N].visible,te=typeof G=="number"&&!this.viewItems[G].visible;O&&A[ne]&&(Y>0||this.startSnappingEnabled)?j.state=1:te&&k[ne]&&(Y<this.contentSize||this.endSnappingEnabled)?j.state=2:j.state=0}else X&&!R?j.state=1:!X&&R?j.state=2:j.state=3}}getSashPosition(v){let k=0;for(let D=0;D<this.sashItems.length;D++)if(k+=this.viewItems[D].size,this.sashItems[D].sash===v)return k;return 0}findFirstSnapIndex(v){for(const k of v){const D=this.viewItems[k];if(D.visible&&D.snap)return k}for(const k of v){const D=this.viewItems[k];if(D.visible&&D.maximumSize-D.minimumSize>0)return;if(!D.visible&&D.snap)return k}}dispose(){super.dispose(),(0,P.AS)(this.viewItems),this.viewItems=[],this.sashItems.forEach(v=>v.disposable.dispose()),this.sashItems=[]}}},67167:(rt,ye,y)=>{y.d(ye,{O:()=>$});var b=y(87110),o=y(79359);class K{constructor(){this.data=new Map}add(U,P){b.ok(o.Kg(U)),b.ok(o.Gv(P)),b.ok(!this.data.has(U),"There is already an extension with this id"),this.data.set(U,P)}as(U){return this.data.get(U)||null}}const $=new K},67954:(rt,ye,y)=>{y.d(ye,{hb:()=>Qe,B8:()=>Ge,MH:()=>E,_C:()=>R,Bm:()=>Q,B6:()=>ne,bm:()=>j,mh:()=>te,tX:()=>O});var b=y(14333),o=y(34061),K=y(87594),$=y(30474),L=y(59407);class U{constructor(he){this.spliceables=he}splice(he,Pe,$e){this.spliceables.forEach(it=>it.splice(he,Pe,$e))}}var P=y(13338),B=y(65958),T=y(94901),p=y(88846),d=y(2106),g=y(97669),h=y(10998),l=y(62992),u=y(71386),w=y(63339),C=y(79359);class m extends Error{constructor(he,Pe){super(`ListError [${he}] ${Pe}`)}}var v=y(83022),k=function(Ae,he,Pe,$e){var it=arguments.length,ft=it<3?he:$e===null?$e=Object.getOwnPropertyDescriptor(he,Pe):$e,Wt;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")ft=Reflect.decorate(Ae,he,Pe,$e);else for(var tt=Ae.length-1;tt>=0;tt--)(Wt=Ae[tt])&&(ft=(it<3?Wt(ft):it>3?Wt(he,Pe,ft):Wt(he,Pe))||ft);return it>3&&ft&&Object.defineProperty(he,Pe,ft),ft},D=function(Ae,he,Pe,$e){function it(ft){return ft instanceof Pe?ft:new Pe(function(Wt){Wt(ft)})}return new(Pe||(Pe=Promise))(function(ft,Wt){function tt(Lt){try{ht($e.next(Lt))}catch(Rt){Wt(Rt)}}function Ye(Lt){try{ht($e.throw(Lt))}catch(Rt){Wt(Rt)}}function ht(Lt){Lt.done?ft(Lt.value):it(Lt.value).then(tt,Ye)}ht(($e=$e.apply(Ae,he||[])).next())})};class x{constructor(he){this.trait=he,this.renderedElements=[]}get templateId(){return`template:${this.trait.name}`}renderTemplate(he){return he}renderElement(he,Pe,$e){const it=this.renderedElements.findIndex(ft=>ft.templateData===$e);if(it>=0){const ft=this.renderedElements[it];this.trait.unrender($e),ft.index=Pe}else{const ft={index:Pe,templateData:$e};this.renderedElements.push(ft)}this.trait.renderIndex(Pe,$e)}splice(he,Pe,$e){const it=[];for(const ft of this.renderedElements)ft.index<he?it.push(ft):ft.index>=he+Pe&&it.push({index:ft.index+$e-Pe,templateData:ft.templateData});this.renderedElements=it}renderIndexes(he){for(const{index:Pe,templateData:$e}of this.renderedElements)he.indexOf(Pe)>-1&&this.trait.renderIndex(Pe,$e)}disposeTemplate(he){const Pe=this.renderedElements.findIndex($e=>$e.templateData===he);Pe<0||this.renderedElements.splice(Pe,1)}}class A{constructor(he){this._trait=he,this.length=0,this.indexes=[],this.sortedIndexes=[],this._onChange=new d.vl,this.onChange=this._onChange.event}get name(){return this._trait}get renderer(){return new x(this)}splice(he,Pe,$e){var it;Pe=Math.max(0,Math.min(Pe,this.length-he));const ft=$e.length-Pe,Wt=he+Pe,tt=[...this.sortedIndexes.filter(ht=>ht<he),...$e.map((ht,Lt)=>ht?Lt+he:-1).filter(ht=>ht!==-1),...this.sortedIndexes.filter(ht=>ht>=Wt).map(ht=>ht+ft)],Ye=this.length+ft;if(this.sortedIndexes.length>0&&tt.length===0&&Ye>0){const ht=(it=this.sortedIndexes.find(Lt=>Lt>=he))!==null&&it!==void 0?it:Ye-1;tt.push(Math.min(ht,Ye-1))}this.renderer.splice(he,Pe,$e.length),this._set(tt,tt),this.length=Ye}renderIndex(he,Pe){Pe.classList.toggle(this._trait,this.contains(he))}unrender(he){he.classList.remove(this._trait)}set(he,Pe){return this._set(he,[...he].sort(be),Pe)}_set(he,Pe,$e){const it=this.indexes,ft=this.sortedIndexes;this.indexes=he,this.sortedIndexes=Pe;const Wt=ce(ft,he);return this.renderer.renderIndexes(Wt),this._onChange.fire({indexes:he,browserEvent:$e}),it}get(){return this.indexes}contains(he){return(0,P.El)(this.sortedIndexes,he,be)>=0}dispose(){(0,h.AS)(this._onChange)}}k([p.B],A.prototype,"renderer",null);class W extends A{constructor(he){super("selected"),this.setAriaSelected=he}renderIndex(he,Pe){super.renderIndex(he,Pe),this.setAriaSelected&&(this.contains(he)?Pe.setAttribute("aria-selected","true"):Pe.setAttribute("aria-selected","false"))}}class Y{constructor(he,Pe,$e){this.trait=he,this.view=Pe,this.identityProvider=$e}splice(he,Pe,$e){if(!this.identityProvider)return this.trait.splice(he,Pe,$e.map(()=>!1));const it=this.trait.get().map(Wt=>this.identityProvider.getId(this.view.element(Wt)).toString()),ft=$e.map(Wt=>it.indexOf(this.identityProvider.getId(Wt).toString())>-1);this.trait.splice(he,Pe,ft)}}function ne(Ae){return Ae.tagName==="INPUT"||Ae.tagName==="TEXTAREA"}function j(Ae){return Ae.classList.contains("monaco-editor")?!0:Ae.classList.contains("monaco-list")||!Ae.parentElement?!1:j(Ae.parentElement)}function Q(Ae){return Ae.tagName==="A"&&Ae.classList.contains("monaco-button")||Ae.tagName==="DIV"&&Ae.classList.contains("monaco-button-dropdown")?!0:Ae.classList.contains("monaco-list")||!Ae.parentElement?!1:Q(Ae.parentElement)}class X{constructor(he,Pe,$e){this.list=he,this.view=Pe,this.disposables=new h.Cm,this.multipleSelectionDisposables=new h.Cm,this.onKeyDown.filter(it=>it.keyCode===3).on(this.onEnter,this,this.disposables),this.onKeyDown.filter(it=>it.keyCode===16).on(this.onUpArrow,this,this.disposables),this.onKeyDown.filter(it=>it.keyCode===18).on(this.onDownArrow,this,this.disposables),this.onKeyDown.filter(it=>it.keyCode===11).on(this.onPageUpArrow,this,this.disposables),this.onKeyDown.filter(it=>it.keyCode===12).on(this.onPageDownArrow,this,this.disposables),this.onKeyDown.filter(it=>it.keyCode===9).on(this.onEscape,this,this.disposables),$e.multipleSelectionSupport!==!1&&this.onKeyDown.filter(it=>(w.zx?it.metaKey:it.ctrlKey)&&it.keyCode===31).on(this.onCtrlA,this,this.multipleSelectionDisposables)}get onKeyDown(){return this.disposables.add(d.Jh.chain(this.disposables.add(new o.f(this.view.domNode,"keydown")).event).filter(he=>!ne(he.target)).map(he=>new K.Z(he)))}updateOptions(he){he.multipleSelectionSupport!==void 0&&(this.multipleSelectionDisposables.clear(),he.multipleSelectionSupport&&this.onKeyDown.filter(Pe=>(w.zx?Pe.metaKey:Pe.ctrlKey)&&Pe.keyCode===31).on(this.onCtrlA,this,this.multipleSelectionDisposables))}onEnter(he){he.preventDefault(),he.stopPropagation(),this.list.setSelection(this.list.getFocus(),he.browserEvent)}onUpArrow(he){he.preventDefault(),he.stopPropagation(),this.list.focusPrevious(1,!1,he.browserEvent);const Pe=this.list.getFocus()[0];this.list.setAnchor(Pe),this.list.reveal(Pe),this.view.domNode.focus()}onDownArrow(he){he.preventDefault(),he.stopPropagation(),this.list.focusNext(1,!1,he.browserEvent);const Pe=this.list.getFocus()[0];this.list.setAnchor(Pe),this.list.reveal(Pe),this.view.domNode.focus()}onPageUpArrow(he){he.preventDefault(),he.stopPropagation(),this.list.focusPreviousPage(he.browserEvent);const Pe=this.list.getFocus()[0];this.list.setAnchor(Pe),this.list.reveal(Pe),this.view.domNode.focus()}onPageDownArrow(he){he.preventDefault(),he.stopPropagation(),this.list.focusNextPage(he.browserEvent);const Pe=this.list.getFocus()[0];this.list.setAnchor(Pe),this.list.reveal(Pe),this.view.domNode.focus()}onCtrlA(he){he.preventDefault(),he.stopPropagation(),this.list.setSelection((0,P.y1)(this.list.length),he.browserEvent),this.list.setAnchor(void 0),this.view.domNode.focus()}onEscape(he){this.list.getSelection().length&&(he.preventDefault(),he.stopPropagation(),this.list.setSelection([],he.browserEvent),this.list.setAnchor(void 0),this.view.domNode.focus())}dispose(){this.disposables.dispose(),this.multipleSelectionDisposables.dispose()}}k([p.B],X.prototype,"onKeyDown",null);var R;(function(Ae){Ae[Ae.Automatic=0]="Automatic",Ae[Ae.Trigger=1]="Trigger"})(R||(R={}));var H;(function(Ae){Ae[Ae.Idle=0]="Idle",Ae[Ae.Typing=1]="Typing"})(H||(H={}));const Z=new class{mightProducePrintableCharacter(Ae){return Ae.ctrlKey||Ae.metaKey||Ae.altKey?!1:Ae.keyCode>=31&&Ae.keyCode<=56||Ae.keyCode>=21&&Ae.keyCode<=30||Ae.keyCode>=93&&Ae.keyCode<=102||Ae.keyCode>=80&&Ae.keyCode<=90}};class N{constructor(he,Pe,$e,it,ft){this.list=he,this.view=Pe,this.keyboardNavigationLabelProvider=$e,this.keyboardNavigationEventFilter=it,this.delegate=ft,this.enabled=!1,this.state=H.Idle,this.mode=R.Automatic,this.triggered=!1,this.previouslyFocused=-1,this.enabledDisposables=new h.Cm,this.disposables=new h.Cm,this.updateOptions(he.options)}updateOptions(he){var Pe,$e;!((Pe=he.typeNavigationEnabled)!==null&&Pe!==void 0)||Pe?this.enable():this.disable(),this.mode=($e=he.typeNavigationMode)!==null&&$e!==void 0?$e:R.Automatic}enable(){if(this.enabled)return;let he=!1;const Pe=this.enabledDisposables.add(d.Jh.chain(this.enabledDisposables.add(new o.f(this.view.domNode,"keydown")).event)).filter(ft=>!ne(ft.target)).filter(()=>this.mode===R.Automatic||this.triggered).map(ft=>new K.Z(ft)).filter(ft=>he||this.keyboardNavigationEventFilter(ft)).filter(ft=>this.delegate.mightProducePrintableCharacter(ft)).forEach(o.j).map(ft=>ft.browserEvent.key).event,$e=d.Jh.debounce(Pe,()=>null,800,void 0,void 0,this.enabledDisposables);d.Jh.reduce(d.Jh.any(Pe,$e),(ft,Wt)=>Wt===null?null:(ft||"")+Wt,void 0,this.enabledDisposables)(this.onInput,this,this.enabledDisposables),$e(this.onClear,this,this.enabledDisposables),Pe(()=>he=!0,void 0,this.enabledDisposables),$e(()=>he=!1,void 0,this.enabledDisposables),this.enabled=!0,this.triggered=!1}disable(){this.enabled&&(this.enabledDisposables.clear(),this.enabled=!1,this.triggered=!1)}onClear(){var he;const Pe=this.list.getFocus();if(Pe.length>0&&Pe[0]===this.previouslyFocused){const $e=(he=this.list.options.accessibilityProvider)===null||he===void 0?void 0:he.getAriaLabel(this.list.element(Pe[0]));$e&&(0,L.xE)($e)}this.previouslyFocused=-1}onInput(he){if(!he){this.state=H.Idle,this.triggered=!1;return}const Pe=this.list.getFocus(),$e=Pe.length>0?Pe[0]:0,it=this.state===H.Idle?1:0;this.state=H.Typing;for(let ft=0;ft<this.list.length;ft++){const Wt=($e+ft+it)%this.list.length,tt=this.keyboardNavigationLabelProvider.getKeyboardNavigationLabel(this.view.element(Wt)),Ye=tt&&tt.toString();if(typeof Ye>"u"||(0,g.WP)(he,Ye)){this.previouslyFocused=$e,this.list.setFocus([Wt]),this.list.reveal(Wt);return}}}dispose(){this.disable(),this.enabledDisposables.dispose(),this.disposables.dispose()}}class G{constructor(he,Pe){this.list=he,this.view=Pe,this.disposables=new h.Cm,this.disposables.add(d.Jh.chain(this.disposables.add(new o.f(Pe.domNode,"keydown")).event)).filter(it=>!ne(it.target)).map(it=>new K.Z(it)).filter(it=>it.keyCode===2&&!it.ctrlKey&&!it.metaKey&&!it.shiftKey&&!it.altKey).on(this.onTab,this,this.disposables)}onTab(he){if(he.target!==this.view.domNode)return;const Pe=this.list.getFocus();if(Pe.length===0)return;const $e=this.view.domElement(Pe[0]);if(!$e)return;const it=$e.querySelector("[tabIndex]");if(!it||!(it instanceof HTMLElement)||it.tabIndex===-1)return;const ft=window.getComputedStyle(it);ft.visibility==="hidden"||ft.display==="none"||(he.preventDefault(),he.stopPropagation(),it.focus())}dispose(){this.disposables.dispose()}}function O(Ae){return w.zx?Ae.browserEvent.metaKey:Ae.browserEvent.ctrlKey}function te(Ae){return Ae.browserEvent.shiftKey}function oe(Ae){return Ae instanceof MouseEvent&&Ae.button===2}const ue={isSelectionSingleChangeEvent:O,isSelectionRangeChangeEvent:te};class E{constructor(he){this.list=he,this.disposables=new h.Cm,this._onPointer=new d.vl,this.onPointer=this._onPointer.event,he.options.multipleSelectionSupport!==!1&&(this.multipleSelectionController=this.list.options.multipleSelectionController||ue),this.mouseSupport=typeof he.options.mouseSupport>"u"||!!he.options.mouseSupport,this.mouseSupport&&(he.onMouseDown(this.onMouseDown,this,this.disposables),he.onContextMenu(this.onContextMenu,this,this.disposables),he.onMouseDblClick(this.onDoubleClick,this,this.disposables),he.onTouchStart(this.onMouseDown,this,this.disposables),this.disposables.add($.q.addTarget(he.getHTMLElement()))),d.Jh.any(he.onMouseClick,he.onMouseMiddleClick,he.onTap)(this.onViewPointer,this,this.disposables)}updateOptions(he){he.multipleSelectionSupport!==void 0&&(this.multipleSelectionController=void 0,he.multipleSelectionSupport&&(this.multipleSelectionController=this.list.options.multipleSelectionController||ue))}isSelectionSingleChangeEvent(he){return this.multipleSelectionController?this.multipleSelectionController.isSelectionSingleChangeEvent(he):!1}isSelectionRangeChangeEvent(he){return this.multipleSelectionController?this.multipleSelectionController.isSelectionRangeChangeEvent(he):!1}isSelectionChangeEvent(he){return this.isSelectionSingleChangeEvent(he)||this.isSelectionRangeChangeEvent(he)}onMouseDown(he){j(he.browserEvent.target)||document.activeElement!==he.browserEvent.target&&this.list.domFocus()}onContextMenu(he){if(j(he.browserEvent.target))return;const Pe=typeof he.index>"u"?[]:[he.index];this.list.setFocus(Pe,he.browserEvent)}onViewPointer(he){if(!this.mouseSupport||ne(he.browserEvent.target)||j(he.browserEvent.target))return;const Pe=he.index;if(typeof Pe>"u"){this.list.setFocus([],he.browserEvent),this.list.setSelection([],he.browserEvent),this.list.setAnchor(void 0);return}if(this.isSelectionRangeChangeEvent(he))return this.changeSelection(he);if(this.isSelectionChangeEvent(he))return this.changeSelection(he);this.list.setFocus([Pe],he.browserEvent),this.list.setAnchor(Pe),oe(he.browserEvent)||this.list.setSelection([Pe],he.browserEvent),this._onPointer.fire(he)}onDoubleClick(he){if(ne(he.browserEvent.target)||j(he.browserEvent.target)||this.isSelectionChangeEvent(he))return;const Pe=this.list.getFocus();this.list.setSelection(Pe,he.browserEvent)}changeSelection(he){const Pe=he.index;let $e=this.list.getAnchor();if(this.isSelectionRangeChangeEvent(he)){if(typeof $e>"u"){const Lt=this.list.getFocus()[0];$e=Lt??Pe,this.list.setAnchor($e)}const it=Math.min($e,Pe),ft=Math.max($e,Pe),Wt=(0,P.y1)(it,ft+1),tt=this.list.getSelection(),Ye=Me(ce(tt,[$e]),$e);if(Ye.length===0)return;const ht=ce(Wt,pe(tt,Ye));this.list.setSelection(ht,he.browserEvent),this.list.setFocus([Pe],he.browserEvent)}else if(this.isSelectionSingleChangeEvent(he)){const it=this.list.getSelection(),ft=it.filter(Wt=>Wt!==Pe);this.list.setFocus([Pe]),this.list.setAnchor(Pe),it.length===ft.length?this.list.setSelection([...ft,Pe],he.browserEvent):this.list.setSelection(ft,he.browserEvent)}}dispose(){this.disposables.dispose()}}class Qe{constructor(he,Pe){this.styleElement=he,this.selectorSuffix=Pe}style(he){const Pe=this.selectorSuffix&&`.${this.selectorSuffix}`,$e=[];he.listBackground&&(he.listBackground.isOpaque()?$e.push(`.monaco-list${Pe} .monaco-list-rows { background: ${he.listBackground}; }`):w.zx||console.warn(`List with id '${this.selectorSuffix}' was styled with a non-opaque background color. This will break sub-pixel antialiasing.`)),he.listFocusBackground&&($e.push(`.monaco-list${Pe}:focus .monaco-list-row.focused { background-color: ${he.listFocusBackground}; }`),$e.push(`.monaco-list${Pe}:focus .monaco-list-row.focused:hover { background-color: ${he.listFocusBackground}; }`)),he.listFocusForeground&&$e.push(`.monaco-list${Pe}:focus .monaco-list-row.focused { color: ${he.listFocusForeground}; }`),he.listActiveSelectionBackground&&($e.push(`.monaco-list${Pe}:focus .monaco-list-row.selected { background-color: ${he.listActiveSelectionBackground}; }`),$e.push(`.monaco-list${Pe}:focus .monaco-list-row.selected:hover { background-color: ${he.listActiveSelectionBackground}; }`)),he.listActiveSelectionForeground&&$e.push(`.monaco-list${Pe}:focus .monaco-list-row.selected { color: ${he.listActiveSelectionForeground}; }`),he.listActiveSelectionIconForeground&&$e.push(`.monaco-list${Pe}:focus .monaco-list-row.selected .codicon { color: ${he.listActiveSelectionIconForeground}; }`),he.listFocusAndSelectionOutline&&$e.push(`.monaco-list${Pe}:focus .monaco-list-row.selected { outline-color: ${he.listFocusAndSelectionOutline} !important; }`),he.listFocusAndSelectionBackground&&$e.push(` .monaco-drag-image, .monaco-list${Pe}:focus .monaco-list-row.selected.focused { background-color: ${he.listFocusAndSelectionBackground}; } `),he.listFocusAndSelectionForeground&&$e.push(` .monaco-drag-image, .monaco-list${Pe}:focus .monaco-list-row.selected.focused { color: ${he.listFocusAndSelectionForeground}; } `),he.listInactiveFocusForeground&&($e.push(`.monaco-list${Pe} .monaco-list-row.focused { color: ${he.listInactiveFocusForeground}; }`),$e.push(`.monaco-list${Pe} .monaco-list-row.focused:hover { color: ${he.listInactiveFocusForeground}; }`)),he.listInactiveSelectionIconForeground&&$e.push(`.monaco-list${Pe} .monaco-list-row.focused .codicon { color: ${he.listInactiveSelectionIconForeground}; }`),he.listInactiveFocusBackground&&($e.push(`.monaco-list${Pe} .monaco-list-row.focused { background-color: ${he.listInactiveFocusBackground}; }`),$e.push(`.monaco-list${Pe} .monaco-list-row.focused:hover { background-color: ${he.listInactiveFocusBackground}; }`)),he.listInactiveSelectionBackground&&($e.push(`.monaco-list${Pe} .monaco-list-row.selected { background-color: ${he.listInactiveSelectionBackground}; }`),$e.push(`.monaco-list${Pe} .monaco-list-row.selected:hover { background-color: ${he.listInactiveSelectionBackground}; }`)),he.listInactiveSelectionForeground&&$e.push(`.monaco-list${Pe} .monaco-list-row.selected { color: ${he.listInactiveSelectionForeground}; }`),he.listHoverBackground&&$e.push(`.monaco-list${Pe}:not(.drop-target) .monaco-list-row:hover:not(.selected):not(.focused) { background-color: ${he.listHoverBackground}; }`),he.listHoverForeground&&$e.push(`.monaco-list${Pe} .monaco-list-row:hover:not(.selected):not(.focused) { color: ${he.listHoverForeground}; }`),he.listSelectionOutline&&$e.push(`.monaco-list${Pe} .monaco-list-row.selected { outline: 1px dotted ${he.listSelectionOutline}; outline-offset: -1px; }`),he.listFocusOutline&&$e.push(` .monaco-drag-image, .monaco-list${Pe}:focus .monaco-list-row.focused { outline: 1px solid ${he.listFocusOutline}; outline-offset: -1px; } .monaco-workbench.context-menu-visible .monaco-list${Pe}.last-focused .monaco-list-row.focused { outline: 1px solid ${he.listFocusOutline}; outline-offset: -1px; } `),he.listInactiveFocusOutline&&$e.push(`.monaco-list${Pe} .monaco-list-row.focused { outline: 1px dotted ${he.listInactiveFocusOutline}; outline-offset: -1px; }`),he.listHoverOutline&&$e.push(`.monaco-list${Pe} .monaco-list-row:hover { outline: 1px dashed ${he.listHoverOutline}; outline-offset: -1px; }`),he.listDropBackground&&$e.push(` .monaco-list${Pe}.drop-target, .monaco-list${Pe} .monaco-list-rows.drop-target, .monaco-list${Pe} .monaco-list-row.drop-target { background-color: ${he.listDropBackground} !important; color: inherit !important; } `),he.tableColumnsBorder&&$e.push(` .monaco-table:hover > .monaco-split-view2, .monaco-table:hover > .monaco-split-view2 .monaco-sash.vertical::before { border-color: ${he.tableColumnsBorder}; }`),he.tableOddRowsBackgroundColor&&$e.push(` .monaco-table .monaco-list-row[data-parity=odd]:not(.focused):not(.selected):not(:hover) .monaco-table-tr, .monaco-table .monaco-list:not(:focus) .monaco-list-row[data-parity=odd].focused:not(.selected):not(:hover) .monaco-table-tr, .monaco-table .monaco-list:not(.focused) .monaco-list-row[data-parity=odd].focused:not(.selected):not(:hover) .monaco-table-tr { background-color: ${he.tableOddRowsBackgroundColor}; } `),this.styleElement.textContent=$e.join(` `)}}const Ke={listFocusBackground:T.Q1.fromHex("#7FB0D0"),listActiveSelectionBackground:T.Q1.fromHex("#0E639C"),listActiveSelectionForeground:T.Q1.fromHex("#FFFFFF"),listActiveSelectionIconForeground:T.Q1.fromHex("#FFFFFF"),listFocusAndSelectionOutline:T.Q1.fromHex("#90C2F9"),listFocusAndSelectionBackground:T.Q1.fromHex("#094771"),listFocusAndSelectionForeground:T.Q1.fromHex("#FFFFFF"),listInactiveSelectionBackground:T.Q1.fromHex("#3F3F46"),listInactiveSelectionIconForeground:T.Q1.fromHex("#FFFFFF"),listHoverBackground:T.Q1.fromHex("#2A2D2E"),listDropBackground:T.Q1.fromHex("#383B3D"),treeIndentGuidesStroke:T.Q1.fromHex("#a9a9a9"),tableColumnsBorder:T.Q1.fromHex("#cccccc").transparent(.2),tableOddRowsBackgroundColor:T.Q1.fromHex("#cccccc").transparent(.04)},Se={keyboardSupport:!0,mouseSupport:!0,multipleSelectionSupport:!0,dnd:{getDragURI(){return null},onDragStart(){},onDragOver(){return!1},drop(){}}};function Me(Ae,he){const Pe=Ae.indexOf(he);if(Pe===-1)return[];const $e=[];let it=Pe-1;for(;it>=0&&Ae[it]===he-(Pe-it);)$e.push(Ae[it--]);for($e.reverse(),it=Pe;it<Ae.length&&Ae[it]===he+(it-Pe);)$e.push(Ae[it++]);return $e}function ce(Ae,he){const Pe=[];let $e=0,it=0;for(;$e<Ae.length||it<he.length;)if($e>=Ae.length)Pe.push(he[it++]);else if(it>=he.length)Pe.push(Ae[$e++]);else if(Ae[$e]===he[it]){Pe.push(Ae[$e]),$e++,it++;continue}else Ae[$e]<he[it]?Pe.push(Ae[$e++]):Pe.push(he[it++]);return Pe}function pe(Ae,he){const Pe=[];let $e=0,it=0;for(;$e<Ae.length||it<he.length;)if($e>=Ae.length)Pe.push(he[it++]);else if(it>=he.length)Pe.push(Ae[$e++]);else if(Ae[$e]===he[it]){$e++,it++;continue}else Ae[$e]<he[it]?Pe.push(Ae[$e++]):it++;return Pe}const be=(Ae,he)=>Ae-he;class ge{constructor(he,Pe){this._templateId=he,this.renderers=Pe}get templateId(){return this._templateId}renderTemplate(he){return this.renderers.map(Pe=>Pe.renderTemplate(he))}renderElement(he,Pe,$e,it){let ft=0;for(const Wt of this.renderers)Wt.renderElement(he,Pe,$e[ft++],it)}disposeElement(he,Pe,$e,it){var ft;let Wt=0;for(const tt of this.renderers)(ft=tt.disposeElement)===null||ft===void 0||ft.call(tt,he,Pe,$e[Wt],it),Wt+=1}disposeTemplate(he){let Pe=0;for(const $e of this.renderers)$e.disposeTemplate(he[Pe++])}}class ke{constructor(he){this.accessibilityProvider=he,this.templateId="a18n"}renderTemplate(he){return he}renderElement(he,Pe,$e){const it=this.accessibilityProvider.getAriaLabel(he);it?$e.setAttribute("aria-label",it):$e.removeAttribute("aria-label");const ft=this.accessibilityProvider.getAriaLevel&&this.accessibilityProvider.getAriaLevel(he);typeof ft=="number"?$e.setAttribute("aria-level",`${ft}`):$e.removeAttribute("aria-level")}disposeTemplate(he){}}class We{constructor(he,Pe){this.list=he,this.dnd=Pe}getDragElements(he){const Pe=this.list.getSelectedElements();return Pe.indexOf(he)>-1?Pe:[he]}getDragURI(he){return this.dnd.getDragURI(he)}getDragLabel(he,Pe){if(this.dnd.getDragLabel)return this.dnd.getDragLabel(he,Pe)}onDragStart(he,Pe){var $e,it;(it=($e=this.dnd).onDragStart)===null||it===void 0||it.call($e,he,Pe)}onDragOver(he,Pe,$e,it){return this.dnd.onDragOver(he,Pe,$e,it)}onDragLeave(he,Pe,$e,it){var ft,Wt;(Wt=(ft=this.dnd).onDragLeave)===null||Wt===void 0||Wt.call(ft,he,Pe,$e,it)}onDragEnd(he){var Pe,$e;($e=(Pe=this.dnd).onDragEnd)===null||$e===void 0||$e.call(Pe,he)}drop(he,Pe,$e,it){this.dnd.drop(he,Pe,$e,it)}}class Ge{constructor(he,Pe,$e,it,ft=Se){var Wt,tt,Ye,ht;this.user=he,this._options=ft,this.focus=new A("focused"),this.anchor=new A("anchor"),this.eventBufferer=new d.at,this._ariaLabel="",this.disposables=new h.Cm,this._onDidDispose=new d.vl,this.onDidDispose=this._onDidDispose.event;const Lt=this._options.accessibilityProvider&&this._options.accessibilityProvider.getWidgetRole?(Wt=this._options.accessibilityProvider)===null||Wt===void 0?void 0:Wt.getWidgetRole():"list";this.selection=new W(Lt!=="listbox"),(0,u.co)(ft,Ke,!1);const Rt=[this.focus.renderer,this.selection.renderer];this.accessibilityProvider=ft.accessibilityProvider,this.accessibilityProvider&&(Rt.push(new ke(this.accessibilityProvider)),(Ye=(tt=this.accessibilityProvider).onDidChangeActiveDescendant)===null||Ye===void 0||Ye.call(tt,this.onDidChangeActiveDescendant,this,this.disposables)),it=it.map(Ve=>new ge(Ve.templateId,[...Rt,Ve]));const Ie=Object.assign(Object.assign({},ft),{dnd:ft.dnd&&new We(this,ft.dnd)});if(this.view=new v.uO(Pe,$e,it,Ie),this.view.domNode.setAttribute("role",Lt),ft.styleController)this.styleController=ft.styleController(this.view.domId);else{const Ve=(0,b.li)(this.view.domNode);this.styleController=new Qe(Ve,this.view.domId)}if(this.spliceable=new U([new Y(this.focus,this.view,ft.identityProvider),new Y(this.selection,this.view,ft.identityProvider),new Y(this.anchor,this.view,ft.identityProvider),this.view]),this.disposables.add(this.focus),this.disposables.add(this.selection),this.disposables.add(this.anchor),this.disposables.add(this.view),this.disposables.add(this._onDidDispose),this.disposables.add(new G(this,this.view)),(typeof ft.keyboardSupport!="boolean"||ft.keyboardSupport)&&(this.keyboardController=new X(this,this.view,ft),this.disposables.add(this.keyboardController)),ft.keyboardNavigationLabelProvider){const Ve=ft.keyboardNavigationDelegate||Z;this.typeNavigationController=new N(this,this.view,ft.keyboardNavigationLabelProvider,(ht=ft.keyboardNavigationEventFilter)!==null&&ht!==void 0?ht:()=>!0,Ve),this.disposables.add(this.typeNavigationController)}this.mouseController=this.createMouseController(ft),this.disposables.add(this.mouseController),this.onDidChangeFocus(this._onFocusChange,this,this.disposables),this.onDidChangeSelection(this._onSelectionChange,this,this.disposables),this.accessibilityProvider&&(this.ariaLabel=this.accessibilityProvider.getWidgetAriaLabel()),this._options.multipleSelectionSupport!==!1&&this.view.domNode.setAttribute("aria-multiselectable","true")}get onDidChangeFocus(){return d.Jh.map(this.eventBufferer.wrapEvent(this.focus.onChange),he=>this.toListEvent(he),this.disposables)}get onDidChangeSelection(){return d.Jh.map(this.eventBufferer.wrapEvent(this.selection.onChange),he=>this.toListEvent(he),this.disposables)}get domId(){return this.view.domId}get onMouseClick(){return this.view.onMouseClick}get onMouseDblClick(){return this.view.onMouseDblClick}get onMouseMiddleClick(){return this.view.onMouseMiddleClick}get onPointer(){return this.mouseController.onPointer}get onMouseDown(){return this.view.onMouseDown}get onMouseOver(){return this.view.onMouseOver}get onTouchStart(){return this.view.onTouchStart}get onTap(){return this.view.onTap}get onContextMenu(){let he=!1;const Pe=this.disposables.add(d.Jh.chain(this.disposables.add(new o.f(this.view.domNode,"keydown")).event)).map(ft=>new K.Z(ft)).filter(ft=>he=ft.keyCode===58||ft.shiftKey&&ft.keyCode===68).map(o.j).filter(()=>!1).event,$e=this.disposables.add(d.Jh.chain(this.disposables.add(new o.f(this.view.domNode,"keyup")).event)).forEach(()=>he=!1).map(ft=>new K.Z(ft)).filter(ft=>ft.keyCode===58||ft.shiftKey&&ft.keyCode===68).map(o.j).map(({browserEvent:ft})=>{const Wt=this.getFocus(),tt=Wt.length?Wt[0]:void 0,Ye=typeof tt<"u"?this.view.element(tt):void 0,ht=typeof tt<"u"?this.view.domElement(tt):this.view.domNode;return{index:tt,element:Ye,anchor:ht,browserEvent:ft}}).event,it=this.disposables.add(d.Jh.chain(this.view.onContextMenu)).filter(ft=>!he).map(({element:ft,index:Wt,browserEvent:tt})=>({element:ft,index:Wt,anchor:{x:tt.pageX+1,y:tt.pageY},browserEvent:tt})).event;return d.Jh.any(Pe,$e,it)}get onKeyDown(){return this.disposables.add(new o.f(this.view.domNode,"keydown")).event}get onDidFocus(){return d.Jh.signal(this.disposables.add(new o.f(this.view.domNode,"focus",!0)).event)}createMouseController(he){return new E(this)}updateOptions(he={}){var Pe,$e;this._options=Object.assign(Object.assign({},this._options),he),(Pe=this.typeNavigationController)===null||Pe===void 0||Pe.updateOptions(this._options),this._options.multipleSelectionController!==void 0&&(this._options.multipleSelectionSupport?this.view.domNode.setAttribute("aria-multiselectable","true"):this.view.domNode.removeAttribute("aria-multiselectable")),this.mouseController.updateOptions(he),($e=this.keyboardController)===null||$e===void 0||$e.updateOptions(he),this.view.updateOptions(he)}get options(){return this._options}splice(he,Pe,$e=[]){if(he<0||he>this.view.length)throw new m(this.user,`Invalid start index: ${he}`);if(Pe<0)throw new m(this.user,`Invalid delete count: ${Pe}`);Pe===0&&$e.length===0||this.eventBufferer.bufferEvents(()=>this.spliceable.splice(he,Pe,$e))}rerender(){this.view.rerender()}element(he){return this.view.element(he)}get length(){return this.view.length}get contentHeight(){return this.view.contentHeight}get scrollTop(){return this.view.getScrollTop()}set scrollTop(he){this.view.setScrollTop(he)}get ariaLabel(){return this._ariaLabel}set ariaLabel(he){this._ariaLabel=he,this.view.domNode.setAttribute("aria-label",he)}domFocus(){this.view.domNode.focus({preventScroll:!0})}layout(he,Pe){this.view.layout(he,Pe)}setSelection(he,Pe){for(const $e of he)if($e<0||$e>=this.length)throw new m(this.user,`Invalid index ${$e}`);this.selection.set(he,Pe)}getSelection(){return this.selection.get()}getSelectedElements(){return this.getSelection().map(he=>this.view.element(he))}setAnchor(he){if(typeof he>"u"){this.anchor.set([]);return}if(he<0||he>=this.length)throw new m(this.user,`Invalid index ${he}`);this.anchor.set([he])}getAnchor(){return(0,P.Fy)(this.anchor.get(),void 0)}getAnchorElement(){const he=this.getAnchor();return typeof he>"u"?void 0:this.element(he)}setFocus(he,Pe){for(const $e of he)if($e<0||$e>=this.length)throw new m(this.user,`Invalid index ${$e}`);this.focus.set(he,Pe)}focusNext(he=1,Pe=!1,$e,it){if(this.length===0)return;const ft=this.focus.get(),Wt=this.findNextIndex(ft.length>0?ft[0]+he:0,Pe,it);Wt>-1&&this.setFocus([Wt],$e)}focusPrevious(he=1,Pe=!1,$e,it){if(this.length===0)return;const ft=this.focus.get(),Wt=this.findPreviousIndex(ft.length>0?ft[0]-he:0,Pe,it);Wt>-1&&this.setFocus([Wt],$e)}focusNextPage(he,Pe){return D(this,void 0,void 0,function*(){let $e=this.view.indexAt(this.view.getScrollTop()+this.view.renderHeight);$e=$e===0?0:$e-1;const it=this.getFocus()[0];if(it!==$e&&(it===void 0||$e>it)){const ft=this.findPreviousIndex($e,!1,Pe);ft>-1&&it!==ft?this.setFocus([ft],he):this.setFocus([$e],he)}else{const ft=this.view.getScrollTop();let Wt=ft+this.view.renderHeight;$e>it&&(Wt-=this.view.elementHeight($e)),this.view.setScrollTop(Wt),this.view.getScrollTop()!==ft&&(this.setFocus([]),yield(0,B.wR)(0),yield this.focusNextPage(he,Pe))}})}focusPreviousPage(he,Pe){return D(this,void 0,void 0,function*(){let $e;const it=this.view.getScrollTop();it===0?$e=this.view.indexAt(it):$e=this.view.indexAfter(it-1);const ft=this.getFocus()[0];if(ft!==$e&&(ft===void 0||ft>=$e)){const Wt=this.findNextIndex($e,!1,Pe);Wt>-1&&ft!==Wt?this.setFocus([Wt],he):this.setFocus([$e],he)}else{const Wt=it;this.view.setScrollTop(it-this.view.renderHeight),this.view.getScrollTop()!==Wt&&(this.setFocus([]),yield(0,B.wR)(0),yield this.focusPreviousPage(he,Pe))}})}focusLast(he,Pe){if(this.length===0)return;const $e=this.findPreviousIndex(this.length-1,!1,Pe);$e>-1&&this.setFocus([$e],he)}focusFirst(he,Pe){this.focusNth(0,he,Pe)}focusNth(he,Pe,$e){if(this.length===0)return;const it=this.findNextIndex(he,!1,$e);it>-1&&this.setFocus([it],Pe)}findNextIndex(he,Pe=!1,$e){for(let it=0;it<this.length;it++){if(he>=this.length&&!Pe)return-1;if(he=he%this.length,!$e||$e(this.element(he)))return he;he++}return-1}findPreviousIndex(he,Pe=!1,$e){for(let it=0;it<this.length;it++){if(he<0&&!Pe)return-1;if(he=(this.length+he%this.length)%this.length,!$e||$e(this.element(he)))return he;he--}return-1}getFocus(){return this.focus.get()}getFocusedElements(){return this.getFocus().map(he=>this.view.element(he))}reveal(he,Pe){if(he<0||he>=this.length)throw new m(this.user,`Invalid index ${he}`);const $e=this.view.getScrollTop(),it=this.view.elementTop(he),ft=this.view.elementHeight(he);if((0,C.Et)(Pe)){const Wt=ft-this.view.renderHeight;this.view.setScrollTop(Wt*(0,l.qE)(Pe,0,1)+it)}else{const Wt=it+ft,tt=$e+this.view.renderHeight;it<$e&&Wt>=tt||(it<$e||Wt>=tt&&ft>=this.view.renderHeight?this.view.setScrollTop(it):Wt>=tt&&this.view.setScrollTop(Wt-this.view.renderHeight))}}getHTMLElement(){return this.view.domNode}getElementID(he){return this.view.getElementDomId(he)}style(he){this.styleController.style(he)}toListEvent({indexes:he,browserEvent:Pe}){return{indexes:he,elements:he.map($e=>this.view.element($e)),browserEvent:Pe}}_onFocusChange(){const he=this.focus.get();this.view.domNode.classList.toggle("element-focused",he.length>0),this.onDidChangeActiveDescendant()}onDidChangeActiveDescendant(){var he;const Pe=this.focus.get();if(Pe.length>0){let $e;!((he=this.accessibilityProvider)===null||he===void 0)&&he.getActiveDescendantId&&($e=this.accessibilityProvider.getActiveDescendantId(this.view.element(Pe[0]))),this.view.domNode.setAttribute("aria-activedescendant",$e||this.view.getElementDomId(Pe[0]))}else this.view.domNode.removeAttribute("aria-activedescendant")}_onSelectionChange(){const he=this.selection.get();this.view.domNode.classList.toggle("selection-none",he.length===0),this.view.domNode.classList.toggle("selection-single",he.length===1),this.view.domNode.classList.toggle("selection-multiple",he.length>1)}dispose(){this._onDidDispose.fire(),this.disposables.dispose(),this._onDidDispose.dispose()}}k([p.B],Ge.prototype,"onDidChangeFocus",null),k([p.B],Ge.prototype,"onDidChangeSelection",null),k([p.B],Ge.prototype,"onContextMenu",null),k([p.B],Ge.prototype,"onKeyDown",null),k([p.B],Ge.prototype,"onDidFocus",null)},68107:(rt,ye,y)=>{y.d(ye,{S:()=>b});const b="monaco-mouse-cursor-text"},68302:(rt,ye,y)=>{y.d(ye,{T:()=>l});var b=y(64651),o=y(22994),K=y(60756),$=y(34883);function L(w){if(w.length===0)return null;if(w.length===1)return w[0];let C=0;function m(){if(C>=w.length)return null;const x=C,A=w[x].listHeight;for(C++;C<w.length&&w[C].listHeight===A;)C++;return C-x>=2?U(x===0&&C===w.length?w:w.slice(x,C),!1):w[x]}let v=m(),k=m();if(!k)return v;for(let x=m();x;x=m())P(v,k)<=P(k,x)?(v=B(v,k),k=x):k=B(k,x);return B(v,k)}function U(w,C=!1){if(w.length===0)return null;if(w.length===1)return w[0];let m=w.length;for(;m>3;){const v=m>>1;for(let k=0;k<v;k++){const D=k<<1;w[k]=b.Xw.create23(w[D],w[D+1],D+3===m?w[D+2]:null,C)}m=v}return b.Xw.create23(w[0],w[1],m>=3?w[2]:null,C)}function P(w,C){return Math.abs(w.listHeight-C.listHeight)}function B(w,C){return w.listHeight===C.listHeight?b.Xw.create23(w,C,null,!1):w.listHeight>C.listHeight?T(w,C):p(C,w)}function T(w,C){w=w.toMutable();let m=w;const v=new Array;let k;for(;;){if(C.listHeight===m.listHeight){k=C;break}if(m.kind!==4)throw new Error("unexpected");v.push(m),m=m.makeLastElementMutable()}for(let D=v.length-1;D>=0;D--){const x=v[D];k?x.childrenLength>=3?k=b.Xw.create23(x.unappendChild(),k,null,!1):(x.appendChildOfSameHeight(k),k=void 0):x.handleChildrenChanged()}return k?b.Xw.create23(w,k,null,!1):w}function p(w,C){w=w.toMutable();let m=w;const v=new Array;for(;C.listHeight!==m.listHeight;){if(m.kind!==4)throw new Error("unexpected");v.push(m),m=m.makeFirstElementMutable()}let k=C;for(let D=v.length-1;D>=0;D--){const x=v[D];k?x.childrenLength>=3?k=b.Xw.create23(k,x.unprependChild(),null,!1):(x.prependChildOfSameHeight(k),k=void 0):x.handleChildrenChanged()}return k?b.Xw.create23(k,w,null,!1):w}class d{constructor(C){this.lastOffset=$.Vp,this.nextNodes=[C],this.offsets=[$.Vp],this.idxs=[]}readLongestNodeAt(C,m){if((0,$.zG)(C,this.lastOffset))throw new Error("Invalid offset");for(this.lastOffset=C;;){const v=h(this.nextNodes);if(!v)return;const k=h(this.offsets);if((0,$.zG)(C,k))return;if((0,$.zG)(k,C))if((0,$.QB)(k,v.length)<=C)this.nextNodeAfterCurrent();else{const D=g(v);D!==-1?(this.nextNodes.push(v.getChild(D)),this.offsets.push(k),this.idxs.push(D)):this.nextNodeAfterCurrent()}else{if(m(v))return this.nextNodeAfterCurrent(),v;{const D=g(v);if(D===-1){this.nextNodeAfterCurrent();return}else this.nextNodes.push(v.getChild(D)),this.offsets.push(k),this.idxs.push(D)}}}}nextNodeAfterCurrent(){for(;;){const C=h(this.offsets),m=h(this.nextNodes);if(this.nextNodes.pop(),this.offsets.pop(),this.idxs.length===0)break;const v=h(this.nextNodes),k=g(v,this.idxs[this.idxs.length-1]);if(k!==-1){this.nextNodes.push(v.getChild(k)),this.offsets.push((0,$.QB)(C,m.length)),this.idxs[this.idxs.length-1]=k;break}else this.idxs.pop()}}}function g(w,C=-1){for(;;){if(C++,C>=w.childrenLength)return-1;if(w.getChild(C))return C}}function h(w){return w.length>0?w[w.length-1]:void 0}function l(w,C,m,v){return new u(w,C,m,v).parseDocument()}class u{constructor(C,m,v,k){if(this.tokenizer=C,this.createImmutableLists=k,this._itemsConstructed=0,this._itemsFromCache=0,v&&k)throw new Error("Not supported");this.oldNodeReader=v?new d(v):void 0,this.positionMapper=new o.W(m,C.length)}parseDocument(){this._itemsConstructed=0,this._itemsFromCache=0;let C=this.parseList(K.gV.getEmpty());return C||(C=b.Xw.getEmpty()),C}parseList(C){const m=new Array;for(;;){const k=this.tokenizer.peek();if(!k||k.kind===2&&k.bracketIds.intersects(C))break;const D=this.parseChild(C);D.kind===4&&D.childrenLength===0||m.push(D)}return this.oldNodeReader?L(m):U(m,this.createImmutableLists)}parseChild(C){if(this.oldNodeReader){const v=this.positionMapper.getDistanceToNextChange(this.tokenizer.offset);if(!(0,$.Vh)(v)){const k=this.oldNodeReader.readLongestNodeAt(this.positionMapper.getOffsetBeforeChange(this.tokenizer.offset),D=>(0,$.zG)(D.length,v)?D.canBeReused(C):!1);if(k)return this._itemsFromCache++,this.tokenizer.skip(k.length),k}}this._itemsConstructed++;const m=this.tokenizer.read();switch(m.kind){case 2:return new b.Gc(m.bracketIds,m.length);case 0:return m.astNode;case 1:{const v=C.merge(m.bracketIds),k=this.parseList(v),D=this.tokenizer.peek();return D&&D.kind===2&&(D.bracketId===m.bracketId||D.bracketIds.intersects(m.bracketIds))?(this.tokenizer.read(),b.Nn.create(m.astNode,k,D.astNode)):b.Nn.create(m.astNode,k,null)}default:throw new Error("unexpected")}}}},68387:(rt,ye,y)=>{y.d(ye,{Fo:()=>p,YM:()=>g,m5:()=>h,uw:()=>L});class b{constructor(){this._keyCodeToStr=[],this._strToKeyCode=Object.create(null)}define(u,w){this._keyCodeToStr[u]=w,this._strToKeyCode[w.toLowerCase()]=u}keyCodeToStr(u){return this._keyCodeToStr[u]}strToKeyCode(u){return this._strToKeyCode[u.toLowerCase()]||0}}const o=new b,K=new b,$=new b,L=new Array(230),U={},P=[],B=Object.create(null),T=Object.create(null),p=[],d=[];for(let l=0;l<=193;l++)p[l]=-1;for(let l=0;l<=127;l++)d[l]=-1;(function(){const u=[[0,1,0,"None",0,"unknown",0,"VK_UNKNOWN","",""],[0,1,1,"Hyper",0,"",0,"","",""],[0,1,2,"Super",0,"",0,"","",""],[0,1,3,"Fn",0,"",0,"","",""],[0,1,4,"FnLock",0,"",0,"","",""],[0,1,5,"Suspend",0,"",0,"","",""],[0,1,6,"Resume",0,"",0,"","",""],[0,1,7,"Turbo",0,"",0,"","",""],[0,1,8,"Sleep",0,"",0,"VK_SLEEP","",""],[0,1,9,"WakeUp",0,"",0,"","",""],[31,0,10,"KeyA",31,"A",65,"VK_A","",""],[32,0,11,"KeyB",32,"B",66,"VK_B","",""],[33,0,12,"KeyC",33,"C",67,"VK_C","",""],[34,0,13,"KeyD",34,"D",68,"VK_D","",""],[35,0,14,"KeyE",35,"E",69,"VK_E","",""],[36,0,15,"KeyF",36,"F",70,"VK_F","",""],[37,0,16,"KeyG",37,"G",71,"VK_G","",""],[38,0,17,"KeyH",38,"H",72,"VK_H","",""],[39,0,18,"KeyI",39,"I",73,"VK_I","",""],[40,0,19,"KeyJ",40,"J",74,"VK_J","",""],[41,0,20,"KeyK",41,"K",75,"VK_K","",""],[42,0,21,"KeyL",42,"L",76,"VK_L","",""],[43,0,22,"KeyM",43,"M",77,"VK_M","",""],[44,0,23,"KeyN",44,"N",78,"VK_N","",""],[45,0,24,"KeyO",45,"O",79,"VK_O","",""],[46,0,25,"KeyP",46,"P",80,"VK_P","",""],[47,0,26,"KeyQ",47,"Q",81,"VK_Q","",""],[48,0,27,"KeyR",48,"R",82,"VK_R","",""],[49,0,28,"KeyS",49,"S",83,"VK_S","",""],[50,0,29,"KeyT",50,"T",84,"VK_T","",""],[51,0,30,"KeyU",51,"U",85,"VK_U","",""],[52,0,31,"KeyV",52,"V",86,"VK_V","",""],[53,0,32,"KeyW",53,"W",87,"VK_W","",""],[54,0,33,"KeyX",54,"X",88,"VK_X","",""],[55,0,34,"KeyY",55,"Y",89,"VK_Y","",""],[56,0,35,"KeyZ",56,"Z",90,"VK_Z","",""],[22,0,36,"Digit1",22,"1",49,"VK_1","",""],[23,0,37,"Digit2",23,"2",50,"VK_2","",""],[24,0,38,"Digit3",24,"3",51,"VK_3","",""],[25,0,39,"Digit4",25,"4",52,"VK_4","",""],[26,0,40,"Digit5",26,"5",53,"VK_5","",""],[27,0,41,"Digit6",27,"6",54,"VK_6","",""],[28,0,42,"Digit7",28,"7",55,"VK_7","",""],[29,0,43,"Digit8",29,"8",56,"VK_8","",""],[30,0,44,"Digit9",30,"9",57,"VK_9","",""],[21,0,45,"Digit0",21,"0",48,"VK_0","",""],[3,1,46,"Enter",3,"Enter",13,"VK_RETURN","",""],[9,1,47,"Escape",9,"Escape",27,"VK_ESCAPE","",""],[1,1,48,"Backspace",1,"Backspace",8,"VK_BACK","",""],[2,1,49,"Tab",2,"Tab",9,"VK_TAB","",""],[10,1,50,"Space",10,"Space",32,"VK_SPACE","",""],[83,0,51,"Minus",83,"-",189,"VK_OEM_MINUS","-","OEM_MINUS"],[81,0,52,"Equal",81,"=",187,"VK_OEM_PLUS","=","OEM_PLUS"],[87,0,53,"BracketLeft",87,"[",219,"VK_OEM_4","[","OEM_4"],[89,0,54,"BracketRight",89,"]",221,"VK_OEM_6","]","OEM_6"],[88,0,55,"Backslash",88,"\\",220,"VK_OEM_5","\\","OEM_5"],[0,0,56,"IntlHash",0,"",0,"","",""],[80,0,57,"Semicolon",80,";",186,"VK_OEM_1",";","OEM_1"],[90,0,58,"Quote",90,"'",222,"VK_OEM_7","'","OEM_7"],[86,0,59,"Backquote",86,"`",192,"VK_OEM_3","`","OEM_3"],[82,0,60,"Comma",82,",",188,"VK_OEM_COMMA",",","OEM_COMMA"],[84,0,61,"Period",84,".",190,"VK_OEM_PERIOD",".","OEM_PERIOD"],[85,0,62,"Slash",85,"/",191,"VK_OEM_2","/","OEM_2"],[8,1,63,"CapsLock",8,"CapsLock",20,"VK_CAPITAL","",""],[59,1,64,"F1",59,"F1",112,"VK_F1","",""],[60,1,65,"F2",60,"F2",113,"VK_F2","",""],[61,1,66,"F3",61,"F3",114,"VK_F3","",""],[62,1,67,"F4",62,"F4",115,"VK_F4","",""],[63,1,68,"F5",63,"F5",116,"VK_F5","",""],[64,1,69,"F6",64,"F6",117,"VK_F6","",""],[65,1,70,"F7",65,"F7",118,"VK_F7","",""],[66,1,71,"F8",66,"F8",119,"VK_F8","",""],[67,1,72,"F9",67,"F9",120,"VK_F9","",""],[68,1,73,"F10",68,"F10",121,"VK_F10","",""],[69,1,74,"F11",69,"F11",122,"VK_F11","",""],[70,1,75,"F12",70,"F12",123,"VK_F12","",""],[0,1,76,"PrintScreen",0,"",0,"","",""],[79,1,77,"ScrollLock",79,"ScrollLock",145,"VK_SCROLL","",""],[7,1,78,"Pause",7,"PauseBreak",19,"VK_PAUSE","",""],[19,1,79,"Insert",19,"Insert",45,"VK_INSERT","",""],[14,1,80,"Home",14,"Home",36,"VK_HOME","",""],[11,1,81,"PageUp",11,"PageUp",33,"VK_PRIOR","",""],[20,1,82,"Delete",20,"Delete",46,"VK_DELETE","",""],[13,1,83,"End",13,"End",35,"VK_END","",""],[12,1,84,"PageDown",12,"PageDown",34,"VK_NEXT","",""],[17,1,85,"ArrowRight",17,"RightArrow",39,"VK_RIGHT","Right",""],[15,1,86,"ArrowLeft",15,"LeftArrow",37,"VK_LEFT","Left",""],[18,1,87,"ArrowDown",18,"DownArrow",40,"VK_DOWN","Down",""],[16,1,88,"ArrowUp",16,"UpArrow",38,"VK_UP","Up",""],[78,1,89,"NumLock",78,"NumLock",144,"VK_NUMLOCK","",""],[108,1,90,"NumpadDivide",108,"NumPad_Divide",111,"VK_DIVIDE","",""],[103,1,91,"NumpadMultiply",103,"NumPad_Multiply",106,"VK_MULTIPLY","",""],[106,1,92,"NumpadSubtract",106,"NumPad_Subtract",109,"VK_SUBTRACT","",""],[104,1,93,"NumpadAdd",104,"NumPad_Add",107,"VK_ADD","",""],[3,1,94,"NumpadEnter",3,"",0,"","",""],[94,1,95,"Numpad1",94,"NumPad1",97,"VK_NUMPAD1","",""],[95,1,96,"Numpad2",95,"NumPad2",98,"VK_NUMPAD2","",""],[96,1,97,"Numpad3",96,"NumPad3",99,"VK_NUMPAD3","",""],[97,1,98,"Numpad4",97,"NumPad4",100,"VK_NUMPAD4","",""],[98,1,99,"Numpad5",98,"NumPad5",101,"VK_NUMPAD5","",""],[99,1,100,"Numpad6",99,"NumPad6",102,"VK_NUMPAD6","",""],[100,1,101,"Numpad7",100,"NumPad7",103,"VK_NUMPAD7","",""],[101,1,102,"Numpad8",101,"NumPad8",104,"VK_NUMPAD8","",""],[102,1,103,"Numpad9",102,"NumPad9",105,"VK_NUMPAD9","",""],[93,1,104,"Numpad0",93,"NumPad0",96,"VK_NUMPAD0","",""],[107,1,105,"NumpadDecimal",107,"NumPad_Decimal",110,"VK_DECIMAL","",""],[92,0,106,"IntlBackslash",92,"OEM_102",226,"VK_OEM_102","",""],[58,1,107,"ContextMenu",58,"ContextMenu",93,"","",""],[0,1,108,"Power",0,"",0,"","",""],[0,1,109,"NumpadEqual",0,"",0,"","",""],[71,1,110,"F13",71,"F13",124,"VK_F13","",""],[72,1,111,"F14",72,"F14",125,"VK_F14","",""],[73,1,112,"F15",73,"F15",126,"VK_F15","",""],[74,1,113,"F16",74,"F16",127,"VK_F16","",""],[75,1,114,"F17",75,"F17",128,"VK_F17","",""],[76,1,115,"F18",76,"F18",129,"VK_F18","",""],[77,1,116,"F19",77,"F19",130,"VK_F19","",""],[0,1,117,"F20",0,"",0,"VK_F20","",""],[0,1,118,"F21",0,"",0,"VK_F21","",""],[0,1,119,"F22",0,"",0,"VK_F22","",""],[0,1,120,"F23",0,"",0,"VK_F23","",""],[0,1,121,"F24",0,"",0,"VK_F24","",""],[0,1,122,"Open",0,"",0,"","",""],[0,1,123,"Help",0,"",0,"","",""],[0,1,124,"Select",0,"",0,"","",""],[0,1,125,"Again",0,"",0,"","",""],[0,1,126,"Undo",0,"",0,"","",""],[0,1,127,"Cut",0,"",0,"","",""],[0,1,128,"Copy",0,"",0,"","",""],[0,1,129,"Paste",0,"",0,"","",""],[0,1,130,"Find",0,"",0,"","",""],[0,1,131,"AudioVolumeMute",112,"AudioVolumeMute",173,"VK_VOLUME_MUTE","",""],[0,1,132,"AudioVolumeUp",113,"AudioVolumeUp",175,"VK_VOLUME_UP","",""],[0,1,133,"AudioVolumeDown",114,"AudioVolumeDown",174,"VK_VOLUME_DOWN","",""],[105,1,134,"NumpadComma",105,"NumPad_Separator",108,"VK_SEPARATOR","",""],[110,0,135,"IntlRo",110,"ABNT_C1",193,"VK_ABNT_C1","",""],[0,1,136,"KanaMode",0,"",0,"","",""],[0,0,137,"IntlYen",0,"",0,"","",""],[0,1,138,"Convert",0,"",0,"","",""],[0,1,139,"NonConvert",0,"",0,"","",""],[0,1,140,"Lang1",0,"",0,"","",""],[0,1,141,"Lang2",0,"",0,"","",""],[0,1,142,"Lang3",0,"",0,"","",""],[0,1,143,"Lang4",0,"",0,"","",""],[0,1,144,"Lang5",0,"",0,"","",""],[0,1,145,"Abort",0,"",0,"","",""],[0,1,146,"Props",0,"",0,"","",""],[0,1,147,"NumpadParenLeft",0,"",0,"","",""],[0,1,148,"NumpadParenRight",0,"",0,"","",""],[0,1,149,"NumpadBackspace",0,"",0,"","",""],[0,1,150,"NumpadMemoryStore",0,"",0,"","",""],[0,1,151,"NumpadMemoryRecall",0,"",0,"","",""],[0,1,152,"NumpadMemoryClear",0,"",0,"","",""],[0,1,153,"NumpadMemoryAdd",0,"",0,"","",""],[0,1,154,"NumpadMemorySubtract",0,"",0,"","",""],[0,1,155,"NumpadClear",126,"Clear",12,"VK_CLEAR","",""],[0,1,156,"NumpadClearEntry",0,"",0,"","",""],[5,1,0,"",5,"Ctrl",17,"VK_CONTROL","",""],[4,1,0,"",4,"Shift",16,"VK_SHIFT","",""],[6,1,0,"",6,"Alt",18,"VK_MENU","",""],[57,1,0,"",57,"Meta",0,"VK_COMMAND","",""],[5,1,157,"ControlLeft",5,"",0,"VK_LCONTROL","",""],[4,1,158,"ShiftLeft",4,"",0,"VK_LSHIFT","",""],[6,1,159,"AltLeft",6,"",0,"VK_LMENU","",""],[57,1,160,"MetaLeft",57,"",0,"VK_LWIN","",""],[5,1,161,"ControlRight",5,"",0,"VK_RCONTROL","",""],[4,1,162,"ShiftRight",4,"",0,"VK_RSHIFT","",""],[6,1,163,"AltRight",6,"",0,"VK_RMENU","",""],[57,1,164,"MetaRight",57,"",0,"VK_RWIN","",""],[0,1,165,"BrightnessUp",0,"",0,"","",""],[0,1,166,"BrightnessDown",0,"",0,"","",""],[0,1,167,"MediaPlay",0,"",0,"","",""],[0,1,168,"MediaRecord",0,"",0,"","",""],[0,1,169,"MediaFastForward",0,"",0,"","",""],[0,1,170,"MediaRewind",0,"",0,"","",""],[114,1,171,"MediaTrackNext",119,"MediaTrackNext",176,"VK_MEDIA_NEXT_TRACK","",""],[115,1,172,"MediaTrackPrevious",120,"MediaTrackPrevious",177,"VK_MEDIA_PREV_TRACK","",""],[116,1,173,"MediaStop",121,"MediaStop",178,"VK_MEDIA_STOP","",""],[0,1,174,"Eject",0,"",0,"","",""],[117,1,175,"MediaPlayPause",122,"MediaPlayPause",179,"VK_MEDIA_PLAY_PAUSE","",""],[0,1,176,"MediaSelect",123,"LaunchMediaPlayer",181,"VK_MEDIA_LAUNCH_MEDIA_SELECT","",""],[0,1,177,"LaunchMail",124,"LaunchMail",180,"VK_MEDIA_LAUNCH_MAIL","",""],[0,1,178,"LaunchApp2",125,"LaunchApp2",183,"VK_MEDIA_LAUNCH_APP2","",""],[0,1,179,"LaunchApp1",0,"",0,"VK_MEDIA_LAUNCH_APP1","",""],[0,1,180,"SelectTask",0,"",0,"","",""],[0,1,181,"LaunchScreenSaver",0,"",0,"","",""],[0,1,182,"BrowserSearch",115,"BrowserSearch",170,"VK_BROWSER_SEARCH","",""],[0,1,183,"BrowserHome",116,"BrowserHome",172,"VK_BROWSER_HOME","",""],[112,1,184,"BrowserBack",117,"BrowserBack",166,"VK_BROWSER_BACK","",""],[113,1,185,"BrowserForward",118,"BrowserForward",167,"VK_BROWSER_FORWARD","",""],[0,1,186,"BrowserStop",0,"",0,"VK_BROWSER_STOP","",""],[0,1,187,"BrowserRefresh",0,"",0,"VK_BROWSER_REFRESH","",""],[0,1,188,"BrowserFavorites",0,"",0,"VK_BROWSER_FAVORITES","",""],[0,1,189,"ZoomToggle",0,"",0,"","",""],[0,1,190,"MailReply",0,"",0,"","",""],[0,1,191,"MailForward",0,"",0,"","",""],[0,1,192,"MailSend",0,"",0,"","",""],[109,1,0,"",109,"KeyInComposition",229,"","",""],[111,1,0,"",111,"ABNT_C2",194,"VK_ABNT_C2","",""],[91,1,0,"",91,"OEM_8",223,"VK_OEM_8","",""],[0,1,0,"",0,"",0,"VK_KANA","",""],[0,1,0,"",0,"",0,"VK_HANGUL","",""],[0,1,0,"",0,"",0,"VK_JUNJA","",""],[0,1,0,"",0,"",0,"VK_FINAL","",""],[0,1,0,"",0,"",0,"VK_HANJA","",""],[0,1,0,"",0,"",0,"VK_KANJI","",""],[0,1,0,"",0,"",0,"VK_CONVERT","",""],[0,1,0,"",0,"",0,"VK_NONCONVERT","",""],[0,1,0,"",0,"",0,"VK_ACCEPT","",""],[0,1,0,"",0,"",0,"VK_MODECHANGE","",""],[0,1,0,"",0,"",0,"VK_SELECT","",""],[0,1,0,"",0,"",0,"VK_PRINT","",""],[0,1,0,"",0,"",0,"VK_EXECUTE","",""],[0,1,0,"",0,"",0,"VK_SNAPSHOT","",""],[0,1,0,"",0,"",0,"VK_HELP","",""],[0,1,0,"",0,"",0,"VK_APPS","",""],[0,1,0,"",0,"",0,"VK_PROCESSKEY","",""],[0,1,0,"",0,"",0,"VK_PACKET","",""],[0,1,0,"",0,"",0,"VK_DBE_SBCSCHAR","",""],[0,1,0,"",0,"",0,"VK_DBE_DBCSCHAR","",""],[0,1,0,"",0,"",0,"VK_ATTN","",""],[0,1,0,"",0,"",0,"VK_CRSEL","",""],[0,1,0,"",0,"",0,"VK_EXSEL","",""],[0,1,0,"",0,"",0,"VK_EREOF","",""],[0,1,0,"",0,"",0,"VK_PLAY","",""],[0,1,0,"",0,"",0,"VK_ZOOM","",""],[0,1,0,"",0,"",0,"VK_NONAME","",""],[0,1,0,"",0,"",0,"VK_PA1","",""],[0,1,0,"",0,"",0,"VK_OEM_CLEAR","",""]],w=[],C=[];for(const m of u){const[v,k,D,x,A,W,Y,ne,j,Q]=m;if(C[D]||(C[D]=!0,P[D]=x,B[x]=D,T[x.toLowerCase()]=D,k&&(p[D]=A,A!==0&&A!==3&&A!==5&&A!==4&&A!==6&&A!==57&&(d[A]=D))),!w[A]){if(w[A]=!0,!W)throw new Error(`String representation missing for key code ${A} around scan code ${x}`);o.define(A,W),K.define(A,j||W),$.define(A,Q||j||W)}Y&&(L[Y]=A),ne&&(U[ne]=A)}d[3]=46})();var g;(function(l){function u(D){return o.keyCodeToStr(D)}l.toString=u;function w(D){return o.strToKeyCode(D)}l.fromString=w;function C(D){return K.keyCodeToStr(D)}l.toUserSettingsUS=C;function m(D){return $.keyCodeToStr(D)}l.toUserSettingsGeneral=m;function v(D){return K.strToKeyCode(D)||$.strToKeyCode(D)}l.fromUserSettings=v;function k(D){if(D>=93&&D<=108)return null;switch(D){case 16:return"Up";case 18:return"Down";case 15:return"Left";case 17:return"Right"}return o.keyCodeToStr(D)}l.toElectronAccelerator=k})(g||(g={}));function h(l,u){const w=(u&65535)<<16>>>0;return(l|w)>>>0}},70645:(rt,ye,y)=>{y.d(ye,{$f:()=>P,MU:()=>B,Yb:()=>p,_t:()=>T,vn:()=>U});var b=y(16844),o=y(49550),K=y(19184),$=y(52394);function L(d,g,h){const l=d.tokenization.getLanguageIdAtPosition(g,0);if(g>1){let u,w=-1;for(u=g-1;u>=1;u--){if(d.tokenization.getLanguageIdAtPosition(u,0)!==l)return w;const C=d.getLineContent(u);if(h.shouldIgnore(C)||/^\s+$/.test(C)||C===""){w=u;continue}return u}}return-1}function U(d,g,h,l=!0,u){if(d<4)return null;const w=u.getLanguageConfiguration(g.tokenization.getLanguageId()).indentRulesSupport;if(!w)return null;if(h<=1)return{indentation:"",action:null};const C=L(g,h,w);if(C<0)return null;if(C<1)return{indentation:"",action:null};const m=g.getLineContent(C);if(w.shouldIncrease(m)||w.shouldIndentNextLine(m))return{indentation:b.UU(m),action:o.l.Indent,line:C};if(w.shouldDecrease(m))return{indentation:b.UU(m),action:null,line:C};{if(C===1)return{indentation:b.UU(g.getLineContent(C)),action:null,line:C};const v=C-1,k=w.getIndentMetadata(g.getLineContent(v));if(!(k&3)&&k&4){let D=0;for(let x=v-1;x>0;x--)if(!w.shouldIndentNextLine(g.getLineContent(x))){D=x;break}return{indentation:b.UU(g.getLineContent(D+1)),action:null,line:D+1}}if(l)return{indentation:b.UU(g.getLineContent(C)),action:null,line:C};for(let D=C;D>0;D--){const x=g.getLineContent(D);if(w.shouldIncrease(x))return{indentation:b.UU(x),action:o.l.Indent,line:D};if(w.shouldIndentNextLine(x)){let A=0;for(let W=D-1;W>0;W--)if(!w.shouldIndentNextLine(g.getLineContent(D))){A=W;break}return{indentation:b.UU(g.getLineContent(A+1)),action:null,line:A+1}}else if(w.shouldDecrease(x))return{indentation:b.UU(x),action:null,line:D}}return{indentation:b.UU(g.getLineContent(1)),action:null,line:1}}}function P(d,g,h,l,u,w){if(d<4)return null;const C=w.getLanguageConfiguration(h);if(!C)return null;const m=w.getLanguageConfiguration(h).indentRulesSupport;if(!m)return null;const v=U(d,g,l,void 0,w),k=g.getLineContent(l);if(v){const D=v.line;if(D!==void 0){const x=C.onEnter(d,"",g.getLineContent(D),"");if(x){let A=b.UU(g.getLineContent(D));return x.removeText&&(A=A.substring(0,A.length-x.removeText)),x.indentAction===o.l.Indent||x.indentAction===o.l.IndentOutdent?A=u.shiftIndent(A):x.indentAction===o.l.Outdent&&(A=u.unshiftIndent(A)),m.shouldDecrease(k)&&(A=u.unshiftIndent(A)),x.appendText&&(A+=x.appendText),b.UU(A)}}return m.shouldDecrease(k)?v.action===o.l.Indent?v.indentation:u.unshiftIndent(v.indentation):v.action===o.l.Indent?u.shiftIndent(v.indentation):v.indentation}return null}function B(d,g,h,l,u){if(d<4)return null;g.tokenization.forceTokenization(h.startLineNumber);const w=g.tokenization.getLineTokens(h.startLineNumber),C=(0,K.BQ)(w,h.startColumn-1),m=C.getLineContent();let v=!1,k;C.firstCharOffset>0&&w.getLanguageId(0)!==C.languageId?(v=!0,k=m.substr(0,h.startColumn-1-C.firstCharOffset)):k=w.getLineContent().substring(0,h.startColumn-1);let D;h.isEmpty()?D=m.substr(h.startColumn-1-C.firstCharOffset):D=(0,$.P6)(g,h.endLineNumber,h.endColumn).getLineContent().substr(h.endColumn-1-C.firstCharOffset);const x=u.getLanguageConfiguration(C.languageId).indentRulesSupport;if(!x)return null;const A=k,W=b.UU(k),Y={tokenization:{getLineTokens:X=>g.tokenization.getLineTokens(X),getLanguageId:()=>g.getLanguageId(),getLanguageIdAtPosition:(X,R)=>g.getLanguageIdAtPosition(X,R)},getLineContent:X=>X===h.startLineNumber?A:g.getLineContent(X)},ne=b.UU(w.getLineContent()),j=U(d,Y,h.startLineNumber+1,void 0,u);if(!j){const X=v?ne:W;return{beforeEnter:X,afterEnter:X}}let Q=v?ne:j.indentation;return j.action===o.l.Indent&&(Q=l.shiftIndent(Q)),x.shouldDecrease(D)&&(Q=l.unshiftIndent(Q)),{beforeEnter:v?ne:W,afterEnter:Q}}function T(d,g,h,l,u,w){if(d<4)return null;const C=(0,$.P6)(g,h.startLineNumber,h.startColumn);if(C.firstCharOffset)return null;const m=w.getLanguageConfiguration(C.languageId).indentRulesSupport;if(!m)return null;const v=C.getLineContent(),k=v.substr(0,h.startColumn-1-C.firstCharOffset);let D;if(h.isEmpty()?D=v.substr(h.startColumn-1-C.firstCharOffset):D=(0,$.P6)(g,h.endLineNumber,h.endColumn).getLineContent().substr(h.endColumn-1-C.firstCharOffset),!m.shouldDecrease(k+D)&&m.shouldDecrease(k+l+D)){const x=U(d,g,h.startLineNumber,!1,w);if(!x)return null;let A=x.indentation;return x.action!==o.l.Indent&&(A=u.unshiftIndent(A)),A}return null}function p(d,g,h){const l=h.getLanguageConfiguration(d.getLanguageId()).indentRulesSupport;return!l||g<1||g>d.getLineCount()?null:l.getIndentMetadata(d.getLineContent(g))}},70802:(rt,ye,y)=>{y.d(ye,{f:()=>U});var b=y(39619),o=y(63339),K=y(59715),$=y(67167);class L{constructor(){this._coreKeybindings=[],this._extensionKeybindings=[],this._cachedMergedKeybindings=null}static bindToCurrentPlatform(p){if(o.OS===1){if(p&&p.win)return p.win}else if(o.OS===2){if(p&&p.mac)return p.mac}else if(p&&p.linux)return p.linux;return p}registerKeybindingRule(p){const d=L.bindToCurrentPlatform(p);if(d&&d.primary){const g=(0,b.ZU)(d.primary,o.OS);g&&this._registerDefaultKeybinding(g,p.id,p.args,p.weight,0,p.when)}if(d&&Array.isArray(d.secondary))for(let g=0,h=d.secondary.length;g<h;g++){const l=d.secondary[g],u=(0,b.ZU)(l,o.OS);u&&this._registerDefaultKeybinding(u,p.id,p.args,p.weight,-g-1,p.when)}}registerCommandAndKeybindingRule(p){this.registerKeybindingRule(p),K.wb.registerCommand(p)}static _mightProduceChar(p){return p>=21&&p<=30||p>=31&&p<=56?!0:p===80||p===81||p===82||p===83||p===84||p===85||p===86||p===110||p===111||p===87||p===88||p===89||p===90||p===91||p===92}_assertNoCtrlAlt(p,d){p.ctrlKey&&p.altKey&&!p.metaKey&&L._mightProduceChar(p.keyCode)&&console.warn("Ctrl+Alt+ keybindings should not be used by default under Windows. Offender: ",p," for ",d)}_registerDefaultKeybinding(p,d,g,h,l,u){o.OS===1&&this._assertNoCtrlAlt(p.parts[0],d),this._coreKeybindings.push({keybinding:p.parts,command:d,commandArgs:g,when:u,weight1:h,weight2:l,extensionId:null,isBuiltinExtension:!1}),this._cachedMergedKeybindings=null}getDefaultKeybindings(){return this._cachedMergedKeybindings||(this._cachedMergedKeybindings=[].concat(this._coreKeybindings).concat(this._extensionKeybindings),this._cachedMergedKeybindings.sort(B)),this._cachedMergedKeybindings.slice(0)}}const U=new L,P={EditorModes:"platform.keybindingsRegistry"};$.O.add(P.EditorModes,U);function B(T,p){if(T.weight1!==p.weight1)return T.weight1-p.weight1;if(T.command&&p.command){if(T.command<p.command)return-1;if(T.command>p.command)return 1}return T.weight2-p.weight2}},71386:(rt,ye,y)=>{y.d(ye,{Go:()=>o,PI:()=>L,aI:()=>B,co:()=>P,ol:()=>K});var b=y(79359);function o(T){if(!T||typeof T!="object"||T instanceof RegExp)return T;const p=Array.isArray(T)?[]:{};return Object.keys(T).forEach(d=>{T[d]&&typeof T[d]=="object"?p[d]=o(T[d]):p[d]=T[d]}),p}function K(T){if(!T||typeof T!="object")return T;const p=[T];for(;p.length>0;){const d=p.shift();Object.freeze(d);for(const g in d)if($.call(d,g)){const h=d[g];typeof h=="object"&&!Object.isFrozen(h)&&!(0,b.iu)(h)&&p.push(h)}}return T}const $=Object.prototype.hasOwnProperty;function L(T,p){return U(T,p,new Set)}function U(T,p,d){if((0,b.z)(T))return T;const g=p(T);if(typeof g<"u")return g;if((0,b.cy)(T)){const h=[];for(const l of T)h.push(U(l,p,d));return h}if((0,b.Gv)(T)){if(d.has(T))throw new Error("Cannot clone recursive data-structure");d.add(T);const h={};for(const l in T)$.call(T,l)&&(h[l]=U(T[l],p,d));return d.delete(T),h}return T}function P(T,p,d=!0){return(0,b.Gv)(T)?((0,b.Gv)(p)&&Object.keys(p).forEach(g=>{g in T?d&&((0,b.Gv)(T[g])&&(0,b.Gv)(p[g])?P(T[g],p[g],d):T[g]=p[g]):T[g]=p[g]}),T):p}function B(T,p){if(T===p)return!0;if(T==null||p===null||p===void 0||typeof T!=typeof p||typeof T!="object"||Array.isArray(T)!==Array.isArray(p))return!1;let d,g;if(Array.isArray(T)){if(T.length!==p.length)return!1;for(d=0;d<T.length;d++)if(!B(T[d],p[d]))return!1}else{const h=[];for(g in T)h.push(g);h.sort();const l=[];for(g in p)l.push(g);if(l.sort(),!B(h,l))return!1;for(d=0;d<h.length;d++)if(!B(T[h[d]],p[h[d]]))return!1}return!0}},71937:(rt,ye,y)=>{y.d(ye,{s:()=>o});var b=y(62549);class o{static whitespaceVisibleColumn($,L,U){const P=$.length;let B=0,T=-1,p=-1;for(let d=0;d<P;d++){if(d===L)return[T,p,B];switch(B%U===0&&(T=d,p=B),$.charCodeAt(d)){case 32:B+=1;break;case 9:B=b.A.nextRenderTabStop(B,U);break;default:return[-1,-1,-1]}}return L===P?[T,p,B]:[-1,-1,-1]}static atomicPosition($,L,U,P){const B=$.length,[T,p,d]=o.whitespaceVisibleColumn($,L,U);if(d===-1)return-1;let g;switch(P){case 0:g=!0;break;case 1:g=!1;break;case 2:if(d%U===0)return L;g=d%U<=U/2;break}if(g){if(T===-1)return-1;let u=p;for(let w=T;w<B;++w){if(u===p+U)return T;switch($.charCodeAt(w)){case 32:u+=1;break;case 9:u=b.A.nextRenderTabStop(u,U);break;default:return-1}}return u===p+U?T:-1}const h=b.A.nextRenderTabStop(d,U);let l=d;for(let u=L;u<B;u++){if(l===h)return u;switch($.charCodeAt(u)){case 32:l+=1;break;case 9:l=b.A.nextRenderTabStop(l,U);break;default:return-1}}return l===h?B:-1}}},72521:(rt,ye,y)=>{y.d(ye,{Yh:()=>ne,QM:()=>x});var b=y(3765),o=y(55893),K=y(79359),$=y(59407),L=y(50946),U=y(87301),P=y(29895),B=y(15365),T=y(50442);class p{static columnSelect(R,H,Z,N,G,O){const te=Math.abs(G-Z)+1,oe=Z>G,ue=N>O,E=N<O,Qe=[];for(let Ke=0;Ke<te;Ke++){const Se=Z+(oe?-Ke:Ke),Me=R.columnFromVisibleColumn(H,Se,N),ce=R.columnFromVisibleColumn(H,Se,O),pe=R.visibleColumnFromColumn(H,new B.y(Se,Me)),be=R.visibleColumnFromColumn(H,new B.y(Se,ce));E&&(pe>O||be<N)||ue&&(be>N||pe<O)||Qe.push(new P.mG(new T.Q(Se,Me,Se,Me),0,new B.y(Se,ce),0))}if(Qe.length===0)for(let Ke=0;Ke<te;Ke++){const Se=Z+(oe?-Ke:Ke),Me=H.getLineMaxColumn(Se);Qe.push(new P.mG(new T.Q(Se,Me,Se,Me),0,new B.y(Se,Me),0))}return{viewStates:Qe,reversed:oe,fromLineNumber:Z,fromVisualColumn:N,toLineNumber:G,toVisualColumn:O}}static columnSelectLeft(R,H,Z){let N=Z.toViewVisualColumn;return N>0&&N--,p.columnSelect(R,H,Z.fromViewLineNumber,Z.fromViewVisualColumn,Z.toViewLineNumber,N)}static columnSelectRight(R,H,Z){let N=0;const G=Math.min(Z.fromViewLineNumber,Z.toViewLineNumber),O=Math.max(Z.fromViewLineNumber,Z.toViewLineNumber);for(let oe=G;oe<=O;oe++){const ue=H.getLineMaxColumn(oe),E=R.visibleColumnFromColumn(H,new B.y(oe,ue));N=Math.max(N,E)}let te=Z.toViewVisualColumn;return te<N&&te++,this.columnSelect(R,H,Z.fromViewLineNumber,Z.fromViewVisualColumn,Z.toViewLineNumber,te)}static columnSelectUp(R,H,Z,N){const G=N?R.pageSize:1,O=Math.max(1,Z.toViewLineNumber-G);return this.columnSelect(R,H,Z.fromViewLineNumber,Z.fromViewVisualColumn,O,Z.toViewVisualColumn)}static columnSelectDown(R,H,Z,N){const G=N?R.pageSize:1,O=Math.min(H.getLineCount(),Z.toViewLineNumber+G);return this.columnSelect(R,H,Z.fromViewLineNumber,Z.fromViewVisualColumn,O,Z.toViewVisualColumn)}}var d=y(97666),g=y(27064),h=y(61710),l=y(38122),u=y(96655),w=y(70802);const C=0;class m extends L.DX{runEditorCommand(R,H,Z){const N=H._getViewModel();N&&this.runCoreEditorCommand(N,Z||{})}}var v;(function(X){const R=function(Z){if(!K.Gv(Z))return!1;const N=Z;return!(!K.Kg(N.to)||!K.b0(N.by)&&!K.Kg(N.by)||!K.b0(N.value)&&!K.Et(N.value)||!K.b0(N.revealCursor)&&!K.Lm(N.revealCursor))};X.description={description:"Scroll editor in the given direction",args:[{name:"Editor scroll argument object",description:"Property-value pairs that can be passed through this argument:\n * 'to': A mandatory direction value.\n ```\n 'up', 'down'\n ```\n * 'by': Unit to move. Default is computed based on 'to' value.\n ```\n 'line', 'wrappedLine', 'page', 'halfPage', 'editor'\n ```\n * 'value': Number of units to move. Default is '1'.\n * 'revealCursor': If 'true' reveals the cursor if it is outside view port.\n ",constraint:R,schema:{type:"object",required:["to"],properties:{to:{type:"string",enum:["up","down"]},by:{type:"string",enum:["line","wrappedLine","page","halfPage","editor"]},value:{type:"number",default:1},revealCursor:{type:"boolean"}}}}]},X.RawDirection={Up:"up",Down:"down"},X.RawUnit={Line:"line",WrappedLine:"wrappedLine",Page:"page",HalfPage:"halfPage",Editor:"editor"};function H(Z){let N;switch(Z.to){case X.RawDirection.Up:N=1;break;case X.RawDirection.Down:N=2;break;default:return null}let G;switch(Z.by){case X.RawUnit.Line:G=1;break;case X.RawUnit.WrappedLine:G=2;break;case X.RawUnit.Page:G=3;break;case X.RawUnit.HalfPage:G=4;break;case X.RawUnit.Editor:G=5;break;default:G=2}const O=Math.floor(Z.value||1),te=!!Z.revealCursor;return{direction:N,unit:G,value:O,revealCursor:te,select:!!Z.select}}X.parse=H})(v||(v={}));var k;(function(X){const R=function(H){if(!K.Gv(H))return!1;const Z=H;return!(!K.Et(Z.lineNumber)&&!K.Kg(Z.lineNumber)||!K.b0(Z.at)&&!K.Kg(Z.at))};X.description={description:"Reveal the given line at the given logical position",args:[{name:"Reveal line argument object",description:"Property-value pairs that can be passed through this argument:\n * 'lineNumber': A mandatory line number value.\n * 'at': Logical position at which line has to be revealed.\n ```\n 'top', 'center', 'bottom'\n ```\n ",constraint:R,schema:{type:"object",required:["lineNumber"],properties:{lineNumber:{type:["number","string"]},at:{type:"string",enum:["top","center","bottom"]}}}}]},X.RawAtArgument={Top:"top",Center:"center",Bottom:"bottom"}})(k||(k={}));class D{constructor(R){R.addImplementation(1e4,"code-editor",(H,Z)=>{const N=H.get(U.T).getFocusedCodeEditor();return N&&N.hasTextFocus()?this._runEditorCommand(H,N,Z):!1}),R.addImplementation(1e3,"generic-dom-input-textarea",(H,Z)=>{const N=document.activeElement;return N&&["input","textarea"].indexOf(N.tagName.toLowerCase())>=0?(this.runDOMCommand(),!0):!1}),R.addImplementation(0,"generic-dom",(H,Z)=>{const N=H.get(U.T).getActiveCodeEditor();return N?(N.focus(),this._runEditorCommand(H,N,Z)):!1})}_runEditorCommand(R,H,Z){const N=this.runEditorCommand(R,H,Z);return N||!0}}var x;(function(X){class R extends m{constructor(ge){super(ge),this._minimalReveal=ge.minimalReveal,this._inSelectionMode=ge.inSelectionMode}runCoreEditorCommand(ge,ke){ge.model.pushStackElement(),ge.setCursorStates(ke.source,3,[g.c.moveTo(ge,ge.getPrimaryCursorState(),this._inSelectionMode,ke.position,ke.viewPosition)])&&ge.revealPrimaryCursor(ke.source,!0,this._minimalReveal)}}X.MoveTo=(0,L.E_)(new R({id:"_moveTo",minimalReveal:!0,inSelectionMode:!1,precondition:void 0})),X.MoveToSelect=(0,L.E_)(new R({id:"_moveToSelect",minimalReveal:!1,inSelectionMode:!0,precondition:void 0}));class H extends m{runCoreEditorCommand(ge,ke){ge.model.pushStackElement();const We=this._getColumnSelectResult(ge,ge.getPrimaryCursorState(),ge.getCursorColumnSelectData(),ke);ge.setCursorStates(ke.source,3,We.viewStates.map(Ge=>P.MF.fromViewState(Ge))),ge.setCursorColumnSelectData({isReal:!0,fromViewLineNumber:We.fromLineNumber,fromViewVisualColumn:We.fromVisualColumn,toViewLineNumber:We.toLineNumber,toViewVisualColumn:We.toVisualColumn}),We.reversed?ge.revealTopMostCursor(ke.source):ge.revealBottomMostCursor(ke.source)}}X.ColumnSelect=(0,L.E_)(new class extends H{constructor(){super({id:"columnSelect",precondition:void 0})}_getColumnSelectResult(be,ge,ke,We){const Ge=be.model.validatePosition(We.position),Ae=be.coordinatesConverter.validateViewPosition(new B.y(We.viewPosition.lineNumber,We.viewPosition.column),Ge),he=We.doColumnSelect?ke.fromViewLineNumber:Ae.lineNumber,Pe=We.doColumnSelect?ke.fromViewVisualColumn:We.mouseColumn-1;return p.columnSelect(be.cursorConfig,be,he,Pe,Ae.lineNumber,We.mouseColumn-1)}}),X.CursorColumnSelectLeft=(0,L.E_)(new class extends H{constructor(){super({id:"cursorColumnSelectLeft",precondition:void 0,kbOpts:{weight:C,kbExpr:l.R.textInputFocus,primary:3599,linux:{primary:0}}})}_getColumnSelectResult(be,ge,ke,We){return p.columnSelectLeft(be.cursorConfig,be,ke)}}),X.CursorColumnSelectRight=(0,L.E_)(new class extends H{constructor(){super({id:"cursorColumnSelectRight",precondition:void 0,kbOpts:{weight:C,kbExpr:l.R.textInputFocus,primary:3601,linux:{primary:0}}})}_getColumnSelectResult(be,ge,ke,We){return p.columnSelectRight(be.cursorConfig,be,ke)}});class Z extends H{constructor(ge){super(ge),this._isPaged=ge.isPaged}_getColumnSelectResult(ge,ke,We,Ge){return p.columnSelectUp(ge.cursorConfig,ge,We,this._isPaged)}}X.CursorColumnSelectUp=(0,L.E_)(new Z({isPaged:!1,id:"cursorColumnSelectUp",precondition:void 0,kbOpts:{weight:C,kbExpr:l.R.textInputFocus,primary:3600,linux:{primary:0}}})),X.CursorColumnSelectPageUp=(0,L.E_)(new Z({isPaged:!0,id:"cursorColumnSelectPageUp",precondition:void 0,kbOpts:{weight:C,kbExpr:l.R.textInputFocus,primary:3595,linux:{primary:0}}}));class N extends H{constructor(ge){super(ge),this._isPaged=ge.isPaged}_getColumnSelectResult(ge,ke,We,Ge){return p.columnSelectDown(ge.cursorConfig,ge,We,this._isPaged)}}X.CursorColumnSelectDown=(0,L.E_)(new N({isPaged:!1,id:"cursorColumnSelectDown",precondition:void 0,kbOpts:{weight:C,kbExpr:l.R.textInputFocus,primary:3602,linux:{primary:0}}})),X.CursorColumnSelectPageDown=(0,L.E_)(new N({isPaged:!0,id:"cursorColumnSelectPageDown",precondition:void 0,kbOpts:{weight:C,kbExpr:l.R.textInputFocus,primary:3596,linux:{primary:0}}}));class G extends m{constructor(){super({id:"cursorMove",precondition:void 0,description:g.S.description})}runCoreEditorCommand(ge,ke){const We=g.S.parse(ke);We&&this._runCursorMove(ge,ke.source,We)}_runCursorMove(ge,ke,We){ge.model.pushStackElement(),ge.setCursorStates(ke,3,G._move(ge,ge.getCursorStates(),We)),ge.revealPrimaryCursor(ke,!0)}static _move(ge,ke,We){const Ge=We.select,Ae=We.value;switch(We.direction){case 0:case 1:case 2:case 3:case 4:case 5:case 6:case 7:case 8:case 9:case 10:return g.c.simpleMove(ge,ke,We.direction,Ge,Ae,We.unit);case 11:case 13:case 12:case 14:return g.c.viewportMove(ge,ke,We.direction,Ge,Ae);default:return null}}}X.CursorMoveImpl=G,X.CursorMove=(0,L.E_)(new G);class O extends m{constructor(ge){super(ge),this._staticArgs=ge.args}runCoreEditorCommand(ge,ke){let We=this._staticArgs;this._staticArgs.value===-1&&(We={direction:this._staticArgs.direction,unit:this._staticArgs.unit,select:this._staticArgs.select,value:ke.pageSize||ge.cursorConfig.pageSize}),ge.model.pushStackElement(),ge.setCursorStates(ke.source,3,g.c.simpleMove(ge,ge.getCursorStates(),We.direction,We.select,We.value,We.unit)),ge.revealPrimaryCursor(ke.source,!0)}}X.CursorLeft=(0,L.E_)(new O({args:{direction:0,unit:0,select:!1,value:1},id:"cursorLeft",precondition:void 0,kbOpts:{weight:C,kbExpr:l.R.textInputFocus,primary:15,mac:{primary:15,secondary:[288]}}})),X.CursorLeftSelect=(0,L.E_)(new O({args:{direction:0,unit:0,select:!0,value:1},id:"cursorLeftSelect",precondition:void 0,kbOpts:{weight:C,kbExpr:l.R.textInputFocus,primary:1039}})),X.CursorRight=(0,L.E_)(new O({args:{direction:1,unit:0,select:!1,value:1},id:"cursorRight",precondition:void 0,kbOpts:{weight:C,kbExpr:l.R.textInputFocus,primary:17,mac:{primary:17,secondary:[292]}}})),X.CursorRightSelect=(0,L.E_)(new O({args:{direction:1,unit:0,select:!0,value:1},id:"cursorRightSelect",precondition:void 0,kbOpts:{weight:C,kbExpr:l.R.textInputFocus,primary:1041}})),X.CursorUp=(0,L.E_)(new O({args:{direction:2,unit:2,select:!1,value:1},id:"cursorUp",precondition:void 0,kbOpts:{weight:C,kbExpr:l.R.textInputFocus,primary:16,mac:{primary:16,secondary:[302]}}})),X.CursorUpSelect=(0,L.E_)(new O({args:{direction:2,unit:2,select:!0,value:1},id:"cursorUpSelect",precondition:void 0,kbOpts:{weight:C,kbExpr:l.R.textInputFocus,primary:1040,secondary:[3088],mac:{primary:1040},linux:{primary:1040}}})),X.CursorPageUp=(0,L.E_)(new O({args:{direction:2,unit:2,select:!1,value:-1},id:"cursorPageUp",precondition:void 0,kbOpts:{weight:C,kbExpr:l.R.textInputFocus,primary:11}})),X.CursorPageUpSelect=(0,L.E_)(new O({args:{direction:2,unit:2,select:!0,value:-1},id:"cursorPageUpSelect",precondition:void 0,kbOpts:{weight:C,kbExpr:l.R.textInputFocus,primary:1035}})),X.CursorDown=(0,L.E_)(new O({args:{direction:3,unit:2,select:!1,value:1},id:"cursorDown",precondition:void 0,kbOpts:{weight:C,kbExpr:l.R.textInputFocus,primary:18,mac:{primary:18,secondary:[300]}}})),X.CursorDownSelect=(0,L.E_)(new O({args:{direction:3,unit:2,select:!0,value:1},id:"cursorDownSelect",precondition:void 0,kbOpts:{weight:C,kbExpr:l.R.textInputFocus,primary:1042,secondary:[3090],mac:{primary:1042},linux:{primary:1042}}})),X.CursorPageDown=(0,L.E_)(new O({args:{direction:3,unit:2,select:!1,value:-1},id:"cursorPageDown",precondition:void 0,kbOpts:{weight:C,kbExpr:l.R.textInputFocus,primary:12}})),X.CursorPageDownSelect=(0,L.E_)(new O({args:{direction:3,unit:2,select:!0,value:-1},id:"cursorPageDownSelect",precondition:void 0,kbOpts:{weight:C,kbExpr:l.R.textInputFocus,primary:1036}})),X.CreateCursor=(0,L.E_)(new class extends m{constructor(){super({id:"createCursor",precondition:void 0})}runCoreEditorCommand(be,ge){let ke;ge.wholeLine?ke=g.c.line(be,be.getPrimaryCursorState(),!1,ge.position,ge.viewPosition):ke=g.c.moveTo(be,be.getPrimaryCursorState(),!1,ge.position,ge.viewPosition);const We=be.getCursorStates();if(We.length>1){const Ge=ke.modelState?ke.modelState.position:null,Ae=ke.viewState?ke.viewState.position:null;for(let he=0,Pe=We.length;he<Pe;he++){const $e=We[he];if(!(Ge&&!$e.modelState.selection.containsPosition(Ge))&&!(Ae&&!$e.viewState.selection.containsPosition(Ae))){We.splice(he,1),be.model.pushStackElement(),be.setCursorStates(ge.source,3,We);return}}}We.push(ke),be.model.pushStackElement(),be.setCursorStates(ge.source,3,We)}}),X.LastCursorMoveToSelect=(0,L.E_)(new class extends m{constructor(){super({id:"_lastCursorMoveToSelect",precondition:void 0})}runCoreEditorCommand(be,ge){const ke=be.getLastAddedCursorIndex(),We=be.getCursorStates(),Ge=We.slice(0);Ge[ke]=g.c.moveTo(be,We[ke],!0,ge.position,ge.viewPosition),be.model.pushStackElement(),be.setCursorStates(ge.source,3,Ge)}});class te extends m{constructor(ge){super(ge),this._inSelectionMode=ge.inSelectionMode}runCoreEditorCommand(ge,ke){ge.model.pushStackElement(),ge.setCursorStates(ke.source,3,g.c.moveToBeginningOfLine(ge,ge.getCursorStates(),this._inSelectionMode)),ge.revealPrimaryCursor(ke.source,!0)}}X.CursorHome=(0,L.E_)(new te({inSelectionMode:!1,id:"cursorHome",precondition:void 0,kbOpts:{weight:C,kbExpr:l.R.textInputFocus,primary:14,mac:{primary:14,secondary:[2063]}}})),X.CursorHomeSelect=(0,L.E_)(new te({inSelectionMode:!0,id:"cursorHomeSelect",precondition:void 0,kbOpts:{weight:C,kbExpr:l.R.textInputFocus,primary:1038,mac:{primary:1038,secondary:[3087]}}}));class oe extends m{constructor(ge){super(ge),this._inSelectionMode=ge.inSelectionMode}runCoreEditorCommand(ge,ke){ge.model.pushStackElement(),ge.setCursorStates(ke.source,3,this._exec(ge.getCursorStates())),ge.revealPrimaryCursor(ke.source,!0)}_exec(ge){const ke=[];for(let We=0,Ge=ge.length;We<Ge;We++){const Ae=ge[We],he=Ae.modelState.position.lineNumber;ke[We]=P.MF.fromModelState(Ae.modelState.move(this._inSelectionMode,he,1,0))}return ke}}X.CursorLineStart=(0,L.E_)(new oe({inSelectionMode:!1,id:"cursorLineStart",precondition:void 0,kbOpts:{weight:C,kbExpr:l.R.textInputFocus,primary:0,mac:{primary:287}}})),X.CursorLineStartSelect=(0,L.E_)(new oe({inSelectionMode:!0,id:"cursorLineStartSelect",precondition:void 0,kbOpts:{weight:C,kbExpr:l.R.textInputFocus,primary:0,mac:{primary:1311}}}));class ue extends m{constructor(ge){super(ge),this._inSelectionMode=ge.inSelectionMode}runCoreEditorCommand(ge,ke){ge.model.pushStackElement(),ge.setCursorStates(ke.source,3,g.c.moveToEndOfLine(ge,ge.getCursorStates(),this._inSelectionMode,ke.sticky||!1)),ge.revealPrimaryCursor(ke.source,!0)}}X.CursorEnd=(0,L.E_)(new ue({inSelectionMode:!1,id:"cursorEnd",precondition:void 0,kbOpts:{args:{sticky:!1},weight:C,kbExpr:l.R.textInputFocus,primary:13,mac:{primary:13,secondary:[2065]}},description:{description:"Go to End",args:[{name:"args",schema:{type:"object",properties:{sticky:{description:b.kg("stickydesc","Stick to the end even when going to longer lines"),type:"boolean",default:!1}}}}]}})),X.CursorEndSelect=(0,L.E_)(new ue({inSelectionMode:!0,id:"cursorEndSelect",precondition:void 0,kbOpts:{args:{sticky:!1},weight:C,kbExpr:l.R.textInputFocus,primary:1037,mac:{primary:1037,secondary:[3089]}},description:{description:"Select to End",args:[{name:"args",schema:{type:"object",properties:{sticky:{description:b.kg("stickydesc","Stick to the end even when going to longer lines"),type:"boolean",default:!1}}}}]}}));class E extends m{constructor(ge){super(ge),this._inSelectionMode=ge.inSelectionMode}runCoreEditorCommand(ge,ke){ge.model.pushStackElement(),ge.setCursorStates(ke.source,3,this._exec(ge,ge.getCursorStates())),ge.revealPrimaryCursor(ke.source,!0)}_exec(ge,ke){const We=[];for(let Ge=0,Ae=ke.length;Ge<Ae;Ge++){const he=ke[Ge],Pe=he.modelState.position.lineNumber,$e=ge.model.getLineMaxColumn(Pe);We[Ge]=P.MF.fromModelState(he.modelState.move(this._inSelectionMode,Pe,$e,0))}return We}}X.CursorLineEnd=(0,L.E_)(new E({inSelectionMode:!1,id:"cursorLineEnd",precondition:void 0,kbOpts:{weight:C,kbExpr:l.R.textInputFocus,primary:0,mac:{primary:291}}})),X.CursorLineEndSelect=(0,L.E_)(new E({inSelectionMode:!0,id:"cursorLineEndSelect",precondition:void 0,kbOpts:{weight:C,kbExpr:l.R.textInputFocus,primary:0,mac:{primary:1315}}}));class Qe extends m{constructor(ge){super(ge),this._inSelectionMode=ge.inSelectionMode}runCoreEditorCommand(ge,ke){ge.model.pushStackElement(),ge.setCursorStates(ke.source,3,g.c.moveToBeginningOfBuffer(ge,ge.getCursorStates(),this._inSelectionMode)),ge.revealPrimaryCursor(ke.source,!0)}}X.CursorTop=(0,L.E_)(new Qe({inSelectionMode:!1,id:"cursorTop",precondition:void 0,kbOpts:{weight:C,kbExpr:l.R.textInputFocus,primary:2062,mac:{primary:2064}}})),X.CursorTopSelect=(0,L.E_)(new Qe({inSelectionMode:!0,id:"cursorTopSelect",precondition:void 0,kbOpts:{weight:C,kbExpr:l.R.textInputFocus,primary:3086,mac:{primary:3088}}}));class Ke extends m{constructor(ge){super(ge),this._inSelectionMode=ge.inSelectionMode}runCoreEditorCommand(ge,ke){ge.model.pushStackElement(),ge.setCursorStates(ke.source,3,g.c.moveToEndOfBuffer(ge,ge.getCursorStates(),this._inSelectionMode)),ge.revealPrimaryCursor(ke.source,!0)}}X.CursorBottom=(0,L.E_)(new Ke({inSelectionMode:!1,id:"cursorBottom",precondition:void 0,kbOpts:{weight:C,kbExpr:l.R.textInputFocus,primary:2061,mac:{primary:2066}}})),X.CursorBottomSelect=(0,L.E_)(new Ke({inSelectionMode:!0,id:"cursorBottomSelect",precondition:void 0,kbOpts:{weight:C,kbExpr:l.R.textInputFocus,primary:3085,mac:{primary:3090}}}));class Se extends m{constructor(){super({id:"editorScroll",precondition:void 0,description:v.description})}runCoreEditorCommand(ge,ke){const We=v.parse(ke);We&&this._runEditorScroll(ge,ke.source,We)}_runEditorScroll(ge,ke,We){const Ge=this._computeDesiredScrollTop(ge,We);if(We.revealCursor){const Ae=ge.getCompletelyVisibleViewRangeAtScrollTop(Ge);ge.setCursorStates(ke,3,[g.c.findPositionInViewportIfOutside(ge,ge.getPrimaryCursorState(),Ae,We.select)])}ge.viewLayout.setScrollPosition({scrollTop:Ge},0)}_computeDesiredScrollTop(ge,ke){if(ke.unit===1){const Ae=ge.getCompletelyVisibleViewRange(),he=ge.coordinatesConverter.convertViewRangeToModelRange(Ae);let Pe;ke.direction===1?Pe=Math.max(1,he.startLineNumber-ke.value):Pe=Math.min(ge.model.getLineCount(),he.startLineNumber+ke.value);const $e=ge.coordinatesConverter.convertModelPositionToViewPosition(new B.y(Pe,1));return ge.viewLayout.getVerticalOffsetForLineNumber($e.lineNumber)}if(ke.unit===5){let Ae=0;return ke.direction===2&&(Ae=ge.model.getLineCount()-ge.cursorConfig.pageSize),ge.viewLayout.getVerticalOffsetForLineNumber(Ae)}let We;ke.unit===3?We=ge.cursorConfig.pageSize*ke.value:ke.unit===4?We=Math.round(ge.cursorConfig.pageSize/2)*ke.value:We=ke.value;const Ge=(ke.direction===1?-1:1)*We;return ge.viewLayout.getCurrentScrollTop()+Ge*ge.cursorConfig.lineHeight}}X.EditorScrollImpl=Se,X.EditorScroll=(0,L.E_)(new Se),X.ScrollLineUp=(0,L.E_)(new class extends m{constructor(){super({id:"scrollLineUp",precondition:void 0,kbOpts:{weight:C,kbExpr:l.R.textInputFocus,primary:2064,mac:{primary:267}}})}runCoreEditorCommand(be,ge){X.EditorScroll._runEditorScroll(be,ge.source,{direction:1,unit:2,value:1,revealCursor:!1,select:!1})}}),X.ScrollPageUp=(0,L.E_)(new class extends m{constructor(){super({id:"scrollPageUp",precondition:void 0,kbOpts:{weight:C,kbExpr:l.R.textInputFocus,primary:2059,win:{primary:523},linux:{primary:523}}})}runCoreEditorCommand(be,ge){X.EditorScroll._runEditorScroll(be,ge.source,{direction:1,unit:3,value:1,revealCursor:!1,select:!1})}}),X.ScrollEditorTop=(0,L.E_)(new class extends m{constructor(){super({id:"scrollEditorTop",precondition:void 0,kbOpts:{weight:C,kbExpr:l.R.textInputFocus}})}runCoreEditorCommand(be,ge){X.EditorScroll._runEditorScroll(be,ge.source,{direction:1,unit:5,value:1,revealCursor:!1,select:!1})}}),X.ScrollLineDown=(0,L.E_)(new class extends m{constructor(){super({id:"scrollLineDown",precondition:void 0,kbOpts:{weight:C,kbExpr:l.R.textInputFocus,primary:2066,mac:{primary:268}}})}runCoreEditorCommand(be,ge){X.EditorScroll._runEditorScroll(be,ge.source,{direction:2,unit:2,value:1,revealCursor:!1,select:!1})}}),X.ScrollPageDown=(0,L.E_)(new class extends m{constructor(){super({id:"scrollPageDown",precondition:void 0,kbOpts:{weight:C,kbExpr:l.R.textInputFocus,primary:2060,win:{primary:524},linux:{primary:524}}})}runCoreEditorCommand(be,ge){X.EditorScroll._runEditorScroll(be,ge.source,{direction:2,unit:3,value:1,revealCursor:!1,select:!1})}}),X.ScrollEditorBottom=(0,L.E_)(new class extends m{constructor(){super({id:"scrollEditorBottom",precondition:void 0,kbOpts:{weight:C,kbExpr:l.R.textInputFocus}})}runCoreEditorCommand(be,ge){X.EditorScroll._runEditorScroll(be,ge.source,{direction:2,unit:5,value:1,revealCursor:!1,select:!1})}});class Me extends m{constructor(ge){super(ge),this._inSelectionMode=ge.inSelectionMode}runCoreEditorCommand(ge,ke){ge.model.pushStackElement(),ge.setCursorStates(ke.source,3,[g.c.word(ge,ge.getPrimaryCursorState(),this._inSelectionMode,ke.position)]),ge.revealPrimaryCursor(ke.source,!0)}}X.WordSelect=(0,L.E_)(new Me({inSelectionMode:!1,id:"_wordSelect",precondition:void 0})),X.WordSelectDrag=(0,L.E_)(new Me({inSelectionMode:!0,id:"_wordSelectDrag",precondition:void 0})),X.LastCursorWordSelect=(0,L.E_)(new class extends m{constructor(){super({id:"lastCursorWordSelect",precondition:void 0})}runCoreEditorCommand(be,ge){const ke=be.getLastAddedCursorIndex(),We=be.getCursorStates(),Ge=We.slice(0),Ae=We[ke];Ge[ke]=g.c.word(be,Ae,Ae.modelState.hasSelection(),ge.position),be.model.pushStackElement(),be.setCursorStates(ge.source,3,Ge)}});class ce extends m{constructor(ge){super(ge),this._inSelectionMode=ge.inSelectionMode}runCoreEditorCommand(ge,ke){ge.model.pushStackElement(),ge.setCursorStates(ke.source,3,[g.c.line(ge,ge.getPrimaryCursorState(),this._inSelectionMode,ke.position,ke.viewPosition)]),ge.revealPrimaryCursor(ke.source,!1)}}X.LineSelect=(0,L.E_)(new ce({inSelectionMode:!1,id:"_lineSelect",precondition:void 0})),X.LineSelectDrag=(0,L.E_)(new ce({inSelectionMode:!0,id:"_lineSelectDrag",precondition:void 0}));class pe extends m{constructor(ge){super(ge),this._inSelectionMode=ge.inSelectionMode}runCoreEditorCommand(ge,ke){const We=ge.getLastAddedCursorIndex(),Ge=ge.getCursorStates(),Ae=Ge.slice(0);Ae[We]=g.c.line(ge,Ge[We],this._inSelectionMode,ke.position,ke.viewPosition),ge.model.pushStackElement(),ge.setCursorStates(ke.source,3,Ae)}}X.LastCursorLineSelect=(0,L.E_)(new pe({inSelectionMode:!1,id:"lastCursorLineSelect",precondition:void 0})),X.LastCursorLineSelectDrag=(0,L.E_)(new pe({inSelectionMode:!0,id:"lastCursorLineSelectDrag",precondition:void 0})),X.CancelSelection=(0,L.E_)(new class extends m{constructor(){super({id:"cancelSelection",precondition:l.R.hasNonEmptySelection,kbOpts:{weight:C,kbExpr:l.R.textInputFocus,primary:9,secondary:[1033]}})}runCoreEditorCommand(be,ge){be.model.pushStackElement(),be.setCursorStates(ge.source,3,[g.c.cancelSelection(be,be.getPrimaryCursorState())]),be.revealPrimaryCursor(ge.source,!0)}}),X.RemoveSecondaryCursors=(0,L.E_)(new class extends m{constructor(){super({id:"removeSecondaryCursors",precondition:l.R.hasMultipleSelections,kbOpts:{weight:C+1,kbExpr:l.R.textInputFocus,primary:9,secondary:[1033]}})}runCoreEditorCommand(be,ge){be.model.pushStackElement(),be.setCursorStates(ge.source,3,[be.getPrimaryCursorState()]),be.revealPrimaryCursor(ge.source,!0),(0,$.h5)(b.kg("removedCursor","Removed secondary cursors"))}}),X.RevealLine=(0,L.E_)(new class extends m{constructor(){super({id:"revealLine",precondition:void 0,description:k.description})}runCoreEditorCommand(be,ge){const ke=ge,We=ke.lineNumber||0;let Ge=typeof We=="number"?We+1:parseInt(We)+1;Ge<1&&(Ge=1);const Ae=be.model.getLineCount();Ge>Ae&&(Ge=Ae);const he=new T.Q(Ge,1,Ge,be.model.getLineMaxColumn(Ge));let Pe=0;if(ke.at)switch(ke.at){case k.RawAtArgument.Top:Pe=3;break;case k.RawAtArgument.Center:Pe=1;break;case k.RawAtArgument.Bottom:Pe=4;break;default:break}const $e=be.coordinatesConverter.convertModelRangeToViewRange(he);be.revealRange(ge.source,!1,$e,Pe,0)}}),X.SelectAll=new class extends D{constructor(){super(L.tc)}runDOMCommand(){o.isFirefox&&(document.activeElement.focus(),document.activeElement.select()),document.execCommand("selectAll")}runEditorCommand(be,ge,ke){const We=ge._getViewModel();We&&this.runCoreEditorCommand(We,ke)}runCoreEditorCommand(be,ge){be.model.pushStackElement(),be.setCursorStates("keyboard",3,[g.c.selectAll(be,be.getPrimaryCursorState())])}},X.SetSelection=(0,L.E_)(new class extends m{constructor(){super({id:"setSelection",precondition:void 0})}runCoreEditorCommand(be,ge){be.model.pushStackElement(),be.setCursorStates(ge.source,3,[P.MF.fromModelSelection(ge.selection)])}})})(x||(x={}));const A=u.M$.and(l.R.textInputFocus,l.R.columnSelection);function W(X,R){w.f.registerKeybindingRule({id:X,primary:R,when:A,weight:C+1})}W(x.CursorColumnSelectLeft.id,1039),W(x.CursorColumnSelectRight.id,1041),W(x.CursorColumnSelectUp.id,1040),W(x.CursorColumnSelectPageUp.id,1035),W(x.CursorColumnSelectDown.id,1042),W(x.CursorColumnSelectPageDown.id,1036);function Y(X){return X.register(),X}var ne;(function(X){class R extends L.DX{runEditorCommand(Z,N,G){const O=N._getViewModel();O&&this.runCoreEditingCommand(N,O,G||{})}}X.CoreEditingCommand=R,X.LineBreakInsert=(0,L.E_)(new class extends R{constructor(){super({id:"lineBreakInsert",precondition:l.R.writable,kbOpts:{weight:C,kbExpr:l.R.textInputFocus,primary:0,mac:{primary:301}}})}runCoreEditingCommand(H,Z,N){H.pushUndoStop(),H.executeCommands(this.id,h.TK.lineBreakInsert(Z.cursorConfig,Z.model,Z.getCursorStates().map(G=>G.modelState.selection)))}}),X.Outdent=(0,L.E_)(new class extends R{constructor(){super({id:"outdent",precondition:l.R.writable,kbOpts:{weight:C,kbExpr:u.M$.and(l.R.editorTextFocus,l.R.tabDoesNotMoveFocus),primary:1026}})}runCoreEditingCommand(H,Z,N){H.pushUndoStop(),H.executeCommands(this.id,h.TK.outdent(Z.cursorConfig,Z.model,Z.getCursorStates().map(G=>G.modelState.selection))),H.pushUndoStop()}}),X.Tab=(0,L.E_)(new class extends R{constructor(){super({id:"tab",precondition:l.R.writable,kbOpts:{weight:C,kbExpr:u.M$.and(l.R.editorTextFocus,l.R.tabDoesNotMoveFocus),primary:2}})}runCoreEditingCommand(H,Z,N){H.pushUndoStop(),H.executeCommands(this.id,h.TK.tab(Z.cursorConfig,Z.model,Z.getCursorStates().map(G=>G.modelState.selection))),H.pushUndoStop()}}),X.DeleteLeft=(0,L.E_)(new class extends R{constructor(){super({id:"deleteLeft",precondition:void 0,kbOpts:{weight:C,kbExpr:l.R.textInputFocus,primary:1,secondary:[1025],mac:{primary:1,secondary:[1025,294,257]}}})}runCoreEditingCommand(H,Z,N){const[G,O]=d.g.deleteLeft(Z.getPrevEditOperationType(),Z.cursorConfig,Z.model,Z.getCursorStates().map(te=>te.modelState.selection),Z.getCursorAutoClosedCharacters());G&&H.pushUndoStop(),H.executeCommands(this.id,O),Z.setPrevEditOperationType(2)}}),X.DeleteRight=(0,L.E_)(new class extends R{constructor(){super({id:"deleteRight",precondition:void 0,kbOpts:{weight:C,kbExpr:l.R.textInputFocus,primary:20,mac:{primary:20,secondary:[290,276]}}})}runCoreEditingCommand(H,Z,N){const[G,O]=d.g.deleteRight(Z.getPrevEditOperationType(),Z.cursorConfig,Z.model,Z.getCursorStates().map(te=>te.modelState.selection));G&&H.pushUndoStop(),H.executeCommands(this.id,O),Z.setPrevEditOperationType(3)}}),X.Undo=new class extends D{constructor(){super(L.aU)}runDOMCommand(){document.execCommand("undo")}runEditorCommand(H,Z,N){if(!(!Z.hasModel()||Z.getOption(83)===!0))return Z.getModel().undo()}},X.Redo=new class extends D{constructor(){super(L.ih)}runDOMCommand(){document.execCommand("redo")}runEditorCommand(H,Z,N){if(!(!Z.hasModel()||Z.getOption(83)===!0))return Z.getModel().redo()}}})(ne||(ne={}));class j extends L.uB{constructor(R,H,Z){super({id:R,precondition:void 0,description:Z}),this._handlerId=H}runCommand(R,H){const Z=R.get(U.T).getFocusedCodeEditor();Z&&Z.trigger("keyboard",this._handlerId,H)}}function Q(X,R){Y(new j("default:"+X,X)),Y(new j(X,X,R))}Q("type",{description:"Type",args:[{name:"args",schema:{type:"object",required:["text"],properties:{text:{type:"string"}}}}]}),Q("replacePreviousChar"),Q("compositionType"),Q("compositionStart"),Q("compositionEnd"),Q("paste"),Q("cut")},73027:(rt,ye,y)=>{y.d(ye,{C1:()=>o.C1,GK:()=>K});var b=y(82399),o=y(32802);const K=(0,b.u1)("quickInputService")},76243:(rt,ye,y)=>{y.d(ye,{k:()=>o});var b=y(82399);const o=(0,b.u1)("telemetryService")},76680:(rt,ye,y)=>{y.d(ye,{x:()=>lr});var b=y(80886),o=y(50946),K=function(Le,e,i,r){var _=arguments.length,S=_<3?e:r===null?r=Object.getOwnPropertyDescriptor(e,i):r,z;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")S=Reflect.decorate(Le,e,i,r);else for(var ie=Le.length-1;ie>=0;ie--)(z=Le[ie])&&(S=(_<3?z(S):_>3?z(e,i,S):z(e,i))||S);return _>3&&S&&Object.defineProperty(e,i,S),S},$=function(Le,e){return function(i,r){e(i,r,Le)}};let L=class{constructor(e,i){}dispose(){}};L.ID="editor.contrib.markerDecorations",L=K([$(1,b.A)],L),(0,o.HW)(L.ID,L);var U=y(3765),P=y(14333),B=y(94327),T=y(2106),p=y(10998),d=y(13072),g=y(55893),h=y(13338),l=y(71386),u=y(63339),w=y(5711),C=y(41106);class m{constructor(e,i){this.key=e,this.migrate=i}apply(e){const i=m._read(e,this.key),r=S=>m._read(e,S),_=(S,z)=>m._write(e,S,z);this.migrate(i,r,_)}static _read(e,i){if(typeof e>"u")return;const r=i.indexOf(".");if(r>=0){const _=i.substring(0,r);return this._read(e[_],i.substring(r+1))}return e[i]}static _write(e,i,r){const _=i.indexOf(".");if(_>=0){const S=i.substring(0,_);e[S]=e[S]||{},this._write(e[S],i.substring(_+1),r);return}e[i]=r}}m.items=[];function v(Le,e){m.items.push(new m(Le,e))}function k(Le,e){v(Le,(i,r,_)=>{if(typeof i<"u"){for(const[S,z]of e)if(i===S){_(Le,z);return}}})}function D(Le){m.items.forEach(e=>e.apply(Le))}k("wordWrap",[[!0,"on"],[!1,"off"]]),k("lineNumbers",[[!0,"on"],[!1,"off"]]),k("cursorBlinking",[["visible","solid"]]),k("renderWhitespace",[[!0,"boundary"],[!1,"none"]]),k("renderLineHighlight",[[!0,"line"],[!1,"none"]]),k("acceptSuggestionOnEnter",[[!0,"on"],[!1,"off"]]),k("tabCompletion",[[!1,"off"],[!0,"onlySnippets"]]),k("hover",[[!0,{enabled:!0}],[!1,{enabled:!1}]]),k("parameterHints",[[!0,{enabled:!0}],[!1,{enabled:!1}]]),k("autoIndent",[[!1,"advanced"],[!0,"full"]]),k("matchBrackets",[[!0,"always"],[!1,"never"]]),v("autoClosingBrackets",(Le,e,i)=>{Le===!1&&(i("autoClosingBrackets","never"),typeof e("autoClosingQuotes")>"u"&&i("autoClosingQuotes","never"),typeof e("autoSurround")>"u"&&i("autoSurround","never"))}),v("renderIndentGuides",(Le,e,i)=>{typeof Le<"u"&&(i("renderIndentGuides",void 0),typeof e("guides.indentation")>"u"&&i("guides.indentation",!!Le))}),v("highlightActiveIndentGuide",(Le,e,i)=>{typeof Le<"u"&&(i("highlightActiveIndentGuide",void 0),typeof e("guides.highlightActiveIndentation")>"u"&&i("guides.highlightActiveIndentation",!!Le))});const x={method:"showMethods",function:"showFunctions",constructor:"showConstructors",deprecated:"showDeprecated",field:"showFields",variable:"showVariables",class:"showClasses",struct:"showStructs",interface:"showInterfaces",module:"showModules",property:"showProperties",event:"showEvents",operator:"showOperators",unit:"showUnits",value:"showValues",constant:"showConstants",enum:"showEnums",enumMember:"showEnumMembers",keyword:"showKeywords",text:"showWords",color:"showColors",file:"showFiles",reference:"showReferences",folder:"showFolders",typeParameter:"showTypeParameters",snippet:"showSnippets"};v("suggest.filteredTypes",(Le,e,i)=>{if(Le&&typeof Le=="object"){for(const r of Object.entries(x))Le[r[0]]===!1&&typeof e(`suggest.${r[1]}`)>"u"&&i(`suggest.${r[1]}`,!1);i("suggest.filteredTypes",void 0)}}),v("quickSuggestions",(Le,e,i)=>{if(typeof Le=="boolean"){const r=Le?"on":"off";i("quickSuggestions",{comments:r,strings:r,other:r})}});var A=y(25155),W=y(66476),Y=y(84587),ne=y(28060),j=y(53909),Q=function(Le,e,i,r){var _=arguments.length,S=_<3?e:r===null?r=Object.getOwnPropertyDescriptor(e,i):r,z;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")S=Reflect.decorate(Le,e,i,r);else for(var ie=Le.length-1;ie>=0;ie--)(z=Le[ie])&&(S=(_<3?z(S):_>3?z(e,i,S):z(e,i))||S);return _>3&&S&&Object.defineProperty(e,i,S),S},X=function(Le,e){return function(i,r){e(i,r,Le)}};let R=class extends p.jG{constructor(e,i,r,_){super(),this._accessibilityService=_,this._onDidChange=this._register(new T.vl),this.onDidChange=this._onDidChange.event,this._onDidChangeFast=this._register(new T.vl),this.onDidChangeFast=this._onDidChangeFast.event,this._isDominatedByLongLines=!1,this._viewLineCount=1,this._lineNumbersDigitCount=1,this._reservedHeight=0,this._computeOptionsMemory=new W.n0,this.isSimpleWidget=e,this._containerObserver=this._register(new w.u(r,i.dimension)),this._rawOptions=te(i),this._validatedOptions=O.validateOptions(this._rawOptions),this.options=this._computeOptions(),this.options.get(10)&&this._containerObserver.startObserving(),this._register(Y.D.onDidChangeZoomLevel(()=>this._recomputeOptions())),this._register(A.M.onDidChangeTabFocus(()=>this._recomputeOptions())),this._register(this._containerObserver.onDidChange(()=>this._recomputeOptions())),this._register(C.T.onDidChange(()=>this._recomputeOptions())),this._register(g.PixelRatio.onDidChange(()=>this._recomputeOptions())),this._register(this._accessibilityService.onDidChangeScreenReaderOptimized(()=>this._recomputeOptions()))}_recomputeOptions(){const e=this._computeOptions(),i=O.checkEquals(this.options,e);i!==null&&(this.options=e,this._onDidChangeFast.fire(i),this._onDidChange.fire(i))}_computeOptions(){const e=this._readEnvConfiguration(),i=ne._8.createFromValidatedSettings(this._validatedOptions,e.pixelRatio,this.isSimpleWidget),r=this._readFontInfo(i),_={memory:this._computeOptionsMemory,outerWidth:e.outerWidth,outerHeight:e.outerHeight-this._reservedHeight,fontInfo:r,extraEditorClassName:e.extraEditorClassName,isDominatedByLongLines:this._isDominatedByLongLines,viewLineCount:this._viewLineCount,lineNumbersDigitCount:this._lineNumbersDigitCount,emptySelectionClipboard:e.emptySelectionClipboard,pixelRatio:e.pixelRatio,tabFocusMode:A.M.getTabFocusMode(),accessibilitySupport:e.accessibilitySupport};return O.computeOptions(this._validatedOptions,_)}_readEnvConfiguration(){return{extraEditorClassName:Z(),outerWidth:this._containerObserver.getWidth(),outerHeight:this._containerObserver.getHeight(),emptySelectionClipboard:g.isWebKit||g.isFirefox,pixelRatio:g.PixelRatio.value,accessibilitySupport:this._accessibilityService.isScreenReaderOptimized()?2:this._accessibilityService.getAccessibilitySupport()}}_readFontInfo(e){return C.T.readFontInfo(e)}getRawOptions(){return this._rawOptions}updateOptions(e){const i=te(e);O.applyUpdate(this._rawOptions,i)&&(this._validatedOptions=O.validateOptions(this._rawOptions),this._recomputeOptions())}observeContainer(e){this._containerObserver.observe(e)}setIsDominatedByLongLines(e){this._isDominatedByLongLines!==e&&(this._isDominatedByLongLines=e,this._recomputeOptions())}setModelLineCount(e){const i=H(e);this._lineNumbersDigitCount!==i&&(this._lineNumbersDigitCount=i,this._recomputeOptions())}setViewLineCount(e){this._viewLineCount!==e&&(this._viewLineCount=e,this._recomputeOptions())}setReservedHeight(e){this._reservedHeight!==e&&(this._reservedHeight=e,this._recomputeOptions())}};R=Q([X(3,j.j)],R);function H(Le){let e=0;for(;Le;)Le=Math.floor(Le/10),e++;return e||1}function Z(){let Le="";return!g.isSafari&&!g.isWebkitWebView&&(Le+="no-user-select "),g.isSafari&&(Le+="no-minimap-shadow ",Le+="enable-user-select "),u.zx&&(Le+="mac "),Le}class N{constructor(){this._values=[]}_read(e){return this._values[e]}get(e){return this._values[e]}_write(e,i){this._values[e]=i}}class G{constructor(){this._values=[]}_read(e){if(e>=this._values.length)throw new Error("Cannot read uninitialized value");return this._values[e]}get(e){return this._read(e)}_write(e,i){this._values[e]=i}}class O{static validateOptions(e){const i=new N;for(const r of W.BE){const _=r.name==="_never_"?void 0:e[r.name];i._write(r.id,r.validate(_))}return i}static computeOptions(e,i){const r=new G;for(const _ of W.BE)r._write(_.id,_.compute(i,r,e._read(_.id)));return r}static _deepEquals(e,i){if(typeof e!="object"||typeof i!="object"||!e||!i)return e===i;if(Array.isArray(e)||Array.isArray(i))return Array.isArray(e)&&Array.isArray(i)?h.aI(e,i):!1;if(Object.keys(e).length!==Object.keys(i).length)return!1;for(const r in e)if(!O._deepEquals(e[r],i[r]))return!1;return!0}static checkEquals(e,i){const r=[];let _=!1;for(const S of W.BE){const z=!O._deepEquals(e._read(S.id),i._read(S.id));r[S.id]=z,z&&(_=!0)}return _?new W.lw(r):null}static applyUpdate(e,i){let r=!1;for(const _ of W.BE)if(i.hasOwnProperty(_.name)){const S=_.applyUpdate(e[_.name],i[_.name]);e[_.name]=S.newValue,r=r||S.didChange}return r}}function te(Le){const e=l.Go(Le);return D(e),e}var oe=y(87301),ue=y(93702),E=y(5043),Qe=y(30474),Ke=y(9715),Se=y(65958),Me=y(58574);class ce extends p.jG{constructor(){super(),this._shouldRender=!0}shouldRender(){return this._shouldRender}forceShouldRender(){this._shouldRender=!0}setShouldRender(){this._shouldRender=!0}onDidRender(){this._shouldRender=!1}onCompositionStart(e){return!1}onCompositionEnd(e){return!1}onConfigurationChanged(e){return!1}onCursorStateChanged(e){return!1}onDecorationsChanged(e){return!1}onFlushed(e){return!1}onFocusChanged(e){return!1}onLanguageConfigurationChanged(e){return!1}onLineMappingChanged(e){return!1}onLinesChanged(e){return!1}onLinesDeleted(e){return!1}onLinesInserted(e){return!1}onRevealRangeRequest(e){return!1}onScrollChanged(e){return!1}onThemeChanged(e){return!1}onTokensChanged(e){return!1}onTokensColorsChanged(e){return!1}onZonesChanged(e){return!1}handleEvents(e){let i=!1;for(let r=0,_=e.length;r<_;r++){const S=e[r];switch(S.type){case 0:this.onCompositionStart(S)&&(i=!0);break;case 1:this.onCompositionEnd(S)&&(i=!0);break;case 2:this.onConfigurationChanged(S)&&(i=!0);break;case 3:this.onCursorStateChanged(S)&&(i=!0);break;case 4:this.onDecorationsChanged(S)&&(i=!0);break;case 5:this.onFlushed(S)&&(i=!0);break;case 6:this.onFocusChanged(S)&&(i=!0);break;case 7:this.onLanguageConfigurationChanged(S)&&(i=!0);break;case 8:this.onLineMappingChanged(S)&&(i=!0);break;case 9:this.onLinesChanged(S)&&(i=!0);break;case 10:this.onLinesDeleted(S)&&(i=!0);break;case 11:this.onLinesInserted(S)&&(i=!0);break;case 12:this.onRevealRangeRequest(S)&&(i=!0);break;case 13:this.onScrollChanged(S)&&(i=!0);break;case 15:this.onTokensChanged(S)&&(i=!0);break;case 14:this.onThemeChanged(S)&&(i=!0);break;case 16:this.onTokensColorsChanged(S)&&(i=!0);break;case 17:this.onZonesChanged(S)&&(i=!0);break;default:console.info("View received unknown event: "),console.info(S)}}i&&(this._shouldRender=!0)}}class pe extends ce{constructor(e){super(),this._context=e,this._context.addEventHandler(this)}dispose(){this._context.removeEventHandler(this),super.dispose()}}class be{static write(e,i){e.setAttribute("data-mprt",String(i))}static read(e){const i=e.getAttribute("data-mprt");return i===null?0:parseInt(i,10)}static collect(e,i){const r=[];let _=0;for(;e&&e!==document.body&&e!==i;)e.nodeType===e.ELEMENT_NODE&&(r[_++]=this.read(e)),e=e.parentElement;const S=new Uint8Array(_);for(let z=0;z<_;z++)S[z]=r[_-z-1];return S}}class ge{constructor(e,i){this._restrictedRenderingContextBrand=void 0,this._viewLayout=e,this.viewportData=i,this.scrollWidth=this._viewLayout.getScrollWidth(),this.scrollHeight=this._viewLayout.getScrollHeight(),this.visibleRange=this.viewportData.visibleRange,this.bigNumbersDelta=this.viewportData.bigNumbersDelta;const r=this._viewLayout.getCurrentViewport();this.scrollTop=r.top,this.scrollLeft=r.left,this.viewportWidth=r.width,this.viewportHeight=r.height}getScrolledTopFromAbsoluteTop(e){return e-this.scrollTop}getVerticalOffsetForLineNumber(e){return this._viewLayout.getVerticalOffsetForLineNumber(e)}getDecorationsInViewport(){return this.viewportData.getDecorationsInViewport()}}class ke extends ge{constructor(e,i,r){super(e,i),this._renderingContextBrand=void 0,this._viewLines=r}linesVisibleRangesForRange(e,i){return this._viewLines.linesVisibleRangesForRange(e,i)}visibleRangeForPosition(e){return this._viewLines.visibleRangeForPosition(e)}}class We{constructor(e,i,r){this.outsideRenderedLine=e,this.lineNumber=i,this.ranges=r}}class Ge{constructor(e,i){this._horizontalRangeBrand=void 0,this.left=Math.round(e),this.width=Math.round(i)}static from(e){const i=new Array(e.length);for(let r=0,_=e.length;r<_;r++){const S=e[r];i[r]=new Ge(S.left,S.width)}return i}toString(){return`[${this.left},${this.width}]`}}class Ae{constructor(e,i){this._floatHorizontalRangeBrand=void 0,this.left=e,this.width=i}toString(){return`[${this.left},${this.width}]`}static compare(e,i){return e.left-i.left}}class he{constructor(e,i){this.outsideRenderedLine=e,this.originalLeft=i,this.left=Math.round(this.originalLeft)}}class Pe{constructor(e,i){this.outsideRenderedLine=e,this.ranges=i}}class $e{static _createRange(){return this._handyReadyRange||(this._handyReadyRange=document.createRange()),this._handyReadyRange}static _detachRange(e,i){e.selectNodeContents(i)}static _readClientRects(e,i,r,_,S){const z=this._createRange();try{return z.setStart(e,i),z.setEnd(r,_),z.getClientRects()}catch{return null}finally{this._detachRange(z,S)}}static _mergeAdjacentRanges(e){if(e.length===1)return e;e.sort(Ae.compare);const i=[];let r=0,_=e[0];for(let S=1,z=e.length;S<z;S++){const ie=e[S];_.left+_.width+.9>=ie.left?_.width=Math.max(_.width,ie.left+ie.width-_.left):(i[r++]=_,_=ie)}return i[r++]=_,i}static _createHorizontalRangesFromClientRects(e,i,r){if(!e||e.length===0)return null;const _=[];for(let S=0,z=e.length;S<z;S++){const ie=e[S];_[S]=new Ae(Math.max(0,(ie.left-i)/r),ie.width/r)}return this._mergeAdjacentRanges(_)}static readHorizontalRanges(e,i,r,_,S,z,ie,re){const me=e.children.length-1;if(0>me)return null;if(i=Math.min(me,Math.max(0,i)),_=Math.min(me,Math.max(0,_)),i===_&&r===S&&r===0&&!e.children[i].firstChild){const Je=e.children[i].getClientRects();return this._createHorizontalRangesFromClientRects(Je,z,ie)}i!==_&&_>0&&S===0&&(_--,S=1073741824);let we=e.children[i].firstChild,Be=e.children[_].firstChild;if((!we||!Be)&&(!we&&r===0&&i>0&&(we=e.children[i-1].firstChild,r=1073741824),!Be&&S===0&&_>0&&(Be=e.children[_-1].firstChild,S=1073741824)),!we||!Be)return null;r=Math.min(we.textContent.length,Math.max(0,r)),S=Math.min(Be.textContent.length,Math.max(0,S));const Re=this._readClientRects(we,r,Be,S,re);return this._createHorizontalRangesFromClientRects(Re,z,ie)}}var it=y(45561),ft=y(39723),Wt=y(89563);const tt=function(){return u.ib?!0:!(u.j9||g.isFirefox||g.isSafari)}();let Ye=!0;class ht{constructor(e,i){this._domNode=e,this._clientRectDeltaLeft=0,this._clientRectScale=1,this._clientRectRead=!1,this.endNode=i}readClientRect(){if(!this._clientRectRead){this._clientRectRead=!0;const e=this._domNode.getBoundingClientRect();this._clientRectDeltaLeft=e.left,this._clientRectScale=e.width/this._domNode.offsetWidth}}get clientRectDeltaLeft(){return this._clientRectRead||this.readClientRect(),this._clientRectDeltaLeft}get clientRectScale(){return this._clientRectRead||this.readClientRect(),this._clientRectScale}}class Lt{constructor(e,i){this.themeType=i;const r=e.options,_=r.get(46);this.renderWhitespace=r.get(90),this.renderControlCharacters=r.get(85),this.spaceWidth=_.spaceWidth,this.middotWidth=_.middotWidth,this.wsmiddotWidth=_.wsmiddotWidth,this.useMonospaceOptimizations=_.isMonospace&&!r.get(29),this.canUseHalfwidthRightwardsArrow=_.canUseHalfwidthRightwardsArrow,this.lineHeight=r.get(61),this.stopRenderingLineAfter=r.get(107),this.fontLigatures=r.get(47)}equals(e){return this.themeType===e.themeType&&this.renderWhitespace===e.renderWhitespace&&this.renderControlCharacters===e.renderControlCharacters&&this.spaceWidth===e.spaceWidth&&this.middotWidth===e.middotWidth&&this.wsmiddotWidth===e.wsmiddotWidth&&this.useMonospaceOptimizations===e.useMonospaceOptimizations&&this.canUseHalfwidthRightwardsArrow===e.canUseHalfwidthRightwardsArrow&&this.lineHeight===e.lineHeight&&this.stopRenderingLineAfter===e.stopRenderingLineAfter&&this.fontLigatures===e.fontLigatures}}class Rt{constructor(e){this._options=e,this._isMaybeInvalid=!0,this._renderedViewLine=null}getDomNode(){return this._renderedViewLine&&this._renderedViewLine.domNode?this._renderedViewLine.domNode.domNode:null}setDomNode(e){if(this._renderedViewLine)this._renderedViewLine.domNode=(0,E.Z)(e);else throw new Error("I have no rendered view line to set the dom node to...")}onContentChanged(){this._isMaybeInvalid=!0}onTokensChanged(){this._isMaybeInvalid=!0}onDecorationsChanged(){this._isMaybeInvalid=!0}onOptionsChanged(e){this._isMaybeInvalid=!0,this._options=e}onSelectionChanged(){return(0,Wt.Bb)(this._options.themeType)||this._options.renderWhitespace==="selection"?(this._isMaybeInvalid=!0,!0):!1}renderLine(e,i,r,_){if(this._isMaybeInvalid===!1)return!1;this._isMaybeInvalid=!1;const S=r.getViewLineRenderingData(e),z=this._options,ie=it.d.filter(S.inlineDecorations,e,S.minColumn,S.maxColumn);let re=null;if((0,Wt.Bb)(z.themeType)||this._options.renderWhitespace==="selection"){const Be=r.selections;for(const Re of Be){if(Re.endLineNumber<e||Re.startLineNumber>e)continue;const Je=Re.startLineNumber===e?Re.startColumn:S.minColumn,st=Re.endLineNumber===e?Re.endColumn:S.maxColumn;Je<st&&((0,Wt.Bb)(z.themeType)||this._options.renderWhitespace!=="selection"?ie.push(new it.d(Je,st,"inline-selected-text",0)):(re||(re=[]),re.push(new ft.MT(Je-1,st-1))))}}const le=new ft.zL(z.useMonospaceOptimizations,z.canUseHalfwidthRightwardsArrow,S.content,S.continuesWithWrappedLine,S.isBasicASCII,S.containsRTL,S.minColumn-1,S.tokens,ie,S.tabSize,S.startVisibleColumn,z.spaceWidth,z.middotWidth,z.wsmiddotWidth,z.stopRenderingLineAfter,z.renderWhitespace,z.renderControlCharacters,z.fontLigatures!==W.Bc.OFF,re);if(this._renderedViewLine&&this._renderedViewLine.input.equals(le))return!1;_.appendASCIIString('<div style="top:'),_.appendASCIIString(String(i)),_.appendASCIIString("px;height:"),_.appendASCIIString(String(this._options.lineHeight)),_.appendASCIIString('px;" class="'),_.appendASCIIString(Rt.CLASS_NAME),_.appendASCIIString('">');const me=(0,ft.UW)(le,_);_.appendASCIIString("</div>");let we=null;return Ye&&tt&&S.isBasicASCII&&z.useMonospaceOptimizations&&me.containsForeignElements===0&&S.content.length<300&&le.lineTokens.getCount()<100&&(we=new Ie(this._renderedViewLine?this._renderedViewLine.domNode:null,le,me.characterMapping)),we||(we=bt(this._renderedViewLine?this._renderedViewLine.domNode:null,le,me.characterMapping,me.containsRTL,me.containsForeignElements)),this._renderedViewLine=we,!0}layoutLine(e,i){this._renderedViewLine&&this._renderedViewLine.domNode&&(this._renderedViewLine.domNode.setTop(i),this._renderedViewLine.domNode.setHeight(this._options.lineHeight))}getWidth(){return this._renderedViewLine?this._renderedViewLine.getWidth():0}getWidthIsFast(){return this._renderedViewLine?this._renderedViewLine.getWidthIsFast():!0}needsMonospaceFontCheck(){return this._renderedViewLine?this._renderedViewLine instanceof Ie:!1}monospaceAssumptionsAreValid(){return this._renderedViewLine&&this._renderedViewLine instanceof Ie?this._renderedViewLine.monospaceAssumptionsAreValid():Ye}onMonospaceAssumptionsInvalidated(){this._renderedViewLine&&this._renderedViewLine instanceof Ie&&(this._renderedViewLine=this._renderedViewLine.toSlowRenderedLine())}getVisibleRangesForRange(e,i,r,_){if(!this._renderedViewLine)return null;i=Math.min(this._renderedViewLine.input.lineContent.length+1,Math.max(1,i)),r=Math.min(this._renderedViewLine.input.lineContent.length+1,Math.max(1,r));const S=this._renderedViewLine.input.stopRenderingLineAfter;let z=!1;S!==-1&&i>S+1&&r>S+1&&(z=!0),S!==-1&&i>S+1&&(i=S+1),S!==-1&&r>S+1&&(r=S+1);const ie=this._renderedViewLine.getVisibleRangesForRange(e,i,r,_);return ie&&ie.length>0?new Pe(z,ie):null}getColumnOfNodeOffset(e,i,r){return this._renderedViewLine?this._renderedViewLine.getColumnOfNodeOffset(e,i,r):1}}Rt.CLASS_NAME="view-line";class Ie{constructor(e,i,r){this.domNode=e,this.input=i,this._characterMapping=r,this._charWidth=i.spaceWidth}getWidth(){return Math.round(this._getCharPosition(this._characterMapping.length))}getWidthIsFast(){return!0}monospaceAssumptionsAreValid(){if(!this.domNode)return Ye;const e=this.getWidth(),i=this.domNode.domNode.firstChild.offsetWidth;return Math.abs(e-i)>=2&&(console.warn("monospace assumptions have been violated, therefore disabling monospace optimizations!"),Ye=!1),Ye}toSlowRenderedLine(){return bt(this.domNode,this.input,this._characterMapping,!1,0)}getVisibleRangesForRange(e,i,r,_){const S=this._getCharPosition(i),z=this._getCharPosition(r);return[new Ae(S,z-S)]}_getCharPosition(e){const i=this._characterMapping.getHorizontalOffset(e);return this._charWidth*i}getColumnOfNodeOffset(e,i,r){const _=i.textContent.length;let S=-1;for(;i;)i=i.previousSibling,S++;return this._characterMapping.getColumn(new ft.wZ(S,r),_)}}class Ve{constructor(e,i,r,_,S){if(this.domNode=e,this.input=i,this._characterMapping=r,this._isWhitespaceOnly=/^\s*$/.test(i.lineContent),this._containsForeignElements=S,this._cachedWidth=-1,this._pixelOffsetCache=null,!_||this._characterMapping.length===0){this._pixelOffsetCache=new Float32Array(Math.max(2,this._characterMapping.length+1));for(let z=0,ie=this._characterMapping.length;z<=ie;z++)this._pixelOffsetCache[z]=-1}}_getReadingTarget(e){return e.domNode.firstChild}getWidth(){return this.domNode?(this._cachedWidth===-1&&(this._cachedWidth=this._getReadingTarget(this.domNode).offsetWidth),this._cachedWidth):0}getWidthIsFast(){return this._cachedWidth!==-1}getVisibleRangesForRange(e,i,r,_){if(!this.domNode)return null;if(this._pixelOffsetCache!==null){const S=this._readPixelOffset(this.domNode,e,i,_);if(S===-1)return null;const z=this._readPixelOffset(this.domNode,e,r,_);return z===-1?null:[new Ae(S,z-S)]}return this._readVisibleRangesForRange(this.domNode,e,i,r,_)}_readVisibleRangesForRange(e,i,r,_,S){if(r===_){const z=this._readPixelOffset(e,i,r,S);return z===-1?null:[new Ae(z,0)]}else return this._readRawVisibleRangesForRange(e,r,_,S)}_readPixelOffset(e,i,r,_){if(this._characterMapping.length===0){if(this._containsForeignElements===0||this._containsForeignElements===2)return 0;if(this._containsForeignElements===1)return this.getWidth();const S=this._getReadingTarget(e);return S.firstChild?S.firstChild.offsetWidth:0}if(this._pixelOffsetCache!==null){const S=this._pixelOffsetCache[r];if(S!==-1)return S;const z=this._actualReadPixelOffset(e,i,r,_);return this._pixelOffsetCache[r]=z,z}return this._actualReadPixelOffset(e,i,r,_)}_actualReadPixelOffset(e,i,r,_){if(this._characterMapping.length===0){const re=$e.readHorizontalRanges(this._getReadingTarget(e),0,0,0,0,_.clientRectDeltaLeft,_.clientRectScale,_.endNode);return!re||re.length===0?-1:re[0].left}if(r===this._characterMapping.length&&this._isWhitespaceOnly&&this._containsForeignElements===0)return this.getWidth();const S=this._characterMapping.getDomPosition(r),z=$e.readHorizontalRanges(this._getReadingTarget(e),S.partIndex,S.charIndex,S.partIndex,S.charIndex,_.clientRectDeltaLeft,_.clientRectScale,_.endNode);if(!z||z.length===0)return-1;const ie=z[0].left;if(this.input.isBasicASCII){const re=this._characterMapping.getHorizontalOffset(r),le=Math.round(this.input.spaceWidth*re);if(Math.abs(le-ie)<=1)return le}return ie}_readRawVisibleRangesForRange(e,i,r,_){if(i===1&&r===this._characterMapping.length)return[new Ae(0,this.getWidth())];const S=this._characterMapping.getDomPosition(i),z=this._characterMapping.getDomPosition(r);return $e.readHorizontalRanges(this._getReadingTarget(e),S.partIndex,S.charIndex,z.partIndex,z.charIndex,_.clientRectDeltaLeft,_.clientRectScale,_.endNode)}getColumnOfNodeOffset(e,i,r){const _=i.textContent.length;let S=-1;for(;i;)i=i.previousSibling,S++;return this._characterMapping.getColumn(new ft.wZ(S,r),_)}}class dt extends Ve{_readVisibleRangesForRange(e,i,r,_,S){const z=super._readVisibleRangesForRange(e,i,r,_,S);if(!z||z.length===0||r===_||r===1&&_===this._characterMapping.length)return z;if(!this.input.containsRTL){const ie=this._readPixelOffset(e,i,_,S);if(ie!==-1){const re=z[z.length-1];re.left<ie&&(re.width=ie-re.left)}}return z}}const bt=function(){return g.isWebKit?Mt:Yt}();function Mt(Le,e,i,r,_){return new dt(Le,e,i,r,_)}function Yt(Le,e,i,r,_){return new Ve(Le,e,i,r,_)}var Nt=y(15365),Pt=y(50442),Ti=y(62549),Ii=y(71937);class ut{constructor(e=null){this.hitTarget=e,this.type=0}}class Si{constructor(e,i,r){this.position=e,this.spanNode=i,this.injectedText=r,this.type=1}}var yt;(function(Le){function e(i,r,_){const S=i.getPositionFromDOMInfo(r,_);return S?new Si(S,r,null):new ut(r)}Le.createFromDOMInfo=e})(yt||(yt={}));class fe{constructor(e,i){this.lastViewCursorsRenderData=e,this.lastTextareaPosition=i}}class ze{static _deduceRage(e,i=null){return!i&&e?new Pt.Q(e.lineNumber,e.column,e.lineNumber,e.column):i??null}static createUnknown(e,i,r){return{type:0,element:e,mouseColumn:i,position:r,range:this._deduceRage(r)}}static createTextarea(e,i){return{type:1,element:e,mouseColumn:i,position:null,range:null}}static createMargin(e,i,r,_,S,z){return{type:e,element:i,mouseColumn:r,position:_,range:S,detail:z}}static createViewZone(e,i,r,_,S){return{type:e,element:i,mouseColumn:r,position:_,range:this._deduceRage(_),detail:S}}static createContentText(e,i,r,_,S){return{type:6,element:e,mouseColumn:i,position:r,range:this._deduceRage(r,_),detail:S}}static createContentEmpty(e,i,r,_){return{type:7,element:e,mouseColumn:i,position:r,range:this._deduceRage(r),detail:_}}static createContentWidget(e,i,r){return{type:9,element:e,mouseColumn:i,position:null,range:null,detail:r}}static createScrollbar(e,i,r){return{type:11,element:e,mouseColumn:i,position:r,range:this._deduceRage(r)}}static createOverlayWidget(e,i,r){return{type:12,element:e,mouseColumn:i,position:null,range:null,detail:r}}static createOutsideEditor(e,i){return{type:13,element:null,mouseColumn:e,position:i,range:this._deduceRage(i)}}static _typeToString(e){return e===1?"TEXTAREA":e===2?"GUTTER_GLYPH_MARGIN":e===3?"GUTTER_LINE_NUMBERS":e===4?"GUTTER_LINE_DECORATIONS":e===5?"GUTTER_VIEW_ZONE":e===6?"CONTENT_TEXT":e===7?"CONTENT_EMPTY":e===8?"CONTENT_VIEW_ZONE":e===9?"CONTENT_WIDGET":e===10?"OVERVIEW_RULER":e===11?"SCROLLBAR":e===12?"OVERLAY_WIDGET":"UNKNOWN"}static toString(e){return this._typeToString(e.type)+": "+e.position+" - "+e.range+" - "+JSON.stringify(e.detail)}}class Et{static isTextArea(e){return e.length===2&&e[0]===3&&e[1]===6}static isChildOfViewLines(e){return e.length>=4&&e[0]===3&&e[3]===7}static isStrictChildOfViewLines(e){return e.length>4&&e[0]===3&&e[3]===7}static isChildOfScrollableElement(e){return e.length>=2&&e[0]===3&&e[1]===5}static isChildOfMinimap(e){return e.length>=2&&e[0]===3&&e[1]===8}static isChildOfContentWidgets(e){return e.length>=4&&e[0]===3&&e[3]===1}static isChildOfOverflowingContentWidgets(e){return e.length>=1&&e[0]===2}static isChildOfOverlayWidgets(e){return e.length>=2&&e[0]===3&&e[1]===4}}class Ot{constructor(e,i,r){this.viewModel=e.viewModel;const _=e.configuration.options;this.layoutInfo=_.get(133),this.viewDomNode=i.viewDomNode,this.lineHeight=_.get(61),this.stickyTabStops=_.get(106),this.typicalHalfwidthCharacterWidth=_.get(46).typicalHalfwidthCharacterWidth,this.lastRenderData=r,this._context=e,this._viewHelper=i}getZoneAtCoord(e){return Ot.getZoneAtCoord(this._context,e)}static getZoneAtCoord(e,i){const r=e.viewLayout.getWhitespaceAtVerticalOffset(i);if(r){const _=r.verticalOffset+r.height/2,S=e.viewModel.getLineCount();let z=null,ie,re=null;return r.afterLineNumber!==S&&(re=new Nt.y(r.afterLineNumber+1,1)),r.afterLineNumber>0&&(z=new Nt.y(r.afterLineNumber,e.viewModel.getLineMaxColumn(r.afterLineNumber))),re===null?ie=z:z===null?ie=re:i<_?ie=z:ie=re,{viewZoneId:r.id,afterLineNumber:r.afterLineNumber,positionBefore:z,positionAfter:re,position:ie}}return null}getFullLineRangeAtCoord(e){if(this._context.viewLayout.isAfterLines(e)){const _=this._context.viewModel.getLineCount(),S=this._context.viewModel.getLineMaxColumn(_);return{range:new Pt.Q(_,S,_,S),isAfterLines:!0}}const i=this._context.viewLayout.getLineNumberAtVerticalOffset(e),r=this._context.viewModel.getLineMaxColumn(i);return{range:new Pt.Q(i,1,i,r),isAfterLines:!1}}getLineNumberAtVerticalOffset(e){return this._context.viewLayout.getLineNumberAtVerticalOffset(e)}isAfterLines(e){return this._context.viewLayout.isAfterLines(e)}isInTopPadding(e){return this._context.viewLayout.isInTopPadding(e)}isInBottomPadding(e){return this._context.viewLayout.isInBottomPadding(e)}getVerticalOffsetForLineNumber(e){return this._context.viewLayout.getVerticalOffsetForLineNumber(e)}findAttribute(e,i){return Ot._findAttribute(e,i,this._viewHelper.viewDomNode)}static _findAttribute(e,i,r){for(;e&&e!==document.body;){if(e.hasAttribute&&e.hasAttribute(i))return e.getAttribute(i);if(e===r)return null;e=e.parentNode}return null}getLineWidth(e){return this._viewHelper.getLineWidth(e)}visibleRangeForPosition(e,i){return this._viewHelper.visibleRangeForPosition(e,i)}getPositionFromDOMInfo(e,i){return this._viewHelper.getPositionFromDOMInfo(e,i)}getCurrentScrollTop(){return this._context.viewLayout.getCurrentScrollTop()}getCurrentScrollLeft(){return this._context.viewLayout.getCurrentScrollLeft()}}class si{constructor(e,i,r,_){this.editorPos=i,this.pos=r,this.relativePos=_,this.mouseVerticalOffset=Math.max(0,e.getCurrentScrollTop()+this.relativePos.y),this.mouseContentHorizontalOffset=e.getCurrentScrollLeft()+this.relativePos.x-e.layoutInfo.contentLeft,this.isInMarginArea=this.relativePos.x<e.layoutInfo.contentLeft&&this.relativePos.x>=e.layoutInfo.glyphMarginLeft,this.isInContentArea=!this.isInMarginArea,this.mouseColumn=Math.max(0,gt._getMouseColumn(this.mouseContentHorizontalOffset,e.typicalHalfwidthCharacterWidth))}}class _i extends si{constructor(e,i,r,_,S){super(e,i,r,_),this._ctx=e,S?(this.target=S,this.targetPath=be.collect(S,e.viewDomNode)):(this.target=null,this.targetPath=new Uint8Array(0))}toString(){return`pos(${this.pos.x},${this.pos.y}), editorPos(${this.editorPos.x},${this.editorPos.y}), relativePos(${this.relativePos.x},${this.relativePos.y}), mouseVerticalOffset: ${this.mouseVerticalOffset}, mouseContentHorizontalOffset: ${this.mouseContentHorizontalOffset} target: ${this.target?this.target.outerHTML:null}`}_getMouseColumn(e=null){return e&&e.column<this._ctx.viewModel.getLineMaxColumn(e.lineNumber)?Ti.A.visibleColumnFromColumn(this._ctx.viewModel.getLineContent(e.lineNumber),e.column,this._ctx.viewModel.model.getOptions().tabSize)+1:this.mouseColumn}fulfillUnknown(e=null){return ze.createUnknown(this.target,this._getMouseColumn(e),e)}fulfillTextarea(){return ze.createTextarea(this.target,this._getMouseColumn())}fulfillMargin(e,i,r,_){return ze.createMargin(e,this.target,this._getMouseColumn(i),i,r,_)}fulfillViewZone(e,i,r){return ze.createViewZone(e,this.target,this._getMouseColumn(i),i,r)}fulfillContentText(e,i,r){return ze.createContentText(this.target,this._getMouseColumn(e),e,i,r)}fulfillContentEmpty(e,i){return ze.createContentEmpty(this.target,this._getMouseColumn(e),e,i)}fulfillContentWidget(e){return ze.createContentWidget(this.target,this._getMouseColumn(),e)}fulfillScrollbar(e){return ze.createScrollbar(this.target,this._getMouseColumn(e),e)}fulfillOverlayWidget(e){return ze.createOverlayWidget(this.target,this._getMouseColumn(),e)}withTarget(e){return new _i(this._ctx,this.editorPos,this.pos,this.relativePos,e)}}const Fe={isAfterLines:!0};function Xe(Le){return{isAfterLines:!1,horizontalDistanceToText:Le}}class gt{constructor(e,i){this._context=e,this._viewHelper=i}mouseTargetIsWidget(e){const i=e.target,r=be.collect(i,this._viewHelper.viewDomNode);return!!(Et.isChildOfContentWidgets(r)||Et.isChildOfOverflowingContentWidgets(r)||Et.isChildOfOverlayWidgets(r))}createMouseTarget(e,i,r,_,S){const z=new Ot(this._context,this._viewHelper,e),ie=new _i(z,i,r,_,S);try{return gt._createMouseTarget(z,ie,!1)}catch{return ie.fulfillUnknown()}}static _createMouseTarget(e,i,r){if(i.target===null){if(r)return i.fulfillUnknown();const z=gt._doHitTest(e,i);return z.type===1?gt.createMouseTargetFromHitTestPosition(e,i,z.spanNode,z.position,z.injectedText):this._createMouseTarget(e,i.withTarget(z.hitTarget),!0)}const _=i;let S=null;return S=S||gt._hitTestContentWidget(e,_),S=S||gt._hitTestOverlayWidget(e,_),S=S||gt._hitTestMinimap(e,_),S=S||gt._hitTestScrollbarSlider(e,_),S=S||gt._hitTestViewZone(e,_),S=S||gt._hitTestMargin(e,_),S=S||gt._hitTestViewCursor(e,_),S=S||gt._hitTestTextArea(e,_),S=S||gt._hitTestViewLines(e,_,r),S=S||gt._hitTestScrollbar(e,_),S||i.fulfillUnknown()}static _hitTestContentWidget(e,i){if(Et.isChildOfContentWidgets(i.targetPath)||Et.isChildOfOverflowingContentWidgets(i.targetPath)){const r=e.findAttribute(i.target,"widgetId");return r?i.fulfillContentWidget(r):i.fulfillUnknown()}return null}static _hitTestOverlayWidget(e,i){if(Et.isChildOfOverlayWidgets(i.targetPath)){const r=e.findAttribute(i.target,"widgetId");return r?i.fulfillOverlayWidget(r):i.fulfillUnknown()}return null}static _hitTestViewCursor(e,i){if(i.target){const r=e.lastRenderData.lastViewCursorsRenderData;for(const _ of r)if(i.target===_.domNode)return i.fulfillContentText(_.position,null,{mightBeForeignElement:!1,injectedText:null})}if(i.isInContentArea){const r=e.lastRenderData.lastViewCursorsRenderData,_=i.mouseContentHorizontalOffset,S=i.mouseVerticalOffset;for(const z of r){if(_<z.contentLeft||_>z.contentLeft+z.width)continue;const ie=e.getVerticalOffsetForLineNumber(z.position.lineNumber);if(ie<=S&&S<=ie+z.height)return i.fulfillContentText(z.position,null,{mightBeForeignElement:!1,injectedText:null})}}return null}static _hitTestViewZone(e,i){const r=e.getZoneAtCoord(i.mouseVerticalOffset);if(r){const _=i.isInContentArea?8:5;return i.fulfillViewZone(_,r.position,r)}return null}static _hitTestTextArea(e,i){return Et.isTextArea(i.targetPath)?e.lastRenderData.lastTextareaPosition?i.fulfillContentText(e.lastRenderData.lastTextareaPosition,null,{mightBeForeignElement:!1,injectedText:null}):i.fulfillTextarea():null}static _hitTestMargin(e,i){if(i.isInMarginArea){const r=e.getFullLineRangeAtCoord(i.mouseVerticalOffset),_=r.range.getStartPosition();let S=Math.abs(i.relativePos.x);const z={isAfterLines:r.isAfterLines,glyphMarginLeft:e.layoutInfo.glyphMarginLeft,glyphMarginWidth:e.layoutInfo.glyphMarginWidth,lineNumbersWidth:e.layoutInfo.lineNumbersWidth,offsetX:S};return S-=e.layoutInfo.glyphMarginLeft,S<=e.layoutInfo.glyphMarginWidth?i.fulfillMargin(2,_,r.range,z):(S-=e.layoutInfo.glyphMarginWidth,S<=e.layoutInfo.lineNumbersWidth?i.fulfillMargin(3,_,r.range,z):(S-=e.layoutInfo.lineNumbersWidth,i.fulfillMargin(4,_,r.range,z)))}return null}static _hitTestViewLines(e,i,r){if(!Et.isChildOfViewLines(i.targetPath))return null;if(e.isInTopPadding(i.mouseVerticalOffset))return i.fulfillContentEmpty(new Nt.y(1,1),Fe);if(e.isAfterLines(i.mouseVerticalOffset)||e.isInBottomPadding(i.mouseVerticalOffset)){const S=e.viewModel.getLineCount(),z=e.viewModel.getLineMaxColumn(S);return i.fulfillContentEmpty(new Nt.y(S,z),Fe)}if(r){if(Et.isStrictChildOfViewLines(i.targetPath)){const S=e.getLineNumberAtVerticalOffset(i.mouseVerticalOffset);if(e.viewModel.getLineLength(S)===0){const ie=e.getLineWidth(S),re=Xe(i.mouseContentHorizontalOffset-ie);return i.fulfillContentEmpty(new Nt.y(S,1),re)}const z=e.getLineWidth(S);if(i.mouseContentHorizontalOffset>=z){const ie=Xe(i.mouseContentHorizontalOffset-z),re=new Nt.y(S,e.viewModel.getLineMaxColumn(S));return i.fulfillContentEmpty(re,ie)}}return i.fulfillUnknown()}const _=gt._doHitTest(e,i);return _.type===1?gt.createMouseTargetFromHitTestPosition(e,i,_.spanNode,_.position,_.injectedText):this._createMouseTarget(e,i.withTarget(_.hitTarget),!0)}static _hitTestMinimap(e,i){if(Et.isChildOfMinimap(i.targetPath)){const r=e.getLineNumberAtVerticalOffset(i.mouseVerticalOffset),_=e.viewModel.getLineMaxColumn(r);return i.fulfillScrollbar(new Nt.y(r,_))}return null}static _hitTestScrollbarSlider(e,i){if(Et.isChildOfScrollableElement(i.targetPath)&&i.target&&i.target.nodeType===1){const r=i.target.className;if(r&&/\b(slider|scrollbar)\b/.test(r)){const _=e.getLineNumberAtVerticalOffset(i.mouseVerticalOffset),S=e.viewModel.getLineMaxColumn(_);return i.fulfillScrollbar(new Nt.y(_,S))}}return null}static _hitTestScrollbar(e,i){if(Et.isChildOfScrollableElement(i.targetPath)){const r=e.getLineNumberAtVerticalOffset(i.mouseVerticalOffset),_=e.viewModel.getLineMaxColumn(r);return i.fulfillScrollbar(new Nt.y(r,_))}return null}getMouseColumn(e){const i=this._context.configuration.options,r=i.get(133),_=this._context.viewLayout.getCurrentScrollLeft()+e.x-r.contentLeft;return gt._getMouseColumn(_,i.get(46).typicalHalfwidthCharacterWidth)}static _getMouseColumn(e,i){return e<0?1:Math.round(e/i)+1}static createMouseTargetFromHitTestPosition(e,i,r,_,S){const z=_.lineNumber,ie=_.column,re=e.getLineWidth(z);if(i.mouseContentHorizontalOffset>re){const ct=Xe(i.mouseContentHorizontalOffset-re);return i.fulfillContentEmpty(_,ct)}const le=e.visibleRangeForPosition(z,ie);if(!le)return i.fulfillUnknown(_);const me=le.left;if(i.mouseContentHorizontalOffset===me)return i.fulfillContentText(_,null,{mightBeForeignElement:!!S,injectedText:S});const we=[];if(we.push({offset:le.left,column:ie}),ie>1){const ct=e.visibleRangeForPosition(z,ie-1);ct&&we.push({offset:ct.left,column:ie-1})}const Be=e.viewModel.getLineMaxColumn(z);if(ie<Be){const ct=e.visibleRangeForPosition(z,ie+1);ct&&we.push({offset:ct.left,column:ie+1})}we.sort((ct,mt)=>ct.offset-mt.offset);const Re=i.pos.toClientCoordinates(),Je=r.getBoundingClientRect(),st=Je.left<=Re.clientX&&Re.clientX<=Je.right;for(let ct=1;ct<we.length;ct++){const mt=we[ct-1],xt=we[ct];if(mt.offset<=i.mouseContentHorizontalOffset&&i.mouseContentHorizontalOffset<=xt.offset){const Dt=new Pt.Q(z,mt.column,z,xt.column),Jt=Math.abs(mt.offset-i.mouseContentHorizontalOffset),$t=Math.abs(xt.offset-i.mouseContentHorizontalOffset),ai=Jt<$t?new Nt.y(z,mt.column):new Nt.y(z,xt.column);return i.fulfillContentText(ai,Dt,{mightBeForeignElement:!st||!!S,injectedText:S})}}return i.fulfillContentText(_,null,{mightBeForeignElement:!st||!!S,injectedText:S})}static _doHitTestWithCaretRangeFromPoint(e,i){const r=e.getLineNumberAtVerticalOffset(i.mouseVerticalOffset),S=e.getVerticalOffsetForLineNumber(r)+Math.floor(e.lineHeight/2);let z=i.pos.y+(S-i.mouseVerticalOffset);z<=i.editorPos.y&&(z=i.editorPos.y+1),z>=i.editorPos.y+i.editorPos.height&&(z=i.editorPos.y+i.editorPos.height-1);const ie=new Me.nz(i.pos.x,z),re=this._actualDoHitTestWithCaretRangeFromPoint(e,ie.toClientCoordinates());return re.type===1?re:this._actualDoHitTestWithCaretRangeFromPoint(e,i.pos.toClientCoordinates())}static _actualDoHitTestWithCaretRangeFromPoint(e,i){const r=P.jG(e.viewDomNode);let _;if(r?typeof r.caretRangeFromPoint>"u"?_=Xt(r,i.clientX,i.clientY):_=r.caretRangeFromPoint(i.clientX,i.clientY):_=document.caretRangeFromPoint(i.clientX,i.clientY),!_||!_.startContainer)return new ut;const S=_.startContainer;if(S.nodeType===S.TEXT_NODE){const z=S.parentNode,ie=z?z.parentNode:null,re=ie?ie.parentNode:null;return(re&&re.nodeType===re.ELEMENT_NODE?re.className:null)===Rt.CLASS_NAME?yt.createFromDOMInfo(e,z,_.startOffset):new ut(S.parentNode)}else if(S.nodeType===S.ELEMENT_NODE){const z=S.parentNode,ie=z?z.parentNode:null;return(ie&&ie.nodeType===ie.ELEMENT_NODE?ie.className:null)===Rt.CLASS_NAME?yt.createFromDOMInfo(e,S,S.textContent.length):new ut(S)}return new ut}static _doHitTestWithCaretPositionFromPoint(e,i){const r=document.caretPositionFromPoint(i.clientX,i.clientY);if(r.offsetNode.nodeType===r.offsetNode.TEXT_NODE){const _=r.offsetNode.parentNode,S=_?_.parentNode:null,z=S?S.parentNode:null;return(z&&z.nodeType===z.ELEMENT_NODE?z.className:null)===Rt.CLASS_NAME?yt.createFromDOMInfo(e,r.offsetNode.parentNode,r.offset):new ut(r.offsetNode.parentNode)}if(r.offsetNode.nodeType===r.offsetNode.ELEMENT_NODE){const _=r.offsetNode.parentNode,S=_&&_.nodeType===_.ELEMENT_NODE?_.className:null,z=_?_.parentNode:null,ie=z&&z.nodeType===z.ELEMENT_NODE?z.className:null;if(S===Rt.CLASS_NAME){const re=r.offsetNode.childNodes[Math.min(r.offset,r.offsetNode.childNodes.length-1)];if(re)return yt.createFromDOMInfo(e,re,0)}else if(ie===Rt.CLASS_NAME)return yt.createFromDOMInfo(e,r.offsetNode,0)}return new ut(r.offsetNode)}static _snapToSoftTabBoundary(e,i){const r=i.getLineContent(e.lineNumber),{tabSize:_}=i.model.getOptions(),S=Ii.s.atomicPosition(r,e.column-1,_,2);return S!==-1?new Nt.y(e.lineNumber,S+1):e}static _doHitTest(e,i){let r=new ut;if(typeof document.caretRangeFromPoint=="function"?r=this._doHitTestWithCaretRangeFromPoint(e,i):document.caretPositionFromPoint&&(r=this._doHitTestWithCaretPositionFromPoint(e,i.pos.toClientCoordinates())),r.type===1){const _=e.viewModel.getInjectedTextAt(r.position),S=e.viewModel.normalizePosition(r.position,2);(_||!S.equals(r.position))&&(r=new Si(S,r.spanNode,_))}return r.type===1&&e.stickyTabStops&&(r=new Si(this._snapToSoftTabBoundary(r.position,e.viewModel),r.spanNode,r.injectedText)),r}}function Xt(Le,e,i){const r=document.createRange();let _=Le.elementFromPoint(e,i);if(_!==null){for(;_&&_.firstChild&&_.firstChild.nodeType!==_.firstChild.TEXT_NODE&&_.lastChild&&_.lastChild.firstChild;)_=_.lastChild;const S=_.getBoundingClientRect(),z=window.getComputedStyle(_,null).getPropertyValue("font"),ie=_.innerText;let re=S.left,le=0,me;if(e>S.left+S.width)le=ie.length;else{const we=Vt.getInstance();for(let Be=0;Be<ie.length+1;Be++){if(me=we.getCharWidth(ie.charAt(Be),z)/2,re+=me,e<re){le=Be;break}re+=me}}r.setStart(_.firstChild,le),r.setEnd(_.firstChild,le)}return r}class Vt{constructor(){this._cache={},this._canvas=document.createElement("canvas")}static getInstance(){return Vt._INSTANCE||(Vt._INSTANCE=new Vt),Vt._INSTANCE}getCharWidth(e,i){const r=e+i;if(this._cache[r])return this._cache[r];const _=this._canvas.getContext("2d");_.font=i;const z=_.measureText(e).width;return this._cache[r]=z,z}}Vt._INSTANCE=null;class ni extends ce{constructor(e,i,r){super(),this._mouseLeaveMonitor=null,this._context=e,this.viewController=i,this.viewHelper=r,this.mouseTargetFactory=new gt(this._context,r),this._mouseDownOperation=this._register(new vi(this._context,this.viewController,this.viewHelper,(ie,re)=>this._createMouseTarget(ie,re),ie=>this._getMouseColumn(ie))),this.lastMouseLeaveTime=-1,this._height=this._context.configuration.options.get(133).height;const _=new Me.$z(this.viewHelper.viewDomNode);this._register(_.onContextMenu(this.viewHelper.viewDomNode,ie=>this._onContextMenu(ie,!0))),this._register(_.onMouseMove(this.viewHelper.viewDomNode,ie=>{this._onMouseMove(ie),this._mouseLeaveMonitor||(this._mouseLeaveMonitor=P.ko(document,"mousemove",re=>{this.viewHelper.viewDomNode.contains(re.target)||this._onMouseLeave(new Me.dO(re,!1,this.viewHelper.viewDomNode))}))})),this._register(_.onMouseUp(this.viewHelper.viewDomNode,ie=>this._onMouseUp(ie))),this._register(_.onMouseLeave(this.viewHelper.viewDomNode,ie=>this._onMouseLeave(ie)));let S=0;this._register(_.onPointerDown(this.viewHelper.viewDomNode,(ie,re)=>{S=re})),this._register(P.ko(this.viewHelper.viewDomNode,P.Bx.POINTER_UP,ie=>{this._mouseDownOperation.onPointerUp()})),this._register(_.onMouseDown(this.viewHelper.viewDomNode,ie=>this._onMouseDown(ie,S)));const z=ie=>{if(this.viewController.emitMouseWheel(ie),!this._context.configuration.options.get(70))return;const re=new Ke.$(ie);if(u.zx?(ie.metaKey||ie.ctrlKey)&&!ie.shiftKey&&!ie.altKey:ie.ctrlKey&&!ie.metaKey&&!ie.shiftKey&&!ie.altKey){const me=Y.D.getZoomLevel(),we=re.deltaY>0?1:-1;Y.D.setZoomLevel(me+we),re.preventDefault(),re.stopPropagation()}};this._register(P.ko(this.viewHelper.viewDomNode,P.Bx.MOUSE_WHEEL,z,{capture:!0,passive:!1})),this._context.addEventHandler(this)}dispose(){this._context.removeEventHandler(this),this._mouseLeaveMonitor&&(this._mouseLeaveMonitor.dispose(),this._mouseLeaveMonitor=null),super.dispose()}onConfigurationChanged(e){if(e.hasChanged(133)){const i=this._context.configuration.options.get(133).height;this._height!==i&&(this._height=i,this._mouseDownOperation.onHeightChanged())}return!1}onCursorStateChanged(e){return this._mouseDownOperation.onCursorStateChanged(e),!1}onFocusChanged(e){return!1}onScrollChanged(e){return this._mouseDownOperation.onScrollChanged(),!1}getTargetAtClientPoint(e,i){const _=new Me.Hh(e,i).toPageCoordinates(),S=(0,Me.wt)(this.viewHelper.viewDomNode);if(_.y<S.y||_.y>S.y+S.height||_.x<S.x||_.x>S.x+S.width)return null;const z=(0,Me.i_)(this.viewHelper.viewDomNode,S,_);return this.mouseTargetFactory.createMouseTarget(this.viewHelper.getLastRenderData(),S,_,z,null)}_createMouseTarget(e,i){let r=e.target;if(!this.viewHelper.viewDomNode.contains(r)){const _=P.jG(this.viewHelper.viewDomNode);_&&(r=_.elementsFromPoint(e.posx,e.posy).find(S=>this.viewHelper.viewDomNode.contains(S)))}return this.mouseTargetFactory.createMouseTarget(this.viewHelper.getLastRenderData(),e.editorPos,e.pos,e.relativePos,i?r:null)}_getMouseColumn(e){return this.mouseTargetFactory.getMouseColumn(e.relativePos)}_onContextMenu(e,i){this.viewController.emitContextMenu({event:e,target:this._createMouseTarget(e,i)})}_onMouseMove(e){this.mouseTargetFactory.mouseTargetIsWidget(e)||e.preventDefault(),!(this._mouseDownOperation.isActive()||e.timestamp<this.lastMouseLeaveTime)&&this.viewController.emitMouseMove({event:e,target:this._createMouseTarget(e,!0)})}_onMouseLeave(e){this._mouseLeaveMonitor&&(this._mouseLeaveMonitor.dispose(),this._mouseLeaveMonitor=null),this.lastMouseLeaveTime=new Date().getTime(),this.viewController.emitMouseLeave({event:e,target:null})}_onMouseUp(e){this.viewController.emitMouseUp({event:e,target:this._createMouseTarget(e,!0)})}_onMouseDown(e,i){const r=this._createMouseTarget(e,!0),_=r.type===6||r.type===7,S=r.type===2||r.type===3||r.type===4,z=r.type===3,ie=this._context.configuration.options.get(100),re=r.type===8||r.type===5,le=r.type===9;let me=e.leftButton||e.middleButton;u.zx&&e.leftButton&&e.ctrlKey&&(me=!1);const we=()=>{e.preventDefault(),this.viewHelper.focusTextArea()};if(me&&(_||z&&ie))we(),this._mouseDownOperation.start(r.type,e,i);else if(S)e.preventDefault();else if(re){const Be=r.detail;me&&this.viewHelper.shouldSuppressMouseDownOnViewZone(Be.viewZoneId)&&(we(),this._mouseDownOperation.start(r.type,e,i),e.preventDefault())}else le&&this.viewHelper.shouldSuppressMouseDownOnWidget(r.detail)&&(we(),e.preventDefault());this.viewController.emitMouseDown({event:e,target:r})}}class vi extends p.jG{constructor(e,i,r,_,S){super(),this._context=e,this._viewController=i,this._viewHelper=r,this._createMouseTarget=_,this._getMouseColumn=S,this._mouseMoveMonitor=this._register(new Me.BA(this._viewHelper.viewDomNode)),this._onScrollTimeout=this._register(new Se.pc),this._mouseState=new Ri,this._currentSelection=new ue.L(1,1,1,1),this._isActive=!1,this._lastMouseEvent=null}dispose(){super.dispose()}isActive(){return this._isActive}_onMouseDownThenMove(e){this._lastMouseEvent=e,this._mouseState.setModifiers(e);const i=this._findMousePosition(e,!1);i&&(this._mouseState.isDragAndDrop?this._viewController.emitMouseDrag({event:e,target:i}):this._dispatchMouse(i,!0))}start(e,i,r){this._lastMouseEvent=i,this._mouseState.setStartedOnLineNumbers(e===3),this._mouseState.setStartButtons(i),this._mouseState.setModifiers(i);const _=this._findMousePosition(i,!0);if(!_||!_.position)return;this._mouseState.trySetCount(i.detail,_.position),i.detail=this._mouseState.count;const S=this._context.configuration.options;if(!S.get(83)&&S.get(31)&&!S.get(18)&&!this._mouseState.altKey&&i.detail<2&&!this._isActive&&!this._currentSelection.isEmpty()&&_.type===6&&_.position&&this._currentSelection.containsPosition(_.position)){this._mouseState.isDragAndDrop=!0,this._isActive=!0,this._mouseMoveMonitor.startMonitoring(this._viewHelper.viewLinesDomNode,r,i.buttons,z=>this._onMouseDownThenMove(z),z=>{const ie=this._findMousePosition(this._lastMouseEvent,!1);z&&z instanceof KeyboardEvent?this._viewController.emitMouseDropCanceled():this._viewController.emitMouseDrop({event:this._lastMouseEvent,target:ie?this._createMouseTarget(this._lastMouseEvent,!0):null}),this._stop()});return}this._mouseState.isDragAndDrop=!1,this._dispatchMouse(_,i.shiftKey),this._isActive||(this._isActive=!0,this._mouseMoveMonitor.startMonitoring(this._viewHelper.viewLinesDomNode,r,i.buttons,z=>this._onMouseDownThenMove(z),()=>this._stop()))}_stop(){this._isActive=!1,this._onScrollTimeout.cancel()}onHeightChanged(){this._mouseMoveMonitor.stopMonitoring()}onPointerUp(){this._mouseMoveMonitor.stopMonitoring()}onScrollChanged(){this._isActive&&this._onScrollTimeout.setIfNotSet(()=>{if(!this._lastMouseEvent)return;const e=this._findMousePosition(this._lastMouseEvent,!1);e&&(this._mouseState.isDragAndDrop||this._dispatchMouse(e,!0))},10)}onCursorStateChanged(e){this._currentSelection=e.selections[0]}_getPositionOutsideEditor(e){const i=e.editorPos,r=this._context.viewModel,_=this._context.viewLayout,S=this._getMouseColumn(e);if(e.posy<i.y){const ie=Math.max(_.getCurrentScrollTop()-(i.y-e.posy),0),re=Ot.getZoneAtCoord(this._context,ie);if(re){const me=this._helpPositionJumpOverViewZone(re);if(me)return ze.createOutsideEditor(S,me)}const le=_.getLineNumberAtVerticalOffset(ie);return ze.createOutsideEditor(S,new Nt.y(le,1))}if(e.posy>i.y+i.height){const ie=_.getCurrentScrollTop()+e.relativePos.y,re=Ot.getZoneAtCoord(this._context,ie);if(re){const me=this._helpPositionJumpOverViewZone(re);if(me)return ze.createOutsideEditor(S,me)}const le=_.getLineNumberAtVerticalOffset(ie);return ze.createOutsideEditor(S,new Nt.y(le,r.getLineMaxColumn(le)))}const z=_.getLineNumberAtVerticalOffset(_.getCurrentScrollTop()+e.relativePos.y);return e.posx<i.x?ze.createOutsideEditor(S,new Nt.y(z,1)):e.posx>i.x+i.width?ze.createOutsideEditor(S,new Nt.y(z,r.getLineMaxColumn(z))):null}_findMousePosition(e,i){const r=this._getPositionOutsideEditor(e);if(r)return r;const _=this._createMouseTarget(e,i);if(!_.position)return null;if(_.type===8||_.type===5){const z=this._helpPositionJumpOverViewZone(_.detail);if(z)return ze.createViewZone(_.type,_.element,_.mouseColumn,z,_.detail)}return _}_helpPositionJumpOverViewZone(e){const i=new Nt.y(this._currentSelection.selectionStartLineNumber,this._currentSelection.selectionStartColumn),r=e.positionBefore,_=e.positionAfter;return r&&_?r.isBefore(i)?r:_:null}_dispatchMouse(e,i){e.position&&this._viewController.dispatchMouse({position:e.position,mouseColumn:e.mouseColumn,startedOnLineNumbers:this._mouseState.startedOnLineNumbers,inSelectionMode:i,mouseDownCount:this._mouseState.count,altKey:this._mouseState.altKey,ctrlKey:this._mouseState.ctrlKey,metaKey:this._mouseState.metaKey,shiftKey:this._mouseState.shiftKey,leftButton:this._mouseState.leftButton,middleButton:this._mouseState.middleButton,onInjectedText:e.type===6&&e.detail.injectedText!==null})}}class Ri{constructor(){this._altKey=!1,this._ctrlKey=!1,this._metaKey=!1,this._shiftKey=!1,this._leftButton=!1,this._middleButton=!1,this._startedOnLineNumbers=!1,this._lastMouseDownPosition=null,this._lastMouseDownPositionEqualCount=0,this._lastMouseDownCount=0,this._lastSetMouseDownCountTime=0,this.isDragAndDrop=!1}get altKey(){return this._altKey}get ctrlKey(){return this._ctrlKey}get metaKey(){return this._metaKey}get shiftKey(){return this._shiftKey}get leftButton(){return this._leftButton}get middleButton(){return this._middleButton}get startedOnLineNumbers(){return this._startedOnLineNumbers}get count(){return this._lastMouseDownCount}setModifiers(e){this._altKey=e.altKey,this._ctrlKey=e.ctrlKey,this._metaKey=e.metaKey,this._shiftKey=e.shiftKey}setStartButtons(e){this._leftButton=e.leftButton,this._middleButton=e.middleButton}setStartedOnLineNumbers(e){this._startedOnLineNumbers=e}trySetCount(e,i){const r=new Date().getTime();r-this._lastSetMouseDownCountTime>Ri.CLEAR_MOUSE_DOWN_COUNT_TIME&&(e=1),this._lastSetMouseDownCountTime=r,e>this._lastMouseDownCount+1&&(e=this._lastMouseDownCount+1),this._lastMouseDownPosition&&this._lastMouseDownPosition.equals(i)?this._lastMouseDownPositionEqualCount++:this._lastMouseDownPositionEqualCount=1,this._lastMouseDownPosition=i,this._lastMouseDownCount=Math.min(e,this._lastMouseDownPositionEqualCount)}}Ri.CLEAR_MOUSE_DOWN_COUNT_TIME=400;var St=y(51577),ve=y(93344);class Te extends ni{constructor(e,i,r){super(e,i,r),this._register(Qe.q.addTarget(this.viewHelper.linesContentDomNode)),this._register(P.ko(this.viewHelper.linesContentDomNode,Qe.B.Tap,S=>this.onTap(S))),this._register(P.ko(this.viewHelper.linesContentDomNode,Qe.B.Change,S=>this.onChange(S))),this._register(P.ko(this.viewHelper.linesContentDomNode,Qe.B.Contextmenu,S=>this._onContextMenu(new Me.dO(S,!1,this.viewHelper.viewDomNode),!1))),this._lastPointerType="mouse",this._register(P.ko(this.viewHelper.linesContentDomNode,"pointerdown",S=>{const z=S.pointerType;if(z==="mouse"){this._lastPointerType="mouse";return}else z==="touch"?this._lastPointerType="touch":this._lastPointerType="pen"}));const _=new Me.DW(this.viewHelper.viewDomNode);this._register(_.onPointerMove(this.viewHelper.viewDomNode,S=>this._onMouseMove(S))),this._register(_.onPointerUp(this.viewHelper.viewDomNode,S=>this._onMouseUp(S))),this._register(_.onPointerLeave(this.viewHelper.viewDomNode,S=>this._onMouseLeave(S))),this._register(_.onPointerDown(this.viewHelper.viewDomNode,(S,z)=>this._onMouseDown(S,z)))}onTap(e){if(!e.initialTarget||!this.viewHelper.linesContentDomNode.contains(e.initialTarget))return;e.preventDefault(),this.viewHelper.focusTextArea();const i=this._createMouseTarget(new Me.dO(e,!1,this.viewHelper.viewDomNode),!1);i.position&&this.viewController.dispatchMouse({position:i.position,mouseColumn:i.position.column,startedOnLineNumbers:!1,mouseDownCount:e.tapCount,inSelectionMode:!1,altKey:!1,ctrlKey:!1,metaKey:!1,shiftKey:!1,leftButton:!1,middleButton:!1,onInjectedText:i.type===6&&i.detail.injectedText!==null})}onChange(e){this._lastPointerType==="touch"&&this._context.viewModel.viewLayout.deltaScrollNow(-e.translationX,-e.translationY)}_onMouseDown(e,i){e.browserEvent.pointerType!=="touch"&&super._onMouseDown(e,i)}}class je extends ni{constructor(e,i,r){super(e,i,r),this._register(Qe.q.addTarget(this.viewHelper.linesContentDomNode)),this._register(P.ko(this.viewHelper.linesContentDomNode,Qe.B.Tap,_=>this.onTap(_))),this._register(P.ko(this.viewHelper.linesContentDomNode,Qe.B.Change,_=>this.onChange(_))),this._register(P.ko(this.viewHelper.linesContentDomNode,Qe.B.Contextmenu,_=>this._onContextMenu(new Me.dO(_,!1,this.viewHelper.viewDomNode),!1)))}onTap(e){e.preventDefault(),this.viewHelper.focusTextArea();const i=this._createMouseTarget(new Me.dO(e,!1,this.viewHelper.viewDomNode),!1);if(i.position){const r=document.createEvent("CustomEvent");r.initEvent(ve.$D.Tap,!1,!0),this.viewHelper.dispatchTextAreaEvent(r),this.viewController.moveTo(i.position)}}onChange(e){this._context.viewModel.viewLayout.deltaScrollNow(-e.translationX,-e.translationY)}}class nt extends p.jG{constructor(e,i,r){super(),u.un&&St.e.pointerEvents?this.handler=this._register(new Te(e,i,r)):window.TouchEvent?this.handler=this._register(new je(e,i,r)):this.handler=this._register(new ni(e,i,r))}getTargetAtClientPoint(e,i){return this.handler.getTargetAtClientPoint(e,i)}}var at=y(16844),vt=y(25837),It=y(13377);class At extends ce{}var wt=y(48295),kt=y(89044);class Ct extends At{constructor(e){super(),this._context=e,this._readConfig(),this._lastCursorModelPosition=new Nt.y(1,1),this._lastCursorViewPosition=new Nt.y(1,1),this._renderResult=null,this._activeLineNumber=1,this._context.addEventHandler(this)}_readConfig(){const e=this._context.configuration.options;this._lineHeight=e.get(61);const i=e.get(62);this._renderLineNumbers=i.renderType,this._renderCustomLineNumbers=i.renderFn,this._renderFinalNewline=e.get(86);const r=e.get(133);this._lineNumbersLeft=r.lineNumbersLeft,this._lineNumbersWidth=r.lineNumbersWidth}dispose(){this._context.removeEventHandler(this),this._renderResult=null,super.dispose()}onConfigurationChanged(e){return this._readConfig(),!0}onCursorStateChanged(e){const i=e.selections[0].getPosition();this._lastCursorViewPosition=i,this._lastCursorModelPosition=this._context.viewModel.coordinatesConverter.convertViewPositionToModelPosition(i);let r=!1;return this._activeLineNumber!==i.lineNumber&&(this._activeLineNumber=i.lineNumber,r=!0),(this._renderLineNumbers===2||this._renderLineNumbers===3)&&(r=!0),r}onFlushed(e){return!0}onLinesChanged(e){return!0}onLinesDeleted(e){return!0}onLinesInserted(e){return!0}onScrollChanged(e){return e.scrollTopChanged}onZonesChanged(e){return!0}_getLineRenderLineNumber(e){const i=this._context.viewModel.coordinatesConverter.convertViewPositionToModelPosition(new Nt.y(e,1));if(i.column!==1)return"";const r=i.lineNumber;return this._renderCustomLineNumbers?this._renderCustomLineNumbers(r):this._renderLineNumbers===3?this._lastCursorModelPosition.lineNumber===r||r%10===0?String(r):"":String(r)}prepareRender(e){if(this._renderLineNumbers===0){this._renderResult=null;return}const i=u.j9?this._lineHeight%2===0?" lh-even":" lh-odd":"",r=e.visibleRange.startLineNumber,_=e.visibleRange.endLineNumber,S='<div class="'+Ct.CLASS_NAME+i+'" style="left:'+this._lineNumbersLeft+"px;width:"+this._lineNumbersWidth+'px;">';let z=null;if(this._renderLineNumbers===2){z=new Array(_-r+1),this._lastCursorViewPosition.lineNumber>=r&&this._lastCursorViewPosition.lineNumber<=_&&(z[this._lastCursorViewPosition.lineNumber-r]=this._lastCursorModelPosition.lineNumber);{let le=0;for(let me=this._lastCursorViewPosition.lineNumber+1;me<=_;me++){const Be=this._context.viewModel.coordinatesConverter.convertViewPositionToModelPosition(new Nt.y(me,1)).column!==1;Be||le++,me>=r&&(z[me-r]=Be?0:le)}}{let le=0;for(let me=this._lastCursorViewPosition.lineNumber-1;me>=r;me--){const Be=this._context.viewModel.coordinatesConverter.convertViewPositionToModelPosition(new Nt.y(me,1)).column!==1;Be||le++,me<=_&&(z[me-r]=Be?0:le)}}}const ie=this._context.viewModel.getLineCount(),re=[];for(let le=r;le<=_;le++){const me=le-r;if(!this._renderFinalNewline&&le===ie&&this._context.viewModel.getLineLength(le)===0){re[me]="";continue}let we;if(z){const Be=z[me];this._lastCursorViewPosition.lineNumber===le?we=`<span class="relative-current-line-number">${Be}</span>`:Be?we=String(Be):we=""}else we=this._getLineRenderLineNumber(le);we?le===this._activeLineNumber?re[me]='<div class="active-line-number '+Ct.CLASS_NAME+i+'" style="left:'+this._lineNumbersLeft+"px;width:"+this._lineNumbersWidth+'px;">'+we+"</div>":re[me]=S+we+"</div>":re[me]=""}this._renderResult=re}render(e,i){if(!this._renderResult)return"";const r=i-e;return r<0||r>=this._renderResult.length?"":this._renderResult[r]}}Ct.CLASS_NAME="line-numbers",(0,kt.zy)((Le,e)=>{const i=Le.getColor(wt.Qt);i&&e.addRule(`.monaco-editor .line-numbers { color: ${i}; }`);const r=Le.getColor(wt.pw);r&&e.addRule(`.monaco-editor .line-numbers.active-line-number { color: ${r}; }`)});class Gt extends pe{constructor(e){super(e);const i=this._context.configuration.options,r=i.get(133);this._canUseLayerHinting=!i.get(28),this._contentLeft=r.contentLeft,this._glyphMarginLeft=r.glyphMarginLeft,this._glyphMarginWidth=r.glyphMarginWidth,this._domNode=(0,E.Z)(document.createElement("div")),this._domNode.setClassName(Gt.OUTER_CLASS_NAME),this._domNode.setPosition("absolute"),this._domNode.setAttribute("role","presentation"),this._domNode.setAttribute("aria-hidden","true"),this._glyphMarginBackgroundDomNode=(0,E.Z)(document.createElement("div")),this._glyphMarginBackgroundDomNode.setClassName(Gt.CLASS_NAME),this._domNode.appendChild(this._glyphMarginBackgroundDomNode)}dispose(){super.dispose()}getDomNode(){return this._domNode}onConfigurationChanged(e){const i=this._context.configuration.options,r=i.get(133);return this._canUseLayerHinting=!i.get(28),this._contentLeft=r.contentLeft,this._glyphMarginLeft=r.glyphMarginLeft,this._glyphMarginWidth=r.glyphMarginWidth,!0}onScrollChanged(e){return super.onScrollChanged(e)||e.scrollTopChanged}prepareRender(e){}render(e){this._domNode.setLayerHinting(this._canUseLayerHinting),this._domNode.setContain("strict");const i=e.scrollTop-e.bigNumbersDelta;this._domNode.setTop(-i);const r=Math.min(e.scrollHeight,1e6);this._domNode.setHeight(r),this._domNode.setWidth(this._contentLeft),this._glyphMarginBackgroundDomNode.setLeft(this._glyphMarginLeft),this._glyphMarginBackgroundDomNode.setWidth(this._glyphMarginWidth),this._glyphMarginBackgroundDomNode.setHeight(r)}}Gt.CLASS_NAME="glyph-margin",Gt.OUTER_CLASS_NAME="margin";var Ht=y(82862),Ut=y(68107),Ue=y(47317),ei=y(94901);class ui{constructor(e,i,r,_,S){this._context=e,this.modelLineNumber=i,this.distanceToModelLineStart=r,this.widthOfHiddenLineTextBefore=_,this.distanceToModelLineEnd=S,this._visibleTextAreaBrand=void 0,this.startPosition=null,this.endPosition=null,this.visibleTextareaStart=null,this.visibleTextareaEnd=null,this._previousPresentation=null}prepareRender(e){const i=new Nt.y(this.modelLineNumber,this.distanceToModelLineStart+1),r=new Nt.y(this.modelLineNumber,this._context.viewModel.model.getLineMaxColumn(this.modelLineNumber)-this.distanceToModelLineEnd);this.startPosition=this._context.viewModel.coordinatesConverter.convertModelPositionToViewPosition(i),this.endPosition=this._context.viewModel.coordinatesConverter.convertModelPositionToViewPosition(r),this.startPosition.lineNumber===this.endPosition.lineNumber?(this.visibleTextareaStart=e.visibleRangeForPosition(this.startPosition),this.visibleTextareaEnd=e.visibleRangeForPosition(this.endPosition)):(this.visibleTextareaStart=null,this.visibleTextareaEnd=null)}definePresentation(e){return this._previousPresentation||(e?this._previousPresentation=e:this._previousPresentation={foreground:1,italic:!1,bold:!1,underline:!1,strikethrough:!1}),this._previousPresentation}}const oi=g.isFirefox;class ki extends pe{constructor(e,i,r){super(e),this._primaryCursorPosition=new Nt.y(1,1),this._primaryCursorVisibleRange=null,this._viewController=i,this._visibleRangeProvider=r,this._scrollLeft=0,this._scrollTop=0;const _=this._context.configuration.options,S=_.get(133);this._setAccessibilityOptions(_),this._contentLeft=S.contentLeft,this._contentWidth=S.contentWidth,this._contentHeight=S.height,this._fontInfo=_.get(46),this._lineHeight=_.get(61),this._emptySelectionClipboard=_.get(33),this._copyWithSyntaxHighlighting=_.get(21),this._visibleTextArea=null,this._selections=[new ue.L(1,1,1,1)],this._modelSelections=[new ue.L(1,1,1,1)],this._lastRenderPosition=null,this.textArea=(0,E.Z)(document.createElement("textarea")),be.write(this.textArea,6),this.textArea.setClassName(`inputarea ${Ut.S}`),this.textArea.setAttribute("wrap","off"),this.textArea.setAttribute("autocorrect","off"),this.textArea.setAttribute("autocapitalize","off"),this.textArea.setAttribute("autocomplete","off"),this.textArea.setAttribute("spellcheck","false"),this.textArea.setAttribute("aria-label",this._getAriaLabel(_)),this.textArea.setAttribute("tabindex",String(_.get(114))),this.textArea.setAttribute("role","textbox"),this.textArea.setAttribute("aria-roledescription",U.kg("editor","editor")),this.textArea.setAttribute("aria-multiline","true"),this.textArea.setAttribute("aria-haspopup","false"),this.textArea.setAttribute("aria-autocomplete","both"),_.get(30)&&_.get(83)&&this.textArea.setAttribute("readonly","true"),this.textAreaCover=(0,E.Z)(document.createElement("div")),this.textAreaCover.setPosition("absolute");const z={getLineCount:()=>this._context.viewModel.getLineCount(),getLineMaxColumn:le=>this._context.viewModel.getLineMaxColumn(le),getValueInRange:(le,me)=>this._context.viewModel.getValueInRange(le,me)},ie={getDataToCopy:()=>{const le=this._context.viewModel.getPlainTextToCopy(this._modelSelections,this._emptySelectionClipboard,u.uF),me=this._context.viewModel.model.getEOL(),we=this._emptySelectionClipboard&&this._modelSelections.length===1&&this._modelSelections[0].isEmpty(),Be=Array.isArray(le)?le:null,Re=Array.isArray(le)?le.join(me):le;let Je,st=null;if(ve.Eq.forceCopyWithSyntaxHighlighting||this._copyWithSyntaxHighlighting&&Re.length<65536){const ct=this._context.viewModel.getRichTextToCopy(this._modelSelections,this._emptySelectionClipboard);ct&&(Je=ct.html,st=ct.mode)}return{isFromEmptySelection:we,multicursorText:Be,text:Re,html:Je,mode:st}},getScreenReaderContent:le=>{if(this._accessibilitySupport===1){const me=this._selections[0];if(u.zx&&me.isEmpty()){const we=me.getStartPosition();let Be=this._getWordBeforePosition(we);if(Be.length===0&&(Be=this._getCharacterBeforePosition(we)),Be.length>0)return new It._O(Be,Be.length,Be.length,we,we)}if(g.isSafari&&!me.isEmpty()){const we="vscode-placeholder";return new It._O(we,0,we.length,null,null)}return It._O.EMPTY}if(g.isAndroid){const me=this._selections[0];if(me.isEmpty()){const we=me.getStartPosition(),[Be,Re]=this._getAndroidWordAtPosition(we);if(Be.length>0)return new It._O(Be,Re,Re,we,we)}return It._O.EMPTY}return It.Al.fromEditorSelection(le,z,this._selections[0],this._accessibilityPageSize,this._accessibilitySupport===0)},deduceModelPosition:(le,me,we)=>this._context.viewModel.deduceModelPositionRelativeToViewPosition(le,me,we)},re=this._register(new ve.M0(this.textArea.domNode));this._textAreaInput=this._register(new ve.No(ie,re,u.OS,g)),this._register(this._textAreaInput.onKeyDown(le=>{this._viewController.emitKeyDown(le)})),this._register(this._textAreaInput.onKeyUp(le=>{this._viewController.emitKeyUp(le)})),this._register(this._textAreaInput.onPaste(le=>{let me=!1,we=null,Be=null;le.metadata&&(me=this._emptySelectionClipboard&&!!le.metadata.isFromEmptySelection,we=typeof le.metadata.multicursorText<"u"?le.metadata.multicursorText:null,Be=le.metadata.mode),this._viewController.paste(le.text,me,we,Be)})),this._register(this._textAreaInput.onCut(()=>{this._viewController.cut()})),this._register(this._textAreaInput.onType(le=>{le.replacePrevCharCnt||le.replaceNextCharCnt||le.positionDelta?(It.Hf&&console.log(` => compositionType: <<${le.text}>>, ${le.replacePrevCharCnt}, ${le.replaceNextCharCnt}, ${le.positionDelta}`),this._viewController.compositionType(le.text,le.replacePrevCharCnt,le.replaceNextCharCnt,le.positionDelta)):(It.Hf&&console.log(` => type: <<${le.text}>>`),this._viewController.type(le.text))})),this._register(this._textAreaInput.onSelectionChangeRequest(le=>{this._viewController.setSelection(le)})),this._register(this._textAreaInput.onCompositionStart(le=>{const me=this.textArea.domNode,we=this._modelSelections[0],{distanceToModelLineStart:Be,widthOfHiddenTextBefore:Re}=(()=>{const st=me.value.substring(0,Math.min(me.selectionStart,me.selectionEnd)),ct=st.lastIndexOf(` `),mt=st.substring(ct+1),xt=mt.lastIndexOf(" "),Dt=mt.length-xt-1,Jt=we.getStartPosition(),$t=Math.min(Jt.column-1,Dt),ai=Jt.column-1-$t,ii=mt.substring(0,mt.length-$t),Zt=Kt(ii,this._fontInfo);return{distanceToModelLineStart:ai,widthOfHiddenTextBefore:Zt}})(),{distanceToModelLineEnd:Je}=(()=>{const st=me.value.substring(Math.max(me.selectionStart,me.selectionEnd)),ct=st.indexOf(` `),mt=ct===-1?st:st.substring(0,ct),xt=mt.indexOf(" "),Dt=xt===-1?mt.length:mt.length-xt-1,Jt=we.getEndPosition(),$t=Math.min(this._context.viewModel.model.getLineMaxColumn(Jt.lineNumber)-Jt.column,Dt);return{distanceToModelLineEnd:this._context.viewModel.model.getLineMaxColumn(Jt.lineNumber)-Jt.column-$t}})();this._context.viewModel.revealRange("keyboard",!0,Pt.Q.fromPositions(this._selections[0].getStartPosition()),0,1),this._visibleTextArea=new ui(this._context,we.startLineNumber,Be,Re,Je),this._visibleTextArea.prepareRender(this._visibleRangeProvider),this._render(),this.textArea.setClassName(`inputarea ${Ut.S} ime-input`),this._viewController.compositionStart(),this._context.viewModel.onCompositionStart()})),this._register(this._textAreaInput.onCompositionUpdate(le=>{this._visibleTextArea&&(this._visibleTextArea.prepareRender(this._visibleRangeProvider),this._render())})),this._register(this._textAreaInput.onCompositionEnd(()=>{this._visibleTextArea=null,this._render(),this.textArea.setClassName(`inputarea ${Ut.S}`),this._viewController.compositionEnd(),this._context.viewModel.onCompositionEnd()})),this._register(this._textAreaInput.onFocus(()=>{this._context.viewModel.setHasFocus(!0)})),this._register(this._textAreaInput.onBlur(()=>{this._context.viewModel.setHasFocus(!1)}))}dispose(){super.dispose()}_getAndroidWordAtPosition(e){const i='`~!@#$%^&*()-=+[{]}\\|;:",.<>/?',r=this._context.viewModel.getLineContent(e.lineNumber),_=(0,Ht.i)(i);let S=!0,z=e.column,ie=!0,re=e.column,le=0;for(;le<50&&(S||ie);){if(S&&z<=1&&(S=!1),S){const me=r.charCodeAt(z-2);_.get(me)!==0?S=!1:z--}if(ie&&re>r.length&&(ie=!1),ie){const me=r.charCodeAt(re-1);_.get(me)!==0?ie=!1:re++}le++}return[r.substring(z-1,re-1),e.column-z]}_getWordBeforePosition(e){const i=this._context.viewModel.getLineContent(e.lineNumber),r=(0,Ht.i)(this._context.configuration.options.get(119));let _=e.column,S=0;for(;_>1;){const z=i.charCodeAt(_-2);if(r.get(z)!==0||S>50)return i.substring(_-1,e.column-1);S++,_--}return i.substring(0,e.column-1)}_getCharacterBeforePosition(e){if(e.column>1){const r=this._context.viewModel.getLineContent(e.lineNumber).charAt(e.column-2);if(!at.pc(r.charCodeAt(0)))return r}return""}_getAriaLabel(e){return e.get(2)===1?U.kg("accessibilityOffAriaLabel","The editor is not accessible at this time. Press {0} for options.",u.j9?"Shift+Alt+F1":"Alt+F1"):e.get(4)}_setAccessibilityOptions(e){this._accessibilitySupport=e.get(2);const i=e.get(3);this._accessibilitySupport===2&&i===W.qB.accessibilityPageSize.defaultValue?this._accessibilityPageSize=500:this._accessibilityPageSize=i}onConfigurationChanged(e){const i=this._context.configuration.options,r=i.get(133);return this._setAccessibilityOptions(i),this._contentLeft=r.contentLeft,this._contentWidth=r.contentWidth,this._contentHeight=r.height,this._fontInfo=i.get(46),this._lineHeight=i.get(61),this._emptySelectionClipboard=i.get(33),this._copyWithSyntaxHighlighting=i.get(21),this.textArea.setAttribute("aria-label",this._getAriaLabel(i)),this.textArea.setAttribute("tabindex",String(i.get(114))),(e.hasChanged(30)||e.hasChanged(83))&&(i.get(30)&&i.get(83)?this.textArea.setAttribute("readonly","true"):this.textArea.removeAttribute("readonly")),e.hasChanged(2)&&this._textAreaInput.writeScreenReaderContent("strategy changed"),!0}onCursorStateChanged(e){return this._selections=e.selections.slice(0),this._modelSelections=e.modelSelections.slice(0),this._textAreaInput.writeScreenReaderContent("selection changed"),!0}onDecorationsChanged(e){return!0}onFlushed(e){return!0}onLinesChanged(e){return!0}onLinesDeleted(e){return!0}onLinesInserted(e){return!0}onScrollChanged(e){return this._scrollLeft=e.scrollLeft,this._scrollTop=e.scrollTop,!0}onZonesChanged(e){return!0}isFocused(){return this._textAreaInput.isFocused()}focusTextArea(){this._textAreaInput.focusTextArea()}getLastRenderData(){return this._lastRenderPosition}setAriaOptions(e){e.activeDescendant?(this.textArea.setAttribute("aria-haspopup","true"),this.textArea.setAttribute("aria-autocomplete","list"),this.textArea.setAttribute("aria-activedescendant",e.activeDescendant)):(this.textArea.setAttribute("aria-haspopup","false"),this.textArea.setAttribute("aria-autocomplete","both"),this.textArea.removeAttribute("aria-activedescendant")),e.role&&this.textArea.setAttribute("role",e.role)}prepareRender(e){var i;this._primaryCursorPosition=new Nt.y(this._selections[0].positionLineNumber,this._selections[0].positionColumn),this._primaryCursorVisibleRange=e.visibleRangeForPosition(this._primaryCursorPosition),(i=this._visibleTextArea)===null||i===void 0||i.prepareRender(e)}render(e){this._textAreaInput.writeScreenReaderContent("render"),this._render()}_render(){if(this._visibleTextArea){const r=this._visibleTextArea.visibleTextareaStart,_=this._visibleTextArea.visibleTextareaEnd,S=this._visibleTextArea.startPosition,z=this._visibleTextArea.endPosition;if(S&&z&&r&&_&&_.left>=this._scrollLeft&&r.left<=this._scrollLeft+this._contentWidth){const ie=this._context.viewLayout.getVerticalOffsetForLineNumber(this._primaryCursorPosition.lineNumber)-this._scrollTop,re=this._newlinecount(this.textArea.domNode.value.substr(0,this.textArea.domNode.selectionStart));let le=this._visibleTextArea.widthOfHiddenLineTextBefore,me=this._contentLeft+r.left-this._scrollLeft,we=_.left-r.left+1;if(me<this._contentLeft){const mt=this._contentLeft-me;me+=mt,le+=mt,we-=mt}we>this._contentWidth&&(we=this._contentWidth);const Be=this._context.viewModel.getViewLineData(S.lineNumber),Re=Be.tokens.findTokenIndexAtOffset(S.column-1),Je=Be.tokens.findTokenIndexAtOffset(z.column-1),st=Re===Je,ct=this._visibleTextArea.definePresentation(st?Be.tokens.getPresentation(Re):null);this.textArea.domNode.scrollTop=re*this._lineHeight,this.textArea.domNode.scrollLeft=le,this._doRender({lastRenderPosition:null,top:ie,left:me,width:we,height:this._lineHeight,useCover:!1,color:(Ue.dG.getColorMap()||[])[ct.foreground],italic:ct.italic,bold:ct.bold,underline:ct.underline,strikethrough:ct.strikethrough})}return}if(!this._primaryCursorVisibleRange){this._renderAtTopLeft();return}const e=this._contentLeft+this._primaryCursorVisibleRange.left-this._scrollLeft;if(e<this._contentLeft||e>this._contentLeft+this._contentWidth){this._renderAtTopLeft();return}const i=this._context.viewLayout.getVerticalOffsetForLineNumber(this._selections[0].positionLineNumber)-this._scrollTop;if(i<0||i>this._contentHeight){this._renderAtTopLeft();return}if(u.zx){this._doRender({lastRenderPosition:this._primaryCursorPosition,top:i,left:e,width:oi?0:1,height:this._lineHeight,useCover:!1}),this.textArea.domNode.scrollLeft=this._primaryCursorVisibleRange.left;const r=this._newlinecount(this.textArea.domNode.value.substr(0,this.textArea.domNode.selectionStart));this.textArea.domNode.scrollTop=r*this._lineHeight;return}this._doRender({lastRenderPosition:this._primaryCursorPosition,top:i,left:e,width:oi?0:1,height:oi?0:1,useCover:!1})}_newlinecount(e){let i=0,r=-1;do{if(r=e.indexOf(` `,r+1),r===-1)break;i++}while(!0);return i}_renderAtTopLeft(){this._doRender({lastRenderPosition:null,top:0,left:0,width:oi?0:1,height:oi?0:1,useCover:!0})}_doRender(e){this._lastRenderPosition=e.lastRenderPosition;const i=this.textArea,r=this.textAreaCover;(0,vt.M)(i,this._fontInfo),i.setTop(e.top),i.setLeft(e.left),i.setWidth(e.width),i.setHeight(e.height),i.setColor(e.color?ei.Q1.Format.CSS.formatHex(e.color):""),i.setFontStyle(e.italic?"italic":""),e.bold&&i.setFontWeight("bold"),i.setTextDecoration(`${e.underline?" underline":""}${e.strikethrough?" line-through":""}`),r.setTop(e.useCover?e.top:0),r.setLeft(e.useCover?e.left:0),r.setWidth(e.useCover?e.width:0),r.setHeight(e.useCover?e.height:0);const _=this._context.configuration.options;_.get(52)?r.setClassName("monaco-editor-background textAreaCover "+Gt.OUTER_CLASS_NAME):_.get(62).renderType!==0?r.setClassName("monaco-editor-background textAreaCover "+Ct.CLASS_NAME):r.setClassName("monaco-editor-background textAreaCover")}}function Kt(Le,e){if(Le.length===0)return 0;const i=document.createElement("div");i.style.position="absolute",i.style.top="-50000px",i.style.width="50000px";const r=document.createElement("span");(0,vt.M)(r,e),r.style.whiteSpace="pre",r.append(Le),i.appendChild(r),document.body.appendChild(i);const _=r.offsetWidth;return document.body.removeChild(i),_}var li=y(72521);class Ci{constructor(e,i,r,_){this.configuration=e,this.viewModel=i,this.userInputEvents=r,this.commandDelegate=_}paste(e,i,r,_){this.commandDelegate.paste(e,i,r,_)}type(e){this.commandDelegate.type(e)}compositionType(e,i,r,_){this.commandDelegate.compositionType(e,i,r,_)}compositionStart(){this.commandDelegate.startComposition()}compositionEnd(){this.commandDelegate.endComposition()}cut(){this.commandDelegate.cut()}setSelection(e){li.QM.SetSelection.runCoreEditorCommand(this.viewModel,{source:"keyboard",selection:e})}_validateViewColumn(e){const i=this.viewModel.getLineMinColumn(e.lineNumber);return e.column<i?new Nt.y(e.lineNumber,i):e}_hasMulticursorModifier(e){switch(this.configuration.options.get(72)){case"altKey":return e.altKey;case"ctrlKey":return e.ctrlKey;case"metaKey":return e.metaKey;default:return!1}}_hasNonMulticursorModifier(e){switch(this.configuration.options.get(72)){case"altKey":return e.ctrlKey||e.metaKey;case"ctrlKey":return e.altKey||e.metaKey;case"metaKey":return e.ctrlKey||e.altKey;default:return!1}}dispatchMouse(e){const i=this.configuration.options,r=u.j9&&i.get(98),_=i.get(18);e.middleButton&&!r?this._columnSelect(e.position,e.mouseColumn,e.inSelectionMode):e.startedOnLineNumbers?this._hasMulticursorModifier(e)?e.inSelectionMode?this._lastCursorLineSelect(e.position):this._createCursor(e.position,!0):e.inSelectionMode?this._lineSelectDrag(e.position):this._lineSelect(e.position):e.mouseDownCount>=4?this._selectAll():e.mouseDownCount===3?this._hasMulticursorModifier(e)?e.inSelectionMode?this._lastCursorLineSelectDrag(e.position):this._lastCursorLineSelect(e.position):e.inSelectionMode?this._lineSelectDrag(e.position):this._lineSelect(e.position):e.mouseDownCount===2?e.onInjectedText||(this._hasMulticursorModifier(e)?this._lastCursorWordSelect(e.position):e.inSelectionMode?this._wordSelectDrag(e.position):this._wordSelect(e.position)):this._hasMulticursorModifier(e)?this._hasNonMulticursorModifier(e)||(e.shiftKey?this._columnSelect(e.position,e.mouseColumn,!0):e.inSelectionMode?this._lastCursorMoveToSelect(e.position):this._createCursor(e.position,!1)):e.inSelectionMode?e.altKey?this._columnSelect(e.position,e.mouseColumn,!0):_?this._columnSelect(e.position,e.mouseColumn,!0):this._moveToSelect(e.position):this.moveTo(e.position)}_usualArgs(e){return e=this._validateViewColumn(e),{source:"mouse",position:this._convertViewToModelPosition(e),viewPosition:e}}moveTo(e){li.QM.MoveTo.runCoreEditorCommand(this.viewModel,this._usualArgs(e))}_moveToSelect(e){li.QM.MoveToSelect.runCoreEditorCommand(this.viewModel,this._usualArgs(e))}_columnSelect(e,i,r){e=this._validateViewColumn(e),li.QM.ColumnSelect.runCoreEditorCommand(this.viewModel,{source:"mouse",position:this._convertViewToModelPosition(e),viewPosition:e,mouseColumn:i,doColumnSelect:r})}_createCursor(e,i){e=this._validateViewColumn(e),li.QM.CreateCursor.runCoreEditorCommand(this.viewModel,{source:"mouse",position:this._convertViewToModelPosition(e),viewPosition:e,wholeLine:i})}_lastCursorMoveToSelect(e){li.QM.LastCursorMoveToSelect.runCoreEditorCommand(this.viewModel,this._usualArgs(e))}_wordSelect(e){li.QM.WordSelect.runCoreEditorCommand(this.viewModel,this._usualArgs(e))}_wordSelectDrag(e){li.QM.WordSelectDrag.runCoreEditorCommand(this.viewModel,this._usualArgs(e))}_lastCursorWordSelect(e){li.QM.LastCursorWordSelect.runCoreEditorCommand(this.viewModel,this._usualArgs(e))}_lineSelect(e){li.QM.LineSelect.runCoreEditorCommand(this.viewModel,this._usualArgs(e))}_lineSelectDrag(e){li.QM.LineSelectDrag.runCoreEditorCommand(this.viewModel,this._usualArgs(e))}_lastCursorLineSelect(e){li.QM.LastCursorLineSelect.runCoreEditorCommand(this.viewModel,this._usualArgs(e))}_lastCursorLineSelectDrag(e){li.QM.LastCursorLineSelectDrag.runCoreEditorCommand(this.viewModel,this._usualArgs(e))}_selectAll(){li.QM.SelectAll.runCoreEditorCommand(this.viewModel,{source:"mouse"})}_convertViewToModelPosition(e){return this.viewModel.coordinatesConverter.convertViewPositionToModelPosition(e)}emitKeyDown(e){this.userInputEvents.emitKeyDown(e)}emitKeyUp(e){this.userInputEvents.emitKeyUp(e)}emitContextMenu(e){this.userInputEvents.emitContextMenu(e)}emitMouseMove(e){this.userInputEvents.emitMouseMove(e)}emitMouseLeave(e){this.userInputEvents.emitMouseLeave(e)}emitMouseUp(e){this.userInputEvents.emitMouseUp(e)}emitMouseDown(e){this.userInputEvents.emitMouseDown(e)}emitMouseDrag(e){this.userInputEvents.emitMouseDrag(e)}emitMouseDrop(e){this.userInputEvents.emitMouseDrop(e)}emitMouseDropCanceled(){this.userInputEvents.emitMouseDropCanceled()}emitMouseWheel(e){this.userInputEvents.emitMouseWheel(e)}}class mi{constructor(e){this.onKeyDown=null,this.onKeyUp=null,this.onContextMenu=null,this.onMouseMove=null,this.onMouseLeave=null,this.onMouseDown=null,this.onMouseUp=null,this.onMouseDrag=null,this.onMouseDrop=null,this.onMouseDropCanceled=null,this.onMouseWheel=null,this._coordinatesConverter=e}emitKeyDown(e){var i;(i=this.onKeyDown)===null||i===void 0||i.call(this,e)}emitKeyUp(e){var i;(i=this.onKeyUp)===null||i===void 0||i.call(this,e)}emitContextMenu(e){var i;(i=this.onContextMenu)===null||i===void 0||i.call(this,this._convertViewToModelMouseEvent(e))}emitMouseMove(e){var i;(i=this.onMouseMove)===null||i===void 0||i.call(this,this._convertViewToModelMouseEvent(e))}emitMouseLeave(e){var i;(i=this.onMouseLeave)===null||i===void 0||i.call(this,this._convertViewToModelMouseEvent(e))}emitMouseDown(e){var i;(i=this.onMouseDown)===null||i===void 0||i.call(this,this._convertViewToModelMouseEvent(e))}emitMouseUp(e){var i;(i=this.onMouseUp)===null||i===void 0||i.call(this,this._convertViewToModelMouseEvent(e))}emitMouseDrag(e){var i;(i=this.onMouseDrag)===null||i===void 0||i.call(this,this._convertViewToModelMouseEvent(e))}emitMouseDrop(e){var i;(i=this.onMouseDrop)===null||i===void 0||i.call(this,this._convertViewToModelMouseEvent(e))}emitMouseDropCanceled(){var e;(e=this.onMouseDropCanceled)===null||e===void 0||e.call(this)}emitMouseWheel(e){var i;(i=this.onMouseWheel)===null||i===void 0||i.call(this,e)}_convertViewToModelMouseEvent(e){return e.target?{event:e.event,target:this._convertViewToModelMouseTarget(e.target)}:e}_convertViewToModelMouseTarget(e){return mi.convertViewToModelMouseTarget(e,this._coordinatesConverter)}static convertViewToModelMouseTarget(e,i){const r=Object.assign({},e);return r.position&&(r.position=i.convertViewPositionToModelPosition(r.position)),r.range&&(r.range=i.convertViewRangeToModelRange(r.range)),r}}var Tt=y(54324),qt;class Ni{constructor(e){this._createLine=e,this._set(1,[])}flush(){this._set(1,[])}_set(e,i){this._lines=i,this._rendLineNumberStart=e}_get(){return{rendLineNumberStart:this._rendLineNumberStart,lines:this._lines}}getStartLineNumber(){return this._rendLineNumberStart}getEndLineNumber(){return this._rendLineNumberStart+this._lines.length-1}getCount(){return this._lines.length}getLine(e){const i=e-this._rendLineNumberStart;if(i<0||i>=this._lines.length)throw new Error("Illegal value for lineNumber");return this._lines[i]}onLinesDeleted(e,i){if(this.getCount()===0)return null;const r=this.getStartLineNumber(),_=this.getEndLineNumber();if(i<r){const re=i-e+1;return this._rendLineNumberStart-=re,null}if(e>_)return null;let S=0,z=0;for(let re=r;re<=_;re++){const le=re-this._rendLineNumberStart;e<=re&&re<=i&&(z===0?(S=le,z=1):z++)}if(e<r){let re=0;i<r?re=i-e+1:re=r-e,this._rendLineNumberStart-=re}return this._lines.splice(S,z)}onLinesChanged(e,i){const r=e+i-1;if(this.getCount()===0)return!1;const _=this.getStartLineNumber(),S=this.getEndLineNumber();let z=!1;for(let ie=e;ie<=r;ie++)ie>=_&&ie<=S&&(this._lines[ie-this._rendLineNumberStart].onContentChanged(),z=!0);return z}onLinesInserted(e,i){if(this.getCount()===0)return null;const r=i-e+1,_=this.getStartLineNumber(),S=this.getEndLineNumber();if(e<=_)return this._rendLineNumberStart+=r,null;if(e>S)return null;if(r+e>S)return this._lines.splice(e-this._rendLineNumberStart,S-e+1);const z=[];for(let we=0;we<r;we++)z[we]=this._createLine();const ie=e-this._rendLineNumberStart,re=this._lines.slice(0,ie),le=this._lines.slice(ie,this._lines.length-r),me=this._lines.slice(this._lines.length-r,this._lines.length);return this._lines=re.concat(z).concat(le),me}onTokensChanged(e){if(this.getCount()===0)return!1;const i=this.getStartLineNumber(),r=this.getEndLineNumber();let _=!1;for(let S=0,z=e.length;S<z;S++){const ie=e[S];if(ie.toLineNumber<i||ie.fromLineNumber>r)continue;const re=Math.max(i,ie.fromLineNumber),le=Math.min(r,ie.toLineNumber);for(let me=re;me<=le;me++){const we=me-this._rendLineNumberStart;this._lines[we].onTokensChanged(),_=!0}}return _}}class Fi{constructor(e){this._host=e,this.domNode=this._createDomNode(),this._linesCollection=new Ni(()=>this._host.createVisibleLine())}_createDomNode(){const e=(0,E.Z)(document.createElement("div"));return e.setClassName("view-layer"),e.setPosition("absolute"),e.domNode.setAttribute("role","presentation"),e.domNode.setAttribute("aria-hidden","true"),e}onConfigurationChanged(e){return!!e.hasChanged(133)}onFlushed(e){return this._linesCollection.flush(),!0}onLinesChanged(e){return this._linesCollection.onLinesChanged(e.fromLineNumber,e.count)}onLinesDeleted(e){const i=this._linesCollection.onLinesDeleted(e.fromLineNumber,e.toLineNumber);if(i)for(let r=0,_=i.length;r<_;r++){const S=i[r].getDomNode();S&&this.domNode.domNode.removeChild(S)}return!0}onLinesInserted(e){const i=this._linesCollection.onLinesInserted(e.fromLineNumber,e.toLineNumber);if(i)for(let r=0,_=i.length;r<_;r++){const S=i[r].getDomNode();S&&this.domNode.domNode.removeChild(S)}return!0}onScrollChanged(e){return e.scrollTopChanged}onTokensChanged(e){return this._linesCollection.onTokensChanged(e.ranges)}onZonesChanged(e){return!0}getStartLineNumber(){return this._linesCollection.getStartLineNumber()}getEndLineNumber(){return this._linesCollection.getEndLineNumber()}getVisibleLine(e){return this._linesCollection.getLine(e)}renderLines(e){const i=this._linesCollection._get(),r=new yi(this.domNode.domNode,this._host,e),_={rendLineNumberStart:i.rendLineNumberStart,lines:i.lines,linesLength:i.lines.length},S=r.render(_,e.startLineNumber,e.endLineNumber,e.relativeVerticalOffset);this._linesCollection._set(S.rendLineNumberStart,S.lines)}}class yi{constructor(e,i,r){this.domNode=e,this.host=i,this.viewportData=r}render(e,i,r,_){const S={rendLineNumberStart:e.rendLineNumberStart,lines:e.lines.slice(0),linesLength:e.linesLength};if(S.rendLineNumberStart+S.linesLength-1<i||r<S.rendLineNumberStart){S.rendLineNumberStart=i,S.linesLength=r-i+1,S.lines=[];for(let z=i;z<=r;z++)S.lines[z-i]=this.host.createVisibleLine();return this._finishRendering(S,!0,_),S}if(this._renderUntouchedLines(S,Math.max(i-S.rendLineNumberStart,0),Math.min(r-S.rendLineNumberStart,S.linesLength-1),_,i),S.rendLineNumberStart>i){const z=i,ie=Math.min(r,S.rendLineNumberStart-1);z<=ie&&(this._insertLinesBefore(S,z,ie,_,i),S.linesLength+=ie-z+1)}else if(S.rendLineNumberStart<i){const z=Math.min(S.linesLength,i-S.rendLineNumberStart);z>0&&(this._removeLinesBefore(S,z),S.linesLength-=z)}if(S.rendLineNumberStart=i,S.rendLineNumberStart+S.linesLength-1<r){const z=S.rendLineNumberStart+S.linesLength,ie=r;z<=ie&&(this._insertLinesAfter(S,z,ie,_,i),S.linesLength+=ie-z+1)}else if(S.rendLineNumberStart+S.linesLength-1>r){const z=Math.max(0,r-S.rendLineNumberStart+1),re=S.linesLength-1-z+1;re>0&&(this._removeLinesAfter(S,re),S.linesLength-=re)}return this._finishRendering(S,!1,_),S}_renderUntouchedLines(e,i,r,_,S){const z=e.rendLineNumberStart,ie=e.lines;for(let re=i;re<=r;re++){const le=z+re;ie[re].layoutLine(le,_[le-S])}}_insertLinesBefore(e,i,r,_,S){const z=[];let ie=0;for(let re=i;re<=r;re++)z[ie++]=this.host.createVisibleLine();e.lines=z.concat(e.lines)}_removeLinesBefore(e,i){for(let r=0;r<i;r++){const _=e.lines[r].getDomNode();_&&this.domNode.removeChild(_)}e.lines.splice(0,i)}_insertLinesAfter(e,i,r,_,S){const z=[];let ie=0;for(let re=i;re<=r;re++)z[ie++]=this.host.createVisibleLine();e.lines=e.lines.concat(z)}_removeLinesAfter(e,i){const r=e.linesLength-i;for(let _=0;_<i;_++){const S=e.lines[r+_].getDomNode();S&&this.domNode.removeChild(S)}e.lines.splice(r,i)}_finishRenderingNewLines(e,i,r,_){yi._ttPolicy&&(r=yi._ttPolicy.createHTML(r));const S=this.domNode.lastChild;i||!S?this.domNode.innerHTML=r:S.insertAdjacentHTML("afterend",r);let z=this.domNode.lastChild;for(let ie=e.linesLength-1;ie>=0;ie--){const re=e.lines[ie];_[ie]&&(re.setDomNode(z),z=z.previousSibling)}}_finishRenderingInvalidLines(e,i,r){const _=document.createElement("div");yi._ttPolicy&&(i=yi._ttPolicy.createHTML(i)),_.innerHTML=i;for(let S=0;S<e.linesLength;S++){const z=e.lines[S];if(r[S]){const ie=_.firstChild,re=z.getDomNode();re.parentNode.replaceChild(ie,re),z.setDomNode(ie)}}}_finishRendering(e,i,r){const _=yi._sb,S=e.linesLength,z=e.lines,ie=e.rendLineNumberStart,re=[];{_.reset();let le=!1;for(let me=0;me<S;me++){const we=z[me];re[me]=!1,!(we.getDomNode()||!we.renderLine(me+ie,r[me],this.viewportData,_))&&(re[me]=!0,le=!0)}le&&this._finishRenderingNewLines(e,i,_.build(),re)}{_.reset();let le=!1;const me=[];for(let we=0;we<S;we++){const Be=z[we];me[we]=!1,!(re[we]||!Be.renderLine(we+ie,r[we],this.viewportData,_))&&(me[we]=!0,le=!0)}le&&this._finishRenderingInvalidLines(e,_.build(),me)}}}yi._ttPolicy=(qt=window.trustedTypes)===null||qt===void 0?void 0:qt.createPolicy("editorViewLayer",{createHTML:Le=>Le}),yi._sb=(0,Tt.Du)(1e5);class ti extends pe{constructor(e){super(e),this._visibleLines=new Fi(this),this.domNode=this._visibleLines.domNode,this._dynamicOverlays=[],this._isFocused=!1,this.domNode.setClassName("view-overlays")}shouldRender(){if(super.shouldRender())return!0;for(let e=0,i=this._dynamicOverlays.length;e<i;e++)if(this._dynamicOverlays[e].shouldRender())return!0;return!1}dispose(){super.dispose();for(let e=0,i=this._dynamicOverlays.length;e<i;e++)this._dynamicOverlays[e].dispose();this._dynamicOverlays=[]}getDomNode(){return this.domNode}createVisibleLine(){return new wi(this._context.configuration,this._dynamicOverlays)}addDynamicOverlay(e){this._dynamicOverlays.push(e)}onConfigurationChanged(e){this._visibleLines.onConfigurationChanged(e);const i=this._visibleLines.getStartLineNumber(),r=this._visibleLines.getEndLineNumber();for(let _=i;_<=r;_++)this._visibleLines.getVisibleLine(_).onConfigurationChanged(e);return!0}onFlushed(e){return this._visibleLines.onFlushed(e)}onFocusChanged(e){return this._isFocused=e.isFocused,!0}onLinesChanged(e){return this._visibleLines.onLinesChanged(e)}onLinesDeleted(e){return this._visibleLines.onLinesDeleted(e)}onLinesInserted(e){return this._visibleLines.onLinesInserted(e)}onScrollChanged(e){return this._visibleLines.onScrollChanged(e)||!0}onTokensChanged(e){return this._visibleLines.onTokensChanged(e)}onZonesChanged(e){return this._visibleLines.onZonesChanged(e)}prepareRender(e){const i=this._dynamicOverlays.filter(r=>r.shouldRender());for(let r=0,_=i.length;r<_;r++){const S=i[r];S.prepareRender(e),S.onDidRender()}}render(e){this._viewOverlaysRender(e),this.domNode.toggleClassName("focused",this._isFocused)}_viewOverlaysRender(e){this._visibleLines.renderLines(e.viewportData)}}class wi{constructor(e,i){this._configuration=e,this._lineHeight=this._configuration.options.get(61),this._dynamicOverlays=i,this._domNode=null,this._renderedContent=null}getDomNode(){return this._domNode?this._domNode.domNode:null}setDomNode(e){this._domNode=(0,E.Z)(e)}onContentChanged(){}onTokensChanged(){}onConfigurationChanged(e){this._lineHeight=this._configuration.options.get(61)}renderLine(e,i,r,_){let S="";for(let z=0,ie=this._dynamicOverlays.length;z<ie;z++){const re=this._dynamicOverlays[z];S+=re.render(r.startLineNumber,e)}return this._renderedContent===S?!1:(this._renderedContent=S,_.appendASCIIString('<div style="position:absolute;top:'),_.appendASCIIString(String(i)),_.appendASCIIString("px;width:100%;height:"),_.appendASCIIString(String(this._lineHeight)),_.appendASCIIString('px;">'),_.appendASCIIString(S),_.appendASCIIString("</div>"),!0)}layoutLine(e,i){this._domNode&&(this._domNode.setTop(i),this._domNode.setHeight(this._lineHeight))}}class Qi extends ti{constructor(e){super(e);const r=this._context.configuration.options.get(133);this._contentWidth=r.contentWidth,this.domNode.setHeight(0)}onConfigurationChanged(e){const r=this._context.configuration.options.get(133);return this._contentWidth=r.contentWidth,super.onConfigurationChanged(e)||!0}onScrollChanged(e){return super.onScrollChanged(e)||e.scrollWidthChanged}_viewOverlaysRender(e){super._viewOverlaysRender(e),this.domNode.setWidth(Math.max(e.scrollWidth,this._contentWidth))}}class Vi extends ti{constructor(e){super(e);const i=this._context.configuration.options,r=i.get(133);this._contentLeft=r.contentLeft,this.domNode.setClassName("margin-view-overlays"),this.domNode.setWidth(1),(0,vt.M)(this.domNode,i.get(46))}onConfigurationChanged(e){const i=this._context.configuration.options;(0,vt.M)(this.domNode,i.get(46));const r=i.get(133);return this._contentLeft=r.contentLeft,super.onConfigurationChanged(e)||!0}onScrollChanged(e){return super.onScrollChanged(e)||e.scrollHeightChanged}_viewOverlaysRender(e){super._viewOverlaysRender(e);const i=Math.min(e.scrollHeight,1e6);this.domNode.setHeight(i),this.domNode.setWidth(this._contentLeft)}}class Zi{constructor(e,i){this._coordinateBrand=void 0,this.top=e,this.left=i}}class Ji extends pe{constructor(e,i){super(e),this._viewDomNode=i,this._widgets={},this.domNode=(0,E.Z)(document.createElement("div")),be.write(this.domNode,1),this.domNode.setClassName("contentWidgets"),this.domNode.setPosition("absolute"),this.domNode.setTop(0),this.overflowingContentWidgetsDomNode=(0,E.Z)(document.createElement("div")),be.write(this.overflowingContentWidgetsDomNode,2),this.overflowingContentWidgetsDomNode.setClassName("overflowingContentWidgets")}dispose(){super.dispose(),this._widgets={}}onConfigurationChanged(e){const i=Object.keys(this._widgets);for(const r of i)this._widgets[r].onConfigurationChanged(e);return!0}onDecorationsChanged(e){return!0}onFlushed(e){return!0}onLineMappingChanged(e){const i=Object.keys(this._widgets);for(const r of i)this._widgets[r].onLineMappingChanged(e);return!0}onLinesChanged(e){return!0}onLinesDeleted(e){return!0}onLinesInserted(e){return!0}onScrollChanged(e){return!0}onZonesChanged(e){return!0}addWidget(e){const i=new qi(this._context,this._viewDomNode,e);this._widgets[i.id]=i,i.allowEditorOverflow?this.overflowingContentWidgetsDomNode.appendChild(i.domNode):this.domNode.appendChild(i.domNode),this.setShouldRender()}setWidgetPosition(e,i,r,_){this._widgets[e.getId()].setPosition(i,r,_),this.setShouldRender()}removeWidget(e){const i=e.getId();if(this._widgets.hasOwnProperty(i)){const r=this._widgets[i];delete this._widgets[i];const _=r.domNode.domNode;_.parentNode.removeChild(_),_.removeAttribute("monaco-visible-content-widget"),this.setShouldRender()}}shouldSuppressMouseDownOnWidget(e){return this._widgets.hasOwnProperty(e)?this._widgets[e].suppressMouseDown:!1}onBeforeRender(e){const i=Object.keys(this._widgets);for(const r of i)this._widgets[r].onBeforeRender(e)}prepareRender(e){const i=Object.keys(this._widgets);for(const r of i)this._widgets[r].prepareRender(e)}render(e){const i=Object.keys(this._widgets);for(const r of i)this._widgets[r].render(e)}}class qi{constructor(e,i,r){this._context=e,this._viewDomNode=i,this._actual=r,this.domNode=(0,E.Z)(this._actual.getDomNode()),this.id=this._actual.getId(),this.allowEditorOverflow=this._actual.allowEditorOverflow||!1,this.suppressMouseDown=this._actual.suppressMouseDown||!1;const _=this._context.configuration.options,S=_.get(133);this._fixedOverflowWidgets=_.get(38),this._contentWidth=S.contentWidth,this._contentLeft=S.contentLeft,this._lineHeight=_.get(61),this._range=null,this._viewRange=null,this._affinity=null,this._preference=[],this._cachedDomNodeOffsetWidth=-1,this._cachedDomNodeOffsetHeight=-1,this._maxWidth=this._getMaxWidth(),this._isVisible=!1,this._renderData=null,this.domNode.setPosition(this._fixedOverflowWidgets&&this.allowEditorOverflow?"fixed":"absolute"),this.domNode.setDisplay("none"),this.domNode.setVisibility("hidden"),this.domNode.setAttribute("widgetId",this.id),this.domNode.setMaxWidth(this._maxWidth)}onConfigurationChanged(e){const i=this._context.configuration.options;if(this._lineHeight=i.get(61),e.hasChanged(133)){const r=i.get(133);this._contentLeft=r.contentLeft,this._contentWidth=r.contentWidth,this._maxWidth=this._getMaxWidth()}}onLineMappingChanged(e){this._setPosition(this._range,this._affinity)}_setPosition(e,i){var r;if(this._range=e,this._viewRange=null,this._affinity=i,this._range){const _=this._context.viewModel.model.validateRange(this._range);(this._context.viewModel.coordinatesConverter.modelPositionIsVisible(_.getStartPosition())||this._context.viewModel.coordinatesConverter.modelPositionIsVisible(_.getEndPosition()))&&(this._viewRange=this._context.viewModel.coordinatesConverter.convertModelRangeToViewRange(_,(r=this._affinity)!==null&&r!==void 0?r:void 0))}}_getMaxWidth(){return this.allowEditorOverflow?window.innerWidth||document.documentElement.offsetWidth||document.body.offsetWidth:this._contentWidth}setPosition(e,i,r){this._setPosition(e,r),this._preference=i,this._viewRange&&this._preference&&this._preference.length>0?this.domNode.setDisplay("block"):this.domNode.setDisplay("none"),this._cachedDomNodeOffsetWidth=-1,this._cachedDomNodeOffsetHeight=-1}_layoutBoxInViewport(e,i,r,_,S){const z=e.top,ie=z,re=i.top+this._lineHeight,le=S.viewportHeight-re,me=z-_,we=ie>=_,Be=re,Re=le>=_;let Je=e.left,st=i.left;return Je+r>S.scrollLeft+S.viewportWidth&&(Je=S.scrollLeft+S.viewportWidth-r),st+r>S.scrollLeft+S.viewportWidth&&(st=S.scrollLeft+S.viewportWidth-r),Je<S.scrollLeft&&(Je=S.scrollLeft),st<S.scrollLeft&&(st=S.scrollLeft),{fitsAbove:we,aboveTop:me,aboveLeft:Je,fitsBelow:Re,belowTop:Be,belowLeft:st}}_layoutHorizontalSegmentInPage(e,i,r,_){const S=Math.max(0,i.left-_),z=Math.min(i.left+i.width+_,e.width);let ie=i.left+r-P.Yx.scrollX;if(ie+_>z){const re=ie-(z-_);ie-=re,r-=re}if(ie<S){const re=ie-S;ie-=re,r-=re}return[r,ie]}_layoutBoxInPage(e,i,r,_,S){const z=e.top-_,ie=i.top+this._lineHeight,re=P.BK(this._viewDomNode.domNode),le=re.top+z-P.Yx.scrollY,me=re.top+ie-P.Yx.scrollY,we=P.tG(document.body),[Be,Re]=this._layoutHorizontalSegmentInPage(we,re,e.left-S.scrollLeft+this._contentLeft,r),[Je,st]=this._layoutHorizontalSegmentInPage(we,re,i.left-S.scrollLeft+this._contentLeft,r),ct=22,mt=22,xt=le>=ct,Dt=me+_<=we.height-mt;return this._fixedOverflowWidgets?{fitsAbove:xt,aboveTop:Math.max(le,ct),aboveLeft:Re,fitsBelow:Dt,belowTop:me,belowLeft:st}:{fitsAbove:xt,aboveTop:z,aboveLeft:Be,fitsBelow:Dt,belowTop:ie,belowLeft:Je}}_prepareRenderWidgetAtExactPositionOverflowing(e){return new Zi(e.top,e.left+this._contentLeft)}_getTopAndBottomLeft(e){if(!this._viewRange)return[null,null];const i=e.linesVisibleRangesForRange(this._viewRange,!1);if(!i||i.length===0)return[null,null];let r=i[0],_=i[0];for(const we of i)we.lineNumber<r.lineNumber&&(r=we),we.lineNumber>_.lineNumber&&(_=we);let S=1073741824;for(const we of r.ranges)we.left<S&&(S=we.left);let z=1073741824;for(const we of _.ranges)we.left<z&&(z=we.left);const ie=e.getVerticalOffsetForLineNumber(r.lineNumber)-e.scrollTop,re=new Zi(ie,S),le=e.getVerticalOffsetForLineNumber(_.lineNumber)-e.scrollTop,me=new Zi(le,z);return[re,me]}_prepareRenderWidget(e){if(!this._preference||this._preference.length===0)return null;const[i,r]=this._getTopAndBottomLeft(e);if(!i||!r)return null;if(this._cachedDomNodeOffsetWidth===-1||this._cachedDomNodeOffsetHeight===-1){let S=null;if(typeof this._actual.beforeRender=="function"&&(S=Pi(this._actual.beforeRender,this._actual)),S)this._cachedDomNodeOffsetWidth=S.width,this._cachedDomNodeOffsetHeight=S.height;else{const ie=this.domNode.domNode.getBoundingClientRect();this._cachedDomNodeOffsetWidth=Math.round(ie.width),this._cachedDomNodeOffsetHeight=Math.round(ie.height)}}let _;this.allowEditorOverflow?_=this._layoutBoxInPage(i,r,this._cachedDomNodeOffsetWidth,this._cachedDomNodeOffsetHeight,e):_=this._layoutBoxInViewport(i,r,this._cachedDomNodeOffsetWidth,this._cachedDomNodeOffsetHeight,e);for(let S=1;S<=2;S++)for(const z of this._preference)if(z===1){if(!_)return null;if(S===2||_.fitsAbove)return{coordinate:new Zi(_.aboveTop,_.aboveLeft),position:1}}else if(z===2){if(!_)return null;if(S===2||_.fitsBelow)return{coordinate:new Zi(_.belowTop,_.belowLeft),position:2}}else return this.allowEditorOverflow?{coordinate:this._prepareRenderWidgetAtExactPositionOverflowing(i),position:0}:{coordinate:i,position:0};return null}onBeforeRender(e){!this._viewRange||!this._preference||this._viewRange.endLineNumber<e.startLineNumber||this._viewRange.startLineNumber>e.endLineNumber||this.domNode.setMaxWidth(this._maxWidth)}prepareRender(e){this._renderData=this._prepareRenderWidget(e)}render(e){if(!this._renderData){this._isVisible&&(this.domNode.removeAttribute("monaco-visible-content-widget"),this._isVisible=!1,this.domNode.setVisibility("hidden")),typeof this._actual.afterRender=="function"&&Pi(this._actual.afterRender,this._actual,null);return}this.allowEditorOverflow?(this.domNode.setTop(this._renderData.coordinate.top),this.domNode.setLeft(this._renderData.coordinate.left)):(this.domNode.setTop(this._renderData.coordinate.top+e.scrollTop-e.bigNumbersDelta),this.domNode.setLeft(this._renderData.coordinate.left)),this._isVisible||(this.domNode.setVisibility("inherit"),this.domNode.setAttribute("monaco-visible-content-widget","true"),this._isVisible=!0),typeof this._actual.afterRender=="function"&&Pi(this._actual.afterRender,this._actual,this._renderData.position)}}function Pi(Le,e,...i){try{return Le.call(e,...i)}catch{return null}}class fi extends At{constructor(e){super(),this._context=e;const i=this._context.configuration.options,r=i.get(133);this._lineHeight=i.get(61),this._renderLineHighlight=i.get(87),this._renderLineHighlightOnlyWhenFocus=i.get(88),this._contentLeft=r.contentLeft,this._contentWidth=r.contentWidth,this._selectionIsEmpty=!0,this._focused=!1,this._cursorLineNumbers=[1],this._selections=[new ue.L(1,1,1,1)],this._renderData=null,this._context.addEventHandler(this)}dispose(){this._context.removeEventHandler(this),super.dispose()}_readFromSelections(){let e=!1;const i=this._selections.map(_=>_.positionLineNumber);i.sort((_,S)=>_-S),h.aI(this._cursorLineNumbers,i)||(this._cursorLineNumbers=i,e=!0);const r=this._selections.every(_=>_.isEmpty());return this._selectionIsEmpty!==r&&(this._selectionIsEmpty=r,e=!0),e}onThemeChanged(e){return this._readFromSelections()}onConfigurationChanged(e){const i=this._context.configuration.options,r=i.get(133);return this._lineHeight=i.get(61),this._renderLineHighlight=i.get(87),this._renderLineHighlightOnlyWhenFocus=i.get(88),this._contentLeft=r.contentLeft,this._contentWidth=r.contentWidth,!0}onCursorStateChanged(e){return this._selections=e.selections,this._readFromSelections()}onFlushed(e){return!0}onLinesDeleted(e){return!0}onLinesInserted(e){return!0}onScrollChanged(e){return e.scrollWidthChanged||e.scrollTopChanged}onZonesChanged(e){return!0}onFocusChanged(e){return this._renderLineHighlightOnlyWhenFocus?(this._focused=e.isFocused,!0):!1}prepareRender(e){if(!this._shouldRenderThis()){this._renderData=null;return}const i=this._renderOne(e),r=e.visibleRange.startLineNumber,_=e.visibleRange.endLineNumber,S=this._cursorLineNumbers.length;let z=0;const ie=[];for(let re=r;re<=_;re++){const le=re-r;for(;z<S&&this._cursorLineNumbers[z]<re;)z++;z<S&&this._cursorLineNumbers[z]===re?ie[le]=i:ie[le]=""}this._renderData=ie}render(e,i){if(!this._renderData)return"";const r=i-e;return r>=this._renderData.length?"":this._renderData[r]}_shouldRenderInMargin(){return(this._renderLineHighlight==="gutter"||this._renderLineHighlight==="all")&&(!this._renderLineHighlightOnlyWhenFocus||this._focused)}_shouldRenderInContent(){return(this._renderLineHighlight==="line"||this._renderLineHighlight==="all")&&this._selectionIsEmpty&&(!this._renderLineHighlightOnlyWhenFocus||this._focused)}}class Sn extends fi{_renderOne(e){return`<div class="${"current-line"+(this._shouldRenderOther()?" current-line-both":"")}" style="width:${Math.max(e.scrollWidth,this._contentWidth)}px; height:${this._lineHeight}px;"></div>`}_shouldRenderThis(){return this._shouldRenderInContent()}_shouldRenderOther(){return this._shouldRenderInMargin()}}class cn extends fi{_renderOne(e){return`<div class="${"current-line"+(this._shouldRenderInMargin()?" current-line-margin":"")+(this._shouldRenderOther()?" current-line-margin-both":"")}" style="width:${this._contentLeft}px; height:${this._lineHeight}px;"></div>`}_shouldRenderThis(){return!0}_shouldRenderOther(){return this._shouldRenderInContent()}}(0,kt.zy)((Le,e)=>{const i=Le.getColor(wt.kG);if(i&&(e.addRule(`.monaco-editor .view-overlays .current-line { background-color: ${i}; }`),e.addRule(`.monaco-editor .margin-view-overlays .current-line-margin { background-color: ${i}; border: none; }`)),!i||i.isTransparent()||Le.defines(wt.Mf)){const r=Le.getColor(wt.Mf);r&&(e.addRule(`.monaco-editor .view-overlays .current-line { border: 2px solid ${r}; }`),e.addRule(`.monaco-editor .margin-view-overlays .current-line-margin { border: 2px solid ${r}; }`),(0,Wt.Bb)(Le.type)&&(e.addRule(".monaco-editor .view-overlays .current-line { border-width: 1px; }"),e.addRule(".monaco-editor .margin-view-overlays .current-line-margin { border-width: 1px; }")))}});class en extends At{constructor(e){super(),this._context=e;const i=this._context.configuration.options;this._lineHeight=i.get(61),this._typicalHalfwidthCharacterWidth=i.get(46).typicalHalfwidthCharacterWidth,this._renderResult=null,this._context.addEventHandler(this)}dispose(){this._context.removeEventHandler(this),this._renderResult=null,super.dispose()}onConfigurationChanged(e){const i=this._context.configuration.options;return this._lineHeight=i.get(61),this._typicalHalfwidthCharacterWidth=i.get(46).typicalHalfwidthCharacterWidth,!0}onDecorationsChanged(e){return!0}onFlushed(e){return!0}onLinesChanged(e){return!0}onLinesDeleted(e){return!0}onLinesInserted(e){return!0}onScrollChanged(e){return e.scrollTopChanged||e.scrollWidthChanged}onZonesChanged(e){return!0}prepareRender(e){const i=e.getDecorationsInViewport();let r=[],_=0;for(let re=0,le=i.length;re<le;re++){const me=i[re];me.options.className&&(r[_++]=me)}r=r.sort((re,le)=>{if(re.options.zIndex<le.options.zIndex)return-1;if(re.options.zIndex>le.options.zIndex)return 1;const me=re.options.className,we=le.options.className;return me<we?-1:me>we?1:Pt.Q.compareRangesUsingStarts(re.range,le.range)});const S=e.visibleRange.startLineNumber,z=e.visibleRange.endLineNumber,ie=[];for(let re=S;re<=z;re++){const le=re-S;ie[le]=""}this._renderWholeLineDecorations(e,r,ie),this._renderNormalDecorations(e,r,ie),this._renderResult=ie}_renderWholeLineDecorations(e,i,r){const _=String(this._lineHeight),S=e.visibleRange.startLineNumber,z=e.visibleRange.endLineNumber;for(let ie=0,re=i.length;ie<re;ie++){const le=i[ie];if(!le.options.isWholeLine)continue;const me='<div class="cdr '+le.options.className+'" style="left:0;width:100%;height:'+_+'px;"></div>',we=Math.max(le.range.startLineNumber,S),Be=Math.min(le.range.endLineNumber,z);for(let Re=we;Re<=Be;Re++){const Je=Re-S;r[Je]+=me}}}_renderNormalDecorations(e,i,r){const _=String(this._lineHeight),S=e.visibleRange.startLineNumber;let z=null,ie=!1,re=null;for(let le=0,me=i.length;le<me;le++){const we=i[le];if(we.options.isWholeLine)continue;const Be=we.options.className,Re=!!we.options.showIfCollapsed;let Je=we.range;if(Re&&Je.endColumn===1&&Je.endLineNumber!==Je.startLineNumber&&(Je=new Pt.Q(Je.startLineNumber,Je.startColumn,Je.endLineNumber-1,this._context.viewModel.getLineMaxColumn(Je.endLineNumber-1))),z===Be&&ie===Re&&Pt.Q.areIntersectingOrTouching(re,Je)){re=Pt.Q.plusRange(re,Je);continue}z!==null&&this._renderNormalDecoration(e,re,z,ie,_,S,r),z=Be,ie=Re,re=Je}z!==null&&this._renderNormalDecoration(e,re,z,ie,_,S,r)}_renderNormalDecoration(e,i,r,_,S,z,ie){const re=e.linesVisibleRangesForRange(i,r==="findMatch");if(re)for(let le=0,me=re.length;le<me;le++){const we=re[le];if(we.outsideRenderedLine)continue;const Be=we.lineNumber-z;if(_&&we.ranges.length===1){const Re=we.ranges[0];if(Re.width<this._typicalHalfwidthCharacterWidth){const Je=Math.round(Re.left+Re.width/2),st=Math.max(0,Math.round(Je-this._typicalHalfwidthCharacterWidth/2));we.ranges[0]=new Ge(st,this._typicalHalfwidthCharacterWidth)}}for(let Re=0,Je=we.ranges.length;Re<Je;Re++){const st=we.ranges[Re],ct='<div class="cdr '+r+'" style="left:'+String(st.left)+"px;width:"+String(st.width)+"px;height:"+S+'px;"></div>';ie[Be]+=ct}}}render(e,i){if(!this._renderResult)return"";const r=i-e;return r<0||r>=this._renderResult.length?"":this._renderResult[r]}}var dn=y(63781),Li=y(4874);class Rn extends pe{constructor(e,i,r,_){super(e);const S=this._context.configuration.options,z=S.get(94),ie=S.get(69),re=S.get(36),le=S.get(97),me={listenOnDomNode:r.domNode,className:"editor-scrollable "+(0,kt.Pz)(e.theme.type),useShadows:!1,lazyRender:!0,vertical:z.vertical,horizontal:z.horizontal,verticalHasArrows:z.verticalHasArrows,horizontalHasArrows:z.horizontalHasArrows,verticalScrollbarSize:z.verticalScrollbarSize,verticalSliderSize:z.verticalSliderSize,horizontalScrollbarSize:z.horizontalScrollbarSize,horizontalSliderSize:z.horizontalSliderSize,handleMouseWheel:z.handleMouseWheel,alwaysConsumeMouseWheel:z.alwaysConsumeMouseWheel,arrowSize:z.arrowSize,mouseWheelScrollSensitivity:ie,fastScrollSensitivity:re,scrollPredominantAxis:le,scrollByPage:z.scrollByPage};this.scrollbar=this._register(new dn.oO(i.domNode,me,this._context.viewLayout.getScrollable())),be.write(this.scrollbar.getDomNode(),5),this.scrollbarDomNode=(0,E.Z)(this.scrollbar.getDomNode()),this.scrollbarDomNode.setPosition("absolute"),this._setLayout();const we=(Be,Re,Je)=>{const st={};if(Re){const ct=Be.scrollTop;ct&&(st.scrollTop=this._context.viewLayout.getCurrentScrollTop()+ct,Be.scrollTop=0)}if(Je){const ct=Be.scrollLeft;ct&&(st.scrollLeft=this._context.viewLayout.getCurrentScrollLeft()+ct,Be.scrollLeft=0)}this._context.viewModel.viewLayout.setScrollPosition(st,1)};this._register(P.ko(r.domNode,"scroll",Be=>we(r.domNode,!0,!0))),this._register(P.ko(i.domNode,"scroll",Be=>we(i.domNode,!0,!1))),this._register(P.ko(_.domNode,"scroll",Be=>we(_.domNode,!0,!1))),this._register(P.ko(this.scrollbarDomNode.domNode,"scroll",Be=>we(this.scrollbarDomNode.domNode,!0,!1)))}dispose(){super.dispose()}_setLayout(){const e=this._context.configuration.options,i=e.get(133);this.scrollbarDomNode.setLeft(i.contentLeft),e.get(67).side==="right"?this.scrollbarDomNode.setWidth(i.contentWidth+i.minimap.minimapWidth):this.scrollbarDomNode.setWidth(i.contentWidth),this.scrollbarDomNode.setHeight(i.height)}getOverviewRulerLayoutInfo(){return this.scrollbar.getOverviewRulerLayoutInfo()}getDomNode(){return this.scrollbarDomNode}delegateVerticalScrollbarPointerDown(e){this.scrollbar.delegateVerticalScrollbarPointerDown(e)}onConfigurationChanged(e){if(e.hasChanged(94)||e.hasChanged(69)||e.hasChanged(36)){const i=this._context.configuration.options,r=i.get(94),_=i.get(69),S=i.get(36),z=i.get(97),ie={vertical:r.vertical,horizontal:r.horizontal,verticalScrollbarSize:r.verticalScrollbarSize,horizontalScrollbarSize:r.horizontalScrollbarSize,scrollByPage:r.scrollByPage,handleMouseWheel:r.handleMouseWheel,mouseWheelScrollSensitivity:_,fastScrollSensitivity:S,scrollPredominantAxis:z};this.scrollbar.updateOptions(ie)}return e.hasChanged(133)&&this._setLayout(),!0}onScrollChanged(e){return!0}onThemeChanged(e){return this.scrollbar.updateClassName("editor-scrollable "+(0,kt.Pz)(this._context.theme.type)),!0}prepareRender(e){}render(e){this.scrollbar.renderNow()}}(0,kt.zy)((Le,e)=>{const i=Le.getColor(Li.bXl);i&&e.addRule(` .monaco-scrollable-element > .shadow.top { box-shadow: ${i} 0 6px 6px -6px inset; } .monaco-scrollable-element > .shadow.left { box-shadow: ${i} 6px 0 6px -6px inset; } .monaco-scrollable-element > .shadow.top.left { box-shadow: ${i} 6px 6px 6px -6px inset; } `);const r=Le.getColor(Li.gnV);r&&e.addRule(` .monaco-scrollable-element > .scrollbar > .slider { background: ${r}; } `);const _=Le.getColor(Li.cI_);_&&e.addRule(` .monaco-scrollable-element > .scrollbar > .slider:hover { background: ${_}; } `);const S=Le.getColor(Li.mhZ);S&&e.addRule(` .monaco-scrollable-element > .scrollbar > .slider.active { background: ${S}; } `)});class In{constructor(e,i,r){this._decorationToRenderBrand=void 0,this.startLineNumber=+e,this.endLineNumber=+i,this.className=String(r)}}class xn extends At{_render(e,i,r){const _=[];for(let ie=e;ie<=i;ie++){const re=ie-e;_[re]=[]}if(r.length===0)return _;r.sort((ie,re)=>ie.className===re.className?ie.startLineNumber===re.startLineNumber?ie.endLineNumber-re.endLineNumber:ie.startLineNumber-re.startLineNumber:ie.className<re.className?-1:1);let S=null,z=0;for(let ie=0,re=r.length;ie<re;ie++){const le=r[ie],me=le.className;let we=Math.max(le.startLineNumber,e)-e;const Be=Math.min(le.endLineNumber,i)-e;S===me?(we=Math.max(z+1,we),z=Math.max(z,Be)):(S=me,z=Be);for(let Re=we;Re<=z;Re++)_[Re].push(S)}return _}}class Tn extends xn{constructor(e){super(),this._context=e;const i=this._context.configuration.options,r=i.get(133);this._lineHeight=i.get(61),this._glyphMargin=i.get(52),this._glyphMarginLeft=r.glyphMarginLeft,this._glyphMarginWidth=r.glyphMarginWidth,this._renderResult=null,this._context.addEventHandler(this)}dispose(){this._context.removeEventHandler(this),this._renderResult=null,super.dispose()}onConfigurationChanged(e){const i=this._context.configuration.options,r=i.get(133);return this._lineHeight=i.get(61),this._glyphMargin=i.get(52),this._glyphMarginLeft=r.glyphMarginLeft,this._glyphMarginWidth=r.glyphMarginWidth,!0}onDecorationsChanged(e){return!0}onFlushed(e){return!0}onLinesChanged(e){return!0}onLinesDeleted(e){return!0}onLinesInserted(e){return!0}onScrollChanged(e){return e.scrollTopChanged}onZonesChanged(e){return!0}_getDecorations(e){const i=e.getDecorationsInViewport(),r=[];let _=0;for(let S=0,z=i.length;S<z;S++){const ie=i[S],re=ie.options.glyphMarginClassName;re&&(r[_++]=new In(ie.range.startLineNumber,ie.range.endLineNumber,re))}return r}prepareRender(e){if(!this._glyphMargin){this._renderResult=null;return}const i=e.visibleRange.startLineNumber,r=e.visibleRange.endLineNumber,_=this._render(i,r,this._getDecorations(e)),S=this._lineHeight.toString(),z=this._glyphMarginLeft.toString(),ie=this._glyphMarginWidth.toString(),re='" style="left:'+z+"px;width:"+ie+"px;height:"+S+'px;"></div>',le=[];for(let me=i;me<=r;me++){const we=me-i,Be=_[we];Be.length===0?le[we]="":le[we]='<div class="cgmr codicon '+Be.join(" ")+re}this._renderResult=le}render(e,i){if(!this._renderResult)return"";const r=i-e;return r<0||r>=this._renderResult.length?"":this._renderResult[r]}}var wn=y(79359),Ln=y(52818),Cn=y(60779);class Bn extends At{constructor(e){super(),this._context=e,this._primaryPosition=null;const i=this._context.configuration.options,r=i.get(134),_=i.get(46);this._lineHeight=i.get(61),this._spaceWidth=_.spaceWidth,this._maxIndentLeft=r.wrappingColumn===-1?-1:r.wrappingColumn*_.typicalHalfwidthCharacterWidth,this._bracketPairGuideOptions=i.get(13),this._renderResult=null,this._context.addEventHandler(this)}dispose(){this._context.removeEventHandler(this),this._renderResult=null,super.dispose()}onConfigurationChanged(e){const i=this._context.configuration.options,r=i.get(134),_=i.get(46);return this._lineHeight=i.get(61),this._spaceWidth=_.spaceWidth,this._maxIndentLeft=r.wrappingColumn===-1?-1:r.wrappingColumn*_.typicalHalfwidthCharacterWidth,this._bracketPairGuideOptions=i.get(13),!0}onCursorStateChanged(e){var i;const _=e.selections[0].getPosition();return!((i=this._primaryPosition)===null||i===void 0)&&i.equals(_)?!1:(this._primaryPosition=_,!0)}onDecorationsChanged(e){return!0}onFlushed(e){return!0}onLinesChanged(e){return!0}onLinesDeleted(e){return!0}onLinesInserted(e){return!0}onScrollChanged(e){return e.scrollTopChanged}onZonesChanged(e){return!0}onLanguageConfigurationChanged(e){return!0}prepareRender(e){var i,r,_,S;if(!this._bracketPairGuideOptions.indentation&&this._bracketPairGuideOptions.bracketPairs===!1){this._renderResult=null;return}const z=e.visibleRange.startLineNumber,ie=e.visibleRange.endLineNumber,re=e.scrollWidth,le=this._lineHeight,me=this._primaryPosition,we=this.getGuidesByLine(z,ie,me),Be=[];for(let Re=z;Re<=ie;Re++){const Je=Re-z,st=we[Je];let ct="";const mt=(r=(i=e.visibleRangeForPosition(new Nt.y(Re,1)))===null||i===void 0?void 0:i.left)!==null&&r!==void 0?r:0;for(const xt of st){const Dt=xt.column===-1?mt+(xt.visibleColumn-1)*this._spaceWidth:e.visibleRangeForPosition(new Nt.y(Re,xt.column)).left;if(Dt>re||this._maxIndentLeft>0&&Dt>this._maxIndentLeft)break;const Jt=xt.horizontalLine?xt.horizontalLine.top?"horizontal-top":"horizontal-bottom":"vertical",$t=xt.horizontalLine?((S=(_=e.visibleRangeForPosition(new Nt.y(Re,xt.horizontalLine.endColumn)))===null||_===void 0?void 0:_.left)!==null&&S!==void 0?S:Dt+this._spaceWidth)-Dt:this._spaceWidth;ct+=`<div class="core-guide ${xt.className} ${Jt}" style="left:${Dt}px;height:${le}px;width:${$t}px"></div>`}Be[Je]=ct}this._renderResult=Be}getGuidesByLine(e,i,r){const _=this._bracketPairGuideOptions.bracketPairs!==!1?this._context.viewModel.getBracketGuidesInRangeByLine(e,i,r,{highlightActive:this._bracketPairGuideOptions.highlightActiveBracketPair,horizontalGuides:this._bracketPairGuideOptions.bracketPairsHorizontal===!0?Cn.N6.Enabled:this._bracketPairGuideOptions.bracketPairsHorizontal==="active"?Cn.N6.EnabledForActive:Cn.N6.Disabled,includeInactive:this._bracketPairGuideOptions.bracketPairs===!0}):null,S=this._bracketPairGuideOptions.indentation?this._context.viewModel.getLinesIndentGuides(e,i):null;let z=0,ie=0,re=0;if(this._bracketPairGuideOptions.highlightActiveIndentation!==!1&&r){const we=this._context.viewModel.getActiveIndentGuide(r.lineNumber,e,i);z=we.startLineNumber,ie=we.endLineNumber,re=we.indent}const{indentSize:le}=this._context.viewModel.model.getOptions(),me=[];for(let we=e;we<=i;we++){const Be=new Array;me.push(Be);const Re=_?_[we-e]:[],Je=new h.j3(Re),st=S?S[we-e]:[];for(let ct=1;ct<=st;ct++){const mt=(ct-1)*le+1,xt=(this._bracketPairGuideOptions.highlightActiveIndentation==="always"||Re.length===0)&&z<=we&&we<=ie&&ct===re;Be.push(...Je.takeWhile(Jt=>Jt.visibleColumn<mt)||[]);const Dt=Je.peek();(!Dt||Dt.visibleColumn!==mt||Dt.horizontalLine)&&Be.push(new Cn.TH(mt,-1,xt?"core-guide-indent-active":"core-guide-indent",null,-1,-1))}Be.push(...Je.takeWhile(ct=>!0)||[])}return me}render(e,i){if(!this._renderResult)return"";const r=i-e;return r<0||r>=this._renderResult.length?"":this._renderResult[r]}}function Mn(Le){if(!(Le&&Le.isTransparent()))return Le}(0,kt.zy)((Le,e)=>{const i=Le.getColor(wt.v0);i&&e.addRule(`.monaco-editor .lines-content .core-guide-indent { box-shadow: 1px 0 0 0 ${i} inset; }`);const r=Le.getColor(wt.fj)||i;r&&e.addRule(`.monaco-editor .lines-content .core-guide-indent-active { box-shadow: 1px 0 0 0 ${r} inset; }`);const _=[{bracketColor:wt.sN,guideColor:wt.n4,guideColorActive:wt.bB},{bracketColor:wt.lQ,guideColor:wt.I2,guideColorActive:wt.WS},{bracketColor:wt.ss,guideColor:wt.Bo,guideColorActive:wt.Pe},{bracketColor:wt.l5,guideColor:wt.If,guideColorActive:wt.WD},{bracketColor:wt.sH,guideColor:wt.BD,guideColorActive:wt.P1},{bracketColor:wt.zp,guideColor:wt.IW,guideColorActive:wt.WY}],S=new Ln.k,z=_.map(ie=>{var re,le;const me=Le.getColor(ie.bracketColor),we=Le.getColor(ie.guideColor),Be=Le.getColor(ie.guideColorActive),Re=Mn((re=Mn(we))!==null&&re!==void 0?re:me?.transparent(.3)),Je=Mn((le=Mn(Be))!==null&&le!==void 0?le:me);if(!(!Re||!Je))return{guideColor:Re,guideColorActive:Je}}).filter(wn.O9);if(z.length>0){for(let ie=0;ie<30;ie++){const re=z[ie%z.length];e.addRule(`.monaco-editor .${S.getInlineClassNameOfLevel(ie).replace(/ /g,".")} { --guide-color: ${re.guideColor}; --guide-color-active: ${re.guideColorActive}; }`)}e.addRule(".monaco-editor .vertical { box-shadow: 1px 0 0 0 var(--guide-color) inset; }"),e.addRule(".monaco-editor .horizontal-top { border-top: 1px solid var(--guide-color); }"),e.addRule(".monaco-editor .horizontal-bottom { border-bottom: 1px solid var(--guide-color); }"),e.addRule(`.monaco-editor .vertical.${S.activeClassName} { box-shadow: 1px 0 0 0 var(--guide-color-active) inset; }`),e.addRule(`.monaco-editor .horizontal-top.${S.activeClassName} { border-top: 1px solid var(--guide-color-active); }`),e.addRule(`.monaco-editor .horizontal-bottom.${S.activeClassName} { border-bottom: 1px solid var(--guide-color-active); }`)}});class Yn{constructor(){this._currentVisibleRange=new Pt.Q(1,1,1,1)}getCurrentVisibleRange(){return this._currentVisibleRange}setCurrentVisibleRange(e){this._currentVisibleRange=e}}class Hn{constructor(e,i,r,_,S,z,ie){this.minimalReveal=e,this.lineNumber=i,this.startColumn=r,this.endColumn=_,this.startScrollTop=S,this.stopScrollTop=z,this.scrollType=ie,this.type="range",this.minLineNumber=i,this.maxLineNumber=i}}class _n{constructor(e,i,r,_,S){this.minimalReveal=e,this.selections=i,this.startScrollTop=r,this.stopScrollTop=_,this.scrollType=S,this.type="selections";let z=i[0].startLineNumber,ie=i[0].endLineNumber;for(let re=1,le=i.length;re<le;re++){const me=i[re];z=Math.min(z,me.startLineNumber),ie=Math.max(ie,me.endLineNumber)}this.minLineNumber=z,this.maxLineNumber=ie}}class yn extends pe{constructor(e,i){super(e),this._linesContent=i,this._textRangeRestingSpot=document.createElement("div"),this._visibleLines=new Fi(this),this.domNode=this._visibleLines.domNode;const r=this._context.configuration,_=this._context.configuration.options,S=_.get(46),z=_.get(134),ie=_.get(133);this._lineHeight=_.get(61),this._typicalHalfwidthCharacterWidth=S.typicalHalfwidthCharacterWidth,this._isViewportWrapping=z.isViewportWrapping,this._revealHorizontalRightPadding=_.get(91),this._horizontalScrollbarHeight=ie.horizontalScrollbarHeight,this._cursorSurroundingLines=_.get(25),this._cursorSurroundingLinesStyle=_.get(26),this._canUseLayerHinting=!_.get(28),this._viewLineOptions=new Lt(r,this._context.theme.type),be.write(this.domNode,7),this.domNode.setClassName(`view-lines ${Ut.S}`),(0,vt.M)(this.domNode,S),this._maxLineWidth=0,this._asyncUpdateLineWidths=new Se.uC(()=>{this._updateLineWidthsSlow()},200),this._asyncCheckMonospaceFontAssumptions=new Se.uC(()=>{this._checkMonospaceFontAssumptions()},2e3),this._lastRenderedData=new Yn,this._horizontalRevealRequest=null}dispose(){this._asyncUpdateLineWidths.dispose(),this._asyncCheckMonospaceFontAssumptions.dispose(),super.dispose()}getDomNode(){return this.domNode}createVisibleLine(){return new Rt(this._viewLineOptions)}onConfigurationChanged(e){this._visibleLines.onConfigurationChanged(e),e.hasChanged(134)&&(this._maxLineWidth=0);const i=this._context.configuration.options,r=i.get(46),_=i.get(134),S=i.get(133);return this._lineHeight=i.get(61),this._typicalHalfwidthCharacterWidth=r.typicalHalfwidthCharacterWidth,this._isViewportWrapping=_.isViewportWrapping,this._revealHorizontalRightPadding=i.get(91),this._horizontalScrollbarHeight=S.horizontalScrollbarHeight,this._cursorSurroundingLines=i.get(25),this._cursorSurroundingLinesStyle=i.get(26),this._canUseLayerHinting=!i.get(28),(0,vt.M)(this.domNode,r),this._onOptionsMaybeChanged(),e.hasChanged(133)&&(this._maxLineWidth=0),!0}_onOptionsMaybeChanged(){const e=this._context.configuration,i=new Lt(e,this._context.theme.type);if(!this._viewLineOptions.equals(i)){this._viewLineOptions=i;const r=this._visibleLines.getStartLineNumber(),_=this._visibleLines.getEndLineNumber();for(let S=r;S<=_;S++)this._visibleLines.getVisibleLine(S).onOptionsChanged(this._viewLineOptions);return!0}return!1}onCursorStateChanged(e){const i=this._visibleLines.getStartLineNumber(),r=this._visibleLines.getEndLineNumber();let _=!1;for(let S=i;S<=r;S++)_=this._visibleLines.getVisibleLine(S).onSelectionChanged()||_;return _}onDecorationsChanged(e){{const i=this._visibleLines.getStartLineNumber(),r=this._visibleLines.getEndLineNumber();for(let _=i;_<=r;_++)this._visibleLines.getVisibleLine(_).onDecorationsChanged()}return!0}onFlushed(e){const i=this._visibleLines.onFlushed(e);return this._maxLineWidth=0,i}onLinesChanged(e){return this._visibleLines.onLinesChanged(e)}onLinesDeleted(e){return this._visibleLines.onLinesDeleted(e)}onLinesInserted(e){return this._visibleLines.onLinesInserted(e)}onRevealRangeRequest(e){const i=this._computeScrollTopToRevealRange(this._context.viewLayout.getFutureViewport(),e.source,e.minimalReveal,e.range,e.selections,e.verticalType);if(i===-1)return!1;let r=this._context.viewLayout.validateScrollPosition({scrollTop:i});e.revealHorizontal?e.range&&e.range.startLineNumber!==e.range.endLineNumber?r={scrollTop:r.scrollTop,scrollLeft:0}:e.range?this._horizontalRevealRequest=new Hn(e.minimalReveal,e.range.startLineNumber,e.range.startColumn,e.range.endColumn,this._context.viewLayout.getCurrentScrollTop(),r.scrollTop,e.scrollType):e.selections&&e.selections.length>0&&(this._horizontalRevealRequest=new _n(e.minimalReveal,e.selections,this._context.viewLayout.getCurrentScrollTop(),r.scrollTop,e.scrollType)):this._horizontalRevealRequest=null;const S=Math.abs(this._context.viewLayout.getCurrentScrollTop()-r.scrollTop)<=this._lineHeight?1:e.scrollType;return this._context.viewModel.viewLayout.setScrollPosition(r,S),!0}onScrollChanged(e){if(this._horizontalRevealRequest&&e.scrollLeftChanged&&(this._horizontalRevealRequest=null),this._horizontalRevealRequest&&e.scrollTopChanged){const i=Math.min(this._horizontalRevealRequest.startScrollTop,this._horizontalRevealRequest.stopScrollTop),r=Math.max(this._horizontalRevealRequest.startScrollTop,this._horizontalRevealRequest.stopScrollTop);(e.scrollTop<i||e.scrollTop>r)&&(this._horizontalRevealRequest=null)}return this.domNode.setWidth(e.scrollWidth),this._visibleLines.onScrollChanged(e)||!0}onTokensChanged(e){return this._visibleLines.onTokensChanged(e)}onZonesChanged(e){return this._context.viewModel.viewLayout.setMaxLineWidth(this._maxLineWidth),this._visibleLines.onZonesChanged(e)}onThemeChanged(e){return this._onOptionsMaybeChanged()}getPositionFromDOMInfo(e,i){const r=this._getViewLineDomNode(e);if(r===null)return null;const _=this._getLineNumberFor(r);if(_===-1||_<1||_>this._context.viewModel.getLineCount())return null;if(this._context.viewModel.getLineMaxColumn(_)===1)return new Nt.y(_,1);const S=this._visibleLines.getStartLineNumber(),z=this._visibleLines.getEndLineNumber();if(_<S||_>z)return null;let ie=this._visibleLines.getVisibleLine(_).getColumnOfNodeOffset(_,e,i);const re=this._context.viewModel.getLineMinColumn(_);return ie<re&&(ie=re),new Nt.y(_,ie)}_getViewLineDomNode(e){for(;e&&e.nodeType===1;){if(e.className===Rt.CLASS_NAME)return e;e=e.parentElement}return null}_getLineNumberFor(e){const i=this._visibleLines.getStartLineNumber(),r=this._visibleLines.getEndLineNumber();for(let _=i;_<=r;_++){const S=this._visibleLines.getVisibleLine(_);if(e===S.getDomNode())return _}return-1}getLineWidth(e){const i=this._visibleLines.getStartLineNumber(),r=this._visibleLines.getEndLineNumber();return e<i||e>r?-1:this._visibleLines.getVisibleLine(e).getWidth()}linesVisibleRangesForRange(e,i){if(this.shouldRender())return null;const r=e.endLineNumber,_=Pt.Q.intersectRanges(e,this._lastRenderedData.getCurrentVisibleRange());if(!_)return null;const S=[];let z=0;const ie=new ht(this.domNode.domNode,this._textRangeRestingSpot);let re=0;i&&(re=this._context.viewModel.coordinatesConverter.convertViewPositionToModelPosition(new Nt.y(_.startLineNumber,1)).lineNumber);const le=this._visibleLines.getStartLineNumber(),me=this._visibleLines.getEndLineNumber();for(let we=_.startLineNumber;we<=_.endLineNumber;we++){if(we<le||we>me)continue;const Be=we===_.startLineNumber?_.startColumn:1,Re=we===_.endLineNumber?_.endColumn:this._context.viewModel.getLineMaxColumn(we),Je=this._visibleLines.getVisibleLine(we).getVisibleRangesForRange(we,Be,Re,ie);if(Je){if(i&&we<r){const st=re;re=this._context.viewModel.coordinatesConverter.convertViewPositionToModelPosition(new Nt.y(we+1,1)).lineNumber,st!==re&&(Je.ranges[Je.ranges.length-1].width+=this._typicalHalfwidthCharacterWidth)}S[z++]=new We(Je.outsideRenderedLine,we,Ge.from(Je.ranges))}}return z===0?null:S}_visibleRangesForLineRange(e,i,r){return this.shouldRender()||e<this._visibleLines.getStartLineNumber()||e>this._visibleLines.getEndLineNumber()?null:this._visibleLines.getVisibleLine(e).getVisibleRangesForRange(e,i,r,new ht(this.domNode.domNode,this._textRangeRestingSpot))}visibleRangeForPosition(e){const i=this._visibleRangesForLineRange(e.lineNumber,e.column,e.column);return i?new he(i.outsideRenderedLine,i.ranges[0].left):null}updateLineWidths(){this._updateLineWidths(!1)}_updateLineWidthsFast(){return this._updateLineWidths(!0)}_updateLineWidthsSlow(){this._updateLineWidths(!1)}_updateLineWidths(e){const i=this._visibleLines.getStartLineNumber(),r=this._visibleLines.getEndLineNumber();let _=1,S=!0;for(let z=i;z<=r;z++){const ie=this._visibleLines.getVisibleLine(z);if(e&&!ie.getWidthIsFast()){S=!1;continue}_=Math.max(_,ie.getWidth())}return S&&i===1&&r===this._context.viewModel.getLineCount()&&(this._maxLineWidth=0),this._ensureMaxLineWidth(_),S}_checkMonospaceFontAssumptions(){let e=-1,i=-1;const r=this._visibleLines.getStartLineNumber(),_=this._visibleLines.getEndLineNumber();for(let S=r;S<=_;S++){const z=this._visibleLines.getVisibleLine(S);if(z.needsMonospaceFontCheck()){const ie=z.getWidth();ie>i&&(i=ie,e=S)}}if(e!==-1&&!this._visibleLines.getVisibleLine(e).monospaceAssumptionsAreValid())for(let S=r;S<=_;S++)this._visibleLines.getVisibleLine(S).onMonospaceAssumptionsInvalidated()}prepareRender(){throw new Error("Not supported")}render(){throw new Error("Not supported")}renderText(e){if(this._visibleLines.renderLines(e),this._lastRenderedData.setCurrentVisibleRange(e.visibleRange),this.domNode.setWidth(this._context.viewLayout.getScrollWidth()),this.domNode.setHeight(Math.min(this._context.viewLayout.getScrollHeight(),1e6)),this._horizontalRevealRequest){const r=this._horizontalRevealRequest;if(e.startLineNumber<=r.minLineNumber&&r.maxLineNumber<=e.endLineNumber){this._horizontalRevealRequest=null,this.onDidRender();const _=this._computeScrollLeftToReveal(r);_&&(this._isViewportWrapping||this._ensureMaxLineWidth(_.maxHorizontalOffset),this._context.viewModel.viewLayout.setScrollPosition({scrollLeft:_.scrollLeft},r.scrollType))}}if(this._updateLineWidthsFast()||this._asyncUpdateLineWidths.schedule(),u.j9&&!this._asyncCheckMonospaceFontAssumptions.isScheduled()){const r=this._visibleLines.getStartLineNumber(),_=this._visibleLines.getEndLineNumber();for(let S=r;S<=_;S++)if(this._visibleLines.getVisibleLine(S).needsMonospaceFontCheck()){this._asyncCheckMonospaceFontAssumptions.schedule();break}}this._linesContent.setLayerHinting(this._canUseLayerHinting),this._linesContent.setContain("strict");const i=this._context.viewLayout.getCurrentScrollTop()-e.bigNumbersDelta;this._linesContent.setTop(-i),this._linesContent.setLeft(-this._context.viewLayout.getCurrentScrollLeft())}_ensureMaxLineWidth(e){const i=Math.ceil(e);this._maxLineWidth<i&&(this._maxLineWidth=i,this._context.viewModel.viewLayout.setMaxLineWidth(this._maxLineWidth))}_computeScrollTopToRevealRange(e,i,r,_,S,z){const ie=e.top,re=e.height,le=ie+re;let me,we,Be;if(S&&S.length>0){let st=S[0].startLineNumber,ct=S[0].endLineNumber;for(let mt=1,xt=S.length;mt<xt;mt++){const Dt=S[mt];st=Math.min(st,Dt.startLineNumber),ct=Math.max(ct,Dt.endLineNumber)}me=!1,we=this._context.viewLayout.getVerticalOffsetForLineNumber(st),Be=this._context.viewLayout.getVerticalOffsetForLineNumber(ct)+this._lineHeight}else if(_)me=!0,we=this._context.viewLayout.getVerticalOffsetForLineNumber(_.startLineNumber),Be=this._context.viewLayout.getVerticalOffsetForLineNumber(_.endLineNumber)+this._lineHeight;else return-1;if((i==="mouse"||r)&&this._cursorSurroundingLinesStyle==="default")r||(we-=this._lineHeight);else{const st=Math.min(re/this._lineHeight/2,this._cursorSurroundingLines);we-=st*this._lineHeight,Be+=Math.max(0,st-1)*this._lineHeight}(z===0||z===4)&&(Be+=r?this._horizontalScrollbarHeight:this._lineHeight);let Je;if(Be-we>re){if(!me)return-1;Je=we}else if(z===5||z===6)if(z===6&&ie<=we&&Be<=le)Je=ie;else{const st=Math.max(5*this._lineHeight,re*.2),ct=we-st,mt=Be-re;Je=Math.max(mt,ct)}else if(z===1||z===2)if(z===2&&ie<=we&&Be<=le)Je=ie;else{const st=(we+Be)/2;Je=Math.max(0,st-re/2)}else Je=this._computeMinimumScrolling(ie,le,we,Be,z===3,z===4);return Je}_computeScrollLeftToReveal(e){const i=this._context.viewLayout.getCurrentViewport(),r=i.left,_=r+i.width;let S=1073741824,z=0;if(e.type==="range"){const re=this._visibleRangesForLineRange(e.lineNumber,e.startColumn,e.endColumn);if(!re)return null;for(const le of re.ranges)S=Math.min(S,Math.round(le.left)),z=Math.max(z,Math.round(le.left+le.width))}else for(const re of e.selections){if(re.startLineNumber!==re.endLineNumber)return null;const le=this._visibleRangesForLineRange(re.startLineNumber,re.startColumn,re.endColumn);if(!le)return null;for(const me of le.ranges)S=Math.min(S,Math.round(me.left)),z=Math.max(z,Math.round(me.left+me.width))}return e.minimalReveal||(S=Math.max(0,S-yn.HORIZONTAL_EXTRA_PX),z+=this._revealHorizontalRightPadding),e.type==="selections"&&z-S>i.width?null:{scrollLeft:this._computeMinimumScrolling(r,_,S,z),maxHorizontalOffset:z}}_computeMinimumScrolling(e,i,r,_,S,z){e=e|0,i=i|0,r=r|0,_=_|0,S=!!S,z=!!z;const ie=i-e;if(_-r<ie){if(S)return r;if(z)return Math.max(0,_-ie);if(r<e)return r;if(_>i)return Math.max(0,_-ie)}else return r;return e}}yn.HORIZONTAL_EXTRA_PX=30;class On extends xn{constructor(e){super(),this._context=e;const r=this._context.configuration.options.get(133);this._decorationsLeft=r.decorationsLeft,this._decorationsWidth=r.decorationsWidth,this._renderResult=null,this._context.addEventHandler(this)}dispose(){this._context.removeEventHandler(this),this._renderResult=null,super.dispose()}onConfigurationChanged(e){const r=this._context.configuration.options.get(133);return this._decorationsLeft=r.decorationsLeft,this._decorationsWidth=r.decorationsWidth,!0}onDecorationsChanged(e){return!0}onFlushed(e){return!0}onLinesChanged(e){return!0}onLinesDeleted(e){return!0}onLinesInserted(e){return!0}onScrollChanged(e){return e.scrollTopChanged}onZonesChanged(e){return!0}_getDecorations(e){const i=e.getDecorationsInViewport(),r=[];let _=0;for(let S=0,z=i.length;S<z;S++){const ie=i[S],re=ie.options.linesDecorationsClassName;re&&(r[_++]=new In(ie.range.startLineNumber,ie.range.endLineNumber,re));const le=ie.options.firstLineDecorationClassName;le&&(r[_++]=new In(ie.range.startLineNumber,ie.range.startLineNumber,le))}return r}prepareRender(e){const i=e.visibleRange.startLineNumber,r=e.visibleRange.endLineNumber,_=this._render(i,r,this._getDecorations(e)),S=this._decorationsLeft.toString(),z=this._decorationsWidth.toString(),ie='" style="left:'+S+"px;width:"+z+'px;"></div>',re=[];for(let le=i;le<=r;le++){const me=le-i,we=_[me];let Be="";for(let Re=0,Je=we.length;Re<Je;Re++)Be+='<div class="cldr '+we[Re]+ie;re[me]=Be}this._renderResult=re}render(e,i){return this._renderResult?this._renderResult[i-e]:""}}class sn extends xn{constructor(e){super(),this._context=e,this._renderResult=null,this._context.addEventHandler(this)}dispose(){this._context.removeEventHandler(this),this._renderResult=null,super.dispose()}onConfigurationChanged(e){return!0}onDecorationsChanged(e){return!0}onFlushed(e){return!0}onLinesChanged(e){return!0}onLinesDeleted(e){return!0}onLinesInserted(e){return!0}onScrollChanged(e){return e.scrollTopChanged}onZonesChanged(e){return!0}_getDecorations(e){const i=e.getDecorationsInViewport(),r=[];let _=0;for(let S=0,z=i.length;S<z;S++){const ie=i[S],re=ie.options.marginClassName;re&&(r[_++]=new In(ie.range.startLineNumber,ie.range.endLineNumber,re))}return r}prepareRender(e){const i=e.visibleRange.startLineNumber,r=e.visibleRange.endLineNumber,_=this._render(i,r,this._getDecorations(e)),S=[];for(let z=i;z<=r;z++){const ie=z-i,re=_[ie];let le="";for(let me=0,we=re.length;me<we;me++)le+='<div class="cmdr '+re[me]+'" style=""></div>';S[ie]=le}this._renderResult=S}render(e,i){return this._renderResult?this._renderResult[i-e]:""}}var zn=y(10176);class Gi{constructor(e,i,r,_){this._rgba8Brand=void 0,this.r=Gi._clamp(e),this.g=Gi._clamp(i),this.b=Gi._clamp(r),this.a=Gi._clamp(_)}equals(e){return this.r===e.r&&this.g===e.g&&this.b===e.b&&this.a===e.a}static _clamp(e){return e<0?0:e>255?255:e|0}}Gi.Empty=new Gi(0,0,0,0);class $n extends p.jG{constructor(){super(),this._onDidChange=new T.vl,this.onDidChange=this._onDidChange.event,this._updateColorMap(),this._register(Ue.dG.onDidChange(e=>{e.changedColorMap&&this._updateColorMap()}))}static getInstance(){return this._INSTANCE||(this._INSTANCE=(0,p.lC)(new $n)),this._INSTANCE}_updateColorMap(){const e=Ue.dG.getColorMap();if(!e){this._colors=[Gi.Empty],this._backgroundIsLight=!0;return}this._colors=[Gi.Empty];for(let r=1;r<e.length;r++){const _=e[r].rgba;this._colors[r]=new Gi(_.r,_.g,_.b,Math.round(_.a*255))}const i=e[2].getRelativeLuminance();this._backgroundIsLight=i>=.5,this._onDidChange.fire(void 0)}getColor(e){return(e<1||e>=this._colors.length)&&(e=2),this._colors[e]}backgroundIsLight(){return this._backgroundIsLight}}$n._INSTANCE=null;var Nn=y(11608);const bi=(()=>{const Le=[];for(let e=32;e<=126;e++)Le.push(e);return Le.push(65533),Le})(),pt=(Le,e)=>(Le-=32,Le<0||Le>96?e<=2?(Le+96)%96:95:Le);var zt=y(37512);class Qt{constructor(e,i){this.scale=i,this._minimapCharRendererBrand=void 0,this.charDataNormal=Qt.soften(e,12/15),this.charDataLight=Qt.soften(e,50/60)}static soften(e,i){const r=new Uint8ClampedArray(e.length);for(let _=0,S=e.length;_<S;_++)r[_]=(0,zt.W)(e[_]*i);return r}renderChar(e,i,r,_,S,z,ie,re,le,me,we){const Be=1*this.scale,Re=2*this.scale,Je=we?1:Re;if(i+Be>e.width||r+Je>e.height){console.warn("bad render request outside image data");return}const st=me?this.charDataLight:this.charDataNormal,ct=pt(_,le),mt=e.width*4,xt=ie.r,Dt=ie.g,Jt=ie.b,$t=S.r-xt,ai=S.g-Dt,ii=S.b-Jt,Zt=Math.max(z,re),di=e.data;let Ai=ct*Be*Re,gi=r*mt+i*4;for(let un=0;un<Je;un++){let Ki=gi;for(let Pn=0;Pn<Be;Pn++){const $i=st[Ai++]/255*(z/255);di[Ki++]=xt+$t*$i,di[Ki++]=Dt+ai*$i,di[Ki++]=Jt+ii*$i,di[Ki++]=Zt}gi+=mt}}blockRenderChar(e,i,r,_,S,z,ie,re){const le=1*this.scale,me=2*this.scale,we=re?1:me;if(i+le>e.width||r+we>e.height){console.warn("bad render request outside image data");return}const Be=e.width*4,Re=.5*(S/255),Je=z.r,st=z.g,ct=z.b,mt=_.r-Je,xt=_.g-st,Dt=_.b-ct,Jt=Je+mt*Re,$t=st+xt*Re,ai=ct+Dt*Re,ii=Math.max(S,ie),Zt=e.data;let di=r*Be+i*4;for(let Ai=0;Ai<we;Ai++){let gi=di;for(let un=0;un<le;un++)Zt[gi++]=Jt,Zt[gi++]=$t,Zt[gi++]=ai,Zt[gi++]=ii;di+=Be}}}var Di=y(48289);const Ui={0:0,1:1,2:2,3:3,4:4,5:5,6:6,7:7,8:8,9:9,A:10,B:11,C:12,D:13,E:14,F:15},Wi=Le=>{const e=new Uint8ClampedArray(Le.length/2);for(let i=0;i<Le.length;i+=2)e[i>>1]=Ui[Le[i]]<<4|Ui[Le[i+1]]&15;return e},xe={1:(0,Di.O)(()=>Wi("0000511D6300CF609C709645A78432005642574171487021003C451900274D35D762755E8B629C5BA856AF57BA649530C167D1512A272A3F6038604460398526BCA2A968DB6F8957C768BE5FBE2FB467CF5D8D5B795DC7625B5DFF50DE64C466DB2FC47CD860A65E9A2EB96CB54CE06DA763AB2EA26860524D3763536601005116008177A8705E53AB738E6A982F88BAA35B5F5B626D9C636B449B737E5B7B678598869A662F6B5B8542706C704C80736A607578685B70594A49715A4522E792")),2:(0,Di.O)(()=>Wi("000000000000000055394F383D2800008B8B1F210002000081B1CBCBCC820000847AAF6B9AAF2119BE08B8881AD60000A44FD07DCCF107015338130C00000000385972265F390B406E2437634B4B48031B12B8A0847000001E15B29A402F0000000000004B33460B00007A752C2A0000000000004D3900000084394B82013400ABA5CFC7AD9C0302A45A3E5A98AB000089A43382D97900008BA54AA087A70A0248A6A7AE6DBE0000BF6F94987EA40A01A06DCFA7A7A9030496C32F77891D0000A99FB1A0AFA80603B29AB9CA75930D010C0948354D3900000C0948354F37460D0028BE673D8400000000AF9D7B6E00002B007AA8933400007AA642675C2700007984CFB9C3985B768772A8A6B7B20000CAAECAAFC4B700009F94A6009F840009D09F9BA4CA9C0000CC8FC76DC87F0000C991C472A2000000A894A48CA7B501079BA2C9C69BA20000B19A5D3FA89000005CA6009DA2960901B0A7F0669FB200009D009E00B7890000DAD0F5D092820000D294D4C48BD10000B5A7A4A3B1A50402CAB6CBA6A2000000B5A7A4A3B1A8044FCDADD19D9CB00000B7778F7B8AAE0803C9AB5D3F5D3F00009EA09EA0BAB006039EA0989A8C7900009B9EF4D6B7C00000A9A7816CACA80000ABAC84705D3F000096DA635CDC8C00006F486F266F263D4784006124097B00374F6D2D6D2D6D4A3A95872322000000030000000000008D8939130000000000002E22A5C9CBC70600AB25C0B5C9B400061A2DB04CA67001082AA6BEBEBFC606002321DACBC19E03087AA08B6768380000282FBAC0B8CA7A88AD25BBA5A29900004C396C5894A6000040485A6E356E9442A32CD17EADA70000B4237923628600003E2DE9C1D7B500002F25BBA5A2990000231DB6AFB4A804023025C0B5CAB588062B2CBDBEC0C706882435A75CA20000002326BD6A82A908048B4B9A5A668000002423A09CB4BB060025259C9D8A7900001C1FCAB2C7C700002A2A9387ABA200002626A4A47D6E9D14333163A0C87500004B6F9C2D643A257049364936493647358A34438355497F1A0000A24C1D590000D38DFFBDD4CD3126"))};class a{static create(e,i){if(this.lastCreated&&e===this.lastCreated.scale&&i===this.lastFontFamily)return this.lastCreated;let r;return xe[e]?r=new Qt(xe[e](),e):r=a.createFromSampleData(a.createSampleData(i).data,e),this.lastFontFamily=i,this.lastCreated=r,r}static createSampleData(e){const i=document.createElement("canvas"),r=i.getContext("2d");i.style.height="16px",i.height=16,i.width=960,i.style.width="960px",r.fillStyle="#ffffff",r.font=`bold 16px ${e}`,r.textBaseline="middle";let _=0;for(const S of bi)r.fillText(String.fromCharCode(S),_,16/2),_+=10;return r.getImageData(0,0,960,16)}static createFromSampleData(e,i){if(e.length!==61440)throw new Error("Unexpected source in MinimapCharRenderer");const _=a._downsample(e,i);return new Qt(_,i)}static _downsampleChar(e,i,r,_,S){const z=1*S,ie=2*S;let re=_,le=0;for(let me=0;me<ie;me++){const we=me/ie*16,Be=(me+1)/ie*16;for(let Re=0;Re<z;Re++){const Je=Re/z*10,st=(Re+1)/z*10;let ct=0,mt=0;for(let Dt=we;Dt<Be;Dt++){const Jt=i+Math.floor(Dt)*3840,$t=1-(Dt-Math.floor(Dt));for(let ai=Je;ai<st;ai++){const ii=1-(ai-Math.floor(ai)),Zt=Jt+Math.floor(ai)*4,di=ii*$t;mt+=di,ct+=e[Zt]*e[Zt+3]/255*di}}const xt=ct/mt;le=Math.max(le,xt),r[re++]=(0,zt.W)(xt)}}return le}static _downsample(e,i){const r=2*i*1*i,_=r*96,S=new Uint8ClampedArray(_);let z=0,ie=0,re=0;for(let le=0;le<96;le++)re=Math.max(re,this._downsampleChar(e,ie,S,z,i)),z+=r,ie+=40;if(re>0){const le=255/re;for(let me=0;me<_;me++)S[me]*=le}return S}}var n=y(66055);const c=140,I=2;class F{constructor(e,i,r){const _=e.options,S=_.get(131),z=_.get(133),ie=z.minimap,re=_.get(46),le=_.get(67);this.renderMinimap=ie.renderMinimap,this.size=le.size,this.minimapHeightIsEditorHeight=ie.minimapHeightIsEditorHeight,this.scrollBeyondLastLine=_.get(96),this.showSlider=le.showSlider,this.autohide=le.autohide,this.pixelRatio=S,this.typicalHalfwidthCharacterWidth=re.typicalHalfwidthCharacterWidth,this.lineHeight=_.get(61),this.minimapLeft=ie.minimapLeft,this.minimapWidth=ie.minimapWidth,this.minimapHeight=z.height,this.canvasInnerWidth=ie.minimapCanvasInnerWidth,this.canvasInnerHeight=ie.minimapCanvasInnerHeight,this.canvasOuterWidth=ie.minimapCanvasOuterWidth,this.canvasOuterHeight=ie.minimapCanvasOuterHeight,this.isSampling=ie.minimapIsSampling,this.editorHeight=z.height,this.fontScale=ie.minimapScale,this.minimapLineHeight=ie.minimapLineHeight,this.minimapCharWidth=1*this.fontScale,this.charRenderer=(0,Di.O)(()=>a.create(this.fontScale,re.fontFamily)),this.defaultBackgroundColor=r.getColor(2),this.backgroundColor=F._getMinimapBackground(i,this.defaultBackgroundColor),this.foregroundAlpha=F._getMinimapForegroundOpacity(i)}static _getMinimapBackground(e,i){const r=e.getColor(Li.ILr);return r?new Gi(r.rgba.r,r.rgba.g,r.rgba.b,Math.round(255*r.rgba.a)):i}static _getMinimapForegroundOpacity(e){const i=e.getColor(Li.K1Z);return i?Gi._clamp(Math.round(255*i.rgba.a)):255}equals(e){return this.renderMinimap===e.renderMinimap&&this.size===e.size&&this.minimapHeightIsEditorHeight===e.minimapHeightIsEditorHeight&&this.scrollBeyondLastLine===e.scrollBeyondLastLine&&this.showSlider===e.showSlider&&this.autohide===e.autohide&&this.pixelRatio===e.pixelRatio&&this.typicalHalfwidthCharacterWidth===e.typicalHalfwidthCharacterWidth&&this.lineHeight===e.lineHeight&&this.minimapLeft===e.minimapLeft&&this.minimapWidth===e.minimapWidth&&this.minimapHeight===e.minimapHeight&&this.canvasInnerWidth===e.canvasInnerWidth&&this.canvasInnerHeight===e.canvasInnerHeight&&this.canvasOuterWidth===e.canvasOuterWidth&&this.canvasOuterHeight===e.canvasOuterHeight&&this.isSampling===e.isSampling&&this.editorHeight===e.editorHeight&&this.fontScale===e.fontScale&&this.minimapLineHeight===e.minimapLineHeight&&this.minimapCharWidth===e.minimapCharWidth&&this.defaultBackgroundColor&&this.defaultBackgroundColor.equals(e.defaultBackgroundColor)&&this.backgroundColor&&this.backgroundColor.equals(e.backgroundColor)&&this.foregroundAlpha===e.foregroundAlpha}}class J{constructor(e,i,r,_,S,z,ie,re){this.scrollTop=e,this.scrollHeight=i,this.sliderNeeded=r,this._computedSliderRatio=_,this.sliderTop=S,this.sliderHeight=z,this.startLineNumber=ie,this.endLineNumber=re}getDesiredScrollTopFromDelta(e){return Math.round(this.scrollTop+e/this._computedSliderRatio)}getDesiredScrollTopFromTouchLocation(e){return Math.round((e-this.sliderHeight/2)/this._computedSliderRatio)}static create(e,i,r,_,S,z,ie,re,le,me,we){const Be=e.pixelRatio,Re=e.minimapLineHeight,Je=Math.floor(e.canvasInnerHeight/Re),st=e.lineHeight;if(e.minimapHeightIsEditorHeight){const $t=re*e.lineHeight+(e.scrollBeyondLastLine?S-e.lineHeight:0),ai=Math.max(1,Math.floor(S*S/$t)),ii=Math.max(0,e.minimapHeight-ai),Zt=ii/(me-S),di=le*Zt,Ai=ii>0,gi=Math.floor(e.canvasInnerHeight/e.minimapLineHeight);return new J(le,me,Ai,Zt,di,ai,1,Math.min(ie,gi))}let ct;if(z&&r!==ie){const $t=r-i+1;ct=Math.floor($t*Re/Be)}else{const $t=S/st;ct=Math.floor($t*Re/Be)}let mt;e.scrollBeyondLastLine?mt=(ie-1)*Re/Be:mt=Math.max(0,ie*Re/Be-ct),mt=Math.min(e.minimapHeight-ct,mt);const xt=mt/(me-S),Dt=le*xt;let Jt=0;if(e.scrollBeyondLastLine&&(Jt=S/st-1),Je>=ie+Jt){const ai=ie,ii=mt>0;return new J(le,me,ii,xt,Dt,ct,1,ai)}else{let $t=Math.max(1,Math.floor(i-Dt*Be/Re));we&&we.scrollHeight===me&&(we.scrollTop>le&&($t=Math.min($t,we.startLineNumber)),we.scrollTop<le&&($t=Math.max($t,we.startLineNumber)));const ai=Math.min(ie,$t+Je-1),ii=(le-_)/st,Zt=(i-$t+ii)*Re/Be;return new J(le,me,!0,xt,Zt,ct,$t,ai)}}}class ae{constructor(e){this.dy=e}onContentChanged(){this.dy=-1}onTokensChanged(){this.dy=-1}}ae.INVALID=new ae(-1);class de{constructor(e,i,r){this.renderedLayout=e,this._imageData=i,this._renderedLines=new Ni(()=>ae.INVALID),this._renderedLines._set(e.startLineNumber,r)}linesEquals(e){if(!this.scrollEquals(e))return!1;const r=this._renderedLines._get().lines;for(let _=0,S=r.length;_<S;_++)if(r[_].dy===-1)return!1;return!0}scrollEquals(e){return this.renderedLayout.startLineNumber===e.startLineNumber&&this.renderedLayout.endLineNumber===e.endLineNumber}_get(){const e=this._renderedLines._get();return{imageData:this._imageData,rendLineNumberStart:e.rendLineNumberStart,lines:e.lines}}onLinesChanged(e,i){return this._renderedLines.onLinesChanged(e,i)}onLinesDeleted(e,i){this._renderedLines.onLinesDeleted(e,i)}onLinesInserted(e,i){this._renderedLines.onLinesInserted(e,i)}onTokensChanged(e){return this._renderedLines.onTokensChanged(e)}}class Ce{constructor(e,i,r,_){this._backgroundFillData=Ce._createBackgroundFillData(i,r,_),this._buffers=[e.createImageData(i,r),e.createImageData(i,r)],this._lastUsedBuffer=0}getBuffer(){this._lastUsedBuffer=1-this._lastUsedBuffer;const e=this._buffers[this._lastUsedBuffer];return e.data.set(this._backgroundFillData),e}static _createBackgroundFillData(e,i,r){const _=r.r,S=r.g,z=r.b,ie=r.a,re=new Uint8ClampedArray(e*i*4);let le=0;for(let me=0;me<i;me++)for(let we=0;we<e;we++)re[le]=_,re[le+1]=S,re[le+2]=z,re[le+3]=ie,le+=4;return re}}class Ee{constructor(e,i){this.samplingRatio=e,this.minimapLines=i}static compute(e,i,r){if(e.renderMinimap===0||!e.isSampling)return[null,[]];const _=e.pixelRatio,S=e.lineHeight,z=e.scrollBeyondLastLine,{minimapLineCount:ie}=W.xZ.computeContainedMinimapLineCount({viewLineCount:i,scrollBeyondLastLine:z,height:e.editorHeight,lineHeight:S,pixelRatio:_}),re=i/ie,le=re/2;if(!r||r.minimapLines.length===0){const Dt=[];if(Dt[0]=1,ie>1){for(let Jt=0,$t=ie-1;Jt<$t;Jt++)Dt[Jt]=Math.round(Jt*re+le);Dt[ie-1]=i}return[new Ee(re,Dt),[]]}const me=r.minimapLines,we=me.length,Be=[];let Re=0,Je=0,st=1;const ct=10;let mt=[],xt=null;for(let Dt=0;Dt<ie;Dt++){const Jt=Math.max(st,Math.round(Dt*re)),$t=Math.max(Jt,Math.round((Dt+1)*re));for(;Re<we&&me[Re]<Jt;){if(mt.length<ct){const ii=Re+1+Je;xt&&xt.type==="deleted"&&xt._oldIndex===Re-1?xt.deleteToLineNumber++:(xt={type:"deleted",_oldIndex:Re,deleteFromLineNumber:ii,deleteToLineNumber:ii},mt.push(xt)),Je--}Re++}let ai;if(Re<we&&me[Re]<=$t)ai=me[Re],Re++;else if(Dt===0?ai=1:Dt+1===ie?ai=i:ai=Math.round(Dt*re+le),mt.length<ct){const ii=Re+1+Je;xt&&xt.type==="inserted"&&xt._i===Dt-1?xt.insertToLineNumber++:(xt={type:"inserted",_i:Dt,insertFromLineNumber:ii,insertToLineNumber:ii},mt.push(xt)),Je++}Be[Dt]=ai,st=ai}if(mt.length<ct)for(;Re<we;){const Dt=Re+1+Je;xt&&xt.type==="deleted"&&xt._oldIndex===Re-1?xt.deleteToLineNumber++:(xt={type:"deleted",_oldIndex:Re,deleteFromLineNumber:Dt,deleteToLineNumber:Dt},mt.push(xt)),Je--,Re++}else mt=[{type:"flush"}];return[new Ee(re,Be),mt]}modelLineToMinimapLine(e){return Math.min(this.minimapLines.length,Math.max(1,Math.round(e/this.samplingRatio)))}modelLineRangeToMinimapLineRange(e,i){let r=this.modelLineToMinimapLine(e)-1;for(;r>0&&this.minimapLines[r-1]>=e;)r--;let _=this.modelLineToMinimapLine(i)-1;for(;_+1<this.minimapLines.length&&this.minimapLines[_+1]<=i;)_++;if(r===_){const S=this.minimapLines[r];if(S<e||S>i)return null}return[r+1,_+1]}decorationLineRangeToMinimapLineRange(e,i){let r=this.modelLineToMinimapLine(e),_=this.modelLineToMinimapLine(i);return e!==i&&_===r&&(_===this.minimapLines.length?r>1&&r--:_++),[r,_]}onLinesDeleted(e){const i=e.toLineNumber-e.fromLineNumber+1;let r=this.minimapLines.length,_=0;for(let S=this.minimapLines.length-1;S>=0&&!(this.minimapLines[S]<e.fromLineNumber);S--)this.minimapLines[S]<=e.toLineNumber?(this.minimapLines[S]=Math.max(1,e.fromLineNumber-1),r=Math.min(r,S),_=Math.max(_,S)):this.minimapLines[S]-=i;return[r,_]}onLinesInserted(e){const i=e.toLineNumber-e.fromLineNumber+1;for(let r=this.minimapLines.length-1;r>=0&&!(this.minimapLines[r]<e.fromLineNumber);r--)this.minimapLines[r]+=i}}class Ne extends pe{constructor(e){super(e),this.tokensColorTracker=$n.getInstance(),this._selections=[],this._minimapSelections=null,this.options=new F(this._context.configuration,this._context.theme,this.tokensColorTracker);const[i]=Ee.compute(this.options,this._context.viewModel.getLineCount(),null);this._samplingState=i,this._shouldCheckSampling=!1,this._actual=new He(e.theme,this)}dispose(){this._actual.dispose(),super.dispose()}getDomNode(){return this._actual.getDomNode()}_onOptionsMaybeChanged(){const e=new F(this._context.configuration,this._context.theme,this.tokensColorTracker);return this.options.equals(e)?!1:(this.options=e,this._recreateLineSampling(),this._actual.onDidChangeOptions(),!0)}onConfigurationChanged(e){return this._onOptionsMaybeChanged()}onCursorStateChanged(e){return this._selections=e.selections,this._minimapSelections=null,this._actual.onSelectionChanged()}onDecorationsChanged(e){return e.affectsMinimap?this._actual.onDecorationsChanged():!1}onFlushed(e){return this._samplingState&&(this._shouldCheckSampling=!0),this._actual.onFlushed()}onLinesChanged(e){if(this._samplingState){const i=this._samplingState.modelLineRangeToMinimapLineRange(e.fromLineNumber,e.fromLineNumber+e.count-1);return i?this._actual.onLinesChanged(i[0],i[1]-i[0]+1):!1}else return this._actual.onLinesChanged(e.fromLineNumber,e.count)}onLinesDeleted(e){if(this._samplingState){const[i,r]=this._samplingState.onLinesDeleted(e);return i<=r&&this._actual.onLinesChanged(i+1,r-i+1),this._shouldCheckSampling=!0,!0}else return this._actual.onLinesDeleted(e.fromLineNumber,e.toLineNumber)}onLinesInserted(e){return this._samplingState?(this._samplingState.onLinesInserted(e),this._shouldCheckSampling=!0,!0):this._actual.onLinesInserted(e.fromLineNumber,e.toLineNumber)}onScrollChanged(e){return this._actual.onScrollChanged()}onThemeChanged(e){return this._actual.onThemeChanged(),this._onOptionsMaybeChanged(),!0}onTokensChanged(e){if(this._samplingState){const i=[];for(const r of e.ranges){const _=this._samplingState.modelLineRangeToMinimapLineRange(r.fromLineNumber,r.toLineNumber);_&&i.push({fromLineNumber:_[0],toLineNumber:_[1]})}return i.length?this._actual.onTokensChanged(i):!1}else return this._actual.onTokensChanged(e.ranges)}onTokensColorsChanged(e){return this._onOptionsMaybeChanged(),this._actual.onTokensColorsChanged()}onZonesChanged(e){return this._actual.onZonesChanged()}prepareRender(e){this._shouldCheckSampling&&(this._shouldCheckSampling=!1,this._recreateLineSampling())}render(e){let i=e.visibleRange.startLineNumber,r=e.visibleRange.endLineNumber;this._samplingState&&(i=this._samplingState.modelLineToMinimapLine(i),r=this._samplingState.modelLineToMinimapLine(r));const _={viewportContainsWhitespaceGaps:e.viewportData.whitespaceViewportData.length>0,scrollWidth:e.scrollWidth,scrollHeight:e.scrollHeight,viewportStartLineNumber:i,viewportEndLineNumber:r,viewportStartLineNumberVerticalOffset:e.getVerticalOffsetForLineNumber(i),scrollTop:e.scrollTop,scrollLeft:e.scrollLeft,viewportWidth:e.viewportWidth,viewportHeight:e.viewportHeight};this._actual.render(_)}_recreateLineSampling(){this._minimapSelections=null;const e=!!this._samplingState,[i,r]=Ee.compute(this.options,this._context.viewModel.getLineCount(),this._samplingState);if(this._samplingState=i,e&&this._samplingState)for(const _ of r)switch(_.type){case"deleted":this._actual.onLinesDeleted(_.deleteFromLineNumber,_.deleteToLineNumber);break;case"inserted":this._actual.onLinesInserted(_.insertFromLineNumber,_.insertToLineNumber);break;case"flush":this._actual.onFlushed();break}}getLineCount(){return this._samplingState?this._samplingState.minimapLines.length:this._context.viewModel.getLineCount()}getRealLineCount(){return this._context.viewModel.getLineCount()}getLineContent(e){return this._samplingState?this._context.viewModel.getLineContent(this._samplingState.minimapLines[e-1]):this._context.viewModel.getLineContent(e)}getLineMaxColumn(e){return this._samplingState?this._context.viewModel.getLineMaxColumn(this._samplingState.minimapLines[e-1]):this._context.viewModel.getLineMaxColumn(e)}getMinimapLinesRenderingData(e,i,r){if(this._samplingState){const _=[];for(let S=0,z=i-e+1;S<z;S++)r[S]?_[S]=this._context.viewModel.getViewLineData(this._samplingState.minimapLines[e+S-1]):_[S]=null;return _}return this._context.viewModel.getMinimapLinesRenderingData(e,i,r).data}getSelections(){if(this._minimapSelections===null)if(this._samplingState){this._minimapSelections=[];for(const e of this._selections){const[i,r]=this._samplingState.decorationLineRangeToMinimapLineRange(e.startLineNumber,e.endLineNumber);this._minimapSelections.push(new ue.L(i,e.startColumn,r,e.endColumn))}}else this._minimapSelections=this._selections;return this._minimapSelections}getMinimapDecorationsInViewport(e,i){let r;if(this._samplingState){const S=this._samplingState.minimapLines[e-1],z=this._samplingState.minimapLines[i-1];r=new Pt.Q(S,1,z,this._context.viewModel.getLineMaxColumn(z))}else r=new Pt.Q(e,1,i,this._context.viewModel.getLineMaxColumn(i));const _=this._context.viewModel.getDecorationsInViewport(r);if(this._samplingState){const S=[];for(const z of _){if(!z.options.minimap)continue;const ie=z.range,re=this._samplingState.modelLineToMinimapLine(ie.startLineNumber),le=this._samplingState.modelLineToMinimapLine(ie.endLineNumber);S.push(new Nn.vo(new Pt.Q(re,ie.startColumn,le,ie.endColumn),z.options))}return S}return _}getOptions(){return this._context.viewModel.model.getOptions()}revealLineNumber(e){this._samplingState&&(e=this._samplingState.minimapLines[e-1]),this._context.viewModel.revealRange("mouse",!1,new Pt.Q(e,1,e,1),1,0)}setScrollTop(e){this._context.viewModel.viewLayout.setScrollPosition({scrollTop:e},1)}}class He extends p.jG{constructor(e,i){super(),this._renderDecorations=!1,this._gestureInProgress=!1,this._theme=e,this._model=i,this._lastRenderData=null,this._buffers=null,this._selectionColor=this._theme.getColor(Li.yr0),this._domNode=(0,E.Z)(document.createElement("div")),be.write(this._domNode,8),this._domNode.setClassName(this._getMinimapDomNodeClassName()),this._domNode.setPosition("absolute"),this._domNode.setAttribute("role","presentation"),this._domNode.setAttribute("aria-hidden","true"),this._shadow=(0,E.Z)(document.createElement("div")),this._shadow.setClassName("minimap-shadow-hidden"),this._domNode.appendChild(this._shadow),this._canvas=(0,E.Z)(document.createElement("canvas")),this._canvas.setPosition("absolute"),this._canvas.setLeft(0),this._domNode.appendChild(this._canvas),this._decorationsCanvas=(0,E.Z)(document.createElement("canvas")),this._decorationsCanvas.setPosition("absolute"),this._decorationsCanvas.setClassName("minimap-decorations-layer"),this._decorationsCanvas.setLeft(0),this._domNode.appendChild(this._decorationsCanvas),this._slider=(0,E.Z)(document.createElement("div")),this._slider.setPosition("absolute"),this._slider.setClassName("minimap-slider"),this._slider.setLayerHinting(!0),this._slider.setContain("strict"),this._domNode.appendChild(this._slider),this._sliderHorizontal=(0,E.Z)(document.createElement("div")),this._sliderHorizontal.setPosition("absolute"),this._sliderHorizontal.setClassName("minimap-slider-horizontal"),this._slider.appendChild(this._sliderHorizontal),this._applyLayout(),this._pointerDownListener=P.b2(this._domNode.domNode,P.Bx.POINTER_DOWN,r=>{if(r.preventDefault(),this._model.options.renderMinimap===0||!this._lastRenderData)return;if(this._model.options.size!=="proportional"){if(r.button===0&&this._lastRenderData){const le=P.BK(this._slider.domNode),me=le.top+le.height/2;this._startSliderDragging(r,me,this._lastRenderData.renderedLayout)}return}const S=this._model.options.minimapLineHeight,z=this._model.options.canvasInnerHeight/this._model.options.canvasOuterHeight*r.offsetY;let re=Math.floor(z/S)+this._lastRenderData.renderedLayout.startLineNumber;re=Math.min(re,this._model.getLineCount()),this._model.revealLineNumber(re)}),this._sliderPointerMoveMonitor=new zn._,this._sliderPointerDownListener=P.b2(this._slider.domNode,P.Bx.POINTER_DOWN,r=>{r.preventDefault(),r.stopPropagation(),r.button===0&&this._lastRenderData&&this._startSliderDragging(r,r.pageY,this._lastRenderData.renderedLayout)}),this._gestureDisposable=Qe.q.addTarget(this._domNode.domNode),this._sliderTouchStartListener=P.ko(this._domNode.domNode,Qe.B.Start,r=>{r.preventDefault(),r.stopPropagation(),this._lastRenderData&&(this._slider.toggleClassName("active",!0),this._gestureInProgress=!0,this.scrollDueToTouchEvent(r))},{passive:!1}),this._sliderTouchMoveListener=P.ko(this._domNode.domNode,Qe.B.Change,r=>{r.preventDefault(),r.stopPropagation(),this._lastRenderData&&this._gestureInProgress&&this.scrollDueToTouchEvent(r)},{passive:!1}),this._sliderTouchEndListener=P.b2(this._domNode.domNode,Qe.B.End,r=>{r.preventDefault(),r.stopPropagation(),this._gestureInProgress=!1,this._slider.toggleClassName("active",!1)})}_startSliderDragging(e,i,r){if(!e.target||!(e.target instanceof Element))return;const _=e.pageX;this._slider.toggleClassName("active",!0);const S=(z,ie)=>{const re=Math.abs(ie-_);if(u.uF&&re>c){this._model.setScrollTop(r.scrollTop);return}const le=z-i;this._model.setScrollTop(r.getDesiredScrollTopFromDelta(le))};e.pageY!==i&&S(e.pageY,_),this._sliderPointerMoveMonitor.startMonitoring(e.target,e.pointerId,e.buttons,z=>S(z.pageY,z.pageX),()=>{this._slider.toggleClassName("active",!1)})}scrollDueToTouchEvent(e){const i=this._domNode.domNode.getBoundingClientRect().top,r=this._lastRenderData.renderedLayout.getDesiredScrollTopFromTouchLocation(e.pageY-i);this._model.setScrollTop(r)}dispose(){this._pointerDownListener.dispose(),this._sliderPointerMoveMonitor.dispose(),this._sliderPointerDownListener.dispose(),this._gestureDisposable.dispose(),this._sliderTouchStartListener.dispose(),this._sliderTouchMoveListener.dispose(),this._sliderTouchEndListener.dispose(),super.dispose()}_getMinimapDomNodeClassName(){const e=["minimap"];return this._model.options.showSlider==="always"?e.push("slider-always"):e.push("slider-mouseover"),this._model.options.autohide&&e.push("autohide"),e.join(" ")}getDomNode(){return this._domNode}_applyLayout(){this._domNode.setLeft(this._model.options.minimapLeft),this._domNode.setWidth(this._model.options.minimapWidth),this._domNode.setHeight(this._model.options.minimapHeight),this._shadow.setHeight(this._model.options.minimapHeight),this._canvas.setWidth(this._model.options.canvasOuterWidth),this._canvas.setHeight(this._model.options.canvasOuterHeight),this._canvas.domNode.width=this._model.options.canvasInnerWidth,this._canvas.domNode.height=this._model.options.canvasInnerHeight,this._decorationsCanvas.setWidth(this._model.options.canvasOuterWidth),this._decorationsCanvas.setHeight(this._model.options.canvasOuterHeight),this._decorationsCanvas.domNode.width=this._model.options.canvasInnerWidth,this._decorationsCanvas.domNode.height=this._model.options.canvasInnerHeight,this._slider.setWidth(this._model.options.minimapWidth)}_getBuffer(){return this._buffers||this._model.options.canvasInnerWidth>0&&this._model.options.canvasInnerHeight>0&&(this._buffers=new Ce(this._canvas.domNode.getContext("2d"),this._model.options.canvasInnerWidth,this._model.options.canvasInnerHeight,this._model.options.backgroundColor)),this._buffers?this._buffers.getBuffer():null}onDidChangeOptions(){this._lastRenderData=null,this._buffers=null,this._applyLayout(),this._domNode.setClassName(this._getMinimapDomNodeClassName())}onSelectionChanged(){return this._renderDecorations=!0,!0}onDecorationsChanged(){return this._renderDecorations=!0,!0}onFlushed(){return this._lastRenderData=null,!0}onLinesChanged(e,i){return this._lastRenderData?this._lastRenderData.onLinesChanged(e,i):!1}onLinesDeleted(e,i){var r;return(r=this._lastRenderData)===null||r===void 0||r.onLinesDeleted(e,i),!0}onLinesInserted(e,i){var r;return(r=this._lastRenderData)===null||r===void 0||r.onLinesInserted(e,i),!0}onScrollChanged(){return this._renderDecorations=!0,!0}onThemeChanged(){return this._selectionColor=this._theme.getColor(Li.yr0),this._renderDecorations=!0,!0}onTokensChanged(e){return this._lastRenderData?this._lastRenderData.onTokensChanged(e):!1}onTokensColorsChanged(){return this._lastRenderData=null,this._buffers=null,!0}onZonesChanged(){return this._lastRenderData=null,!0}render(e){if(this._model.options.renderMinimap===0){this._shadow.setClassName("minimap-shadow-hidden"),this._sliderHorizontal.setWidth(0),this._sliderHorizontal.setHeight(0);return}e.scrollLeft+e.viewportWidth>=e.scrollWidth?this._shadow.setClassName("minimap-shadow-hidden"):this._shadow.setClassName("minimap-shadow-visible");const r=J.create(this._model.options,e.viewportStartLineNumber,e.viewportEndLineNumber,e.viewportStartLineNumberVerticalOffset,e.viewportHeight,e.viewportContainsWhitespaceGaps,this._model.getLineCount(),this._model.getRealLineCount(),e.scrollTop,e.scrollHeight,this._lastRenderData?this._lastRenderData.renderedLayout:null);this._slider.setDisplay(r.sliderNeeded?"block":"none"),this._slider.setTop(r.sliderTop),this._slider.setHeight(r.sliderHeight),this._sliderHorizontal.setLeft(0),this._sliderHorizontal.setWidth(this._model.options.minimapWidth),this._sliderHorizontal.setTop(0),this._sliderHorizontal.setHeight(r.sliderHeight),this.renderDecorations(r),this._lastRenderData=this.renderLines(r)}renderDecorations(e){if(this._renderDecorations){this._renderDecorations=!1;const i=this._model.getSelections();i.sort(Pt.Q.compareRangesUsingStarts);const r=this._model.getMinimapDecorationsInViewport(e.startLineNumber,e.endLineNumber);r.sort((Be,Re)=>(Be.options.zIndex||0)-(Re.options.zIndex||0));const{canvasInnerWidth:_,canvasInnerHeight:S}=this._model.options,z=this._model.options.minimapLineHeight,ie=this._model.options.minimapCharWidth,re=this._model.getOptions().tabSize,le=this._decorationsCanvas.domNode.getContext("2d");le.clearRect(0,0,_,S);const me=new Ze(e.startLineNumber,e.endLineNumber,!1);this._renderSelectionLineHighlights(le,i,me,e,z),this._renderDecorationsLineHighlights(le,r,me,e,z);const we=new Ze(e.startLineNumber,e.endLineNumber,null);this._renderSelectionsHighlights(le,i,we,e,z,re,ie,_),this._renderDecorationsHighlights(le,r,we,e,z,re,ie,_)}}_renderSelectionLineHighlights(e,i,r,_,S){if(!this._selectionColor||this._selectionColor.isTransparent())return;e.fillStyle=this._selectionColor.transparent(.5).toString();let z=0,ie=0;for(const re of i){const le=Math.max(_.startLineNumber,re.startLineNumber),me=Math.min(_.endLineNumber,re.endLineNumber);if(le>me)continue;for(let Re=le;Re<=me;Re++)r.set(Re,!0);const we=(le-_.startLineNumber)*S,Be=(me-_.startLineNumber)*S+S;ie>=we||(ie>z&&e.fillRect(W.xq,z,e.canvas.width,ie-z),z=we),ie=Be}ie>z&&e.fillRect(W.xq,z,e.canvas.width,ie-z)}_renderDecorationsLineHighlights(e,i,r,_,S){const z=new Map;for(let ie=i.length-1;ie>=0;ie--){const re=i[ie],le=re.options.minimap;if(!le||le.position!==n.R3.Inline)continue;const me=Math.max(_.startLineNumber,re.range.startLineNumber),we=Math.min(_.endLineNumber,re.range.endLineNumber);if(me>we)continue;const Be=le.getColor(this._theme.value);if(!Be||Be.isTransparent())continue;let Re=z.get(Be.toString());Re||(Re=Be.transparent(.5).toString(),z.set(Be.toString(),Re)),e.fillStyle=Re;for(let Je=me;Je<=we;Je++){if(r.has(Je))continue;r.set(Je,!0);const st=(me-_.startLineNumber)*S;e.fillRect(W.xq,st,e.canvas.width,S)}}}_renderSelectionsHighlights(e,i,r,_,S,z,ie,re){if(!(!this._selectionColor||this._selectionColor.isTransparent()))for(const le of i){const me=Math.max(_.startLineNumber,le.startLineNumber),we=Math.min(_.endLineNumber,le.endLineNumber);if(!(me>we))for(let Be=me;Be<=we;Be++)this.renderDecorationOnLine(e,r,le,this._selectionColor,_,Be,S,S,z,ie,re)}}_renderDecorationsHighlights(e,i,r,_,S,z,ie,re){for(const le of i){const me=le.options.minimap;if(!me)continue;const we=Math.max(_.startLineNumber,le.range.startLineNumber),Be=Math.min(_.endLineNumber,le.range.endLineNumber);if(we>Be)continue;const Re=me.getColor(this._theme.value);if(!(!Re||Re.isTransparent()))for(let Je=we;Je<=Be;Je++)switch(me.position){case n.R3.Inline:this.renderDecorationOnLine(e,r,le.range,Re,_,Je,S,S,z,ie,re);continue;case n.R3.Gutter:{const st=(Je-_.startLineNumber)*S;this.renderDecoration(e,Re,2,st,I,S);continue}}}}renderDecorationOnLine(e,i,r,_,S,z,ie,re,le,me,we){const Be=(z-S.startLineNumber)*re;if(Be+ie<0||Be>this._model.options.canvasInnerHeight)return;const{startLineNumber:Re,endLineNumber:Je}=r,st=Re===z?r.startColumn:1,ct=Je===z?r.endColumn:this._model.getLineMaxColumn(z),mt=this.getXOffsetForPosition(i,z,st,le,me,we),xt=this.getXOffsetForPosition(i,z,ct,le,me,we);this.renderDecoration(e,_,mt,Be,xt-mt,ie)}getXOffsetForPosition(e,i,r,_,S,z){if(r===1)return W.xq;if((r-1)*S>=z)return z;let re=e.get(i);if(!re){const le=this._model.getLineContent(i);re=[W.xq];let me=W.xq;for(let we=1;we<le.length+1;we++){const Be=le.charCodeAt(we-1),Re=Be===9?_*S:at.ne(Be)?2*S:S,Je=me+Re;if(Je>=z){re[we]=z;break}re[we]=Je,me=Je}e.set(i,re)}return r-1<re.length?re[r-1]:z}renderDecoration(e,i,r,_,S,z){e.fillStyle=i&&i.toString()||"",e.fillRect(r,_,S,z)}renderLines(e){const i=e.startLineNumber,r=e.endLineNumber,_=this._model.options.minimapLineHeight;if(this._lastRenderData&&this._lastRenderData.linesEquals(e)){const $i=this._lastRenderData._get();return new de(e,$i.imageData,$i.lines)}const S=this._getBuffer();if(!S)return null;const[z,ie,re]=He._renderUntouchedLines(S,i,r,_,this._lastRenderData),le=this._model.getMinimapLinesRenderingData(i,r,re),me=this._model.getOptions().tabSize,we=this._model.options.defaultBackgroundColor,Be=this._model.options.backgroundColor,Re=this._model.options.foregroundAlpha,Je=this._model.tokensColorTracker,st=Je.backgroundIsLight(),ct=this._model.options.renderMinimap,mt=this._model.options.charRenderer(),xt=this._model.options.fontScale,Dt=this._model.options.minimapCharWidth,$t=(ct===1?2:3)*xt,ai=_>$t?Math.floor((_-$t)/2):0,ii=Be.a/255,Zt=new Gi(Math.round((Be.r-we.r)*ii+we.r),Math.round((Be.g-we.g)*ii+we.g),Math.round((Be.b-we.b)*ii+we.b),255);let di=0;const Ai=[];for(let $i=0,Dn=r-i+1;$i<Dn;$i++)re[$i]&&He._renderLine(S,Zt,Be.a,st,ct,Dt,Je,Re,mt,di,ai,me,le[$i],xt,_),Ai[$i]=new ae(di),di+=_;const gi=z===-1?0:z,Ki=(ie===-1?S.height:ie)-gi;return this._canvas.domNode.getContext("2d").putImageData(S,0,0,0,gi,S.width,Ki),new de(e,S,Ai)}static _renderUntouchedLines(e,i,r,_,S){const z=[];if(!S){for(let Zt=0,di=r-i+1;Zt<di;Zt++)z[Zt]=!0;return[-1,-1,z]}const ie=S._get(),re=ie.imageData.data,le=ie.rendLineNumberStart,me=ie.lines,we=me.length,Be=e.width,Re=e.data,Je=(r-i+1)*_*Be*4;let st=-1,ct=-1,mt=-1,xt=-1,Dt=-1,Jt=-1,$t=0;for(let Zt=i;Zt<=r;Zt++){const di=Zt-i,Ai=Zt-le,gi=Ai>=0&&Ai<we?me[Ai].dy:-1;if(gi===-1){z[di]=!0,$t+=_;continue}const un=gi*Be*4,Ki=(gi+_)*Be*4,Pn=$t*Be*4,$i=($t+_)*Be*4;xt===un&&Jt===Pn?(xt=Ki,Jt=$i):(mt!==-1&&(Re.set(re.subarray(mt,xt),Dt),st===-1&&mt===0&&mt===Dt&&(st=xt),ct===-1&&xt===Je&&mt===Dt&&(ct=mt)),mt=un,xt=Ki,Dt=Pn,Jt=$i),z[di]=!1,$t+=_}mt!==-1&&(Re.set(re.subarray(mt,xt),Dt),st===-1&&mt===0&&mt===Dt&&(st=xt),ct===-1&&xt===Je&&mt===Dt&&(ct=mt));const ai=st===-1?-1:st/(Be*4),ii=ct===-1?-1:ct/(Be*4);return[ai,ii,z]}static _renderLine(e,i,r,_,S,z,ie,re,le,me,we,Be,Re,Je,st){const ct=Re.content,mt=Re.tokens,xt=e.width-z,Dt=st===1;let Jt=W.xq,$t=0,ai=0;for(let ii=0,Zt=mt.getCount();ii<Zt;ii++){const di=mt.getEndOffset(ii),Ai=mt.getForeground(ii),gi=ie.getColor(Ai);for(;$t<di;$t++){if(Jt>xt)return;const un=ct.charCodeAt($t);if(un===9){const Ki=Be-($t+ai)%Be;ai+=Ki-1,Jt+=Ki*z}else if(un===32)Jt+=z;else{const Ki=at.ne(un)?2:1;for(let Pn=0;Pn<Ki;Pn++)if(S===2?le.blockRenderChar(e,Jt,me+we,gi,re,i,r,Dt):le.renderChar(e,Jt,me+we,un,gi,re,i,r,Je,_,Dt),Jt+=z,Jt>xt)return}}}}}class Ze{constructor(e,i,r){this._startLineNumber=e,this._endLineNumber=i,this._defaultValue=r,this._values=[];for(let _=0,S=this._endLineNumber-this._startLineNumber+1;_<S;_++)this._values[_]=r}has(e){return this.get(e)!==this._defaultValue}set(e,i){e<this._startLineNumber||e>this._endLineNumber||(this._values[e-this._startLineNumber]=i)}get(e){return e<this._startLineNumber||e>this._endLineNumber?this._defaultValue:this._values[e-this._startLineNumber]}}(0,kt.zy)((Le,e)=>{const i=Le.getColor(Li.rB3);i&&e.addRule(`.monaco-editor .minimap-slider .minimap-slider-horizontal { background: ${i}; }`);const r=Le.getColor(Li.Rig);r&&e.addRule(`.monaco-editor .minimap-slider:hover .minimap-slider-horizontal { background: ${r}; }`);const _=Le.getColor(Li.JVY);_&&e.addRule(`.monaco-editor .minimap-slider.active .minimap-slider-horizontal { background: ${_}; }`);const S=Le.getColor(Li.bXl);S&&e.addRule(`.monaco-editor .minimap-shadow-visible { box-shadow: ${S} -6px 0 6px -6px inset; }`)});class et extends pe{constructor(e){super(e);const r=this._context.configuration.options.get(133);this._widgets={},this._verticalScrollbarWidth=r.verticalScrollbarWidth,this._minimapWidth=r.minimap.minimapWidth,this._horizontalScrollbarHeight=r.horizontalScrollbarHeight,this._editorHeight=r.height,this._editorWidth=r.width,this._domNode=(0,E.Z)(document.createElement("div")),be.write(this._domNode,4),this._domNode.setClassName("overlayWidgets")}dispose(){super.dispose(),this._widgets={}}getDomNode(){return this._domNode}onConfigurationChanged(e){const r=this._context.configuration.options.get(133);return this._verticalScrollbarWidth=r.verticalScrollbarWidth,this._minimapWidth=r.minimap.minimapWidth,this._horizontalScrollbarHeight=r.horizontalScrollbarHeight,this._editorHeight=r.height,this._editorWidth=r.width,!0}addWidget(e){const i=(0,E.Z)(e.getDomNode());this._widgets[e.getId()]={widget:e,preference:null,domNode:i},i.setPosition("absolute"),i.setAttribute("widgetId",e.getId()),this._domNode.appendChild(i),this.setShouldRender()}setWidgetPosition(e,i){const r=this._widgets[e.getId()];return r.preference===i?!1:(r.preference=i,this.setShouldRender(),!0)}removeWidget(e){const i=e.getId();if(this._widgets.hasOwnProperty(i)){const _=this._widgets[i].domNode.domNode;delete this._widgets[i],_.parentNode.removeChild(_),this.setShouldRender()}}_renderWidget(e){const i=e.domNode;if(e.preference===null){i.setTop("");return}if(e.preference===0)i.setTop(0),i.setRight(2*this._verticalScrollbarWidth+this._minimapWidth);else if(e.preference===1){const r=i.domNode.clientHeight;i.setTop(this._editorHeight-r-2*this._horizontalScrollbarHeight),i.setRight(2*this._verticalScrollbarWidth+this._minimapWidth)}else e.preference===2&&(i.setTop(0),i.domNode.style.right="50%")}prepareRender(e){}render(e){this._domNode.setWidth(this._editorWidth);const i=Object.keys(this._widgets);for(let r=0,_=i.length;r<_;r++){const S=i[r];this._renderWidget(this._widgets[S])}}}class ot{constructor(e,i){const r=e.options;this.lineHeight=r.get(61),this.pixelRatio=r.get(131),this.overviewRulerLanes=r.get(76),this.renderBorder=r.get(75);const _=i.getColor(wt.x9);this.borderColor=_?_.toString():null,this.hideCursor=r.get(54);const S=i.getColor(wt.D0);this.cursorColor=S?S.transparent(.7).toString():null,this.themeType=i.type;const z=r.get(67),ie=z.enabled,re=z.side,le=i.getColor(wt.Xr),me=Ue.dG.getDefaultBackground();let we=null;le!==void 0?we=le:ie&&(we=me),we===null||re==="left"?this.backgroundColor=null:this.backgroundColor=ei.Q1.Format.CSS.formatHex(we);const Re=r.get(133).overviewRuler;this.top=Re.top,this.right=Re.right,this.domWidth=Re.width,this.domHeight=Re.height,this.overviewRulerLanes===0?(this.canvasWidth=0,this.canvasHeight=0):(this.canvasWidth=this.domWidth*this.pixelRatio|0,this.canvasHeight=this.domHeight*this.pixelRatio|0);const[Je,st]=this._initLanes(1,this.canvasWidth,this.overviewRulerLanes);this.x=Je,this.w=st}_initLanes(e,i,r){const _=i-e;if(r>=3){const S=Math.floor(_/3),z=Math.floor(_/3),ie=_-S-z,re=e,le=re+S,me=re+S+ie;return[[0,re,le,re,me,re,le,re],[0,S,ie,S+ie,z,S+ie+z,ie+z,S+ie+z]]}else if(r===2){const S=Math.floor(_/2),z=_-S,ie=e,re=ie+S;return[[0,ie,ie,ie,re,ie,ie,ie],[0,S,S,S,z,S+z,S+z,S+z]]}else{const S=e,z=_;return[[0,S,S,S,S,S,S,S],[0,z,z,z,z,z,z,z]]}}equals(e){return this.lineHeight===e.lineHeight&&this.pixelRatio===e.pixelRatio&&this.overviewRulerLanes===e.overviewRulerLanes&&this.renderBorder===e.renderBorder&&this.borderColor===e.borderColor&&this.hideCursor===e.hideCursor&&this.cursorColor===e.cursorColor&&this.themeType===e.themeType&&this.backgroundColor===e.backgroundColor&&this.top===e.top&&this.right===e.right&&this.domWidth===e.domWidth&&this.domHeight===e.domHeight&&this.canvasWidth===e.canvasWidth&&this.canvasHeight===e.canvasHeight}}class lt extends pe{constructor(e){super(e),this._domNode=(0,E.Z)(document.createElement("canvas")),this._domNode.setClassName("decorationsOverviewRuler"),this._domNode.setPosition("absolute"),this._domNode.setLayerHinting(!0),this._domNode.setContain("strict"),this._domNode.setAttribute("aria-hidden","true"),this._updateSettings(!1),this._tokensColorTrackerListener=Ue.dG.onDidChange(i=>{i.changedColorMap&&this._updateSettings(!0)}),this._cursorPositions=[]}dispose(){super.dispose(),this._tokensColorTrackerListener.dispose()}_updateSettings(e){const i=new ot(this._context.configuration,this._context.theme);return this._settings&&this._settings.equals(i)?!1:(this._settings=i,this._domNode.setTop(this._settings.top),this._domNode.setRight(this._settings.right),this._domNode.setWidth(this._settings.domWidth),this._domNode.setHeight(this._settings.domHeight),this._domNode.domNode.width=this._settings.canvasWidth,this._domNode.domNode.height=this._settings.canvasHeight,e&&this._render(),!0)}onConfigurationChanged(e){return this._updateSettings(!1)}onCursorStateChanged(e){this._cursorPositions=[];for(let i=0,r=e.selections.length;i<r;i++)this._cursorPositions[i]=e.selections[i].getPosition();return this._cursorPositions.sort(Nt.y.compare),!0}onDecorationsChanged(e){return!!e.affectsOverviewRuler}onFlushed(e){return!0}onScrollChanged(e){return e.scrollHeightChanged}onZonesChanged(e){return!0}onThemeChanged(e){return this._updateSettings(!1)}getDomNode(){return this._domNode.domNode}prepareRender(e){}render(e){this._render()}_render(){if(this._settings.overviewRulerLanes===0){this._domNode.setBackgroundColor(this._settings.backgroundColor?this._settings.backgroundColor:""),this._domNode.setDisplay("none");return}this._domNode.setDisplay("block");const e=this._settings.canvasWidth,i=this._settings.canvasHeight,r=this._settings.lineHeight,_=this._context.viewLayout,S=this._context.viewLayout.getScrollHeight(),z=i/S,ie=this._context.viewModel.getAllOverviewRulerDecorations(this._context.theme),re=6*this._settings.pixelRatio|0,le=re/2|0,me=this._domNode.domNode.getContext("2d");this._settings.backgroundColor===null?me.clearRect(0,0,e,i):(me.fillStyle=this._settings.backgroundColor,me.fillRect(0,0,e,i));const we=this._settings.x,Be=this._settings.w;ie.sort(Nn.Uv.cmp);for(const Re of ie){const Je=Re.color,st=Re.data;me.fillStyle=Je;let ct=0,mt=0,xt=0;for(let Dt=0,Jt=st.length/3;Dt<Jt;Dt++){const $t=st[3*Dt],ai=st[3*Dt+1],ii=st[3*Dt+2];let Zt=_.getVerticalOffsetForLineNumber(ai)*z|0,di=(_.getVerticalOffsetForLineNumber(ii)+r)*z|0;if(di-Zt<re){let gi=(Zt+di)/2|0;gi<le?gi=le:gi+le>i&&(gi=i-le),Zt=gi-le,di=gi+le}Zt>xt+1||$t!==ct?(Dt!==0&&me.fillRect(we[ct],mt,Be[ct],xt-mt),ct=$t,mt=Zt,xt=di):di>xt&&(xt=di)}me.fillRect(we[ct],mt,Be[ct],xt-mt)}if(!this._settings.hideCursor&&this._settings.cursorColor){const Re=2*this._settings.pixelRatio|0,Je=Re/2|0,st=this._settings.x[7],ct=this._settings.w[7];me.fillStyle=this._settings.cursorColor;let mt=-100,xt=-100;for(let Dt=0,Jt=this._cursorPositions.length;Dt<Jt;Dt++){const $t=this._cursorPositions[Dt];let ai=_.getVerticalOffsetForLineNumber($t.lineNumber)*z|0;ai<Je?ai=Je:ai+Je>i&&(ai=i-Je);const ii=ai-Je,Zt=ii+Re;ii>xt+1?(Dt!==0&&me.fillRect(st,mt,ct,xt-mt),mt=ii,xt=Zt):Zt>xt&&(xt=Zt)}me.fillRect(st,mt,ct,xt-mt)}this._settings.renderBorder&&this._settings.borderColor&&this._settings.overviewRulerLanes>0&&(me.beginPath(),me.lineWidth=1,me.strokeStyle=this._settings.borderColor,me.moveTo(0,0),me.lineTo(0,i),me.stroke(),me.moveTo(0,0),me.lineTo(e,0),me.stroke())}}var _t=y(96803);class Ft extends ce{constructor(e,i){super(),this._context=e;const r=this._context.configuration.options;this._domNode=(0,E.Z)(document.createElement("canvas")),this._domNode.setClassName(i),this._domNode.setPosition("absolute"),this._domNode.setLayerHinting(!0),this._domNode.setContain("strict"),this._zoneManager=new _t.rW(_=>this._context.viewLayout.getVerticalOffsetForLineNumber(_)),this._zoneManager.setDOMWidth(0),this._zoneManager.setDOMHeight(0),this._zoneManager.setOuterHeight(this._context.viewLayout.getScrollHeight()),this._zoneManager.setLineHeight(r.get(61)),this._zoneManager.setPixelRatio(r.get(131)),this._context.addEventHandler(this)}dispose(){this._context.removeEventHandler(this),super.dispose()}onConfigurationChanged(e){const i=this._context.configuration.options;return e.hasChanged(61)&&(this._zoneManager.setLineHeight(i.get(61)),this._render()),e.hasChanged(131)&&(this._zoneManager.setPixelRatio(i.get(131)),this._domNode.setWidth(this._zoneManager.getDOMWidth()),this._domNode.setHeight(this._zoneManager.getDOMHeight()),this._domNode.domNode.width=this._zoneManager.getCanvasWidth(),this._domNode.domNode.height=this._zoneManager.getCanvasHeight(),this._render()),!0}onFlushed(e){return this._render(),!0}onScrollChanged(e){return e.scrollHeightChanged&&(this._zoneManager.setOuterHeight(e.scrollHeight),this._render()),!0}onZonesChanged(e){return this._render(),!0}getDomNode(){return this._domNode.domNode}setLayout(e){this._domNode.setTop(e.top),this._domNode.setRight(e.right);let i=!1;i=this._zoneManager.setDOMWidth(e.width)||i,i=this._zoneManager.setDOMHeight(e.height)||i,i&&(this._domNode.setWidth(this._zoneManager.getDOMWidth()),this._domNode.setHeight(this._zoneManager.getDOMHeight()),this._domNode.domNode.width=this._zoneManager.getCanvasWidth(),this._domNode.domNode.height=this._zoneManager.getCanvasHeight(),this._render())}setZones(e){this._zoneManager.setZones(e),this._render()}_render(){if(this._zoneManager.getOuterHeight()===0)return!1;const e=this._zoneManager.getCanvasWidth(),i=this._zoneManager.getCanvasHeight(),r=this._zoneManager.resolveColorZones(),_=this._zoneManager.getId2Color(),S=this._domNode.domNode.getContext("2d");return S.clearRect(0,0,e,i),r.length>0&&this._renderOneLane(S,r,_,e),!0}_renderOneLane(e,i,r,_){let S=0,z=0,ie=0;for(const re of i){const le=re.colorId,me=re.from,we=re.to;le!==S?(e.fillRect(0,z,_,ie-z),S=le,e.fillStyle=r[S],z=me,ie=we):ie>=me?ie=Math.max(ie,we):(e.fillRect(0,z,_,ie-z),z=me,ie=we)}e.fillRect(0,z,_,ie-z)}}class ci extends pe{constructor(e){super(e),this.domNode=(0,E.Z)(document.createElement("div")),this.domNode.setAttribute("role","presentation"),this.domNode.setAttribute("aria-hidden","true"),this.domNode.setClassName("view-rulers"),this._renderedRulers=[];const i=this._context.configuration.options;this._rulers=i.get(93),this._typicalHalfwidthCharacterWidth=i.get(46).typicalHalfwidthCharacterWidth}dispose(){super.dispose()}onConfigurationChanged(e){const i=this._context.configuration.options;return this._rulers=i.get(93),this._typicalHalfwidthCharacterWidth=i.get(46).typicalHalfwidthCharacterWidth,!0}onScrollChanged(e){return e.scrollHeightChanged}prepareRender(e){}_ensureRulersCount(){const e=this._renderedRulers.length,i=this._rulers.length;if(e===i)return;if(e<i){const{tabSize:_}=this._context.viewModel.model.getOptions(),S=_;let z=i-e;for(;z>0;){const ie=(0,E.Z)(document.createElement("div"));ie.setClassName("view-ruler"),ie.setWidth(S),this.domNode.appendChild(ie),this._renderedRulers.push(ie),z--}return}let r=e-i;for(;r>0;){const _=this._renderedRulers.pop();this.domNode.removeChild(_),r--}}render(e){this._ensureRulersCount();for(let i=0,r=this._rulers.length;i<r;i++){const _=this._renderedRulers[i],S=this._rulers[i];_.setBoxShadow(S.color?`1px 0 0 0 ${S.color} inset`:""),_.setHeight(Math.min(e.scrollHeight,1e6)),_.setLeft(S.column*this._typicalHalfwidthCharacterWidth)}}}(0,kt.zy)((Le,e)=>{const i=Le.getColor(wt.ik);i&&e.addRule(`.monaco-editor .view-ruler { box-shadow: 1px 0 0 0 ${i} inset; }`)});class Oi extends pe{constructor(e){super(e),this._scrollTop=0,this._width=0,this._updateWidth(),this._shouldShow=!1;const r=this._context.configuration.options.get(94);this._useShadows=r.useShadows,this._domNode=(0,E.Z)(document.createElement("div")),this._domNode.setAttribute("role","presentation"),this._domNode.setAttribute("aria-hidden","true")}dispose(){super.dispose()}_updateShouldShow(){const e=this._useShadows&&this._scrollTop>0;return this._shouldShow!==e?(this._shouldShow=e,!0):!1}getDomNode(){return this._domNode}_updateWidth(){const i=this._context.configuration.options.get(133);i.minimap.renderMinimap===0||i.minimap.minimapWidth>0&&i.minimap.minimapLeft===0?this._width=i.width:this._width=i.width-i.verticalScrollbarWidth}onConfigurationChanged(e){const r=this._context.configuration.options.get(94);return this._useShadows=r.useShadows,this._updateWidth(),this._updateShouldShow(),!0}onScrollChanged(e){return this._scrollTop=e.scrollTop,this._updateShouldShow()}prepareRender(e){}render(e){this._domNode.setWidth(this._width),this._domNode.setClassName(this._shouldShow?"scroll-decoration":"")}}(0,kt.zy)((Le,e)=>{const i=Le.getColor(Li.bXl);i&&e.addRule(`.monaco-editor .scroll-decoration { box-shadow: ${i} 0 6px 6px -6px inset; }`)});class on{constructor(e){this.left=e.left,this.width=e.width,this.startStyle=null,this.endStyle=null}}class gn{constructor(e,i){this.lineNumber=e,this.ranges=i}}function hn(Le){return new on(Le)}function Yi(Le){return new gn(Le.lineNumber,Le.ranges.map(hn))}class Ei extends At{constructor(e){super(),this._previousFrameVisibleRangesWithStyle=[],this._context=e;const i=this._context.configuration.options;this._lineHeight=i.get(61),this._roundedSelection=i.get(92),this._typicalHalfwidthCharacterWidth=i.get(46).typicalHalfwidthCharacterWidth,this._selections=[],this._renderResult=null,this._context.addEventHandler(this)}dispose(){this._context.removeEventHandler(this),this._renderResult=null,super.dispose()}onConfigurationChanged(e){const i=this._context.configuration.options;return this._lineHeight=i.get(61),this._roundedSelection=i.get(92),this._typicalHalfwidthCharacterWidth=i.get(46).typicalHalfwidthCharacterWidth,!0}onCursorStateChanged(e){return this._selections=e.selections.slice(0),!0}onDecorationsChanged(e){return!0}onFlushed(e){return!0}onLinesChanged(e){return!0}onLinesDeleted(e){return!0}onLinesInserted(e){return!0}onScrollChanged(e){return e.scrollTopChanged}onZonesChanged(e){return!0}_visibleRangesHaveGaps(e){for(let i=0,r=e.length;i<r;i++)if(e[i].ranges.length>1)return!0;return!1}_enrichVisibleRangesWithStyle(e,i,r){const _=this._typicalHalfwidthCharacterWidth/4;let S=null,z=null;if(r&&r.length>0&&i.length>0){const ie=i[0].lineNumber;if(ie===e.startLineNumber)for(let le=0;!S&&le<r.length;le++)r[le].lineNumber===ie&&(S=r[le].ranges[0]);const re=i[i.length-1].lineNumber;if(re===e.endLineNumber)for(let le=r.length-1;!z&&le>=0;le--)r[le].lineNumber===re&&(z=r[le].ranges[0]);S&&!S.startStyle&&(S=null),z&&!z.startStyle&&(z=null)}for(let ie=0,re=i.length;ie<re;ie++){const le=i[ie].ranges[0],me=le.left,we=le.left+le.width,Be={top:0,bottom:0},Re={top:0,bottom:0};if(ie>0){const Je=i[ie-1].ranges[0].left,st=i[ie-1].ranges[0].left+i[ie-1].ranges[0].width;An(me-Je)<_?Be.top=2:me>Je&&(Be.top=1),An(we-st)<_?Re.top=2:Je<we&&we<st&&(Re.top=1)}else S&&(Be.top=S.startStyle.top,Re.top=S.endStyle.top);if(ie+1<re){const Je=i[ie+1].ranges[0].left,st=i[ie+1].ranges[0].left+i[ie+1].ranges[0].width;An(me-Je)<_?Be.bottom=2:Je<me&&me<st&&(Be.bottom=1),An(we-st)<_?Re.bottom=2:we<st&&(Re.bottom=1)}else z&&(Be.bottom=z.startStyle.bottom,Re.bottom=z.endStyle.bottom);le.startStyle=Be,le.endStyle=Re}}_getVisibleRangesWithStyle(e,i,r){const S=(i.linesVisibleRangesForRange(e,!0)||[]).map(Yi);return!this._visibleRangesHaveGaps(S)&&this._roundedSelection&&this._enrichVisibleRangesWithStyle(i.visibleRange,S,r),S}_createSelectionPiece(e,i,r,_,S){return'<div class="cslr '+r+'" style="top:'+e.toString()+"px;left:"+_.toString()+"px;width:"+S.toString()+"px;height:"+i+'px;"></div>'}_actualRenderOneSelection(e,i,r,_){if(_.length===0)return;const S=!!_[0].ranges[0].startStyle,z=this._lineHeight.toString(),ie=(this._lineHeight-1).toString(),re=_[0].lineNumber,le=_[_.length-1].lineNumber;for(let me=0,we=_.length;me<we;me++){const Be=_[me],Re=Be.lineNumber,Je=Re-i,st=r&&(Re===le||Re===re)?ie:z,ct=r&&Re===re?1:0;let mt="",xt="";for(let Dt=0,Jt=Be.ranges.length;Dt<Jt;Dt++){const $t=Be.ranges[Dt];if(S){const ii=$t.startStyle,Zt=$t.endStyle;if(ii.top===1||ii.bottom===1){mt+=this._createSelectionPiece(ct,st,Ei.SELECTION_CLASS_NAME,$t.left-Ei.ROUNDED_PIECE_WIDTH,Ei.ROUNDED_PIECE_WIDTH);let di=Ei.EDITOR_BACKGROUND_CLASS_NAME;ii.top===1&&(di+=" "+Ei.SELECTION_TOP_RIGHT),ii.bottom===1&&(di+=" "+Ei.SELECTION_BOTTOM_RIGHT),mt+=this._createSelectionPiece(ct,st,di,$t.left-Ei.ROUNDED_PIECE_WIDTH,Ei.ROUNDED_PIECE_WIDTH)}if(Zt.top===1||Zt.bottom===1){mt+=this._createSelectionPiece(ct,st,Ei.SELECTION_CLASS_NAME,$t.left+$t.width,Ei.ROUNDED_PIECE_WIDTH);let di=Ei.EDITOR_BACKGROUND_CLASS_NAME;Zt.top===1&&(di+=" "+Ei.SELECTION_TOP_LEFT),Zt.bottom===1&&(di+=" "+Ei.SELECTION_BOTTOM_LEFT),mt+=this._createSelectionPiece(ct,st,di,$t.left+$t.width,Ei.ROUNDED_PIECE_WIDTH)}}let ai=Ei.SELECTION_CLASS_NAME;if(S){const ii=$t.startStyle,Zt=$t.endStyle;ii.top===0&&(ai+=" "+Ei.SELECTION_TOP_LEFT),ii.bottom===0&&(ai+=" "+Ei.SELECTION_BOTTOM_LEFT),Zt.top===0&&(ai+=" "+Ei.SELECTION_TOP_RIGHT),Zt.bottom===0&&(ai+=" "+Ei.SELECTION_BOTTOM_RIGHT)}xt+=this._createSelectionPiece(ct,st,ai,$t.left,$t.width)}e[Je][0]+=mt,e[Je][1]+=xt}}prepareRender(e){const i=[],r=e.visibleRange.startLineNumber,_=e.visibleRange.endLineNumber;for(let z=r;z<=_;z++){const ie=z-r;i[ie]=["",""]}const S=[];for(let z=0,ie=this._selections.length;z<ie;z++){const re=this._selections[z];if(re.isEmpty()){S[z]=null;continue}const le=this._getVisibleRangesWithStyle(re,e,this._previousFrameVisibleRangesWithStyle[z]);S[z]=le,this._actualRenderOneSelection(i,r,this._selections.length>1,le)}this._previousFrameVisibleRangesWithStyle=S,this._renderResult=i.map(([z,ie])=>z+ie)}render(e,i){if(!this._renderResult)return"";const r=i-e;return r<0||r>=this._renderResult.length?"":this._renderResult[r]}}Ei.SELECTION_CLASS_NAME="selected-text",Ei.SELECTION_TOP_LEFT="top-left-radius",Ei.SELECTION_BOTTOM_LEFT="bottom-left-radius",Ei.SELECTION_TOP_RIGHT="top-right-radius",Ei.SELECTION_BOTTOM_RIGHT="bottom-right-radius",Ei.EDITOR_BACKGROUND_CLASS_NAME="monaco-editor-background",Ei.ROUNDED_PIECE_WIDTH=10,(0,kt.zy)((Le,e)=>{const i=Le.getColor(Li.seu);i&&e.addRule(`.monaco-editor .focused .selected-text { background-color: ${i}; }`);const r=Le.getColor(Li.tan);r&&e.addRule(`.monaco-editor .selected-text { background-color: ${r}; }`);const _=Le.getColor(Li.rm4);_&&!_.isTransparent()&&e.addRule(`.monaco-editor .view-line span.inline-selected-text { color: ${_}; }`)});function An(Le){return Le<0?-Le:Le}class Xn{constructor(e,i,r,_,S,z){this.top=e,this.left=i,this.width=r,this.height=_,this.textContent=S,this.textContentClassName=z}}class rs{constructor(e){this._context=e;const i=this._context.configuration.options,r=i.get(46);this._cursorStyle=i.get(24),this._lineHeight=i.get(61),this._typicalHalfwidthCharacterWidth=r.typicalHalfwidthCharacterWidth,this._lineCursorWidth=Math.min(i.get(27),this._typicalHalfwidthCharacterWidth),this._isVisible=!0,this._domNode=(0,E.Z)(document.createElement("div")),this._domNode.setClassName(`cursor ${Ut.S}`),this._domNode.setHeight(this._lineHeight),this._domNode.setTop(0),this._domNode.setLeft(0),(0,vt.M)(this._domNode,r),this._domNode.setDisplay("none"),this._position=new Nt.y(1,1),this._lastRenderedContent="",this._renderData=null}getDomNode(){return this._domNode}getPosition(){return this._position}show(){this._isVisible||(this._domNode.setVisibility("inherit"),this._isVisible=!0)}hide(){this._isVisible&&(this._domNode.setVisibility("hidden"),this._isVisible=!1)}onConfigurationChanged(e){const i=this._context.configuration.options,r=i.get(46);return this._cursorStyle=i.get(24),this._lineHeight=i.get(61),this._typicalHalfwidthCharacterWidth=r.typicalHalfwidthCharacterWidth,this._lineCursorWidth=Math.min(i.get(27),this._typicalHalfwidthCharacterWidth),(0,vt.M)(this._domNode,r),!0}onCursorPositionChanged(e){return this._position=e,!0}_getGraphemeAwarePosition(){const{lineNumber:e,column:i}=this._position,r=this._context.viewModel.getLineContent(e),[_,S]=at.m(r,i-1);return[new Nt.y(e,_+1),r.substring(_,S)]}_prepareRender(e){let i="";const[r,_]=this._getGraphemeAwarePosition();if(this._cursorStyle===W.m9.Line||this._cursorStyle===W.m9.LineThin){const Be=e.visibleRangeForPosition(r);if(!Be||Be.outsideRenderedLine)return null;let Re;this._cursorStyle===W.m9.Line?(Re=P.vT(this._lineCursorWidth>0?this._lineCursorWidth:2),Re>2&&(i=_)):Re=P.vT(1);let Je=Be.left;Re>=2&&Je>=1&&(Je-=1);const st=e.getVerticalOffsetForLineNumber(r.lineNumber)-e.bigNumbersDelta;return new Xn(st,Je,Re,this._lineHeight,i,"")}const S=e.linesVisibleRangesForRange(new Pt.Q(r.lineNumber,r.column,r.lineNumber,r.column+_.length),!1);if(!S||S.length===0)return null;const z=S[0];if(z.outsideRenderedLine||z.ranges.length===0)return null;const ie=z.ranges[0],re=_===" "?this._typicalHalfwidthCharacterWidth:ie.width<1?this._typicalHalfwidthCharacterWidth:ie.width;let le="";if(this._cursorStyle===W.m9.Block){const Be=this._context.viewModel.getViewLineData(r.lineNumber);i=_;const Re=Be.tokens.findTokenIndexAtOffset(r.column-1);le=Be.tokens.getClassName(Re)}let me=e.getVerticalOffsetForLineNumber(r.lineNumber)-e.bigNumbersDelta,we=this._lineHeight;return(this._cursorStyle===W.m9.Underline||this._cursorStyle===W.m9.UnderlineThin)&&(me+=this._lineHeight-2,we=2),new Xn(me,ie.left,re,we,i,le)}prepareRender(e){this._renderData=this._prepareRender(e)}render(e){return this._renderData?(this._lastRenderedContent!==this._renderData.textContent&&(this._lastRenderedContent=this._renderData.textContent,this._domNode.domNode.textContent=this._lastRenderedContent),this._domNode.setClassName(`cursor ${Ut.S} ${this._renderData.textContentClassName}`),this._domNode.setDisplay("block"),this._domNode.setTop(this._renderData.top),this._domNode.setLeft(this._renderData.left),this._domNode.setWidth(this._renderData.width),this._domNode.setLineHeight(this._renderData.height),this._domNode.setHeight(this._renderData.height),{domNode:this._domNode.domNode,position:this._position,contentLeft:this._renderData.left,height:this._renderData.height,width:2}):(this._domNode.setDisplay("none"),null)}}class is extends pe{constructor(e){super(e);const i=this._context.configuration.options;this._readOnly=i.get(83),this._cursorBlinking=i.get(22),this._cursorStyle=i.get(24),this._cursorSmoothCaretAnimation=i.get(23),this._selectionIsEmpty=!0,this._isComposingInput=!1,this._isVisible=!1,this._primaryCursor=new rs(this._context),this._secondaryCursors=[],this._renderData=[],this._domNode=(0,E.Z)(document.createElement("div")),this._domNode.setAttribute("role","presentation"),this._domNode.setAttribute("aria-hidden","true"),this._updateDomClassName(),this._domNode.appendChild(this._primaryCursor.getDomNode()),this._startCursorBlinkAnimation=new Se.pc,this._cursorFlatBlinkInterval=new Se.vb,this._blinkingEnabled=!1,this._editorHasFocus=!1,this._updateBlinking()}dispose(){super.dispose(),this._startCursorBlinkAnimation.dispose(),this._cursorFlatBlinkInterval.dispose()}getDomNode(){return this._domNode}onCompositionStart(e){return this._isComposingInput=!0,this._updateBlinking(),!0}onCompositionEnd(e){return this._isComposingInput=!1,this._updateBlinking(),!0}onConfigurationChanged(e){const i=this._context.configuration.options;this._readOnly=i.get(83),this._cursorBlinking=i.get(22),this._cursorStyle=i.get(24),this._cursorSmoothCaretAnimation=i.get(23),this._updateBlinking(),this._updateDomClassName(),this._primaryCursor.onConfigurationChanged(e);for(let r=0,_=this._secondaryCursors.length;r<_;r++)this._secondaryCursors[r].onConfigurationChanged(e);return!0}_onCursorPositionChanged(e,i){if(this._primaryCursor.onCursorPositionChanged(e),this._updateBlinking(),this._secondaryCursors.length<i.length){const r=i.length-this._secondaryCursors.length;for(let _=0;_<r;_++){const S=new rs(this._context);this._domNode.domNode.insertBefore(S.getDomNode().domNode,this._primaryCursor.getDomNode().domNode.nextSibling),this._secondaryCursors.push(S)}}else if(this._secondaryCursors.length>i.length){const r=this._secondaryCursors.length-i.length;for(let _=0;_<r;_++)this._domNode.removeChild(this._secondaryCursors[0].getDomNode()),this._secondaryCursors.splice(0,1)}for(let r=0;r<i.length;r++)this._secondaryCursors[r].onCursorPositionChanged(i[r])}onCursorStateChanged(e){const i=[];for(let _=0,S=e.selections.length;_<S;_++)i[_]=e.selections[_].getPosition();this._onCursorPositionChanged(i[0],i.slice(1));const r=e.selections[0].isEmpty();return this._selectionIsEmpty!==r&&(this._selectionIsEmpty=r,this._updateDomClassName()),!0}onDecorationsChanged(e){return!0}onFlushed(e){return!0}onFocusChanged(e){return this._editorHasFocus=e.isFocused,this._updateBlinking(),!1}onLinesChanged(e){return!0}onLinesDeleted(e){return!0}onLinesInserted(e){return!0}onScrollChanged(e){return!0}onTokensChanged(e){const i=r=>{for(let _=0,S=e.ranges.length;_<S;_++)if(e.ranges[_].fromLineNumber<=r.lineNumber&&r.lineNumber<=e.ranges[_].toLineNumber)return!0;return!1};if(i(this._primaryCursor.getPosition()))return!0;for(const r of this._secondaryCursors)if(i(r.getPosition()))return!0;return!1}onZonesChanged(e){return!0}_getCursorBlinking(){return this._isComposingInput||!this._editorHasFocus?0:this._readOnly?5:this._cursorBlinking}_updateBlinking(){this._startCursorBlinkAnimation.cancel(),this._cursorFlatBlinkInterval.cancel();const e=this._getCursorBlinking(),i=e===0,r=e===5;i?this._hide():this._show(),this._blinkingEnabled=!1,this._updateDomClassName(),!i&&!r&&(e===1?this._cursorFlatBlinkInterval.cancelAndSet(()=>{this._isVisible?this._hide():this._show()},is.BLINK_INTERVAL):this._startCursorBlinkAnimation.setIfNotSet(()=>{this._blinkingEnabled=!0,this._updateDomClassName()},is.BLINK_INTERVAL))}_updateDomClassName(){this._domNode.setClassName(this._getClassName())}_getClassName(){let e="cursors-layer";switch(this._selectionIsEmpty||(e+=" has-selection"),this._cursorStyle){case W.m9.Line:e+=" cursor-line-style";break;case W.m9.Block:e+=" cursor-block-style";break;case W.m9.Underline:e+=" cursor-underline-style";break;case W.m9.LineThin:e+=" cursor-line-thin-style";break;case W.m9.BlockOutline:e+=" cursor-block-outline-style";break;case W.m9.UnderlineThin:e+=" cursor-underline-thin-style";break;default:e+=" cursor-line-style"}if(this._blinkingEnabled)switch(this._getCursorBlinking()){case 1:e+=" cursor-blink";break;case 2:e+=" cursor-smooth";break;case 3:e+=" cursor-phase";break;case 4:e+=" cursor-expand";break;case 5:e+=" cursor-solid";break;default:e+=" cursor-solid"}else e+=" cursor-solid";return this._cursorSmoothCaretAnimation&&(e+=" cursor-smooth-caret-animation"),e}_show(){this._primaryCursor.show();for(let e=0,i=this._secondaryCursors.length;e<i;e++)this._secondaryCursors[e].show();this._isVisible=!0}_hide(){this._primaryCursor.hide();for(let e=0,i=this._secondaryCursors.length;e<i;e++)this._secondaryCursors[e].hide();this._isVisible=!1}prepareRender(e){this._primaryCursor.prepareRender(e);for(let i=0,r=this._secondaryCursors.length;i<r;i++)this._secondaryCursors[i].prepareRender(e)}render(e){const i=[];let r=0;const _=this._primaryCursor.render(e);_&&(i[r++]=_);for(let S=0,z=this._secondaryCursors.length;S<z;S++){const ie=this._secondaryCursors[S].render(e);ie&&(i[r++]=ie)}this._renderData=i}getLastRenderData(){return this._renderData}}is.BLINK_INTERVAL=500,(0,kt.zy)((Le,e)=>{const i=Le.getColor(wt.D0);if(i){let r=Le.getColor(wt.kM);r||(r=i.opposite()),e.addRule(`.monaco-editor .inputarea.ime-input { caret-color: ${i}; }`),e.addRule(`.monaco-editor .cursors-layer .cursor { background-color: ${i}; border-color: ${i}; color: ${r}; }`),(0,Wt.Bb)(Le.type)&&e.addRule(`.monaco-editor .cursors-layer.has-selection .cursor { border-left: 1px solid ${r}; border-right: 1px solid ${r}; }`)}});const xs=()=>{throw new Error("Invalid change accessor")};class ys extends pe{constructor(e){super(e);const i=this._context.configuration.options,r=i.get(133);this._lineHeight=i.get(61),this._contentWidth=r.contentWidth,this._contentLeft=r.contentLeft,this.domNode=(0,E.Z)(document.createElement("div")),this.domNode.setClassName("view-zones"),this.domNode.setPosition("absolute"),this.domNode.setAttribute("role","presentation"),this.domNode.setAttribute("aria-hidden","true"),this.marginDomNode=(0,E.Z)(document.createElement("div")),this.marginDomNode.setClassName("margin-view-zones"),this.marginDomNode.setPosition("absolute"),this.marginDomNode.setAttribute("role","presentation"),this.marginDomNode.setAttribute("aria-hidden","true"),this._zones={}}dispose(){super.dispose(),this._zones={}}_recomputeWhitespacesProps(){const e=this._context.viewLayout.getWhitespaces(),i=new Map;for(const _ of e)i.set(_.id,_);let r=!1;return this._context.viewModel.changeWhitespace(_=>{const S=Object.keys(this._zones);for(let z=0,ie=S.length;z<ie;z++){const re=S[z],le=this._zones[re],me=this._computeWhitespaceProps(le.delegate);le.isInHiddenArea=me.isInHiddenArea;const we=i.get(re);we&&(we.afterLineNumber!==me.afterViewLineNumber||we.height!==me.heightInPx)&&(_.changeOneWhitespace(re,me.afterViewLineNumber,me.heightInPx),this._safeCallOnComputedHeight(le.delegate,me.heightInPx),r=!0)}}),r}onConfigurationChanged(e){const i=this._context.configuration.options,r=i.get(133);return this._lineHeight=i.get(61),this._contentWidth=r.contentWidth,this._contentLeft=r.contentLeft,e.hasChanged(61)&&this._recomputeWhitespacesProps(),!0}onLineMappingChanged(e){return this._recomputeWhitespacesProps()}onLinesDeleted(e){return!0}onScrollChanged(e){return e.scrollTopChanged||e.scrollWidthChanged}onZonesChanged(e){return!0}onLinesInserted(e){return!0}_getZoneOrdinal(e){return typeof e.afterColumn<"u"?e.afterColumn:1e4}_computeWhitespaceProps(e){if(e.afterLineNumber===0)return{isInHiddenArea:!1,afterViewLineNumber:0,heightInPx:this._heightInPixels(e),minWidthInPx:this._minWidthInPixels(e)};let i;if(typeof e.afterColumn<"u")i=this._context.viewModel.model.validatePosition({lineNumber:e.afterLineNumber,column:e.afterColumn});else{const z=this._context.viewModel.model.validatePosition({lineNumber:e.afterLineNumber,column:1}).lineNumber;i=new Nt.y(z,this._context.viewModel.model.getLineMaxColumn(z))}let r;i.column===this._context.viewModel.model.getLineMaxColumn(i.lineNumber)?r=this._context.viewModel.model.validatePosition({lineNumber:i.lineNumber+1,column:1}):r=this._context.viewModel.model.validatePosition({lineNumber:i.lineNumber,column:i.column+1});const _=this._context.viewModel.coordinatesConverter.convertModelPositionToViewPosition(i,e.afterColumnAffinity),S=this._context.viewModel.coordinatesConverter.modelPositionIsVisible(r);return{isInHiddenArea:!S,afterViewLineNumber:_.lineNumber,heightInPx:S?this._heightInPixels(e):0,minWidthInPx:this._minWidthInPixels(e)}}changeViewZones(e){let i=!1;return this._context.viewModel.changeWhitespace(r=>{const _={addZone:S=>(i=!0,this._addZone(r,S)),removeZone:S=>{S&&(i=this._removeZone(r,S)||i)},layoutZone:S=>{S&&(i=this._layoutZone(r,S)||i)}};Ss(e,_),_.addZone=xs,_.removeZone=xs,_.layoutZone=xs}),i}_addZone(e,i){const r=this._computeWhitespaceProps(i),S={whitespaceId:e.insertWhitespace(r.afterViewLineNumber,this._getZoneOrdinal(i),r.heightInPx,r.minWidthInPx),delegate:i,isInHiddenArea:r.isInHiddenArea,isVisible:!1,domNode:(0,E.Z)(i.domNode),marginDomNode:i.marginDomNode?(0,E.Z)(i.marginDomNode):null};return this._safeCallOnComputedHeight(S.delegate,r.heightInPx),S.domNode.setPosition("absolute"),S.domNode.domNode.style.width="100%",S.domNode.setDisplay("none"),S.domNode.setAttribute("monaco-view-zone",S.whitespaceId),this.domNode.appendChild(S.domNode),S.marginDomNode&&(S.marginDomNode.setPosition("absolute"),S.marginDomNode.domNode.style.width="100%",S.marginDomNode.setDisplay("none"),S.marginDomNode.setAttribute("monaco-view-zone",S.whitespaceId),this.marginDomNode.appendChild(S.marginDomNode)),this._zones[S.whitespaceId]=S,this.setShouldRender(),S.whitespaceId}_removeZone(e,i){if(this._zones.hasOwnProperty(i)){const r=this._zones[i];return delete this._zones[i],e.removeWhitespace(r.whitespaceId),r.domNode.removeAttribute("monaco-visible-view-zone"),r.domNode.removeAttribute("monaco-view-zone"),r.domNode.domNode.parentNode.removeChild(r.domNode.domNode),r.marginDomNode&&(r.marginDomNode.removeAttribute("monaco-visible-view-zone"),r.marginDomNode.removeAttribute("monaco-view-zone"),r.marginDomNode.domNode.parentNode.removeChild(r.marginDomNode.domNode)),this.setShouldRender(),!0}return!1}_layoutZone(e,i){if(this._zones.hasOwnProperty(i)){const r=this._zones[i],_=this._computeWhitespaceProps(r.delegate);return r.isInHiddenArea=_.isInHiddenArea,e.changeOneWhitespace(r.whitespaceId,_.afterViewLineNumber,_.heightInPx),this._safeCallOnComputedHeight(r.delegate,_.heightInPx),this.setShouldRender(),!0}return!1}shouldSuppressMouseDownOnViewZone(e){return this._zones.hasOwnProperty(e)?!!this._zones[e].delegate.suppressMouseDown:!1}_heightInPixels(e){return typeof e.heightInPx=="number"?e.heightInPx:typeof e.heightInLines=="number"?this._lineHeight*e.heightInLines:this._lineHeight}_minWidthInPixels(e){return typeof e.minWidthInPx=="number"?e.minWidthInPx:0}_safeCallOnComputedHeight(e,i){if(typeof e.onComputedHeight=="function")try{e.onComputedHeight(i)}catch(r){(0,B.dz)(r)}}_safeCallOnDomNodeTop(e,i){if(typeof e.onDomNodeTop=="function")try{e.onDomNodeTop(i)}catch(r){(0,B.dz)(r)}}prepareRender(e){}render(e){const i=e.viewportData.whitespaceViewportData,r={};let _=!1;for(const z of i)this._zones[z.id].isInHiddenArea||(r[z.id]=z,_=!0);const S=Object.keys(this._zones);for(let z=0,ie=S.length;z<ie;z++){const re=S[z],le=this._zones[re];let me=0,we=0,Be="none";r.hasOwnProperty(re)?(me=r[re].verticalOffset-e.bigNumbersDelta,we=r[re].height,Be="block",le.isVisible||(le.domNode.setAttribute("monaco-visible-view-zone","true"),le.isVisible=!0),this._safeCallOnDomNodeTop(le.delegate,e.getScrolledTopFromAbsoluteTop(r[re].verticalOffset))):(le.isVisible&&(le.domNode.removeAttribute("monaco-visible-view-zone"),le.isVisible=!1),this._safeCallOnDomNodeTop(le.delegate,e.getScrolledTopFromAbsoluteTop(-1e6))),le.domNode.setTop(me),le.domNode.setHeight(we),le.domNode.setDisplay(Be),le.marginDomNode&&(le.marginDomNode.setTop(me),le.marginDomNode.setHeight(we),le.marginDomNode.setDisplay(Be))}_&&(this.domNode.setWidth(Math.max(e.scrollWidth,this._contentWidth)),this.marginDomNode.setWidth(this._contentLeft))}}function Ss(Le,e){try{return Le(e)}catch(i){(0,B.dz)(i)}}class Fs{constructor(e){this._theme=e}get type(){return this._theme.type}get value(){return this._theme}update(e){this._theme=e}getColor(e){return this._theme.getColor(e)}}class ns{constructor(e,i,r){this.configuration=e,this.theme=new Fs(i),this.viewModel=r,this.viewLayout=r.viewLayout}addEventHandler(e){this.viewModel.addViewEventHandler(e)}removeEventHandler(e){this.viewModel.removeViewEventHandler(e)}}class Zs{constructor(e,i,r,_){this.selections=e,this.startLineNumber=i.startLineNumber|0,this.endLineNumber=i.endLineNumber|0,this.relativeVerticalOffset=i.relativeVerticalOffset,this.bigNumbersDelta=i.bigNumbersDelta|0,this.whitespaceViewportData=r,this._model=_,this.visibleRange=new Pt.Q(i.startLineNumber,this._model.getLineMinColumn(i.startLineNumber),i.endLineNumber,this._model.getLineMaxColumn(i.endLineNumber))}getViewLineRenderingData(e){return this._model.getViewportViewLineRenderingData(this.visibleRange,e)}getDecorationsInViewport(){return this._model.getDecorationsInViewport(this.visibleRange)}}class Ts extends pe{constructor(e){super(e),this.blocks=[],this.contentWidth=-1,this.domNode=(0,E.Z)(document.createElement("div")),this.domNode.setAttribute("role","presentation"),this.domNode.setAttribute("aria-hidden","true"),this.domNode.setClassName("blockDecorations-container"),this.update()}update(){let e=!1;const r=this._context.configuration.options.get(133),_=r.contentWidth-r.verticalScrollbarWidth;return this.contentWidth!==_&&(this.contentWidth=_,e=!0),e}dispose(){super.dispose()}onConfigurationChanged(e){return this.update()}onScrollChanged(e){return e.scrollTopChanged||e.scrollLeftChanged}onDecorationsChanged(e){return!0}onZonesChanged(e){return!0}prepareRender(e){}render(e){let i=0;const r=e.getDecorationsInViewport();for(const _ of r){if(!_.options.blockClassName)continue;let S=this.blocks[i];S||(S=this.blocks[i]=(0,E.Z)(document.createElement("div")),this.domNode.appendChild(S));const z=e.getVerticalOffsetForLineNumber(_.range.startLineNumber),ie=e.getVerticalOffsetForLineNumber(_.range.endLineNumber+1);S.setClassName("blockDecorations-block "+_.options.blockClassName),S.setLeft(e.scrollLeft),S.setWidth(this.contentWidth),S.setTop(z),S.setHeight(ie-z),i++}for(let _=i;_<this.blocks.length;_++)this.blocks[_].domNode.remove();this.blocks.length=i}}class Ys extends ce{constructor(e,i,r,_,S,z){super(),this._selections=[new ue.L(1,1,1,1)],this._renderAnimationFrame=null;const ie=new Ci(i,_,S,e);this._context=new ns(i,r,_),this._context.addEventHandler(this),this._viewParts=[],this._textAreaHandler=new ki(this._context,ie,this._createTextAreaHandlerHelper()),this._viewParts.push(this._textAreaHandler),this._linesContent=(0,E.Z)(document.createElement("div")),this._linesContent.setClassName("lines-content monaco-editor-background"),this._linesContent.setPosition("absolute"),this.domNode=(0,E.Z)(document.createElement("div")),this.domNode.setClassName(this._getEditorClassName()),this.domNode.setAttribute("role","code"),this._overflowGuardContainer=(0,E.Z)(document.createElement("div")),be.write(this._overflowGuardContainer,3),this._overflowGuardContainer.setClassName("overflow-guard"),this._scrollbar=new Rn(this._context,this._linesContent,this.domNode,this._overflowGuardContainer),this._viewParts.push(this._scrollbar),this._viewLines=new yn(this._context,this._linesContent),this._viewZones=new ys(this._context),this._viewParts.push(this._viewZones);const re=new lt(this._context);this._viewParts.push(re);const le=new Oi(this._context);this._viewParts.push(le);const me=new Qi(this._context);this._viewParts.push(me),me.addDynamicOverlay(new Sn(this._context)),me.addDynamicOverlay(new Ei(this._context)),me.addDynamicOverlay(new Bn(this._context)),me.addDynamicOverlay(new en(this._context));const we=new Vi(this._context);this._viewParts.push(we),we.addDynamicOverlay(new cn(this._context)),we.addDynamicOverlay(new Tn(this._context)),we.addDynamicOverlay(new sn(this._context)),we.addDynamicOverlay(new On(this._context)),we.addDynamicOverlay(new Ct(this._context));const Be=new Gt(this._context);Be.getDomNode().appendChild(this._viewZones.marginDomNode),Be.getDomNode().appendChild(we.getDomNode()),this._viewParts.push(Be),this._contentWidgets=new Ji(this._context,this.domNode),this._viewParts.push(this._contentWidgets),this._viewCursors=new is(this._context),this._viewParts.push(this._viewCursors),this._overlayWidgets=new et(this._context),this._viewParts.push(this._overlayWidgets);const Re=new ci(this._context);this._viewParts.push(Re);const Je=new Ts(this._context);this._viewParts.push(Je);const st=new Ne(this._context);if(this._viewParts.push(st),re){const ct=this._scrollbar.getOverviewRulerLayoutInfo();ct.parent.insertBefore(re.getDomNode(),ct.insertBefore)}this._linesContent.appendChild(me.getDomNode()),this._linesContent.appendChild(Re.domNode),this._linesContent.appendChild(Je.domNode),this._linesContent.appendChild(this._viewZones.domNode),this._linesContent.appendChild(this._viewLines.getDomNode()),this._linesContent.appendChild(this._contentWidgets.domNode),this._linesContent.appendChild(this._viewCursors.getDomNode()),this._overflowGuardContainer.appendChild(Be.getDomNode()),this._overflowGuardContainer.appendChild(this._scrollbar.getDomNode()),this._overflowGuardContainer.appendChild(le.getDomNode()),this._overflowGuardContainer.appendChild(this._textAreaHandler.textArea),this._overflowGuardContainer.appendChild(this._textAreaHandler.textAreaCover),this._overflowGuardContainer.appendChild(this._overlayWidgets.getDomNode()),this._overflowGuardContainer.appendChild(st.getDomNode()),this.domNode.appendChild(this._overflowGuardContainer),z?z.appendChild(this._contentWidgets.overflowingContentWidgetsDomNode.domNode):this.domNode.appendChild(this._contentWidgets.overflowingContentWidgetsDomNode),this._applyLayout(),this._pointerHandler=this._register(new nt(this._context,ie,this._createPointerHandlerHelper()))}_flushAccumulatedAndRenderNow(){this._renderNow()}_createPointerHandlerHelper(){return{viewDomNode:this.domNode.domNode,linesContentDomNode:this._linesContent.domNode,viewLinesDomNode:this._viewLines.getDomNode().domNode,focusTextArea:()=>{this.focus()},dispatchTextAreaEvent:e=>{this._textAreaHandler.textArea.domNode.dispatchEvent(e)},getLastRenderData:()=>{const e=this._viewCursors.getLastRenderData()||[],i=this._textAreaHandler.getLastRenderData();return new fe(e,i)},shouldSuppressMouseDownOnViewZone:e=>this._viewZones.shouldSuppressMouseDownOnViewZone(e),shouldSuppressMouseDownOnWidget:e=>this._contentWidgets.shouldSuppressMouseDownOnWidget(e),getPositionFromDOMInfo:(e,i)=>(this._flushAccumulatedAndRenderNow(),this._viewLines.getPositionFromDOMInfo(e,i)),visibleRangeForPosition:(e,i)=>(this._flushAccumulatedAndRenderNow(),this._viewLines.visibleRangeForPosition(new Nt.y(e,i))),getLineWidth:e=>(this._flushAccumulatedAndRenderNow(),this._viewLines.getLineWidth(e))}}_createTextAreaHandlerHelper(){return{visibleRangeForPosition:e=>(this._flushAccumulatedAndRenderNow(),this._viewLines.visibleRangeForPosition(e))}}_applyLayout(){const i=this._context.configuration.options.get(133);this.domNode.setWidth(i.width),this.domNode.setHeight(i.height),this._overflowGuardContainer.setWidth(i.width),this._overflowGuardContainer.setHeight(i.height),this._linesContent.setWidth(1e6),this._linesContent.setHeight(1e6)}_getEditorClassName(){const e=this._textAreaHandler.isFocused()?" focused":"";return this._context.configuration.options.get(130)+" "+(0,kt.Pz)(this._context.theme.type)+e}handleEvents(e){super.handleEvents(e),this._scheduleRender()}onConfigurationChanged(e){return this.domNode.setClassName(this._getEditorClassName()),this._applyLayout(),!1}onCursorStateChanged(e){return this._selections=e.selections,!1}onFocusChanged(e){return this.domNode.setClassName(this._getEditorClassName()),!1}onThemeChanged(e){return this._context.theme.update(e.theme),this.domNode.setClassName(this._getEditorClassName()),!1}dispose(){this._renderAnimationFrame!==null&&(this._renderAnimationFrame.dispose(),this._renderAnimationFrame=null),this._contentWidgets.overflowingContentWidgetsDomNode.domNode.remove(),this._context.removeEventHandler(this),this._viewLines.dispose();for(const e of this._viewParts)e.dispose();super.dispose()}_scheduleRender(){this._renderAnimationFrame===null&&(this._renderAnimationFrame=P.Oq(this._onRenderScheduled.bind(this),100))}_onRenderScheduled(){this._renderAnimationFrame=null,this._flushAccumulatedAndRenderNow()}_renderNow(){Un(()=>this._actualRender())}_getViewPartsToRender(){const e=[];let i=0;for(const r of this._viewParts)r.shouldRender()&&(e[i++]=r);return e}_actualRender(){if(!P.qD(this.domNode.domNode))return;let e=this._getViewPartsToRender();if(!this._viewLines.shouldRender()&&e.length===0)return;const i=this._context.viewLayout.getLinesViewportData();this._context.viewModel.setViewport(i.startLineNumber,i.endLineNumber,i.centeredLineNumber);const r=new Zs(this._selections,i,this._context.viewLayout.getWhitespaceViewportData(),this._context.viewModel);this._contentWidgets.shouldRender()&&this._contentWidgets.onBeforeRender(r),this._viewLines.shouldRender()&&(this._viewLines.renderText(r),this._viewLines.onDidRender(),e=this._getViewPartsToRender());const _=new ke(this._context.viewLayout,r,this._viewLines);for(const S of e)S.prepareRender(_);for(const S of e)S.render(_),S.onDidRender()}delegateVerticalScrollbarPointerDown(e){this._scrollbar.delegateVerticalScrollbarPointerDown(e)}restoreState(e){this._context.viewModel.viewLayout.setScrollPosition({scrollTop:e.scrollTop},1),this._context.viewModel.tokenizeViewport(),this._renderNow(),this._viewLines.updateLineWidths(),this._context.viewModel.viewLayout.setScrollPosition({scrollLeft:e.scrollLeft},1)}getOffsetForColumn(e,i){const r=this._context.viewModel.model.validatePosition({lineNumber:e,column:i}),_=this._context.viewModel.coordinatesConverter.convertModelPositionToViewPosition(r);this._flushAccumulatedAndRenderNow();const S=this._viewLines.visibleRangeForPosition(new Nt.y(_.lineNumber,_.column));return S?S.left:-1}getTargetAtClientPoint(e,i){const r=this._pointerHandler.getTargetAtClientPoint(e,i);return r?mi.convertViewToModelMouseTarget(r,this._context.viewModel.coordinatesConverter):null}createOverviewRuler(e){return new Ft(this._context,e)}change(e){this._viewZones.changeViewZones(e),this._scheduleRender()}render(e,i){if(i){this._viewLines.forceShouldRender();for(const r of this._viewParts)r.forceShouldRender()}e?this._flushAccumulatedAndRenderNow():this._scheduleRender()}focus(){this._textAreaHandler.focusTextArea()}isFocused(){return this._textAreaHandler.isFocused()}setAriaOptions(e){this._textAreaHandler.setAriaOptions(e)}addContentWidget(e){this._contentWidgets.addWidget(e.widget),this.layoutContentWidget(e),this._scheduleRender()}layoutContentWidget(e){var i,r;let _=e.position&&e.position.range||null;if(_===null){const z=e.position?e.position.position:null;z!==null&&(_=new Pt.Q(z.lineNumber,z.column,z.lineNumber,z.column))}const S=e.position?e.position.preference:null;this._contentWidgets.setWidgetPosition(e.widget,_,S,(r=(i=e.position)===null||i===void 0?void 0:i.positionAffinity)!==null&&r!==void 0?r:null),this._scheduleRender()}removeContentWidget(e){this._contentWidgets.removeWidget(e.widget),this._scheduleRender()}addOverlayWidget(e){this._overlayWidgets.addWidget(e.widget),this.layoutOverlayWidget(e),this._scheduleRender()}layoutOverlayWidget(e){const i=e.position?e.position.preference:null;this._overlayWidgets.setWidgetPosition(e.widget,i)&&this._scheduleRender()}removeOverlayWidget(e){this._overlayWidgets.removeWidget(e.widget),this._scheduleRender()}}function Un(Le){try{return Le()}catch(e){(0,B.dz)(e)}}var rn=y(29895);class hs{constructor(e){this._selTrackedRange=null,this._trackSelection=!0,this._setState(e,new rn.mG(new Pt.Q(1,1,1,1),0,new Nt.y(1,1),0),new rn.mG(new Pt.Q(1,1,1,1),0,new Nt.y(1,1),0))}dispose(e){this._removeTrackedRange(e)}startTrackingSelection(e){this._trackSelection=!0,this._updateTrackedRange(e)}stopTrackingSelection(e){this._trackSelection=!1,this._removeTrackedRange(e)}_updateTrackedRange(e){this._trackSelection&&(this._selTrackedRange=e.model._setTrackedRange(this._selTrackedRange,this.modelState.selection,0))}_removeTrackedRange(e){this._selTrackedRange=e.model._setTrackedRange(this._selTrackedRange,null,0)}asCursorState(){return new rn.MF(this.modelState,this.viewState)}readSelectionFromMarkers(e){const i=e.model._getTrackedRange(this._selTrackedRange);return ue.L.fromRange(i,this.modelState.selection.getDirection())}ensureValidState(e){this._setState(e,this.modelState,this.viewState)}setState(e,i,r){this._setState(e,i,r)}static _validatePositionWithCache(e,i,r,_){return i.equals(r)?_:e.normalizePosition(i,2)}static _validateViewState(e,i){const r=i.position,_=i.selectionStart.getStartPosition(),S=i.selectionStart.getEndPosition(),z=e.normalizePosition(r,2),ie=this._validatePositionWithCache(e,_,r,z),re=this._validatePositionWithCache(e,S,_,ie);return r.equals(z)&&_.equals(ie)&&S.equals(re)?i:new rn.mG(Pt.Q.fromPositions(ie,re),i.selectionStartLeftoverVisibleColumns+_.column-ie.column,z,i.leftoverVisibleColumns+r.column-z.column)}_setState(e,i,r){if(r&&(r=hs._validateViewState(e.viewModel,r)),i){const _=e.model.validateRange(i.selectionStart),S=i.selectionStart.equalsRange(_)?i.selectionStartLeftoverVisibleColumns:0,z=e.model.validatePosition(i.position),ie=i.position.equals(z)?i.leftoverVisibleColumns:0;i=new rn.mG(_,S,z,ie)}else{if(!r)return;const _=e.model.validateRange(e.coordinatesConverter.convertViewRangeToModelRange(r.selectionStart)),S=e.model.validatePosition(e.coordinatesConverter.convertViewPositionToModelPosition(r.position));i=new rn.mG(_,r.selectionStartLeftoverVisibleColumns,S,r.leftoverVisibleColumns)}if(r){const _=e.coordinatesConverter.validateViewRange(r.selectionStart,i.selectionStart),S=e.coordinatesConverter.validateViewPosition(r.position,i.position);r=new rn.mG(_,i.selectionStartLeftoverVisibleColumns,S,i.leftoverVisibleColumns)}else{const _=e.coordinatesConverter.convertModelPositionToViewPosition(new Nt.y(i.selectionStart.startLineNumber,i.selectionStart.startColumn)),S=e.coordinatesConverter.convertModelPositionToViewPosition(new Nt.y(i.selectionStart.endLineNumber,i.selectionStart.endColumn)),z=new Pt.Q(_.lineNumber,_.column,S.lineNumber,S.column),ie=e.coordinatesConverter.convertModelPositionToViewPosition(i.position);r=new rn.mG(z,i.selectionStartLeftoverVisibleColumns,ie,i.leftoverVisibleColumns)}this.modelState=i,this.viewState=r,this._updateTrackedRange(e)}}class po{constructor(e){this.context=e,this.cursors=[new hs(e)],this.lastAddedCursorIndex=0}dispose(){for(const e of this.cursors)e.dispose(this.context)}startTrackingSelections(){for(const e of this.cursors)e.startTrackingSelection(this.context)}stopTrackingSelections(){for(const e of this.cursors)e.stopTrackingSelection(this.context)}updateContext(e){this.context=e}ensureValidState(){for(const e of this.cursors)e.ensureValidState(this.context)}readSelectionFromMarkers(){return this.cursors.map(e=>e.readSelectionFromMarkers(this.context))}getAll(){return this.cursors.map(e=>e.asCursorState())}getViewPositions(){return this.cursors.map(e=>e.viewState.position)}getTopMostViewPosition(){return(0,h.Ly)(this.cursors,(0,h.VE)(e=>e.viewState.position,Nt.y.compare)).viewState.position}getBottomMostViewPosition(){return(0,h.Jw)(this.cursors,(0,h.VE)(e=>e.viewState.position,Nt.y.compare)).viewState.position}getSelections(){return this.cursors.map(e=>e.modelState.selection)}getViewSelections(){return this.cursors.map(e=>e.viewState.selection)}setSelections(e){this.setStates(rn.MF.fromModelSelections(e))}getPrimaryCursor(){return this.cursors[0].asCursorState()}setStates(e){e!==null&&(this.cursors[0].setState(this.context,e[0].modelState,e[0].viewState),this._setSecondaryStates(e.slice(1)))}_setSecondaryStates(e){const i=this.cursors.length-1,r=e.length;if(i<r){const _=r-i;for(let S=0;S<_;S++)this._addSecondaryCursor()}else if(i>r){const _=i-r;for(let S=0;S<_;S++)this._removeSecondaryCursor(this.cursors.length-2)}for(let _=0;_<r;_++)this.cursors[_+1].setState(this.context,e[_].modelState,e[_].viewState)}killSecondaryCursors(){this._setSecondaryStates([])}_addSecondaryCursor(){this.cursors.push(new hs(this.context)),this.lastAddedCursorIndex=this.cursors.length-1}getLastAddedCursorIndex(){return this.cursors.length===1||this.lastAddedCursorIndex===0?0:this.lastAddedCursorIndex}_removeSecondaryCursor(e){this.lastAddedCursorIndex>=e+1&&this.lastAddedCursorIndex--,this.cursors[e+1].dispose(this.context),this.cursors.splice(e+1,1)}normalize(){if(this.cursors.length===1)return;const e=this.cursors.slice(0),i=[];for(let r=0,_=e.length;r<_;r++)i.push({index:r,selection:e[r].modelState.selection});i.sort((0,h.VE)(r=>r.selection,Pt.Q.compareRangesUsingStarts));for(let r=0;r<i.length-1;r++){const _=i[r],S=i[r+1],z=_.selection,ie=S.selection;if(!this.context.cursorConfig.multiCursorMergeOverlapping)continue;let re;if(ie.isEmpty()||z.isEmpty()?re=ie.getStartPosition().isBeforeOrEqual(z.getEndPosition()):re=ie.getStartPosition().isBefore(z.getEndPosition()),re){const le=_.index<S.index?r:r+1,me=_.index<S.index?r+1:r,we=i[me].index,Be=i[le].index,Re=i[me].selection,Je=i[le].selection;if(!Re.equalsSelection(Je)){const st=Re.plusRange(Je),ct=Re.selectionStartLineNumber===Re.startLineNumber&&Re.selectionStartColumn===Re.startColumn,mt=Je.selectionStartLineNumber===Je.startLineNumber&&Je.selectionStartColumn===Je.startColumn;let xt;we===this.lastAddedCursorIndex?(xt=ct,this.lastAddedCursorIndex=Be):xt=mt;let Dt;xt?Dt=new ue.L(st.startLineNumber,st.startColumn,st.endLineNumber,st.endColumn):Dt=new ue.L(st.endLineNumber,st.endColumn,st.startLineNumber,st.startColumn),i[le].selection=Dt;const Jt=rn.MF.fromModelSelection(Dt);e[Be].setState(this.context,Jt.modelState,Jt.viewState)}for(const st of i)st.index>we&&st.index--;e.splice(we,1),i.splice(me,1),this._removeSecondaryCursor(we-1),r--}}}}class gs{constructor(e,i,r,_){this._cursorContextBrand=void 0,this.model=e,this.viewModel=i,this.coordinatesConverter=r,this.cursorConfig=_}}var Uo=y(97666),es=y(61710),us=y(83455);class Ls{constructor(){this.type=0}}class _r{constructor(){this.type=1}}class vr{constructor(e){this.type=2,this._source=e}hasChanged(e){return this._source.hasChanged(e)}}class Cr{constructor(e,i){this.type=3,this.selections=e,this.modelSelections=i}}class vs{constructor(e){this.type=4,e?(this.affectsMinimap=e.affectsMinimap,this.affectsOverviewRuler=e.affectsOverviewRuler):(this.affectsMinimap=!0,this.affectsOverviewRuler=!0)}}class Ms{constructor(){this.type=5}}class Gn{constructor(e){this.type=6,this.isFocused=e}}class Xs{constructor(){this.type=7}}class Ns{constructor(){this.type=8}}class Ws{constructor(e,i){this.fromLineNumber=e,this.count=i,this.type=9}}class Js{constructor(e,i){this.type=10,this.fromLineNumber=e,this.toLineNumber=i}}class qs{constructor(e,i){this.type=11,this.fromLineNumber=e,this.toLineNumber=i}}class Vs{constructor(e,i,r,_,S,z,ie){this.source=e,this.minimalReveal=i,this.range=r,this.selections=_,this.verticalType=S,this.revealHorizontal=z,this.scrollType=ie,this.type=12}}class _o{constructor(e){this.type=13,this.scrollWidth=e.scrollWidth,this.scrollLeft=e.scrollLeft,this.scrollHeight=e.scrollHeight,this.scrollTop=e.scrollTop,this.scrollWidthChanged=e.scrollWidthChanged,this.scrollLeftChanged=e.scrollLeftChanged,this.scrollHeightChanged=e.scrollHeightChanged,this.scrollTopChanged=e.scrollTopChanged}}class jo{constructor(e){this.theme=e,this.type=14}}class Ko{constructor(e){this.type=15,this.ranges=e}}class vo{constructor(){this.type=16}}class $o{constructor(){this.type=17}}class Go extends p.jG{constructor(){super(),this._onEvent=this._register(new T.vl),this.onEvent=this._onEvent.event,this._eventHandlers=[],this._viewEventQueue=null,this._isConsumingViewEventQueue=!1,this._collector=null,this._collectorCnt=0,this._outgoingEvents=[]}emitOutgoingEvent(e){this._addOutgoingEvent(e),this._emitOutgoingEvents()}_addOutgoingEvent(e){for(let i=0,r=this._outgoingEvents.length;i<r;i++){const _=this._outgoingEvents[i].kind===e.kind?this._outgoingEvents[i].attemptToMerge(e):null;if(_){this._outgoingEvents[i]=_;return}}this._outgoingEvents.push(e)}_emitOutgoingEvents(){for(;this._outgoingEvents.length>0;){if(this._collector||this._isConsumingViewEventQueue)return;const e=this._outgoingEvents.shift();e.isNoOp()||this._onEvent.fire(e)}}addViewEventHandler(e){for(let i=0,r=this._eventHandlers.length;i<r;i++)this._eventHandlers[i]===e&&console.warn("Detected duplicate listener in ViewEventDispatcher",e);this._eventHandlers.push(e)}removeViewEventHandler(e){for(let i=0;i<this._eventHandlers.length;i++)if(this._eventHandlers[i]===e){this._eventHandlers.splice(i,1);break}}beginEmitViewEvents(){return this._collectorCnt++,this._collectorCnt===1&&(this._collector=new br),this._collector}endEmitViewEvents(){if(this._collectorCnt--,this._collectorCnt===0){const e=this._collector.outgoingEvents,i=this._collector.viewEvents;this._collector=null;for(const r of e)this._addOutgoingEvent(r);i.length>0&&this._emitMany(i)}this._emitOutgoingEvents()}emitSingleViewEvent(e){try{this.beginEmitViewEvents().emitViewEvent(e)}finally{this.endEmitViewEvents()}}_emitMany(e){this._viewEventQueue?this._viewEventQueue=this._viewEventQueue.concat(e):this._viewEventQueue=e,this._isConsumingViewEventQueue||this._consumeViewEventQueue()}_consumeViewEventQueue(){try{this._isConsumingViewEventQueue=!0,this._doConsumeQueue()}finally{this._isConsumingViewEventQueue=!1}}_doConsumeQueue(){for(;this._viewEventQueue;){const e=this._viewEventQueue;this._viewEventQueue=null;const i=this._eventHandlers.slice(0);for(const r of i)r.handleEvents(e)}}}class br{constructor(){this.viewEvents=[],this.outgoingEvents=[]}emitViewEvent(e){this.viewEvents.push(e)}emitOutgoingEvent(e){this.outgoingEvents.push(e)}}class eo{constructor(e,i,r,_){this.kind=0,this._oldContentWidth=e,this._oldContentHeight=i,this.contentWidth=r,this.contentHeight=_,this.contentWidthChanged=this._oldContentWidth!==this.contentWidth,this.contentHeightChanged=this._oldContentHeight!==this.contentHeight}isNoOp(){return!this.contentWidthChanged&&!this.contentHeightChanged}attemptToMerge(e){return e.kind!==this.kind?null:new eo(this._oldContentWidth,this._oldContentHeight,e.contentWidth,e.contentHeight)}}class Es{constructor(e,i){this.kind=1,this.oldHasFocus=e,this.hasFocus=i}isNoOp(){return this.oldHasFocus===this.hasFocus}attemptToMerge(e){return e.kind!==this.kind?null:new Es(this.oldHasFocus,e.hasFocus)}}class ss{constructor(e,i,r,_,S,z,ie,re){this.kind=2,this._oldScrollWidth=e,this._oldScrollLeft=i,this._oldScrollHeight=r,this._oldScrollTop=_,this.scrollWidth=S,this.scrollLeft=z,this.scrollHeight=ie,this.scrollTop=re,this.scrollWidthChanged=this._oldScrollWidth!==this.scrollWidth,this.scrollLeftChanged=this._oldScrollLeft!==this.scrollLeft,this.scrollHeightChanged=this._oldScrollHeight!==this.scrollHeight,this.scrollTopChanged=this._oldScrollTop!==this.scrollTop}isNoOp(){return!this.scrollWidthChanged&&!this.scrollLeftChanged&&!this.scrollHeightChanged&&!this.scrollTopChanged}attemptToMerge(e){return e.kind!==this.kind?null:new ss(this._oldScrollWidth,this._oldScrollLeft,this._oldScrollHeight,this._oldScrollTop,e.scrollWidth,e.scrollLeft,e.scrollHeight,e.scrollTop)}}class Ps{constructor(){this.kind=3}isNoOp(){return!1}attemptToMerge(e){return e.kind!==this.kind?null:this}}class Co{constructor(){this.kind=4}isNoOp(){return!1}attemptToMerge(e){return e.kind!==this.kind?null:this}}class Hs{constructor(e,i,r,_,S,z,ie){this.kind=6,this.oldSelections=e,this.selections=i,this.oldModelVersionId=r,this.modelVersionId=_,this.source=S,this.reason=z,this.reachedMaxCursorCount=ie}static _selectionsAreEqual(e,i){if(!e&&!i)return!0;if(!e||!i)return!1;const r=e.length,_=i.length;if(r!==_)return!1;for(let S=0;S<r;S++)if(!e[S].equalsSelection(i[S]))return!1;return!0}isNoOp(){return Hs._selectionsAreEqual(this.oldSelections,this.selections)&&this.oldModelVersionId===this.modelVersionId}attemptToMerge(e){return e.kind!==this.kind?null:new Hs(this.oldSelections,e.selections,this.oldModelVersionId,e.modelVersionId,e.source,e.reason,this.reachedMaxCursorCount||e.reachedMaxCursorCount)}}class to{constructor(){this.kind=5}isNoOp(){return!1}attemptToMerge(e){return e.kind!==this.kind?null:this}}class Qo{constructor(e){this.event=e,this.kind=7}isNoOp(){return!1}attemptToMerge(e){return null}}class Cs{constructor(e){this.event=e,this.kind=8}isNoOp(){return!1}attemptToMerge(e){return null}}class os{constructor(e){this.event=e,this.kind=9}isNoOp(){return!1}attemptToMerge(e){return null}}class ri{constructor(e){this.event=e,this.kind=10}isNoOp(){return!1}attemptToMerge(e){return null}}class io{constructor(e){this.event=e,this.kind=11}isNoOp(){return!1}attemptToMerge(e){return null}}class bo{constructor(e){this.event=e,this.kind=12}isNoOp(){return!1}attemptToMerge(e){return null}}class bs extends p.jG{constructor(e,i,r,_){super(),this._model=e,this._knownModelVersionId=this._model.getVersionId(),this._viewModel=i,this._coordinatesConverter=r,this.context=new gs(this._model,this._viewModel,this._coordinatesConverter,_),this._cursors=new po(this.context),this._hasFocus=!1,this._isHandling=!1,this._compositionState=null,this._columnSelectData=null,this._autoClosedActions=[],this._prevEditOperationType=0}dispose(){this._cursors.dispose(),this._autoClosedActions=(0,p.AS)(this._autoClosedActions),super.dispose()}updateConfiguration(e){this.context=new gs(this._model,this._viewModel,this._coordinatesConverter,e),this._cursors.updateContext(this.context)}onLineMappingChanged(e){this._knownModelVersionId===this._model.getVersionId()&&this.setStates(e,"viewModel",0,this.getCursorStates())}setHasFocus(e){this._hasFocus=e}_validateAutoClosedActions(){if(this._autoClosedActions.length>0){const e=this._cursors.getSelections();for(let i=0;i<this._autoClosedActions.length;i++){const r=this._autoClosedActions[i];r.isValid(e)||(r.dispose(),this._autoClosedActions.splice(i,1),i--)}}}getPrimaryCursorState(){return this._cursors.getPrimaryCursor()}getLastAddedCursorIndex(){return this._cursors.getLastAddedCursorIndex()}getCursorStates(){return this._cursors.getAll()}setStates(e,i,r,_){let S=!1;_!==null&&_.length>bs.MAX_CURSOR_COUNT&&(_=_.slice(0,bs.MAX_CURSOR_COUNT),S=!0);const z=Fn.from(this._model,this);return this._cursors.setStates(_),this._cursors.normalize(),this._columnSelectData=null,this._validateAutoClosedActions(),this._emitStateChangedIfNecessary(e,i,r,z,S)}setCursorColumnSelectData(e){this._columnSelectData=e}revealPrimary(e,i,r,_,S,z){const ie=this._cursors.getViewPositions();let re=null,le=null;ie.length>1?le=this._cursors.getViewSelections():re=Pt.Q.fromPositions(ie[0],ie[0]),e.emitViewEvent(new Vs(i,r,re,le,_,S,z))}saveState(){const e=[],i=this._cursors.getSelections();for(let r=0,_=i.length;r<_;r++){const S=i[r];e.push({inSelectionMode:!S.isEmpty(),selectionStart:{lineNumber:S.selectionStartLineNumber,column:S.selectionStartColumn},position:{lineNumber:S.positionLineNumber,column:S.positionColumn}})}return e}restoreState(e,i){const r=[];for(let _=0,S=i.length;_<S;_++){const z=i[_];let ie=1,re=1;z.position&&z.position.lineNumber&&(ie=z.position.lineNumber),z.position&&z.position.column&&(re=z.position.column);let le=ie,me=re;z.selectionStart&&z.selectionStart.lineNumber&&(le=z.selectionStart.lineNumber),z.selectionStart&&z.selectionStart.column&&(me=z.selectionStart.column),r.push({selectionStartLineNumber:le,selectionStartColumn:me,positionLineNumber:ie,positionColumn:re})}this.setStates(e,"restoreState",0,rn.MF.fromModelSelections(r)),this.revealPrimary(e,"restoreState",!1,0,!0,1)}onModelContentChanged(e,i){if(i instanceof us.vn){if(this._isHandling)return;this._isHandling=!0;try{this.setStates(e,"modelChange",0,this.getCursorStates())}finally{this._isHandling=!1}}else{const r=i.rawContentChangedEvent;if(this._knownModelVersionId=r.versionId,this._isHandling)return;const _=r.containsEvent(1);if(this._prevEditOperationType=0,_)this._cursors.dispose(),this._cursors=new po(this.context),this._validateAutoClosedActions(),this._emitStateChangedIfNecessary(e,"model",1,null,!1);else if(this._hasFocus&&r.resultingSelection&&r.resultingSelection.length>0){const S=rn.MF.fromModelSelections(r.resultingSelection);this.setStates(e,"modelChange",r.isUndoing?5:r.isRedoing?6:2,S)&&this.revealPrimary(e,"modelChange",!1,0,!0,0)}else{const S=this._cursors.readSelectionFromMarkers();this.setStates(e,"modelChange",2,rn.MF.fromModelSelections(S))}}}getSelection(){return this._cursors.getPrimaryCursor().modelState.selection}getTopMostViewPosition(){return this._cursors.getTopMostViewPosition()}getBottomMostViewPosition(){return this._cursors.getBottomMostViewPosition()}getCursorColumnSelectData(){if(this._columnSelectData)return this._columnSelectData;const e=this._cursors.getPrimaryCursor(),i=e.viewState.selectionStart.getStartPosition(),r=e.viewState.position;return{isReal:!1,fromViewLineNumber:i.lineNumber,fromViewVisualColumn:this.context.cursorConfig.visibleColumnFromColumn(this._viewModel,i),toViewLineNumber:r.lineNumber,toViewVisualColumn:this.context.cursorConfig.visibleColumnFromColumn(this._viewModel,r)}}getSelections(){return this._cursors.getSelections()}setSelections(e,i,r,_){this.setStates(e,i,_,rn.MF.fromModelSelections(r))}getPrevEditOperationType(){return this._prevEditOperationType}setPrevEditOperationType(e){this._prevEditOperationType=e}_pushAutoClosedAction(e,i){const r=[],_=[];for(let ie=0,re=e.length;ie<re;ie++)r.push({range:e[ie],options:{description:"auto-closed-character",inlineClassName:"auto-closed-character",stickiness:1}}),_.push({range:i[ie],options:{description:"auto-closed-enclosing",stickiness:1}});const S=this._model.deltaDecorations([],r),z=this._model.deltaDecorations([],_);this._autoClosedActions.push(new Os(this._model,S,z))}_executeEditOperation(e){if(!e)return;e.shouldPushStackElementBefore&&this._model.pushStackElement();const i=As.executeCommands(this._model,this._cursors.getSelections(),e.commands);if(i){this._interpretCommandResult(i);const r=[],_=[];for(let S=0;S<e.commands.length;S++){const z=e.commands[S];z instanceof es.yl&&z.enclosingRange&&z.closeCharacterRange&&(r.push(z.closeCharacterRange),_.push(z.enclosingRange))}r.length>0&&this._pushAutoClosedAction(r,_),this._prevEditOperationType=e.type}e.shouldPushStackElementAfter&&this._model.pushStackElement()}_interpretCommandResult(e){(!e||e.length===0)&&(e=this._cursors.readSelectionFromMarkers()),this._columnSelectData=null,this._cursors.setSelections(e),this._cursors.normalize()}_emitStateChangedIfNecessary(e,i,r,_,S){const z=Fn.from(this._model,this);if(z.equals(_))return!1;const ie=this._cursors.getSelections(),re=this._cursors.getViewSelections();if(e.emitViewEvent(new Cr(re,ie)),!_||_.cursorState.length!==z.cursorState.length||z.cursorState.some((le,me)=>!le.modelState.equals(_.cursorState[me].modelState))){const le=_?_.cursorState.map(we=>we.modelState.selection):null,me=_?_.modelVersionId:0;e.emitOutgoingEvent(new Hs(le,ie,me,z.modelVersionId,i||"keyboard",r,S))}return!0}_findAutoClosingPairs(e){if(!e.length)return null;const i=[];for(let r=0,_=e.length;r<_;r++){const S=e[r];if(!S.text||S.text.indexOf(` `)>=0)return null;const z=S.text.match(/([)\]}>'"`])([^)\]}>'"`]*)$/);if(!z)return null;const ie=z[1],re=this.context.cursorConfig.autoClosingPairs.autoClosingPairsCloseSingleChar.get(ie);if(!re||re.length!==1)return null;const le=re[0].open,me=S.text.length-z[2].length-1,we=S.text.lastIndexOf(le,me-1);if(we===-1)return null;i.push([we,me])}return i}executeEdits(e,i,r,_){let S=null;i==="snippet"&&(S=this._findAutoClosingPairs(r)),S&&(r[0]._isTracked=!0);const z=[],ie=[],re=this._model.pushEditOperations(this.getSelections(),r,le=>{if(S)for(let we=0,Be=S.length;we<Be;we++){const[Re,Je]=S[we],st=le[we],ct=st.range.startLineNumber,mt=st.range.startColumn-1+Re,xt=st.range.startColumn-1+Je;z.push(new Pt.Q(ct,xt+1,ct,xt+2)),ie.push(new Pt.Q(ct,mt+1,ct,xt+2))}const me=_(le);return me&&(this._isHandling=!0),me});re&&(this._isHandling=!1,this.setSelections(e,i,re,0)),z.length>0&&this._pushAutoClosedAction(z,ie)}_executeEdit(e,i,r,_=0){if(this.context.cursorConfig.readOnly)return;const S=Fn.from(this._model,this);this._cursors.stopTrackingSelections(),this._isHandling=!0;try{this._cursors.ensureValidState(),e()}catch(z){(0,B.dz)(z)}this._isHandling=!1,this._cursors.startTrackingSelections(),this._validateAutoClosedActions(),this._emitStateChangedIfNecessary(i,r,_,S,!1)&&this.revealPrimary(i,r,!1,0,!0,0)}getAutoClosedCharacters(){return Os.getAllAutoClosedCharacters(this._autoClosedActions)}startComposition(e){this._compositionState=new pi(this._model,this.getSelections())}endComposition(e,i){const r=this._compositionState?this._compositionState.deduceOutcome(this._model,this.getSelections()):null;this._compositionState=null,this._executeEdit(()=>{i==="keyboard"&&this._executeEditOperation(es.TK.compositionEndWithInterceptors(this._prevEditOperationType,this.context.cursorConfig,this._model,r,this.getSelections(),this.getAutoClosedCharacters()))},e,i)}type(e,i,r){this._executeEdit(()=>{if(r==="keyboard"){const _=i.length;let S=0;for(;S<_;){const z=at.iy(i,S),ie=i.substr(S,z);this._executeEditOperation(es.TK.typeWithInterceptors(!!this._compositionState,this._prevEditOperationType,this.context.cursorConfig,this._model,this.getSelections(),this.getAutoClosedCharacters(),ie)),S+=z}}else this._executeEditOperation(es.TK.typeWithoutInterceptors(this._prevEditOperationType,this.context.cursorConfig,this._model,this.getSelections(),i))},e,r)}compositionType(e,i,r,_,S,z){if(i.length===0&&r===0&&_===0){if(S!==0){const ie=this.getSelections().map(re=>{const le=re.getPosition();return new ue.L(le.lineNumber,le.column+S,le.lineNumber,le.column+S)});this.setSelections(e,z,ie,0)}return}this._executeEdit(()=>{this._executeEditOperation(es.TK.compositionType(this._prevEditOperationType,this.context.cursorConfig,this._model,this.getSelections(),i,r,_,S))},e,z)}paste(e,i,r,_,S){this._executeEdit(()=>{this._executeEditOperation(es.TK.paste(this.context.cursorConfig,this._model,this.getSelections(),i,r,_||[]))},e,S,4)}cut(e,i){this._executeEdit(()=>{this._executeEditOperation(Uo.g.cut(this.context.cursorConfig,this._model,this.getSelections()))},e,i)}executeCommand(e,i,r){this._executeEdit(()=>{this._cursors.killSecondaryCursors(),this._executeEditOperation(new rn.vY(0,[i],{shouldPushStackElementBefore:!1,shouldPushStackElementAfter:!1}))},e,r)}executeCommands(e,i,r){this._executeEdit(()=>{this._executeEditOperation(new rn.vY(0,i,{shouldPushStackElementBefore:!1,shouldPushStackElementAfter:!1}))},e,r)}}bs.MAX_CURSOR_COUNT=1e4;class Fn{constructor(e,i){this.modelVersionId=e,this.cursorState=i}static from(e,i){return new Fn(e.getVersionId(),i.getCursorStates())}equals(e){if(!e||this.modelVersionId!==e.modelVersionId||this.cursorState.length!==e.cursorState.length)return!1;for(let i=0,r=this.cursorState.length;i<r;i++)if(!this.cursorState[i].equals(e.cursorState[i]))return!1;return!0}}class Os{constructor(e,i,r){this._model=e,this._autoClosedCharactersDecorations=i,this._autoClosedEnclosingDecorations=r}static getAllAutoClosedCharacters(e){let i=[];for(const r of e)i=i.concat(r.getAutoClosedCharactersRanges());return i}dispose(){this._autoClosedCharactersDecorations=this._model.deltaDecorations(this._autoClosedCharactersDecorations,[]),this._autoClosedEnclosingDecorations=this._model.deltaDecorations(this._autoClosedEnclosingDecorations,[])}getAutoClosedCharactersRanges(){const e=[];for(let i=0;i<this._autoClosedCharactersDecorations.length;i++){const r=this._model.getDecorationRange(this._autoClosedCharactersDecorations[i]);r&&e.push(r)}return e}isValid(e){const i=[];for(let r=0;r<this._autoClosedEnclosingDecorations.length;r++){const _=this._model.getDecorationRange(this._autoClosedEnclosingDecorations[r]);if(_&&(i.push(_),_.startLineNumber!==_.endLineNumber))return!1}i.sort(Pt.Q.compareRangesUsingStarts),e.sort(Pt.Q.compareRangesUsingStarts);for(let r=0;r<e.length;r++)if(r>=i.length||!i[r].strictContainsRange(e[r]))return!1;return!0}}class As{static executeCommands(e,i,r){const _={model:e,selectionsBefore:i,trackedRanges:[],trackedRangesDirection:[]},S=this._innerExecuteCommands(_,r);for(let z=0,ie=_.trackedRanges.length;z<ie;z++)_.model._setTrackedRange(_.trackedRanges[z],null,0);return S}static _innerExecuteCommands(e,i){if(this._arrayIsEmpty(i))return null;const r=this._getEditOperations(e,i);if(r.operations.length===0)return null;const _=r.operations,S=this._getLoserCursorMap(_);if(S.hasOwnProperty("0"))return console.warn("Ignoring commands"),null;const z=[];for(let le=0,me=_.length;le<me;le++)S.hasOwnProperty(_[le].identifier.major.toString())||z.push(_[le]);r.hadTrackedEditOperation&&z.length>0&&(z[0]._isTracked=!0);let ie=e.model.pushEditOperations(e.selectionsBefore,z,le=>{const me=[];for(let Re=0;Re<e.selectionsBefore.length;Re++)me[Re]=[];for(const Re of le)Re.identifier&&me[Re.identifier.major].push(Re);const we=(Re,Je)=>Re.identifier.minor-Je.identifier.minor,Be=[];for(let Re=0;Re<e.selectionsBefore.length;Re++)me[Re].length>0?(me[Re].sort(we),Be[Re]=i[Re].computeCursorState(e.model,{getInverseEditOperations:()=>me[Re],getTrackedSelection:Je=>{const st=parseInt(Je,10),ct=e.model._getTrackedRange(e.trackedRanges[st]);return e.trackedRangesDirection[st]===0?new ue.L(ct.startLineNumber,ct.startColumn,ct.endLineNumber,ct.endColumn):new ue.L(ct.endLineNumber,ct.endColumn,ct.startLineNumber,ct.startColumn)}})):Be[Re]=e.selectionsBefore[Re];return Be});ie||(ie=e.selectionsBefore);const re=[];for(const le in S)S.hasOwnProperty(le)&&re.push(parseInt(le,10));re.sort((le,me)=>me-le);for(const le of re)ie.splice(le,1);return ie}static _arrayIsEmpty(e){for(let i=0,r=e.length;i<r;i++)if(e[i])return!1;return!0}static _getEditOperations(e,i){let r=[],_=!1;for(let S=0,z=i.length;S<z;S++){const ie=i[S];if(ie){const re=this._getEditOperationsFromCommand(e,S,ie);r=r.concat(re.operations),_=_||re.hadTrackedEditOperation}}return{operations:r,hadTrackedEditOperation:_}}static _getEditOperationsFromCommand(e,i,r){const _=[];let S=0;const z=(we,Be,Re=!1)=>{Pt.Q.isEmpty(we)&&Be===""||_.push({identifier:{major:i,minor:S++},range:we,text:Be,forceMoveMarkers:Re,isAutoWhitespaceEdit:r.insertsAutoWhitespace})};let ie=!1;const me={addEditOperation:z,addTrackedEditOperation:(we,Be,Re)=>{ie=!0,z(we,Be,Re)},trackSelection:(we,Be)=>{const Re=ue.L.liftSelection(we);let Je;if(Re.isEmpty())if(typeof Be=="boolean")Be?Je=2:Je=3;else{const mt=e.model.getLineMaxColumn(Re.startLineNumber);Re.startColumn===mt?Je=2:Je=3}else Je=1;const st=e.trackedRanges.length,ct=e.model._setTrackedRange(null,Re,Je);return e.trackedRanges[st]=ct,e.trackedRangesDirection[st]=Re.getDirection(),st.toString()}};try{r.getEditOperations(e.model,me)}catch(we){return(0,B.dz)(we),{operations:[],hadTrackedEditOperation:!1}}return{operations:_,hadTrackedEditOperation:ie}}static _getLoserCursorMap(e){e=e.slice(0),e.sort((r,_)=>-Pt.Q.compareRangesUsingEnds(r.range,_.range));const i={};for(let r=1;r<e.length;r++){const _=e[r-1],S=e[r];if(Pt.Q.getStartPosition(_.range).isBefore(Pt.Q.getEndPosition(S.range))){let z;_.identifier.major>S.identifier.major?z=_.identifier.major:z=S.identifier.major,i[z.toString()]=!0;for(let ie=0;ie<e.length;ie++)e[ie].identifier.major===z&&(e.splice(ie,1),ie<r&&r--,ie--);r>0&&r--}}return i}}class no{constructor(e,i,r){this.text=e,this.startSelection=i,this.endSelection=r}}class pi{constructor(e,i){this._original=pi._capture(e,i)}static _capture(e,i){const r=[];for(const _ of i){if(_.startLineNumber!==_.endLineNumber)return null;r.push(new no(e.getLineContent(_.startLineNumber),_.startColumn-1,_.endColumn-1))}return r}deduceOutcome(e,i){if(!this._original)return null;const r=pi._capture(e,i);if(!r||this._original.length!==r.length)return null;const _=[];for(let S=0,z=this._original.length;S<z;S++)_.push(pi._deduceOutcome(this._original[S],r[S]));return _}static _deduceOutcome(e,i){const r=Math.min(e.startSelection,i.startSelection,at.Qp(e.text,i.text)),_=Math.min(e.text.length-e.endSelection,i.text.length-i.endSelection,at.Vi(e.text,i.text)),S=e.text.substring(r,e.text.length-_),z=i.text.substring(r,i.text.length-_);return new es.vS(S,e.startSelection-r,e.endSelection-r,z,i.startSelection-r,i.endSelection-r)}}var zi=y(22595),vn=y(12596),xi=y(38122),jn=y(59922),Wn=y(54957),Qn=y(1458),Rs=y(94513);class wr{constructor(){this._hasPending=!1,this._inserts=[],this._changes=[],this._removes=[]}insert(e){this._hasPending=!0,this._inserts.push(e)}change(e){this._hasPending=!0,this._changes.push(e)}remove(e){this._hasPending=!0,this._removes.push(e)}mustCommit(){return this._hasPending}commit(e){if(!this._hasPending)return;const i=this._inserts,r=this._changes,_=this._removes;this._hasPending=!1,this._inserts=[],this._changes=[],this._removes=[],e._commitPendingChanges(i,r,_)}}class yr{constructor(e,i,r,_,S){this.id=e,this.afterLineNumber=i,this.ordinal=r,this.height=_,this.minWidth=S,this.prefixSum=0}}class so{constructor(e,i,r,_){this._instanceId=at.tk(++so.INSTANCE_COUNT),this._pendingChanges=new wr,this._lastWhitespaceId=0,this._arr=[],this._prefixSumValidIndex=-1,this._minWidth=-1,this._lineCount=e,this._lineHeight=i,this._paddingTop=r,this._paddingBottom=_}static findInsertionIndex(e,i,r){let _=0,S=e.length;for(;_<S;){const z=_+S>>>1;i===e[z].afterLineNumber?r<e[z].ordinal?S=z:_=z+1:i<e[z].afterLineNumber?S=z:_=z+1}return _}setLineHeight(e){this._checkPendingChanges(),this._lineHeight=e}setPadding(e,i){this._paddingTop=e,this._paddingBottom=i}onFlushed(e){this._checkPendingChanges(),this._lineCount=e}changeWhitespace(e){let i=!1;try{e({insertWhitespace:(_,S,z,ie)=>{i=!0,_=_|0,S=S|0,z=z|0,ie=ie|0;const re=this._instanceId+ ++this._lastWhitespaceId;return this._pendingChanges.insert(new yr(re,_,S,z,ie)),re},changeOneWhitespace:(_,S,z)=>{i=!0,S=S|0,z=z|0,this._pendingChanges.change({id:_,newAfterLineNumber:S,newHeight:z})},removeWhitespace:_=>{i=!0,this._pendingChanges.remove({id:_})}})}finally{this._pendingChanges.commit(this)}return i}_commitPendingChanges(e,i,r){if((e.length>0||r.length>0)&&(this._minWidth=-1),e.length+i.length+r.length<=1){for(const re of e)this._insertWhitespace(re);for(const re of i)this._changeOneWhitespace(re.id,re.newAfterLineNumber,re.newHeight);for(const re of r){const le=this._findWhitespaceIndex(re.id);le!==-1&&this._removeWhitespace(le)}return}const _=new Set;for(const re of r)_.add(re.id);const S=new Map;for(const re of i)S.set(re.id,re);const z=re=>{const le=[];for(const me of re)if(!_.has(me.id)){if(S.has(me.id)){const we=S.get(me.id);me.afterLineNumber=we.newAfterLineNumber,me.height=we.newHeight}le.push(me)}return le},ie=z(this._arr).concat(z(e));ie.sort((re,le)=>re.afterLineNumber===le.afterLineNumber?re.ordinal-le.ordinal:re.afterLineNumber-le.afterLineNumber),this._arr=ie,this._prefixSumValidIndex=-1}_checkPendingChanges(){this._pendingChanges.mustCommit()&&this._pendingChanges.commit(this)}_insertWhitespace(e){const i=so.findInsertionIndex(this._arr,e.afterLineNumber,e.ordinal);this._arr.splice(i,0,e),this._prefixSumValidIndex=Math.min(this._prefixSumValidIndex,i-1)}_findWhitespaceIndex(e){const i=this._arr;for(let r=0,_=i.length;r<_;r++)if(i[r].id===e)return r;return-1}_changeOneWhitespace(e,i,r){const _=this._findWhitespaceIndex(e);if(_!==-1&&(this._arr[_].height!==r&&(this._arr[_].height=r,this._prefixSumValidIndex=Math.min(this._prefixSumValidIndex,_-1)),this._arr[_].afterLineNumber!==i)){const S=this._arr[_];this._removeWhitespace(_),S.afterLineNumber=i,this._insertWhitespace(S)}}_removeWhitespace(e){this._arr.splice(e,1),this._prefixSumValidIndex=Math.min(this._prefixSumValidIndex,e-1)}onLinesDeleted(e,i){this._checkPendingChanges(),e=e|0,i=i|0,this._lineCount-=i-e+1;for(let r=0,_=this._arr.length;r<_;r++){const S=this._arr[r].afterLineNumber;e<=S&&S<=i?this._arr[r].afterLineNumber=e-1:S>i&&(this._arr[r].afterLineNumber-=i-e+1)}}onLinesInserted(e,i){this._checkPendingChanges(),e=e|0,i=i|0,this._lineCount+=i-e+1;for(let r=0,_=this._arr.length;r<_;r++){const S=this._arr[r].afterLineNumber;e<=S&&(this._arr[r].afterLineNumber+=i-e+1)}}getWhitespacesTotalHeight(){return this._checkPendingChanges(),this._arr.length===0?0:this.getWhitespacesAccumulatedHeight(this._arr.length-1)}getWhitespacesAccumulatedHeight(e){this._checkPendingChanges(),e=e|0;let i=Math.max(0,this._prefixSumValidIndex+1);i===0&&(this._arr[0].prefixSum=this._arr[0].height,i++);for(let r=i;r<=e;r++)this._arr[r].prefixSum=this._arr[r-1].prefixSum+this._arr[r].height;return this._prefixSumValidIndex=Math.max(this._prefixSumValidIndex,e),this._arr[e].prefixSum}getLinesTotalHeight(){this._checkPendingChanges();const e=this._lineHeight*this._lineCount,i=this.getWhitespacesTotalHeight();return e+i+this._paddingTop+this._paddingBottom}getWhitespaceAccumulatedHeightBeforeLineNumber(e){this._checkPendingChanges(),e=e|0;const i=this._findLastWhitespaceBeforeLineNumber(e);return i===-1?0:this.getWhitespacesAccumulatedHeight(i)}_findLastWhitespaceBeforeLineNumber(e){e=e|0;const i=this._arr;let r=0,_=i.length-1;for(;r<=_;){const z=(_-r|0)/2|0,ie=r+z|0;if(i[ie].afterLineNumber<e){if(ie+1>=i.length||i[ie+1].afterLineNumber>=e)return ie;r=ie+1|0}else _=ie-1|0}return-1}_findFirstWhitespaceAfterLineNumber(e){e=e|0;const r=this._findLastWhitespaceBeforeLineNumber(e)+1;return r<this._arr.length?r:-1}getFirstWhitespaceIndexAfterLineNumber(e){return this._checkPendingChanges(),e=e|0,this._findFirstWhitespaceAfterLineNumber(e)}getVerticalOffsetForLineNumber(e,i=!1){this._checkPendingChanges(),e=e|0;let r;e>1?r=this._lineHeight*(e-1):r=0;const _=this.getWhitespaceAccumulatedHeightBeforeLineNumber(e-(i?1:0));return r+_+this._paddingTop}getVerticalOffsetAfterLineNumber(e,i=!1){this._checkPendingChanges(),e=e|0;const r=this._lineHeight*e,_=this.getWhitespaceAccumulatedHeightBeforeLineNumber(e+(i?1:0));return r+_+this._paddingTop}getWhitespaceMinWidth(){if(this._checkPendingChanges(),this._minWidth===-1){let e=0;for(let i=0,r=this._arr.length;i<r;i++)e=Math.max(e,this._arr[i].minWidth);this._minWidth=e}return this._minWidth}isAfterLines(e){this._checkPendingChanges();const i=this.getLinesTotalHeight();return e>i}isInTopPadding(e){return this._paddingTop===0?!1:(this._checkPendingChanges(),e<this._paddingTop)}isInBottomPadding(e){if(this._paddingBottom===0)return!1;this._checkPendingChanges();const i=this.getLinesTotalHeight();return e>=i-this._paddingBottom}getLineNumberAtOrAfterVerticalOffset(e){if(this._checkPendingChanges(),e=e|0,e<0)return 1;const i=this._lineCount|0,r=this._lineHeight;let _=1,S=i;for(;_<S;){const z=(_+S)/2|0,ie=this.getVerticalOffsetForLineNumber(z)|0;if(e>=ie+r)_=z+1;else{if(e>=ie)return z;S=z}}return _>i?i:_}getLinesViewportData(e,i){this._checkPendingChanges(),e=e|0,i=i|0;const r=this._lineHeight,_=this.getLineNumberAtOrAfterVerticalOffset(e)|0,S=this.getVerticalOffsetForLineNumber(_)|0;let z=this._lineCount|0,ie=this.getFirstWhitespaceIndexAfterLineNumber(_)|0;const re=this.getWhitespacesCount()|0;let le,me;ie===-1?(ie=re,me=z+1,le=0):(me=this.getAfterLineNumberForWhitespaceIndex(ie)|0,le=this.getHeightForWhitespaceIndex(ie)|0);let we=S,Be=we;const Re=5e5;let Je=0;S>=Re&&(Je=Math.floor(S/Re)*Re,Je=Math.floor(Je/r)*r,Be-=Je);const st=[],ct=e+(i-e)/2;let mt=-1;for(let $t=_;$t<=z;$t++){if(mt===-1){const ai=we,ii=we+r;(ai<=ct&&ct<ii||ai>ct)&&(mt=$t)}for(we+=r,st[$t-_]=Be,Be+=r;me===$t;)Be+=le,we+=le,ie++,ie>=re?me=z+1:(me=this.getAfterLineNumberForWhitespaceIndex(ie)|0,le=this.getHeightForWhitespaceIndex(ie)|0);if(we>=i){z=$t;break}}mt===-1&&(mt=z);const xt=this.getVerticalOffsetForLineNumber(z)|0;let Dt=_,Jt=z;return Dt<Jt&&S<e&&Dt++,Dt<Jt&&xt+r>i&&Jt--,{bigNumbersDelta:Je,startLineNumber:_,endLineNumber:z,relativeVerticalOffset:st,centeredLineNumber:mt,completelyVisibleStartLineNumber:Dt,completelyVisibleEndLineNumber:Jt}}getVerticalOffsetForWhitespaceIndex(e){this._checkPendingChanges(),e=e|0;const i=this.getAfterLineNumberForWhitespaceIndex(e);let r;i>=1?r=this._lineHeight*i:r=0;let _;return e>0?_=this.getWhitespacesAccumulatedHeight(e-1):_=0,r+_+this._paddingTop}getWhitespaceIndexAtOrAfterVerticallOffset(e){this._checkPendingChanges(),e=e|0;let i=0,r=this.getWhitespacesCount()-1;if(r<0)return-1;const _=this.getVerticalOffsetForWhitespaceIndex(r),S=this.getHeightForWhitespaceIndex(r);if(e>=_+S)return-1;for(;i<r;){const z=Math.floor((i+r)/2),ie=this.getVerticalOffsetForWhitespaceIndex(z),re=this.getHeightForWhitespaceIndex(z);if(e>=ie+re)i=z+1;else{if(e>=ie)return z;r=z}}return i}getWhitespaceAtVerticalOffset(e){this._checkPendingChanges(),e=e|0;const i=this.getWhitespaceIndexAtOrAfterVerticallOffset(e);if(i<0||i>=this.getWhitespacesCount())return null;const r=this.getVerticalOffsetForWhitespaceIndex(i);if(r>e)return null;const _=this.getHeightForWhitespaceIndex(i),S=this.getIdForWhitespaceIndex(i),z=this.getAfterLineNumberForWhitespaceIndex(i);return{id:S,afterLineNumber:z,verticalOffset:r,height:_}}getWhitespaceViewportData(e,i){this._checkPendingChanges(),e=e|0,i=i|0;const r=this.getWhitespaceIndexAtOrAfterVerticallOffset(e),_=this.getWhitespacesCount()-1;if(r<0)return[];const S=[];for(let z=r;z<=_;z++){const ie=this.getVerticalOffsetForWhitespaceIndex(z),re=this.getHeightForWhitespaceIndex(z);if(ie>=i)break;S.push({id:this.getIdForWhitespaceIndex(z),afterLineNumber:this.getAfterLineNumberForWhitespaceIndex(z),verticalOffset:ie,height:re})}return S}getWhitespaces(){return this._checkPendingChanges(),this._arr.slice(0)}getWhitespacesCount(){return this._checkPendingChanges(),this._arr.length}getIdForWhitespaceIndex(e){return this._checkPendingChanges(),e=e|0,this._arr[e].id}getAfterLineNumberForWhitespaceIndex(e){return this._checkPendingChanges(),e=e|0,this._arr[e].afterLineNumber}getHeightForWhitespaceIndex(e){return this._checkPendingChanges(),e=e|0,this._arr[e].height}}so.INSTANCE_COUNT=0;const ms=125;class ps{constructor(e,i,r,_){e=e|0,i=i|0,r=r|0,_=_|0,e<0&&(e=0),i<0&&(i=0),r<0&&(r=0),_<0&&(_=0),this.width=e,this.contentWidth=i,this.scrollWidth=Math.max(e,i),this.height=r,this.contentHeight=_,this.scrollHeight=Math.max(r,_)}equals(e){return this.width===e.width&&this.contentWidth===e.contentWidth&&this.height===e.height&&this.contentHeight===e.contentHeight}}class fs extends p.jG{constructor(e,i){super(),this._onDidContentSizeChange=this._register(new T.vl),this.onDidContentSizeChange=this._onDidContentSizeChange.event,this._dimensions=new ps(0,0,0,0),this._scrollable=this._register(new Rs.yE({forceIntegerValues:!0,smoothScrollDuration:e,scheduleAtNextAnimationFrame:i})),this.onDidScroll=this._scrollable.onScroll}getScrollable(){return this._scrollable}setSmoothScrollDuration(e){this._scrollable.setSmoothScrollDuration(e)}validateScrollPosition(e){return this._scrollable.validateScrollPosition(e)}getScrollDimensions(){return this._dimensions}setScrollDimensions(e){if(this._dimensions.equals(e))return;const i=this._dimensions;this._dimensions=e,this._scrollable.setScrollDimensions({width:e.width,scrollWidth:e.scrollWidth,height:e.height,scrollHeight:e.scrollHeight},!0);const r=i.contentWidth!==e.contentWidth,_=i.contentHeight!==e.contentHeight;(r||_)&&this._onDidContentSizeChange.fire(new eo(i.contentWidth,i.contentHeight,e.contentWidth,e.contentHeight))}getFutureScrollPosition(){return this._scrollable.getFutureScrollPosition()}getCurrentScrollPosition(){return this._scrollable.getCurrentScrollPosition()}setScrollPositionNow(e){this._scrollable.setScrollPositionNow(e)}setScrollPositionSmooth(e){this._scrollable.setScrollPositionSmooth(e)}}class Zo extends p.jG{constructor(e,i,r){super(),this._configuration=e;const _=this._configuration.options,S=_.get(133),z=_.get(77);this._linesLayout=new so(i,_.get(61),z.top,z.bottom),this._scrollable=this._register(new fs(0,r)),this._configureSmoothScrollDuration(),this._scrollable.setScrollDimensions(new ps(S.contentWidth,0,S.height,0)),this.onDidScroll=this._scrollable.onDidScroll,this.onDidContentSizeChange=this._scrollable.onDidContentSizeChange,this._updateHeight()}dispose(){super.dispose()}getScrollable(){return this._scrollable.getScrollable()}onHeightMaybeChanged(){this._updateHeight()}_configureSmoothScrollDuration(){this._scrollable.setSmoothScrollDuration(this._configuration.options.get(105)?ms:0)}onConfigurationChanged(e){const i=this._configuration.options;if(e.hasChanged(61)&&this._linesLayout.setLineHeight(i.get(61)),e.hasChanged(77)){const r=i.get(77);this._linesLayout.setPadding(r.top,r.bottom)}if(e.hasChanged(133)){const r=i.get(133),_=r.contentWidth,S=r.height,z=this._scrollable.getScrollDimensions(),ie=z.contentWidth;this._scrollable.setScrollDimensions(new ps(_,z.contentWidth,S,this._getContentHeight(_,S,ie)))}else this._updateHeight();e.hasChanged(105)&&this._configureSmoothScrollDuration()}onFlushed(e){this._linesLayout.onFlushed(e)}onLinesDeleted(e,i){this._linesLayout.onLinesDeleted(e,i)}onLinesInserted(e,i){this._linesLayout.onLinesInserted(e,i)}_getHorizontalScrollbarHeight(e,i){const _=this._configuration.options.get(94);return _.horizontal===2||e>=i?0:_.horizontalScrollbarSize}_getContentHeight(e,i,r){const _=this._configuration.options;let S=this._linesLayout.getLinesTotalHeight();return _.get(96)?S+=Math.max(0,i-_.get(61)-_.get(77).bottom):S+=this._getHorizontalScrollbarHeight(e,r),S}_updateHeight(){const e=this._scrollable.getScrollDimensions(),i=e.width,r=e.height,_=e.contentWidth;this._scrollable.setScrollDimensions(new ps(i,e.contentWidth,r,this._getContentHeight(i,r,_)))}getCurrentViewport(){const e=this._scrollable.getScrollDimensions(),i=this._scrollable.getCurrentScrollPosition();return new Nn.LM(i.scrollTop,i.scrollLeft,e.width,e.height)}getFutureViewport(){const e=this._scrollable.getScrollDimensions(),i=this._scrollable.getFutureScrollPosition();return new Nn.LM(i.scrollTop,i.scrollLeft,e.width,e.height)}_computeContentWidth(e){const i=this._configuration.options,r=i.get(134),_=i.get(46),S=i.get(133);if(r.isViewportWrapping){const z=i.get(67);return e>S.contentWidth+_.typicalHalfwidthCharacterWidth&&z.enabled&&z.side==="right"?e+S.verticalScrollbarWidth:e}else{const z=i.get(95)*_.typicalHalfwidthCharacterWidth,ie=this._linesLayout.getWhitespaceMinWidth();return Math.max(e+z+S.verticalScrollbarWidth,ie)}}setMaxLineWidth(e){const i=this._scrollable.getScrollDimensions();this._scrollable.setScrollDimensions(new ps(i.width,this._computeContentWidth(e),i.height,i.contentHeight)),this._updateHeight()}saveState(){const e=this._scrollable.getFutureScrollPosition(),i=e.scrollTop,r=this._linesLayout.getLineNumberAtOrAfterVerticalOffset(i),_=this._linesLayout.getWhitespaceAccumulatedHeightBeforeLineNumber(r);return{scrollTop:i,scrollTopWithoutViewZones:i-_,scrollLeft:e.scrollLeft}}changeWhitespace(e){const i=this._linesLayout.changeWhitespace(e);return i&&this.onHeightMaybeChanged(),i}getVerticalOffsetForLineNumber(e,i=!1){return this._linesLayout.getVerticalOffsetForLineNumber(e,i)}getVerticalOffsetAfterLineNumber(e,i=!1){return this._linesLayout.getVerticalOffsetAfterLineNumber(e,i)}isAfterLines(e){return this._linesLayout.isAfterLines(e)}isInTopPadding(e){return this._linesLayout.isInTopPadding(e)}isInBottomPadding(e){return this._linesLayout.isInBottomPadding(e)}getLineNumberAtVerticalOffset(e){return this._linesLayout.getLineNumberAtOrAfterVerticalOffset(e)}getWhitespaceAtVerticalOffset(e){return this._linesLayout.getWhitespaceAtVerticalOffset(e)}getLinesViewportData(){const e=this.getCurrentViewport();return this._linesLayout.getLinesViewportData(e.top,e.top+e.height)}getLinesViewportDataAtScrollTop(e){const i=this._scrollable.getScrollDimensions();return e+i.height>i.scrollHeight&&(e=i.scrollHeight-i.height),e<0&&(e=0),this._linesLayout.getLinesViewportData(e,e+i.height)}getWhitespaceViewportData(){const e=this.getCurrentViewport();return this._linesLayout.getWhitespaceViewportData(e.top,e.top+e.height)}getWhitespaces(){return this._linesLayout.getWhitespaces()}getContentWidth(){return this._scrollable.getScrollDimensions().contentWidth}getScrollWidth(){return this._scrollable.getScrollDimensions().scrollWidth}getContentHeight(){return this._scrollable.getScrollDimensions().contentHeight}getScrollHeight(){return this._scrollable.getScrollDimensions().scrollHeight}getCurrentScrollLeft(){return this._scrollable.getCurrentScrollPosition().scrollLeft}getCurrentScrollTop(){return this._scrollable.getCurrentScrollPosition().scrollTop}validateScrollPosition(e){return this._scrollable.validateScrollPosition(e)}setScrollPosition(e,i){i===1?this._scrollable.setScrollPositionNow(e):this._scrollable.setScrollPositionSmooth(e)}deltaScrollNow(e,i){const r=this._scrollable.getCurrentScrollPosition();this._scrollable.setScrollPositionNow({scrollLeft:r.scrollLeft+e,scrollTop:r.scrollTop+i})}}var Yo=y(31430),wo=y(57445);function ks(Le,e){return Le===null?e?oo.INSTANCE:zs.INSTANCE:new Xo(Le,e)}class Xo{constructor(e,i){this._projectionData=e,this._isVisible=i}isVisible(){return this._isVisible}setVisible(e){return this._isVisible=e,this}getProjectionData(){return this._projectionData}getViewLineCount(){return this._isVisible?this._projectionData.getOutputLineCount():0}getViewLineContent(e,i,r){this._assertVisible();const _=r>0?this._projectionData.breakOffsets[r-1]:0,S=this._projectionData.breakOffsets[r];let z;if(this._projectionData.injectionOffsets!==null){const ie=this._projectionData.injectionOffsets.map((le,me)=>new us.uK(0,0,le+1,this._projectionData.injectionOptions[me],0));z=us.uK.applyInjectedText(e.getLineContent(i),ie).substring(_,S)}else z=e.getValueInRange({startLineNumber:i,startColumn:_+1,endLineNumber:i,endColumn:S+1});return r>0&&(z=Sr(this._projectionData.wrappedTextIndentLength)+z),z}getViewLineLength(e,i,r){return this._assertVisible(),this._projectionData.getLineLength(r)}getViewLineMinColumn(e,i,r){return this._assertVisible(),this._projectionData.getMinOutputOffset(r)+1}getViewLineMaxColumn(e,i,r){return this._assertVisible(),this._projectionData.getMaxOutputOffset(r)+1}getViewLineData(e,i,r){const _=new Array;return this.getViewLinesData(e,i,r,1,0,[!0],_),_[0]}getViewLinesData(e,i,r,_,S,z,ie){this._assertVisible();const re=this._projectionData,le=re.injectionOffsets,me=re.injectionOptions;let we=null;if(le){we=[];let Re=0,Je=0;for(let st=0;st<re.getOutputLineCount();st++){const ct=new Array;we[st]=ct;const mt=st>0?re.breakOffsets[st-1]:0,xt=re.breakOffsets[st];for(;Je<le.length;){const Dt=me[Je].content.length,Jt=le[Je]+Re,$t=Jt+Dt;if(Jt>xt)break;if(mt<$t){const ai=me[Je];if(ai.inlineClassName){const ii=st>0?re.wrappedTextIndentLength:0,Zt=ii+Math.max(Jt-mt,0),di=ii+Math.min($t-mt,xt);Zt!==di&&ct.push(new Nn.or(Zt,di,ai.inlineClassName,ai.inlineClassNameAffectsLetterSpacing))}}if($t<=xt)Re+=Dt,Je++;else break}}}let Be;le?Be=e.tokenization.getLineTokens(i).withInserted(le.map((Re,Je)=>({offset:Re,text:me[Je].content,tokenMetadata:wo.f.defaultTokenMetadata}))):Be=e.tokenization.getLineTokens(i);for(let Re=r;Re<r+_;Re++){const Je=S+Re-r;if(!z[Je]){ie[Je]=null;continue}ie[Je]=this._getViewLineData(Be,we?we[Re]:null,Re)}}_getViewLineData(e,i,r){this._assertVisible();const _=this._projectionData,S=r>0?_.wrappedTextIndentLength:0,z=r>0?_.breakOffsets[r-1]:0,ie=_.breakOffsets[r],re=e.sliceAndInflate(z,ie,S);let le=re.getLineContent();r>0&&(le=Sr(_.wrappedTextIndentLength)+le);const me=this._projectionData.getMinOutputOffset(r)+1,we=le.length+1,Be=r+1<this.getViewLineCount(),Re=r===0?0:_.breakOffsetsVisibleColumn[r-1];return new Nn.GP(le,Be,me,we,Re,re,i)}getModelColumnOfViewPosition(e,i){return this._assertVisible(),this._projectionData.translateToInputOffset(e,i-1)+1}getViewPositionOfModelPosition(e,i,r=2){return this._assertVisible(),this._projectionData.translateToOutputPosition(i-1,r).toPosition(e)}getViewLineNumberOfModelPosition(e,i){this._assertVisible();const r=this._projectionData.translateToOutputPosition(i-1);return e+r.outputLineIndex}normalizePosition(e,i,r){const _=i.lineNumber-e;return this._projectionData.normalizeOutputPosition(e,i.column-1,r).toPosition(_)}getInjectedTextAt(e,i){return this._projectionData.getInjectedText(e,i-1)}_assertVisible(){if(!this._isVisible)throw new Error("Not supported")}}class oo{constructor(){}isVisible(){return!0}setVisible(e){return e?this:zs.INSTANCE}getProjectionData(){return null}getViewLineCount(){return 1}getViewLineContent(e,i,r){return e.getLineContent(i)}getViewLineLength(e,i,r){return e.getLineLength(i)}getViewLineMinColumn(e,i,r){return e.getLineMinColumn(i)}getViewLineMaxColumn(e,i,r){return e.getLineMaxColumn(i)}getViewLineData(e,i,r){const _=e.tokenization.getLineTokens(i),S=_.getLineContent();return new Nn.GP(S,!1,1,S.length+1,0,_.inflate(),null)}getViewLinesData(e,i,r,_,S,z,ie){if(!z[S]){ie[S]=null;return}ie[S]=this.getViewLineData(e,i,0)}getModelColumnOfViewPosition(e,i){return i}getViewPositionOfModelPosition(e,i){return new Nt.y(e,i)}getViewLineNumberOfModelPosition(e,i){return e}normalizePosition(e,i,r){return i}getInjectedTextAt(e,i){return null}}oo.INSTANCE=new oo;class zs{constructor(){}isVisible(){return!1}setVisible(e){return e?oo.INSTANCE:this}getProjectionData(){return null}getViewLineCount(){return 0}getViewLineContent(e,i,r){throw new Error("Not supported")}getViewLineLength(e,i,r){throw new Error("Not supported")}getViewLineMinColumn(e,i,r){throw new Error("Not supported")}getViewLineMaxColumn(e,i,r){throw new Error("Not supported")}getViewLineData(e,i,r){throw new Error("Not supported")}getViewLinesData(e,i,r,_,S,z,ie){throw new Error("Not supported")}getModelColumnOfViewPosition(e,i){throw new Error("Not supported")}getViewPositionOfModelPosition(e,i){throw new Error("Not supported")}getViewLineNumberOfModelPosition(e,i){throw new Error("Not supported")}normalizePosition(e,i,r){throw new Error("Not supported")}getInjectedTextAt(e,i){throw new Error("Not supported")}}zs.INSTANCE=new zs;const Jo=[""];function Sr(Le){if(Le>=Jo.length)for(let e=1;e<=Le;e++)Jo[e]=Ds(e);return Jo[Le]}function Ds(Le){return new Array(Le+1).join(" ")}var Rr=y(56158);class Br{constructor(e,i,r,_,S,z,ie,re,le){this._editorId=e,this.model=i,this._validModelVersionId=-1,this._domLineBreaksComputerFactory=r,this._monospaceLineBreaksComputerFactory=_,this.fontInfo=S,this.tabSize=z,this.wrappingStrategy=ie,this.wrappingColumn=re,this.wrappingIndent=le,this._constructLines(!0,null)}dispose(){this.hiddenAreasDecorationIds=this.model.deltaDecorations(this.hiddenAreasDecorationIds,[])}createCoordinatesConverter(){return new Lr(this)}_constructLines(e,i){this.modelLineProjections=[],e&&(this.hiddenAreasDecorationIds=this.model.deltaDecorations(this.hiddenAreasDecorationIds,[]));const r=this.model.getLinesContent(),_=this.model.getInjectedTextDecorations(this._editorId),S=r.length,z=this.createLineBreaksComputer(),ie=new h.j3(us.uK.fromDecorations(_));for(let st=0;st<S;st++){const ct=ie.takeWhile(mt=>mt.lineNumber===st+1);z.addRequest(r[st],ct,i?i[st]:null)}const re=z.finalize(),le=[],me=this.hiddenAreasDecorationIds.map(st=>this.model.getDecorationRange(st)).sort(Pt.Q.compareRangesUsingStarts);let we=1,Be=0,Re=-1,Je=Re+1<me.length?Be+1:S+2;for(let st=0;st<S;st++){const ct=st+1;ct===Je&&(Re++,we=me[Re].startLineNumber,Be=me[Re].endLineNumber,Je=Re+1<me.length?Be+1:S+2);const mt=ct>=we&&ct<=Be,xt=ks(re[st],!mt);le[st]=xt.getViewLineCount(),this.modelLineProjections[st]=xt}this._validModelVersionId=this.model.getVersionId(),this.projectedModelLineLineCounts=new Rr.c2(le)}getHiddenAreas(){return this.hiddenAreasDecorationIds.map(e=>this.model.getDecorationRange(e))}setHiddenAreas(e){const i=e.map(Be=>this.model.validateRange(Be)),r=ro(i),_=this.hiddenAreasDecorationIds.map(Be=>this.model.getDecorationRange(Be)).sort(Pt.Q.compareRangesUsingStarts);if(r.length===_.length){let Be=!1;for(let Re=0;Re<r.length;Re++)if(!r[Re].equalsRange(_[Re])){Be=!0;break}if(!Be)return!1}const S=r.map(Be=>({range:Be,options:jn.kI.EMPTY}));this.hiddenAreasDecorationIds=this.model.deltaDecorations(this.hiddenAreasDecorationIds,S);const z=r;let ie=1,re=0,le=-1,me=le+1<z.length?re+1:this.modelLineProjections.length+2,we=!1;for(let Be=0;Be<this.modelLineProjections.length;Be++){const Re=Be+1;Re===me&&(le++,ie=z[le].startLineNumber,re=z[le].endLineNumber,me=le+1<z.length?re+1:this.modelLineProjections.length+2);let Je=!1;if(Re>=ie&&Re<=re?this.modelLineProjections[Be].isVisible()&&(this.modelLineProjections[Be]=this.modelLineProjections[Be].setVisible(!1),Je=!0):(we=!0,this.modelLineProjections[Be].isVisible()||(this.modelLineProjections[Be]=this.modelLineProjections[Be].setVisible(!0),Je=!0)),Je){const st=this.modelLineProjections[Be].getViewLineCount();this.projectedModelLineLineCounts.setValue(Be,st)}}return we||this.setHiddenAreas([]),!0}modelPositionIsVisible(e,i){return e<1||e>this.modelLineProjections.length?!1:this.modelLineProjections[e-1].isVisible()}getModelLineViewLineCount(e){return e<1||e>this.modelLineProjections.length?1:this.modelLineProjections[e-1].getViewLineCount()}setTabSize(e){return this.tabSize===e?!1:(this.tabSize=e,this._constructLines(!1,null),!0)}setWrappingSettings(e,i,r,_){const S=this.fontInfo.equals(e),z=this.wrappingStrategy===i,ie=this.wrappingColumn===r,re=this.wrappingIndent===_;if(S&&z&&ie&&re)return!1;const le=S&&z&&!ie&&re;this.fontInfo=e,this.wrappingStrategy=i,this.wrappingColumn=r,this.wrappingIndent=_;let me=null;if(le){me=[];for(let we=0,Be=this.modelLineProjections.length;we<Be;we++)me[we]=this.modelLineProjections[we].getProjectionData()}return this._constructLines(!1,me),!0}createLineBreaksComputer(){return(this.wrappingStrategy==="advanced"?this._domLineBreaksComputerFactory:this._monospaceLineBreaksComputerFactory).createLineBreaksComputer(this.fontInfo,this.tabSize,this.wrappingColumn,this.wrappingIndent)}onModelFlushed(){this._constructLines(!0,null)}onModelLinesDeleted(e,i,r){if(!e||e<=this._validModelVersionId)return null;const _=i===1?1:this.projectedModelLineLineCounts.getPrefixSum(i-1)+1,S=this.projectedModelLineLineCounts.getPrefixSum(r);return this.modelLineProjections.splice(i-1,r-i+1),this.projectedModelLineLineCounts.removeValues(i-1,r-i+1),new Js(_,S)}onModelLinesInserted(e,i,r,_){if(!e||e<=this._validModelVersionId)return null;const S=i>2&&!this.modelLineProjections[i-2].isVisible(),z=i===1?1:this.projectedModelLineLineCounts.getPrefixSum(i-1)+1;let ie=0;const re=[],le=[];for(let me=0,we=_.length;me<we;me++){const Be=ks(_[me],!S);re.push(Be);const Re=Be.getViewLineCount();ie+=Re,le[me]=Re}return this.modelLineProjections=this.modelLineProjections.slice(0,i-1).concat(re).concat(this.modelLineProjections.slice(i-1)),this.projectedModelLineLineCounts.insertValues(i-1,le),new qs(z,z+ie-1)}onModelLineChanged(e,i,r){if(e!==null&&e<=this._validModelVersionId)return[!1,null,null,null];const _=i-1,S=this.modelLineProjections[_].getViewLineCount(),z=this.modelLineProjections[_].isVisible(),ie=ks(r,z);this.modelLineProjections[_]=ie;const re=this.modelLineProjections[_].getViewLineCount();let le=!1,me=0,we=-1,Be=0,Re=-1,Je=0,st=-1;S>re?(me=this.projectedModelLineLineCounts.getPrefixSum(i-1)+1,we=me+re-1,Je=we+1,st=Je+(S-re)-1,le=!0):S<re?(me=this.projectedModelLineLineCounts.getPrefixSum(i-1)+1,we=me+S-1,Be=we+1,Re=Be+(re-S)-1,le=!0):(me=this.projectedModelLineLineCounts.getPrefixSum(i-1)+1,we=me+re-1),this.projectedModelLineLineCounts.setValue(_,re);const ct=me<=we?new Ws(me,we-me+1):null,mt=Be<=Re?new qs(Be,Re):null,xt=Je<=st?new Js(Je,st):null;return[le,ct,mt,xt]}acceptVersionId(e){this._validModelVersionId=e,this.modelLineProjections.length===1&&!this.modelLineProjections[0].isVisible()&&this.setHiddenAreas([])}getViewLineCount(){return this.projectedModelLineLineCounts.getTotalSum()}_toValidViewLineNumber(e){if(e<1)return 1;const i=this.getViewLineCount();return e>i?i:e|0}getActiveIndentGuide(e,i,r){e=this._toValidViewLineNumber(e),i=this._toValidViewLineNumber(i),r=this._toValidViewLineNumber(r);const _=this.convertViewPositionToModelPosition(e,this.getViewLineMinColumn(e)),S=this.convertViewPositionToModelPosition(i,this.getViewLineMinColumn(i)),z=this.convertViewPositionToModelPosition(r,this.getViewLineMinColumn(r)),ie=this.model.guides.getActiveIndentGuide(_.lineNumber,S.lineNumber,z.lineNumber),re=this.convertModelPositionToViewPosition(ie.startLineNumber,1),le=this.convertModelPositionToViewPosition(ie.endLineNumber,this.model.getLineMaxColumn(ie.endLineNumber));return{startLineNumber:re.lineNumber,endLineNumber:le.lineNumber,indent:ie.indent}}getViewLineInfo(e){e=this._toValidViewLineNumber(e);const i=this.projectedModelLineLineCounts.getIndexOf(e-1),r=i.index,_=i.remainder;return new yo(r+1,_)}getMinColumnOfViewLine(e){return this.modelLineProjections[e.modelLineNumber-1].getViewLineMinColumn(this.model,e.modelLineNumber,e.modelLineWrappedLineIdx)}getMaxColumnOfViewLine(e){return this.modelLineProjections[e.modelLineNumber-1].getViewLineMaxColumn(this.model,e.modelLineNumber,e.modelLineWrappedLineIdx)}getModelStartPositionOfViewLine(e){const i=this.modelLineProjections[e.modelLineNumber-1],r=i.getViewLineMinColumn(this.model,e.modelLineNumber,e.modelLineWrappedLineIdx),_=i.getModelColumnOfViewPosition(e.modelLineWrappedLineIdx,r);return new Nt.y(e.modelLineNumber,_)}getModelEndPositionOfViewLine(e){const i=this.modelLineProjections[e.modelLineNumber-1],r=i.getViewLineMaxColumn(this.model,e.modelLineNumber,e.modelLineWrappedLineIdx),_=i.getModelColumnOfViewPosition(e.modelLineWrappedLineIdx,r);return new Nt.y(e.modelLineNumber,_)}getViewLineInfosGroupedByModelRanges(e,i){const r=this.getViewLineInfo(e),_=this.getViewLineInfo(i),S=new Array;let z=this.getModelStartPositionOfViewLine(r),ie=new Array;for(let re=r.modelLineNumber;re<=_.modelLineNumber;re++){const le=this.modelLineProjections[re-1];if(le.isVisible()){const me=re===r.modelLineNumber?r.modelLineWrappedLineIdx:0,we=re===_.modelLineNumber?_.modelLineWrappedLineIdx+1:le.getViewLineCount();for(let Be=me;Be<we;Be++)ie.push(new yo(re,Be))}if(!le.isVisible()&&z){const me=new Nt.y(re-1,this.model.getLineMaxColumn(re-1)+1),we=Pt.Q.fromPositions(z,me);S.push(new Bs(we,ie)),ie=[],z=null}else le.isVisible()&&!z&&(z=new Nt.y(re,1))}if(z){const re=Pt.Q.fromPositions(z,this.getModelEndPositionOfViewLine(_));S.push(new Bs(re,ie))}return S}getViewLinesBracketGuides(e,i,r,_){const S=r?this.convertViewPositionToModelPosition(r.lineNumber,r.column):null,z=[];for(const ie of this.getViewLineInfosGroupedByModelRanges(e,i)){const re=ie.modelRange.startLineNumber,le=this.model.guides.getLinesBracketGuides(re,ie.modelRange.endLineNumber,S,_);for(const me of ie.viewLines){const Be=le[me.modelLineNumber-re].map(Re=>{if(Re.forWrappedLinesAfterColumn!==-1&&this.modelLineProjections[me.modelLineNumber-1].getViewPositionOfModelPosition(0,Re.forWrappedLinesAfterColumn).lineNumber>=me.modelLineWrappedLineIdx||Re.forWrappedLinesBeforeOrAtColumn!==-1&&this.modelLineProjections[me.modelLineNumber-1].getViewPositionOfModelPosition(0,Re.forWrappedLinesBeforeOrAtColumn).lineNumber<me.modelLineWrappedLineIdx)return;if(!Re.horizontalLine)return Re;let Je=-1;if(Re.column!==-1){const mt=this.modelLineProjections[me.modelLineNumber-1].getViewPositionOfModelPosition(0,Re.column);if(mt.lineNumber===me.modelLineWrappedLineIdx)Je=mt.column;else if(mt.lineNumber<me.modelLineWrappedLineIdx)Je=this.getMinColumnOfViewLine(me);else if(mt.lineNumber>me.modelLineWrappedLineIdx)return}const st=this.convertModelPositionToViewPosition(me.modelLineNumber,Re.horizontalLine.endColumn),ct=this.modelLineProjections[me.modelLineNumber-1].getViewPositionOfModelPosition(0,Re.horizontalLine.endColumn);return ct.lineNumber===me.modelLineWrappedLineIdx?new Cn.TH(Re.visibleColumn,Je,Re.className,new Cn.pv(Re.horizontalLine.top,st.column),-1,-1):ct.lineNumber<me.modelLineWrappedLineIdx||Re.visibleColumn!==-1?void 0:new Cn.TH(Re.visibleColumn,Je,Re.className,new Cn.pv(Re.horizontalLine.top,this.getMaxColumnOfViewLine(me)),-1,-1)});z.push(Be.filter(Re=>!!Re))}}return z}getViewLinesIndentGuides(e,i){e=this._toValidViewLineNumber(e),i=this._toValidViewLineNumber(i);const r=this.convertViewPositionToModelPosition(e,this.getViewLineMinColumn(e)),_=this.convertViewPositionToModelPosition(i,this.getViewLineMaxColumn(i));let S=[];const z=[],ie=[],re=r.lineNumber-1,le=_.lineNumber-1;let me=null;for(let Je=re;Je<=le;Je++){const st=this.modelLineProjections[Je];if(st.isVisible()){const ct=st.getViewLineNumberOfModelPosition(0,Je===re?r.column:1),mt=st.getViewLineNumberOfModelPosition(0,this.model.getLineMaxColumn(Je+1)),xt=mt-ct+1;let Dt=0;xt>1&&st.getViewLineMinColumn(this.model,Je+1,mt)===1&&(Dt=ct===0?1:2),z.push(xt),ie.push(Dt),me===null&&(me=new Nt.y(Je+1,0))}else me!==null&&(S=S.concat(this.model.guides.getLinesIndentGuides(me.lineNumber,Je)),me=null)}me!==null&&(S=S.concat(this.model.guides.getLinesIndentGuides(me.lineNumber,_.lineNumber)),me=null);const we=i-e+1,Be=new Array(we);let Re=0;for(let Je=0,st=S.length;Je<st;Je++){let ct=S[Je];const mt=Math.min(we-Re,z[Je]),xt=ie[Je];let Dt;xt===2?Dt=0:xt===1?Dt=1:Dt=mt;for(let Jt=0;Jt<mt;Jt++)Jt===Dt&&(ct=0),Be[Re++]=ct}return Be}getViewLineContent(e){const i=this.getViewLineInfo(e);return this.modelLineProjections[i.modelLineNumber-1].getViewLineContent(this.model,i.modelLineNumber,i.modelLineWrappedLineIdx)}getViewLineLength(e){const i=this.getViewLineInfo(e);return this.modelLineProjections[i.modelLineNumber-1].getViewLineLength(this.model,i.modelLineNumber,i.modelLineWrappedLineIdx)}getViewLineMinColumn(e){const i=this.getViewLineInfo(e);return this.modelLineProjections[i.modelLineNumber-1].getViewLineMinColumn(this.model,i.modelLineNumber,i.modelLineWrappedLineIdx)}getViewLineMaxColumn(e){const i=this.getViewLineInfo(e);return this.modelLineProjections[i.modelLineNumber-1].getViewLineMaxColumn(this.model,i.modelLineNumber,i.modelLineWrappedLineIdx)}getViewLineData(e){const i=this.getViewLineInfo(e);return this.modelLineProjections[i.modelLineNumber-1].getViewLineData(this.model,i.modelLineNumber,i.modelLineWrappedLineIdx)}getViewLinesData(e,i,r){e=this._toValidViewLineNumber(e),i=this._toValidViewLineNumber(i);const _=this.projectedModelLineLineCounts.getIndexOf(e-1);let S=e;const z=_.index,ie=_.remainder,re=[];for(let le=z,me=this.model.getLineCount();le<me;le++){const we=this.modelLineProjections[le];if(!we.isVisible())continue;const Be=le===z?ie:0;let Re=we.getViewLineCount()-Be,Je=!1;if(S+Re>i&&(Je=!0,Re=i-S+1),we.getViewLinesData(this.model,le+1,Be,Re,S-e,r,re),S+=Re,Je)break}return re}validateViewPosition(e,i,r){e=this._toValidViewLineNumber(e);const _=this.projectedModelLineLineCounts.getIndexOf(e-1),S=_.index,z=_.remainder,ie=this.modelLineProjections[S],re=ie.getViewLineMinColumn(this.model,S+1,z),le=ie.getViewLineMaxColumn(this.model,S+1,z);i<re&&(i=re),i>le&&(i=le);const me=ie.getModelColumnOfViewPosition(z,i);return this.model.validatePosition(new Nt.y(S+1,me)).equals(r)?new Nt.y(e,i):this.convertModelPositionToViewPosition(r.lineNumber,r.column)}validateViewRange(e,i){const r=this.validateViewPosition(e.startLineNumber,e.startColumn,i.getStartPosition()),_=this.validateViewPosition(e.endLineNumber,e.endColumn,i.getEndPosition());return new Pt.Q(r.lineNumber,r.column,_.lineNumber,_.column)}convertViewPositionToModelPosition(e,i){const r=this.getViewLineInfo(e),_=this.modelLineProjections[r.modelLineNumber-1].getModelColumnOfViewPosition(r.modelLineWrappedLineIdx,i);return this.model.validatePosition(new Nt.y(r.modelLineNumber,_))}convertViewRangeToModelRange(e){const i=this.convertViewPositionToModelPosition(e.startLineNumber,e.startColumn),r=this.convertViewPositionToModelPosition(e.endLineNumber,e.endColumn);return new Pt.Q(i.lineNumber,i.column,r.lineNumber,r.column)}convertModelPositionToViewPosition(e,i,r=2){const _=this.model.validatePosition(new Nt.y(e,i)),S=_.lineNumber,z=_.column;let ie=S-1,re=!1;for(;ie>0&&!this.modelLineProjections[ie].isVisible();)ie--,re=!0;if(ie===0&&!this.modelLineProjections[ie].isVisible())return new Nt.y(1,1);const le=1+this.projectedModelLineLineCounts.getPrefixSum(ie);let me;return re?me=this.modelLineProjections[ie].getViewPositionOfModelPosition(le,this.model.getLineMaxColumn(ie+1),r):me=this.modelLineProjections[S-1].getViewPositionOfModelPosition(le,z,r),me}convertModelRangeToViewRange(e,i=0){if(e.isEmpty()){const r=this.convertModelPositionToViewPosition(e.startLineNumber,e.startColumn,i);return Pt.Q.fromPositions(r)}else{const r=this.convertModelPositionToViewPosition(e.startLineNumber,e.startColumn,1),_=this.convertModelPositionToViewPosition(e.endLineNumber,e.endColumn,0);return new Pt.Q(r.lineNumber,r.column,_.lineNumber,_.column)}}getViewLineNumberOfModelPosition(e,i){let r=e-1;if(this.modelLineProjections[r].isVisible()){const S=1+this.projectedModelLineLineCounts.getPrefixSum(r);return this.modelLineProjections[r].getViewLineNumberOfModelPosition(S,i)}for(;r>0&&!this.modelLineProjections[r].isVisible();)r--;if(r===0&&!this.modelLineProjections[r].isVisible())return 1;const _=1+this.projectedModelLineLineCounts.getPrefixSum(r);return this.modelLineProjections[r].getViewLineNumberOfModelPosition(_,this.model.getLineMaxColumn(r+1))}getDecorationsInRange(e,i,r){const _=this.convertViewPositionToModelPosition(e.startLineNumber,e.startColumn),S=this.convertViewPositionToModelPosition(e.endLineNumber,e.endColumn);if(S.lineNumber-_.lineNumber<=e.endLineNumber-e.startLineNumber)return this.model.getDecorationsInRange(new Pt.Q(_.lineNumber,1,S.lineNumber,S.column),i,r);let z=[];const ie=_.lineNumber-1,re=S.lineNumber-1;let le=null;for(let Re=ie;Re<=re;Re++)if(this.modelLineProjections[Re].isVisible())le===null&&(le=new Nt.y(Re+1,Re===ie?_.column:1));else if(le!==null){const st=this.model.getLineMaxColumn(Re);z=z.concat(this.model.getDecorationsInRange(new Pt.Q(le.lineNumber,le.column,Re,st),i,r)),le=null}le!==null&&(z=z.concat(this.model.getDecorationsInRange(new Pt.Q(le.lineNumber,le.column,S.lineNumber,S.column),i,r)),le=null),z.sort((Re,Je)=>{const st=Pt.Q.compareRangesUsingStarts(Re.range,Je.range);return st===0?Re.id<Je.id?-1:Re.id>Je.id?1:0:st});const me=[];let we=0,Be=null;for(const Re of z){const Je=Re.id;Be!==Je&&(Be=Je,me[we++]=Re)}return me}getInjectedTextAt(e){const i=this.getViewLineInfo(e.lineNumber);return this.modelLineProjections[i.modelLineNumber-1].getInjectedTextAt(i.modelLineWrappedLineIdx,e.column)}normalizePosition(e,i){const r=this.getViewLineInfo(e.lineNumber);return this.modelLineProjections[r.modelLineNumber-1].normalizePosition(r.modelLineWrappedLineIdx,e,i)}getLineIndentColumn(e){const i=this.getViewLineInfo(e);return i.modelLineWrappedLineIdx===0?this.model.getLineIndentColumn(i.modelLineNumber):0}}function ro(Le){if(Le.length===0)return[];const e=Le.slice();e.sort(Pt.Q.compareRangesUsingStarts);const i=[];let r=e[0].startLineNumber,_=e[0].endLineNumber;for(let S=1,z=e.length;S<z;S++){const ie=e[S];ie.startLineNumber>_+1?(i.push(new Pt.Q(r,1,_,1)),r=ie.startLineNumber,_=ie.endLineNumber):ie.endLineNumber>_&&(_=ie.endLineNumber)}return i.push(new Pt.Q(r,1,_,1)),i}class yo{constructor(e,i){this.modelLineNumber=e,this.modelLineWrappedLineIdx=i}}class Bs{constructor(e,i){this.modelRange=e,this.viewLines=i}}class Lr{constructor(e){this._lines=e}convertViewPositionToModelPosition(e){return this._lines.convertViewPositionToModelPosition(e.lineNumber,e.column)}convertViewRangeToModelRange(e){return this._lines.convertViewRangeToModelRange(e)}validateViewPosition(e,i){return this._lines.validateViewPosition(e.lineNumber,e.column,i)}validateViewRange(e,i){return this._lines.validateViewRange(e,i)}convertModelPositionToViewPosition(e,i){return this._lines.convertModelPositionToViewPosition(e.lineNumber,e.column,i)}convertModelRangeToViewRange(e,i){return this._lines.convertModelRangeToViewRange(e,i)}modelPositionIsVisible(e){return this._lines.modelPositionIsVisible(e.lineNumber,e.column)}getModelLineViewLineCount(e){return this._lines.getModelLineViewLineCount(e)}getViewLineNumberOfModelPosition(e,i){return this._lines.getViewLineNumberOfModelPosition(e,i)}}class So{constructor(e){this.model=e}dispose(){}createCoordinatesConverter(){return new ao(this)}getHiddenAreas(){return[]}setHiddenAreas(e){return!1}setTabSize(e){return!1}setWrappingSettings(e,i,r,_){return!1}createLineBreaksComputer(){const e=[];return{addRequest:(i,r,_)=>{e.push(null)},finalize:()=>e}}onModelFlushed(){}onModelLinesDeleted(e,i,r){return new Js(i,r)}onModelLinesInserted(e,i,r,_){return new qs(i,r)}onModelLineChanged(e,i,r){return[!1,new Ws(i,1),null,null]}acceptVersionId(e){}getViewLineCount(){return this.model.getLineCount()}getActiveIndentGuide(e,i,r){return{startLineNumber:e,endLineNumber:e,indent:0}}getViewLinesBracketGuides(e,i,r){return new Array(i-e+1).fill([])}getViewLinesIndentGuides(e,i){const r=i-e+1,_=new Array(r);for(let S=0;S<r;S++)_[S]=0;return _}getViewLineContent(e){return this.model.getLineContent(e)}getViewLineLength(e){return this.model.getLineLength(e)}getViewLineMinColumn(e){return this.model.getLineMinColumn(e)}getViewLineMaxColumn(e){return this.model.getLineMaxColumn(e)}getViewLineData(e){const i=this.model.tokenization.getLineTokens(e),r=i.getLineContent();return new Nn.GP(r,!1,1,r.length+1,0,i.inflate(),null)}getViewLinesData(e,i,r){const _=this.model.getLineCount();e=Math.min(Math.max(1,e),_),i=Math.min(Math.max(1,i),_);const S=[];for(let z=e;z<=i;z++){const ie=z-e;S[ie]=r[ie]?this.getViewLineData(z):null}return S}getDecorationsInRange(e,i,r){return this.model.getDecorationsInRange(e,i,r)}normalizePosition(e,i){return this.model.normalizePosition(e,i)}getLineIndentColumn(e){return this.model.getLineIndentColumn(e)}getInjectedTextAt(e){return null}}class ao{constructor(e){this._lines=e}_validPosition(e){return this._lines.model.validatePosition(e)}_validRange(e){return this._lines.model.validateRange(e)}convertViewPositionToModelPosition(e){return this._validPosition(e)}convertViewRangeToModelRange(e){return this._validRange(e)}validateViewPosition(e,i){return this._validPosition(i)}validateViewRange(e,i){return this._validRange(i)}convertModelPositionToViewPosition(e){return this._validPosition(e)}convertModelRangeToViewRange(e){return this._validRange(e)}modelPositionIsVisible(e){const i=this._lines.model.getLineCount();return!(e.lineNumber<1||e.lineNumber>i)}getModelLineViewLineCount(e){return 1}getViewLineNumberOfModelPosition(e,i){return e}}const qo=!0;class Lo extends p.jG{constructor(e,i,r,_,S,z,ie,re){if(super(),this.languageConfigurationService=ie,this._themeService=re,this._editorId=e,this._configuration=i,this.model=r,this._eventDispatcher=new Go,this.onEvent=this._eventDispatcher.onEvent,this.cursorConfig=new rn.d$(this.model.getLanguageId(),this.model.getOptions(),this._configuration,this.languageConfigurationService),this._tokenizeViewportSoon=this._register(new Se.uC(()=>this.tokenizeViewport(),50)),this._updateConfigurationViewLineCount=this._register(new Se.uC(()=>this._updateConfigurationViewLineCountNow(),0)),this._hasFocus=!1,this._viewportStart=ws.create(this.model),qo&&this.model.isTooLargeForTokenization())this._lines=new So(this.model);else{const le=this._configuration.options,me=le.get(46),we=le.get(127),Be=le.get(134),Re=le.get(126);this._lines=new Br(this._editorId,this.model,_,S,me,this.model.getOptions().tabSize,we,Be.wrappingColumn,Re)}this.coordinatesConverter=this._lines.createCoordinatesConverter(),this._cursor=this._register(new bs(r,this,this.coordinatesConverter,this.cursorConfig)),this.viewLayout=this._register(new Zo(this._configuration,this.getLineCount(),z)),this._register(this.viewLayout.onDidScroll(le=>{le.scrollTopChanged&&this._tokenizeViewportSoon.schedule(),le.scrollTopChanged&&this._viewportStart.invalidate(),this._eventDispatcher.emitSingleViewEvent(new _o(le)),this._eventDispatcher.emitOutgoingEvent(new ss(le.oldScrollWidth,le.oldScrollLeft,le.oldScrollHeight,le.oldScrollTop,le.scrollWidth,le.scrollLeft,le.scrollHeight,le.scrollTop))})),this._register(this.viewLayout.onDidContentSizeChange(le=>{this._eventDispatcher.emitOutgoingEvent(le)})),this._decorations=new Yo.UB(this._editorId,this.model,this._configuration,this._lines,this.coordinatesConverter),this._registerModelEvents(),this._register(this._configuration.onDidChangeFast(le=>{try{const me=this._eventDispatcher.beginEmitViewEvents();this._onConfigurationChanged(me,le)}finally{this._eventDispatcher.endEmitViewEvents()}})),this._register($n.getInstance().onDidChange(()=>{this._eventDispatcher.emitSingleViewEvent(new vo)})),this._register(this._themeService.onDidColorThemeChange(le=>{this._invalidateDecorationsColorCache(),this._eventDispatcher.emitSingleViewEvent(new jo(le))})),this._updateConfigurationViewLineCountNow()}dispose(){super.dispose(),this._decorations.dispose(),this._lines.dispose(),this._viewportStart.dispose(),this._eventDispatcher.dispose()}createLineBreaksComputer(){return this._lines.createLineBreaksComputer()}addViewEventHandler(e){this._eventDispatcher.addViewEventHandler(e)}removeViewEventHandler(e){this._eventDispatcher.removeViewEventHandler(e)}_updateConfigurationViewLineCountNow(){this._configuration.setViewLineCount(this._lines.getViewLineCount())}tokenizeViewport(){const e=this.viewLayout.getLinesViewportData(),i=new Pt.Q(e.startLineNumber,this.getLineMinColumn(e.startLineNumber),e.endLineNumber,this.getLineMaxColumn(e.endLineNumber)),r=this._toModelVisibleRanges(i);for(const _ of r)this.model.tokenization.tokenizeViewport(_.startLineNumber,_.endLineNumber)}setHasFocus(e){this._hasFocus=e,this._cursor.setHasFocus(e),this._eventDispatcher.emitSingleViewEvent(new Gn(e)),this._eventDispatcher.emitOutgoingEvent(new Es(!e,e))}onCompositionStart(){this._eventDispatcher.emitSingleViewEvent(new Ls)}onCompositionEnd(){this._eventDispatcher.emitSingleViewEvent(new _r)}_onConfigurationChanged(e,i){let r=null;if(this._viewportStart.isValid){const me=new Nt.y(this._viewportStart.viewLineNumber,this.getLineMinColumn(this._viewportStart.viewLineNumber));r=this.coordinatesConverter.convertViewPositionToModelPosition(me)}let _=!1;const S=this._configuration.options,z=S.get(46),ie=S.get(127),re=S.get(134),le=S.get(126);if(this._lines.setWrappingSettings(z,ie,re.wrappingColumn,le)&&(e.emitViewEvent(new Ms),e.emitViewEvent(new Ns),e.emitViewEvent(new vs(null)),this._cursor.onLineMappingChanged(e),this._decorations.onLineMappingChanged(),this.viewLayout.onFlushed(this.getLineCount()),this.viewLayout.getCurrentScrollTop()!==0&&(_=!0),this._updateConfigurationViewLineCount.schedule()),i.hasChanged(83)&&(this._decorations.reset(),e.emitViewEvent(new vs(null))),e.emitViewEvent(new vr(i)),this.viewLayout.onConfigurationChanged(i),_&&r){const me=this.coordinatesConverter.convertModelPositionToViewPosition(r),we=this.viewLayout.getVerticalOffsetForLineNumber(me.lineNumber);this.viewLayout.setScrollPosition({scrollTop:we+this._viewportStart.startLineDelta},1)}rn.d$.shouldRecreate(i)&&(this.cursorConfig=new rn.d$(this.model.getLanguageId(),this.model.getOptions(),this._configuration,this.languageConfigurationService),this._cursor.updateConfiguration(this.cursorConfig))}_registerModelEvents(){this._register(this.model.onDidChangeContentOrInjectedText(e=>{try{const r=this._eventDispatcher.beginEmitViewEvents();let _=!1,S=!1;const z=e instanceof us.Ic?e.rawContentChangedEvent.changes:e.changes,ie=e instanceof us.Ic?e.rawContentChangedEvent.versionId:null,re=this._lines.createLineBreaksComputer();for(const we of z)switch(we.changeType){case 4:{for(let Be=0;Be<we.detail.length;Be++){const Re=we.detail[Be];let Je=we.injectedTexts[Be];Je&&(Je=Je.filter(st=>!st.ownerId||st.ownerId===this._editorId)),re.addRequest(Re,Je,null)}break}case 2:{let Be=null;we.injectedText&&(Be=we.injectedText.filter(Re=>!Re.ownerId||Re.ownerId===this._editorId)),re.addRequest(we.detail,Be,null);break}}const le=re.finalize(),me=new h.j3(le);for(const we of z)switch(we.changeType){case 1:{this._lines.onModelFlushed(),r.emitViewEvent(new Ms),this._decorations.reset(),this.viewLayout.onFlushed(this.getLineCount()),_=!0;break}case 3:{const Be=this._lines.onModelLinesDeleted(ie,we.fromLineNumber,we.toLineNumber);Be!==null&&(r.emitViewEvent(Be),this.viewLayout.onLinesDeleted(Be.fromLineNumber,Be.toLineNumber)),_=!0;break}case 4:{const Be=me.takeCount(we.detail.length),Re=this._lines.onModelLinesInserted(ie,we.fromLineNumber,we.toLineNumber,Be);Re!==null&&(r.emitViewEvent(Re),this.viewLayout.onLinesInserted(Re.fromLineNumber,Re.toLineNumber)),_=!0;break}case 2:{const Be=me.dequeue(),[Re,Je,st,ct]=this._lines.onModelLineChanged(ie,we.lineNumber,Be);S=Re,Je&&r.emitViewEvent(Je),st&&(r.emitViewEvent(st),this.viewLayout.onLinesInserted(st.fromLineNumber,st.toLineNumber)),ct&&(r.emitViewEvent(ct),this.viewLayout.onLinesDeleted(ct.fromLineNumber,ct.toLineNumber));break}case 5:break}ie!==null&&this._lines.acceptVersionId(ie),this.viewLayout.onHeightMaybeChanged(),!_&&S&&(r.emitViewEvent(new Ns),r.emitViewEvent(new vs(null)),this._cursor.onLineMappingChanged(r),this._decorations.onLineMappingChanged())}finally{this._eventDispatcher.endEmitViewEvents()}const i=this._viewportStart.isValid;if(this._viewportStart.invalidate(),this._configuration.setModelLineCount(this.model.getLineCount()),this._updateConfigurationViewLineCountNow(),!this._hasFocus&&this.model.getAttachedEditorCount()>=2&&i){const r=this.model._getTrackedRange(this._viewportStart.modelTrackedRange);if(r){const _=this.coordinatesConverter.convertModelPositionToViewPosition(r.getStartPosition()),S=this.viewLayout.getVerticalOffsetForLineNumber(_.lineNumber);this.viewLayout.setScrollPosition({scrollTop:S+this._viewportStart.startLineDelta},1)}}try{const r=this._eventDispatcher.beginEmitViewEvents();e instanceof us.Ic&&r.emitOutgoingEvent(new ri(e.contentChangedEvent)),this._cursor.onModelContentChanged(r,e)}finally{this._eventDispatcher.endEmitViewEvents()}this._tokenizeViewportSoon.schedule()})),this._register(this.model.onDidChangeTokens(e=>{const i=[];for(let r=0,_=e.ranges.length;r<_;r++){const S=e.ranges[r],z=this.coordinatesConverter.convertModelPositionToViewPosition(new Nt.y(S.fromLineNumber,1)).lineNumber,ie=this.coordinatesConverter.convertModelPositionToViewPosition(new Nt.y(S.toLineNumber,this.model.getLineMaxColumn(S.toLineNumber))).lineNumber;i[r]={fromLineNumber:z,toLineNumber:ie}}this._eventDispatcher.emitSingleViewEvent(new Ko(i)),e.tokenizationSupportChanged&&this._tokenizeViewportSoon.schedule(),this._eventDispatcher.emitOutgoingEvent(new bo(e))})),this._register(this.model.onDidChangeLanguageConfiguration(e=>{this._eventDispatcher.emitSingleViewEvent(new Xs),this.cursorConfig=new rn.d$(this.model.getLanguageId(),this.model.getOptions(),this._configuration,this.languageConfigurationService),this._cursor.updateConfiguration(this.cursorConfig),this._eventDispatcher.emitOutgoingEvent(new os(e))})),this._register(this.model.onDidChangeLanguage(e=>{this.cursorConfig=new rn.d$(this.model.getLanguageId(),this.model.getOptions(),this._configuration,this.languageConfigurationService),this._cursor.updateConfiguration(this.cursorConfig),this._eventDispatcher.emitOutgoingEvent(new Cs(e))})),this._register(this.model.onDidChangeOptions(e=>{if(this._lines.setTabSize(this.model.getOptions().tabSize)){try{const i=this._eventDispatcher.beginEmitViewEvents();i.emitViewEvent(new Ms),i.emitViewEvent(new Ns),i.emitViewEvent(new vs(null)),this._cursor.onLineMappingChanged(i),this._decorations.onLineMappingChanged(),this.viewLayout.onFlushed(this.getLineCount())}finally{this._eventDispatcher.endEmitViewEvents()}this._updateConfigurationViewLineCount.schedule()}this.cursorConfig=new rn.d$(this.model.getLanguageId(),this.model.getOptions(),this._configuration,this.languageConfigurationService),this._cursor.updateConfiguration(this.cursorConfig),this._eventDispatcher.emitOutgoingEvent(new io(e))})),this._register(this.model.onDidChangeDecorations(e=>{this._decorations.onModelDecorationsChanged(),this._eventDispatcher.emitSingleViewEvent(new vs(e)),this._eventDispatcher.emitOutgoingEvent(new Qo(e))}))}setHiddenAreas(e){let i=!1;try{const r=this._eventDispatcher.beginEmitViewEvents();i=this._lines.setHiddenAreas(e),i&&(r.emitViewEvent(new Ms),r.emitViewEvent(new Ns),r.emitViewEvent(new vs(null)),this._cursor.onLineMappingChanged(r),this._decorations.onLineMappingChanged(),this.viewLayout.onFlushed(this.getLineCount()),this.viewLayout.onHeightMaybeChanged())}finally{this._eventDispatcher.endEmitViewEvents()}this._updateConfigurationViewLineCount.schedule(),i&&this._eventDispatcher.emitOutgoingEvent(new Co)}getVisibleRangesPlusViewportAboveBelow(){const e=this._configuration.options.get(133),i=this._configuration.options.get(61),r=Math.max(20,Math.round(e.height/i)),_=this.viewLayout.getLinesViewportData(),S=Math.max(1,_.completelyVisibleStartLineNumber-r),z=Math.min(this.getLineCount(),_.completelyVisibleEndLineNumber+r);return this._toModelVisibleRanges(new Pt.Q(S,this.getLineMinColumn(S),z,this.getLineMaxColumn(z)))}getVisibleRanges(){const e=this.getCompletelyVisibleViewRange();return this._toModelVisibleRanges(e)}getHiddenAreas(){return this._lines.getHiddenAreas()}_toModelVisibleRanges(e){const i=this.coordinatesConverter.convertViewRangeToModelRange(e),r=this._lines.getHiddenAreas();if(r.length===0)return[i];const _=[];let S=0,z=i.startLineNumber,ie=i.startColumn;const re=i.endLineNumber,le=i.endColumn;for(let me=0,we=r.length;me<we;me++){const Be=r[me].startLineNumber,Re=r[me].endLineNumber;Re<z||Be>re||(z<Be&&(_[S++]=new Pt.Q(z,ie,Be-1,this.model.getLineMaxColumn(Be-1))),z=Re+1,ie=1)}return(z<re||z===re&&ie<le)&&(_[S++]=new Pt.Q(z,ie,re,le)),_}getCompletelyVisibleViewRange(){const e=this.viewLayout.getLinesViewportData(),i=e.completelyVisibleStartLineNumber,r=e.completelyVisibleEndLineNumber;return new Pt.Q(i,this.getLineMinColumn(i),r,this.getLineMaxColumn(r))}getCompletelyVisibleViewRangeAtScrollTop(e){const i=this.viewLayout.getLinesViewportDataAtScrollTop(e),r=i.completelyVisibleStartLineNumber,_=i.completelyVisibleEndLineNumber;return new Pt.Q(r,this.getLineMinColumn(r),_,this.getLineMaxColumn(_))}saveState(){const e=this.viewLayout.saveState(),i=e.scrollTop,r=this.viewLayout.getLineNumberAtVerticalOffset(i),_=this.coordinatesConverter.convertViewPositionToModelPosition(new Nt.y(r,this.getLineMinColumn(r))),S=this.viewLayout.getVerticalOffsetForLineNumber(r)-i;return{scrollLeft:e.scrollLeft,firstPosition:_,firstPositionDeltaTop:S}}reduceRestoreState(e){if(typeof e.firstPosition>"u")return this._reduceRestoreStateCompatibility(e);const i=this.model.validatePosition(e.firstPosition),r=this.coordinatesConverter.convertModelPositionToViewPosition(i),_=this.viewLayout.getVerticalOffsetForLineNumber(r.lineNumber)-e.firstPositionDeltaTop;return{scrollLeft:e.scrollLeft,scrollTop:_}}_reduceRestoreStateCompatibility(e){return{scrollLeft:e.scrollLeft,scrollTop:e.scrollTopWithoutViewZones}}getTabSize(){return this.model.getOptions().tabSize}getLineCount(){return this._lines.getViewLineCount()}setViewport(e,i,r){this._viewportStart.update(this,e)}getActiveIndentGuide(e,i,r){return this._lines.getActiveIndentGuide(e,i,r)}getLinesIndentGuides(e,i){return this._lines.getViewLinesIndentGuides(e,i)}getBracketGuidesInRangeByLine(e,i,r,_){return this._lines.getViewLinesBracketGuides(e,i,r,_)}getLineContent(e){return this._lines.getViewLineContent(e)}getLineLength(e){return this._lines.getViewLineLength(e)}getLineMinColumn(e){return this._lines.getViewLineMinColumn(e)}getLineMaxColumn(e){return this._lines.getViewLineMaxColumn(e)}getLineFirstNonWhitespaceColumn(e){const i=at.HG(this.getLineContent(e));return i===-1?0:i+1}getLineLastNonWhitespaceColumn(e){const i=at.lT(this.getLineContent(e));return i===-1?0:i+2}getDecorationsInViewport(e){return this._decorations.getDecorationsViewportData(e).decorations}getInjectedTextAt(e){return this._lines.getInjectedTextAt(e)}getViewportViewLineRenderingData(e,i){const _=this._decorations.getDecorationsViewportData(e).inlineDecorations[i-e.startLineNumber];return this._getViewLineRenderingData(i,_)}getViewLineRenderingData(e){const i=this._decorations.getInlineDecorationsOnLine(e);return this._getViewLineRenderingData(e,i)}_getViewLineRenderingData(e,i){const r=this.model.mightContainRTL(),_=this.model.mightContainNonBasicASCII(),S=this.getTabSize(),z=this._lines.getViewLineData(e);return z.inlineDecorations&&(i=[...i,...z.inlineDecorations.map(ie=>ie.toInlineDecoration(e))]),new Nn.qL(z.minColumn,z.maxColumn,z.content,z.continuesWithWrappedLine,r,_,z.tokens,i,S,z.startVisibleColumn)}getViewLineData(e){return this._lines.getViewLineData(e)}getMinimapLinesRenderingData(e,i,r){const _=this._lines.getViewLinesData(e,i,r);return new Nn.nt(this.getTabSize(),_)}getAllOverviewRulerDecorations(e){const i=this.model.getOverviewRulerDecorations(this._editorId,(0,W.$C)(this._configuration.options)),r=new er;for(const _ of i){const S=_.options,z=S.overviewRuler;if(!z)continue;const ie=z.position;if(ie===0)continue;const re=z.getColor(e.value),le=this.coordinatesConverter.getViewLineNumberOfModelPosition(_.range.startLineNumber,_.range.startColumn),me=this.coordinatesConverter.getViewLineNumberOfModelPosition(_.range.endLineNumber,_.range.endColumn);r.accept(re,S.zIndex,le,me,ie)}return r.asArray}_invalidateDecorationsColorCache(){const e=this.model.getOverviewRulerDecorations();for(const i of e){const r=i.options.overviewRuler;r&&r.invalidateCachedColor();const _=i.options.minimap;_&&_.invalidateCachedColor()}}getValueInRange(e,i){const r=this.coordinatesConverter.convertViewRangeToModelRange(e);return this.model.getValueInRange(r,i)}deduceModelPositionRelativeToViewPosition(e,i,r){const _=this.coordinatesConverter.convertViewPositionToModelPosition(e);this.model.getEOL().length===2&&(i<0?i-=r:i+=r);const z=this.model.getOffsetAt(_)+i;return this.model.getPositionAt(z)}getPlainTextToCopy(e,i,r){const _=r?`\r `:this.model.getEOL();e=e.slice(0),e.sort(Pt.Q.compareRangesUsingStarts);let S=!1,z=!1;for(const re of e)re.isEmpty()?S=!0:z=!0;if(!z){if(!i)return"";const re=e.map(me=>me.startLineNumber);let le="";for(let me=0;me<re.length;me++)me>0&&re[me-1]===re[me]||(le+=this.model.getLineContent(re[me])+_);return le}if(S&&i){const re=[];let le=0;for(const me of e){const we=me.startLineNumber;me.isEmpty()?we!==le&&re.push(this.model.getLineContent(we)):re.push(this.model.getValueInRange(me,r?2:0)),le=we}return re.length===1?re[0]:re}const ie=[];for(const re of e)re.isEmpty()||ie.push(this.model.getValueInRange(re,r?2:0));return ie.length===1?ie[0]:ie}getRichTextToCopy(e,i){const r=this.model.getLanguageId();if(r===Wn.vH||e.length!==1)return null;let _=e[0];if(_.isEmpty()){if(!i)return null;const me=_.startLineNumber;_=new Pt.Q(me,this.model.getLineMinColumn(me),me,this.model.getLineMaxColumn(me))}const S=this._configuration.options.get(46),z=this._getColorMap(),re=/[:;\\\/<>]/.test(S.fontFamily)||S.fontFamily===W.jU.fontFamily;let le;return re?le=W.jU.fontFamily:(le=S.fontFamily,le=le.replace(/"/g,"'"),/[,']/.test(le)||/[+ ]/.test(le)&&(le=`'${le}'`),le=`${le}, ${W.jU.fontFamily}`),{mode:r,html:`<div style="color: ${z[1]};background-color: ${z[2]};font-family: ${le};font-weight: ${S.fontWeight};font-size: ${S.fontSize}px;line-height: ${S.lineHeight}px;white-space: pre;">`+this._getHTMLToCopy(_,z)+"</div>"}}_getHTMLToCopy(e,i){const r=e.startLineNumber,_=e.startColumn,S=e.endLineNumber,z=e.endColumn,ie=this.getTabSize();let re="";for(let le=r;le<=S;le++){const me=this.model.tokenization.getLineTokens(le),we=me.getLineContent(),Be=le===r?_-1:0,Re=le===S?z-1:we.length;we===""?re+="<br>":re+=(0,Qn.s0)(we,me.inflate(),i,Be,Re,ie,u.uF)}return re}_getColorMap(){const e=Ue.dG.getColorMap(),i=["#000000"];if(e)for(let r=1,_=e.length;r<_;r++)i[r]=ei.Q1.Format.CSS.formatHex(e[r]);return i}getPrimaryCursorState(){return this._cursor.getPrimaryCursorState()}getLastAddedCursorIndex(){return this._cursor.getLastAddedCursorIndex()}getCursorStates(){return this._cursor.getCursorStates()}setCursorStates(e,i,r){return this._withViewEventsCollector(_=>this._cursor.setStates(_,e,i,r))}getCursorColumnSelectData(){return this._cursor.getCursorColumnSelectData()}getCursorAutoClosedCharacters(){return this._cursor.getAutoClosedCharacters()}setCursorColumnSelectData(e){this._cursor.setCursorColumnSelectData(e)}getPrevEditOperationType(){return this._cursor.getPrevEditOperationType()}setPrevEditOperationType(e){this._cursor.setPrevEditOperationType(e)}getSelection(){return this._cursor.getSelection()}getSelections(){return this._cursor.getSelections()}getPosition(){return this._cursor.getPrimaryCursorState().modelState.position}setSelections(e,i,r=0){this._withViewEventsCollector(_=>this._cursor.setSelections(_,e,i,r))}saveCursorState(){return this._cursor.saveState()}restoreCursorState(e){this._withViewEventsCollector(i=>this._cursor.restoreState(i,e))}_executeCursorEdit(e){if(this._cursor.context.cursorConfig.readOnly){this._eventDispatcher.emitOutgoingEvent(new to);return}this._withViewEventsCollector(e)}executeEdits(e,i,r){this._executeCursorEdit(_=>this._cursor.executeEdits(_,e,i,r))}startComposition(){this._executeCursorEdit(e=>this._cursor.startComposition(e))}endComposition(e){this._executeCursorEdit(i=>this._cursor.endComposition(i,e))}type(e,i){this._executeCursorEdit(r=>this._cursor.type(r,e,i))}compositionType(e,i,r,_,S){this._executeCursorEdit(z=>this._cursor.compositionType(z,e,i,r,_,S))}paste(e,i,r,_){this._executeCursorEdit(S=>this._cursor.paste(S,e,i,r,_))}cut(e){this._executeCursorEdit(i=>this._cursor.cut(i,e))}executeCommand(e,i){this._executeCursorEdit(r=>this._cursor.executeCommand(r,e,i))}executeCommands(e,i){this._executeCursorEdit(r=>this._cursor.executeCommands(r,e,i))}revealPrimaryCursor(e,i,r=!1){this._withViewEventsCollector(_=>this._cursor.revealPrimary(_,e,r,0,i,0))}revealTopMostCursor(e){const i=this._cursor.getTopMostViewPosition(),r=new Pt.Q(i.lineNumber,i.column,i.lineNumber,i.column);this._withViewEventsCollector(_=>_.emitViewEvent(new Vs(e,!1,r,null,0,!0,0)))}revealBottomMostCursor(e){const i=this._cursor.getBottomMostViewPosition(),r=new Pt.Q(i.lineNumber,i.column,i.lineNumber,i.column);this._withViewEventsCollector(_=>_.emitViewEvent(new Vs(e,!1,r,null,0,!0,0)))}revealRange(e,i,r,_,S){this._withViewEventsCollector(z=>z.emitViewEvent(new Vs(e,!1,r,null,_,i,S)))}changeWhitespace(e){this.viewLayout.changeWhitespace(e)&&(this._eventDispatcher.emitSingleViewEvent(new $o),this._eventDispatcher.emitOutgoingEvent(new Ps))}_withViewEventsCollector(e){try{const i=this._eventDispatcher.beginEmitViewEvents();return e(i)}finally{this._eventDispatcher.endEmitViewEvents()}}normalizePosition(e,i){return this._lines.normalizePosition(e,i)}getLineIndentColumn(e){return this._lines.getLineIndentColumn(e)}}class ws{constructor(e,i,r,_,S){this._model=e,this._viewLineNumber=i,this._isValid=r,this._modelTrackedRange=_,this._startLineDelta=S}static create(e){const i=e._setTrackedRange(null,new Pt.Q(1,1,1,1),1);return new ws(e,1,!1,i,0)}get viewLineNumber(){return this._viewLineNumber}get isValid(){return this._isValid}get modelTrackedRange(){return this._modelTrackedRange}get startLineDelta(){return this._startLineDelta}dispose(){this._model._setTrackedRange(this._modelTrackedRange,null,1)}update(e,i){const r=e.coordinatesConverter.convertViewPositionToModelPosition(new Nt.y(i,e.getLineMinColumn(i))),_=e.model._setTrackedRange(this._modelTrackedRange,new Pt.Q(r.lineNumber,r.column,r.lineNumber,r.column),1),S=e.viewLayout.getVerticalOffsetForLineNumber(i),z=e.viewLayout.getCurrentScrollTop();this._viewLineNumber=i,this._isValid=!0,this._modelTrackedRange=_,this._startLineDelta=z-S}invalidate(){this._isValid=!1}}class er{constructor(){this._asMap=Object.create(null),this.asArray=[]}accept(e,i,r,_,S){const z=this._asMap[e];if(z){const ie=z.data,re=ie[ie.length-3],le=ie[ie.length-1];if(re===S&&le+1>=r){_>le&&(ie[ie.length-1]=_);return}ie.push(S,r,_)}else{const ie=new Nn.Uv(e,i,[S,r,_]);this._asMap[e]=ie,this.asArray.push(ie)}}}var tr=y(59715),Eo=y(96655),Jn=y(82399),ir=y(30657),ji=y(29879),Fr=y(27454);class Us{constructor(e,i,r,_,S){this.injectionOffsets=e,this.injectionOptions=i,this.breakOffsets=r,this.breakOffsetsVisibleColumn=_,this.wrappedTextIndentLength=S}getOutputLineCount(){return this.breakOffsets.length}getMinOutputOffset(e){return e>0?this.wrappedTextIndentLength:0}getLineLength(e){const i=e>0?this.breakOffsets[e-1]:0;let _=this.breakOffsets[e]-i;return e>0&&(_+=this.wrappedTextIndentLength),_}getMaxOutputOffset(e){return this.getLineLength(e)}translateToInputOffset(e,i){e>0&&(i=Math.max(0,i-this.wrappedTextIndentLength));let _=e===0?i:this.breakOffsets[e-1]+i;if(this.injectionOffsets!==null)for(let S=0;S<this.injectionOffsets.length&&_>this.injectionOffsets[S];S++)_<this.injectionOffsets[S]+this.injectionOptions[S].content.length?_=this.injectionOffsets[S]:_-=this.injectionOptions[S].content.length;return _}translateToOutputPosition(e,i=2){let r=e;if(this.injectionOffsets!==null)for(let _=0;_<this.injectionOffsets.length&&!(e<this.injectionOffsets[_]||i!==1&&e===this.injectionOffsets[_]);_++)r+=this.injectionOptions[_].content.length;return this.offsetInInputWithInjectionsToOutputPosition(r,i)}offsetInInputWithInjectionsToOutputPosition(e,i=2){let r=0,_=this.breakOffsets.length-1,S=0,z=0;for(;r<=_;){S=r+(_-r)/2|0;const re=this.breakOffsets[S];if(z=S>0?this.breakOffsets[S-1]:0,i===0)if(e<=z)_=S-1;else if(e>re)r=S+1;else break;else if(e<z)_=S-1;else if(e>=re)r=S+1;else break}let ie=e-z;return S>0&&(ie+=this.wrappedTextIndentLength),new Do(S,ie)}normalizeOutputPosition(e,i,r){if(this.injectionOffsets!==null){const _=this.outputPositionToOffsetInInputWithInjections(e,i),S=this.normalizeOffsetInInputWithInjectionsAroundInjections(_,r);if(S!==_)return this.offsetInInputWithInjectionsToOutputPosition(S,r)}if(r===0){if(e>0&&i===this.getMinOutputOffset(e))return new Do(e-1,this.getMaxOutputOffset(e-1))}else if(r===1){const _=this.getOutputLineCount()-1;if(e<_&&i===this.getMaxOutputOffset(e))return new Do(e+1,this.getMinOutputOffset(e+1))}return new Do(e,i)}outputPositionToOffsetInInputWithInjections(e,i){return e>0&&(i=Math.max(0,i-this.wrappedTextIndentLength)),(e>0?this.breakOffsets[e-1]:0)+i}normalizeOffsetInInputWithInjectionsAroundInjections(e,i){const r=this.getInjectedTextAtOffset(e);if(!r)return e;if(i===2){if(e===r.offsetInInputWithInjections+r.length&&Er(this.injectionOptions[r.injectedTextIndex].cursorStops))return r.offsetInInputWithInjections+r.length;{let _=r.offsetInInputWithInjections;if(ko(this.injectionOptions[r.injectedTextIndex].cursorStops))return _;let S=r.injectedTextIndex-1;for(;S>=0&&this.injectionOffsets[S]===this.injectionOffsets[r.injectedTextIndex]&&!(Er(this.injectionOptions[S].cursorStops)||(_-=this.injectionOptions[S].content.length,ko(this.injectionOptions[S].cursorStops)));)S--;return _}}else if(i===1||i===4){let _=r.offsetInInputWithInjections+r.length,S=r.injectedTextIndex;for(;S+1<this.injectionOffsets.length&&this.injectionOffsets[S+1]===this.injectionOffsets[S];)_+=this.injectionOptions[S+1].content.length,S++;return _}else if(i===0||i===3){let _=r.offsetInInputWithInjections,S=r.injectedTextIndex;for(;S-1>=0&&this.injectionOffsets[S-1]===this.injectionOffsets[S];)_-=this.injectionOptions[S-1].content.length,S--;return _}(0,wn.xb)(i)}getInjectedText(e,i){const r=this.outputPositionToOffsetInInputWithInjections(e,i),_=this.getInjectedTextAtOffset(r);return _?{options:this.injectionOptions[_.injectedTextIndex]}:null}getInjectedTextAtOffset(e){const i=this.injectionOffsets,r=this.injectionOptions;if(i!==null){let _=0;for(let S=0;S<i.length;S++){const z=r[S].content.length,ie=i[S]+_,re=i[S]+_+z;if(ie>e)break;if(e<=re)return{injectedTextIndex:S,offsetInInputWithInjections:ie,length:z};_+=z}}}}function Er(Le){return Le==null?!0:Le===n.VW.Right||Le===n.VW.Both}function ko(Le){return Le==null?!0:Le===n.VW.Left||Le===n.VW.Both}class va{constructor(e){this.options=e}}class Do{constructor(e,i){this.outputLineIndex=e,this.outputOffset=i}toString(){return`${this.outputLineIndex}:${this.outputOffset}`}toPosition(e){return new Nt.y(e+this.outputLineIndex,this.outputOffset+1)}}class Io{constructor(e,i){this.classifier=new js(e,i)}static create(e){return new Io(e.get(122),e.get(121))}createLineBreaksComputer(e,i,r,_){const S=[],z=[],ie=[];return{addRequest:(re,le,me)=>{S.push(re),z.push(le),ie.push(me)},finalize:()=>{const re=e.typicalFullwidthCharacterWidth/e.typicalHalfwidthCharacterWidth,le=[];for(let me=0,we=S.length;me<we;me++){const Be=z[me],Re=ie[me];Re&&!Re.injectionOptions&&!Be?le[me]=Wr(this.classifier,Re,S[me],i,r,re,_):le[me]=kr(this.classifier,S[me],Be,i,r,re,_)}return xo.length=0,Is.length=0,le}}}}class js extends Fr.V{constructor(e,i){super(0);for(let r=0;r<e.length;r++)this.set(e.charCodeAt(r),1);for(let r=0;r<i.length;r++)this.set(i.charCodeAt(r),2)}get(e){return e>=0&&e<256?this._asciiMap[e]:e>=12352&&e<=12543||e>=13312&&e<=19903||e>=19968&&e<=40959?3:this._map.get(e)||this._defaultValue}}let xo=[],Is=[];function Wr(Le,e,i,r,_,S,z){if(_===-1)return null;const ie=i.length;if(ie<=1)return null;const re=e.breakOffsets,le=e.breakOffsetsVisibleColumn,me=Mo(i,r,_,S,z),we=_-me,Be=xo,Re=Is;let Je=0,st=0,ct=0,mt=_;const xt=re.length;let Dt=0;if(Dt>=0){let Jt=Math.abs(le[Dt]-mt);for(;Dt+1<xt;){const $t=Math.abs(le[Dt+1]-mt);if($t>=Jt)break;Jt=$t,Dt++}}for(;Dt<xt;){let Jt=Dt<0?0:re[Dt],$t=Dt<0?0:le[Dt];st>Jt&&(Jt=st,$t=ct);let ai=0,ii=0,Zt=0,di=0;if($t<=mt){let gi=$t,un=Jt===0?0:i.charCodeAt(Jt-1),Ki=Jt===0?0:Le.get(un),Pn=!0;for(let $i=Jt;$i<ie;$i++){const Dn=$i,Xi=i.charCodeAt($i);let bn,ts;if(at.pc(Xi)?($i++,bn=0,ts=2):(bn=Le.get(Xi),ts=Ks(Xi,gi,r,S)),Dn>st&&To(un,Ki,Xi,bn)&&(ai=Dn,ii=gi),gi+=ts,gi>mt){Dn>st?(Zt=Dn,di=gi-ts):(Zt=$i+1,di=gi),gi-ii>we&&(ai=0),Pn=!1;break}un=Xi,Ki=bn}if(Pn){Je>0&&(Be[Je]=re[re.length-1],Re[Je]=le[re.length-1],Je++);break}}if(ai===0){let gi=$t,un=i.charCodeAt(Jt),Ki=Le.get(un),Pn=!1;for(let $i=Jt-1;$i>=st;$i--){const Dn=$i+1,Xi=i.charCodeAt($i);if(Xi===9){Pn=!0;break}let bn,ts;if(at.LJ(Xi)?($i--,bn=0,ts=2):(bn=Le.get(Xi),ts=at.ne(Xi)?S:1),gi<=mt){if(Zt===0&&(Zt=Dn,di=gi),gi<=mt-we)break;if(To(Xi,bn,un,Ki)){ai=Dn,ii=gi;break}}gi-=ts,un=Xi,Ki=bn}if(ai!==0){const $i=we-(di-ii);if($i<=r){const Dn=i.charCodeAt(Zt);let Xi;at.pc(Dn)?Xi=2:Xi=Ks(Dn,di,r,S),$i-Xi<0&&(ai=0)}}if(Pn){Dt--;continue}}if(ai===0&&(ai=Zt,ii=di),ai<=st){const gi=i.charCodeAt(st);at.pc(gi)?(ai=st+2,ii=ct+2):(ai=st+1,ii=ct+Ks(gi,ct,r,S))}for(st=ai,Be[Je]=ai,ct=ii,Re[Je]=ii,Je++,mt=ii+we;Dt<0||Dt<xt&&le[Dt]<ii;)Dt++;let Ai=Math.abs(le[Dt]-mt);for(;Dt+1<xt;){const gi=Math.abs(le[Dt+1]-mt);if(gi>=Ai)break;Ai=gi,Dt++}}return Je===0?null:(Be.length=Je,Re.length=Je,xo=e.breakOffsets,Is=e.breakOffsetsVisibleColumn,e.breakOffsets=Be,e.breakOffsetsVisibleColumn=Re,e.wrappedTextIndentLength=me,e)}function kr(Le,e,i,r,_,S,z){const ie=us.uK.applyInjectedText(e,i);let re,le;if(i&&i.length>0?(re=i.map(ii=>ii.options),le=i.map(ii=>ii.column-1)):(re=null,le=null),_===-1)return re?new Us(le,re,[ie.length],[],0):null;const me=ie.length;if(me<=1)return re?new Us(le,re,[ie.length],[],0):null;const we=Mo(ie,r,_,S,z),Be=_-we,Re=[],Je=[];let st=0,ct=0,mt=0,xt=_,Dt=ie.charCodeAt(0),Jt=Le.get(Dt),$t=Ks(Dt,0,r,S),ai=1;at.pc(Dt)&&($t+=1,Dt=ie.charCodeAt(1),Jt=Le.get(Dt),ai++);for(let ii=ai;ii<me;ii++){const Zt=ii,di=ie.charCodeAt(ii);let Ai,gi;at.pc(di)?(ii++,Ai=0,gi=2):(Ai=Le.get(di),gi=Ks(di,$t,r,S)),To(Dt,Jt,di,Ai)&&(ct=Zt,mt=$t),$t+=gi,$t>xt&&((ct===0||$t-mt>Be)&&(ct=Zt,mt=$t-gi),Re[st]=ct,Je[st]=mt,st++,xt=mt+Be,ct=0),Dt=di,Jt=Ai}return st===0&&(!i||i.length===0)?null:(Re[st]=me,Je[st]=$t,new Us(le,re,Re,Je,we))}function Ks(Le,e,i,r){return Le===9?i-e%i:at.ne(Le)||Le<32?r:1}function nr(Le,e){return e-Le%e}function To(Le,e,i,r){return i!==32&&(e===2&&r!==2||e!==1&&r===1||e===3&&r!==2||r===3&&e!==1)}function Mo(Le,e,i,r,_){let S=0;if(_!==0){const z=at.HG(Le);if(z!==-1){for(let re=0;re<z;re++){const le=Le.charCodeAt(re)===9?nr(S,e):1;S+=le}const ie=_===3?2:_===2?1:0;for(let re=0;re<ie;re++){const le=nr(S,e);S+=le}S+r>i&&(S=0)}}return S}var lo;const No=(lo=window.trustedTypes)===null||lo===void 0?void 0:lo.createPolicy("domLineBreaksComputer",{createHTML:Le=>Le});class sr{static create(){return new sr}constructor(){}createLineBreaksComputer(e,i,r,_){const S=[],z=[];return{addRequest:(ie,re,le)=>{S.push(ie),z.push(re)},finalize:()=>Po(S,e,i,r,_,z)}}}function Po(Le,e,i,r,_,S){var z;function ie(Zt){const di=S[Zt];if(di){const Ai=us.uK.applyInjectedText(Le[Zt],di),gi=di.map(Ki=>Ki.options),un=di.map(Ki=>Ki.column-1);return new Us(un,gi,[Ai.length],[],0)}else return null}if(r===-1){const Zt=[];for(let di=0,Ai=Le.length;di<Ai;di++)Zt[di]=ie(di);return Zt}const re=Math.round(r*e.typicalHalfwidthCharacterWidth),me=Math.round(i*(_===3?2:_===2?1:0)),we=Math.ceil(e.spaceWidth*me),Be=document.createElement("div");(0,vt.M)(Be,e);const Re=(0,Tt.Du)(1e4),Je=[],st=[],ct=[],mt=[],xt=[];for(let Zt=0;Zt<Le.length;Zt++){const di=us.uK.applyInjectedText(Le[Zt],S[Zt]);let Ai=0,gi=0,un=re;if(_!==0)if(Ai=at.HG(di),Ai===-1)Ai=0;else{for(let Dn=0;Dn<Ai;Dn++){const Xi=di.charCodeAt(Dn)===9?i-gi%i:1;gi+=Xi}const $i=Math.ceil(e.spaceWidth*gi);$i+e.typicalFullwidthCharacterWidth>re?(Ai=0,gi=0):un=re-$i}const Ki=di.substr(Ai),Pn=Vr(Ki,gi,i,un,Re,we);Je[Zt]=Ai,st[Zt]=gi,ct[Zt]=Ki,mt[Zt]=Pn[0],xt[Zt]=Pn[1]}const Dt=Re.build(),Jt=(z=No?.createHTML(Dt))!==null&&z!==void 0?z:Dt;Be.innerHTML=Jt,Be.style.position="absolute",Be.style.top="10000",Be.style.wordWrap="break-word",document.body.appendChild(Be);const $t=document.createRange(),ai=Array.prototype.slice.call(Be.children,0),ii=[];for(let Zt=0;Zt<Le.length;Zt++){const di=ai[Zt],Ai=or($t,di,ct[Zt],mt[Zt]);if(Ai===null){ii[Zt]=ie(Zt);continue}const gi=Je[Zt],un=st[Zt]+me,Ki=xt[Zt],Pn=[];for(let bn=0,ts=Ai.length;bn<ts;bn++)Pn[bn]=Ki[Ai[bn]];if(gi!==0)for(let bn=0,ts=Ai.length;bn<ts;bn++)Ai[bn]+=gi;let $i,Dn;const Xi=S[Zt];Xi?($i=Xi.map(bn=>bn.options),Dn=Xi.map(bn=>bn.column-1)):($i=null,Dn=null),ii[Zt]=new Us(Dn,$i,Ai,Pn,un)}return document.body.removeChild(Be),ii}function Vr(Le,e,i,r,_,S){if(S!==0){const Be=String(S);_.appendASCIIString('<div style="text-indent: -'),_.appendASCIIString(Be),_.appendASCIIString("px; padding-left: "),_.appendASCIIString(Be),_.appendASCIIString("px; box-sizing: border-box; width:")}else _.appendASCIIString('<div style="width:');_.appendASCIIString(String(r)),_.appendASCIIString('px;">');const z=Le.length;let ie=e,re=0;const le=[],me=[];let we=0<z?Le.charCodeAt(0):0;_.appendASCIIString("<span>");for(let Be=0;Be<z;Be++){Be!==0&&Be%16384===0&&_.appendASCIIString("</span><span>"),le[Be]=re,me[Be]=ie;const Re=we;we=Be+1<z?Le.charCodeAt(Be+1):0;let Je=1,st=1;switch(Re){case 9:Je=i-ie%i,st=Je;for(let ct=1;ct<=Je;ct++)ct<Je?_.write1(160):_.appendASCII(32);break;case 32:we===32?_.write1(160):_.appendASCII(32);break;case 60:_.appendASCIIString("<");break;case 62:_.appendASCIIString(">");break;case 38:_.appendASCIIString("&");break;case 0:_.appendASCIIString("�");break;case 65279:case 8232:case 8233:case 133:_.write1(65533);break;default:at.ne(Re)&&st++,Re<32?_.write1(9216+Re):_.write1(Re)}re+=Je,ie+=st}return _.appendASCIIString("</span>"),le[Le.length]=re,me[Le.length]=ie,_.appendASCIIString("</div>"),[le,me]}function or(Le,e,i,r){if(i.length<=1)return null;const _=Array.prototype.slice.call(e.children,0),S=[];try{rr(Le,_,r,0,null,i.length-1,null,S)}catch(z){return console.log(z),null}return S.length===0?null:(S.push(i.length),S)}function rr(Le,e,i,r,_,S,z,ie){if(r===S||(_=_||co(Le,e,i[r],i[r+1]),z=z||co(Le,e,i[S],i[S+1]),Math.abs(_[0].top-z[0].top)<=.1))return;if(r+1===S){ie.push(S);return}const re=r+(S-r)/2|0,le=co(Le,e,i[re],i[re+1]);rr(Le,e,i,r,_,re,le,ie),rr(Le,e,i,re,le,S,z,ie)}function co(Le,e,i,r){return Le.setStart(e[i/16384|0].firstChild,i%16384),Le.setEnd(e[r/16384|0].firstChild,r%16384),Le.getClientRects()}var as=y(89673),Hr=y(52394),zr=y(52230),Ur=function(Le,e,i,r){var _=arguments.length,S=_<3?e:r===null?r=Object.getOwnPropertyDescriptor(e,i):r,z;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")S=Reflect.decorate(Le,e,i,r);else for(var ie=Le.length-1;ie>=0;ie--)(z=Le[ie])&&(S=(_<3?z(S):_>3?z(e,i,S):z(e,i))||S);return _>3&&S&&Object.defineProperty(e,i,S),S},_s=function(Le,e){return function(i,r){e(i,r,Le)}},Oo=function(Le,e,i,r){function _(S){return S instanceof i?S:new i(function(z){z(S)})}return new(i||(i=Promise))(function(S,z){function ie(me){try{le(r.next(me))}catch(we){z(we)}}function re(me){try{le(r.throw(me))}catch(we){z(we)}}function le(me){me.done?S(me.value):_(me.value).then(ie,re)}le((r=r.apply(Le,e||[])).next())})};let ar=0;class Dr{constructor(e,i,r,_,S){this.model=e,this.viewModel=i,this.view=r,this.hasRealView=_,this.listenersToRemove=S}dispose(){(0,p.AS)(this.listenersToRemove),this.model.onBeforeDetached(),this.hasRealView&&this.view.dispose(),this.viewModel.dispose()}}let lr=class Ho extends p.jG{constructor(e,i,r,_,S,z,ie,re,le,me,we,Be){super(),this.languageConfigurationService=we,this._deliveryQueue=new T.ci,this._onDidDispose=this._register(new T.vl),this.onDidDispose=this._onDidDispose.event,this._onDidChangeModelContent=this._register(new T.vl({deliveryQueue:this._deliveryQueue})),this.onDidChangeModelContent=this._onDidChangeModelContent.event,this._onDidChangeModelLanguage=this._register(new T.vl({deliveryQueue:this._deliveryQueue})),this.onDidChangeModelLanguage=this._onDidChangeModelLanguage.event,this._onDidChangeModelLanguageConfiguration=this._register(new T.vl({deliveryQueue:this._deliveryQueue})),this.onDidChangeModelLanguageConfiguration=this._onDidChangeModelLanguageConfiguration.event,this._onDidChangeModelOptions=this._register(new T.vl({deliveryQueue:this._deliveryQueue})),this.onDidChangeModelOptions=this._onDidChangeModelOptions.event,this._onDidChangeModelDecorations=this._register(new T.vl({deliveryQueue:this._deliveryQueue})),this.onDidChangeModelDecorations=this._onDidChangeModelDecorations.event,this._onDidChangeModelTokens=this._register(new T.vl({deliveryQueue:this._deliveryQueue})),this.onDidChangeModelTokens=this._onDidChangeModelTokens.event,this._onDidChangeConfiguration=this._register(new T.vl({deliveryQueue:this._deliveryQueue})),this.onDidChangeConfiguration=this._onDidChangeConfiguration.event,this._onDidChangeModel=this._register(new T.vl({deliveryQueue:this._deliveryQueue})),this.onDidChangeModel=this._onDidChangeModel.event,this._onDidChangeCursorPosition=this._register(new T.vl({deliveryQueue:this._deliveryQueue})),this.onDidChangeCursorPosition=this._onDidChangeCursorPosition.event,this._onDidChangeCursorSelection=this._register(new T.vl({deliveryQueue:this._deliveryQueue})),this.onDidChangeCursorSelection=this._onDidChangeCursorSelection.event,this._onDidAttemptReadOnlyEdit=this._register(new T.vl({deliveryQueue:this._deliveryQueue})),this.onDidAttemptReadOnlyEdit=this._onDidAttemptReadOnlyEdit.event,this._onDidLayoutChange=this._register(new T.vl({deliveryQueue:this._deliveryQueue})),this.onDidLayoutChange=this._onDidLayoutChange.event,this._editorTextFocus=this._register(new jr({deliveryQueue:this._deliveryQueue})),this.onDidFocusEditorText=this._editorTextFocus.onDidChangeToTrue,this.onDidBlurEditorText=this._editorTextFocus.onDidChangeToFalse,this._editorWidgetFocus=this._register(new jr({deliveryQueue:this._deliveryQueue})),this.onDidFocusEditorWidget=this._editorWidgetFocus.onDidChangeToTrue,this.onDidBlurEditorWidget=this._editorWidgetFocus.onDidChangeToFalse,this._onWillType=this._register(new T.vl({deliveryQueue:this._deliveryQueue})),this.onWillType=this._onWillType.event,this._onDidType=this._register(new T.vl({deliveryQueue:this._deliveryQueue})),this.onDidType=this._onDidType.event,this._onDidCompositionStart=this._register(new T.vl({deliveryQueue:this._deliveryQueue})),this.onDidCompositionStart=this._onDidCompositionStart.event,this._onDidCompositionEnd=this._register(new T.vl({deliveryQueue:this._deliveryQueue})),this.onDidCompositionEnd=this._onDidCompositionEnd.event,this._onDidPaste=this._register(new T.vl({deliveryQueue:this._deliveryQueue})),this.onDidPaste=this._onDidPaste.event,this._onMouseUp=this._register(new T.vl({deliveryQueue:this._deliveryQueue})),this.onMouseUp=this._onMouseUp.event,this._onMouseDown=this._register(new T.vl({deliveryQueue:this._deliveryQueue})),this.onMouseDown=this._onMouseDown.event,this._onMouseDrag=this._register(new T.vl({deliveryQueue:this._deliveryQueue})),this.onMouseDrag=this._onMouseDrag.event,this._onMouseDrop=this._register(new T.vl({deliveryQueue:this._deliveryQueue})),this.onMouseDrop=this._onMouseDrop.event,this._onMouseDropCanceled=this._register(new T.vl({deliveryQueue:this._deliveryQueue})),this.onMouseDropCanceled=this._onMouseDropCanceled.event,this._onDropIntoEditor=this._register(new T.vl({deliveryQueue:this._deliveryQueue})),this.onDropIntoEditor=this._onDropIntoEditor.event,this._onContextMenu=this._register(new T.vl({deliveryQueue:this._deliveryQueue})),this.onContextMenu=this._onContextMenu.event,this._onMouseMove=this._register(new T.vl({deliveryQueue:this._deliveryQueue})),this.onMouseMove=this._onMouseMove.event,this._onMouseLeave=this._register(new T.vl({deliveryQueue:this._deliveryQueue})),this.onMouseLeave=this._onMouseLeave.event,this._onMouseWheel=this._register(new T.vl({deliveryQueue:this._deliveryQueue})),this.onMouseWheel=this._onMouseWheel.event,this._onKeyUp=this._register(new T.vl({deliveryQueue:this._deliveryQueue})),this.onKeyUp=this._onKeyUp.event,this._onKeyDown=this._register(new T.vl({deliveryQueue:this._deliveryQueue})),this.onKeyDown=this._onKeyDown.event,this._onDidContentSizeChange=this._register(new T.vl({deliveryQueue:this._deliveryQueue})),this.onDidContentSizeChange=this._onDidContentSizeChange.event,this._onDidScrollChange=this._register(new T.vl({deliveryQueue:this._deliveryQueue})),this.onDidScrollChange=this._onDidScrollChange.event,this._onDidChangeViewZones=this._register(new T.vl({deliveryQueue:this._deliveryQueue})),this.onDidChangeViewZones=this._onDidChangeViewZones.event,this._onDidChangeHiddenAreas=this._register(new T.vl({deliveryQueue:this._deliveryQueue})),this.onDidChangeHiddenAreas=this._onDidChangeHiddenAreas.event,this._bannerDomNode=null,this._dropIntoEditorDecorations=this.createDecorationsCollection();const Re=Object.assign({},i);this._domElement=e,this._overflowWidgetsDomNode=Re.overflowWidgetsDomNode,delete Re.overflowWidgetsDomNode,this._id=++ar,this._decorationTypeKeysToIds={},this._decorationTypeSubtypes={},this._telemetryData=r.telemetryData,this._configuration=this._register(this._createConfiguration(r.isSimpleWidget||!1,Re,me)),this._register(this._configuration.onDidChange(ct=>{this._onDidChangeConfiguration.fire(ct);const mt=this._configuration.options;if(ct.hasChanged(133)){const xt=mt.get(133);this._onDidLayoutChange.fire(xt)}})),this._contextKeyService=this._register(ie.createScoped(this._domElement)),this._notificationService=le,this._codeEditorService=S,this._commandService=z,this._themeService=re,this._register(new Kr(this,this._contextKeyService)),this._register(new $r(this,this._contextKeyService,Be)),this._instantiationService=_.createChild(new ir.a([Eo.fN,this._contextKeyService])),this._modelData=null,this._contributions={},this._actions={},this._focusTracker=new Gr(e),this._register(this._focusTracker.onChange(()=>{this._editorWidgetFocus.setValue(this._focusTracker.hasFocus())})),this._contentWidgets={},this._overlayWidgets={};let Je;Array.isArray(r.contributions)?Je=r.contributions:Je=o.dS.getEditorContributions();for(const ct of Je){if(this._contributions[ct.id]){(0,B.dz)(new Error(`Cannot have two contributions with the same id ${ct.id}`));continue}try{const mt=this._instantiationService.createInstance(ct.ctor,this);this._contributions[ct.id]=mt}catch(mt){(0,B.dz)(mt)}}o.dS.getEditorActions().forEach(ct=>{if(this._actions[ct.id]){(0,B.dz)(new Error(`Cannot have two actions with the same id ${ct.id}`));return}const mt=new zi.f(ct.id,ct.label,ct.alias,(0,wn.UH)(ct.precondition),()=>this._instantiationService.invokeFunction(xt=>Promise.resolve(ct.runEditorCommand(xt,this,null))),this._contextKeyService);this._actions[mt.id]=mt});const st=()=>!this._configuration.options.get(83)&&this._configuration.options.get(32).enabled;this._register(new P.pN(this._domElement,{onDragEnter:()=>{},onDragOver:ct=>{if(!st())return;const mt=this.getTargetAtClientPoint(ct.clientX,ct.clientY);mt?.position&&this.showDropIndicatorAt(mt.position)},onDrop:ct=>Oo(this,void 0,void 0,function*(){if(!st()||(this.removeDropIndicator(),!ct.dataTransfer))return;const mt=this.getTargetAtClientPoint(ct.clientX,ct.clientY);mt?.position&&this._onDropIntoEditor.fire({position:mt.position,event:ct})}),onDragLeave:()=>{this.removeDropIndicator()},onDragEnd:()=>{this.removeDropIndicator()}})),this._codeEditorService.addCodeEditor(this)}get isSimpleWidget(){return this._configuration.isSimpleWidget}_createConfiguration(e,i,r){return new R(e,i,this._domElement,r)}getId(){return this.getEditorType()+":"+this._id}getEditorType(){return vn._.ICodeEditor}dispose(){this._codeEditorService.removeCodeEditor(this),this._focusTracker.dispose();const e=Object.keys(this._contributions);for(let i=0,r=e.length;i<r;i++){const _=e[i];this._contributions[_].dispose()}this._contributions={},this._actions={},this._contentWidgets={},this._overlayWidgets={},this._removeDecorationTypes(),this._postDetachModelCleanup(this._detachModel()),this._onDidDispose.fire(),super.dispose()}invokeWithinContext(e){return this._instantiationService.invokeFunction(e)}updateOptions(e){this._configuration.updateOptions(e||{})}getOptions(){return this._configuration.options}getOption(e){return this._configuration.options.get(e)}getRawOptions(){return this._configuration.getRawOptions()}getOverflowWidgetsDomNode(){return this._overflowWidgetsDomNode}getConfiguredWordAtPosition(e){return this._modelData?as.z.getWordAtPosition(this._modelData.model,this._configuration.options.get(119),e):null}getValue(e=null){if(!this._modelData)return"";const i=!!(e&&e.preserveBOM);let r=0;return e&&e.lineEnding&&e.lineEnding===` `?r=1:e&&e.lineEnding&&e.lineEnding===`\r `&&(r=2),this._modelData.model.getValue(r,i)}setValue(e){this._modelData&&this._modelData.model.setValue(e)}getModel(){return this._modelData?this._modelData.model:null}setModel(e=null){const i=e;if(this._modelData===null&&i===null||this._modelData&&this._modelData.model===i)return;const r=this.hasTextFocus(),_=this._detachModel();this._attachModel(i),r&&this.hasModel()&&this.focus();const S={oldModelUrl:_?_.uri:null,newModelUrl:i?i.uri:null};this._removeDecorationTypes(),this._onDidChangeModel.fire(S),this._postDetachModelCleanup(_)}_removeDecorationTypes(){if(this._decorationTypeKeysToIds={},this._decorationTypeSubtypes){for(const e in this._decorationTypeSubtypes){const i=this._decorationTypeSubtypes[e];for(const r in i)this._removeDecorationType(e+"-"+r)}this._decorationTypeSubtypes={}}}getVisibleRanges(){return this._modelData?this._modelData.viewModel.getVisibleRanges():[]}getVisibleRangesPlusViewportAboveBelow(){return this._modelData?this._modelData.viewModel.getVisibleRangesPlusViewportAboveBelow():[]}getWhitespaces(){return this._modelData?this._modelData.viewModel.viewLayout.getWhitespaces():[]}static _getVerticalOffsetAfterPosition(e,i,r,_){const S=e.model.validatePosition({lineNumber:i,column:r}),z=e.viewModel.coordinatesConverter.convertModelPositionToViewPosition(S);return e.viewModel.viewLayout.getVerticalOffsetAfterLineNumber(z.lineNumber,_)}getTopForLineNumber(e,i=!1){return this._modelData?Ho._getVerticalOffsetForPosition(this._modelData,e,1,i):-1}getTopForPosition(e,i){return this._modelData?Ho._getVerticalOffsetForPosition(this._modelData,e,i,!1):-1}static _getVerticalOffsetForPosition(e,i,r,_=!1){const S=e.model.validatePosition({lineNumber:i,column:r}),z=e.viewModel.coordinatesConverter.convertModelPositionToViewPosition(S);return e.viewModel.viewLayout.getVerticalOffsetForLineNumber(z.lineNumber,_)}getBottomForLineNumber(e,i=!1){return this._modelData?Ho._getVerticalOffsetAfterPosition(this._modelData,e,1,i):-1}setHiddenAreas(e){var i;(i=this._modelData)===null||i===void 0||i.viewModel.setHiddenAreas(e.map(r=>Pt.Q.lift(r)))}getVisibleColumnFromPosition(e){if(!this._modelData)return e.column;const i=this._modelData.model.validatePosition(e),r=this._modelData.model.getOptions().tabSize;return Ti.A.visibleColumnFromColumn(this._modelData.model.getLineContent(i.lineNumber),i.column,r)+1}getPosition(){return this._modelData?this._modelData.viewModel.getPosition():null}setPosition(e,i="api"){if(this._modelData){if(!Nt.y.isIPosition(e))throw new Error("Invalid arguments");this._modelData.viewModel.setSelections(i,[{selectionStartLineNumber:e.lineNumber,selectionStartColumn:e.column,positionLineNumber:e.lineNumber,positionColumn:e.column}])}}_sendRevealRange(e,i,r,_){if(!this._modelData)return;if(!Pt.Q.isIRange(e))throw new Error("Invalid arguments");const S=this._modelData.model.validateRange(e),z=this._modelData.viewModel.coordinatesConverter.convertModelRangeToViewRange(S);this._modelData.viewModel.revealRange("api",r,z,i,_)}revealLine(e,i=0){this._revealLine(e,0,i)}revealLineInCenter(e,i=0){this._revealLine(e,1,i)}revealLineInCenterIfOutsideViewport(e,i=0){this._revealLine(e,2,i)}revealLineNearTop(e,i=0){this._revealLine(e,5,i)}_revealLine(e,i,r){if(typeof e!="number")throw new Error("Invalid arguments");this._sendRevealRange(new Pt.Q(e,1,e,1),i,!1,r)}revealPosition(e,i=0){this._revealPosition(e,0,!0,i)}revealPositionInCenter(e,i=0){this._revealPosition(e,1,!0,i)}revealPositionInCenterIfOutsideViewport(e,i=0){this._revealPosition(e,2,!0,i)}revealPositionNearTop(e,i=0){this._revealPosition(e,5,!0,i)}_revealPosition(e,i,r,_){if(!Nt.y.isIPosition(e))throw new Error("Invalid arguments");this._sendRevealRange(new Pt.Q(e.lineNumber,e.column,e.lineNumber,e.column),i,r,_)}getSelection(){return this._modelData?this._modelData.viewModel.getSelection():null}getSelections(){return this._modelData?this._modelData.viewModel.getSelections():null}setSelection(e,i="api"){const r=ue.L.isISelection(e),_=Pt.Q.isIRange(e);if(!r&&!_)throw new Error("Invalid arguments");if(r)this._setSelectionImpl(e,i);else if(_){const S={selectionStartLineNumber:e.startLineNumber,selectionStartColumn:e.startColumn,positionLineNumber:e.endLineNumber,positionColumn:e.endColumn};this._setSelectionImpl(S,i)}}_setSelectionImpl(e,i){if(!this._modelData)return;const r=new ue.L(e.selectionStartLineNumber,e.selectionStartColumn,e.positionLineNumber,e.positionColumn);this._modelData.viewModel.setSelections(i,[r])}revealLines(e,i,r=0){this._revealLines(e,i,0,r)}revealLinesInCenter(e,i,r=0){this._revealLines(e,i,1,r)}revealLinesInCenterIfOutsideViewport(e,i,r=0){this._revealLines(e,i,2,r)}revealLinesNearTop(e,i,r=0){this._revealLines(e,i,5,r)}_revealLines(e,i,r,_){if(typeof e!="number"||typeof i!="number")throw new Error("Invalid arguments");this._sendRevealRange(new Pt.Q(e,1,i,1),r,!1,_)}revealRange(e,i=0,r=!1,_=!0){this._revealRange(e,r?1:0,_,i)}revealRangeInCenter(e,i=0){this._revealRange(e,1,!0,i)}revealRangeInCenterIfOutsideViewport(e,i=0){this._revealRange(e,2,!0,i)}revealRangeNearTop(e,i=0){this._revealRange(e,5,!0,i)}revealRangeNearTopIfOutsideViewport(e,i=0){this._revealRange(e,6,!0,i)}revealRangeAtTop(e,i=0){this._revealRange(e,3,!0,i)}_revealRange(e,i,r,_){if(!Pt.Q.isIRange(e))throw new Error("Invalid arguments");this._sendRevealRange(Pt.Q.lift(e),i,r,_)}setSelections(e,i="api",r=0){if(this._modelData){if(!e||e.length===0)throw new Error("Invalid arguments");for(let _=0,S=e.length;_<S;_++)if(!ue.L.isISelection(e[_]))throw new Error("Invalid arguments");this._modelData.viewModel.setSelections(i,e,r)}}getContentWidth(){return this._modelData?this._modelData.viewModel.viewLayout.getContentWidth():-1}getScrollWidth(){return this._modelData?this._modelData.viewModel.viewLayout.getScrollWidth():-1}getScrollLeft(){return this._modelData?this._modelData.viewModel.viewLayout.getCurrentScrollLeft():-1}getContentHeight(){return this._modelData?this._modelData.viewModel.viewLayout.getContentHeight():-1}getScrollHeight(){return this._modelData?this._modelData.viewModel.viewLayout.getScrollHeight():-1}getScrollTop(){return this._modelData?this._modelData.viewModel.viewLayout.getCurrentScrollTop():-1}setScrollLeft(e,i=1){if(this._modelData){if(typeof e!="number")throw new Error("Invalid arguments");this._modelData.viewModel.viewLayout.setScrollPosition({scrollLeft:e},i)}}setScrollTop(e,i=1){if(this._modelData){if(typeof e!="number")throw new Error("Invalid arguments");this._modelData.viewModel.viewLayout.setScrollPosition({scrollTop:e},i)}}setScrollPosition(e,i=1){this._modelData&&this._modelData.viewModel.viewLayout.setScrollPosition(e,i)}saveViewState(){if(!this._modelData)return null;const e={},i=Object.keys(this._contributions);for(const S of i){const z=this._contributions[S];typeof z.saveViewState=="function"&&(e[S]=z.saveViewState())}const r=this._modelData.viewModel.saveCursorState(),_=this._modelData.viewModel.saveState();return{cursorState:r,viewState:_,contributionsState:e}}restoreViewState(e){if(!this._modelData||!this._modelData.hasRealView)return;const i=e;if(i&&i.cursorState&&i.viewState){const r=i.cursorState;Array.isArray(r)?r.length>0&&this._modelData.viewModel.restoreCursorState(r):this._modelData.viewModel.restoreCursorState([r]);const _=i.contributionsState||{},S=Object.keys(this._contributions);for(let ie=0,re=S.length;ie<re;ie++){const le=S[ie],me=this._contributions[le];typeof me.restoreViewState=="function"&&me.restoreViewState(_[le])}const z=this._modelData.viewModel.reduceRestoreState(i.viewState);this._modelData.view.restoreState(z)}}getContribution(e){return this._contributions[e]||null}getActions(){const e=[],i=Object.keys(this._actions);for(let r=0,_=i.length;r<_;r++){const S=i[r];e.push(this._actions[S])}return e}getSupportedActions(){let e=this.getActions();return e=e.filter(i=>i.isSupported()),e}getAction(e){return this._actions[e]||null}trigger(e,i,r){switch(r=r||{},i){case"compositionStart":this._startComposition();return;case"compositionEnd":this._endComposition(e);return;case"type":{const S=r;this._type(e,S.text||"");return}case"replacePreviousChar":{const S=r;this._compositionType(e,S.text||"",S.replaceCharCnt||0,0,0);return}case"compositionType":{const S=r;this._compositionType(e,S.text||"",S.replacePrevCharCnt||0,S.replaceNextCharCnt||0,S.positionDelta||0);return}case"paste":{const S=r;this._paste(e,S.text||"",S.pasteOnNewLine||!1,S.multicursorText||null,S.mode||null);return}case"cut":this._cut(e);return}const _=this.getAction(i);if(_){Promise.resolve(_.run()).then(void 0,B.dz);return}this._modelData&&(this._triggerEditorCommand(e,i,r)||this._triggerCommand(i,r))}_triggerCommand(e,i){this._commandService.executeCommand(e,i)}_startComposition(){this._modelData&&(this._modelData.viewModel.startComposition(),this._onDidCompositionStart.fire())}_endComposition(e){this._modelData&&(this._modelData.viewModel.endComposition(e),this._onDidCompositionEnd.fire())}_type(e,i){!this._modelData||i.length===0||(e==="keyboard"&&this._onWillType.fire(i),this._modelData.viewModel.type(i,e),e==="keyboard"&&this._onDidType.fire(i))}_compositionType(e,i,r,_,S){this._modelData&&this._modelData.viewModel.compositionType(i,r,_,S,e)}_paste(e,i,r,_,S){if(!this._modelData||i.length===0)return;const z=this._modelData.viewModel,ie=z.getSelection().getStartPosition();z.paste(i,r,_,e);const re=z.getSelection().getStartPosition();e==="keyboard"&&this._onDidPaste.fire({range:new Pt.Q(ie.lineNumber,ie.column,re.lineNumber,re.column),languageId:S})}_cut(e){this._modelData&&this._modelData.viewModel.cut(e)}_triggerEditorCommand(e,i,r){const _=o.dS.getEditorCommand(i);return _?(r=r||{},r.source=e,this._instantiationService.invokeFunction(S=>{Promise.resolve(_.runEditorCommand(S,this,r)).then(void 0,B.dz)}),!0):!1}_getViewModel(){return this._modelData?this._modelData.viewModel:null}pushUndoStop(){return!this._modelData||this._configuration.options.get(83)?!1:(this._modelData.model.pushStackElement(),!0)}popUndoStop(){return!this._modelData||this._configuration.options.get(83)?!1:(this._modelData.model.popStackElement(),!0)}executeEdits(e,i,r){if(!this._modelData||this._configuration.options.get(83))return!1;let _;return r?Array.isArray(r)?_=()=>r:_=r:_=()=>null,this._modelData.viewModel.executeEdits(e,i,_),!0}executeCommand(e,i){this._modelData&&this._modelData.viewModel.executeCommand(i,e)}executeCommands(e,i){this._modelData&&this._modelData.viewModel.executeCommands(i,e)}createDecorationsCollection(e){return new Ir(this,e)}changeDecorations(e){return this._modelData?this._modelData.model.changeDecorations(e,this._id):null}getLineDecorations(e){return this._modelData?this._modelData.model.getLineDecorations(e,this._id,(0,W.$C)(this._configuration.options)):null}getDecorationsInRange(e){return this._modelData?this._modelData.model.getDecorationsInRange(e,this._id,(0,W.$C)(this._configuration.options)):null}deltaDecorations(e,i){return this._modelData?e.length===0&&i.length===0?e:this._modelData.model.deltaDecorations(e,i,this._id):[]}removeDecorations(e){!this._modelData||e.length===0||this._modelData.model.changeDecorations(i=>{i.deltaDecorations(e,[])})}removeDecorationsByType(e){const i=this._decorationTypeKeysToIds[e];i&&this.deltaDecorations(i,[]),this._decorationTypeKeysToIds.hasOwnProperty(e)&&delete this._decorationTypeKeysToIds[e],this._decorationTypeSubtypes.hasOwnProperty(e)&&delete this._decorationTypeSubtypes[e]}getLayoutInfo(){return this._configuration.options.get(133)}createOverviewRuler(e){return!this._modelData||!this._modelData.hasRealView?null:this._modelData.view.createOverviewRuler(e)}getContainerDomNode(){return this._domElement}getDomNode(){return!this._modelData||!this._modelData.hasRealView?null:this._modelData.view.domNode.domNode}delegateVerticalScrollbarPointerDown(e){!this._modelData||!this._modelData.hasRealView||this._modelData.view.delegateVerticalScrollbarPointerDown(e)}layout(e){this._configuration.observeContainer(e),this.render()}focus(){!this._modelData||!this._modelData.hasRealView||this._modelData.view.focus()}hasTextFocus(){return!this._modelData||!this._modelData.hasRealView?!1:this._modelData.view.isFocused()}hasWidgetFocus(){return this._focusTracker&&this._focusTracker.hasFocus()}addContentWidget(e){const i={widget:e,position:e.getPosition()};this._contentWidgets.hasOwnProperty(e.getId())&&console.warn("Overwriting a content widget with the same id."),this._contentWidgets[e.getId()]=i,this._modelData&&this._modelData.hasRealView&&this._modelData.view.addContentWidget(i)}layoutContentWidget(e){const i=e.getId();if(this._contentWidgets.hasOwnProperty(i)){const r=this._contentWidgets[i];r.position=e.getPosition(),this._modelData&&this._modelData.hasRealView&&this._modelData.view.layoutContentWidget(r)}}removeContentWidget(e){const i=e.getId();if(this._contentWidgets.hasOwnProperty(i)){const r=this._contentWidgets[i];delete this._contentWidgets[i],this._modelData&&this._modelData.hasRealView&&this._modelData.view.removeContentWidget(r)}}addOverlayWidget(e){const i={widget:e,position:e.getPosition()};this._overlayWidgets.hasOwnProperty(e.getId())&&console.warn("Overwriting an overlay widget with the same id."),this._overlayWidgets[e.getId()]=i,this._modelData&&this._modelData.hasRealView&&this._modelData.view.addOverlayWidget(i)}layoutOverlayWidget(e){const i=e.getId();if(this._overlayWidgets.hasOwnProperty(i)){const r=this._overlayWidgets[i];r.position=e.getPosition(),this._modelData&&this._modelData.hasRealView&&this._modelData.view.layoutOverlayWidget(r)}}removeOverlayWidget(e){const i=e.getId();if(this._overlayWidgets.hasOwnProperty(i)){const r=this._overlayWidgets[i];delete this._overlayWidgets[i],this._modelData&&this._modelData.hasRealView&&this._modelData.view.removeOverlayWidget(r)}}changeViewZones(e){!this._modelData||!this._modelData.hasRealView||this._modelData.view.change(e)}getTargetAtClientPoint(e,i){return!this._modelData||!this._modelData.hasRealView?null:this._modelData.view.getTargetAtClientPoint(e,i)}getScrolledVisiblePosition(e){if(!this._modelData||!this._modelData.hasRealView)return null;const i=this._modelData.model.validatePosition(e),r=this._configuration.options,_=r.get(133),S=Ho._getVerticalOffsetForPosition(this._modelData,i.lineNumber,i.column)-this.getScrollTop(),z=this._modelData.view.getOffsetForColumn(i.lineNumber,i.column)+_.glyphMarginWidth+_.lineNumbersWidth+_.decorationsWidth-this.getScrollLeft();return{top:S,left:z,height:r.get(61)}}getOffsetForColumn(e,i){return!this._modelData||!this._modelData.hasRealView?-1:this._modelData.view.getOffsetForColumn(e,i)}render(e=!1){!this._modelData||!this._modelData.hasRealView||this._modelData.view.render(!0,e)}setAriaOptions(e){!this._modelData||!this._modelData.hasRealView||this._modelData.view.setAriaOptions(e)}applyFontInfo(e){(0,vt.M)(e,this._configuration.options.get(46))}setBanner(e,i){this._bannerDomNode&&this._domElement.contains(this._bannerDomNode)&&this._domElement.removeChild(this._bannerDomNode),this._bannerDomNode=e,this._configuration.setReservedHeight(e?i:0),this._bannerDomNode&&this._domElement.prepend(this._bannerDomNode)}_attachModel(e){if(!e){this._modelData=null;return}const i=[];this._domElement.setAttribute("data-mode-id",e.getLanguageId()),this._configuration.setIsDominatedByLongLines(e.isDominatedByLongLines()),this._configuration.setModelLineCount(e.getLineCount()),e.onBeforeAttached();const r=new Lo(this._id,this._configuration,e,sr.create(),Io.create(this._configuration.options),z=>P.PG(z),this.languageConfigurationService,this._themeService);i.push(e.onWillDispose(()=>this.setModel(null))),i.push(r.onEvent(z=>{switch(z.kind){case 0:this._onDidContentSizeChange.fire(z);break;case 1:this._editorTextFocus.setValue(z.hasFocus);break;case 2:this._onDidScrollChange.fire(z);break;case 3:this._onDidChangeViewZones.fire();break;case 4:this._onDidChangeHiddenAreas.fire();break;case 5:this._onDidAttemptReadOnlyEdit.fire();break;case 6:{z.reachedMaxCursorCount&&this._notificationService.warn(U.kg("cursors.maximum","The number of cursors has been limited to {0}.",bs.MAX_CURSOR_COUNT));const ie=[];for(let me=0,we=z.selections.length;me<we;me++)ie[me]=z.selections[me].getPosition();const re={position:ie[0],secondaryPositions:ie.slice(1),reason:z.reason,source:z.source};this._onDidChangeCursorPosition.fire(re);const le={selection:z.selections[0],secondarySelections:z.selections.slice(1),modelVersionId:z.modelVersionId,oldSelections:z.oldSelections,oldModelVersionId:z.oldModelVersionId,source:z.source,reason:z.reason};this._onDidChangeCursorSelection.fire(le);break}case 7:this._onDidChangeModelDecorations.fire(z.event);break;case 8:this._domElement.setAttribute("data-mode-id",e.getLanguageId()),this._onDidChangeModelLanguage.fire(z.event);break;case 9:this._onDidChangeModelLanguageConfiguration.fire(z.event);break;case 10:this._onDidChangeModelContent.fire(z.event);break;case 11:this._onDidChangeModelOptions.fire(z.event);break;case 12:this._onDidChangeModelTokens.fire(z.event);break}}));const[_,S]=this._createView(r);if(S){this._domElement.appendChild(_.domNode.domNode);let z=Object.keys(this._contentWidgets);for(let ie=0,re=z.length;ie<re;ie++){const le=z[ie];_.addContentWidget(this._contentWidgets[le])}z=Object.keys(this._overlayWidgets);for(let ie=0,re=z.length;ie<re;ie++){const le=z[ie];_.addOverlayWidget(this._overlayWidgets[le])}_.render(!1,!0),_.domNode.domNode.setAttribute("data-uri",e.uri.toString())}this._modelData=new Dr(e,r,_,S,i)}_createView(e){let i;this.isSimpleWidget?i={paste:(S,z,ie,re)=>{this._paste("keyboard",S,z,ie,re)},type:S=>{this._type("keyboard",S)},compositionType:(S,z,ie,re)=>{this._compositionType("keyboard",S,z,ie,re)},startComposition:()=>{this._startComposition()},endComposition:()=>{this._endComposition("keyboard")},cut:()=>{this._cut("keyboard")}}:i={paste:(S,z,ie,re)=>{const le={text:S,pasteOnNewLine:z,multicursorText:ie,mode:re};this._commandService.executeCommand("paste",le)},type:S=>{const z={text:S};this._commandService.executeCommand("type",z)},compositionType:(S,z,ie,re)=>{if(ie||re){const le={text:S,replacePrevCharCnt:z,replaceNextCharCnt:ie,positionDelta:re};this._commandService.executeCommand("compositionType",le)}else{const le={text:S,replaceCharCnt:z};this._commandService.executeCommand("replacePreviousChar",le)}},startComposition:()=>{this._commandService.executeCommand("compositionStart",{})},endComposition:()=>{this._commandService.executeCommand("compositionEnd",{})},cut:()=>{this._commandService.executeCommand("cut",{})}};const r=new mi(e.coordinatesConverter);return r.onKeyDown=S=>this._onKeyDown.fire(S),r.onKeyUp=S=>this._onKeyUp.fire(S),r.onContextMenu=S=>this._onContextMenu.fire(S),r.onMouseMove=S=>this._onMouseMove.fire(S),r.onMouseLeave=S=>this._onMouseLeave.fire(S),r.onMouseDown=S=>this._onMouseDown.fire(S),r.onMouseUp=S=>this._onMouseUp.fire(S),r.onMouseDrag=S=>this._onMouseDrag.fire(S),r.onMouseDrop=S=>this._onMouseDrop.fire(S),r.onMouseDropCanceled=S=>this._onMouseDropCanceled.fire(S),r.onMouseWheel=S=>this._onMouseWheel.fire(S),[new Ys(i,this._configuration,this._themeService.getColorTheme(),e,r,this._overflowWidgetsDomNode),!0]}_postDetachModelCleanup(e){e?.removeAllDecorationsWithOwnerId(this._id)}_detachModel(){if(!this._modelData)return null;const e=this._modelData.model,i=this._modelData.hasRealView?this._modelData.view.domNode.domNode:null;return this._modelData.dispose(),this._modelData=null,this._domElement.removeAttribute("data-mode-id"),i&&this._domElement.contains(i)&&this._domElement.removeChild(i),this._bannerDomNode&&this._domElement.contains(this._bannerDomNode)&&this._domElement.removeChild(this._bannerDomNode),e}_removeDecorationType(e){this._codeEditorService.removeDecorationType(e)}hasModel(){return this._modelData!==null}showDropIndicatorAt(e){const i=[{range:new Pt.Q(e.lineNumber,e.column,e.lineNumber,e.column),options:Ho.dropIntoEditorDecorationOptions}];this._dropIntoEditorDecorations.set(i),this.revealPosition(e,1)}removeDropIndicator(){this._dropIntoEditorDecorations.clear()}};lr.dropIntoEditorDecorationOptions=jn.kI.register({description:"workbench-dnd-target",className:"dnd-target"}),lr=Ur([_s(3,Jn._Y),_s(4,oe.T),_s(5,tr.wT),_s(6,Eo.fN),_s(7,kt.Gy),_s(8,ji.Ot),_s(9,j.j),_s(10,Hr.JZ),_s(11,zr.u)],lr);class jr extends p.jG{constructor(e){super(),this._emitterOptions=e,this._onDidChangeToTrue=this._register(new T.vl(this._emitterOptions)),this.onDidChangeToTrue=this._onDidChangeToTrue.event,this._onDidChangeToFalse=this._register(new T.vl(this._emitterOptions)),this.onDidChangeToFalse=this._onDidChangeToFalse.event,this._value=0}setValue(e){const i=e?2:1;this._value!==i&&(this._value=i,this._value===2?this._onDidChangeToTrue.fire():this._value===1&&this._onDidChangeToFalse.fire())}}class Kr extends p.jG{constructor(e,i){super(),this._editor=e,i.createKey("editorId",e.getId()),this._editorSimpleInput=xi.R.editorSimpleInput.bindTo(i),this._editorFocus=xi.R.focus.bindTo(i),this._textInputFocus=xi.R.textInputFocus.bindTo(i),this._editorTextFocus=xi.R.editorTextFocus.bindTo(i),this._editorTabMovesFocus=xi.R.tabMovesFocus.bindTo(i),this._editorReadonly=xi.R.readOnly.bindTo(i),this._inDiffEditor=xi.R.inDiffEditor.bindTo(i),this._editorColumnSelection=xi.R.columnSelection.bindTo(i),this._hasMultipleSelections=xi.R.hasMultipleSelections.bindTo(i),this._hasNonEmptySelection=xi.R.hasNonEmptySelection.bindTo(i),this._canUndo=xi.R.canUndo.bindTo(i),this._canRedo=xi.R.canRedo.bindTo(i),this._register(this._editor.onDidChangeConfiguration(()=>this._updateFromConfig())),this._register(this._editor.onDidChangeCursorSelection(()=>this._updateFromSelection())),this._register(this._editor.onDidFocusEditorWidget(()=>this._updateFromFocus())),this._register(this._editor.onDidBlurEditorWidget(()=>this._updateFromFocus())),this._register(this._editor.onDidFocusEditorText(()=>this._updateFromFocus())),this._register(this._editor.onDidBlurEditorText(()=>this._updateFromFocus())),this._register(this._editor.onDidChangeModel(()=>this._updateFromModel())),this._register(this._editor.onDidChangeConfiguration(()=>this._updateFromModel())),this._updateFromConfig(),this._updateFromSelection(),this._updateFromFocus(),this._updateFromModel(),this._editorSimpleInput.set(this._editor.isSimpleWidget)}_updateFromConfig(){const e=this._editor.getOptions();this._editorTabMovesFocus.set(e.get(132)),this._editorReadonly.set(e.get(83)),this._inDiffEditor.set(e.get(56)),this._editorColumnSelection.set(e.get(18))}_updateFromSelection(){const e=this._editor.getSelections();e?(this._hasMultipleSelections.set(e.length>1),this._hasNonEmptySelection.set(e.some(i=>!i.isEmpty()))):(this._hasMultipleSelections.reset(),this._hasNonEmptySelection.reset())}_updateFromFocus(){this._editorFocus.set(this._editor.hasWidgetFocus()&&!this._editor.isSimpleWidget),this._editorTextFocus.set(this._editor.hasTextFocus()&&!this._editor.isSimpleWidget),this._textInputFocus.set(this._editor.hasTextFocus())}_updateFromModel(){const e=this._editor.getModel();this._canUndo.set(!!(e&&e.canUndo())),this._canRedo.set(!!(e&&e.canRedo()))}}class $r extends p.jG{constructor(e,i,r){super(),this._editor=e,this._contextKeyService=i,this._languageFeaturesService=r,this._langId=xi.R.languageId.bindTo(i),this._hasCompletionItemProvider=xi.R.hasCompletionItemProvider.bindTo(i),this._hasCodeActionsProvider=xi.R.hasCodeActionsProvider.bindTo(i),this._hasCodeLensProvider=xi.R.hasCodeLensProvider.bindTo(i),this._hasDefinitionProvider=xi.R.hasDefinitionProvider.bindTo(i),this._hasDeclarationProvider=xi.R.hasDeclarationProvider.bindTo(i),this._hasImplementationProvider=xi.R.hasImplementationProvider.bindTo(i),this._hasTypeDefinitionProvider=xi.R.hasTypeDefinitionProvider.bindTo(i),this._hasHoverProvider=xi.R.hasHoverProvider.bindTo(i),this._hasDocumentHighlightProvider=xi.R.hasDocumentHighlightProvider.bindTo(i),this._hasDocumentSymbolProvider=xi.R.hasDocumentSymbolProvider.bindTo(i),this._hasReferenceProvider=xi.R.hasReferenceProvider.bindTo(i),this._hasRenameProvider=xi.R.hasRenameProvider.bindTo(i),this._hasSignatureHelpProvider=xi.R.hasSignatureHelpProvider.bindTo(i),this._hasInlayHintsProvider=xi.R.hasInlayHintsProvider.bindTo(i),this._hasDocumentFormattingProvider=xi.R.hasDocumentFormattingProvider.bindTo(i),this._hasDocumentSelectionFormattingProvider=xi.R.hasDocumentSelectionFormattingProvider.bindTo(i),this._hasMultipleDocumentFormattingProvider=xi.R.hasMultipleDocumentFormattingProvider.bindTo(i),this._hasMultipleDocumentSelectionFormattingProvider=xi.R.hasMultipleDocumentSelectionFormattingProvider.bindTo(i),this._isInWalkThrough=xi.R.isInWalkThroughSnippet.bindTo(i);const _=()=>this._update();this._register(e.onDidChangeModel(_)),this._register(e.onDidChangeModelLanguage(_)),this._register(r.completionProvider.onDidChange(_)),this._register(r.codeActionProvider.onDidChange(_)),this._register(r.codeLensProvider.onDidChange(_)),this._register(r.definitionProvider.onDidChange(_)),this._register(r.declarationProvider.onDidChange(_)),this._register(r.implementationProvider.onDidChange(_)),this._register(r.typeDefinitionProvider.onDidChange(_)),this._register(r.hoverProvider.onDidChange(_)),this._register(r.documentHighlightProvider.onDidChange(_)),this._register(r.documentSymbolProvider.onDidChange(_)),this._register(r.referenceProvider.onDidChange(_)),this._register(r.renameProvider.onDidChange(_)),this._register(r.documentFormattingEditProvider.onDidChange(_)),this._register(r.documentRangeFormattingEditProvider.onDidChange(_)),this._register(r.signatureHelpProvider.onDidChange(_)),this._register(r.inlayHintsProvider.onDidChange(_)),_()}dispose(){super.dispose()}reset(){this._contextKeyService.bufferChangeEvents(()=>{this._langId.reset(),this._hasCompletionItemProvider.reset(),this._hasCodeActionsProvider.reset(),this._hasCodeLensProvider.reset(),this._hasDefinitionProvider.reset(),this._hasDeclarationProvider.reset(),this._hasImplementationProvider.reset(),this._hasTypeDefinitionProvider.reset(),this._hasHoverProvider.reset(),this._hasDocumentHighlightProvider.reset(),this._hasDocumentSymbolProvider.reset(),this._hasReferenceProvider.reset(),this._hasRenameProvider.reset(),this._hasDocumentFormattingProvider.reset(),this._hasDocumentSelectionFormattingProvider.reset(),this._hasSignatureHelpProvider.reset(),this._isInWalkThrough.reset()})}_update(){const e=this._editor.getModel();if(!e){this.reset();return}this._contextKeyService.bufferChangeEvents(()=>{this._langId.set(e.getLanguageId()),this._hasCompletionItemProvider.set(this._languageFeaturesService.completionProvider.has(e)),this._hasCodeActionsProvider.set(this._languageFeaturesService.codeActionProvider.has(e)),this._hasCodeLensProvider.set(this._languageFeaturesService.codeLensProvider.has(e)),this._hasDefinitionProvider.set(this._languageFeaturesService.definitionProvider.has(e)),this._hasDeclarationProvider.set(this._languageFeaturesService.declarationProvider.has(e)),this._hasImplementationProvider.set(this._languageFeaturesService.implementationProvider.has(e)),this._hasTypeDefinitionProvider.set(this._languageFeaturesService.typeDefinitionProvider.has(e)),this._hasHoverProvider.set(this._languageFeaturesService.hoverProvider.has(e)),this._hasDocumentHighlightProvider.set(this._languageFeaturesService.documentHighlightProvider.has(e)),this._hasDocumentSymbolProvider.set(this._languageFeaturesService.documentSymbolProvider.has(e)),this._hasReferenceProvider.set(this._languageFeaturesService.referenceProvider.has(e)),this._hasRenameProvider.set(this._languageFeaturesService.renameProvider.has(e)),this._hasSignatureHelpProvider.set(this._languageFeaturesService.signatureHelpProvider.has(e)),this._hasInlayHintsProvider.set(this._languageFeaturesService.inlayHintsProvider.has(e)),this._hasDocumentFormattingProvider.set(this._languageFeaturesService.documentFormattingEditProvider.has(e)||this._languageFeaturesService.documentRangeFormattingEditProvider.has(e)),this._hasDocumentSelectionFormattingProvider.set(this._languageFeaturesService.documentRangeFormattingEditProvider.has(e)),this._hasMultipleDocumentFormattingProvider.set(this._languageFeaturesService.documentFormattingEditProvider.all(e).length+this._languageFeaturesService.documentRangeFormattingEditProvider.all(e).length>1),this._hasMultipleDocumentSelectionFormattingProvider.set(this._languageFeaturesService.documentRangeFormattingEditProvider.all(e).length>1),this._isInWalkThrough.set(e.uri.scheme===d.ny.walkThroughSnippet)})}}class Gr extends p.jG{constructor(e){super(),this._onChange=this._register(new T.vl),this.onChange=this._onChange.event,this._hasFocus=!1,this._domFocusTracker=this._register(P.w5(e)),this._register(this._domFocusTracker.onDidFocus(()=>{this._hasFocus=!0,this._onChange.fire(void 0)})),this._register(this._domFocusTracker.onDidBlur(()=>{this._hasFocus=!1,this._onChange.fire(void 0)}))}hasFocus(){return this._hasFocus}}class Ir{constructor(e,i){this._editor=e,this._decorationIds=[],this._isChangingDecorations=!1,Array.isArray(i)&&i.length>0&&this.set(i)}get length(){return this._decorationIds.length}onDidChange(e,i,r){return this._editor.onDidChangeModelDecorations(_=>{this._isChangingDecorations||e.call(i,_)},r)}getRange(e){return!this._editor.hasModel()||e>=this._decorationIds.length?null:this._editor.getModel().getDecorationRange(this._decorationIds[e])}getRanges(){if(!this._editor.hasModel())return[];const e=this._editor.getModel(),i=[];for(const r of this._decorationIds){const _=e.getDecorationRange(r);_&&i.push(_)}return i}has(e){return this._decorationIds.includes(e.id)}clear(){this._decorationIds.length!==0&&this.set([])}set(e){try{this._isChangingDecorations=!0,this._editor.changeDecorations(i=>{this._decorationIds=i.deltaDecorations(this._decorationIds,e)})}finally{this._isChangingDecorations=!1}}}const xr=encodeURIComponent("<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 6 3' enable-background='new 0 0 6 3' height='3' width='6'><g fill='"),Qr=encodeURIComponent("'><polygon points='5.5,0 2.5,3 1.1,3 4.1,0'/><polygon points='4,0 6,2 6,0.6 5.4,0'/><polygon points='0,2 1,3 2.4,3 0,0.6'/></g></svg>");function ls(Le){return xr+encodeURIComponent(Le.toString())+Qr}const Zr=encodeURIComponent('<svg xmlns="http://www.w3.org/2000/svg" height="3" width="12"><g fill="'),ho=encodeURIComponent('"><circle cx="1" cy="1" r="1"/><circle cx="5" cy="1" r="1"/><circle cx="9" cy="1" r="1"/></g></svg>');function Yr(Le){return Zr+encodeURIComponent(Le.toString())+ho}(0,kt.zy)((Le,e)=>{const i=Le.getColor(Li.AN$);i&&e.addRule(`.monaco-editor .squiggly-error { border-bottom: 4px double ${i}; }`);const r=Le.getColor(Li.Rbi);r&&e.addRule(`.monaco-editor .squiggly-error { background: url("data:image/svg+xml,${ls(r)}") repeat-x bottom left; }`);const _=Le.getColor(Li.Sj);_&&e.addRule(`.monaco-editor .squiggly-error::before { display: block; content: ''; width: 100%; height: 100%; background: ${_}; }`);const S=Le.getColor(Li.Stt);S&&e.addRule(`.monaco-editor .squiggly-warning { border-bottom: 4px double ${S}; }`);const z=Le.getColor(Li.Hng);z&&e.addRule(`.monaco-editor .squiggly-warning { background: url("data:image/svg+xml,${ls(z)}") repeat-x bottom left; }`);const ie=Le.getColor(Li.whs);ie&&e.addRule(`.monaco-editor .squiggly-warning::before { display: block; content: ''; width: 100%; height: 100%; background: ${ie}; }`);const re=Le.getColor(Li.IIb);re&&e.addRule(`.monaco-editor .squiggly-info { border-bottom: 4px double ${re}; }`);const le=Le.getColor(Li.pOz);le&&e.addRule(`.monaco-editor .squiggly-info { background: url("data:image/svg+xml,${ls(le)}") repeat-x bottom left; }`);const me=Le.getColor(Li.sDQ);me&&e.addRule(`.monaco-editor .squiggly-info::before { display: block; content: ''; width: 100%; height: 100%; background: ${me}; }`);const we=Le.getColor(Li.HWC);we&&e.addRule(`.monaco-editor .squiggly-hint { border-bottom: 2px dotted ${we}; }`);const Be=Le.getColor(Li.i61);Be&&e.addRule(`.monaco-editor .squiggly-hint { background: url("data:image/svg+xml,${Yr(Be)}") no-repeat bottom left; }`);const Re=Le.getColor(wt.yw);Re&&e.addRule(`.monaco-editor.showUnused .squiggly-inline-unnecessary { opacity: ${Re.rgba.a}; }`);const Je=Le.getColor(wt.Ln);Je&&e.addRule(`.monaco-editor.showUnused .squiggly-unnecessary { border-bottom: 2px dashed ${Je}; }`);const st=Le.getColor(Li.By2)||"inherit";e.addRule(`.monaco-editor.showDeprecated .squiggly-inline-deprecated { text-decoration: line-through; text-decoration-color: ${st}}`)})},77439:(rt,ye,y)=>{y.d(ye,{E:()=>T});var b=y(14333),o=y(87594),K=y(45854),$=y(50350),L=y(2106),U=y(10998),P=y(79359),B=function(p,d,g,h){function l(u){return u instanceof g?u:new g(function(w){w(u)})}return new(g||(g=Promise))(function(u,w){function C(k){try{v(h.next(k))}catch(D){w(D)}}function m(k){try{v(h.throw(k))}catch(D){w(D)}}function v(k){k.done?u(k.value):l(k.value).then(C,m)}v((h=h.apply(p,d||[])).next())})};class T extends U.jG{constructor(d,g={}){var h,l,u,w,C,m;super(),this.triggerKeyDown=!1,this.focusable=!0,this._onDidBlur=this._register(new L.vl),this.onDidBlur=this._onDidBlur.event,this._onDidCancel=this._register(new L.vl({onFirstListenerAdd:()=>this.cancelHasListener=!0})),this.onDidCancel=this._onDidCancel.event,this.cancelHasListener=!1,this._onDidRun=this._register(new L.vl),this.onDidRun=this._onDidRun.event,this._onBeforeRun=this._register(new L.vl),this.onBeforeRun=this._onBeforeRun.event,this.options=g,this._context=(h=g.context)!==null&&h!==void 0?h:null,this._orientation=(l=this.options.orientation)!==null&&l!==void 0?l:0,this._triggerKeys={keyDown:(w=(u=this.options.triggerKeys)===null||u===void 0?void 0:u.keyDown)!==null&&w!==void 0?w:!1,keys:(m=(C=this.options.triggerKeys)===null||C===void 0?void 0:C.keys)!==null&&m!==void 0?m:[3,10]},this.options.actionRunner?this._actionRunner=this.options.actionRunner:(this._actionRunner=new $.LN,this._register(this._actionRunner)),this._register(this._actionRunner.onDidRun(D=>this._onDidRun.fire(D))),this._register(this._actionRunner.onBeforeRun(D=>this._onBeforeRun.fire(D))),this._actionIds=[],this.viewItems=[],this.viewItemDisposables=new Map,this.focusedItem=void 0,this.domNode=document.createElement("div"),this.domNode.className="monaco-action-bar",g.animated!==!1&&this.domNode.classList.add("animated");let v,k;switch(this._orientation){case 0:v=[15],k=[17];break;case 1:v=[16],k=[18],this.domNode.className+=" vertical";break}this._register(b.ko(this.domNode,b.Bx.KEY_DOWN,D=>{const x=new o.Z(D);let A=!0;const W=typeof this.focusedItem=="number"?this.viewItems[this.focusedItem]:void 0;v&&(x.equals(v[0])||x.equals(v[1]))?A=this.focusPrevious():k&&(x.equals(k[0])||x.equals(k[1]))?A=this.focusNext():x.equals(9)&&this.cancelHasListener?this._onDidCancel.fire():x.equals(14)?A=this.focusFirst():x.equals(13)?A=this.focusLast():x.equals(2)&&W instanceof K.E&&W.trapsArrowNavigation?A=this.focusNext():this.isTriggerKeyEvent(x)?this._triggerKeys.keyDown?this.doTrigger(x):this.triggerKeyDown=!0:A=!1,A&&(x.preventDefault(),x.stopPropagation())})),this._register(b.ko(this.domNode,b.Bx.KEY_UP,D=>{const x=new o.Z(D);this.isTriggerKeyEvent(x)?(!this._triggerKeys.keyDown&&this.triggerKeyDown&&(this.triggerKeyDown=!1,this.doTrigger(x)),x.preventDefault(),x.stopPropagation()):(x.equals(2)||x.equals(1026))&&this.updateFocusedItem()})),this.focusTracker=this._register(b.w5(this.domNode)),this._register(this.focusTracker.onDidBlur(()=>{(b.bq()===this.domNode||!b.QX(b.bq(),this.domNode))&&(this._onDidBlur.fire(),this.focusedItem=void 0,this.previouslyFocusedItem=void 0,this.triggerKeyDown=!1)})),this._register(this.focusTracker.onDidFocus(()=>this.updateFocusedItem())),this.actionsList=document.createElement("ul"),this.actionsList.className="actions-container",this.actionsList.setAttribute("role",this.options.ariaRole||"toolbar"),this.options.ariaLabel&&this.actionsList.setAttribute("aria-label",this.options.ariaLabel),this.domNode.appendChild(this.actionsList),d.appendChild(this.domNode)}refreshRole(){this.length()>=2?this.actionsList.setAttribute("role",this.options.ariaRole||"toolbar"):this.actionsList.setAttribute("role","presentation")}setFocusable(d){if(this.focusable=d,this.focusable){const g=this.viewItems.find(h=>h instanceof K.E&&h.isEnabled());g instanceof K.E&&g.setFocusable(!0)}else this.viewItems.forEach(g=>{g instanceof K.E&&g.setFocusable(!1)})}isTriggerKeyEvent(d){let g=!1;return this._triggerKeys.keys.forEach(h=>{g=g||d.equals(h)}),g}updateFocusedItem(){for(let d=0;d<this.actionsList.children.length;d++){const g=this.actionsList.children[d];if(b.QX(b.bq(),g)){this.focusedItem=d;break}}}get context(){return this._context}set context(d){this._context=d,this.viewItems.forEach(g=>g.setActionContext(d))}get actionRunner(){return this._actionRunner}set actionRunner(d){d&&(this._actionRunner=d,this.viewItems.forEach(g=>g.actionRunner=d))}getContainer(){return this.domNode}push(d,g={}){const h=Array.isArray(d)?d:[d];let l=P.Et(g.index)?g.index:null;h.forEach(u=>{const w=document.createElement("li");w.className="action-item",w.setAttribute("role","presentation");let C;this.options.actionViewItemProvider&&(C=this.options.actionViewItemProvider(u)),C||(C=new K.Z(this.context,u,Object.assign({hoverDelegate:this.options.hoverDelegate},g))),this.options.allowContextMenu||this.viewItemDisposables.set(C,b.ko(w,b.Bx.CONTEXT_MENU,m=>{b.fs.stop(m,!0)})),C.actionRunner=this._actionRunner,C.setActionContext(this.context),C.render(w),this.focusable&&C instanceof K.E&&this.viewItems.length===0&&C.setFocusable(!0),l===null||l<0||l>=this.actionsList.children.length?(this.actionsList.appendChild(w),this.viewItems.push(C),this._actionIds.push(u.id)):(this.actionsList.insertBefore(w,this.actionsList.children[l]),this.viewItems.splice(l,0,C),this._actionIds.splice(l,0,u.id),l++)}),typeof this.focusedItem=="number"&&this.focus(this.focusedItem),this.refreshRole()}clear(){(0,U.AS)(this.viewItems),this.viewItemDisposables.forEach(d=>d.dispose()),this.viewItemDisposables.clear(),this.viewItems=[],this._actionIds=[],b.w_(this.actionsList),this.refreshRole()}length(){return this.viewItems.length}focus(d){let g=!1,h;if(d===void 0?g=!0:typeof d=="number"?h=d:typeof d=="boolean"&&(g=d),g&&typeof this.focusedItem>"u"){const l=this.viewItems.findIndex(u=>u.isEnabled());this.focusedItem=l===-1?void 0:l,this.updateFocus(void 0,void 0,!0)}else h!==void 0&&(this.focusedItem=h),this.updateFocus(void 0,void 0,!0)}focusFirst(){return this.focusedItem=this.length()-1,this.focusNext(!0)}focusLast(){return this.focusedItem=0,this.focusPrevious(!0)}focusNext(d){if(typeof this.focusedItem>"u")this.focusedItem=this.viewItems.length-1;else if(this.viewItems.length<=1)return!1;const g=this.focusedItem;let h;do{if(!d&&this.options.preventLoopNavigation&&this.focusedItem+1>=this.viewItems.length)return this.focusedItem=g,!1;this.focusedItem=(this.focusedItem+1)%this.viewItems.length,h=this.viewItems[this.focusedItem]}while(this.focusedItem!==g&&(this.options.focusOnlyEnabledItems&&!h.isEnabled()||h.action.id===$.wv.ID));return this.updateFocus(),!0}focusPrevious(d){if(typeof this.focusedItem>"u")this.focusedItem=0;else if(this.viewItems.length<=1)return!1;const g=this.focusedItem;let h;do{if(this.focusedItem=this.focusedItem-1,this.focusedItem<0){if(!d&&this.options.preventLoopNavigation)return this.focusedItem=g,!1;this.focusedItem=this.viewItems.length-1}h=this.viewItems[this.focusedItem]}while(this.focusedItem!==g&&(this.options.focusOnlyEnabledItems&&!h.isEnabled()||h.action.id===$.wv.ID));return this.updateFocus(!0),!0}updateFocus(d,g,h=!1){var l;typeof this.focusedItem>"u"&&this.actionsList.focus({preventScroll:g}),this.previouslyFocusedItem!==void 0&&this.previouslyFocusedItem!==this.focusedItem&&((l=this.viewItems[this.previouslyFocusedItem])===null||l===void 0||l.blur());const u=this.focusedItem!==void 0&&this.viewItems[this.focusedItem];if(u){let w=!0;P.Tn(u.focus)||(w=!1),this.options.focusOnlyEnabledItems&&P.Tn(u.isEnabled)&&!u.isEnabled()&&(w=!1),u.action.id===$.wv.ID&&(w=!1),w?(h||this.previouslyFocusedItem!==this.focusedItem)&&(u.focus(d),this.previouslyFocusedItem=this.focusedItem):(this.actionsList.focus({preventScroll:g}),this.previouslyFocusedItem=void 0)}}doTrigger(d){if(typeof this.focusedItem>"u")return;const g=this.viewItems[this.focusedItem];if(g instanceof K.E){const h=g._context===null||g._context===void 0?d:g._context;this.run(g._action,h)}}run(d,g){return B(this,void 0,void 0,function*(){yield this._actionRunner.run(d,g)})}dispose(){(0,U.AS)(this.viewItems),this.viewItems=[],this._actionIds=[],this.getContainer().remove(),super.dispose()}}},77922:(rt,ye,y)=>{y.d(ye,{L:()=>o});var b=y(82399);const o=(0,b.u1)("languageService")},78518:(rt,ye,y)=>{y.d(ye,{No:()=>p,TH:()=>L,Zn:()=>P,_1:()=>B,kb:()=>U});var b=y(18019),o=y(63339),K=y(16844);function $(d){return d===47||d===92}function L(d){return d.replace(/[\\/]/g,b.SA.sep)}function U(d){return d.indexOf("/")===-1&&(d=L(d)),/^[a-zA-Z]:(\/|$)/.test(d)&&(d="/"+d),d}function P(d,g=b.SA.sep){if(!d)return"";const h=d.length,l=d.charCodeAt(0);if($(l)){if($(d.charCodeAt(1))&&!$(d.charCodeAt(2))){let w=3;const C=w;for(;w<h&&!$(d.charCodeAt(w));w++);if(C!==w&&!$(d.charCodeAt(w+1))){for(w+=1;w<h;w++)if($(d.charCodeAt(w)))return d.slice(0,w+1).replace(/[\\/]/g,g)}}return g}else if(T(l)&&d.charCodeAt(1)===58)return $(d.charCodeAt(2))?d.slice(0,2)+g:d.slice(0,2);let u=d.indexOf("://");if(u!==-1){for(u+=3;u<h;u++)if($(d.charCodeAt(u)))return d.slice(0,u+1)}return""}function B(d,g,h,l=b.Vn){if(d===g)return!0;if(!d||!g||g.length>d.length)return!1;if(h){if(!(0,K.ns)(d,g))return!1;if(g.length===d.length)return!0;let w=g.length;return g.charAt(g.length-1)===l&&w--,d.charAt(w)===l}return g.charAt(g.length-1)!==l&&(g+=l),d.indexOf(g)===0}function T(d){return d>=65&&d<=90||d>=97&&d<=122}function p(d,g=o.uF){return g?T(d.charCodeAt(0))&&d.charCodeAt(1)===58:!1}},78903:(rt,ye,y)=>{y.d(ye,{Q:()=>L,X:()=>K});var b=y(2106);const o=Object.freeze(function(U,P){const B=setTimeout(U.bind(P),0);return{dispose(){clearTimeout(B)}}});var K;(function(U){function P(B){return B===U.None||B===U.Cancelled||B instanceof $?!0:!B||typeof B!="object"?!1:typeof B.isCancellationRequested=="boolean"&&typeof B.onCancellationRequested=="function"}U.isCancellationToken=P,U.None=Object.freeze({isCancellationRequested:!1,onCancellationRequested:b.Jh.None}),U.Cancelled=Object.freeze({isCancellationRequested:!0,onCancellationRequested:o})})(K||(K={}));class ${constructor(){this._isCancelled=!1,this._emitter=null}cancel(){this._isCancelled||(this._isCancelled=!0,this._emitter&&(this._emitter.fire(void 0),this.dispose()))}get isCancellationRequested(){return this._isCancelled}get onCancellationRequested(){return this._isCancelled?o:(this._emitter||(this._emitter=new b.vl),this._emitter.event)}dispose(){this._emitter&&(this._emitter.dispose(),this._emitter=null)}}class L{constructor(P){this._token=void 0,this._parentListener=void 0,this._parentListener=P&&P.onCancellationRequested(this.cancel,this)}get token(){return this._token||(this._token=new $),this._token}cancel(){this._token?this._token instanceof $&&this._token.cancel():this._token=K.Cancelled}dispose(P=!1){P&&this.cancel(),this._parentListener&&this._parentListener.dispose(),this._token?this._token instanceof $&&this._token.dispose():this._token=K.None}}},79359:(rt,ye,y)=>{y.d(ye,{Et:()=>L,Gv:()=>K,Kg:()=>o,Lm:()=>P,O9:()=>T,Tn:()=>h,UH:()=>v,V0:()=>C,b0:()=>B,cy:()=>b,eU:()=>g,iu:()=>$,j:()=>d,jx:()=>l,kT:()=>m,xZ:()=>U,xb:()=>k,z:()=>p});function b(D){return Array.isArray(D)}function o(D){return typeof D=="string"}function K(D){return typeof D=="object"&&D!==null&&!Array.isArray(D)&&!(D instanceof RegExp)&&!(D instanceof Date)}function $(D){const x=Object.getPrototypeOf(Uint8Array);return typeof D=="object"&&D instanceof x}function L(D){return typeof D=="number"&&!isNaN(D)}function U(D){return!!D&&typeof D[Symbol.iterator]=="function"}function P(D){return D===!0||D===!1}function B(D){return typeof D>"u"}function T(D){return!p(D)}function p(D){return B(D)||D===null}function d(D,x){if(!D)throw new Error(x?`Unexpected type, expected '${x}'`:"Unexpected type")}function g(D){if(p(D))throw new Error("Assertion Failed: argument is undefined or null");return D}function h(D){return typeof D=="function"}function l(D,x){const A=Math.min(D.length,x.length);for(let W=0;W<A;W++)u(D[W],x[W])}function u(D,x){if(o(x)){if(typeof D!==x)throw new Error(`argument does not match constraint: typeof ${x}`)}else if(h(x)){try{if(D instanceof x)return}catch{}if(!p(D)&&D.constructor===x||x.length===1&&x.call(void 0,D)===!0)return;throw new Error("argument does not match one of these constraints: arg instanceof constraint, arg.constructor === constraint, nor constraint(arg) === true")}}function w(D){let x=[],A=Object.getPrototypeOf(D);for(;Object.prototype!==A;)x=x.concat(Object.getOwnPropertyNames(A)),A=Object.getPrototypeOf(A);return x}function C(D){const x=[];for(const A of w(D))typeof D[A]=="function"&&x.push(A);return x}function m(D,x){const A=Y=>function(){const ne=Array.prototype.slice.call(arguments,0);return x(Y,ne)},W={};for(const Y of D)W[Y]=A(Y);return W}function v(D){return D===null?void 0:D}function k(D,x="Unreachable"){throw new Error(x)}},80794:(rt,ye,y)=>{y.d(ye,{h:()=>K});var b=y(49550),o=y(52394);function K($,L,U,P){const B=(0,o.P6)(L,U.startLineNumber,U.startColumn),T=P.getLanguageConfiguration(B.languageId);if(!T)return null;const p=B.getLineContent(),d=p.substr(0,U.startColumn-1-B.firstCharOffset);let g;U.isEmpty()?g=p.substr(U.startColumn-1-B.firstCharOffset):g=(0,o.P6)(L,U.endLineNumber,U.endColumn).getLineContent().substr(U.endColumn-1-B.firstCharOffset);let h="";if(U.startLineNumber>1&&B.firstCharOffset===0){const v=(0,o.P6)(L,U.startLineNumber-1);v.languageId===B.languageId&&(h=v.getLineContent())}const l=T.onEnter($,h,d,g);if(!l)return null;const u=l.indentAction;let w=l.appendText;const C=l.removeText||0;w?u===b.l.Indent&&(w=" "+w):u===b.l.Indent||u===b.l.IndentOutdent?w=" ":w="";let m=(0,o.Cw)(L,U.startLineNumber,U.startColumn);return C&&(m=m.substring(0,m.length-C)),{indentAction:u,appendText:w,removeText:C,indentation:m}}},80878:(rt,ye,y)=>{y.d(ye,{D:()=>b});class b{constructor(K,$,L){this._visiblePosition=K,this._visiblePositionScrollDelta=$,this._cursorPosition=L}static capture(K){let $=null,L=0;if(K.getScrollTop()!==0){const U=K.getVisibleRanges();if(U.length>0){$=U[0].getStartPosition();const P=K.getTopForPosition($.lineNumber,$.column);L=K.getScrollTop()-P}}return new b($,L,K.getPosition())}restore(K){if(this._visiblePosition){const $=K.getTopForPosition(this._visiblePosition.lineNumber,this._visiblePosition.column);K.setScrollTop($+this._visiblePositionScrollDelta)}}restoreRelativeVerticalPositionOfCursor(K){const $=K.getPosition();if(!this._cursorPosition||!$)return;const L=K.getTopForLineNumber($.lineNumber)-K.getTopForLineNumber(this._cursorPosition.lineNumber);K.setScrollTop(K.getScrollTop()+L)}}},80886:(rt,ye,y)=>{y.d(ye,{A:()=>o});var b=y(82399);const o=(0,b.u1)("markerDecorationsService")},82399:(rt,ye,y)=>{y.d(ye,{_$:()=>b,_Y:()=>o,u1:()=>$});var b;(function(L){L.serviceIds=new Map,L.DI_TARGET="$di$target",L.DI_DEPENDENCIES="$di$dependencies";function U(P){return P[L.DI_DEPENDENCIES]||[]}L.getServiceDependencies=U})(b||(b={}));const o=$("instantiationService");function K(L,U,P){U[b.DI_TARGET]===U?U[b.DI_DEPENDENCIES].push({id:L,index:P}):(U[b.DI_DEPENDENCIES]=[{id:L,index:P}],U[b.DI_TARGET]=U)}function $(L){if(b.serviceIds.has(L))return b.serviceIds.get(L);const U=function(P,B,T){if(arguments.length!==3)throw new Error("@IServiceName-decorator can only be used to decorate a parameter");K(U,P,T)};return U.toString=()=>L,b.serviceIds.set(L,U),U}},82862:(rt,ye,y)=>{y.d(ye,{i:()=>$});var b=y(27454);class o extends b.V{constructor(U){super(0);for(let P=0,B=U.length;P<B;P++)this.set(U.charCodeAt(P),2);this.set(32,1),this.set(9,1)}}function K(L){const U={};return P=>(U.hasOwnProperty(P)||(U[P]=L(P)),U[P])}const $=K(L=>new o(L))},83022:(rt,ye,y)=>{y.d(ye,{ur:()=>A,uO:()=>Q});var b=y(55893),o=y(39587),K=y(14333),$=y(34061),L=y(30474),U=y(63781),P=y(13338),B=y(65958),T=y(88846),p=y(2106),d=y(10998),g=y(4580),h=y(94513);function l(X,R){const H=[];for(const Z of R){if(X.start>=Z.range.end)continue;if(X.end<Z.range.start)break;const N=g.Q.intersect(X,Z.range);g.Q.isEmpty(N)||H.push({range:N,size:Z.size})}return H}function u({start:X,end:R},H){return{start:X+H,end:R+H}}function w(X){const R=[];let H=null;for(const Z of X){const N=Z.range.start,G=Z.range.end,O=Z.size;if(H&&O===H.size){H.range.end=G;continue}H={range:{start:N,end:G},size:O},R.push(H)}return R}function C(...X){return w(X.reduce((R,H)=>R.concat(H),[]))}class m{constructor(){this.groups=[],this._size=0}splice(R,H,Z=[]){const N=Z.length-H,G=l({start:0,end:R},this.groups),O=l({start:R+H,end:Number.POSITIVE_INFINITY},this.groups).map(oe=>({range:u(oe.range,N),size:oe.size})),te=Z.map((oe,ue)=>({range:{start:R+ue,end:R+ue+1},size:oe.size}));this.groups=C(G,te,O),this._size=this.groups.reduce((oe,ue)=>oe+ue.size*(ue.range.end-ue.range.start),0)}get count(){const R=this.groups.length;return R?this.groups[R-1].range.end:0}get size(){return this._size}indexAt(R){if(R<0)return-1;let H=0,Z=0;for(const N of this.groups){const G=N.range.end-N.range.start,O=Z+G*N.size;if(R<O)return H+Math.floor((R-Z)/N.size);H+=G,Z=O}return H}indexAfter(R){return Math.min(this.indexAt(R)+1,this.count)}positionAt(R){if(R<0)return-1;let H=0,Z=0;for(const N of this.groups){const G=N.range.end-N.range.start,O=Z+G;if(R<O)return H+(R-Z)*N.size;H+=G*N.size,Z=O}return-1}}function v(X){var R;try{(R=X.parentElement)===null||R===void 0||R.removeChild(X)}catch{}}class k{constructor(R){this.renderers=R,this.cache=new Map}alloc(R){let H=this.getTemplateCache(R).pop();if(!H){const Z=(0,K.$)(".monaco-list-row"),G=this.getRenderer(R).renderTemplate(Z);H={domNode:Z,templateId:R,templateData:G}}return H}release(R){R&&this.releaseRow(R)}releaseRow(R){const{domNode:H,templateId:Z}=R;H&&(H.classList.remove("scrolling"),v(H)),this.getTemplateCache(Z).push(R)}getTemplateCache(R){let H=this.cache.get(R);return H||(H=[],this.cache.set(R,H)),H}dispose(){this.cache.forEach((R,H)=>{for(const Z of R)this.getRenderer(H).disposeTemplate(Z.templateData),Z.templateData=null}),this.cache.clear()}getRenderer(R){const H=this.renderers.get(R);if(!H)throw new Error(`No renderer found for ${R}`);return H}}var D=function(X,R,H,Z){var N=arguments.length,G=N<3?R:Z===null?Z=Object.getOwnPropertyDescriptor(R,H):Z,O;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")G=Reflect.decorate(X,R,H,Z);else for(var te=X.length-1;te>=0;te--)(O=X[te])&&(G=(N<3?O(G):N>3?O(R,H,G):O(R,H))||G);return N>3&&G&&Object.defineProperty(R,H,G),G};const x={useShadows:!0,verticalScrollMode:1,setRowLineHeight:!0,setRowHeight:!0,supportDynamicHeights:!1,dnd:{getDragElements(X){return[X]},getDragURI(){return null},onDragStart(){},onDragOver(){return!1},drop(){}},horizontalScrolling:!1,transformOptimization:!0,alwaysConsumeMouseWheel:!0};class A{constructor(R){this.elements=R}update(){}getData(){return this.elements}}class W{constructor(R){this.elements=R}update(){}getData(){return this.elements}}class Y{constructor(){this.types=[],this.files=[]}update(R){if(R.types&&this.types.splice(0,this.types.length,...R.types),R.files){this.files.splice(0,this.files.length);for(let H=0;H<R.files.length;H++){const Z=R.files.item(H);Z&&(Z.size||Z.type)&&this.files.push(Z)}}}getData(){return{types:this.types,files:this.files}}}function ne(X,R){return Array.isArray(X)&&Array.isArray(R)?(0,P.aI)(X,R):X===R}class j{constructor(R){R?.getSetSize?this.getSetSize=R.getSetSize.bind(R):this.getSetSize=(H,Z,N)=>N,R?.getPosInSet?this.getPosInSet=R.getPosInSet.bind(R):this.getPosInSet=(H,Z)=>Z+1,R?.getRole?this.getRole=R.getRole.bind(R):this.getRole=H=>"listitem",R?.isChecked?this.isChecked=R.isChecked.bind(R):this.isChecked=H=>{}}}class Q{constructor(R,H,Z,N=x){var G,O,te,oe,ue,E,Qe,Ke,Se,Me;if(this.virtualDelegate=H,this.domId=`list_id_${++Q.InstanceCount}`,this.renderers=new Map,this.renderWidth=0,this._scrollHeight=0,this.scrollableElementUpdateDisposable=null,this.scrollableElementWidthDelayer=new B.ve(50),this.splicing=!1,this.dragOverAnimationStopDisposable=d.jG.None,this.dragOverMouseY=0,this.canDrop=!1,this.currentDragFeedbackDisposable=d.jG.None,this.onDragLeaveTimeout=d.jG.None,this.disposables=new d.Cm,this._onDidChangeContentHeight=new p.vl,this._horizontalScrolling=!1,N.horizontalScrolling&&N.supportDynamicHeights)throw new Error("Horizontal scrolling and dynamic heights not supported simultaneously");this.items=[],this.itemId=0,this.rangeMap=new m;for(const pe of Z)this.renderers.set(pe.templateId,pe);this.cache=this.disposables.add(new k(this.renderers)),this.lastRenderTop=0,this.lastRenderHeight=0,this.domNode=document.createElement("div"),this.domNode.className="monaco-list",this.domNode.classList.add(this.domId),this.domNode.tabIndex=0,this.domNode.classList.toggle("mouse-support",typeof N.mouseSupport=="boolean"?N.mouseSupport:!0),this._horizontalScrolling=(G=N.horizontalScrolling)!==null&&G!==void 0?G:x.horizontalScrolling,this.domNode.classList.toggle("horizontal-scrolling",this._horizontalScrolling),this.additionalScrollHeight=typeof N.additionalScrollHeight>"u"?0:N.additionalScrollHeight,this.accessibilityProvider=new j(N.accessibilityProvider),this.rowsContainer=document.createElement("div"),this.rowsContainer.className="monaco-list-rows",((O=N.transformOptimization)!==null&&O!==void 0?O:x.transformOptimization)&&(this.rowsContainer.style.transform="translate3d(0px, 0px, 0px)"),this.disposables.add(L.q.addTarget(this.rowsContainer)),this.scrollable=new h.yE({forceIntegerValues:!0,smoothScrollDuration:(te=N.smoothScrolling)!==null&&te!==void 0&&te?125:0,scheduleAtNextAnimationFrame:pe=>(0,K.PG)(pe)}),this.scrollableElement=this.disposables.add(new U.oO(this.rowsContainer,{alwaysConsumeMouseWheel:(oe=N.alwaysConsumeMouseWheel)!==null&&oe!==void 0?oe:x.alwaysConsumeMouseWheel,horizontal:1,vertical:(ue=N.verticalScrollMode)!==null&&ue!==void 0?ue:x.verticalScrollMode,useShadows:(E=N.useShadows)!==null&&E!==void 0?E:x.useShadows,mouseWheelScrollSensitivity:N.mouseWheelScrollSensitivity,fastScrollSensitivity:N.fastScrollSensitivity},this.scrollable)),this.domNode.appendChild(this.scrollableElement.getDomNode()),R.appendChild(this.domNode),this.scrollableElement.onScroll(this.onScroll,this,this.disposables),this.disposables.add((0,K.ko)(this.rowsContainer,L.B.Change,pe=>this.onTouchChange(pe))),this.disposables.add((0,K.ko)(this.scrollableElement.getDomNode(),"scroll",pe=>pe.target.scrollTop=0)),this.disposables.add((0,K.ko)(this.domNode,"dragover",pe=>this.onDragOver(this.toDragEvent(pe)))),this.disposables.add((0,K.ko)(this.domNode,"drop",pe=>this.onDrop(this.toDragEvent(pe)))),this.disposables.add((0,K.ko)(this.domNode,"dragleave",pe=>this.onDragLeave(this.toDragEvent(pe)))),this.disposables.add((0,K.ko)(this.domNode,"dragend",pe=>this.onDragEnd(pe))),this.setRowLineHeight=(Qe=N.setRowLineHeight)!==null&&Qe!==void 0?Qe:x.setRowLineHeight,this.setRowHeight=(Ke=N.setRowHeight)!==null&&Ke!==void 0?Ke:x.setRowHeight,this.supportDynamicHeights=(Se=N.supportDynamicHeights)!==null&&Se!==void 0?Se:x.supportDynamicHeights,this.dnd=(Me=N.dnd)!==null&&Me!==void 0?Me:x.dnd,this.layout()}get contentHeight(){return this.rangeMap.size}get horizontalScrolling(){return this._horizontalScrolling}set horizontalScrolling(R){if(R!==this._horizontalScrolling){if(R&&this.supportDynamicHeights)throw new Error("Horizontal scrolling and dynamic heights not supported simultaneously");if(this._horizontalScrolling=R,this.domNode.classList.toggle("horizontal-scrolling",this._horizontalScrolling),this._horizontalScrolling){for(const H of this.items)this.measureItemWidth(H);this.updateScrollWidth(),this.scrollableElement.setScrollDimensions({width:(0,K.y6)(this.domNode)}),this.rowsContainer.style.width=`${Math.max(this.scrollWidth||0,this.renderWidth)}px`}else this.scrollableElementWidthDelayer.cancel(),this.scrollableElement.setScrollDimensions({width:this.renderWidth,scrollWidth:this.renderWidth}),this.rowsContainer.style.width=""}}updateOptions(R){R.additionalScrollHeight!==void 0&&(this.additionalScrollHeight=R.additionalScrollHeight,this.scrollableElement.setScrollDimensions({scrollHeight:this.scrollHeight})),R.smoothScrolling!==void 0&&this.scrollable.setSmoothScrollDuration(R.smoothScrolling?125:0),R.horizontalScrolling!==void 0&&(this.horizontalScrolling=R.horizontalScrolling),R.mouseWheelScrollSensitivity!==void 0&&this.scrollableElement.updateOptions({mouseWheelScrollSensitivity:R.mouseWheelScrollSensitivity}),R.fastScrollSensitivity!==void 0&&this.scrollableElement.updateOptions({fastScrollSensitivity:R.fastScrollSensitivity})}splice(R,H,Z=[]){if(this.splicing)throw new Error("Can't run recursive splices.");this.splicing=!0;try{return this._splice(R,H,Z)}finally{this.splicing=!1,this._onDidChangeContentHeight.fire(this.contentHeight)}}_splice(R,H,Z=[]){const N=this.getRenderRange(this.lastRenderTop,this.lastRenderHeight),G={start:R,end:R+H},O=g.Q.intersect(N,G),te=new Map;for(let Ae=O.end-1;Ae>=O.start;Ae--){const he=this.items[Ae];if(he.dragStartDisposable.dispose(),he.checkedDisposable.dispose(),he.row){let Pe=te.get(he.templateId);Pe||(Pe=[],te.set(he.templateId,Pe));const $e=this.renderers.get(he.templateId);$e&&$e.disposeElement&&$e.disposeElement(he.element,Ae,he.row.templateData,he.size),Pe.push(he.row)}he.row=null}const oe={start:R+H,end:this.items.length},ue=g.Q.intersect(oe,N),E=g.Q.relativeComplement(oe,N),Qe=Z.map(Ae=>({id:String(this.itemId++),element:Ae,templateId:this.virtualDelegate.getTemplateId(Ae),size:this.virtualDelegate.getHeight(Ae),width:void 0,hasDynamicHeight:!!this.virtualDelegate.hasDynamicHeight&&this.virtualDelegate.hasDynamicHeight(Ae),lastDynamicHeightWidth:void 0,row:null,uri:void 0,dropTarget:!1,dragStartDisposable:d.jG.None,checkedDisposable:d.jG.None}));let Ke;R===0&&H>=this.items.length?(this.rangeMap=new m,this.rangeMap.splice(0,0,Qe),Ke=this.items,this.items=Qe):(this.rangeMap.splice(R,H,Qe),Ke=this.items.splice(R,H,...Qe));const Se=Z.length-H,Me=this.getRenderRange(this.lastRenderTop,this.lastRenderHeight),ce=u(ue,Se),pe=g.Q.intersect(Me,ce);for(let Ae=pe.start;Ae<pe.end;Ae++)this.updateItemInDOM(this.items[Ae],Ae);const be=g.Q.relativeComplement(ce,Me);for(const Ae of be)for(let he=Ae.start;he<Ae.end;he++)this.removeItemFromDOM(he);const ge=E.map(Ae=>u(Ae,Se)),We=[{start:R,end:R+Z.length},...ge].map(Ae=>g.Q.intersect(Me,Ae)),Ge=this.getNextToLastElement(We);for(const Ae of We)for(let he=Ae.start;he<Ae.end;he++){const Pe=this.items[he],$e=te.get(Pe.templateId),it=$e?.pop();this.insertItemInDOM(he,Ge,it)}for(const Ae of te.values())for(const he of Ae)this.cache.release(he);return this.eventuallyUpdateScrollDimensions(),this.supportDynamicHeights&&this._rerender(this.scrollTop,this.renderHeight),Ke.map(Ae=>Ae.element)}eventuallyUpdateScrollDimensions(){this._scrollHeight=this.contentHeight,this.rowsContainer.style.height=`${this._scrollHeight}px`,this.scrollableElementUpdateDisposable||(this.scrollableElementUpdateDisposable=(0,K.PG)(()=>{this.scrollableElement.setScrollDimensions({scrollHeight:this.scrollHeight}),this.updateScrollWidth(),this.scrollableElementUpdateDisposable=null}))}eventuallyUpdateScrollWidth(){if(!this.horizontalScrolling){this.scrollableElementWidthDelayer.cancel();return}this.scrollableElementWidthDelayer.trigger(()=>this.updateScrollWidth())}updateScrollWidth(){if(!this.horizontalScrolling)return;let R=0;for(const H of this.items)typeof H.width<"u"&&(R=Math.max(R,H.width));this.scrollWidth=R,this.scrollableElement.setScrollDimensions({scrollWidth:R===0?0:R+10})}rerender(){if(this.supportDynamicHeights){for(const R of this.items)R.lastDynamicHeightWidth=void 0;this._rerender(this.lastRenderTop,this.lastRenderHeight)}}get length(){return this.items.length}get renderHeight(){return this.scrollableElement.getScrollDimensions().height}element(R){return this.items[R].element}domElement(R){const H=this.items[R].row;return H&&H.domNode}elementHeight(R){return this.items[R].size}elementTop(R){return this.rangeMap.positionAt(R)}indexAt(R){return this.rangeMap.indexAt(R)}indexAfter(R){return this.rangeMap.indexAfter(R)}layout(R,H){const Z={height:typeof R=="number"?R:(0,K.H4)(this.domNode)};this.scrollableElementUpdateDisposable&&(this.scrollableElementUpdateDisposable.dispose(),this.scrollableElementUpdateDisposable=null,Z.scrollHeight=this.scrollHeight),this.scrollableElement.setScrollDimensions(Z),typeof H<"u"&&(this.renderWidth=H,this.supportDynamicHeights&&this._rerender(this.scrollTop,this.renderHeight)),this.horizontalScrolling&&this.scrollableElement.setScrollDimensions({width:typeof H=="number"?H:(0,K.y6)(this.domNode)})}render(R,H,Z,N,G,O=!1){const te=this.getRenderRange(H,Z),oe=g.Q.relativeComplement(te,R),ue=g.Q.relativeComplement(R,te),E=this.getNextToLastElement(oe);if(O){const Qe=g.Q.intersect(R,te);for(let Ke=Qe.start;Ke<Qe.end;Ke++)this.updateItemInDOM(this.items[Ke],Ke)}for(const Qe of oe)for(let Ke=Qe.start;Ke<Qe.end;Ke++)this.insertItemInDOM(Ke,E);for(const Qe of ue)for(let Ke=Qe.start;Ke<Qe.end;Ke++)this.removeItemFromDOM(Ke);N!==void 0&&(this.rowsContainer.style.left=`-${N}px`),this.rowsContainer.style.top=`-${H}px`,this.horizontalScrolling&&G!==void 0&&(this.rowsContainer.style.width=`${Math.max(G,this.renderWidth)}px`),this.lastRenderTop=H,this.lastRenderHeight=Z}insertItemInDOM(R,H,Z){const N=this.items[R];N.row||(N.row=Z??this.cache.alloc(N.templateId));const G=this.accessibilityProvider.getRole(N.element)||"listitem";N.row.domNode.setAttribute("role",G);const O=this.accessibilityProvider.isChecked(N.element);if(typeof O=="boolean")N.row.domNode.setAttribute("aria-checked",String(!!O));else if(O){const ue=E=>N.row.domNode.setAttribute("aria-checked",String(!!E));ue(O.value),N.checkedDisposable=O.onDidChange(ue)}N.row.domNode.parentElement||(H?this.rowsContainer.insertBefore(N.row.domNode,H):this.rowsContainer.appendChild(N.row.domNode)),this.updateItemInDOM(N,R);const te=this.renderers.get(N.templateId);if(!te)throw new Error(`No renderer found for template id ${N.templateId}`);te?.renderElement(N.element,R,N.row.templateData,N.size);const oe=this.dnd.getDragURI(N.element);N.dragStartDisposable.dispose(),N.row.domNode.draggable=!!oe,oe&&(N.dragStartDisposable=(0,K.ko)(N.row.domNode,"dragstart",ue=>this.onDragStart(N.element,oe,ue))),this.horizontalScrolling&&(this.measureItemWidth(N),this.eventuallyUpdateScrollWidth())}measureItemWidth(R){if(!R.row||!R.row.domNode)return;R.row.domNode.style.width=b.isFirefox?"-moz-fit-content":"fit-content",R.width=(0,K.y6)(R.row.domNode);const H=window.getComputedStyle(R.row.domNode);H.paddingLeft&&(R.width+=parseFloat(H.paddingLeft)),H.paddingRight&&(R.width+=parseFloat(H.paddingRight)),R.row.domNode.style.width=""}updateItemInDOM(R,H){R.row.domNode.style.top=`${this.elementTop(H)}px`,this.setRowHeight&&(R.row.domNode.style.height=`${R.size}px`),this.setRowLineHeight&&(R.row.domNode.style.lineHeight=`${R.size}px`),R.row.domNode.setAttribute("data-index",`${H}`),R.row.domNode.setAttribute("data-last-element",H===this.length-1?"true":"false"),R.row.domNode.setAttribute("data-parity",H%2===0?"even":"odd"),R.row.domNode.setAttribute("aria-setsize",String(this.accessibilityProvider.getSetSize(R.element,H,this.length))),R.row.domNode.setAttribute("aria-posinset",String(this.accessibilityProvider.getPosInSet(R.element,H))),R.row.domNode.setAttribute("id",this.getElementDomId(H)),R.row.domNode.classList.toggle("drop-target",R.dropTarget)}removeItemFromDOM(R){const H=this.items[R];if(H.dragStartDisposable.dispose(),H.checkedDisposable.dispose(),H.row){const Z=this.renderers.get(H.templateId);Z&&Z.disposeElement&&Z.disposeElement(H.element,R,H.row.templateData,H.size),this.cache.release(H.row),H.row=null}this.horizontalScrolling&&this.eventuallyUpdateScrollWidth()}getScrollTop(){return this.scrollableElement.getScrollPosition().scrollTop}setScrollTop(R,H){this.scrollableElementUpdateDisposable&&(this.scrollableElementUpdateDisposable.dispose(),this.scrollableElementUpdateDisposable=null,this.scrollableElement.setScrollDimensions({scrollHeight:this.scrollHeight})),this.scrollableElement.setScrollPosition({scrollTop:R,reuseAnimation:H})}get scrollTop(){return this.getScrollTop()}set scrollTop(R){this.setScrollTop(R)}get scrollHeight(){return this._scrollHeight+(this.horizontalScrolling?10:0)+this.additionalScrollHeight}get onMouseClick(){return p.Jh.map(this.disposables.add(new $.f(this.domNode,"click")).event,R=>this.toMouseEvent(R),this.disposables)}get onMouseDblClick(){return p.Jh.map(this.disposables.add(new $.f(this.domNode,"dblclick")).event,R=>this.toMouseEvent(R),this.disposables)}get onMouseMiddleClick(){return p.Jh.filter(p.Jh.map(this.disposables.add(new $.f(this.domNode,"auxclick")).event,R=>this.toMouseEvent(R),this.disposables),R=>R.browserEvent.button===1,this.disposables)}get onMouseDown(){return p.Jh.map(this.disposables.add(new $.f(this.domNode,"mousedown")).event,R=>this.toMouseEvent(R),this.disposables)}get onMouseOver(){return p.Jh.map(this.disposables.add(new $.f(this.domNode,"mouseover")).event,R=>this.toMouseEvent(R),this.disposables)}get onContextMenu(){return p.Jh.any(p.Jh.map(this.disposables.add(new $.f(this.domNode,"contextmenu")).event,R=>this.toMouseEvent(R),this.disposables),p.Jh.map(this.disposables.add(new $.f(this.domNode,L.B.Contextmenu)).event,R=>this.toGestureEvent(R),this.disposables))}get onTouchStart(){return p.Jh.map(this.disposables.add(new $.f(this.domNode,"touchstart")).event,R=>this.toTouchEvent(R),this.disposables)}get onTap(){return p.Jh.map(this.disposables.add(new $.f(this.rowsContainer,L.B.Tap)).event,R=>this.toGestureEvent(R),this.disposables)}toMouseEvent(R){const H=this.getItemIndexFromEventTarget(R.target||null),Z=typeof H>"u"?void 0:this.items[H],N=Z&&Z.element;return{browserEvent:R,index:H,element:N}}toTouchEvent(R){const H=this.getItemIndexFromEventTarget(R.target||null),Z=typeof H>"u"?void 0:this.items[H],N=Z&&Z.element;return{browserEvent:R,index:H,element:N}}toGestureEvent(R){const H=this.getItemIndexFromEventTarget(R.initialTarget||null),Z=typeof H>"u"?void 0:this.items[H],N=Z&&Z.element;return{browserEvent:R,index:H,element:N}}toDragEvent(R){const H=this.getItemIndexFromEventTarget(R.target||null),Z=typeof H>"u"?void 0:this.items[H],N=Z&&Z.element;return{browserEvent:R,index:H,element:N}}onScroll(R){try{const H=this.getRenderRange(this.lastRenderTop,this.lastRenderHeight);this.render(H,R.scrollTop,R.height,R.scrollLeft,R.scrollWidth),this.supportDynamicHeights&&this._rerender(R.scrollTop,R.height,R.inSmoothScrolling)}catch(H){throw console.error("Got bad scroll event:",R),H}}onTouchChange(R){R.preventDefault(),R.stopPropagation(),this.scrollTop-=R.translationY}onDragStart(R,H,Z){var N,G;if(!Z.dataTransfer)return;const O=this.dnd.getDragElements(R);if(Z.dataTransfer.effectAllowed="copyMove",Z.dataTransfer.setData(o.t.TEXT,H),Z.dataTransfer.setDragImage){let te;this.dnd.getDragLabel&&(te=this.dnd.getDragLabel(O,Z)),typeof te>"u"&&(te=String(O.length));const oe=(0,K.$)(".monaco-drag-image");oe.textContent=te,document.body.appendChild(oe),Z.dataTransfer.setDragImage(oe,-10,-10),setTimeout(()=>document.body.removeChild(oe),0)}this.currentDragData=new A(O),o.M.CurrentDragAndDropData=new W(O),(G=(N=this.dnd).onDragStart)===null||G===void 0||G.call(N,this.currentDragData,Z)}onDragOver(R){var H;if(R.browserEvent.preventDefault(),this.onDragLeaveTimeout.dispose(),o.M.CurrentDragAndDropData&&o.M.CurrentDragAndDropData.getData()==="vscode-ui"||(this.setupDragAndDropScrollTopAnimation(R.browserEvent),!R.browserEvent.dataTransfer))return!1;if(!this.currentDragData)if(o.M.CurrentDragAndDropData)this.currentDragData=o.M.CurrentDragAndDropData;else{if(!R.browserEvent.dataTransfer.types)return!1;this.currentDragData=new Y}const Z=this.dnd.onDragOver(this.currentDragData,R.element,R.index,R.browserEvent);if(this.canDrop=typeof Z=="boolean"?Z:Z.accept,!this.canDrop)return this.currentDragFeedback=void 0,this.currentDragFeedbackDisposable.dispose(),!1;R.browserEvent.dataTransfer.dropEffect=typeof Z!="boolean"&&Z.effect===0?"copy":"move";let N;if(typeof Z!="boolean"&&Z.feedback?N=Z.feedback:typeof R.index>"u"?N=[-1]:N=[R.index],N=(0,P.dM)(N).filter(G=>G>=-1&&G<this.length).sort((G,O)=>G-O),N=N[0]===-1?[-1]:N,ne(this.currentDragFeedback,N))return!0;if(this.currentDragFeedback=N,this.currentDragFeedbackDisposable.dispose(),N[0]===-1)this.domNode.classList.add("drop-target"),this.rowsContainer.classList.add("drop-target"),this.currentDragFeedbackDisposable=(0,d.s)(()=>{this.domNode.classList.remove("drop-target"),this.rowsContainer.classList.remove("drop-target")});else{for(const G of N){const O=this.items[G];O.dropTarget=!0,(H=O.row)===null||H===void 0||H.domNode.classList.add("drop-target")}this.currentDragFeedbackDisposable=(0,d.s)(()=>{var G;for(const O of N){const te=this.items[O];te.dropTarget=!1,(G=te.row)===null||G===void 0||G.domNode.classList.remove("drop-target")}})}return!0}onDragLeave(R){var H,Z;this.onDragLeaveTimeout.dispose(),this.onDragLeaveTimeout=(0,B.EQ)(()=>this.clearDragOverFeedback(),100),this.currentDragData&&((Z=(H=this.dnd).onDragLeave)===null||Z===void 0||Z.call(H,this.currentDragData,R.element,R.index,R.browserEvent))}onDrop(R){if(!this.canDrop)return;const H=this.currentDragData;this.teardownDragAndDropScrollTopAnimation(),this.clearDragOverFeedback(),this.currentDragData=void 0,o.M.CurrentDragAndDropData=void 0,!(!H||!R.browserEvent.dataTransfer)&&(R.browserEvent.preventDefault(),H.update(R.browserEvent.dataTransfer),this.dnd.drop(H,R.element,R.index,R.browserEvent))}onDragEnd(R){var H,Z;this.canDrop=!1,this.teardownDragAndDropScrollTopAnimation(),this.clearDragOverFeedback(),this.currentDragData=void 0,o.M.CurrentDragAndDropData=void 0,(Z=(H=this.dnd).onDragEnd)===null||Z===void 0||Z.call(H,R)}clearDragOverFeedback(){this.currentDragFeedback=void 0,this.currentDragFeedbackDisposable.dispose(),this.currentDragFeedbackDisposable=d.jG.None}setupDragAndDropScrollTopAnimation(R){if(!this.dragOverAnimationDisposable){const H=(0,K.cL)(this.domNode).top;this.dragOverAnimationDisposable=(0,K.i0)(this.animateDragAndDropScrollTop.bind(this,H))}this.dragOverAnimationStopDisposable.dispose(),this.dragOverAnimationStopDisposable=(0,B.EQ)(()=>{this.dragOverAnimationDisposable&&(this.dragOverAnimationDisposable.dispose(),this.dragOverAnimationDisposable=void 0)},1e3),this.dragOverMouseY=R.pageY}animateDragAndDropScrollTop(R){if(this.dragOverMouseY===void 0)return;const H=this.dragOverMouseY-R,Z=this.renderHeight-35;H<35?this.scrollTop+=Math.max(-14,Math.floor(.3*(H-35))):H>Z&&(this.scrollTop+=Math.min(14,Math.floor(.3*(H-Z))))}teardownDragAndDropScrollTopAnimation(){this.dragOverAnimationStopDisposable.dispose(),this.dragOverAnimationDisposable&&(this.dragOverAnimationDisposable.dispose(),this.dragOverAnimationDisposable=void 0)}getItemIndexFromEventTarget(R){const H=this.scrollableElement.getDomNode();let Z=R;for(;Z instanceof HTMLElement&&Z!==this.rowsContainer&&H.contains(Z);){const N=Z.getAttribute("data-index");if(N){const G=Number(N);if(!isNaN(G))return G}Z=Z.parentElement}}getRenderRange(R,H){return{start:this.rangeMap.indexAt(R),end:this.rangeMap.indexAfter(R+H-1)}}_rerender(R,H,Z){const N=this.getRenderRange(R,H);let G,O;R===this.elementTop(N.start)?(G=N.start,O=0):N.end-N.start>1&&(G=N.start+1,O=this.elementTop(G)-R);let te=0;for(;;){const oe=this.getRenderRange(R,H);let ue=!1;for(let E=oe.start;E<oe.end;E++){const Qe=this.probeDynamicHeight(E);Qe!==0&&this.rangeMap.splice(E,1,[this.items[E]]),te+=Qe,ue=ue||Qe!==0}if(!ue){te!==0&&this.eventuallyUpdateScrollDimensions();const E=g.Q.relativeComplement(N,oe);for(const Ke of E)for(let Se=Ke.start;Se<Ke.end;Se++)this.items[Se].row&&this.removeItemFromDOM(Se);const Qe=g.Q.relativeComplement(oe,N);for(const Ke of Qe)for(let Se=Ke.start;Se<Ke.end;Se++){const Me=Se+1,ce=Me<this.items.length?this.items[Me].row:null,pe=ce?ce.domNode:null;this.insertItemInDOM(Se,pe)}for(let Ke=oe.start;Ke<oe.end;Ke++)this.items[Ke].row&&this.updateItemInDOM(this.items[Ke],Ke);if(typeof G=="number"){const Ke=this.scrollable.getFutureScrollPosition().scrollTop-R,Se=this.elementTop(G)-O+Ke;this.setScrollTop(Se,Z)}this._onDidChangeContentHeight.fire(this.contentHeight);return}}}probeDynamicHeight(R){var H,Z,N;const G=this.items[R];if(this.virtualDelegate.getDynamicHeight){const ue=this.virtualDelegate.getDynamicHeight(G.element);if(ue!==null){const E=G.size;return G.size=ue,G.lastDynamicHeightWidth=this.renderWidth,ue-E}}if(!G.hasDynamicHeight||G.lastDynamicHeightWidth===this.renderWidth||this.virtualDelegate.hasDynamicHeight&&!this.virtualDelegate.hasDynamicHeight(G.element))return 0;const O=G.size;if(!this.setRowHeight&&G.row){const ue=G.row.domNode.offsetHeight;return G.size=ue,G.lastDynamicHeightWidth=this.renderWidth,ue-O}const te=this.cache.alloc(G.templateId);te.domNode.style.height="",this.rowsContainer.appendChild(te.domNode);const oe=this.renderers.get(G.templateId);return oe&&(oe.renderElement(G.element,R,te.templateData,void 0),(H=oe.disposeElement)===null||H===void 0||H.call(oe,G.element,R,te.templateData,void 0)),G.size=te.domNode.offsetHeight,(N=(Z=this.virtualDelegate).setDynamicHeight)===null||N===void 0||N.call(Z,G.element,G.size),G.lastDynamicHeightWidth=this.renderWidth,this.rowsContainer.removeChild(te.domNode),this.cache.release(te),G.size-O}getNextToLastElement(R){const H=R[R.length-1];if(!H)return null;const Z=this.items[H.end];return!Z||!Z.row?null:Z.row.domNode}getElementDomId(R){return`${this.domId}_${R}`}dispose(){var R;if(this.items){for(const H of this.items)if(H.row){const Z=this.renderers.get(H.row.templateId);Z&&((R=Z.disposeElement)===null||R===void 0||R.call(Z,H.element,-1,H.row.templateData,void 0),Z.disposeTemplate(H.row.templateData))}this.items=[]}this.domNode&&this.domNode.parentNode&&this.domNode.parentNode.removeChild(this.domNode),(0,d.AS)(this.disposables)}}Q.InstanceCount=0,D([T.B],Q.prototype,"onMouseClick",null),D([T.B],Q.prototype,"onMouseDblClick",null),D([T.B],Q.prototype,"onMouseMiddleClick",null),D([T.B],Q.prototype,"onMouseDown",null),D([T.B],Q.prototype,"onMouseOver",null),D([T.B],Q.prototype,"onContextMenu",null),D([T.B],Q.prototype,"onTouchStart",null),D([T.B],Q.prototype,"onTap",null)},83312:(rt,ye,y)=>{y.d(ye,{d:()=>b});class b{constructor(K,$=[],L=!1){this.ctor=K,this.staticArguments=$,this.supportsDelayedInstantiation=L}}},83455:(rt,ye,y)=>{y.d(ye,{E$:()=>$,HP:()=>P,Ic:()=>T,U0:()=>K,Wn:()=>b,bg:()=>L,mS:()=>U,uK:()=>o,vn:()=>B});class b{constructor(){this.changeType=1}}class o{constructor(d,g,h,l,u){this.ownerId=d,this.lineNumber=g,this.column=h,this.options=l,this.order=u}static applyInjectedText(d,g){if(!g||g.length===0)return d;let h="",l=0;for(const u of g)h+=d.substring(l,u.column-1),l=u.column-1,h+=u.options.content;return h+=d.substring(l),h}static fromDecorations(d){const g=[];for(const h of d)h.options.before&&h.options.before.content.length>0&&g.push(new o(h.ownerId,h.range.startLineNumber,h.range.startColumn,h.options.before,0)),h.options.after&&h.options.after.content.length>0&&g.push(new o(h.ownerId,h.range.endLineNumber,h.range.endColumn,h.options.after,1));return g.sort((h,l)=>h.lineNumber===l.lineNumber?h.column===l.column?h.order-l.order:h.column-l.column:h.lineNumber-l.lineNumber),g}}class K{constructor(d,g,h){this.changeType=2,this.lineNumber=d,this.detail=g,this.injectedText=h}}class ${constructor(d,g){this.changeType=3,this.fromLineNumber=d,this.toLineNumber=g}}class L{constructor(d,g,h,l){this.changeType=4,this.injectedTexts=l,this.fromLineNumber=d,this.toLineNumber=g,this.detail=h}}class U{constructor(){this.changeType=5}}class P{constructor(d,g,h,l){this.changes=d,this.versionId=g,this.isUndoing=h,this.isRedoing=l,this.resultingSelection=null}containsEvent(d){for(let g=0,h=this.changes.length;g<h;g++)if(this.changes[g].changeType===d)return!0;return!1}static merge(d,g){const h=[].concat(d.changes).concat(g.changes),l=g.versionId,u=d.isUndoing||g.isUndoing,w=d.isRedoing||g.isRedoing;return new P(h,l,u,w)}}class B{constructor(d){this.changes=d}}class T{constructor(d,g){this.rawContentChangedEvent=d,this.contentChangedEvent=g}merge(d){const g=P.merge(this.rawContentChangedEvent,d.rawContentChangedEvent),h=T._mergeChangeEvents(this.contentChangedEvent,d.contentChangedEvent);return new T(g,h)}static _mergeChangeEvents(d,g){const h=[].concat(d.changes).concat(g.changes),l=g.eol,u=g.versionId,w=d.isUndoing||g.isUndoing,C=d.isRedoing||g.isRedoing,m=d.isFlush||g.isFlush;return{changes:h,eol:l,versionId:u,isUndoing:w,isRedoing:C,isFlush:m}}}},83616:(rt,ye,y)=>{y.d(ye,{L:()=>o});var b=y(82399);const o=(0,b.u1)("themeService")},84431:(rt,ye,y)=>{y.d(ye,{s:()=>B});var b=y(14333),o=y(30812),K=y(17589),$=y(10998),L=y(71386),U=y(4580);class P{constructor(h){this._element=h}get element(){return this._element}set textContent(h){this.disposed||h===this._textContent||(this._textContent=h,this._element.textContent=h)}set className(h){this.disposed||h===this._className||(this._className=h,this._element.className=h)}set empty(h){this.disposed||h===this._empty||(this._empty=h,this._element.style.marginLeft=h?"0":"")}dispose(){this.disposed=!0}}class B extends $.jG{constructor(h,l){super(),this.customHovers=new Map,this.domNode=this._register(new P(b.BC(h,b.$(".monaco-icon-label")))),this.labelContainer=b.BC(this.domNode.element,b.$(".monaco-icon-label-container"));const u=b.BC(this.labelContainer,b.$("span.monaco-icon-name-container"));this.descriptionContainer=this._register(new P(b.BC(this.labelContainer,b.$("span.monaco-icon-description-container")))),l?.supportHighlights||l?.supportIcons?this.nameNode=new d(u,!!l.supportIcons):this.nameNode=new T(u),l?.supportDescriptionHighlights?this.descriptionNodeFactory=()=>new o._(b.BC(this.descriptionContainer.element,b.$("span.label-description")),{supportIcons:!!l.supportIcons}):this.descriptionNodeFactory=()=>this._register(new P(b.BC(this.descriptionContainer.element,b.$("span.label-description")))),this.hoverDelegate=l?.hoverDelegate}get element(){return this.domNode.element}setLabel(h,l,u){const w=["monaco-icon-label"];u&&(u.extraClasses&&w.push(...u.extraClasses),u.italic&&w.push("italic"),u.strikethrough&&w.push("strikethrough")),this.domNode.className=w.join(" "),this.setupHover(u?.descriptionTitle?this.labelContainer:this.element,u?.title),this.nameNode.setLabel(h,u),(l||this.descriptionNode)&&(this.descriptionNode||(this.descriptionNode=this.descriptionNodeFactory()),this.descriptionNode instanceof o._?(this.descriptionNode.set(l||"",u?u.descriptionMatches:void 0),this.setupHover(this.descriptionNode.element,u?.descriptionTitle)):(this.descriptionNode.textContent=l||"",this.setupHover(this.descriptionNode.element,u?.descriptionTitle||""),this.descriptionNode.empty=!l))}setupHover(h,l){const u=this.customHovers.get(h);if(u&&(u.dispose(),this.customHovers.delete(h)),!l){h.removeAttribute("title");return}if(!this.hoverDelegate)(0,K.$)(h,l);else{const w=(0,K.f)(this.hoverDelegate,h,l);w&&this.customHovers.set(h,w)}}dispose(){super.dispose();for(const h of this.customHovers.values())h.dispose();this.customHovers.clear()}}class T{constructor(h){this.container=h,this.label=void 0,this.singleLabel=void 0}setLabel(h,l){if(!(this.label===h&&(0,L.aI)(this.options,l)))if(this.label=h,this.options=l,typeof h=="string")this.singleLabel||(this.container.innerText="",this.container.classList.remove("multiple"),this.singleLabel=b.BC(this.container,b.$("a.label-name",{id:l?.domId}))),this.singleLabel.textContent=h;else{this.container.innerText="",this.container.classList.add("multiple"),this.singleLabel=void 0;for(let u=0;u<h.length;u++){const w=h[u],C=l?.domId&&`${l?.domId}_${u}`;b.BC(this.container,b.$("a.label-name",{id:C,"data-icon-label-count":h.length,"data-icon-label-index":u,role:"treeitem"},w)),u<h.length-1&&b.BC(this.container,b.$("span.label-separator",void 0,l?.separator||"/"))}}}}function p(g,h,l){if(!l)return;let u=0;return g.map(w=>{const C={start:u,end:u+w.length},m=l.map(v=>U.Q.intersect(C,v)).filter(v=>!U.Q.isEmpty(v)).map(({start:v,end:k})=>({start:v-u,end:k-u}));return u=C.end+h.length,m})}class d{constructor(h,l){this.container=h,this.supportIcons=l,this.label=void 0,this.singleLabel=void 0}setLabel(h,l){if(!(this.label===h&&(0,L.aI)(this.options,l)))if(this.label=h,this.options=l,typeof h=="string")this.singleLabel||(this.container.innerText="",this.container.classList.remove("multiple"),this.singleLabel=new o._(b.BC(this.container,b.$("a.label-name",{id:l?.domId})),{supportIcons:this.supportIcons})),this.singleLabel.set(h,l?.matches,void 0,l?.labelEscapeNewLines);else{this.container.innerText="",this.container.classList.add("multiple"),this.singleLabel=void 0;const u=l?.separator||"/",w=p(h,u,l?.matches);for(let C=0;C<h.length;C++){const m=h[C],v=w?w[C]:void 0,k=l?.domId&&`${l?.domId}_${C}`,D=b.$("a.label-name",{id:k,"data-icon-label-count":h.length,"data-icon-label-index":C,role:"treeitem"});new o._(b.BC(this.container,D),{supportIcons:this.supportIcons}).set(m,v,void 0,l?.labelEscapeNewLines),C<h.length-1&&b.BC(D,b.$("span.label-separator",void 0,u))}}}}},84587:(rt,ye,y)=>{y.d(ye,{D:()=>o});var b=y(2106);const o=new class{constructor(){this._zoomLevel=0,this._onDidChangeZoomLevel=new b.vl,this.onDidChangeZoomLevel=this._onDidChangeZoomLevel.event}getZoomLevel(){return this._zoomLevel}setZoomLevel(K){K=Math.min(Math.max(-5,K),20),this._zoomLevel!==K&&(this._zoomLevel=K,this._onDidChangeZoomLevel.fire(this._zoomLevel))}}},84657:(rt,ye,y)=>{y.d(ye,{L:()=>o});var b=y(82399);const o=(0,b.u1)("workspaceTrustManagementService")},85003:(rt,ye,y)=>{y.d(ye,{Gn:()=>g,JJ:()=>U,vf:()=>d});var b=y(66476),o=y(12590),K=y(3765),$=y(27142),L=y(67167);const U=Object.freeze({id:"editor",order:5,type:"object",title:K.kg("editorConfigurationTitle","Editor"),scope:5}),P=Object.assign(Object.assign({},U),{properties:{"editor.tabSize":{type:"number",default:o.R.tabSize,minimum:1,markdownDescription:K.kg("tabSize","The number of spaces a tab is equal to. This setting is overridden based on the file contents when `#editor.detectIndentation#` is on.")},"editor.insertSpaces":{type:"boolean",default:o.R.insertSpaces,markdownDescription:K.kg("insertSpaces","Insert spaces when pressing `Tab`. This setting is overridden based on the file contents when `#editor.detectIndentation#` is on.")},"editor.detectIndentation":{type:"boolean",default:o.R.detectIndentation,markdownDescription:K.kg("detectIndentation","Controls whether `#editor.tabSize#` and `#editor.insertSpaces#` will be automatically detected when a file is opened based on the file contents.")},"editor.trimAutoWhitespace":{type:"boolean",default:o.R.trimAutoWhitespace,description:K.kg("trimAutoWhitespace","Remove trailing auto inserted whitespace.")},"editor.largeFileOptimizations":{type:"boolean",default:o.R.largeFileOptimizations,description:K.kg("largeFileOptimizations","Special handling for large files to disable certain memory intensive features.")},"editor.wordBasedSuggestions":{type:"boolean",default:!0,description:K.kg("wordBasedSuggestions","Controls whether completions should be computed based on words in the document.")},"editor.wordBasedSuggestionsMode":{enum:["currentDocument","matchingDocuments","allDocuments"],default:"matchingDocuments",enumDescriptions:[K.kg("wordBasedSuggestionsMode.currentDocument","Only suggest words from the active document."),K.kg("wordBasedSuggestionsMode.matchingDocuments","Suggest words from all open documents of the same language."),K.kg("wordBasedSuggestionsMode.allDocuments","Suggest words from all open documents.")],description:K.kg("wordBasedSuggestionsMode","Controls from which documents word based completions are computed.")},"editor.semanticHighlighting.enabled":{enum:[!0,!1,"configuredByTheme"],enumDescriptions:[K.kg("semanticHighlighting.true","Semantic highlighting enabled for all color themes."),K.kg("semanticHighlighting.false","Semantic highlighting disabled for all color themes."),K.kg("semanticHighlighting.configuredByTheme","Semantic highlighting is configured by the current color theme's `semanticHighlighting` setting.")],default:"configuredByTheme",description:K.kg("semanticHighlighting.enabled","Controls whether the semanticHighlighting is shown for the languages that support it.")},"editor.stablePeek":{type:"boolean",default:!1,markdownDescription:K.kg("stablePeek","Keep peek editors open even when double clicking their content or when hitting `Escape`.")},"editor.maxTokenizationLineLength":{type:"integer",default:2e4,description:K.kg("maxTokenizationLineLength","Lines above this length will not be tokenized for performance reasons")},"editor.language.brackets":{type:["array","null"],default:null,description:K.kg("schema.brackets","Defines the bracket symbols that increase or decrease the indentation."),items:{type:"array",items:[{type:"string",description:K.kg("schema.openBracket","The opening bracket character or string sequence.")},{type:"string",description:K.kg("schema.closeBracket","The closing bracket character or string sequence.")}]}},"editor.language.colorizedBracketPairs":{type:["array","null"],default:null,description:K.kg("schema.colorizedBracketPairs","Defines the bracket pairs that are colorized by their nesting level if bracket pair colorization is enabled."),items:{type:"array",items:[{type:"string",description:K.kg("schema.openBracket","The opening bracket character or string sequence.")},{type:"string",description:K.kg("schema.closeBracket","The closing bracket character or string sequence.")}]}},"diffEditor.maxComputationTime":{type:"number",default:5e3,description:K.kg("maxComputationTime","Timeout in milliseconds after which diff computation is cancelled. Use 0 for no timeout.")},"diffEditor.maxFileSize":{type:"number",default:50,description:K.kg("maxFileSize","Maximum file size in MB for which to compute diffs. Use 0 for no limit.")},"diffEditor.renderSideBySide":{type:"boolean",default:!0,description:K.kg("sideBySide","Controls whether the diff editor shows the diff side by side or inline.")},"diffEditor.renderMarginRevertIcon":{type:"boolean",default:!0,description:K.kg("renderMarginRevertIcon","When enabled, the diff editor shows arrows in its glyph margin to revert changes.")},"diffEditor.ignoreTrimWhitespace":{type:"boolean",default:!0,description:K.kg("ignoreTrimWhitespace","When enabled, the diff editor ignores changes in leading or trailing whitespace.")},"diffEditor.renderIndicators":{type:"boolean",default:!0,description:K.kg("renderIndicators","Controls whether the diff editor shows +/- indicators for added/removed changes.")},"diffEditor.codeLens":{type:"boolean",default:!1,description:K.kg("codeLens","Controls whether the editor shows CodeLens.")},"diffEditor.wordWrap":{type:"string",enum:["off","on","inherit"],default:"inherit",markdownEnumDescriptions:[K.kg("wordWrap.off","Lines will never wrap."),K.kg("wordWrap.on","Lines will wrap at the viewport width."),K.kg("wordWrap.inherit","Lines will wrap according to the `#editor.wordWrap#` setting.")]}}});function B(l){return typeof l.type<"u"||typeof l.anyOf<"u"}for(const l of b.BE){const u=l.schema;if(typeof u<"u")if(B(u))P.properties[`editor.${l.name}`]=u;else for(const w in u)Object.hasOwnProperty.call(u,w)&&(P.properties[w]=u[w])}let T=null;function p(){return T===null&&(T=Object.create(null),Object.keys(P.properties).forEach(l=>{T[l]=!0})),T}function d(l){return p()[`editor.${l}`]||!1}function g(l){return p()[`diffEditor.${l}`]||!1}L.O.as($.Fd.Configuration).registerConfiguration(P)},85702:(rt,ye,y)=>{y.d(ye,{Z:()=>B});var b=y(16844),o=y(64651),K=y(34883),$=y(60756),L=y(33206);class U{constructor(p){this.map=p,this.hasRegExp=!1,this._regExpGlobal=null}static createFromLanguage(p,d){function g(l){return d.getKey(`${l.languageId}:::${l.bracketText}`)}const h=new Map;for(const l of p.bracketsNew.openingBrackets){const u=(0,K.qe)(0,l.bracketText.length),w=g(l),C=$.gV.getEmpty().add(w,$.FD);h.set(l.bracketText,new L.ou(u,1,w,C,o.rh.create(u,l,C)))}for(const l of p.bracketsNew.closingBrackets){const u=(0,K.qe)(0,l.bracketText.length);let w=$.gV.getEmpty();const C=l.getClosedBrackets();for(const m of C)w=w.add(g(m),$.FD);h.set(l.bracketText,new L.ou(u,2,g(C[0]),w,o.rh.create(u,l,w)))}return new U(h)}getRegExpStr(){if(this.isEmpty)return null;{const p=[...this.map.keys()];return p.sort(),p.reverse(),p.map(d=>P(d)).join("|")}}get regExpGlobal(){if(!this.hasRegExp){const p=this.getRegExpStr();this._regExpGlobal=p?new RegExp(p,"gi"):null,this.hasRegExp=!0}return this._regExpGlobal}getToken(p){return this.map.get(p.toLowerCase())}findClosingTokenText(p){for(const[d,g]of this.map)if(g.kind===2&&g.bracketIds.intersects(p))return d}get isEmpty(){return this.map.size===0}}function P(T){let p=(0,b.bm)(T);return/^[\w ]+/.test(T)&&(p=`\\b${p}`),/[\w ]+$/.test(T)&&(p=`${p}\\b`),p}class B{constructor(p,d){this.denseKeyProvider=p,this.getLanguageConfiguration=d,this.languageIdToBracketTokens=new Map}didLanguageChange(p){return this.languageIdToBracketTokens.has(p)}getSingleLanguageBracketTokens(p){let d=this.languageIdToBracketTokens.get(p);return d||(d=U.createFromLanguage(this.getLanguageConfiguration(p),this.denseKeyProvider),this.languageIdToBracketTokens.set(p,d)),d}}},85753:(rt,ye,y)=>{y.d(ye,{Mo:()=>B,ad:()=>K,gD:()=>P,iB:()=>L,kW:()=>$,pG:()=>o});var b=y(82399);const o=(0,b.u1)("configurationService");function K(T,p){const d=Object.create(null);for(const g in T)$(d,g,T[g],p);return d}function $(T,p,d,g){const h=p.split("."),l=h.pop();let u=T;for(let w=0;w<h.length;w++){const C=h[w];let m=u[C];switch(typeof m){case"undefined":m=u[C]=Object.create(null);break;case"object":break;default:g(`Ignoring ${p} as ${h.slice(0,w+1).join(".")} is ${JSON.stringify(m)}`);return}u=m}if(typeof u=="object"&&u!==null)try{u[l]=d}catch{g(`Ignoring ${p} as ${h.join(".")} is ${JSON.stringify(u)}`)}else g(`Ignoring ${p} as ${h.join(".")} is ${JSON.stringify(u)}`)}function L(T,p){const d=p.split(".");U(T,d)}function U(T,p){const d=p.shift();if(p.length===0){delete T[d];return}if(Object.keys(T).indexOf(d)!==-1){const g=T[d];typeof g=="object"&&!Array.isArray(g)&&(U(g,p),Object.keys(g).length===0&&delete T[d])}}function P(T,p,d){function g(u,w){let C=u;for(const m of w){if(typeof C!="object"||C===null)return;C=C[m]}return C}const h=p.split("."),l=g(T,h);return typeof l>"u"?d:l}function B(T){return T.replace(/[\[\]]/g,"")}},86843:(rt,ye,y)=>{y.d(ye,{B:()=>d,m:()=>k});var b=y(14333),o=y(34061),K=y(30474),$=y(65958),L=y(88846),U=y(2106),P=y(10998),B=y(63339),T=function(D,x,A,W){var Y=arguments.length,ne=Y<3?x:W===null?W=Object.getOwnPropertyDescriptor(x,A):W,j;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")ne=Reflect.decorate(D,x,A,W);else for(var Q=D.length-1;Q>=0;Q--)(j=D[Q])&&(ne=(Y<3?j(ne):Y>3?j(x,A,ne):j(x,A))||ne);return Y>3&&ne&&Object.defineProperty(x,A,ne),ne};const p=!1;var d;(function(D){D.North="north",D.South="south",D.East="east",D.West="west"})(d||(d={}));let g=4;const h=new U.vl;let l=300;const u=new U.vl;class w{constructor(){this.disposables=new P.Cm}get onPointerMove(){return this.disposables.add(new o.f(window,"mousemove")).event}get onPointerUp(){return this.disposables.add(new o.f(window,"mouseup")).event}dispose(){this.disposables.dispose()}}T([L.B],w.prototype,"onPointerMove",null),T([L.B],w.prototype,"onPointerUp",null);class C{constructor(x){this.el=x,this.disposables=new P.Cm}get onPointerMove(){return this.disposables.add(new o.f(this.el,K.B.Change)).event}get onPointerUp(){return this.disposables.add(new o.f(this.el,K.B.End)).event}dispose(){this.disposables.dispose()}}T([L.B],C.prototype,"onPointerMove",null),T([L.B],C.prototype,"onPointerUp",null);class m{constructor(x){this.factory=x}get onPointerMove(){return this.factory.onPointerMove}get onPointerUp(){return this.factory.onPointerUp}dispose(){}}T([L.B],m.prototype,"onPointerMove",null),T([L.B],m.prototype,"onPointerUp",null);const v="pointer-events-disabled";class k extends P.jG{constructor(x,A,W){super(),this.hoverDelay=l,this.hoverDelayer=this._register(new $.ve(this.hoverDelay)),this._state=3,this.onDidEnablementChange=this._register(new U.vl),this._onDidStart=this._register(new U.vl),this._onDidChange=this._register(new U.vl),this._onDidReset=this._register(new U.vl),this._onDidEnd=this._register(new U.vl),this.orthogonalStartSashDisposables=this._register(new P.Cm),this.orthogonalStartDragHandleDisposables=this._register(new P.Cm),this.orthogonalEndSashDisposables=this._register(new P.Cm),this.orthogonalEndDragHandleDisposables=this._register(new P.Cm),this.onDidStart=this._onDidStart.event,this.onDidChange=this._onDidChange.event,this.onDidReset=this._onDidReset.event,this.onDidEnd=this._onDidEnd.event,this.linkedSash=void 0,this.el=(0,b.BC)(x,(0,b.$)(".monaco-sash")),W.orthogonalEdge&&this.el.classList.add(`orthogonal-edge-${W.orthogonalEdge}`),B.zx&&this.el.classList.add("mac");const Y=this._register(new o.f(this.el,"mousedown")).event;this._register(Y(Z=>this.onPointerStart(Z,new w),this));const ne=this._register(new o.f(this.el,"dblclick")).event;this._register(ne(this.onPointerDoublePress,this));const j=this._register(new o.f(this.el,"mouseenter")).event;this._register(j(()=>k.onMouseEnter(this)));const Q=this._register(new o.f(this.el,"mouseleave")).event;this._register(Q(()=>k.onMouseLeave(this))),this._register(K.q.addTarget(this.el));const X=U.Jh.map(this._register(new o.f(this.el,K.B.Start)).event,Z=>{var N;return Object.assign(Object.assign({},Z),{target:(N=Z.initialTarget)!==null&&N!==void 0?N:null})});this._register(X(Z=>this.onPointerStart(Z,new C(this.el)),this));const R=this._register(new o.f(this.el,K.B.Tap)).event,H=U.Jh.map(U.Jh.filter(U.Jh.debounce(R,(Z,N)=>{var G;return{event:N,count:((G=Z?.count)!==null&&G!==void 0?G:0)+1}},250),({count:Z})=>Z===2),({event:Z})=>{var N;return Object.assign(Object.assign({},Z),{target:(N=Z.initialTarget)!==null&&N!==void 0?N:null})});this._register(H(this.onPointerDoublePress,this)),typeof W.size=="number"?(this.size=W.size,W.orientation===0?this.el.style.width=`${this.size}px`:this.el.style.height=`${this.size}px`):(this.size=g,this._register(h.event(Z=>{this.size=Z,this.layout()}))),this._register(u.event(Z=>this.hoverDelay=Z)),this.layoutProvider=A,this.orthogonalStartSash=W.orthogonalStartSash,this.orthogonalEndSash=W.orthogonalEndSash,this.orientation=W.orientation||0,this.orientation===1?(this.el.classList.add("horizontal"),this.el.classList.remove("vertical")):(this.el.classList.remove("horizontal"),this.el.classList.add("vertical")),this.el.classList.toggle("debug",p),this.layout()}get state(){return this._state}get orthogonalStartSash(){return this._orthogonalStartSash}get orthogonalEndSash(){return this._orthogonalEndSash}set state(x){this._state!==x&&(this.el.classList.toggle("disabled",x===0),this.el.classList.toggle("minimum",x===1),this.el.classList.toggle("maximum",x===2),this._state=x,this.onDidEnablementChange.fire(x))}set orthogonalStartSash(x){if(this.orthogonalStartDragHandleDisposables.clear(),this.orthogonalStartSashDisposables.clear(),x){const A=W=>{this.orthogonalStartDragHandleDisposables.clear(),W!==0&&(this._orthogonalStartDragHandle=(0,b.BC)(this.el,(0,b.$)(".orthogonal-drag-handle.start")),this.orthogonalStartDragHandleDisposables.add((0,P.s)(()=>this._orthogonalStartDragHandle.remove())),this.orthogonalStartDragHandleDisposables.add(new o.f(this._orthogonalStartDragHandle,"mouseenter")).event(()=>k.onMouseEnter(x),void 0,this.orthogonalStartDragHandleDisposables),this.orthogonalStartDragHandleDisposables.add(new o.f(this._orthogonalStartDragHandle,"mouseleave")).event(()=>k.onMouseLeave(x),void 0,this.orthogonalStartDragHandleDisposables))};this.orthogonalStartSashDisposables.add(x.onDidEnablementChange.event(A,this)),A(x.state)}this._orthogonalStartSash=x}set orthogonalEndSash(x){if(this.orthogonalEndDragHandleDisposables.clear(),this.orthogonalEndSashDisposables.clear(),x){const A=W=>{this.orthogonalEndDragHandleDisposables.clear(),W!==0&&(this._orthogonalEndDragHandle=(0,b.BC)(this.el,(0,b.$)(".orthogonal-drag-handle.end")),this.orthogonalEndDragHandleDisposables.add((0,P.s)(()=>this._orthogonalEndDragHandle.remove())),this.orthogonalEndDragHandleDisposables.add(new o.f(this._orthogonalEndDragHandle,"mouseenter")).event(()=>k.onMouseEnter(x),void 0,this.orthogonalEndDragHandleDisposables),this.orthogonalEndDragHandleDisposables.add(new o.f(this._orthogonalEndDragHandle,"mouseleave")).event(()=>k.onMouseLeave(x),void 0,this.orthogonalEndDragHandleDisposables))};this.orthogonalEndSashDisposables.add(x.onDidEnablementChange.event(A,this)),A(x.state)}this._orthogonalEndSash=x}onPointerStart(x,A){b.fs.stop(x);let W=!1;if(!x.__orthogonalSashEvent){const O=this.getOrthogonalSash(x);O&&(W=!0,x.__orthogonalSashEvent=!0,O.onPointerStart(x,new m(A)))}if(this.linkedSash&&!x.__linkedSashEvent&&(x.__linkedSashEvent=!0,this.linkedSash.onPointerStart(x,new m(A))),!this.state)return;const Y=(0,b.yB)("iframe");for(const O of Y)O.classList.add(v);const ne=x.pageX,j=x.pageY,Q=x.altKey,X={startX:ne,currentX:ne,startY:j,currentY:j,altKey:Q};this.el.classList.add("active"),this._onDidStart.fire(X);const R=(0,b.li)(this.el),H=()=>{let O="";W?O="all-scroll":this.orientation===1?this.state===1?O="s-resize":this.state===2?O="n-resize":O=B.zx?"row-resize":"ns-resize":this.state===1?O="e-resize":this.state===2?O="w-resize":O=B.zx?"col-resize":"ew-resize",R.textContent=`* { cursor: ${O} !important; }`},Z=new P.Cm;H(),W||this.onDidEnablementChange.event(H,null,Z);const N=O=>{b.fs.stop(O,!1);const te={startX:ne,currentX:O.pageX,startY:j,currentY:O.pageY,altKey:Q};this._onDidChange.fire(te)},G=O=>{b.fs.stop(O,!1),this.el.removeChild(R),this.el.classList.remove("active"),this._onDidEnd.fire(),Z.dispose();for(const te of Y)te.classList.remove(v)};A.onPointerMove(N,null,Z),A.onPointerUp(G,null,Z),Z.add(A)}onPointerDoublePress(x){const A=this.getOrthogonalSash(x);A&&A._onDidReset.fire(),this.linkedSash&&this.linkedSash._onDidReset.fire(),this._onDidReset.fire()}static onMouseEnter(x,A=!1){x.el.classList.contains("active")?(x.hoverDelayer.cancel(),x.el.classList.add("hover")):x.hoverDelayer.trigger(()=>x.el.classList.add("hover"),x.hoverDelay).then(void 0,()=>{}),!A&&x.linkedSash&&k.onMouseEnter(x.linkedSash,!0)}static onMouseLeave(x,A=!1){x.hoverDelayer.cancel(),x.el.classList.remove("hover"),!A&&x.linkedSash&&k.onMouseLeave(x.linkedSash,!0)}clearSashHoverState(){k.onMouseLeave(this)}layout(){if(this.orientation===0){const x=this.layoutProvider;this.el.style.left=x.getVerticalSashLeft(this)-this.size/2+"px",x.getVerticalSashTop&&(this.el.style.top=x.getVerticalSashTop(this)+"px"),x.getVerticalSashHeight&&(this.el.style.height=x.getVerticalSashHeight(this)+"px")}else{const x=this.layoutProvider;this.el.style.top=x.getHorizontalSashTop(this)-this.size/2+"px",x.getHorizontalSashLeft&&(this.el.style.left=x.getHorizontalSashLeft(this)+"px"),x.getHorizontalSashWidth&&(this.el.style.width=x.getHorizontalSashWidth(this)+"px")}}getOrthogonalSash(x){if(!(!x.target||!(x.target instanceof HTMLElement))&&x.target.classList.contains("orthogonal-drag-handle"))return x.target.classList.contains("start")?this.orthogonalStartSash:this.orthogonalEndSash}dispose(){super.dispose(),this.el.remove()}}},87110:(rt,ye,y)=>{y.d(ye,{ok:()=>b});function b(o,K){if(!o)throw new Error(K?`Assertion failed (${K})`:"Assertion Failed")}},87301:(rt,ye,y)=>{y.d(ye,{T:()=>o});var b=y(82399);const o=(0,b.u1)("codeEditorService")},87594:(rt,ye,y)=>{y.d(ye,{Z:()=>p});var b=y(55893),o=y(68387),K=y(39619),$=y(63339);function L(d){if(d.charCode){const h=String.fromCharCode(d.charCode).toUpperCase();return o.YM.fromString(h)}const g=d.keyCode;if(g===3)return 7;if(b.isFirefox){if(g===59)return 80;if(g===107)return 81;if(g===109)return 83;if($.zx&&g===224)return 57}else if(b.isWebKit){if(g===91)return 57;if($.zx&&g===93)return 57;if(!$.zx&&g===92)return 57}return o.uw[g]||0}const U=$.zx?256:2048,P=512,B=1024,T=$.zx?2048:256;class p{constructor(g){this._standardKeyboardEventBrand=!0;const h=g;this.browserEvent=h,this.target=h.target,this.ctrlKey=h.ctrlKey,this.shiftKey=h.shiftKey,this.altKey=h.altKey,this.metaKey=h.metaKey,this.keyCode=L(h),this.code=h.code,this.ctrlKey=this.ctrlKey||this.keyCode===5,this.altKey=this.altKey||this.keyCode===6,this.shiftKey=this.shiftKey||this.keyCode===4,this.metaKey=this.metaKey||this.keyCode===57,this._asKeybinding=this._computeKeybinding(),this._asRuntimeKeybinding=this._computeRuntimeKeybinding()}preventDefault(){this.browserEvent&&this.browserEvent.preventDefault&&this.browserEvent.preventDefault()}stopPropagation(){this.browserEvent&&this.browserEvent.stopPropagation&&this.browserEvent.stopPropagation()}toKeybinding(){return this._asRuntimeKeybinding}equals(g){return this._asKeybinding===g}_computeKeybinding(){let g=0;this.keyCode!==5&&this.keyCode!==4&&this.keyCode!==6&&this.keyCode!==57&&(g=this.keyCode);let h=0;return this.ctrlKey&&(h|=U),this.altKey&&(h|=P),this.shiftKey&&(h|=B),this.metaKey&&(h|=T),h|=g,h}_computeRuntimeKeybinding(){let g=0;return this.keyCode!==5&&this.keyCode!==4&&this.keyCode!==6&&this.keyCode!==57&&(g=this.keyCode),new K.h$(this.ctrlKey,this.shiftKey,this.altKey,this.metaKey,g)}}},88213:(rt,ye,y)=>{y.d(ye,{S5:()=>o,n:()=>$,yk:()=>K});var b=y(14333);function o(p,d={}){const g=$(d);return g.textContent=p,g}function K(p,d={}){const g=$(d);return U(g,P(p,!!d.renderCodeSegments),d.actionHandler,d.renderCodeSegments),g}function $(p){const d=p.inline?"span":"div",g=document.createElement(d);return p.className&&(g.className=p.className),g}class L{constructor(d){this.source=d,this.index=0}eos(){return this.index>=this.source.length}next(){const d=this.peek();return this.advance(),d}peek(){return this.source[this.index]}advance(){this.index++}}function U(p,d,g,h){let l;if(d.type===2)l=document.createTextNode(d.content||"");else if(d.type===3)l=document.createElement("b");else if(d.type===4)l=document.createElement("i");else if(d.type===7&&h)l=document.createElement("code");else if(d.type===5&&g){const u=document.createElement("a");g.disposables.add(b.b2(u,"click",w=>{g.callback(String(d.index),w)})),l=u}else d.type===8?l=document.createElement("br"):d.type===1&&(l=p);l&&p!==l&&p.appendChild(l),l&&Array.isArray(d.children)&&d.children.forEach(u=>{U(l,u,g,h)})}function P(p,d){const g={type:1,children:[]};let h=0,l=g;const u=[],w=new L(p);for(;!w.eos();){let C=w.next();const m=C==="\\"&&T(w.peek(),d)!==0;if(m&&(C=w.next()),!m&&B(C,d)&&C===w.peek()){w.advance(),l.type===2&&(l=u.pop());const v=T(C,d);if(l.type===v||l.type===5&&v===6)l=u.pop();else{const k={type:v,children:[]};v===5&&(k.index=h,h++),l.children.push(k),u.push(l),l=k}}else if(C===` `)l.type===2&&(l=u.pop()),l.children.push({type:8});else if(l.type!==2){const v={type:2,content:C};l.children.push(v),u.push(l),l=v}else l.content+=C}return l.type===2&&(l=u.pop()),u.length,g}function B(p,d){return T(p,d)!==0}function T(p,d){switch(p){case"*":return 3;case"_":return 4;case"[":return 5;case"]":return 6;case"`":return d?7:0;default:return 0}}},88846:(rt,ye,y)=>{y.d(ye,{B:()=>b});function b(o,K,$){let L=null,U=null;if(typeof $.value=="function"?(L="value",U=$.value,U.length!==0&&console.warn("Memoize should only be used in functions with zero parameters")):typeof $.get=="function"&&(L="get",U=$.get),!U)throw new Error("not supported");const P=`$memoize$${K}`;$[L]=function(...B){return this.hasOwnProperty(P)||Object.defineProperty(this,P,{configurable:!1,enumerable:!1,writable:!1,value:U.apply(this,B)}),this[P]}}},89044:(rt,ye,y)=>{y.d(ye,{Fd:()=>g,Gy:()=>P,L0:()=>p,Pz:()=>d,Yf:()=>T,lR:()=>w,zy:()=>u});var b=y(26048),o=y(2106),K=y(10998),$=y(82399),L=y(67167),U=y(89563);const P=(0,$.u1)("themeService");var B;(function(C){function m(v){return v&&typeof v=="object"&&typeof v.id=="string"}C.isThemeColor=m})(B||(B={}));function T(C){return{id:C}}var p;(function(C){function m(ne){return ne&&typeof ne=="object"&&typeof ne.id=="string"&&(typeof ne.color>"u"||B.isThemeColor(ne.color))}C.isThemeIcon=m;const v=new RegExp(`^\\$\\((${b.j3.iconNameExpression}(?:${b.j3.iconModifierExpression})?)\\)$`);function k(ne){const j=v.exec(ne);if(!j)return;const[,Q]=j;return{id:Q}}C.fromString=k;function D(ne){return{id:ne}}C.fromId=D;function x(ne,j){let Q=ne.id;const X=Q.lastIndexOf("~");return X!==-1&&(Q=Q.substring(0,X)),j&&(Q=`${Q}~${j}`),{id:Q}}C.modify=x;function A(ne){const j=ne.id.lastIndexOf("~");if(j!==-1)return ne.id.substring(j+1)}C.getModifier=A;function W(ne,j){var Q,X;return ne.id===j.id&&((Q=ne.color)===null||Q===void 0?void 0:Q.id)===((X=j.color)===null||X===void 0?void 0:X.id)}C.isEqual=W;function Y(ne,j){return{id:ne.id,color:j?T(j):void 0}}C.asThemeIcon=Y,C.asClassNameArray=b.j3.asClassNameArray,C.asClassName=b.j3.asClassName,C.asCSSSelector=b.j3.asCSSSelector})(p||(p={}));function d(C){switch(C){case U.zM.DARK:return"vs-dark";case U.zM.HIGH_CONTRAST_DARK:return"hc-black";case U.zM.HIGH_CONTRAST_LIGHT:return"hc-light";default:return"vs"}}const g={ThemingContribution:"base.contributions.theming"};class h{constructor(){this.themingParticipants=[],this.themingParticipants=[],this.onThemingParticipantAddedEmitter=new o.vl}onColorThemeChange(m){return this.themingParticipants.push(m),this.onThemingParticipantAddedEmitter.fire(m),(0,K.s)(()=>{const v=this.themingParticipants.indexOf(m);this.themingParticipants.splice(v,1)})}getThemingParticipants(){return this.themingParticipants}}const l=new h;L.O.add(g.ThemingContribution,l);function u(C){return l.onColorThemeChange(C)}class w extends K.jG{constructor(m){super(),this.themeService=m,this.theme=m.getColorTheme(),this._register(this.themeService.onDidColorThemeChange(v=>this.onThemeChange(v)))}onThemeChange(m){this.theme=m,this.updateStyles()}updateStyles(){}}},89563:(rt,ye,y)=>{y.d(ye,{Bb:()=>o,HD:()=>K,zM:()=>b});var b;(function($){$.DARK="dark",$.LIGHT="light",$.HIGH_CONTRAST_DARK="hcDark",$.HIGH_CONTRAST_LIGHT="hcLight"})(b||(b={}));function o($){return $===b.HIGH_CONTRAST_DARK||$===b.HIGH_CONTRAST_LIGHT}function K($){return $===b.DARK||$===b.HIGH_CONTRAST_DARK}},89673:(rt,ye,y)=>{y.d(ye,{c:()=>B,z:()=>P});var b=y(16844),o=y(29895),K=y(97666),$=y(82862),L=y(15365),U=y(50442);class P{static _createWord(d,g,h,l,u){return{start:l,end:u,wordType:g,nextCharClass:h}}static _findPreviousWordOnLine(d,g,h){const l=g.getLineContent(h.lineNumber);return this._doFindPreviousWordOnLine(l,d,h)}static _doFindPreviousWordOnLine(d,g,h){let l=0;for(let u=h.column-2;u>=0;u--){const w=d.charCodeAt(u),C=g.get(w);if(C===0){if(l===2)return this._createWord(d,l,C,u+1,this._findEndOfWord(d,g,l,u+1));l=1}else if(C===2){if(l===1)return this._createWord(d,l,C,u+1,this._findEndOfWord(d,g,l,u+1));l=2}else if(C===1&&l!==0)return this._createWord(d,l,C,u+1,this._findEndOfWord(d,g,l,u+1))}return l!==0?this._createWord(d,l,1,0,this._findEndOfWord(d,g,l,0)):null}static _findEndOfWord(d,g,h,l){const u=d.length;for(let w=l;w<u;w++){const C=d.charCodeAt(w),m=g.get(C);if(m===1||h===1&&m===2||h===2&&m===0)return w}return u}static _findNextWordOnLine(d,g,h){const l=g.getLineContent(h.lineNumber);return this._doFindNextWordOnLine(l,d,h)}static _doFindNextWordOnLine(d,g,h){let l=0;const u=d.length;for(let w=h.column-1;w<u;w++){const C=d.charCodeAt(w),m=g.get(C);if(m===0){if(l===2)return this._createWord(d,l,m,this._findStartOfWord(d,g,l,w-1),w);l=1}else if(m===2){if(l===1)return this._createWord(d,l,m,this._findStartOfWord(d,g,l,w-1),w);l=2}else if(m===1&&l!==0)return this._createWord(d,l,m,this._findStartOfWord(d,g,l,w-1),w)}return l!==0?this._createWord(d,l,1,this._findStartOfWord(d,g,l,u-1),u):null}static _findStartOfWord(d,g,h,l){for(let u=l;u>=0;u--){const w=d.charCodeAt(u),C=g.get(w);if(C===1||h===1&&C===2||h===2&&C===0)return u+1}return 0}static moveWordLeft(d,g,h,l){let u=h.lineNumber,w=h.column;w===1&&u>1&&(u=u-1,w=g.getLineMaxColumn(u));let C=P._findPreviousWordOnLine(d,g,new L.y(u,w));if(l===0)return new L.y(u,C?C.start+1:1);if(l===1)return C&&C.wordType===2&&C.end-C.start===1&&C.nextCharClass===0&&(C=P._findPreviousWordOnLine(d,g,new L.y(u,C.start+1))),new L.y(u,C?C.start+1:1);if(l===3){for(;C&&C.wordType===2;)C=P._findPreviousWordOnLine(d,g,new L.y(u,C.start+1));return new L.y(u,C?C.start+1:1)}return C&&w<=C.end+1&&(C=P._findPreviousWordOnLine(d,g,new L.y(u,C.start+1))),new L.y(u,C?C.end+1:1)}static _moveWordPartLeft(d,g){const h=g.lineNumber,l=d.getLineMaxColumn(h);if(g.column===1)return h>1?new L.y(h-1,d.getLineMaxColumn(h-1)):g;const u=d.getLineContent(h);for(let w=g.column-1;w>1;w--){const C=u.charCodeAt(w-2),m=u.charCodeAt(w-1);if(C===95&&m!==95)return new L.y(h,w);if((b.Lv(C)||b.DB(C))&&b.Wv(m))return new L.y(h,w);if(b.Wv(C)&&b.Wv(m)&&w+1<l){const v=u.charCodeAt(w);if(b.Lv(v)||b.DB(v))return new L.y(h,w)}}return new L.y(h,1)}static moveWordRight(d,g,h,l){let u=h.lineNumber,w=h.column,C=!1;w===g.getLineMaxColumn(u)&&u<g.getLineCount()&&(C=!0,u=u+1,w=1);let m=P._findNextWordOnLine(d,g,new L.y(u,w));if(l===2)m&&m.wordType===2&&m.end-m.start===1&&m.nextCharClass===0&&(m=P._findNextWordOnLine(d,g,new L.y(u,m.end+1))),m?w=m.end+1:w=g.getLineMaxColumn(u);else if(l===3){for(C&&(w=0);m&&(m.wordType===2||m.start+1<=w);)m=P._findNextWordOnLine(d,g,new L.y(u,m.end+1));m?w=m.start+1:w=g.getLineMaxColumn(u)}else m&&!C&&w>=m.start+1&&(m=P._findNextWordOnLine(d,g,new L.y(u,m.end+1))),m?w=m.start+1:w=g.getLineMaxColumn(u);return new L.y(u,w)}static _moveWordPartRight(d,g){const h=g.lineNumber,l=d.getLineMaxColumn(h);if(g.column===l)return h<d.getLineCount()?new L.y(h+1,1):g;const u=d.getLineContent(h);for(let w=g.column+1;w<l;w++){const C=u.charCodeAt(w-2),m=u.charCodeAt(w-1);if(C!==95&&m===95)return new L.y(h,w);if((b.Lv(C)||b.DB(C))&&b.Wv(m))return new L.y(h,w);if(b.Wv(C)&&b.Wv(m)&&w+1<l){const v=u.charCodeAt(w);if(b.Lv(v)||b.DB(v))return new L.y(h,w)}}return new L.y(h,l)}static _deleteWordLeftWhitespace(d,g){const h=d.getLineContent(g.lineNumber),l=g.column-2,u=b.lT(h,l);return u+1<l?new U.Q(g.lineNumber,u+2,g.lineNumber,g.column):null}static deleteWordLeft(d,g){const h=d.wordSeparators,l=d.model,u=d.selection,w=d.whitespaceHeuristics;if(!u.isEmpty())return u;if(K.g.isAutoClosingPairDelete(d.autoClosingDelete,d.autoClosingBrackets,d.autoClosingQuotes,d.autoClosingPairs.autoClosingPairsOpenByEnd,d.model,[d.selection],d.autoClosedCharacters)){const D=d.selection.getPosition();return new U.Q(D.lineNumber,D.column-1,D.lineNumber,D.column+1)}const C=new L.y(u.positionLineNumber,u.positionColumn);let m=C.lineNumber,v=C.column;if(m===1&&v===1)return null;if(w){const D=this._deleteWordLeftWhitespace(l,C);if(D)return D}let k=P._findPreviousWordOnLine(h,l,C);return g===0?k?v=k.start+1:v>1?v=1:(m--,v=l.getLineMaxColumn(m)):(k&&v<=k.end+1&&(k=P._findPreviousWordOnLine(h,l,new L.y(m,k.start+1))),k?v=k.end+1:v>1?v=1:(m--,v=l.getLineMaxColumn(m))),new U.Q(m,v,C.lineNumber,C.column)}static deleteInsideWord(d,g,h){if(!h.isEmpty())return h;const l=new L.y(h.positionLineNumber,h.positionColumn),u=this._deleteInsideWordWhitespace(g,l);return u||this._deleteInsideWordDetermineDeleteRange(d,g,l)}static _charAtIsWhitespace(d,g){const h=d.charCodeAt(g);return h===32||h===9}static _deleteInsideWordWhitespace(d,g){const h=d.getLineContent(g.lineNumber),l=h.length;if(l===0)return null;let u=Math.max(g.column-2,0);if(!this._charAtIsWhitespace(h,u))return null;let w=Math.min(g.column-1,l-1);if(!this._charAtIsWhitespace(h,w))return null;for(;u>0&&this._charAtIsWhitespace(h,u-1);)u--;for(;w+1<l&&this._charAtIsWhitespace(h,w+1);)w++;return new U.Q(g.lineNumber,u+1,g.lineNumber,w+2)}static _deleteInsideWordDetermineDeleteRange(d,g,h){const l=g.getLineContent(h.lineNumber),u=l.length;if(u===0)return h.lineNumber>1?new U.Q(h.lineNumber-1,g.getLineMaxColumn(h.lineNumber-1),h.lineNumber,1):h.lineNumber<g.getLineCount()?new U.Q(h.lineNumber,1,h.lineNumber+1,1):new U.Q(h.lineNumber,1,h.lineNumber,1);const w=D=>D.start+1<=h.column&&h.column<=D.end+1,C=(D,x)=>(D=Math.min(D,h.column),x=Math.max(x,h.column),new U.Q(h.lineNumber,D,h.lineNumber,x)),m=D=>{let x=D.start+1,A=D.end+1,W=!1;for(;A-1<u&&this._charAtIsWhitespace(l,A-1);)W=!0,A++;if(!W)for(;x>1&&this._charAtIsWhitespace(l,x-2);)x--;return C(x,A)},v=P._findPreviousWordOnLine(d,g,h);if(v&&w(v))return m(v);const k=P._findNextWordOnLine(d,g,h);return k&&w(k)?m(k):v&&k?C(v.end+1,k.start+1):v?C(v.start+1,v.end+1):k?C(k.start+1,k.end+1):C(1,u+1)}static _deleteWordPartLeft(d,g){if(!g.isEmpty())return g;const h=g.getPosition(),l=P._moveWordPartLeft(d,h);return new U.Q(h.lineNumber,h.column,l.lineNumber,l.column)}static _findFirstNonWhitespaceChar(d,g){const h=d.length;for(let l=g;l<h;l++){const u=d.charAt(l);if(u!==" "&&u!==" ")return l}return h}static _deleteWordRightWhitespace(d,g){const h=d.getLineContent(g.lineNumber),l=g.column-1,u=this._findFirstNonWhitespaceChar(h,l);return l+1<u?new U.Q(g.lineNumber,g.column,g.lineNumber,u+1):null}static deleteWordRight(d,g){const h=d.wordSeparators,l=d.model,u=d.selection,w=d.whitespaceHeuristics;if(!u.isEmpty())return u;const C=new L.y(u.positionLineNumber,u.positionColumn);let m=C.lineNumber,v=C.column;const k=l.getLineCount(),D=l.getLineMaxColumn(m);if(m===k&&v===D)return null;if(w){const A=this._deleteWordRightWhitespace(l,C);if(A)return A}let x=P._findNextWordOnLine(h,l,C);return g===2?x?v=x.end+1:v<D||m===k?v=D:(m++,x=P._findNextWordOnLine(h,l,new L.y(m,1)),x?v=x.start+1:v=l.getLineMaxColumn(m)):(x&&v>=x.start+1&&(x=P._findNextWordOnLine(h,l,new L.y(m,x.end+1))),x?v=x.start+1:v<D||m===k?v=D:(m++,x=P._findNextWordOnLine(h,l,new L.y(m,1)),x?v=x.start+1:v=l.getLineMaxColumn(m))),new U.Q(m,v,C.lineNumber,C.column)}static _deleteWordPartRight(d,g){if(!g.isEmpty())return g;const h=g.getPosition(),l=P._moveWordPartRight(d,h);return new U.Q(h.lineNumber,h.column,l.lineNumber,l.column)}static _createWordAtPosition(d,g,h){const l=new U.Q(g,h.start+1,g,h.end+1);return{word:d.getValueInRange(l),startColumn:l.startColumn,endColumn:l.endColumn}}static getWordAtPosition(d,g,h){const l=(0,$.i)(g),u=P._findPreviousWordOnLine(l,d,h);if(u&&u.wordType===1&&u.start<=h.column-1&&h.column-1<=u.end)return P._createWordAtPosition(d,h.lineNumber,u);const w=P._findNextWordOnLine(l,d,h);return w&&w.wordType===1&&w.start<=h.column-1&&h.column-1<=w.end?P._createWordAtPosition(d,h.lineNumber,w):null}static word(d,g,h,l,u){const w=(0,$.i)(d.wordSeparators),C=P._findPreviousWordOnLine(w,g,u),m=P._findNextWordOnLine(w,g,u);if(!l){let A,W;return C&&C.wordType===1&&C.start<=u.column-1&&u.column-1<=C.end?(A=C.start+1,W=C.end+1):m&&m.wordType===1&&m.start<=u.column-1&&u.column-1<=m.end?(A=m.start+1,W=m.end+1):(C?A=C.end+1:A=1,m?W=m.start+1:W=g.getLineMaxColumn(u.lineNumber)),new o.mG(new U.Q(u.lineNumber,A,u.lineNumber,W),0,new L.y(u.lineNumber,W),0)}let v,k;C&&C.wordType===1&&C.start<u.column-1&&u.column-1<C.end?(v=C.start+1,k=C.end+1):m&&m.wordType===1&&m.start<u.column-1&&u.column-1<m.end?(v=m.start+1,k=m.end+1):(v=u.column,k=u.column);const D=u.lineNumber;let x;if(h.selectionStart.containsPosition(u))x=h.selectionStart.endColumn;else if(u.isBeforeOrEqual(h.selectionStart.getStartPosition())){x=v;const A=new L.y(D,x);h.selectionStart.containsPosition(A)&&(x=h.selectionStart.endColumn)}else{x=k;const A=new L.y(D,x);h.selectionStart.containsPosition(A)&&(x=h.selectionStart.startColumn)}return h.move(!0,D,x,0)}}class B extends P{static deleteWordPartLeft(d){const g=T([P.deleteWordLeft(d,0),P.deleteWordLeft(d,2),P._deleteWordPartLeft(d.model,d.selection)]);return g.sort(U.Q.compareRangesUsingEnds),g[2]}static deleteWordPartRight(d){const g=T([P.deleteWordRight(d,0),P.deleteWordRight(d,2),P._deleteWordPartRight(d.model,d.selection)]);return g.sort(U.Q.compareRangesUsingStarts),g[0]}static moveWordPartLeft(d,g,h){const l=T([P.moveWordLeft(d,g,h,0),P.moveWordLeft(d,g,h,2),P._moveWordPartLeft(g,h)]);return l.sort(L.y.compare),l[2]}static moveWordPartRight(d,g,h){const l=T([P.moveWordRight(d,g,h,0),P.moveWordRight(d,g,h,2),P._moveWordPartRight(g,h)]);return l.sort(L.y.compare),l[0]}}function T(p){return p.filter(d=>!!d)}},90028:(rt,ye,y)=>{y.d(ye,{Bc:()=>$,VS:()=>U,_W:()=>T,it:()=>L,nI:()=>p,oO:()=>B});var b=y(94327),o=y(24594),K=y(16844);class ${constructor(g="",h=!1){var l,u,w;if(this.value=g,typeof this.value!="string")throw(0,b.Qg)("value");typeof h=="boolean"?(this.isTrusted=h,this.supportThemeIcons=!1,this.supportHtml=!1):(this.isTrusted=(l=h.isTrusted)!==null&&l!==void 0?l:void 0,this.supportThemeIcons=(u=h.supportThemeIcons)!==null&&u!==void 0?u:!1,this.supportHtml=(w=h.supportHtml)!==null&&w!==void 0?w:!1)}appendText(g,h=0){return this.value+=P(this.supportThemeIcons?(0,o.m2)(g):g).replace(/([ \t]+)/g,(l,u)=>" ".repeat(u.length)).replace(/\>/gm,"\\>").replace(/\n/g,h===1?`\\ `:` `),this}appendMarkdown(g){return this.value+=g,this}appendCodeblock(g,h){return this.value+="\n```",this.value+=g,this.value+=` `,this.value+=h,this.value+="\n```\n",this}appendLink(g,h,l){return this.value+="[",this.value+=this._escape(h,"]"),this.value+="](",this.value+=this._escape(String(g),")"),l&&(this.value+=` "${this._escape(this._escape(l,'"'),")")}"`),this.value+=")",this}_escape(g,h){const l=new RegExp((0,K.bm)(h),"g");return g.replace(l,(u,w)=>g.charAt(w-1)!=="\\"?`\\${u}`:u)}}function L(d){return U(d)?!d.value:Array.isArray(d)?d.every(L):!0}function U(d){return d instanceof $?!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}function P(d){return d.replace(/[\\`*_{}[\]()#+\-!]/g,"\\$&")}function B(d){return d.replace(/"/g,""")}function T(d){return d&&d.replace(/\\([\\`*_{}[\]()#+\-.!])/g,"$1")}function p(d){const g=[],h=d.split("|").map(u=>u.trim());d=h[0];const l=h[1];if(l){const u=/height=(\d+)/.exec(l),w=/width=(\d+)/.exec(l),C=u?u[1]:"",m=w?w[1]:"",v=isFinite(parseInt(m)),k=isFinite(parseInt(C));v&&g.push(`width="${m}"`),k&&g.push(`height="${C}"`)}return{href:d,dimensions:g}}},90304:(rt,ye,y)=>{y.d(ye,{w:()=>K});var b=y(82399);const K=(0,b.u1)("editorWorkerService")},90840:(rt,ye,y)=>{y.d(ye,{CS:()=>d,pc:()=>l,LP:()=>g});var b=y(2106),o=y(10998),K=y(79359),$=y(65958),L=function(u,w,C,m){function v(k){return k instanceof C?k:new C(function(D){D(k)})}return new(C||(C=Promise))(function(k,D){function x(Y){try{W(m.next(Y))}catch(ne){D(ne)}}function A(Y){try{W(m.throw(Y))}catch(ne){D(ne)}}function W(Y){Y.done?k(Y.value):v(Y.value).then(x,A)}W((m=m.apply(u,w||[])).next())})},U;(function(u){u[u.None=0]="None",u[u.Initialized=1]="Initialized",u[u.Closed=2]="Closed"})(U||(U={}));class P extends o.jG{constructor(w,C=Object.create(null)){super(),this.database=w,this.options=C,this._onDidChangeStorage=this._register(new b.vl),this.onDidChangeStorage=this._onDidChangeStorage.event,this.state=U.None,this.cache=new Map,this.flushDelayer=new $.Th(P.DEFAULT_FLUSH_DELAY),this.pendingDeletes=new Set,this.pendingInserts=new Map,this.whenFlushedCallbacks=[],this.registerListeners()}registerListeners(){this._register(this.database.onDidChangeItemsExternal(w=>this.onDidChangeItemsExternal(w)))}onDidChangeItemsExternal(w){var C,m;(C=w.changed)===null||C===void 0||C.forEach((v,k)=>this.accept(k,v)),(m=w.deleted)===null||m===void 0||m.forEach(v=>this.accept(v,void 0))}accept(w,C){if(this.state===U.Closed)return;let m=!1;(0,K.z)(C)?m=this.cache.delete(w):this.cache.get(w)!==C&&(this.cache.set(w,C),m=!0),m&&this._onDidChangeStorage.fire(w)}get(w,C){const m=this.cache.get(w);return(0,K.z)(m)?C:m}getBoolean(w,C){const m=this.get(w);return(0,K.z)(m)?C:m==="true"}getNumber(w,C){const m=this.get(w);return(0,K.z)(m)?C:parseInt(m,10)}set(w,C){return L(this,void 0,void 0,function*(){if(this.state===U.Closed)return;if((0,K.z)(C))return this.delete(w);const m=String(C);if(this.cache.get(w)!==m)return this.cache.set(w,m),this.pendingInserts.set(w,m),this.pendingDeletes.delete(w),this._onDidChangeStorage.fire(w),this.doFlush()})}delete(w){return L(this,void 0,void 0,function*(){if(!(this.state===U.Closed||!this.cache.delete(w)))return this.pendingDeletes.has(w)||this.pendingDeletes.add(w),this.pendingInserts.delete(w),this._onDidChangeStorage.fire(w),this.doFlush()})}get hasPending(){return this.pendingInserts.size>0||this.pendingDeletes.size>0}flushPending(){return L(this,void 0,void 0,function*(){if(!this.hasPending)return;const w={insert:this.pendingInserts,delete:this.pendingDeletes};return this.pendingDeletes=new Set,this.pendingInserts=new Map,this.database.updateItems(w).finally(()=>{var C;if(!this.hasPending)for(;this.whenFlushedCallbacks.length;)(C=this.whenFlushedCallbacks.pop())===null||C===void 0||C()})})}doFlush(w){return L(this,void 0,void 0,function*(){return this.flushDelayer.trigger(()=>this.flushPending(),w)})}dispose(){this.flushDelayer.dispose(),super.dispose()}}P.DEFAULT_FLUSH_DELAY=100;class B{constructor(){this.onDidChangeItemsExternal=b.Jh.None,this.items=new Map}updateItems(w){var C,m;return L(this,void 0,void 0,function*(){(C=w.insert)===null||C===void 0||C.forEach((v,k)=>this.items.set(k,v)),(m=w.delete)===null||m===void 0||m.forEach(v=>this.items.delete(v))})}}var T=y(82399);const p="__$__targetStorageMarker",d=(0,T.u1)("storageService");var g;(function(u){u[u.NONE=0]="NONE",u[u.SHUTDOWN=1]="SHUTDOWN"})(g||(g={}));class h extends o.jG{constructor(w={flushInterval:h.DEFAULT_FLUSH_INTERVAL}){super(),this.options=w,this._onDidChangeValue=this._register(new b.fV),this.onDidChangeValue=this._onDidChangeValue.event,this._onDidChangeTarget=this._register(new b.fV),this._onWillSaveState=this._register(new b.vl),this.onWillSaveState=this._onWillSaveState.event,this._workspaceKeyTargets=void 0,this._profileKeyTargets=void 0,this._applicationKeyTargets=void 0}emitDidChangeValue(w,C){if(C===p){switch(w){case-1:this._applicationKeyTargets=void 0;break;case 0:this._profileKeyTargets=void 0;break;case 1:this._workspaceKeyTargets=void 0;break}this._onDidChangeTarget.fire({scope:w})}else this._onDidChangeValue.fire({scope:w,key:C,target:this.getKeyTargets(w)[C]})}get(w,C,m){var v;return(v=this.getStorage(C))===null||v===void 0?void 0:v.get(w,m)}getBoolean(w,C,m){var v;return(v=this.getStorage(C))===null||v===void 0?void 0:v.getBoolean(w,m)}getNumber(w,C,m){var v;return(v=this.getStorage(C))===null||v===void 0?void 0:v.getNumber(w,m)}store(w,C,m,v){if((0,K.z)(C)){this.remove(w,m);return}this.withPausedEmitters(()=>{var k;this.updateKeyTarget(w,m,v),(k=this.getStorage(m))===null||k===void 0||k.set(w,C)})}remove(w,C){this.withPausedEmitters(()=>{var m;this.updateKeyTarget(w,C,void 0),(m=this.getStorage(C))===null||m===void 0||m.delete(w)})}withPausedEmitters(w){this._onDidChangeValue.pause(),this._onDidChangeTarget.pause();try{w()}finally{this._onDidChangeValue.resume(),this._onDidChangeTarget.resume()}}updateKeyTarget(w,C,m){var v,k;const D=this.getKeyTargets(C);typeof m=="number"?D[w]!==m&&(D[w]=m,(v=this.getStorage(C))===null||v===void 0||v.set(p,JSON.stringify(D))):typeof D[w]=="number"&&(delete D[w],(k=this.getStorage(C))===null||k===void 0||k.set(p,JSON.stringify(D)))}get workspaceKeyTargets(){return this._workspaceKeyTargets||(this._workspaceKeyTargets=this.loadKeyTargets(1)),this._workspaceKeyTargets}get profileKeyTargets(){return this._profileKeyTargets||(this._profileKeyTargets=this.loadKeyTargets(0)),this._profileKeyTargets}get applicationKeyTargets(){return this._applicationKeyTargets||(this._applicationKeyTargets=this.loadKeyTargets(-1)),this._applicationKeyTargets}getKeyTargets(w){switch(w){case-1:return this.applicationKeyTargets;case 0:return this.profileKeyTargets;default:return this.workspaceKeyTargets}}loadKeyTargets(w){const C=this.get(p,w);if(C)try{return JSON.parse(C)}catch{}return Object.create(null)}}h.DEFAULT_FLUSH_INTERVAL=60*1e3;class l extends h{constructor(){super(),this.applicationStorage=this._register(new P(new B)),this.profileStorage=this._register(new P(new B)),this.workspaceStorage=this._register(new P(new B)),this._register(this.workspaceStorage.onDidChangeStorage(w=>this.emitDidChangeValue(1,w))),this._register(this.profileStorage.onDidChangeStorage(w=>this.emitDidChangeValue(0,w))),this._register(this.applicationStorage.onDidChangeStorage(w=>this.emitDidChangeValue(-1,w)))}getStorage(w){switch(w){case-1:return this.applicationStorage;case 0:return this.profileStorage;default:return this.workspaceStorage}}}},91818:(rt,ye,y)=>{y.d(ye,{n:()=>$});var b=y(14333),o=y(26048);const K=new RegExp(`(\\\\)?\\$\\((${o.j3.iconNameExpression}(?:${o.j3.iconModifierExpression})?)\\)`,"g");function $(U){const P=new Array;let B,T=0,p=0;for(;(B=K.exec(U))!==null;){p=B.index||0,P.push(U.substring(T,p)),T=(B.index||0)+B[0].length;const[,d,g]=B;P.push(d?`$(${g})`:L({id:g}))}return T<U.length&&P.push(U.substring(T)),P}function L(U){const P=b.$("span");return P.classList.add(...o.j3.asClassNameArray(U)),P}},92542:(rt,ye,y)=>{y.d(ye,{$w:()=>Ye,SV:()=>ht,aj:()=>it});/*! @license DOMPurify 2.3.1 | (c) Cure53 and other contributors | Released under the Apache license 2.0 and Mozilla Public License 2.0 | github.com/cure53/DOMPurify/blob/2.3.1/LICENSE */function b(Ie){if(Array.isArray(Ie)){for(var Ve=0,dt=Array(Ie.length);Ve<Ie.length;Ve++)dt[Ve]=Ie[Ve];return dt}else return Array.from(Ie)}var o=Object.hasOwnProperty,K=Object.setPrototypeOf,$=Object.isFrozen,L=Object.getPrototypeOf,U=Object.getOwnPropertyDescriptor,P=Object.freeze,B=Object.seal,T=Object.create,p=typeof Reflect<"u"&&Reflect,d=p.apply,g=p.construct;d||(d=function(Ve,dt,bt){return Ve.apply(dt,bt)}),P||(P=function(Ve){return Ve}),B||(B=function(Ve){return Ve}),g||(g=function(Ve,dt){return new(Function.prototype.bind.apply(Ve,[null].concat(b(dt))))});var h=A(Array.prototype.forEach),l=A(Array.prototype.pop),u=A(Array.prototype.push),w=A(String.prototype.toLowerCase),C=A(String.prototype.match),m=A(String.prototype.replace),v=A(String.prototype.indexOf),k=A(String.prototype.trim),D=A(RegExp.prototype.test),x=W(TypeError);function A(Ie){return function(Ve){for(var dt=arguments.length,bt=Array(dt>1?dt-1:0),Mt=1;Mt<dt;Mt++)bt[Mt-1]=arguments[Mt];return d(Ie,Ve,bt)}}function W(Ie){return function(){for(var Ve=arguments.length,dt=Array(Ve),bt=0;bt<Ve;bt++)dt[bt]=arguments[bt];return g(Ie,dt)}}function Y(Ie,Ve){K&&K(Ie,null);for(var dt=Ve.length;dt--;){var bt=Ve[dt];if(typeof bt=="string"){var Mt=w(bt);Mt!==bt&&($(Ve)||(Ve[dt]=Mt),bt=Mt)}Ie[bt]=!0}return Ie}function ne(Ie){var Ve=T(null),dt=void 0;for(dt in Ie)d(o,Ie,[dt])&&(Ve[dt]=Ie[dt]);return Ve}function j(Ie,Ve){for(;Ie!==null;){var dt=U(Ie,Ve);if(dt){if(dt.get)return A(dt.get);if(typeof dt.value=="function")return A(dt.value)}Ie=L(Ie)}function bt(Mt){return console.warn("fallback value for",Mt),null}return bt}var Q=P(["a","abbr","acronym","address","area","article","aside","audio","b","bdi","bdo","big","blink","blockquote","body","br","button","canvas","caption","center","cite","code","col","colgroup","content","data","datalist","dd","decorator","del","details","dfn","dialog","dir","div","dl","dt","element","em","fieldset","figcaption","figure","font","footer","form","h1","h2","h3","h4","h5","h6","head","header","hgroup","hr","html","i","img","input","ins","kbd","label","legend","li","main","map","mark","marquee","menu","menuitem","meter","nav","nobr","ol","optgroup","option","output","p","picture","pre","progress","q","rp","rt","ruby","s","samp","section","select","shadow","small","source","spacer","span","strike","strong","style","sub","summary","sup","table","tbody","td","template","textarea","tfoot","th","thead","time","tr","track","tt","u","ul","var","video","wbr"]),X=P(["svg","a","altglyph","altglyphdef","altglyphitem","animatecolor","animatemotion","animatetransform","circle","clippath","defs","desc","ellipse","filter","font","g","glyph","glyphref","hkern","image","line","lineargradient","marker","mask","metadata","mpath","path","pattern","polygon","polyline","radialgradient","rect","stop","style","switch","symbol","text","textpath","title","tref","tspan","view","vkern"]),R=P(["feBlend","feColorMatrix","feComponentTransfer","feComposite","feConvolveMatrix","feDiffuseLighting","feDisplacementMap","feDistantLight","feFlood","feFuncA","feFuncB","feFuncG","feFuncR","feGaussianBlur","feMerge","feMergeNode","feMorphology","feOffset","fePointLight","feSpecularLighting","feSpotLight","feTile","feTurbulence"]),H=P(["animate","color-profile","cursor","discard","fedropshadow","feimage","font-face","font-face-format","font-face-name","font-face-src","font-face-uri","foreignobject","hatch","hatchpath","mesh","meshgradient","meshpatch","meshrow","missing-glyph","script","set","solidcolor","unknown","use"]),Z=P(["math","menclose","merror","mfenced","mfrac","mglyph","mi","mlabeledtr","mmultiscripts","mn","mo","mover","mpadded","mphantom","mroot","mrow","ms","mspace","msqrt","mstyle","msub","msup","msubsup","mtable","mtd","mtext","mtr","munder","munderover"]),N=P(["maction","maligngroup","malignmark","mlongdiv","mscarries","mscarry","msgroup","mstack","msline","msrow","semantics","annotation","annotation-xml","mprescripts","none"]),G=P(["#text"]),O=P(["accept","action","align","alt","autocapitalize","autocomplete","autopictureinpicture","autoplay","background","bgcolor","border","capture","cellpadding","cellspacing","checked","cite","class","clear","color","cols","colspan","controls","controlslist","coords","crossorigin","datetime","decoding","default","dir","disabled","disablepictureinpicture","disableremoteplayback","download","draggable","enctype","enterkeyhint","face","for","headers","height","hidden","high","href","hreflang","id","inputmode","integrity","ismap","kind","label","lang","list","loading","loop","low","max","maxlength","media","method","min","minlength","multiple","muted","name","noshade","novalidate","nowrap","open","optimum","pattern","placeholder","playsinline","poster","preload","pubdate","radiogroup","readonly","rel","required","rev","reversed","role","rows","rowspan","spellcheck","scope","selected","shape","size","sizes","span","srclang","start","src","srcset","step","style","summary","tabindex","title","translate","type","usemap","valign","value","width","xmlns","slot"]),te=P(["accent-height","accumulate","additive","alignment-baseline","ascent","attributename","attributetype","azimuth","basefrequency","baseline-shift","begin","bias","by","class","clip","clippathunits","clip-path","clip-rule","color","color-interpolation","color-interpolation-filters","color-profile","color-rendering","cx","cy","d","dx","dy","diffuseconstant","direction","display","divisor","dur","edgemode","elevation","end","fill","fill-opacity","fill-rule","filter","filterunits","flood-color","flood-opacity","font-family","font-size","font-size-adjust","font-stretch","font-style","font-variant","font-weight","fx","fy","g1","g2","glyph-name","glyphref","gradientunits","gradienttransform","height","href","id","image-rendering","in","in2","k","k1","k2","k3","k4","kerning","keypoints","keysplines","keytimes","lang","lengthadjust","letter-spacing","kernelmatrix","kernelunitlength","lighting-color","local","marker-end","marker-mid","marker-start","markerheight","markerunits","markerwidth","maskcontentunits","maskunits","max","mask","media","method","mode","min","name","numoctaves","offset","operator","opacity","order","orient","orientation","origin","overflow","paint-order","path","pathlength","patterncontentunits","patterntransform","patternunits","points","preservealpha","preserveaspectratio","primitiveunits","r","rx","ry","radius","refx","refy","repeatcount","repeatdur","restart","result","rotate","scale","seed","shape-rendering","specularconstant","specularexponent","spreadmethod","startoffset","stddeviation","stitchtiles","stop-color","stop-opacity","stroke-dasharray","stroke-dashoffset","stroke-linecap","stroke-linejoin","stroke-miterlimit","stroke-opacity","stroke","stroke-width","style","surfacescale","systemlanguage","tabindex","targetx","targety","transform","text-anchor","text-decoration","text-rendering","textlength","type","u1","u2","unicode","values","viewbox","visibility","version","vert-adv-y","vert-origin-x","vert-origin-y","width","word-spacing","wrap","writing-mode","xchannelselector","ychannelselector","x","x1","x2","xmlns","y","y1","y2","z","zoomandpan"]),oe=P(["accent","accentunder","align","bevelled","close","columnsalign","columnlines","columnspan","denomalign","depth","dir","display","displaystyle","encoding","fence","frame","height","href","id","largeop","length","linethickness","lspace","lquote","mathbackground","mathcolor","mathsize","mathvariant","maxsize","minsize","movablelimits","notation","numalign","open","rowalign","rowlines","rowspacing","rowspan","rspace","rquote","scriptlevel","scriptminsize","scriptsizemultiplier","selection","separator","separators","stretchy","subscriptshift","supscriptshift","symmetric","voffset","width","xmlns"]),ue=P(["xlink:href","xml:id","xlink:title","xml:space","xmlns:xlink"]),E=B(/\{\{[\s\S]*|[\s\S]*\}\}/gm),Qe=B(/<%[\s\S]*|[\s\S]*%>/gm),Ke=B(/^data-[\-\w.\u00B7-\uFFFF]/),Se=B(/^aria-[\-\w]+$/),Me=B(/^(?:(?:(?:f|ht)tps?|mailto|tel|callto|cid|xmpp):|[^a-z]|[a-z+.\-]+(?:[^a-z+.\-:]|$))/i),ce=B(/^(?:\w+script|data):/i),pe=B(/[\u0000-\u0020\u00A0\u1680\u180E\u2000-\u2029\u205F\u3000]/g),be=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(Ie){return typeof Ie}:function(Ie){return Ie&&typeof Symbol=="function"&&Ie.constructor===Symbol&&Ie!==Symbol.prototype?"symbol":typeof Ie};function ge(Ie){if(Array.isArray(Ie)){for(var Ve=0,dt=Array(Ie.length);Ve<Ie.length;Ve++)dt[Ve]=Ie[Ve];return dt}else return Array.from(Ie)}var ke=function(){return typeof window>"u"?null:window},We=function(Ve,dt){if((typeof Ve>"u"?"undefined":be(Ve))!=="object"||typeof Ve.createPolicy!="function")return null;var bt=null,Mt="data-tt-policy-suffix";dt.currentScript&&dt.currentScript.hasAttribute(Mt)&&(bt=dt.currentScript.getAttribute(Mt));var Yt="dompurify"+(bt?"#"+bt:"");try{return Ve.createPolicy(Yt,{createHTML:function(Pt){return Pt}})}catch{return console.warn("TrustedTypes policy "+Yt+" could not be created."),null}};function Ge(){var Ie=arguments.length>0&&arguments[0]!==void 0?arguments[0]:ke(),Ve=function(pt){return Ge(pt)};if(Ve.version="2.3.1",Ve.removed=[],!Ie||!Ie.document||Ie.document.nodeType!==9)return Ve.isSupported=!1,Ve;var dt=Ie.document,bt=Ie.document,Mt=Ie.DocumentFragment,Yt=Ie.HTMLTemplateElement,Nt=Ie.Node,Pt=Ie.Element,Ti=Ie.NodeFilter,Ii=Ie.NamedNodeMap,ut=Ii===void 0?Ie.NamedNodeMap||Ie.MozNamedAttrMap:Ii,Si=Ie.Text,yt=Ie.Comment,fe=Ie.DOMParser,ze=Ie.trustedTypes,Et=Pt.prototype,Ot=j(Et,"cloneNode"),si=j(Et,"nextSibling"),_i=j(Et,"childNodes"),Fe=j(Et,"parentNode");if(typeof Yt=="function"){var Xe=bt.createElement("template");Xe.content&&Xe.content.ownerDocument&&(bt=Xe.content.ownerDocument)}var gt=We(ze,dt),Xt=gt&&Fi?gt.createHTML(""):"",Vt=bt,ni=Vt.implementation,vi=Vt.createNodeIterator,Ri=Vt.createDocumentFragment,St=Vt.getElementsByTagName,ve=dt.importNode,Te={};try{Te=ne(bt).documentMode?bt.documentMode:{}}catch{}var je={};Ve.isSupported=typeof Fe=="function"&&ni&&typeof ni.createHTMLDocument<"u"&&Te!==9;var nt=E,at=Qe,vt=Ke,It=Se,At=ce,wt=pe,kt=Me,Ct=null,Gt=Y({},[].concat(ge(Q),ge(X),ge(R),ge(Z),ge(G))),Ht=null,Ut=Y({},[].concat(ge(O),ge(te),ge(oe),ge(ue))),Ue=null,ei=null,ui=!0,oi=!0,ki=!1,Kt=!1,li=!1,Ci=!1,mi=!1,Tt=!1,qt=!1,Ni=!0,Fi=!1,yi=!0,ti=!0,wi=!1,Qi={},Vi=null,Zi=Y({},["annotation-xml","audio","colgroup","desc","foreignobject","head","iframe","math","mi","mn","mo","ms","mtext","noembed","noframes","noscript","plaintext","script","style","svg","template","thead","title","video","xmp"]),Ji=null,qi=Y({},["audio","video","img","source","image","track"]),Pi=null,fi=Y({},["alt","class","for","id","label","name","pattern","placeholder","role","summary","title","value","style","xmlns"]),Sn="http://www.w3.org/1998/Math/MathML",cn="http://www.w3.org/2000/svg",en="http://www.w3.org/1999/xhtml",dn=en,Li=!1,Rn=null,In=bt.createElement("form"),xn=function(pt){Rn&&Rn===pt||((!pt||(typeof pt>"u"?"undefined":be(pt))!=="object")&&(pt={}),pt=ne(pt),Ct="ALLOWED_TAGS"in pt?Y({},pt.ALLOWED_TAGS):Gt,Ht="ALLOWED_ATTR"in pt?Y({},pt.ALLOWED_ATTR):Ut,Pi="ADD_URI_SAFE_ATTR"in pt?Y(ne(fi),pt.ADD_URI_SAFE_ATTR):fi,Ji="ADD_DATA_URI_TAGS"in pt?Y(ne(qi),pt.ADD_DATA_URI_TAGS):qi,Vi="FORBID_CONTENTS"in pt?Y({},pt.FORBID_CONTENTS):Zi,Ue="FORBID_TAGS"in pt?Y({},pt.FORBID_TAGS):{},ei="FORBID_ATTR"in pt?Y({},pt.FORBID_ATTR):{},Qi="USE_PROFILES"in pt?pt.USE_PROFILES:!1,ui=pt.ALLOW_ARIA_ATTR!==!1,oi=pt.ALLOW_DATA_ATTR!==!1,ki=pt.ALLOW_UNKNOWN_PROTOCOLS||!1,Kt=pt.SAFE_FOR_TEMPLATES||!1,li=pt.WHOLE_DOCUMENT||!1,Tt=pt.RETURN_DOM||!1,qt=pt.RETURN_DOM_FRAGMENT||!1,Ni=pt.RETURN_DOM_IMPORT!==!1,Fi=pt.RETURN_TRUSTED_TYPE||!1,mi=pt.FORCE_BODY||!1,yi=pt.SANITIZE_DOM!==!1,ti=pt.KEEP_CONTENT!==!1,wi=pt.IN_PLACE||!1,kt=pt.ALLOWED_URI_REGEXP||kt,dn=pt.NAMESPACE||en,Kt&&(oi=!1),qt&&(Tt=!0),Qi&&(Ct=Y({},[].concat(ge(G))),Ht=[],Qi.html===!0&&(Y(Ct,Q),Y(Ht,O)),Qi.svg===!0&&(Y(Ct,X),Y(Ht,te),Y(Ht,ue)),Qi.svgFilters===!0&&(Y(Ct,R),Y(Ht,te),Y(Ht,ue)),Qi.mathMl===!0&&(Y(Ct,Z),Y(Ht,oe),Y(Ht,ue))),pt.ADD_TAGS&&(Ct===Gt&&(Ct=ne(Ct)),Y(Ct,pt.ADD_TAGS)),pt.ADD_ATTR&&(Ht===Ut&&(Ht=ne(Ht)),Y(Ht,pt.ADD_ATTR)),pt.ADD_URI_SAFE_ATTR&&Y(Pi,pt.ADD_URI_SAFE_ATTR),pt.FORBID_CONTENTS&&(Vi===Zi&&(Vi=ne(Vi)),Y(Vi,pt.FORBID_CONTENTS)),ti&&(Ct["#text"]=!0),li&&Y(Ct,["html","head","body"]),Ct.table&&(Y(Ct,["tbody"]),delete Ue.tbody),P&&P(pt),Rn=pt)},Tn=Y({},["mi","mo","mn","ms","mtext"]),wn=Y({},["foreignobject","desc","title","annotation-xml"]),Ln=Y({},X);Y(Ln,R),Y(Ln,H);var Cn=Y({},Z);Y(Cn,N);var Bn=function(pt){var zt=Fe(pt);(!zt||!zt.tagName)&&(zt={namespaceURI:en,tagName:"template"});var Qt=w(pt.tagName),Di=w(zt.tagName);if(pt.namespaceURI===cn)return zt.namespaceURI===en?Qt==="svg":zt.namespaceURI===Sn?Qt==="svg"&&(Di==="annotation-xml"||Tn[Di]):!!Ln[Qt];if(pt.namespaceURI===Sn)return zt.namespaceURI===en?Qt==="math":zt.namespaceURI===cn?Qt==="math"&&wn[Di]:!!Cn[Qt];if(pt.namespaceURI===en){if(zt.namespaceURI===cn&&!wn[Di]||zt.namespaceURI===Sn&&!Tn[Di])return!1;var Ui=Y({},["title","style","font","a","script"]);return!Cn[Qt]&&(Ui[Qt]||!Ln[Qt])}return!1},Mn=function(pt){u(Ve.removed,{element:pt});try{pt.parentNode.removeChild(pt)}catch{try{pt.outerHTML=Xt}catch{pt.remove()}}},Yn=function(pt,zt){try{u(Ve.removed,{attribute:zt.getAttributeNode(pt),from:zt})}catch{u(Ve.removed,{attribute:null,from:zt})}if(zt.removeAttribute(pt),pt==="is"&&!Ht[pt])if(Tt||qt)try{Mn(zt)}catch{}else try{zt.setAttribute(pt,"")}catch{}},Hn=function(pt){var zt=void 0,Qt=void 0;if(mi)pt="<remove></remove>"+pt;else{var Di=C(pt,/^[\r\n\t ]+/);Qt=Di&&Di[0]}var Ui=gt?gt.createHTML(pt):pt;if(dn===en)try{zt=new fe().parseFromString(Ui,"text/html")}catch{}if(!zt||!zt.documentElement){zt=ni.createDocument(dn,"template",null);try{zt.documentElement.innerHTML=Li?"":Ui}catch{}}var Wi=zt.body||zt.documentElement;return pt&&Qt&&Wi.insertBefore(bt.createTextNode(Qt),Wi.childNodes[0]||null),dn===en?St.call(zt,li?"html":"body")[0]:li?zt.documentElement:Wi},_n=function(pt){return vi.call(pt.ownerDocument||pt,pt,Ti.SHOW_ELEMENT|Ti.SHOW_COMMENT|Ti.SHOW_TEXT,null,!1)},yn=function(pt){return pt instanceof Si||pt instanceof yt?!1:typeof pt.nodeName!="string"||typeof pt.textContent!="string"||typeof pt.removeChild!="function"||!(pt.attributes instanceof ut)||typeof pt.removeAttribute!="function"||typeof pt.setAttribute!="function"||typeof pt.namespaceURI!="string"||typeof pt.insertBefore!="function"},On=function(pt){return(typeof Nt>"u"?"undefined":be(Nt))==="object"?pt instanceof Nt:pt&&(typeof pt>"u"?"undefined":be(pt))==="object"&&typeof pt.nodeType=="number"&&typeof pt.nodeName=="string"},sn=function(pt,zt,Qt){je[pt]&&h(je[pt],function(Di){Di.call(Ve,zt,Qt,Rn)})},zn=function(pt){var zt=void 0;if(sn("beforeSanitizeElements",pt,null),yn(pt)||C(pt.nodeName,/[\u0080-\uFFFF]/))return Mn(pt),!0;var Qt=w(pt.nodeName);if(sn("uponSanitizeElement",pt,{tagName:Qt,allowedTags:Ct}),!On(pt.firstElementChild)&&(!On(pt.content)||!On(pt.content.firstElementChild))&&D(/<[/\w]/g,pt.innerHTML)&&D(/<[/\w]/g,pt.textContent)||Qt==="select"&&D(/<template/i,pt.innerHTML))return Mn(pt),!0;if(!Ct[Qt]||Ue[Qt]){if(ti&&!Vi[Qt]){var Di=Fe(pt)||pt.parentNode,Ui=_i(pt)||pt.childNodes;if(Ui&&Di)for(var Wi=Ui.length,xe=Wi-1;xe>=0;--xe)Di.insertBefore(Ot(Ui[xe],!0),si(pt))}return Mn(pt),!0}return pt instanceof Pt&&!Bn(pt)||(Qt==="noscript"||Qt==="noembed")&&D(/<\/no(script|embed)/i,pt.innerHTML)?(Mn(pt),!0):(Kt&&pt.nodeType===3&&(zt=pt.textContent,zt=m(zt,nt," "),zt=m(zt,at," "),pt.textContent!==zt&&(u(Ve.removed,{element:pt.cloneNode()}),pt.textContent=zt)),sn("afterSanitizeElements",pt,null),!1)},Gi=function(pt,zt,Qt){if(yi&&(zt==="id"||zt==="name")&&(Qt in bt||Qt in In))return!1;if(!(oi&&!ei[zt]&&D(vt,zt))){if(!(ui&&D(It,zt))){if(!Ht[zt]||ei[zt])return!1;if(!Pi[zt]){if(!D(kt,m(Qt,wt,""))){if(!((zt==="src"||zt==="xlink:href"||zt==="href")&&pt!=="script"&&v(Qt,"data:")===0&&Ji[pt])){if(!(ki&&!D(At,m(Qt,wt,"")))){if(Qt)return!1}}}}}}return!0},$n=function(pt){var zt=void 0,Qt=void 0,Di=void 0,Ui=void 0;sn("beforeSanitizeAttributes",pt,null);var Wi=pt.attributes;if(Wi){var xe={attrName:"",attrValue:"",keepAttr:!0,allowedAttributes:Ht};for(Ui=Wi.length;Ui--;){zt=Wi[Ui];var a=zt,n=a.name,c=a.namespaceURI;if(Qt=k(zt.value),Di=w(n),xe.attrName=Di,xe.attrValue=Qt,xe.keepAttr=!0,xe.forceKeepAttr=void 0,sn("uponSanitizeAttribute",pt,xe),Qt=xe.attrValue,!xe.forceKeepAttr&&(Yn(n,pt),!!xe.keepAttr)){if(D(/\/>/i,Qt)){Yn(n,pt);continue}Kt&&(Qt=m(Qt,nt," "),Qt=m(Qt,at," "));var I=pt.nodeName.toLowerCase();if(Gi(I,Di,Qt))try{c?pt.setAttributeNS(c,n,Qt):pt.setAttribute(n,Qt),l(Ve.removed)}catch{}}}sn("afterSanitizeAttributes",pt,null)}},Nn=function bi(pt){var zt=void 0,Qt=_n(pt);for(sn("beforeSanitizeShadowDOM",pt,null);zt=Qt.nextNode();)sn("uponSanitizeShadowNode",zt,null),!zn(zt)&&(zt.content instanceof Mt&&bi(zt.content),$n(zt));sn("afterSanitizeShadowDOM",pt,null)};return Ve.sanitize=function(bi,pt){var zt=void 0,Qt=void 0,Di=void 0,Ui=void 0,Wi=void 0;if(Li=!bi,Li&&(bi="<!-->"),typeof bi!="string"&&!On(bi)){if(typeof bi.toString!="function")throw x("toString is not a function");if(bi=bi.toString(),typeof bi!="string")throw x("dirty is not a string, aborting")}if(!Ve.isSupported){if(be(Ie.toStaticHTML)==="object"||typeof Ie.toStaticHTML=="function"){if(typeof bi=="string")return Ie.toStaticHTML(bi);if(On(bi))return Ie.toStaticHTML(bi.outerHTML)}return bi}if(Ci||xn(pt),Ve.removed=[],typeof bi=="string"&&(wi=!1),!wi)if(bi instanceof Nt)zt=Hn("<!---->"),Qt=zt.ownerDocument.importNode(bi,!0),Qt.nodeType===1&&Qt.nodeName==="BODY"||Qt.nodeName==="HTML"?zt=Qt:zt.appendChild(Qt);else{if(!Tt&&!Kt&&!li&&bi.indexOf("<")===-1)return gt&&Fi?gt.createHTML(bi):bi;if(zt=Hn(bi),!zt)return Tt?null:Xt}zt&&mi&&Mn(zt.firstChild);for(var xe=_n(wi?bi:zt);Di=xe.nextNode();)Di.nodeType===3&&Di===Ui||zn(Di)||(Di.content instanceof Mt&&Nn(Di.content),$n(Di),Ui=Di);if(Ui=null,wi)return bi;if(Tt){if(qt)for(Wi=Ri.call(zt.ownerDocument);zt.firstChild;)Wi.appendChild(zt.firstChild);else Wi=zt;return Ni&&(Wi=ve.call(dt,Wi,!0)),Wi}var a=li?zt.outerHTML:zt.innerHTML;return Kt&&(a=m(a,nt," "),a=m(a,at," ")),gt&&Fi?gt.createHTML(a):a},Ve.setConfig=function(bi){xn(bi),Ci=!0},Ve.clearConfig=function(){Rn=null,Ci=!1},Ve.isValidAttribute=function(bi,pt,zt){Rn||xn({});var Qt=w(bi),Di=w(pt);return Gi(Qt,Di,zt)},Ve.addHook=function(bi,pt){typeof pt=="function"&&(je[bi]=je[bi]||[],u(je[bi],pt))},Ve.removeHook=function(bi){je[bi]&&l(je[bi])},Ve.removeHooks=function(bi){je[bi]&&(je[bi]=[])},Ve.removeAllHooks=function(){je={}},Ve}var Ae=Ge(),he=null;const Pe=Ae.version,$e=Ae.isSupported,it=Ae.sanitize,ft=Ae.setConfig,Wt=Ae.clearConfig,tt=Ae.isValidAttribute,Ye=Ae.addHook,ht=Ae.removeHook,Lt=Ae.removeHooks,Rt=Ae.removeAllHooks},93344:(rt,ye,y)=>{y.d(ye,{$D:()=>d,Eq:()=>g,M0:()=>C,No:()=>u,bs:()=>h});var b=y(55893),o=y(14333),K=y(87594),$=y(65958),L=y(2106),U=y(10998),P=y(53720),B=y(16844),T=y(13377),p=y(93702),d;(function(m){m.Tap="-monaco-textarea-synthetic-tap"})(d||(d={}));const g={forceCopyWithSyntaxHighlighting:!1};class h{constructor(){this._lastState=null}set(v,k){this._lastState={lastCopiedValue:v,data:k}}get(v){return this._lastState&&this._lastState.lastCopiedValue===v?this._lastState.data:(this._lastState=null,null)}}h.INSTANCE=new h;class l{constructor(){this._lastTypeTextLength=0}handleCompositionUpdate(v){v=v||"";const k={text:v,replacePrevCharCnt:this._lastTypeTextLength,replaceNextCharCnt:0,positionDelta:0};return this._lastTypeTextLength=v.length,k}}class u extends U.jG{constructor(v,k,D,x){super(),this._host=v,this._textArea=k,this._OS=D,this._browser=x,this._onFocus=this._register(new L.vl),this.onFocus=this._onFocus.event,this._onBlur=this._register(new L.vl),this.onBlur=this._onBlur.event,this._onKeyDown=this._register(new L.vl),this.onKeyDown=this._onKeyDown.event,this._onKeyUp=this._register(new L.vl),this.onKeyUp=this._onKeyUp.event,this._onCut=this._register(new L.vl),this.onCut=this._onCut.event,this._onPaste=this._register(new L.vl),this.onPaste=this._onPaste.event,this._onType=this._register(new L.vl),this.onType=this._onType.event,this._onCompositionStart=this._register(new L.vl),this.onCompositionStart=this._onCompositionStart.event,this._onCompositionUpdate=this._register(new L.vl),this.onCompositionUpdate=this._onCompositionUpdate.event,this._onCompositionEnd=this._register(new L.vl),this.onCompositionEnd=this._onCompositionEnd.event,this._onSelectionChangeRequest=this._register(new L.vl),this.onSelectionChangeRequest=this._onSelectionChangeRequest.event,this._asyncTriggerCut=this._register(new $.uC(()=>this._onCut.fire(),0)),this._asyncFocusGainWriteScreenReaderContent=this._register(new $.uC(()=>this.writeScreenReaderContent("asyncFocusGain"),0)),this._textAreaState=T._O.EMPTY,this._selectionChangeListener=null,this.writeScreenReaderContent("ctor"),this._hasFocus=!1,this._currentComposition=null;let A=null;this._register(this._textArea.onKeyDown(W=>{const Y=new K.Z(W);(Y.keyCode===109||this._currentComposition&&Y.keyCode===1)&&Y.stopPropagation(),Y.equals(9)&&Y.preventDefault(),A=Y,this._onKeyDown.fire(Y)})),this._register(this._textArea.onKeyUp(W=>{const Y=new K.Z(W);this._onKeyUp.fire(Y)})),this._register(this._textArea.onCompositionStart(W=>{T.Hf&&console.log("[compositionstart]",W);const Y=new l;if(this._currentComposition){this._currentComposition=Y;return}if(this._currentComposition=Y,this._OS===2&&A&&A.equals(109)&&this._textAreaState.selectionStart===this._textAreaState.selectionEnd&&this._textAreaState.selectionStart>0&&this._textAreaState.value.substr(this._textAreaState.selectionStart-1,1)===W.data&&(A.code==="ArrowRight"||A.code==="ArrowLeft")){T.Hf&&console.log("[compositionstart] Handling long press case on macOS + arrow key",W),Y.handleCompositionUpdate("x"),this._onCompositionStart.fire({data:W.data});return}if(this._browser.isAndroid){this._onCompositionStart.fire({data:W.data});return}this._onCompositionStart.fire({data:W.data})})),this._register(this._textArea.onCompositionUpdate(W=>{T.Hf&&console.log("[compositionupdate]",W);const Y=this._currentComposition;if(!Y)return;if(this._browser.isAndroid){const j=T._O.readFromTextArea(this._textArea),Q=T._O.deduceAndroidCompositionInput(this._textAreaState,j);this._textAreaState=j,this._onType.fire(Q),this._onCompositionUpdate.fire(W);return}const ne=Y.handleCompositionUpdate(W.data);this._textAreaState=T._O.readFromTextArea(this._textArea),this._onType.fire(ne),this._onCompositionUpdate.fire(W)})),this._register(this._textArea.onCompositionEnd(W=>{T.Hf&&console.log("[compositionend]",W);const Y=this._currentComposition;if(!Y)return;if(this._currentComposition=null,this._browser.isAndroid){const j=T._O.readFromTextArea(this._textArea),Q=T._O.deduceAndroidCompositionInput(this._textAreaState,j);this._textAreaState=j,this._onType.fire(Q),this._onCompositionEnd.fire();return}const ne=Y.handleCompositionUpdate(W.data);this._textAreaState=T._O.readFromTextArea(this._textArea),this._onType.fire(ne),this._onCompositionEnd.fire()})),this._register(this._textArea.onInput(W=>{if(T.Hf&&console.log("[input]",W),this._textArea.setIgnoreSelectionChangeTime("received input event"),this._currentComposition)return;const Y=T._O.readFromTextArea(this._textArea),ne=T._O.deduceInput(this._textAreaState,Y,this._OS===2);ne.replacePrevCharCnt===0&&ne.text.length===1&&B.pc(ne.text.charCodeAt(0))||(this._textAreaState=Y,(ne.text!==""||ne.replacePrevCharCnt!==0||ne.replaceNextCharCnt!==0||ne.positionDelta!==0)&&this._onType.fire(ne))})),this._register(this._textArea.onCut(W=>{this._textArea.setIgnoreSelectionChangeTime("received cut event"),this._ensureClipboardGetsEditorSelection(W),this._asyncTriggerCut.schedule()})),this._register(this._textArea.onCopy(W=>{this._ensureClipboardGetsEditorSelection(W)})),this._register(this._textArea.onPaste(W=>{if(this._textArea.setIgnoreSelectionChangeTime("received paste event"),W.preventDefault(),!W.clipboardData)return;let[Y,ne]=w.getTextData(W.clipboardData);Y&&(ne=ne||h.INSTANCE.get(Y),this._onPaste.fire({text:Y,metadata:ne}))})),this._register(this._textArea.onFocus(()=>{const W=this._hasFocus;this._setHasFocus(!0),this._browser.isSafari&&!W&&this._hasFocus&&this._asyncFocusGainWriteScreenReaderContent.schedule()})),this._register(this._textArea.onBlur(()=>{this._currentComposition&&(this._currentComposition=null,this.writeScreenReaderContent("blurWithoutCompositionEnd"),this._onCompositionEnd.fire()),this._setHasFocus(!1)})),this._register(this._textArea.onSyntheticTap(()=>{this._browser.isAndroid&&this._currentComposition&&(this._currentComposition=null,this.writeScreenReaderContent("tapWithoutCompositionEnd"),this._onCompositionEnd.fire())}))}_installSelectionChangeListener(){let v=0;return o.ko(document,"selectionchange",k=>{if(!this._hasFocus||this._currentComposition||!this._browser.isChrome)return;const D=Date.now(),x=D-v;if(v=D,x<5)return;const A=D-this._textArea.getIgnoreSelectionChangeTime();if(this._textArea.resetSelectionChangeTime(),A<100||!this._textAreaState.selectionStartPosition||!this._textAreaState.selectionEndPosition)return;const W=this._textArea.getValue();if(this._textAreaState.value!==W)return;const Y=this._textArea.getSelectionStart(),ne=this._textArea.getSelectionEnd();if(this._textAreaState.selectionStart===Y&&this._textAreaState.selectionEnd===ne)return;const j=this._textAreaState.deduceEditorPosition(Y),Q=this._host.deduceModelPosition(j[0],j[1],j[2]),X=this._textAreaState.deduceEditorPosition(ne),R=this._host.deduceModelPosition(X[0],X[1],X[2]),H=new p.L(Q.lineNumber,Q.column,R.lineNumber,R.column);this._onSelectionChangeRequest.fire(H)})}dispose(){super.dispose(),this._selectionChangeListener&&(this._selectionChangeListener.dispose(),this._selectionChangeListener=null)}focusTextArea(){this._setHasFocus(!0),this.refreshFocusState()}isFocused(){return this._hasFocus}refreshFocusState(){this._setHasFocus(this._textArea.hasFocus())}_setHasFocus(v){this._hasFocus!==v&&(this._hasFocus=v,this._selectionChangeListener&&(this._selectionChangeListener.dispose(),this._selectionChangeListener=null),this._hasFocus&&(this._selectionChangeListener=this._installSelectionChangeListener()),this._hasFocus&&this.writeScreenReaderContent("focusgain"),this._hasFocus?this._onFocus.fire():this._onBlur.fire())}_setAndWriteTextAreaState(v,k){this._hasFocus||(k=k.collapseSelection()),k.writeToTextArea(v,this._textArea,this._hasFocus),this._textAreaState=k}writeScreenReaderContent(v){this._currentComposition||this._setAndWriteTextAreaState(v,this._host.getScreenReaderContent(this._textAreaState))}_ensureClipboardGetsEditorSelection(v){const k=this._host.getDataToCopy(),D={version:1,isFromEmptySelection:k.isFromEmptySelection,multicursorText:k.multicursorText,mode:k.mode};h.INSTANCE.set(this._browser.isFirefox?k.text.replace(/\r\n/g,` `):k.text,D),v.preventDefault(),v.clipboardData&&w.setTextData(v.clipboardData,k.text,k.html,D)}}class w{static getTextData(v){const k=v.getData(P.K.text);let D=null;const x=v.getData("vscode-editor-data");if(typeof x=="string")try{D=JSON.parse(x),D.version!==1&&(D=null)}catch{}return k.length===0&&D===null&&v.files.length>0?[Array.prototype.slice.call(v.files,0).map(W=>W.name).join(` `),null]:[k,D]}static setTextData(v,k,D,x){v.setData(P.K.text,k),typeof D=="string"&&v.setData("text/html",D),v.setData("vscode-editor-data",JSON.stringify(x))}}class C extends U.jG{constructor(v){super(),this._actual=v,this.onKeyDown=this._register(o.dl(this._actual,"keydown")).event,this.onKeyUp=this._register(o.dl(this._actual,"keyup")).event,this.onCompositionStart=this._register(o.dl(this._actual,"compositionstart")).event,this.onCompositionUpdate=this._register(o.dl(this._actual,"compositionupdate")).event,this.onCompositionEnd=this._register(o.dl(this._actual,"compositionend")).event,this.onInput=this._register(o.dl(this._actual,"input")).event,this.onCut=this._register(o.dl(this._actual,"cut")).event,this.onCopy=this._register(o.dl(this._actual,"copy")).event,this.onPaste=this._register(o.dl(this._actual,"paste")).event,this.onFocus=this._register(o.dl(this._actual,"focus")).event,this.onBlur=this._register(o.dl(this._actual,"blur")).event,this._onSyntheticTap=this._register(new L.vl),this.onSyntheticTap=this._onSyntheticTap.event,this._ignoreSelectionChangeTime=0,this._register(o.ko(this._actual,d.Tap,()=>this._onSyntheticTap.fire()))}hasFocus(){const v=o.jG(this._actual);return v?v.activeElement===this._actual:o.qD(this._actual)?document.activeElement===this._actual:!1}setIgnoreSelectionChangeTime(v){this._ignoreSelectionChangeTime=Date.now()}getIgnoreSelectionChangeTime(){return this._ignoreSelectionChangeTime}resetSelectionChangeTime(){this._ignoreSelectionChangeTime=0}getValue(){return this._actual.value}setValue(v,k){const D=this._actual;D.value!==k&&(this.setIgnoreSelectionChangeTime("setValue"),D.value=k)}getSelectionStart(){return this._actual.selectionDirection==="backward"?this._actual.selectionEnd:this._actual.selectionStart}getSelectionEnd(){return this._actual.selectionDirection==="backward"?this._actual.selectionStart:this._actual.selectionEnd}setSelectionRange(v,k,D){const x=this._actual;let A=null;const W=o.jG(x);W?A=W.activeElement:A=document.activeElement;const Y=A===x,ne=x.selectionStart,j=x.selectionEnd;if(Y&&ne===k&&j===D){b.isFirefox&&window.parent!==window&&x.focus();return}if(Y){this.setIgnoreSelectionChangeTime("setSelectionRange"),x.setSelectionRange(k,D),b.isFirefox&&window.parent!==window&&x.focus();return}try{const Q=o.zK(x);this.setIgnoreSelectionChangeTime("setSelectionRange"),x.focus(),x.setSelectionRange(k,D),o.wk(x,Q)}catch{}}}},93582:(rt,ye,y)=>{y.d(ye,{aQ:()=>G,nr:()=>O,Sx:()=>Se,po:()=>N,tj:()=>Z});var b=y(14333),o=y(55893),K=y(94901),$=y(2106),L=y(47317),U=y(15910);class P{constructor(ce,pe,be,ge,ke){this._parsedThemeRuleBrand=void 0,this.token=ce,this.index=pe,this.fontStyle=be,this.foreground=ge,this.background=ke}}function B(Me){if(!Me||!Array.isArray(Me))return[];const ce=[];let pe=0;for(let be=0,ge=Me.length;be<ge;be++){const ke=Me[be];let We=-1;if(typeof ke.fontStyle=="string"){We=0;const he=ke.fontStyle.split(" ");for(let Pe=0,$e=he.length;Pe<$e;Pe++)switch(he[Pe]){case"italic":We=We|1;break;case"bold":We=We|2;break;case"underline":We=We|4;break;case"strikethrough":We=We|8;break}}let Ge=null;typeof ke.foreground=="string"&&(Ge=ke.foreground);let Ae=null;typeof ke.background=="string"&&(Ae=ke.background),ce[pe++]=new P(ke.token||"",be,We,Ge,Ae)}return ce}function T(Me,ce){Me.sort((Pe,$e)=>{const it=u(Pe.token,$e.token);return it!==0?it:Pe.index-$e.index});let pe=0,be="000000",ge="ffffff";for(;Me.length>=1&&Me[0].token==="";){const Pe=Me.shift();Pe.fontStyle!==-1&&(pe=Pe.fontStyle),Pe.foreground!==null&&(be=Pe.foreground),Pe.background!==null&&(ge=Pe.background)}const ke=new d;for(const Pe of ce)ke.getId(Pe);const We=ke.getId(be),Ge=ke.getId(ge),Ae=new w(pe,We,Ge),he=new C(Ae);for(let Pe=0,$e=Me.length;Pe<$e;Pe++){const it=Me[Pe];he.insert(it.token,it.fontStyle,ke.getId(it.foreground),ke.getId(it.background))}return new g(ke,he)}const p=/^#?([0-9A-Fa-f]{6})([0-9A-Fa-f]{2})?$/;class d{constructor(){this._lastColorId=0,this._id2color=[],this._color2id=new Map}getId(ce){if(ce===null)return 0;const pe=ce.match(p);if(!pe)throw new Error("Illegal value for token color: "+ce);ce=pe[1].toUpperCase();let be=this._color2id.get(ce);return be||(be=++this._lastColorId,this._color2id.set(ce,be),this._id2color[be]=K.Q1.fromHex("#"+ce),be)}getColorMap(){return this._id2color.slice(0)}}class g{constructor(ce,pe){this._colorMap=ce,this._root=pe,this._cache=new Map}static createFromRawTokenTheme(ce,pe){return this.createFromParsedTokenTheme(B(ce),pe)}static createFromParsedTokenTheme(ce,pe){return T(ce,pe)}getColorMap(){return this._colorMap.getColorMap()}_match(ce){return this._root.match(ce)}match(ce,pe){let be=this._cache.get(pe);if(typeof be>"u"){const ge=this._match(pe),ke=l(pe);be=(ge.metadata|ke<<8)>>>0,this._cache.set(pe,be)}return(be|ce<<0)>>>0}}const h=/\b(comment|string|regex|regexp)\b/;function l(Me){const ce=Me.match(h);if(!ce)return 0;switch(ce[1]){case"comment":return 1;case"string":return 2;case"regex":return 3;case"regexp":return 3}throw new Error("Unexpected match for standard token type!")}function u(Me,ce){return Me<ce?-1:Me>ce?1:0}class w{constructor(ce,pe,be){this._themeTrieElementRuleBrand=void 0,this._fontStyle=ce,this._foreground=pe,this._background=be,this.metadata=(this._fontStyle<<11|this._foreground<<15|this._background<<24)>>>0}clone(){return new w(this._fontStyle,this._foreground,this._background)}acceptOverwrite(ce,pe,be){ce!==-1&&(this._fontStyle=ce),pe!==0&&(this._foreground=pe),be!==0&&(this._background=be),this.metadata=(this._fontStyle<<11|this._foreground<<15|this._background<<24)>>>0}}class C{constructor(ce){this._themeTrieElementBrand=void 0,this._mainRule=ce,this._children=new Map}match(ce){if(ce==="")return this._mainRule;const pe=ce.indexOf(".");let be,ge;pe===-1?(be=ce,ge=""):(be=ce.substring(0,pe),ge=ce.substring(pe+1));const ke=this._children.get(be);return typeof ke<"u"?ke.match(ge):this._mainRule}insert(ce,pe,be,ge){if(ce===""){this._mainRule.acceptOverwrite(pe,be,ge);return}const ke=ce.indexOf(".");let We,Ge;ke===-1?(We=ce,Ge=""):(We=ce.substring(0,ke),Ge=ce.substring(ke+1));let Ae=this._children.get(We);typeof Ae>"u"&&(Ae=new C(this._mainRule.clone()),this._children.set(We,Ae)),Ae.insert(Ge,pe,be,ge)}}function m(Me){const ce=[];for(let pe=1,be=Me.length;pe<be;pe++){const ge=Me[pe];ce[pe]=`.mtk${pe} { color: ${ge}; }`}return ce.push(".mtki { font-style: italic; }"),ce.push(".mtkb { font-weight: bold; }"),ce.push(".mtku { text-decoration: underline; text-underline-position: under; }"),ce.push(".mtks { text-decoration: line-through; }"),ce.push(".mtks.mtku { text-decoration: underline line-through; text-underline-position: under; }"),ce.join(` `)}var v=y(48295),k=y(4874);const D={base:"vs",inherit:!1,rules:[{token:"",foreground:"000000",background:"fffffe"},{token:"invalid",foreground:"cd3131"},{token:"emphasis",fontStyle:"italic"},{token:"strong",fontStyle:"bold"},{token:"variable",foreground:"001188"},{token:"variable.predefined",foreground:"4864AA"},{token:"constant",foreground:"dd0000"},{token:"comment",foreground:"008000"},{token:"number",foreground:"098658"},{token:"number.hex",foreground:"3030c0"},{token:"regexp",foreground:"800000"},{token:"annotation",foreground:"808080"},{token:"type",foreground:"008080"},{token:"delimiter",foreground:"000000"},{token:"delimiter.html",foreground:"383838"},{token:"delimiter.xml",foreground:"0000FF"},{token:"tag",foreground:"800000"},{token:"tag.id.pug",foreground:"4F76AC"},{token:"tag.class.pug",foreground:"4F76AC"},{token:"meta.scss",foreground:"800000"},{token:"metatag",foreground:"e00000"},{token:"metatag.content.html",foreground:"FF0000"},{token:"metatag.html",foreground:"808080"},{token:"metatag.xml",foreground:"808080"},{token:"metatag.php",fontStyle:"bold"},{token:"key",foreground:"863B00"},{token:"string.key.json",foreground:"A31515"},{token:"string.value.json",foreground:"0451A5"},{token:"attribute.name",foreground:"FF0000"},{token:"attribute.value",foreground:"0451A5"},{token:"attribute.value.number",foreground:"098658"},{token:"attribute.value.unit",foreground:"098658"},{token:"attribute.value.html",foreground:"0000FF"},{token:"attribute.value.xml",foreground:"0000FF"},{token:"string",foreground:"A31515"},{token:"string.html",foreground:"0000FF"},{token:"string.sql",foreground:"FF0000"},{token:"string.yaml",foreground:"0451A5"},{token:"keyword",foreground:"0000FF"},{token:"keyword.json",foreground:"0451A5"},{token:"keyword.flow",foreground:"AF00DB"},{token:"keyword.flow.scss",foreground:"0000FF"},{token:"operator.scss",foreground:"666666"},{token:"operator.sql",foreground:"778899"},{token:"operator.swift",foreground:"666666"},{token:"predefined.sql",foreground:"C700C7"}],colors:{[k.YtV]:"#FFFFFE",[k.By2]:"#000000",[k.tan]:"#E5EBF1",[v.v0]:"#D3D3D3",[v.fj]:"#939393",[k.QwA]:"#ADD6FF4D"}},x={base:"vs-dark",inherit:!1,rules:[{token:"",foreground:"D4D4D4",background:"1E1E1E"},{token:"invalid",foreground:"f44747"},{token:"emphasis",fontStyle:"italic"},{token:"strong",fontStyle:"bold"},{token:"variable",foreground:"74B0DF"},{token:"variable.predefined",foreground:"4864AA"},{token:"variable.parameter",foreground:"9CDCFE"},{token:"constant",foreground:"569CD6"},{token:"comment",foreground:"608B4E"},{token:"number",foreground:"B5CEA8"},{token:"number.hex",foreground:"5BB498"},{token:"regexp",foreground:"B46695"},{token:"annotation",foreground:"cc6666"},{token:"type",foreground:"3DC9B0"},{token:"delimiter",foreground:"DCDCDC"},{token:"delimiter.html",foreground:"808080"},{token:"delimiter.xml",foreground:"808080"},{token:"tag",foreground:"569CD6"},{token:"tag.id.pug",foreground:"4F76AC"},{token:"tag.class.pug",foreground:"4F76AC"},{token:"meta.scss",foreground:"A79873"},{token:"meta.tag",foreground:"CE9178"},{token:"metatag",foreground:"DD6A6F"},{token:"metatag.content.html",foreground:"9CDCFE"},{token:"metatag.html",foreground:"569CD6"},{token:"metatag.xml",foreground:"569CD6"},{token:"metatag.php",fontStyle:"bold"},{token:"key",foreground:"9CDCFE"},{token:"string.key.json",foreground:"9CDCFE"},{token:"string.value.json",foreground:"CE9178"},{token:"attribute.name",foreground:"9CDCFE"},{token:"attribute.value",foreground:"CE9178"},{token:"attribute.value.number.css",foreground:"B5CEA8"},{token:"attribute.value.unit.css",foreground:"B5CEA8"},{token:"attribute.value.hex.css",foreground:"D4D4D4"},{token:"string",foreground:"CE9178"},{token:"string.sql",foreground:"FF0000"},{token:"keyword",foreground:"569CD6"},{token:"keyword.flow",foreground:"C586C0"},{token:"keyword.json",foreground:"CE9178"},{token:"keyword.flow.scss",foreground:"569CD6"},{token:"operator.scss",foreground:"909090"},{token:"operator.sql",foreground:"778899"},{token:"operator.swift",foreground:"909090"},{token:"predefined.sql",foreground:"FF00FF"}],colors:{[k.YtV]:"#1E1E1E",[k.By2]:"#D4D4D4",[k.tan]:"#3A3D41",[v.v0]:"#404040",[v.fj]:"#707070",[k.QwA]:"#ADD6FF26"}},A={base:"hc-black",inherit:!1,rules:[{token:"",foreground:"FFFFFF",background:"000000"},{token:"invalid",foreground:"f44747"},{token:"emphasis",fontStyle:"italic"},{token:"strong",fontStyle:"bold"},{token:"variable",foreground:"1AEBFF"},{token:"variable.parameter",foreground:"9CDCFE"},{token:"constant",foreground:"569CD6"},{token:"comment",foreground:"608B4E"},{token:"number",foreground:"FFFFFF"},{token:"regexp",foreground:"C0C0C0"},{token:"annotation",foreground:"569CD6"},{token:"type",foreground:"3DC9B0"},{token:"delimiter",foreground:"FFFF00"},{token:"delimiter.html",foreground:"FFFF00"},{token:"tag",foreground:"569CD6"},{token:"tag.id.pug",foreground:"4F76AC"},{token:"tag.class.pug",foreground:"4F76AC"},{token:"meta",foreground:"D4D4D4"},{token:"meta.tag",foreground:"CE9178"},{token:"metatag",foreground:"569CD6"},{token:"metatag.content.html",foreground:"1AEBFF"},{token:"metatag.html",foreground:"569CD6"},{token:"metatag.xml",foreground:"569CD6"},{token:"metatag.php",fontStyle:"bold"},{token:"key",foreground:"9CDCFE"},{token:"string.key",foreground:"9CDCFE"},{token:"string.value",foreground:"CE9178"},{token:"attribute.name",foreground:"569CD6"},{token:"attribute.value",foreground:"3FF23F"},{token:"string",foreground:"CE9178"},{token:"string.sql",foreground:"FF0000"},{token:"keyword",foreground:"569CD6"},{token:"keyword.flow",foreground:"C586C0"},{token:"operator.sql",foreground:"778899"},{token:"operator.swift",foreground:"909090"},{token:"predefined.sql",foreground:"FF00FF"}],colors:{[k.YtV]:"#000000",[k.By2]:"#FFFFFF",[v.v0]:"#FFFFFF",[v.fj]:"#FFFFFF"}},W={base:"hc-light",inherit:!1,rules:[{token:"",foreground:"292929",background:"FFFFFF"},{token:"invalid",foreground:"B5200D"},{token:"emphasis",fontStyle:"italic"},{token:"strong",fontStyle:"bold"},{token:"variable",foreground:"264F70"},{token:"variable.predefined",foreground:"4864AA"},{token:"constant",foreground:"dd0000"},{token:"comment",foreground:"008000"},{token:"number",foreground:"098658"},{token:"number.hex",foreground:"3030c0"},{token:"regexp",foreground:"800000"},{token:"annotation",foreground:"808080"},{token:"type",foreground:"008080"},{token:"delimiter",foreground:"000000"},{token:"delimiter.html",foreground:"383838"},{token:"tag",foreground:"800000"},{token:"tag.id.pug",foreground:"4F76AC"},{token:"tag.class.pug",foreground:"4F76AC"},{token:"meta.scss",foreground:"800000"},{token:"metatag",foreground:"e00000"},{token:"metatag.content.html",foreground:"B5200D"},{token:"metatag.html",foreground:"808080"},{token:"metatag.xml",foreground:"808080"},{token:"metatag.php",fontStyle:"bold"},{token:"key",foreground:"863B00"},{token:"string.key.json",foreground:"A31515"},{token:"string.value.json",foreground:"0451A5"},{token:"attribute.name",foreground:"264F78"},{token:"attribute.value",foreground:"0451A5"},{token:"string",foreground:"A31515"},{token:"string.sql",foreground:"B5200D"},{token:"keyword",foreground:"0000FF"},{token:"keyword.flow",foreground:"AF00DB"},{token:"operator.sql",foreground:"778899"},{token:"operator.swift",foreground:"666666"},{token:"predefined.sql",foreground:"C700C7"}],colors:{[k.YtV]:"#FFFFFF",[k.By2]:"#292929",[v.v0]:"#292929",[v.fj]:"#292929"}};var Y=y(67167),ne=y(89044),j=y(10998),Q=y(89563),X=y(11210);function R(Me){const ce=new $.vl,pe=(0,X.HT)();return pe.onDidChange(()=>ce.fire()),Me?.onDidProductIconThemeChange(()=>ce.fire()),{onDidChange:ce.event,getCSS(){const be=Me?Me.getProductIconTheme():new H,ge={},ke=Ge=>{const Ae=be.getIcon(Ge);if(!Ae)return;const he=Ae.font;return he?(ge[he.id]=he.definition,`.codicon-${Ge.id}:before { content: '${Ae.fontCharacter}'; font-family: ${(0,b.yt)(he.id)}; }`):`.codicon-${Ge.id}:before { content: '${Ae.fontCharacter}'; }`},We=[];for(const Ge of pe.getIcons()){const Ae=ke(Ge);Ae&&We.push(Ae)}for(const Ge in ge){const Ae=ge[Ge],he=Ae.weight?`font-weight: ${Ae.weight};`:"",Pe=Ae.style?`font-style: ${Ae.style};`:"",$e=Ae.src.map(it=>`${(0,b.Tf)(it.location)} format('${it.format}')`).join(", ");We.push(`@font-face { src: ${$e}; font-family: ${(0,b.yt)(Ge)};${he}${Pe} font-display: block; }`)}return We.join(` `)}}}class H{getIcon(ce){const pe=(0,X.HT)();let be=ce.defaults;for(;ne.L0.isThemeIcon(be);){const ge=pe.getIcon(be.id);if(!ge)return;be=ge.defaults}return be}}const Z="vs",N="vs-dark",G="hc-black",O="hc-light",te=Y.O.as(k.FdG.ColorContribution),oe=Y.O.as(ne.Fd.ThemingContribution);class ue{constructor(ce,pe){this.semanticHighlighting=!1,this.themeData=pe;const be=pe.base;ce.length>0?(E(ce)?this.id=ce:this.id=be+" "+ce,this.themeName=ce):(this.id=be,this.themeName=be),this.colors=null,this.defaultColors=Object.create(null),this._tokenTheme=null}get base(){return this.themeData.base}notifyBaseUpdated(){this.themeData.inherit&&(this.colors=null,this._tokenTheme=null)}getColors(){if(!this.colors){const ce=new Map;for(const pe in this.themeData.colors)ce.set(pe,K.Q1.fromHex(this.themeData.colors[pe]));if(this.themeData.inherit){const pe=Qe(this.themeData.base);for(const be in pe.colors)ce.has(be)||ce.set(be,K.Q1.fromHex(pe.colors[be]))}this.colors=ce}return this.colors}getColor(ce,pe){const be=this.getColors().get(ce);if(be)return be;if(pe!==!1)return this.getDefault(ce)}getDefault(ce){let pe=this.defaultColors[ce];return pe||(pe=te.resolveDefaultColor(ce,this),this.defaultColors[ce]=pe,pe)}defines(ce){return Object.prototype.hasOwnProperty.call(this.getColors(),ce)}get type(){switch(this.base){case Z:return Q.zM.LIGHT;case G:return Q.zM.HIGH_CONTRAST_DARK;case O:return Q.zM.HIGH_CONTRAST_LIGHT;default:return Q.zM.DARK}}get tokenTheme(){if(!this._tokenTheme){let ce=[],pe=[];if(this.themeData.inherit){const ke=Qe(this.themeData.base);ce=ke.rules,ke.encodedTokensColors&&(pe=ke.encodedTokensColors)}const be=this.themeData.colors["editor.foreground"],ge=this.themeData.colors["editor.background"];if(be||ge){const ke={token:""};be&&(ke.foreground=be),ge&&(ke.background=ge),ce.push(ke)}ce=ce.concat(this.themeData.rules),this.themeData.encodedTokensColors&&(pe=this.themeData.encodedTokensColors),this._tokenTheme=g.createFromRawTokenTheme(ce,pe)}return this._tokenTheme}getTokenStyleMetadata(ce,pe,be){const ke=this.tokenTheme._match([ce].concat(pe).join(".")).metadata,We=U.x.getForeground(ke),Ge=U.x.getFontStyle(ke);return{foreground:We,italic:!!(Ge&1),bold:!!(Ge&2),underline:!!(Ge&4),strikethrough:!!(Ge&8)}}}function E(Me){return Me===Z||Me===N||Me===G||Me===O}function Qe(Me){switch(Me){case Z:return D;case N:return x;case G:return A;case O:return W}}function Ke(Me){const ce=Qe(Me);return new ue(Me,ce)}class Se extends j.jG{constructor(){super(),this._onColorThemeChange=this._register(new $.vl),this.onDidColorThemeChange=this._onColorThemeChange.event,this._onProductIconThemeChange=this._register(new $.vl),this.onDidProductIconThemeChange=this._onProductIconThemeChange.event,this._environment=Object.create(null),this._builtInProductIconTheme=new H,this._autoDetectHighContrast=!0,this._knownThemes=new Map,this._knownThemes.set(Z,Ke(Z)),this._knownThemes.set(N,Ke(N)),this._knownThemes.set(G,Ke(G)),this._knownThemes.set(O,Ke(O));const ce=R(this);this._codiconCSS=ce.getCSS(),this._themeCSS="",this._allCSS=`${this._codiconCSS} ${this._themeCSS}`,this._globalStyleElement=null,this._styleElements=[],this._colorMapOverride=null,this.setTheme(Z),this._onOSSchemeChanged(),ce.onDidChange(()=>{this._codiconCSS=ce.getCSS(),this._updateCSS()}),(0,o.addMatchMediaChangeListener)("(forced-colors: active)",()=>{this._onOSSchemeChanged()})}registerEditorContainer(ce){return b.Cl(ce)?this._registerShadowDomContainer(ce):this._registerRegularEditorContainer()}_registerRegularEditorContainer(){return this._globalStyleElement||(this._globalStyleElement=b.li(),this._globalStyleElement.className="monaco-colors",this._globalStyleElement.textContent=this._allCSS,this._styleElements.push(this._globalStyleElement)),j.jG.None}_registerShadowDomContainer(ce){const pe=b.li(ce);return pe.className="monaco-colors",pe.textContent=this._allCSS,this._styleElements.push(pe),{dispose:()=>{for(let be=0;be<this._styleElements.length;be++)if(this._styleElements[be]===pe){this._styleElements.splice(be,1);return}}}}defineTheme(ce,pe){if(!/^[a-z0-9\-]+$/i.test(ce))throw new Error("Illegal theme name!");if(!E(pe.base)&&!E(ce))throw new Error("Illegal theme base!");this._knownThemes.set(ce,new ue(ce,pe)),E(ce)&&this._knownThemes.forEach(be=>{be.base===ce&&be.notifyBaseUpdated()}),this._theme.themeName===ce&&this.setTheme(ce)}getColorTheme(){return this._theme}setColorMapOverride(ce){this._colorMapOverride=ce,this._updateThemeOrColorMap()}setTheme(ce){let pe;this._knownThemes.has(ce)?pe=this._knownThemes.get(ce):pe=this._knownThemes.get(Z),this._updateActualTheme(pe)}_updateActualTheme(ce){!ce||this._theme===ce||(this._theme=ce,this._updateThemeOrColorMap())}_onOSSchemeChanged(){if(this._autoDetectHighContrast){const ce=window.matchMedia("(forced-colors: active)").matches;if(ce!==(0,Q.Bb)(this._theme.type)){let pe;(0,Q.HD)(this._theme.type)?pe=ce?G:N:pe=ce?O:Z,this._updateActualTheme(this._knownThemes.get(pe))}}}setAutoDetectHighContrast(ce){this._autoDetectHighContrast=ce,this._onOSSchemeChanged()}_updateThemeOrColorMap(){const ce=[],pe={},be={addRule:We=>{pe[We]||(ce.push(We),pe[We]=!0)}};oe.getThemingParticipants().forEach(We=>We(this._theme,be,this._environment));const ge=[];for(const We of te.getColors()){const Ge=this._theme.getColor(We.id,!0);Ge&&ge.push(`${(0,k.Bbc)(We.id)}: ${Ge.toString()};`)}be.addRule(`.monaco-editor { ${ge.join(` `)} }`);const ke=this._colorMapOverride||this._theme.tokenTheme.getColorMap();be.addRule(m(ke)),this._themeCSS=ce.join(` `),this._updateCSS(),L.dG.setColorMap(ke),this._onColorThemeChange.fire(this._theme)}_updateCSS(){this._allCSS=`${this._codiconCSS} ${this._themeCSS}`,this._styleElements.forEach(ce=>ce.textContent=this._allCSS)}getFileIconTheme(){return{hasFileIcons:!1,hasFolderIcons:!1,hidesExplorerArrows:!1}}getProductIconTheme(){return this._builtInProductIconTheme}}},93702:(rt,ye,y)=>{y.d(ye,{L:()=>K});var b=y(15365),o=y(50442);class K extends o.Q{constructor(L,U,P,B){super(L,U,P,B),this.selectionStartLineNumber=L,this.selectionStartColumn=U,this.positionLineNumber=P,this.positionColumn=B}toString(){return"["+this.selectionStartLineNumber+","+this.selectionStartColumn+" -> "+this.positionLineNumber+","+this.positionColumn+"]"}equalsSelection(L){return K.selectionsEqual(this,L)}static selectionsEqual(L,U){return L.selectionStartLineNumber===U.selectionStartLineNumber&&L.selectionStartColumn===U.selectionStartColumn&&L.positionLineNumber===U.positionLineNumber&&L.positionColumn===U.positionColumn}getDirection(){return this.selectionStartLineNumber===this.startLineNumber&&this.selectionStartColumn===this.startColumn?0:1}setEndPosition(L,U){return this.getDirection()===0?new K(this.startLineNumber,this.startColumn,L,U):new K(L,U,this.startLineNumber,this.startColumn)}getPosition(){return new b.y(this.positionLineNumber,this.positionColumn)}getSelectionStart(){return new b.y(this.selectionStartLineNumber,this.selectionStartColumn)}setStartPosition(L,U){return this.getDirection()===0?new K(L,U,this.endLineNumber,this.endColumn):new K(this.endLineNumber,this.endColumn,L,U)}static fromPositions(L,U=L){return new K(L.lineNumber,L.column,U.lineNumber,U.column)}static fromRange(L,U){return U===0?new K(L.startLineNumber,L.startColumn,L.endLineNumber,L.endColumn):new K(L.endLineNumber,L.endColumn,L.startLineNumber,L.startColumn)}static liftSelection(L){return new K(L.selectionStartLineNumber,L.selectionStartColumn,L.positionLineNumber,L.positionColumn)}static selectionsArrEqual(L,U){if(L&&!U||!L&&U)return!1;if(!L&&!U)return!0;if(L.length!==U.length)return!1;for(let P=0,B=L.length;P<B;P++)if(!this.selectionsEqual(L[P],U[P]))return!1;return!0}static isISelection(L){return L&&typeof L.selectionStartLineNumber=="number"&&typeof L.selectionStartColumn=="number"&&typeof L.positionLineNumber=="number"&&typeof L.positionColumn=="number"}static createWithDirection(L,U,P,B,T){return T===0?new K(L,U,P,B):new K(P,B,L,U)}}},94327:(rt,ye,y)=>{y.d(ye,{AL:()=>B,D7:()=>l,EM:()=>g,MB:()=>P,M_:()=>$,Qg:()=>p,aD:()=>T,cU:()=>L,dz:()=>K,iH:()=>d});class b{constructor(){this.listeners=[],this.unexpectedErrorHandler=function(w){setTimeout(()=>{throw w.stack?h.isErrorNoTelemetry(w)?new h(w.message+` `+w.stack):new Error(w.message+` `+w.stack):w},0)}}emit(w){this.listeners.forEach(C=>{C(w)})}onUnexpectedError(w){this.unexpectedErrorHandler(w),this.emit(w)}onUnexpectedExternalError(w){this.unexpectedErrorHandler(w)}}const o=new b;function K(u){P(u)||o.onUnexpectedError(u)}function $(u){P(u)||o.onUnexpectedExternalError(u)}function L(u){if(u instanceof Error){const{name:w,message:C}=u,m=u.stacktrace||u.stack;return{$isError:!0,name:w,message:C,stack:m,noTelemetry:h.isErrorNoTelemetry(u)}}return u}const U="Canceled";function P(u){return u instanceof B?!0:u instanceof Error&&u.name===U&&u.message===U}class B extends Error{constructor(){super(U),this.name=this.message}}function T(){const u=new Error(U);return u.name=u.message,u}function p(u){return u?new Error(`Illegal argument: ${u}`):new Error("Illegal argument")}function d(u){return u?new Error(`Illegal state: ${u}`):new Error("Illegal state")}class g extends Error{constructor(w){super("NotSupported"),w&&(this.message=w)}}class h extends Error{constructor(w){super(w),this.name="ErrorNoTelemetry"}static fromError(w){if(w instanceof h)return w;const C=new h;return C.message=w.message,C.stack=w.stack,C}static isErrorNoTelemetry(w){return w.name==="ErrorNoTelemetry"}}class l extends Error{constructor(w){super(w||"An unexpected bug occurred."),Object.setPrototypeOf(this,l.prototype);debugger}}},94513:(rt,ye,y)=>{y.d(ye,{yE:()=>$});var b=y(2106),o=y(10998);class K{constructor(g,h,l,u,w,C,m){this._forceIntegerValues=g,this._scrollStateBrand=void 0,this._forceIntegerValues&&(h=h|0,l=l|0,u=u|0,w=w|0,C=C|0,m=m|0),this.rawScrollLeft=u,this.rawScrollTop=m,h<0&&(h=0),u+h>l&&(u=l-h),u<0&&(u=0),w<0&&(w=0),m+w>C&&(m=C-w),m<0&&(m=0),this.width=h,this.scrollWidth=l,this.scrollLeft=u,this.height=w,this.scrollHeight=C,this.scrollTop=m}equals(g){return this.rawScrollLeft===g.rawScrollLeft&&this.rawScrollTop===g.rawScrollTop&&this.width===g.width&&this.scrollWidth===g.scrollWidth&&this.scrollLeft===g.scrollLeft&&this.height===g.height&&this.scrollHeight===g.scrollHeight&&this.scrollTop===g.scrollTop}withScrollDimensions(g,h){return new K(this._forceIntegerValues,typeof g.width<"u"?g.width:this.width,typeof g.scrollWidth<"u"?g.scrollWidth:this.scrollWidth,h?this.rawScrollLeft:this.scrollLeft,typeof g.height<"u"?g.height:this.height,typeof g.scrollHeight<"u"?g.scrollHeight:this.scrollHeight,h?this.rawScrollTop:this.scrollTop)}withScrollPosition(g){return new K(this._forceIntegerValues,this.width,this.scrollWidth,typeof g.scrollLeft<"u"?g.scrollLeft:this.rawScrollLeft,this.height,this.scrollHeight,typeof g.scrollTop<"u"?g.scrollTop:this.rawScrollTop)}createScrollEvent(g,h){const l=this.width!==g.width,u=this.scrollWidth!==g.scrollWidth,w=this.scrollLeft!==g.scrollLeft,C=this.height!==g.height,m=this.scrollHeight!==g.scrollHeight,v=this.scrollTop!==g.scrollTop;return{inSmoothScrolling:h,oldWidth:g.width,oldScrollWidth:g.scrollWidth,oldScrollLeft:g.scrollLeft,width:this.width,scrollWidth:this.scrollWidth,scrollLeft:this.scrollLeft,oldHeight:g.height,oldScrollHeight:g.scrollHeight,oldScrollTop:g.scrollTop,height:this.height,scrollHeight:this.scrollHeight,scrollTop:this.scrollTop,widthChanged:l,scrollWidthChanged:u,scrollLeftChanged:w,heightChanged:C,scrollHeightChanged:m,scrollTopChanged:v}}}class $ extends o.jG{constructor(g){super(),this._scrollableBrand=void 0,this._onScroll=this._register(new b.vl),this.onScroll=this._onScroll.event,this._smoothScrollDuration=g.smoothScrollDuration,this._scheduleAtNextAnimationFrame=g.scheduleAtNextAnimationFrame,this._state=new K(g.forceIntegerValues,0,0,0,0,0,0),this._smoothScrolling=null}dispose(){this._smoothScrolling&&(this._smoothScrolling.dispose(),this._smoothScrolling=null),super.dispose()}setSmoothScrollDuration(g){this._smoothScrollDuration=g}validateScrollPosition(g){return this._state.withScrollPosition(g)}getScrollDimensions(){return this._state}setScrollDimensions(g,h){var l;const u=this._state.withScrollDimensions(g,h);this._setState(u,!!this._smoothScrolling),(l=this._smoothScrolling)===null||l===void 0||l.acceptScrollDimensions(this._state)}getFutureScrollPosition(){return this._smoothScrolling?this._smoothScrolling.to:this._state}getCurrentScrollPosition(){return this._state}setScrollPositionNow(g){const h=this._state.withScrollPosition(g);this._smoothScrolling&&(this._smoothScrolling.dispose(),this._smoothScrolling=null),this._setState(h,!1)}setScrollPositionSmooth(g,h){if(this._smoothScrollDuration===0)return this.setScrollPositionNow(g);if(this._smoothScrolling){g={scrollLeft:typeof g.scrollLeft>"u"?this._smoothScrolling.to.scrollLeft:g.scrollLeft,scrollTop:typeof g.scrollTop>"u"?this._smoothScrolling.to.scrollTop:g.scrollTop};const l=this._state.withScrollPosition(g);if(this._smoothScrolling.to.scrollLeft===l.scrollLeft&&this._smoothScrolling.to.scrollTop===l.scrollTop)return;let u;h?u=new B(this._smoothScrolling.from,l,this._smoothScrolling.startTime,this._smoothScrolling.duration):u=this._smoothScrolling.combine(this._state,l,this._smoothScrollDuration),this._smoothScrolling.dispose(),this._smoothScrolling=u}else{const l=this._state.withScrollPosition(g);this._smoothScrolling=B.start(this._state,l,this._smoothScrollDuration)}this._smoothScrolling.animationFrameDisposable=this._scheduleAtNextAnimationFrame(()=>{this._smoothScrolling&&(this._smoothScrolling.animationFrameDisposable=null,this._performSmoothScrolling())})}_performSmoothScrolling(){if(!this._smoothScrolling)return;const g=this._smoothScrolling.tick(),h=this._state.withScrollPosition(g);if(this._setState(h,!0),!!this._smoothScrolling){if(g.isDone){this._smoothScrolling.dispose(),this._smoothScrolling=null;return}this._smoothScrolling.animationFrameDisposable=this._scheduleAtNextAnimationFrame(()=>{this._smoothScrolling&&(this._smoothScrolling.animationFrameDisposable=null,this._performSmoothScrolling())})}}_setState(g,h){const l=this._state;l.equals(g)||(this._state=g,this._onScroll.fire(this._state.createScrollEvent(l,h)))}}class L{constructor(g,h,l){this.scrollLeft=g,this.scrollTop=h,this.isDone=l}}function U(d,g){const h=g-d;return function(l){return d+h*p(l)}}function P(d,g,h){return function(l){return l<h?d(l/h):g((l-h)/(1-h))}}class B{constructor(g,h,l,u){this.from=g,this.to=h,this.duration=u,this.startTime=l,this.animationFrameDisposable=null,this._initAnimations()}_initAnimations(){this.scrollLeft=this._initAnimation(this.from.scrollLeft,this.to.scrollLeft,this.to.width),this.scrollTop=this._initAnimation(this.from.scrollTop,this.to.scrollTop,this.to.height)}_initAnimation(g,h,l){if(Math.abs(g-h)>2.5*l){let w,C;return g<h?(w=g+.75*l,C=h-.75*l):(w=g-.75*l,C=h+.75*l),P(U(g,w),U(C,h),.33)}return U(g,h)}dispose(){this.animationFrameDisposable!==null&&(this.animationFrameDisposable.dispose(),this.animationFrameDisposable=null)}acceptScrollDimensions(g){this.to=g.withScrollPosition(this.to),this._initAnimations()}tick(){return this._tick(Date.now())}_tick(g){const h=(g-this.startTime)/this.duration;if(h<1){const l=this.scrollLeft(h),u=this.scrollTop(h);return new L(l,u,!1)}return new L(this.to.scrollLeft,this.to.scrollTop,!0)}combine(g,h,l){return B.start(g,h,l)}static start(g,h,l){l=l+10;const u=Date.now()-10;return new B(g,h,u,l)}}function T(d){return Math.pow(d,3)}function p(d){return 1-T(1-d)}},94664:(rt,ye,y)=>{y.d(ye,{n:()=>b,r:()=>o});class b{constructor($){this._prefix=$,this._lastId=0}nextId(){return this._prefix+ ++this._lastId}}const o=new b("id#")},94901:(rt,ye,y)=>{y.d(ye,{$J:()=>$,Q1:()=>L,bU:()=>o});function b(U,P){const B=Math.pow(10,P);return Math.round(U*B)/B}class o{constructor(P,B,T,p=1){this._rgbaBrand=void 0,this.r=Math.min(255,Math.max(0,P))|0,this.g=Math.min(255,Math.max(0,B))|0,this.b=Math.min(255,Math.max(0,T))|0,this.a=b(Math.max(Math.min(1,p),0),3)}static equals(P,B){return P.r===B.r&&P.g===B.g&&P.b===B.b&&P.a===B.a}}class K{constructor(P,B,T,p){this._hslaBrand=void 0,this.h=Math.max(Math.min(360,P),0)|0,this.s=b(Math.max(Math.min(1,B),0),3),this.l=b(Math.max(Math.min(1,T),0),3),this.a=b(Math.max(Math.min(1,p),0),3)}static equals(P,B){return P.h===B.h&&P.s===B.s&&P.l===B.l&&P.a===B.a}static fromRGBA(P){const B=P.r/255,T=P.g/255,p=P.b/255,d=P.a,g=Math.max(B,T,p),h=Math.min(B,T,p);let l=0,u=0;const w=(h+g)/2,C=g-h;if(C>0){switch(u=Math.min(w<=.5?C/(2*w):C/(2-2*w),1),g){case B:l=(T-p)/C+(T<p?6:0);break;case T:l=(p-B)/C+2;break;case p:l=(B-T)/C+4;break}l*=60,l=Math.round(l)}return new K(l,u,w,d)}static _hue2rgb(P,B,T){return T<0&&(T+=1),T>1&&(T-=1),T<1/6?P+(B-P)*6*T:T<1/2?B:T<2/3?P+(B-P)*(2/3-T)*6:P}static toRGBA(P){const B=P.h/360,{s:T,l:p,a:d}=P;let g,h,l;if(T===0)g=h=l=p;else{const u=p<.5?p*(1+T):p+T-p*T,w=2*p-u;g=K._hue2rgb(w,u,B+1/3),h=K._hue2rgb(w,u,B),l=K._hue2rgb(w,u,B-1/3)}return new o(Math.round(g*255),Math.round(h*255),Math.round(l*255),d)}}class ${constructor(P,B,T,p){this._hsvaBrand=void 0,this.h=Math.max(Math.min(360,P),0)|0,this.s=b(Math.max(Math.min(1,B),0),3),this.v=b(Math.max(Math.min(1,T),0),3),this.a=b(Math.max(Math.min(1,p),0),3)}static equals(P,B){return P.h===B.h&&P.s===B.s&&P.v===B.v&&P.a===B.a}static fromRGBA(P){const B=P.r/255,T=P.g/255,p=P.b/255,d=Math.max(B,T,p),g=Math.min(B,T,p),h=d-g,l=d===0?0:h/d;let u;return h===0?u=0:d===B?u=((T-p)/h%6+6)%6:d===T?u=(p-B)/h+2:u=(B-T)/h+4,new $(Math.round(u*60),l,d,P.a)}static toRGBA(P){const{h:B,s:T,v:p,a:d}=P,g=p*T,h=g*(1-Math.abs(B/60%2-1)),l=p-g;let[u,w,C]=[0,0,0];return B<60?(u=g,w=h):B<120?(u=h,w=g):B<180?(w=g,C=h):B<240?(w=h,C=g):B<300?(u=h,C=g):B<=360&&(u=g,C=h),u=Math.round((u+l)*255),w=Math.round((w+l)*255),C=Math.round((C+l)*255),new o(u,w,C,d)}}class L{constructor(P){if(P)if(P instanceof o)this.rgba=P;else if(P instanceof K)this._hsla=P,this.rgba=K.toRGBA(P);else if(P instanceof $)this._hsva=P,this.rgba=$.toRGBA(P);else throw new Error("Invalid color ctor argument");else throw new Error("Color needs a value")}static fromHex(P){return L.Format.CSS.parseHex(P)||L.red}get hsla(){return this._hsla?this._hsla:K.fromRGBA(this.rgba)}get hsva(){return this._hsva?this._hsva:$.fromRGBA(this.rgba)}equals(P){return!!P&&o.equals(this.rgba,P.rgba)&&K.equals(this.hsla,P.hsla)&&$.equals(this.hsva,P.hsva)}getRelativeLuminance(){const P=L._relativeLuminanceForComponent(this.rgba.r),B=L._relativeLuminanceForComponent(this.rgba.g),T=L._relativeLuminanceForComponent(this.rgba.b),p=.2126*P+.7152*B+.0722*T;return b(p,4)}static _relativeLuminanceForComponent(P){const B=P/255;return B<=.03928?B/12.92:Math.pow((B+.055)/1.055,2.4)}isLighter(){return(this.rgba.r*299+this.rgba.g*587+this.rgba.b*114)/1e3>=128}isLighterThan(P){const B=this.getRelativeLuminance(),T=P.getRelativeLuminance();return B>T}isDarkerThan(P){const B=this.getRelativeLuminance(),T=P.getRelativeLuminance();return B<T}lighten(P){return new L(new K(this.hsla.h,this.hsla.s,this.hsla.l+this.hsla.l*P,this.hsla.a))}darken(P){return new L(new K(this.hsla.h,this.hsla.s,this.hsla.l-this.hsla.l*P,this.hsla.a))}transparent(P){const{r:B,g:T,b:p,a:d}=this.rgba;return new L(new o(B,T,p,d*P))}isTransparent(){return this.rgba.a===0}isOpaque(){return this.rgba.a===1}opposite(){return new L(new o(255-this.rgba.r,255-this.rgba.g,255-this.rgba.b,this.rgba.a))}toString(){return this._toString||(this._toString=L.Format.CSS.format(this)),this._toString}static getLighterColor(P,B,T){if(P.isLighterThan(B))return P;T=T||.5;const p=P.getRelativeLuminance(),d=B.getRelativeLuminance();return T=T*(d-p)/d,P.lighten(T)}static getDarkerColor(P,B,T){if(P.isDarkerThan(B))return P;T=T||.5;const p=P.getRelativeLuminance(),d=B.getRelativeLuminance();return T=T*(p-d)/p,P.darken(T)}}L.white=new L(new o(255,255,255,1)),L.black=new L(new o(0,0,0,1)),L.red=new L(new o(255,0,0,1)),L.blue=new L(new o(0,0,255,1)),L.green=new L(new o(0,255,0,1)),L.cyan=new L(new o(0,255,255,1)),L.lightgrey=new L(new o(211,211,211,1)),L.transparent=new L(new o(0,0,0,0)),function(U){let P;(function(B){let T;(function(p){function d(D){return D.rgba.a===1?`rgb(${D.rgba.r}, ${D.rgba.g}, ${D.rgba.b})`:U.Format.CSS.formatRGBA(D)}p.formatRGB=d;function g(D){return`rgba(${D.rgba.r}, ${D.rgba.g}, ${D.rgba.b}, ${+D.rgba.a.toFixed(2)})`}p.formatRGBA=g;function h(D){return D.hsla.a===1?`hsl(${D.hsla.h}, ${(D.hsla.s*100).toFixed(2)}%, ${(D.hsla.l*100).toFixed(2)}%)`:U.Format.CSS.formatHSLA(D)}p.formatHSL=h;function l(D){return`hsla(${D.hsla.h}, ${(D.hsla.s*100).toFixed(2)}%, ${(D.hsla.l*100).toFixed(2)}%, ${D.hsla.a.toFixed(2)})`}p.formatHSLA=l;function u(D){const x=D.toString(16);return x.length!==2?"0"+x:x}function w(D){return`#${u(D.rgba.r)}${u(D.rgba.g)}${u(D.rgba.b)}`}p.formatHex=w;function C(D,x=!1){return x&&D.rgba.a===1?U.Format.CSS.formatHex(D):`#${u(D.rgba.r)}${u(D.rgba.g)}${u(D.rgba.b)}${u(Math.round(D.rgba.a*255))}`}p.formatHexA=C;function m(D){return D.isOpaque()?U.Format.CSS.formatHex(D):U.Format.CSS.formatRGBA(D)}p.format=m;function v(D){const x=D.length;if(x===0||D.charCodeAt(0)!==35)return null;if(x===7){const A=16*k(D.charCodeAt(1))+k(D.charCodeAt(2)),W=16*k(D.charCodeAt(3))+k(D.charCodeAt(4)),Y=16*k(D.charCodeAt(5))+k(D.charCodeAt(6));return new U(new o(A,W,Y,1))}if(x===9){const A=16*k(D.charCodeAt(1))+k(D.charCodeAt(2)),W=16*k(D.charCodeAt(3))+k(D.charCodeAt(4)),Y=16*k(D.charCodeAt(5))+k(D.charCodeAt(6)),ne=16*k(D.charCodeAt(7))+k(D.charCodeAt(8));return new U(new o(A,W,Y,ne/255))}if(x===4){const A=k(D.charCodeAt(1)),W=k(D.charCodeAt(2)),Y=k(D.charCodeAt(3));return new U(new o(16*A+A,16*W+W,16*Y+Y))}if(x===5){const A=k(D.charCodeAt(1)),W=k(D.charCodeAt(2)),Y=k(D.charCodeAt(3)),ne=k(D.charCodeAt(4));return new U(new o(16*A+A,16*W+W,16*Y+Y,(16*ne+ne)/255))}return null}p.parseHex=v;function k(D){switch(D){case 48:return 0;case 49:return 1;case 50:return 2;case 51:return 3;case 52:return 4;case 53:return 5;case 54:return 6;case 55:return 7;case 56:return 8;case 57:return 9;case 97:return 10;case 65:return 10;case 98:return 11;case 66:return 11;case 99:return 12;case 67:return 12;case 100:return 13;case 68:return 13;case 101:return 14;case 69:return 14;case 102:return 15;case 70:return 15}return 0}})(T=B.CSS||(B.CSS={}))})(P=U.Format||(U.Format={}))}(L||(L={}))},96655:(rt,ye,y)=>{y.d(ye,{Ho:()=>X,M$:()=>U,M0:()=>Z,N1:()=>j,fN:()=>Q,jQ:()=>P});var b=y(63339),o=y(16844),K=y(82399);const $=new Map;$.set("false",!1),$.set("true",!0),$.set("isMac",b.zx),$.set("isLinux",b.j9),$.set("isWindows",b.uF),$.set("isWeb",b.HZ),$.set("isMacNative",b.zx&&!b.HZ),$.set("isEdge",b.UP),$.set("isFirefox",b.gm),$.set("isChrome",b.H8),$.set("isSafari",b.nr);const L=Object.prototype.hasOwnProperty;class U{static has(O){return d.create(O)}static equals(O,te){return g.create(O,te)}static regex(O,te){return x.create(O,te)}static not(O){return w.create(O)}static and(...O){return Y.create(O,null)}static or(...O){return ne.create(O,null,!0)}static deserialize(O,te=!1){if(O)return this._deserializeOrExpression(O,te)}static _deserializeOrExpression(O,te){const oe=O.split("||");return ne.create(oe.map(ue=>this._deserializeAndExpression(ue,te)),null,!0)}static _deserializeAndExpression(O,te){const oe=O.split("&&");return Y.create(oe.map(ue=>this._deserializeOne(ue,te)),null)}static _deserializeOne(O,te){if(O=O.trim(),O.indexOf("!=")>=0){const oe=O.split("!=");return u.create(oe[0].trim(),this._deserializeValue(oe[1],te))}if(O.indexOf("==")>=0){const oe=O.split("==");return g.create(oe[0].trim(),this._deserializeValue(oe[1],te))}if(O.indexOf("=~")>=0){const oe=O.split("=~");return x.create(oe[0].trim(),this._deserializeRegexValue(oe[1],te))}if(O.indexOf(" not in ")>=0){const oe=O.split(" not in ");return l.create(oe[0].trim(),oe[1].trim())}if(O.indexOf(" in ")>=0){const oe=O.split(" in ");return h.create(oe[0].trim(),oe[1].trim())}if(/^[^<=>]+>=[^<=>]+$/.test(O)){const oe=O.split(">=");return v.create(oe[0].trim(),oe[1].trim())}if(/^[^<=>]+>[^<=>]+$/.test(O)){const oe=O.split(">");return m.create(oe[0].trim(),oe[1].trim())}if(/^[^<=>]+<=[^<=>]+$/.test(O)){const oe=O.split("<=");return D.create(oe[0].trim(),oe[1].trim())}if(/^[^<=>]+<[^<=>]+$/.test(O)){const oe=O.split("<");return k.create(oe[0].trim(),oe[1].trim())}return/^\!\s*/.test(O)?w.create(O.substr(1).trim()):d.create(O)}static _deserializeValue(O,te){if(O=O.trim(),O==="true")return!0;if(O==="false")return!1;const oe=/^'([^']*)'$/.exec(O);return oe?oe[1].trim():O}static _deserializeRegexValue(O,te){if((0,o.AV)(O)){if(te)throw new Error("missing regexp-value for =~-expression");return console.warn("missing regexp-value for =~-expression"),null}const oe=O.indexOf("/"),ue=O.lastIndexOf("/");if(oe===ue||oe<0){if(te)throw new Error(`bad regexp-value '${O}', missing /-enclosure`);return console.warn(`bad regexp-value '${O}', missing /-enclosure`),null}const E=O.slice(oe+1,ue),Qe=O[ue+1]==="i"?"i":"";try{return new RegExp(E,Qe)}catch(Ke){if(te)throw new Error(`bad regexp-value '${O}', parse error: ${Ke}`);return console.warn(`bad regexp-value '${O}', parse error: ${Ke}`),null}}}function P(G,O){const te=G?G.substituteConstants():void 0,oe=O?O.substituteConstants():void 0;return!te&&!oe?!0:!te||!oe?!1:te.equals(oe)}function B(G,O){return G.cmp(O)}class T{constructor(){this.type=0}cmp(O){return this.type-O.type}equals(O){return O.type===this.type}substituteConstants(){return this}evaluate(O){return!1}serialize(){return"false"}keys(){return[]}negate(){return p.INSTANCE}}T.INSTANCE=new T;class p{constructor(){this.type=1}cmp(O){return this.type-O.type}equals(O){return O.type===this.type}substituteConstants(){return this}evaluate(O){return!0}serialize(){return"true"}keys(){return[]}negate(){return T.INSTANCE}}p.INSTANCE=new p;class d{constructor(O,te){this.key=O,this.negated=te,this.type=2}static create(O,te=null){const oe=$.get(O);return typeof oe=="boolean"?oe?p.INSTANCE:T.INSTANCE:new d(O,te)}cmp(O){return O.type!==this.type?this.type-O.type:R(this.key,O.key)}equals(O){return O.type===this.type?this.key===O.key:!1}substituteConstants(){const O=$.get(this.key);return typeof O=="boolean"?O?p.INSTANCE:T.INSTANCE:this}evaluate(O){return!!O.getValue(this.key)}serialize(){return this.key}keys(){return[this.key]}negate(){return this.negated||(this.negated=w.create(this.key,this)),this.negated}}class g{constructor(O,te,oe){this.key=O,this.value=te,this.negated=oe,this.type=4}static create(O,te,oe=null){if(typeof te=="boolean")return te?d.create(O,oe):w.create(O,oe);const ue=$.get(O);return typeof ue=="boolean"?te===(ue?"true":"false")?p.INSTANCE:T.INSTANCE:new g(O,te,oe)}cmp(O){return O.type!==this.type?this.type-O.type:H(this.key,this.value,O.key,O.value)}equals(O){return O.type===this.type?this.key===O.key&&this.value===O.value:!1}substituteConstants(){const O=$.get(this.key);if(typeof O=="boolean"){const te=O?"true":"false";return this.value===te?p.INSTANCE:T.INSTANCE}return this}evaluate(O){return O.getValue(this.key)==this.value}serialize(){return`${this.key} == '${this.value}'`}keys(){return[this.key]}negate(){return this.negated||(this.negated=u.create(this.key,this.value,this)),this.negated}}class h{constructor(O,te){this.key=O,this.valueKey=te,this.type=10,this.negated=null}static create(O,te){return new h(O,te)}cmp(O){return O.type!==this.type?this.type-O.type:H(this.key,this.valueKey,O.key,O.valueKey)}equals(O){return O.type===this.type?this.key===O.key&&this.valueKey===O.valueKey:!1}substituteConstants(){return this}evaluate(O){const te=O.getValue(this.valueKey),oe=O.getValue(this.key);return Array.isArray(te)?te.includes(oe):typeof oe=="string"&&typeof te=="object"&&te!==null?L.call(te,oe):!1}serialize(){return`${this.key} in '${this.valueKey}'`}keys(){return[this.key,this.valueKey]}negate(){return this.negated||(this.negated=l.create(this.key,this.valueKey)),this.negated}}class l{constructor(O,te){this.key=O,this.valueKey=te,this.type=11,this._negated=h.create(O,te)}static create(O,te){return new l(O,te)}cmp(O){return O.type!==this.type?this.type-O.type:this._negated.cmp(O._negated)}equals(O){return O.type===this.type?this._negated.equals(O._negated):!1}substituteConstants(){return this}evaluate(O){return!this._negated.evaluate(O)}serialize(){return`${this.key} not in '${this.valueKey}'`}keys(){return this._negated.keys()}negate(){return this._negated}}class u{constructor(O,te,oe){this.key=O,this.value=te,this.negated=oe,this.type=5}static create(O,te,oe=null){if(typeof te=="boolean")return te?w.create(O,oe):d.create(O,oe);const ue=$.get(O);return typeof ue=="boolean"?te===(ue?"true":"false")?T.INSTANCE:p.INSTANCE:new u(O,te,oe)}cmp(O){return O.type!==this.type?this.type-O.type:H(this.key,this.value,O.key,O.value)}equals(O){return O.type===this.type?this.key===O.key&&this.value===O.value:!1}substituteConstants(){const O=$.get(this.key);if(typeof O=="boolean"){const te=O?"true":"false";return this.value===te?T.INSTANCE:p.INSTANCE}return this}evaluate(O){return O.getValue(this.key)!=this.value}serialize(){return`${this.key} != '${this.value}'`}keys(){return[this.key]}negate(){return this.negated||(this.negated=g.create(this.key,this.value,this)),this.negated}}class w{constructor(O,te){this.key=O,this.negated=te,this.type=3}static create(O,te=null){const oe=$.get(O);return typeof oe=="boolean"?oe?T.INSTANCE:p.INSTANCE:new w(O,te)}cmp(O){return O.type!==this.type?this.type-O.type:R(this.key,O.key)}equals(O){return O.type===this.type?this.key===O.key:!1}substituteConstants(){const O=$.get(this.key);return typeof O=="boolean"?O?T.INSTANCE:p.INSTANCE:this}evaluate(O){return!O.getValue(this.key)}serialize(){return`!${this.key}`}keys(){return[this.key]}negate(){return this.negated||(this.negated=d.create(this.key,this)),this.negated}}function C(G,O){if(typeof G=="string"){const te=parseFloat(G);isNaN(te)||(G=te)}return typeof G=="string"||typeof G=="number"?O(G):T.INSTANCE}class m{constructor(O,te,oe){this.key=O,this.value=te,this.negated=oe,this.type=12}static create(O,te,oe=null){return C(te,ue=>new m(O,ue,oe))}cmp(O){return O.type!==this.type?this.type-O.type:H(this.key,this.value,O.key,O.value)}equals(O){return O.type===this.type?this.key===O.key&&this.value===O.value:!1}substituteConstants(){return this}evaluate(O){return typeof this.value=="string"?!1:parseFloat(O.getValue(this.key))>this.value}serialize(){return`${this.key} > ${this.value}`}keys(){return[this.key]}negate(){return this.negated||(this.negated=D.create(this.key,this.value,this)),this.negated}}class v{constructor(O,te,oe){this.key=O,this.value=te,this.negated=oe,this.type=13}static create(O,te,oe=null){return C(te,ue=>new v(O,ue,oe))}cmp(O){return O.type!==this.type?this.type-O.type:H(this.key,this.value,O.key,O.value)}equals(O){return O.type===this.type?this.key===O.key&&this.value===O.value:!1}substituteConstants(){return this}evaluate(O){return typeof this.value=="string"?!1:parseFloat(O.getValue(this.key))>=this.value}serialize(){return`${this.key} >= ${this.value}`}keys(){return[this.key]}negate(){return this.negated||(this.negated=k.create(this.key,this.value,this)),this.negated}}class k{constructor(O,te,oe){this.key=O,this.value=te,this.negated=oe,this.type=14}static create(O,te,oe=null){return C(te,ue=>new k(O,ue,oe))}cmp(O){return O.type!==this.type?this.type-O.type:H(this.key,this.value,O.key,O.value)}equals(O){return O.type===this.type?this.key===O.key&&this.value===O.value:!1}substituteConstants(){return this}evaluate(O){return typeof this.value=="string"?!1:parseFloat(O.getValue(this.key))<this.value}serialize(){return`${this.key} < ${this.value}`}keys(){return[this.key]}negate(){return this.negated||(this.negated=v.create(this.key,this.value,this)),this.negated}}class D{constructor(O,te,oe){this.key=O,this.value=te,this.negated=oe,this.type=15}static create(O,te,oe=null){return C(te,ue=>new D(O,ue,oe))}cmp(O){return O.type!==this.type?this.type-O.type:H(this.key,this.value,O.key,O.value)}equals(O){return O.type===this.type?this.key===O.key&&this.value===O.value:!1}substituteConstants(){return this}evaluate(O){return typeof this.value=="string"?!1:parseFloat(O.getValue(this.key))<=this.value}serialize(){return`${this.key} <= ${this.value}`}keys(){return[this.key]}negate(){return this.negated||(this.negated=m.create(this.key,this.value,this)),this.negated}}class x{constructor(O,te){this.key=O,this.regexp=te,this.type=7,this.negated=null}static create(O,te){return new x(O,te)}cmp(O){if(O.type!==this.type)return this.type-O.type;if(this.key<O.key)return-1;if(this.key>O.key)return 1;const te=this.regexp?this.regexp.source:"",oe=O.regexp?O.regexp.source:"";return te<oe?-1:te>oe?1:0}equals(O){if(O.type===this.type){const te=this.regexp?this.regexp.source:"",oe=O.regexp?O.regexp.source:"";return this.key===O.key&&te===oe}return!1}substituteConstants(){return this}evaluate(O){const te=O.getValue(this.key);return this.regexp?this.regexp.test(te):!1}serialize(){const O=this.regexp?`/${this.regexp.source}/${this.regexp.ignoreCase?"i":""}`:"/invalid/";return`${this.key} =~ ${O}`}keys(){return[this.key]}negate(){return this.negated||(this.negated=A.create(this)),this.negated}}class A{constructor(O){this._actual=O,this.type=8}static create(O){return new A(O)}cmp(O){return O.type!==this.type?this.type-O.type:this._actual.cmp(O._actual)}equals(O){return O.type===this.type?this._actual.equals(O._actual):!1}substituteConstants(){return this}evaluate(O){return!this._actual.evaluate(O)}serialize(){throw new Error("Method not implemented.")}keys(){return this._actual.keys()}negate(){return this._actual}}function W(G){let O=null;for(let te=0,oe=G.length;te<oe;te++){const ue=G[te].substituteConstants();if(G[te]!==ue&&O===null){O=[];for(let E=0;E<te;E++)O[E]=G[E]}O!==null&&(O[te]=ue)}return O===null?G:O}class Y{constructor(O,te){this.expr=O,this.negated=te,this.type=6}static create(O,te){return Y._normalizeArr(O,te)}cmp(O){if(O.type!==this.type)return this.type-O.type;if(this.expr.length<O.expr.length)return-1;if(this.expr.length>O.expr.length)return 1;for(let te=0,oe=this.expr.length;te<oe;te++){const ue=B(this.expr[te],O.expr[te]);if(ue!==0)return ue}return 0}equals(O){if(O.type===this.type){if(this.expr.length!==O.expr.length)return!1;for(let te=0,oe=this.expr.length;te<oe;te++)if(!this.expr[te].equals(O.expr[te]))return!1;return!0}return!1}substituteConstants(){const O=W(this.expr);return O===this.expr?this:Y.create(O,this.negated)}evaluate(O){for(let te=0,oe=this.expr.length;te<oe;te++)if(!this.expr[te].evaluate(O))return!1;return!0}static _normalizeArr(O,te){const oe=[];let ue=!1;for(const E of O)if(E){if(E.type===1){ue=!0;continue}if(E.type===0)return T.INSTANCE;if(E.type===6){oe.push(...E.expr);continue}oe.push(E)}if(oe.length===0&&ue)return p.INSTANCE;if(oe.length!==0){if(oe.length===1)return oe[0];oe.sort(B);for(let E=1;E<oe.length;E++)oe[E-1].equals(oe[E])&&(oe.splice(E,1),E--);if(oe.length===1)return oe[0];for(;oe.length>1;){const E=oe[oe.length-1];if(E.type!==9)break;oe.pop();const Qe=oe.pop(),Ke=oe.length===0,Se=ne.create(E.expr.map(Me=>Y.create([Me,Qe],null)),null,Ke);Se&&(oe.push(Se),oe.sort(B))}return oe.length===1?oe[0]:new Y(oe,te)}}serialize(){return this.expr.map(O=>O.serialize()).join(" && ")}keys(){const O=[];for(const te of this.expr)O.push(...te.keys());return O}negate(){if(!this.negated){const O=[];for(const te of this.expr)O.push(te.negate());this.negated=ne.create(O,this,!0)}return this.negated}}class ne{constructor(O,te){this.expr=O,this.negated=te,this.type=9}static create(O,te,oe){return ne._normalizeArr(O,te,oe)}cmp(O){if(O.type!==this.type)return this.type-O.type;if(this.expr.length<O.expr.length)return-1;if(this.expr.length>O.expr.length)return 1;for(let te=0,oe=this.expr.length;te<oe;te++){const ue=B(this.expr[te],O.expr[te]);if(ue!==0)return ue}return 0}equals(O){if(O.type===this.type){if(this.expr.length!==O.expr.length)return!1;for(let te=0,oe=this.expr.length;te<oe;te++)if(!this.expr[te].equals(O.expr[te]))return!1;return!0}return!1}substituteConstants(){const O=W(this.expr);return O===this.expr?this:ne.create(O,this.negated,!1)}evaluate(O){for(let te=0,oe=this.expr.length;te<oe;te++)if(this.expr[te].evaluate(O))return!0;return!1}static _normalizeArr(O,te,oe){let ue=[],E=!1;if(O){for(let Qe=0,Ke=O.length;Qe<Ke;Qe++){const Se=O[Qe];if(Se){if(Se.type===0){E=!0;continue}if(Se.type===1)return p.INSTANCE;if(Se.type===9){ue=ue.concat(Se.expr);continue}ue.push(Se)}}if(ue.length===0&&E)return T.INSTANCE;ue.sort(B)}if(ue.length!==0){if(ue.length===1)return ue[0];for(let Qe=1;Qe<ue.length;Qe++)ue[Qe-1].equals(ue[Qe])&&(ue.splice(Qe,1),Qe--);if(ue.length===1)return ue[0];if(oe){for(let Qe=0;Qe<ue.length;Qe++)for(let Ke=Qe+1;Ke<ue.length;Ke++)Z(ue[Qe],ue[Ke])&&(ue.splice(Ke,1),Ke--);if(ue.length===1)return ue[0]}return new ne(ue,te)}}serialize(){return this.expr.map(O=>O.serialize()).join(" || ")}keys(){const O=[];for(const te of this.expr)O.push(...te.keys());return O}negate(){if(!this.negated){const O=[];for(const te of this.expr)O.push(te.negate());for(;O.length>1;){const te=O.shift(),oe=O.shift(),ue=[];for(const Qe of N(te))for(const Ke of N(oe))ue.push(Y.create([Qe,Ke],null));const E=O.length===0;O.unshift(ne.create(ue,null,E))}this.negated=O[0]}return this.negated}}class j extends d{constructor(O,te,oe){super(O,null),this._defaultValue=te,typeof oe=="object"?j._info.push(Object.assign(Object.assign({},oe),{key:O})):oe!==!0&&j._info.push({key:O,description:oe,type:te!=null?typeof te:void 0})}static all(){return j._info.values()}bindTo(O){return O.createKey(this.key,this._defaultValue)}getValue(O){return O.getContextKeyValue(this.key)}toNegated(){return this.negate()}isEqualTo(O){return g.create(this.key,O)}}j._info=[];const Q=(0,K.u1)("contextKeyService"),X="setContext";function R(G,O){return G<O?-1:G>O?1:0}function H(G,O,te,oe){return G<te?-1:G>te?1:O<oe?-1:O>oe?1:0}function Z(G,O){if(O.type===6&&G.type!==9&&G.type!==6){for(const ue of O.expr)if(G.equals(ue))return!0}const te=G.negate(),oe=N(te).concat(N(O));oe.sort(B);for(let ue=0;ue<oe.length;ue++){const Qe=oe[ue].negate();for(let Ke=ue+1;Ke<oe.length;Ke++){const Se=oe[Ke];if(Qe.equals(Se))return!0}}return!1}function N(G){return G.type===9?G.expr:[G]}},96803:(rt,ye,y)=>{y.d(ye,{iE:()=>o,rW:()=>K});class b{constructor(L,U,P){this._colorZoneBrand=void 0,this.from=L|0,this.to=U|0,this.colorId=P|0}static compare(L,U){return L.colorId===U.colorId?L.from===U.from?L.to-U.to:L.from-U.from:L.colorId-U.colorId}}class o{constructor(L,U,P,B){this._overviewRulerZoneBrand=void 0,this.startLineNumber=L,this.endLineNumber=U,this.heightInLines=P,this.color=B,this._colorZone=null}static compare(L,U){return L.color===U.color?L.startLineNumber===U.startLineNumber?L.heightInLines===U.heightInLines?L.endLineNumber-U.endLineNumber:L.heightInLines-U.heightInLines:L.startLineNumber-U.startLineNumber:L.color<U.color?-1:1}setColorZone(L){this._colorZone=L}getColorZones(){return this._colorZone}}class K{constructor(L){this._getVerticalOffsetForLine=L,this._zones=[],this._colorZonesInvalid=!1,this._lineHeight=0,this._domWidth=0,this._domHeight=0,this._outerHeight=0,this._pixelRatio=1,this._lastAssignedId=0,this._color2Id=Object.create(null),this._id2Color=[]}getId2Color(){return this._id2Color}setZones(L){this._zones=L,this._zones.sort(o.compare)}setLineHeight(L){return this._lineHeight===L?!1:(this._lineHeight=L,this._colorZonesInvalid=!0,!0)}setPixelRatio(L){this._pixelRatio=L,this._colorZonesInvalid=!0}getDOMWidth(){return this._domWidth}getCanvasWidth(){return this._domWidth*this._pixelRatio}setDOMWidth(L){return this._domWidth===L?!1:(this._domWidth=L,this._colorZonesInvalid=!0,!0)}getDOMHeight(){return this._domHeight}getCanvasHeight(){return this._domHeight*this._pixelRatio}setDOMHeight(L){return this._domHeight===L?!1:(this._domHeight=L,this._colorZonesInvalid=!0,!0)}getOuterHeight(){return this._outerHeight}setOuterHeight(L){return this._outerHeight===L?!1:(this._outerHeight=L,this._colorZonesInvalid=!0,!0)}resolveColorZones(){const L=this._colorZonesInvalid,U=Math.floor(this._lineHeight),P=Math.floor(this.getCanvasHeight()),B=Math.floor(this._outerHeight),T=P/B,p=Math.floor(4*this._pixelRatio/2),d=[];for(let g=0,h=this._zones.length;g<h;g++){const l=this._zones[g];if(!L){const W=l.getColorZones();if(W){d.push(W);continue}}const u=this._getVerticalOffsetForLine(l.startLineNumber),w=l.heightInLines===0?this._getVerticalOffsetForLine(l.endLineNumber)+U:u+l.heightInLines*U,C=Math.floor(T*u),m=Math.floor(T*w);let v=Math.floor((C+m)/2),k=m-v;k<p&&(k=p),v-k<0&&(v=k),v+k>P&&(v=P-k);const D=l.color;let x=this._color2Id[D];x||(x=++this._lastAssignedId,this._color2Id[D]=x,this._id2Color[x]=D);const A=new b(v-k,v+k,x);l.setColorZone(A),d.push(A)}return this._colorZonesInvalid=!1,d.sort(b.compare),d}}},96852:(rt,ye,y)=>{y.d(ye,{U:()=>o});var b=y(26048);function o(K){let $=K.definition;for(;$ instanceof b.W6;)$=$.definition;return`.codicon-${K.id}:before { content: '${$.fontCharacter}'; }`}},97036:(rt,ye,y)=>{y.d(ye,{$H:()=>K,Lh:()=>$,r3:()=>o});var b=y(47317);const o=new class{clone(){return this}equals(L){return this===L}};function K(L,U){return new b.$M([new b.ou(0,"",L)],U)}function $(L,U){const P=new Uint32Array(2);return P[0]=0,P[1]=(L<<0|0|0|32768|2<<24)>>>0,new b.rY(P,U===null?o:U)}},97396:(rt,ye,y)=>{y.r(ye),y.d(ye,{CancellationTokenSource:()=>Vc,Emitter:()=>Hc,KeyCode:()=>zc,KeyMod:()=>Uc,MarkerSeverity:()=>Qc,MarkerTag:()=>Zc,Position:()=>jc,Range:()=>Kc,Selection:()=>$c,SelectionDirection:()=>Gc,Token:()=>Xc,Uri:()=>Yc,editor:()=>Jc,languages:()=>qc});var b=y(66476),o=y(93059),K=y(10998),$=y(16844),L=y(41106),U=y(87301),P=y(16878),B=y(28060),T=y(12596),p=y(66055),d=y(47317),g=y(52394),h=y(97036),l=y(77922),u=y(64830),w=y(65958),C=y(94327),m=y(2106),v=y(63339),k=y(79359);const D="$initialize";let x=!1;function A(ee){v.HZ&&(x||(x=!0,console.warn("Could not create web worker(s). Falling back to loading web worker code in main thread, which might cause UI freezes. Please see https://github.com/microsoft/monaco-editor#faq")),console.warn(ee.message))}class W{constructor(t,s,f,M){this.vsWorker=t,this.req=s,this.method=f,this.args=M,this.type=0}}class Y{constructor(t,s,f,M){this.vsWorker=t,this.seq=s,this.res=f,this.err=M,this.type=1}}class ne{constructor(t,s,f,M){this.vsWorker=t,this.req=s,this.eventName=f,this.arg=M,this.type=2}}class j{constructor(t,s,f){this.vsWorker=t,this.req=s,this.event=f,this.type=3}}class Q{constructor(t,s){this.vsWorker=t,this.req=s,this.type=4}}class X{constructor(t){this._workerId=-1,this._handler=t,this._lastSentReq=0,this._pendingReplies=Object.create(null),this._pendingEmitters=new Map,this._pendingEvents=new Map}setWorkerId(t){this._workerId=t}sendMessage(t,s){const f=String(++this._lastSentReq);return new Promise((M,V)=>{this._pendingReplies[f]={resolve:M,reject:V},this._send(new W(this._workerId,f,t,s))})}listen(t,s){let f=null;const M=new m.vl({onFirstListenerAdd:()=>{f=String(++this._lastSentReq),this._pendingEmitters.set(f,M),this._send(new ne(this._workerId,f,t,s))},onLastListenerRemove:()=>{this._pendingEmitters.delete(f),this._send(new Q(this._workerId,f)),f=null}});return M.event}handleMessage(t){!t||!t.vsWorker||this._workerId!==-1&&t.vsWorker!==this._workerId||this._handleMessage(t)}_handleMessage(t){switch(t.type){case 1:return this._handleReplyMessage(t);case 0:return this._handleRequestMessage(t);case 2:return this._handleSubscribeEventMessage(t);case 3:return this._handleEventMessage(t);case 4:return this._handleUnsubscribeEventMessage(t)}}_handleReplyMessage(t){if(!this._pendingReplies[t.seq]){console.warn("Got reply to unknown seq");return}const s=this._pendingReplies[t.seq];if(delete this._pendingReplies[t.seq],t.err){let f=t.err;t.err.$isError&&(f=new Error,f.name=t.err.name,f.message=t.err.message,f.stack=t.err.stack),s.reject(f);return}s.resolve(t.res)}_handleRequestMessage(t){const s=t.req;this._handler.handleMessage(t.method,t.args).then(M=>{this._send(new Y(this._workerId,s,M,void 0))},M=>{M.detail instanceof Error&&(M.detail=(0,C.cU)(M.detail)),this._send(new Y(this._workerId,s,void 0,(0,C.cU)(M)))})}_handleSubscribeEventMessage(t){const s=t.req,f=this._handler.handleEvent(t.eventName,t.arg)(M=>{this._send(new j(this._workerId,s,M))});this._pendingEvents.set(s,f)}_handleEventMessage(t){if(!this._pendingEmitters.has(t.req)){console.warn("Got event for unknown req");return}this._pendingEmitters.get(t.req).fire(t.event)}_handleUnsubscribeEventMessage(t){if(!this._pendingEvents.has(t.req)){console.warn("Got unsubscribe for unknown req");return}this._pendingEvents.get(t.req).dispose(),this._pendingEvents.delete(t.req)}_send(t){const s=[];if(t.type===0)for(let f=0;f<t.args.length;f++)t.args[f]instanceof ArrayBuffer&&s.push(t.args[f]);else t.type===1&&t.res instanceof ArrayBuffer&&s.push(t.res);this._handler.sendMessage(t,s)}}class R extends K.jG{constructor(t,s,f){super();let M=null;this._worker=this._register(t.create("vs/base/common/worker/simpleWorker",De=>{this._protocol.handleMessage(De)},De=>{M?.(De)})),this._protocol=new X({sendMessage:(De,Oe)=>{this._worker.postMessage(De,Oe)},handleMessage:(De,Oe)=>{if(typeof f[De]!="function")return Promise.reject(new Error("Missing method "+De+" on main thread host."));try{return Promise.resolve(f[De].apply(f,Oe))}catch(qe){return Promise.reject(qe)}},handleEvent:(De,Oe)=>{if(Z(De)){const qe=f[De].call(f,Oe);if(typeof qe!="function")throw new Error(`Missing dynamic event ${De} on main thread host.`);return qe}if(H(De)){const qe=f[De];if(typeof qe!="function")throw new Error(`Missing event ${De} on main thread host.`);return qe}throw new Error(`Malformed event name ${De}`)}}),this._protocol.setWorkerId(this._worker.getId());let V=null;typeof v.zQ.require<"u"&&typeof v.zQ.require.getConfig=="function"?V=v.zQ.require.getConfig():typeof v.zQ.requirejs<"u"&&(V=v.zQ.requirejs.s.contexts._.config);const q=k.V0(f);this._onModuleLoaded=this._protocol.sendMessage(D,[this._worker.getId(),JSON.parse(JSON.stringify(V)),s,q]);const se=(De,Oe)=>this._request(De,Oe),_e=(De,Oe)=>this._protocol.listen(De,Oe);this._lazyProxy=new Promise((De,Oe)=>{M=Oe,this._onModuleLoaded.then(qe=>{De(N(qe,se,_e))},qe=>{Oe(qe),this._onError("Worker failed to load "+s,qe)})})}getProxyObject(){return this._lazyProxy}_request(t,s){return new Promise((f,M)=>{this._onModuleLoaded.then(()=>{this._protocol.sendMessage(t,s).then(f,M)},M)})}_onError(t,s){console.error(t),console.info(s)}}function H(ee){return ee[0]==="o"&&ee[1]==="n"&&$.Wv(ee.charCodeAt(2))}function Z(ee){return/^onDynamic/.test(ee)&&$.Wv(ee.charCodeAt(9))}function N(ee,t,s){const f=q=>function(){const se=Array.prototype.slice.call(arguments,0);return t(q,se)},M=q=>function(se){return s(q,se)},V={};for(const q of ee){if(Z(q)){V[q]=M(q);continue}if(H(q)){V[q]=s(q,void 0);continue}V[q]=f(q)}return V}class G{constructor(t,s){this._requestHandlerFactory=s,this._requestHandler=null,this._protocol=new X({sendMessage:(f,M)=>{t(f,M)},handleMessage:(f,M)=>this._handleMessage(f,M),handleEvent:(f,M)=>this._handleEvent(f,M)})}onmessage(t){this._protocol.handleMessage(t)}_handleMessage(t,s){if(t===D)return this.initialize(s[0],s[1],s[2],s[3]);if(!this._requestHandler||typeof this._requestHandler[t]!="function")return Promise.reject(new Error("Missing requestHandler or method: "+t));try{return Promise.resolve(this._requestHandler[t].apply(this._requestHandler,s))}catch(f){return Promise.reject(f)}}_handleEvent(t,s){if(!this._requestHandler)throw new Error("Missing requestHandler");if(Z(t)){const f=this._requestHandler[t].call(this._requestHandler,s);if(typeof f!="function")throw new Error(`Missing dynamic event ${t} on request handler.`);return f}if(H(t)){const f=this._requestHandler[t];if(typeof f!="function")throw new Error(`Missing event ${t} on request handler.`);return f}throw new Error(`Malformed event name ${t}`)}initialize(t,s,f,M){this._protocol.setWorkerId(t);const se=N(M,(_e,De)=>this._protocol.sendMessage(_e,De),(_e,De)=>this._protocol.listen(_e,De));return this._requestHandlerFactory?(this._requestHandler=this._requestHandlerFactory(se),Promise.resolve(types.getAllMethodNames(this._requestHandler))):(s&&(typeof s.baseUrl<"u"&&delete s.baseUrl,typeof s.paths<"u"&&typeof s.paths.vs<"u"&&delete s.paths.vs,typeof s.trustedTypesPolicy!==void 0&&delete s.trustedTypesPolicy,s.catchError=!0,globals.require.config(s)),new Promise((_e,De)=>{const Oe=globals.require;Oe([f],qe=>{if(this._requestHandler=qe.create(se),!this._requestHandler){De(new Error("No RequestHandler!"));return}_e(types.getAllMethodNames(this._requestHandler))},De)}))}}function O(ee){return new G(ee,null)}var te;const oe=(te=window.trustedTypes)===null||te===void 0?void 0:te.createPolicy("defaultWorkerFactory",{createScriptURL:ee=>ee});function ue(ee){if(v.zQ.MonacoEnvironment){if(typeof v.zQ.MonacoEnvironment.getWorker=="function")return v.zQ.MonacoEnvironment.getWorker("workerMain.js",ee);if(typeof v.zQ.MonacoEnvironment.getWorkerUrl=="function"){const t=v.zQ.MonacoEnvironment.getWorkerUrl("workerMain.js",ee);return new Worker(oe?oe.createScriptURL(t):t,{name:ee})}}throw new Error("You must define a function MonacoEnvironment.getWorkerUrl or MonacoEnvironment.getWorker")}function E(ee){return typeof ee.then=="function"}class Qe{constructor(t,s,f,M,V){this.id=s;const q=ue(f);E(q)?this.worker=q:this.worker=Promise.resolve(q),this.postMessage(t,[]),this.worker.then(se=>{se.onmessage=function(_e){M(_e.data)},se.onmessageerror=V,typeof se.addEventListener=="function"&&se.addEventListener("error",V)})}getId(){return this.id}postMessage(t,s){var f;(f=this.worker)===null||f===void 0||f.then(M=>M.postMessage(t,s))}dispose(){var t;(t=this.worker)===null||t===void 0||t.then(s=>s.terminate()),this.worker=null}}class Ke{constructor(t){this._label=t,this._webWorkerFailedBeforeError=!1}create(t,s,f){const M=++Ke.LAST_WORKER_ID;if(this._webWorkerFailedBeforeError)throw this._webWorkerFailedBeforeError;return new Qe(t,M,this._label||"anonymous"+M,s,V=>{A(V),this._webWorkerFailedBeforeError=V,f(V)})}}Ke.LAST_WORKER_ID=0;var Se=y(50442),Me=y(39373),ce=y(41504),pe=y(13338),be=y(46441),ge=y(23013),ke=y(52230),We=function(ee,t,s,f){var M=arguments.length,V=M<3?t:f===null?f=Object.getOwnPropertyDescriptor(t,s):f,q;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")V=Reflect.decorate(ee,t,s,f);else for(var se=ee.length-1;se>=0;se--)(q=ee[se])&&(V=(M<3?q(V):M>3?q(t,s,V):q(t,s))||V);return M>3&&V&&Object.defineProperty(t,s,V),V},Ge=function(ee,t){return function(s,f){t(s,f,ee)}},Ae=function(ee,t,s,f){function M(V){return V instanceof s?V:new s(function(q){q(V)})}return new(s||(s=Promise))(function(V,q){function se(Oe){try{De(f.next(Oe))}catch(qe){q(qe)}}function _e(Oe){try{De(f.throw(Oe))}catch(qe){q(qe)}}function De(Oe){Oe.done?V(Oe.value):M(Oe.value).then(se,_e)}De((f=f.apply(ee,t||[])).next())})};const he=60*1e3,Pe=300*1e3;function $e(ee,t){const s=ee.getModel(t);return!(!s||s.isTooLargeForSyncing())}let it=class extends K.jG{constructor(t,s,f,M,V){super(),this._modelService=t,this._workerManager=this._register(new Wt(this._modelService,M)),this._logService=f,this._register(V.linkProvider.register({language:"*",hasAccessToAllModels:!0},{provideLinks:(q,se)=>$e(this._modelService,q.uri)?this._workerManager.withWorker().then(_e=>_e.computeLinks(q.uri)).then(_e=>_e&&{links:_e}):Promise.resolve({links:[]})})),this._register(V.completionProvider.register("*",new ft(this._workerManager,s,this._modelService,M)))}dispose(){super.dispose()}canComputeUnicodeHighlights(t){return $e(this._modelService,t)}computedUnicodeHighlights(t,s,f){return this._workerManager.withWorker().then(M=>M.computedUnicodeHighlights(t,s,f))}computeDiff(t,s,f,M){return this._workerManager.withWorker().then(V=>V.computeDiff(t,s,f,M))}computeMoreMinimalEdits(t,s){if((0,pe.EI)(s)){if(!$e(this._modelService,t))return Promise.resolve(s);const f=ge.W.create(!0),M=this._workerManager.withWorker().then(V=>V.computeMoreMinimalEdits(t,s));return M.finally(()=>this._logService.trace("FORMAT#computeMoreMinimalEdits",t.toString(!0),f.elapsed())),Promise.race([M,(0,w.wR)(1e3).then(()=>s)])}else return Promise.resolve(void 0)}canNavigateValueSet(t){return $e(this._modelService,t)}navigateValueSet(t,s,f){return this._workerManager.withWorker().then(M=>M.navigateValueSet(t,s,f))}canComputeWordRanges(t){return $e(this._modelService,t)}computeWordRanges(t,s){return this._workerManager.withWorker().then(f=>f.computeWordRanges(t,s))}};it=We([Ge(0,u.S),Ge(1,ce.U),Ge(2,be.rr),Ge(3,g.JZ),Ge(4,ke.u)],it);class ft{constructor(t,s,f,M){this.languageConfigurationService=M,this._debugDisplayName="wordbasedCompletions",this._workerManager=t,this._configurationService=s,this._modelService=f}provideCompletionItems(t,s){return Ae(this,void 0,void 0,function*(){const f=this._configurationService.getValue(t.uri,s,"editor");if(!f.wordBasedSuggestions)return;const M=[];if(f.wordBasedSuggestionsMode==="currentDocument")$e(this._modelService,t.uri)&&M.push(t.uri);else for(const qe of this._modelService.getModels())$e(this._modelService,qe.uri)&&(qe===t?M.unshift(qe.uri):(f.wordBasedSuggestionsMode==="allDocuments"||qe.getLanguageId()===t.getLanguageId())&&M.push(qe.uri));if(M.length===0)return;const V=this.languageConfigurationService.getLanguageConfiguration(t.getLanguageId()).getWordDefinition(),q=t.getWordAtPosition(s),se=q?new Se.Q(s.lineNumber,q.startColumn,s.lineNumber,q.endColumn):Se.Q.fromPositions(s),_e=se.setEndPosition(s.lineNumber,s.column),Oe=yield(yield this._workerManager.withWorker()).textualSuggest(M,q?.word,V);if(Oe)return{duration:Oe.duration,suggestions:Oe.words.map(qe=>({kind:18,label:qe,insertText:qe,range:{insert:_e,replace:se}}))}})}}class Wt extends K.jG{constructor(t,s){super(),this.languageConfigurationService=s,this._modelService=t,this._editorWorkerClient=null,this._lastWorkerUsedTime=new Date().getTime(),this._register(new w.vb).cancelAndSet(()=>this._checkStopIdleWorker(),Math.round(Pe/2)),this._register(this._modelService.onModelRemoved(M=>this._checkStopEmptyWorker()))}dispose(){this._editorWorkerClient&&(this._editorWorkerClient.dispose(),this._editorWorkerClient=null),super.dispose()}_checkStopEmptyWorker(){if(!this._editorWorkerClient)return;this._modelService.getModels().length===0&&(this._editorWorkerClient.dispose(),this._editorWorkerClient=null)}_checkStopIdleWorker(){if(!this._editorWorkerClient)return;new Date().getTime()-this._lastWorkerUsedTime>Pe&&(this._editorWorkerClient.dispose(),this._editorWorkerClient=null)}withWorker(){return this._lastWorkerUsedTime=new Date().getTime(),this._editorWorkerClient||(this._editorWorkerClient=new Lt(this._modelService,!1,"editorWorkerService",this.languageConfigurationService)),Promise.resolve(this._editorWorkerClient)}}class tt extends K.jG{constructor(t,s,f){if(super(),this._syncedModels=Object.create(null),this._syncedModelsLastUsedTime=Object.create(null),this._proxy=t,this._modelService=s,!f){const M=new w.vb;M.cancelAndSet(()=>this._checkStopModelSync(),Math.round(he/2)),this._register(M)}}dispose(){for(const t in this._syncedModels)(0,K.AS)(this._syncedModels[t]);this._syncedModels=Object.create(null),this._syncedModelsLastUsedTime=Object.create(null),super.dispose()}ensureSyncedResources(t,s){for(const f of t){const M=f.toString();this._syncedModels[M]||this._beginModelSync(f,s),this._syncedModels[M]&&(this._syncedModelsLastUsedTime[M]=new Date().getTime())}}_checkStopModelSync(){const t=new Date().getTime(),s=[];for(const f in this._syncedModelsLastUsedTime)t-this._syncedModelsLastUsedTime[f]>he&&s.push(f);for(const f of s)this._stopModelSync(f)}_beginModelSync(t,s){const f=this._modelService.getModel(t);if(!f||!s&&f.isTooLargeForSyncing())return;const M=t.toString();this._proxy.acceptNewModel({url:f.uri.toString(),lines:f.getLinesContent(),EOL:f.getEOL(),versionId:f.getVersionId()});const V=new K.Cm;V.add(f.onDidChangeContent(q=>{this._proxy.acceptModelChanged(M.toString(),q)})),V.add(f.onWillDispose(()=>{this._stopModelSync(M)})),V.add((0,K.s)(()=>{this._proxy.acceptRemovedModel(M)})),this._syncedModels[M]=V}_stopModelSync(t){const s=this._syncedModels[t];delete this._syncedModels[t],delete this._syncedModelsLastUsedTime[t],(0,K.AS)(s)}}class Ye{constructor(t){this._instance=t,this._proxyObj=Promise.resolve(this._instance)}dispose(){this._instance.dispose()}getProxyObject(){return this._proxyObj}}class ht{constructor(t){this._workerClient=t}fhr(t,s){return this._workerClient.fhr(t,s)}}class Lt extends K.jG{constructor(t,s,f,M){super(),this.languageConfigurationService=M,this._disposed=!1,this._modelService=t,this._keepIdleModels=s,this._workerFactory=new Ke(f),this._worker=null,this._modelManager=null}fhr(t,s){throw new Error("Not implemented!")}_getOrCreateWorker(){if(!this._worker)try{this._worker=this._register(new R(this._workerFactory,"vs/editor/common/services/editorSimpleWorker",new ht(this)))}catch(t){A(t),this._worker=new Ye(new Me.Wg(new ht(this),null))}return this._worker}_getProxy(){return this._getOrCreateWorker().getProxyObject().then(void 0,t=>(A(t),this._worker=new Ye(new Me.Wg(new ht(this),null)),this._getOrCreateWorker().getProxyObject()))}_getOrCreateModelManager(t){return this._modelManager||(this._modelManager=this._register(new tt(t,this._modelService,this._keepIdleModels))),this._modelManager}_withSyncedResources(t,s=!1){return Ae(this,void 0,void 0,function*(){return this._disposed?Promise.reject((0,C.aD)()):this._getProxy().then(f=>(this._getOrCreateModelManager(f).ensureSyncedResources(t,s),f))})}computedUnicodeHighlights(t,s,f){return this._withSyncedResources([t]).then(M=>M.computeUnicodeHighlights(t.toString(),s,f))}computeDiff(t,s,f,M){return this._withSyncedResources([t,s],!0).then(V=>V.computeDiff(t.toString(),s.toString(),f,M))}computeMoreMinimalEdits(t,s){return this._withSyncedResources([t]).then(f=>f.computeMoreMinimalEdits(t.toString(),s))}computeLinks(t){return this._withSyncedResources([t]).then(s=>s.computeLinks(t.toString()))}textualSuggest(t,s,f){return Ae(this,void 0,void 0,function*(){const M=yield this._withSyncedResources(t),V=f.source,q=(0,$.RH)(f);return M.textualSuggest(t.map(se=>se.toString()),s,V,q)})}computeWordRanges(t,s){return this._withSyncedResources([t]).then(f=>{const M=this._modelService.getModel(t);if(!M)return Promise.resolve(null);const V=this.languageConfigurationService.getLanguageConfiguration(M.getLanguageId()).getWordDefinition(),q=V.source,se=(0,$.RH)(V);return f.computeWordRanges(t.toString(),s,q,se)})}navigateValueSet(t,s,f){return this._withSyncedResources([t]).then(M=>{const V=this._modelService.getModel(t);if(!V)return null;const q=this.languageConfigurationService.getLanguageConfiguration(V.getLanguageId()).getWordDefinition(),se=q.source,_e=(0,$.RH)(q);return M.navigateValueSet(t.toString(),s,f,se,_e)})}dispose(){super.dispose(),this._disposed=!0}}function Rt(ee,t,s){return new Ie(ee,t,s)}class Ie extends Lt{constructor(t,s,f){super(t,f.keepIdleModels||!1,f.label,s),this._foreignModuleId=f.moduleId,this._foreignModuleCreateData=f.createData||null,this._foreignModuleHost=f.host||null,this._foreignProxy=null}fhr(t,s){if(!this._foreignModuleHost||typeof this._foreignModuleHost[t]!="function")return Promise.reject(new Error("Missing method "+t+" or missing main thread foreign host."));try{return Promise.resolve(this._foreignModuleHost[t].apply(this._foreignModuleHost,s))}catch(f){return Promise.reject(f)}}_getForeignProxy(){return this._foreignProxy||(this._foreignProxy=this._getProxy().then(t=>{const s=this._foreignModuleHost?k.V0(this._foreignModuleHost):[];return t.loadForeignModule(this._foreignModuleId,this._foreignModuleCreateData,s).then(f=>{this._foreignModuleCreateData=null;const M=(se,_e)=>t.fmr(se,_e),V=(se,_e)=>function(){const De=Array.prototype.slice.call(arguments,0);return _e(se,De)},q={};for(const se of f)q[se]=V(se,M);return q})})),this._foreignProxy}getProxy(){return this._getForeignProxy()}withSyncedResources(t){return this._withSyncedResources(t).then(s=>this.getProxy())}}var Ve=y(42783),dt=y(57445),bt=y(39723),Mt=y(11608);function Yt(ee){return Array.isArray(ee)}function Nt(ee){return!Yt(ee)}function Pt(ee){return typeof ee=="string"}function Ti(ee){return!Pt(ee)}function Ii(ee){return!ee}function ut(ee,t){return ee.ignoreCase&&t?t.toLowerCase():t}function Si(ee){return ee.replace(/[&<>'"_]/g,"-")}function yt(ee,t){console.log(`${ee.languageId}: ${t}`)}function fe(ee,t){return new Error(`${ee.languageId}: ${t}`)}function ze(ee,t,s,f,M){const V=/\$((\$)|(#)|(\d\d?)|[sS](\d\d?)|@(\w+))/g;let q=null;return t.replace(V,function(se,_e,De,Oe,qe,Bt,jt,Mi,ln){return Ii(De)?Ii(Oe)?!Ii(qe)&&qe<f.length?ut(ee,f[qe]):!Ii(jt)&&ee&&typeof ee[jt]=="string"?ee[jt]:(q===null&&(q=M.split("."),q.unshift(M)),!Ii(Bt)&&Bt<q.length?ut(ee,q[Bt]):""):ut(ee,s):"$"})}function Et(ee,t){let s=t;for(;s&&s.length>0;){const f=ee.tokenizer[s];if(f)return f;const M=s.lastIndexOf(".");M<0?s=null:s=s.substr(0,M)}return null}function Ot(ee,t){let s=t;for(;s&&s.length>0;){if(ee.stateNames[s])return!0;const M=s.lastIndexOf(".");M<0?s=null:s=s.substr(0,M)}return!1}var si=y(85753),_i=function(ee,t,s,f){var M=arguments.length,V=M<3?t:f===null?f=Object.getOwnPropertyDescriptor(t,s):f,q;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")V=Reflect.decorate(ee,t,s,f);else for(var se=ee.length-1;se>=0;se--)(q=ee[se])&&(V=(M<3?q(V):M>3?q(t,s,V):q(t,s))||V);return M>3&&V&&Object.defineProperty(t,s,V),V},Fe=function(ee,t){return function(s,f){t(s,f,ee)}};const Xe=5;class gt{constructor(t){this._maxCacheDepth=t,this._entries=Object.create(null)}static create(t,s){return this._INSTANCE.create(t,s)}create(t,s){if(t!==null&&t.depth>=this._maxCacheDepth)return new Xt(t,s);let f=Xt.getStackElementId(t);f.length>0&&(f+="|"),f+=s;let M=this._entries[f];return M||(M=new Xt(t,s),this._entries[f]=M,M)}}gt._INSTANCE=new gt(Xe);class Xt{constructor(t,s){this.parent=t,this.state=s,this.depth=(this.parent?this.parent.depth:0)+1}static getStackElementId(t){let s="";for(;t!==null;)s.length>0&&(s+="|"),s+=t.state,t=t.parent;return s}static _equals(t,s){for(;t!==null&&s!==null;){if(t===s)return!0;if(t.state!==s.state)return!1;t=t.parent,s=s.parent}return t===null&&s===null}equals(t){return Xt._equals(this,t)}push(t){return gt.create(this,t)}pop(){return this.parent}popall(){let t=this;for(;t.parent;)t=t.parent;return t}switchTo(t){return gt.create(this.parent,t)}}class Vt{constructor(t,s){this.languageId=t,this.state=s}equals(t){return this.languageId===t.languageId&&this.state.equals(t.state)}clone(){return this.state.clone()===this.state?this:new Vt(this.languageId,this.state)}}class ni{constructor(t){this._maxCacheDepth=t,this._entries=Object.create(null)}static create(t,s){return this._INSTANCE.create(t,s)}create(t,s){if(s!==null)return new vi(t,s);if(t!==null&&t.depth>=this._maxCacheDepth)return new vi(t,s);const f=Xt.getStackElementId(t);let M=this._entries[f];return M||(M=new vi(t,null),this._entries[f]=M,M)}}ni._INSTANCE=new ni(Xe);class vi{constructor(t,s){this.stack=t,this.embeddedLanguageData=s}clone(){return(this.embeddedLanguageData?this.embeddedLanguageData.clone():null)===this.embeddedLanguageData?this:ni.create(this.stack,this.embeddedLanguageData)}equals(t){return!(t instanceof vi)||!this.stack.equals(t.stack)?!1:this.embeddedLanguageData===null&&t.embeddedLanguageData===null?!0:this.embeddedLanguageData===null||t.embeddedLanguageData===null?!1:this.embeddedLanguageData.equals(t.embeddedLanguageData)}}class Ri{constructor(){this._tokens=[],this._languageId=null,this._lastTokenType=null,this._lastTokenLanguage=null}enterLanguage(t){this._languageId=t}emit(t,s){this._lastTokenType===s&&this._lastTokenLanguage===this._languageId||(this._lastTokenType=s,this._lastTokenLanguage=this._languageId,this._tokens.push(new d.ou(t,s,this._languageId)))}nestedLanguageTokenize(t,s,f,M){const V=f.languageId,q=f.state,se=d.dG.get(V);if(!se)return this.enterLanguage(V),this.emit(M,""),q;const _e=se.tokenize(t,s,q);if(M!==0)for(const De of _e.tokens)this._tokens.push(new d.ou(De.offset+M,De.type,De.language));else this._tokens=this._tokens.concat(_e.tokens);return this._lastTokenType=null,this._lastTokenLanguage=null,this._languageId=null,_e.endState}finalize(t){return new d.$M(this._tokens,t)}}class St{constructor(t,s){this._languageService=t,this._theme=s,this._prependTokens=null,this._tokens=[],this._currentLanguageId=0,this._lastTokenMetadata=0}enterLanguage(t){this._currentLanguageId=this._languageService.languageIdCodec.encodeLanguageId(t)}emit(t,s){const f=this._theme.match(this._currentLanguageId,s);this._lastTokenMetadata!==f&&(this._lastTokenMetadata=f,this._tokens.push(t),this._tokens.push(f))}static _merge(t,s,f){const M=t!==null?t.length:0,V=s.length,q=f!==null?f.length:0;if(M===0&&V===0&&q===0)return new Uint32Array(0);if(M===0&&V===0)return f;if(V===0&&q===0)return t;const se=new Uint32Array(M+V+q);t!==null&&se.set(t);for(let _e=0;_e<V;_e++)se[M+_e]=s[_e];return f!==null&&se.set(f,M+V),se}nestedLanguageTokenize(t,s,f,M){const V=f.languageId,q=f.state,se=d.dG.get(V);if(!se)return this.enterLanguage(V),this.emit(M,""),q;const _e=se.tokenizeEncoded(t,s,q);if(M!==0)for(let De=0,Oe=_e.tokens.length;De<Oe;De+=2)_e.tokens[De]+=M;return this._prependTokens=St._merge(this._prependTokens,this._tokens,_e.tokens),this._tokens=[],this._currentLanguageId=0,this._lastTokenMetadata=0,_e.endState}finalize(t){return new d.rY(St._merge(this._prependTokens,this._tokens,null),t)}}let ve=class Ua{constructor(t,s,f,M,V){this._configurationService=V,this._languageService=t,this._standaloneThemeService=s,this._languageId=f,this._lexer=M,this._embeddedLanguages=Object.create(null),this.embeddedLoaded=Promise.resolve(void 0);let q=!1;this._tokenizationRegistryListener=d.dG.onDidChange(se=>{if(q)return;let _e=!1;for(let De=0,Oe=se.changedLanguages.length;De<Oe;De++){const qe=se.changedLanguages[De];if(this._embeddedLanguages[qe]){_e=!0;break}}_e&&(q=!0,d.dG.fire([this._languageId]),q=!1)}),this._maxTokenizationLineLength=this._configurationService.getValue("editor.maxTokenizationLineLength",{overrideIdentifier:this._languageId}),this._configurationService.onDidChangeConfiguration(se=>{se.affectsConfiguration("editor.maxTokenizationLineLength")&&(this._maxTokenizationLineLength=this._configurationService.getValue("editor.maxTokenizationLineLength",{overrideIdentifier:this._languageId}))})}dispose(){this._tokenizationRegistryListener.dispose()}getLoadStatus(){const t=[];for(const s in this._embeddedLanguages){const f=d.dG.get(s);if(f){if(f instanceof Ua){const M=f.getLoadStatus();M.loaded===!1&&t.push(M.promise)}continue}d.dG.isResolved(s)||t.push(d.dG.getOrCreate(s))}return t.length===0?{loaded:!0}:{loaded:!1,promise:Promise.all(t).then(s=>{})}}getInitialState(){const t=gt.create(null,this._lexer.start);return ni.create(t,null)}tokenize(t,s,f){if(t.length>=this._maxTokenizationLineLength)return(0,h.$H)(this._languageId,f);const M=new Ri,V=this._tokenize(t,s,f,M);return M.finalize(V)}tokenizeEncoded(t,s,f){if(t.length>=this._maxTokenizationLineLength)return(0,h.Lh)(this._languageService.languageIdCodec.encodeLanguageId(this._languageId),f);const M=new St(this._languageService,this._standaloneThemeService.getColorTheme().tokenTheme),V=this._tokenize(t,s,f,M);return M.finalize(V)}_tokenize(t,s,f,M){return f.embeddedLanguageData?this._nestedTokenize(t,s,f,0,M):this._myTokenize(t,s,f,0,M)}_findLeavingNestedLanguageOffset(t,s){let f=this._lexer.tokenizer[s.stack.state];if(!f&&(f=Et(this._lexer,s.stack.state),!f))throw fe(this._lexer,"tokenizer state is not defined: "+s.stack.state);let M=-1,V=!1;for(const q of f){if(!Ti(q.action)||q.action.nextEmbedded!=="@pop")continue;V=!0;let se=q.regex;const _e=q.regex.source;if(_e.substr(0,4)==="^(?:"&&_e.substr(_e.length-1,1)===")"){const Oe=(se.ignoreCase?"i":"")+(se.unicode?"u":"");se=new RegExp(_e.substr(4,_e.length-5),Oe)}const De=t.search(se);De===-1||De!==0&&q.matchOnlyAtLineStart||(M===-1||De<M)&&(M=De)}if(!V)throw fe(this._lexer,'no rule containing nextEmbedded: "@pop" in tokenizer embedded state: '+s.stack.state);return M}_nestedTokenize(t,s,f,M,V){const q=this._findLeavingNestedLanguageOffset(t,f);if(q===-1){const De=V.nestedLanguageTokenize(t,s,f.embeddedLanguageData,M);return ni.create(f.stack,new Vt(f.embeddedLanguageData.languageId,De))}const se=t.substring(0,q);se.length>0&&V.nestedLanguageTokenize(se,!1,f.embeddedLanguageData,M);const _e=t.substring(q);return this._myTokenize(_e,s,f,M+q,V)}_safeRuleName(t){return t?t.name:"(unknown)"}_myTokenize(t,s,f,M,V){V.enterLanguage(this._languageId);const q=t.length,se=s&&this._lexer.includeLF?t+` `:t,_e=se.length;let De=f.embeddedLanguageData,Oe=f.stack,qe=0,Bt=null,jt=!0;for(;jt||qe<_e;){const Mi=qe,ln=Oe.depth,tn=Bt?Bt.groups.length:0,En=Oe.state;let fn=null,pn=null,Hi=null,ds=null,fo=null;if(Bt){fn=Bt.matches;const nn=Bt.groups.shift();pn=nn.matched,Hi=nn.action,ds=Bt.rule,Bt.groups.length===0&&(Bt=null)}else{if(!jt&&qe>=_e)break;jt=!1;let nn=this._lexer.tokenizer[En];if(!nn&&(nn=Et(this._lexer,En),!nn))throw fe(this._lexer,"tokenizer state is not defined: "+En);const Bi=se.substr(qe);for(const Vn of nn)if((qe===0||!Vn.matchOnlyAtLineStart)&&(fn=Bi.match(Vn.regex),fn)){pn=fn[0],Hi=Vn.action;break}}if(fn||(fn=[""],pn=""),Hi||(qe<_e&&(fn=[se.charAt(qe)],pn=fn[0]),Hi=this._lexer.defaultToken),pn===null)break;for(qe+=pn.length;Nt(Hi)&&Ti(Hi)&&Hi.test;)Hi=Hi.test(pn,fn,En,qe===_e);let kn=null;if(typeof Hi=="string"||Array.isArray(Hi))kn=Hi;else if(Hi.group)kn=Hi.group;else if(Hi.token!==null&&Hi.token!==void 0){if(Hi.tokenSubst?kn=ze(this._lexer,Hi.token,pn,fn,En):kn=Hi.token,Hi.nextEmbedded)if(Hi.nextEmbedded==="@pop"){if(!De)throw fe(this._lexer,"cannot pop embedded language if not inside one");De=null}else{if(De)throw fe(this._lexer,"cannot enter embedded language from within an embedded language");fo=ze(this._lexer,Hi.nextEmbedded,pn,fn,En)}if(Hi.goBack&&(qe=Math.max(0,qe-Hi.goBack)),Hi.switchTo&&typeof Hi.switchTo=="string"){let nn=ze(this._lexer,Hi.switchTo,pn,fn,En);if(nn[0]==="@"&&(nn=nn.substr(1)),Et(this._lexer,nn))Oe=Oe.switchTo(nn);else throw fe(this._lexer,"trying to switch to a state '"+nn+"' that is undefined in rule: "+this._safeRuleName(ds))}else{if(Hi.transform&&typeof Hi.transform=="function")throw fe(this._lexer,"action.transform not supported");if(Hi.next)if(Hi.next==="@push"){if(Oe.depth>=this._lexer.maxStack)throw fe(this._lexer,"maximum tokenizer stack size reached: ["+Oe.state+","+Oe.parent.state+",...]");Oe=Oe.push(En)}else if(Hi.next==="@pop"){if(Oe.depth<=1)throw fe(this._lexer,"trying to pop an empty stack in rule: "+this._safeRuleName(ds));Oe=Oe.pop()}else if(Hi.next==="@popall")Oe=Oe.popall();else{let nn=ze(this._lexer,Hi.next,pn,fn,En);if(nn[0]==="@"&&(nn=nn.substr(1)),Et(this._lexer,nn))Oe=Oe.push(nn);else throw fe(this._lexer,"trying to set a next state '"+nn+"' that is undefined in rule: "+this._safeRuleName(ds))}}Hi.log&&typeof Hi.log=="string"&&yt(this._lexer,this._lexer.languageId+": "+ze(this._lexer,Hi.log,pn,fn,En))}if(kn===null)throw fe(this._lexer,"lexer rule has no well-defined action in rule: "+this._safeRuleName(ds));const fr=nn=>{const Bi=this._languageService.getLanguageIdByLanguageName(nn)||this._languageService.getLanguageIdByMimeType(nn)||nn,Vn=this._getNestedEmbeddedLanguageData(Bi);if(qe<_e){const Wo=t.substr(qe);return this._nestedTokenize(Wo,s,ni.create(Oe,Vn),M+qe,V)}else return ni.create(Oe,Vn)};if(Array.isArray(kn)){if(Bt&&Bt.groups.length>0)throw fe(this._lexer,"groups cannot be nested: "+this._safeRuleName(ds));if(fn.length!==kn.length+1)throw fe(this._lexer,"matched number of groups does not match the number of actions in rule: "+this._safeRuleName(ds));let nn=0;for(let Bi=1;Bi<fn.length;Bi++)nn+=fn[Bi].length;if(nn!==pn.length)throw fe(this._lexer,"with groups, all characters should be matched in consecutive groups in rule: "+this._safeRuleName(ds));Bt={rule:ds,matches:fn,groups:[]};for(let Bi=0;Bi<kn.length;Bi++)Bt.groups[Bi]={action:kn[Bi],matched:fn[Bi+1]};qe-=pn.length;continue}else{if(kn==="@rematch"&&(qe-=pn.length,pn="",fn=null,kn="",fo!==null))return fr(fo);if(pn.length===0){if(_e===0||ln!==Oe.depth||En!==Oe.state||(Bt?Bt.groups.length:0)!==tn)continue;throw fe(this._lexer,"no progress in tokenizer in rule: "+this._safeRuleName(ds))}let nn=null;if(Pt(kn)&&kn.indexOf("@brackets")===0){const Bi=kn.substr(9),Vn=Te(this._lexer,pn);if(!Vn)throw fe(this._lexer,"@brackets token returned but no bracket defined as: "+pn);nn=Si(Vn.token+Bi)}else{const Bi=kn===""?"":kn+this._lexer.tokenPostfix;nn=Si(Bi)}Mi<q&&V.emit(Mi+M,nn)}if(fo!==null)return fr(fo)}return ni.create(Oe,De)}_getNestedEmbeddedLanguageData(t){if(!this._languageService.isRegisteredLanguageId(t))return new Vt(t,h.r3);t!==this._languageId&&(d.dG.getOrCreate(t),this._embeddedLanguages[t]=!0);const s=d.dG.get(t);return s?new Vt(t,s.getInitialState()):new Vt(t,h.r3)}};ve=_i([Fe(4,si.pG)],ve);function Te(ee,t){if(!t)return null;t=ut(ee,t);const s=ee.brackets;for(const f of s){if(f.open===t)return{token:f.token,bracketType:1};if(f.close===t)return{token:f.token,bracketType:-1}}return null}var je=function(ee,t,s,f){function M(V){return V instanceof s?V:new s(function(q){q(V)})}return new(s||(s=Promise))(function(V,q){function se(Oe){try{De(f.next(Oe))}catch(qe){q(qe)}}function _e(Oe){try{De(f.throw(Oe))}catch(qe){q(qe)}}function De(Oe){Oe.done?V(Oe.value):M(Oe.value).then(se,_e)}De((f=f.apply(ee,t||[])).next())})},nt;const at=(nt=window.trustedTypes)===null||nt===void 0?void 0:nt.createPolicy("standaloneColorizer",{createHTML:ee=>ee});class vt{static colorizeElement(t,s,f,M){M=M||{};const V=M.theme||"vs",q=M.mimeType||f.getAttribute("lang")||f.getAttribute("data-lang");if(!q)return console.error("Mode not detected"),Promise.resolve();const se=s.getLanguageIdByMimeType(q)||q;t.setTheme(V);const _e=f.firstChild?f.firstChild.nodeValue:"";f.className+=" "+V;const De=Oe=>{var qe;const Bt=(qe=at?.createHTML(Oe))!==null&&qe!==void 0?qe:Oe;f.innerHTML=Bt};return this.colorize(s,_e||"",se,M).then(De,Oe=>console.error(Oe))}static colorize(t,s,f,M){return je(this,void 0,void 0,function*(){const V=t.languageIdCodec;let q=4;M&&typeof M.tabSize=="number"&&(q=M.tabSize),$.LU(s)&&(s=s.substr(1));const se=$.uz(s);if(!t.isRegisteredLanguageId(f))return At(se,q,V);const _e=yield d.dG.getOrCreate(f);return _e?It(se,q,_e,V):At(se,q,V)})}static colorizeLine(t,s,f,M,V=4){const q=Mt.qL.isBasicASCII(t,s),se=Mt.qL.containsRTL(t,q,f);return(0,bt.Md)(new bt.zL(!1,!0,t,!1,q,se,0,M,[],V,0,0,0,0,-1,"none",!1,!1,null)).html}static colorizeModelLine(t,s,f=4){const M=t.getLineContent(s);t.tokenization.forceTokenization(s);const q=t.tokenization.getLineTokens(s).inflate();return this.colorizeLine(M,t.mightContainNonBasicASCII(),t.mightContainRTL(),q,f)}}function It(ee,t,s,f){return new Promise((M,V)=>{const q=()=>{const se=wt(ee,t,s,f);if(s instanceof ve){const _e=s.getLoadStatus();if(_e.loaded===!1){_e.promise.then(q,V);return}}M(se)};q()})}function At(ee,t,s){let f=[];const V=new Uint32Array(2);V[0]=0,V[1]=33587200;for(let q=0,se=ee.length;q<se;q++){const _e=ee[q];V[0]=_e.length;const De=new dt.f(V,_e,s),Oe=Mt.qL.isBasicASCII(_e,!0),qe=Mt.qL.containsRTL(_e,Oe,!0),Bt=(0,bt.Md)(new bt.zL(!1,!0,_e,!1,Oe,qe,0,De,[],t,0,0,0,0,-1,"none",!1,!1,null));f=f.concat(Bt.html),f.push("<br/>")}return f.join("")}function wt(ee,t,s,f){let M=[],V=s.getInitialState();for(let q=0,se=ee.length;q<se;q++){const _e=ee[q],De=s.tokenizeEncoded(_e,!0,V);dt.f.convertToEndOffset(De.tokens,_e.length);const Oe=new dt.f(De.tokens,_e,f),qe=Mt.qL.isBasicASCII(_e,!0),Bt=Mt.qL.containsRTL(_e,qe,!0),jt=(0,bt.Md)(new bt.zL(!1,!0,_e,!1,qe,Bt,0,Oe.inflate(),[],t,0,0,0,0,-1,"none",!1,!1,null));M=M.concat(jt.html),M.push("<br/>"),V=De.endState}return M.join("")}var kt=y(59407),Ct=y(76680),Gt=y(648),Ht=y(22595),Ut=y(90304),Ue=y(14333),ei=y(13072),ui=y(85525),oi=y(89044),ki=function(ee,t,s,f){var M=arguments.length,V=M<3?t:f===null?f=Object.getOwnPropertyDescriptor(t,s):f,q;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")V=Reflect.decorate(ee,t,s,f);else for(var se=ee.length-1;se>=0;se--)(q=ee[se])&&(V=(M<3?q(V):M>3?q(t,s,V):q(t,s))||V);return M>3&&V&&Object.defineProperty(t,s,V),V},Kt=function(ee,t){return function(s,f){t(s,f,ee)}},li=function(ee,t,s,f){function M(V){return V instanceof s?V:new s(function(q){q(V)})}return new(s||(s=Promise))(function(V,q){function se(Oe){try{De(f.next(Oe))}catch(qe){q(qe)}}function _e(Oe){try{De(f.throw(Oe))}catch(qe){q(qe)}}function De(Oe){Oe.done?V(Oe.value):M(Oe.value).then(se,_e)}De((f=f.apply(ee,t||[])).next())})};let Ci=class extends K.jG{constructor(t){super(),this._themeService=t,this._onCodeEditorAdd=this._register(new m.vl),this.onCodeEditorAdd=this._onCodeEditorAdd.event,this._onCodeEditorRemove=this._register(new m.vl),this.onCodeEditorRemove=this._onCodeEditorRemove.event,this._onDiffEditorAdd=this._register(new m.vl),this.onDiffEditorAdd=this._onDiffEditorAdd.event,this._onDiffEditorRemove=this._register(new m.vl),this.onDiffEditorRemove=this._onDiffEditorRemove.event,this._decorationOptionProviders=new Map,this._codeEditorOpenHandlers=new ui.w,this._modelProperties=new Map,this._codeEditors=Object.create(null),this._diffEditors=Object.create(null),this._globalStyleSheet=null}addCodeEditor(t){this._codeEditors[t.getId()]=t,this._onCodeEditorAdd.fire(t)}removeCodeEditor(t){delete this._codeEditors[t.getId()]&&this._onCodeEditorRemove.fire(t)}listCodeEditors(){return Object.keys(this._codeEditors).map(t=>this._codeEditors[t])}addDiffEditor(t){this._diffEditors[t.getId()]=t,this._onDiffEditorAdd.fire(t)}removeDiffEditor(t){delete this._diffEditors[t.getId()]&&this._onDiffEditorRemove.fire(t)}listDiffEditors(){return Object.keys(this._diffEditors).map(t=>this._diffEditors[t])}getFocusedCodeEditor(){let t=null;const s=this.listCodeEditors();for(const f of s){if(f.hasTextFocus())return f;f.hasWidgetFocus()&&(t=f)}return t}removeDecorationType(t){const s=this._decorationOptionProviders.get(t);s&&(s.refCount--,s.refCount<=0&&(this._decorationOptionProviders.delete(t),s.dispose(),this.listCodeEditors().forEach(f=>f.removeDecorationsByType(t))))}setModelProperty(t,s,f){const M=t.toString();let V;this._modelProperties.has(M)?V=this._modelProperties.get(M):(V=new Map,this._modelProperties.set(M,V)),V.set(s,f)}getModelProperty(t,s){const f=t.toString();if(this._modelProperties.has(f))return this._modelProperties.get(f).get(s)}openCodeEditor(t,s,f){return li(this,void 0,void 0,function*(){for(const M of this._codeEditorOpenHandlers){const V=yield M(t,s,f);if(V!==null)return V}return null})}registerCodeEditorOpenHandler(t){const s=this._codeEditorOpenHandlers.unshift(t);return(0,K.s)(s)}};Ci=ki([Kt(0,oi.Gy)],Ci);class mi{constructor(t){this._styleSheet=t}}var Tt=y(96655),qt=y(66726),Ni=function(ee,t,s,f){var M=arguments.length,V=M<3?t:f===null?f=Object.getOwnPropertyDescriptor(t,s):f,q;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")V=Reflect.decorate(ee,t,s,f);else for(var se=ee.length-1;se>=0;se--)(q=ee[se])&&(V=(M<3?q(V):M>3?q(t,s,V):q(t,s))||V);return M>3&&V&&Object.defineProperty(t,s,V),V},Fi=function(ee,t){return function(s,f){t(s,f,ee)}},yi=function(ee,t,s,f){function M(V){return V instanceof s?V:new s(function(q){q(V)})}return new(s||(s=Promise))(function(V,q){function se(Oe){try{De(f.next(Oe))}catch(qe){q(qe)}}function _e(Oe){try{De(f.throw(Oe))}catch(qe){q(qe)}}function De(Oe){Oe.done?V(Oe.value):M(Oe.value).then(se,_e)}De((f=f.apply(ee,t||[])).next())})};let ti=class extends Ci{constructor(t,s){super(s),this.onCodeEditorAdd(()=>this._checkContextKey()),this.onCodeEditorRemove(()=>this._checkContextKey()),this._editorIsOpen=t.createKey("editorIsOpen",!1),this._activeCodeEditor=null,this.registerCodeEditorOpenHandler((f,M,V)=>yi(this,void 0,void 0,function*(){return M?this.doOpenEditor(M,f):null}))}_checkContextKey(){let t=!1;for(const s of this.listCodeEditors())if(!s.isSimpleWidget){t=!0;break}this._editorIsOpen.set(t)}setActiveCodeEditor(t){this._activeCodeEditor=t}getActiveCodeEditor(){return this._activeCodeEditor}doOpenEditor(t,s){if(!this.findModel(t,s.resource)){if(s.resource){const V=s.resource.scheme;if(V===ei.ny.http||V===ei.ny.https)return(0,Ue.jh)(s.resource.toString()),t}return null}const M=s.options?s.options.selection:null;if(M)if(typeof M.endLineNumber=="number"&&typeof M.endColumn=="number")t.setSelection(M),t.revealRangeInCenter(M,1);else{const V={lineNumber:M.startLineNumber,column:M.startColumn};t.setPosition(V),t.revealPositionInCenter(V,1)}return t}findModel(t,s){const f=t.getModel();return f&&f.uri.toString()!==s.toString()?null:f}};ti=Ni([Fi(0,Tt.fN),Fi(1,oi.Gy)],ti),(0,qt.v)(U.T,ti);var wi=y(82399);const Qi=(0,wi.u1)("layoutService");var Vi=function(ee,t,s,f){var M=arguments.length,V=M<3?t:f===null?f=Object.getOwnPropertyDescriptor(t,s):f,q;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")V=Reflect.decorate(ee,t,s,f);else for(var se=ee.length-1;se>=0;se--)(q=ee[se])&&(V=(M<3?q(V):M>3?q(t,s,V):q(t,s))||V);return M>3&&V&&Object.defineProperty(t,s,V),V},Zi=function(ee,t){return function(s,f){t(s,f,ee)}};let Ji=class{constructor(t){this._codeEditorService=t,this.onDidLayout=m.Jh.None,this.offset={top:0,quickPickTop:0}}get dimension(){return this._dimension||(this._dimension=Ue.tG(window.document.body)),this._dimension}get hasContainer(){return!1}get container(){throw new Error("ILayoutService.container is not available in the standalone editor!")}focus(){var t;(t=this._codeEditorService.getFocusedCodeEditor())===null||t===void 0||t.focus()}};Ji=Vi([Zi(0,U.T)],Ji);let qi=class extends Ji{constructor(t,s){super(s),this._container=t}get hasContainer(){return!1}get container(){return this._container}};qi=Vi([Zi(1,U.T)],qi),(0,qt.v)(Qi,Ji);var Pi=y(66459),fi=y(3765),Sn=y(16916),cn=y(29879),en=y(38803),dn=function(ee,t,s,f){var M=arguments.length,V=M<3?t:f===null?f=Object.getOwnPropertyDescriptor(t,s):f,q;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")V=Reflect.decorate(ee,t,s,f);else for(var se=ee.length-1;se>=0;se--)(q=ee[se])&&(V=(M<3?q(V):M>3?q(t,s,V):q(t,s))||V);return M>3&&V&&Object.defineProperty(t,s,V),V},Li=function(ee,t){return function(s,f){t(s,f,ee)}},Rn=function(ee,t,s,f){function M(V){return V instanceof s?V:new s(function(q){q(V)})}return new(s||(s=Promise))(function(V,q){function se(Oe){try{De(f.next(Oe))}catch(qe){q(qe)}}function _e(Oe){try{De(f.throw(Oe))}catch(qe){q(qe)}}function De(Oe){Oe.done?V(Oe.value):M(Oe.value).then(se,_e)}De((f=f.apply(ee,t||[])).next())})};const In=!1;function xn(ee){return ee.scheme===ei.ny.file?ee.fsPath:ee.path}let Tn=0;class wn{constructor(t,s,f,M,V,q,se){this.id=++Tn,this.type=0,this.actual=t,this.label=t.label,this.confirmBeforeUndo=t.confirmBeforeUndo||!1,this.resourceLabel=s,this.strResource=f,this.resourceLabels=[this.resourceLabel],this.strResources=[this.strResource],this.groupId=M,this.groupOrder=V,this.sourceId=q,this.sourceOrder=se,this.isValid=!0}setValid(t){this.isValid=t}toString(){return`[id:${this.id}] [group:${this.groupId}] [${this.isValid?" VALID":"INVALID"}] ${this.actual.constructor.name} - ${this.actual}`}}class Ln{constructor(t,s){this.resourceLabel=t,this.reason=s}}class Cn{constructor(){this.elements=new Map}createMessage(){const t=[],s=[];for(const[,M]of this.elements)(M.reason===0?t:s).push(M.resourceLabel);const f=[];return t.length>0&&f.push(fi.kg({key:"externalRemoval",comment:["{0} is a list of filenames"]},"The following files have been closed and modified on disk: {0}.",t.join(", "))),s.length>0&&f.push(fi.kg({key:"noParallelUniverses",comment:["{0} is a list of filenames"]},"The following files have been modified in an incompatible way: {0}.",s.join(", "))),f.join(` `)}get size(){return this.elements.size}has(t){return this.elements.has(t)}set(t,s){this.elements.set(t,s)}delete(t){return this.elements.delete(t)}}class Bn{constructor(t,s,f,M,V,q,se){this.id=++Tn,this.type=1,this.actual=t,this.label=t.label,this.confirmBeforeUndo=t.confirmBeforeUndo||!1,this.resourceLabels=s,this.strResources=f,this.groupId=M,this.groupOrder=V,this.sourceId=q,this.sourceOrder=se,this.removedResources=null,this.invalidatedResources=null}canSplit(){return typeof this.actual.split=="function"}removeResource(t,s,f){this.removedResources||(this.removedResources=new Cn),this.removedResources.has(s)||this.removedResources.set(s,new Ln(t,f))}setValid(t,s,f){f?this.invalidatedResources&&(this.invalidatedResources.delete(s),this.invalidatedResources.size===0&&(this.invalidatedResources=null)):(this.invalidatedResources||(this.invalidatedResources=new Cn),this.invalidatedResources.has(s)||this.invalidatedResources.set(s,new Ln(t,0)))}toString(){return`[id:${this.id}] [group:${this.groupId}] [${this.invalidatedResources?"INVALID":" VALID"}] ${this.actual.constructor.name} - ${this.actual}`}}class Mn{constructor(t,s){this.resourceLabel=t,this.strResource=s,this._past=[],this._future=[],this.locked=!1,this.versionId=1}dispose(){for(const t of this._past)t.type===1&&t.removeResource(this.resourceLabel,this.strResource,0);for(const t of this._future)t.type===1&&t.removeResource(this.resourceLabel,this.strResource,0);this.versionId++}toString(){const t=[];t.push(`* ${this.strResource}:`);for(let s=0;s<this._past.length;s++)t.push(` * [UNDO] ${this._past[s]}`);for(let s=this._future.length-1;s>=0;s--)t.push(` * [REDO] ${this._future[s]}`);return t.join(` `)}flushAllElements(){this._past=[],this._future=[],this.versionId++}_setElementValidFlag(t,s){t.type===1?t.setValid(this.resourceLabel,this.strResource,s):t.setValid(s)}setElementsValidFlag(t,s){for(const f of this._past)s(f.actual)&&this._setElementValidFlag(f,t);for(const f of this._future)s(f.actual)&&this._setElementValidFlag(f,t)}pushElement(t){for(const s of this._future)s.type===1&&s.removeResource(this.resourceLabel,this.strResource,1);this._future=[],this._past.push(t),this.versionId++}createSnapshot(t){const s=[];for(let f=0,M=this._past.length;f<M;f++)s.push(this._past[f].id);for(let f=this._future.length-1;f>=0;f--)s.push(this._future[f].id);return new en.To(t,s)}restoreSnapshot(t){const s=t.elements.length;let f=!0,M=0,V=-1;for(let se=0,_e=this._past.length;se<_e;se++,M++){const De=this._past[se];f&&(M>=s||De.id!==t.elements[M])&&(f=!1,V=0),!f&&De.type===1&&De.removeResource(this.resourceLabel,this.strResource,0)}let q=-1;for(let se=this._future.length-1;se>=0;se--,M++){const _e=this._future[se];f&&(M>=s||_e.id!==t.elements[M])&&(f=!1,q=se),!f&&_e.type===1&&_e.removeResource(this.resourceLabel,this.strResource,0)}V!==-1&&(this._past=this._past.slice(0,V)),q!==-1&&(this._future=this._future.slice(q+1)),this.versionId++}getElements(){const t=[],s=[];for(const f of this._past)t.push(f.actual);for(const f of this._future)s.push(f.actual);return{past:t,future:s}}getClosestPastElement(){return this._past.length===0?null:this._past[this._past.length-1]}getSecondClosestPastElement(){return this._past.length<2?null:this._past[this._past.length-2]}getClosestFutureElement(){return this._future.length===0?null:this._future[this._future.length-1]}hasPastElements(){return this._past.length>0}hasFutureElements(){return this._future.length>0}splitPastWorkspaceElement(t,s){for(let f=this._past.length-1;f>=0;f--)if(this._past[f]===t){s.has(this.strResource)?this._past[f]=s.get(this.strResource):this._past.splice(f,1);break}this.versionId++}splitFutureWorkspaceElement(t,s){for(let f=this._future.length-1;f>=0;f--)if(this._future[f]===t){s.has(this.strResource)?this._future[f]=s.get(this.strResource):this._future.splice(f,1);break}this.versionId++}moveBackward(t){this._past.pop(),this._future.push(t),this.versionId++}moveForward(t){this._future.pop(),this._past.push(t),this.versionId++}}class Yn{constructor(t){this.editStacks=t,this._versionIds=[];for(let s=0,f=this.editStacks.length;s<f;s++)this._versionIds[s]=this.editStacks[s].versionId}isValid(){for(let t=0,s=this.editStacks.length;t<s;t++)if(this._versionIds[t]!==this.editStacks[t].versionId)return!1;return!0}}const Hn=new Mn("","");Hn.locked=!0;let _n=class{constructor(t,s){this._dialogService=t,this._notificationService=s,this._editStacks=new Map,this._uriComparisonKeyComputers=[]}getUriComparisonKey(t){for(const s of this._uriComparisonKeyComputers)if(s[0]===t.scheme)return s[1].getComparisonKey(t);return t.toString()}_print(t){console.log("------------------------------------"),console.log(`AFTER ${t}: `);const s=[];for(const f of this._editStacks)s.push(f[1].toString());console.log(s.join(` `))}pushElement(t,s=en.I_.None,f=en.Ym.None){if(t.type===0){const M=xn(t.resource),V=this.getUriComparisonKey(t.resource);this._pushElement(new wn(t,M,V,s.id,s.nextOrder(),f.id,f.nextOrder()))}else{const M=new Set,V=[],q=[];for(const se of t.resources){const _e=xn(se),De=this.getUriComparisonKey(se);M.has(De)||(M.add(De),V.push(_e),q.push(De))}V.length===1?this._pushElement(new wn(t,V[0],q[0],s.id,s.nextOrder(),f.id,f.nextOrder())):this._pushElement(new Bn(t,V,q,s.id,s.nextOrder(),f.id,f.nextOrder()))}In&&this._print("pushElement")}_pushElement(t){for(let s=0,f=t.strResources.length;s<f;s++){const M=t.resourceLabels[s],V=t.strResources[s];let q;this._editStacks.has(V)?q=this._editStacks.get(V):(q=new Mn(M,V),this._editStacks.set(V,q)),q.pushElement(t)}}getLastElement(t){const s=this.getUriComparisonKey(t);if(this._editStacks.has(s)){const f=this._editStacks.get(s);if(f.hasFutureElements())return null;const M=f.getClosestPastElement();return M?M.actual:null}return null}_splitPastWorkspaceElement(t,s){const f=t.actual.split(),M=new Map;for(const V of f){const q=xn(V.resource),se=this.getUriComparisonKey(V.resource),_e=new wn(V,q,se,0,0,0,0);M.set(_e.strResource,_e)}for(const V of t.strResources){if(s&&s.has(V))continue;this._editStacks.get(V).splitPastWorkspaceElement(t,M)}}_splitFutureWorkspaceElement(t,s){const f=t.actual.split(),M=new Map;for(const V of f){const q=xn(V.resource),se=this.getUriComparisonKey(V.resource),_e=new wn(V,q,se,0,0,0,0);M.set(_e.strResource,_e)}for(const V of t.strResources){if(s&&s.has(V))continue;this._editStacks.get(V).splitFutureWorkspaceElement(t,M)}}removeElements(t){const s=typeof t=="string"?t:this.getUriComparisonKey(t);this._editStacks.has(s)&&(this._editStacks.get(s).dispose(),this._editStacks.delete(s)),In&&this._print("removeElements")}setElementsValidFlag(t,s,f){const M=this.getUriComparisonKey(t);this._editStacks.has(M)&&this._editStacks.get(M).setElementsValidFlag(s,f),In&&this._print("setElementsValidFlag")}createSnapshot(t){const s=this.getUriComparisonKey(t);return this._editStacks.has(s)?this._editStacks.get(s).createSnapshot(t):new en.To(t,[])}restoreSnapshot(t){const s=this.getUriComparisonKey(t.resource);if(this._editStacks.has(s)){const f=this._editStacks.get(s);f.restoreSnapshot(t),!f.hasPastElements()&&!f.hasFutureElements()&&(f.dispose(),this._editStacks.delete(s))}In&&this._print("restoreSnapshot")}getElements(t){const s=this.getUriComparisonKey(t);return this._editStacks.has(s)?this._editStacks.get(s).getElements():{past:[],future:[]}}_findClosestUndoElementWithSource(t){if(!t)return[null,null];let s=null,f=null;for(const[M,V]of this._editStacks){const q=V.getClosestPastElement();q&&q.sourceId===t&&(!s||q.sourceOrder>s.sourceOrder)&&(s=q,f=M)}return[s,f]}canUndo(t){if(t instanceof en.Ym){const[,f]=this._findClosestUndoElementWithSource(t.id);return!!f}const s=this.getUriComparisonKey(t);return this._editStacks.has(s)?this._editStacks.get(s).hasPastElements():!1}_onError(t,s){(0,C.dz)(t);for(const f of s.strResources)this.removeElements(f);this._notificationService.error(t)}_acquireLocks(t){for(const s of t.editStacks)if(s.locked)throw new Error("Cannot acquire edit stack lock");for(const s of t.editStacks)s.locked=!0;return()=>{for(const s of t.editStacks)s.locked=!1}}_safeInvokeWithLocks(t,s,f,M,V){const q=this._acquireLocks(f);let se;try{se=s()}catch(_e){return q(),M.dispose(),this._onError(_e,t)}return se?se.then(()=>(q(),M.dispose(),V()),_e=>(q(),M.dispose(),this._onError(_e,t))):(q(),M.dispose(),V())}_invokeWorkspacePrepare(t){return Rn(this,void 0,void 0,function*(){if(typeof t.actual.prepareUndoRedo>"u")return K.jG.None;const s=t.actual.prepareUndoRedo();return typeof s>"u"?K.jG.None:s})}_invokeResourcePrepare(t,s){if(t.actual.type!==1||typeof t.actual.prepareUndoRedo>"u")return s(K.jG.None);const f=t.actual.prepareUndoRedo();return f?(0,K.Xm)(f)?s(f):f.then(M=>s(M)):s(K.jG.None)}_getAffectedEditStacks(t){const s=[];for(const f of t.strResources)s.push(this._editStacks.get(f)||Hn);return new Yn(s)}_tryToSplitAndUndo(t,s,f,M){if(s.canSplit())return this._splitPastWorkspaceElement(s,f),this._notificationService.warn(M),new yn(this._undo(t,0,!0));for(const V of s.strResources)this.removeElements(V);return this._notificationService.warn(M),new yn}_checkWorkspaceUndo(t,s,f,M){if(s.removedResources)return this._tryToSplitAndUndo(t,s,s.removedResources,fi.kg({key:"cannotWorkspaceUndo",comment:["{0} is a label for an operation. {1} is another message."]},"Could not undo '{0}' across all files. {1}",s.label,s.removedResources.createMessage()));if(M&&s.invalidatedResources)return this._tryToSplitAndUndo(t,s,s.invalidatedResources,fi.kg({key:"cannotWorkspaceUndo",comment:["{0} is a label for an operation. {1} is another message."]},"Could not undo '{0}' across all files. {1}",s.label,s.invalidatedResources.createMessage()));const V=[];for(const se of f.editStacks)se.getClosestPastElement()!==s&&V.push(se.resourceLabel);if(V.length>0)return this._tryToSplitAndUndo(t,s,null,fi.kg({key:"cannotWorkspaceUndoDueToChanges",comment:["{0} is a label for an operation. {1} is a list of filenames."]},"Could not undo '{0}' across all files because changes were made to {1}",s.label,V.join(", ")));const q=[];for(const se of f.editStacks)se.locked&&q.push(se.resourceLabel);return q.length>0?this._tryToSplitAndUndo(t,s,null,fi.kg({key:"cannotWorkspaceUndoDueToInProgressUndoRedo",comment:["{0} is a label for an operation. {1} is a list of filenames."]},"Could not undo '{0}' across all files because there is already an undo or redo operation running on {1}",s.label,q.join(", "))):f.isValid()?null:this._tryToSplitAndUndo(t,s,null,fi.kg({key:"cannotWorkspaceUndoDueToInMeantimeUndoRedo",comment:["{0} is a label for an operation. {1} is a list of filenames."]},"Could not undo '{0}' across all files because an undo or redo operation occurred in the meantime",s.label))}_workspaceUndo(t,s,f){const M=this._getAffectedEditStacks(s),V=this._checkWorkspaceUndo(t,s,M,!1);return V?V.returnValue:this._confirmAndExecuteWorkspaceUndo(t,s,M,f)}_isPartOfUndoGroup(t){if(!t.groupId)return!1;for(const[,s]of this._editStacks){const f=s.getClosestPastElement();if(f){if(f===t){const M=s.getSecondClosestPastElement();if(M&&M.groupId===t.groupId)return!0}if(f.groupId===t.groupId)return!0}}return!1}_confirmAndExecuteWorkspaceUndo(t,s,f,M){return Rn(this,void 0,void 0,function*(){if(s.canSplit()&&!this._isPartOfUndoGroup(s)){const se=yield this._dialogService.show(Pi.A.Info,fi.kg("confirmWorkspace","Would you like to undo '{0}' across all files?",s.label),[fi.kg({key:"ok",comment:["{0} denotes a number that is > 1"]},"Undo in {0} Files",f.editStacks.length),fi.kg("nok","Undo this File"),fi.kg("cancel","Cancel")],{cancelId:2});if(se.choice===2)return;if(se.choice===1)return this._splitPastWorkspaceElement(s,null),this._undo(t,0,!0);const _e=this._checkWorkspaceUndo(t,s,f,!1);if(_e)return _e.returnValue;M=!0}let V;try{V=yield this._invokeWorkspacePrepare(s)}catch(se){return this._onError(se,s)}const q=this._checkWorkspaceUndo(t,s,f,!0);if(q)return V.dispose(),q.returnValue;for(const se of f.editStacks)se.moveBackward(s);return this._safeInvokeWithLocks(s,()=>s.actual.undo(),f,V,()=>this._continueUndoInGroup(s.groupId,M))})}_resourceUndo(t,s,f){if(!s.isValid){t.flushAllElements();return}if(t.locked){const M=fi.kg({key:"cannotResourceUndoDueToInProgressUndoRedo",comment:["{0} is a label for an operation."]},"Could not undo '{0}' because there is already an undo or redo operation running.",s.label);this._notificationService.warn(M);return}return this._invokeResourcePrepare(s,M=>(t.moveBackward(s),this._safeInvokeWithLocks(s,()=>s.actual.undo(),new Yn([t]),M,()=>this._continueUndoInGroup(s.groupId,f))))}_findClosestUndoElementInGroup(t){if(!t)return[null,null];let s=null,f=null;for(const[M,V]of this._editStacks){const q=V.getClosestPastElement();q&&q.groupId===t&&(!s||q.groupOrder>s.groupOrder)&&(s=q,f=M)}return[s,f]}_continueUndoInGroup(t,s){if(!t)return;const[,f]=this._findClosestUndoElementInGroup(t);if(f)return this._undo(f,0,s)}undo(t){if(t instanceof en.Ym){const[,s]=this._findClosestUndoElementWithSource(t.id);return s?this._undo(s,t.id,!1):void 0}return typeof t=="string"?this._undo(t,0,!1):this._undo(this.getUriComparisonKey(t),0,!1)}_undo(t,s=0,f){if(!this._editStacks.has(t))return;const M=this._editStacks.get(t),V=M.getClosestPastElement();if(!V)return;if(V.groupId){const[se,_e]=this._findClosestUndoElementInGroup(V.groupId);if(V!==se&&_e)return this._undo(_e,s,f)}if((V.sourceId!==s||V.confirmBeforeUndo)&&!f)return this._confirmAndContinueUndo(t,s,V);try{return V.type===1?this._workspaceUndo(t,V,f):this._resourceUndo(M,V,f)}finally{In&&this._print("undo")}}_confirmAndContinueUndo(t,s,f){return Rn(this,void 0,void 0,function*(){if((yield this._dialogService.show(Pi.A.Info,fi.kg("confirmDifferentSource","Would you like to undo '{0}'?",f.label),[fi.kg("confirmDifferentSource.yes","Yes"),fi.kg("confirmDifferentSource.no","No")],{cancelId:1})).choice!==1)return this._undo(t,s,!0)})}_findClosestRedoElementWithSource(t){if(!t)return[null,null];let s=null,f=null;for(const[M,V]of this._editStacks){const q=V.getClosestFutureElement();q&&q.sourceId===t&&(!s||q.sourceOrder<s.sourceOrder)&&(s=q,f=M)}return[s,f]}canRedo(t){if(t instanceof en.Ym){const[,f]=this._findClosestRedoElementWithSource(t.id);return!!f}const s=this.getUriComparisonKey(t);return this._editStacks.has(s)?this._editStacks.get(s).hasFutureElements():!1}_tryToSplitAndRedo(t,s,f,M){if(s.canSplit())return this._splitFutureWorkspaceElement(s,f),this._notificationService.warn(M),new yn(this._redo(t));for(const V of s.strResources)this.removeElements(V);return this._notificationService.warn(M),new yn}_checkWorkspaceRedo(t,s,f,M){if(s.removedResources)return this._tryToSplitAndRedo(t,s,s.removedResources,fi.kg({key:"cannotWorkspaceRedo",comment:["{0} is a label for an operation. {1} is another message."]},"Could not redo '{0}' across all files. {1}",s.label,s.removedResources.createMessage()));if(M&&s.invalidatedResources)return this._tryToSplitAndRedo(t,s,s.invalidatedResources,fi.kg({key:"cannotWorkspaceRedo",comment:["{0} is a label for an operation. {1} is another message."]},"Could not redo '{0}' across all files. {1}",s.label,s.invalidatedResources.createMessage()));const V=[];for(const se of f.editStacks)se.getClosestFutureElement()!==s&&V.push(se.resourceLabel);if(V.length>0)return this._tryToSplitAndRedo(t,s,null,fi.kg({key:"cannotWorkspaceRedoDueToChanges",comment:["{0} is a label for an operation. {1} is a list of filenames."]},"Could not redo '{0}' across all files because changes were made to {1}",s.label,V.join(", ")));const q=[];for(const se of f.editStacks)se.locked&&q.push(se.resourceLabel);return q.length>0?this._tryToSplitAndRedo(t,s,null,fi.kg({key:"cannotWorkspaceRedoDueToInProgressUndoRedo",comment:["{0} is a label for an operation. {1} is a list of filenames."]},"Could not redo '{0}' across all files because there is already an undo or redo operation running on {1}",s.label,q.join(", "))):f.isValid()?null:this._tryToSplitAndRedo(t,s,null,fi.kg({key:"cannotWorkspaceRedoDueToInMeantimeUndoRedo",comment:["{0} is a label for an operation. {1} is a list of filenames."]},"Could not redo '{0}' across all files because an undo or redo operation occurred in the meantime",s.label))}_workspaceRedo(t,s){const f=this._getAffectedEditStacks(s),M=this._checkWorkspaceRedo(t,s,f,!1);return M?M.returnValue:this._executeWorkspaceRedo(t,s,f)}_executeWorkspaceRedo(t,s,f){return Rn(this,void 0,void 0,function*(){let M;try{M=yield this._invokeWorkspacePrepare(s)}catch(q){return this._onError(q,s)}const V=this._checkWorkspaceRedo(t,s,f,!0);if(V)return M.dispose(),V.returnValue;for(const q of f.editStacks)q.moveForward(s);return this._safeInvokeWithLocks(s,()=>s.actual.redo(),f,M,()=>this._continueRedoInGroup(s.groupId))})}_resourceRedo(t,s){if(!s.isValid){t.flushAllElements();return}if(t.locked){const f=fi.kg({key:"cannotResourceRedoDueToInProgressUndoRedo",comment:["{0} is a label for an operation."]},"Could not redo '{0}' because there is already an undo or redo operation running.",s.label);this._notificationService.warn(f);return}return this._invokeResourcePrepare(s,f=>(t.moveForward(s),this._safeInvokeWithLocks(s,()=>s.actual.redo(),new Yn([t]),f,()=>this._continueRedoInGroup(s.groupId))))}_findClosestRedoElementInGroup(t){if(!t)return[null,null];let s=null,f=null;for(const[M,V]of this._editStacks){const q=V.getClosestFutureElement();q&&q.groupId===t&&(!s||q.groupOrder<s.groupOrder)&&(s=q,f=M)}return[s,f]}_continueRedoInGroup(t){if(!t)return;const[,s]=this._findClosestRedoElementInGroup(t);if(s)return this._redo(s)}redo(t){if(t instanceof en.Ym){const[,s]=this._findClosestRedoElementWithSource(t.id);return s?this._redo(s):void 0}return typeof t=="string"?this._redo(t):this._redo(this.getUriComparisonKey(t))}_redo(t){if(!this._editStacks.has(t))return;const s=this._editStacks.get(t),f=s.getClosestFutureElement();if(f){if(f.groupId){const[M,V]=this._findClosestRedoElementInGroup(f.groupId);if(f!==M&&V)return this._redo(V)}try{return f.type===1?this._workspaceRedo(t,f):this._resourceRedo(s,f)}finally{In&&this._print("redo")}}}};_n=dn([Li(0,Sn.X),Li(1,cn.Ot)],_n);class yn{constructor(t){this.returnValue=t}}(0,qt.v)(en.$D,_n);var On=y(12060),sn=y(87594),zn=y(39619),Gi=y(37264),$n=y(98769),Nn=y(85003),bi=y(23877),pt=y(15365),zt=y(37042),Qt=y(59715),Di=y(27992),Ui=y(71386);class Wi{constructor(t={},s=[],f=[]){this._contents=t,this._keys=s,this._overrides=f,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}getValue(t){return t?(0,si.gD)(this.contents,t):this.contents}getOverrideValue(t,s){const f=this.getContentsForOverrideIdentifer(s);return f?t?(0,si.gD)(f,t):f:void 0}override(t){let s=this.overrideConfigurations.get(t);return s||(s=this.createOverrideConfigurationModel(t),this.overrideConfigurations.set(t,s)),s}merge(...t){const s=Ui.Go(this.contents),f=Ui.Go(this.overrides),M=[...this.keys];for(const V of t)if(!V.isEmpty()){this.mergeContents(s,V.contents);for(const q of V.overrides){const[se]=f.filter(_e=>pe.aI(_e.identifiers,q.identifiers));se?(this.mergeContents(se.contents,q.contents),se.keys.push(...q.keys),se.keys=pe.dM(se.keys)):f.push(Ui.Go(q))}for(const q of V.keys)M.indexOf(q)===-1&&M.push(q)}return new Wi(s,M,f)}freeze(){return this.frozen=!0,this}createOverrideConfigurationModel(t){const s=this.getContentsForOverrideIdentifer(t);if(!s||typeof s!="object"||!Object.keys(s).length)return this;const f={};for(const M of pe.dM([...Object.keys(this.contents),...Object.keys(s)])){let V=this.contents[M];const q=s[M];q&&(typeof V=="object"&&typeof q=="object"?(V=Ui.Go(V),this.mergeContents(V,q)):V=q),f[M]=V}return new Wi(f,this.keys,this.overrides)}mergeContents(t,s){for(const f of Object.keys(s)){if(f in t&&k.Gv(t[f])&&k.Gv(s[f])){this.mergeContents(t[f],s[f]);continue}t[f]=Ui.Go(s[f])}}checkAndFreeze(t){return this.frozen&&!Object.isFrozen(t)?Ui.ol(t):t}getContentsForOverrideIdentifer(t){let s=null,f=null;const M=V=>{V&&(f?this.mergeContents(f,V):f=Ui.Go(V))};for(const V of this.overrides)pe.aI(V.identifiers,[t])?s=V.contents:V.identifiers.includes(t)&&M(V.contents);return M(s),f}toJSON(){return{contents:this.contents,overrides:this.overrides,keys:this.keys}}setValue(t,s){this.addKey(t),(0,si.kW)(this.contents,t,s,f=>{throw new Error(f)})}removeValue(t){this.removeKey(t)&&(0,si.iB)(this.contents,t)}addKey(t){let s=this.keys.length;for(let f=0;f<s;f++)t.indexOf(this.keys[f])===0&&(s=f);this.keys.splice(s,1,t)}removeKey(t){const s=this.keys.indexOf(t);return s!==-1?(this.keys.splice(s,1),!0):!1}}class xe{constructor(t,s,f,M,V=new Wi,q=new Wi,se=new Di.fT,_e=new Wi,De=new Di.fT,Oe=!0){this._defaultConfiguration=t,this._policyConfiguration=s,this._applicationConfiguration=f,this._localUserConfiguration=M,this._remoteUserConfiguration=V,this._workspaceConfiguration=q,this._folderConfigurations=se,this._memoryConfiguration=_e,this._memoryConfigurationByResource=De,this._freeze=Oe,this._workspaceConsolidatedConfiguration=null,this._foldersConsolidatedConfigurations=new Di.fT,this._userConfiguration=null}getValue(t,s,f){return this.getConsolidatedConfigurationModel(t,s,f).getValue(t)}updateValue(t,s,f={}){let M;f.resource?(M=this._memoryConfigurationByResource.get(f.resource),M||(M=new Wi,this._memoryConfigurationByResource.set(f.resource,M))):M=this._memoryConfiguration,s===void 0?M.removeValue(t):M.setValue(t,s),f.resource||(this._workspaceConsolidatedConfiguration=null)}inspect(t,s,f){const M=this.getConsolidatedConfigurationModel(t,s,f),V=this.getFolderConfigurationModelForResource(s.resource,f),q=s.resource?this._memoryConfigurationByResource.get(s.resource)||this._memoryConfiguration:this._memoryConfiguration,se=s.overrideIdentifier?this._defaultConfiguration.freeze().override(s.overrideIdentifier).getValue(t):this._defaultConfiguration.freeze().getValue(t),_e=this._policyConfiguration.isEmpty()?void 0:this._policyConfiguration.freeze().getValue(t),De=this.applicationConfiguration.isEmpty()?void 0:this.applicationConfiguration.freeze().getValue(t),Oe=s.overrideIdentifier?this.userConfiguration.freeze().override(s.overrideIdentifier).getValue(t):this.userConfiguration.freeze().getValue(t),qe=s.overrideIdentifier?this.localUserConfiguration.freeze().override(s.overrideIdentifier).getValue(t):this.localUserConfiguration.freeze().getValue(t),Bt=s.overrideIdentifier?this.remoteUserConfiguration.freeze().override(s.overrideIdentifier).getValue(t):this.remoteUserConfiguration.freeze().getValue(t),jt=f?s.overrideIdentifier?this._workspaceConfiguration.freeze().override(s.overrideIdentifier).getValue(t):this._workspaceConfiguration.freeze().getValue(t):void 0,Mi=V?s.overrideIdentifier?V.freeze().override(s.overrideIdentifier).getValue(t):V.freeze().getValue(t):void 0,ln=s.overrideIdentifier?q.override(s.overrideIdentifier).getValue(t):q.getValue(t),tn=M.getValue(t),En=pe.dM(M.overrides.map(fn=>fn.identifiers).flat()).filter(fn=>M.getOverrideValue(t,fn)!==void 0);return{defaultValue:se,policyValue:_e,applicationValue:De,userValue:Oe,userLocalValue:qe,userRemoteValue:Bt,workspaceValue:jt,workspaceFolderValue:Mi,memoryValue:ln,value:tn,default:se!==void 0?{value:this._defaultConfiguration.freeze().getValue(t),override:s.overrideIdentifier?this._defaultConfiguration.freeze().getOverrideValue(t,s.overrideIdentifier):void 0}:void 0,policy:_e!==void 0?{value:_e}:void 0,application:De!==void 0?{value:De,override:s.overrideIdentifier?this.applicationConfiguration.freeze().getOverrideValue(t,s.overrideIdentifier):void 0}:void 0,user:Oe!==void 0?{value:this.userConfiguration.freeze().getValue(t),override:s.overrideIdentifier?this.userConfiguration.freeze().getOverrideValue(t,s.overrideIdentifier):void 0}:void 0,userLocal:qe!==void 0?{value:this.localUserConfiguration.freeze().getValue(t),override:s.overrideIdentifier?this.localUserConfiguration.freeze().getOverrideValue(t,s.overrideIdentifier):void 0}:void 0,userRemote:Bt!==void 0?{value:this.remoteUserConfiguration.freeze().getValue(t),override:s.overrideIdentifier?this.remoteUserConfiguration.freeze().getOverrideValue(t,s.overrideIdentifier):void 0}:void 0,workspace:jt!==void 0?{value:this._workspaceConfiguration.freeze().getValue(t),override:s.overrideIdentifier?this._workspaceConfiguration.freeze().getOverrideValue(t,s.overrideIdentifier):void 0}:void 0,workspaceFolder:Mi!==void 0?{value:V?.freeze().getValue(t),override:s.overrideIdentifier?V?.freeze().getOverrideValue(t,s.overrideIdentifier):void 0}:void 0,memory:ln!==void 0?{value:q.getValue(t),override:s.overrideIdentifier?q.getOverrideValue(t,s.overrideIdentifier):void 0}:void 0,overrideIdentifiers:En.length?En:void 0}}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}getConsolidatedConfigurationModel(t,s,f){let M=this.getConsolidatedConfigurationModelForResource(s,f);return s.overrideIdentifier&&(M=M.override(s.overrideIdentifier)),!this._policyConfiguration.isEmpty()&&this._policyConfiguration.getValue(t)!==void 0&&(M=M.merge(this._policyConfiguration)),M}getConsolidatedConfigurationModelForResource({resource:t},s){let f=this.getWorkspaceConsolidatedConfiguration();if(s&&t){const M=s.getFolder(t);M&&(f=this.getFolderConsolidatedConfiguration(M.uri)||f);const V=this._memoryConfigurationByResource.get(t);V&&(f=f.merge(V))}return f}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(t){let s=this._foldersConsolidatedConfigurations.get(t);if(!s){const f=this.getWorkspaceConsolidatedConfiguration(),M=this._folderConfigurations.get(t);M?(s=f.merge(M),this._freeze&&(s=s.freeze()),this._foldersConsolidatedConfigurations.set(t,s)):s=f}return s}getFolderConfigurationModelForResource(t,s){if(s&&t){const f=s.getFolder(t);if(f)return this._folderConfigurations.get(f.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((t,s)=>{const{contents:f,overrides:M,keys:V}=this._folderConfigurations.get(s);return t.push([s,{contents:f,overrides:M,keys:V}]),t},[])}}static parse(t){const s=this.parseConfigurationModel(t.defaults),f=this.parseConfigurationModel(t.policy),M=this.parseConfigurationModel(t.application),V=this.parseConfigurationModel(t.user),q=this.parseConfigurationModel(t.workspace),se=t.folders.reduce((_e,De)=>(_e.set(Gi.r.revive(De[0]),this.parseConfigurationModel(De[1])),_e),new Di.fT);return new xe(s,f,M,V,new Wi,q,se,new Wi,new Di.fT,!1)}static parseConfigurationModel(t){return new Wi(t.contents,t.keys,t.overrides).freeze()}}class a{constructor(t,s,f,M){this.change=t,this.previous=s,this.currentConfiguraiton=f,this.currentWorkspace=M,this._previousConfiguration=void 0;const V=new Set;t.keys.forEach(se=>V.add(se)),t.overrides.forEach(([,se])=>se.forEach(_e=>V.add(_e))),this.affectedKeys=[...V.values()];const q=new Wi;this.affectedKeys.forEach(se=>q.setValue(se,{})),this.affectedKeysTree=q.contents}get previousConfiguration(){return!this._previousConfiguration&&this.previous&&(this._previousConfiguration=xe.parse(this.previous.data)),this._previousConfiguration}affectsConfiguration(t,s){var f;if(this.doesAffectedKeysTreeContains(this.affectedKeysTree,t)){if(s){const M=this.previousConfiguration?this.previousConfiguration.getValue(t,s,(f=this.previous)===null||f===void 0?void 0:f.workspace):void 0,V=this.currentConfiguraiton.getValue(t,s,this.currentWorkspace);return!Ui.aI(M,V)}return!0}return!1}doesAffectedKeysTreeContains(t,s){let f=(0,si.ad)({[s]:!0},()=>{}),M;for(;typeof f=="object"&&(M=Object.keys(f)[0]);){if(t=t[M],!t)return!1;f=f[M]}return!0}}const n=/^(cursor|delete)/;class c extends K.jG{constructor(t,s,f,M,V){super(),this._contextKeyService=t,this._commandService=s,this._telemetryService=f,this._notificationService=M,this._logService=V,this._onDidUpdateKeybindings=this._register(new m.vl),this._currentChord=null,this._currentChordChecker=new w.vb,this._currentChordStatusMessage=null,this._ignoreSingleModifiers=I.EMPTY,this._currentSingleModifier=null,this._currentSingleModifierClearTimeout=new w.pc,this._logging=!1}get onDidUpdateKeybindings(){return this._onDidUpdateKeybindings?this._onDidUpdateKeybindings.event:m.Jh.None}dispose(){super.dispose()}_log(t){this._logging&&this._logService.info(`[KeybindingService]: ${t}`)}getKeybindings(){return this._getResolver().getKeybindings()}lookupKeybinding(t,s){const f=this._getResolver().lookupPrimaryKeybinding(t,s||this._contextKeyService);if(f)return f.resolvedKeybinding}dispatchEvent(t,s){return this._dispatch(t,s)}softDispatch(t,s){this._log("/ Soft dispatching keyboard event");const f=this.resolveKeyboardEvent(t);if(f.isChord())return console.warn("Unexpected keyboard event mapped to a chord"),null;const[M]=f.getDispatchParts();if(M===null)return this._log("\\ Keyboard event cannot be dispatched"),null;const V=this._contextKeyService.getContext(s),q=this._currentChord?this._currentChord.keypress:null;return this._getResolver().resolve(V,q,M)}_enterChordMode(t,s){this._currentChord={keypress:t,label:s},this._currentChordStatusMessage=this._notificationService.status(fi.kg("first.chord","({0}) was pressed. Waiting for second key of chord...",s));const f=Date.now();this._currentChordChecker.cancelAndSet(()=>{if(!this._documentHasFocus()){this._leaveChordMode();return}Date.now()-f>5e3&&this._leaveChordMode()},500)}_leaveChordMode(){this._currentChordStatusMessage&&(this._currentChordStatusMessage.dispose(),this._currentChordStatusMessage=null),this._currentChordChecker.cancel(),this._currentChord=null}_dispatch(t,s){return this._doDispatch(this.resolveKeyboardEvent(t),s,!1)}_singleModifierDispatch(t,s){const f=this.resolveKeyboardEvent(t),[M]=f.getSingleModifierDispatchParts();if(M)return this._ignoreSingleModifiers.has(M)?(this._log(`+ Ignoring single modifier ${M} due to it being pressed together with other keys.`),this._ignoreSingleModifiers=I.EMPTY,this._currentSingleModifierClearTimeout.cancel(),this._currentSingleModifier=null,!1):(this._ignoreSingleModifiers=I.EMPTY,this._currentSingleModifier===null?(this._log(`+ Storing single modifier for possible chord ${M}.`),this._currentSingleModifier=M,this._currentSingleModifierClearTimeout.cancelAndSet(()=>{this._log("+ Clearing single modifier due to 300ms elapsed."),this._currentSingleModifier=null},300),!1):M===this._currentSingleModifier?(this._log(`/ Dispatching single modifier chord ${M} ${M}`),this._currentSingleModifierClearTimeout.cancel(),this._currentSingleModifier=null,this._doDispatch(f,s,!0)):(this._log(`+ Clearing single modifier due to modifier mismatch: ${this._currentSingleModifier} ${M}`),this._currentSingleModifierClearTimeout.cancel(),this._currentSingleModifier=null,!1));const[V]=f.getParts();return this._ignoreSingleModifiers=new I(V),this._currentSingleModifier!==null&&this._log("+ Clearing single modifier due to other key up."),this._currentSingleModifierClearTimeout.cancel(),this._currentSingleModifier=null,!1}_doDispatch(t,s,f=!1){let M=!1;if(t.isChord())return console.warn("Unexpected keyboard event mapped to a chord"),!1;let V=null,q=null;if(f){const[Oe]=t.getSingleModifierDispatchParts();V=Oe,q=Oe}else[V]=t.getDispatchParts(),q=this._currentChord?this._currentChord.keypress:null;if(V===null)return this._log("\\ Keyboard event cannot be dispatched in keydown phase."),M;const se=this._contextKeyService.getContext(s),_e=t.getLabel(),De=this._getResolver().resolve(se,q,V);return this._logService.trace("KeybindingService#dispatch",_e,De?.commandId),De&&De.enterChord?(M=!0,this._enterChordMode(V,_e),this._log("+ Entering chord mode..."),M):(this._currentChord&&(!De||!De.commandId)&&(this._log(`+ Leaving chord mode: Nothing bound to "${this._currentChord.label} ${_e}".`),this._notificationService.status(fi.kg("missing.chord","The key combination ({0}, {1}) is not a command.",this._currentChord.label,_e),{hideAfter:10*1e3}),M=!0),this._leaveChordMode(),De&&De.commandId&&(De.bubble||(M=!0),this._log(`+ Invoking command ${De.commandId}.`),typeof De.commandArgs>"u"?this._commandService.executeCommand(De.commandId).then(void 0,Oe=>this._notificationService.warn(Oe)):this._commandService.executeCommand(De.commandId,De.commandArgs).then(void 0,Oe=>this._notificationService.warn(Oe)),n.test(De.commandId)||this._telemetryService.publicLog2("workbenchActionExecuted",{id:De.commandId,from:"keybinding"})),M)}mightProducePrintableCharacter(t){return t.ctrlKey||t.metaKey?!1:t.keyCode>=31&&t.keyCode<=56||t.keyCode>=21&&t.keyCode<=30}}class I{constructor(t){this._ctrlKey=t?t.ctrlKey:!1,this._shiftKey=t?t.shiftKey:!1,this._altKey=t?t.altKey:!1,this._metaKey=t?t.metaKey:!1}has(t){switch(t){case"ctrl":return this._ctrlKey;case"shift":return this._shiftKey;case"alt":return this._altKey;case"meta":return this._metaKey}}}I.EMPTY=new I(null);var F=y(56071);class J{constructor(t,s,f){this._log=f,this._defaultKeybindings=t,this._defaultBoundCommands=new Map;for(const M of t){const V=M.command;V&&V.charAt(0)!=="-"&&this._defaultBoundCommands.set(V,!0)}this._map=new Map,this._lookupMap=new Map,this._keybindings=J.handleRemovals([].concat(t).concat(s));for(let M=0,V=this._keybindings.length;M<V;M++){const q=this._keybindings[M];q.keypressParts.length!==0&&(q.when&&q.when.type===0||this._addKeyPress(q.keypressParts[0],q))}}static _isTargetedForRemoval(t,s,f,M){return!(s&&t.keypressParts[0]!==s||f&&t.keypressParts[1]!==f||M&&(!t.when||!(0,Tt.jQ)(M,t.when)))}static handleRemovals(t){const s=new Map;for(let M=0,V=t.length;M<V;M++){const q=t[M];if(q.command&&q.command.charAt(0)==="-"){const se=q.command.substring(1);s.has(se)?s.get(se).push(q):s.set(se,[q])}}if(s.size===0)return t;const f=[];for(let M=0,V=t.length;M<V;M++){const q=t[M];if(!q.command||q.command.length===0){f.push(q);continue}if(q.command.charAt(0)==="-")continue;const se=s.get(q.command);if(!se||!q.isDefault){f.push(q);continue}let _e=!1;for(const De of se){const Oe=De.keypressParts[0],qe=De.keypressParts[1],Bt=De.when;if(this._isTargetedForRemoval(q,Oe,qe,Bt)){_e=!0;break}}if(!_e){f.push(q);continue}}return f}_addKeyPress(t,s){const f=this._map.get(t);if(typeof f>"u"){this._map.set(t,[s]),this._addToLookupMap(s);return}for(let M=f.length-1;M>=0;M--){const V=f[M];if(V.command===s.command)continue;const q=V.keypressParts.length>1,se=s.keypressParts.length>1;q&&se&&V.keypressParts[1]!==s.keypressParts[1]||J.whenIsEntirelyIncluded(V.when,s.when)&&this._removeFromLookupMap(V)}f.push(s),this._addToLookupMap(s)}_addToLookupMap(t){if(!t.command)return;let s=this._lookupMap.get(t.command);typeof s>"u"?(s=[t],this._lookupMap.set(t.command,s)):s.push(t)}_removeFromLookupMap(t){if(!t.command)return;const s=this._lookupMap.get(t.command);if(!(typeof s>"u")){for(let f=0,M=s.length;f<M;f++)if(s[f]===t){s.splice(f,1);return}}}static whenIsEntirelyIncluded(t,s){return!s||s.type===1?!0:!t||t.type===1?!1:(0,Tt.M0)(t,s)}getKeybindings(){return this._keybindings}lookupPrimaryKeybinding(t,s){const f=this._lookupMap.get(t);if(typeof f>"u"||f.length===0)return null;if(f.length===1)return f[0];for(let M=f.length-1;M>=0;M--){const V=f[M];if(s.contextMatchesRules(V.when))return V}return f[f.length-1]}resolve(t,s,f){this._log(`| Resolving ${f}${s?` chorded from ${s}`:""}`);let M=null;if(s!==null){const q=this._map.get(s);if(typeof q>"u")return this._log("\\ No keybinding entries."),null;M=[];for(let se=0,_e=q.length;se<_e;se++){const De=q[se];De.keypressParts[1]===f&&M.push(De)}}else{const q=this._map.get(f);if(typeof q>"u")return this._log("\\ No keybinding entries."),null;M=q}const V=this._findCommand(t,M);return V?s===null&&V.keypressParts.length>1&&V.keypressParts[1]!==null?(this._log(`\\ From ${M.length} keybinding entries, matched chord, when: ${ae(V.when)}, source: ${de(V)}.`),{enterChord:!0,leaveChord:!1,commandId:null,commandArgs:null,bubble:!1}):(this._log(`\\ From ${M.length} keybinding entries, matched ${V.command}, when: ${ae(V.when)}, source: ${de(V)}.`),{enterChord:!1,leaveChord:V.keypressParts.length>1,commandId:V.command,commandArgs:V.commandArgs,bubble:V.bubble}):(this._log(`\\ From ${M.length} keybinding entries, no when clauses matched the context.`),null)}_findCommand(t,s){for(let f=s.length-1;f>=0;f--){const M=s[f];if(J._contextMatchesRules(t,M.when))return M}return null}static _contextMatchesRules(t,s){return s?s.evaluate(t):!0}}function ae(ee){return ee?`${ee.serialize()}`:"no when condition"}function de(ee){return ee.extensionId?ee.isBuiltinExtension?`built-in extension ${ee.extensionId}`:`user extension ${ee.extensionId}`:ee.isDefault?"built-in":"user"}var Ce=y(70802);class Ee{constructor(t,s,f,M,V,q,se){this._resolvedKeybindingItemBrand=void 0,this.resolvedKeybinding=t,this.keypressParts=t?Ne(t.getDispatchParts()):[],t&&this.keypressParts.length===0&&(this.keypressParts=Ne(t.getSingleModifierDispatchParts())),this.bubble=s?s.charCodeAt(0)===94:!1,this.command=this.bubble?s.substr(1):s,this.commandArgs=f,this.when=M,this.isDefault=V,this.extensionId=q,this.isBuiltinExtension=se}}function Ne(ee){const t=[];for(let s=0,f=ee.length;s<f;s++){const M=ee[s];if(!M)return t;t.push(M)}return t}var He=y(68387),Ze=y(98315);class et extends zn.z5{constructor(t,s){if(super(),s.length===0)throw(0,C.Qg)("parts");this._os=t,this._parts=s}getLabel(){return Ze.Of.toLabel(this._os,this._parts,t=>this._getLabel(t))}getAriaLabel(){return Ze.r0.toLabel(this._os,this._parts,t=>this._getAriaLabel(t))}getElectronAccelerator(){return this._parts.length>1||this._parts[0].isDuplicateModifierCase()?null:Ze.rr.toLabel(this._os,this._parts,t=>this._getElectronAccelerator(t))}isChord(){return this._parts.length>1}getParts(){return this._parts.map(t=>this._getPart(t))}_getPart(t){return new zn.QB(t.ctrlKey,t.shiftKey,t.altKey,t.metaKey,this._getLabel(t),this._getAriaLabel(t))}getDispatchParts(){return this._parts.map(t=>this._getDispatchPart(t))}getSingleModifierDispatchParts(){return this._parts.map(t=>this._getSingleModifierDispatchPart(t))}}class ot extends et{constructor(t,s){super(s,t.parts)}_keyCodeToUILabel(t){if(this._os===2)switch(t){case 15:return"\u2190";case 16:return"\u2191";case 17:return"\u2192";case 18:return"\u2193"}return He.YM.toString(t)}_getLabel(t){return t.isDuplicateModifierCase()?"":this._keyCodeToUILabel(t.keyCode)}_getAriaLabel(t){return t.isDuplicateModifierCase()?"":He.YM.toString(t.keyCode)}_getElectronAccelerator(t){return He.YM.toElectronAccelerator(t.keyCode)}_getDispatchPart(t){return ot.getDispatchStr(t)}static getDispatchStr(t){if(t.isModifierKey())return null;let s="";return t.ctrlKey&&(s+="ctrl+"),t.shiftKey&&(s+="shift+"),t.altKey&&(s+="alt+"),t.metaKey&&(s+="meta+"),s+=He.YM.toString(t.keyCode),s}_getSingleModifierDispatchPart(t){return t.keyCode===5&&!t.shiftKey&&!t.altKey&&!t.metaKey?"ctrl":t.keyCode===4&&!t.ctrlKey&&!t.altKey&&!t.metaKey?"shift":t.keyCode===6&&!t.ctrlKey&&!t.shiftKey&&!t.metaKey?"alt":t.keyCode===57&&!t.ctrlKey&&!t.shiftKey&&!t.altKey?"meta":null}static _scanCodeToKeyCode(t){const s=He.Fo[t];if(s!==-1)return s;switch(t){case 10:return 31;case 11:return 32;case 12:return 33;case 13:return 34;case 14:return 35;case 15:return 36;case 16:return 37;case 17:return 38;case 18:return 39;case 19:return 40;case 20:return 41;case 21:return 42;case 22:return 43;case 23:return 44;case 24:return 45;case 25:return 46;case 26:return 47;case 27:return 48;case 28:return 49;case 29:return 50;case 30:return 51;case 31:return 52;case 32:return 53;case 33:return 54;case 34:return 55;case 35:return 56;case 36:return 22;case 37:return 23;case 38:return 24;case 39:return 25;case 40:return 26;case 41:return 27;case 42:return 28;case 43:return 29;case 44:return 30;case 45:return 21;case 51:return 83;case 52:return 81;case 53:return 87;case 54:return 89;case 55:return 88;case 56:return 0;case 57:return 80;case 58:return 90;case 59:return 86;case 60:return 82;case 61:return 84;case 62:return 85;case 106:return 92}return 0}static _resolveSimpleUserBinding(t){if(!t)return null;if(t instanceof zn.h$)return t;const s=this._scanCodeToKeyCode(t.scanCode);return s===0?null:new zn.h$(t.ctrlKey,t.shiftKey,t.altKey,t.metaKey,s)}static resolveUserBinding(t,s){const f=Ne(t.map(M=>this._resolveSimpleUserBinding(M)));return f.length>0?[new ot(new zn.p(f),s)]:[]}}var lt=y(8377),_t=y(44023),Ft=y(76243),ci=y(26851),Oi=y(45933),on=y(22467),gn=y(84657),hn=y(52348),Yi=y(51577),Ei=y(4580),An;(function(ee){ee[ee.AVOID=0]="AVOID",ee[ee.ALIGN=1]="ALIGN"})(An||(An={}));function Xn(ee,t,s){const f=s.mode===An.ALIGN?s.offset:s.offset+s.size,M=s.mode===An.ALIGN?s.offset+s.size:s.offset;return s.position===0?t<=ee-f?f:t<=M?M-t:Math.max(ee-t,0):t<=M?M-t:t<=ee-f?f:0}class rs extends K.jG{constructor(t,s){super(),this.container=null,this.delegate=null,this.toDisposeOnClean=K.jG.None,this.toDisposeOnSetContainer=K.jG.None,this.shadowRoot=null,this.shadowRootHostElement=null,this.view=Ue.$(".context-view"),this.useFixedPosition=!1,this.useShadowDOM=!1,Ue.jD(this.view),this.setContainer(t,s),this._register((0,K.s)(()=>this.setContainer(null,1)))}setContainer(t,s){var f;if(this.container&&(this.toDisposeOnSetContainer.dispose(),this.shadowRoot?(this.shadowRoot.removeChild(this.view),this.shadowRoot=null,(f=this.shadowRootHostElement)===null||f===void 0||f.remove(),this.shadowRootHostElement=null):this.container.removeChild(this.view),this.container=null),t){if(this.container=t,this.useFixedPosition=s!==1,this.useShadowDOM=s===3,this.useShadowDOM){this.shadowRootHostElement=Ue.$(".shadow-root-host"),this.container.appendChild(this.shadowRootHostElement),this.shadowRoot=this.shadowRootHostElement.attachShadow({mode:"open"});const V=document.createElement("style");V.textContent=is,this.shadowRoot.appendChild(V),this.shadowRoot.appendChild(this.view),this.shadowRoot.appendChild(Ue.$("slot"))}else this.container.appendChild(this.view);const M=new K.Cm;rs.BUBBLE_UP_EVENTS.forEach(V=>{M.add(Ue.b2(this.container,V,q=>{this.onDOMEvent(q,!1)}))}),rs.BUBBLE_DOWN_EVENTS.forEach(V=>{M.add(Ue.b2(this.container,V,q=>{this.onDOMEvent(q,!0)},!0))}),this.toDisposeOnSetContainer=M}}show(t){var s,f;this.isVisible()&&this.hide(),Ue.w_(this.view),this.view.className="context-view",this.view.style.top="0px",this.view.style.left="0px",this.view.style.zIndex="2575",this.view.style.position=this.useFixedPosition?"fixed":"absolute",Ue.WU(this.view),this.toDisposeOnClean=t.render(this.view)||K.jG.None,this.delegate=t,this.doLayout(),(f=(s=this.delegate).focus)===null||f===void 0||f.call(s)}getViewElement(){return this.view}layout(){if(this.isVisible()){if(this.delegate.canRelayout===!1&&!(v.un&&Yi.e.pointerEvents)){this.hide();return}this.delegate.layout&&this.delegate.layout(),this.doLayout()}}doLayout(){if(!this.isVisible())return;const t=this.delegate.getAnchor();let s;if(Ue.sb(t)){const qe=Ue.BK(t),Bt=Ue.mU(t);s={top:qe.top*Bt,left:qe.left*Bt,width:qe.width*Bt,height:qe.height*Bt}}else s={top:t.y,left:t.x,width:t.width||1,height:t.height||2};const f=Ue.Tr(this.view),M=Ue.OK(this.view),V=this.delegate.anchorPosition||0,q=this.delegate.anchorAlignment||0,se=this.delegate.anchorAxisAlignment||0;let _e,De;if(se===0){const qe={offset:s.top-window.pageYOffset,size:s.height,position:V===0?0:1},Bt={offset:s.left,size:s.width,position:q===0?0:1,mode:An.ALIGN};_e=Xn(window.innerHeight,M,qe)+window.pageYOffset,Ei.Q.intersects({start:_e,end:_e+M},{start:qe.offset,end:qe.offset+qe.size})&&(Bt.mode=An.AVOID),De=Xn(window.innerWidth,f,Bt)}else{const qe={offset:s.left,size:s.width,position:q===0?0:1},Bt={offset:s.top,size:s.height,position:V===0?0:1,mode:An.ALIGN};De=Xn(window.innerWidth,f,qe),Ei.Q.intersects({start:De,end:De+f},{start:qe.offset,end:qe.offset+qe.size})&&(Bt.mode=An.AVOID),_e=Xn(window.innerHeight,M,Bt)+window.pageYOffset}this.view.classList.remove("top","bottom","left","right"),this.view.classList.add(V===0?"bottom":"top"),this.view.classList.add(q===0?"left":"right"),this.view.classList.toggle("fixed",this.useFixedPosition);const Oe=Ue.BK(this.container);this.view.style.top=`${_e-(this.useFixedPosition?Ue.BK(this.view).top:Oe.top)}px`,this.view.style.left=`${De-(this.useFixedPosition?Ue.BK(this.view).left:Oe.left)}px`,this.view.style.width="initial"}hide(t){const s=this.delegate;this.delegate=null,s?.onHide&&s.onHide(t),this.toDisposeOnClean.dispose(),Ue.jD(this.view)}isVisible(){return!!this.delegate}onDOMEvent(t,s){this.delegate&&(this.delegate.onDOMEvent?this.delegate.onDOMEvent(t,document.activeElement):s&&!Ue.QX(t.target,this.container)&&this.hide())}dispose(){this.hide(),super.dispose()}}rs.BUBBLE_UP_EVENTS=["click","keydown","focus","blur"],rs.BUBBLE_DOWN_EVENTS=["click"];const is=` :host { all: initial; /* 1st rule so subsequent properties are reset. */ } @font-face { font-family: "codicon"; font-display: block; src: url("./codicon.ttf?5d4d76ab2ce5108968ad644d591a16a6") format("truetype"); } .codicon[class*='codicon-'] { font: normal normal normal 16px/1 codicon; display: inline-block; text-decoration: none; text-rendering: auto; text-align: center; -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; user-select: none; -webkit-user-select: none; -ms-user-select: none; } :host { font-family: -apple-system, BlinkMacSystemFont, "Segoe WPC", "Segoe UI", "HelveticaNeue-Light", system-ui, "Ubuntu", "Droid Sans", sans-serif; } :host-context(.mac) { font-family: -apple-system, BlinkMacSystemFont, sans-serif; } :host-context(.mac:lang(zh-Hans)) { font-family: -apple-system, BlinkMacSystemFont, "PingFang SC", "Hiragino Sans GB", sans-serif; } :host-context(.mac:lang(zh-Hant)) { font-family: -apple-system, BlinkMacSystemFont, "PingFang TC", sans-serif; } :host-context(.mac:lang(ja)) { font-family: -apple-system, BlinkMacSystemFont, "Hiragino Kaku Gothic Pro", sans-serif; } :host-context(.mac:lang(ko)) { font-family: -apple-system, BlinkMacSystemFont, "Nanum Gothic", "Apple SD Gothic Neo", "AppleGothic", sans-serif; } :host-context(.windows) { font-family: "Segoe WPC", "Segoe UI", sans-serif; } :host-context(.windows:lang(zh-Hans)) { font-family: "Segoe WPC", "Segoe UI", "Microsoft YaHei", sans-serif; } :host-context(.windows:lang(zh-Hant)) { font-family: "Segoe WPC", "Segoe UI", "Microsoft Jhenghei", sans-serif; } :host-context(.windows:lang(ja)) { font-family: "Segoe WPC", "Segoe UI", "Yu Gothic UI", "Meiryo UI", sans-serif; } :host-context(.windows:lang(ko)) { font-family: "Segoe WPC", "Segoe UI", "Malgun Gothic", "Dotom", sans-serif; } :host-context(.linux) { font-family: system-ui, "Ubuntu", "Droid Sans", sans-serif; } :host-context(.linux:lang(zh-Hans)) { font-family: system-ui, "Ubuntu", "Droid Sans", "Source Han Sans SC", "Source Han Sans CN", "Source Han Sans", sans-serif; } :host-context(.linux:lang(zh-Hant)) { font-family: system-ui, "Ubuntu", "Droid Sans", "Source Han Sans TC", "Source Han Sans TW", "Source Han Sans", sans-serif; } :host-context(.linux:lang(ja)) { font-family: system-ui, "Ubuntu", "Droid Sans", "Source Han Sans J", "Source Han Sans JP", "Source Han Sans", sans-serif; } :host-context(.linux:lang(ko)) { font-family: system-ui, "Ubuntu", "Droid Sans", "Source Han Sans K", "Source Han Sans JR", "Source Han Sans", "UnDotum", "FBaekmuk Gulim", sans-serif; } `;var xs=function(ee,t,s,f){var M=arguments.length,V=M<3?t:f===null?f=Object.getOwnPropertyDescriptor(t,s):f,q;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")V=Reflect.decorate(ee,t,s,f);else for(var se=ee.length-1;se>=0;se--)(q=ee[se])&&(V=(M<3?q(V):M>3?q(t,s,V):q(t,s))||V);return M>3&&V&&Object.defineProperty(t,s,V),V},ys=function(ee,t){return function(s,f){t(s,f,ee)}};let Ss=class extends K.jG{constructor(t){super(),this.layoutService=t,this.currentViewDisposable=K.jG.None,this.container=t.hasContainer?t.container:null,this.contextView=this._register(new rs(this.container,1)),this.layout(),this._register(t.onDidLayout(()=>this.layout()))}setContainer(t,s){this.contextView.setContainer(t,s||1)}showContextView(t,s,f){s?(s!==this.container||this.shadowRoot!==f)&&(this.container=s,this.setContainer(s,f?3:2)):this.layoutService.hasContainer&&this.container!==this.layoutService.container&&(this.container=this.layoutService.container,this.setContainer(this.container,1)),this.shadowRoot=f,this.contextView.show(t);const M=(0,K.s)(()=>{this.currentViewDisposable===M&&this.hideContextView()});return this.currentViewDisposable=M,M}getContextViewElement(){return this.contextView.getViewElement()}layout(){this.contextView.layout()}hideContextView(t){this.contextView.hide(t)}};Ss=xs([ys(0,Qi)],Ss);var Fs=y(78518),ns=y(18019),Zs=function(ee,t,s,f){function M(V){return V instanceof s?V:new s(function(q){q(V)})}return new(s||(s=Promise))(function(V,q){function se(Oe){try{De(f.next(Oe))}catch(qe){q(qe)}}function _e(Oe){try{De(f.throw(Oe))}catch(qe){q(qe)}}function De(Oe){Oe.done?V(Oe.value):M(Oe.value).then(se,_e)}De((f=f.apply(ee,t||[])).next())})};const Ts="**",Ys="/",Un="[/\\\\]",rn="[^/\\\\]",hs=/\//g;function po(ee,t){switch(ee){case 0:return"";case 1:return`${rn}*?`;default:return`(?:${Un}|${rn}+${Un}${t?`|${Un}${rn}+`:""})*?`}}function gs(ee,t){if(!ee)return[];const s=[];let f=!1,M=!1,V="";for(const q of ee){switch(q){case t:if(!f&&!M){s.push(V),V="";continue}break;case"{":f=!0;break;case"}":f=!1;break;case"[":M=!0;break;case"]":M=!1;break}V+=q}return V&&s.push(V),s}function Uo(ee){if(!ee)return"";let t="";const s=gs(ee,Ys);if(s.every(f=>f===Ts))t=".*";else{let f=!1;s.forEach((M,V)=>{if(M===Ts){if(f)return;t+=po(2,V===s.length-1)}else{let q=!1,se="",_e=!1,De="";for(const Oe of M){if(Oe!=="}"&&q){se+=Oe;continue}if(_e&&(Oe!=="]"||!De)){let qe;Oe==="-"?qe=Oe:(Oe==="^"||Oe==="!")&&!De?qe="^":Oe===Ys?qe="":qe=(0,$.bm)(Oe),De+=qe;continue}switch(Oe){case"{":q=!0;continue;case"[":_e=!0;continue;case"}":{const Bt=`(?:${gs(se,",").map(jt=>Uo(jt)).join("|")})`;t+=Bt,q=!1,se="";break}case"]":{t+="["+De+"]",_e=!1,De="";break}case"?":t+=rn;continue;case"*":t+=po(1);continue;default:t+=(0,$.bm)(Oe)}}V<s.length-1&&(s[V+1]!==Ts||V+2<s.length)&&(t+=Un)}f=M===Ts})}return t}const es=/^\*\*\/\*\.[\w\.-]+$/,us=/^\*\*\/([\w\.-]+)\/?$/,Ls=/^{\*\*\/\*?[\w\.-]+\/?(,\*\*\/\*?[\w\.-]+\/?)*}$/,_r=/^{\*\*\/\*?[\w\.-]+(\/(\*\*)?)?(,\*\*\/\*?[\w\.-]+(\/(\*\*)?)?)*}$/,vr=/^\*\*((\/[\w\.-]+)+)\/?$/,Cr=/^([\w\.-]+(\/[\w\.-]+)*)\/?$/,vs=new Di.qK(1e4),Ms=function(){return!1},Gn=function(){return null};function Xs(ee,t){if(!ee)return Gn;let s;typeof ee!="string"?s=ee.pattern:s=ee,s=s.trim();const f=`${s}_${!!t.trimForExclusions}`;let M=vs.get(f);if(M)return Ns(M,ee);let V;return es.test(s)?M=Js(s.substr(4),s):(V=us.exec(Ws(s,t)))?M=qs(V[1],s):(t.trimForExclusions?_r:Ls).test(s)?M=Vs(s,t):(V=vr.exec(Ws(s,t)))?M=_o(V[1].substr(1),s,!0):(V=Cr.exec(Ws(s,t)))?M=_o(V[1],s,!1):M=jo(s),vs.set(f,M),Ns(M,ee)}function Ns(ee,t){if(typeof t=="string")return ee;const s=function(f,M){return(0,Fs._1)(f,t.base,!v.j9)?ee(f.substr(t.base.length+1),M):null};return s.allBasenames=ee.allBasenames,s.allPaths=ee.allPaths,s.basenames=ee.basenames,s.patterns=ee.patterns,s}function Ws(ee,t){return t.trimForExclusions&&ee.endsWith("/**")?ee.substr(0,ee.length-2):ee}function Js(ee,t){return function(s,f){return typeof s=="string"&&s.endsWith(ee)?t:null}}function qs(ee,t){const s=`/${ee}`,f=`\\${ee}`,M=function(q,se){return typeof q!="string"?null:se?se===ee?t:null:q===ee||q.endsWith(s)||q.endsWith(f)?t:null},V=[ee];return M.basenames=V,M.patterns=[t],M.allBasenames=V,M}function Vs(ee,t){const s=eo(ee.slice(1,-1).split(",").map(se=>Xs(se,t)).filter(se=>se!==Gn),ee),f=s.length;if(!f)return Gn;if(f===1)return s[0];const M=function(se,_e){for(let De=0,Oe=s.length;De<Oe;De++)if(s[De](se,_e))return ee;return null},V=s.find(se=>!!se.allBasenames);V&&(M.allBasenames=V.allBasenames);const q=s.reduce((se,_e)=>_e.allPaths?se.concat(_e.allPaths):se,[]);return q.length&&(M.allPaths=q),M}function _o(ee,t,s){const f=ns.Vn===ns.SA.sep,M=f?ee:ee.replace(hs,ns.Vn),V=ns.Vn+M,q=ns.SA.sep+ee;let se;return s?se=function(_e,De){return typeof _e=="string"&&(_e===M||_e.endsWith(V)||!f&&(_e===ee||_e.endsWith(q)))?t:null}:se=function(_e,De){return typeof _e=="string"&&(_e===M||!f&&_e===ee)?t:null},se.allPaths=[(s?"*/":"./")+ee],se}function jo(ee){try{const t=new RegExp(`^${Uo(ee)}$`);return function(s){return t.lastIndex=0,typeof s=="string"&&t.test(s)?ee:null}}catch{return Gn}}function Ko(ee,t,s){return!ee||typeof t!="string"?!1:vo(ee)(t,void 0,s)}function vo(ee,t={}){if(!ee)return Ms;if(typeof ee=="string"||$o(ee)){const s=Xs(ee,t);if(s===Gn)return Ms;const f=function(M,V){return!!s(M,V)};return s.allBasenames&&(f.allBasenames=s.allBasenames),s.allPaths&&(f.allPaths=s.allPaths),f}return Go(ee,t)}function $o(ee){const t=ee;return t?typeof t.base=="string"&&typeof t.pattern=="string":!1}function Go(ee,t){const s=eo(Object.getOwnPropertyNames(ee).map(se=>br(se,ee[se],t)).filter(se=>se!==Gn)),f=s.length;if(!f)return Gn;if(!s.some(se=>!!se.requiresSiblings)){if(f===1)return s[0];const se=function(Oe,qe){let Bt;for(let jt=0,Mi=s.length;jt<Mi;jt++){const ln=s[jt](Oe,qe);if(typeof ln=="string")return ln;(0,w.Qg)(ln)&&(Bt||(Bt=[]),Bt.push(ln))}return Bt?Zs(this,void 0,void 0,function*(){for(const jt of Bt){const Mi=yield jt;if(typeof Mi=="string")return Mi}return null}):null},_e=s.find(Oe=>!!Oe.allBasenames);_e&&(se.allBasenames=_e.allBasenames);const De=s.reduce((Oe,qe)=>qe.allPaths?Oe.concat(qe.allPaths):Oe,[]);return De.length&&(se.allPaths=De),se}const M=function(se,_e,De){let Oe,qe;for(let Bt=0,jt=s.length;Bt<jt;Bt++){const Mi=s[Bt];Mi.requiresSiblings&&De&&(_e||(_e=(0,ns.P8)(se)),Oe||(Oe=_e.substr(0,_e.length-(0,ns.LC)(se).length)));const ln=Mi(se,_e,Oe,De);if(typeof ln=="string")return ln;(0,w.Qg)(ln)&&(qe||(qe=[]),qe.push(ln))}return qe?Zs(this,void 0,void 0,function*(){for(const Bt of qe){const jt=yield Bt;if(typeof jt=="string")return jt}return null}):null},V=s.find(se=>!!se.allBasenames);V&&(M.allBasenames=V.allBasenames);const q=s.reduce((se,_e)=>_e.allPaths?se.concat(_e.allPaths):se,[]);return q.length&&(M.allPaths=q),M}function br(ee,t,s){if(t===!1)return Gn;const f=Xs(ee,s);if(f===Gn)return Gn;if(typeof t=="boolean")return f;if(t){const M=t.when;if(typeof M=="string"){const V=(q,se,_e,De)=>{if(!De||!f(q,se))return null;const Oe=M.replace("$(basename)",_e),qe=De(Oe);return(0,w.Qg)(qe)?qe.then(Bt=>Bt?ee:null):qe?ee:null};return V.requiresSiblings=!0,V}}return f}function eo(ee,t){const s=ee.filter(se=>!!se.basenames);if(s.length<2)return ee;const f=s.reduce((se,_e)=>{const De=_e.basenames;return De?se.concat(De):se},[]);let M;if(t){M=[];for(let se=0,_e=f.length;se<_e;se++)M.push(t)}else M=s.reduce((se,_e)=>{const De=_e.patterns;return De?se.concat(De):se},[]);const V=function(se,_e){if(typeof se!="string")return null;if(!_e){let Oe;for(Oe=se.length;Oe>0;Oe--){const qe=se.charCodeAt(Oe-1);if(qe===47||qe===92)break}_e=se.substr(Oe)}const De=f.indexOf(_e);return De!==-1?M[De]:null};V.basenames=f,V.patterns=M,V.allBasenames=f;const q=ee.filter(se=>!se.basenames);return q.push(V),q}var Es=y(53720),ss=y(54957);let Ps=[],Co=[],Hs=[];function to(ee,t=!1){Qo(ee,!1,t)}function Qo(ee,t,s){const f=Cs(ee,t);Ps.push(f),f.userConfigured?Hs.push(f):Co.push(f),s&&!f.userConfigured&&Ps.forEach(M=>{M.mime===f.mime||M.userConfigured||(f.extension&&M.extension===f.extension&&console.warn(`Overwriting extension <<${f.extension}>> to now point to mime <<${f.mime}>>`),f.filename&&M.filename===f.filename&&console.warn(`Overwriting filename <<${f.filename}>> to now point to mime <<${f.mime}>>`),f.filepattern&&M.filepattern===f.filepattern&&console.warn(`Overwriting filepattern <<${f.filepattern}>> to now point to mime <<${f.mime}>>`),f.firstline&&M.firstline===f.firstline&&console.warn(`Overwriting firstline <<${f.firstline}>> to now point to mime <<${f.mime}>>`))})}function Cs(ee,t){return{id:ee.id,mime:ee.mime,filename:ee.filename,extension:ee.extension,filepattern:ee.filepattern,firstline:ee.firstline,userConfigured:t,filenameLowercase:ee.filename?ee.filename.toLowerCase():void 0,extensionLowercase:ee.extension?ee.extension.toLowerCase():void 0,filepatternLowercase:ee.filepattern?vo(ee.filepattern.toLowerCase()):void 0,filepatternOnPath:ee.filepattern?ee.filepattern.indexOf(ns.SA.sep)>=0:!1}}function os(){Ps=Ps.filter(ee=>ee.userConfigured),Co=[]}function ri(ee,t){return io(ee,t).map(s=>s.id)}function io(ee,t){let s;if(ee)switch(ee.scheme){case ei.ny.file:s=ee.fsPath;break;case ei.ny.data:{s=on.B6.parseMetaData(ee).get(on.B6.META_DATA_LABEL);break}case ei.ny.vscodeNotebookCell:s=void 0;break;default:s=ee.path}if(!s)return[{id:"unknown",mime:Es.K.unknown}];s=s.toLowerCase();const f=(0,ns.P8)(s),M=bo(s,f,Hs);if(M)return[M,{id:ss.vH,mime:Es.K.text}];const V=bo(s,f,Co);if(V)return[V,{id:ss.vH,mime:Es.K.text}];if(t){const q=bs(t);if(q)return[q,{id:ss.vH,mime:Es.K.text}]}return[{id:"unknown",mime:Es.K.unknown}]}function bo(ee,t,s){var f;let M,V,q;for(let se=s.length-1;se>=0;se--){const _e=s[se];if(t===_e.filenameLowercase){M=_e;break}if(_e.filepattern&&(!V||_e.filepattern.length>V.filepattern.length)){const De=_e.filepatternOnPath?ee:t;!((f=_e.filepatternLowercase)===null||f===void 0)&&f.call(_e,De)&&(V=_e)}_e.extension&&(!q||_e.extension.length>q.extension.length)&&t.endsWith(_e.extensionLowercase)&&(q=_e)}if(M)return M;if(V)return V;if(q)return q}function bs(ee){if((0,$.LU)(ee)&&(ee=ee.substr(1)),ee.length>0)for(let t=Ps.length-1;t>=0;t--){const s=Ps[t];if(!s.firstline)continue;const f=ee.match(s.firstline);if(f&&f.length>0)return s}}var Fn=y(27142),Os=y(67167);const As=Object.prototype.hasOwnProperty,no="vs.editor.nullLanguage";class pi{constructor(){this._languageIdToLanguage=[],this._languageToLanguageId=new Map,this._register(no,0),this._register(ss.vH,1),this._nextLanguageId=2}_register(t,s){this._languageIdToLanguage[s]=t,this._languageToLanguageId.set(t,s)}register(t){if(this._languageToLanguageId.has(t))return;const s=this._nextLanguageId++;this._register(t,s)}encodeLanguageId(t){return this._languageToLanguageId.get(t)||0}decodeLanguageId(t){return this._languageIdToLanguage[t]||no}}class zi extends K.jG{constructor(t=!0,s=!1){super(),this._onDidChange=this._register(new m.vl),this.onDidChange=this._onDidChange.event,zi.instanceCount++,this._warnOnOverwrite=s,this.languageIdCodec=new pi,this._dynamicLanguages=[],this._languages={},this._mimeTypesMap={},this._nameMap={},this._lowercaseNameMap={},t&&(this._initializeFromRegistry(),this._register(ss.W6.onDidChangeLanguages(f=>{this._initializeFromRegistry()})))}dispose(){zi.instanceCount--,super.dispose()}_initializeFromRegistry(){this._languages={},this._mimeTypesMap={},this._nameMap={},this._lowercaseNameMap={},os();const t=[].concat(ss.W6.getLanguages()).concat(this._dynamicLanguages);this._registerLanguages(t)}_registerLanguages(t){for(const s of t)this._registerLanguage(s);this._mimeTypesMap={},this._nameMap={},this._lowercaseNameMap={},Object.keys(this._languages).forEach(s=>{const f=this._languages[s];f.name&&(this._nameMap[f.name]=f.identifier),f.aliases.forEach(M=>{this._lowercaseNameMap[M.toLowerCase()]=f.identifier}),f.mimetypes.forEach(M=>{this._mimeTypesMap[M]=f.identifier})}),Os.O.as(Fn.Fd.Configuration).registerOverrideIdentifiers(this.getRegisteredLanguageIds()),this._onDidChange.fire()}_registerLanguage(t){const s=t.id;let f;As.call(this._languages,s)?f=this._languages[s]:(this.languageIdCodec.register(s),f={identifier:s,name:null,mimetypes:[],aliases:[],extensions:[],filenames:[],configurationFiles:[],icons:[]},this._languages[s]=f),this._mergeLanguage(f,t)}_mergeLanguage(t,s){const f=s.id;let M=null;if(Array.isArray(s.mimetypes)&&s.mimetypes.length>0&&(t.mimetypes.push(...s.mimetypes),M=s.mimetypes[0]),M||(M=`text/x-${f}`,t.mimetypes.push(M)),Array.isArray(s.extensions)){s.configuration?t.extensions=s.extensions.concat(t.extensions):t.extensions=t.extensions.concat(s.extensions);for(const se of s.extensions)to({id:f,mime:M,extension:se},this._warnOnOverwrite)}if(Array.isArray(s.filenames))for(const se of s.filenames)to({id:f,mime:M,filename:se},this._warnOnOverwrite),t.filenames.push(se);if(Array.isArray(s.filenamePatterns))for(const se of s.filenamePatterns)to({id:f,mime:M,filepattern:se},this._warnOnOverwrite);if(typeof s.firstLine=="string"&&s.firstLine.length>0){let se=s.firstLine;se.charAt(0)!=="^"&&(se="^"+se);try{const _e=new RegExp(se);(0,$.eY)(_e)||to({id:f,mime:M,firstline:_e},this._warnOnOverwrite)}catch(_e){(0,C.dz)(_e)}}t.aliases.push(f);let V=null;if(typeof s.aliases<"u"&&Array.isArray(s.aliases)&&(s.aliases.length===0?V=[null]:V=s.aliases),V!==null)for(const se of V)!se||se.length===0||t.aliases.push(se);const q=V!==null&&V.length>0;if(!(q&&V[0]===null)){const se=(q?V[0]:null)||f;(q||!t.name)&&(t.name=se)}s.configuration&&t.configurationFiles.push(s.configuration),s.icon&&t.icons.push(s.icon)}isRegisteredLanguageId(t){return t?As.call(this._languages,t):!1}getRegisteredLanguageIds(){return Object.keys(this._languages)}getLanguageIdByLanguageName(t){const s=t.toLowerCase();return As.call(this._lowercaseNameMap,s)?this._lowercaseNameMap[s]:null}getLanguageIdByMimeType(t){return t&&As.call(this._mimeTypesMap,t)?this._mimeTypesMap[t]:null}guessLanguageIdByFilepathOrFirstLine(t,s){return!t&&!s?[]:ri(t,s)}}zi.instanceCount=0;class vn extends K.jG{constructor(t=!1){super(),this._onDidEncounterLanguage=this._register(new m.vl),this.onDidEncounterLanguage=this._onDidEncounterLanguage.event,this._onDidChange=this._register(new m.vl({leakWarningThreshold:200})),this.onDidChange=this._onDidChange.event,vn.instanceCount++,this._encounteredLanguages=new Set,this._registry=this._register(new zi(!0,t)),this.languageIdCodec=this._registry.languageIdCodec,this._register(this._registry.onDidChange(()=>this._onDidChange.fire()))}dispose(){vn.instanceCount--,super.dispose()}isRegisteredLanguageId(t){return this._registry.isRegisteredLanguageId(t)}getLanguageIdByLanguageName(t){return this._registry.getLanguageIdByLanguageName(t)}getLanguageIdByMimeType(t){return this._registry.getLanguageIdByMimeType(t)}guessLanguageIdByFilepathOrFirstLine(t,s){const f=this._registry.guessLanguageIdByFilepathOrFirstLine(t,s);return(0,pe.Fy)(f,null)}createById(t){return new xi(this.onDidChange,()=>this._createAndGetLanguageIdentifier(t))}createByFilepathOrFirstLine(t,s){return new xi(this.onDidChange,()=>{const f=this.guessLanguageIdByFilepathOrFirstLine(t,s);return this._createAndGetLanguageIdentifier(f)})}_createAndGetLanguageIdentifier(t){return(!t||!this.isRegisteredLanguageId(t))&&(t=ss.vH),this._encounteredLanguages.has(t)||(this._encounteredLanguages.add(t),d.dG.getOrCreate(t),this._onDidEncounterLanguage.fire(t)),t}}vn.instanceCount=0;class xi{constructor(t,s){this._onDidChangeLanguages=t,this._selector=s,this._listener=null,this._emitter=null,this.languageId=this._selector()}_dispose(){this._listener&&(this._listener.dispose(),this._listener=null),this._emitter&&(this._emitter.dispose(),this._emitter=null)}get onDidChange(){return this._listener||(this._listener=this._onDidChangeLanguages(()=>this._evaluate())),this._emitter||(this._emitter=new m.vl({onLastListenerRemove:()=>{this._dispose()}})),this._emitter.event}_evaluate(){var t;const s=this._selector();s!==this.languageId&&(this.languageId=s,(t=this._emitter)===null||t===void 0||t.fire(this.languageId))}}var jn=y(9715),Wn=y(55893),Qn=y(30474),Rs=y(77439),wr=y(45854),yr=y(96852),so=y(63781),ms=y(50350),ps=y(26048),fs=y(24594);const Zo=/\(&([^\s&])\)|(^|[^&])&([^\s&])/,Yo=/(&)?(&)([^\s&])/g;var wo;(function(ee){ee[ee.Right=0]="Right",ee[ee.Left=1]="Left"})(wo||(wo={}));class ks extends Rs.E{constructor(t,s,f={}){t.classList.add("monaco-menu-container"),t.setAttribute("role","presentation");const M=document.createElement("div");M.classList.add("monaco-menu"),M.setAttribute("role","presentation"),super(M,{orientation:1,actionViewItemProvider:se=>this.doGetActionViewItem(se,f,V),context:f.context,actionRunner:f.actionRunner,ariaLabel:f.ariaLabel,ariaRole:"menu",focusOnlyEnabledItems:!0,triggerKeys:{keys:[3,...v.zx||v.j9?[10]:[]],keyDown:!0}}),this.menuElement=M,this.actionsList.tabIndex=0,this.menuDisposables=this._register(new K.Cm),this.initializeOrUpdateStyleSheet(t,{}),this._register(Qn.q.addTarget(M)),(0,Ue.ko)(M,Ue.Bx.KEY_DOWN,se=>{new sn.Z(se).equals(2)&&se.preventDefault()}),f.enableMnemonics&&this.menuDisposables.add((0,Ue.ko)(M,Ue.Bx.KEY_DOWN,se=>{const _e=se.key.toLocaleLowerCase();if(this.mnemonics.has(_e)){Ue.fs.stop(se,!0);const De=this.mnemonics.get(_e);if(De.length===1&&(De[0]instanceof oo&&De[0].container&&this.focusItemByElement(De[0].container),De[0].onClick(se)),De.length>1){const Oe=De.shift();Oe&&Oe.container&&(this.focusItemByElement(Oe.container),De.push(Oe)),this.mnemonics.set(_e,De)}}})),v.j9&&this._register((0,Ue.ko)(M,Ue.Bx.KEY_DOWN,se=>{const _e=new sn.Z(se);_e.equals(14)||_e.equals(11)?(this.focusedItem=this.viewItems.length-1,this.focusNext(),Ue.fs.stop(se,!0)):(_e.equals(13)||_e.equals(12))&&(this.focusedItem=0,this.focusPrevious(),Ue.fs.stop(se,!0))})),this._register((0,Ue.ko)(this.domNode,Ue.Bx.MOUSE_OUT,se=>{const _e=se.relatedTarget;(0,Ue.QX)(_e,this.domNode)||(this.focusedItem=void 0,this.updateFocus(),se.stopPropagation())})),this._register((0,Ue.ko)(this.actionsList,Ue.Bx.MOUSE_OVER,se=>{let _e=se.target;if(!(!_e||!(0,Ue.QX)(_e,this.actionsList)||_e===this.actionsList)){for(;_e.parentElement!==this.actionsList&&_e.parentElement!==null;)_e=_e.parentElement;if(_e.classList.contains("action-item")){const De=this.focusedItem;this.setFocusedItem(_e),De!==this.focusedItem&&this.updateFocus()}}})),this._register(Qn.q.addTarget(this.actionsList)),this._register((0,Ue.ko)(this.actionsList,Qn.B.Tap,se=>{let _e=se.initialTarget;if(!(!_e||!(0,Ue.QX)(_e,this.actionsList)||_e===this.actionsList)){for(;_e.parentElement!==this.actionsList&&_e.parentElement!==null;)_e=_e.parentElement;if(_e.classList.contains("action-item")){const De=this.focusedItem;this.setFocusedItem(_e),De!==this.focusedItem&&this.updateFocus()}}}));const V={parent:this};this.mnemonics=new Map,this.scrollableElement=this._register(new so.MU(M,{alwaysConsumeMouseWheel:!0,horizontal:2,vertical:3,verticalScrollbarSize:7,handleMouseWheel:!0,useShadows:!0}));const q=this.scrollableElement.getDomNode();q.style.position="",this._register((0,Ue.ko)(M,Qn.B.Change,se=>{Ue.fs.stop(se,!0);const _e=this.scrollableElement.getScrollPosition().scrollTop;this.scrollableElement.setScrollPosition({scrollTop:_e-se.translationY})})),this._register((0,Ue.ko)(q,Ue.Bx.MOUSE_UP,se=>{se.preventDefault()})),M.style.maxHeight=`${Math.max(10,window.innerHeight-t.getBoundingClientRect().top-35)}px`,s=s.filter(se=>{var _e;return!((_e=f.submenuIds)===null||_e===void 0)&&_e.has(se.id)?(console.warn(`Found submenu cycle: ${se.id}`),!1):!0}),this.push(s,{icon:!0,label:!0,isMenu:!0}),t.appendChild(this.scrollableElement.getDomNode()),this.scrollableElement.scanDomNode(),this.viewItems.filter(se=>!(se instanceof zs)).forEach((se,_e,De)=>{se.updatePositionInSet(_e+1,De.length)})}initializeOrUpdateStyleSheet(t,s){this.styleSheet||((0,Ue.Cl)(t)?this.styleSheet=(0,Ue.li)(t):(ks.globalStyleSheet||(ks.globalStyleSheet=(0,Ue.li)()),this.styleSheet=ks.globalStyleSheet)),this.styleSheet.textContent=Sr(s,(0,Ue.Cl)(t))}style(t){const s=this.getContainer();this.initializeOrUpdateStyleSheet(s,t);const f=t.foregroundColor?`${t.foregroundColor}`:"",M=t.backgroundColor?`${t.backgroundColor}`:"",V=t.borderColor?`1px solid ${t.borderColor}`:"",q="5px",se=t.shadowColor?`0 2px 8px ${t.shadowColor}`:"";s.style.outline=V,s.style.borderRadius=q,s.style.color=f,s.style.backgroundColor=M,s.style.boxShadow=se,this.viewItems&&this.viewItems.forEach(_e=>{(_e instanceof Xo||_e instanceof zs)&&_e.style(t)})}getContainer(){return this.scrollableElement.getDomNode()}get onScroll(){return this.scrollableElement.onScroll}focusItemByElement(t){const s=this.focusedItem;this.setFocusedItem(t),s!==this.focusedItem&&this.updateFocus()}setFocusedItem(t){for(let s=0;s<this.actionsList.children.length;s++){const f=this.actionsList.children[s];if(t===f){this.focusedItem=s;break}}}updateFocus(t){super.updateFocus(t,!0,!0),typeof this.focusedItem<"u"&&this.scrollableElement.setScrollPosition({scrollTop:Math.round(this.menuElement.scrollTop)})}doGetActionViewItem(t,s,f){if(t instanceof ms.wv)return new zs(s.context,t,{icon:!0});if(t instanceof ms.YH){const M=new oo(t,t.actions,f,Object.assign(Object.assign({},s),{submenuIds:new Set([...s.submenuIds||[],t.id])}));if(s.enableMnemonics){const V=M.getMnemonic();if(V&&M.isEnabled()){let q=[];this.mnemonics.has(V)&&(q=this.mnemonics.get(V)),q.push(M),this.mnemonics.set(V,q)}}return M}else{const M={enableMnemonics:s.enableMnemonics,useEventAsContext:s.useEventAsContext};if(s.getKeyBinding){const q=s.getKeyBinding(t);if(q){const se=q.getLabel();se&&(M.keybinding=se)}}const V=new Xo(s.context,t,M);if(s.enableMnemonics){const q=V.getMnemonic();if(q&&V.isEnabled()){let se=[];this.mnemonics.has(q)&&(se=this.mnemonics.get(q)),se.push(V),this.mnemonics.set(q,se)}}return V}}}class Xo extends wr.E{constructor(t,s,f={}){if(f.isMenu=!0,super(s,s,f),this.options=f,this.options.icon=f.icon!==void 0?f.icon:!1,this.options.label=f.label!==void 0?f.label:!0,this.cssClass="",this.options.label&&f.enableMnemonics){const M=this.getAction().label;if(M){const V=Zo.exec(M);V&&(this.mnemonic=(V[1]?V[1]:V[3]).toLocaleLowerCase())}}this.runOnceToEnableMouseUp=new w.uC(()=>{this.element&&(this._register((0,Ue.ko)(this.element,Ue.Bx.MOUSE_UP,M=>{if(Ue.fs.stop(M,!0),Wn.isFirefox){if(new jn.P(M).rightButton)return;this.onClick(M)}else setTimeout(()=>{this.onClick(M)},0)})),this._register((0,Ue.ko)(this.element,Ue.Bx.CONTEXT_MENU,M=>{Ue.fs.stop(M,!0)})))},100),this._register(this.runOnceToEnableMouseUp)}render(t){super.render(t),this.element&&(this.container=t,this.item=(0,Ue.BC)(this.element,(0,Ue.$)("a.action-menu-item")),this._action.id===ms.wv.ID?this.item.setAttribute("role","presentation"):(this.item.setAttribute("role","menuitem"),this.mnemonic&&this.item.setAttribute("aria-keyshortcuts",`${this.mnemonic}`)),this.check=(0,Ue.BC)(this.item,(0,Ue.$)("span.menu-item-check"+ps.W6.menuSelection.cssSelector)),this.check.setAttribute("role","none"),this.label=(0,Ue.BC)(this.item,(0,Ue.$)("span.action-label")),this.options.label&&this.options.keybinding&&((0,Ue.BC)(this.item,(0,Ue.$)("span.keybinding")).textContent=this.options.keybinding),this.runOnceToEnableMouseUp.schedule(),this.updateClass(),this.updateLabel(),this.updateTooltip(),this.updateEnabled(),this.updateChecked())}blur(){super.blur(),this.applyStyle()}focus(){super.focus(),this.item&&this.item.focus(),this.applyStyle()}updatePositionInSet(t,s){this.item&&(this.item.setAttribute("aria-posinset",`${t}`),this.item.setAttribute("aria-setsize",`${s}`))}updateLabel(){var t;if(this.label&&this.options.label){(0,Ue.w_)(this.label);let s=(0,fs.pS)(this.getAction().label);if(s){const f=Jo(s);this.options.enableMnemonics||(s=f),this.label.setAttribute("aria-label",f.replace(/&&/g,"&"));const M=Zo.exec(s);if(M){s=$.ih(s),Yo.lastIndex=0;let V=Yo.exec(s);for(;V&&V[1];)V=Yo.exec(s);const q=se=>se.replace(/&&/g,"&");V?this.label.append($.NB(q(s.substr(0,V.index))," "),(0,Ue.$)("u",{"aria-hidden":"true"},V[3]),$.BO(q(s.substr(V.index+V[0].length))," ")):this.label.innerText=q(s).trim(),(t=this.item)===null||t===void 0||t.setAttribute("aria-keyshortcuts",(M[1]?M[1]:M[3]).toLocaleLowerCase())}else this.label.innerText=s.replace(/&&/g,"&").trim()}}}updateTooltip(){}updateClass(){this.cssClass&&this.item&&this.item.classList.remove(...this.cssClass.split(" ")),this.options.icon&&this.label?(this.cssClass=this.getAction().class||"",this.label.classList.add("icon"),this.cssClass&&this.label.classList.add(...this.cssClass.split(" ")),this.updateEnabled()):this.label&&this.label.classList.remove("icon")}updateEnabled(){this.getAction().enabled?(this.element&&(this.element.classList.remove("disabled"),this.element.removeAttribute("aria-disabled")),this.item&&(this.item.classList.remove("disabled"),this.item.removeAttribute("aria-disabled"),this.item.tabIndex=0)):(this.element&&(this.element.classList.add("disabled"),this.element.setAttribute("aria-disabled","true")),this.item&&(this.item.classList.add("disabled"),this.item.setAttribute("aria-disabled","true")))}updateChecked(){if(!this.item)return;const t=this.getAction().checked;this.item.classList.toggle("checked",!!t),t!==void 0?(this.item.setAttribute("role","menuitemcheckbox"),this.item.setAttribute("aria-checked",t?"true":"false")):(this.item.setAttribute("role","menuitem"),this.item.setAttribute("aria-checked",""))}getMnemonic(){return this.mnemonic}applyStyle(){if(!this.menuStyle)return;const t=this.element&&this.element.classList.contains("focused"),s=t&&this.menuStyle.selectionForegroundColor?this.menuStyle.selectionForegroundColor:this.menuStyle.foregroundColor,f=t&&this.menuStyle.selectionBackgroundColor?this.menuStyle.selectionBackgroundColor:void 0,M=t&&this.menuStyle.selectionBorderColor?`1px solid ${this.menuStyle.selectionBorderColor}`:"",V=t&&this.menuStyle.selectionBorderColor?"-1px":"";this.item&&(this.item.style.color=s?s.toString():"",this.item.style.backgroundColor=f?f.toString():"",this.item.style.outline=M,this.item.style.outlineOffset=V),this.check&&(this.check.style.color=s?s.toString():"")}style(t){this.menuStyle=t,this.applyStyle()}}class oo extends Xo{constructor(t,s,f,M){super(t,t,M),this.submenuActions=s,this.parentData=f,this.submenuOptions=M,this.mysubmenu=null,this.submenuDisposables=this._register(new K.Cm),this.mouseOver=!1,this.expandDirection=M&&M.expandDirection!==void 0?M.expandDirection:wo.Right,this.showScheduler=new w.uC(()=>{this.mouseOver&&(this.cleanupExistingSubmenu(!1),this.createSubmenu(!1))},250),this.hideScheduler=new w.uC(()=>{this.element&&!(0,Ue.QX)((0,Ue.bq)(),this.element)&&this.parentData.submenu===this.mysubmenu&&(this.parentData.parent.focus(!1),this.cleanupExistingSubmenu(!0))},750)}render(t){super.render(t),this.element&&(this.item&&(this.item.classList.add("monaco-submenu-item"),this.item.tabIndex=0,this.item.setAttribute("aria-haspopup","true"),this.updateAriaExpanded("false"),this.submenuIndicator=(0,Ue.BC)(this.item,(0,Ue.$)("span.submenu-indicator"+ps.W6.menuSubmenu.cssSelector)),this.submenuIndicator.setAttribute("aria-hidden","true")),this._register((0,Ue.ko)(this.element,Ue.Bx.KEY_UP,s=>{const f=new sn.Z(s);(f.equals(17)||f.equals(3))&&(Ue.fs.stop(s,!0),this.createSubmenu(!0))})),this._register((0,Ue.ko)(this.element,Ue.Bx.KEY_DOWN,s=>{const f=new sn.Z(s);(0,Ue.bq)()===this.item&&(f.equals(17)||f.equals(3))&&Ue.fs.stop(s,!0)})),this._register((0,Ue.ko)(this.element,Ue.Bx.MOUSE_OVER,s=>{this.mouseOver||(this.mouseOver=!0,this.showScheduler.schedule())})),this._register((0,Ue.ko)(this.element,Ue.Bx.MOUSE_LEAVE,s=>{this.mouseOver=!1})),this._register((0,Ue.ko)(this.element,Ue.Bx.FOCUS_OUT,s=>{this.element&&!(0,Ue.QX)((0,Ue.bq)(),this.element)&&this.hideScheduler.schedule()})),this._register(this.parentData.parent.onScroll(()=>{this.parentData.submenu===this.mysubmenu&&(this.parentData.parent.focus(!1),this.cleanupExistingSubmenu(!0))})))}updateEnabled(){}onClick(t){Ue.fs.stop(t,!0),this.cleanupExistingSubmenu(!1),this.createSubmenu(!0)}cleanupExistingSubmenu(t){if(this.parentData.submenu&&(t||this.parentData.submenu!==this.mysubmenu)){try{this.parentData.submenu.dispose()}catch{}this.parentData.submenu=void 0,this.updateAriaExpanded("false"),this.submenuContainer&&(this.submenuDisposables.clear(),this.submenuContainer=void 0)}}calculateSubmenuMenuLayout(t,s,f,M){const V={top:0,left:0};return V.left=Xn(t.width,s.width,{position:M===wo.Right?0:1,offset:f.left,size:f.width}),V.left>=f.left&&V.left<f.left+f.width&&(f.left+10+s.width<=t.width&&(V.left=f.left+10),f.top+=10,f.height=0),V.top=Xn(t.height,s.height,{position:0,offset:f.top,size:0}),V.top+s.height===f.top&&V.top+f.height+s.height<=t.height&&(V.top+=f.height),V}createSubmenu(t=!0){if(this.element)if(this.parentData.submenu)this.parentData.submenu.focus(!1);else{this.updateAriaExpanded("true"),this.submenuContainer=(0,Ue.BC)(this.element,(0,Ue.$)("div.monaco-submenu")),this.submenuContainer.classList.add("menubar-menu-items-holder","context-view");const s=getComputedStyle(this.parentData.parent.domNode),f=parseFloat(s.paddingTop||"0")||0;this.submenuContainer.style.zIndex="1",this.submenuContainer.style.position="fixed",this.submenuContainer.style.top="0",this.submenuContainer.style.left="0",this.parentData.submenu=new ks(this.submenuContainer,this.submenuActions.length?this.submenuActions:[new ms.HJ],this.submenuOptions),this.menuStyle&&this.parentData.submenu.style(this.menuStyle);const M=this.element.getBoundingClientRect(),V={top:M.top-f,left:M.left,height:M.height+2*f,width:M.width},q=this.submenuContainer.getBoundingClientRect(),{top:se,left:_e}=this.calculateSubmenuMenuLayout(new Ue.fg(window.innerWidth,window.innerHeight),Ue.fg.lift(q),V,this.expandDirection);this.submenuContainer.style.left=`${_e-q.left}px`,this.submenuContainer.style.top=`${se-q.top}px`,this.submenuDisposables.add((0,Ue.ko)(this.submenuContainer,Ue.Bx.KEY_UP,De=>{new sn.Z(De).equals(15)&&(Ue.fs.stop(De,!0),this.parentData.parent.focus(),this.cleanupExistingSubmenu(!0))})),this.submenuDisposables.add((0,Ue.ko)(this.submenuContainer,Ue.Bx.KEY_DOWN,De=>{new sn.Z(De).equals(15)&&Ue.fs.stop(De,!0)})),this.submenuDisposables.add(this.parentData.submenu.onDidCancel(()=>{this.parentData.parent.focus(),this.cleanupExistingSubmenu(!0)})),this.parentData.submenu.focus(t),this.mysubmenu=this.parentData.submenu}}updateAriaExpanded(t){var s;this.item&&((s=this.item)===null||s===void 0||s.setAttribute("aria-expanded",t))}applyStyle(){var t;if(super.applyStyle(),!this.menuStyle)return;const f=this.element&&this.element.classList.contains("focused")&&this.menuStyle.selectionForegroundColor?this.menuStyle.selectionForegroundColor:this.menuStyle.foregroundColor;this.submenuIndicator&&(this.submenuIndicator.style.color=f?`${f}`:""),(t=this.parentData.submenu)===null||t===void 0||t.style(this.menuStyle)}dispose(){super.dispose(),this.hideScheduler.dispose(),this.mysubmenu&&(this.mysubmenu.dispose(),this.mysubmenu=null),this.submenuContainer&&(this.submenuContainer=void 0)}}class zs extends wr.Z{style(t){this.label&&(this.label.style.borderBottomColor=t.separatorColor?`${t.separatorColor}`:"")}}function Jo(ee){const t=Zo,s=t.exec(ee);if(!s)return ee;const f=!s[1];return ee.replace(t,f?"$2$3":"").trim()}function Sr(ee,t){let s=` .monaco-menu { font-size: 13px; border-radius: 5px; min-width: 160px; } ${(0,yr.U)(ps.W6.menuSelection)} ${(0,yr.U)(ps.W6.menuSubmenu)} .monaco-menu .monaco-action-bar { text-align: right; overflow: hidden; white-space: nowrap; } .monaco-menu .monaco-action-bar .actions-container { display: flex; margin: 0 auto; padding: 0; width: 100%; justify-content: flex-end; } .monaco-menu .monaco-action-bar.vertical .actions-container { display: inline-block; } .monaco-menu .monaco-action-bar.reverse .actions-container { flex-direction: row-reverse; } .monaco-menu .monaco-action-bar .action-item { cursor: pointer; display: inline-block; transition: transform 50ms ease; position: relative; /* DO NOT REMOVE - this is the key to preventing the ghosting icon bug in Chrome 42 */ } .monaco-menu .monaco-action-bar .action-item.disabled { cursor: default; } .monaco-menu .monaco-action-bar.animated .action-item.active { transform: scale(1.272019649, 1.272019649); /* 1.272019649 = \u221A\u03C6 */ } .monaco-menu .monaco-action-bar .action-item .icon, .monaco-menu .monaco-action-bar .action-item .codicon { display: inline-block; } .monaco-menu .monaco-action-bar .action-item .codicon { display: flex; align-items: center; } .monaco-menu .monaco-action-bar .action-label { font-size: 11px; margin-right: 4px; } .monaco-menu .monaco-action-bar .action-item.disabled .action-label, .monaco-menu .monaco-action-bar .action-item.disabled .action-label:hover { color: var(--vscode-disabledForeground); } /* Vertical actions */ .monaco-menu .monaco-action-bar.vertical { text-align: left; } .monaco-menu .monaco-action-bar.vertical .action-item { display: block; } .monaco-menu .monaco-action-bar.vertical .action-label.separator { display: block; border-bottom: 1px solid var(--vscode-menu-separatorBackground); padding-top: 1px; padding: 30px; } .monaco-menu .secondary-actions .monaco-action-bar .action-label { margin-left: 6px; } /* Action Items */ .monaco-menu .monaco-action-bar .action-item.select-container { overflow: hidden; /* somehow the dropdown overflows its container, we prevent it here to not push */ flex: 1; max-width: 170px; min-width: 60px; display: flex; align-items: center; justify-content: center; margin-right: 10px; } .monaco-menu .monaco-action-bar.vertical { margin-left: 0; overflow: visible; } .monaco-menu .monaco-action-bar.vertical .actions-container { display: block; } .monaco-menu .monaco-action-bar.vertical .action-item { padding: 0; transform: none; display: flex; } .monaco-menu .monaco-action-bar.vertical .action-item.active { transform: none; } .monaco-menu .monaco-action-bar.vertical .action-menu-item { flex: 1 1 auto; display: flex; height: 2em; align-items: center; position: relative; } .monaco-menu .monaco-action-bar.vertical .action-menu-item:hover .keybinding, .monaco-menu .monaco-action-bar.vertical .action-menu-item:focus .keybinding { opacity: unset; } .monaco-menu .monaco-action-bar.vertical .action-label { flex: 1 1 auto; text-decoration: none; padding: 0 1em; background: none; font-size: 12px; line-height: 1; } .monaco-menu .monaco-action-bar.vertical .keybinding, .monaco-menu .monaco-action-bar.vertical .submenu-indicator { display: inline-block; flex: 2 1 auto; padding: 0 1em; text-align: right; font-size: 12px; line-height: 1; } .monaco-menu .monaco-action-bar.vertical .submenu-indicator { height: 100%; } .monaco-menu .monaco-action-bar.vertical .submenu-indicator.codicon { font-size: 16px !important; display: flex; align-items: center; } .monaco-menu .monaco-action-bar.vertical .submenu-indicator.codicon::before { margin-left: auto; margin-right: -20px; } .monaco-menu .monaco-action-bar.vertical .action-item.disabled .keybinding, .monaco-menu .monaco-action-bar.vertical .action-item.disabled .submenu-indicator { opacity: 0.4; } .monaco-menu .monaco-action-bar.vertical .action-label:not(.separator) { display: inline-block; box-sizing: border-box; margin: 0; } .monaco-menu .monaco-action-bar.vertical .action-item { position: static; overflow: visible; } .monaco-menu .monaco-action-bar.vertical .action-item .monaco-submenu { position: absolute; } .monaco-menu .monaco-action-bar.vertical .action-label.separator { width: 100%; height: 0px !important; opacity: 1; } .monaco-menu .monaco-action-bar.vertical .action-label.separator.text { padding: 0.7em 1em 0.1em 1em; font-weight: bold; opacity: 1; } .monaco-menu .monaco-action-bar.vertical .action-label:hover { color: inherit; } .monaco-menu .monaco-action-bar.vertical .menu-item-check { position: absolute; visibility: hidden; width: 1em; height: 100%; } .monaco-menu .monaco-action-bar.vertical .action-menu-item.checked .menu-item-check { visibility: visible; display: flex; align-items: center; justify-content: center; } /* Context Menu */ .context-view.monaco-menu-container { outline: 0; border: none; animation: fadeIn 0.083s linear; -webkit-app-region: no-drag; } .context-view.monaco-menu-container :focus, .context-view.monaco-menu-container .monaco-action-bar.vertical:focus, .context-view.monaco-menu-container .monaco-action-bar.vertical :focus { outline: 0; } .hc-black .context-view.monaco-menu-container, .hc-light .context-view.monaco-menu-container, :host-context(.hc-black) .context-view.monaco-menu-container, :host-context(.hc-light) .context-view.monaco-menu-container { box-shadow: none; } .hc-black .monaco-menu .monaco-action-bar.vertical .action-item.focused, .hc-light .monaco-menu .monaco-action-bar.vertical .action-item.focused, :host-context(.hc-black) .monaco-menu .monaco-action-bar.vertical .action-item.focused, :host-context(.hc-light) .monaco-menu .monaco-action-bar.vertical .action-item.focused { background: none; } /* Vertical Action Bar Styles */ .monaco-menu .monaco-action-bar.vertical { padding: .6em 0; } .monaco-menu .monaco-action-bar.vertical .action-menu-item { height: 2em; } .monaco-menu .monaco-action-bar.vertical .action-label:not(.separator), .monaco-menu .monaco-action-bar.vertical .keybinding { font-size: inherit; padding: 0 2em; } .monaco-menu .monaco-action-bar.vertical .menu-item-check { font-size: inherit; width: 2em; } .monaco-menu .monaco-action-bar.vertical .action-label.separator { font-size: inherit; margin: 5px 0 !important; padding: 0; border-radius: 0; } .linux .monaco-menu .monaco-action-bar.vertical .action-label.separator, :host-context(.linux) .monaco-menu .monaco-action-bar.vertical .action-label.separator { margin-left: 0; margin-right: 0; } .monaco-menu .monaco-action-bar.vertical .submenu-indicator { font-size: 60%; padding: 0 1.8em; } .linux .monaco-menu .monaco-action-bar.vertical .submenu-indicator { :host-context(.linux) .monaco-menu .monaco-action-bar.vertical .submenu-indicator { height: 100%; mask-size: 10px 10px; -webkit-mask-size: 10px 10px; } .monaco-menu .action-item { cursor: default; }`;if(t){s+=` /* Arrows */ .monaco-scrollable-element > .scrollbar > .scra { cursor: pointer; font-size: 11px !important; } .monaco-scrollable-element > .visible { opacity: 1; /* Background rule added for IE9 - to allow clicks on dom node */ background:rgba(0,0,0,0); transition: opacity 100ms linear; } .monaco-scrollable-element > .invisible { opacity: 0; pointer-events: none; } .monaco-scrollable-element > .invisible.fade { transition: opacity 800ms linear; } /* Scrollable Content Inset Shadow */ .monaco-scrollable-element > .shadow { position: absolute; display: none; } .monaco-scrollable-element > .shadow.top { display: block; top: 0; left: 3px; height: 3px; width: 100%; } .monaco-scrollable-element > .shadow.left { display: block; top: 3px; left: 0; height: 100%; width: 3px; } .monaco-scrollable-element > .shadow.top-left-corner { display: block; top: 0; left: 0; height: 3px; width: 3px; } `;const f=ee.scrollbarShadow;f&&(s+=` .monaco-scrollable-element > .shadow.top { box-shadow: ${f} 0 6px 6px -6px inset; } .monaco-scrollable-element > .shadow.left { box-shadow: ${f} 6px 0 6px -6px inset; } .monaco-scrollable-element > .shadow.top.left { box-shadow: ${f} 6px 6px 6px -6px inset; } `);const M=ee.scrollbarSliderBackground;M&&(s+=` .monaco-scrollable-element > .scrollbar > .slider { background: ${M}; } `);const V=ee.scrollbarSliderHoverBackground;V&&(s+=` .monaco-scrollable-element > .scrollbar > .slider:hover { background: ${V}; } `);const q=ee.scrollbarSliderActiveBackground;q&&(s+=` .monaco-scrollable-element > .scrollbar > .slider.active { background: ${q}; } `)}return s}var Ds=y(1597);class Rr{constructor(t,s,f,M,V){this.contextViewService=t,this.telemetryService=s,this.notificationService=f,this.keybindingService=M,this.themeService=V,this.focusToReturn=null,this.block=null,this.options={blockMouse:!0}}configure(t){this.options=t}showContextMenu(t){const s=t.getActions();if(!s.length)return;this.focusToReturn=document.activeElement;let f;const M=(0,Ue.sb)(t.domForShadowRoot)?t.domForShadowRoot:void 0;this.contextViewService.showContextView({getAnchor:()=>t.getAnchor(),canRelayout:!1,anchorAlignment:t.anchorAlignment,anchorAxisAlignment:t.anchorAxisAlignment,render:V=>{const q=t.getMenuClassName?t.getMenuClassName():"";q&&(V.className+=" "+q),this.options.blockMouse&&(this.block=V.appendChild((0,Ue.$)(".context-view-block")),this.block.style.position="fixed",this.block.style.cursor="initial",this.block.style.left="0",this.block.style.top="0",this.block.style.width="100%",this.block.style.height="100%",this.block.style.zIndex="-1",(0,Ue.ko)(this.block,Ue.Bx.MOUSE_DOWN,De=>De.stopPropagation()));const se=new K.Cm,_e=t.actionRunner||new ms.LN;return _e.onBeforeRun(this.onActionRun,this,se),_e.onDidRun(this.onDidActionRun,this,se),f=new ks(V,s,{actionViewItemProvider:t.getActionViewItem,context:t.getActionsContext?t.getActionsContext():null,actionRunner:_e,getKeyBinding:t.getKeyBinding?t.getKeyBinding:De=>this.keybindingService.lookupKeybinding(De.id)}),se.add((0,Ds.kg)(f,this.themeService)),f.onDidCancel(()=>this.contextViewService.hideContextView(!0),null,se),f.onDidBlur(()=>this.contextViewService.hideContextView(!0),null,se),se.add((0,Ue.ko)(window,Ue.Bx.BLUR,()=>this.contextViewService.hideContextView(!0))),se.add((0,Ue.ko)(window,Ue.Bx.MOUSE_DOWN,De=>{if(De.defaultPrevented)return;const Oe=new jn.P(De);let qe=Oe.target;if(!Oe.rightButton){for(;qe;){if(qe===V)return;qe=qe.parentElement}this.contextViewService.hideContextView(!0)}})),(0,K.qE)(se,f)},focus:()=>{f?.focus(!!t.autoSelectFirstItem)},onHide:V=>{var q;(q=t.onHide)===null||q===void 0||q.call(t,!!V),this.block&&(this.block.remove(),this.block=null),this.focusToReturn&&this.focusToReturn.focus()}},M,!!M)}onActionRun(t){this.telemetryService.publicLog2("workbenchActionExecuted",{id:t.action.id,from:"contextMenu"}),this.contextViewService.hideContextView(!1),this.focusToReturn&&this.focusToReturn.focus()}onDidActionRun(t){t.error&&!(0,C.MB)(t.error)&&this.notificationService.error(t.error)}}var Br=function(ee,t,s,f){var M=arguments.length,V=M<3?t:f===null?f=Object.getOwnPropertyDescriptor(t,s):f,q;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")V=Reflect.decorate(ee,t,s,f);else for(var se=ee.length-1;se>=0;se--)(q=ee[se])&&(V=(M<3?q(V):M>3?q(t,s,V):q(t,s))||V);return M>3&&V&&Object.defineProperty(t,s,V),V},ro=function(ee,t){return function(s,f){t(s,f,ee)}};let yo=class extends K.jG{constructor(t,s,f,M,V){super(),this._onDidShowContextMenu=new m.vl,this._onDidHideContextMenu=new m.vl,this.contextMenuHandler=new Rr(f,t,s,M,V)}configure(t){this.contextMenuHandler.configure(t)}showContextMenu(t){this.contextMenuHandler.showContextMenu(Object.assign(Object.assign({},t),{onHide:s=>{var f;(f=t.onHide)===null||f===void 0||f.call(t,s),this._onDidHideContextMenu.fire()}})),Ue.Di.getInstance().resetKeyStatus(),this._onDidShowContextMenu.fire()}};yo=Br([ro(0,Ft.k),ro(1,cn.Ot),ro(2,hn.l),ro(3,F.b),ro(4,oi.Gy)],yo);var Bs=y(78903),Lr=y(50180),So;(function(ee){ee[ee.API=0]="API",ee[ee.USER=1]="USER"})(So||(So={}));var ao=y(54435),qo=function(ee,t,s,f){var M=arguments.length,V=M<3?t:f===null?f=Object.getOwnPropertyDescriptor(t,s):f,q;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")V=Reflect.decorate(ee,t,s,f);else for(var se=ee.length-1;se>=0;se--)(q=ee[se])&&(V=(M<3?q(V):M>3?q(t,s,V):q(t,s))||V);return M>3&&V&&Object.defineProperty(t,s,V),V},Lo=function(ee,t){return function(s,f){t(s,f,ee)}},ws=function(ee,t,s,f){function M(V){return V instanceof s?V:new s(function(q){q(V)})}return new(s||(s=Promise))(function(V,q){function se(Oe){try{De(f.next(Oe))}catch(qe){q(qe)}}function _e(Oe){try{De(f.throw(Oe))}catch(qe){q(qe)}}function De(Oe){Oe.done?V(Oe.value):M(Oe.value).then(se,_e)}De((f=f.apply(ee,t||[])).next())})};let er=class{constructor(t){this._commandService=t}open(t,s){return ws(this,void 0,void 0,function*(){if(!(0,ao.v$)(t,ei.ny.command))return!1;if(!s?.allowCommands)return!0;typeof t=="string"&&(t=Gi.r.parse(t));let f=[];try{f=(0,Lr.q)(decodeURIComponent(t.query))}catch{try{f=(0,Lr.q)(t.query)}catch{}}return Array.isArray(f)||(f=[f]),yield this._commandService.executeCommand(t.path,...f),!0})}};er=qo([Lo(0,Qt.wT)],er);let tr=class{constructor(t){this._editorService=t}open(t,s){return ws(this,void 0,void 0,function*(){typeof t=="string"&&(t=Gi.r.parse(t));const{selection:f,uri:M}=(0,ao.ew)(t);return t=M,t.scheme===ei.ny.file&&(t=(0,on.Fd)(t)),yield this._editorService.openCodeEditor({resource:t,options:Object.assign({selection:f,source:s?.fromUserGesture?So.USER:So.API},s?.editorOptions)},this._editorService.getFocusedCodeEditor(),s?.openToSide),!0})}};tr=qo([Lo(0,U.T)],tr);let Eo=class{constructor(t,s){this._openers=new ui.w,this._validators=new ui.w,this._resolvers=new ui.w,this._resolvedUriTargets=new Di.fT(f=>f.with({path:null,fragment:null,query:null}).toString()),this._externalOpeners=new ui.w,this._defaultExternalOpener={openExternal:f=>ws(this,void 0,void 0,function*(){return(0,ao.fV)(f,ei.ny.http,ei.ny.https)?Ue.jh(f):window.location.href=f,!0})},this._openers.push({open:(f,M)=>ws(this,void 0,void 0,function*(){return M?.openExternal||(0,ao.fV)(f,ei.ny.mailto,ei.ny.http,ei.ny.https,ei.ny.vsls)?(yield this._doOpenExternal(f,M),!0):!1})}),this._openers.push(new er(s)),this._openers.push(new tr(t))}registerOpener(t){return{dispose:this._openers.unshift(t)}}registerValidator(t){return{dispose:this._validators.push(t)}}registerExternalUriResolver(t){return{dispose:this._resolvers.push(t)}}setDefaultExternalOpener(t){this._defaultExternalOpener=t}registerExternalOpener(t){return{dispose:this._externalOpeners.push(t)}}open(t,s){var f;return ws(this,void 0,void 0,function*(){const M=typeof t=="string"?Gi.r.parse(t):t,V=(f=this._resolvedUriTargets.get(M))!==null&&f!==void 0?f:t;for(const q of this._validators)if(!(yield q.shouldOpen(V,s)))return!1;for(const q of this._openers)if(yield q.open(t,s))return!0;return!1})}resolveExternalUri(t,s){return ws(this,void 0,void 0,function*(){for(const f of this._resolvers)try{const M=yield f.resolveExternalUri(t,s);if(M)return this._resolvedUriTargets.has(M.resolved)||this._resolvedUriTargets.set(M.resolved,t),M}catch{}throw new Error("Could not resolve external URI: "+t.toString())})}_doOpenExternal(t,s){return ws(this,void 0,void 0,function*(){const f=typeof t=="string"?Gi.r.parse(t):t;let M;try{M=(yield this.resolveExternalUri(f,s)).resolved}catch{M=f}let V;if(typeof t=="string"&&f.toString()===M.toString()?V=t:V=encodeURI(M.toString(!0)),s?.allowContributedOpeners){const q=typeof s?.allowContributedOpeners=="string"?s?.allowContributedOpeners:void 0;for(const se of this._externalOpeners)if(yield se.openExternal(V,{sourceUri:f,preferredOpenerId:q},Bs.X.None))return!0}return this._defaultExternalOpener.openExternal(V,{sourceUri:f},Bs.X.None)})}dispose(){this._validators.clear()}};Eo=qo([Lo(0,U.T),Lo(1,Qt.wT)],Eo);var Jn=y(27619),ir=y(48295),ji=y(4874),Fr=function(ee,t,s,f){var M=arguments.length,V=M<3?t:f===null?f=Object.getOwnPropertyDescriptor(t,s):f,q;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")V=Reflect.decorate(ee,t,s,f);else for(var se=ee.length-1;se>=0;se--)(q=ee[se])&&(V=(M<3?q(V):M>3?q(t,s,V):q(t,s))||V);return M>3&&V&&Object.defineProperty(t,s,V),V},Us=function(ee,t){return function(s,f){t(s,f,ee)}};class Er extends K.jG{constructor(t){super(),this.model=t,this._markersData=new Map,this._register((0,K.s)(()=>{this.model.deltaDecorations([...this._markersData.keys()],[]),this._markersData.clear()}))}update(t,s){const f=[...this._markersData.keys()];this._markersData.clear();const M=this.model.deltaDecorations(f,s);for(let V=0;V<M.length;V++)this._markersData.set(M[V],t[V]);return f.length!==0||M.length!==0}getMarker(t){return this._markersData.get(t.id)}}let ko=class extends K.jG{constructor(t,s){super(),this._markerService=s,this._onDidChangeMarker=this._register(new m.vl),this._markerDecorations=new Di.fT,t.getModels().forEach(f=>this._onModelAdded(f)),this._register(t.onModelAdded(this._onModelAdded,this)),this._register(t.onModelRemoved(this._onModelRemoved,this)),this._register(this._markerService.onMarkerChanged(this._handleMarkerChange,this))}dispose(){super.dispose(),this._markerDecorations.forEach(t=>t.dispose()),this._markerDecorations.clear()}getMarker(t,s){const f=this._markerDecorations.get(t);return f&&f.getMarker(s)||null}_handleMarkerChange(t){t.forEach(s=>{const f=this._markerDecorations.get(s);f&&this._updateDecorations(f)})}_onModelAdded(t){const s=new Er(t);this._markerDecorations.set(t.uri,s),this._updateDecorations(s)}_onModelRemoved(t){var s;const f=this._markerDecorations.get(t.uri);f&&(f.dispose(),this._markerDecorations.delete(t.uri)),(t.uri.scheme===ei.ny.inMemory||t.uri.scheme===ei.ny.internal||t.uri.scheme===ei.ny.vscode)&&((s=this._markerService)===null||s===void 0||s.read({resource:t.uri}).map(M=>M.owner).forEach(M=>this._markerService.remove(M,[t.uri])))}_updateDecorations(t){const s=this._markerService.read({resource:t.model.uri,take:500}),f=s.map(M=>({range:this._createDecorationRange(t.model,M),options:this._createDecorationOption(M)}));t.update(s,f)&&this._onDidChangeMarker.fire(t.model)}_createDecorationRange(t,s){let f=Se.Q.lift(s);if(s.severity===Jn.cj.Hint&&!this._hasMarkerTag(s,1)&&!this._hasMarkerTag(s,2)&&(f=f.setEndPosition(f.startLineNumber,f.startColumn+2)),f=t.validateRange(f),f.isEmpty()){const M=t.getLineLastNonWhitespaceColumn(f.startLineNumber)||t.getLineMaxColumn(f.startLineNumber);if(M===1||f.endColumn>=M)return f;const V=t.getWordAtPosition(f.getStartPosition());V&&(f=new Se.Q(f.startLineNumber,V.startColumn,f.endLineNumber,V.endColumn))}else if(s.endColumn===Number.MAX_VALUE&&s.startColumn===1&&f.startLineNumber===f.endLineNumber){const M=t.getLineFirstNonWhitespaceColumn(s.startLineNumber);M<f.endColumn&&(f=new Se.Q(f.startLineNumber,M,f.endLineNumber,f.endColumn),s.startColumn=M)}return f}_createDecorationOption(t){let s,f,M,V,q;switch(t.severity){case Jn.cj.Hint:this._hasMarkerTag(t,2)?s=void 0:this._hasMarkerTag(t,1)?s="squiggly-unnecessary":s="squiggly-hint",M=0;break;case Jn.cj.Warning:s="squiggly-warning",f=(0,oi.Yf)(ir.aZ),M=20,q={color:(0,oi.Yf)(ji.uMG),position:p.R3.Inline};break;case Jn.cj.Info:s="squiggly-info",f=(0,oi.Yf)(ir.AQ),M=10;break;case Jn.cj.Error:default:s="squiggly-error",f=(0,oi.Yf)(ir.yI),M=30,q={color:(0,oi.Yf)(ji.yLC),position:p.R3.Inline};break}return t.tags&&(t.tags.indexOf(1)!==-1&&(V="squiggly-inline-unnecessary"),t.tags.indexOf(2)!==-1&&(V="squiggly-inline-deprecated")),{description:"marker-decoration",stickiness:1,className:s,showIfCollapsed:!0,overviewRuler:{color:f,position:p.A5.Right},minimap:q,zIndex:M,inlineClassName:V}}_hasMarkerTag(t,s){return t.tags?t.tags.indexOf(s)>=0:!1}};ko=Fr([Us(0,u.S),Us(1,Jn.DR)],ko);var va=y(80886),Do=y(40931),Io=y(50946),js=y(53909),xo=y(91818),Is=y(94901);const Wr={buttonBackground:Is.Q1.fromHex("#0E639C"),buttonHoverBackground:Is.Q1.fromHex("#006BB3"),buttonSeparator:Is.Q1.white,buttonForeground:Is.Q1.white};class kr extends K.jG{constructor(t,s){super(),this._onDidClick=this._register(new m.vl),this.options=s||Object.create(null),(0,Ui.co)(this.options,Wr,!1),this.buttonForeground=this.options.buttonForeground,this.buttonBackground=this.options.buttonBackground,this.buttonHoverBackground=this.options.buttonHoverBackground,this.buttonSecondaryForeground=this.options.buttonSecondaryForeground,this.buttonSecondaryBackground=this.options.buttonSecondaryBackground,this.buttonSecondaryHoverBackground=this.options.buttonSecondaryHoverBackground,this.buttonBorder=this.options.buttonBorder,this._element=document.createElement("a"),this._element.classList.add("monaco-button"),this._element.tabIndex=0,this._element.setAttribute("role","button"),t.appendChild(this._element),this._register(Qn.q.addTarget(this._element)),[Ue.Bx.CLICK,Qn.B.Tap].forEach(f=>{this._register((0,Ue.ko)(this._element,f,M=>{if(!this.enabled){Ue.fs.stop(M);return}this._onDidClick.fire(M)}))}),this._register((0,Ue.ko)(this._element,Ue.Bx.KEY_DOWN,f=>{const M=new sn.Z(f);let V=!1;this.enabled&&(M.equals(3)||M.equals(10))?(this._onDidClick.fire(f),V=!0):M.equals(9)&&(this._element.blur(),V=!0),V&&Ue.fs.stop(M,!0)})),this._register((0,Ue.ko)(this._element,Ue.Bx.MOUSE_OVER,f=>{this._element.classList.contains("disabled")||this.setHoverBackground()})),this._register((0,Ue.ko)(this._element,Ue.Bx.MOUSE_OUT,f=>{this.applyStyles()})),this.focusTracker=this._register((0,Ue.w5)(this._element)),this._register(this.focusTracker.onDidFocus(()=>{this.enabled&&this.setHoverBackground()})),this._register(this.focusTracker.onDidBlur(()=>{this.enabled&&this.applyStyles()})),this.applyStyles()}get onDidClick(){return this._onDidClick.event}setHoverBackground(){let t;this.options.secondary?t=this.buttonSecondaryHoverBackground?this.buttonSecondaryHoverBackground.toString():null:t=this.buttonHoverBackground?this.buttonHoverBackground.toString():null,t&&(this._element.style.backgroundColor=t)}style(t){this.buttonForeground=t.buttonForeground,this.buttonBackground=t.buttonBackground,this.buttonHoverBackground=t.buttonHoverBackground,this.buttonSecondaryForeground=t.buttonSecondaryForeground,this.buttonSecondaryBackground=t.buttonSecondaryBackground,this.buttonSecondaryHoverBackground=t.buttonSecondaryHoverBackground,this.buttonBorder=t.buttonBorder,this.applyStyles()}applyStyles(){if(this._element){let t,s;this.options.secondary?(s=this.buttonSecondaryForeground?this.buttonSecondaryForeground.toString():"",t=this.buttonSecondaryBackground?this.buttonSecondaryBackground.toString():""):(s=this.buttonForeground?this.buttonForeground.toString():"",t=this.buttonBackground?this.buttonBackground.toString():"");const f=this.buttonBorder?this.buttonBorder.toString():"";this._element.style.color=s,this._element.style.backgroundColor=t,this._element.style.borderWidth=f?"1px":"",this._element.style.borderStyle=f?"solid":"",this._element.style.borderColor=f}}get element(){return this._element}set label(t){this._element.classList.add("monaco-text-button"),this.options.supportIcons?(0,Ue.Ln)(this._element,...(0,xo.n)(t)):this._element.textContent=t,typeof this.options.title=="string"?this._element.title=this.options.title:this.options.title&&(this._element.title=t)}set enabled(t){t?(this._element.classList.remove("disabled"),this._element.setAttribute("aria-disabled",String(!1)),this._element.tabIndex=0):(this._element.classList.add("disabled"),this._element.setAttribute("aria-disabled",String(!0)))}get enabled(){return!this._element.classList.contains("disabled")}}var Ks=y(49233);const nr="done",To="active",Mo="infinite",lo="infinite-long-running",No="discrete",sr={progressBarBackground:Is.Q1.fromHex("#0E70C0")};class Po extends K.jG{constructor(t,s){super(),this.options=s||Object.create(null),(0,Ui.co)(this.options,sr,!1),this.workedVal=0,this.progressBarBackground=this.options.progressBarBackground,this.showDelayedScheduler=this._register(new w.uC(()=>(0,Ue.WU)(this.element),0)),this.longRunningScheduler=this._register(new w.uC(()=>this.infiniteLongRunning(),Po.LONG_RUNNING_INFINITE_THRESHOLD)),this.create(t)}create(t){this.element=document.createElement("div"),this.element.classList.add("monaco-progress-container"),this.element.setAttribute("role","progressbar"),this.element.setAttribute("aria-valuemin","0"),t.appendChild(this.element),this.bit=document.createElement("div"),this.bit.classList.add("progress-bit"),this.element.appendChild(this.bit),this.applyStyles()}off(){this.bit.style.width="inherit",this.bit.style.opacity="1",this.element.classList.remove(To,Mo,lo,No),this.workedVal=0,this.totalWork=void 0,this.longRunningScheduler.cancel()}stop(){return this.doDone(!1)}doDone(t){return this.element.classList.add(nr),this.element.classList.contains(Mo)?(this.bit.style.opacity="0",t?setTimeout(()=>this.off(),200):this.off()):(this.bit.style.width="inherit",t?setTimeout(()=>this.off(),200):this.off()),this}infinite(){return this.bit.style.width="2%",this.bit.style.opacity="1",this.element.classList.remove(No,nr,lo),this.element.classList.add(To,Mo),this.longRunningScheduler.schedule(),this}infiniteLongRunning(){this.element.classList.add(lo)}getContainer(){return this.element}style(t){this.progressBarBackground=t.progressBarBackground,this.applyStyles()}applyStyles(){if(this.bit){const t=this.progressBarBackground?this.progressBarBackground.toString():"";this.bit.style.backgroundColor=t}}}Po.LONG_RUNNING_INFINITE_THRESHOLD=1e4;var Vr=y(94664);const or={},rr=new Vr.n("quick-input-button-icon-");function co(ee){if(!ee)return;let t;const s=ee.dark.toString();return or[s]?t=or[s]:(t=rr.nextId(),Ue.Wt(`.${t}, .hc-light .${t}`,`background-image: ${Ue.Tf(ee.light||ee.dark)}`),Ue.Wt(`.vs-dark .${t}, .hc-black .${t}`,`background-image: ${Ue.Tf(ee.dark)}`),or[s]=t),t}var as=y(32802),Hr=y(29004);const zr=Ue.$;class Ur extends K.jG{constructor(t){super(),this.parent=t,this.onKeyDown=s=>Ue.ko(this.inputBox.inputElement,Ue.Bx.KEY_DOWN,f=>{s(new sn.Z(f))}),this.onMouseDown=s=>Ue.ko(this.inputBox.inputElement,Ue.Bx.MOUSE_DOWN,f=>{s(new jn.P(f))}),this.onDidChange=s=>this.inputBox.onDidChange(s),this.container=Ue.BC(this.parent,zr(".quick-input-box")),this.inputBox=this._register(new Hr.c(this.container,void 0))}get value(){return this.inputBox.value}set value(t){this.inputBox.value=t}select(t=null){this.inputBox.select(t)}isSelectionAtEnd(){return this.inputBox.isSelectionAtEnd()}get placeholder(){return this.inputBox.inputElement.getAttribute("placeholder")||""}set placeholder(t){this.inputBox.setPlaceHolder(t)}get ariaLabel(){return this.inputBox.getAriaLabel()}set ariaLabel(t){this.inputBox.setAriaLabel(t)}get password(){return this.inputBox.inputElement.type==="password"}set password(t){this.inputBox.inputElement.type=t?"password":"text"}setAttribute(t,s){this.inputBox.inputElement.setAttribute(t,s)}removeAttribute(t){this.inputBox.inputElement.removeAttribute(t)}showDecoration(t){t===Pi.A.Ignore?this.inputBox.hideMessage():this.inputBox.showMessage({type:t===Pi.A.Info?1:t===Pi.A.Warning?2:3,content:""})}stylesForType(t){return this.inputBox.stylesForType(t===Pi.A.Info?1:t===Pi.A.Warning?2:3)}setFocus(){this.inputBox.focus()}layout(){this.inputBox.layout()}style(t){this.inputBox.style(t)}}var _s=y(84431);const Oo=Ue.$;class ar{constructor(t,s,f){this.os=s,this.keyElements=new Set,this.options=f||Object.create(null),this.labelBackground=this.options.keybindingLabelBackground,this.labelForeground=this.options.keybindingLabelForeground,this.labelBorder=this.options.keybindingLabelBorder,this.labelBottomBorder=this.options.keybindingLabelBottomBorder,this.labelShadow=this.options.keybindingLabelShadow,this.domNode=Ue.BC(t,Oo(".monaco-keybinding")),this.didEverRender=!1,t.appendChild(this.domNode)}get element(){return this.domNode}set(t,s){this.didEverRender&&this.keybinding===t&&ar.areSame(this.matches,s)||(this.keybinding=t,this.matches=s,this.render())}render(){if(this.clear(),this.keybinding){const[t,s]=this.keybinding.getParts();t&&this.renderPart(this.domNode,t,this.matches?this.matches.firstPart:null),s&&(Ue.BC(this.domNode,Oo("span.monaco-keybinding-key-chord-separator",void 0," ")),this.renderPart(this.domNode,s,this.matches?this.matches.chordPart:null)),this.domNode.title=this.keybinding.getAriaLabel()||""}else this.options&&this.options.renderUnboundKeybindings&&this.renderUnbound(this.domNode);this.applyStyles(),this.didEverRender=!0}clear(){Ue.w_(this.domNode),this.keyElements.clear()}renderPart(t,s,f){const M=Ze.Of.modifierLabels[this.os];s.ctrlKey&&this.renderKey(t,M.ctrlKey,!!f?.ctrlKey,M.separator),s.shiftKey&&this.renderKey(t,M.shiftKey,!!f?.shiftKey,M.separator),s.altKey&&this.renderKey(t,M.altKey,!!f?.altKey,M.separator),s.metaKey&&this.renderKey(t,M.metaKey,!!f?.metaKey,M.separator);const V=s.keyLabel;V&&this.renderKey(t,V,!!f?.keyCode,"")}renderKey(t,s,f,M){Ue.BC(t,this.createKeyElement(s,f?".highlight":"")),M&&Ue.BC(t,Oo("span.monaco-keybinding-key-separator",void 0,M))}renderUnbound(t){Ue.BC(t,this.createKeyElement((0,fi.kg)("unbound","Unbound")))}createKeyElement(t,s=""){const f=Oo("span.monaco-keybinding-key"+s,void 0,t);return this.keyElements.add(f),f}style(t){this.labelBackground=t.keybindingLabelBackground,this.labelForeground=t.keybindingLabelForeground,this.labelBorder=t.keybindingLabelBorder,this.labelBottomBorder=t.keybindingLabelBottomBorder,this.labelShadow=t.keybindingLabelShadow,this.applyStyles()}applyStyles(){var t;if(this.element){for(const s of this.keyElements)this.labelBackground&&(s.style.backgroundColor=(t=this.labelBackground)===null||t===void 0?void 0:t.toString()),this.labelBorder&&(s.style.borderColor=this.labelBorder.toString()),this.labelBottomBorder&&(s.style.borderBottomColor=this.labelBottomBorder.toString()),this.labelShadow&&(s.style.boxShadow=`inset 0 -1px 0 ${this.labelShadow}`);this.labelForeground&&(this.element.style.color=this.labelForeground.toString())}}static areSame(t,s){return t===s||!t&&!s?!0:!!t&&!!s&&(0,Ui.aI)(t.firstPart,s.firstPart)&&(0,Ui.aI)(t.chordPart,s.chordPart)}}const Dr=new w.kb(()=>{const ee=new Intl.Collator(void 0,{numeric:!0,sensitivity:"base"});return{collator:ee,collatorIsNumeric:ee.resolvedOptions().numeric}}),lr=new w.kb(()=>({collator:new Intl.Collator(void 0,{numeric:!0})})),jr=new w.kb(()=>({collator:new Intl.Collator(void 0,{numeric:!0,sensitivity:"accent"})}));function Kr(ee,t,s=!1){const f=ee||"",M=t||"",V=Dr.value.collator.compare(f,M);return Dr.value.collatorIsNumeric&&V===0&&f!==M?f<M?-1:1:V}function $r(ee,t,s){const f=ee.toLowerCase(),M=t.toLowerCase(),V=Gr(ee,t,s);if(V)return V;const q=f.endsWith(s),se=M.endsWith(s);if(q!==se)return q?-1:1;const _e=Kr(f,M);return _e!==0?_e:f.localeCompare(M)}function Gr(ee,t,s){const f=ee.toLowerCase(),M=t.toLowerCase(),V=f.startsWith(s),q=M.startsWith(s);if(V!==q)return V?-1:1;if(V&&q){if(f.length<M.length)return-1;if(f.length>M.length)return 1}return 0}var Ir=y(88846),xr=function(ee,t,s,f){var M=arguments.length,V=M<3?t:f===null?f=Object.getOwnPropertyDescriptor(t,s):f,q;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")V=Reflect.decorate(ee,t,s,f);else for(var se=ee.length-1;se>=0;se--)(q=ee[se])&&(V=(M<3?q(V):M>3?q(t,s,V):q(t,s))||V);return M>3&&V&&Object.defineProperty(t,s,V),V},Qr=function(ee,t,s,f){function M(V){return V instanceof s?V:new s(function(q){q(V)})}return new(s||(s=Promise))(function(V,q){function se(Oe){try{De(f.next(Oe))}catch(qe){q(qe)}}function _e(Oe){try{De(f.throw(Oe))}catch(qe){q(qe)}}function De(Oe){Oe.done?V(Oe.value):M(Oe.value).then(se,_e)}De((f=f.apply(ee,t||[])).next())})};const ls=Ue.$;class Zr{constructor(t){this.hidden=!1,this._onChecked=new m.vl,this.onChecked=this._onChecked.event,Object.assign(this,t)}get checked(){return!!this._checked}set checked(t){t!==this._checked&&(this._checked=t,this._onChecked.fire(t))}dispose(){this._onChecked.dispose()}}class ho{get templateId(){return ho.ID}renderTemplate(t){const s=Object.create(null);s.toDisposeElement=[],s.toDisposeTemplate=[],s.entry=Ue.BC(t,ls(".quick-input-list-entry"));const f=Ue.BC(s.entry,ls("label.quick-input-list-label"));s.toDisposeTemplate.push(Ue.b2(f,Ue.Bx.CLICK,De=>{s.checkbox.offsetParent||De.preventDefault()})),s.checkbox=Ue.BC(f,ls("input.quick-input-list-checkbox")),s.checkbox.type="checkbox",s.toDisposeTemplate.push(Ue.b2(s.checkbox,Ue.Bx.CHANGE,De=>{s.element.checked=s.checkbox.checked}));const M=Ue.BC(f,ls(".quick-input-list-rows")),V=Ue.BC(M,ls(".quick-input-list-row")),q=Ue.BC(M,ls(".quick-input-list-row"));s.label=new _s.s(V,{supportHighlights:!0,supportDescriptionHighlights:!0,supportIcons:!0});const se=Ue.BC(V,ls(".quick-input-list-entry-keybinding"));s.keybinding=new ar(se,v.OS);const _e=Ue.BC(q,ls(".quick-input-list-label-meta"));return s.detail=new _s.s(_e,{supportHighlights:!0,supportIcons:!0}),s.separator=Ue.BC(s.entry,ls(".quick-input-list-separator")),s.actionBar=new Rs.E(s.entry),s.actionBar.domNode.classList.add("quick-input-list-entry-action-bar"),s.toDisposeTemplate.push(s.actionBar),s}renderElement(t,s,f){f.toDisposeElement=(0,K.AS)(f.toDisposeElement),f.element=t,f.checkbox.checked=t.checked,f.toDisposeElement.push(t.onChecked(De=>f.checkbox.checked=De));const{labelHighlights:M,descriptionHighlights:V,detailHighlights:q}=t,se=Object.create(null);se.matches=M||[],se.descriptionTitle=t.saneDescription,se.descriptionMatches=V||[],se.extraClasses=t.item.iconClasses,se.italic=t.item.italic,se.strikethrough=t.item.strikethrough,f.label.setLabel(t.saneLabel,t.saneDescription,se),f.keybinding.set(t.item.keybinding),t.saneDetail&&f.detail.setLabel(t.saneDetail,void 0,{matches:q,title:t.saneDetail}),t.separator&&t.separator.label?(f.separator.textContent=t.separator.label,f.separator.style.display=""):f.separator.style.display="none",f.entry.classList.toggle("quick-input-list-separator-border",!!t.separator),f.actionBar.clear();const _e=t.item.buttons;_e&&_e.length?(f.actionBar.push(_e.map((De,Oe)=>{let qe=De.iconClass||(De.iconPath?co(De.iconPath):void 0);De.alwaysVisible&&(qe=qe?`${qe} always-visible`:"always-visible");const Bt=new ms.rc(`id-${Oe}`,"",qe,!0,()=>Qr(this,void 0,void 0,function*(){t.fireButtonTriggered({button:De,item:t.item})}));return Bt.tooltip=De.tooltip||"",Bt}),{icon:!0,label:!1}),f.entry.classList.add("has-actions")):f.entry.classList.remove("has-actions")}disposeElement(t,s,f){f.toDisposeElement=(0,K.AS)(f.toDisposeElement)}disposeTemplate(t){t.toDisposeElement=(0,K.AS)(t.toDisposeElement),t.toDisposeTemplate=(0,K.AS)(t.toDisposeTemplate)}}ho.ID="listelement";class Yr{getHeight(t){return t.saneDetail?44:22}getTemplateId(t){return ho.ID}}var Le;(function(ee){ee[ee.First=1]="First",ee[ee.Second=2]="Second",ee[ee.Last=3]="Last",ee[ee.Next=4]="Next",ee[ee.Previous=5]="Previous",ee[ee.NextPage=6]="NextPage",ee[ee.PreviousPage=7]="PreviousPage"})(Le||(Le={}));class e{constructor(t,s,f){this.parent=t,this.inputElements=[],this.elements=[],this.elementsToIndexes=new Map,this.matchOnDescription=!1,this.matchOnDetail=!1,this.matchOnLabel=!0,this.matchOnLabelMode="fuzzy",this.matchOnMeta=!0,this.sortByLabel=!0,this._onChangedAllVisibleChecked=new m.vl,this.onChangedAllVisibleChecked=this._onChangedAllVisibleChecked.event,this._onChangedCheckedCount=new m.vl,this.onChangedCheckedCount=this._onChangedCheckedCount.event,this._onChangedVisibleCount=new m.vl,this.onChangedVisibleCount=this._onChangedVisibleCount.event,this._onChangedCheckedElements=new m.vl,this.onChangedCheckedElements=this._onChangedCheckedElements.event,this._onButtonTriggered=new m.vl,this.onButtonTriggered=this._onButtonTriggered.event,this._onKeyDown=new m.vl,this.onKeyDown=this._onKeyDown.event,this._onLeave=new m.vl,this.onLeave=this._onLeave.event,this._fireCheckedEvents=!0,this.elementDisposables=[],this.disposables=[],this.id=s,this.container=Ue.BC(this.parent,ls(".quick-input-list"));const M=new Yr,V=new S;this.list=f.createList("QuickInput",this.container,M,[new ho],{identityProvider:{getId:q=>q.saneLabel},setRowLineHeight:!1,multipleSelectionSupport:!1,horizontalScrolling:!1,accessibilityProvider:V}),this.list.getHTMLElement().id=s,this.disposables.push(this.list),this.disposables.push(this.list.onKeyDown(q=>{const se=new sn.Z(q);switch(se.keyCode){case 10:this.toggleCheckbox();break;case 31:(v.zx?q.metaKey:q.ctrlKey)&&this.list.setFocus((0,pe.y1)(this.list.length));break;case 16:{const _e=this.list.getFocus();_e.length===1&&_e[0]===0&&this._onLeave.fire();break}case 18:{const _e=this.list.getFocus();_e.length===1&&_e[0]===this.list.length-1&&this._onLeave.fire();break}}this._onKeyDown.fire(se)})),this.disposables.push(this.list.onMouseDown(q=>{q.browserEvent.button!==2&&q.browserEvent.preventDefault()})),this.disposables.push(Ue.ko(this.container,Ue.Bx.CLICK,q=>{(q.x||q.y)&&this._onLeave.fire()})),this.disposables.push(this.list.onMouseMiddleClick(q=>{this._onLeave.fire()})),this.disposables.push(this.list.onContextMenu(q=>{typeof q.index=="number"&&(q.browserEvent.preventDefault(),this.list.setSelection([q.index]))})),this.disposables.push(this._onChangedAllVisibleChecked,this._onChangedCheckedCount,this._onChangedVisibleCount,this._onChangedCheckedElements,this._onButtonTriggered,this._onLeave,this._onKeyDown)}get onDidChangeFocus(){return m.Jh.map(this.list.onDidChangeFocus,t=>t.elements.map(s=>s.item))}get onDidChangeSelection(){return m.Jh.map(this.list.onDidChangeSelection,t=>({items:t.elements.map(s=>s.item),event:t.browserEvent}))}get scrollTop(){return this.list.scrollTop}set scrollTop(t){this.list.scrollTop=t}getAllVisibleChecked(){return this.allVisibleChecked(this.elements,!1)}allVisibleChecked(t,s=!0){for(let f=0,M=t.length;f<M;f++){const V=t[f];if(!V.hidden)if(V.checked)s=!0;else return!1}return s}getCheckedCount(){let t=0;const s=this.elements;for(let f=0,M=s.length;f<M;f++)s[f].checked&&t++;return t}getVisibleCount(){let t=0;const s=this.elements;for(let f=0,M=s.length;f<M;f++)s[f].hidden||t++;return t}setAllVisibleChecked(t){try{this._fireCheckedEvents=!1,this.elements.forEach(s=>{s.hidden||(s.checked=t)})}finally{this._fireCheckedEvents=!0,this.fireCheckedEvents()}}setElements(t){this.elementDisposables=(0,K.AS)(this.elementDisposables);const s=f=>this.fireButtonTriggered(f);this.inputElements=t,this.elements=t.reduce((f,M,V)=>{var q,se,_e;if(M.type!=="separator"){const De=V&&t[V-1],Oe=M.label&&M.label.replace(/\r?\n/g," "),qe=(0,fs._k)(Oe).text.trim(),Bt=M.meta&&M.meta.replace(/\r?\n/g," "),jt=M.description&&M.description.replace(/\r?\n/g," "),Mi=M.detail&&M.detail.replace(/\r?\n/g," "),ln=M.ariaLabel||[Oe,jt,Mi].map(En=>(0,ps.R$)(En)).filter(En=>!!En).join(", "),tn=this.parent.classList.contains("show-checkboxes");f.push(new Zr({hasCheckbox:tn,index:V,item:M,saneLabel:Oe,saneSortLabel:qe,saneMeta:Bt,saneAriaLabel:ln,saneDescription:jt,saneDetail:Mi,labelHighlights:(q=M.highlights)===null||q===void 0?void 0:q.label,descriptionHighlights:(se=M.highlights)===null||se===void 0?void 0:se.description,detailHighlights:(_e=M.highlights)===null||_e===void 0?void 0:_e.detail,checked:!1,separator:De&&De.type==="separator"?De:void 0,fireButtonTriggered:s}))}return f},[]),this.elementDisposables.push(...this.elements),this.elementDisposables.push(...this.elements.map(f=>f.onChecked(()=>this.fireCheckedEvents()))),this.elementsToIndexes=this.elements.reduce((f,M,V)=>(f.set(M.item,V),f),new Map),this.list.splice(0,this.list.length),this.list.splice(0,this.list.length,this.elements),this._onChangedVisibleCount.fire(this.elements.length)}getFocusedElements(){return this.list.getFocusedElements().map(t=>t.item)}setFocusedElements(t){if(this.list.setFocus(t.filter(s=>this.elementsToIndexes.has(s)).map(s=>this.elementsToIndexes.get(s))),t.length>0){const s=this.list.getFocus()[0];typeof s=="number"&&this.list.reveal(s)}}getActiveDescendant(){return this.list.getHTMLElement().getAttribute("aria-activedescendant")}setSelectedElements(t){this.list.setSelection(t.filter(s=>this.elementsToIndexes.has(s)).map(s=>this.elementsToIndexes.get(s)))}getCheckedElements(){return this.elements.filter(t=>t.checked).map(t=>t.item)}setCheckedElements(t){try{this._fireCheckedEvents=!1;const s=new Set;for(const f of t)s.add(f);for(const f of this.elements)f.checked=s.has(f.item)}finally{this._fireCheckedEvents=!0,this.fireCheckedEvents()}}set enabled(t){this.list.getHTMLElement().style.pointerEvents=t?"":"none"}focus(t){if(!this.list.length)return;switch(t===Le.Next&&this.list.getFocus()[0]===this.list.length-1&&(t=Le.First),t===Le.Previous&&this.list.getFocus()[0]===0&&(t=Le.Last),t===Le.Second&&this.list.length<2&&(t=Le.First),t){case Le.First:this.list.focusFirst();break;case Le.Second:this.list.focusNth(1);break;case Le.Last:this.list.focusLast();break;case Le.Next:this.list.focusNext();break;case Le.Previous:this.list.focusPrevious();break;case Le.NextPage:this.list.focusNextPage();break;case Le.PreviousPage:this.list.focusPreviousPage();break}const s=this.list.getFocus()[0];typeof s=="number"&&this.list.reveal(s)}clearFocus(){this.list.setFocus([])}domFocus(){this.list.domFocus()}layout(t){this.list.getHTMLElement().style.maxHeight=t?`calc(${Math.floor(t/44)*44}px)`:"",this.list.layout()}filter(t){if(!(this.sortByLabel||this.matchOnLabel||this.matchOnDescription||this.matchOnDetail))return this.list.layout(),!1;const s=t;if(t=t.trim(),!t||!(this.matchOnLabel||this.matchOnDescription||this.matchOnDetail))this.elements.forEach(M=>{M.labelHighlights=void 0,M.descriptionHighlights=void 0,M.detailHighlights=void 0,M.hidden=!1;const V=M.index&&this.inputElements[M.index-1];M.separator=V&&V.type==="separator"?V:void 0});else{let M;this.elements.forEach(V=>{let q;this.matchOnLabelMode==="fuzzy"?q=this.matchOnLabel?(0,k.UH)((0,fs.pz)(t,(0,fs._k)(V.saneLabel))):void 0:q=this.matchOnLabel?(0,k.UH)(i(s,(0,fs._k)(V.saneLabel))):void 0;const se=this.matchOnDescription?(0,k.UH)((0,fs.pz)(t,(0,fs._k)(V.saneDescription||""))):void 0,_e=this.matchOnDetail?(0,k.UH)((0,fs.pz)(t,(0,fs._k)(V.saneDetail||""))):void 0,De=this.matchOnMeta?(0,k.UH)((0,fs.pz)(t,(0,fs._k)(V.saneMeta||""))):void 0;if(q||se||_e||De?(V.labelHighlights=q,V.descriptionHighlights=se,V.detailHighlights=_e,V.hidden=!1):(V.labelHighlights=void 0,V.descriptionHighlights=void 0,V.detailHighlights=void 0,V.hidden=!V.item.alwaysShow),V.separator=void 0,!this.sortByLabel){const Oe=V.index&&this.inputElements[V.index-1];M=Oe&&Oe.type==="separator"?Oe:M,M&&!V.hidden&&(V.separator=M,M=void 0)}})}const f=this.elements.filter(M=>!M.hidden);if(this.sortByLabel&&t){const M=t.toLowerCase();f.sort((V,q)=>_(V,q,M))}return this.elementsToIndexes=f.reduce((M,V,q)=>(M.set(V.item,q),M),new Map),this.list.splice(0,this.list.length,f),this.list.setFocus([]),this.list.layout(),this._onChangedAllVisibleChecked.fire(this.getAllVisibleChecked()),this._onChangedVisibleCount.fire(f.length),!0}toggleCheckbox(){try{this._fireCheckedEvents=!1;const t=this.list.getFocusedElements(),s=this.allVisibleChecked(t);for(const f of t)f.checked=!s}finally{this._fireCheckedEvents=!0,this.fireCheckedEvents()}}display(t){this.container.style.display=t?"":"none"}isDisplayed(){return this.container.style.display!=="none"}dispose(){this.elementDisposables=(0,K.AS)(this.elementDisposables),this.disposables=(0,K.AS)(this.disposables)}fireCheckedEvents(){this._fireCheckedEvents&&(this._onChangedAllVisibleChecked.fire(this.getAllVisibleChecked()),this._onChangedCheckedCount.fire(this.getCheckedCount()),this._onChangedCheckedElements.fire(this.getCheckedElements()))}fireButtonTriggered(t){this._onButtonTriggered.fire(t)}style(t){this.list.style(t)}}xr([Ir.B],e.prototype,"onDidChangeFocus",null),xr([Ir.B],e.prototype,"onDidChangeSelection",null);function i(ee,t){const{text:s,iconOffsets:f}=t;if(!f||f.length===0)return r(ee,s);const M=(0,$.NB)(s," "),V=s.length-M.length,q=r(ee,M);if(q)for(const se of q){const _e=f[se.start+V]+V;se.start+=_e,se.end+=_e}return q}function r(ee,t){const s=t.toLowerCase().indexOf(ee.toLowerCase());return s!==-1?[{start:s,end:s+ee.length}]:null}function _(ee,t,s){const f=ee.labelHighlights||[],M=t.labelHighlights||[];return f.length&&!M.length?-1:!f.length&&M.length?1:f.length===0&&M.length===0?0:$r(ee.saneSortLabel,t.saneSortLabel,s)}class S{getWidgetAriaLabel(){return(0,fi.kg)("quickInput","Quick Input")}getAriaLabel(t){var s;return!((s=t.separator)===null||s===void 0)&&s.label?`${t.saneAriaLabel}, ${t.separator.label}`:t.saneAriaLabel}getWidgetRole(){return"listbox"}getRole(t){return t.hasCheckbox?"checkbox":"option"}isChecked(t){if(t.hasCheckbox)return{value:t.checked,onDidChange:t.onChecked}}}var z=function(ee,t,s,f){function M(V){return V instanceof s?V:new s(function(q){q(V)})}return new(s||(s=Promise))(function(V,q){function se(Oe){try{De(f.next(Oe))}catch(qe){q(qe)}}function _e(Oe){try{De(f.throw(Oe))}catch(qe){q(qe)}}function De(Oe){Oe.done?V(Oe.value):M(Oe.value).then(se,_e)}De((f=f.apply(ee,t||[])).next())})};const ie=Ue.$,re={iconClass:ps.W6.quickInputBack.classNames,tooltip:(0,fi.kg)("quickInput.back","Back"),handle:-1};class le extends K.jG{constructor(t){super(),this.ui=t,this.visible=!1,this._enabled=!0,this._busy=!1,this._ignoreFocusOut=!1,this._buttons=[],this.noValidationMessage=le.noPromptMessage,this._severity=Pi.A.Ignore,this.buttonsUpdated=!1,this.onDidTriggerButtonEmitter=this._register(new m.vl),this.onDidHideEmitter=this._register(new m.vl),this.onDisposeEmitter=this._register(new m.vl),this.visibleDisposables=this._register(new K.Cm),this.onDidHide=this.onDidHideEmitter.event}get title(){return this._title}set title(t){this._title=t,this.update()}get description(){return this._description}set description(t){this._description=t,this.update()}get step(){return this._steps}set step(t){this._steps=t,this.update()}get totalSteps(){return this._totalSteps}set totalSteps(t){this._totalSteps=t,this.update()}get enabled(){return this._enabled}set enabled(t){this._enabled=t,this.update()}get contextKey(){return this._contextKey}set contextKey(t){this._contextKey=t,this.update()}get busy(){return this._busy}set busy(t){this._busy=t,this.update()}get ignoreFocusOut(){return this._ignoreFocusOut}set ignoreFocusOut(t){const s=this._ignoreFocusOut!==t&&!v.un;this._ignoreFocusOut=t&&!v.un,s&&this.update()}get buttons(){return this._buttons}set buttons(t){this._buttons=t,this.buttonsUpdated=!0,this.update()}get validationMessage(){return this._validationMessage}set validationMessage(t){this._validationMessage=t,this.update()}get severity(){return this._severity}set severity(t){this._severity=t,this.update()}show(){this.visible||(this.visibleDisposables.add(this.ui.onDidTriggerButton(t=>{this.buttons.indexOf(t)!==-1&&this.onDidTriggerButtonEmitter.fire(t)})),this.ui.show(this),this.visible=!0,this._lastValidationMessage=void 0,this._lastSeverity=void 0,this.buttons.length&&(this.buttonsUpdated=!0),this.update())}hide(){this.visible&&this.ui.hide()}didHide(t=as.kF.Other){this.visible=!1,this.visibleDisposables.clear(),this.onDidHideEmitter.fire({reason:t})}update(){if(!this.visible)return;const t=this.getTitle();t&&this.ui.title.textContent!==t?this.ui.title.textContent=t:!t&&this.ui.title.innerHTML!==" "&&(this.ui.title.innerText="\xA0");const s=this.getDescription();if(this.ui.description1.textContent!==s&&(this.ui.description1.textContent=s),this.ui.description2.textContent!==s&&(this.ui.description2.textContent=s),this.busy&&!this.busyDelay&&(this.busyDelay=new w.pc,this.busyDelay.setIfNotSet(()=>{this.visible&&this.ui.progressBar.infinite()},800)),!this.busy&&this.busyDelay&&(this.ui.progressBar.stop(),this.busyDelay.cancel(),this.busyDelay=void 0),this.buttonsUpdated){this.buttonsUpdated=!1,this.ui.leftActionBar.clear();const M=this.buttons.filter(q=>q===re);this.ui.leftActionBar.push(M.map((q,se)=>{const _e=new ms.rc(`id-${se}`,"",q.iconClass||co(q.iconPath),!0,()=>z(this,void 0,void 0,function*(){this.onDidTriggerButtonEmitter.fire(q)}));return _e.tooltip=q.tooltip||"",_e}),{icon:!0,label:!1}),this.ui.rightActionBar.clear();const V=this.buttons.filter(q=>q!==re);this.ui.rightActionBar.push(V.map((q,se)=>{const _e=new ms.rc(`id-${se}`,"",q.iconClass||co(q.iconPath),!0,()=>z(this,void 0,void 0,function*(){this.onDidTriggerButtonEmitter.fire(q)}));return _e.tooltip=q.tooltip||"",_e}),{icon:!0,label:!1})}this.ui.ignoreFocusOut=this.ignoreFocusOut,this.ui.setEnabled(this.enabled),this.ui.setContextKey(this.contextKey);const f=this.validationMessage||this.noValidationMessage;this._lastValidationMessage!==f&&(this._lastValidationMessage=f,Ue.Ln(this.ui.message,...(0,xo.n)(f))),this._lastSeverity!==this.severity&&(this._lastSeverity=this.severity,this.showMessageDecoration(this.severity))}getTitle(){return this.title&&this.step?`${this.title} (${this.getSteps()})`:this.title?this.title:this.step?this.getSteps():""}getDescription(){return this.description||""}getSteps(){return this.step&&this.totalSteps?(0,fi.kg)("quickInput.steps","{0}/{1}",this.step,this.totalSteps):this.step?String(this.step):""}showMessageDecoration(t){if(this.ui.inputBox.showDecoration(t),t!==Pi.A.Ignore){const s=this.ui.inputBox.stylesForType(t);this.ui.message.style.color=s.foreground?`${s.foreground}`:"",this.ui.message.style.backgroundColor=s.background?`${s.background}`:"",this.ui.message.style.border=s.border?`1px solid ${s.border}`:"",this.ui.message.style.marginBottom="-2px"}else this.ui.message.style.color="",this.ui.message.style.backgroundColor="",this.ui.message.style.border="",this.ui.message.style.marginBottom=""}dispose(){this.hide(),this.onDisposeEmitter.fire(),super.dispose()}}le.noPromptMessage=(0,fi.kg)("inputModeEntry","Press 'Enter' to confirm your input or 'Escape' to cancel");class me extends le{constructor(){super(...arguments),this._value="",this.onDidChangeValueEmitter=this._register(new m.vl),this.onWillAcceptEmitter=this._register(new m.vl),this.onDidAcceptEmitter=this._register(new m.vl),this.onDidCustomEmitter=this._register(new m.vl),this._items=[],this.itemsUpdated=!1,this._canSelectMany=!1,this._canAcceptInBackground=!1,this._matchOnDescription=!1,this._matchOnDetail=!1,this._matchOnLabel=!0,this._matchOnLabelMode="fuzzy",this._sortByLabel=!0,this._autoFocusOnList=!0,this._keepScrollPosition=!1,this._itemActivation=this.ui.isScreenReaderOptimized()?as.C1.NONE:as.C1.FIRST,this._activeItems=[],this.activeItemsUpdated=!1,this.activeItemsToConfirm=[],this.onDidChangeActiveEmitter=this._register(new m.vl),this._selectedItems=[],this.selectedItemsUpdated=!1,this.selectedItemsToConfirm=[],this.onDidChangeSelectionEmitter=this._register(new m.vl),this.onDidTriggerItemButtonEmitter=this._register(new m.vl),this.valueSelectionUpdated=!0,this._ok="default",this._customButton=!1,this.filterValue=t=>t,this.onDidChangeValue=this.onDidChangeValueEmitter.event,this.onWillAccept=this.onWillAcceptEmitter.event,this.onDidAccept=this.onDidAcceptEmitter.event,this.onDidChangeActive=this.onDidChangeActiveEmitter.event,this.onDidChangeSelection=this.onDidChangeSelectionEmitter.event,this.onDidTriggerItemButton=this.onDidTriggerItemButtonEmitter.event}get quickNavigate(){return this._quickNavigate}set quickNavigate(t){this._quickNavigate=t,this.update()}get value(){return this._value}set value(t){this.doSetValue(t)}doSetValue(t,s){this._value!==t&&(this._value=t,s||this.update(),this.visible&&this.ui.list.filter(this.filterValue(this._value))&&this.trySelectFirst(),this.onDidChangeValueEmitter.fire(this._value))}set ariaLabel(t){this._ariaLabel=t,this.update()}get ariaLabel(){return this._ariaLabel}get placeholder(){return this._placeholder}set placeholder(t){this._placeholder=t,this.update()}get items(){return this._items}get scrollTop(){return this.ui.list.scrollTop}set scrollTop(t){this.ui.list.scrollTop=t}set items(t){this._items=t,this.itemsUpdated=!0,this.update()}get canSelectMany(){return this._canSelectMany}set canSelectMany(t){this._canSelectMany=t,this.update()}get canAcceptInBackground(){return this._canAcceptInBackground}set canAcceptInBackground(t){this._canAcceptInBackground=t}get matchOnDescription(){return this._matchOnDescription}set matchOnDescription(t){this._matchOnDescription=t,this.update()}get matchOnDetail(){return this._matchOnDetail}set matchOnDetail(t){this._matchOnDetail=t,this.update()}get matchOnLabel(){return this._matchOnLabel}set matchOnLabel(t){this._matchOnLabel=t,this.update()}get matchOnLabelMode(){return this._matchOnLabelMode}set matchOnLabelMode(t){this._matchOnLabelMode=t,this.update()}get sortByLabel(){return this._sortByLabel}set sortByLabel(t){this._sortByLabel=t,this.update()}get autoFocusOnList(){return this._autoFocusOnList}set autoFocusOnList(t){this._autoFocusOnList=t,this.update()}get keepScrollPosition(){return this._keepScrollPosition}set keepScrollPosition(t){this._keepScrollPosition=t}get itemActivation(){return this._itemActivation}set itemActivation(t){this._itemActivation=t}get activeItems(){return this._activeItems}set activeItems(t){this._activeItems=t,this.activeItemsUpdated=!0,this.update()}get selectedItems(){return this._selectedItems}set selectedItems(t){this._selectedItems=t,this.selectedItemsUpdated=!0,this.update()}get keyMods(){return this._quickNavigate?as.Ym:this.ui.keyMods}set valueSelection(t){this._valueSelection=t,this.valueSelectionUpdated=!0,this.update()}get customButton(){return this._customButton}set customButton(t){this._customButton=t,this.update()}get customLabel(){return this._customButtonLabel}set customLabel(t){this._customButtonLabel=t,this.update()}get customHover(){return this._customButtonHover}set customHover(t){this._customButtonHover=t,this.update()}get ok(){return this._ok}set ok(t){this._ok=t,this.update()}get hideInput(){return!!this._hideInput}set hideInput(t){this._hideInput=t,this.update()}trySelectFirst(){this.autoFocusOnList&&(this.canSelectMany||this.ui.list.focus(Le.First))}show(){this.visible||(this.visibleDisposables.add(this.ui.inputBox.onDidChange(t=>{this.doSetValue(t,!0)})),this.visibleDisposables.add(this.ui.inputBox.onMouseDown(t=>{this.autoFocusOnList||this.ui.list.clearFocus()})),this.visibleDisposables.add((this._hideInput?this.ui.list:this.ui.inputBox).onKeyDown(t=>{switch(t.keyCode){case 18:this.ui.list.focus(Le.Next),this.canSelectMany&&this.ui.list.domFocus(),Ue.fs.stop(t,!0);break;case 16:this.ui.list.getFocusedElements().length?this.ui.list.focus(Le.Previous):this.ui.list.focus(Le.Last),this.canSelectMany&&this.ui.list.domFocus(),Ue.fs.stop(t,!0);break;case 12:this.ui.list.focus(Le.NextPage),this.canSelectMany&&this.ui.list.domFocus(),Ue.fs.stop(t,!0);break;case 11:this.ui.list.focus(Le.PreviousPage),this.canSelectMany&&this.ui.list.domFocus(),Ue.fs.stop(t,!0);break;case 17:if(!this._canAcceptInBackground||!this.ui.inputBox.isSelectionAtEnd())return;this.activeItems[0]&&(this._selectedItems=[this.activeItems[0]],this.onDidChangeSelectionEmitter.fire(this.selectedItems),this.handleAccept(!0));break;case 14:(t.ctrlKey||t.metaKey)&&!t.shiftKey&&!t.altKey&&(this.ui.list.focus(Le.First),Ue.fs.stop(t,!0));break;case 13:(t.ctrlKey||t.metaKey)&&!t.shiftKey&&!t.altKey&&(this.ui.list.focus(Le.Last),Ue.fs.stop(t,!0));break}})),this.visibleDisposables.add(this.ui.onDidAccept(()=>{this.canSelectMany?this.ui.list.getCheckedElements().length||(this._selectedItems=[],this.onDidChangeSelectionEmitter.fire(this.selectedItems)):this.activeItems[0]&&(this._selectedItems=[this.activeItems[0]],this.onDidChangeSelectionEmitter.fire(this.selectedItems)),this.handleAccept(!1)})),this.visibleDisposables.add(this.ui.onDidCustom(()=>{this.onDidCustomEmitter.fire()})),this.visibleDisposables.add(this.ui.list.onDidChangeFocus(t=>{this.activeItemsUpdated||this.activeItemsToConfirm!==this._activeItems&&(0,pe.aI)(t,this._activeItems,(s,f)=>s===f)||(this._activeItems=t,this.onDidChangeActiveEmitter.fire(t))})),this.visibleDisposables.add(this.ui.list.onDidChangeSelection(({items:t,event:s})=>{if(this.canSelectMany){t.length&&this.ui.list.setSelectedElements([]);return}this.selectedItemsToConfirm!==this._selectedItems&&(0,pe.aI)(t,this._selectedItems,(f,M)=>f===M)||(this._selectedItems=t,this.onDidChangeSelectionEmitter.fire(t),t.length&&this.handleAccept(s instanceof MouseEvent&&s.button===1))})),this.visibleDisposables.add(this.ui.list.onChangedCheckedElements(t=>{this.canSelectMany&&(this.selectedItemsToConfirm!==this._selectedItems&&(0,pe.aI)(t,this._selectedItems,(s,f)=>s===f)||(this._selectedItems=t,this.onDidChangeSelectionEmitter.fire(t)))})),this.visibleDisposables.add(this.ui.list.onButtonTriggered(t=>this.onDidTriggerItemButtonEmitter.fire(t))),this.visibleDisposables.add(this.registerQuickNavigation()),this.valueSelectionUpdated=!0),super.show()}handleAccept(t){let s=!1;this.onWillAcceptEmitter.fire({veto:()=>s=!0}),s||this.onDidAcceptEmitter.fire({inBackground:t})}registerQuickNavigation(){return Ue.ko(this.ui.container,Ue.Bx.KEY_UP,t=>{if(this.canSelectMany||!this._quickNavigate)return;const s=new sn.Z(t),f=s.keyCode;this._quickNavigate.keybindings.some(q=>{const[se,_e]=q.getParts();return _e?!1:se.shiftKey&&f===4?!(s.ctrlKey||s.altKey||s.metaKey):!!(se.altKey&&f===6||se.ctrlKey&&f===5||se.metaKey&&f===57)})&&(this.activeItems[0]&&(this._selectedItems=[this.activeItems[0]],this.onDidChangeSelectionEmitter.fire(this.selectedItems),this.handleAccept(!1)),this._quickNavigate=void 0)})}update(){if(!this.visible)return;const t=this.keepScrollPosition?this.scrollTop:0,s=!!this._hideInput&&this._items.length>0;this.ui.container.classList.toggle("hidden-input",s&&!this.description);const f={title:!!this.title||!!this.step||!!this.buttons.length,description:!!this.description,checkAll:this.canSelectMany&&!this._hideCheckAll,checkBox:this.canSelectMany,inputBox:!s,progressBar:!s,visibleCount:!0,count:this.canSelectMany,ok:this.ok==="default"?this.canSelectMany:this.ok,list:!0,message:!!this.validationMessage,customButton:this.customButton};this.ui.setVisibilities(f),super.update(),this.ui.inputBox.value!==this.value&&(this.ui.inputBox.value=this.value),this.valueSelectionUpdated&&(this.valueSelectionUpdated=!1,this.ui.inputBox.select(this._valueSelection&&{start:this._valueSelection[0],end:this._valueSelection[1]})),this.ui.inputBox.placeholder!==(this.placeholder||"")&&(this.ui.inputBox.placeholder=this.placeholder||"");let M=this.ariaLabel;if(M||(M=this.placeholder||me.DEFAULT_ARIA_LABEL,this.title&&(M+=` - ${this.title}`)),this.ui.inputBox.ariaLabel!==M&&(this.ui.inputBox.ariaLabel=M),this.ui.list.matchOnDescription=this.matchOnDescription,this.ui.list.matchOnDetail=this.matchOnDetail,this.ui.list.matchOnLabel=this.matchOnLabel,this.ui.list.matchOnLabelMode=this.matchOnLabelMode,this.ui.list.sortByLabel=this.sortByLabel,this.itemsUpdated)switch(this.itemsUpdated=!1,this.ui.list.setElements(this.items),this.ui.list.filter(this.filterValue(this.ui.inputBox.value)),this.ui.checkAll.checked=this.ui.list.getAllVisibleChecked(),this.ui.visibleCount.setCount(this.ui.list.getVisibleCount()),this.ui.count.setCount(this.ui.list.getCheckedCount()),this._itemActivation){case as.C1.NONE:this._itemActivation=as.C1.FIRST;break;case as.C1.SECOND:this.ui.list.focus(Le.Second),this._itemActivation=as.C1.FIRST;break;case as.C1.LAST:this.ui.list.focus(Le.Last),this._itemActivation=as.C1.FIRST;break;default:this.trySelectFirst();break}this.ui.container.classList.contains("show-checkboxes")!==!!this.canSelectMany&&(this.canSelectMany?this.ui.list.clearFocus():this.trySelectFirst()),this.activeItemsUpdated&&(this.activeItemsUpdated=!1,this.activeItemsToConfirm=this._activeItems,this.ui.list.setFocusedElements(this.activeItems),this.activeItemsToConfirm===this._activeItems&&(this.activeItemsToConfirm=null)),this.selectedItemsUpdated&&(this.selectedItemsUpdated=!1,this.selectedItemsToConfirm=this._selectedItems,this.canSelectMany?this.ui.list.setCheckedElements(this.selectedItems):this.ui.list.setSelectedElements(this.selectedItems),this.selectedItemsToConfirm===this._selectedItems&&(this.selectedItemsToConfirm=null)),this.ui.customButton.label=this.customLabel||"",this.ui.customButton.element.title=this.customHover||"",this.ui.setComboboxAccessibility(!0),f.inputBox||(this.ui.list.domFocus(),this.canSelectMany&&this.ui.list.focus(Le.First)),this.keepScrollPosition&&(this.scrollTop=t)}}me.DEFAULT_ARIA_LABEL=(0,fi.kg)("quickInputBox.ariaLabel","Type to narrow down results.");class we extends K.jG{constructor(t){super(),this.options=t,this.comboboxAccessibility=!1,this.enabled=!0,this.onDidAcceptEmitter=this._register(new m.vl),this.onDidCustomEmitter=this._register(new m.vl),this.onDidTriggerButtonEmitter=this._register(new m.vl),this.keyMods={ctrlCmd:!1,alt:!1},this.controller=null,this.onShowEmitter=this._register(new m.vl),this.onShow=this.onShowEmitter.event,this.onHideEmitter=this._register(new m.vl),this.onHide=this.onHideEmitter.event,this.idPrefix=t.idPrefix,this.parentElement=t.container,this.styles=t.styles,this.registerKeyModsListeners()}registerKeyModsListeners(){const t=s=>{this.keyMods.ctrlCmd=s.ctrlKey||s.metaKey,this.keyMods.alt=s.altKey};this._register(Ue.ko(window,Ue.Bx.KEY_DOWN,t,!0)),this._register(Ue.ko(window,Ue.Bx.KEY_UP,t,!0)),this._register(Ue.ko(window,Ue.Bx.MOUSE_DOWN,t,!0))}getUI(){if(this.ui)return this.ui;const t=Ue.BC(this.parentElement,ie(".quick-input-widget.show-file-icons"));t.tabIndex=-1,t.style.display="none";const s=Ue.li(t),f=Ue.BC(t,ie(".quick-input-titlebar")),M=this._register(new Rs.E(f));M.domNode.classList.add("quick-input-left-action-bar");const V=Ue.BC(f,ie(".quick-input-title")),q=this._register(new Rs.E(f));q.domNode.classList.add("quick-input-right-action-bar");const se=Ue.BC(t,ie(".quick-input-description")),_e=Ue.BC(t,ie(".quick-input-header")),De=Ue.BC(_e,ie("input.quick-input-check-all"));De.type="checkbox",De.setAttribute("aria-label",(0,fi.kg)("quickInput.checkAll","Toggle all checkboxes")),this._register(Ue.b2(De,Ue.Bx.CHANGE,Bi=>{const Vn=De.checked;kn.setAllVisibleChecked(Vn)})),this._register(Ue.ko(De,Ue.Bx.CLICK,Bi=>{(Bi.x||Bi.y)&&jt.setFocus()}));const Oe=Ue.BC(_e,ie(".quick-input-description")),qe=Ue.BC(_e,ie(".quick-input-and-message")),Bt=Ue.BC(qe,ie(".quick-input-filter")),jt=this._register(new Ur(Bt));jt.setAttribute("aria-describedby",`${this.idPrefix}message`);const Mi=Ue.BC(Bt,ie(".quick-input-visible-count"));Mi.setAttribute("aria-live","polite"),Mi.setAttribute("aria-atomic","true");const ln=new Ks.x(Mi,{countFormat:(0,fi.kg)({key:"quickInput.visibleCount",comment:["This tells the user how many items are shown in a list of items to select from. The items can be anything. Currently not visible, but read by screen readers."]},"{0} Results")}),tn=Ue.BC(Bt,ie(".quick-input-count"));tn.setAttribute("aria-live","polite");const En=new Ks.x(tn,{countFormat:(0,fi.kg)({key:"quickInput.countSelected",comment:["This tells the user how many items are selected in a list of items to select from. The items can be anything."]},"{0} Selected")}),fn=Ue.BC(_e,ie(".quick-input-action")),pn=new kr(fn);pn.label=(0,fi.kg)("ok","OK"),this._register(pn.onDidClick(Bi=>{this.onDidAcceptEmitter.fire()}));const Hi=Ue.BC(_e,ie(".quick-input-action")),ds=new kr(Hi);ds.label=(0,fi.kg)("custom","Custom"),this._register(ds.onDidClick(Bi=>{this.onDidCustomEmitter.fire()}));const fo=Ue.BC(qe,ie(`#${this.idPrefix}message.quick-input-message`)),kn=this._register(new e(t,this.idPrefix+"list",this.options));this._register(kn.onChangedAllVisibleChecked(Bi=>{De.checked=Bi})),this._register(kn.onChangedVisibleCount(Bi=>{ln.setCount(Bi)})),this._register(kn.onChangedCheckedCount(Bi=>{En.setCount(Bi)})),this._register(kn.onLeave(()=>{setTimeout(()=>{jt.setFocus(),this.controller instanceof me&&this.controller.canSelectMany&&kn.clearFocus()},0)})),this._register(kn.onDidChangeFocus(()=>{this.comboboxAccessibility&&this.getUI().inputBox.setAttribute("aria-activedescendant",this.getUI().list.getActiveDescendant()||"")}));const fr=new Po(t);fr.getContainer().classList.add("quick-input-progress");const nn=Ue.w5(t);return this._register(nn),this._register(Ue.ko(t,Ue.Bx.FOCUS,Bi=>{this.previousFocusElement=Bi.relatedTarget instanceof HTMLElement?Bi.relatedTarget:void 0},!0)),this._register(nn.onDidBlur(()=>{!this.getUI().ignoreFocusOut&&!this.options.ignoreFocusOut()&&this.hide(as.kF.Blur),this.previousFocusElement=void 0})),this._register(Ue.ko(t,Ue.Bx.FOCUS,Bi=>{jt.setFocus()})),this._register(Ue.ko(t,Ue.Bx.KEY_DOWN,Bi=>{const Vn=new sn.Z(Bi);switch(Vn.keyCode){case 3:Ue.fs.stop(Bi,!0),this.onDidAcceptEmitter.fire();break;case 9:Ue.fs.stop(Bi,!0),this.hide(as.kF.Gesture);break;case 2:if(!Vn.altKey&&!Vn.ctrlKey&&!Vn.metaKey){const Wo=[".action-label.codicon"];t.classList.contains("show-checkboxes")?Wo.push("input"):Wo.push("input[type=text]"),this.getUI().list.isDisplayed()&&Wo.push(".monaco-list");const Vo=t.querySelectorAll(Wo.join(", "));Vn.shiftKey&&Vn.target===Vo[0]?(Ue.fs.stop(Bi,!0),Vo[Vo.length-1].focus()):!Vn.shiftKey&&Vn.target===Vo[Vo.length-1]&&(Ue.fs.stop(Bi,!0),Vo[0].focus())}break}})),this.ui={container:t,styleSheet:s,leftActionBar:M,titleBar:f,title:V,description1:se,description2:Oe,rightActionBar:q,checkAll:De,filterContainer:Bt,inputBox:jt,visibleCountContainer:Mi,visibleCount:ln,countContainer:tn,count:En,okContainer:fn,ok:pn,message:fo,customButtonContainer:Hi,customButton:ds,list:kn,progressBar:fr,onDidAccept:this.onDidAcceptEmitter.event,onDidCustom:this.onDidCustomEmitter.event,onDidTriggerButton:this.onDidTriggerButtonEmitter.event,ignoreFocusOut:!1,keyMods:this.keyMods,isScreenReaderOptimized:()=>this.options.isScreenReaderOptimized(),show:Bi=>this.show(Bi),hide:()=>this.hide(),setVisibilities:Bi=>this.setVisibilities(Bi),setComboboxAccessibility:Bi=>this.setComboboxAccessibility(Bi),setEnabled:Bi=>this.setEnabled(Bi),setContextKey:Bi=>this.options.setContextKey(Bi)},this.updateStyles(),this.ui}pick(t,s={},f=Bs.X.None){return new Promise((M,V)=>{let q=Oe=>{var qe;q=M,(qe=s.onKeyMods)===null||qe===void 0||qe.call(s,se.keyMods),M(Oe)};if(f.isCancellationRequested){q(void 0);return}const se=this.createQuickPick();let _e;const De=[se,se.onDidAccept(()=>{if(se.canSelectMany)q(se.selectedItems.slice()),se.hide();else{const Oe=se.activeItems[0];Oe&&(q(Oe),se.hide())}}),se.onDidChangeActive(Oe=>{const qe=Oe[0];qe&&s.onDidFocus&&s.onDidFocus(qe)}),se.onDidChangeSelection(Oe=>{if(!se.canSelectMany){const qe=Oe[0];qe&&(q(qe),se.hide())}}),se.onDidTriggerItemButton(Oe=>s.onDidTriggerItemButton&&s.onDidTriggerItemButton(Object.assign(Object.assign({},Oe),{removeItem:()=>{const qe=se.items.indexOf(Oe.item);if(qe!==-1){const Bt=se.items.slice(),jt=Bt.splice(qe,1),Mi=se.activeItems.filter(tn=>tn!==jt[0]),ln=se.keepScrollPosition;se.keepScrollPosition=!0,se.items=Bt,Mi&&(se.activeItems=Mi),se.keepScrollPosition=ln}}}))),se.onDidChangeValue(Oe=>{_e&&!Oe&&(se.activeItems.length!==1||se.activeItems[0]!==_e)&&(se.activeItems=[_e])}),f.onCancellationRequested(()=>{se.hide()}),se.onDidHide(()=>{(0,K.AS)(De),q(void 0)})];se.title=s.title,se.canSelectMany=!!s.canPickMany,se.placeholder=s.placeHolder,se.ignoreFocusOut=!!s.ignoreFocusLost,se.matchOnDescription=!!s.matchOnDescription,se.matchOnDetail=!!s.matchOnDetail,se.matchOnLabel=s.matchOnLabel===void 0||s.matchOnLabel,se.autoFocusOnList=s.autoFocusOnList===void 0||s.autoFocusOnList,se.quickNavigate=s.quickNavigate,se.hideInput=!!s.hideInput,se.contextKey=s.contextKey,se.busy=!0,Promise.all([t,s.activeItem]).then(([Oe,qe])=>{_e=qe,se.busy=!1,se.items=Oe,se.canSelectMany&&(se.selectedItems=Oe.filter(Bt=>Bt.type!=="separator"&&Bt.picked)),_e&&(se.activeItems=[_e])}),se.show(),Promise.resolve(t).then(void 0,Oe=>{V(Oe),se.hide()})})}createQuickPick(){const t=this.getUI();return new me(t)}show(t){const s=this.getUI();this.onShowEmitter.fire();const f=this.controller;this.controller=t,f&&f.didHide(),this.setEnabled(!0),s.leftActionBar.clear(),s.title.textContent="",s.description1.textContent="",s.description2.textContent="",s.rightActionBar.clear(),s.checkAll.checked=!1,s.inputBox.placeholder="",s.inputBox.password=!1,s.inputBox.showDecoration(Pi.A.Ignore),s.visibleCount.setCount(0),s.count.setCount(0),Ue.Ln(s.message),s.progressBar.stop(),s.list.setElements([]),s.list.matchOnDescription=!1,s.list.matchOnDetail=!1,s.list.matchOnLabel=!0,s.list.sortByLabel=!0,s.ignoreFocusOut=!1,this.setComboboxAccessibility(!1),s.inputBox.ariaLabel="";const M=this.options.backKeybindingLabel();re.tooltip=M?(0,fi.kg)("quickInput.backWithKeybinding","Back ({0})",M):(0,fi.kg)("quickInput.back","Back"),s.container.style.display="",this.updateLayout(),s.inputBox.setFocus()}setVisibilities(t){const s=this.getUI();s.title.style.display=t.title?"":"none",s.description1.style.display=t.description&&(t.inputBox||t.checkAll)?"":"none",s.description2.style.display=t.description&&!(t.inputBox||t.checkAll)?"":"none",s.checkAll.style.display=t.checkAll?"":"none",s.filterContainer.style.display=t.inputBox?"":"none",s.visibleCountContainer.style.display=t.visibleCount?"":"none",s.countContainer.style.display=t.count?"":"none",s.okContainer.style.display=t.ok?"":"none",s.customButtonContainer.style.display=t.customButton?"":"none",s.message.style.display=t.message?"":"none",s.progressBar.getContainer().style.display=t.progressBar?"":"none",s.list.display(!!t.list),s.container.classList[t.checkBox?"add":"remove"]("show-checkboxes"),this.updateLayout()}setComboboxAccessibility(t){if(t!==this.comboboxAccessibility){const s=this.getUI();this.comboboxAccessibility=t,this.comboboxAccessibility?(s.inputBox.setAttribute("role","combobox"),s.inputBox.setAttribute("aria-haspopup","true"),s.inputBox.setAttribute("aria-autocomplete","list"),s.inputBox.setAttribute("aria-activedescendant",s.list.getActiveDescendant()||"")):(s.inputBox.removeAttribute("role"),s.inputBox.removeAttribute("aria-haspopup"),s.inputBox.removeAttribute("aria-autocomplete"),s.inputBox.removeAttribute("aria-activedescendant"))}}setEnabled(t){if(t!==this.enabled){this.enabled=t;for(const s of this.getUI().leftActionBar.viewItems)s.getAction().enabled=t;for(const s of this.getUI().rightActionBar.viewItems)s.getAction().enabled=t;this.getUI().checkAll.disabled=!t,this.getUI().ok.enabled=t,this.getUI().list.enabled=t}}hide(t){var s;const f=this.controller;if(f){const M=!(!((s=this.ui)===null||s===void 0)&&s.container.contains(document.activeElement));if(this.controller=null,this.onHideEmitter.fire(),this.getUI().container.style.display="none",!M){let V=this.previousFocusElement;for(;V&&!V.offsetParent;)V=(0,k.UH)(V.parentElement);V?.offsetParent?(V.focus(),this.previousFocusElement=void 0):this.options.returnFocus()}f.didHide(t)}}layout(t,s){this.dimension=t,this.titleBarOffset=s,this.updateLayout()}updateLayout(){if(this.ui){this.ui.container.style.top=`${this.titleBarOffset}px`;const t=this.ui.container.style,s=Math.min(this.dimension.width*.62,we.MAX_WIDTH);t.width=s+"px",t.marginLeft="-"+s/2+"px",this.ui.inputBox.layout(),this.ui.list.layout(this.dimension&&this.dimension.height*.4)}}applyStyles(t){this.styles=t,this.updateStyles()}updateStyles(){if(this.ui){const{quickInputTitleBackground:t,quickInputBackground:s,quickInputForeground:f,contrastBorder:M,widgetShadow:V}=this.styles.widget;this.ui.titleBar.style.backgroundColor=t?t.toString():"",this.ui.container.style.backgroundColor=s?s.toString():"",this.ui.container.style.color=f?f.toString():"",this.ui.container.style.border=M?`1px solid ${M}`:"",this.ui.container.style.boxShadow=V?`0 0 8px 2px ${V}`:"",this.ui.inputBox.style(this.styles.inputBox),this.ui.count.style(this.styles.countBadge),this.ui.ok.style(this.styles.button),this.ui.customButton.style(this.styles.button),this.ui.progressBar.style(this.styles.progressBar),this.ui.list.style(this.styles.list);const q=[];this.styles.list.pickerGroupBorder&&q.push(`.quick-input-list .quick-input-list-entry { border-top-color: ${this.styles.list.pickerGroupBorder}; }`),this.styles.list.pickerGroupForeground&&q.push(`.quick-input-list .quick-input-list-separator { color: ${this.styles.list.pickerGroupForeground}; }`),(this.styles.keybindingLabel.keybindingLabelBackground||this.styles.keybindingLabel.keybindingLabelBorder||this.styles.keybindingLabel.keybindingLabelBottomBorder||this.styles.keybindingLabel.keybindingLabelShadow||this.styles.keybindingLabel.keybindingLabelForeground)&&(q.push(".quick-input-list .monaco-keybinding > .monaco-keybinding-key {"),this.styles.keybindingLabel.keybindingLabelBackground&&q.push(`background-color: ${this.styles.keybindingLabel.keybindingLabelBackground};`),this.styles.keybindingLabel.keybindingLabelBorder&&q.push(`border-color: ${this.styles.keybindingLabel.keybindingLabelBorder};`),this.styles.keybindingLabel.keybindingLabelBottomBorder&&q.push(`border-bottom-color: ${this.styles.keybindingLabel.keybindingLabelBottomBorder};`),this.styles.keybindingLabel.keybindingLabelShadow&&q.push(`box-shadow: inset 0 -1px 0 ${this.styles.keybindingLabel.keybindingLabelShadow};`),this.styles.keybindingLabel.keybindingLabelForeground&&q.push(`color: ${this.styles.keybindingLabel.keybindingLabelForeground};`),q.push("}"));const se=q.join(` `);se!==this.ui.styleSheet.textContent&&(this.ui.styleSheet.textContent=se)}}}we.MAX_WIDTH=600;var Be=y(4169),Re=y(48289),Je=y(19381),st=y(73027),ct=function(ee,t,s,f){var M=arguments.length,V=M<3?t:f===null?f=Object.getOwnPropertyDescriptor(t,s):f,q;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")V=Reflect.decorate(ee,t,s,f);else for(var se=ee.length-1;se>=0;se--)(q=ee[se])&&(V=(M<3?q(V):M>3?q(t,s,V):q(t,s))||V);return M>3&&V&&Object.defineProperty(t,s,V),V},mt=function(ee,t){return function(s,f){t(s,f,ee)}};let xt=class extends K.jG{constructor(t,s){super(),this.quickInputService=t,this.instantiationService=s,this.registry=Os.O.as(Je.Fd.Quickaccess),this.mapProviderToDescriptor=new Map,this.lastAcceptedPickerValues=new Map,this.visibleQuickAccess=void 0}show(t="",s){this.doShowOrPick(t,!1,s)}doShowOrPick(t,s,f){var M;const[V,q]=this.getOrInstantiateProvider(t),se=this.visibleQuickAccess,_e=se?.descriptor;if(se&&q&&_e===q){t!==q.prefix&&!f?.preserveValue&&(se.picker.value=t),this.adjustValueSelection(se.picker,q,f);return}if(q&&!f?.preserveValue){let jt;if(se&&_e&&_e!==q){const Mi=se.value.substr(_e.prefix.length);Mi&&(jt=`${q.prefix}${Mi}`)}if(!jt){const Mi=V?.defaultFilterValue;Mi===Je.aJ.LAST?jt=this.lastAcceptedPickerValues.get(q):typeof Mi=="string"&&(jt=`${q.prefix}${Mi}`)}typeof jt=="string"&&(t=jt)}const De=new K.Cm,Oe=De.add(this.quickInputService.createQuickPick());Oe.value=t,this.adjustValueSelection(Oe,q,f),Oe.placeholder=q?.placeholder,Oe.quickNavigate=f?.quickNavigateConfiguration,Oe.hideInput=!!Oe.quickNavigate&&!se,(typeof f?.itemActivation=="number"||f?.quickNavigateConfiguration)&&(Oe.itemActivation=(M=f?.itemActivation)!==null&&M!==void 0?M:st.C1.SECOND),Oe.contextKey=q?.contextKey,Oe.filterValue=jt=>jt.substring(q?q.prefix.length:0),q?.placeholder&&(Oe.ariaLabel=q?.placeholder);let qe;s&&(qe=new w.Zv,De.add((0,Re.O)(Oe.onWillAccept)(jt=>{jt.veto(),Oe.hide()}))),De.add(this.registerPickerListeners(Oe,V,q,t));const Bt=De.add(new Bs.Q);if(V&&De.add(V.provide(Oe,Bt.token)),(0,Re.O)(Oe.onDidHide)(()=>{Oe.selectedItems.length===0&&Bt.cancel(),De.dispose(),qe?.complete(Oe.selectedItems.slice(0))}),Oe.show(),s)return qe?.p}adjustValueSelection(t,s,f){var M;let V;f?.preserveValue?V=[t.value.length,t.value.length]:V=[(M=s?.prefix.length)!==null&&M!==void 0?M:0,t.value.length],t.valueSelection=V}registerPickerListeners(t,s,f,M){const V=new K.Cm,q=this.visibleQuickAccess={picker:t,descriptor:f,value:M};return V.add((0,K.s)(()=>{q===this.visibleQuickAccess&&(this.visibleQuickAccess=void 0)})),V.add(t.onDidChangeValue(se=>{const[_e]=this.getOrInstantiateProvider(se);_e!==s?this.show(se,{preserveValue:!0}):q.value=se})),f&&V.add(t.onDidAccept(()=>{this.lastAcceptedPickerValues.set(f,t.value)})),V}getOrInstantiateProvider(t){const s=this.registry.getQuickAccessProvider(t);if(!s)return[void 0,void 0];let f=this.mapProviderToDescriptor.get(s);return f||(f=this.instantiationService.createInstance(s.ctor),this.mapProviderToDescriptor.set(s,f)),[f,s]}};xt=ct([mt(0,st.GK),mt(1,wi._Y)],xt);var Dt=function(ee,t,s,f){var M=arguments.length,V=M<3?t:f===null?f=Object.getOwnPropertyDescriptor(t,s):f,q;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")V=Reflect.decorate(ee,t,s,f);else for(var se=ee.length-1;se>=0;se--)(q=ee[se])&&(V=(M<3?q(V):M>3?q(t,s,V):q(t,s))||V);return M>3&&V&&Object.defineProperty(t,s,V),V},Jt=function(ee,t){return function(s,f){t(s,f,ee)}};let $t=class extends oi.lR{constructor(t,s,f,M,V){super(f),this.instantiationService=t,this.contextKeyService=s,this.accessibilityService=M,this.layoutService=V,this.contexts=new Map}get controller(){return this._controller||(this._controller=this._register(this.createController())),this._controller}get quickAccess(){return this._quickAccess||(this._quickAccess=this._register(this.instantiationService.createInstance(xt))),this._quickAccess}createController(t=this.layoutService,s){const f={idPrefix:"quickInput_",container:t.container,ignoreFocusOut:()=>!1,isScreenReaderOptimized:()=>this.accessibilityService.isScreenReaderOptimized(),backKeybindingLabel:()=>{},setContextKey:V=>this.setContextKey(V),returnFocus:()=>t.focus(),createList:(V,q,se,_e,De)=>this.instantiationService.createInstance(Be.Ei,V,q,se,_e,De),styles:this.computeStyles()},M=this._register(new we(Object.assign(Object.assign({},f),s)));return M.layout(t.dimension,t.offset.quickPickTop),this._register(t.onDidLayout(V=>M.layout(V,t.offset.quickPickTop))),this._register(M.onShow(()=>this.resetContextKeys())),this._register(M.onHide(()=>this.resetContextKeys())),M}setContextKey(t){let s;t&&(s=this.contexts.get(t),s||(s=new Tt.N1(t,!1).bindTo(this.contextKeyService),this.contexts.set(t,s))),!(s&&s.get())&&(this.resetContextKeys(),s?.set(!0))}resetContextKeys(){this.contexts.forEach(t=>{t.get()&&t.reset()})}pick(t,s={},f=Bs.X.None){return this.controller.pick(t,s,f)}createQuickPick(){return this.controller.createQuickPick()}updateStyles(){this.controller.applyStyles(this.computeStyles())}computeStyles(){return{widget:Object.assign({},(0,Ds.KC)(this.theme,{quickInputBackground:ji.ELA,quickInputForeground:ji.HJZ,quickInputTitleBackground:ji.er1,contrastBorder:ji.b1q,widgetShadow:ji.f9l})),inputBox:(0,Ds.KC)(this.theme,{inputForeground:ji.cws,inputBackground:ji.L4c,inputBorder:ji.Zgs,inputValidationInfoBackground:ji.I$A,inputValidationInfoForeground:ji.L9Z,inputValidationInfoBorder:ji.YSW,inputValidationWarningBackground:ji.ULt,inputValidationWarningForeground:ji.T5N,inputValidationWarningBorder:ji.C1n,inputValidationErrorBackground:ji._$n,inputValidationErrorForeground:ji.h9z,inputValidationErrorBorder:ji.eYZ}),countBadge:(0,Ds.KC)(this.theme,{badgeBackground:ji.WMx,badgeForeground:ji.zRE,badgeBorder:ji.b1q}),button:(0,Ds.KC)(this.theme,{buttonForeground:ji.G_h,buttonBackground:ji.XJc,buttonHoverBackground:ji.T9h,buttonBorder:ji.b1q}),progressBar:(0,Ds.KC)(this.theme,{progressBarBackground:ji.BTi}),keybindingLabel:(0,Ds.KC)(this.theme,{keybindingLabelBackground:ji.HDX,keybindingLabelForeground:ji.eUu,keybindingLabelBorder:ji.zUX,keybindingLabelBottomBorder:ji.Qfh,keybindingLabelShadow:ji.f9l}),list:(0,Ds.KC)(this.theme,{listBackground:ji.ELA,listInactiveFocusForeground:ji.nH,listInactiveSelectionIconForeground:ji.c7i,listInactiveFocusBackground:ji.AlL,listFocusOutline:ji.buw,listInactiveFocusOutline:ji.buw,pickerGroupBorder:ji.iwL,pickerGroupForeground:ji.NBf})}}};$t=Dt([Jt(0,wi._Y),Jt(1,Tt.fN),Jt(2,oi.Gy),Jt(3,js.j),Jt(4,Qi)],$t);var ai=function(ee,t,s,f){var M=arguments.length,V=M<3?t:f===null?f=Object.getOwnPropertyDescriptor(t,s):f,q;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")V=Reflect.decorate(ee,t,s,f);else for(var se=ee.length-1;se>=0;se--)(q=ee[se])&&(V=(M<3?q(V):M>3?q(t,s,V):q(t,s))||V);return M>3&&V&&Object.defineProperty(t,s,V),V},ii=function(ee,t){return function(s,f){t(s,f,ee)}};let Zt=class extends $t{constructor(t,s,f,M,V,q){super(s,f,M,V,new qi(t.getContainerDomNode(),q)),this.host=void 0;const se=Ai.get(t);if(se){const _e=se.widget;this.host={_serviceBrand:void 0,get hasContainer(){return!0},get container(){return _e.getDomNode()},get dimension(){return t.getLayoutInfo()},get onDidLayout(){return t.onDidLayoutChange},focus:()=>t.focus(),offset:{top:0,quickPickTop:0}}}else this.host=void 0}createController(){return super.createController(this.host)}};Zt=ai([ii(1,wi._Y),ii(2,Tt.fN),ii(3,oi.Gy),ii(4,js.j),ii(5,U.T)],Zt);let di=class{constructor(t,s){this.instantiationService=t,this.codeEditorService=s,this.mapEditorToService=new Map}get activeService(){const t=this.codeEditorService.getFocusedCodeEditor();if(!t)throw new Error("Quick input service needs a focused editor to work.");let s=this.mapEditorToService.get(t);if(!s){const f=s=this.instantiationService.createInstance(Zt,t);this.mapEditorToService.set(t,s),(0,Re.O)(t.onDidDispose)(()=>{f.dispose(),this.mapEditorToService.delete(t)})}return s}get quickAccess(){return this.activeService.quickAccess}pick(t,s={},f=Bs.X.None){return this.activeService.pick(t,s,f)}createQuickPick(){return this.activeService.createQuickPick()}};di=ai([ii(0,wi._Y),ii(1,U.T)],di);class Ai{constructor(t){this.editor=t,this.widget=new gi(this.editor)}static get(t){return t.getContribution(Ai.ID)}dispose(){this.widget.dispose()}}Ai.ID="editor.controller.quickInput";class gi{constructor(t){this.codeEditor=t,this.domNode=document.createElement("div"),this.codeEditor.addOverlayWidget(this)}getId(){return gi.ID}getDomNode(){return this.domNode}getPosition(){return{preference:2}}dispose(){this.codeEditor.removeOverlayWidget(this)}}gi.ID="editor.contrib.quickInputWidget",(0,Io.HW)(Ai.ID,Ai);var un=y(93582),Ki=y(83616),Pn=function(ee,t,s,f){var M=arguments.length,V=M<3?t:f===null?f=Object.getOwnPropertyDescriptor(t,s):f,q;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")V=Reflect.decorate(ee,t,s,f);else for(var se=ee.length-1;se>=0;se--)(q=ee[se])&&(V=(M<3?q(V):M>3?q(t,s,V):q(t,s))||V);return M>3&&V&&Object.defineProperty(t,s,V),V},$i=function(ee,t){return function(s,f){t(s,f,ee)}};let Dn=class extends K.jG{constructor(t,s,f){super(),this._contextKeyService=t,this._layoutService=s,this._configurationService=f,this._accessibilitySupport=0,this._onDidChangeScreenReaderOptimized=new m.vl,this._onDidChangeReducedMotion=new m.vl,this._accessibilityModeEnabledContext=js.f.bindTo(this._contextKeyService);const M=()=>this._accessibilityModeEnabledContext.set(this.isScreenReaderOptimized());this._register(this._configurationService.onDidChangeConfiguration(q=>{q.affectsConfiguration("editor.accessibilitySupport")&&(M(),this._onDidChangeScreenReaderOptimized.fire()),q.affectsConfiguration("workbench.reduceMotion")&&(this._configMotionReduced=this._configurationService.getValue("workbench.reduceMotion"),this._onDidChangeReducedMotion.fire())})),M(),this._register(this.onDidChangeScreenReaderOptimized(()=>M()));const V=window.matchMedia("(prefers-reduced-motion: reduce)");this._systemMotionReduced=V.matches,this._configMotionReduced=this._configurationService.getValue("workbench.reduceMotion"),this.initReducedMotionListeners(V)}initReducedMotionListeners(t){if(!this._layoutService.hasContainer)return;this._register((0,Ue.ko)(t,"change",()=>{this._systemMotionReduced=t.matches,this._configMotionReduced==="auto"&&this._onDidChangeReducedMotion.fire()}));const s=()=>{const f=this.isMotionReduced();this._layoutService.container.classList.toggle("reduce-motion",f),this._layoutService.container.classList.toggle("enable-motion",!f)};s(),this._register(this.onDidChangeReducedMotion(()=>s()))}get onDidChangeScreenReaderOptimized(){return this._onDidChangeScreenReaderOptimized.event}isScreenReaderOptimized(){const t=this._configurationService.getValue("editor.accessibilitySupport");return t==="on"||t==="auto"&&this._accessibilitySupport===2}get onDidChangeReducedMotion(){return this._onDidChangeReducedMotion.event}isMotionReduced(){const t=this._configMotionReduced;return t==="on"||t==="auto"&&this._systemMotionReduced}getAccessibilitySupport(){return this._accessibilitySupport}};Dn=Pn([$i(0,Tt.fN),$i(1,Qi),$i(2,si.pG)],Dn);var Xi=y(58067),bn=y(90840),ts=function(ee,t,s,f){var M=arguments.length,V=M<3?t:f===null?f=Object.getOwnPropertyDescriptor(t,s):f,q;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")V=Reflect.decorate(ee,t,s,f);else for(var se=ee.length-1;se>=0;se--)(q=ee[se])&&(V=(M<3?q(V):M>3?q(t,s,V):q(t,s))||V);return M>3&&V&&Object.defineProperty(t,s,V),V},Ao=function(ee,t){return function(s,f){t(s,f,ee)}};let Xr=class{constructor(t,s){this._commandService=t,this._hiddenStates=new Tr(s)}createMenu(t,s,f){return new Jr(t,this._hiddenStates,Object.assign({emitEventsForSubmenuChanges:!1,eventDebounceDelay:50},f),this._commandService,s,this)}};Xr=ts([Ao(0,Qt.wT),Ao(1,bn.CS)],Xr);let Tr=class pr{constructor(t){this._storageService=t,this._disposables=new K.Cm,this._onDidChange=new m.vl,this.onDidChange=this._onDidChange.event,this._ignoreChangeEvent=!1;try{const s=t.get(pr._key,0,"{}");this._data=JSON.parse(s)}catch{this._data=Object.create(null)}this._disposables.add(t.onDidChangeValue(s=>{if(s.key===pr._key){if(!this._ignoreChangeEvent)try{const f=t.get(pr._key,0,"{}");this._data=JSON.parse(f)}catch(f){console.log("FAILED to read storage after UPDATE",f)}this._onDidChange.fire()}}))}dispose(){this._onDidChange.dispose(),this._disposables.dispose()}isHidden(t,s){var f,M;return(M=(f=this._data[t.id])===null||f===void 0?void 0:f.includes(s))!==null&&M!==void 0?M:!1}updateHidden(t,s,f){const M=this._data[t.id];if(f)M?M.indexOf(s)<0&&M.push(s):this._data[t.id]=[s];else if(M){const V=M.indexOf(s);V>=0&&(0,pe.UH)(M,V),M.length===0&&delete this._data[t.id]}this._persist()}_persist(){try{this._ignoreChangeEvent=!0;const t=JSON.stringify(this._data);this._storageService.store(pr._key,t,0,0)}finally{this._ignoreChangeEvent=!1}}};Tr._key="menu.hiddenCommands",Tr=ts([Ao(0,bn.CS)],Tr);let Jr=class zo{constructor(t,s,f,M,V,q){this._id=t,this._hiddenStates=s,this._options=f,this._commandService=M,this._contextKeyService=V,this._menuService=q,this._disposables=new K.Cm,this._menuGroups=[],this._contextKeys=new Set,this._build();const se=new w.uC(()=>{this._build(),this._onDidChange.fire(this)},f.eventDebounceDelay);this._disposables.add(se),this._disposables.add(Xi.ZG.onDidChangeMenu(Oe=>{Oe.has(t)&&se.schedule()}));const _e=this._disposables.add(new K.Cm),De=()=>{const Oe=new w.uC(()=>this._onDidChange.fire(this),f.eventDebounceDelay);_e.add(Oe),_e.add(V.onDidChangeContext(qe=>{qe.affectsSome(this._contextKeys)&&Oe.schedule()})),_e.add(s.onDidChange(()=>{Oe.schedule()}))};this._onDidChange=new m.vl({onFirstListenerAdd:De,onLastListenerRemove:_e.clear.bind(_e)}),this.onDidChange=this._onDidChange.event}dispose(){this._disposables.dispose(),this._onDidChange.dispose()}_build(){this._menuGroups.length=0,this._contextKeys.clear();const t=Xi.ZG.getMenuItems(this._id);let s;t.sort(zo._compareMenuItems);for(const f of t){const M=f.group||"";(!s||s[0]!==M)&&(s=[M,[]],this._menuGroups.push(s)),s[1].push(f),this._collectContextKeys(f)}}_collectContextKeys(t){if(zo._fillInKbExprKeys(t.when,this._contextKeys),(0,Xi.is)(t)){if(t.command.precondition&&zo._fillInKbExprKeys(t.command.precondition,this._contextKeys),t.command.toggled){const s=t.command.toggled.condition||t.command.toggled;zo._fillInKbExprKeys(s,this._contextKeys)}}else this._options.emitEventsForSubmenuChanges&&Xi.ZG.getMenuItems(t.submenu).forEach(this._collectContextKeys,this)}getActions(t){const s=[],f=[];for(const M of this._menuGroups){const[V,q]=M,se=[],_e=[];for(const De of q)if(this._contextKeyService.contextMatchesRules(De.when)){let Oe;if((0,Xi.is)(De)){const Bt=ja(this._id,De.command,this._hiddenStates);Oe=new Xi.Xe(De.command,De.alt,t,Bt,this._contextKeyService,this._commandService)}else Oe=new Xi.nI(De,this._menuService,this._contextKeyService,t),Oe.actions.length===0&&(Oe.dispose(),Oe=void 0);Oe&&_e.push(Oe)}_e.length>0&&s.push([V,_e]),se.length>0&&f.push(se)}return s}static _fillInKbExprKeys(t,s){if(t)for(const f of t.keys())s.add(f)}static _compareMenuItems(t,s){const f=t.group,M=s.group;if(f!==M){if(f){if(!M)return-1}else return 1;if(f==="navigation")return-1;if(M==="navigation")return 1;const se=f.localeCompare(M);if(se!==0)return se}const V=t.order||0,q=s.order||0;return V<q?-1:V>q?1:zo._compareTitles((0,Xi.is)(t)?t.command.title:t.title,(0,Xi.is)(s)?s.command.title:s.title)}static _compareTitles(t,s){const f=typeof t=="string"?t:t.original,M=typeof s=="string"?s:s.original;return f.localeCompare(M)}};Jr=ts([Ao(3,Qt.wT),Ao(4,Tt.fN),Ao(5,Xi.ez)],Jr);function ja(ee,t,s){const f=`${ee.id}/${t.id}`,M=typeof t.title=="string"?t.title:t.title.value,V=(0,ms.ih)({id:f,label:(0,fi.kg)("hide.label","Hide '{0}'",M),run(){s.updateHidden(ee,t.id,!0)}}),q=(0,ms.ih)({id:f,label:M,get checked(){return!s.isHidden(ee,t.id)},run(){const se=!s.isHidden(ee,t.id);s.updateHidden(ee,t.id,se)}});return{hide:V,toggle:q,get isHidden(){return!q.checked}}}var Ka=function(ee,t,s,f){var M=arguments.length,V=M<3?t:f===null?f=Object.getOwnPropertyDescriptor(t,s):f,q;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")V=Reflect.decorate(ee,t,s,f);else for(var se=ee.length-1;se>=0;se--)(q=ee[se])&&(V=(M<3?q(V):M>3?q(t,s,V):q(t,s))||V);return M>3&&V&&Object.defineProperty(t,s,V),V},Ca=function(ee,t){return function(s,f){t(s,f,ee)}},Ro=function(ee,t,s,f){function M(V){return V instanceof s?V:new s(function(q){q(V)})}return new(s||(s=Promise))(function(V,q){function se(Oe){try{De(f.next(Oe))}catch(qe){q(qe)}}function _e(Oe){try{De(f.throw(Oe))}catch(qe){q(qe)}}function De(Oe){Oe.done?V(Oe.value):M(Oe.value).then(se,_e)}De((f=f.apply(ee,t||[])).next())})};let qr=class extends K.jG{constructor(t,s){super(),this.layoutService=t,this.logService=s,this.mapTextToType=new Map,this.findText="",this.resources=[],(Wn.isSafari||Wn.isWebkitWebView)&&this.installWebKitWriteTextWorkaround()}installWebKitWriteTextWorkaround(){const t=()=>{const s=new w.Zv;this.webKitPendingClipboardWritePromise&&!this.webKitPendingClipboardWritePromise.isSettled&&this.webKitPendingClipboardWritePromise.cancel(),this.webKitPendingClipboardWritePromise=s,navigator.clipboard.write([new ClipboardItem({"text/plain":s.p})]).catch(f=>Ro(this,void 0,void 0,function*(){(!(f instanceof Error)||f.name!=="NotAllowedError"||!s.isRejected)&&this.logService.error(f)}))};this.layoutService.hasContainer&&(this._register((0,Ue.ko)(this.layoutService.container,"click",t)),this._register((0,Ue.ko)(this.layoutService.container,"keydown",t)))}writeText(t,s){return Ro(this,void 0,void 0,function*(){if(s){this.mapTextToType.set(s,t);return}if(this.webKitPendingClipboardWritePromise)return this.webKitPendingClipboardWritePromise.complete(t);try{return yield navigator.clipboard.writeText(t)}catch(V){console.error(V)}const f=document.activeElement,M=document.body.appendChild((0,Ue.$)("textarea",{"aria-hidden":!0}));M.style.height="1px",M.style.width="1px",M.style.position="absolute",M.value=t,M.focus(),M.select(),document.execCommand("copy"),f instanceof HTMLElement&&f.focus(),document.body.removeChild(M)})}readText(t){return Ro(this,void 0,void 0,function*(){if(t)return this.mapTextToType.get(t)||"";try{return yield navigator.clipboard.readText()}catch(s){return console.error(s),""}})}readFindText(){return Ro(this,void 0,void 0,function*(){return this.findText})}writeFindText(t){return Ro(this,void 0,void 0,function*(){this.findText=t})}readResources(){return Ro(this,void 0,void 0,function*(){return this.resources})}};qr=Ka([Ca(0,Qi),Ca(1,be.rr)],qr);var ba=y(3338),uo=y(17954),$a=function(ee,t,s,f){var M=arguments.length,V=M<3?t:f===null?f=Object.getOwnPropertyDescriptor(t,s):f,q;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")V=Reflect.decorate(ee,t,s,f);else for(var se=ee.length-1;se>=0;se--)(q=ee[se])&&(V=(M<3?q(V):M>3?q(t,s,V):q(t,s))||V);return M>3&&V&&Object.defineProperty(t,s,V),V},Ga=function(ee,t){return function(s,f){t(s,f,ee)}};const cr="data-keybinding-context";class ea{constructor(t,s){this._id=t,this._parent=s,this._value=Object.create(null),this._value._contextId=t}get value(){return Object.assign({},this._value)}setValue(t,s){return this._value[t]!==s?(this._value[t]=s,!0):!1}removeValue(t){return t in this._value?(delete this._value[t],!0):!1}getValue(t){const s=this._value[t];return typeof s>"u"&&this._parent?this._parent.getValue(t):s}}class Bo extends ea{constructor(){super(-1,null)}setValue(t,s){return!1}removeValue(t){return!1}getValue(t){}}Bo.INSTANCE=new Bo;class dr extends ea{constructor(t,s,f){super(t,null),this._configurationService=s,this._values=Di.cB.forConfigKeys(),this._listener=this._configurationService.onDidChangeConfiguration(M=>{if(M.source===7){const V=Array.from(uo.f.map(this._values,([q])=>q));this._values.clear(),f.fire(new ya(V))}else{const V=[];for(const q of M.affectedKeys){const se=`config.${q}`,_e=this._values.findSuperstr(se);_e!==void 0&&(V.push(...uo.f.map(_e,([De])=>De)),this._values.deleteSuperstr(se)),this._values.has(se)&&(V.push(se),this._values.delete(se))}f.fire(new ya(V))}})}dispose(){this._listener.dispose()}getValue(t){if(t.indexOf(dr._keyPrefix)!==0)return super.getValue(t);if(this._values.has(t))return this._values.get(t);const s=t.substr(dr._keyPrefix.length),f=this._configurationService.getValue(s);let M;switch(typeof f){case"number":case"boolean":case"string":M=f;break;default:Array.isArray(f)?M=JSON.stringify(f):M=f}return this._values.set(t,M),M}setValue(t,s){return super.setValue(t,s)}removeValue(t){return super.removeValue(t)}}dr._keyPrefix="config.";class Qa{constructor(t,s,f){this._service=t,this._key=s,this._defaultValue=f,this.reset()}set(t){this._service.setContext(this._key,t)}reset(){typeof this._defaultValue>"u"?this._service.removeContext(this._key):this._service.setContext(this._key,this._defaultValue)}get(){return this._service.getContextKeyValue(this._key)}}class wa{constructor(t){this.key=t}affectsSome(t){return t.has(this.key)}allKeysContainedIn(t){return this.affectsSome(t)}}class ya{constructor(t){this.keys=t}affectsSome(t){for(const s of this.keys)if(t.has(s))return!0;return!1}allKeysContainedIn(t){return this.keys.every(s=>t.has(s))}}class Za{constructor(t){this.events=t}affectsSome(t){for(const s of this.events)if(s.affectsSome(t))return!0;return!1}allKeysContainedIn(t){return this.events.every(s=>s.allKeysContainedIn(t))}}function Ya(ee,t){return ee.allKeysContainedIn(new Set(Object.keys(t)))}class Sa{constructor(t){this._onDidChangeContext=new m.fV({merge:s=>new Za(s)}),this.onDidChangeContext=this._onDidChangeContext.event,this._isDisposed=!1,this._myContextId=t}createKey(t,s){if(this._isDisposed)throw new Error("AbstractContextKeyService has been disposed");return new Qa(this,t,s)}bufferChangeEvents(t){this._onDidChangeContext.pause();try{t()}finally{this._onDidChangeContext.resume()}}createScoped(t){if(this._isDisposed)throw new Error("AbstractContextKeyService has been disposed");return new Xa(this,t)}contextMatchesRules(t){if(this._isDisposed)throw new Error("AbstractContextKeyService has been disposed");const s=this.getContextValuesContainer(this._myContextId);return t?t.evaluate(s):!0}getContextKeyValue(t){if(!this._isDisposed)return this.getContextValuesContainer(this._myContextId).getValue(t)}setContext(t,s){if(this._isDisposed)return;const f=this.getContextValuesContainer(this._myContextId);f&&f.setValue(t,s)&&this._onDidChangeContext.fire(new wa(t))}removeContext(t){this._isDisposed||this.getContextValuesContainer(this._myContextId).removeValue(t)&&this._onDidChangeContext.fire(new wa(t))}getContext(t){return this._isDisposed?Bo.INSTANCE:this.getContextValuesContainer(Ja(t))}}let ta=class extends Sa{constructor(t){super(0),this._contexts=new Map,this._toDispose=new K.Cm,this._lastContextId=0;const s=new dr(this._myContextId,t,this._onDidChangeContext);this._contexts.set(this._myContextId,s),this._toDispose.add(s)}dispose(){this._onDidChangeContext.dispose(),this._isDisposed=!0,this._toDispose.dispose()}getContextValuesContainer(t){return this._isDisposed?Bo.INSTANCE:this._contexts.get(t)||Bo.INSTANCE}createChildContext(t=this._myContextId){if(this._isDisposed)throw new Error("ContextKeyService has been disposed");const s=++this._lastContextId;return this._contexts.set(s,new ea(s,this.getContextValuesContainer(t))),s}disposeContext(t){this._isDisposed||this._contexts.delete(t)}};ta=$a([Ga(0,si.pG)],ta);class Xa extends Sa{constructor(t,s){if(super(t.createChildContext()),this._parentChangeListener=new K.HE,this._parent=t,this._updateParentChangeListener(),this._domNode=s,this._domNode.hasAttribute(cr)){let f="";this._domNode.classList&&(f=Array.from(this._domNode.classList.values()).join(", ")),console.error(`Element already has context attribute${f?": "+f:""}`)}this._domNode.setAttribute(cr,String(this._myContextId))}_updateParentChangeListener(){this._parentChangeListener.value=this._parent.onDidChangeContext(t=>{const f=this._parent.getContextValuesContainer(this._myContextId).value;Ya(t,f)||this._onDidChangeContext.fire(t)})}dispose(){this._isDisposed||(this._onDidChangeContext.dispose(),this._parent.disposeContext(this._myContextId),this._parentChangeListener.dispose(),this._domNode.removeAttribute(cr),this._isDisposed=!0)}getContextValuesContainer(t){return this._isDisposed?Bo.INSTANCE:this._parent.getContextValuesContainer(t)}createChildContext(t=this._myContextId){if(this._isDisposed)throw new Error("ScopedContextKeyService has been disposed");return this._parent.createChildContext(t)}disposeContext(t){this._isDisposed||this._parent.disposeContext(t)}}function Ja(ee){for(;ee;){if(ee.hasAttribute(cr)){const t=ee.getAttribute(cr);return t?parseInt(t,10):NaN}ee=ee.parentElement}return 0}function qa(ee,t,s){ee.get(Tt.fN).createKey(String(t),el(s))}function el(ee){return(0,Ui.PI)(ee,t=>{if(typeof t=="object"&&t.$mid===1)return Gi.r.revive(t).toString();if(t instanceof Gi.r)return t.toString()})}Qt.wb.registerCommand(Tt.Ho,qa),Qt.wb.registerCommand({id:"getContextKeyInfo",handler(){return[...Tt.N1.all()].sort((ee,t)=>ee.key.localeCompare(t.key))},description:{description:(0,fi.kg)("getContextKeyInfo","A command that returns information about context keys"),args:[]}}),Qt.wb.registerCommand("_generateContextKeyInfo",function(){const ee=[],t=new Set;for(const s of Tt.N1.all())t.has(s.key)||(t.add(s.key),ee.push(s));ee.sort((s,f)=>s.key.localeCompare(f.key)),console.log(JSON.stringify(ee,void 0,2))});var $s=y(83312);class tl{constructor(t){this.incoming=new Map,this.outgoing=new Map,this.data=t}}class il{constructor(t){this._hashFn=t,this._nodes=new Map}roots(){const t=[];for(const s of this._nodes.values())s.outgoing.size===0&&t.push(s);return t}insertEdge(t,s){const f=this.lookupOrInsertNode(t),M=this.lookupOrInsertNode(s);f.outgoing.set(this._hashFn(s),M),M.incoming.set(this._hashFn(t),f)}removeNode(t){const s=this._hashFn(t);this._nodes.delete(s);for(const f of this._nodes.values())f.outgoing.delete(s),f.incoming.delete(s)}lookupOrInsertNode(t){const s=this._hashFn(t);let f=this._nodes.get(s);return f||(f=new tl(t),this._nodes.set(s,f)),f}isEmpty(){return this._nodes.size===0}toString(){const t=[];for(const[s,f]of this._nodes)t.push(`${s}, (incoming)[${[...f.incoming.keys()].join(", ")}], (outgoing)[${[...f.outgoing.keys()].join(",")}]`);return t.join(` `)}findCycleSlow(){for(const[t,s]of this._nodes){const f=new Set([t]),M=this._findCycle(s,f);if(M)return M}}_findCycle(t,s){for(const[f,M]of t.outgoing){if(s.has(f))return[...s,f].join(" -> ");s.add(f);const V=this._findCycle(M,s);if(V)return V;s.delete(f)}}}var La=y(30657);const Ea=!1;class ka extends Error{constructor(t){var s;super("cyclic dependency between services"),this.message=(s=t.findCycleSlow())!==null&&s!==void 0?s:`UNABLE to detect cycle, dumping graph: ${t.toString()}`}}class ia{constructor(t=new La.a,s=!1,f){this._activeInstantiations=new Set,this._services=t,this._strict=s,this._parent=f,this._services.set(wi._Y,this)}createChild(t){return new ia(t,this._strict,this)}invokeFunction(t,...s){const f=cs.traceInvocation(t);let M=!1;try{return t({get:q=>{if(M)throw(0,C.iH)("service accessor is only valid during the invocation of its target method");const se=this._getOrCreateServiceInstance(q,f);if(!se)throw new Error(`[invokeFunction] unknown service '${q}'`);return se}},...s)}finally{M=!0,f.stop()}}createInstance(t,...s){let f,M;return t instanceof $s.d?(f=cs.traceCreation(t.ctor),M=this._createInstance(t.ctor,t.staticArguments.concat(s),f)):(f=cs.traceCreation(t),M=this._createInstance(t,s,f)),f.stop(),M}_createInstance(t,s=[],f){const M=wi._$.getServiceDependencies(t).sort((se,_e)=>se.index-_e.index),V=[];for(const se of M){const _e=this._getOrCreateServiceInstance(se.id,f);_e||this._throwIfStrict(`[createInstance] ${t.name} depends on UNKNOWN service ${se.id}.`,!1),V.push(_e)}const q=M.length>0?M[0].index:s.length;if(s.length!==q){console.trace(`[createInstance] First service dependency of ${t.name} at position ${q+1} conflicts with ${s.length} static arguments`);const se=q-s.length;se>0?s=s.concat(new Array(se)):s=s.slice(0,q)}return new t(...s,...V)}_setServiceInstance(t,s){if(this._services.get(t)instanceof $s.d)this._services.set(t,s);else if(this._parent)this._parent._setServiceInstance(t,s);else throw new Error("illegalState - setting UNKNOWN service instance")}_getServiceInstanceOrDescriptor(t){const s=this._services.get(t);return!s&&this._parent?this._parent._getServiceInstanceOrDescriptor(t):s}_getOrCreateServiceInstance(t,s){const f=this._getServiceInstanceOrDescriptor(t);return f instanceof $s.d?this._safeCreateAndCacheServiceInstance(t,f,s.branch(t,!0)):(s.branch(t,!1),f)}_safeCreateAndCacheServiceInstance(t,s,f){if(this._activeInstantiations.has(t))throw new Error(`illegal state - RECURSIVELY instantiating service '${t}'`);this._activeInstantiations.add(t);try{return this._createAndCacheServiceInstance(t,s,f)}finally{this._activeInstantiations.delete(t)}}_createAndCacheServiceInstance(t,s,f){const M=new il(se=>se.id.toString());let V=0;const q=[{id:t,desc:s,_trace:f}];for(;q.length;){const se=q.pop();if(M.lookupOrInsertNode(se),V++>1e3)throw new ka(M);for(const _e of wi._$.getServiceDependencies(se.desc.ctor)){const De=this._getServiceInstanceOrDescriptor(_e.id);if(De||this._throwIfStrict(`[createInstance] ${t} depends on ${_e.id} which is NOT registered.`,!0),De instanceof $s.d){const Oe={id:_e.id,desc:De,_trace:se._trace.branch(_e.id,!0)};M.insertEdge(se,Oe),q.push(Oe)}}}for(;;){const se=M.roots();if(se.length===0){if(!M.isEmpty())throw new ka(M);break}for(const{data:_e}of se){if(this._getServiceInstanceOrDescriptor(_e.id)instanceof $s.d){const Oe=this._createServiceInstanceWithOwner(_e.id,_e.desc.ctor,_e.desc.staticArguments,_e.desc.supportsDelayedInstantiation,_e._trace);this._setServiceInstance(_e.id,Oe)}M.removeNode(_e)}}return this._getServiceInstanceOrDescriptor(t)}_createServiceInstanceWithOwner(t,s,f=[],M,V){if(this._services.get(t)instanceof $s.d)return this._createServiceInstance(s,f,M,V);if(this._parent)return this._parent._createServiceInstanceWithOwner(t,s,f,M,V);throw new Error(`illegalState - creating UNKNOWN service instance ${s.name}`)}_createServiceInstance(t,s=[],f,M){if(f){const V=new w.kb(()=>this._createInstance(t,s,M));return new Proxy(Object.create(null),{get(q,se){if(se in q)return q[se];const _e=V.value;let De=_e[se];return typeof De!="function"||(De=De.bind(_e),q[se]=De),De},set(q,se,_e){return V.value[se]=_e,!0}})}else return this._createInstance(t,s,M)}_throwIfStrict(t,s){if(s&&console.warn(t),this._strict)throw new Error(t)}}class cs{constructor(t,s){this.type=t,this.name=s,this._start=Date.now(),this._dep=[]}static traceInvocation(t){return Ea?new cs(1,t.name||t.toString().substring(0,42).replace(/\n/g,"")):cs._None}static traceCreation(t){return Ea?new cs(0,t.name):cs._None}branch(t,s){const f=new cs(2,t.toString());return this._dep.push([t,s,f]),f}stop(){const t=Date.now()-this._start;cs._totals+=t;let s=!1;function f(V,q){const se=[],_e=new Array(V+1).join(" ");for(const[De,Oe,qe]of q._dep)if(Oe&&qe){s=!0,se.push(`${_e}CREATES -> ${De}`);const Bt=f(V+1,qe);Bt&&se.push(Bt)}else se.push(`${_e}uses -> ${De}`);return se.join(` `)}const M=[`${this.type===0?"CREATE":"CALL"} ${this.name}`,`${f(1,this)}`,`DONE, took ${t.toFixed(2)}ms (grand total ${cs._totals.toFixed(2)}ms)`];(t>2||s)&&console.log(M.join(` `))}}cs._None=new class extends cs{constructor(){super(-1,null)}stop(){}branch(){return this}},cs._totals=0;class nl{constructor(){this._byResource=new Di.fT,this._byOwner=new Map}set(t,s,f){let M=this._byResource.get(t);M||(M=new Map,this._byResource.set(t,M)),M.set(s,f);let V=this._byOwner.get(s);V||(V=new Di.fT,this._byOwner.set(s,V)),V.set(t,f)}get(t,s){const f=this._byResource.get(t);return f?.get(s)}delete(t,s){let f=!1,M=!1;const V=this._byResource.get(t);V&&(f=V.delete(s));const q=this._byOwner.get(s);if(q&&(M=q.delete(t)),f!==M)throw new Error("illegal state");return f&&M}values(t){var s,f,M,V;return typeof t=="string"?(f=(s=this._byOwner.get(t))===null||s===void 0?void 0:s.values())!==null&&f!==void 0?f:uo.f.empty():Gi.r.isUri(t)?(V=(M=this._byResource.get(t))===null||M===void 0?void 0:M.values())!==null&&V!==void 0?V:uo.f.empty():uo.f.map(uo.f.concat(...this._byOwner.values()),q=>q[1])}}class sl{constructor(t){this.errors=0,this.infos=0,this.warnings=0,this.unknowns=0,this._data=new Di.fT,this._service=t,this._subscription=t.onMarkerChanged(this._update,this)}dispose(){this._subscription.dispose()}_update(t){for(const s of t){const f=this._data.get(s);f&&this._substract(f);const M=this._resourceStats(s);this._add(M),this._data.set(s,M)}}_resourceStats(t){const s={errors:0,warnings:0,infos:0,unknowns:0};if(t.scheme===ei.ny.inMemory||t.scheme===ei.ny.walkThrough||t.scheme===ei.ny.walkThroughSnippet||t.scheme===ei.ny.vscodeSourceControl)return s;for(const{severity:f}of this._service.read({resource:t}))f===Jn.cj.Error?s.errors+=1:f===Jn.cj.Warning?s.warnings+=1:f===Jn.cj.Info?s.infos+=1:s.unknowns+=1;return s}_substract(t){this.errors-=t.errors,this.warnings-=t.warnings,this.infos-=t.infos,this.unknowns-=t.unknowns}_add(t){this.errors+=t.errors,this.warnings+=t.warnings,this.infos+=t.infos,this.unknowns+=t.unknowns}}class Gs{constructor(){this._onMarkerChanged=new m.uI({delay:0,merge:Gs._merge}),this.onMarkerChanged=this._onMarkerChanged.event,this._data=new nl,this._stats=new sl(this)}dispose(){this._stats.dispose(),this._onMarkerChanged.dispose()}remove(t,s){for(const f of s||[])this.changeOne(t,f,[])}changeOne(t,s,f){if((0,pe.Ct)(f))this._data.delete(s,t)&&this._onMarkerChanged.fire([s]);else{const M=[];for(const V of f){const q=Gs._toMarker(t,s,V);q&&M.push(q)}this._data.set(s,t,M),this._onMarkerChanged.fire([s])}}static _toMarker(t,s,f){let{code:M,severity:V,message:q,source:se,startLineNumber:_e,startColumn:De,endLineNumber:Oe,endColumn:qe,relatedInformation:Bt,tags:jt}=f;if(q)return _e=_e>0?_e:1,De=De>0?De:1,Oe=Oe>=_e?Oe:_e,qe=qe>0?qe:De,{resource:s,owner:t,code:M,severity:V,message:q,source:se,startLineNumber:_e,startColumn:De,endLineNumber:Oe,endColumn:qe,relatedInformation:Bt,tags:jt}}changeAll(t,s){const f=[],M=this._data.values(t);if(M)for(const V of M){const q=uo.f.first(V);q&&(f.push(q.resource),this._data.delete(q.resource,t))}if((0,pe.EI)(s)){const V=new Di.fT;for(const{resource:q,marker:se}of s){const _e=Gs._toMarker(t,q,se);if(!_e)continue;const De=V.get(q);De?De.push(_e):(V.set(q,[_e]),f.push(q))}for(const[q,se]of V)this._data.set(q,t,se)}f.length>0&&this._onMarkerChanged.fire(f)}read(t=Object.create(null)){let{owner:s,resource:f,severities:M,take:V}=t;if((!V||V<0)&&(V=-1),s&&f){const q=this._data.get(f,s);if(q){const se=[];for(const _e of q)if(Gs._accept(_e,M)){const De=se.push(_e);if(V>0&&De===V)break}return se}else return[]}else if(!s&&!f){const q=[];for(const se of this._data.values())for(const _e of se)if(Gs._accept(_e,M)){const De=q.push(_e);if(V>0&&De===V)return q}return q}else{const q=this._data.values(f??s),se=[];for(const _e of q)for(const De of _e)if(Gs._accept(De,M)){const Oe=se.push(De);if(V>0&&Oe===V)return se}return se}}static _accept(t,s){return s===void 0||(s&t.severity)===t.severity}static _merge(t){const s=new Di.fT;for(const f of t)for(const M of f)s.set(M,!0);return Array.from(s.keys())}}function Da(ee,t,s,f,M,V){if(Array.isArray(ee)){let q=0;for(const se of ee){const _e=Da(se,t,s,f,M,V);if(_e===10)return _e;_e>q&&(q=_e)}return q}else{if(typeof ee=="string")return f?ee==="*"?5:ee===s?10:0:0;if(ee){const{language:q,pattern:se,scheme:_e,hasAccessToAllModels:De,notebookType:Oe}=ee;if(!f&&!De)return 0;Oe&&M&&(t=M);let qe=0;if(_e)if(_e===t.scheme)qe=10;else if(_e==="*")qe=5;else return 0;if(q)if(q===s)qe=10;else if(q==="*")qe=Math.max(qe,5);else return 0;if(Oe)if(Oe===V)qe=10;else if(Oe==="*"&&V!==void 0)qe=Math.max(qe,5);else return 0;if(se){let Bt;if(typeof se=="string"?Bt=se:Bt=Object.assign(Object.assign({},se),{base:(0,ns.S8)(se.base)}),Bt===t.fsPath||Ko(Bt,t.fsPath))qe=10;else return 0}return qe}else return 0}}function Ia(ee){return typeof ee=="string"?!1:Array.isArray(ee)?ee.every(Ia):!!ee.exclusive}class xa{constructor(t,s,f,M){this.uri=t,this.languageId=s,this.notebookUri=f,this.notebookType=M}equals(t){var s,f;return this.notebookType===t.notebookType&&this.languageId===t.languageId&&this.uri.toString()===t.uri.toString()&&((s=this.notebookUri)===null||s===void 0?void 0:s.toString())===((f=t.notebookUri)===null||f===void 0?void 0:f.toString())}}class mn{constructor(t){this._notebookInfoResolver=t,this._clock=0,this._entries=[],this._onDidChange=new m.vl,this.onDidChange=this._onDidChange.event}register(t,s){let f={selector:t,provider:s,_score:-1,_time:this._clock++};return this._entries.push(f),this._lastCandidate=void 0,this._onDidChange.fire(this._entries.length),(0,K.s)(()=>{if(f){const M=this._entries.indexOf(f);M>=0&&(this._entries.splice(M,1),this._lastCandidate=void 0,this._onDidChange.fire(this._entries.length),f=void 0)}})}has(t){return this.all(t).length>0}all(t){if(!t)return[];this._updateScores(t);const s=[];for(const f of this._entries)f._score>0&&s.push(f.provider);return s}ordered(t){const s=[];return this._orderedForEach(t,f=>s.push(f.provider)),s}orderedGroups(t){const s=[];let f,M;return this._orderedForEach(t,V=>{f&&M===V._score?f.push(V.provider):(M=V._score,f=[V.provider],s.push(f))}),s}_orderedForEach(t,s){this._updateScores(t);for(const f of this._entries)f._score>0&&s(f)}_updateScores(t){var s,f;const M=(s=this._notebookInfoResolver)===null||s===void 0?void 0:s.call(this,t.uri),V=M?new xa(t.uri,t.getLanguageId(),M.uri,M.type):new xa(t.uri,t.getLanguageId(),void 0,void 0);if(!(!((f=this._lastCandidate)===null||f===void 0)&&f.equals(V))){this._lastCandidate=V;for(const q of this._entries)if(q._score=Da(q.selector,V.uri,V.languageId,(0,p.vd)(t),V.notebookUri,V.notebookType),Ia(q.selector)&&q._score>0){for(const se of this._entries)se._score=0;q._score=1e3;break}this._entries.sort(mn._compareByScoreAndTime)}}static _compareByScoreAndTime(t,s){return t._score<s._score?1:t._score>s._score?-1:t._time<s._time?1:t._time>s._time?-1:0}}class ol{constructor(){this.referenceProvider=new mn(this._score.bind(this)),this.renameProvider=new mn(this._score.bind(this)),this.codeActionProvider=new mn(this._score.bind(this)),this.definitionProvider=new mn(this._score.bind(this)),this.typeDefinitionProvider=new mn(this._score.bind(this)),this.declarationProvider=new mn(this._score.bind(this)),this.implementationProvider=new mn(this._score.bind(this)),this.documentSymbolProvider=new mn(this._score.bind(this)),this.inlayHintsProvider=new mn(this._score.bind(this)),this.colorProvider=new mn(this._score.bind(this)),this.codeLensProvider=new mn(this._score.bind(this)),this.documentFormattingEditProvider=new mn(this._score.bind(this)),this.documentRangeFormattingEditProvider=new mn(this._score.bind(this)),this.onTypeFormattingEditProvider=new mn(this._score.bind(this)),this.signatureHelpProvider=new mn(this._score.bind(this)),this.hoverProvider=new mn(this._score.bind(this)),this.documentHighlightProvider=new mn(this._score.bind(this)),this.selectionRangeProvider=new mn(this._score.bind(this)),this.foldingRangeProvider=new mn(this._score.bind(this)),this.linkProvider=new mn(this._score.bind(this)),this.inlineCompletionsProvider=new mn(this._score.bind(this)),this.completionProvider=new mn(this._score.bind(this)),this.linkedEditingRangeProvider=new mn(this._score.bind(this)),this.documentRangeSemanticTokensProvider=new mn(this._score.bind(this)),this.documentSemanticTokensProvider=new mn(this._score.bind(this)),this.documentOnDropEditProvider=new mn(this._score.bind(this)),this.documentPasteEditProvider=new mn(this._score.bind(this))}_score(t){var s;return(s=this._notebookTypeResolver)===null||s===void 0?void 0:s.call(this,t)}}(0,qt.v)(ke.u,ol,!0);class rl extends Wi{constructor(t={}){const s=Os.O.as(Fn.Fd.Configuration).getConfigurationProperties(),f=Object.keys(s),M=Object.create(null),V=[];for(const q in s){const se=t[q],_e=se!==void 0?se:s[q].default;(0,si.kW)(M,q,_e,De=>console.error(`Conflict in default settings: ${De}`))}for(const q of Object.keys(M))Fn.rC.test(q)&&V.push({identifiers:(0,Fn.Gv)(q),keys:Object.keys(M[q]),contents:(0,si.ad)(M[q],se=>console.error(`Conflict in default settings file: ${se}`))});super(M,f,V)}}var Qs=function(ee,t,s,f){var M=arguments.length,V=M<3?t:f===null?f=Object.getOwnPropertyDescriptor(t,s):f,q;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")V=Reflect.decorate(ee,t,s,f);else for(var se=ee.length-1;se>=0;se--)(q=ee[se])&&(V=(M<3?q(V):M>3?q(t,s,V):q(t,s))||V);return M>3&&V&&Object.defineProperty(t,s,V),V},Zn=function(ee,t){return function(s,f){t(s,f,ee)}},Ta=function(ee,t,s,f){function M(V){return V instanceof s?V:new s(function(q){q(V)})}return new(s||(s=Promise))(function(V,q){function se(Oe){try{De(f.next(Oe))}catch(qe){q(qe)}}function _e(Oe){try{De(f.throw(Oe))}catch(qe){q(qe)}}function De(Oe){Oe.done?V(Oe.value):M(Oe.value).then(se,_e)}De((f=f.apply(ee,t||[])).next())})};class al{constructor(t){this.disposed=!1,this.model=t,this._onWillDispose=new m.vl}get textEditorModel(){return this.model}dispose(){this.disposed=!0,this._onWillDispose.fire()}}let na=class{constructor(t){this.modelService=t}createModelReference(t){const s=this.modelService.getModel(t);return s?Promise.resolve(new K.BO(new al(s))):Promise.reject(new Error("Model not found"))}};na=Qs([Zn(0,u.S)],na);class Mr{show(){return Mr.NULL_PROGRESS_RUNNER}showWhile(t,s){return Ta(this,void 0,void 0,function*(){yield t})}}Mr.NULL_PROGRESS_RUNNER={done:()=>{},total:()=>{},worked:()=>{}};class ll{withProgress(t,s,f){return s({report:()=>{}})}}class cl{confirm(t){return this.doConfirm(t).then(s=>({confirmed:s,checkboxChecked:!1}))}doConfirm(t){let s=t.message;return t.detail&&(s=s+` `+t.detail),Promise.resolve(window.confirm(s))}show(t,s,f,M){return Promise.resolve({choice:0})}}class Nr{info(t){return this.notify({severity:Pi.A.Info,message:t})}warn(t){return this.notify({severity:Pi.A.Warning,message:t})}error(t){return this.notify({severity:Pi.A.Error,message:t})}notify(t){switch(t.severity){case Pi.A.Error:console.error(t.message);break;case Pi.A.Warning:console.warn(t.message);break;default:console.log(t.message);break}return Nr.NO_OP}status(t,s){return K.jG.None}}Nr.NO_OP=new cn.Kz;let sa=class{constructor(t){this._onWillExecuteCommand=new m.vl,this._onDidExecuteCommand=new m.vl,this.onWillExecuteCommand=this._onWillExecuteCommand.event,this.onDidExecuteCommand=this._onDidExecuteCommand.event,this._instantiationService=t}executeCommand(t,...s){const f=Qt.wb.getCommand(t);if(!f)return Promise.reject(new Error(`command '${t}' not found`));try{this._onWillExecuteCommand.fire({commandId:t,args:s});const M=this._instantiationService.invokeFunction.apply(this._instantiationService,[f.handler,...s]);return this._onDidExecuteCommand.fire({commandId:t,args:s}),Promise.resolve(M)}catch(M){return Promise.reject(M)}}};sa=Qs([Zn(0,wi._Y)],sa);let Fo=class extends c{constructor(t,s,f,M,V,q){super(t,s,f,M,V),this._cachedResolver=null,this._dynamicKeybindings=[],this._domNodeListeners=[];const se=jt=>{const Mi=new K.Cm;Mi.add(Ue.ko(jt,Ue.Bx.KEY_DOWN,ln=>{const tn=new sn.Z(ln);this._dispatch(tn,tn.target)&&(tn.preventDefault(),tn.stopPropagation())})),Mi.add(Ue.ko(jt,Ue.Bx.KEY_UP,ln=>{const tn=new sn.Z(ln);this._singleModifierDispatch(tn,tn.target)&&tn.preventDefault()})),this._domNodeListeners.push(new dl(jt,Mi))},_e=jt=>{for(let Mi=0;Mi<this._domNodeListeners.length;Mi++){const ln=this._domNodeListeners[Mi];ln.domNode===jt&&(this._domNodeListeners.splice(Mi,1),ln.dispose())}},De=jt=>{jt.getOption(56)||se(jt.getContainerDomNode())},Oe=jt=>{jt.getOption(56)||_e(jt.getContainerDomNode())};this._register(q.onCodeEditorAdd(De)),this._register(q.onCodeEditorRemove(Oe)),q.listCodeEditors().forEach(De);const qe=jt=>{se(jt.getContainerDomNode())},Bt=jt=>{_e(jt.getContainerDomNode())};this._register(q.onDiffEditorAdd(qe)),this._register(q.onDiffEditorRemove(Bt)),q.listDiffEditors().forEach(qe)}addDynamicKeybinding(t,s,f,M){return(0,K.qE)(Qt.wb.registerCommand(t,f),this.addDynamicKeybindings([{keybinding:s,command:t,when:M}]))}addDynamicKeybindings(t){const s=t.map(f=>{var M,V;const q=(0,zn.ZU)(f.keybinding,v.OS);return{keybinding:(M=q?.parts)!==null&&M!==void 0?M:null,command:(V=f.command)!==null&&V!==void 0?V:null,commandArgs:f.commandArgs,when:f.when,weight1:1e3,weight2:0,extensionId:null,isBuiltinExtension:!1}});return this._dynamicKeybindings=this._dynamicKeybindings.concat(s),this.updateResolver(),(0,K.s)(()=>{for(let f=0;f<this._dynamicKeybindings.length;f++)if(this._dynamicKeybindings[f]===s[0]){this._dynamicKeybindings.splice(f,s.length),this.updateResolver();return}})}updateResolver(){this._cachedResolver=null,this._onDidUpdateKeybindings.fire()}_getResolver(){if(!this._cachedResolver){const t=this._toNormalizedKeybindingItems(Ce.f.getDefaultKeybindings(),!0),s=this._toNormalizedKeybindingItems(this._dynamicKeybindings,!1);this._cachedResolver=new J(t,s,f=>this._log(f))}return this._cachedResolver}_documentHasFocus(){return document.hasFocus()}_toNormalizedKeybindingItems(t,s){const f=[];let M=0;for(const V of t){const q=V.when||void 0,se=V.keybinding;if(!se)f[M++]=new Ee(void 0,V.command,V.commandArgs,q,s,null,!1);else{const _e=ot.resolveUserBinding(se,v.OS);for(const De of _e)f[M++]=new Ee(De,V.command,V.commandArgs,q,s,null,!1)}}return f}resolveKeyboardEvent(t){const s=new zn.h$(t.ctrlKey,t.shiftKey,t.altKey,t.metaKey,t.keyCode).toChord();return new ot(s,v.OS)}};Fo=Qs([Zn(0,Tt.fN),Zn(1,Qt.wT),Zn(2,Ft.k),Zn(3,cn.Ot),Zn(4,be.rr),Zn(5,U.T)],Fo);class dl extends K.jG{constructor(t,s){super(),this.domNode=t,this._register(s)}}function Ma(ee){return ee&&typeof ee=="object"&&(!ee.overrideIdentifier||typeof ee.overrideIdentifier=="string")&&(!ee.resource||ee.resource instanceof Gi.r)}class Na{constructor(){this._onDidChangeConfiguration=new m.vl,this.onDidChangeConfiguration=this._onDidChangeConfiguration.event,this._configuration=new xe(new rl,new Wi,new Wi,new Wi)}getValue(t,s){const f=typeof t=="string"?t:void 0,M=Ma(t)?t:Ma(s)?s:{};return this._configuration.getValue(f,M,void 0)}updateValues(t){const s={data:this._configuration.toData()},f=[];for(const M of t){const[V,q]=M;this.getValue(V)!==q&&(this._configuration.updateValue(V,q),f.push(V))}if(f.length>0){const M=new a({keys:f,overrides:[]},s,this._configuration);M.source=8,M.sourceConfig=null,this._onDidChangeConfiguration.fire(M)}return Promise.resolve()}updateValue(t,s,f,M){return this.updateValues([[t,s]])}inspect(t,s={}){return this._configuration.inspect(t,s,void 0)}}let oa=class{constructor(t){this.configurationService=t,this._onDidChangeConfiguration=new m.vl,this.configurationService.onDidChangeConfiguration(s=>{this._onDidChangeConfiguration.fire({affectedKeys:s.affectedKeys,affectsConfiguration:(f,M)=>s.affectsConfiguration(M)})})}getValue(t,s,f){const V=(pt.y.isIPosition(s)?s:null)?typeof f=="string"?f:void 0:typeof s=="string"?s:void 0;return typeof V>"u"?this.configurationService.getValue():this.configurationService.getValue(V)}};oa=Qs([Zn(0,si.pG)],oa);let ra=class{constructor(t){this.configurationService=t}getEOL(t,s){const f=this.configurationService.getValue("files.eol",{overrideIdentifier:s,resource:t});return f&&typeof f=="string"&&f!=="auto"?f:v.j9||v.zx?` `:`\r `}};ra=Qs([Zn(0,si.pG)],ra);class hl{publicLog(t,s){return Promise.resolve(void 0)}publicLog2(t,s){return this.publicLog(t,s)}}class hr{constructor(){const t=Gi.r.from({scheme:hr.SCHEME,authority:"model",path:"/"});this.workspace={id:"4064f6ec-cb38-4ad0-af64-ee6467e63c82",folders:[new ci.mX({uri:t,name:"",index:0})]}}getWorkspace(){return this.workspace}getWorkspaceFolder(t){return t&&t.scheme===hr.SCHEME?this.workspace.folders[0]:null}}hr.SCHEME="inmemory";function Pr(ee,t,s){if(!t||!(ee instanceof Na))return;const f=[];Object.keys(t).forEach(M=>{(0,Nn.vf)(M)&&f.push([`editor.${M}`,t[M]]),s&&(0,Nn.Gn)(M)&&f.push([`diffEditor.${M}`,t[M]])}),f.length>0&&ee.updateValues(f)}let aa=class{constructor(t){this._modelService=t}hasPreviewHandler(){return!1}apply(t,s){return Ta(this,void 0,void 0,function*(){const f=new Map;for(const q of t){if(!(q instanceof $n.cw))throw new Error("bad edit - only text edits are supported");const se=this._modelService.getModel(q.resource);if(!se)throw new Error("bad edit - model not found");if(typeof q.versionId=="number"&&se.getVersionId()!==q.versionId)throw new Error("bad state - model changed in the meantime");let _e=f.get(se);_e||(_e=[],f.set(se,_e)),_e.push(bi.k.replaceMove(Se.Q.lift(q.textEdit.range),q.textEdit.text))}let M=0,V=0;for(const[q,se]of f)q.pushStackElement(),q.pushEditOperations([],se,()=>[]),q.pushStackElement(),V+=1,M+=se.length;return{ariaSummary:$.GP(Oi.tu.bulkEditServiceSummary,M,V)}})}};aa=Qs([Zn(0,u.S)],aa);class ul{getUriLabel(t,s){return t.scheme==="file"?t.fsPath:t.path}getUriBasenameLabel(t){return(0,on.P8)(t)}}let la=class extends Ss{constructor(t,s){super(t),this._codeEditorService=s}showContextView(t,s,f){if(!s){const M=this._codeEditorService.getFocusedCodeEditor()||this._codeEditorService.getActiveCodeEditor();M&&(s=M.getContainerDomNode())}return super.showContextView(t,s,f)}};la=Qs([Zn(0,Qi),Zn(1,U.T)],la);class fl{constructor(){this._neverEmitter=new m.vl,this.onDidChangeTrust=this._neverEmitter.event}isWorkspaceTrusted(){return!0}}class gl extends vn{constructor(){super()}}class ml extends be.Kc{constructor(){super(new be.Cr)}}let ca=class extends yo{constructor(t,s,f,M,V){super(t,s,f,M,V),this.configure({blockMouse:!1})}};ca=Qs([Zn(0,Ft.k),Zn(1,cn.Ot),Zn(2,hn.l),Zn(3,F.b),Zn(4,oi.Gy)],ca),(0,qt.v)(si.pG,Na),(0,qt.v)(ce.U,oa),(0,qt.v)(ce.J,ra),(0,qt.v)(ci.VR,hr),(0,qt.v)(lt.L,ul),(0,qt.v)(Ft.k,hl),(0,qt.v)(Sn.X,cl),(0,qt.v)(cn.Ot,Nr),(0,qt.v)(Jn.DR,Gs),(0,qt.v)(l.L,gl),(0,qt.v)(Ki.L,un.Sx),(0,qt.v)(be.rr,ml),(0,qt.v)(u.S,Do.JW),(0,qt.v)(va.A,ko),(0,qt.v)(Tt.fN,ta),(0,qt.v)(_t.G5,ll),(0,qt.v)(_t.N8,Mr),(0,qt.v)(bn.CS,bn.pc),(0,qt.v)(Ut.w,it),(0,qt.v)($n.nu,aa),(0,qt.v)(gn.L,fl),(0,qt.v)(zt.b,na),(0,qt.v)(js.j,Dn),(0,qt.v)(Be.PE,Be.aG),(0,qt.v)(Qt.wT,sa),(0,qt.v)(F.b,Fo),(0,qt.v)(st.GK,di),(0,qt.v)(hn.l,la),(0,qt.v)(ao.Cr,Eo),(0,qt.v)(ba.h,qr),(0,qt.v)(hn.Z,ca),(0,qt.v)(Xi.ez,Xr);var hi;(function(ee){const t=new La.a;for(const[q,se]of(0,qt.N)())t.set(q,se);const s=new ia(t,!0);t.set(wi._Y,s);function f(q){const se=t.get(q);if(!se)throw new Error("Missing service "+q);return se instanceof $s.d?s.invokeFunction(_e=>_e.get(q)):se}ee.get=f;let M=!1;function V(q){if(M)return s;M=!0;for(const[se,_e]of(0,qt.N)())t.get(se)||t.set(se,_e);for(const se in q)if(q.hasOwnProperty(se)){const _e=(0,wi.u1)(se);t.get(_e)instanceof $s.d&&t.set(_e,q[se])}return s}ee.initialize=V})(hi||(hi={}));var da=function(ee,t,s,f){var M=arguments.length,V=M<3?t:f===null?f=Object.getOwnPropertyDescriptor(t,s):f,q;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")V=Reflect.decorate(ee,t,s,f);else for(var se=ee.length-1;se>=0;se--)(q=ee[se])&&(V=(M<3?q(V):M>3?q(t,s,V):q(t,s))||V);return M>3&&V&&Object.defineProperty(t,s,V),V},an=function(ee,t){return function(s,f){t(s,f,ee)}};let pl=0,Pa=!1;function _l(ee){if(!ee){if(Pa)return;Pa=!0}kt.vr(ee||document.body)}let Or=class extends Ct.x{constructor(t,s,f,M,V,q,se,_e,De,Oe,qe,Bt){const jt=Object.assign({},s);jt.ariaLabel=jt.ariaLabel||Oi.vp.editorViewAccessibleLabel,jt.ariaLabel=jt.ariaLabel+";"+Oi.vp.accessibilityHelpMessage,super(t,jt,{},f,M,V,q,_e,De,Oe,qe,Bt),se instanceof Fo?this._standaloneKeybindingService=se:this._standaloneKeybindingService=null,_l(jt.ariaContainerElement)}addCommand(t,s,f){if(!this._standaloneKeybindingService)return console.warn("Cannot add command because the editor is configured with an unrecognized KeybindingService"),null;const M="DYNAMIC_"+ ++pl,V=Tt.M$.deserialize(f);return this._standaloneKeybindingService.addDynamicKeybinding(M,t,s,V),M}createContextKey(t,s){return this._contextKeyService.createKey(t,s)}addAction(t){if(typeof t.id!="string"||typeof t.label!="string"||typeof t.run!="function")throw new Error("Invalid action descriptor, `id`, `label` and `run` are required properties!");if(!this._standaloneKeybindingService)return console.warn("Cannot add keybinding because the editor is configured with an unrecognized KeybindingService"),K.jG.None;const s=t.id,f=t.label,M=Tt.M$.and(Tt.M$.equals("editorId",this.getId()),Tt.M$.deserialize(t.precondition)),V=t.keybindings,q=Tt.M$.and(M,Tt.M$.deserialize(t.keybindingContext)),se=t.contextMenuGroupId||null,_e=t.contextMenuOrder||0,De=(jt,...Mi)=>Promise.resolve(t.run(this,...Mi)),Oe=new K.Cm,qe=this.getId()+":"+s;if(Oe.add(Qt.wb.registerCommand(qe,De)),se){const jt={command:{id:qe,title:f},when:M,group:se,order:_e};Oe.add(Xi.ZG.appendMenuItem(Xi.D8.EditorContext,jt))}if(Array.isArray(V))for(const jt of V)Oe.add(this._standaloneKeybindingService.addDynamicKeybinding(qe,jt,De,q));const Bt=new Ht.f(qe,f,f,M,De,this._contextKeyService);return this._actions[s]=Bt,Oe.add((0,K.s)(()=>{delete this._actions[s]})),Oe}_triggerCommand(t,s){if(this._codeEditorService instanceof ti)try{this._codeEditorService.setActiveCodeEditor(this),super._triggerCommand(t,s)}finally{this._codeEditorService.setActiveCodeEditor(null)}else super._triggerCommand(t,s)}};Or=da([an(2,wi._Y),an(3,U.T),an(4,Qt.wT),an(5,Tt.fN),an(6,F.b),an(7,oi.Gy),an(8,cn.Ot),an(9,js.j),an(10,g.JZ),an(11,ke.u)],Or);let ha=class extends Or{constructor(t,s,f,M,V,q,se,_e,De,Oe,qe,Bt,jt,Mi,ln){const tn=Object.assign({},s);Pr(Oe,tn,!1);const En=_e.registerEditorContainer(t);typeof tn.theme=="string"&&_e.setTheme(tn.theme),typeof tn.autoDetectHighContrast<"u"&&_e.setAutoDetectHighContrast(!!tn.autoDetectHighContrast);const fn=tn.model;delete tn.model,super(t,tn,f,M,V,q,se,_e,De,qe,Mi,ln),this._configurationService=Oe,this._standaloneThemeService=_e,this._register(En);let pn;if(typeof fn>"u"){const Hi=jt.getLanguageIdByMimeType(tn.language)||tn.language||ss.vH;pn=Oa(Bt,jt,tn.value||"",Hi,void 0),this._ownsModel=!0}else pn=fn,this._ownsModel=!1;if(this._attachModel(pn),pn){const Hi={oldModelUrl:null,newModelUrl:pn.uri};this._onDidChangeModel.fire(Hi)}}dispose(){super.dispose()}updateOptions(t){Pr(this._configurationService,t,!1),typeof t.theme=="string"&&this._standaloneThemeService.setTheme(t.theme),typeof t.autoDetectHighContrast<"u"&&this._standaloneThemeService.setAutoDetectHighContrast(!!t.autoDetectHighContrast),super.updateOptions(t)}_postDetachModelCleanup(t){super._postDetachModelCleanup(t),t&&this._ownsModel&&(t.dispose(),this._ownsModel=!1)}};ha=da([an(2,wi._Y),an(3,U.T),an(4,Qt.wT),an(5,Tt.fN),an(6,F.b),an(7,Ki.L),an(8,cn.Ot),an(9,si.pG),an(10,js.j),an(11,u.S),an(12,l.L),an(13,g.JZ),an(14,ke.u)],ha);let ua=class extends Gt.T{constructor(t,s,f,M,V,q,se,_e,De,Oe,qe,Bt){const jt=Object.assign({},s);Pr(De,jt,!0);const Mi=se.registerEditorContainer(t);typeof jt.theme=="string"&&se.setTheme(jt.theme),typeof jt.autoDetectHighContrast<"u"&&se.setAutoDetectHighContrast(!!jt.autoDetectHighContrast),super(t,jt,{},Bt,V,M,f,q,se,_e,Oe,qe),this._configurationService=De,this._standaloneThemeService=se,this._register(Mi)}dispose(){super.dispose()}updateOptions(t){Pr(this._configurationService,t,!0),typeof t.theme=="string"&&this._standaloneThemeService.setTheme(t.theme),typeof t.autoDetectHighContrast<"u"&&this._standaloneThemeService.setAutoDetectHighContrast(!!t.autoDetectHighContrast),super.updateOptions(t)}_createInnerEditor(t,s,f){return t.createInstance(Or,s,f)}getOriginalEditor(){return super.getOriginalEditor()}getModifiedEditor(){return super.getModifiedEditor()}addCommand(t,s,f){return this.getModifiedEditor().addCommand(t,s,f)}createContextKey(t,s){return this.getModifiedEditor().createContextKey(t,s)}addAction(t){return this.getModifiedEditor().addAction(t)}};ua=da([an(2,wi._Y),an(3,Tt.fN),an(4,Ut.w),an(5,U.T),an(6,Ki.L),an(7,cn.Ot),an(8,si.pG),an(9,hn.Z),an(10,_t.N8),an(11,ba.h)],ua);function Oa(ee,t,s,f,M){if(s=s||"",!f){const V=s.indexOf(` `);let q=s;return V!==-1&&(q=s.substring(0,V)),Aa(ee,s,t.createByFilepathOrFirstLine(M||null,q),M)}return Aa(ee,s,t.createById(f),M)}function Aa(ee,t,s,f){return ee.createModel(t,s,f)}function vl(ee,t,s){return hi.initialize(s||{}).createInstance(ha,ee,t)}function Cl(ee){return hi.get(U.T).onCodeEditorAdd(s=>{ee(s)})}function bl(ee){return hi.get(U.T).onDiffEditorAdd(s=>{ee(s)})}function wl(){return hi.get(U.T).listCodeEditors()}function yl(){return hi.get(U.T).listDiffEditors()}function Sl(ee,t,s){return hi.initialize(s||{}).createInstance(ua,ee,t)}function Ll(ee,t){return new P.b(ee,t)}function El(ee){if(typeof ee.id!="string"||typeof ee.run!="function")throw new Error("Invalid command descriptor, `id` and `run` are required properties!");return Qt.wb.registerCommand(ee.id,ee.run)}function kl(ee){if(typeof ee.id!="string"||typeof ee.label!="string"||typeof ee.run!="function")throw new Error("Invalid action descriptor, `id`, `label` and `run` are required properties!");const t=Tt.M$.deserialize(ee.precondition),s=(M,...V)=>Io.DX.runEditorCommand(M,V,t,(q,se,_e)=>Promise.resolve(ee.run(se,..._e))),f=new K.Cm;if(f.add(Qt.wb.registerCommand(ee.id,s)),ee.contextMenuGroupId){const M={command:{id:ee.id,title:ee.label},when:t,group:ee.contextMenuGroupId,order:ee.contextMenuOrder||0};f.add(Xi.ZG.appendMenuItem(Xi.D8.EditorContext,M))}if(Array.isArray(ee.keybindings)){const M=hi.get(F.b);if(!(M instanceof Fo))console.warn("Cannot add keybinding because the editor is configured with an unrecognized KeybindingService");else{const V=Tt.M$.and(t,Tt.M$.deserialize(ee.keybindingContext));f.add(M.addDynamicKeybindings(ee.keybindings.map(q=>({keybinding:q,command:ee.id,when:V}))))}}return f}function Dl(ee){return Ra([ee])}function Ra(ee){const t=hi.get(F.b);return t instanceof Fo?t.addDynamicKeybindings(ee.map(s=>({keybinding:s.keybinding,command:s.command,commandArgs:s.commandArgs,when:Tt.M$.deserialize(s.when)}))):(console.warn("Cannot add keybinding because the editor is configured with an unrecognized KeybindingService"),K.jG.None)}function Il(ee,t,s){const f=hi.get(l.L),M=f.getLanguageIdByMimeType(t)||t;return Oa(hi.get(u.S),f,ee,M,s)}function xl(ee,t){const s=hi.get(l.L);hi.get(u.S).setMode(ee,s.createById(t))}function Tl(ee,t,s){ee&&hi.get(Jn.DR).changeOne(t,ee.uri,s)}function Ml(ee){hi.get(Jn.DR).changeAll(ee,[])}function Nl(ee){return hi.get(Jn.DR).read(ee)}function Pl(ee){return hi.get(Jn.DR).onMarkerChanged(ee)}function Ol(ee){return hi.get(u.S).getModel(ee)}function Al(){return hi.get(u.S).getModels()}function Rl(ee){return hi.get(u.S).onModelAdded(ee)}function Bl(ee){return hi.get(u.S).onModelRemoved(ee)}function Fl(ee){return hi.get(u.S).onModelLanguageChanged(s=>{ee({model:s.model,oldLanguage:s.oldLanguageId})})}function Wl(ee){return Rt(hi.get(u.S),hi.get(g.JZ),ee)}function Vl(ee,t){const s=hi.get(l.L),f=hi.get(Ki.L);return f.registerEditorContainer(ee),vt.colorizeElement(f,s,ee,t)}function Hl(ee,t,s){const f=hi.get(l.L);return hi.get(Ki.L).registerEditorContainer(document.body),vt.colorize(f,ee,t,s)}function zl(ee,t,s=4){return hi.get(Ki.L).registerEditorContainer(document.body),vt.colorizeModelLine(ee,t,s)}function Ul(ee){const t=d.dG.get(ee);return t||{getInitialState:()=>h.r3,tokenize:(s,f,M)=>(0,h.$H)(ee,M)}}function jl(ee,t){d.dG.getOrCreate(t);const s=Ul(t),f=(0,$.uz)(ee),M=[];let V=s.getInitialState();for(let q=0,se=f.length;q<se;q++){const _e=f[q],De=s.tokenize(_e,!0,V);M[q]=De.tokens,V=De.endState}return M}function Kl(ee,t){hi.get(Ki.L).defineTheme(ee,t)}function $l(ee){hi.get(Ki.L).setTheme(ee)}function Gl(){L.T.clearAllFontInfos()}function Ql(ee,t){return Qt.wb.registerCommand({id:ee,handler:t})}function Zl(){return{create:vl,getEditors:wl,getDiffEditors:yl,onDidCreateEditor:Cl,onDidCreateDiffEditor:bl,createDiffEditor:Sl,createDiffNavigator:Ll,addCommand:El,addEditorAction:kl,addKeybindingRule:Dl,addKeybindingRules:Ra,createModel:Il,setModelLanguage:xl,setModelMarkers:Tl,getModelMarkers:Nl,removeAllMarkers:Ml,onDidChangeMarkers:Pl,getModels:Al,getModel:Ol,onDidCreateModel:Rl,onWillDisposeModel:Bl,onDidChangeModelLanguage:Fl,createWebWorker:Wl,colorizeElement:Vl,colorize:Hl,colorizeModelLine:zl,tokenize:jl,defineTheme:Kl,setTheme:$l,remeasureFonts:Gl,registerCommand:Ql,AccessibilitySupport:Ve.Gn,ContentWidgetPositionPreference:Ve.Qj,CursorChangeReason:Ve.h5,DefaultEndOfLine:Ve.of,EditorAutoIndentStrategy:Ve.e0,EditorOption:Ve.p2,EndOfLinePreference:Ve.kf,EndOfLineSequence:Ve.WU,MinimapPosition:Ve.R3,MouseTargetType:Ve.hS,OverlayWidgetPositionPreference:Ve.dE,OverviewRulerLane:Ve.A5,RenderLineNumbersType:Ve.DO,RenderMinimap:Ve.Ah,ScrollbarVisibility:Ve.XR,ScrollType:Ve.ov,TextEditorCursorBlinkingStyle:Ve.U7,TextEditorCursorStyle:Ve.m9,TrackedRangeStickiness:Ve.kK,WrappingIndent:Ve.tJ,InjectedTextCursorStops:Ve.VW,PositionAffinity:Ve.Ic,ConfigurationChangedEvent:b.lw,BareFontInfo:B._8,FontInfo:B.YJ,TextModelResolvedOptions:p.X2,FindMatch:p.Dg,ApplyUpdateResult:b.hZ,EditorType:T._,EditorOptions:b.qB}}function Yl(ee,t){if(!t||!Array.isArray(t))return!1;for(const s of t)if(!ee(s))return!1;return!0}function Ar(ee,t){return typeof ee=="boolean"?ee:t}function Ba(ee,t){return typeof ee=="string"?ee:t}function Xl(ee){const t={};for(const s of ee)t[s]=!0;return t}function Fa(ee,t=!1){t&&(ee=ee.map(function(f){return f.toLowerCase()}));const s=Xl(ee);return t?function(f){return s[f.toLowerCase()]!==void 0&&s.hasOwnProperty(f.toLowerCase())}:function(f){return s[f]!==void 0&&s.hasOwnProperty(f)}}function fa(ee,t){t=t.replace(/@@/g,"");let s=0,f;do f=!1,t=t.replace(/@(\w+)/g,function(V,q){f=!0;let se="";if(typeof ee[q]=="string")se=ee[q];else if(ee[q]&&ee[q]instanceof RegExp)se=ee[q].source;else throw ee[q]===void 0?fe(ee,"language definition does not contain attribute '"+q+"', used at: "+t):fe(ee,"attribute reference '"+q+"' must be a string, used at: "+t);return Ii(se)?"":"(?:"+se+")"}),s++;while(f&&s<5);t=t.replace(/\x01/g,"@");const M=(ee.ignoreCase?"i":"")+(ee.unicode?"u":"");return new RegExp(t,M)}function Jl(ee,t,s,f){if(f<0)return ee;if(f<t.length)return t[f];if(f>=100){f=f-100;const M=s.split(".");if(M.unshift(s),f<M.length)return M[f]}return null}function ql(ee,t,s,f){let M=-1,V=s,q=s.match(/^\$(([sS]?)(\d\d?)|#)(.*)$/);q&&(q[3]&&(M=parseInt(q[3]),q[2]&&(M=M+100)),V=q[4]);let se="~",_e=V;!V||V.length===0?(se="!=",_e=""):/^\w*$/.test(_e)?se="==":(q=V.match(/^(@|!@|~|!~|==|!=)(.*)$/),q&&(se=q[1],_e=q[2]));let De;if((se==="~"||se==="!~")&&/^(\w|\|)*$/.test(_e)){const Oe=Fa(_e.split("|"),ee.ignoreCase);De=function(qe){return se==="~"?Oe(qe):!Oe(qe)}}else if(se==="@"||se==="!@"){const Oe=ee[_e];if(!Oe)throw fe(ee,"the @ match target '"+_e+"' is not defined, in rule: "+t);if(!Yl(function(Bt){return typeof Bt=="string"},Oe))throw fe(ee,"the @ match target '"+_e+"' must be an array of strings, in rule: "+t);const qe=Fa(Oe,ee.ignoreCase);De=function(Bt){return se==="@"?qe(Bt):!qe(Bt)}}else if(se==="~"||se==="!~")if(_e.indexOf("$")<0){const Oe=fa(ee,"^"+_e+"$");De=function(qe){return se==="~"?Oe.test(qe):!Oe.test(qe)}}else De=function(Oe,qe,Bt,jt){return fa(ee,"^"+ze(ee,_e,qe,Bt,jt)+"$").test(Oe)};else if(_e.indexOf("$")<0){const Oe=ut(ee,_e);De=function(qe){return se==="=="?qe===Oe:qe!==Oe}}else{const Oe=ut(ee,_e);De=function(qe,Bt,jt,Mi,ln){const tn=ze(ee,Oe,Bt,jt,Mi);return se==="=="?qe===tn:qe!==tn}}return M===-1?{name:s,value:f,test:function(Oe,qe,Bt,jt){return De(Oe,Oe,qe,Bt,jt)}}:{name:s,value:f,test:function(Oe,qe,Bt,jt){const Mi=Jl(Oe,qe,Bt,M);return De(Mi||"",Oe,qe,Bt,jt)}}}function ga(ee,t,s){if(s){if(typeof s=="string")return s;if(s.token||s.token===""){if(typeof s.token!="string")throw fe(ee,"a 'token' attribute must be of type string, in rule: "+t);{const f={token:s.token};if(s.token.indexOf("$")>=0&&(f.tokenSubst=!0),typeof s.bracket=="string")if(s.bracket==="@open")f.bracket=1;else if(s.bracket==="@close")f.bracket=-1;else throw fe(ee,"a 'bracket' attribute must be either '@open' or '@close', in rule: "+t);if(s.next){if(typeof s.next!="string")throw fe(ee,"the next state must be a string value in rule: "+t);{let M=s.next;if(!/^(@pop|@push|@popall)$/.test(M)&&(M[0]==="@"&&(M=M.substr(1)),M.indexOf("$")<0&&!Ot(ee,ze(ee,M,"",[],""))))throw fe(ee,"the next state '"+s.next+"' is not defined in rule: "+t);f.next=M}}return typeof s.goBack=="number"&&(f.goBack=s.goBack),typeof s.switchTo=="string"&&(f.switchTo=s.switchTo),typeof s.log=="string"&&(f.log=s.log),typeof s.nextEmbedded=="string"&&(f.nextEmbedded=s.nextEmbedded,ee.usesEmbedded=!0),f}}else if(Array.isArray(s)){const f=[];for(let M=0,V=s.length;M<V;M++)f[M]=ga(ee,t,s[M]);return{group:f}}else if(s.cases){const f=[];for(const V in s.cases)if(s.cases.hasOwnProperty(V)){const q=ga(ee,t,s.cases[V]);V==="@default"||V==="@"||V===""?f.push({test:void 0,value:q,name:V}):V==="@eos"?f.push({test:function(se,_e,De,Oe){return Oe},value:q,name:V}):f.push(ql(ee,t,V,q))}const M=ee.defaultToken;return{test:function(V,q,se,_e){for(const De of f)if(!De.test||De.test(V,q,se,_e))return De.value;return M}}}else throw fe(ee,"an action must be a string, an object with a 'token' or 'cases' attribute, or an array of actions; in rule: "+t)}else return{token:""}}class ec{constructor(t){this.regex=new RegExp(""),this.action={token:""},this.matchOnlyAtLineStart=!1,this.name="",this.name=t}setRegex(t,s){let f;if(typeof s=="string")f=s;else if(s instanceof RegExp)f=s.source;else throw fe(t,"rules must start with a match string or regular expression: "+this.name);this.matchOnlyAtLineStart=f.length>0&&f[0]==="^",this.name=this.name+": "+f,this.regex=fa(t,"^(?:"+(this.matchOnlyAtLineStart?f.substr(1):f)+")")}setAction(t,s){this.action=ga(t,this.name,s)}}function Wa(ee,t){if(!t||typeof t!="object")throw new Error("Monarch: expecting a language definition object");const s={};s.languageId=ee,s.includeLF=Ar(t.includeLF,!1),s.noThrow=!1,s.maxStack=100,s.start=typeof t.start=="string"?t.start:null,s.ignoreCase=Ar(t.ignoreCase,!1),s.unicode=Ar(t.unicode,!1),s.tokenPostfix=Ba(t.tokenPostfix,"."+s.languageId),s.defaultToken=Ba(t.defaultToken,"source"),s.usesEmbedded=!1;const f=t;f.languageId=ee,f.includeLF=s.includeLF,f.ignoreCase=s.ignoreCase,f.unicode=s.unicode,f.noThrow=s.noThrow,f.usesEmbedded=s.usesEmbedded,f.stateNames=t.tokenizer,f.defaultToken=s.defaultToken;function M(q,se,_e){for(const De of _e){let Oe=De.include;if(Oe){if(typeof Oe!="string")throw fe(s,"an 'include' attribute must be a string at: "+q);if(Oe[0]==="@"&&(Oe=Oe.substr(1)),!t.tokenizer[Oe])throw fe(s,"include target '"+Oe+"' is not defined at: "+q);M(q+"."+Oe,se,t.tokenizer[Oe])}else{const qe=new ec(q);if(Array.isArray(De)&&De.length>=1&&De.length<=3)if(qe.setRegex(f,De[0]),De.length>=3)if(typeof De[1]=="string")qe.setAction(f,{token:De[1],next:De[2]});else if(typeof De[1]=="object"){const Bt=De[1];Bt.next=De[2],qe.setAction(f,Bt)}else throw fe(s,"a next state as the last element of a rule can only be given if the action is either an object or a string, at: "+q);else qe.setAction(f,De[1]);else{if(!De.regex)throw fe(s,"a rule must either be an array, or an object with a 'regex' or 'include' field at: "+q);De.name&&typeof De.name=="string"&&(qe.name=De.name),De.matchOnlyAtStart&&(qe.matchOnlyAtLineStart=Ar(De.matchOnlyAtLineStart,!1)),qe.setRegex(f,De.regex),qe.setAction(f,De.action)}se.push(qe)}}}if(!t.tokenizer||typeof t.tokenizer!="object")throw fe(s,"a language definition must define the 'tokenizer' attribute as an object");s.tokenizer=[];for(const q in t.tokenizer)if(t.tokenizer.hasOwnProperty(q)){s.start||(s.start=q);const se=t.tokenizer[q];s.tokenizer[q]=new Array,M("tokenizer."+q,s.tokenizer[q],se)}if(s.usesEmbedded=f.usesEmbedded,t.brackets){if(!Array.isArray(t.brackets))throw fe(s,"the 'brackets' attribute must be defined as an array")}else t.brackets=[{open:"{",close:"}",token:"delimiter.curly"},{open:"[",close:"]",token:"delimiter.square"},{open:"(",close:")",token:"delimiter.parenthesis"},{open:"<",close:">",token:"delimiter.angle"}];const V=[];for(const q of t.brackets){let se=q;if(se&&Array.isArray(se)&&se.length===3&&(se={token:se[2],open:se[0],close:se[1]}),se.open===se.close)throw fe(s,"open and close brackets in a 'brackets' attribute must be different: "+se.open+` hint: use the 'bracket' attribute if matching on equal brackets is required.`);if(typeof se.open=="string"&&typeof se.token=="string"&&typeof se.close=="string")V.push({token:se.token+s.tokenPostfix,open:ut(s,se.open),close:ut(s,se.close)});else throw fe(s,"every element in the 'brackets' array must be a '{open,close,token}' object or array")}return s.brackets=V,s.noThrow=!0,s}var tc=function(ee,t,s,f){function M(V){return V instanceof s?V:new s(function(q){q(V)})}return new(s||(s=Promise))(function(V,q){function se(Oe){try{De(f.next(Oe))}catch(qe){q(qe)}}function _e(Oe){try{De(f.throw(Oe))}catch(qe){q(qe)}}function De(Oe){Oe.done?V(Oe.value):M(Oe.value).then(se,_e)}De((f=f.apply(ee,t||[])).next())})};function ic(ee){ss.W6.registerLanguage(ee)}function nc(){let ee=[];return ee=ee.concat(ss.W6.getLanguages()),ee}function sc(ee){return hi.get(l.L).languageIdCodec.encodeLanguageId(ee)}function oc(ee,t){const f=hi.get(l.L).onDidEncounterLanguage(M=>{M===ee&&(f.dispose(),t())});return f}function rc(ee,t){if(!hi.get(l.L).isRegisteredLanguageId(ee))throw new Error(`Cannot set configuration for unknown language ${ee}`);return hi.get(g.JZ).register(ee,t,100)}class ac{constructor(t,s){this._languageId=t,this._actual=s}getInitialState(){return this._actual.getInitialState()}tokenize(t,s,f){if(typeof this._actual.tokenize=="function")return ur.adaptTokenize(this._languageId,this._actual,t,f);throw new Error("Not supported!")}tokenizeEncoded(t,s,f){const M=this._actual.tokenizeEncoded(t,f);return new d.rY(M.tokens,M.endState)}}class ur{constructor(t,s,f,M){this._languageId=t,this._actual=s,this._languageService=f,this._standaloneThemeService=M}getInitialState(){return this._actual.getInitialState()}static _toClassicTokens(t,s){const f=[];let M=0;for(let V=0,q=t.length;V<q;V++){const se=t[V];let _e=se.startIndex;V===0?_e=0:_e<M&&(_e=M),f[V]=new d.ou(_e,se.scopes,s),M=_e}return f}static adaptTokenize(t,s,f,M){const V=s.tokenize(f,M),q=ur._toClassicTokens(V.tokens,t);let se;return V.endState.equals(M)?se=M:se=V.endState,new d.$M(q,se)}tokenize(t,s,f){return ur.adaptTokenize(this._languageId,this._actual,t,f)}_toBinaryTokens(t,s){const f=t.encodeLanguageId(this._languageId),M=this._standaloneThemeService.getColorTheme().tokenTheme,V=[];let q=0,se=0;for(let De=0,Oe=s.length;De<Oe;De++){const qe=s[De],Bt=M.match(f,qe.scopes);if(q>0&&V[q-1]===Bt)continue;let jt=qe.startIndex;De===0?jt=0:jt<se&&(jt=se),V[q++]=jt,V[q++]=Bt,se=jt}const _e=new Uint32Array(q);for(let De=0;De<q;De++)_e[De]=V[De];return _e}tokenizeEncoded(t,s,f){const M=this._actual.tokenize(t,f),V=this._toBinaryTokens(this._languageService.languageIdCodec,M.tokens);let q;return M.endState.equals(f)?q=f:q=M.endState,new d.rY(V,q)}}function lc(ee){return typeof ee.getInitialState=="function"}function cc(ee){return"tokenizeEncoded"in ee}function Va(ee){return ee&&typeof ee.then=="function"}function dc(ee){const t=hi.get(Ki.L);if(ee){const s=[null];for(let f=1,M=ee.length;f<M;f++)s[f]=Is.Q1.fromHex(ee[f]);t.setColorMapOverride(s)}else t.setColorMapOverride(null)}function Ha(ee,t){return cc(t)?new ac(ee,t):new ur(ee,t,hi.get(l.L),hi.get(Ki.L))}function ma(ee,t){const s={createTokenizationSupport:()=>tc(this,void 0,void 0,function*(){const f=yield Promise.resolve(t.create());return f?lc(f)?Ha(ee,f):new ve(hi.get(l.L),hi.get(Ki.L),ee,Wa(ee,f),hi.get(si.pG)):null})};return d.dG.registerFactory(ee,s)}function hc(ee,t){if(!hi.get(l.L).isRegisteredLanguageId(ee))throw new Error(`Cannot set tokens provider for unknown language ${ee}`);return Va(t)?ma(ee,{create:()=>t}):d.dG.register(ee,Ha(ee,t))}function uc(ee,t){const s=f=>new ve(hi.get(l.L),hi.get(Ki.L),ee,Wa(ee,f),hi.get(si.pG));return Va(t)?ma(ee,{create:()=>t}):d.dG.register(ee,s(t))}function fc(ee,t){return hi.get(ke.u).referenceProvider.register(ee,t)}function gc(ee,t){return hi.get(ke.u).renameProvider.register(ee,t)}function mc(ee,t){return hi.get(ke.u).signatureHelpProvider.register(ee,t)}function pc(ee,t){return hi.get(ke.u).hoverProvider.register(ee,{provideHover:(f,M,V)=>{const q=f.getWordAtPosition(M);return Promise.resolve(t.provideHover(f,M,V)).then(se=>{if(se)return!se.range&&q&&(se.range=new Se.Q(M.lineNumber,q.startColumn,M.lineNumber,q.endColumn)),se.range||(se.range=new Se.Q(M.lineNumber,M.column,M.lineNumber,M.column)),se})}})}function _c(ee,t){return hi.get(ke.u).documentSymbolProvider.register(ee,t)}function vc(ee,t){return hi.get(ke.u).documentHighlightProvider.register(ee,t)}function Cc(ee,t){return hi.get(ke.u).linkedEditingRangeProvider.register(ee,t)}function bc(ee,t){return hi.get(ke.u).definitionProvider.register(ee,t)}function wc(ee,t){return hi.get(ke.u).implementationProvider.register(ee,t)}function yc(ee,t){return hi.get(ke.u).typeDefinitionProvider.register(ee,t)}function Sc(ee,t){return hi.get(ke.u).codeLensProvider.register(ee,t)}function Lc(ee,t,s){return hi.get(ke.u).codeActionProvider.register(ee,{providedCodeActionKinds:s?.providedCodeActionKinds,documentation:s?.documentation,provideCodeActions:(M,V,q,se)=>{const De=hi.get(Jn.DR).read({resource:M.uri}).filter(Oe=>Se.Q.areIntersectingOrTouching(Oe,V));return t.provideCodeActions(M,V,{markers:De,only:q.only,trigger:q.trigger},se)},resolveCodeAction:t.resolveCodeAction})}function Ec(ee,t){return hi.get(ke.u).documentFormattingEditProvider.register(ee,t)}function kc(ee,t){return hi.get(ke.u).documentRangeFormattingEditProvider.register(ee,t)}function Dc(ee,t){return hi.get(ke.u).onTypeFormattingEditProvider.register(ee,t)}function Ic(ee,t){return hi.get(ke.u).linkProvider.register(ee,t)}function xc(ee,t){return hi.get(ke.u).completionProvider.register(ee,t)}function Tc(ee,t){return hi.get(ke.u).colorProvider.register(ee,t)}function Mc(ee,t){return hi.get(ke.u).foldingRangeProvider.register(ee,t)}function Nc(ee,t){return hi.get(ke.u).declarationProvider.register(ee,t)}function Pc(ee,t){return hi.get(ke.u).selectionRangeProvider.register(ee,t)}function Oc(ee,t){return hi.get(ke.u).documentSemanticTokensProvider.register(ee,t)}function Ac(ee,t){return hi.get(ke.u).documentRangeSemanticTokensProvider.register(ee,t)}function Rc(ee,t){return hi.get(ke.u).inlineCompletionsProvider.register(ee,t)}function Bc(ee,t){return hi.get(ke.u).inlayHintsProvider.register(ee,t)}function Fc(){return{register:ic,getLanguages:nc,onLanguage:oc,getEncodedLanguageId:sc,setLanguageConfiguration:rc,setColorMap:dc,registerTokensProviderFactory:ma,setTokensProvider:hc,setMonarchTokensProvider:uc,registerReferenceProvider:fc,registerRenameProvider:gc,registerCompletionItemProvider:xc,registerSignatureHelpProvider:mc,registerHoverProvider:pc,registerDocumentSymbolProvider:_c,registerDocumentHighlightProvider:vc,registerLinkedEditingRangeProvider:Cc,registerDefinitionProvider:bc,registerImplementationProvider:wc,registerTypeDefinitionProvider:yc,registerCodeLensProvider:Sc,registerCodeActionProvider:Lc,registerDocumentFormattingEditProvider:Ec,registerDocumentRangeFormattingEditProvider:kc,registerOnTypeFormattingEditProvider:Dc,registerLinkProvider:Ic,registerColorProvider:Tc,registerFoldingRangeProvider:Mc,registerDeclarationProvider:Nc,registerSelectionRangeProvider:Pc,registerDocumentSemanticTokensProvider:Oc,registerDocumentRangeSemanticTokensProvider:Ac,registerInlineCompletionsProvider:Rc,registerInlayHintsProvider:Bc,DocumentHighlightKind:Ve.Kb,CompletionItemKind:Ve.Io,CompletionItemTag:Ve.QP,CompletionItemInsertTextRule:Ve._E,SymbolKind:Ve.v0,SymbolTag:Ve.H_,IndentAction:Ve.l,CompletionTriggerKind:Ve.t7,SignatureHelpTriggerKind:Ve.WA,InlayHintKind:Ve.r4,InlineCompletionTriggerKind:Ve.qw,CodeActionTriggerType:Ve.ok,FoldingRangeKind:d.lO}}var Wc=y(38801),pa;b.qB.wrappingIndent.defaultValue=0,b.qB.glyphMargin.defaultValue=!1,b.qB.autoIndent.defaultValue=3,b.qB.overviewRulerLanes.defaultValue=2,Wc.Pj.setFormatterSelector((ee,t,s)=>Promise.resolve(ee[0]));const qn=(0,o.r)();qn.editor=Zl(),qn.languages=Fc();const Vc=qn.CancellationTokenSource,Hc=qn.Emitter,zc=qn.KeyCode,Uc=qn.KeyMod,jc=qn.Position,Kc=qn.Range,$c=qn.Selection,Gc=qn.SelectionDirection,Qc=qn.MarkerSeverity,Zc=qn.MarkerTag,Yc=qn.Uri,Xc=qn.Token,Jc=qn.editor,qc=qn.languages;(!((pa=v.zQ.MonacoEnvironment)===null||pa===void 0)&&pa.globalAPI||typeof define=="function"&&y.amdO)&&(self.monaco=qn),typeof self.require<"u"&&typeof self.require.config=="function"&&self.require.config({ignoreDuplicateModules:["vscode-languageserver-types","vscode-languageserver-types/main","vscode-languageserver-textdocument","vscode-languageserver-textdocument/main","vscode-nls","vscode-nls/vscode-nls","jsonc-parser","jsonc-parser/main","vscode-uri","vscode-uri/index","vs/basic-languages/typescript/typescript"]})},97666:(rt,ye,y)=>{y.d(ye,{g:()=>B});var b=y(16844),o=y(66316),K=y(29895),$=y(62549),L=y(50572),U=y(50442),P=y(15365);class B{static deleteRight(p,d,g,h){const l=[];let u=p!==3;for(let w=0,C=h.length;w<C;w++){const m=h[w];let v=m;if(v.isEmpty()){const k=m.getPosition(),D=L.I.right(d,g,k);v=new U.Q(D.lineNumber,D.column,k.lineNumber,k.column)}if(v.isEmpty()){l[w]=null;continue}v.startLineNumber!==v.endLineNumber&&(u=!0),l[w]=new o.iu(v,"")}return[u,l]}static isAutoClosingPairDelete(p,d,g,h,l,u,w){if(d==="never"&&g==="never"||p==="never")return!1;for(let C=0,m=u.length;C<m;C++){const v=u[C],k=v.getPosition();if(!v.isEmpty())return!1;const D=l.getLineContent(k.lineNumber);if(k.column<2||k.column>=D.length+1)return!1;const x=D.charAt(k.column-2),A=h.get(x);if(!A)return!1;if((0,K.vG)(x)){if(g==="never")return!1}else if(d==="never")return!1;const W=D.charAt(k.column-1);let Y=!1;for(const ne of A)ne.open===x&&ne.close===W&&(Y=!0);if(!Y)return!1;if(p==="auto"){let ne=!1;for(let j=0,Q=w.length;j<Q;j++){const X=w[j];if(k.lineNumber===X.startLineNumber&&k.column===X.startColumn){ne=!0;break}}if(!ne)return!1}}return!0}static _runAutoClosingPairDelete(p,d,g){const h=[];for(let l=0,u=g.length;l<u;l++){const w=g[l].getPosition(),C=new U.Q(w.lineNumber,w.column-1,w.lineNumber,w.column+1);h[l]=new o.iu(C,"")}return[!0,h]}static deleteLeft(p,d,g,h,l){if(this.isAutoClosingPairDelete(d.autoClosingDelete,d.autoClosingBrackets,d.autoClosingQuotes,d.autoClosingPairs.autoClosingPairsOpenByEnd,g,h,l))return this._runAutoClosingPairDelete(d,g,h);const u=[];let w=p!==2;for(let C=0,m=h.length;C<m;C++){const v=B.getDeleteRange(h[C],g,d);if(v.isEmpty()){u[C]=null;continue}v.startLineNumber!==v.endLineNumber&&(w=!0),u[C]=new o.iu(v,"")}return[w,u]}static getDeleteRange(p,d,g){if(!p.isEmpty())return p;const h=p.getPosition();if(g.useTabStops&&h.column>1){const l=d.getLineContent(h.lineNumber),u=b.HG(l),w=u===-1?l.length+1:u+1;if(h.column<=w){const C=g.visibleColumnFromColumn(d,h),m=$.A.prevIndentTabStop(C,g.indentSize),v=g.columnFromVisibleColumn(d,h.lineNumber,m);return new U.Q(h.lineNumber,v,h.lineNumber,h.column)}}return U.Q.fromPositions(B.getPositionAfterDeleteLeft(h,d),h)}static getPositionAfterDeleteLeft(p,d){if(p.column>1){const g=b.Wd(p.column-1,d.getLineContent(p.lineNumber));return p.with(void 0,g+1)}else if(p.lineNumber>1){const g=p.lineNumber-1;return new P.y(g,d.getLineMaxColumn(g))}else return p}static cut(p,d,g){const h=[];let l=null;g.sort((u,w)=>P.y.compare(u.getStartPosition(),w.getEndPosition()));for(let u=0,w=g.length;u<w;u++){const C=g[u];if(C.isEmpty())if(p.emptySelectionClipboard){const m=C.getPosition();let v,k,D,x;m.lineNumber<d.getLineCount()?(v=m.lineNumber,k=1,D=m.lineNumber+1,x=1):m.lineNumber>1&&l?.endLineNumber!==m.lineNumber?(v=m.lineNumber-1,k=d.getLineMaxColumn(m.lineNumber-1),D=m.lineNumber,x=d.getLineMaxColumn(m.lineNumber)):(v=m.lineNumber,k=1,D=m.lineNumber,x=d.getLineMaxColumn(m.lineNumber));const A=new U.Q(v,k,D,x);l=A,A.isEmpty()?h[u]=null:h[u]=new o.iu(A,"")}else h[u]=null;else h[u]=new o.iu(C,"")}return new K.vY(0,h,{shouldPushStackElementBefore:!0,shouldPushStackElementAfter:!0})}}},97669:(rt,ye,y)=>{y.d(ye,{J1:()=>ne,Jo:()=>N,Nd:()=>Ae,Tt:()=>P,WJ:()=>G,WP:()=>L,dE:()=>B,dt:()=>he,ne:()=>Ge,or:()=>K,uU:()=>it,yr:()=>Z});var b=y(27992),o=y(16844);function K(...tt){return function(Ye,ht){for(let Lt=0,Rt=tt.length;Lt<Rt;Lt++){const Ie=tt[Lt](Ye,ht);if(Ie)return Ie}return null}}const $=U.bind(void 0,!1),L=U.bind(void 0,!0);function U(tt,Ye,ht){if(!ht||ht.length<Ye.length)return null;let Lt;return tt?Lt=o.ns(ht,Ye):Lt=ht.indexOf(Ye)===0,Lt?Ye.length>0?[{start:0,end:Ye.length}]:[]:null}function P(tt,Ye){const ht=Ye.toLowerCase().indexOf(tt.toLowerCase());return ht===-1?null:[{start:ht,end:ht+tt.length}]}function B(tt,Ye){return T(tt.toLowerCase(),Ye.toLowerCase(),0,0)}function T(tt,Ye,ht,Lt){if(ht===tt.length)return[];if(Lt===Ye.length)return null;if(tt[ht]===Ye[Lt]){let Rt=null;return(Rt=T(tt,Ye,ht+1,Lt+1))?m({start:Lt,end:Lt+1},Rt):null}return T(tt,Ye,ht,Lt+1)}function p(tt){return 97<=tt&&tt<=122}function d(tt){return 65<=tt&&tt<=90}function g(tt){return 48<=tt&&tt<=57}function h(tt){return tt===32||tt===9||tt===10||tt===13}const l=new Set;"()[]{}<>`'\"-/;:,.?!".split("").forEach(tt=>l.add(tt.charCodeAt(0)));function u(tt){return h(tt)||l.has(tt)}function w(tt,Ye){return tt===Ye||u(tt)&&u(Ye)}function C(tt){return p(tt)||d(tt)||g(tt)}function m(tt,Ye){return Ye.length===0?Ye=[tt]:tt.end===Ye[0].start?Ye[0].start=tt.start:Ye.unshift(tt),Ye}function v(tt,Ye){for(let ht=Ye;ht<tt.length;ht++){const Lt=tt.charCodeAt(ht);if(d(Lt)||g(Lt)||ht>0&&!C(tt.charCodeAt(ht-1)))return ht}return tt.length}function k(tt,Ye,ht,Lt){if(ht===tt.length)return[];if(Lt===Ye.length)return null;if(tt[ht]!==Ye[Lt].toLowerCase())return null;{let Rt=null,Ie=Lt+1;for(Rt=k(tt,Ye,ht+1,Lt+1);!Rt&&(Ie=v(Ye,Ie))<Ye.length;)Rt=k(tt,Ye,ht+1,Ie),Ie++;return Rt===null?null:m({start:Lt,end:Lt+1},Rt)}}function D(tt){let Ye=0,ht=0,Lt=0,Rt=0,Ie=0;for(let Yt=0;Yt<tt.length;Yt++)Ie=tt.charCodeAt(Yt),d(Ie)&&Ye++,p(Ie)&&ht++,C(Ie)&&Lt++,g(Ie)&&Rt++;const Ve=Ye/tt.length,dt=ht/tt.length,bt=Lt/tt.length,Mt=Rt/tt.length;return{upperPercent:Ve,lowerPercent:dt,alphaPercent:bt,numericPercent:Mt}}function x(tt){const{upperPercent:Ye,lowerPercent:ht}=tt;return ht===0&&Ye>.6}function A(tt){const{upperPercent:Ye,lowerPercent:ht,alphaPercent:Lt,numericPercent:Rt}=tt;return ht>.2&&Ye<.8&&Lt>.6&&Rt<.2}function W(tt){let Ye=0,ht=0,Lt=0,Rt=0;for(let Ie=0;Ie<tt.length;Ie++)Lt=tt.charCodeAt(Ie),d(Lt)&&Ye++,p(Lt)&&ht++,h(Lt)&&Rt++;return(Ye===0||ht===0)&&Rt===0?tt.length<=30:Ye<=5}function Y(tt,Ye){if(!Ye||(Ye=Ye.trim(),Ye.length===0)||!W(tt)||Ye.length>60)return null;const ht=D(Ye);if(!A(ht)){if(!x(ht))return null;Ye=Ye.toLowerCase()}let Lt=null,Rt=0;for(tt=tt.toLowerCase();Rt<Ye.length&&(Lt=k(tt,Ye,0,Rt))===null;)Rt=v(Ye,Rt+1);return Lt}function ne(tt,Ye,ht=!1){if(!Ye||Ye.length===0)return null;let Lt=null,Rt=0;for(tt=tt.toLowerCase(),Ye=Ye.toLowerCase();Rt<Ye.length&&(Lt=j(tt,Ye,0,Rt,ht))===null;)Rt=Q(Ye,Rt+1);return Lt}function j(tt,Ye,ht,Lt,Rt){if(ht===tt.length)return[];if(Lt===Ye.length)return null;if(w(tt.charCodeAt(ht),Ye.charCodeAt(Lt))){let Ie=null,Ve=Lt+1;if(Ie=j(tt,Ye,ht+1,Lt+1,Rt),!Rt)for(;!Ie&&(Ve=Q(Ye,Ve))<Ye.length;)Ie=j(tt,Ye,ht+1,Ve,Rt),Ve++;return Ie===null?null:m({start:Lt,end:Lt+1},Ie)}else return null}function Q(tt,Ye){for(let ht=Ye;ht<tt.length;ht++)if(u(tt.charCodeAt(ht))||ht>0&&u(tt.charCodeAt(ht-1)))return ht;return tt.length}const X=K(L,Y,P),R=K(L,Y,B),H=new b.qK(1e4);function Z(tt,Ye,ht=!1){if(typeof tt!="string"||typeof Ye!="string")return null;let Lt=H.get(tt);Lt||(Lt=new RegExp(o.Bm(tt),"i"),H.set(tt,Lt));const Rt=Lt.exec(Ye);return Rt?[{start:Rt.index,end:Rt.index+Rt[0].length}]:ht?R(tt,Ye):X(tt,Ye)}function N(tt,Ye,ht,Lt,Rt,Ie){const Ve=Math.min(13,tt.length);for(;ht<Ve;ht++){const dt=he(tt,Ye,ht,Lt,Rt,Ie,{firstMatchCanBeWeak:!1,boostFullMatch:!0});if(dt)return dt}return[0,Ie]}function G(tt){if(typeof tt>"u")return[];const Ye=[],ht=tt[1];for(let Lt=tt.length-1;Lt>1;Lt--){const Rt=tt[Lt]+ht,Ie=Ye[Ye.length-1];Ie&&Ie.end===Rt?Ie.end=Rt+1:Ye.push({start:Rt,end:Rt+1})}return Ye}const O=128;function te(){const tt=[],Ye=[];for(let ht=0;ht<=O;ht++)Ye[ht]=0;for(let ht=0;ht<=O;ht++)tt.push(Ye.slice(0));return tt}function oe(tt){const Ye=[];for(let ht=0;ht<=tt;ht++)Ye[ht]=0;return Ye}const ue=oe(2*O),E=oe(2*O),Qe=te(),Ke=te(),Se=te(),Me=!1;function ce(tt,Ye,ht,Lt,Rt){function Ie(dt,bt,Mt=" "){for(;dt.length<bt;)dt=Mt+dt;return dt}let Ve=` | |${Lt.split("").map(dt=>Ie(dt,3)).join("|")} `;for(let dt=0;dt<=ht;dt++)dt===0?Ve+=" |":Ve+=`${Ye[dt-1]}|`,Ve+=tt[dt].slice(0,Rt+1).map(bt=>Ie(bt.toString(),3)).join("|")+` `;return Ve}function pe(tt,Ye,ht,Lt){tt=tt.substr(Ye),ht=ht.substr(Lt),console.log(ce(Ke,tt,tt.length,ht,ht.length)),console.log(ce(Se,tt,tt.length,ht,ht.length)),console.log(ce(Qe,tt,tt.length,ht,ht.length))}function be(tt,Ye){if(Ye<0||Ye>=tt.length)return!1;const ht=tt.codePointAt(Ye);switch(ht){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!!o.Ss(ht)}}function ge(tt,Ye){if(Ye<0||Ye>=tt.length)return!1;switch(tt.charCodeAt(Ye)){case 32:case 9:return!0;default:return!1}}function ke(tt,Ye,ht){return Ye[tt]!==ht[tt]}function We(tt,Ye,ht,Lt,Rt,Ie,Ve=!1){for(;Ye<ht&&Rt<Ie;)tt[Ye]===Lt[Rt]&&(Ve&&(ue[Ye]=Rt),Ye+=1),Rt+=1;return Ye===ht}var Ge;(function(tt){tt.Default=[-100,0];function Ye(ht){return!ht||ht.length===2&&ht[0]===-100&&ht[1]===0}tt.isDefault=Ye})(Ge||(Ge={}));class Ae{constructor(Ye,ht){this.firstMatchCanBeWeak=Ye,this.boostFullMatch=ht}}Ae.default={boostFullMatch:!0,firstMatchCanBeWeak:!1};function he(tt,Ye,ht,Lt,Rt,Ie,Ve=Ae.default){const dt=tt.length>O?O:tt.length,bt=Lt.length>O?O:Lt.length;if(ht>=dt||Ie>=bt||dt-ht>bt-Ie||!We(Ye,ht,dt,Rt,Ie,bt,!0))return;Pe(dt,bt,ht,Ie,Ye,Rt);let Mt=1,Yt=1,Nt=ht,Pt=Ie;const Ti=[!1];for(Mt=1,Nt=ht;Nt<dt;Mt++,Nt++){const fe=ue[Nt],ze=E[Nt],Et=Nt+1<dt?E[Nt+1]:bt;for(Yt=fe-Ie+1,Pt=fe;Pt<Et;Yt++,Pt++){let Ot=Number.MIN_SAFE_INTEGER,si=!1;Pt<=ze&&(Ot=$e(tt,Ye,Nt,ht,Lt,Rt,Pt,bt,Ie,Qe[Mt-1][Yt-1]===0,Ti));let _i=0;Ot!==Number.MAX_SAFE_INTEGER&&(si=!0,_i=Ot+Ke[Mt-1][Yt-1]);const Fe=Pt>fe,Xe=Fe?Ke[Mt][Yt-1]+(Qe[Mt][Yt-1]>0?-5:0):0,gt=Pt>fe+1&&Qe[Mt][Yt-1]>0,Xt=gt?Ke[Mt][Yt-2]+(Qe[Mt][Yt-2]>0?-5:0):0;if(gt&&(!Fe||Xt>=Xe)&&(!si||Xt>=_i))Ke[Mt][Yt]=Xt,Se[Mt][Yt]=3,Qe[Mt][Yt]=0;else if(Fe&&(!si||Xe>=_i))Ke[Mt][Yt]=Xe,Se[Mt][Yt]=2,Qe[Mt][Yt]=0;else if(si)Ke[Mt][Yt]=_i,Se[Mt][Yt]=1,Qe[Mt][Yt]=Qe[Mt-1][Yt-1]+1;else throw new Error("not possible")}}if(Me&&pe(tt,ht,Lt,Ie),!Ti[0]&&!Ve.firstMatchCanBeWeak)return;Mt--,Yt--;const Ii=[Ke[Mt][Yt],Ie];let ut=0,Si=0;for(;Mt>=1;){let fe=Yt;do{const ze=Se[Mt][fe];if(ze===3)fe=fe-2;else if(ze===2)fe=fe-1;else break}while(fe>=1);ut>1&&Ye[ht+Mt-1]===Rt[Ie+Yt-1]&&!ke(fe+Ie-1,Lt,Rt)&&ut+1>Qe[Mt][fe]&&(fe=Yt),fe===Yt?ut++:ut=1,Si||(Si=fe),Mt--,Yt=fe-1,Ii.push(Yt)}bt===dt&&Ve.boostFullMatch&&(Ii[0]+=2);const yt=Si-dt;return Ii[0]-=yt,Ii}function Pe(tt,Ye,ht,Lt,Rt,Ie){let Ve=tt-1,dt=Ye-1;for(;Ve>=ht&&dt>=Lt;)Rt[Ve]===Ie[dt]&&(E[Ve]=dt,Ve--),dt--}function $e(tt,Ye,ht,Lt,Rt,Ie,Ve,dt,bt,Mt,Yt){if(Ye[ht]!==Ie[Ve])return Number.MIN_SAFE_INTEGER;let Nt=1,Pt=!1;return Ve===ht-Lt?Nt=tt[ht]===Rt[Ve]?7:5:ke(Ve,Rt,Ie)&&(Ve===0||!ke(Ve-1,Rt,Ie))?(Nt=tt[ht]===Rt[Ve]?7:5,Pt=!0):be(Ie,Ve)&&(Ve===0||!be(Ie,Ve-1))?Nt=5:(be(Ie,Ve-1)||ge(Ie,Ve-1))&&(Nt=5,Pt=!0),Nt>1&&ht===Lt&&(Yt[0]=!0),Pt||(Pt=ke(Ve,Rt,Ie)||be(Ie,Ve-1)||ge(Ie,Ve-1)),ht===Lt?Ve>bt&&(Nt-=Pt?3:5):Mt?Nt+=Pt?2:0:Nt+=Pt?0:1,Ve+1===dt&&(Nt-=Pt?3:5),Nt}function it(tt,Ye,ht,Lt,Rt,Ie,Ve){return ft(tt,Ye,ht,Lt,Rt,Ie,!0,Ve)}function ft(tt,Ye,ht,Lt,Rt,Ie,Ve,dt){let bt=he(tt,Ye,ht,Lt,Rt,Ie,dt);if(bt&&!Ve)return bt;if(tt.length>=3){const Mt=Math.min(7,tt.length-1);for(let Yt=ht+1;Yt<Mt;Yt++){const Nt=Wt(tt,Yt);if(Nt){const Pt=he(Nt,Nt.toLowerCase(),ht,Lt,Rt,Ie,dt);Pt&&(Pt[0]-=3,(!bt||Pt[0]>bt[0])&&(bt=Pt))}}}return bt}function Wt(tt,Ye){if(Ye+1>=tt.length)return;const ht=tt[Ye],Lt=tt[Ye+1];if(ht!==Lt)return tt.slice(0,Ye)+Lt+ht+tt.slice(Ye+2)}},98315:(rt,ye,y)=>{y.d(ye,{Of:()=>K,r0:()=>$,rr:()=>L});var b=y(3765);class o{constructor(T,p,d=p){this.modifierLabels=[null],this.modifierLabels[2]=T,this.modifierLabels[1]=p,this.modifierLabels[3]=d}toLabel(T,p,d){if(p.length===0)return null;const g=[];for(let h=0,l=p.length;h<l;h++){const u=p[h],w=d(u);if(w===null)return null;g[h]=P(u,w,this.modifierLabels[T])}return g.join(" ")}}const K=new o({ctrlKey:"\u2303",shiftKey:"\u21E7",altKey:"\u2325",metaKey:"\u2318",separator:""},{ctrlKey:b.kg({key:"ctrlKey",comment:["This is the short form for the Control key on the keyboard"]},"Ctrl"),shiftKey:b.kg({key:"shiftKey",comment:["This is the short form for the Shift key on the keyboard"]},"Shift"),altKey:b.kg({key:"altKey",comment:["This is the short form for the Alt key on the keyboard"]},"Alt"),metaKey:b.kg({key:"windowsKey",comment:["This is the short form for the Windows key on the keyboard"]},"Windows"),separator:"+"},{ctrlKey:b.kg({key:"ctrlKey",comment:["This is the short form for the Control key on the keyboard"]},"Ctrl"),shiftKey:b.kg({key:"shiftKey",comment:["This is the short form for the Shift key on the keyboard"]},"Shift"),altKey:b.kg({key:"altKey",comment:["This is the short form for the Alt key on the keyboard"]},"Alt"),metaKey:b.kg({key:"superKey",comment:["This is the short form for the Super key on the keyboard"]},"Super"),separator:"+"}),$=new o({ctrlKey:b.kg({key:"ctrlKey.long",comment:["This is the long form for the Control key on the keyboard"]},"Control"),shiftKey:b.kg({key:"shiftKey.long",comment:["This is the long form for the Shift key on the keyboard"]},"Shift"),altKey:b.kg({key:"optKey.long",comment:["This is the long form for the Alt/Option key on the keyboard"]},"Option"),metaKey:b.kg({key:"cmdKey.long",comment:["This is the long form for the Command key on the keyboard"]},"Command"),separator:"+"},{ctrlKey:b.kg({key:"ctrlKey.long",comment:["This is the long form for the Control key on the keyboard"]},"Control"),shiftKey:b.kg({key:"shiftKey.long",comment:["This is the long form for the Shift key on the keyboard"]},"Shift"),altKey:b.kg({key:"altKey.long",comment:["This is the long form for the Alt key on the keyboard"]},"Alt"),metaKey:b.kg({key:"windowsKey.long",comment:["This is the long form for the Windows key on the keyboard"]},"Windows"),separator:"+"},{ctrlKey:b.kg({key:"ctrlKey.long",comment:["This is the long form for the Control key on the keyboard"]},"Control"),shiftKey:b.kg({key:"shiftKey.long",comment:["This is the long form for the Shift key on the keyboard"]},"Shift"),altKey:b.kg({key:"altKey.long",comment:["This is the long form for the Alt key on the keyboard"]},"Alt"),metaKey:b.kg({key:"superKey.long",comment:["This is the long form for the Super key on the keyboard"]},"Super"),separator:"+"}),L=new o({ctrlKey:"Ctrl",shiftKey:"Shift",altKey:"Alt",metaKey:"Cmd",separator:"+"},{ctrlKey:"Ctrl",shiftKey:"Shift",altKey:"Alt",metaKey:"Super",separator:"+"}),U=new o({ctrlKey:"ctrl",shiftKey:"shift",altKey:"alt",metaKey:"cmd",separator:"+"},{ctrlKey:"ctrl",shiftKey:"shift",altKey:"alt",metaKey:"win",separator:"+"},{ctrlKey:"ctrl",shiftKey:"shift",altKey:"alt",metaKey:"meta",separator:"+"});function P(B,T,p){if(T===null)return"";const d=[];return B.ctrlKey&&d.push(p.ctrlKey),B.shiftKey&&d.push(p.shiftKey),B.altKey&&d.push(p.altKey),B.metaKey&&d.push(p.metaKey),T!==""&&d.push(T),d.join(p.separator)}},98769:(rt,ye,y)=>{y.d(ye,{cw:()=>U,jN:()=>L,nu:()=>$});var b=y(82399),o=y(37264),K=y(79359);const $=(0,b.u1)("IWorkspaceEditService");class L{constructor(T){this.metadata=T}static convert(T){return T.edits.map(p=>{if(U.is(p))return U.lift(p);if(P.is(p))return P.lift(p);throw new Error("Unsupported edit")})}}class U extends L{constructor(T,p,d=void 0,g){super(g),this.resource=T,this.textEdit=p,this.versionId=d}static is(T){return T instanceof U?!0:(0,K.Gv)(T)&&o.r.isUri(T.resource)&&(0,K.Gv)(T.textEdit)}static lift(T){return T instanceof U?T:new U(T.resource,T.textEdit,T.versionId,T.metadata)}}class P extends L{constructor(T,p,d={},g){super(g),this.oldResource=T,this.newResource=p,this.options=d}static is(T){return T instanceof P?!0:(0,K.Gv)(T)&&(!!T.newResource||!!T.oldResource)}static lift(T){return T instanceof P?T:new P(T.oldResource,T.newResource,T.options,T.metadata)}}}}]); //# sourceMappingURL=7396.ded473b7a47dc42fbb59.js.map
.
Edit
..
Edit
1117.145ac642f59357bc40d8.js
Edit
1117.145ac642f59357bc40d8.js.map
Edit
1118.c684d1aadf16a6c70620.js
Edit
1118.c684d1aadf16a6c70620.js.map
Edit
1122.5fbf0d7cd148c610616d.js
Edit
1122.5fbf0d7cd148c610616d.js.map
Edit
1142.a4b35a0e8699cafd901e.js
Edit
1142.a4b35a0e8699cafd901e.js.map
Edit
1162.81868b3ac499fa5ea04b.js
Edit
1162.81868b3ac499fa5ea04b.js.map
Edit
1183.7444f51e5996a7f23c7d.js
Edit
1183.7444f51e5996a7f23c7d.js.map
Edit
1282.ae38cac1b732d8ac1d96.js
Edit
1282.ae38cac1b732d8ac1d96.js.map
Edit
130.a58aaeea748f37ee6482.js
Edit
130.a58aaeea748f37ee6482.js.map
Edit
1419.59f53ae25085b28e1e11.js
Edit
1419.59f53ae25085b28e1e11.js.map
Edit
1420.e63ce495727f83b8887d.js
Edit
1420.e63ce495727f83b8887d.js.map
Edit
1438.ccdd05d7188edf4191ff.js
Edit
1438.ccdd05d7188edf4191ff.js.map
Edit
1446.fe7b1f4563629b80793f.js
Edit
1446.fe7b1f4563629b80793f.js.map
Edit
1484.3da94e44ecdadcd342d4.js
Edit
1484.3da94e44ecdadcd342d4.js.map
Edit
1492.4026c6e7130c3afdae87.js
Edit
1494.ef220afb67ff6c52c7af.js
Edit
1494.ef220afb67ff6c52c7af.js.map
Edit
1560.538cd2395be11ba4e2c9.js
Edit
1560.538cd2395be11ba4e2c9.js.map
Edit
1579.c391ef869d4f7bfc0d1c.js
Edit
1579.c391ef869d4f7bfc0d1c.js.map
Edit
1646.d7d87a40853795910533.js
Edit
1646.d7d87a40853795910533.js.map
Edit
1710.7db3f56c6714c0c340e0.js
Edit
1710.7db3f56c6714c0c340e0.js.map
Edit
1716.f71f518289da5d2229bc.js
Edit
1716.f71f518289da5d2229bc.js.map
Edit
1740.baf38e7ee007e1a6935e.js
Edit
1740.baf38e7ee007e1a6935e.js.map
Edit
1821.c9a2456dc8d78cf6b02f.js
Edit
1821.c9a2456dc8d78cf6b02f.js.map
Edit
1888.d33142738af4fbf8a230.js
Edit
1888.d33142738af4fbf8a230.js.map
Edit
1914.5f33b3c2133b5bb7ea6e.js
Edit
1914.5f33b3c2133b5bb7ea6e.js.map
Edit
198.65a768ff6c601d19ea3f.js
Edit
198.65a768ff6c601d19ea3f.js.map
Edit
1990.9171129a8deabb59bf30.js
Edit
1990.9171129a8deabb59bf30.js.map
Edit
2018.5ff00ee0456301c1cf43.js
Edit
2018.5ff00ee0456301c1cf43.js.map
Edit
205.2eb73847215c8d021cc9.js
Edit
205.2eb73847215c8d021cc9.js.map
Edit
2077.a5848ca4b4b9fdebca17.js
Edit
2077.a5848ca4b4b9fdebca17.js.map
Edit
2094.97e7f0876201e76a77fd.js
Edit
2094.97e7f0876201e76a77fd.js.map
Edit
2150.7576285186c713978b39.js
Edit
2150.7576285186c713978b39.js.map
Edit
2152.b55841e6f422682a3891.js
Edit
2152.b55841e6f422682a3891.js.map
Edit
221.0fc4d14d0a67f3a25d64.js
Edit
221.0fc4d14d0a67f3a25d64.js.map
Edit
2218.623d73bd0985ddf5f8c4.js
Edit
2218.623d73bd0985ddf5f8c4.js.map
Edit
2223.e65417164a45701ed9dc.js
Edit
2223.e65417164a45701ed9dc.js.map
Edit
2244.70c156ada2487a05595c.js
Edit
2244.70c156ada2487a05595c.js.map
Edit
2278.f887de0a65e1b784ea9f.js
Edit
2278.f887de0a65e1b784ea9f.js.map
Edit
2288.6a65ba08c6c0f4f83435.js
Edit
2288.6a65ba08c6c0f4f83435.js.map
Edit
2311.73e1a2b949d289f5d6c9.js
Edit
2311.73e1a2b949d289f5d6c9.js.map
Edit
2398.d142e32be48079fc63c0.js
Edit
2398.d142e32be48079fc63c0.js.map
Edit
2405.c1b37a7cc8182472f6a6.js
Edit
2405.c1b37a7cc8182472f6a6.js.map
Edit
2446.0418c7ea000998178d8b.js
Edit
2446.0418c7ea000998178d8b.js.map
Edit
2450.d73c024ff7273aebf911.js
Edit
2450.d73c024ff7273aebf911.js.map
Edit
2586.668c65b61e9ea31b5bca.js
Edit
2586.668c65b61e9ea31b5bca.js.map
Edit
265.ed6933785cc750cbd9ed.js
Edit
265.ed6933785cc750cbd9ed.js.map
Edit
2658.7f70ebc378803654a814.js
Edit
2658.7f70ebc378803654a814.js.map
Edit
2686.ae267304ddd1380c30c7.js
Edit
2686.ae267304ddd1380c30c7.js.map
Edit
2692.fa24ada7d987a7ee05f1.js
Edit
2692.fa24ada7d987a7ee05f1.js.map
Edit
2699.b79e57051a1a63376320.js
Edit
2699.b79e57051a1a63376320.js.map
Edit
2710.e1ac8e57578a838f5bd8.js
Edit
2710.e1ac8e57578a838f5bd8.js.map
Edit
2744.d6b14bf01022bdb8eab5.js
Edit
2744.d6b14bf01022bdb8eab5.js.map
Edit
2745.8049d948cb362dfc6cb3.js
Edit
2745.8049d948cb362dfc6cb3.js.map
Edit
2835.01beb5b1a252d779aad7.js
Edit
2835.01beb5b1a252d779aad7.js.map
Edit
2961.4b27b21453fdbb115dd4.js
Edit
2961.4b27b21453fdbb115dd4.js.map
Edit
2962.85c9dc0cca68efab5e0c.js
Edit
2962.85c9dc0cca68efab5e0c.js.map
Edit
2975.e64aaea6ff35a7d3b3fd.js
Edit
2975.e64aaea6ff35a7d3b3fd.js.map
Edit
3003.f51365051eb27cf765d8.js
Edit
3003.f51365051eb27cf765d8.js.map
Edit
3042.44bad7d2d0536000b808.js
Edit
3042.44bad7d2d0536000b808.js.map
Edit
3062.ad5844391370fcc7525a.js
Edit
3062.ad5844391370fcc7525a.js.map
Edit
3082.704af6779ad700a5fa42.js
Edit
3082.704af6779ad700a5fa42.js.map
Edit
3096.aed61083f1ba4803ae84.js
Edit
3096.aed61083f1ba4803ae84.js.map
Edit
3126.10c85e1f02105e470a69.js
Edit
3126.10c85e1f02105e470a69.js.map
Edit
3169.0b88a5a2340f70961599.js
Edit
3169.0b88a5a2340f70961599.js.map
Edit
3171.c79c28e2611563e2dbcb.js
Edit
3171.c79c28e2611563e2dbcb.js.map
Edit
3182.831f754ed3b6f10441a0.js
Edit
3182.831f754ed3b6f10441a0.js.map
Edit
3192.2cb90eadf3399270363e.js
Edit
3192.2cb90eadf3399270363e.js.map
Edit
3217.c6faaa4f5637068f90f3.js
Edit
3217.c6faaa4f5637068f90f3.js.map
Edit
3259.c8e4d6ad93201a56e49f.js
Edit
3259.c8e4d6ad93201a56e49f.js.map
Edit
3284.79c2897655286b0c1f6d.js
Edit
3284.79c2897655286b0c1f6d.js.map
Edit
3303.225dae64cff0c2280c3b.js
Edit
3303.225dae64cff0c2280c3b.js.map
Edit
3326.cabc370d66d7ecfbd2c3.js
Edit
3326.cabc370d66d7ecfbd2c3.js.map
Edit
344.85cff3029cbbb5463c7e.js
Edit
344.85cff3029cbbb5463c7e.js.map
Edit
3466.fda7da0cb4150e59da98.js
Edit
3466.fda7da0cb4150e59da98.js.map
Edit
3474.74dfd856a9528c758a57.js
Edit
3474.74dfd856a9528c758a57.js.map
Edit
348.fd20e2547f12dbed76c7.js
Edit
348.fd20e2547f12dbed76c7.js.map
Edit
3495.9c1ae6f61edf7aef207b.js
Edit
3495.9c1ae6f61edf7aef207b.js.map
Edit
3501.a0ee7c2b24136aa91eb5.js
Edit
3501.a0ee7c2b24136aa91eb5.js.map
Edit
3520.a3c2b474e2dcaf9879fc.js
Edit
3520.a3c2b474e2dcaf9879fc.js.map
Edit
3605.41e3c44dfe2ca2966198.js
Edit
3605.41e3c44dfe2ca2966198.js.map
Edit
362.e5ce68af98ee6713a4e7.js
Edit
362.e5ce68af98ee6713a4e7.js.map
Edit
3622.0b196041f825b42c5233.js
Edit
3622.0b196041f825b42c5233.js.map
Edit
3630.1ffe9229d5c27fd0823a.js
Edit
3630.1ffe9229d5c27fd0823a.js.map
Edit
3659.f5dc1bb19d36546aadb8.js
Edit
3659.f5dc1bb19d36546aadb8.js.map
Edit
3688.ec5e74c60569e9498687.js
Edit
3688.ec5e74c60569e9498687.js.map
Edit
3718.b570aa4fa35f8dfc686e.js
Edit
3718.b570aa4fa35f8dfc686e.js.map
Edit
3726.84ef8bb1304f7adbc7f3.js
Edit
3726.84ef8bb1304f7adbc7f3.js.map
Edit
398.ceeafcf522343c717c4b.js
Edit
398.ceeafcf522343c717c4b.js.map
Edit
4064.e52eb763993ad947e4a1.js
Edit
4064.e52eb763993ad947e4a1.js.map
Edit
407.594046bd73cc88c29e80.js
Edit
407.594046bd73cc88c29e80.js.map
Edit
4113.3fa5432815c4662eb03e.js
Edit
4113.3fa5432815c4662eb03e.js.map
Edit
4114.c4741f0a73781d3f87dc.js
Edit
4114.c4741f0a73781d3f87dc.js.map
Edit
4120.968e1408d894f8515330.js
Edit
4120.968e1408d894f8515330.js.map
Edit
4162.8b8a683fa98d677f9137.js
Edit
4162.8b8a683fa98d677f9137.js.map
Edit
4209.de7f2b850ee1292a67e5.js
Edit
4209.de7f2b850ee1292a67e5.js.map
Edit
4224.cc13db0c6e3f7fdb05c9.js
Edit
4224.cc13db0c6e3f7fdb05c9.js.map
Edit
4251.28e90ad13c8fe749062c.js
Edit
4251.28e90ad13c8fe749062c.js.map
Edit
4334.396d65b7ba31733108e9.js
Edit
4334.396d65b7ba31733108e9.js.map
Edit
4350.6db49924324f8061d361.js
Edit
4350.6db49924324f8061d361.js.map
Edit
4463.24a3e34bed64cbbb8b99.js
Edit
4463.24a3e34bed64cbbb8b99.js.map
Edit
4514.03e966fee9064d7305dd.js
Edit
4514.03e966fee9064d7305dd.js.map
Edit
4564.ea4a09ba96ddbf74a0ee.js
Edit
4564.ea4a09ba96ddbf74a0ee.js.map
Edit
46.7809585ddbb4791e248a.js
Edit
46.7809585ddbb4791e248a.js.map
Edit
4630.54d7f3b9d384c6b95bbc.js
Edit
4630.54d7f3b9d384c6b95bbc.js.map
Edit
4656.a07d832134b096826a58.js
Edit
4656.a07d832134b096826a58.js.map
Edit
468.d3a2ba8b0d226ca1475b.js
Edit
468.d3a2ba8b0d226ca1475b.js.map
Edit
4680.abd86af55b75e75326ab.js
Edit
4680.abd86af55b75e75326ab.js.map
Edit
4691.2f69f76af87a66a1513c.js
Edit
4691.2f69f76af87a66a1513c.js.map
Edit
4698.c9a2c562b12da12dc66e.js
Edit
4698.c9a2c562b12da12dc66e.js.map
Edit
4791.fc3ef0337811ab73b164.js
Edit
4791.fc3ef0337811ab73b164.js.map
Edit
4814.2d8cb562606e508512d8.js
Edit
4814.2d8cb562606e508512d8.js.map
Edit
4824.2da8107f19d58bf153e0.js
Edit
4824.2da8107f19d58bf153e0.js.map
Edit
4839.f4d2edd5c2678ef2b624.js
Edit
4839.f4d2edd5c2678ef2b624.js.map
Edit
4857.4971a98037d2ec3b663d.js
Edit
4857.4971a98037d2ec3b663d.js.map
Edit
4865.be02c1283a83523c4414.js
Edit
4865.be02c1283a83523c4414.js.map
Edit
494.5463fc5a297eaedd150f.js
Edit
494.5463fc5a297eaedd150f.js.map
Edit
4958.226af5f19bf47305a407.js
Edit
4958.226af5f19bf47305a407.js.map
Edit
4962.bbff24c5a85e9314600a.js
Edit
4962.bbff24c5a85e9314600a.js.map
Edit
4964.1f2cc5acc0078feb7b08.js
Edit
4964.1f2cc5acc0078feb7b08.js.map
Edit
4965.ccdc00d808390be53820.js
Edit
4965.ccdc00d808390be53820.js.map
Edit
5065.a2c71dab50ccb4174ee2.js
Edit
5065.a2c71dab50ccb4174ee2.js.map
Edit
5074.92e2d1ae98dcd913506e.js
Edit
5074.92e2d1ae98dcd913506e.js.map
Edit
5091.987ffc33b70121541e5d.js
Edit
5091.987ffc33b70121541e5d.js.map
Edit
5106.581eaf66a6592320d97a.js
Edit
5106.581eaf66a6592320d97a.js.map
Edit
5110.96d49ea826be96c65045.js
Edit
5110.96d49ea826be96c65045.js.map
Edit
5130.cbdddcd716a093bdbaac.js
Edit
5130.cbdddcd716a093bdbaac.js.map
Edit
5196.9b7364caf64a8583ad01.js
Edit
5196.9b7364caf64a8583ad01.js.map
Edit
5198.2cd64d4e16a385dd9b91.js
Edit
5198.2cd64d4e16a385dd9b91.js.map
Edit
5280.2c29942977baa2dfbe0e.js
Edit
5280.2c29942977baa2dfbe0e.js.map
Edit
5364.0288d9c98f74f26b73e7.js
Edit
5364.0288d9c98f74f26b73e7.js.map
Edit
5446.ad01d0b233122dd49849.js
Edit
5446.ad01d0b233122dd49849.js.map
Edit
5550.5bf3e7d23d6b104740fd.js
Edit
5550.5bf3e7d23d6b104740fd.js.map
Edit
5618.909592bbe054b70f2377.js
Edit
5618.909592bbe054b70f2377.js.map
Edit
5648.a1fc2b0cbbca9bfa1d94.js
Edit
5648.a1fc2b0cbbca9bfa1d94.js.map
Edit
5664.c55be32f6d459ac3f3d8.js
Edit
5664.c55be32f6d459ac3f3d8.js.map
Edit
5671.e1e396b75d7b95ef461f.js
Edit
5671.e1e396b75d7b95ef461f.js.map
Edit
5742.117597ec799ab75cb2f4.js
Edit
5742.117597ec799ab75cb2f4.js.map
Edit
5747.b9389680058c12ffba68.js
Edit
5747.b9389680058c12ffba68.js.map
Edit
5757.5a4b7f2368dd09da42be.js
Edit
5786.c45dfaf9e1d969472e5e.js
Edit
5786.c45dfaf9e1d969472e5e.js.map
Edit
5790.29b0a5797fd46e9664f5.js
Edit
5790.29b0a5797fd46e9664f5.js.map
Edit
5923.b9c876b4bf528d8511cb.js
Edit
5923.b9c876b4bf528d8511cb.js.map
Edit
5984.1efdc4bb85100bd19ca9.js
Edit
5984.1efdc4bb85100bd19ca9.js.map
Edit
5995.5c7a375f33ea1cd16daa.js
Edit
5995.5c7a375f33ea1cd16daa.js.map
Edit
6018.befdd11bf701ea71f7bf.js
Edit
6018.befdd11bf701ea71f7bf.js.map
Edit
6029.bdcbf27bcdd36812f646.js
Edit
6029.bdcbf27bcdd36812f646.js.map
Edit
6088.7f526abfdb4003574c68.js
Edit
6088.7f526abfdb4003574c68.js.map
Edit
613.084d33252856771cf6e1.js
Edit
613.084d33252856771cf6e1.js.map
Edit
6185.2a7c893c6b3f2f0dadb8.js
Edit
6185.2a7c893c6b3f2f0dadb8.js.map
Edit
6208.571f272269524cfd14e7.js
Edit
6208.571f272269524cfd14e7.js.map
Edit
6236.30d1fa6aee173c946c50.js
Edit
6236.30d1fa6aee173c946c50.js.map
Edit
6244.64f83fc5d05560979c51.js
Edit
6244.64f83fc5d05560979c51.js.map
Edit
6260.b8be95165766a81dade2.js
Edit
6260.b8be95165766a81dade2.js.map
Edit
630.56b78dcdaeeb9d9c2967.js
Edit
630.56b78dcdaeeb9d9c2967.js.map
Edit
6302.a2ffa52069511df9772f.js
Edit
6302.a2ffa52069511df9772f.js.map
Edit
6315.f4d87fc6f8ae3cb40e38.js
Edit
6315.f4d87fc6f8ae3cb40e38.js.map
Edit
6414.7520859a2d9cc0a63d7f.js
Edit
6414.7520859a2d9cc0a63d7f.js.map
Edit
6446.1d75a8140260005fffbd.js
Edit
6446.1d75a8140260005fffbd.js.map
Edit
6743.67a52a99e2fdd1ae1e10.js
Edit
6743.67a52a99e2fdd1ae1e10.js.map
Edit
6759.0454d3c1e41385379bdc.js
Edit
6759.0454d3c1e41385379bdc.js.map
Edit
6772.0d4a074848bc323be8f8.js
Edit
6772.0d4a074848bc323be8f8.js.map
Edit
680.726adca366b4ecb272db.js
Edit
680.726adca366b4ecb272db.js.map
Edit
6830.a4b0ecf3a6d784ca7609.js
Edit
6830.a4b0ecf3a6d784ca7609.js.map
Edit
6834.0c9ef40e2f2b5428983d.js
Edit
6834.0c9ef40e2f2b5428983d.js.map
Edit
6857.252a60422ee275193aa7.js
Edit
6857.252a60422ee275193aa7.js.map
Edit
6940.b6c74df14413f0188f0d.js
Edit
6940.b6c74df14413f0188f0d.js.map
Edit
6990.d663924714fc213b17c6.js
Edit
6990.d663924714fc213b17c6.js.map
Edit
7018.5a037d2577fedc8d10f1.js
Edit
7018.5a037d2577fedc8d10f1.js.map
Edit
7031.047b15171c23b248efa0.js
Edit
7031.047b15171c23b248efa0.js.map
Edit
7033.141597840e42815ef6a4.js
Edit
7033.141597840e42815ef6a4.js.map
Edit
7048.3746fc9a274bf8ff72f1.js
Edit
7048.3746fc9a274bf8ff72f1.js.map
Edit
7051.604a402d305e093c00c2.js
Edit
7051.604a402d305e093c00c2.js.map
Edit
7061.f18464bcd6c6d7455662.js
Edit
7061.f18464bcd6c6d7455662.js.map
Edit
7080.9cdd1b7a0bf62b48e1fe.js
Edit
7080.9cdd1b7a0bf62b48e1fe.js.map
Edit
7200.d4425528f6cee80f9931.js
Edit
7200.d4425528f6cee80f9931.js.map
Edit
7235.46f071d3e4d0bb976223.js
Edit
7235.46f071d3e4d0bb976223.js.map
Edit
7246.03f5a8496e53f64602e2.js
Edit
7246.03f5a8496e53f64602e2.js.map
Edit
7249.3bea4aaf890f89fdad45.js
Edit
7249.3bea4aaf890f89fdad45.js.map
Edit
7299.cdff402b076dfea09ead.js
Edit
7299.cdff402b076dfea09ead.js.map
Edit
7348.6fd722455e8c7e077815.js
Edit
7348.6fd722455e8c7e077815.js.map
Edit
7396.ded473b7a47dc42fbb59.js
Edit
7396.ded473b7a47dc42fbb59.js.map
Edit
7466.b7c17c526c7b734dd5f7.js
Edit
7466.b7c17c526c7b734dd5f7.js.map
Edit
7539.5f405cae3b15e1e2f6fa.js
Edit
7539.5f405cae3b15e1e2f6fa.js.map
Edit
7585.084552e02c66201a55be.js
Edit
7585.084552e02c66201a55be.js.map
Edit
7626.38819cc0696f2d25cf99.js
Edit
7626.38819cc0696f2d25cf99.js.map
Edit
7651.5024ed8dd1beb08d01ab.js
Edit
7651.5024ed8dd1beb08d01ab.js.map
Edit
7681.7ef7b4f86e99abd7b7e1.js
Edit
7681.7ef7b4f86e99abd7b7e1.js.map
Edit
7691.0ad86f0c686b19ce829e.js
Edit
7691.0ad86f0c686b19ce829e.js.map
Edit
7790.4c141092868e7208a087.js
Edit
7790.4c141092868e7208a087.js.map
Edit
7806.dff3509790e494ca5a45.js
Edit
7806.dff3509790e494ca5a45.js.map
Edit
7836.afe37ef4be354f0a3b91.js
Edit
7836.afe37ef4be354f0a3b91.js.map
Edit
7882.e1721e9d6ac2d421bcda.js
Edit
7882.e1721e9d6ac2d421bcda.js.map
Edit
7886.8499ded396232466be7d.js
Edit
7886.8499ded396232466be7d.js.map
Edit
7887.a6dcfd824d57598ba1c3.js
Edit
7887.a6dcfd824d57598ba1c3.js.map
Edit
7969.a048d8060cabf1aede33.js
Edit
7969.a048d8060cabf1aede33.js.map
Edit
7996.bd232896e4559d37a26f.js
Edit
7996.bd232896e4559d37a26f.js.map
Edit
8016.8145cd87abcdd0646db2.js
Edit
8016.8145cd87abcdd0646db2.js.map
Edit
8018.c31846109f2dff21d8c4.js
Edit
8018.c31846109f2dff21d8c4.js.map
Edit
8056.4e8f71ed4d507f89b487.js
Edit
8056.4e8f71ed4d507f89b487.js.map
Edit
8177.52abd0953ac914f69e26.js
Edit
8177.52abd0953ac914f69e26.js.map
Edit
8220.aeea4a8f0893b3447b56.js
Edit
8220.aeea4a8f0893b3447b56.js.map
Edit
8224.75bd73bf51ff7a2fc4a0.js
Edit
8224.75bd73bf51ff7a2fc4a0.js.map
Edit
8230.d65bce2998eec95c6082.js
Edit
8230.d65bce2998eec95c6082.js.map
Edit
8260.c1da67af19b9259d5651.js
Edit
8260.c1da67af19b9259d5651.js.map
Edit
8271.0ee36e030014244adb47.js
Edit
8271.0ee36e030014244adb47.js.map
Edit
8332.a62e8632a336661f2969.js
Edit
8332.a62e8632a336661f2969.js.map
Edit
8334.1196f5ddcef25711fc25.js
Edit
8334.1196f5ddcef25711fc25.js.map
Edit
8347.de402f9280cd7a316c57.js
Edit
8347.de402f9280cd7a316c57.js.map
Edit
8390.9de755da2e214cc845a3.js
Edit
8390.9de755da2e214cc845a3.js.map
Edit
8393.30e95ae45cbe5455dcda.js
Edit
8393.30e95ae45cbe5455dcda.js.map
Edit
8477.4dad0537d13cf9315e86.js
Edit
8477.4dad0537d13cf9315e86.js.map
Edit
8494.659892f00c9d15ae441a.js
Edit
8494.659892f00c9d15ae441a.js.map
Edit
8530.0460c988ee4a40ce7769.js
Edit
8530.0460c988ee4a40ce7769.js.map
Edit
8542.317c15ed57f68fcf0c97.js
Edit
8542.317c15ed57f68fcf0c97.js.map
Edit
8547.390120a5caf7646e0e3e.js
Edit
8547.390120a5caf7646e0e3e.js.map
Edit
8566.5c8f392bb383ab92eed0.js
Edit
8566.5c8f392bb383ab92eed0.js.map
Edit
8622.5acf73c1485a11dfb0ab.js
Edit
8622.5acf73c1485a11dfb0ab.js.map
Edit
8706.f17afa6bcdfd511d5b03.js
Edit
8706.f17afa6bcdfd511d5b03.js.map
Edit
874.d24410518317d605c708.js
Edit
874.d24410518317d605c708.js.map
Edit
8813.e5137844631f6ddedbce.js
Edit
8813.e5137844631f6ddedbce.js.map
Edit
8856.2720526447b3adb5c75f.js
Edit
8856.2720526447b3adb5c75f.js.map
Edit
886.5f3383e84b10a6530b97.js
Edit
886.5f3383e84b10a6530b97.js.map
Edit
8864.2f4ee982114c25634e55.js
Edit
8864.2f4ee982114c25634e55.js.map
Edit
8902.71f14964ec6cea84dc8e.js
Edit
8902.71f14964ec6cea84dc8e.js.map
Edit
8932.e59e50ddb63414e0f2b9.js
Edit
8932.e59e50ddb63414e0f2b9.js.map
Edit
8990.665213a5c89afd6b2f83.js
Edit
8990.665213a5c89afd6b2f83.js.map
Edit
9034.a32e36472481cbe5d72d.js
Edit
9034.a32e36472481cbe5d72d.js.map
Edit
9038.f03b25f160057d4a0bf6.js
Edit
9038.f03b25f160057d4a0bf6.js.map
Edit
904.b68cd2a0cd6d68c5f1ae.js
Edit
904.b68cd2a0cd6d68c5f1ae.js.map
Edit
9044.441f64d6d946cc93be46.js
Edit
9044.441f64d6d946cc93be46.js.map
Edit
9147.8309cadbc384209d62e5.js
Edit
9147.8309cadbc384209d62e5.js.map
Edit
9150.38487365ffd149b730af.js
Edit
9150.38487365ffd149b730af.js.map
Edit
9292.e6befb57f8f116ad95a8.js
Edit
9292.e6befb57f8f116ad95a8.js.map
Edit
9355.95d7e1782f93f339549e.js
Edit
9355.95d7e1782f93f339549e.js.map
Edit
9388.88d95a230e9432e7037b.js
Edit
9388.88d95a230e9432e7037b.js.map
Edit
9390.c72fcd228017f7647b38.js
Edit
9390.c72fcd228017f7647b38.js.map
Edit
9414.642bfe0d5eb16efd0c16.js
Edit
9414.642bfe0d5eb16efd0c16.js.map
Edit
9449.502f2a824d0203e88d4d.js
Edit
9449.502f2a824d0203e88d4d.js.map
Edit
946.48c5e8c688cf29424295.js
Edit
946.48c5e8c688cf29424295.js.map
Edit
9473.e6fc327da88d88712828.js
Edit
9473.e6fc327da88d88712828.js.map
Edit
9510.1e255e96fe40aad2ed6f.js
Edit
9510.1e255e96fe40aad2ed6f.js.map
Edit
9521.e65411d726c29d77c526.js
Edit
9521.e65411d726c29d77c526.js.map
Edit
9538.a2289ff9ad06e24e391f.js
Edit
9538.a2289ff9ad06e24e391f.js.map
Edit
957.3c35d66aa698d8bdfe05.js
Edit
957.3c35d66aa698d8bdfe05.js.map
Edit
9571.41558d40bff9ea8c0726.js
Edit
9571.41558d40bff9ea8c0726.js.map
Edit
9578.9cfae16465bb9bc1f336.js
Edit
9578.9cfae16465bb9bc1f336.js.map
Edit
968.d4b150f9211c478b7b05.js
Edit
968.d4b150f9211c478b7b05.js.map
Edit
970.46f17b76711e4961a575.js
Edit
970.46f17b76711e4961a575.js.map
Edit
9700.02180b7a06c8a1f7606b.js
Edit
9700.02180b7a06c8a1f7606b.js.map
Edit
9744.aa6baaf988a68fa6a9ba.js
Edit
9744.aa6baaf988a68fa6a9ba.js.map
Edit
9820.6b462d83575efd05c883.js
Edit
9820.6b462d83575efd05c883.js.map
Edit
9838.06bd7dfd4290786f80e3.js
Edit
9838.06bd7dfd4290786f80e3.js.map
Edit
9992.fb08517d3ff77e887443.js
Edit
9992.fb08517d3ff77e887443.js.map
Edit
9996.21c451f22ff76b4bb683.js
Edit
9996.21c451f22ff76b4bb683.js.map
Edit
AdminAuthentication.076c98c6380fd1e42f7e.js
Edit
AdminAuthentication.076c98c6380fd1e42f7e.js.map
Edit
AdminEditOrgPage.8df8167ea6ff8f4803bd.js
Edit
AdminEditOrgPage.8df8167ea6ff8f4803bd.js.map
Edit
AdminListOrgsPage.176dac9ed391bda8952b.js
Edit
AdminListOrgsPage.176dac9ed391bda8952b.js.map
Edit
AdminSettings.7373ed8fa9b943bb2098.js
Edit
AdminSettings.7373ed8fa9b943bb2098.js.map
Edit
AlertGroups.81264e6e5009c36eed6e.js
Edit
AlertGroups.81264e6e5009c36eed6e.js.map
Edit
AlertRuleListIndex.98e7328feeaa2ffe67eb.js
Edit
AlertRuleListIndex.98e7328feeaa2ffe67eb.js.map
Edit
AlertingDisabled.b2c834be0ca4666dd793.js
Edit
AlertingDisabled.b2c834be0ca4666dd793.js.map
Edit
AlertingGroupDetails.3a2c6ef8085b505852e4.js
Edit
AlertingGroupDetails.3a2c6ef8085b505852e4.js.map
Edit
AlertingGroupEdit.69cfe9d5f37a1fc65326.js
Edit
AlertingGroupEdit.69cfe9d5f37a1fc65326.js.map
Edit
AlertingHome.06f307ab9a2a5d8b7f93.js
Edit
AlertingHome.06f307ab9a2a5d8b7f93.js.map
Edit
AlertingImportFromDSRules.f1224bcb622d25e2c94f.js
Edit
AlertingImportFromDSRules.f1224bcb622d25e2c94f.js.map
Edit
AlertingRedirectToRule.9ed1d16829d6833d2827.js
Edit
AlertingRedirectToRule.9ed1d16829d6833d2827.js.map
Edit
AlertingRuleForm.2e69d3f00eb6221e7355.js
Edit
AlertingRuleForm.2e69d3f00eb6221e7355.js.map
Edit
AlertingSettings.7a5f782f877cec4790cb.js
Edit
AlertingSettings.7a5f782f877cec4790cb.js.map
Edit
AlertingTriage.1174f36b4937ad0047c1.js
Edit
AlertingTriage.1174f36b4937ad0047c1.js.map
Edit
BenchmarksPage.ef387f4598ba2b2236ad.js
Edit
BenchmarksPage.ef387f4598ba2b2236ad.js.map
Edit
BookmarksPage.8fe93eb7377073f0c985.js
Edit
BookmarksPage.8fe93eb7377073f0c985.js.map
Edit
ChangePasswordPage.f21b0b1dd107ccd33c1a.js
Edit
ChangePasswordPage.f21b0b1dd107ccd33c1a.js.map
Edit
Connections.949b6389e73bcadb2109.js
Edit
Connections.949b6389e73bcadb2109.js.map
Edit
ContactPoints.9ae2d1927d60c6169b87.js
Edit
ContactPoints.9ae2d1927d60c6169b87.js.map
Edit
CorrelationsFeatureToggle.ec2f1aefce6b456e15eb.js
Edit
CorrelationsFeatureToggle.ec2f1aefce6b456e15eb.js.map
Edit
CorrelationsPage.bd7fcd24ed0b5fe8ac3e.js
Edit
CorrelationsPage.bd7fcd24ed0b5fe8ac3e.js.map
Edit
CreateTeam.429acf93986740280312.js
Edit
CreateTeam.429acf93986740280312.js.map
Edit
DashboardImport.3e9b6f980b81d6f1c755.js
Edit
DashboardImport.3e9b6f980b81d6f1c755.js.map
Edit
DashboardListPage.abeb0c29f072f888f9fb.js
Edit
DashboardListPage.abeb0c29f072f888f9fb.js.map
Edit
DashboardPage.72557fe6dd1a022b7d48.js
Edit
DashboardPage.72557fe6dd1a022b7d48.js.map
Edit
DashboardPageProxy.80adfefad8a885d8e2ef.js
Edit
DashboardPageProxy.80adfefad8a885d8e2ef.js.map
Edit
DashboardScenePage.83fe1fa9509b50120d65.js
Edit
DashboardScenePage.83fe1fa9509b50120d65.js.map
Edit
EditContactPoint.0c33428ddc8ba974d946.js
Edit
EditContactPoint.0c33428ddc8ba974d946.js.map
Edit
EditMuteTiming.8760cc9c77560acf0cd6.js
Edit
EditMuteTiming.8760cc9c77560acf0cd6.js.map
Edit
EditRepositoryPage.d71faaab1af2c8d70a22.js
Edit
EditRepositoryPage.d71faaab1af2c8d70a22.js.map
Edit
EmbeddedDashboard.57de550bce819e3d52e6.js
Edit
EmbeddedDashboard.57de550bce819e3d52e6.js.map
Edit
FileHistoryPage.154ab77c19bbe0ebed20.js
Edit
FileHistoryPage.154ab77c19bbe0ebed20.js.map
Edit
FileStatusPage.36f58cd61202ec603d22.js
Edit
FileStatusPage.36f58cd61202ec603d22.js.map
Edit
FolderAlerting.0b9acb6c42276aaee57d.js
Edit
FolderAlerting.0b9acb6c42276aaee57d.js.map
Edit
FolderLibraryPanelsPage.44f8cabf542ec314d176.js
Edit
FolderLibraryPanelsPage.44f8cabf542ec314d176.js.map
Edit
GettingStartedPage.4bea37f1c9bdcfd0f41b.js
Edit
GettingStartedPage.4bea37f1c9bdcfd0f41b.js.map
Edit
GlobalConfig.1377596507974d18caf6.js
Edit
GlobalConfig.1377596507974d18caf6.js.map
Edit
HistoryPage.4da98f4fa313ee3676ca.js
Edit
HistoryPage.4da98f4fa313ee3676ca.js.map
Edit
LdapSettingsPage.0e9f08d5e59150ecf466.js
Edit
LdapSettingsPage.0e9f08d5e59150ecf466.js.map
Edit
LibraryPanelsPage.824580d7751526c658e2.js
Edit
LibraryPanelsPage.824580d7751526c658e2.js.map
Edit
ListPublicDashboardPage.64c26ffd3ebe6c9076f3.js
Edit
ListPublicDashboardPage.64c26ffd3ebe6c9076f3.js.map
Edit
LoginPage.db48423ed1b455431daa.js
Edit
LoginPage.db48423ed1b455431daa.js.map
Edit
MetricsDrilldownRedirect.fcad4bdff346974952f4.js
Edit
MetricsDrilldownRedirect.fcad4bdff346974952f4.js.map
Edit
MigrateToCloud.5b474ad00e8a3d979750.js
Edit
MigrateToCloud.5b474ad00e8a3d979750.js.map
Edit
NewMuteTiming.2f6302420674f1c73aba.js
Edit
NewMuteTiming.2f6302420674f1c73aba.js.map
Edit
NewOrgPage.be31eaee06e2043d609b.js
Edit
NewOrgPage.be31eaee06e2043d609b.js.map
Edit
NewReceiverView.f1d83eb66a39882b8661.js
Edit
NewReceiverView.f1d83eb66a39882b8661.js.map
Edit
NewSilencePage.2643a48031f7e5d8f376.js
Edit
NewSilencePage.2643a48031f7e5d8f376.js.map
Edit
NotificationPoliciesPage.9333d10ecad1452ebf27.js
Edit
NotificationPoliciesPage.9333d10ecad1452ebf27.js.map
Edit
NotificationsPage.57df4ff5ba1433a4345d.js
Edit
NotificationsPage.57df4ff5ba1433a4345d.js.map
Edit
OrgDetailsPage.7b5835c30585aae81343.js
Edit
OrgDetailsPage.7b5835c30585aae81343.js.map
Edit
PlaylistEditPage.8310e384af659e40c313.js
Edit
PlaylistEditPage.8310e384af659e40c313.js.map
Edit
PlaylistNewPage.f45b642a98a747e28c0d.js
Edit
PlaylistNewPage.f45b642a98a747e28c0d.js.map
Edit
PlaylistPage.9af74957a1cdfb125338.js
Edit
PlaylistPage.9af74957a1cdfb125338.js.map
Edit
PlaylistStartPage.8011a98267ac64c7fa05.js
Edit
PlaylistStartPage.8011a98267ac64c7fa05.js.map
Edit
PluginExtensionsLog.54c02047d569b0c05823.js
Edit
PluginExtensionsLog.54c02047d569b0c05823.js.map
Edit
PluginListPage.e50c18fed21c23ca4ee8.js
Edit
PluginListPage.e50c18fed21c23ca4ee8.js.map
Edit
PluginPage.ae424531bce63dd4721e.js
Edit
PluginPage.ae424531bce63dd4721e.js.map
Edit
ProfileFeatureTogglePage.27378dcbb7520611348e.js
Edit
ProfileFeatureTogglePage.27378dcbb7520611348e.js.map
Edit
ProvisioningWizardPage.c4e4a8f431b4719b0e95.js
Edit
ProvisioningWizardPage.c4e4a8f431b4719b0e95.js.map
Edit
PublicDashboardPage.33d6ec8f685f1b70b9a6.js
Edit
PublicDashboardPage.33d6ec8f685f1b70b9a6.js.map
Edit
RecentlyDeleted.5e0ec16474d939fd9683.js
Edit
RecentlyDeleted.5e0ec16474d939fd9683.js.map
Edit
RecentlyDeletedPage.1dbc2b80b28204de8237.js
Edit
RecentlyDeletedPage.1dbc2b80b28204de8237.js.map
Edit
RepositoryListPage.ec3a0af1cbe2740800bf.js
Edit
RepositoryListPage.ec3a0af1cbe2740800bf.js.map
Edit
RepositoryStatusPage.9aee60589e35a4a19ec2.js
Edit
RepositoryStatusPage.9aee60589e35a4a19ec2.js.map
Edit
SelectOrgPage.910a8d842019a6d7fe93.js
Edit
SelectOrgPage.910a8d842019a6d7fe93.js.map
Edit
SendResetMailPage.513361d6980f98ff8139.js
Edit
SendResetMailPage.513361d6980f98ff8139.js.map
Edit
ServerStats.2830ca154f465dbdecea.js
Edit
ServerStats.2830ca154f465dbdecea.js.map
Edit
ServiceAccountCreatePage.80fcbdd2b7f5aa4e2da1.js
Edit
ServiceAccountCreatePage.80fcbdd2b7f5aa4e2da1.js.map
Edit
ServiceAccountPage.48944056459bb412ff33.js
Edit
ServiceAccountPage.48944056459bb412ff33.js.map
Edit
ServiceAccountsPage.d20b1eb9f87661f10b45.js
Edit
ServiceAccountsPage.d20b1eb9f87661f10b45.js.map
Edit
SignupInvited.fe2c29f380e9888c28cf.js
Edit
SignupInvited.fe2c29f380e9888c28cf.js.map
Edit
SilencesTablePage.b998fdbdcc3d60a81739.js
Edit
SilencesTablePage.b998fdbdcc3d60a81739.js.map
Edit
SnapshotListPage.6feaf24adb92e6a302ec.js
Edit
SnapshotListPage.6feaf24adb92e6a302ec.js.map
Edit
SoloPanelPage.7fc6a934aaadf4c1f84d.js
Edit
SoloPanelPage.7fc6a934aaadf4c1f84d.js.map
Edit
SoloPanelPageOld.bde57e000dd0a0108685.js
Edit
SoloPanelPageOld.bde57e000dd0a0108685.js.map
Edit
SupportBundles.1f46603ad3494624d67a.js
Edit
SupportBundles.1f46603ad3494624d67a.js.map
Edit
SupportBundlesCreate.5eaea61a9713f057277b.js
Edit
SupportBundlesCreate.5eaea61a9713f057277b.js.map
Edit
TeamList.6b088f83e6e8cb66b21d.js
Edit
TeamList.6b088f83e6e8cb66b21d.js.map
Edit
TeamPages.9d8b5dceef8be43c6923.js
Edit
TeamPages.9d8b5dceef8be43c6923.js.map
Edit
Templates.7a02a8497ebca052dcfb.js
Edit
Templates.7a02a8497ebca052dcfb.js.map
Edit
TestStuffPage.982c641592b2f7c9db40.js
Edit
TestStuffPage.982c641592b2f7c9db40.js.map
Edit
ThemePlayground.aeeec77fd8e9c1482f55.js
Edit
ThemePlayground.aeeec77fd8e9c1482f55.js.map
Edit
UserAdminPage.fc4d562eef05d9f59aca.js
Edit
UserAdminPage.fc4d562eef05d9f59aca.js.map
Edit
UserCreatePage.b7036214c66612fb31e9.js
Edit
UserCreatePage.b7036214c66612fb31e9.js.map
Edit
UserInvitePage.4a9bcd4084d7ae454c73.js
Edit
UserInvitePage.4a9bcd4084d7ae454c73.js.map
Edit
UserListPage.a452e1153ae820f58ac9.js
Edit
UserListPage.a452e1153ae820f58ac9.js.map
Edit
UserProfileEditPage.82c11690282e669eabb1.js
Edit
UserProfileEditPage.82c11690282e669eabb1.js.map
Edit
alert-rules-drawer-content.c95bb5ddd3fc813cae92.js
Edit
alert-rules-drawer-content.c95bb5ddd3fc813cae92.js.map
Edit
alert-rules-toolbar-button.0d86c1adae7edb55ff76.js
Edit
alert-rules-toolbar-button.0d86c1adae7edb55ff76.js.map
Edit
alertListPanel.0110106a8d1ab70d65d5.js
Edit
alertListPanel.0110106a8d1ab70d65d5.js.map
Edit
alertmanagerPlugin.2b59de5e7b7a556f87f1.js
Edit
alertmanagerPlugin.2b59de5e7b7a556f87f1.js.map
Edit
annoListPanel.0005a0eab0b05e24d970.js
Edit
annoListPanel.0005a0eab0b05e24d970.js.map
Edit
app.8385deda1df49aa75ec2.js
Edit
app.8385deda1df49aa75ec2.js.map
Edit
assets-manifest.json
Edit
barChartPanel.eecdaeab7d146d477721.js
Edit
barChartPanel.eecdaeab7d146d477721.js.map
Edit
barGaugePanel.6d9e94bbb72ba92a0e9b.js
Edit
barGaugePanel.6d9e94bbb72ba92a0e9b.js.map
Edit
candlestickPanel.af0e0decd06e7b7ab286.js
Edit
candlestickPanel.af0e0decd06e7b7ab286.js.map
Edit
canvasPanel.ddab72fab6e58c3419b2.js
Edit
canvasPanel.ddab72fab6e58c3419b2.js.map
Edit
cloudwatchPlugin.06ef34f60000c4f7ea37.js
Edit
cloudwatchPlugin.06ef34f60000c4f7ea37.js.map
Edit
dark.b66fa87185b9a313ec14.js
Edit
dashListPanel.23b954da0c4888602048.js
Edit
dashListPanel.23b954da0c4888602048.js.map
Edit
dataGridPanel.bb5d4b678cba38dd380b.js
Edit
debugPanel.fff63da32084d7a2e236.js
Edit
debugPanel.fff63da32084d7a2e236.js.map
Edit
elasticsearchPlugin.3f2edb012f5162b48903.js
Edit
elasticsearchPlugin.3f2edb012f5162b48903.js.map
Edit
explore-feature-toggle-page.3de03fa91c88d05cea1c.js
Edit
explore-feature-toggle-page.3de03fa91c88d05cea1c.js.map
Edit
explore.dd32637df83326225e0d.js
Edit
explore.dd32637df83326225e0d.js.map
Edit
flamegraphPanel.cc6c5b4bcd69e406fbb7.js
Edit
flamegraphPanel.cc6c5b4bcd69e406fbb7.js.map
Edit
gaugePanel.5da3c4e39a652e281cc4.js
Edit
gaugePanel.5da3c4e39a652e281cc4.js.map
Edit
gazetteer
Edit
geomapPanel.67ebb4567e9b5fa5074b.js
Edit
gettingStartedPanel.833059170dbbf8d5c4bf.js
Edit
gettingStartedPanel.833059170dbbf8d5c4bf.js.map
Edit
grafana.1492.25120d27db88f863e058.css
Edit
grafana.4350.a45e45977094df4a0bc9.css
Edit
grafana.5790.ffb3a9cd952d3cd7471b.css
Edit
grafana.DashboardPage.a66335f88cd003e4a44f.css
Edit
grafana.DashboardPageProxy.a66335f88cd003e4a44f.css
Edit
grafana.app.1f6473bb54b1e1647be8.css
Edit
grafana.dark.1e8d85816912aadbbba5.css
Edit
grafana.dataGridPanel.c1fc5db1829b1b31eb4d.css
Edit
grafana.geomapPanel.0057d964fa972bb207ec.css
Edit
grafana.light.111a5a99fcebc0962ddc.css
Edit
grafana.livePanel.25120d27db88f863e058.css
Edit
grafana.react-monaco-editor.ffb3a9cd952d3cd7471b.css
Edit
grafana.swagger.d0a2da197b9827204ac1.css
Edit
grafana.tablePanel.25120d27db88f863e058.css
Edit
grafanaPlugin.f21cdb4b84a732cc9dd8.js
Edit
grafanaPlugin.f21cdb4b84a732cc9dd8.js.map
Edit
heatmapPanel.7834b997bc573eddba88.js
Edit
heatmapPanel.7834b997bc573eddba88.js.map
Edit
histogramPanel.9953bfeccf8774500c0c.js
Edit
histogramPanel.9953bfeccf8774500c0c.js.map
Edit
img
Edit
influxdbPlugin.7a899e63be0a65d41e13.js
Edit
influxdbPlugin.7a899e63be0a65d41e13.js.map
Edit
light.827d442410485e491818.js
Edit
livePanel.2a43f499bc746d928d45.js
Edit
livePanel.2a43f499bc746d928d45.js.map
Edit
logsPanel.a328022d248508a083c1.js
Edit
logsPanel.a328022d248508a083c1.js.map
Edit
loki-query-field.f9a0b82b636d4821760c.js
Edit
loki-query-field.f9a0b82b636d4821760c.js.map
Edit
maps
Edit
mixedPlugin.3a69de93f366afbb2f85.js
Edit
newsPanel.c17f40f7c88ea14620e7.js
Edit
newsPanel.c17f40f7c88ea14620e7.js.map
Edit
nodeGraphPanel.f717a9075d994a9a8af4.js
Edit
nodeGraphPanel.f717a9075d994a9a8af4.js.map
Edit
opentsdbPlugin.1795eab1c223ea030c2e.js
Edit
opentsdbPlugin.1795eab1c223ea030c2e.js.map
Edit
pieChartPanel.45166aa6d57d163817ea.js
Edit
pieChartPanel.45166aa6d57d163817ea.js.map
Edit
prometheusPlugin.c3a55eb5353085fc3d2b.js
Edit
prometheusPlugin.c3a55eb5353085fc3d2b.js.map
Edit
radialBarPanel.294c52d497d8f5c2bebb.js
Edit
radialBarPanel.294c52d497d8f5c2bebb.js.map
Edit
runtime.a37cc2f12a959f33871a.js
Edit
runtime.a37cc2f12a959f33871a.js.map
Edit
sql-query-editor.e767d4a2aef360034bd9.js
Edit
sql-query-editor.e767d4a2aef360034bd9.js.map
Edit
statPanel.3a7f191bfb27fd320014.js
Edit
statPanel.3a7f191bfb27fd320014.js.map
Edit
stateTimelinePanel.08d857b143ef89dc195f.js
Edit
stateTimelinePanel.08d857b143ef89dc195f.js.map
Edit
static
Edit
statusHistoryPanel.29f7b8dc01039ba795af.js
Edit
statusHistoryPanel.29f7b8dc01039ba795af.js.map
Edit
swagger.06875a6266679f54141d.js
Edit
swagger.06875a6266679f54141d.js.map
Edit
tablePanel.43861ce2a60617dcd19d.js
Edit
tablePanel.43861ce2a60617dcd19d.js.map
Edit
textPanel.867ee60d01b2039aa159.js
Edit
textPanel.867ee60d01b2039aa159.js.map
Edit
timeseriesPanel.b4a947da450030262a31.js
Edit
timeseriesPanel.b4a947da450030262a31.js.map
Edit
tracesPanel.35bfc3e5ff6bea4212a3.js
Edit
tracesPanel.35bfc3e5ff6bea4212a3.js.map
Edit
trendPanel.001aff2bd153e737c464.js
Edit
trendPanel.001aff2bd153e737c464.js.map
Edit
vis-data.b34535ebabc0fcb91557.js
Edit
vis-data.b34535ebabc0fcb91557.js.map
Edit
vis-network.1b41caf21892c9525709.js
Edit
vis-network.1b41caf21892c9525709.js.map
Edit
welcomeBanner.1a693c9dc02006be4f0b.js
Edit
welcomeBanner.1a693c9dc02006be4f0b.js.map
Edit
xychart.cb20af67a6c495ba6ccd.js
Edit
xychart.cb20af67a6c495ba6ccd.js.map
Edit